From 44255b3b3996c68b209da65b32eecc8216a40463 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Tue, 9 Jun 2026 17:29:39 -0400 Subject: [PATCH 01/12] Update project configuration and enhance documentation - Added new entries to `.gitignore` for Gradle build artifacts and node modules. - Expanded the `todo.md` file to include detailed implementation plans for the MCS Hot-Reload Mod, covering core functionality, project phases, and configuration management. - Introduced a context manager in `config_utils.py` for temporary configuration overrides. - Enhanced argument parsing in `shell_commands.py` to support new flags for the compile command, including `--mc-version` and `--force`. - Updated the `CompileInterpreter` to conditionally track built-in function usage based on logging style. - Minor adjustments to built-in log function templates for consistency. Co-authored-by: Cursor --- .github/workflows/mod.yml | 31 ++ .gitignore | 5 + .../builtins/1.21.2/log.mcfunction | 12 +- .../compiler/compile_interpreter.py | 4 +- minecraft_script/config_utils.py | 13 + minecraft_script/shell_commands.py | 97 ++++- mod/README.md | 65 ++++ mod/build.gradle | 66 ++++ .../.architectury-transformer/debug.log | 106 ++++++ .../.gradle/architectury-cache/projectID | 1 + mod/common/build.gradle | 32 ++ .../dev/spyc0der77/mcspacks/McsPacks.java | 48 +++ .../spyc0der77/mcspacks/config/ModConfig.java | 14 + .../mcspacks/config/ModConfigManager.java | 34 ++ .../mcspacks/deploy/DatapackDeployer.java | 71 ++++ .../mcspacks/pipeline/PackPipeline.java | 163 ++++++++ .../mcspacks/registry/PackDefinition.java | 12 + .../mcspacks/registry/PackRegistry.java | 93 +++++ .../mcspacks/toolchain/CompilerResolver.java | 148 ++++++++ .../mcspacks/toolchain/Diagnostic.java | 7 + .../mcspacks/toolchain/McsToolchain.java | 129 +++++++ .../mcspacks/toolchain/ProcessResult.java | 7 + .../mcspacks/toolchain/SubprocessRunner.java | 29 ++ .../spyc0der77/mcspacks/util/McsPaths.java | 91 +++++ .../mcspacks/util/PlayerFeedback.java | 23 ++ .../mcspacks/version/VersionMapper.java | 56 +++ .../mcspacks/watch/PackWatcher.java | 259 +++++++++++++ .../src/main/resources/mcs-versions.json | 21 ++ .../main/resources/scripts/mcs-compile.cmd | 44 +++ .../scripts/mcs-spyglass-validate.mjs | 199 ++++++++++ .../src/main/resources/starter/pack.mcs | 16 + .../mcspacks/toolchain/CompilerResolver.class | Bin 0 -> 7266 bytes mod/fabric/build.gradle | 49 +++ mod/fabric/gradle.properties | 1 + .../mcspacks/fabric/McsPacksFabric.java | 11 + mod/fabric/src/main/resources/fabric.mod.json | 20 + mod/forge/build.gradle | 54 +++ mod/forge/gradle.properties | 1 + .../mcspacks/forge/McsPacksForge.java | 13 + .../src/main/resources/META-INF/mods.toml | 32 ++ .../src/main/resources/mcs_packs.mixins.json | 9 + mod/gradle.properties | 25 ++ mod/gradle/wrapper/gradle-wrapper.jar | Bin 0 -> 43583 bytes mod/gradle/wrapper/gradle-wrapper.properties | 7 + mod/gradlew.bat | 94 +++++ mod/neoforge/build.gradle | 54 +++ mod/neoforge/gradle.properties | 1 + .../mcspacks/neoforge/McsPacksNeoForge.java | 13 + .../resources/META-INF/neoforge.mods.toml | 32 ++ mod/scripts/apply_version.py | 59 +++ mod/scripts/build_all.py | 66 ++++ mod/scripts/bun.lock | 203 ++++++++++ mod/scripts/mcs-spyglass-validate.mjs | 199 ++++++++++ mod/scripts/package.json | 10 + mod/settings.gradle | 31 ++ mod/versions/manifest.json | 85 +++++ tests/test_compile_cli_flags.py | 94 +++++ todo.md | 357 +++++++++++++++++- 58 files changed, 3391 insertions(+), 25 deletions(-) create mode 100644 .github/workflows/mod.yml create mode 100644 mod/README.md create mode 100644 mod/build.gradle create mode 100644 mod/common/.gradle/.architectury-transformer/debug.log create mode 100644 mod/common/.gradle/architectury-cache/projectID create mode 100644 mod/common/build.gradle create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfig.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackDefinition.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/Diagnostic.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/ProcessResult.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java create mode 100644 mod/common/src/main/resources/mcs-versions.json create mode 100644 mod/common/src/main/resources/scripts/mcs-compile.cmd create mode 100644 mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs create mode 100644 mod/common/src/main/resources/starter/pack.mcs create mode 100644 mod/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.class create mode 100644 mod/fabric/build.gradle create mode 100644 mod/fabric/gradle.properties create mode 100644 mod/fabric/src/main/java/dev/spyc0der77/mcspacks/fabric/McsPacksFabric.java create mode 100644 mod/fabric/src/main/resources/fabric.mod.json create mode 100644 mod/forge/build.gradle create mode 100644 mod/forge/gradle.properties create mode 100644 mod/forge/src/main/java/dev/spyc0der77/mcspacks/forge/McsPacksForge.java create mode 100644 mod/forge/src/main/resources/META-INF/mods.toml create mode 100644 mod/forge/src/main/resources/mcs_packs.mixins.json create mode 100644 mod/gradle.properties create mode 100644 mod/gradle/wrapper/gradle-wrapper.jar create mode 100644 mod/gradle/wrapper/gradle-wrapper.properties create mode 100644 mod/gradlew.bat create mode 100644 mod/neoforge/build.gradle create mode 100644 mod/neoforge/gradle.properties create mode 100644 mod/neoforge/src/main/java/dev/spyc0der77/mcspacks/neoforge/McsPacksNeoForge.java create mode 100644 mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml create mode 100644 mod/scripts/apply_version.py create mode 100644 mod/scripts/build_all.py create mode 100644 mod/scripts/bun.lock create mode 100644 mod/scripts/mcs-spyglass-validate.mjs create mode 100644 mod/scripts/package.json create mode 100644 mod/settings.gradle create mode 100644 mod/versions/manifest.json create mode 100644 tests/test_compile_cli_flags.py diff --git a/.github/workflows/mod.yml b/.github/workflows/mod.yml new file mode 100644 index 0000000..14cae9d --- /dev/null +++ b/.github/workflows/mod.yml @@ -0,0 +1,31 @@ +name: Mod + +on: + push: + paths: + - 'mod/**' + - 'minecraft_script/versions/**' + pull_request: + paths: + - 'mod/**' + - 'minecraft_script/versions/**' + +jobs: + build-matrix: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + profile: [1.21.2, 1.21.4, 1.21.5, 1.21.6, 1.21.7-8, 1.21.9-10, 1.21.11, 26.1] + loader: [fabric, forge, neoforge] + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-java@v4 + with: + distribution: temurin + java-version: 21 + - name: Apply version profile + run: python mod/scripts/apply_version.py ${{ matrix.profile }} + - name: Build ${{ matrix.loader }} for ${{ matrix.profile }} + working-directory: mod + run: ./gradlew :${{ matrix.loader }}:build -Pmcs_profile=${{ matrix.profile }} -x test diff --git a/.gitignore b/.gitignore index 40114b9..b33acc8 100644 --- a/.gitignore +++ b/.gitignore @@ -13,6 +13,11 @@ build/ dist/ *.egg-info/ build_test/ +mod/.gradle/ +mod/build/ +mod/out/ +mod/run/ +mod/scripts/node_modules/ highlighter/node_modules/ highlighter/dist/ highlighter/*.vsix diff --git a/minecraft_script/compiler/build_templates/builtins/1.21.2/log.mcfunction b/minecraft_script/compiler/build_templates/builtins/1.21.2/log.mcfunction index 14482e7..5426d29 100644 --- a/minecraft_script/compiler/build_templates/builtins/1.21.2/log.mcfunction +++ b/minecraft_script/compiler/build_templates/builtins/1.21.2/log.mcfunction @@ -1,7 +1,7 @@ -data modify storage minecraft:temp mcs_log set value "" -data modify storage minecraft:temp mcs_log append value from storage $(s0) $(n0) -data modify storage minecraft:temp mcs_log append value from storage $(s1) $(n1) -data modify storage minecraft:temp mcs_log append value from storage $(s2) $(n2) -data modify storage minecraft:temp mcs_log append value from storage $(s3) $(n3) -data modify storage minecraft:temp mcs_log append value from storage $(s4) $(n4) +$data modify storage minecraft:temp mcs_log set value "" +$data modify storage minecraft:temp mcs_log append value from storage $(s0) $(n0) +$data modify storage minecraft:temp mcs_log append value from storage $(s1) $(n1) +$data modify storage minecraft:temp mcs_log append value from storage $(s2) $(n2) +$data modify storage minecraft:temp mcs_log append value from storage $(s3) $(n3) +$data modify storage minecraft:temp mcs_log append value from storage $(s4) $(n4) $tellraw @a [{"nbt":"mcs_log","storage":"minecraft:temp","interpret":true}] diff --git a/minecraft_script/compiler/compile_interpreter.py b/minecraft_script/compiler/compile_interpreter.py index 9682473..f099e7e 100644 --- a/minecraft_script/compiler/compile_interpreter.py +++ b/minecraft_script/compiler/compile_interpreter.py @@ -493,7 +493,9 @@ def visit_FunctionCallNode(self, node, context: CompileContext) -> CompileResult self.schedule_function_generation(fnc) commands, return_value = fnc.call(self, arguments, context) if is_builtin: - self.used_builtin_functions.add(fnc.call.__name__) + builtin_name = fnc.call.__name__ + if builtin_name != "log" or self.version.orchestration.get("mcs_features", {}).get("log", {}).get("style") != "direct_tellraw": + self.used_builtin_functions.add(builtin_name) if commands is not None: commands = add_comment(tuple(commands), "Function call") self.add_commands(context.mcfunction_name, commands) diff --git a/minecraft_script/config_utils.py b/minecraft_script/config_utils.py index 07efec3..1c60752 100644 --- a/minecraft_script/config_utils.py +++ b/minecraft_script/config_utils.py @@ -1,10 +1,23 @@ import json +from contextlib import contextmanager from pathlib import Path from .common import COMMON_CONFIG, module_folder from .version_config import list_supported_versions, load_version_profile +@contextmanager +def temporary_config(**overrides): + saved = {key: COMMON_CONFIG[key] for key in overrides} + try: + for key, value in overrides.items(): + COMMON_CONFIG[key] = value + yield + finally: + for key, value in saved.items(): + COMMON_CONFIG[key] = value + + def _write_config() -> None: with open(f"{module_folder}/config.json", "wt", encoding="utf-8") as file: json.dump(COMMON_CONFIG, file, indent=4, ensure_ascii=False) diff --git a/minecraft_script/shell_commands.py b/minecraft_script/shell_commands.py index 6b667a7..631410f 100644 --- a/minecraft_script/shell_commands.py +++ b/minecraft_script/shell_commands.py @@ -1,15 +1,56 @@ import json +import shutil import sys from . import debug_code from .compiler import build_datapack from .common import COMMON_CONFIG, version -from .config_utils import update_config, reset_config +from .config_utils import config_minecraft_version_check, temporary_config, update_config, reset_config from .lint import lint_code from .version_config import breaking_changes_between from pathlib import Path +def _parse_flag_args( + args: list, + *, + boolean_flags: set[str], + value_flags: set[str], +) -> tuple[dict[str, str | bool], list[str]]: + parsed: dict[str, str | bool] = {} + positional: list[str] = [] + supported_flags = boolean_flags | value_flags + index = 0 + while index < len(args): + arg = args[index] + if arg.startswith("--") and "=" in arg: + flag, value = arg.split("=", 1) + if flag in value_flags: + parsed[flag] = value + index += 1 + continue + if arg in boolean_flags: + parsed[arg] = True + index += 1 + continue + if arg in value_flags: + next_arg = args[index + 1] if index + 1 < len(args) else None + if next_arg is None or next_arg.startswith("--"): + print(f"Error: {arg} requires a value.") + exit(-1) + parsed[arg] = next_arg + index += 2 + continue + if arg.startswith("--"): + if arg not in supported_flags: + positional.append(arg) + index += 1 + continue + positional.append(arg) + index += 1 + return parsed, positional + + def handle_arguments(arguments: list): if not arguments: sh_default() @@ -31,10 +72,10 @@ def handle_arguments(arguments: list): - debug : debug the minecraft script file found at the given path. -- compile [] []: compile the associated -mcs file into a datapack. The resulting datapack folder will be named after -the mcs file, unless a datapack name is specified. The output path argument -specifies where the datapack should be generated (default to current path). +- compile [--mc-version ] [--force] [--verbose|--no-verbose] +[] []: compile the associated mcs file into a +datapack. --mc-version selects the Minecraft version profile without changing +config.json. --force deletes an existing output datapack folder before building. - lint [--json]: validate MCS syntax and imports for the given file. Use --stdin to read code from standard input and pass --source so @@ -79,29 +120,35 @@ def sh_debug(*args) -> None: def sh_compile(*args) -> None: - # Manage args & parameters: - arg_count = len(args) - if arg_count < 1: + flags, positional = _parse_flag_args( + list(args), + boolean_flags={"--force", "--verbose", "--no-verbose"}, + value_flags={"--mc-version"}, + ) + if len(positional) < 1: print("No path specified to compile.") exit() - source_path = Path(args[0]).resolve() + source_path = Path(positional[0]).resolve() datapack_name: str = ( "-".join(source_path.name.split(".")[:-1]).replace("_", " ").title() - if arg_count < 2 else - args[1] + if len(positional) < 2 else + positional[1] ) output_path = ( Path(COMMON_CONFIG["default_output_path"]).resolve() - if arg_count < 3 else - Path(args[2]).expanduser().resolve() + if len(positional) < 3 else + Path(positional[2]).expanduser().resolve() ) verbose = COMMON_CONFIG["verbose"] + if "--verbose" in flags: + verbose = True + if "--no-verbose" in flags: + verbose = False - # Check if given paths are valid: if not source_path.is_file(): - print(f"Error: Could not find file at {args[0] !r}") + print(f"Error: Could not find file at {positional[0] !r}") exit(-1) if output_path.exists() and not output_path.is_dir(): @@ -110,11 +157,27 @@ def sh_compile(*args) -> None: output_path.mkdir(parents=True, exist_ok=True) - # Build datapack + datapack_folder = output_path / datapack_name + if "--force" in flags and datapack_folder.exists(): + shutil.rmtree(datapack_folder) + + overrides: dict[str, object] = {} + if "--mc-version" in flags: + mc_version = flags["--mc-version"] + if not isinstance(mc_version, str) or mc_version is True: + print("Error: --mc-version requires a value.") + exit(-1) + overrides["minecraft_version"] = config_minecraft_version_check(mc_version, "minecraft_version") + if "--verbose" in flags: + overrides["verbose"] = True + if "--no-verbose" in flags: + overrides["verbose"] = False + with open(source_path, 'rt', encoding='utf-8') as mcs_file: code = mcs_file.read() - build_datapack(code, datapack_name, str(output_path), verbose, source_path=source_path) + with temporary_config(**overrides): + build_datapack(code, datapack_name, str(output_path), verbose, source_path=source_path) def sh_config(*args) -> None: diff --git a/mod/README.md b/mod/README.md new file mode 100644 index 0000000..410ade4 --- /dev/null +++ b/mod/README.md @@ -0,0 +1,65 @@ +# MCS Packs Mod + +Architectury mod for Fabric, Forge, and NeoForge. Watches `.minecraft/mcs_packs//`, runs `mcs lint` → `mcs compile` → Spyglass validation, then hot-reloads into the active world. + +## Requirements + +- Java 21 +- MCS installed (`pip install -e .` from this repo). The mod auto-detects `mcs`, `python -m minecraft_script`, or common Windows Python installs; launchers with a limited PATH (Modrinth, Prism, etc.) get a bundled `mcs-compile.cmd` fallback. +- Node.js on PATH (Spyglass post-compile validation; optional — disable in `config/mcs-packs.json`) + +## Supported Minecraft versions + +All MCS profiles from `minecraft_script/versions/index.json`: + +| MCS profile | Minecraft versions | +| ----------- | ------------------ | +| `1.21.2` | 1.21.2 | +| `1.21.4` | 1.21.4 | +| `1.21.5` | 1.21.5 | +| `1.21.6` | 1.21.6 | +| `1.21.7-8` | 1.21.7, 1.21.8 | +| `1.21.9-10` | 1.21.9, 1.21.10 | +| `1.21.11` | 1.21.11 | +| `26.1` | 26.1 | + +Build one profile: + +```bash +cd mod +python scripts/apply_version.py 1.21.11 +./gradlew :fabric:build -Pmcs_profile=1.21.11 +``` + +Build every profile × loader (24 artifacts): + +```bash +cd mod +python scripts/build_all.py +``` + +Build a single target: + +```bash +python scripts/build_all.py --profile 1.21.4 --loader fabric +``` + +## Layout + +``` +.minecraft/ + config/mcs-packs.json + mcs_packs/ + starter/pack.mcs + my_pack/pack.mcs + _compiled/ +``` + +## Dev run (Fabric) + +```bash +python scripts/apply_version.py 1.21.11 +./gradlew :fabric:runClient -Pmcs_profile=1.21.11 +``` + +Loader dependency versions live in `versions/manifest.json`. Update those pins when bumping Minecraft support. diff --git a/mod/build.gradle b/mod/build.gradle new file mode 100644 index 0000000..92eed01 --- /dev/null +++ b/mod/build.gradle @@ -0,0 +1,66 @@ +import groovy.json.JsonSlurper + +plugins { + id 'dev.architectury.loom' version "${architectury_loom_version}" apply false + id 'architectury-plugin' version "${architectury_plugin_version}" + id 'maven-publish' +} + +def manifest = new JsonSlurper().parse(file('versions/manifest.json')) +def activeProfileName = findProperty('mcs_profile') ?: '1.21.11' +def activeProfile = manifest.profiles[activeProfileName] +if (activeProfile == null) { + throw new GradleException("Unknown mcs_profile '${activeProfileName}'. See versions/manifest.json") +} + +ext { + mcsProfileName = activeProfileName + mcsMinecraftProfile = activeProfile.mcs_profile + supportedGameVersions = (activeProfile.supported_game_versions as List).join(',') +} + +allprojects { + group = rootProject.maven_group + version = rootProject.mod_version +} + +subprojects { + apply plugin: 'dev.architectury.loom' + apply plugin: 'architectury-plugin' + apply plugin: 'maven-publish' + + repositories { + mavenCentral() + maven { url = 'https://maven.fabricmc.net/' } + maven { url = 'https://maven.architectury.dev/' } + maven { url = 'https://files.minecraftforge.net/maven/' } + maven { url = 'https://maven.neoforged.net/releases' } + } + + base { + archivesName = "${rootProject.archives_base_name}-${rootProject.mcsProfileName}-${project.name}" + } + + loom { + silentMojangMappingsLicense() + } + + dependencies { + minecraft "net.minecraft:minecraft:${rootProject.minecraft_version}" + mappings loom.officialMojangMappings() + } + + java { + withSourcesJar() + sourceCompatibility = JavaVersion.VERSION_21 + targetCompatibility = JavaVersion.VERSION_21 + } + + tasks.withType(JavaCompile).configureEach { + it.options.release = 21 + } +} + +architectury { + minecraft = rootProject.minecraft_version +} diff --git a/mod/common/.gradle/.architectury-transformer/debug.log b/mod/common/.gradle/.architectury-transformer/debug.log new file mode 100644 index 0000000..55a418e --- /dev/null +++ b/mod/common/.gradle/.architectury-transformer/debug.log @@ -0,0 +1,106 @@ +[Architectury Transformer DEBUG] +[Architectury Transformer DEBUG] ============================ +[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar +[Architectury Transformer DEBUG] ============================ +[Architectury Transformer DEBUG] +[Architectury Transformer DEBUG] Transforming 5 transformer(s) from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar: +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapMixinVariables@2dec85a9 +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformExpectPlatform@158e3f53 +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapInjectables@780b10da +[Architectury Transformer DEBUG] - AddRefmapName(enabled=() -> kotlin.Boolean) +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformPlatformOnly@3e698c0 +[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar with 5 transformer(s) on dev.architectury.transformer.handler.SimpleTransformerHandler +[Architectury Transformer DEBUG] Found class transformer +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/watch/PackWatcher with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/version/VersionMapper with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/version/VersionMapper$Index with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/util/PlayerFeedback with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/util/McsPaths with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/SubprocessRunner with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/ProcessResult with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/McsToolchain with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/McsToolchain$1 with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/Diagnostic with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/CompilerResolver with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/CompilerResolver$CompilerCommand with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/registry/PackRegistry with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/registry/PackRegistry$PackOverrides with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/registry/PackDefinition with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/pipeline/PackPipeline with maxs=true frames=true +[Architectury Transformer DEBUG] Provided 67 classpath jar(s): +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\dev.architectury\architectury-injectables\1.0.10\62db2a366d662606d1b23ad02ccc3212ed37ec3\architectury-injectables-1.0.10.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.fabricmc\fabric-loader\0.19.3\354dfaa02d0552e11867f85dff7cdbfaf813ba3e\fabric-loader-0.19.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jetbrains\annotations\26.0.2\c7ce3cdeda3d18909368dfe5977332dfad326c6d\annotations-26.0.2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.code.gson\gson\2.13.2\48b8230771e573b54ce6e867a9001e75977fe78e\gson-2.13.2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm\9.9\c29635c8a7afa03d74b33c1884df8abb2b3f3dcc\asm-9.9.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-analysis\9.9\bf4fa6e66638851c1cd22c2caea0c3ee5d5f437\asm-analysis-9.9.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-commons\9.9\db9165a3bf908ded6b08612d583a15d1d0c7bda0\asm-commons-9.9.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-tree\9.9\f8de6eead6d24dd0f45bd065bbe112b2cda6ea21\asm-tree-9.9.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-util\9.9\42fdfc0508b43807c8078d6e82ecff2ce2112ae8\asm-util-9.9.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.fabricmc\sponge-mixin\0.16.5+mixin.0.8.7\80fc3a9f592673cea87f4cd702f87991c6c9fe4d\sponge-mixin-0.16.5+mixin.0.8.7.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.github.llamalad7\mixinextras-fabric\0.5.0\91a83dfb7abd320f6236bd1fcf5c0ff143d59a13\mixinextras-fabric-0.5.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\at.yawk.lz4\lz4-java\1.8.1\1f30a180ee04ccd53339a716aec13cae60a013b5\lz4-java-1.8.1.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.azure\azure-json\1.4.0\fcc1d354dbc3e0300e5276b1bf124d0247799cd8\azure-json-1.4.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.github.oshi\oshi-core\6.9.0\3224870731860cfcd7744581a05b559e94291e7\oshi-core-6.9.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.guava\failureaccess\1.0.3\aeaffd00d57023a2c947393ed251f0354f0985fc\failureaccess-1.0.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.guava\guava\33.5.0-jre\8699de25f2f979108d6c1b804a7ba38cda1116bc\guava-33.5.0-jre.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.ibm.icu\icu4j\77.1\38693cf0b1d7362a8b726af74dc06026a7c23809\icu4j-77.1.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.microsoft.azure\msal4j\1.23.1\6c722b514873b24a4e1ce9c22dca36ea3c22bdbe\msal4j-1.23.1.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\authlib\7.0.61\efee1e6b54e863108576eb3b3ae71144626aaefc\authlib-7.0.61.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\blocklist\1.0.10\5c685c5ffa94c4cd39496c7184c1d122e515ecef\blocklist-1.0.10.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\brigadier\1.3.10\d15b53a14cf20fdcaa98f731af5dda654452c010\brigadier-1.3.10.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\datafixerupper\9.0.19\4e91f9712fa1e83231d1501625381b0210a977da\datafixerupper-9.0.19.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\jtracy\1.0.37\a3fb649b2e2b2288d2978f0b0bc3d83f62809d1e\jtracy-1.0.37.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\logging\1.6.11\fd147240733010c158249d986323f9ef98977fe\logging-1.6.11.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\patchy\2.2.10\da05971b07cbb379d002cf7eaec6a2048211fefc\patchy-2.2.10.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\text2speech\1.18.11\e853a12cdd6ba4f4836e8f4bf3b37844a13482b6\text2speech-1.18.11.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\commons-codec\commons-codec\1.19.0\8c0dbe3ae883fceda9b50a6c76e745e548073388\commons-codec-1.19.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\commons-io\commons-io\2.20.0\36f3474daec2849c149e877614e7f979b2082cd2\commons-io-2.20.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-buffer\4.2.7.Final\5555ff561643bf2f8430fb57c24403c0efe15994\netty-buffer-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-base\4.2.7.Final\915e381ebabcf115f1c7ff7032d55c48afb50210\netty-codec-base-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-compression\4.2.7.Final\572341bc1ca90fd9d6e47f1d2694aab5258566e9\netty-codec-compression-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-http\4.2.7.Final\b734c108854099c421fd94d92d9f865e4d4da853\netty-codec-http-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-common\4.2.7.Final\11aa30df26af4fca3239ac1917f303a280f301e1\netty-common-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-handler\4.2.7.Final\7ad8a1f851e2e6fe93cdd091871fda2b81c03b5b\netty-handler-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-resolver\4.2.7.Final\5f3e5ef8de03992cd4fb46960dc0085ec1a12a12\netty-resolver-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-classes-epoll\4.2.7.Final\1075c09f48a78eef9d819fbfd9096b903fdd362a\netty-transport-classes-epoll-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-classes-kqueue\4.2.7.Final\bdec7c23c75caabd848426d073c09568e8d5f94e\netty-transport-classes-kqueue-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-unix-common\4.2.7.Final\89953f04259ea7502cffb313630dd51e00e60669\netty-transport-native-unix-common-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport\4.2.7.Final\83ea548981d0d8c4a98027cc1a6f9624f902e142\netty-transport-4.2.7.Final.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\it.unimi.dsi\fastutil\8.5.18\a6cff377eecc19c2037bf31568a6d7106b50ba1f\fastutil-8.5.18.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.java.dev.jna\jna-platform\5.17.0\a4934c44d25a9d8c2ddf4203affd20330cb3426f\jna-platform-5.17.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.java.dev.jna\jna\5.17.0\33d12735bef894440780fce64f9758d420c7bae2\jna-5.17.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.sf.jopt-simple\jopt-simple\5.0.4\4fdac2fbe92dfad86aa6e9301736f6b4342a3f5c\jopt-simple-5.0.4.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.commons\commons-compress\1.28.0\e482f2c7a88dac3c497e96aa420b6a769f59c8d7\commons-compress-1.28.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.commons\commons-lang3\3.19.0\d6524b169a6574cd253760c472d419b47bfd37e6\commons-lang3-3.19.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-api\2.25.2\292c1a2b1702f1e1e3adb13e1c57e5bff60335ff\log4j-api-2.25.2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-core\2.25.2\d4d0ad2e51e03e531f784891fbfff1bae1e13a12\log4j-core-2.25.2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-slf4j2-impl\2.25.2\5eec0c392661dee8a366baec17e8896900dd978f\log4j-slf4j2-impl-2.25.2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jcraft\jorbis\0.0.17\8872d22b293e8f5d7d56ff92be966e6dc28ebdc6\jorbis-0.0.17.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.joml\joml\1.10.8\fc0a71dad90a2cf41d82a76156a0e700af8e4f8d\joml-1.10.8.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jspecify\jspecify\1.0.0\7425a601c1c7ec76645a78d22b8c6a627edee507\jspecify-1.0.0.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-freetype\3.3.3\a0db6c84a8becc8ca05f9dbfa985edc348a824c7\lwjgl-freetype-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-glfw\3.3.3\efa1eb78c5ccd840e9f329717109b5e892d72f8e\lwjgl-glfw-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-jemalloc\3.3.3\b543467b7ff3c6920539a88ee602d34098628be5\lwjgl-jemalloc-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-openal\3.3.3\daada81ceb5fc0c291fbfdd4433cb8d9423577f2\lwjgl-openal-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-opengl\3.3.3\2f6b0147078396a58979125a4c947664e98293a\lwjgl-opengl-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-stb\3.3.3\25dd6161988d7e65f71d5065c99902402ee32746\lwjgl-stb-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-tinyfd\3.3.3\82d755ca94b102e9ca77283b9e2dc46d1b15fbe5\lwjgl-tinyfd-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl\3.3.3\29589b5f87ed335a6c7e7ee6a5775f81f97ecb84\lwjgl-3.3.3.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.slf4j\slf4j-api\2.0.17\d9e58ac9c7779ba3bf8142aff6c830617a7fe60f\slf4j-api-2.0.17.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\Code\Minecraft-Script\mod\.gradle\loom-cache\minecraftMaven\net\minecraft\minecraft-merged-c69b0de466\1.21.11-loom.mappings.1_21_11.layered+hash.40359-v2\minecraft-merged-c69b0de466-1.21.11-loom.mappings.1_21_11.layered+hash.40359-v2.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-epoll\4.2.7.Final\e83998bfc10b5289d9bcbe807c4079ef0eed8e6f\netty-transport-native-epoll-4.2.7.Final-linux-x86_64.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-epoll\4.2.7.Final\98d02251c98c8f07a23ac5ea27657d9e0ef57614\netty-transport-native-epoll-4.2.7.Final-linux-aarch_64.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-kqueue\4.2.7.Final\40868fd4e43bce2798245f790624b58803dc26b6\netty-transport-native-kqueue-4.2.7.Final-osx-x86_64.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-kqueue\4.2.7.Final\e5a0feef41410c8a5ae00c6cb4e0c99bd0aded6a\netty-transport-native-kqueue-4.2.7.Final-osx-aarch_64.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\Code\Minecraft-Script\mod\.gradle\loom-cache\remapped_mods\remapped\dev\architectury\architectury-6a6b1e70\19.0.1\architectury-6a6b1e70-19.0.1.jar +[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.errorprone\error_prone_annotations\2.41.0\4381275efdef6ddfae38f002c31e84cd001c97f0\error_prone_annotations-2.41.0.jar +[Architectury Transformer] Read classpath in 1.433 s +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/McsPacks with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer$2 with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer$1 with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/config/ModConfigManager with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/config/ModConfig with maxs=true frames=true +[Architectury Transformer DEBUG] Closed File Systems for C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar +[Architectury Transformer] Transformed jar with 5 transformer(s) in 1.539 s diff --git a/mod/common/.gradle/architectury-cache/projectID b/mod/common/.gradle/architectury-cache/projectID new file mode 100644 index 0000000..8461cfb --- /dev/null +++ b/mod/common/.gradle/architectury-cache/projectID @@ -0,0 +1 @@ +6035d13486624f5d8089c57a493f5da2 \ No newline at end of file diff --git a/mod/common/build.gradle b/mod/common/build.gradle new file mode 100644 index 0000000..a854d87 --- /dev/null +++ b/mod/common/build.gradle @@ -0,0 +1,32 @@ +architectury { + common rootProject.enabled_platforms.split(',') +} + +dependencies { + modImplementation "dev.architectury:architectury:${rootProject.architectury_api_version}" + implementation 'com.google.code.gson:gson:2.11.0' +} + +processResources { + inputs.property 'mod_version', project.version + inputs.property 'minecraft_version', rootProject.minecraft_version + inputs.property 'mcs_profile', rootProject.mcsProfileName + inputs.property 'mcs_minecraft_profile', rootProject.mcsMinecraftProfile + inputs.property 'supported_game_versions', rootProject.supportedGameVersions + + filesMatching('fabric.mod.json') { + expand 'mod_version': project.version, + 'minecraft_version': rootProject.minecraft_version, + 'supported_game_versions': rootProject.supportedGameVersions + } + filesMatching('META-INF/mods.toml') { + expand 'mod_version': project.version, + 'minecraft_version': rootProject.minecraft_version, + 'supported_game_versions': rootProject.supportedGameVersions + } + filesMatching('META-INF/neoforge.mods.toml') { + expand 'mod_version': project.version, + 'minecraft_version': rootProject.minecraft_version, + 'supported_game_versions': rootProject.supportedGameVersions + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java new file mode 100644 index 0000000..6301ca3 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java @@ -0,0 +1,48 @@ +package dev.spyc0der77.mcspacks; + +import dev.architectury.event.events.common.LifecycleEvent; +import dev.spyc0der77.mcspacks.config.ModConfig; +import dev.spyc0der77.mcspacks.config.ModConfigManager; +import dev.spyc0der77.mcspacks.pipeline.PackPipeline; +import dev.spyc0der77.mcspacks.registry.PackRegistry; +import dev.spyc0der77.mcspacks.util.McsPaths; +import dev.spyc0der77.mcspacks.util.PlayerFeedback; +import dev.spyc0der77.mcspacks.version.VersionMapper; +import dev.spyc0der77.mcspacks.watch.PackWatcher; +import net.minecraft.server.MinecraftServer; + +public final class McsPacks { + private static PackPipeline pipeline; + private static PackWatcher watcher; + + private McsPacks() { + } + + public static void init() { + McsPaths.ensureLayout(); + ModConfig config = ModConfigManager.load(); + VersionMapper versionMapper = VersionMapper.load(); + PackRegistry registry = new PackRegistry(McsPaths.packsRoot(), McsPaths.compiledRoot()); + pipeline = new PackPipeline(config, versionMapper, registry, PlayerFeedback::broadcast); + watcher = new PackWatcher(McsPaths.packsRoot(), pipeline::handlePackChange, config.debounceMs); + + pipeline.warmCompileAllPacks(); + + LifecycleEvent.SERVER_STARTING.register(McsPacks::onServerStarting); + LifecycleEvent.SERVER_STARTED.register(McsPacks::onServerStarted); + LifecycleEvent.SERVER_STOPPING.register(McsPacks::onServerStopping); + } + + private static void onServerStarting(MinecraftServer server) { + pipeline.prepareWorldPacks(server); + } + + private static void onServerStarted(MinecraftServer server) { + watcher.refreshBaselines(); + watcher.start(); + } + + private static void onServerStopping(MinecraftServer server) { + watcher.stop(); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfig.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfig.java new file mode 100644 index 0000000..b5e6f70 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfig.java @@ -0,0 +1,14 @@ +package dev.spyc0der77.mcspacks.config; + +public class ModConfig { + public String compiler = "auto"; + public String compilerPath = ""; + public int debounceMs = 500; + public boolean autoReload = true; + public boolean verboseCompile = false; + public String minecraftVersion = "auto"; + public boolean lintBeforeCompile = true; + public boolean spyglassValidateAfterCompile = true; + public boolean blockCompileOnLintErrors = true; + public boolean blockReloadOnSpyglassErrors = true; +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java new file mode 100644 index 0000000..e4bf1eb --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java @@ -0,0 +1,34 @@ +package dev.spyc0der77.mcspacks.config; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import dev.spyc0der77.mcspacks.util.McsPaths; +import java.io.IOException; +import java.nio.file.Files; + +public final class ModConfigManager { + private static final Gson GSON = new GsonBuilder().setPrettyPrinting().create(); + + private ModConfigManager() { + } + + public static ModConfig load() { + try { + if (Files.notExists(McsPaths.configFile())) { + ModConfig defaults = new ModConfig(); + save(defaults); + return defaults; + } + String json = Files.readString(McsPaths.configFile()); + ModConfig config = GSON.fromJson(json, ModConfig.class); + return config == null ? new ModConfig() : config; + } catch (IOException error) { + throw new IllegalStateException("Failed to read mod config", error); + } + } + + public static void save(ModConfig config) throws IOException { + Files.createDirectories(McsPaths.configFile().getParent()); + Files.writeString(McsPaths.configFile(), GSON.toJson(config)); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java new file mode 100644 index 0000000..8a764c4 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java @@ -0,0 +1,71 @@ +package dev.spyc0der77.mcspacks.deploy; + +import java.io.IOException; +import java.nio.file.FileVisitResult; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.SimpleFileVisitor; +import java.nio.file.StandardCopyOption; +import java.nio.file.attribute.BasicFileAttributes; +import net.minecraft.server.MinecraftServer; +import net.minecraft.server.permissions.PermissionSet; +import net.minecraft.world.level.storage.LevelResource; + +public final class DatapackDeployer { + private DatapackDeployer() { + } + + public static void syncPack(MinecraftServer server, Path compiledPack, String packFolderName) throws IOException { + Path worldDatapacks = server.getWorldPath(LevelResource.DATAPACK_DIR); + Files.createDirectories(worldDatapacks); + Path target = worldDatapacks.resolve(packFolderName); + if (Files.exists(target)) { + deleteRecursive(target); + } + copyRecursive(compiledPack, target); + } + + public static void reload(MinecraftServer server) { + server.submit(() -> server.getCommands().performPrefixedCommand( + server.createCommandSourceStack().withPermission(PermissionSet.ALL_PERMISSIONS), + "reload" + )); + } + + private static void copyRecursive(Path source, Path target) throws IOException { + Files.walkFileTree(source, new SimpleFileVisitor<>() { + @Override + public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) throws IOException { + Files.createDirectories(target.resolve(source.relativize(dir).toString())); + return FileVisitResult.CONTINUE; + } + + @Override + public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException { + Path destination = target.resolve(source.relativize(file).toString()); + Files.createDirectories(destination.getParent()); + Files.copy(file, destination, StandardCopyOption.REPLACE_EXISTING); + return FileVisitResult.CONTINUE; + } + }); + } + + private static void deleteRecursive(Path path) throws IOException { + if (!Files.exists(path)) { + return; + } + Files.walkFileTree(path, new SimpleFileVisitor<>() { + @Override + public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException { + Files.delete(file); + return FileVisitResult.CONTINUE; + } + + @Override + public FileVisitResult postVisitDirectory(Path dir, IOException exc) throws IOException { + Files.delete(dir); + return FileVisitResult.CONTINUE; + } + }); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java new file mode 100644 index 0000000..f1c9192 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java @@ -0,0 +1,163 @@ +package dev.spyc0der77.mcspacks.pipeline; + +import dev.architectury.platform.Platform; +import dev.spyc0der77.mcspacks.config.ModConfig; +import dev.spyc0der77.mcspacks.deploy.DatapackDeployer; +import dev.spyc0der77.mcspacks.registry.PackDefinition; +import dev.spyc0der77.mcspacks.registry.PackRegistry; +import dev.spyc0der77.mcspacks.toolchain.Diagnostic; +import dev.spyc0der77.mcspacks.toolchain.McsToolchain; +import dev.spyc0der77.mcspacks.util.PlayerFeedback; +import dev.spyc0der77.mcspacks.version.VersionMapper; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.List; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.function.BiConsumer; +import net.minecraft.server.MinecraftServer; + +public final class PackPipeline { + private final ModConfig config; + private final VersionMapper versionMapper; + private final PackRegistry registry; + private final BiConsumer messenger; + private final ExecutorService executor = Executors.newSingleThreadExecutor(runnable -> { + Thread thread = new Thread(runnable, "mcs-packs-pipeline"); + thread.setDaemon(true); + return thread; + }); + private final Map generations = new ConcurrentHashMap<>(); + private volatile MinecraftServer activeServer; + + public PackPipeline( + ModConfig config, + VersionMapper versionMapper, + PackRegistry registry, + BiConsumer messenger + ) { + this.config = config; + this.versionMapper = versionMapper; + this.registry = registry; + this.messenger = messenger; + } + + public void bindServer(MinecraftServer server) { + this.activeServer = server; + } + + public void warmCompileAllPacks() { + executor.submit(() -> { + try { + for (PackDefinition pack : registry.discover()) { + runToolchain(pack, 0L); + } + } catch (IOException ignored) { + // Warm compile is best-effort before a world is opened. + } + }); + } + + public void prepareWorldPacks(MinecraftServer server) { + bindServer(server); + try { + for (PackDefinition pack : registry.discover()) { + processPack(server, pack, false); + } + } catch (IOException error) { + messenger.accept(server, "[MCS] Failed to prepare packs: " + error.getMessage()); + } + } + + public void handlePackChange(Path packFolder) { + MinecraftServer server = activeServer; + if (server == null) { + return; + } + executor.submit(() -> { + try { + PackDefinition pack = registry.resolvePack(packFolder); + if (pack == null) { + return; + } + processPack(server, pack, true); + } catch (Exception error) { + messenger.accept(server, "[MCS] Failed to process " + packFolder.getFileName() + ": " + error.getMessage()); + } + }); + } + + private void processPack(MinecraftServer server, PackDefinition pack, boolean reloadAfterDeploy) { + long generation = generations.merge(pack.id(), 1L, Long::sum); + messenger.accept(server, "[MCS] Processing " + pack.id() + "…"); + if (!runToolchain(pack, generation)) { + return; + } + if (!Files.exists(pack.compiledFolder())) { + messenger.accept(server, "[MCS] Compile finished but output folder is missing for " + pack.id()); + return; + } + + try { + if (config.autoReload) { + DatapackDeployer.syncPack(server, pack.compiledFolder(), pack.displayName()); + if (reloadAfterDeploy) { + DatapackDeployer.reload(server); + messenger.accept(server, "[MCS] Reloaded " + pack.id()); + } else { + messenger.accept(server, "[MCS] Prepared " + pack.id()); + } + } else { + messenger.accept(server, "[MCS] Built " + pack.id() + " (autoReload disabled)"); + } + } catch (Exception error) { + messenger.accept(server, "[MCS] Failed to deploy " + pack.id() + ": " + error.getMessage()); + } + } + + private boolean runToolchain(PackDefinition pack, long generation) { + String mcsProfile = versionMapper.resolveMcsProfile(Platform.getMinecraftVersion(), config.minecraftVersion); + McsToolchain toolchain = new McsToolchain(config, mcsProfile); + + List lintDiagnostics = toolchain.lint(pack); + if (!lintDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[MCS]", lintDiagnostics); + } + if (config.blockCompileOnLintErrors && lintDiagnostics.stream().anyMatch(Diagnostic::isError)) { + return false; + } + } + if (generation != 0L && generation != generations.get(pack.id())) { + return false; + } + + List compileDiagnostics = toolchain.compile(pack); + if (!compileDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[MCS]", compileDiagnostics); + } + return false; + } + if (generation != 0L && generation != generations.get(pack.id())) { + return false; + } + + List spyglassDiagnostics = toolchain.validateWithSpyglass(pack, Platform.getMinecraftVersion()); + if (!spyglassDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[Spyglass]", spyglassDiagnostics); + } + if (config.blockReloadOnSpyglassErrors && spyglassDiagnostics.stream().anyMatch(Diagnostic::isError)) { + return false; + } + } + return generation == 0L || generation == generations.get(pack.id()); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackDefinition.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackDefinition.java new file mode 100644 index 0000000..471d8c1 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackDefinition.java @@ -0,0 +1,12 @@ +package dev.spyc0der77.mcspacks.registry; + +import java.nio.file.Path; + +public record PackDefinition( + String id, + Path folder, + Path entryFile, + Path compiledFolder, + String displayName +) { +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java new file mode 100644 index 0000000..8a63235 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java @@ -0,0 +1,93 @@ +package dev.spyc0der77.mcspacks.registry; + +import com.google.gson.Gson; +import dev.spyc0der77.mcspacks.util.McsPaths; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.List; +import java.util.Locale; + +public final class PackRegistry { + private final Path packsRoot; + private final Path compiledRoot; + + public PackRegistry(Path packsRoot, Path compiledRoot) { + this.packsRoot = packsRoot; + this.compiledRoot = compiledRoot; + } + + public List discover() throws IOException { + List packs = new ArrayList<>(); + if (Files.notExists(packsRoot)) { + return packs; + } + try (var stream = Files.list(packsRoot)) { + for (Path folder : stream.toList()) { + if (!Files.isDirectory(folder)) { + continue; + } + String name = folder.getFileName().toString(); + if (name.startsWith("_") || name.startsWith(".")) { + continue; + } + PackDefinition pack = resolvePack(folder); + if (pack != null) { + packs.add(pack); + } + } + } + return packs; + } + + public PackDefinition resolvePack(Path folder) throws IOException { + PackOverrides overrides = readOverrides(folder); + Path entry = folder.resolve(overrides.entryFile == null ? McsPaths.DEFAULT_ENTRY : overrides.entryFile); + if (Files.notExists(entry)) { + return null; + } + String id = folder.getFileName().toString(); + String displayName = overrides.displayName == null + ? titleCase(id) + : overrides.displayName; + return new PackDefinition( + id, + folder, + entry, + compiledRoot.resolve(displayName), + displayName + ); + } + + private PackOverrides readOverrides(Path folder) throws IOException { + Path config = folder.resolve("pack.json"); + if (Files.notExists(config)) { + return new PackOverrides(); + } + return new Gson().fromJson(Files.readString(config), PackOverrides.class); + } + + private static String titleCase(String value) { + String[] parts = value.replace('-', '_').split("_"); + StringBuilder builder = new StringBuilder(); + for (String part : parts) { + if (part.isBlank()) { + continue; + } + if (!builder.isEmpty()) { + builder.append(' '); + } + builder.append(part.substring(0, 1).toUpperCase(Locale.ROOT)); + if (part.length() > 1) { + builder.append(part.substring(1).toLowerCase(Locale.ROOT)); + } + } + return builder.isEmpty() ? value : builder.toString(); + } + + private static final class PackOverrides { + private String displayName; + private String entryFile; + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java new file mode 100644 index 0000000..7fe23b2 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -0,0 +1,148 @@ +package dev.spyc0der77.mcspacks.toolchain; + +import dev.spyc0der77.mcspacks.config.ModConfig; +import dev.spyc0der77.mcspacks.util.McsPaths; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.List; +import java.util.Locale; + +public final class CompilerResolver { + private static String cachedKey; + private static CompilerCommand cachedCommand; + + private CompilerResolver() { + } + + public record CompilerCommand(String executable, List baseArgs, boolean windowsBatch) { + List toProcessCommand(List args) { + List allArgs = new ArrayList<>(baseArgs); + allArgs.addAll(args); + if (windowsBatch && isWindows()) { + return List.of("cmd.exe", "/c", buildCmdInvocation(executable, allArgs)); + } + List command = new ArrayList<>(); + command.add(executable); + command.addAll(allArgs); + return command; + } + } + + public static CompilerCommand resolve(ModConfig config) { + String key = (config.compiler == null ? "auto" : config.compiler) + "|" + config.compilerPath; + if (key.equals(cachedKey) && cachedCommand != null) { + return cachedCommand; + } + CompilerCommand resolved = resolveUncached(config); + cachedKey = key; + cachedCommand = resolved; + return resolved; + } + + private static CompilerCommand resolveUncached(ModConfig config) { + String mode = config.compiler == null ? "auto" : config.compiler.toLowerCase(Locale.ROOT); + if (config.compilerPath != null && !config.compilerPath.isBlank()) { + return fromExplicitPath(config.compilerPath, mode); + } + return switch (mode) { + case "python" -> resolvePython(); + case "mcs" -> new CompilerCommand("mcs", List.of(), false); + default -> resolveAuto(); + }; + } + + private static CompilerCommand fromExplicitPath(String compilerPath, String mode) { + if ("python".equals(mode) || looksLikePython(compilerPath)) { + return new CompilerCommand(compilerPath, List.of("-m", "minecraft_script"), isBatch(compilerPath)); + } + return new CompilerCommand(compilerPath, List.of(), isBatch(compilerPath)); + } + + private static CompilerCommand resolveAuto() { + CompilerCommand mcs = new CompilerCommand("mcs", List.of(), false); + if (canRun(mcs, "lint", "--help")) { + return mcs; + } + CompilerCommand python = resolvePython(); + if (canRun(python, "lint", "--help")) { + return python; + } + try { + Path wrapper = McsPaths.compilerWrapper(); + return new CompilerCommand(wrapper.toString(), List.of(), true); + } catch (IOException error) { + return new CompilerCommand("mcs", List.of(), false); + } + } + + private static CompilerCommand resolvePython() { + if (System.getenv("PYTHON") != null && Files.isExecutable(Path.of(System.getenv("PYTHON")))) { + return pythonCommand(System.getenv("PYTHON")); + } + for (String candidate : List.of("python", "python3", "py")) { + CompilerCommand resolved = "py".equals(candidate) + ? new CompilerCommand(candidate, List.of("-3", "-m", "minecraft_script"), false) + : pythonCommand(candidate); + if (canRun(resolved, "lint", "--help")) { + return resolved; + } + } + for (String version : List.of("313", "312", "311", "310")) { + Path candidate = Path.of("C:\\Python" + version + "\\python.exe"); + if (!Files.isExecutable(candidate)) { + continue; + } + CompilerCommand resolved = pythonCommand(candidate.toString()); + if (canRun(resolved, "lint", "--help")) { + return resolved; + } + } + return pythonCommand("python"); + } + + private static CompilerCommand pythonCommand(String executable) { + return new CompilerCommand(executable, List.of("-m", "minecraft_script"), isBatch(executable)); + } + + private static boolean looksLikePython(String compilerPath) { + String lower = compilerPath.toLowerCase(Locale.ROOT); + return lower.endsWith("python.exe") || lower.endsWith("python") || lower.endsWith("python3"); + } + + private static boolean isBatch(String compilerPath) { + String lower = compilerPath.toLowerCase(Locale.ROOT); + return lower.endsWith(".cmd") || lower.endsWith(".bat"); + } + + private static boolean canRun(CompilerCommand compiler, String... args) { + try { + SubprocessRunner.run(compiler.toProcessCommand(List.of(args)), null, 15); + return true; + } catch (Exception ignored) { + return false; + } + } + + private static boolean isWindows() { + String os = System.getProperty("os.name", ""); + return os.toLowerCase(Locale.ROOT).contains("win"); + } + + private static String buildCmdInvocation(String executable, List args) { + StringBuilder command = new StringBuilder(); + command.append('"').append(executable).append('"'); + for (String arg : args) { + command.append(' ').append(quoteForCmd(arg)); + } + return command.toString(); + } + + private static String quoteForCmd(String arg) { + if (!arg.contains(" ") && !arg.contains("\"")) { + return arg; + } + return "\"" + arg.replace("\"", "\\\"") + "\""; + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/Diagnostic.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/Diagnostic.java new file mode 100644 index 0000000..3ef1b21 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/Diagnostic.java @@ -0,0 +1,7 @@ +package dev.spyc0der77.mcspacks.toolchain; + +public record Diagnostic(String file, int line, int column, String message, String severity) { + public boolean isError() { + return "error".equalsIgnoreCase(severity); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java new file mode 100644 index 0000000..47daba0 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -0,0 +1,129 @@ +package dev.spyc0der77.mcspacks.toolchain; + +import com.google.gson.Gson; +import com.google.gson.reflect.TypeToken; +import dev.spyc0der77.mcspacks.config.ModConfig; +import dev.spyc0der77.mcspacks.registry.PackDefinition; +import dev.spyc0der77.mcspacks.util.McsPaths; +import java.io.IOException; +import java.lang.reflect.Type; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; +import java.util.List; + +public final class McsToolchain { + private static final Gson GSON = new Gson(); + private static final Type DIAGNOSTIC_LIST = new TypeToken>() {}.getType(); + + private final ModConfig config; + private final String mcsProfile; + private final CompilerResolver.CompilerCommand compiler; + + public McsToolchain(ModConfig config, String mcsProfile) { + this.config = config; + this.mcsProfile = mcsProfile; + this.compiler = CompilerResolver.resolve(config); + } + + public List lint(PackDefinition pack) { + if (!config.lintBeforeCompile) { + return List.of(); + } + try { + ProcessResult result = SubprocessRunner.run( + compiler.toProcessCommand(List.of("lint", "--json", pack.entryFile().toString())), + pack.folder(), + 120 + ); + if (result.stdout().isBlank()) { + if (!result.success()) { + return List.of(new Diagnostic(relative(pack, pack.entryFile()), 1, 1, result.stderr().trim(), "error")); + } + return List.of(); + } + List diagnostics = GSON.fromJson(result.stdout(), DIAGNOSTIC_LIST); + return diagnostics == null ? List.of() : diagnostics; + } catch (Exception error) { + return List.of(new Diagnostic(relative(pack, pack.entryFile()), 1, 1, error.getMessage(), "error")); + } + } + + public List compile(PackDefinition pack) { + try { + if (Files.exists(pack.compiledFolder())) { + deleteRecursive(pack.compiledFolder()); + } + } catch (IOException error) { + return List.of(new Diagnostic(pack.id(), 1, 1, error.getMessage(), "error")); + } + List args = new ArrayList<>(); + args.add("compile"); + args.add("--mc-version"); + args.add(mcsProfile); + args.add("--force"); + if (!config.verboseCompile) { + args.add("--no-verbose"); + } + args.add(pack.entryFile().toString()); + args.add(pack.displayName()); + args.add(McsPaths.compiledRoot().toString()); + try { + ProcessResult result = SubprocessRunner.run(compiler.toProcessCommand(args), pack.folder(), 300); + if (!result.success()) { + String message = result.stderr().isBlank() ? result.stdout() : result.stderr(); + return List.of(new Diagnostic(relative(pack, pack.entryFile()), 1, 1, message.trim(), "error")); + } + return List.of(); + } catch (Exception error) { + return List.of(new Diagnostic(relative(pack, pack.entryFile()), 1, 1, error.getMessage(), "error")); + } + } + + public List validateWithSpyglass(PackDefinition pack, String gameVersion) { + if (!config.spyglassValidateAfterCompile || Files.notExists(pack.compiledFolder())) { + return List.of(); + } + try { + Path script = McsPaths.spyglassScript(); + ProcessResult result = SubprocessRunner.run( + List.of( + "node", + script.toString(), + "--json", + "--mc-version", + gameVersion, + pack.compiledFolder().toString() + ), + null, + 300 + ); + if (result.stdout().isBlank()) { + if (!result.success()) { + return List.of(new Diagnostic(pack.id(), 1, 1, result.stderr().trim(), "error")); + } + return List.of(); + } + List diagnostics = GSON.fromJson(result.stdout(), DIAGNOSTIC_LIST); + return diagnostics == null ? List.of() : diagnostics; + } catch (Exception error) { + return List.of(new Diagnostic(pack.id(), 1, 1, error.getMessage(), "warning")); + } + } + + private static String relative(PackDefinition pack, Path file) { + return pack.folder().relativize(file).toString().replace('\\', '/'); + } + + private static void deleteRecursive(Path path) throws IOException { + if (Files.isDirectory(path)) { + try (var stream = Files.list(path)) { + for (Path child : stream.toList()) { + deleteRecursive(child); + } + } + } + Files.deleteIfExists(path); + } + +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/ProcessResult.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/ProcessResult.java new file mode 100644 index 0000000..0f5849e --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/ProcessResult.java @@ -0,0 +1,7 @@ +package dev.spyc0der77.mcspacks.toolchain; + +public record ProcessResult(int exitCode, String stdout, String stderr) { + public boolean success() { + return exitCode == 0; + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java new file mode 100644 index 0000000..52e3b4a --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java @@ -0,0 +1,29 @@ +package dev.spyc0der77.mcspacks.toolchain; + +import java.io.IOException; +import java.nio.charset.StandardCharsets; +import java.nio.file.Path; +import java.util.List; +import java.util.concurrent.TimeUnit; + +public final class SubprocessRunner { + private SubprocessRunner() { + } + + public static ProcessResult run(List command, Path workingDirectory, long timeoutSeconds) throws IOException, InterruptedException { + ProcessBuilder builder = new ProcessBuilder(command); + if (workingDirectory != null) { + builder.directory(workingDirectory.toFile()); + } + builder.redirectErrorStream(false); + Process process = builder.start(); + boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS); + if (!finished) { + process.destroyForcibly(); + return new ProcessResult(-1, "", "Process timed out after " + timeoutSeconds + "s"); + } + String stdout = new String(process.getInputStream().readAllBytes(), StandardCharsets.UTF_8); + String stderr = new String(process.getErrorStream().readAllBytes(), StandardCharsets.UTF_8); + return new ProcessResult(process.exitValue(), stdout, stderr); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java new file mode 100644 index 0000000..fd8783b --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java @@ -0,0 +1,91 @@ +package dev.spyc0der77.mcspacks.util; + +import dev.architectury.platform.Platform; +import java.io.IOException; +import java.io.InputStream; +import java.nio.file.Files; +import java.nio.file.Path; + +public final class McsPaths { + public static final String PACKS_DIR = "mcs_packs"; + public static final String COMPILED_DIR = "_compiled"; + public static final String DEFAULT_ENTRY = "pack.mcs"; + public static final String CONFIG_FILE = "mcs-packs.json"; + + private McsPaths() { + } + + public static Path gameRoot() { + return Platform.getGameFolder(); + } + + public static Path configFile() { + return Platform.getConfigFolder().resolve(CONFIG_FILE); + } + + public static Path packsRoot() { + return gameRoot().resolve(PACKS_DIR); + } + + public static Path compiledRoot() { + return packsRoot().resolve(COMPILED_DIR); + } + + public static Path compilerWrapper() throws IOException { + Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); + Files.createDirectories(scriptsDir); + Path wrapper = scriptsDir.resolve("mcs-compile.cmd"); + try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-compile.cmd")) { + if (stream == null) { + throw new IOException("Bundled MCS compiler wrapper is missing from the mod JAR"); + } + Files.copy(stream, wrapper, java.nio.file.StandardCopyOption.REPLACE_EXISTING); + } + return wrapper; + } + + public static Path spyglassScript() throws IOException { + Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); + Files.createDirectories(scriptsDir); + Path script = scriptsDir.resolve("mcs-spyglass-validate.mjs"); + if (Files.notExists(script)) { + try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.mjs")) { + if (stream == null) { + throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); + } + Files.copy(stream, script); + } + } + return script; + } + + public static void ensureLayout() { + try { + Files.createDirectories(packsRoot()); + Files.createDirectories(compiledRoot()); + Path starter = packsRoot().resolve("starter"); + Files.createDirectories(starter); + Path starterPack = starter.resolve(DEFAULT_ENTRY); + if (Files.notExists(starterPack)) { + try (InputStream stream = McsPaths.class.getResourceAsStream("/starter/pack.mcs")) { + if (stream != null) { + Files.copy(stream, starterPack); + } + } + } + Path readme = packsRoot().resolve("README.txt"); + if (Files.notExists(readme)) { + Files.writeString(readme, """ + MCS Packs + ========= + Create one folder per datapack project under mcs_packs/. + Each folder needs a pack.mcs entry file. + Compiled output is written to mcs_packs/_compiled/. + Mod settings live in config/mcs-packs.json. + """); + } + } catch (IOException error) { + throw new IllegalStateException("Failed to initialize mcs_packs folders", error); + } + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java new file mode 100644 index 0000000..0488ffb --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java @@ -0,0 +1,23 @@ +package dev.spyc0der77.mcspacks.util; + +import dev.spyc0der77.mcspacks.toolchain.Diagnostic; +import java.util.List; +import net.minecraft.network.chat.Component; +import net.minecraft.server.MinecraftServer; + +public final class PlayerFeedback { + private PlayerFeedback() { + } + + public static void broadcast(MinecraftServer server, String message) { + Component component = Component.literal(message); + server.getPlayerList().broadcastSystemMessage(component, false); + } + + public static void diagnostics(MinecraftServer server, String prefix, List diagnostics) { + for (Diagnostic diagnostic : diagnostics) { + String location = diagnostic.file() + ":" + diagnostic.line() + ":" + diagnostic.column(); + broadcast(server, prefix + " " + location + " — " + diagnostic.message()); + } + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java new file mode 100644 index 0000000..ffb9718 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java @@ -0,0 +1,56 @@ +package dev.spyc0der77.mcspacks.version; + +import com.google.gson.Gson; +import com.google.gson.annotations.SerializedName; +import dev.architectury.platform.Platform; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.nio.charset.StandardCharsets; +import java.util.List; +import java.util.Map; + +public final class VersionMapper { + private final List supported; + private final Map profiles; + + private VersionMapper(List supported, Map profiles) { + this.supported = supported; + this.profiles = profiles; + } + + public static VersionMapper load() { + try (InputStream stream = VersionMapper.class.getResourceAsStream("/mcs-versions.json")) { + if (stream == null) { + throw new IllegalStateException("Missing mcs-versions.json resource"); + } + Index index = new Gson().fromJson(new InputStreamReader(stream, StandardCharsets.UTF_8), Index.class); + return new VersionMapper(index.supported, index.profiles); + } catch (Exception error) { + throw new IllegalStateException("Failed to load MCS version index", error); + } + } + + public String resolveMcsProfile(String gameVersion, String configuredVersion) { + String version = configuredVersion; + if (version == null || version.isBlank() || "auto".equalsIgnoreCase(version)) { + version = Platform.getMinecraftVersion(); + } + if (profiles.containsKey(version)) { + return profiles.get(version); + } + if (supported.contains(version)) { + return version; + } + throw new IllegalStateException( + "Minecraft version " + version + " is not supported by MCS. Supported: " + String.join(", ", supported) + ); + } + + private static final class Index { + @SerializedName("supported") + private List supported; + + @SerializedName("profiles") + private Map profiles; + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java new file mode 100644 index 0000000..84f6df4 --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java @@ -0,0 +1,259 @@ +package dev.spyc0der77.mcspacks.watch; + +import dev.spyc0der77.mcspacks.util.McsPaths; +import java.io.IOException; +import java.nio.file.FileSystems; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.StandardWatchEventKinds; +import java.nio.file.WatchEvent; +import java.nio.file.WatchKey; +import java.nio.file.WatchService; +import java.util.Locale; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.Executors; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.ScheduledFuture; +import java.util.concurrent.TimeUnit; +import java.util.function.Consumer; + +public final class PackWatcher { + private final Path packsRoot; + private final Consumer onPackChange; + private final long debounceMs; + private final ScheduledExecutorService scheduler = Executors.newSingleThreadScheduledExecutor(runnable -> { + Thread thread = new Thread(runnable, "mcs-packs-watcher-scheduler"); + thread.setDaemon(true); + return thread; + }); + private final Map> pending = new ConcurrentHashMap<>(); + private final Map lastModified = new ConcurrentHashMap<>(); + private volatile boolean running; + private Thread watchThread; + + public PackWatcher(Path packsRoot, Consumer onPackChange, long debounceMs) { + this.packsRoot = packsRoot; + this.onPackChange = onPackChange; + this.debounceMs = Math.max(100, debounceMs); + } + + public synchronized void start() { + if (running) { + return; + } + running = true; + seedModifiedTimes(); + watchThread = new Thread(this::runLoop, "mcs-packs-watcher"); + watchThread.setDaemon(true); + watchThread.start(); + } + + public void refreshBaselines() { + seedModifiedTimes(); + } + + public synchronized void stop() { + running = false; + if (watchThread != null) { + watchThread.interrupt(); + watchThread = null; + } + pending.values().forEach(future -> future.cancel(false)); + pending.clear(); + } + + private void runLoop() { + try (WatchService watchService = FileSystems.getDefault().newWatchService()) { + registerTree(watchService, packsRoot); + while (running) { + WatchKey key = watchService.poll(1, TimeUnit.SECONDS); + if (key == null) { + pollEntryFiles(); + continue; + } + Path watchedDirectory = (Path) key.watchable(); + for (WatchEvent event : key.pollEvents()) { + if (event.kind() == StandardWatchEventKinds.OVERFLOW) { + continue; + } + Path context = (Path) event.context(); + if (context == null || shouldIgnore(context)) { + continue; + } + Path changedPath = watchedDirectory.resolve(context); + if (event.kind() == StandardWatchEventKinds.ENTRY_CREATE && Files.isDirectory(changedPath)) { + registerTree(watchService, changedPath); + } + Path packFolder = resolvePackFolder(changedPath); + if (packFolder != null) { + touchEntryTimestamp(packFolder); + schedule(packFolder); + } + } + if (!key.reset()) { + registerDirectory(watchService, watchedDirectory); + } + } + } catch (InterruptedException ignored) { + Thread.currentThread().interrupt(); + } catch (IOException error) { + throw new IllegalStateException("Failed to watch mcs_packs", error); + } + } + + private void schedule(Path packFolder) { + pending.compute(packFolder, (path, existing) -> { + if (existing != null) { + existing.cancel(false); + } + return scheduler.schedule(() -> { + pending.remove(path); + onPackChange.accept(path); + }, debounceMs, TimeUnit.MILLISECONDS); + }); + } + + private void seedModifiedTimes() { + try { + if (!Files.exists(packsRoot)) { + return; + } + try (var stream = Files.list(packsRoot)) { + for (Path packFolder : stream.toList()) { + if (!isPackFolder(packFolder)) { + continue; + } + Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); + if (Files.exists(entry)) { + lastModified.put(entry, Files.getLastModifiedTime(entry).toMillis()); + } + } + } + } catch (IOException ignored) { + // Best-effort baseline for polling. + } + } + + private void pollEntryFiles() { + try { + if (!Files.exists(packsRoot)) { + return; + } + try (var stream = Files.list(packsRoot)) { + for (Path packFolder : stream.toList()) { + if (!isPackFolder(packFolder)) { + continue; + } + Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); + if (!Files.exists(entry)) { + continue; + } + long modified = Files.getLastModifiedTime(entry).toMillis(); + Long previous = lastModified.put(entry, modified); + if (previous != null && modified > previous) { + schedule(packFolder); + } + } + } + } catch (IOException ignored) { + // Polling is a fallback when native watch events are missed. + } + } + + private void touchEntryTimestamp(Path packFolder) { + try { + Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); + if (Files.exists(entry)) { + lastModified.put(entry, Files.getLastModifiedTime(entry).toMillis()); + } + } catch (IOException ignored) { + // Ignore timestamp refresh failures. + } + } + + private Path resolvePackFolder(Path changedPath) { + if (!changedPath.startsWith(packsRoot)) { + return null; + } + + Path packFolder; + if (Files.isDirectory(changedPath)) { + packFolder = changedPath; + } else { + String fileName = changedPath.getFileName().toString().toLowerCase(Locale.ROOT); + if (!fileName.endsWith(".mcs")) { + return null; + } + packFolder = changedPath.getParent(); + } + + if (packFolder == null || !isPackFolder(packFolder)) { + return null; + } + + Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); + return Files.exists(entry) ? packFolder : null; + } + + private boolean isPackFolder(Path packFolder) { + if (!Files.isDirectory(packFolder) || !packFolder.startsWith(packsRoot)) { + return false; + } + if (packsRoot.equals(packFolder)) { + return false; + } + Path relative = packsRoot.relativize(packFolder); + if (relative.getNameCount() != 1) { + return false; + } + String name = packFolder.getFileName().toString(); + return !name.startsWith("_") && !name.startsWith("."); + } + + private static boolean shouldIgnore(Path path) { + String name = path.getFileName().toString(); + return name.startsWith(".") || name.endsWith("~") || name.endsWith(".swp") || name.endsWith(".tmp"); + } + + private static void registerTree(WatchService watchService, Path root) throws IOException { + if (!Files.exists(root)) { + Files.createDirectories(root); + } + Files.walk(root).filter(Files::isDirectory).forEach(dir -> registerDirectory(watchService, dir)); + } + + private static void registerDirectory(WatchService watchService, Path directory) { + String name = directory.getFileName() == null ? "" : directory.getFileName().toString(); + if (name.equals("_compiled")) { + return; + } + try { + if (isWindows()) { + directory.register( + watchService, + new WatchEvent.Kind[]{ + StandardWatchEventKinds.ENTRY_CREATE, + StandardWatchEventKinds.ENTRY_MODIFY, + StandardWatchEventKinds.ENTRY_DELETE + }, + com.sun.nio.file.SensitivityWatchEventModifier.HIGH + ); + } else { + directory.register( + watchService, + StandardWatchEventKinds.ENTRY_CREATE, + StandardWatchEventKinds.ENTRY_MODIFY, + StandardWatchEventKinds.ENTRY_DELETE + ); + } + } catch (IOException ignored) { + // Some directories may not be watchable on all platforms. + } + } + + private static boolean isWindows() { + String os = System.getProperty("os.name", ""); + return os.toLowerCase(Locale.ROOT).contains("win"); + } +} diff --git a/mod/common/src/main/resources/mcs-versions.json b/mod/common/src/main/resources/mcs-versions.json new file mode 100644 index 0000000..8bffd83 --- /dev/null +++ b/mod/common/src/main/resources/mcs-versions.json @@ -0,0 +1,21 @@ +{ + "default": "1.21.2", + "supported": [ + "1.21.2", + "1.21.4", + "1.21.5", + "1.21.6", + "1.21.7", + "1.21.8", + "1.21.9", + "1.21.10", + "1.21.11", + "26.1" + ], + "profiles": { + "1.21.7": "1.21.7-8", + "1.21.8": "1.21.7-8", + "1.21.9": "1.21.9-10", + "1.21.10": "1.21.9-10" + } +} diff --git a/mod/common/src/main/resources/scripts/mcs-compile.cmd b/mod/common/src/main/resources/scripts/mcs-compile.cmd new file mode 100644 index 0000000..573d107 --- /dev/null +++ b/mod/common/src/main/resources/scripts/mcs-compile.cmd @@ -0,0 +1,44 @@ +@echo off +setlocal EnableExtensions +for %%P in (313 312 311 310) do if exist "C:\Python%%P\python.exe" call :run_python "C:\Python%%P\python.exe" %* & exit /b %ERRORLEVEL% +where mcs >nul 2>&1 && call :run_mcs %* & exit /b %ERRORLEVEL% +where python >nul 2>&1 && call :run_python python %* & exit /b %ERRORLEVEL% +where py >nul 2>&1 && call :run_py %* & exit /b %ERRORLEVEL% +if defined PYTHON if exist "%PYTHON%" call :run_python "%PYTHON%" %* & exit /b %ERRORLEVEL% +echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 +exit /b 1 + +:run_mcs +set "ARGS=" +:quote_mcs +if "%~1"=="" goto exec_mcs +set "ARGS=%ARGS% "%~1"" +shift +goto quote_mcs +:exec_mcs +mcs %ARGS% +exit /b %ERRORLEVEL% + +:run_python +set "PY=%~1" +shift +set "ARGS=" +:quote_py +if "%~1"=="" goto exec_py +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py +:exec_py +"%PY%" -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% + +:run_py +set "ARGS=" +:quote_py_launcher +if "%~1"=="" goto exec_py_launcher +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py_launcher +:exec_py_launcher +py -3 -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% diff --git a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs new file mode 100644 index 0000000..4a864b6 --- /dev/null +++ b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs @@ -0,0 +1,199 @@ +#!/usr/bin/env node +import { mkdirSync } from 'node:fs' +import { mkdtempSync } from 'node:fs' +import { readFileSync } from 'node:fs' +import { readdirSync, statSync } from 'node:fs' +import { join, relative, resolve } from 'node:path' +import { tmpdir } from 'node:os' +import { pathToFileURL } from 'node:url' + +import { + ErrorSeverity, + FileNode, + Logger, + Project, + VanillaConfig, +} from '@spyglassmc/core' +import { getNodeJsExternals } from '@spyglassmc/core/lib/nodejs.js' +import { initialize as initializeJavaEdition } from '@spyglassmc/java-edition' +import { initialize as initializeMcdoc } from '@spyglassmc/mcdoc' + +function parseArgs(argv) { + const flags = { + json: false, + mcVersion: null, + } + const positional = [] + + for (let index = 0; index < argv.length; index += 1) { + const arg = argv[index] + if (arg === '--json') { + flags.json = true + continue + } + if (arg === '--mc-version') { + flags.mcVersion = argv[index + 1] + index += 1 + continue + } + if (arg.startsWith('--mc-version=')) { + flags.mcVersion = arg.slice('--mc-version='.length) + continue + } + positional.push(arg) + } + + if (positional.length < 1) { + throw new Error('Usage: node mcs-spyglass-validate.mjs [--json] [--mc-version ] ') + } + + return { flags, datapackDir: resolve(positional[0]) } +} + +function toRootUri(path) { + const normalized = resolve(path).replace(/\\/g, '/') + return pathToFileURL(`${normalized}/`).href +} + +function severityName(severity) { + switch (severity) { + case ErrorSeverity.Hint: + return 'hint' + case ErrorSeverity.Information: + return 'information' + case ErrorSeverity.Warning: + return 'warning' + case ErrorSeverity.Error: + return 'error' + default: + return 'error' + } +} + +function walkFiles(rootDir) { + const files = [] + const stack = [rootDir] + while (stack.length > 0) { + const current = stack.pop() + for (const entry of readdirSync(current)) { + const fullPath = join(current, entry) + const stats = statSync(fullPath) + if (stats.isDirectory()) { + stack.push(fullPath) + continue + } + files.push(fullPath) + } + } + return files +} + +function languageIdFor(path) { + if (path.endsWith('.mcfunction')) return 'mcfunction' + if (path.endsWith('.json')) return 'json' + if (path.endsWith('.nbt')) return 'nbt' + return null +} + +async function main() { + const { flags, datapackDir } = parseArgs(process.argv.slice(2)) + const packMetaPath = join(datapackDir, 'pack.mcmeta') + if (!statSync(datapackDir).isDirectory() || !statSync(packMetaPath).isFile()) { + throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`) + } + + const cacheRoot = toRootUri(mkdtempSync(join(tmpdir(), 'mcs-spyglass-'))) + mkdirSync(new URL(cacheRoot), { recursive: true }) + const projectRoot = toRootUri(datapackDir) + const gameVersion = flags.mcVersion + const diagnostics = [] + + const project = new Project({ + cacheRoot, + defaultConfig: { + ...VanillaConfig, + env: { + ...VanillaConfig.env, + ...(gameVersion ? { gameVersion } : {}), + }, + }, + externals: getNodeJsExternals({ cacheRoot }), + initializers: [initializeMcdoc, initializeJavaEdition], + isDebugging: false, + logger: Logger.create('warn'), + projectRoots: [projectRoot], + }) + + project.on('documentErrored', ({ uri, errors }) => { + for (const error of errors) { + const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, '$1')) + const relativePath = relative(datapackDir, filePath).replace(/\\/g, '/') + const start = error.posRange?.start + diagnostics.push({ + file: relativePath, + line: (start?.line ?? 0) + 1, + column: (start?.character ?? 0) + 1, + message: error.message, + severity: severityName(error.severity), + }) + } + }) + + await project.init() + await project.ready() + + for (const filePath of walkFiles(datapackDir)) { + const languageId = languageIdFor(filePath) + if (!languageId) continue + const uri = pathToFileURL(filePath).href + const content = readFileSync(filePath, 'utf8') + await project.onDidOpen(uri, languageId, 1, content) + const managed = await project.ensureClientManagedChecked(uri) + if (!managed) continue + for (const error of FileNode.getErrors(managed.node)) { + diagnostics.push({ + file: relative(datapackDir, filePath).replace(/\\/g, '/'), + line: error.range.start.line + 1, + column: error.range.start.character + 1, + message: error.message, + severity: severityName(error.severity), + }) + } + } + + await project.close() + + const unique = new Map() + for (const diagnostic of diagnostics) { + const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}` + unique.set(key, diagnostic) + } + const result = [...unique.values()].sort((left, right) => { + if (left.file !== right.file) return left.file.localeCompare(right.file) + if (left.line !== right.line) return left.line - right.line + return left.column - right.column + }) + + if (flags.json) { + process.stdout.write(`${JSON.stringify(result)}\n`) + } else { + for (const diagnostic of result) { + process.stdout.write( + `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}: ${diagnostic.message}\n`, + ) + } + } + + const hasErrors = result.some((diagnostic) => diagnostic.severity === 'error') + process.exit(hasErrors ? 1 : 0) +} + +main().catch((error) => { + const message = error instanceof Error ? error.stack ?? error.message : String(error) + if (process.argv.includes('--json')) { + process.stdout.write(`${JSON.stringify([{ file: '', line: 0, column: 0, message, severity: 'error' }])}\n`) + } else { + process.stderr.write(`${message}\n`) + } + process.exit(1) +}) diff --git a/mod/common/src/main/resources/starter/pack.mcs b/mod/common/src/main/resources/starter/pack.mcs new file mode 100644 index 0000000..6846016 --- /dev/null +++ b/mod/common/src/main/resources/starter/pack.mcs @@ -0,0 +1,16 @@ +var has_announced = false; + +function init() { + log("Starter datapack loaded"); +} + +function main() { + if (!has_announced) { + tellraw("@a", text().text("Welcome from Minecraft-Script!").color("gold").bold()); + set has_announced = true; + } +} + +function kill() { + log("Starter datapack disabled"); +} diff --git a/mod/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.class b/mod/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.class new file mode 100644 index 0000000000000000000000000000000000000000..e12651e744981d6a4585fb42e55bdf174f516718 GIT binary patch literal 7266 zcmcIo33yc175;BBa4m0tp}i0!Y=z%!3S>%nUOxKwP_M ztEkx8+8SDIwQ5{w8&Si6)!IdDZSAU6t9G$y_gcH!7Nq~Z?@cljCVXh^eBZox-+kxa zd(MB(`Om%YskaV32H-p~OW=&4wY?z`>j}&VTJbq^8oC0Bm>K9yG}zH-IM88+A`MN^ zu2?8+#aCI0Xn4C7*B}Inx0>6{hOimg(y(IFRx4m@$Q39XE?Y0f1QxvgRi>t<;=Rj^ z1U2Ld6bpiA6Q!3*(kM{i2)Nn_ENuDTZRE6h^Foo3JzpTVs(P&s10_CqP%7ZD zJ3D8r1sWM_o}K>IKe9SM+!d+@ACq-7Y!N41+8& zQ%9i$F$ZLeJZoFG872T_>GP)a+Mwe-IMatIn4_Z@W8|Q-nY3=~ts%ZLr*t%8ypQkZ z3HV2hu;C%WILhsm+30nr3#LM#+YW^rTA~3nY-uDlcvh`gv3f9T)7}!DCM+C{1z04I zZ%13AJFIw(l%b=;Q6a#uV zWrQ8WW71Vg#{nFaa*s$Zp_z{gT=5RgJKo@v>B&m6UzKJ)E)f1ds*-i#ugitM!3s2M zCc$_@HO}zjN!6I?#kW;sh8N#abf%af-Nh$k@$oWQRe4&f@;!NmnY+;~2pgSfthaVr zUi?6AiFyqP{D^)hk;zjDx0BBFgGFdw+H!6t&nJHr4-;b-j~J0)C}`SDNR8*J1ZiEs z$HfNo)R(TnPZ_jUB$$wUQ5`SI@-PK2le)rkAH%q-4|D~+_=Rk3GFca1Vatqf;dafb zAPTs&3i2wsyDFV#PLwylmhk+BhS<@S@o2zGBnFwG(v6xy3{qRvp$;9t!|!ET{=+El zDdn%|q|Tmg-J4?0YOH7xdG`D>BO)%VTZ)f{7I7fXBW+C09}XEw;{SI5{&L3_*yhkA2GWaLjM+k7e}}=VXfez ztblfpj<+yF)`4TRY)2^K6+B+^>=Uth_~!75={ecdVaD6I3AZ8vtC4&ya)pOsAV$ee z6orjV-Jx)>sVmsb!!VCCDx@;DC9aCY!!b*N5?GqPboPN+!#(R{V~3L0nQDPll`a+e zKB3DaZl2r|$ecQ*s_FPCT=7O-6pA8_5XAy@Srk0+NJEY+p$E2gM{R3yG)}B^Q6?*K zjwqLk?4}!-H3H+0%jA>_0;0kzCh}J46_W`4M&3`Qr{h*EYzCOm3)22CBdU3o+XHZb2V;bvE!`19ImYs7G{#{(CFKNnQ!H4kET?Sq(G+s_GdMGdb7$km%POgVx{ zyeeHLlg5BbOd$RG`Guh#)2a69n1d>wY^#-i6^;&+nNL|M`Cb|=DCfhuG&@JsvY%Ny zfj6H#5IgEK5=SYV?nqO=K(_Z`@c@>#NGlGZT;2w-d=GTls!3v1e@$!7{MrGmy`M7z zv-!_?;;k7k@jemau3LGpt~J&vyGwHC_o1-X*r1+9dFD@2gJ#Gv{L7!zOZuTAi3|Hs z{s^@7#)c$*v_sVYTd8;XhQ0l;~XD*kW*Zu)GSnPJDY(vmyVs6rqXQrDTyN_vO_A3 z&S5v$A)UwrrW?d>P%RmQRt9X#{G%Sll=ZpB8EqC25WJtYmb54BbY|$kAM!*)@Zm?S?8ycpll(|V?Zvz zG%Q3l7BNH@v$vT~OF7Fjw4+5??q?(}WNv;8A1BJ~9Cs5w!B!#L>s9VnV;!o{pujT!0VD-_ zv5k$d2t1A{EyiBy+Fq2_7>`Mh8kZYaCh@gC6x9qpezP?tHcsN@igH>fUNvUOJ?54&uj*7{`j%TH3J(d40#8Px>}8ZJJ9$-I(k=(VxDzR93G3P0a!xb6rloG#_ZwJ76M=QBxG z(T}U?!8KS;&s{`cgs~3Y^v*79z>W0Do%G7xxDfa9?bF=By~xwzE7*ir5yb1TgohtW z^3WkhBcyyjpS}w-`k%p1=;<4ou#&EFxrT}76otLWZSZp{B3>VS`!vqR^D0s6sF@^Z zXO3q%hYvj7x%oPui6L2~RORBZ{A9mF_IXOCOX=efeJNg$*_Wb$7bxnJUuE2B<6I_( zebs)KC2Ncq2k^5!D65f-$A(^G+{Z>QG*2HqxqB(>N_Z z;4o6PoBm#$hMy}#UH+Eo?~~tZTvbA@DiuSj{4%A%uSV8D5@)6c+o{2hGz}^SH5hli z2D`w|F|Gy)=AI;Sn(m+oEU5{0l8E87|}yxoElZ zALA&Kdzp(&iO3lcdD0W&RQ=CyABbGiQ^!58i zL2GSs<$xID9}uOg(O#pHczK;mCKYTrWHQ%NTU)6+L_7@DRmgn5}|s^=0.16.0", + "minecraft": "${minecraft_version}", + "java": ">=21", + "architectury": "*", + "fabric-api": "*" + } +} diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle new file mode 100644 index 0000000..ed64645 --- /dev/null +++ b/mod/forge/build.gradle @@ -0,0 +1,54 @@ +plugins { + id 'com.github.johnrengelman.shadow' version '8.1.1' +} + +loom { + forge { + mixinConfig 'mcs_packs.mixins.json' + } +} + +architectury { + platformSetupLoomIde() + forge() +} + +configurations { + common + shadowCommon + compileClasspath.extendsFrom common + runtimeClasspath.extendsFrom common + developmentForge.extendsFrom common +} + +dependencies { + forge "net.minecraftforge:forge:${rootProject.minecraft_version}-${rootProject.forge_version}" + modImplementation "dev.architectury:architectury-forge:${rootProject.architectury_api_version}" + + common(project(path: ':common', configuration: 'namedElements')) { transitive false } + shadowCommon(project(path: ':common', configuration: 'transformProductionForge')) { transitive false } +} + +jar { + archiveClassifier = 'dev' +} + +shadowJar { + configurations = [project.configurations.shadowCommon] + archiveClassifier = 'dev-shadow' +} + +remapJar { + input.set shadowJar.archiveFile + dependsOn shadowJar + archiveClassifier = null +} + +processResources { + inputs.property 'mod_version', project.version + filesMatching('META-INF/mods.toml') { + expand 'mod_version': project.version, + 'minecraft_version': rootProject.minecraft_version, + 'supported_game_versions': rootProject.supportedGameVersions + } +} diff --git a/mod/forge/gradle.properties b/mod/forge/gradle.properties new file mode 100644 index 0000000..8242585 --- /dev/null +++ b/mod/forge/gradle.properties @@ -0,0 +1 @@ +loom.platform=forge diff --git a/mod/forge/src/main/java/dev/spyc0der77/mcspacks/forge/McsPacksForge.java b/mod/forge/src/main/java/dev/spyc0der77/mcspacks/forge/McsPacksForge.java new file mode 100644 index 0000000..169c6eb --- /dev/null +++ b/mod/forge/src/main/java/dev/spyc0der77/mcspacks/forge/McsPacksForge.java @@ -0,0 +1,13 @@ +package dev.spyc0der77.mcspacks.forge; + +import dev.spyc0der77.mcspacks.McsPacks; +import net.minecraftforge.fml.common.Mod; + +@Mod(McsPacksForge.MOD_ID) +public final class McsPacksForge { + public static final String MOD_ID = "mcs_packs"; + + public McsPacksForge() { + McsPacks.init(); + } +} diff --git a/mod/forge/src/main/resources/META-INF/mods.toml b/mod/forge/src/main/resources/META-INF/mods.toml new file mode 100644 index 0000000..58f9c16 --- /dev/null +++ b/mod/forge/src/main/resources/META-INF/mods.toml @@ -0,0 +1,32 @@ +modLoader = "javafml" +loaderVersion = "[4,)" +license = "MIT" +issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" + +[[mods]] +modId = "mcs_packs" +version = "${mod_version}" +displayName = "MCS Packs" +description = "Compile and hot-reload Minecraft Script datapacks from mcs_packs/" +authors = "SpyC0der77" + +[[dependencies.mcs_packs]] +modId = "forge" +mandatory = true +versionRange = "[${minecraft_version},)" +ordering = "NONE" +side = "BOTH" + +[[dependencies.mcs_packs]] +modId = "minecraft" +mandatory = true +versionRange = "[${minecraft_version},)" +ordering = "NONE" +side = "BOTH" + +[[dependencies.mcs_packs]] +modId = "architectury" +mandatory = true +versionRange = "[0,)" +ordering = "AFTER" +side = "BOTH" diff --git a/mod/forge/src/main/resources/mcs_packs.mixins.json b/mod/forge/src/main/resources/mcs_packs.mixins.json new file mode 100644 index 0000000..1edac23 --- /dev/null +++ b/mod/forge/src/main/resources/mcs_packs.mixins.json @@ -0,0 +1,9 @@ +{ + "required": true, + "minVersion": "0.8", + "package": "dev.spyc0der77.mcspacks.mixin", + "compatibilityLevel": "JAVA_21", + "mixins": [], + "client": [], + "server": [] +} diff --git a/mod/gradle.properties b/mod/gradle.properties new file mode 100644 index 0000000..a404202 --- /dev/null +++ b/mod/gradle.properties @@ -0,0 +1,25 @@ +org.gradle.jvmargs=-Xmx4G +org.gradle.parallel=true +org.gradle.daemon=false + +mcs_profile=1.21.11 +minecraft_version=1.21.11 +mcs_minecraft_profile=1.21.11 +supported_game_versions=1.21.11 + +architectury_plugin_version=3.4-SNAPSHOT +architectury_loom_version=1.13-SNAPSHOT +loom.ignoreDependencyLoomVersionValidation=true + +mod_version=0.1.0 +maven_group=dev.spyc0der77 +archives_base_name=mcs-packs +mod_id=mcs_packs + +fabric_loader_version=0.18.4 +fabric_api_version=0.140.2+1.21.11 +forge_version=61.1.0 +neoforge_version=21.11.42 +architectury_api_version=19.0.1 + +enabled_platforms=fabric diff --git a/mod/gradle/wrapper/gradle-wrapper.jar b/mod/gradle/wrapper/gradle-wrapper.jar new file mode 100644 index 0000000000000000000000000000000000000000..a4b76b9530d66f5e68d973ea569d8e19de379189 GIT binary patch literal 43583 zcma&N1CXTcmMvW9vTb(Rwr$&4wr$(C?dmSu>@vG-+vuvg^_??!{yS%8zW-#zn-LkA z5&1^$^{lnmUON?}LBF8_K|(?T0Ra(xUH{($5eN!MR#ZihR#HxkUPe+_R8Cn`RRs(P z_^*#_XlXmGv7!4;*Y%p4nw?{bNp@UZHv1?Um8r6)Fei3p@ClJn0ECfg1hkeuUU@Or zDaPa;U3fE=3L}DooL;8f;P0ipPt0Z~9P0)lbStMS)ag54=uL9ia-Lm3nh|@(Y?B`; zx_#arJIpXH!U{fbCbI^17}6Ri*H<>OLR%c|^mh8+)*h~K8Z!9)DPf zR2h?lbDZQ`p9P;&DQ4F0sur@TMa!Y}S8irn(%d-gi0*WxxCSk*A?3lGh=gcYN?FGl z7D=Js!i~0=u3rox^eO3i@$0=n{K1lPNU zwmfjRVmLOCRfe=seV&P*1Iq=^i`502keY8Uy-WNPwVNNtJFx?IwAyRPZo2Wo1+S(xF37LJZ~%i)kpFQ3Fw=mXfd@>%+)RpYQLnr}B~~zoof(JVm^^&f zxKV^+3D3$A1G;qh4gPVjhrC8e(VYUHv#dy^)(RoUFM?o%W-EHxufuWf(l*@-l+7vt z=l`qmR56K~F|v<^Pd*p~1_y^P0P^aPC##d8+HqX4IR1gu+7w#~TBFphJxF)T$2WEa zxa?H&6=Qe7d(#tha?_1uQys2KtHQ{)Qco)qwGjrdNL7thd^G5i8Os)CHqc>iOidS} z%nFEDdm=GXBw=yXe1W-ShHHFb?Cc70+$W~z_+}nAoHFYI1MV1wZegw*0y^tC*s%3h zhD3tN8b=Gv&rj}!SUM6|ajSPp*58KR7MPpI{oAJCtY~JECm)*m_x>AZEu>DFgUcby z1Qaw8lU4jZpQ_$;*7RME+gq1KySGG#Wql>aL~k9tLrSO()LWn*q&YxHEuzmwd1?aAtI zBJ>P=&$=l1efe1CDU;`Fd+_;&wI07?V0aAIgc(!{a z0Jg6Y=inXc3^n!U0Atk`iCFIQooHqcWhO(qrieUOW8X(x?(RD}iYDLMjSwffH2~tB z)oDgNBLB^AJBM1M^c5HdRx6fBfka`(LD-qrlh5jqH~);#nw|iyp)()xVYak3;Ybik z0j`(+69aK*B>)e_p%=wu8XC&9e{AO4c~O1U`5X9}?0mrd*m$_EUek{R?DNSh(=br# z#Q61gBzEpmy`$pA*6!87 zSDD+=@fTY7<4A?GLqpA?Pb2z$pbCc4B4zL{BeZ?F-8`s$?>*lXXtn*NC61>|*w7J* z$?!iB{6R-0=KFmyp1nnEmLsA-H0a6l+1uaH^g%c(p{iT&YFrbQ$&PRb8Up#X3@Zsk zD^^&LK~111%cqlP%!_gFNa^dTYT?rhkGl}5=fL{a`UViaXWI$k-UcHJwmaH1s=S$4 z%4)PdWJX;hh5UoK?6aWoyLxX&NhNRqKam7tcOkLh{%j3K^4Mgx1@i|Pi&}<^5>hs5 zm8?uOS>%)NzT(%PjVPGa?X%`N2TQCKbeH2l;cTnHiHppPSJ<7y-yEIiC!P*ikl&!B z%+?>VttCOQM@ShFguHVjxX^?mHX^hSaO_;pnyh^v9EumqSZTi+#f&_Vaija0Q-e*| z7ulQj6Fs*bbmsWp{`auM04gGwsYYdNNZcg|ph0OgD>7O}Asn7^Z=eI>`$2*v78;sj-}oMoEj&@)9+ycEOo92xSyY344^ z11Hb8^kdOvbf^GNAK++bYioknrpdN>+u8R?JxG=!2Kd9r=YWCOJYXYuM0cOq^FhEd zBg2puKy__7VT3-r*dG4c62Wgxi52EMCQ`bKgf*#*ou(D4-ZN$+mg&7$u!! z-^+Z%;-3IDwqZ|K=ah85OLwkO zKxNBh+4QHh)u9D?MFtpbl)us}9+V!D%w9jfAMYEb>%$A;u)rrI zuBudh;5PN}_6J_}l55P3l_)&RMlH{m!)ai-i$g)&*M`eN$XQMw{v^r@-125^RRCF0 z^2>|DxhQw(mtNEI2Kj(;KblC7x=JlK$@78`O~>V!`|1Lm-^JR$-5pUANAnb(5}B}JGjBsliK4& zk6y(;$e&h)lh2)L=bvZKbvh@>vLlreBdH8No2>$#%_Wp1U0N7Ank!6$dFSi#xzh|( zRi{Uw%-4W!{IXZ)fWx@XX6;&(m_F%c6~X8hx=BN1&q}*( zoaNjWabE{oUPb!Bt$eyd#$5j9rItB-h*5JiNi(v^e|XKAj*8(k<5-2$&ZBR5fF|JA z9&m4fbzNQnAU}r8ab>fFV%J0z5awe#UZ|bz?Ur)U9bCIKWEzi2%A+5CLqh?}K4JHi z4vtM;+uPsVz{Lfr;78W78gC;z*yTch~4YkLr&m-7%-xc ztw6Mh2d>_iO*$Rd8(-Cr1_V8EO1f*^@wRoSozS) zy1UoC@pruAaC8Z_7~_w4Q6n*&B0AjOmMWa;sIav&gu z|J5&|{=a@vR!~k-OjKEgPFCzcJ>#A1uL&7xTDn;{XBdeM}V=l3B8fE1--DHjSaxoSjNKEM9|U9#m2<3>n{Iuo`r3UZp;>GkT2YBNAh|b z^jTq-hJp(ebZh#Lk8hVBP%qXwv-@vbvoREX$TqRGTgEi$%_F9tZES@z8Bx}$#5eeG zk^UsLBH{bc2VBW)*EdS({yw=?qmevwi?BL6*=12k9zM5gJv1>y#ML4!)iiPzVaH9% zgSImetD@dam~e>{LvVh!phhzpW+iFvWpGT#CVE5TQ40n%F|p(sP5mXxna+Ev7PDwA zamaV4m*^~*xV+&p;W749xhb_X=$|LD;FHuB&JL5?*Y2-oIT(wYY2;73<^#46S~Gx| z^cez%V7x$81}UWqS13Gz80379Rj;6~WdiXWOSsdmzY39L;Hg3MH43o*y8ibNBBH`(av4|u;YPq%{R;IuYow<+GEsf@R?=@tT@!}?#>zIIn0CoyV!hq3mw zHj>OOjfJM3F{RG#6ujzo?y32m^tgSXf@v=J$ELdJ+=5j|=F-~hP$G&}tDZsZE?5rX ztGj`!S>)CFmdkccxM9eGIcGnS2AfK#gXwj%esuIBNJQP1WV~b~+D7PJTmWGTSDrR` zEAu4B8l>NPuhsk5a`rReSya2nfV1EK01+G!x8aBdTs3Io$u5!6n6KX%uv@DxAp3F@{4UYg4SWJtQ-W~0MDb|j-$lwVn znAm*Pl!?Ps&3wO=R115RWKb*JKoexo*)uhhHBncEDMSVa_PyA>k{Zm2(wMQ(5NM3# z)jkza|GoWEQo4^s*wE(gHz?Xsg4`}HUAcs42cM1-qq_=+=!Gk^y710j=66(cSWqUe zklbm8+zB_syQv5A2rj!Vbw8;|$@C!vfNmNV!yJIWDQ>{+2x zKjuFX`~~HKG~^6h5FntRpnnHt=D&rq0>IJ9#F0eM)Y-)GpRjiN7gkA8wvnG#K=q{q z9dBn8_~wm4J<3J_vl|9H{7q6u2A!cW{bp#r*-f{gOV^e=8S{nc1DxMHFwuM$;aVI^ zz6A*}m8N-&x8;aunp1w7_vtB*pa+OYBw=TMc6QK=mbA-|Cf* zvyh8D4LRJImooUaSb7t*fVfih<97Gf@VE0|z>NcBwBQze);Rh!k3K_sfunToZY;f2 z^HmC4KjHRVg+eKYj;PRN^|E0>Gj_zagfRbrki68I^#~6-HaHg3BUW%+clM1xQEdPYt_g<2K+z!$>*$9nQ>; zf9Bei{?zY^-e{q_*|W#2rJG`2fy@{%6u0i_VEWTq$*(ZN37|8lFFFt)nCG({r!q#9 z5VK_kkSJ3?zOH)OezMT{!YkCuSSn!K#-Rhl$uUM(bq*jY? zi1xbMVthJ`E>d>(f3)~fozjg^@eheMF6<)I`oeJYx4*+M&%c9VArn(OM-wp%M<-`x z7sLP1&3^%Nld9Dhm@$3f2}87!quhI@nwd@3~fZl_3LYW-B?Ia>ui`ELg z&Qfe!7m6ze=mZ`Ia9$z|ARSw|IdMpooY4YiPN8K z4B(ts3p%2i(Td=tgEHX z0UQ_>URBtG+-?0E;E7Ld^dyZ;jjw0}XZ(}-QzC6+NN=40oDb2^v!L1g9xRvE#@IBR zO!b-2N7wVfLV;mhEaXQ9XAU+>=XVA6f&T4Z-@AX!leJ8obP^P^wP0aICND?~w&NykJ#54x3_@r7IDMdRNy4Hh;h*!u(Ol(#0bJdwEo$5437-UBjQ+j=Ic>Q2z` zJNDf0yO6@mr6y1#n3)s(W|$iE_i8r@Gd@!DWDqZ7J&~gAm1#~maIGJ1sls^gxL9LLG_NhU!pTGty!TbhzQnu)I*S^54U6Yu%ZeCg`R>Q zhBv$n5j0v%O_j{QYWG!R9W?5_b&67KB$t}&e2LdMvd(PxN6Ir!H4>PNlerpBL>Zvyy!yw z-SOo8caEpDt(}|gKPBd$qND5#a5nju^O>V&;f890?yEOfkSG^HQVmEbM3Ugzu+UtH zC(INPDdraBN?P%kE;*Ae%Wto&sgw(crfZ#Qy(<4nk;S|hD3j{IQRI6Yq|f^basLY; z-HB&Je%Gg}Jt@={_C{L$!RM;$$|iD6vu#3w?v?*;&()uB|I-XqEKqZPS!reW9JkLewLb!70T7n`i!gNtb1%vN- zySZj{8-1>6E%H&=V}LM#xmt`J3XQoaD|@XygXjdZ1+P77-=;=eYpoEQ01B@L*a(uW zrZeZz?HJsw_4g0vhUgkg@VF8<-X$B8pOqCuWAl28uB|@r`19DTUQQsb^pfqB6QtiT z*`_UZ`fT}vtUY#%sq2{rchyfu*pCg;uec2$-$N_xgjZcoumE5vSI{+s@iLWoz^Mf; zuI8kDP{!XY6OP~q5}%1&L}CtfH^N<3o4L@J@zg1-mt{9L`s^z$Vgb|mr{@WiwAqKg zp#t-lhrU>F8o0s1q_9y`gQNf~Vb!F%70f}$>i7o4ho$`uciNf=xgJ>&!gSt0g;M>*x4-`U)ysFW&Vs^Vk6m%?iuWU+o&m(2Jm26Y(3%TL; zA7T)BP{WS!&xmxNw%J=$MPfn(9*^*TV;$JwRy8Zl*yUZi8jWYF>==j~&S|Xinsb%c z2?B+kpet*muEW7@AzjBA^wAJBY8i|#C{WtO_or&Nj2{=6JTTX05}|H>N2B|Wf!*3_ z7hW*j6p3TvpghEc6-wufFiY!%-GvOx*bZrhZu+7?iSrZL5q9}igiF^*R3%DE4aCHZ zqu>xS8LkW+Auv%z-<1Xs92u23R$nk@Pk}MU5!gT|c7vGlEA%G^2th&Q*zfg%-D^=f z&J_}jskj|Q;73NP4<4k*Y%pXPU2Thoqr+5uH1yEYM|VtBPW6lXaetokD0u z9qVek6Q&wk)tFbQ8(^HGf3Wp16gKmr>G;#G(HRBx?F`9AIRboK+;OfHaLJ(P>IP0w zyTbTkx_THEOs%Q&aPrxbZrJlio+hCC_HK<4%f3ZoSAyG7Dn`=X=&h@m*|UYO-4Hq0 z-Bq&+Ie!S##4A6OGoC~>ZW`Y5J)*ouaFl_e9GA*VSL!O_@xGiBw!AF}1{tB)z(w%c zS1Hmrb9OC8>0a_$BzeiN?rkPLc9%&;1CZW*4}CDDNr2gcl_3z+WC15&H1Zc2{o~i) z)LLW=WQ{?ricmC`G1GfJ0Yp4Dy~Ba;j6ZV4r{8xRs`13{dD!xXmr^Aga|C=iSmor% z8hi|pTXH)5Yf&v~exp3o+sY4B^^b*eYkkCYl*T{*=-0HniSA_1F53eCb{x~1k3*`W zr~};p1A`k{1DV9=UPnLDgz{aJH=-LQo<5%+Em!DNN252xwIf*wF_zS^!(XSm(9eoj z=*dXG&n0>)_)N5oc6v!>-bd(2ragD8O=M|wGW z!xJQS<)u70m&6OmrF0WSsr@I%T*c#Qo#Ha4d3COcX+9}hM5!7JIGF>7<~C(Ear^Sn zm^ZFkV6~Ula6+8S?oOROOA6$C&q&dp`>oR-2Ym3(HT@O7Sd5c~+kjrmM)YmgPH*tL zX+znN>`tv;5eOfX?h{AuX^LK~V#gPCu=)Tigtq9&?7Xh$qN|%A$?V*v=&-2F$zTUv z`C#WyIrChS5|Kgm_GeudCFf;)!WH7FI60j^0o#65o6`w*S7R@)88n$1nrgU(oU0M9 zx+EuMkC>(4j1;m6NoGqEkpJYJ?vc|B zOlwT3t&UgL!pX_P*6g36`ZXQ; z9~Cv}ANFnJGp(;ZhS(@FT;3e)0)Kp;h^x;$*xZn*k0U6-&FwI=uOGaODdrsp-!K$Ac32^c{+FhI-HkYd5v=`PGsg%6I`4d9Jy)uW0y%) zm&j^9WBAp*P8#kGJUhB!L?a%h$hJgQrx!6KCB_TRo%9{t0J7KW8!o1B!NC)VGLM5! zpZy5Jc{`r{1e(jd%jsG7k%I+m#CGS*BPA65ZVW~fLYw0dA-H_}O zrkGFL&P1PG9p2(%QiEWm6x;U-U&I#;Em$nx-_I^wtgw3xUPVVu zqSuKnx&dIT-XT+T10p;yjo1Y)z(x1fb8Dzfn8e yu?e%!_ptzGB|8GrCfu%p?(_ zQccdaaVK$5bz;*rnyK{_SQYM>;aES6Qs^lj9lEs6_J+%nIiuQC*fN;z8md>r_~Mfl zU%p5Dt_YT>gQqfr@`cR!$NWr~+`CZb%dn;WtzrAOI>P_JtsB76PYe*<%H(y>qx-`Kq!X_; z<{RpAqYhE=L1r*M)gNF3B8r(<%8mo*SR2hu zccLRZwGARt)Hlo1euqTyM>^!HK*!Q2P;4UYrysje@;(<|$&%vQekbn|0Ruu_Io(w4#%p6ld2Yp7tlA`Y$cciThP zKzNGIMPXX%&Ud0uQh!uQZz|FB`4KGD?3!ND?wQt6!n*f4EmCoJUh&b?;B{|lxs#F- z31~HQ`SF4x$&v00@(P+j1pAaj5!s`)b2RDBp*PB=2IB>oBF!*6vwr7Dp%zpAx*dPr zb@Zjq^XjN?O4QcZ*O+8>)|HlrR>oD*?WQl5ri3R#2?*W6iJ>>kH%KnnME&TT@ZzrHS$Q%LC?n|e>V+D+8D zYc4)QddFz7I8#}y#Wj6>4P%34dZH~OUDb?uP%-E zwjXM(?Sg~1!|wI(RVuxbu)-rH+O=igSho_pDCw(c6b=P zKk4ATlB?bj9+HHlh<_!&z0rx13K3ZrAR8W)!@Y}o`?a*JJsD+twZIv`W)@Y?Amu_u zz``@-e2X}27$i(2=9rvIu5uTUOVhzwu%mNazS|lZb&PT;XE2|B&W1>=B58#*!~D&) zfVmJGg8UdP*fx(>Cj^?yS^zH#o-$Q-*$SnK(ZVFkw+er=>N^7!)FtP3y~Xxnu^nzY zikgB>Nj0%;WOltWIob|}%lo?_C7<``a5hEkx&1ku$|)i>Rh6@3h*`slY=9U}(Ql_< zaNG*J8vb&@zpdhAvv`?{=zDedJ23TD&Zg__snRAH4eh~^oawdYi6A3w8<Ozh@Kw)#bdktM^GVb zrG08?0bG?|NG+w^&JvD*7LAbjED{_Zkc`3H!My>0u5Q}m!+6VokMLXxl`Mkd=g&Xx z-a>m*#G3SLlhbKB!)tnzfWOBV;u;ftU}S!NdD5+YtOjLg?X}dl>7m^gOpihrf1;PY zvll&>dIuUGs{Qnd- zwIR3oIrct8Va^Tm0t#(bJD7c$Z7DO9*7NnRZorrSm`b`cxz>OIC;jSE3DO8`hX955ui`s%||YQtt2 z5DNA&pG-V+4oI2s*x^>-$6J?p=I>C|9wZF8z;VjR??Icg?1w2v5Me+FgAeGGa8(3S z4vg*$>zC-WIVZtJ7}o9{D-7d>zCe|z#<9>CFve-OPAYsneTb^JH!Enaza#j}^mXy1 z+ULn^10+rWLF6j2>Ya@@Kq?26>AqK{A_| zQKb*~F1>sE*=d?A?W7N2j?L09_7n+HGi{VY;MoTGr_)G9)ot$p!-UY5zZ2Xtbm=t z@dpPSGwgH=QtIcEulQNI>S-#ifbnO5EWkI;$A|pxJd885oM+ zGZ0_0gDvG8q2xebj+fbCHYfAXuZStH2j~|d^sBAzo46(K8n59+T6rzBwK)^rfPT+B zyIFw)9YC-V^rhtK`!3jrhmW-sTmM+tPH+;nwjL#-SjQPUZ53L@A>y*rt(#M(qsiB2 zx6B)dI}6Wlsw%bJ8h|(lhkJVogQZA&n{?Vgs6gNSXzuZpEyu*xySy8ro07QZ7Vk1!3tJphN_5V7qOiyK8p z#@jcDD8nmtYi1^l8ml;AF<#IPK?!pqf9D4moYk>d99Im}Jtwj6c#+A;f)CQ*f-hZ< z=p_T86jog%!p)D&5g9taSwYi&eP z#JuEK%+NULWus;0w32-SYFku#i}d~+{Pkho&^{;RxzP&0!RCm3-9K6`>KZpnzS6?L z^H^V*s!8<>x8bomvD%rh>Zp3>Db%kyin;qtl+jAv8Oo~1g~mqGAC&Qi_wy|xEt2iz zWAJEfTV%cl2Cs<1L&DLRVVH05EDq`pH7Oh7sR`NNkL%wi}8n>IXcO40hp+J+sC!W?!krJf!GJNE8uj zg-y~Ns-<~D?yqbzVRB}G>0A^f0!^N7l=$m0OdZuqAOQqLc zX?AEGr1Ht+inZ-Qiwnl@Z0qukd__a!C*CKuGdy5#nD7VUBM^6OCpxCa2A(X;e0&V4 zM&WR8+wErQ7UIc6LY~Q9x%Sn*Tn>>P`^t&idaOEnOd(Ufw#>NoR^1QdhJ8s`h^|R_ zXX`c5*O~Xdvh%q;7L!_!ohf$NfEBmCde|#uVZvEo>OfEq%+Ns7&_f$OR9xsihRpBb z+cjk8LyDm@U{YN>+r46?nn{7Gh(;WhFw6GAxtcKD+YWV?uge>;+q#Xx4!GpRkVZYu zzsF}1)7$?%s9g9CH=Zs+B%M_)+~*j3L0&Q9u7!|+T`^O{xE6qvAP?XWv9_MrZKdo& z%IyU)$Q95AB4!#hT!_dA>4e@zjOBD*Y=XjtMm)V|+IXzjuM;(l+8aA5#Kaz_$rR6! zj>#&^DidYD$nUY(D$mH`9eb|dtV0b{S>H6FBfq>t5`;OxA4Nn{J(+XihF(stSche7$es&~N$epi&PDM_N`As;*9D^L==2Q7Z2zD+CiU(|+-kL*VG+&9!Yb3LgPy?A zm7Z&^qRG_JIxK7-FBzZI3Q<;{`DIxtc48k> zc|0dmX;Z=W$+)qE)~`yn6MdoJ4co;%!`ddy+FV538Y)j(vg}5*k(WK)KWZ3WaOG!8 z!syGn=s{H$odtpqFrT#JGM*utN7B((abXnpDM6w56nhw}OY}0TiTG1#f*VFZr+^-g zbP10`$LPq_;PvrA1XXlyx2uM^mrjTzX}w{yuLo-cOClE8MMk47T25G8M!9Z5ypOSV zAJUBGEg5L2fY)ZGJb^E34R2zJ?}Vf>{~gB!8=5Z) z9y$>5c)=;o0HeHHSuE4U)#vG&KF|I%-cF6f$~pdYJWk_dD}iOA>iA$O$+4%@>JU08 zS`ep)$XLPJ+n0_i@PkF#ri6T8?ZeAot$6JIYHm&P6EB=BiaNY|aA$W0I+nz*zkz_z zkEru!tj!QUffq%)8y0y`T&`fuus-1p>=^hnBiBqD^hXrPs`PY9tU3m0np~rISY09> z`P3s=-kt_cYcxWd{de@}TwSqg*xVhp;E9zCsnXo6z z?f&Sv^U7n4`xr=mXle94HzOdN!2kB~4=%)u&N!+2;z6UYKUDqi-s6AZ!haB;@&B`? z_TRX0%@suz^TRdCb?!vNJYPY8L_}&07uySH9%W^Tc&1pia6y1q#?*Drf}GjGbPjBS zbOPcUY#*$3sL2x4v_i*Y=N7E$mR}J%|GUI(>WEr+28+V z%v5{#e!UF*6~G&%;l*q*$V?&r$Pp^sE^i-0$+RH3ERUUdQ0>rAq2(2QAbG}$y{de( z>{qD~GGuOk559Y@%$?N^1ApVL_a704>8OD%8Y%8B;FCt%AoPu8*D1 zLB5X>b}Syz81pn;xnB}%0FnwazlWfUV)Z-~rZg6~b z6!9J$EcE&sEbzcy?CI~=boWA&eeIa%z(7SE^qgVLz??1Vbc1*aRvc%Mri)AJaAG!p z$X!_9Ds;Zz)f+;%s&dRcJt2==P{^j3bf0M=nJd&xwUGlUFn?H=2W(*2I2Gdu zv!gYCwM10aeus)`RIZSrCK=&oKaO_Ry~D1B5!y0R=%!i2*KfXGYX&gNv_u+n9wiR5 z*e$Zjju&ODRW3phN925%S(jL+bCHv6rZtc?!*`1TyYXT6%Ju=|X;6D@lq$8T zW{Y|e39ioPez(pBH%k)HzFITXHvnD6hw^lIoUMA;qAJ^CU?top1fo@s7xT13Fvn1H z6JWa-6+FJF#x>~+A;D~;VDs26>^oH0EI`IYT2iagy23?nyJ==i{g4%HrAf1-*v zK1)~@&(KkwR7TL}L(A@C_S0G;-GMDy=MJn2$FP5s<%wC)4jC5PXoxrQBFZ_k0P{{s@sz+gX`-!=T8rcB(=7vW}^K6oLWMmp(rwDh}b zwaGGd>yEy6fHv%jM$yJXo5oMAQ>c9j`**}F?MCry;T@47@r?&sKHgVe$MCqk#Z_3S z1GZI~nOEN*P~+UaFGnj{{Jo@16`(qVNtbU>O0Hf57-P>x8Jikp=`s8xWs^dAJ9lCQ z)GFm+=OV%AMVqVATtN@|vp61VVAHRn87}%PC^RAzJ%JngmZTasWBAWsoAqBU+8L8u z4A&Pe?fmTm0?mK-BL9t+{y7o(7jm+RpOhL9KnY#E&qu^}B6=K_dB}*VlSEiC9fn)+V=J;OnN)Ta5v66ic1rG+dGAJ1 z1%Zb_+!$=tQ~lxQrzv3x#CPb?CekEkA}0MYSgx$Jdd}q8+R=ma$|&1a#)TQ=l$1tQ z=tL9&_^vJ)Pk}EDO-va`UCT1m#Uty1{v^A3P~83_#v^ozH}6*9mIjIr;t3Uv%@VeW zGL6(CwCUp)Jq%G0bIG%?{_*Y#5IHf*5M@wPo6A{$Um++Co$wLC=J1aoG93&T7Ho}P z=mGEPP7GbvoG!uD$k(H3A$Z))+i{Hy?QHdk>3xSBXR0j!11O^mEe9RHmw!pvzv?Ua~2_l2Yh~_!s1qS`|0~0)YsbHSz8!mG)WiJE| z2f($6TQtt6L_f~ApQYQKSb=`053LgrQq7G@98#igV>y#i==-nEjQ!XNu9 z~;mE+gtj4IDDNQJ~JVk5Ux6&LCSFL!y=>79kE9=V}J7tD==Ga+IW zX)r7>VZ9dY=V&}DR))xUoV!u(Z|%3ciQi_2jl}3=$Agc(`RPb z8kEBpvY>1FGQ9W$n>Cq=DIpski};nE)`p3IUw1Oz0|wxll^)4dq3;CCY@RyJgFgc# zKouFh!`?Xuo{IMz^xi-h=StCis_M7yq$u) z?XHvw*HP0VgR+KR6wI)jEMX|ssqYvSf*_3W8zVTQzD?3>H!#>InzpSO)@SC8q*ii- z%%h}_#0{4JG;Jm`4zg};BPTGkYamx$Xo#O~lBirRY)q=5M45n{GCfV7h9qwyu1NxOMoP4)jjZMxmT|IQQh0U7C$EbnMN<3)Kk?fFHYq$d|ICu>KbY_hO zTZM+uKHe(cIZfEqyzyYSUBZa8;Fcut-GN!HSA9ius`ltNebF46ZX_BbZNU}}ZOm{M2&nANL9@0qvih15(|`S~z}m&h!u4x~(%MAO$jHRWNfuxWF#B)E&g3ghSQ9|> z(MFaLQj)NE0lowyjvg8z0#m6FIuKE9lDO~Glg}nSb7`~^&#(Lw{}GVOS>U)m8bF}x zVjbXljBm34Cs-yM6TVusr+3kYFjr28STT3g056y3cH5Tmge~ASxBj z%|yb>$eF;WgrcOZf569sDZOVwoo%8>XO>XQOX1OyN9I-SQgrm;U;+#3OI(zrWyow3 zk==|{lt2xrQ%FIXOTejR>;wv(Pb8u8}BUpx?yd(Abh6? zsoO3VYWkeLnF43&@*#MQ9-i-d0t*xN-UEyNKeyNMHw|A(k(_6QKO=nKMCxD(W(Yop zsRQ)QeL4X3Lxp^L%wzi2-WVSsf61dqliPUM7srDB?Wm6Lzn0&{*}|IsKQW;02(Y&| zaTKv|`U(pSzuvR6Rduu$wzK_W-Y-7>7s?G$)U}&uK;<>vU}^^ns@Z!p+9?St1s)dG zK%y6xkPyyS1$~&6v{kl?Md6gwM|>mt6Upm>oa8RLD^8T{0?HC!Z>;(Bob7el(DV6x zi`I)$&E&ngwFS@bi4^xFLAn`=fzTC;aimE^!cMI2n@Vo%Ae-ne`RF((&5y6xsjjAZ zVguVoQ?Z9uk$2ON;ersE%PU*xGO@T*;j1BO5#TuZKEf(mB7|g7pcEA=nYJ{s3vlbg zd4-DUlD{*6o%Gc^N!Nptgay>j6E5;3psI+C3Q!1ZIbeCubW%w4pq9)MSDyB{HLm|k zxv-{$$A*pS@csolri$Ge<4VZ}e~78JOL-EVyrbxKra^d{?|NnPp86!q>t<&IP07?Z z^>~IK^k#OEKgRH+LjllZXk7iA>2cfH6+(e&9ku5poo~6y{GC5>(bRK7hwjiurqAiZ zg*DmtgY}v83IjE&AbiWgMyFbaRUPZ{lYiz$U^&Zt2YjG<%m((&_JUbZcfJ22(>bi5 z!J?<7AySj0JZ&<-qXX;mcV!f~>G=sB0KnjWca4}vrtunD^1TrpfeS^4dvFr!65knK zZh`d;*VOkPs4*-9kL>$GP0`(M!j~B;#x?Ba~&s6CopvO86oM?-? zOw#dIRc;6A6T?B`Qp%^<U5 z19x(ywSH$_N+Io!6;e?`tWaM$`=Db!gzx|lQ${DG!zb1Zl&|{kX0y6xvO1o z220r<-oaS^^R2pEyY;=Qllqpmue|5yI~D|iI!IGt@iod{Opz@*ml^w2bNs)p`M(Io z|E;;m*Xpjd9l)4G#KaWfV(t8YUn@A;nK^#xgv=LtnArX|vWQVuw3}B${h+frU2>9^ z!l6)!Uo4`5k`<<;E(ido7M6lKTgWezNLq>U*=uz&s=cc$1%>VrAeOoUtA|T6gO4>UNqsdK=NF*8|~*sl&wI=x9-EGiq*aqV!(VVXA57 zw9*o6Ir8Lj1npUXvlevtn(_+^X5rzdR>#(}4YcB9O50q97%rW2me5_L=%ffYPUSRc z!vv?Kv>dH994Qi>U(a<0KF6NH5b16enCp+mw^Hb3Xs1^tThFpz!3QuN#}KBbww`(h z7GO)1olDqy6?T$()R7y%NYx*B0k_2IBiZ14&8|JPFxeMF{vW>HF-Vi3+ZOI=+qP}n zw(+!WcTd~4ZJX1!ZM&y!+uyt=&i!+~d(V%GjH;-NsEEv6nS1TERt|RHh!0>W4+4pp z1-*EzAM~i`+1f(VEHI8So`S`akPfPTfq*`l{Fz`hS%k#JS0cjT2mS0#QLGf=J?1`he3W*;m4)ce8*WFq1sdP=~$5RlH1EdWm|~dCvKOi4*I_96{^95p#B<(n!d?B z=o`0{t+&OMwKcxiBECznJcfH!fL(z3OvmxP#oWd48|mMjpE||zdiTBdWelj8&Qosv zZFp@&UgXuvJw5y=q6*28AtxZzo-UUpkRW%ne+Ylf!V-0+uQXBW=5S1o#6LXNtY5!I z%Rkz#(S8Pjz*P7bqB6L|M#Er{|QLae-Y{KA>`^} z@lPjeX>90X|34S-7}ZVXe{wEei1<{*e8T-Nbj8JmD4iwcE+Hg_zhkPVm#=@b$;)h6 z<<6y`nPa`f3I6`!28d@kdM{uJOgM%`EvlQ5B2bL)Sl=|y@YB3KeOzz=9cUW3clPAU z^sYc}xf9{4Oj?L5MOlYxR{+>w=vJjvbyO5}ptT(o6dR|ygO$)nVCvNGnq(6;bHlBd zl?w-|plD8spjDF03g5ip;W3Z z><0{BCq!Dw;h5~#1BuQilq*TwEu)qy50@+BE4bX28+7erX{BD4H)N+7U`AVEuREE8 z;X?~fyhF-x_sRfHIj~6f(+^@H)D=ngP;mwJjxhQUbUdzk8f94Ab%59-eRIq?ZKrwD z(BFI=)xrUlgu(b|hAysqK<}8bslmNNeD=#JW*}^~Nrswn^xw*nL@Tx!49bfJecV&KC2G4q5a!NSv)06A_5N3Y?veAz;Gv+@U3R% z)~UA8-0LvVE{}8LVDOHzp~2twReqf}ODIyXMM6=W>kL|OHcx9P%+aJGYi_Om)b!xe zF40Vntn0+VP>o<$AtP&JANjXBn7$}C@{+@3I@cqlwR2MdwGhVPxlTIcRVu@Ho-wO` z_~Or~IMG)A_`6-p)KPS@cT9mu9RGA>dVh5wY$NM9-^c@N=hcNaw4ITjm;iWSP^ZX| z)_XpaI61<+La+U&&%2a z0za$)-wZP@mwSELo#3!PGTt$uy0C(nTT@9NX*r3Ctw6J~7A(m#8fE)0RBd`TdKfAT zCf@$MAxjP`O(u9s@c0Fd@|}UQ6qp)O5Q5DPCeE6mSIh|Rj{$cAVIWsA=xPKVKxdhg zLzPZ`3CS+KIO;T}0Ip!fAUaNU>++ZJZRk@I(h<)RsJUhZ&Ru9*!4Ptn;gX^~4E8W^TSR&~3BAZc#HquXn)OW|TJ`CTahk+{qe`5+ixON^zA9IFd8)kc%*!AiLu z>`SFoZ5bW-%7}xZ>gpJcx_hpF$2l+533{gW{a7ce^B9sIdmLrI0)4yivZ^(Vh@-1q zFT!NQK$Iz^xu%|EOK=n>ug;(7J4OnS$;yWmq>A;hsD_0oAbLYhW^1Vdt9>;(JIYjf zdb+&f&D4@4AS?!*XpH>8egQvSVX`36jMd>$+RgI|pEg))^djhGSo&#lhS~9%NuWfX zDDH;3T*GzRT@5=7ibO>N-6_XPBYxno@mD_3I#rDD?iADxX`! zh*v8^i*JEMzyN#bGEBz7;UYXki*Xr(9xXax(_1qVW=Ml)kSuvK$coq2A(5ZGhs_pF z$*w}FbN6+QDseuB9=fdp_MTs)nQf!2SlROQ!gBJBCXD&@-VurqHj0wm@LWX-TDmS= z71M__vAok|@!qgi#H&H%Vg-((ZfxPAL8AI{x|VV!9)ZE}_l>iWk8UPTGHs*?u7RfP z5MC&=c6X;XlUzrz5q?(!eO@~* zoh2I*%J7dF!!_!vXoSIn5o|wj1#_>K*&CIn{qSaRc&iFVxt*^20ngCL;QonIS>I5^ zMw8HXm>W0PGd*}Ko)f|~dDd%;Wu_RWI_d;&2g6R3S63Uzjd7dn%Svu-OKpx*o|N>F zZg=-~qLb~VRLpv`k zWSdfHh@?dp=s_X`{yxOlxE$4iuyS;Z-x!*E6eqmEm*j2bE@=ZI0YZ5%Yj29!5+J$4h{s($nakA`xgbO8w zi=*r}PWz#lTL_DSAu1?f%-2OjD}NHXp4pXOsCW;DS@BC3h-q4_l`<))8WgzkdXg3! zs1WMt32kS2E#L0p_|x+x**TFV=gn`m9BWlzF{b%6j-odf4{7a4y4Uaef@YaeuPhU8 zHBvRqN^;$Jizy+ z=zW{E5<>2gp$pH{M@S*!sJVQU)b*J5*bX4h>5VJve#Q6ga}cQ&iL#=(u+KroWrxa%8&~p{WEUF0il=db;-$=A;&9M{Rq`ouZ5m%BHT6%st%saGsD6)fQgLN}x@d3q>FC;=f%O3Cyg=Ke@Gh`XW za@RajqOE9UB6eE=zhG%|dYS)IW)&y&Id2n7r)6p_)vlRP7NJL(x4UbhlcFXWT8?K=%s7;z?Vjts?y2+r|uk8Wt(DM*73^W%pAkZa1Jd zNoE)8FvQA>Z`eR5Z@Ig6kS5?0h;`Y&OL2D&xnnAUzQz{YSdh0k zB3exx%A2TyI)M*EM6htrxSlep!Kk(P(VP`$p0G~f$smld6W1r_Z+o?=IB@^weq>5VYsYZZR@` z&XJFxd5{|KPZmVOSxc@^%71C@;z}}WhbF9p!%yLj3j%YOlPL5s>7I3vj25 z@xmf=*z%Wb4;Va6SDk9cv|r*lhZ`(y_*M@>q;wrn)oQx%B(2A$9(74>;$zmQ!4fN; z>XurIk-7@wZys<+7XL@0Fhe-f%*=(weaQEdR9Eh6>Kl-EcI({qoZqyzziGwpg-GM#251sK_ z=3|kitS!j%;fpc@oWn65SEL73^N&t>Ix37xgs= zYG%eQDJc|rqHFia0!_sm7`@lvcv)gfy(+KXA@E{3t1DaZ$DijWAcA)E0@X?2ziJ{v z&KOYZ|DdkM{}t+@{@*6ge}m%xfjIxi%qh`=^2Rwz@w0cCvZ&Tc#UmCDbVwABrON^x zEBK43FO@weA8s7zggCOWhMvGGE`baZ62cC)VHyy!5Zbt%ieH+XN|OLbAFPZWyC6)p z4P3%8sq9HdS3=ih^0OOlqTPbKuzQ?lBEI{w^ReUO{V?@`ARsL|S*%yOS=Z%sF)>-y z(LAQdhgAcuF6LQjRYfdbD1g4o%tV4EiK&ElLB&^VZHbrV1K>tHTO{#XTo>)2UMm`2 z^t4s;vnMQgf-njU-RVBRw0P0-m#d-u`(kq7NL&2T)TjI_@iKuPAK-@oH(J8?%(e!0Ir$yG32@CGUPn5w4)+9@8c&pGx z+K3GKESI4*`tYlmMHt@br;jBWTei&(a=iYslc^c#RU3Q&sYp zSG){)V<(g7+8W!Wxeb5zJb4XE{I|&Y4UrFWr%LHkdQ;~XU zgy^dH-Z3lmY+0G~?DrC_S4@=>0oM8Isw%g(id10gWkoz2Q%7W$bFk@mIzTCcIB(K8 zc<5h&ZzCdT=9n-D>&a8vl+=ZF*`uTvQviG_bLde*k>{^)&0o*b05x$MO3gVLUx`xZ z43j+>!u?XV)Yp@MmG%Y`+COH2?nQcMrQ%k~6#O%PeD_WvFO~Kct za4XoCM_X!c5vhRkIdV=xUB3xI2NNStK*8_Zl!cFjOvp-AY=D;5{uXj}GV{LK1~IE2 z|KffUiBaStRr;10R~K2VVtf{TzM7FaPm;Y(zQjILn+tIPSrJh&EMf6evaBKIvi42-WYU9Vhj~3< zZSM-B;E`g_o8_XTM9IzEL=9Lb^SPhe(f(-`Yh=X6O7+6ALXnTcUFpI>ekl6v)ZQeNCg2 z^H|{SKXHU*%nBQ@I3It0m^h+6tvI@FS=MYS$ZpBaG7j#V@P2ZuYySbp@hA# ze(kc;P4i_-_UDP?%<6>%tTRih6VBgScKU^BV6Aoeg6Uh(W^#J^V$Xo^4#Ekp ztqQVK^g9gKMTHvV7nb64UU7p~!B?>Y0oFH5T7#BSW#YfSB@5PtE~#SCCg3p^o=NkMk$<8- z6PT*yIKGrvne7+y3}_!AC8NNeI?iTY(&nakN>>U-zT0wzZf-RuyZk^X9H-DT_*wk= z;&0}6LsGtfVa1q)CEUPlx#(ED@-?H<1_FrHU#z5^P3lEB|qsxEyn%FOpjx z3S?~gvoXy~L(Q{Jh6*i~=f%9kM1>RGjBzQh_SaIDfSU_9!<>*Pm>l)cJD@wlyxpBV z4Fmhc2q=R_wHCEK69<*wG%}mgD1=FHi4h!98B-*vMu4ZGW~%IrYSLGU{^TuseqVgV zLP<%wirIL`VLyJv9XG_p8w@Q4HzNt-o;U@Au{7%Ji;53!7V8Rv0^Lu^Vf*sL>R(;c zQG_ZuFl)Mh-xEIkGu}?_(HwkB2jS;HdPLSxVU&Jxy9*XRG~^HY(f0g8Q}iqnVmgjI zfd=``2&8GsycjR?M%(zMjn;tn9agcq;&rR!Hp z$B*gzHsQ~aXw8c|a(L^LW(|`yGc!qOnV(ZjU_Q-4z1&0;jG&vAKuNG=F|H?@m5^N@ zq{E!1n;)kNTJ>|Hb2ODt-7U~-MOIFo%9I)_@7fnX+eMMNh>)V$IXesJpBn|uo8f~#aOFytCT zf9&%MCLf8mp4kwHTcojWmM3LU=#|{3L>E}SKwOd?%{HogCZ_Z1BSA}P#O(%H$;z7XyJ^sjGX;j5 zrzp>|Ud;*&VAU3x#f{CKwY7Vc{%TKKqmB@oTHA9;>?!nvMA;8+Jh=cambHz#J18x~ zs!dF>$*AnsQ{{82r5Aw&^7eRCdvcgyxH?*DV5(I$qXh^zS>us*I66_MbL8y4d3ULj z{S(ipo+T3Ag!+5`NU2sc+@*m{_X|&p#O-SAqF&g_n7ObB82~$p%fXA5GLHMC+#qqL zdt`sJC&6C2)=juQ_!NeD>U8lDVpAOkW*khf7MCcs$A(wiIl#B9HM%~GtQ^}yBPjT@ z+E=|A!Z?A(rwzZ;T}o6pOVqHzTr*i;Wrc%&36kc@jXq~+w8kVrs;%=IFdACoLAcCAmhFNpbP8;s`zG|HC2Gv?I~w4ITy=g$`0qMQdkijLSOtX6xW%Z9Nw<;M- zMN`c7=$QxN00DiSjbVt9Mi6-pjv*j(_8PyV-il8Q-&TwBwH1gz1uoxs6~uU}PrgWB zIAE_I-a1EqlIaGQNbcp@iI8W1sm9fBBNOk(k&iLBe%MCo#?xI$%ZmGA?=)M9D=0t7 zc)Q0LnI)kCy{`jCGy9lYX%mUsDWwsY`;jE(;Us@gmWPqjmXL+Hu#^;k%eT>{nMtzj zsV`Iy6leTA8-PndszF;N^X@CJrTw5IIm!GPeu)H2#FQitR{1p;MasQVAG3*+=9FYK zw*k!HT(YQorfQj+1*mCV458(T5=fH`um$gS38hw(OqVMyunQ;rW5aPbF##A3fGH6h z@W)i9Uff?qz`YbK4c}JzQpuxuE3pcQO)%xBRZp{zJ^-*|oryTxJ-rR+MXJ)!f=+pp z10H|DdGd2exhi+hftcYbM0_}C0ZI-2vh+$fU1acsB-YXid7O|=9L!3e@$H*6?G*Zp z%qFB(sgl=FcC=E4CYGp4CN>=M8#5r!RU!u+FJVlH6=gI5xHVD&k;Ta*M28BsxfMV~ zLz+@6TxnfLhF@5=yQo^1&S}cmTN@m!7*c6z;}~*!hNBjuE>NLVl2EwN!F+)0$R1S! zR|lF%n!9fkZ@gPW|x|B={V6x3`=jS*$Pu0+5OWf?wnIy>Y1MbbGSncpKO0qE(qO=ts z!~@&!N`10S593pVQu4FzpOh!tvg}p%zCU(aV5=~K#bKi zHdJ1>tQSrhW%KOky;iW+O_n;`l9~omqM%sdxdLtI`TrJzN6BQz+7xOl*rM>xVI2~# z)7FJ^Dc{DC<%~VS?@WXzuOG$YPLC;>#vUJ^MmtbSL`_yXtNKa$Hk+l-c!aC7gn(Cg ze?YPYZ(2Jw{SF6MiO5(%_pTo7j@&DHNW`|lD`~{iH+_eSTS&OC*2WTT*a`?|9w1dh zh1nh@$a}T#WE5$7Od~NvSEU)T(W$p$s5fe^GpG+7fdJ9=enRT9$wEk+ZaB>G3$KQO zgq?-rZZnIv!p#>Ty~}c*Lb_jxJg$eGM*XwHUwuQ|o^}b3^T6Bxx{!?va8aC@-xK*H ztJBFvFfsSWu89%@b^l3-B~O!CXs)I6Y}y#0C0U0R0WG zybjroj$io0j}3%P7zADXOwHwafT#uu*zfM!oD$6aJx7+WL%t-@6^rD_a_M?S^>c;z zMK580bZXo1f*L$CuMeM4Mp!;P@}b~$cd(s5*q~FP+NHSq;nw3fbWyH)i2)-;gQl{S zZO!T}A}fC}vUdskGSq&{`oxt~0i?0xhr6I47_tBc`fqaSrMOzR4>0H^;A zF)hX1nfHs)%Zb-(YGX;=#2R6C{BG;k=?FfP?9{_uFLri~-~AJ;jw({4MU7e*d)?P@ zXX*GkNY9ItFjhwgAIWq7Y!ksbMzfqpG)IrqKx9q{zu%Mdl+{Dis#p9q`02pr1LG8R z@As?eG!>IoROgS!@J*to<27coFc1zpkh?w=)h9CbYe%^Q!Ui46Y*HO0mr% zEff-*$ndMNw}H2a5@BsGj5oFfd!T(F&0$<{GO!Qdd?McKkorh=5{EIjDTHU`So>8V zBA-fqVLb2;u7UhDV1xMI?y>fe3~4urv3%PX)lDw+HYa;HFkaLqi4c~VtCm&Ca+9C~ zge+67hp#R9`+Euq59WhHX&7~RlXn=--m8$iZ~~1C8cv^2(qO#X0?vl91gzUKBeR1J z^p4!!&7)3#@@X&2aF2-)1Ffcc^F8r|RtdL2X%HgN&XU-KH2SLCbpw?J5xJ*!F-ypZ zMG%AJ!Pr&}`LW?E!K~=(NJxuSVTRCGJ$2a*Ao=uUDSys!OFYu!Vs2IT;xQ6EubLIl z+?+nMGeQQhh~??0!s4iQ#gm3!BpMpnY?04kK375e((Uc7B3RMj;wE?BCoQGu=UlZt!EZ1Q*auI)dj3Jj{Ujgt zW5hd~-HWBLI_3HuO) zNrb^XzPsTIb=*a69wAAA3J6AAZZ1VsYbIG}a`=d6?PjM)3EPaDpW2YP$|GrBX{q*! z$KBHNif)OKMBCFP5>!1d=DK>8u+Upm-{hj5o|Wn$vh1&K!lVfDB&47lw$tJ?d5|=B z^(_9=(1T3Fte)z^>|3**n}mIX;mMN5v2F#l(q*CvU{Ga`@VMp#%rQkDBy7kYbmb-q z<5!4iuB#Q_lLZ8}h|hPODI^U6`gzLJre9u3k3c#%86IKI*^H-@I48Bi*@avYm4v!n0+v zWu{M{&F8#p9cx+gF0yTB_<2QUrjMPo9*7^-uP#~gGW~y3nfPAoV%amgr>PSyVAd@l)}8#X zR5zV6t*uKJZL}?NYvPVK6J0v4iVpwiN|>+t3aYiZSp;m0!(1`bHO}TEtWR1tY%BPB z(W!0DmXbZAsT$iC13p4f>u*ZAy@JoLAkJhzFf1#4;#1deO8#8d&89}en&z!W&A3++^1(;>0SB1*54d@y&9Pn;^IAf3GiXbfT`_>{R+Xv; zQvgL>+0#8-laO!j#-WB~(I>l0NCMt_;@Gp_f0#^c)t?&#Xh1-7RR0@zPyBz!U#0Av zT?}n({(p?p7!4S2ZBw)#KdCG)uPnZe+U|0{BW!m)9 zi_9$F?m<`2!`JNFv+w8MK_K)qJ^aO@7-Ig>cM4-r0bi=>?B_2mFNJ}aE3<+QCzRr*NA!QjHw# z`1OsvcoD0?%jq{*7b!l|L1+Tw0TTAM4XMq7*ntc-Ived>Sj_ZtS|uVdpfg1_I9knY z2{GM_j5sDC7(W&}#s{jqbybqJWyn?{PW*&cQIU|*v8YGOKKlGl@?c#TCnmnAkAzV- zmK={|1G90zz=YUvC}+fMqts0d4vgA%t6Jhjv?d;(Z}(Ep8fTZfHA9``fdUHkA+z3+ zhh{ohP%Bj?T~{i0sYCQ}uC#5BwN`skI7`|c%kqkyWIQ;!ysvA8H`b-t()n6>GJj6xlYDu~8qX{AFo$Cm3d|XFL=4uvc?Keb zzb0ZmMoXca6Mob>JqkNuoP>B2Z>D`Q(TvrG6m`j}-1rGP!g|qoL=$FVQYxJQjFn33lODt3Wb1j8VR zlR++vIT6^DtYxAv_hxupbLLN3e0%A%a+hWTKDV3!Fjr^cWJ{scsAdfhpI)`Bms^M6 zQG$waKgFr=c|p9Piug=fcJvZ1ThMnNhQvBAg-8~b1?6wL*WyqXhtj^g(Ke}mEfZVM zJuLNTUVh#WsE*a6uqiz`b#9ZYg3+2%=C(6AvZGc=u&<6??!slB1a9K)=VL zY9EL^mfyKnD zSJyYBc_>G;5RRnrNgzJz#Rkn3S1`mZgO`(r5;Hw6MveN(URf_XS-r58Cn80K)ArH4 z#Rrd~LG1W&@ttw85cjp8xV&>$b%nSXH_*W}7Ch2pg$$c0BdEo-HWRTZcxngIBJad> z;C>b{jIXjb_9Jis?NZJsdm^EG}e*pR&DAy0EaSGi3XWTa(>C%tz1n$u?5Fb z1qtl?;_yjYo)(gB^iQq?=jusF%kywm?CJP~zEHi0NbZ);$(H$w(Hy@{i>$wcVRD_X|w-~(0Z9BJyh zhNh;+eQ9BEIs;tPz%jSVnfCP!3L&9YtEP;svoj_bNzeGSQIAjd zBss@A;)R^WAu-37RQrM%{DfBNRx>v!G31Z}8-El9IOJlb_MSoMu2}GDYycNaf>uny z+8xykD-7ONCM!APry_Lw6-yT>5!tR}W;W`C)1>pxSs5o1z#j7%m=&=7O4hz+Lsqm` z*>{+xsabZPr&X=}G@obTb{nPTkccJX8w3CG7X+1+t{JcMabv~UNv+G?txRqXib~c^Mo}`q{$`;EBNJ;#F*{gvS12kV?AZ%O0SFB$^ zn+}!HbmEj}w{Vq(G)OGAzH}R~kS^;(-s&=ectz8vN!_)Yl$$U@HNTI-pV`LSj7Opu zTZ5zZ)-S_{GcEQPIQXLQ#oMS`HPu{`SQiAZ)m1at*Hy%3xma|>o`h%E%8BEbi9p0r zVjcsh<{NBKQ4eKlXU|}@XJ#@uQw*$4BxKn6#W~I4T<^f99~(=}a`&3(ur8R9t+|AQ zWkQx7l}wa48-jO@ft2h+7qn%SJtL%~890FG0s5g*kNbL3I&@brh&f6)TlM`K^(bhr zJWM6N6x3flOw$@|C@kPi7yP&SP?bzP-E|HSXQXG>7gk|R9BTj`e=4de9C6+H7H7n# z#GJeVs1mtHhLDmVO?LkYRQc`DVOJ_vdl8VUihO-j#t=0T3%Fc1f9F73ufJz*adn*p zc%&vi(4NqHu^R>sAT_0EDjVR8bc%wTz#$;%NU-kbDyL_dg0%TFafZwZ?5KZpcuaO54Z9hX zD$u>q!-9`U6-D`E#`W~fIfiIF5_m6{fvM)b1NG3xf4Auw;Go~Fu7cth#DlUn{@~yu z=B;RT*dp?bO}o%4x7k9v{r=Y@^YQ^UUm(Qmliw8brO^=NP+UOohLYiaEB3^DB56&V zK?4jV61B|1Uj_5fBKW;8LdwOFZKWp)g{B%7g1~DgO&N& z#lisxf?R~Z@?3E$Mms$$JK8oe@X`5m98V*aV6Ua}8Xs2#A!{x?IP|N(%nxsH?^c{& z@vY&R1QmQs83BW28qAmJfS7MYi=h(YK??@EhjL-t*5W!p z^gYX!Q6-vBqcv~ruw@oMaU&qp0Fb(dbVzm5xJN%0o_^@fWq$oa3X?9s%+b)x4w-q5Koe(@j6Ez7V@~NRFvd zfBH~)U5!ix3isg`6be__wBJp=1@yfsCMw1C@y+9WYD9_C%{Q~7^0AF2KFryfLlUP# zwrtJEcH)jm48!6tUcxiurAMaiD04C&tPe6DI0#aoqz#Bt0_7_*X*TsF7u*zv(iEfA z;$@?XVu~oX#1YXtceQL{dSneL&*nDug^OW$DSLF0M1Im|sSX8R26&)<0Fbh^*l6!5wfSu8MpMoh=2l z^^0Sr$UpZp*9oqa23fcCfm7`ya2<4wzJ`Axt7e4jJrRFVf?nY~2&tRL* zd;6_njcz01c>$IvN=?K}9ie%Z(BO@JG2J}fT#BJQ+f5LFSgup7i!xWRKw6)iITjZU z%l6hPZia>R!`aZjwCp}I zg)%20;}f+&@t;(%5;RHL>K_&7MH^S+7<|(SZH!u zznW|jz$uA`P9@ZWtJgv$EFp>)K&Gt+4C6#*khZQXS*S~6N%JDT$r`aJDs9|uXWdbg zBwho$phWx}x!qy8&}6y5Vr$G{yGSE*r$^r{}pw zVTZKvikRZ`J_IJrjc=X1uw?estdwm&bEahku&D04HD+0Bm~q#YGS6gp!KLf$A{%Qd z&&yX@Hp>~(wU{|(#U&Bf92+1i&Q*-S+=y=3pSZy$#8Uc$#7oiJUuO{cE6=tsPhwPe| zxQpK>`Dbka`V)$}e6_OXKLB%i76~4N*zA?X+PrhH<&)}prET;kel24kW%+9))G^JI zsq7L{P}^#QsZViX%KgxBvEugr>ZmFqe^oAg?{EI=&_O#e)F3V#rc z8$4}0Zr19qd3tE4#$3_f=Bbx9oV6VO!d3(R===i-7p=Vj`520w0D3W6lQfY48}!D* z&)lZMG;~er2qBoI2gsX+Ts-hnpS~NYRDtPd^FPzn!^&yxRy#CSz(b&E*tL|jIkq|l zf%>)7Dtu>jCf`-7R#*GhGn4FkYf;B$+9IxmqH|lf6$4irg{0ept__%)V*R_OK=T06 zyT_m-o@Kp6U{l5h>W1hGq*X#8*y@<;vsOFqEjTQXFEotR+{3}ODDnj;o0@!bB5x=N z394FojuGOtVKBlVRLtHp%EJv_G5q=AgF)SKyRN5=cGBjDWv4LDn$IL`*=~J7u&Dy5 zrMc83y+w^F&{?X(KOOAl-sWZDb{9X9#jrQtmrEXD?;h-}SYT7yM(X_6qksM=K_a;Z z3u0qT0TtaNvDER_8x*rxXw&C^|h{P1qxK|@pS7vdlZ#P z7PdB7MmC2}%sdzAxt>;WM1s0??`1983O4nFK|hVAbHcZ3x{PzytQLkCVk7hA!Lo` zEJH?4qw|}WH{dc4z%aB=0XqsFW?^p=X}4xnCJXK%c#ItOSjdSO`UXJyuc8bh^Cf}8 z@Ht|vXd^6{Fgai8*tmyRGmD_s_nv~r^Fy7j`Bu`6=G)5H$i7Q7lvQnmea&TGvJp9a|qOrUymZ$6G|Ly z#zOCg++$3iB$!6!>215A4!iryregKuUT344X)jQb3|9qY>c0LO{6Vby05n~VFzd?q zgGZv&FGlkiH*`fTurp>B8v&nSxNz)=5IF$=@rgND4d`!AaaX;_lK~)-U8la_Wa8i?NJC@BURO*sUW)E9oyv3RG^YGfN%BmxzjlT)bp*$<| zX3tt?EAy<&K+bhIuMs-g#=d1}N_?isY)6Ay$mDOKRh z4v1asEGWoAp=srraLW^h&_Uw|6O+r;wns=uwYm=JN4Q!quD8SQRSeEcGh|Eb5Jg8m zOT}u;N|x@aq)=&;wufCc^#)5U^VcZw;d_wwaoh9$p@Xrc{DD6GZUqZ ziC6OT^zSq@-lhbgR8B+e;7_Giv;DK5gn^$bs<6~SUadiosfewWDJu`XsBfOd1|p=q zE>m=zF}!lObA%ePey~gqU8S6h-^J2Y?>7)L2+%8kV}Gp=h`Xm_}rlm)SyUS=`=S7msKu zC|T!gPiI1rWGb1z$Md?0YJQ;%>uPLOXf1Z>N~`~JHJ!^@D5kSXQ4ugnFZ>^`zH8CAiZmp z6Ms|#2gcGsQ{{u7+Nb9sA?U>(0e$5V1|WVwY`Kn)rsnnZ4=1u=7u!4WexZD^IQ1Jk zfF#NLe>W$3m&C^ULjdw+5|)-BSHwpegdyt9NYC{3@QtMfd8GrIWDu`gd0nv-3LpGCh@wgBaG z176tikL!_NXM+Bv#7q^cyn9$XSeZR6#!B4JE@GVH zoobHZN_*RF#@_SVYKkQ_igme-Y5U}cV(hkR#k1c{bQNMji zU7aE`?dHyx=1`kOYZo_8U7?3-7vHOp`Qe%Z*i+FX!s?6huNp0iCEW-Z7E&jRWmUW_ z67j>)Ew!yq)hhG4o?^z}HWH-e=es#xJUhDRc4B51M4~E-l5VZ!&zQq`gWe`?}#b~7w1LH4Xa-UCT5LXkXQWheBa2YJYbyQ zl1pXR%b(KCXMO0OsXgl0P0Og<{(@&z1aokU-Pq`eQq*JYgt8xdFQ6S z6Z3IFSua8W&M#`~*L#r>Jfd6*BzJ?JFdBR#bDv$_0N!_5vnmo@!>vULcDm`MFU823 zpG9pqjqz^FE5zMDoGqhs5OMmC{Y3iVcl>F}5Rs24Y5B^mYQ;1T&ks@pIApHOdrzXF z-SdX}Hf{X;TaSxG_T$0~#RhqKISGKNK47}0*x&nRIPtmdwxc&QT3$8&!3fWu1eZ_P zJveQj^hJL#Sn!*4k`3}(d(aasl&7G0j0-*_2xtAnoX1@9+h zO#c>YQg60Z;o{Bi=3i7S`Ic+ZE>K{(u|#)9y}q*j8uKQ1^>+(BI}m%1v3$=4ojGBc zm+o1*!T&b}-lVvZqIUBc8V}QyFEgm#oyIuC{8WqUNV{Toz`oxhYpP!_p2oHHh5P@iB*NVo~2=GQm+8Yrkm2Xjc_VyHg1c0>+o~@>*Qzo zHVBJS>$$}$_4EniTI;b1WShX<5-p#TPB&!;lP!lBVBbLOOxh6FuYloD%m;n{r|;MU3!q4AVkua~fieeWu2 zQAQ$ue(IklX6+V;F1vCu-&V?I3d42FgWgsb_e^29ol}HYft?{SLf>DrmOp9o!t>I^ zY7fBCk+E8n_|apgM|-;^=#B?6RnFKlN`oR)`e$+;D=yO-(U^jV;rft^G_zl`n7qnM zL z*-Y4Phq+ZI1$j$F-f;`CD#|`-T~OM5Q>x}a>B~Gb3-+9i>Lfr|Ca6S^8g*{*?_5!x zH_N!SoRP=gX1?)q%>QTY!r77e2j9W(I!uAz{T`NdNmPBBUzi2{`XMB^zJGGwFWeA9 z{fk33#*9SO0)DjROug+(M)I-pKA!CX;IY(#gE!UxXVsa)X!UftIN98{pt#4MJHOhY zM$_l}-TJlxY?LS6Nuz1T<44m<4i^8k@D$zuCPrkmz@sdv+{ciyFJG2Zwy&%c7;atIeTdh!a(R^QXnu1Oq1b42*OQFWnyQ zWeQrdvP|w_idy53Wa<{QH^lFmEd+VlJkyiC>6B#s)F;w-{c;aKIm;Kp50HnA-o3lY z9B~F$gJ@yYE#g#X&3ADx&tO+P_@mnQTz9gv30_sTsaGXkfNYXY{$(>*PEN3QL>I!k zp)KibPhrfX3%Z$H6SY`rXGYS~143wZrG2;=FLj50+VM6soI~up_>fU(2Wl@{BRsMi zO%sL3x?2l1cXTF)k&moNsHfQrQ+wu(gBt{sk#CU=UhrvJIncy@tJX5klLjgMn>~h= zg|FR&;@eh|C7`>s_9c~0-{IAPV){l|Ts`i=)AW;d9&KPc3fMeoTS%8@V~D8*h;&(^>yjT84MM}=%#LS7shLAuuj(0VAYoozhWjq z4LEr?wUe2^WGwdTIgWBkDUJa>YP@5d9^Rs$kCXmMRxuF*YMVrn?0NFyPl}>`&dqZb z<5eqR=ZG3>n2{6v6BvJ`YBZeeTtB88TAY(x0a58EWyuf>+^|x8Qa6wA|1Nb_p|nA zWWa}|z8a)--Wj`LqyFk_a3gN2>5{Rl_wbW?#by7&i*^hRknK%jwIH6=dQ8*-_{*x0j^DUfMX0`|K@6C<|1cgZ~D(e5vBFFm;HTZF(!vT8=T$K+|F)x3kqzBV4-=p1V(lzi(s7jdu0>LD#N=$Lk#3HkG!a zIF<7>%B7sRNzJ66KrFV76J<2bdYhxll0y2^_rdG=I%AgW4~)1Nvz=$1UkE^J%BxLo z+lUci`UcU062os*=`-j4IfSQA{w@y|3}Vk?i;&SSdh8n+$iHA#%ERL{;EpXl6u&8@ zzg}?hkEOUOJt?ZL=pWZFJ19mI1@P=$U5*Im1e_8Z${JsM>Ov?nh8Z zP5QvI!{Jy@&BP48%P2{Jr_VgzW;P@7)M9n|lDT|Ep#}7C$&ud&6>C^5ZiwKIg2McPU(4jhM!BD@@L(Gd*Nu$ji(ljZ<{FIeW_1Mmf;76{LU z-ywN~=uNN)Xi6$<12A9y)K%X|(W0p|&>>4OXB?IiYr||WKDOJPxiSe01NSV-h24^L z_>m$;|C+q!Mj**-qQ$L-*++en(g|hw;M!^%_h-iDjFHLo-n3JpB;p?+o2;`*jpvJU zLY^lt)Un4joij^^)O(CKs@7E%*!w>!HA4Q?0}oBJ7Nr8NQ7QmY^4~jvf0-`%waOLn zdNjAPaC0_7c|RVhw)+71NWjRi!y>C+Bl;Z`NiL^zn2*0kmj5gyhCLCxts*cWCdRI| zjsd=sT5BVJc^$GxP~YF$-U{-?kW6r@^vHXB%{CqYzU@1>dzf#3SYedJG-Rm6^RB7s zGM5PR(yKPKR)>?~vpUIeTP7A1sc8-knnJk*9)3t^e%izbdm>Y=W{$wm(cy1RB-19i za#828DMBY+ps#7Y8^6t)=Ea@%Nkt)O6JCx|ybC;Ap}Z@Zw~*}3P>MZLPb4Enxz9Wf zssobT^(R@KuShj8>@!1M7tm|2%-pYYDxz-5`rCbaTCG5{;Uxm z*g=+H1X8{NUvFGzz~wXa%Eo};I;~`37*WrRU&K0dPSB$yk(Z*@K&+mFal^?c zurbqB-+|Kb5|sznT;?Pj!+kgFY1#Dr;_%A(GIQC{3ct|{*Bji%FNa6c-thbpBkA;U zURV!Dr&X{0J}iht#-Qp2=xzuh(fM>zRoiGrYl5ttw2#r34gC41CCOC31m~^UPTK@s z6;A@)7O7_%C)>bnAXerYuAHdE93>j2N}H${zEc6&SbZ|-fiG*-qtGuy-qDelH(|u$ zorf8_T6Zqe#Ub!+e3oSyrskt_HyW_^5lrWt#30l)tHk|j$@YyEkXUOV;6B51L;M@=NIWZXU;GrAa(LGxO%|im%7F<-6N;en0Cr zLH>l*y?pMwt`1*cH~LdBPFY_l;~`N!Clyfr;7w<^X;&(ZiVdF1S5e(+Q%60zgh)s4 zn2yj$+mE=miVERP(g8}G4<85^-5f@qxh2ec?n+$A_`?qN=iyT1?U@t?V6DM~BIlBB z>u~eXm-aE>R0sQy!-I4xtCNi!!qh?R1!kKf6BoH2GG{L4%PAz0{Sh6xpuyI%*~u)s z%rLuFl)uQUCBQAtMyN;%)zFMx4loh7uTfKeB2Xif`lN?2gq6NhWhfz0u5WP9J>=V2 zo{mLtSy&BA!mSzs&CrKWq^y40JF5a&GSXIi2= z{EYb59J4}VwikL4P=>+mc6{($FNE@e=VUwG+KV21;<@lrN`mnz5jYGASyvz7BOG_6(p^eTxD-4O#lROgon;R35=|nj#eHIfJBYPWG>H>`dHKCDZ3`R{-?HO0mE~(5_WYcFmp8sU?wr*UkAQiNDGc6T zA%}GOLXlOWqL?WwfHO8MB#8M8*~Y*gz;1rWWoVSXP&IbKxbQ8+s%4Jnt?kDsq7btI zCDr0PZ)b;B%!lu&CT#RJzm{l{2fq|BcY85`w~3LSK<><@(2EdzFLt9Y_`;WXL6x`0 zDoQ?=?I@Hbr;*VVll1Gmd8*%tiXggMK81a+T(5Gx6;eNb8=uYn z5BG-0g>pP21NPn>$ntBh>`*})Fl|38oC^9Qz>~MAazH%3Q~Qb!ALMf$srexgPZ2@&c~+hxRi1;}+)-06)!#Mq<6GhP z-Q?qmgo${aFBApb5p}$1OJKTClfi8%PpnczyVKkoHw7Ml9e7ikrF0d~UB}i3vizos zXW4DN$SiEV9{faLt5bHy2a>33K%7Td-n5C*N;f&ZqAg#2hIqEb(y<&f4u5BWJ>2^4 z414GosL=Aom#m&=x_v<0-fp1r%oVJ{T-(xnomNJ(Dryv zh?vj+%=II_nV+@NR+(!fZZVM&(W6{6%9cm+o+Z6}KqzLw{(>E86uA1`_K$HqINlb1 zKelh3-jr2I9V?ych`{hta9wQ2c9=MM`2cC{m6^MhlL2{DLv7C^j z$xXBCnDl_;l|bPGMX@*tV)B!c|4oZyftUlP*?$YU9C_eAsuVHJ58?)zpbr30P*C`T z7y#ao`uE-SOG(Pi+`$=e^mle~)pRrdwL5)N;o{gpW21of(QE#U6w%*C~`v-z0QqBML!!5EeYA5IQB0 z^l01c;L6E(iytN!LhL}wfwP7W9PNAkb+)Cst?qg#$n;z41O4&v+8-zPs+XNb-q zIeeBCh#ivnFLUCwfS;p{LC0O7tm+Sf9Jn)~b%uwP{%69;QC)Ok0t%*a5M+=;y8j=v z#!*pp$9@!x;UMIs4~hP#pnfVc!%-D<+wsG@R2+J&%73lK|2G!EQC)O05TCV=&3g)C!lT=czLpZ@Sa%TYuoE?v8T8`V;e$#Zf2_Nj6nvBgh1)2 GZ~q4|mN%#X literal 0 HcmV?d00001 diff --git a/mod/gradle/wrapper/gradle-wrapper.properties b/mod/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..cea7a79 --- /dev/null +++ b/mod/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,7 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-bin.zip +networkTimeout=10000 +validateDistributionUrl=true +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/mod/gradlew.bat b/mod/gradlew.bat new file mode 100644 index 0000000..640d686 --- /dev/null +++ b/mod/gradlew.bat @@ -0,0 +1,94 @@ +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem +@rem SPDX-License-Identifier: Apache-2.0 +@rem + +@if "%DEBUG%"=="" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS=-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if %ERRORLEVEL% equ 0 goto execute + +echo. 1>&2 +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2 +echo. 1>&2 +echo Please set the JAVA_HOME variable in your environment to match the 1>&2 +echo location of your Java installation. 1>&2 + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. 1>&2 +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2 +echo. 1>&2 +echo Please set the JAVA_HOME variable in your environment to match the 1>&2 +echo location of your Java installation. 1>&2 + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if %ERRORLEVEL% equ 0 goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle new file mode 100644 index 0000000..25c29a5 --- /dev/null +++ b/mod/neoforge/build.gradle @@ -0,0 +1,54 @@ +plugins { + id 'com.github.johnrengelman.shadow' version '8.1.1' +} + +loom { + neoForge { + version = rootProject.neoforge_version + } +} + +architectury { + platformSetupLoomIde() + neoForge() +} + +configurations { + common + shadowCommon + compileClasspath.extendsFrom common + runtimeClasspath.extendsFrom common + developmentNeoForge.extendsFrom common +} + +dependencies { + neoForge "net.neoforged:neoforge:${rootProject.neoforge_version}" + modImplementation "dev.architectury:architectury-neoforge:${rootProject.architectury_api_version}" + + common(project(path: ':common', configuration: 'namedElements')) { transitive false } + shadowCommon(project(path: ':common', configuration: 'transformProductionNeoForge')) { transitive false } +} + +jar { + archiveClassifier = 'dev' +} + +shadowJar { + configurations = [project.configurations.shadowCommon] + archiveClassifier = 'dev-shadow' +} + +remapJar { + input.set shadowJar.archiveFile + dependsOn shadowJar + archiveClassifier = null +} + +processResources { + inputs.property 'mod_version', project.version + filesMatching('META-INF/neoforge.mods.toml') { + expand 'mod_version': project.version, + 'minecraft_version': rootProject.minecraft_version, + 'supported_game_versions': rootProject.supportedGameVersions + } +} diff --git a/mod/neoforge/gradle.properties b/mod/neoforge/gradle.properties new file mode 100644 index 0000000..7da18ea --- /dev/null +++ b/mod/neoforge/gradle.properties @@ -0,0 +1 @@ +loom.platform=neoforge diff --git a/mod/neoforge/src/main/java/dev/spyc0der77/mcspacks/neoforge/McsPacksNeoForge.java b/mod/neoforge/src/main/java/dev/spyc0der77/mcspacks/neoforge/McsPacksNeoForge.java new file mode 100644 index 0000000..9e2ab25 --- /dev/null +++ b/mod/neoforge/src/main/java/dev/spyc0der77/mcspacks/neoforge/McsPacksNeoForge.java @@ -0,0 +1,13 @@ +package dev.spyc0der77.mcspacks.neoforge; + +import dev.spyc0der77.mcspacks.McsPacks; +import net.neoforged.fml.common.Mod; + +@Mod(McsPacksNeoForge.MOD_ID) +public final class McsPacksNeoForge { + public static final String MOD_ID = "mcs_packs"; + + public McsPacksNeoForge() { + McsPacks.init(); + } +} diff --git a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml new file mode 100644 index 0000000..d93f35d --- /dev/null +++ b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -0,0 +1,32 @@ +modLoader = "javafml" +loaderVersion = "[4,)" +license = "MIT" +issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" + +[[mods]] +modId = "mcs_packs" +version = "${mod_version}" +displayName = "MCS Packs" +description = "Compile and hot-reload Minecraft Script datapacks from mcs_packs/" +authors = "SpyC0der77" + +[[dependencies.mcs_packs]] +modId = "neoforge" +type = "required" +versionRange = "[${minecraft_version},)" +ordering = "NONE" +side = "BOTH" + +[[dependencies.mcs_packs]] +modId = "minecraft" +type = "required" +versionRange = "[${minecraft_version},)" +ordering = "NONE" +side = "BOTH" + +[[dependencies.mcs_packs]] +modId = "architectury" +type = "required" +versionRange = "[0,)" +ordering = "AFTER" +side = "BOTH" diff --git a/mod/scripts/apply_version.py b/mod/scripts/apply_version.py new file mode 100644 index 0000000..a46c4f4 --- /dev/null +++ b/mod/scripts/apply_version.py @@ -0,0 +1,59 @@ +#!/usr/bin/env python3 +"""Write mod/gradle.properties for a selected MCS profile.""" + +from __future__ import annotations + +import argparse +import json +from pathlib import Path + +MOD_ROOT = Path(__file__).resolve().parents[1] +MANIFEST = MOD_ROOT / "versions" / "manifest.json" +GRADLE_PROPERTIES = MOD_ROOT / "gradle.properties" + + +def main() -> int: + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("profile", help="MCS profile key from versions/manifest.json") + args = parser.parse_args() + + manifest = json.loads(MANIFEST.read_text(encoding="utf-8")) + profile = manifest["profiles"].get(args.profile) + if profile is None: + known = ", ".join(manifest["profiles"].keys()) + raise SystemExit(f"Unknown profile {args.profile!r}. Known: {known}") + + lines = [ + "org.gradle.jvmargs=-Xmx4G", + "org.gradle.parallel=true", + "org.gradle.daemon=false", + "", + f"mcs_profile={args.profile}", + f"minecraft_version={profile['minecraft_version']}", + f"mcs_minecraft_profile={profile['mcs_profile']}", + f"supported_game_versions={','.join(profile['supported_game_versions'])}", + "", + "architectury_plugin_version=3.4-SNAPSHOT", + "architectury_loom_version=1.13-SNAPSHOT", + "loom.ignoreDependencyLoomVersionValidation=true", + "", + "mod_version=0.1.0", + "maven_group=dev.spyc0der77", + "archives_base_name=mcs-packs", + "mod_id=mcs_packs", + "", + f"fabric_loader_version={profile['fabric_loader_version']}", + f"fabric_api_version={profile['fabric_api_version']}", + f"forge_version={profile['forge_version']}", + f"neoforge_version={profile['neoforge_version']}", + f"architectury_api_version={profile['architectury_api_version']}", + "", + "enabled_platforms=fabric", + ] + GRADLE_PROPERTIES.write_text("\n".join(lines) + "\n", encoding="utf-8") + print(f"Wrote {GRADLE_PROPERTIES} for profile {args.profile}") + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/mod/scripts/build_all.py b/mod/scripts/build_all.py new file mode 100644 index 0000000..20bc300 --- /dev/null +++ b/mod/scripts/build_all.py @@ -0,0 +1,66 @@ +#!/usr/bin/env python3 +"""Build MCS Packs mod artifacts for every MCS profile and loader.""" + +from __future__ import annotations + +import argparse +import json +import subprocess +import sys +from pathlib import Path + +MOD_ROOT = Path(__file__).resolve().parents[1] +MANIFEST = MOD_ROOT / "versions" / "manifest.json" +GRADLEW = MOD_ROOT / ("gradlew.bat" if sys.platform.startswith("win") else "gradlew") + + +def load_manifest() -> dict: + return json.loads(MANIFEST.read_text(encoding="utf-8")) + + +def run_build(profile: str, loader: str, skip_tests: bool) -> int: + command = [str(GRADLEW), f":{loader}:build", f"-Pmcs_profile={profile}"] + if skip_tests: + command.append("-x") + command.append("test") + print(f"\n==> {' '.join(command)}", flush=True) + return subprocess.run(command, cwd=MOD_ROOT, check=False).returncode + + +def main() -> int: + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("--profile", help="Build only this MCS profile key (e.g. 1.21.11)") + parser.add_argument("--loader", choices=["fabric", "forge", "neoforge"], help="Build only this loader") + parser.add_argument("--skip-tests", action="store_true") + args = parser.parse_args() + + if not GRADLEW.is_file(): + print(f"Gradle wrapper not found at {GRADLEW}. Run setup first.", file=sys.stderr) + return 1 + + manifest = load_manifest() + profiles = [args.profile] if args.profile else list(manifest["profiles"].keys()) + loaders = [args.loader] if args.loader else manifest["loaders"] + + failures: list[str] = [] + for profile in profiles: + if profile not in manifest["profiles"]: + failures.append(f"unknown profile {profile!r}") + continue + for loader in loaders: + code = run_build(profile, loader, args.skip_tests) + if code != 0: + failures.append(f"{profile}:{loader} (exit {code})") + + if failures: + print("\nBuild failures:", file=sys.stderr) + for item in failures: + print(f" - {item}", file=sys.stderr) + return 1 + + print("\nAll requested builds completed successfully.") + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/mod/scripts/bun.lock b/mod/scripts/bun.lock new file mode 100644 index 0000000..7a8908d --- /dev/null +++ b/mod/scripts/bun.lock @@ -0,0 +1,203 @@ +{ + "lockfileVersion": 1, + "configVersion": 1, + "workspaces": { + "": { + "name": "mcs-mod-scripts", + "dependencies": { + "@spyglassmc/core": "^0.4.47", + "@spyglassmc/java-edition": "^0.3.60", + "@spyglassmc/mcdoc": "^0.3.51", + }, + }, + }, + "packages": { + "@spyglassmc/core": ["@spyglassmc/core@0.4.47", "", { "dependencies": { "@spyglassmc/locales": "0.3.24", "base64-arraybuffer": "^1.0.2", "binary-search": "^1.3.6", "decompress": "^4.2.1", "follow-redirects": "^1.14.8", "picomatch": "^4.0.2", "rfdc": "^1.3.0", "vscode-languageserver-textdocument": "^1.0.4", "whatwg-url": "^14.0.0" } }, "sha512-xC75t4+yDZNiofCgRt/up8XuVb6qo03NoEziT32Y05+TbXae0fD5N/8KBZmcLfGnFZQaYB5pYPHkULxMKiV3sg=="], + + "@spyglassmc/java-edition": ["@spyglassmc/java-edition@0.3.60", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/json": "0.3.51", "@spyglassmc/locales": "0.3.24", "@spyglassmc/mcdoc": "0.3.51", "@spyglassmc/mcfunction": "0.2.50", "@spyglassmc/nbt": "0.3.53" } }, "sha512-XUF9kddzOh2lSn5J+s1cTZfMUnY0bDtbk2dZEOnfuN2Jx/apGIiqgxGA/tv8zcs34vomSk/OPHW4rK7S4buvTA=="], + + "@spyglassmc/json": ["@spyglassmc/json@0.3.51", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/locales": "0.3.24", "@spyglassmc/mcdoc": "0.3.51" } }, "sha512-iAvc5VnCcnwSRfF4Nr+aYzPdT2mcSNBjpNNP4O9pycIsOrlbBObOB77A55gi1Axm/e28HpKvge8kjWrn3NDCfg=="], + + "@spyglassmc/locales": ["@spyglassmc/locales@0.3.24", "", {}, "sha512-L3Y2p+zS++pyyDaGGGmBFBTPncjNFERbJ/QtLCBrNQqJyZYFLauEkOUvsWrOky6U7V7ObDF0lnzxoPiVQPUjSw=="], + + "@spyglassmc/mcdoc": ["@spyglassmc/mcdoc@0.3.51", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/locales": "0.3.24" } }, "sha512-J4KXGbs2B7bnsMqbCdFkEj7ZYv+txSwuZsYhC5iwczIU6qyWs7K3nvAURml1j16K0EFJrMY/OVoj7i7IO5UxWA=="], + + "@spyglassmc/mcfunction": ["@spyglassmc/mcfunction@0.2.50", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/locales": "0.3.24" } }, "sha512-C/wmEO08AGlLnOZG3ai7d2GnqEOJFav9aZVL4WDVE+/jJGH5tN1oErSl8LSgOz4x4uUzU+tTOnK0dVjeg4EiOw=="], + + "@spyglassmc/nbt": ["@spyglassmc/nbt@0.3.53", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/locales": "0.3.24", "@spyglassmc/mcdoc": "0.3.51" } }, "sha512-7ybjL7vCCmkYcwQHKZkjjOkKDue/pgWCrzNPVzZ18ZlDQN7SYBOxI8N6MlbqW5bultG8OHFl49tQJ1TFUW4KKw=="], + + "available-typed-arrays": ["available-typed-arrays@1.0.7", "", { "dependencies": { "possible-typed-array-names": "^1.0.0" } }, "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ=="], + + "base64-arraybuffer": ["base64-arraybuffer@1.0.2", "", {}, "sha512-I3yl4r9QB5ZRY3XuJVEPfc2XhZO6YweFPI+UovAzn+8/hb3oJ6lnysaFcjVpkCPfVWFUDvoZ8kmVDP7WyRtYtQ=="], + + "base64-js": ["base64-js@1.5.1", "", {}, "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA=="], + + "binary-search": ["binary-search@1.3.6", "", {}, "sha512-nbE1WxOTTrUWIfsfZ4aHGYu5DOuNkbxGokjV6Z2kxfJK3uaAb8zNK1muzOeipoLHZjInT4Br88BHpzevc681xA=="], + + "bl": ["bl@1.2.3", "", { "dependencies": { "readable-stream": "^2.3.5", "safe-buffer": "^5.1.1" } }, "sha512-pvcNpa0UU69UT341rO6AYy4FVAIkUHuZXRIWbq+zHnsVcRzDDjIAhGuuYoi0d//cwIwtt4pkpKycWEfjdV+vww=="], + + "buffer": ["buffer@5.7.1", "", { "dependencies": { "base64-js": "^1.3.1", "ieee754": "^1.1.13" } }, "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ=="], + + "buffer-alloc": ["buffer-alloc@1.2.0", "", { "dependencies": { "buffer-alloc-unsafe": "^1.1.0", "buffer-fill": "^1.0.0" } }, "sha512-CFsHQgjtW1UChdXgbyJGtnm+O/uLQeZdtbDo8mfUgYXCHSM1wgrVxXm6bSyrUuErEb+4sYVGCzASBRot7zyrow=="], + + "buffer-alloc-unsafe": ["buffer-alloc-unsafe@1.1.0", "", {}, "sha512-TEM2iMIEQdJ2yjPJoSIsldnleVaAk1oW3DBVUykyOLsEsFmEc9kn+SFFPz+gl54KQNxlDnAwCXosOS9Okx2xAg=="], + + "buffer-crc32": ["buffer-crc32@0.2.13", "", {}, "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ=="], + + "buffer-fill": ["buffer-fill@1.0.0", "", {}, "sha512-T7zexNBwiiaCOGDg9xNX9PBmjrubblRkENuptryuI64URkXDFum9il/JGL8Lm8wYfAXpredVXXZz7eMHilimiQ=="], + + "call-bind": ["call-bind@1.0.9", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.2", "es-define-property": "^1.0.1", "get-intrinsic": "^1.3.0", "set-function-length": "^1.2.2" } }, "sha512-a/hy+pNsFUTR+Iz8TCJvXudKVLAnz/DyeSUo10I5yvFDQJBFU2s9uqQpoSrJlroHUKoKqzg+epxyP9lqFdzfBQ=="], + + "call-bind-apply-helpers": ["call-bind-apply-helpers@1.0.2", "", { "dependencies": { "es-errors": "^1.3.0", "function-bind": "^1.1.2" } }, "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ=="], + + "call-bound": ["call-bound@1.0.4", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.2", "get-intrinsic": "^1.3.0" } }, "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg=="], + + "commander": ["commander@2.20.3", "", {}, "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ=="], + + "core-util-is": ["core-util-is@1.0.3", "", {}, "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ=="], + + "decompress": ["decompress@4.2.1", "", { "dependencies": { "decompress-tar": "^4.0.0", "decompress-tarbz2": "^4.0.0", "decompress-targz": "^4.0.0", "decompress-unzip": "^4.0.1", "graceful-fs": "^4.1.10", "make-dir": "^1.0.0", "pify": "^2.3.0", "strip-dirs": "^2.0.0" } }, "sha512-e48kc2IjU+2Zw8cTb6VZcJQ3lgVbS4uuB1TfCHbiZIP/haNXm+SVyhu+87jts5/3ROpd82GSVCoNs/z8l4ZOaQ=="], + + "decompress-tar": ["decompress-tar@4.1.1", "", { "dependencies": { "file-type": "^5.2.0", "is-stream": "^1.1.0", "tar-stream": "^1.5.2" } }, "sha512-JdJMaCrGpB5fESVyxwpCx4Jdj2AagLmv3y58Qy4GE6HMVjWz1FeVQk1Ct4Kye7PftcdOo/7U7UKzYBJgqnGeUQ=="], + + "decompress-tarbz2": ["decompress-tarbz2@4.1.1", "", { "dependencies": { "decompress-tar": "^4.1.0", "file-type": "^6.1.0", "is-stream": "^1.1.0", "seek-bzip": "^1.0.5", "unbzip2-stream": "^1.0.9" } }, "sha512-s88xLzf1r81ICXLAVQVzaN6ZmX4A6U4z2nMbOwobxkLoIIfjVMBg7TeguTUXkKeXni795B6y5rnvDw7rxhAq9A=="], + + "decompress-targz": ["decompress-targz@4.1.1", "", { "dependencies": { "decompress-tar": "^4.1.1", "file-type": "^5.2.0", "is-stream": "^1.1.0" } }, "sha512-4z81Znfr6chWnRDNfFNqLwPvm4db3WuZkqV+UgXQzSngG3CEKdBkw5jrv3axjjL96glyiiKjsxJG3X6WBZwX3w=="], + + "decompress-unzip": ["decompress-unzip@4.0.1", "", { "dependencies": { "file-type": "^3.8.0", "get-stream": "^2.2.0", "pify": "^2.3.0", "yauzl": "^2.4.2" } }, "sha512-1fqeluvxgnn86MOh66u8FjbtJpAFv5wgCT9Iw8rcBqQcCo5tO8eiJw7NNTrvt9n4CRBVq7CstiS922oPgyGLrw=="], + + "define-data-property": ["define-data-property@1.1.4", "", { "dependencies": { "es-define-property": "^1.0.0", "es-errors": "^1.3.0", "gopd": "^1.0.1" } }, "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A=="], + + "dunder-proto": ["dunder-proto@1.0.1", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.1", "es-errors": "^1.3.0", "gopd": "^1.2.0" } }, "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A=="], + + "end-of-stream": ["end-of-stream@1.4.5", "", { "dependencies": { "once": "^1.4.0" } }, "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg=="], + + "es-define-property": ["es-define-property@1.0.1", "", {}, "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g=="], + + "es-errors": ["es-errors@1.3.0", "", {}, "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw=="], + + "es-object-atoms": ["es-object-atoms@1.1.2", "", { "dependencies": { "es-errors": "^1.3.0" } }, "sha512-HWcBoN6NileqtSydK2FqHbS/LoDd2pqrnQHLyJzBj4kOp/ky2MWMN694xOfkK8/SnUsW2DH7EfyVlydKCsm1Zw=="], + + "fd-slicer": ["fd-slicer@1.1.0", "", { "dependencies": { "pend": "~1.2.0" } }, "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g=="], + + "file-type": ["file-type@5.2.0", "", {}, "sha512-Iq1nJ6D2+yIO4c8HHg4fyVb8mAJieo1Oloy1mLLaB2PvezNedhBVm+QU7g0qM42aiMbRXTxKKwGD17rjKNJYVQ=="], + + "follow-redirects": ["follow-redirects@1.16.0", "", { "peerDependencies": { "debug": "*" }, "optionalPeers": ["debug"] }, "sha512-y5rN/uOsadFT/JfYwhxRS5R7Qce+g3zG97+JrtFZlC9klX/W5hD7iiLzScI4nZqUS7DNUdhPgw4xI8W2LuXlUw=="], + + "for-each": ["for-each@0.3.5", "", { "dependencies": { "is-callable": "^1.2.7" } }, "sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg=="], + + "fs-constants": ["fs-constants@1.0.0", "", {}, "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow=="], + + "function-bind": ["function-bind@1.1.2", "", {}, "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA=="], + + "get-intrinsic": ["get-intrinsic@1.3.0", "", { "dependencies": { "call-bind-apply-helpers": "^1.0.2", "es-define-property": "^1.0.1", "es-errors": "^1.3.0", "es-object-atoms": "^1.1.1", "function-bind": "^1.1.2", "get-proto": "^1.0.1", "gopd": "^1.2.0", "has-symbols": "^1.1.0", "hasown": "^2.0.2", "math-intrinsics": "^1.1.0" } }, "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ=="], + + "get-proto": ["get-proto@1.0.1", "", { "dependencies": { "dunder-proto": "^1.0.1", "es-object-atoms": "^1.0.0" } }, "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g=="], + + "get-stream": ["get-stream@2.3.1", "", { "dependencies": { "object-assign": "^4.0.1", "pinkie-promise": "^2.0.0" } }, "sha512-AUGhbbemXxrZJRD5cDvKtQxLuYaIbNtDTK8YqupCI393Q2KSTreEsLUN3ZxAWFGiKTzL6nKuzfcIvieflUX9qA=="], + + "gopd": ["gopd@1.2.0", "", {}, "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg=="], + + "graceful-fs": ["graceful-fs@4.2.11", "", {}, "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ=="], + + "has-property-descriptors": ["has-property-descriptors@1.0.2", "", { "dependencies": { "es-define-property": "^1.0.0" } }, "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg=="], + + "has-symbols": ["has-symbols@1.1.0", "", {}, "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ=="], + + "has-tostringtag": ["has-tostringtag@1.0.2", "", { "dependencies": { "has-symbols": "^1.0.3" } }, "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw=="], + + "hasown": ["hasown@2.0.4", "", { "dependencies": { "function-bind": "^1.1.2" } }, "sha512-T2UbfbBEF32wiepXIsMlTW9+dDYC6wMh/t/vYA4tuOMKqWz/n3vr1NFSxQiyP+zk2mXsoMA/i/7qV6LKut1t1A=="], + + "ieee754": ["ieee754@1.2.1", "", {}, "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA=="], + + "inherits": ["inherits@2.0.4", "", {}, "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ=="], + + "is-callable": ["is-callable@1.2.7", "", {}, "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA=="], + + "is-natural-number": ["is-natural-number@4.0.1", "", {}, "sha512-Y4LTamMe0DDQIIAlaer9eKebAlDSV6huy+TWhJVPlzZh2o4tRP5SQWFlLn5N0To4mDD22/qdOq+veo1cSISLgQ=="], + + "is-stream": ["is-stream@1.1.0", "", {}, "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ=="], + + "is-typed-array": ["is-typed-array@1.1.15", "", { "dependencies": { "which-typed-array": "^1.1.16" } }, "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ=="], + + "isarray": ["isarray@1.0.0", "", {}, "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ=="], + + "make-dir": ["make-dir@1.3.0", "", { "dependencies": { "pify": "^3.0.0" } }, "sha512-2w31R7SJtieJJnQtGc7RVL2StM2vGYVfqUOvUDxH6bC6aJTxPxTF0GnIgCyu7tjockiUWAYQRbxa7vKn34s5sQ=="], + + "math-intrinsics": ["math-intrinsics@1.1.0", "", {}, "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g=="], + + "object-assign": ["object-assign@4.1.1", "", {}, "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg=="], + + "once": ["once@1.4.0", "", { "dependencies": { "wrappy": "1" } }, "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w=="], + + "pend": ["pend@1.2.0", "", {}, "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg=="], + + "picomatch": ["picomatch@4.0.4", "", {}, "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A=="], + + "pify": ["pify@2.3.0", "", {}, "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog=="], + + "pinkie": ["pinkie@2.0.4", "", {}, "sha512-MnUuEycAemtSaeFSjXKW/aroV7akBbY+Sv+RkyqFjgAe73F+MR0TBWKBRDkmfWq/HiFmdavfZ1G7h4SPZXaCSg=="], + + "pinkie-promise": ["pinkie-promise@2.0.1", "", { "dependencies": { "pinkie": "^2.0.0" } }, "sha512-0Gni6D4UcLTbv9c57DfxDGdr41XfgUjqWZu492f0cIGr16zDU06BWP/RAEvOuo7CQ0CNjHaLlM59YJJFm3NWlw=="], + + "possible-typed-array-names": ["possible-typed-array-names@1.1.0", "", {}, "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg=="], + + "process-nextick-args": ["process-nextick-args@2.0.1", "", {}, "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag=="], + + "punycode": ["punycode@2.3.1", "", {}, "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg=="], + + "readable-stream": ["readable-stream@2.3.8", "", { "dependencies": { "core-util-is": "~1.0.0", "inherits": "~2.0.3", "isarray": "~1.0.0", "process-nextick-args": "~2.0.0", "safe-buffer": "~5.1.1", "string_decoder": "~1.1.1", "util-deprecate": "~1.0.1" } }, "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA=="], + + "rfdc": ["rfdc@1.4.1", "", {}, "sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA=="], + + "safe-buffer": ["safe-buffer@5.2.1", "", {}, "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="], + + "seek-bzip": ["seek-bzip@1.0.6", "", { "dependencies": { "commander": "^2.8.1" }, "bin": { "seek-bunzip": "bin/seek-bunzip", "seek-table": "bin/seek-bzip-table" } }, "sha512-e1QtP3YL5tWww8uKaOCQ18UxIT2laNBXHjV/S2WYCiK4udiv8lkG89KRIoCjUagnAmCBurjF4zEVX2ByBbnCjQ=="], + + "set-function-length": ["set-function-length@1.2.2", "", { "dependencies": { "define-data-property": "^1.1.4", "es-errors": "^1.3.0", "function-bind": "^1.1.2", "get-intrinsic": "^1.2.4", "gopd": "^1.0.1", "has-property-descriptors": "^1.0.2" } }, "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg=="], + + "string_decoder": ["string_decoder@1.1.1", "", { "dependencies": { "safe-buffer": "~5.1.0" } }, "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg=="], + + "strip-dirs": ["strip-dirs@2.1.0", "", { "dependencies": { "is-natural-number": "^4.0.1" } }, "sha512-JOCxOeKLm2CAS73y/U4ZeZPTkE+gNVCzKt7Eox84Iej1LT/2pTWYpZKJuxwQpvX1LiZb1xokNR7RLfuBAa7T3g=="], + + "tar-stream": ["tar-stream@1.6.2", "", { "dependencies": { "bl": "^1.0.0", "buffer-alloc": "^1.2.0", "end-of-stream": "^1.0.0", "fs-constants": "^1.0.0", "readable-stream": "^2.3.0", "to-buffer": "^1.1.1", "xtend": "^4.0.0" } }, "sha512-rzS0heiNf8Xn7/mpdSVVSMAWAoy9bfb1WOTYC78Z0UQKeKa/CWS8FOq0lKGNa8DWKAn9gxjCvMLYc5PGXYlK2A=="], + + "through": ["through@2.3.8", "", {}, "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg=="], + + "to-buffer": ["to-buffer@1.2.2", "", { "dependencies": { "isarray": "^2.0.5", "safe-buffer": "^5.2.1", "typed-array-buffer": "^1.0.3" } }, "sha512-db0E3UJjcFhpDhAF4tLo03oli3pwl3dbnzXOUIlRKrp+ldk/VUxzpWYZENsw2SZiuBjHAk7DfB0VU7NKdpb6sw=="], + + "tr46": ["tr46@5.1.1", "", { "dependencies": { "punycode": "^2.3.1" } }, "sha512-hdF5ZgjTqgAntKkklYw0R03MG2x/bSzTtkxmIRw/sTNV8YXsCJ1tfLAX23lhxhHJlEf3CRCOCGGWw3vI3GaSPw=="], + + "typed-array-buffer": ["typed-array-buffer@1.0.3", "", { "dependencies": { "call-bound": "^1.0.3", "es-errors": "^1.3.0", "is-typed-array": "^1.1.14" } }, "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw=="], + + "unbzip2-stream": ["unbzip2-stream@1.4.3", "", { "dependencies": { "buffer": "^5.2.1", "through": "^2.3.8" } }, "sha512-mlExGW4w71ebDJviH16lQLtZS32VKqsSfk80GCfUlwT/4/hNRFsoscrF/c++9xinkMzECL1uL9DDwXqFWkruPg=="], + + "util-deprecate": ["util-deprecate@1.0.2", "", {}, "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw=="], + + "vscode-languageserver-textdocument": ["vscode-languageserver-textdocument@1.0.12", "", {}, "sha512-cxWNPesCnQCcMPeenjKKsOCKQZ/L6Tv19DTRIGuLWe32lyzWhihGVJ/rcckZXJxfdKCFvRLS3fpBIsV/ZGX4zA=="], + + "webidl-conversions": ["webidl-conversions@7.0.0", "", {}, "sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g=="], + + "whatwg-url": ["whatwg-url@14.2.0", "", { "dependencies": { "tr46": "^5.1.0", "webidl-conversions": "^7.0.0" } }, "sha512-De72GdQZzNTUBBChsXueQUnPKDkg/5A5zp7pFDuQAj5UFoENpiACU0wlCvzpAGnTkj++ihpKwKyYewn/XNUbKw=="], + + "which-typed-array": ["which-typed-array@1.1.22", "", { "dependencies": { "available-typed-arrays": "^1.0.7", "call-bind": "^1.0.9", "call-bound": "^1.0.4", "for-each": "^0.3.5", "get-proto": "^1.0.1", "gopd": "^1.2.0", "has-tostringtag": "^1.0.2" } }, "sha512-fvO4ExWMFsqyhG3AiPAObMuY1lxaqgYcxbc49CNdWDDECOJNgQyvsOWVwbZc+qf3rzRtxojBK+CMEv0Ld5CYpw=="], + + "wrappy": ["wrappy@1.0.2", "", {}, "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ=="], + + "xtend": ["xtend@4.0.2", "", {}, "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ=="], + + "yauzl": ["yauzl@2.10.0", "", { "dependencies": { "buffer-crc32": "~0.2.3", "fd-slicer": "~1.1.0" } }, "sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g=="], + + "decompress-tarbz2/file-type": ["file-type@6.2.0", "", {}, "sha512-YPcTBDV+2Tm0VqjybVd32MHdlEGAtuxS3VAYsumFokDSMG+ROT5wawGlnHDoz7bfMcMDt9hxuXvXwoKUx2fkOg=="], + + "decompress-unzip/file-type": ["file-type@3.9.0", "", {}, "sha512-RLoqTXE8/vPmMuTI88DAzhMYC99I8BWv7zYP4A1puo5HIjEJ5EX48ighy4ZyKMG9EDXxBgW6e++cn7d1xuFghA=="], + + "make-dir/pify": ["pify@3.0.0", "", {}, "sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg=="], + + "readable-stream/safe-buffer": ["safe-buffer@5.1.2", "", {}, "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="], + + "string_decoder/safe-buffer": ["safe-buffer@5.1.2", "", {}, "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="], + + "to-buffer/isarray": ["isarray@2.0.5", "", {}, "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw=="], + } +} diff --git a/mod/scripts/mcs-spyglass-validate.mjs b/mod/scripts/mcs-spyglass-validate.mjs new file mode 100644 index 0000000..4a864b6 --- /dev/null +++ b/mod/scripts/mcs-spyglass-validate.mjs @@ -0,0 +1,199 @@ +#!/usr/bin/env node +import { mkdirSync } from 'node:fs' +import { mkdtempSync } from 'node:fs' +import { readFileSync } from 'node:fs' +import { readdirSync, statSync } from 'node:fs' +import { join, relative, resolve } from 'node:path' +import { tmpdir } from 'node:os' +import { pathToFileURL } from 'node:url' + +import { + ErrorSeverity, + FileNode, + Logger, + Project, + VanillaConfig, +} from '@spyglassmc/core' +import { getNodeJsExternals } from '@spyglassmc/core/lib/nodejs.js' +import { initialize as initializeJavaEdition } from '@spyglassmc/java-edition' +import { initialize as initializeMcdoc } from '@spyglassmc/mcdoc' + +function parseArgs(argv) { + const flags = { + json: false, + mcVersion: null, + } + const positional = [] + + for (let index = 0; index < argv.length; index += 1) { + const arg = argv[index] + if (arg === '--json') { + flags.json = true + continue + } + if (arg === '--mc-version') { + flags.mcVersion = argv[index + 1] + index += 1 + continue + } + if (arg.startsWith('--mc-version=')) { + flags.mcVersion = arg.slice('--mc-version='.length) + continue + } + positional.push(arg) + } + + if (positional.length < 1) { + throw new Error('Usage: node mcs-spyglass-validate.mjs [--json] [--mc-version ] ') + } + + return { flags, datapackDir: resolve(positional[0]) } +} + +function toRootUri(path) { + const normalized = resolve(path).replace(/\\/g, '/') + return pathToFileURL(`${normalized}/`).href +} + +function severityName(severity) { + switch (severity) { + case ErrorSeverity.Hint: + return 'hint' + case ErrorSeverity.Information: + return 'information' + case ErrorSeverity.Warning: + return 'warning' + case ErrorSeverity.Error: + return 'error' + default: + return 'error' + } +} + +function walkFiles(rootDir) { + const files = [] + const stack = [rootDir] + while (stack.length > 0) { + const current = stack.pop() + for (const entry of readdirSync(current)) { + const fullPath = join(current, entry) + const stats = statSync(fullPath) + if (stats.isDirectory()) { + stack.push(fullPath) + continue + } + files.push(fullPath) + } + } + return files +} + +function languageIdFor(path) { + if (path.endsWith('.mcfunction')) return 'mcfunction' + if (path.endsWith('.json')) return 'json' + if (path.endsWith('.nbt')) return 'nbt' + return null +} + +async function main() { + const { flags, datapackDir } = parseArgs(process.argv.slice(2)) + const packMetaPath = join(datapackDir, 'pack.mcmeta') + if (!statSync(datapackDir).isDirectory() || !statSync(packMetaPath).isFile()) { + throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`) + } + + const cacheRoot = toRootUri(mkdtempSync(join(tmpdir(), 'mcs-spyglass-'))) + mkdirSync(new URL(cacheRoot), { recursive: true }) + const projectRoot = toRootUri(datapackDir) + const gameVersion = flags.mcVersion + const diagnostics = [] + + const project = new Project({ + cacheRoot, + defaultConfig: { + ...VanillaConfig, + env: { + ...VanillaConfig.env, + ...(gameVersion ? { gameVersion } : {}), + }, + }, + externals: getNodeJsExternals({ cacheRoot }), + initializers: [initializeMcdoc, initializeJavaEdition], + isDebugging: false, + logger: Logger.create('warn'), + projectRoots: [projectRoot], + }) + + project.on('documentErrored', ({ uri, errors }) => { + for (const error of errors) { + const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, '$1')) + const relativePath = relative(datapackDir, filePath).replace(/\\/g, '/') + const start = error.posRange?.start + diagnostics.push({ + file: relativePath, + line: (start?.line ?? 0) + 1, + column: (start?.character ?? 0) + 1, + message: error.message, + severity: severityName(error.severity), + }) + } + }) + + await project.init() + await project.ready() + + for (const filePath of walkFiles(datapackDir)) { + const languageId = languageIdFor(filePath) + if (!languageId) continue + const uri = pathToFileURL(filePath).href + const content = readFileSync(filePath, 'utf8') + await project.onDidOpen(uri, languageId, 1, content) + const managed = await project.ensureClientManagedChecked(uri) + if (!managed) continue + for (const error of FileNode.getErrors(managed.node)) { + diagnostics.push({ + file: relative(datapackDir, filePath).replace(/\\/g, '/'), + line: error.range.start.line + 1, + column: error.range.start.character + 1, + message: error.message, + severity: severityName(error.severity), + }) + } + } + + await project.close() + + const unique = new Map() + for (const diagnostic of diagnostics) { + const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}` + unique.set(key, diagnostic) + } + const result = [...unique.values()].sort((left, right) => { + if (left.file !== right.file) return left.file.localeCompare(right.file) + if (left.line !== right.line) return left.line - right.line + return left.column - right.column + }) + + if (flags.json) { + process.stdout.write(`${JSON.stringify(result)}\n`) + } else { + for (const diagnostic of result) { + process.stdout.write( + `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}: ${diagnostic.message}\n`, + ) + } + } + + const hasErrors = result.some((diagnostic) => diagnostic.severity === 'error') + process.exit(hasErrors ? 1 : 0) +} + +main().catch((error) => { + const message = error instanceof Error ? error.stack ?? error.message : String(error) + if (process.argv.includes('--json')) { + process.stdout.write(`${JSON.stringify([{ file: '', line: 0, column: 0, message, severity: 'error' }])}\n`) + } else { + process.stderr.write(`${message}\n`) + } + process.exit(1) +}) diff --git a/mod/scripts/package.json b/mod/scripts/package.json new file mode 100644 index 0000000..395b9fa --- /dev/null +++ b/mod/scripts/package.json @@ -0,0 +1,10 @@ +{ + "name": "mcs-mod-scripts", + "private": true, + "type": "module", + "dependencies": { + "@spyglassmc/core": "^0.4.47", + "@spyglassmc/java-edition": "^0.3.60", + "@spyglassmc/mcdoc": "^0.3.51" + } +} diff --git a/mod/settings.gradle b/mod/settings.gradle new file mode 100644 index 0000000..0e8cdea --- /dev/null +++ b/mod/settings.gradle @@ -0,0 +1,31 @@ +pluginManagement { + repositories { + maven { url = 'https://maven.fabricmc.net/' } + maven { url = 'https://maven.architectury.dev/' } + maven { url = 'https://files.minecraftforge.net/maven/' } + gradlePluginPortal() + } +} + +rootProject.name = 'mcs-packs' + +def properties = new Properties() +def propertiesFile = file('gradle.properties') +if (propertiesFile.exists()) { + propertiesFile.withInputStream { properties.load(it) } +} +def enabledPlatforms = (properties.getProperty('enabled_platforms', 'fabric') ?: 'fabric') + .split(',') + .collect { it.trim() } + .findAll { !it.isEmpty() } + +include 'common' +if (enabledPlatforms.contains('fabric')) { + include 'fabric' +} +if (enabledPlatforms.contains('forge')) { + include 'forge' +} +if (enabledPlatforms.contains('neoforge')) { + include 'neoforge' +} diff --git a/mod/versions/manifest.json b/mod/versions/manifest.json new file mode 100644 index 0000000..91d5549 --- /dev/null +++ b/mod/versions/manifest.json @@ -0,0 +1,85 @@ +{ + "loaders": ["fabric", "forge", "neoforge"], + "profiles": { + "1.21.2": { + "minecraft_version": "1.21.2", + "mcs_profile": "1.21.2", + "supported_game_versions": ["1.21.2"], + "fabric_loader_version": "0.16.9", + "fabric_api_version": "0.106.0+1.21.2", + "forge_version": "52.0.28", + "neoforge_version": "21.1.80", + "architectury_api_version": "13.0.8" + }, + "1.21.4": { + "minecraft_version": "1.21.4", + "mcs_profile": "1.21.4", + "supported_game_versions": ["1.21.4"], + "fabric_loader_version": "0.16.9", + "fabric_api_version": "0.112.2+1.21.4", + "forge_version": "54.0.10", + "neoforge_version": "21.4.33-beta", + "architectury_api_version": "13.0.8" + }, + "1.21.5": { + "minecraft_version": "1.21.5", + "mcs_profile": "1.21.5", + "supported_game_versions": ["1.21.5"], + "fabric_loader_version": "0.16.12", + "fabric_api_version": "0.119.9+1.21.5", + "forge_version": "55.0.4", + "neoforge_version": "21.5.28-beta", + "architectury_api_version": "14.0.3" + }, + "1.21.6": { + "minecraft_version": "1.21.6", + "mcs_profile": "1.21.6", + "supported_game_versions": ["1.21.6"], + "fabric_loader_version": "0.16.14", + "fabric_api_version": "0.128.1+1.21.6", + "forge_version": "56.0.0", + "neoforge_version": "21.6.4-beta", + "architectury_api_version": "14.0.3" + }, + "1.21.7-8": { + "minecraft_version": "1.21.8", + "mcs_profile": "1.21.7-8", + "supported_game_versions": ["1.21.7", "1.21.8"], + "fabric_loader_version": "0.17.2", + "fabric_api_version": "0.131.0+1.21.8", + "forge_version": "57.0.0", + "neoforge_version": "21.8.4-beta", + "architectury_api_version": "15.0.3" + }, + "1.21.9-10": { + "minecraft_version": "1.21.10", + "mcs_profile": "1.21.9-10", + "supported_game_versions": ["1.21.9", "1.21.10"], + "fabric_loader_version": "0.17.2", + "fabric_api_version": "0.136.0+1.21.10", + "forge_version": "58.0.0", + "neoforge_version": "21.10.4-beta", + "architectury_api_version": "16.0.3" + }, + "1.21.11": { + "minecraft_version": "1.21.11", + "mcs_profile": "1.21.11", + "supported_game_versions": ["1.21.11"], + "fabric_loader_version": "0.18.4", + "fabric_api_version": "0.140.2+1.21.11", + "forge_version": "61.1.0", + "neoforge_version": "21.11.42", + "architectury_api_version": "19.0.1" + }, + "26.1": { + "minecraft_version": "26.1", + "mcs_profile": "26.1", + "supported_game_versions": ["26.1"], + "fabric_loader_version": "0.19.3", + "fabric_api_version": "0.145.0+26.1", + "forge_version": "60.0.0", + "neoforge_version": "26.1.4-beta", + "architectury_api_version": "20.0.1" + } + } +} diff --git a/tests/test_compile_cli_flags.py b/tests/test_compile_cli_flags.py new file mode 100644 index 0000000..a3e7e0f --- /dev/null +++ b/tests/test_compile_cli_flags.py @@ -0,0 +1,94 @@ +import json +import shutil +import subprocess +import sys +from pathlib import Path + +import pytest + +from minecraft_script.common import COMMON_CONFIG, module_folder + + +EXAMPLE = Path(module_folder).parent / "examples" / "starter_datapack.mcs" + + +@pytest.fixture +def build_output(tmp_path): + output = tmp_path / "out" + output.mkdir() + return output + + +def test_compile_force_rebuilds_existing_output(build_output): + first = subprocess.run( + [ + sys.executable, + "-m", + "minecraft_script", + "compile", + "--force", + "--mc-version", + "1.21.11", + "--no-verbose", + str(EXAMPLE), + "Starter Pack", + str(build_output), + ], + capture_output=True, + text=True, + check=False, + ) + assert first.returncode == 0, first.stderr + + marker = build_output / "Starter Pack" / "pack.mcmeta" + assert marker.is_file() + marker.write_text('{"pack":{"pack_format":0,"description":"stale"}}', encoding="utf-8") + + second = subprocess.run( + [ + sys.executable, + "-m", + "minecraft_script", + "compile", + "--force", + "--mc-version", + "1.21.11", + "--no-verbose", + str(EXAMPLE), + "Starter Pack", + str(build_output), + ], + capture_output=True, + text=True, + check=False, + ) + assert second.returncode == 0, second.stderr + assert "stale" not in marker.read_text(encoding="utf-8") + + +def test_compile_mc_version_does_not_mutate_config(build_output): + original_version = COMMON_CONFIG["minecraft_version"] + try: + result = subprocess.run( + [ + sys.executable, + "-m", + "minecraft_script", + "compile", + "--force", + "--mc-version", + "1.21.11", + "--no-verbose", + str(EXAMPLE), + "Starter Pack", + str(build_output), + ], + capture_output=True, + text=True, + check=False, + ) + assert result.returncode == 0, result.stderr + assert COMMON_CONFIG["minecraft_version"] == original_version + finally: + if build_output.exists(): + shutil.rmtree(build_output, ignore_errors=True) diff --git a/todo.md b/todo.md index 16b809c..0a698fd 100644 --- a/todo.md +++ b/todo.md @@ -1 +1,356 @@ -# MCS Todo list +# MCS Hot-Reload Mod — Implementation Todo + +A cross-loader Minecraft mod (Fabric, Forge, NeoForge) that adds an `mcs_packs` folder to the game directory, compiles `.mcs` files on save, and hot-reloads the resulting datapacks into the running world. + +**Target Minecraft versions** (from `minecraft_script/versions/index.json`): + +| MCS profile | Minecraft versions | +| ------------- | ------------------------- | +| `1.21.2` | 1.21.2 | +| `1.21.4` | 1.21.4 | +| `1.21.5` | 1.21.5 | +| `1.21.6` | 1.21.6 | +| `1.21.7-8` | 1.21.7, 1.21.8 | +| `1.21.9-10` | 1.21.9, 1.21.10 | +| `1.21.11` | 1.21.11 | +| `26.1` | 26.1 | + +--- + +## Core loop + +1. Watch `mcs_packs//` for `.mcs` file changes (create / modify / delete). +2. On update → **lint first**, then compile only if lint passes: + ```bash + mcs lint --json + ``` + Surface diagnostics in chat (`[MCS] my_pack/pack.mcs:12:3 — expected '}'`). On lint **errors**, skip compile and keep the last good datapack. +3. On lint OK → delete `mcs_packs/_compiled//` if it exists, then run MCS compile: + ```bash + mcs compile + ``` + Fallback if `mcs` is not on PATH: + ```bash + python -m minecraft_script compile + ``` +4. On compile success → run **Spyglass** on the compiled datapack folder: + ```bash + node mcs-spyglass-validate.mjs --json --mc-version + ``` + Spyglass validates generated `.mcfunction` files, tags, JSON, and commands (uses `pack.mcmeta` + game version). Surface diagnostics in chat (`[Spyglass] my_pack/data/.../main.mcfunction:3:1 — …`). +5. On Spyglass **errors** → do **not** hot-reload; keep the last good injected datapack. Compiled output stays in `_compiled/` for fixing. +6. On Spyglass OK → inject / refresh the datapack and hot-reload into the running world. +7. On compile failure → log the error, keep the last good datapack loaded. + +Pipeline: `mcs lint` → `mcs compile` → **Spyglass on output** → reload. + +--- + +## Phase 0 — Research & Decisions + +- [x] **Choose multi-loader scaffolding** — **Architectury** + - Use [Architectury](https://architectury.dev/) with a shared `common` module and thin Fabric / Forge / NeoForge entrypoints. + - Gradle layout: `mod/common`, `mod/fabric`, `mod/forge`, `mod/neoforge` (monorepo subfolder). + - Build tooling: Architectury Plugin + Architectury Loom; platform-specific hooks live in loader modules, shared logic in `common`. + +- [x] **Compiler integration** — subprocess `mcs compile` + - MCS is Python; the mod shells out to the existing CLI on every file update. + - Primary: `mcs compile ` (npm global install). + - Fallback: `python -m minecraft_script compile ` (pip / editable install). + - Set `minecraft_version` to match the running game before compile (env var or temp config — see Phase 3). + - Delete `_compiled//` before each compile (`Compiler.build()` fails if the output folder already exists). + +- [x] **Lint & validate pipeline** + - **Before compile:** `mcs lint --json` on changed `.mcs` files (syntax + imports). Errors block compile; show line/column in chat. + - **After compile:** Spyglass validates the full compiled datapack in `_compiled//` (mcfunctions, tags, JSON). Errors block hot-reload; show file/line in chat. + +- [x] **`mcs_packs` layout and output flow** + - Each pack is a **folder** under `mcs_packs/`. Mod config lives in the normal **`config/`** folder (not inside `mcs_packs/`). + ``` + .minecraft/ + config/ + mcs-packs.json # mod config (compiler path, debounce, auto-reload, etc.) + mcs_packs/ + my_pack/ # one folder per datapack project + pack.mcs # entry point (default name; override in pack.json) + helpers.mcs # optional additional sources / imports + pack.json # optional per-pack overrides (display name, entry file) + starter/ + pack.mcs + _compiled/ # mod-managed build output (gitignored by users) + my_pack/ # compiled datapack folder + starter/ + ``` + - On save: any `.mcs` change inside `mcs_packs/my_pack/` recompiles that pack → `_compiled/my_pack/`. + - Compile working directory: the pack folder (so relative imports between files in the same pack resolve). + - On reload: inject `_compiled/*` into the active world's datapack list (not copy into `saves//datapacks/` — avoids stale duplicates and `/reload` disable issues). + +- [ ] **Define hot-reload semantics** + - **Lint / compile failure:** keep previous good datapack loaded; surface error in chat + log. + - **Compile success + Spyglass errors:** compiled files remain on disk but are **not** injected/reloaded until Spyglass passes. + - **Compile success + Spyglass OK:** replace datapack source in the mod's `PackRepository` entry, then trigger a datapack reload. + - **Reload scope:** prefer targeted datapack reload over full `/reload` (preserves entities, reduces lag). Fall back to `/reload` if no stable internal API exists for a given loader version. + - **Dedicated server:** only reload when source files change on disk (no "save" event from an editor on the server machine unless files are synced). + +- [ ] **Map loader + MC version matrix** + - 8 MCS profiles × 3 loaders = up to 24 published artifacts per release. + - Use a version table in Gradle (similar to `minecraft_script/versions/index.json`) as the single source of truth for mod build targets. + - Confirm minimum loader versions per MC release (Fabric Loader, Forge, NeoForge). + +--- + +## Phase 1 — Project Scaffolding + +- [ ] Create `mod/` Gradle multi-project: + ``` + mod/ + build.gradle + settings.gradle + gradle.properties + common/ # loader-agnostic logic + fabric/ # Fabric entrypoint + platform hooks + forge/ # Forge entrypoint + platform hooks + neoforge/ # NeoForge entrypoint + platform hooks + ``` +- [ ] Configure Architectury Loom (or loader-specific Loom forks) for all three platforms. +- [ ] Add shared dependencies: SLF4J, Gson (config), optional Cloth Config for in-game settings UI. +- [ ] Wire CI job in `.github/workflows/` to build all matrix targets (can start with one MC version, expand later). +- [ ] Add `mod/README.md` with install instructions and `mcs_packs` usage (keep this todo as the engineering checklist). + +--- + +## Phase 2 — `mcs_packs` Folder Lifecycle + +- [ ] **Create folders on game launch** + - Resolve game directory via loader API (`FabricLoader.getGameDir()`, Forge `FMLPaths.GAMEDIR`, etc.). + - Create `mcs_packs/`, `mcs_packs/_compiled/`, and a starter pack folder `mcs_packs/starter/` with `pack.mcs` (from `examples/starter_datapack.mcs`) plus a short `mcs_packs/README.txt`. + - Create default mod config in `config/` if missing (use loader config dir: `FabricLoader.getConfigDir()`, Forge `FMLPaths.CONFIGDIR`). + +- [ ] **Load mod config from `config/mcs-packs.json`** (with defaults): + ```json + { + "compiler": "auto", + "compilerPath": "", + "debounceMs": 500, + "autoReload": true, + "verboseCompile": false, + "minecraftVersion": "auto", + "lintBeforeCompile": true, + "spyglassValidateAfterCompile": true, + "blockCompileOnLintErrors": true, + "blockReloadOnSpyglassErrors": true + } + ``` + - Lives in `.minecraft/config/` like every other mod — **not** inside `mcs_packs/`. + - `compiler: "auto"` — try `mcs` on PATH, then `python -m minecraft_script`. + - `minecraftVersion: "auto"` — derive from running game version, mapped through MCS profile aliases (`1.21.7` → `1.21.7-8` per `versions/index.json`). + +- [ ] **Per-pack overrides** (optional `mcs_packs//pack.json`): + - Custom datapack display name, namespace override, `entryFile` if not default `pack.mcs`. + +- [ ] **Discover packs** + - Scan `mcs_packs/*/` subdirectories on startup (exclude `_compiled`). + - Each subdirectory with a valid entry `.mcs` is one pack. + - Build a `PackRegistry` map: `packFolder → entryMcs → compiledPath → packId`. + +--- + +## Phase 3 — MCS Compiler Bridge + +- [ ] **Implement `McsCompiler` service (common module)** + - One method: `compile(Path mcsFile) → CompileResult`. + - Runs `mcs compile` (or fallback) as a subprocess; capture stdout/stderr. + - Working directory: the pack folder, e.g. `mcs_packs/my_pack/` (relative imports within a pack must resolve). + - Before compile: delete `_compiled//`. + - After compile: return success/failure + output path. + +- [ ] **Version mapping helper** + - Ship `mcs-versions.json` (from `minecraft_script/versions/index.json`) in the mod JAR. + - Map running game version → MCS profile (`1.21.8` → `1.21.7-8`). + - Pass to compiler via env `MCS_MINECRAFT_VERSION` or temp config file. + +- [ ] **Detect compiler on first run** + - Probe: user `compilerPath` → `mcs` on PATH → `python -m minecraft_script`. + - Error clearly if none found (link to MCS install docs). + +- [ ] **Surface compile diagnostics** + - Log subprocess output; show compile errors in chat + `logs/mcs-mod/latest.log`. + +--- + +## Phase 3b — Lint & Spyglass Validate + +- [ ] **Run `mcs lint --json` before each compile** (when `lintBeforeCompile` is true) + - Lint the changed file; for entry-point compiles, also lint the entry `.mcs` after any sibling file in the pack changes. + - Parse JSON diagnostics into `{ file, line, column, message, severity }`. + - Chat format: `[MCS] my_pack/helpers.mcs:14:1 — Could not resolve import 'foo.mcs'`. + - If `blockCompileOnLintErrors` and any error-severity diagnostic → skip compile, keep last good datapack. + +- [ ] **Run Spyglass on compiled output after each successful compile** (when `spyglassValidateAfterCompile` is true) + - Validate the datapack root: `mcs_packs/_compiled//` (contains `pack.mcmeta`, `data/`, generated mcfunctions). + - Build a headless CLI using `@spyglassmc/core` (same stack as `spyglass/` and `highlighter/`). Open the compiled folder as a Spyglass project; collect diagnostics on all files. + - Spawn via Node: `node mcs-spyglass-validate.mjs --json --mc-version `. + - Pass running game version (or read from `pack.mcmeta` + `mcs-versions.json` mapping). Optionally drop `spyglass.json` into `_compiled//` with `env.gameVersion` if pack format alone is ambiguous. + - Chat format: `[Spyglass] my_pack/data//function/....mcfunction:12:1 — Expected …`. + - If `blockReloadOnSpyglassErrors` and any error-severity diagnostic → skip inject + reload; keep last good injected pack. + - Warnings only → still reload (configurable later if needed). + - Spyglass / Node unavailable → one-time chat warning; optionally allow reload without validation via config fallback. + +- [ ] **Add `mcs-spyglass-validate.mjs` to repo** (e.g. under `mod/scripts/` or `npm/scripts/`) + - JSON stdout: `[{ "file", "line", "column", "message", "severity" }]`. + - Reuse Spyglass project init patterns from `highlighter/command-spyglass.mjs` / `spyglass` language server. + +--- + +## Phase 4 — File Watcher → Compile on Update + +- [ ] **Watch each `mcs_packs//` folder for `.mcs` changes** + - Java `WatchService` on a background thread; ignore `mcs_packs/_compiled/` and editor temp files. + - A change to any `.mcs` in a pack folder triggers a recompile of that pack's entry file. + +- [ ] **On any `.mcs` create/modify in a pack folder → lint → compile → Spyglass validate → reload** + - Debounce per pack (`debounceMs` from `config/mcs-packs.json`, default 500 ms). + - Cancel in-flight lint/compile/validate if the same pack changes again (generation counter). + +- [ ] **On world load → compile all pack folders once** + - Same code path as the watcher; ensures packs exist before first inject. + +- [ ] **On pack folder delete (or entry `.mcs` removed) → remove `_compiled//` and unregister datapack** + +--- + +## Phase 5 — Datapack Injection & Hot Reload + +- [ ] **Register compiled packs as dynamic datapack sources** + - **Fabric:** `ResourceManagerHelper.registerBuiltinResourcePack(...)` or custom `PackResources` via `PackSource` / server pack repository hooks (verify against target Fabric API for 1.21.2+). + - **Forge:** `AddPackFindersEvent` — add `PathPackResources` pointing at `_compiled//`. + - **NeoForge:** equivalent pack finder event (API renamed from Forge — confirm per version). + - Assign a stable pack ID (e.g. `mcs_mod:`) and `PackSource.BUILT_IN` or a custom source so `/datapack list` shows them. + +- [ ] **Implement `DatapackReloader` platform service** + - `registerPack(Path compiledDir, String packName)` + - `unregisterPack(String packName)` + - `reloadDatapacks(MinecraftServer server)` — trigger reload on server thread. + +- [ ] **Reload strategy (prefer least disruptive)** + 1. Try internal server reload API (`ReloadableServerResources`, `MinecraftServer.reloadResources`) with only datapack portion. + 2. If unavailable or unstable on a loader version, run `/reload` via server command source with OP bypass. + 3. Document side effects (function tags re-run, entities preserved vs. not) per approach. + +- [ ] **Hook world lifecycle** + - `SERVER_STARTED` → initial scan, compile, register, inject. + - `SERVER_STOPPING` → stop watcher, clear injected packs. + - Client disconnect / world unload — no reload needed. + +- [ ] **Avoid conflict with MCS `kill.mcfunction`** + - MCS kill template runs `datapack disable "file/{{datapackName}}"`. Injected packs are not `file/` packs — verify kill.mcfunction does not break hot-reload packs (may need MCS template tweak or mod-specific kill override in a future MCS release). + +--- + +## Phase 6 — User Experience + +- [ ] **In-game feedback** + - Chat messages: `[MCS] Compiling my_pack…`, `[MCS] Reloaded 2 datapacks (1.2s)`, `[MCS] Compile failed: …`. + - Optional action bar progress during compile + reload. + +- [ ] **Keybind or command** (optional) + - `/mcs reload` — force recompile all + reload. + - `/mcs status` — show compiler path, watched files, last compile times. + - `/mcs open` — open `mcs_packs/` folder in OS file manager. + +- [ ] **Config screen** (Cloth Config / YACL) + - Edits `config/mcs-packs.json` — compiler path, debounce, auto-reload toggle, verbose compile. + +- [ ] **Log file** + - `logs/mcs-mod/latest.log` with compile output for debugging. + +--- + +## Phase 7 — MCS Repo Integration + +- [ ] **Ship `mcs-versions.json` in mod JAR** + - Generated at build time from `minecraft_script/versions/index.json` + profile `minecraft_version` fields. + - Keeps mod in sync with MCS supported versions without manual duplication. + +- [ ] **Add MCS CLI flags for mod use** (nice-to-have, not blocking v1) + - `mcs compile --mc-version 1.21.11 --force ` — avoids mutating global `config.json` and handles output-dir cleanup in one step. + - v1 workaround: mod deletes output dir itself before calling plain `mcs compile`. + +- [ ] **Document workflow in main `readme.md`** + - Section: "Live development with the MCS mod" — install mod, create a folder in `mcs_packs/` with a `pack.mcs`, edit & save, see changes in world. + +- [ ] **Update `contributors.md`** + - Mod build prerequisites (JDK 21, Gradle), run-client tasks per loader. + +--- + +## Phase 8 — Version Matrix & Releases + +- [ ] **Gradle version manifest** — one row per releasable artifact: + | MC | Fabric Loader | Forge | NeoForge | MCS profile | + | ---- | ------------- | ----- | -------- | ----------- | + | 1.21.2 | … | … | … | 1.21.2 | + | … | … | … | … | … | + | 26.1 | … | … | … | 26.1 | + +- [ ] **Build all targets** in CI; publish to Modrinth + CurseForge (optional). +- [ ] **Tag naming:** `mod-v0.1.0+1.21.11-fabric`, etc. +- [ ] **Compatibility policy:** mod major version tracks MCS major; declare minimum MCS / Python / Node version in mod metadata. + +--- + +## Phase 9 — Testing + +- [ ] **Manual test matrix** (per loader × at least 2 MC versions): + - Fresh install creates `mcs_packs/`, `mcs_packs/starter/`, and `config/mcs-packs.json`. + - Save `.mcs` inside a pack folder triggers lint → compile → Spyglass validate → reload; `load` function runs. + - Lint, compile, or Spyglass errors keep previous injected pack active; chat shows diagnostic with file + line. + - Spyglass catches bad commands in generated `.mcfunction` files that MCS lint missed. + - Delete pack folder removes compiled output and unregisters datapack after reload. + - Multi-pack: two pack folders compile and load independently. + - Import between `.mcs` files within the same pack folder resolves correctly. + +- [ ] **Automated tests (where feasible)** + - Unit tests for version mapping (`1.21.10` → `1.21.9-10`). + - Unit tests for debounce / watch event coalescing. + - Integration test: invoke real `mcs compile` subprocess against `examples/starter_datapack.mcs` into `build_test/` (per `AGENTS.md`). + - GameTest / gametest framework hooks for in-world verification (stretch goal). + +- [ ] **Performance checks** + - Compile + reload time for small vs. large packs. + - No watcher thread leak on world unload. + +--- + +## Phase 10 — Known Risks & Open Questions + +- [ ] **Python / Node dependency** — v1 requires MCS installed separately (`npm install -g minecraft-script` or `pip install -e .`) **and Node on PATH** for post-compile Spyglass validation. Mod shows a clear error if `mcs` / `python -m minecraft_script` / Node is missing. +- [ ] **Dedicated server** — no automatic "save" unless using a sync tool; document that saves on the admin machine trigger reload. +- [ ] **`/reload` cost** — large packs may cause noticeable lag; targeted reload API needs per-version verification. +- [ ] **Pack format drift** — MCS `pack.mcmeta` templates must match the running MC version (handled by MCS version profiles if compiler gets correct `minecraft_version`). +- [ ] **Scoreboard / storage state** — reload re-runs `load.mcfunction`; user scripts must be idempotent or guard with scoreboard markers. +- [ ] **Multiplayer** — only operators / server-side compile should trigger reload; clients should not spawn compilers. +- [ ] **Security** — subprocess executes user-provided `.mcs` which compiles to mcfunctions; treat `mcs_packs/` as trusted local dev content only. + +--- + +## Suggested Implementation Order + +1. ~~Phase 0: Architectury scaffolding, subprocess `mcs compile`, `mcs_packs/` layout.~~ +2. ~~Phase 1 — Architectury Gradle project (all MCS profiles × Fabric/Forge/NeoForge).~~ +3. Phase 2 + 3 + 3b + 4 — `mcs_packs/` folder, file watcher, `mcs lint` → `mcs compile` → Spyglass validate on update. +4. Phase 5 — inject compiled output + hot-reload. +5. Phase 6 — chat/log feedback on compile success or failure. +6. Phase 8 — expand to all MCS versions + Forge + NeoForge. +7. Phase 7 + 9 — MCS CLI flags (optional), tests, release. + +--- + +## Success Criteria + +- [ ] Player installs mod, launches game, sees `mcs_packs/` and `config/mcs-packs.json` in `.minecraft/`. +- [ ] Saving `mcs_packs/starter/pack.mcs` triggers lint → compile → Spyglass validate within ~1–2 s. +- [ ] Spyglass errors in compiled output are shown in chat and **do not** hot-reload a broken pack. +- [ ] World reflects datapack changes without manual `/reload` or moving folders. +- [ ] Works on Fabric, Forge, and NeoForge for every MCS-supported Minecraft version listed above. +- [ ] Clear error when MCS is not installed; no silent failures. From 3cd222e448f0fc1801d413e07d9a9fbf2d80bbb6 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Tue, 9 Jun 2026 17:32:55 -0400 Subject: [PATCH 02/12] Add Gradle wrapper script for POSIX environments - Introduced a new `gradlew` script to facilitate Gradle project execution in POSIX-compliant shells. - The script includes necessary configurations for Java command execution and environment variable handling. - Ensured compatibility with various operating systems, including Cygwin, Darwin, and MinGW. This addition streamlines the build process for users in POSIX environments. --- mod/gradlew | 251 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 251 insertions(+) create mode 100755 mod/gradlew diff --git a/mod/gradlew b/mod/gradlew new file mode 100755 index 0000000..e016b08 --- /dev/null +++ b/mod/gradlew @@ -0,0 +1,251 @@ +#!/bin/sh + +# +# Copyright © 2015-2021 the original authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 +# + +############################################################################## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# +############################################################################## + +# Attempt to set APP_HOME + +# Resolve links: $0 may be a link +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac +done + +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) +APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD=maximum + +warn () { + echo "$*" +} >&2 + +die () { + echo + echo "$*" + echo + exit 1 +} >&2 + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; +esac + +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD=$JAVA_HOME/jre/sh/java + else + JAVACMD=$JAVA_HOME/bin/java + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD=java + if ! command -v java >/dev/null 2>&1 + then + die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +fi + +# Increase the maximum file descriptors if we can. +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC2039,SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC2039,SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac +fi + +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. + +# For Cygwin or MSYS, switch paths to Windows format before running java +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + + # Now convert the arguments - kludge to limit ourselves to /bin/sh + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) + fi + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg + done +fi + + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='-Dfile.encoding=UTF-8 "-Xmx64m" "-Xms64m"' + +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# + +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' + +exec "$JAVACMD" "$@" From c9271b3dbae7aa50edc1c45b4d7f42ccc17a484b Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Tue, 9 Jun 2026 17:45:20 -0400 Subject: [PATCH 03/12] Enhance Gradle build configuration and update permission handling - Introduced a conditional source set in `build.gradle` to switch between modern and legacy Java directories based on Minecraft version. - Updated `DatapackDeployer.java` to replace direct permission handling with a new command source method for improved clarity and maintainability. --- mod/common/build.gradle | 20 +++++++++++++++++++ .../mcspacks/deploy/CommandSources.java | 14 +++++++++++++ .../mcspacks/deploy/DatapackDeployer.java | 3 +-- .../mcspacks/deploy/CommandSources.java | 13 ++++++++++++ 4 files changed, 48 insertions(+), 2 deletions(-) create mode 100644 mod/common/src/legacy/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java create mode 100644 mod/common/src/modern/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java diff --git a/mod/common/build.gradle b/mod/common/build.gradle index a854d87..660f80c 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -1,3 +1,23 @@ +def usesPermissionSetApi = { + def version = rootProject.minecraft_version + if (version ==~ /2[6-9]\..+/) { + return true + } + def match = (version =~ /^1\.21\.(\d+)/) + if (match.matches()) { + return match[0][1].toInteger() >= 11 + } + return false +}() + +sourceSets { + main { + java { + srcDir usesPermissionSetApi ? 'src/modern/java' : 'src/legacy/java' + } + } +} + architectury { common rootProject.enabled_platforms.split(',') } diff --git a/mod/common/src/legacy/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java b/mod/common/src/legacy/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java new file mode 100644 index 0000000..a6a9470 --- /dev/null +++ b/mod/common/src/legacy/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java @@ -0,0 +1,14 @@ +package dev.spyc0der77.mcspacks.deploy; + +import net.minecraft.commands.CommandSourceStack; + +public final class CommandSources { + private static final int ALL_PERMISSIONS = 4; + + private CommandSources() { + } + + public static CommandSourceStack withAllPermissions(CommandSourceStack source) { + return source.withPermission(ALL_PERMISSIONS); + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java index 8a764c4..62aaed6 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java @@ -8,7 +8,6 @@ import java.nio.file.StandardCopyOption; import java.nio.file.attribute.BasicFileAttributes; import net.minecraft.server.MinecraftServer; -import net.minecraft.server.permissions.PermissionSet; import net.minecraft.world.level.storage.LevelResource; public final class DatapackDeployer { @@ -27,7 +26,7 @@ public static void syncPack(MinecraftServer server, Path compiledPack, String pa public static void reload(MinecraftServer server) { server.submit(() -> server.getCommands().performPrefixedCommand( - server.createCommandSourceStack().withPermission(PermissionSet.ALL_PERMISSIONS), + CommandSources.withAllPermissions(server.createCommandSourceStack()), "reload" )); } diff --git a/mod/common/src/modern/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java b/mod/common/src/modern/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java new file mode 100644 index 0000000..00110d6 --- /dev/null +++ b/mod/common/src/modern/java/dev/spyc0der77/mcspacks/deploy/CommandSources.java @@ -0,0 +1,13 @@ +package dev.spyc0der77.mcspacks.deploy; + +import net.minecraft.commands.CommandSourceStack; +import net.minecraft.server.permissions.PermissionSet; + +public final class CommandSources { + private CommandSources() { + } + + public static CommandSourceStack withAllPermissions(CommandSourceStack source) { + return source.withPermission(PermissionSet.ALL_PERMISSIONS); + } +} From 0f056885688e0f42edbec5e9d2df706bd1fa29e8 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Tue, 9 Jun 2026 17:54:11 -0400 Subject: [PATCH 04/12] Enhance build and validation processes for mod development - Added Bun dependency installation step in the GitHub Actions workflow for improved JavaScript package management. - Introduced a validation function in `shell_commands.py` to ensure valid datapack names, enhancing error handling. - Updated `build.gradle` to conditionally set Minecraft version and supported game versions based on CLI input. - Enhanced Gradle properties to support multiple platforms (fabric, forge, neoforge) for better compatibility. - Refactored `apply_version.py` to dynamically read enabled platforms from `gradle.properties`. - Improved error handling in `ModConfigManager` and `PackRegistry` for better resilience against invalid configurations. - Updated `mcs-spyglass-validate` script to streamline datapack validation and improve error reporting. - Removed deprecated `mcs-versions.json` and `mcs-spyglass-validate.mjs` files, consolidating functionality into updated scripts.oo --- .github/workflows/mod.yml | 4 + minecraft_script/shell_commands.py | 20 +- mod/build.gradle | 22 +- mod/common/build.gradle | 33 +- .../dev/spyc0der77/mcspacks/McsPacks.java | 2 - .../mcspacks/config/ModConfigManager.java | 7 +- .../mcspacks/deploy/DatapackDeployer.java | 3 +- .../mcspacks/pipeline/PackPipeline.java | 72 +- .../mcspacks/registry/PackRegistry.java | 12 +- .../mcspacks/toolchain/CompilerResolver.java | 26 +- .../mcspacks/toolchain/McsToolchain.java | 4 + .../mcspacks/toolchain/SubprocessRunner.java | 15 +- .../spyc0der77/mcspacks/util/McsPaths.java | 12 +- .../spyc0der77/mcspacks/util/SafePaths.java | 28 + .../mcspacks/watch/PackWatcher.java | 24 +- .../src/main/resources/mcs-versions.json | 21 - .../main/resources/scripts/mcs-compile.cmd | 29 +- .../scripts/mcs-spyglass-validate.js | 37752 ++++++++++++++++ .../scripts/mcs-spyglass-validate.mjs | 199 - mod/fabric/build.gradle | 2 + mod/forge/build.gradle | 4 + .../src/main/resources/META-INF/mods.toml | 2 +- mod/gradle.properties | 2 +- mod/neoforge/build.gradle | 4 + .../resources/META-INF/neoforge.mods.toml | 2 +- mod/scripts/apply_version.py | 14 +- mod/scripts/bun.lock | 57 + mod/scripts/mcs-spyglass-validate.mjs | 121 +- mod/scripts/package.json | 6 + 29 files changed, 38146 insertions(+), 353 deletions(-) create mode 100644 mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java delete mode 100644 mod/common/src/main/resources/mcs-versions.json create mode 100644 mod/common/src/main/resources/scripts/mcs-spyglass-validate.js delete mode 100644 mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs diff --git a/.github/workflows/mod.yml b/.github/workflows/mod.yml index 14cae9d..ac6a5d2 100644 --- a/.github/workflows/mod.yml +++ b/.github/workflows/mod.yml @@ -24,6 +24,10 @@ jobs: with: distribution: temurin java-version: 21 + - uses: oven-sh/setup-bun@v2 + - name: Install Spyglass bundle dependencies + working-directory: mod/scripts + run: bun install --frozen-lockfile - name: Apply version profile run: python mod/scripts/apply_version.py ${{ matrix.profile }} - name: Build ${{ matrix.loader }} for ${{ matrix.profile }} diff --git a/minecraft_script/shell_commands.py b/minecraft_script/shell_commands.py index 631410f..182ff39 100644 --- a/minecraft_script/shell_commands.py +++ b/minecraft_script/shell_commands.py @@ -51,6 +51,15 @@ def _parse_flag_args( return parsed, positional +def _validate_datapack_name(datapack_name: str) -> None: + if not datapack_name or datapack_name in {".", ".."}: + print("Error: Invalid datapack name.") + exit(-1) + if ".." in datapack_name or "/" in datapack_name or "\\" in datapack_name: + print("Error: Datapack name must not contain path separators or '..'.") + exit(-1) + + def handle_arguments(arguments: list): if not arguments: sh_default() @@ -156,9 +165,18 @@ def sh_compile(*args) -> None: exit(-1) output_path.mkdir(parents=True, exist_ok=True) + resolved_output = output_path.resolve() - datapack_folder = output_path / datapack_name + _validate_datapack_name(datapack_name) + + datapack_folder = (resolved_output / datapack_name).resolve() + if not datapack_folder.is_relative_to(resolved_output): + print("Error: Datapack output path escapes output directory.") + exit(-1) if "--force" in flags and datapack_folder.exists(): + if not datapack_folder.is_dir(): + print(f"Error: Output path is not a directory ({str(datapack_folder) !r})") + exit(-1) shutil.rmtree(datapack_folder) overrides: dict[str, object] = {} diff --git a/mod/build.gradle b/mod/build.gradle index 92eed01..3e54f83 100644 --- a/mod/build.gradle +++ b/mod/build.gradle @@ -7,6 +7,7 @@ plugins { } def manifest = new JsonSlurper().parse(file('versions/manifest.json')) +def mcsProfileFromCli = gradle.startParameter.projectProperties.containsKey('mcs_profile') def activeProfileName = findProperty('mcs_profile') ?: '1.21.11' def activeProfile = manifest.profiles[activeProfileName] if (activeProfile == null) { @@ -15,8 +16,25 @@ if (activeProfile == null) { ext { mcsProfileName = activeProfileName - mcsMinecraftProfile = activeProfile.mcs_profile - supportedGameVersions = (activeProfile.supported_game_versions as List).join(',') + if (mcsProfileFromCli) { + minecraft_version = activeProfile.minecraft_version + mcsMinecraftProfile = activeProfile.mcs_profile + supportedGameVersions = (activeProfile.supported_game_versions as List).join(',') + fabric_loader_version = activeProfile.fabric_loader_version + fabric_api_version = activeProfile.fabric_api_version + forge_version = activeProfile.forge_version + neoforge_version = activeProfile.neoforge_version + architectury_api_version = activeProfile.architectury_api_version + } else { + minecraft_version = findProperty('minecraft_version') + mcsMinecraftProfile = findProperty('mcs_minecraft_profile') + supportedGameVersions = findProperty('supported_game_versions') + fabric_loader_version = findProperty('fabric_loader_version') + fabric_api_version = findProperty('fabric_api_version') + forge_version = findProperty('forge_version') + neoforge_version = findProperty('neoforge_version') + architectury_api_version = findProperty('architectury_api_version') + } } allprojects { diff --git a/mod/common/build.gradle b/mod/common/build.gradle index 660f80c..8e90101 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -19,15 +19,46 @@ sourceSets { } architectury { - common rootProject.enabled_platforms.split(',') + common rootProject.enabled_platforms.split(',').collect { it.trim() }.findAll { !it.isEmpty() } } +def generatedResourcesDir = layout.buildDirectory.dir('generated/resources/main') + +sourceSets.main.resources.srcDir(generatedResourcesDir) + +tasks.register('syncMcsVersions', Copy) { + from rootProject.file('../minecraft_script/versions/index.json') + into generatedResourcesDir + rename { 'mcs-versions.json' } +} + +processResources.dependsOn syncMcsVersions + dependencies { modImplementation "dev.architectury:architectury:${rootProject.architectury_api_version}" implementation 'com.google.code.gson:gson:2.11.0' } +def spyglassSourceScript = file("${rootProject.projectDir}/scripts/mcs-spyglass-validate.mjs") +def spyglassBundledScript = file('src/main/resources/scripts/mcs-spyglass-validate.js') + +tasks.register('bundleSpyglassScript') { + onlyIf { spyglassSourceScript.exists() } + inputs.file(spyglassSourceScript) + inputs.file("${rootProject.projectDir}/scripts/package.json") + inputs.file("${rootProject.projectDir}/scripts/bun.lock") + outputs.file(spyglassBundledScript) + + doLast { + exec { + workingDir "${rootProject.projectDir}/scripts" + commandLine 'bun', 'run', 'bundle:spyglass' + } + } +} + processResources { + dependsOn tasks.named('bundleSpyglassScript') inputs.property 'mod_version', project.version inputs.property 'minecraft_version', rootProject.minecraft_version inputs.property 'mcs_profile', rootProject.mcsProfileName diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java index 6301ca3..45d88d7 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/McsPacks.java @@ -26,8 +26,6 @@ public static void init() { pipeline = new PackPipeline(config, versionMapper, registry, PlayerFeedback::broadcast); watcher = new PackWatcher(McsPaths.packsRoot(), pipeline::handlePackChange, config.debounceMs); - pipeline.warmCompileAllPacks(); - LifecycleEvent.SERVER_STARTING.register(McsPacks::onServerStarting); LifecycleEvent.SERVER_STARTED.register(McsPacks::onServerStarted); LifecycleEvent.SERVER_STOPPING.register(McsPacks::onServerStopping); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java index e4bf1eb..72173b3 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java @@ -2,6 +2,7 @@ import com.google.gson.Gson; import com.google.gson.GsonBuilder; +import com.google.gson.JsonParseException; import dev.spyc0der77.mcspacks.util.McsPaths; import java.io.IOException; import java.nio.file.Files; @@ -22,8 +23,12 @@ public static ModConfig load() { String json = Files.readString(McsPaths.configFile()); ModConfig config = GSON.fromJson(json, ModConfig.class); return config == null ? new ModConfig() : config; + } catch (JsonParseException error) { + System.err.println("[MCS Packs] Invalid config JSON, using defaults: " + error.getMessage()); + return new ModConfig(); } catch (IOException error) { - throw new IllegalStateException("Failed to read mod config", error); + System.err.println("[MCS Packs] Failed to read config, using defaults: " + error.getMessage()); + return new ModConfig(); } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java index 62aaed6..2aada54 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java @@ -1,5 +1,6 @@ package dev.spyc0der77.mcspacks.deploy; +import dev.spyc0der77.mcspacks.util.SafePaths; import java.io.IOException; import java.nio.file.FileVisitResult; import java.nio.file.Files; @@ -17,7 +18,7 @@ private DatapackDeployer() { public static void syncPack(MinecraftServer server, Path compiledPack, String packFolderName) throws IOException { Path worldDatapacks = server.getWorldPath(LevelResource.DATAPACK_DIR); Files.createDirectories(worldDatapacks); - Path target = worldDatapacks.resolve(packFolderName); + Path target = SafePaths.resolveChild(worldDatapacks, packFolderName); if (Files.exists(target)) { deleteRecursive(target); } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java index f1c9192..d642ee9 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java @@ -65,7 +65,11 @@ public void prepareWorldPacks(MinecraftServer server) { bindServer(server); try { for (PackDefinition pack : registry.discover()) { - processPack(server, pack, false); + try { + processPack(server, pack, false); + } catch (RuntimeException error) { + messenger.accept(server, "[MCS] Failed to prepare " + pack.id() + ": " + error.getMessage()); + } } } catch (IOException error) { messenger.accept(server, "[MCS] Failed to prepare packs: " + error.getMessage()); @@ -119,45 +123,53 @@ private void processPack(MinecraftServer server, PackDefinition pack, boolean re } private boolean runToolchain(PackDefinition pack, long generation) { - String mcsProfile = versionMapper.resolveMcsProfile(Platform.getMinecraftVersion(), config.minecraftVersion); - McsToolchain toolchain = new McsToolchain(config, mcsProfile); + try { + String mcsProfile = versionMapper.resolveMcsProfile(Platform.getMinecraftVersion(), config.minecraftVersion); + McsToolchain toolchain = new McsToolchain(config, mcsProfile); - List lintDiagnostics = toolchain.lint(pack); - if (!lintDiagnostics.isEmpty()) { - MinecraftServer server = activeServer; - if (server != null) { - PlayerFeedback.diagnostics(server, "[MCS]", lintDiagnostics); + List lintDiagnostics = toolchain.lint(pack); + if (!lintDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[MCS]", lintDiagnostics); + } + if (config.blockCompileOnLintErrors && lintDiagnostics.stream().anyMatch(Diagnostic::isError)) { + return false; + } } - if (config.blockCompileOnLintErrors && lintDiagnostics.stream().anyMatch(Diagnostic::isError)) { + if (generation != 0L && generation != generations.get(pack.id())) { return false; } - } - if (generation != 0L && generation != generations.get(pack.id())) { - return false; - } - List compileDiagnostics = toolchain.compile(pack); - if (!compileDiagnostics.isEmpty()) { - MinecraftServer server = activeServer; - if (server != null) { - PlayerFeedback.diagnostics(server, "[MCS]", compileDiagnostics); + List compileDiagnostics = toolchain.compile(pack); + if (!compileDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[MCS]", compileDiagnostics); + } + return false; + } + if (generation != 0L && generation != generations.get(pack.id())) { + return false; } - return false; - } - if (generation != 0L && generation != generations.get(pack.id())) { - return false; - } - List spyglassDiagnostics = toolchain.validateWithSpyglass(pack, Platform.getMinecraftVersion()); - if (!spyglassDiagnostics.isEmpty()) { + List spyglassDiagnostics = toolchain.validateWithSpyglass(pack, Platform.getMinecraftVersion()); + if (!spyglassDiagnostics.isEmpty()) { + MinecraftServer server = activeServer; + if (server != null) { + PlayerFeedback.diagnostics(server, "[Spyglass]", spyglassDiagnostics); + } + if (config.blockReloadOnSpyglassErrors && spyglassDiagnostics.stream().anyMatch(Diagnostic::isError)) { + return false; + } + } + return generation == 0L || generation == generations.get(pack.id()); + } catch (RuntimeException error) { MinecraftServer server = activeServer; if (server != null) { - PlayerFeedback.diagnostics(server, "[Spyglass]", spyglassDiagnostics); - } - if (config.blockReloadOnSpyglassErrors && spyglassDiagnostics.stream().anyMatch(Diagnostic::isError)) { - return false; + messenger.accept(server, "[MCS] Toolchain failed for " + pack.id() + ": " + error.getMessage()); } + return false; } - return generation == 0L || generation == generations.get(pack.id()); } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java index 8a63235..19db5d3 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java @@ -1,7 +1,9 @@ package dev.spyc0der77.mcspacks.registry; import com.google.gson.Gson; +import com.google.gson.JsonParseException; import dev.spyc0der77.mcspacks.util.McsPaths; +import dev.spyc0der77.mcspacks.util.SafePaths; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; @@ -51,11 +53,12 @@ public PackDefinition resolvePack(Path folder) throws IOException { String displayName = overrides.displayName == null ? titleCase(id) : overrides.displayName; + SafePaths.validateSafeName(displayName); return new PackDefinition( id, folder, entry, - compiledRoot.resolve(displayName), + SafePaths.resolveChild(compiledRoot, displayName), displayName ); } @@ -65,7 +68,12 @@ private PackOverrides readOverrides(Path folder) throws IOException { if (Files.notExists(config)) { return new PackOverrides(); } - return new Gson().fromJson(Files.readString(config), PackOverrides.class); + try { + PackOverrides overrides = new Gson().fromJson(Files.readString(config), PackOverrides.class); + return overrides == null ? new PackOverrides() : overrides; + } catch (JsonParseException error) { + return new PackOverrides(); + } } private static String titleCase(String value) { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java index 7fe23b2..b547383 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -118,8 +118,8 @@ private static boolean isBatch(String compilerPath) { private static boolean canRun(CompilerCommand compiler, String... args) { try { - SubprocessRunner.run(compiler.toProcessCommand(List.of(args)), null, 15); - return true; + ProcessResult result = SubprocessRunner.run(compiler.toProcessCommand(List.of(args)), null, 15); + return result.success(); } catch (Exception ignored) { return false; } @@ -140,9 +140,29 @@ private static String buildCmdInvocation(String executable, List args) { } private static String quoteForCmd(String arg) { - if (!arg.contains(" ") && !arg.contains("\"")) { + if (!needsCmdQuoting(arg)) { return arg; } return "\"" + arg.replace("\"", "\\\"") + "\""; } + + private static boolean needsCmdQuoting(String arg) { + if (arg.isEmpty()) { + return true; + } + for (int index = 0; index < arg.length(); index++) { + char character = arg.charAt(index); + if (Character.isWhitespace(character) + || character == '"' + || character == '&' + || character == '|' + || character == '<' + || character == '>' + || character == '^' + || character == '%') { + return true; + } + } + return false; + } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java index 47daba0..45796b5 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -116,6 +116,10 @@ private static String relative(PackDefinition pack, Path file) { } private static void deleteRecursive(Path path) throws IOException { + if (Files.isSymbolicLink(path)) { + Files.delete(path); + return; + } if (Files.isDirectory(path)) { try (var stream = Files.list(path)) { for (Path child : stream.toList()) { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java index 52e3b4a..e690de1 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java @@ -4,6 +4,7 @@ import java.nio.charset.StandardCharsets; import java.nio.file.Path; import java.util.List; +import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeUnit; public final class SubprocessRunner { @@ -17,13 +18,21 @@ public static ProcessResult run(List command, Path workingDirectory, lon } builder.redirectErrorStream(false); Process process = builder.start(); + CompletableFuture stdoutFuture = CompletableFuture.supplyAsync(() -> readStream(process.getInputStream())); + CompletableFuture stderrFuture = CompletableFuture.supplyAsync(() -> readStream(process.getErrorStream())); boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS); if (!finished) { process.destroyForcibly(); return new ProcessResult(-1, "", "Process timed out after " + timeoutSeconds + "s"); } - String stdout = new String(process.getInputStream().readAllBytes(), StandardCharsets.UTF_8); - String stderr = new String(process.getErrorStream().readAllBytes(), StandardCharsets.UTF_8); - return new ProcessResult(process.exitValue(), stdout, stderr); + return new ProcessResult(process.exitValue(), stdoutFuture.join(), stderrFuture.join()); + } + + private static String readStream(java.io.InputStream stream) { + try { + return new String(stream.readAllBytes(), StandardCharsets.UTF_8); + } catch (IOException ignored) { + return ""; + } } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java index fd8783b..2e66bf9 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java @@ -47,14 +47,12 @@ public static Path compilerWrapper() throws IOException { public static Path spyglassScript() throws IOException { Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); Files.createDirectories(scriptsDir); - Path script = scriptsDir.resolve("mcs-spyglass-validate.mjs"); - if (Files.notExists(script)) { - try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.mjs")) { - if (stream == null) { - throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); - } - Files.copy(stream, script); + Path script = scriptsDir.resolve("mcs-spyglass-validate.js"); + try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.js")) { + if (stream == null) { + throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); } + Files.copy(stream, script, java.nio.file.StandardCopyOption.REPLACE_EXISTING); } return script; } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java new file mode 100644 index 0000000..49c180d --- /dev/null +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java @@ -0,0 +1,28 @@ +package dev.spyc0der77.mcspacks.util; + +import java.io.IOException; +import java.nio.file.Path; + +public final class SafePaths { + private SafePaths() { + } + + public static void validateSafeName(String name) throws IOException { + if (name == null || name.isBlank()) { + throw new IOException("Name must not be blank"); + } + if (name.contains("/") || name.contains("\\") || name.contains("..")) { + throw new IOException("Unsafe path name: " + name); + } + } + + public static Path resolveChild(Path parent, String childName) throws IOException { + validateSafeName(childName); + Path normalizedParent = parent.toAbsolutePath().normalize(); + Path resolved = normalizedParent.resolve(childName).normalize(); + if (!resolved.startsWith(normalizedParent)) { + throw new IOException("Path escapes parent directory: " + childName); + } + return resolved; + } +} diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java index 84f6df4..30dc5ee 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java @@ -151,7 +151,7 @@ private void pollEntryFiles() { } long modified = Files.getLastModifiedTime(entry).toMillis(); Long previous = lastModified.put(entry, modified); - if (previous != null && modified > previous) { + if (previous == null || modified > previous) { schedule(packFolder); } } @@ -177,23 +177,25 @@ private Path resolvePackFolder(Path changedPath) { return null; } - Path packFolder; + Path current; if (Files.isDirectory(changedPath)) { - packFolder = changedPath; + current = changedPath; } else { String fileName = changedPath.getFileName().toString().toLowerCase(Locale.ROOT); if (!fileName.endsWith(".mcs")) { return null; } - packFolder = changedPath.getParent(); + current = changedPath.getParent(); } - if (packFolder == null || !isPackFolder(packFolder)) { - return null; + while (current != null && current.startsWith(packsRoot) && !packsRoot.equals(current)) { + if (isPackFolder(current)) { + Path entry = current.resolve(McsPaths.DEFAULT_ENTRY); + return Files.exists(entry) ? current : null; + } + current = current.getParent(); } - - Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); - return Files.exists(entry) ? packFolder : null; + return null; } private boolean isPackFolder(Path packFolder) { @@ -220,7 +222,9 @@ private static void registerTree(WatchService watchService, Path root) throws IO if (!Files.exists(root)) { Files.createDirectories(root); } - Files.walk(root).filter(Files::isDirectory).forEach(dir -> registerDirectory(watchService, dir)); + try (var stream = Files.walk(root)) { + stream.filter(Files::isDirectory).forEach(dir -> registerDirectory(watchService, dir)); + } } private static void registerDirectory(WatchService watchService, Path directory) { diff --git a/mod/common/src/main/resources/mcs-versions.json b/mod/common/src/main/resources/mcs-versions.json deleted file mode 100644 index 8bffd83..0000000 --- a/mod/common/src/main/resources/mcs-versions.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "default": "1.21.2", - "supported": [ - "1.21.2", - "1.21.4", - "1.21.5", - "1.21.6", - "1.21.7", - "1.21.8", - "1.21.9", - "1.21.10", - "1.21.11", - "26.1" - ], - "profiles": { - "1.21.7": "1.21.7-8", - "1.21.8": "1.21.7-8", - "1.21.9": "1.21.9-10", - "1.21.10": "1.21.9-10" - } -} diff --git a/mod/common/src/main/resources/scripts/mcs-compile.cmd b/mod/common/src/main/resources/scripts/mcs-compile.cmd index 573d107..1be702e 100644 --- a/mod/common/src/main/resources/scripts/mcs-compile.cmd +++ b/mod/common/src/main/resources/scripts/mcs-compile.cmd @@ -1,10 +1,27 @@ @echo off -setlocal EnableExtensions -for %%P in (313 312 311 310) do if exist "C:\Python%%P\python.exe" call :run_python "C:\Python%%P\python.exe" %* & exit /b %ERRORLEVEL% -where mcs >nul 2>&1 && call :run_mcs %* & exit /b %ERRORLEVEL% -where python >nul 2>&1 && call :run_python python %* & exit /b %ERRORLEVEL% -where py >nul 2>&1 && call :run_py %* & exit /b %ERRORLEVEL% -if defined PYTHON if exist "%PYTHON%" call :run_python "%PYTHON%" %* & exit /b %ERRORLEVEL% +setlocal EnableExtensions EnableDelayedExpansion +for %%P in (313 312 311 310) do ( + if exist "C:\Python%%P\python.exe" ( + call :run_python "C:\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) +) +where mcs >nul 2>&1 && ( + call :run_mcs %* + exit /b !ERRORLEVEL! +) +where python >nul 2>&1 && ( + call :run_python python %* + exit /b !ERRORLEVEL! +) +where py >nul 2>&1 && ( + call :run_py %* + exit /b !ERRORLEVEL! +) +if defined PYTHON if exist "%PYTHON%" ( + call :run_python "%PYTHON%" %* + exit /b !ERRORLEVEL! +) echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 exit /b 1 diff --git a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js new file mode 100644 index 0000000..4de99b3 --- /dev/null +++ b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js @@ -0,0 +1,37752 @@ +#!/usr/bin/env node +var __create = Object.create; +var __defProp = Object.defineProperty; +var __getOwnPropDesc = Object.getOwnPropertyDescriptor; +var __getOwnPropNames = Object.getOwnPropertyNames; +var __getProtoOf = Object.getPrototypeOf; +var __hasOwnProp = Object.prototype.hasOwnProperty; +var __glob = (map3) => (path6) => { + var fn = map3[path6]; + if (fn) return fn(); + throw new Error("Module not found in bundle: " + path6); +}; +var __esm = (fn, res) => function __init() { + return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res; +}; +var __commonJS = (cb, mod) => function __require() { + return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports; +}; +var __export = (target, all) => { + for (var name in all) + __defProp(target, name, { get: all[name], enumerable: true }); +}; +var __copyProps = (to, from, except, desc) => { + if (from && typeof from === "object" || typeof from === "function") { + for (let key2 of __getOwnPropNames(from)) + if (!__hasOwnProp.call(to, key2) && key2 !== except) + __defProp(to, key2, { get: () => from[key2], enumerable: !(desc = __getOwnPropDesc(from, key2)) || desc.enumerable }); + } + return to; +}; +var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps( + // If the importer is in node compatibility mode or this is not an ESM + // file that has been converted to a CommonJS file using a Babel- + // compatible transform (i.e. "__esModule" has not been set), then set + // "default" to the CommonJS "module.exports" for node compatibility. + isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, + mod +)); + +// node_modules/binary-search/index.js +var require_binary_search = __commonJS({ + "node_modules/binary-search/index.js"(exports2, module3) { + module3.exports = function(haystack, needle, comparator, low, high) { + var mid, cmp; + if (low === void 0) + low = 0; + else { + low = low | 0; + if (low < 0 || low >= haystack.length) + throw new RangeError("invalid lower bound"); + } + if (high === void 0) + high = haystack.length - 1; + else { + high = high | 0; + if (high < low || high >= haystack.length) + throw new RangeError("invalid upper bound"); + } + while (low <= high) { + mid = low + (high - low >>> 1); + cmp = +comparator(haystack[mid], needle, mid, haystack); + if (cmp < 0) + low = mid + 1; + else if (cmp > 0) + high = mid - 1; + else + return mid; + } + return ~low; + }; + } +}); + +// node_modules/rfdc/index.js +var require_rfdc = __commonJS({ + "node_modules/rfdc/index.js"(exports2, module3) { + "use strict"; + module3.exports = rfdc4; + function copyBuffer(cur) { + if (cur instanceof Buffer) { + return Buffer.from(cur); + } + return new cur.constructor(cur.buffer.slice(), cur.byteOffset, cur.length); + } + function rfdc4(opts) { + opts = opts || {}; + if (opts.circles) return rfdcCircles(opts); + const constructorHandlers = /* @__PURE__ */ new Map(); + constructorHandlers.set(Date, (o) => new Date(o)); + constructorHandlers.set(Map, (o, fn) => new Map(cloneArray(Array.from(o), fn))); + constructorHandlers.set(Set, (o, fn) => new Set(cloneArray(Array.from(o), fn))); + if (opts.constructorHandlers) { + for (const handler2 of opts.constructorHandlers) { + constructorHandlers.set(handler2[0], handler2[1]); + } + } + let handler = null; + return opts.proto ? cloneProto : clone; + function cloneArray(a, fn) { + const keys = Object.keys(a); + const a2 = new Array(keys.length); + for (let i = 0; i < keys.length; i++) { + const k = keys[i]; + const cur = a[k]; + if (typeof cur !== "object" || cur === null) { + a2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + a2[k] = handler(cur, fn); + } else if (ArrayBuffer.isView(cur)) { + a2[k] = copyBuffer(cur); + } else { + a2[k] = fn(cur); + } + } + return a2; + } + function clone(o) { + if (typeof o !== "object" || o === null) return o; + if (Array.isArray(o)) return cloneArray(o, clone); + if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { + return handler(o, clone); + } + const o2 = {}; + for (const k in o) { + if (Object.hasOwnProperty.call(o, k) === false) continue; + const cur = o[k]; + if (typeof cur !== "object" || cur === null) { + o2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + o2[k] = handler(cur, clone); + } else if (ArrayBuffer.isView(cur)) { + o2[k] = copyBuffer(cur); + } else { + o2[k] = clone(cur); + } + } + return o2; + } + function cloneProto(o) { + if (typeof o !== "object" || o === null) return o; + if (Array.isArray(o)) return cloneArray(o, cloneProto); + if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { + return handler(o, cloneProto); + } + const o2 = {}; + for (const k in o) { + const cur = o[k]; + if (typeof cur !== "object" || cur === null) { + o2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + o2[k] = handler(cur, cloneProto); + } else if (ArrayBuffer.isView(cur)) { + o2[k] = copyBuffer(cur); + } else { + o2[k] = cloneProto(cur); + } + } + return o2; + } + } + function rfdcCircles(opts) { + const refs = []; + const refsNew = []; + const constructorHandlers = /* @__PURE__ */ new Map(); + constructorHandlers.set(Date, (o) => new Date(o)); + constructorHandlers.set(Map, (o, fn) => new Map(cloneArray(Array.from(o), fn))); + constructorHandlers.set(Set, (o, fn) => new Set(cloneArray(Array.from(o), fn))); + if (opts.constructorHandlers) { + for (const handler2 of opts.constructorHandlers) { + constructorHandlers.set(handler2[0], handler2[1]); + } + } + let handler = null; + return opts.proto ? cloneProto : clone; + function cloneArray(a, fn) { + const keys = Object.keys(a); + const a2 = new Array(keys.length); + for (let i = 0; i < keys.length; i++) { + const k = keys[i]; + const cur = a[k]; + if (typeof cur !== "object" || cur === null) { + a2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + a2[k] = handler(cur, fn); + } else if (ArrayBuffer.isView(cur)) { + a2[k] = copyBuffer(cur); + } else { + const index4 = refs.indexOf(cur); + if (index4 !== -1) { + a2[k] = refsNew[index4]; + } else { + a2[k] = fn(cur); + } + } + } + return a2; + } + function clone(o) { + if (typeof o !== "object" || o === null) return o; + if (Array.isArray(o)) return cloneArray(o, clone); + if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { + return handler(o, clone); + } + const o2 = {}; + refs.push(o); + refsNew.push(o2); + for (const k in o) { + if (Object.hasOwnProperty.call(o, k) === false) continue; + const cur = o[k]; + if (typeof cur !== "object" || cur === null) { + o2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + o2[k] = handler(cur, clone); + } else if (ArrayBuffer.isView(cur)) { + o2[k] = copyBuffer(cur); + } else { + const i = refs.indexOf(cur); + if (i !== -1) { + o2[k] = refsNew[i]; + } else { + o2[k] = clone(cur); + } + } + } + refs.pop(); + refsNew.pop(); + return o2; + } + function cloneProto(o) { + if (typeof o !== "object" || o === null) return o; + if (Array.isArray(o)) return cloneArray(o, cloneProto); + if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { + return handler(o, cloneProto); + } + const o2 = {}; + refs.push(o); + refsNew.push(o2); + for (const k in o) { + const cur = o[k]; + if (typeof cur !== "object" || cur === null) { + o2[k] = cur; + } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { + o2[k] = handler(cur, cloneProto); + } else if (ArrayBuffer.isView(cur)) { + o2[k] = copyBuffer(cur); + } else { + const i = refs.indexOf(cur); + if (i !== -1) { + o2[k] = refsNew[i]; + } else { + o2[k] = cloneProto(cur); + } + } + } + refs.pop(); + refsNew.pop(); + return o2; + } + } + } +}); + +// node_modules/webidl-conversions/lib/index.js +var require_lib = __commonJS({ + "node_modules/webidl-conversions/lib/index.js"(exports2) { + "use strict"; + function makeException(ErrorType, message2, options2) { + if (options2.globals) { + ErrorType = options2.globals[ErrorType.name]; + } + return new ErrorType(`${options2.context ? options2.context : "Value"} ${message2}.`); + } + function toNumber(value, options2) { + if (typeof value === "bigint") { + throw makeException(TypeError, "is a BigInt which cannot be converted to a number", options2); + } + if (!options2.globals) { + return Number(value); + } + return options2.globals.Number(value); + } + function evenRound(x) { + if (x > 0 && x % 1 === 0.5 && (x & 1) === 0 || x < 0 && x % 1 === -0.5 && (x & 1) === 1) { + return censorNegativeZero(Math.floor(x)); + } + return censorNegativeZero(Math.round(x)); + } + function integerPart(n) { + return censorNegativeZero(Math.trunc(n)); + } + function sign(x) { + return x < 0 ? -1 : 1; + } + function modulo(x, y) { + const signMightNotMatch = x % y; + if (sign(y) !== sign(signMightNotMatch)) { + return signMightNotMatch + y; + } + return signMightNotMatch; + } + function censorNegativeZero(x) { + return x === 0 ? 0 : x; + } + function createIntegerConversion(bitLength, { unsigned }) { + let lowerBound, upperBound; + if (unsigned) { + lowerBound = 0; + upperBound = 2 ** bitLength - 1; + } else { + lowerBound = -(2 ** (bitLength - 1)); + upperBound = 2 ** (bitLength - 1) - 1; + } + const twoToTheBitLength = 2 ** bitLength; + const twoToOneLessThanTheBitLength = 2 ** (bitLength - 1); + return (value, options2 = {}) => { + let x = toNumber(value, options2); + x = censorNegativeZero(x); + if (options2.enforceRange) { + if (!Number.isFinite(x)) { + throw makeException(TypeError, "is not a finite number", options2); + } + x = integerPart(x); + if (x < lowerBound || x > upperBound) { + throw makeException( + TypeError, + `is outside the accepted range of ${lowerBound} to ${upperBound}, inclusive`, + options2 + ); + } + return x; + } + if (!Number.isNaN(x) && options2.clamp) { + x = Math.min(Math.max(x, lowerBound), upperBound); + x = evenRound(x); + return x; + } + if (!Number.isFinite(x) || x === 0) { + return 0; + } + x = integerPart(x); + if (x >= lowerBound && x <= upperBound) { + return x; + } + x = modulo(x, twoToTheBitLength); + if (!unsigned && x >= twoToOneLessThanTheBitLength) { + return x - twoToTheBitLength; + } + return x; + }; + } + function createLongLongConversion(bitLength, { unsigned }) { + const upperBound = Number.MAX_SAFE_INTEGER; + const lowerBound = unsigned ? 0 : Number.MIN_SAFE_INTEGER; + const asBigIntN = unsigned ? BigInt.asUintN : BigInt.asIntN; + return (value, options2 = {}) => { + let x = toNumber(value, options2); + x = censorNegativeZero(x); + if (options2.enforceRange) { + if (!Number.isFinite(x)) { + throw makeException(TypeError, "is not a finite number", options2); + } + x = integerPart(x); + if (x < lowerBound || x > upperBound) { + throw makeException( + TypeError, + `is outside the accepted range of ${lowerBound} to ${upperBound}, inclusive`, + options2 + ); + } + return x; + } + if (!Number.isNaN(x) && options2.clamp) { + x = Math.min(Math.max(x, lowerBound), upperBound); + x = evenRound(x); + return x; + } + if (!Number.isFinite(x) || x === 0) { + return 0; + } + let xBigInt = BigInt(integerPart(x)); + xBigInt = asBigIntN(bitLength, xBigInt); + return Number(xBigInt); + }; + } + exports2.any = (value) => { + return value; + }; + exports2.undefined = () => { + return void 0; + }; + exports2.boolean = (value) => { + return Boolean(value); + }; + exports2.byte = createIntegerConversion(8, { unsigned: false }); + exports2.octet = createIntegerConversion(8, { unsigned: true }); + exports2.short = createIntegerConversion(16, { unsigned: false }); + exports2["unsigned short"] = createIntegerConversion(16, { unsigned: true }); + exports2.long = createIntegerConversion(32, { unsigned: false }); + exports2["unsigned long"] = createIntegerConversion(32, { unsigned: true }); + exports2["long long"] = createLongLongConversion(64, { unsigned: false }); + exports2["unsigned long long"] = createLongLongConversion(64, { unsigned: true }); + exports2.double = (value, options2 = {}) => { + const x = toNumber(value, options2); + if (!Number.isFinite(x)) { + throw makeException(TypeError, "is not a finite floating-point value", options2); + } + return x; + }; + exports2["unrestricted double"] = (value, options2 = {}) => { + const x = toNumber(value, options2); + return x; + }; + exports2.float = (value, options2 = {}) => { + const x = toNumber(value, options2); + if (!Number.isFinite(x)) { + throw makeException(TypeError, "is not a finite floating-point value", options2); + } + if (Object.is(x, -0)) { + return x; + } + const y = Math.fround(x); + if (!Number.isFinite(y)) { + throw makeException(TypeError, "is outside the range of a single-precision floating-point value", options2); + } + return y; + }; + exports2["unrestricted float"] = (value, options2 = {}) => { + const x = toNumber(value, options2); + if (isNaN(x)) { + return x; + } + if (Object.is(x, -0)) { + return x; + } + return Math.fround(x); + }; + exports2.DOMString = (value, options2 = {}) => { + if (options2.treatNullAsEmptyString && value === null) { + return ""; + } + if (typeof value === "symbol") { + throw makeException(TypeError, "is a symbol, which cannot be converted to a string", options2); + } + const StringCtor = options2.globals ? options2.globals.String : String; + return StringCtor(value); + }; + exports2.ByteString = (value, options2 = {}) => { + const x = exports2.DOMString(value, options2); + let c; + for (let i = 0; (c = x.codePointAt(i)) !== void 0; ++i) { + if (c > 255) { + throw makeException(TypeError, "is not a valid ByteString", options2); + } + } + return x; + }; + exports2.USVString = (value, options2 = {}) => { + const S = exports2.DOMString(value, options2); + const n = S.length; + const U = []; + for (let i = 0; i < n; ++i) { + const c = S.charCodeAt(i); + if (c < 55296 || c > 57343) { + U.push(String.fromCodePoint(c)); + } else if (56320 <= c && c <= 57343) { + U.push(String.fromCodePoint(65533)); + } else if (i === n - 1) { + U.push(String.fromCodePoint(65533)); + } else { + const d = S.charCodeAt(i + 1); + if (56320 <= d && d <= 57343) { + const a = c & 1023; + const b = d & 1023; + U.push(String.fromCodePoint((2 << 15) + (2 << 9) * a + b)); + ++i; + } else { + U.push(String.fromCodePoint(65533)); + } + } + } + return U.join(""); + }; + exports2.object = (value, options2 = {}) => { + if (value === null || typeof value !== "object" && typeof value !== "function") { + throw makeException(TypeError, "is not an object", options2); + } + return value; + }; + var abByteLengthGetter = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get; + var sabByteLengthGetter = typeof SharedArrayBuffer === "function" ? Object.getOwnPropertyDescriptor(SharedArrayBuffer.prototype, "byteLength").get : null; + function isNonSharedArrayBuffer(value) { + try { + abByteLengthGetter.call(value); + return true; + } catch { + return false; + } + } + function isSharedArrayBuffer(value) { + try { + sabByteLengthGetter.call(value); + return true; + } catch { + return false; + } + } + function isArrayBufferDetached(value) { + try { + new Uint8Array(value); + return false; + } catch { + return true; + } + } + exports2.ArrayBuffer = (value, options2 = {}) => { + if (!isNonSharedArrayBuffer(value)) { + if (options2.allowShared && !isSharedArrayBuffer(value)) { + throw makeException(TypeError, "is not an ArrayBuffer or SharedArrayBuffer", options2); + } + throw makeException(TypeError, "is not an ArrayBuffer", options2); + } + if (isArrayBufferDetached(value)) { + throw makeException(TypeError, "is a detached ArrayBuffer", options2); + } + return value; + }; + var dvByteLengthGetter = Object.getOwnPropertyDescriptor(DataView.prototype, "byteLength").get; + exports2.DataView = (value, options2 = {}) => { + try { + dvByteLengthGetter.call(value); + } catch (e) { + throw makeException(TypeError, "is not a DataView", options2); + } + if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { + throw makeException(TypeError, "is backed by a SharedArrayBuffer, which is not allowed", options2); + } + if (isArrayBufferDetached(value.buffer)) { + throw makeException(TypeError, "is backed by a detached ArrayBuffer", options2); + } + return value; + }; + var typedArrayNameGetter = Object.getOwnPropertyDescriptor( + Object.getPrototypeOf(Uint8Array).prototype, + Symbol.toStringTag + ).get; + [ + Int8Array, + Int16Array, + Int32Array, + Uint8Array, + Uint16Array, + Uint32Array, + Uint8ClampedArray, + Float32Array, + Float64Array + ].forEach((func) => { + const { name } = func; + const article = /^[AEIOU]/u.test(name) ? "an" : "a"; + exports2[name] = (value, options2 = {}) => { + if (!ArrayBuffer.isView(value) || typedArrayNameGetter.call(value) !== name) { + throw makeException(TypeError, `is not ${article} ${name} object`, options2); + } + if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { + throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); + } + if (isArrayBufferDetached(value.buffer)) { + throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); + } + return value; + }; + }); + exports2.ArrayBufferView = (value, options2 = {}) => { + if (!ArrayBuffer.isView(value)) { + throw makeException(TypeError, "is not a view on an ArrayBuffer or SharedArrayBuffer", options2); + } + if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { + throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); + } + if (isArrayBufferDetached(value.buffer)) { + throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); + } + return value; + }; + exports2.BufferSource = (value, options2 = {}) => { + if (ArrayBuffer.isView(value)) { + if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { + throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); + } + if (isArrayBufferDetached(value.buffer)) { + throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); + } + return value; + } + if (!options2.allowShared && !isNonSharedArrayBuffer(value)) { + throw makeException(TypeError, "is not an ArrayBuffer or a view on one", options2); + } + if (options2.allowShared && !isSharedArrayBuffer(value) && !isNonSharedArrayBuffer(value)) { + throw makeException(TypeError, "is not an ArrayBuffer, SharedArrayBuffer, or a view on one", options2); + } + if (isArrayBufferDetached(value)) { + throw makeException(TypeError, "is a detached ArrayBuffer", options2); + } + return value; + }; + exports2.DOMTimeStamp = exports2["unsigned long long"]; + } +}); + +// node_modules/whatwg-url/lib/utils.js +var require_utils = __commonJS({ + "node_modules/whatwg-url/lib/utils.js"(exports2, module3) { + "use strict"; + function isObject2(value) { + return typeof value === "object" && value !== null || typeof value === "function"; + } + var hasOwn = Function.prototype.call.bind(Object.prototype.hasOwnProperty); + function define(target, source) { + for (const key2 of Reflect.ownKeys(source)) { + const descriptor = Reflect.getOwnPropertyDescriptor(source, key2); + if (descriptor && !Reflect.defineProperty(target, key2, descriptor)) { + throw new TypeError(`Cannot redefine property: ${String(key2)}`); + } + } + } + function newObjectInRealm(globalObject, object5) { + const ctorRegistry = initCtorRegistry(globalObject); + return Object.defineProperties( + Object.create(ctorRegistry["%Object.prototype%"]), + Object.getOwnPropertyDescriptors(object5) + ); + } + var wrapperSymbol = Symbol("wrapper"); + var implSymbol = Symbol("impl"); + var sameObjectCaches = Symbol("SameObject caches"); + var ctorRegistrySymbol = Symbol.for("[webidl2js] constructor registry"); + var AsyncIteratorPrototype = Object.getPrototypeOf(Object.getPrototypeOf(async function* () { + }).prototype); + function initCtorRegistry(globalObject) { + if (hasOwn(globalObject, ctorRegistrySymbol)) { + return globalObject[ctorRegistrySymbol]; + } + const ctorRegistry = /* @__PURE__ */ Object.create(null); + ctorRegistry["%Object.prototype%"] = globalObject.Object.prototype; + ctorRegistry["%IteratorPrototype%"] = Object.getPrototypeOf( + Object.getPrototypeOf(new globalObject.Array()[Symbol.iterator]()) + ); + try { + ctorRegistry["%AsyncIteratorPrototype%"] = Object.getPrototypeOf( + Object.getPrototypeOf( + globalObject.eval("(async function* () {})").prototype + ) + ); + } catch { + ctorRegistry["%AsyncIteratorPrototype%"] = AsyncIteratorPrototype; + } + globalObject[ctorRegistrySymbol] = ctorRegistry; + return ctorRegistry; + } + function getSameObject(wrapper, prop, creator) { + if (!wrapper[sameObjectCaches]) { + wrapper[sameObjectCaches] = /* @__PURE__ */ Object.create(null); + } + if (prop in wrapper[sameObjectCaches]) { + return wrapper[sameObjectCaches][prop]; + } + wrapper[sameObjectCaches][prop] = creator(); + return wrapper[sameObjectCaches][prop]; + } + function wrapperForImpl(impl) { + return impl ? impl[wrapperSymbol] : null; + } + function implForWrapper(wrapper) { + return wrapper ? wrapper[implSymbol] : null; + } + function tryWrapperForImpl(impl) { + const wrapper = wrapperForImpl(impl); + return wrapper ? wrapper : impl; + } + function tryImplForWrapper(wrapper) { + const impl = implForWrapper(wrapper); + return impl ? impl : wrapper; + } + var iterInternalSymbol = Symbol("internal"); + function isArrayIndexPropName(P) { + if (typeof P !== "string") { + return false; + } + const i = P >>> 0; + if (i === 2 ** 32 - 1) { + return false; + } + const s = `${i}`; + if (P !== s) { + return false; + } + return true; + } + var byteLengthGetter = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get; + function isArrayBuffer(value) { + try { + byteLengthGetter.call(value); + return true; + } catch (e) { + return false; + } + } + function iteratorResult([key2, value], kind) { + let result; + switch (kind) { + case "key": + result = key2; + break; + case "value": + result = value; + break; + case "key+value": + result = [key2, value]; + break; + } + return { value: result, done: false }; + } + var supportsPropertyIndex = Symbol("supports property index"); + var supportedPropertyIndices = Symbol("supported property indices"); + var supportsPropertyName = Symbol("supports property name"); + var supportedPropertyNames = Symbol("supported property names"); + var indexedGet = Symbol("indexed property get"); + var indexedSetNew = Symbol("indexed property set new"); + var indexedSetExisting = Symbol("indexed property set existing"); + var namedGet = Symbol("named property get"); + var namedSetNew = Symbol("named property set new"); + var namedSetExisting = Symbol("named property set existing"); + var namedDelete = Symbol("named property delete"); + var asyncIteratorNext = Symbol("async iterator get the next iteration result"); + var asyncIteratorReturn = Symbol("async iterator return steps"); + var asyncIteratorInit = Symbol("async iterator initialization steps"); + var asyncIteratorEOI = Symbol("async iterator end of iteration"); + module3.exports = exports2 = { + isObject: isObject2, + hasOwn, + define, + newObjectInRealm, + wrapperSymbol, + implSymbol, + getSameObject, + ctorRegistrySymbol, + initCtorRegistry, + wrapperForImpl, + implForWrapper, + tryWrapperForImpl, + tryImplForWrapper, + iterInternalSymbol, + isArrayBuffer, + isArrayIndexPropName, + supportsPropertyIndex, + supportedPropertyIndices, + supportsPropertyName, + supportedPropertyNames, + indexedGet, + indexedSetNew, + indexedSetExisting, + namedGet, + namedSetNew, + namedSetExisting, + namedDelete, + asyncIteratorNext, + asyncIteratorReturn, + asyncIteratorInit, + asyncIteratorEOI, + iteratorResult + }; + } +}); + +// node_modules/punycode/punycode.js +var require_punycode = __commonJS({ + "node_modules/punycode/punycode.js"(exports2, module3) { + "use strict"; + var maxInt = 2147483647; + var base = 36; + var tMin = 1; + var tMax = 26; + var skew = 38; + var damp = 700; + var initialBias = 72; + var initialN = 128; + var delimiter = "-"; + var regexPunycode = /^xn--/; + var regexNonASCII = /[^\0-\x7F]/; + var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g; + var errors = { + "overflow": "Overflow: input needs wider integers to process", + "not-basic": "Illegal input >= 0x80 (not a basic code point)", + "invalid-input": "Invalid input" + }; + var baseMinusTMin = base - tMin; + var floor = Math.floor; + var stringFromCharCode = String.fromCharCode; + function error4(type2) { + throw new RangeError(errors[type2]); + } + function map3(array4, callback) { + const result = []; + let length = array4.length; + while (length--) { + result[length] = callback(array4[length]); + } + return result; + } + function mapDomain(domain, callback) { + const parts = domain.split("@"); + let result = ""; + if (parts.length > 1) { + result = parts[0] + "@"; + domain = parts[1]; + } + domain = domain.replace(regexSeparators, "."); + const labels = domain.split("."); + const encoded = map3(labels, callback).join("."); + return result + encoded; + } + function ucs2decode(string11) { + const output = []; + let counter = 0; + const length = string11.length; + while (counter < length) { + const value = string11.charCodeAt(counter++); + if (value >= 55296 && value <= 56319 && counter < length) { + const extra = string11.charCodeAt(counter++); + if ((extra & 64512) == 56320) { + output.push(((value & 1023) << 10) + (extra & 1023) + 65536); + } else { + output.push(value); + counter--; + } + } else { + output.push(value); + } + } + return output; + } + var ucs2encode = (codePoints) => String.fromCodePoint(...codePoints); + var basicToDigit = function(codePoint) { + if (codePoint >= 48 && codePoint < 58) { + return 26 + (codePoint - 48); + } + if (codePoint >= 65 && codePoint < 91) { + return codePoint - 65; + } + if (codePoint >= 97 && codePoint < 123) { + return codePoint - 97; + } + return base; + }; + var digitToBasic = function(digit, flag) { + return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5); + }; + var adapt = function(delta, numPoints, firstTime) { + let k = 0; + delta = firstTime ? floor(delta / damp) : delta >> 1; + delta += floor(delta / numPoints); + for (; delta > baseMinusTMin * tMax >> 1; k += base) { + delta = floor(delta / baseMinusTMin); + } + return floor(k + (baseMinusTMin + 1) * delta / (delta + skew)); + }; + var decode = function(input) { + const output = []; + const inputLength = input.length; + let i = 0; + let n = initialN; + let bias = initialBias; + let basic = input.lastIndexOf(delimiter); + if (basic < 0) { + basic = 0; + } + for (let j = 0; j < basic; ++j) { + if (input.charCodeAt(j) >= 128) { + error4("not-basic"); + } + output.push(input.charCodeAt(j)); + } + for (let index4 = basic > 0 ? basic + 1 : 0; index4 < inputLength; ) { + const oldi = i; + for (let w = 1, k = base; ; k += base) { + if (index4 >= inputLength) { + error4("invalid-input"); + } + const digit = basicToDigit(input.charCodeAt(index4++)); + if (digit >= base) { + error4("invalid-input"); + } + if (digit > floor((maxInt - i) / w)) { + error4("overflow"); + } + i += digit * w; + const t = k <= bias ? tMin : k >= bias + tMax ? tMax : k - bias; + if (digit < t) { + break; + } + const baseMinusT = base - t; + if (w > floor(maxInt / baseMinusT)) { + error4("overflow"); + } + w *= baseMinusT; + } + const out = output.length + 1; + bias = adapt(i - oldi, out, oldi == 0); + if (floor(i / out) > maxInt - n) { + error4("overflow"); + } + n += floor(i / out); + i %= out; + output.splice(i++, 0, n); + } + return String.fromCodePoint(...output); + }; + var encode = function(input) { + const output = []; + input = ucs2decode(input); + const inputLength = input.length; + let n = initialN; + let delta = 0; + let bias = initialBias; + for (const currentValue of input) { + if (currentValue < 128) { + output.push(stringFromCharCode(currentValue)); + } + } + const basicLength = output.length; + let handledCPCount = basicLength; + if (basicLength) { + output.push(delimiter); + } + while (handledCPCount < inputLength) { + let m = maxInt; + for (const currentValue of input) { + if (currentValue >= n && currentValue < m) { + m = currentValue; + } + } + const handledCPCountPlusOne = handledCPCount + 1; + if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) { + error4("overflow"); + } + delta += (m - n) * handledCPCountPlusOne; + n = m; + for (const currentValue of input) { + if (currentValue < n && ++delta > maxInt) { + error4("overflow"); + } + if (currentValue === n) { + let q = delta; + for (let k = base; ; k += base) { + const t = k <= bias ? tMin : k >= bias + tMax ? tMax : k - bias; + if (q < t) { + break; + } + const qMinusT = q - t; + const baseMinusT = base - t; + output.push( + stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0)) + ); + q = floor(qMinusT / baseMinusT); + } + output.push(stringFromCharCode(digitToBasic(q, 0))); + bias = adapt(delta, handledCPCountPlusOne, handledCPCount === basicLength); + delta = 0; + ++handledCPCount; + } + } + ++delta; + ++n; + } + return output.join(""); + }; + var toUnicode = function(input) { + return mapDomain(input, function(string11) { + return regexPunycode.test(string11) ? decode(string11.slice(4).toLowerCase()) : string11; + }); + }; + var toASCII = function(input) { + return mapDomain(input, function(string11) { + return regexNonASCII.test(string11) ? "xn--" + encode(string11) : string11; + }); + }; + var punycode = { + /** + * A string representing the current Punycode.js version number. + * @memberOf punycode + * @type String + */ + "version": "2.3.1", + /** + * An object of methods to convert from JavaScript's internal character + * representation (UCS-2) to Unicode code points, and back. + * @see + * @memberOf punycode + * @type Object + */ + "ucs2": { + "decode": ucs2decode, + "encode": ucs2encode + }, + "decode": decode, + "encode": encode, + "toASCII": toASCII, + "toUnicode": toUnicode + }; + module3.exports = punycode; + } +}); + +// node_modules/tr46/lib/regexes.js +var require_regexes = __commonJS({ + "node_modules/tr46/lib/regexes.js"(exports2, module3) { + "use strict"; + var combiningMarks = /[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11000}-\u{11002}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11082}\u{110B0}-\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{11134}\u{11145}\u{11146}\u{11173}\u{11180}-\u{11182}\u{111B3}-\u{111C0}\u{111C9}-\u{111CC}\u{111CE}\u{111CF}\u{1122C}-\u{11237}\u{1123E}\u{11241}\u{112DF}-\u{112EA}\u{11300}-\u{11303}\u{1133B}\u{1133C}\u{1133E}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11357}\u{11362}\u{11363}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113B8}-\u{113C0}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}-\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11435}-\u{11446}\u{1145E}\u{114B0}-\u{114C3}\u{115AF}-\u{115B5}\u{115B8}-\u{115C0}\u{115DC}\u{115DD}\u{11630}-\u{11640}\u{116AB}-\u{116B7}\u{1171D}-\u{1172B}\u{1182C}-\u{1183A}\u{11930}-\u{11935}\u{11937}\u{11938}\u{1193B}-\u{1193E}\u{11940}\u{11942}\u{11943}\u{119D1}-\u{119D7}\u{119DA}-\u{119E0}\u{119E4}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A39}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A5B}\u{11A8A}-\u{11A99}\u{11C2F}-\u{11C36}\u{11C38}-\u{11C3F}\u{11C92}-\u{11CA7}\u{11CA9}-\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D8A}-\u{11D8E}\u{11D90}\u{11D91}\u{11D93}-\u{11D97}\u{11EF3}-\u{11EF6}\u{11F00}\u{11F01}\u{11F03}\u{11F34}-\u{11F3A}\u{11F3E}-\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F51}-\u{16F87}\u{16F8F}-\u{16F92}\u{16FE4}\u{16FF0}\u{16FF1}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D165}-\u{1D169}\u{1D16D}-\u{1D172}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]/u; + var combiningClassVirama = /[\u094D\u09CD\u0A4D\u0ACD\u0B4D\u0BCD\u0C4D\u0CCD\u0D3B\u0D3C\u0D4D\u0DCA\u0E3A\u0EBA\u0F84\u1039\u103A\u1714\u1715\u1734\u17D2\u1A60\u1B44\u1BAA\u1BAB\u1BF2\u1BF3\u2D7F\uA806\uA82C\uA8C4\uA953\uA9C0\uAAF6\uABED\u{10A3F}\u{11046}\u{11070}\u{1107F}\u{110B9}\u{11133}\u{11134}\u{111C0}\u{11235}\u{112EA}\u{1134D}\u{113CE}-\u{113D0}\u{11442}\u{114C2}\u{115BF}\u{1163F}\u{116B6}\u{1172B}\u{11839}\u{1193D}\u{1193E}\u{119E0}\u{11A34}\u{11A47}\u{11A99}\u{11C3F}\u{11D44}\u{11D45}\u{11D97}\u{11F41}\u{11F42}\u{1612F}]/u; + var validZWNJ = /[\u0620\u0626\u0628\u062A-\u062E\u0633-\u063F\u0641-\u0647\u0649\u064A\u066E\u066F\u0678-\u0687\u069A-\u06BF\u06C1\u06C2\u06CC\u06CE\u06D0\u06D1\u06FA-\u06FC\u06FF\u0712-\u0714\u071A-\u071D\u071F-\u0727\u0729\u072B\u072D\u072E\u074E-\u0758\u075C-\u076A\u076D-\u0770\u0772\u0775-\u0777\u077A-\u077F\u07CA-\u07EA\u0841-\u0845\u0848\u084A-\u0853\u0855\u0860\u0862-\u0865\u0868\u0886\u0889-\u088D\u08A0-\u08A9\u08AF\u08B0\u08B3-\u08B8\u08BA-\u08C8\u1807\u1820-\u1878\u1887-\u18A8\u18AA\uA840-\uA872\u{10AC0}-\u{10AC4}\u{10ACD}\u{10AD3}-\u{10ADC}\u{10ADE}-\u{10AE0}\u{10AEB}-\u{10AEE}\u{10B80}\u{10B82}\u{10B86}-\u{10B88}\u{10B8A}\u{10B8B}\u{10B8D}\u{10B90}\u{10BAD}\u{10BAE}\u{10D00}-\u{10D21}\u{10D23}\u{10EC3}\u{10EC4}\u{10F30}-\u{10F32}\u{10F34}-\u{10F44}\u{10F51}-\u{10F53}\u{10F70}-\u{10F73}\u{10F76}-\u{10F81}\u{10FB0}\u{10FB2}\u{10FB3}\u{10FB8}\u{10FBB}\u{10FBC}\u{10FBE}\u{10FBF}\u{10FC1}\u{10FC4}\u{10FCA}\u{10FCB}\u{1E900}-\u{1E943}][\xAD\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u061C\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u070F\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC6\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200B\u200E\u200F\u202A-\u202E\u2060-\u2064\u206A-\u206F\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFEFF\uFFF9-\uFFFB\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C3F}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13430}-\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94B}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*\u200C[\xAD\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u061C\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u070F\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC6\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200B\u200E\u200F\u202A-\u202E\u2060-\u2064\u206A-\u206F\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFEFF\uFFF9-\uFFFB\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C3F}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13430}-\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94B}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*[\u0620\u0622-\u063F\u0641-\u064A\u066E\u066F\u0671-\u0673\u0675-\u06D3\u06D5\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u077F\u07CA-\u07EA\u0840-\u0858\u0860\u0862-\u0865\u0867-\u086A\u0870-\u0882\u0886\u0889-\u088E\u08A0-\u08AC\u08AE-\u08C8\u1807\u1820-\u1878\u1887-\u18A8\u18AA\uA840-\uA871\u{10AC0}-\u{10AC5}\u{10AC7}\u{10AC9}\u{10ACA}\u{10ACE}-\u{10AD6}\u{10AD8}-\u{10AE1}\u{10AE4}\u{10AEB}-\u{10AEF}\u{10B80}-\u{10B91}\u{10BA9}-\u{10BAE}\u{10D01}-\u{10D23}\u{10EC2}-\u{10EC4}\u{10F30}-\u{10F44}\u{10F51}-\u{10F54}\u{10F70}-\u{10F81}\u{10FB0}\u{10FB2}-\u{10FB6}\u{10FB8}-\u{10FBF}\u{10FC1}-\u{10FC4}\u{10FC9}\u{10FCA}\u{1E900}-\u{1E943}]/u; + var bidiDomain = /[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0600-\u0605\u0608\u060B\u060D\u061B-\u064A\u0660-\u0669\u066B-\u066F\u0671-\u06D5\u06DD\u06E5\u06E6\u06EE\u06EF\u06FA-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u08A0-\u08C9\u08E2\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}]/u; + var bidiS1LTR = /[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u02BB-\u02C1\u02D0\u02D1\u02E0-\u02E4\u02EE\u0370-\u0373\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0482\u048A-\u052F\u0531-\u0556\u0559-\u0589\u0903-\u0939\u093B\u093D-\u0940\u0949-\u094C\u094E-\u0950\u0958-\u0961\u0964-\u0980\u0982\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD-\u09C0\u09C7\u09C8\u09CB\u09CC\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09FA\u09FC\u09FD\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3E-\u0A40\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A76\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD-\u0AC0\u0AC9\u0ACB\u0ACC\u0AD0\u0AE0\u0AE1\u0AE6-\u0AF0\u0AF9\u0B02\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B3E\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0B57\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0BD0\u0BD7\u0BE6-\u0BF2\u0C01-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C41-\u0C44\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C77\u0C7F\u0C80\u0C82-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD-\u0CC4\u0CC6-\u0CC8\u0CCA\u0CCB\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D02-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D4E\u0D4F\u0D54-\u0D61\u0D66-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCF-\u0DD1\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E4F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F17\u0F1A-\u0F34\u0F36\u0F38\u0F3E-\u0F47\u0F49-\u0F6C\u0F7F\u0F85\u0F88-\u0F8C\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE-\u0FDA\u1000-\u102C\u1031\u1038\u103B\u103C\u103F-\u1057\u105A-\u105D\u1061-\u1070\u1075-\u1081\u1083\u1084\u1087-\u108C\u108E-\u109C\u109E-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1360-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u167F\u1681-\u169A\u16A0-\u16F8\u1700-\u1711\u1715\u171F-\u1731\u1734-\u1736\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17B6\u17BE-\u17C5\u17C7\u17C8\u17D4-\u17DA\u17DC\u17E0-\u17E9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A19\u1A1A\u1A1E-\u1A55\u1A57\u1A61\u1A63\u1A64\u1A6D-\u1A72\u1A80-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1B04-\u1B33\u1B35\u1B3B\u1B3D-\u1B41\u1B43-\u1B4C\u1B4E-\u1B6A\u1B74-\u1B7F\u1B82-\u1BA1\u1BA6\u1BA7\u1BAA\u1BAE-\u1BE5\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1BFC-\u1C2B\u1C34\u1C35\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD3\u1CE1\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5-\u1CF7\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200E\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u214F\u2160-\u2188\u2336-\u237A\u2395\u249C-\u24E9\u26AC\u2800-\u28FF\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u302E\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31BF\u31F0-\u321C\u3220-\u324F\u3260-\u327B\u327F-\u32B0\u32C0-\u32CB\u32D0-\u3376\u337B-\u33DD\u33E0-\u33FE\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA60C\uA610-\uA62B\uA640-\uA66E\uA680-\uA69D\uA6A0-\uA6EF\uA6F2-\uA6F7\uA722-\uA787\uA789-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA824\uA827\uA830-\uA837\uA840-\uA873\uA880-\uA8C3\uA8CE-\uA8D9\uA8F2-\uA8FE\uA900-\uA925\uA92E-\uA946\uA952\uA953\uA95F-\uA97C\uA983-\uA9B2\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA2F\uAA30\uAA33\uAA34\uAA40-\uAA42\uAA44-\uAA4B\uAA4D\uAA50-\uAA59\uAA5C-\uAA7B\uAA7D-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAAEB\uAAEE-\uAAF5\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB69\uAB70-\uABE4\uABE6\uABE7\uABE9-\uABEC\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1013F}\u{1018D}\u{1018E}\u{101D0}-\u{101FC}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{11000}\u{11002}-\u{11037}\u{11047}-\u{1104D}\u{11066}-\u{1106F}\u{11071}\u{11072}\u{11075}\u{11082}-\u{110B2}\u{110B7}\u{110B8}\u{110BB}-\u{110C1}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11103}-\u{11126}\u{1112C}\u{11136}-\u{11147}\u{11150}-\u{11172}\u{11174}-\u{11176}\u{11182}-\u{111B5}\u{111BF}-\u{111C8}\u{111CD}\u{111CE}\u{111D0}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{1122E}\u{11232}\u{11233}\u{11235}\u{11238}-\u{1123D}\u{1123F}\u{11240}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112DE}\u{112E0}-\u{112E2}\u{112F0}-\u{112F9}\u{11302}\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}-\u{1133F}\u{11341}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113BA}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}\u{113CD}\u{113CF}\u{113D1}\u{113D3}-\u{113D5}\u{113D7}\u{113D8}\u{11400}-\u{11437}\u{11440}\u{11441}\u{11445}\u{11447}-\u{1145B}\u{1145D}\u{1145F}-\u{11461}\u{11480}-\u{114B2}\u{114B9}\u{114BB}-\u{114BE}\u{114C1}\u{114C4}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B1}\u{115B8}-\u{115BB}\u{115BE}\u{115C1}-\u{115DB}\u{11600}-\u{11632}\u{1163B}\u{1163C}\u{1163E}\u{11641}-\u{11644}\u{11650}-\u{11659}\u{11680}-\u{116AA}\u{116AC}\u{116AE}\u{116AF}\u{116B6}\u{116B8}\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171E}\u{11720}\u{11721}\u{11726}\u{11730}-\u{11746}\u{11800}-\u{1182E}\u{11838}\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193D}\u{1193F}-\u{11942}\u{11944}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D3}\u{119DC}-\u{119DF}\u{119E1}-\u{119E4}\u{11A00}\u{11A07}\u{11A08}\u{11A0B}-\u{11A32}\u{11A39}\u{11A3A}\u{11A3F}-\u{11A46}\u{11A50}\u{11A57}\u{11A58}\u{11A5C}-\u{11A89}\u{11A97}\u{11A9A}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2F}\u{11C3E}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11CA9}\u{11CB1}\u{11CB4}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D93}\u{11D94}\u{11D96}\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF2}\u{11EF5}-\u{11EF8}\u{11F02}-\u{11F10}\u{11F12}-\u{11F35}\u{11F3E}\u{11F3F}\u{11F41}\u{11F43}-\u{11F59}\u{11FB0}\u{11FC0}-\u{11FD4}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{1343F}\u{13441}-\u{13446}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{1611D}\u{1612A}-\u{1612C}\u{16130}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF5}\u{16B00}-\u{16B2F}\u{16B37}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F50}-\u{16F87}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{16FE3}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}\u{1BC9F}\u{1CCD6}-\u{1CCEF}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D166}\u{1D16A}-\u{1D172}\u{1D183}\u{1D184}\u{1D18C}-\u{1D1A9}\u{1D1AE}-\u{1D1E8}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1D800}-\u{1D9FF}\u{1DA37}-\u{1DA3A}\u{1DA6D}-\u{1DA74}\u{1DA76}-\u{1DA83}\u{1DA85}-\u{1DA8B}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E030}-\u{1E06D}\u{1E100}-\u{1E12C}\u{1E137}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AD}\u{1E2C0}-\u{1E2EB}\u{1E2F0}-\u{1E2F9}\u{1E4D0}-\u{1E4EB}\u{1E4F0}-\u{1E4F9}\u{1E5D0}-\u{1E5ED}\u{1E5F0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1F110}-\u{1F12E}\u{1F130}-\u{1F169}\u{1F170}-\u{1F1AC}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}]/u; + var bidiS1RTL = /[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D4A}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}]/u; + var bidiS2 = /^[\0-\x08\x0E-\x1B!-@\[-`\{-\x84\x86-\xA9\xAB-\xB4\xB6-\xB9\xBB-\xBF\xD7\xF7\u02B9\u02BA\u02C2-\u02CF\u02D2-\u02DF\u02E5-\u02ED\u02EF-\u036F\u0374\u0375\u037E\u0384\u0385\u0387\u03F6\u0483-\u0489\u058A\u058D-\u058F\u0591-\u05C7\u05D0-\u05EA\u05EF-\u05F4\u0600-\u070D\u070F-\u074A\u074D-\u07B1\u07C0-\u07FA\u07FD-\u082D\u0830-\u083E\u0840-\u085B\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u0897-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09F2\u09F3\u09FB\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AF1\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0BF3-\u0BFA\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C78-\u0C7E\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E3F\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39-\u0F3D\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1390-\u1399\u1400\u169B\u169C\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DB\u17DD\u17F0-\u17F9\u1800-\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1940\u1944\u1945\u19DE-\u19FF\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u200B-\u200D\u200F-\u2027\u202F-\u205E\u2060-\u2064\u206A-\u2070\u2074-\u207E\u2080-\u208E\u20A0-\u20C0\u20D0-\u20F0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u2150-\u215F\u2189-\u218B\u2190-\u2335\u237B-\u2394\u2396-\u2429\u2440-\u244A\u2460-\u249B\u24EA-\u26AB\u26AD-\u27FF\u2900-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2CEF-\u2CF1\u2CF9-\u2CFF\u2D7F\u2DE0-\u2E5D\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3001-\u3004\u3008-\u3020\u302A-\u302D\u3030\u3036\u3037\u303D-\u303F\u3099-\u309C\u30A0\u30FB\u31C0-\u31E5\u31EF\u321D\u321E\u3250-\u325F\u327C-\u327E\u32B1-\u32BF\u32CC-\u32CF\u3377-\u337A\u33DE\u33DF\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA60D-\uA60F\uA66F-\uA67F\uA69E\uA69F\uA6F0\uA6F1\uA700-\uA721\uA788\uA802\uA806\uA80B\uA825\uA826\uA828-\uA82C\uA838\uA839\uA874-\uA877\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uAB6A\uAB6B\uABE5\uABE8\uABED\uFB1D-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD8F\uFD92-\uFDC7\uFDCF\uFDF0-\uFE19\uFE20-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFE70-\uFE74\uFE76-\uFEFC\uFEFF\uFF01-\uFF20\uFF3B-\uFF40\uFF5B-\uFF65\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFF9-\uFFFD\u{10101}\u{10140}-\u{1018C}\u{10190}-\u{1019C}\u{101A0}\u{101FD}\u{102E0}-\u{102FB}\u{10376}-\u{1037A}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{1091F}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A38}-\u{10A3A}\u{10A3F}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE6}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B39}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D27}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D69}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAB}-\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10EFC}-\u{10F27}\u{10F30}-\u{10F59}\u{10F70}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{11001}\u{11038}-\u{11046}\u{11052}-\u{11065}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{11660}-\u{1166C}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{11FD5}-\u{11FF1}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE2}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CC00}-\u{1CCD5}\u{1CCF0}-\u{1CCF9}\u{1CD00}-\u{1CEB3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D1E9}\u{1D1EA}\u{1D200}-\u{1D245}\u{1D300}-\u{1D356}\u{1D6C1}\u{1D6DB}\u{1D6FB}\u{1D715}\u{1D735}\u{1D74F}\u{1D76F}\u{1D789}\u{1D7A9}\u{1D7C3}\u{1D7CE}-\u{1D7FF}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E2FF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8D6}\u{1E900}-\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{1EEF0}\u{1EEF1}\u{1F000}-\u{1F02B}\u{1F030}-\u{1F093}\u{1F0A0}-\u{1F0AE}\u{1F0B1}-\u{1F0BF}\u{1F0C1}-\u{1F0CF}\u{1F0D1}-\u{1F0F5}\u{1F100}-\u{1F10F}\u{1F12F}\u{1F16A}-\u{1F16F}\u{1F1AD}\u{1F260}-\u{1F265}\u{1F300}-\u{1F6D7}\u{1F6DC}-\u{1F6EC}\u{1F6F0}-\u{1F6FC}\u{1F700}-\u{1F776}\u{1F77B}-\u{1F7D9}\u{1F7E0}-\u{1F7EB}\u{1F7F0}\u{1F800}-\u{1F80B}\u{1F810}-\u{1F847}\u{1F850}-\u{1F859}\u{1F860}-\u{1F887}\u{1F890}-\u{1F8AD}\u{1F8B0}-\u{1F8BB}\u{1F8C0}\u{1F8C1}\u{1F900}-\u{1FA53}\u{1FA60}-\u{1FA6D}\u{1FA70}-\u{1FA7C}\u{1FA80}-\u{1FA89}\u{1FA8F}-\u{1FAC6}\u{1FACE}-\u{1FADC}\u{1FADF}-\u{1FAE9}\u{1FAF0}-\u{1FAF8}\u{1FB00}-\u{1FB92}\u{1FB94}-\u{1FBF9}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*$/u; + var bidiS3 = /[0-9\xB2\xB3\xB9\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0600-\u0605\u0608\u060B\u060D\u061B-\u064A\u0660-\u0669\u066B-\u066F\u0671-\u06D5\u06DD\u06E5\u06E6\u06EE-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u08A0-\u08C9\u08E2\u200F\u2070\u2074-\u2079\u2080-\u2089\u2488-\u249B\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\u{102E1}-\u{102FB}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1CCF0}-\u{1CCF9}\u{1D7CE}-\u{1D7FF}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{1F100}-\u{1F10A}\u{1FBF0}-\u{1FBF9}][\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]*$/u; + var bidiS4EN = /[0-9\xB2\xB3\xB9\u06F0-\u06F9\u2070\u2074-\u2079\u2080-\u2089\u2488-\u249B\uFF10-\uFF19\u{102E1}-\u{102FB}\u{1CCF0}-\u{1CCF9}\u{1D7CE}-\u{1D7FF}\u{1F100}-\u{1F10A}\u{1FBF0}-\u{1FBF9}]/u; + var bidiS4AN = /[\u0600-\u0605\u0660-\u0669\u066B\u066C\u06DD\u0890\u0891\u08E2\u{10D30}-\u{10D39}\u{10D40}-\u{10D49}\u{10E60}-\u{10E7E}]/u; + var bidiS5 = /^[\0-\x08\x0E-\x1B!-\x84\x86-\u0377\u037A-\u037F\u0384-\u038A\u038C\u038E-\u03A1\u03A3-\u052F\u0531-\u0556\u0559-\u058A\u058D-\u058F\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0606\u0607\u0609\u060A\u060C\u060E-\u061A\u064B-\u065F\u066A\u0670\u06D6-\u06DC\u06DE-\u06E4\u06E7-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07F6-\u07F9\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09FE\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A76\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AF1\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B77\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BFA\u0C00-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3C-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C5D\u0C60-\u0C63\u0C66-\u0C6F\u0C77-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D00-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4F\u0D54-\u0D63\u0D66-\u0D7F\u0D81-\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E3A\u0E3F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECE\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F47\u0F49-\u0F6C\u0F71-\u0F97\u0F99-\u0FBC\u0FBE-\u0FCC\u0FCE-\u0FDA\u1000-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u137C\u1380-\u1399\u13A0-\u13F5\u13F8-\u13FD\u1400-\u167F\u1681-\u169C\u16A0-\u16F8\u1700-\u1715\u171F-\u1736\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17DD\u17E0-\u17E9\u17F0-\u17F9\u1800-\u1819\u1820-\u1878\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1940\u1944-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u19DE-\u1A1B\u1A1E-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1AB0-\u1ACE\u1B00-\u1B4C\u1B4E-\u1BF3\u1BFC-\u1C37\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD0-\u1CFA\u1D00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FC4\u1FC6-\u1FD3\u1FD6-\u1FDB\u1FDD-\u1FEF\u1FF2-\u1FF4\u1FF6-\u1FFE\u200B-\u200E\u2010-\u2027\u202F-\u205E\u2060-\u2064\u206A-\u2071\u2074-\u208E\u2090-\u209C\u20A0-\u20C0\u20D0-\u20F0\u2100-\u218B\u2190-\u2429\u2440-\u244A\u2460-\u2B73\u2B76-\u2B95\u2B97-\u2CF3\u2CF9-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2E5D\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3001-\u303F\u3041-\u3096\u3099-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31E5\u31EF-\u321E\u3220-\uA48C\uA490-\uA4C6\uA4D0-\uA62B\uA640-\uA6F7\uA700-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA82C\uA830-\uA839\uA840-\uA877\uA880-\uA8C5\uA8CE-\uA8D9\uA8E0-\uA953\uA95F-\uA97C\uA980-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA5C-\uAAC2\uAADB-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB6B\uAB70-\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1E\uFB29\uFD3E-\uFD4F\uFDCF\uFDFD-\uFE19\uFE20-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFEFF\uFF01-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFF9-\uFFFD\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}-\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1018E}\u{10190}-\u{1019C}\u{101A0}\u{101D0}-\u{101FD}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{102E0}-\u{102FB}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{1037A}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{1091F}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10B39}-\u{10B3F}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6E}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11000}-\u{1104D}\u{11052}-\u{11075}\u{1107F}-\u{110C2}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11100}-\u{11134}\u{11136}-\u{11147}\u{11150}-\u{11176}\u{11180}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{11241}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112EA}\u{112F0}-\u{112F9}\u{11300}-\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133B}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113C0}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}-\u{113D5}\u{113D7}\u{113D8}\u{113E1}\u{113E2}\u{11400}-\u{1145B}\u{1145D}-\u{11461}\u{11480}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B5}\u{115B8}-\u{115DD}\u{11600}-\u{11644}\u{11650}-\u{11659}\u{11660}-\u{1166C}\u{11680}-\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171D}-\u{1172B}\u{11730}-\u{11746}\u{11800}-\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193B}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D7}\u{119DA}-\u{119E4}\u{11A00}-\u{11A47}\u{11A50}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C36}\u{11C38}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11C92}-\u{11CA7}\u{11CA9}-\u{11CB6}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D47}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D90}\u{11D91}\u{11D93}-\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF8}\u{11F00}-\u{11F10}\u{11F12}-\u{11F3A}\u{11F3E}-\u{11F5A}\u{11FB0}\u{11FC0}-\u{11FF1}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{13455}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF0}-\u{16AF5}\u{16B00}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F4F}-\u{16F87}\u{16F8F}-\u{16F9F}\u{16FE0}-\u{16FE4}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}-\u{1BCA3}\u{1CC00}-\u{1CCF9}\u{1CD00}-\u{1CEB3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D1EA}\u{1D200}-\u{1D245}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D300}-\u{1D356}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D7CB}\u{1D7CE}-\u{1DA8B}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E030}-\u{1E06D}\u{1E08F}\u{1E100}-\u{1E12C}\u{1E130}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AE}\u{1E2C0}-\u{1E2F9}\u{1E2FF}\u{1E4D0}-\u{1E4F9}\u{1E5D0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{1EEF0}\u{1EEF1}\u{1F000}-\u{1F02B}\u{1F030}-\u{1F093}\u{1F0A0}-\u{1F0AE}\u{1F0B1}-\u{1F0BF}\u{1F0C1}-\u{1F0CF}\u{1F0D1}-\u{1F0F5}\u{1F100}-\u{1F1AD}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{1F260}-\u{1F265}\u{1F300}-\u{1F6D7}\u{1F6DC}-\u{1F6EC}\u{1F6F0}-\u{1F6FC}\u{1F700}-\u{1F776}\u{1F77B}-\u{1F7D9}\u{1F7E0}-\u{1F7EB}\u{1F7F0}\u{1F800}-\u{1F80B}\u{1F810}-\u{1F847}\u{1F850}-\u{1F859}\u{1F860}-\u{1F887}\u{1F890}-\u{1F8AD}\u{1F8B0}-\u{1F8BB}\u{1F8C0}\u{1F8C1}\u{1F900}-\u{1FA53}\u{1FA60}-\u{1FA6D}\u{1FA70}-\u{1FA7C}\u{1FA80}-\u{1FA89}\u{1FA8F}-\u{1FAC6}\u{1FACE}-\u{1FADC}\u{1FADF}-\u{1FAE9}\u{1FAF0}-\u{1FAF8}\u{1FB00}-\u{1FB92}\u{1FB94}-\u{1FBF9}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}]*$/u; + var bidiS6 = /[0-9A-Za-z\xAA\xB2\xB3\xB5\xB9\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u02BB-\u02C1\u02D0\u02D1\u02E0-\u02E4\u02EE\u0370-\u0373\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0482\u048A-\u052F\u0531-\u0556\u0559-\u0589\u06F0-\u06F9\u0903-\u0939\u093B\u093D-\u0940\u0949-\u094C\u094E-\u0950\u0958-\u0961\u0964-\u0980\u0982\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD-\u09C0\u09C7\u09C8\u09CB\u09CC\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09FA\u09FC\u09FD\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3E-\u0A40\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A76\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD-\u0AC0\u0AC9\u0ACB\u0ACC\u0AD0\u0AE0\u0AE1\u0AE6-\u0AF0\u0AF9\u0B02\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B3E\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0B57\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0BD0\u0BD7\u0BE6-\u0BF2\u0C01-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C41-\u0C44\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C77\u0C7F\u0C80\u0C82-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD-\u0CC4\u0CC6-\u0CC8\u0CCA\u0CCB\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D02-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D4E\u0D4F\u0D54-\u0D61\u0D66-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCF-\u0DD1\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E4F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F17\u0F1A-\u0F34\u0F36\u0F38\u0F3E-\u0F47\u0F49-\u0F6C\u0F7F\u0F85\u0F88-\u0F8C\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE-\u0FDA\u1000-\u102C\u1031\u1038\u103B\u103C\u103F-\u1057\u105A-\u105D\u1061-\u1070\u1075-\u1081\u1083\u1084\u1087-\u108C\u108E-\u109C\u109E-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1360-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u167F\u1681-\u169A\u16A0-\u16F8\u1700-\u1711\u1715\u171F-\u1731\u1734-\u1736\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17B6\u17BE-\u17C5\u17C7\u17C8\u17D4-\u17DA\u17DC\u17E0-\u17E9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A19\u1A1A\u1A1E-\u1A55\u1A57\u1A61\u1A63\u1A64\u1A6D-\u1A72\u1A80-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1B04-\u1B33\u1B35\u1B3B\u1B3D-\u1B41\u1B43-\u1B4C\u1B4E-\u1B6A\u1B74-\u1B7F\u1B82-\u1BA1\u1BA6\u1BA7\u1BAA\u1BAE-\u1BE5\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1BFC-\u1C2B\u1C34\u1C35\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD3\u1CE1\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5-\u1CF7\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200E\u2070\u2071\u2074-\u2079\u207F-\u2089\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u214F\u2160-\u2188\u2336-\u237A\u2395\u2488-\u24E9\u26AC\u2800-\u28FF\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u302E\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31BF\u31F0-\u321C\u3220-\u324F\u3260-\u327B\u327F-\u32B0\u32C0-\u32CB\u32D0-\u3376\u337B-\u33DD\u33E0-\u33FE\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA60C\uA610-\uA62B\uA640-\uA66E\uA680-\uA69D\uA6A0-\uA6EF\uA6F2-\uA6F7\uA722-\uA787\uA789-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA824\uA827\uA830-\uA837\uA840-\uA873\uA880-\uA8C3\uA8CE-\uA8D9\uA8F2-\uA8FE\uA900-\uA925\uA92E-\uA946\uA952\uA953\uA95F-\uA97C\uA983-\uA9B2\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA2F\uAA30\uAA33\uAA34\uAA40-\uAA42\uAA44-\uAA4B\uAA4D\uAA50-\uAA59\uAA5C-\uAA7B\uAA7D-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAAEB\uAAEE-\uAAF5\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB69\uAB70-\uABE4\uABE6\uABE7\uABE9-\uABEC\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1013F}\u{1018D}\u{1018E}\u{101D0}-\u{101FC}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{102E1}-\u{102FB}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{11000}\u{11002}-\u{11037}\u{11047}-\u{1104D}\u{11066}-\u{1106F}\u{11071}\u{11072}\u{11075}\u{11082}-\u{110B2}\u{110B7}\u{110B8}\u{110BB}-\u{110C1}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11103}-\u{11126}\u{1112C}\u{11136}-\u{11147}\u{11150}-\u{11172}\u{11174}-\u{11176}\u{11182}-\u{111B5}\u{111BF}-\u{111C8}\u{111CD}\u{111CE}\u{111D0}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{1122E}\u{11232}\u{11233}\u{11235}\u{11238}-\u{1123D}\u{1123F}\u{11240}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112DE}\u{112E0}-\u{112E2}\u{112F0}-\u{112F9}\u{11302}\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}-\u{1133F}\u{11341}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113BA}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}\u{113CD}\u{113CF}\u{113D1}\u{113D3}-\u{113D5}\u{113D7}\u{113D8}\u{11400}-\u{11437}\u{11440}\u{11441}\u{11445}\u{11447}-\u{1145B}\u{1145D}\u{1145F}-\u{11461}\u{11480}-\u{114B2}\u{114B9}\u{114BB}-\u{114BE}\u{114C1}\u{114C4}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B1}\u{115B8}-\u{115BB}\u{115BE}\u{115C1}-\u{115DB}\u{11600}-\u{11632}\u{1163B}\u{1163C}\u{1163E}\u{11641}-\u{11644}\u{11650}-\u{11659}\u{11680}-\u{116AA}\u{116AC}\u{116AE}\u{116AF}\u{116B6}\u{116B8}\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171E}\u{11720}\u{11721}\u{11726}\u{11730}-\u{11746}\u{11800}-\u{1182E}\u{11838}\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193D}\u{1193F}-\u{11942}\u{11944}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D3}\u{119DC}-\u{119DF}\u{119E1}-\u{119E4}\u{11A00}\u{11A07}\u{11A08}\u{11A0B}-\u{11A32}\u{11A39}\u{11A3A}\u{11A3F}-\u{11A46}\u{11A50}\u{11A57}\u{11A58}\u{11A5C}-\u{11A89}\u{11A97}\u{11A9A}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2F}\u{11C3E}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11CA9}\u{11CB1}\u{11CB4}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D93}\u{11D94}\u{11D96}\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF2}\u{11EF5}-\u{11EF8}\u{11F02}-\u{11F10}\u{11F12}-\u{11F35}\u{11F3E}\u{11F3F}\u{11F41}\u{11F43}-\u{11F59}\u{11FB0}\u{11FC0}-\u{11FD4}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{1343F}\u{13441}-\u{13446}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{1611D}\u{1612A}-\u{1612C}\u{16130}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF5}\u{16B00}-\u{16B2F}\u{16B37}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F50}-\u{16F87}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{16FE3}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}\u{1BC9F}\u{1CCD6}-\u{1CCF9}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D166}\u{1D16A}-\u{1D172}\u{1D183}\u{1D184}\u{1D18C}-\u{1D1A9}\u{1D1AE}-\u{1D1E8}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1D7CE}-\u{1D9FF}\u{1DA37}-\u{1DA3A}\u{1DA6D}-\u{1DA74}\u{1DA76}-\u{1DA83}\u{1DA85}-\u{1DA8B}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E030}-\u{1E06D}\u{1E100}-\u{1E12C}\u{1E137}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AD}\u{1E2C0}-\u{1E2EB}\u{1E2F0}-\u{1E2F9}\u{1E4D0}-\u{1E4EB}\u{1E4F0}-\u{1E4F9}\u{1E5D0}-\u{1E5ED}\u{1E5F0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1F100}-\u{1F10A}\u{1F110}-\u{1F12E}\u{1F130}-\u{1F169}\u{1F170}-\u{1F1AC}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{1FBF0}-\u{1FBF9}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}][\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]*$/u; + module3.exports = { + combiningMarks, + combiningClassVirama, + validZWNJ, + bidiDomain, + bidiS1LTR, + bidiS1RTL, + bidiS2, + bidiS3, + bidiS4EN, + bidiS4AN, + bidiS5, + bidiS6 + }; + } +}); + +// node_modules/tr46/lib/mappingTable.json +var require_mappingTable = __commonJS({ + "node_modules/tr46/lib/mappingTable.json"(exports2, module3) { + module3.exports = [[[0, 44], 2], [[45, 46], 2], [47, 2], [[48, 57], 2], [[58, 64], 2], [65, 1, "a"], [66, 1, "b"], [67, 1, "c"], [68, 1, "d"], [69, 1, "e"], [70, 1, "f"], [71, 1, "g"], [72, 1, "h"], [73, 1, "i"], [74, 1, "j"], [75, 1, "k"], [76, 1, "l"], [77, 1, "m"], [78, 1, "n"], [79, 1, "o"], [80, 1, "p"], [81, 1, "q"], [82, 1, "r"], [83, 1, "s"], [84, 1, "t"], [85, 1, "u"], [86, 1, "v"], [87, 1, "w"], [88, 1, "x"], [89, 1, "y"], [90, 1, "z"], [[91, 96], 2], [[97, 122], 2], [[123, 127], 2], [[128, 159], 3], [160, 1, " "], [[161, 167], 2], [168, 1, " \u0308"], [169, 2], [170, 1, "a"], [[171, 172], 2], [173, 7], [174, 2], [175, 1, " \u0304"], [[176, 177], 2], [178, 1, "2"], [179, 1, "3"], [180, 1, " \u0301"], [181, 1, "\u03BC"], [182, 2], [183, 2], [184, 1, " \u0327"], [185, 1, "1"], [186, 1, "o"], [187, 2], [188, 1, "1\u20444"], [189, 1, "1\u20442"], [190, 1, "3\u20444"], [191, 2], [192, 1, "\xE0"], [193, 1, "\xE1"], [194, 1, "\xE2"], [195, 1, "\xE3"], [196, 1, "\xE4"], [197, 1, "\xE5"], [198, 1, "\xE6"], [199, 1, "\xE7"], [200, 1, "\xE8"], [201, 1, "\xE9"], [202, 1, "\xEA"], [203, 1, "\xEB"], [204, 1, "\xEC"], [205, 1, "\xED"], [206, 1, "\xEE"], [207, 1, "\xEF"], [208, 1, "\xF0"], [209, 1, "\xF1"], [210, 1, "\xF2"], [211, 1, "\xF3"], [212, 1, "\xF4"], [213, 1, "\xF5"], [214, 1, "\xF6"], [215, 2], [216, 1, "\xF8"], [217, 1, "\xF9"], [218, 1, "\xFA"], [219, 1, "\xFB"], [220, 1, "\xFC"], [221, 1, "\xFD"], [222, 1, "\xFE"], [223, 6, "ss"], [[224, 246], 2], [247, 2], [[248, 255], 2], [256, 1, "\u0101"], [257, 2], [258, 1, "\u0103"], [259, 2], [260, 1, "\u0105"], [261, 2], [262, 1, "\u0107"], [263, 2], [264, 1, "\u0109"], [265, 2], [266, 1, "\u010B"], [267, 2], [268, 1, "\u010D"], [269, 2], [270, 1, "\u010F"], [271, 2], [272, 1, "\u0111"], [273, 2], [274, 1, "\u0113"], [275, 2], [276, 1, "\u0115"], [277, 2], [278, 1, "\u0117"], [279, 2], [280, 1, "\u0119"], [281, 2], [282, 1, "\u011B"], [283, 2], [284, 1, "\u011D"], [285, 2], [286, 1, "\u011F"], [287, 2], [288, 1, "\u0121"], [289, 2], [290, 1, "\u0123"], [291, 2], [292, 1, "\u0125"], [293, 2], [294, 1, "\u0127"], [295, 2], [296, 1, "\u0129"], [297, 2], [298, 1, "\u012B"], [299, 2], [300, 1, "\u012D"], [301, 2], [302, 1, "\u012F"], [303, 2], [304, 1, "i\u0307"], [305, 2], [[306, 307], 1, "ij"], [308, 1, "\u0135"], [309, 2], [310, 1, "\u0137"], [[311, 312], 2], [313, 1, "\u013A"], [314, 2], [315, 1, "\u013C"], [316, 2], [317, 1, "\u013E"], [318, 2], [[319, 320], 1, "l\xB7"], [321, 1, "\u0142"], [322, 2], [323, 1, "\u0144"], [324, 2], [325, 1, "\u0146"], [326, 2], [327, 1, "\u0148"], [328, 2], [329, 1, "\u02BCn"], [330, 1, "\u014B"], [331, 2], [332, 1, "\u014D"], [333, 2], [334, 1, "\u014F"], [335, 2], [336, 1, "\u0151"], [337, 2], [338, 1, "\u0153"], [339, 2], [340, 1, "\u0155"], [341, 2], [342, 1, "\u0157"], [343, 2], [344, 1, "\u0159"], [345, 2], [346, 1, "\u015B"], [347, 2], [348, 1, "\u015D"], [349, 2], [350, 1, "\u015F"], [351, 2], [352, 1, "\u0161"], [353, 2], [354, 1, "\u0163"], [355, 2], [356, 1, "\u0165"], [357, 2], [358, 1, "\u0167"], [359, 2], [360, 1, "\u0169"], [361, 2], [362, 1, "\u016B"], [363, 2], [364, 1, "\u016D"], [365, 2], [366, 1, "\u016F"], [367, 2], [368, 1, "\u0171"], [369, 2], [370, 1, "\u0173"], [371, 2], [372, 1, "\u0175"], [373, 2], [374, 1, "\u0177"], [375, 2], [376, 1, "\xFF"], [377, 1, "\u017A"], [378, 2], [379, 1, "\u017C"], [380, 2], [381, 1, "\u017E"], [382, 2], [383, 1, "s"], [384, 2], [385, 1, "\u0253"], [386, 1, "\u0183"], [387, 2], [388, 1, "\u0185"], [389, 2], [390, 1, "\u0254"], [391, 1, "\u0188"], [392, 2], [393, 1, "\u0256"], [394, 1, "\u0257"], [395, 1, "\u018C"], [[396, 397], 2], [398, 1, "\u01DD"], [399, 1, "\u0259"], [400, 1, "\u025B"], [401, 1, "\u0192"], [402, 2], [403, 1, "\u0260"], [404, 1, "\u0263"], [405, 2], [406, 1, "\u0269"], [407, 1, "\u0268"], [408, 1, "\u0199"], [[409, 411], 2], [412, 1, "\u026F"], [413, 1, "\u0272"], [414, 2], [415, 1, "\u0275"], [416, 1, "\u01A1"], [417, 2], [418, 1, "\u01A3"], [419, 2], [420, 1, "\u01A5"], [421, 2], [422, 1, "\u0280"], [423, 1, "\u01A8"], [424, 2], [425, 1, "\u0283"], [[426, 427], 2], [428, 1, "\u01AD"], [429, 2], [430, 1, "\u0288"], [431, 1, "\u01B0"], [432, 2], [433, 1, "\u028A"], [434, 1, "\u028B"], [435, 1, "\u01B4"], [436, 2], [437, 1, "\u01B6"], [438, 2], [439, 1, "\u0292"], [440, 1, "\u01B9"], [[441, 443], 2], [444, 1, "\u01BD"], [[445, 451], 2], [[452, 454], 1, "d\u017E"], [[455, 457], 1, "lj"], [[458, 460], 1, "nj"], [461, 1, "\u01CE"], [462, 2], [463, 1, "\u01D0"], [464, 2], [465, 1, "\u01D2"], [466, 2], [467, 1, "\u01D4"], [468, 2], [469, 1, "\u01D6"], [470, 2], [471, 1, "\u01D8"], [472, 2], [473, 1, "\u01DA"], [474, 2], [475, 1, "\u01DC"], [[476, 477], 2], [478, 1, "\u01DF"], [479, 2], [480, 1, "\u01E1"], [481, 2], [482, 1, "\u01E3"], [483, 2], [484, 1, "\u01E5"], [485, 2], [486, 1, "\u01E7"], [487, 2], [488, 1, "\u01E9"], [489, 2], [490, 1, "\u01EB"], [491, 2], [492, 1, "\u01ED"], [493, 2], [494, 1, "\u01EF"], [[495, 496], 2], [[497, 499], 1, "dz"], [500, 1, "\u01F5"], [501, 2], [502, 1, "\u0195"], [503, 1, "\u01BF"], [504, 1, "\u01F9"], [505, 2], [506, 1, "\u01FB"], [507, 2], [508, 1, "\u01FD"], [509, 2], [510, 1, "\u01FF"], [511, 2], [512, 1, "\u0201"], [513, 2], [514, 1, "\u0203"], [515, 2], [516, 1, "\u0205"], [517, 2], [518, 1, "\u0207"], [519, 2], [520, 1, "\u0209"], [521, 2], [522, 1, "\u020B"], [523, 2], [524, 1, "\u020D"], [525, 2], [526, 1, "\u020F"], [527, 2], [528, 1, "\u0211"], [529, 2], [530, 1, "\u0213"], [531, 2], [532, 1, "\u0215"], [533, 2], [534, 1, "\u0217"], [535, 2], [536, 1, "\u0219"], [537, 2], [538, 1, "\u021B"], [539, 2], [540, 1, "\u021D"], [541, 2], [542, 1, "\u021F"], [543, 2], [544, 1, "\u019E"], [545, 2], [546, 1, "\u0223"], [547, 2], [548, 1, "\u0225"], [549, 2], [550, 1, "\u0227"], [551, 2], [552, 1, "\u0229"], [553, 2], [554, 1, "\u022B"], [555, 2], [556, 1, "\u022D"], [557, 2], [558, 1, "\u022F"], [559, 2], [560, 1, "\u0231"], [561, 2], [562, 1, "\u0233"], [563, 2], [[564, 566], 2], [[567, 569], 2], [570, 1, "\u2C65"], [571, 1, "\u023C"], [572, 2], [573, 1, "\u019A"], [574, 1, "\u2C66"], [[575, 576], 2], [577, 1, "\u0242"], [578, 2], [579, 1, "\u0180"], [580, 1, "\u0289"], [581, 1, "\u028C"], [582, 1, "\u0247"], [583, 2], [584, 1, "\u0249"], [585, 2], [586, 1, "\u024B"], [587, 2], [588, 1, "\u024D"], [589, 2], [590, 1, "\u024F"], [591, 2], [[592, 680], 2], [[681, 685], 2], [[686, 687], 2], [688, 1, "h"], [689, 1, "\u0266"], [690, 1, "j"], [691, 1, "r"], [692, 1, "\u0279"], [693, 1, "\u027B"], [694, 1, "\u0281"], [695, 1, "w"], [696, 1, "y"], [[697, 705], 2], [[706, 709], 2], [[710, 721], 2], [[722, 727], 2], [728, 1, " \u0306"], [729, 1, " \u0307"], [730, 1, " \u030A"], [731, 1, " \u0328"], [732, 1, " \u0303"], [733, 1, " \u030B"], [734, 2], [735, 2], [736, 1, "\u0263"], [737, 1, "l"], [738, 1, "s"], [739, 1, "x"], [740, 1, "\u0295"], [[741, 745], 2], [[746, 747], 2], [748, 2], [749, 2], [750, 2], [[751, 767], 2], [[768, 831], 2], [832, 1, "\u0300"], [833, 1, "\u0301"], [834, 2], [835, 1, "\u0313"], [836, 1, "\u0308\u0301"], [837, 1, "\u03B9"], [[838, 846], 2], [847, 7], [[848, 855], 2], [[856, 860], 2], [[861, 863], 2], [[864, 865], 2], [866, 2], [[867, 879], 2], [880, 1, "\u0371"], [881, 2], [882, 1, "\u0373"], [883, 2], [884, 1, "\u02B9"], [885, 2], [886, 1, "\u0377"], [887, 2], [[888, 889], 3], [890, 1, " \u03B9"], [[891, 893], 2], [894, 1, ";"], [895, 1, "\u03F3"], [[896, 899], 3], [900, 1, " \u0301"], [901, 1, " \u0308\u0301"], [902, 1, "\u03AC"], [903, 1, "\xB7"], [904, 1, "\u03AD"], [905, 1, "\u03AE"], [906, 1, "\u03AF"], [907, 3], [908, 1, "\u03CC"], [909, 3], [910, 1, "\u03CD"], [911, 1, "\u03CE"], [912, 2], [913, 1, "\u03B1"], [914, 1, "\u03B2"], [915, 1, "\u03B3"], [916, 1, "\u03B4"], [917, 1, "\u03B5"], [918, 1, "\u03B6"], [919, 1, "\u03B7"], [920, 1, "\u03B8"], [921, 1, "\u03B9"], [922, 1, "\u03BA"], [923, 1, "\u03BB"], [924, 1, "\u03BC"], [925, 1, "\u03BD"], [926, 1, "\u03BE"], [927, 1, "\u03BF"], [928, 1, "\u03C0"], [929, 1, "\u03C1"], [930, 3], [931, 1, "\u03C3"], [932, 1, "\u03C4"], [933, 1, "\u03C5"], [934, 1, "\u03C6"], [935, 1, "\u03C7"], [936, 1, "\u03C8"], [937, 1, "\u03C9"], [938, 1, "\u03CA"], [939, 1, "\u03CB"], [[940, 961], 2], [962, 6, "\u03C3"], [[963, 974], 2], [975, 1, "\u03D7"], [976, 1, "\u03B2"], [977, 1, "\u03B8"], [978, 1, "\u03C5"], [979, 1, "\u03CD"], [980, 1, "\u03CB"], [981, 1, "\u03C6"], [982, 1, "\u03C0"], [983, 2], [984, 1, "\u03D9"], [985, 2], [986, 1, "\u03DB"], [987, 2], [988, 1, "\u03DD"], [989, 2], [990, 1, "\u03DF"], [991, 2], [992, 1, "\u03E1"], [993, 2], [994, 1, "\u03E3"], [995, 2], [996, 1, "\u03E5"], [997, 2], [998, 1, "\u03E7"], [999, 2], [1e3, 1, "\u03E9"], [1001, 2], [1002, 1, "\u03EB"], [1003, 2], [1004, 1, "\u03ED"], [1005, 2], [1006, 1, "\u03EF"], [1007, 2], [1008, 1, "\u03BA"], [1009, 1, "\u03C1"], [1010, 1, "\u03C3"], [1011, 2], [1012, 1, "\u03B8"], [1013, 1, "\u03B5"], [1014, 2], [1015, 1, "\u03F8"], [1016, 2], [1017, 1, "\u03C3"], [1018, 1, "\u03FB"], [1019, 2], [1020, 2], [1021, 1, "\u037B"], [1022, 1, "\u037C"], [1023, 1, "\u037D"], [1024, 1, "\u0450"], [1025, 1, "\u0451"], [1026, 1, "\u0452"], [1027, 1, "\u0453"], [1028, 1, "\u0454"], [1029, 1, "\u0455"], [1030, 1, "\u0456"], [1031, 1, "\u0457"], [1032, 1, "\u0458"], [1033, 1, "\u0459"], [1034, 1, "\u045A"], [1035, 1, "\u045B"], [1036, 1, "\u045C"], [1037, 1, "\u045D"], [1038, 1, "\u045E"], [1039, 1, "\u045F"], [1040, 1, "\u0430"], [1041, 1, "\u0431"], [1042, 1, "\u0432"], [1043, 1, "\u0433"], [1044, 1, "\u0434"], [1045, 1, "\u0435"], [1046, 1, "\u0436"], [1047, 1, "\u0437"], [1048, 1, "\u0438"], [1049, 1, "\u0439"], [1050, 1, "\u043A"], [1051, 1, "\u043B"], [1052, 1, "\u043C"], [1053, 1, "\u043D"], [1054, 1, "\u043E"], [1055, 1, "\u043F"], [1056, 1, "\u0440"], [1057, 1, "\u0441"], [1058, 1, "\u0442"], [1059, 1, "\u0443"], [1060, 1, "\u0444"], [1061, 1, "\u0445"], [1062, 1, "\u0446"], [1063, 1, "\u0447"], [1064, 1, "\u0448"], [1065, 1, "\u0449"], [1066, 1, "\u044A"], [1067, 1, "\u044B"], [1068, 1, "\u044C"], [1069, 1, "\u044D"], [1070, 1, "\u044E"], [1071, 1, "\u044F"], [[1072, 1103], 2], [1104, 2], [[1105, 1116], 2], [1117, 2], [[1118, 1119], 2], [1120, 1, "\u0461"], [1121, 2], [1122, 1, "\u0463"], [1123, 2], [1124, 1, "\u0465"], [1125, 2], [1126, 1, "\u0467"], [1127, 2], [1128, 1, "\u0469"], [1129, 2], [1130, 1, "\u046B"], [1131, 2], [1132, 1, "\u046D"], [1133, 2], [1134, 1, "\u046F"], [1135, 2], [1136, 1, "\u0471"], [1137, 2], [1138, 1, "\u0473"], [1139, 2], [1140, 1, "\u0475"], [1141, 2], [1142, 1, "\u0477"], [1143, 2], [1144, 1, "\u0479"], [1145, 2], [1146, 1, "\u047B"], [1147, 2], [1148, 1, "\u047D"], [1149, 2], [1150, 1, "\u047F"], [1151, 2], [1152, 1, "\u0481"], [1153, 2], [1154, 2], [[1155, 1158], 2], [1159, 2], [[1160, 1161], 2], [1162, 1, "\u048B"], [1163, 2], [1164, 1, "\u048D"], [1165, 2], [1166, 1, "\u048F"], [1167, 2], [1168, 1, "\u0491"], [1169, 2], [1170, 1, "\u0493"], [1171, 2], [1172, 1, "\u0495"], [1173, 2], [1174, 1, "\u0497"], [1175, 2], [1176, 1, "\u0499"], [1177, 2], [1178, 1, "\u049B"], [1179, 2], [1180, 1, "\u049D"], [1181, 2], [1182, 1, "\u049F"], [1183, 2], [1184, 1, "\u04A1"], [1185, 2], [1186, 1, "\u04A3"], [1187, 2], [1188, 1, "\u04A5"], [1189, 2], [1190, 1, "\u04A7"], [1191, 2], [1192, 1, "\u04A9"], [1193, 2], [1194, 1, "\u04AB"], [1195, 2], [1196, 1, "\u04AD"], [1197, 2], [1198, 1, "\u04AF"], [1199, 2], [1200, 1, "\u04B1"], [1201, 2], [1202, 1, "\u04B3"], [1203, 2], [1204, 1, "\u04B5"], [1205, 2], [1206, 1, "\u04B7"], [1207, 2], [1208, 1, "\u04B9"], [1209, 2], [1210, 1, "\u04BB"], [1211, 2], [1212, 1, "\u04BD"], [1213, 2], [1214, 1, "\u04BF"], [1215, 2], [1216, 1, "\u04CF"], [1217, 1, "\u04C2"], [1218, 2], [1219, 1, "\u04C4"], [1220, 2], [1221, 1, "\u04C6"], [1222, 2], [1223, 1, "\u04C8"], [1224, 2], [1225, 1, "\u04CA"], [1226, 2], [1227, 1, "\u04CC"], [1228, 2], [1229, 1, "\u04CE"], [1230, 2], [1231, 2], [1232, 1, "\u04D1"], [1233, 2], [1234, 1, "\u04D3"], [1235, 2], [1236, 1, "\u04D5"], [1237, 2], [1238, 1, "\u04D7"], [1239, 2], [1240, 1, "\u04D9"], [1241, 2], [1242, 1, "\u04DB"], [1243, 2], [1244, 1, "\u04DD"], [1245, 2], [1246, 1, "\u04DF"], [1247, 2], [1248, 1, "\u04E1"], [1249, 2], [1250, 1, "\u04E3"], [1251, 2], [1252, 1, "\u04E5"], [1253, 2], [1254, 1, "\u04E7"], [1255, 2], [1256, 1, "\u04E9"], [1257, 2], [1258, 1, "\u04EB"], [1259, 2], [1260, 1, "\u04ED"], [1261, 2], [1262, 1, "\u04EF"], [1263, 2], [1264, 1, "\u04F1"], [1265, 2], [1266, 1, "\u04F3"], [1267, 2], [1268, 1, "\u04F5"], [1269, 2], [1270, 1, "\u04F7"], [1271, 2], [1272, 1, "\u04F9"], [1273, 2], [1274, 1, "\u04FB"], [1275, 2], [1276, 1, "\u04FD"], [1277, 2], [1278, 1, "\u04FF"], [1279, 2], [1280, 1, "\u0501"], [1281, 2], [1282, 1, "\u0503"], [1283, 2], [1284, 1, "\u0505"], [1285, 2], [1286, 1, "\u0507"], [1287, 2], [1288, 1, "\u0509"], [1289, 2], [1290, 1, "\u050B"], [1291, 2], [1292, 1, "\u050D"], [1293, 2], [1294, 1, "\u050F"], [1295, 2], [1296, 1, "\u0511"], [1297, 2], [1298, 1, "\u0513"], [1299, 2], [1300, 1, "\u0515"], [1301, 2], [1302, 1, "\u0517"], [1303, 2], [1304, 1, "\u0519"], [1305, 2], [1306, 1, "\u051B"], [1307, 2], [1308, 1, "\u051D"], [1309, 2], [1310, 1, "\u051F"], [1311, 2], [1312, 1, "\u0521"], [1313, 2], [1314, 1, "\u0523"], [1315, 2], [1316, 1, "\u0525"], [1317, 2], [1318, 1, "\u0527"], [1319, 2], [1320, 1, "\u0529"], [1321, 2], [1322, 1, "\u052B"], [1323, 2], [1324, 1, "\u052D"], [1325, 2], [1326, 1, "\u052F"], [1327, 2], [1328, 3], [1329, 1, "\u0561"], [1330, 1, "\u0562"], [1331, 1, "\u0563"], [1332, 1, "\u0564"], [1333, 1, "\u0565"], [1334, 1, "\u0566"], [1335, 1, "\u0567"], [1336, 1, "\u0568"], [1337, 1, "\u0569"], [1338, 1, "\u056A"], [1339, 1, "\u056B"], [1340, 1, "\u056C"], [1341, 1, "\u056D"], [1342, 1, "\u056E"], [1343, 1, "\u056F"], [1344, 1, "\u0570"], [1345, 1, "\u0571"], [1346, 1, "\u0572"], [1347, 1, "\u0573"], [1348, 1, "\u0574"], [1349, 1, "\u0575"], [1350, 1, "\u0576"], [1351, 1, "\u0577"], [1352, 1, "\u0578"], [1353, 1, "\u0579"], [1354, 1, "\u057A"], [1355, 1, "\u057B"], [1356, 1, "\u057C"], [1357, 1, "\u057D"], [1358, 1, "\u057E"], [1359, 1, "\u057F"], [1360, 1, "\u0580"], [1361, 1, "\u0581"], [1362, 1, "\u0582"], [1363, 1, "\u0583"], [1364, 1, "\u0584"], [1365, 1, "\u0585"], [1366, 1, "\u0586"], [[1367, 1368], 3], [1369, 2], [[1370, 1375], 2], [1376, 2], [[1377, 1414], 2], [1415, 1, "\u0565\u0582"], [1416, 2], [1417, 2], [1418, 2], [[1419, 1420], 3], [[1421, 1422], 2], [1423, 2], [1424, 3], [[1425, 1441], 2], [1442, 2], [[1443, 1455], 2], [[1456, 1465], 2], [1466, 2], [[1467, 1469], 2], [1470, 2], [1471, 2], [1472, 2], [[1473, 1474], 2], [1475, 2], [1476, 2], [1477, 2], [1478, 2], [1479, 2], [[1480, 1487], 3], [[1488, 1514], 2], [[1515, 1518], 3], [1519, 2], [[1520, 1524], 2], [[1525, 1535], 3], [[1536, 1539], 3], [1540, 3], [1541, 3], [[1542, 1546], 2], [1547, 2], [1548, 2], [[1549, 1551], 2], [[1552, 1557], 2], [[1558, 1562], 2], [1563, 2], [1564, 3], [1565, 2], [1566, 2], [1567, 2], [1568, 2], [[1569, 1594], 2], [[1595, 1599], 2], [1600, 2], [[1601, 1618], 2], [[1619, 1621], 2], [[1622, 1624], 2], [[1625, 1630], 2], [1631, 2], [[1632, 1641], 2], [[1642, 1645], 2], [[1646, 1647], 2], [[1648, 1652], 2], [1653, 1, "\u0627\u0674"], [1654, 1, "\u0648\u0674"], [1655, 1, "\u06C7\u0674"], [1656, 1, "\u064A\u0674"], [[1657, 1719], 2], [[1720, 1721], 2], [[1722, 1726], 2], [1727, 2], [[1728, 1742], 2], [1743, 2], [[1744, 1747], 2], [1748, 2], [[1749, 1756], 2], [1757, 3], [1758, 2], [[1759, 1768], 2], [1769, 2], [[1770, 1773], 2], [[1774, 1775], 2], [[1776, 1785], 2], [[1786, 1790], 2], [1791, 2], [[1792, 1805], 2], [1806, 3], [1807, 3], [[1808, 1836], 2], [[1837, 1839], 2], [[1840, 1866], 2], [[1867, 1868], 3], [[1869, 1871], 2], [[1872, 1901], 2], [[1902, 1919], 2], [[1920, 1968], 2], [1969, 2], [[1970, 1983], 3], [[1984, 2037], 2], [[2038, 2042], 2], [[2043, 2044], 3], [2045, 2], [[2046, 2047], 2], [[2048, 2093], 2], [[2094, 2095], 3], [[2096, 2110], 2], [2111, 3], [[2112, 2139], 2], [[2140, 2141], 3], [2142, 2], [2143, 3], [[2144, 2154], 2], [[2155, 2159], 3], [[2160, 2183], 2], [2184, 2], [[2185, 2190], 2], [2191, 3], [[2192, 2193], 3], [[2194, 2198], 3], [2199, 2], [[2200, 2207], 2], [2208, 2], [2209, 2], [[2210, 2220], 2], [[2221, 2226], 2], [[2227, 2228], 2], [2229, 2], [[2230, 2237], 2], [[2238, 2247], 2], [[2248, 2258], 2], [2259, 2], [[2260, 2273], 2], [2274, 3], [2275, 2], [[2276, 2302], 2], [2303, 2], [2304, 2], [[2305, 2307], 2], [2308, 2], [[2309, 2361], 2], [[2362, 2363], 2], [[2364, 2381], 2], [2382, 2], [2383, 2], [[2384, 2388], 2], [2389, 2], [[2390, 2391], 2], [2392, 1, "\u0915\u093C"], [2393, 1, "\u0916\u093C"], [2394, 1, "\u0917\u093C"], [2395, 1, "\u091C\u093C"], [2396, 1, "\u0921\u093C"], [2397, 1, "\u0922\u093C"], [2398, 1, "\u092B\u093C"], [2399, 1, "\u092F\u093C"], [[2400, 2403], 2], [[2404, 2405], 2], [[2406, 2415], 2], [2416, 2], [[2417, 2418], 2], [[2419, 2423], 2], [2424, 2], [[2425, 2426], 2], [[2427, 2428], 2], [2429, 2], [[2430, 2431], 2], [2432, 2], [[2433, 2435], 2], [2436, 3], [[2437, 2444], 2], [[2445, 2446], 3], [[2447, 2448], 2], [[2449, 2450], 3], [[2451, 2472], 2], [2473, 3], [[2474, 2480], 2], [2481, 3], [2482, 2], [[2483, 2485], 3], [[2486, 2489], 2], [[2490, 2491], 3], [2492, 2], [2493, 2], [[2494, 2500], 2], [[2501, 2502], 3], [[2503, 2504], 2], [[2505, 2506], 3], [[2507, 2509], 2], [2510, 2], [[2511, 2518], 3], [2519, 2], [[2520, 2523], 3], [2524, 1, "\u09A1\u09BC"], [2525, 1, "\u09A2\u09BC"], [2526, 3], [2527, 1, "\u09AF\u09BC"], [[2528, 2531], 2], [[2532, 2533], 3], [[2534, 2545], 2], [[2546, 2554], 2], [2555, 2], [2556, 2], [2557, 2], [2558, 2], [[2559, 2560], 3], [2561, 2], [2562, 2], [2563, 2], [2564, 3], [[2565, 2570], 2], [[2571, 2574], 3], [[2575, 2576], 2], [[2577, 2578], 3], [[2579, 2600], 2], [2601, 3], [[2602, 2608], 2], [2609, 3], [2610, 2], [2611, 1, "\u0A32\u0A3C"], [2612, 3], [2613, 2], [2614, 1, "\u0A38\u0A3C"], [2615, 3], [[2616, 2617], 2], [[2618, 2619], 3], [2620, 2], [2621, 3], [[2622, 2626], 2], [[2627, 2630], 3], [[2631, 2632], 2], [[2633, 2634], 3], [[2635, 2637], 2], [[2638, 2640], 3], [2641, 2], [[2642, 2648], 3], [2649, 1, "\u0A16\u0A3C"], [2650, 1, "\u0A17\u0A3C"], [2651, 1, "\u0A1C\u0A3C"], [2652, 2], [2653, 3], [2654, 1, "\u0A2B\u0A3C"], [[2655, 2661], 3], [[2662, 2676], 2], [2677, 2], [2678, 2], [[2679, 2688], 3], [[2689, 2691], 2], [2692, 3], [[2693, 2699], 2], [2700, 2], [2701, 2], [2702, 3], [[2703, 2705], 2], [2706, 3], [[2707, 2728], 2], [2729, 3], [[2730, 2736], 2], [2737, 3], [[2738, 2739], 2], [2740, 3], [[2741, 2745], 2], [[2746, 2747], 3], [[2748, 2757], 2], [2758, 3], [[2759, 2761], 2], [2762, 3], [[2763, 2765], 2], [[2766, 2767], 3], [2768, 2], [[2769, 2783], 3], [2784, 2], [[2785, 2787], 2], [[2788, 2789], 3], [[2790, 2799], 2], [2800, 2], [2801, 2], [[2802, 2808], 3], [2809, 2], [[2810, 2815], 2], [2816, 3], [[2817, 2819], 2], [2820, 3], [[2821, 2828], 2], [[2829, 2830], 3], [[2831, 2832], 2], [[2833, 2834], 3], [[2835, 2856], 2], [2857, 3], [[2858, 2864], 2], [2865, 3], [[2866, 2867], 2], [2868, 3], [2869, 2], [[2870, 2873], 2], [[2874, 2875], 3], [[2876, 2883], 2], [2884, 2], [[2885, 2886], 3], [[2887, 2888], 2], [[2889, 2890], 3], [[2891, 2893], 2], [[2894, 2900], 3], [2901, 2], [[2902, 2903], 2], [[2904, 2907], 3], [2908, 1, "\u0B21\u0B3C"], [2909, 1, "\u0B22\u0B3C"], [2910, 3], [[2911, 2913], 2], [[2914, 2915], 2], [[2916, 2917], 3], [[2918, 2927], 2], [2928, 2], [2929, 2], [[2930, 2935], 2], [[2936, 2945], 3], [[2946, 2947], 2], [2948, 3], [[2949, 2954], 2], [[2955, 2957], 3], [[2958, 2960], 2], [2961, 3], [[2962, 2965], 2], [[2966, 2968], 3], [[2969, 2970], 2], [2971, 3], [2972, 2], [2973, 3], [[2974, 2975], 2], [[2976, 2978], 3], [[2979, 2980], 2], [[2981, 2983], 3], [[2984, 2986], 2], [[2987, 2989], 3], [[2990, 2997], 2], [2998, 2], [[2999, 3001], 2], [[3002, 3005], 3], [[3006, 3010], 2], [[3011, 3013], 3], [[3014, 3016], 2], [3017, 3], [[3018, 3021], 2], [[3022, 3023], 3], [3024, 2], [[3025, 3030], 3], [3031, 2], [[3032, 3045], 3], [3046, 2], [[3047, 3055], 2], [[3056, 3058], 2], [[3059, 3066], 2], [[3067, 3071], 3], [3072, 2], [[3073, 3075], 2], [3076, 2], [[3077, 3084], 2], [3085, 3], [[3086, 3088], 2], [3089, 3], [[3090, 3112], 2], [3113, 3], [[3114, 3123], 2], [3124, 2], [[3125, 3129], 2], [[3130, 3131], 3], [3132, 2], [3133, 2], [[3134, 3140], 2], [3141, 3], [[3142, 3144], 2], [3145, 3], [[3146, 3149], 2], [[3150, 3156], 3], [[3157, 3158], 2], [3159, 3], [[3160, 3161], 2], [3162, 2], [[3163, 3164], 3], [3165, 2], [[3166, 3167], 3], [[3168, 3169], 2], [[3170, 3171], 2], [[3172, 3173], 3], [[3174, 3183], 2], [[3184, 3190], 3], [3191, 2], [[3192, 3199], 2], [3200, 2], [3201, 2], [[3202, 3203], 2], [3204, 2], [[3205, 3212], 2], [3213, 3], [[3214, 3216], 2], [3217, 3], [[3218, 3240], 2], [3241, 3], [[3242, 3251], 2], [3252, 3], [[3253, 3257], 2], [[3258, 3259], 3], [[3260, 3261], 2], [[3262, 3268], 2], [3269, 3], [[3270, 3272], 2], [3273, 3], [[3274, 3277], 2], [[3278, 3284], 3], [[3285, 3286], 2], [[3287, 3292], 3], [3293, 2], [3294, 2], [3295, 3], [[3296, 3297], 2], [[3298, 3299], 2], [[3300, 3301], 3], [[3302, 3311], 2], [3312, 3], [[3313, 3314], 2], [3315, 2], [[3316, 3327], 3], [3328, 2], [3329, 2], [[3330, 3331], 2], [3332, 2], [[3333, 3340], 2], [3341, 3], [[3342, 3344], 2], [3345, 3], [[3346, 3368], 2], [3369, 2], [[3370, 3385], 2], [3386, 2], [[3387, 3388], 2], [3389, 2], [[3390, 3395], 2], [3396, 2], [3397, 3], [[3398, 3400], 2], [3401, 3], [[3402, 3405], 2], [3406, 2], [3407, 2], [[3408, 3411], 3], [[3412, 3414], 2], [3415, 2], [[3416, 3422], 2], [3423, 2], [[3424, 3425], 2], [[3426, 3427], 2], [[3428, 3429], 3], [[3430, 3439], 2], [[3440, 3445], 2], [[3446, 3448], 2], [3449, 2], [[3450, 3455], 2], [3456, 3], [3457, 2], [[3458, 3459], 2], [3460, 3], [[3461, 3478], 2], [[3479, 3481], 3], [[3482, 3505], 2], [3506, 3], [[3507, 3515], 2], [3516, 3], [3517, 2], [[3518, 3519], 3], [[3520, 3526], 2], [[3527, 3529], 3], [3530, 2], [[3531, 3534], 3], [[3535, 3540], 2], [3541, 3], [3542, 2], [3543, 3], [[3544, 3551], 2], [[3552, 3557], 3], [[3558, 3567], 2], [[3568, 3569], 3], [[3570, 3571], 2], [3572, 2], [[3573, 3584], 3], [[3585, 3634], 2], [3635, 1, "\u0E4D\u0E32"], [[3636, 3642], 2], [[3643, 3646], 3], [3647, 2], [[3648, 3662], 2], [3663, 2], [[3664, 3673], 2], [[3674, 3675], 2], [[3676, 3712], 3], [[3713, 3714], 2], [3715, 3], [3716, 2], [3717, 3], [3718, 2], [[3719, 3720], 2], [3721, 2], [3722, 2], [3723, 3], [3724, 2], [3725, 2], [[3726, 3731], 2], [[3732, 3735], 2], [3736, 2], [[3737, 3743], 2], [3744, 2], [[3745, 3747], 2], [3748, 3], [3749, 2], [3750, 3], [3751, 2], [[3752, 3753], 2], [[3754, 3755], 2], [3756, 2], [[3757, 3762], 2], [3763, 1, "\u0ECD\u0EB2"], [[3764, 3769], 2], [3770, 2], [[3771, 3773], 2], [[3774, 3775], 3], [[3776, 3780], 2], [3781, 3], [3782, 2], [3783, 3], [[3784, 3789], 2], [3790, 2], [3791, 3], [[3792, 3801], 2], [[3802, 3803], 3], [3804, 1, "\u0EAB\u0E99"], [3805, 1, "\u0EAB\u0EA1"], [[3806, 3807], 2], [[3808, 3839], 3], [3840, 2], [[3841, 3850], 2], [3851, 2], [3852, 1, "\u0F0B"], [[3853, 3863], 2], [[3864, 3865], 2], [[3866, 3871], 2], [[3872, 3881], 2], [[3882, 3892], 2], [3893, 2], [3894, 2], [3895, 2], [3896, 2], [3897, 2], [[3898, 3901], 2], [[3902, 3906], 2], [3907, 1, "\u0F42\u0FB7"], [[3908, 3911], 2], [3912, 3], [[3913, 3916], 2], [3917, 1, "\u0F4C\u0FB7"], [[3918, 3921], 2], [3922, 1, "\u0F51\u0FB7"], [[3923, 3926], 2], [3927, 1, "\u0F56\u0FB7"], [[3928, 3931], 2], [3932, 1, "\u0F5B\u0FB7"], [[3933, 3944], 2], [3945, 1, "\u0F40\u0FB5"], [3946, 2], [[3947, 3948], 2], [[3949, 3952], 3], [[3953, 3954], 2], [3955, 1, "\u0F71\u0F72"], [3956, 2], [3957, 1, "\u0F71\u0F74"], [3958, 1, "\u0FB2\u0F80"], [3959, 1, "\u0FB2\u0F71\u0F80"], [3960, 1, "\u0FB3\u0F80"], [3961, 1, "\u0FB3\u0F71\u0F80"], [[3962, 3968], 2], [3969, 1, "\u0F71\u0F80"], [[3970, 3972], 2], [3973, 2], [[3974, 3979], 2], [[3980, 3983], 2], [[3984, 3986], 2], [3987, 1, "\u0F92\u0FB7"], [[3988, 3989], 2], [3990, 2], [3991, 2], [3992, 3], [[3993, 3996], 2], [3997, 1, "\u0F9C\u0FB7"], [[3998, 4001], 2], [4002, 1, "\u0FA1\u0FB7"], [[4003, 4006], 2], [4007, 1, "\u0FA6\u0FB7"], [[4008, 4011], 2], [4012, 1, "\u0FAB\u0FB7"], [4013, 2], [[4014, 4016], 2], [[4017, 4023], 2], [4024, 2], [4025, 1, "\u0F90\u0FB5"], [[4026, 4028], 2], [4029, 3], [[4030, 4037], 2], [4038, 2], [[4039, 4044], 2], [4045, 3], [4046, 2], [4047, 2], [[4048, 4049], 2], [[4050, 4052], 2], [[4053, 4056], 2], [[4057, 4058], 2], [[4059, 4095], 3], [[4096, 4129], 2], [4130, 2], [[4131, 4135], 2], [4136, 2], [[4137, 4138], 2], [4139, 2], [[4140, 4146], 2], [[4147, 4149], 2], [[4150, 4153], 2], [[4154, 4159], 2], [[4160, 4169], 2], [[4170, 4175], 2], [[4176, 4185], 2], [[4186, 4249], 2], [[4250, 4253], 2], [[4254, 4255], 2], [4256, 1, "\u2D00"], [4257, 1, "\u2D01"], [4258, 1, "\u2D02"], [4259, 1, "\u2D03"], [4260, 1, "\u2D04"], [4261, 1, "\u2D05"], [4262, 1, "\u2D06"], [4263, 1, "\u2D07"], [4264, 1, "\u2D08"], [4265, 1, "\u2D09"], [4266, 1, "\u2D0A"], [4267, 1, "\u2D0B"], [4268, 1, "\u2D0C"], [4269, 1, "\u2D0D"], [4270, 1, "\u2D0E"], [4271, 1, "\u2D0F"], [4272, 1, "\u2D10"], [4273, 1, "\u2D11"], [4274, 1, "\u2D12"], [4275, 1, "\u2D13"], [4276, 1, "\u2D14"], [4277, 1, "\u2D15"], [4278, 1, "\u2D16"], [4279, 1, "\u2D17"], [4280, 1, "\u2D18"], [4281, 1, "\u2D19"], [4282, 1, "\u2D1A"], [4283, 1, "\u2D1B"], [4284, 1, "\u2D1C"], [4285, 1, "\u2D1D"], [4286, 1, "\u2D1E"], [4287, 1, "\u2D1F"], [4288, 1, "\u2D20"], [4289, 1, "\u2D21"], [4290, 1, "\u2D22"], [4291, 1, "\u2D23"], [4292, 1, "\u2D24"], [4293, 1, "\u2D25"], [4294, 3], [4295, 1, "\u2D27"], [[4296, 4300], 3], [4301, 1, "\u2D2D"], [[4302, 4303], 3], [[4304, 4342], 2], [[4343, 4344], 2], [[4345, 4346], 2], [4347, 2], [4348, 1, "\u10DC"], [[4349, 4351], 2], [[4352, 4441], 2], [[4442, 4446], 2], [[4447, 4448], 7], [[4449, 4514], 2], [[4515, 4519], 2], [[4520, 4601], 2], [[4602, 4607], 2], [[4608, 4614], 2], [4615, 2], [[4616, 4678], 2], [4679, 2], [4680, 2], [4681, 3], [[4682, 4685], 2], [[4686, 4687], 3], [[4688, 4694], 2], [4695, 3], [4696, 2], [4697, 3], [[4698, 4701], 2], [[4702, 4703], 3], [[4704, 4742], 2], [4743, 2], [4744, 2], [4745, 3], [[4746, 4749], 2], [[4750, 4751], 3], [[4752, 4782], 2], [4783, 2], [4784, 2], [4785, 3], [[4786, 4789], 2], [[4790, 4791], 3], [[4792, 4798], 2], [4799, 3], [4800, 2], [4801, 3], [[4802, 4805], 2], [[4806, 4807], 3], [[4808, 4814], 2], [4815, 2], [[4816, 4822], 2], [4823, 3], [[4824, 4846], 2], [4847, 2], [[4848, 4878], 2], [4879, 2], [4880, 2], [4881, 3], [[4882, 4885], 2], [[4886, 4887], 3], [[4888, 4894], 2], [4895, 2], [[4896, 4934], 2], [4935, 2], [[4936, 4954], 2], [[4955, 4956], 3], [[4957, 4958], 2], [4959, 2], [4960, 2], [[4961, 4988], 2], [[4989, 4991], 3], [[4992, 5007], 2], [[5008, 5017], 2], [[5018, 5023], 3], [[5024, 5108], 2], [5109, 2], [[5110, 5111], 3], [5112, 1, "\u13F0"], [5113, 1, "\u13F1"], [5114, 1, "\u13F2"], [5115, 1, "\u13F3"], [5116, 1, "\u13F4"], [5117, 1, "\u13F5"], [[5118, 5119], 3], [5120, 2], [[5121, 5740], 2], [[5741, 5742], 2], [[5743, 5750], 2], [[5751, 5759], 2], [5760, 3], [[5761, 5786], 2], [[5787, 5788], 2], [[5789, 5791], 3], [[5792, 5866], 2], [[5867, 5872], 2], [[5873, 5880], 2], [[5881, 5887], 3], [[5888, 5900], 2], [5901, 2], [[5902, 5908], 2], [5909, 2], [[5910, 5918], 3], [5919, 2], [[5920, 5940], 2], [[5941, 5942], 2], [[5943, 5951], 3], [[5952, 5971], 2], [[5972, 5983], 3], [[5984, 5996], 2], [5997, 3], [[5998, 6e3], 2], [6001, 3], [[6002, 6003], 2], [[6004, 6015], 3], [[6016, 6067], 2], [[6068, 6069], 7], [[6070, 6099], 2], [[6100, 6102], 2], [6103, 2], [[6104, 6107], 2], [6108, 2], [6109, 2], [[6110, 6111], 3], [[6112, 6121], 2], [[6122, 6127], 3], [[6128, 6137], 2], [[6138, 6143], 3], [[6144, 6154], 2], [[6155, 6158], 7], [6159, 7], [[6160, 6169], 2], [[6170, 6175], 3], [[6176, 6263], 2], [6264, 2], [[6265, 6271], 3], [[6272, 6313], 2], [6314, 2], [[6315, 6319], 3], [[6320, 6389], 2], [[6390, 6399], 3], [[6400, 6428], 2], [[6429, 6430], 2], [6431, 3], [[6432, 6443], 2], [[6444, 6447], 3], [[6448, 6459], 2], [[6460, 6463], 3], [6464, 2], [[6465, 6467], 3], [[6468, 6469], 2], [[6470, 6509], 2], [[6510, 6511], 3], [[6512, 6516], 2], [[6517, 6527], 3], [[6528, 6569], 2], [[6570, 6571], 2], [[6572, 6575], 3], [[6576, 6601], 2], [[6602, 6607], 3], [[6608, 6617], 2], [6618, 2], [[6619, 6621], 3], [[6622, 6623], 2], [[6624, 6655], 2], [[6656, 6683], 2], [[6684, 6685], 3], [[6686, 6687], 2], [[6688, 6750], 2], [6751, 3], [[6752, 6780], 2], [[6781, 6782], 3], [[6783, 6793], 2], [[6794, 6799], 3], [[6800, 6809], 2], [[6810, 6815], 3], [[6816, 6822], 2], [6823, 2], [[6824, 6829], 2], [[6830, 6831], 3], [[6832, 6845], 2], [6846, 2], [[6847, 6848], 2], [[6849, 6862], 2], [[6863, 6911], 3], [[6912, 6987], 2], [6988, 2], [6989, 3], [[6990, 6991], 2], [[6992, 7001], 2], [[7002, 7018], 2], [[7019, 7027], 2], [[7028, 7036], 2], [[7037, 7038], 2], [7039, 2], [[7040, 7082], 2], [[7083, 7085], 2], [[7086, 7097], 2], [[7098, 7103], 2], [[7104, 7155], 2], [[7156, 7163], 3], [[7164, 7167], 2], [[7168, 7223], 2], [[7224, 7226], 3], [[7227, 7231], 2], [[7232, 7241], 2], [[7242, 7244], 3], [[7245, 7293], 2], [[7294, 7295], 2], [7296, 1, "\u0432"], [7297, 1, "\u0434"], [7298, 1, "\u043E"], [7299, 1, "\u0441"], [[7300, 7301], 1, "\u0442"], [7302, 1, "\u044A"], [7303, 1, "\u0463"], [7304, 1, "\uA64B"], [7305, 1, "\u1C8A"], [7306, 2], [[7307, 7311], 3], [7312, 1, "\u10D0"], [7313, 1, "\u10D1"], [7314, 1, "\u10D2"], [7315, 1, "\u10D3"], [7316, 1, "\u10D4"], [7317, 1, "\u10D5"], [7318, 1, "\u10D6"], [7319, 1, "\u10D7"], [7320, 1, "\u10D8"], [7321, 1, "\u10D9"], [7322, 1, "\u10DA"], [7323, 1, "\u10DB"], [7324, 1, "\u10DC"], [7325, 1, "\u10DD"], [7326, 1, "\u10DE"], [7327, 1, "\u10DF"], [7328, 1, "\u10E0"], [7329, 1, "\u10E1"], [7330, 1, "\u10E2"], [7331, 1, "\u10E3"], [7332, 1, "\u10E4"], [7333, 1, "\u10E5"], [7334, 1, "\u10E6"], [7335, 1, "\u10E7"], [7336, 1, "\u10E8"], [7337, 1, "\u10E9"], [7338, 1, "\u10EA"], [7339, 1, "\u10EB"], [7340, 1, "\u10EC"], [7341, 1, "\u10ED"], [7342, 1, "\u10EE"], [7343, 1, "\u10EF"], [7344, 1, "\u10F0"], [7345, 1, "\u10F1"], [7346, 1, "\u10F2"], [7347, 1, "\u10F3"], [7348, 1, "\u10F4"], [7349, 1, "\u10F5"], [7350, 1, "\u10F6"], [7351, 1, "\u10F7"], [7352, 1, "\u10F8"], [7353, 1, "\u10F9"], [7354, 1, "\u10FA"], [[7355, 7356], 3], [7357, 1, "\u10FD"], [7358, 1, "\u10FE"], [7359, 1, "\u10FF"], [[7360, 7367], 2], [[7368, 7375], 3], [[7376, 7378], 2], [7379, 2], [[7380, 7410], 2], [[7411, 7414], 2], [7415, 2], [[7416, 7417], 2], [7418, 2], [[7419, 7423], 3], [[7424, 7467], 2], [7468, 1, "a"], [7469, 1, "\xE6"], [7470, 1, "b"], [7471, 2], [7472, 1, "d"], [7473, 1, "e"], [7474, 1, "\u01DD"], [7475, 1, "g"], [7476, 1, "h"], [7477, 1, "i"], [7478, 1, "j"], [7479, 1, "k"], [7480, 1, "l"], [7481, 1, "m"], [7482, 1, "n"], [7483, 2], [7484, 1, "o"], [7485, 1, "\u0223"], [7486, 1, "p"], [7487, 1, "r"], [7488, 1, "t"], [7489, 1, "u"], [7490, 1, "w"], [7491, 1, "a"], [7492, 1, "\u0250"], [7493, 1, "\u0251"], [7494, 1, "\u1D02"], [7495, 1, "b"], [7496, 1, "d"], [7497, 1, "e"], [7498, 1, "\u0259"], [7499, 1, "\u025B"], [7500, 1, "\u025C"], [7501, 1, "g"], [7502, 2], [7503, 1, "k"], [7504, 1, "m"], [7505, 1, "\u014B"], [7506, 1, "o"], [7507, 1, "\u0254"], [7508, 1, "\u1D16"], [7509, 1, "\u1D17"], [7510, 1, "p"], [7511, 1, "t"], [7512, 1, "u"], [7513, 1, "\u1D1D"], [7514, 1, "\u026F"], [7515, 1, "v"], [7516, 1, "\u1D25"], [7517, 1, "\u03B2"], [7518, 1, "\u03B3"], [7519, 1, "\u03B4"], [7520, 1, "\u03C6"], [7521, 1, "\u03C7"], [7522, 1, "i"], [7523, 1, "r"], [7524, 1, "u"], [7525, 1, "v"], [7526, 1, "\u03B2"], [7527, 1, "\u03B3"], [7528, 1, "\u03C1"], [7529, 1, "\u03C6"], [7530, 1, "\u03C7"], [7531, 2], [[7532, 7543], 2], [7544, 1, "\u043D"], [[7545, 7578], 2], [7579, 1, "\u0252"], [7580, 1, "c"], [7581, 1, "\u0255"], [7582, 1, "\xF0"], [7583, 1, "\u025C"], [7584, 1, "f"], [7585, 1, "\u025F"], [7586, 1, "\u0261"], [7587, 1, "\u0265"], [7588, 1, "\u0268"], [7589, 1, "\u0269"], [7590, 1, "\u026A"], [7591, 1, "\u1D7B"], [7592, 1, "\u029D"], [7593, 1, "\u026D"], [7594, 1, "\u1D85"], [7595, 1, "\u029F"], [7596, 1, "\u0271"], [7597, 1, "\u0270"], [7598, 1, "\u0272"], [7599, 1, "\u0273"], [7600, 1, "\u0274"], [7601, 1, "\u0275"], [7602, 1, "\u0278"], [7603, 1, "\u0282"], [7604, 1, "\u0283"], [7605, 1, "\u01AB"], [7606, 1, "\u0289"], [7607, 1, "\u028A"], [7608, 1, "\u1D1C"], [7609, 1, "\u028B"], [7610, 1, "\u028C"], [7611, 1, "z"], [7612, 1, "\u0290"], [7613, 1, "\u0291"], [7614, 1, "\u0292"], [7615, 1, "\u03B8"], [[7616, 7619], 2], [[7620, 7626], 2], [[7627, 7654], 2], [[7655, 7669], 2], [[7670, 7673], 2], [7674, 2], [7675, 2], [7676, 2], [7677, 2], [[7678, 7679], 2], [7680, 1, "\u1E01"], [7681, 2], [7682, 1, "\u1E03"], [7683, 2], [7684, 1, "\u1E05"], [7685, 2], [7686, 1, "\u1E07"], [7687, 2], [7688, 1, "\u1E09"], [7689, 2], [7690, 1, "\u1E0B"], [7691, 2], [7692, 1, "\u1E0D"], [7693, 2], [7694, 1, "\u1E0F"], [7695, 2], [7696, 1, "\u1E11"], [7697, 2], [7698, 1, "\u1E13"], [7699, 2], [7700, 1, "\u1E15"], [7701, 2], [7702, 1, "\u1E17"], [7703, 2], [7704, 1, "\u1E19"], [7705, 2], [7706, 1, "\u1E1B"], [7707, 2], [7708, 1, "\u1E1D"], [7709, 2], [7710, 1, "\u1E1F"], [7711, 2], [7712, 1, "\u1E21"], [7713, 2], [7714, 1, "\u1E23"], [7715, 2], [7716, 1, "\u1E25"], [7717, 2], [7718, 1, "\u1E27"], [7719, 2], [7720, 1, "\u1E29"], [7721, 2], [7722, 1, "\u1E2B"], [7723, 2], [7724, 1, "\u1E2D"], [7725, 2], [7726, 1, "\u1E2F"], [7727, 2], [7728, 1, "\u1E31"], [7729, 2], [7730, 1, "\u1E33"], [7731, 2], [7732, 1, "\u1E35"], [7733, 2], [7734, 1, "\u1E37"], [7735, 2], [7736, 1, "\u1E39"], [7737, 2], [7738, 1, "\u1E3B"], [7739, 2], [7740, 1, "\u1E3D"], [7741, 2], [7742, 1, "\u1E3F"], [7743, 2], [7744, 1, "\u1E41"], [7745, 2], [7746, 1, "\u1E43"], [7747, 2], [7748, 1, "\u1E45"], [7749, 2], [7750, 1, "\u1E47"], [7751, 2], [7752, 1, "\u1E49"], [7753, 2], [7754, 1, "\u1E4B"], [7755, 2], [7756, 1, "\u1E4D"], [7757, 2], [7758, 1, "\u1E4F"], [7759, 2], [7760, 1, "\u1E51"], [7761, 2], [7762, 1, "\u1E53"], [7763, 2], [7764, 1, "\u1E55"], [7765, 2], [7766, 1, "\u1E57"], [7767, 2], [7768, 1, "\u1E59"], [7769, 2], [7770, 1, "\u1E5B"], [7771, 2], [7772, 1, "\u1E5D"], [7773, 2], [7774, 1, "\u1E5F"], [7775, 2], [7776, 1, "\u1E61"], [7777, 2], [7778, 1, "\u1E63"], [7779, 2], [7780, 1, "\u1E65"], [7781, 2], [7782, 1, "\u1E67"], [7783, 2], [7784, 1, "\u1E69"], [7785, 2], [7786, 1, "\u1E6B"], [7787, 2], [7788, 1, "\u1E6D"], [7789, 2], [7790, 1, "\u1E6F"], [7791, 2], [7792, 1, "\u1E71"], [7793, 2], [7794, 1, "\u1E73"], [7795, 2], [7796, 1, "\u1E75"], [7797, 2], [7798, 1, "\u1E77"], [7799, 2], [7800, 1, "\u1E79"], [7801, 2], [7802, 1, "\u1E7B"], [7803, 2], [7804, 1, "\u1E7D"], [7805, 2], [7806, 1, "\u1E7F"], [7807, 2], [7808, 1, "\u1E81"], [7809, 2], [7810, 1, "\u1E83"], [7811, 2], [7812, 1, "\u1E85"], [7813, 2], [7814, 1, "\u1E87"], [7815, 2], [7816, 1, "\u1E89"], [7817, 2], [7818, 1, "\u1E8B"], [7819, 2], [7820, 1, "\u1E8D"], [7821, 2], [7822, 1, "\u1E8F"], [7823, 2], [7824, 1, "\u1E91"], [7825, 2], [7826, 1, "\u1E93"], [7827, 2], [7828, 1, "\u1E95"], [[7829, 7833], 2], [7834, 1, "a\u02BE"], [7835, 1, "\u1E61"], [[7836, 7837], 2], [7838, 1, "\xDF"], [7839, 2], [7840, 1, "\u1EA1"], [7841, 2], [7842, 1, "\u1EA3"], [7843, 2], [7844, 1, "\u1EA5"], [7845, 2], [7846, 1, "\u1EA7"], [7847, 2], [7848, 1, "\u1EA9"], [7849, 2], [7850, 1, "\u1EAB"], [7851, 2], [7852, 1, "\u1EAD"], [7853, 2], [7854, 1, "\u1EAF"], [7855, 2], [7856, 1, "\u1EB1"], [7857, 2], [7858, 1, "\u1EB3"], [7859, 2], [7860, 1, "\u1EB5"], [7861, 2], [7862, 1, "\u1EB7"], [7863, 2], [7864, 1, "\u1EB9"], [7865, 2], [7866, 1, "\u1EBB"], [7867, 2], [7868, 1, "\u1EBD"], [7869, 2], [7870, 1, "\u1EBF"], [7871, 2], [7872, 1, "\u1EC1"], [7873, 2], [7874, 1, "\u1EC3"], [7875, 2], [7876, 1, "\u1EC5"], [7877, 2], [7878, 1, "\u1EC7"], [7879, 2], [7880, 1, "\u1EC9"], [7881, 2], [7882, 1, "\u1ECB"], [7883, 2], [7884, 1, "\u1ECD"], [7885, 2], [7886, 1, "\u1ECF"], [7887, 2], [7888, 1, "\u1ED1"], [7889, 2], [7890, 1, "\u1ED3"], [7891, 2], [7892, 1, "\u1ED5"], [7893, 2], [7894, 1, "\u1ED7"], [7895, 2], [7896, 1, "\u1ED9"], [7897, 2], [7898, 1, "\u1EDB"], [7899, 2], [7900, 1, "\u1EDD"], [7901, 2], [7902, 1, "\u1EDF"], [7903, 2], [7904, 1, "\u1EE1"], [7905, 2], [7906, 1, "\u1EE3"], [7907, 2], [7908, 1, "\u1EE5"], [7909, 2], [7910, 1, "\u1EE7"], [7911, 2], [7912, 1, "\u1EE9"], [7913, 2], [7914, 1, "\u1EEB"], [7915, 2], [7916, 1, "\u1EED"], [7917, 2], [7918, 1, "\u1EEF"], [7919, 2], [7920, 1, "\u1EF1"], [7921, 2], [7922, 1, "\u1EF3"], [7923, 2], [7924, 1, "\u1EF5"], [7925, 2], [7926, 1, "\u1EF7"], [7927, 2], [7928, 1, "\u1EF9"], [7929, 2], [7930, 1, "\u1EFB"], [7931, 2], [7932, 1, "\u1EFD"], [7933, 2], [7934, 1, "\u1EFF"], [7935, 2], [[7936, 7943], 2], [7944, 1, "\u1F00"], [7945, 1, "\u1F01"], [7946, 1, "\u1F02"], [7947, 1, "\u1F03"], [7948, 1, "\u1F04"], [7949, 1, "\u1F05"], [7950, 1, "\u1F06"], [7951, 1, "\u1F07"], [[7952, 7957], 2], [[7958, 7959], 3], [7960, 1, "\u1F10"], [7961, 1, "\u1F11"], [7962, 1, "\u1F12"], [7963, 1, "\u1F13"], [7964, 1, "\u1F14"], [7965, 1, "\u1F15"], [[7966, 7967], 3], [[7968, 7975], 2], [7976, 1, "\u1F20"], [7977, 1, "\u1F21"], [7978, 1, "\u1F22"], [7979, 1, "\u1F23"], [7980, 1, "\u1F24"], [7981, 1, "\u1F25"], [7982, 1, "\u1F26"], [7983, 1, "\u1F27"], [[7984, 7991], 2], [7992, 1, "\u1F30"], [7993, 1, "\u1F31"], [7994, 1, "\u1F32"], [7995, 1, "\u1F33"], [7996, 1, "\u1F34"], [7997, 1, "\u1F35"], [7998, 1, "\u1F36"], [7999, 1, "\u1F37"], [[8e3, 8005], 2], [[8006, 8007], 3], [8008, 1, "\u1F40"], [8009, 1, "\u1F41"], [8010, 1, "\u1F42"], [8011, 1, "\u1F43"], [8012, 1, "\u1F44"], [8013, 1, "\u1F45"], [[8014, 8015], 3], [[8016, 8023], 2], [8024, 3], [8025, 1, "\u1F51"], [8026, 3], [8027, 1, "\u1F53"], [8028, 3], [8029, 1, "\u1F55"], [8030, 3], [8031, 1, "\u1F57"], [[8032, 8039], 2], [8040, 1, "\u1F60"], [8041, 1, "\u1F61"], [8042, 1, "\u1F62"], [8043, 1, "\u1F63"], [8044, 1, "\u1F64"], [8045, 1, "\u1F65"], [8046, 1, "\u1F66"], [8047, 1, "\u1F67"], [8048, 2], [8049, 1, "\u03AC"], [8050, 2], [8051, 1, "\u03AD"], [8052, 2], [8053, 1, "\u03AE"], [8054, 2], [8055, 1, "\u03AF"], [8056, 2], [8057, 1, "\u03CC"], [8058, 2], [8059, 1, "\u03CD"], [8060, 2], [8061, 1, "\u03CE"], [[8062, 8063], 3], [8064, 1, "\u1F00\u03B9"], [8065, 1, "\u1F01\u03B9"], [8066, 1, "\u1F02\u03B9"], [8067, 1, "\u1F03\u03B9"], [8068, 1, "\u1F04\u03B9"], [8069, 1, "\u1F05\u03B9"], [8070, 1, "\u1F06\u03B9"], [8071, 1, "\u1F07\u03B9"], [8072, 1, "\u1F00\u03B9"], [8073, 1, "\u1F01\u03B9"], [8074, 1, "\u1F02\u03B9"], [8075, 1, "\u1F03\u03B9"], [8076, 1, "\u1F04\u03B9"], [8077, 1, "\u1F05\u03B9"], [8078, 1, "\u1F06\u03B9"], [8079, 1, "\u1F07\u03B9"], [8080, 1, "\u1F20\u03B9"], [8081, 1, "\u1F21\u03B9"], [8082, 1, "\u1F22\u03B9"], [8083, 1, "\u1F23\u03B9"], [8084, 1, "\u1F24\u03B9"], [8085, 1, "\u1F25\u03B9"], [8086, 1, "\u1F26\u03B9"], [8087, 1, "\u1F27\u03B9"], [8088, 1, "\u1F20\u03B9"], [8089, 1, "\u1F21\u03B9"], [8090, 1, "\u1F22\u03B9"], [8091, 1, "\u1F23\u03B9"], [8092, 1, "\u1F24\u03B9"], [8093, 1, "\u1F25\u03B9"], [8094, 1, "\u1F26\u03B9"], [8095, 1, "\u1F27\u03B9"], [8096, 1, "\u1F60\u03B9"], [8097, 1, "\u1F61\u03B9"], [8098, 1, "\u1F62\u03B9"], [8099, 1, "\u1F63\u03B9"], [8100, 1, "\u1F64\u03B9"], [8101, 1, "\u1F65\u03B9"], [8102, 1, "\u1F66\u03B9"], [8103, 1, "\u1F67\u03B9"], [8104, 1, "\u1F60\u03B9"], [8105, 1, "\u1F61\u03B9"], [8106, 1, "\u1F62\u03B9"], [8107, 1, "\u1F63\u03B9"], [8108, 1, "\u1F64\u03B9"], [8109, 1, "\u1F65\u03B9"], [8110, 1, "\u1F66\u03B9"], [8111, 1, "\u1F67\u03B9"], [[8112, 8113], 2], [8114, 1, "\u1F70\u03B9"], [8115, 1, "\u03B1\u03B9"], [8116, 1, "\u03AC\u03B9"], [8117, 3], [8118, 2], [8119, 1, "\u1FB6\u03B9"], [8120, 1, "\u1FB0"], [8121, 1, "\u1FB1"], [8122, 1, "\u1F70"], [8123, 1, "\u03AC"], [8124, 1, "\u03B1\u03B9"], [8125, 1, " \u0313"], [8126, 1, "\u03B9"], [8127, 1, " \u0313"], [8128, 1, " \u0342"], [8129, 1, " \u0308\u0342"], [8130, 1, "\u1F74\u03B9"], [8131, 1, "\u03B7\u03B9"], [8132, 1, "\u03AE\u03B9"], [8133, 3], [8134, 2], [8135, 1, "\u1FC6\u03B9"], [8136, 1, "\u1F72"], [8137, 1, "\u03AD"], [8138, 1, "\u1F74"], [8139, 1, "\u03AE"], [8140, 1, "\u03B7\u03B9"], [8141, 1, " \u0313\u0300"], [8142, 1, " \u0313\u0301"], [8143, 1, " \u0313\u0342"], [[8144, 8146], 2], [8147, 1, "\u0390"], [[8148, 8149], 3], [[8150, 8151], 2], [8152, 1, "\u1FD0"], [8153, 1, "\u1FD1"], [8154, 1, "\u1F76"], [8155, 1, "\u03AF"], [8156, 3], [8157, 1, " \u0314\u0300"], [8158, 1, " \u0314\u0301"], [8159, 1, " \u0314\u0342"], [[8160, 8162], 2], [8163, 1, "\u03B0"], [[8164, 8167], 2], [8168, 1, "\u1FE0"], [8169, 1, "\u1FE1"], [8170, 1, "\u1F7A"], [8171, 1, "\u03CD"], [8172, 1, "\u1FE5"], [8173, 1, " \u0308\u0300"], [8174, 1, " \u0308\u0301"], [8175, 1, "`"], [[8176, 8177], 3], [8178, 1, "\u1F7C\u03B9"], [8179, 1, "\u03C9\u03B9"], [8180, 1, "\u03CE\u03B9"], [8181, 3], [8182, 2], [8183, 1, "\u1FF6\u03B9"], [8184, 1, "\u1F78"], [8185, 1, "\u03CC"], [8186, 1, "\u1F7C"], [8187, 1, "\u03CE"], [8188, 1, "\u03C9\u03B9"], [8189, 1, " \u0301"], [8190, 1, " \u0314"], [8191, 3], [[8192, 8202], 1, " "], [8203, 7], [[8204, 8205], 6, ""], [[8206, 8207], 3], [8208, 2], [8209, 1, "\u2010"], [[8210, 8214], 2], [8215, 1, " \u0333"], [[8216, 8227], 2], [[8228, 8230], 3], [8231, 2], [[8232, 8238], 3], [8239, 1, " "], [[8240, 8242], 2], [8243, 1, "\u2032\u2032"], [8244, 1, "\u2032\u2032\u2032"], [8245, 2], [8246, 1, "\u2035\u2035"], [8247, 1, "\u2035\u2035\u2035"], [[8248, 8251], 2], [8252, 1, "!!"], [8253, 2], [8254, 1, " \u0305"], [[8255, 8262], 2], [8263, 1, "??"], [8264, 1, "?!"], [8265, 1, "!?"], [[8266, 8269], 2], [[8270, 8274], 2], [[8275, 8276], 2], [[8277, 8278], 2], [8279, 1, "\u2032\u2032\u2032\u2032"], [[8280, 8286], 2], [8287, 1, " "], [[8288, 8291], 7], [8292, 7], [8293, 3], [[8294, 8297], 3], [[8298, 8303], 7], [8304, 1, "0"], [8305, 1, "i"], [[8306, 8307], 3], [8308, 1, "4"], [8309, 1, "5"], [8310, 1, "6"], [8311, 1, "7"], [8312, 1, "8"], [8313, 1, "9"], [8314, 1, "+"], [8315, 1, "\u2212"], [8316, 1, "="], [8317, 1, "("], [8318, 1, ")"], [8319, 1, "n"], [8320, 1, "0"], [8321, 1, "1"], [8322, 1, "2"], [8323, 1, "3"], [8324, 1, "4"], [8325, 1, "5"], [8326, 1, "6"], [8327, 1, "7"], [8328, 1, "8"], [8329, 1, "9"], [8330, 1, "+"], [8331, 1, "\u2212"], [8332, 1, "="], [8333, 1, "("], [8334, 1, ")"], [8335, 3], [8336, 1, "a"], [8337, 1, "e"], [8338, 1, "o"], [8339, 1, "x"], [8340, 1, "\u0259"], [8341, 1, "h"], [8342, 1, "k"], [8343, 1, "l"], [8344, 1, "m"], [8345, 1, "n"], [8346, 1, "p"], [8347, 1, "s"], [8348, 1, "t"], [[8349, 8351], 3], [[8352, 8359], 2], [8360, 1, "rs"], [[8361, 8362], 2], [8363, 2], [8364, 2], [[8365, 8367], 2], [[8368, 8369], 2], [[8370, 8373], 2], [[8374, 8376], 2], [8377, 2], [8378, 2], [[8379, 8381], 2], [8382, 2], [8383, 2], [8384, 2], [[8385, 8399], 3], [[8400, 8417], 2], [[8418, 8419], 2], [[8420, 8426], 2], [8427, 2], [[8428, 8431], 2], [8432, 2], [[8433, 8447], 3], [8448, 1, "a/c"], [8449, 1, "a/s"], [8450, 1, "c"], [8451, 1, "\xB0c"], [8452, 2], [8453, 1, "c/o"], [8454, 1, "c/u"], [8455, 1, "\u025B"], [8456, 2], [8457, 1, "\xB0f"], [8458, 1, "g"], [[8459, 8462], 1, "h"], [8463, 1, "\u0127"], [[8464, 8465], 1, "i"], [[8466, 8467], 1, "l"], [8468, 2], [8469, 1, "n"], [8470, 1, "no"], [[8471, 8472], 2], [8473, 1, "p"], [8474, 1, "q"], [[8475, 8477], 1, "r"], [[8478, 8479], 2], [8480, 1, "sm"], [8481, 1, "tel"], [8482, 1, "tm"], [8483, 2], [8484, 1, "z"], [8485, 2], [8486, 1, "\u03C9"], [8487, 2], [8488, 1, "z"], [8489, 2], [8490, 1, "k"], [8491, 1, "\xE5"], [8492, 1, "b"], [8493, 1, "c"], [8494, 2], [[8495, 8496], 1, "e"], [8497, 1, "f"], [8498, 1, "\u214E"], [8499, 1, "m"], [8500, 1, "o"], [8501, 1, "\u05D0"], [8502, 1, "\u05D1"], [8503, 1, "\u05D2"], [8504, 1, "\u05D3"], [8505, 1, "i"], [8506, 2], [8507, 1, "fax"], [8508, 1, "\u03C0"], [[8509, 8510], 1, "\u03B3"], [8511, 1, "\u03C0"], [8512, 1, "\u2211"], [[8513, 8516], 2], [[8517, 8518], 1, "d"], [8519, 1, "e"], [8520, 1, "i"], [8521, 1, "j"], [[8522, 8523], 2], [8524, 2], [8525, 2], [8526, 2], [8527, 2], [8528, 1, "1\u20447"], [8529, 1, "1\u20449"], [8530, 1, "1\u204410"], [8531, 1, "1\u20443"], [8532, 1, "2\u20443"], [8533, 1, "1\u20445"], [8534, 1, "2\u20445"], [8535, 1, "3\u20445"], [8536, 1, "4\u20445"], [8537, 1, "1\u20446"], [8538, 1, "5\u20446"], [8539, 1, "1\u20448"], [8540, 1, "3\u20448"], [8541, 1, "5\u20448"], [8542, 1, "7\u20448"], [8543, 1, "1\u2044"], [8544, 1, "i"], [8545, 1, "ii"], [8546, 1, "iii"], [8547, 1, "iv"], [8548, 1, "v"], [8549, 1, "vi"], [8550, 1, "vii"], [8551, 1, "viii"], [8552, 1, "ix"], [8553, 1, "x"], [8554, 1, "xi"], [8555, 1, "xii"], [8556, 1, "l"], [8557, 1, "c"], [8558, 1, "d"], [8559, 1, "m"], [8560, 1, "i"], [8561, 1, "ii"], [8562, 1, "iii"], [8563, 1, "iv"], [8564, 1, "v"], [8565, 1, "vi"], [8566, 1, "vii"], [8567, 1, "viii"], [8568, 1, "ix"], [8569, 1, "x"], [8570, 1, "xi"], [8571, 1, "xii"], [8572, 1, "l"], [8573, 1, "c"], [8574, 1, "d"], [8575, 1, "m"], [[8576, 8578], 2], [8579, 1, "\u2184"], [8580, 2], [[8581, 8584], 2], [8585, 1, "0\u20443"], [[8586, 8587], 2], [[8588, 8591], 3], [[8592, 8682], 2], [[8683, 8691], 2], [[8692, 8703], 2], [[8704, 8747], 2], [8748, 1, "\u222B\u222B"], [8749, 1, "\u222B\u222B\u222B"], [8750, 2], [8751, 1, "\u222E\u222E"], [8752, 1, "\u222E\u222E\u222E"], [[8753, 8945], 2], [[8946, 8959], 2], [8960, 2], [8961, 2], [[8962, 9e3], 2], [9001, 1, "\u3008"], [9002, 1, "\u3009"], [[9003, 9082], 2], [9083, 2], [9084, 2], [[9085, 9114], 2], [[9115, 9166], 2], [[9167, 9168], 2], [[9169, 9179], 2], [[9180, 9191], 2], [9192, 2], [[9193, 9203], 2], [[9204, 9210], 2], [[9211, 9214], 2], [9215, 2], [[9216, 9252], 2], [[9253, 9254], 2], [[9255, 9257], 2], [[9258, 9279], 3], [[9280, 9290], 2], [[9291, 9311], 3], [9312, 1, "1"], [9313, 1, "2"], [9314, 1, "3"], [9315, 1, "4"], [9316, 1, "5"], [9317, 1, "6"], [9318, 1, "7"], [9319, 1, "8"], [9320, 1, "9"], [9321, 1, "10"], [9322, 1, "11"], [9323, 1, "12"], [9324, 1, "13"], [9325, 1, "14"], [9326, 1, "15"], [9327, 1, "16"], [9328, 1, "17"], [9329, 1, "18"], [9330, 1, "19"], [9331, 1, "20"], [9332, 1, "(1)"], [9333, 1, "(2)"], [9334, 1, "(3)"], [9335, 1, "(4)"], [9336, 1, "(5)"], [9337, 1, "(6)"], [9338, 1, "(7)"], [9339, 1, "(8)"], [9340, 1, "(9)"], [9341, 1, "(10)"], [9342, 1, "(11)"], [9343, 1, "(12)"], [9344, 1, "(13)"], [9345, 1, "(14)"], [9346, 1, "(15)"], [9347, 1, "(16)"], [9348, 1, "(17)"], [9349, 1, "(18)"], [9350, 1, "(19)"], [9351, 1, "(20)"], [[9352, 9371], 3], [9372, 1, "(a)"], [9373, 1, "(b)"], [9374, 1, "(c)"], [9375, 1, "(d)"], [9376, 1, "(e)"], [9377, 1, "(f)"], [9378, 1, "(g)"], [9379, 1, "(h)"], [9380, 1, "(i)"], [9381, 1, "(j)"], [9382, 1, "(k)"], [9383, 1, "(l)"], [9384, 1, "(m)"], [9385, 1, "(n)"], [9386, 1, "(o)"], [9387, 1, "(p)"], [9388, 1, "(q)"], [9389, 1, "(r)"], [9390, 1, "(s)"], [9391, 1, "(t)"], [9392, 1, "(u)"], [9393, 1, "(v)"], [9394, 1, "(w)"], [9395, 1, "(x)"], [9396, 1, "(y)"], [9397, 1, "(z)"], [9398, 1, "a"], [9399, 1, "b"], [9400, 1, "c"], [9401, 1, "d"], [9402, 1, "e"], [9403, 1, "f"], [9404, 1, "g"], [9405, 1, "h"], [9406, 1, "i"], [9407, 1, "j"], [9408, 1, "k"], [9409, 1, "l"], [9410, 1, "m"], [9411, 1, "n"], [9412, 1, "o"], [9413, 1, "p"], [9414, 1, "q"], [9415, 1, "r"], [9416, 1, "s"], [9417, 1, "t"], [9418, 1, "u"], [9419, 1, "v"], [9420, 1, "w"], [9421, 1, "x"], [9422, 1, "y"], [9423, 1, "z"], [9424, 1, "a"], [9425, 1, "b"], [9426, 1, "c"], [9427, 1, "d"], [9428, 1, "e"], [9429, 1, "f"], [9430, 1, "g"], [9431, 1, "h"], [9432, 1, "i"], [9433, 1, "j"], [9434, 1, "k"], [9435, 1, "l"], [9436, 1, "m"], [9437, 1, "n"], [9438, 1, "o"], [9439, 1, "p"], [9440, 1, "q"], [9441, 1, "r"], [9442, 1, "s"], [9443, 1, "t"], [9444, 1, "u"], [9445, 1, "v"], [9446, 1, "w"], [9447, 1, "x"], [9448, 1, "y"], [9449, 1, "z"], [9450, 1, "0"], [[9451, 9470], 2], [9471, 2], [[9472, 9621], 2], [[9622, 9631], 2], [[9632, 9711], 2], [[9712, 9719], 2], [[9720, 9727], 2], [[9728, 9747], 2], [[9748, 9749], 2], [[9750, 9751], 2], [9752, 2], [9753, 2], [[9754, 9839], 2], [[9840, 9841], 2], [[9842, 9853], 2], [[9854, 9855], 2], [[9856, 9865], 2], [[9866, 9873], 2], [[9874, 9884], 2], [9885, 2], [[9886, 9887], 2], [[9888, 9889], 2], [[9890, 9905], 2], [9906, 2], [[9907, 9916], 2], [[9917, 9919], 2], [[9920, 9923], 2], [[9924, 9933], 2], [9934, 2], [[9935, 9953], 2], [9954, 2], [9955, 2], [[9956, 9959], 2], [[9960, 9983], 2], [9984, 2], [[9985, 9988], 2], [9989, 2], [[9990, 9993], 2], [[9994, 9995], 2], [[9996, 10023], 2], [10024, 2], [[10025, 10059], 2], [10060, 2], [10061, 2], [10062, 2], [[10063, 10066], 2], [[10067, 10069], 2], [10070, 2], [10071, 2], [[10072, 10078], 2], [[10079, 10080], 2], [[10081, 10087], 2], [[10088, 10101], 2], [[10102, 10132], 2], [[10133, 10135], 2], [[10136, 10159], 2], [10160, 2], [[10161, 10174], 2], [10175, 2], [[10176, 10182], 2], [[10183, 10186], 2], [10187, 2], [10188, 2], [10189, 2], [[10190, 10191], 2], [[10192, 10219], 2], [[10220, 10223], 2], [[10224, 10239], 2], [[10240, 10495], 2], [[10496, 10763], 2], [10764, 1, "\u222B\u222B\u222B\u222B"], [[10765, 10867], 2], [10868, 1, "::="], [10869, 1, "=="], [10870, 1, "==="], [[10871, 10971], 2], [10972, 1, "\u2ADD\u0338"], [[10973, 11007], 2], [[11008, 11021], 2], [[11022, 11027], 2], [[11028, 11034], 2], [[11035, 11039], 2], [[11040, 11043], 2], [[11044, 11084], 2], [[11085, 11087], 2], [[11088, 11092], 2], [[11093, 11097], 2], [[11098, 11123], 2], [[11124, 11125], 3], [[11126, 11157], 2], [11158, 3], [11159, 2], [[11160, 11193], 2], [[11194, 11196], 2], [[11197, 11208], 2], [11209, 2], [[11210, 11217], 2], [11218, 2], [[11219, 11243], 2], [[11244, 11247], 2], [[11248, 11262], 2], [11263, 2], [11264, 1, "\u2C30"], [11265, 1, "\u2C31"], [11266, 1, "\u2C32"], [11267, 1, "\u2C33"], [11268, 1, "\u2C34"], [11269, 1, "\u2C35"], [11270, 1, "\u2C36"], [11271, 1, "\u2C37"], [11272, 1, "\u2C38"], [11273, 1, "\u2C39"], [11274, 1, "\u2C3A"], [11275, 1, "\u2C3B"], [11276, 1, "\u2C3C"], [11277, 1, "\u2C3D"], [11278, 1, "\u2C3E"], [11279, 1, "\u2C3F"], [11280, 1, "\u2C40"], [11281, 1, "\u2C41"], [11282, 1, "\u2C42"], [11283, 1, "\u2C43"], [11284, 1, "\u2C44"], [11285, 1, "\u2C45"], [11286, 1, "\u2C46"], [11287, 1, "\u2C47"], [11288, 1, "\u2C48"], [11289, 1, "\u2C49"], [11290, 1, "\u2C4A"], [11291, 1, "\u2C4B"], [11292, 1, "\u2C4C"], [11293, 1, "\u2C4D"], [11294, 1, "\u2C4E"], [11295, 1, "\u2C4F"], [11296, 1, "\u2C50"], [11297, 1, "\u2C51"], [11298, 1, "\u2C52"], [11299, 1, "\u2C53"], [11300, 1, "\u2C54"], [11301, 1, "\u2C55"], [11302, 1, "\u2C56"], [11303, 1, "\u2C57"], [11304, 1, "\u2C58"], [11305, 1, "\u2C59"], [11306, 1, "\u2C5A"], [11307, 1, "\u2C5B"], [11308, 1, "\u2C5C"], [11309, 1, "\u2C5D"], [11310, 1, "\u2C5E"], [11311, 1, "\u2C5F"], [[11312, 11358], 2], [11359, 2], [11360, 1, "\u2C61"], [11361, 2], [11362, 1, "\u026B"], [11363, 1, "\u1D7D"], [11364, 1, "\u027D"], [[11365, 11366], 2], [11367, 1, "\u2C68"], [11368, 2], [11369, 1, "\u2C6A"], [11370, 2], [11371, 1, "\u2C6C"], [11372, 2], [11373, 1, "\u0251"], [11374, 1, "\u0271"], [11375, 1, "\u0250"], [11376, 1, "\u0252"], [11377, 2], [11378, 1, "\u2C73"], [11379, 2], [11380, 2], [11381, 1, "\u2C76"], [[11382, 11383], 2], [[11384, 11387], 2], [11388, 1, "j"], [11389, 1, "v"], [11390, 1, "\u023F"], [11391, 1, "\u0240"], [11392, 1, "\u2C81"], [11393, 2], [11394, 1, "\u2C83"], [11395, 2], [11396, 1, "\u2C85"], [11397, 2], [11398, 1, "\u2C87"], [11399, 2], [11400, 1, "\u2C89"], [11401, 2], [11402, 1, "\u2C8B"], [11403, 2], [11404, 1, "\u2C8D"], [11405, 2], [11406, 1, "\u2C8F"], [11407, 2], [11408, 1, "\u2C91"], [11409, 2], [11410, 1, "\u2C93"], [11411, 2], [11412, 1, "\u2C95"], [11413, 2], [11414, 1, "\u2C97"], [11415, 2], [11416, 1, "\u2C99"], [11417, 2], [11418, 1, "\u2C9B"], [11419, 2], [11420, 1, "\u2C9D"], [11421, 2], [11422, 1, "\u2C9F"], [11423, 2], [11424, 1, "\u2CA1"], [11425, 2], [11426, 1, "\u2CA3"], [11427, 2], [11428, 1, "\u2CA5"], [11429, 2], [11430, 1, "\u2CA7"], [11431, 2], [11432, 1, "\u2CA9"], [11433, 2], [11434, 1, "\u2CAB"], [11435, 2], [11436, 1, "\u2CAD"], [11437, 2], [11438, 1, "\u2CAF"], [11439, 2], [11440, 1, "\u2CB1"], [11441, 2], [11442, 1, "\u2CB3"], [11443, 2], [11444, 1, "\u2CB5"], [11445, 2], [11446, 1, "\u2CB7"], [11447, 2], [11448, 1, "\u2CB9"], [11449, 2], [11450, 1, "\u2CBB"], [11451, 2], [11452, 1, "\u2CBD"], [11453, 2], [11454, 1, "\u2CBF"], [11455, 2], [11456, 1, "\u2CC1"], [11457, 2], [11458, 1, "\u2CC3"], [11459, 2], [11460, 1, "\u2CC5"], [11461, 2], [11462, 1, "\u2CC7"], [11463, 2], [11464, 1, "\u2CC9"], [11465, 2], [11466, 1, "\u2CCB"], [11467, 2], [11468, 1, "\u2CCD"], [11469, 2], [11470, 1, "\u2CCF"], [11471, 2], [11472, 1, "\u2CD1"], [11473, 2], [11474, 1, "\u2CD3"], [11475, 2], [11476, 1, "\u2CD5"], [11477, 2], [11478, 1, "\u2CD7"], [11479, 2], [11480, 1, "\u2CD9"], [11481, 2], [11482, 1, "\u2CDB"], [11483, 2], [11484, 1, "\u2CDD"], [11485, 2], [11486, 1, "\u2CDF"], [11487, 2], [11488, 1, "\u2CE1"], [11489, 2], [11490, 1, "\u2CE3"], [[11491, 11492], 2], [[11493, 11498], 2], [11499, 1, "\u2CEC"], [11500, 2], [11501, 1, "\u2CEE"], [[11502, 11505], 2], [11506, 1, "\u2CF3"], [11507, 2], [[11508, 11512], 3], [[11513, 11519], 2], [[11520, 11557], 2], [11558, 3], [11559, 2], [[11560, 11564], 3], [11565, 2], [[11566, 11567], 3], [[11568, 11621], 2], [[11622, 11623], 2], [[11624, 11630], 3], [11631, 1, "\u2D61"], [11632, 2], [[11633, 11646], 3], [11647, 2], [[11648, 11670], 2], [[11671, 11679], 3], [[11680, 11686], 2], [11687, 3], [[11688, 11694], 2], [11695, 3], [[11696, 11702], 2], [11703, 3], [[11704, 11710], 2], [11711, 3], [[11712, 11718], 2], [11719, 3], [[11720, 11726], 2], [11727, 3], [[11728, 11734], 2], [11735, 3], [[11736, 11742], 2], [11743, 3], [[11744, 11775], 2], [[11776, 11799], 2], [[11800, 11803], 2], [[11804, 11805], 2], [[11806, 11822], 2], [11823, 2], [11824, 2], [11825, 2], [[11826, 11835], 2], [[11836, 11842], 2], [[11843, 11844], 2], [[11845, 11849], 2], [[11850, 11854], 2], [11855, 2], [[11856, 11858], 2], [[11859, 11869], 2], [[11870, 11903], 3], [[11904, 11929], 2], [11930, 3], [[11931, 11934], 2], [11935, 1, "\u6BCD"], [[11936, 12018], 2], [12019, 1, "\u9F9F"], [[12020, 12031], 3], [12032, 1, "\u4E00"], [12033, 1, "\u4E28"], [12034, 1, "\u4E36"], [12035, 1, "\u4E3F"], [12036, 1, "\u4E59"], [12037, 1, "\u4E85"], [12038, 1, "\u4E8C"], [12039, 1, "\u4EA0"], [12040, 1, "\u4EBA"], [12041, 1, "\u513F"], [12042, 1, "\u5165"], [12043, 1, "\u516B"], [12044, 1, "\u5182"], [12045, 1, "\u5196"], [12046, 1, "\u51AB"], [12047, 1, "\u51E0"], [12048, 1, "\u51F5"], [12049, 1, "\u5200"], [12050, 1, "\u529B"], [12051, 1, "\u52F9"], [12052, 1, "\u5315"], [12053, 1, "\u531A"], [12054, 1, "\u5338"], [12055, 1, "\u5341"], [12056, 1, "\u535C"], [12057, 1, "\u5369"], [12058, 1, "\u5382"], [12059, 1, "\u53B6"], [12060, 1, "\u53C8"], [12061, 1, "\u53E3"], [12062, 1, "\u56D7"], [12063, 1, "\u571F"], [12064, 1, "\u58EB"], [12065, 1, "\u5902"], [12066, 1, "\u590A"], [12067, 1, "\u5915"], [12068, 1, "\u5927"], [12069, 1, "\u5973"], [12070, 1, "\u5B50"], [12071, 1, "\u5B80"], [12072, 1, "\u5BF8"], [12073, 1, "\u5C0F"], [12074, 1, "\u5C22"], [12075, 1, "\u5C38"], [12076, 1, "\u5C6E"], [12077, 1, "\u5C71"], [12078, 1, "\u5DDB"], [12079, 1, "\u5DE5"], [12080, 1, "\u5DF1"], [12081, 1, "\u5DFE"], [12082, 1, "\u5E72"], [12083, 1, "\u5E7A"], [12084, 1, "\u5E7F"], [12085, 1, "\u5EF4"], [12086, 1, "\u5EFE"], [12087, 1, "\u5F0B"], [12088, 1, "\u5F13"], [12089, 1, "\u5F50"], [12090, 1, "\u5F61"], [12091, 1, "\u5F73"], [12092, 1, "\u5FC3"], [12093, 1, "\u6208"], [12094, 1, "\u6236"], [12095, 1, "\u624B"], [12096, 1, "\u652F"], [12097, 1, "\u6534"], [12098, 1, "\u6587"], [12099, 1, "\u6597"], [12100, 1, "\u65A4"], [12101, 1, "\u65B9"], [12102, 1, "\u65E0"], [12103, 1, "\u65E5"], [12104, 1, "\u66F0"], [12105, 1, "\u6708"], [12106, 1, "\u6728"], [12107, 1, "\u6B20"], [12108, 1, "\u6B62"], [12109, 1, "\u6B79"], [12110, 1, "\u6BB3"], [12111, 1, "\u6BCB"], [12112, 1, "\u6BD4"], [12113, 1, "\u6BDB"], [12114, 1, "\u6C0F"], [12115, 1, "\u6C14"], [12116, 1, "\u6C34"], [12117, 1, "\u706B"], [12118, 1, "\u722A"], [12119, 1, "\u7236"], [12120, 1, "\u723B"], [12121, 1, "\u723F"], [12122, 1, "\u7247"], [12123, 1, "\u7259"], [12124, 1, "\u725B"], [12125, 1, "\u72AC"], [12126, 1, "\u7384"], [12127, 1, "\u7389"], [12128, 1, "\u74DC"], [12129, 1, "\u74E6"], [12130, 1, "\u7518"], [12131, 1, "\u751F"], [12132, 1, "\u7528"], [12133, 1, "\u7530"], [12134, 1, "\u758B"], [12135, 1, "\u7592"], [12136, 1, "\u7676"], [12137, 1, "\u767D"], [12138, 1, "\u76AE"], [12139, 1, "\u76BF"], [12140, 1, "\u76EE"], [12141, 1, "\u77DB"], [12142, 1, "\u77E2"], [12143, 1, "\u77F3"], [12144, 1, "\u793A"], [12145, 1, "\u79B8"], [12146, 1, "\u79BE"], [12147, 1, "\u7A74"], [12148, 1, "\u7ACB"], [12149, 1, "\u7AF9"], [12150, 1, "\u7C73"], [12151, 1, "\u7CF8"], [12152, 1, "\u7F36"], [12153, 1, "\u7F51"], [12154, 1, "\u7F8A"], [12155, 1, "\u7FBD"], [12156, 1, "\u8001"], [12157, 1, "\u800C"], [12158, 1, "\u8012"], [12159, 1, "\u8033"], [12160, 1, "\u807F"], [12161, 1, "\u8089"], [12162, 1, "\u81E3"], [12163, 1, "\u81EA"], [12164, 1, "\u81F3"], [12165, 1, "\u81FC"], [12166, 1, "\u820C"], [12167, 1, "\u821B"], [12168, 1, "\u821F"], [12169, 1, "\u826E"], [12170, 1, "\u8272"], [12171, 1, "\u8278"], [12172, 1, "\u864D"], [12173, 1, "\u866B"], [12174, 1, "\u8840"], [12175, 1, "\u884C"], [12176, 1, "\u8863"], [12177, 1, "\u897E"], [12178, 1, "\u898B"], [12179, 1, "\u89D2"], [12180, 1, "\u8A00"], [12181, 1, "\u8C37"], [12182, 1, "\u8C46"], [12183, 1, "\u8C55"], [12184, 1, "\u8C78"], [12185, 1, "\u8C9D"], [12186, 1, "\u8D64"], [12187, 1, "\u8D70"], [12188, 1, "\u8DB3"], [12189, 1, "\u8EAB"], [12190, 1, "\u8ECA"], [12191, 1, "\u8F9B"], [12192, 1, "\u8FB0"], [12193, 1, "\u8FB5"], [12194, 1, "\u9091"], [12195, 1, "\u9149"], [12196, 1, "\u91C6"], [12197, 1, "\u91CC"], [12198, 1, "\u91D1"], [12199, 1, "\u9577"], [12200, 1, "\u9580"], [12201, 1, "\u961C"], [12202, 1, "\u96B6"], [12203, 1, "\u96B9"], [12204, 1, "\u96E8"], [12205, 1, "\u9751"], [12206, 1, "\u975E"], [12207, 1, "\u9762"], [12208, 1, "\u9769"], [12209, 1, "\u97CB"], [12210, 1, "\u97ED"], [12211, 1, "\u97F3"], [12212, 1, "\u9801"], [12213, 1, "\u98A8"], [12214, 1, "\u98DB"], [12215, 1, "\u98DF"], [12216, 1, "\u9996"], [12217, 1, "\u9999"], [12218, 1, "\u99AC"], [12219, 1, "\u9AA8"], [12220, 1, "\u9AD8"], [12221, 1, "\u9ADF"], [12222, 1, "\u9B25"], [12223, 1, "\u9B2F"], [12224, 1, "\u9B32"], [12225, 1, "\u9B3C"], [12226, 1, "\u9B5A"], [12227, 1, "\u9CE5"], [12228, 1, "\u9E75"], [12229, 1, "\u9E7F"], [12230, 1, "\u9EA5"], [12231, 1, "\u9EBB"], [12232, 1, "\u9EC3"], [12233, 1, "\u9ECD"], [12234, 1, "\u9ED1"], [12235, 1, "\u9EF9"], [12236, 1, "\u9EFD"], [12237, 1, "\u9F0E"], [12238, 1, "\u9F13"], [12239, 1, "\u9F20"], [12240, 1, "\u9F3B"], [12241, 1, "\u9F4A"], [12242, 1, "\u9F52"], [12243, 1, "\u9F8D"], [12244, 1, "\u9F9C"], [12245, 1, "\u9FA0"], [[12246, 12271], 3], [[12272, 12283], 3], [[12284, 12287], 3], [12288, 1, " "], [12289, 2], [12290, 1, "."], [[12291, 12292], 2], [[12293, 12295], 2], [[12296, 12329], 2], [[12330, 12333], 2], [[12334, 12341], 2], [12342, 1, "\u3012"], [12343, 2], [12344, 1, "\u5341"], [12345, 1, "\u5344"], [12346, 1, "\u5345"], [12347, 2], [12348, 2], [12349, 2], [12350, 2], [12351, 2], [12352, 3], [[12353, 12436], 2], [[12437, 12438], 2], [[12439, 12440], 3], [[12441, 12442], 2], [12443, 1, " \u3099"], [12444, 1, " \u309A"], [[12445, 12446], 2], [12447, 1, "\u3088\u308A"], [12448, 2], [[12449, 12542], 2], [12543, 1, "\u30B3\u30C8"], [[12544, 12548], 3], [[12549, 12588], 2], [12589, 2], [12590, 2], [12591, 2], [12592, 3], [12593, 1, "\u1100"], [12594, 1, "\u1101"], [12595, 1, "\u11AA"], [12596, 1, "\u1102"], [12597, 1, "\u11AC"], [12598, 1, "\u11AD"], [12599, 1, "\u1103"], [12600, 1, "\u1104"], [12601, 1, "\u1105"], [12602, 1, "\u11B0"], [12603, 1, "\u11B1"], [12604, 1, "\u11B2"], [12605, 1, "\u11B3"], [12606, 1, "\u11B4"], [12607, 1, "\u11B5"], [12608, 1, "\u111A"], [12609, 1, "\u1106"], [12610, 1, "\u1107"], [12611, 1, "\u1108"], [12612, 1, "\u1121"], [12613, 1, "\u1109"], [12614, 1, "\u110A"], [12615, 1, "\u110B"], [12616, 1, "\u110C"], [12617, 1, "\u110D"], [12618, 1, "\u110E"], [12619, 1, "\u110F"], [12620, 1, "\u1110"], [12621, 1, "\u1111"], [12622, 1, "\u1112"], [12623, 1, "\u1161"], [12624, 1, "\u1162"], [12625, 1, "\u1163"], [12626, 1, "\u1164"], [12627, 1, "\u1165"], [12628, 1, "\u1166"], [12629, 1, "\u1167"], [12630, 1, "\u1168"], [12631, 1, "\u1169"], [12632, 1, "\u116A"], [12633, 1, "\u116B"], [12634, 1, "\u116C"], [12635, 1, "\u116D"], [12636, 1, "\u116E"], [12637, 1, "\u116F"], [12638, 1, "\u1170"], [12639, 1, "\u1171"], [12640, 1, "\u1172"], [12641, 1, "\u1173"], [12642, 1, "\u1174"], [12643, 1, "\u1175"], [12644, 7], [12645, 1, "\u1114"], [12646, 1, "\u1115"], [12647, 1, "\u11C7"], [12648, 1, "\u11C8"], [12649, 1, "\u11CC"], [12650, 1, "\u11CE"], [12651, 1, "\u11D3"], [12652, 1, "\u11D7"], [12653, 1, "\u11D9"], [12654, 1, "\u111C"], [12655, 1, "\u11DD"], [12656, 1, "\u11DF"], [12657, 1, "\u111D"], [12658, 1, "\u111E"], [12659, 1, "\u1120"], [12660, 1, "\u1122"], [12661, 1, "\u1123"], [12662, 1, "\u1127"], [12663, 1, "\u1129"], [12664, 1, "\u112B"], [12665, 1, "\u112C"], [12666, 1, "\u112D"], [12667, 1, "\u112E"], [12668, 1, "\u112F"], [12669, 1, "\u1132"], [12670, 1, "\u1136"], [12671, 1, "\u1140"], [12672, 1, "\u1147"], [12673, 1, "\u114C"], [12674, 1, "\u11F1"], [12675, 1, "\u11F2"], [12676, 1, "\u1157"], [12677, 1, "\u1158"], [12678, 1, "\u1159"], [12679, 1, "\u1184"], [12680, 1, "\u1185"], [12681, 1, "\u1188"], [12682, 1, "\u1191"], [12683, 1, "\u1192"], [12684, 1, "\u1194"], [12685, 1, "\u119E"], [12686, 1, "\u11A1"], [12687, 3], [[12688, 12689], 2], [12690, 1, "\u4E00"], [12691, 1, "\u4E8C"], [12692, 1, "\u4E09"], [12693, 1, "\u56DB"], [12694, 1, "\u4E0A"], [12695, 1, "\u4E2D"], [12696, 1, "\u4E0B"], [12697, 1, "\u7532"], [12698, 1, "\u4E59"], [12699, 1, "\u4E19"], [12700, 1, "\u4E01"], [12701, 1, "\u5929"], [12702, 1, "\u5730"], [12703, 1, "\u4EBA"], [[12704, 12727], 2], [[12728, 12730], 2], [[12731, 12735], 2], [[12736, 12751], 2], [[12752, 12771], 2], [[12772, 12773], 2], [[12774, 12782], 3], [12783, 3], [[12784, 12799], 2], [12800, 1, "(\u1100)"], [12801, 1, "(\u1102)"], [12802, 1, "(\u1103)"], [12803, 1, "(\u1105)"], [12804, 1, "(\u1106)"], [12805, 1, "(\u1107)"], [12806, 1, "(\u1109)"], [12807, 1, "(\u110B)"], [12808, 1, "(\u110C)"], [12809, 1, "(\u110E)"], [12810, 1, "(\u110F)"], [12811, 1, "(\u1110)"], [12812, 1, "(\u1111)"], [12813, 1, "(\u1112)"], [12814, 1, "(\uAC00)"], [12815, 1, "(\uB098)"], [12816, 1, "(\uB2E4)"], [12817, 1, "(\uB77C)"], [12818, 1, "(\uB9C8)"], [12819, 1, "(\uBC14)"], [12820, 1, "(\uC0AC)"], [12821, 1, "(\uC544)"], [12822, 1, "(\uC790)"], [12823, 1, "(\uCC28)"], [12824, 1, "(\uCE74)"], [12825, 1, "(\uD0C0)"], [12826, 1, "(\uD30C)"], [12827, 1, "(\uD558)"], [12828, 1, "(\uC8FC)"], [12829, 1, "(\uC624\uC804)"], [12830, 1, "(\uC624\uD6C4)"], [12831, 3], [12832, 1, "(\u4E00)"], [12833, 1, "(\u4E8C)"], [12834, 1, "(\u4E09)"], [12835, 1, "(\u56DB)"], [12836, 1, "(\u4E94)"], [12837, 1, "(\u516D)"], [12838, 1, "(\u4E03)"], [12839, 1, "(\u516B)"], [12840, 1, "(\u4E5D)"], [12841, 1, "(\u5341)"], [12842, 1, "(\u6708)"], [12843, 1, "(\u706B)"], [12844, 1, "(\u6C34)"], [12845, 1, "(\u6728)"], [12846, 1, "(\u91D1)"], [12847, 1, "(\u571F)"], [12848, 1, "(\u65E5)"], [12849, 1, "(\u682A)"], [12850, 1, "(\u6709)"], [12851, 1, "(\u793E)"], [12852, 1, "(\u540D)"], [12853, 1, "(\u7279)"], [12854, 1, "(\u8CA1)"], [12855, 1, "(\u795D)"], [12856, 1, "(\u52B4)"], [12857, 1, "(\u4EE3)"], [12858, 1, "(\u547C)"], [12859, 1, "(\u5B66)"], [12860, 1, "(\u76E3)"], [12861, 1, "(\u4F01)"], [12862, 1, "(\u8CC7)"], [12863, 1, "(\u5354)"], [12864, 1, "(\u796D)"], [12865, 1, "(\u4F11)"], [12866, 1, "(\u81EA)"], [12867, 1, "(\u81F3)"], [12868, 1, "\u554F"], [12869, 1, "\u5E7C"], [12870, 1, "\u6587"], [12871, 1, "\u7B8F"], [[12872, 12879], 2], [12880, 1, "pte"], [12881, 1, "21"], [12882, 1, "22"], [12883, 1, "23"], [12884, 1, "24"], [12885, 1, "25"], [12886, 1, "26"], [12887, 1, "27"], [12888, 1, "28"], [12889, 1, "29"], [12890, 1, "30"], [12891, 1, "31"], [12892, 1, "32"], [12893, 1, "33"], [12894, 1, "34"], [12895, 1, "35"], [12896, 1, "\u1100"], [12897, 1, "\u1102"], [12898, 1, "\u1103"], [12899, 1, "\u1105"], [12900, 1, "\u1106"], [12901, 1, "\u1107"], [12902, 1, "\u1109"], [12903, 1, "\u110B"], [12904, 1, "\u110C"], [12905, 1, "\u110E"], [12906, 1, "\u110F"], [12907, 1, "\u1110"], [12908, 1, "\u1111"], [12909, 1, "\u1112"], [12910, 1, "\uAC00"], [12911, 1, "\uB098"], [12912, 1, "\uB2E4"], [12913, 1, "\uB77C"], [12914, 1, "\uB9C8"], [12915, 1, "\uBC14"], [12916, 1, "\uC0AC"], [12917, 1, "\uC544"], [12918, 1, "\uC790"], [12919, 1, "\uCC28"], [12920, 1, "\uCE74"], [12921, 1, "\uD0C0"], [12922, 1, "\uD30C"], [12923, 1, "\uD558"], [12924, 1, "\uCC38\uACE0"], [12925, 1, "\uC8FC\uC758"], [12926, 1, "\uC6B0"], [12927, 2], [12928, 1, "\u4E00"], [12929, 1, "\u4E8C"], [12930, 1, "\u4E09"], [12931, 1, "\u56DB"], [12932, 1, "\u4E94"], [12933, 1, "\u516D"], [12934, 1, "\u4E03"], [12935, 1, "\u516B"], [12936, 1, "\u4E5D"], [12937, 1, "\u5341"], [12938, 1, "\u6708"], [12939, 1, "\u706B"], [12940, 1, "\u6C34"], [12941, 1, "\u6728"], [12942, 1, "\u91D1"], [12943, 1, "\u571F"], [12944, 1, "\u65E5"], [12945, 1, "\u682A"], [12946, 1, "\u6709"], [12947, 1, "\u793E"], [12948, 1, "\u540D"], [12949, 1, "\u7279"], [12950, 1, "\u8CA1"], [12951, 1, "\u795D"], [12952, 1, "\u52B4"], [12953, 1, "\u79D8"], [12954, 1, "\u7537"], [12955, 1, "\u5973"], [12956, 1, "\u9069"], [12957, 1, "\u512A"], [12958, 1, "\u5370"], [12959, 1, "\u6CE8"], [12960, 1, "\u9805"], [12961, 1, "\u4F11"], [12962, 1, "\u5199"], [12963, 1, "\u6B63"], [12964, 1, "\u4E0A"], [12965, 1, "\u4E2D"], [12966, 1, "\u4E0B"], [12967, 1, "\u5DE6"], [12968, 1, "\u53F3"], [12969, 1, "\u533B"], [12970, 1, "\u5B97"], [12971, 1, "\u5B66"], [12972, 1, "\u76E3"], [12973, 1, "\u4F01"], [12974, 1, "\u8CC7"], [12975, 1, "\u5354"], [12976, 1, "\u591C"], [12977, 1, "36"], [12978, 1, "37"], [12979, 1, "38"], [12980, 1, "39"], [12981, 1, "40"], [12982, 1, "41"], [12983, 1, "42"], [12984, 1, "43"], [12985, 1, "44"], [12986, 1, "45"], [12987, 1, "46"], [12988, 1, "47"], [12989, 1, "48"], [12990, 1, "49"], [12991, 1, "50"], [12992, 1, "1\u6708"], [12993, 1, "2\u6708"], [12994, 1, "3\u6708"], [12995, 1, "4\u6708"], [12996, 1, "5\u6708"], [12997, 1, "6\u6708"], [12998, 1, "7\u6708"], [12999, 1, "8\u6708"], [13e3, 1, "9\u6708"], [13001, 1, "10\u6708"], [13002, 1, "11\u6708"], [13003, 1, "12\u6708"], [13004, 1, "hg"], [13005, 1, "erg"], [13006, 1, "ev"], [13007, 1, "ltd"], [13008, 1, "\u30A2"], [13009, 1, "\u30A4"], [13010, 1, "\u30A6"], [13011, 1, "\u30A8"], [13012, 1, "\u30AA"], [13013, 1, "\u30AB"], [13014, 1, "\u30AD"], [13015, 1, "\u30AF"], [13016, 1, "\u30B1"], [13017, 1, "\u30B3"], [13018, 1, "\u30B5"], [13019, 1, "\u30B7"], [13020, 1, "\u30B9"], [13021, 1, "\u30BB"], [13022, 1, "\u30BD"], [13023, 1, "\u30BF"], [13024, 1, "\u30C1"], [13025, 1, "\u30C4"], [13026, 1, "\u30C6"], [13027, 1, "\u30C8"], [13028, 1, "\u30CA"], [13029, 1, "\u30CB"], [13030, 1, "\u30CC"], [13031, 1, "\u30CD"], [13032, 1, "\u30CE"], [13033, 1, "\u30CF"], [13034, 1, "\u30D2"], [13035, 1, "\u30D5"], [13036, 1, "\u30D8"], [13037, 1, "\u30DB"], [13038, 1, "\u30DE"], [13039, 1, "\u30DF"], [13040, 1, "\u30E0"], [13041, 1, "\u30E1"], [13042, 1, "\u30E2"], [13043, 1, "\u30E4"], [13044, 1, "\u30E6"], [13045, 1, "\u30E8"], [13046, 1, "\u30E9"], [13047, 1, "\u30EA"], [13048, 1, "\u30EB"], [13049, 1, "\u30EC"], [13050, 1, "\u30ED"], [13051, 1, "\u30EF"], [13052, 1, "\u30F0"], [13053, 1, "\u30F1"], [13054, 1, "\u30F2"], [13055, 1, "\u4EE4\u548C"], [13056, 1, "\u30A2\u30D1\u30FC\u30C8"], [13057, 1, "\u30A2\u30EB\u30D5\u30A1"], [13058, 1, "\u30A2\u30F3\u30DA\u30A2"], [13059, 1, "\u30A2\u30FC\u30EB"], [13060, 1, "\u30A4\u30CB\u30F3\u30B0"], [13061, 1, "\u30A4\u30F3\u30C1"], [13062, 1, "\u30A6\u30A9\u30F3"], [13063, 1, "\u30A8\u30B9\u30AF\u30FC\u30C9"], [13064, 1, "\u30A8\u30FC\u30AB\u30FC"], [13065, 1, "\u30AA\u30F3\u30B9"], [13066, 1, "\u30AA\u30FC\u30E0"], [13067, 1, "\u30AB\u30A4\u30EA"], [13068, 1, "\u30AB\u30E9\u30C3\u30C8"], [13069, 1, "\u30AB\u30ED\u30EA\u30FC"], [13070, 1, "\u30AC\u30ED\u30F3"], [13071, 1, "\u30AC\u30F3\u30DE"], [13072, 1, "\u30AE\u30AC"], [13073, 1, "\u30AE\u30CB\u30FC"], [13074, 1, "\u30AD\u30E5\u30EA\u30FC"], [13075, 1, "\u30AE\u30EB\u30C0\u30FC"], [13076, 1, "\u30AD\u30ED"], [13077, 1, "\u30AD\u30ED\u30B0\u30E9\u30E0"], [13078, 1, "\u30AD\u30ED\u30E1\u30FC\u30C8\u30EB"], [13079, 1, "\u30AD\u30ED\u30EF\u30C3\u30C8"], [13080, 1, "\u30B0\u30E9\u30E0"], [13081, 1, "\u30B0\u30E9\u30E0\u30C8\u30F3"], [13082, 1, "\u30AF\u30EB\u30BC\u30A4\u30ED"], [13083, 1, "\u30AF\u30ED\u30FC\u30CD"], [13084, 1, "\u30B1\u30FC\u30B9"], [13085, 1, "\u30B3\u30EB\u30CA"], [13086, 1, "\u30B3\u30FC\u30DD"], [13087, 1, "\u30B5\u30A4\u30AF\u30EB"], [13088, 1, "\u30B5\u30F3\u30C1\u30FC\u30E0"], [13089, 1, "\u30B7\u30EA\u30F3\u30B0"], [13090, 1, "\u30BB\u30F3\u30C1"], [13091, 1, "\u30BB\u30F3\u30C8"], [13092, 1, "\u30C0\u30FC\u30B9"], [13093, 1, "\u30C7\u30B7"], [13094, 1, "\u30C9\u30EB"], [13095, 1, "\u30C8\u30F3"], [13096, 1, "\u30CA\u30CE"], [13097, 1, "\u30CE\u30C3\u30C8"], [13098, 1, "\u30CF\u30A4\u30C4"], [13099, 1, "\u30D1\u30FC\u30BB\u30F3\u30C8"], [13100, 1, "\u30D1\u30FC\u30C4"], [13101, 1, "\u30D0\u30FC\u30EC\u30EB"], [13102, 1, "\u30D4\u30A2\u30B9\u30C8\u30EB"], [13103, 1, "\u30D4\u30AF\u30EB"], [13104, 1, "\u30D4\u30B3"], [13105, 1, "\u30D3\u30EB"], [13106, 1, "\u30D5\u30A1\u30E9\u30C3\u30C9"], [13107, 1, "\u30D5\u30A3\u30FC\u30C8"], [13108, 1, "\u30D6\u30C3\u30B7\u30A7\u30EB"], [13109, 1, "\u30D5\u30E9\u30F3"], [13110, 1, "\u30D8\u30AF\u30BF\u30FC\u30EB"], [13111, 1, "\u30DA\u30BD"], [13112, 1, "\u30DA\u30CB\u30D2"], [13113, 1, "\u30D8\u30EB\u30C4"], [13114, 1, "\u30DA\u30F3\u30B9"], [13115, 1, "\u30DA\u30FC\u30B8"], [13116, 1, "\u30D9\u30FC\u30BF"], [13117, 1, "\u30DD\u30A4\u30F3\u30C8"], [13118, 1, "\u30DC\u30EB\u30C8"], [13119, 1, "\u30DB\u30F3"], [13120, 1, "\u30DD\u30F3\u30C9"], [13121, 1, "\u30DB\u30FC\u30EB"], [13122, 1, "\u30DB\u30FC\u30F3"], [13123, 1, "\u30DE\u30A4\u30AF\u30ED"], [13124, 1, "\u30DE\u30A4\u30EB"], [13125, 1, "\u30DE\u30C3\u30CF"], [13126, 1, "\u30DE\u30EB\u30AF"], [13127, 1, "\u30DE\u30F3\u30B7\u30E7\u30F3"], [13128, 1, "\u30DF\u30AF\u30ED\u30F3"], [13129, 1, "\u30DF\u30EA"], [13130, 1, "\u30DF\u30EA\u30D0\u30FC\u30EB"], [13131, 1, "\u30E1\u30AC"], [13132, 1, "\u30E1\u30AC\u30C8\u30F3"], [13133, 1, "\u30E1\u30FC\u30C8\u30EB"], [13134, 1, "\u30E4\u30FC\u30C9"], [13135, 1, "\u30E4\u30FC\u30EB"], [13136, 1, "\u30E6\u30A2\u30F3"], [13137, 1, "\u30EA\u30C3\u30C8\u30EB"], [13138, 1, "\u30EA\u30E9"], [13139, 1, "\u30EB\u30D4\u30FC"], [13140, 1, "\u30EB\u30FC\u30D6\u30EB"], [13141, 1, "\u30EC\u30E0"], [13142, 1, "\u30EC\u30F3\u30C8\u30B2\u30F3"], [13143, 1, "\u30EF\u30C3\u30C8"], [13144, 1, "0\u70B9"], [13145, 1, "1\u70B9"], [13146, 1, "2\u70B9"], [13147, 1, "3\u70B9"], [13148, 1, "4\u70B9"], [13149, 1, "5\u70B9"], [13150, 1, "6\u70B9"], [13151, 1, "7\u70B9"], [13152, 1, "8\u70B9"], [13153, 1, "9\u70B9"], [13154, 1, "10\u70B9"], [13155, 1, "11\u70B9"], [13156, 1, "12\u70B9"], [13157, 1, "13\u70B9"], [13158, 1, "14\u70B9"], [13159, 1, "15\u70B9"], [13160, 1, "16\u70B9"], [13161, 1, "17\u70B9"], [13162, 1, "18\u70B9"], [13163, 1, "19\u70B9"], [13164, 1, "20\u70B9"], [13165, 1, "21\u70B9"], [13166, 1, "22\u70B9"], [13167, 1, "23\u70B9"], [13168, 1, "24\u70B9"], [13169, 1, "hpa"], [13170, 1, "da"], [13171, 1, "au"], [13172, 1, "bar"], [13173, 1, "ov"], [13174, 1, "pc"], [13175, 1, "dm"], [13176, 1, "dm2"], [13177, 1, "dm3"], [13178, 1, "iu"], [13179, 1, "\u5E73\u6210"], [13180, 1, "\u662D\u548C"], [13181, 1, "\u5927\u6B63"], [13182, 1, "\u660E\u6CBB"], [13183, 1, "\u682A\u5F0F\u4F1A\u793E"], [13184, 1, "pa"], [13185, 1, "na"], [13186, 1, "\u03BCa"], [13187, 1, "ma"], [13188, 1, "ka"], [13189, 1, "kb"], [13190, 1, "mb"], [13191, 1, "gb"], [13192, 1, "cal"], [13193, 1, "kcal"], [13194, 1, "pf"], [13195, 1, "nf"], [13196, 1, "\u03BCf"], [13197, 1, "\u03BCg"], [13198, 1, "mg"], [13199, 1, "kg"], [13200, 1, "hz"], [13201, 1, "khz"], [13202, 1, "mhz"], [13203, 1, "ghz"], [13204, 1, "thz"], [13205, 1, "\u03BCl"], [13206, 1, "ml"], [13207, 1, "dl"], [13208, 1, "kl"], [13209, 1, "fm"], [13210, 1, "nm"], [13211, 1, "\u03BCm"], [13212, 1, "mm"], [13213, 1, "cm"], [13214, 1, "km"], [13215, 1, "mm2"], [13216, 1, "cm2"], [13217, 1, "m2"], [13218, 1, "km2"], [13219, 1, "mm3"], [13220, 1, "cm3"], [13221, 1, "m3"], [13222, 1, "km3"], [13223, 1, "m\u2215s"], [13224, 1, "m\u2215s2"], [13225, 1, "pa"], [13226, 1, "kpa"], [13227, 1, "mpa"], [13228, 1, "gpa"], [13229, 1, "rad"], [13230, 1, "rad\u2215s"], [13231, 1, "rad\u2215s2"], [13232, 1, "ps"], [13233, 1, "ns"], [13234, 1, "\u03BCs"], [13235, 1, "ms"], [13236, 1, "pv"], [13237, 1, "nv"], [13238, 1, "\u03BCv"], [13239, 1, "mv"], [13240, 1, "kv"], [13241, 1, "mv"], [13242, 1, "pw"], [13243, 1, "nw"], [13244, 1, "\u03BCw"], [13245, 1, "mw"], [13246, 1, "kw"], [13247, 1, "mw"], [13248, 1, "k\u03C9"], [13249, 1, "m\u03C9"], [13250, 3], [13251, 1, "bq"], [13252, 1, "cc"], [13253, 1, "cd"], [13254, 1, "c\u2215kg"], [13255, 3], [13256, 1, "db"], [13257, 1, "gy"], [13258, 1, "ha"], [13259, 1, "hp"], [13260, 1, "in"], [13261, 1, "kk"], [13262, 1, "km"], [13263, 1, "kt"], [13264, 1, "lm"], [13265, 1, "ln"], [13266, 1, "log"], [13267, 1, "lx"], [13268, 1, "mb"], [13269, 1, "mil"], [13270, 1, "mol"], [13271, 1, "ph"], [13272, 3], [13273, 1, "ppm"], [13274, 1, "pr"], [13275, 1, "sr"], [13276, 1, "sv"], [13277, 1, "wb"], [13278, 1, "v\u2215m"], [13279, 1, "a\u2215m"], [13280, 1, "1\u65E5"], [13281, 1, "2\u65E5"], [13282, 1, "3\u65E5"], [13283, 1, "4\u65E5"], [13284, 1, "5\u65E5"], [13285, 1, "6\u65E5"], [13286, 1, "7\u65E5"], [13287, 1, "8\u65E5"], [13288, 1, "9\u65E5"], [13289, 1, "10\u65E5"], [13290, 1, "11\u65E5"], [13291, 1, "12\u65E5"], [13292, 1, "13\u65E5"], [13293, 1, "14\u65E5"], [13294, 1, "15\u65E5"], [13295, 1, "16\u65E5"], [13296, 1, "17\u65E5"], [13297, 1, "18\u65E5"], [13298, 1, "19\u65E5"], [13299, 1, "20\u65E5"], [13300, 1, "21\u65E5"], [13301, 1, "22\u65E5"], [13302, 1, "23\u65E5"], [13303, 1, "24\u65E5"], [13304, 1, "25\u65E5"], [13305, 1, "26\u65E5"], [13306, 1, "27\u65E5"], [13307, 1, "28\u65E5"], [13308, 1, "29\u65E5"], [13309, 1, "30\u65E5"], [13310, 1, "31\u65E5"], [13311, 1, "gal"], [[13312, 19893], 2], [[19894, 19903], 2], [[19904, 19967], 2], [[19968, 40869], 2], [[40870, 40891], 2], [[40892, 40899], 2], [[40900, 40907], 2], [40908, 2], [[40909, 40917], 2], [[40918, 40938], 2], [[40939, 40943], 2], [[40944, 40956], 2], [[40957, 40959], 2], [[40960, 42124], 2], [[42125, 42127], 3], [[42128, 42145], 2], [[42146, 42147], 2], [[42148, 42163], 2], [42164, 2], [[42165, 42176], 2], [42177, 2], [[42178, 42180], 2], [42181, 2], [42182, 2], [[42183, 42191], 3], [[42192, 42237], 2], [[42238, 42239], 2], [[42240, 42508], 2], [[42509, 42511], 2], [[42512, 42539], 2], [[42540, 42559], 3], [42560, 1, "\uA641"], [42561, 2], [42562, 1, "\uA643"], [42563, 2], [42564, 1, "\uA645"], [42565, 2], [42566, 1, "\uA647"], [42567, 2], [42568, 1, "\uA649"], [42569, 2], [42570, 1, "\uA64B"], [42571, 2], [42572, 1, "\uA64D"], [42573, 2], [42574, 1, "\uA64F"], [42575, 2], [42576, 1, "\uA651"], [42577, 2], [42578, 1, "\uA653"], [42579, 2], [42580, 1, "\uA655"], [42581, 2], [42582, 1, "\uA657"], [42583, 2], [42584, 1, "\uA659"], [42585, 2], [42586, 1, "\uA65B"], [42587, 2], [42588, 1, "\uA65D"], [42589, 2], [42590, 1, "\uA65F"], [42591, 2], [42592, 1, "\uA661"], [42593, 2], [42594, 1, "\uA663"], [42595, 2], [42596, 1, "\uA665"], [42597, 2], [42598, 1, "\uA667"], [42599, 2], [42600, 1, "\uA669"], [42601, 2], [42602, 1, "\uA66B"], [42603, 2], [42604, 1, "\uA66D"], [[42605, 42607], 2], [[42608, 42611], 2], [[42612, 42619], 2], [[42620, 42621], 2], [42622, 2], [42623, 2], [42624, 1, "\uA681"], [42625, 2], [42626, 1, "\uA683"], [42627, 2], [42628, 1, "\uA685"], [42629, 2], [42630, 1, "\uA687"], [42631, 2], [42632, 1, "\uA689"], [42633, 2], [42634, 1, "\uA68B"], [42635, 2], [42636, 1, "\uA68D"], [42637, 2], [42638, 1, "\uA68F"], [42639, 2], [42640, 1, "\uA691"], [42641, 2], [42642, 1, "\uA693"], [42643, 2], [42644, 1, "\uA695"], [42645, 2], [42646, 1, "\uA697"], [42647, 2], [42648, 1, "\uA699"], [42649, 2], [42650, 1, "\uA69B"], [42651, 2], [42652, 1, "\u044A"], [42653, 1, "\u044C"], [42654, 2], [42655, 2], [[42656, 42725], 2], [[42726, 42735], 2], [[42736, 42737], 2], [[42738, 42743], 2], [[42744, 42751], 3], [[42752, 42774], 2], [[42775, 42778], 2], [[42779, 42783], 2], [[42784, 42785], 2], [42786, 1, "\uA723"], [42787, 2], [42788, 1, "\uA725"], [42789, 2], [42790, 1, "\uA727"], [42791, 2], [42792, 1, "\uA729"], [42793, 2], [42794, 1, "\uA72B"], [42795, 2], [42796, 1, "\uA72D"], [42797, 2], [42798, 1, "\uA72F"], [[42799, 42801], 2], [42802, 1, "\uA733"], [42803, 2], [42804, 1, "\uA735"], [42805, 2], [42806, 1, "\uA737"], [42807, 2], [42808, 1, "\uA739"], [42809, 2], [42810, 1, "\uA73B"], [42811, 2], [42812, 1, "\uA73D"], [42813, 2], [42814, 1, "\uA73F"], [42815, 2], [42816, 1, "\uA741"], [42817, 2], [42818, 1, "\uA743"], [42819, 2], [42820, 1, "\uA745"], [42821, 2], [42822, 1, "\uA747"], [42823, 2], [42824, 1, "\uA749"], [42825, 2], [42826, 1, "\uA74B"], [42827, 2], [42828, 1, "\uA74D"], [42829, 2], [42830, 1, "\uA74F"], [42831, 2], [42832, 1, "\uA751"], [42833, 2], [42834, 1, "\uA753"], [42835, 2], [42836, 1, "\uA755"], [42837, 2], [42838, 1, "\uA757"], [42839, 2], [42840, 1, "\uA759"], [42841, 2], [42842, 1, "\uA75B"], [42843, 2], [42844, 1, "\uA75D"], [42845, 2], [42846, 1, "\uA75F"], [42847, 2], [42848, 1, "\uA761"], [42849, 2], [42850, 1, "\uA763"], [42851, 2], [42852, 1, "\uA765"], [42853, 2], [42854, 1, "\uA767"], [42855, 2], [42856, 1, "\uA769"], [42857, 2], [42858, 1, "\uA76B"], [42859, 2], [42860, 1, "\uA76D"], [42861, 2], [42862, 1, "\uA76F"], [42863, 2], [42864, 1, "\uA76F"], [[42865, 42872], 2], [42873, 1, "\uA77A"], [42874, 2], [42875, 1, "\uA77C"], [42876, 2], [42877, 1, "\u1D79"], [42878, 1, "\uA77F"], [42879, 2], [42880, 1, "\uA781"], [42881, 2], [42882, 1, "\uA783"], [42883, 2], [42884, 1, "\uA785"], [42885, 2], [42886, 1, "\uA787"], [[42887, 42888], 2], [[42889, 42890], 2], [42891, 1, "\uA78C"], [42892, 2], [42893, 1, "\u0265"], [42894, 2], [42895, 2], [42896, 1, "\uA791"], [42897, 2], [42898, 1, "\uA793"], [42899, 2], [[42900, 42901], 2], [42902, 1, "\uA797"], [42903, 2], [42904, 1, "\uA799"], [42905, 2], [42906, 1, "\uA79B"], [42907, 2], [42908, 1, "\uA79D"], [42909, 2], [42910, 1, "\uA79F"], [42911, 2], [42912, 1, "\uA7A1"], [42913, 2], [42914, 1, "\uA7A3"], [42915, 2], [42916, 1, "\uA7A5"], [42917, 2], [42918, 1, "\uA7A7"], [42919, 2], [42920, 1, "\uA7A9"], [42921, 2], [42922, 1, "\u0266"], [42923, 1, "\u025C"], [42924, 1, "\u0261"], [42925, 1, "\u026C"], [42926, 1, "\u026A"], [42927, 2], [42928, 1, "\u029E"], [42929, 1, "\u0287"], [42930, 1, "\u029D"], [42931, 1, "\uAB53"], [42932, 1, "\uA7B5"], [42933, 2], [42934, 1, "\uA7B7"], [42935, 2], [42936, 1, "\uA7B9"], [42937, 2], [42938, 1, "\uA7BB"], [42939, 2], [42940, 1, "\uA7BD"], [42941, 2], [42942, 1, "\uA7BF"], [42943, 2], [42944, 1, "\uA7C1"], [42945, 2], [42946, 1, "\uA7C3"], [42947, 2], [42948, 1, "\uA794"], [42949, 1, "\u0282"], [42950, 1, "\u1D8E"], [42951, 1, "\uA7C8"], [42952, 2], [42953, 1, "\uA7CA"], [42954, 2], [42955, 1, "\u0264"], [42956, 1, "\uA7CD"], [42957, 2], [[42958, 42959], 3], [42960, 1, "\uA7D1"], [42961, 2], [42962, 3], [42963, 2], [42964, 3], [42965, 2], [42966, 1, "\uA7D7"], [42967, 2], [42968, 1, "\uA7D9"], [42969, 2], [42970, 1, "\uA7DB"], [42971, 2], [42972, 1, "\u019B"], [[42973, 42993], 3], [42994, 1, "c"], [42995, 1, "f"], [42996, 1, "q"], [42997, 1, "\uA7F6"], [42998, 2], [42999, 2], [43e3, 1, "\u0127"], [43001, 1, "\u0153"], [43002, 2], [[43003, 43007], 2], [[43008, 43047], 2], [[43048, 43051], 2], [43052, 2], [[43053, 43055], 3], [[43056, 43065], 2], [[43066, 43071], 3], [[43072, 43123], 2], [[43124, 43127], 2], [[43128, 43135], 3], [[43136, 43204], 2], [43205, 2], [[43206, 43213], 3], [[43214, 43215], 2], [[43216, 43225], 2], [[43226, 43231], 3], [[43232, 43255], 2], [[43256, 43258], 2], [43259, 2], [43260, 2], [43261, 2], [[43262, 43263], 2], [[43264, 43309], 2], [[43310, 43311], 2], [[43312, 43347], 2], [[43348, 43358], 3], [43359, 2], [[43360, 43388], 2], [[43389, 43391], 3], [[43392, 43456], 2], [[43457, 43469], 2], [43470, 3], [[43471, 43481], 2], [[43482, 43485], 3], [[43486, 43487], 2], [[43488, 43518], 2], [43519, 3], [[43520, 43574], 2], [[43575, 43583], 3], [[43584, 43597], 2], [[43598, 43599], 3], [[43600, 43609], 2], [[43610, 43611], 3], [[43612, 43615], 2], [[43616, 43638], 2], [[43639, 43641], 2], [[43642, 43643], 2], [[43644, 43647], 2], [[43648, 43714], 2], [[43715, 43738], 3], [[43739, 43741], 2], [[43742, 43743], 2], [[43744, 43759], 2], [[43760, 43761], 2], [[43762, 43766], 2], [[43767, 43776], 3], [[43777, 43782], 2], [[43783, 43784], 3], [[43785, 43790], 2], [[43791, 43792], 3], [[43793, 43798], 2], [[43799, 43807], 3], [[43808, 43814], 2], [43815, 3], [[43816, 43822], 2], [43823, 3], [[43824, 43866], 2], [43867, 2], [43868, 1, "\uA727"], [43869, 1, "\uAB37"], [43870, 1, "\u026B"], [43871, 1, "\uAB52"], [[43872, 43875], 2], [[43876, 43877], 2], [[43878, 43879], 2], [43880, 2], [43881, 1, "\u028D"], [[43882, 43883], 2], [[43884, 43887], 3], [43888, 1, "\u13A0"], [43889, 1, "\u13A1"], [43890, 1, "\u13A2"], [43891, 1, "\u13A3"], [43892, 1, "\u13A4"], [43893, 1, "\u13A5"], [43894, 1, "\u13A6"], [43895, 1, "\u13A7"], [43896, 1, "\u13A8"], [43897, 1, "\u13A9"], [43898, 1, "\u13AA"], [43899, 1, "\u13AB"], [43900, 1, "\u13AC"], [43901, 1, "\u13AD"], [43902, 1, "\u13AE"], [43903, 1, "\u13AF"], [43904, 1, "\u13B0"], [43905, 1, "\u13B1"], [43906, 1, "\u13B2"], [43907, 1, "\u13B3"], [43908, 1, "\u13B4"], [43909, 1, "\u13B5"], [43910, 1, "\u13B6"], [43911, 1, "\u13B7"], [43912, 1, "\u13B8"], [43913, 1, "\u13B9"], [43914, 1, "\u13BA"], [43915, 1, "\u13BB"], [43916, 1, "\u13BC"], [43917, 1, "\u13BD"], [43918, 1, "\u13BE"], [43919, 1, "\u13BF"], [43920, 1, "\u13C0"], [43921, 1, "\u13C1"], [43922, 1, "\u13C2"], [43923, 1, "\u13C3"], [43924, 1, "\u13C4"], [43925, 1, "\u13C5"], [43926, 1, "\u13C6"], [43927, 1, "\u13C7"], [43928, 1, "\u13C8"], [43929, 1, "\u13C9"], [43930, 1, "\u13CA"], [43931, 1, "\u13CB"], [43932, 1, "\u13CC"], [43933, 1, "\u13CD"], [43934, 1, "\u13CE"], [43935, 1, "\u13CF"], [43936, 1, "\u13D0"], [43937, 1, "\u13D1"], [43938, 1, "\u13D2"], [43939, 1, "\u13D3"], [43940, 1, "\u13D4"], [43941, 1, "\u13D5"], [43942, 1, "\u13D6"], [43943, 1, "\u13D7"], [43944, 1, "\u13D8"], [43945, 1, "\u13D9"], [43946, 1, "\u13DA"], [43947, 1, "\u13DB"], [43948, 1, "\u13DC"], [43949, 1, "\u13DD"], [43950, 1, "\u13DE"], [43951, 1, "\u13DF"], [43952, 1, "\u13E0"], [43953, 1, "\u13E1"], [43954, 1, "\u13E2"], [43955, 1, "\u13E3"], [43956, 1, "\u13E4"], [43957, 1, "\u13E5"], [43958, 1, "\u13E6"], [43959, 1, "\u13E7"], [43960, 1, "\u13E8"], [43961, 1, "\u13E9"], [43962, 1, "\u13EA"], [43963, 1, "\u13EB"], [43964, 1, "\u13EC"], [43965, 1, "\u13ED"], [43966, 1, "\u13EE"], [43967, 1, "\u13EF"], [[43968, 44010], 2], [44011, 2], [[44012, 44013], 2], [[44014, 44015], 3], [[44016, 44025], 2], [[44026, 44031], 3], [[44032, 55203], 2], [[55204, 55215], 3], [[55216, 55238], 2], [[55239, 55242], 3], [[55243, 55291], 2], [[55292, 55295], 3], [[55296, 57343], 3], [[57344, 63743], 3], [63744, 1, "\u8C48"], [63745, 1, "\u66F4"], [63746, 1, "\u8ECA"], [63747, 1, "\u8CC8"], [63748, 1, "\u6ED1"], [63749, 1, "\u4E32"], [63750, 1, "\u53E5"], [[63751, 63752], 1, "\u9F9C"], [63753, 1, "\u5951"], [63754, 1, "\u91D1"], [63755, 1, "\u5587"], [63756, 1, "\u5948"], [63757, 1, "\u61F6"], [63758, 1, "\u7669"], [63759, 1, "\u7F85"], [63760, 1, "\u863F"], [63761, 1, "\u87BA"], [63762, 1, "\u88F8"], [63763, 1, "\u908F"], [63764, 1, "\u6A02"], [63765, 1, "\u6D1B"], [63766, 1, "\u70D9"], [63767, 1, "\u73DE"], [63768, 1, "\u843D"], [63769, 1, "\u916A"], [63770, 1, "\u99F1"], [63771, 1, "\u4E82"], [63772, 1, "\u5375"], [63773, 1, "\u6B04"], [63774, 1, "\u721B"], [63775, 1, "\u862D"], [63776, 1, "\u9E1E"], [63777, 1, "\u5D50"], [63778, 1, "\u6FEB"], [63779, 1, "\u85CD"], [63780, 1, "\u8964"], [63781, 1, "\u62C9"], [63782, 1, "\u81D8"], [63783, 1, "\u881F"], [63784, 1, "\u5ECA"], [63785, 1, "\u6717"], [63786, 1, "\u6D6A"], [63787, 1, "\u72FC"], [63788, 1, "\u90CE"], [63789, 1, "\u4F86"], [63790, 1, "\u51B7"], [63791, 1, "\u52DE"], [63792, 1, "\u64C4"], [63793, 1, "\u6AD3"], [63794, 1, "\u7210"], [63795, 1, "\u76E7"], [63796, 1, "\u8001"], [63797, 1, "\u8606"], [63798, 1, "\u865C"], [63799, 1, "\u8DEF"], [63800, 1, "\u9732"], [63801, 1, "\u9B6F"], [63802, 1, "\u9DFA"], [63803, 1, "\u788C"], [63804, 1, "\u797F"], [63805, 1, "\u7DA0"], [63806, 1, "\u83C9"], [63807, 1, "\u9304"], [63808, 1, "\u9E7F"], [63809, 1, "\u8AD6"], [63810, 1, "\u58DF"], [63811, 1, "\u5F04"], [63812, 1, "\u7C60"], [63813, 1, "\u807E"], [63814, 1, "\u7262"], [63815, 1, "\u78CA"], [63816, 1, "\u8CC2"], [63817, 1, "\u96F7"], [63818, 1, "\u58D8"], [63819, 1, "\u5C62"], [63820, 1, "\u6A13"], [63821, 1, "\u6DDA"], [63822, 1, "\u6F0F"], [63823, 1, "\u7D2F"], [63824, 1, "\u7E37"], [63825, 1, "\u964B"], [63826, 1, "\u52D2"], [63827, 1, "\u808B"], [63828, 1, "\u51DC"], [63829, 1, "\u51CC"], [63830, 1, "\u7A1C"], [63831, 1, "\u7DBE"], [63832, 1, "\u83F1"], [63833, 1, "\u9675"], [63834, 1, "\u8B80"], [63835, 1, "\u62CF"], [63836, 1, "\u6A02"], [63837, 1, "\u8AFE"], [63838, 1, "\u4E39"], [63839, 1, "\u5BE7"], [63840, 1, "\u6012"], [63841, 1, "\u7387"], [63842, 1, "\u7570"], [63843, 1, "\u5317"], [63844, 1, "\u78FB"], [63845, 1, "\u4FBF"], [63846, 1, "\u5FA9"], [63847, 1, "\u4E0D"], [63848, 1, "\u6CCC"], [63849, 1, "\u6578"], [63850, 1, "\u7D22"], [63851, 1, "\u53C3"], [63852, 1, "\u585E"], [63853, 1, "\u7701"], [63854, 1, "\u8449"], [63855, 1, "\u8AAA"], [63856, 1, "\u6BBA"], [63857, 1, "\u8FB0"], [63858, 1, "\u6C88"], [63859, 1, "\u62FE"], [63860, 1, "\u82E5"], [63861, 1, "\u63A0"], [63862, 1, "\u7565"], [63863, 1, "\u4EAE"], [63864, 1, "\u5169"], [63865, 1, "\u51C9"], [63866, 1, "\u6881"], [63867, 1, "\u7CE7"], [63868, 1, "\u826F"], [63869, 1, "\u8AD2"], [63870, 1, "\u91CF"], [63871, 1, "\u52F5"], [63872, 1, "\u5442"], [63873, 1, "\u5973"], [63874, 1, "\u5EEC"], [63875, 1, "\u65C5"], [63876, 1, "\u6FFE"], [63877, 1, "\u792A"], [63878, 1, "\u95AD"], [63879, 1, "\u9A6A"], [63880, 1, "\u9E97"], [63881, 1, "\u9ECE"], [63882, 1, "\u529B"], [63883, 1, "\u66C6"], [63884, 1, "\u6B77"], [63885, 1, "\u8F62"], [63886, 1, "\u5E74"], [63887, 1, "\u6190"], [63888, 1, "\u6200"], [63889, 1, "\u649A"], [63890, 1, "\u6F23"], [63891, 1, "\u7149"], [63892, 1, "\u7489"], [63893, 1, "\u79CA"], [63894, 1, "\u7DF4"], [63895, 1, "\u806F"], [63896, 1, "\u8F26"], [63897, 1, "\u84EE"], [63898, 1, "\u9023"], [63899, 1, "\u934A"], [63900, 1, "\u5217"], [63901, 1, "\u52A3"], [63902, 1, "\u54BD"], [63903, 1, "\u70C8"], [63904, 1, "\u88C2"], [63905, 1, "\u8AAA"], [63906, 1, "\u5EC9"], [63907, 1, "\u5FF5"], [63908, 1, "\u637B"], [63909, 1, "\u6BAE"], [63910, 1, "\u7C3E"], [63911, 1, "\u7375"], [63912, 1, "\u4EE4"], [63913, 1, "\u56F9"], [63914, 1, "\u5BE7"], [63915, 1, "\u5DBA"], [63916, 1, "\u601C"], [63917, 1, "\u73B2"], [63918, 1, "\u7469"], [63919, 1, "\u7F9A"], [63920, 1, "\u8046"], [63921, 1, "\u9234"], [63922, 1, "\u96F6"], [63923, 1, "\u9748"], [63924, 1, "\u9818"], [63925, 1, "\u4F8B"], [63926, 1, "\u79AE"], [63927, 1, "\u91B4"], [63928, 1, "\u96B8"], [63929, 1, "\u60E1"], [63930, 1, "\u4E86"], [63931, 1, "\u50DA"], [63932, 1, "\u5BEE"], [63933, 1, "\u5C3F"], [63934, 1, "\u6599"], [63935, 1, "\u6A02"], [63936, 1, "\u71CE"], [63937, 1, "\u7642"], [63938, 1, "\u84FC"], [63939, 1, "\u907C"], [63940, 1, "\u9F8D"], [63941, 1, "\u6688"], [63942, 1, "\u962E"], [63943, 1, "\u5289"], [63944, 1, "\u677B"], [63945, 1, "\u67F3"], [63946, 1, "\u6D41"], [63947, 1, "\u6E9C"], [63948, 1, "\u7409"], [63949, 1, "\u7559"], [63950, 1, "\u786B"], [63951, 1, "\u7D10"], [63952, 1, "\u985E"], [63953, 1, "\u516D"], [63954, 1, "\u622E"], [63955, 1, "\u9678"], [63956, 1, "\u502B"], [63957, 1, "\u5D19"], [63958, 1, "\u6DEA"], [63959, 1, "\u8F2A"], [63960, 1, "\u5F8B"], [63961, 1, "\u6144"], [63962, 1, "\u6817"], [63963, 1, "\u7387"], [63964, 1, "\u9686"], [63965, 1, "\u5229"], [63966, 1, "\u540F"], [63967, 1, "\u5C65"], [63968, 1, "\u6613"], [63969, 1, "\u674E"], [63970, 1, "\u68A8"], [63971, 1, "\u6CE5"], [63972, 1, "\u7406"], [63973, 1, "\u75E2"], [63974, 1, "\u7F79"], [63975, 1, "\u88CF"], [63976, 1, "\u88E1"], [63977, 1, "\u91CC"], [63978, 1, "\u96E2"], [63979, 1, "\u533F"], [63980, 1, "\u6EBA"], [63981, 1, "\u541D"], [63982, 1, "\u71D0"], [63983, 1, "\u7498"], [63984, 1, "\u85FA"], [63985, 1, "\u96A3"], [63986, 1, "\u9C57"], [63987, 1, "\u9E9F"], [63988, 1, "\u6797"], [63989, 1, "\u6DCB"], [63990, 1, "\u81E8"], [63991, 1, "\u7ACB"], [63992, 1, "\u7B20"], [63993, 1, "\u7C92"], [63994, 1, "\u72C0"], [63995, 1, "\u7099"], [63996, 1, "\u8B58"], [63997, 1, "\u4EC0"], [63998, 1, "\u8336"], [63999, 1, "\u523A"], [64e3, 1, "\u5207"], [64001, 1, "\u5EA6"], [64002, 1, "\u62D3"], [64003, 1, "\u7CD6"], [64004, 1, "\u5B85"], [64005, 1, "\u6D1E"], [64006, 1, "\u66B4"], [64007, 1, "\u8F3B"], [64008, 1, "\u884C"], [64009, 1, "\u964D"], [64010, 1, "\u898B"], [64011, 1, "\u5ED3"], [64012, 1, "\u5140"], [64013, 1, "\u55C0"], [[64014, 64015], 2], [64016, 1, "\u585A"], [64017, 2], [64018, 1, "\u6674"], [[64019, 64020], 2], [64021, 1, "\u51DE"], [64022, 1, "\u732A"], [64023, 1, "\u76CA"], [64024, 1, "\u793C"], [64025, 1, "\u795E"], [64026, 1, "\u7965"], [64027, 1, "\u798F"], [64028, 1, "\u9756"], [64029, 1, "\u7CBE"], [64030, 1, "\u7FBD"], [64031, 2], [64032, 1, "\u8612"], [64033, 2], [64034, 1, "\u8AF8"], [[64035, 64036], 2], [64037, 1, "\u9038"], [64038, 1, "\u90FD"], [[64039, 64041], 2], [64042, 1, "\u98EF"], [64043, 1, "\u98FC"], [64044, 1, "\u9928"], [64045, 1, "\u9DB4"], [64046, 1, "\u90DE"], [64047, 1, "\u96B7"], [64048, 1, "\u4FAE"], [64049, 1, "\u50E7"], [64050, 1, "\u514D"], [64051, 1, "\u52C9"], [64052, 1, "\u52E4"], [64053, 1, "\u5351"], [64054, 1, "\u559D"], [64055, 1, "\u5606"], [64056, 1, "\u5668"], [64057, 1, "\u5840"], [64058, 1, "\u58A8"], [64059, 1, "\u5C64"], [64060, 1, "\u5C6E"], [64061, 1, "\u6094"], [64062, 1, "\u6168"], [64063, 1, "\u618E"], [64064, 1, "\u61F2"], [64065, 1, "\u654F"], [64066, 1, "\u65E2"], [64067, 1, "\u6691"], [64068, 1, "\u6885"], [64069, 1, "\u6D77"], [64070, 1, "\u6E1A"], [64071, 1, "\u6F22"], [64072, 1, "\u716E"], [64073, 1, "\u722B"], [64074, 1, "\u7422"], [64075, 1, "\u7891"], [64076, 1, "\u793E"], [64077, 1, "\u7949"], [64078, 1, "\u7948"], [64079, 1, "\u7950"], [64080, 1, "\u7956"], [64081, 1, "\u795D"], [64082, 1, "\u798D"], [64083, 1, "\u798E"], [64084, 1, "\u7A40"], [64085, 1, "\u7A81"], [64086, 1, "\u7BC0"], [64087, 1, "\u7DF4"], [64088, 1, "\u7E09"], [64089, 1, "\u7E41"], [64090, 1, "\u7F72"], [64091, 1, "\u8005"], [64092, 1, "\u81ED"], [[64093, 64094], 1, "\u8279"], [64095, 1, "\u8457"], [64096, 1, "\u8910"], [64097, 1, "\u8996"], [64098, 1, "\u8B01"], [64099, 1, "\u8B39"], [64100, 1, "\u8CD3"], [64101, 1, "\u8D08"], [64102, 1, "\u8FB6"], [64103, 1, "\u9038"], [64104, 1, "\u96E3"], [64105, 1, "\u97FF"], [64106, 1, "\u983B"], [64107, 1, "\u6075"], [64108, 1, "\u{242EE}"], [64109, 1, "\u8218"], [[64110, 64111], 3], [64112, 1, "\u4E26"], [64113, 1, "\u51B5"], [64114, 1, "\u5168"], [64115, 1, "\u4F80"], [64116, 1, "\u5145"], [64117, 1, "\u5180"], [64118, 1, "\u52C7"], [64119, 1, "\u52FA"], [64120, 1, "\u559D"], [64121, 1, "\u5555"], [64122, 1, "\u5599"], [64123, 1, "\u55E2"], [64124, 1, "\u585A"], [64125, 1, "\u58B3"], [64126, 1, "\u5944"], [64127, 1, "\u5954"], [64128, 1, "\u5A62"], [64129, 1, "\u5B28"], [64130, 1, "\u5ED2"], [64131, 1, "\u5ED9"], [64132, 1, "\u5F69"], [64133, 1, "\u5FAD"], [64134, 1, "\u60D8"], [64135, 1, "\u614E"], [64136, 1, "\u6108"], [64137, 1, "\u618E"], [64138, 1, "\u6160"], [64139, 1, "\u61F2"], [64140, 1, "\u6234"], [64141, 1, "\u63C4"], [64142, 1, "\u641C"], [64143, 1, "\u6452"], [64144, 1, "\u6556"], [64145, 1, "\u6674"], [64146, 1, "\u6717"], [64147, 1, "\u671B"], [64148, 1, "\u6756"], [64149, 1, "\u6B79"], [64150, 1, "\u6BBA"], [64151, 1, "\u6D41"], [64152, 1, "\u6EDB"], [64153, 1, "\u6ECB"], [64154, 1, "\u6F22"], [64155, 1, "\u701E"], [64156, 1, "\u716E"], [64157, 1, "\u77A7"], [64158, 1, "\u7235"], [64159, 1, "\u72AF"], [64160, 1, "\u732A"], [64161, 1, "\u7471"], [64162, 1, "\u7506"], [64163, 1, "\u753B"], [64164, 1, "\u761D"], [64165, 1, "\u761F"], [64166, 1, "\u76CA"], [64167, 1, "\u76DB"], [64168, 1, "\u76F4"], [64169, 1, "\u774A"], [64170, 1, "\u7740"], [64171, 1, "\u78CC"], [64172, 1, "\u7AB1"], [64173, 1, "\u7BC0"], [64174, 1, "\u7C7B"], [64175, 1, "\u7D5B"], [64176, 1, "\u7DF4"], [64177, 1, "\u7F3E"], [64178, 1, "\u8005"], [64179, 1, "\u8352"], [64180, 1, "\u83EF"], [64181, 1, "\u8779"], [64182, 1, "\u8941"], [64183, 1, "\u8986"], [64184, 1, "\u8996"], [64185, 1, "\u8ABF"], [64186, 1, "\u8AF8"], [64187, 1, "\u8ACB"], [64188, 1, "\u8B01"], [64189, 1, "\u8AFE"], [64190, 1, "\u8AED"], [64191, 1, "\u8B39"], [64192, 1, "\u8B8A"], [64193, 1, "\u8D08"], [64194, 1, "\u8F38"], [64195, 1, "\u9072"], [64196, 1, "\u9199"], [64197, 1, "\u9276"], [64198, 1, "\u967C"], [64199, 1, "\u96E3"], [64200, 1, "\u9756"], [64201, 1, "\u97DB"], [64202, 1, "\u97FF"], [64203, 1, "\u980B"], [64204, 1, "\u983B"], [64205, 1, "\u9B12"], [64206, 1, "\u9F9C"], [64207, 1, "\u{2284A}"], [64208, 1, "\u{22844}"], [64209, 1, "\u{233D5}"], [64210, 1, "\u3B9D"], [64211, 1, "\u4018"], [64212, 1, "\u4039"], [64213, 1, "\u{25249}"], [64214, 1, "\u{25CD0}"], [64215, 1, "\u{27ED3}"], [64216, 1, "\u9F43"], [64217, 1, "\u9F8E"], [[64218, 64255], 3], [64256, 1, "ff"], [64257, 1, "fi"], [64258, 1, "fl"], [64259, 1, "ffi"], [64260, 1, "ffl"], [[64261, 64262], 1, "st"], [[64263, 64274], 3], [64275, 1, "\u0574\u0576"], [64276, 1, "\u0574\u0565"], [64277, 1, "\u0574\u056B"], [64278, 1, "\u057E\u0576"], [64279, 1, "\u0574\u056D"], [[64280, 64284], 3], [64285, 1, "\u05D9\u05B4"], [64286, 2], [64287, 1, "\u05F2\u05B7"], [64288, 1, "\u05E2"], [64289, 1, "\u05D0"], [64290, 1, "\u05D3"], [64291, 1, "\u05D4"], [64292, 1, "\u05DB"], [64293, 1, "\u05DC"], [64294, 1, "\u05DD"], [64295, 1, "\u05E8"], [64296, 1, "\u05EA"], [64297, 1, "+"], [64298, 1, "\u05E9\u05C1"], [64299, 1, "\u05E9\u05C2"], [64300, 1, "\u05E9\u05BC\u05C1"], [64301, 1, "\u05E9\u05BC\u05C2"], [64302, 1, "\u05D0\u05B7"], [64303, 1, "\u05D0\u05B8"], [64304, 1, "\u05D0\u05BC"], [64305, 1, "\u05D1\u05BC"], [64306, 1, "\u05D2\u05BC"], [64307, 1, "\u05D3\u05BC"], [64308, 1, "\u05D4\u05BC"], [64309, 1, "\u05D5\u05BC"], [64310, 1, "\u05D6\u05BC"], [64311, 3], [64312, 1, "\u05D8\u05BC"], [64313, 1, "\u05D9\u05BC"], [64314, 1, "\u05DA\u05BC"], [64315, 1, "\u05DB\u05BC"], [64316, 1, "\u05DC\u05BC"], [64317, 3], [64318, 1, "\u05DE\u05BC"], [64319, 3], [64320, 1, "\u05E0\u05BC"], [64321, 1, "\u05E1\u05BC"], [64322, 3], [64323, 1, "\u05E3\u05BC"], [64324, 1, "\u05E4\u05BC"], [64325, 3], [64326, 1, "\u05E6\u05BC"], [64327, 1, "\u05E7\u05BC"], [64328, 1, "\u05E8\u05BC"], [64329, 1, "\u05E9\u05BC"], [64330, 1, "\u05EA\u05BC"], [64331, 1, "\u05D5\u05B9"], [64332, 1, "\u05D1\u05BF"], [64333, 1, "\u05DB\u05BF"], [64334, 1, "\u05E4\u05BF"], [64335, 1, "\u05D0\u05DC"], [[64336, 64337], 1, "\u0671"], [[64338, 64341], 1, "\u067B"], [[64342, 64345], 1, "\u067E"], [[64346, 64349], 1, "\u0680"], [[64350, 64353], 1, "\u067A"], [[64354, 64357], 1, "\u067F"], [[64358, 64361], 1, "\u0679"], [[64362, 64365], 1, "\u06A4"], [[64366, 64369], 1, "\u06A6"], [[64370, 64373], 1, "\u0684"], [[64374, 64377], 1, "\u0683"], [[64378, 64381], 1, "\u0686"], [[64382, 64385], 1, "\u0687"], [[64386, 64387], 1, "\u068D"], [[64388, 64389], 1, "\u068C"], [[64390, 64391], 1, "\u068E"], [[64392, 64393], 1, "\u0688"], [[64394, 64395], 1, "\u0698"], [[64396, 64397], 1, "\u0691"], [[64398, 64401], 1, "\u06A9"], [[64402, 64405], 1, "\u06AF"], [[64406, 64409], 1, "\u06B3"], [[64410, 64413], 1, "\u06B1"], [[64414, 64415], 1, "\u06BA"], [[64416, 64419], 1, "\u06BB"], [[64420, 64421], 1, "\u06C0"], [[64422, 64425], 1, "\u06C1"], [[64426, 64429], 1, "\u06BE"], [[64430, 64431], 1, "\u06D2"], [[64432, 64433], 1, "\u06D3"], [[64434, 64449], 2], [64450, 2], [[64451, 64466], 3], [[64467, 64470], 1, "\u06AD"], [[64471, 64472], 1, "\u06C7"], [[64473, 64474], 1, "\u06C6"], [[64475, 64476], 1, "\u06C8"], [64477, 1, "\u06C7\u0674"], [[64478, 64479], 1, "\u06CB"], [[64480, 64481], 1, "\u06C5"], [[64482, 64483], 1, "\u06C9"], [[64484, 64487], 1, "\u06D0"], [[64488, 64489], 1, "\u0649"], [[64490, 64491], 1, "\u0626\u0627"], [[64492, 64493], 1, "\u0626\u06D5"], [[64494, 64495], 1, "\u0626\u0648"], [[64496, 64497], 1, "\u0626\u06C7"], [[64498, 64499], 1, "\u0626\u06C6"], [[64500, 64501], 1, "\u0626\u06C8"], [[64502, 64504], 1, "\u0626\u06D0"], [[64505, 64507], 1, "\u0626\u0649"], [[64508, 64511], 1, "\u06CC"], [64512, 1, "\u0626\u062C"], [64513, 1, "\u0626\u062D"], [64514, 1, "\u0626\u0645"], [64515, 1, "\u0626\u0649"], [64516, 1, "\u0626\u064A"], [64517, 1, "\u0628\u062C"], [64518, 1, "\u0628\u062D"], [64519, 1, "\u0628\u062E"], [64520, 1, "\u0628\u0645"], [64521, 1, "\u0628\u0649"], [64522, 1, "\u0628\u064A"], [64523, 1, "\u062A\u062C"], [64524, 1, "\u062A\u062D"], [64525, 1, "\u062A\u062E"], [64526, 1, "\u062A\u0645"], [64527, 1, "\u062A\u0649"], [64528, 1, "\u062A\u064A"], [64529, 1, "\u062B\u062C"], [64530, 1, "\u062B\u0645"], [64531, 1, "\u062B\u0649"], [64532, 1, "\u062B\u064A"], [64533, 1, "\u062C\u062D"], [64534, 1, "\u062C\u0645"], [64535, 1, "\u062D\u062C"], [64536, 1, "\u062D\u0645"], [64537, 1, "\u062E\u062C"], [64538, 1, "\u062E\u062D"], [64539, 1, "\u062E\u0645"], [64540, 1, "\u0633\u062C"], [64541, 1, "\u0633\u062D"], [64542, 1, "\u0633\u062E"], [64543, 1, "\u0633\u0645"], [64544, 1, "\u0635\u062D"], [64545, 1, "\u0635\u0645"], [64546, 1, "\u0636\u062C"], [64547, 1, "\u0636\u062D"], [64548, 1, "\u0636\u062E"], [64549, 1, "\u0636\u0645"], [64550, 1, "\u0637\u062D"], [64551, 1, "\u0637\u0645"], [64552, 1, "\u0638\u0645"], [64553, 1, "\u0639\u062C"], [64554, 1, "\u0639\u0645"], [64555, 1, "\u063A\u062C"], [64556, 1, "\u063A\u0645"], [64557, 1, "\u0641\u062C"], [64558, 1, "\u0641\u062D"], [64559, 1, "\u0641\u062E"], [64560, 1, "\u0641\u0645"], [64561, 1, "\u0641\u0649"], [64562, 1, "\u0641\u064A"], [64563, 1, "\u0642\u062D"], [64564, 1, "\u0642\u0645"], [64565, 1, "\u0642\u0649"], [64566, 1, "\u0642\u064A"], [64567, 1, "\u0643\u0627"], [64568, 1, "\u0643\u062C"], [64569, 1, "\u0643\u062D"], [64570, 1, "\u0643\u062E"], [64571, 1, "\u0643\u0644"], [64572, 1, "\u0643\u0645"], [64573, 1, "\u0643\u0649"], [64574, 1, "\u0643\u064A"], [64575, 1, "\u0644\u062C"], [64576, 1, "\u0644\u062D"], [64577, 1, "\u0644\u062E"], [64578, 1, "\u0644\u0645"], [64579, 1, "\u0644\u0649"], [64580, 1, "\u0644\u064A"], [64581, 1, "\u0645\u062C"], [64582, 1, "\u0645\u062D"], [64583, 1, "\u0645\u062E"], [64584, 1, "\u0645\u0645"], [64585, 1, "\u0645\u0649"], [64586, 1, "\u0645\u064A"], [64587, 1, "\u0646\u062C"], [64588, 1, "\u0646\u062D"], [64589, 1, "\u0646\u062E"], [64590, 1, "\u0646\u0645"], [64591, 1, "\u0646\u0649"], [64592, 1, "\u0646\u064A"], [64593, 1, "\u0647\u062C"], [64594, 1, "\u0647\u0645"], [64595, 1, "\u0647\u0649"], [64596, 1, "\u0647\u064A"], [64597, 1, "\u064A\u062C"], [64598, 1, "\u064A\u062D"], [64599, 1, "\u064A\u062E"], [64600, 1, "\u064A\u0645"], [64601, 1, "\u064A\u0649"], [64602, 1, "\u064A\u064A"], [64603, 1, "\u0630\u0670"], [64604, 1, "\u0631\u0670"], [64605, 1, "\u0649\u0670"], [64606, 1, " \u064C\u0651"], [64607, 1, " \u064D\u0651"], [64608, 1, " \u064E\u0651"], [64609, 1, " \u064F\u0651"], [64610, 1, " \u0650\u0651"], [64611, 1, " \u0651\u0670"], [64612, 1, "\u0626\u0631"], [64613, 1, "\u0626\u0632"], [64614, 1, "\u0626\u0645"], [64615, 1, "\u0626\u0646"], [64616, 1, "\u0626\u0649"], [64617, 1, "\u0626\u064A"], [64618, 1, "\u0628\u0631"], [64619, 1, "\u0628\u0632"], [64620, 1, "\u0628\u0645"], [64621, 1, "\u0628\u0646"], [64622, 1, "\u0628\u0649"], [64623, 1, "\u0628\u064A"], [64624, 1, "\u062A\u0631"], [64625, 1, "\u062A\u0632"], [64626, 1, "\u062A\u0645"], [64627, 1, "\u062A\u0646"], [64628, 1, "\u062A\u0649"], [64629, 1, "\u062A\u064A"], [64630, 1, "\u062B\u0631"], [64631, 1, "\u062B\u0632"], [64632, 1, "\u062B\u0645"], [64633, 1, "\u062B\u0646"], [64634, 1, "\u062B\u0649"], [64635, 1, "\u062B\u064A"], [64636, 1, "\u0641\u0649"], [64637, 1, "\u0641\u064A"], [64638, 1, "\u0642\u0649"], [64639, 1, "\u0642\u064A"], [64640, 1, "\u0643\u0627"], [64641, 1, "\u0643\u0644"], [64642, 1, "\u0643\u0645"], [64643, 1, "\u0643\u0649"], [64644, 1, "\u0643\u064A"], [64645, 1, "\u0644\u0645"], [64646, 1, "\u0644\u0649"], [64647, 1, "\u0644\u064A"], [64648, 1, "\u0645\u0627"], [64649, 1, "\u0645\u0645"], [64650, 1, "\u0646\u0631"], [64651, 1, "\u0646\u0632"], [64652, 1, "\u0646\u0645"], [64653, 1, "\u0646\u0646"], [64654, 1, "\u0646\u0649"], [64655, 1, "\u0646\u064A"], [64656, 1, "\u0649\u0670"], [64657, 1, "\u064A\u0631"], [64658, 1, "\u064A\u0632"], [64659, 1, "\u064A\u0645"], [64660, 1, "\u064A\u0646"], [64661, 1, "\u064A\u0649"], [64662, 1, "\u064A\u064A"], [64663, 1, "\u0626\u062C"], [64664, 1, "\u0626\u062D"], [64665, 1, "\u0626\u062E"], [64666, 1, "\u0626\u0645"], [64667, 1, "\u0626\u0647"], [64668, 1, "\u0628\u062C"], [64669, 1, "\u0628\u062D"], [64670, 1, "\u0628\u062E"], [64671, 1, "\u0628\u0645"], [64672, 1, "\u0628\u0647"], [64673, 1, "\u062A\u062C"], [64674, 1, "\u062A\u062D"], [64675, 1, "\u062A\u062E"], [64676, 1, "\u062A\u0645"], [64677, 1, "\u062A\u0647"], [64678, 1, "\u062B\u0645"], [64679, 1, "\u062C\u062D"], [64680, 1, "\u062C\u0645"], [64681, 1, "\u062D\u062C"], [64682, 1, "\u062D\u0645"], [64683, 1, "\u062E\u062C"], [64684, 1, "\u062E\u0645"], [64685, 1, "\u0633\u062C"], [64686, 1, "\u0633\u062D"], [64687, 1, "\u0633\u062E"], [64688, 1, "\u0633\u0645"], [64689, 1, "\u0635\u062D"], [64690, 1, "\u0635\u062E"], [64691, 1, "\u0635\u0645"], [64692, 1, "\u0636\u062C"], [64693, 1, "\u0636\u062D"], [64694, 1, "\u0636\u062E"], [64695, 1, "\u0636\u0645"], [64696, 1, "\u0637\u062D"], [64697, 1, "\u0638\u0645"], [64698, 1, "\u0639\u062C"], [64699, 1, "\u0639\u0645"], [64700, 1, "\u063A\u062C"], [64701, 1, "\u063A\u0645"], [64702, 1, "\u0641\u062C"], [64703, 1, "\u0641\u062D"], [64704, 1, "\u0641\u062E"], [64705, 1, "\u0641\u0645"], [64706, 1, "\u0642\u062D"], [64707, 1, "\u0642\u0645"], [64708, 1, "\u0643\u062C"], [64709, 1, "\u0643\u062D"], [64710, 1, "\u0643\u062E"], [64711, 1, "\u0643\u0644"], [64712, 1, "\u0643\u0645"], [64713, 1, "\u0644\u062C"], [64714, 1, "\u0644\u062D"], [64715, 1, "\u0644\u062E"], [64716, 1, "\u0644\u0645"], [64717, 1, "\u0644\u0647"], [64718, 1, "\u0645\u062C"], [64719, 1, "\u0645\u062D"], [64720, 1, "\u0645\u062E"], [64721, 1, "\u0645\u0645"], [64722, 1, "\u0646\u062C"], [64723, 1, "\u0646\u062D"], [64724, 1, "\u0646\u062E"], [64725, 1, "\u0646\u0645"], [64726, 1, "\u0646\u0647"], [64727, 1, "\u0647\u062C"], [64728, 1, "\u0647\u0645"], [64729, 1, "\u0647\u0670"], [64730, 1, "\u064A\u062C"], [64731, 1, "\u064A\u062D"], [64732, 1, "\u064A\u062E"], [64733, 1, "\u064A\u0645"], [64734, 1, "\u064A\u0647"], [64735, 1, "\u0626\u0645"], [64736, 1, "\u0626\u0647"], [64737, 1, "\u0628\u0645"], [64738, 1, "\u0628\u0647"], [64739, 1, "\u062A\u0645"], [64740, 1, "\u062A\u0647"], [64741, 1, "\u062B\u0645"], [64742, 1, "\u062B\u0647"], [64743, 1, "\u0633\u0645"], [64744, 1, "\u0633\u0647"], [64745, 1, "\u0634\u0645"], [64746, 1, "\u0634\u0647"], [64747, 1, "\u0643\u0644"], [64748, 1, "\u0643\u0645"], [64749, 1, "\u0644\u0645"], [64750, 1, "\u0646\u0645"], [64751, 1, "\u0646\u0647"], [64752, 1, "\u064A\u0645"], [64753, 1, "\u064A\u0647"], [64754, 1, "\u0640\u064E\u0651"], [64755, 1, "\u0640\u064F\u0651"], [64756, 1, "\u0640\u0650\u0651"], [64757, 1, "\u0637\u0649"], [64758, 1, "\u0637\u064A"], [64759, 1, "\u0639\u0649"], [64760, 1, "\u0639\u064A"], [64761, 1, "\u063A\u0649"], [64762, 1, "\u063A\u064A"], [64763, 1, "\u0633\u0649"], [64764, 1, "\u0633\u064A"], [64765, 1, "\u0634\u0649"], [64766, 1, "\u0634\u064A"], [64767, 1, "\u062D\u0649"], [64768, 1, "\u062D\u064A"], [64769, 1, "\u062C\u0649"], [64770, 1, "\u062C\u064A"], [64771, 1, "\u062E\u0649"], [64772, 1, "\u062E\u064A"], [64773, 1, "\u0635\u0649"], [64774, 1, "\u0635\u064A"], [64775, 1, "\u0636\u0649"], [64776, 1, "\u0636\u064A"], [64777, 1, "\u0634\u062C"], [64778, 1, "\u0634\u062D"], [64779, 1, "\u0634\u062E"], [64780, 1, "\u0634\u0645"], [64781, 1, "\u0634\u0631"], [64782, 1, "\u0633\u0631"], [64783, 1, "\u0635\u0631"], [64784, 1, "\u0636\u0631"], [64785, 1, "\u0637\u0649"], [64786, 1, "\u0637\u064A"], [64787, 1, "\u0639\u0649"], [64788, 1, "\u0639\u064A"], [64789, 1, "\u063A\u0649"], [64790, 1, "\u063A\u064A"], [64791, 1, "\u0633\u0649"], [64792, 1, "\u0633\u064A"], [64793, 1, "\u0634\u0649"], [64794, 1, "\u0634\u064A"], [64795, 1, "\u062D\u0649"], [64796, 1, "\u062D\u064A"], [64797, 1, "\u062C\u0649"], [64798, 1, "\u062C\u064A"], [64799, 1, "\u062E\u0649"], [64800, 1, "\u062E\u064A"], [64801, 1, "\u0635\u0649"], [64802, 1, "\u0635\u064A"], [64803, 1, "\u0636\u0649"], [64804, 1, "\u0636\u064A"], [64805, 1, "\u0634\u062C"], [64806, 1, "\u0634\u062D"], [64807, 1, "\u0634\u062E"], [64808, 1, "\u0634\u0645"], [64809, 1, "\u0634\u0631"], [64810, 1, "\u0633\u0631"], [64811, 1, "\u0635\u0631"], [64812, 1, "\u0636\u0631"], [64813, 1, "\u0634\u062C"], [64814, 1, "\u0634\u062D"], [64815, 1, "\u0634\u062E"], [64816, 1, "\u0634\u0645"], [64817, 1, "\u0633\u0647"], [64818, 1, "\u0634\u0647"], [64819, 1, "\u0637\u0645"], [64820, 1, "\u0633\u062C"], [64821, 1, "\u0633\u062D"], [64822, 1, "\u0633\u062E"], [64823, 1, "\u0634\u062C"], [64824, 1, "\u0634\u062D"], [64825, 1, "\u0634\u062E"], [64826, 1, "\u0637\u0645"], [64827, 1, "\u0638\u0645"], [[64828, 64829], 1, "\u0627\u064B"], [[64830, 64831], 2], [[64832, 64847], 2], [64848, 1, "\u062A\u062C\u0645"], [[64849, 64850], 1, "\u062A\u062D\u062C"], [64851, 1, "\u062A\u062D\u0645"], [64852, 1, "\u062A\u062E\u0645"], [64853, 1, "\u062A\u0645\u062C"], [64854, 1, "\u062A\u0645\u062D"], [64855, 1, "\u062A\u0645\u062E"], [[64856, 64857], 1, "\u062C\u0645\u062D"], [64858, 1, "\u062D\u0645\u064A"], [64859, 1, "\u062D\u0645\u0649"], [64860, 1, "\u0633\u062D\u062C"], [64861, 1, "\u0633\u062C\u062D"], [64862, 1, "\u0633\u062C\u0649"], [[64863, 64864], 1, "\u0633\u0645\u062D"], [64865, 1, "\u0633\u0645\u062C"], [[64866, 64867], 1, "\u0633\u0645\u0645"], [[64868, 64869], 1, "\u0635\u062D\u062D"], [64870, 1, "\u0635\u0645\u0645"], [[64871, 64872], 1, "\u0634\u062D\u0645"], [64873, 1, "\u0634\u062C\u064A"], [[64874, 64875], 1, "\u0634\u0645\u062E"], [[64876, 64877], 1, "\u0634\u0645\u0645"], [64878, 1, "\u0636\u062D\u0649"], [[64879, 64880], 1, "\u0636\u062E\u0645"], [[64881, 64882], 1, "\u0637\u0645\u062D"], [64883, 1, "\u0637\u0645\u0645"], [64884, 1, "\u0637\u0645\u064A"], [64885, 1, "\u0639\u062C\u0645"], [[64886, 64887], 1, "\u0639\u0645\u0645"], [64888, 1, "\u0639\u0645\u0649"], [64889, 1, "\u063A\u0645\u0645"], [64890, 1, "\u063A\u0645\u064A"], [64891, 1, "\u063A\u0645\u0649"], [[64892, 64893], 1, "\u0641\u062E\u0645"], [64894, 1, "\u0642\u0645\u062D"], [64895, 1, "\u0642\u0645\u0645"], [64896, 1, "\u0644\u062D\u0645"], [64897, 1, "\u0644\u062D\u064A"], [64898, 1, "\u0644\u062D\u0649"], [[64899, 64900], 1, "\u0644\u062C\u062C"], [[64901, 64902], 1, "\u0644\u062E\u0645"], [[64903, 64904], 1, "\u0644\u0645\u062D"], [64905, 1, "\u0645\u062D\u062C"], [64906, 1, "\u0645\u062D\u0645"], [64907, 1, "\u0645\u062D\u064A"], [64908, 1, "\u0645\u062C\u062D"], [64909, 1, "\u0645\u062C\u0645"], [64910, 1, "\u0645\u062E\u062C"], [64911, 1, "\u0645\u062E\u0645"], [[64912, 64913], 3], [64914, 1, "\u0645\u062C\u062E"], [64915, 1, "\u0647\u0645\u062C"], [64916, 1, "\u0647\u0645\u0645"], [64917, 1, "\u0646\u062D\u0645"], [64918, 1, "\u0646\u062D\u0649"], [[64919, 64920], 1, "\u0646\u062C\u0645"], [64921, 1, "\u0646\u062C\u0649"], [64922, 1, "\u0646\u0645\u064A"], [64923, 1, "\u0646\u0645\u0649"], [[64924, 64925], 1, "\u064A\u0645\u0645"], [64926, 1, "\u0628\u062E\u064A"], [64927, 1, "\u062A\u062C\u064A"], [64928, 1, "\u062A\u062C\u0649"], [64929, 1, "\u062A\u062E\u064A"], [64930, 1, "\u062A\u062E\u0649"], [64931, 1, "\u062A\u0645\u064A"], [64932, 1, "\u062A\u0645\u0649"], [64933, 1, "\u062C\u0645\u064A"], [64934, 1, "\u062C\u062D\u0649"], [64935, 1, "\u062C\u0645\u0649"], [64936, 1, "\u0633\u062E\u0649"], [64937, 1, "\u0635\u062D\u064A"], [64938, 1, "\u0634\u062D\u064A"], [64939, 1, "\u0636\u062D\u064A"], [64940, 1, "\u0644\u062C\u064A"], [64941, 1, "\u0644\u0645\u064A"], [64942, 1, "\u064A\u062D\u064A"], [64943, 1, "\u064A\u062C\u064A"], [64944, 1, "\u064A\u0645\u064A"], [64945, 1, "\u0645\u0645\u064A"], [64946, 1, "\u0642\u0645\u064A"], [64947, 1, "\u0646\u062D\u064A"], [64948, 1, "\u0642\u0645\u062D"], [64949, 1, "\u0644\u062D\u0645"], [64950, 1, "\u0639\u0645\u064A"], [64951, 1, "\u0643\u0645\u064A"], [64952, 1, "\u0646\u062C\u062D"], [64953, 1, "\u0645\u062E\u064A"], [64954, 1, "\u0644\u062C\u0645"], [64955, 1, "\u0643\u0645\u0645"], [64956, 1, "\u0644\u062C\u0645"], [64957, 1, "\u0646\u062C\u062D"], [64958, 1, "\u062C\u062D\u064A"], [64959, 1, "\u062D\u062C\u064A"], [64960, 1, "\u0645\u062C\u064A"], [64961, 1, "\u0641\u0645\u064A"], [64962, 1, "\u0628\u062D\u064A"], [64963, 1, "\u0643\u0645\u0645"], [64964, 1, "\u0639\u062C\u0645"], [64965, 1, "\u0635\u0645\u0645"], [64966, 1, "\u0633\u062E\u064A"], [64967, 1, "\u0646\u062C\u064A"], [[64968, 64974], 3], [64975, 2], [[64976, 65007], 3], [65008, 1, "\u0635\u0644\u06D2"], [65009, 1, "\u0642\u0644\u06D2"], [65010, 1, "\u0627\u0644\u0644\u0647"], [65011, 1, "\u0627\u0643\u0628\u0631"], [65012, 1, "\u0645\u062D\u0645\u062F"], [65013, 1, "\u0635\u0644\u0639\u0645"], [65014, 1, "\u0631\u0633\u0648\u0644"], [65015, 1, "\u0639\u0644\u064A\u0647"], [65016, 1, "\u0648\u0633\u0644\u0645"], [65017, 1, "\u0635\u0644\u0649"], [65018, 1, "\u0635\u0644\u0649 \u0627\u0644\u0644\u0647 \u0639\u0644\u064A\u0647 \u0648\u0633\u0644\u0645"], [65019, 1, "\u062C\u0644 \u062C\u0644\u0627\u0644\u0647"], [65020, 1, "\u0631\u06CC\u0627\u0644"], [65021, 2], [[65022, 65023], 2], [[65024, 65039], 7], [65040, 1, ","], [65041, 1, "\u3001"], [65042, 3], [65043, 1, ":"], [65044, 1, ";"], [65045, 1, "!"], [65046, 1, "?"], [65047, 1, "\u3016"], [65048, 1, "\u3017"], [65049, 3], [[65050, 65055], 3], [[65056, 65059], 2], [[65060, 65062], 2], [[65063, 65069], 2], [[65070, 65071], 2], [65072, 3], [65073, 1, "\u2014"], [65074, 1, "\u2013"], [[65075, 65076], 1, "_"], [65077, 1, "("], [65078, 1, ")"], [65079, 1, "{"], [65080, 1, "}"], [65081, 1, "\u3014"], [65082, 1, "\u3015"], [65083, 1, "\u3010"], [65084, 1, "\u3011"], [65085, 1, "\u300A"], [65086, 1, "\u300B"], [65087, 1, "\u3008"], [65088, 1, "\u3009"], [65089, 1, "\u300C"], [65090, 1, "\u300D"], [65091, 1, "\u300E"], [65092, 1, "\u300F"], [[65093, 65094], 2], [65095, 1, "["], [65096, 1, "]"], [[65097, 65100], 1, " \u0305"], [[65101, 65103], 1, "_"], [65104, 1, ","], [65105, 1, "\u3001"], [65106, 3], [65107, 3], [65108, 1, ";"], [65109, 1, ":"], [65110, 1, "?"], [65111, 1, "!"], [65112, 1, "\u2014"], [65113, 1, "("], [65114, 1, ")"], [65115, 1, "{"], [65116, 1, "}"], [65117, 1, "\u3014"], [65118, 1, "\u3015"], [65119, 1, "#"], [65120, 1, "&"], [65121, 1, "*"], [65122, 1, "+"], [65123, 1, "-"], [65124, 1, "<"], [65125, 1, ">"], [65126, 1, "="], [65127, 3], [65128, 1, "\\"], [65129, 1, "$"], [65130, 1, "%"], [65131, 1, "@"], [[65132, 65135], 3], [65136, 1, " \u064B"], [65137, 1, "\u0640\u064B"], [65138, 1, " \u064C"], [65139, 2], [65140, 1, " \u064D"], [65141, 3], [65142, 1, " \u064E"], [65143, 1, "\u0640\u064E"], [65144, 1, " \u064F"], [65145, 1, "\u0640\u064F"], [65146, 1, " \u0650"], [65147, 1, "\u0640\u0650"], [65148, 1, " \u0651"], [65149, 1, "\u0640\u0651"], [65150, 1, " \u0652"], [65151, 1, "\u0640\u0652"], [65152, 1, "\u0621"], [[65153, 65154], 1, "\u0622"], [[65155, 65156], 1, "\u0623"], [[65157, 65158], 1, "\u0624"], [[65159, 65160], 1, "\u0625"], [[65161, 65164], 1, "\u0626"], [[65165, 65166], 1, "\u0627"], [[65167, 65170], 1, "\u0628"], [[65171, 65172], 1, "\u0629"], [[65173, 65176], 1, "\u062A"], [[65177, 65180], 1, "\u062B"], [[65181, 65184], 1, "\u062C"], [[65185, 65188], 1, "\u062D"], [[65189, 65192], 1, "\u062E"], [[65193, 65194], 1, "\u062F"], [[65195, 65196], 1, "\u0630"], [[65197, 65198], 1, "\u0631"], [[65199, 65200], 1, "\u0632"], [[65201, 65204], 1, "\u0633"], [[65205, 65208], 1, "\u0634"], [[65209, 65212], 1, "\u0635"], [[65213, 65216], 1, "\u0636"], [[65217, 65220], 1, "\u0637"], [[65221, 65224], 1, "\u0638"], [[65225, 65228], 1, "\u0639"], [[65229, 65232], 1, "\u063A"], [[65233, 65236], 1, "\u0641"], [[65237, 65240], 1, "\u0642"], [[65241, 65244], 1, "\u0643"], [[65245, 65248], 1, "\u0644"], [[65249, 65252], 1, "\u0645"], [[65253, 65256], 1, "\u0646"], [[65257, 65260], 1, "\u0647"], [[65261, 65262], 1, "\u0648"], [[65263, 65264], 1, "\u0649"], [[65265, 65268], 1, "\u064A"], [[65269, 65270], 1, "\u0644\u0622"], [[65271, 65272], 1, "\u0644\u0623"], [[65273, 65274], 1, "\u0644\u0625"], [[65275, 65276], 1, "\u0644\u0627"], [[65277, 65278], 3], [65279, 7], [65280, 3], [65281, 1, "!"], [65282, 1, '"'], [65283, 1, "#"], [65284, 1, "$"], [65285, 1, "%"], [65286, 1, "&"], [65287, 1, "'"], [65288, 1, "("], [65289, 1, ")"], [65290, 1, "*"], [65291, 1, "+"], [65292, 1, ","], [65293, 1, "-"], [65294, 1, "."], [65295, 1, "/"], [65296, 1, "0"], [65297, 1, "1"], [65298, 1, "2"], [65299, 1, "3"], [65300, 1, "4"], [65301, 1, "5"], [65302, 1, "6"], [65303, 1, "7"], [65304, 1, "8"], [65305, 1, "9"], [65306, 1, ":"], [65307, 1, ";"], [65308, 1, "<"], [65309, 1, "="], [65310, 1, ">"], [65311, 1, "?"], [65312, 1, "@"], [65313, 1, "a"], [65314, 1, "b"], [65315, 1, "c"], [65316, 1, "d"], [65317, 1, "e"], [65318, 1, "f"], [65319, 1, "g"], [65320, 1, "h"], [65321, 1, "i"], [65322, 1, "j"], [65323, 1, "k"], [65324, 1, "l"], [65325, 1, "m"], [65326, 1, "n"], [65327, 1, "o"], [65328, 1, "p"], [65329, 1, "q"], [65330, 1, "r"], [65331, 1, "s"], [65332, 1, "t"], [65333, 1, "u"], [65334, 1, "v"], [65335, 1, "w"], [65336, 1, "x"], [65337, 1, "y"], [65338, 1, "z"], [65339, 1, "["], [65340, 1, "\\"], [65341, 1, "]"], [65342, 1, "^"], [65343, 1, "_"], [65344, 1, "`"], [65345, 1, "a"], [65346, 1, "b"], [65347, 1, "c"], [65348, 1, "d"], [65349, 1, "e"], [65350, 1, "f"], [65351, 1, "g"], [65352, 1, "h"], [65353, 1, "i"], [65354, 1, "j"], [65355, 1, "k"], [65356, 1, "l"], [65357, 1, "m"], [65358, 1, "n"], [65359, 1, "o"], [65360, 1, "p"], [65361, 1, "q"], [65362, 1, "r"], [65363, 1, "s"], [65364, 1, "t"], [65365, 1, "u"], [65366, 1, "v"], [65367, 1, "w"], [65368, 1, "x"], [65369, 1, "y"], [65370, 1, "z"], [65371, 1, "{"], [65372, 1, "|"], [65373, 1, "}"], [65374, 1, "~"], [65375, 1, "\u2985"], [65376, 1, "\u2986"], [65377, 1, "."], [65378, 1, "\u300C"], [65379, 1, "\u300D"], [65380, 1, "\u3001"], [65381, 1, "\u30FB"], [65382, 1, "\u30F2"], [65383, 1, "\u30A1"], [65384, 1, "\u30A3"], [65385, 1, "\u30A5"], [65386, 1, "\u30A7"], [65387, 1, "\u30A9"], [65388, 1, "\u30E3"], [65389, 1, "\u30E5"], [65390, 1, "\u30E7"], [65391, 1, "\u30C3"], [65392, 1, "\u30FC"], [65393, 1, "\u30A2"], [65394, 1, "\u30A4"], [65395, 1, "\u30A6"], [65396, 1, "\u30A8"], [65397, 1, "\u30AA"], [65398, 1, "\u30AB"], [65399, 1, "\u30AD"], [65400, 1, "\u30AF"], [65401, 1, "\u30B1"], [65402, 1, "\u30B3"], [65403, 1, "\u30B5"], [65404, 1, "\u30B7"], [65405, 1, "\u30B9"], [65406, 1, "\u30BB"], [65407, 1, "\u30BD"], [65408, 1, "\u30BF"], [65409, 1, "\u30C1"], [65410, 1, "\u30C4"], [65411, 1, "\u30C6"], [65412, 1, "\u30C8"], [65413, 1, "\u30CA"], [65414, 1, "\u30CB"], [65415, 1, "\u30CC"], [65416, 1, "\u30CD"], [65417, 1, "\u30CE"], [65418, 1, "\u30CF"], [65419, 1, "\u30D2"], [65420, 1, "\u30D5"], [65421, 1, "\u30D8"], [65422, 1, "\u30DB"], [65423, 1, "\u30DE"], [65424, 1, "\u30DF"], [65425, 1, "\u30E0"], [65426, 1, "\u30E1"], [65427, 1, "\u30E2"], [65428, 1, "\u30E4"], [65429, 1, "\u30E6"], [65430, 1, "\u30E8"], [65431, 1, "\u30E9"], [65432, 1, "\u30EA"], [65433, 1, "\u30EB"], [65434, 1, "\u30EC"], [65435, 1, "\u30ED"], [65436, 1, "\u30EF"], [65437, 1, "\u30F3"], [65438, 1, "\u3099"], [65439, 1, "\u309A"], [65440, 7], [65441, 1, "\u1100"], [65442, 1, "\u1101"], [65443, 1, "\u11AA"], [65444, 1, "\u1102"], [65445, 1, "\u11AC"], [65446, 1, "\u11AD"], [65447, 1, "\u1103"], [65448, 1, "\u1104"], [65449, 1, "\u1105"], [65450, 1, "\u11B0"], [65451, 1, "\u11B1"], [65452, 1, "\u11B2"], [65453, 1, "\u11B3"], [65454, 1, "\u11B4"], [65455, 1, "\u11B5"], [65456, 1, "\u111A"], [65457, 1, "\u1106"], [65458, 1, "\u1107"], [65459, 1, "\u1108"], [65460, 1, "\u1121"], [65461, 1, "\u1109"], [65462, 1, "\u110A"], [65463, 1, "\u110B"], [65464, 1, "\u110C"], [65465, 1, "\u110D"], [65466, 1, "\u110E"], [65467, 1, "\u110F"], [65468, 1, "\u1110"], [65469, 1, "\u1111"], [65470, 1, "\u1112"], [[65471, 65473], 3], [65474, 1, "\u1161"], [65475, 1, "\u1162"], [65476, 1, "\u1163"], [65477, 1, "\u1164"], [65478, 1, "\u1165"], [65479, 1, "\u1166"], [[65480, 65481], 3], [65482, 1, "\u1167"], [65483, 1, "\u1168"], [65484, 1, "\u1169"], [65485, 1, "\u116A"], [65486, 1, "\u116B"], [65487, 1, "\u116C"], [[65488, 65489], 3], [65490, 1, "\u116D"], [65491, 1, "\u116E"], [65492, 1, "\u116F"], [65493, 1, "\u1170"], [65494, 1, "\u1171"], [65495, 1, "\u1172"], [[65496, 65497], 3], [65498, 1, "\u1173"], [65499, 1, "\u1174"], [65500, 1, "\u1175"], [[65501, 65503], 3], [65504, 1, "\xA2"], [65505, 1, "\xA3"], [65506, 1, "\xAC"], [65507, 1, " \u0304"], [65508, 1, "\xA6"], [65509, 1, "\xA5"], [65510, 1, "\u20A9"], [65511, 3], [65512, 1, "\u2502"], [65513, 1, "\u2190"], [65514, 1, "\u2191"], [65515, 1, "\u2192"], [65516, 1, "\u2193"], [65517, 1, "\u25A0"], [65518, 1, "\u25CB"], [[65519, 65528], 3], [[65529, 65531], 3], [65532, 3], [65533, 3], [[65534, 65535], 3], [[65536, 65547], 2], [65548, 3], [[65549, 65574], 2], [65575, 3], [[65576, 65594], 2], [65595, 3], [[65596, 65597], 2], [65598, 3], [[65599, 65613], 2], [[65614, 65615], 3], [[65616, 65629], 2], [[65630, 65663], 3], [[65664, 65786], 2], [[65787, 65791], 3], [[65792, 65794], 2], [[65795, 65798], 3], [[65799, 65843], 2], [[65844, 65846], 3], [[65847, 65855], 2], [[65856, 65930], 2], [[65931, 65932], 2], [[65933, 65934], 2], [65935, 3], [[65936, 65947], 2], [65948, 2], [[65949, 65951], 3], [65952, 2], [[65953, 65999], 3], [[66e3, 66044], 2], [66045, 2], [[66046, 66175], 3], [[66176, 66204], 2], [[66205, 66207], 3], [[66208, 66256], 2], [[66257, 66271], 3], [66272, 2], [[66273, 66299], 2], [[66300, 66303], 3], [[66304, 66334], 2], [66335, 2], [[66336, 66339], 2], [[66340, 66348], 3], [[66349, 66351], 2], [[66352, 66368], 2], [66369, 2], [[66370, 66377], 2], [66378, 2], [[66379, 66383], 3], [[66384, 66426], 2], [[66427, 66431], 3], [[66432, 66461], 2], [66462, 3], [66463, 2], [[66464, 66499], 2], [[66500, 66503], 3], [[66504, 66511], 2], [[66512, 66517], 2], [[66518, 66559], 3], [66560, 1, "\u{10428}"], [66561, 1, "\u{10429}"], [66562, 1, "\u{1042A}"], [66563, 1, "\u{1042B}"], [66564, 1, "\u{1042C}"], [66565, 1, "\u{1042D}"], [66566, 1, "\u{1042E}"], [66567, 1, "\u{1042F}"], [66568, 1, "\u{10430}"], [66569, 1, "\u{10431}"], [66570, 1, "\u{10432}"], [66571, 1, "\u{10433}"], [66572, 1, "\u{10434}"], [66573, 1, "\u{10435}"], [66574, 1, "\u{10436}"], [66575, 1, "\u{10437}"], [66576, 1, "\u{10438}"], [66577, 1, "\u{10439}"], [66578, 1, "\u{1043A}"], [66579, 1, "\u{1043B}"], [66580, 1, "\u{1043C}"], [66581, 1, "\u{1043D}"], [66582, 1, "\u{1043E}"], [66583, 1, "\u{1043F}"], [66584, 1, "\u{10440}"], [66585, 1, "\u{10441}"], [66586, 1, "\u{10442}"], [66587, 1, "\u{10443}"], [66588, 1, "\u{10444}"], [66589, 1, "\u{10445}"], [66590, 1, "\u{10446}"], [66591, 1, "\u{10447}"], [66592, 1, "\u{10448}"], [66593, 1, "\u{10449}"], [66594, 1, "\u{1044A}"], [66595, 1, "\u{1044B}"], [66596, 1, "\u{1044C}"], [66597, 1, "\u{1044D}"], [66598, 1, "\u{1044E}"], [66599, 1, "\u{1044F}"], [[66600, 66637], 2], [[66638, 66717], 2], [[66718, 66719], 3], [[66720, 66729], 2], [[66730, 66735], 3], [66736, 1, "\u{104D8}"], [66737, 1, "\u{104D9}"], [66738, 1, "\u{104DA}"], [66739, 1, "\u{104DB}"], [66740, 1, "\u{104DC}"], [66741, 1, "\u{104DD}"], [66742, 1, "\u{104DE}"], [66743, 1, "\u{104DF}"], [66744, 1, "\u{104E0}"], [66745, 1, "\u{104E1}"], [66746, 1, "\u{104E2}"], [66747, 1, "\u{104E3}"], [66748, 1, "\u{104E4}"], [66749, 1, "\u{104E5}"], [66750, 1, "\u{104E6}"], [66751, 1, "\u{104E7}"], [66752, 1, "\u{104E8}"], [66753, 1, "\u{104E9}"], [66754, 1, "\u{104EA}"], [66755, 1, "\u{104EB}"], [66756, 1, "\u{104EC}"], [66757, 1, "\u{104ED}"], [66758, 1, "\u{104EE}"], [66759, 1, "\u{104EF}"], [66760, 1, "\u{104F0}"], [66761, 1, "\u{104F1}"], [66762, 1, "\u{104F2}"], [66763, 1, "\u{104F3}"], [66764, 1, "\u{104F4}"], [66765, 1, "\u{104F5}"], [66766, 1, "\u{104F6}"], [66767, 1, "\u{104F7}"], [66768, 1, "\u{104F8}"], [66769, 1, "\u{104F9}"], [66770, 1, "\u{104FA}"], [66771, 1, "\u{104FB}"], [[66772, 66775], 3], [[66776, 66811], 2], [[66812, 66815], 3], [[66816, 66855], 2], [[66856, 66863], 3], [[66864, 66915], 2], [[66916, 66926], 3], [66927, 2], [66928, 1, "\u{10597}"], [66929, 1, "\u{10598}"], [66930, 1, "\u{10599}"], [66931, 1, "\u{1059A}"], [66932, 1, "\u{1059B}"], [66933, 1, "\u{1059C}"], [66934, 1, "\u{1059D}"], [66935, 1, "\u{1059E}"], [66936, 1, "\u{1059F}"], [66937, 1, "\u{105A0}"], [66938, 1, "\u{105A1}"], [66939, 3], [66940, 1, "\u{105A3}"], [66941, 1, "\u{105A4}"], [66942, 1, "\u{105A5}"], [66943, 1, "\u{105A6}"], [66944, 1, "\u{105A7}"], [66945, 1, "\u{105A8}"], [66946, 1, "\u{105A9}"], [66947, 1, "\u{105AA}"], [66948, 1, "\u{105AB}"], [66949, 1, "\u{105AC}"], [66950, 1, "\u{105AD}"], [66951, 1, "\u{105AE}"], [66952, 1, "\u{105AF}"], [66953, 1, "\u{105B0}"], [66954, 1, "\u{105B1}"], [66955, 3], [66956, 1, "\u{105B3}"], [66957, 1, "\u{105B4}"], [66958, 1, "\u{105B5}"], [66959, 1, "\u{105B6}"], [66960, 1, "\u{105B7}"], [66961, 1, "\u{105B8}"], [66962, 1, "\u{105B9}"], [66963, 3], [66964, 1, "\u{105BB}"], [66965, 1, "\u{105BC}"], [66966, 3], [[66967, 66977], 2], [66978, 3], [[66979, 66993], 2], [66994, 3], [[66995, 67001], 2], [67002, 3], [[67003, 67004], 2], [[67005, 67007], 3], [[67008, 67059], 2], [[67060, 67071], 3], [[67072, 67382], 2], [[67383, 67391], 3], [[67392, 67413], 2], [[67414, 67423], 3], [[67424, 67431], 2], [[67432, 67455], 3], [67456, 2], [67457, 1, "\u02D0"], [67458, 1, "\u02D1"], [67459, 1, "\xE6"], [67460, 1, "\u0299"], [67461, 1, "\u0253"], [67462, 3], [67463, 1, "\u02A3"], [67464, 1, "\uAB66"], [67465, 1, "\u02A5"], [67466, 1, "\u02A4"], [67467, 1, "\u0256"], [67468, 1, "\u0257"], [67469, 1, "\u1D91"], [67470, 1, "\u0258"], [67471, 1, "\u025E"], [67472, 1, "\u02A9"], [67473, 1, "\u0264"], [67474, 1, "\u0262"], [67475, 1, "\u0260"], [67476, 1, "\u029B"], [67477, 1, "\u0127"], [67478, 1, "\u029C"], [67479, 1, "\u0267"], [67480, 1, "\u0284"], [67481, 1, "\u02AA"], [67482, 1, "\u02AB"], [67483, 1, "\u026C"], [67484, 1, "\u{1DF04}"], [67485, 1, "\uA78E"], [67486, 1, "\u026E"], [67487, 1, "\u{1DF05}"], [67488, 1, "\u028E"], [67489, 1, "\u{1DF06}"], [67490, 1, "\xF8"], [67491, 1, "\u0276"], [67492, 1, "\u0277"], [67493, 1, "q"], [67494, 1, "\u027A"], [67495, 1, "\u{1DF08}"], [67496, 1, "\u027D"], [67497, 1, "\u027E"], [67498, 1, "\u0280"], [67499, 1, "\u02A8"], [67500, 1, "\u02A6"], [67501, 1, "\uAB67"], [67502, 1, "\u02A7"], [67503, 1, "\u0288"], [67504, 1, "\u2C71"], [67505, 3], [67506, 1, "\u028F"], [67507, 1, "\u02A1"], [67508, 1, "\u02A2"], [67509, 1, "\u0298"], [67510, 1, "\u01C0"], [67511, 1, "\u01C1"], [67512, 1, "\u01C2"], [67513, 1, "\u{1DF0A}"], [67514, 1, "\u{1DF1E}"], [[67515, 67583], 3], [[67584, 67589], 2], [[67590, 67591], 3], [67592, 2], [67593, 3], [[67594, 67637], 2], [67638, 3], [[67639, 67640], 2], [[67641, 67643], 3], [67644, 2], [[67645, 67646], 3], [67647, 2], [[67648, 67669], 2], [67670, 3], [[67671, 67679], 2], [[67680, 67702], 2], [[67703, 67711], 2], [[67712, 67742], 2], [[67743, 67750], 3], [[67751, 67759], 2], [[67760, 67807], 3], [[67808, 67826], 2], [67827, 3], [[67828, 67829], 2], [[67830, 67834], 3], [[67835, 67839], 2], [[67840, 67861], 2], [[67862, 67865], 2], [[67866, 67867], 2], [[67868, 67870], 3], [67871, 2], [[67872, 67897], 2], [[67898, 67902], 3], [67903, 2], [[67904, 67967], 3], [[67968, 68023], 2], [[68024, 68027], 3], [[68028, 68029], 2], [[68030, 68031], 2], [[68032, 68047], 2], [[68048, 68049], 3], [[68050, 68095], 2], [[68096, 68099], 2], [68100, 3], [[68101, 68102], 2], [[68103, 68107], 3], [[68108, 68115], 2], [68116, 3], [[68117, 68119], 2], [68120, 3], [[68121, 68147], 2], [[68148, 68149], 2], [[68150, 68151], 3], [[68152, 68154], 2], [[68155, 68158], 3], [68159, 2], [[68160, 68167], 2], [68168, 2], [[68169, 68175], 3], [[68176, 68184], 2], [[68185, 68191], 3], [[68192, 68220], 2], [[68221, 68223], 2], [[68224, 68252], 2], [[68253, 68255], 2], [[68256, 68287], 3], [[68288, 68295], 2], [68296, 2], [[68297, 68326], 2], [[68327, 68330], 3], [[68331, 68342], 2], [[68343, 68351], 3], [[68352, 68405], 2], [[68406, 68408], 3], [[68409, 68415], 2], [[68416, 68437], 2], [[68438, 68439], 3], [[68440, 68447], 2], [[68448, 68466], 2], [[68467, 68471], 3], [[68472, 68479], 2], [[68480, 68497], 2], [[68498, 68504], 3], [[68505, 68508], 2], [[68509, 68520], 3], [[68521, 68527], 2], [[68528, 68607], 3], [[68608, 68680], 2], [[68681, 68735], 3], [68736, 1, "\u{10CC0}"], [68737, 1, "\u{10CC1}"], [68738, 1, "\u{10CC2}"], [68739, 1, "\u{10CC3}"], [68740, 1, "\u{10CC4}"], [68741, 1, "\u{10CC5}"], [68742, 1, "\u{10CC6}"], [68743, 1, "\u{10CC7}"], [68744, 1, "\u{10CC8}"], [68745, 1, "\u{10CC9}"], [68746, 1, "\u{10CCA}"], [68747, 1, "\u{10CCB}"], [68748, 1, "\u{10CCC}"], [68749, 1, "\u{10CCD}"], [68750, 1, "\u{10CCE}"], [68751, 1, "\u{10CCF}"], [68752, 1, "\u{10CD0}"], [68753, 1, "\u{10CD1}"], [68754, 1, "\u{10CD2}"], [68755, 1, "\u{10CD3}"], [68756, 1, "\u{10CD4}"], [68757, 1, "\u{10CD5}"], [68758, 1, "\u{10CD6}"], [68759, 1, "\u{10CD7}"], [68760, 1, "\u{10CD8}"], [68761, 1, "\u{10CD9}"], [68762, 1, "\u{10CDA}"], [68763, 1, "\u{10CDB}"], [68764, 1, "\u{10CDC}"], [68765, 1, "\u{10CDD}"], [68766, 1, "\u{10CDE}"], [68767, 1, "\u{10CDF}"], [68768, 1, "\u{10CE0}"], [68769, 1, "\u{10CE1}"], [68770, 1, "\u{10CE2}"], [68771, 1, "\u{10CE3}"], [68772, 1, "\u{10CE4}"], [68773, 1, "\u{10CE5}"], [68774, 1, "\u{10CE6}"], [68775, 1, "\u{10CE7}"], [68776, 1, "\u{10CE8}"], [68777, 1, "\u{10CE9}"], [68778, 1, "\u{10CEA}"], [68779, 1, "\u{10CEB}"], [68780, 1, "\u{10CEC}"], [68781, 1, "\u{10CED}"], [68782, 1, "\u{10CEE}"], [68783, 1, "\u{10CEF}"], [68784, 1, "\u{10CF0}"], [68785, 1, "\u{10CF1}"], [68786, 1, "\u{10CF2}"], [[68787, 68799], 3], [[68800, 68850], 2], [[68851, 68857], 3], [[68858, 68863], 2], [[68864, 68903], 2], [[68904, 68911], 3], [[68912, 68921], 2], [[68922, 68927], 3], [[68928, 68943], 2], [68944, 1, "\u{10D70}"], [68945, 1, "\u{10D71}"], [68946, 1, "\u{10D72}"], [68947, 1, "\u{10D73}"], [68948, 1, "\u{10D74}"], [68949, 1, "\u{10D75}"], [68950, 1, "\u{10D76}"], [68951, 1, "\u{10D77}"], [68952, 1, "\u{10D78}"], [68953, 1, "\u{10D79}"], [68954, 1, "\u{10D7A}"], [68955, 1, "\u{10D7B}"], [68956, 1, "\u{10D7C}"], [68957, 1, "\u{10D7D}"], [68958, 1, "\u{10D7E}"], [68959, 1, "\u{10D7F}"], [68960, 1, "\u{10D80}"], [68961, 1, "\u{10D81}"], [68962, 1, "\u{10D82}"], [68963, 1, "\u{10D83}"], [68964, 1, "\u{10D84}"], [68965, 1, "\u{10D85}"], [[68966, 68968], 3], [[68969, 68973], 2], [68974, 2], [[68975, 68997], 2], [[68998, 69005], 3], [[69006, 69007], 2], [[69008, 69215], 3], [[69216, 69246], 2], [69247, 3], [[69248, 69289], 2], [69290, 3], [[69291, 69292], 2], [69293, 2], [[69294, 69295], 3], [[69296, 69297], 2], [[69298, 69313], 3], [[69314, 69316], 2], [[69317, 69371], 3], [69372, 2], [[69373, 69375], 2], [[69376, 69404], 2], [[69405, 69414], 2], [69415, 2], [[69416, 69423], 3], [[69424, 69456], 2], [[69457, 69465], 2], [[69466, 69487], 3], [[69488, 69509], 2], [[69510, 69513], 2], [[69514, 69551], 3], [[69552, 69572], 2], [[69573, 69579], 2], [[69580, 69599], 3], [[69600, 69622], 2], [[69623, 69631], 3], [[69632, 69702], 2], [[69703, 69709], 2], [[69710, 69713], 3], [[69714, 69733], 2], [[69734, 69743], 2], [[69744, 69749], 2], [[69750, 69758], 3], [69759, 2], [[69760, 69818], 2], [[69819, 69820], 2], [69821, 3], [[69822, 69825], 2], [69826, 2], [[69827, 69836], 3], [69837, 3], [[69838, 69839], 3], [[69840, 69864], 2], [[69865, 69871], 3], [[69872, 69881], 2], [[69882, 69887], 3], [[69888, 69940], 2], [69941, 3], [[69942, 69951], 2], [[69952, 69955], 2], [[69956, 69958], 2], [69959, 2], [[69960, 69967], 3], [[69968, 70003], 2], [[70004, 70005], 2], [70006, 2], [[70007, 70015], 3], [[70016, 70084], 2], [[70085, 70088], 2], [[70089, 70092], 2], [70093, 2], [[70094, 70095], 2], [[70096, 70105], 2], [70106, 2], [70107, 2], [70108, 2], [[70109, 70111], 2], [70112, 3], [[70113, 70132], 2], [[70133, 70143], 3], [[70144, 70161], 2], [70162, 3], [[70163, 70199], 2], [[70200, 70205], 2], [70206, 2], [[70207, 70209], 2], [[70210, 70271], 3], [[70272, 70278], 2], [70279, 3], [70280, 2], [70281, 3], [[70282, 70285], 2], [70286, 3], [[70287, 70301], 2], [70302, 3], [[70303, 70312], 2], [70313, 2], [[70314, 70319], 3], [[70320, 70378], 2], [[70379, 70383], 3], [[70384, 70393], 2], [[70394, 70399], 3], [70400, 2], [[70401, 70403], 2], [70404, 3], [[70405, 70412], 2], [[70413, 70414], 3], [[70415, 70416], 2], [[70417, 70418], 3], [[70419, 70440], 2], [70441, 3], [[70442, 70448], 2], [70449, 3], [[70450, 70451], 2], [70452, 3], [[70453, 70457], 2], [70458, 3], [70459, 2], [[70460, 70468], 2], [[70469, 70470], 3], [[70471, 70472], 2], [[70473, 70474], 3], [[70475, 70477], 2], [[70478, 70479], 3], [70480, 2], [[70481, 70486], 3], [70487, 2], [[70488, 70492], 3], [[70493, 70499], 2], [[70500, 70501], 3], [[70502, 70508], 2], [[70509, 70511], 3], [[70512, 70516], 2], [[70517, 70527], 3], [[70528, 70537], 2], [70538, 3], [70539, 2], [[70540, 70541], 3], [70542, 2], [70543, 3], [[70544, 70581], 2], [70582, 3], [[70583, 70592], 2], [70593, 3], [70594, 2], [[70595, 70596], 3], [70597, 2], [70598, 3], [[70599, 70602], 2], [70603, 3], [[70604, 70611], 2], [[70612, 70613], 2], [70614, 3], [[70615, 70616], 2], [[70617, 70624], 3], [[70625, 70626], 2], [[70627, 70655], 3], [[70656, 70730], 2], [[70731, 70735], 2], [[70736, 70745], 2], [70746, 2], [70747, 2], [70748, 3], [70749, 2], [70750, 2], [70751, 2], [[70752, 70753], 2], [[70754, 70783], 3], [[70784, 70853], 2], [70854, 2], [70855, 2], [[70856, 70863], 3], [[70864, 70873], 2], [[70874, 71039], 3], [[71040, 71093], 2], [[71094, 71095], 3], [[71096, 71104], 2], [[71105, 71113], 2], [[71114, 71127], 2], [[71128, 71133], 2], [[71134, 71167], 3], [[71168, 71232], 2], [[71233, 71235], 2], [71236, 2], [[71237, 71247], 3], [[71248, 71257], 2], [[71258, 71263], 3], [[71264, 71276], 2], [[71277, 71295], 3], [[71296, 71351], 2], [71352, 2], [71353, 2], [[71354, 71359], 3], [[71360, 71369], 2], [[71370, 71375], 3], [[71376, 71395], 2], [[71396, 71423], 3], [[71424, 71449], 2], [71450, 2], [[71451, 71452], 3], [[71453, 71467], 2], [[71468, 71471], 3], [[71472, 71481], 2], [[71482, 71487], 2], [[71488, 71494], 2], [[71495, 71679], 3], [[71680, 71738], 2], [71739, 2], [[71740, 71839], 3], [71840, 1, "\u{118C0}"], [71841, 1, "\u{118C1}"], [71842, 1, "\u{118C2}"], [71843, 1, "\u{118C3}"], [71844, 1, "\u{118C4}"], [71845, 1, "\u{118C5}"], [71846, 1, "\u{118C6}"], [71847, 1, "\u{118C7}"], [71848, 1, "\u{118C8}"], [71849, 1, "\u{118C9}"], [71850, 1, "\u{118CA}"], [71851, 1, "\u{118CB}"], [71852, 1, "\u{118CC}"], [71853, 1, "\u{118CD}"], [71854, 1, "\u{118CE}"], [71855, 1, "\u{118CF}"], [71856, 1, "\u{118D0}"], [71857, 1, "\u{118D1}"], [71858, 1, "\u{118D2}"], [71859, 1, "\u{118D3}"], [71860, 1, "\u{118D4}"], [71861, 1, "\u{118D5}"], [71862, 1, "\u{118D6}"], [71863, 1, "\u{118D7}"], [71864, 1, "\u{118D8}"], [71865, 1, "\u{118D9}"], [71866, 1, "\u{118DA}"], [71867, 1, "\u{118DB}"], [71868, 1, "\u{118DC}"], [71869, 1, "\u{118DD}"], [71870, 1, "\u{118DE}"], [71871, 1, "\u{118DF}"], [[71872, 71913], 2], [[71914, 71922], 2], [[71923, 71934], 3], [71935, 2], [[71936, 71942], 2], [[71943, 71944], 3], [71945, 2], [[71946, 71947], 3], [[71948, 71955], 2], [71956, 3], [[71957, 71958], 2], [71959, 3], [[71960, 71989], 2], [71990, 3], [[71991, 71992], 2], [[71993, 71994], 3], [[71995, 72003], 2], [[72004, 72006], 2], [[72007, 72015], 3], [[72016, 72025], 2], [[72026, 72095], 3], [[72096, 72103], 2], [[72104, 72105], 3], [[72106, 72151], 2], [[72152, 72153], 3], [[72154, 72161], 2], [72162, 2], [[72163, 72164], 2], [[72165, 72191], 3], [[72192, 72254], 2], [[72255, 72262], 2], [72263, 2], [[72264, 72271], 3], [[72272, 72323], 2], [[72324, 72325], 2], [[72326, 72345], 2], [[72346, 72348], 2], [72349, 2], [[72350, 72354], 2], [[72355, 72367], 3], [[72368, 72383], 2], [[72384, 72440], 2], [[72441, 72447], 3], [[72448, 72457], 2], [[72458, 72639], 3], [[72640, 72672], 2], [72673, 2], [[72674, 72687], 3], [[72688, 72697], 2], [[72698, 72703], 3], [[72704, 72712], 2], [72713, 3], [[72714, 72758], 2], [72759, 3], [[72760, 72768], 2], [[72769, 72773], 2], [[72774, 72783], 3], [[72784, 72793], 2], [[72794, 72812], 2], [[72813, 72815], 3], [[72816, 72817], 2], [[72818, 72847], 2], [[72848, 72849], 3], [[72850, 72871], 2], [72872, 3], [[72873, 72886], 2], [[72887, 72959], 3], [[72960, 72966], 2], [72967, 3], [[72968, 72969], 2], [72970, 3], [[72971, 73014], 2], [[73015, 73017], 3], [73018, 2], [73019, 3], [[73020, 73021], 2], [73022, 3], [[73023, 73031], 2], [[73032, 73039], 3], [[73040, 73049], 2], [[73050, 73055], 3], [[73056, 73061], 2], [73062, 3], [[73063, 73064], 2], [73065, 3], [[73066, 73102], 2], [73103, 3], [[73104, 73105], 2], [73106, 3], [[73107, 73112], 2], [[73113, 73119], 3], [[73120, 73129], 2], [[73130, 73439], 3], [[73440, 73462], 2], [[73463, 73464], 2], [[73465, 73471], 3], [[73472, 73488], 2], [73489, 3], [[73490, 73530], 2], [[73531, 73533], 3], [[73534, 73538], 2], [[73539, 73551], 2], [[73552, 73561], 2], [73562, 2], [[73563, 73647], 3], [73648, 2], [[73649, 73663], 3], [[73664, 73713], 2], [[73714, 73726], 3], [73727, 2], [[73728, 74606], 2], [[74607, 74648], 2], [74649, 2], [[74650, 74751], 3], [[74752, 74850], 2], [[74851, 74862], 2], [74863, 3], [[74864, 74867], 2], [74868, 2], [[74869, 74879], 3], [[74880, 75075], 2], [[75076, 77711], 3], [[77712, 77808], 2], [[77809, 77810], 2], [[77811, 77823], 3], [[77824, 78894], 2], [78895, 2], [[78896, 78904], 3], [[78905, 78911], 3], [[78912, 78933], 2], [[78934, 78943], 3], [[78944, 82938], 2], [[82939, 82943], 3], [[82944, 83526], 2], [[83527, 90367], 3], [[90368, 90425], 2], [[90426, 92159], 3], [[92160, 92728], 2], [[92729, 92735], 3], [[92736, 92766], 2], [92767, 3], [[92768, 92777], 2], [[92778, 92781], 3], [[92782, 92783], 2], [[92784, 92862], 2], [92863, 3], [[92864, 92873], 2], [[92874, 92879], 3], [[92880, 92909], 2], [[92910, 92911], 3], [[92912, 92916], 2], [92917, 2], [[92918, 92927], 3], [[92928, 92982], 2], [[92983, 92991], 2], [[92992, 92995], 2], [[92996, 92997], 2], [[92998, 93007], 3], [[93008, 93017], 2], [93018, 3], [[93019, 93025], 2], [93026, 3], [[93027, 93047], 2], [[93048, 93052], 3], [[93053, 93071], 2], [[93072, 93503], 3], [[93504, 93548], 2], [[93549, 93551], 2], [[93552, 93561], 2], [[93562, 93759], 3], [93760, 1, "\u{16E60}"], [93761, 1, "\u{16E61}"], [93762, 1, "\u{16E62}"], [93763, 1, "\u{16E63}"], [93764, 1, "\u{16E64}"], [93765, 1, "\u{16E65}"], [93766, 1, "\u{16E66}"], [93767, 1, "\u{16E67}"], [93768, 1, "\u{16E68}"], [93769, 1, "\u{16E69}"], [93770, 1, "\u{16E6A}"], [93771, 1, "\u{16E6B}"], [93772, 1, "\u{16E6C}"], [93773, 1, "\u{16E6D}"], [93774, 1, "\u{16E6E}"], [93775, 1, "\u{16E6F}"], [93776, 1, "\u{16E70}"], [93777, 1, "\u{16E71}"], [93778, 1, "\u{16E72}"], [93779, 1, "\u{16E73}"], [93780, 1, "\u{16E74}"], [93781, 1, "\u{16E75}"], [93782, 1, "\u{16E76}"], [93783, 1, "\u{16E77}"], [93784, 1, "\u{16E78}"], [93785, 1, "\u{16E79}"], [93786, 1, "\u{16E7A}"], [93787, 1, "\u{16E7B}"], [93788, 1, "\u{16E7C}"], [93789, 1, "\u{16E7D}"], [93790, 1, "\u{16E7E}"], [93791, 1, "\u{16E7F}"], [[93792, 93823], 2], [[93824, 93850], 2], [[93851, 93951], 3], [[93952, 94020], 2], [[94021, 94026], 2], [[94027, 94030], 3], [94031, 2], [[94032, 94078], 2], [[94079, 94087], 2], [[94088, 94094], 3], [[94095, 94111], 2], [[94112, 94175], 3], [94176, 2], [94177, 2], [94178, 2], [94179, 2], [94180, 2], [[94181, 94191], 3], [[94192, 94193], 2], [[94194, 94207], 3], [[94208, 100332], 2], [[100333, 100337], 2], [[100338, 100343], 2], [[100344, 100351], 3], [[100352, 101106], 2], [[101107, 101589], 2], [[101590, 101630], 3], [101631, 2], [[101632, 101640], 2], [[101641, 110575], 3], [[110576, 110579], 2], [110580, 3], [[110581, 110587], 2], [110588, 3], [[110589, 110590], 2], [110591, 3], [[110592, 110593], 2], [[110594, 110878], 2], [[110879, 110882], 2], [[110883, 110897], 3], [110898, 2], [[110899, 110927], 3], [[110928, 110930], 2], [[110931, 110932], 3], [110933, 2], [[110934, 110947], 3], [[110948, 110951], 2], [[110952, 110959], 3], [[110960, 111355], 2], [[111356, 113663], 3], [[113664, 113770], 2], [[113771, 113775], 3], [[113776, 113788], 2], [[113789, 113791], 3], [[113792, 113800], 2], [[113801, 113807], 3], [[113808, 113817], 2], [[113818, 113819], 3], [113820, 2], [[113821, 113822], 2], [113823, 2], [[113824, 113827], 7], [[113828, 117759], 3], [[117760, 117973], 2], [117974, 1, "a"], [117975, 1, "b"], [117976, 1, "c"], [117977, 1, "d"], [117978, 1, "e"], [117979, 1, "f"], [117980, 1, "g"], [117981, 1, "h"], [117982, 1, "i"], [117983, 1, "j"], [117984, 1, "k"], [117985, 1, "l"], [117986, 1, "m"], [117987, 1, "n"], [117988, 1, "o"], [117989, 1, "p"], [117990, 1, "q"], [117991, 1, "r"], [117992, 1, "s"], [117993, 1, "t"], [117994, 1, "u"], [117995, 1, "v"], [117996, 1, "w"], [117997, 1, "x"], [117998, 1, "y"], [117999, 1, "z"], [118e3, 1, "0"], [118001, 1, "1"], [118002, 1, "2"], [118003, 1, "3"], [118004, 1, "4"], [118005, 1, "5"], [118006, 1, "6"], [118007, 1, "7"], [118008, 1, "8"], [118009, 1, "9"], [[118010, 118015], 3], [[118016, 118451], 2], [[118452, 118527], 3], [[118528, 118573], 2], [[118574, 118575], 3], [[118576, 118598], 2], [[118599, 118607], 3], [[118608, 118723], 2], [[118724, 118783], 3], [[118784, 119029], 2], [[119030, 119039], 3], [[119040, 119078], 2], [[119079, 119080], 3], [119081, 2], [[119082, 119133], 2], [119134, 1, "\u{1D157}\u{1D165}"], [119135, 1, "\u{1D158}\u{1D165}"], [119136, 1, "\u{1D158}\u{1D165}\u{1D16E}"], [119137, 1, "\u{1D158}\u{1D165}\u{1D16F}"], [119138, 1, "\u{1D158}\u{1D165}\u{1D170}"], [119139, 1, "\u{1D158}\u{1D165}\u{1D171}"], [119140, 1, "\u{1D158}\u{1D165}\u{1D172}"], [[119141, 119154], 2], [[119155, 119162], 7], [[119163, 119226], 2], [119227, 1, "\u{1D1B9}\u{1D165}"], [119228, 1, "\u{1D1BA}\u{1D165}"], [119229, 1, "\u{1D1B9}\u{1D165}\u{1D16E}"], [119230, 1, "\u{1D1BA}\u{1D165}\u{1D16E}"], [119231, 1, "\u{1D1B9}\u{1D165}\u{1D16F}"], [119232, 1, "\u{1D1BA}\u{1D165}\u{1D16F}"], [[119233, 119261], 2], [[119262, 119272], 2], [[119273, 119274], 2], [[119275, 119295], 3], [[119296, 119365], 2], [[119366, 119487], 3], [[119488, 119507], 2], [[119508, 119519], 3], [[119520, 119539], 2], [[119540, 119551], 3], [[119552, 119638], 2], [[119639, 119647], 3], [[119648, 119665], 2], [[119666, 119672], 2], [[119673, 119807], 3], [119808, 1, "a"], [119809, 1, "b"], [119810, 1, "c"], [119811, 1, "d"], [119812, 1, "e"], [119813, 1, "f"], [119814, 1, "g"], [119815, 1, "h"], [119816, 1, "i"], [119817, 1, "j"], [119818, 1, "k"], [119819, 1, "l"], [119820, 1, "m"], [119821, 1, "n"], [119822, 1, "o"], [119823, 1, "p"], [119824, 1, "q"], [119825, 1, "r"], [119826, 1, "s"], [119827, 1, "t"], [119828, 1, "u"], [119829, 1, "v"], [119830, 1, "w"], [119831, 1, "x"], [119832, 1, "y"], [119833, 1, "z"], [119834, 1, "a"], [119835, 1, "b"], [119836, 1, "c"], [119837, 1, "d"], [119838, 1, "e"], [119839, 1, "f"], [119840, 1, "g"], [119841, 1, "h"], [119842, 1, "i"], [119843, 1, "j"], [119844, 1, "k"], [119845, 1, "l"], [119846, 1, "m"], [119847, 1, "n"], [119848, 1, "o"], [119849, 1, "p"], [119850, 1, "q"], [119851, 1, "r"], [119852, 1, "s"], [119853, 1, "t"], [119854, 1, "u"], [119855, 1, "v"], [119856, 1, "w"], [119857, 1, "x"], [119858, 1, "y"], [119859, 1, "z"], [119860, 1, "a"], [119861, 1, "b"], [119862, 1, "c"], [119863, 1, "d"], [119864, 1, "e"], [119865, 1, "f"], [119866, 1, "g"], [119867, 1, "h"], [119868, 1, "i"], [119869, 1, "j"], [119870, 1, "k"], [119871, 1, "l"], [119872, 1, "m"], [119873, 1, "n"], [119874, 1, "o"], [119875, 1, "p"], [119876, 1, "q"], [119877, 1, "r"], [119878, 1, "s"], [119879, 1, "t"], [119880, 1, "u"], [119881, 1, "v"], [119882, 1, "w"], [119883, 1, "x"], [119884, 1, "y"], [119885, 1, "z"], [119886, 1, "a"], [119887, 1, "b"], [119888, 1, "c"], [119889, 1, "d"], [119890, 1, "e"], [119891, 1, "f"], [119892, 1, "g"], [119893, 3], [119894, 1, "i"], [119895, 1, "j"], [119896, 1, "k"], [119897, 1, "l"], [119898, 1, "m"], [119899, 1, "n"], [119900, 1, "o"], [119901, 1, "p"], [119902, 1, "q"], [119903, 1, "r"], [119904, 1, "s"], [119905, 1, "t"], [119906, 1, "u"], [119907, 1, "v"], [119908, 1, "w"], [119909, 1, "x"], [119910, 1, "y"], [119911, 1, "z"], [119912, 1, "a"], [119913, 1, "b"], [119914, 1, "c"], [119915, 1, "d"], [119916, 1, "e"], [119917, 1, "f"], [119918, 1, "g"], [119919, 1, "h"], [119920, 1, "i"], [119921, 1, "j"], [119922, 1, "k"], [119923, 1, "l"], [119924, 1, "m"], [119925, 1, "n"], [119926, 1, "o"], [119927, 1, "p"], [119928, 1, "q"], [119929, 1, "r"], [119930, 1, "s"], [119931, 1, "t"], [119932, 1, "u"], [119933, 1, "v"], [119934, 1, "w"], [119935, 1, "x"], [119936, 1, "y"], [119937, 1, "z"], [119938, 1, "a"], [119939, 1, "b"], [119940, 1, "c"], [119941, 1, "d"], [119942, 1, "e"], [119943, 1, "f"], [119944, 1, "g"], [119945, 1, "h"], [119946, 1, "i"], [119947, 1, "j"], [119948, 1, "k"], [119949, 1, "l"], [119950, 1, "m"], [119951, 1, "n"], [119952, 1, "o"], [119953, 1, "p"], [119954, 1, "q"], [119955, 1, "r"], [119956, 1, "s"], [119957, 1, "t"], [119958, 1, "u"], [119959, 1, "v"], [119960, 1, "w"], [119961, 1, "x"], [119962, 1, "y"], [119963, 1, "z"], [119964, 1, "a"], [119965, 3], [119966, 1, "c"], [119967, 1, "d"], [[119968, 119969], 3], [119970, 1, "g"], [[119971, 119972], 3], [119973, 1, "j"], [119974, 1, "k"], [[119975, 119976], 3], [119977, 1, "n"], [119978, 1, "o"], [119979, 1, "p"], [119980, 1, "q"], [119981, 3], [119982, 1, "s"], [119983, 1, "t"], [119984, 1, "u"], [119985, 1, "v"], [119986, 1, "w"], [119987, 1, "x"], [119988, 1, "y"], [119989, 1, "z"], [119990, 1, "a"], [119991, 1, "b"], [119992, 1, "c"], [119993, 1, "d"], [119994, 3], [119995, 1, "f"], [119996, 3], [119997, 1, "h"], [119998, 1, "i"], [119999, 1, "j"], [12e4, 1, "k"], [120001, 1, "l"], [120002, 1, "m"], [120003, 1, "n"], [120004, 3], [120005, 1, "p"], [120006, 1, "q"], [120007, 1, "r"], [120008, 1, "s"], [120009, 1, "t"], [120010, 1, "u"], [120011, 1, "v"], [120012, 1, "w"], [120013, 1, "x"], [120014, 1, "y"], [120015, 1, "z"], [120016, 1, "a"], [120017, 1, "b"], [120018, 1, "c"], [120019, 1, "d"], [120020, 1, "e"], [120021, 1, "f"], [120022, 1, "g"], [120023, 1, "h"], [120024, 1, "i"], [120025, 1, "j"], [120026, 1, "k"], [120027, 1, "l"], [120028, 1, "m"], [120029, 1, "n"], [120030, 1, "o"], [120031, 1, "p"], [120032, 1, "q"], [120033, 1, "r"], [120034, 1, "s"], [120035, 1, "t"], [120036, 1, "u"], [120037, 1, "v"], [120038, 1, "w"], [120039, 1, "x"], [120040, 1, "y"], [120041, 1, "z"], [120042, 1, "a"], [120043, 1, "b"], [120044, 1, "c"], [120045, 1, "d"], [120046, 1, "e"], [120047, 1, "f"], [120048, 1, "g"], [120049, 1, "h"], [120050, 1, "i"], [120051, 1, "j"], [120052, 1, "k"], [120053, 1, "l"], [120054, 1, "m"], [120055, 1, "n"], [120056, 1, "o"], [120057, 1, "p"], [120058, 1, "q"], [120059, 1, "r"], [120060, 1, "s"], [120061, 1, "t"], [120062, 1, "u"], [120063, 1, "v"], [120064, 1, "w"], [120065, 1, "x"], [120066, 1, "y"], [120067, 1, "z"], [120068, 1, "a"], [120069, 1, "b"], [120070, 3], [120071, 1, "d"], [120072, 1, "e"], [120073, 1, "f"], [120074, 1, "g"], [[120075, 120076], 3], [120077, 1, "j"], [120078, 1, "k"], [120079, 1, "l"], [120080, 1, "m"], [120081, 1, "n"], [120082, 1, "o"], [120083, 1, "p"], [120084, 1, "q"], [120085, 3], [120086, 1, "s"], [120087, 1, "t"], [120088, 1, "u"], [120089, 1, "v"], [120090, 1, "w"], [120091, 1, "x"], [120092, 1, "y"], [120093, 3], [120094, 1, "a"], [120095, 1, "b"], [120096, 1, "c"], [120097, 1, "d"], [120098, 1, "e"], [120099, 1, "f"], [120100, 1, "g"], [120101, 1, "h"], [120102, 1, "i"], [120103, 1, "j"], [120104, 1, "k"], [120105, 1, "l"], [120106, 1, "m"], [120107, 1, "n"], [120108, 1, "o"], [120109, 1, "p"], [120110, 1, "q"], [120111, 1, "r"], [120112, 1, "s"], [120113, 1, "t"], [120114, 1, "u"], [120115, 1, "v"], [120116, 1, "w"], [120117, 1, "x"], [120118, 1, "y"], [120119, 1, "z"], [120120, 1, "a"], [120121, 1, "b"], [120122, 3], [120123, 1, "d"], [120124, 1, "e"], [120125, 1, "f"], [120126, 1, "g"], [120127, 3], [120128, 1, "i"], [120129, 1, "j"], [120130, 1, "k"], [120131, 1, "l"], [120132, 1, "m"], [120133, 3], [120134, 1, "o"], [[120135, 120137], 3], [120138, 1, "s"], [120139, 1, "t"], [120140, 1, "u"], [120141, 1, "v"], [120142, 1, "w"], [120143, 1, "x"], [120144, 1, "y"], [120145, 3], [120146, 1, "a"], [120147, 1, "b"], [120148, 1, "c"], [120149, 1, "d"], [120150, 1, "e"], [120151, 1, "f"], [120152, 1, "g"], [120153, 1, "h"], [120154, 1, "i"], [120155, 1, "j"], [120156, 1, "k"], [120157, 1, "l"], [120158, 1, "m"], [120159, 1, "n"], [120160, 1, "o"], [120161, 1, "p"], [120162, 1, "q"], [120163, 1, "r"], [120164, 1, "s"], [120165, 1, "t"], [120166, 1, "u"], [120167, 1, "v"], [120168, 1, "w"], [120169, 1, "x"], [120170, 1, "y"], [120171, 1, "z"], [120172, 1, "a"], [120173, 1, "b"], [120174, 1, "c"], [120175, 1, "d"], [120176, 1, "e"], [120177, 1, "f"], [120178, 1, "g"], [120179, 1, "h"], [120180, 1, "i"], [120181, 1, "j"], [120182, 1, "k"], [120183, 1, "l"], [120184, 1, "m"], [120185, 1, "n"], [120186, 1, "o"], [120187, 1, "p"], [120188, 1, "q"], [120189, 1, "r"], [120190, 1, "s"], [120191, 1, "t"], [120192, 1, "u"], [120193, 1, "v"], [120194, 1, "w"], [120195, 1, "x"], [120196, 1, "y"], [120197, 1, "z"], [120198, 1, "a"], [120199, 1, "b"], [120200, 1, "c"], [120201, 1, "d"], [120202, 1, "e"], [120203, 1, "f"], [120204, 1, "g"], [120205, 1, "h"], [120206, 1, "i"], [120207, 1, "j"], [120208, 1, "k"], [120209, 1, "l"], [120210, 1, "m"], [120211, 1, "n"], [120212, 1, "o"], [120213, 1, "p"], [120214, 1, "q"], [120215, 1, "r"], [120216, 1, "s"], [120217, 1, "t"], [120218, 1, "u"], [120219, 1, "v"], [120220, 1, "w"], [120221, 1, "x"], [120222, 1, "y"], [120223, 1, "z"], [120224, 1, "a"], [120225, 1, "b"], [120226, 1, "c"], [120227, 1, "d"], [120228, 1, "e"], [120229, 1, "f"], [120230, 1, "g"], [120231, 1, "h"], [120232, 1, "i"], [120233, 1, "j"], [120234, 1, "k"], [120235, 1, "l"], [120236, 1, "m"], [120237, 1, "n"], [120238, 1, "o"], [120239, 1, "p"], [120240, 1, "q"], [120241, 1, "r"], [120242, 1, "s"], [120243, 1, "t"], [120244, 1, "u"], [120245, 1, "v"], [120246, 1, "w"], [120247, 1, "x"], [120248, 1, "y"], [120249, 1, "z"], [120250, 1, "a"], [120251, 1, "b"], [120252, 1, "c"], [120253, 1, "d"], [120254, 1, "e"], [120255, 1, "f"], [120256, 1, "g"], [120257, 1, "h"], [120258, 1, "i"], [120259, 1, "j"], [120260, 1, "k"], [120261, 1, "l"], [120262, 1, "m"], [120263, 1, "n"], [120264, 1, "o"], [120265, 1, "p"], [120266, 1, "q"], [120267, 1, "r"], [120268, 1, "s"], [120269, 1, "t"], [120270, 1, "u"], [120271, 1, "v"], [120272, 1, "w"], [120273, 1, "x"], [120274, 1, "y"], [120275, 1, "z"], [120276, 1, "a"], [120277, 1, "b"], [120278, 1, "c"], [120279, 1, "d"], [120280, 1, "e"], [120281, 1, "f"], [120282, 1, "g"], [120283, 1, "h"], [120284, 1, "i"], [120285, 1, "j"], [120286, 1, "k"], [120287, 1, "l"], [120288, 1, "m"], [120289, 1, "n"], [120290, 1, "o"], [120291, 1, "p"], [120292, 1, "q"], [120293, 1, "r"], [120294, 1, "s"], [120295, 1, "t"], [120296, 1, "u"], [120297, 1, "v"], [120298, 1, "w"], [120299, 1, "x"], [120300, 1, "y"], [120301, 1, "z"], [120302, 1, "a"], [120303, 1, "b"], [120304, 1, "c"], [120305, 1, "d"], [120306, 1, "e"], [120307, 1, "f"], [120308, 1, "g"], [120309, 1, "h"], [120310, 1, "i"], [120311, 1, "j"], [120312, 1, "k"], [120313, 1, "l"], [120314, 1, "m"], [120315, 1, "n"], [120316, 1, "o"], [120317, 1, "p"], [120318, 1, "q"], [120319, 1, "r"], [120320, 1, "s"], [120321, 1, "t"], [120322, 1, "u"], [120323, 1, "v"], [120324, 1, "w"], [120325, 1, "x"], [120326, 1, "y"], [120327, 1, "z"], [120328, 1, "a"], [120329, 1, "b"], [120330, 1, "c"], [120331, 1, "d"], [120332, 1, "e"], [120333, 1, "f"], [120334, 1, "g"], [120335, 1, "h"], [120336, 1, "i"], [120337, 1, "j"], [120338, 1, "k"], [120339, 1, "l"], [120340, 1, "m"], [120341, 1, "n"], [120342, 1, "o"], [120343, 1, "p"], [120344, 1, "q"], [120345, 1, "r"], [120346, 1, "s"], [120347, 1, "t"], [120348, 1, "u"], [120349, 1, "v"], [120350, 1, "w"], [120351, 1, "x"], [120352, 1, "y"], [120353, 1, "z"], [120354, 1, "a"], [120355, 1, "b"], [120356, 1, "c"], [120357, 1, "d"], [120358, 1, "e"], [120359, 1, "f"], [120360, 1, "g"], [120361, 1, "h"], [120362, 1, "i"], [120363, 1, "j"], [120364, 1, "k"], [120365, 1, "l"], [120366, 1, "m"], [120367, 1, "n"], [120368, 1, "o"], [120369, 1, "p"], [120370, 1, "q"], [120371, 1, "r"], [120372, 1, "s"], [120373, 1, "t"], [120374, 1, "u"], [120375, 1, "v"], [120376, 1, "w"], [120377, 1, "x"], [120378, 1, "y"], [120379, 1, "z"], [120380, 1, "a"], [120381, 1, "b"], [120382, 1, "c"], [120383, 1, "d"], [120384, 1, "e"], [120385, 1, "f"], [120386, 1, "g"], [120387, 1, "h"], [120388, 1, "i"], [120389, 1, "j"], [120390, 1, "k"], [120391, 1, "l"], [120392, 1, "m"], [120393, 1, "n"], [120394, 1, "o"], [120395, 1, "p"], [120396, 1, "q"], [120397, 1, "r"], [120398, 1, "s"], [120399, 1, "t"], [120400, 1, "u"], [120401, 1, "v"], [120402, 1, "w"], [120403, 1, "x"], [120404, 1, "y"], [120405, 1, "z"], [120406, 1, "a"], [120407, 1, "b"], [120408, 1, "c"], [120409, 1, "d"], [120410, 1, "e"], [120411, 1, "f"], [120412, 1, "g"], [120413, 1, "h"], [120414, 1, "i"], [120415, 1, "j"], [120416, 1, "k"], [120417, 1, "l"], [120418, 1, "m"], [120419, 1, "n"], [120420, 1, "o"], [120421, 1, "p"], [120422, 1, "q"], [120423, 1, "r"], [120424, 1, "s"], [120425, 1, "t"], [120426, 1, "u"], [120427, 1, "v"], [120428, 1, "w"], [120429, 1, "x"], [120430, 1, "y"], [120431, 1, "z"], [120432, 1, "a"], [120433, 1, "b"], [120434, 1, "c"], [120435, 1, "d"], [120436, 1, "e"], [120437, 1, "f"], [120438, 1, "g"], [120439, 1, "h"], [120440, 1, "i"], [120441, 1, "j"], [120442, 1, "k"], [120443, 1, "l"], [120444, 1, "m"], [120445, 1, "n"], [120446, 1, "o"], [120447, 1, "p"], [120448, 1, "q"], [120449, 1, "r"], [120450, 1, "s"], [120451, 1, "t"], [120452, 1, "u"], [120453, 1, "v"], [120454, 1, "w"], [120455, 1, "x"], [120456, 1, "y"], [120457, 1, "z"], [120458, 1, "a"], [120459, 1, "b"], [120460, 1, "c"], [120461, 1, "d"], [120462, 1, "e"], [120463, 1, "f"], [120464, 1, "g"], [120465, 1, "h"], [120466, 1, "i"], [120467, 1, "j"], [120468, 1, "k"], [120469, 1, "l"], [120470, 1, "m"], [120471, 1, "n"], [120472, 1, "o"], [120473, 1, "p"], [120474, 1, "q"], [120475, 1, "r"], [120476, 1, "s"], [120477, 1, "t"], [120478, 1, "u"], [120479, 1, "v"], [120480, 1, "w"], [120481, 1, "x"], [120482, 1, "y"], [120483, 1, "z"], [120484, 1, "\u0131"], [120485, 1, "\u0237"], [[120486, 120487], 3], [120488, 1, "\u03B1"], [120489, 1, "\u03B2"], [120490, 1, "\u03B3"], [120491, 1, "\u03B4"], [120492, 1, "\u03B5"], [120493, 1, "\u03B6"], [120494, 1, "\u03B7"], [120495, 1, "\u03B8"], [120496, 1, "\u03B9"], [120497, 1, "\u03BA"], [120498, 1, "\u03BB"], [120499, 1, "\u03BC"], [120500, 1, "\u03BD"], [120501, 1, "\u03BE"], [120502, 1, "\u03BF"], [120503, 1, "\u03C0"], [120504, 1, "\u03C1"], [120505, 1, "\u03B8"], [120506, 1, "\u03C3"], [120507, 1, "\u03C4"], [120508, 1, "\u03C5"], [120509, 1, "\u03C6"], [120510, 1, "\u03C7"], [120511, 1, "\u03C8"], [120512, 1, "\u03C9"], [120513, 1, "\u2207"], [120514, 1, "\u03B1"], [120515, 1, "\u03B2"], [120516, 1, "\u03B3"], [120517, 1, "\u03B4"], [120518, 1, "\u03B5"], [120519, 1, "\u03B6"], [120520, 1, "\u03B7"], [120521, 1, "\u03B8"], [120522, 1, "\u03B9"], [120523, 1, "\u03BA"], [120524, 1, "\u03BB"], [120525, 1, "\u03BC"], [120526, 1, "\u03BD"], [120527, 1, "\u03BE"], [120528, 1, "\u03BF"], [120529, 1, "\u03C0"], [120530, 1, "\u03C1"], [[120531, 120532], 1, "\u03C3"], [120533, 1, "\u03C4"], [120534, 1, "\u03C5"], [120535, 1, "\u03C6"], [120536, 1, "\u03C7"], [120537, 1, "\u03C8"], [120538, 1, "\u03C9"], [120539, 1, "\u2202"], [120540, 1, "\u03B5"], [120541, 1, "\u03B8"], [120542, 1, "\u03BA"], [120543, 1, "\u03C6"], [120544, 1, "\u03C1"], [120545, 1, "\u03C0"], [120546, 1, "\u03B1"], [120547, 1, "\u03B2"], [120548, 1, "\u03B3"], [120549, 1, "\u03B4"], [120550, 1, "\u03B5"], [120551, 1, "\u03B6"], [120552, 1, "\u03B7"], [120553, 1, "\u03B8"], [120554, 1, "\u03B9"], [120555, 1, "\u03BA"], [120556, 1, "\u03BB"], [120557, 1, "\u03BC"], [120558, 1, "\u03BD"], [120559, 1, "\u03BE"], [120560, 1, "\u03BF"], [120561, 1, "\u03C0"], [120562, 1, "\u03C1"], [120563, 1, "\u03B8"], [120564, 1, "\u03C3"], [120565, 1, "\u03C4"], [120566, 1, "\u03C5"], [120567, 1, "\u03C6"], [120568, 1, "\u03C7"], [120569, 1, "\u03C8"], [120570, 1, "\u03C9"], [120571, 1, "\u2207"], [120572, 1, "\u03B1"], [120573, 1, "\u03B2"], [120574, 1, "\u03B3"], [120575, 1, "\u03B4"], [120576, 1, "\u03B5"], [120577, 1, "\u03B6"], [120578, 1, "\u03B7"], [120579, 1, "\u03B8"], [120580, 1, "\u03B9"], [120581, 1, "\u03BA"], [120582, 1, "\u03BB"], [120583, 1, "\u03BC"], [120584, 1, "\u03BD"], [120585, 1, "\u03BE"], [120586, 1, "\u03BF"], [120587, 1, "\u03C0"], [120588, 1, "\u03C1"], [[120589, 120590], 1, "\u03C3"], [120591, 1, "\u03C4"], [120592, 1, "\u03C5"], [120593, 1, "\u03C6"], [120594, 1, "\u03C7"], [120595, 1, "\u03C8"], [120596, 1, "\u03C9"], [120597, 1, "\u2202"], [120598, 1, "\u03B5"], [120599, 1, "\u03B8"], [120600, 1, "\u03BA"], [120601, 1, "\u03C6"], [120602, 1, "\u03C1"], [120603, 1, "\u03C0"], [120604, 1, "\u03B1"], [120605, 1, "\u03B2"], [120606, 1, "\u03B3"], [120607, 1, "\u03B4"], [120608, 1, "\u03B5"], [120609, 1, "\u03B6"], [120610, 1, "\u03B7"], [120611, 1, "\u03B8"], [120612, 1, "\u03B9"], [120613, 1, "\u03BA"], [120614, 1, "\u03BB"], [120615, 1, "\u03BC"], [120616, 1, "\u03BD"], [120617, 1, "\u03BE"], [120618, 1, "\u03BF"], [120619, 1, "\u03C0"], [120620, 1, "\u03C1"], [120621, 1, "\u03B8"], [120622, 1, "\u03C3"], [120623, 1, "\u03C4"], [120624, 1, "\u03C5"], [120625, 1, "\u03C6"], [120626, 1, "\u03C7"], [120627, 1, "\u03C8"], [120628, 1, "\u03C9"], [120629, 1, "\u2207"], [120630, 1, "\u03B1"], [120631, 1, "\u03B2"], [120632, 1, "\u03B3"], [120633, 1, "\u03B4"], [120634, 1, "\u03B5"], [120635, 1, "\u03B6"], [120636, 1, "\u03B7"], [120637, 1, "\u03B8"], [120638, 1, "\u03B9"], [120639, 1, "\u03BA"], [120640, 1, "\u03BB"], [120641, 1, "\u03BC"], [120642, 1, "\u03BD"], [120643, 1, "\u03BE"], [120644, 1, "\u03BF"], [120645, 1, "\u03C0"], [120646, 1, "\u03C1"], [[120647, 120648], 1, "\u03C3"], [120649, 1, "\u03C4"], [120650, 1, "\u03C5"], [120651, 1, "\u03C6"], [120652, 1, "\u03C7"], [120653, 1, "\u03C8"], [120654, 1, "\u03C9"], [120655, 1, "\u2202"], [120656, 1, "\u03B5"], [120657, 1, "\u03B8"], [120658, 1, "\u03BA"], [120659, 1, "\u03C6"], [120660, 1, "\u03C1"], [120661, 1, "\u03C0"], [120662, 1, "\u03B1"], [120663, 1, "\u03B2"], [120664, 1, "\u03B3"], [120665, 1, "\u03B4"], [120666, 1, "\u03B5"], [120667, 1, "\u03B6"], [120668, 1, "\u03B7"], [120669, 1, "\u03B8"], [120670, 1, "\u03B9"], [120671, 1, "\u03BA"], [120672, 1, "\u03BB"], [120673, 1, "\u03BC"], [120674, 1, "\u03BD"], [120675, 1, "\u03BE"], [120676, 1, "\u03BF"], [120677, 1, "\u03C0"], [120678, 1, "\u03C1"], [120679, 1, "\u03B8"], [120680, 1, "\u03C3"], [120681, 1, "\u03C4"], [120682, 1, "\u03C5"], [120683, 1, "\u03C6"], [120684, 1, "\u03C7"], [120685, 1, "\u03C8"], [120686, 1, "\u03C9"], [120687, 1, "\u2207"], [120688, 1, "\u03B1"], [120689, 1, "\u03B2"], [120690, 1, "\u03B3"], [120691, 1, "\u03B4"], [120692, 1, "\u03B5"], [120693, 1, "\u03B6"], [120694, 1, "\u03B7"], [120695, 1, "\u03B8"], [120696, 1, "\u03B9"], [120697, 1, "\u03BA"], [120698, 1, "\u03BB"], [120699, 1, "\u03BC"], [120700, 1, "\u03BD"], [120701, 1, "\u03BE"], [120702, 1, "\u03BF"], [120703, 1, "\u03C0"], [120704, 1, "\u03C1"], [[120705, 120706], 1, "\u03C3"], [120707, 1, "\u03C4"], [120708, 1, "\u03C5"], [120709, 1, "\u03C6"], [120710, 1, "\u03C7"], [120711, 1, "\u03C8"], [120712, 1, "\u03C9"], [120713, 1, "\u2202"], [120714, 1, "\u03B5"], [120715, 1, "\u03B8"], [120716, 1, "\u03BA"], [120717, 1, "\u03C6"], [120718, 1, "\u03C1"], [120719, 1, "\u03C0"], [120720, 1, "\u03B1"], [120721, 1, "\u03B2"], [120722, 1, "\u03B3"], [120723, 1, "\u03B4"], [120724, 1, "\u03B5"], [120725, 1, "\u03B6"], [120726, 1, "\u03B7"], [120727, 1, "\u03B8"], [120728, 1, "\u03B9"], [120729, 1, "\u03BA"], [120730, 1, "\u03BB"], [120731, 1, "\u03BC"], [120732, 1, "\u03BD"], [120733, 1, "\u03BE"], [120734, 1, "\u03BF"], [120735, 1, "\u03C0"], [120736, 1, "\u03C1"], [120737, 1, "\u03B8"], [120738, 1, "\u03C3"], [120739, 1, "\u03C4"], [120740, 1, "\u03C5"], [120741, 1, "\u03C6"], [120742, 1, "\u03C7"], [120743, 1, "\u03C8"], [120744, 1, "\u03C9"], [120745, 1, "\u2207"], [120746, 1, "\u03B1"], [120747, 1, "\u03B2"], [120748, 1, "\u03B3"], [120749, 1, "\u03B4"], [120750, 1, "\u03B5"], [120751, 1, "\u03B6"], [120752, 1, "\u03B7"], [120753, 1, "\u03B8"], [120754, 1, "\u03B9"], [120755, 1, "\u03BA"], [120756, 1, "\u03BB"], [120757, 1, "\u03BC"], [120758, 1, "\u03BD"], [120759, 1, "\u03BE"], [120760, 1, "\u03BF"], [120761, 1, "\u03C0"], [120762, 1, "\u03C1"], [[120763, 120764], 1, "\u03C3"], [120765, 1, "\u03C4"], [120766, 1, "\u03C5"], [120767, 1, "\u03C6"], [120768, 1, "\u03C7"], [120769, 1, "\u03C8"], [120770, 1, "\u03C9"], [120771, 1, "\u2202"], [120772, 1, "\u03B5"], [120773, 1, "\u03B8"], [120774, 1, "\u03BA"], [120775, 1, "\u03C6"], [120776, 1, "\u03C1"], [120777, 1, "\u03C0"], [[120778, 120779], 1, "\u03DD"], [[120780, 120781], 3], [120782, 1, "0"], [120783, 1, "1"], [120784, 1, "2"], [120785, 1, "3"], [120786, 1, "4"], [120787, 1, "5"], [120788, 1, "6"], [120789, 1, "7"], [120790, 1, "8"], [120791, 1, "9"], [120792, 1, "0"], [120793, 1, "1"], [120794, 1, "2"], [120795, 1, "3"], [120796, 1, "4"], [120797, 1, "5"], [120798, 1, "6"], [120799, 1, "7"], [120800, 1, "8"], [120801, 1, "9"], [120802, 1, "0"], [120803, 1, "1"], [120804, 1, "2"], [120805, 1, "3"], [120806, 1, "4"], [120807, 1, "5"], [120808, 1, "6"], [120809, 1, "7"], [120810, 1, "8"], [120811, 1, "9"], [120812, 1, "0"], [120813, 1, "1"], [120814, 1, "2"], [120815, 1, "3"], [120816, 1, "4"], [120817, 1, "5"], [120818, 1, "6"], [120819, 1, "7"], [120820, 1, "8"], [120821, 1, "9"], [120822, 1, "0"], [120823, 1, "1"], [120824, 1, "2"], [120825, 1, "3"], [120826, 1, "4"], [120827, 1, "5"], [120828, 1, "6"], [120829, 1, "7"], [120830, 1, "8"], [120831, 1, "9"], [[120832, 121343], 2], [[121344, 121398], 2], [[121399, 121402], 2], [[121403, 121452], 2], [[121453, 121460], 2], [121461, 2], [[121462, 121475], 2], [121476, 2], [[121477, 121483], 2], [[121484, 121498], 3], [[121499, 121503], 2], [121504, 3], [[121505, 121519], 2], [[121520, 122623], 3], [[122624, 122654], 2], [[122655, 122660], 3], [[122661, 122666], 2], [[122667, 122879], 3], [[122880, 122886], 2], [122887, 3], [[122888, 122904], 2], [[122905, 122906], 3], [[122907, 122913], 2], [122914, 3], [[122915, 122916], 2], [122917, 3], [[122918, 122922], 2], [[122923, 122927], 3], [122928, 1, "\u0430"], [122929, 1, "\u0431"], [122930, 1, "\u0432"], [122931, 1, "\u0433"], [122932, 1, "\u0434"], [122933, 1, "\u0435"], [122934, 1, "\u0436"], [122935, 1, "\u0437"], [122936, 1, "\u0438"], [122937, 1, "\u043A"], [122938, 1, "\u043B"], [122939, 1, "\u043C"], [122940, 1, "\u043E"], [122941, 1, "\u043F"], [122942, 1, "\u0440"], [122943, 1, "\u0441"], [122944, 1, "\u0442"], [122945, 1, "\u0443"], [122946, 1, "\u0444"], [122947, 1, "\u0445"], [122948, 1, "\u0446"], [122949, 1, "\u0447"], [122950, 1, "\u0448"], [122951, 1, "\u044B"], [122952, 1, "\u044D"], [122953, 1, "\u044E"], [122954, 1, "\uA689"], [122955, 1, "\u04D9"], [122956, 1, "\u0456"], [122957, 1, "\u0458"], [122958, 1, "\u04E9"], [122959, 1, "\u04AF"], [122960, 1, "\u04CF"], [122961, 1, "\u0430"], [122962, 1, "\u0431"], [122963, 1, "\u0432"], [122964, 1, "\u0433"], [122965, 1, "\u0434"], [122966, 1, "\u0435"], [122967, 1, "\u0436"], [122968, 1, "\u0437"], [122969, 1, "\u0438"], [122970, 1, "\u043A"], [122971, 1, "\u043B"], [122972, 1, "\u043E"], [122973, 1, "\u043F"], [122974, 1, "\u0441"], [122975, 1, "\u0443"], [122976, 1, "\u0444"], [122977, 1, "\u0445"], [122978, 1, "\u0446"], [122979, 1, "\u0447"], [122980, 1, "\u0448"], [122981, 1, "\u044A"], [122982, 1, "\u044B"], [122983, 1, "\u0491"], [122984, 1, "\u0456"], [122985, 1, "\u0455"], [122986, 1, "\u045F"], [122987, 1, "\u04AB"], [122988, 1, "\uA651"], [122989, 1, "\u04B1"], [[122990, 123022], 3], [123023, 2], [[123024, 123135], 3], [[123136, 123180], 2], [[123181, 123183], 3], [[123184, 123197], 2], [[123198, 123199], 3], [[123200, 123209], 2], [[123210, 123213], 3], [123214, 2], [123215, 2], [[123216, 123535], 3], [[123536, 123566], 2], [[123567, 123583], 3], [[123584, 123641], 2], [[123642, 123646], 3], [123647, 2], [[123648, 124111], 3], [[124112, 124153], 2], [[124154, 124367], 3], [[124368, 124410], 2], [[124411, 124414], 3], [124415, 2], [[124416, 124895], 3], [[124896, 124902], 2], [124903, 3], [[124904, 124907], 2], [124908, 3], [[124909, 124910], 2], [124911, 3], [[124912, 124926], 2], [124927, 3], [[124928, 125124], 2], [[125125, 125126], 3], [[125127, 125135], 2], [[125136, 125142], 2], [[125143, 125183], 3], [125184, 1, "\u{1E922}"], [125185, 1, "\u{1E923}"], [125186, 1, "\u{1E924}"], [125187, 1, "\u{1E925}"], [125188, 1, "\u{1E926}"], [125189, 1, "\u{1E927}"], [125190, 1, "\u{1E928}"], [125191, 1, "\u{1E929}"], [125192, 1, "\u{1E92A}"], [125193, 1, "\u{1E92B}"], [125194, 1, "\u{1E92C}"], [125195, 1, "\u{1E92D}"], [125196, 1, "\u{1E92E}"], [125197, 1, "\u{1E92F}"], [125198, 1, "\u{1E930}"], [125199, 1, "\u{1E931}"], [125200, 1, "\u{1E932}"], [125201, 1, "\u{1E933}"], [125202, 1, "\u{1E934}"], [125203, 1, "\u{1E935}"], [125204, 1, "\u{1E936}"], [125205, 1, "\u{1E937}"], [125206, 1, "\u{1E938}"], [125207, 1, "\u{1E939}"], [125208, 1, "\u{1E93A}"], [125209, 1, "\u{1E93B}"], [125210, 1, "\u{1E93C}"], [125211, 1, "\u{1E93D}"], [125212, 1, "\u{1E93E}"], [125213, 1, "\u{1E93F}"], [125214, 1, "\u{1E940}"], [125215, 1, "\u{1E941}"], [125216, 1, "\u{1E942}"], [125217, 1, "\u{1E943}"], [[125218, 125258], 2], [125259, 2], [[125260, 125263], 3], [[125264, 125273], 2], [[125274, 125277], 3], [[125278, 125279], 2], [[125280, 126064], 3], [[126065, 126132], 2], [[126133, 126208], 3], [[126209, 126269], 2], [[126270, 126463], 3], [126464, 1, "\u0627"], [126465, 1, "\u0628"], [126466, 1, "\u062C"], [126467, 1, "\u062F"], [126468, 3], [126469, 1, "\u0648"], [126470, 1, "\u0632"], [126471, 1, "\u062D"], [126472, 1, "\u0637"], [126473, 1, "\u064A"], [126474, 1, "\u0643"], [126475, 1, "\u0644"], [126476, 1, "\u0645"], [126477, 1, "\u0646"], [126478, 1, "\u0633"], [126479, 1, "\u0639"], [126480, 1, "\u0641"], [126481, 1, "\u0635"], [126482, 1, "\u0642"], [126483, 1, "\u0631"], [126484, 1, "\u0634"], [126485, 1, "\u062A"], [126486, 1, "\u062B"], [126487, 1, "\u062E"], [126488, 1, "\u0630"], [126489, 1, "\u0636"], [126490, 1, "\u0638"], [126491, 1, "\u063A"], [126492, 1, "\u066E"], [126493, 1, "\u06BA"], [126494, 1, "\u06A1"], [126495, 1, "\u066F"], [126496, 3], [126497, 1, "\u0628"], [126498, 1, "\u062C"], [126499, 3], [126500, 1, "\u0647"], [[126501, 126502], 3], [126503, 1, "\u062D"], [126504, 3], [126505, 1, "\u064A"], [126506, 1, "\u0643"], [126507, 1, "\u0644"], [126508, 1, "\u0645"], [126509, 1, "\u0646"], [126510, 1, "\u0633"], [126511, 1, "\u0639"], [126512, 1, "\u0641"], [126513, 1, "\u0635"], [126514, 1, "\u0642"], [126515, 3], [126516, 1, "\u0634"], [126517, 1, "\u062A"], [126518, 1, "\u062B"], [126519, 1, "\u062E"], [126520, 3], [126521, 1, "\u0636"], [126522, 3], [126523, 1, "\u063A"], [[126524, 126529], 3], [126530, 1, "\u062C"], [[126531, 126534], 3], [126535, 1, "\u062D"], [126536, 3], [126537, 1, "\u064A"], [126538, 3], [126539, 1, "\u0644"], [126540, 3], [126541, 1, "\u0646"], [126542, 1, "\u0633"], [126543, 1, "\u0639"], [126544, 3], [126545, 1, "\u0635"], [126546, 1, "\u0642"], [126547, 3], [126548, 1, "\u0634"], [[126549, 126550], 3], [126551, 1, "\u062E"], [126552, 3], [126553, 1, "\u0636"], [126554, 3], [126555, 1, "\u063A"], [126556, 3], [126557, 1, "\u06BA"], [126558, 3], [126559, 1, "\u066F"], [126560, 3], [126561, 1, "\u0628"], [126562, 1, "\u062C"], [126563, 3], [126564, 1, "\u0647"], [[126565, 126566], 3], [126567, 1, "\u062D"], [126568, 1, "\u0637"], [126569, 1, "\u064A"], [126570, 1, "\u0643"], [126571, 3], [126572, 1, "\u0645"], [126573, 1, "\u0646"], [126574, 1, "\u0633"], [126575, 1, "\u0639"], [126576, 1, "\u0641"], [126577, 1, "\u0635"], [126578, 1, "\u0642"], [126579, 3], [126580, 1, "\u0634"], [126581, 1, "\u062A"], [126582, 1, "\u062B"], [126583, 1, "\u062E"], [126584, 3], [126585, 1, "\u0636"], [126586, 1, "\u0638"], [126587, 1, "\u063A"], [126588, 1, "\u066E"], [126589, 3], [126590, 1, "\u06A1"], [126591, 3], [126592, 1, "\u0627"], [126593, 1, "\u0628"], [126594, 1, "\u062C"], [126595, 1, "\u062F"], [126596, 1, "\u0647"], [126597, 1, "\u0648"], [126598, 1, "\u0632"], [126599, 1, "\u062D"], [126600, 1, "\u0637"], [126601, 1, "\u064A"], [126602, 3], [126603, 1, "\u0644"], [126604, 1, "\u0645"], [126605, 1, "\u0646"], [126606, 1, "\u0633"], [126607, 1, "\u0639"], [126608, 1, "\u0641"], [126609, 1, "\u0635"], [126610, 1, "\u0642"], [126611, 1, "\u0631"], [126612, 1, "\u0634"], [126613, 1, "\u062A"], [126614, 1, "\u062B"], [126615, 1, "\u062E"], [126616, 1, "\u0630"], [126617, 1, "\u0636"], [126618, 1, "\u0638"], [126619, 1, "\u063A"], [[126620, 126624], 3], [126625, 1, "\u0628"], [126626, 1, "\u062C"], [126627, 1, "\u062F"], [126628, 3], [126629, 1, "\u0648"], [126630, 1, "\u0632"], [126631, 1, "\u062D"], [126632, 1, "\u0637"], [126633, 1, "\u064A"], [126634, 3], [126635, 1, "\u0644"], [126636, 1, "\u0645"], [126637, 1, "\u0646"], [126638, 1, "\u0633"], [126639, 1, "\u0639"], [126640, 1, "\u0641"], [126641, 1, "\u0635"], [126642, 1, "\u0642"], [126643, 1, "\u0631"], [126644, 1, "\u0634"], [126645, 1, "\u062A"], [126646, 1, "\u062B"], [126647, 1, "\u062E"], [126648, 1, "\u0630"], [126649, 1, "\u0636"], [126650, 1, "\u0638"], [126651, 1, "\u063A"], [[126652, 126703], 3], [[126704, 126705], 2], [[126706, 126975], 3], [[126976, 127019], 2], [[127020, 127023], 3], [[127024, 127123], 2], [[127124, 127135], 3], [[127136, 127150], 2], [[127151, 127152], 3], [[127153, 127166], 2], [127167, 2], [127168, 3], [[127169, 127183], 2], [127184, 3], [[127185, 127199], 2], [[127200, 127221], 2], [[127222, 127231], 3], [127232, 3], [127233, 1, "0,"], [127234, 1, "1,"], [127235, 1, "2,"], [127236, 1, "3,"], [127237, 1, "4,"], [127238, 1, "5,"], [127239, 1, "6,"], [127240, 1, "7,"], [127241, 1, "8,"], [127242, 1, "9,"], [[127243, 127244], 2], [[127245, 127247], 2], [127248, 1, "(a)"], [127249, 1, "(b)"], [127250, 1, "(c)"], [127251, 1, "(d)"], [127252, 1, "(e)"], [127253, 1, "(f)"], [127254, 1, "(g)"], [127255, 1, "(h)"], [127256, 1, "(i)"], [127257, 1, "(j)"], [127258, 1, "(k)"], [127259, 1, "(l)"], [127260, 1, "(m)"], [127261, 1, "(n)"], [127262, 1, "(o)"], [127263, 1, "(p)"], [127264, 1, "(q)"], [127265, 1, "(r)"], [127266, 1, "(s)"], [127267, 1, "(t)"], [127268, 1, "(u)"], [127269, 1, "(v)"], [127270, 1, "(w)"], [127271, 1, "(x)"], [127272, 1, "(y)"], [127273, 1, "(z)"], [127274, 1, "\u3014s\u3015"], [127275, 1, "c"], [127276, 1, "r"], [127277, 1, "cd"], [127278, 1, "wz"], [127279, 2], [127280, 1, "a"], [127281, 1, "b"], [127282, 1, "c"], [127283, 1, "d"], [127284, 1, "e"], [127285, 1, "f"], [127286, 1, "g"], [127287, 1, "h"], [127288, 1, "i"], [127289, 1, "j"], [127290, 1, "k"], [127291, 1, "l"], [127292, 1, "m"], [127293, 1, "n"], [127294, 1, "o"], [127295, 1, "p"], [127296, 1, "q"], [127297, 1, "r"], [127298, 1, "s"], [127299, 1, "t"], [127300, 1, "u"], [127301, 1, "v"], [127302, 1, "w"], [127303, 1, "x"], [127304, 1, "y"], [127305, 1, "z"], [127306, 1, "hv"], [127307, 1, "mv"], [127308, 1, "sd"], [127309, 1, "ss"], [127310, 1, "ppv"], [127311, 1, "wc"], [[127312, 127318], 2], [127319, 2], [[127320, 127326], 2], [127327, 2], [[127328, 127337], 2], [127338, 1, "mc"], [127339, 1, "md"], [127340, 1, "mr"], [[127341, 127343], 2], [[127344, 127352], 2], [127353, 2], [127354, 2], [[127355, 127356], 2], [[127357, 127358], 2], [127359, 2], [[127360, 127369], 2], [[127370, 127373], 2], [[127374, 127375], 2], [127376, 1, "dj"], [[127377, 127386], 2], [[127387, 127404], 2], [127405, 2], [[127406, 127461], 3], [[127462, 127487], 2], [127488, 1, "\u307B\u304B"], [127489, 1, "\u30B3\u30B3"], [127490, 1, "\u30B5"], [[127491, 127503], 3], [127504, 1, "\u624B"], [127505, 1, "\u5B57"], [127506, 1, "\u53CC"], [127507, 1, "\u30C7"], [127508, 1, "\u4E8C"], [127509, 1, "\u591A"], [127510, 1, "\u89E3"], [127511, 1, "\u5929"], [127512, 1, "\u4EA4"], [127513, 1, "\u6620"], [127514, 1, "\u7121"], [127515, 1, "\u6599"], [127516, 1, "\u524D"], [127517, 1, "\u5F8C"], [127518, 1, "\u518D"], [127519, 1, "\u65B0"], [127520, 1, "\u521D"], [127521, 1, "\u7D42"], [127522, 1, "\u751F"], [127523, 1, "\u8CA9"], [127524, 1, "\u58F0"], [127525, 1, "\u5439"], [127526, 1, "\u6F14"], [127527, 1, "\u6295"], [127528, 1, "\u6355"], [127529, 1, "\u4E00"], [127530, 1, "\u4E09"], [127531, 1, "\u904A"], [127532, 1, "\u5DE6"], [127533, 1, "\u4E2D"], [127534, 1, "\u53F3"], [127535, 1, "\u6307"], [127536, 1, "\u8D70"], [127537, 1, "\u6253"], [127538, 1, "\u7981"], [127539, 1, "\u7A7A"], [127540, 1, "\u5408"], [127541, 1, "\u6E80"], [127542, 1, "\u6709"], [127543, 1, "\u6708"], [127544, 1, "\u7533"], [127545, 1, "\u5272"], [127546, 1, "\u55B6"], [127547, 1, "\u914D"], [[127548, 127551], 3], [127552, 1, "\u3014\u672C\u3015"], [127553, 1, "\u3014\u4E09\u3015"], [127554, 1, "\u3014\u4E8C\u3015"], [127555, 1, "\u3014\u5B89\u3015"], [127556, 1, "\u3014\u70B9\u3015"], [127557, 1, "\u3014\u6253\u3015"], [127558, 1, "\u3014\u76D7\u3015"], [127559, 1, "\u3014\u52DD\u3015"], [127560, 1, "\u3014\u6557\u3015"], [[127561, 127567], 3], [127568, 1, "\u5F97"], [127569, 1, "\u53EF"], [[127570, 127583], 3], [[127584, 127589], 2], [[127590, 127743], 3], [[127744, 127776], 2], [[127777, 127788], 2], [[127789, 127791], 2], [[127792, 127797], 2], [127798, 2], [[127799, 127868], 2], [127869, 2], [[127870, 127871], 2], [[127872, 127891], 2], [[127892, 127903], 2], [[127904, 127940], 2], [127941, 2], [[127942, 127946], 2], [[127947, 127950], 2], [[127951, 127955], 2], [[127956, 127967], 2], [[127968, 127984], 2], [[127985, 127991], 2], [[127992, 127999], 2], [[128e3, 128062], 2], [128063, 2], [128064, 2], [128065, 2], [[128066, 128247], 2], [128248, 2], [[128249, 128252], 2], [[128253, 128254], 2], [128255, 2], [[128256, 128317], 2], [[128318, 128319], 2], [[128320, 128323], 2], [[128324, 128330], 2], [[128331, 128335], 2], [[128336, 128359], 2], [[128360, 128377], 2], [128378, 2], [[128379, 128419], 2], [128420, 2], [[128421, 128506], 2], [[128507, 128511], 2], [128512, 2], [[128513, 128528], 2], [128529, 2], [[128530, 128532], 2], [128533, 2], [128534, 2], [128535, 2], [128536, 2], [128537, 2], [128538, 2], [128539, 2], [[128540, 128542], 2], [128543, 2], [[128544, 128549], 2], [[128550, 128551], 2], [[128552, 128555], 2], [128556, 2], [128557, 2], [[128558, 128559], 2], [[128560, 128563], 2], [128564, 2], [[128565, 128576], 2], [[128577, 128578], 2], [[128579, 128580], 2], [[128581, 128591], 2], [[128592, 128639], 2], [[128640, 128709], 2], [[128710, 128719], 2], [128720, 2], [[128721, 128722], 2], [[128723, 128724], 2], [128725, 2], [[128726, 128727], 2], [[128728, 128731], 3], [128732, 2], [[128733, 128735], 2], [[128736, 128748], 2], [[128749, 128751], 3], [[128752, 128755], 2], [[128756, 128758], 2], [[128759, 128760], 2], [128761, 2], [128762, 2], [[128763, 128764], 2], [[128765, 128767], 3], [[128768, 128883], 2], [[128884, 128886], 2], [[128887, 128890], 3], [[128891, 128895], 2], [[128896, 128980], 2], [[128981, 128984], 2], [128985, 2], [[128986, 128991], 3], [[128992, 129003], 2], [[129004, 129007], 3], [129008, 2], [[129009, 129023], 3], [[129024, 129035], 2], [[129036, 129039], 3], [[129040, 129095], 2], [[129096, 129103], 3], [[129104, 129113], 2], [[129114, 129119], 3], [[129120, 129159], 2], [[129160, 129167], 3], [[129168, 129197], 2], [[129198, 129199], 3], [[129200, 129201], 2], [[129202, 129211], 2], [[129212, 129215], 3], [[129216, 129217], 2], [[129218, 129279], 3], [[129280, 129291], 2], [129292, 2], [[129293, 129295], 2], [[129296, 129304], 2], [[129305, 129310], 2], [129311, 2], [[129312, 129319], 2], [[129320, 129327], 2], [129328, 2], [[129329, 129330], 2], [[129331, 129342], 2], [129343, 2], [[129344, 129355], 2], [129356, 2], [[129357, 129359], 2], [[129360, 129374], 2], [[129375, 129387], 2], [[129388, 129392], 2], [129393, 2], [129394, 2], [[129395, 129398], 2], [[129399, 129400], 2], [129401, 2], [129402, 2], [129403, 2], [[129404, 129407], 2], [[129408, 129412], 2], [[129413, 129425], 2], [[129426, 129431], 2], [[129432, 129442], 2], [[129443, 129444], 2], [[129445, 129450], 2], [[129451, 129453], 2], [[129454, 129455], 2], [[129456, 129465], 2], [[129466, 129471], 2], [129472, 2], [[129473, 129474], 2], [[129475, 129482], 2], [129483, 2], [129484, 2], [[129485, 129487], 2], [[129488, 129510], 2], [[129511, 129535], 2], [[129536, 129619], 2], [[129620, 129631], 3], [[129632, 129645], 2], [[129646, 129647], 3], [[129648, 129651], 2], [129652, 2], [[129653, 129655], 2], [[129656, 129658], 2], [[129659, 129660], 2], [[129661, 129663], 3], [[129664, 129666], 2], [[129667, 129670], 2], [[129671, 129672], 2], [129673, 2], [[129674, 129678], 3], [129679, 2], [[129680, 129685], 2], [[129686, 129704], 2], [[129705, 129708], 2], [[129709, 129711], 2], [[129712, 129718], 2], [[129719, 129722], 2], [[129723, 129725], 2], [129726, 2], [129727, 2], [[129728, 129730], 2], [[129731, 129733], 2], [129734, 2], [[129735, 129741], 3], [[129742, 129743], 2], [[129744, 129750], 2], [[129751, 129753], 2], [[129754, 129755], 2], [129756, 2], [[129757, 129758], 3], [129759, 2], [[129760, 129767], 2], [129768, 2], [129769, 2], [[129770, 129775], 3], [[129776, 129782], 2], [[129783, 129784], 2], [[129785, 129791], 3], [[129792, 129938], 2], [129939, 3], [[129940, 129994], 2], [[129995, 130031], 2], [130032, 1, "0"], [130033, 1, "1"], [130034, 1, "2"], [130035, 1, "3"], [130036, 1, "4"], [130037, 1, "5"], [130038, 1, "6"], [130039, 1, "7"], [130040, 1, "8"], [130041, 1, "9"], [[130042, 131069], 3], [[131070, 131071], 3], [[131072, 173782], 2], [[173783, 173789], 2], [[173790, 173791], 2], [[173792, 173823], 3], [[173824, 177972], 2], [[177973, 177976], 2], [177977, 2], [[177978, 177983], 3], [[177984, 178205], 2], [[178206, 178207], 3], [[178208, 183969], 2], [[183970, 183983], 3], [[183984, 191456], 2], [[191457, 191471], 3], [[191472, 192093], 2], [[192094, 194559], 3], [194560, 1, "\u4E3D"], [194561, 1, "\u4E38"], [194562, 1, "\u4E41"], [194563, 1, "\u{20122}"], [194564, 1, "\u4F60"], [194565, 1, "\u4FAE"], [194566, 1, "\u4FBB"], [194567, 1, "\u5002"], [194568, 1, "\u507A"], [194569, 1, "\u5099"], [194570, 1, "\u50E7"], [194571, 1, "\u50CF"], [194572, 1, "\u349E"], [194573, 1, "\u{2063A}"], [194574, 1, "\u514D"], [194575, 1, "\u5154"], [194576, 1, "\u5164"], [194577, 1, "\u5177"], [194578, 1, "\u{2051C}"], [194579, 1, "\u34B9"], [194580, 1, "\u5167"], [194581, 1, "\u518D"], [194582, 1, "\u{2054B}"], [194583, 1, "\u5197"], [194584, 1, "\u51A4"], [194585, 1, "\u4ECC"], [194586, 1, "\u51AC"], [194587, 1, "\u51B5"], [194588, 1, "\u{291DF}"], [194589, 1, "\u51F5"], [194590, 1, "\u5203"], [194591, 1, "\u34DF"], [194592, 1, "\u523B"], [194593, 1, "\u5246"], [194594, 1, "\u5272"], [194595, 1, "\u5277"], [194596, 1, "\u3515"], [194597, 1, "\u52C7"], [194598, 1, "\u52C9"], [194599, 1, "\u52E4"], [194600, 1, "\u52FA"], [194601, 1, "\u5305"], [194602, 1, "\u5306"], [194603, 1, "\u5317"], [194604, 1, "\u5349"], [194605, 1, "\u5351"], [194606, 1, "\u535A"], [194607, 1, "\u5373"], [194608, 1, "\u537D"], [[194609, 194611], 1, "\u537F"], [194612, 1, "\u{20A2C}"], [194613, 1, "\u7070"], [194614, 1, "\u53CA"], [194615, 1, "\u53DF"], [194616, 1, "\u{20B63}"], [194617, 1, "\u53EB"], [194618, 1, "\u53F1"], [194619, 1, "\u5406"], [194620, 1, "\u549E"], [194621, 1, "\u5438"], [194622, 1, "\u5448"], [194623, 1, "\u5468"], [194624, 1, "\u54A2"], [194625, 1, "\u54F6"], [194626, 1, "\u5510"], [194627, 1, "\u5553"], [194628, 1, "\u5563"], [[194629, 194630], 1, "\u5584"], [194631, 1, "\u5599"], [194632, 1, "\u55AB"], [194633, 1, "\u55B3"], [194634, 1, "\u55C2"], [194635, 1, "\u5716"], [194636, 1, "\u5606"], [194637, 1, "\u5717"], [194638, 1, "\u5651"], [194639, 1, "\u5674"], [194640, 1, "\u5207"], [194641, 1, "\u58EE"], [194642, 1, "\u57CE"], [194643, 1, "\u57F4"], [194644, 1, "\u580D"], [194645, 1, "\u578B"], [194646, 1, "\u5832"], [194647, 1, "\u5831"], [194648, 1, "\u58AC"], [194649, 1, "\u{214E4}"], [194650, 1, "\u58F2"], [194651, 1, "\u58F7"], [194652, 1, "\u5906"], [194653, 1, "\u591A"], [194654, 1, "\u5922"], [194655, 1, "\u5962"], [194656, 1, "\u{216A8}"], [194657, 1, "\u{216EA}"], [194658, 1, "\u59EC"], [194659, 1, "\u5A1B"], [194660, 1, "\u5A27"], [194661, 1, "\u59D8"], [194662, 1, "\u5A66"], [194663, 1, "\u36EE"], [194664, 1, "\u36FC"], [194665, 1, "\u5B08"], [[194666, 194667], 1, "\u5B3E"], [194668, 1, "\u{219C8}"], [194669, 1, "\u5BC3"], [194670, 1, "\u5BD8"], [194671, 1, "\u5BE7"], [194672, 1, "\u5BF3"], [194673, 1, "\u{21B18}"], [194674, 1, "\u5BFF"], [194675, 1, "\u5C06"], [194676, 1, "\u5F53"], [194677, 1, "\u5C22"], [194678, 1, "\u3781"], [194679, 1, "\u5C60"], [194680, 1, "\u5C6E"], [194681, 1, "\u5CC0"], [194682, 1, "\u5C8D"], [194683, 1, "\u{21DE4}"], [194684, 1, "\u5D43"], [194685, 1, "\u{21DE6}"], [194686, 1, "\u5D6E"], [194687, 1, "\u5D6B"], [194688, 1, "\u5D7C"], [194689, 1, "\u5DE1"], [194690, 1, "\u5DE2"], [194691, 1, "\u382F"], [194692, 1, "\u5DFD"], [194693, 1, "\u5E28"], [194694, 1, "\u5E3D"], [194695, 1, "\u5E69"], [194696, 1, "\u3862"], [194697, 1, "\u{22183}"], [194698, 1, "\u387C"], [194699, 1, "\u5EB0"], [194700, 1, "\u5EB3"], [194701, 1, "\u5EB6"], [194702, 1, "\u5ECA"], [194703, 1, "\u{2A392}"], [194704, 1, "\u5EFE"], [[194705, 194706], 1, "\u{22331}"], [194707, 1, "\u8201"], [[194708, 194709], 1, "\u5F22"], [194710, 1, "\u38C7"], [194711, 1, "\u{232B8}"], [194712, 1, "\u{261DA}"], [194713, 1, "\u5F62"], [194714, 1, "\u5F6B"], [194715, 1, "\u38E3"], [194716, 1, "\u5F9A"], [194717, 1, "\u5FCD"], [194718, 1, "\u5FD7"], [194719, 1, "\u5FF9"], [194720, 1, "\u6081"], [194721, 1, "\u393A"], [194722, 1, "\u391C"], [194723, 1, "\u6094"], [194724, 1, "\u{226D4}"], [194725, 1, "\u60C7"], [194726, 1, "\u6148"], [194727, 1, "\u614C"], [194728, 1, "\u614E"], [194729, 1, "\u614C"], [194730, 1, "\u617A"], [194731, 1, "\u618E"], [194732, 1, "\u61B2"], [194733, 1, "\u61A4"], [194734, 1, "\u61AF"], [194735, 1, "\u61DE"], [194736, 1, "\u61F2"], [194737, 1, "\u61F6"], [194738, 1, "\u6210"], [194739, 1, "\u621B"], [194740, 1, "\u625D"], [194741, 1, "\u62B1"], [194742, 1, "\u62D4"], [194743, 1, "\u6350"], [194744, 1, "\u{22B0C}"], [194745, 1, "\u633D"], [194746, 1, "\u62FC"], [194747, 1, "\u6368"], [194748, 1, "\u6383"], [194749, 1, "\u63E4"], [194750, 1, "\u{22BF1}"], [194751, 1, "\u6422"], [194752, 1, "\u63C5"], [194753, 1, "\u63A9"], [194754, 1, "\u3A2E"], [194755, 1, "\u6469"], [194756, 1, "\u647E"], [194757, 1, "\u649D"], [194758, 1, "\u6477"], [194759, 1, "\u3A6C"], [194760, 1, "\u654F"], [194761, 1, "\u656C"], [194762, 1, "\u{2300A}"], [194763, 1, "\u65E3"], [194764, 1, "\u66F8"], [194765, 1, "\u6649"], [194766, 1, "\u3B19"], [194767, 1, "\u6691"], [194768, 1, "\u3B08"], [194769, 1, "\u3AE4"], [194770, 1, "\u5192"], [194771, 1, "\u5195"], [194772, 1, "\u6700"], [194773, 1, "\u669C"], [194774, 1, "\u80AD"], [194775, 1, "\u43D9"], [194776, 1, "\u6717"], [194777, 1, "\u671B"], [194778, 1, "\u6721"], [194779, 1, "\u675E"], [194780, 1, "\u6753"], [194781, 1, "\u{233C3}"], [194782, 1, "\u3B49"], [194783, 1, "\u67FA"], [194784, 1, "\u6785"], [194785, 1, "\u6852"], [194786, 1, "\u6885"], [194787, 1, "\u{2346D}"], [194788, 1, "\u688E"], [194789, 1, "\u681F"], [194790, 1, "\u6914"], [194791, 1, "\u3B9D"], [194792, 1, "\u6942"], [194793, 1, "\u69A3"], [194794, 1, "\u69EA"], [194795, 1, "\u6AA8"], [194796, 1, "\u{236A3}"], [194797, 1, "\u6ADB"], [194798, 1, "\u3C18"], [194799, 1, "\u6B21"], [194800, 1, "\u{238A7}"], [194801, 1, "\u6B54"], [194802, 1, "\u3C4E"], [194803, 1, "\u6B72"], [194804, 1, "\u6B9F"], [194805, 1, "\u6BBA"], [194806, 1, "\u6BBB"], [194807, 1, "\u{23A8D}"], [194808, 1, "\u{21D0B}"], [194809, 1, "\u{23AFA}"], [194810, 1, "\u6C4E"], [194811, 1, "\u{23CBC}"], [194812, 1, "\u6CBF"], [194813, 1, "\u6CCD"], [194814, 1, "\u6C67"], [194815, 1, "\u6D16"], [194816, 1, "\u6D3E"], [194817, 1, "\u6D77"], [194818, 1, "\u6D41"], [194819, 1, "\u6D69"], [194820, 1, "\u6D78"], [194821, 1, "\u6D85"], [194822, 1, "\u{23D1E}"], [194823, 1, "\u6D34"], [194824, 1, "\u6E2F"], [194825, 1, "\u6E6E"], [194826, 1, "\u3D33"], [194827, 1, "\u6ECB"], [194828, 1, "\u6EC7"], [194829, 1, "\u{23ED1}"], [194830, 1, "\u6DF9"], [194831, 1, "\u6F6E"], [194832, 1, "\u{23F5E}"], [194833, 1, "\u{23F8E}"], [194834, 1, "\u6FC6"], [194835, 1, "\u7039"], [194836, 1, "\u701E"], [194837, 1, "\u701B"], [194838, 1, "\u3D96"], [194839, 1, "\u704A"], [194840, 1, "\u707D"], [194841, 1, "\u7077"], [194842, 1, "\u70AD"], [194843, 1, "\u{20525}"], [194844, 1, "\u7145"], [194845, 1, "\u{24263}"], [194846, 1, "\u719C"], [194847, 1, "\u{243AB}"], [194848, 1, "\u7228"], [194849, 1, "\u7235"], [194850, 1, "\u7250"], [194851, 1, "\u{24608}"], [194852, 1, "\u7280"], [194853, 1, "\u7295"], [194854, 1, "\u{24735}"], [194855, 1, "\u{24814}"], [194856, 1, "\u737A"], [194857, 1, "\u738B"], [194858, 1, "\u3EAC"], [194859, 1, "\u73A5"], [[194860, 194861], 1, "\u3EB8"], [194862, 1, "\u7447"], [194863, 1, "\u745C"], [194864, 1, "\u7471"], [194865, 1, "\u7485"], [194866, 1, "\u74CA"], [194867, 1, "\u3F1B"], [194868, 1, "\u7524"], [194869, 1, "\u{24C36}"], [194870, 1, "\u753E"], [194871, 1, "\u{24C92}"], [194872, 1, "\u7570"], [194873, 1, "\u{2219F}"], [194874, 1, "\u7610"], [194875, 1, "\u{24FA1}"], [194876, 1, "\u{24FB8}"], [194877, 1, "\u{25044}"], [194878, 1, "\u3FFC"], [194879, 1, "\u4008"], [194880, 1, "\u76F4"], [194881, 1, "\u{250F3}"], [194882, 1, "\u{250F2}"], [194883, 1, "\u{25119}"], [194884, 1, "\u{25133}"], [194885, 1, "\u771E"], [[194886, 194887], 1, "\u771F"], [194888, 1, "\u774A"], [194889, 1, "\u4039"], [194890, 1, "\u778B"], [194891, 1, "\u4046"], [194892, 1, "\u4096"], [194893, 1, "\u{2541D}"], [194894, 1, "\u784E"], [194895, 1, "\u788C"], [194896, 1, "\u78CC"], [194897, 1, "\u40E3"], [194898, 1, "\u{25626}"], [194899, 1, "\u7956"], [194900, 1, "\u{2569A}"], [194901, 1, "\u{256C5}"], [194902, 1, "\u798F"], [194903, 1, "\u79EB"], [194904, 1, "\u412F"], [194905, 1, "\u7A40"], [194906, 1, "\u7A4A"], [194907, 1, "\u7A4F"], [194908, 1, "\u{2597C}"], [[194909, 194910], 1, "\u{25AA7}"], [194911, 1, "\u7AEE"], [194912, 1, "\u4202"], [194913, 1, "\u{25BAB}"], [194914, 1, "\u7BC6"], [194915, 1, "\u7BC9"], [194916, 1, "\u4227"], [194917, 1, "\u{25C80}"], [194918, 1, "\u7CD2"], [194919, 1, "\u42A0"], [194920, 1, "\u7CE8"], [194921, 1, "\u7CE3"], [194922, 1, "\u7D00"], [194923, 1, "\u{25F86}"], [194924, 1, "\u7D63"], [194925, 1, "\u4301"], [194926, 1, "\u7DC7"], [194927, 1, "\u7E02"], [194928, 1, "\u7E45"], [194929, 1, "\u4334"], [194930, 1, "\u{26228}"], [194931, 1, "\u{26247}"], [194932, 1, "\u4359"], [194933, 1, "\u{262D9}"], [194934, 1, "\u7F7A"], [194935, 1, "\u{2633E}"], [194936, 1, "\u7F95"], [194937, 1, "\u7FFA"], [194938, 1, "\u8005"], [194939, 1, "\u{264DA}"], [194940, 1, "\u{26523}"], [194941, 1, "\u8060"], [194942, 1, "\u{265A8}"], [194943, 1, "\u8070"], [194944, 1, "\u{2335F}"], [194945, 1, "\u43D5"], [194946, 1, "\u80B2"], [194947, 1, "\u8103"], [194948, 1, "\u440B"], [194949, 1, "\u813E"], [194950, 1, "\u5AB5"], [194951, 1, "\u{267A7}"], [194952, 1, "\u{267B5}"], [194953, 1, "\u{23393}"], [194954, 1, "\u{2339C}"], [194955, 1, "\u8201"], [194956, 1, "\u8204"], [194957, 1, "\u8F9E"], [194958, 1, "\u446B"], [194959, 1, "\u8291"], [194960, 1, "\u828B"], [194961, 1, "\u829D"], [194962, 1, "\u52B3"], [194963, 1, "\u82B1"], [194964, 1, "\u82B3"], [194965, 1, "\u82BD"], [194966, 1, "\u82E6"], [194967, 1, "\u{26B3C}"], [194968, 1, "\u82E5"], [194969, 1, "\u831D"], [194970, 1, "\u8363"], [194971, 1, "\u83AD"], [194972, 1, "\u8323"], [194973, 1, "\u83BD"], [194974, 1, "\u83E7"], [194975, 1, "\u8457"], [194976, 1, "\u8353"], [194977, 1, "\u83CA"], [194978, 1, "\u83CC"], [194979, 1, "\u83DC"], [194980, 1, "\u{26C36}"], [194981, 1, "\u{26D6B}"], [194982, 1, "\u{26CD5}"], [194983, 1, "\u452B"], [194984, 1, "\u84F1"], [194985, 1, "\u84F3"], [194986, 1, "\u8516"], [194987, 1, "\u{273CA}"], [194988, 1, "\u8564"], [194989, 1, "\u{26F2C}"], [194990, 1, "\u455D"], [194991, 1, "\u4561"], [194992, 1, "\u{26FB1}"], [194993, 1, "\u{270D2}"], [194994, 1, "\u456B"], [194995, 1, "\u8650"], [194996, 1, "\u865C"], [194997, 1, "\u8667"], [194998, 1, "\u8669"], [194999, 1, "\u86A9"], [195e3, 1, "\u8688"], [195001, 1, "\u870E"], [195002, 1, "\u86E2"], [195003, 1, "\u8779"], [195004, 1, "\u8728"], [195005, 1, "\u876B"], [195006, 1, "\u8786"], [195007, 1, "\u45D7"], [195008, 1, "\u87E1"], [195009, 1, "\u8801"], [195010, 1, "\u45F9"], [195011, 1, "\u8860"], [195012, 1, "\u8863"], [195013, 1, "\u{27667}"], [195014, 1, "\u88D7"], [195015, 1, "\u88DE"], [195016, 1, "\u4635"], [195017, 1, "\u88FA"], [195018, 1, "\u34BB"], [195019, 1, "\u{278AE}"], [195020, 1, "\u{27966}"], [195021, 1, "\u46BE"], [195022, 1, "\u46C7"], [195023, 1, "\u8AA0"], [195024, 1, "\u8AED"], [195025, 1, "\u8B8A"], [195026, 1, "\u8C55"], [195027, 1, "\u{27CA8}"], [195028, 1, "\u8CAB"], [195029, 1, "\u8CC1"], [195030, 1, "\u8D1B"], [195031, 1, "\u8D77"], [195032, 1, "\u{27F2F}"], [195033, 1, "\u{20804}"], [195034, 1, "\u8DCB"], [195035, 1, "\u8DBC"], [195036, 1, "\u8DF0"], [195037, 1, "\u{208DE}"], [195038, 1, "\u8ED4"], [195039, 1, "\u8F38"], [195040, 1, "\u{285D2}"], [195041, 1, "\u{285ED}"], [195042, 1, "\u9094"], [195043, 1, "\u90F1"], [195044, 1, "\u9111"], [195045, 1, "\u{2872E}"], [195046, 1, "\u911B"], [195047, 1, "\u9238"], [195048, 1, "\u92D7"], [195049, 1, "\u92D8"], [195050, 1, "\u927C"], [195051, 1, "\u93F9"], [195052, 1, "\u9415"], [195053, 1, "\u{28BFA}"], [195054, 1, "\u958B"], [195055, 1, "\u4995"], [195056, 1, "\u95B7"], [195057, 1, "\u{28D77}"], [195058, 1, "\u49E6"], [195059, 1, "\u96C3"], [195060, 1, "\u5DB2"], [195061, 1, "\u9723"], [195062, 1, "\u{29145}"], [195063, 1, "\u{2921A}"], [195064, 1, "\u4A6E"], [195065, 1, "\u4A76"], [195066, 1, "\u97E0"], [195067, 1, "\u{2940A}"], [195068, 1, "\u4AB2"], [195069, 1, "\u{29496}"], [[195070, 195071], 1, "\u980B"], [195072, 1, "\u9829"], [195073, 1, "\u{295B6}"], [195074, 1, "\u98E2"], [195075, 1, "\u4B33"], [195076, 1, "\u9929"], [195077, 1, "\u99A7"], [195078, 1, "\u99C2"], [195079, 1, "\u99FE"], [195080, 1, "\u4BCE"], [195081, 1, "\u{29B30}"], [195082, 1, "\u9B12"], [195083, 1, "\u9C40"], [195084, 1, "\u9CFD"], [195085, 1, "\u4CCE"], [195086, 1, "\u4CED"], [195087, 1, "\u9D67"], [195088, 1, "\u{2A0CE}"], [195089, 1, "\u4CF8"], [195090, 1, "\u{2A105}"], [195091, 1, "\u{2A20E}"], [195092, 1, "\u{2A291}"], [195093, 1, "\u9EBB"], [195094, 1, "\u4D56"], [195095, 1, "\u9EF9"], [195096, 1, "\u9EFE"], [195097, 1, "\u9F05"], [195098, 1, "\u9F0F"], [195099, 1, "\u9F16"], [195100, 1, "\u9F3B"], [195101, 1, "\u{2A600}"], [[195102, 196605], 3], [[196606, 196607], 3], [[196608, 201546], 2], [[201547, 201551], 3], [[201552, 205743], 2], [[205744, 262141], 3], [[262142, 262143], 3], [[262144, 327677], 3], [[327678, 327679], 3], [[327680, 393213], 3], [[393214, 393215], 3], [[393216, 458749], 3], [[458750, 458751], 3], [[458752, 524285], 3], [[524286, 524287], 3], [[524288, 589821], 3], [[589822, 589823], 3], [[589824, 655357], 3], [[655358, 655359], 3], [[655360, 720893], 3], [[720894, 720895], 3], [[720896, 786429], 3], [[786430, 786431], 3], [[786432, 851965], 3], [[851966, 851967], 3], [[851968, 917501], 3], [[917502, 917503], 3], [917504, 3], [917505, 3], [[917506, 917535], 3], [[917536, 917631], 3], [[917632, 917759], 3], [[917760, 917999], 7], [[918e3, 983037], 3], [[983038, 983039], 3], [[983040, 1048573], 3], [[1048574, 1048575], 3], [[1048576, 1114109], 3], [[1114110, 1114111], 3]]; + } +}); + +// node_modules/tr46/lib/statusMapping.js +var require_statusMapping = __commonJS({ + "node_modules/tr46/lib/statusMapping.js"(exports2, module3) { + "use strict"; + module3.exports.STATUS_MAPPING = { + mapped: 1, + valid: 2, + disallowed: 3, + deviation: 6, + ignored: 7 + }; + } +}); + +// node_modules/tr46/index.js +var require_tr46 = __commonJS({ + "node_modules/tr46/index.js"(exports2, module3) { + "use strict"; + var punycode = require_punycode(); + var regexes = require_regexes(); + var mappingTable = require_mappingTable(); + var { STATUS_MAPPING } = require_statusMapping(); + function containsNonASCII(str) { + return /[^\x00-\x7F]/u.test(str); + } + function findStatus(val) { + let start = 0; + let end = mappingTable.length - 1; + while (start <= end) { + const mid = Math.floor((start + end) / 2); + const target = mappingTable[mid]; + const min2 = Array.isArray(target[0]) ? target[0][0] : target[0]; + const max2 = Array.isArray(target[0]) ? target[0][1] : target[0]; + if (min2 <= val && max2 >= val) { + return target.slice(1); + } else if (min2 > val) { + end = mid - 1; + } else { + start = mid + 1; + } + } + return null; + } + function mapChars(domainName, { transitionalProcessing }) { + let processed = ""; + for (const ch of domainName) { + const [status, mapping] = findStatus(ch.codePointAt(0)); + switch (status) { + case STATUS_MAPPING.disallowed: + processed += ch; + break; + case STATUS_MAPPING.ignored: + break; + case STATUS_MAPPING.mapped: + if (transitionalProcessing && ch === "\u1E9E") { + processed += "ss"; + } else { + processed += mapping; + } + break; + case STATUS_MAPPING.deviation: + if (transitionalProcessing) { + processed += mapping; + } else { + processed += ch; + } + break; + case STATUS_MAPPING.valid: + processed += ch; + break; + } + } + return processed; + } + function validateLabel(label, { + checkHyphens, + checkBidi, + checkJoiners, + transitionalProcessing, + useSTD3ASCIIRules, + isBidi + }) { + if (label.length === 0) { + return true; + } + if (label.normalize("NFC") !== label) { + return false; + } + const codePoints = Array.from(label); + if (checkHyphens) { + if (codePoints[2] === "-" && codePoints[3] === "-" || (label.startsWith("-") || label.endsWith("-"))) { + return false; + } + } + if (!checkHyphens) { + if (label.startsWith("xn--")) { + return false; + } + } + if (label.includes(".")) { + return false; + } + if (regexes.combiningMarks.test(codePoints[0])) { + return false; + } + for (const ch of codePoints) { + const codePoint = ch.codePointAt(0); + const [status] = findStatus(codePoint); + if (transitionalProcessing) { + if (status !== STATUS_MAPPING.valid) { + return false; + } + } else if (status !== STATUS_MAPPING.valid && status !== STATUS_MAPPING.deviation) { + return false; + } + if (useSTD3ASCIIRules && codePoint <= 127) { + if (!/^(?:[a-z]|[0-9]|-)$/u.test(ch)) { + return false; + } + } + } + if (checkJoiners) { + let last = 0; + for (const [i, ch] of codePoints.entries()) { + if (ch === "\u200C" || ch === "\u200D") { + if (i > 0) { + if (regexes.combiningClassVirama.test(codePoints[i - 1])) { + continue; + } + if (ch === "\u200C") { + const next = codePoints.indexOf("\u200C", i + 1); + const test = next < 0 ? codePoints.slice(last) : codePoints.slice(last, next); + if (regexes.validZWNJ.test(test.join(""))) { + last = i + 1; + continue; + } + } + } + return false; + } + } + } + if (checkBidi && isBidi) { + let rtl; + if (regexes.bidiS1LTR.test(codePoints[0])) { + rtl = false; + } else if (regexes.bidiS1RTL.test(codePoints[0])) { + rtl = true; + } else { + return false; + } + if (rtl) { + if (!regexes.bidiS2.test(label) || !regexes.bidiS3.test(label) || regexes.bidiS4EN.test(label) && regexes.bidiS4AN.test(label)) { + return false; + } + } else if (!regexes.bidiS5.test(label) || !regexes.bidiS6.test(label)) { + return false; + } + } + return true; + } + function isBidiDomain(labels) { + const domain = labels.map((label) => { + if (label.startsWith("xn--")) { + try { + return punycode.decode(label.substring(4)); + } catch { + return ""; + } + } + return label; + }).join("."); + return regexes.bidiDomain.test(domain); + } + function processing(domainName, options2) { + let string11 = mapChars(domainName, options2); + string11 = string11.normalize("NFC"); + const labels = string11.split("."); + const isBidi = isBidiDomain(labels); + let error4 = false; + for (const [i, origLabel] of labels.entries()) { + let label = origLabel; + let transitionalProcessingForThisLabel = options2.transitionalProcessing; + if (label.startsWith("xn--")) { + if (containsNonASCII(label)) { + error4 = true; + continue; + } + try { + label = punycode.decode(label.substring(4)); + } catch { + if (!options2.ignoreInvalidPunycode) { + error4 = true; + continue; + } + } + labels[i] = label; + if (label === "" || !containsNonASCII(label)) { + error4 = true; + } + transitionalProcessingForThisLabel = false; + } + if (error4) { + continue; + } + const validation = validateLabel(label, { + ...options2, + transitionalProcessing: transitionalProcessingForThisLabel, + isBidi + }); + if (!validation) { + error4 = true; + } + } + return { + string: labels.join("."), + error: error4 + }; + } + function toASCII(domainName, { + checkHyphens = false, + checkBidi = false, + checkJoiners = false, + useSTD3ASCIIRules = false, + verifyDNSLength = false, + transitionalProcessing = false, + ignoreInvalidPunycode = false + } = {}) { + const result = processing(domainName, { + checkHyphens, + checkBidi, + checkJoiners, + useSTD3ASCIIRules, + transitionalProcessing, + ignoreInvalidPunycode + }); + let labels = result.string.split("."); + labels = labels.map((l) => { + if (containsNonASCII(l)) { + try { + return `xn--${punycode.encode(l)}`; + } catch { + result.error = true; + } + } + return l; + }); + if (verifyDNSLength) { + const total = labels.join(".").length; + if (total > 253 || total === 0) { + result.error = true; + } + for (let i = 0; i < labels.length; ++i) { + if (labels[i].length > 63 || labels[i].length === 0) { + result.error = true; + break; + } + } + } + if (result.error) { + return null; + } + return labels.join("."); + } + function toUnicode(domainName, { + checkHyphens = false, + checkBidi = false, + checkJoiners = false, + useSTD3ASCIIRules = false, + transitionalProcessing = false, + ignoreInvalidPunycode = false + } = {}) { + const result = processing(domainName, { + checkHyphens, + checkBidi, + checkJoiners, + useSTD3ASCIIRules, + transitionalProcessing, + ignoreInvalidPunycode + }); + return { + domain: result.string, + error: result.error + }; + } + module3.exports = { + toASCII, + toUnicode + }; + } +}); + +// node_modules/whatwg-url/lib/infra.js +var require_infra = __commonJS({ + "node_modules/whatwg-url/lib/infra.js"(exports2, module3) { + "use strict"; + function isASCIIDigit(c) { + return c >= 48 && c <= 57; + } + function isASCIIAlpha(c) { + return c >= 65 && c <= 90 || c >= 97 && c <= 122; + } + function isASCIIAlphanumeric(c) { + return isASCIIAlpha(c) || isASCIIDigit(c); + } + function isASCIIHex(c) { + return isASCIIDigit(c) || c >= 65 && c <= 70 || c >= 97 && c <= 102; + } + module3.exports = { + isASCIIDigit, + isASCIIAlpha, + isASCIIAlphanumeric, + isASCIIHex + }; + } +}); + +// node_modules/whatwg-url/lib/encoding.js +var require_encoding = __commonJS({ + "node_modules/whatwg-url/lib/encoding.js"(exports2, module3) { + "use strict"; + var utf8Encoder = new TextEncoder(); + var utf8Decoder = new TextDecoder("utf-8", { ignoreBOM: true }); + function utf8Encode(string11) { + return utf8Encoder.encode(string11); + } + function utf8DecodeWithoutBOM(bytes) { + return utf8Decoder.decode(bytes); + } + module3.exports = { + utf8Encode, + utf8DecodeWithoutBOM + }; + } +}); + +// node_modules/whatwg-url/lib/percent-encoding.js +var require_percent_encoding = __commonJS({ + "node_modules/whatwg-url/lib/percent-encoding.js"(exports2, module3) { + "use strict"; + var { isASCIIHex } = require_infra(); + var { utf8Encode } = require_encoding(); + function p(char) { + return char.codePointAt(0); + } + function percentEncode(c) { + let hex = c.toString(16).toUpperCase(); + if (hex.length === 1) { + hex = `0${hex}`; + } + return `%${hex}`; + } + function percentDecodeBytes(input) { + const output = new Uint8Array(input.byteLength); + let outputIndex = 0; + for (let i = 0; i < input.byteLength; ++i) { + const byte = input[i]; + if (byte !== 37) { + output[outputIndex++] = byte; + } else if (byte === 37 && (!isASCIIHex(input[i + 1]) || !isASCIIHex(input[i + 2]))) { + output[outputIndex++] = byte; + } else { + const bytePoint = parseInt(String.fromCodePoint(input[i + 1], input[i + 2]), 16); + output[outputIndex++] = bytePoint; + i += 2; + } + } + return output.slice(0, outputIndex); + } + function percentDecodeString(input) { + const bytes = utf8Encode(input); + return percentDecodeBytes(bytes); + } + function isC0ControlPercentEncode(c) { + return c <= 31 || c > 126; + } + var extraFragmentPercentEncodeSet = /* @__PURE__ */ new Set([p(" "), p('"'), p("<"), p(">"), p("`")]); + function isFragmentPercentEncode(c) { + return isC0ControlPercentEncode(c) || extraFragmentPercentEncodeSet.has(c); + } + var extraQueryPercentEncodeSet = /* @__PURE__ */ new Set([p(" "), p('"'), p("#"), p("<"), p(">")]); + function isQueryPercentEncode(c) { + return isC0ControlPercentEncode(c) || extraQueryPercentEncodeSet.has(c); + } + function isSpecialQueryPercentEncode(c) { + return isQueryPercentEncode(c) || c === p("'"); + } + var extraPathPercentEncodeSet = /* @__PURE__ */ new Set([p("?"), p("`"), p("{"), p("}"), p("^")]); + function isPathPercentEncode(c) { + return isQueryPercentEncode(c) || extraPathPercentEncodeSet.has(c); + } + var extraUserinfoPercentEncodeSet = /* @__PURE__ */ new Set([p("/"), p(":"), p(";"), p("="), p("@"), p("["), p("\\"), p("]"), p("|")]); + function isUserinfoPercentEncode(c) { + return isPathPercentEncode(c) || extraUserinfoPercentEncodeSet.has(c); + } + var extraComponentPercentEncodeSet = /* @__PURE__ */ new Set([p("$"), p("%"), p("&"), p("+"), p(",")]); + function isComponentPercentEncode(c) { + return isUserinfoPercentEncode(c) || extraComponentPercentEncodeSet.has(c); + } + var extraURLEncodedPercentEncodeSet = /* @__PURE__ */ new Set([p("!"), p("'"), p("("), p(")"), p("~")]); + function isURLEncodedPercentEncode(c) { + return isComponentPercentEncode(c) || extraURLEncodedPercentEncodeSet.has(c); + } + function utf8PercentEncodeCodePointInternal(codePoint, percentEncodePredicate) { + const bytes = utf8Encode(codePoint); + let output = ""; + for (const byte of bytes) { + if (!percentEncodePredicate(byte)) { + output += String.fromCharCode(byte); + } else { + output += percentEncode(byte); + } + } + return output; + } + function utf8PercentEncodeCodePoint(codePoint, percentEncodePredicate) { + return utf8PercentEncodeCodePointInternal(String.fromCodePoint(codePoint), percentEncodePredicate); + } + function utf8PercentEncodeString(input, percentEncodePredicate, spaceAsPlus = false) { + let output = ""; + for (const codePoint of input) { + if (spaceAsPlus && codePoint === " ") { + output += "+"; + } else { + output += utf8PercentEncodeCodePointInternal(codePoint, percentEncodePredicate); + } + } + return output; + } + module3.exports = { + isC0ControlPercentEncode, + isFragmentPercentEncode, + isQueryPercentEncode, + isSpecialQueryPercentEncode, + isPathPercentEncode, + isUserinfoPercentEncode, + isURLEncodedPercentEncode, + percentDecodeString, + percentDecodeBytes, + utf8PercentEncodeString, + utf8PercentEncodeCodePoint + }; + } +}); + +// node_modules/whatwg-url/lib/url-state-machine.js +var require_url_state_machine = __commonJS({ + "node_modules/whatwg-url/lib/url-state-machine.js"(exports2, module3) { + "use strict"; + var tr46 = require_tr46(); + var infra = require_infra(); + var { utf8DecodeWithoutBOM } = require_encoding(); + var { + percentDecodeString, + utf8PercentEncodeCodePoint, + utf8PercentEncodeString, + isC0ControlPercentEncode, + isFragmentPercentEncode, + isQueryPercentEncode, + isSpecialQueryPercentEncode, + isPathPercentEncode, + isUserinfoPercentEncode + } = require_percent_encoding(); + function p(char) { + return char.codePointAt(0); + } + var specialSchemes = { + ftp: 21, + file: null, + http: 80, + https: 443, + ws: 80, + wss: 443 + }; + var failure = Symbol("failure"); + function countSymbols(str) { + return [...str].length; + } + function at(input, idx) { + const c = input[idx]; + return isNaN(c) ? void 0 : String.fromCodePoint(c); + } + function isSingleDot(buffer) { + return buffer === "." || buffer.toLowerCase() === "%2e"; + } + function isDoubleDot(buffer) { + buffer = buffer.toLowerCase(); + return buffer === ".." || buffer === "%2e." || buffer === ".%2e" || buffer === "%2e%2e"; + } + function isWindowsDriveLetterCodePoints(cp1, cp2) { + return infra.isASCIIAlpha(cp1) && (cp2 === p(":") || cp2 === p("|")); + } + function isWindowsDriveLetterString(string11) { + return string11.length === 2 && infra.isASCIIAlpha(string11.codePointAt(0)) && (string11[1] === ":" || string11[1] === "|"); + } + function isNormalizedWindowsDriveLetterString(string11) { + return string11.length === 2 && infra.isASCIIAlpha(string11.codePointAt(0)) && string11[1] === ":"; + } + function containsForbiddenHostCodePoint(string11) { + return string11.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|\/|:|<|>|\?|@|\[|\\|\]|\^|\|/u) !== -1; + } + function containsForbiddenDomainCodePoint(string11) { + return containsForbiddenHostCodePoint(string11) || string11.search(/[\u0000-\u001F]|%|\u007F/u) !== -1; + } + function isSpecialScheme(scheme) { + return specialSchemes[scheme] !== void 0; + } + function isSpecial(url2) { + return isSpecialScheme(url2.scheme); + } + function isNotSpecial(url2) { + return !isSpecialScheme(url2.scheme); + } + function defaultPort(scheme) { + return specialSchemes[scheme]; + } + function parseIPv4Number(input) { + if (input === "") { + return failure; + } + let R = 10; + if (input.length >= 2 && input.charAt(0) === "0" && input.charAt(1).toLowerCase() === "x") { + input = input.substring(2); + R = 16; + } else if (input.length >= 2 && input.charAt(0) === "0") { + input = input.substring(1); + R = 8; + } + if (input === "") { + return 0; + } + let regex = /[^0-7]/u; + if (R === 10) { + regex = /[^0-9]/u; + } + if (R === 16) { + regex = /[^0-9A-Fa-f]/u; + } + if (regex.test(input)) { + return failure; + } + return parseInt(input, R); + } + function parseIPv4(input) { + const parts = input.split("."); + if (parts[parts.length - 1] === "") { + if (parts.length > 1) { + parts.pop(); + } + } + if (parts.length > 4) { + return failure; + } + const numbers = []; + for (const part of parts) { + const n = parseIPv4Number(part); + if (n === failure) { + return failure; + } + numbers.push(n); + } + for (let i = 0; i < numbers.length - 1; ++i) { + if (numbers[i] > 255) { + return failure; + } + } + if (numbers[numbers.length - 1] >= 256 ** (5 - numbers.length)) { + return failure; + } + let ipv4 = numbers.pop(); + let counter = 0; + for (const n of numbers) { + ipv4 += n * 256 ** (3 - counter); + ++counter; + } + return ipv4; + } + function serializeIPv4(address) { + let output = ""; + let n = address; + for (let i = 1; i <= 4; ++i) { + output = String(n % 256) + output; + if (i !== 4) { + output = `.${output}`; + } + n = Math.floor(n / 256); + } + return output; + } + function parseIPv6(input) { + const address = [0, 0, 0, 0, 0, 0, 0, 0]; + let pieceIndex = 0; + let compress = null; + let pointer = 0; + input = Array.from(input, (c) => c.codePointAt(0)); + if (input[pointer] === p(":")) { + if (input[pointer + 1] !== p(":")) { + return failure; + } + pointer += 2; + ++pieceIndex; + compress = pieceIndex; + } + while (pointer < input.length) { + if (pieceIndex === 8) { + return failure; + } + if (input[pointer] === p(":")) { + if (compress !== null) { + return failure; + } + ++pointer; + ++pieceIndex; + compress = pieceIndex; + continue; + } + let value = 0; + let length = 0; + while (length < 4 && infra.isASCIIHex(input[pointer])) { + value = value * 16 + parseInt(at(input, pointer), 16); + ++pointer; + ++length; + } + if (input[pointer] === p(".")) { + if (length === 0) { + return failure; + } + pointer -= length; + if (pieceIndex > 6) { + return failure; + } + let numbersSeen = 0; + while (input[pointer] !== void 0) { + let ipv4Piece = null; + if (numbersSeen > 0) { + if (input[pointer] === p(".") && numbersSeen < 4) { + ++pointer; + } else { + return failure; + } + } + if (!infra.isASCIIDigit(input[pointer])) { + return failure; + } + while (infra.isASCIIDigit(input[pointer])) { + const number5 = parseInt(at(input, pointer)); + if (ipv4Piece === null) { + ipv4Piece = number5; + } else if (ipv4Piece === 0) { + return failure; + } else { + ipv4Piece = ipv4Piece * 10 + number5; + } + if (ipv4Piece > 255) { + return failure; + } + ++pointer; + } + address[pieceIndex] = address[pieceIndex] * 256 + ipv4Piece; + ++numbersSeen; + if (numbersSeen === 2 || numbersSeen === 4) { + ++pieceIndex; + } + } + if (numbersSeen !== 4) { + return failure; + } + break; + } else if (input[pointer] === p(":")) { + ++pointer; + if (input[pointer] === void 0) { + return failure; + } + } else if (input[pointer] !== void 0) { + return failure; + } + address[pieceIndex] = value; + ++pieceIndex; + } + if (compress !== null) { + let swaps = pieceIndex - compress; + pieceIndex = 7; + while (pieceIndex !== 0 && swaps > 0) { + const temp = address[compress + swaps - 1]; + address[compress + swaps - 1] = address[pieceIndex]; + address[pieceIndex] = temp; + --pieceIndex; + --swaps; + } + } else if (compress === null && pieceIndex !== 8) { + return failure; + } + return address; + } + function serializeIPv6(address) { + let output = ""; + const compress = findTheIPv6AddressCompressedPieceIndex(address); + let ignore0 = false; + for (let pieceIndex = 0; pieceIndex <= 7; ++pieceIndex) { + if (ignore0 && address[pieceIndex] === 0) { + continue; + } else if (ignore0) { + ignore0 = false; + } + if (compress === pieceIndex) { + const separator = pieceIndex === 0 ? "::" : ":"; + output += separator; + ignore0 = true; + continue; + } + output += address[pieceIndex].toString(16); + if (pieceIndex !== 7) { + output += ":"; + } + } + return output; + } + function parseHost(input, isOpaque = false) { + if (input[0] === "[") { + if (input[input.length - 1] !== "]") { + return failure; + } + return parseIPv6(input.substring(1, input.length - 1)); + } + if (isOpaque) { + return parseOpaqueHost(input); + } + const domain = utf8DecodeWithoutBOM(percentDecodeString(input)); + const asciiDomain = domainToASCII(domain); + if (asciiDomain === failure) { + return failure; + } + if (endsInANumber(asciiDomain)) { + return parseIPv4(asciiDomain); + } + return asciiDomain; + } + function endsInANumber(input) { + const parts = input.split("."); + if (parts[parts.length - 1] === "") { + if (parts.length === 1) { + return false; + } + parts.pop(); + } + const last = parts[parts.length - 1]; + if (parseIPv4Number(last) !== failure) { + return true; + } + if (/^[0-9]+$/u.test(last)) { + return true; + } + return false; + } + function parseOpaqueHost(input) { + if (containsForbiddenHostCodePoint(input)) { + return failure; + } + return utf8PercentEncodeString(input, isC0ControlPercentEncode); + } + function findTheIPv6AddressCompressedPieceIndex(address) { + let longestIndex = null; + let longestSize = 1; + let foundIndex = null; + let foundSize = 0; + for (let pieceIndex = 0; pieceIndex < address.length; ++pieceIndex) { + if (address[pieceIndex] !== 0) { + if (foundSize > longestSize) { + longestIndex = foundIndex; + longestSize = foundSize; + } + foundIndex = null; + foundSize = 0; + } else { + if (foundIndex === null) { + foundIndex = pieceIndex; + } + ++foundSize; + } + } + if (foundSize > longestSize) { + return foundIndex; + } + return longestIndex; + } + function serializeHost(host) { + if (typeof host === "number") { + return serializeIPv4(host); + } + if (host instanceof Array) { + return `[${serializeIPv6(host)}]`; + } + return host; + } + function domainToASCII(domain, beStrict = false) { + const result = tr46.toASCII(domain, { + checkHyphens: beStrict, + checkBidi: true, + checkJoiners: true, + useSTD3ASCIIRules: beStrict, + transitionalProcessing: false, + verifyDNSLength: beStrict, + ignoreInvalidPunycode: false + }); + if (result === null) { + return failure; + } + if (!beStrict) { + if (result === "") { + return failure; + } + if (containsForbiddenDomainCodePoint(result)) { + return failure; + } + } + return result; + } + function trimControlChars(string11) { + let start = 0; + let end = string11.length; + for (; start < end; ++start) { + if (string11.charCodeAt(start) > 32) { + break; + } + } + for (; end > start; --end) { + if (string11.charCodeAt(end - 1) > 32) { + break; + } + } + return string11.substring(start, end); + } + function trimTabAndNewline(url2) { + return url2.replace(/\u0009|\u000A|\u000D/ug, ""); + } + function shortenPath(url2) { + const { path: path6 } = url2; + if (path6.length === 0) { + return; + } + if (url2.scheme === "file" && path6.length === 1 && isNormalizedWindowsDriveLetter(path6[0])) { + return; + } + path6.pop(); + } + function includesCredentials(url2) { + return url2.username !== "" || url2.password !== ""; + } + function cannotHaveAUsernamePasswordPort(url2) { + return url2.host === null || url2.host === "" || url2.scheme === "file"; + } + function hasAnOpaquePath(url2) { + return typeof url2.path === "string"; + } + function isNormalizedWindowsDriveLetter(string11) { + return /^[A-Za-z]:$/u.test(string11); + } + function URLStateMachine(input, base, encodingOverride, url2, stateOverride) { + this.pointer = 0; + this.input = input; + this.base = base || null; + this.encodingOverride = encodingOverride || "utf-8"; + this.stateOverride = stateOverride; + this.url = url2; + this.failure = false; + this.parseError = false; + if (!this.url) { + this.url = { + scheme: "", + username: "", + password: "", + host: null, + port: null, + path: [], + query: null, + fragment: null + }; + const res2 = trimControlChars(this.input); + if (res2 !== this.input) { + this.parseError = true; + } + this.input = res2; + } + const res = trimTabAndNewline(this.input); + if (res !== this.input) { + this.parseError = true; + } + this.input = res; + this.state = stateOverride || "scheme start"; + this.buffer = ""; + this.atFlag = false; + this.arrFlag = false; + this.passwordTokenSeenFlag = false; + this.input = Array.from(this.input, (c) => c.codePointAt(0)); + for (; this.pointer <= this.input.length; ++this.pointer) { + const c = this.input[this.pointer]; + const cStr = isNaN(c) ? void 0 : String.fromCodePoint(c); + const ret = this[`parse ${this.state}`](c, cStr); + if (!ret) { + break; + } else if (ret === failure) { + this.failure = true; + break; + } + } + } + URLStateMachine.prototype["parse scheme start"] = function parseSchemeStart(c, cStr) { + if (infra.isASCIIAlpha(c)) { + this.buffer += cStr.toLowerCase(); + this.state = "scheme"; + } else if (!this.stateOverride) { + this.state = "no scheme"; + --this.pointer; + } else { + this.parseError = true; + return failure; + } + return true; + }; + URLStateMachine.prototype["parse scheme"] = function parseScheme(c, cStr) { + if (infra.isASCIIAlphanumeric(c) || c === p("+") || c === p("-") || c === p(".")) { + this.buffer += cStr.toLowerCase(); + } else if (c === p(":")) { + if (this.stateOverride) { + if (isSpecial(this.url) && !isSpecialScheme(this.buffer)) { + return false; + } + if (!isSpecial(this.url) && isSpecialScheme(this.buffer)) { + return false; + } + if ((includesCredentials(this.url) || this.url.port !== null) && this.buffer === "file") { + return false; + } + if (this.url.scheme === "file" && this.url.host === "") { + return false; + } + } + this.url.scheme = this.buffer; + if (this.stateOverride) { + if (this.url.port === defaultPort(this.url.scheme)) { + this.url.port = null; + } + return false; + } + this.buffer = ""; + if (this.url.scheme === "file") { + if (this.input[this.pointer + 1] !== p("/") || this.input[this.pointer + 2] !== p("/")) { + this.parseError = true; + } + this.state = "file"; + } else if (isSpecial(this.url) && this.base !== null && this.base.scheme === this.url.scheme) { + this.state = "special relative or authority"; + } else if (isSpecial(this.url)) { + this.state = "special authority slashes"; + } else if (this.input[this.pointer + 1] === p("/")) { + this.state = "path or authority"; + ++this.pointer; + } else { + this.url.path = ""; + this.state = "opaque path"; + } + } else if (!this.stateOverride) { + this.buffer = ""; + this.state = "no scheme"; + this.pointer = -1; + } else { + this.parseError = true; + return failure; + } + return true; + }; + URLStateMachine.prototype["parse no scheme"] = function parseNoScheme(c) { + if (this.base === null || hasAnOpaquePath(this.base) && c !== p("#")) { + return failure; + } else if (hasAnOpaquePath(this.base) && c === p("#")) { + this.url.scheme = this.base.scheme; + this.url.path = this.base.path; + this.url.query = this.base.query; + this.url.fragment = ""; + this.state = "fragment"; + } else if (this.base.scheme === "file") { + this.state = "file"; + --this.pointer; + } else { + this.state = "relative"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse special relative or authority"] = function parseSpecialRelativeOrAuthority(c) { + if (c === p("/") && this.input[this.pointer + 1] === p("/")) { + this.state = "special authority ignore slashes"; + ++this.pointer; + } else { + this.parseError = true; + this.state = "relative"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse path or authority"] = function parsePathOrAuthority(c) { + if (c === p("/")) { + this.state = "authority"; + } else { + this.state = "path"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse relative"] = function parseRelative(c) { + this.url.scheme = this.base.scheme; + if (c === p("/")) { + this.state = "relative slash"; + } else if (isSpecial(this.url) && c === p("\\")) { + this.parseError = true; + this.state = "relative slash"; + } else { + this.url.username = this.base.username; + this.url.password = this.base.password; + this.url.host = this.base.host; + this.url.port = this.base.port; + this.url.path = this.base.path.slice(); + this.url.query = this.base.query; + if (c === p("?")) { + this.url.query = ""; + this.state = "query"; + } else if (c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } else if (!isNaN(c)) { + this.url.query = null; + this.url.path.pop(); + this.state = "path"; + --this.pointer; + } + } + return true; + }; + URLStateMachine.prototype["parse relative slash"] = function parseRelativeSlash(c) { + if (isSpecial(this.url) && (c === p("/") || c === p("\\"))) { + if (c === p("\\")) { + this.parseError = true; + } + this.state = "special authority ignore slashes"; + } else if (c === p("/")) { + this.state = "authority"; + } else { + this.url.username = this.base.username; + this.url.password = this.base.password; + this.url.host = this.base.host; + this.url.port = this.base.port; + this.state = "path"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse special authority slashes"] = function parseSpecialAuthoritySlashes(c) { + if (c === p("/") && this.input[this.pointer + 1] === p("/")) { + this.state = "special authority ignore slashes"; + ++this.pointer; + } else { + this.parseError = true; + this.state = "special authority ignore slashes"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse special authority ignore slashes"] = function parseSpecialAuthorityIgnoreSlashes(c) { + if (c !== p("/") && c !== p("\\")) { + this.state = "authority"; + --this.pointer; + } else { + this.parseError = true; + } + return true; + }; + URLStateMachine.prototype["parse authority"] = function parseAuthority(c, cStr) { + if (c === p("@")) { + this.parseError = true; + if (this.atFlag) { + this.buffer = `%40${this.buffer}`; + } + this.atFlag = true; + const len = countSymbols(this.buffer); + for (let pointer = 0; pointer < len; ++pointer) { + const codePoint = this.buffer.codePointAt(pointer); + if (codePoint === p(":") && !this.passwordTokenSeenFlag) { + this.passwordTokenSeenFlag = true; + continue; + } + const encodedCodePoints = utf8PercentEncodeCodePoint(codePoint, isUserinfoPercentEncode); + if (this.passwordTokenSeenFlag) { + this.url.password += encodedCodePoints; + } else { + this.url.username += encodedCodePoints; + } + } + this.buffer = ""; + } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\")) { + if (this.atFlag && this.buffer === "") { + this.parseError = true; + return failure; + } + this.pointer -= countSymbols(this.buffer) + 1; + this.buffer = ""; + this.state = "host"; + } else { + this.buffer += cStr; + } + return true; + }; + URLStateMachine.prototype["parse hostname"] = URLStateMachine.prototype["parse host"] = function parseHostName(c, cStr) { + if (this.stateOverride && this.url.scheme === "file") { + --this.pointer; + this.state = "file host"; + } else if (c === p(":") && !this.arrFlag) { + if (this.buffer === "") { + this.parseError = true; + return failure; + } + if (this.stateOverride === "hostname") { + return false; + } + const host = parseHost(this.buffer, isNotSpecial(this.url)); + if (host === failure) { + return failure; + } + this.url.host = host; + this.buffer = ""; + this.state = "port"; + } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\")) { + --this.pointer; + if (isSpecial(this.url) && this.buffer === "") { + this.parseError = true; + return failure; + } else if (this.stateOverride && this.buffer === "" && (includesCredentials(this.url) || this.url.port !== null)) { + this.parseError = true; + return false; + } + const host = parseHost(this.buffer, isNotSpecial(this.url)); + if (host === failure) { + return failure; + } + this.url.host = host; + this.buffer = ""; + this.state = "path start"; + if (this.stateOverride) { + return false; + } + } else { + if (c === p("[")) { + this.arrFlag = true; + } else if (c === p("]")) { + this.arrFlag = false; + } + this.buffer += cStr; + } + return true; + }; + URLStateMachine.prototype["parse port"] = function parsePort(c, cStr) { + if (infra.isASCIIDigit(c)) { + this.buffer += cStr; + } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\") || this.stateOverride) { + if (this.buffer !== "") { + const port = parseInt(this.buffer); + if (port > 2 ** 16 - 1) { + this.parseError = true; + return failure; + } + this.url.port = port === defaultPort(this.url.scheme) ? null : port; + this.buffer = ""; + } + if (this.stateOverride) { + return false; + } + this.state = "path start"; + --this.pointer; + } else { + this.parseError = true; + return failure; + } + return true; + }; + var fileOtherwiseCodePoints = /* @__PURE__ */ new Set([p("/"), p("\\"), p("?"), p("#")]); + function startsWithWindowsDriveLetter(input, pointer) { + const length = input.length - pointer; + return length >= 2 && isWindowsDriveLetterCodePoints(input[pointer], input[pointer + 1]) && (length === 2 || fileOtherwiseCodePoints.has(input[pointer + 2])); + } + URLStateMachine.prototype["parse file"] = function parseFile(c) { + this.url.scheme = "file"; + this.url.host = ""; + if (c === p("/") || c === p("\\")) { + if (c === p("\\")) { + this.parseError = true; + } + this.state = "file slash"; + } else if (this.base !== null && this.base.scheme === "file") { + this.url.host = this.base.host; + this.url.path = this.base.path.slice(); + this.url.query = this.base.query; + if (c === p("?")) { + this.url.query = ""; + this.state = "query"; + } else if (c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } else if (!isNaN(c)) { + this.url.query = null; + if (!startsWithWindowsDriveLetter(this.input, this.pointer)) { + shortenPath(this.url); + } else { + this.parseError = true; + this.url.path = []; + } + this.state = "path"; + --this.pointer; + } + } else { + this.state = "path"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse file slash"] = function parseFileSlash(c) { + if (c === p("/") || c === p("\\")) { + if (c === p("\\")) { + this.parseError = true; + } + this.state = "file host"; + } else { + if (this.base !== null && this.base.scheme === "file") { + if (!startsWithWindowsDriveLetter(this.input, this.pointer) && isNormalizedWindowsDriveLetterString(this.base.path[0])) { + this.url.path.push(this.base.path[0]); + } + this.url.host = this.base.host; + } + this.state = "path"; + --this.pointer; + } + return true; + }; + URLStateMachine.prototype["parse file host"] = function parseFileHost(c, cStr) { + if (isNaN(c) || c === p("/") || c === p("\\") || c === p("?") || c === p("#")) { + --this.pointer; + if (!this.stateOverride && isWindowsDriveLetterString(this.buffer)) { + this.parseError = true; + this.state = "path"; + } else if (this.buffer === "") { + this.url.host = ""; + if (this.stateOverride) { + return false; + } + this.state = "path start"; + } else { + let host = parseHost(this.buffer, isNotSpecial(this.url)); + if (host === failure) { + return failure; + } + if (host === "localhost") { + host = ""; + } + this.url.host = host; + if (this.stateOverride) { + return false; + } + this.buffer = ""; + this.state = "path start"; + } + } else { + this.buffer += cStr; + } + return true; + }; + URLStateMachine.prototype["parse path start"] = function parsePathStart(c) { + if (isSpecial(this.url)) { + if (c === p("\\")) { + this.parseError = true; + } + this.state = "path"; + if (c !== p("/") && c !== p("\\")) { + --this.pointer; + } + } else if (!this.stateOverride && c === p("?")) { + this.url.query = ""; + this.state = "query"; + } else if (!this.stateOverride && c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } else if (c !== void 0) { + this.state = "path"; + if (c !== p("/")) { + --this.pointer; + } + } else if (this.stateOverride && this.url.host === null) { + this.url.path.push(""); + } + return true; + }; + URLStateMachine.prototype["parse path"] = function parsePath(c) { + if (isNaN(c) || c === p("/") || isSpecial(this.url) && c === p("\\") || !this.stateOverride && (c === p("?") || c === p("#"))) { + if (isSpecial(this.url) && c === p("\\")) { + this.parseError = true; + } + if (isDoubleDot(this.buffer)) { + shortenPath(this.url); + if (c !== p("/") && !(isSpecial(this.url) && c === p("\\"))) { + this.url.path.push(""); + } + } else if (isSingleDot(this.buffer) && c !== p("/") && !(isSpecial(this.url) && c === p("\\"))) { + this.url.path.push(""); + } else if (!isSingleDot(this.buffer)) { + if (this.url.scheme === "file" && this.url.path.length === 0 && isWindowsDriveLetterString(this.buffer)) { + this.buffer = `${this.buffer[0]}:`; + } + this.url.path.push(this.buffer); + } + this.buffer = ""; + if (c === p("?")) { + this.url.query = ""; + this.state = "query"; + } + if (c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } + } else { + if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { + this.parseError = true; + } + this.buffer += utf8PercentEncodeCodePoint(c, isPathPercentEncode); + } + return true; + }; + URLStateMachine.prototype["parse opaque path"] = function parseOpaquePath(c) { + if (c === p("?")) { + this.url.query = ""; + this.state = "query"; + } else if (c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } else if (c === p(" ")) { + const remaining = this.input[this.pointer + 1]; + if (remaining === p("?") || remaining === p("#")) { + this.url.path += "%20"; + } else { + this.url.path += " "; + } + } else { + if (!isNaN(c) && c !== p("%")) { + this.parseError = true; + } + if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { + this.parseError = true; + } + if (!isNaN(c)) { + this.url.path += utf8PercentEncodeCodePoint(c, isC0ControlPercentEncode); + } + } + return true; + }; + URLStateMachine.prototype["parse query"] = function parseQuery(c, cStr) { + if (!isSpecial(this.url) || this.url.scheme === "ws" || this.url.scheme === "wss") { + this.encodingOverride = "utf-8"; + } + if (!this.stateOverride && c === p("#") || isNaN(c)) { + const queryPercentEncodePredicate = isSpecial(this.url) ? isSpecialQueryPercentEncode : isQueryPercentEncode; + this.url.query += utf8PercentEncodeString(this.buffer, queryPercentEncodePredicate); + this.buffer = ""; + if (c === p("#")) { + this.url.fragment = ""; + this.state = "fragment"; + } + } else if (!isNaN(c)) { + if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { + this.parseError = true; + } + this.buffer += cStr; + } + return true; + }; + URLStateMachine.prototype["parse fragment"] = function parseFragment(c) { + if (!isNaN(c)) { + if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { + this.parseError = true; + } + this.url.fragment += utf8PercentEncodeCodePoint(c, isFragmentPercentEncode); + } + return true; + }; + function serializeURL(url2, excludeFragment) { + let output = `${url2.scheme}:`; + if (url2.host !== null) { + output += "//"; + if (url2.username !== "" || url2.password !== "") { + output += url2.username; + if (url2.password !== "") { + output += `:${url2.password}`; + } + output += "@"; + } + output += serializeHost(url2.host); + if (url2.port !== null) { + output += `:${url2.port}`; + } + } + if (url2.host === null && !hasAnOpaquePath(url2) && url2.path.length > 1 && url2.path[0] === "") { + output += "/."; + } + output += serializePath(url2); + if (url2.query !== null) { + output += `?${url2.query}`; + } + if (!excludeFragment && url2.fragment !== null) { + output += `#${url2.fragment}`; + } + return output; + } + function serializeOrigin(tuple) { + let result = `${tuple.scheme}://`; + result += serializeHost(tuple.host); + if (tuple.port !== null) { + result += `:${tuple.port}`; + } + return result; + } + function serializePath(url2) { + if (hasAnOpaquePath(url2)) { + return url2.path; + } + let output = ""; + for (const segment of url2.path) { + output += `/${segment}`; + } + return output; + } + module3.exports.serializeURL = serializeURL; + module3.exports.serializePath = serializePath; + module3.exports.serializeURLOrigin = function(url2) { + switch (url2.scheme) { + case "blob": { + const pathURL = module3.exports.parseURL(serializePath(url2)); + if (pathURL === null) { + return "null"; + } + if (pathURL.scheme !== "http" && pathURL.scheme !== "https") { + return "null"; + } + return module3.exports.serializeURLOrigin(pathURL); + } + case "ftp": + case "http": + case "https": + case "ws": + case "wss": + return serializeOrigin({ + scheme: url2.scheme, + host: url2.host, + port: url2.port + }); + case "file": + return "null"; + default: + return "null"; + } + }; + module3.exports.basicURLParse = function(input, options2) { + if (options2 === void 0) { + options2 = {}; + } + const usm = new URLStateMachine(input, options2.baseURL, options2.encodingOverride, options2.url, options2.stateOverride); + if (usm.failure) { + return null; + } + return usm.url; + }; + module3.exports.setTheUsername = function(url2, username) { + url2.username = utf8PercentEncodeString(username, isUserinfoPercentEncode); + }; + module3.exports.setThePassword = function(url2, password) { + url2.password = utf8PercentEncodeString(password, isUserinfoPercentEncode); + }; + module3.exports.serializeHost = serializeHost; + module3.exports.cannotHaveAUsernamePasswordPort = cannotHaveAUsernamePasswordPort; + module3.exports.hasAnOpaquePath = hasAnOpaquePath; + module3.exports.serializeInteger = function(integer5) { + return String(integer5); + }; + module3.exports.parseURL = function(input, options2) { + if (options2 === void 0) { + options2 = {}; + } + return module3.exports.basicURLParse(input, { baseURL: options2.baseURL, encodingOverride: options2.encodingOverride }); + }; + } +}); + +// node_modules/whatwg-url/lib/urlencoded.js +var require_urlencoded = __commonJS({ + "node_modules/whatwg-url/lib/urlencoded.js"(exports2, module3) { + "use strict"; + var { utf8Encode, utf8DecodeWithoutBOM } = require_encoding(); + var { percentDecodeBytes, utf8PercentEncodeString, isURLEncodedPercentEncode } = require_percent_encoding(); + function p(char) { + return char.codePointAt(0); + } + function parseUrlencoded(input) { + const sequences = strictlySplitByteSequence(input, p("&")); + const output = []; + for (const bytes of sequences) { + if (bytes.length === 0) { + continue; + } + let name, value; + const indexOfEqual = bytes.indexOf(p("=")); + if (indexOfEqual >= 0) { + name = bytes.slice(0, indexOfEqual); + value = bytes.slice(indexOfEqual + 1); + } else { + name = bytes; + value = new Uint8Array(0); + } + name = replaceByteInByteSequence(name, 43, 32); + value = replaceByteInByteSequence(value, 43, 32); + const nameString = utf8DecodeWithoutBOM(percentDecodeBytes(name)); + const valueString = utf8DecodeWithoutBOM(percentDecodeBytes(value)); + output.push([nameString, valueString]); + } + return output; + } + function parseUrlencodedString(input) { + return parseUrlencoded(utf8Encode(input)); + } + function serializeUrlencoded(tuples) { + let output = ""; + for (const [i, tuple] of tuples.entries()) { + const name = utf8PercentEncodeString(tuple[0], isURLEncodedPercentEncode, true); + const value = utf8PercentEncodeString(tuple[1], isURLEncodedPercentEncode, true); + if (i !== 0) { + output += "&"; + } + output += `${name}=${value}`; + } + return output; + } + function strictlySplitByteSequence(buf, cp2) { + const list4 = []; + let last = 0; + let i = buf.indexOf(cp2); + while (i >= 0) { + list4.push(buf.slice(last, i)); + last = i + 1; + i = buf.indexOf(cp2, last); + } + if (last !== buf.length) { + list4.push(buf.slice(last)); + } + return list4; + } + function replaceByteInByteSequence(buf, from, to) { + let i = buf.indexOf(from); + while (i >= 0) { + buf[i] = to; + i = buf.indexOf(from, i + 1); + } + return buf; + } + module3.exports = { + parseUrlencodedString, + serializeUrlencoded + }; + } +}); + +// node_modules/whatwg-url/lib/Function.js +var require_Function = __commonJS({ + "node_modules/whatwg-url/lib/Function.js"(exports2) { + "use strict"; + var conversions = require_lib(); + var utils = require_utils(); + exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { + if (typeof value !== "function") { + throw new globalObject.TypeError(context + " is not a function"); + } + function invokeTheCallbackFunction(...args) { + const thisArg = utils.tryWrapperForImpl(this); + let callResult; + for (let i = 0; i < args.length; i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + callResult = Reflect.apply(value, thisArg, args); + callResult = conversions["any"](callResult, { context, globals: globalObject }); + return callResult; + } + invokeTheCallbackFunction.construct = (...args) => { + for (let i = 0; i < args.length; i++) { + args[i] = utils.tryWrapperForImpl(args[i]); + } + let callResult = Reflect.construct(value, args); + callResult = conversions["any"](callResult, { context, globals: globalObject }); + return callResult; + }; + invokeTheCallbackFunction[utils.wrapperSymbol] = value; + invokeTheCallbackFunction.objectReference = value; + return invokeTheCallbackFunction; + }; + } +}); + +// node_modules/whatwg-url/lib/URLSearchParams-impl.js +var require_URLSearchParams_impl = __commonJS({ + "node_modules/whatwg-url/lib/URLSearchParams-impl.js"(exports2) { + "use strict"; + var urlencoded = require_urlencoded(); + exports2.implementation = class URLSearchParamsImpl { + constructor(globalObject, constructorArgs, { doNotStripQMark = false }) { + let init = constructorArgs[0]; + this._list = []; + this._url = null; + if (!doNotStripQMark && typeof init === "string" && init[0] === "?") { + init = init.slice(1); + } + if (Array.isArray(init)) { + for (const pair of init) { + if (pair.length !== 2) { + throw new TypeError("Failed to construct 'URLSearchParams': parameter 1 sequence's element does not contain exactly two elements."); + } + this._list.push([pair[0], pair[1]]); + } + } else if (typeof init === "object" && Object.getPrototypeOf(init) === null) { + for (const name of Object.keys(init)) { + const value = init[name]; + this._list.push([name, value]); + } + } else { + this._list = urlencoded.parseUrlencodedString(init); + } + } + _updateSteps() { + if (this._url !== null) { + let serializedQuery = urlencoded.serializeUrlencoded(this._list); + if (serializedQuery === "") { + serializedQuery = null; + } + this._url._url.query = serializedQuery; + } + } + get size() { + return this._list.length; + } + append(name, value) { + this._list.push([name, value]); + this._updateSteps(); + } + delete(name, value) { + let i = 0; + while (i < this._list.length) { + if (this._list[i][0] === name && (value === void 0 || this._list[i][1] === value)) { + this._list.splice(i, 1); + } else { + i++; + } + } + this._updateSteps(); + } + get(name) { + for (const tuple of this._list) { + if (tuple[0] === name) { + return tuple[1]; + } + } + return null; + } + getAll(name) { + const output = []; + for (const tuple of this._list) { + if (tuple[0] === name) { + output.push(tuple[1]); + } + } + return output; + } + has(name, value) { + for (const tuple of this._list) { + if (tuple[0] === name && (value === void 0 || tuple[1] === value)) { + return true; + } + } + return false; + } + set(name, value) { + let found = false; + let i = 0; + while (i < this._list.length) { + if (this._list[i][0] === name) { + if (found) { + this._list.splice(i, 1); + } else { + found = true; + this._list[i][1] = value; + i++; + } + } else { + i++; + } + } + if (!found) { + this._list.push([name, value]); + } + this._updateSteps(); + } + sort() { + this._list.sort((a, b) => { + if (a[0] < b[0]) { + return -1; + } + if (a[0] > b[0]) { + return 1; + } + return 0; + }); + this._updateSteps(); + } + [Symbol.iterator]() { + return this._list[Symbol.iterator](); + } + toString() { + return urlencoded.serializeUrlencoded(this._list); + } + }; + } +}); + +// node_modules/whatwg-url/lib/URLSearchParams.js +var require_URLSearchParams = __commonJS({ + "node_modules/whatwg-url/lib/URLSearchParams.js"(exports2) { + "use strict"; + var conversions = require_lib(); + var utils = require_utils(); + var Function2 = require_Function(); + var newObjectInRealm = utils.newObjectInRealm; + var implSymbol = utils.implSymbol; + var ctorRegistrySymbol = utils.ctorRegistrySymbol; + var interfaceName = "URLSearchParams"; + exports2.is = (value) => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; + }; + exports2.isImpl = (value) => { + return utils.isObject(value) && value instanceof Impl.implementation; + }; + exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { + if (exports2.is(value)) { + return utils.implForWrapper(value); + } + throw new globalObject.TypeError(`${context} is not of type 'URLSearchParams'.`); + }; + exports2.createDefaultIterator = (globalObject, target, kind) => { + const ctorRegistry = globalObject[ctorRegistrySymbol]; + const iteratorPrototype = ctorRegistry["URLSearchParams Iterator"]; + const iterator = Object.create(iteratorPrototype); + Object.defineProperty(iterator, utils.iterInternalSymbol, { + value: { target, kind, index: 0 }, + configurable: true + }); + return iterator; + }; + function makeWrapper(globalObject, newTarget) { + let proto; + if (newTarget !== void 0) { + proto = newTarget.prototype; + } + if (!utils.isObject(proto)) { + proto = globalObject[ctorRegistrySymbol]["URLSearchParams"].prototype; + } + return Object.create(proto); + } + exports2.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports2.setup(wrapper, globalObject, constructorArgs, privateData); + }; + exports2.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports2.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); + }; + exports2._internalSetup = (wrapper, globalObject) => { + }; + exports2.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + exports2._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; + }; + exports2.new = (globalObject, newTarget) => { + const wrapper = makeWrapper(globalObject, newTarget); + exports2._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; + }; + var exposed = /* @__PURE__ */ new Set(["Window", "Worker"]); + exports2.install = (globalObject, globalNames) => { + if (!globalNames.some((globalName) => exposed.has(globalName))) { + return; + } + const ctorRegistry = utils.initCtorRegistry(globalObject); + class URLSearchParams { + constructor() { + const args = []; + { + let curArg = arguments[0]; + if (curArg !== void 0) { + if (utils.isObject(curArg)) { + if (curArg[Symbol.iterator] !== void 0) { + if (!utils.isObject(curArg)) { + throw new globalObject.TypeError( + "Failed to construct 'URLSearchParams': parameter 1 sequence is not an iterable object." + ); + } else { + const V = []; + const tmp = curArg; + for (let nextItem of tmp) { + if (!utils.isObject(nextItem)) { + throw new globalObject.TypeError( + "Failed to construct 'URLSearchParams': parameter 1 sequence's element is not an iterable object." + ); + } else { + const V2 = []; + const tmp2 = nextItem; + for (let nextItem2 of tmp2) { + nextItem2 = conversions["USVString"](nextItem2, { + context: "Failed to construct 'URLSearchParams': parameter 1 sequence's element's element", + globals: globalObject + }); + V2.push(nextItem2); + } + nextItem = V2; + } + V.push(nextItem); + } + curArg = V; + } + } else { + if (!utils.isObject(curArg)) { + throw new globalObject.TypeError( + "Failed to construct 'URLSearchParams': parameter 1 record is not an object." + ); + } else { + const result = /* @__PURE__ */ Object.create(null); + for (const key2 of Reflect.ownKeys(curArg)) { + const desc = Object.getOwnPropertyDescriptor(curArg, key2); + if (desc && desc.enumerable) { + let typedKey = key2; + typedKey = conversions["USVString"](typedKey, { + context: "Failed to construct 'URLSearchParams': parameter 1 record's key", + globals: globalObject + }); + let typedValue = curArg[key2]; + typedValue = conversions["USVString"](typedValue, { + context: "Failed to construct 'URLSearchParams': parameter 1 record's value", + globals: globalObject + }); + result[typedKey] = typedValue; + } + } + curArg = result; + } + } + } else { + curArg = conversions["USVString"](curArg, { + context: "Failed to construct 'URLSearchParams': parameter 1", + globals: globalObject + }); + } + } else { + curArg = ""; + } + args.push(curArg); + } + return exports2.setup(Object.create(new.target.prototype), globalObject, args); + } + append(name, value) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError( + "'append' called on an object that is not a valid instance of URLSearchParams." + ); + } + if (arguments.length < 2) { + throw new globalObject.TypeError( + `Failed to execute 'append' on 'URLSearchParams': 2 arguments required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'append' on 'URLSearchParams': parameter 2", + globals: globalObject + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].append(...args)); + } + delete(name) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError( + "'delete' called on an object that is not a valid instance of URLSearchParams." + ); + } + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'delete' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'delete' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== void 0) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'delete' on 'URLSearchParams': parameter 2", + globals: globalObject + }); + } + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].delete(...args)); + } + get(name) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get' called on an object that is not a valid instance of URLSearchParams."); + } + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'get' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'get' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + return esValue[implSymbol].get(...args); + } + getAll(name) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError( + "'getAll' called on an object that is not a valid instance of URLSearchParams." + ); + } + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'getAll' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'getAll' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].getAll(...args)); + } + has(name) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'has' called on an object that is not a valid instance of URLSearchParams."); + } + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'has' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'has' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== void 0) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'has' on 'URLSearchParams': parameter 2", + globals: globalObject + }); + } + args.push(curArg); + } + return esValue[implSymbol].has(...args); + } + set(name, value) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set' called on an object that is not a valid instance of URLSearchParams."); + } + if (arguments.length < 2) { + throw new globalObject.TypeError( + `Failed to execute 'set' on 'URLSearchParams': 2 arguments required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'URLSearchParams': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'set' on 'URLSearchParams': parameter 2", + globals: globalObject + }); + args.push(curArg); + } + return utils.tryWrapperForImpl(esValue[implSymbol].set(...args)); + } + sort() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'sort' called on an object that is not a valid instance of URLSearchParams."); + } + return utils.tryWrapperForImpl(esValue[implSymbol].sort()); + } + toString() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError( + "'toString' called on an object that is not a valid instance of URLSearchParams." + ); + } + return esValue[implSymbol].toString(); + } + keys() { + if (!exports2.is(this)) { + throw new globalObject.TypeError("'keys' called on an object that is not a valid instance of URLSearchParams."); + } + return exports2.createDefaultIterator(globalObject, this, "key"); + } + values() { + if (!exports2.is(this)) { + throw new globalObject.TypeError( + "'values' called on an object that is not a valid instance of URLSearchParams." + ); + } + return exports2.createDefaultIterator(globalObject, this, "value"); + } + entries() { + if (!exports2.is(this)) { + throw new globalObject.TypeError( + "'entries' called on an object that is not a valid instance of URLSearchParams." + ); + } + return exports2.createDefaultIterator(globalObject, this, "key+value"); + } + forEach(callback) { + if (!exports2.is(this)) { + throw new globalObject.TypeError( + "'forEach' called on an object that is not a valid instance of URLSearchParams." + ); + } + if (arguments.length < 1) { + throw new globalObject.TypeError( + "Failed to execute 'forEach' on 'iterable': 1 argument required, but only 0 present." + ); + } + callback = Function2.convert(globalObject, callback, { + context: "Failed to execute 'forEach' on 'iterable': The callback provided as parameter 1" + }); + const thisArg = arguments[1]; + let pairs = Array.from(this[implSymbol]); + let i = 0; + while (i < pairs.length) { + const [key2, value] = pairs[i].map(utils.tryWrapperForImpl); + callback.call(thisArg, value, key2, this); + pairs = Array.from(this[implSymbol]); + i++; + } + } + get size() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError( + "'get size' called on an object that is not a valid instance of URLSearchParams." + ); + } + return esValue[implSymbol]["size"]; + } + } + Object.defineProperties(URLSearchParams.prototype, { + append: { enumerable: true }, + delete: { enumerable: true }, + get: { enumerable: true }, + getAll: { enumerable: true }, + has: { enumerable: true }, + set: { enumerable: true }, + sort: { enumerable: true }, + toString: { enumerable: true }, + keys: { enumerable: true }, + values: { enumerable: true }, + entries: { enumerable: true }, + forEach: { enumerable: true }, + size: { enumerable: true }, + [Symbol.toStringTag]: { value: "URLSearchParams", configurable: true }, + [Symbol.iterator]: { value: URLSearchParams.prototype.entries, configurable: true, writable: true } + }); + ctorRegistry[interfaceName] = URLSearchParams; + ctorRegistry["URLSearchParams Iterator"] = Object.create(ctorRegistry["%IteratorPrototype%"], { + [Symbol.toStringTag]: { + configurable: true, + value: "URLSearchParams Iterator" + } + }); + utils.define(ctorRegistry["URLSearchParams Iterator"], { + next() { + const internal = this && this[utils.iterInternalSymbol]; + if (!internal) { + throw new globalObject.TypeError("next() called on a value that is not a URLSearchParams iterator object"); + } + const { target, kind, index: index4 } = internal; + const values = Array.from(target[implSymbol]); + const len = values.length; + if (index4 >= len) { + return newObjectInRealm(globalObject, { value: void 0, done: true }); + } + const pair = values[index4]; + internal.index = index4 + 1; + return newObjectInRealm(globalObject, utils.iteratorResult(pair.map(utils.tryWrapperForImpl), kind)); + } + }); + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: URLSearchParams + }); + }; + var Impl = require_URLSearchParams_impl(); + } +}); + +// node_modules/whatwg-url/lib/URL-impl.js +var require_URL_impl = __commonJS({ + "node_modules/whatwg-url/lib/URL-impl.js"(exports2) { + "use strict"; + var usm = require_url_state_machine(); + var urlencoded = require_urlencoded(); + var URLSearchParams = require_URLSearchParams(); + exports2.implementation = class URLImpl { + // Unlike the spec, we duplicate some code between the constructor and canParse, because we want to give useful error + // messages in the constructor that distinguish between the different causes of failure. + constructor(globalObject, [url2, base]) { + let parsedBase = null; + if (base !== void 0) { + parsedBase = usm.basicURLParse(base); + if (parsedBase === null) { + throw new TypeError(`Invalid base URL: ${base}`); + } + } + const parsedURL = usm.basicURLParse(url2, { baseURL: parsedBase }); + if (parsedURL === null) { + throw new TypeError(`Invalid URL: ${url2}`); + } + const query = parsedURL.query !== null ? parsedURL.query : ""; + this._url = parsedURL; + this._query = URLSearchParams.createImpl(globalObject, [query], { doNotStripQMark: true }); + this._query._url = this; + } + static parse(globalObject, input, base) { + try { + return new URLImpl(globalObject, [input, base]); + } catch { + return null; + } + } + static canParse(url2, base) { + let parsedBase = null; + if (base !== void 0) { + parsedBase = usm.basicURLParse(base); + if (parsedBase === null) { + return false; + } + } + const parsedURL = usm.basicURLParse(url2, { baseURL: parsedBase }); + if (parsedURL === null) { + return false; + } + return true; + } + get href() { + return usm.serializeURL(this._url); + } + set href(v) { + const parsedURL = usm.basicURLParse(v); + if (parsedURL === null) { + throw new TypeError(`Invalid URL: ${v}`); + } + this._url = parsedURL; + this._query._list.splice(0); + const { query } = parsedURL; + if (query !== null) { + this._query._list = urlencoded.parseUrlencodedString(query); + } + } + get origin() { + return usm.serializeURLOrigin(this._url); + } + get protocol() { + return `${this._url.scheme}:`; + } + set protocol(v) { + usm.basicURLParse(`${v}:`, { url: this._url, stateOverride: "scheme start" }); + } + get username() { + return this._url.username; + } + set username(v) { + if (usm.cannotHaveAUsernamePasswordPort(this._url)) { + return; + } + usm.setTheUsername(this._url, v); + } + get password() { + return this._url.password; + } + set password(v) { + if (usm.cannotHaveAUsernamePasswordPort(this._url)) { + return; + } + usm.setThePassword(this._url, v); + } + get host() { + const url2 = this._url; + if (url2.host === null) { + return ""; + } + if (url2.port === null) { + return usm.serializeHost(url2.host); + } + return `${usm.serializeHost(url2.host)}:${usm.serializeInteger(url2.port)}`; + } + set host(v) { + if (usm.hasAnOpaquePath(this._url)) { + return; + } + usm.basicURLParse(v, { url: this._url, stateOverride: "host" }); + } + get hostname() { + if (this._url.host === null) { + return ""; + } + return usm.serializeHost(this._url.host); + } + set hostname(v) { + if (usm.hasAnOpaquePath(this._url)) { + return; + } + usm.basicURLParse(v, { url: this._url, stateOverride: "hostname" }); + } + get port() { + if (this._url.port === null) { + return ""; + } + return usm.serializeInteger(this._url.port); + } + set port(v) { + if (usm.cannotHaveAUsernamePasswordPort(this._url)) { + return; + } + if (v === "") { + this._url.port = null; + } else { + usm.basicURLParse(v, { url: this._url, stateOverride: "port" }); + } + } + get pathname() { + return usm.serializePath(this._url); + } + set pathname(v) { + if (usm.hasAnOpaquePath(this._url)) { + return; + } + this._url.path = []; + usm.basicURLParse(v, { url: this._url, stateOverride: "path start" }); + } + get search() { + if (this._url.query === null || this._url.query === "") { + return ""; + } + return `?${this._url.query}`; + } + set search(v) { + const url2 = this._url; + if (v === "") { + url2.query = null; + this._query._list = []; + return; + } + const input = v[0] === "?" ? v.substring(1) : v; + url2.query = ""; + usm.basicURLParse(input, { url: url2, stateOverride: "query" }); + this._query._list = urlencoded.parseUrlencodedString(input); + } + get searchParams() { + return this._query; + } + get hash() { + if (this._url.fragment === null || this._url.fragment === "") { + return ""; + } + return `#${this._url.fragment}`; + } + set hash(v) { + if (v === "") { + this._url.fragment = null; + return; + } + const input = v[0] === "#" ? v.substring(1) : v; + this._url.fragment = ""; + usm.basicURLParse(input, { url: this._url, stateOverride: "fragment" }); + } + toJSON() { + return this.href; + } + }; + } +}); + +// node_modules/whatwg-url/lib/URL.js +var require_URL = __commonJS({ + "node_modules/whatwg-url/lib/URL.js"(exports2) { + "use strict"; + var conversions = require_lib(); + var utils = require_utils(); + var implSymbol = utils.implSymbol; + var ctorRegistrySymbol = utils.ctorRegistrySymbol; + var interfaceName = "URL"; + exports2.is = (value) => { + return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; + }; + exports2.isImpl = (value) => { + return utils.isObject(value) && value instanceof Impl.implementation; + }; + exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { + if (exports2.is(value)) { + return utils.implForWrapper(value); + } + throw new globalObject.TypeError(`${context} is not of type 'URL'.`); + }; + function makeWrapper(globalObject, newTarget) { + let proto; + if (newTarget !== void 0) { + proto = newTarget.prototype; + } + if (!utils.isObject(proto)) { + proto = globalObject[ctorRegistrySymbol]["URL"].prototype; + } + return Object.create(proto); + } + exports2.create = (globalObject, constructorArgs, privateData) => { + const wrapper = makeWrapper(globalObject); + return exports2.setup(wrapper, globalObject, constructorArgs, privateData); + }; + exports2.createImpl = (globalObject, constructorArgs, privateData) => { + const wrapper = exports2.create(globalObject, constructorArgs, privateData); + return utils.implForWrapper(wrapper); + }; + exports2._internalSetup = (wrapper, globalObject) => { + }; + exports2.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { + privateData.wrapper = wrapper; + exports2._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: new Impl.implementation(globalObject, constructorArgs, privateData), + configurable: true + }); + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper; + }; + exports2.new = (globalObject, newTarget) => { + const wrapper = makeWrapper(globalObject, newTarget); + exports2._internalSetup(wrapper, globalObject); + Object.defineProperty(wrapper, implSymbol, { + value: Object.create(Impl.implementation.prototype), + configurable: true + }); + wrapper[implSymbol][utils.wrapperSymbol] = wrapper; + if (Impl.init) { + Impl.init(wrapper[implSymbol]); + } + return wrapper[implSymbol]; + }; + var exposed = /* @__PURE__ */ new Set(["Window", "Worker"]); + exports2.install = (globalObject, globalNames) => { + if (!globalNames.some((globalName) => exposed.has(globalName))) { + return; + } + const ctorRegistry = utils.initCtorRegistry(globalObject); + class URL2 { + constructor(url2) { + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to construct 'URL': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to construct 'URL': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== void 0) { + curArg = conversions["USVString"](curArg, { + context: "Failed to construct 'URL': parameter 2", + globals: globalObject + }); + } + args.push(curArg); + } + return exports2.setup(Object.create(new.target.prototype), globalObject, args); + } + toJSON() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'toJSON' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol].toJSON(); + } + get href() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get href' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["href"]; + } + set href(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set href' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'href' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["href"] = V; + } + toString() { + const esValue = this; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'toString' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["href"]; + } + get origin() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get origin' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["origin"]; + } + get protocol() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get protocol' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["protocol"]; + } + set protocol(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set protocol' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'protocol' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["protocol"] = V; + } + get username() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get username' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["username"]; + } + set username(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set username' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'username' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["username"] = V; + } + get password() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get password' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["password"]; + } + set password(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set password' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'password' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["password"] = V; + } + get host() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get host' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["host"]; + } + set host(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set host' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'host' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["host"] = V; + } + get hostname() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get hostname' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["hostname"]; + } + set hostname(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set hostname' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'hostname' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["hostname"] = V; + } + get port() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get port' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["port"]; + } + set port(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set port' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'port' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["port"] = V; + } + get pathname() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get pathname' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["pathname"]; + } + set pathname(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set pathname' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'pathname' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["pathname"] = V; + } + get search() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get search' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["search"]; + } + set search(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set search' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'search' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["search"] = V; + } + get searchParams() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get searchParams' called on an object that is not a valid instance of URL."); + } + return utils.getSameObject(this, "searchParams", () => { + return utils.tryWrapperForImpl(esValue[implSymbol]["searchParams"]); + }); + } + get hash() { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'get hash' called on an object that is not a valid instance of URL."); + } + return esValue[implSymbol]["hash"]; + } + set hash(V) { + const esValue = this !== null && this !== void 0 ? this : globalObject; + if (!exports2.is(esValue)) { + throw new globalObject.TypeError("'set hash' called on an object that is not a valid instance of URL."); + } + V = conversions["USVString"](V, { + context: "Failed to set the 'hash' property on 'URL': The provided value", + globals: globalObject + }); + esValue[implSymbol]["hash"] = V; + } + static parse(url2) { + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'parse' on 'URL': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'parse' on 'URL': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== void 0) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'parse' on 'URL': parameter 2", + globals: globalObject + }); + } + args.push(curArg); + } + return utils.tryWrapperForImpl(Impl.implementation.parse(globalObject, ...args)); + } + static canParse(url2) { + if (arguments.length < 1) { + throw new globalObject.TypeError( + `Failed to execute 'canParse' on 'URL': 1 argument required, but only ${arguments.length} present.` + ); + } + const args = []; + { + let curArg = arguments[0]; + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'canParse' on 'URL': parameter 1", + globals: globalObject + }); + args.push(curArg); + } + { + let curArg = arguments[1]; + if (curArg !== void 0) { + curArg = conversions["USVString"](curArg, { + context: "Failed to execute 'canParse' on 'URL': parameter 2", + globals: globalObject + }); + } + args.push(curArg); + } + return Impl.implementation.canParse(...args); + } + } + Object.defineProperties(URL2.prototype, { + toJSON: { enumerable: true }, + href: { enumerable: true }, + toString: { enumerable: true }, + origin: { enumerable: true }, + protocol: { enumerable: true }, + username: { enumerable: true }, + password: { enumerable: true }, + host: { enumerable: true }, + hostname: { enumerable: true }, + port: { enumerable: true }, + pathname: { enumerable: true }, + search: { enumerable: true }, + searchParams: { enumerable: true }, + hash: { enumerable: true }, + [Symbol.toStringTag]: { value: "URL", configurable: true } + }); + Object.defineProperties(URL2, { parse: { enumerable: true }, canParse: { enumerable: true } }); + ctorRegistry[interfaceName] = URL2; + Object.defineProperty(globalObject, interfaceName, { + configurable: true, + writable: true, + value: URL2 + }); + if (globalNames.includes("Window")) { + Object.defineProperty(globalObject, "webkitURL", { + configurable: true, + writable: true, + value: URL2 + }); + } + }; + var Impl = require_URL_impl(); + } +}); + +// node_modules/whatwg-url/webidl2js-wrapper.js +var require_webidl2js_wrapper = __commonJS({ + "node_modules/whatwg-url/webidl2js-wrapper.js"(exports2) { + "use strict"; + var URL2 = require_URL(); + var URLSearchParams = require_URLSearchParams(); + exports2.URL = URL2; + exports2.URLSearchParams = URLSearchParams; + } +}); + +// node_modules/whatwg-url/index.js +var require_whatwg_url = __commonJS({ + "node_modules/whatwg-url/index.js"(exports2) { + "use strict"; + var { URL: URL2, URLSearchParams } = require_webidl2js_wrapper(); + var urlStateMachine = require_url_state_machine(); + var percentEncoding = require_percent_encoding(); + var sharedGlobalObject = { Array, Object, Promise, String, TypeError }; + URL2.install(sharedGlobalObject, ["Window"]); + URLSearchParams.install(sharedGlobalObject, ["Window"]); + exports2.URL = sharedGlobalObject.URL; + exports2.URLSearchParams = sharedGlobalObject.URLSearchParams; + exports2.parseURL = urlStateMachine.parseURL; + exports2.basicURLParse = urlStateMachine.basicURLParse; + exports2.serializeURL = urlStateMachine.serializeURL; + exports2.serializePath = urlStateMachine.serializePath; + exports2.serializeHost = urlStateMachine.serializeHost; + exports2.serializeInteger = urlStateMachine.serializeInteger; + exports2.serializeURLOrigin = urlStateMachine.serializeURLOrigin; + exports2.setTheUsername = urlStateMachine.setTheUsername; + exports2.setThePassword = urlStateMachine.setThePassword; + exports2.cannotHaveAUsernamePasswordPort = urlStateMachine.cannotHaveAUsernamePasswordPort; + exports2.hasAnOpaquePath = urlStateMachine.hasAnOpaquePath; + exports2.percentDecodeString = percentEncoding.percentDecodeString; + exports2.percentDecodeBytes = percentEncoding.percentDecodeBytes; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/en.json +var en_exports = {}; +__export(en_exports, { + default: () => en_default +}); +var en_default; +var init_en = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/en.json"() { + en_default = { + array: "an array", + boolean: "a boolean", + "bug-of-mc": "Due to a bug of Minecraft (%0%), %1%. Please Mojang, fix your game", + "code-action.block-state-sort-keys": "Sort block state", + "code-action.command-replaceitem": "Update this command to /item \u2026 replace", + "code-action.fix-file": "Fix all auto-fixable problems in this file", + "code-action.fix-workspace": "Fix all auto-fixable problems in the workspace", + "code-action.id-attribute-datafix": "Update this attribute name to 1.16", + "code-action.add-default-namespace": "Add default namespace", + "code-action.add-leading-slash": "Add leading slash", + "code-action.create-undeclared-file": "Create %0% %1% in the same pack", + "code-action.id-omit-default-namespace": "Omit default namespace", + "code-action.id-zombified-piglin-datafix": "Change this ID to Zombified Piglin's", + "code-action.nbt-compound-sort-keys": "Sort NBT compound tag", + "code-action.nbt-type-to-byte": "Convert to an NBT byte tag", + "code-action.nbt-type-to-double": "Convert to an NBT double tag", + "code-action.nbt-type-to-float": "Convert to an NBT float tag", + "code-action.nbt-type-to-int": "Convert to an NBT int tag", + "code-action.nbt-type-to-long": "Convert to an NBT long tag", + "code-action.nbt-type-to-short": "Convert to an NBT short tag", + "code-action.nbt-uuid-datafix": "Update this UUID to 1.16", + "code-action.remove-leading-slash": "Remove leading slash", + "code-action.remove-trailing-separation": "Remove trailing separation", + "code-action.selector-sort-keys": "Sort selector argument", + "code-action.string-double-quote": "Quote this string with double quotation marks", + "code-action.string-single-quote": "Quote this string with single quotation marks", + "code-action.string-unquote": "Unquote this string", + "code-action.vector-align-0.0": "Align this vector to block origin", + "code-action.vector-align-0.5": "Align this vector to block center", + comment: "a comment starting with %0%", + "conjunction.and_2": " and ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", and ", + "conjunction.or_2": " or ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", or ", + "datafix.error.command-replaceitem": "/replaceitem was removed in 20w46a (the second snapshot of 1.17) in favour of /item", + "duplicate-key": "Duplicate key %0%", + "ending-quote": "an ending quote %0%", + entity: "an entity", + "error.unparseable-content": "Encountered unparseable content", + expected: "Expected %0%", + "expected-got": "Expected %0% but got %1%", + float: "a float", + "float.between": "a float between %0% and %1%", + integer: "an integer", + "integer.between": "an integer between %0% and %1%", + "invalid-key-combination": "Invalid combination of keys %0%", + "invalid-regex-pattern": "Invalid regex pattern: %0%", + "mismatching-regex-pattern": "Value does not match regex: %0%", + "java-edition.binder.wrong-folder": "Files in the %0% folder are not recognized in loaded version %1%, did you meant to use the %2% folder?", + "java-edition.binder.wrong-version": "Files in the %0% folder are not recognized in loaded version %1%", + "java-edition.translation-value.percent-escape-hint": "%0%. If you want to display a literal percent sign, use \u201C%%\u201D instead", + "json.doc.advancement.display": "Advancement display settings. If present, the advancement will be visible in the advancement tabs.", + "json.checker.array.length-between": "%0% with length between %1% and %2%", + "json.checker.object.field.union-empty-members": "Disallowed property", + "json.checker.item.duplicate": "Duplicate list item", + "json.checker.property.deprecated": "Property %0% is deprecated", + "json.checker.property.missing": "Missing property %0%", + "json.checker.property.unknown": "Unknown property %0%", + "json.checker.string.hex-color": "a 6-digit hexadecimal number", + "json.checker.tag-entry.duplicate": "Duplicate tag entry", + "json.checker.value": "a value", + "json.node.array": "an array", + "json.node.boolean": "a boolean", + "json.node.null": "a null", + "json.node.number": "a number", + "json.node.object": "an object", + "json.node.string": "a string", + "key-not-following-convention": "Invalid key %0% which doesn't follow %1% convention", + "linter.diagnostic-message-wrapper": "%0% (rule: %1%)", + "linter.name-convention.illegal": "Name %0% doesn't match %1%", + "linter.undeclared-symbol.message": "Cannot find %0% %1%", + "linter-config-validator.name-convention.type": "Expects a string that contains a regular expression describing the name", + "linter-config-validator.wrapper": "%0%. See [the documentation](%1) for more information", + long: "a long", + "long.between": "a long between %0% and %1%", + "mcdoc.binder.dispatcher-statement.duplicated-key": "Duplicated dispatcher case %0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% has already been dispatched here", + "mcdoc.binder.duplicated-declaration": "Duplicated declaration for %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% is already declared here", + "mcdoc.binder.out-of-root": "File %0% is not under the root directory of any mcdoc project; semantic checking will be skipped", + "mcdoc.binder.path.super-from-root": "Cannot access super of the project root", + "mcdoc.binder.path.unknown-identifier": "Identifier %0% does not exist in module %1%", + "mcdoc.binder.path.unknown-module": "Module %0% does not exist", + "mcdoc.checker.entry.empty-mod-seg": "You cannot put \u201Cmod.mcdoc\u201D under a root directly", + "mcdoc.checker.inject-clause.unmatched-injection": "Cannot inject %0% with %1%", + "mcdoc.checker.type-not-assignable": "Type %0% is not assignable to type %1%", + "mcdoc.checker.reference.unexpected-number-of-type-arguments": "Type %0% requires %1% type arguments, but received %2%", + "mcdoc.node.compound-definition": "a compound definition", + "mcdoc.node.enum-definition": "an enum definition", + "mcdoc.node.identifier": "an identifier", + "mcdoc.parser.compound-definition.field-type": "a field type", + "mcdoc.parser.float.illegal": "Encountered illegal float number", + "mcdoc.parser.identifier.reserved-word": "%0% is a reserved word and cannot be used as an identifier name", + "mcdoc.parser.identifier.illegal": "%0% doesn't follow the format of %1%", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "Dynamic indexing is not allowed", + "mcdoc.parser.inject-clause.definition-expected": "Expected either an enum inject or a compound inject", + "mcdoc.parser.keyword.separation": "a separation", + "mcdoc.parser.resource-location.colon-expected": "Expected the colon (%0%) of resource locations", + "mcdoc.parser.syntax.doc-comment-unexpected": "Doc comments are not allowed here; you might want to replace the three slashes with two slashes", + "mcdoc.runtime.checker.key-value-pair": "a key-value pair", + "mcdoc.runtime.checker.range.collection": "collection length to be %0%", + "mcdoc.runtime.checker.range.concat": "%0% and %1%", + "mcdoc.runtime.checker.range.left-exclusive": "above %0%", + "mcdoc.runtime.checker.range.left-inclusive": "at least %0%", + "mcdoc.runtime.checker.range.right-exclusive": "below %0%", + "mcdoc.runtime.checker.range.right-inclusive": "at most %0%", + "mcdoc.runtime.checker.range.number": "numeric value to be %0%", + "mcdoc.runtime.checker.range.string": "string length to be %0%", + "mcdoc.runtime.checker.some-missing-keys": "Missing at least one of the keys %0%", + "mcdoc.runtime.checker.trailing": "Trailing data encountered", + "mcdoc.runtime.checker.value": "a value", + "mcdoc.type.boolean": "a boolean", + "mcdoc.type.byte": "a byte", + "mcdoc.type.short": "a short", + "mcdoc.type.int": "an int", + "mcdoc.type.long": "a long", + "mcdoc.type.float": "a float", + "mcdoc.type.double": "a double", + "mcdoc.type.list": "a list", + "mcdoc.type.byte_array": "a byte array", + "mcdoc.type.int_array": "an int array", + "mcdoc.type.long_array": "a long array", + "mcdoc.type.string": "a string", + "mcdoc.type.struct": "a map-like", + "mcfunction.checker.command.data-modify-unapplicable-operation": "Operation %0% can only be used on %1%; the target path has type %2% instead", + "mcfunction.completer.block.states.default-value": "Default: %0%", + "mcfunction.parser.command-too-long": "Command with length %0% is longer than maximum length %1%", + "mcfunction.parser.duplicate-components": "Duplicate component", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% is not applicable here", + "mcfunction.parser.entity-selector.arguments.unknown": "Unknown entity selector argument %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "The selector contains non-player entities", + "mcfunction.parser.entity-selector.invalid": "Invalid entity selector: \u201C%0%\u201D", + "mcfunction.parser.entity-selector.multiple-disallowed": "The selector contains multiple entities", + "mcfunction.parser.entity-selector.player-name.too-long": "Player names cannot be longer than %0% characters", + "mcfunction.parser.eoc-unexpected": "Expected more arguments", + "mcfunction.parser.leading-slash": "a leading slash \u201C/\u201D", + "mcfunction.parser.leading-slash.unexpected": "Unexpected leading slash \u201C/\u201D", + "mcfunction.parser.macro.at-least-one": "at least one macro argument", + "mcfunction.parser.macro.disallowed": "Macro lines are only supported since 1.20.2", + "mcfunction.parser.macro.illegal-key": "Illegal key character: \u201C%0%\u201D", + "mcfunction.parser.macro.key": "a macro key", + "mcfunction.parser.no-permission": "Permission level %0% is required, which is higher than %1% defined in config", + "mcfunction.parser.objective.too-long": "Objective names cannot be longer than %0% characters", + "mcfunction.parser.range.min>max": "The minimum value %0% is larger than the maximum value %1%", + "mcfunction.parser.range.span-too-large": "The range size %0% is larger than the maximum %1%", + "mcfunction.parser.range.span-too-small": "The range size %0% is smaller than the minimum %1%", + "mcfunction.parser.score_holder.fake-name.too-long": "Fake names cannot be longer than %0% characters", + "mcfunction.parser.sep": "a space (%0%)", + "mcfunction.parser.trailing": "Trailing data encountered: %0%", + "mcfunction.parser.unknown-parser": "Parser %0% hasn't been supported yet", + "mcfunction.parser.uuid.invalid": "Invalid UUID format", + "mcfunction.parser.vector.local-disallowed": "Local coordinates disallowed", + "mcfunction.parser.vector.mixed": "Cannot mix local coordinates and world coordinates together", + "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: `%0%` command](https://minecraft.fandom.com/wiki/Commands/%0%)", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: `%0%` argument parser](https://minecraft.fandom.com/wiki/Argument_types#%0%)", + "missing-key": "Missing key %0%", + "nbt.checker.block-states.fake-boolean": "Boolean block state values should be quoted", + "nbt.checker.block-states.unexpected-value-type": "Block state values should be either a string or an int", + "nbt.checker.block-states.unknown-state": "Unknown block state %0% for the following block(s): %1%", + "nbt.checker.boolean.out-of-range": "A boolean value should be either %0% or %1%", + "nbt.checker.collection.length-between": "%0% with length between %1% and %2%", + "nbt.checker.compound.field.union-empty-members": "Disallowed property", + "nbt.checker.path.index-out-of-bound": "The provided index %0% is out of bound, as the collection can only have at most %1% elements", + "nbt.checker.path.unexpected-filter": "Compound filters can only be used on compound tags", + "nbt.checker.path.unexpected-index": "Indices can only be used on array or list tags", + "nbt.checker.path.unexpected-key": "String keys can only be specified for compound tags", + "nbt.node": "a tag", + "nbt.node.byte": "a byte tag", + "nbt.node.byte_array": "a byte array tag", + "nbt.node.compound": "a compound tag", + "nbt.node.double": "a double tag", + "nbt.node.float": "a float tag", + "nbt.node.int": "an int tag", + "nbt.node.int_array": "an int array tag", + "nbt.node.list": "a list tag", + "nbt.node.long": "a long tag", + "nbt.node.long_array": "a long array tag", + "nbt.node.path.end": "the end of path", + "nbt.node.path.filter": "a compound filter", + "nbt.node.path.index": "an index", + "nbt.node.path.key": "a key", + "nbt.node.short": "a short tag", + "nbt.node.string": "a string tag", + "nbt.path": "an NBT path", + "nbt.parser.number.out-of-range": "This looks like %0%, but it is actually %1% due to the numeral value being out of [%2%, %3%]", + "not-allowed-here": "Value %0% is not allowed here", + "not-divisible-by": "Value %0% is not divisible by %1%", + "not-matching-any-child": "Invalid argument type", + nothing: "nothing", + number: "a number", + "number-range": "a number range", + "number-range.missing-min-and-max": "Expected either a minimum value or a maximum value", + "number.<=": "a number smaller than or equal to %0%", + "number.>=": "a number greater than or equal to %0%", + "number.between": "a number between %0% and %1%", + object: "an object", + objective: "an objective", + "objective-not-following-convention": "Invalid objective %0% which doesn't follow %1% convention", + "parser.float.illegal": "Illegal float numeral that doesn't follow %0%", + "parser.integer.illegal": "Illegal integer that doesn't follow %0%", + "parser.line-continuation-end-of-file": "A line continuation cannot be the end of the file", + "parser.list.value": "a value", + "parser.list.trailing-sep": "Trailing separation", + "parser.long.illegal": "Illegal long numeral that doesn't follow %0%", + "parser.record.key": "a key", + "parser.record.trailing-end": "Trailing separation", + "parser.record.unexpected-char": "Unexpected character %0%", + "parser.record.value": "a value", + "parser.resource-location.illegal": "Illegal character(s): %0%", + "parser.resource-location.namespace-expected": "Namespaces cannot be omitted here", + "parser.resource-location.tag-disallowed": "Tags are not allowed here", + "parser.resource-location.tag-required": "Only tags are allowed here", + "parser.string.illegal-brigadier": "Encountered non-[0-9A-Za-z_.+-] characters in %0%", + "parser.string.illegal-escape": "Unexpected escape character %0%", + "parser.string.illegal-quote": "Only %0% can be used to quote strings here", + "parser.string.illegal-unicode-escape": "Hexadecimal digit expected", + "progress.initializing.title": "Initializing Spyglass\u2026", + "progress.reset-project-cache.title": "Resetting Project Cache\u2026", + "punc.period": ".", + "punc.quote": "\u201C%0%\u201D", + quote: `a quote (\u201C'\u201D or \u201C"\u201D)`, + quote_prefer_double: 'Double quote (\u201C"\u201D) is preferable here', + quote_prefer_single: "Single quote (\u201C'\u201D) is preferable here", + "resource-location": "a resource location", + "score-holder": "a score holder", + "scoreholder-not-following-convention": "Invalid score_holder %0% which doesn't follow %1% convention", + selector: "a selector", + "server.new-version": "The Data-pack Language Server has been updated to a newer version: %0%", + "server.progress.fixing-workspace.begin": "Fixing all auto-fixable problems in the workspace", + "server.progress.fixing-workspace.report": "fixing %0%", + "server.progress.preparing.title": "Preparing Spyglass language features", + "server.remove-cache-file": "The cache file of DHP was moved to a storage location provided by VSCode. You can safely delete the ugly \u201C.datapack\u201D folder in your workspace root.", + "server.show-release-notes": "Show Release Notes", + string: "a string", + tag: "a tag", + "tag-not-following-convention": "Invalid tag %0% which doesn't follow %1% convention", + team: "a team", + "team-not-following-convention": "Invalid team %0% which doesn't follow %1% convention", + "text-component": "a text component", + "time-unit": "a time unit", + "too-many-block-affected": "Too many blocks in the specified area (maximum %0%, specified %1%)", + "too-many-chunk-affected": "Too many chunks in the specified area (maximum %0%, specified %1%)", + "unexpected-character": "Found non [a-z0-9/._-] character(s)", + "unexpected-datapack-tag": "Tags are not allowed here", + "unexpected-default-namespace": "Default namespace should be omitted here", + "unexpected-local-coordinate": "Local coordinate %0% is not allowed", + "unexpected-nbt": "This tag doesn't exist here", + "unexpected-nbt-array-type": "Invalid array type %0%. Should be one of \u201CB\u201D, \u201CI\u201D, and \u201CL\u201D", + "unexpected-nbt-path-filter": "Compound filters are only used for compound tags", + "unexpected-nbt-path-index": "Indices are only used for lists/arrays tags", + "unexpected-nbt-path-key": "Keys are only used for compound tags", + "unexpected-nbt-path-sub": "The current tag doesn't have extra items", + "unexpected-omitted-default-namespace": "Default namespace shouldn't be omitted here", + "unexpected-relative-coordinate": "Relative coordinate %0% is not allowed", + "unexpected-scoreboard-sub-slot": "Only \u201Csidebar\u201D has sub slots", + "unknown-command": "Unknown command %0%", + "unknown-escape": "Unexpected escape character %0%", + "unknown-key": "Unknown key %0%", + "unquoted-string": "an unquoted string", + "unsorted-keys": "Unsorted keys", + uuid: "a UUID", + vector: "a vector" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/de.json +var de_exports = {}; +__export(de_exports, { + default: () => de_default +}); +var de_default; +var init_de = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/de.json"() { + de_default = { + array: "ein Array", + boolean: "einen Wahrheitswert", + "bug-of-mc": "Aufgrund eines Fehlers in Minecraft (%0%), %1%. Bitte beheben, Mojang danke", + "code-action.add-default-namespace": "Standardnamensraum hinzuf\xFCgen", + "code-action.add-leading-slash": "F\xFChrenden Schr\xE4gstrich hinzuf\xFCgen", + "code-action.block-state-sort-keys": "Blockzust\xE4nde sortieren", + "code-action.command-replaceitem": "Aktualisiere diesen Befehl zu /item ... replace", + "code-action.create-undeclared-file": "%0% %1% im selben Paket erstellen", + "code-action.fix-file": "Alle automatisch behebbaren Probleme in dieser Datei beheben", + "code-action.fix-workspace": "Alle automatisch behebbaren Probleme im Arbeitsbereich beheben", + "code-action.id-attribute-datafix": "Den Namen dieses Attributs auf Version 1.16 aktualisieren", + "code-action.id-complete-default-namespace": "Standardnamensraum vervollst\xE4ndigen", + "code-action.id-create-file": "%0% im selben Datenpaket erstellen", + "code-action.id-omit-default-namespace": "Standardnamensraum auslassen", + "code-action.id-zombified-piglin-datafix": "ID zu zombified_piglin \xE4ndern", + "code-action.nbt-compound-sort-keys": "NBT-Compound-Eigenschaften sortieren", + "code-action.nbt-type-to-byte": "In ein NBT-Byte-Tag umwandeln", + "code-action.nbt-type-to-double": "In ein NBT-Double-Tag umwandeln", + "code-action.nbt-type-to-float": "In ein NBT-Float-Tag umwandeln", + "code-action.nbt-type-to-int": "In ein NBT-Int-Tag umwandeln", + "code-action.nbt-type-to-long": "In ein NBT-Long-Tag umwandeln", + "code-action.nbt-type-to-short": "In ein NBT-Short-Tag umwandeln", + "code-action.nbt-uuid-datafix": "Diese UUID auf Version 1.16 aktualisieren", + "code-action.remove-leading-slash": "F\xFChrenden Schr\xE4gstrich entfernen", + "code-action.remove-trailing-separation": "Nachlaufende Trennung entfernen", + "code-action.selector-sort-keys": "Selektor-Argumente sortieren", + "code-action.string-double-quote": "Diese Zeichenkette in doppelte Anf\xFChrungszeichen setzen", + "code-action.string-single-quote": "Diese Zeichenkette in einfache Anf\xFChrungszeichen setzen", + "code-action.string-unquote": "Anf\xFChrungszeichen von dieser Zeichenkette entfernen", + "code-action.vector-align-0.0": "Diesen Vektor am Ursprung des Blocks ausrichten", + "code-action.vector-align-0.5": "Diesen Vektor am Zentrum des Blocks ausrichten", + comment: "ein Kommentar, der mit %0% beginnt", + "conjunction.and_2": " und ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", und ", + "conjunction.or_2": " oder ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", oder ", + "datafix.error.command-replaceitem": "/replaceitem wurde in 20w46a (dem zweiten Snapshot von 1.17) zugunsten von /item entfernt", + "duplicate-key": "Doppelter Schl\xFCssel %0%", + "ending-quote": "ein schlie\xDFendes Anf\xFChrungszeichen %0%", + entity: "eine Entit\xE4t", + "error.unparseable-content": "Nicht analysierbarer Inhalt gefunden", + expected: "%0% erwartet", + "expected-got": "%0% erwartet, aber %1% erhalten", + float: "eine Gleitkommazahl", + "float.between": "eine Gleitkommazahl zwischen %0% und %1%", + integer: "eine Ganzzahl", + "integer.between": "eine Ganzzahl zwischen %0% und %1%", + "invalid-key-combination": "Ung\xFCltige Schl\xFCsselkombination %0%", + "invalid-regex-pattern": "Ung\xFCltiges Regex-Muster: %0%", + "java-edition.binder.wrong-folder": "Dateien im Ordner %0% werden in der geladenen Version %1% nicht erkannt, wollten Sie den Ordner %2% verwenden?", + "java-edition.binder.wrong-version": "Dateien im Ordner %0% werden in der geladenen Version %1% nicht erkannt", + "java-edition.translation-value.percent-escape-hint": "%0%. Wenn Sie ein w\xF6rtliches Prozentzeichen anzeigen m\xF6chten, verwenden Sie stattdessen \u201E%%\u201C", + "json.checker.array.length-between": "%0% mit einer L\xE4nge zwischen %1% und %2%", + "json.checker.item.duplicate": "Gegenstand aus der Liste duplizieren", + "json.checker.object.field.union-empty-members": "Unerlaubte Eigenschaft", + "json.checker.property.deprecated": "Eigenschaft %0% ist veraltet", + "json.checker.property.missing": "Fehlende Eigenschaft %0%", + "json.checker.property.unknown": "Unbekannte Eigenschaft %0%", + "json.checker.string.hex-color": "eine sechstellige Hexadezimalzahl", + "json.checker.tag-entry.duplicate": "Tag-Eintrag duplizieren", + "json.checker.value": "ein Wert", + "json.doc.advancement.display": "Anzeigeeinstellungen f\xFCr Fortschritte. Falls vorhanden, wird der Fortschritt in den Fortschrittsregisterkarten angezeigt.", + "json.node.array": "ein Array", + "json.node.boolean": "ein Wahrheitswert", + "json.node.null": "ein null", + "json.node.number": "eine Zahl", + "json.node.object": "ein Objekt", + "json.node.string": "eine Zeichenkette", + "key-not-following-convention": "Der Schl\xFCssel %0% entspricht nicht der Namenskonvention %1%", + "linter-config-validator.name-convention.type": "Erwartet eine Zeichenkette, die einen Regex-Ausdruck enth\xE4lt, welcher den Bezeichner beschreibt", + "linter-config-validator.wrapper": "%0%. Siehe [die Dokumentation](%1) f\xFCr mehr Informationen", + "linter.diagnostic-message-wrapper": "%0% (Regel: %1%)", + "linter.name-convention.illegal": "Bezeichner %0% passt nicht zu %1%", + "linter.undeclared-symbol.message": "Kann %0% %1% nicht finden", + long: "eine lange Ganzzahl", + "long.between": "ein long zwischen %0% und %1%", + "mcdoc.binder.dispatcher-statement.duplicated-key": "Duplizierter Dispatcher-Fall %0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% wurde bereits hierher versandt", + "mcdoc.binder.duplicated-declaration": "Deklaration von %0% dupliziert", + "mcdoc.binder.duplicated-declaration.related": "%0% ist bereits deklariert", + "mcdoc.binder.out-of-root": "Datei %0% liegt nicht im root-Verzeichnis eines mcdoc-Projektes; Semantische \xDCberpr\xFCfung wird ausgelassen", + "mcdoc.binder.path.super-from-root": "Zugriff auf Superverzeichnis des Projektstamms nicht m\xF6glich", + "mcdoc.binder.path.unknown-identifier": "ID %0% existiert im Modul %1% nicht", + "mcdoc.binder.path.unknown-module": "Modul %0% existiert nicht", + "mcdoc.checker.entry.empty-mod-seg": "Sie k\xF6nnen \u201Emod.mcdoc\u201C nicht direkt unter einem Stammverzeichnis ablegen", + "mcdoc.checker.inject-clause.unmatched-injection": "%0% kann nicht mit %1% injiziert werden", + "mcdoc.checker.reference.unexpected-number-of-type-arguments": "Der Typ %0% erfordert Argumente vom Typ %1%, aber es wurden %2% empfangen", + "mcdoc.checker.type-not-assignable": "Typ %0% kann nicht dem Typ %1% zugewiesen werden", + "mcdoc.node.compound-definition": "eine zusammengesetzte Definition", + "mcdoc.node.enum-definition": "eine Enumerations-Definition", + "mcdoc.node.identifier": "ein Identifizierer", + "mcdoc.parser.compound-definition.field-type": "ein Feldtyp", + "mcdoc.parser.float.illegal": "Ung\xFCltige Flie\xDFkommazahl gefunden", + "mcdoc.parser.identifier.illegal": "%0% entspricht nicht dem Format von %1%", + "mcdoc.parser.identifier.reserved-word": "%0% ist ein reserviertes Wort und kann nicht als Identifizierungsname verwendet werden", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "Dynamische Indizierung ist nicht erlaubt", + "mcdoc.parser.inject-clause.definition-expected": "Erwartet wurde entweder ein Enum-Inject oder ein Compound-Inject", + "mcdoc.parser.keyword.separation": "eine Trennung", + "mcdoc.parser.resource-location.colon-expected": "Erwarteter Doppelpunkt (%0%) der Ressourcenstandorte", + "mcdoc.parser.syntax.doc-comment-unexpected": "Doc-Kommentare sind hier nicht erlaubt; Sie sollten die drei Schr\xE4gstriche durch zwei Schr\xE4gstriche ersetzen", + "mcdoc.runtime.checker.key-value-pair": "ein Schl\xFCssel-Wert-Paar", + "mcdoc.runtime.checker.range.collection": "Kollektionsl\xE4nge soll %0% betragen", + "mcdoc.runtime.checker.range.concat": "%0% und %1%", + "mcdoc.runtime.checker.range.left-exclusive": "\xFCber %0%", + "mcdoc.runtime.checker.range.left-inclusive": "mindestens %0%", + "mcdoc.runtime.checker.range.number": "numerischer Wert soll %0% sein", + "mcdoc.runtime.checker.range.right-exclusive": "unter %0%", + "mcdoc.runtime.checker.range.right-inclusive": "h\xF6chstens %0%", + "mcdoc.runtime.checker.range.string": "Zeichenkettenl\xE4nge soll %0% sein", + "mcdoc.runtime.checker.some-missing-keys": "Mindestens einer der Schl\xFCssel fehlt %0%", + "mcdoc.runtime.checker.trailing": "Nachgestellte Daten gefunden", + "mcdoc.runtime.checker.value": "ein Wert", + "mcdoc.type.boolean": "ein Boolescher Wert", + "mcdoc.type.byte": "ein Byte", + "mcdoc.type.byte_array": "ein Byte-Array", + "mcdoc.type.double": "ein Double", + "mcdoc.type.float": "ein Float", + "mcdoc.type.int": "ein Integer", + "mcdoc.type.int_array": "ein Integer-Array", + "mcdoc.type.list": "eine Liste", + "mcdoc.type.long": "ein Long", + "mcdoc.type.long_array": "ein Long-Array", + "mcdoc.type.short": "ein Short", + "mcdoc.type.string": "ein String", + "mcdoc.type.struct": "eine karten\xE4hnliche", + "mcfunction.checker.command.data-modify-unapplicable-operation": "Operation %0% kann nur auf %1% angewendet werden; Zielpfad hat stattdessen Type %2%", + "mcfunction.completer.block.states.default-value": "Standard: %0%", + "mcfunction.parser.command-too-long": "Befehl mit L\xE4nge %0% ist l\xE4nger als die maximale L\xE4nge %1%", + "mcfunction.parser.duplicate-components": "Doppelte Komponente", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% kann hier nicht angewendet werden", + "mcfunction.parser.entity-selector.arguments.unknown": "Unbekanntes Entit\xE4ts-Auswahl Argument %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "Der Selektor enth\xE4lt Nicht-Spieler-Entit\xE4ten", + "mcfunction.parser.entity-selector.invalid": "Ung\xFCltiger Entit\xE4tsselektor: \u201E%0%\u201C", + "mcfunction.parser.entity-selector.multiple-disallowed": "Der Selektor enth\xE4lt mehrere Entit\xE4ten", + "mcfunction.parser.entity-selector.player-name.too-long": "Spielernamen k\xF6nnen nicht l\xE4nger als %0% Zeichen sein", + "mcfunction.parser.eoc-unexpected": "Mehr Argumente erwartet", + "mcfunction.parser.leading-slash": "einen f\xFChrenden Schr\xE4gstrich \u201E/\u201C", + "mcfunction.parser.leading-slash.unexpected": "Unerwarteter f\xFChrender Schr\xE4gstrich \u201E/\u201C", + "mcfunction.parser.macro.at-least-one": "mindestens ein Makro-Argument", + "mcfunction.parser.macro.disallowed": "Makro-Zeilen werden erst seit Version 1.20.2 unterst\xFCtzt", + "mcfunction.parser.macro.illegal-key": "Unzul\xE4ssiges Schl\xFCsselzeichen: \u201E%0%\u201C", + "mcfunction.parser.macro.key": "eine Makro-Taste", + "mcfunction.parser.no-permission": "Die Berechtigungsstufe %0% ist erforderlich, die h\xF6her ist als die in der Konfiguration definierte Stufe %1%", + "mcfunction.parser.objective.too-long": "Objektivnamen d\xFCrfen nicht l\xE4nger als %0% Zeichen sein", + "mcfunction.parser.range.min>max": "Der Mindestwert %0% ist gr\xF6\xDFer als Maximalwert %1%", + "mcfunction.parser.range.span-too-large": "Der Bereichswert %0% ist gr\xF6\xDFer als der Maximalwert %1%", + "mcfunction.parser.range.span-too-small": "Der Bereichswert %0% ist kleiner als der Mindestwert %1%", + "mcfunction.parser.score_holder.fake-name.too-long": "Fake-Namen d\xFCrfen nicht l\xE4nger als %0% Zeichen sein", + "mcfunction.parser.sep": "ein Leerzeichen (%0%)", + "mcfunction.parser.trailing": "Nachgestellte Daten gefunden: %0%", + "mcfunction.parser.unknown-parser": "Der Parser %0% wird noch nicht unterst\xFCtzt", + "mcfunction.parser.uuid.invalid": "Ung\xFCltiges UUID Format", + "mcfunction.parser.vector.local-disallowed": "Lokale Koordinaten nicht zul\xE4ssig", + "mcfunction.parser.vector.mixed": "Lokale Koordinaten und Weltkoordinaten k\xF6nnen nicht miteinander kombiniert werden", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: Argument-Parser `%0%`](https://minecraft.fandom.com/wiki/Argument_types#%0%)", + "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: Befehl `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", + "mismatching-regex-pattern": "Wert stimmt nicht mit Regex \xFCberein: %0%", + "missing-key": "Fehlender Schl\xFCssel %0%", + "nbt.checker.block-states.fake-boolean": "Boolesche Blockzustandswerte sollten in Anf\xFChrungszeichen gesetzt werden", + "nbt.checker.block-states.unexpected-value-type": "Blockzustandswerte sollten entweder eine Zeichenkette oder eine Ganzzahl sein", + "nbt.checker.block-states.unknown-state": "Unbekannter Blockstatus %0% f\xFCr die folgenden Bl\xF6cke: %1%", + "nbt.checker.boolean.out-of-range": "Ein boolescher Wert sollte entweder %0% oder %1% sein", + "nbt.checker.collection.length-between": "%0% mit L\xE4nge zwischen %1% und %2%", + "nbt.checker.compound.field.union-empty-members": "Unerlaubte Eigenschaft", + "nbt.checker.path.index-out-of-bound": "Der angegebene Index %0% liegt au\xDFerhalb des Bereichs, da die Sammlung h\xF6chstens %1% Elemente enthalten kann", + "nbt.checker.path.unexpected-filter": "Zusammengesetzte Filter k\xF6nnen nur f\xFCr zusammengesetzte Tags verwendet werden", + "nbt.checker.path.unexpected-index": "Indizes k\xF6nnen nur f\xFCr Array- oder Listen-Tags verwendet werden", + "nbt.checker.path.unexpected-key": "String-Schl\xFCssel k\xF6nnen nur f\xFCr zusammengesetzte Tags angegeben werden", + "nbt.node": "ein Tag", + "nbt.node.byte": "ein Byte-Tag", + "nbt.node.byte_array": "ein Byte-Array-Tag", + "nbt.node.compound": "ein zusammengesetztes Tag", + "nbt.node.double": "ein Double-Tag", + "nbt.node.float": "ein Float-Tag", + "nbt.node.int": "ein Integer-Tag", + "nbt.node.int_array": "ein Integer-Array-Tag", + "nbt.node.list": "ein Listen-Tag", + "nbt.node.long": "ein Long-Tag", + "nbt.node.long_array": "ein Long-Array-Tag", + "nbt.node.path.end": "das Ende des Pfades", + "nbt.node.path.filter": "ein zusammengesetzter Filter", + "nbt.node.path.index": "ein Index", + "nbt.node.path.key": "ein Schl\xFCssel", + "nbt.node.short": "ein Short-Tag", + "nbt.node.string": "ein String-Tag", + "nbt.parser.number.out-of-range": "Dies sieht aus wie %0%, ist aber tats\xE4chlich %1%, da der Zahlenwert au\xDFerhalb von [%2%, %3%] liegt", + "nbt.path": "ein NBT-Pfad", + "not-allowed-here": "Der Wert %0% ist hier nicht erlaubt", + "not-divisible-by": "Der Wert %0% ist nicht durch %1% teilbar", + "not-matching-any-child": "Ung\xFCltiger Argumenttyp", + nothing: "nichts", + number: "eine Zahl", + "number-range": "einen Wertebereich", + "number-range.missing-min-and-max": "Minimaler oder maximaler Wert erwartet", + "number.<=": "eine Zahl kleiner oder gleich %0%", + "number.>=": "eine Zahl gr\xF6\xDFer oder gleich %0%", + "number.between": "eine Zahl zwischen %0% und %1%", + object: "ein Objekt", + objective: "ein Ziel", + "objective-not-following-convention": "Ung\xFCltiges Ziel %0%, das nicht der Konvention %1% entspricht", + "parser.float.illegal": "Unzul\xE4ssige Gleitkommazahl, die nicht %0% folgt", + "parser.integer.illegal": "Unzul\xE4ssige Ganzzahl, die nicht %0% folgt", + "parser.line-continuation-end-of-file": "Eine Zeilenfortsetzung darf nicht das Ende der Datei sein", + "parser.list.trailing-sep": "Nachlaufende Trennung", + "parser.list.value": "ein Wert", + "parser.long.illegal": "Unzul\xE4ssige Long Zahl, die nicht %0% folgt", + "parser.record.key": "ein Schl\xFCssel", + "parser.record.trailing-end": "Nachlaufende Trennung", + "parser.record.unexpected-char": "Unerwartetes Zeichen %0%", + "parser.record.value": "ein Wert", + "parser.resource-location.illegal": "Unzul\xE4ssige(s) Zeichen: %0%", + "parser.resource-location.namespace-expected": "Namensr\xE4ume d\xFCrfen hier nicht weggelassen werden", + "parser.resource-location.tag-disallowed": "Tags sind hier nicht erlaubt", + "parser.resource-location.tag-required": "Nur Tags sind hier erlaubt", + "parser.string.illegal-brigadier": "In %0% sind andere Zeichen als [0-9A-Za-z_.+-] aufgetreten", + "parser.string.illegal-escape": "Unerwartetes Escape-Zeichen %0%", + "parser.string.illegal-quote": "Nur %0% kann hier als Anf\xFChrungszeichen f\xFCr Zeichenketten verwendet werden", + "parser.string.illegal-unicode-escape": "Hexadezimalziffer erwartet", + "progress.initializing.title": "Spyglass wird initialisiert\u2026", + "progress.reset-project-cache.title": "Projekt-Cache wird zur\xFCckgesetzt\u2026", + "punc.period": ".", + "punc.quote": "\u201E%0%\u201C", + quote: "ein Anf\xFChrungszeichen (\u201E'\u201C oder \u201E'\u201C)", + quote_prefer_double: 'Doppelte Anf\xFChrungszeichen (\u201E"\u201C) sind hier zu bevorzugen', + quote_prefer_single: "Einfache Anf\xFChrungszeichen (\u201E'\u201C) sind hier zu bevorzugen", + "resource-location": "einen Ressourcenstandort", + "score-holder": "einen Punktehalter", + "scoreholder-not-following-convention": "Ung\xFCltiger Punktehalter %0%, der nicht der Konvention %1% entspricht", + selector: "einen Selektor", + "server.new-version": "Der Datapack Language Server wurde aktualisiert: %0%", + "server.progress.fixing-workspace.begin": "Behebe alle automatisch behebbaren Probleme im Arbeitsbereich", + "server.progress.fixing-workspace.report": "behebe %0%", + "server.progress.preparing.title": "Vorbereiten der Spyglass-Sprachfunktionen", + "server.remove-cache-file": "Der Cache von DHP wurde in ein Verzeichnis von VSCode verschoben. Der \u201E.datapack\u201C-Ordner im Arbeitsbereich kann nun gel\xF6scht werden.", + "server.show-release-notes": "Versionsinformationen anzeigen", + string: "eine Zeichenkette", + tag: "einen Tag", + "tag-not-following-convention": "Ung\xFCltiger Tag %0%, der nicht der Konvention %1% entspricht", + team: "ein Team", + "team-not-following-convention": "Ung\xFCltiges Team %0%, das nicht der Konvention %1% entspricht", + "text-component": "eine Textkomponente", + "time-unit": "eine Zeiteinheit", + "too-many-block-affected": "Zu viele Bl\xF6cke im angegebenen Bereich (maximal %0%, angegeben %1%)", + "too-many-chunk-affected": "Zu viele Chunks im angegebenen Bereich (maximal %0%, angegeben %1%)", + "unexpected-character": "Zeichen gefunden, die nicht [a-z0-9/._-] entsprechen", + "unexpected-datapack-tag": "Aliasse sind hier nicht erlaubt", + "unexpected-default-namespace": "Der Standardnamensraum sollte hier ausgelassen werden", + "unexpected-local-coordinate": "Lokale Koordinate %0% ist nicht erlaubt", + "unexpected-nbt": "Diese Eigenschaft existiert hier nicht", + "unexpected-nbt-array-type": "Ung\xFCltiger Array-Typ %0%. Sollte entweder \u201EB\u201C, \u201EI\u201C oder \u201EL\u201C sein", + "unexpected-nbt-path-filter": "Pfadfilter funktionieren nur mit Compound-Eigenschaften", + "unexpected-nbt-path-index": "Indizes funktionieren nur mit Listen oder Array-Eigenschaften", + "unexpected-nbt-path-key": "Schl\xFCssel funktionieren nur mit Compound-Eigenschaften", + "unexpected-nbt-path-sub": "Die aktuelle Eigenschaft hat keine weiteren Elemente", + "unexpected-omitted-default-namespace": "Der Standardnamensraum kann hier nicht ausgelassen werden", + "unexpected-relative-coordinate": "Die relative Koordinate %0% ist nicht erlaubt", + "unexpected-scoreboard-sub-slot": "Nur \u201Esidebar\u201C hat Unterkategorien", + "unknown-command": "Unbekannter Befehl %0%", + "unknown-escape": "Unerwartetes Escape-Zeichen %0%", + "unknown-key": "Unbekannter Schl\xFCssel %0%", + "unquoted-string": "eine Zeichenkette ohne Anf\xFChrungszeichen", + "unsorted-keys": "Unsortierte Schl\xFCssel", + uuid: "eine UUID", + vector: "einen Vektor" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/es.json +var es_exports = {}; +__export(es_exports, { + default: () => es_default +}); +var es_default; +var init_es = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/es.json"() { + es_default = { + array: "un array", + boolean: "un booleano", + "bug-of-mc": "Debido a un error de Minecraft (%0%), %1%. Por favor Mojang, arreglen su juego", + "code-action.block-state-sort-keys": "Discriminar estado de bloque (block state)", + "code-action.command-replaceitem": "Actualizar este commando a /item ... replace", + "code-action.fix-file": "Arreglar todos los problemas auto-arreglables en este archivo", + "code-action.fix-workspace": "Arreglar todos los problemas auto-arreglables en este espacio de trabajo", + "code-action.id-attribute-datafix": "Actualizar este nombre de atributo a la 1.16", + "code-action.id-complete-default-namespace": "Completar el namespace por defecto", + "code-action.id-create-file": "Crear %0% en el mismo paquete de datos", + "code-action.id-omit-default-namespace": "Omitir namespace por defecto", + "code-action.id-zombified-piglin-datafix": "Cambiar este identificador por el del Piglin Zombificado", + "code-action.nbt-compound-sort-keys": "Discriminar etiqueta compuesta de NBT", + "code-action.nbt-type-to-byte": "Convertir a una etiqueta NBT de octeto (byte)", + "code-action.nbt-type-to-double": "Convertir a una etiqueta NBT de coma flotante doble (double)", + "code-action.nbt-type-to-float": "Convertir a una etiqueta NBT de coma flotante (float)", + "code-action.nbt-type-to-int": "Convertir a una etiqueta NBT de n\xFAmero entero (int)", + "code-action.nbt-type-to-long": "Convertir a una etiqueta NBT de n\xFAmero largo (long)", + "code-action.nbt-type-to-short": "Convertir a una etiqueta NBT de n\xFAmero corto (short)", + "code-action.nbt-uuid-datafix": "Actualizar este Identificador \xDAnico a la 1.16", + "code-action.selector-sort-keys": "Discriminar por argumentos de selector", + "code-action.string-double-quote": 'A\xF1adir comillas dobles (") a esta cadena', + "code-action.string-single-quote": 'A\xF1adir comillas singular (") a esta cadena', + "code-action.string-unquote": "Remover comillas de esta cadena", + "code-action.vector-align-0.0": "Alinear este vector al punto de origen del bloque", + "code-action.vector-align-0.5": "Alinear este vector al centro del bloque", + comment: "un comentario comenzando con %0%", + "conjunction.and_2": " y ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", y ", + "conjunction.or_2": " o ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", o ", + "datafix.error.command-replaceitem": "/replaceitem fue removido en la 20w46a (segunda snapshot de la 1.17) en favor de /item", + "duplicate-key": "Llave duplicada %0%", + "ending-quote": "una comilla cerrando %0%", + entity: "una entidad", + "error.unparseable-content": "Contenido no analizable encontrado", + expected: "Esperado %0%", + "expected-got": "Esperado %0% pero se encontr\xF3 %0%", + float: "un n\xFAmero de coma flotante (float)", + "float.between": "un n\xFAmero de coma flotante (float) entre %0% y %1%", + integer: "un n\xFAmero entero", + "integer.between": "un n\xFAmero entero entre %0% y %1%", + "json.checker.item.duplicate": "Lista de objetos duplicados", + "json.checker.property.deprecated": "Propiedad %0% es obsoleta", + "json.checker.property.missing": "Propiedad %0% faltante", + "json.checker.property.unknown": "Propiedad %0% desconocida", + "json.checker.string.hex-color": "un n\xFAmero hexademical de 6 d\xEDgitos", + "json.checker.tag-entry.duplicate": "Entrada de etiqueta duplicada", + "json.doc.advancement.display": "Configuraci\xF3n de visualizaci\xF3n del avance. Si est\xE1 presenta, el avance ser\xE1 visible en la pesta\xF1a de Progresos.", + "key-not-following-convention": "Llave %0% invalida por no seguir la convenci\xF3n %1%", + "linter-config-validator.name-convention.type": "Espera una cadena que contenga una expresi\xF3n regular describiendo el nombre", + "linter-config-validator.wrapper": "%0%. Vea [la documentaci\xF3n](%1) para m\xE1s informaci\xF3n", + "linter.diagnostic-message-wrapper": "%0% (regla: %1%)", + "linter.name-convention.illegal": "El nombre %0% no coincide con %1%", + "linter.undeclared-symbol.message": "No se pudo encontrar %0% %1%", + long: "un n\xFAmero largo (long)", + "mcdoc.binder.duplicated-declaration": "Declaraci\xF3n duplicada para %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% ya ha sido declarado aqu\xED", + "mcdoc.binder.out-of-root": "El archivo %0% no esta bajo el directorio raiz de ning\xFAn proyecto de mcdoc; se omitir\xE1 el revisado de sem\xE1ntica", + "mcdoc.binder.path.super-from-root": "No se puede acceder a la super de la ra\xEDz del proyecto", + "mcdoc.binder.path.unknown-identifier": "El identificador %0% no existe en el m\xF3dulo %1%", + "mcdoc.binder.path.unknown-module": "El m\xF3dulo %0% no existe", + "mcdoc.checker.entry.empty-mod-seg": "No puedes colocar \u201Cmod.mcdoc\u201D bajo una ra\xEDz directamente", + "mcdoc.checker.inject-clause.unmatched-injection": "No se puede injectar %0% con %1%", + "mcdoc.checker.type-not-assignable": "Tipo %0% no es asignable a tipo %1%", + "mcdoc.node.compound-definition": "una definici\xF3n compuesta", + "mcdoc.node.identifier": "un identificador", + "mcdoc.parser.float.illegal": "Se econtr\xF3 un n\xFAmero de coma flotante (float) ilegal", + "mcdoc.parser.identifier.illegal": "%0% no sigue el formato de %1%", + "mcdoc.parser.identifier.reserved-word": "%0% es una palabra reservada y no puede ser usado como nombre identificador", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "El \xEDndexado din\xE1mico no est\xE1 permitido", + "mcdoc.parser.keyword.separation": "una separaci\xF3n", + "mcfunction.checker.command.data-modify-unapplicable-operation": "Operaci\xF3n %0% s\xF3lo puede ser usada con %1%; el camino del objetivo tiene, en cambio, %2%", + "mcfunction.completer.block.states.default-value": "For defecto: %0%", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% no es aplicable aqu\xED", + "mcfunction.parser.entity-selector.arguments.unknown": "Argumento de selector de entidades desconocido %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "El selector contiene entidades que no son jugadores", + "mcfunction.parser.entity-selector.multiple-disallowed": "El selector contiene multiples entidades", + "mcfunction.parser.entity-selector.player-name.too-long": "Los nombres de jugadores no pueden tener m\xE1s de %0% caracteres", + "mcfunction.parser.eoc-unexpected": "M\xE1s argumentos esperados", + "mcfunction.parser.no-permission": "Se requiere permiso de nivel %0%, el cual es mayor que el definido en configuraci\xF3n: %1%", + "mcfunction.parser.objective.too-long": "Los nombres de los objetivos no pueden tener m\xE1s de %0% caracteres", + "mcfunction.parser.range.min>max": "El valor m\xEDnimo (%0%) es m\xE1s largo que el valor m\xE1ximo (%1%)", + "mcfunction.parser.score_holder.fake-name.too-long": "Nombres falsos no pueden tener m\xE1s de %0% caracteres", + "mcfunction.parser.sep": "un espacio (%0%)", + "mcfunction.parser.unknown-parser": "El analizador %0% a\xFAn no es soportado", + "mcfunction.parser.uuid.invalid": "Formato de Identificador \xDAnico inv\xE1lido", + "mcfunction.parser.vector.local-disallowed": "No est\xE1n permitidas las coordenadas locales", + "mcfunction.parser.vector.mixed": "No se pueden mezclar juntas las coordenadas locales y coordenadas del mundo", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: argumento `%0%` de Brigadier](https://minecraft.fandom.com/wiki/Argument_types#%0%)", + "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: comando `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", + "missing-key": "Llave faltante %0%", + "nbt.checker.block-states.fake-boolean": "Valores de estado de bloque binarios deber\xEDan estar marcados con comillas", + "nbt.checker.block-states.unexpected-value-type": "Los valores de estado de bloque deber\xEDan ser, ya sea, una cadena o un n\xFAmero entero (int)", + "nbt.checker.block-states.unknown-state": "Estado de bloque %0% desconocido para el(los) siguiente(s) bloque(s): %1%", + "nbt.checker.boolean.out-of-range": "Un valor booleano deber\xEDa ser, ya sea, %0% o %1%", + "nbt.checker.collection.length-between": "%0% con una longitud de entre %1% y %2%", + "nbt.checker.compound.field.union-empty-members": "Propiedad no permitida", + "nbt.checker.path.index-out-of-bound": "El \xEDndice proporcionado (%0%) est\xE1 fuera de los l\xEDmites, ya que la colecci\xF3n s\xF3lo puede tener, al menos %1% elementos", + "nbt.checker.path.unexpected-filter": "Los filtros de datos compuestos s\xF3lo pueden ser usados en etiquetas compuestas", + "nbt.checker.path.unexpected-index": "\xCDndices s\xF3lo pueden ser usados en arrays o en listas con etiquetas", + "nbt.checker.path.unexpected-key": "S\xF3lo pueden especificarse llaves de cadena para etiquetas compuestas", + "nbt.node": "una etiqueta", + "nbt.node.byte": "una etiqueta de tipo octeto (byte)", + "nbt.node.byte_array": "una etiqueta de array de tipo octeto (byte)", + "nbt.node.compound": "una etiqueta compuesta", + "nbt.node.double": "una etiqueta de tipo coma flotante doble (double)", + "nbt.node.float": "una etiqueta de coma flotante (float)", + "nbt.node.int": "una etiqueta de n\xFAmero entero (int)", + "nbt.node.int_array": "una etiqueta de array de n\xFAmero entero (int)", + "nbt.node.list": "una etiqueta de lista", + "nbt.node.long": "una etiqueta de n\xFAmero largo (long)", + "nbt.node.long_array": "una etiqueta de array de n\xFAmero largo (long)", + "nbt.node.path.end": "el final del camino", + "nbt.node.path.filter": "un filtro compuesto", + "nbt.node.path.index": "un \xEDndice", + "nbt.node.path.key": "una llave", + "nbt.node.short": "una etiqueta de n\xFAmero corto (short)", + "nbt.node.string": "una etiqueta de cadena", + "nbt.parser.number.out-of-range": "Esto luce similar a %0%, pero de hecho es %1% debido al valor num\xE9rico estando fuera de [%2%, %3%]", + "not-matching-any-child": "Tipo de argumento inv\xE1lido", + nothing: "nada", + number: "un n\xFAmero", + "number-range": "un rango num\xE9rico", + "number-range.missing-min-and-max": "Se esperaba, ya sea, un valor m\xEDnimo o un valor m\xE1ximo", + "number.<=": "un n\xFAmero igual o menor a %0%", + "number.>=": "un n\xFAmero igual o mayor que %0%", + "number.between": "un n\xFAmero entre %0% y %1%", + object: "un objeto", + objective: "un objetivo", + "objective-not-following-convention": "Objetivo %0% inv\xE1lido que no sigue la convenci\xF3n %1%", + "parser.float.illegal": "N\xFAmero de coma flotante (float) illegal por no segu\xEDr %0%", + "parser.integer.illegal": "N\xFAmero entero (int) illegal por no segu\xEDr %0%", + "parser.list.value": "un valor", + "parser.record.key": "una llave", + "parser.record.unexpected-char": "Caracter %0% inesperado", + "parser.string.illegal-brigadier": "Se encontraron caracteres que no entran entre los caracteres permitidos [0-9A-Za-z_.+-] en %0%", + "parser.string.illegal-escape": "Escape de caracter %0% inesperado", + "parser.string.illegal-quote": "Solo %0% pueden ser usados para marcar cardenas aqu\xED", + "parser.string.illegal-unicode-escape": "D\xEDgito hexadecimal esperado", + "punc.period": ".", + "punc.quote": "\u201C%0%\u201D", + quote: `comillas (\u201C'\u201D o \u201C"\u201D)`, + quote_prefer_double: 'Comillas dobles (\u201C"\u201D) son preferidas aqu\xED', + quote_prefer_single: "Comillas singulares (\u201C'\u201D) son preferidas aqu\xED", + "resource-location": "posici\xF3n de recurso", + "score-holder": "una vacante de puntaje", + "scoreholder-not-following-convention": "Vacante de puntaje %0% inv\xE1lida por no seguir la convenci\xF3n %1%", + "server.new-version": "El Servidor del Lenguaje Data-pack ha sido actualizado a una nueva versi\xF3n: %0%", + "server.progress.fixing-workspace.begin": "Reparando todos los errors auto-reparables en el espacio de trabajo", + "server.progress.fixing-workspace.report": "arreglando %0%", + "server.progress.preparing.title": "Preparando funciones del lenguaje Spyglass", + "server.remove-cache-file": "El archivo cach\xE9 de DHP fue movido a una localizaci\xF3n provisionada por VSCode. Ahora puedes remover la fea carpeta \u201C.datapack\u201D en la ra\xEDz de tu espacio de trabajo.", + "server.show-release-notes": "Mostrar Notas de Lanzamientos", + string: "una cadena", + tag: "una etiqueta", + "tag-not-following-convention": "Etiqueta %0% inv\xE1lido" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/fr.json +var fr_exports = {}; +__export(fr_exports, { + default: () => fr_default +}); +var fr_default; +var init_fr = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/fr.json"() { + fr_default = { + array: "un tableau", + boolean: "un bool\xE9en", + "bug-of-mc": "\xC0 cause d'un bug de Minecraft (%0%), %1%. S'il vous pla\xEEt Mojang, corrigez votre jeu", + "code-action.add-default-namespace": "Ajouter un espace de nommage par d\xE9faut", + "code-action.block-state-sort-keys": "Trier les \xE9tats de bloc", + "code-action.command-replaceitem": "Mettre \xE0 jour cette commande sous la forme /item ... replace", + "code-action.create-undeclared-file": "Cr\xE9er %0% %1% dans le m\xEAme pack", + "code-action.fix-file": "Corriger tous les probl\xE8mes auto-corrigibles dans ce fichier", + "code-action.fix-workspace": "Corriger tous les probl\xE8mes auto-corrigibles dans l'espace de travail", + "code-action.id-attribute-datafix": "Mettre \xE0 jour ce nom d'attribut pour la 1.16", + "code-action.id-complete-default-namespace": "Compl\xE9ter l'espace de nommage par d\xE9faut", + "code-action.id-create-file": "Cr\xE9er %0% dans le m\xEAme pack de donn\xE9es", + "code-action.id-omit-default-namespace": "Omettre l'espace de nommage par d\xE9faut", + "code-action.id-zombified-piglin-datafix": "Changer cet ID en celui du Piglin zombifi\xE9", + "code-action.nbt-compound-sort-keys": "Trier les cl\xE9s du compound NBT", + "code-action.nbt-type-to-byte": "Convertir en octet NBT", + "code-action.nbt-type-to-double": "Convertir en double NBT", + "code-action.nbt-type-to-float": "Convertir en un flottant NBT", + "code-action.nbt-type-to-int": "Convertir en entier NBT", + "code-action.nbt-type-to-long": "Convertir en long NBT", + "code-action.nbt-type-to-short": "Convertir en short NBT", + "code-action.nbt-uuid-datafix": "Mettre \xE0 jour cet UUID pour la 1.16", + "code-action.selector-sort-keys": "Trier les arguments du s\xE9lecteur", + "code-action.string-double-quote": "Encadrer cette cha\xEEne de caract\xE8res avec des guillemets", + "code-action.string-single-quote": "Encadrer cette cha\xEEne de caract\xE8res avec des apostrophes", + "code-action.string-unquote": "Enlever les d\xE9limiteurs autour de cette cha\xEEne de caract\xE8res", + "code-action.vector-align-0.0": "Aligner ce vecteur \xE0 l'origine du bloc", + "code-action.vector-align-0.5": "Aligner ce vecteur au centre du bloc", + comment: "un commentaire commen\xE7ant par %0%", + "conjunction.and_2": " et ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", et ", + "conjunction.or_2": " ou ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", ou ", + "datafix.error.command-replaceitem": "/replaceitem a \xE9t\xE9 enlev\xE9 en 20w46a (la deuxi\xE8me snapshot de la 1.17) en faveur de /item", + "duplicate-key": "Cl\xE9 duplique %0%", + "ending-quote": "un guillemet de fermeture %0%", + entity: "une entit\xE9", + "error.unparseable-content": "Rencontr\xE9 du contenu non interpr\xE9table", + expected: "%0% attendu", + "expected-got": "Attendu %0% mais obtenu %1%", + float: "un flottant", + "float.between": "un flottant entre %0% et %1%", + integer: "un integer", + "integer.between": "un integer entre %0% et %1%", + "invalid-key-combination": "Combinaison de touches %0% invalide", + "invalid-regex-pattern": "Motif de regex invalide: %0%", + "java-edition.binder.wrong-folder": "Les fichiers dans le dossier %0% ne sont pas reconnus dans la version charg\xE9e %1%, ne vouliez vous pas plut\xF4t utiliser le dossier %2% ?", + "java-edition.binder.wrong-version": "Les fichiers dans le dossier %0% ne sont pas reconnus dans la version charg\xE9e %1%", + "java-edition.translation-value.percent-escape-hint": "%0%. Si vous voulez afficher un signe pourcent, utilisez \u201C%%\u201D \xE0 la place", + "json.checker.array.length-between": "%0% avec une longueur entre %1% et %2%", + "json.checker.item.duplicate": "Dupliquer la liste d'objets", + "json.checker.object.field.union-empty-members": "Propri\xE9t\xE9 refus\xE9e", + "json.checker.property.deprecated": "La propri\xE9t\xE9 %0% est obsol\xE8te", + "json.checker.property.missing": "Propri\xE9t\xE9 %0% manquante", + "json.checker.property.unknown": "Propri\xE9t\xE9 %0% inconnue", + "json.checker.string.hex-color": "un nombre hexad\xE9cimal \xE0 six chiffres", + "json.checker.tag-entry.duplicate": "Dupliquer la liste de tag", + "json.checker.value": "une valeur", + "json.doc.advancement.display": "Param\xE8tres d'affichages du progr\xE8s. Si pr\xE9sent, le progr\xE8s sera visible dans les onglets de progr\xE8s.", + "json.node.array": "un tableau", + "json.node.boolean": "un bool\xE9en", + "json.node.null": "un null", + "json.node.number": "un nombre", + "json.node.object": "un objet", + "json.node.string": "une cha\xEEne de caract\xE8res", + "key-not-following-convention": "Cl\xE9 invalide %0% qui ne suit pas la convention %1%", + "linter-config-validator.name-convention.type": "Attend un cha\xEEne de caract\xE8res contenant une expression r\xE9guli\xE8re qui d\xE9crit le nom", + "linter-config-validator.wrapper": "%0%. Lisez [la documentation](%1) pour plus d'informations", + "linter.diagnostic-message-wrapper": "%0% (r\xE8gle : %1%)", + "linter.name-convention.illegal": "Le nom %0% ne correspond pas \xE0 %1%", + "linter.undeclared-symbol.message": "N'arrive pas \xE0 trouver %0% %1%", + long: "un long", + "long.between": "un long entre %0% et %1%", + "mcdoc.binder.dispatcher-statement.duplicated-key": "Cas de r\xE9partiteur dupliqu\xE9 %0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% a d\xE9j\xE0 \xE9t\xE9 envoy\xE9 ici", + "mcdoc.binder.duplicated-declaration": "D\xE9claration dupliqu\xE9e pour %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% est d\xE9j\xE0 d\xE9clar\xE9 ici", + "mcdoc.binder.out-of-root": "Le fichier %0% ne se trouve pas dans le r\xE9pertoire racine d'un projet mcdoc ; la v\xE9rification s\xE9mantique sera ignor\xE9e", + "mcdoc.binder.path.super-from-root": "Impossible d'acc\xE9der au super de la racine du projet", + "mcdoc.binder.path.unknown-identifier": "L'identificateur %0% n'existe pas dans le module %1%", + "mcdoc.binder.path.unknown-module": "Le module %0% n'existe pas", + "mcdoc.checker.entry.empty-mod-seg": 'Vous ne pouvez pas mettre "mod.mcdoc" \xE0 la racine', + "mcdoc.checker.inject-clause.unmatched-injection": "Impossible d'injecter %0% avec %1%", + "mcdoc.checker.type-not-assignable": "Le type %0% n'est pas assignable au type %1%", + "mcdoc.node.compound-definition": "une d\xE9finition compos\xE9e", + "mcdoc.node.enum-definition": "une d\xE9finition \xE9num\xE9r\xE9e", + "mcdoc.node.identifier": "un identifiant", + "mcdoc.parser.compound-definition.field-type": "un type de champ", + "mcdoc.parser.float.illegal": "Nombre flottant ill\xE9gal rencontr\xE9", + "mcdoc.parser.identifier.illegal": "%0% ne respecte pas le format de %1%", + "mcdoc.parser.identifier.reserved-word": "%0% est un mot r\xE9serv\xE9 et ne peut \xEAtre utilis\xE9 comme nom d'identifiant", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "L'indexation dynamique n'est pas autoris\xE9e", + "mcdoc.parser.inject-clause.definition-expected": "Attendu soit une injection \xE9num\xE9r\xE9e, soit une injection compos\xE9e", + "mcdoc.parser.keyword.separation": "une s\xE9paration", + "mcdoc.parser.resource-location.colon-expected": "Attendu les deux-points (%0 %) aux emplacements de ressources", + "mcdoc.parser.syntax.doc-comment-unexpected": "Les commentaires de documentation ne sont pas autoris\xE9s ici\xA0; vous devrez peut-\xEAtre remplacer les trois barres obliques par deux barres obliques", + "mcdoc.runtime.checker.key-value-pair": "une paire cl\xE9-valeur", + "mcdoc.runtime.checker.range.concat": "%0% et %1%", + "mcdoc.runtime.checker.range.left-exclusive": "au-dessus de %0%", + "mcdoc.runtime.checker.range.left-inclusive": "au moins %0%", + "mcdoc.runtime.checker.range.right-exclusive": "en-dessous de %0%", + "mcdoc.runtime.checker.range.right-inclusive": "au plus %0%", + "mcdoc.runtime.checker.some-missing-keys": "Il manque au moins une des cl\xE9s %0%", + "mcdoc.runtime.checker.value": "une valeur", + "mcdoc.type.boolean": "un bool\xE9en", + "mcfunction.checker.command.data-modify-unapplicable-operation": "L'op\xE9ration %0% ne peut \xEAtre utilis\xE9 que sur %1%; le chemin cible a \xE0 la place un type %2%", + "mcfunction.completer.block.states.default-value": "D\xE9faut : %0%", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% n'est pas applicable ici", + "mcfunction.parser.entity-selector.arguments.unknown": "Argument de s\xE9lecteur d'entit\xE9 inconnu %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "Le s\xE9lecteur contient des entit\xE9s non joueur", + "mcfunction.parser.entity-selector.multiple-disallowed": "Le s\xE9lecteur contient plusieurs entit\xE9s", + "mcfunction.parser.entity-selector.player-name.too-long": "Les noms de joueurs ne peuvent pas avoir plus de %0% caract\xE8res", + "mcfunction.parser.eoc-unexpected": "Plus d'arguments attendus", + "mcfunction.parser.leading-slash": "une barre oblique \u201C/\u201D", + "mcfunction.parser.leading-slash.unexpected": "Slash \u201C/\u201D inattendu", + "mcfunction.parser.no-permission": "Le niveau de permission %0% est requis, mais le niveau de permission d\xE9fini en configuration est seulement %1%", + "mcfunction.parser.objective.too-long": "Les noms d'objectifs ne peuvent pas avoir plus que %0% caract\xE8res", + "mcfunction.parser.range.min>max": "La valeur minimale %0% est plus grande que la valeur maximale %1%", + "mcfunction.parser.score_holder.fake-name.too-long": "Les faux noms ne peuvent pas avoir plus que %0% caract\xE8res", + "mcfunction.parser.sep": "un espace (%0%)", + "mcfunction.parser.trailing": "Trouv\xE9 des donn\xE9es suppl\xE9mentaires \xE0 la fin", + "mcfunction.parser.unknown-parser": "L'analyseur %0% n'est pas support\xE9 pour le moment", + "mcfunction.parser.uuid.invalid": "Format d'UUID invalide", + "mcfunction.parser.vector.local-disallowed": "Coordonn\xE9es locales interdites", + "mcfunction.parser.vector.mixed": "Les coordonn\xE9es locales et absolues/relatives ne peuvent pas \xEAtre m\xE9lang\xE9es", + "mcfunction.signature-help.command-documentation": "[Wiki Minecraft : commande `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", + "mismatching-regex-pattern": "La valeur ne correspond pas \xE0 la regex: %0%", + "missing-key": "Cl\xE9 %0% manquante", + "nbt.checker.block-states.fake-boolean": "Les \xE9tats de blocs bool\xE9ens doivent \xEAtre mises entre guillemets", + "nbt.checker.block-states.unexpected-value-type": "Les valeurs des \xE9tats de blocs doivent \xEAtre soit une cha\xEEne de caract\xE8res soit un nombre entier", + "nbt.checker.block-states.unknown-state": "\xC9tat de bloc %0% inconnu pour le(s) bloc(s) suivant(s) : %1%", + "nbt.checker.boolean.out-of-range": "Une valeur bool\xE9enne devrait \xEAtre soit %0% soit %1%", + "nbt.checker.collection.length-between": "%0% de longueur comprise entre %1% et %2%", + "nbt.checker.compound.field.union-empty-members": "Propri\xE9t\xE9 interdite", + "nbt.checker.path.index-out-of-bound": "L'indice %0% fourni est hors limite, car la collection ne peut contenir que %1% d'\xE9l\xE9ments maximum", + "nbt.checker.path.unexpected-filter": "Les filtres compos\xE9s ne peuvent \xEAtre utilis\xE9s que sur des \xE9tiquettes compos\xE9es", + "nbt.checker.path.unexpected-index": "Les indices ne peuvent \xEAtre utilis\xE9s que dans des tableaux ou des listes", + "nbt.checker.path.unexpected-key": "Les cl\xE9s de type cha\xEEne ne peuvent \xEAtre sp\xE9cifi\xE9es que pour les \xE9tiquettes compos\xE9es", + "nbt.node": "un tag", + "nbt.node.byte": "un octet", + "nbt.node.byte_array": "un tableau d'octets", + "nbt.node.compound": "un tag compos\xE9", + "nbt.node.double": "un tag de nombre double", + "nbt.node.float": "un tag de nombre flottant", + "nbt.node.int": "un tag de nombre entier", + "nbt.node.int_array": "un tag de liste d'entier", + "nbt.node.list": "un tag de liste", + "nbt.node.long": "un tag d'entier long", + "nbt.node.long_array": "un tag de liste d'entier long", + "nbt.node.path.end": "La fin du chemin", + "nbt.node.path.filter": "un filtre compos\xE9", + "nbt.node.path.index": "un indice", + "nbt.node.path.key": "une cl\xE9", + "nbt.node.short": "une \xE9tiquette courte", + "nbt.node.string": "un tag \xE0 cha\xEEne de caract\xE8res", + "nbt.parser.number.out-of-range": "Cela ressemble \xE0 %0%, mais c'est en fait %1% car la valeur du chiffre est hors de [%2%, %3%]", + "not-matching-any-child": "Type d'argument invalide", + nothing: "rien", + number: "un nombre", + "number-range": "un intervalle de valeur", + "number-range.missing-min-and-max": "Attendu une valeure minimale ou une valeure maximale", + "number.<=": "un nombre inf\xE9rieur ou \xE9gal \xE0 %0%", + "number.>=": "un nombre sup\xE9rieur ou \xE9gal \xE0 %0%", + "number.between": "un nombre entre %0% et %1%", + object: "un objet", + objective: "un objectif", + "objective-not-following-convention": "L'objectif %0% est invalide car elle ne respecte pas la convention %1%", + "parser.float.illegal": "Chiffre flottant ill\xE9gal qui ne suit pas %0%", + "parser.integer.illegal": "Entier ill\xE9gal qui ne suit pas %0%", + "parser.list.trailing-sep": "S\xE9paration \xE0 la fin", + "parser.list.value": "une valeur", + "parser.record.key": "une cl\xE9", + "parser.record.trailing-end": "S\xE9paration \xE0 la fin", + "parser.record.unexpected-char": "Caract\xE8re %0% inattendu", + "parser.record.value": "une valeur", + "parser.resource-location.illegal": "Caract\xE8re(s) inattendu(s) : %0%", + "parser.resource-location.namespace-expected": "Les espaces de noms ne peuvent pas \xEAtre omis ici", + "parser.resource-location.tag-disallowed": "Les tags ne sont pas autoris\xE9s ici", + "parser.string.illegal-brigadier": "Des caract\xE8res autres que [0-9A-Za-z_.+-] ont \xE9t\xE9 rencontr\xE9s dans %0%", + "parser.string.illegal-escape": "Caract\xE8re d'\xE9chappement inattendu %0%", + "parser.string.illegal-quote": "Seuls %0% peuvent \xEAtre utilis\xE9s pour citer des cha\xEEnes de caract\xE8res", + "parser.string.illegal-unicode-escape": "Chiffre hexad\xE9cimal attendu", + "punc.period": ".", + "punc.quote": "\u201C%0%\u201D", + quote: `un guillemet (\u201C"\u201D) ou une apostrophe (\u201C'\u201D)`, + quote_prefer_double: 'Des guillemets (\u201C"\u201D) sont pr\xE9f\xE9rables ici', + quote_prefer_single: "Une apostrophe (\u201C'\u201D) est pr\xE9f\xE9rable ici", + "resource-location": "un emplacement de ressource", + "score-holder": "un score holder", + "scoreholder-not-following-convention": "Le score_holder %0% est invalide car il ne respecte pas la convention %1%", + "server.new-version": "Le Data-pack Language Server a \xE9t\xE9 mis \xE0 jour vers une version plus r\xE9cente : %0%", + "server.progress.fixing-workspace.begin": "Correction de tous les probl\xE8mes auto-corrigibles dans l'espace de travail", + "server.progress.fixing-workspace.report": "correction de %0%", + "server.progress.preparing.title": "Pr\xE9paration des caract\xE9ristiques du langage Spyglass", + "server.remove-cache-file": "Le fichier de cache a \xE9t\xE9 d\xE9plac\xE9 au chemin donn\xE9 par VSCode. Vous pouvez supprimer sans risque le dossier \u201C.datapack\u201D du dossier racine de votre espace de travail.", + "server.show-release-notes": "Afficher les notes de version", + string: "un string", + tag: "un tag", + "tag-not-following-convention": "Le tag %0% est invalide car il ne respecte pas la convention %1%", + team: "une \xE9quipe", + "team-not-following-convention": "L'\xE9quipe %0% est invalide car elle ne respecte pas la convention %1%", + "time-unit": "une unit\xE9 de temps", + "too-many-block-affected": "Trop de blocs dans la zone sp\xE9cifi\xE9e (%0% au maximum, %1% sp\xE9cifi\xE9s)", + "too-many-chunk-affected": "Trop de tron\xE7ons dans la zone sp\xE9cifi\xE9e (maximum %0%, sp\xE9cifi\xE9 %1%)", + "unexpected-character": "Trouv\xE9 un caract\xE8re(s) non-[a-z0-9/._-]", + "unexpected-datapack-tag": "Les tags ne sont pas admis ici", + "unexpected-default-namespace": "L'espace de nommage par d\xE9faut devrait \xEAtre omis ici", + "unexpected-local-coordinate": "La coordonn\xE9e locale %0% n'est pas admise", + "unexpected-nbt": "Ce tag n\u2019existe pas", + "unexpected-nbt-array-type": "Type de tableau invalide %0%. Devrait \xEAtre \u201CB\u201D, \u201CI\u201D, ou \u201CL\u201D", + "unexpected-nbt-path-filter": "Les filtres de champs sont seulement utilis\xE9s pour les tags de champs", + "unexpected-nbt-path-index": "Les indices sont seulement utilis\xE9s pour les tags de listes/tableaux", + "unexpected-nbt-path-key": "Les cl\xE9s sont seulement utilis\xE9es pour les tags de champs", + "unexpected-nbt-path-sub": "Ce tag n'a pas d'items suppl\xE9mentaires", + "unexpected-omitted-default-namespace": "L'espace de nom par d\xE9faut ne peut \xEAtre omis ici", + "unexpected-relative-coordinate": "La coordonn\xE9e relative %0% n'est pas admise", + "unexpected-scoreboard-sub-slot": "Seulement \u201Csidebar\u201D a des sous-emplacements", + "unknown-command": "Commande inconnue %0%", + "unknown-escape": "Caract\xE8re d'\xE9chappement %0% inattendu", + "unknown-key": "Cl\xE9 inconnue %0%", + "unquoted-string": "une cha\xEEne de caract\xE8res sans d\xE9limiteurs", + "unsorted-keys": "Cl\xE9s non tri\xE9es", + uuid: "un UUID", + vector: "un vecteur" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/it.json +var it_exports = {}; +__export(it_exports, { + default: () => it_default +}); +var it_default; +var init_it = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/it.json"() { + it_default = { + array: "un array", + boolean: "un booleano", + "code-action.block-state-sort-keys": "Ordina stato blocco", + "code-action.fix-file": "Aggiusta tutti i problemi auto-aggiustabili in questo file", + "code-action.fix-workspace": "Aggiusta tutti i problemi auto-aggiustabili nel spazio di lavoro", + "code-action.id-attribute-datafix": "Aggiorna il nome di questo attributo a 1.16", + "code-action.id-complete-default-namespace": "Completa il namespace predefinito", + "code-action.id-omit-default-namespace": "Ommetti il namespace predefinito", + "code-action.id-zombified-piglin-datafix": "Cambia questo ID a quello di un Piglin Zombificato", + "code-action.nbt-compound-sort-keys": "Ordina i tag NBT composti", + "code-action.nbt-type-to-byte": "Converti in un tag NBT di byte", + "code-action.nbt-type-to-double": "Converti in un tag NBT double", + "code-action.nbt-type-to-float": "Converti in un tag NBT float", + "code-action.nbt-type-to-int": "Converti in un tag NBT int", + "code-action.nbt-type-to-long": "Converti in un tag NBT long", + "code-action.nbt-type-to-short": "Converti in un tag NBT short", + "code-action.nbt-uuid-datafix": "Aggiorna questo UUID a 1.16", + "code-action.selector-sort-keys": "Ordina gli argomenti di selettore", + "code-action.string-double-quote": "Quota questa stringa con doppie virgolette", + "code-action.string-single-quote": "Quota questa stringa con singole virgolette", + "code-action.string-unquote": "De-quota questa stringa", + "code-action.vector-align-0.0": "Allinea questo vettore all'origine del blocco", + "code-action.vector-align-0.5": "Allinea questo vettore al centro del blocco", + "conjunction.and_2": " e ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", e ", + "conjunction.or_2": " o ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", o ", + "duplicate-key": "Chiave duplicate %0%", + "ending-quote": "quotazione finale %0%", + entity: "un'entit\xE0", + expected: "Previsto %0%", + "expected-got": "Aspettato %0% ma ricevuto %1%", + integer: "un numero intero", + "integer.between": "un numero intero da %0% a %1%", + "key-not-following-convention": "Chiave invalida %0% che non segue il convegno %1%", + long: "un long", + "mcfunction.parser.leading-slash.unexpected": "Barra '/' inaspettata", + "not-matching-any-child": "Fallito a combaciare con qualsiasi figli nell'albero del sintassi del commando", + nothing: "niente", + number: "un numero", + "number-range": "un intervallo di numeri", + "number-range.missing-min-and-max": "Aspettato un valore minimo o massimo", + "number.<=": "un numero meno o uguale a %0%", + "number.>=": "un numero maggiore o uguale a %0%", + "number.between": "un numero da %0% a %1%", + objective: "un oggettivo", + "punc.period": ".", + "punc.quote": "'%0%'", + quote: `una quotazione ('"o"')`, + "score-holder": "un contenitore di punteggio", + "server.new-version": "Il Server di Linguaggio Datapack \xE9 stato aggiornato a una nuova versione: %0%", + "server.remove-cache-file": "Il file del cache di DHP \xE8 stato spostato in un luogo in memoria da VSCose. Ora puoi tranquillamente cancellare il brutto file '.datapack' nel tuo spazio di lavoro.", + "server.show-release-notes": "Mostra appunti di pubblicazione", + string: "uno string", + tag: "un tag", + team: "una squadra", + "time-unit": "un unit\xE0 di tempo", + "too-many-block-affected": "Troppi blocchi nell'area (massimo: %0%, specificati: %1%)", + "unexpected-character": "Trovati caratteri che non sono da a-z, da 0-9 o [/._-]", + "unexpected-datapack-tag": "I tag non sono permessi qui", + "unexpected-default-namespace": "Namespace predefinito dovrebbe essere ommesso qui", + "unexpected-local-coordinate": "La coordinata locale %0% non \xE8 permessa", + "unexpected-nbt": "Questo tag non esiste qui", + "unexpected-nbt-array-type": "Tipo di array invalido %0%. Deve essere un tipo 'B', 'I' o 'L'", + "unexpected-nbt-path-filter": "Filtri composti sono esclusivamente usati per i tag composti", + "unexpected-nbt-path-index": "Gli indici sono solo usati per le liste, gli tag e gli array", + "unexpected-nbt-path-key": "Le chiavi sono solo usati per i tag composti", + "unexpected-nbt-path-sub": "Il tag corrente non ha elementi extra", + "unexpected-omitted-default-namespace": "Il namespace predefinito non pu\xF2 essere omesso qui", + "unexpected-relative-coordinate": "Coordinata %0% non \xE8 permessa", + "unexpected-scoreboard-sub-slot": "Solo il 'sidebar' ha sub-posti", + "unknown-command": "Commando sconosciuto", + "unknown-key": "Chiave sconisciuta", + "unquoted-string": "una stringa non quotata", + "unsorted-keys": "Chiavi non ordinati", + uuid: "un UUID", + vector: "Un vettore" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/ja.json +var ja_exports = {}; +__export(ja_exports, { + default: () => ja_default +}); +var ja_default; +var init_ja = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/ja.json"() { + ja_default = { + array: "\u914D\u5217\u578B", + boolean: "boolean\u578B", + "bug-of-mc": "Minecraft\uFF08%0%\uFF09\u306E\u30D0\u30B0\u306E\u305B\u3044\u3067\u3001%1%\u3002\u3069\u3046\u304BMojang\u3055\u3093\u3001\u30B2\u30FC\u30E0\u3092\u4FEE\u6B63\u3057\u3066\u304F\u3060\u3055\u3044", + "code-action.add-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u8FFD\u52A0", + "code-action.add-leading-slash": "\u5148\u982D\u306B\u30B9\u30E9\u30C3\u30B7\u30E5\u3092\u8FFD\u52A0", + "code-action.block-state-sort-keys": "block state\u3092\u30BD\u30FC\u30C8\u3059\u308B", + "code-action.command-replaceitem": "\u3053\u306E\u30B3\u30DE\u30F3\u30C9\u3092/item ... replace\u306B\u66F4\u65B0\u3057\u307E\u3059", + "code-action.create-undeclared-file": "\u540C\u3058\u30D1\u30C3\u30AF\u5185\u306B %0% \u306E %1% \u3092\u4F5C\u6210\u3059\u308B", + "code-action.fix-file": "\u3053\u306E\u30D5\u30A1\u30A4\u30EB\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", + "code-action.fix-workspace": "\u3053\u306E\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u5185\u306E\u3059\u3079\u3066\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", + "code-action.id-attribute-datafix": "\u3053\u306Eattribute\u306Ename\u30921.16\u306B\u66F4\u65B0\u3059\u308B", + "code-action.id-complete-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u88DC\u5B8C\u3059\u308B", + "code-action.id-create-file": "\u540C\u3058\u30C7\u30FC\u30BF\u30D1\u30C3\u30AF\u5185\u306B%0%\u3092\u4F5C\u6210", + "code-action.id-omit-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u7701\u7565\u3059\u308B", + "code-action.id-zombified-piglin-datafix": "\u3053\u306EID\u3092zombified_piglin\u306B\u5909\u66F4\u3057\u307E\u3059", + "code-action.nbt-compound-sort-keys": "NBT Compound\u30BF\u30B0\u3092\u30BD\u30FC\u30C8\u3059\u308B", + "code-action.nbt-type-to-byte": "byte\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-type-to-double": "double\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-type-to-float": "float\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-type-to-int": "int\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-type-to-long": "long\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-type-to-short": "short\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", + "code-action.nbt-uuid-datafix": "\u3053\u306EUUID\u30921.16\u306B\u66F4\u65B0\u3059\u308B", + "code-action.remove-leading-slash": "\u5148\u982D\u306E\u30B9\u30E9\u30C3\u30B7\u30E5\u3092\u524A\u9664", + "code-action.remove-trailing-separation": "\u672B\u5C3E\u306E\u533A\u5207\u308A\u3092\u524A\u9664\u3059\u308B", + "code-action.selector-sort-keys": "\u30BB\u30EC\u30AF\u30BF\u30FC\u306E\u5F15\u6570\u3092\u30BD\u30FC\u30C8\u3059\u308B", + "code-action.string-double-quote": "\u3053\u306E\u6587\u5B57\u5217\u3092\u4E8C\u91CD\u5F15\u7528\u7B26\u3067\u56F2\u3080", + "code-action.string-single-quote": "\u3053\u306E\u6587\u5B57\u5217\u3092\u4E00\u91CD\u5F15\u7528\u7B26\u3067\u56F2\u3080", + "code-action.string-unquote": "\u3053\u306E\u6587\u5B57\u5217\u306E\u5F15\u7528\u7B26\u3092\u5916\u3059", + "code-action.vector-align-0.0": "\u5EA7\u6A19\u306E\u5024\u3092\u30D6\u30ED\u30C3\u30AF\u306E\u539F\u70B9\u306B\u63C3\u3048\u308B", + "code-action.vector-align-0.5": "\u5EA7\u6A19\u306E\u5024\u3092\u30D6\u30ED\u30C3\u30AF\u306E\u4E2D\u5FC3\u306B\u63C3\u3048\u308B", + comment: "\u30B3\u30E1\u30F3\u30C8\u306F%0%\u3067\u59CB\u307E\u308A\u307E\u3059", + "conjunction.and_2": " \u3068 ", + "conjunction.and_3+_1": "\u3068 ", + "conjunction.and_3+_2": "\u3068 ", + "conjunction.or_2": " \u307E\u305F\u306F ", + "conjunction.or_3+_1": "\u304B ", + "conjunction.or_3+_2": "\u3082\u3057\u304F\u306F ", + "datafix.error.command-replaceitem": "/replaceitem\u306F20w46a (1.17\u306E2\u56DE\u76EE\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8)\u3067\u524A\u9664\u3055\u308C\u3001/item\u306B\u7F6E\u304D\u63DB\u308F\u308A\u307E\u3057\u305F", + "duplicate-key": "\u30AD\u30FC %0% \u306F\u91CD\u8907\u3057\u3066\u307E\u3059", + "ending-quote": "\u6587\u5B57\u5217\u3092\u9589\u3058\u308B\u5F15\u7528\u7B26 %0%", + entity: "\u30A8\u30F3\u30C6\u30A3\u30C6\u30A3", + "error.unparseable-content": "\u89E3\u91C8\u4E0D\u80FD\u306A\u5185\u5BB9\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F", + expected: "%0%\u304C\u5FC5\u8981\u3067\u3059", + "expected-got": "%0%\u304C\u5FC5\u8981\u3067\u3059\u304C%1%\u304C\u78BA\u8A8D\u3055\u308C\u307E\u3057\u305F", + float: "float\u578B", + "float.between": "float\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u3067\u3059", + integer: "int\u578B", + "integer.between": "int\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u306E\u5024\u3067\u3059", + "invalid-key-combination": "%0% \u3068\u3044\u3046\u30AD\u30FC\u306E\u7D44\u307F\u5408\u308F\u305B\u306F\u7121\u52B9\u3067\u3059", + "invalid-regex-pattern": "\u7121\u52B9\u306A\u6B63\u898F\u8868\u73FE\u3067\u3059: %0%", + "java-edition.binder.wrong-folder": "%0% \u30D5\u30A9\u30EB\u30C0\u5185\u306E\u30D5\u30A1\u30A4\u30EB\u306F\u3001\u8AAD\u307F\u8FBC\u307E\u308C\u305F\u30D0\u30FC\u30B8\u30E7\u30F3 %1% \u3067\u306F\u8A8D\u8B58\u3055\u308C\u307E\u305B\u3093\u3002%2% \u30D5\u30A9\u30EB\u30C0\u3092\u4F7F\u7528\u3059\u308B\u3064\u3082\u308A\u3067\u3057\u305F\u304B\uFF1F", + "java-edition.binder.wrong-version": "%0% \u30D5\u30A9\u30EB\u30C0\u5185\u306E\u30D5\u30A1\u30A4\u30EB\u306F\u3001\u8AAD\u307F\u8FBC\u307E\u308C\u305F\u30D0\u30FC\u30B8\u30E7\u30F3 %1% \u3067\u306F\u8A8D\u8B58\u3055\u308C\u307E\u305B\u3093", + "java-edition.translation-value.percent-escape-hint": '%0%\u3002\u30D1\u30FC\u30BB\u30F3\u30C8\u8A18\u53F7\u3092\u8868\u793A\u3057\u305F\u3044\u5834\u5408\u306F\u3001"%%"\u3092\u4F7F\u7528\u3059\u308B', + "json.checker.array.length-between": "%0%\u306E\u8981\u7D20\u6570\u306F%1%\u304B\u3089%2%\u306E\u9593\u307E\u3067\u3067\u3059", + "json.checker.item.duplicate": "\u91CD\u8907\u3057\u305F\u30EA\u30B9\u30C8\u9805\u76EE", + "json.checker.object.field.union-empty-members": "\u8A31\u53EF\u3055\u308C\u3066\u3044\u306A\u3044\u30D7\u30ED\u30D1\u30C6\u30A3\u3067\u3059", + "json.checker.property.deprecated": "\u30D7\u30ED\u30D1\u30C6\u30A3 %0% \u306F\u975E\u63A8\u5968\u3067\u3059", + "json.checker.property.missing": "\u30D7\u30ED\u30D1\u30C6\u30A3 %0% \u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093", + "json.checker.property.unknown": "\u4E0D\u660E\u306A\u30D7\u30ED\u30D1\u30C6\u30A3 %0%", + "json.checker.string.hex-color": "6\u6841\u306E16\u9032\u6570", + "json.checker.tag-entry.duplicate": "\u91CD\u8907\u3057\u305F\u30BF\u30B0\u9805\u76EE", + "json.checker.value": "\u5024", + "json.doc.advancement.display": "\u9032\u6357\u306E\u8868\u793A\u8A2D\u5B9A\u3002\u8A2D\u5B9A\u3057\u305F\u5834\u5408\u3001\u9032\u6357\u30BF\u30D6\u306B\u9032\u6357\u304C\u8868\u793A\u3055\u308C\u308B\u3088\u3046\u306B\u306A\u308B\u3002", + "json.node.array": "\u914D\u5217\u578B", + "json.node.boolean": "boolean\u578B", + "json.node.null": "null\u578B", + "json.node.number": "number\u578B", + "json.node.object": "object\u578B", + "json.node.string": "string\u578B", + "key-not-following-convention": "\u30AD\u30FC%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "linter-config-validator.name-convention.type": "\u540D\u524D\u3092\u8868\u3057\u3001\u6B63\u898F\u8868\u73FE\u3092\u542B\u3080\u6587\u5B57\u5217\u304C\u5FC5\u8981\u3067\u3059", + "linter-config-validator.wrapper": "%0%\u3002\u8A73\u7D30\u306F\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\uFF08%1\uFF09\u3092\u53C2\u7167\u3057\u3066\u304F\u3060\u3055\u3044", + "linter.diagnostic-message-wrapper": "%0%\uFF08\u30EB\u30FC\u30EB: %1%\uFF09", + "linter.name-convention.illegal": "\u540D\u524D %0% \u306F %1% \u3068\u4E00\u81F4\u3057\u307E\u305B\u3093", + "linter.undeclared-symbol.message": "%0% %1% \u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093", + long: "long\u578B", + "long.between": "long\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u3067\u3059", + "mcdoc.binder.dispatcher-statement.duplicated-key": "%0% \u306E\u30C7\u30A3\u30B9\u30D1\u30C3\u30C1\u30E3\u30FC\u30B1\u30FC\u30B9\u304C\u91CD\u8907\u3057\u3066\u3044\u307E\u3059", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% \u306F\u3001\u3059\u3067\u306B\u30C7\u30A3\u30B9\u30D1\u30C3\u30C1\u3055\u308C\u3066\u3044\u307E\u3059", + "mcdoc.binder.duplicated-declaration": "%0% \u306E\u5BA3\u8A00\u304C\u91CD\u8907\u3057\u3066\u3044\u307E\u3059", + "mcdoc.binder.duplicated-declaration.related": "%0% \u306F\u3059\u3067\u306B\u5BA3\u8A00\u3055\u308C\u3066\u3044\u307E\u3059", + "mcdoc.binder.out-of-root": "\u30D5\u30A1\u30A4\u30EB%0%\u306F\u3069\u306Emcdoc\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u30EB\u30FC\u30C8\u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u306B\u3082\u3042\u308A\u307E\u305B\u3093\u3002\u30BB\u30DE\u30F3\u30C6\u30A3\u30C3\u30AF\u30C1\u30A7\u30C3\u30AF\u306F\u30B9\u30AD\u30C3\u30D7\u3055\u308C\u307E\u3059", + "mcdoc.binder.path.super-from-root": "\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u30EB\u30FC\u30C8\u306E super \u306B\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u305B\u3093", + "mcdoc.binder.path.unknown-identifier": "\u8B58\u5225\u5B50 %0% \u306F\u30E2\u30B8\u30E5\u30FC\u30EB %1% \u306B\u5B58\u5728\u3057\u307E\u305B\u3093", + "mcdoc.binder.path.unknown-module": "\u30E2\u30B8\u30E5\u30FC\u30EB %0% \u306F\u5B58\u5728\u3057\u307E\u305B\u3093", + "mcdoc.checker.entry.empty-mod-seg": '"mod.mcdoc" \u30D5\u30A1\u30A4\u30EB\u3092\u30EB\u30FC\u30C8\u76F4\u4E0B\u306B\u7F6E\u304F\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093', + "mcdoc.checker.inject-clause.unmatched-injection": "%0% \u306B %1% \u3092\u5165\u308C\u308B\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093", + "mcdoc.checker.type-not-assignable": "\u578B %0% \u306F\u578B %1% \u306B\u5272\u308A\u5F53\u3066\u3067\u304D\u307E\u305B\u3093", + "mcdoc.node.compound-definition": "\u8907\u5408\u7684\u306A\u5B9A\u7FA9", + "mcdoc.node.enum-definition": "\u5217\u6319\u578B\u306E\u5B9A\u7FA9", + "mcdoc.node.identifier": "\u8B58\u5225\u5B50", + "mcdoc.parser.compound-definition.field-type": "\u30D5\u30A3\u30FC\u30EB\u30C9\u30BF\u30A4\u30D7", + "mcdoc.parser.float.illegal": "\u4E0D\u6B63\u306A\u6D6E\u52D5\u5C0F\u6570\u70B9\u6570\u304C\u691C\u51FA\u3055\u308C\u307E\u3057\u305F", + "mcdoc.parser.identifier.illegal": "%0% \u306F %1% \u306E\u5F62\u5F0F\u306B\u5F93\u3063\u3066\u3044\u307E\u305B\u3093", + "mcdoc.parser.identifier.reserved-word": "%0% \u306F\u4E88\u7D04\u8A9E\u3067\u3042\u308A\u3001\u8B58\u5225\u5B50\u540D\u3068\u3057\u3066\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u52D5\u7684\u30A4\u30F3\u30C7\u30C3\u30AF\u30B9\u306E\u6307\u5B9A\u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093", + "mcdoc.parser.inject-clause.definition-expected": "\u5217\u6319\u578B\u304B\u8907\u5408\u578B\u304C\u5FC5\u8981\u3067\u3059", + "mcdoc.parser.keyword.separation": "\u533A\u5207\u308A", + "mcdoc.parser.resource-location.colon-expected": "\u30EA\u30BD\u30FC\u30B9\u306E\u5834\u6240\u306B\u30B3\u30ED\u30F3\uFF08%0%\uFF09\u304C\u5FC5\u8981\u3067\u3059", + "mcdoc.parser.syntax.doc-comment-unexpected": "\u3053\u3053\u3067\u306F\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\u30B3\u30E1\u30F3\u30C8\u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002\u4E09\u91CD\u30B9\u30E9\u30C3\u30B7\u30E5\uFF08///\uFF09\u3092\u4E8C\u91CD\u30B9\u30E9\u30C3\u30B7\u30E5\uFF08//\uFF09\u306B\u7F6E\u304D\u63DB\u3048\u308B\u3068\u3088\u3044\u3067\u3057\u3087\u3046", + "mcdoc.runtime.checker.key-value-pair": "\u30AD\u30FC\u3068\u5024\u306E\u30DA\u30A2", + "mcdoc.runtime.checker.range.collection": "\u30B3\u30EC\u30AF\u30B7\u30E7\u30F3\u306E\u9577\u3055\u304C %0% \u3067\u3042\u308B\u3053\u3068", + "mcdoc.runtime.checker.range.concat": "%0% \u3068 %1%", + "mcdoc.runtime.checker.range.left-exclusive": "%0% \u3088\u308A\u4E0A", + "mcdoc.runtime.checker.range.left-inclusive": "\u5C11\u306A\u304F\u3068\u3082 %0%", + "mcdoc.runtime.checker.range.number": "\u6570\u5024\u304C %0% \u3067\u3042\u308B\u3053\u3068", + "mcdoc.runtime.checker.range.right-exclusive": "%0% \u672A\u6E80", + "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u5927 %0%", + "mcdoc.runtime.checker.range.string": "\u6587\u5B57\u5217\u306E\u9577\u3055\u304C %0% \u3067\u3042\u308B\u3053\u3068", + "mcdoc.runtime.checker.some-missing-keys": "\u30AD\u30FC %0% \u306E\u3046\u3061\u5C11\u306A\u304F\u3068\u30821\u3064\u304C\u4E0D\u8DB3\u3057\u3066\u3044\u307E\u3059", + "mcdoc.runtime.checker.trailing": "\u672B\u5C3E\u306B\u4F59\u5206\u306A\u30C7\u30FC\u30BF\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F", + "mcdoc.runtime.checker.value": "\u5024", + "mcdoc.type.boolean": "boolean\u578B", + "mcdoc.type.byte": "byte\u578B", + "mcdoc.type.byte_array": "byte\u914D\u5217\u578B", + "mcdoc.type.double": "double\u578B", + "mcdoc.type.float": "float\u578B", + "mcdoc.type.int": "int\u578B", + "mcdoc.type.int_array": "int\u914D\u5217\u578B", + "mcdoc.type.list": "list\u578B", + "mcdoc.type.long": "long\u578B", + "mcdoc.type.long_array": "long\u914D\u5217\u578B", + "mcdoc.type.short": "short\u578B", + "mcdoc.type.string": "string\u578B", + "mcdoc.type.struct": "\u69CB\u9020\u578B", + "mcfunction.parser.entity-selector.arguments.unknown": "%0% \u306F\u4E0D\u660E\u306A\u30BB\u30EC\u30AF\u30BF\u30FC\u5F15\u6570\u3067\u3059", + "mcfunction.parser.entity-selector.entities-disallowed": "\u3053\u306E\u30BB\u30EC\u30AF\u30BF\u30FC\u306F\u30D7\u30EC\u30A4\u30E4\u30FC\u3067\u306A\u3044\u30A8\u30F3\u30C6\u30A3\u30C6\u30A3\u3092\u542B\u307F\u307E\u3059", + "mcfunction.parser.leading-slash.unexpected": "\u201C/\u201D\u306F\u4E0D\u660E\u306A\u5148\u982D\u306E\u6587\u5B57\u3067\u3059", + "mismatching-regex-pattern": "\u5024\u304C\u6B63\u898F\u8868\u73FE\u3068\u4E00\u81F4\u3057\u307E\u305B\u3093: %0%", + "not-matching-any-child": "\u7121\u52B9\u306A\u5F15\u6570\u306E\u578B\u3067\u3059", + nothing: "\u672A\u8A18\u5165\u306E\u72B6\u6CC1", + number: "\u6570\u5024", + "number-range": "\u6570\u5024\u306E\u7BC4\u56F2", + "number-range.missing-min-and-max": "\u5C11\u306A\u304F\u3068\u3082\u6700\u5C0F\u5024\u307E\u305F\u306F\u6700\u5927\u5024\u306E\u3069\u3061\u3089\u304B\u3092\u8A18\u5165\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "number.<=": "%0%\u4EE5\u4E0B\u306E\u6570\u5024", + "number.>=": "%0%\u4EE5\u4E0A\u306E\u6570\u5024", + "number.between": "%0% ~ %1%\u306E\u7BC4\u56F2\u306E\u6570\u5024", + objective: "\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u540D", + "objective-not-following-convention": "\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "punc.period": "\u3002", + "punc.quote": "\u300C%0%\u300D", + quote: `\u5F15\u7528\u7B26 (\u2018'\u2019 \u304B \u2018"\u2019)`, + quote_prefer_double: '\u3053\u3053\u306F\u4E8C\u91CD\u5F15\u7528\u7B26(\u201C"\u201D)\u304C\u6700\u9069\u3067\u3059', + quote_prefer_single: "\u3053\u3053\u306F\u4E00\u91CD\u5F15\u7528\u7B26(\u201C'\u201D)\u304C\u6700\u9069\u3067\u3059", + "score-holder": "\u30B9\u30B3\u30A2\u4FDD\u6301\u8005", + "scoreholder-not-following-convention": "\u30B9\u30B3\u30A2\u4FDD\u6301\u8005%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "server.new-version": "Data-pack Language Server\u304C%0%\u306B\u66F4\u65B0\u3055\u308C\u307E\u3057\u305F", + "server.progress.fixing-workspace.begin": "\u3053\u306E\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u5185\u306E\u3059\u3079\u3066\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", + "server.progress.fixing-workspace.report": "\u6B21\u306E\u30D5\u30A1\u30A4\u30EB\u3092\u4FEE\u6B63\u4E2D: %0%", + "server.remove-cache-file": "DHP\u306E\u30AD\u30E3\u30C3\u30B7\u30E5\u30D5\u30A1\u30A4\u30EB\u306FVSCode\u306E\u63D0\u4F9B\u3059\u308B\u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u79FB\u52D5\u3055\u308C\u307E\u3057\u305F\u3002\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u30EB\u30FC\u30C8\u306E\u201C.datapack\u201D\u30D5\u30A9\u30EB\u30C0\u306F\u5B89\u5168\u306B\u6D88\u53BB\u3059\u308B\u3053\u3068\u304C\u53EF\u80FD\u3067\u3059\u3002", + "server.show-release-notes": "\u30EA\u30EA\u30FC\u30B9\u30CE\u30FC\u30C8\u3092\u898B\u308B", + string: "\u6587\u5B57\u5217", + tag: "tag", + "tag-not-following-convention": "tag%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + team: "\u30C1\u30FC\u30E0", + "team-not-following-convention": "\u30C1\u30FC\u30E0%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "time-unit": "\u6642\u9593\u306E\u5358\u4F4D", + "too-many-block-affected": "\u6307\u5B9A\u3057\u305F\u9818\u57DF\u306B\u3042\u308B\u30D6\u30ED\u30C3\u30AF\u304C\u591A\u3059\u304E\u307E\u3059\uFF08\u6700\u5927 %0%\u3001\u6307\u5B9A %1%\uFF09", + "too-many-chunk-affected": "\u6307\u5B9A\u3057\u305F\u9818\u57DF\u306B\u3042\u308B\u30C1\u30E3\u30F3\u30AF\u304C\u591A\u3059\u304E\u307E\u3059\uFF08\u6700\u5927 %0%\u3001\u6307\u5B9A %1%\uFF09", + "unexpected-character": "[a-z0-9/._-] \u4EE5\u5916\u306E\u6587\u5B57\u304C\u5B58\u5728\u3057\u307E\u3059", + "unexpected-datapack-tag": "\u3053\u3053\u306B\u30BF\u30B0\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", + "unexpected-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u306F\u7701\u7565\u3057\u3066\u304F\u3060\u3055\u3044", + "unexpected-local-coordinate": "\u30ED\u30FC\u30AB\u30EB\u5EA7\u6A19 %0% \u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093", + "unexpected-nbt": "\u3053\u306E\u30BF\u30B0\u306F\u5B58\u5728\u3057\u307E\u305B\u3093", + "unexpected-nbt-array-type": "%0%\u306F\u7121\u52B9\u306A\u914D\u5217\u306E\u578B\u3067\u3059\u3002 \u201CB\u201D, \u201CI\u201D, \u201CL\u201D\u306E\u3069\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", + "unexpected-nbt-path-filter": "Compound\u30D5\u30A3\u30EB\u30BF\u30FC\u306FCompound\u30BF\u30B0\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", + "unexpected-nbt-path-index": "\u30A4\u30F3\u30C7\u30C3\u30AF\u30B9\u306Flist\u30BF\u30B0/\u914D\u5217\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", + "unexpected-nbt-path-key": "\u30AD\u30FC\u306FCompound\u30BF\u30B0\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", + "unexpected-nbt-path-sub": "\u3053\u306E\u30BF\u30B0\u306B\u30B5\u30D6\u30A2\u30A4\u30C6\u30E0\u306F\u5B58\u5728\u3057\u307E\u305B\u3093", + "unexpected-omitted-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u540D\u524D\u7A7A\u9593\u306F\u3053\u3053\u3067\u306F\u7701\u7565\u3067\u304D\u307E\u305B\u3093", + "unexpected-relative-coordinate": "\u76F8\u5BFE\u5EA7\u6A19 %0% \u306F\u3053\u3053\u3067\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", + "unexpected-scoreboard-sub-slot": "\u30B5\u30D6\u30B9\u30ED\u30C3\u30C8\u306F\u201Csidebar\u201D\u3067\u306E\u307F\u4F7F\u7528\u3067\u304D\u307E\u3059", + "unknown-command": "%0%\u306F\u4E0D\u660E\u306A\u30B3\u30DE\u30F3\u30C9\u3067\u3059", + "unknown-key": "%0%\u306F\u4E0D\u660E\u306A\u30AD\u30FC\u3067\u3059", + "unquoted-string": "\u5F15\u7528\u7B26\u3067\u56F2\u307E\u308C\u3066\u3044\u306A\u3044\u6587\u5B57\u5217", + "unsorted-keys": "\u30BD\u30FC\u30C8\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC", + uuid: "UUID", + vector: "\u5EA7\u6A19\u306E\u5024" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/pt-br.json +var pt_br_exports = {}; +__export(pt_br_exports, { + default: () => pt_br_default +}); +var pt_br_default; +var init_pt_br = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/pt-br.json"() { + pt_br_default = { + array: "uma matriz", + boolean: "um boolean", + "bug-of-mc": "Devido a um bug do Minecraft (%0%), %1%. Por favor, Mojang, conserte o seu jogo", + "code-action.block-state-sort-keys": "Classificar estado do bloco", + "code-action.command-replaceitem": "Comando atualizado para /item \u2026 replace", + "code-action.fix-file": "Corrija todos os problemas auto corrig\xEDveis neste arquivo", + "code-action.fix-workspace": "Corrija todos os problemas auto corrig\xEDveis nesta \xE1rea de trabalho", + "code-action.id-attribute-datafix": "Nome de atributo atualizado para a 1.16", + "code-action.id-complete-default-namespace": "Espa\xE7o do nome completo por padr\xE3o", + "code-action.id-create-file": "Criar %0% no mesmo data pack", + "code-action.id-omit-default-namespace": "Omita o espa\xE7o de nome por padr\xE3o", + "code-action.id-zombified-piglin-datafix": "Altere este ID para Piglin Zumbificado", + "code-action.nbt-compound-sort-keys": "Classificar NBT da tag composta", + "code-action.nbt-type-to-byte": "Converter para uma tag de NBT byte", + "code-action.nbt-type-to-double": "Converter para uma tag de NBT double", + "code-action.nbt-type-to-float": "Converter para uma tag de NBT float", + "code-action.nbt-type-to-int": "Converter para uma tag de NBT int", + "code-action.nbt-type-to-long": "Converter para uma tag de NBT long", + "code-action.nbt-type-to-short": "Converter para uma tag de NBT short", + "code-action.nbt-uuid-datafix": "Atualizar este UUID para 1.16", + "code-action.selector-sort-keys": "Classificar argumento do seletor", + "code-action.string-double-quote": "Cite esta string com aspas duplas", + "code-action.string-single-quote": "Cite esta string com aspas simples", + "code-action.string-unquote": "Retire as aspas desta string", + "code-action.vector-align-0.0": "Alinhar este vetor para bloquear a origem", + "code-action.vector-align-0.5": "Alinhar este vetor para bloquear o centro", + comment: "um coment\xE1rio come\xE7ando com %0%", + "conjunction.and_2": " e ", + "conjunction.and_3+_1": ", ", + "conjunction.and_3+_2": ", e ", + "conjunction.or_2": " ou ", + "conjunction.or_3+_1": ", ", + "conjunction.or_3+_2": ", ou ", + "datafix.error.command-replaceitem": "/replaceitem foi removida na 20w46a (a segunda snapshot da 1.17) a favor de /item", + "duplicate-key": "Duplicar chave %0%", + "ending-quote": "uma cita\xE7\xE3o final %0%", + entity: "uma entidade", + "error.unparseable-content": "Conte\xFAdo n\xE3o analis\xE1vel encontrado", + expected: "Esperado %0%", + "expected-got": "Esperado %0% mas obteve %1%", + float: "um float", + "float.between": "um float entre %0% e %1%", + integer: "um inteiro", + "integer.between": "um inteiro entre %0% e %1%", + "json.checker.item.duplicate": "Duplicar lista de itens", + "json.checker.property.deprecated": "A propriedade %0% est\xE1 descontinuada", + "json.checker.property.missing": "Falta da propriedade %0%", + "json.checker.property.unknown": "Propriedade desconhecida %0%", + "json.checker.string.hex-color": "um n\xFAmero hexadecimal de 6-d\xEDgitos", + "json.checker.tag-entry.duplicate": "Duplicar tag de entrada", + "json.doc.advancement.display": "Configura\xE7\xF5es de exibi\xE7\xE3o de progressos. Se estiver presente, o progressos ser\xE1 vis\xEDvel nas guias de progressos.", + "key-not-following-convention": "Chave inv\xE1lida %0% que n\xE3o segue a conven\xE7\xE3o %1%", + "linter-config-validator.name-convention.type": "Espera uma string que cont\xE9m uma express\xE3o regular descrevendo o nome", + "linter-config-validator.wrapper": "%0%. Veja [a documenta\xE7\xE3o](%1) para mais informa\xE7\xF5es", + "linter.diagnostic-message-wrapper": "%0% (regras: %1%)", + "linter.name-convention.illegal": "Nome %0% n\xE3o corresponde %1%", + "linter.undeclared-symbol.message": "N\xE3o consigo encontrar %0% %1%", + long: "uma long", + "mcdoc.binder.dispatcher-statement.duplicated-key": "Caso de despachante duplicado %0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% j\xE1 foi despachado aqui", + "mcdoc.binder.duplicated-declaration": "Declara\xE7\xE3o duplicada para %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% j\xE1 est\xE1 declarado aqui", + "mcdoc.binder.out-of-root": "O arquivo %0% n\xE3o est\xE1 no diret\xF3rio raiz de nenhum projeto mcdoc; a verifica\xE7\xE3o sem\xE2ntica ser\xE1 ignorada", + "mcdoc.binder.path.super-from-root": "N\xE3o \xE9 poss\xEDvel acessar super da raiz do projeto", + "mcdoc.binder.path.unknown-identifier": "O identificador %0% n\xE3o existe no m\xF3dulo %1%", + "mcdoc.binder.path.unknown-module": "M\xF3dulo %0% n\xE3o existe", + "mcdoc.checker.entry.empty-mod-seg": "Voc\xEA n\xE3o pode colocar \u201Cmod.mcdoc\u201D em uma raiz diretamente", + "mcdoc.checker.inject-clause.unmatched-injection": "N\xE3o \xE9 poss\xEDvel injetar %0% com %1%", + "mcdoc.checker.type-not-assignable": "O tipo %0% n\xE3o pode ser atribu\xEDdo ao tipo %1%", + "mcdoc.node.compound-definition": "uma defini\xE7\xE3o composta", + "mcdoc.node.enum-definition": "uma defini\xE7\xE3o de enumera\xE7\xE3o", + "mcdoc.node.identifier": "um identificador", + "mcdoc.parser.compound-definition.field-type": "um tipo de campo", + "mcdoc.parser.float.illegal": "N\xFAmero float ilegal encontrado", + "mcdoc.parser.identifier.illegal": "%0% n\xE3o segue o formato de %1%", + "mcdoc.parser.identifier.reserved-word": "%0% \xE9 uma palavra reservada e n\xE3o pode ser usada como um nome identificador", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "A indexa\xE7\xE3o din\xE2mica n\xE3o \xE9 permitida", + "mcdoc.parser.inject-clause.definition-expected": "Esperado um enum inje\xE7\xE3o ou um compound inje\xE7\xE3o", + "mcdoc.parser.keyword.separation": "uma separa\xE7\xE3o", + "mcdoc.parser.resource-location.colon-expected": "Esperado os dois pontos (%0%) dos locais de recursos", + "mcdoc.parser.syntax.doc-comment-unexpected": "Coment\xE1rios de documentos n\xE3o s\xE3o permitidos aqui; voc\xEA pode querer substituir as tr\xEAs barras por duas barras", + "mcfunction.checker.command.data-modify-unapplicable-operation": "A opera\xE7\xE3o %0% s\xF3 pode ser usada em %1%; o caminho de destino tem o tipo %2% em vez disso", + "mcfunction.completer.block.states.default-value": "Padr\xE3o: %0%", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% n\xE3o \xE9 aplic\xE1vel aqui", + "mcfunction.parser.entity-selector.arguments.unknown": "Argumento do seletor de entidade desconhecido %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "O seletor cont\xE9m entidades n\xE3o-player", + "mcfunction.parser.entity-selector.multiple-disallowed": "O seletor cont\xE9m v\xE1rias entidades", + "mcfunction.parser.entity-selector.player-name.too-long": "Os nomes dos jogadores n\xE3o podem ter mais de %0% caracteres", + "mcfunction.parser.eoc-unexpected": "Esperava-se mais argumentos", + "mcfunction.parser.leading-slash": "uma barra inicial \u201C/\u201D", + "mcfunction.parser.leading-slash.unexpected": "Barra inicial inesperada \u201C/\u201D", + "mcfunction.parser.no-permission": "N\xEDvel de permiss\xE3o %0% \xE9 necess\xE1rio, que \xE9 superior a %1% definido na configura\xE7\xE3o", + "mcfunction.parser.objective.too-long": "Os nomes dos objetivos n\xE3o podem ter mais de %0% caracteres", + "mcfunction.parser.range.min>max": "O valor m\xEDnimo %0% \xE9 maior que o valor m\xE1ximo %1%", + "mcfunction.parser.score_holder.fake-name.too-long": "Nomes falsos n\xE3o podem ter mais de %0% caracteres", + "mcfunction.parser.sep": "um espa\xE7o (%0%)", + "mcfunction.parser.trailing": "Dados finais encontrados", + "mcfunction.parser.unknown-parser": "O analisador %0% ainda n\xE3o foi suportado", + "mcfunction.parser.uuid.invalid": "Formato UUID inv\xE1lido", + "mcfunction.parser.vector.local-disallowed": "Coordenadas locais n\xE3o permitidas", + "mcfunction.parser.vector.mixed": "N\xE3o \xE9 poss\xEDvel misturar coordenadas locais e coordenadas mundiais juntas", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: analisador de argumentos `%0%`](https://minecraft.fandom.com/wiki/Argument_types#%0%)", + "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: comando `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", + "missing-key": "Falta a chave %0%", + "nbt.checker.block-states.fake-boolean": "Os valores do estado do bloco boolean devem ser citados", + "nbt.checker.block-states.unexpected-value-type": "Os valores do estado do bloco devem ser uma string ou um int", + "nbt.checker.block-states.unknown-state": "Estado de bloco desconhecido %0% para o(s) seguinte(s) bloco(s): %1%", + "nbt.checker.boolean.out-of-range": "Um valor boolean deve ser %0% ou %1%", + "nbt.checker.collection.length-between": "%0% com comprimento entre %1% e %2%", + "nbt.checker.compound.field.union-empty-members": "Propriedade proibida", + "nbt.checker.path.index-out-of-bound": "O \xEDndice fornecido %0% est\xE1 fora do limite, pois a cole\xE7\xE3o s\xF3 pode ter no m\xE1ximo %1% elementos", + "nbt.checker.path.unexpected-filter": "Filtros compostos s\xF3 podem ser usados em tags compostas", + "nbt.checker.path.unexpected-index": "Os \xEDndices s\xF3 podem ser usados em array ou lista de tags", + "nbt.checker.path.unexpected-key": "As chaves de string s\xF3 podem ser especificadas para tags compostas", + "nbt.node": "uma tag", + "nbt.node.byte": "uma byte tag", + "nbt.node.byte_array": "uma byte array tag", + "nbt.node.compound": "uma tag composta", + "nbt.node.double": "uma double tag", + "nbt.node.float": "uma float tag", + "nbt.node.int": "uma int tag", + "nbt.node.int_array": "uma int array tag", + "nbt.node.list": "uma lista de tag", + "nbt.node.long": "uma long tag", + "nbt.node.long_array": "uma long array tag", + "nbt.node.path.end": "fim do path", + "nbt.node.path.filter": "um filtro composto", + "nbt.node.path.index": "um \xEDndice", + "nbt.node.path.key": "uma chave", + "nbt.node.short": "uma short tag", + "nbt.node.string": "uma string tag", + "nbt.parser.number.out-of-range": "Parece que %0%, mas na verdade \xE9 %1% devido ao valor numeral estar fora de [%2%, %3%]", + "not-matching-any-child": "Tipo de argumento inv\xE1lido", + nothing: "nada", + number: "um n\xFAmero", + "number-range": "uma gama de n\xFAmeros", + "number-range.missing-min-and-max": "Esperado um valor m\xEDnimo ou um valor m\xE1ximo", + "number.<=": "um n\xFAmero menor ou igual a %0%", + "number.>=": "um n\xFAmero maior ou igual a %0%", + "number.between": "um n\xFAmero entre %0% e %1%", + object: "um objeto", + objective: "um objetivo", + "objective-not-following-convention": "Objetivo inv\xE1lido %0% que n\xE3o segue a conven\xE7\xE3o %1%", + "parser.float.illegal": "Numeral float ilegal que n\xE3o segue %0%", + "parser.integer.illegal": "Inteiro ilegal que n\xE3o segue %0%", + "parser.list.trailing-sep": "Separa\xE7\xE3o final", + "parser.list.value": "um valor", + "parser.record.key": "uma chave", + "parser.record.trailing-end": "Separa\xE7\xE3o final", + "parser.record.unexpected-char": "Caractere inesperado %0%", + "parser.record.value": "um valor", + "parser.resource-location.illegal": "Car\xE1ter(s) ilegal(is): %0%", + "parser.resource-location.namespace-expected": "Espa\xE7oDeNome n\xE3o podem ser omitidos aqui", + "parser.resource-location.tag-disallowed": "Tags n\xE3o s\xE3o permitidas aqui", + "parser.string.illegal-brigadier": "Encontrou n\xE3o-[0-9A-Za-z_.+-] caracteres em %0%", + "parser.string.illegal-escape": "Car\xE1ter de escape inesperado %0%", + "parser.string.illegal-quote": "Apenas %0% pode ser usado para citar strings aqui", + "parser.string.illegal-unicode-escape": "Espera-se um d\xEDgito hexadecimal", + "punc.period": ".", + "punc.quote": "\u201C%0%\u201D", + quote: `uma cita\xE7\xE3o (\u201C'\u201D ou \u201C"\u201D)`, + quote_prefer_double: 'Aspas duplas (\u201C"\u201D) s\xE3o prefer\xEDveis aqui', + quote_prefer_single: "Aspas simples (\u201C'\u201D) s\xE3o prefer\xEDveis aqui", + "resource-location": "um local de recurso", + "score-holder": "um marcador de pontos", + "scoreholder-not-following-convention": "Score_holder %0% inv\xE1lido que n\xE3o segue a conven\xE7\xE3o %1%", + "server.new-version": "O idioma do servidor do Data-pack foi atualizado para uma vers\xE3o mais recente: %0%", + "server.progress.fixing-workspace.begin": "Corrigindo todos os problemas auto corrig\xEDveis na mesa de trabalho", + "server.progress.fixing-workspace.report": "corrigindo %0%", + "server.progress.preparing.title": "Preparando recursos de linguagem do Spyglass", + "server.remove-cache-file": "O arquivo de cache do DHP foi movido para um local de armazenamento fornecido pelo VSCode. Voc\xEA pode excluir com seguran\xE7a a pasta \u201C.datapack\u201D desagrad\xE1vel na raiz do seu espa\xE7o de trabalho.", + "server.show-release-notes": "Mostrar Notas de Lan\xE7amento", + string: "uma string", + tag: "uma tag", + "tag-not-following-convention": "Tag inv\xE1lida %0% que n\xE3o segue a conven\xE7\xE3o %1%", + team: "um equipe", + "team-not-following-convention": "Equipe invalida %0% que n\xE3o segue a conven\xE7\xE3o %1%", + "time-unit": "uma unidade de tempo", + "too-many-block-affected": "Muitos blocos na \xE1rea especificada (m\xE1ximo %0%, especificado %1%)", + "too-many-chunk-affected": "Muitos peda\xE7os na \xE1rea especificada (m\xE1ximo %0%, especificado %1%)", + "unexpected-character": "N\xE3o foram encontrados caracteres [a-z0-9/._-]", + "unexpected-datapack-tag": "Tags n\xE3o s\xE3o permitidas aqui", + "unexpected-default-namespace": "O espa\xE7o-de-nome padr\xE3o deve ser omitido aqui", + "unexpected-local-coordinate": "Coordenada local %0% n\xE3o \xE9 permitida", + "unexpected-nbt": "Esta tag n\xE3o existe aqui", + "unexpected-nbt-array-type": "Tipo de array inv\xE1lida %0%. Deve ser um de \u201CB\u201D, \u201CI\u201D e \u201CL\u201D", + "unexpected-nbt-path-filter": "Filtros compostos s\xE3o usados apenas para tags compostas", + "unexpected-nbt-path-index": "Os \xEDndices s\xE3o usados apenas para listas de tags/arrays tags", + "unexpected-nbt-path-key": "As chaves s\xE3o usadas apenas para tags compostas", + "unexpected-nbt-path-sub": "A tag atual n\xE3o tem itens extras", + "unexpected-omitted-default-namespace": "O espa\xE7o-de-nome padr\xE3o n\xE3o deve ser omitido aqui", + "unexpected-relative-coordinate": "Coordenada relativa %0% n\xE3o \xE9 permitida", + "unexpected-scoreboard-sub-slot": "Apenas a \u201Csidebar\u201D tem sub slots", + "unknown-command": "Comando desconhecido %0%", + "unknown-escape": "Car\xE1ter de escape inesperado %0%", + "unknown-key": "Chave desconhecida %0%", + "unquoted-string": "uma string n\xE3o citada", + "unsorted-keys": "Chaves n\xE3o classificadas", + uuid: "um UUID", + vector: "um vetor" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/zh-cn.json +var zh_cn_exports = {}; +__export(zh_cn_exports, { + default: () => zh_cn_default +}); +var zh_cn_default; +var init_zh_cn = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/zh-cn.json"() { + zh_cn_default = { + array: "\u4E00\u4E2A\u6570\u7EC4", + boolean: "\u4E00\u4E2A\u5E03\u5C14\u503C", + "bug-of-mc": "\u7531\u4E8E\u4E00\u4E2AMinecraft\u7684\u6F0F\u6D1E\uFF08%0%\uFF09\uFF0C%1%\u3002\u8BF7\u62A5\u544AMojang\u4EE5\u4FEE\u590D", + "code-action.add-default-namespace": "\u6DFB\u52A0\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", + "code-action.add-leading-slash": "\u6DFB\u52A0\u524D\u5BFC\u659C\u6760", + "code-action.block-state-sort-keys": "\u5C06\u65B9\u5757\u72B6\u6001\u6309\u952E\u6392\u5E8F", + "code-action.command-replaceitem": "\u5C06\u8BE5\u547D\u4EE4\u5347\u7EA7\u4E3A /item ... replace", + "code-action.create-undeclared-file": "\u5728\u540C\u4E00\u4E2A\u5305\u4E2D\u521B\u5EFA %0% %1%", + "code-action.fix-file": "\u4FEE\u590D\u5F53\u524D\u6587\u4EF6\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", + "code-action.fix-workspace": "\u4FEE\u590D\u5F53\u524D\u5DE5\u4F5C\u7A7A\u95F4\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", + "code-action.id-attribute-datafix": "\u5C06\u8BE5\u5C5E\u6027\u540D\u66F4\u65B0\u5230 1.16", + "code-action.id-complete-default-namespace": "\u8865\u5168\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", + "code-action.id-create-file": "\u5728\u540C\u4E00\u4E2A\u6570\u636E\u5305\u4E2D\u521B\u5EFA%0%", + "code-action.id-omit-default-namespace": "\u7701\u7565\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", + "code-action.id-zombified-piglin-datafix": "\u6539\u4E3A\u50F5\u5C38\u732A\u7075\u7684ID", + "code-action.nbt-compound-sort-keys": "\u5C06 NBT \u590D\u5408\u6807\u7B7E\u6309\u952E\u6392\u5E8F", + "code-action.nbt-type-to-byte": "\u8F6C\u6362\u4E3A NBT \u5B57\u8282\u578B\uFF08byte\uFF09\u6807\u7B7E", + "code-action.nbt-type-to-double": "\u8F6C\u6362\u4E3A NBT \u53CC\u7CBE\u5EA6\u6D6E\u70B9\u6570\uFF08double\uFF09\u6807\u7B7E", + "code-action.nbt-type-to-float": "\u8F6C\u6362\u4E3A NBT \u5355\u7CBE\u5EA6\u6D6E\u70B9\u6570\uFF08float\uFF09\u6807\u7B7E", + "code-action.nbt-type-to-int": "\u8F6C\u6362\u4E3A NBT \u6574\u578B\uFF08int\uFF09\u6807\u7B7E", + "code-action.nbt-type-to-long": "\u8F6C\u6362\u4E3A NBT \u957F\u6574\u578B\uFF08long\uFF09\u6807\u7B7E", + "code-action.nbt-type-to-short": "\u8F6C\u6362\u4E3A NBT \u77ED\u6574\u578B\uFF08short\uFF09\u6807\u7B7E", + "code-action.nbt-uuid-datafix": "\u5C06\u8BE5 UUID \u66F4\u65B0\u5230 1.16", + "code-action.remove-leading-slash": "\u79FB\u9664\u524D\u5BFC\u659C\u6760", + "code-action.remove-trailing-separation": "\u79FB\u9664\u53E5\u5C3E\u5206\u9694\u7B26", + "code-action.selector-sort-keys": "\u5C06\u9009\u62E9\u5668\u53C2\u6570\u6309\u952E\u6392\u5E8F", + "code-action.string-double-quote": "\u4F7F\u7528\u534A\u89D2\u53CC\u5F15\u53F7\u5305\u88F9\u8BE5\u5B57\u7B26\u4E32", + "code-action.string-single-quote": "\u4F7F\u7528\u534A\u89D2\u5355\u5F15\u53F7\u5305\u88F9\u8BE5\u5B57\u7B26\u4E32", + "code-action.string-unquote": "\u79FB\u9664\u8BE5\u5B57\u7B26\u4E32\u7684\u5F15\u53F7", + "code-action.vector-align-0.0": "\u5C06\u8BE5\u5411\u91CF\u5BF9\u9F50\u81F3\u65B9\u5757\u539F\u70B9", + "code-action.vector-align-0.5": "\u5C06\u8BE5\u5411\u91CF\u5BF9\u9F50\u81F3\u65B9\u5757\u4E2D\u5FC3", + comment: "\u4EE5 %0% \u5F00\u59CB\u7684\u6CE8\u91CA", + "conjunction.and_2": " \u548C ", + "conjunction.and_3+_1": "\u3001 ", + "conjunction.and_3+_2": "\u548C ", + "conjunction.or_2": " \u6216 ", + "conjunction.or_3+_1": "\u3001 ", + "conjunction.or_3+_2": "\u6216 ", + "datafix.error.command-replaceitem": "/replaceitem \u5728 20w46a\uFF081.17 \u7684\u7B2C\u4E8C\u4E2A\u5FEB\u7167\uFF09\u4E2D\u88AB /item \u53D6\u4EE3", + "duplicate-key": "\u952E%0%\u91CD\u590D", + "ending-quote": "\u4E00\u4E2A\u7ED3\u5C3E\u5F15\u53F7%0%", + entity: "\u4E00\u4E2A\u5B9E\u4F53", + "error.unparseable-content": "\u9047\u5230\u4E86\u65E0\u6CD5\u89E3\u6790\u7684\u6587\u4EF6\u5185\u5BB9", + expected: "\u671F\u671B%0%", + "expected-got": "\u671F\u671B%0%\uFF0C\u4F46\u5F97\u5230\u4E86%1%", + float: "\u4E00\u4E2A\u6D6E\u70B9\u6570", + "float.between": "\u4E00\u4E2A\u5904\u4E8E %0% \u4E0E %1% \u4E4B\u95F4\u7684\u6D6E\u70B9\u578B\u6570\u5B57", + integer: "\u4E00\u4E2A\u6574\u578B\u6570\u5B57", + "integer.between": "\u4E00\u4E2A\u5904\u4E8E %0% \u4E0E %1% \u4E4B\u95F4\u7684\u6574\u578B\u6570\u5B57", + "invalid-key-combination": "\u952E\u7EC4\u5408 %0% \u65E0\u6548", + "invalid-regex-pattern": "\u65E0\u6548\u7684\u6B63\u5219\u6A21\u5F0F\u4E32\uFF1A%0%", + "java-edition.binder.wrong-folder": "\u5DF2\u52A0\u8F7D\u7684\u7248\u672C %1% \u65E0\u6CD5\u8BC6\u522B %0% \u6587\u4EF6\u5939\u4E2D\u7684\u6587\u4EF6\uFF0C\u4F60\u60F3\u4F7F\u7528\u7684\u662F %2% \u6587\u4EF6\u5939\u5417\uFF1F", + "java-edition.binder.wrong-version": "\u5728\u5DF2\u52A0\u8F7D\u7684\u7248\u672C %1% \u4E2D\u65E0\u6CD5\u8BC6\u522B %0% \u6587\u4EF6\u5939\u4E2D\u7684\u6587\u4EF6", + "java-edition.translation-value.percent-escape-hint": "%0%\u3002\u5982\u679C\u4F60\u60F3\u8981\u663E\u793A\u767E\u5206\u53F7\u7B26\u53F7\uFF0C\u8BF7\u6539\u7528\u201C%%\u201D", + "json.checker.array.length-between": "\u957F\u5EA6\u5728 %1% \u4E0E %2% \u4E4B\u95F4\u7684%0%", + "json.checker.item.duplicate": "\u91CD\u590D\u7684\u5217\u8868\u6761\u76EE", + "json.checker.object.field.union-empty-members": "\u7981\u7528\u5C5E\u6027", + "json.checker.property.deprecated": "\u5C5E\u6027 %0% \u5DF2\u88AB\u5F03\u7528", + "json.checker.property.missing": "\u7F3A\u5931\u5C5E\u6027 %0%", + "json.checker.property.unknown": "\u672A\u77E5\u5C5E\u6027 %0%", + "json.checker.string.hex-color": "\u4E00\u4E2A6\u4F4D\u7684\u5341\u516D\u8FDB\u5236\u6570\u5B57", + "json.checker.tag-entry.duplicate": "\u91CD\u590D\u7684\u6807\u7B7E\u6761\u76EE", + "json.checker.value": "\u4E00\u4E2A\u503C", + "json.doc.advancement.display": "\u8FDB\u5EA6\u7684\u663E\u793A\u8BBE\u7F6E\u3002\u5982\u679C\u5B58\u5728\uFF0C\u5219\u8BE5\u8FDB\u5EA6\u5C06\u5728\u8FDB\u5EA6\u9009\u9879\u5361\u4E2D\u53EF\u89C1\u3002", + "json.node.array": "\u4E00\u4E2A\u6570\u7EC4", + "json.node.boolean": "\u4E00\u4E2A\u5E03\u5C14\u503C", + "json.node.null": "\u4E00\u4E2A\u7A7A\u503C", + "json.node.number": "\u4E00\u4E2A\u6570\u5B57", + "json.node.object": "\u4E00\u4E2A\u5BF9\u8C61", + "json.node.string": "\u4E00\u4E2A\u5B57\u7B26\u4E32", + "key-not-following-convention": "\u65E0\u6548\u7684\u952E%0%\uFF0C\u56E0\u4E3A\u6CA1\u6709\u9075\u5FAA%1%\u547D\u540D\u89C4\u8303", + "linter-config-validator.name-convention.type": "\u671F\u671B\u4E00\u4E2A\u6B63\u5219\u8868\u8FBE\u5F0F\u5B57\u7B26\u4E32\u7528\u4E8E\u63CF\u8FF0\u547D\u540D\u89C4\u8303", + "linter-config-validator.wrapper": "%0%\u3002\u8BF7\u53C2\u9605[\u6587\u6863](%1)\u83B7\u53D6\u66F4\u591A\u4FE1\u606F", + "linter.diagnostic-message-wrapper": "%0%\uFF08\u89C4\u5219\uFF1A%1%\uFF09", + "linter.name-convention.illegal": "\u540D\u79F0 %0% \u4E0D\u5339\u914D\u914D\u7F6E\u7684\u6B63\u5219\u8868\u8FBE\u5F0F %1%", + "linter.undeclared-symbol.message": "\u627E\u4E0D\u5230%0%%1%", + long: "\u4E00\u4E2A\u957F\u6574\u578B\u6570\u5B57", + "long.between": "\u5728%0%\u548C%1%\u4E4B\u95F4\u7684\u957F\u6574\u578B", + "mcdoc.binder.dispatcher-statement.duplicated-key": "\u91CD\u590D\u7684\u8C03\u5EA6\u5668 %0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% \u5DF2\u7ECF\u88AB\u8C03\u5EA6\u5230\u4E86\u8FD9\u91CC", + "mcdoc.binder.duplicated-declaration": "\u91CD\u590D\u58F0\u660E %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% \u5DF2\u5728\u8FD9\u91CC\u88AB\u58F0\u660E\u8FC7\u4E86", + "mcdoc.binder.out-of-root": "\u6587\u4EF6 %0% \u4E0D\u5728\u4EFB\u4F55 mcdoc \u9879\u76EE\u7684\u6839\u76EE\u5F55\u4E0B\uFF0C\u56E0\u6B64\u5C06\u8DF3\u8FC7\u8BED\u4E49\u68C0\u6D4B", + "mcdoc.binder.path.super-from-root": "\u65E0\u6CD5\u8BBF\u95EE\u9879\u76EE\u6839\u76EE\u5F55\u7684\u4E0A\u4E00\u7EA7\u76EE\u5F55\uFF08`super`\uFF09", + "mcdoc.binder.path.unknown-identifier": "\u6A21\u5757 %1% \u4E2D\u4E0D\u5B58\u5728\u6807\u8BC6\u7B26 %0%", + "mcdoc.binder.path.unknown-module": "\u6A21\u5757 %0% \u4E0D\u5B58\u5728", + "mcdoc.checker.entry.empty-mod-seg": "\u4F60\u4E0D\u80FD\u5C06\u201Cmod.mcdoc\u201D\u76F4\u63A5\u653E\u5728\u6839\u76EE\u5F55\u4E0B", + "mcdoc.checker.inject-clause.unmatched-injection": "\u4E0D\u80FD\u6CE8\u5165 %0% \u4EE5 %1%", + "mcdoc.checker.type-not-assignable": "\u7C7B\u578B %0% \u4E0D\u80FD\u5206\u914D\u7ED9\u7C7B\u578B %1%", + "mcdoc.node.compound-definition": "\u4E00\u4E2A\u590D\u5408\u5B9A\u4E49", + "mcdoc.node.enum-definition": "\u4E00\u4E2A\u679A\u4E3E\u5B9A\u4E49", + "mcdoc.node.identifier": "\u4E00\u4E2A\u6807\u8BC6\u7B26", + "mcdoc.parser.compound-definition.field-type": "\u4E00\u4E2A\u5B57\u6BB5\u7C7B\u578B", + "mcdoc.parser.float.illegal": "\u9047\u5230\u4E86\u65E0\u6548\u7684\u6D6E\u70B9\u6570", + "mcdoc.parser.identifier.illegal": "%0% \u4E0D\u9075\u5FAA\u683C\u5F0F %1%", + "mcdoc.parser.identifier.reserved-word": "%0% \u662F\u4FDD\u7559\u5B57\uFF0C\u65E0\u6CD5\u88AB\u7528\u4F5C\u6807\u8BC6\u7B26", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u4E0D\u5141\u8BB8\u52A8\u6001\u7D22\u5F15", + "mcdoc.parser.inject-clause.definition-expected": "\u671F\u671B\u4E00\u4E2A\u679A\u4E3E\u6CE8\u5165\u6216\u590D\u5408\u6CE8\u5165", + "mcdoc.parser.keyword.separation": "\u4E00\u4E2A\u5206\u9694\u7B26", + "mcdoc.parser.resource-location.colon-expected": "\u671F\u671B\u8D44\u6E90\u8DEF\u5F84\u4E2D\u7684\u5192\u53F7\uFF08%0%\uFF09", + "mcdoc.parser.syntax.doc-comment-unexpected": "\u6B64\u5904\u4E0D\u5141\u8BB8\u6587\u6863\u6CE8\u91CA\uFF1B\u4F60\u53EF\u80FD\u60F3\u5C06\u4E09\u4E2A\u659C\u6760\u66FF\u6362\u4E3A\u4E24\u4E2A\u659C\u6760", + "mcdoc.runtime.checker.key-value-pair": "\u4E00\u4E2A\u952E\u503C\u5BF9", + "mcdoc.runtime.checker.range.collection": "\u96C6\u5408\u957F\u5EA6\u5E94\u4E3A%0%", + "mcdoc.runtime.checker.range.concat": "%0%\u548C%1%", + "mcdoc.runtime.checker.range.left-exclusive": "\u5728%0%\u4EE5\u4E0A", + "mcdoc.runtime.checker.range.left-inclusive": "\u81F3\u5C11\u4E3A%0%", + "mcdoc.runtime.checker.range.number": "\u5E94\u4E3A\u6570\u503C%0%", + "mcdoc.runtime.checker.range.right-exclusive": "\u5728%0%\u4EE5\u4E0B", + "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u5927\u4E3A%0%", + "mcdoc.runtime.checker.range.string": "\u5B57\u7B26\u4E32\u957F\u5EA6\u5E94\u4E3A%0%", + "mcdoc.runtime.checker.some-missing-keys": "\u81F3\u5C11\u9700\u8981 %0% \u4E2D\u7684\u4E00\u4E2A\u952E", + "mcdoc.runtime.checker.trailing": "\u7A81\u9047\u53E5\u5C3E\u6570\u636E", + "mcfunction.checker.command.data-modify-unapplicable-operation": "\u4E0D\u80FD\u5728 %1% \u4E0A\u4F7F\u7528 %0% \u64CD\u4F5C\uFF1B\u76EE\u6807\u8DEF\u5F84\u7684\u7C7B\u578B\u4E3A %2%", + "mcfunction.completer.block.states.default-value": "\u9ED8\u8BA4\u503C\uFF1A%0%", + "mcfunction.parser.command-too-long": "\u547D\u4EE4\u957F\u5EA6\u4E3A %0% \uFF0C\u4E0D\u5141\u8BB8\u8D85\u8FC7\u5176\u957F\u5EA6\u4E0A\u9650 %1%", + "mcfunction.parser.duplicate-components": "\u7EC4\u4EF6\u91CD\u590D", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% \u4E0D\u9002\u7528\u4E8E\u6B64\u5904", + "mcfunction.parser.entity-selector.arguments.unknown": "\u672A\u77E5\u7684\u5B9E\u4F53\u9009\u62E9\u5668\u53C2\u6570 %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "\u8BE5\u9009\u62E9\u5668\u5305\u542B\u975E\u73A9\u5BB6\u5B9E\u4F53", + "mcfunction.parser.entity-selector.invalid": "\u65E0\u6548\u7684\u9009\u62E9\u5668\uFF1A\u201C%0%\u201D", + "mcfunction.parser.entity-selector.multiple-disallowed": "\u8BE5\u9009\u62E9\u5668\u5305\u542B\u591A\u4E2A\u5B9E\u4F53", + "mcfunction.parser.entity-selector.player-name.too-long": "\u73A9\u5BB6\u540D\u79F0\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", + "mcfunction.parser.eoc-unexpected": "\u671F\u671B\u66F4\u591A\u53C2\u6570", + "mcfunction.parser.leading-slash": "\u4E00\u4E2A\u524D\u5BFC\u659C\u6760 \u201C/\u201D", + "mcfunction.parser.leading-slash.unexpected": "\u4E0D\u80FD\u4EE5\u659C\u6760\u201C/\u201D\u5F00\u5934", + "mcfunction.parser.macro.at-least-one": "\u5E94\u81F3\u5C11\u5305\u542B\u4E00\u4E2A\u5B8F\u53C2\u6570", + "mcfunction.parser.macro.disallowed": "\u5B8F\u884C\u4EC5\u53D71.20.2\u4E4B\u540E\u7684\u7248\u672C\u652F\u6301", + "mcfunction.parser.macro.illegal-key": "\u952E\u5B57\u7B26\u8BED\u6CD5\u9519\u8BEF\uFF1A\u201C%0%\u201D", + "mcfunction.parser.macro.key": "\u4E00\u4E2A\u5B8F\u952E", + "mcfunction.parser.no-permission": "\u9700\u8981\u6743\u9650\u7B49\u7EA7 %0%\uFF0C\u9AD8\u4E8E\u8BBE\u7F6E\u4E2D\u5B9A\u4E49\u7684 %1%", + "mcfunction.parser.objective.too-long": "\u8BB0\u5206\u9879\u540D\u79F0\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", + "mcfunction.parser.range.min>max": "\u6700\u5C0F\u503C %0% \u5927\u4E8E\u6700\u5927\u503C %1%", + "mcfunction.parser.range.span-too-large": "\u8303\u56F4 %0% \u6BD4\u6700\u5927\u503C %1% \u8FD8\u5927", + "mcfunction.parser.range.span-too-small": "\u8303\u56F4 %0% \u6BD4\u6700\u5C0F\u503C %1% \u8FD8\u5C0F", + "mcfunction.parser.score_holder.fake-name.too-long": "\u5B9E\u4F53\u5047\u540D\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", + "mcfunction.parser.sep": "\u4E00\u4E2A\u7A7A\u683C (%0%)", + "mcfunction.parser.trailing": "\u9047\u5230\u5C3E\u968F\u7684\u6570\u636E\uFF1A%0%", + "mcfunction.parser.unknown-parser": "\u5C1A\u672A\u652F\u6301\u89E3\u6790\u5668 %0%", + "mcfunction.parser.uuid.invalid": "\u65E0\u6548\u7684UUID\u683C\u5F0F", + "mcfunction.parser.vector.local-disallowed": "\u5C40\u90E8\u5750\u6807\u4E0D\u5141\u8BB8\u5728\u6B64\u5904\u4F7F\u7528", + "mcfunction.parser.vector.mixed": "\u4E0D\u80FD\u5C06\u5C40\u90E8\u5750\u6807\u4E0E\u4E16\u754C\u5750\u6807\u6DF7\u5408\u4F7F\u7528", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki\uFF1A`%0%` \u53C2\u6570\u89E3\u6790\u5668](https://minecraft.fandom.com/zh/wiki/\u53C2\u6570\u7C7B\u578B#%0%)", + "mcfunction.signature-help.command-documentation": "[Minecraft Wiki\uFF1A`%0%` \u547D\u4EE4](https://minecraft.fandom.com/zh/wiki/Commands/%0%)", + "mismatching-regex-pattern": "\u503C\u65E0\u6CD5\u5339\u914D\u6B63\u5219\u8868\u8FBE\u5F0F\uFF1A%0%", + "missing-key": "\u7F3A\u5931\u952E %0%", + "nbt.checker.block-states.fake-boolean": "\u5E94\u7528\u5F15\u53F7\u5305\u88F9\u5E03\u5C14\u578B\u65B9\u5757\u72B6\u6001\u503C", + "nbt.checker.block-states.unexpected-value-type": "\u65B9\u5757\u72B6\u6001\u503C\u5E94\u4E3A\u5B57\u7B26\u4E32\u6216\u6574\u6570", + "nbt.checker.block-states.unknown-state": "\u4EE5\u4E0B\u65B9\u5757\u5177\u6709\u672A\u77E5\u65B9\u5757\u72B6\u6001 %0% \uFF1A%1%", + "nbt.checker.boolean.out-of-range": "\u5E03\u5C14\u503C\u5E94\u4E3A %0% \u6216 %1%", + "nbt.checker.collection.length-between": "%0% \u7684\u957F\u5EA6\u5728 %1% \u548C %2% \u4E4B\u95F4", + "nbt.checker.compound.field.union-empty-members": "\u4E0D\u5141\u8BB8\u7684\u5C5E\u6027", + "nbt.checker.path.index-out-of-bound": "\u63D0\u4F9B\u7684\u7D22\u5F15 %0% \u8D8A\u754C\uFF0C\u56E0\u4E3A\u96C6\u5408\u6700\u591A\u53EA\u80FD\u62E5\u6709 %1% \u4E2A\u5143\u7D20", + "nbt.checker.path.unexpected-filter": "\u590D\u5408\u6807\u7B7E\u8FC7\u6EE4\u5668\u53EA\u80FD\u7528\u4E8E\u590D\u5408\u6807\u7B7E", + "nbt.checker.path.unexpected-index": "\u7D22\u5F15\u53EA\u80FD\u7528\u4E8E\u6570\u7EC4\u6216\u5217\u8868\u6807\u7B7E", + "nbt.checker.path.unexpected-key": "\u5B57\u7B26\u4E32\u952E\u53EA\u80FD\u4E3A\u590D\u5408\u6807\u7B7E\u6307\u5B9A", + "nbt.node": "\u4E00\u4E2A\u6807\u7B7E", + "nbt.node.byte": "\u4E00\u4E2A\u5B57\u8282\u6807\u7B7E", + "nbt.node.byte_array": "\u4E00\u4E2A\u5B57\u8282\u6570\u7EC4\u6807\u7B7E", + "nbt.node.compound": "\u4E00\u4E2A\u590D\u5408\u6807\u7B7E", + "nbt.node.double": "\u4E00\u4E2A\u53CC\u7CBE\u5EA6\u6D6E\u70B9\u578B\u6807\u7B7E", + "nbt.node.float": "\u4E00\u4E2A\u6D6E\u70B9\u578B\u6807\u7B7E", + "nbt.node.int": "\u4E00\u4E2A\u6574\u578B\u6807\u7B7E", + "nbt.node.int_array": "\u4E00\u4E2A\u6574\u578B\u6570\u7EC4\u6807\u7B7E", + "nbt.node.list": "\u4E00\u4E2A\u5217\u8868\u6807\u7B7E", + "nbt.node.long": "\u4E00\u4E2A\u957F\u6574\u578B\u6807\u7B7E", + "nbt.node.long_array": "\u4E00\u4E2A\u957F\u6574\u578B\u6570\u7EC4\u6807\u7B7E", + "nbt.node.path.end": "\u8DEF\u5F84\u7ED3\u5C3E", + "nbt.node.path.filter": "\u4E00\u4E2A\u590D\u5408\u6807\u7B7E\u8FC7\u6EE4\u5668", + "nbt.node.path.index": "\u4E00\u4E2A\u7D22\u5F15", + "nbt.node.path.key": "\u4E00\u4E2A\u952E", + "nbt.node.short": "\u4E00\u4E2A\u77ED\u6574\u578B\u6807\u7B7E", + "nbt.node.string": "\u4E00\u4E2A\u5B57\u7B26\u4E32\u6807\u7B7E", + "nbt.parser.number.out-of-range": "\u8FD9\u770B\u8D77\u6765\u50CF %0%\uFF0C\u4F46\u5B9E\u9645\u4E0A\u662F %1%\uFF0C\u7531\u4E8E\u6570\u503C\u8D85\u51FA\u4E86 [%2%, %3%]", + "nbt.path": "\u4E00\u4E2ANBT\u8DEF\u5F84", + "not-allowed-here": "\u503C %0% \u4E0D\u5141\u8BB8\u5728\u8FD9\u91CC\u51FA\u73B0", + "not-divisible-by": "\u503C %0% \u4E0D\u80FD\u88AB %1% \u6574\u9664", + "not-matching-any-child": "\u65E0\u6548\u53C2\u6570", + nothing: "\u65E0", + number: "\u4E00\u4E2A\u6570\u5B57", + "number-range": "\u4E00\u4E2A\u6570\u5B57\u8303\u56F4", + "number-range.missing-min-and-max": "\u671F\u671B\u4E00\u4E2A\u6700\u5C0F\u503C\u6216\u4E00\u4E2A\u6700\u5927\u503C", + "number.<=": "\u4E00\u4E2A\u5C0F\u4E8E\u7B49\u4E8E %0% \u7684\u6570\u5B57", + "number.>=": "\u4E00\u4E2A\u5927\u4E8E\u7B49\u4E8E %0% \u7684\u6570\u5B57", + "number.between": "\u4E00\u4E2A\u4F4D\u4E8E %0% \u548C %1% \u4E4B\u95F4\u7684\u6570\u5B57", + object: "\u4E00\u4E2A\u5BF9\u8C61", + objective: "\u4E00\u4E2A\u8BB0\u5206\u9879", + "objective-not-following-convention": "\u8BE5\u8BB0\u5206\u9879%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", + "parser.float.illegal": "\u6D6E\u70B9\u6570\u7531\u4E8E\u672A\u8DDF\u968F %0% \u800C\u65E0\u6548", + "parser.integer.illegal": "\u65E0\u6548\u7684\u6574\u6570\u4E0D\u9075\u5FAA %0%", + "parser.line-continuation-end-of-file": "\u884C\u4E0D\u80FD\u4EE5\u6587\u4EF6\u7ED3\u675F\u7B26\u7EED\u63A5", + "parser.list.trailing-sep": "\u5C3E\u968F\u5206\u9694\u7B26", + "parser.list.value": "\u4E00\u4E2A\u503C", + "parser.long.illegal": "\u957F\u6574\u578B\u6570\u5B57\u56E0\u672A\u8DDF\u968F %0% \u800C\u65E0\u6548", + "parser.record.key": "\u4E00\u4E2A\u952E", + "parser.record.trailing-end": "\u5C3E\u968F\u5206\u9694\u7B26", + "parser.record.unexpected-char": "\u9884\u671F\u5916\u7684\u5B57\u7B26 %0%", + "parser.record.value": "\u4E00\u4E2A\u503C", + "parser.resource-location.illegal": "\u65E0\u6548\u5B57\u7B26\uFF1A%0%", + "parser.resource-location.namespace-expected": "\u4E0D\u53EF\u5728\u6B64\u7701\u7565\u547D\u540D\u7A7A\u95F4", + "parser.resource-location.tag-disallowed": "\u6B64\u5904\u4E0D\u5141\u8BB8\u4F7F\u7528\u6807\u7B7E", + "parser.resource-location.tag-required": "\u8FD9\u91CC\u53EA\u80FD\u4E3A\u6807\u7B7E", + "parser.string.illegal-brigadier": "\u5728 %0% \u4E2D\u9047\u5230\u4E86\u975E [0-9A-Za-z_.+-] \u5B57\u7B26", + "parser.string.illegal-escape": "\u9884\u671F\u5916\u7684\u8F6C\u4E49\u5B57\u7B26 %0%", + "parser.string.illegal-quote": "\u6B64\u5904\u53EA\u5141\u8BB8\u4F7F\u7528 %0% \u5305\u88F9\u5B57\u7B26\u4E32", + "parser.string.illegal-unicode-escape": "\u671F\u671B\u5341\u516D\u8FDB\u5236\u6570\u5B57", + "progress.initializing.title": "\u6B63\u5728\u521D\u59CB\u5316Spyglass\u2026\u2026", + "progress.reset-project-cache.title": "\u6B63\u5728\u91CD\u7F6E\u9879\u76EE\u7F13\u5B58\u2026", + "punc.period": "\u3002", + "punc.quote": "\u201C%0%\u201D", + quote: `\u4E00\u4E2A\u534A\u89D2\u5F15\u53F7\uFF08\u201C'\u201D\u6216\u201C"\u201D\uFF09`, + quote_prefer_double: '\u6B64\u5904\u8BF7\u4F18\u5148\u4F7F\u7528\u534A\u89D2\u53CC\u5F15\u53F7\uFF08\u201C"\u201D\uFF09', + quote_prefer_single: "\u6B64\u5904\u8BF7\u4F18\u5148\u4F7F\u7528\u534A\u89D2\u5355\u5F15\u53F7\uFF08\u201C'\u201D\uFF09", + "resource-location": "\u4E00\u4E2A\u8D44\u6E90\u4F4D\u7F6E", + "score-holder": "\u4E00\u4E2A\u5206\u6570\u6301\u6709\u8005", + "scoreholder-not-following-convention": "\u65E0\u6548\u7684\u5206\u6570\u6301\u6709\u8005 %0% \u4E0D\u9075\u5FAA %1% \u547D\u540D\u89C4\u5219", + selector: "\u4E00\u4E2A\u9009\u62E9\u5668", + "server.new-version": "\u5DF2\u66F4\u65B0\u6570\u636E\u5305\u8BED\u8A00\u670D\u52A1\u5668\u5230\u65B0\u7248\u672C\uFF1A%0%", + "server.progress.fixing-workspace.begin": "\u4FEE\u590D\u5F53\u524D\u5DE5\u4F5C\u7A7A\u95F4\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", + "server.progress.fixing-workspace.report": "\u6B63\u5728\u4FEE\u590D%0%", + "server.progress.preparing.title": "\u6B63\u5728\u51C6\u5907 Spyglass \u8BED\u8A00\u7279\u6027", + "server.remove-cache-file": "DHP \u7684\u7F13\u5B58\u6587\u4EF6\u88AB\u79FB\u52A8\u5230\u4E86\u4E00\u4E2A\u7531 VS Code \u63D0\u4F9B\u7684\u7F13\u5B58\u4F4D\u7F6E\u3002\u60A8\u73B0\u5728\u53EF\u4EE5\u653E\u5FC3\u5730\u5220\u9664\u5DE5\u4F5C\u533A\u6839\u6587\u4EF6\u5939\u4E2D\u7684\u201C.datapack\u201D\u6587\u4EF6\u5939\u3002", + "server.show-release-notes": "\u663E\u793A\u66F4\u65B0\u65E5\u5FD7", + string: "\u4E00\u4E2A\u5B57\u7B26\u4E32", + tag: "\u4E00\u4E2A\u6807\u7B7E", + "tag-not-following-convention": "\u8BE5\u6807\u7B7E%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", + team: "\u4E00\u4E2A\u961F\u4F0D", + "team-not-following-convention": "\u8BE5\u961F\u4F0D%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", + "text-component": "\u4E00\u4E2A\u6587\u672C\u7EC4\u4EF6", + "time-unit": "\u4E00\u4E2A\u65F6\u95F4\u5355\u4F4D", + "too-many-block-affected": "\u6307\u5B9A\u533A\u57DF\u5185\u7684\u65B9\u5757\u592A\u591A\uFF08\u6700\u5927\u503C\u4E3A %0%\uFF0C\u6307\u5B9A\u503C\u4E3A %1%\uFF09", + "too-many-chunk-affected": "\u6307\u5B9A\u533A\u57DF\u5185\u7684\u533A\u5757\u592A\u591A\uFF08\u6700\u5927\u503C\u4E3A %0%\uFF0C\u6307\u5B9A\u503C\u4E3A %1%\uFF09", + "unexpected-character": "\u9047\u5230\u4E86\u975E [a-z0-9/._-] \u5B57\u7B26", + "unexpected-datapack-tag": "\u6B64\u5904\u4E0D\u5141\u8BB8\u4F7F\u7528\u6807\u7B7E", + "unexpected-default-namespace": "\u5E94\u5F53\u7701\u7565\u6B64\u5904\u7684\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", + "unexpected-local-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u5C40\u90E8\u5750\u6807%0%", + "unexpected-nbt": "\u6B64\u5904\u4E0D\u5E94\u4F7F\u7528\u8BE5 NBT \u6807\u7B7E", + "unexpected-nbt-array-type": "\u65E0\u6548\u7684\u6570\u7EC4\u7C7B\u578B%0%\u3002\u5E94\u5F53\u4E3A\u201CB\u201D\u201CI\u201D\u201CL\u201D\u4E2D\u7684\u4E00\u4E2A", + "unexpected-nbt-path-filter": "\u590D\u5408\u6807\u7B7E\u7B5B\u9009\u5668\u53EA\u80FD\u5BF9\u590D\u5408\u6807\u7B7E\u4F7F\u7528", + "unexpected-nbt-path-index": "\u7D22\u5F15\u53EA\u80FD\u5BF9\u5217\u8868\u6216\u6570\u7EC4\u6807\u7B7E\u4F7F\u7528", + "unexpected-nbt-path-key": "\u952E\u53EA\u80FD\u5BF9\u590D\u5408\u6807\u7B7E\u4F7F\u7528", + "unexpected-nbt-path-sub": "\u5F53\u524D\u7684\u6807\u7B7E\u5E76\u6CA1\u6709\u66F4\u591A\u7684\u5B50\u9879", + "unexpected-omitted-default-namespace": "\u6B64\u5904\u4E0D\u80FD\u7701\u7565\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", + "unexpected-relative-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u76F8\u5BF9\u5750\u6807%0%", + "unexpected-scoreboard-sub-slot": "\u53EA\u6709\u201Csidebar\u201D\u6709\u5B50\u663E\u793A\u4F4D\u7F6E", + "unknown-command": "\u672A\u77E5\u7684\u547D\u4EE4%0%", + "unknown-escape": "\u9884\u671F\u5916\u7684\u8F6C\u4E49\u5B57\u7B26 %0%", + "unknown-key": "\u672A\u77E5\u7684\u952E%0%", + "unquoted-string": "\u4E00\u4E2A\u672A\u88AB\u5F15\u53F7\u5305\u88F9\u7684\u5B57\u7B26\u4E32", + "unsorted-keys": "\u952E\u672A\u6392\u5E8F", + uuid: "\u4E00\u4E2A UUID", + vector: "\u4E00\u4E2A\u5411\u91CF" + }; + } +}); + +// node_modules/@spyglassmc/locales/lib/locales/zh-tw.json +var zh_tw_exports = {}; +__export(zh_tw_exports, { + default: () => zh_tw_default +}); +var zh_tw_default; +var init_zh_tw = __esm({ + "node_modules/@spyglassmc/locales/lib/locales/zh-tw.json"() { + zh_tw_default = { + array: "\u4E00\u500B\u9663\u5217", + boolean: "\u4E00\u500B\u5E03\u6797\u503C", + "bug-of-mc": "\u7531\u65BC\u4E00\u500BMinecraft\u7684\u932F\u8AA4\uFF08%0%\uFF09\uFF0C%1%\u3002Mojang\uFF0C\u62DC\u8A17\u4FEE\u597D\u4F60\u7684\u904A\u6232", + "code-action.add-default-namespace": "\u589E\u52A0\u9810\u8A2D\u547D\u540D\u7A7A\u9593", + "code-action.add-leading-slash": "\u589E\u52A0\u958B\u982D\u7684\u659C\u7DDA", + "code-action.block-state-sort-keys": "\u5C07\u65B9\u584A\u72C0\u614B\u6309\u9375\u6392\u5E8F", + "code-action.command-replaceitem": "\u5C07\u8A72\u6307\u4EE4\u5347\u7D1A\u5230 /item ... replace", + "code-action.create-undeclared-file": "\u5EFA\u7ACB%0% %1%", + "code-action.fix-file": "\u4FEE\u5FA9\u7576\u524D\u6A94\u6848\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", + "code-action.fix-workspace": "\u4FEE\u5FA9\u7576\u524D\u5DE5\u4F5C\u5340\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", + "code-action.id-attribute-datafix": "\u5C07\u8A72\u5C6C\u6027\u540D\u66F4\u65B0\u81F3 1.16", + "code-action.id-complete-default-namespace": "\u88DC\u5B8C\u9810\u8A2D\u547D\u540D\u7A7A\u9593", + "code-action.id-create-file": "\u5728\u540C\u4E00\u500B\u8CC7\u6599\u5305\u4E2D\u5EFA\u7ACB%0%", + "code-action.id-omit-default-namespace": "\u7701\u7565\u9810\u8A2D\u547D\u540D\u7A7A\u9593", + "code-action.id-zombified-piglin-datafix": "\u5C07\u8A72 ID \u5347\u7D1A\u70BA\u6BAD\u5C4D\u5316\u8C6C\u5E03\u6797", + "code-action.nbt-compound-sort-keys": "\u5C07 NBT \u8907\u5408\u6A19\u7C64\u6309\u9375\u6392\u5E8F", + "code-action.nbt-type-to-byte": "\u8F49\u63DB\u70BA NBT \u4F4D\u5143\u7D44\uFF08byte\uFF09\u6A19\u7C64", + "code-action.nbt-type-to-double": "\u8F49\u63DB\u70BA NBT \u500D\u7CBE\u5EA6\u6D6E\u9EDE\u6578\uFF08double\uFF09\u6A19\u7C64", + "code-action.nbt-type-to-float": "\u8F49\u63DB\u70BA NBT \u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\uFF08float\uFF09\u6A19\u7C64", + "code-action.nbt-type-to-int": "\u8F49\u63DB\u70BA NBT \u6574\u6578\uFF08int\uFF09\u6A19\u7C64", + "code-action.nbt-type-to-long": "\u8F49\u63DB\u70BA NBT \u9577\u6574\u6578\uFF08long\uFF09\u6A19\u7C64", + "code-action.nbt-type-to-short": "\u8F49\u63DB\u70BA NBT \u77ED\u6574\u6578\uFF08short\uFF09\u6A19\u7C64", + "code-action.nbt-uuid-datafix": "\u5C07\u8A72 UUID \u66F4\u65B0\u81F3 1.16", + "code-action.remove-leading-slash": "\u79FB\u9664\u958B\u982D\u7684\u659C\u7DDA", + "code-action.remove-trailing-separation": "\u79FB\u9664\u7D50\u5C3E\u7684\u5206\u9694\u7B26\u865F", + "code-action.selector-sort-keys": "\u5C07\u9078\u64C7\u5668\u5F15\u6578\u6309\u9375\u6392\u5E8F", + "code-action.string-double-quote": "\u4F7F\u7528\u82F1\u6587\u96D9\u5F15\u865F\u5305\u88F9\u8A72\u5B57\u4E32", + "code-action.string-single-quote": "\u4F7F\u7528\u82F1\u6587\u55AE\u5F15\u865F\u5305\u88F9\u8A72\u5B57\u4E32", + "code-action.string-unquote": "\u79FB\u9664\u8A72\u5B57\u4E32\u7684\u5F15\u865F", + "code-action.vector-align-0.0": "\u5C07\u8A72\u5411\u91CF\u5C0D\u9F4A\u5230\u65B9\u584A\u539F\u9EDE", + "code-action.vector-align-0.5": "\u5C07\u8A72\u5411\u91CF\u5C0D\u9F4A\u5230\u65B9\u584A\u4E2D\u5FC3", + comment: "\u4EE5 %0% \u958B\u59CB\u7684\u8A3B\u89E3", + "conjunction.and_2": " \u548C ", + "conjunction.and_3+_1": "\u3001 ", + "conjunction.and_3+_2": "\u548C ", + "conjunction.or_2": " \u6216 ", + "conjunction.or_3+_1": "\u3001 ", + "conjunction.or_3+_2": "\u6216 ", + "datafix.error.command-replaceitem": "/replaceitem \u5728 20w46a\uFF081.17 \u7684\u7B2C\u4E8C\u500B\u5FEB\u7167\uFF09\u4E2D\u88AB /item \u53D6\u4EE3", + "duplicate-key": "\u9375%0%\u91CD\u8907", + "ending-quote": "\u4E00\u500B\u7D50\u5C3E\u5F15\u865F%0%", + entity: "\u4E00\u500B\u5BE6\u9AD4", + "error.unparseable-content": "\u9047\u5230\u4E86\u7121\u6CD5\u89E3\u6790\u7684\u5167\u5BB9", + expected: "\u671F\u671B%0%", + "expected-got": "\u671F\u671B%0%\uFF0C\u4F46\u5F97\u5230\u4E86%1%", + float: "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578", + "float.between": "\u4E00\u500B\u8655\u65BC %0% \u8207 %1% \u4E4B\u9593\u7684\u6D6E\u9EDE\u578B\u6578\u5B57", + integer: "\u4E00\u500B\u6574\u6578", + "integer.between": "\u4E00\u500B\u8655\u65BC %0% \u8207 %1% \u4E4B\u9593\u7684\u6574\u6578", + "invalid-key-combination": "\u7121\u6548\u7684\u7D44\u5408 %0%", + "invalid-regex-pattern": "\u7121\u6548\u7684regex\uFF1A%0%", + "java-edition.binder.wrong-folder": "\u5728%0%\u8CC7\u6599\u593E\u4E2D\u7684\u6A94\u6848\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09\uFF0C\u4F60\u9700\u8981\u7684\u662F%2%\u8CC7\u6599\u593E\u55CE\uFF1F", + "java-edition.binder.wrong-version": "\u5728%0%\u8CC7\u6599\u593E\u4E2D\u7684\u6A94\u6848\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09", + "java-edition.pack-format.not-loaded": "\u8CC7\u6599\u5305\u7248\u672C%0%\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09\u3002\u4F60\u53EF\u80FD\u9700\u8981\u91CD\u65B0\u8F09\u5165Spyglass\u3002", + "java-edition.pack-format.unsupported": "\u8CC7\u6599\u5305\u7248\u672C%0%\u4E0D\u5C6C\u65BC\u6B63\u5F0F\u7248\u672C\u3002\u5FEB\u7167\u7248\u672C\u4E0D\u53D7\u652F\u63F4\u3002", + "java-edition.translation-value.percent-escape-hint": "%0%\u3002\u4F7F\u7528\u300C%%\u300D\u986F\u793A\u767E\u5206\u6BD4\u7B26\u865F", + "json.checker.array.length-between": "\u9577\u5EA6\u5728%1%\u548C%2%\u4E4B\u9593\u7684%0%", + "json.checker.item.duplicate": "\u91CD\u8907\u7684\u6E05\u55AE\u5167\u5BB9", + "json.checker.object.field.union-empty-members": "\u4E0D\u5141\u8A31\u7684\u5C6C\u6027", + "json.checker.property.deprecated": "\u5C6C\u6027 %0% \u5DF2\u88AB\u68C4\u7528", + "json.checker.property.missing": "\u7F3A\u5931\u5C6C\u6027 %0%", + "json.checker.property.unknown": "\u672A\u77E5\u5C6C\u6027 %0%", + "json.checker.string.hex-color": "\u4E00\u500B 6 \u4F4D\u7684\u5341\u516D\u9032\u4F4D\u6578\u5B57", + "json.checker.tag-entry.duplicate": "\u91CD\u8907\u7684\u503C", + "json.checker.value": "\u4E00\u500B\u503C", + "json.doc.advancement.display": "\u9032\u5EA6\u7684\u986F\u793A\u8A2D\u5B9A\u3002\u82E5\u5B58\u5728\uFF0C\u5247\u6B64\u9032\u5EA6\u6703\u5728\u9032\u5EA6\u756B\u9762\u4E2D\u53EF\u898B\u3002", + "json.node.array": "\u4E00\u500B\u9663\u5217", + "json.node.boolean": "\u4E00\u500B\u5E03\u6797\u503C", + "json.node.null": "null", + "json.node.number": "\u4E00\u500B\u6578\u5B57", + "json.node.object": "\u4E00\u500B\u7269\u4EF6", + "json.node.string": "\u4E00\u500B\u5B57\u4E32", + "key-not-following-convention": "\u7121\u6548\u7684\u9375%0%\uFF0C\u56E0\u70BA\u6C92\u6709\u9075\u5FAA%1%\u547D\u540D\u898F\u7BC4", + "linter-config-validator.name-convention.type": "\u671F\u671B\u4E00\u500B\u63CF\u8FF0\u540D\u5B57\u7684\u6B63\u898F\u8868\u793A\u5F0F\u5B57\u4E32", + "linter-config-validator.wrapper": "%0%\u3002 \u95B1\u8B80[\u6587\u4EF6]\uFF08%1\uFF09\u4EE5\u7372\u53D6\u66F4\u591A\u8CC7\u8A0A", + "linter.diagnostic-message-wrapper": "%0%\uFF08\u898F\u5247\uFF1A%1%\uFF09", + "linter.name-convention.illegal": "\u540D\u7A31 %0% \u8207\u7D44\u614B\u7684\u6B63\u898F\u8868\u793A\u5F0F %1% \u4E0D\u76F8\u7B26", + "linter.undeclared-symbol.message": "\u627E\u4E0D\u5230 %0% %1%", + long: "\u4E00\u500B\u9577\u6574\u6578", + "long.between": "\u4E00\u500B\u5728%0%\u548C%1%\u4E4B\u9593\u7684\u9577\u6574\u6578", + "mcdoc.binder.dispatcher-statement.duplicated-key": "\u91CD\u8907\u7684dispatcher\uFF1A%0%", + "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0%\u5DF2\u7D93\u5728\u9019\u88E1\u5B9A\u7FA9\u904E\u4E86", + "mcdoc.binder.duplicated-declaration": "\u91CD\u8907\u7684\u5BA3\u544A %0%", + "mcdoc.binder.duplicated-declaration.related": "%0% \u5DF2\u5728\u9019\u88E1\u5BA3\u544A\u904E\u4E86", + "mcdoc.binder.out-of-root": "\u6A94\u6848 %0% \u4E0D\u5728\u4EFB\u4F55 mcdoc \u5C08\u6848\u4E2D\u7684\u6839\u76EE\u9304\uFF1B\u8A9E\u610F\u6AA2\u67E5\u5C07\u88AB\u8DF3\u904E", + "mcdoc.binder.path.super-from-root": "\u4E0D\u53EF\u8A2A\u554F\u6839\u76EE\u9304\u7684\u7236\u7D1A\u76EE\u9304", + "mcdoc.binder.path.unknown-identifier": "\u6A19\u8B58\u7B26 %0% \u4E0D\u5B58\u5728\u65BC\u6A21\u7D44 %1%", + "mcdoc.binder.path.unknown-module": "\u6A21\u7D44 \uFF050% \u4E0D\u5B58\u5728", + "mcdoc.checker.entry.empty-mod-seg": "\u60A8\u4E0D\u80FD\u5C07\u300Cmod.mcdoc\u300D\u76F4\u63A5\u653E\u5728\u6839\u76EE\u9304\u4E0B", + "mcdoc.checker.inject-clause.unmatched-injection": "\u4E0D\u80FD\u7528 %1% \u6CE8\u78BC\u65BC %0%", + "mcdoc.checker.type-not-assignable": "\u985E\u578B %0% \u4E0D\u80FD\u5206\u914D\u7D66\u985E\u578B %1%", + "mcdoc.node.compound-definition": "\u4E00\u500B\u8907\u5408\u5B9A\u7FA9", + "mcdoc.node.enum-definition": "\u4E00\u500B\u5217\u8209\u5B9A\u7FA9", + "mcdoc.node.identifier": "\u4E00\u500B\u6A19\u8B58\u7B26", + "mcdoc.parser.compound-definition.field-type": "\u4E00\u500B\u6B04\u4F4D\u985E\u578B", + "mcdoc.parser.float.illegal": "\u9047\u5230\u4E86\u7121\u6548\u7684\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578", + "mcdoc.parser.identifier.illegal": "%0% \u4E0D\u9075\u5FAA\u683C\u5F0F %1%", + "mcdoc.parser.identifier.reserved-word": "%0% \u662F\u500B\u53CD\u8F49\u6587\u5B57\u4E14\u4E0D\u53EF\u88AB\u7528\u65BC\u6A19\u8B58\u7B26\u540D\u7A31", + "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u52D5\u614B\u7D22\u5F15\u662F\u4E0D\u5141\u8A31\u7684", + "mcdoc.parser.inject-clause.definition-expected": "\u671F\u671B\u4E00\u500B\u5217\u8209\u6CE8\u78BC\u6216\u8907\u5408\u6CE8\u78BC", + "mcdoc.parser.keyword.separation": "\u4E00\u500B\u5206\u9694\u7B26", + "mcdoc.parser.resource-location.colon-expected": "\u8CC7\u6E90\u4F4D\u7F6E\u9810\u671F\u70BA\u5192\u865F (%0%)", + "mcdoc.parser.syntax.doc-comment-unexpected": "\u6B64\u8655\u4E0D\u5141\u8A31\u6587\u6A94\u8A3B\u89E3\uFF1B\u60A8\u53EF\u80FD\u60F3\u7528\u5169\u500B\u659C\u7DDA\u53D6\u4EE3\u4E09\u500B\u659C\u7DDA", + "mcdoc.runtime.checker.key-value-pair": "\u4E00\u500B\u9375\u503C\u5C0D", + "mcdoc.runtime.checker.range.collection": "\u96C6\u5408\u9577\u5EA6\u70BA %0%", + "mcdoc.runtime.checker.range.concat": "%0% \u548C %1%", + "mcdoc.runtime.checker.range.left-exclusive": "\u5927\u65BC %0%", + "mcdoc.runtime.checker.range.left-inclusive": "\u81F3\u5C11\u70BA %0%", + "mcdoc.runtime.checker.range.number": "\u61C9\u70BA\u6578\u503C %0%", + "mcdoc.runtime.checker.range.right-exclusive": "\u4F4E\u65BC %0%", + "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u591A %0%", + "mcdoc.runtime.checker.range.string": "\u5B57\u4E32\u9577\u5EA6\u61C9\u70BA %0%", + "mcdoc.runtime.checker.some-missing-keys": "\u7F3A\u5C11 %0% \u4E2D\u7684\u81F3\u5C11\u4E00\u500B\u9375", + "mcdoc.runtime.checker.trailing": "\u767C\u73FE\u5C3E\u96A8\u8CC7\u6599", + "mcdoc.runtime.checker.value": "\u4E00\u500B\u503C", + "mcdoc.type.boolean": "\u4E00\u500B\u5E03\u6797\u503C", + "mcdoc.type.byte": "\u4E00\u500B\u5B57\u7BC0\u503C", + "mcdoc.type.byte_array": "\u4E00\u500B\u5B57\u7BC0\u9663\u5217", + "mcdoc.type.double": "\u4E00\u500B\u500D\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u503C", + "mcdoc.type.float": "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u503C", + "mcdoc.type.int": "\u4E00\u500B\u6574\u6578\u503C", + "mcdoc.type.int_array": "\u4E00\u500B\u6574\u6578\u9663\u5217", + "mcdoc.type.list": "\u4E00\u500B\u5217\u8868", + "mcdoc.type.long": "\u4E00\u500B\u9577\u6574\u6578\u503C", + "mcdoc.type.long_array": "\u4E00\u500B\u9577\u6574\u6578\u9663\u5217", + "mcdoc.type.short": "\u4E00\u500B\u77ED\u6574\u6578\u503C", + "mcdoc.type.string": "\u4E00\u500B\u5B57\u4E32\u503C", + "mcfunction.checker.command.data-modify-unapplicable-operation": "%0% \u64CD\u4F5C\u53EA\u80FD\u88AB\u7528\u65BC %1%\uFF1B\u76EE\u6A19\u8DEF\u5F91\u985E\u578B\u5247\u70BA %2%", + "mcfunction.completer.block.states.default-value": "\u9810\u8A2D\uFF1A %0%", + "mcfunction.parser.command-too-long": "\u6307\u4EE4\u9577\u5EA6 %0% \u7B46\u6700\u5927\u9577\u5EA6 %1% \u9577", + "mcfunction.parser.duplicate-components": "\u91CD\u8907\u7684\u7D44\u4EF6", + "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% \u4E0D\u9069\u7528\u65BC\u6B64\u8655", + "mcfunction.parser.entity-selector.arguments.unknown": "\u672A\u77E5\u7684\u5BE6\u9AD4\u9078\u64C7\u5668\u5F15\u6578 %0%", + "mcfunction.parser.entity-selector.entities-disallowed": "\u6B64\u9078\u64C7\u5668\u5305\u542B\u975E\u73A9\u5BB6\u5BE6\u9AD4", + "mcfunction.parser.entity-selector.invalid": '\u7121\u6548\u7684\u76EE\u6A19\u9078\u64C7\u5668\uFF1A"%0%"', + "mcfunction.parser.entity-selector.multiple-disallowed": "\u6B64\u9078\u64C7\u5668\u5305\u542B\u591A\u500B\u5BE6\u9AD4", + "mcfunction.parser.entity-selector.player-name.too-long": "\u73A9\u5BB6\u540D\u7A31\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", + "mcfunction.parser.eoc-unexpected": "\u671F\u671B\u66F4\u591A\u5F15\u6578", + "mcfunction.parser.leading-slash": "\u4E00\u500B\u524D\u7F6E\u659C\u7DDA \u300C/\u300D", + "mcfunction.parser.leading-slash.unexpected": "\u4E0D\u80FD\u4EE5\u659C\u69D3\u300C/\u300D\u958B\u59CB\u6307\u4EE4", + "mcfunction.parser.macro.at-least-one": "\u81F3\u5C11\u4E00\u500B\u5DE8\u96C6\u53C3\u6578", + "mcfunction.parser.macro.disallowed": "\u5DE8\u96C6\u884C\u53EA\u652F\u63F4\u65BC 1.20.2 \u4E4B\u5F8C", + "mcfunction.parser.macro.illegal-key": '\u4E0D\u6B63\u78BA\u7684\u9375\u5B57\u7B26\uFF1A"%0%"', + "mcfunction.parser.macro.key": "\u4E00\u500B\u5DE8\u96C6\u9375", + "mcfunction.parser.no-permission": "\u9700\u8981\u6B0A\u9650\u7B49\u7D1A %0%\uFF0C\u9AD8\u65BC\u8A2D\u5B9A\u4E2D\u5B9A\u7FA9\u7684 %1%", + "mcfunction.parser.objective.too-long": "\u8A08\u5206\u677F\u76EE\u6A19\u540D\u7A31\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", + "mcfunction.parser.range.min>max": "\u6700\u5C0F\u503C %0% \u5927\u65BC\u6700\u5927\u503C %1%", + "mcfunction.parser.range.span-too-large": "\u7BC4\u570D\u5927\u5C0F %0% \u5927\u65BC\u6700\u5927\u503C %1%", + "mcfunction.parser.range.span-too-small": "\u7BC4\u570D\u5927\u5C0F %0% \u5C0F\u65BC\u6700\u5C0F\u503C %1%", + "mcfunction.parser.score_holder.fake-name.too-long": "\u5BE6\u9AD4\u5047\u540D\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", + "mcfunction.parser.sep": "\u4E00\u500B\u7A7A\u767D\u5B57\u5143\uFF08%0%\uFF09", + "mcfunction.parser.trailing": "\u9047\u5230\u5C3E\u96A8\u8CC7\u6599\uFF1A%0%", + "mcfunction.parser.unknown-parser": "\u5C1A\u672A\u652F\u63F4\u89E3\u6790\u5668 %0%", + "mcfunction.parser.uuid.invalid": "\u7121\u6548\u7684 UUID \u683C\u5F0F", + "mcfunction.parser.vector.local-disallowed": "\u5C40\u90E8\u5EA7\u6A19\u4E0D\u5141\u8A31\u5728\u6B64\u8655\u4F7F\u7528", + "mcfunction.parser.vector.mixed": "\u4E0D\u80FD\u6DF7\u7528\u5C40\u90E8\u5EA7\u6A19\u8207\u4E16\u754C\u5EA7\u6A19", + "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki\uFF1A `%0%` \u53C3\u6578\u985E\u578B](https://zh.minecraft.wiki/w/\u53C3\u6578\u985E\u578B#%0%)", + "mcfunction.signature-help.command-documentation": "[Minecraft \u7DAD\u57FA\uFF1A `%0%` \u6307\u4EE4](https://minecraft.fandom.com/zh/wiki/\u547D\u4EE4/%0%)", + "mismatching-regex-pattern": "\u503C\u4E0D\u7B26\u5408regex\uFF1A%0%", + "missing-key": "\u7F3A\u5931\u9375 %0%", + "nbt.checker.block-states.fake-boolean": "\u61C9\u7528\u5F15\u865F\u5305\u88F9\u5E03\u6797\u578B\u65B9\u584A\u72C0\u614B\u503C", + "nbt.checker.block-states.unexpected-value-type": "\u65B9\u584A\u72C0\u614B\u503C\u61C9\u70BA\u5B57\u4E32\u6216\u6574\u6578", + "nbt.checker.block-states.unknown-state": "\u4EE5\u4E0B\u65B9\u584A\u5177\u6709\u672A\u77E5\u7684\u65B9\u584A\u72C0\u614B %0%\uFF1A%1%", + "nbt.checker.boolean.out-of-range": "\u5E03\u6797\u503C\u61C9\u70BA %0% \u6216 %1%", + "nbt.checker.collection.length-between": "%0% \u7684\u9577\u5EA6\u5728 %1% \u548C %2% \u4E4B\u9593", + "nbt.checker.compound.field.union-empty-members": "\u4E0D\u5141\u8A31\u7684\u5C6C\u6027", + "nbt.checker.path.index-out-of-bound": "\u63D0\u4F9B\u7684\u7D22\u5F15 %0% \u8D8A\u754C\uFF0C\u56E0\u70BA\u96C6\u5408\u6700\u591A\u53EA\u80FD\u64C1\u6709 %1% \u500B\u5143\u7D20", + "nbt.checker.path.unexpected-filter": "\u8907\u5408\u6A19\u7C64\u904E\u6FFE\u5668\u53EA\u80FD\u7528\u65BC\u8907\u5408\u6A19\u7C64", + "nbt.checker.path.unexpected-index": "\u7D22\u5F15\u53EA\u80FD\u7528\u65BC\u9663\u5217\u6216\u4E32\u5217\u6A19\u7C64", + "nbt.checker.path.unexpected-key": "\u5B57\u4E32\u9375\u53EA\u80FD\u70BA\u8907\u5408\u6A19\u7C64\u6307\u5B9A", + "nbt.node": "\u4E00\u500B\u6A19\u7C64", + "nbt.node.byte": "\u4E00\u500B\u5B57\u5143\u7D44\u6A19\u7C64", + "nbt.node.byte_array": "\u4E00\u500B\u5B57\u5143\u7D44\u9663\u5217\u6A19\u7C64", + "nbt.node.compound": "\u4E00\u500B\u8907\u5408\u6A19\u7C64", + "nbt.node.double": "\u4E00\u500B\u500D\u7CBE\u5EA6\u6D6E\u9EDE\u578B\u6A19\u7C64", + "nbt.node.float": "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u578B\u6A19\u7C64", + "nbt.node.int": "\u4E00\u500B\u6574\u6578\u6A19\u7C64", + "nbt.node.int_array": "\u4E00\u500B\u6574\u6578\u9663\u5217\u6A19\u7C64", + "nbt.node.list": "\u4E00\u500B\u4E32\u5217\u6A19\u7C64", + "nbt.node.long": "\u4E00\u500B\u9577\u6574\u6578\u6A19\u7C64", + "nbt.node.long_array": "\u4E00\u500B\u9577\u6574\u6578\u9663\u5217\u6A19\u7C64", + "nbt.node.path.end": "\u8DEF\u5F91\u7D50\u5C3E", + "nbt.node.path.filter": "\u4E00\u500B\u8907\u5408\u6A19\u7C64\u904E\u6FFE\u5668", + "nbt.node.path.index": "\u4E00\u500B\u7D22\u5F15", + "nbt.node.path.key": "\u4E00\u500B\u9375", + "nbt.node.short": "\u4E00\u500B\u77ED\u6574\u6578\u6A19\u7C64", + "nbt.node.string": "\u4E00\u500B\u5B57\u4E32\u6A19\u7C64", + "nbt.parser.number.out-of-range": "\u9019\u770B\u8D77\u4F86\u50CF %0%\uFF0C\u4F46\u5BE6\u969B\u4E0A\u662F %1%\uFF0C\u56E0\u70BA\u6578\u503C\u8D85\u51FA\u4E86 [%2%, %3%]", + "not-matching-any-child": "\u7121\u6548\u5F15\u6578", + nothing: "\u7121", + number: "\u4E00\u500B\u6578\u5B57", + "number-range": "\u4E00\u500B\u6578\u5B57\u7BC4\u570D", + "number-range.missing-min-and-max": "\u671F\u671B\u4E00\u500B\u6700\u5C0F\u503C\u6216\u4E00\u500B\u6700\u5927\u503C", + "number.<=": "\u4E00\u500B\u5C0F\u65BC\u7B49\u65BC %0% \u7684\u6578\u5B57", + "number.>=": "\u4E00\u500B\u5927\u65BC\u7B49\u65BC %0% \u7684\u6578\u5B57", + "number.between": "\u4E00\u500B\u4F4D\u65BC %0% \u548C %1% \u4E4B\u9593\u7684\u6578\u5B57", + object: "\u4E00\u500B\u7269\u4EF6", + objective: "\u4E00\u500B\u8A08\u5206\u677F\u76EE\u6A19", + "objective-not-following-convention": "\u8A72\u8A08\u5206\u677F\u76EE\u6A19 %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", + "parser.float.illegal": "\u7121\u6548\u7684\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u4E0D\u9075\u5FAA %0%", + "parser.integer.illegal": "\u7121\u6548\u7684\u6574\u6578\u4E0D\u9075\u5FAA %0%", + "parser.list.trailing-sep": "\u5C3E\u96A8\u5206\u9694\u7B26", + "parser.list.value": "\u4E00\u500B\u503C", + "parser.record.key": "\u4E00\u500B\u9375", + "parser.record.trailing-end": "\u5C3E\u96A8\u5206\u9694\u7B26", + "parser.record.unexpected-char": "\u9810\u671F\u5916\u7684\u5B57\u5143 %0%", + "parser.record.value": "\u4E00\u500B\u503C", + "parser.resource-location.illegal": "\u7121\u6548\u5B57\u5143\uFF1A%0%", + "parser.resource-location.namespace-expected": "\u4E0D\u53EF\u5728\u6B64\u7701\u7565\u547D\u540D\u7A7A\u9593", + "parser.resource-location.tag-disallowed": "\u6B64\u8655\u4E0D\u5141\u8A31\u4F7F\u7528\u6A19\u7C64", + "parser.string.illegal-brigadier": "\u5728 %0% \u4E2D\u9047\u5230\u4E86\u975E [0-9A-Za-z_.+-] \u5B57\u5143", + "parser.string.illegal-escape": "\u9810\u671F\u5916\u7684\u8DF3\u812B\u5B57\u5143 %0%", + "parser.string.illegal-quote": "\u6B64\u8655\u53EA\u5141\u8A31\u4F7F\u7528 %0% \u5305\u88F9\u5B57\u4E32", + "parser.string.illegal-unicode-escape": "\u671F\u671B\u5341\u516D\u9032\u4F4D\u6578\u5B57", + "punc.period": "\u3002", + "punc.quote": "\u300C%0%\u300D", + quote: `\u4E00\u500B\u82F1\u6587\u5F15\u865F\uFF08\u300C'\u300D\u6216\u300C"\u300D\uFF09`, + quote_prefer_double: '\u6B64\u8655\u8ACB\u512A\u5148\u4F7F\u7528\u82F1\u6587\u96D9\u5F15\u865F\uFF08\u300C"\u300D\uFF09', + quote_prefer_single: "\u6B64\u8655\u8ACB\u512A\u5148\u4F7F\u7528\u82F1\u6587\u55AE\u5F15\u865F\uFF08\u300C'\u300D\uFF09", + "resource-location": "\u4E00\u500B\u8CC7\u6E90\u4F4D\u7F6E", + "score-holder": "\u4E00\u500B\u5206\u6578\u6301\u6709\u8005", + "scoreholder-not-following-convention": "\u7121\u6548\u7684\u5206\u6578\u6301\u6709\u8005 %0% \u4E0D\u9075\u5FAA %1% \u547D\u540D\u898F\u5247", + "server.new-version": "\u5DF2\u66F4\u65B0\u8CC7\u6599\u5305\u8A9E\u8A00\u4F3A\u670D\u5668\u5230\u65B0\u7248\u672C\uFF1A%0%", + "server.progress.fixing-workspace.begin": "\u4FEE\u5FA9\u7576\u524D\u5DE5\u4F5C\u5340\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", + "server.progress.fixing-workspace.report": "\u6B63\u5728\u4FEE\u5FA9%0%", + "server.remove-cache-file": "DHP \u7684\u5FEB\u53D6\u6A94\u6848\u88AB\u79FB\u52D5\u5230\u4E86\u4E00\u500B\u7531 VSCode \u63D0\u4F9B\u7684\u5FEB\u53D6\u76EE\u9304\u3002\u60A8\u73FE\u5728\u53EF\u4EE5\u653E\u5FC3\u5730\u522A\u9664\u5DE5\u4F5C\u5340\u6839\u76EE\u9304\u4E0B\u7684\u300C.datapack\u300D\u6A94\u6848\u593E\u3002", + "server.show-release-notes": "\u986F\u793A\u66F4\u65B0\u65E5\u8A8C", + string: "\u4E00\u500B\u5B57\u4E32", + tag: "\u4E00\u500B\u6A19\u7C64", + "tag-not-following-convention": "\u8A72\u6A19\u7C64 %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", + team: "\u4E00\u500B\u968A\u4F0D", + "team-not-following-convention": "\u8A72\u968A\u4F0D %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", + "time-unit": "\u4E00\u500B\u6642\u9593\u55AE\u4F4D", + "too-many-block-affected": "\u6307\u5B9A\u5340\u57DF\u5167\u7684\u65B9\u584A\u592A\u591A\uFF08\u6700\u5927\u503C\u70BA %0%\uFF0C\u6307\u5B9A\u70BA %1%\uFF09", + "too-many-chunk-affected": "\u6307\u5B9A\u5340\u57DF\u5167\u7684\u5340\u584A\u592A\u591A\uFF08\u6700\u5927\u503C\u70BA %0%\uFF0C\u6307\u5B9A\u503C\u70BA %1%\uFF09", + "unexpected-character": "\u9047\u5230\u4E86\u975E [a-z0-9/._-] \u5B57\u5143", + "unexpected-datapack-tag": "\u6B64\u8655\u4E0D\u5141\u8A31\u4F7F\u7528\u6A19\u7C64", + "unexpected-default-namespace": "\u61C9\u7576\u7701\u7565\u6B64\u8655\u7684\u9810\u8A2D\u547D\u540D\u7A7A\u9593", + "unexpected-local-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u5C40\u90E8\u5EA7\u6A19%0%", + "unexpected-nbt": "\u6B64\u8655\u4E0D\u61C9\u4F7F\u7528 NBT \u6A19\u7C64", + "unexpected-nbt-array-type": "\u7121\u6548\u7684\u9663\u5217\u985E\u578B%0%\u3002\u61C9\u70BA\u300CB\u300D\u3001\u300CI\u300D\u3001\u300CL\u300D\u4E2D\u7684\u4E00\u500B", + "unexpected-nbt-path-filter": "\u8907\u5408\u6A19\u7C64\u7BE9\u9078\u5668\u53EA\u80FD\u5C0D\u8907\u5408\u6A19\u7C64\u4F7F\u7528", + "unexpected-nbt-path-index": "\u7D22\u5F15\u53EA\u80FD\u5C0D\u4E32\u5217\u6216\u9663\u5217\u6A19\u7C64\u4F7F\u7528", + "unexpected-nbt-path-key": "\u9375\u53EA\u80FD\u5C0D\u8907\u5408\u6A19\u7C64\u4F7F\u7528", + "unexpected-nbt-path-sub": "\u7576\u524D\u7684\u6A19\u7C64\u4E26\u6C92\u6709\u66F4\u591A\u5B50\u9805\u76EE", + "unexpected-omitted-default-namespace": "\u6B64\u8655\u4E0D\u80FD\u7701\u7565\u9810\u8A2D\u547D\u540D\u7A7A\u9593", + "unexpected-relative-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u76F8\u5C0D\u5EA7\u6A19%0%", + "unexpected-scoreboard-sub-slot": "\u53EA\u6709\u300Csidebar\u300D\u6709\u5B50\u6B04\u76EE", + "unknown-command": "\u672A\u77E5\u7684\u6307\u4EE4%0%", + "unknown-escape": "\u9810\u671F\u5916\u7684\u8DF3\u812B\u5B57\u5143 %0%", + "unknown-key": "\u672A\u77E5\u7684\u9375%0%", + "unquoted-string": "\u4E00\u500B\u672A\u88AB\u5F15\u865F\u5305\u88F9\u7684\u5B57\u4E32", + "unsorted-keys": "\u9375\u672A\u6392\u5E8F", + uuid: "\u4E00\u500B UUID", + vector: "\u4E00\u500B\u5411\u91CF" + }; + } +}); + +// node_modules/picomatch/lib/constants.js +var require_constants = __commonJS({ + "node_modules/picomatch/lib/constants.js"(exports2, module3) { + "use strict"; + var WIN_SLASH = "\\\\/"; + var WIN_NO_SLASH = `[^${WIN_SLASH}]`; + var DEFAULT_MAX_EXTGLOB_RECURSION = 0; + var DOT_LITERAL = "\\."; + var PLUS_LITERAL = "\\+"; + var QMARK_LITERAL = "\\?"; + var SLASH_LITERAL = "\\/"; + var ONE_CHAR = "(?=.)"; + var QMARK = "[^/]"; + var END_ANCHOR = `(?:${SLASH_LITERAL}|$)`; + var START_ANCHOR = `(?:^|${SLASH_LITERAL})`; + var DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`; + var NO_DOT = `(?!${DOT_LITERAL})`; + var NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`; + var NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`; + var NO_DOTS_SLASH = `(?!${DOTS_SLASH})`; + var QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`; + var STAR = `${QMARK}*?`; + var SEP = "/"; + var POSIX_CHARS = { + DOT_LITERAL, + PLUS_LITERAL, + QMARK_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + QMARK, + END_ANCHOR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK_NO_DOT, + STAR, + START_ANCHOR, + SEP + }; + var WINDOWS_CHARS = { + ...POSIX_CHARS, + SLASH_LITERAL: `[${WIN_SLASH}]`, + QMARK: WIN_NO_SLASH, + STAR: `${WIN_NO_SLASH}*?`, + DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`, + NO_DOT: `(?!${DOT_LITERAL})`, + NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`, + NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, + QMARK_NO_DOT: `[^.${WIN_SLASH}]`, + START_ANCHOR: `(?:^|[${WIN_SLASH}])`, + END_ANCHOR: `(?:[${WIN_SLASH}]|$)`, + SEP: "\\" + }; + var POSIX_REGEX_SOURCE = { + __proto__: null, + alnum: "a-zA-Z0-9", + alpha: "a-zA-Z", + ascii: "\\x00-\\x7F", + blank: " \\t", + cntrl: "\\x00-\\x1F\\x7F", + digit: "0-9", + graph: "\\x21-\\x7E", + lower: "a-z", + print: "\\x20-\\x7E ", + punct: "\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~", + space: " \\t\\r\\n\\v\\f", + upper: "A-Z", + word: "A-Za-z0-9_", + xdigit: "A-Fa-f0-9" + }; + module3.exports = { + DEFAULT_MAX_EXTGLOB_RECURSION, + MAX_LENGTH: 1024 * 64, + POSIX_REGEX_SOURCE, + // regular expressions + REGEX_BACKSLASH: /\\(?![*+?^${}(|)[\]])/g, + REGEX_NON_SPECIAL_CHARS: /^[^@![\].,$*+?^{}()|\\/]+/, + REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\]]/, + REGEX_SPECIAL_CHARS_BACKREF: /(\\?)((\W)(\3*))/g, + REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\]])/g, + REGEX_REMOVE_BACKSLASH: /(?:\[.*?[^\\]\]|\\(?=.))/g, + // Replace globs with equivalent patterns to reduce parsing time. + REPLACEMENTS: { + __proto__: null, + "***": "*", + "**/**": "**", + "**/**/**": "**" + }, + // Digits + CHAR_0: 48, + /* 0 */ + CHAR_9: 57, + /* 9 */ + // Alphabet chars. + CHAR_UPPERCASE_A: 65, + /* A */ + CHAR_LOWERCASE_A: 97, + /* a */ + CHAR_UPPERCASE_Z: 90, + /* Z */ + CHAR_LOWERCASE_Z: 122, + /* z */ + CHAR_LEFT_PARENTHESES: 40, + /* ( */ + CHAR_RIGHT_PARENTHESES: 41, + /* ) */ + CHAR_ASTERISK: 42, + /* * */ + // Non-alphabetic chars. + CHAR_AMPERSAND: 38, + /* & */ + CHAR_AT: 64, + /* @ */ + CHAR_BACKWARD_SLASH: 92, + /* \ */ + CHAR_CARRIAGE_RETURN: 13, + /* \r */ + CHAR_CIRCUMFLEX_ACCENT: 94, + /* ^ */ + CHAR_COLON: 58, + /* : */ + CHAR_COMMA: 44, + /* , */ + CHAR_DOT: 46, + /* . */ + CHAR_DOUBLE_QUOTE: 34, + /* " */ + CHAR_EQUAL: 61, + /* = */ + CHAR_EXCLAMATION_MARK: 33, + /* ! */ + CHAR_FORM_FEED: 12, + /* \f */ + CHAR_FORWARD_SLASH: 47, + /* / */ + CHAR_GRAVE_ACCENT: 96, + /* ` */ + CHAR_HASH: 35, + /* # */ + CHAR_HYPHEN_MINUS: 45, + /* - */ + CHAR_LEFT_ANGLE_BRACKET: 60, + /* < */ + CHAR_LEFT_CURLY_BRACE: 123, + /* { */ + CHAR_LEFT_SQUARE_BRACKET: 91, + /* [ */ + CHAR_LINE_FEED: 10, + /* \n */ + CHAR_NO_BREAK_SPACE: 160, + /* \u00A0 */ + CHAR_PERCENT: 37, + /* % */ + CHAR_PLUS: 43, + /* + */ + CHAR_QUESTION_MARK: 63, + /* ? */ + CHAR_RIGHT_ANGLE_BRACKET: 62, + /* > */ + CHAR_RIGHT_CURLY_BRACE: 125, + /* } */ + CHAR_RIGHT_SQUARE_BRACKET: 93, + /* ] */ + CHAR_SEMICOLON: 59, + /* ; */ + CHAR_SINGLE_QUOTE: 39, + /* ' */ + CHAR_SPACE: 32, + /* */ + CHAR_TAB: 9, + /* \t */ + CHAR_UNDERSCORE: 95, + /* _ */ + CHAR_VERTICAL_LINE: 124, + /* | */ + CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, + /* \uFEFF */ + /** + * Create EXTGLOB_CHARS + */ + extglobChars(chars) { + return { + "!": { type: "negate", open: "(?:(?!(?:", close: `))${chars.STAR})` }, + "?": { type: "qmark", open: "(?:", close: ")?" }, + "+": { type: "plus", open: "(?:", close: ")+" }, + "*": { type: "star", open: "(?:", close: ")*" }, + "@": { type: "at", open: "(?:", close: ")" } + }; + }, + /** + * Create GLOB_CHARS + */ + globChars(win32) { + return win32 === true ? WINDOWS_CHARS : POSIX_CHARS; + } + }; + } +}); + +// node_modules/picomatch/lib/utils.js +var require_utils2 = __commonJS({ + "node_modules/picomatch/lib/utils.js"(exports2) { + "use strict"; + var { + REGEX_BACKSLASH, + REGEX_REMOVE_BACKSLASH, + REGEX_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_GLOBAL + } = require_constants(); + exports2.isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val); + exports2.hasRegexChars = (str) => REGEX_SPECIAL_CHARS.test(str); + exports2.isRegexChar = (str) => str.length === 1 && exports2.hasRegexChars(str); + exports2.escapeRegex = (str) => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, "\\$1"); + exports2.toPosixSlashes = (str) => str.replace(REGEX_BACKSLASH, "/"); + exports2.isWindows = () => { + if (typeof navigator !== "undefined" && navigator.platform) { + const platform = navigator.platform.toLowerCase(); + return platform === "win32" || platform === "windows"; + } + if (typeof process !== "undefined" && process.platform) { + return process.platform === "win32"; + } + return false; + }; + exports2.removeBackslashes = (str) => { + return str.replace(REGEX_REMOVE_BACKSLASH, (match) => { + return match === "\\" ? "" : match; + }); + }; + exports2.escapeLast = (input, char, lastIdx) => { + const idx = input.lastIndexOf(char, lastIdx); + if (idx === -1) return input; + if (input[idx - 1] === "\\") return exports2.escapeLast(input, char, idx - 1); + return `${input.slice(0, idx)}\\${input.slice(idx)}`; + }; + exports2.removePrefix = (input, state = {}) => { + let output = input; + if (output.startsWith("./")) { + output = output.slice(2); + state.prefix = "./"; + } + return output; + }; + exports2.wrapOutput = (input, state = {}, options2 = {}) => { + const prepend = options2.contains ? "" : "^"; + const append = options2.contains ? "" : "$"; + let output = `${prepend}(?:${input})${append}`; + if (state.negated === true) { + output = `(?:^(?!${output}).*$)`; + } + return output; + }; + exports2.basename = (path6, { windows } = {}) => { + const segs = path6.split(windows ? /[\\/]/ : "/"); + const last = segs[segs.length - 1]; + if (last === "") { + return segs[segs.length - 2]; + } + return last; + }; + } +}); + +// node_modules/picomatch/lib/scan.js +var require_scan = __commonJS({ + "node_modules/picomatch/lib/scan.js"(exports2, module3) { + "use strict"; + var utils = require_utils2(); + var { + CHAR_ASTERISK, + /* * */ + CHAR_AT, + /* @ */ + CHAR_BACKWARD_SLASH, + /* \ */ + CHAR_COMMA, + /* , */ + CHAR_DOT, + /* . */ + CHAR_EXCLAMATION_MARK, + /* ! */ + CHAR_FORWARD_SLASH, + /* / */ + CHAR_LEFT_CURLY_BRACE, + /* { */ + CHAR_LEFT_PARENTHESES, + /* ( */ + CHAR_LEFT_SQUARE_BRACKET, + /* [ */ + CHAR_PLUS, + /* + */ + CHAR_QUESTION_MARK, + /* ? */ + CHAR_RIGHT_CURLY_BRACE, + /* } */ + CHAR_RIGHT_PARENTHESES, + /* ) */ + CHAR_RIGHT_SQUARE_BRACKET + /* ] */ + } = require_constants(); + var isPathSeparator = (code) => { + return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH; + }; + var depth = (token) => { + if (token.isPrefix !== true) { + token.depth = token.isGlobstar ? Infinity : 1; + } + }; + var scan = (input, options2) => { + const opts = options2 || {}; + const length = input.length - 1; + const scanToEnd = opts.parts === true || opts.scanToEnd === true; + const slashes = []; + const tokens = []; + const parts = []; + let str = input; + let index4 = -1; + let start = 0; + let lastIndex = 0; + let isBrace = false; + let isBracket = false; + let isGlob = false; + let isExtglob = false; + let isGlobstar = false; + let braceEscaped = false; + let backslashes = false; + let negated = false; + let negatedExtglob = false; + let finished = false; + let braces = 0; + let prev; + let code; + let token = { value: "", depth: 0, isGlob: false }; + const eos = () => index4 >= length; + const peek = () => str.charCodeAt(index4 + 1); + const advance = () => { + prev = code; + return str.charCodeAt(++index4); + }; + while (index4 < length) { + code = advance(); + let next; + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + if (code === CHAR_LEFT_CURLY_BRACE) { + braceEscaped = true; + } + continue; + } + if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) { + braces++; + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + if (code === CHAR_LEFT_CURLY_BRACE) { + braces++; + continue; + } + if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + if (scanToEnd === true) { + continue; + } + break; + } + if (braceEscaped !== true && code === CHAR_COMMA) { + isBrace = token.isBrace = true; + isGlob = token.isGlob = true; + finished = true; + if (scanToEnd === true) { + continue; + } + break; + } + if (code === CHAR_RIGHT_CURLY_BRACE) { + braces--; + if (braces === 0) { + braceEscaped = false; + isBrace = token.isBrace = true; + finished = true; + break; + } + } + } + if (scanToEnd === true) { + continue; + } + break; + } + if (code === CHAR_FORWARD_SLASH) { + slashes.push(index4); + tokens.push(token); + token = { value: "", depth: 0, isGlob: false }; + if (finished === true) continue; + if (prev === CHAR_DOT && index4 === start + 1) { + start += 2; + continue; + } + lastIndex = index4 + 1; + continue; + } + if (opts.noext !== true) { + const isExtglobChar = code === CHAR_PLUS || code === CHAR_AT || code === CHAR_ASTERISK || code === CHAR_QUESTION_MARK || code === CHAR_EXCLAMATION_MARK; + if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + isExtglob = token.isExtglob = true; + finished = true; + if (code === CHAR_EXCLAMATION_MARK && index4 === start) { + negatedExtglob = true; + } + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + if (code === CHAR_RIGHT_PARENTHESES) { + isGlob = token.isGlob = true; + finished = true; + break; + } + } + continue; + } + break; + } + } + if (code === CHAR_ASTERISK) { + if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true; + isGlob = token.isGlob = true; + finished = true; + if (scanToEnd === true) { + continue; + } + break; + } + if (code === CHAR_QUESTION_MARK) { + isGlob = token.isGlob = true; + finished = true; + if (scanToEnd === true) { + continue; + } + break; + } + if (code === CHAR_LEFT_SQUARE_BRACKET) { + while (eos() !== true && (next = advance())) { + if (next === CHAR_BACKWARD_SLASH) { + backslashes = token.backslashes = true; + advance(); + continue; + } + if (next === CHAR_RIGHT_SQUARE_BRACKET) { + isBracket = token.isBracket = true; + isGlob = token.isGlob = true; + finished = true; + break; + } + } + if (scanToEnd === true) { + continue; + } + break; + } + if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index4 === start) { + negated = token.negated = true; + start++; + continue; + } + if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) { + isGlob = token.isGlob = true; + if (scanToEnd === true) { + while (eos() !== true && (code = advance())) { + if (code === CHAR_LEFT_PARENTHESES) { + backslashes = token.backslashes = true; + code = advance(); + continue; + } + if (code === CHAR_RIGHT_PARENTHESES) { + finished = true; + break; + } + } + continue; + } + break; + } + if (isGlob === true) { + finished = true; + if (scanToEnd === true) { + continue; + } + break; + } + } + if (opts.noext === true) { + isExtglob = false; + isGlob = false; + } + let base = str; + let prefix = ""; + let glob = ""; + if (start > 0) { + prefix = str.slice(0, start); + str = str.slice(start); + lastIndex -= start; + } + if (base && isGlob === true && lastIndex > 0) { + base = str.slice(0, lastIndex); + glob = str.slice(lastIndex); + } else if (isGlob === true) { + base = ""; + glob = str; + } else { + base = str; + } + if (base && base !== "" && base !== "/" && base !== str) { + if (isPathSeparator(base.charCodeAt(base.length - 1))) { + base = base.slice(0, -1); + } + } + if (opts.unescape === true) { + if (glob) glob = utils.removeBackslashes(glob); + if (base && backslashes === true) { + base = utils.removeBackslashes(base); + } + } + const state = { + prefix, + input, + start, + base, + glob, + isBrace, + isBracket, + isGlob, + isExtglob, + isGlobstar, + negated, + negatedExtglob + }; + if (opts.tokens === true) { + state.maxDepth = 0; + if (!isPathSeparator(code)) { + tokens.push(token); + } + state.tokens = tokens; + } + if (opts.parts === true || opts.tokens === true) { + let prevIndex; + for (let idx = 0; idx < slashes.length; idx++) { + const n = prevIndex ? prevIndex + 1 : start; + const i = slashes[idx]; + const value = input.slice(n, i); + if (opts.tokens) { + if (idx === 0 && start !== 0) { + tokens[idx].isPrefix = true; + tokens[idx].value = prefix; + } else { + tokens[idx].value = value; + } + depth(tokens[idx]); + state.maxDepth += tokens[idx].depth; + } + if (idx !== 0 || value !== "") { + parts.push(value); + } + prevIndex = i; + } + if (prevIndex && prevIndex + 1 < input.length) { + const value = input.slice(prevIndex + 1); + parts.push(value); + if (opts.tokens) { + tokens[tokens.length - 1].value = value; + depth(tokens[tokens.length - 1]); + state.maxDepth += tokens[tokens.length - 1].depth; + } + } + state.slashes = slashes; + state.parts = parts; + } + return state; + }; + module3.exports = scan; + } +}); + +// node_modules/picomatch/lib/parse.js +var require_parse = __commonJS({ + "node_modules/picomatch/lib/parse.js"(exports2, module3) { + "use strict"; + var constants = require_constants(); + var utils = require_utils2(); + var { + MAX_LENGTH, + POSIX_REGEX_SOURCE, + REGEX_NON_SPECIAL_CHARS, + REGEX_SPECIAL_CHARS_BACKREF, + REPLACEMENTS + } = constants; + var expandRange = (args, options2) => { + if (typeof options2.expandRange === "function") { + return options2.expandRange(...args, options2); + } + args.sort(); + const value = `[${args.join("-")}]`; + try { + new RegExp(value); + } catch (ex) { + return args.map((v) => utils.escapeRegex(v)).join(".."); + } + return value; + }; + var syntaxError = (type2, char) => { + return `Missing ${type2}: "${char}" - use "\\\\${char}" to match literal characters`; + }; + var splitTopLevel = (input) => { + const parts = []; + let bracket = 0; + let paren = 0; + let quote2 = 0; + let value = ""; + let escaped = false; + for (const ch of input) { + if (escaped === true) { + value += ch; + escaped = false; + continue; + } + if (ch === "\\") { + value += ch; + escaped = true; + continue; + } + if (ch === '"') { + quote2 = quote2 === 1 ? 0 : 1; + value += ch; + continue; + } + if (quote2 === 0) { + if (ch === "[") { + bracket++; + } else if (ch === "]" && bracket > 0) { + bracket--; + } else if (bracket === 0) { + if (ch === "(") { + paren++; + } else if (ch === ")" && paren > 0) { + paren--; + } else if (ch === "|" && paren === 0) { + parts.push(value); + value = ""; + continue; + } + } + } + value += ch; + } + parts.push(value); + return parts; + }; + var isPlainBranch = (branch) => { + let escaped = false; + for (const ch of branch) { + if (escaped === true) { + escaped = false; + continue; + } + if (ch === "\\") { + escaped = true; + continue; + } + if (/[?*+@!()[\]{}]/.test(ch)) { + return false; + } + } + return true; + }; + var normalizeSimpleBranch = (branch) => { + let value = branch.trim(); + let changed = true; + while (changed === true) { + changed = false; + if (/^@\([^\\()[\]{}|]+\)$/.test(value)) { + value = value.slice(2, -1); + changed = true; + } + } + if (!isPlainBranch(value)) { + return; + } + return value.replace(/\\(.)/g, "$1"); + }; + var hasRepeatedCharPrefixOverlap = (branches) => { + const values = branches.map(normalizeSimpleBranch).filter(Boolean); + for (let i = 0; i < values.length; i++) { + for (let j = i + 1; j < values.length; j++) { + const a = values[i]; + const b = values[j]; + const char = a[0]; + if (!char || a !== char.repeat(a.length) || b !== char.repeat(b.length)) { + continue; + } + if (a === b || a.startsWith(b) || b.startsWith(a)) { + return true; + } + } + } + return false; + }; + var parseRepeatedExtglob = (pattern, requireEnd = true) => { + if (pattern[0] !== "+" && pattern[0] !== "*" || pattern[1] !== "(") { + return; + } + let bracket = 0; + let paren = 0; + let quote2 = 0; + let escaped = false; + for (let i = 1; i < pattern.length; i++) { + const ch = pattern[i]; + if (escaped === true) { + escaped = false; + continue; + } + if (ch === "\\") { + escaped = true; + continue; + } + if (ch === '"') { + quote2 = quote2 === 1 ? 0 : 1; + continue; + } + if (quote2 === 1) { + continue; + } + if (ch === "[") { + bracket++; + continue; + } + if (ch === "]" && bracket > 0) { + bracket--; + continue; + } + if (bracket > 0) { + continue; + } + if (ch === "(") { + paren++; + continue; + } + if (ch === ")") { + paren--; + if (paren === 0) { + if (requireEnd === true && i !== pattern.length - 1) { + return; + } + return { + type: pattern[0], + body: pattern.slice(2, i), + end: i + }; + } + } + } + }; + var getStarExtglobSequenceOutput = (pattern) => { + let index4 = 0; + const chars = []; + while (index4 < pattern.length) { + const match = parseRepeatedExtglob(pattern.slice(index4), false); + if (!match || match.type !== "*") { + return; + } + const branches = splitTopLevel(match.body).map((branch2) => branch2.trim()); + if (branches.length !== 1) { + return; + } + const branch = normalizeSimpleBranch(branches[0]); + if (!branch || branch.length !== 1) { + return; + } + chars.push(branch); + index4 += match.end + 1; + } + if (chars.length < 1) { + return; + } + const source = chars.length === 1 ? utils.escapeRegex(chars[0]) : `[${chars.map((ch) => utils.escapeRegex(ch)).join("")}]`; + return `${source}*`; + }; + var repeatedExtglobRecursion = (pattern) => { + let depth = 0; + let value = pattern.trim(); + let match = parseRepeatedExtglob(value); + while (match) { + depth++; + value = match.body.trim(); + match = parseRepeatedExtglob(value); + } + return depth; + }; + var analyzeRepeatedExtglob = (body, options2) => { + if (options2.maxExtglobRecursion === false) { + return { risky: false }; + } + const max2 = typeof options2.maxExtglobRecursion === "number" ? options2.maxExtglobRecursion : constants.DEFAULT_MAX_EXTGLOB_RECURSION; + const branches = splitTopLevel(body).map((branch) => branch.trim()); + if (branches.length > 1) { + if (branches.some((branch) => branch === "") || branches.some((branch) => /^[*?]+$/.test(branch)) || hasRepeatedCharPrefixOverlap(branches)) { + return { risky: true }; + } + } + for (const branch of branches) { + const safeOutput = getStarExtglobSequenceOutput(branch); + if (safeOutput) { + return { risky: true, safeOutput }; + } + if (repeatedExtglobRecursion(branch) > max2) { + return { risky: true }; + } + } + return { risky: false }; + }; + var parse = (input, options2) => { + if (typeof input !== "string") { + throw new TypeError("Expected a string"); + } + input = REPLACEMENTS[input] || input; + const opts = { ...options2 }; + const max2 = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + let len = input.length; + if (len > max2) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max2}`); + } + const bos = { type: "bos", value: "", output: opts.prepend || "" }; + const tokens = [bos]; + const capture = opts.capture ? "" : "?:"; + const PLATFORM_CHARS = constants.globChars(opts.windows); + const EXTGLOB_CHARS = constants.extglobChars(PLATFORM_CHARS); + const { + DOT_LITERAL, + PLUS_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOT_SLASH, + NO_DOTS_SLASH, + QMARK, + QMARK_NO_DOT, + STAR, + START_ANCHOR + } = PLATFORM_CHARS; + const globstar = (opts2) => { + return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + const nodot = opts.dot ? "" : NO_DOT; + const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT; + let star = opts.bash === true ? globstar(opts) : STAR; + if (opts.capture) { + star = `(${star})`; + } + if (typeof opts.noext === "boolean") { + opts.noextglob = opts.noext; + } + const state = { + input, + index: -1, + start: 0, + dot: opts.dot === true, + consumed: "", + output: "", + prefix: "", + backtrack: false, + negated: false, + brackets: 0, + braces: 0, + parens: 0, + quotes: 0, + globstar: false, + tokens + }; + input = utils.removePrefix(input, state); + len = input.length; + const extglobs = []; + const braces = []; + const stack = []; + let prev = bos; + let value; + const eos = () => state.index === len - 1; + const peek = state.peek = (n = 1) => input[state.index + n]; + const advance = state.advance = () => input[++state.index] || ""; + const remaining = () => input.slice(state.index + 1); + const consume = (value2 = "", num = 0) => { + state.consumed += value2; + state.index += num; + }; + const append = (token) => { + state.output += token.output != null ? token.output : token.value; + consume(token.value); + }; + const negate = () => { + let count = 1; + while (peek() === "!" && (peek(2) !== "(" || peek(3) === "?")) { + advance(); + state.start++; + count++; + } + if (count % 2 === 0) { + return false; + } + state.negated = true; + state.start++; + return true; + }; + const increment = (type2) => { + state[type2]++; + stack.push(type2); + }; + const decrement = (type2) => { + state[type2]--; + stack.pop(); + }; + const push = (tok) => { + if (prev.type === "globstar") { + const isBrace = state.braces > 0 && (tok.type === "comma" || tok.type === "brace"); + const isExtglob = tok.extglob === true || extglobs.length && (tok.type === "pipe" || tok.type === "paren"); + if (tok.type !== "slash" && tok.type !== "paren" && !isBrace && !isExtglob) { + state.output = state.output.slice(0, -prev.output.length); + prev.type = "star"; + prev.value = "*"; + prev.output = star; + state.output += prev.output; + } + } + if (extglobs.length && tok.type !== "paren") { + extglobs[extglobs.length - 1].inner += tok.value; + } + if (tok.value || tok.output) append(tok); + if (prev && prev.type === "text" && tok.type === "text") { + prev.output = (prev.output || prev.value) + tok.value; + prev.value += tok.value; + return; + } + tok.prev = prev; + tokens.push(tok); + prev = tok; + }; + const extglobOpen = (type2, value2) => { + const token = { ...EXTGLOB_CHARS[value2], conditions: 1, inner: "" }; + token.prev = prev; + token.parens = state.parens; + token.output = state.output; + token.startIndex = state.index; + token.tokensIndex = tokens.length; + const output = (opts.capture ? "(" : "") + token.open; + increment("parens"); + push({ type: type2, value: value2, output: state.output ? "" : ONE_CHAR }); + push({ type: "paren", extglob: true, value: advance(), output }); + extglobs.push(token); + }; + const extglobClose = (token) => { + const literal9 = input.slice(token.startIndex, state.index + 1); + const body = input.slice(token.startIndex + 2, state.index); + const analysis = analyzeRepeatedExtglob(body, opts); + if ((token.type === "plus" || token.type === "star") && analysis.risky) { + const safeOutput = analysis.safeOutput ? (token.output ? "" : ONE_CHAR) + (opts.capture ? `(${analysis.safeOutput})` : analysis.safeOutput) : void 0; + const open = tokens[token.tokensIndex]; + open.type = "text"; + open.value = literal9; + open.output = safeOutput || utils.escapeRegex(literal9); + for (let i = token.tokensIndex + 1; i < tokens.length; i++) { + tokens[i].value = ""; + tokens[i].output = ""; + delete tokens[i].suffix; + } + state.output = token.output + open.output; + state.backtrack = true; + push({ type: "paren", extglob: true, value, output: "" }); + decrement("parens"); + return; + } + let output = token.close + (opts.capture ? ")" : ""); + let rest; + if (token.type === "negate") { + let extglobStar = star; + if (token.inner && token.inner.length > 1 && token.inner.includes("/")) { + extglobStar = globstar(opts); + } + if (extglobStar !== star || eos() || /^\)+$/.test(remaining())) { + output = token.close = `)$))${extglobStar}`; + } + if (token.inner.includes("*") && (rest = remaining()) && /^\.[^\\/.]+$/.test(rest)) { + const expression = parse(rest, { ...options2, fastpaths: false }).output; + output = token.close = `)${expression})${extglobStar})`; + } + if (token.prev.type === "bos") { + state.negatedExtglob = true; + } + } + push({ type: "paren", extglob: true, value, output }); + decrement("parens"); + }; + if (opts.fastpaths !== false && !/(^[*!]|[/()[\]{}"])/.test(input)) { + let backslashes = false; + let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m, esc, chars, first, rest, index4) => { + if (first === "\\") { + backslashes = true; + return m; + } + if (first === "?") { + if (esc) { + return esc + first + (rest ? QMARK.repeat(rest.length) : ""); + } + if (index4 === 0) { + return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : ""); + } + return QMARK.repeat(chars.length); + } + if (first === ".") { + return DOT_LITERAL.repeat(chars.length); + } + if (first === "*") { + if (esc) { + return esc + first + (rest ? star : ""); + } + return star; + } + return esc ? m : `\\${m}`; + }); + if (backslashes === true) { + if (opts.unescape === true) { + output = output.replace(/\\/g, ""); + } else { + output = output.replace(/\\+/g, (m) => { + return m.length % 2 === 0 ? "\\\\" : m ? "\\" : ""; + }); + } + } + if (output === input && opts.contains === true) { + state.output = input; + return state; + } + state.output = utils.wrapOutput(output, state, options2); + return state; + } + while (!eos()) { + value = advance(); + if (value === "\0") { + continue; + } + if (value === "\\") { + const next = peek(); + if (next === "/" && opts.bash !== true) { + continue; + } + if (next === "." || next === ";") { + continue; + } + if (!next) { + value += "\\"; + push({ type: "text", value }); + continue; + } + const match = /^\\+/.exec(remaining()); + let slashes = 0; + if (match && match[0].length > 2) { + slashes = match[0].length; + state.index += slashes; + if (slashes % 2 !== 0) { + value += "\\"; + } + } + if (opts.unescape === true) { + value = advance(); + } else { + value += advance(); + } + if (state.brackets === 0) { + push({ type: "text", value }); + continue; + } + } + if (state.brackets > 0 && (value !== "]" || prev.value === "[" || prev.value === "[^")) { + if (opts.posix !== false && value === ":") { + const inner = prev.value.slice(1); + if (inner.includes("[")) { + prev.posix = true; + if (inner.includes(":")) { + const idx = prev.value.lastIndexOf("["); + const pre = prev.value.slice(0, idx); + const rest2 = prev.value.slice(idx + 2); + const posix = POSIX_REGEX_SOURCE[rest2]; + if (posix) { + prev.value = pre + posix; + state.backtrack = true; + advance(); + if (!bos.output && tokens.indexOf(prev) === 1) { + bos.output = ONE_CHAR; + } + continue; + } + } + } + } + if (value === "[" && peek() !== ":" || value === "-" && peek() === "]") { + value = `\\${value}`; + } + if (value === "]" && (prev.value === "[" || prev.value === "[^")) { + value = `\\${value}`; + } + if (opts.posix === true && value === "!" && prev.value === "[") { + value = "^"; + } + prev.value += value; + append({ value }); + continue; + } + if (state.quotes === 1 && value !== '"') { + value = utils.escapeRegex(value); + prev.value += value; + append({ value }); + continue; + } + if (value === '"') { + state.quotes = state.quotes === 1 ? 0 : 1; + if (opts.keepQuotes === true) { + push({ type: "text", value }); + } + continue; + } + if (value === "(") { + increment("parens"); + push({ type: "paren", value }); + continue; + } + if (value === ")") { + if (state.parens === 0 && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError("opening", "(")); + } + const extglob = extglobs[extglobs.length - 1]; + if (extglob && state.parens === extglob.parens + 1) { + extglobClose(extglobs.pop()); + continue; + } + push({ type: "paren", value, output: state.parens ? ")" : "\\)" }); + decrement("parens"); + continue; + } + if (value === "[") { + if (opts.nobracket === true || !remaining().includes("]")) { + if (opts.nobracket !== true && opts.strictBrackets === true) { + throw new SyntaxError(syntaxError("closing", "]")); + } + value = `\\${value}`; + } else { + increment("brackets"); + } + push({ type: "bracket", value }); + continue; + } + if (value === "]") { + if (opts.nobracket === true || prev && prev.type === "bracket" && prev.value.length === 1) { + push({ type: "text", value, output: `\\${value}` }); + continue; + } + if (state.brackets === 0) { + if (opts.strictBrackets === true) { + throw new SyntaxError(syntaxError("opening", "[")); + } + push({ type: "text", value, output: `\\${value}` }); + continue; + } + decrement("brackets"); + const prevValue = prev.value.slice(1); + if (prev.posix !== true && prevValue[0] === "^" && !prevValue.includes("/")) { + value = `/${value}`; + } + prev.value += value; + append({ value }); + if (opts.literalBrackets === false || utils.hasRegexChars(prevValue)) { + continue; + } + const escaped = utils.escapeRegex(prev.value); + state.output = state.output.slice(0, -prev.value.length); + if (opts.literalBrackets === true) { + state.output += escaped; + prev.value = escaped; + continue; + } + prev.value = `(${capture}${escaped}|${prev.value})`; + state.output += prev.value; + continue; + } + if (value === "{" && opts.nobrace !== true) { + increment("braces"); + const open = { + type: "brace", + value, + output: "(", + outputIndex: state.output.length, + tokensIndex: state.tokens.length + }; + braces.push(open); + push(open); + continue; + } + if (value === "}") { + const brace = braces[braces.length - 1]; + if (opts.nobrace === true || !brace) { + push({ type: "text", value, output: value }); + continue; + } + let output = ")"; + if (brace.dots === true) { + const arr = tokens.slice(); + const range3 = []; + for (let i = arr.length - 1; i >= 0; i--) { + tokens.pop(); + if (arr[i].type === "brace") { + break; + } + if (arr[i].type !== "dots") { + range3.unshift(arr[i].value); + } + } + output = expandRange(range3, opts); + state.backtrack = true; + } + if (brace.comma !== true && brace.dots !== true) { + const out = state.output.slice(0, brace.outputIndex); + const toks = state.tokens.slice(brace.tokensIndex); + brace.value = brace.output = "\\{"; + value = output = "\\}"; + state.output = out; + for (const t of toks) { + state.output += t.output || t.value; + } + } + push({ type: "brace", value, output }); + decrement("braces"); + braces.pop(); + continue; + } + if (value === "|") { + if (extglobs.length > 0) { + extglobs[extglobs.length - 1].conditions++; + } + push({ type: "text", value }); + continue; + } + if (value === ",") { + let output = value; + const brace = braces[braces.length - 1]; + if (brace && stack[stack.length - 1] === "braces") { + brace.comma = true; + output = "|"; + } + push({ type: "comma", value, output }); + continue; + } + if (value === "/") { + if (prev.type === "dot" && state.index === state.start + 1) { + state.start = state.index + 1; + state.consumed = ""; + state.output = ""; + tokens.pop(); + prev = bos; + continue; + } + push({ type: "slash", value, output: SLASH_LITERAL }); + continue; + } + if (value === ".") { + if (state.braces > 0 && prev.type === "dot") { + if (prev.value === ".") prev.output = DOT_LITERAL; + const brace = braces[braces.length - 1]; + prev.type = "dots"; + prev.output += value; + prev.value += value; + brace.dots = true; + continue; + } + if (state.braces + state.parens === 0 && prev.type !== "bos" && prev.type !== "slash") { + push({ type: "text", value, output: DOT_LITERAL }); + continue; + } + push({ type: "dot", value, output: DOT_LITERAL }); + continue; + } + if (value === "?") { + const isGroup = prev && prev.value === "("; + if (!isGroup && opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { + extglobOpen("qmark", value); + continue; + } + if (prev && prev.type === "paren") { + const next = peek(); + let output = value; + if (prev.value === "(" && !/[!=<:]/.test(next) || next === "<" && !/<([!=]|\w+>)/.test(remaining())) { + output = `\\${value}`; + } + push({ type: "text", value, output }); + continue; + } + if (opts.dot !== true && (prev.type === "slash" || prev.type === "bos")) { + push({ type: "qmark", value, output: QMARK_NO_DOT }); + continue; + } + push({ type: "qmark", value, output: QMARK }); + continue; + } + if (value === "!") { + if (opts.noextglob !== true && peek() === "(") { + if (peek(2) !== "?" || !/[!=<:]/.test(peek(3))) { + extglobOpen("negate", value); + continue; + } + } + if (opts.nonegate !== true && state.index === 0) { + negate(); + continue; + } + } + if (value === "+") { + if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { + extglobOpen("plus", value); + continue; + } + if (prev && prev.value === "(" || opts.regex === false) { + push({ type: "plus", value, output: PLUS_LITERAL }); + continue; + } + if (prev && (prev.type === "bracket" || prev.type === "paren" || prev.type === "brace") || state.parens > 0) { + push({ type: "plus", value }); + continue; + } + push({ type: "plus", value: PLUS_LITERAL }); + continue; + } + if (value === "@") { + if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { + push({ type: "at", extglob: true, value, output: "" }); + continue; + } + push({ type: "text", value }); + continue; + } + if (value !== "*") { + if (value === "$" || value === "^") { + value = `\\${value}`; + } + const match = REGEX_NON_SPECIAL_CHARS.exec(remaining()); + if (match) { + value += match[0]; + state.index += match[0].length; + } + push({ type: "text", value }); + continue; + } + if (prev && (prev.type === "globstar" || prev.star === true)) { + prev.type = "star"; + prev.star = true; + prev.value += value; + prev.output = star; + state.backtrack = true; + state.globstar = true; + consume(value); + continue; + } + let rest = remaining(); + if (opts.noextglob !== true && /^\([^?]/.test(rest)) { + extglobOpen("star", value); + continue; + } + if (prev.type === "star") { + if (opts.noglobstar === true) { + consume(value); + continue; + } + const prior = prev.prev; + const before = prior.prev; + const isStart = prior.type === "slash" || prior.type === "bos"; + const afterStar = before && (before.type === "star" || before.type === "globstar"); + if (opts.bash === true && (!isStart || rest[0] && rest[0] !== "/")) { + push({ type: "star", value, output: "" }); + continue; + } + const isBrace = state.braces > 0 && (prior.type === "comma" || prior.type === "brace"); + const isExtglob = extglobs.length && (prior.type === "pipe" || prior.type === "paren"); + if (!isStart && prior.type !== "paren" && !isBrace && !isExtglob) { + push({ type: "star", value, output: "" }); + continue; + } + while (rest.slice(0, 3) === "/**") { + const after = input[state.index + 4]; + if (after && after !== "/") { + break; + } + rest = rest.slice(3); + consume("/**", 3); + } + if (prior.type === "bos" && eos()) { + prev.type = "globstar"; + prev.value += value; + prev.output = globstar(opts); + state.output = prev.output; + state.globstar = true; + consume(value); + continue; + } + if (prior.type === "slash" && prior.prev.type !== "bos" && !afterStar && eos()) { + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + prev.type = "globstar"; + prev.output = globstar(opts) + (opts.strictSlashes ? ")" : "|$)"); + prev.value += value; + state.globstar = true; + state.output += prior.output + prev.output; + consume(value); + continue; + } + if (prior.type === "slash" && prior.prev.type !== "bos" && rest[0] === "/") { + const end = rest[1] !== void 0 ? "|$" : ""; + state.output = state.output.slice(0, -(prior.output + prev.output).length); + prior.output = `(?:${prior.output}`; + prev.type = "globstar"; + prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`; + prev.value += value; + state.output += prior.output + prev.output; + state.globstar = true; + consume(value + advance()); + push({ type: "slash", value: "/", output: "" }); + continue; + } + if (prior.type === "bos" && rest[0] === "/") { + prev.type = "globstar"; + prev.value += value; + prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`; + state.output = prev.output; + state.globstar = true; + consume(value + advance()); + push({ type: "slash", value: "/", output: "" }); + continue; + } + state.output = state.output.slice(0, -prev.output.length); + prev.type = "globstar"; + prev.output = globstar(opts); + prev.value += value; + state.output += prev.output; + state.globstar = true; + consume(value); + continue; + } + const token = { type: "star", value, output: star }; + if (opts.bash === true) { + token.output = ".*?"; + if (prev.type === "bos" || prev.type === "slash") { + token.output = nodot + token.output; + } + push(token); + continue; + } + if (prev && (prev.type === "bracket" || prev.type === "paren") && opts.regex === true) { + token.output = value; + push(token); + continue; + } + if (state.index === state.start || prev.type === "slash" || prev.type === "dot") { + if (prev.type === "dot") { + state.output += NO_DOT_SLASH; + prev.output += NO_DOT_SLASH; + } else if (opts.dot === true) { + state.output += NO_DOTS_SLASH; + prev.output += NO_DOTS_SLASH; + } else { + state.output += nodot; + prev.output += nodot; + } + if (peek() !== "*") { + state.output += ONE_CHAR; + prev.output += ONE_CHAR; + } + } + push(token); + } + while (state.brackets > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "]")); + state.output = utils.escapeLast(state.output, "["); + decrement("brackets"); + } + while (state.parens > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", ")")); + state.output = utils.escapeLast(state.output, "("); + decrement("parens"); + } + while (state.braces > 0) { + if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "}")); + state.output = utils.escapeLast(state.output, "{"); + decrement("braces"); + } + if (opts.strictSlashes !== true && (prev.type === "star" || prev.type === "bracket")) { + push({ type: "maybe_slash", value: "", output: `${SLASH_LITERAL}?` }); + } + if (state.backtrack === true) { + state.output = ""; + for (const token of state.tokens) { + state.output += token.output != null ? token.output : token.value; + if (token.suffix) { + state.output += token.suffix; + } + } + } + return state; + }; + parse.fastpaths = (input, options2) => { + const opts = { ...options2 }; + const max2 = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; + const len = input.length; + if (len > max2) { + throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max2}`); + } + input = REPLACEMENTS[input] || input; + const { + DOT_LITERAL, + SLASH_LITERAL, + ONE_CHAR, + DOTS_SLASH, + NO_DOT, + NO_DOTS, + NO_DOTS_SLASH, + STAR, + START_ANCHOR + } = constants.globChars(opts.windows); + const nodot = opts.dot ? NO_DOTS : NO_DOT; + const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT; + const capture = opts.capture ? "" : "?:"; + const state = { negated: false, prefix: "" }; + let star = opts.bash === true ? ".*?" : STAR; + if (opts.capture) { + star = `(${star})`; + } + const globstar = (opts2) => { + if (opts2.noglobstar === true) return star; + return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; + }; + const create = (str) => { + switch (str) { + case "*": + return `${nodot}${ONE_CHAR}${star}`; + case ".*": + return `${DOT_LITERAL}${ONE_CHAR}${star}`; + case "*.*": + return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + case "*/*": + return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`; + case "**": + return nodot + globstar(opts); + case "**/*": + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`; + case "**/*.*": + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; + case "**/.*": + return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`; + default: { + const match = /^(.*?)\.(\w+)$/.exec(str); + if (!match) return; + const source2 = create(match[1]); + if (!source2) return; + return source2 + DOT_LITERAL + match[2]; + } + } + }; + const output = utils.removePrefix(input, state); + let source = create(output); + if (source && opts.strictSlashes !== true) { + source += `${SLASH_LITERAL}?`; + } + return source; + }; + module3.exports = parse; + } +}); + +// node_modules/picomatch/lib/picomatch.js +var require_picomatch = __commonJS({ + "node_modules/picomatch/lib/picomatch.js"(exports2, module3) { + "use strict"; + var scan = require_scan(); + var parse = require_parse(); + var utils = require_utils2(); + var constants = require_constants(); + var isObject2 = (val) => val && typeof val === "object" && !Array.isArray(val); + var picomatch2 = (glob, options2, returnState = false) => { + if (Array.isArray(glob)) { + const fns = glob.map((input) => picomatch2(input, options2, returnState)); + const arrayMatcher = (str) => { + for (const isMatch of fns) { + const state2 = isMatch(str); + if (state2) return state2; + } + return false; + }; + return arrayMatcher; + } + const isState = isObject2(glob) && glob.tokens && glob.input; + if (glob === "" || typeof glob !== "string" && !isState) { + throw new TypeError("Expected pattern to be a non-empty string"); + } + const opts = options2 || {}; + const posix = opts.windows; + const regex = isState ? picomatch2.compileRe(glob, options2) : picomatch2.makeRe(glob, options2, false, true); + const state = regex.state; + delete regex.state; + let isIgnored = () => false; + if (opts.ignore) { + const ignoreOpts = { ...options2, ignore: null, onMatch: null, onResult: null }; + isIgnored = picomatch2(opts.ignore, ignoreOpts, returnState); + } + const matcher = (input, returnObject = false) => { + const { isMatch, match, output } = picomatch2.test(input, regex, options2, { glob, posix }); + const result = { glob, state, regex, posix, input, output, match, isMatch }; + if (typeof opts.onResult === "function") { + opts.onResult(result); + } + if (isMatch === false) { + result.isMatch = false; + return returnObject ? result : false; + } + if (isIgnored(input)) { + if (typeof opts.onIgnore === "function") { + opts.onIgnore(result); + } + result.isMatch = false; + return returnObject ? result : false; + } + if (typeof opts.onMatch === "function") { + opts.onMatch(result); + } + return returnObject ? result : true; + }; + if (returnState) { + matcher.state = state; + } + return matcher; + }; + picomatch2.test = (input, regex, options2, { glob, posix } = {}) => { + if (typeof input !== "string") { + throw new TypeError("Expected input to be a string"); + } + if (input === "") { + return { isMatch: false, output: "" }; + } + const opts = options2 || {}; + const format = opts.format || (posix ? utils.toPosixSlashes : null); + let match = input === glob; + let output = match && format ? format(input) : input; + if (match === false) { + output = format ? format(input) : input; + match = output === glob; + } + if (match === false || opts.capture === true) { + if (opts.matchBase === true || opts.basename === true) { + match = picomatch2.matchBase(input, regex, options2, posix); + } else { + match = regex.exec(output); + } + } + return { isMatch: Boolean(match), match, output }; + }; + picomatch2.matchBase = (input, glob, options2) => { + const regex = glob instanceof RegExp ? glob : picomatch2.makeRe(glob, options2); + return regex.test(utils.basename(input)); + }; + picomatch2.isMatch = (str, patterns, options2) => picomatch2(patterns, options2)(str); + picomatch2.parse = (pattern, options2) => { + if (Array.isArray(pattern)) return pattern.map((p) => picomatch2.parse(p, options2)); + return parse(pattern, { ...options2, fastpaths: false }); + }; + picomatch2.scan = (input, options2) => scan(input, options2); + picomatch2.compileRe = (state, options2, returnOutput = false, returnState = false) => { + if (returnOutput === true) { + return state.output; + } + const opts = options2 || {}; + const prepend = opts.contains ? "" : "^"; + const append = opts.contains ? "" : "$"; + let source = `${prepend}(?:${state.output})${append}`; + if (state && state.negated === true) { + source = `^(?!${source}).*$`; + } + const regex = picomatch2.toRegex(source, options2); + if (returnState === true) { + regex.state = state; + } + return regex; + }; + picomatch2.makeRe = (input, options2 = {}, returnOutput = false, returnState = false) => { + if (!input || typeof input !== "string") { + throw new TypeError("Expected a non-empty string"); + } + let parsed = { negated: false, fastpaths: true }; + if (options2.fastpaths !== false && (input[0] === "." || input[0] === "*")) { + parsed.output = parse.fastpaths(input, options2); + } + if (!parsed.output) { + parsed = parse(input, options2); + } + return picomatch2.compileRe(parsed, options2, returnOutput, returnState); + }; + picomatch2.toRegex = (source, options2) => { + try { + const opts = options2 || {}; + return new RegExp(source, opts.flags || (opts.nocase ? "i" : "")); + } catch (err) { + if (options2 && options2.debug === true) throw err; + return /$^/; + } + }; + picomatch2.constants = constants; + module3.exports = picomatch2; + } +}); + +// node_modules/picomatch/index.js +var require_picomatch2 = __commonJS({ + "node_modules/picomatch/index.js"(exports2, module3) { + "use strict"; + var pico = require_picomatch(); + var utils = require_utils2(); + function picomatch2(glob, options2, returnState = false) { + if (options2 && (options2.windows === null || options2.windows === void 0)) { + options2 = { ...options2, windows: utils.isWindows() }; + } + return pico(glob, options2, returnState); + } + Object.assign(picomatch2, pico); + module3.exports = picomatch2; + } +}); + +// node_modules/graceful-fs/polyfills.js +var require_polyfills = __commonJS({ + "node_modules/graceful-fs/polyfills.js"(exports2, module3) { + var constants = require("constants"); + var origCwd = process.cwd; + var cwd = null; + var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform; + process.cwd = function() { + if (!cwd) + cwd = origCwd.call(process); + return cwd; + }; + try { + process.cwd(); + } catch (er) { + } + if (typeof process.chdir === "function") { + chdir = process.chdir; + process.chdir = function(d) { + cwd = null; + chdir.call(process, d); + }; + if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir); + } + var chdir; + module3.exports = patch; + function patch(fs2) { + if (constants.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) { + patchLchmod(fs2); + } + if (!fs2.lutimes) { + patchLutimes(fs2); + } + fs2.chown = chownFix(fs2.chown); + fs2.fchown = chownFix(fs2.fchown); + fs2.lchown = chownFix(fs2.lchown); + fs2.chmod = chmodFix(fs2.chmod); + fs2.fchmod = chmodFix(fs2.fchmod); + fs2.lchmod = chmodFix(fs2.lchmod); + fs2.chownSync = chownFixSync(fs2.chownSync); + fs2.fchownSync = chownFixSync(fs2.fchownSync); + fs2.lchownSync = chownFixSync(fs2.lchownSync); + fs2.chmodSync = chmodFixSync(fs2.chmodSync); + fs2.fchmodSync = chmodFixSync(fs2.fchmodSync); + fs2.lchmodSync = chmodFixSync(fs2.lchmodSync); + fs2.stat = statFix(fs2.stat); + fs2.fstat = statFix(fs2.fstat); + fs2.lstat = statFix(fs2.lstat); + fs2.statSync = statFixSync(fs2.statSync); + fs2.fstatSync = statFixSync(fs2.fstatSync); + fs2.lstatSync = statFixSync(fs2.lstatSync); + if (fs2.chmod && !fs2.lchmod) { + fs2.lchmod = function(path6, mode, cb) { + if (cb) process.nextTick(cb); + }; + fs2.lchmodSync = function() { + }; + } + if (fs2.chown && !fs2.lchown) { + fs2.lchown = function(path6, uid, gid, cb) { + if (cb) process.nextTick(cb); + }; + fs2.lchownSync = function() { + }; + } + if (platform === "win32") { + fs2.rename = typeof fs2.rename !== "function" ? fs2.rename : (function(fs$rename) { + function rename(from, to, cb) { + var start = Date.now(); + var backoff = 0; + fs$rename(from, to, function CB(er) { + if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) { + setTimeout(function() { + fs2.stat(to, function(stater, st) { + if (stater && stater.code === "ENOENT") + fs$rename(from, to, CB); + else + cb(er); + }); + }, backoff); + if (backoff < 100) + backoff += 10; + return; + } + if (cb) cb(er); + }); + } + if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename); + return rename; + })(fs2.rename); + } + fs2.read = typeof fs2.read !== "function" ? fs2.read : (function(fs$read) { + function read(fd, buffer, offset, length, position, callback_) { + var callback; + if (callback_ && typeof callback_ === "function") { + var eagCounter = 0; + callback = function(er, _, __) { + if (er && er.code === "EAGAIN" && eagCounter < 10) { + eagCounter++; + return fs$read.call(fs2, fd, buffer, offset, length, position, callback); + } + callback_.apply(this, arguments); + }; + } + return fs$read.call(fs2, fd, buffer, offset, length, position, callback); + } + if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read); + return read; + })(fs2.read); + fs2.readSync = typeof fs2.readSync !== "function" ? fs2.readSync : /* @__PURE__ */ (function(fs$readSync) { + return function(fd, buffer, offset, length, position) { + var eagCounter = 0; + while (true) { + try { + return fs$readSync.call(fs2, fd, buffer, offset, length, position); + } catch (er) { + if (er.code === "EAGAIN" && eagCounter < 10) { + eagCounter++; + continue; + } + throw er; + } + } + }; + })(fs2.readSync); + function patchLchmod(fs3) { + fs3.lchmod = function(path6, mode, callback) { + fs3.open( + path6, + constants.O_WRONLY | constants.O_SYMLINK, + mode, + function(err, fd) { + if (err) { + if (callback) callback(err); + return; + } + fs3.fchmod(fd, mode, function(err2) { + fs3.close(fd, function(err22) { + if (callback) callback(err2 || err22); + }); + }); + } + ); + }; + fs3.lchmodSync = function(path6, mode) { + var fd = fs3.openSync(path6, constants.O_WRONLY | constants.O_SYMLINK, mode); + var threw = true; + var ret; + try { + ret = fs3.fchmodSync(fd, mode); + threw = false; + } finally { + if (threw) { + try { + fs3.closeSync(fd); + } catch (er) { + } + } else { + fs3.closeSync(fd); + } + } + return ret; + }; + } + function patchLutimes(fs3) { + if (constants.hasOwnProperty("O_SYMLINK") && fs3.futimes) { + fs3.lutimes = function(path6, at, mt, cb) { + fs3.open(path6, constants.O_SYMLINK, function(er, fd) { + if (er) { + if (cb) cb(er); + return; + } + fs3.futimes(fd, at, mt, function(er2) { + fs3.close(fd, function(er22) { + if (cb) cb(er2 || er22); + }); + }); + }); + }; + fs3.lutimesSync = function(path6, at, mt) { + var fd = fs3.openSync(path6, constants.O_SYMLINK); + var ret; + var threw = true; + try { + ret = fs3.futimesSync(fd, at, mt); + threw = false; + } finally { + if (threw) { + try { + fs3.closeSync(fd); + } catch (er) { + } + } else { + fs3.closeSync(fd); + } + } + return ret; + }; + } else if (fs3.futimes) { + fs3.lutimes = function(_a, _b, _c, cb) { + if (cb) process.nextTick(cb); + }; + fs3.lutimesSync = function() { + }; + } + } + function chmodFix(orig) { + if (!orig) return orig; + return function(target, mode, cb) { + return orig.call(fs2, target, mode, function(er) { + if (chownErOk(er)) er = null; + if (cb) cb.apply(this, arguments); + }); + }; + } + function chmodFixSync(orig) { + if (!orig) return orig; + return function(target, mode) { + try { + return orig.call(fs2, target, mode); + } catch (er) { + if (!chownErOk(er)) throw er; + } + }; + } + function chownFix(orig) { + if (!orig) return orig; + return function(target, uid, gid, cb) { + return orig.call(fs2, target, uid, gid, function(er) { + if (chownErOk(er)) er = null; + if (cb) cb.apply(this, arguments); + }); + }; + } + function chownFixSync(orig) { + if (!orig) return orig; + return function(target, uid, gid) { + try { + return orig.call(fs2, target, uid, gid); + } catch (er) { + if (!chownErOk(er)) throw er; + } + }; + } + function statFix(orig) { + if (!orig) return orig; + return function(target, options2, cb) { + if (typeof options2 === "function") { + cb = options2; + options2 = null; + } + function callback(er, stats) { + if (stats) { + if (stats.uid < 0) stats.uid += 4294967296; + if (stats.gid < 0) stats.gid += 4294967296; + } + if (cb) cb.apply(this, arguments); + } + return options2 ? orig.call(fs2, target, options2, callback) : orig.call(fs2, target, callback); + }; + } + function statFixSync(orig) { + if (!orig) return orig; + return function(target, options2) { + var stats = options2 ? orig.call(fs2, target, options2) : orig.call(fs2, target); + if (stats) { + if (stats.uid < 0) stats.uid += 4294967296; + if (stats.gid < 0) stats.gid += 4294967296; + } + return stats; + }; + } + function chownErOk(er) { + if (!er) + return true; + if (er.code === "ENOSYS") + return true; + var nonroot = !process.getuid || process.getuid() !== 0; + if (nonroot) { + if (er.code === "EINVAL" || er.code === "EPERM") + return true; + } + return false; + } + } + } +}); + +// node_modules/graceful-fs/legacy-streams.js +var require_legacy_streams = __commonJS({ + "node_modules/graceful-fs/legacy-streams.js"(exports2, module3) { + var Stream = require("stream").Stream; + module3.exports = legacy; + function legacy(fs2) { + return { + ReadStream, + WriteStream + }; + function ReadStream(path6, options2) { + if (!(this instanceof ReadStream)) return new ReadStream(path6, options2); + Stream.call(this); + var self2 = this; + this.path = path6; + this.fd = null; + this.readable = true; + this.paused = false; + this.flags = "r"; + this.mode = 438; + this.bufferSize = 64 * 1024; + options2 = options2 || {}; + var keys = Object.keys(options2); + for (var index4 = 0, length = keys.length; index4 < length; index4++) { + var key2 = keys[index4]; + this[key2] = options2[key2]; + } + if (this.encoding) this.setEncoding(this.encoding); + if (this.start !== void 0) { + if ("number" !== typeof this.start) { + throw TypeError("start must be a Number"); + } + if (this.end === void 0) { + this.end = Infinity; + } else if ("number" !== typeof this.end) { + throw TypeError("end must be a Number"); + } + if (this.start > this.end) { + throw new Error("start must be <= end"); + } + this.pos = this.start; + } + if (this.fd !== null) { + process.nextTick(function() { + self2._read(); + }); + return; + } + fs2.open(this.path, this.flags, this.mode, function(err, fd) { + if (err) { + self2.emit("error", err); + self2.readable = false; + return; + } + self2.fd = fd; + self2.emit("open", fd); + self2._read(); + }); + } + function WriteStream(path6, options2) { + if (!(this instanceof WriteStream)) return new WriteStream(path6, options2); + Stream.call(this); + this.path = path6; + this.fd = null; + this.writable = true; + this.flags = "w"; + this.encoding = "binary"; + this.mode = 438; + this.bytesWritten = 0; + options2 = options2 || {}; + var keys = Object.keys(options2); + for (var index4 = 0, length = keys.length; index4 < length; index4++) { + var key2 = keys[index4]; + this[key2] = options2[key2]; + } + if (this.start !== void 0) { + if ("number" !== typeof this.start) { + throw TypeError("start must be a Number"); + } + if (this.start < 0) { + throw new Error("start must be >= zero"); + } + this.pos = this.start; + } + this.busy = false; + this._queue = []; + if (this.fd === null) { + this._open = fs2.open; + this._queue.push([this._open, this.path, this.flags, this.mode, void 0]); + this.flush(); + } + } + } + } +}); + +// node_modules/graceful-fs/clone.js +var require_clone = __commonJS({ + "node_modules/graceful-fs/clone.js"(exports2, module3) { + "use strict"; + module3.exports = clone; + var getPrototypeOf = Object.getPrototypeOf || function(obj) { + return obj.__proto__; + }; + function clone(obj) { + if (obj === null || typeof obj !== "object") + return obj; + if (obj instanceof Object) + var copy = { __proto__: getPrototypeOf(obj) }; + else + var copy = /* @__PURE__ */ Object.create(null); + Object.getOwnPropertyNames(obj).forEach(function(key2) { + Object.defineProperty(copy, key2, Object.getOwnPropertyDescriptor(obj, key2)); + }); + return copy; + } + } +}); + +// node_modules/graceful-fs/graceful-fs.js +var require_graceful_fs = __commonJS({ + "node_modules/graceful-fs/graceful-fs.js"(exports2, module3) { + var fs2 = require("fs"); + var polyfills = require_polyfills(); + var legacy = require_legacy_streams(); + var clone = require_clone(); + var util = require("util"); + var gracefulQueue; + var previousSymbol; + if (typeof Symbol === "function" && typeof Symbol.for === "function") { + gracefulQueue = Symbol.for("graceful-fs.queue"); + previousSymbol = Symbol.for("graceful-fs.previous"); + } else { + gracefulQueue = "___graceful-fs.queue"; + previousSymbol = "___graceful-fs.previous"; + } + function noop6() { + } + function publishQueue(context, queue2) { + Object.defineProperty(context, gracefulQueue, { + get: function() { + return queue2; + } + }); + } + var debug = noop6; + if (util.debuglog) + debug = util.debuglog("gfs4"); + else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) + debug = function() { + var m = util.format.apply(util, arguments); + m = "GFS4: " + m.split(/\n/).join("\nGFS4: "); + console.error(m); + }; + if (!fs2[gracefulQueue]) { + queue = global[gracefulQueue] || []; + publishQueue(fs2, queue); + fs2.close = (function(fs$close) { + function close(fd, cb) { + return fs$close.call(fs2, fd, function(err) { + if (!err) { + resetQueue(); + } + if (typeof cb === "function") + cb.apply(this, arguments); + }); + } + Object.defineProperty(close, previousSymbol, { + value: fs$close + }); + return close; + })(fs2.close); + fs2.closeSync = (function(fs$closeSync) { + function closeSync(fd) { + fs$closeSync.apply(fs2, arguments); + resetQueue(); + } + Object.defineProperty(closeSync, previousSymbol, { + value: fs$closeSync + }); + return closeSync; + })(fs2.closeSync); + if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) { + process.on("exit", function() { + debug(fs2[gracefulQueue]); + require("assert").equal(fs2[gracefulQueue].length, 0); + }); + } + } + var queue; + if (!global[gracefulQueue]) { + publishQueue(global, fs2[gracefulQueue]); + } + module3.exports = patch(clone(fs2)); + if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs2.__patched) { + module3.exports = patch(fs2); + fs2.__patched = true; + } + function patch(fs3) { + polyfills(fs3); + fs3.gracefulify = patch; + fs3.createReadStream = createReadStream; + fs3.createWriteStream = createWriteStream; + var fs$readFile = fs3.readFile; + fs3.readFile = readFile; + function readFile(path6, options2, cb) { + if (typeof options2 === "function") + cb = options2, options2 = null; + return go$readFile(path6, options2, cb); + function go$readFile(path7, options3, cb2, startTime) { + return fs$readFile(path7, options3, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([go$readFile, [path7, options3, cb2], err, startTime || Date.now(), Date.now()]); + else { + if (typeof cb2 === "function") + cb2.apply(this, arguments); + } + }); + } + } + var fs$writeFile = fs3.writeFile; + fs3.writeFile = writeFile; + function writeFile(path6, data, options2, cb) { + if (typeof options2 === "function") + cb = options2, options2 = null; + return go$writeFile(path6, data, options2, cb); + function go$writeFile(path7, data2, options3, cb2, startTime) { + return fs$writeFile(path7, data2, options3, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([go$writeFile, [path7, data2, options3, cb2], err, startTime || Date.now(), Date.now()]); + else { + if (typeof cb2 === "function") + cb2.apply(this, arguments); + } + }); + } + } + var fs$appendFile = fs3.appendFile; + if (fs$appendFile) + fs3.appendFile = appendFile; + function appendFile(path6, data, options2, cb) { + if (typeof options2 === "function") + cb = options2, options2 = null; + return go$appendFile(path6, data, options2, cb); + function go$appendFile(path7, data2, options3, cb2, startTime) { + return fs$appendFile(path7, data2, options3, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([go$appendFile, [path7, data2, options3, cb2], err, startTime || Date.now(), Date.now()]); + else { + if (typeof cb2 === "function") + cb2.apply(this, arguments); + } + }); + } + } + var fs$copyFile = fs3.copyFile; + if (fs$copyFile) + fs3.copyFile = copyFile; + function copyFile(src, dest, flags, cb) { + if (typeof flags === "function") { + cb = flags; + flags = 0; + } + return go$copyFile(src, dest, flags, cb); + function go$copyFile(src2, dest2, flags2, cb2, startTime) { + return fs$copyFile(src2, dest2, flags2, function(err) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([go$copyFile, [src2, dest2, flags2, cb2], err, startTime || Date.now(), Date.now()]); + else { + if (typeof cb2 === "function") + cb2.apply(this, arguments); + } + }); + } + } + var fs$readdir = fs3.readdir; + fs3.readdir = readdir; + var noReaddirOptionVersions = /^v[0-5]\./; + function readdir(path6, options2, cb) { + if (typeof options2 === "function") + cb = options2, options2 = null; + var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path7, options3, cb2, startTime) { + return fs$readdir(path7, fs$readdirCallback( + path7, + options3, + cb2, + startTime + )); + } : function go$readdir2(path7, options3, cb2, startTime) { + return fs$readdir(path7, options3, fs$readdirCallback( + path7, + options3, + cb2, + startTime + )); + }; + return go$readdir(path6, options2, cb); + function fs$readdirCallback(path7, options3, cb2, startTime) { + return function(err, files) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([ + go$readdir, + [path7, options3, cb2], + err, + startTime || Date.now(), + Date.now() + ]); + else { + if (files && files.sort) + files.sort(); + if (typeof cb2 === "function") + cb2.call(this, err, files); + } + }; + } + } + if (process.version.substr(0, 4) === "v0.8") { + var legStreams = legacy(fs3); + ReadStream = legStreams.ReadStream; + WriteStream = legStreams.WriteStream; + } + var fs$ReadStream = fs3.ReadStream; + if (fs$ReadStream) { + ReadStream.prototype = Object.create(fs$ReadStream.prototype); + ReadStream.prototype.open = ReadStream$open; + } + var fs$WriteStream = fs3.WriteStream; + if (fs$WriteStream) { + WriteStream.prototype = Object.create(fs$WriteStream.prototype); + WriteStream.prototype.open = WriteStream$open; + } + Object.defineProperty(fs3, "ReadStream", { + get: function() { + return ReadStream; + }, + set: function(val) { + ReadStream = val; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(fs3, "WriteStream", { + get: function() { + return WriteStream; + }, + set: function(val) { + WriteStream = val; + }, + enumerable: true, + configurable: true + }); + var FileReadStream = ReadStream; + Object.defineProperty(fs3, "FileReadStream", { + get: function() { + return FileReadStream; + }, + set: function(val) { + FileReadStream = val; + }, + enumerable: true, + configurable: true + }); + var FileWriteStream = WriteStream; + Object.defineProperty(fs3, "FileWriteStream", { + get: function() { + return FileWriteStream; + }, + set: function(val) { + FileWriteStream = val; + }, + enumerable: true, + configurable: true + }); + function ReadStream(path6, options2) { + if (this instanceof ReadStream) + return fs$ReadStream.apply(this, arguments), this; + else + return ReadStream.apply(Object.create(ReadStream.prototype), arguments); + } + function ReadStream$open() { + var that = this; + open(that.path, that.flags, that.mode, function(err, fd) { + if (err) { + if (that.autoClose) + that.destroy(); + that.emit("error", err); + } else { + that.fd = fd; + that.emit("open", fd); + that.read(); + } + }); + } + function WriteStream(path6, options2) { + if (this instanceof WriteStream) + return fs$WriteStream.apply(this, arguments), this; + else + return WriteStream.apply(Object.create(WriteStream.prototype), arguments); + } + function WriteStream$open() { + var that = this; + open(that.path, that.flags, that.mode, function(err, fd) { + if (err) { + that.destroy(); + that.emit("error", err); + } else { + that.fd = fd; + that.emit("open", fd); + } + }); + } + function createReadStream(path6, options2) { + return new fs3.ReadStream(path6, options2); + } + function createWriteStream(path6, options2) { + return new fs3.WriteStream(path6, options2); + } + var fs$open = fs3.open; + fs3.open = open; + function open(path6, flags, mode, cb) { + if (typeof mode === "function") + cb = mode, mode = null; + return go$open(path6, flags, mode, cb); + function go$open(path7, flags2, mode2, cb2, startTime) { + return fs$open(path7, flags2, mode2, function(err, fd) { + if (err && (err.code === "EMFILE" || err.code === "ENFILE")) + enqueue([go$open, [path7, flags2, mode2, cb2], err, startTime || Date.now(), Date.now()]); + else { + if (typeof cb2 === "function") + cb2.apply(this, arguments); + } + }); + } + } + return fs3; + } + function enqueue(elem) { + debug("ENQUEUE", elem[0].name, elem[1]); + fs2[gracefulQueue].push(elem); + retry(); + } + var retryTimer; + function resetQueue() { + var now = Date.now(); + for (var i = 0; i < fs2[gracefulQueue].length; ++i) { + if (fs2[gracefulQueue][i].length > 2) { + fs2[gracefulQueue][i][3] = now; + fs2[gracefulQueue][i][4] = now; + } + } + retry(); + } + function retry() { + clearTimeout(retryTimer); + retryTimer = void 0; + if (fs2[gracefulQueue].length === 0) + return; + var elem = fs2[gracefulQueue].shift(); + var fn = elem[0]; + var args = elem[1]; + var err = elem[2]; + var startTime = elem[3]; + var lastTime = elem[4]; + if (startTime === void 0) { + debug("RETRY", fn.name, args); + fn.apply(null, args); + } else if (Date.now() - startTime >= 6e4) { + debug("TIMEOUT", fn.name, args); + var cb = args.pop(); + if (typeof cb === "function") + cb.call(null, err); + } else { + var sinceAttempt = Date.now() - lastTime; + var sinceStart = Math.max(lastTime - startTime, 1); + var desiredDelay = Math.min(sinceStart * 1.2, 100); + if (sinceAttempt >= desiredDelay) { + debug("RETRY", fn.name, args); + fn.apply(null, args.concat([startTime])); + } else { + fs2[gracefulQueue].push(elem); + } + } + if (retryTimer === void 0) { + retryTimer = setTimeout(retry, 0); + } + } + } +}); + +// node_modules/file-type/index.js +var require_file_type = __commonJS({ + "node_modules/file-type/index.js"(exports2, module3) { + "use strict"; + module3.exports = (input) => { + const buf = new Uint8Array(input); + if (!(buf && buf.length > 1)) { + return null; + } + const check = (header, opts) => { + opts = Object.assign({ + offset: 0 + }, opts); + for (let i = 0; i < header.length; i++) { + if (header[i] !== buf[i + opts.offset]) { + return false; + } + } + return true; + }; + if (check([255, 216, 255])) { + return { + ext: "jpg", + mime: "image/jpeg" + }; + } + if (check([137, 80, 78, 71, 13, 10, 26, 10])) { + return { + ext: "png", + mime: "image/png" + }; + } + if (check([71, 73, 70])) { + return { + ext: "gif", + mime: "image/gif" + }; + } + if (check([87, 69, 66, 80], { offset: 8 })) { + return { + ext: "webp", + mime: "image/webp" + }; + } + if (check([70, 76, 73, 70])) { + return { + ext: "flif", + mime: "image/flif" + }; + } + if ((check([73, 73, 42, 0]) || check([77, 77, 0, 42])) && check([67, 82], { offset: 8 })) { + return { + ext: "cr2", + mime: "image/x-canon-cr2" + }; + } + if (check([73, 73, 42, 0]) || check([77, 77, 0, 42])) { + return { + ext: "tif", + mime: "image/tiff" + }; + } + if (check([66, 77])) { + return { + ext: "bmp", + mime: "image/bmp" + }; + } + if (check([73, 73, 188])) { + return { + ext: "jxr", + mime: "image/vnd.ms-photo" + }; + } + if (check([56, 66, 80, 83])) { + return { + ext: "psd", + mime: "image/vnd.adobe.photoshop" + }; + } + if (check([80, 75, 3, 4]) && check([109, 105, 109, 101, 116, 121, 112, 101, 97, 112, 112, 108, 105, 99, 97, 116, 105, 111, 110, 47, 101, 112, 117, 98, 43, 122, 105, 112], { offset: 30 })) { + return { + ext: "epub", + mime: "application/epub+zip" + }; + } + if (check([80, 75, 3, 4]) && check([77, 69, 84, 65, 45, 73, 78, 70, 47, 109, 111, 122, 105, 108, 108, 97, 46, 114, 115, 97], { offset: 30 })) { + return { + ext: "xpi", + mime: "application/x-xpinstall" + }; + } + if (check([80, 75]) && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { + return { + ext: "zip", + mime: "application/zip" + }; + } + if (check([117, 115, 116, 97, 114], { offset: 257 })) { + return { + ext: "tar", + mime: "application/x-tar" + }; + } + if (check([82, 97, 114, 33, 26, 7]) && (buf[6] === 0 || buf[6] === 1)) { + return { + ext: "rar", + mime: "application/x-rar-compressed" + }; + } + if (check([31, 139, 8])) { + return { + ext: "gz", + mime: "application/gzip" + }; + } + if (check([66, 90, 104])) { + return { + ext: "bz2", + mime: "application/x-bzip2" + }; + } + if (check([55, 122, 188, 175, 39, 28])) { + return { + ext: "7z", + mime: "application/x-7z-compressed" + }; + } + if (check([120, 1])) { + return { + ext: "dmg", + mime: "application/x-apple-diskimage" + }; + } + if (check([0, 0, 0]) && (buf[3] === 24 || buf[3] === 32) && check([102, 116, 121, 112], { offset: 4 }) || check([51, 103, 112, 53]) || check([0, 0, 0, 28, 102, 116, 121, 112, 109, 112, 52, 50]) && check([109, 112, 52, 49, 109, 112, 52, 50, 105, 115, 111, 109], { offset: 16 }) || check([0, 0, 0, 28, 102, 116, 121, 112, 105, 115, 111, 109]) || check([0, 0, 0, 28, 102, 116, 121, 112, 109, 112, 52, 50, 0, 0, 0, 0])) { + return { + ext: "mp4", + mime: "video/mp4" + }; + } + if (check([0, 0, 0, 28, 102, 116, 121, 112, 77, 52, 86])) { + return { + ext: "m4v", + mime: "video/x-m4v" + }; + } + if (check([77, 84, 104, 100])) { + return { + ext: "mid", + mime: "audio/midi" + }; + } + if (check([26, 69, 223, 163])) { + const sliced = buf.subarray(4, 4 + 4096); + const idPos = sliced.findIndex((el, i, arr) => arr[i] === 66 && arr[i + 1] === 130); + if (idPos >= 0) { + const docTypePos = idPos + 3; + const findDocType = (type2) => Array.from(type2).every((c, i) => sliced[docTypePos + i] === c.charCodeAt(0)); + if (findDocType("matroska")) { + return { + ext: "mkv", + mime: "video/x-matroska" + }; + } + if (findDocType("webm")) { + return { + ext: "webm", + mime: "video/webm" + }; + } + } + } + if (check([0, 0, 0, 20, 102, 116, 121, 112, 113, 116, 32, 32]) || check([102, 114, 101, 101], { offset: 4 }) || check([102, 116, 121, 112, 113, 116, 32, 32], { offset: 4 }) || check([109, 100, 97, 116], { offset: 4 }) || // MJPEG + check([119, 105, 100, 101], { offset: 4 })) { + return { + ext: "mov", + mime: "video/quicktime" + }; + } + if (check([82, 73, 70, 70]) && check([65, 86, 73], { offset: 8 })) { + return { + ext: "avi", + mime: "video/x-msvideo" + }; + } + if (check([48, 38, 178, 117, 142, 102, 207, 17, 166, 217])) { + return { + ext: "wmv", + mime: "video/x-ms-wmv" + }; + } + if (check([0, 0, 1, 186])) { + return { + ext: "mpg", + mime: "video/mpeg" + }; + } + if (check([73, 68, 51]) || check([255, 251])) { + return { + ext: "mp3", + mime: "audio/mpeg" + }; + } + if (check([102, 116, 121, 112, 77, 52, 65], { offset: 4 }) || check([77, 52, 65, 32])) { + return { + ext: "m4a", + mime: "audio/m4a" + }; + } + if (check([79, 112, 117, 115, 72, 101, 97, 100], { offset: 28 })) { + return { + ext: "opus", + mime: "audio/opus" + }; + } + if (check([79, 103, 103, 83])) { + return { + ext: "ogg", + mime: "audio/ogg" + }; + } + if (check([102, 76, 97, 67])) { + return { + ext: "flac", + mime: "audio/x-flac" + }; + } + if (check([82, 73, 70, 70]) && check([87, 65, 86, 69], { offset: 8 })) { + return { + ext: "wav", + mime: "audio/x-wav" + }; + } + if (check([35, 33, 65, 77, 82, 10])) { + return { + ext: "amr", + mime: "audio/amr" + }; + } + if (check([37, 80, 68, 70])) { + return { + ext: "pdf", + mime: "application/pdf" + }; + } + if (check([77, 90])) { + return { + ext: "exe", + mime: "application/x-msdownload" + }; + } + if ((buf[0] === 67 || buf[0] === 70) && check([87, 83], { offset: 1 })) { + return { + ext: "swf", + mime: "application/x-shockwave-flash" + }; + } + if (check([123, 92, 114, 116, 102])) { + return { + ext: "rtf", + mime: "application/rtf" + }; + } + if (check([0, 97, 115, 109])) { + return { + ext: "wasm", + mime: "application/wasm" + }; + } + if (check([119, 79, 70, 70]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { + return { + ext: "woff", + mime: "font/woff" + }; + } + if (check([119, 79, 70, 50]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { + return { + ext: "woff2", + mime: "font/woff2" + }; + } + if (check([76, 80], { offset: 34 }) && (check([0, 0, 1], { offset: 8 }) || check([1, 0, 2], { offset: 8 }) || check([2, 0, 2], { offset: 8 }))) { + return { + ext: "eot", + mime: "application/octet-stream" + }; + } + if (check([0, 1, 0, 0, 0])) { + return { + ext: "ttf", + mime: "font/ttf" + }; + } + if (check([79, 84, 84, 79, 0])) { + return { + ext: "otf", + mime: "font/otf" + }; + } + if (check([0, 0, 1, 0])) { + return { + ext: "ico", + mime: "image/x-icon" + }; + } + if (check([70, 76, 86, 1])) { + return { + ext: "flv", + mime: "video/x-flv" + }; + } + if (check([37, 33])) { + return { + ext: "ps", + mime: "application/postscript" + }; + } + if (check([253, 55, 122, 88, 90, 0])) { + return { + ext: "xz", + mime: "application/x-xz" + }; + } + if (check([83, 81, 76, 105])) { + return { + ext: "sqlite", + mime: "application/x-sqlite3" + }; + } + if (check([78, 69, 83, 26])) { + return { + ext: "nes", + mime: "application/x-nintendo-nes-rom" + }; + } + if (check([67, 114, 50, 52])) { + return { + ext: "crx", + mime: "application/x-google-chrome-extension" + }; + } + if (check([77, 83, 67, 70]) || check([73, 83, 99, 40])) { + return { + ext: "cab", + mime: "application/vnd.ms-cab-compressed" + }; + } + if (check([33, 60, 97, 114, 99, 104, 62, 10, 100, 101, 98, 105, 97, 110, 45, 98, 105, 110, 97, 114, 121])) { + return { + ext: "deb", + mime: "application/x-deb" + }; + } + if (check([33, 60, 97, 114, 99, 104, 62])) { + return { + ext: "ar", + mime: "application/x-unix-archive" + }; + } + if (check([237, 171, 238, 219])) { + return { + ext: "rpm", + mime: "application/x-rpm" + }; + } + if (check([31, 160]) || check([31, 157])) { + return { + ext: "Z", + mime: "application/x-compress" + }; + } + if (check([76, 90, 73, 80])) { + return { + ext: "lz", + mime: "application/x-lzip" + }; + } + if (check([208, 207, 17, 224, 161, 177, 26, 225])) { + return { + ext: "msi", + mime: "application/x-msi" + }; + } + if (check([6, 14, 43, 52, 2, 5, 1, 1, 13, 1, 2, 1, 1, 2])) { + return { + ext: "mxf", + mime: "application/mxf" + }; + } + if (check([71], { offset: 4 }) && (check([71], { offset: 192 }) || check([71], { offset: 196 }))) { + return { + ext: "mts", + mime: "video/mp2t" + }; + } + if (check([66, 76, 69, 78, 68, 69, 82])) { + return { + ext: "blend", + mime: "application/x-blender" + }; + } + if (check([66, 80, 71, 251])) { + return { + ext: "bpg", + mime: "image/bpg" + }; + } + return null; + }; + } +}); + +// node_modules/is-stream/index.js +var require_is_stream = __commonJS({ + "node_modules/is-stream/index.js"(exports2, module3) { + "use strict"; + var isStream = module3.exports = function(stream2) { + return stream2 !== null && typeof stream2 === "object" && typeof stream2.pipe === "function"; + }; + isStream.writable = function(stream2) { + return isStream(stream2) && stream2.writable !== false && typeof stream2._write === "function" && typeof stream2._writableState === "object"; + }; + isStream.readable = function(stream2) { + return isStream(stream2) && stream2.readable !== false && typeof stream2._read === "function" && typeof stream2._readableState === "object"; + }; + isStream.duplex = function(stream2) { + return isStream.writable(stream2) && isStream.readable(stream2); + }; + isStream.transform = function(stream2) { + return isStream.duplex(stream2) && typeof stream2._transform === "function" && typeof stream2._transformState === "object"; + }; + } +}); + +// node_modules/process-nextick-args/index.js +var require_process_nextick_args = __commonJS({ + "node_modules/process-nextick-args/index.js"(exports2, module3) { + "use strict"; + if (typeof process === "undefined" || !process.version || process.version.indexOf("v0.") === 0 || process.version.indexOf("v1.") === 0 && process.version.indexOf("v1.8.") !== 0) { + module3.exports = { nextTick }; + } else { + module3.exports = process; + } + function nextTick(fn, arg1, arg2, arg3) { + if (typeof fn !== "function") { + throw new TypeError('"callback" argument must be a function'); + } + var len = arguments.length; + var args, i; + switch (len) { + case 0: + case 1: + return process.nextTick(fn); + case 2: + return process.nextTick(function afterTickOne() { + fn.call(null, arg1); + }); + case 3: + return process.nextTick(function afterTickTwo() { + fn.call(null, arg1, arg2); + }); + case 4: + return process.nextTick(function afterTickThree() { + fn.call(null, arg1, arg2, arg3); + }); + default: + args = new Array(len - 1); + i = 0; + while (i < args.length) { + args[i++] = arguments[i]; + } + return process.nextTick(function afterTick() { + fn.apply(null, args); + }); + } + } + } +}); + +// node_modules/isarray/index.js +var require_isarray = __commonJS({ + "node_modules/isarray/index.js"(exports2, module3) { + var toString = {}.toString; + module3.exports = Array.isArray || function(arr) { + return toString.call(arr) == "[object Array]"; + }; + } +}); + +// node_modules/readable-stream/lib/internal/streams/stream.js +var require_stream = __commonJS({ + "node_modules/readable-stream/lib/internal/streams/stream.js"(exports2, module3) { + module3.exports = require("stream"); + } +}); + +// node_modules/readable-stream/node_modules/safe-buffer/index.js +var require_safe_buffer = __commonJS({ + "node_modules/readable-stream/node_modules/safe-buffer/index.js"(exports2, module3) { + var buffer = require("buffer"); + var Buffer3 = buffer.Buffer; + function copyProps(src, dst) { + for (var key2 in src) { + dst[key2] = src[key2]; + } + } + if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { + module3.exports = buffer; + } else { + copyProps(buffer, exports2); + exports2.Buffer = SafeBuffer; + } + function SafeBuffer(arg, encodingOrOffset, length) { + return Buffer3(arg, encodingOrOffset, length); + } + copyProps(Buffer3, SafeBuffer); + SafeBuffer.from = function(arg, encodingOrOffset, length) { + if (typeof arg === "number") { + throw new TypeError("Argument must not be a number"); + } + return Buffer3(arg, encodingOrOffset, length); + }; + SafeBuffer.alloc = function(size, fill, encoding) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + var buf = Buffer3(size); + if (fill !== void 0) { + if (typeof encoding === "string") { + buf.fill(fill, encoding); + } else { + buf.fill(fill); + } + } else { + buf.fill(0); + } + return buf; + }; + SafeBuffer.allocUnsafe = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return Buffer3(size); + }; + SafeBuffer.allocUnsafeSlow = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return buffer.SlowBuffer(size); + }; + } +}); + +// node_modules/core-util-is/lib/util.js +var require_util = __commonJS({ + "node_modules/core-util-is/lib/util.js"(exports2) { + function isArray(arg) { + if (Array.isArray) { + return Array.isArray(arg); + } + return objectToString(arg) === "[object Array]"; + } + exports2.isArray = isArray; + function isBoolean(arg) { + return typeof arg === "boolean"; + } + exports2.isBoolean = isBoolean; + function isNull(arg) { + return arg === null; + } + exports2.isNull = isNull; + function isNullOrUndefined(arg) { + return arg == null; + } + exports2.isNullOrUndefined = isNullOrUndefined; + function isNumber(arg) { + return typeof arg === "number"; + } + exports2.isNumber = isNumber; + function isString(arg) { + return typeof arg === "string"; + } + exports2.isString = isString; + function isSymbol(arg) { + return typeof arg === "symbol"; + } + exports2.isSymbol = isSymbol; + function isUndefined(arg) { + return arg === void 0; + } + exports2.isUndefined = isUndefined; + function isRegExp(re) { + return objectToString(re) === "[object RegExp]"; + } + exports2.isRegExp = isRegExp; + function isObject2(arg) { + return typeof arg === "object" && arg !== null; + } + exports2.isObject = isObject2; + function isDate(d) { + return objectToString(d) === "[object Date]"; + } + exports2.isDate = isDate; + function isError(e) { + return objectToString(e) === "[object Error]" || e instanceof Error; + } + exports2.isError = isError; + function isFunction(arg) { + return typeof arg === "function"; + } + exports2.isFunction = isFunction; + function isPrimitive(arg) { + return arg === null || typeof arg === "boolean" || typeof arg === "number" || typeof arg === "string" || typeof arg === "symbol" || // ES6 symbol + typeof arg === "undefined"; + } + exports2.isPrimitive = isPrimitive; + exports2.isBuffer = require("buffer").Buffer.isBuffer; + function objectToString(o) { + return Object.prototype.toString.call(o); + } + } +}); + +// node_modules/inherits/inherits_browser.js +var require_inherits_browser = __commonJS({ + "node_modules/inherits/inherits_browser.js"(exports2, module3) { + if (typeof Object.create === "function") { + module3.exports = function inherits(ctor, superCtor) { + if (superCtor) { + ctor.super_ = superCtor; + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + } + }; + } else { + module3.exports = function inherits(ctor, superCtor) { + if (superCtor) { + ctor.super_ = superCtor; + var TempCtor = function() { + }; + TempCtor.prototype = superCtor.prototype; + ctor.prototype = new TempCtor(); + ctor.prototype.constructor = ctor; + } + }; + } + } +}); + +// node_modules/inherits/inherits.js +var require_inherits = __commonJS({ + "node_modules/inherits/inherits.js"(exports2, module3) { + try { + util = require("util"); + if (typeof util.inherits !== "function") throw ""; + module3.exports = util.inherits; + } catch (e) { + module3.exports = require_inherits_browser(); + } + var util; + } +}); + +// node_modules/readable-stream/lib/internal/streams/BufferList.js +var require_BufferList = __commonJS({ + "node_modules/readable-stream/lib/internal/streams/BufferList.js"(exports2, module3) { + "use strict"; + function _classCallCheck(instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } + } + var Buffer3 = require_safe_buffer().Buffer; + var util = require("util"); + function copyBuffer(src, target, offset) { + src.copy(target, offset); + } + module3.exports = (function() { + function BufferList() { + _classCallCheck(this, BufferList); + this.head = null; + this.tail = null; + this.length = 0; + } + BufferList.prototype.push = function push(v) { + var entry6 = { data: v, next: null }; + if (this.length > 0) this.tail.next = entry6; + else this.head = entry6; + this.tail = entry6; + ++this.length; + }; + BufferList.prototype.unshift = function unshift(v) { + var entry6 = { data: v, next: this.head }; + if (this.length === 0) this.tail = entry6; + this.head = entry6; + ++this.length; + }; + BufferList.prototype.shift = function shift() { + if (this.length === 0) return; + var ret = this.head.data; + if (this.length === 1) this.head = this.tail = null; + else this.head = this.head.next; + --this.length; + return ret; + }; + BufferList.prototype.clear = function clear() { + this.head = this.tail = null; + this.length = 0; + }; + BufferList.prototype.join = function join2(s) { + if (this.length === 0) return ""; + var p = this.head; + var ret = "" + p.data; + while (p = p.next) { + ret += s + p.data; + } + return ret; + }; + BufferList.prototype.concat = function concat(n) { + if (this.length === 0) return Buffer3.alloc(0); + var ret = Buffer3.allocUnsafe(n >>> 0); + var p = this.head; + var i = 0; + while (p) { + copyBuffer(p.data, ret, i); + i += p.data.length; + p = p.next; + } + return ret; + }; + return BufferList; + })(); + if (util && util.inspect && util.inspect.custom) { + module3.exports.prototype[util.inspect.custom] = function() { + var obj = util.inspect({ length: this.length }); + return this.constructor.name + " " + obj; + }; + } + } +}); + +// node_modules/readable-stream/lib/internal/streams/destroy.js +var require_destroy = __commonJS({ + "node_modules/readable-stream/lib/internal/streams/destroy.js"(exports2, module3) { + "use strict"; + var pna = require_process_nextick_args(); + function destroy(err, cb) { + var _this = this; + var readableDestroyed = this._readableState && this._readableState.destroyed; + var writableDestroyed = this._writableState && this._writableState.destroyed; + if (readableDestroyed || writableDestroyed) { + if (cb) { + cb(err); + } else if (err) { + if (!this._writableState) { + pna.nextTick(emitErrorNT, this, err); + } else if (!this._writableState.errorEmitted) { + this._writableState.errorEmitted = true; + pna.nextTick(emitErrorNT, this, err); + } + } + return this; + } + if (this._readableState) { + this._readableState.destroyed = true; + } + if (this._writableState) { + this._writableState.destroyed = true; + } + this._destroy(err || null, function(err2) { + if (!cb && err2) { + if (!_this._writableState) { + pna.nextTick(emitErrorNT, _this, err2); + } else if (!_this._writableState.errorEmitted) { + _this._writableState.errorEmitted = true; + pna.nextTick(emitErrorNT, _this, err2); + } + } else if (cb) { + cb(err2); + } + }); + return this; + } + function undestroy() { + if (this._readableState) { + this._readableState.destroyed = false; + this._readableState.reading = false; + this._readableState.ended = false; + this._readableState.endEmitted = false; + } + if (this._writableState) { + this._writableState.destroyed = false; + this._writableState.ended = false; + this._writableState.ending = false; + this._writableState.finalCalled = false; + this._writableState.prefinished = false; + this._writableState.finished = false; + this._writableState.errorEmitted = false; + } + } + function emitErrorNT(self2, err) { + self2.emit("error", err); + } + module3.exports = { + destroy, + undestroy + }; + } +}); + +// node_modules/util-deprecate/node.js +var require_node = __commonJS({ + "node_modules/util-deprecate/node.js"(exports2, module3) { + module3.exports = require("util").deprecate; + } +}); + +// node_modules/readable-stream/lib/_stream_writable.js +var require_stream_writable = __commonJS({ + "node_modules/readable-stream/lib/_stream_writable.js"(exports2, module3) { + "use strict"; + var pna = require_process_nextick_args(); + module3.exports = Writable; + function CorkedRequest(state) { + var _this = this; + this.next = null; + this.entry = null; + this.finish = function() { + onCorkedFinish(_this, state); + }; + } + var asyncWrite = !process.browser && ["v0.10", "v0.9."].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : pna.nextTick; + var Duplex; + Writable.WritableState = WritableState; + var util = Object.create(require_util()); + util.inherits = require_inherits(); + var internalUtil = { + deprecate: require_node() + }; + var Stream = require_stream(); + var Buffer3 = require_safe_buffer().Buffer; + var OurUint8Array = (typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : {}).Uint8Array || function() { + }; + function _uint8ArrayToBuffer(chunk) { + return Buffer3.from(chunk); + } + function _isUint8Array(obj) { + return Buffer3.isBuffer(obj) || obj instanceof OurUint8Array; + } + var destroyImpl = require_destroy(); + util.inherits(Writable, Stream); + function nop() { + } + function WritableState(options2, stream2) { + Duplex = Duplex || require_stream_duplex(); + options2 = options2 || {}; + var isDuplex = stream2 instanceof Duplex; + this.objectMode = !!options2.objectMode; + if (isDuplex) this.objectMode = this.objectMode || !!options2.writableObjectMode; + var hwm = options2.highWaterMark; + var writableHwm = options2.writableHighWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + if (hwm || hwm === 0) this.highWaterMark = hwm; + else if (isDuplex && (writableHwm || writableHwm === 0)) this.highWaterMark = writableHwm; + else this.highWaterMark = defaultHwm; + this.highWaterMark = Math.floor(this.highWaterMark); + this.finalCalled = false; + this.needDrain = false; + this.ending = false; + this.ended = false; + this.finished = false; + this.destroyed = false; + var noDecode = options2.decodeStrings === false; + this.decodeStrings = !noDecode; + this.defaultEncoding = options2.defaultEncoding || "utf8"; + this.length = 0; + this.writing = false; + this.corked = 0; + this.sync = true; + this.bufferProcessing = false; + this.onwrite = function(er) { + onwrite(stream2, er); + }; + this.writecb = null; + this.writelen = 0; + this.bufferedRequest = null; + this.lastBufferedRequest = null; + this.pendingcb = 0; + this.prefinished = false; + this.errorEmitted = false; + this.bufferedRequestCount = 0; + this.corkedRequestsFree = new CorkedRequest(this); + } + WritableState.prototype.getBuffer = function getBuffer() { + var current = this.bufferedRequest; + var out = []; + while (current) { + out.push(current); + current = current.next; + } + return out; + }; + (function() { + try { + Object.defineProperty(WritableState.prototype, "buffer", { + get: internalUtil.deprecate(function() { + return this.getBuffer(); + }, "_writableState.buffer is deprecated. Use _writableState.getBuffer instead.", "DEP0003") + }); + } catch (_) { + } + })(); + var realHasInstance; + if (typeof Symbol === "function" && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === "function") { + realHasInstance = Function.prototype[Symbol.hasInstance]; + Object.defineProperty(Writable, Symbol.hasInstance, { + value: function(object5) { + if (realHasInstance.call(this, object5)) return true; + if (this !== Writable) return false; + return object5 && object5._writableState instanceof WritableState; + } + }); + } else { + realHasInstance = function(object5) { + return object5 instanceof this; + }; + } + function Writable(options2) { + Duplex = Duplex || require_stream_duplex(); + if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { + return new Writable(options2); + } + this._writableState = new WritableState(options2, this); + this.writable = true; + if (options2) { + if (typeof options2.write === "function") this._write = options2.write; + if (typeof options2.writev === "function") this._writev = options2.writev; + if (typeof options2.destroy === "function") this._destroy = options2.destroy; + if (typeof options2.final === "function") this._final = options2.final; + } + Stream.call(this); + } + Writable.prototype.pipe = function() { + this.emit("error", new Error("Cannot pipe, not readable")); + }; + function writeAfterEnd(stream2, cb) { + var er = new Error("write after end"); + stream2.emit("error", er); + pna.nextTick(cb, er); + } + function validChunk(stream2, state, chunk, cb) { + var valid = true; + var er = false; + if (chunk === null) { + er = new TypeError("May not write null values to stream"); + } else if (typeof chunk !== "string" && chunk !== void 0 && !state.objectMode) { + er = new TypeError("Invalid non-string/buffer chunk"); + } + if (er) { + stream2.emit("error", er); + pna.nextTick(cb, er); + valid = false; + } + return valid; + } + Writable.prototype.write = function(chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + var isBuf = !state.objectMode && _isUint8Array(chunk); + if (isBuf && !Buffer3.isBuffer(chunk)) { + chunk = _uint8ArrayToBuffer(chunk); + } + if (typeof encoding === "function") { + cb = encoding; + encoding = null; + } + if (isBuf) encoding = "buffer"; + else if (!encoding) encoding = state.defaultEncoding; + if (typeof cb !== "function") cb = nop; + if (state.ended) writeAfterEnd(this, cb); + else if (isBuf || validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); + } + return ret; + }; + Writable.prototype.cork = function() { + var state = this._writableState; + state.corked++; + }; + Writable.prototype.uncork = function() { + var state = this._writableState; + if (state.corked) { + state.corked--; + if (!state.writing && !state.corked && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); + } + }; + Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { + if (typeof encoding === "string") encoding = encoding.toLowerCase(); + if (!(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((encoding + "").toLowerCase()) > -1)) throw new TypeError("Unknown encoding: " + encoding); + this._writableState.defaultEncoding = encoding; + return this; + }; + function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && state.decodeStrings !== false && typeof chunk === "string") { + chunk = Buffer3.from(chunk, encoding); + } + return chunk; + } + Object.defineProperty(Writable.prototype, "writableHighWaterMark", { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function() { + return this._writableState.highWaterMark; + } + }); + function writeOrBuffer(stream2, state, isBuf, chunk, encoding, cb) { + if (!isBuf) { + var newChunk = decodeChunk(state, chunk, encoding); + if (chunk !== newChunk) { + isBuf = true; + encoding = "buffer"; + chunk = newChunk; + } + } + var len = state.objectMode ? 1 : chunk.length; + state.length += len; + var ret = state.length < state.highWaterMark; + if (!ret) state.needDrain = true; + if (state.writing || state.corked) { + var last = state.lastBufferedRequest; + state.lastBufferedRequest = { + chunk, + encoding, + isBuf, + callback: cb, + next: null + }; + if (last) { + last.next = state.lastBufferedRequest; + } else { + state.bufferedRequest = state.lastBufferedRequest; + } + state.bufferedRequestCount += 1; + } else { + doWrite(stream2, state, false, len, chunk, encoding, cb); + } + return ret; + } + function doWrite(stream2, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) stream2._writev(chunk, state.onwrite); + else stream2._write(chunk, encoding, state.onwrite); + state.sync = false; + } + function onwriteError(stream2, state, sync, er, cb) { + --state.pendingcb; + if (sync) { + pna.nextTick(cb, er); + pna.nextTick(finishMaybe, stream2, state); + stream2._writableState.errorEmitted = true; + stream2.emit("error", er); + } else { + cb(er); + stream2._writableState.errorEmitted = true; + stream2.emit("error", er); + finishMaybe(stream2, state); + } + } + function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; + } + function onwrite(stream2, er) { + var state = stream2._writableState; + var sync = state.sync; + var cb = state.writecb; + onwriteStateUpdate(state); + if (er) onwriteError(stream2, state, sync, er, cb); + else { + var finished = needFinish(state); + if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { + clearBuffer(stream2, state); + } + if (sync) { + asyncWrite(afterWrite, stream2, state, finished, cb); + } else { + afterWrite(stream2, state, finished, cb); + } + } + } + function afterWrite(stream2, state, finished, cb) { + if (!finished) onwriteDrain(stream2, state); + state.pendingcb--; + cb(); + finishMaybe(stream2, state); + } + function onwriteDrain(stream2, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream2.emit("drain"); + } + } + function clearBuffer(stream2, state) { + state.bufferProcessing = true; + var entry6 = state.bufferedRequest; + if (stream2._writev && entry6 && entry6.next) { + var l = state.bufferedRequestCount; + var buffer = new Array(l); + var holder = state.corkedRequestsFree; + holder.entry = entry6; + var count = 0; + var allBuffers = true; + while (entry6) { + buffer[count] = entry6; + if (!entry6.isBuf) allBuffers = false; + entry6 = entry6.next; + count += 1; + } + buffer.allBuffers = allBuffers; + doWrite(stream2, state, true, state.length, buffer, "", holder.finish); + state.pendingcb++; + state.lastBufferedRequest = null; + if (holder.next) { + state.corkedRequestsFree = holder.next; + holder.next = null; + } else { + state.corkedRequestsFree = new CorkedRequest(state); + } + state.bufferedRequestCount = 0; + } else { + while (entry6) { + var chunk = entry6.chunk; + var encoding = entry6.encoding; + var cb = entry6.callback; + var len = state.objectMode ? 1 : chunk.length; + doWrite(stream2, state, false, len, chunk, encoding, cb); + entry6 = entry6.next; + state.bufferedRequestCount--; + if (state.writing) { + break; + } + } + if (entry6 === null) state.lastBufferedRequest = null; + } + state.bufferedRequest = entry6; + state.bufferProcessing = false; + } + Writable.prototype._write = function(chunk, encoding, cb) { + cb(new Error("_write() is not implemented")); + }; + Writable.prototype._writev = null; + Writable.prototype.end = function(chunk, encoding, cb) { + var state = this._writableState; + if (typeof chunk === "function") { + cb = chunk; + chunk = null; + encoding = null; + } else if (typeof encoding === "function") { + cb = encoding; + encoding = null; + } + if (chunk !== null && chunk !== void 0) this.write(chunk, encoding); + if (state.corked) { + state.corked = 1; + this.uncork(); + } + if (!state.ending) endWritable(this, state, cb); + }; + function needFinish(state) { + return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; + } + function callFinal(stream2, state) { + stream2._final(function(err) { + state.pendingcb--; + if (err) { + stream2.emit("error", err); + } + state.prefinished = true; + stream2.emit("prefinish"); + finishMaybe(stream2, state); + }); + } + function prefinish(stream2, state) { + if (!state.prefinished && !state.finalCalled) { + if (typeof stream2._final === "function") { + state.pendingcb++; + state.finalCalled = true; + pna.nextTick(callFinal, stream2, state); + } else { + state.prefinished = true; + stream2.emit("prefinish"); + } + } + } + function finishMaybe(stream2, state) { + var need = needFinish(state); + if (need) { + prefinish(stream2, state); + if (state.pendingcb === 0) { + state.finished = true; + stream2.emit("finish"); + } + } + return need; + } + function endWritable(stream2, state, cb) { + state.ending = true; + finishMaybe(stream2, state); + if (cb) { + if (state.finished) pna.nextTick(cb); + else stream2.once("finish", cb); + } + state.ended = true; + stream2.writable = false; + } + function onCorkedFinish(corkReq, state, err) { + var entry6 = corkReq.entry; + corkReq.entry = null; + while (entry6) { + var cb = entry6.callback; + state.pendingcb--; + cb(err); + entry6 = entry6.next; + } + state.corkedRequestsFree.next = corkReq; + } + Object.defineProperty(Writable.prototype, "destroyed", { + get: function() { + if (this._writableState === void 0) { + return false; + } + return this._writableState.destroyed; + }, + set: function(value) { + if (!this._writableState) { + return; + } + this._writableState.destroyed = value; + } + }); + Writable.prototype.destroy = destroyImpl.destroy; + Writable.prototype._undestroy = destroyImpl.undestroy; + Writable.prototype._destroy = function(err, cb) { + this.end(); + cb(err); + }; + } +}); + +// node_modules/readable-stream/lib/_stream_duplex.js +var require_stream_duplex = __commonJS({ + "node_modules/readable-stream/lib/_stream_duplex.js"(exports2, module3) { + "use strict"; + var pna = require_process_nextick_args(); + var objectKeys = Object.keys || function(obj) { + var keys2 = []; + for (var key2 in obj) { + keys2.push(key2); + } + return keys2; + }; + module3.exports = Duplex; + var util = Object.create(require_util()); + util.inherits = require_inherits(); + var Readable = require_stream_readable(); + var Writable = require_stream_writable(); + util.inherits(Duplex, Readable); + { + keys = objectKeys(Writable.prototype); + for (v = 0; v < keys.length; v++) { + method = keys[v]; + if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; + } + } + var keys; + var method; + var v; + function Duplex(options2) { + if (!(this instanceof Duplex)) return new Duplex(options2); + Readable.call(this, options2); + Writable.call(this, options2); + if (options2 && options2.readable === false) this.readable = false; + if (options2 && options2.writable === false) this.writable = false; + this.allowHalfOpen = true; + if (options2 && options2.allowHalfOpen === false) this.allowHalfOpen = false; + this.once("end", onend); + } + Object.defineProperty(Duplex.prototype, "writableHighWaterMark", { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function() { + return this._writableState.highWaterMark; + } + }); + function onend() { + if (this.allowHalfOpen || this._writableState.ended) return; + pna.nextTick(onEndNT, this); + } + function onEndNT(self2) { + self2.end(); + } + Object.defineProperty(Duplex.prototype, "destroyed", { + get: function() { + if (this._readableState === void 0 || this._writableState === void 0) { + return false; + } + return this._readableState.destroyed && this._writableState.destroyed; + }, + set: function(value) { + if (this._readableState === void 0 || this._writableState === void 0) { + return; + } + this._readableState.destroyed = value; + this._writableState.destroyed = value; + } + }); + Duplex.prototype._destroy = function(err, cb) { + this.push(null); + this.end(); + pna.nextTick(cb, err); + }; + } +}); + +// node_modules/string_decoder/node_modules/safe-buffer/index.js +var require_safe_buffer2 = __commonJS({ + "node_modules/string_decoder/node_modules/safe-buffer/index.js"(exports2, module3) { + var buffer = require("buffer"); + var Buffer3 = buffer.Buffer; + function copyProps(src, dst) { + for (var key2 in src) { + dst[key2] = src[key2]; + } + } + if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { + module3.exports = buffer; + } else { + copyProps(buffer, exports2); + exports2.Buffer = SafeBuffer; + } + function SafeBuffer(arg, encodingOrOffset, length) { + return Buffer3(arg, encodingOrOffset, length); + } + copyProps(Buffer3, SafeBuffer); + SafeBuffer.from = function(arg, encodingOrOffset, length) { + if (typeof arg === "number") { + throw new TypeError("Argument must not be a number"); + } + return Buffer3(arg, encodingOrOffset, length); + }; + SafeBuffer.alloc = function(size, fill, encoding) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + var buf = Buffer3(size); + if (fill !== void 0) { + if (typeof encoding === "string") { + buf.fill(fill, encoding); + } else { + buf.fill(fill); + } + } else { + buf.fill(0); + } + return buf; + }; + SafeBuffer.allocUnsafe = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return Buffer3(size); + }; + SafeBuffer.allocUnsafeSlow = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return buffer.SlowBuffer(size); + }; + } +}); + +// node_modules/string_decoder/lib/string_decoder.js +var require_string_decoder = __commonJS({ + "node_modules/string_decoder/lib/string_decoder.js"(exports2) { + "use strict"; + var Buffer3 = require_safe_buffer2().Buffer; + var isEncoding = Buffer3.isEncoding || function(encoding) { + encoding = "" + encoding; + switch (encoding && encoding.toLowerCase()) { + case "hex": + case "utf8": + case "utf-8": + case "ascii": + case "binary": + case "base64": + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + case "raw": + return true; + default: + return false; + } + }; + function _normalizeEncoding(enc) { + if (!enc) return "utf8"; + var retried; + while (true) { + switch (enc) { + case "utf8": + case "utf-8": + return "utf8"; + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return "utf16le"; + case "latin1": + case "binary": + return "latin1"; + case "base64": + case "ascii": + case "hex": + return enc; + default: + if (retried) return; + enc = ("" + enc).toLowerCase(); + retried = true; + } + } + } + function normalizeEncoding(enc) { + var nenc = _normalizeEncoding(enc); + if (typeof nenc !== "string" && (Buffer3.isEncoding === isEncoding || !isEncoding(enc))) throw new Error("Unknown encoding: " + enc); + return nenc || enc; + } + exports2.StringDecoder = StringDecoder; + function StringDecoder(encoding) { + this.encoding = normalizeEncoding(encoding); + var nb; + switch (this.encoding) { + case "utf16le": + this.text = utf16Text; + this.end = utf16End; + nb = 4; + break; + case "utf8": + this.fillLast = utf8FillLast; + nb = 4; + break; + case "base64": + this.text = base64Text; + this.end = base64End; + nb = 3; + break; + default: + this.write = simpleWrite; + this.end = simpleEnd; + return; + } + this.lastNeed = 0; + this.lastTotal = 0; + this.lastChar = Buffer3.allocUnsafe(nb); + } + StringDecoder.prototype.write = function(buf) { + if (buf.length === 0) return ""; + var r; + var i; + if (this.lastNeed) { + r = this.fillLast(buf); + if (r === void 0) return ""; + i = this.lastNeed; + this.lastNeed = 0; + } else { + i = 0; + } + if (i < buf.length) return r ? r + this.text(buf, i) : this.text(buf, i); + return r || ""; + }; + StringDecoder.prototype.end = utf8End; + StringDecoder.prototype.text = utf8Text; + StringDecoder.prototype.fillLast = function(buf) { + if (this.lastNeed <= buf.length) { + buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed); + return this.lastChar.toString(this.encoding, 0, this.lastTotal); + } + buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, buf.length); + this.lastNeed -= buf.length; + }; + function utf8CheckByte(byte) { + if (byte <= 127) return 0; + else if (byte >> 5 === 6) return 2; + else if (byte >> 4 === 14) return 3; + else if (byte >> 3 === 30) return 4; + return byte >> 6 === 2 ? -1 : -2; + } + function utf8CheckIncomplete(self2, buf, i) { + var j = buf.length - 1; + if (j < i) return 0; + var nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) self2.lastNeed = nb - 1; + return nb; + } + if (--j < i || nb === -2) return 0; + nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) self2.lastNeed = nb - 2; + return nb; + } + if (--j < i || nb === -2) return 0; + nb = utf8CheckByte(buf[j]); + if (nb >= 0) { + if (nb > 0) { + if (nb === 2) nb = 0; + else self2.lastNeed = nb - 3; + } + return nb; + } + return 0; + } + function utf8CheckExtraBytes(self2, buf, p) { + if ((buf[0] & 192) !== 128) { + self2.lastNeed = 0; + return "\uFFFD"; + } + if (self2.lastNeed > 1 && buf.length > 1) { + if ((buf[1] & 192) !== 128) { + self2.lastNeed = 1; + return "\uFFFD"; + } + if (self2.lastNeed > 2 && buf.length > 2) { + if ((buf[2] & 192) !== 128) { + self2.lastNeed = 2; + return "\uFFFD"; + } + } + } + } + function utf8FillLast(buf) { + var p = this.lastTotal - this.lastNeed; + var r = utf8CheckExtraBytes(this, buf, p); + if (r !== void 0) return r; + if (this.lastNeed <= buf.length) { + buf.copy(this.lastChar, p, 0, this.lastNeed); + return this.lastChar.toString(this.encoding, 0, this.lastTotal); + } + buf.copy(this.lastChar, p, 0, buf.length); + this.lastNeed -= buf.length; + } + function utf8Text(buf, i) { + var total = utf8CheckIncomplete(this, buf, i); + if (!this.lastNeed) return buf.toString("utf8", i); + this.lastTotal = total; + var end = buf.length - (total - this.lastNeed); + buf.copy(this.lastChar, 0, end); + return buf.toString("utf8", i, end); + } + function utf8End(buf) { + var r = buf && buf.length ? this.write(buf) : ""; + if (this.lastNeed) return r + "\uFFFD"; + return r; + } + function utf16Text(buf, i) { + if ((buf.length - i) % 2 === 0) { + var r = buf.toString("utf16le", i); + if (r) { + var c = r.charCodeAt(r.length - 1); + if (c >= 55296 && c <= 56319) { + this.lastNeed = 2; + this.lastTotal = 4; + this.lastChar[0] = buf[buf.length - 2]; + this.lastChar[1] = buf[buf.length - 1]; + return r.slice(0, -1); + } + } + return r; + } + this.lastNeed = 1; + this.lastTotal = 2; + this.lastChar[0] = buf[buf.length - 1]; + return buf.toString("utf16le", i, buf.length - 1); + } + function utf16End(buf) { + var r = buf && buf.length ? this.write(buf) : ""; + if (this.lastNeed) { + var end = this.lastTotal - this.lastNeed; + return r + this.lastChar.toString("utf16le", 0, end); + } + return r; + } + function base64Text(buf, i) { + var n = (buf.length - i) % 3; + if (n === 0) return buf.toString("base64", i); + this.lastNeed = 3 - n; + this.lastTotal = 3; + if (n === 1) { + this.lastChar[0] = buf[buf.length - 1]; + } else { + this.lastChar[0] = buf[buf.length - 2]; + this.lastChar[1] = buf[buf.length - 1]; + } + return buf.toString("base64", i, buf.length - n); + } + function base64End(buf) { + var r = buf && buf.length ? this.write(buf) : ""; + if (this.lastNeed) return r + this.lastChar.toString("base64", 0, 3 - this.lastNeed); + return r; + } + function simpleWrite(buf) { + return buf.toString(this.encoding); + } + function simpleEnd(buf) { + return buf && buf.length ? this.write(buf) : ""; + } + } +}); + +// node_modules/readable-stream/lib/_stream_readable.js +var require_stream_readable = __commonJS({ + "node_modules/readable-stream/lib/_stream_readable.js"(exports2, module3) { + "use strict"; + var pna = require_process_nextick_args(); + module3.exports = Readable; + var isArray = require_isarray(); + var Duplex; + Readable.ReadableState = ReadableState; + var EE = require("events").EventEmitter; + var EElistenerCount = function(emitter, type2) { + return emitter.listeners(type2).length; + }; + var Stream = require_stream(); + var Buffer3 = require_safe_buffer().Buffer; + var OurUint8Array = (typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : {}).Uint8Array || function() { + }; + function _uint8ArrayToBuffer(chunk) { + return Buffer3.from(chunk); + } + function _isUint8Array(obj) { + return Buffer3.isBuffer(obj) || obj instanceof OurUint8Array; + } + var util = Object.create(require_util()); + util.inherits = require_inherits(); + var debugUtil = require("util"); + var debug = void 0; + if (debugUtil && debugUtil.debuglog) { + debug = debugUtil.debuglog("stream"); + } else { + debug = function() { + }; + } + var BufferList = require_BufferList(); + var destroyImpl = require_destroy(); + var StringDecoder; + util.inherits(Readable, Stream); + var kProxyEvents = ["error", "close", "destroy", "pause", "resume"]; + function prependListener(emitter, event, fn) { + if (typeof emitter.prependListener === "function") return emitter.prependListener(event, fn); + if (!emitter._events || !emitter._events[event]) emitter.on(event, fn); + else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn); + else emitter._events[event] = [fn, emitter._events[event]]; + } + function ReadableState(options2, stream2) { + Duplex = Duplex || require_stream_duplex(); + options2 = options2 || {}; + var isDuplex = stream2 instanceof Duplex; + this.objectMode = !!options2.objectMode; + if (isDuplex) this.objectMode = this.objectMode || !!options2.readableObjectMode; + var hwm = options2.highWaterMark; + var readableHwm = options2.readableHighWaterMark; + var defaultHwm = this.objectMode ? 16 : 16 * 1024; + if (hwm || hwm === 0) this.highWaterMark = hwm; + else if (isDuplex && (readableHwm || readableHwm === 0)) this.highWaterMark = readableHwm; + else this.highWaterMark = defaultHwm; + this.highWaterMark = Math.floor(this.highWaterMark); + this.buffer = new BufferList(); + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = false; + this.sync = true; + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + this.resumeScheduled = false; + this.destroyed = false; + this.defaultEncoding = options2.defaultEncoding || "utf8"; + this.awaitDrain = 0; + this.readingMore = false; + this.decoder = null; + this.encoding = null; + if (options2.encoding) { + if (!StringDecoder) StringDecoder = require_string_decoder().StringDecoder; + this.decoder = new StringDecoder(options2.encoding); + this.encoding = options2.encoding; + } + } + function Readable(options2) { + Duplex = Duplex || require_stream_duplex(); + if (!(this instanceof Readable)) return new Readable(options2); + this._readableState = new ReadableState(options2, this); + this.readable = true; + if (options2) { + if (typeof options2.read === "function") this._read = options2.read; + if (typeof options2.destroy === "function") this._destroy = options2.destroy; + } + Stream.call(this); + } + Object.defineProperty(Readable.prototype, "destroyed", { + get: function() { + if (this._readableState === void 0) { + return false; + } + return this._readableState.destroyed; + }, + set: function(value) { + if (!this._readableState) { + return; + } + this._readableState.destroyed = value; + } + }); + Readable.prototype.destroy = destroyImpl.destroy; + Readable.prototype._undestroy = destroyImpl.undestroy; + Readable.prototype._destroy = function(err, cb) { + this.push(null); + cb(err); + }; + Readable.prototype.push = function(chunk, encoding) { + var state = this._readableState; + var skipChunkCheck; + if (!state.objectMode) { + if (typeof chunk === "string") { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = Buffer3.from(chunk, encoding); + encoding = ""; + } + skipChunkCheck = true; + } + } else { + skipChunkCheck = true; + } + return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); + }; + Readable.prototype.unshift = function(chunk) { + return readableAddChunk(this, chunk, null, true, false); + }; + function readableAddChunk(stream2, chunk, encoding, addToFront, skipChunkCheck) { + var state = stream2._readableState; + if (chunk === null) { + state.reading = false; + onEofChunk(stream2, state); + } else { + var er; + if (!skipChunkCheck) er = chunkInvalid(state, chunk); + if (er) { + stream2.emit("error", er); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (typeof chunk !== "string" && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer3.prototype) { + chunk = _uint8ArrayToBuffer(chunk); + } + if (addToFront) { + if (state.endEmitted) stream2.emit("error", new Error("stream.unshift() after end event")); + else addChunk(stream2, state, chunk, true); + } else if (state.ended) { + stream2.emit("error", new Error("stream.push() after EOF")); + } else { + state.reading = false; + if (state.decoder && !encoding) { + chunk = state.decoder.write(chunk); + if (state.objectMode || chunk.length !== 0) addChunk(stream2, state, chunk, false); + else maybeReadMore(stream2, state); + } else { + addChunk(stream2, state, chunk, false); + } + } + } else if (!addToFront) { + state.reading = false; + } + } + return needMoreData(state); + } + function addChunk(stream2, state, chunk, addToFront) { + if (state.flowing && state.length === 0 && !state.sync) { + stream2.emit("data", chunk); + stream2.read(0); + } else { + state.length += state.objectMode ? 1 : chunk.length; + if (addToFront) state.buffer.unshift(chunk); + else state.buffer.push(chunk); + if (state.needReadable) emitReadable(stream2); + } + maybeReadMore(stream2, state); + } + function chunkInvalid(state, chunk) { + var er; + if (!_isUint8Array(chunk) && typeof chunk !== "string" && chunk !== void 0 && !state.objectMode) { + er = new TypeError("Invalid non-string/buffer chunk"); + } + return er; + } + function needMoreData(state) { + return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); + } + Readable.prototype.isPaused = function() { + return this._readableState.flowing === false; + }; + Readable.prototype.setEncoding = function(enc) { + if (!StringDecoder) StringDecoder = require_string_decoder().StringDecoder; + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; + }; + var MAX_HWM = 8388608; + function computeNewHighWaterMark(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + n--; + n |= n >>> 1; + n |= n >>> 2; + n |= n >>> 4; + n |= n >>> 8; + n |= n >>> 16; + n++; + } + return n; + } + function howMuchToRead(n, state) { + if (n <= 0 || state.length === 0 && state.ended) return 0; + if (state.objectMode) return 1; + if (n !== n) { + if (state.flowing && state.length) return state.buffer.head.data.length; + else return state.length; + } + if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); + if (n <= state.length) return n; + if (!state.ended) { + state.needReadable = true; + return 0; + } + return state.length; + } + Readable.prototype.read = function(n) { + debug("read", n); + n = parseInt(n, 10); + var state = this._readableState; + var nOrig = n; + if (n !== 0) state.emittedReadable = false; + if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { + debug("read: emitReadable", state.length, state.ended); + if (state.length === 0 && state.ended) endReadable(this); + else emitReadable(this); + return null; + } + n = howMuchToRead(n, state); + if (n === 0 && state.ended) { + if (state.length === 0) endReadable(this); + return null; + } + var doRead = state.needReadable; + debug("need readable", doRead); + if (state.length === 0 || state.length - n < state.highWaterMark) { + doRead = true; + debug("length less than watermark", doRead); + } + if (state.ended || state.reading) { + doRead = false; + debug("reading or ended", doRead); + } else if (doRead) { + debug("do read"); + state.reading = true; + state.sync = true; + if (state.length === 0) state.needReadable = true; + this._read(state.highWaterMark); + state.sync = false; + if (!state.reading) n = howMuchToRead(nOrig, state); + } + var ret; + if (n > 0) ret = fromList(n, state); + else ret = null; + if (ret === null) { + state.needReadable = true; + n = 0; + } else { + state.length -= n; + } + if (state.length === 0) { + if (!state.ended) state.needReadable = true; + if (nOrig !== n && state.ended) endReadable(this); + } + if (ret !== null) this.emit("data", ret); + return ret; + }; + function onEofChunk(stream2, state) { + if (state.ended) return; + if (state.decoder) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; + } + } + state.ended = true; + emitReadable(stream2); + } + function emitReadable(stream2) { + var state = stream2._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug("emitReadable", state.flowing); + state.emittedReadable = true; + if (state.sync) pna.nextTick(emitReadable_, stream2); + else emitReadable_(stream2); + } + } + function emitReadable_(stream2) { + debug("emit readable"); + stream2.emit("readable"); + flow(stream2); + } + function maybeReadMore(stream2, state) { + if (!state.readingMore) { + state.readingMore = true; + pna.nextTick(maybeReadMore_, stream2, state); + } + } + function maybeReadMore_(stream2, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { + debug("maybeReadMore read 0"); + stream2.read(0); + if (len === state.length) + break; + else len = state.length; + } + state.readingMore = false; + } + Readable.prototype._read = function(n) { + this.emit("error", new Error("_read() is not implemented")); + }; + Readable.prototype.pipe = function(dest, pipeOpts) { + var src = this; + var state = this._readableState; + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; + } + state.pipesCount += 1; + debug("pipe count=%d opts=%j", state.pipesCount, pipeOpts); + var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; + var endFn = doEnd ? onend : unpipe; + if (state.endEmitted) pna.nextTick(endFn); + else src.once("end", endFn); + dest.on("unpipe", onunpipe); + function onunpipe(readable, unpipeInfo) { + debug("onunpipe"); + if (readable === src) { + if (unpipeInfo && unpipeInfo.hasUnpiped === false) { + unpipeInfo.hasUnpiped = true; + cleanup(); + } + } + } + function onend() { + debug("onend"); + dest.end(); + } + var ondrain = pipeOnDrain(src); + dest.on("drain", ondrain); + var cleanedUp = false; + function cleanup() { + debug("cleanup"); + dest.removeListener("close", onclose); + dest.removeListener("finish", onfinish); + dest.removeListener("drain", ondrain); + dest.removeListener("error", onerror); + dest.removeListener("unpipe", onunpipe); + src.removeListener("end", onend); + src.removeListener("end", unpipe); + src.removeListener("data", ondata); + cleanedUp = true; + if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); + } + var increasedAwaitDrain = false; + src.on("data", ondata); + function ondata(chunk) { + debug("ondata"); + increasedAwaitDrain = false; + var ret = dest.write(chunk); + if (false === ret && !increasedAwaitDrain) { + if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { + debug("false write response, pause", state.awaitDrain); + state.awaitDrain++; + increasedAwaitDrain = true; + } + src.pause(); + } + } + function onerror(er) { + debug("onerror", er); + unpipe(); + dest.removeListener("error", onerror); + if (EElistenerCount(dest, "error") === 0) dest.emit("error", er); + } + prependListener(dest, "error", onerror); + function onclose() { + dest.removeListener("finish", onfinish); + unpipe(); + } + dest.once("close", onclose); + function onfinish() { + debug("onfinish"); + dest.removeListener("close", onclose); + unpipe(); + } + dest.once("finish", onfinish); + function unpipe() { + debug("unpipe"); + src.unpipe(dest); + } + dest.emit("pipe", src); + if (!state.flowing) { + debug("pipe resume"); + src.resume(); + } + return dest; + }; + function pipeOnDrain(src) { + return function() { + var state = src._readableState; + debug("pipeOnDrain", state.awaitDrain); + if (state.awaitDrain) state.awaitDrain--; + if (state.awaitDrain === 0 && EElistenerCount(src, "data")) { + state.flowing = true; + flow(src); + } + }; + } + Readable.prototype.unpipe = function(dest) { + var state = this._readableState; + var unpipeInfo = { hasUnpiped: false }; + if (state.pipesCount === 0) return this; + if (state.pipesCount === 1) { + if (dest && dest !== state.pipes) return this; + if (!dest) dest = state.pipes; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) dest.emit("unpipe", this, unpipeInfo); + return this; + } + if (!dest) { + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + for (var i = 0; i < len; i++) { + dests[i].emit("unpipe", this, { hasUnpiped: false }); + } + return this; + } + var index4 = indexOf(state.pipes, dest); + if (index4 === -1) return this; + state.pipes.splice(index4, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) state.pipes = state.pipes[0]; + dest.emit("unpipe", this, unpipeInfo); + return this; + }; + Readable.prototype.on = function(ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); + if (ev === "data") { + if (this._readableState.flowing !== false) this.resume(); + } else if (ev === "readable") { + var state = this._readableState; + if (!state.endEmitted && !state.readableListening) { + state.readableListening = state.needReadable = true; + state.emittedReadable = false; + if (!state.reading) { + pna.nextTick(nReadingNextTick, this); + } else if (state.length) { + emitReadable(this); + } + } + } + return res; + }; + Readable.prototype.addListener = Readable.prototype.on; + function nReadingNextTick(self2) { + debug("readable nexttick read 0"); + self2.read(0); + } + Readable.prototype.resume = function() { + var state = this._readableState; + if (!state.flowing) { + debug("resume"); + state.flowing = true; + resume(this, state); + } + return this; + }; + function resume(stream2, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + pna.nextTick(resume_, stream2, state); + } + } + function resume_(stream2, state) { + if (!state.reading) { + debug("resume read 0"); + stream2.read(0); + } + state.resumeScheduled = false; + state.awaitDrain = 0; + stream2.emit("resume"); + flow(stream2); + if (state.flowing && !state.reading) stream2.read(0); + } + Readable.prototype.pause = function() { + debug("call pause flowing=%j", this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug("pause"); + this._readableState.flowing = false; + this.emit("pause"); + } + return this; + }; + function flow(stream2) { + var state = stream2._readableState; + debug("flow", state.flowing); + while (state.flowing && stream2.read() !== null) { + } + } + Readable.prototype.wrap = function(stream2) { + var _this = this; + var state = this._readableState; + var paused = false; + stream2.on("end", function() { + debug("wrapped end"); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) _this.push(chunk); + } + _this.push(null); + }); + stream2.on("data", function(chunk) { + debug("wrapped data"); + if (state.decoder) chunk = state.decoder.write(chunk); + if (state.objectMode && (chunk === null || chunk === void 0)) return; + else if (!state.objectMode && (!chunk || !chunk.length)) return; + var ret = _this.push(chunk); + if (!ret) { + paused = true; + stream2.pause(); + } + }); + for (var i in stream2) { + if (this[i] === void 0 && typeof stream2[i] === "function") { + this[i] = /* @__PURE__ */ (function(method) { + return function() { + return stream2[method].apply(stream2, arguments); + }; + })(i); + } + } + for (var n = 0; n < kProxyEvents.length; n++) { + stream2.on(kProxyEvents[n], this.emit.bind(this, kProxyEvents[n])); + } + this._read = function(n2) { + debug("wrapped _read", n2); + if (paused) { + paused = false; + stream2.resume(); + } + }; + return this; + }; + Object.defineProperty(Readable.prototype, "readableHighWaterMark", { + // making it explicit this property is not enumerable + // because otherwise some prototype manipulation in + // userland will fail + enumerable: false, + get: function() { + return this._readableState.highWaterMark; + } + }); + Readable._fromList = fromList; + function fromList(n, state) { + if (state.length === 0) return null; + var ret; + if (state.objectMode) ret = state.buffer.shift(); + else if (!n || n >= state.length) { + if (state.decoder) ret = state.buffer.join(""); + else if (state.buffer.length === 1) ret = state.buffer.head.data; + else ret = state.buffer.concat(state.length); + state.buffer.clear(); + } else { + ret = fromListPartial(n, state.buffer, state.decoder); + } + return ret; + } + function fromListPartial(n, list4, hasStrings) { + var ret; + if (n < list4.head.data.length) { + ret = list4.head.data.slice(0, n); + list4.head.data = list4.head.data.slice(n); + } else if (n === list4.head.data.length) { + ret = list4.shift(); + } else { + ret = hasStrings ? copyFromBufferString(n, list4) : copyFromBuffer(n, list4); + } + return ret; + } + function copyFromBufferString(n, list4) { + var p = list4.head; + var c = 1; + var ret = p.data; + n -= ret.length; + while (p = p.next) { + var str = p.data; + var nb = n > str.length ? str.length : n; + if (nb === str.length) ret += str; + else ret += str.slice(0, n); + n -= nb; + if (n === 0) { + if (nb === str.length) { + ++c; + if (p.next) list4.head = p.next; + else list4.head = list4.tail = null; + } else { + list4.head = p; + p.data = str.slice(nb); + } + break; + } + ++c; + } + list4.length -= c; + return ret; + } + function copyFromBuffer(n, list4) { + var ret = Buffer3.allocUnsafe(n); + var p = list4.head; + var c = 1; + p.data.copy(ret); + n -= p.data.length; + while (p = p.next) { + var buf = p.data; + var nb = n > buf.length ? buf.length : n; + buf.copy(ret, ret.length - n, 0, nb); + n -= nb; + if (n === 0) { + if (nb === buf.length) { + ++c; + if (p.next) list4.head = p.next; + else list4.head = list4.tail = null; + } else { + list4.head = p; + p.data = buf.slice(nb); + } + break; + } + ++c; + } + list4.length -= c; + return ret; + } + function endReadable(stream2) { + var state = stream2._readableState; + if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); + if (!state.endEmitted) { + state.ended = true; + pna.nextTick(endReadableNT, state, stream2); + } + } + function endReadableNT(state, stream2) { + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream2.readable = false; + stream2.emit("end"); + } + } + function indexOf(xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; + } + } +}); + +// node_modules/readable-stream/lib/_stream_transform.js +var require_stream_transform = __commonJS({ + "node_modules/readable-stream/lib/_stream_transform.js"(exports2, module3) { + "use strict"; + module3.exports = Transform; + var Duplex = require_stream_duplex(); + var util = Object.create(require_util()); + util.inherits = require_inherits(); + util.inherits(Transform, Duplex); + function afterTransform(er, data) { + var ts = this._transformState; + ts.transforming = false; + var cb = ts.writecb; + if (!cb) { + return this.emit("error", new Error("write callback called multiple times")); + } + ts.writechunk = null; + ts.writecb = null; + if (data != null) + this.push(data); + cb(er); + var rs = this._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + this._read(rs.highWaterMark); + } + } + function Transform(options2) { + if (!(this instanceof Transform)) return new Transform(options2); + Duplex.call(this, options2); + this._transformState = { + afterTransform: afterTransform.bind(this), + needTransform: false, + transforming: false, + writecb: null, + writechunk: null, + writeencoding: null + }; + this._readableState.needReadable = true; + this._readableState.sync = false; + if (options2) { + if (typeof options2.transform === "function") this._transform = options2.transform; + if (typeof options2.flush === "function") this._flush = options2.flush; + } + this.on("prefinish", prefinish); + } + function prefinish() { + var _this = this; + if (typeof this._flush === "function") { + this._flush(function(er, data) { + done(_this, er, data); + }); + } else { + done(this, null, null); + } + } + Transform.prototype.push = function(chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); + }; + Transform.prototype._transform = function(chunk, encoding, cb) { + throw new Error("_transform() is not implemented"); + }; + Transform.prototype._write = function(chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); + } + }; + Transform.prototype._read = function(n) { + var ts = this._transformState; + if (ts.writechunk !== null && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + ts.needTransform = true; + } + }; + Transform.prototype._destroy = function(err, cb) { + var _this2 = this; + Duplex.prototype._destroy.call(this, err, function(err2) { + cb(err2); + _this2.emit("close"); + }); + }; + function done(stream2, er, data) { + if (er) return stream2.emit("error", er); + if (data != null) + stream2.push(data); + if (stream2._writableState.length) throw new Error("Calling transform done when ws.length != 0"); + if (stream2._transformState.transforming) throw new Error("Calling transform done when still transforming"); + return stream2.push(null); + } + } +}); + +// node_modules/readable-stream/lib/_stream_passthrough.js +var require_stream_passthrough = __commonJS({ + "node_modules/readable-stream/lib/_stream_passthrough.js"(exports2, module3) { + "use strict"; + module3.exports = PassThrough; + var Transform = require_stream_transform(); + var util = Object.create(require_util()); + util.inherits = require_inherits(); + util.inherits(PassThrough, Transform); + function PassThrough(options2) { + if (!(this instanceof PassThrough)) return new PassThrough(options2); + Transform.call(this, options2); + } + PassThrough.prototype._transform = function(chunk, encoding, cb) { + cb(null, chunk); + }; + } +}); + +// node_modules/readable-stream/readable.js +var require_readable = __commonJS({ + "node_modules/readable-stream/readable.js"(exports2, module3) { + var Stream = require("stream"); + if (process.env.READABLE_STREAM === "disable" && Stream) { + module3.exports = Stream; + exports2 = module3.exports = Stream.Readable; + exports2.Readable = Stream.Readable; + exports2.Writable = Stream.Writable; + exports2.Duplex = Stream.Duplex; + exports2.Transform = Stream.Transform; + exports2.PassThrough = Stream.PassThrough; + exports2.Stream = Stream; + } else { + exports2 = module3.exports = require_stream_readable(); + exports2.Stream = Stream || exports2; + exports2.Readable = exports2; + exports2.Writable = require_stream_writable(); + exports2.Duplex = require_stream_duplex(); + exports2.Transform = require_stream_transform(); + exports2.PassThrough = require_stream_passthrough(); + } + } +}); + +// node_modules/readable-stream/duplex.js +var require_duplex = __commonJS({ + "node_modules/readable-stream/duplex.js"(exports2, module3) { + module3.exports = require_readable().Duplex; + } +}); + +// node_modules/safe-buffer/index.js +var require_safe_buffer3 = __commonJS({ + "node_modules/safe-buffer/index.js"(exports2, module3) { + var buffer = require("buffer"); + var Buffer3 = buffer.Buffer; + function copyProps(src, dst) { + for (var key2 in src) { + dst[key2] = src[key2]; + } + } + if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { + module3.exports = buffer; + } else { + copyProps(buffer, exports2); + exports2.Buffer = SafeBuffer; + } + function SafeBuffer(arg, encodingOrOffset, length) { + return Buffer3(arg, encodingOrOffset, length); + } + SafeBuffer.prototype = Object.create(Buffer3.prototype); + copyProps(Buffer3, SafeBuffer); + SafeBuffer.from = function(arg, encodingOrOffset, length) { + if (typeof arg === "number") { + throw new TypeError("Argument must not be a number"); + } + return Buffer3(arg, encodingOrOffset, length); + }; + SafeBuffer.alloc = function(size, fill, encoding) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + var buf = Buffer3(size); + if (fill !== void 0) { + if (typeof encoding === "string") { + buf.fill(fill, encoding); + } else { + buf.fill(fill); + } + } else { + buf.fill(0); + } + return buf; + }; + SafeBuffer.allocUnsafe = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return Buffer3(size); + }; + SafeBuffer.allocUnsafeSlow = function(size) { + if (typeof size !== "number") { + throw new TypeError("Argument must be a number"); + } + return buffer.SlowBuffer(size); + }; + } +}); + +// node_modules/bl/bl.js +var require_bl = __commonJS({ + "node_modules/bl/bl.js"(exports2, module3) { + var DuplexStream = require_duplex(); + var util = require("util"); + var Buffer3 = require_safe_buffer3().Buffer; + function BufferList(callback) { + if (!(this instanceof BufferList)) + return new BufferList(callback); + this._bufs = []; + this.length = 0; + if (typeof callback == "function") { + this._callback = callback; + var piper = function piper2(err) { + if (this._callback) { + this._callback(err); + this._callback = null; + } + }.bind(this); + this.on("pipe", function onPipe(src) { + src.on("error", piper); + }); + this.on("unpipe", function onUnpipe(src) { + src.removeListener("error", piper); + }); + } else { + this.append(callback); + } + DuplexStream.call(this); + } + util.inherits(BufferList, DuplexStream); + BufferList.prototype._offset = function _offset(offset) { + var tot = 0, i = 0, _t; + if (offset === 0) return [0, 0]; + for (; i < this._bufs.length; i++) { + _t = tot + this._bufs[i].length; + if (offset < _t || i == this._bufs.length - 1) + return [i, offset - tot]; + tot = _t; + } + }; + BufferList.prototype.append = function append(buf) { + var i = 0; + if (Buffer3.isBuffer(buf)) { + this._appendBuffer(buf); + } else if (Array.isArray(buf)) { + for (; i < buf.length; i++) + this.append(buf[i]); + } else if (buf instanceof BufferList) { + for (; i < buf._bufs.length; i++) + this.append(buf._bufs[i]); + } else if (buf != null) { + if (typeof buf == "number") + buf = buf.toString(); + this._appendBuffer(Buffer3.from(buf)); + } + return this; + }; + BufferList.prototype._appendBuffer = function appendBuffer(buf) { + this._bufs.push(buf); + this.length += buf.length; + }; + BufferList.prototype._write = function _write(buf, encoding, callback) { + this._appendBuffer(buf); + if (typeof callback == "function") + callback(); + }; + BufferList.prototype._read = function _read(size) { + if (!this.length) + return this.push(null); + size = Math.min(size, this.length); + this.push(this.slice(0, size)); + this.consume(size); + }; + BufferList.prototype.end = function end(chunk) { + DuplexStream.prototype.end.call(this, chunk); + if (this._callback) { + this._callback(null, this.slice()); + this._callback = null; + } + }; + BufferList.prototype.get = function get(index4) { + return this.slice(index4, index4 + 1)[0]; + }; + BufferList.prototype.slice = function slice(start, end) { + if (typeof start == "number" && start < 0) + start += this.length; + if (typeof end == "number" && end < 0) + end += this.length; + return this.copy(null, 0, start, end); + }; + BufferList.prototype.copy = function copy(dst, dstStart, srcStart, srcEnd) { + if (typeof srcStart != "number" || srcStart < 0) + srcStart = 0; + if (typeof srcEnd != "number" || srcEnd > this.length) + srcEnd = this.length; + if (srcStart >= this.length) + return dst || Buffer3.alloc(0); + if (srcEnd <= 0) + return dst || Buffer3.alloc(0); + var copy2 = !!dst, off = this._offset(srcStart), len = srcEnd - srcStart, bytes = len, bufoff = copy2 && dstStart || 0, start = off[1], l, i; + if (srcStart === 0 && srcEnd == this.length) { + if (!copy2) { + return this._bufs.length === 1 ? this._bufs[0] : Buffer3.concat(this._bufs, this.length); + } + for (i = 0; i < this._bufs.length; i++) { + this._bufs[i].copy(dst, bufoff); + bufoff += this._bufs[i].length; + } + return dst; + } + if (bytes <= this._bufs[off[0]].length - start) { + return copy2 ? this._bufs[off[0]].copy(dst, dstStart, start, start + bytes) : this._bufs[off[0]].slice(start, start + bytes); + } + if (!copy2) + dst = Buffer3.allocUnsafe(len); + for (i = off[0]; i < this._bufs.length; i++) { + l = this._bufs[i].length - start; + if (bytes > l) { + this._bufs[i].copy(dst, bufoff, start); + bufoff += l; + } else { + this._bufs[i].copy(dst, bufoff, start, start + bytes); + bufoff += l; + break; + } + bytes -= l; + if (start) + start = 0; + } + if (dst.length > bufoff) return dst.slice(0, bufoff); + return dst; + }; + BufferList.prototype.shallowSlice = function shallowSlice(start, end) { + start = start || 0; + end = end || this.length; + if (start < 0) + start += this.length; + if (end < 0) + end += this.length; + var startOffset = this._offset(start), endOffset = this._offset(end), buffers = this._bufs.slice(startOffset[0], endOffset[0] + 1); + if (endOffset[1] == 0) + buffers.pop(); + else + buffers[buffers.length - 1] = buffers[buffers.length - 1].slice(0, endOffset[1]); + if (startOffset[1] != 0) + buffers[0] = buffers[0].slice(startOffset[1]); + return new BufferList(buffers); + }; + BufferList.prototype.toString = function toString(encoding, start, end) { + return this.slice(start, end).toString(encoding); + }; + BufferList.prototype.consume = function consume(bytes) { + bytes = Math.trunc(bytes); + if (Number.isNaN(bytes) || bytes <= 0) return this; + while (this._bufs.length) { + if (bytes >= this._bufs[0].length) { + bytes -= this._bufs[0].length; + this.length -= this._bufs[0].length; + this._bufs.shift(); + } else { + this._bufs[0] = this._bufs[0].slice(bytes); + this.length -= bytes; + break; + } + } + return this; + }; + BufferList.prototype.duplicate = function duplicate() { + var i = 0, copy = new BufferList(); + for (; i < this._bufs.length; i++) + copy.append(this._bufs[i]); + return copy; + }; + BufferList.prototype.destroy = function destroy() { + this._bufs.length = 0; + this.length = 0; + this.push(null); + }; + (function() { + var methods = { + "readDoubleBE": 8, + "readDoubleLE": 8, + "readFloatBE": 4, + "readFloatLE": 4, + "readInt32BE": 4, + "readInt32LE": 4, + "readUInt32BE": 4, + "readUInt32LE": 4, + "readInt16BE": 2, + "readInt16LE": 2, + "readUInt16BE": 2, + "readUInt16LE": 2, + "readInt8": 1, + "readUInt8": 1 + }; + for (var m in methods) { + (function(m2) { + BufferList.prototype[m2] = function(offset) { + return this.slice(offset, offset + methods[m2])[m2](0); + }; + })(m); + } + })(); + module3.exports = BufferList; + } +}); + +// node_modules/xtend/immutable.js +var require_immutable = __commonJS({ + "node_modules/xtend/immutable.js"(exports2, module3) { + module3.exports = extend; + var hasOwnProperty = Object.prototype.hasOwnProperty; + function extend() { + var target = {}; + for (var i = 0; i < arguments.length; i++) { + var source = arguments[i]; + for (var key2 in source) { + if (hasOwnProperty.call(source, key2)) { + target[key2] = source[key2]; + } + } + } + return target; + } + } +}); + +// node_modules/to-buffer/node_modules/isarray/index.js +var require_isarray2 = __commonJS({ + "node_modules/to-buffer/node_modules/isarray/index.js"(exports2, module3) { + var toString = {}.toString; + module3.exports = Array.isArray || function(arr) { + return toString.call(arr) == "[object Array]"; + }; + } +}); + +// node_modules/es-errors/type.js +var require_type = __commonJS({ + "node_modules/es-errors/type.js"(exports2, module3) { + "use strict"; + module3.exports = TypeError; + } +}); + +// node_modules/es-object-atoms/index.js +var require_es_object_atoms = __commonJS({ + "node_modules/es-object-atoms/index.js"(exports2, module3) { + "use strict"; + module3.exports = Object; + } +}); + +// node_modules/es-errors/index.js +var require_es_errors = __commonJS({ + "node_modules/es-errors/index.js"(exports2, module3) { + "use strict"; + module3.exports = Error; + } +}); + +// node_modules/es-errors/eval.js +var require_eval = __commonJS({ + "node_modules/es-errors/eval.js"(exports2, module3) { + "use strict"; + module3.exports = EvalError; + } +}); + +// node_modules/es-errors/range.js +var require_range = __commonJS({ + "node_modules/es-errors/range.js"(exports2, module3) { + "use strict"; + module3.exports = RangeError; + } +}); + +// node_modules/es-errors/ref.js +var require_ref = __commonJS({ + "node_modules/es-errors/ref.js"(exports2, module3) { + "use strict"; + module3.exports = ReferenceError; + } +}); + +// node_modules/es-errors/syntax.js +var require_syntax = __commonJS({ + "node_modules/es-errors/syntax.js"(exports2, module3) { + "use strict"; + module3.exports = SyntaxError; + } +}); + +// node_modules/es-errors/uri.js +var require_uri = __commonJS({ + "node_modules/es-errors/uri.js"(exports2, module3) { + "use strict"; + module3.exports = URIError; + } +}); + +// node_modules/math-intrinsics/abs.js +var require_abs = __commonJS({ + "node_modules/math-intrinsics/abs.js"(exports2, module3) { + "use strict"; + module3.exports = Math.abs; + } +}); + +// node_modules/math-intrinsics/floor.js +var require_floor = __commonJS({ + "node_modules/math-intrinsics/floor.js"(exports2, module3) { + "use strict"; + module3.exports = Math.floor; + } +}); + +// node_modules/math-intrinsics/max.js +var require_max = __commonJS({ + "node_modules/math-intrinsics/max.js"(exports2, module3) { + "use strict"; + module3.exports = Math.max; + } +}); + +// node_modules/math-intrinsics/min.js +var require_min = __commonJS({ + "node_modules/math-intrinsics/min.js"(exports2, module3) { + "use strict"; + module3.exports = Math.min; + } +}); + +// node_modules/math-intrinsics/pow.js +var require_pow = __commonJS({ + "node_modules/math-intrinsics/pow.js"(exports2, module3) { + "use strict"; + module3.exports = Math.pow; + } +}); + +// node_modules/math-intrinsics/round.js +var require_round = __commonJS({ + "node_modules/math-intrinsics/round.js"(exports2, module3) { + "use strict"; + module3.exports = Math.round; + } +}); + +// node_modules/math-intrinsics/isNaN.js +var require_isNaN = __commonJS({ + "node_modules/math-intrinsics/isNaN.js"(exports2, module3) { + "use strict"; + module3.exports = Number.isNaN || function isNaN2(a) { + return a !== a; + }; + } +}); + +// node_modules/math-intrinsics/sign.js +var require_sign = __commonJS({ + "node_modules/math-intrinsics/sign.js"(exports2, module3) { + "use strict"; + var $isNaN = require_isNaN(); + module3.exports = function sign(number5) { + if ($isNaN(number5) || number5 === 0) { + return number5; + } + return number5 < 0 ? -1 : 1; + }; + } +}); + +// node_modules/gopd/gOPD.js +var require_gOPD = __commonJS({ + "node_modules/gopd/gOPD.js"(exports2, module3) { + "use strict"; + module3.exports = Object.getOwnPropertyDescriptor; + } +}); + +// node_modules/gopd/index.js +var require_gopd = __commonJS({ + "node_modules/gopd/index.js"(exports2, module3) { + "use strict"; + var $gOPD = require_gOPD(); + if ($gOPD) { + try { + $gOPD([], "length"); + } catch (e) { + $gOPD = null; + } + } + module3.exports = $gOPD; + } +}); + +// node_modules/es-define-property/index.js +var require_es_define_property = __commonJS({ + "node_modules/es-define-property/index.js"(exports2, module3) { + "use strict"; + var $defineProperty = Object.defineProperty || false; + if ($defineProperty) { + try { + $defineProperty({}, "a", { value: 1 }); + } catch (e) { + $defineProperty = false; + } + } + module3.exports = $defineProperty; + } +}); + +// node_modules/has-symbols/shams.js +var require_shams = __commonJS({ + "node_modules/has-symbols/shams.js"(exports2, module3) { + "use strict"; + module3.exports = function hasSymbols() { + if (typeof Symbol !== "function" || typeof Object.getOwnPropertySymbols !== "function") { + return false; + } + if (typeof Symbol.iterator === "symbol") { + return true; + } + var obj = {}; + var sym = Symbol("test"); + var symObj = Object(sym); + if (typeof sym === "string") { + return false; + } + if (Object.prototype.toString.call(sym) !== "[object Symbol]") { + return false; + } + if (Object.prototype.toString.call(symObj) !== "[object Symbol]") { + return false; + } + var symVal = 42; + obj[sym] = symVal; + for (var _ in obj) { + return false; + } + if (typeof Object.keys === "function" && Object.keys(obj).length !== 0) { + return false; + } + if (typeof Object.getOwnPropertyNames === "function" && Object.getOwnPropertyNames(obj).length !== 0) { + return false; + } + var syms = Object.getOwnPropertySymbols(obj); + if (syms.length !== 1 || syms[0] !== sym) { + return false; + } + if (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { + return false; + } + if (typeof Object.getOwnPropertyDescriptor === "function") { + var descriptor = ( + /** @type {PropertyDescriptor} */ + Object.getOwnPropertyDescriptor(obj, sym) + ); + if (descriptor.value !== symVal || descriptor.enumerable !== true) { + return false; + } + } + return true; + }; + } +}); + +// node_modules/has-symbols/index.js +var require_has_symbols = __commonJS({ + "node_modules/has-symbols/index.js"(exports2, module3) { + "use strict"; + var origSymbol = typeof Symbol !== "undefined" && Symbol; + var hasSymbolSham = require_shams(); + module3.exports = function hasNativeSymbols() { + if (typeof origSymbol !== "function") { + return false; + } + if (typeof Symbol !== "function") { + return false; + } + if (typeof origSymbol("foo") !== "symbol") { + return false; + } + if (typeof Symbol("bar") !== "symbol") { + return false; + } + return hasSymbolSham(); + }; + } +}); + +// node_modules/get-proto/Reflect.getPrototypeOf.js +var require_Reflect_getPrototypeOf = __commonJS({ + "node_modules/get-proto/Reflect.getPrototypeOf.js"(exports2, module3) { + "use strict"; + module3.exports = typeof Reflect !== "undefined" && Reflect.getPrototypeOf || null; + } +}); + +// node_modules/get-proto/Object.getPrototypeOf.js +var require_Object_getPrototypeOf = __commonJS({ + "node_modules/get-proto/Object.getPrototypeOf.js"(exports2, module3) { + "use strict"; + var $Object = require_es_object_atoms(); + module3.exports = $Object.getPrototypeOf || null; + } +}); + +// node_modules/function-bind/implementation.js +var require_implementation = __commonJS({ + "node_modules/function-bind/implementation.js"(exports2, module3) { + "use strict"; + var ERROR_MESSAGE = "Function.prototype.bind called on incompatible "; + var toStr = Object.prototype.toString; + var max2 = Math.max; + var funcType = "[object Function]"; + var concatty = function concatty2(a, b) { + var arr = []; + for (var i = 0; i < a.length; i += 1) { + arr[i] = a[i]; + } + for (var j = 0; j < b.length; j += 1) { + arr[j + a.length] = b[j]; + } + return arr; + }; + var slicy = function slicy2(arrLike, offset) { + var arr = []; + for (var i = offset || 0, j = 0; i < arrLike.length; i += 1, j += 1) { + arr[j] = arrLike[i]; + } + return arr; + }; + var joiny = function(arr, joiner) { + var str = ""; + for (var i = 0; i < arr.length; i += 1) { + str += arr[i]; + if (i + 1 < arr.length) { + str += joiner; + } + } + return str; + }; + module3.exports = function bind(that) { + var target = this; + if (typeof target !== "function" || toStr.apply(target) !== funcType) { + throw new TypeError(ERROR_MESSAGE + target); + } + var args = slicy(arguments, 1); + var bound; + var binder = function() { + if (this instanceof bound) { + var result = target.apply( + this, + concatty(args, arguments) + ); + if (Object(result) === result) { + return result; + } + return this; + } + return target.apply( + that, + concatty(args, arguments) + ); + }; + var boundLength = max2(0, target.length - args.length); + var boundArgs = []; + for (var i = 0; i < boundLength; i++) { + boundArgs[i] = "$" + i; + } + bound = Function("binder", "return function (" + joiny(boundArgs, ",") + "){ return binder.apply(this,arguments); }")(binder); + if (target.prototype) { + var Empty = function Empty2() { + }; + Empty.prototype = target.prototype; + bound.prototype = new Empty(); + Empty.prototype = null; + } + return bound; + }; + } +}); + +// node_modules/function-bind/index.js +var require_function_bind = __commonJS({ + "node_modules/function-bind/index.js"(exports2, module3) { + "use strict"; + var implementation = require_implementation(); + module3.exports = Function.prototype.bind || implementation; + } +}); + +// node_modules/call-bind-apply-helpers/functionCall.js +var require_functionCall = __commonJS({ + "node_modules/call-bind-apply-helpers/functionCall.js"(exports2, module3) { + "use strict"; + module3.exports = Function.prototype.call; + } +}); + +// node_modules/call-bind-apply-helpers/functionApply.js +var require_functionApply = __commonJS({ + "node_modules/call-bind-apply-helpers/functionApply.js"(exports2, module3) { + "use strict"; + module3.exports = Function.prototype.apply; + } +}); + +// node_modules/call-bind-apply-helpers/reflectApply.js +var require_reflectApply = __commonJS({ + "node_modules/call-bind-apply-helpers/reflectApply.js"(exports2, module3) { + "use strict"; + module3.exports = typeof Reflect !== "undefined" && Reflect && Reflect.apply; + } +}); + +// node_modules/call-bind-apply-helpers/actualApply.js +var require_actualApply = __commonJS({ + "node_modules/call-bind-apply-helpers/actualApply.js"(exports2, module3) { + "use strict"; + var bind = require_function_bind(); + var $apply = require_functionApply(); + var $call = require_functionCall(); + var $reflectApply = require_reflectApply(); + module3.exports = $reflectApply || bind.call($call, $apply); + } +}); + +// node_modules/call-bind-apply-helpers/index.js +var require_call_bind_apply_helpers = __commonJS({ + "node_modules/call-bind-apply-helpers/index.js"(exports2, module3) { + "use strict"; + var bind = require_function_bind(); + var $TypeError = require_type(); + var $call = require_functionCall(); + var $actualApply = require_actualApply(); + module3.exports = function callBindBasic(args) { + if (args.length < 1 || typeof args[0] !== "function") { + throw new $TypeError("a function is required"); + } + return $actualApply(bind, $call, args); + }; + } +}); + +// node_modules/dunder-proto/get.js +var require_get = __commonJS({ + "node_modules/dunder-proto/get.js"(exports2, module3) { + "use strict"; + var callBind = require_call_bind_apply_helpers(); + var gOPD = require_gopd(); + var hasProtoAccessor; + try { + hasProtoAccessor = /** @type {{ __proto__?: typeof Array.prototype }} */ + [].__proto__ === Array.prototype; + } catch (e) { + if (!e || typeof e !== "object" || !("code" in e) || e.code !== "ERR_PROTO_ACCESS") { + throw e; + } + } + var desc = !!hasProtoAccessor && gOPD && gOPD( + Object.prototype, + /** @type {keyof typeof Object.prototype} */ + "__proto__" + ); + var $Object = Object; + var $getPrototypeOf = $Object.getPrototypeOf; + module3.exports = desc && typeof desc.get === "function" ? callBind([desc.get]) : typeof $getPrototypeOf === "function" ? ( + /** @type {import('./get')} */ + function getDunder(value) { + return $getPrototypeOf(value == null ? value : $Object(value)); + } + ) : false; + } +}); + +// node_modules/get-proto/index.js +var require_get_proto = __commonJS({ + "node_modules/get-proto/index.js"(exports2, module3) { + "use strict"; + var reflectGetProto = require_Reflect_getPrototypeOf(); + var originalGetProto = require_Object_getPrototypeOf(); + var getDunderProto = require_get(); + module3.exports = reflectGetProto ? function getProto(O) { + return reflectGetProto(O); + } : originalGetProto ? function getProto(O) { + if (!O || typeof O !== "object" && typeof O !== "function") { + throw new TypeError("getProto: not an object"); + } + return originalGetProto(O); + } : getDunderProto ? function getProto(O) { + return getDunderProto(O); + } : null; + } +}); + +// node_modules/hasown/index.js +var require_hasown = __commonJS({ + "node_modules/hasown/index.js"(exports2, module3) { + "use strict"; + var call = Function.prototype.call; + var $hasOwn = Object.prototype.hasOwnProperty; + var bind = require_function_bind(); + module3.exports = bind.call(call, $hasOwn); + } +}); + +// node_modules/get-intrinsic/index.js +var require_get_intrinsic = __commonJS({ + "node_modules/get-intrinsic/index.js"(exports2, module3) { + "use strict"; + var undefined2; + var $Object = require_es_object_atoms(); + var $Error = require_es_errors(); + var $EvalError = require_eval(); + var $RangeError = require_range(); + var $ReferenceError = require_ref(); + var $SyntaxError = require_syntax(); + var $TypeError = require_type(); + var $URIError = require_uri(); + var abs = require_abs(); + var floor = require_floor(); + var max2 = require_max(); + var min2 = require_min(); + var pow = require_pow(); + var round = require_round(); + var sign = require_sign(); + var $Function = Function; + var getEvalledConstructor = function(expressionSyntax) { + try { + return $Function('"use strict"; return (' + expressionSyntax + ").constructor;")(); + } catch (e) { + } + }; + var $gOPD = require_gopd(); + var $defineProperty = require_es_define_property(); + var throwTypeError = function() { + throw new $TypeError(); + }; + var ThrowTypeError = $gOPD ? (function() { + try { + arguments.callee; + return throwTypeError; + } catch (calleeThrows) { + try { + return $gOPD(arguments, "callee").get; + } catch (gOPDthrows) { + return throwTypeError; + } + } + })() : throwTypeError; + var hasSymbols = require_has_symbols()(); + var getProto = require_get_proto(); + var $ObjectGPO = require_Object_getPrototypeOf(); + var $ReflectGPO = require_Reflect_getPrototypeOf(); + var $apply = require_functionApply(); + var $call = require_functionCall(); + var needsEval = {}; + var TypedArray = typeof Uint8Array === "undefined" || !getProto ? undefined2 : getProto(Uint8Array); + var INTRINSICS = { + __proto__: null, + "%AggregateError%": typeof AggregateError === "undefined" ? undefined2 : AggregateError, + "%Array%": Array, + "%ArrayBuffer%": typeof ArrayBuffer === "undefined" ? undefined2 : ArrayBuffer, + "%ArrayIteratorPrototype%": hasSymbols && getProto ? getProto([][Symbol.iterator]()) : undefined2, + "%AsyncFromSyncIteratorPrototype%": undefined2, + "%AsyncFunction%": needsEval, + "%AsyncGenerator%": needsEval, + "%AsyncGeneratorFunction%": needsEval, + "%AsyncIteratorPrototype%": needsEval, + "%Atomics%": typeof Atomics === "undefined" ? undefined2 : Atomics, + "%BigInt%": typeof BigInt === "undefined" ? undefined2 : BigInt, + "%BigInt64Array%": typeof BigInt64Array === "undefined" ? undefined2 : BigInt64Array, + "%BigUint64Array%": typeof BigUint64Array === "undefined" ? undefined2 : BigUint64Array, + "%Boolean%": Boolean, + "%DataView%": typeof DataView === "undefined" ? undefined2 : DataView, + "%Date%": Date, + "%decodeURI%": decodeURI, + "%decodeURIComponent%": decodeURIComponent, + "%encodeURI%": encodeURI, + "%encodeURIComponent%": encodeURIComponent, + "%Error%": $Error, + "%eval%": eval, + // eslint-disable-line no-eval + "%EvalError%": $EvalError, + "%Float16Array%": typeof Float16Array === "undefined" ? undefined2 : Float16Array, + "%Float32Array%": typeof Float32Array === "undefined" ? undefined2 : Float32Array, + "%Float64Array%": typeof Float64Array === "undefined" ? undefined2 : Float64Array, + "%FinalizationRegistry%": typeof FinalizationRegistry === "undefined" ? undefined2 : FinalizationRegistry, + "%Function%": $Function, + "%GeneratorFunction%": needsEval, + "%Int8Array%": typeof Int8Array === "undefined" ? undefined2 : Int8Array, + "%Int16Array%": typeof Int16Array === "undefined" ? undefined2 : Int16Array, + "%Int32Array%": typeof Int32Array === "undefined" ? undefined2 : Int32Array, + "%isFinite%": isFinite, + "%isNaN%": isNaN, + "%IteratorPrototype%": hasSymbols && getProto ? getProto(getProto([][Symbol.iterator]())) : undefined2, + "%JSON%": typeof JSON === "object" ? JSON : undefined2, + "%Map%": typeof Map === "undefined" ? undefined2 : Map, + "%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols || !getProto ? undefined2 : getProto((/* @__PURE__ */ new Map())[Symbol.iterator]()), + "%Math%": Math, + "%Number%": Number, + "%Object%": $Object, + "%Object.getOwnPropertyDescriptor%": $gOPD, + "%parseFloat%": parseFloat, + "%parseInt%": parseInt, + "%Promise%": typeof Promise === "undefined" ? undefined2 : Promise, + "%Proxy%": typeof Proxy === "undefined" ? undefined2 : Proxy, + "%RangeError%": $RangeError, + "%ReferenceError%": $ReferenceError, + "%Reflect%": typeof Reflect === "undefined" ? undefined2 : Reflect, + "%RegExp%": RegExp, + "%Set%": typeof Set === "undefined" ? undefined2 : Set, + "%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols || !getProto ? undefined2 : getProto((/* @__PURE__ */ new Set())[Symbol.iterator]()), + "%SharedArrayBuffer%": typeof SharedArrayBuffer === "undefined" ? undefined2 : SharedArrayBuffer, + "%String%": String, + "%StringIteratorPrototype%": hasSymbols && getProto ? getProto(""[Symbol.iterator]()) : undefined2, + "%Symbol%": hasSymbols ? Symbol : undefined2, + "%SyntaxError%": $SyntaxError, + "%ThrowTypeError%": ThrowTypeError, + "%TypedArray%": TypedArray, + "%TypeError%": $TypeError, + "%Uint8Array%": typeof Uint8Array === "undefined" ? undefined2 : Uint8Array, + "%Uint8ClampedArray%": typeof Uint8ClampedArray === "undefined" ? undefined2 : Uint8ClampedArray, + "%Uint16Array%": typeof Uint16Array === "undefined" ? undefined2 : Uint16Array, + "%Uint32Array%": typeof Uint32Array === "undefined" ? undefined2 : Uint32Array, + "%URIError%": $URIError, + "%WeakMap%": typeof WeakMap === "undefined" ? undefined2 : WeakMap, + "%WeakRef%": typeof WeakRef === "undefined" ? undefined2 : WeakRef, + "%WeakSet%": typeof WeakSet === "undefined" ? undefined2 : WeakSet, + "%Function.prototype.call%": $call, + "%Function.prototype.apply%": $apply, + "%Object.defineProperty%": $defineProperty, + "%Object.getPrototypeOf%": $ObjectGPO, + "%Math.abs%": abs, + "%Math.floor%": floor, + "%Math.max%": max2, + "%Math.min%": min2, + "%Math.pow%": pow, + "%Math.round%": round, + "%Math.sign%": sign, + "%Reflect.getPrototypeOf%": $ReflectGPO + }; + if (getProto) { + try { + null.error; + } catch (e) { + errorProto = getProto(getProto(e)); + INTRINSICS["%Error.prototype%"] = errorProto; + } + } + var errorProto; + var doEval = function doEval2(name) { + var value; + if (name === "%AsyncFunction%") { + value = getEvalledConstructor("async function () {}"); + } else if (name === "%GeneratorFunction%") { + value = getEvalledConstructor("function* () {}"); + } else if (name === "%AsyncGeneratorFunction%") { + value = getEvalledConstructor("async function* () {}"); + } else if (name === "%AsyncGenerator%") { + var fn = doEval2("%AsyncGeneratorFunction%"); + if (fn) { + value = fn.prototype; + } + } else if (name === "%AsyncIteratorPrototype%") { + var gen = doEval2("%AsyncGenerator%"); + if (gen && getProto) { + value = getProto(gen.prototype); + } + } + INTRINSICS[name] = value; + return value; + }; + var LEGACY_ALIASES = { + __proto__: null, + "%ArrayBufferPrototype%": ["ArrayBuffer", "prototype"], + "%ArrayPrototype%": ["Array", "prototype"], + "%ArrayProto_entries%": ["Array", "prototype", "entries"], + "%ArrayProto_forEach%": ["Array", "prototype", "forEach"], + "%ArrayProto_keys%": ["Array", "prototype", "keys"], + "%ArrayProto_values%": ["Array", "prototype", "values"], + "%AsyncFunctionPrototype%": ["AsyncFunction", "prototype"], + "%AsyncGenerator%": ["AsyncGeneratorFunction", "prototype"], + "%AsyncGeneratorPrototype%": ["AsyncGeneratorFunction", "prototype", "prototype"], + "%BooleanPrototype%": ["Boolean", "prototype"], + "%DataViewPrototype%": ["DataView", "prototype"], + "%DatePrototype%": ["Date", "prototype"], + "%ErrorPrototype%": ["Error", "prototype"], + "%EvalErrorPrototype%": ["EvalError", "prototype"], + "%Float32ArrayPrototype%": ["Float32Array", "prototype"], + "%Float64ArrayPrototype%": ["Float64Array", "prototype"], + "%FunctionPrototype%": ["Function", "prototype"], + "%Generator%": ["GeneratorFunction", "prototype"], + "%GeneratorPrototype%": ["GeneratorFunction", "prototype", "prototype"], + "%Int8ArrayPrototype%": ["Int8Array", "prototype"], + "%Int16ArrayPrototype%": ["Int16Array", "prototype"], + "%Int32ArrayPrototype%": ["Int32Array", "prototype"], + "%JSONParse%": ["JSON", "parse"], + "%JSONStringify%": ["JSON", "stringify"], + "%MapPrototype%": ["Map", "prototype"], + "%NumberPrototype%": ["Number", "prototype"], + "%ObjectPrototype%": ["Object", "prototype"], + "%ObjProto_toString%": ["Object", "prototype", "toString"], + "%ObjProto_valueOf%": ["Object", "prototype", "valueOf"], + "%PromisePrototype%": ["Promise", "prototype"], + "%PromiseProto_then%": ["Promise", "prototype", "then"], + "%Promise_all%": ["Promise", "all"], + "%Promise_reject%": ["Promise", "reject"], + "%Promise_resolve%": ["Promise", "resolve"], + "%RangeErrorPrototype%": ["RangeError", "prototype"], + "%ReferenceErrorPrototype%": ["ReferenceError", "prototype"], + "%RegExpPrototype%": ["RegExp", "prototype"], + "%SetPrototype%": ["Set", "prototype"], + "%SharedArrayBufferPrototype%": ["SharedArrayBuffer", "prototype"], + "%StringPrototype%": ["String", "prototype"], + "%SymbolPrototype%": ["Symbol", "prototype"], + "%SyntaxErrorPrototype%": ["SyntaxError", "prototype"], + "%TypedArrayPrototype%": ["TypedArray", "prototype"], + "%TypeErrorPrototype%": ["TypeError", "prototype"], + "%Uint8ArrayPrototype%": ["Uint8Array", "prototype"], + "%Uint8ClampedArrayPrototype%": ["Uint8ClampedArray", "prototype"], + "%Uint16ArrayPrototype%": ["Uint16Array", "prototype"], + "%Uint32ArrayPrototype%": ["Uint32Array", "prototype"], + "%URIErrorPrototype%": ["URIError", "prototype"], + "%WeakMapPrototype%": ["WeakMap", "prototype"], + "%WeakSetPrototype%": ["WeakSet", "prototype"] + }; + var bind = require_function_bind(); + var hasOwn = require_hasown(); + var $concat = bind.call($call, Array.prototype.concat); + var $spliceApply = bind.call($apply, Array.prototype.splice); + var $replace = bind.call($call, String.prototype.replace); + var $strSlice = bind.call($call, String.prototype.slice); + var $exec = bind.call($call, RegExp.prototype.exec); + var rePropName = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g; + var reEscapeChar = /\\(\\)?/g; + var stringToPath = function stringToPath2(string11) { + var first = $strSlice(string11, 0, 1); + var last = $strSlice(string11, -1); + if (first === "%" && last !== "%") { + throw new $SyntaxError("invalid intrinsic syntax, expected closing `%`"); + } else if (last === "%" && first !== "%") { + throw new $SyntaxError("invalid intrinsic syntax, expected opening `%`"); + } + var result = []; + $replace(string11, rePropName, function(match, number5, quote2, subString) { + result[result.length] = quote2 ? $replace(subString, reEscapeChar, "$1") : number5 || match; + }); + return result; + }; + var getBaseIntrinsic = function getBaseIntrinsic2(name, allowMissing) { + var intrinsicName = name; + var alias; + if (hasOwn(LEGACY_ALIASES, intrinsicName)) { + alias = LEGACY_ALIASES[intrinsicName]; + intrinsicName = "%" + alias[0] + "%"; + } + if (hasOwn(INTRINSICS, intrinsicName)) { + var value = INTRINSICS[intrinsicName]; + if (value === needsEval) { + value = doEval(intrinsicName); + } + if (typeof value === "undefined" && !allowMissing) { + throw new $TypeError("intrinsic " + name + " exists, but is not available. Please file an issue!"); + } + return { + alias, + name: intrinsicName, + value + }; + } + throw new $SyntaxError("intrinsic " + name + " does not exist!"); + }; + module3.exports = function GetIntrinsic(name, allowMissing) { + if (typeof name !== "string" || name.length === 0) { + throw new $TypeError("intrinsic name must be a non-empty string"); + } + if (arguments.length > 1 && typeof allowMissing !== "boolean") { + throw new $TypeError('"allowMissing" argument must be a boolean'); + } + if ($exec(/^%?[^%]*%?$/, name) === null) { + throw new $SyntaxError("`%` may not be present anywhere but at the beginning and end of the intrinsic name"); + } + var parts = stringToPath(name); + var intrinsicBaseName = parts.length > 0 ? parts[0] : ""; + var intrinsic = getBaseIntrinsic("%" + intrinsicBaseName + "%", allowMissing); + var intrinsicRealName = intrinsic.name; + var value = intrinsic.value; + var skipFurtherCaching = false; + var alias = intrinsic.alias; + if (alias) { + intrinsicBaseName = alias[0]; + $spliceApply(parts, $concat([0, 1], alias)); + } + for (var i = 1, isOwn = true; i < parts.length; i += 1) { + var part = parts[i]; + var first = $strSlice(part, 0, 1); + var last = $strSlice(part, -1); + if ((first === '"' || first === "'" || first === "`" || (last === '"' || last === "'" || last === "`")) && first !== last) { + throw new $SyntaxError("property names with quotes must have matching quotes"); + } + if (part === "constructor" || !isOwn) { + skipFurtherCaching = true; + } + intrinsicBaseName += "." + part; + intrinsicRealName = "%" + intrinsicBaseName + "%"; + if (hasOwn(INTRINSICS, intrinsicRealName)) { + value = INTRINSICS[intrinsicRealName]; + } else if (value != null) { + if (!(part in value)) { + if (!allowMissing) { + throw new $TypeError("base intrinsic for " + name + " exists, but the property is not available."); + } + return void undefined2; + } + if ($gOPD && i + 1 >= parts.length) { + var desc = $gOPD(value, part); + isOwn = !!desc; + if (isOwn && "get" in desc && !("originalValue" in desc.get)) { + value = desc.get; + } else { + value = value[part]; + } + } else { + isOwn = hasOwn(value, part); + value = value[part]; + } + if (isOwn && !skipFurtherCaching) { + INTRINSICS[intrinsicRealName] = value; + } + } + } + return value; + }; + } +}); + +// node_modules/call-bound/index.js +var require_call_bound = __commonJS({ + "node_modules/call-bound/index.js"(exports2, module3) { + "use strict"; + var GetIntrinsic = require_get_intrinsic(); + var callBindBasic = require_call_bind_apply_helpers(); + var $indexOf = callBindBasic([GetIntrinsic("%String.prototype.indexOf%")]); + module3.exports = function callBoundIntrinsic(name, allowMissing) { + var intrinsic = ( + /** @type {(this: unknown, ...args: unknown[]) => unknown} */ + GetIntrinsic(name, !!allowMissing) + ); + if (typeof intrinsic === "function" && $indexOf(name, ".prototype.") > -1) { + return callBindBasic( + /** @type {const} */ + [intrinsic] + ); + } + return intrinsic; + }; + } +}); + +// node_modules/is-callable/index.js +var require_is_callable = __commonJS({ + "node_modules/is-callable/index.js"(exports2, module3) { + "use strict"; + var fnToStr = Function.prototype.toString; + var reflectApply = typeof Reflect === "object" && Reflect !== null && Reflect.apply; + var badArrayLike; + var isCallableMarker; + if (typeof reflectApply === "function" && typeof Object.defineProperty === "function") { + try { + badArrayLike = Object.defineProperty({}, "length", { + get: function() { + throw isCallableMarker; + } + }); + isCallableMarker = {}; + reflectApply(function() { + throw 42; + }, null, badArrayLike); + } catch (_) { + if (_ !== isCallableMarker) { + reflectApply = null; + } + } + } else { + reflectApply = null; + } + var constructorRegex = /^\s*class\b/; + var isES6ClassFn = function isES6ClassFunction(value) { + try { + var fnStr = fnToStr.call(value); + return constructorRegex.test(fnStr); + } catch (e) { + return false; + } + }; + var tryFunctionObject = function tryFunctionToStr(value) { + try { + if (isES6ClassFn(value)) { + return false; + } + fnToStr.call(value); + return true; + } catch (e) { + return false; + } + }; + var toStr = Object.prototype.toString; + var objectClass = "[object Object]"; + var fnClass = "[object Function]"; + var genClass = "[object GeneratorFunction]"; + var ddaClass = "[object HTMLAllCollection]"; + var ddaClass2 = "[object HTML document.all class]"; + var ddaClass3 = "[object HTMLCollection]"; + var hasToStringTag = typeof Symbol === "function" && !!Symbol.toStringTag; + var isIE68 = !(0 in [,]); + var isDDA = function isDocumentDotAll() { + return false; + }; + if (typeof document === "object") { + all = document.all; + if (toStr.call(all) === toStr.call(document.all)) { + isDDA = function isDocumentDotAll(value) { + if ((isIE68 || !value) && (typeof value === "undefined" || typeof value === "object")) { + try { + var str = toStr.call(value); + return (str === ddaClass || str === ddaClass2 || str === ddaClass3 || str === objectClass) && value("") == null; + } catch (e) { + } + } + return false; + }; + } + } + var all; + module3.exports = reflectApply ? function isCallable(value) { + if (isDDA(value)) { + return true; + } + if (!value) { + return false; + } + if (typeof value !== "function" && typeof value !== "object") { + return false; + } + try { + reflectApply(value, null, badArrayLike); + } catch (e) { + if (e !== isCallableMarker) { + return false; + } + } + return !isES6ClassFn(value) && tryFunctionObject(value); + } : function isCallable(value) { + if (isDDA(value)) { + return true; + } + if (!value) { + return false; + } + if (typeof value !== "function" && typeof value !== "object") { + return false; + } + if (hasToStringTag) { + return tryFunctionObject(value); + } + if (isES6ClassFn(value)) { + return false; + } + var strClass = toStr.call(value); + if (strClass !== fnClass && strClass !== genClass && !/^\[object HTML/.test(strClass)) { + return false; + } + return tryFunctionObject(value); + }; + } +}); + +// node_modules/for-each/index.js +var require_for_each = __commonJS({ + "node_modules/for-each/index.js"(exports2, module3) { + "use strict"; + var isCallable = require_is_callable(); + var toStr = Object.prototype.toString; + var hasOwnProperty = Object.prototype.hasOwnProperty; + var forEachArray = function forEachArray2(array4, iterator, receiver) { + for (var i = 0, len = array4.length; i < len; i++) { + if (hasOwnProperty.call(array4, i)) { + if (receiver == null) { + iterator(array4[i], i, array4); + } else { + iterator.call(receiver, array4[i], i, array4); + } + } + } + }; + var forEachString = function forEachString2(string11, iterator, receiver) { + for (var i = 0, len = string11.length; i < len; i++) { + if (receiver == null) { + iterator(string11.charAt(i), i, string11); + } else { + iterator.call(receiver, string11.charAt(i), i, string11); + } + } + }; + var forEachObject = function forEachObject2(object5, iterator, receiver) { + for (var k in object5) { + if (hasOwnProperty.call(object5, k)) { + if (receiver == null) { + iterator(object5[k], k, object5); + } else { + iterator.call(receiver, object5[k], k, object5); + } + } + } + }; + function isArray(x) { + return toStr.call(x) === "[object Array]"; + } + module3.exports = function forEach(list4, iterator, thisArg) { + if (!isCallable(iterator)) { + throw new TypeError("iterator must be a function"); + } + var receiver; + if (arguments.length >= 3) { + receiver = thisArg; + } + if (isArray(list4)) { + forEachArray(list4, iterator, receiver); + } else if (typeof list4 === "string") { + forEachString(list4, iterator, receiver); + } else { + forEachObject(list4, iterator, receiver); + } + }; + } +}); + +// node_modules/possible-typed-array-names/index.js +var require_possible_typed_array_names = __commonJS({ + "node_modules/possible-typed-array-names/index.js"(exports2, module3) { + "use strict"; + module3.exports = [ + "Float16Array", + "Float32Array", + "Float64Array", + "Int8Array", + "Int16Array", + "Int32Array", + "Uint8Array", + "Uint8ClampedArray", + "Uint16Array", + "Uint32Array", + "BigInt64Array", + "BigUint64Array" + ]; + } +}); + +// node_modules/available-typed-arrays/index.js +var require_available_typed_arrays = __commonJS({ + "node_modules/available-typed-arrays/index.js"(exports2, module3) { + "use strict"; + var possibleNames = require_possible_typed_array_names(); + var g = typeof globalThis === "undefined" ? global : globalThis; + module3.exports = function availableTypedArrays() { + var out = []; + for (var i = 0; i < possibleNames.length; i++) { + if (typeof g[possibleNames[i]] === "function") { + out[out.length] = possibleNames[i]; + } + } + return out; + }; + } +}); + +// node_modules/define-data-property/index.js +var require_define_data_property = __commonJS({ + "node_modules/define-data-property/index.js"(exports2, module3) { + "use strict"; + var $defineProperty = require_es_define_property(); + var $SyntaxError = require_syntax(); + var $TypeError = require_type(); + var gopd = require_gopd(); + module3.exports = function defineDataProperty(obj, property, value) { + if (!obj || typeof obj !== "object" && typeof obj !== "function") { + throw new $TypeError("`obj` must be an object or a function`"); + } + if (typeof property !== "string" && typeof property !== "symbol") { + throw new $TypeError("`property` must be a string or a symbol`"); + } + if (arguments.length > 3 && typeof arguments[3] !== "boolean" && arguments[3] !== null) { + throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null"); + } + if (arguments.length > 4 && typeof arguments[4] !== "boolean" && arguments[4] !== null) { + throw new $TypeError("`nonWritable`, if provided, must be a boolean or null"); + } + if (arguments.length > 5 && typeof arguments[5] !== "boolean" && arguments[5] !== null) { + throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null"); + } + if (arguments.length > 6 && typeof arguments[6] !== "boolean") { + throw new $TypeError("`loose`, if provided, must be a boolean"); + } + var nonEnumerable = arguments.length > 3 ? arguments[3] : null; + var nonWritable = arguments.length > 4 ? arguments[4] : null; + var nonConfigurable = arguments.length > 5 ? arguments[5] : null; + var loose = arguments.length > 6 ? arguments[6] : false; + var desc = !!gopd && gopd(obj, property); + if ($defineProperty) { + $defineProperty(obj, property, { + configurable: nonConfigurable === null && desc ? desc.configurable : !nonConfigurable, + enumerable: nonEnumerable === null && desc ? desc.enumerable : !nonEnumerable, + value, + writable: nonWritable === null && desc ? desc.writable : !nonWritable + }); + } else if (loose || !nonEnumerable && !nonWritable && !nonConfigurable) { + obj[property] = value; + } else { + throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable."); + } + }; + } +}); + +// node_modules/has-property-descriptors/index.js +var require_has_property_descriptors = __commonJS({ + "node_modules/has-property-descriptors/index.js"(exports2, module3) { + "use strict"; + var $defineProperty = require_es_define_property(); + var hasPropertyDescriptors = function hasPropertyDescriptors2() { + return !!$defineProperty; + }; + hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBug() { + if (!$defineProperty) { + return null; + } + try { + return $defineProperty([], "length", { value: 1 }).length !== 1; + } catch (e) { + return true; + } + }; + module3.exports = hasPropertyDescriptors; + } +}); + +// node_modules/set-function-length/index.js +var require_set_function_length = __commonJS({ + "node_modules/set-function-length/index.js"(exports2, module3) { + "use strict"; + var GetIntrinsic = require_get_intrinsic(); + var define = require_define_data_property(); + var hasDescriptors = require_has_property_descriptors()(); + var gOPD = require_gopd(); + var $TypeError = require_type(); + var $floor = GetIntrinsic("%Math.floor%"); + module3.exports = function setFunctionLength(fn, length) { + if (typeof fn !== "function") { + throw new $TypeError("`fn` is not a function"); + } + if (typeof length !== "number" || length < 0 || length > 4294967295 || $floor(length) !== length) { + throw new $TypeError("`length` must be a positive 32-bit integer"); + } + var loose = arguments.length > 2 && !!arguments[2]; + var functionLengthIsConfigurable = true; + var functionLengthIsWritable = true; + if ("length" in fn && gOPD) { + var desc = gOPD(fn, "length"); + if (desc && !desc.configurable) { + functionLengthIsConfigurable = false; + } + if (desc && !desc.writable) { + functionLengthIsWritable = false; + } + } + if (functionLengthIsConfigurable || functionLengthIsWritable || !loose) { + if (hasDescriptors) { + define( + /** @type {Parameters[0]} */ + fn, + "length", + length, + true, + true + ); + } else { + define( + /** @type {Parameters[0]} */ + fn, + "length", + length + ); + } + } + return fn; + }; + } +}); + +// node_modules/call-bind-apply-helpers/applyBind.js +var require_applyBind = __commonJS({ + "node_modules/call-bind-apply-helpers/applyBind.js"(exports2, module3) { + "use strict"; + var bind = require_function_bind(); + var $apply = require_functionApply(); + var actualApply = require_actualApply(); + module3.exports = function applyBind() { + return actualApply(bind, $apply, arguments); + }; + } +}); + +// node_modules/call-bind/index.js +var require_call_bind = __commonJS({ + "node_modules/call-bind/index.js"(exports2, module3) { + "use strict"; + var setFunctionLength = require_set_function_length(); + var $defineProperty = require_es_define_property(); + var callBindBasic = require_call_bind_apply_helpers(); + var applyBind = require_applyBind(); + module3.exports = function callBind(originalFunction) { + var func = callBindBasic(arguments); + var adjustedLength = 1 + originalFunction.length - (arguments.length - 1); + return setFunctionLength( + func, + adjustedLength > 0 ? adjustedLength : 0, + true + ); + }; + if ($defineProperty) { + $defineProperty(module3.exports, "apply", { value: applyBind }); + } else { + module3.exports.apply = applyBind; + } + } +}); + +// node_modules/has-tostringtag/shams.js +var require_shams2 = __commonJS({ + "node_modules/has-tostringtag/shams.js"(exports2, module3) { + "use strict"; + var hasSymbols = require_shams(); + module3.exports = function hasToStringTagShams() { + return hasSymbols() && !!Symbol.toStringTag; + }; + } +}); + +// node_modules/which-typed-array/index.js +var require_which_typed_array = __commonJS({ + "node_modules/which-typed-array/index.js"(exports2, module3) { + "use strict"; + var forEach = require_for_each(); + var availableTypedArrays = require_available_typed_arrays(); + var callBind = require_call_bind(); + var callBound = require_call_bound(); + var gOPD = require_gopd(); + var getProto = require_get_proto(); + var $toString = callBound("Object.prototype.toString"); + var hasToStringTag = require_shams2()(); + var g = typeof globalThis === "undefined" ? global : globalThis; + var typedArrays = availableTypedArrays(); + var $slice = callBound("String.prototype.slice"); + var $indexOf = callBound("Array.prototype.indexOf", true) || function indexOf(array4, value) { + for (var i = 0; i < array4.length; i += 1) { + if (array4[i] === value) { + return i; + } + } + return -1; + }; + var cache = { __proto__: null }; + if (hasToStringTag && gOPD && getProto) { + forEach(typedArrays, function(typedArray) { + var arr = new g[typedArray](); + if (Symbol.toStringTag in arr && getProto) { + var proto = getProto(arr); + var descriptor = gOPD(proto, Symbol.toStringTag); + if (!descriptor && proto) { + var superProto = getProto(proto); + descriptor = gOPD(superProto, Symbol.toStringTag); + } + if (descriptor && descriptor.get) { + var bound = callBind(descriptor.get); + cache[ + /** @type {`$${TypedArrayName}`} */ + "$" + typedArray + ] = bound; + } + } + }); + } else { + forEach(typedArrays, function(typedArray) { + var arr = new g[typedArray](); + var fn = arr.slice || arr.set; + if (fn) { + var bound = ( + /** @type {BoundSlice | BoundSet} */ + // @ts-expect-error TODO FIXME + callBind(fn) + ); + cache[ + /** @type {`$${TypedArrayName}`} */ + "$" + typedArray + ] = bound; + } + }); + } + function tryTypedArrays(value) { + var found = false; + forEach( + /** @type {Record<`$${TypedArrayName}`, Getter>} */ + cache, + /** @param {Getter} getter @param {`$${TypedArrayName}`} typedArray */ + function(getter, typedArray) { + if (!found) { + try { + if ("$" + getter(value) === typedArray) { + found = /** @type {TypedArrayName} */ + $slice(typedArray, 1); + } + } catch (e) { + } + } + } + ); + return found; + } + function trySlices(value) { + var found = false; + forEach( + /** @type {Record<`$${TypedArrayName}`, Getter>} */ + cache, + /** @param {Getter} getter @param {`$${TypedArrayName}`} name */ + function(getter, name) { + if (!found) { + try { + getter(value); + found = /** @type {TypedArrayName} */ + $slice(name, 1); + } catch (e) { + } + } + } + ); + return found; + } + function isTATag(tag2) { + return $indexOf(typedArrays, tag2) > -1; + } + module3.exports = function whichTypedArray(value) { + if (!value || typeof value !== "object") { + return false; + } + if (!hasToStringTag) { + var tag2 = $slice($toString(value), 8, -1); + if (isTATag(tag2)) { + return tag2; + } + if (tag2 !== "Object") { + return false; + } + return trySlices(value); + } + if (!gOPD) { + return null; + } + return tryTypedArrays(value); + }; + } +}); + +// node_modules/is-typed-array/index.js +var require_is_typed_array = __commonJS({ + "node_modules/is-typed-array/index.js"(exports2, module3) { + "use strict"; + var whichTypedArray = require_which_typed_array(); + module3.exports = function isTypedArray(value) { + return !!whichTypedArray(value); + }; + } +}); + +// node_modules/typed-array-buffer/index.js +var require_typed_array_buffer = __commonJS({ + "node_modules/typed-array-buffer/index.js"(exports2, module3) { + "use strict"; + var $TypeError = require_type(); + var callBound = require_call_bound(); + var $typedArrayBuffer = callBound("TypedArray.prototype.buffer", true); + var isTypedArray = require_is_typed_array(); + module3.exports = $typedArrayBuffer || function typedArrayBuffer(x) { + if (!isTypedArray(x)) { + throw new $TypeError("Not a Typed Array"); + } + return x.buffer; + }; + } +}); + +// node_modules/to-buffer/index.js +var require_to_buffer = __commonJS({ + "node_modules/to-buffer/index.js"(exports2, module3) { + "use strict"; + var Buffer3 = require_safe_buffer3().Buffer; + var isArray = require_isarray2(); + var typedArrayBuffer = require_typed_array_buffer(); + var isView = ArrayBuffer.isView || function isView2(obj) { + try { + typedArrayBuffer(obj); + return true; + } catch (e) { + return false; + } + }; + var useUint8Array = typeof Uint8Array !== "undefined"; + var useArrayBuffer = typeof ArrayBuffer !== "undefined" && typeof Uint8Array !== "undefined"; + var useFromArrayBuffer = useArrayBuffer && (Buffer3.prototype instanceof Uint8Array || Buffer3.TYPED_ARRAY_SUPPORT); + module3.exports = function toBuffer(data, encoding) { + if (Buffer3.isBuffer(data)) { + if (data.constructor && !("isBuffer" in data)) { + return Buffer3.from(data); + } + return data; + } + if (typeof data === "string") { + return Buffer3.from(data, encoding); + } + if (useArrayBuffer && isView(data)) { + if (data.byteLength === 0) { + return Buffer3.alloc(0); + } + if (useFromArrayBuffer) { + var res = Buffer3.from(data.buffer, data.byteOffset, data.byteLength); + if (res.byteLength === data.byteLength) { + return res; + } + } + var uint8 = data instanceof Uint8Array ? data : new Uint8Array(data.buffer, data.byteOffset, data.byteLength); + var result = Buffer3.from(uint8); + if (result.length === data.byteLength) { + return result; + } + } + if (useUint8Array && data instanceof Uint8Array) { + return Buffer3.from(data); + } + var isArr = isArray(data); + if (isArr) { + for (var i = 0; i < data.length; i += 1) { + var x = data[i]; + if (typeof x !== "number" || x < 0 || x > 255 || ~~x !== x) { + throw new RangeError("Array items must be numbers in the range 0-255."); + } + } + } + if (isArr || Buffer3.isBuffer(data) && data.constructor && typeof data.constructor.isBuffer === "function" && data.constructor.isBuffer(data)) { + return Buffer3.from(data); + } + throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.'); + }; + } +}); + +// node_modules/buffer-fill/index.js +var require_buffer_fill = __commonJS({ + "node_modules/buffer-fill/index.js"(exports2, module3) { + var hasFullSupport = (function() { + try { + if (!Buffer.isEncoding("latin1")) { + return false; + } + var buf = Buffer.alloc ? Buffer.alloc(4) : new Buffer(4); + buf.fill("ab", "ucs2"); + return buf.toString("hex") === "61006200"; + } catch (_) { + return false; + } + })(); + function isSingleByte(val) { + return val.length === 1 && val.charCodeAt(0) < 256; + } + function fillWithNumber(buffer, val, start, end) { + if (start < 0 || end > buffer.length) { + throw new RangeError("Out of range index"); + } + start = start >>> 0; + end = end === void 0 ? buffer.length : end >>> 0; + if (end > start) { + buffer.fill(val, start, end); + } + return buffer; + } + function fillWithBuffer(buffer, val, start, end) { + if (start < 0 || end > buffer.length) { + throw new RangeError("Out of range index"); + } + if (end <= start) { + return buffer; + } + start = start >>> 0; + end = end === void 0 ? buffer.length : end >>> 0; + var pos = start; + var len = val.length; + while (pos <= end - len) { + val.copy(buffer, pos); + pos += len; + } + if (pos !== end) { + val.copy(buffer, pos, 0, end - pos); + } + return buffer; + } + function fill(buffer, val, start, end, encoding) { + if (hasFullSupport) { + return buffer.fill(val, start, end, encoding); + } + if (typeof val === "number") { + return fillWithNumber(buffer, val, start, end); + } + if (typeof val === "string") { + if (typeof start === "string") { + encoding = start; + start = 0; + end = buffer.length; + } else if (typeof end === "string") { + encoding = end; + end = buffer.length; + } + if (encoding !== void 0 && typeof encoding !== "string") { + throw new TypeError("encoding must be a string"); + } + if (encoding === "latin1") { + encoding = "binary"; + } + if (typeof encoding === "string" && !Buffer.isEncoding(encoding)) { + throw new TypeError("Unknown encoding: " + encoding); + } + if (val === "") { + return fillWithNumber(buffer, 0, start, end); + } + if (isSingleByte(val)) { + return fillWithNumber(buffer, val.charCodeAt(0), start, end); + } + val = new Buffer(val, encoding); + } + if (Buffer.isBuffer(val)) { + return fillWithBuffer(buffer, val, start, end); + } + return fillWithNumber(buffer, 0, start, end); + } + module3.exports = fill; + } +}); + +// node_modules/buffer-alloc-unsafe/index.js +var require_buffer_alloc_unsafe = __commonJS({ + "node_modules/buffer-alloc-unsafe/index.js"(exports2, module3) { + function allocUnsafe(size) { + if (typeof size !== "number") { + throw new TypeError('"size" argument must be a number'); + } + if (size < 0) { + throw new RangeError('"size" argument must not be negative'); + } + if (Buffer.allocUnsafe) { + return Buffer.allocUnsafe(size); + } else { + return new Buffer(size); + } + } + module3.exports = allocUnsafe; + } +}); + +// node_modules/buffer-alloc/index.js +var require_buffer_alloc = __commonJS({ + "node_modules/buffer-alloc/index.js"(exports2, module3) { + var bufferFill = require_buffer_fill(); + var allocUnsafe = require_buffer_alloc_unsafe(); + module3.exports = function alloc(size, fill, encoding) { + if (typeof size !== "number") { + throw new TypeError('"size" argument must be a number'); + } + if (size < 0) { + throw new RangeError('"size" argument must not be negative'); + } + if (Buffer.alloc) { + return Buffer.alloc(size, fill, encoding); + } + var buffer = allocUnsafe(size); + if (size === 0) { + return buffer; + } + if (fill === void 0) { + return bufferFill(buffer, 0); + } + if (typeof encoding !== "string") { + encoding = void 0; + } + return bufferFill(buffer, fill, encoding); + }; + } +}); + +// node_modules/tar-stream/headers.js +var require_headers = __commonJS({ + "node_modules/tar-stream/headers.js"(exports2) { + var toBuffer = require_to_buffer(); + var alloc = require_buffer_alloc(); + var ZEROS = "0000000000000000000"; + var SEVENS = "7777777777777777777"; + var ZERO_OFFSET = "0".charCodeAt(0); + var USTAR = "ustar\x0000"; + var MASK = parseInt("7777", 8); + var clamp = function(index4, len, defaultValue) { + if (typeof index4 !== "number") return defaultValue; + index4 = ~~index4; + if (index4 >= len) return len; + if (index4 >= 0) return index4; + index4 += len; + if (index4 >= 0) return index4; + return 0; + }; + var toType = function(flag) { + switch (flag) { + case 0: + return "file"; + case 1: + return "link"; + case 2: + return "symlink"; + case 3: + return "character-device"; + case 4: + return "block-device"; + case 5: + return "directory"; + case 6: + return "fifo"; + case 7: + return "contiguous-file"; + case 72: + return "pax-header"; + case 55: + return "pax-global-header"; + case 27: + return "gnu-long-link-path"; + case 28: + case 30: + return "gnu-long-path"; + } + return null; + }; + var toTypeflag = function(flag) { + switch (flag) { + case "file": + return 0; + case "link": + return 1; + case "symlink": + return 2; + case "character-device": + return 3; + case "block-device": + return 4; + case "directory": + return 5; + case "fifo": + return 6; + case "contiguous-file": + return 7; + case "pax-header": + return 72; + } + return 0; + }; + var indexOf = function(block4, num, offset, end) { + for (; offset < end; offset++) { + if (block4[offset] === num) return offset; + } + return end; + }; + var cksum = function(block4) { + var sum = 8 * 32; + for (var i = 0; i < 148; i++) sum += block4[i]; + for (var j = 156; j < 512; j++) sum += block4[j]; + return sum; + }; + var encodeOct = function(val, n) { + val = val.toString(8); + if (val.length > n) return SEVENS.slice(0, n) + " "; + else return ZEROS.slice(0, n - val.length) + val + " "; + }; + function parse256(buf) { + var positive; + if (buf[0] === 128) positive = true; + else if (buf[0] === 255) positive = false; + else return null; + var zero = false; + var tuple = []; + for (var i = buf.length - 1; i > 0; i--) { + var byte = buf[i]; + if (positive) tuple.push(byte); + else if (zero && byte === 0) tuple.push(0); + else if (zero) { + zero = false; + tuple.push(256 - byte); + } else tuple.push(255 - byte); + } + var sum = 0; + var l = tuple.length; + for (i = 0; i < l; i++) { + sum += tuple[i] * Math.pow(256, i); + } + return positive ? sum : -1 * sum; + } + var decodeOct = function(val, offset, length) { + val = val.slice(offset, offset + length); + offset = 0; + if (val[offset] & 128) { + return parse256(val); + } else { + while (offset < val.length && val[offset] === 32) offset++; + var end = clamp(indexOf(val, 32, offset, val.length), val.length, val.length); + while (offset < end && val[offset] === 0) offset++; + if (end === offset) return 0; + return parseInt(val.slice(offset, end).toString(), 8); + } + }; + var decodeStr = function(val, offset, length, encoding) { + return val.slice(offset, indexOf(val, 0, offset, offset + length)).toString(encoding); + }; + var addLength = function(str) { + var len = Buffer.byteLength(str); + var digits = Math.floor(Math.log(len) / Math.log(10)) + 1; + if (len + digits >= Math.pow(10, digits)) digits++; + return len + digits + str; + }; + exports2.decodeLongPath = function(buf, encoding) { + return decodeStr(buf, 0, buf.length, encoding); + }; + exports2.encodePax = function(opts) { + var result = ""; + if (opts.name) result += addLength(" path=" + opts.name + "\n"); + if (opts.linkname) result += addLength(" linkpath=" + opts.linkname + "\n"); + var pax = opts.pax; + if (pax) { + for (var key2 in pax) { + result += addLength(" " + key2 + "=" + pax[key2] + "\n"); + } + } + return toBuffer(result); + }; + exports2.decodePax = function(buf) { + var result = {}; + while (buf.length) { + var i = 0; + while (i < buf.length && buf[i] !== 32) i++; + var len = parseInt(buf.slice(0, i).toString(), 10); + if (!len) return result; + var b = buf.slice(i + 1, len - 1).toString(); + var keyIndex = b.indexOf("="); + if (keyIndex === -1) return result; + result[b.slice(0, keyIndex)] = b.slice(keyIndex + 1); + buf = buf.slice(len); + } + return result; + }; + exports2.encode = function(opts) { + var buf = alloc(512); + var name = opts.name; + var prefix = ""; + if (opts.typeflag === 5 && name[name.length - 1] !== "/") name += "/"; + if (Buffer.byteLength(name) !== name.length) return null; + while (Buffer.byteLength(name) > 100) { + var i = name.indexOf("/"); + if (i === -1) return null; + prefix += prefix ? "/" + name.slice(0, i) : name.slice(0, i); + name = name.slice(i + 1); + } + if (Buffer.byteLength(name) > 100 || Buffer.byteLength(prefix) > 155) return null; + if (opts.linkname && Buffer.byteLength(opts.linkname) > 100) return null; + buf.write(name); + buf.write(encodeOct(opts.mode & MASK, 6), 100); + buf.write(encodeOct(opts.uid, 6), 108); + buf.write(encodeOct(opts.gid, 6), 116); + buf.write(encodeOct(opts.size, 11), 124); + buf.write(encodeOct(opts.mtime.getTime() / 1e3 | 0, 11), 136); + buf[156] = ZERO_OFFSET + toTypeflag(opts.type); + if (opts.linkname) buf.write(opts.linkname, 157); + buf.write(USTAR, 257); + if (opts.uname) buf.write(opts.uname, 265); + if (opts.gname) buf.write(opts.gname, 297); + buf.write(encodeOct(opts.devmajor || 0, 6), 329); + buf.write(encodeOct(opts.devminor || 0, 6), 337); + if (prefix) buf.write(prefix, 345); + buf.write(encodeOct(cksum(buf), 6), 148); + return buf; + }; + exports2.decode = function(buf, filenameEncoding) { + var typeflag = buf[156] === 0 ? 0 : buf[156] - ZERO_OFFSET; + var name = decodeStr(buf, 0, 100, filenameEncoding); + var mode = decodeOct(buf, 100, 8); + var uid = decodeOct(buf, 108, 8); + var gid = decodeOct(buf, 116, 8); + var size = decodeOct(buf, 124, 12); + var mtime = decodeOct(buf, 136, 12); + var type2 = toType(typeflag); + var linkname = buf[157] === 0 ? null : decodeStr(buf, 157, 100, filenameEncoding); + var uname = decodeStr(buf, 265, 32); + var gname = decodeStr(buf, 297, 32); + var devmajor = decodeOct(buf, 329, 8); + var devminor = decodeOct(buf, 337, 8); + if (buf[345]) name = decodeStr(buf, 345, 155, filenameEncoding) + "/" + name; + if (typeflag === 0 && name && name[name.length - 1] === "/") typeflag = 5; + var c = cksum(buf); + if (c === 8 * 32) return null; + if (c !== decodeOct(buf, 148, 8)) throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?"); + return { + name, + mode, + uid, + gid, + size, + mtime: new Date(1e3 * mtime), + type: type2, + linkname, + uname, + gname, + devmajor, + devminor + }; + }; + } +}); + +// node_modules/tar-stream/extract.js +var require_extract = __commonJS({ + "node_modules/tar-stream/extract.js"(exports2, module3) { + var util = require("util"); + var bl = require_bl(); + var xtend = require_immutable(); + var headers = require_headers(); + var Writable = require_readable().Writable; + var PassThrough = require_readable().PassThrough; + var noop6 = function() { + }; + var overflow = function(size) { + size &= 511; + return size && 512 - size; + }; + var emptyStream = function(self2, offset) { + var s = new Source2(self2, offset); + s.end(); + return s; + }; + var mixinPax = function(header, pax) { + if (pax.path) header.name = pax.path; + if (pax.linkpath) header.linkname = pax.linkpath; + if (pax.size) header.size = parseInt(pax.size, 10); + header.pax = pax; + return header; + }; + var Source2 = function(self2, offset) { + this._parent = self2; + this.offset = offset; + PassThrough.call(this); + }; + util.inherits(Source2, PassThrough); + Source2.prototype.destroy = function(err) { + this._parent.destroy(err); + }; + var Extract = function(opts) { + if (!(this instanceof Extract)) return new Extract(opts); + Writable.call(this, opts); + opts = opts || {}; + this._offset = 0; + this._buffer = bl(); + this._missing = 0; + this._partial = false; + this._onparse = noop6; + this._header = null; + this._stream = null; + this._overflow = null; + this._cb = null; + this._locked = false; + this._destroyed = false; + this._pax = null; + this._paxGlobal = null; + this._gnuLongPath = null; + this._gnuLongLinkPath = null; + var self2 = this; + var b = self2._buffer; + var oncontinue = function() { + self2._continue(); + }; + var onunlock = function(err) { + self2._locked = false; + if (err) return self2.destroy(err); + if (!self2._stream) oncontinue(); + }; + var onstreamend = function() { + self2._stream = null; + var drain = overflow(self2._header.size); + if (drain) self2._parse(drain, ondrain); + else self2._parse(512, onheader); + if (!self2._locked) oncontinue(); + }; + var ondrain = function() { + self2._buffer.consume(overflow(self2._header.size)); + self2._parse(512, onheader); + oncontinue(); + }; + var onpaxglobalheader = function() { + var size = self2._header.size; + self2._paxGlobal = headers.decodePax(b.slice(0, size)); + b.consume(size); + onstreamend(); + }; + var onpaxheader = function() { + var size = self2._header.size; + self2._pax = headers.decodePax(b.slice(0, size)); + if (self2._paxGlobal) self2._pax = xtend(self2._paxGlobal, self2._pax); + b.consume(size); + onstreamend(); + }; + var ongnulongpath = function() { + var size = self2._header.size; + this._gnuLongPath = headers.decodeLongPath(b.slice(0, size), opts.filenameEncoding); + b.consume(size); + onstreamend(); + }; + var ongnulonglinkpath = function() { + var size = self2._header.size; + this._gnuLongLinkPath = headers.decodeLongPath(b.slice(0, size), opts.filenameEncoding); + b.consume(size); + onstreamend(); + }; + var onheader = function() { + var offset = self2._offset; + var header; + try { + header = self2._header = headers.decode(b.slice(0, 512), opts.filenameEncoding); + } catch (err) { + self2.emit("error", err); + } + b.consume(512); + if (!header) { + self2._parse(512, onheader); + oncontinue(); + return; + } + if (header.type === "gnu-long-path") { + self2._parse(header.size, ongnulongpath); + oncontinue(); + return; + } + if (header.type === "gnu-long-link-path") { + self2._parse(header.size, ongnulonglinkpath); + oncontinue(); + return; + } + if (header.type === "pax-global-header") { + self2._parse(header.size, onpaxglobalheader); + oncontinue(); + return; + } + if (header.type === "pax-header") { + self2._parse(header.size, onpaxheader); + oncontinue(); + return; + } + if (self2._gnuLongPath) { + header.name = self2._gnuLongPath; + self2._gnuLongPath = null; + } + if (self2._gnuLongLinkPath) { + header.linkname = self2._gnuLongLinkPath; + self2._gnuLongLinkPath = null; + } + if (self2._pax) { + self2._header = header = mixinPax(header, self2._pax); + self2._pax = null; + } + self2._locked = true; + if (!header.size || header.type === "directory") { + self2._parse(512, onheader); + self2.emit("entry", header, emptyStream(self2, offset), onunlock); + return; + } + self2._stream = new Source2(self2, offset); + self2.emit("entry", header, self2._stream, onunlock); + self2._parse(header.size, onstreamend); + oncontinue(); + }; + this._onheader = onheader; + this._parse(512, onheader); + }; + util.inherits(Extract, Writable); + Extract.prototype.destroy = function(err) { + if (this._destroyed) return; + this._destroyed = true; + if (err) this.emit("error", err); + this.emit("close"); + if (this._stream) this._stream.emit("close"); + }; + Extract.prototype._parse = function(size, onparse) { + if (this._destroyed) return; + this._offset += size; + this._missing = size; + if (onparse === this._onheader) this._partial = false; + this._onparse = onparse; + }; + Extract.prototype._continue = function() { + if (this._destroyed) return; + var cb = this._cb; + this._cb = noop6; + if (this._overflow) this._write(this._overflow, void 0, cb); + else cb(); + }; + Extract.prototype._write = function(data, enc, cb) { + if (this._destroyed) return; + var s = this._stream; + var b = this._buffer; + var missing = this._missing; + if (data.length) this._partial = true; + if (data.length < missing) { + this._missing -= data.length; + this._overflow = null; + if (s) return s.write(data, cb); + b.append(data); + return cb(); + } + this._cb = cb; + this._missing = 0; + var overflow2 = null; + if (data.length > missing) { + overflow2 = data.slice(missing); + data = data.slice(0, missing); + } + if (s) s.end(data); + else b.append(data); + this._overflow = overflow2; + this._onparse(); + }; + Extract.prototype._final = function(cb) { + if (this._partial) return this.destroy(new Error("Unexpected end of data")); + cb(); + }; + module3.exports = Extract; + } +}); + +// node_modules/fs-constants/index.js +var require_fs_constants = __commonJS({ + "node_modules/fs-constants/index.js"(exports2, module3) { + module3.exports = require("fs").constants || require("constants"); + } +}); + +// node_modules/wrappy/wrappy.js +var require_wrappy = __commonJS({ + "node_modules/wrappy/wrappy.js"(exports2, module3) { + module3.exports = wrappy; + function wrappy(fn, cb) { + if (fn && cb) return wrappy(fn)(cb); + if (typeof fn !== "function") + throw new TypeError("need wrapper function"); + Object.keys(fn).forEach(function(k) { + wrapper[k] = fn[k]; + }); + return wrapper; + function wrapper() { + var args = new Array(arguments.length); + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i]; + } + var ret = fn.apply(this, args); + var cb2 = args[args.length - 1]; + if (typeof ret === "function" && ret !== cb2) { + Object.keys(cb2).forEach(function(k) { + ret[k] = cb2[k]; + }); + } + return ret; + } + } + } +}); + +// node_modules/once/once.js +var require_once = __commonJS({ + "node_modules/once/once.js"(exports2, module3) { + var wrappy = require_wrappy(); + module3.exports = wrappy(once); + module3.exports.strict = wrappy(onceStrict); + once.proto = once(function() { + Object.defineProperty(Function.prototype, "once", { + value: function() { + return once(this); + }, + configurable: true + }); + Object.defineProperty(Function.prototype, "onceStrict", { + value: function() { + return onceStrict(this); + }, + configurable: true + }); + }); + function once(fn) { + var f = function() { + if (f.called) return f.value; + f.called = true; + return f.value = fn.apply(this, arguments); + }; + f.called = false; + return f; + } + function onceStrict(fn) { + var f = function() { + if (f.called) + throw new Error(f.onceError); + f.called = true; + return f.value = fn.apply(this, arguments); + }; + var name = fn.name || "Function wrapped with `once`"; + f.onceError = name + " shouldn't be called more than once"; + f.called = false; + return f; + } + } +}); + +// node_modules/end-of-stream/index.js +var require_end_of_stream = __commonJS({ + "node_modules/end-of-stream/index.js"(exports2, module3) { + var once = require_once(); + var noop6 = function() { + }; + var qnt = global.Bare ? queueMicrotask : process.nextTick.bind(process); + var isRequest = function(stream2) { + return stream2.setHeader && typeof stream2.abort === "function"; + }; + var isChildProcess = function(stream2) { + return stream2.stdio && Array.isArray(stream2.stdio) && stream2.stdio.length === 3; + }; + var eos = function(stream2, opts, callback) { + if (typeof opts === "function") return eos(stream2, null, opts); + if (!opts) opts = {}; + callback = once(callback || noop6); + var ws = stream2._writableState; + var rs = stream2._readableState; + var readable = opts.readable || opts.readable !== false && stream2.readable; + var writable = opts.writable || opts.writable !== false && stream2.writable; + var cancelled = false; + var onlegacyfinish = function() { + if (!stream2.writable) onfinish(); + }; + var onfinish = function() { + writable = false; + if (!readable) callback.call(stream2); + }; + var onend = function() { + readable = false; + if (!writable) callback.call(stream2); + }; + var onexit = function(exitCode) { + callback.call(stream2, exitCode ? new Error("exited with error code: " + exitCode) : null); + }; + var onerror = function(err) { + callback.call(stream2, err); + }; + var onclose = function() { + qnt(onclosenexttick); + }; + var onclosenexttick = function() { + if (cancelled) return; + if (readable && !(rs && (rs.ended && !rs.destroyed))) return callback.call(stream2, new Error("premature close")); + if (writable && !(ws && (ws.ended && !ws.destroyed))) return callback.call(stream2, new Error("premature close")); + }; + var onrequest = function() { + stream2.req.on("finish", onfinish); + }; + if (isRequest(stream2)) { + stream2.on("complete", onfinish); + stream2.on("abort", onclose); + if (stream2.req) onrequest(); + else stream2.on("request", onrequest); + } else if (writable && !ws) { + stream2.on("end", onlegacyfinish); + stream2.on("close", onlegacyfinish); + } + if (isChildProcess(stream2)) stream2.on("exit", onexit); + stream2.on("end", onend); + stream2.on("finish", onfinish); + if (opts.error !== false) stream2.on("error", onerror); + stream2.on("close", onclose); + return function() { + cancelled = true; + stream2.removeListener("complete", onfinish); + stream2.removeListener("abort", onclose); + stream2.removeListener("request", onrequest); + if (stream2.req) stream2.req.removeListener("finish", onfinish); + stream2.removeListener("end", onlegacyfinish); + stream2.removeListener("close", onlegacyfinish); + stream2.removeListener("finish", onfinish); + stream2.removeListener("exit", onexit); + stream2.removeListener("end", onend); + stream2.removeListener("error", onerror); + stream2.removeListener("close", onclose); + }; + }; + module3.exports = eos; + } +}); + +// node_modules/tar-stream/pack.js +var require_pack = __commonJS({ + "node_modules/tar-stream/pack.js"(exports2, module3) { + var constants = require_fs_constants(); + var eos = require_end_of_stream(); + var util = require("util"); + var alloc = require_buffer_alloc(); + var toBuffer = require_to_buffer(); + var Readable = require_readable().Readable; + var Writable = require_readable().Writable; + var StringDecoder = require("string_decoder").StringDecoder; + var headers = require_headers(); + var DMODE = parseInt("755", 8); + var FMODE = parseInt("644", 8); + var END_OF_TAR = alloc(1024); + var noop6 = function() { + }; + var overflow = function(self2, size) { + size &= 511; + if (size) self2.push(END_OF_TAR.slice(0, 512 - size)); + }; + function modeToType(mode) { + switch (mode & constants.S_IFMT) { + case constants.S_IFBLK: + return "block-device"; + case constants.S_IFCHR: + return "character-device"; + case constants.S_IFDIR: + return "directory"; + case constants.S_IFIFO: + return "fifo"; + case constants.S_IFLNK: + return "symlink"; + } + return "file"; + } + var Sink = function(to) { + Writable.call(this); + this.written = 0; + this._to = to; + this._destroyed = false; + }; + util.inherits(Sink, Writable); + Sink.prototype._write = function(data, enc, cb) { + this.written += data.length; + if (this._to.push(data)) return cb(); + this._to._drain = cb; + }; + Sink.prototype.destroy = function() { + if (this._destroyed) return; + this._destroyed = true; + this.emit("close"); + }; + var LinkSink = function() { + Writable.call(this); + this.linkname = ""; + this._decoder = new StringDecoder("utf-8"); + this._destroyed = false; + }; + util.inherits(LinkSink, Writable); + LinkSink.prototype._write = function(data, enc, cb) { + this.linkname += this._decoder.write(data); + cb(); + }; + LinkSink.prototype.destroy = function() { + if (this._destroyed) return; + this._destroyed = true; + this.emit("close"); + }; + var Void = function() { + Writable.call(this); + this._destroyed = false; + }; + util.inherits(Void, Writable); + Void.prototype._write = function(data, enc, cb) { + cb(new Error("No body allowed for this entry")); + }; + Void.prototype.destroy = function() { + if (this._destroyed) return; + this._destroyed = true; + this.emit("close"); + }; + var Pack = function(opts) { + if (!(this instanceof Pack)) return new Pack(opts); + Readable.call(this, opts); + this._drain = noop6; + this._finalized = false; + this._finalizing = false; + this._destroyed = false; + this._stream = null; + }; + util.inherits(Pack, Readable); + Pack.prototype.entry = function(header, buffer, callback) { + if (this._stream) throw new Error("already piping an entry"); + if (this._finalized || this._destroyed) return; + if (typeof buffer === "function") { + callback = buffer; + buffer = null; + } + if (!callback) callback = noop6; + var self2 = this; + if (!header.size || header.type === "symlink") header.size = 0; + if (!header.type) header.type = modeToType(header.mode); + if (!header.mode) header.mode = header.type === "directory" ? DMODE : FMODE; + if (!header.uid) header.uid = 0; + if (!header.gid) header.gid = 0; + if (!header.mtime) header.mtime = /* @__PURE__ */ new Date(); + if (typeof buffer === "string") buffer = toBuffer(buffer); + if (Buffer.isBuffer(buffer)) { + header.size = buffer.length; + this._encode(header); + this.push(buffer); + overflow(self2, header.size); + process.nextTick(callback); + return new Void(); + } + if (header.type === "symlink" && !header.linkname) { + var linkSink = new LinkSink(); + eos(linkSink, function(err) { + if (err) { + self2.destroy(); + return callback(err); + } + header.linkname = linkSink.linkname; + self2._encode(header); + callback(); + }); + return linkSink; + } + this._encode(header); + if (header.type !== "file" && header.type !== "contiguous-file") { + process.nextTick(callback); + return new Void(); + } + var sink = new Sink(this); + this._stream = sink; + eos(sink, function(err) { + self2._stream = null; + if (err) { + self2.destroy(); + return callback(err); + } + if (sink.written !== header.size) { + self2.destroy(); + return callback(new Error("size mismatch")); + } + overflow(self2, header.size); + if (self2._finalizing) self2.finalize(); + callback(); + }); + return sink; + }; + Pack.prototype.finalize = function() { + if (this._stream) { + this._finalizing = true; + return; + } + if (this._finalized) return; + this._finalized = true; + this.push(END_OF_TAR); + this.push(null); + }; + Pack.prototype.destroy = function(err) { + if (this._destroyed) return; + this._destroyed = true; + if (err) this.emit("error", err); + this.emit("close"); + if (this._stream && this._stream.destroy) this._stream.destroy(); + }; + Pack.prototype._encode = function(header) { + if (!header.pax) { + var buf = headers.encode(header); + if (buf) { + this.push(buf); + return; + } + } + this._encodePax(header); + }; + Pack.prototype._encodePax = function(header) { + var paxHeader = headers.encodePax({ + name: header.name, + linkname: header.linkname, + pax: header.pax + }); + var newHeader = { + name: "PaxHeader", + mode: header.mode, + uid: header.uid, + gid: header.gid, + size: paxHeader.length, + mtime: header.mtime, + type: "pax-header", + linkname: header.linkname && "PaxHeader", + uname: header.uname, + gname: header.gname, + devmajor: header.devmajor, + devminor: header.devminor + }; + this.push(headers.encode(newHeader)); + this.push(paxHeader); + overflow(this, paxHeader.length); + newHeader.size = header.size; + newHeader.type = header.type; + this.push(headers.encode(newHeader)); + }; + Pack.prototype._read = function(n) { + var drain = this._drain; + this._drain = noop6; + drain(); + }; + module3.exports = Pack; + } +}); + +// node_modules/tar-stream/index.js +var require_tar_stream = __commonJS({ + "node_modules/tar-stream/index.js"(exports2) { + exports2.extract = require_extract(); + exports2.pack = require_pack(); + } +}); + +// node_modules/decompress-tar/index.js +var require_decompress_tar = __commonJS({ + "node_modules/decompress-tar/index.js"(exports2, module3) { + "use strict"; + var fileType = require_file_type(); + var isStream = require_is_stream(); + var tarStream = require_tar_stream(); + module3.exports = () => (input) => { + if (!Buffer.isBuffer(input) && !isStream(input)) { + return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); + } + if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "tar")) { + return Promise.resolve([]); + } + const extract = tarStream.extract(); + const files = []; + extract.on("entry", (header, stream2, cb) => { + const chunk = []; + stream2.on("data", (data) => chunk.push(data)); + stream2.on("end", () => { + const file9 = { + data: Buffer.concat(chunk), + mode: header.mode, + mtime: header.mtime, + path: header.name, + type: header.type + }; + if (header.type === "symlink" || header.type === "link") { + file9.linkname = header.linkname; + } + files.push(file9); + cb(); + }); + }); + const promise = new Promise((resolve2, reject) => { + if (!Buffer.isBuffer(input)) { + input.on("error", reject); + } + extract.on("finish", () => resolve2(files)); + extract.on("error", reject); + }); + extract.then = promise.then.bind(promise); + extract.catch = promise.catch.bind(promise); + if (Buffer.isBuffer(input)) { + extract.end(input); + } else { + input.pipe(extract); + } + return extract; + }; + } +}); + +// node_modules/decompress-tarbz2/node_modules/file-type/index.js +var require_file_type2 = __commonJS({ + "node_modules/decompress-tarbz2/node_modules/file-type/index.js"(exports2, module3) { + "use strict"; + var toBytes = (s) => Array.from(s).map((c) => c.charCodeAt(0)); + var xpiZipFilename = toBytes("META-INF/mozilla.rsa"); + var oxmlContentTypes = toBytes("[Content_Types].xml"); + var oxmlRels = toBytes("_rels/.rels"); + module3.exports = (input) => { + const buf = new Uint8Array(input); + if (!(buf && buf.length > 1)) { + return null; + } + const check = (header, opts) => { + opts = Object.assign({ + offset: 0 + }, opts); + for (let i = 0; i < header.length; i++) { + if (opts.mask) { + if (header[i] !== (opts.mask[i] & buf[i + opts.offset])) { + return false; + } + } else if (header[i] !== buf[i + opts.offset]) { + return false; + } + } + return true; + }; + if (check([255, 216, 255])) { + return { + ext: "jpg", + mime: "image/jpeg" + }; + } + if (check([137, 80, 78, 71, 13, 10, 26, 10])) { + return { + ext: "png", + mime: "image/png" + }; + } + if (check([71, 73, 70])) { + return { + ext: "gif", + mime: "image/gif" + }; + } + if (check([87, 69, 66, 80], { offset: 8 })) { + return { + ext: "webp", + mime: "image/webp" + }; + } + if (check([70, 76, 73, 70])) { + return { + ext: "flif", + mime: "image/flif" + }; + } + if ((check([73, 73, 42, 0]) || check([77, 77, 0, 42])) && check([67, 82], { offset: 8 })) { + return { + ext: "cr2", + mime: "image/x-canon-cr2" + }; + } + if (check([73, 73, 42, 0]) || check([77, 77, 0, 42])) { + return { + ext: "tif", + mime: "image/tiff" + }; + } + if (check([66, 77])) { + return { + ext: "bmp", + mime: "image/bmp" + }; + } + if (check([73, 73, 188])) { + return { + ext: "jxr", + mime: "image/vnd.ms-photo" + }; + } + if (check([56, 66, 80, 83])) { + return { + ext: "psd", + mime: "image/vnd.adobe.photoshop" + }; + } + if (check([80, 75, 3, 4])) { + if (check([109, 105, 109, 101, 116, 121, 112, 101, 97, 112, 112, 108, 105, 99, 97, 116, 105, 111, 110, 47, 101, 112, 117, 98, 43, 122, 105, 112], { offset: 30 })) { + return { + ext: "epub", + mime: "application/epub+zip" + }; + } + if (check(xpiZipFilename, { offset: 30 })) { + return { + ext: "xpi", + mime: "application/x-xpinstall" + }; + } + if (check(oxmlContentTypes, { offset: 30 }) || check(oxmlRels, { offset: 30 })) { + const sliced = buf.subarray(4, 4 + 2e3); + const nextZipHeaderIndex = (arr) => arr.findIndex((el, i, arr2) => arr2[i] === 80 && arr2[i + 1] === 75 && arr2[i + 2] === 3 && arr2[i + 3] === 4); + const header2Pos = nextZipHeaderIndex(sliced); + if (header2Pos !== -1) { + const slicedAgain = buf.subarray(header2Pos + 8, header2Pos + 8 + 1e3); + const header3Pos = nextZipHeaderIndex(slicedAgain); + if (header3Pos !== -1) { + const offset = 8 + header2Pos + header3Pos + 30; + if (check(toBytes("word/"), { offset })) { + return { + ext: "docx", + mime: "application/vnd.openxmlformats-officedocument.wordprocessingml.document" + }; + } + if (check(toBytes("ppt/"), { offset })) { + return { + ext: "pptx", + mime: "application/vnd.openxmlformats-officedocument.presentationml.presentation" + }; + } + if (check(toBytes("xl/"), { offset })) { + return { + ext: "xlsx", + mime: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" + }; + } + } + } + } + } + if (check([80, 75]) && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { + return { + ext: "zip", + mime: "application/zip" + }; + } + if (check([117, 115, 116, 97, 114], { offset: 257 })) { + return { + ext: "tar", + mime: "application/x-tar" + }; + } + if (check([82, 97, 114, 33, 26, 7]) && (buf[6] === 0 || buf[6] === 1)) { + return { + ext: "rar", + mime: "application/x-rar-compressed" + }; + } + if (check([31, 139, 8])) { + return { + ext: "gz", + mime: "application/gzip" + }; + } + if (check([66, 90, 104])) { + return { + ext: "bz2", + mime: "application/x-bzip2" + }; + } + if (check([55, 122, 188, 175, 39, 28])) { + return { + ext: "7z", + mime: "application/x-7z-compressed" + }; + } + if (check([120, 1])) { + return { + ext: "dmg", + mime: "application/x-apple-diskimage" + }; + } + if (check([51, 103, 112, 53]) || // 3gp5 + check([0, 0, 0]) && check([102, 116, 121, 112], { offset: 4 }) && (check([109, 112, 52, 49], { offset: 8 }) || // MP41 + check([109, 112, 52, 50], { offset: 8 }) || // MP42 + check([105, 115, 111, 109], { offset: 8 }) || // ISOM + check([105, 115, 111, 50], { offset: 8 }) || // ISO2 + check([109, 109, 112, 52], { offset: 8 }) || // MMP4 + check([77, 52, 86], { offset: 8 }) || // M4V + check([100, 97, 115, 104], { offset: 8 }))) { + return { + ext: "mp4", + mime: "video/mp4" + }; + } + if (check([77, 84, 104, 100])) { + return { + ext: "mid", + mime: "audio/midi" + }; + } + if (check([26, 69, 223, 163])) { + const sliced = buf.subarray(4, 4 + 4096); + const idPos = sliced.findIndex((el, i, arr) => arr[i] === 66 && arr[i + 1] === 130); + if (idPos !== -1) { + const docTypePos = idPos + 3; + const findDocType = (type2) => Array.from(type2).every((c, i) => sliced[docTypePos + i] === c.charCodeAt(0)); + if (findDocType("matroska")) { + return { + ext: "mkv", + mime: "video/x-matroska" + }; + } + if (findDocType("webm")) { + return { + ext: "webm", + mime: "video/webm" + }; + } + } + } + if (check([0, 0, 0, 20, 102, 116, 121, 112, 113, 116, 32, 32]) || check([102, 114, 101, 101], { offset: 4 }) || check([102, 116, 121, 112, 113, 116, 32, 32], { offset: 4 }) || check([109, 100, 97, 116], { offset: 4 }) || // MJPEG + check([119, 105, 100, 101], { offset: 4 })) { + return { + ext: "mov", + mime: "video/quicktime" + }; + } + if (check([82, 73, 70, 70]) && check([65, 86, 73], { offset: 8 })) { + return { + ext: "avi", + mime: "video/x-msvideo" + }; + } + if (check([48, 38, 178, 117, 142, 102, 207, 17, 166, 217])) { + return { + ext: "wmv", + mime: "video/x-ms-wmv" + }; + } + if (check([0, 0, 1, 186])) { + return { + ext: "mpg", + mime: "video/mpeg" + }; + } + for (let start = 0; start < 2 && start < buf.length - 16; start++) { + if (check([73, 68, 51], { offset: start }) || // ID3 header + check([255, 226], { offset: start, mask: [255, 226] })) { + return { + ext: "mp3", + mime: "audio/mpeg" + }; + } + } + if (check([102, 116, 121, 112, 77, 52, 65], { offset: 4 }) || check([77, 52, 65, 32])) { + return { + ext: "m4a", + mime: "audio/m4a" + }; + } + if (check([79, 112, 117, 115, 72, 101, 97, 100], { offset: 28 })) { + return { + ext: "opus", + mime: "audio/opus" + }; + } + if (check([79, 103, 103, 83])) { + return { + ext: "ogg", + mime: "audio/ogg" + }; + } + if (check([102, 76, 97, 67])) { + return { + ext: "flac", + mime: "audio/x-flac" + }; + } + if (check([82, 73, 70, 70]) && check([87, 65, 86, 69], { offset: 8 })) { + return { + ext: "wav", + mime: "audio/x-wav" + }; + } + if (check([35, 33, 65, 77, 82, 10])) { + return { + ext: "amr", + mime: "audio/amr" + }; + } + if (check([37, 80, 68, 70])) { + return { + ext: "pdf", + mime: "application/pdf" + }; + } + if (check([77, 90])) { + return { + ext: "exe", + mime: "application/x-msdownload" + }; + } + if ((buf[0] === 67 || buf[0] === 70) && check([87, 83], { offset: 1 })) { + return { + ext: "swf", + mime: "application/x-shockwave-flash" + }; + } + if (check([123, 92, 114, 116, 102])) { + return { + ext: "rtf", + mime: "application/rtf" + }; + } + if (check([0, 97, 115, 109])) { + return { + ext: "wasm", + mime: "application/wasm" + }; + } + if (check([119, 79, 70, 70]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { + return { + ext: "woff", + mime: "font/woff" + }; + } + if (check([119, 79, 70, 50]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { + return { + ext: "woff2", + mime: "font/woff2" + }; + } + if (check([76, 80], { offset: 34 }) && (check([0, 0, 1], { offset: 8 }) || check([1, 0, 2], { offset: 8 }) || check([2, 0, 2], { offset: 8 }))) { + return { + ext: "eot", + mime: "application/octet-stream" + }; + } + if (check([0, 1, 0, 0, 0])) { + return { + ext: "ttf", + mime: "font/ttf" + }; + } + if (check([79, 84, 84, 79, 0])) { + return { + ext: "otf", + mime: "font/otf" + }; + } + if (check([0, 0, 1, 0])) { + return { + ext: "ico", + mime: "image/x-icon" + }; + } + if (check([70, 76, 86, 1])) { + return { + ext: "flv", + mime: "video/x-flv" + }; + } + if (check([37, 33])) { + return { + ext: "ps", + mime: "application/postscript" + }; + } + if (check([253, 55, 122, 88, 90, 0])) { + return { + ext: "xz", + mime: "application/x-xz" + }; + } + if (check([83, 81, 76, 105])) { + return { + ext: "sqlite", + mime: "application/x-sqlite3" + }; + } + if (check([78, 69, 83, 26])) { + return { + ext: "nes", + mime: "application/x-nintendo-nes-rom" + }; + } + if (check([67, 114, 50, 52])) { + return { + ext: "crx", + mime: "application/x-google-chrome-extension" + }; + } + if (check([77, 83, 67, 70]) || check([73, 83, 99, 40])) { + return { + ext: "cab", + mime: "application/vnd.ms-cab-compressed" + }; + } + if (check([33, 60, 97, 114, 99, 104, 62, 10, 100, 101, 98, 105, 97, 110, 45, 98, 105, 110, 97, 114, 121])) { + return { + ext: "deb", + mime: "application/x-deb" + }; + } + if (check([33, 60, 97, 114, 99, 104, 62])) { + return { + ext: "ar", + mime: "application/x-unix-archive" + }; + } + if (check([237, 171, 238, 219])) { + return { + ext: "rpm", + mime: "application/x-rpm" + }; + } + if (check([31, 160]) || check([31, 157])) { + return { + ext: "Z", + mime: "application/x-compress" + }; + } + if (check([76, 90, 73, 80])) { + return { + ext: "lz", + mime: "application/x-lzip" + }; + } + if (check([208, 207, 17, 224, 161, 177, 26, 225])) { + return { + ext: "msi", + mime: "application/x-msi" + }; + } + if (check([6, 14, 43, 52, 2, 5, 1, 1, 13, 1, 2, 1, 1, 2])) { + return { + ext: "mxf", + mime: "application/mxf" + }; + } + if (check([71], { offset: 4 }) && (check([71], { offset: 192 }) || check([71], { offset: 196 }))) { + return { + ext: "mts", + mime: "video/mp2t" + }; + } + if (check([66, 76, 69, 78, 68, 69, 82])) { + return { + ext: "blend", + mime: "application/x-blender" + }; + } + if (check([66, 80, 71, 251])) { + return { + ext: "bpg", + mime: "image/bpg" + }; + } + return null; + }; + } +}); + +// node_modules/seek-bzip/lib/bitreader.js +var require_bitreader = __commonJS({ + "node_modules/seek-bzip/lib/bitreader.js"(exports2, module3) { + var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; + var BitReader = function(stream2) { + this.stream = stream2; + this.bitOffset = 0; + this.curByte = 0; + this.hasByte = false; + }; + BitReader.prototype._ensureByte = function() { + if (!this.hasByte) { + this.curByte = this.stream.readByte(); + this.hasByte = true; + } + }; + BitReader.prototype.read = function(bits) { + var result = 0; + while (bits > 0) { + this._ensureByte(); + var remaining = 8 - this.bitOffset; + if (bits >= remaining) { + result <<= remaining; + result |= BITMASK[remaining] & this.curByte; + this.hasByte = false; + this.bitOffset = 0; + bits -= remaining; + } else { + result <<= bits; + var shift = remaining - bits; + result |= (this.curByte & BITMASK[bits] << shift) >> shift; + this.bitOffset += bits; + bits = 0; + } + } + return result; + }; + BitReader.prototype.seek = function(pos) { + var n_bit = pos % 8; + var n_byte = (pos - n_bit) / 8; + this.bitOffset = n_bit; + this.stream.seek(n_byte); + this.hasByte = false; + }; + BitReader.prototype.pi = function() { + var buf = new Buffer(6), i; + for (i = 0; i < buf.length; i++) { + buf[i] = this.read(8); + } + return buf.toString("hex"); + }; + module3.exports = BitReader; + } +}); + +// node_modules/seek-bzip/lib/stream.js +var require_stream2 = __commonJS({ + "node_modules/seek-bzip/lib/stream.js"(exports2, module3) { + var Stream = function() { + }; + Stream.prototype.readByte = function() { + throw new Error("abstract method readByte() not implemented"); + }; + Stream.prototype.read = function(buffer, bufOffset, length) { + var bytesRead = 0; + while (bytesRead < length) { + var c = this.readByte(); + if (c < 0) { + return bytesRead === 0 ? -1 : bytesRead; + } + buffer[bufOffset++] = c; + bytesRead++; + } + return bytesRead; + }; + Stream.prototype.seek = function(new_pos) { + throw new Error("abstract method seek() not implemented"); + }; + Stream.prototype.writeByte = function(_byte) { + throw new Error("abstract method readByte() not implemented"); + }; + Stream.prototype.write = function(buffer, bufOffset, length) { + var i; + for (i = 0; i < length; i++) { + this.writeByte(buffer[bufOffset++]); + } + return length; + }; + Stream.prototype.flush = function() { + }; + module3.exports = Stream; + } +}); + +// node_modules/seek-bzip/lib/crc32.js +var require_crc32 = __commonJS({ + "node_modules/seek-bzip/lib/crc32.js"(exports2, module3) { + module3.exports = (function() { + var crc32Lookup = new Uint32Array([ + 0, + 79764919, + 159529838, + 222504665, + 319059676, + 398814059, + 445009330, + 507990021, + 638119352, + 583659535, + 797628118, + 726387553, + 890018660, + 835552979, + 1015980042, + 944750013, + 1276238704, + 1221641927, + 1167319070, + 1095957929, + 1595256236, + 1540665371, + 1452775106, + 1381403509, + 1780037320, + 1859660671, + 1671105958, + 1733955601, + 2031960084, + 2111593891, + 1889500026, + 1952343757, + 2552477408, + 2632100695, + 2443283854, + 2506133561, + 2334638140, + 2414271883, + 2191915858, + 2254759653, + 3190512472, + 3135915759, + 3081330742, + 3009969537, + 2905550212, + 2850959411, + 2762807018, + 2691435357, + 3560074640, + 3505614887, + 3719321342, + 3648080713, + 3342211916, + 3287746299, + 3467911202, + 3396681109, + 4063920168, + 4143685023, + 4223187782, + 4286162673, + 3779000052, + 3858754371, + 3904687514, + 3967668269, + 881225847, + 809987520, + 1023691545, + 969234094, + 662832811, + 591600412, + 771767749, + 717299826, + 311336399, + 374308984, + 453813921, + 533576470, + 25881363, + 88864420, + 134795389, + 214552010, + 2023205639, + 2086057648, + 1897238633, + 1976864222, + 1804852699, + 1867694188, + 1645340341, + 1724971778, + 1587496639, + 1516133128, + 1461550545, + 1406951526, + 1302016099, + 1230646740, + 1142491917, + 1087903418, + 2896545431, + 2825181984, + 2770861561, + 2716262478, + 3215044683, + 3143675388, + 3055782693, + 3001194130, + 2326604591, + 2389456536, + 2200899649, + 2280525302, + 2578013683, + 2640855108, + 2418763421, + 2498394922, + 3769900519, + 3832873040, + 3912640137, + 3992402750, + 4088425275, + 4151408268, + 4197601365, + 4277358050, + 3334271071, + 3263032808, + 3476998961, + 3422541446, + 3585640067, + 3514407732, + 3694837229, + 3640369242, + 1762451694, + 1842216281, + 1619975040, + 1682949687, + 2047383090, + 2127137669, + 1938468188, + 2001449195, + 1325665622, + 1271206113, + 1183200824, + 1111960463, + 1543535498, + 1489069629, + 1434599652, + 1363369299, + 622672798, + 568075817, + 748617968, + 677256519, + 907627842, + 853037301, + 1067152940, + 995781531, + 51762726, + 131386257, + 177728840, + 240578815, + 269590778, + 349224269, + 429104020, + 491947555, + 4046411278, + 4126034873, + 4172115296, + 4234965207, + 3794477266, + 3874110821, + 3953728444, + 4016571915, + 3609705398, + 3555108353, + 3735388376, + 3664026991, + 3290680682, + 3236090077, + 3449943556, + 3378572211, + 3174993278, + 3120533705, + 3032266256, + 2961025959, + 2923101090, + 2868635157, + 2813903052, + 2742672763, + 2604032198, + 2683796849, + 2461293480, + 2524268063, + 2284983834, + 2364738477, + 2175806836, + 2238787779, + 1569362073, + 1498123566, + 1409854455, + 1355396672, + 1317987909, + 1246755826, + 1192025387, + 1137557660, + 2072149281, + 2135122070, + 1912620623, + 1992383480, + 1753615357, + 1816598090, + 1627664531, + 1707420964, + 295390185, + 358241886, + 404320391, + 483945776, + 43990325, + 106832002, + 186451547, + 266083308, + 932423249, + 861060070, + 1041341759, + 986742920, + 613929101, + 542559546, + 756411363, + 701822548, + 3316196985, + 3244833742, + 3425377559, + 3370778784, + 3601682597, + 3530312978, + 3744426955, + 3689838204, + 3819031489, + 3881883254, + 3928223919, + 4007849240, + 4037393693, + 4100235434, + 4180117107, + 4259748804, + 2310601993, + 2373574846, + 2151335527, + 2231098320, + 2596047829, + 2659030626, + 2470359227, + 2550115596, + 2947551409, + 2876312838, + 2788305887, + 2733848168, + 3165939309, + 3094707162, + 3040238851, + 2985771188 + ]); + var CRC32 = function() { + var crc = 4294967295; + this.getCRC = function() { + return ~crc >>> 0; + }; + this.updateCRC = function(value) { + crc = crc << 8 ^ crc32Lookup[(crc >>> 24 ^ value) & 255]; + }; + this.updateCRCRun = function(value, count) { + while (count-- > 0) { + crc = crc << 8 ^ crc32Lookup[(crc >>> 24 ^ value) & 255]; + } + }; + }; + return CRC32; + })(); + } +}); + +// node_modules/seek-bzip/package.json +var require_package = __commonJS({ + "node_modules/seek-bzip/package.json"(exports2, module3) { + module3.exports = { + name: "seek-bzip", + version: "1.0.6", + contributors: [ + "C. Scott Ananian (http://cscott.net)", + "Eli Skeggs", + "Kevin Kwok", + "Rob Landley (http://landley.net)" + ], + description: "a pure-JavaScript Node.JS module for random-access decoding bzip2 data", + main: "./lib/index.js", + repository: { + type: "git", + url: "https://github.com/cscott/seek-bzip.git" + }, + license: "MIT", + bin: { + "seek-bunzip": "./bin/seek-bunzip", + "seek-table": "./bin/seek-bzip-table" + }, + directories: { + test: "test" + }, + dependencies: { + commander: "^2.8.1" + }, + devDependencies: { + fibers: "~1.0.6", + mocha: "~2.2.5" + }, + scripts: { + test: "mocha" + } + }; + } +}); + +// node_modules/seek-bzip/lib/index.js +var require_lib2 = __commonJS({ + "node_modules/seek-bzip/lib/index.js"(exports2, module3) { + var BitReader = require_bitreader(); + var Stream = require_stream2(); + var CRC32 = require_crc32(); + var pjson = require_package(); + var MAX_HUFCODE_BITS = 20; + var MAX_SYMBOLS = 258; + var SYMBOL_RUNA = 0; + var SYMBOL_RUNB = 1; + var MIN_GROUPS = 2; + var MAX_GROUPS = 6; + var GROUP_SIZE = 50; + var WHOLEPI = "314159265359"; + var SQRTPI = "177245385090"; + var mtf = function(array4, index4) { + var src = array4[index4], i; + for (i = index4; i > 0; i--) { + array4[i] = array4[i - 1]; + } + array4[0] = src; + return src; + }; + var Err = { + OK: 0, + LAST_BLOCK: -1, + NOT_BZIP_DATA: -2, + UNEXPECTED_INPUT_EOF: -3, + UNEXPECTED_OUTPUT_EOF: -4, + DATA_ERROR: -5, + OUT_OF_MEMORY: -6, + OBSOLETE_INPUT: -7, + END_OF_BLOCK: -8 + }; + var ErrorMessages = {}; + ErrorMessages[Err.LAST_BLOCK] = "Bad file checksum"; + ErrorMessages[Err.NOT_BZIP_DATA] = "Not bzip data"; + ErrorMessages[Err.UNEXPECTED_INPUT_EOF] = "Unexpected input EOF"; + ErrorMessages[Err.UNEXPECTED_OUTPUT_EOF] = "Unexpected output EOF"; + ErrorMessages[Err.DATA_ERROR] = "Data error"; + ErrorMessages[Err.OUT_OF_MEMORY] = "Out of memory"; + ErrorMessages[Err.OBSOLETE_INPUT] = "Obsolete (pre 0.9.5) bzip format not supported."; + var _throw = function(status, optDetail) { + var msg = ErrorMessages[status] || "unknown error"; + if (optDetail) { + msg += ": " + optDetail; + } + var e = new TypeError(msg); + e.errorCode = status; + throw e; + }; + var Bunzip = function(inputStream, outputStream) { + this.writePos = this.writeCurrent = this.writeCount = 0; + this._start_bunzip(inputStream, outputStream); + }; + Bunzip.prototype._init_block = function() { + var moreBlocks = this._get_next_block(); + if (!moreBlocks) { + this.writeCount = -1; + return false; + } + this.blockCRC = new CRC32(); + return true; + }; + Bunzip.prototype._start_bunzip = function(inputStream, outputStream) { + var buf = new Buffer(4); + if (inputStream.read(buf, 0, 4) !== 4 || String.fromCharCode(buf[0], buf[1], buf[2]) !== "BZh") + _throw(Err.NOT_BZIP_DATA, "bad magic"); + var level = buf[3] - 48; + if (level < 1 || level > 9) + _throw(Err.NOT_BZIP_DATA, "level out of range"); + this.reader = new BitReader(inputStream); + this.dbufSize = 1e5 * level; + this.nextoutput = 0; + this.outputStream = outputStream; + this.streamCRC = 0; + }; + Bunzip.prototype._get_next_block = function() { + var i, j, k; + var reader = this.reader; + var h = reader.pi(); + if (h === SQRTPI) { + return false; + } + if (h !== WHOLEPI) + _throw(Err.NOT_BZIP_DATA); + this.targetBlockCRC = reader.read(32) >>> 0; + this.streamCRC = (this.targetBlockCRC ^ (this.streamCRC << 1 | this.streamCRC >>> 31)) >>> 0; + if (reader.read(1)) + _throw(Err.OBSOLETE_INPUT); + var origPointer = reader.read(24); + if (origPointer > this.dbufSize) + _throw(Err.DATA_ERROR, "initial position out of bounds"); + var t = reader.read(16); + var symToByte = new Buffer(256), symTotal = 0; + for (i = 0; i < 16; i++) { + if (t & 1 << 15 - i) { + var o = i * 16; + k = reader.read(16); + for (j = 0; j < 16; j++) + if (k & 1 << 15 - j) + symToByte[symTotal++] = o + j; + } + } + var groupCount = reader.read(3); + if (groupCount < MIN_GROUPS || groupCount > MAX_GROUPS) + _throw(Err.DATA_ERROR); + var nSelectors = reader.read(15); + if (nSelectors === 0) + _throw(Err.DATA_ERROR); + var mtfSymbol = new Buffer(256); + for (i = 0; i < groupCount; i++) + mtfSymbol[i] = i; + var selectors = new Buffer(nSelectors); + for (i = 0; i < nSelectors; i++) { + for (j = 0; reader.read(1); j++) + if (j >= groupCount) _throw(Err.DATA_ERROR); + selectors[i] = mtf(mtfSymbol, j); + } + var symCount = symTotal + 2; + var groups = [], hufGroup; + for (j = 0; j < groupCount; j++) { + var length = new Buffer(symCount), temp = new Uint16Array(MAX_HUFCODE_BITS + 1); + t = reader.read(5); + for (i = 0; i < symCount; i++) { + for (; ; ) { + if (t < 1 || t > MAX_HUFCODE_BITS) _throw(Err.DATA_ERROR); + if (!reader.read(1)) + break; + if (!reader.read(1)) + t++; + else + t--; + } + length[i] = t; + } + var minLen, maxLen; + minLen = maxLen = length[0]; + for (i = 1; i < symCount; i++) { + if (length[i] > maxLen) + maxLen = length[i]; + else if (length[i] < minLen) + minLen = length[i]; + } + hufGroup = {}; + groups.push(hufGroup); + hufGroup.permute = new Uint16Array(MAX_SYMBOLS); + hufGroup.limit = new Uint32Array(MAX_HUFCODE_BITS + 2); + hufGroup.base = new Uint32Array(MAX_HUFCODE_BITS + 1); + hufGroup.minLen = minLen; + hufGroup.maxLen = maxLen; + var pp = 0; + for (i = minLen; i <= maxLen; i++) { + temp[i] = hufGroup.limit[i] = 0; + for (t = 0; t < symCount; t++) + if (length[t] === i) + hufGroup.permute[pp++] = t; + } + for (i = 0; i < symCount; i++) + temp[length[i]]++; + pp = t = 0; + for (i = minLen; i < maxLen; i++) { + pp += temp[i]; + hufGroup.limit[i] = pp - 1; + pp <<= 1; + t += temp[i]; + hufGroup.base[i + 1] = pp - t; + } + hufGroup.limit[maxLen + 1] = Number.MAX_VALUE; + hufGroup.limit[maxLen] = pp + temp[maxLen] - 1; + hufGroup.base[minLen] = 0; + } + var byteCount = new Uint32Array(256); + for (i = 0; i < 256; i++) + mtfSymbol[i] = i; + var runPos = 0, dbufCount = 0, selector3 = 0, uc; + var dbuf = this.dbuf = new Uint32Array(this.dbufSize); + symCount = 0; + for (; ; ) { + if (!symCount--) { + symCount = GROUP_SIZE - 1; + if (selector3 >= nSelectors) { + _throw(Err.DATA_ERROR); + } + hufGroup = groups[selectors[selector3++]]; + } + i = hufGroup.minLen; + j = reader.read(i); + for (; ; i++) { + if (i > hufGroup.maxLen) { + _throw(Err.DATA_ERROR); + } + if (j <= hufGroup.limit[i]) + break; + j = j << 1 | reader.read(1); + } + j -= hufGroup.base[i]; + if (j < 0 || j >= MAX_SYMBOLS) { + _throw(Err.DATA_ERROR); + } + var nextSym = hufGroup.permute[j]; + if (nextSym === SYMBOL_RUNA || nextSym === SYMBOL_RUNB) { + if (!runPos) { + runPos = 1; + t = 0; + } + if (nextSym === SYMBOL_RUNA) + t += runPos; + else + t += 2 * runPos; + runPos <<= 1; + continue; + } + if (runPos) { + runPos = 0; + if (dbufCount + t > this.dbufSize) { + _throw(Err.DATA_ERROR); + } + uc = symToByte[mtfSymbol[0]]; + byteCount[uc] += t; + while (t--) + dbuf[dbufCount++] = uc; + } + if (nextSym > symTotal) + break; + if (dbufCount >= this.dbufSize) { + _throw(Err.DATA_ERROR); + } + i = nextSym - 1; + uc = mtf(mtfSymbol, i); + uc = symToByte[uc]; + byteCount[uc]++; + dbuf[dbufCount++] = uc; + } + if (origPointer < 0 || origPointer >= dbufCount) { + _throw(Err.DATA_ERROR); + } + j = 0; + for (i = 0; i < 256; i++) { + k = j + byteCount[i]; + byteCount[i] = j; + j = k; + } + for (i = 0; i < dbufCount; i++) { + uc = dbuf[i] & 255; + dbuf[byteCount[uc]] |= i << 8; + byteCount[uc]++; + } + var pos = 0, current = 0, run = 0; + if (dbufCount) { + pos = dbuf[origPointer]; + current = pos & 255; + pos >>= 8; + run = -1; + } + this.writePos = pos; + this.writeCurrent = current; + this.writeCount = dbufCount; + this.writeRun = run; + return true; + }; + Bunzip.prototype._read_bunzip = function(outputBuffer, len) { + var copies, previous, outbyte; + if (this.writeCount < 0) { + return 0; + } + var gotcount = 0; + var dbuf = this.dbuf, pos = this.writePos, current = this.writeCurrent; + var dbufCount = this.writeCount, outputsize = this.outputsize; + var run = this.writeRun; + while (dbufCount) { + dbufCount--; + previous = current; + pos = dbuf[pos]; + current = pos & 255; + pos >>= 8; + if (run++ === 3) { + copies = current; + outbyte = previous; + current = -1; + } else { + copies = 1; + outbyte = current; + } + this.blockCRC.updateCRCRun(outbyte, copies); + while (copies--) { + this.outputStream.writeByte(outbyte); + this.nextoutput++; + } + if (current != previous) + run = 0; + } + this.writeCount = dbufCount; + if (this.blockCRC.getCRC() !== this.targetBlockCRC) { + _throw(Err.DATA_ERROR, "Bad block CRC (got " + this.blockCRC.getCRC().toString(16) + " expected " + this.targetBlockCRC.toString(16) + ")"); + } + return this.nextoutput; + }; + var coerceInputStream = function(input) { + if ("readByte" in input) { + return input; + } + var inputStream = new Stream(); + inputStream.pos = 0; + inputStream.readByte = function() { + return input[this.pos++]; + }; + inputStream.seek = function(pos) { + this.pos = pos; + }; + inputStream.eof = function() { + return this.pos >= input.length; + }; + return inputStream; + }; + var coerceOutputStream = function(output) { + var outputStream = new Stream(); + var resizeOk = true; + if (output) { + if (typeof output === "number") { + outputStream.buffer = new Buffer(output); + resizeOk = false; + } else if ("writeByte" in output) { + return output; + } else { + outputStream.buffer = output; + resizeOk = false; + } + } else { + outputStream.buffer = new Buffer(16384); + } + outputStream.pos = 0; + outputStream.writeByte = function(_byte) { + if (resizeOk && this.pos >= this.buffer.length) { + var newBuffer = new Buffer(this.buffer.length * 2); + this.buffer.copy(newBuffer); + this.buffer = newBuffer; + } + this.buffer[this.pos++] = _byte; + }; + outputStream.getBuffer = function() { + if (this.pos !== this.buffer.length) { + if (!resizeOk) + throw new TypeError("outputsize does not match decoded input"); + var newBuffer = new Buffer(this.pos); + this.buffer.copy(newBuffer, 0, 0, this.pos); + this.buffer = newBuffer; + } + return this.buffer; + }; + outputStream._coerced = true; + return outputStream; + }; + Bunzip.Err = Err; + Bunzip.decode = function(input, output, multistream) { + var inputStream = coerceInputStream(input); + var outputStream = coerceOutputStream(output); + var bz = new Bunzip(inputStream, outputStream); + while (true) { + if ("eof" in inputStream && inputStream.eof()) break; + if (bz._init_block()) { + bz._read_bunzip(); + } else { + var targetStreamCRC = bz.reader.read(32) >>> 0; + if (targetStreamCRC !== bz.streamCRC) { + _throw(Err.DATA_ERROR, "Bad stream CRC (got " + bz.streamCRC.toString(16) + " expected " + targetStreamCRC.toString(16) + ")"); + } + if (multistream && "eof" in inputStream && !inputStream.eof()) { + bz._start_bunzip(inputStream, outputStream); + } else break; + } + } + if ("getBuffer" in outputStream) + return outputStream.getBuffer(); + }; + Bunzip.decodeBlock = function(input, pos, output) { + var inputStream = coerceInputStream(input); + var outputStream = coerceOutputStream(output); + var bz = new Bunzip(inputStream, outputStream); + bz.reader.seek(pos); + var moreBlocks = bz._get_next_block(); + if (moreBlocks) { + bz.blockCRC = new CRC32(); + bz.writeCopies = 0; + bz._read_bunzip(); + } + if ("getBuffer" in outputStream) + return outputStream.getBuffer(); + }; + Bunzip.table = function(input, callback, multistream) { + var inputStream = new Stream(); + inputStream.delegate = coerceInputStream(input); + inputStream.pos = 0; + inputStream.readByte = function() { + this.pos++; + return this.delegate.readByte(); + }; + if (inputStream.delegate.eof) { + inputStream.eof = inputStream.delegate.eof.bind(inputStream.delegate); + } + var outputStream = new Stream(); + outputStream.pos = 0; + outputStream.writeByte = function() { + this.pos++; + }; + var bz = new Bunzip(inputStream, outputStream); + var blockSize = bz.dbufSize; + while (true) { + if ("eof" in inputStream && inputStream.eof()) break; + var position = inputStream.pos * 8 + bz.reader.bitOffset; + if (bz.reader.hasByte) { + position -= 8; + } + if (bz._init_block()) { + var start = outputStream.pos; + bz._read_bunzip(); + callback(position, outputStream.pos - start); + } else { + var crc = bz.reader.read(32); + if (multistream && "eof" in inputStream && !inputStream.eof()) { + bz._start_bunzip(inputStream, outputStream); + console.assert( + bz.dbufSize === blockSize, + "shouldn't change block size within multistream file" + ); + } else break; + } + } + }; + Bunzip.Stream = Stream; + Bunzip.version = pjson.version; + Bunzip.license = pjson.license; + module3.exports = Bunzip; + } +}); + +// node_modules/through/index.js +var require_through = __commonJS({ + "node_modules/through/index.js"(exports2, module3) { + var Stream = require("stream"); + exports2 = module3.exports = through; + through.through = through; + function through(write, end, opts) { + write = write || function(data) { + this.queue(data); + }; + end = end || function() { + this.queue(null); + }; + var ended = false, destroyed = false, buffer = [], _ended = false; + var stream2 = new Stream(); + stream2.readable = stream2.writable = true; + stream2.paused = false; + stream2.autoDestroy = !(opts && opts.autoDestroy === false); + stream2.write = function(data) { + write.call(this, data); + return !stream2.paused; + }; + function drain() { + while (buffer.length && !stream2.paused) { + var data = buffer.shift(); + if (null === data) + return stream2.emit("end"); + else + stream2.emit("data", data); + } + } + stream2.queue = stream2.push = function(data) { + if (_ended) return stream2; + if (data === null) _ended = true; + buffer.push(data); + drain(); + return stream2; + }; + stream2.on("end", function() { + stream2.readable = false; + if (!stream2.writable && stream2.autoDestroy) + process.nextTick(function() { + stream2.destroy(); + }); + }); + function _end() { + stream2.writable = false; + end.call(stream2); + if (!stream2.readable && stream2.autoDestroy) + stream2.destroy(); + } + stream2.end = function(data) { + if (ended) return; + ended = true; + if (arguments.length) stream2.write(data); + _end(); + return stream2; + }; + stream2.destroy = function() { + if (destroyed) return; + destroyed = true; + ended = true; + buffer.length = 0; + stream2.writable = stream2.readable = false; + stream2.emit("close"); + return stream2; + }; + stream2.pause = function() { + if (stream2.paused) return; + stream2.paused = true; + return stream2; + }; + stream2.resume = function() { + if (stream2.paused) { + stream2.paused = false; + stream2.emit("resume"); + } + drain(); + if (!stream2.paused) + stream2.emit("drain"); + return stream2; + }; + return stream2; + } + } +}); + +// node_modules/unbzip2-stream/lib/bzip2.js +var require_bzip2 = __commonJS({ + "node_modules/unbzip2-stream/lib/bzip2.js"(exports2, module3) { + function Bzip2Error(message3) { + this.name = "Bzip2Error"; + this.message = message3; + this.stack = new Error().stack; + } + Bzip2Error.prototype = new Error(); + var message2 = { + Error: function(message3) { + throw new Bzip2Error(message3); + } + }; + var bzip2 = {}; + bzip2.Bzip2Error = Bzip2Error; + bzip2.crcTable = [ + 0, + 79764919, + 159529838, + 222504665, + 319059676, + 398814059, + 445009330, + 507990021, + 638119352, + 583659535, + 797628118, + 726387553, + 890018660, + 835552979, + 1015980042, + 944750013, + 1276238704, + 1221641927, + 1167319070, + 1095957929, + 1595256236, + 1540665371, + 1452775106, + 1381403509, + 1780037320, + 1859660671, + 1671105958, + 1733955601, + 2031960084, + 2111593891, + 1889500026, + 1952343757, + 2552477408, + 2632100695, + 2443283854, + 2506133561, + 2334638140, + 2414271883, + 2191915858, + 2254759653, + 3190512472, + 3135915759, + 3081330742, + 3009969537, + 2905550212, + 2850959411, + 2762807018, + 2691435357, + 3560074640, + 3505614887, + 3719321342, + 3648080713, + 3342211916, + 3287746299, + 3467911202, + 3396681109, + 4063920168, + 4143685023, + 4223187782, + 4286162673, + 3779000052, + 3858754371, + 3904687514, + 3967668269, + 881225847, + 809987520, + 1023691545, + 969234094, + 662832811, + 591600412, + 771767749, + 717299826, + 311336399, + 374308984, + 453813921, + 533576470, + 25881363, + 88864420, + 134795389, + 214552010, + 2023205639, + 2086057648, + 1897238633, + 1976864222, + 1804852699, + 1867694188, + 1645340341, + 1724971778, + 1587496639, + 1516133128, + 1461550545, + 1406951526, + 1302016099, + 1230646740, + 1142491917, + 1087903418, + 2896545431, + 2825181984, + 2770861561, + 2716262478, + 3215044683, + 3143675388, + 3055782693, + 3001194130, + 2326604591, + 2389456536, + 2200899649, + 2280525302, + 2578013683, + 2640855108, + 2418763421, + 2498394922, + 3769900519, + 3832873040, + 3912640137, + 3992402750, + 4088425275, + 4151408268, + 4197601365, + 4277358050, + 3334271071, + 3263032808, + 3476998961, + 3422541446, + 3585640067, + 3514407732, + 3694837229, + 3640369242, + 1762451694, + 1842216281, + 1619975040, + 1682949687, + 2047383090, + 2127137669, + 1938468188, + 2001449195, + 1325665622, + 1271206113, + 1183200824, + 1111960463, + 1543535498, + 1489069629, + 1434599652, + 1363369299, + 622672798, + 568075817, + 748617968, + 677256519, + 907627842, + 853037301, + 1067152940, + 995781531, + 51762726, + 131386257, + 177728840, + 240578815, + 269590778, + 349224269, + 429104020, + 491947555, + 4046411278, + 4126034873, + 4172115296, + 4234965207, + 3794477266, + 3874110821, + 3953728444, + 4016571915, + 3609705398, + 3555108353, + 3735388376, + 3664026991, + 3290680682, + 3236090077, + 3449943556, + 3378572211, + 3174993278, + 3120533705, + 3032266256, + 2961025959, + 2923101090, + 2868635157, + 2813903052, + 2742672763, + 2604032198, + 2683796849, + 2461293480, + 2524268063, + 2284983834, + 2364738477, + 2175806836, + 2238787779, + 1569362073, + 1498123566, + 1409854455, + 1355396672, + 1317987909, + 1246755826, + 1192025387, + 1137557660, + 2072149281, + 2135122070, + 1912620623, + 1992383480, + 1753615357, + 1816598090, + 1627664531, + 1707420964, + 295390185, + 358241886, + 404320391, + 483945776, + 43990325, + 106832002, + 186451547, + 266083308, + 932423249, + 861060070, + 1041341759, + 986742920, + 613929101, + 542559546, + 756411363, + 701822548, + 3316196985, + 3244833742, + 3425377559, + 3370778784, + 3601682597, + 3530312978, + 3744426955, + 3689838204, + 3819031489, + 3881883254, + 3928223919, + 4007849240, + 4037393693, + 4100235434, + 4180117107, + 4259748804, + 2310601993, + 2373574846, + 2151335527, + 2231098320, + 2596047829, + 2659030626, + 2470359227, + 2550115596, + 2947551409, + 2876312838, + 2788305887, + 2733848168, + 3165939309, + 3094707162, + 3040238851, + 2985771188 + ]; + bzip2.array = function(bytes) { + var bit = 0, byte = 0; + var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; + return function(n) { + var result = 0; + while (n > 0) { + var left = 8 - bit; + if (n >= left) { + result <<= left; + result |= BITMASK[left] & bytes[byte++]; + bit = 0; + n -= left; + } else { + result <<= n; + result |= (bytes[byte] & BITMASK[n] << 8 - n - bit) >> 8 - n - bit; + bit += n; + n = 0; + } + } + return result; + }; + }; + bzip2.simple = function(srcbuffer, stream2) { + var bits = bzip2.array(srcbuffer); + var size = bzip2.header(bits); + var ret = false; + var bufsize = 1e5 * size; + var buf = new Int32Array(bufsize); + do { + ret = bzip2.decompress(bits, stream2, buf, bufsize); + } while (!ret); + }; + bzip2.header = function(bits) { + this.byteCount = new Int32Array(256); + this.symToByte = new Uint8Array(256); + this.mtfSymbol = new Int32Array(256); + this.selectors = new Uint8Array(32768); + if (bits(8 * 3) != 4348520) message2.Error("No magic number found"); + var i = bits(8) - 48; + if (i < 1 || i > 9) message2.Error("Not a BZIP archive"); + return i; + }; + bzip2.decompress = function(bits, stream2, buf, bufsize, streamCRC) { + var MAX_HUFCODE_BITS = 20; + var MAX_SYMBOLS = 258; + var SYMBOL_RUNA = 0; + var SYMBOL_RUNB = 1; + var GROUP_SIZE = 50; + var crc = 0 ^ -1; + for (var h = "", i = 0; i < 6; i++) h += bits(8).toString(16); + if (h == "177245385090") { + var finalCRC = bits(32) | 0; + if (finalCRC !== streamCRC) message2.Error("Error in bzip2: crc32 do not match"); + bits(null); + return null; + } + if (h != "314159265359") message2.Error("eek not valid bzip data"); + var crcblock = bits(32) | 0; + if (bits(1)) message2.Error("unsupported obsolete version"); + var origPtr = bits(24); + if (origPtr > bufsize) message2.Error("Initial position larger than buffer size"); + var t = bits(16); + var symTotal = 0; + for (i = 0; i < 16; i++) { + if (t & 1 << 15 - i) { + var k = bits(16); + for (j = 0; j < 16; j++) { + if (k & 1 << 15 - j) { + this.symToByte[symTotal++] = 16 * i + j; + } + } + } + } + var groupCount = bits(3); + if (groupCount < 2 || groupCount > 6) message2.Error("another error"); + var nSelectors = bits(15); + if (nSelectors == 0) message2.Error("meh"); + for (var i = 0; i < groupCount; i++) this.mtfSymbol[i] = i; + for (var i = 0; i < nSelectors; i++) { + for (var j = 0; bits(1); j++) if (j >= groupCount) message2.Error("whoops another error"); + var uc = this.mtfSymbol[j]; + for (var k = j - 1; k >= 0; k--) { + this.mtfSymbol[k + 1] = this.mtfSymbol[k]; + } + this.mtfSymbol[0] = uc; + this.selectors[i] = uc; + } + var symCount = symTotal + 2; + var groups = []; + var length = new Uint8Array(MAX_SYMBOLS), temp = new Uint16Array(MAX_HUFCODE_BITS + 1); + var hufGroup; + for (var j = 0; j < groupCount; j++) { + t = bits(5); + for (var i = 0; i < symCount; i++) { + while (true) { + if (t < 1 || t > MAX_HUFCODE_BITS) message2.Error("I gave up a while ago on writing error messages"); + if (!bits(1)) break; + if (!bits(1)) t++; + else t--; + } + length[i] = t; + } + var minLen, maxLen; + minLen = maxLen = length[0]; + for (var i = 1; i < symCount; i++) { + if (length[i] > maxLen) maxLen = length[i]; + else if (length[i] < minLen) minLen = length[i]; + } + hufGroup = groups[j] = {}; + hufGroup.permute = new Int32Array(MAX_SYMBOLS); + hufGroup.limit = new Int32Array(MAX_HUFCODE_BITS + 1); + hufGroup.base = new Int32Array(MAX_HUFCODE_BITS + 1); + hufGroup.minLen = minLen; + hufGroup.maxLen = maxLen; + var base = hufGroup.base; + var limit = hufGroup.limit; + var pp = 0; + for (var i = minLen; i <= maxLen; i++) + for (var t = 0; t < symCount; t++) + if (length[t] == i) hufGroup.permute[pp++] = t; + for (i = minLen; i <= maxLen; i++) temp[i] = limit[i] = 0; + for (i = 0; i < symCount; i++) temp[length[i]]++; + pp = t = 0; + for (i = minLen; i < maxLen; i++) { + pp += temp[i]; + limit[i] = pp - 1; + pp <<= 1; + base[i + 1] = pp - (t += temp[i]); + } + limit[maxLen] = pp + temp[maxLen] - 1; + base[minLen] = 0; + } + for (var i = 0; i < 256; i++) { + this.mtfSymbol[i] = i; + this.byteCount[i] = 0; + } + var runPos, count, symCount, selector3; + runPos = count = symCount = selector3 = 0; + while (true) { + if (!symCount--) { + symCount = GROUP_SIZE - 1; + if (selector3 >= nSelectors) message2.Error("meow i'm a kitty, that's an error"); + hufGroup = groups[this.selectors[selector3++]]; + base = hufGroup.base; + limit = hufGroup.limit; + } + i = hufGroup.minLen; + j = bits(i); + while (true) { + if (i > hufGroup.maxLen) message2.Error("rawr i'm a dinosaur"); + if (j <= limit[i]) break; + i++; + j = j << 1 | bits(1); + } + j -= base[i]; + if (j < 0 || j >= MAX_SYMBOLS) message2.Error("moo i'm a cow"); + var nextSym = hufGroup.permute[j]; + if (nextSym == SYMBOL_RUNA || nextSym == SYMBOL_RUNB) { + if (!runPos) { + runPos = 1; + t = 0; + } + if (nextSym == SYMBOL_RUNA) t += runPos; + else t += 2 * runPos; + runPos <<= 1; + continue; + } + if (runPos) { + runPos = 0; + if (count + t > bufsize) message2.Error("Boom."); + uc = this.symToByte[this.mtfSymbol[0]]; + this.byteCount[uc] += t; + while (t--) buf[count++] = uc; + } + if (nextSym > symTotal) break; + if (count >= bufsize) message2.Error("I can't think of anything. Error"); + i = nextSym - 1; + uc = this.mtfSymbol[i]; + for (var k = i - 1; k >= 0; k--) { + this.mtfSymbol[k + 1] = this.mtfSymbol[k]; + } + this.mtfSymbol[0] = uc; + uc = this.symToByte[uc]; + this.byteCount[uc]++; + buf[count++] = uc; + } + if (origPtr < 0 || origPtr >= count) message2.Error("I'm a monkey and I'm throwing something at someone, namely you"); + var j = 0; + for (var i = 0; i < 256; i++) { + k = j + this.byteCount[i]; + this.byteCount[i] = j; + j = k; + } + for (var i = 0; i < count; i++) { + uc = buf[i] & 255; + buf[this.byteCount[uc]] |= i << 8; + this.byteCount[uc]++; + } + var pos = 0, current = 0, run = 0; + if (count) { + pos = buf[origPtr]; + current = pos & 255; + pos >>= 8; + run = -1; + } + count = count; + var copies, previous, outbyte; + while (count) { + count--; + previous = current; + pos = buf[pos]; + current = pos & 255; + pos >>= 8; + if (run++ == 3) { + copies = current; + outbyte = previous; + current = -1; + } else { + copies = 1; + outbyte = current; + } + while (copies--) { + crc = (crc << 8 ^ this.crcTable[(crc >> 24 ^ outbyte) & 255]) & 4294967295; + stream2(outbyte); + } + if (current != previous) run = 0; + } + crc = (crc ^ -1) >>> 0; + if ((crc | 0) != (crcblock | 0)) message2.Error("Error in bzip2: crc32 do not match"); + streamCRC = (crc ^ (streamCRC << 1 | streamCRC >>> 31)) & 4294967295; + return streamCRC; + }; + module3.exports = bzip2; + } +}); + +// node_modules/unbzip2-stream/lib/bit_iterator.js +var require_bit_iterator = __commonJS({ + "node_modules/unbzip2-stream/lib/bit_iterator.js"(exports2, module3) { + var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; + module3.exports = function bitIterator(nextBuffer) { + var bit = 0, byte = 0; + var bytes = nextBuffer(); + var f = function(n) { + if (n === null && bit != 0) { + bit = 0; + byte++; + return; + } + var result = 0; + while (n > 0) { + if (byte >= bytes.length) { + byte = 0; + bytes = nextBuffer(); + } + var left = 8 - bit; + if (bit === 0 && n > 0) + f.bytesRead++; + if (n >= left) { + result <<= left; + result |= BITMASK[left] & bytes[byte++]; + bit = 0; + n -= left; + } else { + result <<= n; + result |= (bytes[byte] & BITMASK[n] << 8 - n - bit) >> 8 - n - bit; + bit += n; + n = 0; + } + } + return result; + }; + f.bytesRead = 0; + return f; + }; + } +}); + +// node_modules/unbzip2-stream/index.js +var require_unbzip2_stream = __commonJS({ + "node_modules/unbzip2-stream/index.js"(exports2, module3) { + var through = require_through(); + var bz2 = require_bzip2(); + var bitIterator = require_bit_iterator(); + module3.exports = unbzip2Stream; + function unbzip2Stream() { + var bufferQueue = []; + var hasBytes = 0; + var blockSize = 0; + var broken = false; + var done = false; + var bitReader = null; + var streamCRC = null; + function decompressBlock(push) { + if (!blockSize) { + blockSize = bz2.header(bitReader); + streamCRC = 0; + return true; + } else { + var bufsize = 1e5 * blockSize; + var buf = new Int32Array(bufsize); + var chunk = []; + var f = function(b) { + chunk.push(b); + }; + streamCRC = bz2.decompress(bitReader, f, buf, bufsize, streamCRC); + if (streamCRC === null) { + blockSize = 0; + return false; + } else { + push(Buffer.from(chunk)); + return true; + } + } + } + var outlength = 0; + function decompressAndQueue(stream2) { + if (broken) return; + try { + return decompressBlock(function(d) { + stream2.queue(d); + if (d !== null) { + outlength += d.length; + } else { + } + }); + } catch (e) { + stream2.emit("error", e); + broken = true; + return false; + } + } + return through( + function write(data) { + bufferQueue.push(data); + hasBytes += data.length; + if (bitReader === null) { + bitReader = bitIterator(function() { + return bufferQueue.shift(); + }); + } + while (!broken && hasBytes - bitReader.bytesRead + 1 >= (25e3 + 1e5 * blockSize || 4)) { + decompressAndQueue(this); + } + }, + function end(x) { + while (!broken && bitReader && hasBytes > bitReader.bytesRead) { + decompressAndQueue(this); + } + if (!broken) { + if (streamCRC !== null) + this.emit("error", new Error("input stream ended prematurely")); + this.queue(null); + } + } + ); + } + } +}); + +// node_modules/decompress-tarbz2/index.js +var require_decompress_tarbz2 = __commonJS({ + "node_modules/decompress-tarbz2/index.js"(exports2, module3) { + "use strict"; + var decompressTar = require_decompress_tar(); + var fileType = require_file_type2(); + var isStream = require_is_stream(); + var seekBzip = require_lib2(); + var unbzip2Stream = require_unbzip2_stream(); + module3.exports = () => (input) => { + if (!Buffer.isBuffer(input) && !isStream(input)) { + return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); + } + if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "bz2")) { + return Promise.resolve([]); + } + if (Buffer.isBuffer(input)) { + return decompressTar()(seekBzip.decode(input)); + } + return decompressTar()(input.pipe(unbzip2Stream())); + }; + } +}); + +// node_modules/decompress-targz/index.js +var require_decompress_targz = __commonJS({ + "node_modules/decompress-targz/index.js"(exports2, module3) { + "use strict"; + var zlib = require("zlib"); + var decompressTar = require_decompress_tar(); + var fileType = require_file_type(); + var isStream = require_is_stream(); + module3.exports = () => (input) => { + if (!Buffer.isBuffer(input) && !isStream(input)) { + return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); + } + if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "gz")) { + return Promise.resolve([]); + } + const unzip = zlib.createGunzip(); + const result = decompressTar()(unzip); + if (Buffer.isBuffer(input)) { + unzip.end(input); + } else { + input.pipe(unzip); + } + return result; + }; + } +}); + +// node_modules/decompress-unzip/node_modules/file-type/index.js +var require_file_type3 = __commonJS({ + "node_modules/decompress-unzip/node_modules/file-type/index.js"(exports2, module3) { + "use strict"; + module3.exports = function(buf) { + if (!(buf && buf.length > 1)) { + return null; + } + if (buf[0] === 255 && buf[1] === 216 && buf[2] === 255) { + return { + ext: "jpg", + mime: "image/jpeg" + }; + } + if (buf[0] === 137 && buf[1] === 80 && buf[2] === 78 && buf[3] === 71) { + return { + ext: "png", + mime: "image/png" + }; + } + if (buf[0] === 71 && buf[1] === 73 && buf[2] === 70) { + return { + ext: "gif", + mime: "image/gif" + }; + } + if (buf[8] === 87 && buf[9] === 69 && buf[10] === 66 && buf[11] === 80) { + return { + ext: "webp", + mime: "image/webp" + }; + } + if (buf[0] === 70 && buf[1] === 76 && buf[2] === 73 && buf[3] === 70) { + return { + ext: "flif", + mime: "image/flif" + }; + } + if ((buf[0] === 73 && buf[1] === 73 && buf[2] === 42 && buf[3] === 0 || buf[0] === 77 && buf[1] === 77 && buf[2] === 0 && buf[3] === 42) && buf[8] === 67 && buf[9] === 82) { + return { + ext: "cr2", + mime: "image/x-canon-cr2" + }; + } + if (buf[0] === 73 && buf[1] === 73 && buf[2] === 42 && buf[3] === 0 || buf[0] === 77 && buf[1] === 77 && buf[2] === 0 && buf[3] === 42) { + return { + ext: "tif", + mime: "image/tiff" + }; + } + if (buf[0] === 66 && buf[1] === 77) { + return { + ext: "bmp", + mime: "image/bmp" + }; + } + if (buf[0] === 73 && buf[1] === 73 && buf[2] === 188) { + return { + ext: "jxr", + mime: "image/vnd.ms-photo" + }; + } + if (buf[0] === 56 && buf[1] === 66 && buf[2] === 80 && buf[3] === 83) { + return { + ext: "psd", + mime: "image/vnd.adobe.photoshop" + }; + } + if (buf[0] === 80 && buf[1] === 75 && buf[2] === 3 && buf[3] === 4 && buf[30] === 109 && buf[31] === 105 && buf[32] === 109 && buf[33] === 101 && buf[34] === 116 && buf[35] === 121 && buf[36] === 112 && buf[37] === 101 && buf[38] === 97 && buf[39] === 112 && buf[40] === 112 && buf[41] === 108 && buf[42] === 105 && buf[43] === 99 && buf[44] === 97 && buf[45] === 116 && buf[46] === 105 && buf[47] === 111 && buf[48] === 110 && buf[49] === 47 && buf[50] === 101 && buf[51] === 112 && buf[52] === 117 && buf[53] === 98 && buf[54] === 43 && buf[55] === 122 && buf[56] === 105 && buf[57] === 112) { + return { + ext: "epub", + mime: "application/epub+zip" + }; + } + if (buf[0] === 80 && buf[1] === 75 && buf[2] === 3 && buf[3] === 4 && buf[30] === 77 && buf[31] === 69 && buf[32] === 84 && buf[33] === 65 && buf[34] === 45 && buf[35] === 73 && buf[36] === 78 && buf[37] === 70 && buf[38] === 47 && buf[39] === 109 && buf[40] === 111 && buf[41] === 122 && buf[42] === 105 && buf[43] === 108 && buf[44] === 108 && buf[45] === 97 && buf[46] === 46 && buf[47] === 114 && buf[48] === 115 && buf[49] === 97) { + return { + ext: "xpi", + mime: "application/x-xpinstall" + }; + } + if (buf[0] === 80 && buf[1] === 75 && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { + return { + ext: "zip", + mime: "application/zip" + }; + } + if (buf[257] === 117 && buf[258] === 115 && buf[259] === 116 && buf[260] === 97 && buf[261] === 114) { + return { + ext: "tar", + mime: "application/x-tar" + }; + } + if (buf[0] === 82 && buf[1] === 97 && buf[2] === 114 && buf[3] === 33 && buf[4] === 26 && buf[5] === 7 && (buf[6] === 0 || buf[6] === 1)) { + return { + ext: "rar", + mime: "application/x-rar-compressed" + }; + } + if (buf[0] === 31 && buf[1] === 139 && buf[2] === 8) { + return { + ext: "gz", + mime: "application/gzip" + }; + } + if (buf[0] === 66 && buf[1] === 90 && buf[2] === 104) { + return { + ext: "bz2", + mime: "application/x-bzip2" + }; + } + if (buf[0] === 55 && buf[1] === 122 && buf[2] === 188 && buf[3] === 175 && buf[4] === 39 && buf[5] === 28) { + return { + ext: "7z", + mime: "application/x-7z-compressed" + }; + } + if (buf[0] === 120 && buf[1] === 1) { + return { + ext: "dmg", + mime: "application/x-apple-diskimage" + }; + } + if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && (buf[3] === 24 || buf[3] === 32) && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 || buf[0] === 51 && buf[1] === 103 && buf[2] === 112 && buf[3] === 53 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 109 && buf[9] === 112 && buf[10] === 52 && buf[11] === 50 && buf[16] === 109 && buf[17] === 112 && buf[18] === 52 && buf[19] === 49 && buf[20] === 109 && buf[21] === 112 && buf[22] === 52 && buf[23] === 50 && buf[24] === 105 && buf[25] === 115 && buf[26] === 111 && buf[27] === 109 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 105 && buf[9] === 115 && buf[10] === 111 && buf[11] === 109 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 109 && buf[9] === 112 && buf[10] === 52 && buf[11] === 50 && buf[12] === 0 && buf[13] === 0 && buf[14] === 0 && buf[15] === 0) { + return { + ext: "mp4", + mime: "video/mp4" + }; + } + if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 77 && buf[9] === 52 && buf[10] === 86) { + return { + ext: "m4v", + mime: "video/x-m4v" + }; + } + if (buf[0] === 77 && buf[1] === 84 && buf[2] === 104 && buf[3] === 100) { + return { + ext: "mid", + mime: "audio/midi" + }; + } + if (buf[31] === 109 && buf[32] === 97 && buf[33] === 116 && buf[34] === 114 && buf[35] === 111 && buf[36] === 115 && buf[37] === 107 && buf[38] === 97) { + return { + ext: "mkv", + mime: "video/x-matroska" + }; + } + if (buf[0] === 26 && buf[1] === 69 && buf[2] === 223 && buf[3] === 163) { + return { + ext: "webm", + mime: "video/webm" + }; + } + if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 20 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112) { + return { + ext: "mov", + mime: "video/quicktime" + }; + } + if (buf[0] === 82 && buf[1] === 73 && buf[2] === 70 && buf[3] === 70 && buf[8] === 65 && buf[9] === 86 && buf[10] === 73) { + return { + ext: "avi", + mime: "video/x-msvideo" + }; + } + if (buf[0] === 48 && buf[1] === 38 && buf[2] === 178 && buf[3] === 117 && buf[4] === 142 && buf[5] === 102 && buf[6] === 207 && buf[7] === 17 && buf[8] === 166 && buf[9] === 217) { + return { + ext: "wmv", + mime: "video/x-ms-wmv" + }; + } + if (buf[0] === 0 && buf[1] === 0 && buf[2] === 1 && buf[3].toString(16)[0] === "b") { + return { + ext: "mpg", + mime: "video/mpeg" + }; + } + if (buf[0] === 73 && buf[1] === 68 && buf[2] === 51 || buf[0] === 255 && buf[1] === 251) { + return { + ext: "mp3", + mime: "audio/mpeg" + }; + } + if (buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 77 && buf[9] === 52 && buf[10] === 65 || buf[0] === 77 && buf[1] === 52 && buf[2] === 65 && buf[3] === 32) { + return { + ext: "m4a", + mime: "audio/m4a" + }; + } + if (buf[28] === 79 && buf[29] === 112 && buf[30] === 117 && buf[31] === 115 && buf[32] === 72 && buf[33] === 101 && buf[34] === 97 && buf[35] === 100) { + return { + ext: "opus", + mime: "audio/opus" + }; + } + if (buf[0] === 79 && buf[1] === 103 && buf[2] === 103 && buf[3] === 83) { + return { + ext: "ogg", + mime: "audio/ogg" + }; + } + if (buf[0] === 102 && buf[1] === 76 && buf[2] === 97 && buf[3] === 67) { + return { + ext: "flac", + mime: "audio/x-flac" + }; + } + if (buf[0] === 82 && buf[1] === 73 && buf[2] === 70 && buf[3] === 70 && buf[8] === 87 && buf[9] === 65 && buf[10] === 86 && buf[11] === 69) { + return { + ext: "wav", + mime: "audio/x-wav" + }; + } + if (buf[0] === 35 && buf[1] === 33 && buf[2] === 65 && buf[3] === 77 && buf[4] === 82 && buf[5] === 10) { + return { + ext: "amr", + mime: "audio/amr" + }; + } + if (buf[0] === 37 && buf[1] === 80 && buf[2] === 68 && buf[3] === 70) { + return { + ext: "pdf", + mime: "application/pdf" + }; + } + if (buf[0] === 77 && buf[1] === 90) { + return { + ext: "exe", + mime: "application/x-msdownload" + }; + } + if ((buf[0] === 67 || buf[0] === 70) && buf[1] === 87 && buf[2] === 83) { + return { + ext: "swf", + mime: "application/x-shockwave-flash" + }; + } + if (buf[0] === 123 && buf[1] === 92 && buf[2] === 114 && buf[3] === 116 && buf[4] === 102) { + return { + ext: "rtf", + mime: "application/rtf" + }; + } + if (buf[0] === 119 && buf[1] === 79 && buf[2] === 70 && buf[3] === 70 && (buf[4] === 0 && buf[5] === 1 && buf[6] === 0 && buf[7] === 0 || buf[4] === 79 && buf[5] === 84 && buf[6] === 84 && buf[7] === 79)) { + return { + ext: "woff", + mime: "application/font-woff" + }; + } + if (buf[0] === 119 && buf[1] === 79 && buf[2] === 70 && buf[3] === 50 && (buf[4] === 0 && buf[5] === 1 && buf[6] === 0 && buf[7] === 0 || buf[4] === 79 && buf[5] === 84 && buf[6] === 84 && buf[7] === 79)) { + return { + ext: "woff2", + mime: "application/font-woff" + }; + } + if (buf[34] === 76 && buf[35] === 80 && (buf[8] === 0 && buf[9] === 0 && buf[10] === 1 || buf[8] === 1 && buf[9] === 0 && buf[10] === 2 || buf[8] === 2 && buf[9] === 0 && buf[10] === 2)) { + return { + ext: "eot", + mime: "application/octet-stream" + }; + } + if (buf[0] === 0 && buf[1] === 1 && buf[2] === 0 && buf[3] === 0 && buf[4] === 0) { + return { + ext: "ttf", + mime: "application/font-sfnt" + }; + } + if (buf[0] === 79 && buf[1] === 84 && buf[2] === 84 && buf[3] === 79 && buf[4] === 0) { + return { + ext: "otf", + mime: "application/font-sfnt" + }; + } + if (buf[0] === 0 && buf[1] === 0 && buf[2] === 1 && buf[3] === 0) { + return { + ext: "ico", + mime: "image/x-icon" + }; + } + if (buf[0] === 70 && buf[1] === 76 && buf[2] === 86 && buf[3] === 1) { + return { + ext: "flv", + mime: "video/x-flv" + }; + } + if (buf[0] === 37 && buf[1] === 33) { + return { + ext: "ps", + mime: "application/postscript" + }; + } + if (buf[0] === 253 && buf[1] === 55 && buf[2] === 122 && buf[3] === 88 && buf[4] === 90 && buf[5] === 0) { + return { + ext: "xz", + mime: "application/x-xz" + }; + } + if (buf[0] === 83 && buf[1] === 81 && buf[2] === 76 && buf[3] === 105) { + return { + ext: "sqlite", + mime: "application/x-sqlite3" + }; + } + if (buf[0] === 78 && buf[1] === 69 && buf[2] === 83 && buf[3] === 26) { + return { + ext: "nes", + mime: "application/x-nintendo-nes-rom" + }; + } + if (buf[0] === 67 && buf[1] === 114 && buf[2] === 50 && buf[3] === 52) { + return { + ext: "crx", + mime: "application/x-google-chrome-extension" + }; + } + if (buf[0] === 77 && buf[1] === 83 && buf[2] === 67 && buf[3] === 70 || buf[0] === 73 && buf[1] === 83 && buf[2] === 99 && buf[3] === 40) { + return { + ext: "cab", + mime: "application/vnd.ms-cab-compressed" + }; + } + if (buf[0] === 33 && buf[1] === 60 && buf[2] === 97 && buf[3] === 114 && buf[4] === 99 && buf[5] === 104 && buf[6] === 62 && buf[7] === 10 && buf[8] === 100 && buf[9] === 101 && buf[10] === 98 && buf[11] === 105 && buf[12] === 97 && buf[13] === 110 && buf[14] === 45 && buf[15] === 98 && buf[16] === 105 && buf[17] === 110 && buf[18] === 97 && buf[19] === 114 && buf[20] === 121) { + return { + ext: "deb", + mime: "application/x-deb" + }; + } + if (buf[0] === 33 && buf[1] === 60 && buf[2] === 97 && buf[3] === 114 && buf[4] === 99 && buf[5] === 104 && buf[6] === 62) { + return { + ext: "ar", + mime: "application/x-unix-archive" + }; + } + if (buf[0] === 237 && buf[1] === 171 && buf[2] === 238 && buf[3] === 219) { + return { + ext: "rpm", + mime: "application/x-rpm" + }; + } + if (buf[0] === 31 && buf[1] === 160 || buf[0] === 31 && buf[1] === 157) { + return { + ext: "Z", + mime: "application/x-compress" + }; + } + if (buf[0] === 76 && buf[1] === 90 && buf[2] === 73 && buf[3] === 80) { + return { + ext: "lz", + mime: "application/x-lzip" + }; + } + if (buf[0] === 208 && buf[1] === 207 && buf[2] === 17 && buf[3] === 224 && buf[4] === 161 && buf[5] === 177 && buf[6] === 26 && buf[7] === 225) { + return { + ext: "msi", + mime: "application/x-msi" + }; + } + return null; + }; + } +}); + +// node_modules/pinkie/index.js +var require_pinkie = __commonJS({ + "node_modules/pinkie/index.js"(exports2, module3) { + "use strict"; + var PENDING = "pending"; + var SETTLED = "settled"; + var FULFILLED = "fulfilled"; + var REJECTED = "rejected"; + var NOOP = function() { + }; + var isNode = typeof global !== "undefined" && typeof global.process !== "undefined" && typeof global.process.emit === "function"; + var asyncSetTimer = typeof setImmediate === "undefined" ? setTimeout : setImmediate; + var asyncQueue = []; + var asyncTimer; + function asyncFlush() { + for (var i = 0; i < asyncQueue.length; i++) { + asyncQueue[i][0](asyncQueue[i][1]); + } + asyncQueue = []; + asyncTimer = false; + } + function asyncCall(callback, arg) { + asyncQueue.push([callback, arg]); + if (!asyncTimer) { + asyncTimer = true; + asyncSetTimer(asyncFlush, 0); + } + } + function invokeResolver(resolver, promise) { + function resolvePromise(value) { + resolve2(promise, value); + } + function rejectPromise(reason) { + reject(promise, reason); + } + try { + resolver(resolvePromise, rejectPromise); + } catch (e) { + rejectPromise(e); + } + } + function invokeCallback(subscriber) { + var owner = subscriber.owner; + var settled = owner._state; + var value = owner._data; + var callback = subscriber[settled]; + var promise = subscriber.then; + if (typeof callback === "function") { + settled = FULFILLED; + try { + value = callback(value); + } catch (e) { + reject(promise, e); + } + } + if (!handleThenable(promise, value)) { + if (settled === FULFILLED) { + resolve2(promise, value); + } + if (settled === REJECTED) { + reject(promise, value); + } + } + } + function handleThenable(promise, value) { + var resolved; + try { + if (promise === value) { + throw new TypeError("A promises callback cannot return that same promise."); + } + if (value && (typeof value === "function" || typeof value === "object")) { + var then = value.then; + if (typeof then === "function") { + then.call(value, function(val) { + if (!resolved) { + resolved = true; + if (value === val) { + fulfill(promise, val); + } else { + resolve2(promise, val); + } + } + }, function(reason) { + if (!resolved) { + resolved = true; + reject(promise, reason); + } + }); + return true; + } + } + } catch (e) { + if (!resolved) { + reject(promise, e); + } + return true; + } + return false; + } + function resolve2(promise, value) { + if (promise === value || !handleThenable(promise, value)) { + fulfill(promise, value); + } + } + function fulfill(promise, value) { + if (promise._state === PENDING) { + promise._state = SETTLED; + promise._data = value; + asyncCall(publishFulfillment, promise); + } + } + function reject(promise, reason) { + if (promise._state === PENDING) { + promise._state = SETTLED; + promise._data = reason; + asyncCall(publishRejection, promise); + } + } + function publish(promise) { + promise._then = promise._then.forEach(invokeCallback); + } + function publishFulfillment(promise) { + promise._state = FULFILLED; + publish(promise); + } + function publishRejection(promise) { + promise._state = REJECTED; + publish(promise); + if (!promise._handled && isNode) { + global.process.emit("unhandledRejection", promise._data, promise); + } + } + function notifyRejectionHandled(promise) { + global.process.emit("rejectionHandled", promise); + } + function Promise2(resolver) { + if (typeof resolver !== "function") { + throw new TypeError("Promise resolver " + resolver + " is not a function"); + } + if (this instanceof Promise2 === false) { + throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function."); + } + this._then = []; + invokeResolver(resolver, this); + } + Promise2.prototype = { + constructor: Promise2, + _state: PENDING, + _then: null, + _data: void 0, + _handled: false, + then: function(onFulfillment, onRejection) { + var subscriber = { + owner: this, + then: new this.constructor(NOOP), + fulfilled: onFulfillment, + rejected: onRejection + }; + if ((onRejection || onFulfillment) && !this._handled) { + this._handled = true; + if (this._state === REJECTED && isNode) { + asyncCall(notifyRejectionHandled, this); + } + } + if (this._state === FULFILLED || this._state === REJECTED) { + asyncCall(invokeCallback, subscriber); + } else { + this._then.push(subscriber); + } + return subscriber.then; + }, + catch: function(onRejection) { + return this.then(null, onRejection); + } + }; + Promise2.all = function(promises) { + if (!Array.isArray(promises)) { + throw new TypeError("You must pass an array to Promise.all()."); + } + return new Promise2(function(resolve3, reject2) { + var results = []; + var remaining = 0; + function resolver(index4) { + remaining++; + return function(value) { + results[index4] = value; + if (!--remaining) { + resolve3(results); + } + }; + } + for (var i = 0, promise; i < promises.length; i++) { + promise = promises[i]; + if (promise && typeof promise.then === "function") { + promise.then(resolver(i), reject2); + } else { + results[i] = promise; + } + } + if (!remaining) { + resolve3(results); + } + }); + }; + Promise2.race = function(promises) { + if (!Array.isArray(promises)) { + throw new TypeError("You must pass an array to Promise.race()."); + } + return new Promise2(function(resolve3, reject2) { + for (var i = 0, promise; i < promises.length; i++) { + promise = promises[i]; + if (promise && typeof promise.then === "function") { + promise.then(resolve3, reject2); + } else { + resolve3(promise); + } + } + }); + }; + Promise2.resolve = function(value) { + if (value && typeof value === "object" && value.constructor === Promise2) { + return value; + } + return new Promise2(function(resolve3) { + resolve3(value); + }); + }; + Promise2.reject = function(reason) { + return new Promise2(function(resolve3, reject2) { + reject2(reason); + }); + }; + module3.exports = Promise2; + } +}); + +// node_modules/pinkie-promise/index.js +var require_pinkie_promise = __commonJS({ + "node_modules/pinkie-promise/index.js"(exports2, module3) { + "use strict"; + module3.exports = typeof Promise === "function" ? Promise : require_pinkie(); + } +}); + +// node_modules/object-assign/index.js +var require_object_assign = __commonJS({ + "node_modules/object-assign/index.js"(exports2, module3) { + "use strict"; + var getOwnPropertySymbols = Object.getOwnPropertySymbols; + var hasOwnProperty = Object.prototype.hasOwnProperty; + var propIsEnumerable = Object.prototype.propertyIsEnumerable; + function toObject(val) { + if (val === null || val === void 0) { + throw new TypeError("Object.assign cannot be called with null or undefined"); + } + return Object(val); + } + function shouldUseNative() { + try { + if (!Object.assign) { + return false; + } + var test1 = new String("abc"); + test1[5] = "de"; + if (Object.getOwnPropertyNames(test1)[0] === "5") { + return false; + } + var test2 = {}; + for (var i = 0; i < 10; i++) { + test2["_" + String.fromCharCode(i)] = i; + } + var order2 = Object.getOwnPropertyNames(test2).map(function(n) { + return test2[n]; + }); + if (order2.join("") !== "0123456789") { + return false; + } + var test3 = {}; + "abcdefghijklmnopqrst".split("").forEach(function(letter) { + test3[letter] = letter; + }); + if (Object.keys(Object.assign({}, test3)).join("") !== "abcdefghijklmnopqrst") { + return false; + } + return true; + } catch (err) { + return false; + } + } + module3.exports = shouldUseNative() ? Object.assign : function(target, source) { + var from; + var to = toObject(target); + var symbols; + for (var s = 1; s < arguments.length; s++) { + from = Object(arguments[s]); + for (var key2 in from) { + if (hasOwnProperty.call(from, key2)) { + to[key2] = from[key2]; + } + } + if (getOwnPropertySymbols) { + symbols = getOwnPropertySymbols(from); + for (var i = 0; i < symbols.length; i++) { + if (propIsEnumerable.call(from, symbols[i])) { + to[symbols[i]] = from[symbols[i]]; + } + } + } + } + return to; + }; + } +}); + +// node_modules/get-stream/buffer-stream.js +var require_buffer_stream = __commonJS({ + "node_modules/get-stream/buffer-stream.js"(exports2, module3) { + var PassThrough = require("stream").PassThrough; + var objectAssign = require_object_assign(); + module3.exports = function(opts) { + opts = objectAssign({}, opts); + var array4 = opts.array; + var encoding = opts.encoding; + var buffer = encoding === "buffer"; + var objectMode = false; + if (array4) { + objectMode = !(encoding || buffer); + } else { + encoding = encoding || "utf8"; + } + if (buffer) { + encoding = null; + } + var len = 0; + var ret = []; + var stream2 = new PassThrough({ objectMode }); + if (encoding) { + stream2.setEncoding(encoding); + } + stream2.on("data", function(chunk) { + ret.push(chunk); + if (objectMode) { + len = ret.length; + } else { + len += chunk.length; + } + }); + stream2.getBufferedValue = function() { + if (array4) { + return ret; + } + return buffer ? Buffer.concat(ret, len) : ret.join(""); + }; + stream2.getBufferedLength = function() { + return len; + }; + return stream2; + }; + } +}); + +// node_modules/get-stream/index.js +var require_get_stream = __commonJS({ + "node_modules/get-stream/index.js"(exports2, module3) { + "use strict"; + var Promise2 = require_pinkie_promise(); + var objectAssign = require_object_assign(); + var bufferStream = require_buffer_stream(); + function getStream(inputStream, opts) { + if (!inputStream) { + return Promise2.reject(new Error("Expected a stream")); + } + opts = objectAssign({ maxBuffer: Infinity }, opts); + var maxBuffer = opts.maxBuffer; + var stream2; + var clean; + var p = new Promise2(function(resolve2, reject) { + stream2 = bufferStream(opts); + inputStream.once("error", error4); + inputStream.pipe(stream2); + stream2.on("data", function() { + if (stream2.getBufferedLength() > maxBuffer) { + reject(new Error("maxBuffer exceeded")); + } + }); + stream2.once("error", error4); + stream2.on("end", resolve2); + clean = function() { + if (inputStream.unpipe) { + inputStream.unpipe(stream2); + } + }; + function error4(err) { + if (err) { + err.bufferedData = stream2.getBufferedValue(); + } + reject(err); + } + }); + p.then(clean, clean); + return p.then(function() { + return stream2.getBufferedValue(); + }); + } + module3.exports = getStream; + module3.exports.buffer = function(stream2, opts) { + return getStream(stream2, objectAssign({}, opts, { encoding: "buffer" })); + }; + module3.exports.array = function(stream2, opts) { + return getStream(stream2, objectAssign({}, opts, { array: true })); + }; + } +}); + +// node_modules/pify/index.js +var require_pify = __commonJS({ + "node_modules/pify/index.js"(exports2, module3) { + "use strict"; + var processFn = function(fn, P, opts) { + return function() { + var that = this; + var args = new Array(arguments.length); + for (var i = 0; i < arguments.length; i++) { + args[i] = arguments[i]; + } + return new P(function(resolve2, reject) { + args.push(function(err, result) { + if (err) { + reject(err); + } else if (opts.multiArgs) { + var results = new Array(arguments.length - 1); + for (var i2 = 1; i2 < arguments.length; i2++) { + results[i2 - 1] = arguments[i2]; + } + resolve2(results); + } else { + resolve2(result); + } + }); + fn.apply(that, args); + }); + }; + }; + var pify = module3.exports = function(obj, P, opts) { + if (typeof P !== "function") { + opts = P; + P = Promise; + } + opts = opts || {}; + opts.exclude = opts.exclude || [/.+Sync$/]; + var filter2 = function(key2) { + var match = function(pattern) { + return typeof pattern === "string" ? key2 === pattern : pattern.test(key2); + }; + return opts.include ? opts.include.some(match) : !opts.exclude.some(match); + }; + var ret = typeof obj === "function" ? function() { + if (opts.excludeMain) { + return obj.apply(this, arguments); + } + return processFn(obj, P, opts).apply(this, arguments); + } : {}; + return Object.keys(obj).reduce(function(ret2, key2) { + var x = obj[key2]; + ret2[key2] = typeof x === "function" && filter2(key2) ? processFn(x, P, opts) : x; + return ret2; + }, ret); + }; + pify.all = pify; + } +}); + +// node_modules/pend/index.js +var require_pend = __commonJS({ + "node_modules/pend/index.js"(exports2, module3) { + module3.exports = Pend; + function Pend() { + this.pending = 0; + this.max = Infinity; + this.listeners = []; + this.waiting = []; + this.error = null; + } + Pend.prototype.go = function(fn) { + if (this.pending < this.max) { + pendGo(this, fn); + } else { + this.waiting.push(fn); + } + }; + Pend.prototype.wait = function(cb) { + if (this.pending === 0) { + cb(this.error); + } else { + this.listeners.push(cb); + } + }; + Pend.prototype.hold = function() { + return pendHold(this); + }; + function pendHold(self2) { + self2.pending += 1; + var called = false; + return onCb; + function onCb(err) { + if (called) throw new Error("callback called twice"); + called = true; + self2.error = self2.error || err; + self2.pending -= 1; + if (self2.waiting.length > 0 && self2.pending < self2.max) { + pendGo(self2, self2.waiting.shift()); + } else if (self2.pending === 0) { + var listeners = self2.listeners; + self2.listeners = []; + listeners.forEach(cbListener); + } + } + function cbListener(listener) { + listener(self2.error); + } + } + function pendGo(self2, fn) { + fn(pendHold(self2)); + } + } +}); + +// node_modules/fd-slicer/index.js +var require_fd_slicer = __commonJS({ + "node_modules/fd-slicer/index.js"(exports2) { + var fs2 = require("fs"); + var util = require("util"); + var stream2 = require("stream"); + var Readable = stream2.Readable; + var Writable = stream2.Writable; + var PassThrough = stream2.PassThrough; + var Pend = require_pend(); + var EventEmitter = require("events").EventEmitter; + exports2.createFromBuffer = createFromBuffer; + exports2.createFromFd = createFromFd; + exports2.BufferSlicer = BufferSlicer; + exports2.FdSlicer = FdSlicer; + util.inherits(FdSlicer, EventEmitter); + function FdSlicer(fd, options2) { + options2 = options2 || {}; + EventEmitter.call(this); + this.fd = fd; + this.pend = new Pend(); + this.pend.max = 1; + this.refCount = 0; + this.autoClose = !!options2.autoClose; + } + FdSlicer.prototype.read = function(buffer, offset, length, position, callback) { + var self2 = this; + self2.pend.go(function(cb) { + fs2.read(self2.fd, buffer, offset, length, position, function(err, bytesRead, buffer2) { + cb(); + callback(err, bytesRead, buffer2); + }); + }); + }; + FdSlicer.prototype.write = function(buffer, offset, length, position, callback) { + var self2 = this; + self2.pend.go(function(cb) { + fs2.write(self2.fd, buffer, offset, length, position, function(err, written, buffer2) { + cb(); + callback(err, written, buffer2); + }); + }); + }; + FdSlicer.prototype.createReadStream = function(options2) { + return new ReadStream(this, options2); + }; + FdSlicer.prototype.createWriteStream = function(options2) { + return new WriteStream(this, options2); + }; + FdSlicer.prototype.ref = function() { + this.refCount += 1; + }; + FdSlicer.prototype.unref = function() { + var self2 = this; + self2.refCount -= 1; + if (self2.refCount > 0) return; + if (self2.refCount < 0) throw new Error("invalid unref"); + if (self2.autoClose) { + fs2.close(self2.fd, onCloseDone); + } + function onCloseDone(err) { + if (err) { + self2.emit("error", err); + } else { + self2.emit("close"); + } + } + }; + util.inherits(ReadStream, Readable); + function ReadStream(context, options2) { + options2 = options2 || {}; + Readable.call(this, options2); + this.context = context; + this.context.ref(); + this.start = options2.start || 0; + this.endOffset = options2.end; + this.pos = this.start; + this.destroyed = false; + } + ReadStream.prototype._read = function(n) { + var self2 = this; + if (self2.destroyed) return; + var toRead = Math.min(self2._readableState.highWaterMark, n); + if (self2.endOffset != null) { + toRead = Math.min(toRead, self2.endOffset - self2.pos); + } + if (toRead <= 0) { + self2.destroyed = true; + self2.push(null); + self2.context.unref(); + return; + } + self2.context.pend.go(function(cb) { + if (self2.destroyed) return cb(); + var buffer = new Buffer(toRead); + fs2.read(self2.context.fd, buffer, 0, toRead, self2.pos, function(err, bytesRead) { + if (err) { + self2.destroy(err); + } else if (bytesRead === 0) { + self2.destroyed = true; + self2.push(null); + self2.context.unref(); + } else { + self2.pos += bytesRead; + self2.push(buffer.slice(0, bytesRead)); + } + cb(); + }); + }); + }; + ReadStream.prototype.destroy = function(err) { + if (this.destroyed) return; + err = err || new Error("stream destroyed"); + this.destroyed = true; + this.emit("error", err); + this.context.unref(); + }; + util.inherits(WriteStream, Writable); + function WriteStream(context, options2) { + options2 = options2 || {}; + Writable.call(this, options2); + this.context = context; + this.context.ref(); + this.start = options2.start || 0; + this.endOffset = options2.end == null ? Infinity : +options2.end; + this.bytesWritten = 0; + this.pos = this.start; + this.destroyed = false; + this.on("finish", this.destroy.bind(this)); + } + WriteStream.prototype._write = function(buffer, encoding, callback) { + var self2 = this; + if (self2.destroyed) return; + if (self2.pos + buffer.length > self2.endOffset) { + var err = new Error("maximum file length exceeded"); + err.code = "ETOOBIG"; + self2.destroy(); + callback(err); + return; + } + self2.context.pend.go(function(cb) { + if (self2.destroyed) return cb(); + fs2.write(self2.context.fd, buffer, 0, buffer.length, self2.pos, function(err2, bytes) { + if (err2) { + self2.destroy(); + cb(); + callback(err2); + } else { + self2.bytesWritten += bytes; + self2.pos += bytes; + self2.emit("progress"); + cb(); + callback(); + } + }); + }); + }; + WriteStream.prototype.destroy = function() { + if (this.destroyed) return; + this.destroyed = true; + this.context.unref(); + }; + util.inherits(BufferSlicer, EventEmitter); + function BufferSlicer(buffer, options2) { + EventEmitter.call(this); + options2 = options2 || {}; + this.refCount = 0; + this.buffer = buffer; + this.maxChunkSize = options2.maxChunkSize || Number.MAX_SAFE_INTEGER; + } + BufferSlicer.prototype.read = function(buffer, offset, length, position, callback) { + var end = position + length; + var delta = end - this.buffer.length; + var written = delta > 0 ? delta : length; + this.buffer.copy(buffer, offset, position, end); + setImmediate(function() { + callback(null, written); + }); + }; + BufferSlicer.prototype.write = function(buffer, offset, length, position, callback) { + buffer.copy(this.buffer, position, offset, offset + length); + setImmediate(function() { + callback(null, length, buffer); + }); + }; + BufferSlicer.prototype.createReadStream = function(options2) { + options2 = options2 || {}; + var readStream = new PassThrough(options2); + readStream.destroyed = false; + readStream.start = options2.start || 0; + readStream.endOffset = options2.end; + readStream.pos = readStream.endOffset || this.buffer.length; + var entireSlice = this.buffer.slice(readStream.start, readStream.pos); + var offset = 0; + while (true) { + var nextOffset = offset + this.maxChunkSize; + if (nextOffset >= entireSlice.length) { + if (offset < entireSlice.length) { + readStream.write(entireSlice.slice(offset, entireSlice.length)); + } + break; + } + readStream.write(entireSlice.slice(offset, nextOffset)); + offset = nextOffset; + } + readStream.end(); + readStream.destroy = function() { + readStream.destroyed = true; + }; + return readStream; + }; + BufferSlicer.prototype.createWriteStream = function(options2) { + var bufferSlicer = this; + options2 = options2 || {}; + var writeStream = new Writable(options2); + writeStream.start = options2.start || 0; + writeStream.endOffset = options2.end == null ? this.buffer.length : +options2.end; + writeStream.bytesWritten = 0; + writeStream.pos = writeStream.start; + writeStream.destroyed = false; + writeStream._write = function(buffer, encoding, callback) { + if (writeStream.destroyed) return; + var end = writeStream.pos + buffer.length; + if (end > writeStream.endOffset) { + var err = new Error("maximum file length exceeded"); + err.code = "ETOOBIG"; + writeStream.destroyed = true; + callback(err); + return; + } + buffer.copy(bufferSlicer.buffer, writeStream.pos, 0, buffer.length); + writeStream.bytesWritten += buffer.length; + writeStream.pos = end; + writeStream.emit("progress"); + callback(); + }; + writeStream.destroy = function() { + writeStream.destroyed = true; + }; + return writeStream; + }; + BufferSlicer.prototype.ref = function() { + this.refCount += 1; + }; + BufferSlicer.prototype.unref = function() { + this.refCount -= 1; + if (this.refCount < 0) { + throw new Error("invalid unref"); + } + }; + function createFromBuffer(buffer, options2) { + return new BufferSlicer(buffer, options2); + } + function createFromFd(fd, options2) { + return new FdSlicer(fd, options2); + } + } +}); + +// node_modules/buffer-crc32/index.js +var require_buffer_crc32 = __commonJS({ + "node_modules/buffer-crc32/index.js"(exports2, module3) { + var Buffer3 = require("buffer").Buffer; + var CRC_TABLE = [ + 0, + 1996959894, + 3993919788, + 2567524794, + 124634137, + 1886057615, + 3915621685, + 2657392035, + 249268274, + 2044508324, + 3772115230, + 2547177864, + 162941995, + 2125561021, + 3887607047, + 2428444049, + 498536548, + 1789927666, + 4089016648, + 2227061214, + 450548861, + 1843258603, + 4107580753, + 2211677639, + 325883990, + 1684777152, + 4251122042, + 2321926636, + 335633487, + 1661365465, + 4195302755, + 2366115317, + 997073096, + 1281953886, + 3579855332, + 2724688242, + 1006888145, + 1258607687, + 3524101629, + 2768942443, + 901097722, + 1119000684, + 3686517206, + 2898065728, + 853044451, + 1172266101, + 3705015759, + 2882616665, + 651767980, + 1373503546, + 3369554304, + 3218104598, + 565507253, + 1454621731, + 3485111705, + 3099436303, + 671266974, + 1594198024, + 3322730930, + 2970347812, + 795835527, + 1483230225, + 3244367275, + 3060149565, + 1994146192, + 31158534, + 2563907772, + 4023717930, + 1907459465, + 112637215, + 2680153253, + 3904427059, + 2013776290, + 251722036, + 2517215374, + 3775830040, + 2137656763, + 141376813, + 2439277719, + 3865271297, + 1802195444, + 476864866, + 2238001368, + 4066508878, + 1812370925, + 453092731, + 2181625025, + 4111451223, + 1706088902, + 314042704, + 2344532202, + 4240017532, + 1658658271, + 366619977, + 2362670323, + 4224994405, + 1303535960, + 984961486, + 2747007092, + 3569037538, + 1256170817, + 1037604311, + 2765210733, + 3554079995, + 1131014506, + 879679996, + 2909243462, + 3663771856, + 1141124467, + 855842277, + 2852801631, + 3708648649, + 1342533948, + 654459306, + 3188396048, + 3373015174, + 1466479909, + 544179635, + 3110523913, + 3462522015, + 1591671054, + 702138776, + 2966460450, + 3352799412, + 1504918807, + 783551873, + 3082640443, + 3233442989, + 3988292384, + 2596254646, + 62317068, + 1957810842, + 3939845945, + 2647816111, + 81470997, + 1943803523, + 3814918930, + 2489596804, + 225274430, + 2053790376, + 3826175755, + 2466906013, + 167816743, + 2097651377, + 4027552580, + 2265490386, + 503444072, + 1762050814, + 4150417245, + 2154129355, + 426522225, + 1852507879, + 4275313526, + 2312317920, + 282753626, + 1742555852, + 4189708143, + 2394877945, + 397917763, + 1622183637, + 3604390888, + 2714866558, + 953729732, + 1340076626, + 3518719985, + 2797360999, + 1068828381, + 1219638859, + 3624741850, + 2936675148, + 906185462, + 1090812512, + 3747672003, + 2825379669, + 829329135, + 1181335161, + 3412177804, + 3160834842, + 628085408, + 1382605366, + 3423369109, + 3138078467, + 570562233, + 1426400815, + 3317316542, + 2998733608, + 733239954, + 1555261956, + 3268935591, + 3050360625, + 752459403, + 1541320221, + 2607071920, + 3965973030, + 1969922972, + 40735498, + 2617837225, + 3943577151, + 1913087877, + 83908371, + 2512341634, + 3803740692, + 2075208622, + 213261112, + 2463272603, + 3855990285, + 2094854071, + 198958881, + 2262029012, + 4057260610, + 1759359992, + 534414190, + 2176718541, + 4139329115, + 1873836001, + 414664567, + 2282248934, + 4279200368, + 1711684554, + 285281116, + 2405801727, + 4167216745, + 1634467795, + 376229701, + 2685067896, + 3608007406, + 1308918612, + 956543938, + 2808555105, + 3495958263, + 1231636301, + 1047427035, + 2932959818, + 3654703836, + 1088359270, + 936918e3, + 2847714899, + 3736837829, + 1202900863, + 817233897, + 3183342108, + 3401237130, + 1404277552, + 615818150, + 3134207493, + 3453421203, + 1423857449, + 601450431, + 3009837614, + 3294710456, + 1567103746, + 711928724, + 3020668471, + 3272380065, + 1510334235, + 755167117 + ]; + if (typeof Int32Array !== "undefined") { + CRC_TABLE = new Int32Array(CRC_TABLE); + } + function ensureBuffer(input) { + if (Buffer3.isBuffer(input)) { + return input; + } + var hasNewBufferAPI = typeof Buffer3.alloc === "function" && typeof Buffer3.from === "function"; + if (typeof input === "number") { + return hasNewBufferAPI ? Buffer3.alloc(input) : new Buffer3(input); + } else if (typeof input === "string") { + return hasNewBufferAPI ? Buffer3.from(input) : new Buffer3(input); + } else { + throw new Error("input must be buffer, number, or string, received " + typeof input); + } + } + function bufferizeInt(num) { + var tmp = ensureBuffer(4); + tmp.writeInt32BE(num, 0); + return tmp; + } + function _crc32(buf, previous) { + buf = ensureBuffer(buf); + if (Buffer3.isBuffer(previous)) { + previous = previous.readUInt32BE(0); + } + var crc = ~~previous ^ -1; + for (var n = 0; n < buf.length; n++) { + crc = CRC_TABLE[(crc ^ buf[n]) & 255] ^ crc >>> 8; + } + return crc ^ -1; + } + function crc32() { + return bufferizeInt(_crc32.apply(null, arguments)); + } + crc32.signed = function() { + return _crc32.apply(null, arguments); + }; + crc32.unsigned = function() { + return _crc32.apply(null, arguments) >>> 0; + }; + module3.exports = crc32; + } +}); + +// node_modules/yauzl/index.js +var require_yauzl = __commonJS({ + "node_modules/yauzl/index.js"(exports2) { + var fs2 = require("fs"); + var zlib = require("zlib"); + var fd_slicer = require_fd_slicer(); + var crc32 = require_buffer_crc32(); + var util = require("util"); + var EventEmitter = require("events").EventEmitter; + var Transform = require("stream").Transform; + var PassThrough = require("stream").PassThrough; + var Writable = require("stream").Writable; + exports2.open = open; + exports2.fromFd = fromFd; + exports2.fromBuffer = fromBuffer; + exports2.fromRandomAccessReader = fromRandomAccessReader; + exports2.dosDateTimeToDate = dosDateTimeToDate; + exports2.validateFileName = validateFileName; + exports2.ZipFile = ZipFile; + exports2.Entry = Entry; + exports2.RandomAccessReader = RandomAccessReader; + function open(path6, options2, callback) { + if (typeof options2 === "function") { + callback = options2; + options2 = null; + } + if (options2 == null) options2 = {}; + if (options2.autoClose == null) options2.autoClose = true; + if (options2.lazyEntries == null) options2.lazyEntries = false; + if (options2.decodeStrings == null) options2.decodeStrings = true; + if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; + if (options2.strictFileNames == null) options2.strictFileNames = false; + if (callback == null) callback = defaultCallback; + fs2.open(path6, "r", function(err, fd) { + if (err) return callback(err); + fromFd(fd, options2, function(err2, zipfile) { + if (err2) fs2.close(fd, defaultCallback); + callback(err2, zipfile); + }); + }); + } + function fromFd(fd, options2, callback) { + if (typeof options2 === "function") { + callback = options2; + options2 = null; + } + if (options2 == null) options2 = {}; + if (options2.autoClose == null) options2.autoClose = false; + if (options2.lazyEntries == null) options2.lazyEntries = false; + if (options2.decodeStrings == null) options2.decodeStrings = true; + if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; + if (options2.strictFileNames == null) options2.strictFileNames = false; + if (callback == null) callback = defaultCallback; + fs2.fstat(fd, function(err, stats) { + if (err) return callback(err); + var reader = fd_slicer.createFromFd(fd, { autoClose: true }); + fromRandomAccessReader(reader, stats.size, options2, callback); + }); + } + function fromBuffer(buffer, options2, callback) { + if (typeof options2 === "function") { + callback = options2; + options2 = null; + } + if (options2 == null) options2 = {}; + options2.autoClose = false; + if (options2.lazyEntries == null) options2.lazyEntries = false; + if (options2.decodeStrings == null) options2.decodeStrings = true; + if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; + if (options2.strictFileNames == null) options2.strictFileNames = false; + var reader = fd_slicer.createFromBuffer(buffer, { maxChunkSize: 65536 }); + fromRandomAccessReader(reader, buffer.length, options2, callback); + } + function fromRandomAccessReader(reader, totalSize, options2, callback) { + if (typeof options2 === "function") { + callback = options2; + options2 = null; + } + if (options2 == null) options2 = {}; + if (options2.autoClose == null) options2.autoClose = true; + if (options2.lazyEntries == null) options2.lazyEntries = false; + if (options2.decodeStrings == null) options2.decodeStrings = true; + var decodeStrings = !!options2.decodeStrings; + if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; + if (options2.strictFileNames == null) options2.strictFileNames = false; + if (callback == null) callback = defaultCallback; + if (typeof totalSize !== "number") throw new Error("expected totalSize parameter to be a number"); + if (totalSize > Number.MAX_SAFE_INTEGER) { + throw new Error("zip file too large. only file sizes up to 2^52 are supported due to JavaScript's Number type being an IEEE 754 double."); + } + reader.ref(); + var eocdrWithoutCommentSize = 22; + var maxCommentSize = 65535; + var bufferSize = Math.min(eocdrWithoutCommentSize + maxCommentSize, totalSize); + var buffer = newBuffer(bufferSize); + var bufferReadStart = totalSize - buffer.length; + readAndAssertNoEof(reader, buffer, 0, bufferSize, bufferReadStart, function(err) { + if (err) return callback(err); + for (var i = bufferSize - eocdrWithoutCommentSize; i >= 0; i -= 1) { + if (buffer.readUInt32LE(i) !== 101010256) continue; + var eocdrBuffer = buffer.slice(i); + var diskNumber = eocdrBuffer.readUInt16LE(4); + if (diskNumber !== 0) { + return callback(new Error("multi-disk zip files are not supported: found disk number: " + diskNumber)); + } + var entryCount = eocdrBuffer.readUInt16LE(10); + var centralDirectoryOffset = eocdrBuffer.readUInt32LE(16); + var commentLength = eocdrBuffer.readUInt16LE(20); + var expectedCommentLength = eocdrBuffer.length - eocdrWithoutCommentSize; + if (commentLength !== expectedCommentLength) { + return callback(new Error("invalid comment length. expected: " + expectedCommentLength + ". found: " + commentLength)); + } + var comment6 = decodeStrings ? decodeBuffer(eocdrBuffer, 22, eocdrBuffer.length, false) : eocdrBuffer.slice(22); + if (!(entryCount === 65535 || centralDirectoryOffset === 4294967295)) { + return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames)); + } + var zip64EocdlBuffer = newBuffer(20); + var zip64EocdlOffset = bufferReadStart + i - zip64EocdlBuffer.length; + readAndAssertNoEof(reader, zip64EocdlBuffer, 0, zip64EocdlBuffer.length, zip64EocdlOffset, function(err2) { + if (err2) return callback(err2); + if (zip64EocdlBuffer.readUInt32LE(0) !== 117853008) { + return callback(new Error("invalid zip64 end of central directory locator signature")); + } + var zip64EocdrOffset = readUInt64LE(zip64EocdlBuffer, 8); + var zip64EocdrBuffer = newBuffer(56); + readAndAssertNoEof(reader, zip64EocdrBuffer, 0, zip64EocdrBuffer.length, zip64EocdrOffset, function(err3) { + if (err3) return callback(err3); + if (zip64EocdrBuffer.readUInt32LE(0) !== 101075792) { + return callback(new Error("invalid zip64 end of central directory record signature")); + } + entryCount = readUInt64LE(zip64EocdrBuffer, 32); + centralDirectoryOffset = readUInt64LE(zip64EocdrBuffer, 48); + return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames)); + }); + }); + return; + } + callback(new Error("end of central directory record signature not found")); + }); + } + util.inherits(ZipFile, EventEmitter); + function ZipFile(reader, centralDirectoryOffset, fileSize, entryCount, comment6, autoClose, lazyEntries, decodeStrings, validateEntrySizes, strictFileNames) { + var self2 = this; + EventEmitter.call(self2); + self2.reader = reader; + self2.reader.on("error", function(err) { + emitError(self2, err); + }); + self2.reader.once("close", function() { + self2.emit("close"); + }); + self2.readEntryCursor = centralDirectoryOffset; + self2.fileSize = fileSize; + self2.entryCount = entryCount; + self2.comment = comment6; + self2.entriesRead = 0; + self2.autoClose = !!autoClose; + self2.lazyEntries = !!lazyEntries; + self2.decodeStrings = !!decodeStrings; + self2.validateEntrySizes = !!validateEntrySizes; + self2.strictFileNames = !!strictFileNames; + self2.isOpen = true; + self2.emittedError = false; + if (!self2.lazyEntries) self2._readEntry(); + } + ZipFile.prototype.close = function() { + if (!this.isOpen) return; + this.isOpen = false; + this.reader.unref(); + }; + function emitErrorAndAutoClose(self2, err) { + if (self2.autoClose) self2.close(); + emitError(self2, err); + } + function emitError(self2, err) { + if (self2.emittedError) return; + self2.emittedError = true; + self2.emit("error", err); + } + ZipFile.prototype.readEntry = function() { + if (!this.lazyEntries) throw new Error("readEntry() called without lazyEntries:true"); + this._readEntry(); + }; + ZipFile.prototype._readEntry = function() { + var self2 = this; + if (self2.entryCount === self2.entriesRead) { + setImmediate(function() { + if (self2.autoClose) self2.close(); + if (self2.emittedError) return; + self2.emit("end"); + }); + return; + } + if (self2.emittedError) return; + var buffer = newBuffer(46); + readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, self2.readEntryCursor, function(err) { + if (err) return emitErrorAndAutoClose(self2, err); + if (self2.emittedError) return; + var entry6 = new Entry(); + var signature = buffer.readUInt32LE(0); + if (signature !== 33639248) return emitErrorAndAutoClose(self2, new Error("invalid central directory file header signature: 0x" + signature.toString(16))); + entry6.versionMadeBy = buffer.readUInt16LE(4); + entry6.versionNeededToExtract = buffer.readUInt16LE(6); + entry6.generalPurposeBitFlag = buffer.readUInt16LE(8); + entry6.compressionMethod = buffer.readUInt16LE(10); + entry6.lastModFileTime = buffer.readUInt16LE(12); + entry6.lastModFileDate = buffer.readUInt16LE(14); + entry6.crc32 = buffer.readUInt32LE(16); + entry6.compressedSize = buffer.readUInt32LE(20); + entry6.uncompressedSize = buffer.readUInt32LE(24); + entry6.fileNameLength = buffer.readUInt16LE(28); + entry6.extraFieldLength = buffer.readUInt16LE(30); + entry6.fileCommentLength = buffer.readUInt16LE(32); + entry6.internalFileAttributes = buffer.readUInt16LE(36); + entry6.externalFileAttributes = buffer.readUInt32LE(38); + entry6.relativeOffsetOfLocalHeader = buffer.readUInt32LE(42); + if (entry6.generalPurposeBitFlag & 64) return emitErrorAndAutoClose(self2, new Error("strong encryption is not supported")); + self2.readEntryCursor += 46; + buffer = newBuffer(entry6.fileNameLength + entry6.extraFieldLength + entry6.fileCommentLength); + readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, self2.readEntryCursor, function(err2) { + if (err2) return emitErrorAndAutoClose(self2, err2); + if (self2.emittedError) return; + var isUtf8 = (entry6.generalPurposeBitFlag & 2048) !== 0; + entry6.fileName = self2.decodeStrings ? decodeBuffer(buffer, 0, entry6.fileNameLength, isUtf8) : buffer.slice(0, entry6.fileNameLength); + var fileCommentStart = entry6.fileNameLength + entry6.extraFieldLength; + var extraFieldBuffer = buffer.slice(entry6.fileNameLength, fileCommentStart); + entry6.extraFields = []; + var i = 0; + while (i < extraFieldBuffer.length - 3) { + var headerId = extraFieldBuffer.readUInt16LE(i + 0); + var dataSize = extraFieldBuffer.readUInt16LE(i + 2); + var dataStart = i + 4; + var dataEnd = dataStart + dataSize; + if (dataEnd > extraFieldBuffer.length) return emitErrorAndAutoClose(self2, new Error("extra field length exceeds extra field buffer size")); + var dataBuffer = newBuffer(dataSize); + extraFieldBuffer.copy(dataBuffer, 0, dataStart, dataEnd); + entry6.extraFields.push({ + id: headerId, + data: dataBuffer + }); + i = dataEnd; + } + entry6.fileComment = self2.decodeStrings ? decodeBuffer(buffer, fileCommentStart, fileCommentStart + entry6.fileCommentLength, isUtf8) : buffer.slice(fileCommentStart, fileCommentStart + entry6.fileCommentLength); + entry6.comment = entry6.fileComment; + self2.readEntryCursor += buffer.length; + self2.entriesRead += 1; + if (entry6.uncompressedSize === 4294967295 || entry6.compressedSize === 4294967295 || entry6.relativeOffsetOfLocalHeader === 4294967295) { + var zip64EiefBuffer = null; + for (var i = 0; i < entry6.extraFields.length; i++) { + var extraField = entry6.extraFields[i]; + if (extraField.id === 1) { + zip64EiefBuffer = extraField.data; + break; + } + } + if (zip64EiefBuffer == null) { + return emitErrorAndAutoClose(self2, new Error("expected zip64 extended information extra field")); + } + var index4 = 0; + if (entry6.uncompressedSize === 4294967295) { + if (index4 + 8 > zip64EiefBuffer.length) { + return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include uncompressed size")); + } + entry6.uncompressedSize = readUInt64LE(zip64EiefBuffer, index4); + index4 += 8; + } + if (entry6.compressedSize === 4294967295) { + if (index4 + 8 > zip64EiefBuffer.length) { + return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include compressed size")); + } + entry6.compressedSize = readUInt64LE(zip64EiefBuffer, index4); + index4 += 8; + } + if (entry6.relativeOffsetOfLocalHeader === 4294967295) { + if (index4 + 8 > zip64EiefBuffer.length) { + return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include relative header offset")); + } + entry6.relativeOffsetOfLocalHeader = readUInt64LE(zip64EiefBuffer, index4); + index4 += 8; + } + } + if (self2.decodeStrings) { + for (var i = 0; i < entry6.extraFields.length; i++) { + var extraField = entry6.extraFields[i]; + if (extraField.id === 28789) { + if (extraField.data.length < 6) { + continue; + } + if (extraField.data.readUInt8(0) !== 1) { + continue; + } + var oldNameCrc32 = extraField.data.readUInt32LE(1); + if (crc32.unsigned(buffer.slice(0, entry6.fileNameLength)) !== oldNameCrc32) { + continue; + } + entry6.fileName = decodeBuffer(extraField.data, 5, extraField.data.length, true); + break; + } + } + } + if (self2.validateEntrySizes && entry6.compressionMethod === 0) { + var expectedCompressedSize = entry6.uncompressedSize; + if (entry6.isEncrypted()) { + expectedCompressedSize += 12; + } + if (entry6.compressedSize !== expectedCompressedSize) { + var msg = "compressed/uncompressed size mismatch for stored file: " + entry6.compressedSize + " != " + entry6.uncompressedSize; + return emitErrorAndAutoClose(self2, new Error(msg)); + } + } + if (self2.decodeStrings) { + if (!self2.strictFileNames) { + entry6.fileName = entry6.fileName.replace(/\\/g, "/"); + } + var errorMessage = validateFileName(entry6.fileName, self2.validateFileNameOptions); + if (errorMessage != null) return emitErrorAndAutoClose(self2, new Error(errorMessage)); + } + self2.emit("entry", entry6); + if (!self2.lazyEntries) self2._readEntry(); + }); + }); + }; + ZipFile.prototype.openReadStream = function(entry6, options2, callback) { + var self2 = this; + var relativeStart = 0; + var relativeEnd = entry6.compressedSize; + if (callback == null) { + callback = options2; + options2 = {}; + } else { + if (options2.decrypt != null) { + if (!entry6.isEncrypted()) { + throw new Error("options.decrypt can only be specified for encrypted entries"); + } + if (options2.decrypt !== false) throw new Error("invalid options.decrypt value: " + options2.decrypt); + if (entry6.isCompressed()) { + if (options2.decompress !== false) throw new Error("entry is encrypted and compressed, and options.decompress !== false"); + } + } + if (options2.decompress != null) { + if (!entry6.isCompressed()) { + throw new Error("options.decompress can only be specified for compressed entries"); + } + if (!(options2.decompress === false || options2.decompress === true)) { + throw new Error("invalid options.decompress value: " + options2.decompress); + } + } + if (options2.start != null || options2.end != null) { + if (entry6.isCompressed() && options2.decompress !== false) { + throw new Error("start/end range not allowed for compressed entry without options.decompress === false"); + } + if (entry6.isEncrypted() && options2.decrypt !== false) { + throw new Error("start/end range not allowed for encrypted entry without options.decrypt === false"); + } + } + if (options2.start != null) { + relativeStart = options2.start; + if (relativeStart < 0) throw new Error("options.start < 0"); + if (relativeStart > entry6.compressedSize) throw new Error("options.start > entry.compressedSize"); + } + if (options2.end != null) { + relativeEnd = options2.end; + if (relativeEnd < 0) throw new Error("options.end < 0"); + if (relativeEnd > entry6.compressedSize) throw new Error("options.end > entry.compressedSize"); + if (relativeEnd < relativeStart) throw new Error("options.end < options.start"); + } + } + if (!self2.isOpen) return callback(new Error("closed")); + if (entry6.isEncrypted()) { + if (options2.decrypt !== false) return callback(new Error("entry is encrypted, and options.decrypt !== false")); + } + self2.reader.ref(); + var buffer = newBuffer(30); + readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, entry6.relativeOffsetOfLocalHeader, function(err) { + try { + if (err) return callback(err); + var signature = buffer.readUInt32LE(0); + if (signature !== 67324752) { + return callback(new Error("invalid local file header signature: 0x" + signature.toString(16))); + } + var fileNameLength = buffer.readUInt16LE(26); + var extraFieldLength = buffer.readUInt16LE(28); + var localFileHeaderEnd = entry6.relativeOffsetOfLocalHeader + buffer.length + fileNameLength + extraFieldLength; + var decompress2; + if (entry6.compressionMethod === 0) { + decompress2 = false; + } else if (entry6.compressionMethod === 8) { + decompress2 = options2.decompress != null ? options2.decompress : true; + } else { + return callback(new Error("unsupported compression method: " + entry6.compressionMethod)); + } + var fileDataStart = localFileHeaderEnd; + var fileDataEnd = fileDataStart + entry6.compressedSize; + if (entry6.compressedSize !== 0) { + if (fileDataEnd > self2.fileSize) { + return callback(new Error("file data overflows file bounds: " + fileDataStart + " + " + entry6.compressedSize + " > " + self2.fileSize)); + } + } + var readStream = self2.reader.createReadStream({ + start: fileDataStart + relativeStart, + end: fileDataStart + relativeEnd + }); + var endpointStream = readStream; + if (decompress2) { + var destroyed = false; + var inflateFilter = zlib.createInflateRaw(); + readStream.on("error", function(err2) { + setImmediate(function() { + if (!destroyed) inflateFilter.emit("error", err2); + }); + }); + readStream.pipe(inflateFilter); + if (self2.validateEntrySizes) { + endpointStream = new AssertByteCountStream(entry6.uncompressedSize); + inflateFilter.on("error", function(err2) { + setImmediate(function() { + if (!destroyed) endpointStream.emit("error", err2); + }); + }); + inflateFilter.pipe(endpointStream); + } else { + endpointStream = inflateFilter; + } + endpointStream.destroy = function() { + destroyed = true; + if (inflateFilter !== endpointStream) inflateFilter.unpipe(endpointStream); + readStream.unpipe(inflateFilter); + readStream.destroy(); + }; + } + callback(null, endpointStream); + } finally { + self2.reader.unref(); + } + }); + }; + function Entry() { + } + Entry.prototype.getLastModDate = function() { + return dosDateTimeToDate(this.lastModFileDate, this.lastModFileTime); + }; + Entry.prototype.isEncrypted = function() { + return (this.generalPurposeBitFlag & 1) !== 0; + }; + Entry.prototype.isCompressed = function() { + return this.compressionMethod === 8; + }; + function dosDateTimeToDate(date, time2) { + var day = date & 31; + var month = (date >> 5 & 15) - 1; + var year = (date >> 9 & 127) + 1980; + var millisecond = 0; + var second = (time2 & 31) * 2; + var minute = time2 >> 5 & 63; + var hour = time2 >> 11 & 31; + return new Date(year, month, day, hour, minute, second, millisecond); + } + function validateFileName(fileName) { + if (fileName.indexOf("\\") !== -1) { + return "invalid characters in fileName: " + fileName; + } + if (/^[a-zA-Z]:/.test(fileName) || /^\//.test(fileName)) { + return "absolute path: " + fileName; + } + if (fileName.split("/").indexOf("..") !== -1) { + return "invalid relative path: " + fileName; + } + return null; + } + function readAndAssertNoEof(reader, buffer, offset, length, position, callback) { + if (length === 0) { + return setImmediate(function() { + callback(null, newBuffer(0)); + }); + } + reader.read(buffer, offset, length, position, function(err, bytesRead) { + if (err) return callback(err); + if (bytesRead < length) { + return callback(new Error("unexpected EOF")); + } + callback(); + }); + } + util.inherits(AssertByteCountStream, Transform); + function AssertByteCountStream(byteCount) { + Transform.call(this); + this.actualByteCount = 0; + this.expectedByteCount = byteCount; + } + AssertByteCountStream.prototype._transform = function(chunk, encoding, cb) { + this.actualByteCount += chunk.length; + if (this.actualByteCount > this.expectedByteCount) { + var msg = "too many bytes in the stream. expected " + this.expectedByteCount + ". got at least " + this.actualByteCount; + return cb(new Error(msg)); + } + cb(null, chunk); + }; + AssertByteCountStream.prototype._flush = function(cb) { + if (this.actualByteCount < this.expectedByteCount) { + var msg = "not enough bytes in the stream. expected " + this.expectedByteCount + ". got only " + this.actualByteCount; + return cb(new Error(msg)); + } + cb(); + }; + util.inherits(RandomAccessReader, EventEmitter); + function RandomAccessReader() { + EventEmitter.call(this); + this.refCount = 0; + } + RandomAccessReader.prototype.ref = function() { + this.refCount += 1; + }; + RandomAccessReader.prototype.unref = function() { + var self2 = this; + self2.refCount -= 1; + if (self2.refCount > 0) return; + if (self2.refCount < 0) throw new Error("invalid unref"); + self2.close(onCloseDone); + function onCloseDone(err) { + if (err) return self2.emit("error", err); + self2.emit("close"); + } + }; + RandomAccessReader.prototype.createReadStream = function(options2) { + var start = options2.start; + var end = options2.end; + if (start === end) { + var emptyStream = new PassThrough(); + setImmediate(function() { + emptyStream.end(); + }); + return emptyStream; + } + var stream2 = this._readStreamForRange(start, end); + var destroyed = false; + var refUnrefFilter = new RefUnrefFilter(this); + stream2.on("error", function(err) { + setImmediate(function() { + if (!destroyed) refUnrefFilter.emit("error", err); + }); + }); + refUnrefFilter.destroy = function() { + stream2.unpipe(refUnrefFilter); + refUnrefFilter.unref(); + stream2.destroy(); + }; + var byteCounter = new AssertByteCountStream(end - start); + refUnrefFilter.on("error", function(err) { + setImmediate(function() { + if (!destroyed) byteCounter.emit("error", err); + }); + }); + byteCounter.destroy = function() { + destroyed = true; + refUnrefFilter.unpipe(byteCounter); + refUnrefFilter.destroy(); + }; + return stream2.pipe(refUnrefFilter).pipe(byteCounter); + }; + RandomAccessReader.prototype._readStreamForRange = function(start, end) { + throw new Error("not implemented"); + }; + RandomAccessReader.prototype.read = function(buffer, offset, length, position, callback) { + var readStream = this.createReadStream({ start: position, end: position + length }); + var writeStream = new Writable(); + var written = 0; + writeStream._write = function(chunk, encoding, cb) { + chunk.copy(buffer, offset + written, 0, chunk.length); + written += chunk.length; + cb(); + }; + writeStream.on("finish", callback); + readStream.on("error", function(error4) { + callback(error4); + }); + readStream.pipe(writeStream); + }; + RandomAccessReader.prototype.close = function(callback) { + setImmediate(callback); + }; + util.inherits(RefUnrefFilter, PassThrough); + function RefUnrefFilter(context) { + PassThrough.call(this); + this.context = context; + this.context.ref(); + this.unreffedYet = false; + } + RefUnrefFilter.prototype._flush = function(cb) { + this.unref(); + cb(); + }; + RefUnrefFilter.prototype.unref = function(cb) { + if (this.unreffedYet) return; + this.unreffedYet = true; + this.context.unref(); + }; + var cp437 = "\0\u263A\u263B\u2665\u2666\u2663\u2660\u2022\u25D8\u25CB\u25D9\u2642\u2640\u266A\u266B\u263C\u25BA\u25C4\u2195\u203C\xB6\xA7\u25AC\u21A8\u2191\u2193\u2192\u2190\u221F\u2194\u25B2\u25BC !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u2302\xC7\xFC\xE9\xE2\xE4\xE0\xE5\xE7\xEA\xEB\xE8\xEF\xEE\xEC\xC4\xC5\xC9\xE6\xC6\xF4\xF6\xF2\xFB\xF9\xFF\xD6\xDC\xA2\xA3\xA5\u20A7\u0192\xE1\xED\xF3\xFA\xF1\xD1\xAA\xBA\xBF\u2310\xAC\xBD\xBC\xA1\xAB\xBB\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255D\u255C\u255B\u2510\u2514\u2534\u252C\u251C\u2500\u253C\u255E\u255F\u255A\u2554\u2569\u2566\u2560\u2550\u256C\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256B\u256A\u2518\u250C\u2588\u2584\u258C\u2590\u2580\u03B1\xDF\u0393\u03C0\u03A3\u03C3\xB5\u03C4\u03A6\u0398\u03A9\u03B4\u221E\u03C6\u03B5\u2229\u2261\xB1\u2265\u2264\u2320\u2321\xF7\u2248\xB0\u2219\xB7\u221A\u207F\xB2\u25A0\xA0"; + function decodeBuffer(buffer, start, end, isUtf8) { + if (isUtf8) { + return buffer.toString("utf8", start, end); + } else { + var result = ""; + for (var i = start; i < end; i++) { + result += cp437[buffer[i]]; + } + return result; + } + } + function readUInt64LE(buffer, offset) { + var lower32 = buffer.readUInt32LE(offset); + var upper32 = buffer.readUInt32LE(offset + 4); + return upper32 * 4294967296 + lower32; + } + var newBuffer; + if (typeof Buffer.allocUnsafe === "function") { + newBuffer = function(len) { + return Buffer.allocUnsafe(len); + }; + } else { + newBuffer = function(len) { + return new Buffer(len); + }; + } + function defaultCallback(err) { + if (err) throw err; + } + } +}); + +// node_modules/decompress-unzip/index.js +var require_decompress_unzip = __commonJS({ + "node_modules/decompress-unzip/index.js"(exports2, module3) { + "use strict"; + var fileType = require_file_type3(); + var getStream = require_get_stream(); + var pify = require_pify(); + var yauzl = require_yauzl(); + var getType = (entry6, mode) => { + const IFMT = 61440; + const IFDIR = 16384; + const IFLNK = 40960; + const madeBy = entry6.versionMadeBy >> 8; + if ((mode & IFMT) === IFLNK) { + return "symlink"; + } + if ((mode & IFMT) === IFDIR || madeBy === 0 && entry6.externalFileAttributes === 16) { + return "directory"; + } + return "file"; + }; + var extractEntry = (entry6, zip) => { + const file9 = { + mode: entry6.externalFileAttributes >> 16 & 65535, + mtime: entry6.getLastModDate(), + path: entry6.fileName + }; + file9.type = getType(entry6, file9.mode); + if (file9.mode === 0 && file9.type === "directory") { + file9.mode = 493; + } + if (file9.mode === 0) { + file9.mode = 420; + } + return pify(zip.openReadStream.bind(zip))(entry6).then(getStream.buffer).then((buf) => { + file9.data = buf; + if (file9.type === "symlink") { + file9.linkname = buf.toString(); + } + return file9; + }).catch((err) => { + zip.close(); + throw err; + }); + }; + var extractFile = (zip) => new Promise((resolve2, reject) => { + const files = []; + zip.readEntry(); + zip.on("entry", (entry6) => { + extractEntry(entry6, zip).catch(reject).then((file9) => { + files.push(file9); + zip.readEntry(); + }); + }); + zip.on("error", reject); + zip.on("end", () => resolve2(files)); + }); + module3.exports = () => (buf) => { + if (!Buffer.isBuffer(buf)) { + return Promise.reject(new TypeError(`Expected a Buffer, got ${typeof buf}`)); + } + if (!fileType(buf) || fileType(buf).ext !== "zip") { + return Promise.resolve([]); + } + return pify(yauzl.fromBuffer)(buf, { lazyEntries: true }).then(extractFile); + }; + } +}); + +// node_modules/make-dir/node_modules/pify/index.js +var require_pify2 = __commonJS({ + "node_modules/make-dir/node_modules/pify/index.js"(exports2, module3) { + "use strict"; + var processFn = (fn, opts) => function() { + const P = opts.promiseModule; + const args = new Array(arguments.length); + for (let i = 0; i < arguments.length; i++) { + args[i] = arguments[i]; + } + return new P((resolve2, reject) => { + if (opts.errorFirst) { + args.push(function(err, result) { + if (opts.multiArgs) { + const results = new Array(arguments.length - 1); + for (let i = 1; i < arguments.length; i++) { + results[i - 1] = arguments[i]; + } + if (err) { + results.unshift(err); + reject(results); + } else { + resolve2(results); + } + } else if (err) { + reject(err); + } else { + resolve2(result); + } + }); + } else { + args.push(function(result) { + if (opts.multiArgs) { + const results = new Array(arguments.length - 1); + for (let i = 0; i < arguments.length; i++) { + results[i] = arguments[i]; + } + resolve2(results); + } else { + resolve2(result); + } + }); + } + fn.apply(this, args); + }); + }; + module3.exports = (obj, opts) => { + opts = Object.assign({ + exclude: [/.+(Sync|Stream)$/], + errorFirst: true, + promiseModule: Promise + }, opts); + const filter2 = (key2) => { + const match = (pattern) => typeof pattern === "string" ? key2 === pattern : pattern.test(key2); + return opts.include ? opts.include.some(match) : !opts.exclude.some(match); + }; + let ret; + if (typeof obj === "function") { + ret = function() { + if (opts.excludeMain) { + return obj.apply(this, arguments); + } + return processFn(obj, opts).apply(this, arguments); + }; + } else { + ret = Object.create(Object.getPrototypeOf(obj)); + } + for (const key2 in obj) { + const x = obj[key2]; + ret[key2] = typeof x === "function" && filter2(key2) ? processFn(x, opts) : x; + } + return ret; + }; + } +}); + +// node_modules/make-dir/index.js +var require_make_dir = __commonJS({ + "node_modules/make-dir/index.js"(exports2, module3) { + "use strict"; + var fs2 = require("fs"); + var path6 = require("path"); + var pify = require_pify2(); + var defaults = { + mode: 511 & ~process.umask(), + fs: fs2 + }; + var checkPath = (pth) => { + if (process.platform === "win32") { + const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path6.parse(pth).root, "")); + if (pathHasInvalidWinCharacters) { + const err = new Error(`Path contains invalid characters: ${pth}`); + err.code = "EINVAL"; + throw err; + } + } + }; + module3.exports = (input, opts) => Promise.resolve().then(() => { + checkPath(input); + opts = Object.assign({}, defaults, opts); + const mkdir = pify(opts.fs.mkdir); + const stat = pify(opts.fs.stat); + const make = (pth) => { + return mkdir(pth, opts.mode).then(() => pth).catch((err) => { + if (err.code === "ENOENT") { + if (err.message.includes("null bytes") || path6.dirname(pth) === pth) { + throw err; + } + return make(path6.dirname(pth)).then(() => make(pth)); + } + return stat(pth).then((stats) => stats.isDirectory() ? pth : Promise.reject()).catch(() => { + throw err; + }); + }); + }; + return make(path6.resolve(input)); + }); + module3.exports.sync = (input, opts) => { + checkPath(input); + opts = Object.assign({}, defaults, opts); + const make = (pth) => { + try { + opts.fs.mkdirSync(pth, opts.mode); + } catch (err) { + if (err.code === "ENOENT") { + if (err.message.includes("null bytes") || path6.dirname(pth) === pth) { + throw err; + } + make(path6.dirname(pth)); + return make(pth); + } + try { + if (!opts.fs.statSync(pth).isDirectory()) { + throw new Error("The path is not a directory"); + } + } catch (_) { + throw err; + } + } + return pth; + }; + return make(path6.resolve(input)); + }; + } +}); + +// node_modules/is-natural-number/index.js +var require_is_natural_number = __commonJS({ + "node_modules/is-natural-number/index.js"(exports2, module3) { + "use strict"; + module3.exports = function isNaturalNumber(val, option) { + if (option) { + if (typeof option !== "object") { + throw new TypeError( + String(option) + " is not an object. Expected an object that has boolean `includeZero` property." + ); + } + if ("includeZero" in option) { + if (typeof option.includeZero !== "boolean") { + throw new TypeError( + String(option.includeZero) + " is neither true nor false. `includeZero` option must be a Boolean value." + ); + } + if (option.includeZero && val === 0) { + return true; + } + } + } + return Number.isSafeInteger(val) && val >= 1; + }; + } +}); + +// node_modules/strip-dirs/index.js +var require_strip_dirs = __commonJS({ + "node_modules/strip-dirs/index.js"(exports2, module3) { + "use strict"; + var path6 = require("path"); + var util = require("util"); + var isNaturalNumber = require_is_natural_number(); + module3.exports = function stripDirs(pathStr, count, option) { + if (typeof pathStr !== "string") { + throw new TypeError( + util.inspect(pathStr) + " is not a string. First argument to strip-dirs must be a path string." + ); + } + if (path6.posix.isAbsolute(pathStr) || path6.win32.isAbsolute(pathStr)) { + throw new Error(`${pathStr} is an absolute path. strip-dirs requires a relative path.`); + } + if (!isNaturalNumber(count, { includeZero: true })) { + throw new Error( + "The Second argument of strip-dirs must be a natural number or 0, but received " + util.inspect(count) + "." + ); + } + if (option) { + if (typeof option !== "object") { + throw new TypeError( + util.inspect(option) + " is not an object. Expected an object with a boolean `disallowOverflow` property." + ); + } + if (Array.isArray(option)) { + throw new TypeError( + util.inspect(option) + " is an array. Expected an object with a boolean `disallowOverflow` property." + ); + } + if ("disallowOverflow" in option && typeof option.disallowOverflow !== "boolean") { + throw new TypeError( + util.inspect(option.disallowOverflow) + " is neither true nor false. `disallowOverflow` option must be a Boolean value." + ); + } + } else { + option = { disallowOverflow: false }; + } + const pathComponents = path6.normalize(pathStr).split(path6.sep); + if (pathComponents.length > 1 && pathComponents[0] === ".") { + pathComponents.shift(); + } + if (count > pathComponents.length - 1) { + if (option.disallowOverflow) { + throw new RangeError("Cannot strip more directories than there are."); + } + count = pathComponents.length - 1; + } + return path6.join.apply(null, pathComponents.slice(count)); + }; + } +}); + +// node_modules/decompress/index.js +var require_decompress = __commonJS({ + "node_modules/decompress/index.js"(exports2, module3) { + "use strict"; + var path6 = require("path"); + var fs2 = require_graceful_fs(); + var decompressTar = require_decompress_tar(); + var decompressTarbz2 = require_decompress_tarbz2(); + var decompressTargz = require_decompress_targz(); + var decompressUnzip = require_decompress_unzip(); + var makeDir = require_make_dir(); + var pify = require_pify(); + var stripDirs = require_strip_dirs(); + var fsP = pify(fs2); + var runPlugins = (input, opts) => { + if (opts.plugins.length === 0) { + return Promise.resolve([]); + } + return Promise.all(opts.plugins.map((x) => x(input, opts))).then((files) => files.reduce((a, b) => a.concat(b))); + }; + var safeMakeDir = (dir, realOutputPath) => { + return fsP.realpath(dir).catch((_) => { + const parent = path6.dirname(dir); + return safeMakeDir(parent, realOutputPath); + }).then((realParentPath) => { + if (realParentPath.indexOf(realOutputPath) !== 0) { + throw new Error("Refusing to create a directory outside the output path."); + } + return makeDir(dir).then(fsP.realpath); + }); + }; + var preventWritingThroughSymlink = (destination, realOutputPath) => { + return fsP.readlink(destination).catch((_) => { + return null; + }).then((symlinkPointsTo) => { + if (symlinkPointsTo) { + throw new Error("Refusing to write into a symlink"); + } + return realOutputPath; + }); + }; + var extractFile = (input, output, opts) => runPlugins(input, opts).then((files) => { + if (opts.strip > 0) { + files = files.map((x) => { + x.path = stripDirs(x.path, opts.strip); + return x; + }).filter((x) => x.path !== "."); + } + if (typeof opts.filter === "function") { + files = files.filter(opts.filter); + } + if (typeof opts.map === "function") { + files = files.map(opts.map); + } + if (!output) { + return files; + } + return Promise.all(files.map((x) => { + const dest = path6.join(output, x.path); + const mode = x.mode & ~process.umask(); + const now = /* @__PURE__ */ new Date(); + if (x.type === "directory") { + return makeDir(output).then((outputPath) => fsP.realpath(outputPath)).then((realOutputPath) => safeMakeDir(dest, realOutputPath)).then(() => fsP.utimes(dest, now, x.mtime)).then(() => x); + } + return makeDir(output).then((outputPath) => fsP.realpath(outputPath)).then((realOutputPath) => { + return safeMakeDir(path6.dirname(dest), realOutputPath).then(() => realOutputPath); + }).then((realOutputPath) => { + if (x.type === "file") { + return preventWritingThroughSymlink(dest, realOutputPath); + } + return realOutputPath; + }).then((realOutputPath) => { + return fsP.realpath(path6.dirname(dest)).then((realDestinationDir) => { + if (realDestinationDir.indexOf(realOutputPath) !== 0) { + throw new Error("Refusing to write outside output directory: " + realDestinationDir); + } + }); + }).then(() => { + if (x.type === "link") { + return fsP.link(x.linkname, dest); + } + if (x.type === "symlink" && process.platform === "win32") { + return fsP.link(x.linkname, dest); + } + if (x.type === "symlink") { + return fsP.symlink(x.linkname, dest); + } + return fsP.writeFile(dest, x.data, { mode }); + }).then(() => x.type === "file" && fsP.utimes(dest, now, x.mtime)).then(() => x); + })); + }); + module3.exports = (input, output, opts) => { + if (typeof input !== "string" && !Buffer.isBuffer(input)) { + return Promise.reject(new TypeError("Input file required")); + } + if (typeof output === "object") { + opts = output; + output = null; + } + opts = Object.assign({ plugins: [ + decompressTar(), + decompressTarbz2(), + decompressTargz(), + decompressUnzip() + ] }, opts); + const read = typeof input === "string" ? fsP.readFile(input) : Promise.resolve(input); + return read.then((buf) => extractFile(buf, output, opts)); + }; + } +}); + +// mcs-spyglass-validate.mjs +var import_node_fs2 = require("node:fs"); +var import_node_os2 = require("node:os"); +var import_node_path = require("node:path"); +var import_node_url2 = require("node:url"); + +// node_modules/@spyglassmc/core/lib/common/Dev.js +var Dev; +(function(Dev2) { + function assertDefined(value) { + if (value === void 0) { + throw new Error(`'${Dev2.stringify(value)}' is 'undefined'`); + } + } + Dev2.assertDefined = assertDefined; + function assertNever(value) { + throw new Error(`'${Dev2.stringify(value)}' is not of type 'never'`); + } + Dev2.assertNever = assertNever; + function assertTrue(value, message2) { + if (!value) { + throw new Error(`Assertion failed: ${message2}. '${Dev2.stringify(value)}' should be true.`); + } + } + Dev2.assertTrue = assertTrue; + function estimateMemoryUsage(value) { + const ByteToBits = 8; + const PointerSize = 8; + let ans = 0; + const calculatedObjects = /* @__PURE__ */ new Set(); + const stack = [value]; + while (stack.length) { + const current = stack.pop(); + switch (typeof current) { + case "bigint": { + const bits = Math.ceil(Math.log2(Number(current))); + ans += (2 + Math.ceil(bits / (ByteToBits * PointerSize))) * PointerSize; + break; + } + case "boolean": + ans += PointerSize; + break; + case "number": + ans += 8; + break; + case "object": + ans += PointerSize; + if (!current || calculatedObjects.has(current)) { + break; + } + ans += PointerSize; + for (const value2 of Object.values(current)) { + stack.push(value2); + ans += PointerSize; + } + calculatedObjects.add(current); + break; + case "string": + ans += current.length * 2; + break; + case "symbol": + ans += PointerSize; + break; + default: + break; + } + } + return ans; + } + Dev2.estimateMemoryUsage = estimateMemoryUsage; + function stringify(value) { + if (value && typeof value === "object") { + try { + const seen = /* @__PURE__ */ new Set(); + return JSON.stringify(value, (k, v) => { + if (v && typeof v === "object") { + return seen.has(v) ? "[Circular]" : (seen.add(v), v); + } else { + return bigintJsonNumberReplacer(k, v); + } + }); + } catch (ignored) { + return `{ ${Object.entries(value).map(([k, v]) => `'${k}': '${String(v)}'`).join(", ")} }`; + } + } else if (typeof value === "symbol") { + return String(value); + } else { + return `${value}`; + } + } + Dev2.stringify = stringify; +})(Dev || (Dev = {})); + +// node_modules/@spyglassmc/core/lib/common/EventDispatcher.js +var EventDispatcher = class { + #target = new EventTarget(); + emit(name, data) { + this.#target.dispatchEvent(new CustomEvent(name, { detail: data })); + } + on(name, listener, options2) { + this.#target.addEventListener(name, (event) => { + Dev.assertTrue(event instanceof CustomEvent, "event must be an instance of CustomEvent"); + listener(event.detail); + }, options2); + return this; + } +}; + +// node_modules/@spyglassmc/core/lib/common/json.js +function bigintJsonLosslessReplacer(_key, value) { + return typeof value === "bigint" ? `$$type:bigint;$$value:${value}` : value; +} +function bigintJsonLosslessReviver(_key, value) { + return typeof value === "string" && value.startsWith("$$type:bigint;$$value:") ? BigInt(value.substring(22)) : value; +} +function bigintJsonNumberReplacer(_key, value) { + return typeof value === "bigint" ? JSON.rawJSON(value.toString()) : value; +} +function bigintJsonNumberReviver(_key, value, data) { + return typeof value === "number" && data?.source !== void 0 && !data.source.includes(".") && !data.source.includes("e") && !data.source.includes("E") && BigInt(value).toString() !== data.source ? BigInt(data.source) : value; +} + +// node_modules/@spyglassmc/core/lib/common/Logger.js +var Logger; +(function(Logger2) { + function create() { + return console; + } + Logger2.create = create; + function noop6() { + return new NoopLogger(); + } + Logger2.noop = noop6; +})(Logger || (Logger = {})); +var NoopLogger = class { + error() { + } + info() { + } + log() { + } + warn() { + } +}; + +// node_modules/@spyglassmc/core/lib/common/Operations.js +var Operations = class { + parent; + constructor(parent) { + this.parent = parent; + } + undoOps = []; + redoOps = []; + addUndoOp(op) { + this.undoOps.push(op); + this.parent?.addUndoOp(op); + } + addRedoOp(op) { + this.redoOps.push(op); + this.parent?.addRedoOp(op); + } + set(obj, key2, value, receiver = obj) { + const oldValue = Reflect.get(obj, key2, receiver); + const op = () => { + Reflect.set(obj, key2, value, receiver); + }; + const undoOp = () => { + Reflect.set(obj, key2, oldValue, receiver); + }; + this.addRedoOp(op); + this.addUndoOp(undoOp); + op(); + } + undo() { + for (let i = this.undoOps.length - 1; i >= 0; i--) { + this.undoOps[i](); + } + } + redo() { + this.redoOps.forEach((op) => op()); + } +}; + +// node_modules/@spyglassmc/core/lib/common/util.js +var import_binary_search = __toESM(require_binary_search(), 1); +var import_rfdc = __toESM(require_rfdc(), 1); +var import_whatwg_url = __toESM(require_whatwg_url(), 1); +var Uri = isBuiltInURLGood() ? URL : import_whatwg_url.URL; +function isBuiltInURLGood() { + try { + return new URL("archive://mcdoc.tar.gz/foo.mcdoc").host === "mcdoc.tar.gz"; + } catch { + return false; + } +} +function SingletonPromise(getKey = (args) => args[0]) { + return (_target, _key, descripter) => { + const promises = /* @__PURE__ */ new Map(); + const decoratedMethod = descripter.value; + descripter.value = function(...args) { + const key2 = getKey(args); + if (promises.has(key2)) { + return promises.get(key2); + } + const ans = decoratedMethod.apply(this, args).then((ans2) => (promises.delete(key2), ans2), (e) => (promises.delete(key2), Promise.reject(e))); + promises.set(key2, ans); + return ans; + }; + return descripter; + }; +} +var ResourceLocation; +(function(ResourceLocation2) { + ResourceLocation2.TagPrefix = "#"; + ResourceLocation2.NamespacePathSep = ":"; + ResourceLocation2.PathSep = "/"; + ResourceLocation2.DefaultNamespace = "minecraft"; + function lengthen(value) { + switch (value.indexOf(ResourceLocation2.NamespacePathSep)) { + case -1: + return `${ResourceLocation2.DefaultNamespace}${ResourceLocation2.NamespacePathSep}${value}`; + case 0: + return `${ResourceLocation2.DefaultNamespace}${value}`; + default: + return value; + } + } + ResourceLocation2.lengthen = lengthen; + function shorten(value) { + return value.replace(/^(?:minecraft)?:/, ""); + } + ResourceLocation2.shorten = shorten; +})(ResourceLocation || (ResourceLocation = {})); +function bufferToString(buffer) { + const ans = new TextDecoder().decode(buffer); + return ans; +} +var Arrayable; +(function(Arrayable2) { + function is(value, isT) { + return Array.isArray(value) ? value.every((e) => isT(e)) : isT(value); + } + Arrayable2.is = is; + function toArray(value) { + return Array.isArray(value) ? value : [value]; + } + Arrayable2.toArray = toArray; +})(Arrayable || (Arrayable = {})); +var TypePredicates; +(function(TypePredicates2) { + function isString(value) { + return typeof value === "string"; + } + TypePredicates2.isString = isString; +})(TypePredicates || (TypePredicates = {})); +function isPojo(value) { + return !!value && typeof value === "object" && !Array.isArray(value); +} +function merge(a, b) { + const ans = (0, import_rfdc.default)()(a); + for (const [key2, value] of Object.entries(b)) { + if (isPojo(ans[key2]) && isPojo(value)) { + ans[key2] = merge(ans[key2], value); + } else if (value === void 0) { + delete ans[key2]; + } else { + ans[key2] = value; + } + } + return ans; +} +var Lazy; +(function(Lazy2) { + const LazyDiscriminator = Symbol("LazyDiscriminator"); + function create(getter) { + return { discriminator: LazyDiscriminator, getter }; + } + Lazy2.create = create; + function isComplex(lazy) { + return lazy?.discriminator === LazyDiscriminator; + } + Lazy2.isComplex = isComplex; + function isUnresolved(lazy) { + return isComplex(lazy) && !("value" in lazy); + } + Lazy2.isUnresolved = isUnresolved; + function resolve2(lazy) { + return isUnresolved(lazy) ? lazy.value = lazy.getter() : lazy; + } + Lazy2.resolve = resolve2; +})(Lazy || (Lazy = {})); +function getStates(category, ids, ctx) { + const ans = {}; + ids = ids.map(ResourceLocation.lengthen); + for (const id of ids) { + ctx.symbols.query(ctx.doc, category, id).forEachMember((state, stateQuery) => { + const values = Object.keys(stateQuery.visibleMembers); + const set = ans[state] ??= /* @__PURE__ */ new Set(); + const defaultValue = stateQuery.symbol?.relations?.default; + if (defaultValue) { + set.add(defaultValue.path[defaultValue.path.length - 1]); + } + for (const value of values) { + set.add(value); + } + }); + } + return Object.fromEntries(Object.entries(ans).map(([k, v]) => [k, [...v]])); +} +var binarySearch = import_binary_search.default; +function isIterable(value) { + return !!value[Symbol.iterator]; +} +function getOrInsertComputed(map3, key2, callbackFunction) { + if (!map3.has(key2)) { + map3.set(key2, callbackFunction(key2)); + } + return map3.get(key2); +} +function bytesToHex(bytes) { + if ("Buffer" in globalThis && bytes instanceof Buffer) { + return bytes.toString("hex"); + } else if ("toHex" in Uint8Array.prototype && typeof Uint8Array.prototype.toHex === "function") { + return Uint8Array.prototype.toHex.call(bytes); + } + let ans = ""; + for (const v of bytes) { + ans += v.toString(16).padStart(2, "0"); + } + return ans; +} +function isObject(val) { + return typeof val === "function" || !!val && typeof val === "object"; +} +function normalizeUriPathname(pathname) { + return pathname.replace(/%3A/gi, ":").replace(/^\/[A-Z]:\//, (match) => match.toLowerCase()); +} +function normalizeUri(uri) { + const obj = new Uri(uri); + obj.pathname = normalizeUriPathname(obj.pathname); + return obj.toString(); +} +async function getSha1(data) { + if (typeof data === "string") { + data = new TextEncoder().encode(data); + } + const hash = await crypto.subtle.digest("SHA-1", data.buffer); + return bytesToHex(new Uint8Array(hash)); +} +function compressBytes(bytes, algorithm) { + return streamToBytes(compressStream(bytesToStream(bytes), algorithm)); +} +function compressStream(stream2, algorithm) { + return stream2.pipeThrough(new CompressionStream(algorithm)); +} +function decompressBytes(bytes, algorithm) { + return streamToBytes(decompressStream(bytesToStream(bytes), algorithm)); +} +function decompressStream(stream2, algorithm) { + return stream2.pipeThrough(new DecompressionStream(algorithm)); +} +function bytesToStream(bytes) { + return new Blob([bytes]).stream(); +} +function streamToBytes(stream2) { + return new Response(stream2).bytes(); +} +function numericEquals(a, b) { + return tryConvertToNumberWithoutPrecisionLoss(a) === tryConvertToNumberWithoutPrecisionLoss(b); +} +function tryConvertToNumberWithoutPrecisionLoss(n) { + if (typeof n === "bigint") { + const num = Number(n); + if (BigInt(num) === n) { + return num; + } + } + return n; +} +function min(a, b) { + return a < b ? a : b; +} +function max(a, b) { + return a > b ? a : b; +} + +// node_modules/@spyglassmc/core/lib/common/ReadonlyProxy.js +var ReadonlyProxy; +(function(ReadonlyProxy2) { + function create(obj) { + return new Proxy(obj, new ReadonlyProxyHandler()); + } + ReadonlyProxy2.create = create; +})(ReadonlyProxy || (ReadonlyProxy = {})); +var ReadonlyProxyHandler = class { + map = /* @__PURE__ */ new Map(); + get(target, p, receiver) { + const value = Reflect.get(target, p, receiver); + if (p !== "prototype" && isObject(value)) { + return getOrInsertComputed(this.map, p, () => ReadonlyProxy.create(value)); + } + return value; + } + set(_target, p, _value, _receiver) { + throw new TypeError(`Cannot set property '${String(p)}' on a readonly proxy`); + } + deleteProperty(_target, p) { + throw new TypeError(`Cannot delete property '${String(p)}' on a readonly proxy`); + } +}; + +// node_modules/@spyglassmc/core/lib/common/StateProxy.js +var BranchOff = Symbol("StateBranchOff"); +var Is = Symbol("IsStateProxy"); +var Origin = Symbol("OriginState"); +var Redo = Symbol("RedoStateChanges"); +var Undo = Symbol("UndoStateChanges"); +var StateProxy; +(function(StateProxy2) { + function branchOff(proxy) { + return proxy[BranchOff](); + } + StateProxy2.branchOff = branchOff; + function create(obj) { + if (StateProxy2.is(obj)) { + throw new TypeError("Cannot create a proxy over a proxy. You might want to use branchOff instead."); + } + return _createStateProxy(obj, new Operations()); + } + StateProxy2.create = create; + function dereference(value) { + return StateProxy2.is(value) ? value[Origin] : value; + } + StateProxy2.dereference = dereference; + function is(obj) { + return obj?.[Is]; + } + StateProxy2.is = is; + function redoChanges(proxy) { + proxy[Redo](); + } + StateProxy2.redoChanges = redoChanges; + function undoChanges(proxy) { + proxy[Undo](); + } + StateProxy2.undoChanges = undoChanges; +})(StateProxy || (StateProxy = {})); +var StateProxyHandler = class { + rootOps; + map = /* @__PURE__ */ new Map(); + constructor(rootOps) { + this.rootOps = rootOps; + } + #branchOff(target) { + return _createStateProxy(target, new Operations(this.rootOps)); + } + get(target, p, receiver) { + switch (p) { + case BranchOff: + return () => this.#branchOff(target); + case Is: + return true; + case Origin: + return target; + case Redo: + return () => this.rootOps.redo(); + case Undo: + return () => this.rootOps.undo(); + } + const value = Reflect.get(target, p, receiver); + if (p !== "prototype" && isObject(value)) { + return getOrInsertComputed(this.map, p, () => _createStateProxy(value, this.rootOps)); + } + return value; + } + set(target, p, value, receiver) { + if (p === BranchOff || p === Is || p === Origin || p === Redo || p === Undo) { + throw new TypeError(`Cannot set ${String(p)}`); + } + this.rootOps.set(target, p, StateProxy.dereference(value), receiver); + return true; + } +}; +function _createStateProxy(target, operations) { + return new Proxy(target, new StateProxyHandler(operations)); +} + +// node_modules/@spyglassmc/core/lib/common/TwoWayMap.js +var TwoWayMap = class { + _map = /* @__PURE__ */ new Map(); + _reversedMap = /* @__PURE__ */ new Map(); + constructor(values = []) { + for (const [k, v] of values) { + this._map.set(k, v); + this._reversedMap.set(v, k); + } + } + get size() { + return this._map.size; + } + clear() { + this._map.clear(); + this._reversedMap.clear(); + } + delete(key2) { + const value = this._map.get(key2); + const ans = this._map.delete(key2); + if (value !== void 0) { + this._reversedMap.delete(value); + } + return ans; + } + deleteValue(value) { + const key2 = this._reversedMap.get(value); + const ans = this._reversedMap.delete(value); + if (key2 !== void 0) { + this._map.delete(key2); + } + return ans; + } + get(key2) { + return this._map.get(key2); + } + getKey(value) { + return this._reversedMap.get(value); + } + has(key2) { + return this._map.has(key2); + } + hasValue(value) { + return this._reversedMap.has(value); + } + set(key2, value) { + this._map.set(key2, value); + this._reversedMap.set(value, key2); + return this; + } + forEach(callbackfn, thisArg) { + for (const [key2, value] of this._map) { + callbackfn.apply(thisArg, [value, key2, this]); + } + } + entries() { + return this._map.entries(); + } + keys() { + return this._map.keys(); + } + values() { + return this._map.values(); + } + [Symbol.iterator]() { + return this._map.entries(); + } + [Symbol.toStringTag] = "TwoWayMap"; +}; + +// node_modules/@spyglassmc/core/lib/common/UriStore.js +var UriStore = class _UriStore { + #trie = /* @__PURE__ */ new Map(); + /** + * Adds a file URI or a directory URI to the store. + * Directory URIs must end with a slash (`/`), otherwise it will be treated as a file URI. + */ + add(uri) { + const [parts, isDir] = this.#dissectUri(uri); + let node = this.#trie; + for (const [i, part] of parts.entries()) { + const isLast = i === parts.length - 1; + const shouldAddDir = !isLast || isDir; + if (!node.has(part)) { + node.set(part, shouldAddDir ? /* @__PURE__ */ new Map() : {}); + } + if (!isLast) { + const next = node.get(part); + if (next instanceof Map) { + node = next; + } else { + throw new Error(`Cannot add '${uri}' because ${parts.slice(0, i + 1).join("/")} is a file`); + } + } + } + } + /** + * Returns true if the specified URI exists in the store and is of the expected type. + * Directory URIs must end with a slash (`/`), otherwise it will be treated as a file URI. + */ + has(uri) { + const [parts, isDir] = this.#dissectUri(uri); + let node = this.#trie; + for (const part of parts) { + if (!(node instanceof Map)) { + return false; + } + node = node.get(part); + } + return isDir ? node instanceof Map : !!node && typeof node === "object" && !(node instanceof Map); + } + /** + * Deletes a URI from the store if it exists. + * For directories, all sub URIs under them will be recursively removed. + */ + delete(uri) { + const [parts, _isDir] = this.#dissectUri(uri); + let node = this.#trie; + for (const [i, part] of parts.entries()) { + if (!(node instanceof Map)) { + return; + } + if (i === parts.length - 1) { + node.delete(part); + } else { + node = node.get(part); + } + } + } + /** + * Returns names of all direct children of the URI. + * An empty result is generated if the directory URI does not exist. + */ + *getChildrenNames(uri) { + const [parts, _isDir] = this.#dissectUri(uri); + let node = this.#trie; + for (const part of parts) { + if (!(node instanceof Map)) { + return; + } + node = node.get(part); + } + if (!(node instanceof Map)) { + return; + } + yield* node.keys(); + } + /** + * Returns URIs of all files under a directory and its subdirectories. + * An empty result is generated if the directory URI does not exist. + */ + *getSubFiles(uri) { + const [parts, _isDir] = this.#dissectUri(uri); + let node = this.#trie; + for (const part of parts) { + if (!(node instanceof Map)) { + return; + } + node = node.get(part); + } + if (!(node instanceof Map)) { + return; + } + yield* this.#collect(node, parts); + } + /** + * Removes all URIs from the store. + */ + clear() { + this.#trie.clear(); + } + /** + * Creates a deep copy of this store. + */ + clone() { + const clonedStore = new _UriStore(); + clonedStore.#trie = structuredClone(this.#trie); + return clonedStore; + } + [Symbol.iterator]() { + return this.#collect(this.#trie, []); + } + /** + * Dissects a URI string into parts that can be used as edges in the trie. + */ + #dissectUri(uriString) { + const uri = new Uri(uriString); + const isDir = uriString.endsWith("/"); + const parts = [ + uri.protocol, + uri.host || "localhost", + ...normalizeUriPathname(uri.pathname).split("/").filter((p) => p).map(decodeURIComponent) + ]; + return [parts, isDir]; + } + /** + * Reconstructs a URI string from its parts. + * + * This is the inverse of `#dissectUri`. + * It handles special cases like omitting the host when it's 'localhost' and adding a trailing + * slash for directory URIs. + */ + #buildUri(parts, isDir) { + const [protocol, host, ...segments] = parts; + const pathname = normalizeUriPathname(`/${segments.map(encodeURIComponent).join("/")}`); + const trailingSlash = isDir && segments.length ? "/" : ""; + return `${protocol}//${host === "localhost" ? "" : host}${pathname}${trailingSlash}`; + } + /** + * Returns a generator that yields all URIs under a DirectoryNode recursively. + * @param currentParts Parts corresponding to the URI of the DirectoryNode. + */ + *#collect(node, currentParts) { + for (const [key2, value] of node) { + const nextParts = [...currentParts, key2]; + if (value instanceof Map) { + yield* this.#collect(value, nextParts); + } else { + yield this.#buildUri(nextParts, false); + } + } + } +}; + +// node_modules/@spyglassmc/core/lib/node/AstNode.js +var import_binary_search2 = __toESM(require_binary_search(), 1); + +// node_modules/@spyglassmc/core/lib/source/Source.js +var CRLF = "\r\n"; +var CR = "\r"; +var LF = "\n"; +var Whitespaces = Object.freeze([" ", "\n", "\r", " "]); +var ReadonlySource = class { + string; + indexMap; + innerCursor = 0; + constructor(string11, indexMap = []) { + this.string = string11; + this.indexMap = indexMap; + } + get cursor() { + return IndexMap.toOuterOffset(this.indexMap, this.innerCursor); + } + /** + * @param offset The index to offset from cursor. Defaults to 0. + * + * @returns The range of the specified character. + * + * @example + * getCharRange(-1) // Returns the range of the character before cursor. + * getCharRange() // Returns the range of the character at cursor. + * getCharRange(1) // Returns the range of the character after cursor. + */ + getCharRange(offset = 0) { + return IndexMap.toOuterRange(this.indexMap, Range.create(this.innerCursor + offset, this.innerCursor + offset + 1)); + } + /** + * Returns a string that helps visualize this `Source`'s index map. + * Primarily intended for debugging purposes. + */ + visualizeIndexMap() { + let res = this.string; + const adjustments = []; + for (const { inner, outer } of this.indexMap) { + const innerLength = inner.end - inner.start; + const outerLength = outer.end - outer.start; + const { char, count } = outerLength > innerLength ? { + count: outerLength - innerLength, + char: "\u2190" + // ← + } : { count: outer.start - inner.start, char: "\u2017" }; + adjustments.push({ idx: inner.start, str: char.repeat(count) }); + } + for (const { idx, str } of adjustments.reverse()) { + res = `${res.slice(0, idx)}${str}${res.slice(idx)}`; + } + return res; + } + /** + * Peeks a substring from the current cursor. + * @param length The length of the substring. Defaults to 1 + * @param offset The index to offset from cursor. Defaults to 0 + */ + peek(length = 1, offset = 0) { + return this.string.slice(this.innerCursor + offset, this.innerCursor + offset + length); + } + canRead(length = 1) { + const needed = this.innerCursor + length; + const available = this.string.length; + return this.innerCursor + length <= this.string.length; + } + canReadInLine() { + return this.canRead() && this.peek() !== CR && this.peek() !== LF; + } + /** + * If the `expectedValue` is right after the cursor, returns `true`. Otherwise returns `false`. + * + * @param offset Defaults to 0. + * + * @see {@link Source.trySkip} + */ + tryPeek(expectedValue, offset = 0) { + return this.peek(expectedValue.length, offset) === expectedValue; + } + tryPeekAfterWhitespace(expectedValue) { + const maxOffset = this.string.length - this.innerCursor; + let offset = 0; + while (offset < maxOffset && Source.isWhitespace(this.peek(1, offset))) { + offset++; + } + return this.tryPeek(expectedValue, offset); + } + peekUntil(...terminators) { + let ans = ""; + for (let cursor = this.innerCursor; cursor < this.string.length; cursor++) { + const c = this.string.charAt(cursor); + if (terminators.includes(c)) { + return ans; + } else { + ans += c; + } + } + return ans; + } + peekLine() { + return this.peekUntil(CR, LF); + } + peekRemaining(offset = 0) { + return this.string.slice(this.innerCursor + offset); + } + matchPattern(regex, offset = 0) { + return regex.test(this.peekRemaining(offset)); + } + /** + * If there is a non-space character between `cursor + offset` (inclusive) and the next newline, returns `true`. Otherwise returns `false`. + * + * @param offset Defaults to 0. + */ + hasNonSpaceAheadInLine(offset = 0) { + for (let cursor = this.innerCursor + offset; cursor < this.string.length; cursor++) { + const c = this.string.charAt(cursor); + if (Source.isNewline(c)) { + break; + } + if (!Source.isSpace(c)) { + return true; + } + } + return false; + } + slice(param0, end) { + if (typeof param0 === "number") { + const innerStart = IndexMap.toInnerOffset(this.indexMap, param0); + const innerEnd = end !== void 0 ? IndexMap.toInnerOffset(this.indexMap, end) : void 0; + return this.string.slice(innerStart, innerEnd); + } + const range3 = IndexMap.toInnerRange(this.indexMap, Range.get(param0)); + return this.string.slice(range3.start, range3.end); + } + sliceToCursor(start) { + const innerStart = IndexMap.toInnerOffset(this.indexMap, start); + return this.string.slice(innerStart, this.innerCursor); + } +}; +var Source = class _Source extends ReadonlySource { + string; + indexMap; + constructor(string11, indexMap = []) { + super(string11, indexMap); + this.string = string11; + this.indexMap = indexMap; + } + get cursor() { + return super.cursor; + } + set cursor(cursor) { + this.innerCursor = IndexMap.toInnerOffset(this.indexMap, cursor); + } + clone() { + const ans = new _Source(this.string, this.indexMap); + ans.innerCursor = this.innerCursor; + return ans; + } + read() { + return this.string.charAt(this.innerCursor++); + } + /** + * Skips the current character. + * @param step The step to skip. Defaults to 1 + */ + skip(step = 1) { + this.innerCursor += step; + return this; + } + /** + * If the `expectedValue` is right after the cursor, skips it and returns `true`. Otherwise returns `false`. + * + * This is a shortcut for the following piece of code: + * ```typescript + * declare const src: Source + * if (src.peek(expectedValue.length) === expectedValue) { + * src.skip(expectedValue.length) + * // Do something here. + * } + * ``` + * + * @see {@link Source.tryPeek} + */ + trySkip(expectedValue) { + if (this.peek(expectedValue.length) === expectedValue) { + this.skip(expectedValue.length); + return true; + } + return false; + } + /** + * Reads until the end of this line. + */ + readLine() { + return this.readUntil(CR, LF); + } + /** + * Skips until the end of this line. + */ + skipLine() { + this.readLine(); + return this; + } + /** + * Jumps to the beginning of the next line. + */ + nextLine() { + this.skipLine(); + if (this.peek(2) === CRLF) { + this.skip(2); + } else if (this.peek() === CR || this.peek() === LF) { + this.skip(); + } + return this; + } + readSpace() { + const start = this.innerCursor; + this.skipSpace(); + return this.string.slice(start, this.innerCursor); + } + skipSpace() { + while (this.canRead() && _Source.isSpace(this.peek())) { + this.skip(); + } + return this; + } + readWhitespace() { + const start = this.innerCursor; + this.skipWhitespace(); + return this.string.slice(start, this.innerCursor); + } + skipWhitespace() { + while (this.canRead() && _Source.isWhitespace(this.peek())) { + this.skip(); + } + return this; + } + readIf(predicate) { + let ans = ""; + while (this.canRead()) { + const c = this.peek(); + if (predicate(c)) { + this.skip(); + ans += c; + } else { + break; + } + } + return ans; + } + skipIf(predicate) { + this.readIf(predicate); + return this; + } + /** + * @param terminators Ending character. Will not be skipped or included in the result. + */ + readUntil(...terminators) { + let ans = ""; + while (this.canRead()) { + const c = this.peek(); + if (terminators.includes(c)) { + return ans; + } else { + ans += c; + } + this.skip(); + } + return ans; + } + /** + * @param terminators Ending character. Will not be skipped. + */ + skipUntilOrEnd(...terminators) { + this.readUntil(...terminators); + return this; + } + readUntilLineEnd() { + return this.readUntil(CR, LF); + } + skipUntilLineEnd() { + return this.skipUntilOrEnd(CR, LF); + } + readRemaining() { + const start = this.innerCursor; + this.innerCursor = this.string.length; + return this.string.slice(start); + } + skipRemaining() { + this.readRemaining(); + return this; + } +}; +(function(Source2) { + function isDigit(c) { + return c >= "0" && c <= "9"; + } + Source2.isDigit = isDigit; + function isBrigadierQuote(c) { + return c === '"' || c === "'"; + } + Source2.isBrigadierQuote = isBrigadierQuote; + function isNewline(c) { + return c === "\r\n" || c === "\r" || c === "\n"; + } + Source2.isNewline = isNewline; + function isSpace(c) { + return c === " " || c === " "; + } + Source2.isSpace = isSpace; + function isWhitespace(c) { + return Source2.isSpace(c) || Source2.isNewline(c); + } + Source2.isWhitespace = isWhitespace; +})(Source || (Source = {})); + +// node_modules/@spyglassmc/core/lib/source/Offset.js +var Offset; +(function(Offset2) { + function get(offset) { + if (typeof offset === "function") { + offset = offset(); + } + if (offset instanceof ReadonlySource) { + offset = offset.cursor; + } + return offset; + } + Offset2.get = get; +})(Offset || (Offset = {})); + +// node_modules/@spyglassmc/core/lib/source/Range.js +var Range; +(function(Range2) { + function get(range3) { + const evaluated = typeof range3 === "function" ? range3() : range3; + if (Range2.is(evaluated)) { + return Range2.create(evaluated.start, evaluated.end); + } + if (RangeContainer.is(evaluated)) { + return Range2.create(evaluated.range.start, evaluated.range.end); + } + return Range2.create(evaluated); + } + Range2.get = get; + function create(start, end) { + start = Offset.get(start); + return { start, end: end !== void 0 ? Offset.get(end) : start }; + } + Range2.create = create; + function span(from, to) { + return { start: Range2.get(from).start, end: Range2.get(to).end }; + } + Range2.span = span; + function is(obj) { + return !!obj && typeof obj === "object" && typeof obj.start === "number" && typeof obj.end === "number"; + } + Range2.is = is; + Range2.Beginning = Object.freeze(Range2.create(0, 1)); + Range2.Full = Object.freeze(Range2.create(0, Number.POSITIVE_INFINITY)); + function toString(range3) { + return `[${range3.start}, ${range3.end})`; + } + Range2.toString = toString; + function contains(range3, offset, endInclusive = false) { + range3 = get(range3); + return range3.start <= offset && (endInclusive ? offset <= range3.end : offset < range3.end); + } + Range2.contains = contains; + function containsRange(a, b, endInclusive = false) { + a = get(a); + b = get(b); + return contains(a, b.start, endInclusive) && contains(a, b.end, true); + } + Range2.containsRange = containsRange; + function intersects(a, b) { + return Range2.contains(a, b.start) || Range2.contains(b, a.start); + } + Range2.intersects = intersects; + function equals(a, b) { + return a.start === b.start && a.end === b.end; + } + Range2.equals = equals; + function endsBefore(range3, target, endInclusive = false) { + return endInclusive ? range3.end < Range2.get(target).start : range3.end <= Range2.get(target).start; + } + Range2.endsBefore = endsBefore; + function isEmpty(range3) { + range3 = get(range3); + return range3.start === range3.end; + } + Range2.isEmpty = isEmpty; + function length(range3) { + return range3.end - range3.start; + } + Range2.length = length; + function compare(a, b, endInclusive = false) { + if (endInclusive ? a.end < b.start : a.end <= b.start) { + return -1; + } else if (endInclusive ? a.start > b.end : a.start >= b.end) { + return 1; + } else { + return 0; + } + } + Range2.compare = compare; + function compareOffset(range3, offset, endInclusive = false) { + if (endInclusive ? range3.end < offset : range3.end <= offset) { + return -1; + } else if (range3.start > offset) { + return 1; + } else { + return 0; + } + } + Range2.compareOffset = compareOffset; + function translate(range3, startOffset, endOffset = startOffset) { + range3 = get(range3); + return { start: range3.start + startOffset, end: range3.end + endOffset }; + } + Range2.translate = translate; +})(Range || (Range = {})); +var RangeContainer; +(function(RangeContainer2) { + function is(obj) { + return !!obj && typeof obj === "object" && Range.is(obj.range); + } + RangeContainer2.is = is; +})(RangeContainer || (RangeContainer = {})); + +// node_modules/@spyglassmc/core/lib/source/IndexMap.js +var IndexMap; +(function(IndexMap2) { + function convertOffset(map3, offset, from, to) { + let ans = offset; + for (const pair of map3) { + if (Range.contains(pair[from], offset)) { + return pair[to].start; + } else if (Range.endsBefore(pair[from], offset)) { + ans = offset - pair[from].end + pair[to].end; + } else { + break; + } + } + return ans; + } + function toInnerOffset(map3, offset) { + return convertOffset(map3, offset, "outer", "inner"); + } + IndexMap2.toInnerOffset = toInnerOffset; + function toInnerRange(map3, outer) { + return Range.create(toInnerOffset(map3, outer.start), toInnerOffset(map3, outer.end)); + } + IndexMap2.toInnerRange = toInnerRange; + function toOuterOffset(map3, offset) { + return convertOffset(map3, offset, "inner", "outer"); + } + IndexMap2.toOuterOffset = toOuterOffset; + function toOuterRange(map3, inner) { + return Range.create(toOuterOffset(map3, inner.start), toOuterOffset(map3, inner.end)); + } + IndexMap2.toOuterRange = toOuterRange; +})(IndexMap || (IndexMap = {})); + +// node_modules/@spyglassmc/core/lib/source/Position.js +var Position; +(function(Position2) { + function create(param1, param2) { + if (typeof param1 === "object") { + return _createFromPartial(param1); + } else { + return _createFromNumbers(param1, param2); + } + } + Position2.create = create; + function _createFromPartial(partial) { + return { line: partial.line ?? 0, character: partial.character ?? 0 }; + } + function _createFromNumbers(line, character) { + return _createFromPartial({ line, character }); + } + Position2.Beginning = Position2.create(0, 0); + Position2.Infinity = Position2.create(Number.POSITIVE_INFINITY, Number.POSITIVE_INFINITY); + function toString(pos) { + return `<${pos.line}, ${pos.character}>`; + } + Position2.toString = toString; + function isBefore(pos1, pos2) { + return pos1.line < pos2.line || pos1.line === pos2.line && pos1.character < pos2.character; + } + Position2.isBefore = isBefore; +})(Position || (Position = {})); + +// node_modules/@spyglassmc/core/lib/source/PositionRange.js +var PositionRange; +(function(PositionRange2) { + function create(param1, param2, param3, param4) { + if (typeof param1 === "number") { + return { + start: Position.create(param1, param2), + end: Position.create(param3, param4) + }; + } else if (param2 !== void 0) { + return { + start: Position.create(param1), + end: Position.create(param2) + }; + } else { + const partial = param1; + return { + start: Position.create(partial.start ?? {}), + end: Position.create(partial.end ?? {}) + }; + } + } + PositionRange2.create = create; + function from(rangeLike, doc) { + const range3 = Range.get(rangeLike); + const ans = { + start: doc.positionAt(range3.start), + end: doc.positionAt(range3.end) + }; + return ans; + } + PositionRange2.from = from; + PositionRange2.Beginning = Object.freeze(PositionRange2.create(0, 0, 0, 1)); + PositionRange2.Full = Object.freeze(PositionRange2.create(Position.Beginning, Position.Infinity)); + function toString(range3) { + return `[${Position.toString(range3.start)}, ${Position.toString(range3.end)})`; + } + PositionRange2.toString = toString; + function contains(range3, pos) { + const { start, end } = range3; + if (pos.line < start.line || pos.line > end.line) { + return false; + } + if (start.line < pos.line && pos.line < end.line) { + return true; + } + return (pos.line === start.line ? pos.character >= start.character : true) && (pos.line === end.line ? pos.character < end.character : true); + } + PositionRange2.contains = contains; + function endsBefore(range3, pos) { + return Position.isBefore(Position.create(range3.end.line, range3.end.character - 1), pos); + } + PositionRange2.endsBefore = endsBefore; +})(PositionRange || (PositionRange = {})); + +// node_modules/@spyglassmc/core/lib/source/LanguageError.js +var LanguageError; +(function(LanguageError2) { + function create(message2, range3, severity = ErrorSeverity.Error, info, source) { + const ans = { range: range3, message: message2, severity }; + if (info) { + ans.info = info; + } + if (source) { + ans.source = source; + } + return ans; + } + LanguageError2.create = create; + function withPosRange(error4, doc) { + return { + posRange: PositionRange.from(error4.range, doc), + message: error4.message, + severity: error4.severity, + ...error4.info && { info: error4.info }, + ...error4.source && { source: error4.source } + }; + } + LanguageError2.withPosRange = withPosRange; +})(LanguageError || (LanguageError = {})); +var ErrorSeverity; +(function(ErrorSeverity2) { + ErrorSeverity2[ErrorSeverity2["Hint"] = 0] = "Hint"; + ErrorSeverity2[ErrorSeverity2["Information"] = 1] = "Information"; + ErrorSeverity2[ErrorSeverity2["Warning"] = 2] = "Warning"; + ErrorSeverity2[ErrorSeverity2["Error"] = 3] = "Error"; +})(ErrorSeverity || (ErrorSeverity = {})); + +// node_modules/@spyglassmc/core/lib/source/Location.js +var Location; +(function(Location2) { + function get(partial) { + return { + uri: partial.uri ?? "", + range: Range.get(partial.range ?? { start: 0, end: 0 }), + posRange: partial.posRange ?? { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } } + }; + } + Location2.get = get; + function create(doc, range3) { + return Location2.get({ uri: doc.uri, range: range3, posRange: PositionRange.from(range3, doc) }); + } + Location2.create = create; +})(Location || (Location = {})); + +// node_modules/@spyglassmc/core/lib/node/AstNode.js +var AstNode; +(function(AstNode2) { + function is(obj) { + return !!obj && typeof obj === "object" && typeof obj.type === "string" && Range.is(obj.range); + } + AstNode2.is = is; + function setParents(node) { + for (const child of node.children ?? []) { + child.parent = node; + setParents(child); + } + } + AstNode2.setParents = setParents; + function findChildIndex(node, needle, endInclusive = false) { + if (!node.children) { + return -1; + } + const comparator = typeof needle === "number" ? Range.compareOffset : Range.compare; + return (0, import_binary_search2.default)(node.children, needle, (a, b) => comparator(a.range, b, endInclusive)); + } + AstNode2.findChildIndex = findChildIndex; + function findChild(node, needle, endInclusive = false) { + return node.children?.[findChildIndex(node, needle, endInclusive)]; + } + AstNode2.findChild = findChild; + function findLastChildIndex(node, needle, endInclusive = false) { + if (!node.children) { + return -1; + } + let ans = -1; + for (const [i, childNode] of node.children.entries()) { + if (Range.endsBefore(childNode.range, needle, endInclusive)) { + ans = i; + } else { + break; + } + } + return ans; + } + AstNode2.findLastChildIndex = findLastChildIndex; + function findLastChild(node, needle, endInclusive = false) { + return node.children?.[findLastChildIndex(node, needle, endInclusive)]; + } + AstNode2.findLastChild = findLastChild; + function findDeepestChild({ node, needle, endInclusive = false, predicate = () => true }) { + let last; + let head = Range.contains(node, needle, endInclusive) ? node : void 0; + while (head && predicate(head)) { + last = head; + head = findChild(head, needle, endInclusive); + } + return last; + } + AstNode2.findDeepestChild = findDeepestChild; + function findShallowestChild({ node, needle, endInclusive = false, predicate = () => true }) { + let head = Range.contains(node, needle, endInclusive) ? node : void 0; + while (head && !predicate(head)) { + head = findChild(head, needle, endInclusive); + } + return head; + } + AstNode2.findShallowestChild = findShallowestChild; + function* getLocalsToRoot(node) { + let head = node; + while (head) { + if (head.locals) { + yield head.locals; + } + head = node.parent; + } + } + AstNode2.getLocalsToRoot = getLocalsToRoot; + function* getLocalsToLeaves(node) { + if (node.locals) { + yield node.locals; + } + for (const child of node.children ?? []) { + yield* getLocalsToLeaves(child); + } + } + AstNode2.getLocalsToLeaves = getLocalsToLeaves; +})(AstNode || (AstNode = {})); + +// node_modules/@spyglassmc/core/lib/node/BooleanNode.js +var BooleanNode; +(function(BooleanNode2) { + function is(obj) { + return obj.type === "boolean"; + } + BooleanNode2.is = is; + function mock(range3) { + return { type: "boolean", range: Range.get(range3) }; + } + BooleanNode2.mock = mock; +})(BooleanNode || (BooleanNode = {})); + +// node_modules/@spyglassmc/core/lib/node/CommentNode.js +var CommentNode; +(function(CommentNode2) { + function is(obj) { + return obj?.type === "comment"; + } + CommentNode2.is = is; +})(CommentNode || (CommentNode = {})); + +// node_modules/@spyglassmc/core/lib/node/ErrorNode.js +var ErrorNode; +(function(ErrorNode2) { + function is(obj) { + return obj.type === "error"; + } + ErrorNode2.is = is; +})(ErrorNode || (ErrorNode = {})); + +// node_modules/@spyglassmc/core/lib/node/FileNode.js +var FileNode; +(function(FileNode2) { + function getErrors(node) { + return [ + ...node.parserErrors, + ...node.binderErrors ?? [], + ...node.checkerErrors ?? [], + ...node.linterErrors ?? [] + ]; + } + FileNode2.getErrors = getErrors; +})(FileNode || (FileNode = {})); + +// node_modules/@spyglassmc/core/lib/node/FloatNode.js +var FloatNode; +(function(FloatNode2) { + function is(obj) { + return obj.type === "float"; + } + FloatNode2.is = is; + function mock(range3) { + return { type: "float", range: Range.get(range3), value: 0 }; + } + FloatNode2.mock = mock; +})(FloatNode || (FloatNode = {})); + +// node_modules/@spyglassmc/core/lib/node/IntegerNode.js +var IntegerNode; +(function(IntegerNode2) { + function is(obj) { + return obj.type === "integer"; + } + IntegerNode2.is = is; + function mock(range3) { + return { type: "integer", range: Range.get(range3), value: 0 }; + } + IntegerNode2.mock = mock; +})(IntegerNode || (IntegerNode = {})); + +// node_modules/@spyglassmc/core/lib/node/ListNode.js +var ItemNode; +(function(ItemNode2) { + function is(node) { + return node?.type === "item"; + } + ItemNode2.is = is; +})(ItemNode || (ItemNode = {})); + +// node_modules/@spyglassmc/core/lib/node/LiteralNode.js +var LiteralNode; +(function(LiteralNode3) { + function is(obj) { + return obj?.type === "literal"; + } + LiteralNode3.is = is; + function mock(range3, options2) { + return { type: "literal", range: Range.get(range3), options: options2, value: "" }; + } + LiteralNode3.mock = mock; +})(LiteralNode || (LiteralNode = {})); + +// node_modules/@spyglassmc/core/lib/node/LongNode.js +var LongNode; +(function(LongNode2) { + function is(obj) { + return obj.type === "long"; + } + LongNode2.is = is; + function mock(range3) { + return { type: "long", range: Range.get(range3), value: 0n }; + } + LongNode2.mock = mock; +})(LongNode || (LongNode = {})); + +// node_modules/@spyglassmc/core/lib/node/PrefixedNode.js +var PrefixedNode; +(function(PrefixedNode2) { + function is(obj) { + return obj.type === "prefixed"; + } + PrefixedNode2.is = is; + function mock(range3, prefix, child) { + return { + type: "prefixed", + range: Range.get(range3), + prefix, + children: [ + LiteralNode.mock(range3, { pool: [prefix] }), + child + ] + }; + } + PrefixedNode2.mock = mock; +})(PrefixedNode || (PrefixedNode = {})); + +// node_modules/@spyglassmc/core/lib/node/RecordNode.js +var PairNode; +(function(PairNode2) { + function is(node) { + return node?.type === "pair"; + } + PairNode2.is = is; +})(PairNode || (PairNode = {})); + +// node_modules/@spyglassmc/core/lib/node/ResourceLocationNode.js +var ResourceLocationNode; +(function(ResourceLocationNode2) { + const TagPrefix = ResourceLocation.TagPrefix; + const NamespacePathSep = ResourceLocation.NamespacePathSep; + const PathSep = ResourceLocation.PathSep; + const DefaultNamespace = ResourceLocation.DefaultNamespace; + function is(obj) { + return obj?.type === "resource_location"; + } + ResourceLocationNode2.is = is; + function mock(range3, options2) { + return { type: "resource_location", range: Range.get(range3), options: options2 }; + } + ResourceLocationNode2.mock = mock; + function toString(node, type2 = "origin", includesTagPrefix = false) { + const path6 = node.path ? node.path.join(PathSep) : ""; + let id; + switch (type2) { + case "origin": + id = node.namespace !== void 0 ? `${node.namespace}${NamespacePathSep}${path6}` : path6; + break; + case "full": + id = `${node.namespace || DefaultNamespace}${NamespacePathSep}${path6}`; + break; + case "short": + id = node.namespace && node.namespace !== DefaultNamespace ? `${node.namespace}${NamespacePathSep}${path6}` : path6; + break; + } + return includesTagPrefix && node.isTag ? `${TagPrefix}${id}` : id; + } + ResourceLocationNode2.toString = toString; +})(ResourceLocationNode || (ResourceLocationNode = {})); + +// node_modules/@spyglassmc/core/lib/node/Sequence.js +var SequenceUtilDiscriminator = Symbol("SequenceUtilDiscriminator"); +var SequenceUtil; +(function(SequenceUtil2) { + function is(obj) { + return !!obj && obj[SequenceUtilDiscriminator]; + } + SequenceUtil2.is = is; +})(SequenceUtil || (SequenceUtil = {})); + +// node_modules/@spyglassmc/core/lib/node/StringNode.js +var EscapeChar; +(function(EscapeChar2) { + function is(expected, c) { + return expected ? expected.includes(c) : false; + } + EscapeChar2.is = is; +})(EscapeChar || (EscapeChar = {})); +var EscapeTable = /* @__PURE__ */ new Map([ + ['"', '"'], + ["'", "'"], + ["\\", "\\"], + ["b", "\b"], + ["f", "\f"], + ["n", "\n"], + ["r", "\r"], + ["s", " "], + ["t", " "] +]); +var StringBaseNode; +(function(StringBaseNode2) { + function is(obj) { + return Array.isArray(obj?.valueMap) && typeof obj?.options === "object"; + } + StringBaseNode2.is = is; +})(StringBaseNode || (StringBaseNode = {})); +var StringNode; +(function(StringNode2) { + function is(obj) { + return obj?.type === "string"; + } + StringNode2.is = is; + function mock(range3, options2) { + range3 = Range.get(range3); + return { + type: "string", + range: range3, + options: options2, + value: "", + valueMap: [{ inner: Range.create(0), outer: Range.create(range3.start) }] + }; + } + StringNode2.mock = mock; +})(StringNode || (StringNode = {})); + +// node_modules/@spyglassmc/core/lib/node/SymbolNode.js +var SymbolNode; +(function(SymbolNode2) { + function is(obj) { + return obj?.type === "symbol"; + } + SymbolNode2.is = is; + function mock(range3, options2) { + return { type: "symbol", range: Range.get(range3), options: options2, value: "" }; + } + SymbolNode2.mock = mock; +})(SymbolNode || (SymbolNode = {})); + +// node_modules/@spyglassmc/locales/lib/index.js +init_en(); + +// import("./locales/**/*.json") in node_modules/@spyglassmc/locales/lib/index.js +var globImport_locales_json = __glob({ + "./locales/de.json": () => Promise.resolve().then(() => (init_de(), de_exports)), + "./locales/en.json": () => Promise.resolve().then(() => (init_en(), en_exports)), + "./locales/es.json": () => Promise.resolve().then(() => (init_es(), es_exports)), + "./locales/fr.json": () => Promise.resolve().then(() => (init_fr(), fr_exports)), + "./locales/it.json": () => Promise.resolve().then(() => (init_it(), it_exports)), + "./locales/ja.json": () => Promise.resolve().then(() => (init_ja(), ja_exports)), + "./locales/pt-br.json": () => Promise.resolve().then(() => (init_pt_br(), pt_br_exports)), + "./locales/zh-cn.json": () => Promise.resolve().then(() => (init_zh_cn(), zh_cn_exports)), + "./locales/zh-tw.json": () => Promise.resolve().then(() => (init_zh_tw(), zh_tw_exports)) +}); + +// node_modules/@spyglassmc/locales/lib/index.js +var Locales = { en: en_default }; +var language = "en"; +function localize(key2, ...params) { + const value = Locales[language][key2] ?? Locales.en[key2]; + return _resolveLocalePlaceholders(value, params) ?? key2; +} +function localeQuote(content) { + return localize("punc.quote", content); +} +function _resolveLocalePlaceholders(val, params) { + return val?.replace(/%\d+%/g, (match) => { + const index4 = parseInt(match.slice(1, -1)); + let param = params[index4]; + if (typeof param !== "string" && param?.[Symbol.iterator]) { + param = arrayToMessage(param); + } + return `${param ?? match}`; + }); +} +function arrayToMessage(param, quoted = true, conjunction = "or") { + const getPart = (str) => quoted ? localeQuote(str) : str; + const arr = (typeof param === "string" ? [param] : Array.from(param)).map(getPart); + switch (arr.length) { + case 0: + return localize("nothing"); + case 1: + return arr[0]; + case 2: + return arr[0] + localize(`conjunction.${conjunction}_2`) + arr[1]; + default: + return `${arr.slice(0, -1).join(localize(`conjunction.${conjunction}_3+_1`))}${localize(`conjunction.${conjunction}_3+_2`)}${arr[arr.length - 1]}`; + } +} + +// node_modules/@spyglassmc/core/lib/parser/literal.js +function literal(...param) { + const options2 = getOptions(param); + return (src, ctx) => { + const ans = { type: "literal", range: Range.create(src), options: options2, value: "" }; + for (const expected of options2.pool) { + if (src.trySkip(expected)) { + ans.value = expected; + ans.range.end = src.cursor; + return ans; + } + } + ctx.err.report(localize("expected", options2.pool), ans); + return ans; + }; +} +function getOptions(param) { + let ans; + if (typeof param[0] === "object") { + ans = param[0]; + } else { + ans = { pool: param }; + } + ans.pool = ans.pool.sort((a, b) => b.length - a.length); + return ans; +} + +// node_modules/@spyglassmc/core/lib/symbol/Symbol.js +var import_rfdc2 = __toESM(require_rfdc(), 1); +var McdocCategories = Object.freeze(["mcdoc", "mcdoc/dispatcher"]); +var RegistryCategories = Object.freeze([ + "activity", + "armor_material", + // Removed + "attribute", + "attribute_type", + "block", + "block_entity_type", + "block_predicate_type", + "block_type", + "chunk_status", + "command_argument_type", + "consume_effect_type", + "creative_mode_tab", + "custom_stat", + "data_component_predicate_type", + "data_component_type", + "debug_subscription", + "decorated_pot_pattern", + "decorated_pot_patterns", + // Removed + "dialog_action_type", + "dialog_body_type", + "dialog_type", + "enchantment_effect_component_type", + "enchantment_entity_effect_type", + "enchantment_level_based_value_type", + "enchantment_location_based_effect_type", + "enchantment_provider_type", + "enchantment_value_effect_type", + "entity_sub_predicate_type", + "entity_type", + "environment_attribute", + "float_provider_type", + "fluid", + "game_event", + "game_rule", + "height_provider_type", + "incoming_rpc_methods", + "input_control_type", + "instrument", + "int_provider_type", + "item", + "item_sub_predicate_type", + // Removed + "loot_condition_type", + "loot_function_type", + "loot_nbt_provider_type", + "loot_number_provider_type", + "loot_pool_entry_type", + "loot_score_provider_type", + "map_decoration_type", + "memory_module_type", + "menu", + "mob_effect", + "motive", + // Removed + "number_format_type", + "outgoing_rpc_methods", + "particle_type", + "permission_check_type", + "permission_type", + "point_of_interest_type", + "pos_rule_test", + "position_source_type", + "potion", + "recipe_book_category", + "recipe_display", + "recipe_serializer", + "recipe_type", + "rule_block_entity_modifier", + "rule_test", + "schedule", + // Removed + "sensor_type", + "slot_display", + "slot_source_type", + "sound_event", + "spawn_condition_type", + "stat_type", + "test_environment_definition_type", + "test_function", + "test_instance_type", + "trigger_type", + "ticket_type", + "villager_profession", + "villager_type", + "worldgen/biome_source", + "worldgen/block_placer_type", + // Removed + "worldgen/block_state_provider_type", + "worldgen/carver", + "worldgen/chunk_generator", + "worldgen/decorator", + // Removed + "worldgen/density_function_type", + "worldgen/feature", + "worldgen/feature_size_type", + "worldgen/foliage_placer_type", + "worldgen/material_condition", + "worldgen/material_rule", + "worldgen/placement_modifier_type", + "worldgen/pool_alias_binding", + "worldgen/root_placer_type", + "worldgen/structure_feature", + // Removed + "worldgen/structure_piece", + "worldgen/structure_placement", + "worldgen/structure_pool_element", + "worldgen/structure_processor", + "worldgen/structure_type", + "worldgen/surface_builder", + // Removed + "worldgen/tree_decorator_type", + "worldgen/trunk_placer_type" +]); +var NormalFileCategories = Object.freeze([ + "advancement", + "banner_pattern", + "cat_variant", + "chat_type", + "chicken_variant", + "cow_variant", + "damage_type", + "dialog", + "dimension", + "dimension_type", + "enchantment", + "enchantment_provider", + "frog_variant", + "function", + "instrument", + "item_modifier", + "jukebox_song", + "loot_table", + "painting_variant", + "pig_variant", + "predicate", + "recipe", + "structure", + "sulfur_cube_archetype", + "test_environment", + "test_instance", + "timeline", + "trade_set", + "trial_spawner", + "trim_material", + "trim_pattern", + "villager_trade", + "wolf_sound_variant", + "wolf_variant", + "world_clock", + "zombie_nautilus_variant" +]); +var WorldgenFileCategories = Object.freeze([ + "worldgen/biome", + "worldgen/configured_carver", + "worldgen/configured_feature", + "worldgen/configured_structure_feature", + "worldgen/configured_surface_builder", + "worldgen/density_function", + "worldgen/flat_level_generator_preset", + "worldgen/multi_noise_biome_source_parameter_list", + "worldgen/noise", + "worldgen/noise_settings", + "worldgen/placed_feature", + "worldgen/processor_list", + "worldgen/structure", + "worldgen/structure_set", + "worldgen/template_pool", + "worldgen/world_preset" +]); +var TaggableResourceLocationCategories = Object.freeze([...NormalFileCategories, ...RegistryCategories, ...WorldgenFileCategories]); +var TaggableResourceLocationCategory; +(function(TaggableResourceLocationCategory2) { + function is(category) { + return TaggableResourceLocationCategories.includes(category); + } + TaggableResourceLocationCategory2.is = is; +})(TaggableResourceLocationCategory || (TaggableResourceLocationCategory = {})); +var TagFileCategories = Object.freeze(TaggableResourceLocationCategories.map((key2) => `tag/${key2}`)); +var DataFileCategories = Object.freeze([...NormalFileCategories, ...TagFileCategories, ...WorldgenFileCategories]); +var DataMiscCategories = Object.freeze([ + "attribute_modifier", + "bossbar", + "jigsaw_block_name", + "random_sequence", + "storage", + "stopwatch" +]); +var DatapackCategories = Object.freeze([ + "attribute_modifier_uuid", + "objective", + "player_uuid", + "score_holder", + "tag", + "team", + ...DataFileCategories, + ...DataMiscCategories +]); +var AssetsFileCategories = Object.freeze([ + "atlas", + "block_definition", + // blockstates + "equipment", + "font", + "font/ttf", + "font/otf", + "font/unihex", + "gpu_warnlist", + "item_definition", + // items + "lang", + "lang/deprecated", + "model", + "particle", + "post_effect", + "regional_compliancies", + "shader", + "shader/fragment", + "shader/vertex", + "sound", + "sounds", + // sounds.json + "texture", + "texture_meta", + // *.png.mcmeta + "waypoint_style" +]); +var AssetsMiscCategories = Object.freeze([ + "texture_slot", + "shader_target", + "translation_key" +]); +var ResourcepackCategories = Object.freeze([ + ...AssetsMiscCategories, + ...AssetsFileCategories +]); +var FileCategories = Object.freeze([...DataFileCategories, ...AssetsFileCategories]); +var AllCategories = Object.freeze([ + ...DatapackCategories, + ...ResourcepackCategories, + ...McdocCategories, + ...RegistryCategories +]); +var ResourceLocationCategories = Object.freeze([ + "mcdoc/dispatcher", + ...DataMiscCategories, + ...AssetsMiscCategories, + ...FileCategories, + ...RegistryCategories +]); +var ResourceLocationCategory; +(function(ResourceLocationCategory2) { + function is(category) { + return ResourceLocationCategories.includes(category); + } + ResourceLocationCategory2.is = is; +})(ResourceLocationCategory || (ResourceLocationCategory = {})); +var SymbolPath; +(function(SymbolPath2) { + function fromSymbol(symbol7) { + return symbol7 ? { category: symbol7.category, path: symbol7.path } : void 0; + } + SymbolPath2.fromSymbol = fromSymbol; + function toString(path6) { + return JSON.stringify({ category: path6.category, path: path6.path }); + } + SymbolPath2.toString = toString; + function fromString(value) { + return JSON.parse(value); + } + SymbolPath2.fromString = fromString; +})(SymbolPath || (SymbolPath = {})); +var SymbolUsageTypes = Object.freeze(["definition", "declaration", "implementation", "reference", "typeDefinition"]); +var SymbolUsageType; +(function(SymbolUsageType2) { + function is(value) { + return SymbolUsageTypes.includes(value); + } + SymbolUsageType2.is = is; +})(SymbolUsageType || (SymbolUsageType = {})); +var Symbol2; +(function(Symbol3) { + function get(table, category, ...path6) { + if (isIterable(table)) { + for (const t of table) { + const result = get(t, category, ...path6); + if (result) { + return result; + } + } + return void 0; + } + const map3 = table[category]; + for (const p of path6) { + } + return void 0; + } + Symbol3.get = get; +})(Symbol2 || (Symbol2 = {})); +var SymbolLocation; +(function(SymbolLocation2) { + function create(doc, range3, fullRange, contributor, additional) { + return { + ...Location.create(doc, range3), + ...fullRange ? { fullRange: Range.get(fullRange), fullPosRange: PositionRange.from(fullRange, doc) } : {}, + ...contributor ? { contributor } : {}, + ...additional ? additional : {} + }; + } + SymbolLocation2.create = create; +})(SymbolLocation || (SymbolLocation = {})); +var SymbolTable; +(function(SymbolTable2) { + function link(table) { + const linkSymbol = (symbol7, parentMap, parentSymbol, category, path6) => { + symbol7.category = category; + symbol7.identifier = path6[path6.length - 1]; + symbol7.path = path6; + symbol7.parentMap = parentMap; + if (parentSymbol) { + symbol7.parentSymbol = parentSymbol; + } + if (symbol7.members) { + linkSymbolMap(symbol7.members, symbol7, category, path6); + } + }; + const linkSymbolMap = (map3, parentSymbol, category, path6) => { + for (const [identifier4, childSymbol] of Object.entries(map3)) { + linkSymbol(childSymbol, map3, parentSymbol, category, [...path6, identifier4]); + } + }; + const ans = (0, import_rfdc2.default)()(table); + for (const [category, map3] of Object.entries(ans)) { + linkSymbolMap(map3, void 0, category, []); + } + return ans; + } + SymbolTable2.link = link; + function unlink(table) { + const unlinkSymbol = (symbol7) => { + delete symbol7.category; + delete symbol7.identifier; + delete symbol7.parentMap; + delete symbol7.parentSymbol; + delete symbol7.path; + if (symbol7.members) { + unlinkSymbolMap(symbol7.members); + } + }; + const unlinkSymbolMap = (map3) => { + for (const childSymbol of Object.values(map3)) { + unlinkSymbol(childSymbol); + } + }; + const ans = (0, import_rfdc2.default)({ circles: true })(table); + for (const map3 of Object.values(ans)) { + unlinkSymbolMap(map3); + } + return ans; + } + SymbolTable2.unlink = unlink; + function serialize(table) { + return JSON.stringify(unlink(table), bigintJsonLosslessReplacer); + } + SymbolTable2.serialize = serialize; + function deserialize(json) { + return link(JSON.parse(json, bigintJsonLosslessReviver)); + } + SymbolTable2.deserialize = deserialize; +})(SymbolTable || (SymbolTable = {})); + +// node_modules/vscode-languageserver-textdocument/lib/esm/main.js +var FullTextDocument = class _FullTextDocument { + constructor(uri, languageId, version, content) { + this._uri = uri; + this._languageId = languageId; + this._version = version; + this._content = content; + this._lineOffsets = void 0; + } + get uri() { + return this._uri; + } + get languageId() { + return this._languageId; + } + get version() { + return this._version; + } + getText(range3) { + if (range3) { + const start = this.offsetAt(range3.start); + const end = this.offsetAt(range3.end); + return this._content.substring(start, end); + } + return this._content; + } + update(changes, version) { + for (const change of changes) { + if (_FullTextDocument.isIncremental(change)) { + const range3 = getWellformedRange(change.range); + const startOffset = this.offsetAt(range3.start); + const endOffset = this.offsetAt(range3.end); + this._content = this._content.substring(0, startOffset) + change.text + this._content.substring(endOffset, this._content.length); + const startLine = Math.max(range3.start.line, 0); + const endLine = Math.max(range3.end.line, 0); + let lineOffsets = this._lineOffsets; + const addedLineOffsets = computeLineOffsets(change.text, false, startOffset); + if (endLine - startLine === addedLineOffsets.length) { + for (let i = 0, len = addedLineOffsets.length; i < len; i++) { + lineOffsets[i + startLine + 1] = addedLineOffsets[i]; + } + } else { + if (addedLineOffsets.length < 1e4) { + lineOffsets.splice(startLine + 1, endLine - startLine, ...addedLineOffsets); + } else { + this._lineOffsets = lineOffsets = lineOffsets.slice(0, startLine + 1).concat(addedLineOffsets, lineOffsets.slice(endLine + 1)); + } + } + const diff = change.text.length - (endOffset - startOffset); + if (diff !== 0) { + for (let i = startLine + 1 + addedLineOffsets.length, len = lineOffsets.length; i < len; i++) { + lineOffsets[i] = lineOffsets[i] + diff; + } + } + } else if (_FullTextDocument.isFull(change)) { + this._content = change.text; + this._lineOffsets = void 0; + } else { + throw new Error("Unknown change event received"); + } + } + this._version = version; + } + getLineOffsets() { + if (this._lineOffsets === void 0) { + this._lineOffsets = computeLineOffsets(this._content, true); + } + return this._lineOffsets; + } + positionAt(offset) { + offset = Math.max(Math.min(offset, this._content.length), 0); + const lineOffsets = this.getLineOffsets(); + let low = 0, high = lineOffsets.length; + if (high === 0) { + return { line: 0, character: offset }; + } + while (low < high) { + const mid = Math.floor((low + high) / 2); + if (lineOffsets[mid] > offset) { + high = mid; + } else { + low = mid + 1; + } + } + const line = low - 1; + offset = this.ensureBeforeEOL(offset, lineOffsets[line]); + return { line, character: offset - lineOffsets[line] }; + } + offsetAt(position) { + const lineOffsets = this.getLineOffsets(); + if (position.line >= lineOffsets.length) { + return this._content.length; + } else if (position.line < 0) { + return 0; + } + const lineOffset = lineOffsets[position.line]; + if (position.character <= 0) { + return lineOffset; + } + const nextLineOffset = position.line + 1 < lineOffsets.length ? lineOffsets[position.line + 1] : this._content.length; + const offset = Math.min(lineOffset + position.character, nextLineOffset); + return this.ensureBeforeEOL(offset, lineOffset); + } + ensureBeforeEOL(offset, lineOffset) { + while (offset > lineOffset && isEOL(this._content.charCodeAt(offset - 1))) { + offset--; + } + return offset; + } + get lineCount() { + return this.getLineOffsets().length; + } + static isIncremental(event) { + const candidate = event; + return candidate !== void 0 && candidate !== null && typeof candidate.text === "string" && candidate.range !== void 0 && (candidate.rangeLength === void 0 || typeof candidate.rangeLength === "number"); + } + static isFull(event) { + const candidate = event; + return candidate !== void 0 && candidate !== null && typeof candidate.text === "string" && candidate.range === void 0 && candidate.rangeLength === void 0; + } +}; +var TextDocument; +(function(TextDocument2) { + function create(uri, languageId, version, content) { + return new FullTextDocument(uri, languageId, version, content); + } + TextDocument2.create = create; + function update(document2, changes, version) { + if (document2 instanceof FullTextDocument) { + document2.update(changes, version); + return document2; + } else { + throw new Error("TextDocument.update: document must be created by TextDocument.create"); + } + } + TextDocument2.update = update; + function applyEdits(document2, edits) { + const text = document2.getText(); + const sortedEdits = mergeSort(edits.map(getWellformedEdit), (a, b) => { + const diff = a.range.start.line - b.range.start.line; + if (diff === 0) { + return a.range.start.character - b.range.start.character; + } + return diff; + }); + let lastModifiedOffset = 0; + const spans = []; + for (const e of sortedEdits) { + const startOffset = document2.offsetAt(e.range.start); + if (startOffset < lastModifiedOffset) { + throw new Error("Overlapping edit"); + } else if (startOffset > lastModifiedOffset) { + spans.push(text.substring(lastModifiedOffset, startOffset)); + } + if (e.newText.length) { + spans.push(e.newText); + } + lastModifiedOffset = document2.offsetAt(e.range.end); + } + spans.push(text.substr(lastModifiedOffset)); + return spans.join(""); + } + TextDocument2.applyEdits = applyEdits; +})(TextDocument || (TextDocument = {})); +function mergeSort(data, compare) { + if (data.length <= 1) { + return data; + } + const p = data.length / 2 | 0; + const left = data.slice(0, p); + const right = data.slice(p); + mergeSort(left, compare); + mergeSort(right, compare); + let leftIdx = 0; + let rightIdx = 0; + let i = 0; + while (leftIdx < left.length && rightIdx < right.length) { + const ret = compare(left[leftIdx], right[rightIdx]); + if (ret <= 0) { + data[i++] = left[leftIdx++]; + } else { + data[i++] = right[rightIdx++]; + } + } + while (leftIdx < left.length) { + data[i++] = left[leftIdx++]; + } + while (rightIdx < right.length) { + data[i++] = right[rightIdx++]; + } + return data; +} +function computeLineOffsets(text, isAtLineStart, textOffset = 0) { + const result = isAtLineStart ? [textOffset] : []; + for (let i = 0; i < text.length; i++) { + const ch = text.charCodeAt(i); + if (isEOL(ch)) { + if (ch === 13 && i + 1 < text.length && text.charCodeAt(i + 1) === 10) { + i++; + } + result.push(textOffset + i + 1); + } + } + return result; +} +function isEOL(char) { + return char === 13 || char === 10; +} +function getWellformedRange(range3) { + const start = range3.start; + const end = range3.end; + if (start.line > end.line || start.line === end.line && start.character > end.character) { + return { start: end, end: start }; + } + return range3; +} +function getWellformedEdit(textEdit) { + const range3 = getWellformedRange(textEdit.range); + if (range3 !== textEdit.range) { + return { newText: textEdit.newText, range: range3 }; + } + return textEdit; +} + +// node_modules/@spyglassmc/core/lib/symbol/SymbolUtil.js +var __decorate = function(decorators, target, key2, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key2) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key2, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key2, r) : d(target, key2)) || r; + return c > 3 && r && Object.defineProperty(target, key2, r), r; +}; +var SymbolUtil = class _SymbolUtil extends EventDispatcher { + #global; + #trimmableSymbols = /* @__PURE__ */ new Set(); + #cache = /* @__PURE__ */ Object.create(null); + #currentContributor; + /** + * @internal + */ + _delayedOps = []; + /** + * @internal + */ + _inDelayMode; + get global() { + return this.#global; + } + constructor(global2, _currentContributor, _inDelayMode = false) { + super(); + this.#global = global2; + this.#currentContributor = _currentContributor; + this._inDelayMode = _inDelayMode; + this.on("symbolCreated", ({ symbol: symbol7 }) => { + this.#trimmableSymbols.add(SymbolPath.toString(symbol7)); + }).on("symbolRemoved", ({ symbol: symbol7 }) => { + this.#trimmableSymbols.delete(SymbolPath.toString(symbol7)); + }).on("symbolLocationCreated", ({ symbol: symbol7, location }) => { + const cache = this.#cache[location.contributor ?? "undefined"] ??= /* @__PURE__ */ Object.create(null); + const fileSymbols = cache[location.uri] ??= /* @__PURE__ */ new Set(); + const path6 = SymbolPath.toString(symbol7); + fileSymbols.add(path6); + this.#trimmableSymbols.delete(path6); + }).on("symbolLocationRemoved", ({ symbol: symbol7 }) => { + const path6 = SymbolPath.toString(symbol7); + this.#trimmableSymbols.add(path6); + }); + } + /** + * Build the internal cache of the SymbolUtil according to the current global symbol table. + */ + buildCache() { + _SymbolUtil.forEachSymbol(this.global, (symbol7) => { + this.emit("symbolCreated", { symbol: symbol7 }); + _SymbolUtil.forEachLocationOfSymbol(symbol7, ({ type: type2, location }) => { + this.emit("symbolLocationCreated", { symbol: symbol7, type: type2, location }); + }); + }); + } + /** + * @returns A clone of this SymbolUtil that is in delay mode: changes to the symbol table happened in the clone will + * not take effect until the {@link SymbolUtil.applyDelayedEdits} method is called on that clone. + * + * The clone shares the same reference of the global symbol table and symbol stacks, meaning that after + * `applyDelayedEdits` is called, the original SymbolUtil will also be modified. + */ + clone() { + return new _SymbolUtil(this.#global, this.#currentContributor, true); + } + /** + * Apply edits done during the delay mode. + */ + applyDelayedEdits() { + this._delayedOps.forEach((f) => f()); + this._delayedOps = []; + this._inDelayMode = false; + } + contributeAs(contributor, fn) { + const originalValue = this.#currentContributor; + this.#currentContributor = contributor; + try { + fn(); + } finally { + this.#currentContributor = originalValue; + } + return this; + } + async contributeAsAsync(contributor, fn) { + const originalValue = this.#currentContributor; + this.#currentContributor = contributor; + try { + await fn(); + } finally { + this.#currentContributor = originalValue; + } + return this; + } + /** + * @param + * - `contributor` - clear symbol locations contributed by this contributor. Pass in `undefined` + * to select all symbol locations that don't have a contributor. + * - `uri` - clear symbol locations associated with this URI. + * - `predicate` - clear symbol locations matching this predicate + */ + clear({ uri, contributor, predicate = () => true }) { + const getCaches = () => { + if (contributor) { + return this.#cache[contributor] ? [this.#cache[contributor]] : []; + } else { + return Object.values(this.#cache); + } + }; + const getPaths = () => { + const caches = getCaches(); + const sets = uri ? caches.map((cache) => cache[uri] ?? /* @__PURE__ */ new Set()) : caches.map((cache) => Object.values(cache)).flat(); + return sets.map((s) => [...s]).flat().map(SymbolPath.fromString); + }; + const getTables = () => { + return uri ? [this.#global] : [this.#global]; + }; + const paths = getPaths(); + const tables = getTables(); + for (const table of tables) { + for (const path6 of paths) { + const { symbol: symbol7 } = _SymbolUtil.lookupTable(table, path6.category, path6.path); + if (!symbol7) { + continue; + } + this.removeLocationsFromSymbol(symbol7, (data) => (!uri || data.location.uri === uri) && (!contributor || data.location.contributor === contributor) && predicate(data)); + } + this.trim(table); + } + } + lookup(category, path6, node) { + while (node) { + if (node.locals) { + const result = _SymbolUtil.lookupTable(node.locals, category, path6); + if (result.symbol) { + return result; + } + } + node = node.parent; + } + return _SymbolUtil.lookupTable(this.global, category, path6); + } + query(doc, category, ...path6) { + const uri = _SymbolUtil.toUri(doc); + const { parentSymbol, parentMap, symbol: symbol7 } = this.lookup(category, path6, isDocAndNode(doc) ? doc.node : void 0); + const visible = symbol7 ? _SymbolUtil.isVisible(symbol7, uri) : true; + return new SymbolQuery({ + category, + doc, + contributor: this.#currentContributor, + map: visible ? parentMap : void 0, + parentSymbol, + path: path6, + symbol: visible ? symbol7 : void 0, + util: this + }); + } + getVisibleSymbols(category, uri) { + const map3 = this.lookup(category, [], void 0).parentMap ?? void 0; + return _SymbolUtil.filterVisibleSymbols(uri, map3); + } + static toUri(uri) { + if (typeof uri === "string") { + return uri; + } + if (isDocAndNode(uri)) { + return uri.doc.uri; + } + return uri.uri; + } + /** + * @see {@link SymbolUtil.trimMap} + */ + trim(table) { + const trimSymbol = (symbol7) => { + if (!symbol7) { + return; + } + if (_SymbolUtil.isTrimmable(symbol7)) { + delete symbol7.parentMap[symbol7.identifier]; + this.emit("symbolRemoved", { symbol: symbol7 }); + trimSymbol(symbol7.parentSymbol); + } + }; + for (const pathString of this.#trimmableSymbols) { + const path6 = SymbolPath.fromString(pathString); + const { symbol: symbol7 } = _SymbolUtil.lookupTable(table, path6.category, path6.path); + trimSymbol(symbol7); + } + } + removeLocationsFromSymbol(symbol7, predicate) { + for (const type2 of SymbolUsageTypes) { + if (!symbol7[type2]) { + continue; + } + symbol7[type2] = symbol7[type2].reduce((result, location) => { + if (predicate({ location, symbol: symbol7, type: type2 })) { + this.emit("symbolLocationRemoved", { symbol: symbol7, type: type2, location }); + } else { + result.push(location); + } + return result; + }, []); + } + } + enterMap(parentSymbol, map3, category, path6, identifier4, addition, doc, contributor) { + let ans = map3[identifier4]; + if (ans) { + this.amendSymbol(ans, addition, doc, contributor); + } else { + ans = this.createSymbol(category, parentSymbol, map3, path6, identifier4, addition, doc, contributor); + } + this.emit("symbolAmended", { symbol: ans }); + return ans; + } + static lookupTable(table, category, path6) { + let parentMap = table[category]; + let parentSymbol; + let symbol7; + for (let i = 0; i < path6.length; i++) { + symbol7 = parentMap?.[path6[i]]; + if (!symbol7) { + if (i !== path6.length - 1) { + parentSymbol = void 0; + parentMap = void 0; + } + break; + } + if (i === path6.length - 1) { + break; + } + parentSymbol = symbol7; + parentMap = symbol7.members; + } + return { parentSymbol, parentMap, symbol: symbol7 }; + } + static lookupTables(tables, category, path6) { + let parentMap; + let parentSymbol; + for (let i = tables.length - 1; i >= 0; i--) { + const table = tables[i]; + const result = this.lookupTable(table, category, path6); + if (result.symbol) { + return result; + } + if (!parentSymbol && !parentMap && (result.parentSymbol || result.parentMap)) { + parentSymbol = result.parentSymbol; + parentMap = result.parentMap; + } + } + return { parentSymbol, parentMap, symbol: void 0 }; + } + createSymbol(category, parentSymbol, parentMap, path6, identifier4, addition, doc, contributor) { + const ans = parentMap[identifier4] = { + category, + identifier: identifier4, + ...parentSymbol ? { parentSymbol } : {}, + parentMap, + path: path6, + ...addition.data + }; + this.emit("symbolCreated", { symbol: ans }); + this.amendSymbolUsage(ans, addition.usage, doc, contributor); + return ans; + } + amendSymbol(symbol7, addition, doc, contributor) { + this.amendSymbolMetadata(symbol7, addition.data); + this.amendSymbolUsage(symbol7, addition.usage, doc, contributor); + } + amendSymbolMetadata(symbol7, addition) { + if (addition) { + if ("data" in addition) { + symbol7.data = addition.data; + } + if ("desc" in addition) { + symbol7.desc = addition.desc; + } + if (addition.relations && Object.keys(addition.relations).length) { + symbol7.relations ??= {}; + for (const relationship of Object.keys(addition.relations)) { + symbol7.relations[relationship] = addition.relations[relationship]; + } + } + if ("subcategory" in addition) { + symbol7.subcategory = addition.subcategory; + } + if ("visibility" in addition) { + const inGlobalTable = (v) => v === void 0 || v === 2 || v === 3; + if (symbol7.visibility === addition.visibility || inGlobalTable(symbol7.visibility) && inGlobalTable(addition.visibility)) { + symbol7.visibility = addition.visibility; + } else { + throw new Error(`Cannot change visibility from ${symbol7.visibility} to ${addition.visibility}: ${JSON.stringify(SymbolPath.fromSymbol(symbol7))}`); + } + } + if (addition.visibilityRestriction?.length) { + symbol7.visibilityRestriction = (symbol7.visibilityRestriction ?? []).concat(addition.visibilityRestriction); + } + } + } + amendSymbolUsage(symbol7, addition, doc, contributor) { + if (addition) { + const type2 = addition.type ?? "reference"; + const arr = symbol7[type2] ??= []; + const range3 = Range.get((SymbolAdditionUsageWithNode.is(addition) ? addition.node : addition.range) ?? 0); + const location = SymbolLocation.create(doc, range3, addition.fullRange, contributor, { + accessType: addition.accessType, + skipRenaming: addition.skipRenaming + }); + if (!doc.uri.startsWith("file:")) { + delete location.range; + delete location.posRange; + delete location.fullRange; + delete location.fullPosRange; + } + arr.push(location); + this.emit("symbolLocationCreated", { symbol: symbol7, type: type2, location }); + } + } + /** + * @returns The ultimate symbol being pointed by the passed-in `symbol`'s alias. + */ + resolveAlias(symbol7) { + return symbol7?.relations?.aliasOf ? this.resolveAlias(this.lookup(symbol7.relations.aliasOf.category, symbol7.relations.aliasOf.path).symbol) : symbol7; + } + static filterVisibleSymbols(uri, map3 = {}) { + const ans = {}; + for (const [identifier4, symbol7] of Object.entries(map3)) { + if (_SymbolUtil.isVisible(symbol7, uri)) { + ans[identifier4] = symbol7; + } + } + return ans; + } + static isTrimmable(symbol7) { + return !Object.keys(symbol7.members ?? {}).length && !symbol7.declaration?.length && !symbol7.definition?.length && !symbol7.implementation?.length && !symbol7.reference?.length && !symbol7.typeDefinition?.length; + } + static isVisible(symbol7, _uri) { + switch (symbol7.visibility) { + case 3: + return false; + // FIXME: check with workspace root URIs. + case 0: + case 1: + case 2: + default: + return true; + } + } + /** + * @returns If the symbol has declarations or definitions. + */ + static isDeclared(symbol7) { + return !!(symbol7?.declaration?.length || symbol7?.definition?.length); + } + /** + * @returns If the symbol has definitions, or declarations and implementations. + */ + static isDefined(symbol7) { + return !!(symbol7?.definition?.length || symbol7?.definition?.length && symbol7?.implementation?.length); + } + /** + * @returns If the symbol has implementations or definitions. + */ + static isImplemented(symbol7) { + return !!(symbol7?.implementation?.length || symbol7?.definition?.length); + } + /** + * @returns If the symbol has references. + */ + static isReferenced(symbol7) { + return !!symbol7?.reference?.length; + } + /** + * @returns If the symbol has type definitions. + */ + static isTypeDefined(symbol7) { + return !!symbol7?.typeDefinition?.length; + } + /** + * @throws If the symbol does not have any declarations or definitions. + */ + static getDeclaredLocation(symbol7) { + return symbol7.declaration?.[0] ?? symbol7.definition?.[0] ?? (() => { + throw new Error(`Cannot get declared location of ${JSON.stringify(SymbolPath.fromSymbol(symbol7))}`); + })(); + } + static forEachSymbolInMap(map3, fn) { + for (const symbol7 of Object.values(map3)) { + fn(symbol7); + if (symbol7.members) { + this.forEachSymbolInMap(symbol7.members, fn); + } + } + } + static forEachSymbol(table, fn) { + for (const map3 of Object.values(table)) { + this.forEachSymbolInMap(map3, fn); + } + } + static forEachLocationOfSymbol(symbol7, fn) { + for (const type2 of SymbolUsageTypes) { + symbol7[type2]?.forEach((location) => fn({ type: type2, location })); + } + } + static isVisibilityInGlobal(v) { + return v === void 0 || v === 2 || v === 3; + } + static areVisibilitiesCompatible(v1, v2) { + return this.isVisibilityInGlobal(v1) && this.isVisibilityInGlobal(v2) || v1 === 0 && v2 === 0 || v1 === 1 && v2 === 1; + } +}; +__decorate([ + DelayModeSupport() +], SymbolUtil.prototype, "clear", null); +__decorate([ + DelayModeSupport() +], SymbolUtil.prototype, "trim", null); +__decorate([ + DelayModeSupport() +], SymbolUtil.prototype, "removeLocationsFromSymbol", null); +var SymbolAdditionUsageWithRange; +(function(SymbolAdditionUsageWithRange2) { + function is(usage) { + return !!usage?.range; + } + SymbolAdditionUsageWithRange2.is = is; +})(SymbolAdditionUsageWithRange || (SymbolAdditionUsageWithRange = {})); +var SymbolAdditionUsageWithNode; +(function(SymbolAdditionUsageWithNode2) { + function is(usage) { + return !!usage?.node; + } + SymbolAdditionUsageWithNode2.is = is; +})(SymbolAdditionUsageWithNode || (SymbolAdditionUsageWithNode = {})); +var SymbolQuery = class _SymbolQuery { + category; + path; + #doc; + #node; + /** + * If only a string URI (instead of a {@link TextDocument}) is provided when constructing this class. + * + * If this is `true`, {@link SymbolAdditionUsageWithRange.range} is ignored and treated as `[0, 0)` when entering symbols through this class. + */ + #createdWithUri; + #currentContributor; + #hasTriggeredIf = false; + /** + * The map where the queried symbol is stored. `undefined` if the map hasn't been created yet. + */ + #map; + #parentSymbol; + /** + * The queried symbol. `undefined` if the symbol hasn't been created yet. + */ + #symbol; + /** + * The {@link SymbolUtil} where this query was created. + */ + util; + get symbol() { + return this.#symbol; + } + get visibleMembers() { + return SymbolUtil.filterVisibleSymbols(this.#doc.uri, this.path.length === 0 ? this.#map : this.#symbol?.members); + } + constructor({ category, contributor, doc, map: map3, parentSymbol, path: path6, symbol: symbol7, util }) { + this.category = category; + this.path = path6; + if (typeof doc === "string") { + doc = TextDocument.create(doc, "", 0, ""); + this.#createdWithUri = true; + } else if (isDocAndNode(doc)) { + this.#node = doc.node; + doc = doc.doc; + } + this.#doc = doc; + this.#currentContributor = contributor; + this.#map = map3; + this.#parentSymbol = parentSymbol; + this.#symbol = symbol7; + this.util = util; + } + heyGimmeDaSymbol() { + return this.#symbol; + } + getData(predicate) { + const data = this.#symbol?.data; + return predicate(data) ? data : void 0; + } + with(fn) { + fn(this); + return this; + } + if(predicate, fn) { + if (predicate.call(this, this.#symbol, this)) { + fn.call(this, this.#symbol, this); + this.#hasTriggeredIf = true; + } + return this; + } + /** + * Calls `fn` if the queried symbol does not exist. + */ + ifUnknown(fn) { + return this.if((s) => s === void 0, fn); + } + /** + * Calls `fn` if the queried symbol exists (i.e. has any of declarations/definitions/implementations/references/typeDefinitions). + */ + ifKnown(fn) { + return this.if((s) => s !== void 0, fn); + } + /** + * Calls `fn` if the queried symbol has declarations or definitions. + */ + ifDeclared(fn) { + return this.if((s) => SymbolUtil.isDeclared(s), fn); + } + /** + * Calls `fn` if the queried symbol has definitions, or both declarations and implementations. + */ + ifDefined(fn) { + return this.if(SymbolUtil.isDefined, fn); + } + /** + * Calls `fn` if the queried symbol has implementations or definitions. + */ + ifImplemented(fn) { + return this.if(SymbolUtil.isImplemented, fn); + } + /** + * Calls `fn` if the queried symbol has references. + */ + ifReferenced(fn) { + return this.if(SymbolUtil.isReferenced, fn); + } + /** + * Calls `fn` if the queried symbol has type definitions. + */ + ifTypeDefined(fn) { + return this.if(SymbolUtil.isTypeDefined, fn); + } + /** + * Calls `fn` if none of the former `if` conditions are met. + */ + else(fn) { + if (!this.#hasTriggeredIf) { + fn.call(this, this.#symbol, this); + } + return this; + } + /** + * Enters the queried symbol if none of the former `if` conditions are met. + */ + elseEnter(symbol7) { + return this.else(() => this.enter(symbol7)); + } + /** + * Resolves the queried symbol if it is an alias and if none of the former `if` conditions are met. + * + * @throws If the current symbol points to an non-existent symbol. + */ + elseResolveAlias() { + return this.else(() => this.resolveAlias()); + } + _enter(addition) { + const getAdditionVisibility = (addition2) => { + return addition2.data?.visibility ?? this.symbol?.visibility ?? 2; + }; + const getMap = (addition2) => { + const additionVisibility = getAdditionVisibility(addition2); + if (this.#map && SymbolUtil.areVisibilitiesCompatible(additionVisibility, this.#symbol?.visibility)) { + return this.#map; + } + if (this.path.length > 1) { + if (this.#parentSymbol) { + if (!SymbolUtil.areVisibilitiesCompatible(additionVisibility, this.#parentSymbol.visibility)) { + throw new Error(`Cannot enter member \u201C${this.getPath()}\u201D of ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility to parent of ${SymbolFormatter.stringifyVisibility(this.#parentSymbol.visibility)} visibility`); + } + return this.#parentSymbol.members ??= {}; + } + } else { + let table; + if (SymbolUtil.isVisibilityInGlobal(additionVisibility)) { + table = this.util.global; + } else if (additionVisibility === 1) { + if (!this.#node) { + throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node is supplied`); + } + let node = this.#node; + while (node) { + if (node.type === "file") { + table = node.locals; + break; + } + node = node.parent; + } + if (!table) { + throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no file node is supplied`); + } + } else { + if (!this.#node) { + throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node is supplied`); + } + let node = this.#node; + while (node) { + if (node.locals) { + table = node.locals; + break; + } + node = node.parent; + } + if (!table) { + throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node with locals is supplied`); + } + } + return table[this.category] ??= {}; + } + throw new Error(`Cannot create the symbol map for \u201C${this.getPath()}\u201D`); + }; + if (this.#createdWithUri && SymbolAdditionUsageWithRange.is(addition.usage)) { + addition.usage.range = Range.create(0, 0); + } + this.#map = getMap(addition); + this.#symbol = this.util.enterMap(this.#parentSymbol, this.#map, this.category, this.path, this.path[this.path.length - 1], addition, this.#doc, this.#currentContributor); + if (addition.usage?.node) { + addition.usage.node.symbol = this.#symbol; + } + } + /** + * Enters the queried symbol. + * + * @throws If the parent of this symbol doesn't exist either. + */ + enter(addition) { + this._enter(addition); + return this; + } + /** + * Amends the queried symbol if the queried symbol exists (i.e. has any of declarations/definitions/implementations/references/typeDefinitions) and is visible at the current scope. + * + * This is equivalent to calling + * ```typescript + * query.ifKnown(function () { + * this.enter(symbol) + * }) + * ``` + * + * Therefore, if the symbol is successfully amended, `elseX` methods afterwards will **not** be executed. + */ + amend(symbol7) { + return this.ifKnown(() => this.enter(symbol7)); + } + /** + * Resolves this symbol if it exists and is an alias. + * + * @throws If the current symbol points to an non-existent symbol. The state of this object will not be changed + * after the error is thrown. + */ + resolveAlias() { + if (this.#symbol) { + const result = this.util.resolveAlias(this.#symbol); + if (!result) { + throw new Error("The current symbol points to an non-existent symbol."); + } + this.#symbol = result; + this.#map = result.parentMap; + this.#parentSymbol = result.parentSymbol; + this.path = result.path; + } + return this; + } + member() { + let doc, identifier4, fn; + if (arguments.length === 2) { + doc = this.#createdWithUri ? this.#doc.uri : this.#doc; + identifier4 = arguments[0]; + fn = arguments[1]; + } else { + doc = arguments[0]; + identifier4 = arguments[1]; + fn = arguments[2]; + } + if (this.#symbol === void 0) { + throw new Error(`Tried to query member symbol \u201C${identifier4}\u201D from an undefined symbol (path \u201C${this.path.join(".")}\u201D)`); + } + const memberDoc = typeof doc === "string" && doc === this.#doc.uri && !this.#createdWithUri ? this.#doc : doc; + const memberMap = this.#symbol.members; + const memberSymbol = memberMap?.[identifier4]; + const memberQueryResult = new _SymbolQuery({ + category: this.category, + doc: memberDoc, + contributor: this.#currentContributor, + map: memberMap, + parentSymbol: this.#symbol, + path: [...this.path, identifier4], + symbol: memberSymbol, + util: this.util + }); + fn(memberQueryResult); + return this; + } + /** + * Do something with this query on each value in a given iterable. The query itself will be included + * in the callback function as the second parameter. + */ + onEach(values, fn) { + for (const value of values) { + fn.call(this, value, this); + } + return this; + } + forEachMember(fn) { + return this.onEach(Object.keys(this.visibleMembers), (identifier4) => this.member(identifier4, (query) => fn(identifier4, query))); + } + getPath() { + return `${this.category}.${this.path.join("/")}`; + } +}; +__decorate([ + DelayModeSupport((self2) => self2.util) +], SymbolQuery.prototype, "_enter", null); +var SymbolFormatter; +(function(SymbolFormatter2) { + const IndentChar = "+ "; + function assertEqual(a, b) { + if (a !== b) { + throw new Error(`Assertion error: ${a} !== ${b}`); + } + } + function stringifySymbolStack(stack) { + return stack.map((table) => stringifySymbolTable(table)).join("\n------------\n"); + } + SymbolFormatter2.stringifySymbolStack = stringifySymbolStack; + function stringifySymbolTable(table, indent = "") { + const ans = []; + for (const category of Object.keys(table)) { + const map3 = table[category]; + ans.push([category, stringifySymbolMap(map3, `${indent}${IndentChar}`)]); + } + return ans.map((v) => `CATEGORY ${v[0]} +${v[1]}`).join(` +${indent}------------ +`) || "EMPTY TABLE"; + } + SymbolFormatter2.stringifySymbolTable = stringifySymbolTable; + function stringifySymbolMap(map3, indent = "") { + if (!map3) { + return "undefined"; + } + const ans = []; + for (const identifier4 of Object.keys(map3)) { + const symbol7 = map3[identifier4]; + assertEqual(identifier4, symbol7.identifier); + ans.push(stringifySymbol(symbol7, indent)); + } + return ans.join(` +${indent}------------ +`); + } + SymbolFormatter2.stringifySymbolMap = stringifySymbolMap; + function stringifySymbol(symbol7, indent = "") { + if (!symbol7) { + return "undefined"; + } + const ans = []; + assertEqual(symbol7.path[symbol7.path.length - 1], symbol7.identifier); + ans.push(`SYMBOL ${symbol7.path.join(".")} {${symbol7.category}${symbol7.subcategory ? ` (${symbol7.subcategory})` : ""}} [${stringifyVisibility(symbol7.visibility, symbol7.visibilityRestriction)}]`); + if (symbol7.data) { + ans.push(`${IndentChar}data: ${JSON.stringify(symbol7.data, bigintJsonNumberReplacer)}`); + } + if (symbol7.desc) { + ans.push(`${IndentChar}description: ${symbol7.desc}`); + } + for (const type2 of SymbolUsageTypes) { + if (symbol7[type2]) { + ans.push(`${IndentChar}${type2}: +${symbol7[type2].map((v) => `${indent}${IndentChar.repeat(2)}${JSON.stringify(v)}`).join(` +${indent}${IndentChar.repeat(2)}------------ +`)}`); + } + } + if (symbol7.relations) { + ans.push(`${IndentChar}relations: ${JSON.stringify(symbol7.relations)}`); + } + if (symbol7.members) { + ans.push(`${IndentChar}members: +${stringifySymbolMap(symbol7.members, `${indent}${IndentChar.repeat(2)}`)}`); + } + return ans.map((v) => `${indent}${v}`).join("\n"); + } + SymbolFormatter2.stringifySymbol = stringifySymbol; + function stringifyVisibility(visibility, visibilityRestriction) { + let stringVisibility; + switch (visibility) { + case 0: + stringVisibility = "Block"; + break; + case 1: + stringVisibility = "File"; + break; + case 3: + stringVisibility = "Restricted"; + break; + default: + stringVisibility = "Public"; + break; + } + return `${stringVisibility}${visibilityRestriction ? ` ${visibilityRestriction.map((v) => `\u201C${v}\u201D`).join(", ")}` : ""}`; + } + SymbolFormatter2.stringifyVisibility = stringifyVisibility; + function stringifyLookupResult(result) { + return `parentSymbol: +${stringifySymbol(result.parentSymbol, IndentChar)} +parentMap: +${stringifySymbolMap(result.parentMap, IndentChar)} +symbol: +${stringifySymbol(result.symbol, IndentChar)}`; + } + SymbolFormatter2.stringifyLookupResult = stringifyLookupResult; +})(SymbolFormatter || (SymbolFormatter = {})); +function DelayModeSupport(getUtil = (self2) => self2) { + return (_target, _key, descripter) => { + const decoratedMethod = descripter.value; + descripter.value = function(...args) { + const util = getUtil(this); + if (util._inDelayMode) { + util._delayedOps.push(decoratedMethod.bind(this, ...args)); + } else { + decoratedMethod.apply(this, args); + } + }; + return descripter; + }; +} +function isDocAndNode(doc) { + return !!doc.doc; +} + +// node_modules/@spyglassmc/core/lib/service/fileUtil.js +var fileUtil; +(function(fileUtil2) { + function getRelativeUriFromBase(target, base) { + const baseUri = new Uri(base); + const targetUri = new Uri(target); + if (baseUri.origin !== targetUri.origin) { + return void 0; + } + const baseComponents = baseUri.pathname.split("/").filter((v) => !!v); + const targetComponents = targetUri.pathname.split("/").filter((v) => !!v); + if (baseComponents.length > targetComponents.length || baseComponents.some((bc, i) => decodeURIComponent(bc) !== decodeURIComponent(targetComponents[i]))) { + return void 0; + } + return targetComponents.slice(baseComponents.length).map(encodeURIComponent).join("/"); + } + fileUtil2.getRelativeUriFromBase = getRelativeUriFromBase; + function isSubUriOf(uri, base) { + return getRelativeUriFromBase(uri, base) !== void 0; + } + fileUtil2.isSubUriOf = isSubUriOf; + function* getRels2(uri, rootUris) { + for (const root of rootUris) { + const rel = getRelativeUriFromBase(uri, root); + if (rel !== void 0) { + yield rel; + } + } + return void 0; + } + fileUtil2.getRels = getRels2; + function getRel(uri, rootUris) { + return getRels2(uri, rootUris).next().value; + } + fileUtil2.getRel = getRel; + function* getRoots2(uri, rootUris) { + for (const root of rootUris) { + const rel = getRelativeUriFromBase(uri, root); + if (rel !== void 0) { + yield root; + } + } + return void 0; + } + fileUtil2.getRoots = getRoots2; + function getRoot(uri, rootUris) { + return getRoots2(uri, rootUris).next().value; + } + fileUtil2.getRoot = getRoot; + function isRootUri(uri) { + return uri.endsWith("/"); + } + fileUtil2.isRootUri = isRootUri; + function ensureEndingSlash(uri) { + return isRootUri(uri) ? uri : `${uri}/`; + } + fileUtil2.ensureEndingSlash = ensureEndingSlash; + function trimEndingSlash(uri) { + return isRootUri(uri) ? uri.slice(0, -1) : uri; + } + fileUtil2.trimEndingSlash = trimEndingSlash; + function join2(fromUri, toUri) { + return ensureEndingSlash(fromUri) + (toUri.startsWith("/") ? toUri.slice(1) : toUri); + } + fileUtil2.join = join2; + function isFileUri(uri) { + return uri.startsWith("file:"); + } + fileUtil2.isFileUri = isFileUri; + function extname(value) { + const i = value.lastIndexOf("."); + return i >= 0 ? value.slice(i) : void 0; + } + fileUtil2.extname = extname; + function basename(uri) { + const i = uri.lastIndexOf("/"); + return i >= 0 ? uri.slice(i + 1) : uri; + } + fileUtil2.basename = basename; + function dirname(uri) { + const i = uri.lastIndexOf("/"); + return i >= 0 ? uri.slice(0, i) : uri; + } + fileUtil2.dirname = dirname; + function getParentOfUri(uri) { + return new Uri(".", trimEndingSlash(uri.toString())); + } + fileUtil2.getParentOfUri = getParentOfUri; + async function ensureDir(externals, path6, mode = 511) { + try { + await externals.fs.mkdir(path6, { mode, recursive: true }); + } catch (e) { + if (!externals.error.isKind(e, "EEXIST")) { + throw e; + } + } + } + fileUtil2.ensureDir = ensureDir; + async function ensureParentOfFile(externals, path6, mode = 511) { + return ensureDir(externals, getParentOfUri(path6), mode); + } + fileUtil2.ensureParentOfFile = ensureParentOfFile; + async function chmod(externals, path6, mode) { + return externals.fs.chmod(path6, mode); + } + fileUtil2.chmod = chmod; + async function ensureWritable(externals, path6) { + try { + await chmod(externals, path6, 438); + } catch (e) { + if (!externals.error.isKind(e, "ENOENT")) { + throw e; + } + } + } + fileUtil2.ensureWritable = ensureWritable; + async function getAllFiles(externals, root, depth = Number.POSITIVE_INFINITY) { + async function walk(path6, level) { + if (level > depth) { + return []; + } + const entries = await externals.fs.readdir(path6); + return (await Promise.all(entries.map(async (e) => { + const entryPath = fileUtil2.join(path6.toString(), e.name); + if (e.isDirectory()) { + return await walk(entryPath, level + 1); + } else if (e.isFile()) { + return entryPath; + } else { + return []; + } + }))).flat(); + } + return walk(root, 0); + } + fileUtil2.getAllFiles = getAllFiles; + async function markReadOnly(externals, path6) { + return chmod(externals, path6, 292); + } + fileUtil2.markReadOnly = markReadOnly; + async function unlink(externals, path6) { + return externals.fs.unlink(path6); + } + fileUtil2.unlink = unlink; + async function readFile(externals, path6) { + return externals.fs.readFile(path6); + } + fileUtil2.readFile = readFile; + async function writeFile(externals, path6, data, mode = 438) { + await ensureParentOfFile(externals, path6); + await ensureWritable(externals, path6); + return externals.fs.writeFile(path6, data, { mode }); + } + fileUtil2.writeFile = writeFile; + async function readJson(externals, path6) { + return JSON.parse(bufferToString(await readFile(externals, path6)), bigintJsonNumberReviver); + } + fileUtil2.readJson = readJson; + async function writeJson(externals, path6, data) { + return writeFile(externals, path6, JSON.stringify(data, bigintJsonNumberReplacer)); + } + fileUtil2.writeJson = writeJson; + async function readGzippedFile(externals, path6) { + return decompressBytes(await readFile(externals, path6), "gzip"); + } + fileUtil2.readGzippedFile = readGzippedFile; + async function writeGzippedFile(externals, path6, buffer) { + if (typeof buffer === "string") { + buffer = new TextEncoder().encode(buffer); + } + return writeFile(externals, path6, await compressBytes(buffer, "gzip")); + } + fileUtil2.writeGzippedFile = writeGzippedFile; + async function readGzippedJson(externals, path6, reviver) { + return JSON.parse(bufferToString(await readGzippedFile(externals, path6)), reviver ?? bigintJsonNumberReviver); + } + fileUtil2.readGzippedJson = readGzippedJson; + async function writeGzippedJson(externals, path6, data, replacer) { + return writeGzippedFile(externals, path6, JSON.stringify(data, replacer ?? bigintJsonNumberReplacer)); + } + fileUtil2.writeGzippedJson = writeGzippedJson; +})(fileUtil || (fileUtil = {})); + +// node_modules/@spyglassmc/core/lib/service/FileService.js +var FileService; +(function(FileService2) { + function create(externals, cacheRoot) { + const virtualUrisRoot = fileUtil.ensureEndingSlash(new Uri("virtual-uris/", cacheRoot).toString()); + return new FileServiceImpl(externals, virtualUrisRoot); + } + FileService2.create = create; +})(FileService || (FileService = {})); +var FileServiceImpl = class { + externals; + virtualUrisRoot; + supporters = /* @__PURE__ */ new Map(); + /** + * A two-way map from mapped physical URIs to virtual URIs. + */ + map = new TwoWayMap(); + constructor(externals, virtualUrisRoot) { + this.externals = externals; + this.virtualUrisRoot = virtualUrisRoot; + } + register(protocol, supporter, force = false) { + if (!force && this.supporters.has(protocol)) { + throw new Error(`The protocol \u201C${protocol}\u201D is already associated with another supporter.`); + } + this.supporters.set(protocol, supporter); + } + unregister(protocol) { + this.supporters.delete(protocol); + } + /** + * @throws If the protocol of `uri` isn't supported. + * + * @returns The protocol if it's supported. + */ + getSupportedProtocol(uri) { + const protocol = new Uri(uri).protocol; + if (!this.supporters.has(protocol)) { + throw new Error(`The protocol \u201C${protocol}\u201D is unsupported.`); + } + return protocol; + } + /** + * @throws + */ + async hash(uri) { + const protocol = this.getSupportedProtocol(uri); + return this.supporters.get(protocol).hash(uri); + } + /** + * @throws + */ + readFile(uri) { + const protocol = this.getSupportedProtocol(uri); + return this.supporters.get(protocol).readFile(uri); + } + *listFiles() { + for (const supporter of this.supporters.values()) { + yield* supporter.listFiles(); + } + } + *listRoots() { + for (const supporter of this.supporters.values()) { + yield* supporter.listRoots(); + } + } + async mapToDisk(virtualUri) { + if (fileUtil.isFileUri(virtualUri)) { + return virtualUri; + } + if (!this.virtualUrisRoot) { + return void 0; + } + try { + let mappedUri = this.map.getKey(virtualUri); + if (mappedUri === void 0) { + mappedUri = `${this.virtualUrisRoot}${await getSha1(virtualUri)}/${fileUtil.basename(virtualUri)}`; + try { + await fileUtil.unlink(this.externals, mappedUri); + } catch (e) { + if (!this.externals.error.isKind(e, "ENOENT")) { + throw e; + } + } + const buffer = await this.readFile(virtualUri); + await fileUtil.writeFile(this.externals, mappedUri, buffer, 292); + this.map.set(mappedUri, virtualUri); + } + return mappedUri; + } catch (e) { + } + return void 0; + } + mapFromDisk(mappedUri) { + if (!this.virtualUrisRoot) { + return mappedUri; + } + return this.map.get(mappedUri) ?? mappedUri; + } +}; +var FileUriSupporter = class _FileUriSupporter { + externals; + roots; + files; + protocol = "file:"; + constructor(externals, roots, files) { + this.externals = externals; + this.roots = roots; + this.files = files; + } + async hash(uri) { + return hashFile(this.externals, uri); + } + readFile(uri) { + return this.externals.fs.readFile(uri); + } + *listFiles() { + for (const files of this.files.values()) { + yield* files; + } + } + listRoots() { + return this.roots; + } + async mapToDisk(uri) { + return uri; + } + static async create(dependencies, externals, logger) { + const roots = []; + const files = /* @__PURE__ */ new Map(); + for (const dependency of dependencies) { + if (dependency.type !== "directory") { + continue; + } + let { uri } = dependency; + try { + if (fileUtil.isFileUri(uri) && (await externals.fs.stat(uri)).isDirectory()) { + uri = fileUtil.ensureEndingSlash(uri); + roots.push(uri); + files.set(uri, await fileUtil.getAllFiles(externals, uri)); + } + } catch (e) { + logger.error(`[FileUriSupporter#create] Bad dependency ${uri}`, e); + } + } + return new _FileUriSupporter(externals, roots, files); + } +}; +var ArchiveUriSupporter = class _ArchiveUriSupporter { + externals; + logger; + archiveHashes; + entries; + static Protocol = "archive:"; + protocol = _ArchiveUriSupporter.Protocol; + /** + * @param entries A map from archive names to unzipped entries. + */ + constructor(externals, logger, archiveHashes, entries) { + this.externals = externals; + this.logger = logger; + this.archiveHashes = archiveHashes; + this.entries = entries; + } + async hash(uri) { + const { archiveName, pathInArchive } = _ArchiveUriSupporter.decodeUri(new Uri(uri)); + if (!pathInArchive) { + if (!this.archiveHashes.has(archiveName)) { + throw new Error(`No archiveHashes entry for ${archiveName}`); + } + return this.archiveHashes.get(archiveName); + } else { + return getSha1(this.getDataInArchive(archiveName, pathInArchive)); + } + } + async readFile(uri) { + const { archiveName, pathInArchive } = _ArchiveUriSupporter.decodeUri(new Uri(uri)); + return this.getDataInArchive(archiveName, pathInArchive); + } + /** + * @throws + */ + getDataInArchive(archiveName, pathInArchive) { + const entries = this.entries.get(archiveName); + if (!entries) { + throw this.externals.error.createKind("ENOENT", `Archive \u201C${archiveName}\u201D has not been loaded into the memory`); + } + const entry6 = entries.get(pathInArchive); + if (!entry6) { + throw this.externals.error.createKind("ENOENT", `Path \u201C${pathInArchive}\u201D does not exist in archive \u201C${archiveName}\u201D`); + } + if (entry6.type !== "file") { + throw this.externals.error.createKind("EISDIR", `Path \u201C${pathInArchive}\u201D in archive \u201C${archiveName}\u201D is not a file`); + } + return entry6.data; + } + *listFiles() { + for (const [archiveName, entries] of this.entries.entries()) { + this.logger.info(`[ArchiveUriSupporter#listFiles] Listing ${entries.size} entries from ${archiveName}`); + for (const entry6 of entries.values()) { + if (entry6.type === "file") { + yield _ArchiveUriSupporter.getUri(archiveName, entry6.path); + } + } + } + } + *listRoots() { + for (const archiveName of this.entries.keys()) { + yield _ArchiveUriSupporter.getUri(archiveName); + } + } + static getUri(archiveName, pathInArchive = "") { + return `${_ArchiveUriSupporter.Protocol}//${archiveName}/${pathInArchive.replace(/\\/g, "/")}`; + } + /** + * @throws When `uri` has the wrong protocol or hostname. + */ + static decodeUri(uri) { + if (uri.protocol !== _ArchiveUriSupporter.Protocol) { + throw new Error(`Expected protocol \u201C${_ArchiveUriSupporter.Protocol}\u201D in ${uri}`); + } + const path6 = uri.pathname; + if (!path6) { + throw new Error(`Missing path in archive uri ${uri}`); + } + return { archiveName: uri.host, pathInArchive: path6.charAt(0) === "/" ? path6.slice(1) : path6 }; + } + static async create(dependencies, externals, logger) { + const archiveHashes = /* @__PURE__ */ new Map(); + const entries = /* @__PURE__ */ new Map(); + for (const dependency of dependencies) { + if (dependency.type === "directory") { + continue; + } + const archiveName = dependency.type === "tarball-file" ? fileUtil.basename(dependency.uri) : dependency.name; + try { + if (entries.has(archiveName)) { + throw new Error(`A different archive with ${archiveName} already exists`); + } + const bytes = dependency.type === "tarball-file" ? await externals.fs.readFile(dependency.uri) : dependency.data; + const files = await externals.archive.decompressBall(bytes, { stripLevel: dependency.stripLevel ?? 0 }); + logger.info(`[ArchiveUriSupporter#create] Extracted ${files.length} files from ${archiveName}`); + const hash = await getSha1(bytes); + archiveHashes.set(archiveName, hash); + entries.set(archiveName, new Map(files.map((f) => [f.path.replace(/\\/g, "/"), f]))); + } catch (e) { + logger.error(`[ArchiveUriSupporter#create] Bad dependency ${archiveName}`, e); + } + } + return new _ArchiveUriSupporter(externals, logger, archiveHashes, entries); + } +}; +async function hashFile(externals, uri) { + return getSha1(await externals.fs.readFile(uri)); +} + +// node_modules/@spyglassmc/core/lib/service/CacheService.js +var LatestCacheVersion = 7; +var Checksums; +(function(Checksums2) { + function create() { + return { files: {}, roots: {}, symbolRegistrars: {} }; + } + Checksums2.create = create; +})(Checksums || (Checksums = {})); +var CacheService = class { + cacheRoot; + project; + checksums = Checksums.create(); + errors = {}; + #hasValidatedFiles = false; + /** + * @param cacheRoot File path to the directory where cache files by Spyglass should be stored. + * @param project + */ + constructor(cacheRoot, project) { + this.cacheRoot = cacheRoot; + this.project = project; + this.project.on("documentUpdated", async ({ doc }) => { + if (!this.#hasValidatedFiles || !(doc.uri.startsWith(ArchiveUriSupporter.Protocol) || doc.uri.startsWith("file:"))) { + return; + } + try { + this.checksums.files[doc.uri] = await getSha1(doc.getText()); + } catch (e) { + if (!this.project.externals.error.isKind(e, "EISDIR")) { + this.project.logger.error(`[CacheService#hash-file] ${doc.uri}`); + } + } + }); + this.project.on("rootsUpdated", async ({ roots }) => { + if (!this.#hasValidatedFiles) { + return; + } + for (const root of roots) { + try { + this.checksums.roots[root] = await this.project.fs.hash(root); + } catch (e) { + if (!this.project.externals.error.isKind(e, "EISDIR")) { + this.project.logger.error(`[CacheService#hash-root] ${root}`, e); + } + } + } + }); + this.project.on("symbolRegistrarExecuted", ({ id, checksum }) => { + if (checksum !== void 0) { + this.checksums.symbolRegistrars[id] = checksum; + } + }); + this.project.on("documentErrored", ({ uri, errors }) => { + this.errors[uri] = errors; + }); + } + #cacheFilePath; + async getCacheFileUri() { + if (!this.#cacheFilePath) { + const sortedRoots = [...this.project.projectRoots].sort(); + const hash = await getSha1(sortedRoots.join(":")); + this.#cacheFilePath = new Uri(`symbols/${hash}.json.gz`, this.cacheRoot).toString(); + } + return this.#cacheFilePath; + } + async load() { + const ans = { symbols: {} }; + if (this.project.projectRoots.length === 0) { + return ans; + } + const __profiler = this.project.profilers.get("cache#load"); + let filePath; + try { + filePath = await this.getCacheFileUri(); + this.project.logger.info(`[CacheService#load] symbolCachePath = ${filePath}`); + const cache = await fileUtil.readGzippedJson(this.project.externals, filePath, bigintJsonLosslessReviver); + __profiler.task("Read File"); + if (cache.version === LatestCacheVersion) { + this.checksums = cache.checksums; + this.errors = cache.errors; + ans.symbols = SymbolTable.link(cache.symbols); + __profiler.task("Link Symbols"); + } else { + this.project.logger.info(`[CacheService#load] Unsupported cache format ${cache.version}; expected ${LatestCacheVersion}`); + } + } catch (e) { + if (!this.project.externals.error.isKind(e, "ENOENT")) { + this.project.logger.error("[CacheService#load] ", e); + } + } + __profiler.finalize(); + return ans; + } + async validate() { + const ans = { + addedFiles: [], + changedFiles: [], + removedFiles: [], + unchangedFiles: [] + }; + const unchangedRoots = []; + for (const [uri, checksum] of Object.entries(this.checksums.roots)) { + try { + const hash = await this.project.fs.hash(uri); + if (hash === checksum) { + unchangedRoots.push(uri); + } + } catch (e) { + if (!this.project.externals.error.isKind(e, "EISDIR")) { + this.project.logger.error(`[CacheService#hash-file] ${uri}`); + } + } + } + for (const [uri, checksum] of Object.entries(this.checksums.files)) { + if (unchangedRoots.some((root) => fileUtil.isSubUriOf(uri, root))) { + ans.unchangedFiles.push(uri); + continue; + } + if (this.project.shouldExclude(uri)) { + ans.removedFiles.push(uri); + continue; + } + try { + const hash = await this.project.fs.hash(uri); + if (hash === checksum) { + ans.unchangedFiles.push(uri); + } else { + ans.changedFiles.push(uri); + } + } catch (e) { + if (this.project.externals.error.isKind(e, "ENOENT") || this.project.externals.error.isKind(e, "EISDIR")) { + ans.removedFiles.push(uri); + } else { + this.project.logger.error(`[CacheService#validate] ${uri}`, e); + ans.changedFiles.push(uri); + } + } + } + for (const uri of this.project.getTrackedFiles()) { + if (!(uri in this.checksums.files)) { + ans.addedFiles.push(uri); + } + } + this.#hasValidatedFiles = true; + return ans; + } + /** + * @returns If the cache file was saved successfully. + */ + async save() { + if (this.project.projectRoots.length === 0) { + return false; + } + const __profiler = this.project.profilers.get("cache#save"); + let filePath; + try { + filePath = await this.getCacheFileUri(); + const cache = { + version: LatestCacheVersion, + projectRoots: this.project.projectRoots, + checksums: this.checksums, + symbols: SymbolTable.unlink(this.project.symbols.global), + errors: this.errors + }; + __profiler.task("Unlink Symbols"); + await fileUtil.writeGzippedJson(this.project.externals, filePath, cache, bigintJsonLosslessReplacer); + __profiler.task("Write File").finalize(); + return true; + } catch (e) { + this.project.logger.error(`[CacheService#save] path = ${filePath}`, e); + } + return false; + } + async hasFileChangedSinceCache(doc) { + return this.checksums.files[doc.uri] !== await getSha1(doc.getText()); + } + reset() { + this.#hasValidatedFiles = false; + this.checksums = Checksums.create(); + this.errors = {}; + return { symbols: {} }; + } +}; + +// node_modules/@spyglassmc/core/lib/service/Config.js +var import_rfdc3 = __toESM(require_rfdc(), 1); +var LinterSeverity; +(function(LinterSeverity2) { + function is(value) { + return value === "hint" || value === "information" || value === "warning" || value === "error"; + } + LinterSeverity2.is = is; + function toErrorSeverity(value) { + switch (value) { + case "error": + return ErrorSeverity.Error; + case "hint": + return ErrorSeverity.Hint; + case "information": + return ErrorSeverity.Information; + case "warning": + return ErrorSeverity.Warning; + } + } + LinterSeverity2.toErrorSeverity = toErrorSeverity; +})(LinterSeverity || (LinterSeverity = {})); +var LinterConfigValue; +(function(LinterConfigValue2) { + function destruct(value) { + if (value === null || value === void 0) { + return void 0; + } + if (LinterSeverity.is(value)) { + return { ruleSeverity: LinterSeverity.toErrorSeverity(value), ruleValue: true }; + } + if (Array.isArray(value) && LinterSeverity.is(value[0])) { + return { ruleSeverity: LinterSeverity.toErrorSeverity(value[0]), ruleValue: value[1] }; + } + return { ruleSeverity: ErrorSeverity.Warning, ruleValue: value }; + } + LinterConfigValue2.destruct = destruct; +})(LinterConfigValue || (LinterConfigValue = {})); +var SymbolLinterConfig; +(function(SymbolLinterConfig2) { + function is(value) { + return Arrayable.is(value, Complex.is) || Action.is(value); + } + SymbolLinterConfig2.is = is; + let Complex; + (function(Complex2) { + function is2(v) { + if (!v || typeof v !== "object") { + return false; + } + const value = v; + return (value.if === void 0 || Arrayable.is(value.if, Condition.is)) && (value.then === void 0 || Action.is(value.then)) && (value.override === void 0 || Arrayable.is(value.override, Complex2.is)); + } + Complex2.is = is2; + })(Complex = SymbolLinterConfig2.Complex || (SymbolLinterConfig2.Complex = {})); + let Condition; + (function(Condition2) { + function is2(v) { + if (!v || typeof v !== "object") { + return false; + } + const value = v; + return (value.category === void 0 || Arrayable.is(value.category, TypePredicates.isString)) && (value.pattern === void 0 || Arrayable.is(value.pattern, TypePredicates.isString)) && (value.excludePattern === void 0 || Arrayable.is(value.excludePattern, TypePredicates.isString)) && (value.namespace === void 0 || Arrayable.is(value.namespace, TypePredicates.isString)) && (value.excludeNamespace === void 0 || Arrayable.is(value.excludeNamespace, TypePredicates.isString)); + } + Condition2.is = is2; + })(Condition = SymbolLinterConfig2.Condition || (SymbolLinterConfig2.Condition = {})); + let Action; + (function(Action2) { + function isDeclare(value) { + return value !== void 0 && ["block", "file", "public"].includes(value.declare); + } + Action2.isDeclare = isDeclare; + function isReport(value) { + return value !== void 0 && ["inherit", "hint", "information", "warning", "error"].includes(value.report); + } + Action2.isReport = isReport; + function is2(v) { + if (!v || typeof v !== "object") { + return false; + } + const value = v; + return isDeclare(value) || isReport(value); + } + Action2.is = is2; + })(Action = SymbolLinterConfig2.Action || (SymbolLinterConfig2.Action = {})); +})(SymbolLinterConfig || (SymbolLinterConfig = {})); +var VanillaConfig = { + env: { + dependencies: ["@vanilla-datapack", "@vanilla-resourcepack", "@vanilla-mcdoc"], + exclude: [ + ".*/**", + "**/node_modules/**", + "**/__pycache__/**" + ], + customResources: {}, + feature: { + codeActions: true, + colors: true, + completions: true, + documentHighlighting: true, + documentLinks: true, + foldingRanges: true, + formatting: true, + hover: true, + inlayHint: { + enabledNodes: [ + "boolean", + "double", + "float", + "integer", + "long", + "mcfunction:coordinate", + "mcfunction:vector", + "mcfunction:command_child/unknown" + ] + }, + semanticColoring: true, + selectionRanges: true, + signatures: true + }, + gameVersion: "Auto", + permissionLevel: 2, + plugins: [], + mcmetaSummaryOverrides: {}, + enableMcdocCaching: false + }, + format: { + blockStateBracketSpacing: { inside: 0 }, + blockStateCommaSpacing: { before: 0, after: 1 }, + blockStateEqualSpacing: { before: 0, after: 0 }, + blockStateTrailingComma: false, + eol: "auto", + nbtArrayBracketSpacing: { inside: 0 }, + nbtArrayCommaSpacing: { before: 0, after: 1 }, + nbtArraySemicolonSpacing: { after: 1 }, + nbtArrayTrailingComma: false, + nbtByteSuffix: "b", + nbtCompoundBracketSpacing: { inside: 0 }, + nbtCompoundColonSpacing: { before: 0, after: 1 }, + nbtCompoundCommaSpacing: { before: 0, after: 1 }, + nbtCompoundTrailingComma: false, + nbtDoubleOmitSuffix: false, + nbtDoubleSuffix: "d", + nbtFloatSuffix: "f", + nbtListBracketSpacing: { inside: 0 }, + nbtListCommaSpacing: { before: 0, after: 1 }, + nbtListTrailingComma: false, + nbtLongSuffix: "L", + nbtShortSuffix: "s", + selectorBracketSpacing: { inside: 0 }, + selectorCommaSpacing: { before: 0, after: 1 }, + selectorEqualSpacing: { before: 0, after: 0 }, + selectorTrailingComma: false, + timeOmitTickUnit: false + }, + lint: { + blockStateSortKeys: null, + nbtCompoundSortKeys: null, + selectorSortKeys: null, + commandStringQuote: null, + nbtKeyQuote: null, + nbtPathQuote: null, + nbtStringQuote: null, + selectorKeyQuote: null, + idOmitDefaultNamespace: null, + nameOfNbtKey: null, + nameOfObjective: null, + nameOfScoreHolder: null, + nameOfTag: null, + nameOfTeam: null, + nbtArrayLengthCheck: true, + nbtBoolean: null, + nbtListLengthCheck: null, + nbtTypeCheck: "loosely", + undeclaredSymbol: [ + { + if: [ + { category: RegistryCategories, namespace: "minecraft" }, + { category: [...DataFileCategories, "bossbar", "objective", "stopwatch", "team"] } + ], + then: { report: "warning" } + }, + { + if: { category: ["attribute_modifier", "attribute_modifier_uuid", "tag"] }, + then: { declare: "public" } + }, + { + then: { declare: "block" } + } + ] + }, + snippet: { + executeIfScoreSet: "execute if score ${1:score_holder} ${2:objective} = ${1:score_holder} ${2:objective} $0", + summonAec: 'summon minecraft:area_effect_cloud ~ ~ ~ {Age: -2147483648, Duration: -1, WaitTime: -2147483648, Tags: ["${1:tag}"]}' + } +}; +var PartialConfig; +(function(PartialConfig2) { + function buildConfigFromEditorSettingsSafe(spyglassmcConfiguration) { + const result = {}; + if (!spyglassmcConfiguration || typeof spyglassmcConfiguration !== "object") { + return result; + } + if (spyglassmcConfiguration.env && typeof spyglassmcConfiguration.env === "object") { + result.env = {}; + if (typeof spyglassmcConfiguration.env.gameVersion === "string") { + result.env.gameVersion = spyglassmcConfiguration.env.gameVersion; + } + if (typeof spyglassmcConfiguration.env.enableMcdocCaching === "boolean") { + result.env.enableMcdocCaching = spyglassmcConfiguration.env.enableMcdocCaching; + } + if (spyglassmcConfiguration.env.feature && typeof spyglassmcConfiguration.env.feature === "object") { + result.env.feature = {}; + if (typeof spyglassmcConfiguration.env.feature.codeActions === "boolean") { + result.env.feature.codeActions = spyglassmcConfiguration.env.feature.codeActions; + } + if (typeof spyglassmcConfiguration.env.feature.colors === "boolean") { + result.env.feature.colors = spyglassmcConfiguration.env.feature.colors; + } + if (typeof spyglassmcConfiguration.env.feature.completions === "boolean") { + result.env.feature.completions = spyglassmcConfiguration.env.feature.completions; + } + if (typeof spyglassmcConfiguration.env.feature.documentHighlighting === "boolean") { + result.env.feature.documentHighlighting = spyglassmcConfiguration.env.feature.documentHighlighting; + } + if (typeof spyglassmcConfiguration.env.feature.documentLinks === "boolean") { + result.env.feature.documentLinks = spyglassmcConfiguration.env.feature.documentLinks; + } + if (typeof spyglassmcConfiguration.env.feature.foldingRanges === "boolean") { + result.env.feature.foldingRanges = spyglassmcConfiguration.env.feature.foldingRanges; + } + if (typeof spyglassmcConfiguration.env.feature.formatting === "boolean") { + result.env.feature.formatting = spyglassmcConfiguration.env.feature.formatting; + } + if (typeof spyglassmcConfiguration.env.feature.hover === "boolean") { + result.env.feature.hover = spyglassmcConfiguration.env.feature.hover; + } + if (spyglassmcConfiguration.env.feature.inlayHint && typeof spyglassmcConfiguration.env.feature.inlayHint === "object" && Array.isArray(spyglassmcConfiguration.env.feature.inlayHint.enabledNodes)) { + result.env.feature.inlayHint = { + enabledNodes: spyglassmcConfiguration.env.feature.inlayHint.enabledNodes.filter((element) => typeof element === "string") + }; + } + if (typeof spyglassmcConfiguration.env.feature.semanticColoring === "boolean") { + result.env.feature.semanticColoring = spyglassmcConfiguration.env.feature.semanticColoring; + } + if (spyglassmcConfiguration.env.feature.semanticColoring && typeof spyglassmcConfiguration.env.feature.semanticColoring === "object" && Array.isArray(spyglassmcConfiguration.env.feature.semanticColoring.disabledLanguages)) { + result.env.feature.semanticColoring = { + disabledLanguages: spyglassmcConfiguration.env.feature.semanticColoring.disabledLanguages.filter((element) => typeof element === "string") + }; + } + if (typeof spyglassmcConfiguration.env.feature.selectionRanges === "boolean") { + result.env.feature.selectionRanges = spyglassmcConfiguration.env.feature.selectionRanges; + } + if (typeof spyglassmcConfiguration.env.feature.signatures === "boolean") { + result.env.feature.signatures = spyglassmcConfiguration.env.feature.signatures; + } + } + } + return result; + } + PartialConfig2.buildConfigFromEditorSettingsSafe = buildConfigFromEditorSettingsSafe; +})(PartialConfig || (PartialConfig = {})); +var ConfigService = class _ConfigService extends EventDispatcher { + project; + defaultConfig; + static ConfigFileNames = Object.freeze(["spyglass.json", ".spyglassrc", ".spyglassrc.json"]); + currentEditorConfiguration = {}; + constructor(project, defaultConfig = VanillaConfig) { + super(); + this.project = project; + this.defaultConfig = defaultConfig; + const handler = async ({ uri }) => { + if (_ConfigService.isConfigFile(uri)) { + this.emit("changed", { config: await this.load() }); + } + }; + project.on("fileCreated", handler); + project.on("fileModified", handler); + project.on("fileDeleted", handler); + } + async onEditorConfigurationUpdate(editorConfiguration) { + this.currentEditorConfiguration = editorConfiguration; + this.emit("changed", { config: await this.load() }); + } + async load() { + const overrides = []; + for (const projectRoot of this.project.projectRoots) { + for (const name of _ConfigService.ConfigFileNames) { + const uri = projectRoot + name; + try { + const contents = await this.project.externals.fs.readFile(uri); + overrides.push(JSON.parse(bufferToString(contents))); + } catch (e) { + if (this.project.externals.error.isKind(e, "ENOENT")) { + continue; + } + this.emit("error", { error: e, uri }); + } + break; + } + } + return _ConfigService.merge(this.defaultConfig, this.currentEditorConfiguration, ...overrides); + } + static isConfigFile(uri) { + return _ConfigService.ConfigFileNames.some((n) => uri.endsWith(`/${n}`)); + } + static merge(base, ...overrides) { + return overrides.reduce(merge, (0, import_rfdc3.default)()(base)); + } +}; + +// node_modules/@spyglassmc/core/lib/processor/binder/Binder.js +var IsAsync = Symbol("IsAsyncBinder"); +var SyncBinder; +(function(SyncBinder2) { + function create(binder) { + return binder; + } + SyncBinder2.create = create; + function is(binder) { + return !binder[IsAsync]; + } + SyncBinder2.is = is; +})(SyncBinder || (SyncBinder = {})); +var AsyncBinder; +(function(AsyncBinder2) { + function create(binder) { + return Object.assign(binder, { [IsAsync]: true }); + } + AsyncBinder2.create = create; + function is(binder) { + return binder[IsAsync]; + } + AsyncBinder2.is = is; +})(AsyncBinder || (AsyncBinder = {})); + +// node_modules/@spyglassmc/core/lib/processor/binder/builtin.js +var builtin_exports = {}; +__export(builtin_exports, { + any: () => any, + attempt: () => attempt, + dispatchSync: () => dispatchSync, + fallback: () => fallback, + fallbackSync: () => fallbackSync, + noop: () => noop, + registerBinders: () => registerBinders, + resourceLocation: () => resourceLocation, + symbol: () => symbol +}); + +// node_modules/@spyglassmc/core/lib/processor/util.js +function traversePreOrder(node, shouldContinue, shouldCallFn, fn) { + traversePreOrderImpl(node, shouldContinue, shouldCallFn, fn, []); +} +function traversePreOrderImpl(node, shouldContinue, shouldCallFn, fn, parents) { + if (shouldCallFn(node, parents)) { + fn(node, parents); + } + if (!node.children || !shouldContinue(node, parents)) { + return; + } + for (const child of node.children ?? []) { + parents.unshift(node); + traversePreOrderImpl(child, shouldContinue, shouldCallFn, fn, parents); + parents.shift(); + } +} + +// node_modules/@spyglassmc/core/lib/processor/binder/builtin.js +function attempt(binder, node, ctx) { + const tempCtx = { + ...ctx, + err: new ErrorReporter(ctx.err.source), + symbols: ctx.symbols.clone() + }; + const processAfterBinder = () => { + StateProxy.undoChanges(node); + const totalErrorSpan = tempCtx.err.errors.map((e) => e.range.end - e.range.start).reduce((a, b) => a + b, 0); + return { + errorAmount: tempCtx.err.errors.length, + totalErrorSpan, + updateNodeAndCtx: () => { + ctx.err.absorb(tempCtx.err); + StateProxy.redoChanges(node); + tempCtx.symbols.applyDelayedEdits(); + } + }; + }; + if (SyncBinder.is(binder)) { + binder(node, tempCtx); + return processAfterBinder(); + } else { + return (async () => { + await binder(node, tempCtx); + return processAfterBinder(); + })(); + } +} +function any(binders) { + if (binders.length === 0) { + throw new Error("Expected at least one binder"); + } + const attemptSorter = (a, b) => a.errorAmount - b.errorAmount || a.totalErrorSpan - b.totalErrorSpan; + if (binders.every(SyncBinder.is)) { + return SyncBinder.create((node, ctx) => { + const attempts = binders.map((binder) => attempt(binder, node, ctx)).sort(attemptSorter); + attempts[0].updateNodeAndCtx(); + }); + } else { + return AsyncBinder.create(async (node, ctx) => { + const attempts = (await Promise.all(binders.map((binder) => attempt(binder, node, ctx)))).sort(attemptSorter); + attempts[0].updateNodeAndCtx(); + }); + } +} +var noop = SyncBinder.create(() => { +}); +var fallback = AsyncBinder.create(async (node, ctx) => { + const promises = []; + traversePreOrder(node, (node2) => !ctx.meta.hasBinder(node2.type), (node2) => ctx.meta.hasBinder(node2.type), (node2) => { + const binder = ctx.meta.getBinder(node2.type); + const result = binder(node2, ctx); + if (result instanceof Promise) { + promises.push(result); + } + }); + await Promise.all(promises); +}); +var fallbackSync = SyncBinder.create((node, ctx) => { + traversePreOrder(node, (node2) => !ctx.meta.hasBinder(node2.type), (node2) => ctx.meta.hasBinder(node2.type), (node2) => { + const binder = ctx.meta.getBinder(node2.type); + if (SyncBinder.is(binder)) { + binder(node2, ctx); + } else { + ctx.logger.warn(`[fallbackSync] Trying to run async binder for "${node2.type}"`); + } + }); +}); +var dispatchSync = SyncBinder.create((node, ctx) => { + for (const child of node.children ?? []) { + if (ctx.meta.hasBinder(child.type)) { + const binder = ctx.meta.getBinder(child.type); + binder(child, ctx); + } + } +}); +var resourceLocation = SyncBinder.create((node, ctx) => { + const raw = ResourceLocationNode.toString(node, "full"); + let sanitizedRaw = ResourceLocation.lengthen(node.options.namespacePathSep === "." ? raw.replace(/\./g, ResourceLocation.NamespacePathSep) : raw); + if (node.options.implicitPath) { + const sepIndex = sanitizedRaw.indexOf(ResourceLocation.NamespacePathSep); + sanitizedRaw = sanitizedRaw.substring(0, sepIndex + 1) + node.options.implicitPath + sanitizedRaw.substring(sepIndex + 1); + } + if (node.options.category) { + ctx.symbols.query(ctx.doc, node.isTag ? `tag/${node.options.category}` : node.options.category, sanitizedRaw).enter({ + usage: { type: node.options.usageType, node, accessType: node.options.accessType } + }); + } + if (node.options.pool && !node.options.allowUnknown) { + if (!node.options.pool.includes(sanitizedRaw)) { + ctx.err.report(localize("expected", node.options.pool), node, ErrorSeverity.Error); + } + return; + } +}); +var symbol = SyncBinder.create((node, ctx) => { + if (node.value) { + const path6 = node.options.parentPath ? [...node.options.parentPath, node.value] : [node.value]; + ctx.symbols.query(ctx.doc, node.options.category, ...path6).enter({ + data: { subcategory: node.options.subcategory }, + usage: { type: node.options.usageType, node, accessType: node.options.accessType } + }); + } +}); +function registerBinders(meta) { + meta.registerBinder("resource_location", resourceLocation); + meta.registerBinder("symbol", symbol); +} + +// node_modules/@spyglassmc/core/lib/processor/checker/builtin.js +var builtin_exports2 = {}; +__export(builtin_exports2, { + any: () => any2, + attempt: () => attempt2, + dispatchSync: () => dispatchSync2, + fallback: () => fallback2, + fallbackSync: () => fallbackSync2, + noop: () => noop2, + registerCheckers: () => registerCheckers, + resourceLocation: () => resourceLocation2, + symbol: () => symbol2 +}); +function attempt2(checker, node, ctx) { + const tempCtx = { + ...ctx, + err: new ErrorReporter(ctx.err.source), + symbols: ctx.symbols.clone() + }; + checker(node, tempCtx); + StateProxy.undoChanges(node); + const totalErrorSpan = tempCtx.err.errors.map((e) => e.range.end - e.range.start).reduce((a, b) => a + b, 0); + return { + errorAmount: tempCtx.err.errors.length, + totalErrorSpan, + updateNodeAndCtx: () => { + ctx.err.absorb(tempCtx.err); + StateProxy.redoChanges(node); + tempCtx.symbols.applyDelayedEdits(); + } + }; +} +function any2(checkers) { + if (checkers.length === 0) { + throw new Error("Expected at least one checker"); + } + return (node, ctx) => { + const attempts = checkers.map((checker) => attempt2(checker, node, ctx)).sort((a, b) => a.errorAmount - b.errorAmount || a.totalErrorSpan - b.totalErrorSpan); + attempts[0].updateNodeAndCtx(); + }; +} +var noop2 = () => { +}; +var fallback2 = async (node, ctx) => { + const promises = []; + traversePreOrder(node, (node2) => !ctx.meta.hasChecker(node2.type), (node2) => ctx.meta.hasChecker(node2.type), (node2) => { + const checker = ctx.meta.getChecker(node2.type); + const result = checker(node2, ctx); + if (result instanceof Promise) { + promises.push(result); + } + }); + await Promise.all(promises); +}; +var fallbackSync2 = async (node, ctx) => { + const promises = []; + traversePreOrder(node, (node2) => !ctx.meta.hasChecker(node2.type), (node2) => ctx.meta.hasChecker(node2.type), (node2) => { + const checker = ctx.meta.getChecker(node2.type); + const result = checker(node2, ctx); + if (result instanceof Promise) { + ctx.logger.warn(`[fallbackSync] Trying to run async checker for "${node2.type}"`); + } + }); + await Promise.all(promises); +}; +var dispatchSync2 = (node, ctx) => { + for (const child of node.children ?? []) { + if (ctx.meta.hasChecker(child.type)) { + const checker = ctx.meta.getChecker(child.type); + checker(child, ctx); + } + } +}; +var resourceLocation2 = (node, ctx) => { +}; +var symbol2 = (_node, _ctx) => { +}; +function registerCheckers(meta) { + meta.registerChecker("resource_location", resourceLocation2); + meta.registerChecker("symbol", symbol2); +} + +// node_modules/@spyglassmc/core/lib/processor/codeActions/builtin.js +var builtin_exports3 = {}; +__export(builtin_exports3, { + fallback: () => fallback3, + file: () => file, + registerProviders: () => registerProviders +}); +var fallback3 = (node, ctx) => { + const ans = []; + traversePreOrder(node, (node2) => Range.containsRange(node2.range, ctx.range, true), (node2) => ctx.meta.hasCodeActionProvider(node2.type), (node2) => ans.push(...ctx.meta.getCodeActionProvider(node2.type)(node2, ctx))); + return ans; +}; +var file = (node, ctx) => { + const ans = []; + for (const error4 of FileNode.getErrors(node)) { + const action = error4.info?.codeAction; + if (!action) { + continue; + } + if (!Range.containsRange(error4.range, ctx.range, true)) { + continue; + } + ans.push({ + ...action, + errors: [error4] + }); + } + return ans; +}; +function registerProviders(meta) { + meta.registerCodeActionProvider("file", file); +} + +// node_modules/@spyglassmc/core/lib/processor/ColorInfoProvider.js +var Color; +(function(Color2) { + Color2.NamedColors = /* @__PURE__ */ new Map([ + ["aqua", 5636095], + ["black", 0], + ["blue", 5592575], + ["dark_aqua", 43690], + ["dark_blue", 170], + ["dark_gray", 5592405], + ["dark_green", 43520], + ["dark_purple", 11141290], + ["dark_red", 11141120], + ["gold", 16755200], + ["gray", 11184810], + ["green", 5635925], + ["light_purple", 16733695], + ["red", 16733525], + ["white", 16777215], + ["yellow", 16777045] + ]); + Color2.ColorNames = [...Color2.NamedColors.keys()]; + function fromNamed(value) { + const composite = Color2.NamedColors.get(value); + if (composite === void 0) { + return void 0; + } + return fromCompositeRGB(composite); + } + Color2.fromNamed = fromNamed; + function fromDecRGBA(r, g, b, a) { + return [r, g, b, a]; + } + Color2.fromDecRGBA = fromDecRGBA; + function fromDecRGB(r, g, b) { + return fromDecRGBA(r, g, b, 1); + } + Color2.fromDecRGB = fromDecRGB; + function fromIntRGBA(r, g, b, a) { + return fromDecRGBA(r / 255, g / 255, b / 255, a / 255); + } + Color2.fromIntRGBA = fromIntRGBA; + function fromIntRGB(r, g, b) { + return fromIntRGBA(r, g, b, 255); + } + Color2.fromIntRGB = fromIntRGB; + function fromHexRGB(value) { + var bigint = parseInt(value.slice(1), 16); + var r = bigint >> 16 & 255; + var g = bigint >> 8 & 255; + var b = bigint & 255; + return fromIntRGB(r, g, b); + } + Color2.fromHexRGB = fromHexRGB; + function fromCompositeRGB(value) { + const r = value >> 16 & 255; + const g = value >> 8 & 255; + const b = value & 255; + return fromIntRGB(r, g, b); + } + Color2.fromCompositeRGB = fromCompositeRGB; + function fromCompositeARGB(value) { + value |= 0; + const a = value >>> 24 & 255; + const r = value >>> 16 & 255; + const g = value >>> 8 & 255; + const b = value & 255; + return fromIntRGBA(r, g, b, a); + } + Color2.fromCompositeARGB = fromCompositeARGB; +})(Color || (Color = {})); +var ColorFormat; +(function(ColorFormat2) { + ColorFormat2[ColorFormat2["DecRGBA"] = 0] = "DecRGBA"; + ColorFormat2[ColorFormat2["DecRGB"] = 1] = "DecRGB"; + ColorFormat2[ColorFormat2["IntRGBA"] = 2] = "IntRGBA"; + ColorFormat2[ColorFormat2["IntRGB"] = 3] = "IntRGB"; + ColorFormat2[ColorFormat2["HexRGBA"] = 4] = "HexRGBA"; + ColorFormat2[ColorFormat2["HexRGB"] = 5] = "HexRGB"; + ColorFormat2[ColorFormat2["CompositeRGB"] = 6] = "CompositeRGB"; + ColorFormat2[ColorFormat2["CompositeARGB"] = 7] = "CompositeARGB"; +})(ColorFormat || (ColorFormat = {})); +var ColorPresentation; +(function(ColorPresentation2) { + function fromColorFormat(format, color, range3) { + const presentation = colorPresentation(format, color); + return { label: presentation, text: presentation, range: range3 }; + } + ColorPresentation2.fromColorFormat = fromColorFormat; + function colorPresentation(format, color) { + const round = (num) => parseFloat(num.toFixed(3)); + switch (format) { + case ColorFormat.DecRGBA: + return color.map((c) => round(c)).join(" "); + case ColorFormat.DecRGB: + return color.slice(0, 3).map((c) => round(c)).join(" "); + case ColorFormat.IntRGBA: + return color.map((c) => Math.round(c * 255)).join(" "); + case ColorFormat.IntRGB: + return color.slice(0, 3).map((c) => Math.round(c * 255)).join(" "); + case ColorFormat.HexRGBA: + return `#${Math.round((color[0] * 255 << 24) + (color[1] * 255 << 16) + color[2] * 255 << 8 + color[3] * 255).toString(16).padStart(8, "0")}`; + case ColorFormat.HexRGB: + return `#${Math.round((color[0] * 255 << 16) + (color[1] * 255 << 8) + color[2] * 255).toString(16).padStart(6, "0")}`; + case ColorFormat.CompositeRGB: + return `${Math.round((color[0] * 255 << 16) + (color[1] * 255 << 8) + color[2] * 255)}`; + case ColorFormat.CompositeARGB: + return `${Number((BigInt(Math.round(color[3] * 255)) << 24n) + (BigInt(Math.round(color[0] * 255)) << 16n) + (BigInt(Math.round(color[1] * 255)) << 8n) + BigInt(Math.round(color[2] * 255))) << 0}`; + } + } +})(ColorPresentation || (ColorPresentation = {})); + +// node_modules/@spyglassmc/core/lib/processor/colorizer/builtin.js +var builtin_exports4 = {}; +__export(builtin_exports4, { + boolean: () => boolean, + comment: () => comment, + error: () => error, + fallback: () => fallback4, + literal: () => literal2, + number: () => number, + registerColorizers: () => registerColorizers, + resourceLocation: () => resourceLocation3, + string: () => string, + symbol: () => symbol3 +}); + +// node_modules/@spyglassmc/core/lib/processor/colorizer/Colorizer.js +var ColorToken; +(function(ColorToken2) { + function create(range3, type2, modifiers) { + return { range: Range.get(range3), type: type2, modifiers }; + } + ColorToken2.create = create; + function fillGap(tokens, targetRange, type2, modifiers) { + const ans = []; + let nextStart = Math.min(targetRange.start, tokens[0]?.range.start ?? Infinity); + for (const t of tokens) { + if (t.range.start > nextStart) { + ans.push(ColorToken2.create(Range.create(nextStart, t.range.start), type2, modifiers)); + } + ans.push(t); + nextStart = t.range.end; + } + if (nextStart < targetRange.end) { + ans.push(ColorToken2.create(Range.create(nextStart, targetRange.end), type2, modifiers)); + } + return ans; + } + ColorToken2.fillGap = fillGap; +})(ColorToken || (ColorToken = {})); +var ColorTokenTypes = Object.freeze([ + "comment", + "enum", + "enumMember", + "escape", + "function", + "keyword", + "modifier", + "number", + "property", + "string", + "struct", + "type", + "variable", + // Below are custom types. + "error", + "literal", + "operator", + "resourceLocation", + "vector" +]); +var ColorTokenModifiers = Object.freeze([ + "declaration", + "defaultLibrary", + "definition", + "deprecated", + "documentation", + "modification", + "readonly" + // Below are custom modifiers. +]); + +// node_modules/@spyglassmc/core/lib/processor/colorizer/builtin.js +var fallback4 = (node, ctx) => { + const ans = []; + traversePreOrder(node, (node2) => !ctx.meta.hasColorizer(node2.type) && (!ctx.range || Range.intersects(node2.range, ctx.range)), (node2) => ctx.meta.hasColorizer(node2.type), (node2) => { + const colorizer = ctx.meta.getColorizer(node2.type); + const result = colorizer(node2, ctx); + ans.push(...result); + }); + return Object.freeze(ans); +}; +var boolean = (node) => { + return [ColorToken.create(node, "literal")]; +}; +var comment = (node) => { + return [ColorToken.create(node, "comment")]; +}; +var error = (node) => { + return []; +}; +var literal2 = (node) => { + return [ColorToken.create(node, node.options.colorTokenType ?? "literal")]; +}; +var number = (node) => { + return [ColorToken.create(node, "number")]; +}; +var resourceLocation3 = (node, _ctx) => { + let type2; + switch (node.options.category) { + case "function": + case "tag/function": + type2 = "function"; + break; + default: + type2 = "resourceLocation"; + break; + } + return [ColorToken.create(node, type2)]; +}; +var string = (node, ctx) => { + if (node.children) { + const colorizer = ctx.meta.getColorizer(node.children[0].type); + const result = colorizer(node.children[0], ctx); + return ColorToken.fillGap(result, node.range, node.options.colorTokenType ?? "string"); + } else { + return [ColorToken.create(node, node.options.colorTokenType ?? "string")]; + } +}; +var symbol3 = (node) => { + return [ColorToken.create(node, "variable")]; +}; +function registerColorizers(meta) { + meta.registerColorizer("boolean", boolean); + meta.registerColorizer("comment", comment); + meta.registerColorizer("error", error); + meta.registerColorizer("float", number); + meta.registerColorizer("integer", number); + meta.registerColorizer("long", number); + meta.registerColorizer("literal", literal2); + meta.registerColorizer("resource_location", resourceLocation3); + meta.registerColorizer("string", string); + meta.registerColorizer("symbol", symbol3); +} + +// node_modules/@spyglassmc/core/lib/processor/completer/builtin.js +var builtin_exports5 = {}; +__export(builtin_exports5, { + boolean: () => boolean2, + dispatch: () => dispatch, + escapeString: () => escapeString, + fallback: () => fallback5, + file: () => file2, + literal: () => literal3, + noop: () => noop3, + record: () => record, + registerCompleters: () => registerCompleters, + resourceLocation: () => resourceLocation4, + string: () => string2, + symbol: () => symbol4 +}); +var import_binary_search3 = __toESM(require_binary_search(), 1); + +// node_modules/@spyglassmc/core/lib/processor/completer/Completer.js +var CompletionItem; +(function(CompletionItem2) { + function create(label, range3, other) { + const shouldEscape = other?.insertText === void 0 && needsEscape(label); + return { + ...other, + label, + range: Range.get(range3), + ...shouldEscape ? { insertText: escape(label) } : {} + }; + } + CompletionItem2.create = create; + function needsEscape(textToInsert) { + return /[\\$}]/.test(textToInsert); + } + CompletionItem2.needsEscape = needsEscape; + function escape(textToInsert) { + return textToInsert.replace(/([\\$}])/g, "\\$1"); + } + CompletionItem2.escape = escape; + function unescape(textToInsert) { + return textToInsert.replace(/\\([\\$}])/g, "$1"); + } + CompletionItem2.unescape = unescape; +})(CompletionItem || (CompletionItem = {})); +var InsertTextBuilder = class { + #ans = ""; + #nextPlaceholder = 1; + literal(str) { + this.#ans += CompletionItem.escape(str); + return this; + } + placeholder(...defaultValues) { + if (defaultValues.length === 0) { + this.#ans += `\${${this.#nextPlaceholder}}`; + } else if (defaultValues.length === 1) { + this.#ans += `\${${this.#nextPlaceholder}:${CompletionItem.escape(defaultValues[0])}}`; + } else { + this.#ans += `\${${this.#nextPlaceholder}|${defaultValues.map((v) => v.replace(/([\\$},|])/g, "\\$1")).join(",")}|}`; + } + this.#nextPlaceholder += 1; + return this; + } + exitPlace() { + this.#ans += "$0"; + return this; + } + build() { + return this.#ans; + } + if(condition, callback) { + if (condition) { + callback(this); + } + return this; + } +}; + +// node_modules/@spyglassmc/core/lib/processor/completer/builtin.js +var dispatch = (node, ctx) => { + const child = AstNode.findShallowestChild({ + node, + needle: ctx.offset, + endInclusive: true, + predicate: (n) => ctx.meta.hasCompleter(n.type) + }); + return child ? ctx.meta.getCompleter(child.type)(child, ctx) : []; +}; +var fallback5 = dispatch; +var boolean2 = (node, ctx) => { + return [ + CompletionItem.create("false", node, { + kind: 21 + /* CompletionKind.Constant */ + }), + CompletionItem.create("true", node, { + kind: 21 + /* CompletionKind.Constant */ + }) + ]; +}; +var file2 = (node, ctx) => { + const completer = ctx.meta.getCompleterForLanguageID(ctx.doc.languageId); + return completer(node.children[0], ctx); +}; +var literal3 = (node) => { + const kind = (/* @__PURE__ */ new Map([ + [ + "enum", + 13 + /* CompletionKind.Enum */ + ], + [ + "enumMember", + 20 + /* CompletionKind.EnumMember */ + ], + [ + "function", + 3 + /* CompletionKind.Function */ + ], + [ + "keyword", + 14 + /* CompletionKind.Keyword */ + ], + [ + "literal", + 14 + /* CompletionKind.Keyword */ + ], + [ + "number", + 21 + /* CompletionKind.Constant */ + ], + [ + "operator", + 24 + /* CompletionKind.Operator */ + ], + [ + "property", + 10 + /* CompletionKind.Property */ + ], + [ + "resourceLocation", + 17 + /* CompletionKind.File */ + ], + [ + "variable", + 6 + /* CompletionKind.Variable */ + ] + ])).get(node.options.colorTokenType ?? "keyword") ?? 14; + return node.options.pool.map((v) => CompletionItem.create(v, node, { kind })) ?? []; +}; +var noop3 = () => []; +var prefixed = (node, ctx) => { + const child = node.children.find((c) => c.type !== "literal"); + if (!child) { + return [CompletionItem.create("!", node)]; + } + const childItems = dispatch(child, ctx); + return childItems.map((item) => ({ + ...item, + label: node.prefix + item.label, + filterText: node.prefix + (item.filterText ?? item.label), + insertText: node.prefix + (item.insertText ?? item.label) + })); +}; +function record(o) { + return (node, ctx) => { + if (!node.innerRange || !Range.contains(node.innerRange, ctx.offset, true)) { + return []; + } + const completeKeys = (pair2) => o.key(node, pair2, ctx, pair2?.key ?? ctx.offset, false, false, existingKeys); + const completePairs = (pair2) => o.key(node, pair2, ctx, pair2 ?? ctx.offset, true, hasNextPair || !!pair2?.end, existingKeys); + const existingKeys = node.children.filter((n) => !!n.key).map((n) => n.key); + const index4 = (0, import_binary_search3.default)(node.children, ctx.offset, (n, o2) => n.end ? Range.compareOffset(Range.translate(n, 0, -1), o2, true) : Range.compareOffset(n.range, o2, true)); + const pair = index4 >= 0 ? node.children[index4] : void 0; + const hasNextPair = !!node.children.find((n) => n.range.start > ctx.offset); + if (!pair) { + return completePairs(void 0); + } + const { key: key2, sep: sep2, value } = pair; + if (!key2 && !sep2 && !value) { + return completePairs(void 0); + } + if (key2 && Range.contains(key2, ctx.offset, true) || sep2 && ctx.offset <= sep2.start) { + if (!value || Range.isEmpty(value.range)) { + return completePairs(pair); + } + return completeKeys(pair); + } + if (value && ctx.offset < value.range.start) { + return o.value(node, pair, ctx, ctx.offset); + } + if (value && Range.contains(value, ctx.offset, true) || sep2 && ctx.offset >= sep2.end || key2 && ctx.offset > key2.range.end) { + return o.value(node, pair, ctx, value ?? ctx.offset); + } + return []; + }; +} +var resourceLocation4 = (node, ctx) => { + const config = LinterConfigValue.destruct(ctx.config.lint.idOmitDefaultNamespace); + const includeEmptyNamespace = !node.options.requireCanonical && node.namespace === ""; + const includeDefaultNamespace = node.options.requireCanonical || config?.ruleValue !== true; + const excludeDefaultNamespace = !node.options.requireCanonical && config?.ruleValue !== false; + const getPool = (category) => { + const symbols = ctx.symbols.getVisibleSymbols(category, ctx.doc.uri); + const declarations = Object.entries(symbols).flatMap(([key2, symbol7]) => SymbolUtil.isDeclared(symbol7) ? [key2] : []); + return optimizePool(declarations); + }; + const optimizePool = (pool2) => { + const defaultNsPrefix = ResourceLocation.DefaultNamespace + ResourceLocation.NamespacePathSep; + const defaultNsIds = []; + const otherIds = []; + for (const id of filterPool(pool2)) { + if (id.startsWith(defaultNsPrefix)) { + defaultNsIds.push(id); + } else { + otherIds.push(id); + } + } + const ans = [ + ...otherIds, + ...includeDefaultNamespace ? defaultNsIds : [], + ...excludeDefaultNamespace ? defaultNsIds.map((id) => id.slice(defaultNsPrefix.length)) : [], + ...includeEmptyNamespace ? defaultNsIds.map((id) => id.slice(ResourceLocation.DefaultNamespace.length)) : [] + ]; + if (node.options.namespacePathSep === ".") { + return ans.map((v) => v.replace(ResourceLocation.NamespacePathSep, ".")); + } + return ans; + }; + const filterPool = (pool2) => { + if (!node.options.implicitPath) { + return pool2; + } + const ans = []; + for (const id of pool2) { + const sep2 = id.indexOf(ResourceLocation.NamespacePathSep); + const path6 = id.slice(sep2 + 1); + if (path6.startsWith(node.options.implicitPath)) { + ans.push(id.slice(0, sep2 + 1) + path6.slice(node.options.implicitPath.length)); + } + } + return ans; + }; + const pool = node.options.pool ? optimizePool(node.options.pool) : [ + ...!node.options.requireTag ? getPool(node.options.category) : [], + ...node.options.allowTag ? getPool(`tag/${node.options.category}`).map((v) => `${ResourceLocation.TagPrefix}${v}`) : [] + ]; + const items = pool.map((v) => CompletionItem.create(v, node, { + kind: 3 + /* CompletionKind.Function */ + })); + if (node.options.category) { + const symbols = ctx.symbols.getVisibleSymbols(node.options.category, ctx.doc.uri); + const thisKey = Object.entries(symbols).flatMap(([key2, symbol7]) => { + if ((symbol7.declaration?.[0] ?? symbol7.definition?.[0])?.uri === ctx.doc.uri) { + return [key2]; + } + return []; + }); + if (thisKey.length > 0) { + items.push(CompletionItem.create("THIS", node, { + kind: 15, + insertText: thisKey[0], + detail: thisKey[0] + })); + } + } + return items; +}; +var string2 = (node, ctx) => { + if (node.children?.length) { + return dispatch(node.children[0], ctx).map((item) => ({ + ...item, + filterText: escapeString(item.filterText ?? item.label, node.quote), + insertText: escapeString(item.insertText ?? item.label, node.quote) + })); + } + if (node.options.quotes && node.value === "") { + return node.options.quotes.map((q) => CompletionItem.create(`${q}${q}`, node, { + insertText: `${q}$1${q}`, + kind: 12 + })); + } + return []; +}; +function escapeString(value, quote2) { + if (!quote2) { + return value; + } + value = CompletionItem.unescape(value); + value = value.replaceAll("\\", "\\\\").replaceAll(quote2, '\\"'); + return CompletionItem.escape(value); +} +var symbol4 = (node, ctx) => { + const path6 = node.options.parentPath ?? []; + const symbols = ctx.symbols.query(ctx.doc, node.options.category, ...path6).visibleMembers; + return Object.entries(symbols).filter(([k, v]) => SymbolUtil.isDeclared(v)).map(([k, v]) => CompletionItem.create(k, node, { + kind: 6 + /* CompletionKind.Variable */ + })); +}; +function registerCompleters(meta) { + meta.registerCompleter("boolean", boolean2); + meta.registerCompleter("comment", noop3); + meta.registerCompleter("float", noop3); + meta.registerCompleter("integer", noop3); + meta.registerCompleter("long", noop3); + meta.registerCompleter("literal", literal3); + meta.registerCompleter("prefixed", prefixed); + meta.registerCompleter("resource_location", resourceLocation4); + meta.registerCompleter("string", string2); + meta.registerCompleter("symbol", symbol4); +} + +// node_modules/@spyglassmc/core/lib/processor/formatter/builtin.js +var builtin_exports6 = {}; +__export(builtin_exports6, { + boolean: () => boolean3, + comment: () => comment2, + error: () => error2, + fallback: () => fallback6, + file: () => file3, + float: () => float, + integer: () => integer, + literal: () => literal4, + long: () => long, + registerFormatters: () => registerFormatters, + resourceLocation: () => resourceLocation5, + string: () => string3 +}); +var fallback6 = (node) => { + throw new Error(`No formatter registered for type ${node.type}`); +}; +var error2 = (node) => { + return ""; +}; +var file3 = (node, ctx) => { + return node.children.map((child) => { + return ctx.meta.getFormatter(child.type)(child, ctx); + }).join(""); +}; +var boolean3 = (node) => { + return node.value ? "true" : "false"; +}; +var comment2 = (node) => { + return node.prefix + node.comment; +}; +var float = (node) => { + return node.value.toString(); +}; +var integer = (node) => { + return node.value.toFixed(); +}; +var literal4 = (node) => { + return node.value; +}; +var long = (node) => { + return node.value.toString(); +}; +var resourceLocation5 = (node) => { + return ResourceLocationNode.toString(node, "origin", true); +}; +var string3 = (node) => { + return `"${node.value}"`; +}; +function registerFormatters(meta) { + meta.registerFormatter("error", error2); + meta.registerFormatter("file", file3); + meta.registerFormatter("boolean", boolean3); + meta.registerFormatter("comment", comment2); + meta.registerFormatter("float", float); + meta.registerFormatter("integer", integer); + meta.registerFormatter("long", long); + meta.registerFormatter("literal", literal4); + meta.registerFormatter("resource_location", resourceLocation5); + meta.registerFormatter("string", string3); +} + +// node_modules/@spyglassmc/core/lib/processor/formatter/Formatter.js +function formatterContextIndentation(ctx, additionalLevels = 0) { + const total = ctx.indentLevel + additionalLevels; + return ctx.insertSpaces ? " ".repeat(total * ctx.tabSize) : " ".repeat(total); +} +function indentFormatter(ctx, additionalLevels = 1) { + return { + ...ctx, + indentLevel: ctx.indentLevel + additionalLevels, + indent(additionalLevels2) { + return formatterContextIndentation(this, additionalLevels2); + } + }; +} + +// node_modules/@spyglassmc/core/lib/processor/linter/builtin.js +var builtin_exports7 = {}; +__export(builtin_exports7, { + configValidator: () => configValidator, + nameConvention: () => nameConvention, + noop: () => noop4, + quote: () => quote, + registerLinters: () => registerLinters +}); + +// node_modules/@spyglassmc/core/lib/processor/linter/builtin/undeclaredSymbol.js +var undeclaredSymbol = (node, ctx) => { + if (!node.symbol || SymbolUtil.isDeclared(node.symbol)) { + return; + } + const action = getAction(ctx.ruleValue, node.symbol, ctx); + if (SymbolLinterConfig.Action.isDeclare(action)) { + ctx.symbols.query({ doc: ctx.doc, node }, node.symbol.category, ...node.symbol.path).amend({ + data: { visibility: getVisibility(action.declare) }, + usage: { type: "declaration", node } + }); + } + if (SymbolLinterConfig.Action.isReport(action)) { + const info = {}; + const uriBuilder2 = ctx.meta.getUriBuilder(node.symbol.category); + if (uriBuilder2) { + const uri = uriBuilder2(node.symbol.identifier, ctx); + if (uri) { + info.codeAction = { + title: localize("code-action.create-undeclared-file", node.symbol.category, localeQuote(node.symbol.identifier)), + changes: [{ type: "create", uri }] + }; + } + } + const severityOverride = action.report === "inherit" ? void 0 : LinterSeverity.toErrorSeverity(action.report); + ctx.err.lint(localize("linter.undeclared-symbol.message", node.symbol.category, localeQuote(node.symbol.identifier)), node, info, severityOverride); + } +}; +function getAction(config, symbol7, ctx) { + if (SymbolLinterConfig.Action.is(config)) { + return config; + } + function test(conditions) { + function testSingleCondition(condition) { + const resourceLocation7 = ResourceLocation.lengthen(symbol7.identifier); + const namespace = resourceLocation7.slice(0, resourceLocation7.indexOf(ResourceLocation.NamespacePathSep)); + return (condition.category ? Arrayable.toArray(condition.category).includes(symbol7.category) : true) && (condition.namespace ? Arrayable.toArray(condition.namespace).includes(namespace) : true) && (condition.excludeNamespace ? !Arrayable.toArray(condition.excludeNamespace).includes(namespace) : true) && (condition.pattern ? Arrayable.toArray(condition.pattern).some((p) => new RegExp(p).test(symbol7.identifier)) : true) && (condition.excludePattern ? !Arrayable.toArray(condition.excludePattern).some((p) => new RegExp(p).test(symbol7.identifier)) : true); + } + try { + return Arrayable.toArray(conditions).some(testSingleCondition); + } catch (e) { + ctx.logger.error("[undeclaredSymbol#getAction] Likely encountered an illegal regular expression in the config", e); + return false; + } + } + function evaluateComplexes(complexes) { + for (const complex of Arrayable.toArray(complexes)) { + if (complex.if && !test(complex.if)) { + continue; + } + return complex.override ? evaluateComplexes(complex.override) ?? complex.then : complex.then; + } + return void 0; + } + return evaluateComplexes(config); +} +function getVisibility(input) { + switch (input) { + case "block": + return 0; + case "file": + return 1; + case "public": + return 2; + } +} + +// node_modules/@spyglassmc/core/lib/processor/linter/builtin.js +var noop4 = () => { +}; +function nameConvention(key2) { + return (node, ctx) => { + if (typeof node[key2] !== "string") { + throw new Error(`Trying to access property "${key2}" of node type "${node.type}"`); + } + const name = node[key2]; + try { + const regex = new RegExp(ctx.ruleValue); + if (!name.match(regex)) { + ctx.err.lint(localize("linter.name-convention.illegal", localeQuote(name), localeQuote(ctx.ruleValue)), node); + } + } catch (e) { + ctx.logger.error(`[nameConvention linter] The value \u201C${ctx.ruleValue}\u201D set for rule \u201C${ctx.ruleName}\u201D is not a valid regular expression.`, e); + } + }; +} +var quote = (node, ctx) => { + const config = ctx.ruleValue; + const mustValueBeQuoted = node.options.unquotable ? [...node.value].some((c) => !isAllowedCharacter(c, node.options.unquotable)) : true; + const isQuoteRequired = config.always || mustValueBeQuoted; + const isQuoteProhibited = config.always === false && !mustValueBeQuoted; + const firstChar = ctx.src.slice(node.range.start, node.range.start + 1); + const isFirstCharQuote = !!node.options.quotes?.includes(firstChar); + if (isQuoteRequired) { + if (isFirstCharQuote) { + config.avoidEscape; + config.type; + } else { + } + } else if (isQuoteProhibited && isFirstCharQuote) { + } +}; +var configValidator; +(function(configValidator2) { + function getDocLink(name) { + return `https://spyglassmc.com/user/lint/${name}`; + } + function wrapError(name, msg) { + return `[Invalid Linter Config] [${name}] ${localize("linter-config-validator.wrapper", msg, getDocLink(name))}`; + } + function nameConvention2(name, val, logger) { + if (typeof val !== "string") { + logger.error(wrapError(name, localize("linter-config-validator.name-convention.type"))); + return false; + } + try { + new RegExp(val); + } catch (e) { + logger.error(wrapError(name, localize("")), e); + return false; + } + return true; + } + configValidator2.nameConvention = nameConvention2; + function symbolLinterConfig(_name, value, _logger) { + return SymbolLinterConfig.is(value); + } + configValidator2.symbolLinterConfig = symbolLinterConfig; +})(configValidator || (configValidator = {})); +function registerLinters(meta) { + meta.registerLinter("nameOfObjective", { + configValidator: configValidator.nameConvention, + linter: nameConvention("value"), + nodePredicate: (n) => n.symbol && n.symbol.category === "objective" + }); + meta.registerLinter("nameOfScoreHolder", { + configValidator: configValidator.nameConvention, + linter: nameConvention("value"), + nodePredicate: (n) => n.symbol && n.symbol.category === "score_holder" + }); + meta.registerLinter("nameOfTag", { + configValidator: configValidator.nameConvention, + linter: nameConvention("value"), + nodePredicate: (n) => n.symbol && n.symbol.category === "tag" + }); + meta.registerLinter("nameOfTeam", { + configValidator: configValidator.nameConvention, + linter: nameConvention("value"), + nodePredicate: (n) => n.symbol && n.symbol.category === "team" + }); + meta.registerLinter("undeclaredSymbol", { + configValidator: configValidator.symbolLinterConfig, + linter: undeclaredSymbol, + nodePredicate: (n) => n.symbol && !McdocCategories.includes(n.symbol.category) + }); +} + +// node_modules/@spyglassmc/core/lib/service/ErrorReporter.js +var ErrorReporter = class { + source; + errors = []; + constructor(source) { + this.source = source; + } + /** + * Reports a new error. + */ + report(message2, range3, severity = ErrorSeverity.Error, info) { + if (message2.trim() === "") { + throw new Error("Tried to report an error with no message"); + } + this.errors.push(LanguageError.create(message2, Range.get(range3), severity, info, this.source)); + } + /** + * @returns All reported errors, and then clears the error stack. + */ + dump() { + const ans = Object.freeze(this.errors); + this.errors = []; + return ans; + } + /** + * Adds all errors from another reporter's error stack to the current reporter. + * This method does not affect the passed-in reporter. + */ + absorb(reporter) { + this.errors.push(...reporter.errors); + } +}; +var LinterErrorReporter = class _LinterErrorReporter extends ErrorReporter { + ruleName; + ruleSeverity; + constructor(ruleName, ruleSeverity, source) { + super(source); + this.ruleName = ruleName; + this.ruleSeverity = ruleSeverity; + } + lint(message2, range3, info, severityOverride) { + return this.report(localize("linter.diagnostic-message-wrapper", message2, this.ruleName), range3, severityOverride ?? this.ruleSeverity, info); + } + static fromErrorReporter(reporter, ruleName, ruleSeverity) { + const ans = new _LinterErrorReporter(ruleName, ruleSeverity, reporter.source); + ans.errors = reporter.errors; + return ans; + } +}; + +// node_modules/@spyglassmc/core/lib/service/Context.js +var ContextBase; +(function(ContextBase2) { + function create(project) { + return { + fs: project.fs, + isDebugging: project.isDebugging, + logger: project.logger, + meta: project.meta, + profilers: project.profilers, + roots: project.roots, + project: project.ctx + }; + } + ContextBase2.create = create; +})(ContextBase || (ContextBase = {})); +var ParserContext; +(function(ParserContext2) { + function create(project, opts) { + return { + ...ContextBase.create(project), + config: project.config, + doc: opts.doc, + err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]) + }; + } + ParserContext2.create = create; +})(ParserContext || (ParserContext = {})); +var ProcessorContext; +(function(ProcessorContext2) { + function create(project, opts) { + return { + ...ContextBase.create(project), + config: project.config, + doc: opts.doc, + src: opts.src ?? new ReadonlySource(opts.doc.getText()), + symbols: project.symbols + }; + } + ProcessorContext2.create = create; +})(ProcessorContext || (ProcessorContext = {})); +var ProcessorWithRangeContext; +(function(ProcessorWithRangeContext2) { + function create(project, opts) { + return { ...ProcessorContext.create(project, opts), range: opts.range }; + } + ProcessorWithRangeContext2.create = create; +})(ProcessorWithRangeContext || (ProcessorWithRangeContext = {})); +var ProcessorWithOffsetContext; +(function(ProcessorWithOffsetContext2) { + function create(project, opts) { + return { ...ProcessorContext.create(project, opts), offset: opts.offset }; + } + ProcessorWithOffsetContext2.create = create; +})(ProcessorWithOffsetContext || (ProcessorWithOffsetContext = {})); +var BinderContext; +(function(BinderContext2) { + function create(project, opts) { + return { + ...ProcessorContext.create(project, opts), + err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]), + ensureBindingStarted: project.ensureBindingStarted?.bind(project) + }; + } + BinderContext2.create = create; +})(BinderContext || (BinderContext = {})); +var CheckerContext; +(function(CheckerContext2) { + function create(project, opts) { + return { + ...ProcessorContext.create(project, opts), + err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]), + ensureBindingStarted: project.ensureBindingStarted?.bind(project) + }; + } + CheckerContext2.create = create; +})(CheckerContext || (CheckerContext = {})); +var LinterContext; +(function(LinterContext2) { + function create(project, opts) { + return { + ...ProcessorContext.create(project, opts), + err: opts.err, + ruleName: opts.ruleName, + ruleValue: opts.ruleValue + }; + } + LinterContext2.create = create; +})(LinterContext || (LinterContext = {})); +var FormatterContext; +(function(FormatterContext2) { + function create(project, opts) { + return { + ...ProcessorContext.create(project, opts), + ...opts, + indentLevel: 0, + indent(additionalLevels) { + return formatterContextIndentation(this, additionalLevels); + } + }; + } + FormatterContext2.create = create; +})(FormatterContext || (FormatterContext = {})); +var CodeActionProviderContext; +(function(CodeActionProviderContext2) { + function create(project, opts) { + return { ...ProcessorContext.create(project, opts), range: opts.range }; + } + CodeActionProviderContext2.create = create; +})(CodeActionProviderContext || (CodeActionProviderContext = {})); +var ColorizerContext; +(function(ColorizerContext2) { + function create(project, opts) { + return ProcessorWithRangeContext.create(project, opts); + } + ColorizerContext2.create = create; +})(ColorizerContext || (ColorizerContext = {})); +var CompleterContext; +(function(CompleterContext2) { + function create(project, opts) { + return { + ...ProcessorContext.create(project, opts), + offset: opts.offset, + triggerCharacter: opts.triggerCharacter + }; + } + CompleterContext2.create = create; +})(CompleterContext || (CompleterContext = {})); +var SignatureHelpProviderContext; +(function(SignatureHelpProviderContext2) { + function create(project, opts) { + return ProcessorWithOffsetContext.create(project, opts); + } + SignatureHelpProviderContext2.create = create; +})(SignatureHelpProviderContext || (SignatureHelpProviderContext = {})); +var UriBinderContext; +(function(UriBinderContext2) { + function create(project) { + return { ...ContextBase.create(project), config: project.config, symbols: project.symbols }; + } + UriBinderContext2.create = create; +})(UriBinderContext || (UriBinderContext = {})); +var UriPredicateContext; +(function(UriPredicateContext2) { + function create(project) { + return { ...ContextBase.create(project) }; + } + UriPredicateContext2.create = create; +})(UriPredicateContext || (UriPredicateContext = {})); + +// node_modules/@spyglassmc/core/lib/service/Dependency.js +var DependencyKey; +(function(DependencyKey2) { + function is(value) { + return value.startsWith("@"); + } + DependencyKey2.is = is; +})(DependencyKey || (DependencyKey = {})); + +// node_modules/@spyglassmc/core/lib/service/fetcher.js +var FETCH_TIMEOUT_MS = 3e4; +async function fetchWithCache({ web }, logger, input, init) { + const cache = await web.getCache(); + const request = new Request(input, init); + const cachedResponse = await cache.match(request); + const cachedEtag = cachedResponse?.headers.get("ETag"); + if (cachedEtag) { + request.headers.set("If-None-Match", cachedEtag); + } + request.headers.set("User-Agent", "SpyglassMC (+https://spyglassmc.com)"); + try { + const response = await fetch(request, { signal: AbortSignal.timeout(FETCH_TIMEOUT_MS) }); + if (response.status === 304) { + Dev.assertDefined(cachedResponse); + logger.info(`[fetchWithCache] reusing cache for ${request.url}`); + return cachedResponse; + } else if (!response.ok) { + let message2 = response.statusText; + try { + message2 = (await response.json()).message; + } catch { + } + throw new TypeError(`${response.status} ${message2}`); + } else { + try { + await cache.put(request, response.clone()); + logger.info(`[fetchWithCache] updated cache for ${request.url}`); + } catch (e) { + logger.warn("[fetchWithCache] put cache", e); + } + return response; + } + } catch (e) { + logger.warn("[fetchWithCache] fetch", e); + if (cachedResponse) { + logger.info(`[fetchWithCache] falling back to cache for ${request.url}`); + return cachedResponse; + } + throw e; + } +} + +// node_modules/@spyglassmc/core/lib/service/Hover.js +var Hover; +(function(Hover2) { + function create(range3, markdown) { + return { range: Range.get(range3), markdown }; + } + Hover2.create = create; +})(Hover || (Hover = {})); + +// node_modules/@spyglassmc/core/lib/service/MetaRegistry.js +var MetaRegistry = class { + /** + * A map from language IDs to language options. + */ + #languages = /* @__PURE__ */ new Map(); + #binders = /* @__PURE__ */ new Map(); + #checkers = /* @__PURE__ */ new Map(); + #colorizers = /* @__PURE__ */ new Map(); + #codeActionProviders = /* @__PURE__ */ new Map(); + #completers = /* @__PURE__ */ new Map(); + #dependencyProviders = /* @__PURE__ */ new Map(); + #formatters = /* @__PURE__ */ new Map(); + #inlayHintProviders = /* @__PURE__ */ new Set(); + #linters = /* @__PURE__ */ new Map(); + #parsers = /* @__PURE__ */ new Map(); + #signatureHelpProviders = /* @__PURE__ */ new Set(); + #symbolRegistrars = /* @__PURE__ */ new Map(); + #custom = /* @__PURE__ */ new Map(); + #uriBinders = /* @__PURE__ */ new Set(); + #uriBuilders = /* @__PURE__ */ new Map(); + #uriSorter = () => 0; + constructor() { + builtin_exports.registerBinders(this); + builtin_exports2.registerCheckers(this); + builtin_exports3.registerProviders(this); + builtin_exports4.registerColorizers(this); + builtin_exports5.registerCompleters(this); + builtin_exports6.registerFormatters(this); + builtin_exports7.registerLinters(this); + } + /** + * Registers a new language. + * @param languageID The language ID. e.g. `"mcfunction"` + * @param options The language options for this language. + */ + registerLanguage(languageID, options2) { + this.#languages.set(languageID, options2); + } + /** + * An array of all registered language IDs. + */ + getLanguages() { + return Array.from(this.#languages.keys()); + } + getLanguageOptions(language2) { + return this.#languages.get(language2); + } + /** + * An array of characters that trigger a completion request. + */ + getTriggerCharacters() { + return Array.from(this.#languages.values()).flatMap((v) => v.triggerCharacters ?? []); + } + /** + * @param fileExtension The file extension including the leading dot. e.g. `".mcfunction"`. + * @returns The language ID registered for the file extension, or `undefined`. + */ + getLanguageID(fileExtension) { + for (const [languageID, { extensions }] of this.#languages) { + if (extensions.includes(fileExtension)) { + return languageID; + } + } + return void 0; + } + hasBinder(type2) { + return this.#binders.has(type2); + } + getBinder(type2) { + return this.#binders.get(type2) ?? builtin_exports.fallback; + } + registerBinder(type2, binder) { + this.#binders.set(type2, binder); + } + hasChecker(type2) { + return this.#checkers.has(type2); + } + getChecker(type2) { + return this.#checkers.get(type2) ?? builtin_exports2.fallback; + } + registerChecker(type2, checker) { + this.#checkers.set(type2, checker); + } + hasCodeActionProvider(type2) { + return this.#codeActionProviders.has(type2); + } + getCodeActionProvider(type2) { + return this.#codeActionProviders.get(type2) ?? builtin_exports3.fallback; + } + registerCodeActionProvider(type2, codeActionProvider) { + this.#codeActionProviders.set(type2, codeActionProvider); + } + hasColorizer(type2) { + return this.#colorizers.has(type2); + } + getColorizer(type2) { + return this.#colorizers.get(type2) ?? builtin_exports4.fallback; + } + registerColorizer(type2, colorizer) { + this.#colorizers.set(type2, colorizer); + } + hasCompleter(type2) { + return this.#completers.has(type2); + } + getCompleter(type2) { + return this.#completers.get(type2) ?? builtin_exports5.fallback; + } + registerCompleter(type2, completer) { + this.#completers.set(type2, completer); + } + shouldComplete(languageID, triggerCharacter) { + const language2 = this.#languages.get(languageID); + return !triggerCharacter || !!language2?.triggerCharacters?.includes(triggerCharacter); + } + getCompleterForLanguageID(languageID) { + return this.#languages.get(languageID)?.completer ?? builtin_exports5.fallback; + } + getDependencyProvider(key2) { + return this.#dependencyProviders.get(key2); + } + registerDependencyProvider(key2, provider) { + this.#dependencyProviders.set(key2, provider); + } + hasFormatter(type2) { + return this.#formatters.has(type2); + } + getFormatter(type2) { + return this.#formatters.get(type2) ?? builtin_exports6.fallback; + } + registerFormatter(type2, formatter) { + this.#formatters.set(type2, formatter); + } + registerInlayHintProvider(provider) { + this.#inlayHintProviders.add(provider); + } + get inlayHintProviders() { + return this.#inlayHintProviders; + } + getLinter(ruleName) { + return this.#linters.get(ruleName) ?? { configValidator: () => false, linter: builtin_exports7.noop, nodePredicate: () => false }; + } + registerLinter(ruleName, options2) { + this.#linters.set(ruleName, options2); + } + hasParser(id) { + return this.#parsers.has(id); + } + getParser(id) { + const ans = this.#parsers.get(id); + if (!ans) { + throw new Error(`There is no parser '${id}'`); + } + return ans; + } + getParserLazily(id) { + return Lazy.create(() => this.getParser(id)); + } + registerParser(id, parser) { + this.#parsers.set(id, parser); + } + /** + * @returns The corresponding `Parser` for the language ID. + * @throws If there's no such language in the registry. + */ + getParserForLanguageId(languageID) { + if (this.#languages.has(languageID)) { + return this.#languages.get(languageID).parser; + } + throw new Error(`There is no parser registered for language ID '${languageID}'`); + } + registerSignatureHelpProvider(provider) { + this.#signatureHelpProviders.add(provider); + } + get signatureHelpProviders() { + return this.#signatureHelpProviders; + } + registerSymbolRegistrar(id, registrar) { + this.#symbolRegistrars.set(id, registrar); + } + get symbolRegistrars() { + return this.#symbolRegistrars; + } + registerCustom(group, id, object5) { + let groupRegistry = this.#custom.get(group); + if (!groupRegistry) { + groupRegistry = /* @__PURE__ */ new Map(); + this.#custom.set(group, groupRegistry); + } + groupRegistry.set(id, object5); + } + getCustom(group) { + return this.#custom.get(group); + } + registerUriBinder(uriBinder3) { + this.#uriBinders.add(uriBinder3); + } + get uriBinders() { + return this.#uriBinders; + } + hasUriBuilder(category) { + return this.#uriBuilders.has(category); + } + getUriBuilder(category) { + return this.#uriBuilders.get(category); + } + registerUriBuilder(category, builder) { + this.#uriBuilders.set(category, builder); + } + setUriSorter(uriSorter2) { + const nextSorter = this.#uriSorter; + this.#uriSorter = (a, b) => uriSorter2(a, b, nextSorter); + } + get uriSorter() { + return this.#uriSorter; + } +}; + +// node_modules/@spyglassmc/core/lib/service/Profiler.js +var TopNImpl = class { + id; + logger; + n; + #finalized = false; + #startTime; + #lastTime; + #taskCount = 0; + #topTasks = []; + #minTime = Infinity; + #maxTime = 0; + constructor(id, logger, n) { + this.id = id; + this.logger = logger; + this.n = n; + this.#startTime = this.#lastTime = performance.now(); + } + task(name) { + if (this.#finalized) { + throw new Error("The profiler has already been finalized"); + } + this.#taskCount++; + const time2 = performance.now(); + const duration = time2 - this.#lastTime; + this.#lastTime = time2; + this.#minTime = Math.min(this.#minTime, duration); + this.#maxTime = Math.max(this.#maxTime, duration); + this.#topTasks.push([name, duration]); + this.#topTasks.sort((a, b) => b[1] - a[1]); + if (this.#topTasks.length > this.n) { + this.#topTasks = this.#topTasks.slice(0, -1); + } + return this; + } + finalize() { + this.#finalized = true; + const longestTaskNameLength = this.#topTasks.reduce((length, [name]) => Math.max(length, name.length), 0); + const totalDuration = this.#lastTime - this.#startTime; + this.logger.info(`[Profiler: ${this.id}] == Summary ==`); + this.logger.info(`[Profiler: ${this.id}] Total tasks: ${this.#taskCount} done in ${totalDuration} ms`); + this.logger.info(`[Profiler: ${this.id}] Min/Avg/Max: ${this.#minTime} / ${totalDuration / this.#taskCount} / ${this.#maxTime} ms`); + this.logger.info(`[Profiler: ${this.id}] Top ${Math.min(this.n, this.#topTasks.length)} task(s):`); + for (const [name, time2] of this.#topTasks) { + this.logger.info(`[Profiler: ${this.id}] ${name}${" ".repeat(longestTaskNameLength - name.length)} - ${time2} ms (${time2 / totalDuration * 100}%)`); + } + } +}; +var TotalTaskName = "Total"; +var TotalImpl = class { + id; + logger; + #finalized = false; + #startTime; + #lastTime; + #tasks = []; + #longestTaskNameLength = 0; + constructor(id, logger) { + this.id = id; + this.logger = logger; + this.#startTime = this.#lastTime = performance.now(); + } + task(name) { + if (this.#finalized) { + throw new Error("The profiler is finalized."); + } + const time2 = performance.now(); + const duration = time2 - this.#lastTime; + this.#lastTime = time2; + this.#tasks.push([name, duration]); + this.#longestTaskNameLength = Math.max(this.#longestTaskNameLength, name.length); + this.logger.info(`[Profiler: ${this.id}] Done: ${name} in ${duration} ms`); + return this; + } + finalize() { + this.#finalized = true; + this.#tasks.push([TotalTaskName, this.#lastTime - this.#startTime]); + this.#longestTaskNameLength = Math.max(this.#longestTaskNameLength, TotalTaskName.length); + this.logger.info(`[Profiler: ${this.id}] == Summary ==`); + for (const [name, time2] of this.#tasks) { + this.logger.info(`[Profiler: ${this.id}] ${name}${" ".repeat(this.#longestTaskNameLength - name.length)} - ${time2} ms`); + } + } +}; +var NoopImpl = class { + task() { + return this; + } + finalize() { + } +}; +var ProfilerFactory = class _ProfilerFactory { + logger; + #enabledProfilers; + constructor(logger, enabledProfilers) { + this.logger = logger; + this.#enabledProfilers = new Set(enabledProfilers); + } + get(id, style = "total", n) { + if (this.#enabledProfilers.has(id)) { + switch (style) { + case "top-n": + return new TopNImpl(id, this.logger, n); + case "total": + return new TotalImpl(id, this.logger); + default: + return Dev.assertNever(style); + } + } else { + return new NoopImpl(); + } + } + static noop() { + return new _ProfilerFactory(Logger.noop(), []); + } +}; + +// node_modules/@spyglassmc/core/lib/service/Project.js +var import_picomatch = __toESM(require_picomatch2(), 1); +var __decorate2 = function(decorators, target, key2, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key2) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key2, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key2, r) : d(target, key2)) || r; + return c > 3 && r && Object.defineProperty(target, key2, r), r; +}; +var CacheAutoSaveInterval = 6e5; +var Project = class _Project extends EventDispatcher { + static RootSuffix = "/pack.mcmeta"; + /** Prevent circular binding. */ + #bindingInProgressUris = /* @__PURE__ */ new Set(); + #cacheSaverIntervalId; + cacheService; + /** URI of files that are currently managed by the language client. */ + #clientManagedUris = /* @__PURE__ */ new Set(); + #clientManagedDocAndNodes = /* @__PURE__ */ new Map(); + #configService; + #symbolUpToDateUris = /* @__PURE__ */ new Set(); + #initializers; + #watcher; + get watchedFiles() { + return this.#watcher?.watchedFiles ?? new UriStore(); + } + #initPromise; + #readyPromise; + #isInitialized = false; + #isReady = false; + get isReady() { + return this.#isReady; + } + config; + externals; + fs; + isDebugging; + logger; + meta = new MetaRegistry(); + profilers; + projectRoots; + symbols; + #dependencyRoots; + #dependencyFiles; + #roots = []; + /** + * All tracked root URIs. Each URI in this array is guaranteed to end with a slash (`/`). + * + * Includes the roots of all dependencies, the project root, and all data pack roots identified + * by `pack.mcmeta` files. + * + * Some URIs in the array may overlap with each other. In such cases, the deeper ones are guaranteed to come + * before the shallower ones (e.g. `file:///foo/bar/` will come before `file:///foo/`). + */ + get roots() { + return this.#roots; + } + #ctx; + /** + * Arbitrary information that will be included in the `project` property of all `Context`s. + */ + get ctx() { + return this.#ctx; + } + #cacheRoot; + /** + * File URI to a directory where all cache files of Spyglass should be stored. + */ + get cacheRoot() { + return this.#cacheRoot; + } + updateRoots() { + const rawRoots = [...this.#dependencyRoots ?? [], ...this.projectRoots]; + const ans = new Set(rawRoots); + for (const file9 of this.getTrackedFiles()) { + if (file9.endsWith(_Project.RootSuffix) && rawRoots.some((r) => file9.startsWith(r))) { + ans.add(file9.slice(0, 1 - _Project.RootSuffix.length)); + } + } + this.#roots = [...ans].sort((a, b) => b.length - a.length); + this.emit("rootsUpdated", { roots: this.#roots }); + } + /** + * Get all files that are tracked and supported. + * + * Files in cached archives may not show up in the result as those files + * are not loaded into the memory. + */ + getTrackedFiles() { + const supportedFiles = [...this.#dependencyFiles ?? [], ...this.watchedFiles]; + this.logger.info(`[Project#getTrackedFiles] Listed ${supportedFiles.length} supported files`); + return supportedFiles; + } + constructor({ cacheRoot, defaultConfig, externals, fs: fs2 = FileService.create(externals, cacheRoot), initializers = [], isDebugging = false, logger = Logger.create(), profilers = ProfilerFactory.noop(), projectRoots }) { + super(); + this.#cacheRoot = cacheRoot; + this.externals = externals; + this.fs = fs2; + this.#initializers = initializers; + this.isDebugging = isDebugging; + this.logger = logger; + this.profilers = profilers; + this.projectRoots = projectRoots; + this.cacheService = new CacheService(cacheRoot, this); + this.#configService = new ConfigService(this, defaultConfig); + this.symbols = new SymbolUtil({}); + this.#ctx = {}; + this.logger.info(`[Project] [init] cacheRoot = ${cacheRoot}`); + this.logger.info(`[Project] [init] projectRoots = ${projectRoots.join(" ")}`); + this.#configService.on("changed", ({ config }) => { + const oldConfig = this.config; + this.config = config; + this.logger.info("[Project] [Config] Changed"); + this.emit("configChanged", { oldConfig, newConfig: config }); + }).on("error", ({ error: error4, uri }) => this.logger.error(`[Project] [Config] Failed loading ${uri}`, error4)); + this.#cacheSaverIntervalId = setInterval(() => this.cacheService.save(), CacheAutoSaveInterval); + this.on("documentUpdated", ({ doc, node }) => { + this.emit("documentErrored", { + errors: FileNode.getErrors(node).map((e) => LanguageError.withPosRange(e, doc)), + uri: doc.uri, + version: doc.version + }); + }).on("documentRemoved", ({ uri }) => { + this.emit("documentErrored", { errors: [], uri }); + }).on("fileCreated", async ({ uri }) => { + if (uri.endsWith(_Project.RootSuffix)) { + this.updateRoots(); + } + this.bindUri(uri); + return this.ensureBindingStarted(uri); + }).on("fileModified", async ({ uri }) => { + this.#symbolUpToDateUris.delete(uri); + if (this.isOnlyWatched(uri)) { + await this.ensureBindingStarted(uri); + } + }).on("fileDeleted", ({ uri }) => { + if (uri.endsWith(_Project.RootSuffix)) { + this.updateRoots(); + } + this.#symbolUpToDateUris.delete(uri); + this.symbols.clear({ uri }); + this.tryClearingCache(uri); + }).on("ready", () => { + this.#isReady = true; + const promises = []; + for (const { doc, node } of this.#clientManagedDocAndNodes.values()) { + promises.push(this.bind(doc, node).then(() => this.check(doc, node))); + } + Promise.all(promises).catch((e) => this.logger.error("[Project#ready] Error occurred when rechecking client managed files after READY", e)); + }); + } + /** + * Load the config file and initialize parsers and processors. + */ + async init() { + return this.#initPromise ??= this.#init(); + } + async #init() { + this.#isInitialized = false; + const callIntializers = async () => { + const initCtx = { + cacheRoot: this.cacheRoot, + config: this.config, + externals: this.externals, + isDebugging: this.isDebugging, + logger: this.logger, + meta: this.meta, + projectRoots: this.projectRoots + }; + const results = await Promise.allSettled(this.#initializers.map((init) => init(initCtx))); + let ctx = {}; + results.forEach(async (r, i) => { + if (r.status === "rejected") { + this.logger.error(`[Project] [callInitializers] [${i}] \u201C${this.#initializers[i].name}\u201D`, r.reason); + } else if (r.value) { + ctx = { ...ctx, ...r.value }; + } + }); + this.#ctx = ctx; + }; + const __profiler = this.profilers.get("project#init"); + const { symbols } = await this.cacheService.load(); + this.symbols = new SymbolUtil(symbols); + this.symbols.buildCache(); + __profiler.task("Load Cache"); + this.config = await this.#configService.load(); + __profiler.task("Load Config"); + await callIntializers(); + __profiler.task("Initialize").finalize(); + this.#isInitialized = true; + return this; + } + /** + * Finish the initial run of parsing, binding, and checking the entire project. + */ + async ready(options2 = {}) { + return this.#readyPromise ??= this.#ready(options2); + } + async #ready({ projectRootsWatcher } = {}) { + if (!this.#isInitialized) { + throw new Error("Project.ready() must be called after Project.init() resolves"); + } + this.#isReady = false; + this.#watcher = projectRootsWatcher; + const getDependencies = async () => { + const dependencies = []; + for (const input of this.config.env.dependencies) { + try { + if (DependencyKey.is(input)) { + const provider = this.meta.getDependencyProvider(input); + if (!provider) { + throw new Error(`No provider for ${input}`); + } + dependencies.push(await provider()); + this.logger.info(`[Project] [getDependencies] Executed provider \u201C${input}\u201D`); + } else { + const stats = await this.externals.fs.stat(input); + if (stats.isDirectory()) { + dependencies.push({ type: "directory", uri: input }); + } else if (stats.isFile()) { + dependencies.push({ type: "tarball-file", uri: input }); + } else { + throw new Error("Unsupported file entry type"); + } + } + } catch (e) { + this.logger.error(`[Project] [getDependencies] Bad dependency \u201C${input}\u201D`, e); + } + } + return dependencies; + }; + const listDependencyFiles = async () => { + const dependencies = await getDependencies(); + const fileUriSupporter = await FileUriSupporter.create(dependencies, this.externals, this.logger); + const archiveUriSupporter = await ArchiveUriSupporter.create(dependencies, this.externals, this.logger); + this.fs.register("file:", fileUriSupporter, true); + this.fs.register(ArchiveUriSupporter.Protocol, archiveUriSupporter, true); + }; + const listProjectFiles = async () => { + if (!this.#watcher) { + return; + } + this.#watcher.on("add", (uri) => { + if (this.shouldExclude(uri)) { + return; + } + this.emit("fileCreated", { uri }); + }).on("change", (uri) => { + if (this.shouldExclude(uri)) { + return; + } + this.emit("fileModified", { uri }); + }).on("unlink", (uri) => { + this.emit("fileDeleted", { uri }); + }).on("error", (e) => { + this.logger.error("[Project#watcher]", e); + }); + await this.#watcher.ready(); + }; + const __profiler = this.profilers.get("project#ready"); + await Promise.all([listDependencyFiles(), listProjectFiles()]); + this.#dependencyFiles = new Set([...this.fs.listFiles()].filter((uri) => !this.shouldExclude(uri))); + this.#dependencyRoots = new Set(this.fs.listRoots()); + this.updateRoots(); + __profiler.task("List URIs"); + for (const [id, { checksum, registrar }] of this.meta.symbolRegistrars) { + const cacheChecksum = this.cacheService.checksums.symbolRegistrars[id]; + if (cacheChecksum === void 0 || checksum !== cacheChecksum) { + this.symbols.clear({ contributor: `symbol_registrar/${id}` }); + this.symbols.contributeAs(`symbol_registrar/${id}`, () => { + registrar(this.symbols, { logger: this.logger }); + }); + this.emit("symbolRegistrarExecuted", { id, checksum }); + } else { + this.logger.info(`[SymbolRegistrar] Skipped \u201C${id}\u201D thanks to cache ${checksum}`); + } + } + __profiler.task("Register Symbols"); + for (const [uri, values] of Object.entries(this.cacheService.errors)) { + this.emit("documentErrored", { errors: values, uri }); + } + __profiler.task("Pop Errors"); + const { addedFiles, changedFiles, removedFiles } = await this.cacheService.validate(); + this.logger.info(`[Project#ready] Files added/changed/removed: ${addedFiles.length}/${changedFiles.length}/${removedFiles.length}`); + for (const uri of removedFiles) { + this.emit("fileDeleted", { uri }); + } + __profiler.task("Validate Cache"); + if (addedFiles.length > 0) { + this.bindUri(addedFiles); + } + __profiler.task("Bind URIs"); + const files = [...addedFiles, ...changedFiles].sort(this.meta.uriSorter); + __profiler.task("Sort URIs"); + const fileCountByExtension = /* @__PURE__ */ new Map(); + for (const file9 of files) { + const ext = fileUtil.extname(file9)?.replace(/^\./, ""); + if (ext) { + fileCountByExtension.set(ext, (fileCountByExtension.get(ext) ?? 0) + 1); + } + } + this.logger.info(`[Project#ready] == Files to bind ==`); + for (const [ext, count] of fileCountByExtension.entries()) { + this.logger.info(`[Project#ready] File extension ${ext}: ${count}`); + } + const __bindProfiler = this.profilers.get("project#ready#bind", "top-n", 50); + for (const uri of files) { + await this.ensureBindingStarted(uri); + __bindProfiler.task(uri); + } + __bindProfiler.finalize(); + __profiler.task("Bind Files"); + __profiler.finalize(); + this.emit("ready", {}); + this.#isReady = true; + return this; + } + /** + * Behavior of the `Project` instance is undefined after this function has settled. + */ + async close() { + clearInterval(this.#cacheSaverIntervalId); + await this.#watcher?.close(); + await this.cacheService.save(); + } + async restart() { + try { + this.#bindingInProgressUris.clear(); + this.#symbolUpToDateUris.clear(); + this.#readyPromise = void 0; + await this.ready(); + } catch (e) { + this.logger.error("[Project#reset]", e); + } + } + resetCache() { + this.logger.info("[Project#resetCache] Initiated..."); + for (const uri of Object.keys(this.cacheService.errors)) { + this.emit("documentErrored", { errors: [], uri }); + } + const { symbols } = this.cacheService.reset(); + this.symbols = new SymbolUtil(symbols); + this.symbols.buildCache(); + return this.restart(); + } + normalizeUri(uri) { + return this.fs.mapFromDisk(normalizeUri(uri)); + } + static TextDocumentCacheMaxLength = 268435456; + #textDocumentCache = /* @__PURE__ */ new Map(); + #textDocumentCacheLength = 0; + removeCachedTextDocument(uri) { + const doc = this.#textDocumentCache.get(uri); + if (doc && !(doc instanceof Promise)) { + this.#textDocumentCacheLength -= doc.getText().length; + } + this.#textDocumentCache.delete(uri); + } + async read(uri) { + const createTextDocument = async (uri2) => { + const languageId = this.guessLanguageID(uri2); + if (!this.isSupportedLanguage(uri2, languageId)) { + return void 0; + } + try { + const content = bufferToString(await this.fs.readFile(uri2)); + return TextDocument.create(uri2, languageId, -1, content); + } catch (e) { + this.logger.warn(`[Project] [read] Failed creating TextDocument for ${uri2}`, e); + return void 0; + } + }; + const trimCache = () => { + const iterator = this.#textDocumentCache.keys(); + while (this.#textDocumentCacheLength > _Project.TextDocumentCacheMaxLength) { + const result = iterator.next(); + if (result.done) { + throw new Error(`[Project] [read] Cache is too large with length ${this.#textDocumentCacheLength} even though it's empty; make sure to call 'removeCachedTextDocument()' instead of 'this.#textDocumentCache.delete()'`); + } + this.removeCachedTextDocument(result.value); + } + }; + const getCacheHandlingPromise = async (uri2) => { + if (this.#textDocumentCache.has(uri2)) { + const ans = this.#textDocumentCache.get(uri2); + this.#textDocumentCache.delete(uri2); + this.#textDocumentCache.set(uri2, ans); + return ans; + } else { + const promise = createTextDocument(uri2); + this.#textDocumentCache.set(uri2, promise); + const doc = await promise; + if (this.#textDocumentCache.get(uri2) === promise) { + if (doc) { + this.#textDocumentCache.set(uri2, doc); + this.#textDocumentCacheLength += doc.getText().length; + trimCache(); + } else { + this.#textDocumentCache.delete(uri2); + } + } + return doc; + } + }; + uri = this.normalizeUri(uri); + if (this.#clientManagedUris.has(uri)) { + const result = this.#clientManagedDocAndNodes.get(uri); + if (result) { + return result.doc; + } + throw new Error(`[Project] [read] Client-managed URI ${uri} does not have a TextDocument in the cache`); + } + return getCacheHandlingPromise(uri); + } + parse(doc) { + const ctx = ParserContext.create(this, { doc }); + const parser = ctx.meta.getParserForLanguageId(ctx.doc.languageId); + if (!parser) { + return { + type: "file", + range: Range.create(0), + children: [], + locals: /* @__PURE__ */ Object.create(null), + parserErrors: [] + }; + } + const src = new Source(doc.getText()); + return file4(parser)(src, ctx); + } + async bind(doc, node) { + if (node.binderErrors) { + return; + } + try { + this.#bindingInProgressUris.add(doc.uri); + const binder = this.meta.getBinder(node.type); + const ctx = BinderContext.create(this, { doc }); + ctx.symbols.clear({ contributor: "binder", uri: doc.uri }); + await ctx.symbols.contributeAsAsync("binder", async () => { + const proxy = StateProxy.create(node); + await binder(proxy, ctx); + node.binderErrors = ctx.err.dump(); + }); + this.#bindingInProgressUris.delete(doc.uri); + this.#symbolUpToDateUris.add(doc.uri); + } catch (e) { + this.logger.error(`[Project] [bind] Failed for ${doc.uri} # ${doc.version}`, e); + } + } + async check(doc, node) { + if (node.checkerErrors) { + return; + } + try { + const checker = this.meta.getChecker(node.type); + const ctx = CheckerContext.create(this, { doc }); + ctx.symbols.clear({ contributor: "checker", uri: doc.uri }); + await ctx.symbols.contributeAsAsync("checker", async () => { + await checker(StateProxy.create(node), ctx); + node.checkerErrors = ctx.err.dump(); + this.lint(doc, node); + }); + } catch (e) { + this.logger.error(`[Project] [check] Failed for ${doc.uri} # ${doc.version}`, e); + } + } + lint(doc, node) { + if (node.linterErrors) { + return; + } + node.linterErrors = []; + try { + for (const [ruleName, rawValue] of Object.entries(this.config.lint)) { + const result = LinterConfigValue.destruct(rawValue); + if (!result) { + continue; + } + const { ruleSeverity, ruleValue } = result; + const { configValidator: configValidator2, linter, nodePredicate } = this.meta.getLinter(ruleName); + if (!configValidator2(ruleName, ruleValue, this.logger)) { + continue; + } + const ctx = LinterContext.create(this, { + doc, + err: new LinterErrorReporter(ruleName, ruleSeverity, this.ctx["errorSource"]), + ruleName, + ruleValue + }); + traversePreOrder(node, () => true, () => true, (node2) => { + if (nodePredicate(node2)) { + const proxy = StateProxy.create(node2); + linter(proxy, ctx); + } + }); + node.linterErrors.push(...ctx.err.dump()); + } + } catch (e) { + this.logger.error(`[Project] [lint] Failed for ${doc.uri} # ${doc.version}`, e); + } + } + // @SingletonPromise() + async ensureBindingStarted(uri) { + uri = this.normalizeUri(uri); + if (this.#symbolUpToDateUris.has(uri) || this.#bindingInProgressUris.has(uri)) { + return; + } + this.#bindingInProgressUris.add(uri); + const doc = await this.read(uri); + if (!doc || !await this.cacheService.hasFileChangedSinceCache(doc)) { + return; + } + const node = this.parse(doc); + await this.bind(doc, node); + this.emit("documentUpdated", { doc, node }); + } + bindUri(param) { + const ctx = UriBinderContext.create(this); + if (typeof param === "string") { + ctx.symbols.clear({ contributor: "uri_binder", uri: param }); + } + ctx.symbols.contributeAs("uri_binder", () => { + const uris = Array.isArray(param) ? param : [param]; + for (const binder of this.meta.uriBinders) { + binder(uris, ctx); + } + }); + } + /** + * Notify that a new document was opened in the editor. + */ + async onDidOpen(uri, languageID, version, content) { + uri = this.normalizeUri(uri); + if (uri.startsWith(ArchiveUriSupporter.Protocol)) { + return; + } + if (this.shouldExclude(uri, languageID)) { + return; + } + const doc = TextDocument.create(uri, languageID, version, content); + const node = this.parse(doc); + this.#clientManagedUris.add(uri); + this.#clientManagedDocAndNodes.set(uri, { doc, node }); + if (this.#isReady) { + await this.bind(doc, node); + await this.check(doc, node); + } + } + /** + * Notify that an existing document was changed in the editor. + * @throws If there is no `TextDocument` corresponding to the URI. + */ + async onDidChange(uri, changes, version) { + uri = this.normalizeUri(uri); + this.#symbolUpToDateUris.delete(uri); + if (uri.startsWith(ArchiveUriSupporter.Protocol)) { + return; + } + const doc = this.#clientManagedDocAndNodes.get(uri)?.doc; + if (!doc || this.shouldExclude(uri, doc.languageId)) { + return; + } + TextDocument.update(doc, changes, version); + const node = this.parse(doc); + this.#clientManagedDocAndNodes.set(uri, { doc, node }); + if (this.#isReady) { + await this.bind(doc, node); + await this.check(doc, node); + } + } + /** + * Notify that an existing document was closed in the editor. + */ + onDidClose(uri) { + uri = this.normalizeUri(uri); + if (uri.startsWith(ArchiveUriSupporter.Protocol)) { + return; + } + this.#clientManagedUris.delete(uri); + this.#clientManagedDocAndNodes.delete(uri); + this.tryClearingCache(uri); + } + async ensureClientManagedChecked(uri) { + uri = this.normalizeUri(uri); + const result = this.#clientManagedDocAndNodes.get(uri); + if (result) { + const { doc, node } = result; + if (this.#isReady) { + await this.bind(doc, node); + await this.check(doc, node); + this.emit("documentUpdated", result); + } + return result; + } + return void 0; + } + getClientManaged(uri) { + uri = this.normalizeUri(uri); + return this.#clientManagedDocAndNodes.get(uri); + } + async showCacheRoot() { + if (!this.#cacheRoot) { + return; + } + try { + await fileUtil.ensureDir(this.externals, this.#cacheRoot); + await this.externals.fs.showFile(this.#cacheRoot); + } catch (e) { + this.logger.error("[Service#showCacheRoot]", e); + } + } + /** + * Returns true iff the URI should be excluded from all Spyglass language support. + * + * @param language Optional. If ommitted, a language will be derived from the URI according to + * its file extension. + */ + shouldExclude(uri, language2) { + return !this.isSupportedLanguage(uri, language2) && !ConfigService.isConfigFile(uri) || this.isUserExcluded(uri); + } + isSupportedLanguage(uri, language2) { + language2 ??= this.guessLanguageID(uri); + const languageOptions = this.meta.getLanguageOptions(language2); + if (!languageOptions) { + return false; + } + const { uriPredicate } = languageOptions; + return uriPredicate?.(uri, UriPredicateContext.create(this)) ?? true; + } + /** + * Guess a language ID from a URI. The guessed language ID may or may not actually be supported. + */ + guessLanguageID(uri) { + const ext = fileUtil.extname(uri) ?? ".spyglassmc-unknown"; + return this.meta.getLanguageID(ext) ?? ext.slice(1); + } + isUserExcluded(uri) { + if (this.config.env.exclude.length === 0) { + return false; + } + for (const rel of fileUtil.getRels(uri, this.projectRoots)) { + if ((0, import_picomatch.default)(this.config.env.exclude, { dot: true, posixSlashes: false })(rel)) { + return true; + } + } + return false; + } + tryClearingCache(uri) { + if (this.shouldRemove(uri)) { + this.removeCachedTextDocument(uri); + this.emit("documentRemoved", { uri }); + } + } + shouldRemove(uri) { + return !this.#clientManagedUris.has(uri) && !this.#dependencyFiles?.has(uri) && !this.watchedFiles.has(uri); + } + isOnlyWatched(uri) { + return this.watchedFiles.has(uri) && !this.#clientManagedUris.has(uri) && !this.#dependencyFiles?.has(uri); + } + async onEditorConfigurationUpdate(editorConfiguration) { + await this.#configService.onEditorConfigurationUpdate(editorConfiguration); + } +}; +__decorate2([ + SingletonPromise() +], Project.prototype, "bind", null); +__decorate2([ + SingletonPromise() +], Project.prototype, "check", null); +__decorate2([ + SingletonPromise() +], Project.prototype, "ensureClientManagedChecked", null); + +// node_modules/@spyglassmc/core/lib/service/SymbolLocations.js +var SymbolLocations; +(function(SymbolLocations2) { + function create(range3, locations) { + return { range: Range.get(range3), locations }; + } + SymbolLocations2.create = create; +})(SymbolLocations || (SymbolLocations = {})); + +// node_modules/@spyglassmc/core/lib/parser/Parser.js +var Failure = Symbol("Failure"); + +// node_modules/@spyglassmc/core/lib/parser/util.js +function attempt3(parser, src, ctx) { + const tmpSrc = src.clone(); + const tmpCtx = { ...ctx, err: new ErrorReporter(ctx.err.source) }; + const result = parser(tmpSrc, tmpCtx); + return { + result, + endCursor: tmpSrc.cursor, + errorAmount: tmpCtx.err.errors.length, + updateSrcAndCtx: () => { + src.innerCursor = tmpSrc.innerCursor; + ctx.err.absorb(tmpCtx.err); + } + }; +} +function sequence(parsers, parseGap) { + return (src, ctx) => { + const ans = { + [SequenceUtilDiscriminator]: true, + children: [], + range: Range.create(src) + }; + for (const [i, p] of parsers.entries()) { + const parser = typeof p === "function" ? p : p.get(ans); + if (parser === void 0) { + continue; + } + if (i > 0 && parseGap) { + ans.children.push(...parseGap(src, ctx)); + } + const result = parser(src, ctx); + if (result === Failure) { + return Failure; + } else if (result === void 0) { + continue; + } else if (SequenceUtil.is(result)) { + ans.children.push(...result.children); + } else { + ans.children.push(result); + } + } + ans.range.end = src.cursor; + return ans; + }; +} +function repeat(parser, parseGap) { + return (src, ctx) => { + const ans = { + [SequenceUtilDiscriminator]: true, + children: [], + range: Range.create(src) + }; + while (src.canRead()) { + if (parseGap) { + ans.children.push(...parseGap(src, ctx)); + } + const { result, updateSrcAndCtx } = attempt3(parser, src, ctx); + if (result === Failure) { + break; + } + updateSrcAndCtx(); + if (SequenceUtil.is(result)) { + ans.children.push(...result.children); + } else { + ans.children.push(result); + } + } + ans.range.end = src.cursor; + return ans; + }; +} +function any3(parsers, out) { + return (src, ctx) => { + const results = parsers.map((parser, i) => ({ attempt: attempt3(parser, src, ctx), index: i })).filter(({ attempt: attempt4 }) => attempt4.result !== Failure).sort((a, b) => b.attempt.endCursor - a.attempt.endCursor || a.attempt.errorAmount - b.attempt.errorAmount); + if (results.length === 0) { + if (out) { + out.index = -1; + } + return Failure; + } + results[0].attempt.updateSrcAndCtx(); + if (out) { + out.index = results[0].index; + } + return results[0].attempt.result; + }; +} +function failOnEmpty(parser) { + return (src, ctx) => { + const start = src.cursor; + const { endCursor, updateSrcAndCtx, result } = attempt3(parser, src, ctx); + if (endCursor - start > 0) { + updateSrcAndCtx(); + return result; + } + return Failure; + }; +} +function failOnError(parser) { + return (src, ctx) => { + const start = src.cursor; + const { errorAmount, updateSrcAndCtx, result } = attempt3(parser, src, ctx); + if (!errorAmount) { + updateSrcAndCtx(); + return result; + } + return Failure; + }; +} +function optional(parser) { + return ((src, ctx) => { + const { result, updateSrcAndCtx } = attempt3(parser, src, ctx); + if (result === Failure) { + return void 0; + } else { + updateSrcAndCtx(); + return result; + } + }); +} +function select(cases) { + return (src, ctx) => { + for (const { predicate, prefix, parser, regex } of cases) { + if (predicate?.(src) ?? (prefix !== void 0 ? src.tryPeek(prefix) : void 0) ?? (regex && src.matchPattern(regex)) ?? true) { + const callableParser = typeof parser === "object" ? parser.get() : parser; + return callableParser(src, ctx); + } + } + throw new Error("The select parser util was called with non-exhaustive cases"); + }; +} +function map(parser, fn) { + return (src, ctx) => { + const result = parser(src, ctx); + if (result === Failure) { + return Failure; + } + const ans = fn(result, src, ctx); + return ans; + }; +} +function setType(type2, parser) { + return map(parser, (res) => { + const { type: _type, ...restResult } = res; + const ans = { type: type2, ...restResult }; + delete ans[SequenceUtilDiscriminator]; + return ans; + }); +} +function validate(parser, validator4, message2, severity) { + return map(parser, (res, src, ctx) => { + const isLegal = validator4(res, src, ctx); + if (!isLegal) { + ctx.err.report(message2, res.range, severity); + } + return res; + }); +} +function stopBefore(parser, ...terminators) { + const flatTerminators = terminators.flat(); + return (src, ctx) => { + const tmpSrc = src.clone(); + tmpSrc.string = tmpSrc.string.slice(0, flatTerminators.reduce((p, c) => { + const index4 = tmpSrc.string.indexOf(c, tmpSrc.innerCursor); + return Math.min(p, index4 === -1 ? Infinity : index4); + }, Infinity)); + const ans = parser(tmpSrc, ctx); + src.cursor = tmpSrc.cursor; + return ans; + }; +} +function concatOnTrailingBackslash(parser) { + return (src, ctx) => { + let wrappedStr = src.sliceToCursor(0); + const wrappedSrcCursor = wrappedStr.length; + const indexMap = []; + while (src.canRead()) { + wrappedStr += src.readUntil("\\"); + if (!src.canRead()) { + break; + } + if (src.hasNonSpaceAheadInLine(1)) { + wrappedStr += src.read(); + continue; + } + const from = src.getCharRange(); + src.nextLine(); + if (!src.canRead()) { + const ans2 = { type: "error", range: Range.span(from, src) }; + ctx.err.report(localize("parser.line-continuation-end-of-file"), ans2); + } + src.skipSpace(); + const to = src.getCharRange(-1); + indexMap.push({ inner: Range.create(wrappedStr.length), outer: Range.span(from, to) }); + } + const wrappedSrc = new Source(wrappedStr, indexMap); + wrappedSrc.innerCursor = wrappedSrcCursor; + const ans = parser(wrappedSrc, ctx); + src.cursor = wrappedSrc.cursor; + return ans; + }; +} +function dumpErrors(parser) { + return ((src, ctx) => { + const ans = parser(src, ctx); + ctx.err.dump(); + return ans; + }); +} + +// node_modules/@spyglassmc/core/lib/parser/boolean.js +var boolean4 = map(literal("false", "true"), (res) => ({ + type: "boolean", + range: res.range, + value: res.value === "" ? void 0 : res.value === "true" +})); + +// node_modules/@spyglassmc/core/lib/parser/comment.js +function comment3({ singleLinePrefixes, includesEol }) { + return (src, _ctx) => { + const start = src.cursor; + const ans = { + type: "comment", + range: Range.create(start), + comment: "", + prefix: "" + }; + for (const prefix of singleLinePrefixes) { + if (src.peek(prefix.length) === prefix) { + if (includesEol) { + src.nextLine(); + } else { + src.skipLine(); + } + ans.range.end = src.cursor; + ans.comment = src.sliceToCursor(start + prefix.length); + ans.prefix = prefix; + return ans; + } + } + return Failure; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/error.js +var error3 = (src, ctx) => { + if (!src.canRead()) { + return void 0; + } + const ans = { type: "error", range: Range.create(src, () => src.skipRemaining()) }; + ctx.err.report(localize("error.unparseable-content"), ans); + return ans; +}; + +// node_modules/@spyglassmc/core/lib/parser/file.js +function file4(parser) { + return (src, ctx) => { + const fullRange = Range.create(src, src.string.length); + const ans = { + type: "file", + range: fullRange, + children: [], + locals: /* @__PURE__ */ Object.create(null), + parserErrors: [] + }; + src.skipWhitespace(); + const result = parser(src, ctx); + if (result && result !== Failure) { + ans.children.push(result); + } + if (src.skipWhitespace().canRead()) { + ans.children.push(error3(src, ctx)); + } + AstNode.setParents(ans); + ans.parserErrors = ctx.err.dump(); + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/float.js +var fallbackOnOutOfRange = (ans, _src, ctx, options2) => { + ctx.err.report(localize("expected", localize("float.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); +}; +function float2(options2) { + return (src, ctx) => { + const ans = { type: "float", range: Range.create(src), value: 0 }; + if (src.peek() === "-" || src.peek() === "+") { + src.skip(); + } + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + } + if (src.trySkip(".")) { + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + } + } + if (src.peek().toLowerCase() === "e") { + src.skip(); + if (src.peek() === "-" || src.peek() === "+") { + src.skip(); + } + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + } + } + ans.range.end = src.cursor; + const raw = src.sliceToCursor(ans.range.start); + ans.value = parseFloat(raw) || 0; + if (!raw) { + if (options2.failsOnEmpty) { + return Failure; + } + ctx.err.report(localize("expected", localize("float")), ans); + } else if (!options2.pattern.test(raw)) { + ctx.err.report(localize("parser.float.illegal", options2.pattern), ans); + } else if (options2.min && ans.value < options2.min || options2.max && ans.value > options2.max) { + const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange; + onOutOfRange(ans, src, ctx, options2); + } + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/integer.js +var fallbackOnOutOfRange2 = (ans, _src, ctx, options2) => { + ctx.err.report(localize("expected", localize("integer.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); +}; +function integer2(options2) { + return (src, ctx) => { + const ans = { type: "integer", range: Range.create(src), value: 0 }; + if (src.peek() === "-" || src.peek() === "+") { + src.skip(); + } + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + } + ans.range.end = src.cursor; + const raw = src.sliceToCursor(ans.range.start); + const isOnlySign = raw === "-" || raw === "+"; + if (!isOnlySign) { + ans.value = Number(raw); + } + if (!raw) { + if (options2.failsOnEmpty) { + return Failure; + } + ctx.err.report(localize("expected", localize("integer")), ans); + } else if (!options2.pattern.test(raw) || isOnlySign) { + ctx.err.report(localize("parser.integer.illegal", options2.pattern), ans); + } else if (options2.min !== void 0 && ans.value < options2.min || options2.max !== void 0 && ans.value > options2.max) { + const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange2; + onOutOfRange(ans, src, ctx, options2); + } + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/list.js +function list({ start, value, sep: sep2, trailingSep, end }) { + return (src, ctx) => { + const ans = { type: "list", range: Range.create(src), children: [] }; + if (src.trySkip(start)) { + src.skipWhitespace(); + let requiresValueSep = false; + let hasValueSep = false; + while (src.canRead() && src.peek(end.length) !== end) { + const itemStart = src.cursor; + let valueNode; + if (requiresValueSep && !hasValueSep) { + ctx.err.report(localize("expected", localeQuote(sep2)), src); + } + src.skipWhitespace(); + const { result, endCursor, updateSrcAndCtx } = attempt3(value, src, ctx); + if (result === Failure || endCursor === src.cursor) { + ctx.err.report(localize("expected", localize("parser.list.value")), Range.create(src, () => src.skipUntilOrEnd(sep2, end, "\r", "\n"))); + } else { + updateSrcAndCtx(); + valueNode = result; + } + let sepRange = void 0; + src.skipWhitespace(); + requiresValueSep = true; + if (hasValueSep = src.peek(sep2.length) === sep2) { + sepRange = Range.create(src, () => src.skip(sep2.length)); + } + ans.children.push({ + type: "item", + range: Range.create(itemStart, src), + ...valueNode ? { children: [valueNode] } : {}, + value: valueNode, + sep: sepRange + }); + src.skipWhitespace(); + } + if (hasValueSep && !trailingSep) { + const trailingRange = ans.children[ans.children.length - 1].sep; + ctx.err.report(localize("parser.list.trailing-sep"), trailingRange, ErrorSeverity.Error, { + codeAction: { + title: localize("code-action.remove-trailing-separation"), + isPreferred: true, + changes: [ + { + type: "edit", + range: trailingRange, + text: "" + } + ] + } + }); + } + if (!src.trySkip(end)) { + ctx.err.report(localize("expected", localeQuote(end)), src); + } + } else { + ctx.err.report(localize("expected", localeQuote(start)), src); + } + ans.range.end = src.cursor; + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/long.js +var fallbackOnOutOfRange3 = (ans, _src, ctx, options2) => { + ctx.err.report(localize("expected", localize("long.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); +}; +function long2(options2) { + return (src, ctx) => { + const ans = { type: "long", range: Range.create(src), value: 0n }; + if (src.peek() === "-" || src.peek() === "+") { + src.skip(); + } + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + } + ans.range.end = src.cursor; + const raw = src.sliceToCursor(ans.range.start); + let isOnlySign = false; + try { + ans.value = BigInt(raw); + } catch (_) { + isOnlySign = true; + } + if (!raw) { + if (options2.failsOnEmpty) { + return Failure; + } + ctx.err.report(localize("expected", localize("long")), ans); + } else if (!options2.pattern.test(raw) || isOnlySign) { + ctx.err.report(localize("parser.long.illegal", options2.pattern), ans); + } else if (options2.min && ans.value < options2.min || options2.max && ans.value > options2.max) { + const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange3; + onOutOfRange(ans, src, ctx, options2); + } + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/prefixed.js +function prefixed2(options2) { + return (src, ctx) => { + const ans = { + type: "prefixed", + range: Range.create(src), + prefix: options2.prefix, + children: [] + }; + const prefix = literal(options2.prefix)(src, ctx); + ans.children.push(prefix); + ans.range.end = src.cursor; + const child = options2.child(src, ctx); + if (child !== Failure) { + ans.children.push(child); + } + ans.range.end = src.cursor; + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/record.js +function record2({ start, pair, end }) { + return (src, ctx) => { + const ans = { type: "record", range: Range.create(src), children: [] }; + if (src.trySkip(start)) { + ans.innerRange = Range.create(src); + src.skipWhitespace(); + let requiresPairEnd = false; + let hasPairEnd = false; + while (src.canRead() && src.peek(end.length) !== end) { + const pairStart = src.cursor; + let key2; + let value; + if (requiresPairEnd && !hasPairEnd) { + ctx.err.report(localize("expected", localeQuote(pair.end)), src); + } + const keyStart = src.cursor; + const { result: keyResult, updateSrcAndCtx: updateForKey, endCursor: keyEnd } = attempt3(pair.key, src, ctx); + if (keyResult === Failure || keyEnd - keyStart === 0 && ![pair.sep, pair.end, end, "\r", "\n", " ", " "].includes(src.peek())) { + ctx.err.report(localize("expected", localize("parser.record.key")), Range.create(src, () => src.skipUntilOrEnd(pair.sep, pair.end, end, "\r", "\n"))); + } else { + updateForKey(); + key2 = keyResult; + } + let sepCharRange = void 0; + src.skipWhitespace(); + if (src.peek(pair.sep.length) === pair.sep) { + sepCharRange = Range.create(src, () => src.skip(pair.sep.length)); + } else { + ctx.err.report(localize("expected", localeQuote(pair.sep)), src); + } + src.skipWhitespace(); + const valueParser = typeof pair.value === "function" ? pair.value : pair.value.get(ans, key2); + const valueStart = src.cursor; + const { result: valueResult, updateSrcAndCtx: updateForValue, endCursor: valueEnd } = attempt3(valueParser, src, ctx); + if (valueResult === Failure || valueEnd - valueStart === 0 && ![pair.sep, pair.end, end, "\r", "\n", " ", " "].includes(src.peek())) { + ctx.err.report(localize("expected", localize("parser.record.value")), Range.create(src, () => src.skipUntilOrEnd(pair.sep, pair.end, end, "\r", "\n"))); + } else { + updateForValue(); + value = valueResult; + } + let endCharRange = void 0; + src.skipWhitespace(); + requiresPairEnd = true; + if (hasPairEnd = src.peek(pair.end.length) === pair.end) { + endCharRange = Range.create(src, () => src.skip(pair.end.length)); + } + ans.children.push({ + type: "pair", + range: Range.create(pairStart, src), + ...key2 || value ? { children: [key2, value].filter((v) => !!v) } : {}, + key: key2, + sep: sepCharRange, + value, + end: endCharRange + }); + src.skipWhitespace(); + } + if (hasPairEnd && !pair.trailingEnd) { + const trailingRange = ans.children[ans.children.length - 1].end; + ctx.err.report(localize("parser.record.trailing-end"), trailingRange, ErrorSeverity.Error, { + codeAction: { + title: localize("code-action.remove-trailing-separation"), + isPreferred: true, + changes: [ + { + type: "edit", + range: trailingRange, + text: "" + } + ] + } + }); + } + ans.innerRange.end = src.cursor; + if (!src.trySkip(end)) { + ctx.err.report(localize("expected", localeQuote(end)), src); + } + } else { + ctx.err.report(localize("expected", localeQuote(start)), src); + } + ans.range.end = src.cursor; + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/resourceLocation.js +var Terminators = /* @__PURE__ */ new Set([ + " ", + "\r", + "\n", + "=", + "~", + ",", + '"', + "'", + "{", + "}", + "[", + "]", + "(", + ")", + ";", + "|" +]); +var LegalResourceLocationCharacters = /* @__PURE__ */ new Set([ + "a", + "b", + "c", + "d", + "e", + "f", + "g", + "h", + "i", + "j", + "k", + "l", + "m", + "n", + "o", + "p", + "q", + "r", + "s", + "t", + "u", + "v", + "w", + "x", + "y", + "z", + "0", + "1", + "2", + "3", + "4", + "5", + "6", + "7", + "8", + "9", + "_", + "-", + "." +]); +function resourceLocation6(options2) { + return (src, ctx) => { + const ans = { + type: "resource_location", + range: Range.create(src), + options: options2 + }; + if (src.trySkip(ResourceLocation.TagPrefix)) { + ans.isTag = true; + } + const start = src.cursor; + while (src.canReadInLine() && !Terminators.has(src.peek())) { + src.skip(); + } + const raw = src.sliceToCursor(start); + ans.range.end = src.cursor; + if (raw.length === 0) { + ctx.err.report(localize("expected", localize("resource-location")), ans); + } else { + const sepIndex = raw.indexOf(options2.namespacePathSep ?? ResourceLocation.NamespacePathSep); + if (sepIndex >= 0) { + ans.namespace = raw.slice(0, sepIndex); + } + const rawPath = raw.slice(sepIndex + 1); + ans.path = rawPath.split(ResourceLocation.PathSep); + const illegalChars = [ + .../* @__PURE__ */ new Set([ + ...[...ans.namespace ?? []].filter((c) => !LegalResourceLocationCharacters.has(c)), + ...[...rawPath].filter((c) => c !== "/" && !LegalResourceLocationCharacters.has(c)) + ]) + ]; + if (illegalChars.length) { + ctx.err.report(localize("parser.resource-location.illegal", arrayToMessage(illegalChars, true, "and")), ans); + } + if (ans.isTag && !options2.allowTag) { + ctx.err.report(localize("parser.resource-location.tag-disallowed"), ans); + } + if (!ans.isTag && options2.requireTag) { + ctx.err.report(localize("parser.resource-location.tag-required"), ans); + } + if (!ans.namespace && options2.requireCanonical) { + ctx.err.report(localize("parser.resource-location.namespace-expected"), ans, ErrorSeverity.Error, { + codeAction: { + title: localize("code-action.add-default-namespace"), + isPreferred: true, + changes: [ + { + type: "edit", + range: Range.create(start), + text: ResourceLocation.DefaultNamespace + ResourceLocation.NamespacePathSep + } + ] + } + }); + } + } + return ans; + }; +} + +// node_modules/@spyglassmc/core/lib/parser/string.js +function string4(options2) { + return (src, ctx) => { + const ans = { + type: "string", + range: Range.create(src), + options: options2, + value: "", + valueMap: [] + }; + let start; + if (options2.quotes?.length && (src.peek() === '"' || src.peek() === "'")) { + const currentQuote = src.read(); + ans.quote = currentQuote; + let cStart = src.cursor; + start = cStart; + while (src.canRead() && src.peek() !== currentQuote) { + const c = src.peek(); + if (options2.escapable && c === "\\") { + src.skip(); + const c2 = src.read(); + if (c2 === "\\" || c2 === currentQuote || EscapeChar.is(options2.escapable.characters, c2)) { + ans.valueMap.push({ + inner: Range.create(ans.value.length, ans.value.length + 1), + outer: Range.create(cStart, src) + }); + ans.value += EscapeTable.get(c2); + } else if (options2.escapable.unicode && c2 === "u") { + const hex = src.peek(4); + if (/^[0-9a-f]{4}$/i.test(hex)) { + src.skip(4); + ans.valueMap.push({ + inner: Range.create(ans.value.length, ans.value.length + 1), + outer: Range.create(cStart, src) + }); + ans.value += String.fromCharCode(parseInt(hex, 16)); + } else { + ctx.err.report(localize("parser.string.illegal-unicode-escape"), Range.create(src, src.getCharRange(3).end)); + ans.valueMap.push({ + inner: Range.create(ans.value.length, ans.value.length + 1), + outer: Range.create(cStart, src) + }); + ans.value += c2; + } + } else { + if (!options2.escapable.allowUnknown) { + ctx.err.report(localize("parser.string.illegal-escape", localeQuote(c2)), src.getCharRange(-1)); + } + ans.valueMap.push({ + inner: Range.create(ans.value.length, ans.value.length + 1), + outer: Range.create(cStart, src) + }); + ans.value += c2; + } + cStart = src.cursor; + } else { + src.skip(); + const cEnd = src.cursor; + if (cEnd - cStart > 1) { + ans.valueMap.push({ + inner: Range.create(ans.value.length, ans.value.length + 1), + outer: Range.create(cStart, cEnd) + }); + } + ans.value += c; + cStart = cEnd; + } + } + if (!src.trySkip(currentQuote)) { + ctx.err.report(localize("expected", localeQuote(currentQuote)), src); + } + if (!options2.quotes.includes(currentQuote)) { + ctx.err.report(localize("parser.string.illegal-quote", options2.quotes), ans); + } + } else if (options2.unquotable) { + start = src.cursor; + while (src.canRead() && isAllowedCharacter(src.peek(), options2.unquotable)) { + ans.value += src.read(); + } + if (!ans.value && !options2.unquotable.allowEmpty) { + ctx.err.report(localize("expected", localize("string")), src); + } + } else { + start = src.cursor; + ctx.err.report(localize("expected", options2.quotes), src); + } + ans.valueMap.unshift({ inner: Range.create(0), outer: Range.create(start) }); + if (options2.value?.parser) { + const valueResult = parseStringValue(options2.value.parser, ans.value, ans.valueMap, ctx); + if (valueResult !== Failure) { + ans.children = [valueResult]; + } + } + ans.range.end = src.cursor; + return ans; + }; +} +function parseStringValue(parser, value, map3, ctx) { + const valueSrc = new Source(value, map3); + const valueCtx = { + ...ctx, + doc: TextDocument.create(ctx.doc.uri, ctx.doc.languageId, ctx.doc.version, value) + }; + return parser(valueSrc, valueCtx); +} +var BrigadierUnquotableCharacters = Object.freeze([ + "0", + "1", + "2", + "3", + "4", + "5", + "6", + "7", + "8", + "9", + "A", + "B", + "C", + "D", + "E", + "F", + "G", + "H", + "I", + "J", + "K", + "L", + "M", + "N", + "O", + "P", + "Q", + "R", + "S", + "T", + "U", + "V", + "W", + "X", + "Y", + "Z", + "a", + "b", + "c", + "d", + "e", + "f", + "g", + "h", + "i", + "j", + "k", + "l", + "m", + "n", + "o", + "p", + "q", + "r", + "s", + "t", + "u", + "v", + "w", + "x", + "y", + "z", + "_", + ".", + "+", + "-" +]); +var BrigadierUnquotableCharacterSet = new Set(BrigadierUnquotableCharacters); +var BrigadierUnquotablePattern = /^[0-9A-Za-z_\.\+\-]*$/; +var BrigadierUnquotableOption = { + allowEmpty: true, + allowList: BrigadierUnquotableCharacterSet +}; +var BrigadierStringOptions = { + escapable: {}, + quotes: ['"', "'"], + unquotable: BrigadierUnquotableOption +}; +var brigadierString = string4(BrigadierStringOptions); +function isAllowedCharacter(c, options2) { + return options2.allowList?.has(c) ?? !options2.blockList?.has(c); +} + +// node_modules/@spyglassmc/core/lib/parser/symbol.js +function symbol5(param) { + const options2 = getOptions2(param); + return (src, _ctx) => { + const ans = { + type: "symbol", + range: Range.create(src), + options: options2, + value: src.readRemaining() + }; + ans.range.end = src.cursor; + return ans; + }; +} +function getOptions2(param) { + if (typeof param === "string") { + return { category: param }; + } else { + return param; + } +} + +// node_modules/@spyglassmc/core/lib/common/externals/NodeJsExternals.js +var import_decompress = __toESM(require_decompress(), 1); +var import_node_buffer = require("node:buffer"); +var import_node_child_process = __toESM(require("node:child_process"), 1); +var import_node_fs = __toESM(require("node:fs"), 1); +var import_node_os = __toESM(require("node:os"), 1); +var import_node_process = __toESM(require("node:process"), 1); +var import_node_stream = __toESM(require("node:stream"), 1); +var import_node_url = __toESM(require("node:url"), 1); +var import_node_util = require("node:util"); +function getNodeJsExternals({ cacheRoot, nodeFsp = import_node_fs.promises } = {}) { + return Object.freeze({ + archive: { + decompressBall(buffer, options2) { + if (!(buffer instanceof import_node_buffer.Buffer)) { + buffer = import_node_buffer.Buffer.from(buffer); + } + return (0, import_decompress.default)(buffer, { strip: options2?.stripLevel }); + } + }, + error: { + createKind(kind, message2) { + const error4 = new Error(message2); + error4.code = kind; + return error4; + }, + isKind(e, kind) { + return e instanceof Error && e.code === kind; + } + }, + fs: { + chmod(location, mode) { + return nodeFsp.chmod(toFsPathLike(location), mode); + }, + async mkdir(location, options2) { + return void await nodeFsp.mkdir(toFsPathLike(location), options2); + }, + readdir(location) { + return nodeFsp.readdir(toFsPathLike(location), { + encoding: "utf-8", + withFileTypes: true + }); + }, + readFile(location) { + return nodeFsp.readFile(toFsPathLike(location)); + }, + rm(location, options2) { + return nodeFsp.rm(toFsPathLike(location), options2); + }, + async showFile(location) { + const execFile = (0, import_node_util.promisify)(import_node_child_process.default.execFile); + let command4; + switch (import_node_process.default.platform) { + case "darwin": + command4 = "open"; + break; + case "win32": + command4 = "explorer"; + break; + default: + command4 = "xdg-open"; + break; + } + return void await execFile(command4, [toPath(location)]); + }, + stat(location) { + return nodeFsp.stat(toFsPathLike(location)); + }, + unlink(location) { + return nodeFsp.unlink(toFsPathLike(location)); + }, + writeFile(location, data, options2) { + return nodeFsp.writeFile(toFsPathLike(location), data, options2); + } + }, + web: { + getCache: async () => { + return new HttpCache(cacheRoot); + } + } + }); +} +var NodeJsExternals = getNodeJsExternals(); +function toFsPathLike(path6) { + if (typeof path6 === "string" && path6.startsWith("file:")) { + return new import_node_url.default.URL(path6); + } + return path6; +} +function toPath(path6) { + if (typeof path6 === "string" && !path6.startsWith("file:")) { + return path6; + } + return uriToPath(path6); +} +var uriToPath = (uri) => import_node_url.default.fileURLToPath(uri); +var HttpCache = class { + #cacheRoot; + constructor(cacheRoot) { + if (cacheRoot) { + this.#cacheRoot = `${cacheRoot}http/`; + } + } + async match(request, _options) { + if (!this.#cacheRoot) { + return void 0; + } + const fileName = this.#getFileName(request); + try { + const etag = (await import_node_fs.promises.readFile(new URL(`${fileName}.etag`, this.#cacheRoot), "utf8")).trim(); + const bodyStream = import_node_fs.default.createReadStream(new URL(`${fileName}.bin`, this.#cacheRoot)); + return new Response( + import_node_stream.default.Readable.toWeb(bodyStream), + // \___/ + // stream Readable -> stream/web ReadableStream + // \_______________/ + // stream/web ReadableStream -> DOM ReadableStream + { headers: { etag } } + ); + } catch (e) { + if (e?.code === "ENOENT") { + return void 0; + } + throw e; + } + } + async put(request, response) { + const etag = response.headers.get("etag"); + if (!(this.#cacheRoot && response.body && etag)) { + return; + } + const fileName = this.#getFileName(request); + await import_node_fs.promises.mkdir(new URL(this.#cacheRoot), { recursive: true }); + await Promise.all([ + import_node_fs.promises.writeFile(new URL(`${fileName}.bin`, this.#cacheRoot), import_node_stream.default.Readable.fromWeb(response.body)), + import_node_fs.promises.writeFile(new URL(`${fileName}.etag`, this.#cacheRoot), `${etag}${import_node_os.default.EOL}`) + ]); + } + #getFileName(request) { + const uriString = request instanceof Request ? request.url : request.toString(); + return import_node_buffer.Buffer.from(uriString, "utf8").toString("base64url"); + } + async add() { + throw new Error("Method not implemented."); + } + async addAll() { + throw new Error("Method not implemented."); + } + async delete() { + throw new Error("Method not implemented."); + } + async keys() { + throw new Error("Method not implemented."); + } + async matchAll() { + throw new Error("Method not implemented."); + } +}; + +// node_modules/@spyglassmc/json/lib/checker/index.js +var checker_exports3 = {}; +__export(checker_exports3, { + index: () => index, + register: () => register, + typed: () => typed +}); + +// node_modules/@spyglassmc/mcdoc/lib/node/index.js +var ModuleNode; +(function(ModuleNode2) { + function is(node) { + return node?.type === "mcdoc:module"; + } + ModuleNode2.is = is; +})(ModuleNode || (ModuleNode = {})); +var TopLevelNode; +(function(TopLevelNode2) { + function is(node) { + return CommentNode.is(node) || DispatchStatementNode.is(node) || EnumNode.is(node) || InjectionNode.is(node) || StructNode.is(node) || TypeAliasNode.is(node) || UseStatementNode.is(node); + } + TopLevelNode2.is = is; +})(TopLevelNode || (TopLevelNode = {})); +var DispatchStatementNode; +(function(DispatchStatementNode2) { + function destruct(node) { + return { + attributes: node.children.filter(AttributeNode.is), + location: node.children.find(ResourceLocationNode.is), + index: node.children.find(IndexBodyNode.is), + target: node.children.find(TypeNode.is), + typeParams: node.children.find(TypeParamBlockNode.is) + }; + } + DispatchStatementNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:dispatch_statement"; + } + DispatchStatementNode2.is = is; +})(DispatchStatementNode || (DispatchStatementNode = {})); +var LiteralNode2; +(function(LiteralNode3) { + function is(node) { + return node?.type === "mcdoc:literal"; + } + LiteralNode3.is = is; +})(LiteralNode2 || (LiteralNode2 = {})); +var IndexBodyNode; +(function(IndexBodyNode2) { + function destruct(node) { + return { parallelIndices: node.children.filter(IndexNode.is) }; + } + IndexBodyNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:index_body"; + } + IndexBodyNode2.is = is; +})(IndexBodyNode || (IndexBodyNode = {})); +var IndexNode; +(function(IndexNode2) { + function is(node) { + return StaticIndexNode.is(node) || DynamicIndexNode.is(node); + } + IndexNode2.is = is; +})(IndexNode || (IndexNode = {})); +var StaticIndexNode; +(function(StaticIndexNode2) { + function is(node) { + return LiteralNode2.is(node) || IdentifierNode.is(node) || StringNode.is(node) || ResourceLocationNode.is(node); + } + StaticIndexNode2.is = is; +})(StaticIndexNode || (StaticIndexNode = {})); +var IdentifierNode; +(function(IdentifierNode2) { + function is(node) { + return node?.type === "mcdoc:identifier"; + } + IdentifierNode2.is = is; +})(IdentifierNode || (IdentifierNode = {})); +var DynamicIndexNode; +(function(DynamicIndexNode2) { + function destruct(node) { + return { keys: node.children.filter(AccessorKeyNode.is) }; + } + DynamicIndexNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:dynamic_index"; + } + DynamicIndexNode2.is = is; +})(DynamicIndexNode || (DynamicIndexNode = {})); +var AccessorKeyNode; +(function(AccessorKeyNode2) { + function is(node) { + return LiteralNode2.is(node) || IdentifierNode.is(node) || StringNode.is(node); + } + AccessorKeyNode2.is = is; +})(AccessorKeyNode || (AccessorKeyNode = {})); +var TypeNode; +(function(TypeNode2) { + function is(node) { + return AnyTypeNode.is(node) || BooleanTypeNode.is(node) || StringTypeNode.is(node) || LiteralTypeNode.is(node) || NumericTypeNode.is(node) || PrimitiveArrayTypeNode.is(node) || ListTypeNode.is(node) || TupleTypeNode.is(node) || EnumNode.is(node) || StructNode.is(node) || ReferenceTypeNode.is(node) || DispatcherTypeNode.is(node) || UnionTypeNode.is(node); + } + TypeNode2.is = is; +})(TypeNode || (TypeNode = {})); +var TypeBaseNode; +(function(TypeBaseNode2) { + function destruct(node) { + return { + appendixes: node.children.filter((n) => IndexBodyNode.is(n) || TypeArgBlockNode.is(n)), + attributes: node.children.filter(AttributeNode.is) + }; + } + TypeBaseNode2.destruct = destruct; +})(TypeBaseNode || (TypeBaseNode = {})); +var AttributeNode; +(function(AttributeNode2) { + function destruct(node) { + return { + name: node.children.find(IdentifierNode.is), + value: node.children.find(AttributeValueNode.is) + }; + } + AttributeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:attribute"; + } + AttributeNode2.is = is; +})(AttributeNode || (AttributeNode = {})); +var AttributeValueNode; +(function(AttributeValueNode2) { + function is(node) { + return TypeNode.is(node) || AttributeTreeNode.is(node); + } + AttributeValueNode2.is = is; +})(AttributeValueNode || (AttributeValueNode = {})); +var AttributeTreeNode; +(function(AttributeTreeNode2) { + function destruct(node) { + return { + positional: node.children.find(AttributeTreePosValuesNode.is), + named: node.children.find(AttributeTreeNamedValuesNode.is) + }; + } + AttributeTreeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:attribute/tree"; + } + AttributeTreeNode2.is = is; +})(AttributeTreeNode || (AttributeTreeNode = {})); +var AttributeTreePosValuesNode; +(function(AttributeTreePosValuesNode2) { + function destruct(node) { + return { values: node.children.filter(AttributeValueNode.is) }; + } + AttributeTreePosValuesNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:attribute/tree/pos"; + } + AttributeTreePosValuesNode2.is = is; +})(AttributeTreePosValuesNode || (AttributeTreePosValuesNode = {})); +var AttributeTreeNamedValuesNode; +(function(AttributeTreeNamedValuesNode2) { + function destruct(node) { + const ans = { values: [] }; + let key2; + for (const child of node.children) { + if (CommentNode.is(child)) { + continue; + } + if (IdentifierNode.is(child) || StringNode.is(child)) { + key2 = child; + } else if (key2) { + ans.values.push({ key: key2, value: child }); + key2 = void 0; + } + } + return ans; + } + AttributeTreeNamedValuesNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:attribute/tree/named"; + } + AttributeTreeNamedValuesNode2.is = is; +})(AttributeTreeNamedValuesNode || (AttributeTreeNamedValuesNode = {})); +var TypeArgBlockNode; +(function(TypeArgBlockNode2) { + function destruct(node) { + return { args: node.children.filter(TypeNode.is) }; + } + TypeArgBlockNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type_arg_block"; + } + TypeArgBlockNode2.is = is; +})(TypeArgBlockNode || (TypeArgBlockNode = {})); +var AnyTypeNode; +(function(AnyTypeNode2) { + function is(node) { + return node?.type === "mcdoc:type/any"; + } + AnyTypeNode2.is = is; +})(AnyTypeNode || (AnyTypeNode = {})); +var BooleanTypeNode; +(function(BooleanTypeNode2) { + function is(node) { + return node?.type === "mcdoc:type/boolean"; + } + BooleanTypeNode2.is = is; +})(BooleanTypeNode || (BooleanTypeNode = {})); +var IntRangeNode; +(function(IntRangeNode3) { + function destruct(node) { + return destructRangeNode(node); + } + IntRangeNode3.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:int_range"; + } + IntRangeNode3.is = is; +})(IntRangeNode || (IntRangeNode = {})); +var LongRangeNode; +(function(LongRangeNode2) { + function destruct(node) { + return destructRangeNode(node); + } + LongRangeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:long_range"; + } + LongRangeNode2.is = is; +})(LongRangeNode || (LongRangeNode = {})); +var LiteralTypeNode; +(function(LiteralTypeNode2) { + function destruct(node) { + return { value: node.children.find(LiteralTypeValueNode.is) }; + } + LiteralTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/literal"; + } + LiteralTypeNode2.is = is; +})(LiteralTypeNode || (LiteralTypeNode = {})); +var LiteralTypeValueNode; +(function(LiteralTypeValueNode2) { + function is(node) { + return LiteralNode2.is(node) || TypedNumberNode.is(node) || StringNode.is(node); + } + LiteralTypeValueNode2.is = is; +})(LiteralTypeValueNode || (LiteralTypeValueNode = {})); +var TypedNumberNode; +(function(TypedNumberNode2) { + function destruct(node) { + return { + value: node.children.find(FloatNode.is) ?? node.children.find(IntegerNode.is) ?? node.children.find(LongNode.is), + suffix: node.children.find(LiteralNode2.is) + }; + } + TypedNumberNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:typed_number"; + } + TypedNumberNode2.is = is; +})(TypedNumberNode || (TypedNumberNode = {})); +var NumericTypeNode; +(function(NumericTypeNode2) { + function destruct(node) { + return { + numericKind: node.children.find(LiteralNode2.is), + valueRange: node.children.find(FloatRangeNode.is) || node.children.find(IntRangeNode.is) || node.children.find(LongRangeNode.is) + }; + } + NumericTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/numeric_type"; + } + NumericTypeNode2.is = is; +})(NumericTypeNode || (NumericTypeNode = {})); +var RangeExclusiveChar = "<"; +var RangeKind; +(function(RangeKind2) { + function isLeftExclusive(rangeKind) { + return (rangeKind & 2) !== 0; + } + RangeKind2.isLeftExclusive = isLeftExclusive; + function isRightExclusive(rangeKind) { + return (rangeKind & 1) !== 0; + } + RangeKind2.isRightExclusive = isRightExclusive; +})(RangeKind || (RangeKind = {})); +function getRangeDelimiter(kind) { + const prefix = kind & 2 ? RangeExclusiveChar : ""; + const suffix = kind & 1 ? RangeExclusiveChar : ""; + return `${prefix}..${suffix}`; +} +function destructRangeNode(node) { + let kind; + let min2; + let max2; + if (node.children.length === 1) { + kind = 0; + min2 = max2 = node.children[0]; + } else if (node.children.length === 3) { + kind = getKind(node.children[1]); + min2 = node.children[0]; + max2 = node.children[2]; + } else if (LiteralNode2.is(node.children[0])) { + kind = getKind(node.children[0]); + max2 = node.children[1]; + } else { + kind = getKind(node.children[1]); + min2 = node.children[0]; + } + return { kind, min: min2, max: max2 }; + function getKind(delimiter) { + let ans = 0; + if (delimiter.value.startsWith(RangeExclusiveChar)) { + ans |= 2; + } + if (delimiter.value.endsWith(RangeExclusiveChar)) { + ans |= 1; + } + return ans; + } +} +var FloatRangeNode; +(function(FloatRangeNode2) { + function destruct(node) { + return destructRangeNode(node); + } + FloatRangeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:float_range"; + } + FloatRangeNode2.is = is; +})(FloatRangeNode || (FloatRangeNode = {})); +var PrimitiveArrayTypeNode; +(function(PrimitiveArrayTypeNode2) { + function destruct(node) { + let lengthRange; + let valueRange; + let afterBrackets = false; + for (const child of node.children) { + if (LiteralNode2.is(child) && child.value === "[]") { + afterBrackets = true; + } else if (LongRangeNode.is(child)) { + valueRange = child; + } else if (IntRangeNode.is(child)) { + if (afterBrackets) { + lengthRange = child; + } else { + valueRange = child; + } + } + } + return { arrayKind: node.children.find(LiteralNode2.is), lengthRange, valueRange }; + } + PrimitiveArrayTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/primitive_array"; + } + PrimitiveArrayTypeNode2.is = is; +})(PrimitiveArrayTypeNode || (PrimitiveArrayTypeNode = {})); +var ListTypeNode; +(function(ListTypeNode2) { + function destruct(node) { + return { + item: node.children.find(TypeNode.is), + lengthRange: node.children.find(IntRangeNode.is) + }; + } + ListTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/list"; + } + ListTypeNode2.is = is; +})(ListTypeNode || (ListTypeNode = {})); +var StringTypeNode; +(function(StringTypeNode2) { + function destruct(node) { + return { lengthRange: node.children.find(IntRangeNode.is) }; + } + StringTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/string"; + } + StringTypeNode2.is = is; +})(StringTypeNode || (StringTypeNode = {})); +var TupleTypeNode; +(function(TupleTypeNode2) { + function destruct(node) { + return { items: node.children.filter(TypeNode.is) }; + } + TupleTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/tuple"; + } + TupleTypeNode2.is = is; +})(TupleTypeNode || (TupleTypeNode = {})); +var EnumNode; +(function(EnumNode2) { + EnumNode2.Kinds = /* @__PURE__ */ new Set(["byte", "short", "int", "long", "float", "double", "string"]); + function destruct(node) { + return { + block: node.children.find(EnumBlockNode.is), + docComments: node.children.find(DocCommentsNode.is), + enumKind: getEnumKind(node), + identifier: node.children.find(IdentifierNode.is), + keyword: node.children.find(LiteralNode2.is) + }; + function getEnumKind(node2) { + for (const literal9 of node2.children.filter(LiteralNode2.is)) { + if (EnumNode2.Kinds.has(literal9.value)) { + return literal9.value; + } + } + return void 0; + } + } + EnumNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:enum"; + } + EnumNode2.is = is; +})(EnumNode || (EnumNode = {})); +var DocCommentsNode; +(function(DocCommentsNode2) { + function asText(node) { + if (!node) { + return void 0; + } + let comments = node.children.map((doc) => doc.comment); + if (comments.every((s) => !s.trim() || s.startsWith(" "))) { + comments = comments.map((s) => s.replace(/^ /, "")); + } + return comments.join("").trimEnd(); + } + DocCommentsNode2.asText = asText; + function is(node) { + return node?.type === "mcdoc:doc_comments"; + } + DocCommentsNode2.is = is; +})(DocCommentsNode || (DocCommentsNode = {})); +var EnumBlockNode; +(function(EnumBlockNode2) { + function destruct(node) { + return { fields: node.children.filter(EnumFieldNode.is) }; + } + EnumBlockNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:enum/block"; + } + EnumBlockNode2.is = is; +})(EnumBlockNode || (EnumBlockNode = {})); +var EnumFieldNode; +(function(EnumFieldNode2) { + function destruct(node) { + return { + attributes: node.children.filter(AttributeNode.is), + docComments: node.children.find(DocCommentsNode.is), + identifier: node.children.find(IdentifierNode.is), + value: node.children.find(EnumValueNode.is) + }; + } + EnumFieldNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:enum/field"; + } + EnumFieldNode2.is = is; +})(EnumFieldNode || (EnumFieldNode = {})); +var EnumValueNode; +(function(EnumValueNode2) { + function is(node) { + return TypedNumberNode.is(node) || StringNode.is(node); + } + EnumValueNode2.is = is; +})(EnumValueNode || (EnumValueNode = {})); +var PrelimNode; +(function(PrelimNode2) { + function is(node) { + return AttributeNode.is(node) || DocCommentsNode.is(node); + } + PrelimNode2.is = is; +})(PrelimNode || (PrelimNode = {})); +var StructNode; +(function(StructNode2) { + function destruct(node) { + return { + block: node.children.find(StructBlockNode.is), + docComments: node.children.find(DocCommentsNode.is), + identifier: node.children.find(IdentifierNode.is), + keyword: node.children.find(LiteralNode2.is) + }; + } + StructNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:struct"; + } + StructNode2.is = is; +})(StructNode || (StructNode = {})); +var ReferenceTypeNode; +(function(ReferenceTypeNode2) { + function destruct(node) { + return { path: node.children.find(PathNode.is) }; + } + ReferenceTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/reference"; + } + ReferenceTypeNode2.is = is; +})(ReferenceTypeNode || (ReferenceTypeNode = {})); +var TypeParamBlockNode; +(function(TypeParamBlockNode2) { + function destruct(node) { + return { params: node.children.filter(TypeParamNode.is) }; + } + TypeParamBlockNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type_param_block"; + } + TypeParamBlockNode2.is = is; +})(TypeParamBlockNode || (TypeParamBlockNode = {})); +var TypeParamNode; +(function(TypeParamNode2) { + function destruct(node) { + return { + // constraint: node.children.find(TypeNode.is), + identifier: node.children.find(IdentifierNode.is) + }; + } + TypeParamNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type_param"; + } + TypeParamNode2.is = is; +})(TypeParamNode || (TypeParamNode = {})); +var PathNode; +(function(PathNode2) { + function destruct(node) { + const lastChild = node?.children.at(-1); + return { + children: node?.children ?? [], + isAbsolute: node?.isAbsolute, + lastIdentifier: IdentifierNode.is(lastChild) ? lastChild : void 0 + }; + } + PathNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:path"; + } + PathNode2.is = is; +})(PathNode || (PathNode = {})); +var StructBlockNode; +(function(StructBlockNode2) { + function destruct(node) { + return { fields: node.children.filter(StructFieldNode.is) }; + } + StructBlockNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:struct/block"; + } + StructBlockNode2.is = is; +})(StructBlockNode || (StructBlockNode = {})); +var StructFieldNode; +(function(StructFieldNode2) { + function is(node) { + return StructPairFieldNode.is(node) || StructSpreadFieldNode.is(node); + } + StructFieldNode2.is = is; +})(StructFieldNode || (StructFieldNode = {})); +var StructPairFieldNode; +(function(StructPairFieldNode2) { + function destruct(node) { + return { + attributes: node.children.filter(AttributeNode.is), + docComments: node.children.find(DocCommentsNode.is), + key: node.children.find(StructKeyNode.is), + type: node.children.find(TypeNode.is), + isOptional: node.isOptional + }; + } + StructPairFieldNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:struct/field/pair"; + } + StructPairFieldNode2.is = is; +})(StructPairFieldNode || (StructPairFieldNode = {})); +var StructKeyNode; +(function(StructKeyNode2) { + function is(node) { + return StringNode.is(node) || IdentifierNode.is(node) || StructMapKeyNode.is(node); + } + StructKeyNode2.is = is; +})(StructKeyNode || (StructKeyNode = {})); +var StructMapKeyNode; +(function(StructMapKeyNode2) { + function destruct(node) { + return { type: node.children.find(TypeNode.is) }; + } + StructMapKeyNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:struct/map_key"; + } + StructMapKeyNode2.is = is; +})(StructMapKeyNode || (StructMapKeyNode = {})); +var StructSpreadFieldNode; +(function(StructSpreadFieldNode2) { + function destruct(node) { + return { + attributes: node.children.filter(AttributeNode.is), + type: node.children.find(TypeNode.is) + }; + } + StructSpreadFieldNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:struct/field/spread"; + } + StructSpreadFieldNode2.is = is; +})(StructSpreadFieldNode || (StructSpreadFieldNode = {})); +var DispatcherTypeNode; +(function(DispatcherTypeNode2) { + function destruct(node) { + return { + location: node.children.find(ResourceLocationNode.is), + index: node.children.find(IndexBodyNode.is) + }; + } + DispatcherTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/dispatcher"; + } + DispatcherTypeNode2.is = is; +})(DispatcherTypeNode || (DispatcherTypeNode = {})); +var UnionTypeNode; +(function(UnionTypeNode2) { + function destruct(node) { + return { members: node.children.filter(TypeNode.is) }; + } + UnionTypeNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type/union"; + } + UnionTypeNode2.is = is; +})(UnionTypeNode || (UnionTypeNode = {})); +var InjectionNode; +(function(InjectionNode2) { + function destruct(node) { + return { injection: node.children.find(InjectionContentNode.is) }; + } + InjectionNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:injection"; + } + InjectionNode2.is = is; +})(InjectionNode || (InjectionNode = {})); +var InjectionContentNode; +(function(InjectionContentNode2) { + function is(node) { + return EnumInjectionNode.is(node) || StructInjectionNode.is(node); + } + InjectionContentNode2.is = is; +})(InjectionContentNode || (InjectionContentNode = {})); +var EnumInjectionNode; +(function(EnumInjectionNode2) { + function is(node) { + return node?.type === "mcdoc:injection/enum"; + } + EnumInjectionNode2.is = is; +})(EnumInjectionNode || (EnumInjectionNode = {})); +var StructInjectionNode; +(function(StructInjectionNode2) { + function is(node) { + return node?.type === "mcdoc:injection/struct"; + } + StructInjectionNode2.is = is; +})(StructInjectionNode || (StructInjectionNode = {})); +var TypeAliasNode; +(function(TypeAliasNode2) { + function destruct(node) { + return { + attributes: node.children.filter(AttributeNode.is), + docComments: node.children.find(DocCommentsNode.is), + identifier: node.children.find(IdentifierNode.is), + keyword: node.children.find(LiteralNode2.is), + typeParams: node.children.find(TypeParamBlockNode.is), + rhs: node.children.find(TypeNode.is) + }; + } + TypeAliasNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:type_alias"; + } + TypeAliasNode2.is = is; +})(TypeAliasNode || (TypeAliasNode = {})); +var UseStatementNode; +(function(UseStatementNode2) { + function destruct(node) { + return { + binding: node.children.find(IdentifierNode.is), + path: node.children.find(PathNode.is) + }; + } + UseStatementNode2.destruct = destruct; + function is(node) { + return node?.type === "mcdoc:use_statement"; + } + UseStatementNode2.is = is; +})(UseStatementNode || (UseStatementNode = {})); + +// node_modules/@spyglassmc/mcdoc/lib/binder/index.js +var ModuleSymbolData; +(function(ModuleSymbolData2) { + function is(data) { + return !!data && typeof data === "object" && typeof data.nextAnonymousIndex === "number"; + } + ModuleSymbolData2.is = is; +})(ModuleSymbolData || (ModuleSymbolData = {})); +var TypeDefSymbolData; +(function(TypeDefSymbolData2) { + function is(data) { + return !!data && typeof data === "object" && typeof data.typeDef === "object"; + } + TypeDefSymbolData2.is = is; +})(TypeDefSymbolData || (TypeDefSymbolData = {})); +var fileModule = AsyncBinder.create(async (node, ctx) => { + const moduleIdentifier = uriToIdentifier(ctx.doc.uri, ctx); + if (!moduleIdentifier) { + ctx.err.report(localize("mcdoc.binder.out-of-root", localeQuote(ctx.doc.uri)), Range.Beginning, ErrorSeverity.Hint); + return; + } + const mcdocCtx = { ...ctx, moduleIdentifier }; + return module_(node, mcdocCtx); +}); +async function module_(node, ctx) { + const data = { nextAnonymousIndex: 0 }; + ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ctx.moduleIdentifier).amend({ + data: { data } + }); + hoist(node, { ...ctx, isHoisting: true }); + for (const child of node.children) { + switch (child.type) { + case "mcdoc:dispatch_statement": + await bindDispatchStatement(child, ctx); + break; + case "mcdoc:enum": + bindEnum(child, ctx); + break; + case "mcdoc:injection": + await bindInjection(child, ctx); + break; + case "mcdoc:struct": + await bindStruct(child, ctx); + break; + case "mcdoc:type_alias": + await bindTypeAlias(child, ctx); + break; + case "mcdoc:use_statement": + await bindUseStatement(child, ctx); + break; + } + } +} +function hoist(node, ctx) { + traversePreOrder(node, () => true, TopLevelNode.is, (child) => { + switch (child.type) { + case "mcdoc:enum": + hoistEnum(child); + break; + case "mcdoc:struct": + hoistStruct(child); + break; + case "mcdoc:type_alias": + hoistTypeAlias(child); + break; + case "mcdoc:use_statement": + hoistUseStatement(child); + break; + } + }); + function hoistEnum(node2) { + hoistFor("enum", node2, EnumNode.destruct, (n) => ({ typeDef: convertEnum(n, ctx) })); + } + function hoistStruct(node2) { + hoistFor("struct", node2, StructNode.destruct, (n) => ({ typeDef: convertStruct(n, ctx) })); + } + function hoistTypeAlias(node2) { + hoistFor("type_alias", node2, TypeAliasNode.destruct, (n) => { + const { attributes: attributes2, rhs, typeParams } = TypeAliasNode.destruct(n); + if (!rhs) { + return void 0; + } + const ans = { typeDef: convertType(rhs, ctx) }; + if (typeParams) { + bindTypeParamBlock(node2, typeParams, ans, ctx); + } + appendAttributes(ans.typeDef, attributes2, ctx); + return ans; + }); + } + function hoistUseStatement(node2) { + const { binding, path: path6 } = UseStatementNode.destruct(node2); + if (!path6) { + return; + } + const { lastIdentifier } = PathNode.destruct(path6); + const identifier4 = binding ?? lastIdentifier; + if (!identifier4) { + return; + } + const target = resolvePath(path6, ctx); + ctx.symbols.query({ doc: ctx.doc, node: node2 }, "mcdoc", `${ctx.moduleIdentifier}::${identifier4.value}`).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4)).elseEnter({ + data: { + subcategory: "use_statement_binding", + visibility: 1, + data: target ? { target } : void 0 + }, + usage: { type: "definition", node: identifier4, fullRange: node2 } + }); + } + function hoistFor(subcategory, node2, destructor, getData) { + const { docComments: docComments3, identifier: identifier4, keyword: keyword2 } = destructor(node2); + const name = identifier4?.value ?? nextAnonymousIdentifier(node2, ctx); + ctx.symbols.query({ doc: ctx.doc, node: node2 }, "mcdoc", `${ctx.moduleIdentifier}::${name}`).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4 ?? node2)).elseEnter({ + data: { data: getData(node2), desc: DocCommentsNode.asText(docComments3), subcategory }, + // If the current syntax structure is named, then the identifier node is entered as a definition; + // otherwise, an anonymous identifier is generated for the symbol and the keyword node is entered as a definition. + usage: { + type: "definition", + node: identifier4 ?? keyword2, + fullRange: identifier4 && node2 + } + }); + } + function nextAnonymousIndex(node2, ctx2) { + const data = ctx2.symbols.query({ doc: ctx2.doc, node: node2 }, "mcdoc", ctx2.moduleIdentifier).getData(ModuleSymbolData.is); + if (!data) { + throw new Error(`No symbol data for module '${ctx2.moduleIdentifier}'`); + } + return data.nextAnonymousIndex++; + } + function nextAnonymousIdentifier(node2, ctx2) { + return ``; + } +} +function bindTypeParamBlock(node, typeParams, data, ctx) { + node.locals = /* @__PURE__ */ Object.create(null); + data.typeDef = { kind: "template", child: data.typeDef, typeParams: [] }; + const { params } = TypeParamBlockNode.destruct(typeParams); + for (const param of params) { + const { identifier: paramIdentifier } = TypeParamNode.destruct(param); + if (paramIdentifier.value) { + const paramPath = `${ctx.moduleIdentifier}::${paramIdentifier.value}`; + ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", paramPath).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, paramIdentifier)).elseEnter({ + data: { + visibility: 0 + /* SymbolVisibility.Block */ + }, + usage: { type: "declaration", node: paramIdentifier, fullRange: param } + }); + data.typeDef.typeParams.push({ path: paramPath }); + } + } +} +async function bindDispatchStatement(node, ctx) { + const { attributes: attributes2, location, index: index4, target, typeParams } = DispatchStatementNode.destruct(node); + if (!(location && index4 && target)) { + return; + } + const locationStr = ResourceLocationNode.toString(location, "full"); + ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr).enter({ + usage: { type: "reference", node: location, fullRange: node } + }); + const { parallelIndices } = IndexBodyNode.destruct(index4); + if (parallelIndices.length) { + const data = { typeDef: convertType(target, ctx) }; + if (typeParams) { + bindTypeParamBlock(node, typeParams, data, ctx); + } + appendAttributes(data.typeDef, attributes2, ctx); + for (const key2 of parallelIndices) { + if (DynamicIndexNode.is(key2)) { + continue; + } + ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr, asString(key2)).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, key2, { + localeString: "mcdoc.binder.dispatcher-statement.duplicated-key" + })).elseEnter({ data: { data }, usage: { type: "definition", node: key2, fullRange: node } }); + } + } + await bindType(target, ctx); +} +async function bindType(node, ctx) { + if (DispatcherTypeNode.is(node)) { + await bindDispatcherType(node, ctx); + } else if (EnumNode.is(node)) { + bindEnum(node, ctx); + } else if (ListTypeNode.is(node)) { + const { item } = ListTypeNode.destruct(node); + await bindType(item, ctx); + } else if (ReferenceTypeNode.is(node)) { + const { path: path6 } = ReferenceTypeNode.destruct(node); + await bindPath(path6, ctx); + } else if (StructNode.is(node)) { + await bindStruct(node, ctx); + } else if (TupleTypeNode.is(node)) { + const { items } = TupleTypeNode.destruct(node); + for (const item of items) { + await bindType(item, ctx); + } + } else if (UnionTypeNode.is(node)) { + const { members } = UnionTypeNode.destruct(node); + for (const member of members) { + await bindType(member, ctx); + } + } + const { appendixes } = TypeBaseNode.destruct(node); + for (const appendix of appendixes) { + if (TypeArgBlockNode.is(appendix)) { + const { args } = TypeArgBlockNode.destruct(appendix); + for (const arg of args) { + await bindType(arg, ctx); + } + } + } +} +async function bindDispatcherType(node, ctx) { + const { index: index4, location } = DispatcherTypeNode.destruct(node); + const locationStr = ResourceLocationNode.toString(location, "full"); + ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr).enter({ + usage: { type: "reference", node: location, fullRange: node } + }); + const { parallelIndices } = IndexBodyNode.destruct(index4); + for (const key2 of parallelIndices) { + if (DynamicIndexNode.is(key2)) { + continue; + } + ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr, asString(key2)).enter({ + usage: { type: "reference", node: key2, fullRange: node } + }); + } +} +async function bindPath(node, ctx) { + for (const { identifiers, node: identNode, indexRight } of resolvePathByStep(node, ctx, { + reportErrors: true + })) { + if (!identifiers?.length) { + continue; + } + if (indexRight === 1) { + const referencedModuleFile = pathArrayToString(identifiers); + const referencedModuleUri = identifierToUri(referencedModuleFile, ctx); + if (!referencedModuleUri) { + ctx.err.report(localize("mcdoc.binder.path.unknown-module", localeQuote(referencedModuleFile)), node, ErrorSeverity.Warning); + return; + } + await ctx.ensureBindingStarted(referencedModuleUri); + } + ctx.symbols.query({ doc: ctx.doc, node: identNode }, "mcdoc", pathArrayToString(identifiers)).ifDeclared((_, query) => query.enter({ + usage: { + type: "reference", + node: identNode, + fullRange: node, + skipRenaming: LiteralNode2.is(identNode) + } + })).else(() => { + if (indexRight === 0) { + ctx.err.report(localize("mcdoc.binder.path.unknown-identifier", localeQuote(identifiers.at(-1)), localeQuote(pathArrayToString(identifiers.slice(0, -1)))), node, ErrorSeverity.Warning); + } + }); + } +} +function bindEnum(node, ctx) { + const { block: block4, identifier: identifier4, keyword: keyword2 } = EnumNode.destruct(node); + const symbol7 = identifier4?.symbol ?? keyword2.symbol; + if (symbol7?.subcategory !== "enum") { + return; + } + const query = ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ...symbol7.path); + Dev.assertDefined(query.symbol); + bindEnumBlock(block4, ctx, query); +} +function bindEnumBlock(node, ctx, query, options2 = {}) { + const { fields } = EnumBlockNode.destruct(node); + for (const field of fields) { + const { identifier: identifier4 } = EnumFieldNode.destruct(field); + query.member(identifier4.value, (fieldQuery) => fieldQuery.ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4)).elseEnter({ usage: { type: "definition", node: identifier4, fullRange: field } })); + } +} +async function bindInjection(node, ctx) { + const { injection: injection3 } = InjectionNode.destruct(node); + if (EnumInjectionNode.is(injection3)) { + } +} +async function bindStruct(node, ctx) { + const { block: block4, identifier: identifier4, keyword: keyword2 } = StructNode.destruct(node); + const symbol7 = identifier4?.symbol ?? keyword2.symbol; + if (symbol7?.subcategory !== "struct") { + return; + } + const query = ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ...symbol7.path); + Dev.assertDefined(query.symbol); + await bindStructBlock(block4, ctx, query); +} +async function bindStructBlock(node, ctx, query, options2 = {}) { + const { fields } = StructBlockNode.destruct(node); + for (const field of fields) { + if (StructPairFieldNode.is(field)) { + const { key: key2, type: type2 } = StructPairFieldNode.destruct(field); + if (!StructMapKeyNode.is(key2)) { + query.member(key2.value, (fieldQuery) => fieldQuery.ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, key2)).elseEnter({ usage: { type: "definition", node: key2, fullRange: field } })); + } + await bindType(type2, ctx); + } else { + const { type: type2 } = StructSpreadFieldNode.destruct(field); + await bindType(type2, ctx); + } + } +} +async function bindTypeAlias(node, ctx) { + const { identifier: identifier4, rhs, typeParams } = TypeAliasNode.destruct(node); + if (!identifier4?.value) { + return; + } + if (rhs) { + await bindType(rhs, ctx); + } +} +async function bindUseStatement(node, ctx) { + const { path: path6 } = UseStatementNode.destruct(node); + if (!path6) { + return; + } + return bindPath(path6, ctx); +} +function registerMcdocBinders(meta) { + meta.registerBinder("mcdoc:module", fileModule); +} +function reportDuplicatedDeclaration(ctx, symbol7, range3, options2 = { localeString: "mcdoc.binder.duplicated-declaration" }) { + ctx.err.report(localize(options2.localeString, localeQuote(symbol7.identifier)), range3, ErrorSeverity.Warning, { + related: [{ + location: SymbolUtil.getDeclaredLocation(symbol7), + message: localize(`${options2.localeString}.related`, localeQuote(symbol7.identifier)) + }] + }); +} +function* resolvePathByStep(path6, ctx, options2 = {}) { + const { children, isAbsolute } = PathNode.destruct(path6); + let identifiers = isAbsolute ? [] : pathStringToArray(ctx.moduleIdentifier); + for (const [i, child] of children.entries()) { + const indexRight = children.length - 1 - i; + switch (child.type) { + case "mcdoc:identifier": + identifiers.push(child.value); + if (indexRight === 0) { + ctx.symbols.query({ doc: ctx.doc, node: child }, "mcdoc", pathArrayToString(identifiers)).ifDeclared((symbol7) => { + const data = symbol7.data; + if (data?.target) { + identifiers = [...data.target]; + } + }); + } + break; + case "mcdoc:literal": + if (identifiers.length === 0) { + if (options2.reportErrors) { + ctx.err.report(localize("mcdoc.binder.path.super-from-root"), child); + } + return; + } + identifiers.pop(); + break; + default: + Dev.assertNever(child); + } + yield { identifiers, node: child, index: i, indexRight }; + } +} +function resolvePath(path6, ctx, options2 = {}) { + return [...resolvePathByStep(path6, ctx, options2)].at(-1)?.identifiers; +} +function identifierToUri(module3, ctx) { + return ctx.symbols.global.mcdoc?.[module3]?.definition?.[0]?.uri; +} +function uriToIdentifier(uri, ctx) { + return Object.values(ctx.symbols.global.mcdoc ?? {}).find((symbol7) => { + return symbol7.subcategory === "module" && symbol7.definition?.some((loc) => loc.uri === uri); + })?.identifier; +} +function pathArrayToString(path6) { + return path6 ? `::${path6.join("::")}` : void 0; +} +function pathStringToArray(path6) { + if (!path6.startsWith("::")) { + throw new Error("Only absolute paths are supported"); + } + return path6.slice(2).split("::"); +} +function convertType(node, ctx) { + switch (node.type) { + case "mcdoc:enum": + return convertEnum(node, ctx); + case "mcdoc:struct": + return convertStruct(node, ctx); + case "mcdoc:type/any": + return convertAny(node, ctx); + case "mcdoc:type/boolean": + return convertBoolean(node, ctx); + case "mcdoc:type/dispatcher": + return convertDispatcher(node, ctx); + case "mcdoc:type/list": + return convertList(node, ctx); + case "mcdoc:type/literal": + return convertLiteral(node, ctx); + case "mcdoc:type/numeric_type": + return convertNumericType(node, ctx); + case "mcdoc:type/primitive_array": + return convertPrimitiveArray(node, ctx); + case "mcdoc:type/string": + return convertString(node, ctx); + case "mcdoc:type/reference": + return convertReference(node, ctx); + case "mcdoc:type/tuple": + return convertTuple(node, ctx); + case "mcdoc:type/union": + return convertUnion(node, ctx); + default: + return Dev.assertNever(node); + } +} +function wrapType(node, type2, ctx, options2 = {}) { + const { attributes: attributes2, appendixes } = TypeBaseNode.destruct(node); + let ans = type2; + for (const appendix of appendixes) { + if (IndexBodyNode.is(appendix)) { + if (options2.skipFirstIndexBody) { + options2.skipFirstIndexBody = false; + continue; + } + ans = { kind: "indexed", child: ans, parallelIndices: convertIndexBody(appendix, ctx) }; + } else { + ans = { kind: "concrete", child: ans, typeArgs: convertTypeArgBlock(appendix, ctx) }; + } + } + ans.attributes = convertAttributes(attributes2, ctx); + return ans; +} +function appendAttributes(typeDef, attributes2, ctx) { + const convertedAttributes = convertAttributes(attributes2, ctx); + if (convertedAttributes) { + if (typeDef.attributes) { + typeDef.attributes = [...typeDef.attributes, ...convertedAttributes]; + } else { + typeDef.attributes = convertedAttributes; + } + } +} +function convertAttributes(nodes, ctx) { + return undefineEmptyArray(nodes.map((n) => convertAttribute(n, ctx))); +} +function undefineEmptyArray(array4) { + return array4.length ? array4 : void 0; +} +function convertAttribute(node, ctx) { + const { name, value } = AttributeNode.destruct(node); + return { name: name.value, value: value && convertAttributeValue(value, ctx) }; +} +function convertAttributeValue(node, ctx) { + if (node.type === "mcdoc:attribute/tree") { + return { kind: "tree", values: convertAttributeTree(node, ctx) }; + } else { + return convertType(node, ctx); + } +} +function convertAttributeTree(node, ctx) { + const ans = {}; + const { named, positional } = AttributeTreeNode.destruct(node); + if (positional) { + const { values } = AttributeTreePosValuesNode.destruct(positional); + for (const [i, child] of values.entries()) { + ans[i] = convertAttributeValue(child, ctx); + } + } + if (named) { + const { values } = AttributeTreeNamedValuesNode.destruct(named); + for (const { key: key2, value } of values) { + ans[key2.value] = convertAttributeValue(value, ctx); + } + } + return ans; +} +function convertIndexBody(node, ctx) { + const { parallelIndices } = IndexBodyNode.destruct(node); + return parallelIndices.map((n) => convertIndex(n, ctx)); +} +function convertIndex(node, ctx) { + return StaticIndexNode.is(node) ? convertStaticIndex(node, ctx) : convertDynamicIndex(node, ctx); +} +function convertStaticIndex(node, ctx) { + return { kind: "static", value: asString(node) }; +} +function convertDynamicIndex(node, ctx) { + const { keys } = DynamicIndexNode.destruct(node); + return { + kind: "dynamic", + accessor: keys.map((key2) => { + if (LiteralNode2.is(key2) && key2.value.startsWith("%")) { + return { keyword: key2.value.slice(1) }; + } + return asString(key2); + }) + }; +} +function convertTypeArgBlock(node, ctx) { + const { args } = TypeArgBlockNode.destruct(node); + return args.map((a) => convertType(a, ctx)); +} +function convertEnum(node, ctx) { + const { block: block4, enumKind, identifier: identifier4 } = EnumNode.destruct(node); + if (identifier4 && !ctx.isHoisting) { + return wrapType(node, { + kind: "reference", + path: `${ctx.moduleIdentifier}::${identifier4.value}` + }, ctx); + } + const symbol7 = identifier4?.symbol ?? node.symbol; + if (symbol7 && TypeDefSymbolData.is(symbol7.data) && symbol7.data.typeDef.kind === "enum") { + return symbol7.data.typeDef; + } + switch (enumKind) { + case "byte": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumIntValue(enumKind, "b"), ctx) + }, ctx); + case "short": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumIntValue(enumKind, "s"), ctx) + }, ctx); + case "int": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumIntValue(enumKind), ctx) + }, ctx); + case "long": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumLongValue, ctx) + }, ctx); + case "float": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumFloatValue(enumKind, "f"), ctx) + }, ctx); + case "double": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumFloatValue(enumKind, "d"), ctx) + }, ctx); + case "string": + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumStringValue, ctx) + }, ctx); + case void 0: + return wrapType(node, { + kind: "enum", + enumKind, + values: convertEnumBlock(block4, convertEnumValue, ctx) + }, ctx); + } +} +function convertEnumBlock(node, getEnumFieldValue, ctx) { + const { fields } = EnumBlockNode.destruct(node); + return fields.map((n) => convertEnumField(n, getEnumFieldValue, ctx)); +} +function convertEnumField(node, getEnumFieldValue, ctx) { + const { attributes: attributes2, docComments: docComments3, identifier: identifier4, value } = EnumFieldNode.destruct(node); + return { + attributes: convertAttributes(attributes2, ctx), + desc: DocCommentsNode.asText(docComments3), + identifier: identifier4.value, + value: getEnumFieldValue(value, ctx) + }; +} +function convertEnumIntValue(expected, expectedSuffix) { + return (node, ctx) => { + const { value: valueNode, suffix: suffixNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; + const value = Math.floor(typeof valueNode.value === "string" ? Number.parseFloat(valueNode.value) : Number(valueNode.value)); + const suffix = suffixNode?.value.toLowerCase(); + if (suffix !== expectedSuffix || !IntegerNode.is(valueNode)) { + ctx.err.report(localize("expected", localize(expected)), node); + } + return value; + }; +} +function convertEnumFloatValue(expected, expectedSuffix) { + return (node, ctx) => { + const { value: valueNode, suffix: suffixNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; + const value = typeof valueNode.value === "string" ? Number.parseFloat(valueNode.value) : Number(valueNode.value); + const suffix = suffixNode?.value.toLowerCase(); + if (suffix !== expectedSuffix && (expectedSuffix !== "d" || suffix !== void 0 || !FloatNode.is(valueNode))) { + ctx.err.report(localize("expected", localize(expected)), node); + } + return value; + }; +} +function convertEnumStringValue(node, ctx) { + const { value: valueNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; + const value = typeof valueNode.value === "string" ? valueNode.value : valueNode.value.toString(); + if (!StringNode.is(valueNode)) { + ctx.err.report(localize("expected", localize("string")), node); + } + return value; +} +function convertEnumLongValue(node, ctx) { + const { value: valueNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; + let value = valueNode.value; + if (typeof value === "string") { + if (/^-?\d+$/.test(value)) { + value = BigInt(value); + } else { + value = parseFloat(value); + } + } + if (typeof value === "number") { + if (isNaN(value) || !isFinite(value)) { + value = 0n; + } else { + value = BigInt(Math.floor(value)); + } + } + if (!LongNode.is(valueNode)) { + ctx.err.report(localize("expected", localize("long")), node); + } + return value; +} +function convertEnumValue(node, ctx) { + const { value } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; + return value.value; +} +function convertStruct(node, ctx) { + const { block: block4, identifier: identifier4 } = StructNode.destruct(node); + if (identifier4 && !ctx.isHoisting) { + return wrapType(node, { + kind: "reference", + path: `${ctx.moduleIdentifier}::${identifier4.value}` + }, ctx); + } + const symbol7 = identifier4?.symbol ?? node.symbol; + if (symbol7 && TypeDefSymbolData.is(symbol7.data) && symbol7.data.typeDef.kind === "struct") { + return symbol7.data.typeDef; + } + return wrapType(node, { kind: "struct", fields: convertStructBlock(block4, ctx) }, ctx); +} +function convertStructBlock(node, ctx) { + const { fields } = StructBlockNode.destruct(node); + return fields.map((n) => convertStructField(n, ctx)); +} +function convertStructField(node, ctx) { + return StructPairFieldNode.is(node) ? convertStructPairField(node, ctx) : convertStructSpreadField(node, ctx); +} +function convertStructPairField(node, ctx) { + const { attributes: attributes2, docComments: docComments3, key: key2, type: type2, isOptional } = StructPairFieldNode.destruct(node); + return { + kind: "pair", + attributes: convertAttributes(attributes2, ctx), + desc: DocCommentsNode.asText(docComments3), + key: convertStructKey(key2, ctx), + type: convertType(type2, ctx), + optional: isOptional + }; +} +function convertStructKey(node, ctx) { + if (StructMapKeyNode.is(node)) { + const { type: type2 } = StructMapKeyNode.destruct(node); + return convertType(type2, ctx); + } else { + return asString(node); + } +} +function convertStructSpreadField(node, ctx) { + const { attributes: attributes2, type: type2 } = StructSpreadFieldNode.destruct(node); + return { + kind: "spread", + attributes: convertAttributes(attributes2, ctx), + type: convertType(type2, ctx) + }; +} +function convertAny(node, ctx) { + return wrapType(node, { kind: "any" }, ctx); +} +function convertBoolean(node, ctx) { + return wrapType(node, { kind: "boolean" }, ctx); +} +function convertDispatcher(node, ctx) { + const { index: index4, location } = DispatcherTypeNode.destruct(node); + return wrapType(node, { + kind: "dispatcher", + parallelIndices: convertIndexBody(index4, ctx), + registry: ResourceLocationNode.toString(location, "full") + }, ctx, { skipFirstIndexBody: true }); +} +function convertList(node, ctx) { + const { item, lengthRange } = ListTypeNode.destruct(node); + return wrapType(node, { + kind: "list", + item: convertType(item, ctx), + lengthRange: convertRange(lengthRange) + }, ctx); +} +function convertRange(node) { + if (!node) { + return void 0; + } + if (LongRangeNode.is(node)) { + const { kind: kind2, min: min3, max: max3 } = LongRangeNode.destruct(node); + return { kind: kind2, min: min3?.value, max: max3?.value }; + } + const { kind, min: min2, max: max2 } = FloatRangeNode.is(node) ? FloatRangeNode.destruct(node) : IntRangeNode.destruct(node); + return { kind, min: min2?.value, max: max2?.value }; +} +function convertLiteral(node, ctx) { + const { value } = LiteralTypeNode.destruct(node); + return wrapType(node, { kind: "literal", value: convertLiteralValue(value, ctx) }, ctx); +} +function convertLiteralValue(node, ctx) { + if (LiteralNode2.is(node)) { + return { kind: "boolean", value: node.value === "true" }; + } else if (TypedNumberNode.is(node)) { + const { suffix, value } = TypedNumberNode.destruct(node); + return { + kind: convertLiteralNumberSuffix(suffix, ctx) ?? (value.type === "integer" ? "int" : "double"), + value: value.value + }; + } else { + return { kind: "string", value: node.value }; + } +} +function convertLiteralNumberSuffix(node, ctx) { + const suffix = node?.value; + switch (suffix?.toLowerCase()) { + case "b": + return "byte"; + case "s": + return "short"; + case "l": + return "long"; + case "f": + return "float"; + case "d": + return "double"; + default: + return void 0; + } +} +function convertNumericType(node, ctx) { + const { numericKind, valueRange } = NumericTypeNode.destruct(node); + return wrapType(node, { + kind: numericKind.value, + valueRange: convertRange(valueRange) + }, ctx); +} +function convertPrimitiveArray(node, ctx) { + const { arrayKind, lengthRange, valueRange } = PrimitiveArrayTypeNode.destruct(node); + return wrapType(node, { + kind: `${arrayKind.value}_array`, + lengthRange: convertRange(lengthRange), + valueRange: convertRange(valueRange) + }, ctx); +} +function convertString(node, ctx) { + const { lengthRange } = StringTypeNode.destruct(node); + return wrapType(node, { kind: "string", lengthRange: convertRange(lengthRange) }, ctx); +} +function convertReference(node, ctx) { + const { path: path6 } = ReferenceTypeNode.destruct(node); + return wrapType(node, { kind: "reference", path: pathArrayToString(resolvePath(path6, ctx)) }, ctx); +} +function convertTuple(node, ctx) { + const { items } = TupleTypeNode.destruct(node); + return wrapType(node, { kind: "tuple", items: items.map((n) => convertType(n, ctx)) }, ctx); +} +function convertUnion(node, ctx) { + const { members } = UnionTypeNode.destruct(node); + return wrapType(node, { kind: "union", members: members.map((n) => convertType(n, ctx)) }, ctx); +} +function asString(node) { + if (ResourceLocationNode.is(node)) { + return ResourceLocationNode.toString(node, "short"); + } + return node.value; +} + +// node_modules/@spyglassmc/mcdoc/lib/checker/index.js +var reference = (node, ctx) => { + const { path: path6 } = ReferenceTypeNode.destruct(node); + const { children } = PathNode.destruct(path6); + const symbol7 = children.findLast((c) => c.symbol && c.symbol.category === "mcdoc" && c.symbol.subcategory !== "module")?.symbol; + if (!TypeDefSymbolData.is(symbol7?.data)) { + return; + } + const { appendixes } = TypeBaseNode.destruct(node); + let typeArgs = []; + if (TypeArgBlockNode.is(appendixes[0])) { + const { args } = TypeArgBlockNode.destruct(appendixes[0]); + typeArgs = args; + } + let typeParams = []; + if (symbol7.data.typeDef.kind === "template") { + typeParams = symbol7.data.typeDef.typeParams; + } + if (typeParams.length !== typeArgs.length) { + ctx.err.report(localize("mcdoc.checker.reference.unexpected-number-of-type-arguments", symbol7.identifier, typeParams.length, typeArgs.length), node); + } +}; +function registerMcdocChecker(meta) { + meta.registerChecker("mcdoc:type/reference", reference); +} + +// node_modules/@spyglassmc/mcdoc/lib/colorizer/index.js +var identifier = (node) => { + return [ColorToken.create(node, "variable")]; +}; +var literal5 = (node) => { + return [ColorToken.create(node, node.colorTokenType ?? "literal")]; +}; +function registerMcdocColorizer(meta) { + meta.registerColorizer("mcdoc:literal", literal5); + meta.registerColorizer("mcdoc:identifier", identifier); +} + +// node_modules/@spyglassmc/mcdoc/lib/type/index.js +var Attributes; +(function(Attributes2) { + function equals(a, b) { + if (a?.length !== b?.length) { + return false; + } + if (!a || !b) { + return true; + } + for (let i = 0; i < a.length; i++) { + if (!Attribute.equals(a[i], b[i])) { + return false; + } + } + return true; + } + Attributes2.equals = equals; +})(Attributes || (Attributes = {})); +var Attribute; +(function(Attribute2) { + function equals(a, b) { + if (a.name !== b.name) { + return false; + } + if (a.value && b.value) { + return AttributeValue.equals(a.value, b.value); + } + return a.value === b.value; + } + Attribute2.equals = equals; +})(Attribute || (Attribute = {})); +var AttributeValue; +(function(AttributeValue2) { + function equals(a, b) { + if (a.kind !== b.kind) { + return false; + } + if (a.kind === "tree") { + if (Object.keys(a.values).length !== Object.keys(b.values).length) { + return false; + } + for (const kvp of Object.entries(a.values)) { + const other = b.values[kvp[0]]; + if (!other) { + return false; + } + if (!equals(kvp[1], other)) { + return false; + } + } + return true; + } else { + return McdocType.equals(a, b); + } + } + AttributeValue2.equals = equals; +})(AttributeValue || (AttributeValue = {})); +var NumericRange; +(function(NumericRange2) { + function isInRange(range3, val) { + const { min: min2 = -Infinity, max: max2 = Infinity } = range3; + if (RangeKind.isLeftExclusive(range3.kind) ? val <= min2 : val < min2) { + return false; + } + if (RangeKind.isRightExclusive(range3.kind) ? val >= max2 : val > max2) { + return false; + } + return true; + } + NumericRange2.isInRange = isInRange; + function equals(a, b) { + return a.kind === b.kind && numericEquals(a.min, b.min) && numericEquals(a.max, b.max); + } + NumericRange2.equals = equals; + function intersect(a, b) { + const rangeMin = a.min !== void 0 && b.min !== void 0 ? max(a.min, b.min) : a.min ?? b.min; + const rangeMax = a.max !== void 0 && b.max !== void 0 ? min(a.max, b.max) : a.max ?? b.max; + let kind = 0; + if (numericEquals(rangeMin, a.min) && RangeKind.isLeftExclusive(a.kind)) { + kind |= 2; + } else if (numericEquals(rangeMin, b.min) && RangeKind.isLeftExclusive(b.kind)) { + kind |= 2; + } + if (numericEquals(rangeMax, a.max) && RangeKind.isRightExclusive(a.kind)) { + kind |= 1; + } else if (numericEquals(rangeMax, b.max) && RangeKind.isRightExclusive(b.kind)) { + kind |= 1; + } + return { kind, min: rangeMin, max: rangeMax }; + } + NumericRange2.intersect = intersect; + function toString({ kind, min: min2, max: max2 }) { + return min2 === max2 && kind === 0 ? min2 !== void 0 ? `${min2}` : getRangeDelimiter(kind) : `${min2 ?? ""}${getRangeDelimiter(kind)}${max2 ?? ""}`; + } + NumericRange2.toString = toString; +})(NumericRange || (NumericRange = {})); +var StaticIndexKeywords = Object.freeze(["fallback", "none", "unknown", "spawnitem", "blockitem"]); +var ParallelIndices; +(function(ParallelIndices2) { + function equals(a, b) { + if (a.length !== b.length) { + return false; + } + for (let i = 0; i < a.length; i++) { + const first = a[i]; + const second = b[i]; + if (first.kind !== second.kind) { + return false; + } + if (first.kind === "static") { + return first.value !== second.value; + } + if (first.accessor.length !== second.accessor.length) { + return false; + } + for (let j = 0; j < first.accessor.length; j++) { + const firstAcc = first.accessor[j]; + const secondAcc = second.accessor[j]; + if (typeof firstAcc === "string" || typeof secondAcc === "string") { + if (firstAcc !== secondAcc) { + return false; + } + } else if (firstAcc.keyword !== secondAcc.keyword) { + return false; + } + } + } + return true; + } + ParallelIndices2.equals = equals; +})(ParallelIndices || (ParallelIndices = {})); +var EmptyUnion = Object.freeze({ kind: "union", members: [] }); +var LiteralNumericValue; +(function(LiteralNumericValue2) { + function makeIfValid(kind, value, allowInt = true, allowFloat = true) { + value = Number(value); + switch (kind) { + case "byte": + if (allowInt && value >= -128 && value < 128) { + return { kind: "byte", value }; + } + break; + case "short": + if (allowInt && value >= -32768 && value < 32768) { + return { kind: "short", value }; + } + break; + case "int": + if (allowInt && value >= -2147483648 && value < 2147483648) { + return { kind: "int", value }; + } + break; + case "long": + if (allowInt && value >= -9223372036854775808n && value < 9223372036854775808n) { + return { kind: "long", value: BigInt(value) }; + } + break; + case "float": + if (allowFloat) { + return { kind: "float", value }; + } + break; + case "double": + if (allowFloat) { + return { kind: "double", value }; + } + break; + } + return void 0; + } + LiteralNumericValue2.makeIfValid = makeIfValid; +})(LiteralNumericValue || (LiteralNumericValue = {})); +var NumericTypeIntKinds = Object.freeze(["byte", "short", "int", "long"]); +var NumericTypeFloatKinds = Object.freeze(["float", "double"]); +var NumericTypeKinds = Object.freeze([...NumericTypeIntKinds, ...NumericTypeFloatKinds]); +var PrimitiveArrayValueKinds = Object.freeze(["byte", "int", "long"]); +var PrimitiveArrayKinds = Object.freeze(PrimitiveArrayValueKinds.map((kind) => `${kind}_array`)); +var McdocType; +(function(McdocType2) { + function equals(a, b) { + if (a.kind !== b.kind) { + return false; + } + if (!Attributes.equals(a.attributes, b.attributes)) { + return false; + } + switch (a.kind) { + case "literal": + return a.value.kind === b.value.kind && a.value.value === b.value.value; + case "byte": + case "short": + case "int": + case "long": + case "float": + case "double": + return a.valueRange === b.valueRange; + case "string": + return a.lengthRange === b.lengthRange; + case "byte_array": + case "int_array": + case "long_array": + return a.lengthRange === b.lengthRange && a.valueRange === b.valueRange; + case "list": + return a.lengthRange === b.lengthRange && equals(a.item, b.item); + case "tuple": + if (a.items.length !== b.items.length) { + return false; + } + for (let i = 0; i < a.items.length; i++) { + if (!equals(a.items[i], b.items[i])) { + return false; + } + } + return true; + case "struct": + return a.fields.length === b.fields.length && !a.fields.some((f) => { + if (f.kind === "pair") { + return !b.fields.some((of) => of.kind === "pair" && f.optional === of.optional && f.deprecated === of.deprecated && Attributes.equals(f.attributes, of.attributes) && (typeof f.key === "string" || typeof of.key === "string" ? f.key === of.key : equals(f.key, of.key)) && equals(f.type, of.type)); + } + return !b.fields.some((of) => of.kind === "spread" && Attributes.equals(f.attributes, of.attributes) && equals(f.type, of.type)); + }); + case "union": + if (a.members.length !== b.members.length) { + return false; + } + for (let i = 0; i < a.members.length; i++) { + if (!equals(a.members[i], b.members[i])) { + return false; + } + } + return true; + case "enum": + if (a.enumKind !== b.enumKind || a.values.length !== b.values.length) { + return false; + } + for (let i = 0; i < a.values.length; i++) { + const first = a.values[i]; + const second = b.values[i]; + if (first.identifier !== second.identifier || first.value !== second.value || !Attributes.equals(first.attributes, second.attributes)) { + return false; + } + } + return true; + case "reference": + return a.path === b.path; + case "template": + if (a.typeParams.length !== b.typeParams.length) { + return false; + } + for (let i = 0; i < a.typeParams.length; i++) { + if (a.typeParams[i].path !== b.typeParams[i].path) { + return false; + } + } + return equals(a.child, b.child); + case "concrete": + if (a.typeArgs.length !== b.typeArgs.length) { + return false; + } + for (let i = 0; i < a.typeArgs.length; i++) { + if (!equals(a.typeArgs[i], b.typeArgs[i])) { + return false; + } + } + return equals(a.child, b.child); + case "indexed": + if (ParallelIndices.equals(a.parallelIndices, b.parallelIndices)) { + return false; + } + return equals(a.child, b.child); + case "dispatcher": + if (a.registry !== b.registry) { + return false; + } + return ParallelIndices.equals(a.parallelIndices, b.parallelIndices); + case "mapped": + if (Object.keys(a.mapping).length !== Object.keys(b.mapping).length) { + return false; + } + for (const kvp of Object.entries(a.mapping)) { + const other = b.mapping[kvp[0]]; + if (!other) { + return false; + } + if (!equals(kvp[1], other)) { + return false; + } + } + return equals(a.child, b.child); + default: + return true; + } + } + McdocType2.equals = equals; + function toString(type2) { + const rangeToString = (range3) => { + return range3 ? ` @ ${NumericRange.toString(range3)}` : ""; + }; + const indicesToString = (indices) => { + const strings = []; + for (const index4 of Arrayable.toArray(indices)) { + if (index4 === void 0) { + strings.push("()"); + } else { + strings.push(index4.kind === "static" ? `[${index4.value}]` : `[[${index4.accessor.map((v) => typeof v === "string" ? v : v.keyword).join(".")}]]`); + } + } + return `[${strings.join(", ")}]`; + }; + if (type2 === void 0) { + return ""; + } + let attributesString = ""; + if (type2.attributes?.length) { + for (const attribute3 of type2.attributes) { + attributesString += `#[${attribute3.name}${attribute3.value ? "=" : ""}] `; + } + } + let typeString; + switch (type2.kind) { + case "any": + case "boolean": + typeString = type2.kind; + break; + case "byte": + typeString = `byte${rangeToString(type2.valueRange)}`; + break; + case "byte_array": + typeString = `byte${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; + break; + case "concrete": + typeString = `${toString(type2.child)}${type2.typeArgs.length ? `<${type2.typeArgs.map(toString).join(", ")}>` : ""}`; + break; + case "dispatcher": + typeString = `${type2.registry ?? "spyglass:unknown"}[${indicesToString(type2.parallelIndices)}]`; + break; + case "double": + typeString = `double${rangeToString(type2.valueRange)}`; + break; + case "enum": + typeString = ""; + break; + case "float": + typeString = `float${rangeToString(type2.valueRange)}`; + break; + case "indexed": + typeString = `${toString(type2.child)}${indicesToString(type2.parallelIndices)}`; + break; + case "int": + typeString = `int${rangeToString(type2.valueRange)}`; + break; + case "int_array": + typeString = `int${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; + break; + case "list": + typeString = `[${toString(type2.item)}]${rangeToString(type2.lengthRange)}`; + break; + case "literal": + typeString = `${type2.value.value}`; + break; + case "long": + typeString = `long${rangeToString(type2.valueRange)}`; + break; + case "long_array": + typeString = `long${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; + break; + case "mapped": + typeString = toString(type2.child); + break; + case "reference": + typeString = type2.path ?? ""; + break; + case "short": + typeString = `short${rangeToString(type2.valueRange)}`; + break; + case "string": + typeString = `string${rangeToString(type2.lengthRange)}`; + break; + case "struct": + typeString = ""; + break; + case "template": + typeString = `${toString(type2.child)}${type2.typeParams.length ? `<${type2.typeParams.map((v) => `?${v.path}`).join(", ")}>` : ""}`; + break; + case "tuple": + typeString = `[${type2.items.map((v) => toString(v)).join(",")}${type2.items.length === 1 ? "," : ""}]`; + break; + case "union": + typeString = `(${type2.members.map(toString).join(" | ")})`; + break; + case "unsafe": + typeString = "unsafe"; + break; + default: + Dev.assertNever(type2); + } + return attributesString + typeString; + } + McdocType2.toString = toString; +})(McdocType || (McdocType = {})); + +// node_modules/@spyglassmc/mcdoc/lib/parser/index.js +var comment4 = validate(comment3({ singleLinePrefixes: /* @__PURE__ */ new Set(["//"]) }), (res, src) => !src.slice(res).startsWith("///"), localize("mcdoc.parser.syntax.doc-comment-unexpected")); +function syntaxGap(delegatesDocComments = false) { + return (src, ctx) => { + const ans = []; + src.skipWhitespace(); + while (src.canRead() && src.peek(2) === "//" && (!delegatesDocComments || src.peek(3) !== "///")) { + const result = comment4(src, ctx); + ans.push(result); + src.skipWhitespace(); + } + return ans; + }; +} +function syntax(parsers, delegatesDocComments = false) { + return (src, ctx) => { + src.skipWhitespace(); + const ans = sequence(parsers, syntaxGap(delegatesDocComments))(src, ctx); + src.skipWhitespace(); + return ans; + }; +} +function syntaxRepeat(parser, delegatesDocComments = false) { + return repeat(parser, syntaxGap(delegatesDocComments)); +} +function literal6(literal9, options2) { + return (src, ctx) => { + const ans = { + type: "mcdoc:literal", + range: Range.create(src), + value: "", + colorTokenType: options2?.colorTokenType + }; + ans.value = src.readIf((c) => options2?.allowedChars?.has(c) ?? (options2?.specialChars?.has(c) || /[a-z]/i.test(c))); + ans.range.end = src.cursor; + if (Arrayable.toArray(literal9).every((l) => l !== ans.value)) { + ctx.err.report(localize("expected-got", arrayToMessage(literal9), localeQuote(ans.value)), ans); + } + return ans; + }; +} +function keyword(keyword2, options2 = { colorTokenType: "keyword" }) { + return (src, ctx) => { + const result = literal6(keyword2, options2)(src, ctx); + if (!Arrayable.toArray(keyword2).includes(result.value)) { + return Failure; + } + return result; + }; +} +function punctuation(punctuation2) { + return (src, ctx) => { + src.skipWhitespace(); + if (!src.trySkip(punctuation2)) { + ctx.err.report(localize("expected-got", localeQuote(punctuation2), localeQuote(src.peek())), src); + } + return void 0; + }; +} +function marker(punctuation2) { + return (src, _ctx) => { + src.skipWhitespace(); + if (!src.trySkip(punctuation2)) { + return Failure; + } + return void 0; + }; +} +function resLoc(options2) { + return validate(resourceLocation6(options2), (res) => res.namespace !== void 0, localize("mcdoc.parser.resource-location.colon-expected", localeQuote(ResourceLocation.NamespacePathSep))); +} +var UnicodeControlCharacters = Object.freeze([ + "\0", + "", + "", + "", + "", + "", + "", + "\x07", + "\b", + " ", + "\n", + "\v", + "\f", + "\r", + "", + "", + "\x7F" +]); +var string5 = stopBefore(string4({ + escapable: { characters: ["b", "f", "n", "r", "t", "\\", '"'], unicode: true }, + quotes: ['"'] +}), ...UnicodeControlCharacters); +var identifier2 = (src, ctx) => { + const IdentifierStart = /^[\p{L}\p{Nl}]$/u; + const IdentifierContinue = /^[\p{L}\p{Nl}\u200C\u200D\p{Mn}\p{Mc}\p{Nd}\p{Pc}]$/u; + const ReservedWords = /* @__PURE__ */ new Set([ + "any", + "boolean", + "byte", + "double", + "enum", + "false", + "float", + "int", + "long", + "short", + "string", + "struct", + "super", + "true" + ]); + const ans = { + type: "mcdoc:identifier", + range: Range.create(src), + options: { category: "mcdoc" }, + value: "" + }; + const start = src.innerCursor; + if (IdentifierStart.test(src.peek())) { + src.skip(); + while (IdentifierContinue.test(src.peek())) { + src.skip(); + } + } else { + ctx.err.report(localize("expected", localize("mcdoc.node.identifier")), src); + } + ans.value = src.string.slice(start, src.innerCursor); + ans.range.end = src.cursor; + if (ReservedWords.has(ans.value)) { + ctx.err.report(localize("mcdoc.parser.identifier.reserved-word", localeQuote(ans.value)), ans); + } + return ans; +}; +function indexBody(options2) { + const accessorKey = select([ + { prefix: "%", parser: literal6(["%key", "%parent"], { specialChars: /* @__PURE__ */ new Set(["%"]) }) }, + { prefix: '"', parser: string5 }, + { parser: identifier2 } + ]); + const dynamicIndex2 = setType("mcdoc:dynamic_index", syntax([ + punctuation("["), + accessorKey, + repeat(sequence([marker("."), accessorKey])), + punctuation("]") + ])); + const index4 = select([ + { + prefix: "%", + parser: literal6(StaticIndexKeywords.map((v) => `%${v}`), { specialChars: /* @__PURE__ */ new Set(["%"]) }) + }, + { prefix: '"', parser: string5 }, + { + prefix: "[", + parser: options2?.noDynamic ? validate(dynamicIndex2, () => false, localize("mcdoc.parser.index-body.dynamic-index-not-allowed")) : dynamicIndex2 + }, + { + parser: any3([ + resLoc({ category: "mcdoc/dispatcher", accessType: options2?.accessType }), + identifier2 + ]) + } + ]); + return setType("mcdoc:index_body", syntax([ + punctuation("["), + index4, + syntaxRepeat(syntax([marker(","), failOnEmpty(index4)])), + optional(marker(",")), + punctuation("]") + ])); +} +var pathSegment = select([{ + prefix: "super", + parser: literal6("super") +}, { parser: identifier2 }]); +var path = (src, ctx) => { + let isAbsolute; + if (src.trySkip("::")) { + isAbsolute = true; + } + return map(sequence([pathSegment, repeat(sequence([marker("::"), pathSegment]))]), (res) => { + const ans = { + type: "mcdoc:path", + children: res.children, + range: res.range, + isAbsolute + }; + return ans; + })(src, ctx); +}; +var attributeTreePosValues = setType("mcdoc:attribute/tree/pos", syntax([ + { get: () => attributeValue }, + syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(attributeValue) }], true), true) +], true)); +var attributeNamedValue = syntax([ + select([{ prefix: '"', parser: string5 }, { parser: identifier2 }]), + select([{ + prefix: "=", + parser: syntax([punctuation("="), { get: () => attributeValue }], true) + }, { parser: { get: () => attributeTree } }]) +], true); +var attributeTreeNamedValues = setType("mcdoc:attribute/tree/named", syntax([ + attributeNamedValue, + syntaxRepeat(syntax([marker(","), failOnEmpty(attributeNamedValue)], true), true) +], true)); +var treeBody = any3([ + syntax([attributeTreeNamedValues, optional(marker(","))]), + syntax([ + attributeTreePosValues, + punctuation(","), + attributeTreeNamedValues, + optional(marker(",")) + ]), + syntax([attributeTreePosValues, optional(marker(","))]) +]); +var AttributeTreeClosure = Object.freeze({ "(": ")", "[": "]", "{": "}" }); +var attributeTree = (src, ctx) => { + const delim = src.trySkip("(") ? "(" : src.trySkip("[") ? "[" : src.trySkip("{") ? "{" : void 0; + if (!delim) { + return Failure; + } + const res = treeBody(src, ctx); + const ans = { + type: "mcdoc:attribute/tree", + range: res.range, + children: res.children, + delim + }; + src.trySkip(AttributeTreeClosure[delim]); + return ans; +}; +var attributeValue = select([{ + predicate: (src) => ["(", "[", "{"].includes(src.peek()), + parser: attributeTree +}, { parser: { get: () => type } }]); +var attribute = setType("mcdoc:attribute", syntax([ + marker("#["), + identifier2, + select([{ + prefix: "=", + parser: syntax([punctuation("="), attributeValue, punctuation("]")], true) + }, { + predicate: (src) => ["(", "[", "{"].includes(src.peek()), + parser: syntax([attributeTree, punctuation("]")], true) + }, { parser: punctuation("]") }]) +], true)); +var attributes = repeat(attribute); +var typeParam = setType("mcdoc:type_param", syntax([ + identifier2 + // optional(syntax([failOnError(literal('extends')), { get: () => type }])), +])); +var typeParamBlock = setType("mcdoc:type_param_block", syntax([ + punctuation("<"), + select([{ prefix: ">", parser: punctuation(">") }, { + parser: syntax([ + typeParam, + syntaxRepeat(syntax([marker(","), failOnEmpty(typeParam)])), + optional(marker(",")), + punctuation(">") + ]) + }]) +])); +var noop5 = () => void 0; +var docComment = comment3({ + singleLinePrefixes: /* @__PURE__ */ new Set(["///"]), + includesEol: true +}); +var docComments = setType("mcdoc:doc_comments", repeat(docComment, (src) => { + src.skipWhitespace(); + return []; +})); +var prelim = syntax([ + optional(failOnEmpty(docComments)), + attributes +]); +var optionalTypeParamBlock = select([{ + prefix: "<", + parser: typeParamBlock +}, { parser: noop5 }]); +var dispatchStatement = setType("mcdoc:dispatch_statement", syntax([ + prelim, + keyword("dispatch"), + resLoc({ + category: "mcdoc/dispatcher", + accessType: 1 + /* SymbolAccessType.Write */ + }), + indexBody({ noDynamic: true }), + optionalTypeParamBlock, + literal6("to"), + { get: () => type } +], true)); +var enumType = literal6([ + "byte", + "short", + "int", + "long", + "string", + "float", + "double" +], { colorTokenType: "type" }); +var float3 = float2({ + pattern: /^[-+]?(?:[0-9]+(?:[eE][-+]?[0-9]+)?|[0-9]*\.[0-9]+(?:[eE][-+]?[0-9]+)?)$/ +}); +var integer3 = integer2({ + pattern: /^(?:0|[-+]?[1-9][0-9]*)$/ +}); +var long3 = long2({ + pattern: /^(?:0|[-+]?[1-9][0-9]*)$/ +}); +var LiteralIntSuffixes = Object.freeze(["b", "s", "l"]); +var LiteralIntCaseInsensitiveSuffixes = Object.freeze([...LiteralIntSuffixes, "B", "S", "L"]); +var LiteralFloatSuffixes = Object.freeze(["f", "d"]); +var LiteralFloatCaseInsensitiveSuffixes = Object.freeze([...LiteralFloatSuffixes, "F", "D"]); +var LiteralNumberSuffixes = Object.freeze([...LiteralIntSuffixes, ...LiteralFloatSuffixes]); +var LiteralNumberCaseInsensitiveSuffixes = Object.freeze([ + ...LiteralNumberSuffixes, + ...LiteralIntCaseInsensitiveSuffixes, + ...LiteralFloatCaseInsensitiveSuffixes +]); +var typedNumber = setType("mcdoc:typed_number", select([{ + regex: /^(?:\+|-)?\d+L/i, + parser: sequence([ + long3, + optional(failOnEmpty(literal6(LiteralIntCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) + ]) +}, { + regex: /^(?:\+|-)?\d+(?!\d|[.dfe])/i, + parser: sequence([ + integer3, + optional(failOnEmpty(literal6(LiteralIntCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) + ]) +}, { + parser: sequence([ + float3, + optional(failOnEmpty(literal6(LiteralFloatCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) + ]) +}])); +var failableTypedNumber = (src, ctx) => { + const { updateSrcAndCtx, result, errorAmount } = attempt3(typedNumber, src, ctx); + if (errorAmount > 0) { + if (result.children.length !== 2) { + return Failure; + } + const { errorAmount: numberErrors } = attempt3(float3, src, ctx); + if (numberErrors > 0) { + return Failure; + } + } + updateSrcAndCtx(); + return result; +}; +var enumValue = select([{ prefix: '"', parser: string5 }, { + parser: typedNumber +}]); +var enumField = setType("mcdoc:enum/field", syntax([prelim, identifier2, punctuation("="), enumValue], true)); +var enumBlock = setType("mcdoc:enum/block", syntax([ + punctuation("{"), + select([{ prefix: "}", parser: punctuation("}") }, { + parser: syntax([ + enumField, + syntaxRepeat(syntax([marker(","), failOnEmpty(enumField)], true), true), + optional(marker(",")), + punctuation("}") + ], true) + }]) +], true)); +var enum_ = setType("mcdoc:enum", syntax([ + prelim, + keyword("enum"), + punctuation("("), + enumType, + punctuation(")"), + optional(failOnError(identifier2)), + enumBlock +], true)); +var structMapKey = setType("mcdoc:struct/map_key", syntax([punctuation("["), { get: () => type }, punctuation("]")], true)); +var structKey = select([{ prefix: '"', parser: string5 }, { + prefix: "[", + parser: structMapKey +}, { parser: identifier2 }]); +var structPairField = (src, ctx) => { + let isOptional; + const result0 = syntax([prelim, structKey], true)(src, ctx); + if (src.trySkip("?")) { + isOptional = true; + } + const result1 = syntax([punctuation(":"), { get: () => type }], true)(src, ctx); + const ans = { + type: "mcdoc:struct/field/pair", + children: [...result0.children, ...result1.children], + range: Range.span(result0, result1), + isOptional + }; + return ans; +}; +var structSpreadField = setType("mcdoc:struct/field/spread", syntax([attributes, marker("..."), { get: () => type }], true)); +var structField = any3([ + structSpreadField, + structPairField +]); +var structBlock = setType("mcdoc:struct/block", syntax([ + punctuation("{"), + select([{ prefix: "}", parser: punctuation("}") }, { + parser: syntax([ + structField, + syntaxRepeat(syntax([marker(","), failOnEmpty(structField)], true), true), + optional(marker(",")), + punctuation("}") + ], true) + }]) +], true)); +var struct = setType("mcdoc:struct", syntax([prelim, keyword("struct"), optional(failOnEmpty(identifier2)), structBlock], true)); +var enumInjection = setType("mcdoc:injection/enum", syntax([literal6("enum"), punctuation("("), enumType, punctuation(")"), path, enumBlock])); +var structInjection = setType("mcdoc:injection/struct", syntax([literal6("struct"), path, structBlock])); +var injection = setType("mcdoc:injection", syntax([ + keyword("inject"), + select([{ prefix: "enum", parser: enumInjection }, { parser: structInjection }]) +])); +var typeAliasStatement = setType("mcdoc:type_alias", syntax([prelim, keyword("type"), identifier2, optionalTypeParamBlock, punctuation("="), { + get: () => type +}], true)); +var useStatement = setType("mcdoc:use_statement", syntax([ + keyword("use"), + path, + select([{ prefix: "as", parser: syntax([literal6("as"), identifier2]) }, { parser: noop5 }]) +], true)); +var topLevel = any3([ + comment4, + dispatchStatement, + enum_, + injection, + struct, + typeAliasStatement, + useStatement +]); +var module_2 = setType("mcdoc:module", syntaxRepeat(topLevel, true)); +var typeArgBlock = setType("mcdoc:type_arg_block", syntax([ + marker("<"), + select([{ prefix: ">", parser: punctuation(">") }, { + parser: syntax([ + { get: () => type }, + syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(type) }], true), true), + optional(marker(",")), + punctuation(">") + ], true) + }]) +])); +function typeBase(type2, parser) { + return setType(type2, syntax([ + attributes, + parser, + syntaxRepeat(select([{ prefix: "<", parser: typeArgBlock }, { parser: failOnError(indexBody()) }]), true) + ], true)); +} +var anyType = typeBase("mcdoc:type/any", keyword("any", { colorTokenType: "type" })); +var booleanType = typeBase("mcdoc:type/boolean", keyword("boolean", { colorTokenType: "type" })); +function range(type2, number5) { + const delimiterPredicate = (src) => src.tryPeek("..") || src.tryPeek(`${RangeExclusiveChar}..`); + const delimiterParser = literal6([ + "..", + `..${RangeExclusiveChar}`, + `${RangeExclusiveChar}..`, + `${RangeExclusiveChar}..${RangeExclusiveChar}` + ], { allowedChars: /* @__PURE__ */ new Set([".", RangeExclusiveChar]) }); + return setType(type2, select([{ predicate: delimiterPredicate, parser: sequence([delimiterParser, number5]) }, { + parser: sequence([ + stopBefore(number5, ".."), + select([{ + predicate: delimiterPredicate, + parser: sequence([delimiterParser, optional(failOnEmpty(number5))]) + }, { parser: noop5 }]) + ]) + }])); +} +function atRange(parser) { + return optional((src, ctx) => { + if (!src.trySkip("@")) { + return Failure; + } + src.skipWhitespace(); + return parser(src, ctx); + }); +} +var intRange = range("mcdoc:int_range", integer3); +var longRange = range("mcdoc:long_range", long3); +var floatRange = range("mcdoc:float_range", float3); +var atIntRange = atRange(intRange); +var atLongRange = atRange(longRange); +var atFloatRange = atRange(floatRange); +var stringType = typeBase("mcdoc:type/string", syntax([ + keyword("string", { colorTokenType: "type" }), + atIntRange +], true)); +var literalType = typeBase("mcdoc:type/literal", select([ + { + predicate: (src) => src.tryPeek("false") || src.tryPeek("true"), + parser: keyword(["false", "true"], { colorTokenType: "type" }) + }, + { prefix: '"', parser: failOnEmpty(string5) }, + { parser: failableTypedNumber } +])); +var numericType = typeBase("mcdoc:type/numeric_type", select([{ + predicate: (src) => NumericTypeFloatKinds.some((k) => src.tryPeek(k)), + parser: syntax([keyword(NumericTypeFloatKinds, { colorTokenType: "type" }), atFloatRange], true) +}, { + predicate: (src) => src.tryPeek("long"), + parser: syntax([keyword("long", { colorTokenType: "type" }), atLongRange], true) +}, { + parser: syntax([keyword(NumericTypeIntKinds, { colorTokenType: "type" }), atIntRange], true) +}])); +var primitiveArrayType = typeBase("mcdoc:type/primitive_array", syntax([ + select([{ + predicate: (src) => src.tryPeek("long"), + parser: syntax([literal6("long"), atLongRange], true) + }, { + parser: syntax([literal6(PrimitiveArrayValueKinds), atIntRange], true) + }]), + keyword("[]", { allowedChars: /* @__PURE__ */ new Set(["[", "]"]), colorTokenType: "type" }), + atIntRange +])); +var listType = typeBase("mcdoc:type/list", syntax([marker("["), { get: () => type }, punctuation("]"), atIntRange], true)); +var tupleType = typeBase("mcdoc:type/tuple", syntax([ + marker("["), + { get: () => type }, + marker(","), + select([{ prefix: "]", parser: punctuation("]") }, { + parser: syntax([ + { get: () => type }, + syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(type) }], true), true), + optional(marker(",")), + punctuation("]") + ], true) + }]) +], true)); +var dispatcherType = typeBase("mcdoc:type/dispatcher", syntax([failOnError(resLoc({ category: "mcdoc/dispatcher" })), indexBody()])); +var unionType = typeBase("mcdoc:type/union", syntax([ + marker("("), + select([{ prefix: ")", parser: punctuation(")") }, { + parser: syntax([ + { get: () => type }, + syntaxRepeat(syntax([marker("|"), { get: () => failOnEmpty(type) }], true), true), + optional(marker("|")), + punctuation(")") + ], true) + }]) +])); +var referenceType = typeBase("mcdoc:type/reference", syntax([path])); +var type = any3([ + anyType, + booleanType, + dispatcherType, + enum_, + listType, + literalType, + numericType, + primitiveArrayType, + stringType, + struct, + tupleType, + unionType, + referenceType +]); + +// node_modules/@spyglassmc/mcdoc/lib/formatter/index.js +var nodeTypesAllowingComments = /* @__PURE__ */ new Set([ + "mcdoc:module", + "mcdoc:struct/block", + "mcdoc:enum/block", + "mcdoc:doc_comments", + "mcdoc:type/tuple", + "mcdoc:type/union" +]); +var nodeTypesAllowingTrailingComments = /* @__PURE__ */ new Set([ + "mcdoc:module", + "mcdoc:struct/block", + "mcdoc:enum/block", + "mcdoc:doc_comments" +]); +var prelimNodeTypes = /* @__PURE__ */ new Set([ + "mcdoc:attribute", + "mcdoc:doc_comments" +]); +function formatChildren(node, ctx, childFormatInfo, excludeLastChildSuffix = false, onlyFormatPrelimType) { + const allowsComments = nodeTypesAllowingComments.has(node.type); + const allowsTrailingComments = nodeTypesAllowingTrailingComments.has(node.type); + const children = allowsComments ? liftChildComments(node.children) : node.children; + const lastNonComment = children.findLastIndex((child) => child.type !== "comment"); + const lastFormattedChild = onlyFormatPrelimType !== void 0 ? children.findLastIndex((child) => child.type === onlyFormatPrelimType) : children.findLastIndex((child) => child.type !== "comment"); + const content = children.map((child, i) => { + if (onlyFormatPrelimType !== void 0 && child.type !== onlyFormatPrelimType) { + return ""; + } + if (onlyFormatPrelimType === void 0 && prelimNodeTypes.has(child.type)) { + return ""; + } + if (child.type === "comment" && !allowsComments) { + return ""; + } + if (i > lastNonComment && !allowsTrailingComments) { + return ""; + } + const info = childFormatInfo[child.type]; + const value = ctx.meta.getFormatter(child.type)(child, info?.indentSelf ? indentFormatter(ctx) : ctx); + const prefix = info?.prefix ?? ""; + const hasSuffix = info?.suffix !== void 0 && (!excludeLastChildSuffix || lastFormattedChild !== i); + const suffix = hasSuffix ? info.suffix : ""; + const formatted = `${prefix}${value}${suffix}`; + return formatted; + }).join(""); + return content; +} +var formatterIgnoreAttributeName = "formatter_ignore"; +function shouldFormatterIgnore(node) { + return node.children?.some((child) => { + if (child.type !== "mcdoc:attribute") { + return false; + } + return child.children.some((attributeChild) => { + return attributeChild.type === "mcdoc:identifier" && attributeChild.value === formatterIgnoreAttributeName; + }); + }) ?? false; +} +function getUnformatted(node, ctx) { + return ctx.doc.getText({ + start: ctx.doc.positionAt(node.range.start), + end: ctx.doc.positionAt(node.range.end) + }); +} +function hasMultilineChild(node, isRecursiveCall = false, alwaysIncludeComments = false) { + if (!node.children) { + return false; + } + for (let i = 0; i < node.children.length; i++) { + const child = node.children[i]; + if (child.type === "comment") { + if (alwaysIncludeComments) { + return true; + } + if (nodeTypesAllowingComments.has(node.type)) { + if (nodeTypesAllowingTrailingComments.has(node.type)) { + return true; + } + if (i < node.children.length - 1 && node.children[i + 1].type !== "comment") { + return true; + } + } + } + if (child.type === "mcdoc:struct") { + return true; + } + if (child.type === "mcdoc:enum") { + return true; + } + if (isRecursiveCall && child.type === "mcdoc:attribute") { + return true; + } + if (hasMultilineChild(child, true, alwaysIncludeComments || i < node.children.length - 1)) { + return true; + } + } + return false; +} +var maxDynamicInlineLength = 80; +function formatDynamicMultiline(node, formatter) { + if (hasMultilineChild(node)) { + return formatter(true); + } + const inlineFormat = formatter(false); + if (inlineFormat.length > maxDynamicInlineLength) { + return formatter(true); + } + return inlineFormat; +} +function formatWithPrelim(node, ctx, putAttributesOnSeparateLine, putDocOnSeparateLine, contentFormatter) { + if (shouldFormatterIgnore(node)) { + return getUnformatted(node, ctx); + } + function attributeFormatter(doMultiline, attributeCtx) { + const childFormatInfo = { + "mcdoc:attribute": { + suffix: doMultiline ? ` +${attributeCtx.indent()}` : " " + } + }; + return formatChildren( + node, + attributeCtx, + childFormatInfo, + // Last suffix is excluded, because it is specified separately through `putAttributesOnSeparateLine`. + // This makes it possible to put all attributes on one line but still add a newline at the end. + true, + "mcdoc:attribute" + ); + } + const shouldIndentPrelim = !putDocOnSeparateLine && node.children.some((child) => child.type === "mcdoc:doc_comments"); + function processFormattedAttributes(formattedAttributes, areAttributesMultiline) { + const formattedDocComments = formatChildren(node, putDocOnSeparateLine ? ctx : indentFormatter(ctx), {}, false, "mcdoc:doc_comments"); + const hasAdditionalIndent = shouldIndentPrelim || !putAttributesOnSeparateLine && areAttributesMultiline; + if (formattedAttributes !== "") { + if (hasAdditionalIndent) { + formattedAttributes += ` +${ctx.indent(1)}`; + } else if (putAttributesOnSeparateLine) { + formattedAttributes += ` +${ctx.indent()}`; + } else { + formattedAttributes += " "; + } + } + const prelim2 = (hasAdditionalIndent ? ` +${ctx.indent(1)}` : "") + formattedDocComments + formattedAttributes; + const content = contentFormatter(hasAdditionalIndent ? indentFormatter(ctx) : ctx); + return prelim2 + content; + } + const multilineChild = node.children?.some((child) => { + child.type === "mcdoc:attribute" && hasMultilineChild(child); + }); + if (multilineChild) { + return processFormattedAttributes(attributeFormatter(true, putAttributesOnSeparateLine ? ctx : indentFormatter(ctx)), true); + } + const inlineAttributes = attributeFormatter(false, ctx); + if (inlineAttributes.length > maxDynamicInlineLength) { + return processFormattedAttributes(attributeFormatter(true, putAttributesOnSeparateLine ? ctx : indentFormatter(ctx)), true); + } + return processFormattedAttributes((shouldIndentPrelim ? ctx.indent(1) : "") + inlineAttributes, false); +} +function liftChildComments(children) { + const mutableChildren = [...children]; + for (let i = 0; i < mutableChildren.length; i++) { + const child = mutableChildren[i]; + const { beforeNode, afterNode } = findComments(child); + mutableChildren.splice(i, 0, ...beforeNode); + i += beforeNode.length; + mutableChildren.splice(i + 1, 0, ...afterNode); + i += afterNode.length; + } + return mutableChildren; +} +function findComments(node) { + const result = { + beforeNode: [], + afterNode: [] + }; + if (!node.children) { + return result; + } + let currentCommentSequence = []; + node.children.forEach((child) => { + if (child.type === "comment") { + currentCommentSequence.push(child); + return; + } + result.beforeNode.push(...currentCommentSequence); + currentCommentSequence = []; + const childComments = findComments(child); + if (nodeTypesAllowingComments.has(child.type)) { + if (!nodeTypesAllowingTrailingComments.has(child.type)) { + currentCommentSequence = childComments.afterNode; + } + return; + } + result.beforeNode.push(...childComments.beforeNode); + currentCommentSequence = childComments.afterNode; + }); + result.afterNode.push(...currentCommentSequence); + return result; +} +function getTypeNodes(children) { + return children.filter((child) => child.type.startsWith("mcdoc:type/") || child.type === "mcdoc:enum" || child.type === "mcdoc:struct"); +} +var module2 = (node, ctx) => { + const children = liftChildComments(node.children); + return children.map((child, i) => { + function addNewlineSeparator(formatted2) { + if (i === children.length - 1) { + return formatted2; + } + return `${formatted2} +`; + } + const formatted = ctx.meta.getFormatter(child.type)(child, ctx); + if (shouldFormatterIgnore(child)) { + return formatted; + } + if (child.type === "comment") { + return `${formatted} +`; + } + if (child.type === "mcdoc:use_statement" && children[i + 1]?.type === "mcdoc:use_statement") { + return `${formatted} +`; + } + return addNewlineSeparator(`${formatted} +`); + }).join(""); +}; +var useStatement2 = (node, ctx) => { + const hasAlias = node.children.some((child) => child.type === "mcdoc:identifier"); + return formatChildren(node, ctx, { + "mcdoc:literal": { suffix: " " }, + "mcdoc:path": { suffix: hasAlias ? " " : "" } + }); +}; +var injection2 = (node, ctx) => { + return formatChildren(node, ctx, { + "mcdoc:literal": { suffix: " " } + }); +}; +var struct2 = (node, ctx) => { + const isTopLevel = node.parent?.type === "mcdoc:module"; + return formatWithPrelim(node, ctx, isTopLevel, isTopLevel, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:literal": { suffix: " " }, + "mcdoc:identifier": { suffix: " " } + }); + }); +}; +var structInjection2 = (node, ctx) => { + return formatChildren(node, ctx, { + "mcdoc:literal": { suffix: " " }, + "mcdoc:path": { suffix: " " } + }); +}; +var structBlock2 = (node, ctx) => { + if (node.children.length === 0) { + return "{}"; + } + const content = formatChildren(node, ctx, { + "comment": { prefix: ctx.indent(1), suffix: "\n", indentSelf: true }, + "mcdoc:struct/field/pair": { suffix: ",\n", indentSelf: true }, + "mcdoc:struct/field/spread": { suffix: ",\n", indentSelf: true } + }); + return `{ +${content}${ctx.indent()}}`; +}; +var structPairField2 = (node, ctx) => { + const keySuffix = `${node.isOptional ? "?" : ""}: `; + return ctx.indent() + formatWithPrelim(node, ctx, true, true, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:struct/map_key": { suffix: keySuffix }, + "mcdoc:identifier": { suffix: keySuffix }, + "string": { suffix: keySuffix } + }); + }); +}; +var structMapKey2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children)[0]; + return formatChildren(node, ctx, { + [typeNode.type]: { prefix: "[", suffix: "]" } + }); +}; +var structSpreadField2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children)[0]; + return ctx.indent() + formatWithPrelim(node, ctx, true, true, (contentCtx) => { + return formatChildren(node, contentCtx, { + [typeNode.type]: { prefix: "..." } + }); + }); +}; +var _enum = (node, ctx) => { + const isTopLevel = node.parent?.type === "mcdoc:module"; + return formatWithPrelim(node, ctx, isTopLevel, isTopLevel, (contentCtx) => { + return node.children.map((child) => { + if (child.type === "comment") { + return ""; + } + if (child.type === "mcdoc:attribute") { + return ""; + } + const formatted = contentCtx.meta.getFormatter(child.type)(child, contentCtx); + if (child.type === "mcdoc:identifier") { + return formatted + " "; + } + if (child.type !== "mcdoc:literal" || child.value === "enum") { + return formatted; + } + return `(${formatted}) `; + }).join(""); + }); +}; +var enumInjection2 = (node, ctx) => { + return node.children.map((child) => { + if (child.type === "comment") { + return ""; + } + const formatted = ctx.meta.getFormatter(child.type)(child, ctx); + if (child.type === "mcdoc:path") { + return formatted + " "; + } + if (child.type !== "mcdoc:literal" || child.value === "enum") { + return formatted; + } + return `(${formatted}) `; + }).join(""); +}; +var enumBlock2 = (node, ctx) => { + if (node.children.length === 0) { + return "{}"; + } + const content = formatChildren(node, ctx, { + "comment": { prefix: ctx.indent(1), suffix: "\n", indentSelf: true }, + "mcdoc:enum/field": { prefix: ctx.indent(1), suffix: ",\n", indentSelf: true } + }); + return `{ +${content}${ctx.indent()}}`; +}; +var enumField2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, true, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:identifier": { suffix: " = " } + }); + }); +}; +var tupleType2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children); + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatDynamicMultiline(node, (doMultiline) => { + const childFormatInfo = { + "comment": { + prefix: contentCtx.indent(1), + suffix: ` +` + } + }; + const typeFormatInfo = { + prefix: doMultiline ? contentCtx.indent(1) : "", + suffix: "," + (doMultiline ? ` +` : " "), + indentSelf: true + }; + for (const child of typeNode) { + childFormatInfo[child.type] = typeFormatInfo; + } + const content = formatChildren(node, contentCtx, childFormatInfo, !doMultiline); + return doMultiline ? `[ +${content}${contentCtx.indent()}]` : `[${content}]`; + }); + }); +}; +var unionType2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children); + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatDynamicMultiline(node, (doMultiline) => { + const childFormatInfo = { + "comment": { + prefix: contentCtx.indent(1), + suffix: ` +` + } + }; + const typeFormatInfo = { + prefix: doMultiline ? contentCtx.indent(1) : "", + suffix: " |" + (doMultiline ? ` +` : " "), + indentSelf: true + }; + for (const child of typeNode) { + childFormatInfo[child.type] = typeFormatInfo; + } + const content = formatChildren(node, contentCtx, childFormatInfo, !doMultiline); + return doMultiline ? `( +${content}${contentCtx.indent()})` : `(${content})`; + }); + }); +}; +var referenceType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, {}); + }); +}; +var path2 = (node, ctx) => { + const formatted = formatChildren(node, ctx, { + "mcdoc:literal": { prefix: "::" }, + "mcdoc:identifier": { prefix: "::" } + }); + if (!node.isAbsolute) { + return formatted.substring(2); + } + return formatted; +}; +var stringType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:int_range": { prefix: " @ " } + }); + }); +}; +var primitiveArrayType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:int_range": { prefix: " @ " } + }); + }); +}; +var listType2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children)[0]; + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, { + [typeNode.type]: { prefix: "[", suffix: "]" }, + "mcdoc:int_range": { prefix: " @ " } + }); + }); +}; +var typeAlias = (node, ctx) => { + const typeNode = getTypeNodes(node.children)[0]; + return formatWithPrelim(node, ctx, true, true, (contentCtx) => { + return formatChildren(node, contentCtx, { + [typeNode.type]: { prefix: " = " }, + "mcdoc:literal": { suffix: " " } + }); + }); +}; +var dispatcherType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, true, true, (contentCtx) => { + return formatChildren(node, contentCtx, {}); + }); +}; +var dispatchStatement2 = (node, ctx) => { + return formatWithPrelim(node, ctx, true, true, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:literal": { suffix: " " }, + "mcdoc:index_body": { suffix: " " } + }); + }); +}; +var indexBody2 = (node, ctx) => { + return formatDynamicMultiline(node, (doMultiline) => { + const indexFormatInfo = { + prefix: doMultiline ? ctx.indent(1) : "", + suffix: "," + (doMultiline ? ` +` : " "), + indentSelf: true + }; + const content = formatChildren(node, ctx, { + "mcdoc:dynamic_index": indexFormatInfo, + "mcdoc:identifier": indexFormatInfo, + "mcdoc:literal": indexFormatInfo, + "resource_location": indexFormatInfo, + "string": indexFormatInfo + }, !doMultiline); + return doMultiline ? `[ +${content}${ctx.indent()}]` : `[${content}]`; + }); +}; +var dynamicIndex = (node, ctx) => { + const path6 = node.children.map((child) => { + if (child.type === "comment") { + return ""; + } + return ctx.meta.getFormatter(child.type)(child, ctx); + }).join("."); + return `[${path6}]`; +}; +var attribute2 = (node, ctx) => { + const hasTypeValue = getTypeNodes(node.children).length !== 0; + return formatChildren(node, ctx, { + "mcdoc:identifier": { prefix: "#[", suffix: hasTypeValue ? "=" : "" } + }) + "]"; +}; +var attributeTree2 = (node, ctx) => { + const content = formatChildren(node, ctx, {}); + return `${node.delim}${content}${AttributeTreeClosure[node.delim]}`; +}; +var attributeTreePosValues2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children); + return formatDynamicMultiline(node, (doMultiline) => { + const childFormatInfo = { + prefix: doMultiline ? ctx.indent(1) : "", + suffix: "," + (doMultiline ? ` +` : " "), + indentSelf: true + }; + const childFormatInfoMap = { + "mcdoc:attribute/tree": childFormatInfo + }; + for (const child of typeNode) { + childFormatInfoMap[child.type] = childFormatInfo; + } + const content = formatChildren(node, ctx, childFormatInfoMap, !doMultiline); + return doMultiline ? ` +${content}${ctx.indent()}` : content; + }); +}; +var attributeTreeNamedValues2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children); + return formatDynamicMultiline(node, (doMultiline) => { + const childFormatInfo = { + prefix: "=", + suffix: "," + (doMultiline ? ` +` : " "), + indentSelf: true + }; + const childFormatInfoMap = { + "mcdoc:attribute/tree": childFormatInfo, + "mcdoc:identifier": { prefix: doMultiline ? ctx.indent(1) : "" }, + "string": { prefix: doMultiline ? ctx.indent(1) : "" } + }; + for (const child of typeNode) { + childFormatInfoMap[child.type] = childFormatInfo; + } + const content = formatChildren(node, ctx, childFormatInfoMap, !doMultiline); + return doMultiline ? ` +${content}${ctx.indent()}` : content; + }); +}; +var typeArgBlock2 = (node, ctx) => { + const typeNode = getTypeNodes(node.children); + const childFormatInfo = {}; + for (const child of typeNode) { + childFormatInfo[child.type] = { suffix: ", " }; + } + const content = formatChildren(node, ctx, childFormatInfo, true); + return `<${content}>`; +}; +var typeParamBlock2 = (node, ctx) => { + const content = formatChildren(node, ctx, { + "mcdoc:type_param": { suffix: ", " } + }, true); + return `<${content}>`; +}; +var typeParam2 = (node, ctx) => { + return formatChildren(node, ctx, {}); +}; +var literalType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, {}); + }); +}; +var typedNumber2 = (node, ctx) => { + return formatChildren(node, ctx, {}); +}; +var numericType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, { + "mcdoc:int_range": { prefix: " @ " }, + "mcdoc:float_range": { prefix: " @ " } + }); + }); +}; +var intRange2 = (node, ctx) => { + return formatChildren(node, ctx, {}); +}; +var floatRange2 = (node, ctx) => { + return formatChildren(node, ctx, {}); +}; +var anyType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, {}); + }); +}; +var booleanType2 = (node, ctx) => { + return formatWithPrelim(node, ctx, false, false, (contentCtx) => { + return formatChildren(node, contentCtx, {}); + }); +}; +var literal7 = (node) => { + return node.value; +}; +var identifier3 = (node) => { + return node.value; +}; +var docComments2 = (node, ctx) => { + if (node.children.length === 0) { + return ""; + } + return formatChildren(node, ctx, { + comment: { suffix: ctx.indent() } + // No need to add new lines, because DocCommentNodes include them + }); +}; +function registerMcdocFormatter(meta) { + meta.registerFormatter("mcdoc:module", module2); + meta.registerFormatter("mcdoc:use_statement", useStatement2); + meta.registerFormatter("mcdoc:injection", injection2); + meta.registerFormatter("mcdoc:struct", struct2); + meta.registerFormatter("mcdoc:injection/struct", structInjection2); + meta.registerFormatter("mcdoc:struct/block", structBlock2); + meta.registerFormatter("mcdoc:struct/field/pair", structPairField2); + meta.registerFormatter("mcdoc:struct/map_key", structMapKey2); + meta.registerFormatter("mcdoc:struct/field/spread", structSpreadField2); + meta.registerFormatter("mcdoc:enum", _enum); + meta.registerFormatter("mcdoc:injection/enum", enumInjection2); + meta.registerFormatter("mcdoc:enum/block", enumBlock2); + meta.registerFormatter("mcdoc:enum/field", enumField2); + meta.registerFormatter("mcdoc:type/tuple", tupleType2); + meta.registerFormatter("mcdoc:type/union", unionType2); + meta.registerFormatter("mcdoc:type/reference", referenceType2); + meta.registerFormatter("mcdoc:path", path2); + meta.registerFormatter("mcdoc:type/string", stringType2); + meta.registerFormatter("mcdoc:type/primitive_array", primitiveArrayType2); + meta.registerFormatter("mcdoc:type/list", listType2); + meta.registerFormatter("mcdoc:type_alias", typeAlias); + meta.registerFormatter("mcdoc:type/dispatcher", dispatcherType2); + meta.registerFormatter("mcdoc:dispatch_statement", dispatchStatement2); + meta.registerFormatter("mcdoc:index_body", indexBody2); + meta.registerFormatter("mcdoc:dynamic_index", dynamicIndex); + meta.registerFormatter("mcdoc:attribute", attribute2); + meta.registerFormatter("mcdoc:attribute/tree", attributeTree2); + meta.registerFormatter("mcdoc:attribute/tree/pos", attributeTreePosValues2); + meta.registerFormatter("mcdoc:attribute/tree/named", attributeTreeNamedValues2); + meta.registerFormatter("mcdoc:type_arg_block", typeArgBlock2); + meta.registerFormatter("mcdoc:type_param_block", typeParamBlock2); + meta.registerFormatter("mcdoc:type_param", typeParam2); + meta.registerFormatter("mcdoc:type/literal", literalType2); + meta.registerFormatter("mcdoc:typed_number", typedNumber2); + meta.registerFormatter("mcdoc:type/numeric_type", numericType2); + meta.registerFormatter("mcdoc:int_range", intRange2); + meta.registerFormatter("mcdoc:float_range", floatRange2); + meta.registerFormatter("mcdoc:type/any", anyType2); + meta.registerFormatter("mcdoc:type/boolean", booleanType2); + meta.registerFormatter("mcdoc:literal", literal7); + meta.registerFormatter("mcdoc:identifier", identifier3); + meta.registerFormatter("mcdoc:doc_comments", docComments2); +} + +// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/index.js +var attribute_exports = {}; +__export(attribute_exports, { + getAttribute: () => getAttribute, + handleAttributes: () => handleAttributes, + registerAttribute: () => registerAttribute, + shouldKeepAccordingToAttributeFilters: () => shouldKeepAccordingToAttributeFilters, + validator: () => validator_exports +}); + +// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/validator.js +var validator_exports = {}; +__export(validator_exports, { + alternatives: () => alternatives, + boolean: () => boolean5, + list: () => list2, + map: () => map2, + number: () => number2, + optional: () => optional2, + options: () => options, + string: () => string6, + tree: () => tree +}); +var string6 = (value) => { + if (value === void 0) { + return Failure; + } + if (value.kind === "literal" && value.value.kind === "string") { + return value.value.value; + } + if (value.kind === "reference" && value.path) { + return value.path.replace(/.*::/, ""); + } + return Failure; +}; +var number2 = (value) => { + if (value === void 0) { + return Failure; + } + if (value.kind === "literal" && typeof value.value.value === "number") { + return value.value.value; + } + return Failure; +}; +var boolean5 = (value) => { + if (value === void 0) { + return Failure; + } + if (value.kind === "literal" && value.value.kind === "boolean") { + return value.value.value; + } + return Failure; +}; +function options(...options2) { + return (value, ctx) => { + const stringValue = string6(value, ctx); + if (stringValue === Failure) { + return Failure; + } + if (options2.includes(stringValue)) { + return stringValue; + } + return Failure; + }; +} +function tree(properties) { + return (value, ctx) => { + if (value?.kind !== "tree") { + return Failure; + } + const result = {}; + for (const key2 in properties) { + const validator4 = properties[key2]; + const propValue = value.values[key2]; + const property = validator4(propValue, ctx); + if (property === Failure) { + return Failure; + } + result[key2] = property; + } + return result; + }; +} +function list2(itemValidator) { + return (value, ctx) => { + if (value?.kind !== "tree") { + return Failure; + } + const result = []; + for (const element of Object.values(value.values)) { + const item = itemValidator(element, ctx); + if (item === Failure) { + return Failure; + } + result.push(item); + } + return result; + }; +} +function optional2(validator4) { + return (value, ctx) => { + const config = validator4(value, ctx); + return config === Failure ? void 0 : config; + }; +} +function map2(validator4, mapper) { + return (value, ctx) => { + const config = validator4(value, ctx); + return config === Failure ? Failure : mapper(config); + }; +} +function alternatives(...validators) { + return (value, ctx) => { + for (const validator4 of validators) { + const result = validator4(value, ctx); + if (result !== Failure) { + return result; + } + } + return Failure; + }; +} + +// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/index.js +function registerAttribute(meta, name, validator4, attribute3) { + meta.registerCustom("mcdoc:attribute", name, { validator: validator4, attribute: attribute3 }); +} +function getAttribute(meta, name) { + return meta.getCustom("mcdoc:attribute")?.get(name); +} +function handleAttributes(attributes2, ctx, fn) { + for (const { name, value } of attributes2 ?? []) { + const handler = getAttribute(ctx.meta, name); + if (!handler) { + continue; + } + const config = handler.validator(value, ctx); + if (config === Failure) { + continue; + } + fn(handler.attribute, config); + } +} +function shouldKeepAccordingToAttributeFilters(attributes2, ctx) { + let keep = true; + handleAttributes(attributes2, ctx, (handler, config) => { + if (!keep || !handler.filterElement) { + return; + } + if (!handler.filterElement(config, ctx)) { + keep = false; + } + }); + return keep; +} + +// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/builtin.js +var idValidator = validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => ({ registry: v })), validator_exports.tree({ + registry: validator_exports.string, + tags: validator_exports.optional(validator_exports.options("allowed", "implicit", "required")), + definition: validator_exports.optional(validator_exports.boolean), + prefix: validator_exports.optional(validator_exports.options("!")), + path: validator_exports.optional(validator_exports.string), + empty: validator_exports.optional(validator_exports.options("allowed")), + exclude: validator_exports.optional(validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => [v]), validator_exports.list(validator_exports.string))) +}), () => ({})); +var matchRegexValidator = validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => ({ pattern: v })), validator_exports.tree({ + pattern: validator_exports.string, + message: validator_exports.optional(validator_exports.string) +})); +function getResourceLocationOptions({ registry, tags, definition, path: path6 }, requireCanonical, ctx, typeDef) { + if (!registry) { + if (typeDef?.kind === "enum" && typeDef.enumKind === "string") { + return { + pool: typeDef.values.map((v) => ResourceLocation.lengthen(`${v.value}`)), + allowUnknown: true + // the mcdoc checker will already report errors for this + }; + } + if (typeDef?.kind === "literal" && typeDef.value.kind === "string") { + return { + pool: [ResourceLocation.lengthen(typeDef.value.value)], + allowUnknown: true + }; + } + return { pool: [], allowUnknown: true }; + } + if (tags === "implicit") { + registry = `tag/${registry}`; + } + if (tags === "allowed" || tags === "required") { + return { + category: registry, + requireCanonical, + allowTag: true, + requireTag: tags === "required", + implicitPath: path6 + }; + } + return { + category: registry, + requireCanonical, + usageType: definition ? "definition" : "reference", + implicitPath: path6 + }; +} +var integerValidator = validator_exports.alternatives(validator_exports.tree({ + min: validator_exports.optional(validator_exports.number), + max: validator_exports.optional(validator_exports.number) +}), () => ({})); +function registerBuiltinAttributes(meta) { + registerAttribute(meta, "canonical", () => void 0, { + // Has hardcoded behavior in the runtime checker + }); + registerAttribute(meta, "dispatcher_key", validator_exports.string, { + stringMocker: (config, _, ctx) => { + const symbol7 = ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", config).symbol; + const keys = Object.entries(symbol7?.members ?? {}).filter(([k, v]) => { + if (k.startsWith("%")) { + return false; + } + if (!TypeDefSymbolData.is(v.data)) { + return false; + } + return shouldKeepAccordingToAttributeFilters(v.data.typeDef.attributes, ctx); + }).map(([k, _2]) => k); + return LiteralNode.mock(ctx.offset, { pool: keys }); + } + }); + registerAttribute(meta, "divisible_by", validator_exports.number, { + checker(config, typeDef) { + if (typeDef.kind !== "literal" || typeDef.value.kind === "string" || typeDef.value.kind === "boolean") { + return void 0; + } + const value = typeDef.value.value; + return (node, ctx) => { + const moduloResult = typeof value === "number" ? value % config : value % BigInt(config); + if (moduloResult !== 0 && moduloResult !== 0n) { + ctx.err.report(localize("not-divisible-by", value, config), node, ErrorSeverity.Warning); + } + }; + } + }); + registerAttribute(meta, "id", idValidator, { + checkInferred: (config, inferred, ctx) => { + if (inferred.kind === "string") { + const idAttr = inferred.attributes?.find((a) => a.name === "id"); + if (idAttr) { + const inferredConfig = idValidator(idAttr.value, ctx); + return inferredConfig === Failure || inferredConfig.prefix === config.prefix; + } + } + if (inferred.kind !== "literal" || inferred.value.kind !== "string") { + return true; + } + if (config.prefix && !inferred.value.value.startsWith(config.prefix)) { + return false; + } + if (!config.prefix && inferred.value.value.startsWith("!")) { + return false; + } + if (!inferred.value.value.includes(":")) { + if (config.prefix) { + inferred.value.value = config.prefix + "minecraft:" + inferred.value.value.slice(config.prefix.length); + } else { + inferred.value.value = "minecraft:" + inferred.value.value; + } + } + return true; + }, + mapType: (config, typeDef, ctx) => { + if (typeDef.kind === "literal" && typeDef.value.kind === "string") { + const value = ResourceLocation.lengthen(typeDef.value.value); + return { ...typeDef, value: { kind: "string", value } }; + } + if (typeDef.kind === "enum" && typeDef.enumKind === "string") { + const values = typeDef.values.map((v) => ({ + ...v, + value: ResourceLocation.lengthen(`${v.value}`) + })); + return { ...typeDef, values }; + } + return typeDef; + }, + stringParser: (config, typeDef, ctx) => { + const options2 = getResourceLocationOptions(config, ctx.requireCanonical, ctx, typeDef); + if (!options2) { + return; + } + const resourceLocation7 = resourceLocation6(options2); + return (src, ctx2) => { + if (config.empty && !src.canRead()) { + return string4({ + unquotable: { blockList: /* @__PURE__ */ new Set(), allowEmpty: true } + })(src, ctx2); + } + if (config.prefix) { + return prefixed2({ prefix: config.prefix, child: resourceLocation7 })(src, ctx2); + } + const node = resourceLocation7(src, ctx2); + if (config.exclude) { + const resourceLocation8 = ResourceLocationNode.toString(node, "full"); + for (const e of config.exclude ?? []) { + const excluded = ResourceLocation.lengthen(e); + if (resourceLocation8 === excluded) { + ctx2.err.report(localize("not-allowed-here", localeQuote(excluded)), node, ErrorSeverity.Warning); + } + } + } + return node; + }; + }, + stringMocker: (config, typeDef, ctx) => { + const options2 = getResourceLocationOptions(config, ctx.requireCanonical ?? false, ctx, typeDef); + if (!options2) { + return void 0; + } + const resourceLocation7 = ResourceLocationNode.mock(ctx.offset, options2); + if (config.prefix) { + return PrefixedNode.mock(ctx.offset, config.prefix, resourceLocation7); + } + return resourceLocation7; + } + }); + registerAttribute(meta, "integer", integerValidator, { + stringParser: (config) => { + return integer2({ pattern: /^-?\d+$/, min: config.min, max: config.max }); + } + }); + registerAttribute(meta, "color", validator_exports.string, { + checkInferred: (config, inferred, ctx) => { + if (config === "hex_rgb" && inferred.kind === "literal" && inferred.value.kind === "string") { + return inferred.value.value.startsWith("#"); + } + return true; + }, + checker: (config, inferred) => { + return (node, ctx) => { + switch (config) { + case "named": + if (inferred.kind !== "literal" || inferred.value.kind !== "string") { + return; + } + node.color = Color.fromNamed(inferred.value.value); + return; + case "hex_rgb": + if (inferred.kind !== "literal" || inferred.value.kind !== "string") { + return; + } + let range3 = node.range; + if (StringBaseNode.is(node) && node.quote) { + range3 = Range.translate(range3, 1, -1); + } + if (!inferred.value.value.startsWith("#")) { + ctx.err.report(localize("expected", localeQuote("#")), range3, ErrorSeverity.Warning); + return; + } + node.color = { + value: Color.fromHexRGB(inferred.value.value), + format: [ColorFormat.HexRGB], + range: range3 + }; + return; + case "composite_rgb": + if (inferred.kind !== "literal" || typeof inferred.value.value !== "number") { + return; + } + node.color = { + value: Color.fromCompositeRGB(inferred.value.value), + format: [ColorFormat.CompositeRGB], + range: node.range + }; + return; + case "composite_argb": + if (inferred.kind !== "literal" || typeof inferred.value.value !== "number") { + return; + } + node.color = { + value: Color.fromCompositeARGB(inferred.value.value), + format: [ColorFormat.CompositeARGB], + range: node.range + }; + return; + default: + return; + } + }; + } + }); + registerAttribute(meta, "regex_pattern", () => void 0, { + checker: (_, typeDef) => { + if (typeDef.kind !== "literal" || typeDef.value.kind !== "string") { + return void 0; + } + const pattern = typeDef.value.value; + return (node, ctx) => { + try { + RegExp(pattern); + } catch (e) { + const message2 = e instanceof Error ? e.message : `${e}`; + const error4 = message2.replace(/^Invalid regular expression: /, "").replace(/^\/.+\/: /, ""); + ctx.err.report(localize("invalid-regex-pattern", error4), node, ErrorSeverity.Warning); + } + }; + } + }); + registerAttribute(meta, "match_regex", matchRegexValidator, { + checker: (config, typeDef, _) => { + if (typeDef.kind !== "literal" || typeDef.value.kind !== "string") { + return void 0; + } + const pattern = config.pattern; + const value = typeDef.value.value; + return (node, ctx) => { + try { + const regex = RegExp(pattern); + if (!regex.test(value)) { + const message2 = config.message ?? localize("mismatching-regex-pattern", pattern); + ctx.err.report(message2, node, ErrorSeverity.Warning); + } + } catch (e) { + ctx.logger.warn(`Invalid regular expression in "match_regex" mcdoc attribute: ${pattern}`); + } + }; + } + }); +} + +// node_modules/@spyglassmc/mcdoc/lib/common.js +function segToIdentifier(seg) { + return `::${seg.join("::")}`; +} + +// node_modules/@spyglassmc/mcdoc/lib/uri_processors.js +var Extension = ".mcdoc"; +var McdocRootPrefix = "mcdoc/"; +var uriBinder = (uris, ctx) => { + let urisAndRels = []; + for (const uri of uris) { + if (!uri.endsWith(Extension)) { + continue; + } + let rel = fileUtil.getRel(uri, ctx.roots); + if (!rel) { + continue; + } + rel = rel.slice(0, -Extension.length).replace(/(^|\/)mod$/, ""); + urisAndRels.push([uri, rel]); + } + if (urisAndRels.every(([_, rel]) => rel.startsWith(McdocRootPrefix))) { + urisAndRels = urisAndRels.map(([uri, rel]) => [uri, rel.slice(McdocRootPrefix.length)]); + } + for (const [uri, rel] of urisAndRels) { + ctx.symbols.query(uri, "mcdoc", segToIdentifier(rel.split("/"))).ifDefined(() => { + }).elseEnter({ + data: { subcategory: "module" }, + usage: { type: "definition" } + }); + } +}; +var uriSorter = (a, b, next) => { + if (a.endsWith(Extension) && !b.endsWith(Extension)) { + return -1; + } else if (!a.endsWith(Extension) && b.endsWith(Extension)) { + return 1; + } else { + return next(a, b); + } +}; + +// node_modules/@spyglassmc/mcdoc/lib/runtime/index.js +var runtime_exports = {}; +__export(runtime_exports, { + attribute: () => attribute_exports, + checker: () => checker_exports, + completer: () => completer_exports, + registerAttribute: () => registerAttribute +}); + +// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/index.js +var checker_exports = {}; +__export(checker_exports, { + McdocCheckerContext: () => McdocCheckerContext, + MissingKeyError: () => MissingKeyError, + RangeError: () => RangeError2, + SimpleError: () => SimpleError, + TypeMismatchError: () => TypeMismatchError, + UnknownKeyError: () => UnknownKeyError, + condenseAndPropagate: () => condenseAndPropagate, + dispatcher: () => dispatcher, + getDefaultErrorRange: () => getDefaultErrorRange, + getDefaultErrorReporter: () => getDefaultErrorReporter, + getPossibleTypes: () => getPossibleTypes, + isAssignable: () => isAssignable, + reference: () => reference2, + simplify: () => simplify, + typeDefinition: () => typeDefinition +}); + +// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/context.js +var McdocCheckerContext; +(function(McdocCheckerContext2) { + function create(ctx, options2) { + return { + ...ctx, + allowMissingKeys: options2.allowMissingKeys ?? false, + requireCanonical: options2.requireCanonical ?? false, + tryConvertTo: options2.tryConvertTo ?? (() => void 0), + getChildren: options2.getChildren ?? (() => []), + reportError: options2.reportError ?? (() => { + }), + attachTypeInfo: options2.attachTypeInfo, + nodeAttacher: options2.nodeAttacher, + stringAttacher: options2.stringAttacher + }; + } + McdocCheckerContext2.create = create; +})(McdocCheckerContext || (McdocCheckerContext = {})); + +// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/error.js +var SimpleError; +(function(SimpleError2) { + function is(error4) { + return error4?.kind === "duplicate_key" || error4?.kind === "unknown_key" || error4?.kind === "expected_key_value_pair" || error4?.kind === "unknown_tuple_element" || error4?.kind === "internal"; + } + SimpleError2.is = is; +})(SimpleError || (SimpleError = {})); +var UnknownKeyError; +(function(UnknownKeyError2) { + function is(error4) { + return error4?.kind === "unknown_key"; + } + UnknownKeyError2.is = is; +})(UnknownKeyError || (UnknownKeyError = {})); +var RangeError2; +(function(RangeError3) { + function is(error4) { + return error4?.kind === "invalid_collection_length" || error4?.kind === "invalid_string_length" || error4?.kind === "number_out_of_range"; + } + RangeError3.is = is; +})(RangeError2 || (RangeError2 = {})); +var MissingKeyError; +(function(MissingKeyError2) { + function is(error4) { + return error4?.kind === "missing_key"; + } + MissingKeyError2.is = is; +})(MissingKeyError || (MissingKeyError = {})); +var TypeMismatchError; +(function(TypeMismatchError2) { + function is(error4) { + return error4?.kind === "type_mismatch"; + } + TypeMismatchError2.is = is; +})(TypeMismatchError || (TypeMismatchError = {})); +function condenseAndPropagate(definitionGroup, definitionErrors) { + const queue = [{ node: definitionGroup, errorsOnLayer: definitionErrors, depth: 0 }]; + while (queue.length) { + const { node, errorsOnLayer, depth } = queue.shift(); + const stillValidDefinitions = []; + const { definitions, condensedErrors } = condenseErrorsAndFilterSiblings(errorsOnLayer); + stillValidDefinitions.push(...definitions); + node.condensedErrors.push(condensedErrors); + if (node.validDefinitions.length !== stillValidDefinitions.length) { + filterChildDefinitions(node.validDefinitions.filter((d) => !stillValidDefinitions.includes(d)), node.runtimeNode.children); + node.validDefinitions = stillValidDefinitions; + } + const parents = node.parents.filter((parent) => { + const lastDefWithNode = parent.groupNode.validDefinitions.findLast((d) => d.children.includes(node)); + if (lastDefWithNode !== parent) { + return false; + } + const lastChild = parent.groupNode.validDefinitions.flatMap((d) => d.children).findLast((v) => { + if (v.condensedErrors.length > depth) { + return true; + } + let children = [v]; + for (let i = 0; i < depth; i++) { + children = children.flatMap((v2) => v2.validDefinitions).flatMap((v2) => v2.children); + } + return children.length > 0; + }); + if (lastChild !== node) { + return false; + } + return true; + }).map((parent) => ({ + node: parent.groupNode, + depth: depth + 1, + errorsOnLayer: parent.groupNode.validDefinitions.flatMap((d) => ({ + definition: d, + errors: d.children.flatMap((c) => c.condensedErrors.length > depth ? c.condensedErrors[depth] : []) + })) + })); + queue.push(...parents); + } +} +function filterChildDefinitions(removedDefs, children) { + for (const child of children) { + for (const childValue of child.possibleValues) { + const removedChildDefs = []; + for (let i = 0; i < childValue.definitionsByParent.length; i++) { + const definitionGroup = childValue.definitionsByParent[i]; + definitionGroup.parents = definitionGroup.parents.filter((p) => !removedDefs.includes(p)); + if (definitionGroup.parents.length === 0) { + removedChildDefs.push(...definitionGroup.validDefinitions); + childValue.definitionsByParent.splice(i, 1); + i--; + } + } + if (removedChildDefs.length > 0) { + filterChildDefinitions(removedChildDefs, childValue.children); + } + } + } +} +function condenseErrorsAndFilterSiblings(definitions) { + if (definitions.length === 0) { + return { definitions: [], condensedErrors: [] }; + } + let validDefinitions = definitions; + const errors = []; + const typeMismatchResult = condense(validDefinitions, TypeMismatchError.is, (a, b) => a.expected.length === b.expected.length && !a.expected.some((d) => !b.expected.some((od) => McdocType.equals(d, od))), (errors2) => ({ + kind: "type_mismatch", + node: errors2[0].node, + expected: deduplicateGroups(errors2.map((e) => e.expected), McdocType.equals) + })); + validDefinitions = typeMismatchResult.filteredDefinitions; + errors.push(...typeMismatchResult.condensedErrors); + for (const kind of [ + "unknown_key", + "expected_key_value_pair", + "unknown_tuple_element" + ]) { + const simpleErrorResult = condense(validDefinitions, (e) => e.kind === kind, (_) => true); + validDefinitions = simpleErrorResult.filteredDefinitions; + errors.push(...simpleErrorResult.condensedErrors); + } + const missingKeyResult = condense(validDefinitions, MissingKeyError.is, (a, b) => !a.keys.some((k) => !b.keys.includes(k)), (errors2) => ({ + kind: "missing_key", + node: errors2[0].node, + keys: deduplicateGroups(errors2.map((e) => e.keys)) + })); + validDefinitions = missingKeyResult.filteredDefinitions; + errors.push(...missingKeyResult.condensedErrors); + for (const kind of [ + "invalid_collection_length", + "invalid_string_length", + "number_out_of_range" + ]) { + const rangeErrorResult = condense( + validDefinitions, + (e) => e.kind === kind, + (a, b) => a.ranges.length === b.ranges.length && !a.ranges.some((r) => !b.ranges.some((or) => NumericRange.equals(r, or))), + // TODO merge overlapping ranges better? + (errors2) => ({ + kind, + node: errors2[0].node, + ranges: deduplicateGroups(errors2.map((e) => e.ranges), NumericRange.equals) + }) + ); + validDefinitions = rangeErrorResult.filteredDefinitions; + errors.push(...rangeErrorResult.condensedErrors); + } + validDefinitions[0].errors.filter((e) => e.kind === "duplicate_key"); + const internalErrorResult = condense(validDefinitions, (e) => e.kind === "internal", (_) => false); + validDefinitions = internalErrorResult.filteredDefinitions; + errors.push(...internalErrorResult.condensedErrors); + return { + definitions: validDefinitions.map((d) => d.definition), + condensedErrors: errors + }; +} +function condense(validDefinitions, is, equals, combineAlternatives) { + const errorsOfType = validDefinitions.map((def) => ({ def, errors: def.errors.filter(is) })); + const definitionsWithoutError = errorsOfType.filter((d) => d.errors.length === 0).map((e) => e.def); + if (definitionsWithoutError.length > 0) { + return { condensedErrors: [], filteredDefinitions: definitionsWithoutError }; + } + const distinctErrorsPerNode = errorsOfType.flatMap((d) => d.errors.map((e) => ({ definition: d.def, error: e }))).reduce((entries, e) => { + const entry6 = entries.find((oe) => oe.errors[0].error.node === e.error.node); + if (entry6) { + const error4 = entry6.errors.find((oe) => equals(e.error, oe.error)); + if (error4) { + error4.definitions.push(e.definition); + } else { + entry6.errors.push({ error: e.error, definitions: [e.definition] }); + } + } else { + entries.push({ errors: [{ error: e.error, definitions: [e.definition] }] }); + } + return entries; + }, []); + const distinctErrors = distinctErrorsPerNode.flatMap((e) => e.errors); + const commonErrors = distinctErrors.filter((e) => e.definitions.length === validDefinitions.length).map((e) => e.error); + const definitionsWithUncommonErrors = distinctErrors.filter((e) => e.definitions.length < validDefinitions.length).flatMap((e) => e.definitions); + const definitionsWithOnlyCommonErrors = validDefinitions.filter((d) => !definitionsWithUncommonErrors.includes(d)); + if (definitionsWithOnlyCommonErrors.length > 0) { + return { + filteredDefinitions: definitionsWithOnlyCommonErrors, + condensedErrors: commonErrors + }; + } + const combinedErrors = combineAlternatives ? distinctErrorsPerNode.map((e) => { + const uniqueDefinitions = deduplicateGroups(e.errors.map((e2) => e2.definitions), (a, b) => McdocType.equals(a.definition.typeDef, b.definition.typeDef)); + const ans = { + definitions: uniqueDefinitions, + error: combineAlternatives(e.errors.filter((e2) => !commonErrors.includes(e2.error)).map((e2) => e2.error)) + }; + ans.error.nodesWithConflictingErrors = deduplicateGroups(e.errors.map((e2) => e2.error.nodesWithConflictingErrors ?? [])); + if (ans.error.nodesWithConflictingErrors.length === 0) { + ans.error.nodesWithConflictingErrors = void 0; + } + return ans; + }) : distinctErrorsPerNode.flatMap((e) => e.errors.map((ee) => ({ definitions: ee.definitions, error: ee.error }))); + const conflictingErrors = combinedErrors.filter((e) => e.definitions.length < validDefinitions.length); + const nodesWithConflictingErrors = conflictingErrors.map((e) => e.error.node).filter((n, i, arr) => arr.indexOf(n) === i); + for (const error4 of conflictingErrors) { + error4.error.nodesWithConflictingErrors = nodesWithConflictingErrors; + } + return { + filteredDefinitions: validDefinitions, + condensedErrors: [...commonErrors, ...combinedErrors.map((e) => e.error)] + }; +} +function deduplicateGroups(definitionGroups, predicate) { + const definitions = []; + for (let i = 0; i < definitionGroups.length; i++) { + const group = definitionGroups[i]; + if (group.length === 1) { + definitions.push(group[0]); + continue; + } + definitions.push(...group.filter((v) => !definitionGroups.some((og, oi) => (oi > i || og.length === 1) && predicate ? og.some((ov) => predicate(v, ov)) : og.includes(v)))); + } + return definitions; +} +function getDefaultErrorRange(node, error4) { + const { range: range3 } = node.originalNode; + if (error4 === "missing_key" || error4 === "invalid_collection_length") { + return { start: range3.start, end: range3.start + 1 }; + } + return range3; +} +function getDefaultErrorReporter(ctx, getErrorRange) { + return (error4) => { + const defaultTranslationKey = error4.kind.replaceAll("_", "-"); + let localizedText; + let severity = ErrorSeverity.Error; + switch (error4.kind) { + case "unknown_tuple_element": + localizedText = localize("expected", localize("nothing")); + break; + case "unknown_key": + if (error4.nodesWithConflictingErrors) { + localizedText = localize("invalid-key-combination", arrayToMessage(error4.nodesWithConflictingErrors.map((n) => McdocType.toString(n.inferredType)), true, "and")); + } else { + localizedText = localize(defaultTranslationKey, error4.node.inferredType.kind === "literal" ? localeQuote(error4.node.inferredType.value.value.toString()) : `<${localize(`mcdoc.type.${error4.node.inferredType.kind}`)}>`); + severity = ErrorSeverity.Warning; + } + break; + case "missing_key": + if (error4.keys.length === 1) { + localizedText = localize(defaultTranslationKey, localeQuote(error4.keys[0])); + } else { + localizedText = localize("mcdoc.runtime.checker.some-missing-keys", arrayToMessage(error4.keys)); + } + break; + case "invalid_collection_length": + case "invalid_string_length": + case "number_out_of_range": + const baseKey = error4.kind === "invalid_collection_length" ? "mcdoc.runtime.checker.range.collection" : error4.kind === "invalid_string_length" ? "mcdoc.runtime.checker.range.string" : "mcdoc.runtime.checker.range.number"; + const rangeMessages = error4.ranges.map((r) => { + const left = r.min !== void 0 ? localize(RangeKind.isLeftExclusive(r.kind) ? "mcdoc.runtime.checker.range.left-exclusive" : "mcdoc.runtime.checker.range.left-inclusive", r.min) : void 0; + const right = r.max !== void 0 ? localize(RangeKind.isLeftExclusive(r.kind) ? "mcdoc.runtime.checker.range.right-exclusive" : "mcdoc.runtime.checker.range.right-inclusive", r.max) : void 0; + if (left !== void 0 && right !== void 0) { + return localize("mcdoc.runtime.checker.range.concat", left, right); + } + return left ?? right; + }).filter((r) => r !== void 0); + localizedText = localize("expected", localize(baseKey, arrayToMessage(rangeMessages, false))); + break; + case "type_mismatch": + localizedText = localize("expected", arrayToMessage(error4.expected.map((e) => e.kind === "enum" ? arrayToMessage(e.values.map((v) => ResourceLocation.shorten(v.value.toString()))) : e.kind === "literal" ? localeQuote(e.value.value.toString()) : localize(`mcdoc.type.${e.kind}`)), false)); + break; + case "expected_key_value_pair": + localizedText = localize(`mcdoc.runtime.checker.${defaultTranslationKey}`); + break; + case "internal": + return; + default: + localizedText = localize(defaultTranslationKey); + } + ctx.err.report(localizedText, getErrorRange(error4.node, error4.kind), severity); + }; +} + +// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/index.js +function reference2(node, path6, ctx) { + typeDefinition(node, { kind: "reference", path: path6 }, ctx); +} +function dispatcher(node, registry, index4, ctx) { + const parallelIndices = typeof index4 === "string" ? [{ kind: "static", value: index4 }] : Array.isArray(index4) ? index4 : [index4]; + typeDefinition(node, { kind: "dispatcher", registry, parallelIndices }, ctx); +} +function isAssignable(assignValue, typeDef, ctx, convert) { + if (assignValue.kind === "literal" && typeDef.kind === "literal" && assignValue.value.kind === typeDef.value.kind && !assignValue.attributes && !typeDef.attributes) { + return assignValue.value.value === typeDef.value.value; + } + let ans = true; + const newCtx = McdocCheckerContext.create(ctx, { + tryConvertTo: convert, + getChildren: (_, d) => { + switch (d.kind) { + case "list": + const vals = getPossibleTypes(d.item); + return [vals.map((v) => ({ originalNode: v, inferredType: v }))]; + case "byte_array": + return [[{ + originalNode: { kind: "byte" }, + inferredType: { kind: "byte" } + }]]; + case "int_array": + return [[{ + originalNode: { kind: "int" }, + inferredType: { kind: "int" } + }]]; + case "long_array": + return [[{ + originalNode: { kind: "long" }, + inferredType: { kind: "long" } + }]]; + case "struct": + return d.fields.map((f) => { + const vals2 = getPossibleTypes(f.type); + return { + attributes: f.attributes, + key: { originalNode: f.key, inferredType: f.key }, + possibleValues: vals2.map((v) => ({ originalNode: v, inferredType: v })) + }; + }); + case "tuple": + return d.items.map((f) => { + const vals2 = getPossibleTypes(f); + return vals2.map((v) => ({ originalNode: v, inferredType: v })); + }); + default: + return []; + } + }, + reportError: () => { + ans = false; + } + }); + const node = { + parent: void 0, + runtimeKey: void 0, + possibleValues: [] + }; + node.possibleValues = getPossibleTypes(typeDef).map((v) => ({ + entryNode: node, + node: { originalNode: v, inferredType: v }, + children: [], + definitionsByParent: [] + })); + typeDefinition(getPossibleTypes(assignValue).map((v) => ({ originalNode: v, inferredType: v })), typeDef, newCtx); + return ans; +} +function typeDefinition(runtimeValues, typeDef, ctx) { + const rootNode = { + parent: void 0, + runtimeKey: void 0, + possibleValues: [] + }; + rootNode.possibleValues = runtimeValues.map((n) => ({ + node: n, + entryNode: rootNode, + definitionsByParent: [], + children: [] + })); + for (const value of rootNode.possibleValues) { + const simplifiedRoot = simplify(typeDef, { ctx, node: value }).typeDef; + const validRootDefinitions = simplifiedRoot.kind === "union" ? simplifiedRoot.members : [simplifiedRoot]; + if (validRootDefinitions.length === 0 && (typeDef.kind !== "union" || typeDef.members.length > 0)) { + validRootDefinitions.push({ kind: "any" }); + } + value.definitionsByParent = [{ + parents: [], + keyDefinition: void 0, + runtimeNode: value, + originalTypeDef: typeDef, + condensedErrors: [], + validDefinitions: [] + }]; + value.definitionsByParent[0].validDefinitions = validRootDefinitions.map((d) => ({ + groupNode: value.definitionsByParent[0], + typeDef: d, + children: [] + })); + } + const nodeQueue = [rootNode]; + while (nodeQueue.length !== 0) { + const node = nodeQueue.shift(); + for (const value of node.possibleValues) { + const inferredSimplified = simplify(value.node.inferredType, { ctx, node: value }).typeDef; + const children = ctx.getChildren(value.node.originalNode, inferredSimplified); + const childNodes = children.map((c) => { + const ans = { + parent: value, + runtimeKey: !Array.isArray(c) ? c.key : void 0, + possibleValues: [] + }; + ans.possibleValues = (Array.isArray(c) ? c : c.possibleValues).map((v) => ({ + entryNode: ans, + node: v, + definitionsByParent: [], + condensedErrors: [], + children: [] + })); + return ans; + }); + for (const definitionGroup of value.definitionsByParent) { + const definitionErrors = []; + if (definitionGroup.validDefinitions.length === 0) { + definitionGroup.condensedErrors = [[{ + kind: "type_mismatch", + node: value.node, + expected: [] + }]]; + } + for (const def of definitionGroup.validDefinitions) { + const { errors, childDefinitions } = checkShallowly(value.node, inferredSimplified, children, def.typeDef, ctx); + definitionErrors.push({ definition: def, errors }); + for (let i = 0; i < childDefinitions.length; i++) { + const childDef = childDefinitions[i]; + if (!childDef) { + continue; + } + const child = childNodes[i]; + const existingDef = child.possibleValues.length > 0 ? child.possibleValues[0].definitionsByParent.find((d) => (d.keyDefinition === void 0 || childDef.keyType === void 0 ? d.keyDefinition === void 0 : McdocType.equals(d.keyDefinition, childDef.keyType)) && McdocType.equals(d.originalTypeDef, childDef.type)) : void 0; + for (const childValue of child.possibleValues) { + if (existingDef) { + existingDef.parents.push(def); + def.children.push(existingDef); + continue; + } + const simplified = simplify(childDef.type, { ctx, node: childValue }).typeDef; + const childDefinitionGroup = { + parents: [def], + runtimeNode: childValue, + keyDefinition: childDef.keyType, + originalTypeDef: childDef.type, + validDefinitions: [], + condensedErrors: [], + desc: childDef.desc + }; + childDefinitionGroup.validDefinitions = (simplified.kind === "union" ? simplified.members : [simplified]).map((d) => ({ + groupNode: childDefinitionGroup, + typeDef: d, + children: [] + })); + childValue.definitionsByParent.push(childDefinitionGroup); + def.children.push(childDefinitionGroup); + } + } + } + condenseAndPropagate(definitionGroup, definitionErrors); + } + value.children = childNodes; + nodeQueue.push(...childNodes); + } + } + if (ctx.attachTypeInfo) { + for (const node of rootNode.possibleValues) { + attachTypeInfo(node, ctx); + } + } + for (const error4 of rootNode.possibleValues.flatMap((v) => v.definitionsByParent).flatMap((d) => d.condensedErrors).flat()) { + if (error4) { + ctx.reportError(error4); + } + } +} +function attachTypeInfo(node, ctx) { + const definitions = node.definitionsByParent.flatMap((d) => d.validDefinitions); + if (definitions.length === 1) { + const { typeDef, groupNode } = definitions[0]; + ctx.attachTypeInfo?.(node.node.originalNode, typeDef, groupNode.desc); + handleNodeAttachers(node.node, typeDef, ctx); + if (node.entryNode.runtimeKey && groupNode.keyDefinition) { + ctx.attachTypeInfo?.(node.entryNode.runtimeKey.originalNode, groupNode.keyDefinition, groupNode.desc); + handleNodeAttachers(node.entryNode.runtimeKey, groupNode.keyDefinition, ctx); + } + } else if (definitions.length > 1) { + ctx.attachTypeInfo?.(node.node.originalNode, { + kind: "union", + members: definitions.map((d) => d.typeDef) + }); + if (node.entryNode.runtimeKey) { + ctx.attachTypeInfo?.(node.entryNode.runtimeKey.originalNode, { + kind: "union", + members: node.definitionsByParent.map((d) => d.keyDefinition).filter((d) => d !== void 0) + }); + } + } + for (const child of node.children.flatMap((c) => c.possibleValues)) { + attachTypeInfo(child, ctx); + } +} +function handleNodeAttachers(runtimeValue, typeDef, ctx) { + const { nodeAttacher, stringAttacher } = ctx; + if (!nodeAttacher && !stringAttacher) { + return; + } + handleAttributes(typeDef.attributes, ctx, (handler, config) => { + const parser = handler.stringParser?.(config, typeDef, ctx); + if (parser && stringAttacher) { + stringAttacher(runtimeValue.originalNode, (node) => { + const src = new Source(node.value, node.valueMap); + const start = src.cursor; + const child = parser(src, ctx); + if (!child) { + ctx.err.report(localize("expected", localize("mcdoc.runtime.checker.value")), Range.create(start, src.skipRemaining())); + return; + } else if (src.canRead()) { + ctx.err.report(localize("mcdoc.runtime.checker.trailing"), Range.create(src.cursor, src.skipRemaining())); + } + node.children = [child]; + }); + } + const checker = handler.checker?.(config, runtimeValue.inferredType, ctx); + if (checker && nodeAttacher) { + nodeAttacher(runtimeValue.originalNode, (node) => { + checker(node, ctx); + }); + } + }); +} +function checkShallowly(runtimeNode, simplifiedInferred, children, typeDef, ctx) { + const childDefinitions = Array(children.length).fill(void 0); + if (typeDef.kind === "any" || typeDef.kind === "unsafe" || simplifiedInferred.kind === "unsafe") { + return { childDefinitions, errors: [] }; + } + const typeDefValueType = getValueType(typeDef); + let runtimeValueType = getValueType(simplifiedInferred); + if (runtimeValueType.kind !== typeDefValueType.kind) { + simplifiedInferred = ctx.tryConvertTo(runtimeNode.originalNode, typeDefValueType) ?? simplifiedInferred; + runtimeValueType = getValueType(simplifiedInferred); + } + if (runtimeValueType.kind !== typeDefValueType.kind) { + return { + childDefinitions, + errors: [{ kind: "type_mismatch", node: runtimeNode, expected: [typeDef] }] + }; + } + const errors = []; + let assignable = true; + handleAttributes(typeDef.attributes, ctx, (handler, config) => { + if (handler.checkInferred?.(config, simplifiedInferred, ctx) === false) { + assignable = false; + } + }); + if (!assignable) { + errors.push({ kind: "internal", node: runtimeNode }); + } + if (typeDef.kind === "literal" && (simplifiedInferred.kind !== "literal" || typeDef.value.value !== simplifiedInferred.value.value) || typeDef.kind === "enum" && (simplifiedInferred.kind !== "literal" || !typeDef.values.some((v) => v.value === simplifiedInferred.value.value))) { + return { + childDefinitions, + errors: [{ kind: "type_mismatch", node: runtimeNode, expected: [typeDef] }] + }; + } + switch (typeDef.kind) { + case "byte": + case "short": + case "int": + case "long": + case "float": + case "double": + if (typeDef.valueRange && simplifiedInferred.kind === "literal" && simplifiedInferred.value.kind !== "string" && simplifiedInferred.value.kind !== "boolean" && !NumericRange.isInRange(typeDef.valueRange, simplifiedInferred.value.value)) { + errors.push({ + kind: "number_out_of_range", + node: runtimeNode, + ranges: [typeDef.valueRange] + }); + } + break; + case "string": + if (typeDef.lengthRange && simplifiedInferred.kind === "literal" && simplifiedInferred.value.kind === "string" && !NumericRange.isInRange(typeDef.lengthRange, [...simplifiedInferred.value.value].length)) { + errors.push({ + kind: "invalid_string_length", + node: runtimeNode, + ranges: [typeDef.lengthRange] + }); + } + break; + case "struct": { + const literalKvps = /* @__PURE__ */ new Map(); + const otherKvps = []; + for (let i = 0; i < children.length; i++) { + const child = children[i]; + if (Array.isArray(child)) { + continue; + } + if (child.key.inferredType.kind === "literal" && child.key.inferredType.value.kind === "string") { + const existing = literalKvps.get(child.key.inferredType.value.value); + if (existing) { + existing.values.push({ pair: child, index: i }); + } else { + literalKvps.set(child.key.inferredType.value.value, { + values: [{ pair: child, index: i }], + definition: void 0 + }); + } + } else { + otherKvps.push({ value: child, index: i }); + } + } + const missingKeys = /* @__PURE__ */ new Set(); + for (const pair of typeDef.fields) { + const otherKvpMatches = []; + let foundMatch = false; + if (pair.key.kind === "literal" && pair.key.value.kind === "string") { + const runtimeChild = literalKvps.get(pair.key.value.value); + if (runtimeChild) { + foundMatch = true; + runtimeChild.definition = { keyType: pair.key, type: pair.type, desc: pair.desc }; + } + } + if (!foundMatch) { + for (const kvp of otherKvps) { + if (isAssignable(kvp.value.key.inferredType, pair.key, ctx, (type2, target) => type2 === kvp.value.key.inferredType ? ctx.tryConvertTo(kvp.value.key.originalNode, target) : void 0)) { + foundMatch = true; + otherKvpMatches.push(kvp.index); + } + } + for (const kvp of literalKvps.entries()) { + const literalType3 = { + kind: "literal", + value: { kind: "string", value: kvp[0] } + }; + if ((!kvp[1].definition || kvp[1].definition.keyType?.kind !== "literal") && kvp[1].values.some((v) => isAssignable(literalType3, pair.key, ctx, (type2, target) => type2 === literalType3 ? ctx.tryConvertTo(v.pair.key.originalNode, target) : void 0))) { + foundMatch = true; + kvp[1].definition = { keyType: pair.key, type: pair.type, desc: pair.desc }; + } + } + } + for (const match of otherKvpMatches) { + childDefinitions[match] = { keyType: pair.key, type: pair.type, desc: pair.desc }; + } + if (!foundMatch && !ctx.allowMissingKeys && pair.key.kind === "literal" && pair.key.value.kind === "string" && pair.optional !== true) { + missingKeys.add(pair.key.value.value); + } + } + errors.push(...Array.from(missingKeys).map((key2) => ({ + kind: "missing_key", + node: runtimeNode, + keys: [key2] + }))); + for (const kvp of literalKvps.values()) { + for (const value of kvp.values) { + childDefinitions[value.index] = kvp.definition; + if (kvp.values.length > 1) { + errors.push({ kind: "duplicate_key", node: value.pair.key }); + } + } + } + for (let i = 0; i < children.length; i++) { + const childDef = childDefinitions[i]; + const child = children[i]; + if (childDef === void 0) { + if (Array.isArray(child)) { + errors.push(...child.map((v) => ({ + kind: "expected_key_value_pair", + node: v + }))); + } else { + errors.push({ kind: "unknown_key", node: child.key }); + } + } + } + break; + } + case "list": + case "byte_array": + case "int_array": + case "long_array": { + let itemType; + switch (typeDef.kind) { + case "list": + itemType = typeDef.item; + break; + case "byte_array": + itemType = { kind: "byte", valueRange: typeDef.valueRange }; + break; + case "int_array": + itemType = { kind: "int", valueRange: typeDef.valueRange }; + break; + case "long_array": + itemType = { kind: "long", valueRange: typeDef.valueRange }; + break; + } + for (let i = 0; i < childDefinitions.length; i++) { + childDefinitions[i] = { type: itemType }; + } + if (typeDef.lengthRange && !NumericRange.isInRange(typeDef.lengthRange, children.length)) { + errors.push({ + kind: "invalid_collection_length", + node: runtimeNode, + ranges: [typeDef.lengthRange] + }); + } + break; + } + case "tuple": { + for (let i = 0; i < children.length; i++) { + const child = children[i]; + if (i < typeDef.items.length) { + childDefinitions[i] = { type: typeDef.items[i] }; + } else { + const values = Array.isArray(child) ? child : [...child.possibleValues, child.key]; + errors.push(...values.map((v) => ({ + kind: "unknown_tuple_element", + node: v + }))); + } + } + if (typeDef.items.length > children.length) { + errors.push({ + kind: "invalid_collection_length", + node: runtimeNode, + ranges: [{ kind: 0, max: typeDef.items.length, min: typeDef.items.length }] + }); + } + break; + } + } + return { childDefinitions, errors }; +} +function getPossibleTypes(typeDef) { + return typeDef.kind === "union" ? typeDef.members.flatMap((m) => getPossibleTypes(m)) : [typeDef]; +} +function simplify(typeDef, context) { + function wrap(result) { + if (!result.typeDef.attributes?.length) { + return result; + } + handleAttributes(typeDef.attributes, context.ctx, (handler, config) => { + if (handler.mapType) { + result.typeDef = handler.mapType(config, result.typeDef, context.ctx); + } + }); + return result; + } + switch (typeDef.kind) { + case "reference": + return wrap(simplifyReference(typeDef, context)); + case "dispatcher": + return wrap(simplifyDispatcher(typeDef, context)); + case "indexed": + return wrap(simplifyIndexed(typeDef, context)); + case "union": + return wrap(simplifyUnion(typeDef, context)); + case "struct": + return wrap(simplifyStruct(typeDef, context)); + case "list": + return wrap(simplifyList(typeDef, context)); + case "tuple": + return wrap(simplifyTuple(typeDef, context)); + case "enum": + return wrap(simplifyEnum(typeDef, context)); + case "concrete": + return wrap(simplifyConcrete(typeDef, context)); + case "template": + return wrap(simplifyTemplate(typeDef, context)); + case "mapped": + return wrap(simplifyMapped(typeDef, context)); + default: + return wrap({ typeDef }); + } +} +function simplifyReference(typeDef, context) { + if (!typeDef.path) { + context.ctx.logger.warn(`Tried to access empty reference`); + return { typeDef: { kind: "union", members: [] } }; + } + const mapped = context.typeMapping?.[typeDef.path]; + if (mapped) { + return { typeDef: mapped, dynamicData: true }; + } + const symbol7 = context.ctx.symbols.query(context.ctx.doc, "mcdoc", typeDef.path); + const data = symbol7.getData(TypeDefSymbolData.is); + if (!data?.typeDef) { + context.ctx.logger.warn(`Tried to access unknown reference ${typeDef.path}`); + return { typeDef: { kind: "union", members: [] } }; + } + if (context.ctx.config.env.enableMcdocCaching && data.simplifiedTypeDef) { + return { typeDef: data.simplifiedTypeDef }; + } + const simplifiedResult = simplify(data.typeDef, context); + if (typeDef.attributes?.length) { + simplifiedResult.typeDef = { + ...simplifiedResult.typeDef, + attributes: [...typeDef.attributes, ...simplifiedResult.typeDef.attributes ?? []] + }; + } + if (context.ctx.config.env.enableMcdocCaching && !simplifiedResult.dynamicData) { + symbol7.amend({ + data: { + data: { + ...data, + simplifiedTypeDef: simplifiedResult.typeDef + } + } + }); + } + return simplifiedResult; +} +function simplifyDispatcher(typeDef, context) { + const dispatcherQuery = context.ctx.symbols.query(context.ctx.doc, "mcdoc/dispatcher", typeDef.registry); + const dispatcher2 = dispatcherQuery.symbol?.members; + if (!dispatcher2) { + context.ctx.logger.warn(`Tried to access unknown dispatcher ${typeDef.registry}`); + return { typeDef: { kind: "union", members: [] } }; + } + const result = resolveIndices(typeDef.parallelIndices, dispatcher2, dispatcherQuery, context); + return result; +} +function simplifyIndexed(typeDef, context) { + const childResult = simplify(typeDef.child, { + ...context, + typeArgs: [] + }); + const child = childResult.typeDef; + if (child.kind !== "struct") { + context.ctx.logger.warn(`Tried to index un-indexable type ${child.kind}`); + return { typeDef: { kind: "union", members: [] }, dynamicData: childResult.dynamicData }; + } + const symbolMap = {}; + for (const field of child.fields) { + if (field.key.kind === "literal" && field.key.value.kind === "string") { + symbolMap[field.key.value.value] = { + data: { + typeDef: field.type + } + }; + } + } + const simplified = resolveIndices(typeDef.parallelIndices, symbolMap, void 0, context); + return { ...simplified, dynamicData: childResult.dynamicData ?? simplified.dynamicData }; +} +function resolveIndices(parallelIndices, symbolMap, symbolQuery, context) { + let dynamicData = false; + let values = []; + function pushValue(key2, data) { + if (!shouldKeepAccordingToAttributeFilters(data.typeDef.attributes, context.ctx)) { + return; + } + if (context.ctx.config.env.enableMcdocCaching && data.simplifiedTypeDef) { + if (data.simplifiedTypeDef.kind === "union") { + values.push(...data.simplifiedTypeDef.members); + } else { + values.push(data.simplifiedTypeDef); + } + } else { + const simplifiedResult = simplify(data.typeDef, context); + if (simplifiedResult.dynamicData) { + dynamicData = true; + } else if (context.ctx.config.env.enableMcdocCaching && symbolQuery) { + symbolQuery.member(key2, (s) => s.amend({ + data: { data: { ...data, simplifiedTypeDef: simplifiedResult.typeDef } } + })); + } + if (simplifiedResult.typeDef.kind === "union") { + values.push(...simplifiedResult.typeDef.members); + } else { + values.push(simplifiedResult.typeDef); + } + } + } + let unkownTypeDef = false; + function getUnknownTypeDef() { + if (unkownTypeDef === false) { + const data = symbolMap["%unknown"]?.data; + unkownTypeDef = TypeDefSymbolData.is(data) ? data : void 0; + } + return unkownTypeDef; + } + for (const index4 of parallelIndices) { + let lookup = []; + if (index4.kind === "static") { + if (index4.value === "%fallback") { + values = []; + for (const [key2, value] of Object.entries(symbolMap)) { + if (TypeDefSymbolData.is(value.data)) { + pushValue(key2, value.data); + } + } + break; + } + if (index4.value.startsWith("minecraft:")) { + lookup.push(index4.value.substring(10)); + } else { + lookup.push(index4.value); + } + } else { + dynamicData = true; + let possibilities = context.isMember ? [{ value: context.node, key: context.node.entryNode.runtimeKey }] : [{ + value: context.node.entryNode.parent, + key: context.node.entryNode.runtimeKey + }]; + for (const entry6 of index4.accessor) { + if (typeof entry6 !== "string" && entry6.keyword === "parent") { + possibilities = possibilities.map((n) => ({ + value: n.value?.entryNode.parent, + key: n.value?.entryNode.runtimeKey + })); + } else if (typeof entry6 !== "string" && entry6.keyword === "key") { + possibilities = possibilities.map((p) => ({ + value: p.key ? { node: p.key, entryNode: { parent: p.value, runtimeKey: p.key } } : void 0, + key: void 0 + })); + break; + } else if (typeof entry6 === "string") { + const newPossibilities = []; + for (const node of possibilities) { + const possibleChildren = node.value ? context.ctx.getChildren(node.value.node.originalNode, simplify(node.value.node.inferredType, { ...context, node: node.value }).typeDef).filter((child) => { + if (!Array.isArray(child)) { + return child.key.inferredType.kind === "literal" && child.key.inferredType.value.kind === "string" && child.key.inferredType.value.value === entry6; + } + return false; + }).flatMap((c) => c.possibleValues.map((v) => ({ + value: { + node: v, + entryNode: { parent: node.value, runtimeKey: c.key } + }, + key: void 0 + }))) : [{ value: void 0, key: void 0 }]; + newPossibilities.push(...possibleChildren); + } + possibilities = newPossibilities; + } else { + lookup.push("%none"); + break; + } + } + for (const value of possibilities.map((p) => p.value?.node)) { + if (value?.inferredType.kind === "literal" && value.inferredType.value.kind === "string") { + const ans = value.inferredType.value.value; + if (ans.startsWith("minecraft:")) { + lookup.push(ans.substring(10)); + } else { + lookup.push(ans); + } + } else { + lookup.push("%none"); + } + } + } + if (lookup.length === 0) { + lookup = ["%none"]; + } + const currentValues = lookup.map((v) => { + const data = symbolMap[v]?.data; + return { value: v, data: TypeDefSymbolData.is(data) ? data : getUnknownTypeDef() }; + }); + const missing = currentValues.find((v) => !v.data); + if (missing) { + return { typeDef: { kind: "any" }, dynamicData }; + } else { + for (const entry6 of currentValues) { + pushValue(entry6.value, entry6.data); + } + } + } + if (values.length === 1) { + return { typeDef: values[0], dynamicData }; + } + return { typeDef: { kind: "union", members: values }, dynamicData }; +} +function simplifyUnion(typeDef, context) { + let dynamicData = false; + let validMembers = typeDef.members.filter((member) => shouldKeepAccordingToAttributeFilters(member.attributes, context.ctx)); + const filterCanonical = context.ctx.requireCanonical && validMembers.some((m) => m.attributes?.some((a) => a.name === "canonical")); + if (filterCanonical) { + validMembers = validMembers.filter((member) => member.attributes?.some((a) => a.name === "canonical")); + } + if (validMembers.length === 1) { + return simplify(validMembers[0], context); + } + const members = []; + for (const member of validMembers) { + const { typeDef: simplified, dynamicData: memberDynamic } = simplify(member, context); + if (memberDynamic) { + dynamicData = true; + } + if (simplified.kind === "union") { + members.push(...simplified.members); + } else { + members.push(simplified); + } + } + if (members.length === 1) { + return { typeDef: members[0], dynamicData }; + } + return { typeDef: { kind: "union", members }, dynamicData }; +} +function simplifyStruct(typeDef, context) { + const fields = []; + let dynamicData = false; + function addField(key2, field) { + handleAttributes(field.attributes, context.ctx, (handler, config) => { + if (handler.mapField) { + field = handler.mapField(config, field, context.ctx); + } + }); + if (typeof key2 === "string") { + fields.push({ + ...field, + key: { kind: "literal", value: { kind: "string", value: key2 } } + }); + } else if (key2.kind === "union") { + key2.members.forEach((m) => addField(m, { ...field, optional: true })); + } else { + fields.push({ ...field, key: key2 }); + } + } + for (const field of typeDef.fields) { + if (!shouldKeepAccordingToAttributeFilters(field.attributes, context.ctx)) { + continue; + } + if (field.kind === "pair") { + let structKey2; + if (typeof field.key === "string") { + structKey2 = field.key; + } else { + const simplifiedKeyResult = simplify(field.key, { + ...context, + isMember: true, + typeArgs: [] + }); + if (simplifiedKeyResult.dynamicData) { + dynamicData = true; + } + structKey2 = simplifiedKeyResult.typeDef; + } + let mappedField; + if (context.typeMapping) { + mappedField = { + ...field, + type: { + kind: "mapped", + child: field.type, + mapping: context.typeMapping + } + }; + dynamicData = true; + } else { + mappedField = field; + } + addField(structKey2, mappedField); + } else { + const simplifiedSpread = simplify(field.type, { + ...context, + isMember: true, + typeArgs: [] + }); + if (simplifiedSpread.dynamicData) { + dynamicData = true; + } + if (simplifiedSpread.typeDef.kind === "any") { + fields.push({ kind: "pair", key: { kind: "any" }, type: { kind: "any" } }); + } else if (simplifiedSpread.typeDef.kind === "struct") { + fields.push(...simplifiedSpread.typeDef.fields); + } + } + } + return { + typeDef: { kind: "struct", fields }, + dynamicData + }; +} +function simplifyList(typeDef, context) { + if (!context.typeMapping) { + return { typeDef }; + } + return { + typeDef: { + ...typeDef, + item: { kind: "mapped", child: typeDef.item, mapping: context.typeMapping } + }, + // Don't cache mapped field data + // TODO find a better way to handle mapped types with caching + dynamicData: true + }; +} +function simplifyTuple(typeDef, context) { + if (!context.typeMapping) { + return { typeDef }; + } + return { + typeDef: { + ...typeDef, + items: typeDef.items.map((item) => ({ + kind: "mapped", + child: item, + mapping: context.typeMapping + })) + }, + // Don't cache mapped field data + // TODO find a better way to handle mapped types with caching + dynamicData: true + }; +} +function simplifyEnum(typeDef, context) { + const filteredValues = typeDef.values.filter((value) => shouldKeepAccordingToAttributeFilters(value.attributes, context.ctx)); + return { typeDef: { ...typeDef, values: filteredValues } }; +} +function simplifyConcrete(typeDef, context) { + let dynamicData = false; + const simplifiedArgs = typeDef.typeArgs.map((arg) => { + const ans = simplify(arg, context); + if (ans.dynamicData) { + dynamicData = true; + } + return ans.typeDef; + }); + const result = simplify(typeDef.child, { ...context, typeArgs: simplifiedArgs }); + return { typeDef: result.typeDef, dynamicData: dynamicData || result.dynamicData }; +} +function simplifyTemplate(typeDef, context) { + if (context.typeArgs?.length !== typeDef.typeParams.length) { + context.ctx.logger.warn(`Expected ${typeDef.typeParams.length} mcdoc type args for ${McdocType.toString(typeDef.child)}, but got ${context.typeArgs?.length ?? 0}`); + } + const mapping = Object.fromEntries(typeDef.typeParams.map((param, i) => { + const arg = context.typeArgs?.[i] ?? { kind: "union", members: [] }; + return [param.path, arg]; + })); + return simplify(typeDef.child, { ...context, typeArgs: [], typeMapping: mapping }); +} +function simplifyMapped(typeDef, context) { + let dynamicData = false; + const simplifiedMapping = Object.fromEntries(Object.entries(typeDef.mapping).map(([path6, param]) => { + const ans2 = simplify(param, context); + if (ans2.dynamicData) { + dynamicData = true; + } + return [path6, ans2.typeDef]; + })); + const ans = simplify(typeDef.child, { ...context, typeMapping: simplifiedMapping }); + return { typeDef: ans.typeDef, dynamicData: dynamicData || ans.dynamicData }; +} +function getValueType(type2) { + switch (type2.kind) { + case "literal": + return { kind: type2.value.kind }; + case "enum": + if (type2.enumKind === void 0) { + return { kind: "any" }; + } + return { kind: type2.enumKind }; + default: + return type2; + } +} + +// node_modules/@spyglassmc/mcdoc/lib/runtime/completer/index.js +var completer_exports = {}; +__export(completer_exports, { + getFields: () => getFields, + getValues: () => getValues +}); +function getFields(typeDef, ctx) { + switch (typeDef.kind) { + case "union": + const allFields = /* @__PURE__ */ new Map(); + for (const member of typeDef.members) { + for (const field of getFields(member, ctx)) { + allFields.set(field.key, field); + } + } + return [...allFields.values()]; + case "struct": + return typeDef.fields.flatMap((field) => { + if (typeof field.key === "string") { + return [{ key: field.key, field }]; + } + if (field.key.kind === "string" || field.key.kind === "literal" && field.key.value.kind === "string" || field.key.kind === "enum" && field.key.enumKind === "string") { + const ans = getStringCompletions(field.key, ctx); + if (ans.length > 0) { + return ans.map((c) => ({ key: c.value, field })); + } + } + if (field.key.kind === "literal") { + return [{ key: `${field.key.value.value}`, field }]; + } + if (field.key.kind === "string") { + return getStringCompletions(field.key, ctx).map((c) => ({ key: c.value, field })); + } + return getValues(field.key, ctx).map((c) => ({ key: c.value, field })); + }); + default: + return []; + } +} +function getValues(typeDef, ctx) { + if (typeDef.kind === "string" || typeDef.kind === "literal" && typeDef.value.kind === "string" || typeDef.kind === "enum" && typeDef.enumKind === "string") { + const ans = getStringCompletions(typeDef, ctx); + if (ans.length > 0) { + return ans; + } + } + switch (typeDef.kind) { + case "union": + const allValues = /* @__PURE__ */ new Map(); + for (const member of typeDef.members) { + for (const value of getValues(member, ctx)) { + allValues.set(value.value, value); + } + } + return [...allValues.values()]; + case "reference": + if (!typeDef.path) { + return []; + } + const symbol7 = ctx.symbols.query(ctx.doc, "mcdoc", typeDef.path); + const def = symbol7.getData(TypeDefSymbolData.is)?.typeDef; + if (!def) { + return []; + } + if (typeDef.attributes?.length) { + return getValues({ + ...def, + attributes: [...typeDef.attributes, ...def.attributes ?? []] + }, ctx); + } + return getValues(def, ctx); + case "literal": + return [{ value: `${typeDef.value.value}`, kind: typeDef.value.kind }]; + case "boolean": + return ["false", "true"].map((v) => ({ value: v, kind: "boolean" })); + case "enum": + const filteredValues = typeDef.values.filter((value) => shouldKeepAccordingToAttributeFilters(value.attributes, ctx)); + return filteredValues.map((v) => ({ + value: `${v.value}`, + detail: v.identifier, + kind: typeDef.enumKind ?? "string", + documentation: v.desc + })); + case "byte": + case "short": + case "int": + case "long": + case "float": + case "double": + return getNumericCompletions(typeDef, ctx); + default: + return []; + } +} +function getStringCompletions(typeDef, ctx) { + const ans = []; + handleAttributes(typeDef.attributes, ctx, (handler, config) => { + const mock = handler.stringMocker?.(config, typeDef, ctx); + if (!mock) { + return; + } + const items = ctx.meta.getCompleter(mock.type)(mock, ctx); + ans.push(...items.map((item) => ({ + value: item.label, + kind: "string", + labelSuffix: item.labelSuffix, + detail: item.detail, + completionKind: item.kind, + insertText: item.insertText, + sortText: item.sortText + }))); + }); + if (ans.length === 0 && typeDef.kind === "literal") { + ans.push({ value: `${typeDef.value.value}`, kind: "string" }); + } + return ans; +} +function getNumericCompletions(typeDef, ctx) { + const ans = []; + handleAttributes(typeDef.attributes, ctx, (handler, config) => { + const items = handler.numericCompleter?.(config, ctx); + if (!items) { + return; + } + ans.push(...items.map((item) => ({ + value: item.label, + kind: typeDef.kind, + labelSuffix: item.labelSuffix, + detail: item.detail, + completionKind: item.kind, + insertText: item.insertText, + sortText: item.sortText + }))); + }); + return ans; +} + +// node_modules/@spyglassmc/mcdoc/lib/index.js +var initialize = ({ meta }) => { + meta.registerLanguage("mcdoc", { extensions: [".mcdoc"], parser: module_2 }); + registerBuiltinAttributes(meta); + meta.registerUriBinder(uriBinder); + meta.setUriSorter(uriSorter); + registerMcdocBinders(meta); + registerMcdocColorizer(meta); + registerMcdocFormatter(meta); + registerMcdocChecker(meta); +}; + +// node_modules/@spyglassmc/json/lib/parser/index.js +var parser_exports2 = {}; +__export(parser_exports2, { + JsonStringOptions: () => JsonStringOptions, + array: () => array, + boolean: () => boolean6, + entry: () => entry, + file: () => file5, + null_: () => null_, + number: () => number3, + object: () => object, + string: () => string7 +}); + +// node_modules/@spyglassmc/json/lib/parser/boolean.js +var boolean6 = (src, _ctx) => { + const start = src.cursor; + if (src.trySkip("false")) { + return { type: "json:boolean", range: Range.create(start, src), value: false }; + } + if (src.trySkip("true")) { + return { type: "json:boolean", range: Range.create(start, src), value: true }; + } + return Failure; +}; + +// node_modules/@spyglassmc/json/lib/parser/null.js +var null_ = (src, ctx) => { + const start = src.cursor; + if (src.trySkip("null")) { + return { type: "json:null", range: Range.create(start, src) }; + } + return Failure; +}; + +// node_modules/@spyglassmc/json/lib/parser/number.js +var number3 = (src, ctx) => { + const value = select([{ + regex: /^-?(?:0|[1-9]\d*)(?!\d|[.eE])/, + parser: long2({ pattern: /^-?(?:0|[1-9]\d*)$/ }) + }, { + parser: float2({ + // Regex form of the chart from https://www.json.org. + pattern: /^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][-+]?\d+)?$/ + }) + }])(src, ctx); + return { type: "json:number", children: [value], value, range: value.range }; +}; + +// node_modules/@spyglassmc/json/lib/parser/string.js +var JsonStringOptions = { + escapable: { characters: ["b", "f", "n", "r", "t"], unicode: true }, + quotes: ['"'] +}; +var string7 = (src, ctx) => setType("json:string", string4(JsonStringOptions))(src, ctx); + +// node_modules/@spyglassmc/json/lib/parser/object.js +var object = (src, ctx) => setType("json:object", record2({ + start: "{", + pair: { key: string7, sep: ":", value: entry, end: ",", trailingEnd: false }, + end: "}" +}))(src, ctx); + +// node_modules/@spyglassmc/json/lib/parser/entry.js +var LegalNumberStart = /* @__PURE__ */ new Set(["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "-"]); +var entry = (src, ctx) => select([ + { predicate: (src2) => src2.tryPeek("["), parser: array }, + { predicate: (src2) => src2.tryPeek("false") || src2.tryPeek("true"), parser: boolean6 }, + { predicate: (src2) => src2.tryPeek("null"), parser: null_ }, + { predicate: (src2) => LegalNumberStart.has(src2.peek()), parser: number3 }, + { + predicate: (src2) => src2.tryPeek("{"), + parser: object + }, + { parser: string7 } +])(src, ctx); + +// node_modules/@spyglassmc/json/lib/parser/array.js +var array = (ctx, src) => setType("json:array", list({ start: "[", value: entry, sep: ",", trailingSep: false, end: "]" }))(ctx, src); + +// node_modules/@spyglassmc/json/lib/parser/file.js +var file5 = map(dumpErrors(entry), (res) => ({ type: "json:file", range: res.range, children: [res] })); + +// node_modules/@spyglassmc/json/lib/node/index.js +var JsonFileNode; +(function(JsonFileNode2) { + function is(obj) { + return obj?.type === "json:file"; + } + JsonFileNode2.is = is; +})(JsonFileNode || (JsonFileNode = {})); +var JsonNode; +(function(JsonNode2) { + function is(node) { + return JsonObjectNode.is(node) || JsonArrayNode.is(node) || JsonStringNode.is(node) || JsonNumberNode.is(node) || JsonBooleanNode.is(node) || JsonNullNode.is(node); + } + JsonNode2.is = is; +})(JsonNode || (JsonNode = {})); +var JsonObjectNode; +(function(JsonObjectNode2) { + function is(obj) { + return obj?.type === "json:object"; + } + JsonObjectNode2.is = is; + function mock(range3) { + return { type: "json:object", range: Range.get(range3), children: [] }; + } + JsonObjectNode2.mock = mock; +})(JsonObjectNode || (JsonObjectNode = {})); +var JsonPairNode; +(function(JsonPairNode2) { + function is(obj) { + return obj.type === "pair"; + } + JsonPairNode2.is = is; +})(JsonPairNode || (JsonPairNode = {})); +var JsonArrayNode; +(function(JsonArrayNode2) { + function is(obj) { + return obj?.type === "json:array"; + } + JsonArrayNode2.is = is; + function mock(range3) { + return { type: "json:array", range: Range.get(range3), children: [] }; + } + JsonArrayNode2.mock = mock; +})(JsonArrayNode || (JsonArrayNode = {})); +var JsonStringNode; +(function(JsonStringNode2) { + function is(obj) { + return obj?.type === "json:string"; + } + JsonStringNode2.is = is; + function mock(range3) { + return { ...StringNode.mock(range3, JsonStringOptions), type: "json:string" }; + } + JsonStringNode2.mock = mock; +})(JsonStringNode || (JsonStringNode = {})); +var JsonNumberNode; +(function(JsonNumberNode2) { + function is(obj) { + return obj.type === "json:number"; + } + JsonNumberNode2.is = is; +})(JsonNumberNode || (JsonNumberNode = {})); +var JsonBooleanNode; +(function(JsonBooleanNode2) { + function is(obj) { + return obj.type === "json:boolean"; + } + JsonBooleanNode2.is = is; +})(JsonBooleanNode || (JsonBooleanNode = {})); +var JsonNullNode; +(function(JsonNullNode2) { + function is(obj) { + return obj.type === "json:null"; + } + JsonNullNode2.is = is; +})(JsonNullNode || (JsonNullNode = {})); +var TypedJsonNode; +(function(TypedJsonNode2) { + function is(obj) { + return obj.type === "json:typed"; + } + TypedJsonNode2.is = is; +})(TypedJsonNode || (TypedJsonNode = {})); + +// node_modules/@spyglassmc/json/lib/checker/index.js +var typed = (node, ctx) => { + index(node.targetType)(node.children[0], ctx); +}; +function register(meta) { + meta.registerChecker("json:typed", typed); +} +function index(type2, options2) { + return (node, ctx) => { + runtime_exports.checker.typeDefinition([{ originalNode: node, inferredType: inferType(node) }], type2, runtime_exports.checker.McdocCheckerContext.create(ctx, { + tryConvertTo: (node2, target) => { + switch (node2.type) { + case "json:array": + switch (target.kind) { + case "list": + return { kind: "list", item: { kind: "any" } }; + case "byte_array": + case "int_array": + case "long_array": + return { kind: target.kind }; + case "tuple": + return { kind: "tuple", items: [] }; + } + break; + case "json:number": + const literalValue = LiteralNumericValue.makeIfValid(target.kind, node2.value.value, true, true); + if (literalValue !== void 0) { + return { kind: "literal", value: literalValue }; + } + } + return void 0; + }, + getChildren: (node2) => { + if (node2.type === "json:array") { + return node2.children.filter((n) => n.value).map((n) => [{ originalNode: n.value, inferredType: inferType(n.value) }]); + } + if (node2.type === "json:object") { + return node2.children.filter((kvp) => kvp.key).map((kvp) => ({ + key: { originalNode: kvp.key, inferredType: inferType(kvp.key) }, + possibleValues: kvp.value ? [{ originalNode: kvp.value, inferredType: inferType(kvp.value) }] : [] + })); + } + return []; + }, + reportError: (err) => { + if (err.kind === "duplicate_key" && options2?.discardDuplicateKeyErrors) { + return; + } + runtime_exports.checker.getDefaultErrorReporter(ctx, runtime_exports.checker.getDefaultErrorRange)(err); + }, + attachTypeInfo: (node2, definition, desc = "") => { + node2.typeDef = definition; + if (node2.parent && JsonPairNode?.is(node2.parent)) { + if (node2.parent.key?.typeDef && node2.parent.value?.typeDef) { + const valueString = McdocType.toString(node2.parent.value.typeDef); + let keyString = McdocType.toString(node2.parent.key.typeDef); + if (node2.parent.key.typeDef.kind !== "literal") { + keyString = `[${keyString}]`; + } + const hover = `\`\`\`typescript +${keyString}: ${valueString} +\`\`\` +${desc}`; + node2.parent.key.hover = hover; + if (node2.parent.value.type !== "json:array" && node2.parent.value.type !== "json:object") { + node2.parent.value.hover = `\`\`\`typescript +${valueString} +\`\`\` +${desc}`; + } + } + } else if (node2.type !== "json:array" && node2.type !== "json:object") { + node2.hover = `\`\`\`typescript +${McdocType.toString(definition)} +\`\`\` +${desc}`; + } + }, + nodeAttacher: (node2, attacher) => attacher(node2), + stringAttacher: (node2, attacher) => { + if (!JsonStringNode.is(node2)) { + return; + } + attacher(node2); + if (node2.children) { + AstNode.setParents(node2); + builtin_exports.fallbackSync(node2, ctx); + builtin_exports2.fallbackSync(node2, ctx); + } + } + })); + }; +} +function inferType(node) { + switch (node.type) { + case "json:boolean": + return { kind: "literal", value: { kind: "boolean", value: node.value } }; + case "json:number": + return { + kind: "literal", + value: { + kind: node.value.type, + value: node.value.value + } + }; + case "json:null": + return { kind: "any" }; + // null is always invalid? + case "json:string": + return { kind: "literal", value: { kind: "string", value: node.value } }; + case "json:array": + return { kind: "list", item: { kind: "any" } }; + case "json:object": + return { kind: "struct", fields: [] }; + } +} + +// node_modules/@spyglassmc/json/lib/colorizer/index.js +var boolean7 = (node) => { + return [ColorToken.create(node, "literal")]; +}; +var null_2 = (node) => { + return [ColorToken.create(node, "literal")]; +}; +var object2 = (node, ctx) => { + const ans = []; + for (const pair of node.children) { + if (pair.key) { + ans.push(ColorToken.create(pair.key, "property")); + } + if (pair.value) { + const colorizer = ctx.meta.getColorizer(pair.value.type); + ans.push(...colorizer(pair.value, ctx)); + } + } + return ans; +}; +var string8 = (node, ctx) => { + if (node.children && node.children?.length > 0) { + const child = node.children[0]; + const colorizer = ctx.meta.getColorizer(child.type); + return colorizer(child, ctx); + } + return builtin_exports4.string(node, ctx); +}; +function register2(meta) { + meta.registerColorizer("json:boolean", boolean7); + meta.registerColorizer("json:null", null_2); + meta.registerColorizer("json:number", builtin_exports4.number); + meta.registerColorizer("json:object", object2); + meta.registerColorizer("json:string", string8); +} + +// node_modules/@spyglassmc/json/lib/completer/index.js +var array2 = (node, ctx) => { + const index4 = binarySearch(node.children, ctx.offset, (n, o) => { + return Range.compareOffset(n.range, o, true); + }); + const item = index4 >= 0 ? node.children[index4] : void 0; + if (item?.value) { + return ctx.meta.getCompleter(item.value.type)(item.value, ctx); + } + if (node.typeDef?.kind === "list") { + const completions = getValues2(node.typeDef.item, ctx.offset, ctx); + if (ctx.offset < (node.children[node.children.length - 1]?.range.start ?? 0)) { + return completions.map((c) => ({ ...c, insertText: c.insertText + "," })); + } + return completions; + } + return []; +}; +var object3 = builtin_exports5.record({ + key: (record3, pair, ctx, range3, iv, ipe, exitingKeys) => { + if (!record3.typeDef) { + return []; + } + const keySet = new Set(exitingKeys.map((n) => n.value)); + return runtime_exports.completer.getFields(record3.typeDef, ctx).filter(({ key: key2 }) => !keySet.has(key2)).map(({ key: key2, field }) => CompletionItem.create(key2, pair?.key ?? range3, { + kind: 5, + detail: McdocType.toString(field.type), + documentation: field.desc, + deprecated: field.deprecated, + sortText: field.optional ? "$b" : "$a", + // sort above hardcoded $schema + filterText: `"${key2}"`, + insertText: `"${key2}"${iv ? ": " : ""}${ipe ? "$1," : ""}` + })); + }, + value: (record3, pair, ctx, range3) => { + if (pair.value) { + return ctx.meta.getCompleter(pair.value.type)(pair.value, ctx); + } + if (pair.key && record3.typeDef) { + const pairKey = pair.key.value; + const field = runtime_exports.completer.getFields(record3.typeDef, ctx).find(({ key: key2 }) => key2 === pairKey)?.field.type; + if (field) { + return getValues2(field, range3, ctx); + } + } + return []; + } +}); +var primitive = (node, ctx) => { + const insideRange = Range.contains(node, ctx.offset, true); + if (node.type === "json:string" && node.children?.length && insideRange) { + const childItems = builtin_exports5.string(node, ctx); + if (childItems.length > 0) { + return childItems; + } + } + if (!node.typeDef) { + return []; + } + return getValues2(node.typeDef, insideRange ? node : ctx.offset, ctx); +}; +function getValues2(typeDef, range3, ctx) { + return runtime_exports.completer.getValues(typeDef, ctx).map(({ value, labelSuffix, detail, documentation, kind, completionKind, insertText, sortText }) => CompletionItem.create(value, range3, { + kind: completionKind ?? 12, + labelSuffix, + detail, + documentation, + filterText: kind === "string" ? `"${value}"` : value, + insertText: kind === "string" ? `"${insertText ?? value}"` : insertText ?? value, + sortText + })); +} +function register3(meta) { + meta.registerCompleter("json:array", array2); + meta.registerCompleter("json:boolean", primitive); + meta.registerCompleter("json:number", primitive); + meta.registerCompleter("json:null", primitive); + meta.registerCompleter("json:object", object3); + meta.registerCompleter("json:string", primitive); +} + +// node_modules/@spyglassmc/json/lib/formatter/index.js +var file6 = (node, ctx) => { + const child = node.children[0]; + return ctx.meta.getFormatter(child.type)(child, ctx); +}; +var array3 = (node, ctx) => { + if (node.children.length === 0) { + return "[]"; + } + const values = node.children.map((child) => { + const value = child.value && ctx.meta.getFormatter(child.value.type)(child.value, indentFormatter(ctx)); + return `${ctx.indent(1)}${value ?? ""}`; + }); + return `[ +${values.join(",\n")} +${ctx.indent()}]`; +}; +var object4 = (node, ctx) => { + if (node.children.length === 0) { + return "{}"; + } + const fields = node.children.map((child) => { + const key2 = child.key && string9(child.key, ctx); + const value = child.value && ctx.meta.getFormatter(child.value.type)(child.value, indentFormatter(ctx)); + return `${ctx.indent(1)}${key2 ?? ""}: ${value ?? ""}`; + }); + return `{ +${fields.join(",\n")} +${ctx.indent()}}`; +}; +var number4 = (node, ctx) => { + return ctx.meta.getFormatter(node.value.type)(node.value, ctx); +}; +var string9 = (node, ctx) => { + return JSON.stringify(node.value); +}; +function register4(meta) { + meta.registerFormatter("json:file", file6); + meta.registerFormatter("json:array", array3); + meta.registerFormatter("json:boolean", builtin_exports6.boolean); + meta.registerFormatter("json:null", () => "null"); + meta.registerFormatter("json:number", number4); + meta.registerFormatter("json:object", object4); + meta.registerFormatter("json:string", string9); +} + +// node_modules/@spyglassmc/json/lib/index.js +function getInitializer(jsonUriPredicate) { + return ({ meta }) => { + meta.registerLanguage("json", { + extensions: [".json"], + uriPredicate: jsonUriPredicate, + triggerCharacters: ["\n", ":", '"'], + parser: file5 + }); + meta.registerLanguage("mcmeta", { + extensions: [".mcmeta"], + triggerCharacters: ["\n", ":", '"'], + parser: file5 + }); + meta.registerParser("json:entry", entry); + register(meta); + register2(meta); + register3(meta); + register4(meta); + }; +} + +// node_modules/@spyglassmc/nbt/lib/checker/index.js +var checker_exports4 = {}; +__export(checker_exports4, { + blockStates: () => blockStates, + index: () => index2, + path: () => path3, + register: () => register5, + typeDefinition: () => typeDefinition2, + typed: () => typed2 +}); + +// node_modules/@spyglassmc/nbt/lib/node/index.js +var NbtNode; +(function(NbtNode3) { + function is(node) { + return NbtPrimitiveNode.is(node) || NbtCompoundNode.is(node) || NbtCollectionNode.is(node); + } + NbtNode3.is = is; +})(NbtNode || (NbtNode = {})); +var NbtPrimitiveNode; +(function(NbtPrimitiveNode2) { + function is(node) { + return NbtNumberNode.is(node) || NbtStringNode.is(node); + } + NbtPrimitiveNode2.is = is; +})(NbtPrimitiveNode || (NbtPrimitiveNode = {})); +var NbtStringNode; +(function(NbtStringNode2) { + function is(obj) { + return obj?.type === "nbt:string"; + } + NbtStringNode2.is = is; +})(NbtStringNode || (NbtStringNode = {})); +var NbtNumberNode; +(function(NbtNumberNode2) { + function is(node) { + return NbtIntegerAlikeNode.is(node) || NbtFloatAlikeNode.is(node); + } + NbtNumberNode2.is = is; +})(NbtNumberNode || (NbtNumberNode = {})); +var NbtIntegerAlikeNode; +(function(NbtIntegerAlikeNode2) { + function is(node) { + return NbtByteNode.is(node) || NbtShortNode.is(node) || NbtIntNode.is(node) || NbtLongNode.is(node); + } + NbtIntegerAlikeNode2.is = is; +})(NbtIntegerAlikeNode || (NbtIntegerAlikeNode = {})); +var NbtByteNode; +(function(NbtByteNode2) { + function is(node) { + return node?.type === "nbt:byte"; + } + NbtByteNode2.is = is; +})(NbtByteNode || (NbtByteNode = {})); +var NbtShortNode; +(function(NbtShortNode2) { + function is(node) { + return node?.type === "nbt:short"; + } + NbtShortNode2.is = is; +})(NbtShortNode || (NbtShortNode = {})); +var NbtIntNode; +(function(NbtIntNode2) { + function is(node) { + return node?.type === "nbt:int"; + } + NbtIntNode2.is = is; +})(NbtIntNode || (NbtIntNode = {})); +var NbtLongNode; +(function(NbtLongNode2) { + function is(node) { + return node?.type === "nbt:long"; + } + NbtLongNode2.is = is; +})(NbtLongNode || (NbtLongNode = {})); +var NbtFloatAlikeNode; +(function(NbtFloatAlikeNode2) { + function is(node) { + return NbtFloatNode.is(node) || NbtDoubleNode.is(node); + } + NbtFloatAlikeNode2.is = is; +})(NbtFloatAlikeNode || (NbtFloatAlikeNode = {})); +var NbtFloatNode; +(function(NbtFloatNode2) { + function is(node) { + return node?.type === "nbt:float"; + } + NbtFloatNode2.is = is; +})(NbtFloatNode || (NbtFloatNode = {})); +var NbtDoubleNode; +(function(NbtDoubleNode2) { + function is(node) { + return node?.type === "nbt:double"; + } + NbtDoubleNode2.is = is; +})(NbtDoubleNode || (NbtDoubleNode = {})); +var NbtCompoundNode; +(function(NbtCompoundNode2) { + function is(node) { + return node?.type === "nbt:compound"; + } + NbtCompoundNode2.is = is; +})(NbtCompoundNode || (NbtCompoundNode = {})); +var NbtCollectionNode; +(function(NbtCollectionNode2) { + function is(node) { + return NbtListNode.is(node) || NbtPrimitiveArrayNode.is(node); + } + NbtCollectionNode2.is = is; +})(NbtCollectionNode || (NbtCollectionNode = {})); +var NbtListNode; +(function(NbtListNode2) { + function is(node) { + return node?.type === "nbt:list"; + } + NbtListNode2.is = is; +})(NbtListNode || (NbtListNode = {})); +var NbtPrimitiveArrayNode; +(function(NbtPrimitiveArrayNode2) { + function is(node) { + return NbtByteArrayNode.is(node) || NbtIntArrayNode.is(node) || NbtLongArrayNode.is(node); + } + NbtPrimitiveArrayNode2.is = is; +})(NbtPrimitiveArrayNode || (NbtPrimitiveArrayNode = {})); +var NbtByteArrayNode; +(function(NbtByteArrayNode2) { + function is(node) { + return node?.type === "nbt:byte_array"; + } + NbtByteArrayNode2.is = is; +})(NbtByteArrayNode || (NbtByteArrayNode = {})); +var NbtIntArrayNode; +(function(NbtIntArrayNode2) { + function is(node) { + return node?.type === "nbt:int_array"; + } + NbtIntArrayNode2.is = is; +})(NbtIntArrayNode || (NbtIntArrayNode = {})); +var NbtLongArrayNode; +(function(NbtLongArrayNode2) { + function is(node) { + return node?.type === "nbt:long_array"; + } + NbtLongArrayNode2.is = is; +})(NbtLongArrayNode || (NbtLongArrayNode = {})); +var NbtPathNode; +(function(NbtPathNode3) { + function is(node) { + return node?.type === "nbt:path"; + } + NbtPathNode3.is = is; +})(NbtPathNode || (NbtPathNode = {})); +var NbtPathKeyNode; +(function(NbtPathKeyNode2) { + function is(node) { + return node?.type === "nbt:path/key"; + } + NbtPathKeyNode2.is = is; +})(NbtPathKeyNode || (NbtPathKeyNode = {})); +var NbtPathFilterNode; +(function(NbtPathFilterNode2) { + function is(node) { + return node?.type === "nbt:path/filter"; + } + NbtPathFilterNode2.is = is; +})(NbtPathFilterNode || (NbtPathFilterNode = {})); +var NbtPathIndexNode; +(function(NbtPathIndexNode2) { + function is(node) { + return node?.type === "nbt:path/index"; + } + NbtPathIndexNode2.is = is; +})(NbtPathIndexNode || (NbtPathIndexNode = {})); +var TypedNbtNode; +(function(TypedNbtNode2) { + function is(node) { + return node?.type === "nbt:typed"; + } + TypedNbtNode2.is = is; +})(TypedNbtNode || (TypedNbtNode = {})); + +// node_modules/@spyglassmc/nbt/lib/checker/mcdocUtil.js +var BlockItems = { + // Coral fans. + "minecraft:brain_coral_fan": ["minecraft:brain_coral_fan", "minecraft:brain_coral_wall_fan"], + "minecraft:bubble_coral_fan": ["minecraft:bubble_coral_fan", "minecraft:bubble_coral_wall_fan"], + "minecraft:fire_coral_fan": ["minecraft:fire_coral_fan", "minecraft:fire_coral_wall_fan"], + "minecraft:horn_coral_fan": ["minecraft:horn_coral_fan", "minecraft:horn_coral_wall_fan"], + "minecraft:tube_coral_fan": ["minecraft:tube_coral_fan", "minecraft:tube_coral_wall_fan"], + // Heads and skulls. + "minecraft:creeper_head": ["minecraft:creeper_head", "minecraft:creeper_wall_head"], + "minecraft:dragon_head": ["minecraft:dragon_head", "minecraft:dragon_wall_head"], + "minecraft:player_head": ["minecraft:player_head", "minecraft:player_wall_head"], + "minecraft:skeleton_skull": ["minecraft:skeleton_skull", "minecraft:skeleton_wall_skull"], + "minecraft:wither_skeleton_skull": [ + "minecraft:wither_skeleton_skull", + "minecraft:wither_skeleton_wall_skull" + ], + // Dead coral fans. + "minecraft:dead_brain_coral_fan": [ + "minecraft:dead_brain_coral_fan", + "minecraft:dead_brain_coral_wall_fan" + ], + "minecraft:dead_bubble_coral_fan": [ + "minecraft:dead_bubble_coral_fan", + "minecraft:dead_bubble_coral_wall_fan" + ], + "minecraft:dead_fire_coral_fan": [ + "minecraft:dead_fire_coral_fan", + "minecraft:dead_fire_coral_wall_fan" + ], + "minecraft:dead_horn_coral_fan": [ + "minecraft:dead_horn_coral_fan", + "minecraft:dead_horn_coral_wall_fan" + ], + "minecraft:dead_tube_coral_fan": [ + "minecraft:dead_tube_coral_fan", + "minecraft:dead_tube_coral_wall_fan" + ], + // Torches. + "minecraft:torch": ["minecraft:torch", "minecraft:wall_torch"], + "minecraft:soul_torch": ["minecraft:soul_torch", "minecraft:soul_wall_torch"], + "minecraft:redstone_torch": ["minecraft:redstone_torch", "minecraft:redstone_wall_torch"], + "minecraft:beetroot_seeds": ["minecraft:beetroots"], + "minecraft:carrot": ["minecraft:carrots"], + "minecraft:cocoa_beans": ["minecraft:cocoa"], + "minecraft:glow_berries": ["minecraft:cave_vines"], + "minecraft:melon_seeds": ["minecraft:melon_stem"], + "minecraft:potato": ["minecraft:potatoes"], + "minecraft:pumpkin_seeds": ["minecraft:pumpkin_stem"], + "minecraft:redstone": ["minecraft:redstone_wire"], + "minecraft:string": ["minecraft:tripwire"], + "minecraft:sweat_berries": ["minecraft:sweat_berry_bush"], + "minecraft:wheat_seeds": ["minecraft:wheat"] +}; +function getBlocksFromItem(item) { + return BlockItems[item]; +} +function getEntityFromItem(item) { + if (item === "minecraft:armor_stand") { + return item; + } + const result = item.match(/^minecraft:([a-z0-9_]+)_spawn_egg$/); + if (result) { + return `minecraft:${result[1]}`; + } + return void 0; +} + +// node_modules/@spyglassmc/nbt/lib/checker/index.js +var typed2 = (node, ctx) => { + typeDefinition2(node.targetType)(node.children[0], ctx); +}; +function register5(meta) { + meta.registerChecker("nbt:typed", typed2); +} +function index2(registry, id, options2 = {}) { + switch (registry) { + case "custom:blockitemstates": + const blockIds = getBlocksFromItem(id); + return blockIds ? blockStates(blockIds, options2) : builtin_exports2.noop; + case "custom:blockstates": + return blockStates([id], options2); + case "custom:spawnitemtag": + const entityId = getEntityFromItem(id); + return entityId ? index2("minecraft:entity", entityId, options2) : builtin_exports2.noop; + default: + const typeDef = { + kind: "dispatcher", + registry, + parallelIndices: getIndices(id) + }; + return (node, ctx) => { + typeDefinition2(typeDef, options2)(node, ctx); + }; + } +} +function getIndices(id) { + if (typeof id === "string") { + return [{ kind: "static", value: id }]; + } else if (id === void 0 || id.length === 0) { + return [{ kind: "static", value: "%fallback" }]; + } else { + return id.map((i) => ({ kind: "static", value: i })); + } +} +function typeDefinition2(typeDef, options2 = {}) { + return (node, ctx) => { + runtime_exports.checker.typeDefinition([{ originalNode: node, inferredType: inferType2(node) }], typeDef, runtime_exports.checker.McdocCheckerContext.create(ctx, { + allowMissingKeys: options2.isPredicate || options2.isMerge, + requireCanonical: options2.isPredicate, + tryConvertTo: (node2, target) => { + if (target.kind === "boolean" && NbtByteNode.is(node2)) { + if (node2.value === 0) { + return { kind: "literal", value: { kind: "boolean", value: false } }; + } else if (node2.value === 1) { + return { kind: "literal", value: { kind: "boolean", value: true } }; + } + } + if (target.kind === "tuple" && NbtListNode.is(node2)) { + return { + kind: "tuple", + items: [] + }; + } + if (!options2.isPredicate) { + if (NbtNumberNode.is(node2)) { + const literalValue = LiteralNumericValue.makeIfValid(target.kind, node2.value, NbtIntegerAlikeNode.is(node2), true); + if (literalValue !== void 0) { + return { kind: "literal", value: literalValue }; + } + } + if (NbtCollectionNode.is(node2)) { + switch (target.kind) { + case "list": + return { kind: "list", item: { kind: "any" } }; + case "byte_array": + case "int_array": + case "long_array": + return { kind: target.kind }; + case "tuple": + return { kind: "tuple", items: [] }; + } + } + } + return void 0; + }, + getChildren: (node2) => { + const { type: type2 } = node2; + if (type2 === "nbt:list" || type2 === "nbt:byte_array" || type2 === "nbt:int_array" || type2 === "nbt:long_array") { + return node2.children.filter((n) => n.value).map((n) => [{ originalNode: n.value, inferredType: inferType2(n.value) }]); + } + if (type2 === "nbt:compound") { + return node2.children.filter((kvp) => kvp.key).map((kvp) => ({ + key: { originalNode: kvp.key, inferredType: inferType2(kvp.key) }, + possibleValues: kvp.value ? [{ originalNode: kvp.value, inferredType: inferType2(kvp.value) }] : [] + })); + } + return []; + }, + reportError: (error4) => { + if (options2.isPredicate && error4.kind === "invalid_collection_length") { + return; + } + runtime_exports.checker.getDefaultErrorReporter(ctx, runtime_exports.checker.getDefaultErrorRange)(error4); + }, + attachTypeInfo: (node2, definition, desc = "") => { + node2.typeDef = definition; + node2.requireCanonical = options2.isPredicate; + if (node2.parent && PairNode?.is(node2.parent) && NbtNode.is(node2.parent.key) && NbtNode.is(node2.parent.value)) { + if (node2.parent.key?.typeDef && node2.parent.value?.typeDef) { + const valueString = McdocType.toString(node2.parent.value.typeDef); + let keyString = McdocType.toString(node2.parent.key.typeDef); + if (node2.parent.key.typeDef.kind !== "literal") { + keyString = `[${keyString}]`; + } + node2.parent.key.hover = `\`\`\`typescript +${keyString}: ${valueString} +\`\`\` +${desc}`; + if (NbtPrimitiveNode.is(node2.parent.value)) { + node2.parent.value.hover = `\`\`\`typescript +${valueString} +\`\`\` +${desc}`; + } + } + } else if (NbtPrimitiveNode.is(node2)) { + node2.hover = `\`\`\`typescript +${McdocType.toString(definition)} +\`\`\` +${desc}`; + } + }, + nodeAttacher: (node2, attacher) => attacher(node2), + stringAttacher: (node2, attacher) => { + if (!NbtStringNode.is(node2)) { + return; + } + attacher(node2); + if (node2.children) { + AstNode.setParents(node2); + builtin_exports.fallbackSync(node2, ctx); + builtin_exports2.fallbackSync(node2, ctx); + } + } + })); + }; +} +function inferType2(node) { + switch (node.type) { + case "nbt:byte": + return { kind: "literal", value: { kind: "byte", value: node.value } }; + case "nbt:double": + return { kind: "literal", value: { kind: "double", value: node.value } }; + case "nbt:float": + return { kind: "literal", value: { kind: "float", value: node.value } }; + case "nbt:long": + return { kind: "literal", value: { kind: "long", value: node.value } }; + case "nbt:int": + return { kind: "literal", value: { kind: "int", value: node.value } }; + case "nbt:short": + return { kind: "literal", value: { kind: "short", value: node.value } }; + case "nbt:string": + return { kind: "literal", value: { kind: "string", value: node.value } }; + case "nbt:list": + return { kind: "list", item: { kind: "any" } }; + case "nbt:compound": + return { kind: "struct", fields: [] }; + case "nbt:byte_array": + return { kind: "byte_array" }; + case "nbt:long_array": + return { kind: "long_array" }; + case "nbt:int_array": + return { kind: "int_array" }; + } +} +function blockStates(blocks, _options = {}) { + return (node, ctx) => { + if (!NbtCompoundNode.is(node)) { + return; + } + const states = getStates("block", blocks, ctx); + for (const { key: keyNode, value: valueNode } of node.children) { + if (!keyNode || !valueNode) { + continue; + } + if (valueNode.type === "nbt:byte" && (ctx.src.slice(valueNode.range).toLowerCase() === "false" || ctx.src.slice(valueNode.range).toLowerCase() === "true")) { + ctx.err.report(localize("nbt.checker.block-states.fake-boolean"), valueNode, ErrorSeverity.Warning); + continue; + } else if (valueNode.type !== "nbt:string" && valueNode.type !== "nbt:int") { + ctx.err.report(localize("nbt.checker.block-states.unexpected-value-type"), valueNode, ErrorSeverity.Warning); + continue; + } + if (Object.keys(states).includes(keyNode.value)) { + const stateValues = states[keyNode.value]; + if (!stateValues.includes(valueNode.value.toString())) { + ctx.err.report(localize("expected-got", stateValues, localeQuote(valueNode.value.toString())), valueNode, ErrorSeverity.Warning); + } + } else { + ctx.err.report(localize("nbt.checker.block-states.unknown-state", localeQuote(keyNode.value), blocks), keyNode, ErrorSeverity.Warning); + } + } + }; +} +function path3(registry, id) { + return (node, ctx) => { + const typeDef = { + kind: "dispatcher", + registry, + parallelIndices: getIndices(id) + }; + const leaf = { type: "leaf", range: Range.create(node.range.end) }; + let link = { path: node, node: leaf }; + for (let i = node.children.length - 1; i >= 0; i -= 1) { + link = { path: node, node: node.children[i], next: link }; + } + let prev = link; + while (prev.next) { + prev.next.prev = prev; + prev = prev.next; + } + runtime_exports.checker.typeDefinition([{ originalNode: link, inferredType: inferPath(link) }], typeDef, runtime_exports.checker.McdocCheckerContext.create(ctx, { + allowMissingKeys: true, + requireCanonical: true, + tryConvertTo: (node2, target) => { + if (NbtPathIndexNode.is(node2.node)) { + switch (target.kind) { + case "list": + return { kind: "list", item: { kind: "any" } }; + case "byte_array": + case "int_array": + case "long_array": + return { kind: target.kind }; + case "tuple": + return { kind: "tuple", items: [] }; + } + } + return void 0; + }, + getChildren: (link2) => { + while (link2.next && link2.node.type !== "leaf" && NbtPathFilterNode.is(link2.node)) { + link2 = link2.next; + } + if (!link2.next || link2.node.type === "leaf") { + return []; + } + if (NbtPathIndexNode.is(link2.node)) { + return [[{ originalNode: link2.next, inferredType: inferPath(link2.next) }]]; + } + if (NbtPathKeyNode.is(link2.node)) { + return [{ + key: { + originalNode: link2, + inferredType: { + kind: "literal", + value: { kind: "string", value: link2.node.children[0].value } + } + }, + possibleValues: [{ + originalNode: link2.next, + inferredType: inferPath(link2.next) + }] + }]; + } + return []; + }, + reportError: (error4) => { + if (error4.kind === "invalid_collection_length") { + return; + } + runtime_exports.checker.getDefaultErrorReporter(ctx, ({ originalNode: link2 }) => link2.node.range)(error4); + }, + attachTypeInfo: (link2, definition, desc = "") => { + if (definition.kind === "literal" && !definition.attributes?.length) { + return; + } + if (link2.node.type === "leaf") { + link2.path.endTypeDef = definition; + } else { + link2.node.typeDef = definition; + } + if (NbtPathKeyNode.is(link2.prev?.node)) { + link2.prev.node.hover = `\`\`\`typescript +${link2.prev.node.children[0].value}: ${McdocType.toString(definition)} +\`\`\` +${desc}`; + } + }, + nodeAttacher: (link2, attacher) => { + if (link2.node.type !== "leaf") { + attacher(link2.node); + } + }, + stringAttacher: (link2, attacher) => { + if (!NbtPathKeyNode.is(link2.node)) { + return; + } + attacher(link2.node.children[0]); + if (link2.node.children[0].children) { + AstNode.setParents(link2.node.children[0]); + builtin_exports.fallbackSync(link2.node.children[0], ctx); + builtin_exports2.fallbackSync(link2.node.children[0], ctx); + } + } + })); + }; +} +function inferPath(link) { + if (link.node.type === "leaf") { + return { kind: "unsafe" }; + } + if (NbtPathIndexNode.is(link.node)) { + return { kind: "list", item: { kind: "any" } }; + } + return { kind: "struct", fields: [] }; +} + +// node_modules/@spyglassmc/nbt/lib/colorizer/index.js +function register6(meta) { + meta.registerColorizer("nbt:string", builtin_exports4.string); + meta.registerColorizer("nbt:byte", builtin_exports4.number); + meta.registerColorizer("nbt:short", builtin_exports4.number); + meta.registerColorizer("nbt:int", builtin_exports4.number); + meta.registerColorizer("nbt:long", builtin_exports4.number); + meta.registerColorizer("nbt:float", builtin_exports4.number); + meta.registerColorizer("nbt:double", builtin_exports4.number); +} + +// node_modules/@spyglassmc/nbt/lib/completer/index.js +var collection = (node, ctx) => { + const index4 = binarySearch(node.children, ctx.offset, (n, o) => { + return Range.compareOffset(n.range, o, true); + }); + const item = index4 >= 0 ? node.children[index4] : void 0; + if (item?.value) { + return ctx.meta.getCompleter(item.value.type)(item.value, ctx); + } + if (node.typeDef?.kind === "list") { + const completions = getValues3(node.typeDef.item, ctx.offset, { + ...ctx, + requireCanonical: node.requireCanonical + }); + if (ctx.offset < (node.children[node.children.length - 1]?.range.start ?? 0)) { + return completions.map((c) => ({ ...c, insertText: c.insertText + "," })); + } + return completions; + } + return []; +}; +var compound = builtin_exports5.record({ + key: (record3, pair, ctx, range3, iv, ipe, exitingKeys) => { + if (!record3.typeDef) { + return []; + } + const keySet = new Set(exitingKeys.map((n) => n.value)); + return runtime_exports.completer.getFields(record3.typeDef, { ...ctx, requireCanonical: record3.requireCanonical }).filter(({ key: key2 }) => !keySet.has(key2)).map(({ key: key2, field }) => CompletionItem.create(key2, pair?.key ?? range3, { + kind: 5, + detail: McdocType.toString(field.type), + documentation: field.desc, + deprecated: field.deprecated, + sortText: field.optional ? "$b" : "$a", + // sort above hardcoded $schema + filterText: formatKey(key2, pair?.key?.quote), + insertText: `${formatKey(key2, pair?.key?.quote)}${iv ? ":" : ""}${ipe ? "$1," : ""}` + })); + }, + value: (record3, pair, ctx, range3) => { + if (pair.value) { + return ctx.meta.getCompleter(pair.value.type)(pair.value, ctx); + } + if (pair.key && record3.typeDef) { + const pairKey = pair.key.value; + const field = runtime_exports.completer.getFields(record3.typeDef, ctx).find(({ key: key2 }) => key2 === pairKey)?.field.type; + if (field) { + return getValues3(field, range3, { + ...ctx, + requireCanonical: record3.requireCanonical + }); + } + } + return []; + } +}); +var primitive2 = (node, ctx) => { + const insideRange = Range.contains(node, ctx.offset, true); + if (node.type === "nbt:string" && node.children?.length && insideRange) { + const childItems = builtin_exports5.string(node, ctx); + if (childItems.length > 0) { + return childItems; + } + } + if (!node.typeDef) { + return []; + } + return getValues3(node.typeDef, insideRange ? node : ctx.offset, { + ...ctx, + requireCanonical: node.requireCanonical + }); +}; +var path4 = (node, ctx) => { + const index4 = binarySearch(node.children, ctx.offset, (n, o) => { + return Range.compareOffset(n.range, o, true); + }); + const item = index4 >= 0 ? node.children[index4] : void 0; + if (item) { + return ctx.meta.getCompleter(item.type)(item, ctx); + } + if (!node.endTypeDef) { + return []; + } + return getPathKeys(node.endTypeDef, ctx.offset, void 0, ctx); +}; +var pathKey = (node, ctx) => { + if (!node.typeDef) { + return []; + } + const child = node.children[0]; + if (child.children?.length) { + return builtin_exports5.dispatch(child.children[0], ctx); + } + return getPathKeys(node.typeDef, node, child.quote, ctx); +}; +function getPathKeys(typeDef, range3, quote2, ctx) { + return runtime_exports.completer.getFields(typeDef, { ...ctx, requireCanonical: true }).map(({ key: key2, field }) => CompletionItem.create(key2, range3, { + kind: 5, + detail: McdocType.toString(field.type), + documentation: field.desc, + deprecated: field.deprecated, + sortText: field.optional ? "$b" : "$a", + // sort above hardcoded $schema + filterText: formatKey(key2, quote2), + insertText: formatKey(key2, quote2) + })); +} +function getValues3(typeDef, range3, ctx) { + return runtime_exports.completer.getValues(typeDef, ctx).map(({ value, labelSuffix, detail, documentation, kind, completionKind, insertText, sortText }) => CompletionItem.create(value, range3, { + kind: completionKind ?? 12, + labelSuffix, + detail, + documentation, + filterText: formatValue(value, kind), + insertText: formatValue(insertText ?? value, kind), + sortText + })); +} +function formatKey(key2, quote2) { + if (!quote2 && BrigadierUnquotablePattern.test(key2)) { + return key2; + } + const q = quote2 ?? '"'; + return q + builtin_exports5.escapeString(key2, q) + q; +} +function formatValue(value, kind) { + switch (kind) { + case "string": + return `"${builtin_exports5.escapeString(value, '"')}"`; + case "byte": + return `${value}b`; + case "short": + return `${value}s`; + case "long": + return `${value}L`; + case "float": + return `${value}f`; + default: + return value; + } +} +function register7(meta) { + meta.registerCompleter("nbt:byte", primitive2); + meta.registerCompleter("nbt:byte_array", collection); + meta.registerCompleter("nbt:compound", compound); + meta.registerCompleter("nbt:double", primitive2); + meta.registerCompleter("nbt:int", primitive2); + meta.registerCompleter("nbt:int_array", collection); + meta.registerCompleter("nbt:list", collection); + meta.registerCompleter("nbt:long", primitive2); + meta.registerCompleter("nbt:long_array", collection); + meta.registerCompleter("nbt:string", primitive2); + meta.registerCompleter("nbt:short", primitive2); + meta.registerCompleter("nbt:float", primitive2); + meta.registerCompleter("nbt:path", path4); + meta.registerCompleter("nbt:path/key", pathKey); +} + +// node_modules/@spyglassmc/nbt/lib/util.js +function localizeTag(type2) { + return localize(`nbt.node.${type2.replace(/^nbt:/, "")}`); +} +function newSyntax(ctx) { + const release = ctx.project["loadedVersion"]; + if (!release) { + return true; + } + const [majorA, minorA, patchA = 0] = release.split("."); + const [majorB, minorB, patchB = 0] = "1.21.5".split("."); + if (majorA !== majorB) { + return Number(majorA) >= Number(majorB); + } + if (minorA !== minorB) { + return Number(minorA) >= Number(minorB); + } + return Number(patchA) >= Number(patchB); +} + +// node_modules/@spyglassmc/nbt/lib/parser/primitive.js +var FloatMaximum = (2 - 2 ** -23) * 2 ** 127; +var NumeralPatterns = [ + { + pattern: /^[-+]?(?:0|[1-9][0-9]*)b$/i, + type: "nbt:byte", + hasSuffix: true, + group: 2, + min: -128, + max: 127 + }, + { + pattern: /^[-+]?(?:0|[1-9][0-9]*)s$/i, + type: "nbt:short", + hasSuffix: true, + group: 2, + min: -32768, + max: 32767 + }, + { + pattern: /^[-+]?(?:0|[1-9][0-9]*)$/, + type: "nbt:int", + hasSuffix: false, + group: 2, + min: -2147483648, + max: 2147483647 + }, + { + pattern: /^[-+]?(?:0|[1-9][0-9]*)l$/i, + type: "nbt:long", + hasSuffix: true, + group: 3, + min: -9223372036854775808n, + max: 9223372036854775807n + }, + { + pattern: /^[-+]?(?:[0-9]+\.?|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?f$/i, + type: "nbt:float", + hasSuffix: true, + group: 1, + min: -FloatMaximum, + max: FloatMaximum + }, + { + pattern: /^[-+]?(?:[0-9]+\.|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?$/i, + type: "nbt:double", + hasSuffix: false, + group: 1, + min: -Number.MAX_VALUE, + max: Number.MAX_VALUE + }, + { + pattern: /^[-+]?(?:[0-9]+\.?|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?d$/i, + type: "nbt:double", + hasSuffix: true, + group: 1, + min: -Number.MAX_VALUE, + max: Number.MAX_VALUE + }, + { + pattern: /^true$/i, + type: "nbt:byte", + value: 1, + group: 0 + /* Group.Boolean */ + }, + { + pattern: /^false$/i, + type: "nbt:byte", + value: 0, + group: 0 + /* Group.Boolean */ + } +]; +var NbtStringOptions = { + escapable: { characters: ["b", "f", "n", "r", "s", "t"], unicode: true }, + quotes: ['"', "'"], + unquotable: BrigadierUnquotableOption +}; +var string10 = (src, ctx) => { + const options2 = newSyntax(ctx) ? NbtStringOptions : BrigadierStringOptions; + return setType("nbt:string", string4(options2))(src, ctx); +}; +var primitive3 = (src, ctx) => { + if (Source.isBrigadierQuote(src.peek())) { + return string10(src, ctx); + } + const { result: unquotedResult, updateSrcAndCtx: updateUnquoted } = attempt3(string10, src, ctx); + for (const e of NumeralPatterns) { + if (e.pattern.test(unquotedResult.value)) { + if (e.group === 0) { + const ans = { + type: "nbt:byte", + range: unquotedResult.range, + value: e.value + }; + updateUnquoted(); + return ans; + } + let isOutOfRange = false; + const onOutOfRange = () => isOutOfRange = true; + const numeralParser = e.group === 2 ? integer2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }) : e.group === 3 ? long2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }) : float2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }); + const { result: numeralResult, updateSrcAndCtx: updateNumeral } = attempt3(numeralParser, src, ctx); + if (isOutOfRange) { + ctx.err.report(localize("nbt.parser.number.out-of-range", localizeTag(e.type), localize("nbt.node.string"), e.min, e.max), unquotedResult, ErrorSeverity.Warning); + break; + } + updateNumeral(); + if (e.hasSuffix) { + src.skip(); + numeralResult.range.end++; + } + return { ...numeralResult, type: e.type }; + } + } + updateUnquoted(); + return unquotedResult; +}; + +// node_modules/@spyglassmc/nbt/lib/parser/collection.js +var list3 = (src, ctx) => { + const parser = list({ + start: "[", + value: entry2, + sep: ",", + trailingSep: true, + end: "]" + }); + const ans = parser(src, ctx); + ans.type = "nbt:list"; + ans.valueType = ans.children[0]?.value?.type; + if (ans.valueType && !newSyntax(ctx)) { + for (const { value } of ans.children) { + if (value && value.type !== ans.valueType) { + ctx.err.report(localize("expected-got", localizeTag(ans.valueType), localizeTag(value.type)), value); + } + } + } + return ans; +}; +var byteArray = (src, ctx) => { + const parser = list({ + start: "[B;", + value: primitive3, + sep: ",", + trailingSep: true, + end: "]" + }); + const ans = parser(src, ctx); + ans.type = "nbt:byte_array"; + for (const { value } of ans.children) { + if (value && value.type !== "nbt:byte") { + ctx.err.report(localize("expected-got", localize("nbt.node.byte"), localizeTag(value.type)), value); + } + } + return ans; +}; +var intArray = (src, ctx) => { + const parser = list({ + start: "[I;", + value: primitive3, + sep: ",", + trailingSep: true, + end: "]" + }); + const ans = parser(src, ctx); + ans.type = "nbt:int_array"; + for (const { value } of ans.children) { + if (value && value.type !== "nbt:int") { + ctx.err.report(localize("expected-got", localize("nbt.node.int"), localizeTag(value.type)), value); + } + } + return ans; +}; +var longArray = (src, ctx) => { + const parser = list({ + start: "[L;", + value: primitive3, + sep: ",", + trailingSep: true, + end: "]" + }); + const ans = parser(src, ctx); + ans.type = "nbt:long_array"; + for (const { value } of ans.children) { + if (value && value.type !== "nbt:long") { + ctx.err.report(localize("expected-got", localize("nbt.node.long"), localizeTag(value.type)), value); + } + } + return ans; +}; + +// node_modules/@spyglassmc/nbt/lib/parser/compound.js +var compound2 = (src, ctx) => { + return setType("nbt:compound", record2({ + start: "{", + pair: { + key: failOnEmpty(setType("nbt:string", string4({ ...BrigadierStringOptions, colorTokenType: "property" }))), + sep: ":", + value: entry2, + end: ",", + trailingEnd: true + }, + end: "}" + }))(src, ctx); +}; + +// node_modules/@spyglassmc/nbt/lib/parser/entry.js +var entry2 = (src, ctx) => failOnEmpty(select([ + { predicate: (src2) => src2.tryPeek("[B;"), parser: byteArray }, + { + predicate: (src2) => src2.tryPeek("[I;"), + parser: intArray + }, + { predicate: (src2) => src2.tryPeek("[L;"), parser: longArray }, + { predicate: (src2) => src2.tryPeek("["), parser: list3 }, + { predicate: (src2) => src2.tryPeek("{"), parser: compound2 }, + { parser: primitive3 } +]))(src, ctx); + +// node_modules/@spyglassmc/nbt/lib/parser/path.js +var path5 = (src, ctx) => { + const ans = { type: "nbt:path", children: [], range: Range.create(src) }; + let expectedParts = ["filter", "key"]; + let currentPart = nextPart(src); + let cursor; + while (cursor !== src.cursor) { + if (!expectedParts.includes(currentPart)) { + ctx.err.report(localize("expected-got", arrayToMessage(expectedParts.map(localizePart), false, "or"), localizePart(currentPart)), src); + } + if (currentPart === "end") { + break; + } + cursor = src.cursor; + expectedParts = PartParsers[currentPart](ans.children, src, ctx); + currentPart = nextPart(src); + } + ans.range.end = src.cursor; + return ans; +}; +var filter = (children, src, ctx) => { + const node = compound2(src, ctx); + children.push({ + type: "nbt:path/filter", + range: node.range, + children: [node] + }); + return src.trySkip(".") ? ["key"] : ["end"]; +}; +var index3 = (children, src, ctx) => { + const node = { + type: "nbt:path/index", + children: void 0, + range: Range.create(src) + }; + if (!src.trySkip("[")) { + throw new Error(`NBT path index parser called at illegal position: \u201C${src.peek()}\u201D at ${src.cursor}`); + } + const c = src.peek(); + if (c === "{") { + node.children = [compound2(src, ctx)]; + } else if (c !== "]") { + node.children = [integer2({ pattern: /^-?\d+$/ })(src, ctx)]; + } + if (!src.trySkip("]")) { + ctx.err.report(localize("expected-got", localeQuote("]"), localeQuote(src.peek())), src); + } + node.range.end = src.cursor; + children.push(node); + return src.trySkip(".") ? ["index", "key"] : ["end", "index"]; +}; +var key = (children, src, ctx) => { + const node = setType("nbt:string", string4({ + colorTokenType: "property", + escapable: {}, + // Single quotes supported since 1.20 Pre-release 2 (roughly pack format 15) + // https://bugs.mojang.com/browse/MC-175504 + quotes: ['"', "'"], + unquotable: { blockList: /* @__PURE__ */ new Set(["\n", "\r", " ", " ", '"', "[", "]", ".", "{", "}"]) } + }))(src, ctx); + children.push({ + type: "nbt:path/key", + range: node.range, + children: [node] + }); + return src.trySkip(".") ? ["index", "key"] : ["end", "filter", "index"]; +}; +function nextPart(src) { + switch (src.peek()) { + case "": + case " ": + case "\n": + case "\r": + return "end"; + case "{": + return "filter"; + case "[": + return "index"; + default: + return "key"; + } +} +function localizePart(part) { + return localize(`nbt.node.path.${part}`); +} +var PartParsers = { filter, index: index3, key }; + +// node_modules/@spyglassmc/nbt/lib/mcdocAttributes.js +var nbtValidator = (value) => { + if (!value || value?.kind === "tree") { + return Failure; + } + return value; +}; +function registerMcdocAttributes(meta) { + runtime_exports.registerAttribute(meta, "nbt", nbtValidator, { + stringParser: (config) => makeInfallible(map(entry2, (res) => ({ + type: "nbt:typed", + range: res.range, + children: [res], + targetType: config + })), localize("nbt.node")) + }); + runtime_exports.registerAttribute(meta, "nbt_path", nbtValidator, { + stringParser: () => makeInfallible(path5, localize("nbt.path")) + }); +} +function makeInfallible(parser, message2) { + return (src, ctx) => { + const start = src.cursor; + const res = parser(src, ctx); + if (res === Failure) { + ctx.err.report(localize("expected", message2), Range.create(start, src.skipRemaining())); + return void 0; + } + return res; + }; +} + +// node_modules/@spyglassmc/nbt/lib/parser/index.js +var parser_exports3 = {}; +__export(parser_exports3, { + byteArray: () => byteArray, + compound: () => compound2, + entry: () => entry2, + intArray: () => intArray, + list: () => list3, + longArray: () => longArray, + path: () => path5, + primitive: () => primitive3, + string: () => string10 +}); + +// node_modules/@spyglassmc/nbt/lib/index.js +var initialize2 = ({ meta }) => { + meta.registerLanguage("snbt", { + extensions: [".snbt"], + parser: entry2 + }); + meta.registerLanguage("nbt", { + extensions: [".nbt"] + }); + meta.registerParser("nbt:entry", entry2); + meta.registerParser("nbt:compound", compound2); + meta.registerParser("nbt:path", path5); + register5(meta); + register6(meta); + register7(meta); + registerMcdocAttributes(meta); +}; + +// node_modules/@spyglassmc/java-edition/lib/dependency/common.js +var ReleaseVersion; +(function(ReleaseVersion2) { + function cmp(a, b) { + const [majorA, minorA, patchA = 0] = a.split("."); + const [majorB, minorB, patchB = 0] = b.split("."); + if (majorA !== majorB) { + return Math.sign(Number(majorA) - Number(majorB)); + } + if (minorA !== minorB) { + return Math.sign(Number(minorA) - Number(minorB)); + } + return Math.sign(Number(patchA) - Number(patchB)); + } + ReleaseVersion2.cmp = cmp; + function isBetween(version, since, until) { + return cmp(version, since) >= 0 && cmp(version, until) < 0; + } + ReleaseVersion2.isBetween = isBetween; +})(ReleaseVersion || (ReleaseVersion = {})); +var PackMcmeta; +(function(PackMcmeta2) { + function readPackFormat(data) { + const max2 = data?.pack?.max_format; + if (Array.isArray(max2) && max2.length >= 1 && typeof max2[0] === "number") { + return max2[0]; + } + if (typeof max2 === "number") { + return max2; + } + const supported = data?.pack?.supported_formats; + if (Array.isArray(supported) && supported.length === 2 && typeof supported[1] === "number") { + return supported[1]; + } + if (typeof supported === "object" && typeof supported?.max_inclusive === "number") { + return supported.max_inclusive; + } + const format = data?.pack?.pack_format; + if (typeof format === "number") { + return format; + } + throw new Error("No pack format found"); + } + PackMcmeta2.readPackFormat = readPackFormat; + async function getType(packRoot, externals) { + const dir = await externals.fs.readdir(packRoot); + const isResourcePack = dir.some((e) => e.isDirectory() && e.name === "assets") && !dir.some((e) => e.isDirectory() && e.name === "data"); + return isResourcePack ? "assets" : "data"; + } + PackMcmeta2.getType = getType; +})(PackMcmeta || (PackMcmeta = {})); + +// node_modules/@spyglassmc/java-edition/lib/dependency/mcmeta.js +var DevelopmentVersionPattern = /^(\d\d\.\d(?:\.\d?\d)?)\-\w+\-\d+$/; +function toVersionInfo(version, release) { + return { + id: version.id, + name: version.name, + release: release ?? version.id, + data_pack_version: version.data_pack_version, + resource_pack_version: version.resource_pack_version + }; +} +function getLatestSnapshot(versions) { + for (const version of versions) { + if (version.type === "release") { + return toVersionInfo(version); + } + const matches = version.id.match(DevelopmentVersionPattern); + if (matches) { + return toVersionInfo(version, matches[1]); + } + } + throw new Error("no next release version found"); +} +function resolveConfiguredVersion(inputVersion, versions, packs, logger) { + function getReleaseVersion(version) { + if (version.type === "release") { + return version.id; + } + const matches = version.id.match(DevelopmentVersionPattern); + if (matches) { + return matches[1]; + } + const index4 = versions.findIndex((v) => v.id === version.id); + for (let i = index4; i >= 0; i -= 1) { + if (versions[i].type === "release") { + return versions[i].id; + } + } + return void 0; + } + if (versions.length === 0) { + throw new Error("mcmeta version list is empty"); + } + if (inputVersion === void 0) { + logger.warn('[resolveConfiguredVersion] Input version was undefined! Falling back to "auto"'); + inputVersion = "auto"; + } + inputVersion = inputVersion.toLowerCase(); + versions = versions.sort((a, b) => b.data_version - a.data_version); + const latestReleaseMcmeta = versions.find((v) => v.type === "release"); + if (latestReleaseMcmeta === void 0) { + throw new Error("mcmeta version list does not contain any releases"); + } + const latestRelease = toVersionInfo(latestReleaseMcmeta); + const latestSnaphot = getLatestSnapshot(versions); + if (inputVersion === "auto") { + if (packs.length === 0) { + logger.info(`[resolveConfiguredVersion] No pack format detected, selecting latest release ${latestRelease?.id}`); + return latestRelease; + } + packs.sort((a, b) => b.format - a.format); + const maxData = packs.filter((p) => p.type === "data")[0]; + const maxAssets = packs.filter((p) => p.type === "assets")[0]; + let nextReleaseVersionInfo = latestSnaphot; + const releases = versions.filter((v) => v.type === "release"); + for (const version of releases) { + if (maxData && maxData.format > version.data_pack_version) { + logger.info(`[resolveConfiguredVersion] Detected data pack format ${maxData.format} in ${maxData.packRoot}, selecting version ${nextReleaseVersionInfo.id}`); + return nextReleaseVersionInfo; + } + if (maxAssets && maxAssets.format > version.resource_pack_version) { + logger.info(`[resolveConfiguredVersion] Detected resource pack format ${maxAssets.format} in ${maxAssets.packRoot}, selecting version ${nextReleaseVersionInfo.id}`); + return nextReleaseVersionInfo; + } + if (maxData && maxData.format === version.data_pack_version) { + logger.info(`[resolveConfiguredVersion] Detected data pack format ${maxData.format} in ${maxData.packRoot}, selecting version ${version.id}`); + return toVersionInfo(version); + } + if (maxAssets && maxAssets.format === version.resource_pack_version) { + logger.info(`[resolveConfiguredVersion] Detected resource pack format ${maxAssets.format} in ${maxAssets.packRoot}, selecting version ${version.id}`); + return toVersionInfo(version); + } + nextReleaseVersionInfo = toVersionInfo(version); + } + logger.info(`[resolveConfiguredVersion] Detected pack format too low, selecting oldest supported release ${nextReleaseVersionInfo?.id}`); + return nextReleaseVersionInfo; + } else if (inputVersion === "latest release") { + logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${latestRelease.id}`); + return latestRelease; + } else if (inputVersion === "latest snapshot") { + logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${latestSnaphot.id}`); + return latestSnaphot; + } + const configVersion = versions.find((v) => inputVersion === v.id.toLowerCase() || inputVersion === v.name.toLowerCase()); + if (configVersion === void 0) { + logger.info(`[resolveConfiguredVersion] Could not find config version "${inputVersion}", selecting version ${latestSnaphot.id}`); + return latestSnaphot; + } + const configReleaseVersion = getReleaseVersion(configVersion); + if (configReleaseVersion === void 0) { + logger.info(`[resolveConfiguredVersion] Could not determine release version of config "${inputVersion}", selecting version ${latestSnaphot.id}`); + return latestSnaphot; + } + logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${configVersion?.id}`); + return toVersionInfo(configVersion, configReleaseVersion); +} +function symbolRegistrar(summary, release) { + const McmetaSummaryUri = "mcmeta://summary/registries.json"; + function addStatesSymbols(category, states, symbols) { + const capitalizedCategory = `${category[0].toUpperCase()}${category.slice(1)}`; + for (const [id, [properties, defaults]] of Object.entries(states)) { + const uri = McmetaSummaryUri; + symbols.query(uri, category, ResourceLocation.lengthen(id)).onEach(Object.entries(properties), ([state, values], blockQuery) => { + const defaultValue = defaults[state]; + blockQuery.member(`${uri}#${capitalizedCategory}_states`, state, (stateQuery) => { + stateQuery.enter({ + data: { subcategory: "state" }, + usage: { type: "declaration" } + }).onEach(values, (value) => { + stateQuery.member(value, (valueQuery) => { + valueQuery.enter({ + data: { subcategory: "state_value" }, + usage: { type: "declaration" } + }); + if (value === defaultValue) { + stateQuery.amend({ + data: { relations: { default: { category, path: valueQuery.path } } } + }); + } + }); + }); + }); + }); + } + const stateTypes = { block: summary.blocks, fluid: summary.fluids }; + for (const [type2, states2] of Object.entries(stateTypes)) { + symbols.query(McmetaSummaryUri, "mcdoc/dispatcher", `mcdoc:${type2}_states`).enter({ usage: { type: "declaration" } }).onEach(Object.entries(states2), ([id, [properties]], query) => { + const data = { + typeDef: { + kind: "struct", + fields: Object.entries(properties).map(([propKey, propValues]) => ({ + kind: "pair", + key: propKey, + optional: true, + type: { + kind: "union", + members: propValues.map((value) => ({ + kind: "literal", + value: { kind: "string", value } + })) + } + })) + } + }; + query.member(id, (stateQuery) => { + stateQuery.enter({ + data: { data }, + usage: { type: "declaration" } + }); + }); + }); + symbols.query(McmetaSummaryUri, "mcdoc/dispatcher", `mcdoc:${type2}_state_keys`).enter({ usage: { type: "declaration" } }).onEach(Object.entries(states2), ([id, [properties]], query) => { + const data = { + typeDef: { + kind: "union", + members: Object.keys(properties).map((propKey) => ({ + kind: "literal", + value: { kind: "string", value: propKey } + })) + } + }; + query.member(id, (stateQuery) => { + stateQuery.enter({ + data: { data }, + usage: { type: "declaration" } + }); + }); + }); + } + } + function addRegistriesSymbols(registries, symbols) { + function isCategory(str) { + return FileCategories.includes(str) || RegistryCategories.includes(str); + } + for (const [registryId, registry] of Object.entries(registries)) { + if (isCategory(registryId)) { + for (const entryId of registry) { + symbols.query(McmetaSummaryUri, registryId, ResourceLocation.lengthen(entryId)).enter({ usage: { type: "declaration" } }); + } + } + } + } + function addBuiltinSymbols(symbols) { + if (ReleaseVersion.cmp(release, "1.21.2") < 0) { + symbols.query(McmetaSummaryUri, "loot_table", "minecraft:empty").enter({ usage: { type: "declaration" } }); + } + symbols.query(McmetaSummaryUri, "model", "minecraft:builtin/generated").enter({ usage: { type: "declaration" } }); + if (ReleaseVersion.cmp(release, "1.21.4") < 0) { + symbols.query(McmetaSummaryUri, "model", "minecraft:builtin/entity").enter({ usage: { type: "declaration" } }); + } + } + return (symbols) => { + addRegistriesSymbols(summary.registries, symbols); + addStatesSymbols("block", summary.blocks, symbols); + addStatesSymbols("fluid", summary.fluids, symbols); + addBuiltinSymbols(symbols); + }; +} +var Fluids = { + flowing_lava: [{ falling: ["false", "true"], level: ["1", "2", "3", "4", "5", "6", "7", "8"] }, { + falling: "false", + level: "1" + }], + flowing_water: [ + { falling: ["false", "true"], level: ["1", "2", "3", "4", "5", "6", "7", "8"] }, + { falling: "false", level: "1" } + ], + lava: [{ falling: ["false", "true"] }, { falling: "false" }], + water: [{ falling: ["false", "true"] }, { falling: "false" }] +}; + +// node_modules/@spyglassmc/java-edition/lib/dependency/index.js +async function getVersions(externals, logger) { + return (await fetchWithCache(externals, logger, "https://api.spyglassmc.com/mcje/versions")).json(); +} +async function getMcmetaSummary(externals, logger, version, overridePaths = {}) { + async function handleOverride(currentValue, overrideConfig) { + if (overrideConfig) { + try { + const override = await fileUtil.readJson(externals, overrideConfig.path); + if (overrideConfig.replace) { + return override; + } else { + return merge(currentValue, override); + } + } catch (e) { + logger.error(`[je] [mcmeta-overrides] Failed loading customized mcmeta summary file \u201C${overrideConfig.path}\u201D`, e); + } + } + return currentValue; + } + const getResource = async (type2, overrideConfig) => { + const response = await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/${type2}`); + return { + data: await handleOverride(await response.json(), overrideConfig), + checksum: response.headers.get("etag") ?? "" + }; + }; + const [blocks, commands, fluids, registries] = [ + await getResource("block_states", overridePaths.blocks), + await getResource("commands", overridePaths.commands), + { + data: await handleOverride(Fluids, overridePaths.fluids), + checksum: "v1" + }, + await getResource("registries", overridePaths.registries) + ]; + return { + blocks: blocks.data, + commands: commands.data, + fluids: fluids.data, + registries: registries.data, + checksum: `${blocks.checksum}-${commands.checksum}-${fluids.checksum}-${registries.checksum}` + }; +} +async function getVanillaDatapack(externals, logger, version) { + return { + type: "tarball-ram", + name: "vanilla-datapack", + data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/vanilla-data/tarball`)).arrayBuffer()), + stripLevel: 0 + }; +} +async function getVanillaResourcepack(externals, logger, version) { + return { + type: "tarball-ram", + name: "vanilla-assets-tiny", + data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/vanilla-assets-tiny/tarball`)).arrayBuffer()), + stripLevel: 0 + }; +} +async function getVanillaMcdoc(externals, logger) { + return { + type: "tarball-ram", + name: "vanilla-mcdoc", + data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/vanilla-mcdoc/tarball`)).arrayBuffer()), + stripLevel: 0 + }; +} + +// node_modules/@spyglassmc/java-edition/lib/binder/index.js +var Resources = /* @__PURE__ */ new Map(); +function resource(path6, resource2 = {}) { + const previous = Resources.get(path6) ?? []; + Resources.set(path6, [ + ...previous, + { + path: path6, + category: resource2.category ?? path6, + ext: resource2.ext ?? ".json", + pack: resource2.pack ?? "data", + ...resource2 + } + ]); +} +resource("advancements", { category: "advancement", until: "1.21" }); +resource("functions", { category: "function", until: "1.21", ext: ".mcfunction" }); +resource("item_modifiers", { category: "item_modifier", since: "1.17", until: "1.21" }); +resource("loot_tables", { category: "loot_table", until: "1.21" }); +resource("predicates", { category: "predicate", until: "1.21" }); +resource("recipes", { category: "recipe", until: "1.21" }); +resource("structures", { category: "structure", until: "1.21", ext: ".nbt" }); +resource("tags/blocks", { category: "tag/block", until: "1.21" }); +resource("tags/entity_types", { category: "tag/entity_type", until: "1.21" }); +resource("tags/fluids", { category: "tag/fluid", until: "1.21" }); +resource("tags/functions", { category: "tag/function", until: "1.21" }); +resource("tags/game_events", { category: "tag/game_event", since: "1.17", until: "1.21" }); +resource("tags/items", { category: "tag/item", until: "1.21" }); +resource("advancement", { since: "1.21" }); +resource("function", { since: "1.21", ext: ".mcfunction" }); +resource("item_modifier", { since: "1.21" }); +resource("loot_table", { since: "1.21" }); +resource("predicate", { since: "1.21" }); +resource("recipe", { since: "1.21" }); +resource("structure", { since: "1.21", ext: ".nbt" }); +resource("tags/block", { category: "tag/block", since: "1.21" }); +resource("tags/entity_type", { category: "tag/entity_type", since: "1.21" }); +resource("tags/fluid", { category: "tag/fluid", since: "1.21" }); +resource("tags/function", { category: "tag/function", since: "1.21" }); +resource("tags/game_event", { category: "tag/game_event", since: "1.21" }); +resource("tags/item", { category: "tag/item", since: "1.21" }); +resource("banner_pattern", { since: "1.20.5" }); +resource("cat_variant", { since: "1.21.5" }); +resource("chat_type", { since: "1.19" }); +resource("chicken_variant", { since: "1.21.5" }); +resource("cow_variant", { since: "1.21.5" }); +resource("damage_type", { since: "1.19.4" }); +resource("dialog", { since: "1.21.6" }); +resource("enchantment", { since: "1.21" }); +resource("enchantment_provider", { since: "1.21" }); +resource("frog_variant", { since: "1.21.5" }); +resource("instrument", { since: "1.21.2" }); +resource("jukebox_song", { since: "1.21" }); +resource("painting_variant", { since: "1.21" }); +resource("pig_variant", { since: "1.21.5" }); +resource("sulfur_cube_archetype", { since: "26.2" }); +resource("test_instance", { since: "1.21.5" }); +resource("test_environment", { since: "1.21.5" }); +resource("timeline", { since: "1.21.11" }); +resource("trade_set", { since: "26.1" }); +resource("trial_spawner", { since: "1.21.2" }); +resource("trim_pattern", { since: "1.19.4" }); +resource("trim_material", { since: "1.19.4" }); +resource("villager_trade", { since: "26.1" }); +resource("wolf_sound_variant", { since: "1.21.5" }); +resource("wolf_variant", { since: "1.20.5" }); +resource("world_clock", { since: "26.1" }); +resource("zombie_nautilus_variant", { since: "1.21.11" }); +resource("dimension", { since: "1.16" }); +resource("dimension_type", { since: "1.16" }); +resource("worldgen/biome", { since: "1.16.2" }); +resource("worldgen/configured_carver", { since: "1.16.2" }); +resource("worldgen/configured_feature", { since: "1.16.2" }); +resource("worldgen/configured_structure_feature", { since: "1.16.2", until: "1.19" }); +resource("worldgen/density_function", { since: "1.18.2" }); +resource("worldgen/flat_level_generator_preset", { since: "1.19" }); +resource("worldgen/multi_noise_biome_source_parameter_list", { since: "1.19.4" }); +resource("worldgen/noise", { since: "1.18" }); +resource("worldgen/noise_settings", { since: "1.16.2" }); +resource("worldgen/placed_feature", { since: "1.18" }); +resource("worldgen/processor_list", { since: "1.16.2" }); +resource("worldgen/configured_surface_builder", { since: "1.16.2", until: "1.18" }); +resource("worldgen/structure", { since: "1.19" }); +resource("worldgen/structure_set", { since: "1.18.2" }); +resource("worldgen/template_pool", { since: "1.16.2" }); +resource("worldgen/world_preset", { since: "1.19" }); +var NonTaggableRegistries = /* @__PURE__ */ new Set([ + // Legacy plural paths + "block", + "fluid", + "function", + "game_event", + "item", + // Removed before 1.18 + "worldgen/block_placer_type", + "worldgen/surface_builder" +]); +for (const registry of TaggableResourceLocationCategories) { + if (NonTaggableRegistries.has(registry)) { + continue; + } + resource(`tags/${registry}`, { category: `tag/${registry}`, since: "1.18" }); +} +resource("atlases", { pack: "assets", category: "atlas", since: "1.19.3" }); +resource("blockstates", { pack: "assets", category: "block_definition" }); +resource("equipment", { pack: "assets", since: "1.21.4" }); +resource("font", { pack: "assets", since: "1.16" }); +resource("font", { pack: "assets", category: "font/ttf", since: "1.16", ext: ".ttf" }); +resource("font", { pack: "assets", category: "font/otf", since: "1.16", ext: ".otf" }); +resource("font", { pack: "assets", category: "font/unihex", since: "1.20", ext: ".zip" }); +resource("items", { pack: "assets", category: "item_definition", since: "1.21.4" }); +resource("lang", { pack: "assets" }); +resource("models", { pack: "assets", category: "model" }); +resource("models/equipment", { + pack: "assets", + category: "equipment", + since: "1.21.2", + until: "1.21.4" +}); +resource("particles", { pack: "assets", category: "particle" }); +resource("post_effect", { pack: "assets", since: "1.21.2" }); +resource("shaders/post", { pack: "assets", category: "post_effect", until: "1.21.2" }); +resource("shaders", { pack: "assets", category: "shader" }); +resource("shaders", { pack: "assets", category: "shader/fragment", ext: ".fsh" }); +resource("shaders", { pack: "assets", category: "shader/vertex", ext: ".vsh" }); +resource("sounds", { pack: "assets", category: "sound", ext: ".ogg" }); +resource("textures", { pack: "assets", category: "texture", ext: ".png" }); +resource("textures", { pack: "assets", category: "texture_meta", ext: ".png.mcmeta" }); +resource("waypoint_style", { pack: "assets", since: "1.21.6" }); +resource("lang", { pack: "assets", category: "lang/deprecated", identifier: "deprecated" }); +resource("", { pack: "assets", category: "sounds", identifier: "sounds" }); +resource("", { + pack: "assets", + category: "regional_compliancies", + identifier: "regional_compliancies" +}); +resource("", { pack: "assets", category: "gpu_warnlist", identifier: "gpu_warnlist" }); +function* getResources() { + for (const resources of Resources.values()) { + yield* resources; + } + return void 0; +} +function* getRels(uri, rootUris) { + yield* fileUtil.getRels(uri, rootUris); + const parts = uri.split("/"); + for (let i = parts.length - 2; i >= 0; i--) { + if (parts[i] === "data" || parts[i] === "assets") { + yield parts.slice(i).join("/"); + } + } + return void 0; +} +function* getRoots(uri, rootUris) { + yield* fileUtil.getRoots(uri, rootUris); + const parts = uri.split("/"); + for (let i = parts.length - 2; i >= 0; i--) { + if (parts[i] === "data" || parts[i] === "assets") { + yield `${parts.slice(0, i).join("/")}/`; + } + } + return void 0; +} +function getCandidateResourcesForRel(rel) { + const parts = rel.split("/"); + if (parts.length < 3) { + return []; + } + const [pack, namespace, ...rest] = parts; + if (pack !== "data" && pack !== "assets") { + return []; + } + const candidateResources = []; + if (rest.length === 1) { + const resources = Resources.get(""); + for (const res of resources ?? []) { + if (res.pack !== pack) { + continue; + } + let identifier4 = rest[0]; + if (!identifier4.endsWith(res.ext)) { + continue; + } + identifier4 = identifier4.slice(0, -res.ext.length); + if (res.identifier && identifier4 !== res.identifier) { + continue; + } + candidateResources.push({ ...res, namespace, identifier: identifier4 }); + } + } + for (let i = 1; i < rest.length; i += 1) { + const resources = Resources.get(rest.slice(0, i).join("/")); + for (const res of resources ?? []) { + if (res.pack !== pack) { + continue; + } + let identifier4 = rest.slice(i).join("/"); + if (!identifier4.endsWith(res.ext)) { + continue; + } + identifier4 = identifier4.slice(0, -res.ext.length); + if (res.identifier && identifier4 !== res.identifier) { + continue; + } + candidateResources.push({ ...res, namespace, identifier: identifier4 }); + } + } + return candidateResources; +} +function dissectUri(uri, ctx) { + const rels = getRels(uri, ctx.roots); + const release = ctx.project["loadedVersion"]; + if (!release) { + return void 0; + } + for (const rel of rels) { + const candidateResources = getCandidateResourcesForRel(rel); + if (candidateResources.length === 0) { + continue; + } + let res = candidateResources.findLast((res2) => matchVersion(release, res2.since, res2.until)); + if (res !== void 0) { + return { ok: true, ...res, expected: void 0 }; + } + res = candidateResources[candidateResources.length - 1]; + let expected = void 0; + for (const [path6, others] of Resources) { + for (const other of others) { + if (other.category !== res.category) { + continue; + } + if (matchVersion(release, other.since, other.until)) { + expected = path6; + break; + } + } + } + return { ok: false, ...res, expected }; + } + return void 0; +} +var uriBinder2 = (uris, ctx) => { + for (const uri of uris) { + const parts = dissectUri(uri, ctx); + if (parts) { + ctx.symbols.query(uri, parts.category, `${parts.namespace}:${parts.identifier}`).enter({ + usage: { type: "definition" } + }); + } + } +}; +function registerCustomResources(config) { + for (const [path6, res] of Object.entries(config.env.customResources)) { + resource(path6, { ...res, category: res.category }); + } +} +function matchVersion(target, since, until) { + if (since && ReleaseVersion.cmp(target, since) < 0) { + return false; + } + if (until && ReleaseVersion.cmp(until, target) <= 0) { + return false; + } + return true; +} +function reportDissectError(realPath, expectedPath, ctx) { + const release = ctx.project["loadedVersion"]; + if (!release) { + return; + } + if (expectedPath) { + ctx.err.report(localize("java-edition.binder.wrong-folder", localeQuote(realPath), release, localeQuote(expectedPath)), Range.Beginning, ErrorSeverity.Hint); + } else { + ctx.err.report(localize("java-edition.binder.wrong-version", localeQuote(realPath), release), Range.Beginning, ErrorSeverity.Hint); + } +} +function uriBuilder(resources) { + return (identifier4, ctx) => { + const root = getRoots(ctx.doc.uri, ctx.roots).next().value; + if (!root) { + return void 0; + } + const release = ctx.project["loadedVersion"]; + if (!release) { + return void 0; + } + const resource2 = resources.find((r) => matchVersion(release, r.since, r.until)); + if (!resource2) { + return void 0; + } + const sepIndex = identifier4.indexOf(":"); + const namespace = sepIndex > 0 ? identifier4.slice(0, sepIndex) : "minecraft"; + const path6 = identifier4.slice(sepIndex + 1); + return `${root}${resource2.pack}/${namespace}/${resource2.path}/${path6}${resource2.ext}`; + }; +} +function registerUriBuilders(meta) { + const resourcesByCategory = /* @__PURE__ */ new Map(); + for (const resource2 of getResources()) { + resourcesByCategory.set(resource2.category, [ + ...resourcesByCategory.get(resource2.category) ?? [], + resource2 + ]); + } + for (const [category, resources] of resourcesByCategory.entries()) { + meta.registerUriBuilder(category, uriBuilder(resources)); + } +} +var jeFileUriPredicate = (uri, ctx) => { + const rels = [...getRels(uri, ctx.roots)]; + return rels.some((rel) => getCandidateResourcesForRel(rel).length > 0); +}; + +// node_modules/@spyglassmc/java-edition/lib/json/binder/index.js +function bindDeprecated(node, ctx) { + const renamed = node.children.find((p) => p.key?.value === "renamed")?.value; + if (JsonObjectNode.is(renamed)) { + for (const pair of renamed.children) { + if (JsonStringNode.is(pair.value)) { + const range3 = Range.translate(pair.value.range, 1, -1); + ctx.symbols.query(ctx.doc, "translation_key", pair.value.value).enter({ + usage: { type: "definition", range: range3, fullRange: pair } + }); + } + } + } +} +function bindLanguage(node, ctx) { + const isEnglish = ctx.doc.uri.endsWith("/en_us.json"); + for (const pair of node.children) { + if (pair.key) { + const desc = JsonStringNode.is(pair.value) ? pair.value.value : void 0; + const range3 = Range.translate(pair.key.range, 1, -1); + ctx.symbols.query(ctx.doc, "translation_key", pair.key.value).enter({ + data: { desc: isEnglish ? desc : void 0 }, + usage: { type: "definition", range: range3, fullRange: pair } + }); + } + } +} +var file7 = (node, ctx) => { + if (ctx.doc.uri.match(/\/lang\/[a-z_]+.json$/)) { + const child = node.children[0]; + if (JsonObjectNode.is(child)) { + if (ctx.doc.uri.endsWith("/deprecated.json")) { + bindDeprecated(child, ctx); + } else { + bindLanguage(child, ctx); + } + } + } +}; +function register8(meta) { + meta.registerBinder("json:file", file7); +} + +// node_modules/@spyglassmc/java-edition/lib/json/checker/index.js +function createTagDefinition(registry) { + const id = { + kind: "tree", + values: { + registry: { kind: "literal", value: { kind: "string", value: registry } }, + tags: { kind: "literal", value: { kind: "string", value: "allowed" } } + } + }; + return { + kind: "concrete", + child: { kind: "reference", path: "::java::data::tag::Tag" }, + typeArgs: [{ kind: "string", attributes: [{ name: "id", value: id }] }] + }; +} +var file8 = (node, ctx) => { + const child = node.children[0]; + if (ctx.doc.uri.endsWith("/pack.mcmeta")) { + const type2 = { kind: "reference", path: "::java::pack::Pack" }; + return checker_exports3.index(type2)(child, ctx); + } + const parts = dissectUri(ctx.doc.uri, ctx); + if (parts?.ok) { + if (parts.category.startsWith("tag/")) { + const type3 = createTagDefinition(parts.category.slice(4)); + return checker_exports3.index(type3)(child, ctx); + } + const type2 = { + kind: "dispatcher", + registry: "minecraft:resource", + parallelIndices: [{ kind: "static", value: parts.category }] + }; + return checker_exports3.index(type2, { discardDuplicateKeyErrors: true })(child, ctx); + } else if (parts?.ok === false) { + reportDissectError(parts.path, parts.expected, ctx); + } +}; +function register9(meta) { + meta.registerChecker("json:file", file8); +} + +// node_modules/@spyglassmc/java-edition/lib/json/completer/index.js +var textureSlot = (node, ctx) => { + const slot = node.slot ?? SymbolNode.mock(node, { + category: "texture_slot", + usageType: node.kind === "definition" ? "definition" : "reference" + }); + const slotItems = builtin_exports5.symbol(slot, ctx); + if (node.kind === "definition") { + return slotItems; + } + if (node.kind === "reference") { + return slotItems.map((item) => ({ + ...item, + range: node.range, + label: "#" + item.label, + insertText: "#" + (item.insertText ?? item.label) + })); + } + const id = node.id ?? ResourceLocationNode.mock(node, { category: "texture" }); + return builtin_exports5.resourceLocation(id, ctx); +}; +function register10(meta) { + meta.registerCompleter("java_edition:texture_slot", textureSlot); +} + +// node_modules/@spyglassmc/java-edition/lib/json/parser/index.js +function textureSlotParser(kind) { + return (src, ctx) => { + const start = src.cursor; + const ans = { + type: "java_edition:texture_slot", + range: Range.create(start), + kind, + children: [] + }; + if (kind === "definition") { + const slot = symbol5({ category: "texture_slot", usageType: "definition" })(src, ctx); + ans.children.push(slot); + ans.slot = slot; + } else if (src.tryPeek("#")) { + ans.children.push(literal("#")(src, ctx)); + const slot = symbol5({ category: "texture_slot", usageType: "reference" })(src, ctx); + ans.children.push(slot); + ans.slot = slot; + } else if (kind === "reference") { + ctx.err.report(localize("expected", localeQuote("#")), src); + } else { + const id = resourceLocation6({ category: "texture", usageType: "reference" })(src, ctx); + ans.children.push(id); + ans.id = id; + } + ans.range = Range.create(start, src); + return ans; + }; +} +var translationValueParser = (src, ctx) => { + const start = src.cursor; + const ans = { + type: "java_edition:translation_value", + range: Range.create(start), + children: [], + value: "" + }; + while (src.canRead()) { + src.skipUntilOrEnd("%"); + const argStart = src.cursor; + if (src.trySkip("%")) { + if (src.trySkip("%")) { + const token2 = src.sliceToCursor(argStart); + ans.children.push({ + type: "literal", + range: Range.create(argStart, src), + options: { pool: [token2], colorTokenType: "escape" }, + value: token2 + }); + continue; + } + let hasInteger = false; + while (src.canRead() && Source.isDigit(src.peek())) { + src.skip(); + hasInteger = true; + } + if (hasInteger && !src.trySkip("$")) { + ctx.err.report(localize("java-edition.translation-value.percent-escape-hint", localize("expected", localeQuote("$"))), src); + } + if (!src.trySkip("s")) { + ctx.err.report(localize("java-edition.translation-value.percent-escape-hint", localize("expected", localeQuote("s"))), src); + } + const token = src.sliceToCursor(argStart); + ans.children.push({ + type: "literal", + range: Range.create(argStart, src), + options: { pool: [token] }, + value: token + }); + } + } + ans.value = src.sliceToCursor(start); + ans.range = Range.create(start, src); + return ans; +}; + +// node_modules/@spyglassmc/java-edition/lib/json/mcdocAttributes.js +var validator = runtime_exports.attribute.validator; +var criterionValidator = validator.alternatives(validator.tree({ + definition: validator.boolean +}), () => ({ definition: false })); +var textureSlotValidator = validator.alternatives(validator.tree({ + kind: validator.options("definition", "value", "reference") +}), () => ({ kind: "value" })); +var translationKeyValidator = validator.alternatives(validator.tree({ + definition: validator.boolean +}), () => ({ definition: false })); +function registerMcdocAttributes2(meta) { + runtime_exports.registerAttribute(meta, "criterion", criterionValidator, { + stringParser: (config, _, ctx) => { + const parts = dissectUri(ctx.doc.uri, ctx); + if (!parts || !parts.ok || parts.category !== "advancement") { + return void 0; + } + return symbol5({ + category: "advancement", + subcategory: "criterion", + parentPath: [`${parts.namespace}:${parts.identifier}`], + usageType: config.definition ? "definition" : "reference" + }); + }, + stringMocker: (config, _, ctx) => { + const parts = dissectUri(ctx.doc.uri, ctx); + if (!parts || !parts.ok || parts.category !== "advancement") { + return void 0; + } + return SymbolNode.mock(ctx.offset, { + category: "advancement", + subcategory: "criterion", + parentPath: [`${parts.namespace}:${parts.identifier}`] + }); + } + }); + runtime_exports.registerAttribute(meta, "texture_slot", textureSlotValidator, { + stringParser: (config, _, ctx) => { + return textureSlotParser(config.kind); + }, + stringMocker: (config, _, ctx) => { + return { + type: "java_edition:texture_slot", + range: Range.create(ctx.offset), + kind: config.kind, + children: [] + }; + } + }); + runtime_exports.registerAttribute(meta, "translation_key", translationKeyValidator, { + stringParser: (config, _, ctx) => { + return symbol5({ + category: "translation_key", + usageType: config.definition ? "definition" : "reference" + }); + }, + stringMocker: (config, _, ctx) => { + return SymbolNode.mock(ctx.offset, { + category: "translation_key", + usageType: config.definition ? "definition" : "reference" + }); + } + }); + runtime_exports.registerAttribute(meta, "translation_value", () => void 0, { + stringParser: () => translationValueParser + }); +} + +// node_modules/@spyglassmc/java-edition/lib/json/index.js +var initialize3 = (ctx) => { + registerMcdocAttributes2(ctx.meta); + register8(ctx.meta); + register9(ctx.meta); + register10(ctx.meta); +}; + +// node_modules/@spyglassmc/java-edition/lib/mcdocAttributes.js +var validator2 = runtime_exports.attribute.validator; +var gameRuleValidator = validator2.tree({ + type: validator2.options("boolean", "int") +}); +function registerMcdocAttributes3(meta, commands, release) { + runtime_exports.registerAttribute(meta, "since", validator2.string, { + filterElement: (config, ctx) => { + return ReleaseVersion.cmp(release, config) >= 0; + } + }); + runtime_exports.registerAttribute(meta, "until", validator2.string, { + filterElement: (config, ctx) => { + return ReleaseVersion.cmp(release, config) < 0; + } + }); + runtime_exports.registerAttribute(meta, "deprecated", validator2.optional(validator2.string), { + mapField: (config, field, ctx) => { + if (!config || ReleaseVersion.cmp(release, config) >= 0) { + return { ...field, deprecated: true }; + } + return field; + } + }); + const gameRuleNode = commands.children.gamerule?.children; + if (gameRuleNode) { + const [boolGameRules, intGameRules] = ["brigadier:bool", "brigadier:integer"].map((type2) => Object.entries(gameRuleNode).flatMap(([key2, node]) => node.children?.value?.type === "argument" && node.children.value.parser === type2 ? [key2] : [])); + runtime_exports.registerAttribute(meta, "game_rule", gameRuleValidator, { + stringParser: (config, _, ctx) => { + return literal({ + pool: config.type === "boolean" ? boolGameRules : intGameRules, + colorTokenType: "string" + }); + }, + stringMocker: (config, _, ctx) => { + return LiteralNode.mock(ctx.offset, { + pool: config.type === "boolean" ? boolGameRules : intGameRules + }); + } + }); + } +} +function registerPackFormatAttribute(meta, versions, packs) { + const dataFormats = /* @__PURE__ */ new Map(); + const assetsFormats = /* @__PURE__ */ new Map(); + const latestSnapshot = getLatestSnapshot(versions); + if (latestSnapshot.release !== latestSnapshot.id) { + dataFormats.set(latestSnapshot.data_pack_version, [latestSnapshot.release]); + assetsFormats.set(latestSnapshot.resource_pack_version, [latestSnapshot.release]); + } + for (const version of versions) { + if (version.type === "release") { + dataFormats.set(version.data_pack_version, [ + ...dataFormats.get(version.data_pack_version) ?? [], + version.id + ]); + assetsFormats.set(version.resource_pack_version, [ + ...assetsFormats.get(version.resource_pack_version) ?? [], + version.id + ]); + } + } + function getFormats(packMcmetaUri) { + const thisPack = packs.find((p) => fileUtil.isSubUriOf(packMcmetaUri, p.packRoot)); + return thisPack?.type === "assets" ? assetsFormats : dataFormats; + } + runtime_exports.registerAttribute(meta, "pack_format", () => void 0, { + numericCompleter: (_, ctx) => { + return [...getFormats(ctx.doc.uri).entries()].map(([k, v], i) => ({ + range: Range.create(ctx.offset), + label: `${k}`, + labelSuffix: ` (${v[0]})`, + sortText: `${i}`.padStart(4, "0") + })); + } + }); +} + +// node_modules/@spyglassmc/mcfunction/lib/colorizer/macro.js +var macro = (node, ctx) => { + const tokens = []; + for (const child of node.children) { + if (child.type === "mcfunction:macro/prefix") { + tokens.push(ColorToken.create(child.range, "literal")); + } else if (child.type === "mcfunction:macro/other") { + tokens.push(ColorToken.create(child.range, "string")); + } else { + const { start, end } = child.range; + tokens.push(ColorToken.create(Range.create(start, start + 2), "literal")); + tokens.push(ColorToken.create(Range.create(start + 2, end - 1), "property")); + tokens.push(ColorToken.create(Range.create(end - 1, end), "literal")); + } + } + return tokens; +}; + +// node_modules/@spyglassmc/mcfunction/lib/colorizer/index.js +function register11(meta) { + meta.registerColorizer("mcfunction:command_child/literal", builtin_exports4.literal); + meta.registerColorizer("mcfunction:command_child/trailing", builtin_exports4.error); + meta.registerColorizer("mcfunction:macro", macro); +} + +// node_modules/@spyglassmc/mcfunction/lib/completer/index.js +var completer_exports5 = {}; +__export(completer_exports5, { + command: () => command, + entry: () => entry3 +}); + +// node_modules/@spyglassmc/mcfunction/lib/node/command.js +var CommandNode; +(function(CommandNode2) { + function is(node) { + return node?.type === "mcfunction:command"; + } + CommandNode2.is = is; + function mock(range3, options2 = {}) { + return { type: "mcfunction:command", range: Range.get(range3), children: [], options: options2 }; + } + CommandNode2.mock = mock; +})(CommandNode || (CommandNode = {})); +var CommandChildNode; +(function(CommandChildNode2) { + function is(node) { + return node.type === "mcfunction:command_child"; + } + CommandChildNode2.is = is; +})(CommandChildNode || (CommandChildNode = {})); +var LiteralCommandChildNode; +(function(LiteralCommandChildNode2) { + function is(node) { + return node?.type === "mcfunction:command_child/literal"; + } + LiteralCommandChildNode2.is = is; +})(LiteralCommandChildNode || (LiteralCommandChildNode = {})); + +// node_modules/@spyglassmc/mcfunction/lib/node/entry.js +var McfunctionNode; +(function(McfunctionNode2) { + function is(node) { + return node?.type === "mcfunction:entry"; + } + McfunctionNode2.is = is; +})(McfunctionNode || (McfunctionNode = {})); + +// node_modules/@spyglassmc/mcfunction/lib/node/macro.js +var MacroNode; +(function(MacroNode2) { + function is(obj) { + return obj?.type === "mcfunction:macro"; + } + MacroNode2.is = is; + function mock(range3) { + return { type: "mcfunction:macro", range: Range.get(range3), children: [] }; + } + MacroNode2.mock = mock; +})(MacroNode || (MacroNode = {})); + +// node_modules/@spyglassmc/mcfunction/lib/tree/util.js +function redirect(rootTreeNode, path6) { + return path6.reduce((p, c) => p?.children?.[c], rootTreeNode); +} +function resolveParentTreeNode(parentTreeNode, rootTreeNode, parentPath) { + if (parentTreeNode?.redirect) { + return { + treeNode: redirect(rootTreeNode, parentTreeNode.redirect), + path: [...parentTreeNode.redirect] + }; + } else if (parentTreeNode && !parentTreeNode.children && !parentTreeNode.executable) { + return { treeNode: rootTreeNode, path: [] }; + } else { + return { treeNode: parentTreeNode, path: parentPath }; + } +} +function categorizeTreeChildren(children) { + const ans = { + literalTreeNodes: [], + argumentTreeNodes: [] + }; + for (const e of Object.entries(children)) { + if (e[1].type === "literal") { + ans.literalTreeNodes.push(e); + } else if (e[1].type === "argument") { + ans.argumentTreeNodes.push(e); + } + } + return ans; +} + +// node_modules/@spyglassmc/mcfunction/lib/completer/index.js +function entry3(tree2, getMockNodes2) { + return (node, ctx) => { + const childNode = AstNode.findChild(node, ctx.offset, true); + if (CommandNode.is(childNode)) { + return command(tree2, getMockNodes2)(childNode ?? CommandNode.mock(ctx.offset), ctx); + } else { + return []; + } + }; +} +function command(tree2, getMockNodes2) { + return (node, ctx) => { + const index4 = AstNode.findChildIndex(node, ctx.offset, true); + const selectedChildNode = node.children[index4]?.children[0]; + if (selectedChildNode) { + return builtin_exports5.dispatch(selectedChildNode, ctx); + } + const lastChildNode = AstNode.findLastChild(node, ctx.offset); + if (!lastChildNode) { + return Object.keys(tree2.children ?? {}).map((v) => CompletionItem.create(v, ctx.offset, { + kind: 14 + /* core.CompletionKind.Keyword */ + })); + } + const treePath = lastChildNode.path; + const { treeNode: parentTreeNode } = resolveParentTreeNode(redirect(tree2, treePath), tree2); + if (!parentTreeNode?.children) { + return []; + } + const { literalTreeNodes, argumentTreeNodes } = categorizeTreeChildren(parentTreeNode.children); + const lastIndex = node.children.indexOf(lastChildNode); + const prevNodes = node.children.slice(0, lastIndex + 1); + return [ + ...literalTreeNodes.map(([name]) => CompletionItem.create(name, ctx.offset, { + kind: 14 + /* core.CompletionKind.Keyword */ + })), + ...argumentTreeNodes.flatMap(([_name, treeNode]) => Arrayable.toArray(getMockNodes2(treeNode, prevNodes, ctx)).flatMap((n) => builtin_exports5.dispatch(n, ctx))) + ]; + }; +} + +// node_modules/@spyglassmc/mcfunction/lib/parser/argument.js +function argumentTreeNodeToString(name, treeNode) { + const parserName = treeNode.parser.slice(treeNode.parser.indexOf(":") + 1); + return `<${name}: ${parserName}>`; +} + +// node_modules/@spyglassmc/mcfunction/lib/parser/common.js +var sep = (src, ctx) => { + const start = src.cursor; + const ans = src.readSpace(); + if (ans !== " ") { + ctx.err.report(localize("expected", localize("mcfunction.parser.sep", localeQuote(" "))), Range.create(start, src)); + } + return ans; +}; + +// node_modules/@spyglassmc/mcfunction/lib/parser/literal.js +function literal8(names, isRoot = false) { + const options2 = { + pool: names, + colorTokenType: isRoot ? "keyword" : "literal" + }; + return (src, ctx) => { + const start = src.cursor; + const value = src.readUntil(" ", "\r", "\n"); + if (!value.length) { + return Failure; + } + const ans = { + type: "mcfunction:command_child/literal", + range: Range.create(start, src), + options: options2, + value + }; + if (!names.includes(value)) { + ctx.err.report(localize("expected", names), ans); + } + return ans; + }; +} + +// node_modules/@spyglassmc/mcfunction/lib/parser/command.js +function command2(tree2, argument2, options2 = {}) { + return (src, ctx) => { + const ans = { + type: "mcfunction:command", + range: Range.create(src), + children: [], + options: options2 + }; + const start = src.cursor; + const innerStart = src.innerCursor; + if (src.trySkip("/")) { + ans.slash = Range.create(start, src.cursor); + if (!options2.slash) { + ctx.err.report(localize("mcfunction.parser.leading-slash.unexpected"), ans.slash, ErrorSeverity.Error, { + codeAction: { + title: localize("code-action.remove-leading-slash"), + isPreferred: true, + changes: [ + { + type: "edit", + range: ans.slash, + text: "" + } + ] + } + }); + } + } else if (options2.slash === "required") { + ctx.err.report(localize("expected", localize("mcfunction.parser.leading-slash")), Range.create(start, start + 1), ErrorSeverity.Error, { + codeAction: { + title: localize("code-action.add-leading-slash"), + isPreferred: true, + changes: [ + { + type: "edit", + range: Range.create(start), + text: "/" + } + ] + } + }); + } + dispatch2(ans.children, src, ctx, [], tree2, tree2, argument2); + if (src.canReadInLine()) { + const node = trailing(src, ctx); + ans.children.push({ + type: "mcfunction:command_child", + range: node.range, + children: [node], + path: [] + }); + } + ans.range.end = src.cursor; + if (options2.maxLength) { + const commandLength = src.innerCursor - innerStart; + if (commandLength > options2.maxLength) { + ctx.err.report(localize("mcfunction.parser.command-too-long", commandLength, options2.maxLength), ans); + } + } + return ans; + }; +} +function dispatch2(ans, src, ctx, path6, rootTreeNode, parentTreeNode, argument2) { + function _dispatch(path7, parentTreeNode2) { + const { treeNode: parent, path: resolvedPath } = resolveParentTreeNode(parentTreeNode2, rootTreeNode, path7); + path7 = resolvedPath; + const children = parent?.children; + if (!children) { + return false; + } + const { literalTreeNodes, argumentTreeNodes } = categorizeTreeChildren(children); + const argumentParsers = argumentTreeNodes.map(([name, treeNode]) => ({ name, parser: argument2(treeNode, ans) ?? unknown(treeNode) })); + const literalParser = literalTreeNodes.length ? literal8(literalTreeNodes.map(([name, _treeNode]) => name), parent.type === "root") : void 0; + const parsers = [ + ...literalParser ? [literalParser] : [], + ...argumentParsers.map((v) => v.parser) + ]; + const out = { index: 0 }; + if (parsers.length === 0) { + return false; + } + const parser = parsers.length > 1 ? any3(parsers, out) : parsers[0]; + const result2 = parser(src, ctx); + if (result2 !== Failure) { + const takenName = argumentParsers[out.index - (literalParser ? 1 : 0)]?.name ?? result2.value; + const childPath = [...path7, takenName]; + ans.push({ + type: "mcfunction:command_child", + range: result2.range, + children: [result2], + path: childPath + }); + const childTreeNode = children[takenName]; + if (!childTreeNode) { + return false; + } + const requiredPermissionLevel = childTreeNode.permission ?? 2; + if (ctx.config.env.permissionLevel < requiredPermissionLevel) { + ctx.err.report(localize("mcfunction.parser.no-permission", requiredPermissionLevel, ctx.config.env.permissionLevel), result2); + } + if (result2.type === "mcfunction:command_child/unknown") { + return false; + } + if (src.canReadInLine()) { + sep(src, ctx); + return { childPath, childTreeNode }; + } else { + if (!childTreeNode.executable) { + ctx.err.report(localize("mcfunction.parser.eoc-unexpected"), src); + } + } + } else { + ctx.err.report(localize("expected", treeNodeChildrenToString(children)), Range.create(src)); + } + return false; + } + let result = _dispatch(path6, parentTreeNode); + while (result) { + result = _dispatch(result.childPath, result.childTreeNode); + } +} +function unknown(treeNode) { + return (src, ctx) => { + const start = src.cursor; + const value = src.readUntilLineEnd(); + const range3 = Range.create(start, src); + ctx.err.report(localize("mcfunction.parser.unknown-parser", localeQuote(treeNode.parser)), range3, ErrorSeverity.Hint); + return { type: "mcfunction:command_child/unknown", range: range3, value }; + }; +} +var trailing = (src, ctx) => { + const start = src.cursor; + const value = src.readUntilLineEnd(); + const range3 = Range.create(start, src); + ctx.err.report(localize("mcfunction.parser.trailing", localeQuote(value)), range3); + return { type: "mcfunction:command_child/trailing", range: range3, value }; +}; +function wrapWithBrackets(syntax2, executable) { + return executable ? `[${syntax2}]` : syntax2; +} +function treeNodeChildrenToStringArray(children, executable = false) { + const entries = Object.entries(children).map(([name, treeNode]) => wrapWithBrackets(treeNodeToString(name, treeNode), executable)); + return entries; +} +function treeNodeChildrenToString(children) { + const entries = treeNodeChildrenToStringArray(children); + return entries.length > 5 ? `${entries.slice(0, 3).join("|")}|...|${entries.slice(-2).join("|")}` : entries.join("|"); +} +function treeNodeToString(name, treeNode) { + if (treeNode.type === "argument") { + return argumentTreeNodeToString(name, treeNode); + } else { + return name; + } +} + +// node_modules/@spyglassmc/mcfunction/lib/parser/macro.js +function macro2(hasPrefix = true) { + return (src, ctx) => { + const ans = { + type: "mcfunction:macro", + range: Range.create(src.cursor), + children: [] + }; + let start = src.cursor; + let hasMacroArgs = false; + if (hasPrefix) { + if (src.trySkip("$")) { + ans.children.push({ + type: "mcfunction:macro/prefix", + range: Range.create(start, src) + }); + start = src.cursor; + } else { + ctx.err.report(localize("expected", localeQuote("$")), ans); + } + } + while (src.canReadInLine()) { + src.skipUntilOrEnd(LF, CR, "$"); + if (src.peek(2) === "$(") { + hasMacroArgs = true; + const other = src.sliceToCursor(start); + if (other.length > 0) { + ans.children.push({ + type: "mcfunction:macro/other", + range: Range.create(start, src), + value: other + }); + start = src.cursor; + } + const key2 = validateMacroArgument(src, ctx, start); + ans.children.push({ + type: "mcfunction:macro/argument", + range: Range.create(start, src.cursor), + value: key2 + }); + start = src.cursor; + } else { + if (src.peek() === "$") { + src.skip(); + } + if (!src.canReadInLine()) { + ans.children.push({ + type: "mcfunction:macro/other", + range: Range.create(start, src), + value: src.sliceToCursor(start) + }); + } + } + } + if (!hasMacroArgs) { + ctx.err.report(localize("expected", localize("mcfunction.parser.macro.at-least-one")), Range.create(start, src)); + } + ans.range.end = src.cursor; + return ans; + }; +} +function validateMacroArgument(src, ctx, start) { + src.skip(2); + const keyStart = src.cursor; + src.skipUntilOrEnd(LF, CR, ")"); + if (src.peek() !== ")") { + ctx.err.report(localize("expected", localeQuote(")")), Range.create(keyStart, src.cursor)); + } else if (src.cursor <= keyStart) { + ctx.err.report(localize("expected", localize("mcfunction.parser.macro.key")), Range.create(start, src.cursor + 1)); + } + const key2 = src.sliceToCursor(keyStart); + const matchedInvalid = key2.replace(/[a-zA-Z0-9_]*/, ""); + if (matchedInvalid.length > 0) { + ctx.err.report(localize("mcfunction.parser.macro.illegal-key", matchedInvalid.charAt(0)), Range.create(keyStart, src.cursor)); + } + src.skip(); + return key2; +} + +// node_modules/@spyglassmc/mcfunction/lib/parser/entry.js +function mcfunction(commandTree, argument2, options2) { + return (src, ctx) => { + const ans = { + type: "mcfunction:entry", + range: Range.create(src), + children: [] + }; + while (src.skipWhitespace().canReadInLine()) { + let result; + if (src.peek() === "#") { + result = comment5(src, ctx); + } else if (src.peek() === "$") { + const start = src.cursor; + if (options2.macros) { + result = macro2()(src, ctx); + } else { + src.skipLine(); + ans.range.end = src.cursor; + result = { + type: "error", + range: Range.create(start, src) + }; + ctx.err.report(localize("mcfunction.parser.macro.disallowed"), result); + } + } else { + result = command2(commandTree, argument2, options2.commandOptions)(src, ctx); + } + ans.children.push(result); + src.nextLine(); + } + ans.range.end = src.cursor; + return ans; + }; +} +var comment5 = comment3({ singleLinePrefixes: /* @__PURE__ */ new Set(["#"]) }); +var entry4 = (commandTree, argument2, options2 = {}) => { + const parser = mcfunction(commandTree, argument2, options2); + return options2.lineContinuation ? concatOnTrailingBackslash(parser) : parser; +}; + +// node_modules/@spyglassmc/mcfunction/lib/index.js +var initialize4 = ({ meta }) => { + register11(meta); + meta.registerCompleter("mcfunction:command_child/literal", builtin_exports5.literal); +}; + +// node_modules/@spyglassmc/java-edition/lib/common/index.js +function getUris(category, id, ctx) { + return ctx.symbols.query(ctx.doc, category, ResourceLocation.lengthen(id)).symbol?.definition?.map((v) => v.uri) ?? []; +} +function getTagValues(category, id, ctx) { + const resolveValueNode = (node) => JsonStringNode.is(node) ? node.value : node.children.find((n) => n.key?.value === "id").value.value; + const set = getUris(category, id, ctx).reduce((ans, uri) => { + const result = void 0; + if (!result || result.node.parserErrors.length || result.node.checkerErrors?.length) { + return ans; + } + const rootNode = result.node.children[0]; + const replaceNode = rootNode.children.find((n) => n.key?.value === "replace")?.value; + const valuesNode = rootNode.children.find((n) => n.key?.value === "values")?.value; + const replace = replaceNode?.value; + const values = valuesNode.children.map((n) => ResourceLocation.lengthen(resolveValueNode(n.value))); + if (replace) { + ans = /* @__PURE__ */ new Set(); + } + for (const value of values) { + ans.add(value); + } + return ans; + }, /* @__PURE__ */ new Set()); + return [...set]; +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/node/argument.js +var BlockStatesNode; +(function(BlockStatesNode2) { + function is(node) { + return node.type === "mcfunction:block/states"; + } + BlockStatesNode2.is = is; +})(BlockStatesNode || (BlockStatesNode = {})); +var BlockNode; +(function(BlockNode2) { + function is(node) { + return node?.type === "mcfunction:block"; + } + BlockNode2.is = is; + function mock(range3, isPredicate) { + const id = ResourceLocationNode.mock(range3, { category: "block", allowTag: isPredicate }); + return { + type: "mcfunction:block", + range: Range.get(range3), + children: [id], + id, + isPredicate: false + }; + } + BlockNode2.mock = mock; +})(BlockNode || (BlockNode = {})); +var CoordinateNode; +(function(CoordinateNode2) { + function mock(range3) { + return { type: "mcfunction:coordinate", range: Range.get(range3), notation: "", value: 0 }; + } + CoordinateNode2.mock = mock; + function toDegree(node) { + const value = node.value % 360; + return value >= 180 ? value - 360 : value < -180 ? value + 360 : value; + } + CoordinateNode2.toDegree = toDegree; +})(CoordinateNode || (CoordinateNode = {})); +var EntitySelectorArgumentsNode; +(function(EntitySelectorArgumentsNode2) { + function is(node) { + return node.type === "mcfunction:entity_selector/arguments"; + } + EntitySelectorArgumentsNode2.is = is; +})(EntitySelectorArgumentsNode || (EntitySelectorArgumentsNode = {})); +var EntitySelectorVariables = ["a", "e", "p", "r", "s", "n"]; +var EntitySelectorVariable; +(function(EntitySelectorVariable2) { + function is(value) { + return EntitySelectorVariables.includes(value); + } + EntitySelectorVariable2.is = is; +})(EntitySelectorVariable || (EntitySelectorVariable = {})); +var EntitySelectorAtVariables = EntitySelectorVariables.map((v) => `@${v}`); +var EntitySelectorAtVariable; +(function(EntitySelectorAtVariable2) { + function is(value) { + return EntitySelectorAtVariables.includes(value); + } + EntitySelectorAtVariable2.is = is; + function filterAvailable(ctx) { + const release = ctx.project["loadedVersion"]; + return EntitySelectorAtVariables.filter((variable) => !(variable === "@n" && release && ReleaseVersion.cmp(release, "1.21") < 0)); + } + EntitySelectorAtVariable2.filterAvailable = filterAvailable; +})(EntitySelectorAtVariable || (EntitySelectorAtVariable = {})); +var EntitySelectorNode; +(function(EntitySelectorNode2) { + function is(node) { + return node?.type === "mcfunction:entity_selector"; + } + EntitySelectorNode2.is = is; + function mock(range3, options2) { + const literal9 = LiteralNode.mock(range3, options2); + return { + type: "mcfunction:entity_selector", + range: Range.get(range3), + children: [literal9], + variable: "e" + }; + } + EntitySelectorNode2.mock = mock; + EntitySelectorNode2.ArgumentKeys = /* @__PURE__ */ new Set([ + "advancements", + "distance", + "gamemode", + "level", + "limit", + "name", + "nbt", + "predicate", + "scores", + "sort", + "tag", + "team", + "type", + "x", + "y", + "z", + "dx", + "dy", + "dz", + "x_rotation", + "y_rotation" + ]); + function canKeyExist(selector3, argument2, key2) { + const hasKey = (key3) => !!argument2.children.find((p) => p.key?.value === key3); + const hasNonInvertedKey = (key3) => !!argument2.children.find((p) => p.key?.value === key3 && !p.value?.inverted); + switch (key2) { + case "advancements": + case "distance": + case "level": + case "scores": + case "x": + case "y": + case "z": + case "dx": + case "dy": + case "dz": + case "x_rotation": + case "y_rotation": + return hasKey(key2) ? 1 : 0; + case "gamemode": + case "name": + case "team": + return hasNonInvertedKey(key2) ? 1 : 0; + case "limit": + case "sort": + return selector3.currentEntity ? 2 : hasKey(key2) ? 1 : 0; + case "type": + return selector3.typeLimited ? hasKey(key2) ? 1 : 2 : 0; + } + return 0; + } + EntitySelectorNode2.canKeyExist = canKeyExist; +})(EntitySelectorNode || (EntitySelectorNode = {})); +var EntityNode; +(function(EntityNode2) { + function is(node) { + return node?.type === "mcfunction:entity"; + } + EntityNode2.is = is; +})(EntityNode || (EntityNode = {})); +var ItemStackNode; +(function(ItemStackNode2) { + function is(node) { + return node?.type === "mcfunction:item_stack"; + } + ItemStackNode2.is = is; + function mock(range3) { + const id = ResourceLocationNode.mock(range3, { category: "item" }); + return { type: "mcfunction:item_stack", range: Range.get(range3), children: [id], id }; + } + ItemStackNode2.mock = mock; +})(ItemStackNode || (ItemStackNode = {})); +var ComponentListNode; +(function(ComponentListNode2) { + function is(node) { + return node.type === "mcfunction:component_list"; + } + ComponentListNode2.is = is; +})(ComponentListNode || (ComponentListNode = {})); +var ComponentNode; +(function(ComponentNode2) { + function is(node) { + return node.type === "mcfunction:component"; + } + ComponentNode2.is = is; +})(ComponentNode || (ComponentNode = {})); +var ComponentRemovalNode; +(function(ComponentRemovalNode2) { + function is(node) { + return node.type === "mcfunction:component_removal"; + } + ComponentRemovalNode2.is = is; +})(ComponentRemovalNode || (ComponentRemovalNode = {})); +var ItemPredicateNode; +(function(ItemPredicateNode2) { + function is(node) { + return node?.type === "mcfunction:item_predicate"; + } + ItemPredicateNode2.is = is; + function mock(range3) { + const id = ResourceLocationNode.mock(range3, { category: "item", allowTag: true }); + return { type: "mcfunction:item_predicate", range: Range.get(range3), children: [id], id }; + } + ItemPredicateNode2.mock = mock; +})(ItemPredicateNode || (ItemPredicateNode = {})); +var ComponentTestsNode; +(function(ComponentTestsNode2) { + function is(node) { + return node.type === "mcfunction:component_tests"; + } + ComponentTestsNode2.is = is; +})(ComponentTestsNode || (ComponentTestsNode = {})); +var ComponentTestsAnyOfNode; +(function(ComponentTestsAnyOfNode2) { + function is(node) { + return node.type === "mcfunction:component_tests_any_of"; + } + ComponentTestsAnyOfNode2.is = is; +})(ComponentTestsAnyOfNode || (ComponentTestsAnyOfNode = {})); +var ComponentTestsAllOfNode; +(function(ComponentTestsAllOfNode2) { + function is(node) { + return node.type === "mcfunction:component_tests_all_of"; + } + ComponentTestsAllOfNode2.is = is; +})(ComponentTestsAllOfNode || (ComponentTestsAllOfNode = {})); +var ComponentTestExactNode; +(function(ComponentTestExactNode2) { + function is(node) { + return node.type === "mcfunction:component_test_exact"; + } + ComponentTestExactNode2.is = is; +})(ComponentTestExactNode || (ComponentTestExactNode = {})); +var ComponentTestExistsNode; +(function(ComponentTestExistsNode2) { + function is(node) { + return node.type === "mcfunction:component_test_exists"; + } + ComponentTestExistsNode2.is = is; +})(ComponentTestExistsNode || (ComponentTestExistsNode = {})); +var ComponentTestSubpredicateNode; +(function(ComponentTestSubpredicateNode2) { + function is(node) { + return node.type === "mcfunction:component_test_sub_predicate"; + } + ComponentTestSubpredicateNode2.is = is; +})(ComponentTestSubpredicateNode || (ComponentTestSubpredicateNode = {})); +var IntRangeNode2; +(function(IntRangeNode3) { + function mock(range3) { + return { + type: "mcfunction:int_range", + range: Range.get(range3), + children: [], + value: [void 0, void 0] + }; + } + IntRangeNode3.mock = mock; +})(IntRangeNode2 || (IntRangeNode2 = {})); +var NbtNode2; +(function(NbtNode3) { + function is(node) { + return node.type === "mcfunction:nbt"; + } + NbtNode3.is = is; +})(NbtNode2 || (NbtNode2 = {})); +var NbtPathNode2; +(function(NbtPathNode3) { + function is(node) { + return node.type === "mcfunction:nbt_path"; + } + NbtPathNode3.is = is; +})(NbtPathNode2 || (NbtPathNode2 = {})); +var NbtResourceNode; +(function(NbtResourceNode2) { + function is(node) { + return node.type === "mcfunction:nbt_resource"; + } + NbtResourceNode2.is = is; +})(NbtResourceNode || (NbtResourceNode = {})); +var ObjectiveCriteriaNode; +(function(ObjectiveCriteriaNode2) { + ObjectiveCriteriaNode2.SimpleValues = [ + "air", + "armor", + "deathCount", + "dummy", + "food", + "health", + "level", + "playerKillCount", + "totalKillCount", + "trigger", + "xp", + ...Color.ColorNames.map((n) => `killedByTeam.${n}`), + ...Color.ColorNames.map((n) => `teamkill.${n}`) + ]; + ObjectiveCriteriaNode2.ComplexCategories = /* @__PURE__ */ new Map([ + ["broken", "item"], + ["crafted", "item"], + ["custom", "custom_stat"], + ["dropped", "item"], + ["killed", "entity_type"], + ["killed_by", "entity_type"], + ["mined", "block"], + ["picked_up", "item"], + ["used", "item"] + ]); + ObjectiveCriteriaNode2.ComplexSep = ":"; + function mock(range3) { + return { type: "mcfunction:objective_criteria", range: Range.get(range3) }; + } + ObjectiveCriteriaNode2.mock = mock; +})(ObjectiveCriteriaNode || (ObjectiveCriteriaNode = {})); +var ParticleNode; +(function(ParticleNode2) { + const SpecialTypes = /* @__PURE__ */ new Set([ + "block", + "block_marker", + "dust", + "dust_color_transition", + "falling_dust", + "item", + "sculk_charge", + "shriek", + "vibration" + ]); + function isSpecialType(type2) { + return SpecialTypes.has(type2); + } + ParticleNode2.isSpecialType = isSpecialType; + const OptionTypes = /* @__PURE__ */ new Set([ + ...SpecialTypes, + "block_crumble", + "dust_pillar", + "entity_effect", + "trail" + ]); + function requiresOptions(type2, release) { + if (type2 === "flash" && ReleaseVersion.cmp(release, "1.21.9") >= 0) { + return true; + } + return OptionTypes.has(type2); + } + ParticleNode2.requiresOptions = requiresOptions; + function is(node) { + return node?.type === "mcfunction:particle"; + } + ParticleNode2.is = is; + function mock(range3) { + const id = ResourceLocationNode.mock(range3, { category: "particle_type" }); + return { type: "mcfunction:particle", range: Range.get(range3), children: [id], id }; + } + ParticleNode2.mock = mock; +})(ParticleNode || (ParticleNode = {})); +var ScoreHolderNode; +(function(ScoreHolderNode2) { + function mock(range3) { + const fakeName = SymbolNode.mock(range3, { category: "score_holder" }); + return { + type: "mcfunction:score_holder", + range: Range.get(range3), + children: [fakeName], + fakeName + }; + } + ScoreHolderNode2.mock = mock; +})(ScoreHolderNode || (ScoreHolderNode = {})); +var TimeNode; +(function(TimeNode2) { + TimeNode2.UnitToTicks = /* @__PURE__ */ new Map([["", 1], ["t", 1], ["s", 20], ["d", 24e3]]); + TimeNode2.Units = [...TimeNode2.UnitToTicks.keys()]; +})(TimeNode || (TimeNode = {})); +var VectorNode; +(function(VectorNode2) { + function mock(range3, options2) { + return { + type: "mcfunction:vector", + range: Range.get(range3), + children: [], + options: options2, + system: 0 + }; + } + VectorNode2.mock = mock; +})(VectorNode || (VectorNode = {})); + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/checker/index.js +var entry5 = (node, ctx) => { + const parts = dissectUri(ctx.doc.uri, ctx); + if (parts?.ok === false) { + reportDissectError(parts.path, parts.expected, ctx); + } + builtin_exports2.dispatchSync(node, ctx); +}; +var command3 = (node, ctx) => { + rootCommand(node.children, 0, ctx); +}; +function getEarlierNode(nodes, before, name) { + if (name === void 0) { + return void 0; + } + for (let i = before - 1; i > 0; i -= 1) { + if (nodes[i].path[nodes[i].path.length - 1] === name) { + return nodes[i].children[0]; + } + } + return void 0; +} +var rootCommand = (nodes, index4, ctx) => { + for (let i = 0; i < nodes.length; i += 1) { + const node = nodes[i].children[0]; + if (BlockNode.is(node)) { + block(node, ctx); + } else if (EntityNode.is(node)) { + entity(node, ctx); + } else if (ItemPredicateNode.is(node)) { + itemPredicate(node, ctx); + } else if (ItemStackNode.is(node)) { + itemStack(node, ctx); + } else if (ParticleNode.is(node)) { + particle(node, ctx); + } else if (NbtResourceNode.is(node)) { + nbtResource(node, ctx); + } else if (TypedJsonNode.is(node)) { + checker_exports3.typed(node, ctx); + } else if (TypedNbtNode.is(node)) { + checker_exports4.typed(node, ctx); + } else if (NbtNode2.is(node) && node.properties) { + const dispatchedBy = getEarlierNode(nodes, i, node.properties.dispatchedBy); + const indexedBy = getEarlierNode(nodes, i, node.properties.indexedBy); + nbtChecker(dispatchedBy, indexedBy)(node, ctx); + } else if (NbtPathNode2.is(node) && node.properties) { + const dispatchedBy = getEarlierNode(nodes, i, node.properties.dispatchedBy); + nbtPathChecker(dispatchedBy)(node, ctx); + } + } +}; +var block = (node, ctx) => { + if (!node.nbt) { + return; + } + const type2 = ResourceLocationNode.toString(node.id, "full"); + checker_exports4.index("minecraft:block", type2, { isPredicate: node.isPredicate })(node.nbt, ctx); +}; +var entity = (node, ctx) => { + for (const pair of node.selector?.arguments?.children ?? []) { + if (pair.key?.value !== "nbt" || !pair.value) { + continue; + } + const types = getTypesFromEntity(node, ctx); + if (!NbtCompoundNode.is(pair.value.value)) { + continue; + } + checker_exports4.index("minecraft:entity", types, { isPredicate: true })(pair.value.value, ctx); + } +}; +var itemPredicate = (node, ctx) => { + if (node.nbt) { + const type2 = ResourceLocationNode.toString(node.id, "full"); + checker_exports4.index("minecraft:item", type2, { isPredicate: true })(node.nbt, ctx); + } + if (!node.tests?.children) { + return; + } + const anyOfTest = node.tests.children[0]; + for (const allOfTest of anyOfTest.children) { + for (const test of allOfTest.children) { + const key2 = ResourceLocationNode.toString(test.key, "full"); + if (key2 === "minecraft:count" && !ComponentTestExistsNode.is(test) && test.value) { + const validInt = { kind: "int", valueRange: { kind: 0, min: 0 } }; + const type2 = { + kind: "union", + members: [ + validInt, + { + kind: "struct", + fields: [ + { kind: "pair", key: "min", optional: true, type: validInt }, + { kind: "pair", key: "max", optional: true, type: validInt } + ] + } + ] + }; + checker_exports4.typeDefinition(type2)(test.value, ctx); + } else if (ComponentTestExactNode.is(test) && test.value) { + checker_exports4.index("minecraft:data_component", key2)(test.value, ctx); + } else if (ComponentTestSubpredicateNode.is(test) && test.value) { + checker_exports4.index("minecraft:data_component_predicate", key2)(test.value, ctx); + } + } + } +}; +var itemStack = (node, ctx) => { + const itemId = ResourceLocationNode.toString(node.id, "full"); + if (node.nbt) { + checker_exports4.index("minecraft:item", itemId)(node.nbt, ctx); + } + if (!node.components) { + return; + } + const groupedComponents = /* @__PURE__ */ new Map(); + for (const child of node.components.children) { + if (!child.key) { + continue; + } + const componentId = ResourceLocationNode.toString(child.key, "full"); + if (!groupedComponents.has(componentId)) { + groupedComponents.set(componentId, []); + } + groupedComponents.get(componentId).push(child.key); + if (child.type === "mcfunction:component" && child.value) { + checker_exports4.index("minecraft:data_component", componentId)(child.value, ctx); + } + } + for (const [_, group] of groupedComponents) { + if (group.length > 1) { + for (const node2 of group) { + ctx.err.report(localize("mcfunction.parser.duplicate-components"), node2.range, ErrorSeverity.Warning); + } + } + } +}; +var nbtResource = (node, ctx) => { + const type2 = { + kind: "dispatcher", + registry: "minecraft:resource", + parallelIndices: [{ kind: "static", value: ResourceLocation.lengthen(node.category) }] + }; + checker_exports4.typeDefinition(type2)(node.children[0], ctx); +}; +function nbtChecker(dispatchedBy, indexedBy) { + return (node, ctx) => { + if (!node.properties) { + return; + } + const tag2 = node.children[0]; + if (indexedBy) { + if (NbtPathNode2.is(indexedBy)) { + const indexedByTypedef = indexedBy.children[0].endTypeDef; + const typeDef = indexedByTypedef && node.properties.isListIndex ? getListLikeChild(indexedByTypedef) : indexedByTypedef; + if (typeDef) { + checker_exports4.typeDefinition(typeDef, node.properties)(tag2, ctx); + } + } + return; + } + switch (node.properties.dispatcher) { + case "minecraft:entity": + if (NbtCompoundNode.is(tag2)) { + const types = EntityNode.is(dispatchedBy) || ResourceLocationNode.is(dispatchedBy) ? getTypesFromEntity(dispatchedBy, ctx) : void 0; + checker_exports4.index("minecraft:entity", types, { + isPredicate: node.properties.isPredicate, + isMerge: node.properties.isMerge + })(tag2, ctx); + } + break; + case "minecraft:block": + if (NbtCompoundNode.is(tag2)) { + checker_exports4.index("minecraft:block", void 0, { + isPredicate: node.properties.isPredicate, + isMerge: node.properties.isMerge + })(tag2, ctx); + } + break; + case "minecraft:storage": + if (NbtCompoundNode.is(tag2)) { + const storage = ResourceLocationNode.is(dispatchedBy) ? ResourceLocationNode.toString(dispatchedBy) : void 0; + checker_exports4.index("minecraft:storage", storage, { + isPredicate: node.properties.isPredicate, + isMerge: node.properties.isMerge + })(tag2, ctx); + } + break; + } + }; +} +function getListLikeChild(typeDef) { + switch (typeDef.kind) { + case "list": + return typeDef.item; + case "byte_array": + return { kind: "byte" }; + case "int_array": + return { kind: "int" }; + case "long_array": + return { kind: "long" }; + case "union": + const members = typeDef.members.map((m) => getListLikeChild(m)).filter((m) => m !== void 0); + if (members.length === 0) { + return void 0; + } + if (members.length === 1) { + return members[0]; + } + return { kind: "union", members }; + default: + return void 0; + } +} +function nbtPathChecker(dispatchedBy) { + return (node, ctx) => { + if (!node.properties) { + return; + } + const path6 = node.children[0]; + switch (node.properties.dispatcher) { + case "minecraft:entity": + const types = EntityNode.is(dispatchedBy) || ResourceLocationNode.is(dispatchedBy) ? getTypesFromEntity(dispatchedBy, ctx) : void 0; + checker_exports4.path("minecraft:entity", types)(path6, ctx); + break; + case "minecraft:block": + checker_exports4.path("minecraft:block", void 0)(path6, ctx); + break; + case "minecraft:storage": + const storage = ResourceLocationNode.is(dispatchedBy) ? ResourceLocationNode.toString(dispatchedBy) : void 0; + checker_exports4.path("minecraft:storage", storage)(path6, ctx); + break; + } + }; +} +var particle = (node, ctx) => { + const id = ResourceLocationNode.toString(node.id, "short"); + const release = ctx.project["loadedVersion"]; + if (!release || ReleaseVersion.cmp(release, "1.20.5") < 0) { + return; + } + const options2 = node.children?.find(NbtCompoundNode.is); + if (options2) { + checker_exports4.index("minecraft:particle", ResourceLocation.lengthen(id))(options2, ctx); + } else if (ParticleNode.requiresOptions(id, release)) { + ctx.err.report(localize("expected", localize("nbt.node.compound")), Range.create(node.id.range.end, node.id.range.end + 1)); + } +}; +function getTypesFromEntity(entity3, ctx) { + if (ResourceLocationNode.is(entity3)) { + const value = ResourceLocationNode.toString(entity3, "full", true); + if (value.startsWith(ResourceLocation.TagPrefix)) { + return getTagValues("tag/entity_type", value.slice(1), ctx); + } else { + return [value]; + } + } else if (entity3.playerName !== void 0 || entity3.selector?.playersOnly) { + return ["minecraft:player"]; + } else if (entity3.selector) { + const argumentsNode = entity3.selector.arguments; + if (!argumentsNode) { + return void 0; + } + let types = void 0; + for (const pairNode of argumentsNode.children) { + if (pairNode.key?.value !== "type") { + continue; + } + const valueNode = pairNode.value; + if (!valueNode || valueNode.inverted) { + continue; + } + const value = ResourceLocationNode.toString(valueNode.value, "full", true); + if (value.startsWith(ResourceLocation.TagPrefix)) { + const tagValues = getTagValues("tag/entity_type", value.slice(1), ctx); + if (types === void 0) { + types = tagValues.map(ResourceLocation.lengthen); + } else { + types = types.filter((t) => tagValues.includes(t)); + } + } else { + types = [value]; + } + } + return types; + } + return void 0; +} +function register12(meta) { + meta.registerChecker("mcfunction:entry", entry5); + meta.registerChecker("mcfunction:command", command3); + meta.registerChecker("mcfunction:block", block); + meta.registerChecker("mcfunction:entity", entity); + meta.registerChecker("mcfunction:item_stack", itemStack); + meta.registerChecker("mcfunction:item_predicate", itemPredicate); + meta.registerChecker("mcfunction:particle", particle); +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/colorizer/index.js +var objectiveCriterion = (node) => [ColorToken.create(node, "type")]; +var vector = (node) => { + return [ColorToken.create(node, "vector")]; +}; +function register13(meta) { + meta.registerColorizer("mcfunction:coordinate", builtin_exports4.number); + meta.registerColorizer("mcfunction:vector", vector); + meta.registerColorizer("mcfunction:objective_criteria", objectiveCriterion); +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/common/index.js +var ColorArgumentValues = [...Color.ColorNames, "reset"]; +var EntityAnchorArgumentValues = ["feet", "eyes"]; +var GamemodeArgumentValues = ["adventure", "survival", "creative", "spectator"]; +function getItemSlotArgumentValues(ctx) { + const release = ctx.project["loadedVersion"]; + const output = [ + ...[...Array(54).keys()].map((n) => `container.${n}`), + ...[...Array(27).keys()].map((n) => `enderchest.${n}`), + ...[...Array(15).keys()].map((n) => `horse.${n}`), + ...[...Array(9).keys()].map((n) => `hotbar.${n}`), + ...[...Array(27).keys()].map((n) => `inventory.${n}`), + "armor.chest", + "armor.feet", + "armor.head", + "armor.legs", + "horse.chest", + "weapon", + "weapon.mainhand", + "weapon.offhand" + ]; + if (ReleaseVersion.cmp(release, "1.20.5") >= 0) { + output.push(...[...Array(4).keys()].map((n) => `player.crafting.${n}`), "armor.body", "contents", "player.cursor"); + } else { + output.push("horse.armor"); + } + if (ReleaseVersion.cmp(release, "1.21.5") >= 0) { + output.push("saddle"); + } else { + output.push("horse.saddle"); + } + if (ReleaseVersion.cmp(release, "26.1") >= 0) { + output.push(...[...Array(8).keys()].map((n) => `mob.inventory.${n}`)); + } else { + output.push(...[...Array(8).keys()].map((n) => `villager.${n}`)); + } + return output; +} +function getItemSlotsArgumentValues(ctx) { + const release = ctx.project["loadedVersion"]; + const output = [ + ...getItemSlotArgumentValues(ctx), + "armor.*", + "container.*", + "enderchest.*", + "horse.*", + "hotbar.*", + "inventory.*", + "player.crafting.*", + "weapon.*" + ]; + if (ReleaseVersion.cmp(release, "26.1") >= 0) { + output.push("mob.inventory.*"); + } else { + output.push("villager.*"); + } + return output; +} +var OperationArgumentValues = ["=", "+=", "-=", "*=", "/=", "%=", "<", ">", "><"]; +function getScoreboardSlotArgumentValues(ctx) { + const release = ctx.project["loadedVersion"]; + return [ + ReleaseVersion.cmp(release, "1.20.2") < 0 ? "belowName" : "below_name", + "list", + "sidebar", + ...Color.ColorNames.map((n) => `sidebar.team.${n}`) + ]; +} +var SwizzleArgumentValues = [ + "x", + "xy", + "xz", + "xyz", + "xzy", + "y", + "yx", + "yz", + "yxz", + "yzx", + "z", + "zx", + "zy", + "zxy", + "zyx" +]; +var HeightmapValues = [ + "motion_blocking", + "motion_blocking_no_leaves", + "ocean_floor", + "world_surface" +]; +var RotationValues = ["none", "clockwise_90", "180", "counterclockwise_90"]; +var MirrorValues = ["none", "left_right", "front_back"]; + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/completer/argument.js +var getMockNodes = (rawTreeNode, prevNodes, ctx) => { + const range3 = ctx.offset; + const treeNode = rawTreeNode; + switch (treeNode.parser) { + case "brigadier:bool": + return BooleanNode.mock(range3); + case "brigadier:double": + case "brigadier:float": + case "brigadier:integer": + case "brigadier:long": + case "minecraft:float_range": + case "minecraft:message": + case "minecraft:time": + case "minecraft:uuid": + return []; + case "brigadier:string": + return treeNode.properties.type === "phrase" ? StringNode.mock(range3, BrigadierStringOptions) : []; + case "minecraft:angle": + return CoordinateNode.mock(range3); + case "minecraft:block_pos": + return VectorNode.mock(range3, { dimension: 3, integersOnly: true }); + case "minecraft:block_predicate": + return BlockNode.mock(range3, true); + case "minecraft:block_state": + return BlockNode.mock(range3, false); + case "minecraft:color": + return LiteralNode.mock(range3, { pool: ColorArgumentValues }); + case "minecraft:column_pos": + return VectorNode.mock(range3, { dimension: 2, integersOnly: true }); + case "minecraft:component": + return [ + JsonArrayNode.mock(range3), + JsonObjectNode.mock(range3), + JsonStringNode.mock(range3) + ]; + case "minecraft:dialog": + return ResourceLocationNode.mock(range3, { category: "dialog" }); + case "minecraft:dimension": + return ResourceLocationNode.mock(range3, { category: "dimension" }); + case "minecraft:entity": + case "minecraft:game_profile": + return EntitySelectorNode.mock(range3, { + pool: EntitySelectorAtVariable.filterAvailable(ctx) + }); + case "minecraft:heightmap": + return LiteralNode.mock(range3, { pool: HeightmapValues }); + case "minecraft:entity_anchor": + return LiteralNode.mock(range3, { pool: EntityAnchorArgumentValues }); + case "minecraft:entity_summon": + return ResourceLocationNode.mock(range3, { category: "entity_type" }); + case "minecraft:function": + return ResourceLocationNode.mock(range3, { category: "function" }); + case "minecraft:gamemode": + return LiteralNode.mock(range3, { pool: GamemodeArgumentValues }); + case "minecraft:int_range": + return IntRangeNode2.mock(range3); + case "minecraft:item_enchantment": + return ResourceLocationNode.mock(range3, { category: "enchantment" }); + case "minecraft:item_predicate": + return ItemPredicateNode.mock(range3); + case "minecraft:item_slot": + return LiteralNode.mock(range3, { pool: getItemSlotArgumentValues(ctx) }); + case "minecraft:item_slots": + return LiteralNode.mock(range3, { pool: getItemSlotsArgumentValues(ctx) }); + case "minecraft:item_stack": + return ItemStackNode.mock(range3); + case "minecraft:loot_modifier": + return ResourceLocationNode.mock(range3, { category: "item_modifier" }); + case "minecraft:loot_predicate": + return ResourceLocationNode.mock(range3, { category: "predicate" }); + case "minecraft:loot_table": + return ResourceLocationNode.mock(range3, { category: "loot_table" }); + case "minecraft:mob_effect": + return ResourceLocationNode.mock(range3, { category: "mob_effect" }); + case "minecraft:objective": + return SymbolNode.mock(range3, { category: "objective" }); + case "minecraft:objective_criteria": + return ObjectiveCriteriaNode.mock(range3); + case "minecraft:operation": + return LiteralNode.mock(range3, { + pool: OperationArgumentValues, + colorTokenType: "operator" + }); + case "minecraft:particle": + return ParticleNode.mock(range3); + case "minecraft:resource": + case "minecraft:resource_key": + case "minecraft:resource_or_tag": + case "minecraft:resource_or_tag_key": + const allowTag = treeNode.parser === "minecraft:resource_or_tag" || treeNode.parser === "minecraft:resource_or_tag_key"; + return ResourceLocationNode.mock(range3, { + category: ResourceLocation.shorten(treeNode.properties.registry), + allowTag + }); + case "minecraft:resource_location": + return ResourceLocationNode.mock(range3, treeNode.properties ?? { pool: [], allowUnknown: true }); + case "minecraft:rotation": + return VectorNode.mock(range3, { dimension: 2, noLocal: true }); + case "minecraft:scoreboard_slot": + return LiteralNode.mock(range3, { pool: getScoreboardSlotArgumentValues(ctx) }); + case "minecraft:score_holder": + return ScoreHolderNode.mock(range3); + case "minecraft:style": + return JsonObjectNode.mock(range3); + case "minecraft:swizzle": + return LiteralNode.mock(range3, { pool: SwizzleArgumentValues }); + case "minecraft:team": + return SymbolNode.mock(range3, { category: "team" }); + case "minecraft:team_color": + return LiteralNode.mock(range3, { pool: Color.ColorNames }); + case "minecraft:template_mirror": + return LiteralNode.mock(range3, { pool: MirrorValues }); + case "minecraft:template_rotation": + return LiteralNode.mock(range3, { pool: RotationValues }); + case "minecraft:vec2": + return VectorNode.mock(range3, { dimension: 2, integersOnly: true }); + case "minecraft:vec3": + return VectorNode.mock(range3, { dimension: 3 }); + case "spyglassmc:criterion": + const advancementNode = prevNodes.length > 0 ? prevNodes[prevNodes.length - 1].children[0] : void 0; + if (ResourceLocationNode.is(advancementNode)) { + return SymbolNode.mock(range3, { + category: "advancement", + subcategory: "criterion", + parentPath: [ResourceLocationNode.toString(advancementNode, "full")] + }); + } + return []; + case "spyglassmc:tag": + return SymbolNode.mock(range3, { category: "tag" }); + // ==== Unimplemented ==== + case "minecraft:nbt_compound_tag": + case "minecraft:nbt_path": + case "minecraft:nbt_tag": + default: + return []; + } +}; +var block2 = (node, ctx) => { + const ans = []; + if (Range.contains(node.id, ctx.offset, true)) { + ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); + } + if (node.states?.innerRange && Range.contains(node.states.innerRange, ctx.offset, true)) { + ans.push(...blockStates2(node.states, ctx)); + } + if (node.nbt?.innerRange && Range.contains(node.nbt.innerRange, ctx.offset, true)) { + ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); + } + return ans; +}; +var blockStates2 = (node, ctx) => { + if (!BlockNode.is(node.parent)) { + return []; + } + const idNode = node.parent.id; + const id = ResourceLocationNode.toString(idNode, "full"); + const blocks = idNode.isTag ? getTagValues("tag/block", id, ctx) : [id]; + const states = getStates("block", blocks, ctx); + return builtin_exports5.record({ + key: (_record, pair, _ctx, range3, insertValue, insertComma, existingKeys) => { + return Object.keys(states).filter((k) => pair?.key?.value === k || !existingKeys.some((ek) => ek.value === k)).map((k) => CompletionItem.create(k, range3, { + kind: 10, + detail: localize("mcfunction.completer.block.states.default-value", localeQuote(states[k][0])), + insertText: new InsertTextBuilder().literal(k).if(insertValue, (b) => b.literal("=").placeholder(...states[k])).if(insertComma, (b) => b.literal(",")).build() + })); + }, + value: (_record, pair, ctx2) => { + if (pair.key && states[pair.key.value]) { + return states[pair.key.value].map((v) => CompletionItem.create(v, pair.value ?? ctx2.offset, { + kind: 12 + /* CompletionKind.Value */ + })); + } + return []; + } + })(node, ctx); +}; +var componentList = (node, ctx) => { + if (!node.innerRange || !Range.contains(node.innerRange, ctx.offset, true)) { + return []; + } + const completeKey = (key2) => { + const id = key2 ?? ResourceLocationNode.mock(key2 ?? ctx.offset, { category: "data_component_type" }); + return builtin_exports5.resourceLocation(id, ctx); + }; + const index4 = binarySearch(node.children, ctx.offset, (n, o) => Range.compareOffset(n.range, o, true)); + const child = index4 >= 0 ? node.children[index4] : void 0; + if (!child) { + return [ + ...builtin_exports5.literal(LiteralNode.mock(ctx.offset, { pool: ["!"] }), ctx), + ...completeKey(void 0) + ]; + } + if (child.type === "mcfunction:component_removal") { + return completeKey(child.key); + } + if (child.key && Range.contains(child.key, ctx.offset, true)) { + return completeKey(child.key); + } + if (child.value && Range.contains(child.value, ctx.offset, true)) { + return builtin_exports5.dispatch(child.value, ctx); + } + return []; +}; +var componentTests = (node, ctx) => { + const test = AstNode.findShallowestChild({ + node, + needle: ctx.offset, + endInclusive: true, + predicate: (n) => ComponentTestExactNode.is(n) || ComponentTestSubpredicateNode.is(n) + }); + if (test && ComponentTestExactNode.is(test) && test.value) { + return builtin_exports5.dispatch(test.value, ctx); + } else if (test && ComponentTestSubpredicateNode.is(test) && test.value) { + return builtin_exports5.dispatch(test.value, ctx); + } + return []; +}; +var coordinate = (node, _ctx) => { + return [CompletionItem.create("~", node)]; +}; +var itemStack2 = (node, ctx) => { + const ans = []; + if (Range.contains(node.id, ctx.offset, true)) { + ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); + } + if (node.components && Range.contains(node.components, ctx.offset, true)) { + ans.push(...componentList(node.components, ctx)); + } + if (node.nbt && Range.contains(node.nbt, ctx.offset, true)) { + ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); + } + return ans; +}; +var itemPredicate2 = (node, ctx) => { + const ans = []; + if (Range.contains(node.id, ctx.offset, true)) { + ans.push(CompletionItem.create("*", node, { sortText: "##" })); + if (node.id.type === "resource_location") { + ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); + } + } + if (node.tests && Range.contains(node.tests, ctx.offset, true)) { + ans.push(...componentTests(node.tests, ctx)); + } + if (node.nbt && Range.contains(node.nbt, ctx.offset, true)) { + ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); + } + return ans; +}; +var objectiveCriteria = (node, ctx) => { + const ans = ObjectiveCriteriaNode.SimpleValues.map((v) => CompletionItem.create(v, node)); + if (!node.children?.[0] || Range.contains(node.children[0], ctx.offset, true)) { + ans.push(...builtin_exports5.resourceLocation(node.children?.[0] ?? ResourceLocationNode.mock(node, { category: "stat_type", namespacePathSep: "." }), ctx)); + } + if (node.children?.[1] && Range.contains(node.children[1], ctx.offset, true)) { + ans.push(...builtin_exports5.resourceLocation(node.children[1], ctx)); + } + return ans; +}; +var particle2 = (node, ctx) => { + const child = AstNode.findChild(node, ctx.offset, true); + if (child) { + return builtin_exports5.dispatch(child, ctx); + } + const release = ctx.project["loadedVersion"]; + if (!release || ReleaseVersion.cmp(release, "1.20.5") >= 0) { + return []; + } + const id = ResourceLocationNode.toString(node.id, "short"); + const map3 = { + block: [BlockNode.mock(ctx.offset, false)], + block_marker: [BlockNode.mock(ctx.offset, false)], + dust: [VectorNode.mock(ctx.offset, { dimension: 3 }), FloatNode.mock(ctx.offset)], + dust_color_transition: [ + VectorNode.mock(ctx.offset, { dimension: 3 }), + FloatNode.mock(ctx.offset), + VectorNode.mock(ctx.offset, { dimension: 3 }) + ], + falling_dust: [BlockNode.mock(ctx.offset, false)], + item: [ItemStackNode.mock(ctx.offset)], + sculk_charge: [FloatNode.mock(ctx.offset)], + shriek: [IntegerNode.mock(ctx.offset)], + vibration: [ + VectorNode.mock(ctx.offset, { dimension: 3 }), + VectorNode.mock(ctx.offset, { dimension: 3 }), + IntegerNode.mock(ctx.offset) + ] + }; + if (ParticleNode.isSpecialType(id)) { + const numParamsBefore = node.children?.slice(1).filter((n) => n.range.end < ctx.offset).length ?? 0; + const mock = map3[id][numParamsBefore]; + if (mock) { + return builtin_exports5.dispatch(mock, ctx); + } + } + return []; +}; +var scoreHolder = (node, ctx) => { + let ans; + if (node.selector && Range.contains(node.selector, ctx.offset, true)) { + ans = selector(node.selector, ctx); + if (Range.contains(node.children[0], ctx.offset, true)) { + ans.push(...builtin_exports5.symbol(SymbolNode.mock(node, { category: "score_holder" }), ctx)); + } + } else { + ans = builtin_exports5.symbol(node.fakeName ?? SymbolNode.mock(node, { category: "score_holder" }), ctx); + ans.push(...builtin_exports5.literal(LiteralNode.mock(node, { pool: ["*"] }), ctx), ...selector(EntitySelectorNode.mock(node, { pool: EntitySelectorAtVariable.filterAvailable(ctx) }), ctx)); + } + return ans; +}; +var selector = (node, ctx) => { + if (Range.contains(node.children[0], ctx.offset, true)) { + return builtin_exports5.literal(node.children[0], ctx); + } + if (node.arguments?.innerRange && Range.contains(node.arguments.innerRange, ctx.offset, true)) { + return selectorArguments(node.arguments, ctx); + } + return []; +}; +var selectorArguments = (node, ctx) => { + const selector3 = node.parent; + if (!EntitySelectorNode.is(selector3)) { + return []; + } + return builtin_exports5.record({ + key: (record3, pair, _ctx, range3, insertValue, insertComma) => { + return [...EntitySelectorNode.ArgumentKeys].filter( + (k) => EntitySelectorNode.canKeyExist(selector3, record3, k) === 0 + /* EntitySelectorNode.Result.Ok */ + ).map((k) => CompletionItem.create(k, range3, { + kind: 10, + insertText: new InsertTextBuilder().literal(k).if(insertValue, (b) => b.literal("=").placeholder()).if(insertComma, (b) => b.literal(",")).build() + })); + }, + value: (_record, pair, ctx2) => { + if (pair.value) { + return builtin_exports5.dispatch(pair.value, ctx2); + } + return []; + } + })(node, ctx); +}; +var intRange3 = (node, _ctx) => { + return [ + CompletionItem.create("-2147483648..2147483647", node, { + kind: 21 + /* CompletionKind.Constant */ + }) + ]; +}; +var vector2 = (node, _ctx) => { + const createCompletion = (coordinate3, sortText) => CompletionItem.create(new Array(node.options.dimension).fill(coordinate3).join(" "), node, { + sortText + }); + const ans = []; + ans.push(createCompletion("~", "a")); + if (!node.options.noLocal) { + ans.push(createCompletion("^", "b")); + } + ans.push(createCompletion("0.0", "c")); + return ans; +}; +function register14(meta) { + meta.registerCompleter("mcfunction:block", block2); + meta.registerCompleter("mcfunction:component_list", componentList); + meta.registerCompleter("mcfunction:component_tests", componentTests); + meta.registerCompleter("mcfunction:coordinate", coordinate); + meta.registerCompleter("mcfunction:entity_selector", selector); + meta.registerCompleter("mcfunction:entity_selector/arguments", selectorArguments); + meta.registerCompleter("mcfunction:int_range", intRange3); + meta.registerCompleter("mcfunction:item_stack", itemStack2); + meta.registerCompleter("mcfunction:item_predicate", itemPredicate2); + meta.registerCompleter("mcfunction:objective_criteria", objectiveCriteria); + meta.registerCompleter("mcfunction:particle", particle2); + meta.registerCompleter("mcfunction:score_holder", scoreHolder); + meta.registerCompleter("mcfunction:vector", vector2); +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/inlayHintProvider.js +var inlayHintProvider = (node, ctx) => { + if (node.children[0]?.type !== "mcfunction:entry") { + return []; + } + const ans = []; + traversePreOrder(node, (_) => true, CommandChildNode.is, (n) => { + const node2 = n; + const config = ctx.config.env.feature.inlayHint; + if (config === true || typeof config === "object" && config.enabledNodes.includes(node2.children[0].type)) { + ans.push({ + offset: node2.range.start, + label: `${node2.path[node2.path.length - 1]}:`, + paddingRight: true + }); + } + }); + return ans; +}; + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/parser/argument.js +var IntegerPattern = /^-?\d+$/; +var FloatPattern = /^-?(?:\d+\.?\d*|\.\d+)$/; +var DoubleMax = Number.MAX_VALUE; +var DoubleMin = -DoubleMax; +var FloatMax = (2 - 2 ** -23) * 2 ** 127; +var FloatMin = -FloatMax; +var IntegerMax = 2 ** 31 - 1; +var IntegerMin = -(2 ** 31); +var LongMax = 9223372036854775807n; +var LongMin = -9223372036854775808n; +var FakeNameMaxLength = 40; +var ObjectiveMaxLength = 16; +var PlayerNameMaxLength = 16; +function shouldValidateLength(ctx) { + const release = ctx.project["loadedVersion"]; + return !release || ReleaseVersion.cmp(release, "1.18") < 0; +} +function shouldUseOldItemStackFormat(ctx) { + const release = ctx.project["loadedVersion"]; + return !release || ReleaseVersion.cmp(release, "1.20.5") < 0; +} +var argument = (rawTreeNode, prevNodes) => { + const treeNode = rawTreeNode; + const wrap = (parser) => failOnEmpty(stopBefore(parser, "\r", "\n")); + switch (treeNode.parser) { + case "brigadier:bool": + return wrap(boolean4); + case "brigadier:double": + return wrap(double(treeNode.properties?.min, treeNode.properties?.max)); + case "brigadier:float": + return wrap(float4(treeNode.properties?.min, treeNode.properties?.max)); + case "brigadier:integer": + return wrap(integer4(treeNode.properties?.min, treeNode.properties?.max)); + case "brigadier:long": + return wrap(long4(treeNode.properties?.min, treeNode.properties?.max)); + case "brigadier:string": + switch (treeNode.properties.type) { + case "word": + return wrap(unquotedString); + case "phrase": + return wrap(brigadierString); + case "greedy": + default: + return wrap(greedyString); + } + case "minecraft:angle": + return wrap(validate(coordinate2(), (res) => res.notation !== "^", localize("mcfunction.parser.vector.local-disallowed"))); + case "minecraft:block_pos": + return wrap(vector3({ dimension: 3, integersOnly: true })); + case "minecraft:block_predicate": + return wrap(blockPredicate); + case "minecraft:block_state": + return wrap(blockState); + case "minecraft:color": + return wrap(map(commandLiteral({ pool: ColorArgumentValues }), (res) => ({ + ...res, + color: Color.NamedColors.has(res.value) ? Color.fromCompositeRGB(Color.NamedColors.get(res.value)) : void 0 + }))); + case "minecraft:column_pos": + return wrap(vector3({ dimension: 2, integersOnly: true })); + case "minecraft:component": + return wrap(typeRefParser("::java::server::util::text::Text")); + case "minecraft:dialog": + return wrap(resourceOrInline("dialog")); + case "minecraft:dimension": + return wrap(resourceLocation6({ category: "dimension" })); + case "minecraft:entity": + return wrap(entity2(treeNode.properties.amount, treeNode.properties.type)); + case "minecraft:entity_anchor": + return wrap(commandLiteral({ pool: EntityAnchorArgumentValues })); + case "minecraft:entity_summon": + return wrap(resourceLocation6({ category: "entity_type" })); + case "minecraft:float_range": + return wrap(range2("float", treeNode.properties?.min, treeNode.properties?.max, treeNode.properties?.minSpan, treeNode.properties?.maxSpan)); + case "minecraft:function": + return wrap(resourceLocation6({ category: "function", allowTag: true })); + case "minecraft:gamemode": + return wrap(commandLiteral({ pool: GamemodeArgumentValues })); + case "minecraft:game_profile": + return wrap(entity2("multiple", "players")); + case "minecraft:heightmap": + return wrap(commandLiteral({ pool: HeightmapValues })); + case "minecraft:int_range": + return wrap(range2("integer", treeNode.properties?.min, treeNode.properties?.max, treeNode.properties?.minSpan, treeNode.properties?.maxSpan)); + case "minecraft:item_enchantment": + return wrap(resourceLocation6({ category: "enchantment" })); + case "minecraft:item_predicate": + return wrap(itemPredicate3); + case "minecraft:item_slot": + return wrap((src, ctx) => { + return commandLiteral({ pool: getItemSlotArgumentValues(ctx) })(src, ctx); + }); + case "minecraft:item_slots": + return wrap((src, ctx) => { + return commandLiteral({ pool: getItemSlotsArgumentValues(ctx) })(src, ctx); + }); + case "minecraft:item_stack": + return wrap(itemStack3); + case "minecraft:loot_modifier": + return wrap(resourceOrInline("item_modifier")); + case "minecraft:loot_predicate": + return wrap(resourceOrInline("predicate")); + case "minecraft:loot_table": + return wrap(resourceOrInline("loot_table")); + case "minecraft:message": + return wrap(message); + case "minecraft:mob_effect": + return wrap(resourceLocation6({ category: "mob_effect" })); + case "minecraft:nbt_compound_tag": + return wrap(nbtDispatchedParser(parser_exports3.compound, treeNode.properties)); + case "minecraft:nbt_path": + return wrap(nbtPathParser(parser_exports3.path, treeNode.properties)); + case "minecraft:nbt_tag": + return wrap(nbtDispatchedParser(parser_exports3.entry, treeNode.properties)); + case "minecraft:objective": + return wrap(objective(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); + case "minecraft:objective_criteria": + return wrap(objectiveCriteria2); + case "minecraft:operation": + return wrap(commandLiteral({ pool: OperationArgumentValues, colorTokenType: "operator" })); + case "minecraft:particle": + return wrap(particle3); + case "minecraft:resource": + case "minecraft:resource_key": + case "minecraft:resource_or_tag": + case "minecraft:resource_or_tag_key": + const allowTag = treeNode.parser === "minecraft:resource_or_tag" || treeNode.parser === "minecraft:resource_or_tag_key"; + return wrap(resourceLocation6({ + category: ResourceLocation.shorten(treeNode.properties.registry), + allowTag + })); + case "minecraft:resource_location": + return wrap(resourceLocation6(treeNode.properties ?? { pool: [], allowUnknown: true })); + case "minecraft:resource_selector": + return wrap(resourceSelector(treeNode.properties.registry)); + case "minecraft:rotation": + return wrap(vector3({ dimension: 2, noLocal: true })); + case "minecraft:score_holder": + return wrap(scoreHolder2(treeNode.properties.usageType, treeNode.properties.amount)); + case "minecraft:scoreboard_slot": + return wrap((src, ctx) => { + return commandLiteral({ pool: getScoreboardSlotArgumentValues(ctx) })(src, ctx); + }); + case "minecraft:style": + return wrap(typeRefParser("::java::server::util::text::TextStyle")); + case "minecraft:swizzle": + return wrap(commandLiteral({ pool: SwizzleArgumentValues })); + case "minecraft:team": + return wrap(team(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); + case "minecraft:team_color": + return wrap(map(commandLiteral({ pool: Color.ColorNames }), (res) => ({ + ...res, + color: Color.NamedColors.has(res.value) ? Color.fromCompositeRGB(Color.NamedColors.get(res.value)) : void 0 + }))); + case "minecraft:template_mirror": + return wrap(commandLiteral({ pool: MirrorValues })); + case "minecraft:template_rotation": + return wrap(commandLiteral({ pool: RotationValues })); + case "minecraft:time": + return wrap(time); + case "minecraft:uuid": + return wrap(uuid); + case "minecraft:vec2": + return wrap(vector3({ dimension: 2, noLocal: true })); + case "minecraft:vec3": + return wrap(vector3({ dimension: 3 })); + case "spyglassmc:criterion": + const advancementNode = prevNodes.length > 0 ? prevNodes[prevNodes.length - 1].children[0] : void 0; + if (ResourceLocationNode.is(advancementNode)) { + return wrap(criterion(ResourceLocationNode.toString(advancementNode, "full"), SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); + } + return wrap(greedyString); + case "spyglassmc:tag": + return wrap(tag(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); + default: + return void 0; + } +}; +function block3(isPredicate) { + return map(sequence([ + resourceLocation6({ category: "block", allowTag: isPredicate }), + optional(map(failOnEmpty(record2({ + start: "[", + pair: { + key: string4({ + ...BrigadierStringOptions, + colorTokenType: "property" + }), + sep: "=", + value: brigadierString, + end: ",", + trailingEnd: true + }, + end: "]" + })), (res) => ({ ...res, type: "mcfunction:block/states" }))), + optional(failOnEmpty(parser_exports3.compound)) + ]), (res) => { + const ans = { + type: "mcfunction:block", + range: res.range, + children: res.children, + id: res.children.find(ResourceLocationNode.is), + states: res.children.find(BlockStatesNode.is), + nbt: res.children.find(NbtCompoundNode.is), + isPredicate + }; + return ans; + }); +} +var blockState = block3(false); +var blockPredicate = block3(true); +function double(min2 = DoubleMin, max2 = DoubleMax) { + return float2({ pattern: FloatPattern, min: min2, max: max2 }); +} +function float4(min2 = FloatMin, max2 = FloatMax) { + return float2({ pattern: FloatPattern, min: min2, max: max2 }); +} +function integer4(min2 = IntegerMin, max2 = IntegerMax) { + return integer2({ pattern: IntegerPattern, min: min2, max: max2 }); +} +function long4(min2, max2) { + return long2({ + pattern: IntegerPattern, + min: BigInt(min2 ?? LongMin), + max: BigInt(max2 ?? LongMax) + }); +} +function coordinate2(integerOnly = false) { + return (src, ctx) => { + const ans = { + type: "mcfunction:coordinate", + notation: "", + range: Range.create(src), + value: 0 + }; + if (src.trySkip("^")) { + ans.notation = "^"; + } else if (src.trySkip("~")) { + ans.notation = "~"; + } + if (src.canReadInLine() && src.peek() !== " " || ans.notation === "") { + const result = (integerOnly && ans.notation === "" ? integer4 : double)()(src, ctx); + ans.value = Number(result.value); + } + ans.range.end = src.cursor; + return ans; + }; +} +function criterion(advancement, usageType, terminators = []) { + return unquotableSymbol({ category: "advancement", subcategory: "criterion", parentPath: [advancement], usageType }, terminators); +} +function entity2(amount, type2) { + return map(select([{ predicate: (src) => src.peek() === "@", parser: selector2() }, { + parser: any3([ + failOnError(uuid), + validateLength(brigadierString, PlayerNameMaxLength, "mcfunction.parser.entity-selector.player-name.too-long") + ]) + }]), (res, _src, ctx) => { + const ans = { type: "mcfunction:entity", range: res.range, children: [res] }; + if (StringNode.is(res)) { + ans.playerName = res; + } else if (EntitySelectorNode.is(res)) { + ans.selector = res; + } else { + ans.uuid = res; + } + if (amount === "single" && ans.selector && !ans.selector.single) { + ctx.err.report(localize("mcfunction.parser.entity-selector.multiple-disallowed"), ans); + } + if (type2 === "players" && (ans.uuid || ans.selector && !ans.selector.playersOnly && !ans.selector.currentEntity)) { + ctx.err.report(localize("mcfunction.parser.entity-selector.entities-disallowed"), ans); + } + return ans; + }); +} +var greedyString = string4({ + unquotable: { blockList: /* @__PURE__ */ new Set(["\n", "\r"]) } +}); +var itemStack3 = (src, ctx) => { + const oldFormat = shouldUseOldItemStackFormat(ctx); + return map(sequence([ + resourceLocation6({ category: "item" }), + oldFormat ? optional(failOnEmpty(parser_exports3.compound)) : optional(failOnEmpty(components)) + ]), (res) => { + const ans = { + type: "mcfunction:item_stack", + range: res.range, + children: res.children, + id: res.children.find(ResourceLocationNode.is), + components: res.children.find(ComponentListNode.is), + nbt: res.children.find(NbtCompoundNode.is) + }; + return ans; + })(src, ctx); +}; +var itemPredicate3 = (src, ctx) => { + const oldFormat = shouldUseOldItemStackFormat(ctx); + return map(sequence([ + oldFormat ? resourceLocation6({ category: "item", allowTag: true }) : any3([ + resourceLocation6({ category: "item", allowTag: true }), + literal("*") + ]), + oldFormat ? optional(failOnEmpty(parser_exports3.compound)) : optional(componentTests2) + ]), (res) => { + const ans = { + type: "mcfunction:item_predicate", + range: res.range, + children: res.children, + id: res.children.find(ResourceLocationNode.is) || res.children.find(LiteralNode.is), + tests: res.children.find(ComponentTestsNode.is), + nbt: res.children.find(NbtCompoundNode.is) + }; + return ans; + })(src, ctx); +}; +function typeRefParser(typeRef) { + return (src, ctx) => { + const release = ctx.project["loadedVersion"]; + if (!release || ReleaseVersion.cmp(release, "1.21.5") < 0) { + return jsonParser(typeRef)(src, ctx); + } + return nbtParser(typeRef)(src, ctx); + }; +} +function jsonParser(typeRef) { + return map(parser_exports2.entry, (res) => ({ + type: "json:typed", + range: res.range, + children: [res], + targetType: { kind: "reference", path: typeRef } + })); +} +function nbtParser(typeRef) { + return map(parser_exports3.entry, (res) => ({ + type: "nbt:typed", + range: res.range, + children: [res], + targetType: { kind: "reference", path: typeRef } + })); +} +function commandLiteral(options2) { + return (src, ctx) => { + const ans = literal(options2)(src, ctx); + if (ans.value.length === 0) { + ans.value = src.readUntil(...Whitespaces); + ans.range = Range.create(ans.range.start, src); + } + return ans; + }; +} +var message = (src, ctx) => { + const ans = { + type: "mcfunction:message", + range: Range.create(src), + children: [] + }; + while (src.canReadInLine()) { + if (EntitySelectorAtVariable.is(src.peek(2))) { + ans.children.push(selector2(true)(src, ctx)); + } else { + ans.children.push(stopBefore(greedyString, ...EntitySelectorAtVariable.filterAvailable(ctx))(src, ctx)); + } + } + return ans; +}; +function nbtDispatchedParser(parser, properties) { + return map(parser, (res) => { + const ans = { type: "mcfunction:nbt", range: res.range, children: [res], properties }; + return ans; + }); +} +function nbtPathParser(parser, properties) { + return map(parser, (res) => { + const ans = { + type: "mcfunction:nbt_path", + range: res.range, + children: [res], + properties + }; + return ans; + }); +} +var particle3 = (src, ctx) => { + const release = ctx.project["loadedVersion"]; + if (!release || ReleaseVersion.cmp(release, "1.20.5") >= 0) { + return map(sequence([ + resourceLocation6({ category: "particle_type" }), + optional(failOnEmpty(parser_exports3.compound)) + ]), (res) => { + const ans = { + type: "mcfunction:particle", + range: res.range, + children: res.children, + id: res.children.find(ResourceLocationNode.is) + }; + return ans; + })(src, ctx); + } + const sep2 = map(sep, () => []); + const vec = vector3({ dimension: 3 }); + const color = map(vec, (res) => ({ + ...res, + color: res.children.length === 3 ? { + value: Color.fromDecRGB(res.children[0].value, res.children[1].value, res.children[2].value), + format: [ColorFormat.DecRGB] + } : void 0 + })); + const map3 = { + block: blockState, + block_marker: blockState, + dust: sequence([color, float4()], sep2), + dust_color_transition: sequence([color, float4(), color], sep2), + falling_dust: blockState, + item: itemStack3, + sculk_charge: float4(), + shriek: integer4(), + vibration: sequence([vec, integer4()], sep2) + }; + return map(sequence([resourceLocation6({ category: "particle_type" }), { + get: (res) => { + return map3[ResourceLocationNode.toString(res.children[0], "short")]; + } + }], sep2), (res) => { + const ans = { + type: "mcfunction:particle", + range: res.range, + children: res.children, + id: res.children.find(ResourceLocationNode.is) + }; + return ans; + })(src, ctx); +}; +function range2(type2, min2, max2, minSpan, maxSpan, cycleable) { + const number5 = type2 === "float" ? float4(min2, max2) : integer4(min2, max2); + const low = failOnEmpty(stopBefore(number5, "..")); + const sep2 = failOnEmpty(literal({ pool: [".."], colorTokenType: "keyword" })); + const high = failOnEmpty(number5); + return map(any3([ + /* exactly */ + sequence([low]), + /* atLeast */ + sequence([low, sep2]), + /* atMost */ + sequence([sep2, high]), + /* between */ + sequence([low, sep2, high]) + ]), (res, _src, ctx) => { + const valueNodes = type2 === "float" ? res.children.filter(FloatNode.is) : res.children.filter(IntegerNode.is); + const sepNode = res.children.find(LiteralNode.is); + const ans = { + type: type2 === "float" ? "mcfunction:float_range" : "mcfunction:int_range", + range: res.range, + children: res.children, + value: sepNode ? valueNodes.length === 2 ? [valueNodes[0].value, valueNodes[1].value] : Range.endsBefore(valueNodes[0].range, sepNode.range.start) ? [valueNodes[0].value, void 0] : [void 0, valueNodes[0].value] : [valueNodes[0].value, valueNodes[0].value] + }; + if (!cycleable && ans.value[0] !== void 0 && ans.value[1] !== void 0 && ans.value[0] > ans.value[1]) { + ctx.err.report(localize("mcfunction.parser.range.min>max", ans.value[0], ans.value[1]), res); + } else if (minSpan !== void 0 || maxSpan !== void 0) { + const span = ans.value[0] !== void 0 && ans.value[1] !== void 0 ? Math.abs(ans.value[0] - ans.value[1]) : ans.value[0] ?? ans.value[1] ?? Infinity; + if (minSpan !== void 0 && span < minSpan) { + ctx.err.report(localize("mcfunction.parser.range.span-too-small", span, minSpan), res); + } else if (maxSpan !== void 0 && span > maxSpan) { + ctx.err.report(localize("mcfunction.parser.range.span-too-large", span, maxSpan), res); + } + } + return ans; + }); +} +function resourceOrInline(category) { + return select([{ + predicate: (src) => LegalResourceLocationCharacters.has(src.peek()), + parser: resourceLocation6({ category }) + }, { + parser: map(parser_exports3.entry, (res) => { + const ans = { + type: "mcfunction:nbt_resource", + range: res.range, + children: [res], + category + }; + return ans; + }) + }]); +} +var LegalResourceSelectorCharacters = /* @__PURE__ */ new Set([ + ...LegalResourceLocationCharacters, + ":", + "/", + "*", + "?" +]); +function resourceSelector(registry) { + return string4({ + colorTokenType: "resourceLocation", + unquotable: { allowList: LegalResourceSelectorCharacters } + }); +} +function selectorPrefix(ignoreInvalidPrefix) { + return (src, ctx) => { + const start = src.cursor; + let value; + if (ignoreInvalidPrefix) { + value = src.peek(2); + src.skip(2); + } else { + value = src.readUntil(" ", "\r", "\n", "["); + } + const allowedVariables = EntitySelectorAtVariable.filterAvailable(ctx); + const ans = { + type: "literal", + range: Range.create(start, src), + options: { pool: allowedVariables }, + value + }; + if (!allowedVariables.includes(value) && !ignoreInvalidPrefix) { + ctx.err.report(localize("mcfunction.parser.entity-selector.invalid", ans.value), ans); + } + return ans; + }; +} +function selector2(ignoreInvalidPrefix = false) { + let chunkLimited; + let currentEntity; + let dimensionLimited; + let playersOnly; + let predicates; + let single; + let typeLimited; + return map(sequence([failOnEmpty(selectorPrefix(ignoreInvalidPrefix)), { + get: (res) => { + const variable = LiteralNode.is(res.children?.[0]) ? res.children[0].value : void 0; + currentEntity = variable ? variable === "@s" : void 0; + playersOnly = variable ? variable === "@p" || variable === "@a" || variable === "@r" : void 0; + predicates = variable === "@e" ? ["Entity::isAlive"] : void 0; + single = variable ? ["@p", "@r", "@s", "@n"].includes(variable) : void 0; + typeLimited = playersOnly; + function invertable(parser) { + return map(sequence([ + optional(failOnEmpty(literal({ pool: ["!"], colorTokenType: "keyword" }))), + (src) => { + src.skipSpace(); + return void 0; + }, + parser + ]), (res2) => { + const ans = { + type: "mcfunction:entity_selector/arguments/value/invertable", + range: res2.range, + children: res2.children, + inverted: !!res2.children.find((n) => LiteralNode.is(n) && n.value === "!"), + value: res2.children.find((n) => !LiteralNode.is(n) || n.value !== "!") + }; + return ans; + }); + } + return optional(map(failOnEmpty(record2({ + start: "[", + pair: { + key: string4({ + ...BrigadierStringOptions, + value: { + parser: literal({ + pool: [...EntitySelectorNode.ArgumentKeys], + colorTokenType: "property" + }), + type: "literal" + } + }), + sep: "=", + value: { + get: (record3, key2) => { + const hasKey = (key3) => !!record3.children.find((p) => p.key?.value === key3); + const hasNonInvertedKey = (key3) => !!record3.children.find((p) => p.key?.value === key3 && !p.value?.inverted); + switch (key2?.value) { + case "advancements": + return map(record2({ + start: "{", + pair: { + key: resourceLocation6({ + category: "advancement" + }), + sep: "=", + value: { + get: (_, key3) => select([{ + predicate: (src) => src.peek() === "{", + parser: map(record2({ + start: "{", + pair: { + key: key3 ? criterion(ResourceLocationNode.toString(key3, "full"), "reference", ["}", ",", "="]) : unquotedString, + sep: "=", + value: boolean4, + end: ",", + trailingEnd: true + }, + end: "}" + }), (res2) => { + const ans = { + ...res2, + type: "mcfunction:entity_selector/arguments/advancements/criteria" + }; + return ans; + }) + }, { parser: boolean4 }]) + }, + end: ",", + trailingEnd: true + }, + end: "}" + }), (res2, _, ctx) => { + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + const ans = { + ...res2, + type: "mcfunction:entity_selector/arguments/advancements" + }; + return ans; + }); + case "distance": + return map(range2("float", 0), (res2, _, ctx) => { + dimensionLimited = true; + chunkLimited ??= !playersOnly && res2.value[1] !== void 0; + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "gamemode": + return map(invertable(string4({ + unquotable: BrigadierUnquotableOption, + value: { + type: "literal", + parser: literal(...GamemodeArgumentValues) + } + })), (res2, _, ctx) => { + playersOnly = true; + if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "limit": + return map(integer4(0), (res2, _, ctx) => { + single = res2.value <= 1; + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + if (currentEntity) { + ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); + } + return res2; + }); + case "level": + return map(range2("integer", 0), (res2, _, ctx) => { + playersOnly = true; + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "name": + return map(invertable(brigadierString), (res2, _, ctx) => { + if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "nbt": + return invertable(parser_exports3.compound); + case "predicate": + return invertable(resourceLocation6({ category: "predicate" })); + case "scores": + return map(record2({ + start: "{", + pair: { + key: objective("reference", [ + "[", + "=", + ",", + "]", + "{", + "}" + ]), + sep: "=", + value: range2("integer"), + end: ",", + trailingEnd: true + }, + end: "}" + }), (res2, _, ctx) => { + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + const ans = { + ...res2, + type: "mcfunction:entity_selector/arguments/scores" + }; + return ans; + }); + case "sort": + return map(string4({ + unquotable: BrigadierUnquotableOption, + value: { + type: "literal", + parser: literal("arbitrary", "furthest", "nearest", "random") + } + }), (res2, _, ctx) => { + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + if (currentEntity) { + ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); + } + return res2; + }); + case "tag": + return invertable(tag("reference", ["[", "=", ",", "]", "{", "}"])); + case "team": + return map(invertable(team("reference", ["[", "=", ",", "]", "{", "}"])), (res2, _, ctx) => { + if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "type": + return map(invertable(resourceLocation6({ + category: "entity_type", + allowTag: true + })), (res2, _, ctx) => { + if (typeLimited) { + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } else { + ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); + } + } else if (!res2.inverted && !res2.value.isTag) { + typeLimited = true; + if (ResourceLocationNode.toString(res2.value, "short") === "player") { + playersOnly = true; + } + } + return res2; + }); + case "x": + case "y": + case "z": + return map(double(), (res2, _, ctx) => { + dimensionLimited = true; + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "dx": + case "dy": + case "dz": + return map(double(), (res2, _, ctx) => { + dimensionLimited = true; + chunkLimited = !playersOnly; + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case "x_rotation": + case "y_rotation": + return map(range2("float", void 0, void 0, void 0, void 0, true), (res2, _, ctx) => { + if (hasKey(key2.value)) { + ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); + } + return res2; + }); + case void 0: + return () => Failure; + default: + return (_src, ctx) => { + ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.unknown", localeQuote(key2.value)), key2); + return Failure; + }; + } + } + }, + end: ",", + trailingEnd: true + }, + end: "]" + })), (res2) => { + const ans = { + ...res2, + type: "mcfunction:entity_selector/arguments" + }; + return ans; + })); + } + }]), (res) => { + const ans = { + type: "mcfunction:entity_selector", + range: res.range, + children: res.children, + variable: res.children.find(LiteralNode.is).value.slice(1), + arguments: res.children.find(EntitySelectorArgumentsNode.is), + chunkLimited, + currentEntity, + dimensionLimited, + playersOnly, + predicates, + single, + typeLimited + }; + ans.hover = getEntitySelectorHover(ans); + return ans; + }); +} +function getEntitySelectorHover(node) { + const grades = /* @__PURE__ */ new Map([ + [0, "\u{1F922}"], + // Bad + [1, "\u{1F605}"], + // Normal + [2, "Good"], + // Good + [3, "Great"], + // Great + [4, "\u{1F60C}\u{1F44C}"] + // Excellent + ]); + let ans; + if (node.currentEntity) { + ans = `**Performance**: ${grades.get(4)} +- \`currentEntity\`: \`${node.currentEntity}\``; + } else { + const amountOfTrue = [node.chunkLimited, node.dimensionLimited, node.playersOnly, node.typeLimited].filter((v) => v).length; + ans = `**Performance**: ${grades.get(amountOfTrue)} +- \`chunkLimited\`: \`${!!node.chunkLimited}\` +- \`dimensionLimited\`: \`${!!node.dimensionLimited}\` +- \`playersOnly\`: \`${!!node.playersOnly}\` +- \`typeLimited\`: \`${!!node.typeLimited}\``; + } + if (node.predicates?.length) { + ans += ` + +------ +**Predicates**: +${node.predicates.map((p) => `- \`${p}\``).join("\n")}`; + } + return ans; +} +function scoreHolderFakeName(usageType) { + return validateLength(symbol6({ category: "score_holder", usageType }), FakeNameMaxLength, "mcfunction.parser.score_holder.fake-name.too-long"); +} +function scoreHolder2(usageType, amount) { + return map(select([ + { + predicate: (src) => src.peek() === "*" && (!src.canRead(2) || src.matchPattern(/^\s/, 1)), + parser: literal("*") + }, + { prefix: "@", parser: selector2() }, + { parser: scoreHolderFakeName(usageType) } + ]), (res, _src, ctx) => { + const ans = { + type: "mcfunction:score_holder", + range: res.range, + children: [res] + }; + if (SymbolNode.is(res)) { + ans.fakeName = res; + } else if (EntitySelectorNode.is(res)) { + ans.selector = res; + } else { + ans.wildcard = res; + } + if (amount === "single" && ans.selector && !ans.selector.single) { + ctx.err.report(localize("mcfunction.parser.entity-selector.multiple-disallowed"), ans); + } + return ans; + }); +} +function symbol6(options2, terminators = []) { + return stopBefore(symbol5(options2), Whitespaces, terminators); +} +function objective(usageType, terminators = []) { + return validateLength(unquotableSymbol({ category: "objective", usageType }, terminators), ObjectiveMaxLength, "mcfunction.parser.objective.too-long"); +} +var objectiveCriteria2 = map(any3([ + sequence([ + stopBefore(resourceLocation6({ category: "stat_type", namespacePathSep: "." }), ":"), + failOnEmpty(literal(":")), + { + get: (res) => { + if (ResourceLocationNode.is(res.children[0])) { + const category = ObjectiveCriteriaNode.ComplexCategories.get(ResourceLocationNode.toString(res.children[0], "short")); + if (category) { + return resourceLocation6({ category, namespacePathSep: "." }); + } + } + return resourceLocation6({ pool: [], allowUnknown: true, namespacePathSep: "." }); + } + } + ]), + literal(...ObjectiveCriteriaNode.SimpleValues) +]), (res) => { + const ans = { type: "mcfunction:objective_criteria", range: res.range }; + if (LiteralNode.is(res)) { + ans.simpleValue = res.value; + } else { + ans.children = res.children.filter(ResourceLocationNode.is); + } + return ans; +}); +function tag(usageType, terminators = []) { + return unquotableSymbol({ category: "tag", usageType }, terminators); +} +function team(usageType, terminators = []) { + return unquotableSymbol({ category: "team", usageType }, terminators); +} +function unquotableSymbol(options2, terminators) { + return validateUnquotable(symbol6(options2, terminators)); +} +var time = map(sequence([ + float4(0, void 0), + optional(failOnEmpty(literal(...TimeNode.Units))) +]), (res) => { + const valueNode = res.children.find(FloatNode.is); + const unitNode = res.children.find(LiteralNode.is); + const ans = { + type: "mcfunction:time", + range: res.range, + children: res.children, + value: valueNode.value, + unit: unitNode?.value + }; + return ans; +}); +var unquotedString = string4({ + unquotable: BrigadierUnquotableOption +}); +var UuidPattern = /^[0-9a-f]+-[0-9a-f]+-[0-9a-f]+-[0-9a-f]+-[0-9a-f]+$/i; +var uuid = (src, ctx) => { + const ans = { type: "mcfunction:uuid", range: Range.create(src), bits: [0n, 0n] }; + const raw = src.readUntil(" ", "\r", "\n", "\r"); + let isLegal = false; + if (raw.match(UuidPattern)) { + try { + const parts = raw.split("-").map((p) => BigInt(`0x${p}`)); + if (parts.every((p) => p <= LongMax)) { + isLegal = true; + ans.bits[0] = BigInt.asIntN(64, parts[0] << 32n | parts[1] << 16n | parts[2]); + ans.bits[1] = BigInt.asIntN(64, parts[3] << 48n | parts[4]); + } + } catch { + } + } + ans.range.end = src.cursor; + if (!isLegal) { + ctx.err.report(localize("mcfunction.parser.uuid.invalid"), ans); + } + return ans; +}; +function validateLength(parser, maxLength, localeKey) { + return (src, ctx) => { + if (!shouldValidateLength(ctx)) { + return parser(src, ctx); + } + return map(parser, (res, _src, ctx2) => { + if (res.value.length > maxLength) { + ctx2.err.report(localize(localeKey, maxLength), res); + } + return res; + })(src, ctx); + }; +} +function validateUnquotable(parser) { + return map(parser, (res, _src, ctx) => { + if (!res.value.match(BrigadierUnquotablePattern)) { + ctx.err.report(localize("parser.string.illegal-brigadier", localeQuote(res.value)), res); + } + return res; + }); +} +function vector3(options2) { + return (src, ctx) => { + const ans = { + type: "mcfunction:vector", + range: Range.create(src), + children: [], + options: options2, + system: 0 + }; + if (src.peek() === "^") { + ans.system = 1; + } + for (let i = 0; i < options2.dimension; i++) { + if (i > 0) { + sep(src, ctx); + } + const coord = options2.integersOnly ? coordinate2(options2.integersOnly)(src, ctx) : coordinate2(options2.integersOnly)(src, ctx); + ans.children.push(coord); + if (ans.system === 1 !== (coord.notation === "^")) { + ctx.err.report(localize("mcfunction.parser.vector.mixed"), coord); + } + } + if (options2.noLocal && ans.system === 1) { + ctx.err.report(localize("mcfunction.parser.vector.local-disallowed"), ans); + } + ans.range.end = src.cursor; + return ans; + }; +} +var components = (src, ctx) => { + const release = ctx.project["loadedVersion"]; + const allowComponentRemoval = !release || ReleaseVersion.cmp(release, "1.21") >= 0; + const ans = { + type: "mcfunction:component_list", + range: Range.create(src), + children: [] + }; + if (!src.trySkip("[")) { + return Failure; + } + ans.innerRange = Range.create(src); + src.skipWhitespace(); + while (src.canRead() && src.peek() !== "]") { + const start = src.cursor; + if (allowComponentRemoval && src.tryPeek("!")) { + const prefix = literal("!")(src, ctx); + src.skipWhitespace(); + const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); + ans.children.push({ + type: "mcfunction:component_removal", + range: Range.create(start, src), + children: [prefix, key2], + prefix, + key: key2 + }); + src.skipWhitespace(); + } else { + const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); + src.skipWhitespace(); + literal("=")(src, ctx); + src.skipWhitespace(); + const value = parser_exports3.entry(src, ctx); + if (value === Failure) { + ctx.err.report(localize("expected", localize("parser.record.value")), Range.create(src, () => src.skipUntilOrEnd(",", "]", "\r", "\n"))); + ans.children.push({ + type: "mcfunction:component", + range: Range.create(start, src), + children: [key2], + key: key2, + value: void 0 + }); + } else { + ans.children.push({ + type: "mcfunction:component", + range: Range.create(start, src), + children: [key2, value], + key: key2, + value + }); + } + src.skipWhitespace(); + } + if (src.trySkip(",")) { + src.skipWhitespace(); + if (src.peek() === "]") { + break; + } + } else { + break; + } + } + src.skipWhitespace(); + ans.innerRange.end = src.cursor; + literal("]")(src, ctx); + ans.range.end = src.cursor; + return ans; +}; +var componentTest = (src, ctx) => { + const start = src.cursor; + src.skipWhitespace(); + const negated = src.trySkip("!"); + src.skipWhitespace(); + const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); + src.skipWhitespace(); + if (ResourceLocationNode.toString(key2, "full") === "minecraft:count") { + key2.options.category = void 0; + key2.options.pool = ["minecraft:count"]; + } + if (src.trySkip("=")) { + src.skipWhitespace(); + const ans2 = { + type: "mcfunction:component_test_exact", + range: Range.create(start, src), + children: [key2], + key: key2, + negated + }; + const value = parser_exports3.entry(src, ctx); + if (value === Failure) { + ctx.err.report(localize("expected", localize("nbt.node")), src); + src.skipUntilOrEnd(",", "|", "]"); + } else { + ans2.children.push(value); + ans2.value = value; + } + src.skipWhitespace(); + ans2.range.end = src.cursor; + return ans2; + } + if (src.trySkip("~")) { + src.skipWhitespace(); + if (key2.options.category !== void 0) { + const release = ctx.project["loadedVersion"]; + if (release && ReleaseVersion.cmp(release, "1.21.5") < 0) { + key2.options.category = "item_sub_predicate_type"; + } else { + key2.options.category = "data_component_predicate_type"; + } + } + const ans2 = { + type: "mcfunction:component_test_sub_predicate", + range: Range.create(start, src), + children: [key2], + key: key2, + negated + }; + const predicate = parser_exports3.entry(src, ctx); + if (predicate === Failure) { + ctx.err.report(localize("expected", localize("nbt.node")), src); + src.skipUntilOrEnd(",", "|", "]"); + } else { + ans2.children.push(predicate); + ans2.value = predicate; + } + src.skipWhitespace(); + ans2.range.end = src.cursor; + return ans2; + } + const ans = { + type: "mcfunction:component_test_exists", + range: Range.create(start, src), + children: [key2], + key: key2, + negated + }; + return ans; +}; +var componentTestsAllOf = (src, ctx) => { + const ans = { + type: "mcfunction:component_tests_all_of", + range: Range.create(src), + children: [] + }; + while (src.canRead()) { + src.skipWhitespace(); + const testNode = componentTest(src, ctx); + ans.children.push(testNode); + src.skipWhitespace(); + if (src.peek() === ",") { + src.skip(); + } else if (src.peek() === "|" || src.peek() === "]") { + break; + } else { + ctx.err.report(localize("expected", localeQuote("]")), src); + src.skipUntilOrEnd(",", "|", "]"); + } + } + ans.range.end = src.cursor; + return ans; +}; +var componentTestsAnyOf = (src, ctx) => { + const ans = { + type: "mcfunction:component_tests_any_of", + range: Range.create(src), + children: [] + }; + while (src.canRead()) { + src.skipWhitespace(); + const allOfNode = componentTestsAllOf(src, ctx); + ans.children.push(allOfNode); + src.skipWhitespace(); + if (src.peek() === "|") { + src.skip(); + } else if (src.peek() === "]") { + break; + } else { + ctx.err.report(localize("expected", localeQuote("]")), src); + src.skipUntilOrEnd("|", "]"); + } + } + ans.range.end = src.cursor; + return ans; +}; +var componentTests2 = (src, ctx) => { + const ans = { + type: "mcfunction:component_tests", + range: Range.create(src) + }; + if (!src.trySkip("[")) { + return Failure; + } + src.skipWhitespace(); + const tests = optional(failOnEmpty(componentTestsAnyOf))(src, ctx); + if (tests) { + ans.children = [tests]; + } + src.skipWhitespace(); + literal("]")(src, ctx); + ans.range.end = src.cursor; + return ans; +}; + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/mcdocAttributes.js +var validator3 = runtime_exports.attribute.validator; +var commandValidator = validator3.alternatives(validator3.tree({ + slash: validator3.optional(validator3.options("allowed", "required", "chat")), + macro: validator3.optional(validator3.options("implicit")), + max_length: validator3.optional(validator3.number), + empty: validator3.optional(validator3.options("allowed")), + incomplete: validator3.optional(validator3.options("allowed")) +}), () => ({})); +var entityValidator = validator3.alternatives(validator3.tree({ + amount: validator3.options("multiple", "single"), + type: validator3.options("entities", "players") +}), () => ({ amount: "multiple", type: "entities" })); +var scoreHolderValidator = validator3.alternatives(validator3.tree({ + amount: validator3.options("multiple", "single") +}), () => ({ amount: "multiple" })); +function registerMcdocAttributes4(meta, rootTreeNode) { + runtime_exports.registerAttribute(meta, "command", commandValidator, { + // TODO: fix completer inside commands + stringParser: ({ slash, macro: macro3, max_length, empty, incomplete }) => { + return (src, ctx) => { + if (macro3) { + return macro2(false)(src, ctx); + } + if (empty && !src.canRead() || slash === "chat" && src.peek() !== "/") { + return string4({ + unquotable: { blockList: /* @__PURE__ */ new Set(), allowEmpty: true } + })(src, ctx); + } + const tmpCtx = { ...ctx, err: new ErrorReporter(ctx.err.source) }; + const result = command2(rootTreeNode, argument, { + slash: slash === "chat" ? "allowed" : slash, + maxLength: max_length + })(src, tmpCtx); + if (incomplete) { + tmpCtx.err.errors = tmpCtx.err.errors.filter((e) => e.range.end < result.range.end); + } + ctx.err.absorb(tmpCtx.err); + return result; + }; + } + }); + runtime_exports.registerAttribute(meta, "text_component", () => void 0, { + stringParser: () => makeInfallible2(map(parser_exports2.entry, (res) => ({ + type: "json:typed", + range: res.range, + children: [res], + targetType: { kind: "reference", path: "::java::server::util::text::Text" } + })), localize("text-component")) + }); + runtime_exports.registerAttribute(meta, "objective", () => void 0, { + stringParser: () => objective("reference"), + stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "objective" }) + }); + runtime_exports.registerAttribute(meta, "team", () => void 0, { + stringParser: () => team("reference"), + stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "team" }) + }); + runtime_exports.registerAttribute(meta, "score_holder", scoreHolderValidator, { + stringParser: (config) => makeInfallible2(scoreHolder2("reference", config.amount), localize("score-holder")), + stringMocker: (_, __, ctx) => ScoreHolderNode.mock(ctx.offset) + }); + runtime_exports.registerAttribute(meta, "tag", () => void 0, { + stringParser: () => tag("reference"), + stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "tag" }) + }); + runtime_exports.registerAttribute(meta, "block_predicate", () => void 0, { + stringParser: () => blockPredicate, + stringMocker: (_, __, ctx) => BlockNode.mock(ctx.offset, true) + }); + runtime_exports.registerAttribute(meta, "entity", entityValidator, { + stringParser: (config) => makeInfallible2(entity2(config.amount, config.type), localize("selector")), + stringMocker: (_, __, ctx) => EntitySelectorNode.mock(ctx.offset, { + pool: EntitySelectorAtVariable.filterAvailable(ctx) + }) + }); + runtime_exports.registerAttribute(meta, "item_slots", () => void 0, { + stringParser: (_, __, ctx) => literal({ pool: getItemSlotsArgumentValues(ctx) }), + stringMocker: (_, __, ctx) => LiteralNode.mock(ctx.offset, { pool: getItemSlotsArgumentValues(ctx) }) + }); + runtime_exports.registerAttribute(meta, "uuid", () => void 0, { + stringParser: () => uuid + }); +} +function makeInfallible2(parser, message2) { + return (src, ctx) => { + const start = src.cursor; + const res = parser(src, ctx); + if (res === Failure) { + ctx.err.report(localize("expected", message2), Range.create(start, src.skipRemaining())); + return void 0; + } + return res; + }; +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/signatureHelpProvider.js +function signatureHelpProvider(rootTreeNode) { + return (fileNode, ctx) => { + if (fileNode.children[0]?.type !== "mcfunction:entry") { + return void 0; + } + const node = getSelectedCommandNode(fileNode, ctx.offset); + if (!CommandNode.is(node)) { + return void 0; + } + const argumentNodes = node ? node.children : []; + const options2 = getOptions3(rootTreeNode, argumentNodes); + if (options2.length === 0) { + return void 0; + } + let selectedIndex = 0; + for (const child of argumentNodes) { + if (ctx.offset > child.range.end) { + selectedIndex += 1; + } else { + break; + } + } + if (selectedIndex >= options2[0].length) { + return void 0; + } + const ans = { activeSignature: 0, signatures: [] }; + ans.signatures = options2.map((v) => { + const part1 = v[selectedIndex]; + const part2 = selectedIndex + 1 < v.length ? ` ${v[selectedIndex + 1]}` : ""; + const label = `${part1}${part2}`; + return { + label, + activeParameter: 0, + // documentation: localize('mcfunction.signature-help.command-documentation', v[0]), + parameters: [{ label: [0, part1.length] }, { label: [part1.length, label.length] }] + }; + }); + return ans; + }; +} +function getSelectedCommandNode(fileNode, offset) { + return AstNode.findChild(fileNode.children[0], offset, true); +} +function getOptions3(rootTreeNode, argumentNodes) { + const current = []; + let treeNode = rootTreeNode; + for (const argumentNode of argumentNodes) { + const name = argumentNode.path[argumentNode.path.length - 1]; + if (!name) { + break; + } + treeNode = resolveParentTreeNode(treeNode, rootTreeNode).treeNode?.children?.[name]; + if (!treeNode) { + break; + } + current.push(treeNodeToString(name, treeNode)); + } + if (treeNode) { + treeNode = resolveParentTreeNode(treeNode, rootTreeNode).treeNode; + if (treeNode?.children) { + return treeNodeChildrenToStringArray(treeNode.children, treeNode.executable).map((v) => [...current, v]); + } + } + return current.length ? [current] : []; +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/tree/patch.js +function getPatch(release) { + return { + children: { + advancement: { + children: { + grant: AdvancementTargets, + revoke: AdvancementTargets + } + }, + ...ReleaseVersion.cmp(release, "1.16") >= 0 ? { + attribute: { + children: { + target: { + children: { + attribute: { + properties: { + category: "attribute" + }, + children: { + modifier: { + children: { + add: { + children: { + id: { + properties: { + category: "attribute_modifier" + } + }, + uuid: { + properties: { + category: "attribute_modifier_uuid" + } + } + } + }, + remove: { + children: { + id: { + properties: { + category: "attribute_modifier" + } + }, + uuid: { + properties: { + category: "attribute_modifier_uuid" + } + } + } + }, + value: { + children: { + get: { + children: { + id: { + properties: { + category: "attribute_modifier" + } + }, + uuid: { + properties: { + category: "attribute_modifier_uuid" + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } : {}, + ban: { + permission: 3 + }, + "ban-ip": { + permission: 3 + }, + banlist: { + permission: 3 + }, + bossbar: { + children: { + add: { + children: { + id: { + properties: { + category: "bossbar", + usageType: "definition" + } + } + } + }, + get: { + children: { + id: { + properties: { + category: "bossbar" + } + } + } + }, + remove: { + children: { + id: { + properties: { + category: "bossbar" + } + } + } + }, + set: { + children: { + id: { + properties: { + category: "bossbar", + accessType: 1 + } + } + } + } + } + }, + data: { + children: { + get: getDataPatch("target", "path"), + merge: getDataPatch("target", "nbt", { + isMerge: true, + vaultAccessType: 1 + }), + modify: getDataPatch("target", "targetPath", { + nbtAccessType: 1, + vaultAccessType: 1, + children: (type2) => ({ + append: getDataModifySource(type2, { + isListIndex: true + }), + insert: { + children: { + index: getDataModifySource(type2, { + isListIndex: true + }) + } + }, + merge: getDataModifySource(type2, { + isMerge: true + }), + prepend: getDataModifySource(type2, { + isListIndex: true + }), + set: getDataModifySource(type2) + }) + }), + remove: getDataPatch("target", "path", { + nbtAccessType: 1, + vaultAccessType: 1 + }) + } + }, + datapack: { + children: { + ...ReleaseVersion.cmp(release, "1.21.6") >= 0 ? { + // Added in 21w15a (1.21.6, pack format 72) + create: { + permission: 4 + } + } : {} + } + }, + debug: { + permission: 3 + }, + deop: { + permission: 3 + }, + execute: { + children: { + if: ExecuteCondition, + store: { + children: { + result: ExecuteStoreTarget, + success: ExecuteStoreTarget + } + }, + unless: ExecuteCondition + } + }, + ...ReleaseVersion.cmp(release, "1.21.9") >= 0 ? { + fetchprofile: { + children: { + id: { + children: { + id: { + properties: { + category: "player_uuid" + } + } + } + } + } + } + } : {}, + function: { + children: { + name: { + ...ReleaseVersion.cmp(release, "1.20.2") >= 0 ? { + children: { + // Added in 23w31a (1.20.2, pack format 16) + arguments: { + properties: { + dispatcher: "minecraft:macro_function", + dispatchedBy: "name" + } + }, + with: getDataPatch("source", "path") + } + } : {} + } + } + }, + ...ReleaseVersion.cmp(release, "1.17") >= 0 ? { + // Added in 20w46a (1.17, pack format 7) + item: { + children: { + replace: { + children: { + block: { + children: { + pos: { + children: { + slot: { + children: { + from: { + children: { + block: { + children: { + source: { + children: { + sourceSlot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + }, + entity: { + children: { + source: { + children: { + sourceSlot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + }, + entity: { + children: { + targets: { + children: { + slot: { + children: { + from: { + children: { + block: { + children: { + source: { + children: { + sourceSlot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + }, + entity: { + children: { + source: { + children: { + sourceSlot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + }, + modify: { + children: { + block: { + children: { + pos: { + children: { + slot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + }, + entity: { + children: { + targets: { + children: { + slot: { + children: { + modifier: { + properties: { + category: "item_modifier" + } + } + } + } + } + } + } + } + } + } + } + } + } : {}, + help: { + permission: 0 + }, + ...ReleaseVersion.cmp(release, "1.18") >= 0 ? { + // Added in 21w37a (1.18, pack format 8) + jfr: { + permission: 4 + } + } : {}, + kick: { + permission: 3 + }, + list: { + permission: 0 + }, + ...ReleaseVersion.isBetween(release, "1.16", "1.19") ? { + // Added in 20w06a (1.16, pack format 5) + // Removed in 22w19a (1.19, pack format 10) + locatebiome: { + children: { + biome: { + properties: { + category: "worldgen/biome", + // Allowed in 1.18.2-pre1 (1.18.2, pack format 9) + allowTag: ReleaseVersion.cmp(release, "1.18.2") >= 0 + } + } + } + } + } : {}, + loot: { + children: { + give: { + children: { + players: LootSource + } + }, + insert: { + children: { + targetPos: LootSource + } + }, + replace: { + children: { + block: { + children: { + targetPos: { + children: { + slot: { + children: { + ...LootSource.children, + count: LootSource + } + } + } + } + } + }, + entity: { + children: { + entities: { + children: { + slot: { + children: { + ...LootSource.children, + count: LootSource + } + } + } + } + } + } + } + }, + spawn: { + children: { + targetPos: LootSource + } + } + } + }, + me: { + permission: 0 + }, + msg: { + permission: 0 + }, + op: { + permission: 3 + }, + pardon: { + permission: 3 + }, + "pardon-ip": { + permission: 3 + }, + ...ReleaseVersion.cmp(release, "1.17") >= 0 ? { + // Added in 1.17 Pre-release 1 (1.17, pack format 7) + perf: { + permission: 4 + } + } : {}, + ...ReleaseVersion.cmp(release, "1.19") >= 0 ? { + // Added in 22w18a (1.19, pack format 10) + place: { + children: { + jigsaw: { + children: { + pool: { + children: { + target: { + properties: { + category: "jigsaw_block_name", + allowUnknown: true + } + } + } + } + } + }, + template: { + children: { + template: { + properties: { + category: "structure" + } + } + } + } + } + } + } : {}, + playsound: Sound, + publish: { + permission: 4 + }, + ...ReleaseVersion.cmp(release, "1.20.2") >= 0 ? { + // Added in 23w31a (1.20.2, pack format 16) + random: { + children: { + reset: { + children: { + sequence: { + properties: { + category: "random_sequence", + allowUnknown: true + } + } + } + }, + roll: { + children: { + range: { + properties: { + minSpan: 1, + maxSpan: 2147483646 + }, + children: { + sequence: { + properties: { + category: "random_sequence", + allowUnknown: true + } + } + } + } + } + }, + value: { + children: { + range: { + properties: { + minSpan: 1, + maxSpan: 2147483646 + }, + children: { + sequence: { + properties: { + category: "random_sequence", + allowUnknown: true + } + } + } + } + } + } + } + } + } : {}, + recipe: { + children: { + give: RecipeTargets, + take: RecipeTargets + } + }, + "save-all": { + permission: 4 + }, + "save-off": { + permission: 4 + }, + "save-on": { + permission: 4 + }, + schedule: { + children: { + clear: { + children: { + function: { + parser: "minecraft:function", + properties: void 0 + } + } + } + } + }, + scoreboard: { + children: { + objectives: { + children: { + add: { + children: { + objective: { + parser: "minecraft:objective", + properties: { + usageType: "definition" + } + } + } + } + } + }, + players: { + children: { + add: ObjectiveWriteTargets, + operation: ObjectiveWriteTargets, + remove: ObjectiveWriteTargets, + reset: ObjectiveWriteTargets, + set: ObjectiveWriteTargets + } + } + } + }, + setidletimeout: { + permission: 3 + }, + stop: { + permission: 4 + }, + stopsound: { + children: { + targets: { + children: { + "*": Sound, + ambient: Sound, + block: Sound, + hostile: Sound, + master: Sound, + music: Sound, + neutral: Sound, + player: Sound, + record: Sound, + ...ReleaseVersion.cmp(release, "1.21.9") >= 0 ? { + ui: Sound + } : {}, + voice: Sound, + weather: Sound + } + } + } + }, + ...ReleaseVersion.cmp(release, "1.21.11") >= 0 ? { + stopwatch: { + children: { + create: { + children: { + id: { + properties: { + category: "stopwatch", + usageType: "definition" + } + } + } + }, + query: { + children: { + id: { + properties: { + category: "stopwatch" + } + } + } + }, + remove: { + children: { + id: { + properties: { + category: "stopwatch" + } + } + } + }, + restart: { + children: { + id: { + properties: { + category: "stopwatch" + } + } + } + } + } + } + } : {}, + summon: { + children: { + entity: { + children: { + pos: { + children: { + nbt: { + properties: { + dispatcher: "minecraft:entity", + dispatchedBy: "entity" + } + } + } + } + } + } + } + }, + tag: { + children: { + targets: { + children: { + add: { + children: { + name: { + parser: "spyglassmc:tag" + } + } + }, + remove: { + children: { + name: { + parser: "spyglassmc:tag" + } + } + } + } + } + } + }, + team: { + children: { + add: { + children: { + team: { + parser: "minecraft:team", + properties: { + usageType: "definition" + } + } + } + } + } + }, + teammsg: { + permission: 0 + }, + /** + * Original command syntax: + * 1. `teleport ` + * 2. `teleport ` + * 3. `teleport <...arguments>` + * + * It is impossible for Spyglass to differentiate between (1) and (3) when it encounters a single entity + * at the position of the first argument, due to its lack of ability to backtrack. + * + * Therefore, we have compromised to patch the trees to something like this: + * - `teleport ` + * - `teleport [<...arguments>]` + * + * Diff: + * - Removed (1) `teleport `. + * - Marked `<...arguments>` in (3) as optional. + * + * The downside of this patch is that entity selectors tracking multiple entities can now be used as the + * `` argument. We will see how this work. + */ + teleport: { + children: { + destination: void 0, + targets: { + executable: true + } + } + }, + tell: { + permission: 0 + }, + ...ReleaseVersion.cmp(release, "1.21.5") >= 0 ? { + test: { + children: { + create: { + children: { + id: { + properties: { + category: "test_instance", + allowUnknown: true + } + } + } + } + } + } + } : {}, + ...ReleaseVersion.cmp(release, "1.20.3") >= 0 ? { + // Added in 23w43a (1.20.3, pack format 22) + tick: { + permission: 3 + } + } : {}, + tm: { + permission: 0 + }, + ...ReleaseVersion.cmp(release, "1.20.5") >= 0 ? { + // Added in 24w04a (1.20.5, pack format 29) + transfer: { + permission: 3 + } + } : {}, + trigger: { + permission: 0, + children: { + objective: { + properties: { + category: "objective", + accessType: 1 + } + } + } + }, + w: { + permission: 0 + }, + ...ReleaseVersion.cmp(release, "1.21.6") >= 0 ? { + waypoint: { + children: { + modify: { + children: { + waypoint: { + children: { + style: { + children: { + set: { + children: { + style: { + properties: { + category: "waypoint_style" + } + } + } + } + } + } + } + } + } + } + } + } + } : {}, + whitelist: { + permission: 3 + } + } + }; +} +var AdvancementTargets = Object.freeze({ + children: { + targets: { + children: { + from: { + children: { + advancement: { + properties: { + category: "advancement" + } + } + } + }, + only: { + children: { + advancement: { + properties: { + category: "advancement" + }, + children: { + criterion: { + parser: "spyglassmc:criterion", + properties: { + usageType: "reference" + } + } + } + } + } + }, + through: { + children: { + advancement: { + properties: { + category: "advancement" + } + } + } + }, + until: { + children: { + advancement: { + properties: { + category: "advancement" + } + } + } + } + } + } + } +}); +function getDataPatch(vaultKey, nbtKey, { children, isPredicate = false, isMerge = false, nbtAccessType = 0, vaultAccessType = 0 } = {}) { + return Object.freeze({ + children: { + block: { + children: { + [`${vaultKey}Pos`]: { + children: { + [nbtKey]: { + properties: { + dispatcher: "minecraft:block", + dispatchedBy: `${vaultKey}Pos`, + accessType: nbtAccessType, + isPredicate, + isMerge + }, + ...children ? { children: children("block") } : {} + } + } + } + } + }, + entity: { + children: { + [vaultKey]: { + children: { + [nbtKey]: { + properties: { + dispatcher: "minecraft:entity", + dispatchedBy: vaultKey, + accessType: nbtAccessType, + isPredicate, + isMerge + }, + ...children ? { children: children("entity") } : {} + } + } + } + } + }, + storage: { + children: { + [vaultKey]: { + properties: { + category: "storage", + accessType: vaultAccessType, + usageType: "definition" + }, + children: { + [nbtKey]: { + properties: { + dispatcher: "minecraft:storage", + dispatchedBy: vaultKey, + accessType: nbtAccessType, + isPredicate, + isMerge + }, + ...children ? { children: children("storage") } : {} + } + } + } + } + } + } + }); +} +var getDataModifySource = (type2, { isMerge = false, isListIndex = false } = {}) => Object.freeze({ + children: { + from: getDataPatch("source", "sourcePath"), + string: getDataPatch("source", "sourcePath"), + value: { + children: { + value: { + properties: { + dispatcher: `minecraft:${type2}`, + dispatchedBy: type2 === "block" ? "targetPos" : "target", + indexedBy: "targetPath", + isMerge, + isListIndex + } + } + } + } + } +}); +var ExecuteCondition = Object.freeze({ + children: { + data: getDataPatch("source", "path", { + isPredicate: true + }), + predicate: { + children: { + predicate: { + properties: { + category: "predicate" + } + } + } + }, + stopwatch: { + children: { + id: { + properties: { + category: "stopwatch" + } + } + } + } + } +}); +var ExecuteStoreTarget = Object.freeze({ + children: { + ...getDataPatch("target", "path", { + nbtAccessType: 1, + vaultAccessType: 1 + }).children, + bossbar: { + children: { + id: { + properties: { + category: "bossbar", + accessType: 1 + } + } + } + }, + score: { + children: { + targets: { + properties: { + usageType: "definition" + }, + children: { + objective: { + properties: { + accessType: 1 + } + } + } + } + } + } + } +}); +var LootSource = Object.freeze({ + children: { + fish: { + children: { + loot_table: { + properties: { + category: "loot_table" + } + } + } + }, + loot: { + children: { + loot_table: { + properties: { + category: "loot_table" + } + } + } + } + } +}); +var ObjectiveWriteTargets = Object.freeze({ + children: { + targets: { + properties: { + usageType: "definition" + }, + children: { + objective: { + properties: { + accessType: 1 + } + } + } + } + } +}); +var RecipeTargets = Object.freeze({ + children: { + targets: { + children: { + recipe: { + properties: { + category: "recipe" + } + } + } + } + } +}); +var Sound = Object.freeze({ + children: { + sound: { + properties: { + category: "sound_event" + } + } + } +}); + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/tree/patchValidator.js +var PatchRequiredParsers = /* @__PURE__ */ new Set([ + "minecraft:nbt_compound_tag", + "minecraft:nbt_path", + "minecraft:nbt_tag", + "minecraft:resource_location", + "minecraft:uuid" +]); +function validatePatchedTree(tree2, logger) { + walk(tree2, []); + function walk(node, path6) { + if (node.type === "argument" && PatchRequiredParsers.has(node.parser) && !node.properties) { + logger.warn(`[validatePatchedTree] Patch required: ${node.parser} at ${path6.join(".")}`); + } + for (const [key2, value] of Object.entries(node.children ?? {})) { + walk(value, [...path6, key2]); + } + } +} + +// node_modules/@spyglassmc/java-edition/lib/mcfunction/index.js +var initialize5 = (ctx, commands, releaseVersion) => { + const { meta } = ctx; + registerCustomResources(ctx.config); + const tree2 = merge(commands, getPatch(releaseVersion)); + if (ctx.isDebugging) { + validatePatchedTree(tree2, ctx.logger); + } + initialize4(ctx); + const mcfunctionOptions = { + lineContinuation: ReleaseVersion.cmp(releaseVersion, "1.20.2") >= 0, + macros: ReleaseVersion.cmp(releaseVersion, "1.20.2") >= 0, + commandOptions: ReleaseVersion.cmp(releaseVersion, "1.20.5") >= 0 ? { maxLength: 2e6 } : {} + }; + meta.registerLanguage("mcfunction", { + extensions: [".mcfunction"], + parser: entry4(tree2, argument, mcfunctionOptions), + completer: completer_exports5.entry(tree2, getMockNodes), + triggerCharacters: [" ", "[", "=", "!", ",", "{", ":", "/", ".", '"', "'"] + }); + meta.registerParser("mcfunction:block_predicate", blockPredicate); + meta.registerParser("mcfunction:particle", particle3); + meta.registerParser("mcfunction:tag", tag()); + meta.registerParser("mcfunction:team", team()); + meta.registerParser("mcfunction:command", command2(tree2, argument)); + registerMcdocAttributes4(meta, tree2); + register12(meta); + register13(meta); + register14(meta); + meta.registerInlayHintProvider(inlayHintProvider); + meta.registerSignatureHelpProvider(signatureHelpProvider(tree2)); +}; + +// node_modules/@spyglassmc/java-edition/lib/index.js +var initialize6 = async (ctx) => { + const { config, externals, logger, meta, projectRoots } = ctx; + async function readPackFormat(uri) { + try { + const data = await fileUtil.readJson(externals, uri); + return PackMcmeta.readPackFormat(data); + } catch (e) { + if (!externals.error.isKind(e, "ENOENT")) { + logger.error(`[je.initialize] Failed loading pack.mcmeta ${uri}`, e); + } + } + return void 0; + } + async function findPackMcmetas() { + const searchedUris = /* @__PURE__ */ new Set(); + const packs2 = []; + for (let depth = 0; depth <= 2; depth += 1) { + for (const projectRoot of projectRoots) { + const files = await fileUtil.getAllFiles(externals, projectRoot, depth + 1); + for (const uri of files.filter((uri2) => uri2.endsWith("/pack.mcmeta"))) { + if (searchedUris.has(uri)) { + continue; + } + searchedUris.add(uri); + const packRoot = fileUtil.dirname(uri); + const [format, type2] = await Promise.all([ + readPackFormat(uri), + PackMcmeta.getType(packRoot, externals) + ]); + if (format !== void 0) { + packs2.push({ type: type2, packRoot, format }); + } + } + } + } + return packs2; + } + meta.registerUriBinder(uriBinder2); + registerUriBuilders(meta); + const [versions, packs] = await Promise.all([ + getVersions(externals, logger), + findPackMcmetas() + ]); + if (!versions) { + ctx.logger.error("[je-initialize] Failed loading game version list. Expect everything to be broken."); + return; + } + const version = resolveConfiguredVersion(config.env.gameVersion, versions, packs, logger); + const release = version.release; + meta.registerDependencyProvider("@vanilla-datapack", () => getVanillaDatapack(externals, logger, version.id)); + meta.registerDependencyProvider("@vanilla-resourcepack", () => getVanillaResourcepack(externals, logger, version.id)); + meta.registerDependencyProvider("@vanilla-mcdoc", () => getVanillaMcdoc(externals, logger)); + const summary = await getMcmetaSummary(ctx.externals, logger, version.id, config.env.mcmetaSummaryOverrides); + if (!summary.blocks || !summary.commands || !summary.fluids || !summary.registries) { + ctx.logger.error("[je-initialize] Failed loading mcmeta summaries. Expect everything to be broken."); + return; + } + meta.registerSymbolRegistrar("mcmeta-summary", { + checksum: `${summary.checksum}-v4`, + registrar: symbolRegistrar(summary, release) + }); + meta.registerLinter("nameOfNbtKey", { + configValidator: builtin_exports7.configValidator.nameConvention, + linter: builtin_exports7.nameConvention("value"), + nodePredicate: (n) => ( + // nbt compound keys without mcdoc definition. + !n.symbol && n.parent?.parent?.type === "nbt:compound" && PairNode.is(n.parent) && n.type === "string" && n.parent.key === n || !n.symbol && n.parent?.type === "nbt:path" && n.type === "string" || StructFieldNode.is(n.parent) && StructKeyNode.is(n) && !n.symbol?.path[0]?.startsWith("::minecraft") + ) + }); + registerMcdocAttributes3(meta, summary.commands, release); + registerPackFormatAttribute(meta, versions, packs); + meta.registerLanguage("zip", { extensions: [".zip"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("png", { extensions: [".png"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("ogg", { extensions: [".ogg"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("ttf", { extensions: [".ttf"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("otf", { extensions: [".otf"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("fsh", { extensions: [".fsh"], uriPredicate: jeFileUriPredicate }); + meta.registerLanguage("vsh", { extensions: [".vsh"], uriPredicate: jeFileUriPredicate }); + getInitializer(jeFileUriPredicate)(ctx); + initialize3(ctx); + initialize5(ctx, summary.commands, release); + initialize2(ctx); + return { loadedVersion: release, errorSource: release }; +}; + +// mcs-spyglass-validate.mjs +function parseArgs(argv) { + const flags = { + json: false, + mcVersion: null + }; + const positional = []; + for (let index4 = 0; index4 < argv.length; index4 += 1) { + const arg = argv[index4]; + if (arg === "--json") { + flags.json = true; + continue; + } + if (arg === "--mc-version") { + flags.mcVersion = argv[index4 + 1]; + index4 += 1; + continue; + } + if (arg.startsWith("--mc-version=")) { + flags.mcVersion = arg.slice("--mc-version=".length); + continue; + } + positional.push(arg); + } + if (positional.length < 1) { + throw new Error("Usage: node mcs-spyglass-validate.js [--json] [--mc-version ] "); + } + return { flags, datapackDir: (0, import_node_path.resolve)(positional[0]) }; +} +function toRootUri(path6) { + const normalized = (0, import_node_path.resolve)(path6).replace(/\\/g, "/"); + return (0, import_node_url2.pathToFileURL)(`${normalized}/`).href; +} +function severityName(severity) { + switch (severity) { + case ErrorSeverity.Hint: + return "hint"; + case ErrorSeverity.Information: + return "information"; + case ErrorSeverity.Warning: + return "warning"; + case ErrorSeverity.Error: + return "error"; + default: + return "error"; + } +} +function walkFiles(rootDir) { + const files = []; + const stack = [rootDir]; + while (stack.length > 0) { + const current = stack.pop(); + for (const entry6 of (0, import_node_fs2.readdirSync)(current)) { + const fullPath = (0, import_node_path.join)(current, entry6); + const stats = (0, import_node_fs2.statSync)(fullPath); + if (stats.isDirectory()) { + stack.push(fullPath); + continue; + } + files.push(fullPath); + } + } + return files; +} +function languageIdFor(path6) { + if (path6.endsWith(".mcfunction")) return "mcfunction"; + if (path6.endsWith(".json")) return "json"; + if (path6.endsWith(".nbt")) return "nbt"; + return null; +} +async function main() { + const { flags, datapackDir } = parseArgs(process.argv.slice(2)); + const packMetaPath = (0, import_node_path.join)(datapackDir, "pack.mcmeta"); + if (!(0, import_node_fs2.statSync)(datapackDir).isDirectory() || !(0, import_node_fs2.statSync)(packMetaPath).isFile()) { + throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`); + } + const cacheDir = (0, import_node_fs2.mkdtempSync)((0, import_node_path.join)((0, import_node_os2.tmpdir)(), "mcs-spyglass-")); + const cacheRoot = toRootUri(cacheDir); + (0, import_node_fs2.mkdirSync)(new URL(cacheRoot), { recursive: true }); + const projectRoot = toRootUri(datapackDir); + const gameVersion = flags.mcVersion; + const diagnostics = []; + try { + const project = new Project({ + cacheRoot, + defaultConfig: { + ...VanillaConfig, + env: { + ...VanillaConfig.env, + ...gameVersion ? { gameVersion } : {} + } + }, + externals: getNodeJsExternals({ cacheRoot }), + initializers: [initialize, initialize6], + isDebugging: false, + logger: Logger.create("warn"), + projectRoots: [projectRoot] + }); + project.on("documentErrored", ({ uri, errors }) => { + for (const error4 of errors) { + const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, "$1")); + const relativePath = (0, import_node_path.relative)(datapackDir, filePath).replace(/\\/g, "/"); + const start = error4.posRange?.start; + diagnostics.push({ + file: relativePath, + line: (start?.line ?? 0) + 1, + column: (start?.character ?? 0) + 1, + message: error4.message, + severity: severityName(error4.severity) + }); + } + }); + await project.init(); + await project.ready(); + for (const filePath of walkFiles(datapackDir)) { + const languageId = languageIdFor(filePath); + if (!languageId) continue; + const uri = (0, import_node_url2.pathToFileURL)(filePath).href; + const content = (0, import_node_fs2.readFileSync)(filePath, "utf8"); + await project.onDidOpen(uri, languageId, 1, content); + const managed = await project.ensureClientManagedChecked(uri); + if (!managed) continue; + for (const error4 of FileNode.getErrors(managed.node)) { + diagnostics.push({ + file: (0, import_node_path.relative)(datapackDir, filePath).replace(/\\/g, "/"), + line: error4.range.start.line + 1, + column: error4.range.start.character + 1, + message: error4.message, + severity: severityName(error4.severity) + }); + } + } + await project.close(); + } finally { + (0, import_node_fs2.rmSync)(cacheDir, { recursive: true, force: true }); + } + const unique = /* @__PURE__ */ new Map(); + for (const diagnostic of diagnostics) { + const key2 = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}`; + unique.set(key2, diagnostic); + } + const result = [...unique.values()].sort((left, right) => { + if (left.file !== right.file) return left.file.localeCompare(right.file); + if (left.line !== right.line) return left.line - right.line; + return left.column - right.column; + }); + if (flags.json) { + process.stdout.write(`${JSON.stringify(result)} +`); + } else { + for (const diagnostic of result) { + process.stdout.write( + `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}: ${diagnostic.message} +` + ); + } + } + const hasErrors = result.some((diagnostic) => diagnostic.severity === "error"); + process.exitCode = hasErrors ? 1 : 0; +} +main().catch((error4) => { + const message2 = error4 instanceof Error ? error4.stack ?? error4.message : String(error4); + if (process.argv.includes("--json")) { + process.stdout.write(`${JSON.stringify([{ file: "", line: 0, column: 0, message: message2, severity: "error" }])} +`); + } else { + process.stderr.write(`${message2} +`); + } + process.exitCode = 1; +}); +/*! Bundled license information: + +safe-buffer/index.js: + (*! safe-buffer. MIT License. Feross Aboukhadijeh *) + +object-assign/index.js: + (* + object-assign + (c) Sindre Sorhus + @license MIT + *) + +is-natural-number/index.js: + (*! + * is-natural-number.js | MIT (c) Shinnosuke Watanabe + * https://github.com/shinnn/is-natural-number.js + *) + +strip-dirs/index.js: + (*! + * strip-dirs | MIT (c) Shinnosuke Watanabe + * https://github.com/shinnn/node-strip-dirs + *) +*/ diff --git a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs deleted file mode 100644 index 4a864b6..0000000 --- a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.mjs +++ /dev/null @@ -1,199 +0,0 @@ -#!/usr/bin/env node -import { mkdirSync } from 'node:fs' -import { mkdtempSync } from 'node:fs' -import { readFileSync } from 'node:fs' -import { readdirSync, statSync } from 'node:fs' -import { join, relative, resolve } from 'node:path' -import { tmpdir } from 'node:os' -import { pathToFileURL } from 'node:url' - -import { - ErrorSeverity, - FileNode, - Logger, - Project, - VanillaConfig, -} from '@spyglassmc/core' -import { getNodeJsExternals } from '@spyglassmc/core/lib/nodejs.js' -import { initialize as initializeJavaEdition } from '@spyglassmc/java-edition' -import { initialize as initializeMcdoc } from '@spyglassmc/mcdoc' - -function parseArgs(argv) { - const flags = { - json: false, - mcVersion: null, - } - const positional = [] - - for (let index = 0; index < argv.length; index += 1) { - const arg = argv[index] - if (arg === '--json') { - flags.json = true - continue - } - if (arg === '--mc-version') { - flags.mcVersion = argv[index + 1] - index += 1 - continue - } - if (arg.startsWith('--mc-version=')) { - flags.mcVersion = arg.slice('--mc-version='.length) - continue - } - positional.push(arg) - } - - if (positional.length < 1) { - throw new Error('Usage: node mcs-spyglass-validate.mjs [--json] [--mc-version ] ') - } - - return { flags, datapackDir: resolve(positional[0]) } -} - -function toRootUri(path) { - const normalized = resolve(path).replace(/\\/g, '/') - return pathToFileURL(`${normalized}/`).href -} - -function severityName(severity) { - switch (severity) { - case ErrorSeverity.Hint: - return 'hint' - case ErrorSeverity.Information: - return 'information' - case ErrorSeverity.Warning: - return 'warning' - case ErrorSeverity.Error: - return 'error' - default: - return 'error' - } -} - -function walkFiles(rootDir) { - const files = [] - const stack = [rootDir] - while (stack.length > 0) { - const current = stack.pop() - for (const entry of readdirSync(current)) { - const fullPath = join(current, entry) - const stats = statSync(fullPath) - if (stats.isDirectory()) { - stack.push(fullPath) - continue - } - files.push(fullPath) - } - } - return files -} - -function languageIdFor(path) { - if (path.endsWith('.mcfunction')) return 'mcfunction' - if (path.endsWith('.json')) return 'json' - if (path.endsWith('.nbt')) return 'nbt' - return null -} - -async function main() { - const { flags, datapackDir } = parseArgs(process.argv.slice(2)) - const packMetaPath = join(datapackDir, 'pack.mcmeta') - if (!statSync(datapackDir).isDirectory() || !statSync(packMetaPath).isFile()) { - throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`) - } - - const cacheRoot = toRootUri(mkdtempSync(join(tmpdir(), 'mcs-spyglass-'))) - mkdirSync(new URL(cacheRoot), { recursive: true }) - const projectRoot = toRootUri(datapackDir) - const gameVersion = flags.mcVersion - const diagnostics = [] - - const project = new Project({ - cacheRoot, - defaultConfig: { - ...VanillaConfig, - env: { - ...VanillaConfig.env, - ...(gameVersion ? { gameVersion } : {}), - }, - }, - externals: getNodeJsExternals({ cacheRoot }), - initializers: [initializeMcdoc, initializeJavaEdition], - isDebugging: false, - logger: Logger.create('warn'), - projectRoots: [projectRoot], - }) - - project.on('documentErrored', ({ uri, errors }) => { - for (const error of errors) { - const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, '$1')) - const relativePath = relative(datapackDir, filePath).replace(/\\/g, '/') - const start = error.posRange?.start - diagnostics.push({ - file: relativePath, - line: (start?.line ?? 0) + 1, - column: (start?.character ?? 0) + 1, - message: error.message, - severity: severityName(error.severity), - }) - } - }) - - await project.init() - await project.ready() - - for (const filePath of walkFiles(datapackDir)) { - const languageId = languageIdFor(filePath) - if (!languageId) continue - const uri = pathToFileURL(filePath).href - const content = readFileSync(filePath, 'utf8') - await project.onDidOpen(uri, languageId, 1, content) - const managed = await project.ensureClientManagedChecked(uri) - if (!managed) continue - for (const error of FileNode.getErrors(managed.node)) { - diagnostics.push({ - file: relative(datapackDir, filePath).replace(/\\/g, '/'), - line: error.range.start.line + 1, - column: error.range.start.character + 1, - message: error.message, - severity: severityName(error.severity), - }) - } - } - - await project.close() - - const unique = new Map() - for (const diagnostic of diagnostics) { - const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}` - unique.set(key, diagnostic) - } - const result = [...unique.values()].sort((left, right) => { - if (left.file !== right.file) return left.file.localeCompare(right.file) - if (left.line !== right.line) return left.line - right.line - return left.column - right.column - }) - - if (flags.json) { - process.stdout.write(`${JSON.stringify(result)}\n`) - } else { - for (const diagnostic of result) { - process.stdout.write( - `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}: ${diagnostic.message}\n`, - ) - } - } - - const hasErrors = result.some((diagnostic) => diagnostic.severity === 'error') - process.exit(hasErrors ? 1 : 0) -} - -main().catch((error) => { - const message = error instanceof Error ? error.stack ?? error.message : String(error) - if (process.argv.includes('--json')) { - process.stdout.write(`${JSON.stringify([{ file: '', line: 0, column: 0, message, severity: 'error' }])}\n`) - } else { - process.stderr.write(`${message}\n`) - } - process.exit(1) -}) diff --git a/mod/fabric/build.gradle b/mod/fabric/build.gradle index 0c296e2..bb2aaec 100644 --- a/mod/fabric/build.gradle +++ b/mod/fabric/build.gradle @@ -41,6 +41,8 @@ remapJar { processResources { inputs.property 'mod_version', project.version + inputs.property 'minecraft_version', rootProject.minecraft_version + inputs.property 'supported_game_versions', rootProject.supportedGameVersions filesMatching('fabric.mod.json') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle index ed64645..7f7e21b 100644 --- a/mod/forge/build.gradle +++ b/mod/forge/build.gradle @@ -46,9 +46,13 @@ remapJar { processResources { inputs.property 'mod_version', project.version + inputs.property 'minecraft_version', rootProject.minecraft_version + inputs.property 'supported_game_versions', rootProject.supportedGameVersions + inputs.property 'forge_version', rootProject.forge_version filesMatching('META-INF/mods.toml') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, + 'forge_version': rootProject.forge_version, 'supported_game_versions': rootProject.supportedGameVersions } } diff --git a/mod/forge/src/main/resources/META-INF/mods.toml b/mod/forge/src/main/resources/META-INF/mods.toml index 58f9c16..13819fa 100644 --- a/mod/forge/src/main/resources/META-INF/mods.toml +++ b/mod/forge/src/main/resources/META-INF/mods.toml @@ -13,7 +13,7 @@ authors = "SpyC0der77" [[dependencies.mcs_packs]] modId = "forge" mandatory = true -versionRange = "[${minecraft_version},)" +versionRange = "[${forge_version},)" ordering = "NONE" side = "BOTH" diff --git a/mod/gradle.properties b/mod/gradle.properties index a404202..16bcbf1 100644 --- a/mod/gradle.properties +++ b/mod/gradle.properties @@ -22,4 +22,4 @@ forge_version=61.1.0 neoforge_version=21.11.42 architectury_api_version=19.0.1 -enabled_platforms=fabric +enabled_platforms=fabric,forge,neoforge diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle index 25c29a5..f76b3bd 100644 --- a/mod/neoforge/build.gradle +++ b/mod/neoforge/build.gradle @@ -46,9 +46,13 @@ remapJar { processResources { inputs.property 'mod_version', project.version + inputs.property 'minecraft_version', rootProject.minecraft_version + inputs.property 'supported_game_versions', rootProject.supportedGameVersions + inputs.property 'neoforge_version', rootProject.neoforge_version filesMatching('META-INF/neoforge.mods.toml') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, + 'neoforge_version': rootProject.neoforge_version, 'supported_game_versions': rootProject.supportedGameVersions } } diff --git a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml index d93f35d..d749f48 100644 --- a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml +++ b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -13,7 +13,7 @@ authors = "SpyC0der77" [[dependencies.mcs_packs]] modId = "neoforge" type = "required" -versionRange = "[${minecraft_version},)" +versionRange = "[${neoforge_version},)" ordering = "NONE" side = "BOTH" diff --git a/mod/scripts/apply_version.py b/mod/scripts/apply_version.py index a46c4f4..79e1fad 100644 --- a/mod/scripts/apply_version.py +++ b/mod/scripts/apply_version.py @@ -10,6 +10,18 @@ MOD_ROOT = Path(__file__).resolve().parents[1] MANIFEST = MOD_ROOT / "versions" / "manifest.json" GRADLE_PROPERTIES = MOD_ROOT / "gradle.properties" +DEFAULT_ENABLED_PLATFORMS = "fabric,forge,neoforge" + + +def read_enabled_platforms() -> str: + if not GRADLE_PROPERTIES.exists(): + return DEFAULT_ENABLED_PLATFORMS + for line in GRADLE_PROPERTIES.read_text(encoding="utf-8").splitlines(): + if line.startswith("enabled_platforms="): + value = line.split("=", 1)[1].strip() + if value and value != "fabric": + return value + return DEFAULT_ENABLED_PLATFORMS def main() -> int: @@ -48,7 +60,7 @@ def main() -> int: f"neoforge_version={profile['neoforge_version']}", f"architectury_api_version={profile['architectury_api_version']}", "", - "enabled_platforms=fabric", + f"enabled_platforms={read_enabled_platforms()}", ] GRADLE_PROPERTIES.write_text("\n".join(lines) + "\n", encoding="utf-8") print(f"Wrote {GRADLE_PROPERTIES} for profile {args.profile}") diff --git a/mod/scripts/bun.lock b/mod/scripts/bun.lock index 7a8908d..4677c73 100644 --- a/mod/scripts/bun.lock +++ b/mod/scripts/bun.lock @@ -9,9 +9,64 @@ "@spyglassmc/java-edition": "^0.3.60", "@spyglassmc/mcdoc": "^0.3.51", }, + "devDependencies": { + "esbuild": "^0.25.5", + }, }, }, "packages": { + "@esbuild/aix-ppc64": ["@esbuild/aix-ppc64@0.25.12", "", { "os": "aix", "cpu": "ppc64" }, "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA=="], + + "@esbuild/android-arm": ["@esbuild/android-arm@0.25.12", "", { "os": "android", "cpu": "arm" }, "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg=="], + + "@esbuild/android-arm64": ["@esbuild/android-arm64@0.25.12", "", { "os": "android", "cpu": "arm64" }, "sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg=="], + + "@esbuild/android-x64": ["@esbuild/android-x64@0.25.12", "", { "os": "android", "cpu": "x64" }, "sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg=="], + + "@esbuild/darwin-arm64": ["@esbuild/darwin-arm64@0.25.12", "", { "os": "darwin", "cpu": "arm64" }, "sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg=="], + + "@esbuild/darwin-x64": ["@esbuild/darwin-x64@0.25.12", "", { "os": "darwin", "cpu": "x64" }, "sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA=="], + + "@esbuild/freebsd-arm64": ["@esbuild/freebsd-arm64@0.25.12", "", { "os": "freebsd", "cpu": "arm64" }, "sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg=="], + + "@esbuild/freebsd-x64": ["@esbuild/freebsd-x64@0.25.12", "", { "os": "freebsd", "cpu": "x64" }, "sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ=="], + + "@esbuild/linux-arm": ["@esbuild/linux-arm@0.25.12", "", { "os": "linux", "cpu": "arm" }, "sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw=="], + + "@esbuild/linux-arm64": ["@esbuild/linux-arm64@0.25.12", "", { "os": "linux", "cpu": "arm64" }, "sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ=="], + + "@esbuild/linux-ia32": ["@esbuild/linux-ia32@0.25.12", "", { "os": "linux", "cpu": "ia32" }, "sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA=="], + + "@esbuild/linux-loong64": ["@esbuild/linux-loong64@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng=="], + + "@esbuild/linux-mips64el": ["@esbuild/linux-mips64el@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw=="], + + "@esbuild/linux-ppc64": ["@esbuild/linux-ppc64@0.25.12", "", { "os": "linux", "cpu": "ppc64" }, "sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA=="], + + "@esbuild/linux-riscv64": ["@esbuild/linux-riscv64@0.25.12", "", { "os": "linux", "cpu": "none" }, "sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w=="], + + "@esbuild/linux-s390x": ["@esbuild/linux-s390x@0.25.12", "", { "os": "linux", "cpu": "s390x" }, "sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg=="], + + "@esbuild/linux-x64": ["@esbuild/linux-x64@0.25.12", "", { "os": "linux", "cpu": "x64" }, "sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw=="], + + "@esbuild/netbsd-arm64": ["@esbuild/netbsd-arm64@0.25.12", "", { "os": "none", "cpu": "arm64" }, "sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg=="], + + "@esbuild/netbsd-x64": ["@esbuild/netbsd-x64@0.25.12", "", { "os": "none", "cpu": "x64" }, "sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ=="], + + "@esbuild/openbsd-arm64": ["@esbuild/openbsd-arm64@0.25.12", "", { "os": "openbsd", "cpu": "arm64" }, "sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A=="], + + "@esbuild/openbsd-x64": ["@esbuild/openbsd-x64@0.25.12", "", { "os": "openbsd", "cpu": "x64" }, "sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw=="], + + "@esbuild/openharmony-arm64": ["@esbuild/openharmony-arm64@0.25.12", "", { "os": "none", "cpu": "arm64" }, "sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg=="], + + "@esbuild/sunos-x64": ["@esbuild/sunos-x64@0.25.12", "", { "os": "sunos", "cpu": "x64" }, "sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w=="], + + "@esbuild/win32-arm64": ["@esbuild/win32-arm64@0.25.12", "", { "os": "win32", "cpu": "arm64" }, "sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg=="], + + "@esbuild/win32-ia32": ["@esbuild/win32-ia32@0.25.12", "", { "os": "win32", "cpu": "ia32" }, "sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ=="], + + "@esbuild/win32-x64": ["@esbuild/win32-x64@0.25.12", "", { "os": "win32", "cpu": "x64" }, "sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA=="], + "@spyglassmc/core": ["@spyglassmc/core@0.4.47", "", { "dependencies": { "@spyglassmc/locales": "0.3.24", "base64-arraybuffer": "^1.0.2", "binary-search": "^1.3.6", "decompress": "^4.2.1", "follow-redirects": "^1.14.8", "picomatch": "^4.0.2", "rfdc": "^1.3.0", "vscode-languageserver-textdocument": "^1.0.4", "whatwg-url": "^14.0.0" } }, "sha512-xC75t4+yDZNiofCgRt/up8XuVb6qo03NoEziT32Y05+TbXae0fD5N/8KBZmcLfGnFZQaYB5pYPHkULxMKiV3sg=="], "@spyglassmc/java-edition": ["@spyglassmc/java-edition@0.3.60", "", { "dependencies": { "@spyglassmc/core": "0.4.47", "@spyglassmc/json": "0.3.51", "@spyglassmc/locales": "0.3.24", "@spyglassmc/mcdoc": "0.3.51", "@spyglassmc/mcfunction": "0.2.50", "@spyglassmc/nbt": "0.3.53" } }, "sha512-XUF9kddzOh2lSn5J+s1cTZfMUnY0bDtbk2dZEOnfuN2Jx/apGIiqgxGA/tv8zcs34vomSk/OPHW4rK7S4buvTA=="], @@ -78,6 +133,8 @@ "es-object-atoms": ["es-object-atoms@1.1.2", "", { "dependencies": { "es-errors": "^1.3.0" } }, "sha512-HWcBoN6NileqtSydK2FqHbS/LoDd2pqrnQHLyJzBj4kOp/ky2MWMN694xOfkK8/SnUsW2DH7EfyVlydKCsm1Zw=="], + "esbuild": ["esbuild@0.25.12", "", { "optionalDependencies": { "@esbuild/aix-ppc64": "0.25.12", "@esbuild/android-arm": "0.25.12", "@esbuild/android-arm64": "0.25.12", "@esbuild/android-x64": "0.25.12", "@esbuild/darwin-arm64": "0.25.12", "@esbuild/darwin-x64": "0.25.12", "@esbuild/freebsd-arm64": "0.25.12", "@esbuild/freebsd-x64": "0.25.12", "@esbuild/linux-arm": "0.25.12", "@esbuild/linux-arm64": "0.25.12", "@esbuild/linux-ia32": "0.25.12", "@esbuild/linux-loong64": "0.25.12", "@esbuild/linux-mips64el": "0.25.12", "@esbuild/linux-ppc64": "0.25.12", "@esbuild/linux-riscv64": "0.25.12", "@esbuild/linux-s390x": "0.25.12", "@esbuild/linux-x64": "0.25.12", "@esbuild/netbsd-arm64": "0.25.12", "@esbuild/netbsd-x64": "0.25.12", "@esbuild/openbsd-arm64": "0.25.12", "@esbuild/openbsd-x64": "0.25.12", "@esbuild/openharmony-arm64": "0.25.12", "@esbuild/sunos-x64": "0.25.12", "@esbuild/win32-arm64": "0.25.12", "@esbuild/win32-ia32": "0.25.12", "@esbuild/win32-x64": "0.25.12" }, "bin": { "esbuild": "bin/esbuild" } }, "sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg=="], + "fd-slicer": ["fd-slicer@1.1.0", "", { "dependencies": { "pend": "~1.2.0" } }, "sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g=="], "file-type": ["file-type@5.2.0", "", {}, "sha512-Iq1nJ6D2+yIO4c8HHg4fyVb8mAJieo1Oloy1mLLaB2PvezNedhBVm+QU7g0qM42aiMbRXTxKKwGD17rjKNJYVQ=="], diff --git a/mod/scripts/mcs-spyglass-validate.mjs b/mod/scripts/mcs-spyglass-validate.mjs index 4a864b6..6c296a7 100644 --- a/mod/scripts/mcs-spyglass-validate.mjs +++ b/mod/scripts/mcs-spyglass-validate.mjs @@ -1,10 +1,6 @@ -#!/usr/bin/env node -import { mkdirSync } from 'node:fs' -import { mkdtempSync } from 'node:fs' -import { readFileSync } from 'node:fs' -import { readdirSync, statSync } from 'node:fs' -import { join, relative, resolve } from 'node:path' +import { mkdirSync, mkdtempSync, readFileSync, readdirSync, rmSync, statSync } from 'node:fs' import { tmpdir } from 'node:os' +import { join, relative, resolve } from 'node:path' import { pathToFileURL } from 'node:url' import { @@ -44,7 +40,7 @@ function parseArgs(argv) { } if (positional.length < 1) { - throw new Error('Usage: node mcs-spyglass-validate.mjs [--json] [--mc-version ] ') + throw new Error('Usage: node mcs-spyglass-validate.js [--json] [--mc-version ] ') } return { flags, datapackDir: resolve(positional[0]) } @@ -102,67 +98,72 @@ async function main() { throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`) } - const cacheRoot = toRootUri(mkdtempSync(join(tmpdir(), 'mcs-spyglass-'))) + const cacheDir = mkdtempSync(join(tmpdir(), 'mcs-spyglass-')) + const cacheRoot = toRootUri(cacheDir) mkdirSync(new URL(cacheRoot), { recursive: true }) const projectRoot = toRootUri(datapackDir) const gameVersion = flags.mcVersion const diagnostics = [] - const project = new Project({ - cacheRoot, - defaultConfig: { - ...VanillaConfig, - env: { - ...VanillaConfig.env, - ...(gameVersion ? { gameVersion } : {}), + try { + const project = new Project({ + cacheRoot, + defaultConfig: { + ...VanillaConfig, + env: { + ...VanillaConfig.env, + ...(gameVersion ? { gameVersion } : {}), + }, }, - }, - externals: getNodeJsExternals({ cacheRoot }), - initializers: [initializeMcdoc, initializeJavaEdition], - isDebugging: false, - logger: Logger.create('warn'), - projectRoots: [projectRoot], - }) - - project.on('documentErrored', ({ uri, errors }) => { - for (const error of errors) { - const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, '$1')) - const relativePath = relative(datapackDir, filePath).replace(/\\/g, '/') - const start = error.posRange?.start - diagnostics.push({ - file: relativePath, - line: (start?.line ?? 0) + 1, - column: (start?.character ?? 0) + 1, - message: error.message, - severity: severityName(error.severity), - }) + externals: getNodeJsExternals({ cacheRoot }), + initializers: [initializeMcdoc, initializeJavaEdition], + isDebugging: false, + logger: Logger.create('warn'), + projectRoots: [projectRoot], + }) + + project.on('documentErrored', ({ uri, errors }) => { + for (const error of errors) { + const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, '$1')) + const relativePath = relative(datapackDir, filePath).replace(/\\/g, '/') + const start = error.posRange?.start + diagnostics.push({ + file: relativePath, + line: (start?.line ?? 0) + 1, + column: (start?.character ?? 0) + 1, + message: error.message, + severity: severityName(error.severity), + }) + } + }) + + await project.init() + await project.ready() + + for (const filePath of walkFiles(datapackDir)) { + const languageId = languageIdFor(filePath) + if (!languageId) continue + const uri = pathToFileURL(filePath).href + const content = readFileSync(filePath, 'utf8') + await project.onDidOpen(uri, languageId, 1, content) + const managed = await project.ensureClientManagedChecked(uri) + if (!managed) continue + for (const error of FileNode.getErrors(managed.node)) { + diagnostics.push({ + file: relative(datapackDir, filePath).replace(/\\/g, '/'), + line: error.range.start.line + 1, + column: error.range.start.character + 1, + message: error.message, + severity: severityName(error.severity), + }) + } } - }) - await project.init() - await project.ready() - - for (const filePath of walkFiles(datapackDir)) { - const languageId = languageIdFor(filePath) - if (!languageId) continue - const uri = pathToFileURL(filePath).href - const content = readFileSync(filePath, 'utf8') - await project.onDidOpen(uri, languageId, 1, content) - const managed = await project.ensureClientManagedChecked(uri) - if (!managed) continue - for (const error of FileNode.getErrors(managed.node)) { - diagnostics.push({ - file: relative(datapackDir, filePath).replace(/\\/g, '/'), - line: error.range.start.line + 1, - column: error.range.start.character + 1, - message: error.message, - severity: severityName(error.severity), - }) - } + await project.close() + } finally { + rmSync(cacheDir, { recursive: true, force: true }) } - await project.close() - const unique = new Map() for (const diagnostic of diagnostics) { const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}` @@ -185,7 +186,7 @@ async function main() { } const hasErrors = result.some((diagnostic) => diagnostic.severity === 'error') - process.exit(hasErrors ? 1 : 0) + process.exitCode = hasErrors ? 1 : 0 } main().catch((error) => { @@ -195,5 +196,5 @@ main().catch((error) => { } else { process.stderr.write(`${message}\n`) } - process.exit(1) + process.exitCode = 1 }) diff --git a/mod/scripts/package.json b/mod/scripts/package.json index 395b9fa..b3a356f 100644 --- a/mod/scripts/package.json +++ b/mod/scripts/package.json @@ -2,9 +2,15 @@ "name": "mcs-mod-scripts", "private": true, "type": "module", + "scripts": { + "bundle:spyglass": "esbuild mcs-spyglass-validate.mjs --bundle --platform=node --format=cjs --packages=bundle --outfile=../common/src/main/resources/scripts/mcs-spyglass-validate.js --banner:js=\"#!/usr/bin/env node\"" + }, "dependencies": { "@spyglassmc/core": "^0.4.47", "@spyglassmc/java-edition": "^0.3.60", "@spyglassmc/mcdoc": "^0.3.51" + }, + "devDependencies": { + "esbuild": "^0.25.5" } } From f1bbb62727727e8fe2c24cc0a5fe7dea2bd2c3a9 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Tue, 9 Jun 2026 18:23:53 -0400 Subject: [PATCH 05/12] Enhance mod build process and platform support - Updated GitHub Actions workflow to pass the loader argument to the version application script, allowing for targeted platform builds. - Modified `settings.gradle` to dynamically set enabled platforms based on the provided loader or default to multiple platforms. - Enhanced `apply_version.py` to conditionally set enabled platforms based on the loader argument, improving flexibility in build configurations. - Refactored `build_all.py` to incorporate the loader argument in the build command, streamlining the build process for specific platforms. --- .github/workflows/mod.yml | 6 +++-- mod/build.gradle | 2 +- mod/common/build.gradle | 26 ++++++++++++++++--- .../mcspacks/toolchain/CompilerResolver.java | 2 +- .../mcspacks/toolchain/McsToolchain.java | 7 ++++- .../spyc0der77/mcspacks/util/SafePaths.java | 4 +-- .../mcspacks/version/VersionMapper.java | 3 +-- .../main/resources/scripts/mcs-compile.cmd | 12 ++++----- .../src/main/resources/starter/pack.mcs | 16 ------------ mod/gradle/wrapper/gradle-wrapper.properties | 1 + .../resources/META-INF/neoforge.mods.toml | 2 +- mod/scripts/apply_version.py | 7 ++++- mod/scripts/build_all.py | 19 +++++++++++++- mod/settings.gradle | 10 +++++-- mod/versions/manifest.json | 2 +- 15 files changed, 79 insertions(+), 40 deletions(-) delete mode 100644 mod/common/src/main/resources/starter/pack.mcs diff --git a/.github/workflows/mod.yml b/.github/workflows/mod.yml index ac6a5d2..1b167fc 100644 --- a/.github/workflows/mod.yml +++ b/.github/workflows/mod.yml @@ -5,10 +5,12 @@ on: paths: - 'mod/**' - 'minecraft_script/versions/**' + - '.github/workflows/mod.yml' pull_request: paths: - 'mod/**' - 'minecraft_script/versions/**' + - '.github/workflows/mod.yml' jobs: build-matrix: @@ -29,7 +31,7 @@ jobs: working-directory: mod/scripts run: bun install --frozen-lockfile - name: Apply version profile - run: python mod/scripts/apply_version.py ${{ matrix.profile }} + run: python mod/scripts/apply_version.py ${{ matrix.profile }} --loader ${{ matrix.loader }} - name: Build ${{ matrix.loader }} for ${{ matrix.profile }} working-directory: mod - run: ./gradlew :${{ matrix.loader }}:build -Pmcs_profile=${{ matrix.profile }} -x test + run: ./gradlew :${{ matrix.loader }}:build -Pmcs_profile=${{ matrix.profile }} -Penabled_platforms=${{ matrix.loader }} -x test diff --git a/mod/build.gradle b/mod/build.gradle index 3e54f83..e44149d 100644 --- a/mod/build.gradle +++ b/mod/build.gradle @@ -51,7 +51,7 @@ subprojects { mavenCentral() maven { url = 'https://maven.fabricmc.net/' } maven { url = 'https://maven.architectury.dev/' } - maven { url = 'https://files.minecraftforge.net/maven/' } + maven { url = 'https://maven.minecraftforge.net/' } maven { url = 'https://maven.neoforged.net/releases' } } diff --git a/mod/common/build.gradle b/mod/common/build.gradle index 8e90101..c5da377 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -32,7 +32,13 @@ tasks.register('syncMcsVersions', Copy) { rename { 'mcs-versions.json' } } -processResources.dependsOn syncMcsVersions +tasks.register('syncStarterPack', Copy) { + from rootProject.file('../examples/starter_datapack.mcs') + into generatedResourcesDir.map { it.dir('starter') } + rename { 'pack.mcs' } +} + +processResources.dependsOn syncMcsVersions, syncStarterPack dependencies { modImplementation "dev.architectury:architectury:${rootProject.architectury_api_version}" @@ -50,9 +56,23 @@ tasks.register('bundleSpyglassScript') { outputs.file(spyglassBundledScript) doLast { + def scriptsDir = file("${rootProject.projectDir}/scripts") + def bunAvailable = providers.exec { + workingDir scriptsDir + commandLine 'bun', '--version' + ignoreExitValue true + }.result.get().exitValue == 0 + exec { - workingDir "${rootProject.projectDir}/scripts" - commandLine 'bun', 'run', 'bundle:spyglass' + workingDir scriptsDir + if (bunAvailable) { + commandLine 'bun', 'run', 'bundle:spyglass' + } else { + commandLine 'npx', '--yes', 'esbuild', 'mcs-spyglass-validate.mjs', + '--bundle', '--platform=node', '--format=cjs', '--packages=bundle', + '--outfile=../common/src/main/resources/scripts/mcs-spyglass-validate.js', + '--banner:js=#!/usr/bin/env node' + } } } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java index b547383..b46bf91 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -143,7 +143,7 @@ private static String quoteForCmd(String arg) { if (!needsCmdQuoting(arg)) { return arg; } - return "\"" + arg.replace("\"", "\\\"") + "\""; + return "\"" + arg.replace("\"", "\\\"").replace("%", "%%") + "\""; } private static boolean needsCmdQuoting(String arg) { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java index 45796b5..3cf0df3 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -112,7 +112,12 @@ public List validateWithSpyglass(PackDefinition pack, String gameVer } private static String relative(PackDefinition pack, Path file) { - return pack.folder().relativize(file).toString().replace('\\', '/'); + Path folder = pack.folder().toAbsolutePath().normalize(); + Path absolute = file.toAbsolutePath().normalize(); + if (!absolute.startsWith(folder)) { + return absolute.toString().replace('\\', '/'); + } + return folder.relativize(absolute).toString().replace('\\', '/'); } private static void deleteRecursive(Path path) throws IOException { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java index 49c180d..8b511d8 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/SafePaths.java @@ -11,7 +11,7 @@ public static void validateSafeName(String name) throws IOException { if (name == null || name.isBlank()) { throw new IOException("Name must not be blank"); } - if (name.contains("/") || name.contains("\\") || name.contains("..")) { + if (name.equals(".") || name.contains("/") || name.contains("\\") || name.contains("..")) { throw new IOException("Unsafe path name: " + name); } } @@ -20,7 +20,7 @@ public static Path resolveChild(Path parent, String childName) throws IOExceptio validateSafeName(childName); Path normalizedParent = parent.toAbsolutePath().normalize(); Path resolved = normalizedParent.resolve(childName).normalize(); - if (!resolved.startsWith(normalizedParent)) { + if (resolved.equals(normalizedParent) || !resolved.startsWith(normalizedParent)) { throw new IOException("Path escapes parent directory: " + childName); } return resolved; diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java index ffb9718..f428fa6 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java @@ -2,7 +2,6 @@ import com.google.gson.Gson; import com.google.gson.annotations.SerializedName; -import dev.architectury.platform.Platform; import java.io.InputStream; import java.io.InputStreamReader; import java.nio.charset.StandardCharsets; @@ -33,7 +32,7 @@ public static VersionMapper load() { public String resolveMcsProfile(String gameVersion, String configuredVersion) { String version = configuredVersion; if (version == null || version.isBlank() || "auto".equalsIgnoreCase(version)) { - version = Platform.getMinecraftVersion(); + version = gameVersion; } if (profiles.containsKey(version)) { return profiles.get(version); diff --git a/mod/common/src/main/resources/scripts/mcs-compile.cmd b/mod/common/src/main/resources/scripts/mcs-compile.cmd index 1be702e..789d916 100644 --- a/mod/common/src/main/resources/scripts/mcs-compile.cmd +++ b/mod/common/src/main/resources/scripts/mcs-compile.cmd @@ -1,11 +1,5 @@ @echo off setlocal EnableExtensions EnableDelayedExpansion -for %%P in (313 312 311 310) do ( - if exist "C:\Python%%P\python.exe" ( - call :run_python "C:\Python%%P\python.exe" %* - exit /b !ERRORLEVEL! - ) -) where mcs >nul 2>&1 && ( call :run_mcs %* exit /b !ERRORLEVEL! @@ -22,6 +16,12 @@ if defined PYTHON if exist "%PYTHON%" ( call :run_python "%PYTHON%" %* exit /b !ERRORLEVEL! ) +for %%P in (313 312 311 310) do ( + if exist "C:\Python%%P\python.exe" ( + call :run_python "C:\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) +) echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 exit /b 1 diff --git a/mod/common/src/main/resources/starter/pack.mcs b/mod/common/src/main/resources/starter/pack.mcs deleted file mode 100644 index 6846016..0000000 --- a/mod/common/src/main/resources/starter/pack.mcs +++ /dev/null @@ -1,16 +0,0 @@ -var has_announced = false; - -function init() { - log("Starter datapack loaded"); -} - -function main() { - if (!has_announced) { - tellraw("@a", text().text("Welcome from Minecraft-Script!").color("gold").bold()); - set has_announced = true; - } -} - -function kill() { - log("Starter datapack disabled"); -} diff --git a/mod/gradle/wrapper/gradle-wrapper.properties b/mod/gradle/wrapper/gradle-wrapper.properties index cea7a79..c43ecd6 100644 --- a/mod/gradle/wrapper/gradle-wrapper.properties +++ b/mod/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-bin.zip +distributionSha256Sum=7a00d51fb93147819aab76024feece20b6b84e420694101f276be952e08bef03 networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml index d749f48..32af25d 100644 --- a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml +++ b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -1,5 +1,5 @@ modLoader = "javafml" -loaderVersion = "[4,)" +loaderVersion = "[1,)" license = "MIT" issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" diff --git a/mod/scripts/apply_version.py b/mod/scripts/apply_version.py index 79e1fad..43843ec 100644 --- a/mod/scripts/apply_version.py +++ b/mod/scripts/apply_version.py @@ -27,6 +27,11 @@ def read_enabled_platforms() -> str: def main() -> int: parser = argparse.ArgumentParser(description=__doc__) parser.add_argument("profile", help="MCS profile key from versions/manifest.json") + parser.add_argument( + "--loader", + choices=["fabric", "forge", "neoforge"], + help="Enable only this loader platform in gradle.properties (default: all loaders)", + ) args = parser.parse_args() manifest = json.loads(MANIFEST.read_text(encoding="utf-8")) @@ -60,7 +65,7 @@ def main() -> int: f"neoforge_version={profile['neoforge_version']}", f"architectury_api_version={profile['architectury_api_version']}", "", - f"enabled_platforms={read_enabled_platforms()}", + f"enabled_platforms={args.loader if args.loader else read_enabled_platforms()}", ] GRADLE_PROPERTIES.write_text("\n".join(lines) + "\n", encoding="utf-8") print(f"Wrote {GRADLE_PROPERTIES} for profile {args.profile}") diff --git a/mod/scripts/build_all.py b/mod/scripts/build_all.py index 20bc300..ee2bef2 100644 --- a/mod/scripts/build_all.py +++ b/mod/scripts/build_all.py @@ -19,7 +19,24 @@ def load_manifest() -> dict: def run_build(profile: str, loader: str, skip_tests: bool) -> int: - command = [str(GRADLEW), f":{loader}:build", f"-Pmcs_profile={profile}"] + apply = [ + sys.executable, + str(MOD_ROOT / "scripts" / "apply_version.py"), + profile, + "--loader", + loader, + ] + print(f"\n==> {' '.join(apply)}", flush=True) + apply_code = subprocess.run(apply, cwd=MOD_ROOT, check=False).returncode + if apply_code != 0: + return apply_code + + command = [ + str(GRADLEW), + f":{loader}:build", + f"-Pmcs_profile={profile}", + f"-Penabled_platforms={loader}", + ] if skip_tests: command.append("-x") command.append("test") diff --git a/mod/settings.gradle b/mod/settings.gradle index 0e8cdea..5625720 100644 --- a/mod/settings.gradle +++ b/mod/settings.gradle @@ -2,7 +2,7 @@ pluginManagement { repositories { maven { url = 'https://maven.fabricmc.net/' } maven { url = 'https://maven.architectury.dev/' } - maven { url = 'https://files.minecraftforge.net/maven/' } + maven { url = 'https://maven.minecraftforge.net/' } gradlePluginPortal() } } @@ -14,7 +14,13 @@ def propertiesFile = file('gradle.properties') if (propertiesFile.exists()) { propertiesFile.withInputStream { properties.load(it) } } -def enabledPlatforms = (properties.getProperty('enabled_platforms', 'fabric') ?: 'fabric') + +def enabledPlatformsProperty = gradle.startParameter.projectProperties.get('enabled_platforms') +if (enabledPlatformsProperty == null) { + enabledPlatformsProperty = properties.getProperty('enabled_platforms', 'fabric,forge,neoforge') +} + +def enabledPlatforms = (enabledPlatformsProperty ?: 'fabric,forge,neoforge') .split(',') .collect { it.trim() } .findAll { !it.isEmpty() } diff --git a/mod/versions/manifest.json b/mod/versions/manifest.json index 91d5549..465dc0a 100644 --- a/mod/versions/manifest.json +++ b/mod/versions/manifest.json @@ -77,7 +77,7 @@ "supported_game_versions": ["26.1"], "fabric_loader_version": "0.19.3", "fabric_api_version": "0.145.0+26.1", - "forge_version": "60.0.0", + "forge_version": "64.0.0", "neoforge_version": "26.1.4-beta", "architectury_api_version": "20.0.1" } From 7d52ac0906a965923f31c8cabdc01d761cf15657 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 13:31:31 -0400 Subject: [PATCH 06/12] Remove obsolete architectury-cache project ID file from Gradle configuration --- mod/common/.gradle/architectury-cache/projectID | 1 - 1 file changed, 1 deletion(-) delete mode 100644 mod/common/.gradle/architectury-cache/projectID diff --git a/mod/common/.gradle/architectury-cache/projectID b/mod/common/.gradle/architectury-cache/projectID deleted file mode 100644 index 8461cfb..0000000 --- a/mod/common/.gradle/architectury-cache/projectID +++ /dev/null @@ -1 +0,0 @@ -6035d13486624f5d8089c57a493f5da2 \ No newline at end of file From 55623a9f96caa43bd0d456a0c36e67fb4ce18ea7 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 13:31:37 -0400 Subject: [PATCH 07/12] e --- .gitattributes | 2 + .github/workflows/mod.yml | 8 +- .gitignore | 1 + minecraft_script/shell_commands.py | 3 +- mod/common/build.gradle | 8 +- .../mcspacks/config/ModConfigManager.java | 13 +- .../mcspacks/deploy/DatapackDeployer.java | 3 + .../mcspacks/pipeline/PackPipeline.java | 23 +-- .../mcspacks/registry/PackRegistry.java | 2 +- .../mcspacks/toolchain/CompilerResolver.java | 64 ++++++--- .../mcspacks/toolchain/McsToolchain.java | 10 +- .../mcspacks/toolchain/SubprocessRunner.java | 16 ++- .../spyc0der77/mcspacks/util/McsPaths.java | 30 +++- .../mcspacks/util/PlayerFeedback.java | 6 +- .../mcspacks/version/VersionMapper.java | 6 + .../mcspacks/watch/PackWatcher.java | 11 +- .../main/resources/scripts/mcs-compile.cmd | 134 ++++++++++-------- .../src/main/resources/scripts/mcs-compile.sh | 38 +++++ mod/fabric/build.gradle | 6 +- mod/fabric/src/main/resources/fabric.mod.json | 4 +- mod/forge/build.gradle | 32 ++++- .../src/main/resources/META-INF/mods.toml | 8 +- mod/gradle.properties | 20 +-- mod/neoforge/build.gradle | 30 ++++ .../resources/META-INF/neoforge.mods.toml | 8 +- mod/scripts/apply_version.py | 13 +- mod/scripts/mcs-spyglass-validate.mjs | 8 +- mod/scripts/package.json | 2 +- mod/versions/manifest.json | 2 +- tests/test_compile_cli_flags.py | 3 + 30 files changed, 362 insertions(+), 152 deletions(-) create mode 100644 .gitattributes create mode 100644 mod/common/src/main/resources/scripts/mcs-compile.sh diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..8517edc --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +*.cmd text eol=crlf +*.bat text eol=crlf diff --git a/.github/workflows/mod.yml b/.github/workflows/mod.yml index 1b167fc..6c6e097 100644 --- a/.github/workflows/mod.yml +++ b/.github/workflows/mod.yml @@ -21,12 +21,14 @@ jobs: profile: [1.21.2, 1.21.4, 1.21.5, 1.21.6, 1.21.7-8, 1.21.9-10, 1.21.11, 26.1] loader: [fabric, forge, neoforge] steps: - - uses: actions/checkout@v4 - - uses: actions/setup-java@v4 + - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 + with: + persist-credentials: false + - uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4 with: distribution: temurin java-version: 21 - - uses: oven-sh/setup-bun@v2 + - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 - name: Install Spyglass bundle dependencies working-directory: mod/scripts run: bun install --frozen-lockfile diff --git a/.gitignore b/.gitignore index b33acc8..ce15fdc 100644 --- a/.gitignore +++ b/.gitignore @@ -14,6 +14,7 @@ dist/ *.egg-info/ build_test/ mod/.gradle/ +mod/**/.gradle/architectury-cache/ mod/build/ mod/out/ mod/run/ diff --git a/minecraft_script/shell_commands.py b/minecraft_script/shell_commands.py index 182ff39..d96b7c9 100644 --- a/minecraft_script/shell_commands.py +++ b/minecraft_script/shell_commands.py @@ -43,7 +43,8 @@ def _parse_flag_args( continue if arg.startswith("--"): if arg not in supported_flags: - positional.append(arg) + print(f"Error: Unknown flag {arg}.") + exit(-1) index += 1 continue positional.append(arg) diff --git a/mod/common/build.gradle b/mod/common/build.gradle index c5da377..9cc7ae0 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -46,14 +46,14 @@ dependencies { } def spyglassSourceScript = file("${rootProject.projectDir}/scripts/mcs-spyglass-validate.mjs") -def spyglassBundledScript = file('src/main/resources/scripts/mcs-spyglass-validate.js') +def spyglassBundledScript = layout.buildDirectory.file('generated/resources/main/scripts/mcs-spyglass-validate.js') tasks.register('bundleSpyglassScript') { onlyIf { spyglassSourceScript.exists() } inputs.file(spyglassSourceScript) inputs.file("${rootProject.projectDir}/scripts/package.json") inputs.file("${rootProject.projectDir}/scripts/bun.lock") - outputs.file(spyglassBundledScript) + outputs.file(spyglassBundledScript.get().asFile) doLast { def scriptsDir = file("${rootProject.projectDir}/scripts") @@ -68,9 +68,9 @@ tasks.register('bundleSpyglassScript') { if (bunAvailable) { commandLine 'bun', 'run', 'bundle:spyglass' } else { - commandLine 'npx', '--yes', 'esbuild', 'mcs-spyglass-validate.mjs', + commandLine 'npx', '--no-install', 'esbuild', 'mcs-spyglass-validate.mjs', '--bundle', '--platform=node', '--format=cjs', '--packages=bundle', - '--outfile=../common/src/main/resources/scripts/mcs-spyglass-validate.js', + "--outfile=${spyglassBundledScript.get().asFile}", '--banner:js=#!/usr/bin/env node' } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java index 72173b3..5d926a4 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java @@ -6,6 +6,8 @@ import dev.spyc0der77.mcspacks.util.McsPaths; import java.io.IOException; import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.StandardCopyOption; public final class ModConfigManager { private static final Gson GSON = new GsonBuilder().setPrettyPrinting().create(); @@ -33,7 +35,14 @@ public static ModConfig load() { } public static void save(ModConfig config) throws IOException { - Files.createDirectories(McsPaths.configFile().getParent()); - Files.writeString(McsPaths.configFile(), GSON.toJson(config)); + Path configFile = McsPaths.configFile(); + Files.createDirectories(configFile.getParent()); + Path tempFile = Files.createTempFile(configFile.getParent(), "mcs-packs-", ".json.tmp"); + try { + Files.writeString(tempFile, GSON.toJson(config)); + Files.move(tempFile, configFile, StandardCopyOption.ATOMIC_MOVE, StandardCopyOption.REPLACE_EXISTING); + } finally { + Files.deleteIfExists(tempFile); + } } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java index 2aada54..7268cdb 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/deploy/DatapackDeployer.java @@ -18,6 +18,9 @@ private DatapackDeployer() { public static void syncPack(MinecraftServer server, Path compiledPack, String packFolderName) throws IOException { Path worldDatapacks = server.getWorldPath(LevelResource.DATAPACK_DIR); Files.createDirectories(worldDatapacks); + if (!Files.exists(compiledPack) || !Files.isDirectory(compiledPack) || !Files.isReadable(compiledPack)) { + throw new IOException("Compiled pack is missing or unreadable: " + compiledPack); + } Path target = SafePaths.resolveChild(worldDatapacks, packFolderName); if (Files.exists(target)) { deleteRecursive(target); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java index d642ee9..392f103 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/pipeline/PackPipeline.java @@ -66,7 +66,8 @@ public void prepareWorldPacks(MinecraftServer server) { try { for (PackDefinition pack : registry.discover()) { try { - processPack(server, pack, false); + long generation = generations.merge(pack.id(), 1L, Long::sum); + processPack(server, pack, false, generation); } catch (RuntimeException error) { messenger.accept(server, "[MCS] Failed to prepare " + pack.id() + ": " + error.getMessage()); } @@ -81,21 +82,27 @@ public void handlePackChange(Path packFolder) { if (server == null) { return; } + PackDefinition pack; + try { + pack = registry.resolvePack(packFolder); + } catch (IOException error) { + messenger.accept(server, "[MCS] Failed to resolve " + packFolder.getFileName() + ": " + error.getMessage()); + return; + } + if (pack == null) { + return; + } + long generation = generations.merge(pack.id(), 1L, Long::sum); executor.submit(() -> { try { - PackDefinition pack = registry.resolvePack(packFolder); - if (pack == null) { - return; - } - processPack(server, pack, true); + processPack(server, pack, true, generation); } catch (Exception error) { messenger.accept(server, "[MCS] Failed to process " + packFolder.getFileName() + ": " + error.getMessage()); } }); } - private void processPack(MinecraftServer server, PackDefinition pack, boolean reloadAfterDeploy) { - long generation = generations.merge(pack.id(), 1L, Long::sum); + private void processPack(MinecraftServer server, PackDefinition pack, boolean reloadAfterDeploy, long generation) { messenger.accept(server, "[MCS] Processing " + pack.id() + "…"); if (!runToolchain(pack, generation)) { return; diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java index 19db5d3..4b5e19c 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/registry/PackRegistry.java @@ -58,7 +58,7 @@ public PackDefinition resolvePack(Path folder) throws IOException { id, folder, entry, - SafePaths.resolveChild(compiledRoot, displayName), + SafePaths.resolveChild(compiledRoot, id), displayName ); } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java index b46bf91..bddf7b9 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -10,8 +10,9 @@ import java.util.Locale; public final class CompilerResolver { - private static String cachedKey; - private static CompilerCommand cachedCommand; + private static final Object CACHE_LOCK = new Object(); + private static volatile String cachedKey; + private static volatile CompilerCommand cachedCommand; private CompilerResolver() { } @@ -32,13 +33,15 @@ List toProcessCommand(List args) { public static CompilerCommand resolve(ModConfig config) { String key = (config.compiler == null ? "auto" : config.compiler) + "|" + config.compilerPath; - if (key.equals(cachedKey) && cachedCommand != null) { - return cachedCommand; + synchronized (CACHE_LOCK) { + if (key.equals(cachedKey) && cachedCommand != null) { + return cachedCommand; + } + CompilerCommand resolved = resolveUncached(config); + cachedKey = key; + cachedCommand = resolved; + return resolved; } - CompilerCommand resolved = resolveUncached(config); - cachedKey = key; - cachedCommand = resolved; - return resolved; } private static CompilerCommand resolveUncached(ModConfig config) { @@ -79,7 +82,21 @@ private static CompilerCommand resolveAuto() { private static CompilerCommand resolvePython() { if (System.getenv("PYTHON") != null && Files.isExecutable(Path.of(System.getenv("PYTHON")))) { - return pythonCommand(System.getenv("PYTHON")); + CompilerCommand resolved = pythonCommand(System.getenv("PYTHON")); + if (canRun(resolved, "lint", "--help")) { + return resolved; + } + } + for (String version : List.of("313", "312", "311", "310")) { + for (Path candidate : knownPythonInstalls(version)) { + if (!Files.isExecutable(candidate)) { + continue; + } + CompilerCommand resolved = pythonCommand(candidate.toString()); + if (canRun(resolved, "lint", "--help")) { + return resolved; + } + } } for (String candidate : List.of("python", "python3", "py")) { CompilerCommand resolved = "py".equals(candidate) @@ -89,17 +106,27 @@ private static CompilerCommand resolvePython() { return resolved; } } - for (String version : List.of("313", "312", "311", "310")) { - Path candidate = Path.of("C:\\Python" + version + "\\python.exe"); - if (!Files.isExecutable(candidate)) { - continue; + return pythonCommand("python"); + } + + private static List knownPythonInstalls(String version) { + List candidates = new ArrayList<>(); + if (isWindows()) { + String localAppData = System.getenv("LOCALAPPDATA"); + String programFiles = System.getenv("PROGRAMFILES"); + candidates.add(Path.of("C:\\Python" + version + "\\python.exe")); + if (localAppData != null) { + candidates.add(Path.of(localAppData, "Programs", "Python", "Python" + version, "python.exe")); + candidates.add(Path.of(localAppData, "Microsoft", "WindowsApps", "python.exe")); } - CompilerCommand resolved = pythonCommand(candidate.toString()); - if (canRun(resolved, "lint", "--help")) { - return resolved; + if (programFiles != null) { + candidates.add(Path.of(programFiles, "Python" + version, "python.exe")); } + } else { + candidates.add(Path.of("/usr/local/bin/python" + version)); + candidates.add(Path.of("/usr/bin/python" + version)); } - return pythonCommand("python"); + return candidates; } private static CompilerCommand pythonCommand(String executable) { @@ -120,6 +147,9 @@ private static boolean canRun(CompilerCommand compiler, String... args) { try { ProcessResult result = SubprocessRunner.run(compiler.toProcessCommand(List.of(args)), null, 15); return result.success(); + } catch (InterruptedException error) { + Thread.currentThread().interrupt(); + return false; } catch (Exception ignored) { return false; } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java index 3cf0df3..03d8f6f 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -127,9 +127,13 @@ private static void deleteRecursive(Path path) throws IOException { } if (Files.isDirectory(path)) { try (var stream = Files.list(path)) { - for (Path child : stream.toList()) { - deleteRecursive(child); - } + stream.forEach(child -> { + try { + deleteRecursive(child); + } catch (IOException error) { + throw new RuntimeException(error); + } + }); } } Files.deleteIfExists(path); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java index e690de1..b1775a1 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java @@ -20,12 +20,20 @@ public static ProcessResult run(List command, Path workingDirectory, lon Process process = builder.start(); CompletableFuture stdoutFuture = CompletableFuture.supplyAsync(() -> readStream(process.getInputStream())); CompletableFuture stderrFuture = CompletableFuture.supplyAsync(() -> readStream(process.getErrorStream())); - boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS); - if (!finished) { + try { + boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS); + if (!finished) { + process.destroyForcibly(); + process.waitFor(); + return new ProcessResult(-1, "", "Process timed out after " + timeoutSeconds + "s"); + } + return new ProcessResult(process.exitValue(), stdoutFuture.join(), stderrFuture.join()); + } catch (InterruptedException error) { process.destroyForcibly(); - return new ProcessResult(-1, "", "Process timed out after " + timeoutSeconds + "s"); + process.waitFor(); + Thread.currentThread().interrupt(); + return new ProcessResult(-1, "", "Process interrupted"); } - return new ProcessResult(process.exitValue(), stdoutFuture.join(), stderrFuture.join()); } private static String readStream(java.io.InputStream stream) { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java index 2e66bf9..da34c8f 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java @@ -5,6 +5,7 @@ import java.io.InputStream; import java.nio.file.Files; import java.nio.file.Path; +import java.util.Locale; public final class McsPaths { public static final String PACKS_DIR = "mcs_packs"; @@ -32,15 +33,21 @@ public static Path compiledRoot() { } public static Path compilerWrapper() throws IOException { + boolean windows = isWindows(); + String resourceName = windows ? "/scripts/mcs-compile.cmd" : "/scripts/mcs-compile.sh"; + String fileName = windows ? "mcs-compile.cmd" : "mcs-compile.sh"; Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); Files.createDirectories(scriptsDir); - Path wrapper = scriptsDir.resolve("mcs-compile.cmd"); - try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-compile.cmd")) { + Path wrapper = scriptsDir.resolve(fileName); + try (InputStream stream = McsPaths.class.getResourceAsStream(resourceName)) { if (stream == null) { - throw new IOException("Bundled MCS compiler wrapper is missing from the mod JAR"); + throw new IOException("Bundled MCS compiler wrapper is missing from the mod JAR: " + resourceName); } Files.copy(stream, wrapper, java.nio.file.StandardCopyOption.REPLACE_EXISTING); } + if (!windows) { + wrapper.toFile().setExecutable(true, false); + } return wrapper; } @@ -48,10 +55,14 @@ public static Path spyglassScript() throws IOException { Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); Files.createDirectories(scriptsDir); Path script = scriptsDir.resolve("mcs-spyglass-validate.js"); - try (InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.js")) { - if (stream == null) { - throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); - } + InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.mjs"); + if (stream == null) { + stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.js"); + } + if (stream == null) { + throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); + } + try (stream) { Files.copy(stream, script, java.nio.file.StandardCopyOption.REPLACE_EXISTING); } return script; @@ -86,4 +97,9 @@ public static void ensureLayout() { throw new IllegalStateException("Failed to initialize mcs_packs folders", error); } } + + private static boolean isWindows() { + String os = System.getProperty("os.name", ""); + return os.toLowerCase(Locale.ROOT).contains("win"); + } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java index 0488ffb..552c5fc 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/PlayerFeedback.java @@ -10,8 +10,10 @@ private PlayerFeedback() { } public static void broadcast(MinecraftServer server, String message) { - Component component = Component.literal(message); - server.getPlayerList().broadcastSystemMessage(component, false); + server.submit(() -> { + Component component = Component.literal(message); + server.getPlayerList().broadcastSystemMessage(component, false); + }); } public static void diagnostics(MinecraftServer server, String prefix, List diagnostics) { diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java index f428fa6..2d84deb 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/version/VersionMapper.java @@ -23,6 +23,12 @@ public static VersionMapper load() { throw new IllegalStateException("Missing mcs-versions.json resource"); } Index index = new Gson().fromJson(new InputStreamReader(stream, StandardCharsets.UTF_8), Index.class); + if (index == null || index.supported == null || index.supported.isEmpty()) { + throw new IllegalStateException("mcs-versions.json must define a non-empty supported version list"); + } + if (index.profiles == null || index.profiles.isEmpty()) { + throw new IllegalStateException("mcs-versions.json must define a non-empty profiles map"); + } return new VersionMapper(index.supported, index.profiles); } catch (Exception error) { throw new IllegalStateException("Failed to load MCS version index", error); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java index 30dc5ee..ebb1482 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/watch/PackWatcher.java @@ -147,6 +147,9 @@ private void pollEntryFiles() { } Path entry = packFolder.resolve(McsPaths.DEFAULT_ENTRY); if (!Files.exists(entry)) { + if (lastModified.remove(entry) != null) { + schedule(packFolder); + } continue; } long modified = Files.getLastModifiedTime(entry).toMillis(); @@ -191,7 +194,13 @@ private Path resolvePackFolder(Path changedPath) { while (current != null && current.startsWith(packsRoot) && !packsRoot.equals(current)) { if (isPackFolder(current)) { Path entry = current.resolve(McsPaths.DEFAULT_ENTRY); - return Files.exists(entry) ? current : null; + if (Files.exists(entry)) { + return current; + } + if (lastModified.containsKey(entry)) { + return current; + } + return null; } current = current.getParent(); } diff --git a/mod/common/src/main/resources/scripts/mcs-compile.cmd b/mod/common/src/main/resources/scripts/mcs-compile.cmd index 789d916..0fd6823 100644 --- a/mod/common/src/main/resources/scripts/mcs-compile.cmd +++ b/mod/common/src/main/resources/scripts/mcs-compile.cmd @@ -1,61 +1,73 @@ -@echo off -setlocal EnableExtensions EnableDelayedExpansion -where mcs >nul 2>&1 && ( - call :run_mcs %* - exit /b !ERRORLEVEL! -) -where python >nul 2>&1 && ( - call :run_python python %* - exit /b !ERRORLEVEL! -) -where py >nul 2>&1 && ( - call :run_py %* - exit /b !ERRORLEVEL! -) -if defined PYTHON if exist "%PYTHON%" ( - call :run_python "%PYTHON%" %* - exit /b !ERRORLEVEL! -) -for %%P in (313 312 311 310) do ( - if exist "C:\Python%%P\python.exe" ( - call :run_python "C:\Python%%P\python.exe" %* - exit /b !ERRORLEVEL! - ) -) -echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 -exit /b 1 - -:run_mcs -set "ARGS=" -:quote_mcs -if "%~1"=="" goto exec_mcs -set "ARGS=%ARGS% "%~1"" -shift -goto quote_mcs -:exec_mcs -mcs %ARGS% -exit /b %ERRORLEVEL% - -:run_python -set "PY=%~1" -shift -set "ARGS=" -:quote_py -if "%~1"=="" goto exec_py -set "ARGS=%ARGS% "%~1"" -shift -goto quote_py -:exec_py -"%PY%" -m minecraft_script %ARGS% -exit /b %ERRORLEVEL% - -:run_py -set "ARGS=" -:quote_py_launcher -if "%~1"=="" goto exec_py_launcher -set "ARGS=%ARGS% "%~1"" -shift -goto quote_py_launcher -:exec_py_launcher -py -3 -m minecraft_script %ARGS% -exit /b %ERRORLEVEL% +@echo off +setlocal EnableExtensions EnableDelayedExpansion +where mcs >nul 2>&1 && ( + call :run_mcs %* + exit /b !ERRORLEVEL! +) +if defined PYTHON if exist "%PYTHON%" ( + call :run_python "%PYTHON%" %* + exit /b !ERRORLEVEL! +) +for %%P in (313 312 311 310) do ( + if exist "C:\Python%%P\python.exe" ( + call :run_python "C:\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) + if exist "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" ( + call :run_python "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) + if exist "%PROGRAMFILES%\Python%%P\python.exe" ( + call :run_python "%PROGRAMFILES%\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) +) +if exist "%LOCALAPPDATA%\Microsoft\WindowsApps\python.exe" ( + call :run_python "%LOCALAPPDATA%\Microsoft\WindowsApps\python.exe" %* + exit /b !ERRORLEVEL! +) +where python >nul 2>&1 && ( + call :run_python python %* + exit /b !ERRORLEVEL! +) +where py >nul 2>&1 && ( + call :run_py %* + exit /b !ERRORLEVEL! +) +echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 +exit /b 1 + +:run_mcs +set "ARGS=" +:quote_mcs +if "%~1"=="" goto exec_mcs +set "ARGS=%ARGS% "%~1"" +shift +goto quote_mcs +:exec_mcs +mcs %ARGS% +exit /b %ERRORLEVEL% + +:run_python +set "PY=%~1" +shift +set "ARGS=" +:quote_py +if "%~1"=="" goto exec_py +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py +:exec_py +"%PY%" -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% + +:run_py +set "ARGS=" +:quote_py_launcher +if "%~1"=="" goto exec_py_launcher +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py_launcher +:exec_py_launcher +py -3 -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% diff --git a/mod/common/src/main/resources/scripts/mcs-compile.sh b/mod/common/src/main/resources/scripts/mcs-compile.sh new file mode 100644 index 0000000..8c0259a --- /dev/null +++ b/mod/common/src/main/resources/scripts/mcs-compile.sh @@ -0,0 +1,38 @@ +#!/bin/sh +set -e + +if command -v mcs >/dev/null 2>&1; then + exec mcs "$@" +fi + +if [ -n "$PYTHON" ] && [ -x "$PYTHON" ]; then + exec "$PYTHON" -m minecraft_script "$@" +fi + +for version in 313 312 311 310; do + for candidate in \ + "/c/Python${version}/python.exe" \ + "$LOCALAPPDATA/Programs/Python/Python${version}/python.exe" \ + "$PROGRAMFILES/Python${version}/python.exe" \ + "/usr/local/bin/python${version}" \ + "/usr/bin/python${version}"; do + if [ -x "$candidate" ]; then + exec "$candidate" -m minecraft_script "$@" + fi + done +done + +if command -v python3 >/dev/null 2>&1; then + exec python3 -m minecraft_script "$@" +fi + +if command -v python >/dev/null 2>&1; then + exec python -m minecraft_script "$@" +fi + +if command -v py >/dev/null 2>&1; then + exec py -3 -m minecraft_script "$@" +fi + +echo "MCS compiler not found. Install minecraft-script (pip install -e .) or set compilerPath in config/mcs-packs.json." >&2 +exit 1 diff --git a/mod/fabric/build.gradle b/mod/fabric/build.gradle index bb2aaec..c98c1a6 100644 --- a/mod/fabric/build.gradle +++ b/mod/fabric/build.gradle @@ -43,9 +43,13 @@ processResources { inputs.property 'mod_version', project.version inputs.property 'minecraft_version', rootProject.minecraft_version inputs.property 'supported_game_versions', rootProject.supportedGameVersions + inputs.property 'architectury_api_version', rootProject.architectury_api_version + inputs.property 'fabric_api_version', rootProject.fabric_api_version filesMatching('fabric.mod.json') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, - 'supported_game_versions': rootProject.supportedGameVersions + 'supported_game_versions': rootProject.supportedGameVersions, + 'architectury_api_version': rootProject.architectury_api_version, + 'fabric_api_version': rootProject.fabric_api_version } } diff --git a/mod/fabric/src/main/resources/fabric.mod.json b/mod/fabric/src/main/resources/fabric.mod.json index 2d510dc..9677c8a 100644 --- a/mod/fabric/src/main/resources/fabric.mod.json +++ b/mod/fabric/src/main/resources/fabric.mod.json @@ -14,7 +14,7 @@ "fabricloader": ">=0.16.0", "minecraft": "${minecraft_version}", "java": ">=21", - "architectury": "*", - "fabric-api": "*" + "architectury": ">=${architectury_api_version}", + "fabric-api": ">=${fabric_api_version}" } } diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle index 7f7e21b..3ff02c1 100644 --- a/mod/forge/build.gradle +++ b/mod/forge/build.gradle @@ -23,7 +23,7 @@ configurations { dependencies { forge "net.minecraftforge:forge:${rootProject.minecraft_version}-${rootProject.forge_version}" - modImplementation "dev.architectury:architectury-forge:${rootProject.architectury_api_version}" + modImplementation "dev.architectury:architectury-neoforge:${rootProject.architectury_api_version}" common(project(path: ':common', configuration: 'namedElements')) { transitive false } shadowCommon(project(path: ':common', configuration: 'transformProductionForge')) { transitive false } @@ -44,15 +44,45 @@ remapJar { archiveClassifier = null } +def nextMinecraftVersion = { + def version = rootProject.minecraft_version + def modern = (version =~ /^2[6-9]\.(\d+)$/) + if (modern.matches()) { + return "${modern[0][0].split('\\.')[0]}.${modern[0][1].toInteger() + 1}" + } + def release = (version =~ /^(\d+)\.(\d+)\.(\d+)$/) + if (release.matches()) { + return "${release[0][1]}.${release[0][2]}.${release[0][3].toInteger() + 1}" + } + return version +}() + +def nextForgeVersion = { + def version = rootProject.forge_version + def match = (version =~ /^(\d+)\./) + return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version +}() + +def nextArchitecturyVersion = { + def version = rootProject.architectury_api_version + def match = (version =~ /^(\d+)\./) + return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version +}() + processResources { inputs.property 'mod_version', project.version inputs.property 'minecraft_version', rootProject.minecraft_version inputs.property 'supported_game_versions', rootProject.supportedGameVersions inputs.property 'forge_version', rootProject.forge_version + inputs.property 'architectury_api_version', rootProject.architectury_api_version filesMatching('META-INF/mods.toml') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, 'forge_version': rootProject.forge_version, + 'minecraft_version_upper': nextMinecraftVersion, + 'forge_version_upper': nextForgeVersion, + 'architectury_api_version': rootProject.architectury_api_version, + 'architectury_api_version_upper': nextArchitecturyVersion, 'supported_game_versions': rootProject.supportedGameVersions } } diff --git a/mod/forge/src/main/resources/META-INF/mods.toml b/mod/forge/src/main/resources/META-INF/mods.toml index 13819fa..2050bc4 100644 --- a/mod/forge/src/main/resources/META-INF/mods.toml +++ b/mod/forge/src/main/resources/META-INF/mods.toml @@ -1,5 +1,5 @@ modLoader = "javafml" -loaderVersion = "[4,)" +loaderVersion = "[4,5)" license = "MIT" issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" @@ -13,20 +13,20 @@ authors = "SpyC0der77" [[dependencies.mcs_packs]] modId = "forge" mandatory = true -versionRange = "[${forge_version},)" +versionRange = "[${forge_version},${forge_version_upper})" ordering = "NONE" side = "BOTH" [[dependencies.mcs_packs]] modId = "minecraft" mandatory = true -versionRange = "[${minecraft_version},)" +versionRange = "[${minecraft_version},${minecraft_version_upper})" ordering = "NONE" side = "BOTH" [[dependencies.mcs_packs]] modId = "architectury" mandatory = true -versionRange = "[0,)" +versionRange = "[${architectury_api_version},${architectury_api_version_upper})" ordering = "AFTER" side = "BOTH" diff --git a/mod/gradle.properties b/mod/gradle.properties index 16bcbf1..e42c4fb 100644 --- a/mod/gradle.properties +++ b/mod/gradle.properties @@ -2,10 +2,10 @@ org.gradle.jvmargs=-Xmx4G org.gradle.parallel=true org.gradle.daemon=false -mcs_profile=1.21.11 -minecraft_version=1.21.11 -mcs_minecraft_profile=1.21.11 -supported_game_versions=1.21.11 +mcs_profile=1.21.2 +minecraft_version=1.21.2 +mcs_minecraft_profile=1.21.2 +supported_game_versions=1.21.2 architectury_plugin_version=3.4-SNAPSHOT architectury_loom_version=1.13-SNAPSHOT @@ -16,10 +16,10 @@ maven_group=dev.spyc0der77 archives_base_name=mcs-packs mod_id=mcs_packs -fabric_loader_version=0.18.4 -fabric_api_version=0.140.2+1.21.11 -forge_version=61.1.0 -neoforge_version=21.11.42 -architectury_api_version=19.0.1 +fabric_loader_version=0.16.9 +fabric_api_version=0.106.0+1.21.2 +forge_version=52.0.28 +neoforge_version=21.2.0-beta +architectury_api_version=13.0.8 -enabled_platforms=fabric,forge,neoforge +enabled_platforms=forge diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle index f76b3bd..830b453 100644 --- a/mod/neoforge/build.gradle +++ b/mod/neoforge/build.gradle @@ -44,15 +44,45 @@ remapJar { archiveClassifier = null } +def nextMinecraftVersion = { + def version = rootProject.minecraft_version + def modern = (version =~ /^2[6-9]\.(\d+)$/) + if (modern.matches()) { + return "${modern[0][0].split('\\.')[0]}.${modern[0][1].toInteger() + 1}" + } + def release = (version =~ /^(\d+)\.(\d+)\.(\d+)$/) + if (release.matches()) { + return "${release[0][1]}.${release[0][2]}.${release[0][3].toInteger() + 1}" + } + return version +}() + +def nextNeoForgeVersion = { + def version = rootProject.neoforge_version + def match = (version =~ /^(\d+)\./) + return match.matches() ? "${match[0][1].toInteger() + 1}.0.0-beta" : version +}() + +def nextArchitecturyVersion = { + def version = rootProject.architectury_api_version + def match = (version =~ /^(\d+)\./) + return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version +}() + processResources { inputs.property 'mod_version', project.version inputs.property 'minecraft_version', rootProject.minecraft_version inputs.property 'supported_game_versions', rootProject.supportedGameVersions inputs.property 'neoforge_version', rootProject.neoforge_version + inputs.property 'architectury_api_version', rootProject.architectury_api_version filesMatching('META-INF/neoforge.mods.toml') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, 'neoforge_version': rootProject.neoforge_version, + 'minecraft_version_upper': nextMinecraftVersion, + 'neoforge_version_upper': nextNeoForgeVersion, + 'architectury_api_version': rootProject.architectury_api_version, + 'architectury_api_version_upper': nextArchitecturyVersion, 'supported_game_versions': rootProject.supportedGameVersions } } diff --git a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml index 32af25d..a0a3542 100644 --- a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml +++ b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -1,5 +1,5 @@ modLoader = "javafml" -loaderVersion = "[1,)" +loaderVersion = "[1,2)" license = "MIT" issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" @@ -13,20 +13,20 @@ authors = "SpyC0der77" [[dependencies.mcs_packs]] modId = "neoforge" type = "required" -versionRange = "[${neoforge_version},)" +versionRange = "[${neoforge_version},${neoforge_version_upper})" ordering = "NONE" side = "BOTH" [[dependencies.mcs_packs]] modId = "minecraft" type = "required" -versionRange = "[${minecraft_version},)" +versionRange = "[${minecraft_version},${minecraft_version_upper})" ordering = "NONE" side = "BOTH" [[dependencies.mcs_packs]] modId = "architectury" type = "required" -versionRange = "[0,)" +versionRange = "[${architectury_api_version},${architectury_api_version_upper})" ordering = "AFTER" side = "BOTH" diff --git a/mod/scripts/apply_version.py b/mod/scripts/apply_version.py index 43843ec..e1c7b02 100644 --- a/mod/scripts/apply_version.py +++ b/mod/scripts/apply_version.py @@ -13,17 +13,6 @@ DEFAULT_ENABLED_PLATFORMS = "fabric,forge,neoforge" -def read_enabled_platforms() -> str: - if not GRADLE_PROPERTIES.exists(): - return DEFAULT_ENABLED_PLATFORMS - for line in GRADLE_PROPERTIES.read_text(encoding="utf-8").splitlines(): - if line.startswith("enabled_platforms="): - value = line.split("=", 1)[1].strip() - if value and value != "fabric": - return value - return DEFAULT_ENABLED_PLATFORMS - - def main() -> int: parser = argparse.ArgumentParser(description=__doc__) parser.add_argument("profile", help="MCS profile key from versions/manifest.json") @@ -65,7 +54,7 @@ def main() -> int: f"neoforge_version={profile['neoforge_version']}", f"architectury_api_version={profile['architectury_api_version']}", "", - f"enabled_platforms={args.loader if args.loader else read_enabled_platforms()}", + f"enabled_platforms={args.loader if args.loader else DEFAULT_ENABLED_PLATFORMS}", ] GRADLE_PROPERTIES.write_text("\n".join(lines) + "\n", encoding="utf-8") print(f"Wrote {GRADLE_PROPERTIES} for profile {args.profile}") diff --git a/mod/scripts/mcs-spyglass-validate.mjs b/mod/scripts/mcs-spyglass-validate.mjs index 6c296a7..2ef0805 100644 --- a/mod/scripts/mcs-spyglass-validate.mjs +++ b/mod/scripts/mcs-spyglass-validate.mjs @@ -28,7 +28,11 @@ function parseArgs(argv) { continue } if (arg === '--mc-version') { - flags.mcVersion = argv[index + 1] + const value = argv[index + 1] + if (!value || value.startsWith('-')) { + throw new Error('Missing value for --mc-version') + } + flags.mcVersion = value index += 1 continue } @@ -166,7 +170,7 @@ async function main() { const unique = new Map() for (const diagnostic of diagnostics) { - const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}` + const key = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.severity || diagnostic.level}:${diagnostic.message}` unique.set(key, diagnostic) } const result = [...unique.values()].sort((left, right) => { diff --git a/mod/scripts/package.json b/mod/scripts/package.json index b3a356f..8cbb58c 100644 --- a/mod/scripts/package.json +++ b/mod/scripts/package.json @@ -3,7 +3,7 @@ "private": true, "type": "module", "scripts": { - "bundle:spyglass": "esbuild mcs-spyglass-validate.mjs --bundle --platform=node --format=cjs --packages=bundle --outfile=../common/src/main/resources/scripts/mcs-spyglass-validate.js --banner:js=\"#!/usr/bin/env node\"" + "bundle:spyglass": "esbuild mcs-spyglass-validate.mjs --bundle --platform=node --format=cjs --packages=bundle --outfile=../common/build/generated/resources/main/scripts/mcs-spyglass-validate.js --banner:js=\"#!/usr/bin/env node\"" }, "dependencies": { "@spyglassmc/core": "^0.4.47", diff --git a/mod/versions/manifest.json b/mod/versions/manifest.json index 465dc0a..222da9b 100644 --- a/mod/versions/manifest.json +++ b/mod/versions/manifest.json @@ -8,7 +8,7 @@ "fabric_loader_version": "0.16.9", "fabric_api_version": "0.106.0+1.21.2", "forge_version": "52.0.28", - "neoforge_version": "21.1.80", + "neoforge_version": "21.2.0-beta", "architectury_api_version": "13.0.8" }, "1.21.4": { diff --git a/tests/test_compile_cli_flags.py b/tests/test_compile_cli_flags.py index a3e7e0f..a5cf630 100644 --- a/tests/test_compile_cli_flags.py +++ b/tests/test_compile_cli_flags.py @@ -89,6 +89,9 @@ def test_compile_mc_version_does_not_mutate_config(build_output): ) assert result.returncode == 0, result.stderr assert COMMON_CONFIG["minecraft_version"] == original_version + with open(f"{module_folder}/config.json", encoding="utf-8") as config_file: + persisted_config = json.loads(config_file.read()) + assert persisted_config["minecraft_version"] == original_version finally: if build_output.exists(): shutil.rmtree(build_output, ignore_errors=True) From 8d4c593b706c4a45513d7c6fd813938d50967973 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 13:45:05 -0400 Subject: [PATCH 08/12] Update platform support and improve build scripts - Modified `gradle.properties` to enable support for multiple platforms: fabric, forge, and neoforge. - Updated `build.gradle` scripts to streamline version management for Forge and NeoForge. - Enhanced `ModConfigManager` to handle atomic file moves with fallback for unsupported operations. - Refactored `mcs-compile` scripts for improved Python version detection and execution. - Cleaned up unnecessary candidate paths in `CompilerResolver` and improved error handling in `McsPaths`. - Adjusted loader version constraints in `mods.toml` files for Forge and NeoForge. --- mod/common/build.gradle | 2 +- .../mcspacks/config/ModConfigManager.java | 7 +- .../mcspacks/toolchain/CompilerResolver.java | 1 - .../mcspacks/toolchain/McsToolchain.java | 11 +- .../spyc0der77/mcspacks/util/McsPaths.java | 4 +- .../main/resources/scripts/mcs-compile.cmd | 142 +++++++++--------- .../src/main/resources/scripts/mcs-compile.sh | 7 +- mod/forge/build.gradle | 16 +- .../src/main/resources/META-INF/mods.toml | 2 +- mod/gradle.properties | 2 +- mod/neoforge/build.gradle | 16 +- .../resources/META-INF/neoforge.mods.toml | 2 +- 12 files changed, 102 insertions(+), 110 deletions(-) diff --git a/mod/common/build.gradle b/mod/common/build.gradle index 9cc7ae0..6463cbf 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -68,7 +68,7 @@ tasks.register('bundleSpyglassScript') { if (bunAvailable) { commandLine 'bun', 'run', 'bundle:spyglass' } else { - commandLine 'npx', '--no-install', 'esbuild', 'mcs-spyglass-validate.mjs', + commandLine 'npx', '--yes', 'esbuild@0.25.5', 'mcs-spyglass-validate.mjs', '--bundle', '--platform=node', '--format=cjs', '--packages=bundle', "--outfile=${spyglassBundledScript.get().asFile}", '--banner:js=#!/usr/bin/env node' diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java index 5d926a4..8d91dcc 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/config/ModConfigManager.java @@ -5,6 +5,7 @@ import com.google.gson.JsonParseException; import dev.spyc0der77.mcspacks.util.McsPaths; import java.io.IOException; +import java.nio.file.AtomicMoveNotSupportedException; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.StandardCopyOption; @@ -40,7 +41,11 @@ public static void save(ModConfig config) throws IOException { Path tempFile = Files.createTempFile(configFile.getParent(), "mcs-packs-", ".json.tmp"); try { Files.writeString(tempFile, GSON.toJson(config)); - Files.move(tempFile, configFile, StandardCopyOption.ATOMIC_MOVE, StandardCopyOption.REPLACE_EXISTING); + try { + Files.move(tempFile, configFile, StandardCopyOption.ATOMIC_MOVE, StandardCopyOption.REPLACE_EXISTING); + } catch (AtomicMoveNotSupportedException error) { + Files.move(tempFile, configFile, StandardCopyOption.REPLACE_EXISTING); + } } finally { Files.deleteIfExists(tempFile); } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java index bddf7b9..2606a08 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -117,7 +117,6 @@ private static List knownPythonInstalls(String version) { candidates.add(Path.of("C:\\Python" + version + "\\python.exe")); if (localAppData != null) { candidates.add(Path.of(localAppData, "Programs", "Python", "Python" + version, "python.exe")); - candidates.add(Path.of(localAppData, "Microsoft", "WindowsApps", "python.exe")); } if (programFiles != null) { candidates.add(Path.of(programFiles, "Python" + version, "python.exe")); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java index 03d8f6f..7f30c59 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -127,13 +127,10 @@ private static void deleteRecursive(Path path) throws IOException { } if (Files.isDirectory(path)) { try (var stream = Files.list(path)) { - stream.forEach(child -> { - try { - deleteRecursive(child); - } catch (IOException error) { - throw new RuntimeException(error); - } - }); + var iterator = stream.iterator(); + while (iterator.hasNext()) { + deleteRecursive(iterator.next()); + } } } Files.deleteIfExists(path); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java index da34c8f..0a5d3ea 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java @@ -45,8 +45,8 @@ public static Path compilerWrapper() throws IOException { } Files.copy(stream, wrapper, java.nio.file.StandardCopyOption.REPLACE_EXISTING); } - if (!windows) { - wrapper.toFile().setExecutable(true, false); + if (!windows && !wrapper.toFile().setExecutable(true, false)) { + throw new IOException("Failed to mark MCS compiler wrapper as executable: " + wrapper); } return wrapper; } diff --git a/mod/common/src/main/resources/scripts/mcs-compile.cmd b/mod/common/src/main/resources/scripts/mcs-compile.cmd index 0fd6823..98ff0e1 100644 --- a/mod/common/src/main/resources/scripts/mcs-compile.cmd +++ b/mod/common/src/main/resources/scripts/mcs-compile.cmd @@ -1,73 +1,69 @@ -@echo off -setlocal EnableExtensions EnableDelayedExpansion -where mcs >nul 2>&1 && ( - call :run_mcs %* - exit /b !ERRORLEVEL! -) -if defined PYTHON if exist "%PYTHON%" ( - call :run_python "%PYTHON%" %* - exit /b !ERRORLEVEL! -) -for %%P in (313 312 311 310) do ( - if exist "C:\Python%%P\python.exe" ( - call :run_python "C:\Python%%P\python.exe" %* - exit /b !ERRORLEVEL! - ) - if exist "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" ( - call :run_python "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" %* - exit /b !ERRORLEVEL! - ) - if exist "%PROGRAMFILES%\Python%%P\python.exe" ( - call :run_python "%PROGRAMFILES%\Python%%P\python.exe" %* - exit /b !ERRORLEVEL! - ) -) -if exist "%LOCALAPPDATA%\Microsoft\WindowsApps\python.exe" ( - call :run_python "%LOCALAPPDATA%\Microsoft\WindowsApps\python.exe" %* - exit /b !ERRORLEVEL! -) -where python >nul 2>&1 && ( - call :run_python python %* - exit /b !ERRORLEVEL! -) -where py >nul 2>&1 && ( - call :run_py %* - exit /b !ERRORLEVEL! -) -echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 -exit /b 1 - -:run_mcs -set "ARGS=" -:quote_mcs -if "%~1"=="" goto exec_mcs -set "ARGS=%ARGS% "%~1"" -shift -goto quote_mcs -:exec_mcs -mcs %ARGS% -exit /b %ERRORLEVEL% - -:run_python -set "PY=%~1" -shift -set "ARGS=" -:quote_py -if "%~1"=="" goto exec_py -set "ARGS=%ARGS% "%~1"" -shift -goto quote_py -:exec_py -"%PY%" -m minecraft_script %ARGS% -exit /b %ERRORLEVEL% - -:run_py -set "ARGS=" -:quote_py_launcher -if "%~1"=="" goto exec_py_launcher -set "ARGS=%ARGS% "%~1"" -shift -goto quote_py_launcher -:exec_py_launcher -py -3 -m minecraft_script %ARGS% -exit /b %ERRORLEVEL% +@echo off +setlocal EnableExtensions EnableDelayedExpansion +where mcs >nul 2>&1 && ( + call :run_mcs %* + exit /b !ERRORLEVEL! +) +if defined PYTHON if exist "%PYTHON%" ( + call :run_python "%PYTHON%" %* + exit /b !ERRORLEVEL! +) +for %%P in (313 312 311 310) do ( + if exist "C:\Python%%P\python.exe" ( + call :run_python "C:\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) + if exist "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" ( + call :run_python "%LOCALAPPDATA%\Programs\Python\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) + if exist "%PROGRAMFILES%\Python%%P\python.exe" ( + call :run_python "%PROGRAMFILES%\Python%%P\python.exe" %* + exit /b !ERRORLEVEL! + ) +) +where python >nul 2>&1 && ( + call :run_python python %* + exit /b !ERRORLEVEL! +) +where py >nul 2>&1 && ( + call :run_py %* + exit /b !ERRORLEVEL! +) +echo MCS compiler not found. Install minecraft-script ^(pip install -e .^) or set compilerPath in config/mcs-packs.json. 1>&2 +exit /b 1 + +:run_mcs +set "ARGS=" +:quote_mcs +if "%~1"=="" goto exec_mcs +set "ARGS=%ARGS% "%~1"" +shift +goto quote_mcs +:exec_mcs +mcs %ARGS% +exit /b %ERRORLEVEL% + +:run_python +set "PY=%~1" +shift +set "ARGS=" +:quote_py +if "%~1"=="" goto exec_py +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py +:exec_py +"%PY%" -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% + +:run_py +set "ARGS=" +:quote_py_launcher +if "%~1"=="" goto exec_py_launcher +set "ARGS=%ARGS% "%~1"" +shift +goto quote_py_launcher +:exec_py_launcher +py -3 -m minecraft_script %ARGS% +exit /b %ERRORLEVEL% diff --git a/mod/common/src/main/resources/scripts/mcs-compile.sh b/mod/common/src/main/resources/scripts/mcs-compile.sh index 8c0259a..661799c 100644 --- a/mod/common/src/main/resources/scripts/mcs-compile.sh +++ b/mod/common/src/main/resources/scripts/mcs-compile.sh @@ -10,12 +10,15 @@ if [ -n "$PYTHON" ] && [ -x "$PYTHON" ]; then fi for version in 313 312 311 310; do + dotted_version="${version%??}.${version#?}" for candidate in \ "/c/Python${version}/python.exe" \ "$LOCALAPPDATA/Programs/Python/Python${version}/python.exe" \ "$PROGRAMFILES/Python${version}/python.exe" \ - "/usr/local/bin/python${version}" \ - "/usr/bin/python${version}"; do + "/usr/local/bin/python${dotted_version}" \ + "/usr/bin/python${dotted_version}" \ + "/usr/local/bin/python3.${version#?}" \ + "/usr/bin/python3.${version#?}"; do if [ -x "$candidate" ]; then exec "$candidate" -m minecraft_script "$@" fi diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle index 3ff02c1..78888ec 100644 --- a/mod/forge/build.gradle +++ b/mod/forge/build.gradle @@ -57,17 +57,13 @@ def nextMinecraftVersion = { return version }() -def nextForgeVersion = { - def version = rootProject.forge_version - def match = (version =~ /^(\d+)\./) - return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version -}() +def nextMajorVersion = { String version, String suffix = '' -> + def major = version.tokenize('.')[0] + major.isInteger() ? "${major.toInteger() + 1}${suffix}" : version +} -def nextArchitecturyVersion = { - def version = rootProject.architectury_api_version - def match = (version =~ /^(\d+)\./) - return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version -}() +def nextForgeVersion = nextMajorVersion(rootProject.forge_version, '.0.0') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0') processResources { inputs.property 'mod_version', project.version diff --git a/mod/forge/src/main/resources/META-INF/mods.toml b/mod/forge/src/main/resources/META-INF/mods.toml index 2050bc4..85a6233 100644 --- a/mod/forge/src/main/resources/META-INF/mods.toml +++ b/mod/forge/src/main/resources/META-INF/mods.toml @@ -1,5 +1,5 @@ modLoader = "javafml" -loaderVersion = "[4,5)" +loaderVersion = "[4,)" license = "MIT" issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" diff --git a/mod/gradle.properties b/mod/gradle.properties index e42c4fb..c072a9e 100644 --- a/mod/gradle.properties +++ b/mod/gradle.properties @@ -22,4 +22,4 @@ forge_version=52.0.28 neoforge_version=21.2.0-beta architectury_api_version=13.0.8 -enabled_platforms=forge +enabled_platforms=fabric,forge,neoforge diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle index 830b453..90367ea 100644 --- a/mod/neoforge/build.gradle +++ b/mod/neoforge/build.gradle @@ -57,17 +57,13 @@ def nextMinecraftVersion = { return version }() -def nextNeoForgeVersion = { - def version = rootProject.neoforge_version - def match = (version =~ /^(\d+)\./) - return match.matches() ? "${match[0][1].toInteger() + 1}.0.0-beta" : version -}() +def nextMajorVersion = { String version, String suffix = '' -> + def major = version.tokenize('.')[0] + major.isInteger() ? "${major.toInteger() + 1}${suffix}" : version +} -def nextArchitecturyVersion = { - def version = rootProject.architectury_api_version - def match = (version =~ /^(\d+)\./) - return match.matches() ? "${match[0][1].toInteger() + 1}.0.0" : version -}() +def nextNeoForgeVersion = nextMajorVersion(rootProject.neoforge_version, '.0.0-beta') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0') processResources { inputs.property 'mod_version', project.version diff --git a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml index a0a3542..8415203 100644 --- a/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml +++ b/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml @@ -1,5 +1,5 @@ modLoader = "javafml" -loaderVersion = "[1,2)" +loaderVersion = "[1,)" license = "MIT" issueTrackerURL = "https://github.com/SpyC0der77/Minecraft-Script/issues" From 275feb601912bc61e3bd1774aee19dd4c4661a02 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 13:49:01 -0400 Subject: [PATCH 09/12] Refactor version management in build scripts for Forge and NeoForge - Introduced `stripPreReleaseSuffix` and `warnVersionFallback` functions to improve version handling. - Updated `nextMinecraftVersion` and `nextMajorVersion` functions to utilize the new helper methods for better version normalization and fallback warnings. - Enhanced version retrieval for `forge_version` and `neoforge_version` to include fallback handling for unrecognized formats. --- mod/forge/build.gradle | 38 +++++++++++++++++++++++++------------- mod/neoforge/build.gradle | 38 +++++++++++++++++++++++++------------- 2 files changed, 50 insertions(+), 26 deletions(-) diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle index 78888ec..2b5048b 100644 --- a/mod/forge/build.gradle +++ b/mod/forge/build.gradle @@ -44,26 +44,38 @@ remapJar { archiveClassifier = null } +def stripPreReleaseSuffix = { String version -> + version.replaceFirst(/-(?:beta|alpha|rc\d*|snapshot|pre).*$/, '') +} + +def warnVersionFallback = { String name, String version, String reason -> + logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}") + version +} + def nextMinecraftVersion = { - def version = rootProject.minecraft_version - def modern = (version =~ /^2[6-9]\.(\d+)$/) - if (modern.matches()) { - return "${modern[0][0].split('\\.')[0]}.${modern[0][1].toInteger() + 1}" + def version = stripPreReleaseSuffix(rootProject.minecraft_version) + def parts = version.tokenize('.') + if (parts.size() == 2 && parts[0].isInteger() && parts[1].isInteger() && parts[0].toInteger() >= 26) { + return "${parts[0]}.${parts[1].toInteger() + 1}" } - def release = (version =~ /^(\d+)\.(\d+)\.(\d+)$/) - if (release.matches()) { - return "${release[0][1]}.${release[0][2]}.${release[0][3].toInteger() + 1}" + if (parts.size() == 3 && parts.every { it.isInteger() }) { + return "${parts[0]}.${parts[1]}.${parts[2].toInteger() + 1}" } - return version + warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'") }() -def nextMajorVersion = { String version, String suffix = '' -> - def major = version.tokenize('.')[0] - major.isInteger() ? "${major.toInteger() + 1}${suffix}" : version +def nextMajorVersion = { String version, String suffix = '', String name = 'version' -> + def normalized = stripPreReleaseSuffix(version) + def major = normalized.tokenize('.')[0] + if (major.isInteger()) { + return "${major.toInteger() + 1}${suffix}" + } + warnVersionFallback(name, version, "unrecognized major component '${major}'") } -def nextForgeVersion = nextMajorVersion(rootProject.forge_version, '.0.0') -def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0') +def nextForgeVersion = nextMajorVersion(rootProject.forge_version, '.0.0', 'forge_version') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version') processResources { inputs.property 'mod_version', project.version diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle index 90367ea..90586e9 100644 --- a/mod/neoforge/build.gradle +++ b/mod/neoforge/build.gradle @@ -44,26 +44,38 @@ remapJar { archiveClassifier = null } +def stripPreReleaseSuffix = { String version -> + version.replaceFirst(/-(?:beta|alpha|rc\d*|snapshot|pre).*$/, '') +} + +def warnVersionFallback = { String name, String version, String reason -> + logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}") + version +} + def nextMinecraftVersion = { - def version = rootProject.minecraft_version - def modern = (version =~ /^2[6-9]\.(\d+)$/) - if (modern.matches()) { - return "${modern[0][0].split('\\.')[0]}.${modern[0][1].toInteger() + 1}" + def version = stripPreReleaseSuffix(rootProject.minecraft_version) + def parts = version.tokenize('.') + if (parts.size() == 2 && parts[0].isInteger() && parts[1].isInteger() && parts[0].toInteger() >= 26) { + return "${parts[0]}.${parts[1].toInteger() + 1}" } - def release = (version =~ /^(\d+)\.(\d+)\.(\d+)$/) - if (release.matches()) { - return "${release[0][1]}.${release[0][2]}.${release[0][3].toInteger() + 1}" + if (parts.size() == 3 && parts.every { it.isInteger() }) { + return "${parts[0]}.${parts[1]}.${parts[2].toInteger() + 1}" } - return version + warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'") }() -def nextMajorVersion = { String version, String suffix = '' -> - def major = version.tokenize('.')[0] - major.isInteger() ? "${major.toInteger() + 1}${suffix}" : version +def nextMajorVersion = { String version, String suffix = '', String name = 'version' -> + def normalized = stripPreReleaseSuffix(version) + def major = normalized.tokenize('.')[0] + if (major.isInteger()) { + return "${major.toInteger() + 1}${suffix}" + } + warnVersionFallback(name, version, "unrecognized major component '${major}'") } -def nextNeoForgeVersion = nextMajorVersion(rootProject.neoforge_version, '.0.0-beta') -def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0') +def nextNeoForgeVersion = nextMajorVersion(rootProject.neoforge_version, '.0.0-beta', 'neoforge_version') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version') processResources { inputs.property 'mod_version', project.version From bb3902d5ca828715b9e81b929d83b02ee9833856 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 13:59:04 -0400 Subject: [PATCH 10/12] Update Java version handling and improve build scripts - Modified GitHub Actions workflow to dynamically set the Java version based on the profile, allowing for better compatibility with different Minecraft versions. - Enhanced `build.gradle` files to conditionally set the required Java version based on the Minecraft version, improving version management. - Updated `McsToolchain` to use the pack ID instead of display name for better clarity. - Refactored Python version detection in `CompilerResolver` to handle version formatting more robustly. - Improved error handling in `mcs-spyglass-validate.mjs` to ensure required arguments are provided. --- .github/workflows/mod.yml | 2 +- mod/build.gradle | 8 +++++--- mod/common/build.gradle | 2 +- .../mcspacks/toolchain/CompilerResolver.java | 7 +++++-- .../mcspacks/toolchain/McsToolchain.java | 7 +++---- .../mcspacks/toolchain/SubprocessRunner.java | 10 ++++++++-- .../dev/spyc0der77/mcspacks/util/McsPaths.java | 10 +++++----- mod/fabric/build.gradle | 4 +++- mod/fabric/src/main/resources/fabric.mod.json | 2 +- mod/forge/build.gradle | 16 ++++++++-------- mod/neoforge/build.gradle | 16 ++++++++-------- mod/scripts/mcs-spyglass-validate.mjs | 6 +++++- 12 files changed, 53 insertions(+), 37 deletions(-) diff --git a/.github/workflows/mod.yml b/.github/workflows/mod.yml index 6c6e097..df531be 100644 --- a/.github/workflows/mod.yml +++ b/.github/workflows/mod.yml @@ -27,7 +27,7 @@ jobs: - uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4 with: distribution: temurin - java-version: 21 + java-version: ${{ !startsWith(matrix.profile, '1.') && '25' || '21' }} - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2 - name: Install Spyglass bundle dependencies working-directory: mod/scripts diff --git a/mod/build.gradle b/mod/build.gradle index e44149d..b46fe8b 100644 --- a/mod/build.gradle +++ b/mod/build.gradle @@ -35,6 +35,7 @@ ext { neoforge_version = findProperty('neoforge_version') architectury_api_version = findProperty('architectury_api_version') } + requiredJavaVersion = (minecraft_version ==~ /^(?:2[6-9]|[3-9]\d*)\..+/) ? 25 : 21 } allprojects { @@ -70,12 +71,13 @@ subprojects { java { withSourcesJar() - sourceCompatibility = JavaVersion.VERSION_21 - targetCompatibility = JavaVersion.VERSION_21 + def javaVersion = JavaVersion.toVersion(rootProject.requiredJavaVersion) + sourceCompatibility = javaVersion + targetCompatibility = javaVersion } tasks.withType(JavaCompile).configureEach { - it.options.release = 21 + it.options.release = rootProject.requiredJavaVersion } } diff --git a/mod/common/build.gradle b/mod/common/build.gradle index 6463cbf..9500651 100644 --- a/mod/common/build.gradle +++ b/mod/common/build.gradle @@ -1,6 +1,6 @@ def usesPermissionSetApi = { def version = rootProject.minecraft_version - if (version ==~ /2[6-9]\..+/) { + if (version ==~ /^(?:2[6-9]|[3-9]\d*)\..+/) { return true } def match = (version =~ /^1\.21\.(\d+)/) diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java index 2606a08..a79e106 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/CompilerResolver.java @@ -122,8 +122,11 @@ private static List knownPythonInstalls(String version) { candidates.add(Path.of(programFiles, "Python" + version, "python.exe")); } } else { - candidates.add(Path.of("/usr/local/bin/python" + version)); - candidates.add(Path.of("/usr/bin/python" + version)); + String dottedVersion = version.charAt(0) + "." + version.substring(1); + candidates.add(Path.of("/usr/local/bin/python" + dottedVersion)); + candidates.add(Path.of("/usr/bin/python" + dottedVersion)); + candidates.add(Path.of("/usr/local/bin/python3." + version.substring(1))); + candidates.add(Path.of("/usr/bin/python3." + version.substring(1))); } return candidates; } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java index 7f30c59..ca94004 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/McsToolchain.java @@ -66,7 +66,7 @@ public List compile(PackDefinition pack) { args.add("--no-verbose"); } args.add(pack.entryFile().toString()); - args.add(pack.displayName()); + args.add(pack.id()); args.add(McsPaths.compiledRoot().toString()); try { ProcessResult result = SubprocessRunner.run(compiler.toProcessCommand(args), pack.folder(), 300); @@ -127,9 +127,8 @@ private static void deleteRecursive(Path path) throws IOException { } if (Files.isDirectory(path)) { try (var stream = Files.list(path)) { - var iterator = stream.iterator(); - while (iterator.hasNext()) { - deleteRecursive(iterator.next()); + for (Path child : stream.toList()) { + deleteRecursive(child); } } } diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java index b1775a1..5c54b35 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/toolchain/SubprocessRunner.java @@ -8,6 +8,8 @@ import java.util.concurrent.TimeUnit; public final class SubprocessRunner { + private static final long REAP_TIMEOUT_SECONDS = 5; + private SubprocessRunner() { } @@ -24,18 +26,22 @@ public static ProcessResult run(List command, Path workingDirectory, lon boolean finished = process.waitFor(timeoutSeconds, TimeUnit.SECONDS); if (!finished) { process.destroyForcibly(); - process.waitFor(); + reapProcess(process); return new ProcessResult(-1, "", "Process timed out after " + timeoutSeconds + "s"); } return new ProcessResult(process.exitValue(), stdoutFuture.join(), stderrFuture.join()); } catch (InterruptedException error) { process.destroyForcibly(); - process.waitFor(); + reapProcess(process); Thread.currentThread().interrupt(); return new ProcessResult(-1, "", "Process interrupted"); } } + private static void reapProcess(Process process) throws InterruptedException { + process.waitFor(REAP_TIMEOUT_SECONDS, TimeUnit.SECONDS); + } + private static String readStream(java.io.InputStream stream) { try { return new String(stream.readAllBytes(), StandardCharsets.UTF_8); diff --git a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java index 0a5d3ea..93065bc 100644 --- a/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java +++ b/mod/common/src/main/java/dev/spyc0der77/mcspacks/util/McsPaths.java @@ -55,14 +55,14 @@ public static Path spyglassScript() throws IOException { Path scriptsDir = gameRoot().resolve("mcs-packs-scripts"); Files.createDirectories(scriptsDir); Path script = scriptsDir.resolve("mcs-spyglass-validate.js"); - InputStream stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.mjs"); - if (stream == null) { - stream = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.js"); + InputStream bundled = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.mjs"); + if (bundled == null) { + bundled = McsPaths.class.getResourceAsStream("/scripts/mcs-spyglass-validate.js"); } - if (stream == null) { + if (bundled == null) { throw new IOException("Bundled Spyglass validator script is missing from the mod JAR"); } - try (stream) { + try (InputStream stream = bundled) { Files.copy(stream, script, java.nio.file.StandardCopyOption.REPLACE_EXISTING); } return script; diff --git a/mod/fabric/build.gradle b/mod/fabric/build.gradle index c98c1a6..1dd5d71 100644 --- a/mod/fabric/build.gradle +++ b/mod/fabric/build.gradle @@ -45,11 +45,13 @@ processResources { inputs.property 'supported_game_versions', rootProject.supportedGameVersions inputs.property 'architectury_api_version', rootProject.architectury_api_version inputs.property 'fabric_api_version', rootProject.fabric_api_version + inputs.property 'java_version', rootProject.requiredJavaVersion filesMatching('fabric.mod.json') { expand 'mod_version': project.version, 'minecraft_version': rootProject.minecraft_version, 'supported_game_versions': rootProject.supportedGameVersions, 'architectury_api_version': rootProject.architectury_api_version, - 'fabric_api_version': rootProject.fabric_api_version + 'fabric_api_version': rootProject.fabric_api_version, + 'java_version': rootProject.requiredJavaVersion } } diff --git a/mod/fabric/src/main/resources/fabric.mod.json b/mod/fabric/src/main/resources/fabric.mod.json index 9677c8a..fe55296 100644 --- a/mod/fabric/src/main/resources/fabric.mod.json +++ b/mod/fabric/src/main/resources/fabric.mod.json @@ -13,7 +13,7 @@ "depends": { "fabricloader": ">=0.16.0", "minecraft": "${minecraft_version}", - "java": ">=21", + "java": ">=${java_version}", "architectury": ">=${architectury_api_version}", "fabric-api": ">=${fabric_api_version}" } diff --git a/mod/forge/build.gradle b/mod/forge/build.gradle index 2b5048b..6b5e680 100644 --- a/mod/forge/build.gradle +++ b/mod/forge/build.gradle @@ -48,9 +48,9 @@ def stripPreReleaseSuffix = { String version -> version.replaceFirst(/-(?:beta|alpha|rc\d*|snapshot|pre).*$/, '') } -def warnVersionFallback = { String name, String version, String reason -> - logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}") - version +def warnVersionFallback = { String name, String version, String reason, String safeUpper -> + logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}. Using '${safeUpper}'") + safeUpper } def nextMinecraftVersion = { @@ -62,20 +62,20 @@ def nextMinecraftVersion = { if (parts.size() == 3 && parts.every { it.isInteger() }) { return "${parts[0]}.${parts[1]}.${parts[2].toInteger() + 1}" } - warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'") + warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'", '99.99.99') }() -def nextMajorVersion = { String version, String suffix = '', String name = 'version' -> +def nextMajorVersion = { String version, String suffix = '', String name = 'version', String safeUpper = '99.0.0' -> def normalized = stripPreReleaseSuffix(version) def major = normalized.tokenize('.')[0] if (major.isInteger()) { return "${major.toInteger() + 1}${suffix}" } - warnVersionFallback(name, version, "unrecognized major component '${major}'") + warnVersionFallback(name, version, "unrecognized major component '${major}'", safeUpper) } -def nextForgeVersion = nextMajorVersion(rootProject.forge_version, '.0.0', 'forge_version') -def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version') +def nextForgeVersion = nextMajorVersion(rootProject.forge_version, '.0.0', 'forge_version', '99.0.0') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version', '99.0.0') processResources { inputs.property 'mod_version', project.version diff --git a/mod/neoforge/build.gradle b/mod/neoforge/build.gradle index 90586e9..4db757b 100644 --- a/mod/neoforge/build.gradle +++ b/mod/neoforge/build.gradle @@ -48,9 +48,9 @@ def stripPreReleaseSuffix = { String version -> version.replaceFirst(/-(?:beta|alpha|rc\d*|snapshot|pre).*$/, '') } -def warnVersionFallback = { String name, String version, String reason -> - logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}") - version +def warnVersionFallback = { String name, String version, String reason, String safeUpper -> + logger.warn("Using fallback upper bound for ${name} '${version}': ${reason}. Using '${safeUpper}'") + safeUpper } def nextMinecraftVersion = { @@ -62,20 +62,20 @@ def nextMinecraftVersion = { if (parts.size() == 3 && parts.every { it.isInteger() }) { return "${parts[0]}.${parts[1]}.${parts[2].toInteger() + 1}" } - warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'") + warnVersionFallback('minecraft_version', rootProject.minecraft_version, "unrecognized format after normalization '${version}'", '99.99.99') }() -def nextMajorVersion = { String version, String suffix = '', String name = 'version' -> +def nextMajorVersion = { String version, String suffix = '', String name = 'version', String safeUpper = '99.0.0' -> def normalized = stripPreReleaseSuffix(version) def major = normalized.tokenize('.')[0] if (major.isInteger()) { return "${major.toInteger() + 1}${suffix}" } - warnVersionFallback(name, version, "unrecognized major component '${major}'") + warnVersionFallback(name, version, "unrecognized major component '${major}'", safeUpper) } -def nextNeoForgeVersion = nextMajorVersion(rootProject.neoforge_version, '.0.0-beta', 'neoforge_version') -def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version') +def nextNeoForgeVersion = nextMajorVersion(rootProject.neoforge_version, '.0.0-beta', 'neoforge_version', '99.0.0-beta') +def nextArchitecturyVersion = nextMajorVersion(rootProject.architectury_api_version, '.0.0', 'architectury_api_version', '99.0.0') processResources { inputs.property 'mod_version', project.version diff --git a/mod/scripts/mcs-spyglass-validate.mjs b/mod/scripts/mcs-spyglass-validate.mjs index 2ef0805..a99a2a4 100644 --- a/mod/scripts/mcs-spyglass-validate.mjs +++ b/mod/scripts/mcs-spyglass-validate.mjs @@ -37,7 +37,11 @@ function parseArgs(argv) { continue } if (arg.startsWith('--mc-version=')) { - flags.mcVersion = arg.slice('--mc-version='.length) + const value = arg.slice('--mc-version='.length) + if (!value) { + throw new Error('Missing value for --mc-version=') + } + flags.mcVersion = value continue } positional.push(arg) From c779d21c14787213302a7a465b23648030832815 Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 14:07:54 -0400 Subject: [PATCH 11/12] Update Gradle wrapper and remove obsolete script - Updated Gradle wrapper to version 8.14.5 for improved build performance and compatibility. - Deleted the `mcs-spyglass-validate.js` script as part of the ongoing cleanup and consolidation of validation functionality. --- .../.architectury-transformer/debug.log | 89 +- .../scripts/mcs-spyglass-validate.js | 37752 ---------------- mod/gradle/wrapper/gradle-wrapper.properties | 4 +- 3 files changed, 13 insertions(+), 37832 deletions(-) delete mode 100644 mod/common/src/main/resources/scripts/mcs-spyglass-validate.js diff --git a/mod/common/.gradle/.architectury-transformer/debug.log b/mod/common/.gradle/.architectury-transformer/debug.log index 55a418e..dfc3bda 100644 --- a/mod/common/.gradle/.architectury-transformer/debug.log +++ b/mod/common/.gradle/.architectury-transformer/debug.log @@ -1,19 +1,20 @@ [Architectury Transformer DEBUG] [Architectury Transformer DEBUG] ============================ -[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar +[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.2-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.2-common-0.1.0-transformProductionFabric.jar [Architectury Transformer DEBUG] ============================ [Architectury Transformer DEBUG] -[Architectury Transformer DEBUG] Transforming 5 transformer(s) from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar: -[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapMixinVariables@2dec85a9 -[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformExpectPlatform@158e3f53 -[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapInjectables@780b10da +[Architectury Transformer DEBUG] Transforming 5 transformer(s) from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.2-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.2-common-0.1.0-transformProductionFabric.jar: +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapMixinVariables@2b184553 +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformExpectPlatform@26a5c8fc +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.RemapInjectables@3e780c0a [Architectury Transformer DEBUG] - AddRefmapName(enabled=() -> kotlin.Boolean) -[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformPlatformOnly@3e698c0 -[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.11-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar with 5 transformer(s) on dev.architectury.transformer.handler.SimpleTransformerHandler +[Architectury Transformer DEBUG] - dev.architectury.transformer.transformers.TransformPlatformOnly@3a17f3 +[Architectury Transformer DEBUG] Transforming from C:\Users\Carter\Code\Minecraft-Script\mod\common\build\devlibs\mcs-packs-1.21.2-common-0.1.0-dev.jar to C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.2-common-0.1.0-transformProductionFabric.jar with 5 transformer(s) on dev.architectury.transformer.handler.SimpleTransformerHandler [Architectury Transformer DEBUG] Found class transformer [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/watch/PackWatcher with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/version/VersionMapper with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/version/VersionMapper$Index with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/util/SafePaths with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/util/PlayerFeedback with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/util/McsPaths with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/toolchain/SubprocessRunner with maxs=true frames=true @@ -27,80 +28,12 @@ [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/registry/PackRegistry$PackOverrides with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/registry/PackDefinition with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/pipeline/PackPipeline with maxs=true frames=true -[Architectury Transformer DEBUG] Provided 67 classpath jar(s): -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\dev.architectury\architectury-injectables\1.0.10\62db2a366d662606d1b23ad02ccc3212ed37ec3\architectury-injectables-1.0.10.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.fabricmc\fabric-loader\0.19.3\354dfaa02d0552e11867f85dff7cdbfaf813ba3e\fabric-loader-0.19.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jetbrains\annotations\26.0.2\c7ce3cdeda3d18909368dfe5977332dfad326c6d\annotations-26.0.2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.code.gson\gson\2.13.2\48b8230771e573b54ce6e867a9001e75977fe78e\gson-2.13.2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm\9.9\c29635c8a7afa03d74b33c1884df8abb2b3f3dcc\asm-9.9.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-analysis\9.9\bf4fa6e66638851c1cd22c2caea0c3ee5d5f437\asm-analysis-9.9.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-commons\9.9\db9165a3bf908ded6b08612d583a15d1d0c7bda0\asm-commons-9.9.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-tree\9.9\f8de6eead6d24dd0f45bd065bbe112b2cda6ea21\asm-tree-9.9.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.ow2.asm\asm-util\9.9\42fdfc0508b43807c8078d6e82ecff2ce2112ae8\asm-util-9.9.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.fabricmc\sponge-mixin\0.16.5+mixin.0.8.7\80fc3a9f592673cea87f4cd702f87991c6c9fe4d\sponge-mixin-0.16.5+mixin.0.8.7.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.github.llamalad7\mixinextras-fabric\0.5.0\91a83dfb7abd320f6236bd1fcf5c0ff143d59a13\mixinextras-fabric-0.5.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\at.yawk.lz4\lz4-java\1.8.1\1f30a180ee04ccd53339a716aec13cae60a013b5\lz4-java-1.8.1.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.azure\azure-json\1.4.0\fcc1d354dbc3e0300e5276b1bf124d0247799cd8\azure-json-1.4.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.github.oshi\oshi-core\6.9.0\3224870731860cfcd7744581a05b559e94291e7\oshi-core-6.9.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.guava\failureaccess\1.0.3\aeaffd00d57023a2c947393ed251f0354f0985fc\failureaccess-1.0.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.guava\guava\33.5.0-jre\8699de25f2f979108d6c1b804a7ba38cda1116bc\guava-33.5.0-jre.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.ibm.icu\icu4j\77.1\38693cf0b1d7362a8b726af74dc06026a7c23809\icu4j-77.1.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.microsoft.azure\msal4j\1.23.1\6c722b514873b24a4e1ce9c22dca36ea3c22bdbe\msal4j-1.23.1.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\authlib\7.0.61\efee1e6b54e863108576eb3b3ae71144626aaefc\authlib-7.0.61.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\blocklist\1.0.10\5c685c5ffa94c4cd39496c7184c1d122e515ecef\blocklist-1.0.10.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\brigadier\1.3.10\d15b53a14cf20fdcaa98f731af5dda654452c010\brigadier-1.3.10.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\datafixerupper\9.0.19\4e91f9712fa1e83231d1501625381b0210a977da\datafixerupper-9.0.19.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\jtracy\1.0.37\a3fb649b2e2b2288d2978f0b0bc3d83f62809d1e\jtracy-1.0.37.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\logging\1.6.11\fd147240733010c158249d986323f9ef98977fe\logging-1.6.11.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\patchy\2.2.10\da05971b07cbb379d002cf7eaec6a2048211fefc\patchy-2.2.10.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.mojang\text2speech\1.18.11\e853a12cdd6ba4f4836e8f4bf3b37844a13482b6\text2speech-1.18.11.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\commons-codec\commons-codec\1.19.0\8c0dbe3ae883fceda9b50a6c76e745e548073388\commons-codec-1.19.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\commons-io\commons-io\2.20.0\36f3474daec2849c149e877614e7f979b2082cd2\commons-io-2.20.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-buffer\4.2.7.Final\5555ff561643bf2f8430fb57c24403c0efe15994\netty-buffer-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-base\4.2.7.Final\915e381ebabcf115f1c7ff7032d55c48afb50210\netty-codec-base-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-compression\4.2.7.Final\572341bc1ca90fd9d6e47f1d2694aab5258566e9\netty-codec-compression-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-codec-http\4.2.7.Final\b734c108854099c421fd94d92d9f865e4d4da853\netty-codec-http-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-common\4.2.7.Final\11aa30df26af4fca3239ac1917f303a280f301e1\netty-common-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-handler\4.2.7.Final\7ad8a1f851e2e6fe93cdd091871fda2b81c03b5b\netty-handler-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-resolver\4.2.7.Final\5f3e5ef8de03992cd4fb46960dc0085ec1a12a12\netty-resolver-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-classes-epoll\4.2.7.Final\1075c09f48a78eef9d819fbfd9096b903fdd362a\netty-transport-classes-epoll-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-classes-kqueue\4.2.7.Final\bdec7c23c75caabd848426d073c09568e8d5f94e\netty-transport-classes-kqueue-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-unix-common\4.2.7.Final\89953f04259ea7502cffb313630dd51e00e60669\netty-transport-native-unix-common-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport\4.2.7.Final\83ea548981d0d8c4a98027cc1a6f9624f902e142\netty-transport-4.2.7.Final.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\it.unimi.dsi\fastutil\8.5.18\a6cff377eecc19c2037bf31568a6d7106b50ba1f\fastutil-8.5.18.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.java.dev.jna\jna-platform\5.17.0\a4934c44d25a9d8c2ddf4203affd20330cb3426f\jna-platform-5.17.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.java.dev.jna\jna\5.17.0\33d12735bef894440780fce64f9758d420c7bae2\jna-5.17.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\net.sf.jopt-simple\jopt-simple\5.0.4\4fdac2fbe92dfad86aa6e9301736f6b4342a3f5c\jopt-simple-5.0.4.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.commons\commons-compress\1.28.0\e482f2c7a88dac3c497e96aa420b6a769f59c8d7\commons-compress-1.28.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.commons\commons-lang3\3.19.0\d6524b169a6574cd253760c472d419b47bfd37e6\commons-lang3-3.19.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-api\2.25.2\292c1a2b1702f1e1e3adb13e1c57e5bff60335ff\log4j-api-2.25.2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-core\2.25.2\d4d0ad2e51e03e531f784891fbfff1bae1e13a12\log4j-core-2.25.2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.apache.logging.log4j\log4j-slf4j2-impl\2.25.2\5eec0c392661dee8a366baec17e8896900dd978f\log4j-slf4j2-impl-2.25.2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jcraft\jorbis\0.0.17\8872d22b293e8f5d7d56ff92be966e6dc28ebdc6\jorbis-0.0.17.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.joml\joml\1.10.8\fc0a71dad90a2cf41d82a76156a0e700af8e4f8d\joml-1.10.8.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.jspecify\jspecify\1.0.0\7425a601c1c7ec76645a78d22b8c6a627edee507\jspecify-1.0.0.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-freetype\3.3.3\a0db6c84a8becc8ca05f9dbfa985edc348a824c7\lwjgl-freetype-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-glfw\3.3.3\efa1eb78c5ccd840e9f329717109b5e892d72f8e\lwjgl-glfw-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-jemalloc\3.3.3\b543467b7ff3c6920539a88ee602d34098628be5\lwjgl-jemalloc-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-openal\3.3.3\daada81ceb5fc0c291fbfdd4433cb8d9423577f2\lwjgl-openal-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-opengl\3.3.3\2f6b0147078396a58979125a4c947664e98293a\lwjgl-opengl-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-stb\3.3.3\25dd6161988d7e65f71d5065c99902402ee32746\lwjgl-stb-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl-tinyfd\3.3.3\82d755ca94b102e9ca77283b9e2dc46d1b15fbe5\lwjgl-tinyfd-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.lwjgl\lwjgl\3.3.3\29589b5f87ed335a6c7e7ee6a5775f81f97ecb84\lwjgl-3.3.3.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\org.slf4j\slf4j-api\2.0.17\d9e58ac9c7779ba3bf8142aff6c830617a7fe60f\slf4j-api-2.0.17.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\Code\Minecraft-Script\mod\.gradle\loom-cache\minecraftMaven\net\minecraft\minecraft-merged-c69b0de466\1.21.11-loom.mappings.1_21_11.layered+hash.40359-v2\minecraft-merged-c69b0de466-1.21.11-loom.mappings.1_21_11.layered+hash.40359-v2.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-epoll\4.2.7.Final\e83998bfc10b5289d9bcbe807c4079ef0eed8e6f\netty-transport-native-epoll-4.2.7.Final-linux-x86_64.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-epoll\4.2.7.Final\98d02251c98c8f07a23ac5ea27657d9e0ef57614\netty-transport-native-epoll-4.2.7.Final-linux-aarch_64.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-kqueue\4.2.7.Final\40868fd4e43bce2798245f790624b58803dc26b6\netty-transport-native-kqueue-4.2.7.Final-osx-x86_64.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\io.netty\netty-transport-native-kqueue\4.2.7.Final\e5a0feef41410c8a5ae00c6cb4e0c99bd0aded6a\netty-transport-native-kqueue-4.2.7.Final-osx-aarch_64.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\Code\Minecraft-Script\mod\.gradle\loom-cache\remapped_mods\remapped\dev\architectury\architectury-6a6b1e70\19.0.1\architectury-6a6b1e70-19.0.1.jar -[Architectury Transformer DEBUG] - C:\Users\Carter\.gradle\caches\modules-2\files-2.1\com.google.errorprone\error_prone_annotations\2.41.0\4381275efdef6ddfae38f002c31e84cd001c97f0\error_prone_annotations-2.41.0.jar -[Architectury Transformer] Read classpath in 1.433 s [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/McsPacks with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer$2 with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/DatapackDeployer$1 with maxs=true frames=true +[Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/deploy/CommandSources with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/config/ModConfigManager with maxs=true frames=true [Architectury Transformer DEBUG] Writing dev/spyc0der77/mcspacks/config/ModConfig with maxs=true frames=true -[Architectury Transformer DEBUG] Closed File Systems for C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.11-common-0.1.0-transformProductionFabric.jar -[Architectury Transformer] Transformed jar with 5 transformer(s) in 1.539 s +[Architectury Transformer DEBUG] Closed File Systems for C:\Users\Carter\Code\Minecraft-Script\mod\common\build\libs\mcs-packs-1.21.2-common-0.1.0-transformProductionFabric.jar +[Architectury Transformer] Transformed jar with 5 transformer(s) in 225.5 ms diff --git a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js b/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js deleted file mode 100644 index 4de99b3..0000000 --- a/mod/common/src/main/resources/scripts/mcs-spyglass-validate.js +++ /dev/null @@ -1,37752 +0,0 @@ -#!/usr/bin/env node -var __create = Object.create; -var __defProp = Object.defineProperty; -var __getOwnPropDesc = Object.getOwnPropertyDescriptor; -var __getOwnPropNames = Object.getOwnPropertyNames; -var __getProtoOf = Object.getPrototypeOf; -var __hasOwnProp = Object.prototype.hasOwnProperty; -var __glob = (map3) => (path6) => { - var fn = map3[path6]; - if (fn) return fn(); - throw new Error("Module not found in bundle: " + path6); -}; -var __esm = (fn, res) => function __init() { - return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res; -}; -var __commonJS = (cb, mod) => function __require() { - return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports; -}; -var __export = (target, all) => { - for (var name in all) - __defProp(target, name, { get: all[name], enumerable: true }); -}; -var __copyProps = (to, from, except, desc) => { - if (from && typeof from === "object" || typeof from === "function") { - for (let key2 of __getOwnPropNames(from)) - if (!__hasOwnProp.call(to, key2) && key2 !== except) - __defProp(to, key2, { get: () => from[key2], enumerable: !(desc = __getOwnPropDesc(from, key2)) || desc.enumerable }); - } - return to; -}; -var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps( - // If the importer is in node compatibility mode or this is not an ESM - // file that has been converted to a CommonJS file using a Babel- - // compatible transform (i.e. "__esModule" has not been set), then set - // "default" to the CommonJS "module.exports" for node compatibility. - isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, - mod -)); - -// node_modules/binary-search/index.js -var require_binary_search = __commonJS({ - "node_modules/binary-search/index.js"(exports2, module3) { - module3.exports = function(haystack, needle, comparator, low, high) { - var mid, cmp; - if (low === void 0) - low = 0; - else { - low = low | 0; - if (low < 0 || low >= haystack.length) - throw new RangeError("invalid lower bound"); - } - if (high === void 0) - high = haystack.length - 1; - else { - high = high | 0; - if (high < low || high >= haystack.length) - throw new RangeError("invalid upper bound"); - } - while (low <= high) { - mid = low + (high - low >>> 1); - cmp = +comparator(haystack[mid], needle, mid, haystack); - if (cmp < 0) - low = mid + 1; - else if (cmp > 0) - high = mid - 1; - else - return mid; - } - return ~low; - }; - } -}); - -// node_modules/rfdc/index.js -var require_rfdc = __commonJS({ - "node_modules/rfdc/index.js"(exports2, module3) { - "use strict"; - module3.exports = rfdc4; - function copyBuffer(cur) { - if (cur instanceof Buffer) { - return Buffer.from(cur); - } - return new cur.constructor(cur.buffer.slice(), cur.byteOffset, cur.length); - } - function rfdc4(opts) { - opts = opts || {}; - if (opts.circles) return rfdcCircles(opts); - const constructorHandlers = /* @__PURE__ */ new Map(); - constructorHandlers.set(Date, (o) => new Date(o)); - constructorHandlers.set(Map, (o, fn) => new Map(cloneArray(Array.from(o), fn))); - constructorHandlers.set(Set, (o, fn) => new Set(cloneArray(Array.from(o), fn))); - if (opts.constructorHandlers) { - for (const handler2 of opts.constructorHandlers) { - constructorHandlers.set(handler2[0], handler2[1]); - } - } - let handler = null; - return opts.proto ? cloneProto : clone; - function cloneArray(a, fn) { - const keys = Object.keys(a); - const a2 = new Array(keys.length); - for (let i = 0; i < keys.length; i++) { - const k = keys[i]; - const cur = a[k]; - if (typeof cur !== "object" || cur === null) { - a2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - a2[k] = handler(cur, fn); - } else if (ArrayBuffer.isView(cur)) { - a2[k] = copyBuffer(cur); - } else { - a2[k] = fn(cur); - } - } - return a2; - } - function clone(o) { - if (typeof o !== "object" || o === null) return o; - if (Array.isArray(o)) return cloneArray(o, clone); - if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { - return handler(o, clone); - } - const o2 = {}; - for (const k in o) { - if (Object.hasOwnProperty.call(o, k) === false) continue; - const cur = o[k]; - if (typeof cur !== "object" || cur === null) { - o2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - o2[k] = handler(cur, clone); - } else if (ArrayBuffer.isView(cur)) { - o2[k] = copyBuffer(cur); - } else { - o2[k] = clone(cur); - } - } - return o2; - } - function cloneProto(o) { - if (typeof o !== "object" || o === null) return o; - if (Array.isArray(o)) return cloneArray(o, cloneProto); - if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { - return handler(o, cloneProto); - } - const o2 = {}; - for (const k in o) { - const cur = o[k]; - if (typeof cur !== "object" || cur === null) { - o2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - o2[k] = handler(cur, cloneProto); - } else if (ArrayBuffer.isView(cur)) { - o2[k] = copyBuffer(cur); - } else { - o2[k] = cloneProto(cur); - } - } - return o2; - } - } - function rfdcCircles(opts) { - const refs = []; - const refsNew = []; - const constructorHandlers = /* @__PURE__ */ new Map(); - constructorHandlers.set(Date, (o) => new Date(o)); - constructorHandlers.set(Map, (o, fn) => new Map(cloneArray(Array.from(o), fn))); - constructorHandlers.set(Set, (o, fn) => new Set(cloneArray(Array.from(o), fn))); - if (opts.constructorHandlers) { - for (const handler2 of opts.constructorHandlers) { - constructorHandlers.set(handler2[0], handler2[1]); - } - } - let handler = null; - return opts.proto ? cloneProto : clone; - function cloneArray(a, fn) { - const keys = Object.keys(a); - const a2 = new Array(keys.length); - for (let i = 0; i < keys.length; i++) { - const k = keys[i]; - const cur = a[k]; - if (typeof cur !== "object" || cur === null) { - a2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - a2[k] = handler(cur, fn); - } else if (ArrayBuffer.isView(cur)) { - a2[k] = copyBuffer(cur); - } else { - const index4 = refs.indexOf(cur); - if (index4 !== -1) { - a2[k] = refsNew[index4]; - } else { - a2[k] = fn(cur); - } - } - } - return a2; - } - function clone(o) { - if (typeof o !== "object" || o === null) return o; - if (Array.isArray(o)) return cloneArray(o, clone); - if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { - return handler(o, clone); - } - const o2 = {}; - refs.push(o); - refsNew.push(o2); - for (const k in o) { - if (Object.hasOwnProperty.call(o, k) === false) continue; - const cur = o[k]; - if (typeof cur !== "object" || cur === null) { - o2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - o2[k] = handler(cur, clone); - } else if (ArrayBuffer.isView(cur)) { - o2[k] = copyBuffer(cur); - } else { - const i = refs.indexOf(cur); - if (i !== -1) { - o2[k] = refsNew[i]; - } else { - o2[k] = clone(cur); - } - } - } - refs.pop(); - refsNew.pop(); - return o2; - } - function cloneProto(o) { - if (typeof o !== "object" || o === null) return o; - if (Array.isArray(o)) return cloneArray(o, cloneProto); - if (o.constructor !== Object && (handler = constructorHandlers.get(o.constructor))) { - return handler(o, cloneProto); - } - const o2 = {}; - refs.push(o); - refsNew.push(o2); - for (const k in o) { - const cur = o[k]; - if (typeof cur !== "object" || cur === null) { - o2[k] = cur; - } else if (cur.constructor !== Object && (handler = constructorHandlers.get(cur.constructor))) { - o2[k] = handler(cur, cloneProto); - } else if (ArrayBuffer.isView(cur)) { - o2[k] = copyBuffer(cur); - } else { - const i = refs.indexOf(cur); - if (i !== -1) { - o2[k] = refsNew[i]; - } else { - o2[k] = cloneProto(cur); - } - } - } - refs.pop(); - refsNew.pop(); - return o2; - } - } - } -}); - -// node_modules/webidl-conversions/lib/index.js -var require_lib = __commonJS({ - "node_modules/webidl-conversions/lib/index.js"(exports2) { - "use strict"; - function makeException(ErrorType, message2, options2) { - if (options2.globals) { - ErrorType = options2.globals[ErrorType.name]; - } - return new ErrorType(`${options2.context ? options2.context : "Value"} ${message2}.`); - } - function toNumber(value, options2) { - if (typeof value === "bigint") { - throw makeException(TypeError, "is a BigInt which cannot be converted to a number", options2); - } - if (!options2.globals) { - return Number(value); - } - return options2.globals.Number(value); - } - function evenRound(x) { - if (x > 0 && x % 1 === 0.5 && (x & 1) === 0 || x < 0 && x % 1 === -0.5 && (x & 1) === 1) { - return censorNegativeZero(Math.floor(x)); - } - return censorNegativeZero(Math.round(x)); - } - function integerPart(n) { - return censorNegativeZero(Math.trunc(n)); - } - function sign(x) { - return x < 0 ? -1 : 1; - } - function modulo(x, y) { - const signMightNotMatch = x % y; - if (sign(y) !== sign(signMightNotMatch)) { - return signMightNotMatch + y; - } - return signMightNotMatch; - } - function censorNegativeZero(x) { - return x === 0 ? 0 : x; - } - function createIntegerConversion(bitLength, { unsigned }) { - let lowerBound, upperBound; - if (unsigned) { - lowerBound = 0; - upperBound = 2 ** bitLength - 1; - } else { - lowerBound = -(2 ** (bitLength - 1)); - upperBound = 2 ** (bitLength - 1) - 1; - } - const twoToTheBitLength = 2 ** bitLength; - const twoToOneLessThanTheBitLength = 2 ** (bitLength - 1); - return (value, options2 = {}) => { - let x = toNumber(value, options2); - x = censorNegativeZero(x); - if (options2.enforceRange) { - if (!Number.isFinite(x)) { - throw makeException(TypeError, "is not a finite number", options2); - } - x = integerPart(x); - if (x < lowerBound || x > upperBound) { - throw makeException( - TypeError, - `is outside the accepted range of ${lowerBound} to ${upperBound}, inclusive`, - options2 - ); - } - return x; - } - if (!Number.isNaN(x) && options2.clamp) { - x = Math.min(Math.max(x, lowerBound), upperBound); - x = evenRound(x); - return x; - } - if (!Number.isFinite(x) || x === 0) { - return 0; - } - x = integerPart(x); - if (x >= lowerBound && x <= upperBound) { - return x; - } - x = modulo(x, twoToTheBitLength); - if (!unsigned && x >= twoToOneLessThanTheBitLength) { - return x - twoToTheBitLength; - } - return x; - }; - } - function createLongLongConversion(bitLength, { unsigned }) { - const upperBound = Number.MAX_SAFE_INTEGER; - const lowerBound = unsigned ? 0 : Number.MIN_SAFE_INTEGER; - const asBigIntN = unsigned ? BigInt.asUintN : BigInt.asIntN; - return (value, options2 = {}) => { - let x = toNumber(value, options2); - x = censorNegativeZero(x); - if (options2.enforceRange) { - if (!Number.isFinite(x)) { - throw makeException(TypeError, "is not a finite number", options2); - } - x = integerPart(x); - if (x < lowerBound || x > upperBound) { - throw makeException( - TypeError, - `is outside the accepted range of ${lowerBound} to ${upperBound}, inclusive`, - options2 - ); - } - return x; - } - if (!Number.isNaN(x) && options2.clamp) { - x = Math.min(Math.max(x, lowerBound), upperBound); - x = evenRound(x); - return x; - } - if (!Number.isFinite(x) || x === 0) { - return 0; - } - let xBigInt = BigInt(integerPart(x)); - xBigInt = asBigIntN(bitLength, xBigInt); - return Number(xBigInt); - }; - } - exports2.any = (value) => { - return value; - }; - exports2.undefined = () => { - return void 0; - }; - exports2.boolean = (value) => { - return Boolean(value); - }; - exports2.byte = createIntegerConversion(8, { unsigned: false }); - exports2.octet = createIntegerConversion(8, { unsigned: true }); - exports2.short = createIntegerConversion(16, { unsigned: false }); - exports2["unsigned short"] = createIntegerConversion(16, { unsigned: true }); - exports2.long = createIntegerConversion(32, { unsigned: false }); - exports2["unsigned long"] = createIntegerConversion(32, { unsigned: true }); - exports2["long long"] = createLongLongConversion(64, { unsigned: false }); - exports2["unsigned long long"] = createLongLongConversion(64, { unsigned: true }); - exports2.double = (value, options2 = {}) => { - const x = toNumber(value, options2); - if (!Number.isFinite(x)) { - throw makeException(TypeError, "is not a finite floating-point value", options2); - } - return x; - }; - exports2["unrestricted double"] = (value, options2 = {}) => { - const x = toNumber(value, options2); - return x; - }; - exports2.float = (value, options2 = {}) => { - const x = toNumber(value, options2); - if (!Number.isFinite(x)) { - throw makeException(TypeError, "is not a finite floating-point value", options2); - } - if (Object.is(x, -0)) { - return x; - } - const y = Math.fround(x); - if (!Number.isFinite(y)) { - throw makeException(TypeError, "is outside the range of a single-precision floating-point value", options2); - } - return y; - }; - exports2["unrestricted float"] = (value, options2 = {}) => { - const x = toNumber(value, options2); - if (isNaN(x)) { - return x; - } - if (Object.is(x, -0)) { - return x; - } - return Math.fround(x); - }; - exports2.DOMString = (value, options2 = {}) => { - if (options2.treatNullAsEmptyString && value === null) { - return ""; - } - if (typeof value === "symbol") { - throw makeException(TypeError, "is a symbol, which cannot be converted to a string", options2); - } - const StringCtor = options2.globals ? options2.globals.String : String; - return StringCtor(value); - }; - exports2.ByteString = (value, options2 = {}) => { - const x = exports2.DOMString(value, options2); - let c; - for (let i = 0; (c = x.codePointAt(i)) !== void 0; ++i) { - if (c > 255) { - throw makeException(TypeError, "is not a valid ByteString", options2); - } - } - return x; - }; - exports2.USVString = (value, options2 = {}) => { - const S = exports2.DOMString(value, options2); - const n = S.length; - const U = []; - for (let i = 0; i < n; ++i) { - const c = S.charCodeAt(i); - if (c < 55296 || c > 57343) { - U.push(String.fromCodePoint(c)); - } else if (56320 <= c && c <= 57343) { - U.push(String.fromCodePoint(65533)); - } else if (i === n - 1) { - U.push(String.fromCodePoint(65533)); - } else { - const d = S.charCodeAt(i + 1); - if (56320 <= d && d <= 57343) { - const a = c & 1023; - const b = d & 1023; - U.push(String.fromCodePoint((2 << 15) + (2 << 9) * a + b)); - ++i; - } else { - U.push(String.fromCodePoint(65533)); - } - } - } - return U.join(""); - }; - exports2.object = (value, options2 = {}) => { - if (value === null || typeof value !== "object" && typeof value !== "function") { - throw makeException(TypeError, "is not an object", options2); - } - return value; - }; - var abByteLengthGetter = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get; - var sabByteLengthGetter = typeof SharedArrayBuffer === "function" ? Object.getOwnPropertyDescriptor(SharedArrayBuffer.prototype, "byteLength").get : null; - function isNonSharedArrayBuffer(value) { - try { - abByteLengthGetter.call(value); - return true; - } catch { - return false; - } - } - function isSharedArrayBuffer(value) { - try { - sabByteLengthGetter.call(value); - return true; - } catch { - return false; - } - } - function isArrayBufferDetached(value) { - try { - new Uint8Array(value); - return false; - } catch { - return true; - } - } - exports2.ArrayBuffer = (value, options2 = {}) => { - if (!isNonSharedArrayBuffer(value)) { - if (options2.allowShared && !isSharedArrayBuffer(value)) { - throw makeException(TypeError, "is not an ArrayBuffer or SharedArrayBuffer", options2); - } - throw makeException(TypeError, "is not an ArrayBuffer", options2); - } - if (isArrayBufferDetached(value)) { - throw makeException(TypeError, "is a detached ArrayBuffer", options2); - } - return value; - }; - var dvByteLengthGetter = Object.getOwnPropertyDescriptor(DataView.prototype, "byteLength").get; - exports2.DataView = (value, options2 = {}) => { - try { - dvByteLengthGetter.call(value); - } catch (e) { - throw makeException(TypeError, "is not a DataView", options2); - } - if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { - throw makeException(TypeError, "is backed by a SharedArrayBuffer, which is not allowed", options2); - } - if (isArrayBufferDetached(value.buffer)) { - throw makeException(TypeError, "is backed by a detached ArrayBuffer", options2); - } - return value; - }; - var typedArrayNameGetter = Object.getOwnPropertyDescriptor( - Object.getPrototypeOf(Uint8Array).prototype, - Symbol.toStringTag - ).get; - [ - Int8Array, - Int16Array, - Int32Array, - Uint8Array, - Uint16Array, - Uint32Array, - Uint8ClampedArray, - Float32Array, - Float64Array - ].forEach((func) => { - const { name } = func; - const article = /^[AEIOU]/u.test(name) ? "an" : "a"; - exports2[name] = (value, options2 = {}) => { - if (!ArrayBuffer.isView(value) || typedArrayNameGetter.call(value) !== name) { - throw makeException(TypeError, `is not ${article} ${name} object`, options2); - } - if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { - throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); - } - if (isArrayBufferDetached(value.buffer)) { - throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); - } - return value; - }; - }); - exports2.ArrayBufferView = (value, options2 = {}) => { - if (!ArrayBuffer.isView(value)) { - throw makeException(TypeError, "is not a view on an ArrayBuffer or SharedArrayBuffer", options2); - } - if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { - throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); - } - if (isArrayBufferDetached(value.buffer)) { - throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); - } - return value; - }; - exports2.BufferSource = (value, options2 = {}) => { - if (ArrayBuffer.isView(value)) { - if (!options2.allowShared && isSharedArrayBuffer(value.buffer)) { - throw makeException(TypeError, "is a view on a SharedArrayBuffer, which is not allowed", options2); - } - if (isArrayBufferDetached(value.buffer)) { - throw makeException(TypeError, "is a view on a detached ArrayBuffer", options2); - } - return value; - } - if (!options2.allowShared && !isNonSharedArrayBuffer(value)) { - throw makeException(TypeError, "is not an ArrayBuffer or a view on one", options2); - } - if (options2.allowShared && !isSharedArrayBuffer(value) && !isNonSharedArrayBuffer(value)) { - throw makeException(TypeError, "is not an ArrayBuffer, SharedArrayBuffer, or a view on one", options2); - } - if (isArrayBufferDetached(value)) { - throw makeException(TypeError, "is a detached ArrayBuffer", options2); - } - return value; - }; - exports2.DOMTimeStamp = exports2["unsigned long long"]; - } -}); - -// node_modules/whatwg-url/lib/utils.js -var require_utils = __commonJS({ - "node_modules/whatwg-url/lib/utils.js"(exports2, module3) { - "use strict"; - function isObject2(value) { - return typeof value === "object" && value !== null || typeof value === "function"; - } - var hasOwn = Function.prototype.call.bind(Object.prototype.hasOwnProperty); - function define(target, source) { - for (const key2 of Reflect.ownKeys(source)) { - const descriptor = Reflect.getOwnPropertyDescriptor(source, key2); - if (descriptor && !Reflect.defineProperty(target, key2, descriptor)) { - throw new TypeError(`Cannot redefine property: ${String(key2)}`); - } - } - } - function newObjectInRealm(globalObject, object5) { - const ctorRegistry = initCtorRegistry(globalObject); - return Object.defineProperties( - Object.create(ctorRegistry["%Object.prototype%"]), - Object.getOwnPropertyDescriptors(object5) - ); - } - var wrapperSymbol = Symbol("wrapper"); - var implSymbol = Symbol("impl"); - var sameObjectCaches = Symbol("SameObject caches"); - var ctorRegistrySymbol = Symbol.for("[webidl2js] constructor registry"); - var AsyncIteratorPrototype = Object.getPrototypeOf(Object.getPrototypeOf(async function* () { - }).prototype); - function initCtorRegistry(globalObject) { - if (hasOwn(globalObject, ctorRegistrySymbol)) { - return globalObject[ctorRegistrySymbol]; - } - const ctorRegistry = /* @__PURE__ */ Object.create(null); - ctorRegistry["%Object.prototype%"] = globalObject.Object.prototype; - ctorRegistry["%IteratorPrototype%"] = Object.getPrototypeOf( - Object.getPrototypeOf(new globalObject.Array()[Symbol.iterator]()) - ); - try { - ctorRegistry["%AsyncIteratorPrototype%"] = Object.getPrototypeOf( - Object.getPrototypeOf( - globalObject.eval("(async function* () {})").prototype - ) - ); - } catch { - ctorRegistry["%AsyncIteratorPrototype%"] = AsyncIteratorPrototype; - } - globalObject[ctorRegistrySymbol] = ctorRegistry; - return ctorRegistry; - } - function getSameObject(wrapper, prop, creator) { - if (!wrapper[sameObjectCaches]) { - wrapper[sameObjectCaches] = /* @__PURE__ */ Object.create(null); - } - if (prop in wrapper[sameObjectCaches]) { - return wrapper[sameObjectCaches][prop]; - } - wrapper[sameObjectCaches][prop] = creator(); - return wrapper[sameObjectCaches][prop]; - } - function wrapperForImpl(impl) { - return impl ? impl[wrapperSymbol] : null; - } - function implForWrapper(wrapper) { - return wrapper ? wrapper[implSymbol] : null; - } - function tryWrapperForImpl(impl) { - const wrapper = wrapperForImpl(impl); - return wrapper ? wrapper : impl; - } - function tryImplForWrapper(wrapper) { - const impl = implForWrapper(wrapper); - return impl ? impl : wrapper; - } - var iterInternalSymbol = Symbol("internal"); - function isArrayIndexPropName(P) { - if (typeof P !== "string") { - return false; - } - const i = P >>> 0; - if (i === 2 ** 32 - 1) { - return false; - } - const s = `${i}`; - if (P !== s) { - return false; - } - return true; - } - var byteLengthGetter = Object.getOwnPropertyDescriptor(ArrayBuffer.prototype, "byteLength").get; - function isArrayBuffer(value) { - try { - byteLengthGetter.call(value); - return true; - } catch (e) { - return false; - } - } - function iteratorResult([key2, value], kind) { - let result; - switch (kind) { - case "key": - result = key2; - break; - case "value": - result = value; - break; - case "key+value": - result = [key2, value]; - break; - } - return { value: result, done: false }; - } - var supportsPropertyIndex = Symbol("supports property index"); - var supportedPropertyIndices = Symbol("supported property indices"); - var supportsPropertyName = Symbol("supports property name"); - var supportedPropertyNames = Symbol("supported property names"); - var indexedGet = Symbol("indexed property get"); - var indexedSetNew = Symbol("indexed property set new"); - var indexedSetExisting = Symbol("indexed property set existing"); - var namedGet = Symbol("named property get"); - var namedSetNew = Symbol("named property set new"); - var namedSetExisting = Symbol("named property set existing"); - var namedDelete = Symbol("named property delete"); - var asyncIteratorNext = Symbol("async iterator get the next iteration result"); - var asyncIteratorReturn = Symbol("async iterator return steps"); - var asyncIteratorInit = Symbol("async iterator initialization steps"); - var asyncIteratorEOI = Symbol("async iterator end of iteration"); - module3.exports = exports2 = { - isObject: isObject2, - hasOwn, - define, - newObjectInRealm, - wrapperSymbol, - implSymbol, - getSameObject, - ctorRegistrySymbol, - initCtorRegistry, - wrapperForImpl, - implForWrapper, - tryWrapperForImpl, - tryImplForWrapper, - iterInternalSymbol, - isArrayBuffer, - isArrayIndexPropName, - supportsPropertyIndex, - supportedPropertyIndices, - supportsPropertyName, - supportedPropertyNames, - indexedGet, - indexedSetNew, - indexedSetExisting, - namedGet, - namedSetNew, - namedSetExisting, - namedDelete, - asyncIteratorNext, - asyncIteratorReturn, - asyncIteratorInit, - asyncIteratorEOI, - iteratorResult - }; - } -}); - -// node_modules/punycode/punycode.js -var require_punycode = __commonJS({ - "node_modules/punycode/punycode.js"(exports2, module3) { - "use strict"; - var maxInt = 2147483647; - var base = 36; - var tMin = 1; - var tMax = 26; - var skew = 38; - var damp = 700; - var initialBias = 72; - var initialN = 128; - var delimiter = "-"; - var regexPunycode = /^xn--/; - var regexNonASCII = /[^\0-\x7F]/; - var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g; - var errors = { - "overflow": "Overflow: input needs wider integers to process", - "not-basic": "Illegal input >= 0x80 (not a basic code point)", - "invalid-input": "Invalid input" - }; - var baseMinusTMin = base - tMin; - var floor = Math.floor; - var stringFromCharCode = String.fromCharCode; - function error4(type2) { - throw new RangeError(errors[type2]); - } - function map3(array4, callback) { - const result = []; - let length = array4.length; - while (length--) { - result[length] = callback(array4[length]); - } - return result; - } - function mapDomain(domain, callback) { - const parts = domain.split("@"); - let result = ""; - if (parts.length > 1) { - result = parts[0] + "@"; - domain = parts[1]; - } - domain = domain.replace(regexSeparators, "."); - const labels = domain.split("."); - const encoded = map3(labels, callback).join("."); - return result + encoded; - } - function ucs2decode(string11) { - const output = []; - let counter = 0; - const length = string11.length; - while (counter < length) { - const value = string11.charCodeAt(counter++); - if (value >= 55296 && value <= 56319 && counter < length) { - const extra = string11.charCodeAt(counter++); - if ((extra & 64512) == 56320) { - output.push(((value & 1023) << 10) + (extra & 1023) + 65536); - } else { - output.push(value); - counter--; - } - } else { - output.push(value); - } - } - return output; - } - var ucs2encode = (codePoints) => String.fromCodePoint(...codePoints); - var basicToDigit = function(codePoint) { - if (codePoint >= 48 && codePoint < 58) { - return 26 + (codePoint - 48); - } - if (codePoint >= 65 && codePoint < 91) { - return codePoint - 65; - } - if (codePoint >= 97 && codePoint < 123) { - return codePoint - 97; - } - return base; - }; - var digitToBasic = function(digit, flag) { - return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5); - }; - var adapt = function(delta, numPoints, firstTime) { - let k = 0; - delta = firstTime ? floor(delta / damp) : delta >> 1; - delta += floor(delta / numPoints); - for (; delta > baseMinusTMin * tMax >> 1; k += base) { - delta = floor(delta / baseMinusTMin); - } - return floor(k + (baseMinusTMin + 1) * delta / (delta + skew)); - }; - var decode = function(input) { - const output = []; - const inputLength = input.length; - let i = 0; - let n = initialN; - let bias = initialBias; - let basic = input.lastIndexOf(delimiter); - if (basic < 0) { - basic = 0; - } - for (let j = 0; j < basic; ++j) { - if (input.charCodeAt(j) >= 128) { - error4("not-basic"); - } - output.push(input.charCodeAt(j)); - } - for (let index4 = basic > 0 ? basic + 1 : 0; index4 < inputLength; ) { - const oldi = i; - for (let w = 1, k = base; ; k += base) { - if (index4 >= inputLength) { - error4("invalid-input"); - } - const digit = basicToDigit(input.charCodeAt(index4++)); - if (digit >= base) { - error4("invalid-input"); - } - if (digit > floor((maxInt - i) / w)) { - error4("overflow"); - } - i += digit * w; - const t = k <= bias ? tMin : k >= bias + tMax ? tMax : k - bias; - if (digit < t) { - break; - } - const baseMinusT = base - t; - if (w > floor(maxInt / baseMinusT)) { - error4("overflow"); - } - w *= baseMinusT; - } - const out = output.length + 1; - bias = adapt(i - oldi, out, oldi == 0); - if (floor(i / out) > maxInt - n) { - error4("overflow"); - } - n += floor(i / out); - i %= out; - output.splice(i++, 0, n); - } - return String.fromCodePoint(...output); - }; - var encode = function(input) { - const output = []; - input = ucs2decode(input); - const inputLength = input.length; - let n = initialN; - let delta = 0; - let bias = initialBias; - for (const currentValue of input) { - if (currentValue < 128) { - output.push(stringFromCharCode(currentValue)); - } - } - const basicLength = output.length; - let handledCPCount = basicLength; - if (basicLength) { - output.push(delimiter); - } - while (handledCPCount < inputLength) { - let m = maxInt; - for (const currentValue of input) { - if (currentValue >= n && currentValue < m) { - m = currentValue; - } - } - const handledCPCountPlusOne = handledCPCount + 1; - if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) { - error4("overflow"); - } - delta += (m - n) * handledCPCountPlusOne; - n = m; - for (const currentValue of input) { - if (currentValue < n && ++delta > maxInt) { - error4("overflow"); - } - if (currentValue === n) { - let q = delta; - for (let k = base; ; k += base) { - const t = k <= bias ? tMin : k >= bias + tMax ? tMax : k - bias; - if (q < t) { - break; - } - const qMinusT = q - t; - const baseMinusT = base - t; - output.push( - stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0)) - ); - q = floor(qMinusT / baseMinusT); - } - output.push(stringFromCharCode(digitToBasic(q, 0))); - bias = adapt(delta, handledCPCountPlusOne, handledCPCount === basicLength); - delta = 0; - ++handledCPCount; - } - } - ++delta; - ++n; - } - return output.join(""); - }; - var toUnicode = function(input) { - return mapDomain(input, function(string11) { - return regexPunycode.test(string11) ? decode(string11.slice(4).toLowerCase()) : string11; - }); - }; - var toASCII = function(input) { - return mapDomain(input, function(string11) { - return regexNonASCII.test(string11) ? "xn--" + encode(string11) : string11; - }); - }; - var punycode = { - /** - * A string representing the current Punycode.js version number. - * @memberOf punycode - * @type String - */ - "version": "2.3.1", - /** - * An object of methods to convert from JavaScript's internal character - * representation (UCS-2) to Unicode code points, and back. - * @see - * @memberOf punycode - * @type Object - */ - "ucs2": { - "decode": ucs2decode, - "encode": ucs2encode - }, - "decode": decode, - "encode": encode, - "toASCII": toASCII, - "toUnicode": toUnicode - }; - module3.exports = punycode; - } -}); - -// node_modules/tr46/lib/regexes.js -var require_regexes = __commonJS({ - "node_modules/tr46/lib/regexes.js"(exports2, module3) { - "use strict"; - var combiningMarks = /[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3C\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CF3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D81-\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1715\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA82C\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11000}-\u{11002}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11082}\u{110B0}-\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{11134}\u{11145}\u{11146}\u{11173}\u{11180}-\u{11182}\u{111B3}-\u{111C0}\u{111C9}-\u{111CC}\u{111CE}\u{111CF}\u{1122C}-\u{11237}\u{1123E}\u{11241}\u{112DF}-\u{112EA}\u{11300}-\u{11303}\u{1133B}\u{1133C}\u{1133E}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11357}\u{11362}\u{11363}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113B8}-\u{113C0}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}-\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11435}-\u{11446}\u{1145E}\u{114B0}-\u{114C3}\u{115AF}-\u{115B5}\u{115B8}-\u{115C0}\u{115DC}\u{115DD}\u{11630}-\u{11640}\u{116AB}-\u{116B7}\u{1171D}-\u{1172B}\u{1182C}-\u{1183A}\u{11930}-\u{11935}\u{11937}\u{11938}\u{1193B}-\u{1193E}\u{11940}\u{11942}\u{11943}\u{119D1}-\u{119D7}\u{119DA}-\u{119E0}\u{119E4}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A39}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A5B}\u{11A8A}-\u{11A99}\u{11C2F}-\u{11C36}\u{11C38}-\u{11C3F}\u{11C92}-\u{11CA7}\u{11CA9}-\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D8A}-\u{11D8E}\u{11D90}\u{11D91}\u{11D93}-\u{11D97}\u{11EF3}-\u{11EF6}\u{11F00}\u{11F01}\u{11F03}\u{11F34}-\u{11F3A}\u{11F3E}-\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F51}-\u{16F87}\u{16F8F}-\u{16F92}\u{16FE4}\u{16FF0}\u{16FF1}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D165}-\u{1D169}\u{1D16D}-\u{1D172}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]/u; - var combiningClassVirama = /[\u094D\u09CD\u0A4D\u0ACD\u0B4D\u0BCD\u0C4D\u0CCD\u0D3B\u0D3C\u0D4D\u0DCA\u0E3A\u0EBA\u0F84\u1039\u103A\u1714\u1715\u1734\u17D2\u1A60\u1B44\u1BAA\u1BAB\u1BF2\u1BF3\u2D7F\uA806\uA82C\uA8C4\uA953\uA9C0\uAAF6\uABED\u{10A3F}\u{11046}\u{11070}\u{1107F}\u{110B9}\u{11133}\u{11134}\u{111C0}\u{11235}\u{112EA}\u{1134D}\u{113CE}-\u{113D0}\u{11442}\u{114C2}\u{115BF}\u{1163F}\u{116B6}\u{1172B}\u{11839}\u{1193D}\u{1193E}\u{119E0}\u{11A34}\u{11A47}\u{11A99}\u{11C3F}\u{11D44}\u{11D45}\u{11D97}\u{11F41}\u{11F42}\u{1612F}]/u; - var validZWNJ = /[\u0620\u0626\u0628\u062A-\u062E\u0633-\u063F\u0641-\u0647\u0649\u064A\u066E\u066F\u0678-\u0687\u069A-\u06BF\u06C1\u06C2\u06CC\u06CE\u06D0\u06D1\u06FA-\u06FC\u06FF\u0712-\u0714\u071A-\u071D\u071F-\u0727\u0729\u072B\u072D\u072E\u074E-\u0758\u075C-\u076A\u076D-\u0770\u0772\u0775-\u0777\u077A-\u077F\u07CA-\u07EA\u0841-\u0845\u0848\u084A-\u0853\u0855\u0860\u0862-\u0865\u0868\u0886\u0889-\u088D\u08A0-\u08A9\u08AF\u08B0\u08B3-\u08B8\u08BA-\u08C8\u1807\u1820-\u1878\u1887-\u18A8\u18AA\uA840-\uA872\u{10AC0}-\u{10AC4}\u{10ACD}\u{10AD3}-\u{10ADC}\u{10ADE}-\u{10AE0}\u{10AEB}-\u{10AEE}\u{10B80}\u{10B82}\u{10B86}-\u{10B88}\u{10B8A}\u{10B8B}\u{10B8D}\u{10B90}\u{10BAD}\u{10BAE}\u{10D00}-\u{10D21}\u{10D23}\u{10EC3}\u{10EC4}\u{10F30}-\u{10F32}\u{10F34}-\u{10F44}\u{10F51}-\u{10F53}\u{10F70}-\u{10F73}\u{10F76}-\u{10F81}\u{10FB0}\u{10FB2}\u{10FB3}\u{10FB8}\u{10FBB}\u{10FBC}\u{10FBE}\u{10FBF}\u{10FC1}\u{10FC4}\u{10FCA}\u{10FCB}\u{1E900}-\u{1E943}][\xAD\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u061C\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u070F\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC6\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200B\u200E\u200F\u202A-\u202E\u2060-\u2064\u206A-\u206F\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFEFF\uFFF9-\uFFFB\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C3F}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13430}-\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94B}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*\u200C[\xAD\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u061C\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u070F\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC6\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u200B\u200E\u200F\u202A-\u202E\u2060-\u2064\u206A-\u206F\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFEFF\uFFF9-\uFFFB\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C3F}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13430}-\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94B}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*[\u0620\u0622-\u063F\u0641-\u064A\u066E\u066F\u0671-\u0673\u0675-\u06D3\u06D5\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u077F\u07CA-\u07EA\u0840-\u0858\u0860\u0862-\u0865\u0867-\u086A\u0870-\u0882\u0886\u0889-\u088E\u08A0-\u08AC\u08AE-\u08C8\u1807\u1820-\u1878\u1887-\u18A8\u18AA\uA840-\uA871\u{10AC0}-\u{10AC5}\u{10AC7}\u{10AC9}\u{10ACA}\u{10ACE}-\u{10AD6}\u{10AD8}-\u{10AE1}\u{10AE4}\u{10AEB}-\u{10AEF}\u{10B80}-\u{10B91}\u{10BA9}-\u{10BAE}\u{10D01}-\u{10D23}\u{10EC2}-\u{10EC4}\u{10F30}-\u{10F44}\u{10F51}-\u{10F54}\u{10F70}-\u{10F81}\u{10FB0}\u{10FB2}-\u{10FB6}\u{10FB8}-\u{10FBF}\u{10FC1}-\u{10FC4}\u{10FC9}\u{10FCA}\u{1E900}-\u{1E943}]/u; - var bidiDomain = /[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0600-\u0605\u0608\u060B\u060D\u061B-\u064A\u0660-\u0669\u066B-\u066F\u0671-\u06D5\u06DD\u06E5\u06E6\u06EE\u06EF\u06FA-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u08A0-\u08C9\u08E2\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}]/u; - var bidiS1LTR = /[A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u02BB-\u02C1\u02D0\u02D1\u02E0-\u02E4\u02EE\u0370-\u0373\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0482\u048A-\u052F\u0531-\u0556\u0559-\u0589\u0903-\u0939\u093B\u093D-\u0940\u0949-\u094C\u094E-\u0950\u0958-\u0961\u0964-\u0980\u0982\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD-\u09C0\u09C7\u09C8\u09CB\u09CC\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09FA\u09FC\u09FD\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3E-\u0A40\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A76\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD-\u0AC0\u0AC9\u0ACB\u0ACC\u0AD0\u0AE0\u0AE1\u0AE6-\u0AF0\u0AF9\u0B02\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B3E\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0B57\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0BD0\u0BD7\u0BE6-\u0BF2\u0C01-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C41-\u0C44\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C77\u0C7F\u0C80\u0C82-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD-\u0CC4\u0CC6-\u0CC8\u0CCA\u0CCB\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D02-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D4E\u0D4F\u0D54-\u0D61\u0D66-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCF-\u0DD1\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E4F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F17\u0F1A-\u0F34\u0F36\u0F38\u0F3E-\u0F47\u0F49-\u0F6C\u0F7F\u0F85\u0F88-\u0F8C\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE-\u0FDA\u1000-\u102C\u1031\u1038\u103B\u103C\u103F-\u1057\u105A-\u105D\u1061-\u1070\u1075-\u1081\u1083\u1084\u1087-\u108C\u108E-\u109C\u109E-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1360-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u167F\u1681-\u169A\u16A0-\u16F8\u1700-\u1711\u1715\u171F-\u1731\u1734-\u1736\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17B6\u17BE-\u17C5\u17C7\u17C8\u17D4-\u17DA\u17DC\u17E0-\u17E9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A19\u1A1A\u1A1E-\u1A55\u1A57\u1A61\u1A63\u1A64\u1A6D-\u1A72\u1A80-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1B04-\u1B33\u1B35\u1B3B\u1B3D-\u1B41\u1B43-\u1B4C\u1B4E-\u1B6A\u1B74-\u1B7F\u1B82-\u1BA1\u1BA6\u1BA7\u1BAA\u1BAE-\u1BE5\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1BFC-\u1C2B\u1C34\u1C35\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD3\u1CE1\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5-\u1CF7\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200E\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u214F\u2160-\u2188\u2336-\u237A\u2395\u249C-\u24E9\u26AC\u2800-\u28FF\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u302E\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31BF\u31F0-\u321C\u3220-\u324F\u3260-\u327B\u327F-\u32B0\u32C0-\u32CB\u32D0-\u3376\u337B-\u33DD\u33E0-\u33FE\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA60C\uA610-\uA62B\uA640-\uA66E\uA680-\uA69D\uA6A0-\uA6EF\uA6F2-\uA6F7\uA722-\uA787\uA789-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA824\uA827\uA830-\uA837\uA840-\uA873\uA880-\uA8C3\uA8CE-\uA8D9\uA8F2-\uA8FE\uA900-\uA925\uA92E-\uA946\uA952\uA953\uA95F-\uA97C\uA983-\uA9B2\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA2F\uAA30\uAA33\uAA34\uAA40-\uAA42\uAA44-\uAA4B\uAA4D\uAA50-\uAA59\uAA5C-\uAA7B\uAA7D-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAAEB\uAAEE-\uAAF5\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB69\uAB70-\uABE4\uABE6\uABE7\uABE9-\uABEC\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1013F}\u{1018D}\u{1018E}\u{101D0}-\u{101FC}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{11000}\u{11002}-\u{11037}\u{11047}-\u{1104D}\u{11066}-\u{1106F}\u{11071}\u{11072}\u{11075}\u{11082}-\u{110B2}\u{110B7}\u{110B8}\u{110BB}-\u{110C1}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11103}-\u{11126}\u{1112C}\u{11136}-\u{11147}\u{11150}-\u{11172}\u{11174}-\u{11176}\u{11182}-\u{111B5}\u{111BF}-\u{111C8}\u{111CD}\u{111CE}\u{111D0}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{1122E}\u{11232}\u{11233}\u{11235}\u{11238}-\u{1123D}\u{1123F}\u{11240}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112DE}\u{112E0}-\u{112E2}\u{112F0}-\u{112F9}\u{11302}\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}-\u{1133F}\u{11341}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113BA}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}\u{113CD}\u{113CF}\u{113D1}\u{113D3}-\u{113D5}\u{113D7}\u{113D8}\u{11400}-\u{11437}\u{11440}\u{11441}\u{11445}\u{11447}-\u{1145B}\u{1145D}\u{1145F}-\u{11461}\u{11480}-\u{114B2}\u{114B9}\u{114BB}-\u{114BE}\u{114C1}\u{114C4}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B1}\u{115B8}-\u{115BB}\u{115BE}\u{115C1}-\u{115DB}\u{11600}-\u{11632}\u{1163B}\u{1163C}\u{1163E}\u{11641}-\u{11644}\u{11650}-\u{11659}\u{11680}-\u{116AA}\u{116AC}\u{116AE}\u{116AF}\u{116B6}\u{116B8}\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171E}\u{11720}\u{11721}\u{11726}\u{11730}-\u{11746}\u{11800}-\u{1182E}\u{11838}\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193D}\u{1193F}-\u{11942}\u{11944}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D3}\u{119DC}-\u{119DF}\u{119E1}-\u{119E4}\u{11A00}\u{11A07}\u{11A08}\u{11A0B}-\u{11A32}\u{11A39}\u{11A3A}\u{11A3F}-\u{11A46}\u{11A50}\u{11A57}\u{11A58}\u{11A5C}-\u{11A89}\u{11A97}\u{11A9A}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2F}\u{11C3E}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11CA9}\u{11CB1}\u{11CB4}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D93}\u{11D94}\u{11D96}\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF2}\u{11EF5}-\u{11EF8}\u{11F02}-\u{11F10}\u{11F12}-\u{11F35}\u{11F3E}\u{11F3F}\u{11F41}\u{11F43}-\u{11F59}\u{11FB0}\u{11FC0}-\u{11FD4}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{1343F}\u{13441}-\u{13446}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{1611D}\u{1612A}-\u{1612C}\u{16130}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF5}\u{16B00}-\u{16B2F}\u{16B37}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F50}-\u{16F87}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{16FE3}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}\u{1BC9F}\u{1CCD6}-\u{1CCEF}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D166}\u{1D16A}-\u{1D172}\u{1D183}\u{1D184}\u{1D18C}-\u{1D1A9}\u{1D1AE}-\u{1D1E8}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1D800}-\u{1D9FF}\u{1DA37}-\u{1DA3A}\u{1DA6D}-\u{1DA74}\u{1DA76}-\u{1DA83}\u{1DA85}-\u{1DA8B}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E030}-\u{1E06D}\u{1E100}-\u{1E12C}\u{1E137}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AD}\u{1E2C0}-\u{1E2EB}\u{1E2F0}-\u{1E2F9}\u{1E4D0}-\u{1E4EB}\u{1E4F0}-\u{1E4F9}\u{1E5D0}-\u{1E5ED}\u{1E5F0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1F110}-\u{1F12E}\u{1F130}-\u{1F169}\u{1F170}-\u{1F1AC}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}]/u; - var bidiS1RTL = /[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D4A}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}]/u; - var bidiS2 = /^[\0-\x08\x0E-\x1B!-@\[-`\{-\x84\x86-\xA9\xAB-\xB4\xB6-\xB9\xBB-\xBF\xD7\xF7\u02B9\u02BA\u02C2-\u02CF\u02D2-\u02DF\u02E5-\u02ED\u02EF-\u036F\u0374\u0375\u037E\u0384\u0385\u0387\u03F6\u0483-\u0489\u058A\u058D-\u058F\u0591-\u05C7\u05D0-\u05EA\u05EF-\u05F4\u0600-\u070D\u070F-\u074A\u074D-\u07B1\u07C0-\u07FA\u07FD-\u082D\u0830-\u083E\u0840-\u085B\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u0897-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09F2\u09F3\u09FB\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AF1\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0BF3-\u0BFA\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C78-\u0C7E\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E3F\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39-\u0F3D\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1390-\u1399\u1400\u169B\u169C\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DB\u17DD\u17F0-\u17F9\u1800-\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1940\u1944\u1945\u19DE-\u19FF\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u200B-\u200D\u200F-\u2027\u202F-\u205E\u2060-\u2064\u206A-\u2070\u2074-\u207E\u2080-\u208E\u20A0-\u20C0\u20D0-\u20F0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u2150-\u215F\u2189-\u218B\u2190-\u2335\u237B-\u2394\u2396-\u2429\u2440-\u244A\u2460-\u249B\u24EA-\u26AB\u26AD-\u27FF\u2900-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2CEF-\u2CF1\u2CF9-\u2CFF\u2D7F\u2DE0-\u2E5D\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3001-\u3004\u3008-\u3020\u302A-\u302D\u3030\u3036\u3037\u303D-\u303F\u3099-\u309C\u30A0\u30FB\u31C0-\u31E5\u31EF\u321D\u321E\u3250-\u325F\u327C-\u327E\u32B1-\u32BF\u32CC-\u32CF\u3377-\u337A\u33DE\u33DF\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA60D-\uA60F\uA66F-\uA67F\uA69E\uA69F\uA6F0\uA6F1\uA700-\uA721\uA788\uA802\uA806\uA80B\uA825\uA826\uA828-\uA82C\uA838\uA839\uA874-\uA877\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uAB6A\uAB6B\uABE5\uABE8\uABED\uFB1D-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD8F\uFD92-\uFDC7\uFDCF\uFDF0-\uFE19\uFE20-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFE70-\uFE74\uFE76-\uFEFC\uFEFF\uFF01-\uFF20\uFF3B-\uFF40\uFF5B-\uFF65\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFF9-\uFFFD\u{10101}\u{10140}-\u{1018C}\u{10190}-\u{1019C}\u{101A0}\u{101FD}\u{102E0}-\u{102FB}\u{10376}-\u{1037A}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{1091F}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A38}-\u{10A3A}\u{10A3F}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE6}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B39}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D27}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D69}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAB}-\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10EFC}-\u{10F27}\u{10F30}-\u{10F59}\u{10F70}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{11001}\u{11038}-\u{11046}\u{11052}-\u{11065}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{11660}-\u{1166C}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{11FD5}-\u{11FF1}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE2}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1BCA0}-\u{1BCA3}\u{1CC00}-\u{1CCD5}\u{1CCF0}-\u{1CCF9}\u{1CD00}-\u{1CEB3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D173}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D1E9}\u{1D1EA}\u{1D200}-\u{1D245}\u{1D300}-\u{1D356}\u{1D6C1}\u{1D6DB}\u{1D6FB}\u{1D715}\u{1D735}\u{1D74F}\u{1D76F}\u{1D789}\u{1D7A9}\u{1D7C3}\u{1D7CE}-\u{1D7FF}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E2FF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8D6}\u{1E900}-\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{1EEF0}\u{1EEF1}\u{1F000}-\u{1F02B}\u{1F030}-\u{1F093}\u{1F0A0}-\u{1F0AE}\u{1F0B1}-\u{1F0BF}\u{1F0C1}-\u{1F0CF}\u{1F0D1}-\u{1F0F5}\u{1F100}-\u{1F10F}\u{1F12F}\u{1F16A}-\u{1F16F}\u{1F1AD}\u{1F260}-\u{1F265}\u{1F300}-\u{1F6D7}\u{1F6DC}-\u{1F6EC}\u{1F6F0}-\u{1F6FC}\u{1F700}-\u{1F776}\u{1F77B}-\u{1F7D9}\u{1F7E0}-\u{1F7EB}\u{1F7F0}\u{1F800}-\u{1F80B}\u{1F810}-\u{1F847}\u{1F850}-\u{1F859}\u{1F860}-\u{1F887}\u{1F890}-\u{1F8AD}\u{1F8B0}-\u{1F8BB}\u{1F8C0}\u{1F8C1}\u{1F900}-\u{1FA53}\u{1FA60}-\u{1FA6D}\u{1FA70}-\u{1FA7C}\u{1FA80}-\u{1FA89}\u{1FA8F}-\u{1FAC6}\u{1FACE}-\u{1FADC}\u{1FADF}-\u{1FAE9}\u{1FAF0}-\u{1FAF8}\u{1FB00}-\u{1FB92}\u{1FB94}-\u{1FBF9}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}]*$/u; - var bidiS3 = /[0-9\xB2\xB3\xB9\u05BE\u05C0\u05C3\u05C6\u05D0-\u05EA\u05EF-\u05F4\u0600-\u0605\u0608\u060B\u060D\u061B-\u064A\u0660-\u0669\u066B-\u066F\u0671-\u06D5\u06DD\u06E5\u06E6\u06EE-\u070D\u070F\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u083E\u0840-\u0858\u085E\u0860-\u086A\u0870-\u088E\u0890\u0891\u08A0-\u08C9\u08E2\u200F\u2070\u2074-\u2079\u2080-\u2089\u2488-\u249B\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBC2\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFC\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\u{102E1}-\u{102FB}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10857}-\u{1089E}\u{108A7}-\u{108AF}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{108FB}-\u{1091B}\u{10920}-\u{10939}\u{1093F}\u{10980}-\u{109B7}\u{109BC}-\u{109CF}\u{109D2}-\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A40}-\u{10A48}\u{10A50}-\u{10A58}\u{10A60}-\u{10A9F}\u{10AC0}-\u{10AE4}\u{10AEB}-\u{10AF6}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B58}-\u{10B72}\u{10B78}-\u{10B91}\u{10B99}-\u{10B9C}\u{10BA9}-\u{10BAF}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10CFA}-\u{10D23}\u{10D30}-\u{10D39}\u{10D40}-\u{10D65}\u{10D6F}-\u{10D85}\u{10D8E}\u{10D8F}\u{10E60}-\u{10E7E}\u{10E80}-\u{10EA9}\u{10EAD}\u{10EB0}\u{10EB1}\u{10EC2}-\u{10EC4}\u{10F00}-\u{10F27}\u{10F30}-\u{10F45}\u{10F51}-\u{10F59}\u{10F70}-\u{10F81}\u{10F86}-\u{10F89}\u{10FB0}-\u{10FCB}\u{10FE0}-\u{10FF6}\u{1CCF0}-\u{1CCF9}\u{1D7CE}-\u{1D7FF}\u{1E800}-\u{1E8C4}\u{1E8C7}-\u{1E8CF}\u{1E900}-\u{1E943}\u{1E94B}\u{1E950}-\u{1E959}\u{1E95E}\u{1E95F}\u{1EC71}-\u{1ECB4}\u{1ED01}-\u{1ED3D}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{1F100}-\u{1F10A}\u{1FBF0}-\u{1FBF9}][\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]*$/u; - var bidiS4EN = /[0-9\xB2\xB3\xB9\u06F0-\u06F9\u2070\u2074-\u2079\u2080-\u2089\u2488-\u249B\uFF10-\uFF19\u{102E1}-\u{102FB}\u{1CCF0}-\u{1CCF9}\u{1D7CE}-\u{1D7FF}\u{1F100}-\u{1F10A}\u{1FBF0}-\u{1FBF9}]/u; - var bidiS4AN = /[\u0600-\u0605\u0660-\u0669\u066B\u066C\u06DD\u0890\u0891\u08E2\u{10D30}-\u{10D39}\u{10D40}-\u{10D49}\u{10E60}-\u{10E7E}]/u; - var bidiS5 = /^[\0-\x08\x0E-\x1B!-\x84\x86-\u0377\u037A-\u037F\u0384-\u038A\u038C\u038E-\u03A1\u03A3-\u052F\u0531-\u0556\u0559-\u058A\u058D-\u058F\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0606\u0607\u0609\u060A\u060C\u060E-\u061A\u064B-\u065F\u066A\u0670\u06D6-\u06DC\u06DE-\u06E4\u06E7-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07F6-\u07F9\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09FE\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A76\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AF1\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B55-\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B77\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BFA\u0C00-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3C-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C5D\u0C60-\u0C63\u0C66-\u0C6F\u0C77-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D00-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4F\u0D54-\u0D63\u0D66-\u0D7F\u0D81-\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E3A\u0E3F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECE\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F47\u0F49-\u0F6C\u0F71-\u0F97\u0F99-\u0FBC\u0FBE-\u0FCC\u0FCE-\u0FDA\u1000-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u137C\u1380-\u1399\u13A0-\u13F5\u13F8-\u13FD\u1400-\u167F\u1681-\u169C\u16A0-\u16F8\u1700-\u1715\u171F-\u1736\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17DD\u17E0-\u17E9\u17F0-\u17F9\u1800-\u1819\u1820-\u1878\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1940\u1944-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u19DE-\u1A1B\u1A1E-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1AB0-\u1ACE\u1B00-\u1B4C\u1B4E-\u1BF3\u1BFC-\u1C37\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD0-\u1CFA\u1D00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FC4\u1FC6-\u1FD3\u1FD6-\u1FDB\u1FDD-\u1FEF\u1FF2-\u1FF4\u1FF6-\u1FFE\u200B-\u200E\u2010-\u2027\u202F-\u205E\u2060-\u2064\u206A-\u2071\u2074-\u208E\u2090-\u209C\u20A0-\u20C0\u20D0-\u20F0\u2100-\u218B\u2190-\u2429\u2440-\u244A\u2460-\u2B73\u2B76-\u2B95\u2B97-\u2CF3\u2CF9-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2E5D\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3001-\u303F\u3041-\u3096\u3099-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31E5\u31EF-\u321E\u3220-\uA48C\uA490-\uA4C6\uA4D0-\uA62B\uA640-\uA6F7\uA700-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA82C\uA830-\uA839\uA840-\uA877\uA880-\uA8C5\uA8CE-\uA8D9\uA8E0-\uA953\uA95F-\uA97C\uA980-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA5C-\uAAC2\uAADB-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB6B\uAB70-\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1E\uFB29\uFD3E-\uFD4F\uFDCF\uFDFD-\uFE19\uFE20-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFEFF\uFF01-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFF9-\uFFFD\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}-\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1018E}\u{10190}-\u{1019C}\u{101A0}\u{101D0}-\u{101FD}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{102E0}-\u{102FB}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{1037A}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{1091F}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10B39}-\u{10B3F}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6E}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11000}-\u{1104D}\u{11052}-\u{11075}\u{1107F}-\u{110C2}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11100}-\u{11134}\u{11136}-\u{11147}\u{11150}-\u{11176}\u{11180}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{11241}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112EA}\u{112F0}-\u{112F9}\u{11300}-\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133B}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113C0}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}-\u{113D5}\u{113D7}\u{113D8}\u{113E1}\u{113E2}\u{11400}-\u{1145B}\u{1145D}-\u{11461}\u{11480}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B5}\u{115B8}-\u{115DD}\u{11600}-\u{11644}\u{11650}-\u{11659}\u{11660}-\u{1166C}\u{11680}-\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171D}-\u{1172B}\u{11730}-\u{11746}\u{11800}-\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193B}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D7}\u{119DA}-\u{119E4}\u{11A00}-\u{11A47}\u{11A50}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C36}\u{11C38}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11C92}-\u{11CA7}\u{11CA9}-\u{11CB6}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D47}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D90}\u{11D91}\u{11D93}-\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF8}\u{11F00}-\u{11F10}\u{11F12}-\u{11F3A}\u{11F3E}-\u{11F5A}\u{11FB0}\u{11FC0}-\u{11FF1}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{13455}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF0}-\u{16AF5}\u{16B00}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F4F}-\u{16F87}\u{16F8F}-\u{16F9F}\u{16FE0}-\u{16FE4}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}-\u{1BCA3}\u{1CC00}-\u{1CCF9}\u{1CD00}-\u{1CEB3}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D1EA}\u{1D200}-\u{1D245}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D300}-\u{1D356}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D7CB}\u{1D7CE}-\u{1DA8B}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E030}-\u{1E06D}\u{1E08F}\u{1E100}-\u{1E12C}\u{1E130}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AE}\u{1E2C0}-\u{1E2F9}\u{1E2FF}\u{1E4D0}-\u{1E4F9}\u{1E5D0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{1EEF0}\u{1EEF1}\u{1F000}-\u{1F02B}\u{1F030}-\u{1F093}\u{1F0A0}-\u{1F0AE}\u{1F0B1}-\u{1F0BF}\u{1F0C1}-\u{1F0CF}\u{1F0D1}-\u{1F0F5}\u{1F100}-\u{1F1AD}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{1F260}-\u{1F265}\u{1F300}-\u{1F6D7}\u{1F6DC}-\u{1F6EC}\u{1F6F0}-\u{1F6FC}\u{1F700}-\u{1F776}\u{1F77B}-\u{1F7D9}\u{1F7E0}-\u{1F7EB}\u{1F7F0}\u{1F800}-\u{1F80B}\u{1F810}-\u{1F847}\u{1F850}-\u{1F859}\u{1F860}-\u{1F887}\u{1F890}-\u{1F8AD}\u{1F8B0}-\u{1F8BB}\u{1F8C0}\u{1F8C1}\u{1F900}-\u{1FA53}\u{1FA60}-\u{1FA6D}\u{1FA70}-\u{1FA7C}\u{1FA80}-\u{1FA89}\u{1FA8F}-\u{1FAC6}\u{1FACE}-\u{1FADC}\u{1FADF}-\u{1FAE9}\u{1FAF0}-\u{1FAF8}\u{1FB00}-\u{1FB92}\u{1FB94}-\u{1FBF9}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{E0001}\u{E0020}-\u{E007F}\u{E0100}-\u{E01EF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}]*$/u; - var bidiS6 = /[0-9A-Za-z\xAA\xB2\xB3\xB5\xB9\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02B8\u02BB-\u02C1\u02D0\u02D1\u02E0-\u02E4\u02EE\u0370-\u0373\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0482\u048A-\u052F\u0531-\u0556\u0559-\u0589\u06F0-\u06F9\u0903-\u0939\u093B\u093D-\u0940\u0949-\u094C\u094E-\u0950\u0958-\u0961\u0964-\u0980\u0982\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD-\u09C0\u09C7\u09C8\u09CB\u09CC\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09FA\u09FC\u09FD\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3E-\u0A40\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A76\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD-\u0AC0\u0AC9\u0ACB\u0ACC\u0AD0\u0AE0\u0AE1\u0AE6-\u0AF0\u0AF9\u0B02\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B3E\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0B57\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0BD0\u0BD7\u0BE6-\u0BF2\u0C01-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C41-\u0C44\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C77\u0C7F\u0C80\u0C82-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD-\u0CC4\u0CC6-\u0CC8\u0CCA\u0CCB\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1-\u0CF3\u0D02-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D-\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D4E\u0D4F\u0D54-\u0D61\u0D66-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCF-\u0DD1\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2-\u0DF4\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E4F-\u0E5B\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00-\u0F17\u0F1A-\u0F34\u0F36\u0F38\u0F3E-\u0F47\u0F49-\u0F6C\u0F7F\u0F85\u0F88-\u0F8C\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE-\u0FDA\u1000-\u102C\u1031\u1038\u103B\u103C\u103F-\u1057\u105A-\u105D\u1061-\u1070\u1075-\u1081\u1083\u1084\u1087-\u108C\u108E-\u109C\u109E-\u10C5\u10C7\u10CD\u10D0-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1360-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u167F\u1681-\u169A\u16A0-\u16F8\u1700-\u1711\u1715\u171F-\u1731\u1734-\u1736\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17B6\u17BE-\u17C5\u17C7\u17C8\u17D4-\u17DA\u17DC\u17E0-\u17E9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A19\u1A1A\u1A1E-\u1A55\u1A57\u1A61\u1A63\u1A64\u1A6D-\u1A72\u1A80-\u1A89\u1A90-\u1A99\u1AA0-\u1AAD\u1B04-\u1B33\u1B35\u1B3B\u1B3D-\u1B41\u1B43-\u1B4C\u1B4E-\u1B6A\u1B74-\u1B7F\u1B82-\u1BA1\u1BA6\u1BA7\u1BAA\u1BAE-\u1BE5\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1BFC-\u1C2B\u1C34\u1C35\u1C3B-\u1C49\u1C4D-\u1C8A\u1C90-\u1CBA\u1CBD-\u1CC7\u1CD3\u1CE1\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5-\u1CF7\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u200E\u2070\u2071\u2074-\u2079\u207F-\u2089\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u214F\u2160-\u2188\u2336-\u237A\u2395\u2488-\u24E9\u26AC\u2800-\u28FF\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D70\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u302E\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\u31BF\u31F0-\u321C\u3220-\u324F\u3260-\u327B\u327F-\u32B0\u32C0-\u32CB\u32D0-\u3376\u337B-\u33DD\u33E0-\u33FE\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA60C\uA610-\uA62B\uA640-\uA66E\uA680-\uA69D\uA6A0-\uA6EF\uA6F2-\uA6F7\uA722-\uA787\uA789-\uA7CD\uA7D0\uA7D1\uA7D3\uA7D5-\uA7DC\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA824\uA827\uA830-\uA837\uA840-\uA873\uA880-\uA8C3\uA8CE-\uA8D9\uA8F2-\uA8FE\uA900-\uA925\uA92E-\uA946\uA952\uA953\uA95F-\uA97C\uA983-\uA9B2\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9CD\uA9CF-\uA9D9\uA9DE-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA2F\uAA30\uAA33\uAA34\uAA40-\uAA42\uAA44-\uAA4B\uAA4D\uAA50-\uAA59\uAA5C-\uAA7B\uAA7D-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAAEB\uAAEE-\uAAF5\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB69\uAB70-\uABE4\uABE6\uABE7\uABE9-\uABEC\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uD800-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10100}\u{10102}\u{10107}-\u{10133}\u{10137}-\u{1013F}\u{1018D}\u{1018E}\u{101D0}-\u{101FC}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{102E1}-\u{102FB}\u{10300}-\u{10323}\u{1032D}-\u{1034A}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{1039F}-\u{103C3}\u{103C8}-\u{103D5}\u{10400}-\u{1049D}\u{104A0}-\u{104A9}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{1056F}-\u{1057A}\u{1057C}-\u{1058A}\u{1058C}-\u{10592}\u{10594}\u{10595}\u{10597}-\u{105A1}\u{105A3}-\u{105B1}\u{105B3}-\u{105B9}\u{105BB}\u{105BC}\u{105C0}-\u{105F3}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10780}-\u{10785}\u{10787}-\u{107B0}\u{107B2}-\u{107BA}\u{11000}\u{11002}-\u{11037}\u{11047}-\u{1104D}\u{11066}-\u{1106F}\u{11071}\u{11072}\u{11075}\u{11082}-\u{110B2}\u{110B7}\u{110B8}\u{110BB}-\u{110C1}\u{110CD}\u{110D0}-\u{110E8}\u{110F0}-\u{110F9}\u{11103}-\u{11126}\u{1112C}\u{11136}-\u{11147}\u{11150}-\u{11172}\u{11174}-\u{11176}\u{11182}-\u{111B5}\u{111BF}-\u{111C8}\u{111CD}\u{111CE}\u{111D0}-\u{111DF}\u{111E1}-\u{111F4}\u{11200}-\u{11211}\u{11213}-\u{1122E}\u{11232}\u{11233}\u{11235}\u{11238}-\u{1123D}\u{1123F}\u{11240}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A9}\u{112B0}-\u{112DE}\u{112E0}-\u{112E2}\u{112F0}-\u{112F9}\u{11302}\u{11303}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}-\u{1133F}\u{11341}-\u{11344}\u{11347}\u{11348}\u{1134B}-\u{1134D}\u{11350}\u{11357}\u{1135D}-\u{11363}\u{11380}-\u{11389}\u{1138B}\u{1138E}\u{11390}-\u{113B5}\u{113B7}-\u{113BA}\u{113C2}\u{113C5}\u{113C7}-\u{113CA}\u{113CC}\u{113CD}\u{113CF}\u{113D1}\u{113D3}-\u{113D5}\u{113D7}\u{113D8}\u{11400}-\u{11437}\u{11440}\u{11441}\u{11445}\u{11447}-\u{1145B}\u{1145D}\u{1145F}-\u{11461}\u{11480}-\u{114B2}\u{114B9}\u{114BB}-\u{114BE}\u{114C1}\u{114C4}-\u{114C7}\u{114D0}-\u{114D9}\u{11580}-\u{115B1}\u{115B8}-\u{115BB}\u{115BE}\u{115C1}-\u{115DB}\u{11600}-\u{11632}\u{1163B}\u{1163C}\u{1163E}\u{11641}-\u{11644}\u{11650}-\u{11659}\u{11680}-\u{116AA}\u{116AC}\u{116AE}\u{116AF}\u{116B6}\u{116B8}\u{116B9}\u{116C0}-\u{116C9}\u{116D0}-\u{116E3}\u{11700}-\u{1171A}\u{1171E}\u{11720}\u{11721}\u{11726}\u{11730}-\u{11746}\u{11800}-\u{1182E}\u{11838}\u{1183B}\u{118A0}-\u{118F2}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{11935}\u{11937}\u{11938}\u{1193D}\u{1193F}-\u{11942}\u{11944}-\u{11946}\u{11950}-\u{11959}\u{119A0}-\u{119A7}\u{119AA}-\u{119D3}\u{119DC}-\u{119DF}\u{119E1}-\u{119E4}\u{11A00}\u{11A07}\u{11A08}\u{11A0B}-\u{11A32}\u{11A39}\u{11A3A}\u{11A3F}-\u{11A46}\u{11A50}\u{11A57}\u{11A58}\u{11A5C}-\u{11A89}\u{11A97}\u{11A9A}-\u{11AA2}\u{11AB0}-\u{11AF8}\u{11B00}-\u{11B09}\u{11BC0}-\u{11BE1}\u{11BF0}-\u{11BF9}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2F}\u{11C3E}-\u{11C45}\u{11C50}-\u{11C6C}\u{11C70}-\u{11C8F}\u{11CA9}\u{11CB1}\u{11CB4}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D50}-\u{11D59}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D8E}\u{11D93}\u{11D94}\u{11D96}\u{11D98}\u{11DA0}-\u{11DA9}\u{11EE0}-\u{11EF2}\u{11EF5}-\u{11EF8}\u{11F02}-\u{11F10}\u{11F12}-\u{11F35}\u{11F3E}\u{11F3F}\u{11F41}\u{11F43}-\u{11F59}\u{11FB0}\u{11FC0}-\u{11FD4}\u{11FFF}-\u{12399}\u{12400}-\u{1246E}\u{12470}-\u{12474}\u{12480}-\u{12543}\u{12F90}-\u{12FF2}\u{13000}-\u{1343F}\u{13441}-\u{13446}\u{13460}-\u{143FA}\u{14400}-\u{14646}\u{16100}-\u{1611D}\u{1612A}-\u{1612C}\u{16130}-\u{16139}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16A60}-\u{16A69}\u{16A6E}-\u{16ABE}\u{16AC0}-\u{16AC9}\u{16AD0}-\u{16AED}\u{16AF5}\u{16B00}-\u{16B2F}\u{16B37}-\u{16B45}\u{16B50}-\u{16B59}\u{16B5B}-\u{16B61}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16D40}-\u{16D79}\u{16E40}-\u{16E9A}\u{16F00}-\u{16F4A}\u{16F50}-\u{16F87}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{16FE3}\u{16FF0}\u{16FF1}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18CFF}-\u{18D08}\u{1AFF0}-\u{1AFF3}\u{1AFF5}-\u{1AFFB}\u{1AFFD}\u{1AFFE}\u{1B000}-\u{1B122}\u{1B132}\u{1B150}-\u{1B152}\u{1B155}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1BC9C}\u{1BC9F}\u{1CCD6}-\u{1CCF9}\u{1CF50}-\u{1CFC3}\u{1D000}-\u{1D0F5}\u{1D100}-\u{1D126}\u{1D129}-\u{1D166}\u{1D16A}-\u{1D172}\u{1D183}\u{1D184}\u{1D18C}-\u{1D1A9}\u{1D1AE}-\u{1D1E8}\u{1D2C0}-\u{1D2D3}\u{1D2E0}-\u{1D2F3}\u{1D360}-\u{1D378}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1D7CE}-\u{1D9FF}\u{1DA37}-\u{1DA3A}\u{1DA6D}-\u{1DA74}\u{1DA76}-\u{1DA83}\u{1DA85}-\u{1DA8B}\u{1DF00}-\u{1DF1E}\u{1DF25}-\u{1DF2A}\u{1E030}-\u{1E06D}\u{1E100}-\u{1E12C}\u{1E137}-\u{1E13D}\u{1E140}-\u{1E149}\u{1E14E}\u{1E14F}\u{1E290}-\u{1E2AD}\u{1E2C0}-\u{1E2EB}\u{1E2F0}-\u{1E2F9}\u{1E4D0}-\u{1E4EB}\u{1E4F0}-\u{1E4F9}\u{1E5D0}-\u{1E5ED}\u{1E5F0}-\u{1E5FA}\u{1E5FF}\u{1E7E0}-\u{1E7E6}\u{1E7E8}-\u{1E7EB}\u{1E7ED}\u{1E7EE}\u{1E7F0}-\u{1E7FE}\u{1F100}-\u{1F10A}\u{1F110}-\u{1F12E}\u{1F130}-\u{1F169}\u{1F170}-\u{1F1AC}\u{1F1E6}-\u{1F202}\u{1F210}-\u{1F23B}\u{1F240}-\u{1F248}\u{1F250}\u{1F251}\u{1FBF0}-\u{1FBF9}\u{20000}-\u{2A6DF}\u{2A700}-\u{2B739}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2EBF0}-\u{2EE5D}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}\u{31350}-\u{323AF}\u{F0000}-\u{FFFFD}\u{100000}-\u{10FFFD}][\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u0897-\u089F\u08CA-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09C1-\u09C4\u09CD\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3F\u0B41-\u0B44\u0B4D\u0B55\u0B56\u0B62\u0B63\u0B82\u0BC0\u0BCD\u0C00\u0C04\u0C3C\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CCC\u0CCD\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D41-\u0D44\u0D4D\u0D62\u0D63\u0D81\u0DCA\u0DD2-\u0DD4\u0DD6\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECE\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732\u1733\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u180F\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1ACE\u1B00-\u1B03\u1B34\u1B36-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302D\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\u{101FD}\u{102E0}\u{10376}-\u{1037A}\u{10A01}-\u{10A03}\u{10A05}\u{10A06}\u{10A0C}-\u{10A0F}\u{10A38}-\u{10A3A}\u{10A3F}\u{10AE5}\u{10AE6}\u{10D24}-\u{10D27}\u{10D69}-\u{10D6D}\u{10EAB}\u{10EAC}\u{10EFC}-\u{10EFF}\u{10F46}-\u{10F50}\u{10F82}-\u{10F85}\u{11001}\u{11038}-\u{11046}\u{11070}\u{11073}\u{11074}\u{1107F}-\u{11081}\u{110B3}-\u{110B6}\u{110B9}\u{110BA}\u{110C2}\u{11100}-\u{11102}\u{11127}-\u{1112B}\u{1112D}-\u{11134}\u{11173}\u{11180}\u{11181}\u{111B6}-\u{111BE}\u{111C9}-\u{111CC}\u{111CF}\u{1122F}-\u{11231}\u{11234}\u{11236}\u{11237}\u{1123E}\u{11241}\u{112DF}\u{112E3}-\u{112EA}\u{11300}\u{11301}\u{1133B}\u{1133C}\u{11340}\u{11366}-\u{1136C}\u{11370}-\u{11374}\u{113BB}-\u{113C0}\u{113CE}\u{113D0}\u{113D2}\u{113E1}\u{113E2}\u{11438}-\u{1143F}\u{11442}-\u{11444}\u{11446}\u{1145E}\u{114B3}-\u{114B8}\u{114BA}\u{114BF}\u{114C0}\u{114C2}\u{114C3}\u{115B2}-\u{115B5}\u{115BC}\u{115BD}\u{115BF}\u{115C0}\u{115DC}\u{115DD}\u{11633}-\u{1163A}\u{1163D}\u{1163F}\u{11640}\u{116AB}\u{116AD}\u{116B0}-\u{116B5}\u{116B7}\u{1171D}\u{1171F}\u{11722}-\u{11725}\u{11727}-\u{1172B}\u{1182F}-\u{11837}\u{11839}\u{1183A}\u{1193B}\u{1193C}\u{1193E}\u{11943}\u{119D4}-\u{119D7}\u{119DA}\u{119DB}\u{119E0}\u{11A01}-\u{11A06}\u{11A09}\u{11A0A}\u{11A33}-\u{11A38}\u{11A3B}-\u{11A3E}\u{11A47}\u{11A51}-\u{11A56}\u{11A59}-\u{11A5B}\u{11A8A}-\u{11A96}\u{11A98}\u{11A99}\u{11C30}-\u{11C36}\u{11C38}-\u{11C3D}\u{11C92}-\u{11CA7}\u{11CAA}-\u{11CB0}\u{11CB2}\u{11CB3}\u{11CB5}\u{11CB6}\u{11D31}-\u{11D36}\u{11D3A}\u{11D3C}\u{11D3D}\u{11D3F}-\u{11D45}\u{11D47}\u{11D90}\u{11D91}\u{11D95}\u{11D97}\u{11EF3}\u{11EF4}\u{11F00}\u{11F01}\u{11F36}-\u{11F3A}\u{11F40}\u{11F42}\u{11F5A}\u{13440}\u{13447}-\u{13455}\u{1611E}-\u{16129}\u{1612D}-\u{1612F}\u{16AF0}-\u{16AF4}\u{16B30}-\u{16B36}\u{16F4F}\u{16F8F}-\u{16F92}\u{16FE4}\u{1BC9D}\u{1BC9E}\u{1CF00}-\u{1CF2D}\u{1CF30}-\u{1CF46}\u{1D167}-\u{1D169}\u{1D17B}-\u{1D182}\u{1D185}-\u{1D18B}\u{1D1AA}-\u{1D1AD}\u{1D242}-\u{1D244}\u{1DA00}-\u{1DA36}\u{1DA3B}-\u{1DA6C}\u{1DA75}\u{1DA84}\u{1DA9B}-\u{1DA9F}\u{1DAA1}-\u{1DAAF}\u{1E000}-\u{1E006}\u{1E008}-\u{1E018}\u{1E01B}-\u{1E021}\u{1E023}\u{1E024}\u{1E026}-\u{1E02A}\u{1E08F}\u{1E130}-\u{1E136}\u{1E2AE}\u{1E2EC}-\u{1E2EF}\u{1E4EC}-\u{1E4EF}\u{1E5EE}\u{1E5EF}\u{1E8D0}-\u{1E8D6}\u{1E944}-\u{1E94A}\u{E0100}-\u{E01EF}]*$/u; - module3.exports = { - combiningMarks, - combiningClassVirama, - validZWNJ, - bidiDomain, - bidiS1LTR, - bidiS1RTL, - bidiS2, - bidiS3, - bidiS4EN, - bidiS4AN, - bidiS5, - bidiS6 - }; - } -}); - -// node_modules/tr46/lib/mappingTable.json -var require_mappingTable = __commonJS({ - "node_modules/tr46/lib/mappingTable.json"(exports2, module3) { - module3.exports = [[[0, 44], 2], [[45, 46], 2], [47, 2], [[48, 57], 2], [[58, 64], 2], [65, 1, "a"], [66, 1, "b"], [67, 1, "c"], [68, 1, "d"], [69, 1, "e"], [70, 1, "f"], [71, 1, "g"], [72, 1, "h"], [73, 1, "i"], [74, 1, "j"], [75, 1, "k"], [76, 1, "l"], [77, 1, "m"], [78, 1, "n"], [79, 1, "o"], [80, 1, "p"], [81, 1, "q"], [82, 1, "r"], [83, 1, "s"], [84, 1, "t"], [85, 1, "u"], [86, 1, "v"], [87, 1, "w"], [88, 1, "x"], [89, 1, "y"], [90, 1, "z"], [[91, 96], 2], [[97, 122], 2], [[123, 127], 2], [[128, 159], 3], [160, 1, " "], [[161, 167], 2], [168, 1, " \u0308"], [169, 2], [170, 1, "a"], [[171, 172], 2], [173, 7], [174, 2], [175, 1, " \u0304"], [[176, 177], 2], [178, 1, "2"], [179, 1, "3"], [180, 1, " \u0301"], [181, 1, "\u03BC"], [182, 2], [183, 2], [184, 1, " \u0327"], [185, 1, "1"], [186, 1, "o"], [187, 2], [188, 1, "1\u20444"], [189, 1, "1\u20442"], [190, 1, "3\u20444"], [191, 2], [192, 1, "\xE0"], [193, 1, "\xE1"], [194, 1, "\xE2"], [195, 1, "\xE3"], [196, 1, "\xE4"], [197, 1, "\xE5"], [198, 1, "\xE6"], [199, 1, "\xE7"], [200, 1, "\xE8"], [201, 1, "\xE9"], [202, 1, "\xEA"], [203, 1, "\xEB"], [204, 1, "\xEC"], [205, 1, "\xED"], [206, 1, "\xEE"], [207, 1, "\xEF"], [208, 1, "\xF0"], [209, 1, "\xF1"], [210, 1, "\xF2"], [211, 1, "\xF3"], [212, 1, "\xF4"], [213, 1, "\xF5"], [214, 1, "\xF6"], [215, 2], [216, 1, "\xF8"], [217, 1, "\xF9"], [218, 1, "\xFA"], [219, 1, "\xFB"], [220, 1, "\xFC"], [221, 1, "\xFD"], [222, 1, "\xFE"], [223, 6, "ss"], [[224, 246], 2], [247, 2], [[248, 255], 2], [256, 1, "\u0101"], [257, 2], [258, 1, "\u0103"], [259, 2], [260, 1, "\u0105"], [261, 2], [262, 1, "\u0107"], [263, 2], [264, 1, "\u0109"], [265, 2], [266, 1, "\u010B"], [267, 2], [268, 1, "\u010D"], [269, 2], [270, 1, "\u010F"], [271, 2], [272, 1, "\u0111"], [273, 2], [274, 1, "\u0113"], [275, 2], [276, 1, "\u0115"], [277, 2], [278, 1, "\u0117"], [279, 2], [280, 1, "\u0119"], [281, 2], [282, 1, "\u011B"], [283, 2], [284, 1, "\u011D"], [285, 2], [286, 1, "\u011F"], [287, 2], [288, 1, "\u0121"], [289, 2], [290, 1, "\u0123"], [291, 2], [292, 1, "\u0125"], [293, 2], [294, 1, "\u0127"], [295, 2], [296, 1, "\u0129"], [297, 2], [298, 1, "\u012B"], [299, 2], [300, 1, "\u012D"], [301, 2], [302, 1, "\u012F"], [303, 2], [304, 1, "i\u0307"], [305, 2], [[306, 307], 1, "ij"], [308, 1, "\u0135"], [309, 2], [310, 1, "\u0137"], [[311, 312], 2], [313, 1, "\u013A"], [314, 2], [315, 1, "\u013C"], [316, 2], [317, 1, "\u013E"], [318, 2], [[319, 320], 1, "l\xB7"], [321, 1, "\u0142"], [322, 2], [323, 1, "\u0144"], [324, 2], [325, 1, "\u0146"], [326, 2], [327, 1, "\u0148"], [328, 2], [329, 1, "\u02BCn"], [330, 1, "\u014B"], [331, 2], [332, 1, "\u014D"], [333, 2], [334, 1, "\u014F"], [335, 2], [336, 1, "\u0151"], [337, 2], [338, 1, "\u0153"], [339, 2], [340, 1, "\u0155"], [341, 2], [342, 1, "\u0157"], [343, 2], [344, 1, "\u0159"], [345, 2], [346, 1, "\u015B"], [347, 2], [348, 1, "\u015D"], [349, 2], [350, 1, "\u015F"], [351, 2], [352, 1, "\u0161"], [353, 2], [354, 1, "\u0163"], [355, 2], [356, 1, "\u0165"], [357, 2], [358, 1, "\u0167"], [359, 2], [360, 1, "\u0169"], [361, 2], [362, 1, "\u016B"], [363, 2], [364, 1, "\u016D"], [365, 2], [366, 1, "\u016F"], [367, 2], [368, 1, "\u0171"], [369, 2], [370, 1, "\u0173"], [371, 2], [372, 1, "\u0175"], [373, 2], [374, 1, "\u0177"], [375, 2], [376, 1, "\xFF"], [377, 1, "\u017A"], [378, 2], [379, 1, "\u017C"], [380, 2], [381, 1, "\u017E"], [382, 2], [383, 1, "s"], [384, 2], [385, 1, "\u0253"], [386, 1, "\u0183"], [387, 2], [388, 1, "\u0185"], [389, 2], [390, 1, "\u0254"], [391, 1, "\u0188"], [392, 2], [393, 1, "\u0256"], [394, 1, "\u0257"], [395, 1, "\u018C"], [[396, 397], 2], [398, 1, "\u01DD"], [399, 1, "\u0259"], [400, 1, "\u025B"], [401, 1, "\u0192"], [402, 2], [403, 1, "\u0260"], [404, 1, "\u0263"], [405, 2], [406, 1, "\u0269"], [407, 1, "\u0268"], [408, 1, "\u0199"], [[409, 411], 2], [412, 1, "\u026F"], [413, 1, "\u0272"], [414, 2], [415, 1, "\u0275"], [416, 1, "\u01A1"], [417, 2], [418, 1, "\u01A3"], [419, 2], [420, 1, "\u01A5"], [421, 2], [422, 1, "\u0280"], [423, 1, "\u01A8"], [424, 2], [425, 1, "\u0283"], [[426, 427], 2], [428, 1, "\u01AD"], [429, 2], [430, 1, "\u0288"], [431, 1, "\u01B0"], [432, 2], [433, 1, "\u028A"], [434, 1, "\u028B"], [435, 1, "\u01B4"], [436, 2], [437, 1, "\u01B6"], [438, 2], [439, 1, "\u0292"], [440, 1, "\u01B9"], [[441, 443], 2], [444, 1, "\u01BD"], [[445, 451], 2], [[452, 454], 1, "d\u017E"], [[455, 457], 1, "lj"], [[458, 460], 1, "nj"], [461, 1, "\u01CE"], [462, 2], [463, 1, "\u01D0"], [464, 2], [465, 1, "\u01D2"], [466, 2], [467, 1, "\u01D4"], [468, 2], [469, 1, "\u01D6"], [470, 2], [471, 1, "\u01D8"], [472, 2], [473, 1, "\u01DA"], [474, 2], [475, 1, "\u01DC"], [[476, 477], 2], [478, 1, "\u01DF"], [479, 2], [480, 1, "\u01E1"], [481, 2], [482, 1, "\u01E3"], [483, 2], [484, 1, "\u01E5"], [485, 2], [486, 1, "\u01E7"], [487, 2], [488, 1, "\u01E9"], [489, 2], [490, 1, "\u01EB"], [491, 2], [492, 1, "\u01ED"], [493, 2], [494, 1, "\u01EF"], [[495, 496], 2], [[497, 499], 1, "dz"], [500, 1, "\u01F5"], [501, 2], [502, 1, "\u0195"], [503, 1, "\u01BF"], [504, 1, "\u01F9"], [505, 2], [506, 1, "\u01FB"], [507, 2], [508, 1, "\u01FD"], [509, 2], [510, 1, "\u01FF"], [511, 2], [512, 1, "\u0201"], [513, 2], [514, 1, "\u0203"], [515, 2], [516, 1, "\u0205"], [517, 2], [518, 1, "\u0207"], [519, 2], [520, 1, "\u0209"], [521, 2], [522, 1, "\u020B"], [523, 2], [524, 1, "\u020D"], [525, 2], [526, 1, "\u020F"], [527, 2], [528, 1, "\u0211"], [529, 2], [530, 1, "\u0213"], [531, 2], [532, 1, "\u0215"], [533, 2], [534, 1, "\u0217"], [535, 2], [536, 1, "\u0219"], [537, 2], [538, 1, "\u021B"], [539, 2], [540, 1, "\u021D"], [541, 2], [542, 1, "\u021F"], [543, 2], [544, 1, "\u019E"], [545, 2], [546, 1, "\u0223"], [547, 2], [548, 1, "\u0225"], [549, 2], [550, 1, "\u0227"], [551, 2], [552, 1, "\u0229"], [553, 2], [554, 1, "\u022B"], [555, 2], [556, 1, "\u022D"], [557, 2], [558, 1, "\u022F"], [559, 2], [560, 1, "\u0231"], [561, 2], [562, 1, "\u0233"], [563, 2], [[564, 566], 2], [[567, 569], 2], [570, 1, "\u2C65"], [571, 1, "\u023C"], [572, 2], [573, 1, "\u019A"], [574, 1, "\u2C66"], [[575, 576], 2], [577, 1, "\u0242"], [578, 2], [579, 1, "\u0180"], [580, 1, "\u0289"], [581, 1, "\u028C"], [582, 1, "\u0247"], [583, 2], [584, 1, "\u0249"], [585, 2], [586, 1, "\u024B"], [587, 2], [588, 1, "\u024D"], [589, 2], [590, 1, "\u024F"], [591, 2], [[592, 680], 2], [[681, 685], 2], [[686, 687], 2], [688, 1, "h"], [689, 1, "\u0266"], [690, 1, "j"], [691, 1, "r"], [692, 1, "\u0279"], [693, 1, "\u027B"], [694, 1, "\u0281"], [695, 1, "w"], [696, 1, "y"], [[697, 705], 2], [[706, 709], 2], [[710, 721], 2], [[722, 727], 2], [728, 1, " \u0306"], [729, 1, " \u0307"], [730, 1, " \u030A"], [731, 1, " \u0328"], [732, 1, " \u0303"], [733, 1, " \u030B"], [734, 2], [735, 2], [736, 1, "\u0263"], [737, 1, "l"], [738, 1, "s"], [739, 1, "x"], [740, 1, "\u0295"], [[741, 745], 2], [[746, 747], 2], [748, 2], [749, 2], [750, 2], [[751, 767], 2], [[768, 831], 2], [832, 1, "\u0300"], [833, 1, "\u0301"], [834, 2], [835, 1, "\u0313"], [836, 1, "\u0308\u0301"], [837, 1, "\u03B9"], [[838, 846], 2], [847, 7], [[848, 855], 2], [[856, 860], 2], [[861, 863], 2], [[864, 865], 2], [866, 2], [[867, 879], 2], [880, 1, "\u0371"], [881, 2], [882, 1, "\u0373"], [883, 2], [884, 1, "\u02B9"], [885, 2], [886, 1, "\u0377"], [887, 2], [[888, 889], 3], [890, 1, " \u03B9"], [[891, 893], 2], [894, 1, ";"], [895, 1, "\u03F3"], [[896, 899], 3], [900, 1, " \u0301"], [901, 1, " \u0308\u0301"], [902, 1, "\u03AC"], [903, 1, "\xB7"], [904, 1, "\u03AD"], [905, 1, "\u03AE"], [906, 1, "\u03AF"], [907, 3], [908, 1, "\u03CC"], [909, 3], [910, 1, "\u03CD"], [911, 1, "\u03CE"], [912, 2], [913, 1, "\u03B1"], [914, 1, "\u03B2"], [915, 1, "\u03B3"], [916, 1, "\u03B4"], [917, 1, "\u03B5"], [918, 1, "\u03B6"], [919, 1, "\u03B7"], [920, 1, "\u03B8"], [921, 1, "\u03B9"], [922, 1, "\u03BA"], [923, 1, "\u03BB"], [924, 1, "\u03BC"], [925, 1, "\u03BD"], [926, 1, "\u03BE"], [927, 1, "\u03BF"], [928, 1, "\u03C0"], [929, 1, "\u03C1"], [930, 3], [931, 1, "\u03C3"], [932, 1, "\u03C4"], [933, 1, "\u03C5"], [934, 1, "\u03C6"], [935, 1, "\u03C7"], [936, 1, "\u03C8"], [937, 1, "\u03C9"], [938, 1, "\u03CA"], [939, 1, "\u03CB"], [[940, 961], 2], [962, 6, "\u03C3"], [[963, 974], 2], [975, 1, "\u03D7"], [976, 1, "\u03B2"], [977, 1, "\u03B8"], [978, 1, "\u03C5"], [979, 1, "\u03CD"], [980, 1, "\u03CB"], [981, 1, "\u03C6"], [982, 1, "\u03C0"], [983, 2], [984, 1, "\u03D9"], [985, 2], [986, 1, "\u03DB"], [987, 2], [988, 1, "\u03DD"], [989, 2], [990, 1, "\u03DF"], [991, 2], [992, 1, "\u03E1"], [993, 2], [994, 1, "\u03E3"], [995, 2], [996, 1, "\u03E5"], [997, 2], [998, 1, "\u03E7"], [999, 2], [1e3, 1, "\u03E9"], [1001, 2], [1002, 1, "\u03EB"], [1003, 2], [1004, 1, "\u03ED"], [1005, 2], [1006, 1, "\u03EF"], [1007, 2], [1008, 1, "\u03BA"], [1009, 1, "\u03C1"], [1010, 1, "\u03C3"], [1011, 2], [1012, 1, "\u03B8"], [1013, 1, "\u03B5"], [1014, 2], [1015, 1, "\u03F8"], [1016, 2], [1017, 1, "\u03C3"], [1018, 1, "\u03FB"], [1019, 2], [1020, 2], [1021, 1, "\u037B"], [1022, 1, "\u037C"], [1023, 1, "\u037D"], [1024, 1, "\u0450"], [1025, 1, "\u0451"], [1026, 1, "\u0452"], [1027, 1, "\u0453"], [1028, 1, "\u0454"], [1029, 1, "\u0455"], [1030, 1, "\u0456"], [1031, 1, "\u0457"], [1032, 1, "\u0458"], [1033, 1, "\u0459"], [1034, 1, "\u045A"], [1035, 1, "\u045B"], [1036, 1, "\u045C"], [1037, 1, "\u045D"], [1038, 1, "\u045E"], [1039, 1, "\u045F"], [1040, 1, "\u0430"], [1041, 1, "\u0431"], [1042, 1, "\u0432"], [1043, 1, "\u0433"], [1044, 1, "\u0434"], [1045, 1, "\u0435"], [1046, 1, "\u0436"], [1047, 1, "\u0437"], [1048, 1, "\u0438"], [1049, 1, "\u0439"], [1050, 1, "\u043A"], [1051, 1, "\u043B"], [1052, 1, "\u043C"], [1053, 1, "\u043D"], [1054, 1, "\u043E"], [1055, 1, "\u043F"], [1056, 1, "\u0440"], [1057, 1, "\u0441"], [1058, 1, "\u0442"], [1059, 1, "\u0443"], [1060, 1, "\u0444"], [1061, 1, "\u0445"], [1062, 1, "\u0446"], [1063, 1, "\u0447"], [1064, 1, "\u0448"], [1065, 1, "\u0449"], [1066, 1, "\u044A"], [1067, 1, "\u044B"], [1068, 1, "\u044C"], [1069, 1, "\u044D"], [1070, 1, "\u044E"], [1071, 1, "\u044F"], [[1072, 1103], 2], [1104, 2], [[1105, 1116], 2], [1117, 2], [[1118, 1119], 2], [1120, 1, "\u0461"], [1121, 2], [1122, 1, "\u0463"], [1123, 2], [1124, 1, "\u0465"], [1125, 2], [1126, 1, "\u0467"], [1127, 2], [1128, 1, "\u0469"], [1129, 2], [1130, 1, "\u046B"], [1131, 2], [1132, 1, "\u046D"], [1133, 2], [1134, 1, "\u046F"], [1135, 2], [1136, 1, "\u0471"], [1137, 2], [1138, 1, "\u0473"], [1139, 2], [1140, 1, "\u0475"], [1141, 2], [1142, 1, "\u0477"], [1143, 2], [1144, 1, "\u0479"], [1145, 2], [1146, 1, "\u047B"], [1147, 2], [1148, 1, "\u047D"], [1149, 2], [1150, 1, "\u047F"], [1151, 2], [1152, 1, "\u0481"], [1153, 2], [1154, 2], [[1155, 1158], 2], [1159, 2], [[1160, 1161], 2], [1162, 1, "\u048B"], [1163, 2], [1164, 1, "\u048D"], [1165, 2], [1166, 1, "\u048F"], [1167, 2], [1168, 1, "\u0491"], [1169, 2], [1170, 1, "\u0493"], [1171, 2], [1172, 1, "\u0495"], [1173, 2], [1174, 1, "\u0497"], [1175, 2], [1176, 1, "\u0499"], [1177, 2], [1178, 1, "\u049B"], [1179, 2], [1180, 1, "\u049D"], [1181, 2], [1182, 1, "\u049F"], [1183, 2], [1184, 1, "\u04A1"], [1185, 2], [1186, 1, "\u04A3"], [1187, 2], [1188, 1, "\u04A5"], [1189, 2], [1190, 1, "\u04A7"], [1191, 2], [1192, 1, "\u04A9"], [1193, 2], [1194, 1, "\u04AB"], [1195, 2], [1196, 1, "\u04AD"], [1197, 2], [1198, 1, "\u04AF"], [1199, 2], [1200, 1, "\u04B1"], [1201, 2], [1202, 1, "\u04B3"], [1203, 2], [1204, 1, "\u04B5"], [1205, 2], [1206, 1, "\u04B7"], [1207, 2], [1208, 1, "\u04B9"], [1209, 2], [1210, 1, "\u04BB"], [1211, 2], [1212, 1, "\u04BD"], [1213, 2], [1214, 1, "\u04BF"], [1215, 2], [1216, 1, "\u04CF"], [1217, 1, "\u04C2"], [1218, 2], [1219, 1, "\u04C4"], [1220, 2], [1221, 1, "\u04C6"], [1222, 2], [1223, 1, "\u04C8"], [1224, 2], [1225, 1, "\u04CA"], [1226, 2], [1227, 1, "\u04CC"], [1228, 2], [1229, 1, "\u04CE"], [1230, 2], [1231, 2], [1232, 1, "\u04D1"], [1233, 2], [1234, 1, "\u04D3"], [1235, 2], [1236, 1, "\u04D5"], [1237, 2], [1238, 1, "\u04D7"], [1239, 2], [1240, 1, "\u04D9"], [1241, 2], [1242, 1, "\u04DB"], [1243, 2], [1244, 1, "\u04DD"], [1245, 2], [1246, 1, "\u04DF"], [1247, 2], [1248, 1, "\u04E1"], [1249, 2], [1250, 1, "\u04E3"], [1251, 2], [1252, 1, "\u04E5"], [1253, 2], [1254, 1, "\u04E7"], [1255, 2], [1256, 1, "\u04E9"], [1257, 2], [1258, 1, "\u04EB"], [1259, 2], [1260, 1, "\u04ED"], [1261, 2], [1262, 1, "\u04EF"], [1263, 2], [1264, 1, "\u04F1"], [1265, 2], [1266, 1, "\u04F3"], [1267, 2], [1268, 1, "\u04F5"], [1269, 2], [1270, 1, "\u04F7"], [1271, 2], [1272, 1, "\u04F9"], [1273, 2], [1274, 1, "\u04FB"], [1275, 2], [1276, 1, "\u04FD"], [1277, 2], [1278, 1, "\u04FF"], [1279, 2], [1280, 1, "\u0501"], [1281, 2], [1282, 1, "\u0503"], [1283, 2], [1284, 1, "\u0505"], [1285, 2], [1286, 1, "\u0507"], [1287, 2], [1288, 1, "\u0509"], [1289, 2], [1290, 1, "\u050B"], [1291, 2], [1292, 1, "\u050D"], [1293, 2], [1294, 1, "\u050F"], [1295, 2], [1296, 1, "\u0511"], [1297, 2], [1298, 1, "\u0513"], [1299, 2], [1300, 1, "\u0515"], [1301, 2], [1302, 1, "\u0517"], [1303, 2], [1304, 1, "\u0519"], [1305, 2], [1306, 1, "\u051B"], [1307, 2], [1308, 1, "\u051D"], [1309, 2], [1310, 1, "\u051F"], [1311, 2], [1312, 1, "\u0521"], [1313, 2], [1314, 1, "\u0523"], [1315, 2], [1316, 1, "\u0525"], [1317, 2], [1318, 1, "\u0527"], [1319, 2], [1320, 1, "\u0529"], [1321, 2], [1322, 1, "\u052B"], [1323, 2], [1324, 1, "\u052D"], [1325, 2], [1326, 1, "\u052F"], [1327, 2], [1328, 3], [1329, 1, "\u0561"], [1330, 1, "\u0562"], [1331, 1, "\u0563"], [1332, 1, "\u0564"], [1333, 1, "\u0565"], [1334, 1, "\u0566"], [1335, 1, "\u0567"], [1336, 1, "\u0568"], [1337, 1, "\u0569"], [1338, 1, "\u056A"], [1339, 1, "\u056B"], [1340, 1, "\u056C"], [1341, 1, "\u056D"], [1342, 1, "\u056E"], [1343, 1, "\u056F"], [1344, 1, "\u0570"], [1345, 1, "\u0571"], [1346, 1, "\u0572"], [1347, 1, "\u0573"], [1348, 1, "\u0574"], [1349, 1, "\u0575"], [1350, 1, "\u0576"], [1351, 1, "\u0577"], [1352, 1, "\u0578"], [1353, 1, "\u0579"], [1354, 1, "\u057A"], [1355, 1, "\u057B"], [1356, 1, "\u057C"], [1357, 1, "\u057D"], [1358, 1, "\u057E"], [1359, 1, "\u057F"], [1360, 1, "\u0580"], [1361, 1, "\u0581"], [1362, 1, "\u0582"], [1363, 1, "\u0583"], [1364, 1, "\u0584"], [1365, 1, "\u0585"], [1366, 1, "\u0586"], [[1367, 1368], 3], [1369, 2], [[1370, 1375], 2], [1376, 2], [[1377, 1414], 2], [1415, 1, "\u0565\u0582"], [1416, 2], [1417, 2], [1418, 2], [[1419, 1420], 3], [[1421, 1422], 2], [1423, 2], [1424, 3], [[1425, 1441], 2], [1442, 2], [[1443, 1455], 2], [[1456, 1465], 2], [1466, 2], [[1467, 1469], 2], [1470, 2], [1471, 2], [1472, 2], [[1473, 1474], 2], [1475, 2], [1476, 2], [1477, 2], [1478, 2], [1479, 2], [[1480, 1487], 3], [[1488, 1514], 2], [[1515, 1518], 3], [1519, 2], [[1520, 1524], 2], [[1525, 1535], 3], [[1536, 1539], 3], [1540, 3], [1541, 3], [[1542, 1546], 2], [1547, 2], [1548, 2], [[1549, 1551], 2], [[1552, 1557], 2], [[1558, 1562], 2], [1563, 2], [1564, 3], [1565, 2], [1566, 2], [1567, 2], [1568, 2], [[1569, 1594], 2], [[1595, 1599], 2], [1600, 2], [[1601, 1618], 2], [[1619, 1621], 2], [[1622, 1624], 2], [[1625, 1630], 2], [1631, 2], [[1632, 1641], 2], [[1642, 1645], 2], [[1646, 1647], 2], [[1648, 1652], 2], [1653, 1, "\u0627\u0674"], [1654, 1, "\u0648\u0674"], [1655, 1, "\u06C7\u0674"], [1656, 1, "\u064A\u0674"], [[1657, 1719], 2], [[1720, 1721], 2], [[1722, 1726], 2], [1727, 2], [[1728, 1742], 2], [1743, 2], [[1744, 1747], 2], [1748, 2], [[1749, 1756], 2], [1757, 3], [1758, 2], [[1759, 1768], 2], [1769, 2], [[1770, 1773], 2], [[1774, 1775], 2], [[1776, 1785], 2], [[1786, 1790], 2], [1791, 2], [[1792, 1805], 2], [1806, 3], [1807, 3], [[1808, 1836], 2], [[1837, 1839], 2], [[1840, 1866], 2], [[1867, 1868], 3], [[1869, 1871], 2], [[1872, 1901], 2], [[1902, 1919], 2], [[1920, 1968], 2], [1969, 2], [[1970, 1983], 3], [[1984, 2037], 2], [[2038, 2042], 2], [[2043, 2044], 3], [2045, 2], [[2046, 2047], 2], [[2048, 2093], 2], [[2094, 2095], 3], [[2096, 2110], 2], [2111, 3], [[2112, 2139], 2], [[2140, 2141], 3], [2142, 2], [2143, 3], [[2144, 2154], 2], [[2155, 2159], 3], [[2160, 2183], 2], [2184, 2], [[2185, 2190], 2], [2191, 3], [[2192, 2193], 3], [[2194, 2198], 3], [2199, 2], [[2200, 2207], 2], [2208, 2], [2209, 2], [[2210, 2220], 2], [[2221, 2226], 2], [[2227, 2228], 2], [2229, 2], [[2230, 2237], 2], [[2238, 2247], 2], [[2248, 2258], 2], [2259, 2], [[2260, 2273], 2], [2274, 3], [2275, 2], [[2276, 2302], 2], [2303, 2], [2304, 2], [[2305, 2307], 2], [2308, 2], [[2309, 2361], 2], [[2362, 2363], 2], [[2364, 2381], 2], [2382, 2], [2383, 2], [[2384, 2388], 2], [2389, 2], [[2390, 2391], 2], [2392, 1, "\u0915\u093C"], [2393, 1, "\u0916\u093C"], [2394, 1, "\u0917\u093C"], [2395, 1, "\u091C\u093C"], [2396, 1, "\u0921\u093C"], [2397, 1, "\u0922\u093C"], [2398, 1, "\u092B\u093C"], [2399, 1, "\u092F\u093C"], [[2400, 2403], 2], [[2404, 2405], 2], [[2406, 2415], 2], [2416, 2], [[2417, 2418], 2], [[2419, 2423], 2], [2424, 2], [[2425, 2426], 2], [[2427, 2428], 2], [2429, 2], [[2430, 2431], 2], [2432, 2], [[2433, 2435], 2], [2436, 3], [[2437, 2444], 2], [[2445, 2446], 3], [[2447, 2448], 2], [[2449, 2450], 3], [[2451, 2472], 2], [2473, 3], [[2474, 2480], 2], [2481, 3], [2482, 2], [[2483, 2485], 3], [[2486, 2489], 2], [[2490, 2491], 3], [2492, 2], [2493, 2], [[2494, 2500], 2], [[2501, 2502], 3], [[2503, 2504], 2], [[2505, 2506], 3], [[2507, 2509], 2], [2510, 2], [[2511, 2518], 3], [2519, 2], [[2520, 2523], 3], [2524, 1, "\u09A1\u09BC"], [2525, 1, "\u09A2\u09BC"], [2526, 3], [2527, 1, "\u09AF\u09BC"], [[2528, 2531], 2], [[2532, 2533], 3], [[2534, 2545], 2], [[2546, 2554], 2], [2555, 2], [2556, 2], [2557, 2], [2558, 2], [[2559, 2560], 3], [2561, 2], [2562, 2], [2563, 2], [2564, 3], [[2565, 2570], 2], [[2571, 2574], 3], [[2575, 2576], 2], [[2577, 2578], 3], [[2579, 2600], 2], [2601, 3], [[2602, 2608], 2], [2609, 3], [2610, 2], [2611, 1, "\u0A32\u0A3C"], [2612, 3], [2613, 2], [2614, 1, "\u0A38\u0A3C"], [2615, 3], [[2616, 2617], 2], [[2618, 2619], 3], [2620, 2], [2621, 3], [[2622, 2626], 2], [[2627, 2630], 3], [[2631, 2632], 2], [[2633, 2634], 3], [[2635, 2637], 2], [[2638, 2640], 3], [2641, 2], [[2642, 2648], 3], [2649, 1, "\u0A16\u0A3C"], [2650, 1, "\u0A17\u0A3C"], [2651, 1, "\u0A1C\u0A3C"], [2652, 2], [2653, 3], [2654, 1, "\u0A2B\u0A3C"], [[2655, 2661], 3], [[2662, 2676], 2], [2677, 2], [2678, 2], [[2679, 2688], 3], [[2689, 2691], 2], [2692, 3], [[2693, 2699], 2], [2700, 2], [2701, 2], [2702, 3], [[2703, 2705], 2], [2706, 3], [[2707, 2728], 2], [2729, 3], [[2730, 2736], 2], [2737, 3], [[2738, 2739], 2], [2740, 3], [[2741, 2745], 2], [[2746, 2747], 3], [[2748, 2757], 2], [2758, 3], [[2759, 2761], 2], [2762, 3], [[2763, 2765], 2], [[2766, 2767], 3], [2768, 2], [[2769, 2783], 3], [2784, 2], [[2785, 2787], 2], [[2788, 2789], 3], [[2790, 2799], 2], [2800, 2], [2801, 2], [[2802, 2808], 3], [2809, 2], [[2810, 2815], 2], [2816, 3], [[2817, 2819], 2], [2820, 3], [[2821, 2828], 2], [[2829, 2830], 3], [[2831, 2832], 2], [[2833, 2834], 3], [[2835, 2856], 2], [2857, 3], [[2858, 2864], 2], [2865, 3], [[2866, 2867], 2], [2868, 3], [2869, 2], [[2870, 2873], 2], [[2874, 2875], 3], [[2876, 2883], 2], [2884, 2], [[2885, 2886], 3], [[2887, 2888], 2], [[2889, 2890], 3], [[2891, 2893], 2], [[2894, 2900], 3], [2901, 2], [[2902, 2903], 2], [[2904, 2907], 3], [2908, 1, "\u0B21\u0B3C"], [2909, 1, "\u0B22\u0B3C"], [2910, 3], [[2911, 2913], 2], [[2914, 2915], 2], [[2916, 2917], 3], [[2918, 2927], 2], [2928, 2], [2929, 2], [[2930, 2935], 2], [[2936, 2945], 3], [[2946, 2947], 2], [2948, 3], [[2949, 2954], 2], [[2955, 2957], 3], [[2958, 2960], 2], [2961, 3], [[2962, 2965], 2], [[2966, 2968], 3], [[2969, 2970], 2], [2971, 3], [2972, 2], [2973, 3], [[2974, 2975], 2], [[2976, 2978], 3], [[2979, 2980], 2], [[2981, 2983], 3], [[2984, 2986], 2], [[2987, 2989], 3], [[2990, 2997], 2], [2998, 2], [[2999, 3001], 2], [[3002, 3005], 3], [[3006, 3010], 2], [[3011, 3013], 3], [[3014, 3016], 2], [3017, 3], [[3018, 3021], 2], [[3022, 3023], 3], [3024, 2], [[3025, 3030], 3], [3031, 2], [[3032, 3045], 3], [3046, 2], [[3047, 3055], 2], [[3056, 3058], 2], [[3059, 3066], 2], [[3067, 3071], 3], [3072, 2], [[3073, 3075], 2], [3076, 2], [[3077, 3084], 2], [3085, 3], [[3086, 3088], 2], [3089, 3], [[3090, 3112], 2], [3113, 3], [[3114, 3123], 2], [3124, 2], [[3125, 3129], 2], [[3130, 3131], 3], [3132, 2], [3133, 2], [[3134, 3140], 2], [3141, 3], [[3142, 3144], 2], [3145, 3], [[3146, 3149], 2], [[3150, 3156], 3], [[3157, 3158], 2], [3159, 3], [[3160, 3161], 2], [3162, 2], [[3163, 3164], 3], [3165, 2], [[3166, 3167], 3], [[3168, 3169], 2], [[3170, 3171], 2], [[3172, 3173], 3], [[3174, 3183], 2], [[3184, 3190], 3], [3191, 2], [[3192, 3199], 2], [3200, 2], [3201, 2], [[3202, 3203], 2], [3204, 2], [[3205, 3212], 2], [3213, 3], [[3214, 3216], 2], [3217, 3], [[3218, 3240], 2], [3241, 3], [[3242, 3251], 2], [3252, 3], [[3253, 3257], 2], [[3258, 3259], 3], [[3260, 3261], 2], [[3262, 3268], 2], [3269, 3], [[3270, 3272], 2], [3273, 3], [[3274, 3277], 2], [[3278, 3284], 3], [[3285, 3286], 2], [[3287, 3292], 3], [3293, 2], [3294, 2], [3295, 3], [[3296, 3297], 2], [[3298, 3299], 2], [[3300, 3301], 3], [[3302, 3311], 2], [3312, 3], [[3313, 3314], 2], [3315, 2], [[3316, 3327], 3], [3328, 2], [3329, 2], [[3330, 3331], 2], [3332, 2], [[3333, 3340], 2], [3341, 3], [[3342, 3344], 2], [3345, 3], [[3346, 3368], 2], [3369, 2], [[3370, 3385], 2], [3386, 2], [[3387, 3388], 2], [3389, 2], [[3390, 3395], 2], [3396, 2], [3397, 3], [[3398, 3400], 2], [3401, 3], [[3402, 3405], 2], [3406, 2], [3407, 2], [[3408, 3411], 3], [[3412, 3414], 2], [3415, 2], [[3416, 3422], 2], [3423, 2], [[3424, 3425], 2], [[3426, 3427], 2], [[3428, 3429], 3], [[3430, 3439], 2], [[3440, 3445], 2], [[3446, 3448], 2], [3449, 2], [[3450, 3455], 2], [3456, 3], [3457, 2], [[3458, 3459], 2], [3460, 3], [[3461, 3478], 2], [[3479, 3481], 3], [[3482, 3505], 2], [3506, 3], [[3507, 3515], 2], [3516, 3], [3517, 2], [[3518, 3519], 3], [[3520, 3526], 2], [[3527, 3529], 3], [3530, 2], [[3531, 3534], 3], [[3535, 3540], 2], [3541, 3], [3542, 2], [3543, 3], [[3544, 3551], 2], [[3552, 3557], 3], [[3558, 3567], 2], [[3568, 3569], 3], [[3570, 3571], 2], [3572, 2], [[3573, 3584], 3], [[3585, 3634], 2], [3635, 1, "\u0E4D\u0E32"], [[3636, 3642], 2], [[3643, 3646], 3], [3647, 2], [[3648, 3662], 2], [3663, 2], [[3664, 3673], 2], [[3674, 3675], 2], [[3676, 3712], 3], [[3713, 3714], 2], [3715, 3], [3716, 2], [3717, 3], [3718, 2], [[3719, 3720], 2], [3721, 2], [3722, 2], [3723, 3], [3724, 2], [3725, 2], [[3726, 3731], 2], [[3732, 3735], 2], [3736, 2], [[3737, 3743], 2], [3744, 2], [[3745, 3747], 2], [3748, 3], [3749, 2], [3750, 3], [3751, 2], [[3752, 3753], 2], [[3754, 3755], 2], [3756, 2], [[3757, 3762], 2], [3763, 1, "\u0ECD\u0EB2"], [[3764, 3769], 2], [3770, 2], [[3771, 3773], 2], [[3774, 3775], 3], [[3776, 3780], 2], [3781, 3], [3782, 2], [3783, 3], [[3784, 3789], 2], [3790, 2], [3791, 3], [[3792, 3801], 2], [[3802, 3803], 3], [3804, 1, "\u0EAB\u0E99"], [3805, 1, "\u0EAB\u0EA1"], [[3806, 3807], 2], [[3808, 3839], 3], [3840, 2], [[3841, 3850], 2], [3851, 2], [3852, 1, "\u0F0B"], [[3853, 3863], 2], [[3864, 3865], 2], [[3866, 3871], 2], [[3872, 3881], 2], [[3882, 3892], 2], [3893, 2], [3894, 2], [3895, 2], [3896, 2], [3897, 2], [[3898, 3901], 2], [[3902, 3906], 2], [3907, 1, "\u0F42\u0FB7"], [[3908, 3911], 2], [3912, 3], [[3913, 3916], 2], [3917, 1, "\u0F4C\u0FB7"], [[3918, 3921], 2], [3922, 1, "\u0F51\u0FB7"], [[3923, 3926], 2], [3927, 1, "\u0F56\u0FB7"], [[3928, 3931], 2], [3932, 1, "\u0F5B\u0FB7"], [[3933, 3944], 2], [3945, 1, "\u0F40\u0FB5"], [3946, 2], [[3947, 3948], 2], [[3949, 3952], 3], [[3953, 3954], 2], [3955, 1, "\u0F71\u0F72"], [3956, 2], [3957, 1, "\u0F71\u0F74"], [3958, 1, "\u0FB2\u0F80"], [3959, 1, "\u0FB2\u0F71\u0F80"], [3960, 1, "\u0FB3\u0F80"], [3961, 1, "\u0FB3\u0F71\u0F80"], [[3962, 3968], 2], [3969, 1, "\u0F71\u0F80"], [[3970, 3972], 2], [3973, 2], [[3974, 3979], 2], [[3980, 3983], 2], [[3984, 3986], 2], [3987, 1, "\u0F92\u0FB7"], [[3988, 3989], 2], [3990, 2], [3991, 2], [3992, 3], [[3993, 3996], 2], [3997, 1, "\u0F9C\u0FB7"], [[3998, 4001], 2], [4002, 1, "\u0FA1\u0FB7"], [[4003, 4006], 2], [4007, 1, "\u0FA6\u0FB7"], [[4008, 4011], 2], [4012, 1, "\u0FAB\u0FB7"], [4013, 2], [[4014, 4016], 2], [[4017, 4023], 2], [4024, 2], [4025, 1, "\u0F90\u0FB5"], [[4026, 4028], 2], [4029, 3], [[4030, 4037], 2], [4038, 2], [[4039, 4044], 2], [4045, 3], [4046, 2], [4047, 2], [[4048, 4049], 2], [[4050, 4052], 2], [[4053, 4056], 2], [[4057, 4058], 2], [[4059, 4095], 3], [[4096, 4129], 2], [4130, 2], [[4131, 4135], 2], [4136, 2], [[4137, 4138], 2], [4139, 2], [[4140, 4146], 2], [[4147, 4149], 2], [[4150, 4153], 2], [[4154, 4159], 2], [[4160, 4169], 2], [[4170, 4175], 2], [[4176, 4185], 2], [[4186, 4249], 2], [[4250, 4253], 2], [[4254, 4255], 2], [4256, 1, "\u2D00"], [4257, 1, "\u2D01"], [4258, 1, "\u2D02"], [4259, 1, "\u2D03"], [4260, 1, "\u2D04"], [4261, 1, "\u2D05"], [4262, 1, "\u2D06"], [4263, 1, "\u2D07"], [4264, 1, "\u2D08"], [4265, 1, "\u2D09"], [4266, 1, "\u2D0A"], [4267, 1, "\u2D0B"], [4268, 1, "\u2D0C"], [4269, 1, "\u2D0D"], [4270, 1, "\u2D0E"], [4271, 1, "\u2D0F"], [4272, 1, "\u2D10"], [4273, 1, "\u2D11"], [4274, 1, "\u2D12"], [4275, 1, "\u2D13"], [4276, 1, "\u2D14"], [4277, 1, "\u2D15"], [4278, 1, "\u2D16"], [4279, 1, "\u2D17"], [4280, 1, "\u2D18"], [4281, 1, "\u2D19"], [4282, 1, "\u2D1A"], [4283, 1, "\u2D1B"], [4284, 1, "\u2D1C"], [4285, 1, "\u2D1D"], [4286, 1, "\u2D1E"], [4287, 1, "\u2D1F"], [4288, 1, "\u2D20"], [4289, 1, "\u2D21"], [4290, 1, "\u2D22"], [4291, 1, "\u2D23"], [4292, 1, "\u2D24"], [4293, 1, "\u2D25"], [4294, 3], [4295, 1, "\u2D27"], [[4296, 4300], 3], [4301, 1, "\u2D2D"], [[4302, 4303], 3], [[4304, 4342], 2], [[4343, 4344], 2], [[4345, 4346], 2], [4347, 2], [4348, 1, "\u10DC"], [[4349, 4351], 2], [[4352, 4441], 2], [[4442, 4446], 2], [[4447, 4448], 7], [[4449, 4514], 2], [[4515, 4519], 2], [[4520, 4601], 2], [[4602, 4607], 2], [[4608, 4614], 2], [4615, 2], [[4616, 4678], 2], [4679, 2], [4680, 2], [4681, 3], [[4682, 4685], 2], [[4686, 4687], 3], [[4688, 4694], 2], [4695, 3], [4696, 2], [4697, 3], [[4698, 4701], 2], [[4702, 4703], 3], [[4704, 4742], 2], [4743, 2], [4744, 2], [4745, 3], [[4746, 4749], 2], [[4750, 4751], 3], [[4752, 4782], 2], [4783, 2], [4784, 2], [4785, 3], [[4786, 4789], 2], [[4790, 4791], 3], [[4792, 4798], 2], [4799, 3], [4800, 2], [4801, 3], [[4802, 4805], 2], [[4806, 4807], 3], [[4808, 4814], 2], [4815, 2], [[4816, 4822], 2], [4823, 3], [[4824, 4846], 2], [4847, 2], [[4848, 4878], 2], [4879, 2], [4880, 2], [4881, 3], [[4882, 4885], 2], [[4886, 4887], 3], [[4888, 4894], 2], [4895, 2], [[4896, 4934], 2], [4935, 2], [[4936, 4954], 2], [[4955, 4956], 3], [[4957, 4958], 2], [4959, 2], [4960, 2], [[4961, 4988], 2], [[4989, 4991], 3], [[4992, 5007], 2], [[5008, 5017], 2], [[5018, 5023], 3], [[5024, 5108], 2], [5109, 2], [[5110, 5111], 3], [5112, 1, "\u13F0"], [5113, 1, "\u13F1"], [5114, 1, "\u13F2"], [5115, 1, "\u13F3"], [5116, 1, "\u13F4"], [5117, 1, "\u13F5"], [[5118, 5119], 3], [5120, 2], [[5121, 5740], 2], [[5741, 5742], 2], [[5743, 5750], 2], [[5751, 5759], 2], [5760, 3], [[5761, 5786], 2], [[5787, 5788], 2], [[5789, 5791], 3], [[5792, 5866], 2], [[5867, 5872], 2], [[5873, 5880], 2], [[5881, 5887], 3], [[5888, 5900], 2], [5901, 2], [[5902, 5908], 2], [5909, 2], [[5910, 5918], 3], [5919, 2], [[5920, 5940], 2], [[5941, 5942], 2], [[5943, 5951], 3], [[5952, 5971], 2], [[5972, 5983], 3], [[5984, 5996], 2], [5997, 3], [[5998, 6e3], 2], [6001, 3], [[6002, 6003], 2], [[6004, 6015], 3], [[6016, 6067], 2], [[6068, 6069], 7], [[6070, 6099], 2], [[6100, 6102], 2], [6103, 2], [[6104, 6107], 2], [6108, 2], [6109, 2], [[6110, 6111], 3], [[6112, 6121], 2], [[6122, 6127], 3], [[6128, 6137], 2], [[6138, 6143], 3], [[6144, 6154], 2], [[6155, 6158], 7], [6159, 7], [[6160, 6169], 2], [[6170, 6175], 3], [[6176, 6263], 2], [6264, 2], [[6265, 6271], 3], [[6272, 6313], 2], [6314, 2], [[6315, 6319], 3], [[6320, 6389], 2], [[6390, 6399], 3], [[6400, 6428], 2], [[6429, 6430], 2], [6431, 3], [[6432, 6443], 2], [[6444, 6447], 3], [[6448, 6459], 2], [[6460, 6463], 3], [6464, 2], [[6465, 6467], 3], [[6468, 6469], 2], [[6470, 6509], 2], [[6510, 6511], 3], [[6512, 6516], 2], [[6517, 6527], 3], [[6528, 6569], 2], [[6570, 6571], 2], [[6572, 6575], 3], [[6576, 6601], 2], [[6602, 6607], 3], [[6608, 6617], 2], [6618, 2], [[6619, 6621], 3], [[6622, 6623], 2], [[6624, 6655], 2], [[6656, 6683], 2], [[6684, 6685], 3], [[6686, 6687], 2], [[6688, 6750], 2], [6751, 3], [[6752, 6780], 2], [[6781, 6782], 3], [[6783, 6793], 2], [[6794, 6799], 3], [[6800, 6809], 2], [[6810, 6815], 3], [[6816, 6822], 2], [6823, 2], [[6824, 6829], 2], [[6830, 6831], 3], [[6832, 6845], 2], [6846, 2], [[6847, 6848], 2], [[6849, 6862], 2], [[6863, 6911], 3], [[6912, 6987], 2], [6988, 2], [6989, 3], [[6990, 6991], 2], [[6992, 7001], 2], [[7002, 7018], 2], [[7019, 7027], 2], [[7028, 7036], 2], [[7037, 7038], 2], [7039, 2], [[7040, 7082], 2], [[7083, 7085], 2], [[7086, 7097], 2], [[7098, 7103], 2], [[7104, 7155], 2], [[7156, 7163], 3], [[7164, 7167], 2], [[7168, 7223], 2], [[7224, 7226], 3], [[7227, 7231], 2], [[7232, 7241], 2], [[7242, 7244], 3], [[7245, 7293], 2], [[7294, 7295], 2], [7296, 1, "\u0432"], [7297, 1, "\u0434"], [7298, 1, "\u043E"], [7299, 1, "\u0441"], [[7300, 7301], 1, "\u0442"], [7302, 1, "\u044A"], [7303, 1, "\u0463"], [7304, 1, "\uA64B"], [7305, 1, "\u1C8A"], [7306, 2], [[7307, 7311], 3], [7312, 1, "\u10D0"], [7313, 1, "\u10D1"], [7314, 1, "\u10D2"], [7315, 1, "\u10D3"], [7316, 1, "\u10D4"], [7317, 1, "\u10D5"], [7318, 1, "\u10D6"], [7319, 1, "\u10D7"], [7320, 1, "\u10D8"], [7321, 1, "\u10D9"], [7322, 1, "\u10DA"], [7323, 1, "\u10DB"], [7324, 1, "\u10DC"], [7325, 1, "\u10DD"], [7326, 1, "\u10DE"], [7327, 1, "\u10DF"], [7328, 1, "\u10E0"], [7329, 1, "\u10E1"], [7330, 1, "\u10E2"], [7331, 1, "\u10E3"], [7332, 1, "\u10E4"], [7333, 1, "\u10E5"], [7334, 1, "\u10E6"], [7335, 1, "\u10E7"], [7336, 1, "\u10E8"], [7337, 1, "\u10E9"], [7338, 1, "\u10EA"], [7339, 1, "\u10EB"], [7340, 1, "\u10EC"], [7341, 1, "\u10ED"], [7342, 1, "\u10EE"], [7343, 1, "\u10EF"], [7344, 1, "\u10F0"], [7345, 1, "\u10F1"], [7346, 1, "\u10F2"], [7347, 1, "\u10F3"], [7348, 1, "\u10F4"], [7349, 1, "\u10F5"], [7350, 1, "\u10F6"], [7351, 1, "\u10F7"], [7352, 1, "\u10F8"], [7353, 1, "\u10F9"], [7354, 1, "\u10FA"], [[7355, 7356], 3], [7357, 1, "\u10FD"], [7358, 1, "\u10FE"], [7359, 1, "\u10FF"], [[7360, 7367], 2], [[7368, 7375], 3], [[7376, 7378], 2], [7379, 2], [[7380, 7410], 2], [[7411, 7414], 2], [7415, 2], [[7416, 7417], 2], [7418, 2], [[7419, 7423], 3], [[7424, 7467], 2], [7468, 1, "a"], [7469, 1, "\xE6"], [7470, 1, "b"], [7471, 2], [7472, 1, "d"], [7473, 1, "e"], [7474, 1, "\u01DD"], [7475, 1, "g"], [7476, 1, "h"], [7477, 1, "i"], [7478, 1, "j"], [7479, 1, "k"], [7480, 1, "l"], [7481, 1, "m"], [7482, 1, "n"], [7483, 2], [7484, 1, "o"], [7485, 1, "\u0223"], [7486, 1, "p"], [7487, 1, "r"], [7488, 1, "t"], [7489, 1, "u"], [7490, 1, "w"], [7491, 1, "a"], [7492, 1, "\u0250"], [7493, 1, "\u0251"], [7494, 1, "\u1D02"], [7495, 1, "b"], [7496, 1, "d"], [7497, 1, "e"], [7498, 1, "\u0259"], [7499, 1, "\u025B"], [7500, 1, "\u025C"], [7501, 1, "g"], [7502, 2], [7503, 1, "k"], [7504, 1, "m"], [7505, 1, "\u014B"], [7506, 1, "o"], [7507, 1, "\u0254"], [7508, 1, "\u1D16"], [7509, 1, "\u1D17"], [7510, 1, "p"], [7511, 1, "t"], [7512, 1, "u"], [7513, 1, "\u1D1D"], [7514, 1, "\u026F"], [7515, 1, "v"], [7516, 1, "\u1D25"], [7517, 1, "\u03B2"], [7518, 1, "\u03B3"], [7519, 1, "\u03B4"], [7520, 1, "\u03C6"], [7521, 1, "\u03C7"], [7522, 1, "i"], [7523, 1, "r"], [7524, 1, "u"], [7525, 1, "v"], [7526, 1, "\u03B2"], [7527, 1, "\u03B3"], [7528, 1, "\u03C1"], [7529, 1, "\u03C6"], [7530, 1, "\u03C7"], [7531, 2], [[7532, 7543], 2], [7544, 1, "\u043D"], [[7545, 7578], 2], [7579, 1, "\u0252"], [7580, 1, "c"], [7581, 1, "\u0255"], [7582, 1, "\xF0"], [7583, 1, "\u025C"], [7584, 1, "f"], [7585, 1, "\u025F"], [7586, 1, "\u0261"], [7587, 1, "\u0265"], [7588, 1, "\u0268"], [7589, 1, "\u0269"], [7590, 1, "\u026A"], [7591, 1, "\u1D7B"], [7592, 1, "\u029D"], [7593, 1, "\u026D"], [7594, 1, "\u1D85"], [7595, 1, "\u029F"], [7596, 1, "\u0271"], [7597, 1, "\u0270"], [7598, 1, "\u0272"], [7599, 1, "\u0273"], [7600, 1, "\u0274"], [7601, 1, "\u0275"], [7602, 1, "\u0278"], [7603, 1, "\u0282"], [7604, 1, "\u0283"], [7605, 1, "\u01AB"], [7606, 1, "\u0289"], [7607, 1, "\u028A"], [7608, 1, "\u1D1C"], [7609, 1, "\u028B"], [7610, 1, "\u028C"], [7611, 1, "z"], [7612, 1, "\u0290"], [7613, 1, "\u0291"], [7614, 1, "\u0292"], [7615, 1, "\u03B8"], [[7616, 7619], 2], [[7620, 7626], 2], [[7627, 7654], 2], [[7655, 7669], 2], [[7670, 7673], 2], [7674, 2], [7675, 2], [7676, 2], [7677, 2], [[7678, 7679], 2], [7680, 1, "\u1E01"], [7681, 2], [7682, 1, "\u1E03"], [7683, 2], [7684, 1, "\u1E05"], [7685, 2], [7686, 1, "\u1E07"], [7687, 2], [7688, 1, "\u1E09"], [7689, 2], [7690, 1, "\u1E0B"], [7691, 2], [7692, 1, "\u1E0D"], [7693, 2], [7694, 1, "\u1E0F"], [7695, 2], [7696, 1, "\u1E11"], [7697, 2], [7698, 1, "\u1E13"], [7699, 2], [7700, 1, "\u1E15"], [7701, 2], [7702, 1, "\u1E17"], [7703, 2], [7704, 1, "\u1E19"], [7705, 2], [7706, 1, "\u1E1B"], [7707, 2], [7708, 1, "\u1E1D"], [7709, 2], [7710, 1, "\u1E1F"], [7711, 2], [7712, 1, "\u1E21"], [7713, 2], [7714, 1, "\u1E23"], [7715, 2], [7716, 1, "\u1E25"], [7717, 2], [7718, 1, "\u1E27"], [7719, 2], [7720, 1, "\u1E29"], [7721, 2], [7722, 1, "\u1E2B"], [7723, 2], [7724, 1, "\u1E2D"], [7725, 2], [7726, 1, "\u1E2F"], [7727, 2], [7728, 1, "\u1E31"], [7729, 2], [7730, 1, "\u1E33"], [7731, 2], [7732, 1, "\u1E35"], [7733, 2], [7734, 1, "\u1E37"], [7735, 2], [7736, 1, "\u1E39"], [7737, 2], [7738, 1, "\u1E3B"], [7739, 2], [7740, 1, "\u1E3D"], [7741, 2], [7742, 1, "\u1E3F"], [7743, 2], [7744, 1, "\u1E41"], [7745, 2], [7746, 1, "\u1E43"], [7747, 2], [7748, 1, "\u1E45"], [7749, 2], [7750, 1, "\u1E47"], [7751, 2], [7752, 1, "\u1E49"], [7753, 2], [7754, 1, "\u1E4B"], [7755, 2], [7756, 1, "\u1E4D"], [7757, 2], [7758, 1, "\u1E4F"], [7759, 2], [7760, 1, "\u1E51"], [7761, 2], [7762, 1, "\u1E53"], [7763, 2], [7764, 1, "\u1E55"], [7765, 2], [7766, 1, "\u1E57"], [7767, 2], [7768, 1, "\u1E59"], [7769, 2], [7770, 1, "\u1E5B"], [7771, 2], [7772, 1, "\u1E5D"], [7773, 2], [7774, 1, "\u1E5F"], [7775, 2], [7776, 1, "\u1E61"], [7777, 2], [7778, 1, "\u1E63"], [7779, 2], [7780, 1, "\u1E65"], [7781, 2], [7782, 1, "\u1E67"], [7783, 2], [7784, 1, "\u1E69"], [7785, 2], [7786, 1, "\u1E6B"], [7787, 2], [7788, 1, "\u1E6D"], [7789, 2], [7790, 1, "\u1E6F"], [7791, 2], [7792, 1, "\u1E71"], [7793, 2], [7794, 1, "\u1E73"], [7795, 2], [7796, 1, "\u1E75"], [7797, 2], [7798, 1, "\u1E77"], [7799, 2], [7800, 1, "\u1E79"], [7801, 2], [7802, 1, "\u1E7B"], [7803, 2], [7804, 1, "\u1E7D"], [7805, 2], [7806, 1, "\u1E7F"], [7807, 2], [7808, 1, "\u1E81"], [7809, 2], [7810, 1, "\u1E83"], [7811, 2], [7812, 1, "\u1E85"], [7813, 2], [7814, 1, "\u1E87"], [7815, 2], [7816, 1, "\u1E89"], [7817, 2], [7818, 1, "\u1E8B"], [7819, 2], [7820, 1, "\u1E8D"], [7821, 2], [7822, 1, "\u1E8F"], [7823, 2], [7824, 1, "\u1E91"], [7825, 2], [7826, 1, "\u1E93"], [7827, 2], [7828, 1, "\u1E95"], [[7829, 7833], 2], [7834, 1, "a\u02BE"], [7835, 1, "\u1E61"], [[7836, 7837], 2], [7838, 1, "\xDF"], [7839, 2], [7840, 1, "\u1EA1"], [7841, 2], [7842, 1, "\u1EA3"], [7843, 2], [7844, 1, "\u1EA5"], [7845, 2], [7846, 1, "\u1EA7"], [7847, 2], [7848, 1, "\u1EA9"], [7849, 2], [7850, 1, "\u1EAB"], [7851, 2], [7852, 1, "\u1EAD"], [7853, 2], [7854, 1, "\u1EAF"], [7855, 2], [7856, 1, "\u1EB1"], [7857, 2], [7858, 1, "\u1EB3"], [7859, 2], [7860, 1, "\u1EB5"], [7861, 2], [7862, 1, "\u1EB7"], [7863, 2], [7864, 1, "\u1EB9"], [7865, 2], [7866, 1, "\u1EBB"], [7867, 2], [7868, 1, "\u1EBD"], [7869, 2], [7870, 1, "\u1EBF"], [7871, 2], [7872, 1, "\u1EC1"], [7873, 2], [7874, 1, "\u1EC3"], [7875, 2], [7876, 1, "\u1EC5"], [7877, 2], [7878, 1, "\u1EC7"], [7879, 2], [7880, 1, "\u1EC9"], [7881, 2], [7882, 1, "\u1ECB"], [7883, 2], [7884, 1, "\u1ECD"], [7885, 2], [7886, 1, "\u1ECF"], [7887, 2], [7888, 1, "\u1ED1"], [7889, 2], [7890, 1, "\u1ED3"], [7891, 2], [7892, 1, "\u1ED5"], [7893, 2], [7894, 1, "\u1ED7"], [7895, 2], [7896, 1, "\u1ED9"], [7897, 2], [7898, 1, "\u1EDB"], [7899, 2], [7900, 1, "\u1EDD"], [7901, 2], [7902, 1, "\u1EDF"], [7903, 2], [7904, 1, "\u1EE1"], [7905, 2], [7906, 1, "\u1EE3"], [7907, 2], [7908, 1, "\u1EE5"], [7909, 2], [7910, 1, "\u1EE7"], [7911, 2], [7912, 1, "\u1EE9"], [7913, 2], [7914, 1, "\u1EEB"], [7915, 2], [7916, 1, "\u1EED"], [7917, 2], [7918, 1, "\u1EEF"], [7919, 2], [7920, 1, "\u1EF1"], [7921, 2], [7922, 1, "\u1EF3"], [7923, 2], [7924, 1, "\u1EF5"], [7925, 2], [7926, 1, "\u1EF7"], [7927, 2], [7928, 1, "\u1EF9"], [7929, 2], [7930, 1, "\u1EFB"], [7931, 2], [7932, 1, "\u1EFD"], [7933, 2], [7934, 1, "\u1EFF"], [7935, 2], [[7936, 7943], 2], [7944, 1, "\u1F00"], [7945, 1, "\u1F01"], [7946, 1, "\u1F02"], [7947, 1, "\u1F03"], [7948, 1, "\u1F04"], [7949, 1, "\u1F05"], [7950, 1, "\u1F06"], [7951, 1, "\u1F07"], [[7952, 7957], 2], [[7958, 7959], 3], [7960, 1, "\u1F10"], [7961, 1, "\u1F11"], [7962, 1, "\u1F12"], [7963, 1, "\u1F13"], [7964, 1, "\u1F14"], [7965, 1, "\u1F15"], [[7966, 7967], 3], [[7968, 7975], 2], [7976, 1, "\u1F20"], [7977, 1, "\u1F21"], [7978, 1, "\u1F22"], [7979, 1, "\u1F23"], [7980, 1, "\u1F24"], [7981, 1, "\u1F25"], [7982, 1, "\u1F26"], [7983, 1, "\u1F27"], [[7984, 7991], 2], [7992, 1, "\u1F30"], [7993, 1, "\u1F31"], [7994, 1, "\u1F32"], [7995, 1, "\u1F33"], [7996, 1, "\u1F34"], [7997, 1, "\u1F35"], [7998, 1, "\u1F36"], [7999, 1, "\u1F37"], [[8e3, 8005], 2], [[8006, 8007], 3], [8008, 1, "\u1F40"], [8009, 1, "\u1F41"], [8010, 1, "\u1F42"], [8011, 1, "\u1F43"], [8012, 1, "\u1F44"], [8013, 1, "\u1F45"], [[8014, 8015], 3], [[8016, 8023], 2], [8024, 3], [8025, 1, "\u1F51"], [8026, 3], [8027, 1, "\u1F53"], [8028, 3], [8029, 1, "\u1F55"], [8030, 3], [8031, 1, "\u1F57"], [[8032, 8039], 2], [8040, 1, "\u1F60"], [8041, 1, "\u1F61"], [8042, 1, "\u1F62"], [8043, 1, "\u1F63"], [8044, 1, "\u1F64"], [8045, 1, "\u1F65"], [8046, 1, "\u1F66"], [8047, 1, "\u1F67"], [8048, 2], [8049, 1, "\u03AC"], [8050, 2], [8051, 1, "\u03AD"], [8052, 2], [8053, 1, "\u03AE"], [8054, 2], [8055, 1, "\u03AF"], [8056, 2], [8057, 1, "\u03CC"], [8058, 2], [8059, 1, "\u03CD"], [8060, 2], [8061, 1, "\u03CE"], [[8062, 8063], 3], [8064, 1, "\u1F00\u03B9"], [8065, 1, "\u1F01\u03B9"], [8066, 1, "\u1F02\u03B9"], [8067, 1, "\u1F03\u03B9"], [8068, 1, "\u1F04\u03B9"], [8069, 1, "\u1F05\u03B9"], [8070, 1, "\u1F06\u03B9"], [8071, 1, "\u1F07\u03B9"], [8072, 1, "\u1F00\u03B9"], [8073, 1, "\u1F01\u03B9"], [8074, 1, "\u1F02\u03B9"], [8075, 1, "\u1F03\u03B9"], [8076, 1, "\u1F04\u03B9"], [8077, 1, "\u1F05\u03B9"], [8078, 1, "\u1F06\u03B9"], [8079, 1, "\u1F07\u03B9"], [8080, 1, "\u1F20\u03B9"], [8081, 1, "\u1F21\u03B9"], [8082, 1, "\u1F22\u03B9"], [8083, 1, "\u1F23\u03B9"], [8084, 1, "\u1F24\u03B9"], [8085, 1, "\u1F25\u03B9"], [8086, 1, "\u1F26\u03B9"], [8087, 1, "\u1F27\u03B9"], [8088, 1, "\u1F20\u03B9"], [8089, 1, "\u1F21\u03B9"], [8090, 1, "\u1F22\u03B9"], [8091, 1, "\u1F23\u03B9"], [8092, 1, "\u1F24\u03B9"], [8093, 1, "\u1F25\u03B9"], [8094, 1, "\u1F26\u03B9"], [8095, 1, "\u1F27\u03B9"], [8096, 1, "\u1F60\u03B9"], [8097, 1, "\u1F61\u03B9"], [8098, 1, "\u1F62\u03B9"], [8099, 1, "\u1F63\u03B9"], [8100, 1, "\u1F64\u03B9"], [8101, 1, "\u1F65\u03B9"], [8102, 1, "\u1F66\u03B9"], [8103, 1, "\u1F67\u03B9"], [8104, 1, "\u1F60\u03B9"], [8105, 1, "\u1F61\u03B9"], [8106, 1, "\u1F62\u03B9"], [8107, 1, "\u1F63\u03B9"], [8108, 1, "\u1F64\u03B9"], [8109, 1, "\u1F65\u03B9"], [8110, 1, "\u1F66\u03B9"], [8111, 1, "\u1F67\u03B9"], [[8112, 8113], 2], [8114, 1, "\u1F70\u03B9"], [8115, 1, "\u03B1\u03B9"], [8116, 1, "\u03AC\u03B9"], [8117, 3], [8118, 2], [8119, 1, "\u1FB6\u03B9"], [8120, 1, "\u1FB0"], [8121, 1, "\u1FB1"], [8122, 1, "\u1F70"], [8123, 1, "\u03AC"], [8124, 1, "\u03B1\u03B9"], [8125, 1, " \u0313"], [8126, 1, "\u03B9"], [8127, 1, " \u0313"], [8128, 1, " \u0342"], [8129, 1, " \u0308\u0342"], [8130, 1, "\u1F74\u03B9"], [8131, 1, "\u03B7\u03B9"], [8132, 1, "\u03AE\u03B9"], [8133, 3], [8134, 2], [8135, 1, "\u1FC6\u03B9"], [8136, 1, "\u1F72"], [8137, 1, "\u03AD"], [8138, 1, "\u1F74"], [8139, 1, "\u03AE"], [8140, 1, "\u03B7\u03B9"], [8141, 1, " \u0313\u0300"], [8142, 1, " \u0313\u0301"], [8143, 1, " \u0313\u0342"], [[8144, 8146], 2], [8147, 1, "\u0390"], [[8148, 8149], 3], [[8150, 8151], 2], [8152, 1, "\u1FD0"], [8153, 1, "\u1FD1"], [8154, 1, "\u1F76"], [8155, 1, "\u03AF"], [8156, 3], [8157, 1, " \u0314\u0300"], [8158, 1, " \u0314\u0301"], [8159, 1, " \u0314\u0342"], [[8160, 8162], 2], [8163, 1, "\u03B0"], [[8164, 8167], 2], [8168, 1, "\u1FE0"], [8169, 1, "\u1FE1"], [8170, 1, "\u1F7A"], [8171, 1, "\u03CD"], [8172, 1, "\u1FE5"], [8173, 1, " \u0308\u0300"], [8174, 1, " \u0308\u0301"], [8175, 1, "`"], [[8176, 8177], 3], [8178, 1, "\u1F7C\u03B9"], [8179, 1, "\u03C9\u03B9"], [8180, 1, "\u03CE\u03B9"], [8181, 3], [8182, 2], [8183, 1, "\u1FF6\u03B9"], [8184, 1, "\u1F78"], [8185, 1, "\u03CC"], [8186, 1, "\u1F7C"], [8187, 1, "\u03CE"], [8188, 1, "\u03C9\u03B9"], [8189, 1, " \u0301"], [8190, 1, " \u0314"], [8191, 3], [[8192, 8202], 1, " "], [8203, 7], [[8204, 8205], 6, ""], [[8206, 8207], 3], [8208, 2], [8209, 1, "\u2010"], [[8210, 8214], 2], [8215, 1, " \u0333"], [[8216, 8227], 2], [[8228, 8230], 3], [8231, 2], [[8232, 8238], 3], [8239, 1, " "], [[8240, 8242], 2], [8243, 1, "\u2032\u2032"], [8244, 1, "\u2032\u2032\u2032"], [8245, 2], [8246, 1, "\u2035\u2035"], [8247, 1, "\u2035\u2035\u2035"], [[8248, 8251], 2], [8252, 1, "!!"], [8253, 2], [8254, 1, " \u0305"], [[8255, 8262], 2], [8263, 1, "??"], [8264, 1, "?!"], [8265, 1, "!?"], [[8266, 8269], 2], [[8270, 8274], 2], [[8275, 8276], 2], [[8277, 8278], 2], [8279, 1, "\u2032\u2032\u2032\u2032"], [[8280, 8286], 2], [8287, 1, " "], [[8288, 8291], 7], [8292, 7], [8293, 3], [[8294, 8297], 3], [[8298, 8303], 7], [8304, 1, "0"], [8305, 1, "i"], [[8306, 8307], 3], [8308, 1, "4"], [8309, 1, "5"], [8310, 1, "6"], [8311, 1, "7"], [8312, 1, "8"], [8313, 1, "9"], [8314, 1, "+"], [8315, 1, "\u2212"], [8316, 1, "="], [8317, 1, "("], [8318, 1, ")"], [8319, 1, "n"], [8320, 1, "0"], [8321, 1, "1"], [8322, 1, "2"], [8323, 1, "3"], [8324, 1, "4"], [8325, 1, "5"], [8326, 1, "6"], [8327, 1, "7"], [8328, 1, "8"], [8329, 1, "9"], [8330, 1, "+"], [8331, 1, "\u2212"], [8332, 1, "="], [8333, 1, "("], [8334, 1, ")"], [8335, 3], [8336, 1, "a"], [8337, 1, "e"], [8338, 1, "o"], [8339, 1, "x"], [8340, 1, "\u0259"], [8341, 1, "h"], [8342, 1, "k"], [8343, 1, "l"], [8344, 1, "m"], [8345, 1, "n"], [8346, 1, "p"], [8347, 1, "s"], [8348, 1, "t"], [[8349, 8351], 3], [[8352, 8359], 2], [8360, 1, "rs"], [[8361, 8362], 2], [8363, 2], [8364, 2], [[8365, 8367], 2], [[8368, 8369], 2], [[8370, 8373], 2], [[8374, 8376], 2], [8377, 2], [8378, 2], [[8379, 8381], 2], [8382, 2], [8383, 2], [8384, 2], [[8385, 8399], 3], [[8400, 8417], 2], [[8418, 8419], 2], [[8420, 8426], 2], [8427, 2], [[8428, 8431], 2], [8432, 2], [[8433, 8447], 3], [8448, 1, "a/c"], [8449, 1, "a/s"], [8450, 1, "c"], [8451, 1, "\xB0c"], [8452, 2], [8453, 1, "c/o"], [8454, 1, "c/u"], [8455, 1, "\u025B"], [8456, 2], [8457, 1, "\xB0f"], [8458, 1, "g"], [[8459, 8462], 1, "h"], [8463, 1, "\u0127"], [[8464, 8465], 1, "i"], [[8466, 8467], 1, "l"], [8468, 2], [8469, 1, "n"], [8470, 1, "no"], [[8471, 8472], 2], [8473, 1, "p"], [8474, 1, "q"], [[8475, 8477], 1, "r"], [[8478, 8479], 2], [8480, 1, "sm"], [8481, 1, "tel"], [8482, 1, "tm"], [8483, 2], [8484, 1, "z"], [8485, 2], [8486, 1, "\u03C9"], [8487, 2], [8488, 1, "z"], [8489, 2], [8490, 1, "k"], [8491, 1, "\xE5"], [8492, 1, "b"], [8493, 1, "c"], [8494, 2], [[8495, 8496], 1, "e"], [8497, 1, "f"], [8498, 1, "\u214E"], [8499, 1, "m"], [8500, 1, "o"], [8501, 1, "\u05D0"], [8502, 1, "\u05D1"], [8503, 1, "\u05D2"], [8504, 1, "\u05D3"], [8505, 1, "i"], [8506, 2], [8507, 1, "fax"], [8508, 1, "\u03C0"], [[8509, 8510], 1, "\u03B3"], [8511, 1, "\u03C0"], [8512, 1, "\u2211"], [[8513, 8516], 2], [[8517, 8518], 1, "d"], [8519, 1, "e"], [8520, 1, "i"], [8521, 1, "j"], [[8522, 8523], 2], [8524, 2], [8525, 2], [8526, 2], [8527, 2], [8528, 1, "1\u20447"], [8529, 1, "1\u20449"], [8530, 1, "1\u204410"], [8531, 1, "1\u20443"], [8532, 1, "2\u20443"], [8533, 1, "1\u20445"], [8534, 1, "2\u20445"], [8535, 1, "3\u20445"], [8536, 1, "4\u20445"], [8537, 1, "1\u20446"], [8538, 1, "5\u20446"], [8539, 1, "1\u20448"], [8540, 1, "3\u20448"], [8541, 1, "5\u20448"], [8542, 1, "7\u20448"], [8543, 1, "1\u2044"], [8544, 1, "i"], [8545, 1, "ii"], [8546, 1, "iii"], [8547, 1, "iv"], [8548, 1, "v"], [8549, 1, "vi"], [8550, 1, "vii"], [8551, 1, "viii"], [8552, 1, "ix"], [8553, 1, "x"], [8554, 1, "xi"], [8555, 1, "xii"], [8556, 1, "l"], [8557, 1, "c"], [8558, 1, "d"], [8559, 1, "m"], [8560, 1, "i"], [8561, 1, "ii"], [8562, 1, "iii"], [8563, 1, "iv"], [8564, 1, "v"], [8565, 1, "vi"], [8566, 1, "vii"], [8567, 1, "viii"], [8568, 1, "ix"], [8569, 1, "x"], [8570, 1, "xi"], [8571, 1, "xii"], [8572, 1, "l"], [8573, 1, "c"], [8574, 1, "d"], [8575, 1, "m"], [[8576, 8578], 2], [8579, 1, "\u2184"], [8580, 2], [[8581, 8584], 2], [8585, 1, "0\u20443"], [[8586, 8587], 2], [[8588, 8591], 3], [[8592, 8682], 2], [[8683, 8691], 2], [[8692, 8703], 2], [[8704, 8747], 2], [8748, 1, "\u222B\u222B"], [8749, 1, "\u222B\u222B\u222B"], [8750, 2], [8751, 1, "\u222E\u222E"], [8752, 1, "\u222E\u222E\u222E"], [[8753, 8945], 2], [[8946, 8959], 2], [8960, 2], [8961, 2], [[8962, 9e3], 2], [9001, 1, "\u3008"], [9002, 1, "\u3009"], [[9003, 9082], 2], [9083, 2], [9084, 2], [[9085, 9114], 2], [[9115, 9166], 2], [[9167, 9168], 2], [[9169, 9179], 2], [[9180, 9191], 2], [9192, 2], [[9193, 9203], 2], [[9204, 9210], 2], [[9211, 9214], 2], [9215, 2], [[9216, 9252], 2], [[9253, 9254], 2], [[9255, 9257], 2], [[9258, 9279], 3], [[9280, 9290], 2], [[9291, 9311], 3], [9312, 1, "1"], [9313, 1, "2"], [9314, 1, "3"], [9315, 1, "4"], [9316, 1, "5"], [9317, 1, "6"], [9318, 1, "7"], [9319, 1, "8"], [9320, 1, "9"], [9321, 1, "10"], [9322, 1, "11"], [9323, 1, "12"], [9324, 1, "13"], [9325, 1, "14"], [9326, 1, "15"], [9327, 1, "16"], [9328, 1, "17"], [9329, 1, "18"], [9330, 1, "19"], [9331, 1, "20"], [9332, 1, "(1)"], [9333, 1, "(2)"], [9334, 1, "(3)"], [9335, 1, "(4)"], [9336, 1, "(5)"], [9337, 1, "(6)"], [9338, 1, "(7)"], [9339, 1, "(8)"], [9340, 1, "(9)"], [9341, 1, "(10)"], [9342, 1, "(11)"], [9343, 1, "(12)"], [9344, 1, "(13)"], [9345, 1, "(14)"], [9346, 1, "(15)"], [9347, 1, "(16)"], [9348, 1, "(17)"], [9349, 1, "(18)"], [9350, 1, "(19)"], [9351, 1, "(20)"], [[9352, 9371], 3], [9372, 1, "(a)"], [9373, 1, "(b)"], [9374, 1, "(c)"], [9375, 1, "(d)"], [9376, 1, "(e)"], [9377, 1, "(f)"], [9378, 1, "(g)"], [9379, 1, "(h)"], [9380, 1, "(i)"], [9381, 1, "(j)"], [9382, 1, "(k)"], [9383, 1, "(l)"], [9384, 1, "(m)"], [9385, 1, "(n)"], [9386, 1, "(o)"], [9387, 1, "(p)"], [9388, 1, "(q)"], [9389, 1, "(r)"], [9390, 1, "(s)"], [9391, 1, "(t)"], [9392, 1, "(u)"], [9393, 1, "(v)"], [9394, 1, "(w)"], [9395, 1, "(x)"], [9396, 1, "(y)"], [9397, 1, "(z)"], [9398, 1, "a"], [9399, 1, "b"], [9400, 1, "c"], [9401, 1, "d"], [9402, 1, "e"], [9403, 1, "f"], [9404, 1, "g"], [9405, 1, "h"], [9406, 1, "i"], [9407, 1, "j"], [9408, 1, "k"], [9409, 1, "l"], [9410, 1, "m"], [9411, 1, "n"], [9412, 1, "o"], [9413, 1, "p"], [9414, 1, "q"], [9415, 1, "r"], [9416, 1, "s"], [9417, 1, "t"], [9418, 1, "u"], [9419, 1, "v"], [9420, 1, "w"], [9421, 1, "x"], [9422, 1, "y"], [9423, 1, "z"], [9424, 1, "a"], [9425, 1, "b"], [9426, 1, "c"], [9427, 1, "d"], [9428, 1, "e"], [9429, 1, "f"], [9430, 1, "g"], [9431, 1, "h"], [9432, 1, "i"], [9433, 1, "j"], [9434, 1, "k"], [9435, 1, "l"], [9436, 1, "m"], [9437, 1, "n"], [9438, 1, "o"], [9439, 1, "p"], [9440, 1, "q"], [9441, 1, "r"], [9442, 1, "s"], [9443, 1, "t"], [9444, 1, "u"], [9445, 1, "v"], [9446, 1, "w"], [9447, 1, "x"], [9448, 1, "y"], [9449, 1, "z"], [9450, 1, "0"], [[9451, 9470], 2], [9471, 2], [[9472, 9621], 2], [[9622, 9631], 2], [[9632, 9711], 2], [[9712, 9719], 2], [[9720, 9727], 2], [[9728, 9747], 2], [[9748, 9749], 2], [[9750, 9751], 2], [9752, 2], [9753, 2], [[9754, 9839], 2], [[9840, 9841], 2], [[9842, 9853], 2], [[9854, 9855], 2], [[9856, 9865], 2], [[9866, 9873], 2], [[9874, 9884], 2], [9885, 2], [[9886, 9887], 2], [[9888, 9889], 2], [[9890, 9905], 2], [9906, 2], [[9907, 9916], 2], [[9917, 9919], 2], [[9920, 9923], 2], [[9924, 9933], 2], [9934, 2], [[9935, 9953], 2], [9954, 2], [9955, 2], [[9956, 9959], 2], [[9960, 9983], 2], [9984, 2], [[9985, 9988], 2], [9989, 2], [[9990, 9993], 2], [[9994, 9995], 2], [[9996, 10023], 2], [10024, 2], [[10025, 10059], 2], [10060, 2], [10061, 2], [10062, 2], [[10063, 10066], 2], [[10067, 10069], 2], [10070, 2], [10071, 2], [[10072, 10078], 2], [[10079, 10080], 2], [[10081, 10087], 2], [[10088, 10101], 2], [[10102, 10132], 2], [[10133, 10135], 2], [[10136, 10159], 2], [10160, 2], [[10161, 10174], 2], [10175, 2], [[10176, 10182], 2], [[10183, 10186], 2], [10187, 2], [10188, 2], [10189, 2], [[10190, 10191], 2], [[10192, 10219], 2], [[10220, 10223], 2], [[10224, 10239], 2], [[10240, 10495], 2], [[10496, 10763], 2], [10764, 1, "\u222B\u222B\u222B\u222B"], [[10765, 10867], 2], [10868, 1, "::="], [10869, 1, "=="], [10870, 1, "==="], [[10871, 10971], 2], [10972, 1, "\u2ADD\u0338"], [[10973, 11007], 2], [[11008, 11021], 2], [[11022, 11027], 2], [[11028, 11034], 2], [[11035, 11039], 2], [[11040, 11043], 2], [[11044, 11084], 2], [[11085, 11087], 2], [[11088, 11092], 2], [[11093, 11097], 2], [[11098, 11123], 2], [[11124, 11125], 3], [[11126, 11157], 2], [11158, 3], [11159, 2], [[11160, 11193], 2], [[11194, 11196], 2], [[11197, 11208], 2], [11209, 2], [[11210, 11217], 2], [11218, 2], [[11219, 11243], 2], [[11244, 11247], 2], [[11248, 11262], 2], [11263, 2], [11264, 1, "\u2C30"], [11265, 1, "\u2C31"], [11266, 1, "\u2C32"], [11267, 1, "\u2C33"], [11268, 1, "\u2C34"], [11269, 1, "\u2C35"], [11270, 1, "\u2C36"], [11271, 1, "\u2C37"], [11272, 1, "\u2C38"], [11273, 1, "\u2C39"], [11274, 1, "\u2C3A"], [11275, 1, "\u2C3B"], [11276, 1, "\u2C3C"], [11277, 1, "\u2C3D"], [11278, 1, "\u2C3E"], [11279, 1, "\u2C3F"], [11280, 1, "\u2C40"], [11281, 1, "\u2C41"], [11282, 1, "\u2C42"], [11283, 1, "\u2C43"], [11284, 1, "\u2C44"], [11285, 1, "\u2C45"], [11286, 1, "\u2C46"], [11287, 1, "\u2C47"], [11288, 1, "\u2C48"], [11289, 1, "\u2C49"], [11290, 1, "\u2C4A"], [11291, 1, "\u2C4B"], [11292, 1, "\u2C4C"], [11293, 1, "\u2C4D"], [11294, 1, "\u2C4E"], [11295, 1, "\u2C4F"], [11296, 1, "\u2C50"], [11297, 1, "\u2C51"], [11298, 1, "\u2C52"], [11299, 1, "\u2C53"], [11300, 1, "\u2C54"], [11301, 1, "\u2C55"], [11302, 1, "\u2C56"], [11303, 1, "\u2C57"], [11304, 1, "\u2C58"], [11305, 1, "\u2C59"], [11306, 1, "\u2C5A"], [11307, 1, "\u2C5B"], [11308, 1, "\u2C5C"], [11309, 1, "\u2C5D"], [11310, 1, "\u2C5E"], [11311, 1, "\u2C5F"], [[11312, 11358], 2], [11359, 2], [11360, 1, "\u2C61"], [11361, 2], [11362, 1, "\u026B"], [11363, 1, "\u1D7D"], [11364, 1, "\u027D"], [[11365, 11366], 2], [11367, 1, "\u2C68"], [11368, 2], [11369, 1, "\u2C6A"], [11370, 2], [11371, 1, "\u2C6C"], [11372, 2], [11373, 1, "\u0251"], [11374, 1, "\u0271"], [11375, 1, "\u0250"], [11376, 1, "\u0252"], [11377, 2], [11378, 1, "\u2C73"], [11379, 2], [11380, 2], [11381, 1, "\u2C76"], [[11382, 11383], 2], [[11384, 11387], 2], [11388, 1, "j"], [11389, 1, "v"], [11390, 1, "\u023F"], [11391, 1, "\u0240"], [11392, 1, "\u2C81"], [11393, 2], [11394, 1, "\u2C83"], [11395, 2], [11396, 1, "\u2C85"], [11397, 2], [11398, 1, "\u2C87"], [11399, 2], [11400, 1, "\u2C89"], [11401, 2], [11402, 1, "\u2C8B"], [11403, 2], [11404, 1, "\u2C8D"], [11405, 2], [11406, 1, "\u2C8F"], [11407, 2], [11408, 1, "\u2C91"], [11409, 2], [11410, 1, "\u2C93"], [11411, 2], [11412, 1, "\u2C95"], [11413, 2], [11414, 1, "\u2C97"], [11415, 2], [11416, 1, "\u2C99"], [11417, 2], [11418, 1, "\u2C9B"], [11419, 2], [11420, 1, "\u2C9D"], [11421, 2], [11422, 1, "\u2C9F"], [11423, 2], [11424, 1, "\u2CA1"], [11425, 2], [11426, 1, "\u2CA3"], [11427, 2], [11428, 1, "\u2CA5"], [11429, 2], [11430, 1, "\u2CA7"], [11431, 2], [11432, 1, "\u2CA9"], [11433, 2], [11434, 1, "\u2CAB"], [11435, 2], [11436, 1, "\u2CAD"], [11437, 2], [11438, 1, "\u2CAF"], [11439, 2], [11440, 1, "\u2CB1"], [11441, 2], [11442, 1, "\u2CB3"], [11443, 2], [11444, 1, "\u2CB5"], [11445, 2], [11446, 1, "\u2CB7"], [11447, 2], [11448, 1, "\u2CB9"], [11449, 2], [11450, 1, "\u2CBB"], [11451, 2], [11452, 1, "\u2CBD"], [11453, 2], [11454, 1, "\u2CBF"], [11455, 2], [11456, 1, "\u2CC1"], [11457, 2], [11458, 1, "\u2CC3"], [11459, 2], [11460, 1, "\u2CC5"], [11461, 2], [11462, 1, "\u2CC7"], [11463, 2], [11464, 1, "\u2CC9"], [11465, 2], [11466, 1, "\u2CCB"], [11467, 2], [11468, 1, "\u2CCD"], [11469, 2], [11470, 1, "\u2CCF"], [11471, 2], [11472, 1, "\u2CD1"], [11473, 2], [11474, 1, "\u2CD3"], [11475, 2], [11476, 1, "\u2CD5"], [11477, 2], [11478, 1, "\u2CD7"], [11479, 2], [11480, 1, "\u2CD9"], [11481, 2], [11482, 1, "\u2CDB"], [11483, 2], [11484, 1, "\u2CDD"], [11485, 2], [11486, 1, "\u2CDF"], [11487, 2], [11488, 1, "\u2CE1"], [11489, 2], [11490, 1, "\u2CE3"], [[11491, 11492], 2], [[11493, 11498], 2], [11499, 1, "\u2CEC"], [11500, 2], [11501, 1, "\u2CEE"], [[11502, 11505], 2], [11506, 1, "\u2CF3"], [11507, 2], [[11508, 11512], 3], [[11513, 11519], 2], [[11520, 11557], 2], [11558, 3], [11559, 2], [[11560, 11564], 3], [11565, 2], [[11566, 11567], 3], [[11568, 11621], 2], [[11622, 11623], 2], [[11624, 11630], 3], [11631, 1, "\u2D61"], [11632, 2], [[11633, 11646], 3], [11647, 2], [[11648, 11670], 2], [[11671, 11679], 3], [[11680, 11686], 2], [11687, 3], [[11688, 11694], 2], [11695, 3], [[11696, 11702], 2], [11703, 3], [[11704, 11710], 2], [11711, 3], [[11712, 11718], 2], [11719, 3], [[11720, 11726], 2], [11727, 3], [[11728, 11734], 2], [11735, 3], [[11736, 11742], 2], [11743, 3], [[11744, 11775], 2], [[11776, 11799], 2], [[11800, 11803], 2], [[11804, 11805], 2], [[11806, 11822], 2], [11823, 2], [11824, 2], [11825, 2], [[11826, 11835], 2], [[11836, 11842], 2], [[11843, 11844], 2], [[11845, 11849], 2], [[11850, 11854], 2], [11855, 2], [[11856, 11858], 2], [[11859, 11869], 2], [[11870, 11903], 3], [[11904, 11929], 2], [11930, 3], [[11931, 11934], 2], [11935, 1, "\u6BCD"], [[11936, 12018], 2], [12019, 1, "\u9F9F"], [[12020, 12031], 3], [12032, 1, "\u4E00"], [12033, 1, "\u4E28"], [12034, 1, "\u4E36"], [12035, 1, "\u4E3F"], [12036, 1, "\u4E59"], [12037, 1, "\u4E85"], [12038, 1, "\u4E8C"], [12039, 1, "\u4EA0"], [12040, 1, "\u4EBA"], [12041, 1, "\u513F"], [12042, 1, "\u5165"], [12043, 1, "\u516B"], [12044, 1, "\u5182"], [12045, 1, "\u5196"], [12046, 1, "\u51AB"], [12047, 1, "\u51E0"], [12048, 1, "\u51F5"], [12049, 1, "\u5200"], [12050, 1, "\u529B"], [12051, 1, "\u52F9"], [12052, 1, "\u5315"], [12053, 1, "\u531A"], [12054, 1, "\u5338"], [12055, 1, "\u5341"], [12056, 1, "\u535C"], [12057, 1, "\u5369"], [12058, 1, "\u5382"], [12059, 1, "\u53B6"], [12060, 1, "\u53C8"], [12061, 1, "\u53E3"], [12062, 1, "\u56D7"], [12063, 1, "\u571F"], [12064, 1, "\u58EB"], [12065, 1, "\u5902"], [12066, 1, "\u590A"], [12067, 1, "\u5915"], [12068, 1, "\u5927"], [12069, 1, "\u5973"], [12070, 1, "\u5B50"], [12071, 1, "\u5B80"], [12072, 1, "\u5BF8"], [12073, 1, "\u5C0F"], [12074, 1, "\u5C22"], [12075, 1, "\u5C38"], [12076, 1, "\u5C6E"], [12077, 1, "\u5C71"], [12078, 1, "\u5DDB"], [12079, 1, "\u5DE5"], [12080, 1, "\u5DF1"], [12081, 1, "\u5DFE"], [12082, 1, "\u5E72"], [12083, 1, "\u5E7A"], [12084, 1, "\u5E7F"], [12085, 1, "\u5EF4"], [12086, 1, "\u5EFE"], [12087, 1, "\u5F0B"], [12088, 1, "\u5F13"], [12089, 1, "\u5F50"], [12090, 1, "\u5F61"], [12091, 1, "\u5F73"], [12092, 1, "\u5FC3"], [12093, 1, "\u6208"], [12094, 1, "\u6236"], [12095, 1, "\u624B"], [12096, 1, "\u652F"], [12097, 1, "\u6534"], [12098, 1, "\u6587"], [12099, 1, "\u6597"], [12100, 1, "\u65A4"], [12101, 1, "\u65B9"], [12102, 1, "\u65E0"], [12103, 1, "\u65E5"], [12104, 1, "\u66F0"], [12105, 1, "\u6708"], [12106, 1, "\u6728"], [12107, 1, "\u6B20"], [12108, 1, "\u6B62"], [12109, 1, "\u6B79"], [12110, 1, "\u6BB3"], [12111, 1, "\u6BCB"], [12112, 1, "\u6BD4"], [12113, 1, "\u6BDB"], [12114, 1, "\u6C0F"], [12115, 1, "\u6C14"], [12116, 1, "\u6C34"], [12117, 1, "\u706B"], [12118, 1, "\u722A"], [12119, 1, "\u7236"], [12120, 1, "\u723B"], [12121, 1, "\u723F"], [12122, 1, "\u7247"], [12123, 1, "\u7259"], [12124, 1, "\u725B"], [12125, 1, "\u72AC"], [12126, 1, "\u7384"], [12127, 1, "\u7389"], [12128, 1, "\u74DC"], [12129, 1, "\u74E6"], [12130, 1, "\u7518"], [12131, 1, "\u751F"], [12132, 1, "\u7528"], [12133, 1, "\u7530"], [12134, 1, "\u758B"], [12135, 1, "\u7592"], [12136, 1, "\u7676"], [12137, 1, "\u767D"], [12138, 1, "\u76AE"], [12139, 1, "\u76BF"], [12140, 1, "\u76EE"], [12141, 1, "\u77DB"], [12142, 1, "\u77E2"], [12143, 1, "\u77F3"], [12144, 1, "\u793A"], [12145, 1, "\u79B8"], [12146, 1, "\u79BE"], [12147, 1, "\u7A74"], [12148, 1, "\u7ACB"], [12149, 1, "\u7AF9"], [12150, 1, "\u7C73"], [12151, 1, "\u7CF8"], [12152, 1, "\u7F36"], [12153, 1, "\u7F51"], [12154, 1, "\u7F8A"], [12155, 1, "\u7FBD"], [12156, 1, "\u8001"], [12157, 1, "\u800C"], [12158, 1, "\u8012"], [12159, 1, "\u8033"], [12160, 1, "\u807F"], [12161, 1, "\u8089"], [12162, 1, "\u81E3"], [12163, 1, "\u81EA"], [12164, 1, "\u81F3"], [12165, 1, "\u81FC"], [12166, 1, "\u820C"], [12167, 1, "\u821B"], [12168, 1, "\u821F"], [12169, 1, "\u826E"], [12170, 1, "\u8272"], [12171, 1, "\u8278"], [12172, 1, "\u864D"], [12173, 1, "\u866B"], [12174, 1, "\u8840"], [12175, 1, "\u884C"], [12176, 1, "\u8863"], [12177, 1, "\u897E"], [12178, 1, "\u898B"], [12179, 1, "\u89D2"], [12180, 1, "\u8A00"], [12181, 1, "\u8C37"], [12182, 1, "\u8C46"], [12183, 1, "\u8C55"], [12184, 1, "\u8C78"], [12185, 1, "\u8C9D"], [12186, 1, "\u8D64"], [12187, 1, "\u8D70"], [12188, 1, "\u8DB3"], [12189, 1, "\u8EAB"], [12190, 1, "\u8ECA"], [12191, 1, "\u8F9B"], [12192, 1, "\u8FB0"], [12193, 1, "\u8FB5"], [12194, 1, "\u9091"], [12195, 1, "\u9149"], [12196, 1, "\u91C6"], [12197, 1, "\u91CC"], [12198, 1, "\u91D1"], [12199, 1, "\u9577"], [12200, 1, "\u9580"], [12201, 1, "\u961C"], [12202, 1, "\u96B6"], [12203, 1, "\u96B9"], [12204, 1, "\u96E8"], [12205, 1, "\u9751"], [12206, 1, "\u975E"], [12207, 1, "\u9762"], [12208, 1, "\u9769"], [12209, 1, "\u97CB"], [12210, 1, "\u97ED"], [12211, 1, "\u97F3"], [12212, 1, "\u9801"], [12213, 1, "\u98A8"], [12214, 1, "\u98DB"], [12215, 1, "\u98DF"], [12216, 1, "\u9996"], [12217, 1, "\u9999"], [12218, 1, "\u99AC"], [12219, 1, "\u9AA8"], [12220, 1, "\u9AD8"], [12221, 1, "\u9ADF"], [12222, 1, "\u9B25"], [12223, 1, "\u9B2F"], [12224, 1, "\u9B32"], [12225, 1, "\u9B3C"], [12226, 1, "\u9B5A"], [12227, 1, "\u9CE5"], [12228, 1, "\u9E75"], [12229, 1, "\u9E7F"], [12230, 1, "\u9EA5"], [12231, 1, "\u9EBB"], [12232, 1, "\u9EC3"], [12233, 1, "\u9ECD"], [12234, 1, "\u9ED1"], [12235, 1, "\u9EF9"], [12236, 1, "\u9EFD"], [12237, 1, "\u9F0E"], [12238, 1, "\u9F13"], [12239, 1, "\u9F20"], [12240, 1, "\u9F3B"], [12241, 1, "\u9F4A"], [12242, 1, "\u9F52"], [12243, 1, "\u9F8D"], [12244, 1, "\u9F9C"], [12245, 1, "\u9FA0"], [[12246, 12271], 3], [[12272, 12283], 3], [[12284, 12287], 3], [12288, 1, " "], [12289, 2], [12290, 1, "."], [[12291, 12292], 2], [[12293, 12295], 2], [[12296, 12329], 2], [[12330, 12333], 2], [[12334, 12341], 2], [12342, 1, "\u3012"], [12343, 2], [12344, 1, "\u5341"], [12345, 1, "\u5344"], [12346, 1, "\u5345"], [12347, 2], [12348, 2], [12349, 2], [12350, 2], [12351, 2], [12352, 3], [[12353, 12436], 2], [[12437, 12438], 2], [[12439, 12440], 3], [[12441, 12442], 2], [12443, 1, " \u3099"], [12444, 1, " \u309A"], [[12445, 12446], 2], [12447, 1, "\u3088\u308A"], [12448, 2], [[12449, 12542], 2], [12543, 1, "\u30B3\u30C8"], [[12544, 12548], 3], [[12549, 12588], 2], [12589, 2], [12590, 2], [12591, 2], [12592, 3], [12593, 1, "\u1100"], [12594, 1, "\u1101"], [12595, 1, "\u11AA"], [12596, 1, "\u1102"], [12597, 1, "\u11AC"], [12598, 1, "\u11AD"], [12599, 1, "\u1103"], [12600, 1, "\u1104"], [12601, 1, "\u1105"], [12602, 1, "\u11B0"], [12603, 1, "\u11B1"], [12604, 1, "\u11B2"], [12605, 1, "\u11B3"], [12606, 1, "\u11B4"], [12607, 1, "\u11B5"], [12608, 1, "\u111A"], [12609, 1, "\u1106"], [12610, 1, "\u1107"], [12611, 1, "\u1108"], [12612, 1, "\u1121"], [12613, 1, "\u1109"], [12614, 1, "\u110A"], [12615, 1, "\u110B"], [12616, 1, "\u110C"], [12617, 1, "\u110D"], [12618, 1, "\u110E"], [12619, 1, "\u110F"], [12620, 1, "\u1110"], [12621, 1, "\u1111"], [12622, 1, "\u1112"], [12623, 1, "\u1161"], [12624, 1, "\u1162"], [12625, 1, "\u1163"], [12626, 1, "\u1164"], [12627, 1, "\u1165"], [12628, 1, "\u1166"], [12629, 1, "\u1167"], [12630, 1, "\u1168"], [12631, 1, "\u1169"], [12632, 1, "\u116A"], [12633, 1, "\u116B"], [12634, 1, "\u116C"], [12635, 1, "\u116D"], [12636, 1, "\u116E"], [12637, 1, "\u116F"], [12638, 1, "\u1170"], [12639, 1, "\u1171"], [12640, 1, "\u1172"], [12641, 1, "\u1173"], [12642, 1, "\u1174"], [12643, 1, "\u1175"], [12644, 7], [12645, 1, "\u1114"], [12646, 1, "\u1115"], [12647, 1, "\u11C7"], [12648, 1, "\u11C8"], [12649, 1, "\u11CC"], [12650, 1, "\u11CE"], [12651, 1, "\u11D3"], [12652, 1, "\u11D7"], [12653, 1, "\u11D9"], [12654, 1, "\u111C"], [12655, 1, "\u11DD"], [12656, 1, "\u11DF"], [12657, 1, "\u111D"], [12658, 1, "\u111E"], [12659, 1, "\u1120"], [12660, 1, "\u1122"], [12661, 1, "\u1123"], [12662, 1, "\u1127"], [12663, 1, "\u1129"], [12664, 1, "\u112B"], [12665, 1, "\u112C"], [12666, 1, "\u112D"], [12667, 1, "\u112E"], [12668, 1, "\u112F"], [12669, 1, "\u1132"], [12670, 1, "\u1136"], [12671, 1, "\u1140"], [12672, 1, "\u1147"], [12673, 1, "\u114C"], [12674, 1, "\u11F1"], [12675, 1, "\u11F2"], [12676, 1, "\u1157"], [12677, 1, "\u1158"], [12678, 1, "\u1159"], [12679, 1, "\u1184"], [12680, 1, "\u1185"], [12681, 1, "\u1188"], [12682, 1, "\u1191"], [12683, 1, "\u1192"], [12684, 1, "\u1194"], [12685, 1, "\u119E"], [12686, 1, "\u11A1"], [12687, 3], [[12688, 12689], 2], [12690, 1, "\u4E00"], [12691, 1, "\u4E8C"], [12692, 1, "\u4E09"], [12693, 1, "\u56DB"], [12694, 1, "\u4E0A"], [12695, 1, "\u4E2D"], [12696, 1, "\u4E0B"], [12697, 1, "\u7532"], [12698, 1, "\u4E59"], [12699, 1, "\u4E19"], [12700, 1, "\u4E01"], [12701, 1, "\u5929"], [12702, 1, "\u5730"], [12703, 1, "\u4EBA"], [[12704, 12727], 2], [[12728, 12730], 2], [[12731, 12735], 2], [[12736, 12751], 2], [[12752, 12771], 2], [[12772, 12773], 2], [[12774, 12782], 3], [12783, 3], [[12784, 12799], 2], [12800, 1, "(\u1100)"], [12801, 1, "(\u1102)"], [12802, 1, "(\u1103)"], [12803, 1, "(\u1105)"], [12804, 1, "(\u1106)"], [12805, 1, "(\u1107)"], [12806, 1, "(\u1109)"], [12807, 1, "(\u110B)"], [12808, 1, "(\u110C)"], [12809, 1, "(\u110E)"], [12810, 1, "(\u110F)"], [12811, 1, "(\u1110)"], [12812, 1, "(\u1111)"], [12813, 1, "(\u1112)"], [12814, 1, "(\uAC00)"], [12815, 1, "(\uB098)"], [12816, 1, "(\uB2E4)"], [12817, 1, "(\uB77C)"], [12818, 1, "(\uB9C8)"], [12819, 1, "(\uBC14)"], [12820, 1, "(\uC0AC)"], [12821, 1, "(\uC544)"], [12822, 1, "(\uC790)"], [12823, 1, "(\uCC28)"], [12824, 1, "(\uCE74)"], [12825, 1, "(\uD0C0)"], [12826, 1, "(\uD30C)"], [12827, 1, "(\uD558)"], [12828, 1, "(\uC8FC)"], [12829, 1, "(\uC624\uC804)"], [12830, 1, "(\uC624\uD6C4)"], [12831, 3], [12832, 1, "(\u4E00)"], [12833, 1, "(\u4E8C)"], [12834, 1, "(\u4E09)"], [12835, 1, "(\u56DB)"], [12836, 1, "(\u4E94)"], [12837, 1, "(\u516D)"], [12838, 1, "(\u4E03)"], [12839, 1, "(\u516B)"], [12840, 1, "(\u4E5D)"], [12841, 1, "(\u5341)"], [12842, 1, "(\u6708)"], [12843, 1, "(\u706B)"], [12844, 1, "(\u6C34)"], [12845, 1, "(\u6728)"], [12846, 1, "(\u91D1)"], [12847, 1, "(\u571F)"], [12848, 1, "(\u65E5)"], [12849, 1, "(\u682A)"], [12850, 1, "(\u6709)"], [12851, 1, "(\u793E)"], [12852, 1, "(\u540D)"], [12853, 1, "(\u7279)"], [12854, 1, "(\u8CA1)"], [12855, 1, "(\u795D)"], [12856, 1, "(\u52B4)"], [12857, 1, "(\u4EE3)"], [12858, 1, "(\u547C)"], [12859, 1, "(\u5B66)"], [12860, 1, "(\u76E3)"], [12861, 1, "(\u4F01)"], [12862, 1, "(\u8CC7)"], [12863, 1, "(\u5354)"], [12864, 1, "(\u796D)"], [12865, 1, "(\u4F11)"], [12866, 1, "(\u81EA)"], [12867, 1, "(\u81F3)"], [12868, 1, "\u554F"], [12869, 1, "\u5E7C"], [12870, 1, "\u6587"], [12871, 1, "\u7B8F"], [[12872, 12879], 2], [12880, 1, "pte"], [12881, 1, "21"], [12882, 1, "22"], [12883, 1, "23"], [12884, 1, "24"], [12885, 1, "25"], [12886, 1, "26"], [12887, 1, "27"], [12888, 1, "28"], [12889, 1, "29"], [12890, 1, "30"], [12891, 1, "31"], [12892, 1, "32"], [12893, 1, "33"], [12894, 1, "34"], [12895, 1, "35"], [12896, 1, "\u1100"], [12897, 1, "\u1102"], [12898, 1, "\u1103"], [12899, 1, "\u1105"], [12900, 1, "\u1106"], [12901, 1, "\u1107"], [12902, 1, "\u1109"], [12903, 1, "\u110B"], [12904, 1, "\u110C"], [12905, 1, "\u110E"], [12906, 1, "\u110F"], [12907, 1, "\u1110"], [12908, 1, "\u1111"], [12909, 1, "\u1112"], [12910, 1, "\uAC00"], [12911, 1, "\uB098"], [12912, 1, "\uB2E4"], [12913, 1, "\uB77C"], [12914, 1, "\uB9C8"], [12915, 1, "\uBC14"], [12916, 1, "\uC0AC"], [12917, 1, "\uC544"], [12918, 1, "\uC790"], [12919, 1, "\uCC28"], [12920, 1, "\uCE74"], [12921, 1, "\uD0C0"], [12922, 1, "\uD30C"], [12923, 1, "\uD558"], [12924, 1, "\uCC38\uACE0"], [12925, 1, "\uC8FC\uC758"], [12926, 1, "\uC6B0"], [12927, 2], [12928, 1, "\u4E00"], [12929, 1, "\u4E8C"], [12930, 1, "\u4E09"], [12931, 1, "\u56DB"], [12932, 1, "\u4E94"], [12933, 1, "\u516D"], [12934, 1, "\u4E03"], [12935, 1, "\u516B"], [12936, 1, "\u4E5D"], [12937, 1, "\u5341"], [12938, 1, "\u6708"], [12939, 1, "\u706B"], [12940, 1, "\u6C34"], [12941, 1, "\u6728"], [12942, 1, "\u91D1"], [12943, 1, "\u571F"], [12944, 1, "\u65E5"], [12945, 1, "\u682A"], [12946, 1, "\u6709"], [12947, 1, "\u793E"], [12948, 1, "\u540D"], [12949, 1, "\u7279"], [12950, 1, "\u8CA1"], [12951, 1, "\u795D"], [12952, 1, "\u52B4"], [12953, 1, "\u79D8"], [12954, 1, "\u7537"], [12955, 1, "\u5973"], [12956, 1, "\u9069"], [12957, 1, "\u512A"], [12958, 1, "\u5370"], [12959, 1, "\u6CE8"], [12960, 1, "\u9805"], [12961, 1, "\u4F11"], [12962, 1, "\u5199"], [12963, 1, "\u6B63"], [12964, 1, "\u4E0A"], [12965, 1, "\u4E2D"], [12966, 1, "\u4E0B"], [12967, 1, "\u5DE6"], [12968, 1, "\u53F3"], [12969, 1, "\u533B"], [12970, 1, "\u5B97"], [12971, 1, "\u5B66"], [12972, 1, "\u76E3"], [12973, 1, "\u4F01"], [12974, 1, "\u8CC7"], [12975, 1, "\u5354"], [12976, 1, "\u591C"], [12977, 1, "36"], [12978, 1, "37"], [12979, 1, "38"], [12980, 1, "39"], [12981, 1, "40"], [12982, 1, "41"], [12983, 1, "42"], [12984, 1, "43"], [12985, 1, "44"], [12986, 1, "45"], [12987, 1, "46"], [12988, 1, "47"], [12989, 1, "48"], [12990, 1, "49"], [12991, 1, "50"], [12992, 1, "1\u6708"], [12993, 1, "2\u6708"], [12994, 1, "3\u6708"], [12995, 1, "4\u6708"], [12996, 1, "5\u6708"], [12997, 1, "6\u6708"], [12998, 1, "7\u6708"], [12999, 1, "8\u6708"], [13e3, 1, "9\u6708"], [13001, 1, "10\u6708"], [13002, 1, "11\u6708"], [13003, 1, "12\u6708"], [13004, 1, "hg"], [13005, 1, "erg"], [13006, 1, "ev"], [13007, 1, "ltd"], [13008, 1, "\u30A2"], [13009, 1, "\u30A4"], [13010, 1, "\u30A6"], [13011, 1, "\u30A8"], [13012, 1, "\u30AA"], [13013, 1, "\u30AB"], [13014, 1, "\u30AD"], [13015, 1, "\u30AF"], [13016, 1, "\u30B1"], [13017, 1, "\u30B3"], [13018, 1, "\u30B5"], [13019, 1, "\u30B7"], [13020, 1, "\u30B9"], [13021, 1, "\u30BB"], [13022, 1, "\u30BD"], [13023, 1, "\u30BF"], [13024, 1, "\u30C1"], [13025, 1, "\u30C4"], [13026, 1, "\u30C6"], [13027, 1, "\u30C8"], [13028, 1, "\u30CA"], [13029, 1, "\u30CB"], [13030, 1, "\u30CC"], [13031, 1, "\u30CD"], [13032, 1, "\u30CE"], [13033, 1, "\u30CF"], [13034, 1, "\u30D2"], [13035, 1, "\u30D5"], [13036, 1, "\u30D8"], [13037, 1, "\u30DB"], [13038, 1, "\u30DE"], [13039, 1, "\u30DF"], [13040, 1, "\u30E0"], [13041, 1, "\u30E1"], [13042, 1, "\u30E2"], [13043, 1, "\u30E4"], [13044, 1, "\u30E6"], [13045, 1, "\u30E8"], [13046, 1, "\u30E9"], [13047, 1, "\u30EA"], [13048, 1, "\u30EB"], [13049, 1, "\u30EC"], [13050, 1, "\u30ED"], [13051, 1, "\u30EF"], [13052, 1, "\u30F0"], [13053, 1, "\u30F1"], [13054, 1, "\u30F2"], [13055, 1, "\u4EE4\u548C"], [13056, 1, "\u30A2\u30D1\u30FC\u30C8"], [13057, 1, "\u30A2\u30EB\u30D5\u30A1"], [13058, 1, "\u30A2\u30F3\u30DA\u30A2"], [13059, 1, "\u30A2\u30FC\u30EB"], [13060, 1, "\u30A4\u30CB\u30F3\u30B0"], [13061, 1, "\u30A4\u30F3\u30C1"], [13062, 1, "\u30A6\u30A9\u30F3"], [13063, 1, "\u30A8\u30B9\u30AF\u30FC\u30C9"], [13064, 1, "\u30A8\u30FC\u30AB\u30FC"], [13065, 1, "\u30AA\u30F3\u30B9"], [13066, 1, "\u30AA\u30FC\u30E0"], [13067, 1, "\u30AB\u30A4\u30EA"], [13068, 1, "\u30AB\u30E9\u30C3\u30C8"], [13069, 1, "\u30AB\u30ED\u30EA\u30FC"], [13070, 1, "\u30AC\u30ED\u30F3"], [13071, 1, "\u30AC\u30F3\u30DE"], [13072, 1, "\u30AE\u30AC"], [13073, 1, "\u30AE\u30CB\u30FC"], [13074, 1, "\u30AD\u30E5\u30EA\u30FC"], [13075, 1, "\u30AE\u30EB\u30C0\u30FC"], [13076, 1, "\u30AD\u30ED"], [13077, 1, "\u30AD\u30ED\u30B0\u30E9\u30E0"], [13078, 1, "\u30AD\u30ED\u30E1\u30FC\u30C8\u30EB"], [13079, 1, "\u30AD\u30ED\u30EF\u30C3\u30C8"], [13080, 1, "\u30B0\u30E9\u30E0"], [13081, 1, "\u30B0\u30E9\u30E0\u30C8\u30F3"], [13082, 1, "\u30AF\u30EB\u30BC\u30A4\u30ED"], [13083, 1, "\u30AF\u30ED\u30FC\u30CD"], [13084, 1, "\u30B1\u30FC\u30B9"], [13085, 1, "\u30B3\u30EB\u30CA"], [13086, 1, "\u30B3\u30FC\u30DD"], [13087, 1, "\u30B5\u30A4\u30AF\u30EB"], [13088, 1, "\u30B5\u30F3\u30C1\u30FC\u30E0"], [13089, 1, "\u30B7\u30EA\u30F3\u30B0"], [13090, 1, "\u30BB\u30F3\u30C1"], [13091, 1, "\u30BB\u30F3\u30C8"], [13092, 1, "\u30C0\u30FC\u30B9"], [13093, 1, "\u30C7\u30B7"], [13094, 1, "\u30C9\u30EB"], [13095, 1, "\u30C8\u30F3"], [13096, 1, "\u30CA\u30CE"], [13097, 1, "\u30CE\u30C3\u30C8"], [13098, 1, "\u30CF\u30A4\u30C4"], [13099, 1, "\u30D1\u30FC\u30BB\u30F3\u30C8"], [13100, 1, "\u30D1\u30FC\u30C4"], [13101, 1, "\u30D0\u30FC\u30EC\u30EB"], [13102, 1, "\u30D4\u30A2\u30B9\u30C8\u30EB"], [13103, 1, "\u30D4\u30AF\u30EB"], [13104, 1, "\u30D4\u30B3"], [13105, 1, "\u30D3\u30EB"], [13106, 1, "\u30D5\u30A1\u30E9\u30C3\u30C9"], [13107, 1, "\u30D5\u30A3\u30FC\u30C8"], [13108, 1, "\u30D6\u30C3\u30B7\u30A7\u30EB"], [13109, 1, "\u30D5\u30E9\u30F3"], [13110, 1, "\u30D8\u30AF\u30BF\u30FC\u30EB"], [13111, 1, "\u30DA\u30BD"], [13112, 1, "\u30DA\u30CB\u30D2"], [13113, 1, "\u30D8\u30EB\u30C4"], [13114, 1, "\u30DA\u30F3\u30B9"], [13115, 1, "\u30DA\u30FC\u30B8"], [13116, 1, "\u30D9\u30FC\u30BF"], [13117, 1, "\u30DD\u30A4\u30F3\u30C8"], [13118, 1, "\u30DC\u30EB\u30C8"], [13119, 1, "\u30DB\u30F3"], [13120, 1, "\u30DD\u30F3\u30C9"], [13121, 1, "\u30DB\u30FC\u30EB"], [13122, 1, "\u30DB\u30FC\u30F3"], [13123, 1, "\u30DE\u30A4\u30AF\u30ED"], [13124, 1, "\u30DE\u30A4\u30EB"], [13125, 1, "\u30DE\u30C3\u30CF"], [13126, 1, "\u30DE\u30EB\u30AF"], [13127, 1, "\u30DE\u30F3\u30B7\u30E7\u30F3"], [13128, 1, "\u30DF\u30AF\u30ED\u30F3"], [13129, 1, "\u30DF\u30EA"], [13130, 1, "\u30DF\u30EA\u30D0\u30FC\u30EB"], [13131, 1, "\u30E1\u30AC"], [13132, 1, "\u30E1\u30AC\u30C8\u30F3"], [13133, 1, "\u30E1\u30FC\u30C8\u30EB"], [13134, 1, "\u30E4\u30FC\u30C9"], [13135, 1, "\u30E4\u30FC\u30EB"], [13136, 1, "\u30E6\u30A2\u30F3"], [13137, 1, "\u30EA\u30C3\u30C8\u30EB"], [13138, 1, "\u30EA\u30E9"], [13139, 1, "\u30EB\u30D4\u30FC"], [13140, 1, "\u30EB\u30FC\u30D6\u30EB"], [13141, 1, "\u30EC\u30E0"], [13142, 1, "\u30EC\u30F3\u30C8\u30B2\u30F3"], [13143, 1, "\u30EF\u30C3\u30C8"], [13144, 1, "0\u70B9"], [13145, 1, "1\u70B9"], [13146, 1, "2\u70B9"], [13147, 1, "3\u70B9"], [13148, 1, "4\u70B9"], [13149, 1, "5\u70B9"], [13150, 1, "6\u70B9"], [13151, 1, "7\u70B9"], [13152, 1, "8\u70B9"], [13153, 1, "9\u70B9"], [13154, 1, "10\u70B9"], [13155, 1, "11\u70B9"], [13156, 1, "12\u70B9"], [13157, 1, "13\u70B9"], [13158, 1, "14\u70B9"], [13159, 1, "15\u70B9"], [13160, 1, "16\u70B9"], [13161, 1, "17\u70B9"], [13162, 1, "18\u70B9"], [13163, 1, "19\u70B9"], [13164, 1, "20\u70B9"], [13165, 1, "21\u70B9"], [13166, 1, "22\u70B9"], [13167, 1, "23\u70B9"], [13168, 1, "24\u70B9"], [13169, 1, "hpa"], [13170, 1, "da"], [13171, 1, "au"], [13172, 1, "bar"], [13173, 1, "ov"], [13174, 1, "pc"], [13175, 1, "dm"], [13176, 1, "dm2"], [13177, 1, "dm3"], [13178, 1, "iu"], [13179, 1, "\u5E73\u6210"], [13180, 1, "\u662D\u548C"], [13181, 1, "\u5927\u6B63"], [13182, 1, "\u660E\u6CBB"], [13183, 1, "\u682A\u5F0F\u4F1A\u793E"], [13184, 1, "pa"], [13185, 1, "na"], [13186, 1, "\u03BCa"], [13187, 1, "ma"], [13188, 1, "ka"], [13189, 1, "kb"], [13190, 1, "mb"], [13191, 1, "gb"], [13192, 1, "cal"], [13193, 1, "kcal"], [13194, 1, "pf"], [13195, 1, "nf"], [13196, 1, "\u03BCf"], [13197, 1, "\u03BCg"], [13198, 1, "mg"], [13199, 1, "kg"], [13200, 1, "hz"], [13201, 1, "khz"], [13202, 1, "mhz"], [13203, 1, "ghz"], [13204, 1, "thz"], [13205, 1, "\u03BCl"], [13206, 1, "ml"], [13207, 1, "dl"], [13208, 1, "kl"], [13209, 1, "fm"], [13210, 1, "nm"], [13211, 1, "\u03BCm"], [13212, 1, "mm"], [13213, 1, "cm"], [13214, 1, "km"], [13215, 1, "mm2"], [13216, 1, "cm2"], [13217, 1, "m2"], [13218, 1, "km2"], [13219, 1, "mm3"], [13220, 1, "cm3"], [13221, 1, "m3"], [13222, 1, "km3"], [13223, 1, "m\u2215s"], [13224, 1, "m\u2215s2"], [13225, 1, "pa"], [13226, 1, "kpa"], [13227, 1, "mpa"], [13228, 1, "gpa"], [13229, 1, "rad"], [13230, 1, "rad\u2215s"], [13231, 1, "rad\u2215s2"], [13232, 1, "ps"], [13233, 1, "ns"], [13234, 1, "\u03BCs"], [13235, 1, "ms"], [13236, 1, "pv"], [13237, 1, "nv"], [13238, 1, "\u03BCv"], [13239, 1, "mv"], [13240, 1, "kv"], [13241, 1, "mv"], [13242, 1, "pw"], [13243, 1, "nw"], [13244, 1, "\u03BCw"], [13245, 1, "mw"], [13246, 1, "kw"], [13247, 1, "mw"], [13248, 1, "k\u03C9"], [13249, 1, "m\u03C9"], [13250, 3], [13251, 1, "bq"], [13252, 1, "cc"], [13253, 1, "cd"], [13254, 1, "c\u2215kg"], [13255, 3], [13256, 1, "db"], [13257, 1, "gy"], [13258, 1, "ha"], [13259, 1, "hp"], [13260, 1, "in"], [13261, 1, "kk"], [13262, 1, "km"], [13263, 1, "kt"], [13264, 1, "lm"], [13265, 1, "ln"], [13266, 1, "log"], [13267, 1, "lx"], [13268, 1, "mb"], [13269, 1, "mil"], [13270, 1, "mol"], [13271, 1, "ph"], [13272, 3], [13273, 1, "ppm"], [13274, 1, "pr"], [13275, 1, "sr"], [13276, 1, "sv"], [13277, 1, "wb"], [13278, 1, "v\u2215m"], [13279, 1, "a\u2215m"], [13280, 1, "1\u65E5"], [13281, 1, "2\u65E5"], [13282, 1, "3\u65E5"], [13283, 1, "4\u65E5"], [13284, 1, "5\u65E5"], [13285, 1, "6\u65E5"], [13286, 1, "7\u65E5"], [13287, 1, "8\u65E5"], [13288, 1, "9\u65E5"], [13289, 1, "10\u65E5"], [13290, 1, "11\u65E5"], [13291, 1, "12\u65E5"], [13292, 1, "13\u65E5"], [13293, 1, "14\u65E5"], [13294, 1, "15\u65E5"], [13295, 1, "16\u65E5"], [13296, 1, "17\u65E5"], [13297, 1, "18\u65E5"], [13298, 1, "19\u65E5"], [13299, 1, "20\u65E5"], [13300, 1, "21\u65E5"], [13301, 1, "22\u65E5"], [13302, 1, "23\u65E5"], [13303, 1, "24\u65E5"], [13304, 1, "25\u65E5"], [13305, 1, "26\u65E5"], [13306, 1, "27\u65E5"], [13307, 1, "28\u65E5"], [13308, 1, "29\u65E5"], [13309, 1, "30\u65E5"], [13310, 1, "31\u65E5"], [13311, 1, "gal"], [[13312, 19893], 2], [[19894, 19903], 2], [[19904, 19967], 2], [[19968, 40869], 2], [[40870, 40891], 2], [[40892, 40899], 2], [[40900, 40907], 2], [40908, 2], [[40909, 40917], 2], [[40918, 40938], 2], [[40939, 40943], 2], [[40944, 40956], 2], [[40957, 40959], 2], [[40960, 42124], 2], [[42125, 42127], 3], [[42128, 42145], 2], [[42146, 42147], 2], [[42148, 42163], 2], [42164, 2], [[42165, 42176], 2], [42177, 2], [[42178, 42180], 2], [42181, 2], [42182, 2], [[42183, 42191], 3], [[42192, 42237], 2], [[42238, 42239], 2], [[42240, 42508], 2], [[42509, 42511], 2], [[42512, 42539], 2], [[42540, 42559], 3], [42560, 1, "\uA641"], [42561, 2], [42562, 1, "\uA643"], [42563, 2], [42564, 1, "\uA645"], [42565, 2], [42566, 1, "\uA647"], [42567, 2], [42568, 1, "\uA649"], [42569, 2], [42570, 1, "\uA64B"], [42571, 2], [42572, 1, "\uA64D"], [42573, 2], [42574, 1, "\uA64F"], [42575, 2], [42576, 1, "\uA651"], [42577, 2], [42578, 1, "\uA653"], [42579, 2], [42580, 1, "\uA655"], [42581, 2], [42582, 1, "\uA657"], [42583, 2], [42584, 1, "\uA659"], [42585, 2], [42586, 1, "\uA65B"], [42587, 2], [42588, 1, "\uA65D"], [42589, 2], [42590, 1, "\uA65F"], [42591, 2], [42592, 1, "\uA661"], [42593, 2], [42594, 1, "\uA663"], [42595, 2], [42596, 1, "\uA665"], [42597, 2], [42598, 1, "\uA667"], [42599, 2], [42600, 1, "\uA669"], [42601, 2], [42602, 1, "\uA66B"], [42603, 2], [42604, 1, "\uA66D"], [[42605, 42607], 2], [[42608, 42611], 2], [[42612, 42619], 2], [[42620, 42621], 2], [42622, 2], [42623, 2], [42624, 1, "\uA681"], [42625, 2], [42626, 1, "\uA683"], [42627, 2], [42628, 1, "\uA685"], [42629, 2], [42630, 1, "\uA687"], [42631, 2], [42632, 1, "\uA689"], [42633, 2], [42634, 1, "\uA68B"], [42635, 2], [42636, 1, "\uA68D"], [42637, 2], [42638, 1, "\uA68F"], [42639, 2], [42640, 1, "\uA691"], [42641, 2], [42642, 1, "\uA693"], [42643, 2], [42644, 1, "\uA695"], [42645, 2], [42646, 1, "\uA697"], [42647, 2], [42648, 1, "\uA699"], [42649, 2], [42650, 1, "\uA69B"], [42651, 2], [42652, 1, "\u044A"], [42653, 1, "\u044C"], [42654, 2], [42655, 2], [[42656, 42725], 2], [[42726, 42735], 2], [[42736, 42737], 2], [[42738, 42743], 2], [[42744, 42751], 3], [[42752, 42774], 2], [[42775, 42778], 2], [[42779, 42783], 2], [[42784, 42785], 2], [42786, 1, "\uA723"], [42787, 2], [42788, 1, "\uA725"], [42789, 2], [42790, 1, "\uA727"], [42791, 2], [42792, 1, "\uA729"], [42793, 2], [42794, 1, "\uA72B"], [42795, 2], [42796, 1, "\uA72D"], [42797, 2], [42798, 1, "\uA72F"], [[42799, 42801], 2], [42802, 1, "\uA733"], [42803, 2], [42804, 1, "\uA735"], [42805, 2], [42806, 1, "\uA737"], [42807, 2], [42808, 1, "\uA739"], [42809, 2], [42810, 1, "\uA73B"], [42811, 2], [42812, 1, "\uA73D"], [42813, 2], [42814, 1, "\uA73F"], [42815, 2], [42816, 1, "\uA741"], [42817, 2], [42818, 1, "\uA743"], [42819, 2], [42820, 1, "\uA745"], [42821, 2], [42822, 1, "\uA747"], [42823, 2], [42824, 1, "\uA749"], [42825, 2], [42826, 1, "\uA74B"], [42827, 2], [42828, 1, "\uA74D"], [42829, 2], [42830, 1, "\uA74F"], [42831, 2], [42832, 1, "\uA751"], [42833, 2], [42834, 1, "\uA753"], [42835, 2], [42836, 1, "\uA755"], [42837, 2], [42838, 1, "\uA757"], [42839, 2], [42840, 1, "\uA759"], [42841, 2], [42842, 1, "\uA75B"], [42843, 2], [42844, 1, "\uA75D"], [42845, 2], [42846, 1, "\uA75F"], [42847, 2], [42848, 1, "\uA761"], [42849, 2], [42850, 1, "\uA763"], [42851, 2], [42852, 1, "\uA765"], [42853, 2], [42854, 1, "\uA767"], [42855, 2], [42856, 1, "\uA769"], [42857, 2], [42858, 1, "\uA76B"], [42859, 2], [42860, 1, "\uA76D"], [42861, 2], [42862, 1, "\uA76F"], [42863, 2], [42864, 1, "\uA76F"], [[42865, 42872], 2], [42873, 1, "\uA77A"], [42874, 2], [42875, 1, "\uA77C"], [42876, 2], [42877, 1, "\u1D79"], [42878, 1, "\uA77F"], [42879, 2], [42880, 1, "\uA781"], [42881, 2], [42882, 1, "\uA783"], [42883, 2], [42884, 1, "\uA785"], [42885, 2], [42886, 1, "\uA787"], [[42887, 42888], 2], [[42889, 42890], 2], [42891, 1, "\uA78C"], [42892, 2], [42893, 1, "\u0265"], [42894, 2], [42895, 2], [42896, 1, "\uA791"], [42897, 2], [42898, 1, "\uA793"], [42899, 2], [[42900, 42901], 2], [42902, 1, "\uA797"], [42903, 2], [42904, 1, "\uA799"], [42905, 2], [42906, 1, "\uA79B"], [42907, 2], [42908, 1, "\uA79D"], [42909, 2], [42910, 1, "\uA79F"], [42911, 2], [42912, 1, "\uA7A1"], [42913, 2], [42914, 1, "\uA7A3"], [42915, 2], [42916, 1, "\uA7A5"], [42917, 2], [42918, 1, "\uA7A7"], [42919, 2], [42920, 1, "\uA7A9"], [42921, 2], [42922, 1, "\u0266"], [42923, 1, "\u025C"], [42924, 1, "\u0261"], [42925, 1, "\u026C"], [42926, 1, "\u026A"], [42927, 2], [42928, 1, "\u029E"], [42929, 1, "\u0287"], [42930, 1, "\u029D"], [42931, 1, "\uAB53"], [42932, 1, "\uA7B5"], [42933, 2], [42934, 1, "\uA7B7"], [42935, 2], [42936, 1, "\uA7B9"], [42937, 2], [42938, 1, "\uA7BB"], [42939, 2], [42940, 1, "\uA7BD"], [42941, 2], [42942, 1, "\uA7BF"], [42943, 2], [42944, 1, "\uA7C1"], [42945, 2], [42946, 1, "\uA7C3"], [42947, 2], [42948, 1, "\uA794"], [42949, 1, "\u0282"], [42950, 1, "\u1D8E"], [42951, 1, "\uA7C8"], [42952, 2], [42953, 1, "\uA7CA"], [42954, 2], [42955, 1, "\u0264"], [42956, 1, "\uA7CD"], [42957, 2], [[42958, 42959], 3], [42960, 1, "\uA7D1"], [42961, 2], [42962, 3], [42963, 2], [42964, 3], [42965, 2], [42966, 1, "\uA7D7"], [42967, 2], [42968, 1, "\uA7D9"], [42969, 2], [42970, 1, "\uA7DB"], [42971, 2], [42972, 1, "\u019B"], [[42973, 42993], 3], [42994, 1, "c"], [42995, 1, "f"], [42996, 1, "q"], [42997, 1, "\uA7F6"], [42998, 2], [42999, 2], [43e3, 1, "\u0127"], [43001, 1, "\u0153"], [43002, 2], [[43003, 43007], 2], [[43008, 43047], 2], [[43048, 43051], 2], [43052, 2], [[43053, 43055], 3], [[43056, 43065], 2], [[43066, 43071], 3], [[43072, 43123], 2], [[43124, 43127], 2], [[43128, 43135], 3], [[43136, 43204], 2], [43205, 2], [[43206, 43213], 3], [[43214, 43215], 2], [[43216, 43225], 2], [[43226, 43231], 3], [[43232, 43255], 2], [[43256, 43258], 2], [43259, 2], [43260, 2], [43261, 2], [[43262, 43263], 2], [[43264, 43309], 2], [[43310, 43311], 2], [[43312, 43347], 2], [[43348, 43358], 3], [43359, 2], [[43360, 43388], 2], [[43389, 43391], 3], [[43392, 43456], 2], [[43457, 43469], 2], [43470, 3], [[43471, 43481], 2], [[43482, 43485], 3], [[43486, 43487], 2], [[43488, 43518], 2], [43519, 3], [[43520, 43574], 2], [[43575, 43583], 3], [[43584, 43597], 2], [[43598, 43599], 3], [[43600, 43609], 2], [[43610, 43611], 3], [[43612, 43615], 2], [[43616, 43638], 2], [[43639, 43641], 2], [[43642, 43643], 2], [[43644, 43647], 2], [[43648, 43714], 2], [[43715, 43738], 3], [[43739, 43741], 2], [[43742, 43743], 2], [[43744, 43759], 2], [[43760, 43761], 2], [[43762, 43766], 2], [[43767, 43776], 3], [[43777, 43782], 2], [[43783, 43784], 3], [[43785, 43790], 2], [[43791, 43792], 3], [[43793, 43798], 2], [[43799, 43807], 3], [[43808, 43814], 2], [43815, 3], [[43816, 43822], 2], [43823, 3], [[43824, 43866], 2], [43867, 2], [43868, 1, "\uA727"], [43869, 1, "\uAB37"], [43870, 1, "\u026B"], [43871, 1, "\uAB52"], [[43872, 43875], 2], [[43876, 43877], 2], [[43878, 43879], 2], [43880, 2], [43881, 1, "\u028D"], [[43882, 43883], 2], [[43884, 43887], 3], [43888, 1, "\u13A0"], [43889, 1, "\u13A1"], [43890, 1, "\u13A2"], [43891, 1, "\u13A3"], [43892, 1, "\u13A4"], [43893, 1, "\u13A5"], [43894, 1, "\u13A6"], [43895, 1, "\u13A7"], [43896, 1, "\u13A8"], [43897, 1, "\u13A9"], [43898, 1, "\u13AA"], [43899, 1, "\u13AB"], [43900, 1, "\u13AC"], [43901, 1, "\u13AD"], [43902, 1, "\u13AE"], [43903, 1, "\u13AF"], [43904, 1, "\u13B0"], [43905, 1, "\u13B1"], [43906, 1, "\u13B2"], [43907, 1, "\u13B3"], [43908, 1, "\u13B4"], [43909, 1, "\u13B5"], [43910, 1, "\u13B6"], [43911, 1, "\u13B7"], [43912, 1, "\u13B8"], [43913, 1, "\u13B9"], [43914, 1, "\u13BA"], [43915, 1, "\u13BB"], [43916, 1, "\u13BC"], [43917, 1, "\u13BD"], [43918, 1, "\u13BE"], [43919, 1, "\u13BF"], [43920, 1, "\u13C0"], [43921, 1, "\u13C1"], [43922, 1, "\u13C2"], [43923, 1, "\u13C3"], [43924, 1, "\u13C4"], [43925, 1, "\u13C5"], [43926, 1, "\u13C6"], [43927, 1, "\u13C7"], [43928, 1, "\u13C8"], [43929, 1, "\u13C9"], [43930, 1, "\u13CA"], [43931, 1, "\u13CB"], [43932, 1, "\u13CC"], [43933, 1, "\u13CD"], [43934, 1, "\u13CE"], [43935, 1, "\u13CF"], [43936, 1, "\u13D0"], [43937, 1, "\u13D1"], [43938, 1, "\u13D2"], [43939, 1, "\u13D3"], [43940, 1, "\u13D4"], [43941, 1, "\u13D5"], [43942, 1, "\u13D6"], [43943, 1, "\u13D7"], [43944, 1, "\u13D8"], [43945, 1, "\u13D9"], [43946, 1, "\u13DA"], [43947, 1, "\u13DB"], [43948, 1, "\u13DC"], [43949, 1, "\u13DD"], [43950, 1, "\u13DE"], [43951, 1, "\u13DF"], [43952, 1, "\u13E0"], [43953, 1, "\u13E1"], [43954, 1, "\u13E2"], [43955, 1, "\u13E3"], [43956, 1, "\u13E4"], [43957, 1, "\u13E5"], [43958, 1, "\u13E6"], [43959, 1, "\u13E7"], [43960, 1, "\u13E8"], [43961, 1, "\u13E9"], [43962, 1, "\u13EA"], [43963, 1, "\u13EB"], [43964, 1, "\u13EC"], [43965, 1, "\u13ED"], [43966, 1, "\u13EE"], [43967, 1, "\u13EF"], [[43968, 44010], 2], [44011, 2], [[44012, 44013], 2], [[44014, 44015], 3], [[44016, 44025], 2], [[44026, 44031], 3], [[44032, 55203], 2], [[55204, 55215], 3], [[55216, 55238], 2], [[55239, 55242], 3], [[55243, 55291], 2], [[55292, 55295], 3], [[55296, 57343], 3], [[57344, 63743], 3], [63744, 1, "\u8C48"], [63745, 1, "\u66F4"], [63746, 1, "\u8ECA"], [63747, 1, "\u8CC8"], [63748, 1, "\u6ED1"], [63749, 1, "\u4E32"], [63750, 1, "\u53E5"], [[63751, 63752], 1, "\u9F9C"], [63753, 1, "\u5951"], [63754, 1, "\u91D1"], [63755, 1, "\u5587"], [63756, 1, "\u5948"], [63757, 1, "\u61F6"], [63758, 1, "\u7669"], [63759, 1, "\u7F85"], [63760, 1, "\u863F"], [63761, 1, "\u87BA"], [63762, 1, "\u88F8"], [63763, 1, "\u908F"], [63764, 1, "\u6A02"], [63765, 1, "\u6D1B"], [63766, 1, "\u70D9"], [63767, 1, "\u73DE"], [63768, 1, "\u843D"], [63769, 1, "\u916A"], [63770, 1, "\u99F1"], [63771, 1, "\u4E82"], [63772, 1, "\u5375"], [63773, 1, "\u6B04"], [63774, 1, "\u721B"], [63775, 1, "\u862D"], [63776, 1, "\u9E1E"], [63777, 1, "\u5D50"], [63778, 1, "\u6FEB"], [63779, 1, "\u85CD"], [63780, 1, "\u8964"], [63781, 1, "\u62C9"], [63782, 1, "\u81D8"], [63783, 1, "\u881F"], [63784, 1, "\u5ECA"], [63785, 1, "\u6717"], [63786, 1, "\u6D6A"], [63787, 1, "\u72FC"], [63788, 1, "\u90CE"], [63789, 1, "\u4F86"], [63790, 1, "\u51B7"], [63791, 1, "\u52DE"], [63792, 1, "\u64C4"], [63793, 1, "\u6AD3"], [63794, 1, "\u7210"], [63795, 1, "\u76E7"], [63796, 1, "\u8001"], [63797, 1, "\u8606"], [63798, 1, "\u865C"], [63799, 1, "\u8DEF"], [63800, 1, "\u9732"], [63801, 1, "\u9B6F"], [63802, 1, "\u9DFA"], [63803, 1, "\u788C"], [63804, 1, "\u797F"], [63805, 1, "\u7DA0"], [63806, 1, "\u83C9"], [63807, 1, "\u9304"], [63808, 1, "\u9E7F"], [63809, 1, "\u8AD6"], [63810, 1, "\u58DF"], [63811, 1, "\u5F04"], [63812, 1, "\u7C60"], [63813, 1, "\u807E"], [63814, 1, "\u7262"], [63815, 1, "\u78CA"], [63816, 1, "\u8CC2"], [63817, 1, "\u96F7"], [63818, 1, "\u58D8"], [63819, 1, "\u5C62"], [63820, 1, "\u6A13"], [63821, 1, "\u6DDA"], [63822, 1, "\u6F0F"], [63823, 1, "\u7D2F"], [63824, 1, "\u7E37"], [63825, 1, "\u964B"], [63826, 1, "\u52D2"], [63827, 1, "\u808B"], [63828, 1, "\u51DC"], [63829, 1, "\u51CC"], [63830, 1, "\u7A1C"], [63831, 1, "\u7DBE"], [63832, 1, "\u83F1"], [63833, 1, "\u9675"], [63834, 1, "\u8B80"], [63835, 1, "\u62CF"], [63836, 1, "\u6A02"], [63837, 1, "\u8AFE"], [63838, 1, "\u4E39"], [63839, 1, "\u5BE7"], [63840, 1, "\u6012"], [63841, 1, "\u7387"], [63842, 1, "\u7570"], [63843, 1, "\u5317"], [63844, 1, "\u78FB"], [63845, 1, "\u4FBF"], [63846, 1, "\u5FA9"], [63847, 1, "\u4E0D"], [63848, 1, "\u6CCC"], [63849, 1, "\u6578"], [63850, 1, "\u7D22"], [63851, 1, "\u53C3"], [63852, 1, "\u585E"], [63853, 1, "\u7701"], [63854, 1, "\u8449"], [63855, 1, "\u8AAA"], [63856, 1, "\u6BBA"], [63857, 1, "\u8FB0"], [63858, 1, "\u6C88"], [63859, 1, "\u62FE"], [63860, 1, "\u82E5"], [63861, 1, "\u63A0"], [63862, 1, "\u7565"], [63863, 1, "\u4EAE"], [63864, 1, "\u5169"], [63865, 1, "\u51C9"], [63866, 1, "\u6881"], [63867, 1, "\u7CE7"], [63868, 1, "\u826F"], [63869, 1, "\u8AD2"], [63870, 1, "\u91CF"], [63871, 1, "\u52F5"], [63872, 1, "\u5442"], [63873, 1, "\u5973"], [63874, 1, "\u5EEC"], [63875, 1, "\u65C5"], [63876, 1, "\u6FFE"], [63877, 1, "\u792A"], [63878, 1, "\u95AD"], [63879, 1, "\u9A6A"], [63880, 1, "\u9E97"], [63881, 1, "\u9ECE"], [63882, 1, "\u529B"], [63883, 1, "\u66C6"], [63884, 1, "\u6B77"], [63885, 1, "\u8F62"], [63886, 1, "\u5E74"], [63887, 1, "\u6190"], [63888, 1, "\u6200"], [63889, 1, "\u649A"], [63890, 1, "\u6F23"], [63891, 1, "\u7149"], [63892, 1, "\u7489"], [63893, 1, "\u79CA"], [63894, 1, "\u7DF4"], [63895, 1, "\u806F"], [63896, 1, "\u8F26"], [63897, 1, "\u84EE"], [63898, 1, "\u9023"], [63899, 1, "\u934A"], [63900, 1, "\u5217"], [63901, 1, "\u52A3"], [63902, 1, "\u54BD"], [63903, 1, "\u70C8"], [63904, 1, "\u88C2"], [63905, 1, "\u8AAA"], [63906, 1, "\u5EC9"], [63907, 1, "\u5FF5"], [63908, 1, "\u637B"], [63909, 1, "\u6BAE"], [63910, 1, "\u7C3E"], [63911, 1, "\u7375"], [63912, 1, "\u4EE4"], [63913, 1, "\u56F9"], [63914, 1, "\u5BE7"], [63915, 1, "\u5DBA"], [63916, 1, "\u601C"], [63917, 1, "\u73B2"], [63918, 1, "\u7469"], [63919, 1, "\u7F9A"], [63920, 1, "\u8046"], [63921, 1, "\u9234"], [63922, 1, "\u96F6"], [63923, 1, "\u9748"], [63924, 1, "\u9818"], [63925, 1, "\u4F8B"], [63926, 1, "\u79AE"], [63927, 1, "\u91B4"], [63928, 1, "\u96B8"], [63929, 1, "\u60E1"], [63930, 1, "\u4E86"], [63931, 1, "\u50DA"], [63932, 1, "\u5BEE"], [63933, 1, "\u5C3F"], [63934, 1, "\u6599"], [63935, 1, "\u6A02"], [63936, 1, "\u71CE"], [63937, 1, "\u7642"], [63938, 1, "\u84FC"], [63939, 1, "\u907C"], [63940, 1, "\u9F8D"], [63941, 1, "\u6688"], [63942, 1, "\u962E"], [63943, 1, "\u5289"], [63944, 1, "\u677B"], [63945, 1, "\u67F3"], [63946, 1, "\u6D41"], [63947, 1, "\u6E9C"], [63948, 1, "\u7409"], [63949, 1, "\u7559"], [63950, 1, "\u786B"], [63951, 1, "\u7D10"], [63952, 1, "\u985E"], [63953, 1, "\u516D"], [63954, 1, "\u622E"], [63955, 1, "\u9678"], [63956, 1, "\u502B"], [63957, 1, "\u5D19"], [63958, 1, "\u6DEA"], [63959, 1, "\u8F2A"], [63960, 1, "\u5F8B"], [63961, 1, "\u6144"], [63962, 1, "\u6817"], [63963, 1, "\u7387"], [63964, 1, "\u9686"], [63965, 1, "\u5229"], [63966, 1, "\u540F"], [63967, 1, "\u5C65"], [63968, 1, "\u6613"], [63969, 1, "\u674E"], [63970, 1, "\u68A8"], [63971, 1, "\u6CE5"], [63972, 1, "\u7406"], [63973, 1, "\u75E2"], [63974, 1, "\u7F79"], [63975, 1, "\u88CF"], [63976, 1, "\u88E1"], [63977, 1, "\u91CC"], [63978, 1, "\u96E2"], [63979, 1, "\u533F"], [63980, 1, "\u6EBA"], [63981, 1, "\u541D"], [63982, 1, "\u71D0"], [63983, 1, "\u7498"], [63984, 1, "\u85FA"], [63985, 1, "\u96A3"], [63986, 1, "\u9C57"], [63987, 1, "\u9E9F"], [63988, 1, "\u6797"], [63989, 1, "\u6DCB"], [63990, 1, "\u81E8"], [63991, 1, "\u7ACB"], [63992, 1, "\u7B20"], [63993, 1, "\u7C92"], [63994, 1, "\u72C0"], [63995, 1, "\u7099"], [63996, 1, "\u8B58"], [63997, 1, "\u4EC0"], [63998, 1, "\u8336"], [63999, 1, "\u523A"], [64e3, 1, "\u5207"], [64001, 1, "\u5EA6"], [64002, 1, "\u62D3"], [64003, 1, "\u7CD6"], [64004, 1, "\u5B85"], [64005, 1, "\u6D1E"], [64006, 1, "\u66B4"], [64007, 1, "\u8F3B"], [64008, 1, "\u884C"], [64009, 1, "\u964D"], [64010, 1, "\u898B"], [64011, 1, "\u5ED3"], [64012, 1, "\u5140"], [64013, 1, "\u55C0"], [[64014, 64015], 2], [64016, 1, "\u585A"], [64017, 2], [64018, 1, "\u6674"], [[64019, 64020], 2], [64021, 1, "\u51DE"], [64022, 1, "\u732A"], [64023, 1, "\u76CA"], [64024, 1, "\u793C"], [64025, 1, "\u795E"], [64026, 1, "\u7965"], [64027, 1, "\u798F"], [64028, 1, "\u9756"], [64029, 1, "\u7CBE"], [64030, 1, "\u7FBD"], [64031, 2], [64032, 1, "\u8612"], [64033, 2], [64034, 1, "\u8AF8"], [[64035, 64036], 2], [64037, 1, "\u9038"], [64038, 1, "\u90FD"], [[64039, 64041], 2], [64042, 1, "\u98EF"], [64043, 1, "\u98FC"], [64044, 1, "\u9928"], [64045, 1, "\u9DB4"], [64046, 1, "\u90DE"], [64047, 1, "\u96B7"], [64048, 1, "\u4FAE"], [64049, 1, "\u50E7"], [64050, 1, "\u514D"], [64051, 1, "\u52C9"], [64052, 1, "\u52E4"], [64053, 1, "\u5351"], [64054, 1, "\u559D"], [64055, 1, "\u5606"], [64056, 1, "\u5668"], [64057, 1, "\u5840"], [64058, 1, "\u58A8"], [64059, 1, "\u5C64"], [64060, 1, "\u5C6E"], [64061, 1, "\u6094"], [64062, 1, "\u6168"], [64063, 1, "\u618E"], [64064, 1, "\u61F2"], [64065, 1, "\u654F"], [64066, 1, "\u65E2"], [64067, 1, "\u6691"], [64068, 1, "\u6885"], [64069, 1, "\u6D77"], [64070, 1, "\u6E1A"], [64071, 1, "\u6F22"], [64072, 1, "\u716E"], [64073, 1, "\u722B"], [64074, 1, "\u7422"], [64075, 1, "\u7891"], [64076, 1, "\u793E"], [64077, 1, "\u7949"], [64078, 1, "\u7948"], [64079, 1, "\u7950"], [64080, 1, "\u7956"], [64081, 1, "\u795D"], [64082, 1, "\u798D"], [64083, 1, "\u798E"], [64084, 1, "\u7A40"], [64085, 1, "\u7A81"], [64086, 1, "\u7BC0"], [64087, 1, "\u7DF4"], [64088, 1, "\u7E09"], [64089, 1, "\u7E41"], [64090, 1, "\u7F72"], [64091, 1, "\u8005"], [64092, 1, "\u81ED"], [[64093, 64094], 1, "\u8279"], [64095, 1, "\u8457"], [64096, 1, "\u8910"], [64097, 1, "\u8996"], [64098, 1, "\u8B01"], [64099, 1, "\u8B39"], [64100, 1, "\u8CD3"], [64101, 1, "\u8D08"], [64102, 1, "\u8FB6"], [64103, 1, "\u9038"], [64104, 1, "\u96E3"], [64105, 1, "\u97FF"], [64106, 1, "\u983B"], [64107, 1, "\u6075"], [64108, 1, "\u{242EE}"], [64109, 1, "\u8218"], [[64110, 64111], 3], [64112, 1, "\u4E26"], [64113, 1, "\u51B5"], [64114, 1, "\u5168"], [64115, 1, "\u4F80"], [64116, 1, "\u5145"], [64117, 1, "\u5180"], [64118, 1, "\u52C7"], [64119, 1, "\u52FA"], [64120, 1, "\u559D"], [64121, 1, "\u5555"], [64122, 1, "\u5599"], [64123, 1, "\u55E2"], [64124, 1, "\u585A"], [64125, 1, "\u58B3"], [64126, 1, "\u5944"], [64127, 1, "\u5954"], [64128, 1, "\u5A62"], [64129, 1, "\u5B28"], [64130, 1, "\u5ED2"], [64131, 1, "\u5ED9"], [64132, 1, "\u5F69"], [64133, 1, "\u5FAD"], [64134, 1, "\u60D8"], [64135, 1, "\u614E"], [64136, 1, "\u6108"], [64137, 1, "\u618E"], [64138, 1, "\u6160"], [64139, 1, "\u61F2"], [64140, 1, "\u6234"], [64141, 1, "\u63C4"], [64142, 1, "\u641C"], [64143, 1, "\u6452"], [64144, 1, "\u6556"], [64145, 1, "\u6674"], [64146, 1, "\u6717"], [64147, 1, "\u671B"], [64148, 1, "\u6756"], [64149, 1, "\u6B79"], [64150, 1, "\u6BBA"], [64151, 1, "\u6D41"], [64152, 1, "\u6EDB"], [64153, 1, "\u6ECB"], [64154, 1, "\u6F22"], [64155, 1, "\u701E"], [64156, 1, "\u716E"], [64157, 1, "\u77A7"], [64158, 1, "\u7235"], [64159, 1, "\u72AF"], [64160, 1, "\u732A"], [64161, 1, "\u7471"], [64162, 1, "\u7506"], [64163, 1, "\u753B"], [64164, 1, "\u761D"], [64165, 1, "\u761F"], [64166, 1, "\u76CA"], [64167, 1, "\u76DB"], [64168, 1, "\u76F4"], [64169, 1, "\u774A"], [64170, 1, "\u7740"], [64171, 1, "\u78CC"], [64172, 1, "\u7AB1"], [64173, 1, "\u7BC0"], [64174, 1, "\u7C7B"], [64175, 1, "\u7D5B"], [64176, 1, "\u7DF4"], [64177, 1, "\u7F3E"], [64178, 1, "\u8005"], [64179, 1, "\u8352"], [64180, 1, "\u83EF"], [64181, 1, "\u8779"], [64182, 1, "\u8941"], [64183, 1, "\u8986"], [64184, 1, "\u8996"], [64185, 1, "\u8ABF"], [64186, 1, "\u8AF8"], [64187, 1, "\u8ACB"], [64188, 1, "\u8B01"], [64189, 1, "\u8AFE"], [64190, 1, "\u8AED"], [64191, 1, "\u8B39"], [64192, 1, "\u8B8A"], [64193, 1, "\u8D08"], [64194, 1, "\u8F38"], [64195, 1, "\u9072"], [64196, 1, "\u9199"], [64197, 1, "\u9276"], [64198, 1, "\u967C"], [64199, 1, "\u96E3"], [64200, 1, "\u9756"], [64201, 1, "\u97DB"], [64202, 1, "\u97FF"], [64203, 1, "\u980B"], [64204, 1, "\u983B"], [64205, 1, "\u9B12"], [64206, 1, "\u9F9C"], [64207, 1, "\u{2284A}"], [64208, 1, "\u{22844}"], [64209, 1, "\u{233D5}"], [64210, 1, "\u3B9D"], [64211, 1, "\u4018"], [64212, 1, "\u4039"], [64213, 1, "\u{25249}"], [64214, 1, "\u{25CD0}"], [64215, 1, "\u{27ED3}"], [64216, 1, "\u9F43"], [64217, 1, "\u9F8E"], [[64218, 64255], 3], [64256, 1, "ff"], [64257, 1, "fi"], [64258, 1, "fl"], [64259, 1, "ffi"], [64260, 1, "ffl"], [[64261, 64262], 1, "st"], [[64263, 64274], 3], [64275, 1, "\u0574\u0576"], [64276, 1, "\u0574\u0565"], [64277, 1, "\u0574\u056B"], [64278, 1, "\u057E\u0576"], [64279, 1, "\u0574\u056D"], [[64280, 64284], 3], [64285, 1, "\u05D9\u05B4"], [64286, 2], [64287, 1, "\u05F2\u05B7"], [64288, 1, "\u05E2"], [64289, 1, "\u05D0"], [64290, 1, "\u05D3"], [64291, 1, "\u05D4"], [64292, 1, "\u05DB"], [64293, 1, "\u05DC"], [64294, 1, "\u05DD"], [64295, 1, "\u05E8"], [64296, 1, "\u05EA"], [64297, 1, "+"], [64298, 1, "\u05E9\u05C1"], [64299, 1, "\u05E9\u05C2"], [64300, 1, "\u05E9\u05BC\u05C1"], [64301, 1, "\u05E9\u05BC\u05C2"], [64302, 1, "\u05D0\u05B7"], [64303, 1, "\u05D0\u05B8"], [64304, 1, "\u05D0\u05BC"], [64305, 1, "\u05D1\u05BC"], [64306, 1, "\u05D2\u05BC"], [64307, 1, "\u05D3\u05BC"], [64308, 1, "\u05D4\u05BC"], [64309, 1, "\u05D5\u05BC"], [64310, 1, "\u05D6\u05BC"], [64311, 3], [64312, 1, "\u05D8\u05BC"], [64313, 1, "\u05D9\u05BC"], [64314, 1, "\u05DA\u05BC"], [64315, 1, "\u05DB\u05BC"], [64316, 1, "\u05DC\u05BC"], [64317, 3], [64318, 1, "\u05DE\u05BC"], [64319, 3], [64320, 1, "\u05E0\u05BC"], [64321, 1, "\u05E1\u05BC"], [64322, 3], [64323, 1, "\u05E3\u05BC"], [64324, 1, "\u05E4\u05BC"], [64325, 3], [64326, 1, "\u05E6\u05BC"], [64327, 1, "\u05E7\u05BC"], [64328, 1, "\u05E8\u05BC"], [64329, 1, "\u05E9\u05BC"], [64330, 1, "\u05EA\u05BC"], [64331, 1, "\u05D5\u05B9"], [64332, 1, "\u05D1\u05BF"], [64333, 1, "\u05DB\u05BF"], [64334, 1, "\u05E4\u05BF"], [64335, 1, "\u05D0\u05DC"], [[64336, 64337], 1, "\u0671"], [[64338, 64341], 1, "\u067B"], [[64342, 64345], 1, "\u067E"], [[64346, 64349], 1, "\u0680"], [[64350, 64353], 1, "\u067A"], [[64354, 64357], 1, "\u067F"], [[64358, 64361], 1, "\u0679"], [[64362, 64365], 1, "\u06A4"], [[64366, 64369], 1, "\u06A6"], [[64370, 64373], 1, "\u0684"], [[64374, 64377], 1, "\u0683"], [[64378, 64381], 1, "\u0686"], [[64382, 64385], 1, "\u0687"], [[64386, 64387], 1, "\u068D"], [[64388, 64389], 1, "\u068C"], [[64390, 64391], 1, "\u068E"], [[64392, 64393], 1, "\u0688"], [[64394, 64395], 1, "\u0698"], [[64396, 64397], 1, "\u0691"], [[64398, 64401], 1, "\u06A9"], [[64402, 64405], 1, "\u06AF"], [[64406, 64409], 1, "\u06B3"], [[64410, 64413], 1, "\u06B1"], [[64414, 64415], 1, "\u06BA"], [[64416, 64419], 1, "\u06BB"], [[64420, 64421], 1, "\u06C0"], [[64422, 64425], 1, "\u06C1"], [[64426, 64429], 1, "\u06BE"], [[64430, 64431], 1, "\u06D2"], [[64432, 64433], 1, "\u06D3"], [[64434, 64449], 2], [64450, 2], [[64451, 64466], 3], [[64467, 64470], 1, "\u06AD"], [[64471, 64472], 1, "\u06C7"], [[64473, 64474], 1, "\u06C6"], [[64475, 64476], 1, "\u06C8"], [64477, 1, "\u06C7\u0674"], [[64478, 64479], 1, "\u06CB"], [[64480, 64481], 1, "\u06C5"], [[64482, 64483], 1, "\u06C9"], [[64484, 64487], 1, "\u06D0"], [[64488, 64489], 1, "\u0649"], [[64490, 64491], 1, "\u0626\u0627"], [[64492, 64493], 1, "\u0626\u06D5"], [[64494, 64495], 1, "\u0626\u0648"], [[64496, 64497], 1, "\u0626\u06C7"], [[64498, 64499], 1, "\u0626\u06C6"], [[64500, 64501], 1, "\u0626\u06C8"], [[64502, 64504], 1, "\u0626\u06D0"], [[64505, 64507], 1, "\u0626\u0649"], [[64508, 64511], 1, "\u06CC"], [64512, 1, "\u0626\u062C"], [64513, 1, "\u0626\u062D"], [64514, 1, "\u0626\u0645"], [64515, 1, "\u0626\u0649"], [64516, 1, "\u0626\u064A"], [64517, 1, "\u0628\u062C"], [64518, 1, "\u0628\u062D"], [64519, 1, "\u0628\u062E"], [64520, 1, "\u0628\u0645"], [64521, 1, "\u0628\u0649"], [64522, 1, "\u0628\u064A"], [64523, 1, "\u062A\u062C"], [64524, 1, "\u062A\u062D"], [64525, 1, "\u062A\u062E"], [64526, 1, "\u062A\u0645"], [64527, 1, "\u062A\u0649"], [64528, 1, "\u062A\u064A"], [64529, 1, "\u062B\u062C"], [64530, 1, "\u062B\u0645"], [64531, 1, "\u062B\u0649"], [64532, 1, "\u062B\u064A"], [64533, 1, "\u062C\u062D"], [64534, 1, "\u062C\u0645"], [64535, 1, "\u062D\u062C"], [64536, 1, "\u062D\u0645"], [64537, 1, "\u062E\u062C"], [64538, 1, "\u062E\u062D"], [64539, 1, "\u062E\u0645"], [64540, 1, "\u0633\u062C"], [64541, 1, "\u0633\u062D"], [64542, 1, "\u0633\u062E"], [64543, 1, "\u0633\u0645"], [64544, 1, "\u0635\u062D"], [64545, 1, "\u0635\u0645"], [64546, 1, "\u0636\u062C"], [64547, 1, "\u0636\u062D"], [64548, 1, "\u0636\u062E"], [64549, 1, "\u0636\u0645"], [64550, 1, "\u0637\u062D"], [64551, 1, "\u0637\u0645"], [64552, 1, "\u0638\u0645"], [64553, 1, "\u0639\u062C"], [64554, 1, "\u0639\u0645"], [64555, 1, "\u063A\u062C"], [64556, 1, "\u063A\u0645"], [64557, 1, "\u0641\u062C"], [64558, 1, "\u0641\u062D"], [64559, 1, "\u0641\u062E"], [64560, 1, "\u0641\u0645"], [64561, 1, "\u0641\u0649"], [64562, 1, "\u0641\u064A"], [64563, 1, "\u0642\u062D"], [64564, 1, "\u0642\u0645"], [64565, 1, "\u0642\u0649"], [64566, 1, "\u0642\u064A"], [64567, 1, "\u0643\u0627"], [64568, 1, "\u0643\u062C"], [64569, 1, "\u0643\u062D"], [64570, 1, "\u0643\u062E"], [64571, 1, "\u0643\u0644"], [64572, 1, "\u0643\u0645"], [64573, 1, "\u0643\u0649"], [64574, 1, "\u0643\u064A"], [64575, 1, "\u0644\u062C"], [64576, 1, "\u0644\u062D"], [64577, 1, "\u0644\u062E"], [64578, 1, "\u0644\u0645"], [64579, 1, "\u0644\u0649"], [64580, 1, "\u0644\u064A"], [64581, 1, "\u0645\u062C"], [64582, 1, "\u0645\u062D"], [64583, 1, "\u0645\u062E"], [64584, 1, "\u0645\u0645"], [64585, 1, "\u0645\u0649"], [64586, 1, "\u0645\u064A"], [64587, 1, "\u0646\u062C"], [64588, 1, "\u0646\u062D"], [64589, 1, "\u0646\u062E"], [64590, 1, "\u0646\u0645"], [64591, 1, "\u0646\u0649"], [64592, 1, "\u0646\u064A"], [64593, 1, "\u0647\u062C"], [64594, 1, "\u0647\u0645"], [64595, 1, "\u0647\u0649"], [64596, 1, "\u0647\u064A"], [64597, 1, "\u064A\u062C"], [64598, 1, "\u064A\u062D"], [64599, 1, "\u064A\u062E"], [64600, 1, "\u064A\u0645"], [64601, 1, "\u064A\u0649"], [64602, 1, "\u064A\u064A"], [64603, 1, "\u0630\u0670"], [64604, 1, "\u0631\u0670"], [64605, 1, "\u0649\u0670"], [64606, 1, " \u064C\u0651"], [64607, 1, " \u064D\u0651"], [64608, 1, " \u064E\u0651"], [64609, 1, " \u064F\u0651"], [64610, 1, " \u0650\u0651"], [64611, 1, " \u0651\u0670"], [64612, 1, "\u0626\u0631"], [64613, 1, "\u0626\u0632"], [64614, 1, "\u0626\u0645"], [64615, 1, "\u0626\u0646"], [64616, 1, "\u0626\u0649"], [64617, 1, "\u0626\u064A"], [64618, 1, "\u0628\u0631"], [64619, 1, "\u0628\u0632"], [64620, 1, "\u0628\u0645"], [64621, 1, "\u0628\u0646"], [64622, 1, "\u0628\u0649"], [64623, 1, "\u0628\u064A"], [64624, 1, "\u062A\u0631"], [64625, 1, "\u062A\u0632"], [64626, 1, "\u062A\u0645"], [64627, 1, "\u062A\u0646"], [64628, 1, "\u062A\u0649"], [64629, 1, "\u062A\u064A"], [64630, 1, "\u062B\u0631"], [64631, 1, "\u062B\u0632"], [64632, 1, "\u062B\u0645"], [64633, 1, "\u062B\u0646"], [64634, 1, "\u062B\u0649"], [64635, 1, "\u062B\u064A"], [64636, 1, "\u0641\u0649"], [64637, 1, "\u0641\u064A"], [64638, 1, "\u0642\u0649"], [64639, 1, "\u0642\u064A"], [64640, 1, "\u0643\u0627"], [64641, 1, "\u0643\u0644"], [64642, 1, "\u0643\u0645"], [64643, 1, "\u0643\u0649"], [64644, 1, "\u0643\u064A"], [64645, 1, "\u0644\u0645"], [64646, 1, "\u0644\u0649"], [64647, 1, "\u0644\u064A"], [64648, 1, "\u0645\u0627"], [64649, 1, "\u0645\u0645"], [64650, 1, "\u0646\u0631"], [64651, 1, "\u0646\u0632"], [64652, 1, "\u0646\u0645"], [64653, 1, "\u0646\u0646"], [64654, 1, "\u0646\u0649"], [64655, 1, "\u0646\u064A"], [64656, 1, "\u0649\u0670"], [64657, 1, "\u064A\u0631"], [64658, 1, "\u064A\u0632"], [64659, 1, "\u064A\u0645"], [64660, 1, "\u064A\u0646"], [64661, 1, "\u064A\u0649"], [64662, 1, "\u064A\u064A"], [64663, 1, "\u0626\u062C"], [64664, 1, "\u0626\u062D"], [64665, 1, "\u0626\u062E"], [64666, 1, "\u0626\u0645"], [64667, 1, "\u0626\u0647"], [64668, 1, "\u0628\u062C"], [64669, 1, "\u0628\u062D"], [64670, 1, "\u0628\u062E"], [64671, 1, "\u0628\u0645"], [64672, 1, "\u0628\u0647"], [64673, 1, "\u062A\u062C"], [64674, 1, "\u062A\u062D"], [64675, 1, "\u062A\u062E"], [64676, 1, "\u062A\u0645"], [64677, 1, "\u062A\u0647"], [64678, 1, "\u062B\u0645"], [64679, 1, "\u062C\u062D"], [64680, 1, "\u062C\u0645"], [64681, 1, "\u062D\u062C"], [64682, 1, "\u062D\u0645"], [64683, 1, "\u062E\u062C"], [64684, 1, "\u062E\u0645"], [64685, 1, "\u0633\u062C"], [64686, 1, "\u0633\u062D"], [64687, 1, "\u0633\u062E"], [64688, 1, "\u0633\u0645"], [64689, 1, "\u0635\u062D"], [64690, 1, "\u0635\u062E"], [64691, 1, "\u0635\u0645"], [64692, 1, "\u0636\u062C"], [64693, 1, "\u0636\u062D"], [64694, 1, "\u0636\u062E"], [64695, 1, "\u0636\u0645"], [64696, 1, "\u0637\u062D"], [64697, 1, "\u0638\u0645"], [64698, 1, "\u0639\u062C"], [64699, 1, "\u0639\u0645"], [64700, 1, "\u063A\u062C"], [64701, 1, "\u063A\u0645"], [64702, 1, "\u0641\u062C"], [64703, 1, "\u0641\u062D"], [64704, 1, "\u0641\u062E"], [64705, 1, "\u0641\u0645"], [64706, 1, "\u0642\u062D"], [64707, 1, "\u0642\u0645"], [64708, 1, "\u0643\u062C"], [64709, 1, "\u0643\u062D"], [64710, 1, "\u0643\u062E"], [64711, 1, "\u0643\u0644"], [64712, 1, "\u0643\u0645"], [64713, 1, "\u0644\u062C"], [64714, 1, "\u0644\u062D"], [64715, 1, "\u0644\u062E"], [64716, 1, "\u0644\u0645"], [64717, 1, "\u0644\u0647"], [64718, 1, "\u0645\u062C"], [64719, 1, "\u0645\u062D"], [64720, 1, "\u0645\u062E"], [64721, 1, "\u0645\u0645"], [64722, 1, "\u0646\u062C"], [64723, 1, "\u0646\u062D"], [64724, 1, "\u0646\u062E"], [64725, 1, "\u0646\u0645"], [64726, 1, "\u0646\u0647"], [64727, 1, "\u0647\u062C"], [64728, 1, "\u0647\u0645"], [64729, 1, "\u0647\u0670"], [64730, 1, "\u064A\u062C"], [64731, 1, "\u064A\u062D"], [64732, 1, "\u064A\u062E"], [64733, 1, "\u064A\u0645"], [64734, 1, "\u064A\u0647"], [64735, 1, "\u0626\u0645"], [64736, 1, "\u0626\u0647"], [64737, 1, "\u0628\u0645"], [64738, 1, "\u0628\u0647"], [64739, 1, "\u062A\u0645"], [64740, 1, "\u062A\u0647"], [64741, 1, "\u062B\u0645"], [64742, 1, "\u062B\u0647"], [64743, 1, "\u0633\u0645"], [64744, 1, "\u0633\u0647"], [64745, 1, "\u0634\u0645"], [64746, 1, "\u0634\u0647"], [64747, 1, "\u0643\u0644"], [64748, 1, "\u0643\u0645"], [64749, 1, "\u0644\u0645"], [64750, 1, "\u0646\u0645"], [64751, 1, "\u0646\u0647"], [64752, 1, "\u064A\u0645"], [64753, 1, "\u064A\u0647"], [64754, 1, "\u0640\u064E\u0651"], [64755, 1, "\u0640\u064F\u0651"], [64756, 1, "\u0640\u0650\u0651"], [64757, 1, "\u0637\u0649"], [64758, 1, "\u0637\u064A"], [64759, 1, "\u0639\u0649"], [64760, 1, "\u0639\u064A"], [64761, 1, "\u063A\u0649"], [64762, 1, "\u063A\u064A"], [64763, 1, "\u0633\u0649"], [64764, 1, "\u0633\u064A"], [64765, 1, "\u0634\u0649"], [64766, 1, "\u0634\u064A"], [64767, 1, "\u062D\u0649"], [64768, 1, "\u062D\u064A"], [64769, 1, "\u062C\u0649"], [64770, 1, "\u062C\u064A"], [64771, 1, "\u062E\u0649"], [64772, 1, "\u062E\u064A"], [64773, 1, "\u0635\u0649"], [64774, 1, "\u0635\u064A"], [64775, 1, "\u0636\u0649"], [64776, 1, "\u0636\u064A"], [64777, 1, "\u0634\u062C"], [64778, 1, "\u0634\u062D"], [64779, 1, "\u0634\u062E"], [64780, 1, "\u0634\u0645"], [64781, 1, "\u0634\u0631"], [64782, 1, "\u0633\u0631"], [64783, 1, "\u0635\u0631"], [64784, 1, "\u0636\u0631"], [64785, 1, "\u0637\u0649"], [64786, 1, "\u0637\u064A"], [64787, 1, "\u0639\u0649"], [64788, 1, "\u0639\u064A"], [64789, 1, "\u063A\u0649"], [64790, 1, "\u063A\u064A"], [64791, 1, "\u0633\u0649"], [64792, 1, "\u0633\u064A"], [64793, 1, "\u0634\u0649"], [64794, 1, "\u0634\u064A"], [64795, 1, "\u062D\u0649"], [64796, 1, "\u062D\u064A"], [64797, 1, "\u062C\u0649"], [64798, 1, "\u062C\u064A"], [64799, 1, "\u062E\u0649"], [64800, 1, "\u062E\u064A"], [64801, 1, "\u0635\u0649"], [64802, 1, "\u0635\u064A"], [64803, 1, "\u0636\u0649"], [64804, 1, "\u0636\u064A"], [64805, 1, "\u0634\u062C"], [64806, 1, "\u0634\u062D"], [64807, 1, "\u0634\u062E"], [64808, 1, "\u0634\u0645"], [64809, 1, "\u0634\u0631"], [64810, 1, "\u0633\u0631"], [64811, 1, "\u0635\u0631"], [64812, 1, "\u0636\u0631"], [64813, 1, "\u0634\u062C"], [64814, 1, "\u0634\u062D"], [64815, 1, "\u0634\u062E"], [64816, 1, "\u0634\u0645"], [64817, 1, "\u0633\u0647"], [64818, 1, "\u0634\u0647"], [64819, 1, "\u0637\u0645"], [64820, 1, "\u0633\u062C"], [64821, 1, "\u0633\u062D"], [64822, 1, "\u0633\u062E"], [64823, 1, "\u0634\u062C"], [64824, 1, "\u0634\u062D"], [64825, 1, "\u0634\u062E"], [64826, 1, "\u0637\u0645"], [64827, 1, "\u0638\u0645"], [[64828, 64829], 1, "\u0627\u064B"], [[64830, 64831], 2], [[64832, 64847], 2], [64848, 1, "\u062A\u062C\u0645"], [[64849, 64850], 1, "\u062A\u062D\u062C"], [64851, 1, "\u062A\u062D\u0645"], [64852, 1, "\u062A\u062E\u0645"], [64853, 1, "\u062A\u0645\u062C"], [64854, 1, "\u062A\u0645\u062D"], [64855, 1, "\u062A\u0645\u062E"], [[64856, 64857], 1, "\u062C\u0645\u062D"], [64858, 1, "\u062D\u0645\u064A"], [64859, 1, "\u062D\u0645\u0649"], [64860, 1, "\u0633\u062D\u062C"], [64861, 1, "\u0633\u062C\u062D"], [64862, 1, "\u0633\u062C\u0649"], [[64863, 64864], 1, "\u0633\u0645\u062D"], [64865, 1, "\u0633\u0645\u062C"], [[64866, 64867], 1, "\u0633\u0645\u0645"], [[64868, 64869], 1, "\u0635\u062D\u062D"], [64870, 1, "\u0635\u0645\u0645"], [[64871, 64872], 1, "\u0634\u062D\u0645"], [64873, 1, "\u0634\u062C\u064A"], [[64874, 64875], 1, "\u0634\u0645\u062E"], [[64876, 64877], 1, "\u0634\u0645\u0645"], [64878, 1, "\u0636\u062D\u0649"], [[64879, 64880], 1, "\u0636\u062E\u0645"], [[64881, 64882], 1, "\u0637\u0645\u062D"], [64883, 1, "\u0637\u0645\u0645"], [64884, 1, "\u0637\u0645\u064A"], [64885, 1, "\u0639\u062C\u0645"], [[64886, 64887], 1, "\u0639\u0645\u0645"], [64888, 1, "\u0639\u0645\u0649"], [64889, 1, "\u063A\u0645\u0645"], [64890, 1, "\u063A\u0645\u064A"], [64891, 1, "\u063A\u0645\u0649"], [[64892, 64893], 1, "\u0641\u062E\u0645"], [64894, 1, "\u0642\u0645\u062D"], [64895, 1, "\u0642\u0645\u0645"], [64896, 1, "\u0644\u062D\u0645"], [64897, 1, "\u0644\u062D\u064A"], [64898, 1, "\u0644\u062D\u0649"], [[64899, 64900], 1, "\u0644\u062C\u062C"], [[64901, 64902], 1, "\u0644\u062E\u0645"], [[64903, 64904], 1, "\u0644\u0645\u062D"], [64905, 1, "\u0645\u062D\u062C"], [64906, 1, "\u0645\u062D\u0645"], [64907, 1, "\u0645\u062D\u064A"], [64908, 1, "\u0645\u062C\u062D"], [64909, 1, "\u0645\u062C\u0645"], [64910, 1, "\u0645\u062E\u062C"], [64911, 1, "\u0645\u062E\u0645"], [[64912, 64913], 3], [64914, 1, "\u0645\u062C\u062E"], [64915, 1, "\u0647\u0645\u062C"], [64916, 1, "\u0647\u0645\u0645"], [64917, 1, "\u0646\u062D\u0645"], [64918, 1, "\u0646\u062D\u0649"], [[64919, 64920], 1, "\u0646\u062C\u0645"], [64921, 1, "\u0646\u062C\u0649"], [64922, 1, "\u0646\u0645\u064A"], [64923, 1, "\u0646\u0645\u0649"], [[64924, 64925], 1, "\u064A\u0645\u0645"], [64926, 1, "\u0628\u062E\u064A"], [64927, 1, "\u062A\u062C\u064A"], [64928, 1, "\u062A\u062C\u0649"], [64929, 1, "\u062A\u062E\u064A"], [64930, 1, "\u062A\u062E\u0649"], [64931, 1, "\u062A\u0645\u064A"], [64932, 1, "\u062A\u0645\u0649"], [64933, 1, "\u062C\u0645\u064A"], [64934, 1, "\u062C\u062D\u0649"], [64935, 1, "\u062C\u0645\u0649"], [64936, 1, "\u0633\u062E\u0649"], [64937, 1, "\u0635\u062D\u064A"], [64938, 1, "\u0634\u062D\u064A"], [64939, 1, "\u0636\u062D\u064A"], [64940, 1, "\u0644\u062C\u064A"], [64941, 1, "\u0644\u0645\u064A"], [64942, 1, "\u064A\u062D\u064A"], [64943, 1, "\u064A\u062C\u064A"], [64944, 1, "\u064A\u0645\u064A"], [64945, 1, "\u0645\u0645\u064A"], [64946, 1, "\u0642\u0645\u064A"], [64947, 1, "\u0646\u062D\u064A"], [64948, 1, "\u0642\u0645\u062D"], [64949, 1, "\u0644\u062D\u0645"], [64950, 1, "\u0639\u0645\u064A"], [64951, 1, "\u0643\u0645\u064A"], [64952, 1, "\u0646\u062C\u062D"], [64953, 1, "\u0645\u062E\u064A"], [64954, 1, "\u0644\u062C\u0645"], [64955, 1, "\u0643\u0645\u0645"], [64956, 1, "\u0644\u062C\u0645"], [64957, 1, "\u0646\u062C\u062D"], [64958, 1, "\u062C\u062D\u064A"], [64959, 1, "\u062D\u062C\u064A"], [64960, 1, "\u0645\u062C\u064A"], [64961, 1, "\u0641\u0645\u064A"], [64962, 1, "\u0628\u062D\u064A"], [64963, 1, "\u0643\u0645\u0645"], [64964, 1, "\u0639\u062C\u0645"], [64965, 1, "\u0635\u0645\u0645"], [64966, 1, "\u0633\u062E\u064A"], [64967, 1, "\u0646\u062C\u064A"], [[64968, 64974], 3], [64975, 2], [[64976, 65007], 3], [65008, 1, "\u0635\u0644\u06D2"], [65009, 1, "\u0642\u0644\u06D2"], [65010, 1, "\u0627\u0644\u0644\u0647"], [65011, 1, "\u0627\u0643\u0628\u0631"], [65012, 1, "\u0645\u062D\u0645\u062F"], [65013, 1, "\u0635\u0644\u0639\u0645"], [65014, 1, "\u0631\u0633\u0648\u0644"], [65015, 1, "\u0639\u0644\u064A\u0647"], [65016, 1, "\u0648\u0633\u0644\u0645"], [65017, 1, "\u0635\u0644\u0649"], [65018, 1, "\u0635\u0644\u0649 \u0627\u0644\u0644\u0647 \u0639\u0644\u064A\u0647 \u0648\u0633\u0644\u0645"], [65019, 1, "\u062C\u0644 \u062C\u0644\u0627\u0644\u0647"], [65020, 1, "\u0631\u06CC\u0627\u0644"], [65021, 2], [[65022, 65023], 2], [[65024, 65039], 7], [65040, 1, ","], [65041, 1, "\u3001"], [65042, 3], [65043, 1, ":"], [65044, 1, ";"], [65045, 1, "!"], [65046, 1, "?"], [65047, 1, "\u3016"], [65048, 1, "\u3017"], [65049, 3], [[65050, 65055], 3], [[65056, 65059], 2], [[65060, 65062], 2], [[65063, 65069], 2], [[65070, 65071], 2], [65072, 3], [65073, 1, "\u2014"], [65074, 1, "\u2013"], [[65075, 65076], 1, "_"], [65077, 1, "("], [65078, 1, ")"], [65079, 1, "{"], [65080, 1, "}"], [65081, 1, "\u3014"], [65082, 1, "\u3015"], [65083, 1, "\u3010"], [65084, 1, "\u3011"], [65085, 1, "\u300A"], [65086, 1, "\u300B"], [65087, 1, "\u3008"], [65088, 1, "\u3009"], [65089, 1, "\u300C"], [65090, 1, "\u300D"], [65091, 1, "\u300E"], [65092, 1, "\u300F"], [[65093, 65094], 2], [65095, 1, "["], [65096, 1, "]"], [[65097, 65100], 1, " \u0305"], [[65101, 65103], 1, "_"], [65104, 1, ","], [65105, 1, "\u3001"], [65106, 3], [65107, 3], [65108, 1, ";"], [65109, 1, ":"], [65110, 1, "?"], [65111, 1, "!"], [65112, 1, "\u2014"], [65113, 1, "("], [65114, 1, ")"], [65115, 1, "{"], [65116, 1, "}"], [65117, 1, "\u3014"], [65118, 1, "\u3015"], [65119, 1, "#"], [65120, 1, "&"], [65121, 1, "*"], [65122, 1, "+"], [65123, 1, "-"], [65124, 1, "<"], [65125, 1, ">"], [65126, 1, "="], [65127, 3], [65128, 1, "\\"], [65129, 1, "$"], [65130, 1, "%"], [65131, 1, "@"], [[65132, 65135], 3], [65136, 1, " \u064B"], [65137, 1, "\u0640\u064B"], [65138, 1, " \u064C"], [65139, 2], [65140, 1, " \u064D"], [65141, 3], [65142, 1, " \u064E"], [65143, 1, "\u0640\u064E"], [65144, 1, " \u064F"], [65145, 1, "\u0640\u064F"], [65146, 1, " \u0650"], [65147, 1, "\u0640\u0650"], [65148, 1, " \u0651"], [65149, 1, "\u0640\u0651"], [65150, 1, " \u0652"], [65151, 1, "\u0640\u0652"], [65152, 1, "\u0621"], [[65153, 65154], 1, "\u0622"], [[65155, 65156], 1, "\u0623"], [[65157, 65158], 1, "\u0624"], [[65159, 65160], 1, "\u0625"], [[65161, 65164], 1, "\u0626"], [[65165, 65166], 1, "\u0627"], [[65167, 65170], 1, "\u0628"], [[65171, 65172], 1, "\u0629"], [[65173, 65176], 1, "\u062A"], [[65177, 65180], 1, "\u062B"], [[65181, 65184], 1, "\u062C"], [[65185, 65188], 1, "\u062D"], [[65189, 65192], 1, "\u062E"], [[65193, 65194], 1, "\u062F"], [[65195, 65196], 1, "\u0630"], [[65197, 65198], 1, "\u0631"], [[65199, 65200], 1, "\u0632"], [[65201, 65204], 1, "\u0633"], [[65205, 65208], 1, "\u0634"], [[65209, 65212], 1, "\u0635"], [[65213, 65216], 1, "\u0636"], [[65217, 65220], 1, "\u0637"], [[65221, 65224], 1, "\u0638"], [[65225, 65228], 1, "\u0639"], [[65229, 65232], 1, "\u063A"], [[65233, 65236], 1, "\u0641"], [[65237, 65240], 1, "\u0642"], [[65241, 65244], 1, "\u0643"], [[65245, 65248], 1, "\u0644"], [[65249, 65252], 1, "\u0645"], [[65253, 65256], 1, "\u0646"], [[65257, 65260], 1, "\u0647"], [[65261, 65262], 1, "\u0648"], [[65263, 65264], 1, "\u0649"], [[65265, 65268], 1, "\u064A"], [[65269, 65270], 1, "\u0644\u0622"], [[65271, 65272], 1, "\u0644\u0623"], [[65273, 65274], 1, "\u0644\u0625"], [[65275, 65276], 1, "\u0644\u0627"], [[65277, 65278], 3], [65279, 7], [65280, 3], [65281, 1, "!"], [65282, 1, '"'], [65283, 1, "#"], [65284, 1, "$"], [65285, 1, "%"], [65286, 1, "&"], [65287, 1, "'"], [65288, 1, "("], [65289, 1, ")"], [65290, 1, "*"], [65291, 1, "+"], [65292, 1, ","], [65293, 1, "-"], [65294, 1, "."], [65295, 1, "/"], [65296, 1, "0"], [65297, 1, "1"], [65298, 1, "2"], [65299, 1, "3"], [65300, 1, "4"], [65301, 1, "5"], [65302, 1, "6"], [65303, 1, "7"], [65304, 1, "8"], [65305, 1, "9"], [65306, 1, ":"], [65307, 1, ";"], [65308, 1, "<"], [65309, 1, "="], [65310, 1, ">"], [65311, 1, "?"], [65312, 1, "@"], [65313, 1, "a"], [65314, 1, "b"], [65315, 1, "c"], [65316, 1, "d"], [65317, 1, "e"], [65318, 1, "f"], [65319, 1, "g"], [65320, 1, "h"], [65321, 1, "i"], [65322, 1, "j"], [65323, 1, "k"], [65324, 1, "l"], [65325, 1, "m"], [65326, 1, "n"], [65327, 1, "o"], [65328, 1, "p"], [65329, 1, "q"], [65330, 1, "r"], [65331, 1, "s"], [65332, 1, "t"], [65333, 1, "u"], [65334, 1, "v"], [65335, 1, "w"], [65336, 1, "x"], [65337, 1, "y"], [65338, 1, "z"], [65339, 1, "["], [65340, 1, "\\"], [65341, 1, "]"], [65342, 1, "^"], [65343, 1, "_"], [65344, 1, "`"], [65345, 1, "a"], [65346, 1, "b"], [65347, 1, "c"], [65348, 1, "d"], [65349, 1, "e"], [65350, 1, "f"], [65351, 1, "g"], [65352, 1, "h"], [65353, 1, "i"], [65354, 1, "j"], [65355, 1, "k"], [65356, 1, "l"], [65357, 1, "m"], [65358, 1, "n"], [65359, 1, "o"], [65360, 1, "p"], [65361, 1, "q"], [65362, 1, "r"], [65363, 1, "s"], [65364, 1, "t"], [65365, 1, "u"], [65366, 1, "v"], [65367, 1, "w"], [65368, 1, "x"], [65369, 1, "y"], [65370, 1, "z"], [65371, 1, "{"], [65372, 1, "|"], [65373, 1, "}"], [65374, 1, "~"], [65375, 1, "\u2985"], [65376, 1, "\u2986"], [65377, 1, "."], [65378, 1, "\u300C"], [65379, 1, "\u300D"], [65380, 1, "\u3001"], [65381, 1, "\u30FB"], [65382, 1, "\u30F2"], [65383, 1, "\u30A1"], [65384, 1, "\u30A3"], [65385, 1, "\u30A5"], [65386, 1, "\u30A7"], [65387, 1, "\u30A9"], [65388, 1, "\u30E3"], [65389, 1, "\u30E5"], [65390, 1, "\u30E7"], [65391, 1, "\u30C3"], [65392, 1, "\u30FC"], [65393, 1, "\u30A2"], [65394, 1, "\u30A4"], [65395, 1, "\u30A6"], [65396, 1, "\u30A8"], [65397, 1, "\u30AA"], [65398, 1, "\u30AB"], [65399, 1, "\u30AD"], [65400, 1, "\u30AF"], [65401, 1, "\u30B1"], [65402, 1, "\u30B3"], [65403, 1, "\u30B5"], [65404, 1, "\u30B7"], [65405, 1, "\u30B9"], [65406, 1, "\u30BB"], [65407, 1, "\u30BD"], [65408, 1, "\u30BF"], [65409, 1, "\u30C1"], [65410, 1, "\u30C4"], [65411, 1, "\u30C6"], [65412, 1, "\u30C8"], [65413, 1, "\u30CA"], [65414, 1, "\u30CB"], [65415, 1, "\u30CC"], [65416, 1, "\u30CD"], [65417, 1, "\u30CE"], [65418, 1, "\u30CF"], [65419, 1, "\u30D2"], [65420, 1, "\u30D5"], [65421, 1, "\u30D8"], [65422, 1, "\u30DB"], [65423, 1, "\u30DE"], [65424, 1, "\u30DF"], [65425, 1, "\u30E0"], [65426, 1, "\u30E1"], [65427, 1, "\u30E2"], [65428, 1, "\u30E4"], [65429, 1, "\u30E6"], [65430, 1, "\u30E8"], [65431, 1, "\u30E9"], [65432, 1, "\u30EA"], [65433, 1, "\u30EB"], [65434, 1, "\u30EC"], [65435, 1, "\u30ED"], [65436, 1, "\u30EF"], [65437, 1, "\u30F3"], [65438, 1, "\u3099"], [65439, 1, "\u309A"], [65440, 7], [65441, 1, "\u1100"], [65442, 1, "\u1101"], [65443, 1, "\u11AA"], [65444, 1, "\u1102"], [65445, 1, "\u11AC"], [65446, 1, "\u11AD"], [65447, 1, "\u1103"], [65448, 1, "\u1104"], [65449, 1, "\u1105"], [65450, 1, "\u11B0"], [65451, 1, "\u11B1"], [65452, 1, "\u11B2"], [65453, 1, "\u11B3"], [65454, 1, "\u11B4"], [65455, 1, "\u11B5"], [65456, 1, "\u111A"], [65457, 1, "\u1106"], [65458, 1, "\u1107"], [65459, 1, "\u1108"], [65460, 1, "\u1121"], [65461, 1, "\u1109"], [65462, 1, "\u110A"], [65463, 1, "\u110B"], [65464, 1, "\u110C"], [65465, 1, "\u110D"], [65466, 1, "\u110E"], [65467, 1, "\u110F"], [65468, 1, "\u1110"], [65469, 1, "\u1111"], [65470, 1, "\u1112"], [[65471, 65473], 3], [65474, 1, "\u1161"], [65475, 1, "\u1162"], [65476, 1, "\u1163"], [65477, 1, "\u1164"], [65478, 1, "\u1165"], [65479, 1, "\u1166"], [[65480, 65481], 3], [65482, 1, "\u1167"], [65483, 1, "\u1168"], [65484, 1, "\u1169"], [65485, 1, "\u116A"], [65486, 1, "\u116B"], [65487, 1, "\u116C"], [[65488, 65489], 3], [65490, 1, "\u116D"], [65491, 1, "\u116E"], [65492, 1, "\u116F"], [65493, 1, "\u1170"], [65494, 1, "\u1171"], [65495, 1, "\u1172"], [[65496, 65497], 3], [65498, 1, "\u1173"], [65499, 1, "\u1174"], [65500, 1, "\u1175"], [[65501, 65503], 3], [65504, 1, "\xA2"], [65505, 1, "\xA3"], [65506, 1, "\xAC"], [65507, 1, " \u0304"], [65508, 1, "\xA6"], [65509, 1, "\xA5"], [65510, 1, "\u20A9"], [65511, 3], [65512, 1, "\u2502"], [65513, 1, "\u2190"], [65514, 1, "\u2191"], [65515, 1, "\u2192"], [65516, 1, "\u2193"], [65517, 1, "\u25A0"], [65518, 1, "\u25CB"], [[65519, 65528], 3], [[65529, 65531], 3], [65532, 3], [65533, 3], [[65534, 65535], 3], [[65536, 65547], 2], [65548, 3], [[65549, 65574], 2], [65575, 3], [[65576, 65594], 2], [65595, 3], [[65596, 65597], 2], [65598, 3], [[65599, 65613], 2], [[65614, 65615], 3], [[65616, 65629], 2], [[65630, 65663], 3], [[65664, 65786], 2], [[65787, 65791], 3], [[65792, 65794], 2], [[65795, 65798], 3], [[65799, 65843], 2], [[65844, 65846], 3], [[65847, 65855], 2], [[65856, 65930], 2], [[65931, 65932], 2], [[65933, 65934], 2], [65935, 3], [[65936, 65947], 2], [65948, 2], [[65949, 65951], 3], [65952, 2], [[65953, 65999], 3], [[66e3, 66044], 2], [66045, 2], [[66046, 66175], 3], [[66176, 66204], 2], [[66205, 66207], 3], [[66208, 66256], 2], [[66257, 66271], 3], [66272, 2], [[66273, 66299], 2], [[66300, 66303], 3], [[66304, 66334], 2], [66335, 2], [[66336, 66339], 2], [[66340, 66348], 3], [[66349, 66351], 2], [[66352, 66368], 2], [66369, 2], [[66370, 66377], 2], [66378, 2], [[66379, 66383], 3], [[66384, 66426], 2], [[66427, 66431], 3], [[66432, 66461], 2], [66462, 3], [66463, 2], [[66464, 66499], 2], [[66500, 66503], 3], [[66504, 66511], 2], [[66512, 66517], 2], [[66518, 66559], 3], [66560, 1, "\u{10428}"], [66561, 1, "\u{10429}"], [66562, 1, "\u{1042A}"], [66563, 1, "\u{1042B}"], [66564, 1, "\u{1042C}"], [66565, 1, "\u{1042D}"], [66566, 1, "\u{1042E}"], [66567, 1, "\u{1042F}"], [66568, 1, "\u{10430}"], [66569, 1, "\u{10431}"], [66570, 1, "\u{10432}"], [66571, 1, "\u{10433}"], [66572, 1, "\u{10434}"], [66573, 1, "\u{10435}"], [66574, 1, "\u{10436}"], [66575, 1, "\u{10437}"], [66576, 1, "\u{10438}"], [66577, 1, "\u{10439}"], [66578, 1, "\u{1043A}"], [66579, 1, "\u{1043B}"], [66580, 1, "\u{1043C}"], [66581, 1, "\u{1043D}"], [66582, 1, "\u{1043E}"], [66583, 1, "\u{1043F}"], [66584, 1, "\u{10440}"], [66585, 1, "\u{10441}"], [66586, 1, "\u{10442}"], [66587, 1, "\u{10443}"], [66588, 1, "\u{10444}"], [66589, 1, "\u{10445}"], [66590, 1, "\u{10446}"], [66591, 1, "\u{10447}"], [66592, 1, "\u{10448}"], [66593, 1, "\u{10449}"], [66594, 1, "\u{1044A}"], [66595, 1, "\u{1044B}"], [66596, 1, "\u{1044C}"], [66597, 1, "\u{1044D}"], [66598, 1, "\u{1044E}"], [66599, 1, "\u{1044F}"], [[66600, 66637], 2], [[66638, 66717], 2], [[66718, 66719], 3], [[66720, 66729], 2], [[66730, 66735], 3], [66736, 1, "\u{104D8}"], [66737, 1, "\u{104D9}"], [66738, 1, "\u{104DA}"], [66739, 1, "\u{104DB}"], [66740, 1, "\u{104DC}"], [66741, 1, "\u{104DD}"], [66742, 1, "\u{104DE}"], [66743, 1, "\u{104DF}"], [66744, 1, "\u{104E0}"], [66745, 1, "\u{104E1}"], [66746, 1, "\u{104E2}"], [66747, 1, "\u{104E3}"], [66748, 1, "\u{104E4}"], [66749, 1, "\u{104E5}"], [66750, 1, "\u{104E6}"], [66751, 1, "\u{104E7}"], [66752, 1, "\u{104E8}"], [66753, 1, "\u{104E9}"], [66754, 1, "\u{104EA}"], [66755, 1, "\u{104EB}"], [66756, 1, "\u{104EC}"], [66757, 1, "\u{104ED}"], [66758, 1, "\u{104EE}"], [66759, 1, "\u{104EF}"], [66760, 1, "\u{104F0}"], [66761, 1, "\u{104F1}"], [66762, 1, "\u{104F2}"], [66763, 1, "\u{104F3}"], [66764, 1, "\u{104F4}"], [66765, 1, "\u{104F5}"], [66766, 1, "\u{104F6}"], [66767, 1, "\u{104F7}"], [66768, 1, "\u{104F8}"], [66769, 1, "\u{104F9}"], [66770, 1, "\u{104FA}"], [66771, 1, "\u{104FB}"], [[66772, 66775], 3], [[66776, 66811], 2], [[66812, 66815], 3], [[66816, 66855], 2], [[66856, 66863], 3], [[66864, 66915], 2], [[66916, 66926], 3], [66927, 2], [66928, 1, "\u{10597}"], [66929, 1, "\u{10598}"], [66930, 1, "\u{10599}"], [66931, 1, "\u{1059A}"], [66932, 1, "\u{1059B}"], [66933, 1, "\u{1059C}"], [66934, 1, "\u{1059D}"], [66935, 1, "\u{1059E}"], [66936, 1, "\u{1059F}"], [66937, 1, "\u{105A0}"], [66938, 1, "\u{105A1}"], [66939, 3], [66940, 1, "\u{105A3}"], [66941, 1, "\u{105A4}"], [66942, 1, "\u{105A5}"], [66943, 1, "\u{105A6}"], [66944, 1, "\u{105A7}"], [66945, 1, "\u{105A8}"], [66946, 1, "\u{105A9}"], [66947, 1, "\u{105AA}"], [66948, 1, "\u{105AB}"], [66949, 1, "\u{105AC}"], [66950, 1, "\u{105AD}"], [66951, 1, "\u{105AE}"], [66952, 1, "\u{105AF}"], [66953, 1, "\u{105B0}"], [66954, 1, "\u{105B1}"], [66955, 3], [66956, 1, "\u{105B3}"], [66957, 1, "\u{105B4}"], [66958, 1, "\u{105B5}"], [66959, 1, "\u{105B6}"], [66960, 1, "\u{105B7}"], [66961, 1, "\u{105B8}"], [66962, 1, "\u{105B9}"], [66963, 3], [66964, 1, "\u{105BB}"], [66965, 1, "\u{105BC}"], [66966, 3], [[66967, 66977], 2], [66978, 3], [[66979, 66993], 2], [66994, 3], [[66995, 67001], 2], [67002, 3], [[67003, 67004], 2], [[67005, 67007], 3], [[67008, 67059], 2], [[67060, 67071], 3], [[67072, 67382], 2], [[67383, 67391], 3], [[67392, 67413], 2], [[67414, 67423], 3], [[67424, 67431], 2], [[67432, 67455], 3], [67456, 2], [67457, 1, "\u02D0"], [67458, 1, "\u02D1"], [67459, 1, "\xE6"], [67460, 1, "\u0299"], [67461, 1, "\u0253"], [67462, 3], [67463, 1, "\u02A3"], [67464, 1, "\uAB66"], [67465, 1, "\u02A5"], [67466, 1, "\u02A4"], [67467, 1, "\u0256"], [67468, 1, "\u0257"], [67469, 1, "\u1D91"], [67470, 1, "\u0258"], [67471, 1, "\u025E"], [67472, 1, "\u02A9"], [67473, 1, "\u0264"], [67474, 1, "\u0262"], [67475, 1, "\u0260"], [67476, 1, "\u029B"], [67477, 1, "\u0127"], [67478, 1, "\u029C"], [67479, 1, "\u0267"], [67480, 1, "\u0284"], [67481, 1, "\u02AA"], [67482, 1, "\u02AB"], [67483, 1, "\u026C"], [67484, 1, "\u{1DF04}"], [67485, 1, "\uA78E"], [67486, 1, "\u026E"], [67487, 1, "\u{1DF05}"], [67488, 1, "\u028E"], [67489, 1, "\u{1DF06}"], [67490, 1, "\xF8"], [67491, 1, "\u0276"], [67492, 1, "\u0277"], [67493, 1, "q"], [67494, 1, "\u027A"], [67495, 1, "\u{1DF08}"], [67496, 1, "\u027D"], [67497, 1, "\u027E"], [67498, 1, "\u0280"], [67499, 1, "\u02A8"], [67500, 1, "\u02A6"], [67501, 1, "\uAB67"], [67502, 1, "\u02A7"], [67503, 1, "\u0288"], [67504, 1, "\u2C71"], [67505, 3], [67506, 1, "\u028F"], [67507, 1, "\u02A1"], [67508, 1, "\u02A2"], [67509, 1, "\u0298"], [67510, 1, "\u01C0"], [67511, 1, "\u01C1"], [67512, 1, "\u01C2"], [67513, 1, "\u{1DF0A}"], [67514, 1, "\u{1DF1E}"], [[67515, 67583], 3], [[67584, 67589], 2], [[67590, 67591], 3], [67592, 2], [67593, 3], [[67594, 67637], 2], [67638, 3], [[67639, 67640], 2], [[67641, 67643], 3], [67644, 2], [[67645, 67646], 3], [67647, 2], [[67648, 67669], 2], [67670, 3], [[67671, 67679], 2], [[67680, 67702], 2], [[67703, 67711], 2], [[67712, 67742], 2], [[67743, 67750], 3], [[67751, 67759], 2], [[67760, 67807], 3], [[67808, 67826], 2], [67827, 3], [[67828, 67829], 2], [[67830, 67834], 3], [[67835, 67839], 2], [[67840, 67861], 2], [[67862, 67865], 2], [[67866, 67867], 2], [[67868, 67870], 3], [67871, 2], [[67872, 67897], 2], [[67898, 67902], 3], [67903, 2], [[67904, 67967], 3], [[67968, 68023], 2], [[68024, 68027], 3], [[68028, 68029], 2], [[68030, 68031], 2], [[68032, 68047], 2], [[68048, 68049], 3], [[68050, 68095], 2], [[68096, 68099], 2], [68100, 3], [[68101, 68102], 2], [[68103, 68107], 3], [[68108, 68115], 2], [68116, 3], [[68117, 68119], 2], [68120, 3], [[68121, 68147], 2], [[68148, 68149], 2], [[68150, 68151], 3], [[68152, 68154], 2], [[68155, 68158], 3], [68159, 2], [[68160, 68167], 2], [68168, 2], [[68169, 68175], 3], [[68176, 68184], 2], [[68185, 68191], 3], [[68192, 68220], 2], [[68221, 68223], 2], [[68224, 68252], 2], [[68253, 68255], 2], [[68256, 68287], 3], [[68288, 68295], 2], [68296, 2], [[68297, 68326], 2], [[68327, 68330], 3], [[68331, 68342], 2], [[68343, 68351], 3], [[68352, 68405], 2], [[68406, 68408], 3], [[68409, 68415], 2], [[68416, 68437], 2], [[68438, 68439], 3], [[68440, 68447], 2], [[68448, 68466], 2], [[68467, 68471], 3], [[68472, 68479], 2], [[68480, 68497], 2], [[68498, 68504], 3], [[68505, 68508], 2], [[68509, 68520], 3], [[68521, 68527], 2], [[68528, 68607], 3], [[68608, 68680], 2], [[68681, 68735], 3], [68736, 1, "\u{10CC0}"], [68737, 1, "\u{10CC1}"], [68738, 1, "\u{10CC2}"], [68739, 1, "\u{10CC3}"], [68740, 1, "\u{10CC4}"], [68741, 1, "\u{10CC5}"], [68742, 1, "\u{10CC6}"], [68743, 1, "\u{10CC7}"], [68744, 1, "\u{10CC8}"], [68745, 1, "\u{10CC9}"], [68746, 1, "\u{10CCA}"], [68747, 1, "\u{10CCB}"], [68748, 1, "\u{10CCC}"], [68749, 1, "\u{10CCD}"], [68750, 1, "\u{10CCE}"], [68751, 1, "\u{10CCF}"], [68752, 1, "\u{10CD0}"], [68753, 1, "\u{10CD1}"], [68754, 1, "\u{10CD2}"], [68755, 1, "\u{10CD3}"], [68756, 1, "\u{10CD4}"], [68757, 1, "\u{10CD5}"], [68758, 1, "\u{10CD6}"], [68759, 1, "\u{10CD7}"], [68760, 1, "\u{10CD8}"], [68761, 1, "\u{10CD9}"], [68762, 1, "\u{10CDA}"], [68763, 1, "\u{10CDB}"], [68764, 1, "\u{10CDC}"], [68765, 1, "\u{10CDD}"], [68766, 1, "\u{10CDE}"], [68767, 1, "\u{10CDF}"], [68768, 1, "\u{10CE0}"], [68769, 1, "\u{10CE1}"], [68770, 1, "\u{10CE2}"], [68771, 1, "\u{10CE3}"], [68772, 1, "\u{10CE4}"], [68773, 1, "\u{10CE5}"], [68774, 1, "\u{10CE6}"], [68775, 1, "\u{10CE7}"], [68776, 1, "\u{10CE8}"], [68777, 1, "\u{10CE9}"], [68778, 1, "\u{10CEA}"], [68779, 1, "\u{10CEB}"], [68780, 1, "\u{10CEC}"], [68781, 1, "\u{10CED}"], [68782, 1, "\u{10CEE}"], [68783, 1, "\u{10CEF}"], [68784, 1, "\u{10CF0}"], [68785, 1, "\u{10CF1}"], [68786, 1, "\u{10CF2}"], [[68787, 68799], 3], [[68800, 68850], 2], [[68851, 68857], 3], [[68858, 68863], 2], [[68864, 68903], 2], [[68904, 68911], 3], [[68912, 68921], 2], [[68922, 68927], 3], [[68928, 68943], 2], [68944, 1, "\u{10D70}"], [68945, 1, "\u{10D71}"], [68946, 1, "\u{10D72}"], [68947, 1, "\u{10D73}"], [68948, 1, "\u{10D74}"], [68949, 1, "\u{10D75}"], [68950, 1, "\u{10D76}"], [68951, 1, "\u{10D77}"], [68952, 1, "\u{10D78}"], [68953, 1, "\u{10D79}"], [68954, 1, "\u{10D7A}"], [68955, 1, "\u{10D7B}"], [68956, 1, "\u{10D7C}"], [68957, 1, "\u{10D7D}"], [68958, 1, "\u{10D7E}"], [68959, 1, "\u{10D7F}"], [68960, 1, "\u{10D80}"], [68961, 1, "\u{10D81}"], [68962, 1, "\u{10D82}"], [68963, 1, "\u{10D83}"], [68964, 1, "\u{10D84}"], [68965, 1, "\u{10D85}"], [[68966, 68968], 3], [[68969, 68973], 2], [68974, 2], [[68975, 68997], 2], [[68998, 69005], 3], [[69006, 69007], 2], [[69008, 69215], 3], [[69216, 69246], 2], [69247, 3], [[69248, 69289], 2], [69290, 3], [[69291, 69292], 2], [69293, 2], [[69294, 69295], 3], [[69296, 69297], 2], [[69298, 69313], 3], [[69314, 69316], 2], [[69317, 69371], 3], [69372, 2], [[69373, 69375], 2], [[69376, 69404], 2], [[69405, 69414], 2], [69415, 2], [[69416, 69423], 3], [[69424, 69456], 2], [[69457, 69465], 2], [[69466, 69487], 3], [[69488, 69509], 2], [[69510, 69513], 2], [[69514, 69551], 3], [[69552, 69572], 2], [[69573, 69579], 2], [[69580, 69599], 3], [[69600, 69622], 2], [[69623, 69631], 3], [[69632, 69702], 2], [[69703, 69709], 2], [[69710, 69713], 3], [[69714, 69733], 2], [[69734, 69743], 2], [[69744, 69749], 2], [[69750, 69758], 3], [69759, 2], [[69760, 69818], 2], [[69819, 69820], 2], [69821, 3], [[69822, 69825], 2], [69826, 2], [[69827, 69836], 3], [69837, 3], [[69838, 69839], 3], [[69840, 69864], 2], [[69865, 69871], 3], [[69872, 69881], 2], [[69882, 69887], 3], [[69888, 69940], 2], [69941, 3], [[69942, 69951], 2], [[69952, 69955], 2], [[69956, 69958], 2], [69959, 2], [[69960, 69967], 3], [[69968, 70003], 2], [[70004, 70005], 2], [70006, 2], [[70007, 70015], 3], [[70016, 70084], 2], [[70085, 70088], 2], [[70089, 70092], 2], [70093, 2], [[70094, 70095], 2], [[70096, 70105], 2], [70106, 2], [70107, 2], [70108, 2], [[70109, 70111], 2], [70112, 3], [[70113, 70132], 2], [[70133, 70143], 3], [[70144, 70161], 2], [70162, 3], [[70163, 70199], 2], [[70200, 70205], 2], [70206, 2], [[70207, 70209], 2], [[70210, 70271], 3], [[70272, 70278], 2], [70279, 3], [70280, 2], [70281, 3], [[70282, 70285], 2], [70286, 3], [[70287, 70301], 2], [70302, 3], [[70303, 70312], 2], [70313, 2], [[70314, 70319], 3], [[70320, 70378], 2], [[70379, 70383], 3], [[70384, 70393], 2], [[70394, 70399], 3], [70400, 2], [[70401, 70403], 2], [70404, 3], [[70405, 70412], 2], [[70413, 70414], 3], [[70415, 70416], 2], [[70417, 70418], 3], [[70419, 70440], 2], [70441, 3], [[70442, 70448], 2], [70449, 3], [[70450, 70451], 2], [70452, 3], [[70453, 70457], 2], [70458, 3], [70459, 2], [[70460, 70468], 2], [[70469, 70470], 3], [[70471, 70472], 2], [[70473, 70474], 3], [[70475, 70477], 2], [[70478, 70479], 3], [70480, 2], [[70481, 70486], 3], [70487, 2], [[70488, 70492], 3], [[70493, 70499], 2], [[70500, 70501], 3], [[70502, 70508], 2], [[70509, 70511], 3], [[70512, 70516], 2], [[70517, 70527], 3], [[70528, 70537], 2], [70538, 3], [70539, 2], [[70540, 70541], 3], [70542, 2], [70543, 3], [[70544, 70581], 2], [70582, 3], [[70583, 70592], 2], [70593, 3], [70594, 2], [[70595, 70596], 3], [70597, 2], [70598, 3], [[70599, 70602], 2], [70603, 3], [[70604, 70611], 2], [[70612, 70613], 2], [70614, 3], [[70615, 70616], 2], [[70617, 70624], 3], [[70625, 70626], 2], [[70627, 70655], 3], [[70656, 70730], 2], [[70731, 70735], 2], [[70736, 70745], 2], [70746, 2], [70747, 2], [70748, 3], [70749, 2], [70750, 2], [70751, 2], [[70752, 70753], 2], [[70754, 70783], 3], [[70784, 70853], 2], [70854, 2], [70855, 2], [[70856, 70863], 3], [[70864, 70873], 2], [[70874, 71039], 3], [[71040, 71093], 2], [[71094, 71095], 3], [[71096, 71104], 2], [[71105, 71113], 2], [[71114, 71127], 2], [[71128, 71133], 2], [[71134, 71167], 3], [[71168, 71232], 2], [[71233, 71235], 2], [71236, 2], [[71237, 71247], 3], [[71248, 71257], 2], [[71258, 71263], 3], [[71264, 71276], 2], [[71277, 71295], 3], [[71296, 71351], 2], [71352, 2], [71353, 2], [[71354, 71359], 3], [[71360, 71369], 2], [[71370, 71375], 3], [[71376, 71395], 2], [[71396, 71423], 3], [[71424, 71449], 2], [71450, 2], [[71451, 71452], 3], [[71453, 71467], 2], [[71468, 71471], 3], [[71472, 71481], 2], [[71482, 71487], 2], [[71488, 71494], 2], [[71495, 71679], 3], [[71680, 71738], 2], [71739, 2], [[71740, 71839], 3], [71840, 1, "\u{118C0}"], [71841, 1, "\u{118C1}"], [71842, 1, "\u{118C2}"], [71843, 1, "\u{118C3}"], [71844, 1, "\u{118C4}"], [71845, 1, "\u{118C5}"], [71846, 1, "\u{118C6}"], [71847, 1, "\u{118C7}"], [71848, 1, "\u{118C8}"], [71849, 1, "\u{118C9}"], [71850, 1, "\u{118CA}"], [71851, 1, "\u{118CB}"], [71852, 1, "\u{118CC}"], [71853, 1, "\u{118CD}"], [71854, 1, "\u{118CE}"], [71855, 1, "\u{118CF}"], [71856, 1, "\u{118D0}"], [71857, 1, "\u{118D1}"], [71858, 1, "\u{118D2}"], [71859, 1, "\u{118D3}"], [71860, 1, "\u{118D4}"], [71861, 1, "\u{118D5}"], [71862, 1, "\u{118D6}"], [71863, 1, "\u{118D7}"], [71864, 1, "\u{118D8}"], [71865, 1, "\u{118D9}"], [71866, 1, "\u{118DA}"], [71867, 1, "\u{118DB}"], [71868, 1, "\u{118DC}"], [71869, 1, "\u{118DD}"], [71870, 1, "\u{118DE}"], [71871, 1, "\u{118DF}"], [[71872, 71913], 2], [[71914, 71922], 2], [[71923, 71934], 3], [71935, 2], [[71936, 71942], 2], [[71943, 71944], 3], [71945, 2], [[71946, 71947], 3], [[71948, 71955], 2], [71956, 3], [[71957, 71958], 2], [71959, 3], [[71960, 71989], 2], [71990, 3], [[71991, 71992], 2], [[71993, 71994], 3], [[71995, 72003], 2], [[72004, 72006], 2], [[72007, 72015], 3], [[72016, 72025], 2], [[72026, 72095], 3], [[72096, 72103], 2], [[72104, 72105], 3], [[72106, 72151], 2], [[72152, 72153], 3], [[72154, 72161], 2], [72162, 2], [[72163, 72164], 2], [[72165, 72191], 3], [[72192, 72254], 2], [[72255, 72262], 2], [72263, 2], [[72264, 72271], 3], [[72272, 72323], 2], [[72324, 72325], 2], [[72326, 72345], 2], [[72346, 72348], 2], [72349, 2], [[72350, 72354], 2], [[72355, 72367], 3], [[72368, 72383], 2], [[72384, 72440], 2], [[72441, 72447], 3], [[72448, 72457], 2], [[72458, 72639], 3], [[72640, 72672], 2], [72673, 2], [[72674, 72687], 3], [[72688, 72697], 2], [[72698, 72703], 3], [[72704, 72712], 2], [72713, 3], [[72714, 72758], 2], [72759, 3], [[72760, 72768], 2], [[72769, 72773], 2], [[72774, 72783], 3], [[72784, 72793], 2], [[72794, 72812], 2], [[72813, 72815], 3], [[72816, 72817], 2], [[72818, 72847], 2], [[72848, 72849], 3], [[72850, 72871], 2], [72872, 3], [[72873, 72886], 2], [[72887, 72959], 3], [[72960, 72966], 2], [72967, 3], [[72968, 72969], 2], [72970, 3], [[72971, 73014], 2], [[73015, 73017], 3], [73018, 2], [73019, 3], [[73020, 73021], 2], [73022, 3], [[73023, 73031], 2], [[73032, 73039], 3], [[73040, 73049], 2], [[73050, 73055], 3], [[73056, 73061], 2], [73062, 3], [[73063, 73064], 2], [73065, 3], [[73066, 73102], 2], [73103, 3], [[73104, 73105], 2], [73106, 3], [[73107, 73112], 2], [[73113, 73119], 3], [[73120, 73129], 2], [[73130, 73439], 3], [[73440, 73462], 2], [[73463, 73464], 2], [[73465, 73471], 3], [[73472, 73488], 2], [73489, 3], [[73490, 73530], 2], [[73531, 73533], 3], [[73534, 73538], 2], [[73539, 73551], 2], [[73552, 73561], 2], [73562, 2], [[73563, 73647], 3], [73648, 2], [[73649, 73663], 3], [[73664, 73713], 2], [[73714, 73726], 3], [73727, 2], [[73728, 74606], 2], [[74607, 74648], 2], [74649, 2], [[74650, 74751], 3], [[74752, 74850], 2], [[74851, 74862], 2], [74863, 3], [[74864, 74867], 2], [74868, 2], [[74869, 74879], 3], [[74880, 75075], 2], [[75076, 77711], 3], [[77712, 77808], 2], [[77809, 77810], 2], [[77811, 77823], 3], [[77824, 78894], 2], [78895, 2], [[78896, 78904], 3], [[78905, 78911], 3], [[78912, 78933], 2], [[78934, 78943], 3], [[78944, 82938], 2], [[82939, 82943], 3], [[82944, 83526], 2], [[83527, 90367], 3], [[90368, 90425], 2], [[90426, 92159], 3], [[92160, 92728], 2], [[92729, 92735], 3], [[92736, 92766], 2], [92767, 3], [[92768, 92777], 2], [[92778, 92781], 3], [[92782, 92783], 2], [[92784, 92862], 2], [92863, 3], [[92864, 92873], 2], [[92874, 92879], 3], [[92880, 92909], 2], [[92910, 92911], 3], [[92912, 92916], 2], [92917, 2], [[92918, 92927], 3], [[92928, 92982], 2], [[92983, 92991], 2], [[92992, 92995], 2], [[92996, 92997], 2], [[92998, 93007], 3], [[93008, 93017], 2], [93018, 3], [[93019, 93025], 2], [93026, 3], [[93027, 93047], 2], [[93048, 93052], 3], [[93053, 93071], 2], [[93072, 93503], 3], [[93504, 93548], 2], [[93549, 93551], 2], [[93552, 93561], 2], [[93562, 93759], 3], [93760, 1, "\u{16E60}"], [93761, 1, "\u{16E61}"], [93762, 1, "\u{16E62}"], [93763, 1, "\u{16E63}"], [93764, 1, "\u{16E64}"], [93765, 1, "\u{16E65}"], [93766, 1, "\u{16E66}"], [93767, 1, "\u{16E67}"], [93768, 1, "\u{16E68}"], [93769, 1, "\u{16E69}"], [93770, 1, "\u{16E6A}"], [93771, 1, "\u{16E6B}"], [93772, 1, "\u{16E6C}"], [93773, 1, "\u{16E6D}"], [93774, 1, "\u{16E6E}"], [93775, 1, "\u{16E6F}"], [93776, 1, "\u{16E70}"], [93777, 1, "\u{16E71}"], [93778, 1, "\u{16E72}"], [93779, 1, "\u{16E73}"], [93780, 1, "\u{16E74}"], [93781, 1, "\u{16E75}"], [93782, 1, "\u{16E76}"], [93783, 1, "\u{16E77}"], [93784, 1, "\u{16E78}"], [93785, 1, "\u{16E79}"], [93786, 1, "\u{16E7A}"], [93787, 1, "\u{16E7B}"], [93788, 1, "\u{16E7C}"], [93789, 1, "\u{16E7D}"], [93790, 1, "\u{16E7E}"], [93791, 1, "\u{16E7F}"], [[93792, 93823], 2], [[93824, 93850], 2], [[93851, 93951], 3], [[93952, 94020], 2], [[94021, 94026], 2], [[94027, 94030], 3], [94031, 2], [[94032, 94078], 2], [[94079, 94087], 2], [[94088, 94094], 3], [[94095, 94111], 2], [[94112, 94175], 3], [94176, 2], [94177, 2], [94178, 2], [94179, 2], [94180, 2], [[94181, 94191], 3], [[94192, 94193], 2], [[94194, 94207], 3], [[94208, 100332], 2], [[100333, 100337], 2], [[100338, 100343], 2], [[100344, 100351], 3], [[100352, 101106], 2], [[101107, 101589], 2], [[101590, 101630], 3], [101631, 2], [[101632, 101640], 2], [[101641, 110575], 3], [[110576, 110579], 2], [110580, 3], [[110581, 110587], 2], [110588, 3], [[110589, 110590], 2], [110591, 3], [[110592, 110593], 2], [[110594, 110878], 2], [[110879, 110882], 2], [[110883, 110897], 3], [110898, 2], [[110899, 110927], 3], [[110928, 110930], 2], [[110931, 110932], 3], [110933, 2], [[110934, 110947], 3], [[110948, 110951], 2], [[110952, 110959], 3], [[110960, 111355], 2], [[111356, 113663], 3], [[113664, 113770], 2], [[113771, 113775], 3], [[113776, 113788], 2], [[113789, 113791], 3], [[113792, 113800], 2], [[113801, 113807], 3], [[113808, 113817], 2], [[113818, 113819], 3], [113820, 2], [[113821, 113822], 2], [113823, 2], [[113824, 113827], 7], [[113828, 117759], 3], [[117760, 117973], 2], [117974, 1, "a"], [117975, 1, "b"], [117976, 1, "c"], [117977, 1, "d"], [117978, 1, "e"], [117979, 1, "f"], [117980, 1, "g"], [117981, 1, "h"], [117982, 1, "i"], [117983, 1, "j"], [117984, 1, "k"], [117985, 1, "l"], [117986, 1, "m"], [117987, 1, "n"], [117988, 1, "o"], [117989, 1, "p"], [117990, 1, "q"], [117991, 1, "r"], [117992, 1, "s"], [117993, 1, "t"], [117994, 1, "u"], [117995, 1, "v"], [117996, 1, "w"], [117997, 1, "x"], [117998, 1, "y"], [117999, 1, "z"], [118e3, 1, "0"], [118001, 1, "1"], [118002, 1, "2"], [118003, 1, "3"], [118004, 1, "4"], [118005, 1, "5"], [118006, 1, "6"], [118007, 1, "7"], [118008, 1, "8"], [118009, 1, "9"], [[118010, 118015], 3], [[118016, 118451], 2], [[118452, 118527], 3], [[118528, 118573], 2], [[118574, 118575], 3], [[118576, 118598], 2], [[118599, 118607], 3], [[118608, 118723], 2], [[118724, 118783], 3], [[118784, 119029], 2], [[119030, 119039], 3], [[119040, 119078], 2], [[119079, 119080], 3], [119081, 2], [[119082, 119133], 2], [119134, 1, "\u{1D157}\u{1D165}"], [119135, 1, "\u{1D158}\u{1D165}"], [119136, 1, "\u{1D158}\u{1D165}\u{1D16E}"], [119137, 1, "\u{1D158}\u{1D165}\u{1D16F}"], [119138, 1, "\u{1D158}\u{1D165}\u{1D170}"], [119139, 1, "\u{1D158}\u{1D165}\u{1D171}"], [119140, 1, "\u{1D158}\u{1D165}\u{1D172}"], [[119141, 119154], 2], [[119155, 119162], 7], [[119163, 119226], 2], [119227, 1, "\u{1D1B9}\u{1D165}"], [119228, 1, "\u{1D1BA}\u{1D165}"], [119229, 1, "\u{1D1B9}\u{1D165}\u{1D16E}"], [119230, 1, "\u{1D1BA}\u{1D165}\u{1D16E}"], [119231, 1, "\u{1D1B9}\u{1D165}\u{1D16F}"], [119232, 1, "\u{1D1BA}\u{1D165}\u{1D16F}"], [[119233, 119261], 2], [[119262, 119272], 2], [[119273, 119274], 2], [[119275, 119295], 3], [[119296, 119365], 2], [[119366, 119487], 3], [[119488, 119507], 2], [[119508, 119519], 3], [[119520, 119539], 2], [[119540, 119551], 3], [[119552, 119638], 2], [[119639, 119647], 3], [[119648, 119665], 2], [[119666, 119672], 2], [[119673, 119807], 3], [119808, 1, "a"], [119809, 1, "b"], [119810, 1, "c"], [119811, 1, "d"], [119812, 1, "e"], [119813, 1, "f"], [119814, 1, "g"], [119815, 1, "h"], [119816, 1, "i"], [119817, 1, "j"], [119818, 1, "k"], [119819, 1, "l"], [119820, 1, "m"], [119821, 1, "n"], [119822, 1, "o"], [119823, 1, "p"], [119824, 1, "q"], [119825, 1, "r"], [119826, 1, "s"], [119827, 1, "t"], [119828, 1, "u"], [119829, 1, "v"], [119830, 1, "w"], [119831, 1, "x"], [119832, 1, "y"], [119833, 1, "z"], [119834, 1, "a"], [119835, 1, "b"], [119836, 1, "c"], [119837, 1, "d"], [119838, 1, "e"], [119839, 1, "f"], [119840, 1, "g"], [119841, 1, "h"], [119842, 1, "i"], [119843, 1, "j"], [119844, 1, "k"], [119845, 1, "l"], [119846, 1, "m"], [119847, 1, "n"], [119848, 1, "o"], [119849, 1, "p"], [119850, 1, "q"], [119851, 1, "r"], [119852, 1, "s"], [119853, 1, "t"], [119854, 1, "u"], [119855, 1, "v"], [119856, 1, "w"], [119857, 1, "x"], [119858, 1, "y"], [119859, 1, "z"], [119860, 1, "a"], [119861, 1, "b"], [119862, 1, "c"], [119863, 1, "d"], [119864, 1, "e"], [119865, 1, "f"], [119866, 1, "g"], [119867, 1, "h"], [119868, 1, "i"], [119869, 1, "j"], [119870, 1, "k"], [119871, 1, "l"], [119872, 1, "m"], [119873, 1, "n"], [119874, 1, "o"], [119875, 1, "p"], [119876, 1, "q"], [119877, 1, "r"], [119878, 1, "s"], [119879, 1, "t"], [119880, 1, "u"], [119881, 1, "v"], [119882, 1, "w"], [119883, 1, "x"], [119884, 1, "y"], [119885, 1, "z"], [119886, 1, "a"], [119887, 1, "b"], [119888, 1, "c"], [119889, 1, "d"], [119890, 1, "e"], [119891, 1, "f"], [119892, 1, "g"], [119893, 3], [119894, 1, "i"], [119895, 1, "j"], [119896, 1, "k"], [119897, 1, "l"], [119898, 1, "m"], [119899, 1, "n"], [119900, 1, "o"], [119901, 1, "p"], [119902, 1, "q"], [119903, 1, "r"], [119904, 1, "s"], [119905, 1, "t"], [119906, 1, "u"], [119907, 1, "v"], [119908, 1, "w"], [119909, 1, "x"], [119910, 1, "y"], [119911, 1, "z"], [119912, 1, "a"], [119913, 1, "b"], [119914, 1, "c"], [119915, 1, "d"], [119916, 1, "e"], [119917, 1, "f"], [119918, 1, "g"], [119919, 1, "h"], [119920, 1, "i"], [119921, 1, "j"], [119922, 1, "k"], [119923, 1, "l"], [119924, 1, "m"], [119925, 1, "n"], [119926, 1, "o"], [119927, 1, "p"], [119928, 1, "q"], [119929, 1, "r"], [119930, 1, "s"], [119931, 1, "t"], [119932, 1, "u"], [119933, 1, "v"], [119934, 1, "w"], [119935, 1, "x"], [119936, 1, "y"], [119937, 1, "z"], [119938, 1, "a"], [119939, 1, "b"], [119940, 1, "c"], [119941, 1, "d"], [119942, 1, "e"], [119943, 1, "f"], [119944, 1, "g"], [119945, 1, "h"], [119946, 1, "i"], [119947, 1, "j"], [119948, 1, "k"], [119949, 1, "l"], [119950, 1, "m"], [119951, 1, "n"], [119952, 1, "o"], [119953, 1, "p"], [119954, 1, "q"], [119955, 1, "r"], [119956, 1, "s"], [119957, 1, "t"], [119958, 1, "u"], [119959, 1, "v"], [119960, 1, "w"], [119961, 1, "x"], [119962, 1, "y"], [119963, 1, "z"], [119964, 1, "a"], [119965, 3], [119966, 1, "c"], [119967, 1, "d"], [[119968, 119969], 3], [119970, 1, "g"], [[119971, 119972], 3], [119973, 1, "j"], [119974, 1, "k"], [[119975, 119976], 3], [119977, 1, "n"], [119978, 1, "o"], [119979, 1, "p"], [119980, 1, "q"], [119981, 3], [119982, 1, "s"], [119983, 1, "t"], [119984, 1, "u"], [119985, 1, "v"], [119986, 1, "w"], [119987, 1, "x"], [119988, 1, "y"], [119989, 1, "z"], [119990, 1, "a"], [119991, 1, "b"], [119992, 1, "c"], [119993, 1, "d"], [119994, 3], [119995, 1, "f"], [119996, 3], [119997, 1, "h"], [119998, 1, "i"], [119999, 1, "j"], [12e4, 1, "k"], [120001, 1, "l"], [120002, 1, "m"], [120003, 1, "n"], [120004, 3], [120005, 1, "p"], [120006, 1, "q"], [120007, 1, "r"], [120008, 1, "s"], [120009, 1, "t"], [120010, 1, "u"], [120011, 1, "v"], [120012, 1, "w"], [120013, 1, "x"], [120014, 1, "y"], [120015, 1, "z"], [120016, 1, "a"], [120017, 1, "b"], [120018, 1, "c"], [120019, 1, "d"], [120020, 1, "e"], [120021, 1, "f"], [120022, 1, "g"], [120023, 1, "h"], [120024, 1, "i"], [120025, 1, "j"], [120026, 1, "k"], [120027, 1, "l"], [120028, 1, "m"], [120029, 1, "n"], [120030, 1, "o"], [120031, 1, "p"], [120032, 1, "q"], [120033, 1, "r"], [120034, 1, "s"], [120035, 1, "t"], [120036, 1, "u"], [120037, 1, "v"], [120038, 1, "w"], [120039, 1, "x"], [120040, 1, "y"], [120041, 1, "z"], [120042, 1, "a"], [120043, 1, "b"], [120044, 1, "c"], [120045, 1, "d"], [120046, 1, "e"], [120047, 1, "f"], [120048, 1, "g"], [120049, 1, "h"], [120050, 1, "i"], [120051, 1, "j"], [120052, 1, "k"], [120053, 1, "l"], [120054, 1, "m"], [120055, 1, "n"], [120056, 1, "o"], [120057, 1, "p"], [120058, 1, "q"], [120059, 1, "r"], [120060, 1, "s"], [120061, 1, "t"], [120062, 1, "u"], [120063, 1, "v"], [120064, 1, "w"], [120065, 1, "x"], [120066, 1, "y"], [120067, 1, "z"], [120068, 1, "a"], [120069, 1, "b"], [120070, 3], [120071, 1, "d"], [120072, 1, "e"], [120073, 1, "f"], [120074, 1, "g"], [[120075, 120076], 3], [120077, 1, "j"], [120078, 1, "k"], [120079, 1, "l"], [120080, 1, "m"], [120081, 1, "n"], [120082, 1, "o"], [120083, 1, "p"], [120084, 1, "q"], [120085, 3], [120086, 1, "s"], [120087, 1, "t"], [120088, 1, "u"], [120089, 1, "v"], [120090, 1, "w"], [120091, 1, "x"], [120092, 1, "y"], [120093, 3], [120094, 1, "a"], [120095, 1, "b"], [120096, 1, "c"], [120097, 1, "d"], [120098, 1, "e"], [120099, 1, "f"], [120100, 1, "g"], [120101, 1, "h"], [120102, 1, "i"], [120103, 1, "j"], [120104, 1, "k"], [120105, 1, "l"], [120106, 1, "m"], [120107, 1, "n"], [120108, 1, "o"], [120109, 1, "p"], [120110, 1, "q"], [120111, 1, "r"], [120112, 1, "s"], [120113, 1, "t"], [120114, 1, "u"], [120115, 1, "v"], [120116, 1, "w"], [120117, 1, "x"], [120118, 1, "y"], [120119, 1, "z"], [120120, 1, "a"], [120121, 1, "b"], [120122, 3], [120123, 1, "d"], [120124, 1, "e"], [120125, 1, "f"], [120126, 1, "g"], [120127, 3], [120128, 1, "i"], [120129, 1, "j"], [120130, 1, "k"], [120131, 1, "l"], [120132, 1, "m"], [120133, 3], [120134, 1, "o"], [[120135, 120137], 3], [120138, 1, "s"], [120139, 1, "t"], [120140, 1, "u"], [120141, 1, "v"], [120142, 1, "w"], [120143, 1, "x"], [120144, 1, "y"], [120145, 3], [120146, 1, "a"], [120147, 1, "b"], [120148, 1, "c"], [120149, 1, "d"], [120150, 1, "e"], [120151, 1, "f"], [120152, 1, "g"], [120153, 1, "h"], [120154, 1, "i"], [120155, 1, "j"], [120156, 1, "k"], [120157, 1, "l"], [120158, 1, "m"], [120159, 1, "n"], [120160, 1, "o"], [120161, 1, "p"], [120162, 1, "q"], [120163, 1, "r"], [120164, 1, "s"], [120165, 1, "t"], [120166, 1, "u"], [120167, 1, "v"], [120168, 1, "w"], [120169, 1, "x"], [120170, 1, "y"], [120171, 1, "z"], [120172, 1, "a"], [120173, 1, "b"], [120174, 1, "c"], [120175, 1, "d"], [120176, 1, "e"], [120177, 1, "f"], [120178, 1, "g"], [120179, 1, "h"], [120180, 1, "i"], [120181, 1, "j"], [120182, 1, "k"], [120183, 1, "l"], [120184, 1, "m"], [120185, 1, "n"], [120186, 1, "o"], [120187, 1, "p"], [120188, 1, "q"], [120189, 1, "r"], [120190, 1, "s"], [120191, 1, "t"], [120192, 1, "u"], [120193, 1, "v"], [120194, 1, "w"], [120195, 1, "x"], [120196, 1, "y"], [120197, 1, "z"], [120198, 1, "a"], [120199, 1, "b"], [120200, 1, "c"], [120201, 1, "d"], [120202, 1, "e"], [120203, 1, "f"], [120204, 1, "g"], [120205, 1, "h"], [120206, 1, "i"], [120207, 1, "j"], [120208, 1, "k"], [120209, 1, "l"], [120210, 1, "m"], [120211, 1, "n"], [120212, 1, "o"], [120213, 1, "p"], [120214, 1, "q"], [120215, 1, "r"], [120216, 1, "s"], [120217, 1, "t"], [120218, 1, "u"], [120219, 1, "v"], [120220, 1, "w"], [120221, 1, "x"], [120222, 1, "y"], [120223, 1, "z"], [120224, 1, "a"], [120225, 1, "b"], [120226, 1, "c"], [120227, 1, "d"], [120228, 1, "e"], [120229, 1, "f"], [120230, 1, "g"], [120231, 1, "h"], [120232, 1, "i"], [120233, 1, "j"], [120234, 1, "k"], [120235, 1, "l"], [120236, 1, "m"], [120237, 1, "n"], [120238, 1, "o"], [120239, 1, "p"], [120240, 1, "q"], [120241, 1, "r"], [120242, 1, "s"], [120243, 1, "t"], [120244, 1, "u"], [120245, 1, "v"], [120246, 1, "w"], [120247, 1, "x"], [120248, 1, "y"], [120249, 1, "z"], [120250, 1, "a"], [120251, 1, "b"], [120252, 1, "c"], [120253, 1, "d"], [120254, 1, "e"], [120255, 1, "f"], [120256, 1, "g"], [120257, 1, "h"], [120258, 1, "i"], [120259, 1, "j"], [120260, 1, "k"], [120261, 1, "l"], [120262, 1, "m"], [120263, 1, "n"], [120264, 1, "o"], [120265, 1, "p"], [120266, 1, "q"], [120267, 1, "r"], [120268, 1, "s"], [120269, 1, "t"], [120270, 1, "u"], [120271, 1, "v"], [120272, 1, "w"], [120273, 1, "x"], [120274, 1, "y"], [120275, 1, "z"], [120276, 1, "a"], [120277, 1, "b"], [120278, 1, "c"], [120279, 1, "d"], [120280, 1, "e"], [120281, 1, "f"], [120282, 1, "g"], [120283, 1, "h"], [120284, 1, "i"], [120285, 1, "j"], [120286, 1, "k"], [120287, 1, "l"], [120288, 1, "m"], [120289, 1, "n"], [120290, 1, "o"], [120291, 1, "p"], [120292, 1, "q"], [120293, 1, "r"], [120294, 1, "s"], [120295, 1, "t"], [120296, 1, "u"], [120297, 1, "v"], [120298, 1, "w"], [120299, 1, "x"], [120300, 1, "y"], [120301, 1, "z"], [120302, 1, "a"], [120303, 1, "b"], [120304, 1, "c"], [120305, 1, "d"], [120306, 1, "e"], [120307, 1, "f"], [120308, 1, "g"], [120309, 1, "h"], [120310, 1, "i"], [120311, 1, "j"], [120312, 1, "k"], [120313, 1, "l"], [120314, 1, "m"], [120315, 1, "n"], [120316, 1, "o"], [120317, 1, "p"], [120318, 1, "q"], [120319, 1, "r"], [120320, 1, "s"], [120321, 1, "t"], [120322, 1, "u"], [120323, 1, "v"], [120324, 1, "w"], [120325, 1, "x"], [120326, 1, "y"], [120327, 1, "z"], [120328, 1, "a"], [120329, 1, "b"], [120330, 1, "c"], [120331, 1, "d"], [120332, 1, "e"], [120333, 1, "f"], [120334, 1, "g"], [120335, 1, "h"], [120336, 1, "i"], [120337, 1, "j"], [120338, 1, "k"], [120339, 1, "l"], [120340, 1, "m"], [120341, 1, "n"], [120342, 1, "o"], [120343, 1, "p"], [120344, 1, "q"], [120345, 1, "r"], [120346, 1, "s"], [120347, 1, "t"], [120348, 1, "u"], [120349, 1, "v"], [120350, 1, "w"], [120351, 1, "x"], [120352, 1, "y"], [120353, 1, "z"], [120354, 1, "a"], [120355, 1, "b"], [120356, 1, "c"], [120357, 1, "d"], [120358, 1, "e"], [120359, 1, "f"], [120360, 1, "g"], [120361, 1, "h"], [120362, 1, "i"], [120363, 1, "j"], [120364, 1, "k"], [120365, 1, "l"], [120366, 1, "m"], [120367, 1, "n"], [120368, 1, "o"], [120369, 1, "p"], [120370, 1, "q"], [120371, 1, "r"], [120372, 1, "s"], [120373, 1, "t"], [120374, 1, "u"], [120375, 1, "v"], [120376, 1, "w"], [120377, 1, "x"], [120378, 1, "y"], [120379, 1, "z"], [120380, 1, "a"], [120381, 1, "b"], [120382, 1, "c"], [120383, 1, "d"], [120384, 1, "e"], [120385, 1, "f"], [120386, 1, "g"], [120387, 1, "h"], [120388, 1, "i"], [120389, 1, "j"], [120390, 1, "k"], [120391, 1, "l"], [120392, 1, "m"], [120393, 1, "n"], [120394, 1, "o"], [120395, 1, "p"], [120396, 1, "q"], [120397, 1, "r"], [120398, 1, "s"], [120399, 1, "t"], [120400, 1, "u"], [120401, 1, "v"], [120402, 1, "w"], [120403, 1, "x"], [120404, 1, "y"], [120405, 1, "z"], [120406, 1, "a"], [120407, 1, "b"], [120408, 1, "c"], [120409, 1, "d"], [120410, 1, "e"], [120411, 1, "f"], [120412, 1, "g"], [120413, 1, "h"], [120414, 1, "i"], [120415, 1, "j"], [120416, 1, "k"], [120417, 1, "l"], [120418, 1, "m"], [120419, 1, "n"], [120420, 1, "o"], [120421, 1, "p"], [120422, 1, "q"], [120423, 1, "r"], [120424, 1, "s"], [120425, 1, "t"], [120426, 1, "u"], [120427, 1, "v"], [120428, 1, "w"], [120429, 1, "x"], [120430, 1, "y"], [120431, 1, "z"], [120432, 1, "a"], [120433, 1, "b"], [120434, 1, "c"], [120435, 1, "d"], [120436, 1, "e"], [120437, 1, "f"], [120438, 1, "g"], [120439, 1, "h"], [120440, 1, "i"], [120441, 1, "j"], [120442, 1, "k"], [120443, 1, "l"], [120444, 1, "m"], [120445, 1, "n"], [120446, 1, "o"], [120447, 1, "p"], [120448, 1, "q"], [120449, 1, "r"], [120450, 1, "s"], [120451, 1, "t"], [120452, 1, "u"], [120453, 1, "v"], [120454, 1, "w"], [120455, 1, "x"], [120456, 1, "y"], [120457, 1, "z"], [120458, 1, "a"], [120459, 1, "b"], [120460, 1, "c"], [120461, 1, "d"], [120462, 1, "e"], [120463, 1, "f"], [120464, 1, "g"], [120465, 1, "h"], [120466, 1, "i"], [120467, 1, "j"], [120468, 1, "k"], [120469, 1, "l"], [120470, 1, "m"], [120471, 1, "n"], [120472, 1, "o"], [120473, 1, "p"], [120474, 1, "q"], [120475, 1, "r"], [120476, 1, "s"], [120477, 1, "t"], [120478, 1, "u"], [120479, 1, "v"], [120480, 1, "w"], [120481, 1, "x"], [120482, 1, "y"], [120483, 1, "z"], [120484, 1, "\u0131"], [120485, 1, "\u0237"], [[120486, 120487], 3], [120488, 1, "\u03B1"], [120489, 1, "\u03B2"], [120490, 1, "\u03B3"], [120491, 1, "\u03B4"], [120492, 1, "\u03B5"], [120493, 1, "\u03B6"], [120494, 1, "\u03B7"], [120495, 1, "\u03B8"], [120496, 1, "\u03B9"], [120497, 1, "\u03BA"], [120498, 1, "\u03BB"], [120499, 1, "\u03BC"], [120500, 1, "\u03BD"], [120501, 1, "\u03BE"], [120502, 1, "\u03BF"], [120503, 1, "\u03C0"], [120504, 1, "\u03C1"], [120505, 1, "\u03B8"], [120506, 1, "\u03C3"], [120507, 1, "\u03C4"], [120508, 1, "\u03C5"], [120509, 1, "\u03C6"], [120510, 1, "\u03C7"], [120511, 1, "\u03C8"], [120512, 1, "\u03C9"], [120513, 1, "\u2207"], [120514, 1, "\u03B1"], [120515, 1, "\u03B2"], [120516, 1, "\u03B3"], [120517, 1, "\u03B4"], [120518, 1, "\u03B5"], [120519, 1, "\u03B6"], [120520, 1, "\u03B7"], [120521, 1, "\u03B8"], [120522, 1, "\u03B9"], [120523, 1, "\u03BA"], [120524, 1, "\u03BB"], [120525, 1, "\u03BC"], [120526, 1, "\u03BD"], [120527, 1, "\u03BE"], [120528, 1, "\u03BF"], [120529, 1, "\u03C0"], [120530, 1, "\u03C1"], [[120531, 120532], 1, "\u03C3"], [120533, 1, "\u03C4"], [120534, 1, "\u03C5"], [120535, 1, "\u03C6"], [120536, 1, "\u03C7"], [120537, 1, "\u03C8"], [120538, 1, "\u03C9"], [120539, 1, "\u2202"], [120540, 1, "\u03B5"], [120541, 1, "\u03B8"], [120542, 1, "\u03BA"], [120543, 1, "\u03C6"], [120544, 1, "\u03C1"], [120545, 1, "\u03C0"], [120546, 1, "\u03B1"], [120547, 1, "\u03B2"], [120548, 1, "\u03B3"], [120549, 1, "\u03B4"], [120550, 1, "\u03B5"], [120551, 1, "\u03B6"], [120552, 1, "\u03B7"], [120553, 1, "\u03B8"], [120554, 1, "\u03B9"], [120555, 1, "\u03BA"], [120556, 1, "\u03BB"], [120557, 1, "\u03BC"], [120558, 1, "\u03BD"], [120559, 1, "\u03BE"], [120560, 1, "\u03BF"], [120561, 1, "\u03C0"], [120562, 1, "\u03C1"], [120563, 1, "\u03B8"], [120564, 1, "\u03C3"], [120565, 1, "\u03C4"], [120566, 1, "\u03C5"], [120567, 1, "\u03C6"], [120568, 1, "\u03C7"], [120569, 1, "\u03C8"], [120570, 1, "\u03C9"], [120571, 1, "\u2207"], [120572, 1, "\u03B1"], [120573, 1, "\u03B2"], [120574, 1, "\u03B3"], [120575, 1, "\u03B4"], [120576, 1, "\u03B5"], [120577, 1, "\u03B6"], [120578, 1, "\u03B7"], [120579, 1, "\u03B8"], [120580, 1, "\u03B9"], [120581, 1, "\u03BA"], [120582, 1, "\u03BB"], [120583, 1, "\u03BC"], [120584, 1, "\u03BD"], [120585, 1, "\u03BE"], [120586, 1, "\u03BF"], [120587, 1, "\u03C0"], [120588, 1, "\u03C1"], [[120589, 120590], 1, "\u03C3"], [120591, 1, "\u03C4"], [120592, 1, "\u03C5"], [120593, 1, "\u03C6"], [120594, 1, "\u03C7"], [120595, 1, "\u03C8"], [120596, 1, "\u03C9"], [120597, 1, "\u2202"], [120598, 1, "\u03B5"], [120599, 1, "\u03B8"], [120600, 1, "\u03BA"], [120601, 1, "\u03C6"], [120602, 1, "\u03C1"], [120603, 1, "\u03C0"], [120604, 1, "\u03B1"], [120605, 1, "\u03B2"], [120606, 1, "\u03B3"], [120607, 1, "\u03B4"], [120608, 1, "\u03B5"], [120609, 1, "\u03B6"], [120610, 1, "\u03B7"], [120611, 1, "\u03B8"], [120612, 1, "\u03B9"], [120613, 1, "\u03BA"], [120614, 1, "\u03BB"], [120615, 1, "\u03BC"], [120616, 1, "\u03BD"], [120617, 1, "\u03BE"], [120618, 1, "\u03BF"], [120619, 1, "\u03C0"], [120620, 1, "\u03C1"], [120621, 1, "\u03B8"], [120622, 1, "\u03C3"], [120623, 1, "\u03C4"], [120624, 1, "\u03C5"], [120625, 1, "\u03C6"], [120626, 1, "\u03C7"], [120627, 1, "\u03C8"], [120628, 1, "\u03C9"], [120629, 1, "\u2207"], [120630, 1, "\u03B1"], [120631, 1, "\u03B2"], [120632, 1, "\u03B3"], [120633, 1, "\u03B4"], [120634, 1, "\u03B5"], [120635, 1, "\u03B6"], [120636, 1, "\u03B7"], [120637, 1, "\u03B8"], [120638, 1, "\u03B9"], [120639, 1, "\u03BA"], [120640, 1, "\u03BB"], [120641, 1, "\u03BC"], [120642, 1, "\u03BD"], [120643, 1, "\u03BE"], [120644, 1, "\u03BF"], [120645, 1, "\u03C0"], [120646, 1, "\u03C1"], [[120647, 120648], 1, "\u03C3"], [120649, 1, "\u03C4"], [120650, 1, "\u03C5"], [120651, 1, "\u03C6"], [120652, 1, "\u03C7"], [120653, 1, "\u03C8"], [120654, 1, "\u03C9"], [120655, 1, "\u2202"], [120656, 1, "\u03B5"], [120657, 1, "\u03B8"], [120658, 1, "\u03BA"], [120659, 1, "\u03C6"], [120660, 1, "\u03C1"], [120661, 1, "\u03C0"], [120662, 1, "\u03B1"], [120663, 1, "\u03B2"], [120664, 1, "\u03B3"], [120665, 1, "\u03B4"], [120666, 1, "\u03B5"], [120667, 1, "\u03B6"], [120668, 1, "\u03B7"], [120669, 1, "\u03B8"], [120670, 1, "\u03B9"], [120671, 1, "\u03BA"], [120672, 1, "\u03BB"], [120673, 1, "\u03BC"], [120674, 1, "\u03BD"], [120675, 1, "\u03BE"], [120676, 1, "\u03BF"], [120677, 1, "\u03C0"], [120678, 1, "\u03C1"], [120679, 1, "\u03B8"], [120680, 1, "\u03C3"], [120681, 1, "\u03C4"], [120682, 1, "\u03C5"], [120683, 1, "\u03C6"], [120684, 1, "\u03C7"], [120685, 1, "\u03C8"], [120686, 1, "\u03C9"], [120687, 1, "\u2207"], [120688, 1, "\u03B1"], [120689, 1, "\u03B2"], [120690, 1, "\u03B3"], [120691, 1, "\u03B4"], [120692, 1, "\u03B5"], [120693, 1, "\u03B6"], [120694, 1, "\u03B7"], [120695, 1, "\u03B8"], [120696, 1, "\u03B9"], [120697, 1, "\u03BA"], [120698, 1, "\u03BB"], [120699, 1, "\u03BC"], [120700, 1, "\u03BD"], [120701, 1, "\u03BE"], [120702, 1, "\u03BF"], [120703, 1, "\u03C0"], [120704, 1, "\u03C1"], [[120705, 120706], 1, "\u03C3"], [120707, 1, "\u03C4"], [120708, 1, "\u03C5"], [120709, 1, "\u03C6"], [120710, 1, "\u03C7"], [120711, 1, "\u03C8"], [120712, 1, "\u03C9"], [120713, 1, "\u2202"], [120714, 1, "\u03B5"], [120715, 1, "\u03B8"], [120716, 1, "\u03BA"], [120717, 1, "\u03C6"], [120718, 1, "\u03C1"], [120719, 1, "\u03C0"], [120720, 1, "\u03B1"], [120721, 1, "\u03B2"], [120722, 1, "\u03B3"], [120723, 1, "\u03B4"], [120724, 1, "\u03B5"], [120725, 1, "\u03B6"], [120726, 1, "\u03B7"], [120727, 1, "\u03B8"], [120728, 1, "\u03B9"], [120729, 1, "\u03BA"], [120730, 1, "\u03BB"], [120731, 1, "\u03BC"], [120732, 1, "\u03BD"], [120733, 1, "\u03BE"], [120734, 1, "\u03BF"], [120735, 1, "\u03C0"], [120736, 1, "\u03C1"], [120737, 1, "\u03B8"], [120738, 1, "\u03C3"], [120739, 1, "\u03C4"], [120740, 1, "\u03C5"], [120741, 1, "\u03C6"], [120742, 1, "\u03C7"], [120743, 1, "\u03C8"], [120744, 1, "\u03C9"], [120745, 1, "\u2207"], [120746, 1, "\u03B1"], [120747, 1, "\u03B2"], [120748, 1, "\u03B3"], [120749, 1, "\u03B4"], [120750, 1, "\u03B5"], [120751, 1, "\u03B6"], [120752, 1, "\u03B7"], [120753, 1, "\u03B8"], [120754, 1, "\u03B9"], [120755, 1, "\u03BA"], [120756, 1, "\u03BB"], [120757, 1, "\u03BC"], [120758, 1, "\u03BD"], [120759, 1, "\u03BE"], [120760, 1, "\u03BF"], [120761, 1, "\u03C0"], [120762, 1, "\u03C1"], [[120763, 120764], 1, "\u03C3"], [120765, 1, "\u03C4"], [120766, 1, "\u03C5"], [120767, 1, "\u03C6"], [120768, 1, "\u03C7"], [120769, 1, "\u03C8"], [120770, 1, "\u03C9"], [120771, 1, "\u2202"], [120772, 1, "\u03B5"], [120773, 1, "\u03B8"], [120774, 1, "\u03BA"], [120775, 1, "\u03C6"], [120776, 1, "\u03C1"], [120777, 1, "\u03C0"], [[120778, 120779], 1, "\u03DD"], [[120780, 120781], 3], [120782, 1, "0"], [120783, 1, "1"], [120784, 1, "2"], [120785, 1, "3"], [120786, 1, "4"], [120787, 1, "5"], [120788, 1, "6"], [120789, 1, "7"], [120790, 1, "8"], [120791, 1, "9"], [120792, 1, "0"], [120793, 1, "1"], [120794, 1, "2"], [120795, 1, "3"], [120796, 1, "4"], [120797, 1, "5"], [120798, 1, "6"], [120799, 1, "7"], [120800, 1, "8"], [120801, 1, "9"], [120802, 1, "0"], [120803, 1, "1"], [120804, 1, "2"], [120805, 1, "3"], [120806, 1, "4"], [120807, 1, "5"], [120808, 1, "6"], [120809, 1, "7"], [120810, 1, "8"], [120811, 1, "9"], [120812, 1, "0"], [120813, 1, "1"], [120814, 1, "2"], [120815, 1, "3"], [120816, 1, "4"], [120817, 1, "5"], [120818, 1, "6"], [120819, 1, "7"], [120820, 1, "8"], [120821, 1, "9"], [120822, 1, "0"], [120823, 1, "1"], [120824, 1, "2"], [120825, 1, "3"], [120826, 1, "4"], [120827, 1, "5"], [120828, 1, "6"], [120829, 1, "7"], [120830, 1, "8"], [120831, 1, "9"], [[120832, 121343], 2], [[121344, 121398], 2], [[121399, 121402], 2], [[121403, 121452], 2], [[121453, 121460], 2], [121461, 2], [[121462, 121475], 2], [121476, 2], [[121477, 121483], 2], [[121484, 121498], 3], [[121499, 121503], 2], [121504, 3], [[121505, 121519], 2], [[121520, 122623], 3], [[122624, 122654], 2], [[122655, 122660], 3], [[122661, 122666], 2], [[122667, 122879], 3], [[122880, 122886], 2], [122887, 3], [[122888, 122904], 2], [[122905, 122906], 3], [[122907, 122913], 2], [122914, 3], [[122915, 122916], 2], [122917, 3], [[122918, 122922], 2], [[122923, 122927], 3], [122928, 1, "\u0430"], [122929, 1, "\u0431"], [122930, 1, "\u0432"], [122931, 1, "\u0433"], [122932, 1, "\u0434"], [122933, 1, "\u0435"], [122934, 1, "\u0436"], [122935, 1, "\u0437"], [122936, 1, "\u0438"], [122937, 1, "\u043A"], [122938, 1, "\u043B"], [122939, 1, "\u043C"], [122940, 1, "\u043E"], [122941, 1, "\u043F"], [122942, 1, "\u0440"], [122943, 1, "\u0441"], [122944, 1, "\u0442"], [122945, 1, "\u0443"], [122946, 1, "\u0444"], [122947, 1, "\u0445"], [122948, 1, "\u0446"], [122949, 1, "\u0447"], [122950, 1, "\u0448"], [122951, 1, "\u044B"], [122952, 1, "\u044D"], [122953, 1, "\u044E"], [122954, 1, "\uA689"], [122955, 1, "\u04D9"], [122956, 1, "\u0456"], [122957, 1, "\u0458"], [122958, 1, "\u04E9"], [122959, 1, "\u04AF"], [122960, 1, "\u04CF"], [122961, 1, "\u0430"], [122962, 1, "\u0431"], [122963, 1, "\u0432"], [122964, 1, "\u0433"], [122965, 1, "\u0434"], [122966, 1, "\u0435"], [122967, 1, "\u0436"], [122968, 1, "\u0437"], [122969, 1, "\u0438"], [122970, 1, "\u043A"], [122971, 1, "\u043B"], [122972, 1, "\u043E"], [122973, 1, "\u043F"], [122974, 1, "\u0441"], [122975, 1, "\u0443"], [122976, 1, "\u0444"], [122977, 1, "\u0445"], [122978, 1, "\u0446"], [122979, 1, "\u0447"], [122980, 1, "\u0448"], [122981, 1, "\u044A"], [122982, 1, "\u044B"], [122983, 1, "\u0491"], [122984, 1, "\u0456"], [122985, 1, "\u0455"], [122986, 1, "\u045F"], [122987, 1, "\u04AB"], [122988, 1, "\uA651"], [122989, 1, "\u04B1"], [[122990, 123022], 3], [123023, 2], [[123024, 123135], 3], [[123136, 123180], 2], [[123181, 123183], 3], [[123184, 123197], 2], [[123198, 123199], 3], [[123200, 123209], 2], [[123210, 123213], 3], [123214, 2], [123215, 2], [[123216, 123535], 3], [[123536, 123566], 2], [[123567, 123583], 3], [[123584, 123641], 2], [[123642, 123646], 3], [123647, 2], [[123648, 124111], 3], [[124112, 124153], 2], [[124154, 124367], 3], [[124368, 124410], 2], [[124411, 124414], 3], [124415, 2], [[124416, 124895], 3], [[124896, 124902], 2], [124903, 3], [[124904, 124907], 2], [124908, 3], [[124909, 124910], 2], [124911, 3], [[124912, 124926], 2], [124927, 3], [[124928, 125124], 2], [[125125, 125126], 3], [[125127, 125135], 2], [[125136, 125142], 2], [[125143, 125183], 3], [125184, 1, "\u{1E922}"], [125185, 1, "\u{1E923}"], [125186, 1, "\u{1E924}"], [125187, 1, "\u{1E925}"], [125188, 1, "\u{1E926}"], [125189, 1, "\u{1E927}"], [125190, 1, "\u{1E928}"], [125191, 1, "\u{1E929}"], [125192, 1, "\u{1E92A}"], [125193, 1, "\u{1E92B}"], [125194, 1, "\u{1E92C}"], [125195, 1, "\u{1E92D}"], [125196, 1, "\u{1E92E}"], [125197, 1, "\u{1E92F}"], [125198, 1, "\u{1E930}"], [125199, 1, "\u{1E931}"], [125200, 1, "\u{1E932}"], [125201, 1, "\u{1E933}"], [125202, 1, "\u{1E934}"], [125203, 1, "\u{1E935}"], [125204, 1, "\u{1E936}"], [125205, 1, "\u{1E937}"], [125206, 1, "\u{1E938}"], [125207, 1, "\u{1E939}"], [125208, 1, "\u{1E93A}"], [125209, 1, "\u{1E93B}"], [125210, 1, "\u{1E93C}"], [125211, 1, "\u{1E93D}"], [125212, 1, "\u{1E93E}"], [125213, 1, "\u{1E93F}"], [125214, 1, "\u{1E940}"], [125215, 1, "\u{1E941}"], [125216, 1, "\u{1E942}"], [125217, 1, "\u{1E943}"], [[125218, 125258], 2], [125259, 2], [[125260, 125263], 3], [[125264, 125273], 2], [[125274, 125277], 3], [[125278, 125279], 2], [[125280, 126064], 3], [[126065, 126132], 2], [[126133, 126208], 3], [[126209, 126269], 2], [[126270, 126463], 3], [126464, 1, "\u0627"], [126465, 1, "\u0628"], [126466, 1, "\u062C"], [126467, 1, "\u062F"], [126468, 3], [126469, 1, "\u0648"], [126470, 1, "\u0632"], [126471, 1, "\u062D"], [126472, 1, "\u0637"], [126473, 1, "\u064A"], [126474, 1, "\u0643"], [126475, 1, "\u0644"], [126476, 1, "\u0645"], [126477, 1, "\u0646"], [126478, 1, "\u0633"], [126479, 1, "\u0639"], [126480, 1, "\u0641"], [126481, 1, "\u0635"], [126482, 1, "\u0642"], [126483, 1, "\u0631"], [126484, 1, "\u0634"], [126485, 1, "\u062A"], [126486, 1, "\u062B"], [126487, 1, "\u062E"], [126488, 1, "\u0630"], [126489, 1, "\u0636"], [126490, 1, "\u0638"], [126491, 1, "\u063A"], [126492, 1, "\u066E"], [126493, 1, "\u06BA"], [126494, 1, "\u06A1"], [126495, 1, "\u066F"], [126496, 3], [126497, 1, "\u0628"], [126498, 1, "\u062C"], [126499, 3], [126500, 1, "\u0647"], [[126501, 126502], 3], [126503, 1, "\u062D"], [126504, 3], [126505, 1, "\u064A"], [126506, 1, "\u0643"], [126507, 1, "\u0644"], [126508, 1, "\u0645"], [126509, 1, "\u0646"], [126510, 1, "\u0633"], [126511, 1, "\u0639"], [126512, 1, "\u0641"], [126513, 1, "\u0635"], [126514, 1, "\u0642"], [126515, 3], [126516, 1, "\u0634"], [126517, 1, "\u062A"], [126518, 1, "\u062B"], [126519, 1, "\u062E"], [126520, 3], [126521, 1, "\u0636"], [126522, 3], [126523, 1, "\u063A"], [[126524, 126529], 3], [126530, 1, "\u062C"], [[126531, 126534], 3], [126535, 1, "\u062D"], [126536, 3], [126537, 1, "\u064A"], [126538, 3], [126539, 1, "\u0644"], [126540, 3], [126541, 1, "\u0646"], [126542, 1, "\u0633"], [126543, 1, "\u0639"], [126544, 3], [126545, 1, "\u0635"], [126546, 1, "\u0642"], [126547, 3], [126548, 1, "\u0634"], [[126549, 126550], 3], [126551, 1, "\u062E"], [126552, 3], [126553, 1, "\u0636"], [126554, 3], [126555, 1, "\u063A"], [126556, 3], [126557, 1, "\u06BA"], [126558, 3], [126559, 1, "\u066F"], [126560, 3], [126561, 1, "\u0628"], [126562, 1, "\u062C"], [126563, 3], [126564, 1, "\u0647"], [[126565, 126566], 3], [126567, 1, "\u062D"], [126568, 1, "\u0637"], [126569, 1, "\u064A"], [126570, 1, "\u0643"], [126571, 3], [126572, 1, "\u0645"], [126573, 1, "\u0646"], [126574, 1, "\u0633"], [126575, 1, "\u0639"], [126576, 1, "\u0641"], [126577, 1, "\u0635"], [126578, 1, "\u0642"], [126579, 3], [126580, 1, "\u0634"], [126581, 1, "\u062A"], [126582, 1, "\u062B"], [126583, 1, "\u062E"], [126584, 3], [126585, 1, "\u0636"], [126586, 1, "\u0638"], [126587, 1, "\u063A"], [126588, 1, "\u066E"], [126589, 3], [126590, 1, "\u06A1"], [126591, 3], [126592, 1, "\u0627"], [126593, 1, "\u0628"], [126594, 1, "\u062C"], [126595, 1, "\u062F"], [126596, 1, "\u0647"], [126597, 1, "\u0648"], [126598, 1, "\u0632"], [126599, 1, "\u062D"], [126600, 1, "\u0637"], [126601, 1, "\u064A"], [126602, 3], [126603, 1, "\u0644"], [126604, 1, "\u0645"], [126605, 1, "\u0646"], [126606, 1, "\u0633"], [126607, 1, "\u0639"], [126608, 1, "\u0641"], [126609, 1, "\u0635"], [126610, 1, "\u0642"], [126611, 1, "\u0631"], [126612, 1, "\u0634"], [126613, 1, "\u062A"], [126614, 1, "\u062B"], [126615, 1, "\u062E"], [126616, 1, "\u0630"], [126617, 1, "\u0636"], [126618, 1, "\u0638"], [126619, 1, "\u063A"], [[126620, 126624], 3], [126625, 1, "\u0628"], [126626, 1, "\u062C"], [126627, 1, "\u062F"], [126628, 3], [126629, 1, "\u0648"], [126630, 1, "\u0632"], [126631, 1, "\u062D"], [126632, 1, "\u0637"], [126633, 1, "\u064A"], [126634, 3], [126635, 1, "\u0644"], [126636, 1, "\u0645"], [126637, 1, "\u0646"], [126638, 1, "\u0633"], [126639, 1, "\u0639"], [126640, 1, "\u0641"], [126641, 1, "\u0635"], [126642, 1, "\u0642"], [126643, 1, "\u0631"], [126644, 1, "\u0634"], [126645, 1, "\u062A"], [126646, 1, "\u062B"], [126647, 1, "\u062E"], [126648, 1, "\u0630"], [126649, 1, "\u0636"], [126650, 1, "\u0638"], [126651, 1, "\u063A"], [[126652, 126703], 3], [[126704, 126705], 2], [[126706, 126975], 3], [[126976, 127019], 2], [[127020, 127023], 3], [[127024, 127123], 2], [[127124, 127135], 3], [[127136, 127150], 2], [[127151, 127152], 3], [[127153, 127166], 2], [127167, 2], [127168, 3], [[127169, 127183], 2], [127184, 3], [[127185, 127199], 2], [[127200, 127221], 2], [[127222, 127231], 3], [127232, 3], [127233, 1, "0,"], [127234, 1, "1,"], [127235, 1, "2,"], [127236, 1, "3,"], [127237, 1, "4,"], [127238, 1, "5,"], [127239, 1, "6,"], [127240, 1, "7,"], [127241, 1, "8,"], [127242, 1, "9,"], [[127243, 127244], 2], [[127245, 127247], 2], [127248, 1, "(a)"], [127249, 1, "(b)"], [127250, 1, "(c)"], [127251, 1, "(d)"], [127252, 1, "(e)"], [127253, 1, "(f)"], [127254, 1, "(g)"], [127255, 1, "(h)"], [127256, 1, "(i)"], [127257, 1, "(j)"], [127258, 1, "(k)"], [127259, 1, "(l)"], [127260, 1, "(m)"], [127261, 1, "(n)"], [127262, 1, "(o)"], [127263, 1, "(p)"], [127264, 1, "(q)"], [127265, 1, "(r)"], [127266, 1, "(s)"], [127267, 1, "(t)"], [127268, 1, "(u)"], [127269, 1, "(v)"], [127270, 1, "(w)"], [127271, 1, "(x)"], [127272, 1, "(y)"], [127273, 1, "(z)"], [127274, 1, "\u3014s\u3015"], [127275, 1, "c"], [127276, 1, "r"], [127277, 1, "cd"], [127278, 1, "wz"], [127279, 2], [127280, 1, "a"], [127281, 1, "b"], [127282, 1, "c"], [127283, 1, "d"], [127284, 1, "e"], [127285, 1, "f"], [127286, 1, "g"], [127287, 1, "h"], [127288, 1, "i"], [127289, 1, "j"], [127290, 1, "k"], [127291, 1, "l"], [127292, 1, "m"], [127293, 1, "n"], [127294, 1, "o"], [127295, 1, "p"], [127296, 1, "q"], [127297, 1, "r"], [127298, 1, "s"], [127299, 1, "t"], [127300, 1, "u"], [127301, 1, "v"], [127302, 1, "w"], [127303, 1, "x"], [127304, 1, "y"], [127305, 1, "z"], [127306, 1, "hv"], [127307, 1, "mv"], [127308, 1, "sd"], [127309, 1, "ss"], [127310, 1, "ppv"], [127311, 1, "wc"], [[127312, 127318], 2], [127319, 2], [[127320, 127326], 2], [127327, 2], [[127328, 127337], 2], [127338, 1, "mc"], [127339, 1, "md"], [127340, 1, "mr"], [[127341, 127343], 2], [[127344, 127352], 2], [127353, 2], [127354, 2], [[127355, 127356], 2], [[127357, 127358], 2], [127359, 2], [[127360, 127369], 2], [[127370, 127373], 2], [[127374, 127375], 2], [127376, 1, "dj"], [[127377, 127386], 2], [[127387, 127404], 2], [127405, 2], [[127406, 127461], 3], [[127462, 127487], 2], [127488, 1, "\u307B\u304B"], [127489, 1, "\u30B3\u30B3"], [127490, 1, "\u30B5"], [[127491, 127503], 3], [127504, 1, "\u624B"], [127505, 1, "\u5B57"], [127506, 1, "\u53CC"], [127507, 1, "\u30C7"], [127508, 1, "\u4E8C"], [127509, 1, "\u591A"], [127510, 1, "\u89E3"], [127511, 1, "\u5929"], [127512, 1, "\u4EA4"], [127513, 1, "\u6620"], [127514, 1, "\u7121"], [127515, 1, "\u6599"], [127516, 1, "\u524D"], [127517, 1, "\u5F8C"], [127518, 1, "\u518D"], [127519, 1, "\u65B0"], [127520, 1, "\u521D"], [127521, 1, "\u7D42"], [127522, 1, "\u751F"], [127523, 1, "\u8CA9"], [127524, 1, "\u58F0"], [127525, 1, "\u5439"], [127526, 1, "\u6F14"], [127527, 1, "\u6295"], [127528, 1, "\u6355"], [127529, 1, "\u4E00"], [127530, 1, "\u4E09"], [127531, 1, "\u904A"], [127532, 1, "\u5DE6"], [127533, 1, "\u4E2D"], [127534, 1, "\u53F3"], [127535, 1, "\u6307"], [127536, 1, "\u8D70"], [127537, 1, "\u6253"], [127538, 1, "\u7981"], [127539, 1, "\u7A7A"], [127540, 1, "\u5408"], [127541, 1, "\u6E80"], [127542, 1, "\u6709"], [127543, 1, "\u6708"], [127544, 1, "\u7533"], [127545, 1, "\u5272"], [127546, 1, "\u55B6"], [127547, 1, "\u914D"], [[127548, 127551], 3], [127552, 1, "\u3014\u672C\u3015"], [127553, 1, "\u3014\u4E09\u3015"], [127554, 1, "\u3014\u4E8C\u3015"], [127555, 1, "\u3014\u5B89\u3015"], [127556, 1, "\u3014\u70B9\u3015"], [127557, 1, "\u3014\u6253\u3015"], [127558, 1, "\u3014\u76D7\u3015"], [127559, 1, "\u3014\u52DD\u3015"], [127560, 1, "\u3014\u6557\u3015"], [[127561, 127567], 3], [127568, 1, "\u5F97"], [127569, 1, "\u53EF"], [[127570, 127583], 3], [[127584, 127589], 2], [[127590, 127743], 3], [[127744, 127776], 2], [[127777, 127788], 2], [[127789, 127791], 2], [[127792, 127797], 2], [127798, 2], [[127799, 127868], 2], [127869, 2], [[127870, 127871], 2], [[127872, 127891], 2], [[127892, 127903], 2], [[127904, 127940], 2], [127941, 2], [[127942, 127946], 2], [[127947, 127950], 2], [[127951, 127955], 2], [[127956, 127967], 2], [[127968, 127984], 2], [[127985, 127991], 2], [[127992, 127999], 2], [[128e3, 128062], 2], [128063, 2], [128064, 2], [128065, 2], [[128066, 128247], 2], [128248, 2], [[128249, 128252], 2], [[128253, 128254], 2], [128255, 2], [[128256, 128317], 2], [[128318, 128319], 2], [[128320, 128323], 2], [[128324, 128330], 2], [[128331, 128335], 2], [[128336, 128359], 2], [[128360, 128377], 2], [128378, 2], [[128379, 128419], 2], [128420, 2], [[128421, 128506], 2], [[128507, 128511], 2], [128512, 2], [[128513, 128528], 2], [128529, 2], [[128530, 128532], 2], [128533, 2], [128534, 2], [128535, 2], [128536, 2], [128537, 2], [128538, 2], [128539, 2], [[128540, 128542], 2], [128543, 2], [[128544, 128549], 2], [[128550, 128551], 2], [[128552, 128555], 2], [128556, 2], [128557, 2], [[128558, 128559], 2], [[128560, 128563], 2], [128564, 2], [[128565, 128576], 2], [[128577, 128578], 2], [[128579, 128580], 2], [[128581, 128591], 2], [[128592, 128639], 2], [[128640, 128709], 2], [[128710, 128719], 2], [128720, 2], [[128721, 128722], 2], [[128723, 128724], 2], [128725, 2], [[128726, 128727], 2], [[128728, 128731], 3], [128732, 2], [[128733, 128735], 2], [[128736, 128748], 2], [[128749, 128751], 3], [[128752, 128755], 2], [[128756, 128758], 2], [[128759, 128760], 2], [128761, 2], [128762, 2], [[128763, 128764], 2], [[128765, 128767], 3], [[128768, 128883], 2], [[128884, 128886], 2], [[128887, 128890], 3], [[128891, 128895], 2], [[128896, 128980], 2], [[128981, 128984], 2], [128985, 2], [[128986, 128991], 3], [[128992, 129003], 2], [[129004, 129007], 3], [129008, 2], [[129009, 129023], 3], [[129024, 129035], 2], [[129036, 129039], 3], [[129040, 129095], 2], [[129096, 129103], 3], [[129104, 129113], 2], [[129114, 129119], 3], [[129120, 129159], 2], [[129160, 129167], 3], [[129168, 129197], 2], [[129198, 129199], 3], [[129200, 129201], 2], [[129202, 129211], 2], [[129212, 129215], 3], [[129216, 129217], 2], [[129218, 129279], 3], [[129280, 129291], 2], [129292, 2], [[129293, 129295], 2], [[129296, 129304], 2], [[129305, 129310], 2], [129311, 2], [[129312, 129319], 2], [[129320, 129327], 2], [129328, 2], [[129329, 129330], 2], [[129331, 129342], 2], [129343, 2], [[129344, 129355], 2], [129356, 2], [[129357, 129359], 2], [[129360, 129374], 2], [[129375, 129387], 2], [[129388, 129392], 2], [129393, 2], [129394, 2], [[129395, 129398], 2], [[129399, 129400], 2], [129401, 2], [129402, 2], [129403, 2], [[129404, 129407], 2], [[129408, 129412], 2], [[129413, 129425], 2], [[129426, 129431], 2], [[129432, 129442], 2], [[129443, 129444], 2], [[129445, 129450], 2], [[129451, 129453], 2], [[129454, 129455], 2], [[129456, 129465], 2], [[129466, 129471], 2], [129472, 2], [[129473, 129474], 2], [[129475, 129482], 2], [129483, 2], [129484, 2], [[129485, 129487], 2], [[129488, 129510], 2], [[129511, 129535], 2], [[129536, 129619], 2], [[129620, 129631], 3], [[129632, 129645], 2], [[129646, 129647], 3], [[129648, 129651], 2], [129652, 2], [[129653, 129655], 2], [[129656, 129658], 2], [[129659, 129660], 2], [[129661, 129663], 3], [[129664, 129666], 2], [[129667, 129670], 2], [[129671, 129672], 2], [129673, 2], [[129674, 129678], 3], [129679, 2], [[129680, 129685], 2], [[129686, 129704], 2], [[129705, 129708], 2], [[129709, 129711], 2], [[129712, 129718], 2], [[129719, 129722], 2], [[129723, 129725], 2], [129726, 2], [129727, 2], [[129728, 129730], 2], [[129731, 129733], 2], [129734, 2], [[129735, 129741], 3], [[129742, 129743], 2], [[129744, 129750], 2], [[129751, 129753], 2], [[129754, 129755], 2], [129756, 2], [[129757, 129758], 3], [129759, 2], [[129760, 129767], 2], [129768, 2], [129769, 2], [[129770, 129775], 3], [[129776, 129782], 2], [[129783, 129784], 2], [[129785, 129791], 3], [[129792, 129938], 2], [129939, 3], [[129940, 129994], 2], [[129995, 130031], 2], [130032, 1, "0"], [130033, 1, "1"], [130034, 1, "2"], [130035, 1, "3"], [130036, 1, "4"], [130037, 1, "5"], [130038, 1, "6"], [130039, 1, "7"], [130040, 1, "8"], [130041, 1, "9"], [[130042, 131069], 3], [[131070, 131071], 3], [[131072, 173782], 2], [[173783, 173789], 2], [[173790, 173791], 2], [[173792, 173823], 3], [[173824, 177972], 2], [[177973, 177976], 2], [177977, 2], [[177978, 177983], 3], [[177984, 178205], 2], [[178206, 178207], 3], [[178208, 183969], 2], [[183970, 183983], 3], [[183984, 191456], 2], [[191457, 191471], 3], [[191472, 192093], 2], [[192094, 194559], 3], [194560, 1, "\u4E3D"], [194561, 1, "\u4E38"], [194562, 1, "\u4E41"], [194563, 1, "\u{20122}"], [194564, 1, "\u4F60"], [194565, 1, "\u4FAE"], [194566, 1, "\u4FBB"], [194567, 1, "\u5002"], [194568, 1, "\u507A"], [194569, 1, "\u5099"], [194570, 1, "\u50E7"], [194571, 1, "\u50CF"], [194572, 1, "\u349E"], [194573, 1, "\u{2063A}"], [194574, 1, "\u514D"], [194575, 1, "\u5154"], [194576, 1, "\u5164"], [194577, 1, "\u5177"], [194578, 1, "\u{2051C}"], [194579, 1, "\u34B9"], [194580, 1, "\u5167"], [194581, 1, "\u518D"], [194582, 1, "\u{2054B}"], [194583, 1, "\u5197"], [194584, 1, "\u51A4"], [194585, 1, "\u4ECC"], [194586, 1, "\u51AC"], [194587, 1, "\u51B5"], [194588, 1, "\u{291DF}"], [194589, 1, "\u51F5"], [194590, 1, "\u5203"], [194591, 1, "\u34DF"], [194592, 1, "\u523B"], [194593, 1, "\u5246"], [194594, 1, "\u5272"], [194595, 1, "\u5277"], [194596, 1, "\u3515"], [194597, 1, "\u52C7"], [194598, 1, "\u52C9"], [194599, 1, "\u52E4"], [194600, 1, "\u52FA"], [194601, 1, "\u5305"], [194602, 1, "\u5306"], [194603, 1, "\u5317"], [194604, 1, "\u5349"], [194605, 1, "\u5351"], [194606, 1, "\u535A"], [194607, 1, "\u5373"], [194608, 1, "\u537D"], [[194609, 194611], 1, "\u537F"], [194612, 1, "\u{20A2C}"], [194613, 1, "\u7070"], [194614, 1, "\u53CA"], [194615, 1, "\u53DF"], [194616, 1, "\u{20B63}"], [194617, 1, "\u53EB"], [194618, 1, "\u53F1"], [194619, 1, "\u5406"], [194620, 1, "\u549E"], [194621, 1, "\u5438"], [194622, 1, "\u5448"], [194623, 1, "\u5468"], [194624, 1, "\u54A2"], [194625, 1, "\u54F6"], [194626, 1, "\u5510"], [194627, 1, "\u5553"], [194628, 1, "\u5563"], [[194629, 194630], 1, "\u5584"], [194631, 1, "\u5599"], [194632, 1, "\u55AB"], [194633, 1, "\u55B3"], [194634, 1, "\u55C2"], [194635, 1, "\u5716"], [194636, 1, "\u5606"], [194637, 1, "\u5717"], [194638, 1, "\u5651"], [194639, 1, "\u5674"], [194640, 1, "\u5207"], [194641, 1, "\u58EE"], [194642, 1, "\u57CE"], [194643, 1, "\u57F4"], [194644, 1, "\u580D"], [194645, 1, "\u578B"], [194646, 1, "\u5832"], [194647, 1, "\u5831"], [194648, 1, "\u58AC"], [194649, 1, "\u{214E4}"], [194650, 1, "\u58F2"], [194651, 1, "\u58F7"], [194652, 1, "\u5906"], [194653, 1, "\u591A"], [194654, 1, "\u5922"], [194655, 1, "\u5962"], [194656, 1, "\u{216A8}"], [194657, 1, "\u{216EA}"], [194658, 1, "\u59EC"], [194659, 1, "\u5A1B"], [194660, 1, "\u5A27"], [194661, 1, "\u59D8"], [194662, 1, "\u5A66"], [194663, 1, "\u36EE"], [194664, 1, "\u36FC"], [194665, 1, "\u5B08"], [[194666, 194667], 1, "\u5B3E"], [194668, 1, "\u{219C8}"], [194669, 1, "\u5BC3"], [194670, 1, "\u5BD8"], [194671, 1, "\u5BE7"], [194672, 1, "\u5BF3"], [194673, 1, "\u{21B18}"], [194674, 1, "\u5BFF"], [194675, 1, "\u5C06"], [194676, 1, "\u5F53"], [194677, 1, "\u5C22"], [194678, 1, "\u3781"], [194679, 1, "\u5C60"], [194680, 1, "\u5C6E"], [194681, 1, "\u5CC0"], [194682, 1, "\u5C8D"], [194683, 1, "\u{21DE4}"], [194684, 1, "\u5D43"], [194685, 1, "\u{21DE6}"], [194686, 1, "\u5D6E"], [194687, 1, "\u5D6B"], [194688, 1, "\u5D7C"], [194689, 1, "\u5DE1"], [194690, 1, "\u5DE2"], [194691, 1, "\u382F"], [194692, 1, "\u5DFD"], [194693, 1, "\u5E28"], [194694, 1, "\u5E3D"], [194695, 1, "\u5E69"], [194696, 1, "\u3862"], [194697, 1, "\u{22183}"], [194698, 1, "\u387C"], [194699, 1, "\u5EB0"], [194700, 1, "\u5EB3"], [194701, 1, "\u5EB6"], [194702, 1, "\u5ECA"], [194703, 1, "\u{2A392}"], [194704, 1, "\u5EFE"], [[194705, 194706], 1, "\u{22331}"], [194707, 1, "\u8201"], [[194708, 194709], 1, "\u5F22"], [194710, 1, "\u38C7"], [194711, 1, "\u{232B8}"], [194712, 1, "\u{261DA}"], [194713, 1, "\u5F62"], [194714, 1, "\u5F6B"], [194715, 1, "\u38E3"], [194716, 1, "\u5F9A"], [194717, 1, "\u5FCD"], [194718, 1, "\u5FD7"], [194719, 1, "\u5FF9"], [194720, 1, "\u6081"], [194721, 1, "\u393A"], [194722, 1, "\u391C"], [194723, 1, "\u6094"], [194724, 1, "\u{226D4}"], [194725, 1, "\u60C7"], [194726, 1, "\u6148"], [194727, 1, "\u614C"], [194728, 1, "\u614E"], [194729, 1, "\u614C"], [194730, 1, "\u617A"], [194731, 1, "\u618E"], [194732, 1, "\u61B2"], [194733, 1, "\u61A4"], [194734, 1, "\u61AF"], [194735, 1, "\u61DE"], [194736, 1, "\u61F2"], [194737, 1, "\u61F6"], [194738, 1, "\u6210"], [194739, 1, "\u621B"], [194740, 1, "\u625D"], [194741, 1, "\u62B1"], [194742, 1, "\u62D4"], [194743, 1, "\u6350"], [194744, 1, "\u{22B0C}"], [194745, 1, "\u633D"], [194746, 1, "\u62FC"], [194747, 1, "\u6368"], [194748, 1, "\u6383"], [194749, 1, "\u63E4"], [194750, 1, "\u{22BF1}"], [194751, 1, "\u6422"], [194752, 1, "\u63C5"], [194753, 1, "\u63A9"], [194754, 1, "\u3A2E"], [194755, 1, "\u6469"], [194756, 1, "\u647E"], [194757, 1, "\u649D"], [194758, 1, "\u6477"], [194759, 1, "\u3A6C"], [194760, 1, "\u654F"], [194761, 1, "\u656C"], [194762, 1, "\u{2300A}"], [194763, 1, "\u65E3"], [194764, 1, "\u66F8"], [194765, 1, "\u6649"], [194766, 1, "\u3B19"], [194767, 1, "\u6691"], [194768, 1, "\u3B08"], [194769, 1, "\u3AE4"], [194770, 1, "\u5192"], [194771, 1, "\u5195"], [194772, 1, "\u6700"], [194773, 1, "\u669C"], [194774, 1, "\u80AD"], [194775, 1, "\u43D9"], [194776, 1, "\u6717"], [194777, 1, "\u671B"], [194778, 1, "\u6721"], [194779, 1, "\u675E"], [194780, 1, "\u6753"], [194781, 1, "\u{233C3}"], [194782, 1, "\u3B49"], [194783, 1, "\u67FA"], [194784, 1, "\u6785"], [194785, 1, "\u6852"], [194786, 1, "\u6885"], [194787, 1, "\u{2346D}"], [194788, 1, "\u688E"], [194789, 1, "\u681F"], [194790, 1, "\u6914"], [194791, 1, "\u3B9D"], [194792, 1, "\u6942"], [194793, 1, "\u69A3"], [194794, 1, "\u69EA"], [194795, 1, "\u6AA8"], [194796, 1, "\u{236A3}"], [194797, 1, "\u6ADB"], [194798, 1, "\u3C18"], [194799, 1, "\u6B21"], [194800, 1, "\u{238A7}"], [194801, 1, "\u6B54"], [194802, 1, "\u3C4E"], [194803, 1, "\u6B72"], [194804, 1, "\u6B9F"], [194805, 1, "\u6BBA"], [194806, 1, "\u6BBB"], [194807, 1, "\u{23A8D}"], [194808, 1, "\u{21D0B}"], [194809, 1, "\u{23AFA}"], [194810, 1, "\u6C4E"], [194811, 1, "\u{23CBC}"], [194812, 1, "\u6CBF"], [194813, 1, "\u6CCD"], [194814, 1, "\u6C67"], [194815, 1, "\u6D16"], [194816, 1, "\u6D3E"], [194817, 1, "\u6D77"], [194818, 1, "\u6D41"], [194819, 1, "\u6D69"], [194820, 1, "\u6D78"], [194821, 1, "\u6D85"], [194822, 1, "\u{23D1E}"], [194823, 1, "\u6D34"], [194824, 1, "\u6E2F"], [194825, 1, "\u6E6E"], [194826, 1, "\u3D33"], [194827, 1, "\u6ECB"], [194828, 1, "\u6EC7"], [194829, 1, "\u{23ED1}"], [194830, 1, "\u6DF9"], [194831, 1, "\u6F6E"], [194832, 1, "\u{23F5E}"], [194833, 1, "\u{23F8E}"], [194834, 1, "\u6FC6"], [194835, 1, "\u7039"], [194836, 1, "\u701E"], [194837, 1, "\u701B"], [194838, 1, "\u3D96"], [194839, 1, "\u704A"], [194840, 1, "\u707D"], [194841, 1, "\u7077"], [194842, 1, "\u70AD"], [194843, 1, "\u{20525}"], [194844, 1, "\u7145"], [194845, 1, "\u{24263}"], [194846, 1, "\u719C"], [194847, 1, "\u{243AB}"], [194848, 1, "\u7228"], [194849, 1, "\u7235"], [194850, 1, "\u7250"], [194851, 1, "\u{24608}"], [194852, 1, "\u7280"], [194853, 1, "\u7295"], [194854, 1, "\u{24735}"], [194855, 1, "\u{24814}"], [194856, 1, "\u737A"], [194857, 1, "\u738B"], [194858, 1, "\u3EAC"], [194859, 1, "\u73A5"], [[194860, 194861], 1, "\u3EB8"], [194862, 1, "\u7447"], [194863, 1, "\u745C"], [194864, 1, "\u7471"], [194865, 1, "\u7485"], [194866, 1, "\u74CA"], [194867, 1, "\u3F1B"], [194868, 1, "\u7524"], [194869, 1, "\u{24C36}"], [194870, 1, "\u753E"], [194871, 1, "\u{24C92}"], [194872, 1, "\u7570"], [194873, 1, "\u{2219F}"], [194874, 1, "\u7610"], [194875, 1, "\u{24FA1}"], [194876, 1, "\u{24FB8}"], [194877, 1, "\u{25044}"], [194878, 1, "\u3FFC"], [194879, 1, "\u4008"], [194880, 1, "\u76F4"], [194881, 1, "\u{250F3}"], [194882, 1, "\u{250F2}"], [194883, 1, "\u{25119}"], [194884, 1, "\u{25133}"], [194885, 1, "\u771E"], [[194886, 194887], 1, "\u771F"], [194888, 1, "\u774A"], [194889, 1, "\u4039"], [194890, 1, "\u778B"], [194891, 1, "\u4046"], [194892, 1, "\u4096"], [194893, 1, "\u{2541D}"], [194894, 1, "\u784E"], [194895, 1, "\u788C"], [194896, 1, "\u78CC"], [194897, 1, "\u40E3"], [194898, 1, "\u{25626}"], [194899, 1, "\u7956"], [194900, 1, "\u{2569A}"], [194901, 1, "\u{256C5}"], [194902, 1, "\u798F"], [194903, 1, "\u79EB"], [194904, 1, "\u412F"], [194905, 1, "\u7A40"], [194906, 1, "\u7A4A"], [194907, 1, "\u7A4F"], [194908, 1, "\u{2597C}"], [[194909, 194910], 1, "\u{25AA7}"], [194911, 1, "\u7AEE"], [194912, 1, "\u4202"], [194913, 1, "\u{25BAB}"], [194914, 1, "\u7BC6"], [194915, 1, "\u7BC9"], [194916, 1, "\u4227"], [194917, 1, "\u{25C80}"], [194918, 1, "\u7CD2"], [194919, 1, "\u42A0"], [194920, 1, "\u7CE8"], [194921, 1, "\u7CE3"], [194922, 1, "\u7D00"], [194923, 1, "\u{25F86}"], [194924, 1, "\u7D63"], [194925, 1, "\u4301"], [194926, 1, "\u7DC7"], [194927, 1, "\u7E02"], [194928, 1, "\u7E45"], [194929, 1, "\u4334"], [194930, 1, "\u{26228}"], [194931, 1, "\u{26247}"], [194932, 1, "\u4359"], [194933, 1, "\u{262D9}"], [194934, 1, "\u7F7A"], [194935, 1, "\u{2633E}"], [194936, 1, "\u7F95"], [194937, 1, "\u7FFA"], [194938, 1, "\u8005"], [194939, 1, "\u{264DA}"], [194940, 1, "\u{26523}"], [194941, 1, "\u8060"], [194942, 1, "\u{265A8}"], [194943, 1, "\u8070"], [194944, 1, "\u{2335F}"], [194945, 1, "\u43D5"], [194946, 1, "\u80B2"], [194947, 1, "\u8103"], [194948, 1, "\u440B"], [194949, 1, "\u813E"], [194950, 1, "\u5AB5"], [194951, 1, "\u{267A7}"], [194952, 1, "\u{267B5}"], [194953, 1, "\u{23393}"], [194954, 1, "\u{2339C}"], [194955, 1, "\u8201"], [194956, 1, "\u8204"], [194957, 1, "\u8F9E"], [194958, 1, "\u446B"], [194959, 1, "\u8291"], [194960, 1, "\u828B"], [194961, 1, "\u829D"], [194962, 1, "\u52B3"], [194963, 1, "\u82B1"], [194964, 1, "\u82B3"], [194965, 1, "\u82BD"], [194966, 1, "\u82E6"], [194967, 1, "\u{26B3C}"], [194968, 1, "\u82E5"], [194969, 1, "\u831D"], [194970, 1, "\u8363"], [194971, 1, "\u83AD"], [194972, 1, "\u8323"], [194973, 1, "\u83BD"], [194974, 1, "\u83E7"], [194975, 1, "\u8457"], [194976, 1, "\u8353"], [194977, 1, "\u83CA"], [194978, 1, "\u83CC"], [194979, 1, "\u83DC"], [194980, 1, "\u{26C36}"], [194981, 1, "\u{26D6B}"], [194982, 1, "\u{26CD5}"], [194983, 1, "\u452B"], [194984, 1, "\u84F1"], [194985, 1, "\u84F3"], [194986, 1, "\u8516"], [194987, 1, "\u{273CA}"], [194988, 1, "\u8564"], [194989, 1, "\u{26F2C}"], [194990, 1, "\u455D"], [194991, 1, "\u4561"], [194992, 1, "\u{26FB1}"], [194993, 1, "\u{270D2}"], [194994, 1, "\u456B"], [194995, 1, "\u8650"], [194996, 1, "\u865C"], [194997, 1, "\u8667"], [194998, 1, "\u8669"], [194999, 1, "\u86A9"], [195e3, 1, "\u8688"], [195001, 1, "\u870E"], [195002, 1, "\u86E2"], [195003, 1, "\u8779"], [195004, 1, "\u8728"], [195005, 1, "\u876B"], [195006, 1, "\u8786"], [195007, 1, "\u45D7"], [195008, 1, "\u87E1"], [195009, 1, "\u8801"], [195010, 1, "\u45F9"], [195011, 1, "\u8860"], [195012, 1, "\u8863"], [195013, 1, "\u{27667}"], [195014, 1, "\u88D7"], [195015, 1, "\u88DE"], [195016, 1, "\u4635"], [195017, 1, "\u88FA"], [195018, 1, "\u34BB"], [195019, 1, "\u{278AE}"], [195020, 1, "\u{27966}"], [195021, 1, "\u46BE"], [195022, 1, "\u46C7"], [195023, 1, "\u8AA0"], [195024, 1, "\u8AED"], [195025, 1, "\u8B8A"], [195026, 1, "\u8C55"], [195027, 1, "\u{27CA8}"], [195028, 1, "\u8CAB"], [195029, 1, "\u8CC1"], [195030, 1, "\u8D1B"], [195031, 1, "\u8D77"], [195032, 1, "\u{27F2F}"], [195033, 1, "\u{20804}"], [195034, 1, "\u8DCB"], [195035, 1, "\u8DBC"], [195036, 1, "\u8DF0"], [195037, 1, "\u{208DE}"], [195038, 1, "\u8ED4"], [195039, 1, "\u8F38"], [195040, 1, "\u{285D2}"], [195041, 1, "\u{285ED}"], [195042, 1, "\u9094"], [195043, 1, "\u90F1"], [195044, 1, "\u9111"], [195045, 1, "\u{2872E}"], [195046, 1, "\u911B"], [195047, 1, "\u9238"], [195048, 1, "\u92D7"], [195049, 1, "\u92D8"], [195050, 1, "\u927C"], [195051, 1, "\u93F9"], [195052, 1, "\u9415"], [195053, 1, "\u{28BFA}"], [195054, 1, "\u958B"], [195055, 1, "\u4995"], [195056, 1, "\u95B7"], [195057, 1, "\u{28D77}"], [195058, 1, "\u49E6"], [195059, 1, "\u96C3"], [195060, 1, "\u5DB2"], [195061, 1, "\u9723"], [195062, 1, "\u{29145}"], [195063, 1, "\u{2921A}"], [195064, 1, "\u4A6E"], [195065, 1, "\u4A76"], [195066, 1, "\u97E0"], [195067, 1, "\u{2940A}"], [195068, 1, "\u4AB2"], [195069, 1, "\u{29496}"], [[195070, 195071], 1, "\u980B"], [195072, 1, "\u9829"], [195073, 1, "\u{295B6}"], [195074, 1, "\u98E2"], [195075, 1, "\u4B33"], [195076, 1, "\u9929"], [195077, 1, "\u99A7"], [195078, 1, "\u99C2"], [195079, 1, "\u99FE"], [195080, 1, "\u4BCE"], [195081, 1, "\u{29B30}"], [195082, 1, "\u9B12"], [195083, 1, "\u9C40"], [195084, 1, "\u9CFD"], [195085, 1, "\u4CCE"], [195086, 1, "\u4CED"], [195087, 1, "\u9D67"], [195088, 1, "\u{2A0CE}"], [195089, 1, "\u4CF8"], [195090, 1, "\u{2A105}"], [195091, 1, "\u{2A20E}"], [195092, 1, "\u{2A291}"], [195093, 1, "\u9EBB"], [195094, 1, "\u4D56"], [195095, 1, "\u9EF9"], [195096, 1, "\u9EFE"], [195097, 1, "\u9F05"], [195098, 1, "\u9F0F"], [195099, 1, "\u9F16"], [195100, 1, "\u9F3B"], [195101, 1, "\u{2A600}"], [[195102, 196605], 3], [[196606, 196607], 3], [[196608, 201546], 2], [[201547, 201551], 3], [[201552, 205743], 2], [[205744, 262141], 3], [[262142, 262143], 3], [[262144, 327677], 3], [[327678, 327679], 3], [[327680, 393213], 3], [[393214, 393215], 3], [[393216, 458749], 3], [[458750, 458751], 3], [[458752, 524285], 3], [[524286, 524287], 3], [[524288, 589821], 3], [[589822, 589823], 3], [[589824, 655357], 3], [[655358, 655359], 3], [[655360, 720893], 3], [[720894, 720895], 3], [[720896, 786429], 3], [[786430, 786431], 3], [[786432, 851965], 3], [[851966, 851967], 3], [[851968, 917501], 3], [[917502, 917503], 3], [917504, 3], [917505, 3], [[917506, 917535], 3], [[917536, 917631], 3], [[917632, 917759], 3], [[917760, 917999], 7], [[918e3, 983037], 3], [[983038, 983039], 3], [[983040, 1048573], 3], [[1048574, 1048575], 3], [[1048576, 1114109], 3], [[1114110, 1114111], 3]]; - } -}); - -// node_modules/tr46/lib/statusMapping.js -var require_statusMapping = __commonJS({ - "node_modules/tr46/lib/statusMapping.js"(exports2, module3) { - "use strict"; - module3.exports.STATUS_MAPPING = { - mapped: 1, - valid: 2, - disallowed: 3, - deviation: 6, - ignored: 7 - }; - } -}); - -// node_modules/tr46/index.js -var require_tr46 = __commonJS({ - "node_modules/tr46/index.js"(exports2, module3) { - "use strict"; - var punycode = require_punycode(); - var regexes = require_regexes(); - var mappingTable = require_mappingTable(); - var { STATUS_MAPPING } = require_statusMapping(); - function containsNonASCII(str) { - return /[^\x00-\x7F]/u.test(str); - } - function findStatus(val) { - let start = 0; - let end = mappingTable.length - 1; - while (start <= end) { - const mid = Math.floor((start + end) / 2); - const target = mappingTable[mid]; - const min2 = Array.isArray(target[0]) ? target[0][0] : target[0]; - const max2 = Array.isArray(target[0]) ? target[0][1] : target[0]; - if (min2 <= val && max2 >= val) { - return target.slice(1); - } else if (min2 > val) { - end = mid - 1; - } else { - start = mid + 1; - } - } - return null; - } - function mapChars(domainName, { transitionalProcessing }) { - let processed = ""; - for (const ch of domainName) { - const [status, mapping] = findStatus(ch.codePointAt(0)); - switch (status) { - case STATUS_MAPPING.disallowed: - processed += ch; - break; - case STATUS_MAPPING.ignored: - break; - case STATUS_MAPPING.mapped: - if (transitionalProcessing && ch === "\u1E9E") { - processed += "ss"; - } else { - processed += mapping; - } - break; - case STATUS_MAPPING.deviation: - if (transitionalProcessing) { - processed += mapping; - } else { - processed += ch; - } - break; - case STATUS_MAPPING.valid: - processed += ch; - break; - } - } - return processed; - } - function validateLabel(label, { - checkHyphens, - checkBidi, - checkJoiners, - transitionalProcessing, - useSTD3ASCIIRules, - isBidi - }) { - if (label.length === 0) { - return true; - } - if (label.normalize("NFC") !== label) { - return false; - } - const codePoints = Array.from(label); - if (checkHyphens) { - if (codePoints[2] === "-" && codePoints[3] === "-" || (label.startsWith("-") || label.endsWith("-"))) { - return false; - } - } - if (!checkHyphens) { - if (label.startsWith("xn--")) { - return false; - } - } - if (label.includes(".")) { - return false; - } - if (regexes.combiningMarks.test(codePoints[0])) { - return false; - } - for (const ch of codePoints) { - const codePoint = ch.codePointAt(0); - const [status] = findStatus(codePoint); - if (transitionalProcessing) { - if (status !== STATUS_MAPPING.valid) { - return false; - } - } else if (status !== STATUS_MAPPING.valid && status !== STATUS_MAPPING.deviation) { - return false; - } - if (useSTD3ASCIIRules && codePoint <= 127) { - if (!/^(?:[a-z]|[0-9]|-)$/u.test(ch)) { - return false; - } - } - } - if (checkJoiners) { - let last = 0; - for (const [i, ch] of codePoints.entries()) { - if (ch === "\u200C" || ch === "\u200D") { - if (i > 0) { - if (regexes.combiningClassVirama.test(codePoints[i - 1])) { - continue; - } - if (ch === "\u200C") { - const next = codePoints.indexOf("\u200C", i + 1); - const test = next < 0 ? codePoints.slice(last) : codePoints.slice(last, next); - if (regexes.validZWNJ.test(test.join(""))) { - last = i + 1; - continue; - } - } - } - return false; - } - } - } - if (checkBidi && isBidi) { - let rtl; - if (regexes.bidiS1LTR.test(codePoints[0])) { - rtl = false; - } else if (regexes.bidiS1RTL.test(codePoints[0])) { - rtl = true; - } else { - return false; - } - if (rtl) { - if (!regexes.bidiS2.test(label) || !regexes.bidiS3.test(label) || regexes.bidiS4EN.test(label) && regexes.bidiS4AN.test(label)) { - return false; - } - } else if (!regexes.bidiS5.test(label) || !regexes.bidiS6.test(label)) { - return false; - } - } - return true; - } - function isBidiDomain(labels) { - const domain = labels.map((label) => { - if (label.startsWith("xn--")) { - try { - return punycode.decode(label.substring(4)); - } catch { - return ""; - } - } - return label; - }).join("."); - return regexes.bidiDomain.test(domain); - } - function processing(domainName, options2) { - let string11 = mapChars(domainName, options2); - string11 = string11.normalize("NFC"); - const labels = string11.split("."); - const isBidi = isBidiDomain(labels); - let error4 = false; - for (const [i, origLabel] of labels.entries()) { - let label = origLabel; - let transitionalProcessingForThisLabel = options2.transitionalProcessing; - if (label.startsWith("xn--")) { - if (containsNonASCII(label)) { - error4 = true; - continue; - } - try { - label = punycode.decode(label.substring(4)); - } catch { - if (!options2.ignoreInvalidPunycode) { - error4 = true; - continue; - } - } - labels[i] = label; - if (label === "" || !containsNonASCII(label)) { - error4 = true; - } - transitionalProcessingForThisLabel = false; - } - if (error4) { - continue; - } - const validation = validateLabel(label, { - ...options2, - transitionalProcessing: transitionalProcessingForThisLabel, - isBidi - }); - if (!validation) { - error4 = true; - } - } - return { - string: labels.join("."), - error: error4 - }; - } - function toASCII(domainName, { - checkHyphens = false, - checkBidi = false, - checkJoiners = false, - useSTD3ASCIIRules = false, - verifyDNSLength = false, - transitionalProcessing = false, - ignoreInvalidPunycode = false - } = {}) { - const result = processing(domainName, { - checkHyphens, - checkBidi, - checkJoiners, - useSTD3ASCIIRules, - transitionalProcessing, - ignoreInvalidPunycode - }); - let labels = result.string.split("."); - labels = labels.map((l) => { - if (containsNonASCII(l)) { - try { - return `xn--${punycode.encode(l)}`; - } catch { - result.error = true; - } - } - return l; - }); - if (verifyDNSLength) { - const total = labels.join(".").length; - if (total > 253 || total === 0) { - result.error = true; - } - for (let i = 0; i < labels.length; ++i) { - if (labels[i].length > 63 || labels[i].length === 0) { - result.error = true; - break; - } - } - } - if (result.error) { - return null; - } - return labels.join("."); - } - function toUnicode(domainName, { - checkHyphens = false, - checkBidi = false, - checkJoiners = false, - useSTD3ASCIIRules = false, - transitionalProcessing = false, - ignoreInvalidPunycode = false - } = {}) { - const result = processing(domainName, { - checkHyphens, - checkBidi, - checkJoiners, - useSTD3ASCIIRules, - transitionalProcessing, - ignoreInvalidPunycode - }); - return { - domain: result.string, - error: result.error - }; - } - module3.exports = { - toASCII, - toUnicode - }; - } -}); - -// node_modules/whatwg-url/lib/infra.js -var require_infra = __commonJS({ - "node_modules/whatwg-url/lib/infra.js"(exports2, module3) { - "use strict"; - function isASCIIDigit(c) { - return c >= 48 && c <= 57; - } - function isASCIIAlpha(c) { - return c >= 65 && c <= 90 || c >= 97 && c <= 122; - } - function isASCIIAlphanumeric(c) { - return isASCIIAlpha(c) || isASCIIDigit(c); - } - function isASCIIHex(c) { - return isASCIIDigit(c) || c >= 65 && c <= 70 || c >= 97 && c <= 102; - } - module3.exports = { - isASCIIDigit, - isASCIIAlpha, - isASCIIAlphanumeric, - isASCIIHex - }; - } -}); - -// node_modules/whatwg-url/lib/encoding.js -var require_encoding = __commonJS({ - "node_modules/whatwg-url/lib/encoding.js"(exports2, module3) { - "use strict"; - var utf8Encoder = new TextEncoder(); - var utf8Decoder = new TextDecoder("utf-8", { ignoreBOM: true }); - function utf8Encode(string11) { - return utf8Encoder.encode(string11); - } - function utf8DecodeWithoutBOM(bytes) { - return utf8Decoder.decode(bytes); - } - module3.exports = { - utf8Encode, - utf8DecodeWithoutBOM - }; - } -}); - -// node_modules/whatwg-url/lib/percent-encoding.js -var require_percent_encoding = __commonJS({ - "node_modules/whatwg-url/lib/percent-encoding.js"(exports2, module3) { - "use strict"; - var { isASCIIHex } = require_infra(); - var { utf8Encode } = require_encoding(); - function p(char) { - return char.codePointAt(0); - } - function percentEncode(c) { - let hex = c.toString(16).toUpperCase(); - if (hex.length === 1) { - hex = `0${hex}`; - } - return `%${hex}`; - } - function percentDecodeBytes(input) { - const output = new Uint8Array(input.byteLength); - let outputIndex = 0; - for (let i = 0; i < input.byteLength; ++i) { - const byte = input[i]; - if (byte !== 37) { - output[outputIndex++] = byte; - } else if (byte === 37 && (!isASCIIHex(input[i + 1]) || !isASCIIHex(input[i + 2]))) { - output[outputIndex++] = byte; - } else { - const bytePoint = parseInt(String.fromCodePoint(input[i + 1], input[i + 2]), 16); - output[outputIndex++] = bytePoint; - i += 2; - } - } - return output.slice(0, outputIndex); - } - function percentDecodeString(input) { - const bytes = utf8Encode(input); - return percentDecodeBytes(bytes); - } - function isC0ControlPercentEncode(c) { - return c <= 31 || c > 126; - } - var extraFragmentPercentEncodeSet = /* @__PURE__ */ new Set([p(" "), p('"'), p("<"), p(">"), p("`")]); - function isFragmentPercentEncode(c) { - return isC0ControlPercentEncode(c) || extraFragmentPercentEncodeSet.has(c); - } - var extraQueryPercentEncodeSet = /* @__PURE__ */ new Set([p(" "), p('"'), p("#"), p("<"), p(">")]); - function isQueryPercentEncode(c) { - return isC0ControlPercentEncode(c) || extraQueryPercentEncodeSet.has(c); - } - function isSpecialQueryPercentEncode(c) { - return isQueryPercentEncode(c) || c === p("'"); - } - var extraPathPercentEncodeSet = /* @__PURE__ */ new Set([p("?"), p("`"), p("{"), p("}"), p("^")]); - function isPathPercentEncode(c) { - return isQueryPercentEncode(c) || extraPathPercentEncodeSet.has(c); - } - var extraUserinfoPercentEncodeSet = /* @__PURE__ */ new Set([p("/"), p(":"), p(";"), p("="), p("@"), p("["), p("\\"), p("]"), p("|")]); - function isUserinfoPercentEncode(c) { - return isPathPercentEncode(c) || extraUserinfoPercentEncodeSet.has(c); - } - var extraComponentPercentEncodeSet = /* @__PURE__ */ new Set([p("$"), p("%"), p("&"), p("+"), p(",")]); - function isComponentPercentEncode(c) { - return isUserinfoPercentEncode(c) || extraComponentPercentEncodeSet.has(c); - } - var extraURLEncodedPercentEncodeSet = /* @__PURE__ */ new Set([p("!"), p("'"), p("("), p(")"), p("~")]); - function isURLEncodedPercentEncode(c) { - return isComponentPercentEncode(c) || extraURLEncodedPercentEncodeSet.has(c); - } - function utf8PercentEncodeCodePointInternal(codePoint, percentEncodePredicate) { - const bytes = utf8Encode(codePoint); - let output = ""; - for (const byte of bytes) { - if (!percentEncodePredicate(byte)) { - output += String.fromCharCode(byte); - } else { - output += percentEncode(byte); - } - } - return output; - } - function utf8PercentEncodeCodePoint(codePoint, percentEncodePredicate) { - return utf8PercentEncodeCodePointInternal(String.fromCodePoint(codePoint), percentEncodePredicate); - } - function utf8PercentEncodeString(input, percentEncodePredicate, spaceAsPlus = false) { - let output = ""; - for (const codePoint of input) { - if (spaceAsPlus && codePoint === " ") { - output += "+"; - } else { - output += utf8PercentEncodeCodePointInternal(codePoint, percentEncodePredicate); - } - } - return output; - } - module3.exports = { - isC0ControlPercentEncode, - isFragmentPercentEncode, - isQueryPercentEncode, - isSpecialQueryPercentEncode, - isPathPercentEncode, - isUserinfoPercentEncode, - isURLEncodedPercentEncode, - percentDecodeString, - percentDecodeBytes, - utf8PercentEncodeString, - utf8PercentEncodeCodePoint - }; - } -}); - -// node_modules/whatwg-url/lib/url-state-machine.js -var require_url_state_machine = __commonJS({ - "node_modules/whatwg-url/lib/url-state-machine.js"(exports2, module3) { - "use strict"; - var tr46 = require_tr46(); - var infra = require_infra(); - var { utf8DecodeWithoutBOM } = require_encoding(); - var { - percentDecodeString, - utf8PercentEncodeCodePoint, - utf8PercentEncodeString, - isC0ControlPercentEncode, - isFragmentPercentEncode, - isQueryPercentEncode, - isSpecialQueryPercentEncode, - isPathPercentEncode, - isUserinfoPercentEncode - } = require_percent_encoding(); - function p(char) { - return char.codePointAt(0); - } - var specialSchemes = { - ftp: 21, - file: null, - http: 80, - https: 443, - ws: 80, - wss: 443 - }; - var failure = Symbol("failure"); - function countSymbols(str) { - return [...str].length; - } - function at(input, idx) { - const c = input[idx]; - return isNaN(c) ? void 0 : String.fromCodePoint(c); - } - function isSingleDot(buffer) { - return buffer === "." || buffer.toLowerCase() === "%2e"; - } - function isDoubleDot(buffer) { - buffer = buffer.toLowerCase(); - return buffer === ".." || buffer === "%2e." || buffer === ".%2e" || buffer === "%2e%2e"; - } - function isWindowsDriveLetterCodePoints(cp1, cp2) { - return infra.isASCIIAlpha(cp1) && (cp2 === p(":") || cp2 === p("|")); - } - function isWindowsDriveLetterString(string11) { - return string11.length === 2 && infra.isASCIIAlpha(string11.codePointAt(0)) && (string11[1] === ":" || string11[1] === "|"); - } - function isNormalizedWindowsDriveLetterString(string11) { - return string11.length === 2 && infra.isASCIIAlpha(string11.codePointAt(0)) && string11[1] === ":"; - } - function containsForbiddenHostCodePoint(string11) { - return string11.search(/\u0000|\u0009|\u000A|\u000D|\u0020|#|\/|:|<|>|\?|@|\[|\\|\]|\^|\|/u) !== -1; - } - function containsForbiddenDomainCodePoint(string11) { - return containsForbiddenHostCodePoint(string11) || string11.search(/[\u0000-\u001F]|%|\u007F/u) !== -1; - } - function isSpecialScheme(scheme) { - return specialSchemes[scheme] !== void 0; - } - function isSpecial(url2) { - return isSpecialScheme(url2.scheme); - } - function isNotSpecial(url2) { - return !isSpecialScheme(url2.scheme); - } - function defaultPort(scheme) { - return specialSchemes[scheme]; - } - function parseIPv4Number(input) { - if (input === "") { - return failure; - } - let R = 10; - if (input.length >= 2 && input.charAt(0) === "0" && input.charAt(1).toLowerCase() === "x") { - input = input.substring(2); - R = 16; - } else if (input.length >= 2 && input.charAt(0) === "0") { - input = input.substring(1); - R = 8; - } - if (input === "") { - return 0; - } - let regex = /[^0-7]/u; - if (R === 10) { - regex = /[^0-9]/u; - } - if (R === 16) { - regex = /[^0-9A-Fa-f]/u; - } - if (regex.test(input)) { - return failure; - } - return parseInt(input, R); - } - function parseIPv4(input) { - const parts = input.split("."); - if (parts[parts.length - 1] === "") { - if (parts.length > 1) { - parts.pop(); - } - } - if (parts.length > 4) { - return failure; - } - const numbers = []; - for (const part of parts) { - const n = parseIPv4Number(part); - if (n === failure) { - return failure; - } - numbers.push(n); - } - for (let i = 0; i < numbers.length - 1; ++i) { - if (numbers[i] > 255) { - return failure; - } - } - if (numbers[numbers.length - 1] >= 256 ** (5 - numbers.length)) { - return failure; - } - let ipv4 = numbers.pop(); - let counter = 0; - for (const n of numbers) { - ipv4 += n * 256 ** (3 - counter); - ++counter; - } - return ipv4; - } - function serializeIPv4(address) { - let output = ""; - let n = address; - for (let i = 1; i <= 4; ++i) { - output = String(n % 256) + output; - if (i !== 4) { - output = `.${output}`; - } - n = Math.floor(n / 256); - } - return output; - } - function parseIPv6(input) { - const address = [0, 0, 0, 0, 0, 0, 0, 0]; - let pieceIndex = 0; - let compress = null; - let pointer = 0; - input = Array.from(input, (c) => c.codePointAt(0)); - if (input[pointer] === p(":")) { - if (input[pointer + 1] !== p(":")) { - return failure; - } - pointer += 2; - ++pieceIndex; - compress = pieceIndex; - } - while (pointer < input.length) { - if (pieceIndex === 8) { - return failure; - } - if (input[pointer] === p(":")) { - if (compress !== null) { - return failure; - } - ++pointer; - ++pieceIndex; - compress = pieceIndex; - continue; - } - let value = 0; - let length = 0; - while (length < 4 && infra.isASCIIHex(input[pointer])) { - value = value * 16 + parseInt(at(input, pointer), 16); - ++pointer; - ++length; - } - if (input[pointer] === p(".")) { - if (length === 0) { - return failure; - } - pointer -= length; - if (pieceIndex > 6) { - return failure; - } - let numbersSeen = 0; - while (input[pointer] !== void 0) { - let ipv4Piece = null; - if (numbersSeen > 0) { - if (input[pointer] === p(".") && numbersSeen < 4) { - ++pointer; - } else { - return failure; - } - } - if (!infra.isASCIIDigit(input[pointer])) { - return failure; - } - while (infra.isASCIIDigit(input[pointer])) { - const number5 = parseInt(at(input, pointer)); - if (ipv4Piece === null) { - ipv4Piece = number5; - } else if (ipv4Piece === 0) { - return failure; - } else { - ipv4Piece = ipv4Piece * 10 + number5; - } - if (ipv4Piece > 255) { - return failure; - } - ++pointer; - } - address[pieceIndex] = address[pieceIndex] * 256 + ipv4Piece; - ++numbersSeen; - if (numbersSeen === 2 || numbersSeen === 4) { - ++pieceIndex; - } - } - if (numbersSeen !== 4) { - return failure; - } - break; - } else if (input[pointer] === p(":")) { - ++pointer; - if (input[pointer] === void 0) { - return failure; - } - } else if (input[pointer] !== void 0) { - return failure; - } - address[pieceIndex] = value; - ++pieceIndex; - } - if (compress !== null) { - let swaps = pieceIndex - compress; - pieceIndex = 7; - while (pieceIndex !== 0 && swaps > 0) { - const temp = address[compress + swaps - 1]; - address[compress + swaps - 1] = address[pieceIndex]; - address[pieceIndex] = temp; - --pieceIndex; - --swaps; - } - } else if (compress === null && pieceIndex !== 8) { - return failure; - } - return address; - } - function serializeIPv6(address) { - let output = ""; - const compress = findTheIPv6AddressCompressedPieceIndex(address); - let ignore0 = false; - for (let pieceIndex = 0; pieceIndex <= 7; ++pieceIndex) { - if (ignore0 && address[pieceIndex] === 0) { - continue; - } else if (ignore0) { - ignore0 = false; - } - if (compress === pieceIndex) { - const separator = pieceIndex === 0 ? "::" : ":"; - output += separator; - ignore0 = true; - continue; - } - output += address[pieceIndex].toString(16); - if (pieceIndex !== 7) { - output += ":"; - } - } - return output; - } - function parseHost(input, isOpaque = false) { - if (input[0] === "[") { - if (input[input.length - 1] !== "]") { - return failure; - } - return parseIPv6(input.substring(1, input.length - 1)); - } - if (isOpaque) { - return parseOpaqueHost(input); - } - const domain = utf8DecodeWithoutBOM(percentDecodeString(input)); - const asciiDomain = domainToASCII(domain); - if (asciiDomain === failure) { - return failure; - } - if (endsInANumber(asciiDomain)) { - return parseIPv4(asciiDomain); - } - return asciiDomain; - } - function endsInANumber(input) { - const parts = input.split("."); - if (parts[parts.length - 1] === "") { - if (parts.length === 1) { - return false; - } - parts.pop(); - } - const last = parts[parts.length - 1]; - if (parseIPv4Number(last) !== failure) { - return true; - } - if (/^[0-9]+$/u.test(last)) { - return true; - } - return false; - } - function parseOpaqueHost(input) { - if (containsForbiddenHostCodePoint(input)) { - return failure; - } - return utf8PercentEncodeString(input, isC0ControlPercentEncode); - } - function findTheIPv6AddressCompressedPieceIndex(address) { - let longestIndex = null; - let longestSize = 1; - let foundIndex = null; - let foundSize = 0; - for (let pieceIndex = 0; pieceIndex < address.length; ++pieceIndex) { - if (address[pieceIndex] !== 0) { - if (foundSize > longestSize) { - longestIndex = foundIndex; - longestSize = foundSize; - } - foundIndex = null; - foundSize = 0; - } else { - if (foundIndex === null) { - foundIndex = pieceIndex; - } - ++foundSize; - } - } - if (foundSize > longestSize) { - return foundIndex; - } - return longestIndex; - } - function serializeHost(host) { - if (typeof host === "number") { - return serializeIPv4(host); - } - if (host instanceof Array) { - return `[${serializeIPv6(host)}]`; - } - return host; - } - function domainToASCII(domain, beStrict = false) { - const result = tr46.toASCII(domain, { - checkHyphens: beStrict, - checkBidi: true, - checkJoiners: true, - useSTD3ASCIIRules: beStrict, - transitionalProcessing: false, - verifyDNSLength: beStrict, - ignoreInvalidPunycode: false - }); - if (result === null) { - return failure; - } - if (!beStrict) { - if (result === "") { - return failure; - } - if (containsForbiddenDomainCodePoint(result)) { - return failure; - } - } - return result; - } - function trimControlChars(string11) { - let start = 0; - let end = string11.length; - for (; start < end; ++start) { - if (string11.charCodeAt(start) > 32) { - break; - } - } - for (; end > start; --end) { - if (string11.charCodeAt(end - 1) > 32) { - break; - } - } - return string11.substring(start, end); - } - function trimTabAndNewline(url2) { - return url2.replace(/\u0009|\u000A|\u000D/ug, ""); - } - function shortenPath(url2) { - const { path: path6 } = url2; - if (path6.length === 0) { - return; - } - if (url2.scheme === "file" && path6.length === 1 && isNormalizedWindowsDriveLetter(path6[0])) { - return; - } - path6.pop(); - } - function includesCredentials(url2) { - return url2.username !== "" || url2.password !== ""; - } - function cannotHaveAUsernamePasswordPort(url2) { - return url2.host === null || url2.host === "" || url2.scheme === "file"; - } - function hasAnOpaquePath(url2) { - return typeof url2.path === "string"; - } - function isNormalizedWindowsDriveLetter(string11) { - return /^[A-Za-z]:$/u.test(string11); - } - function URLStateMachine(input, base, encodingOverride, url2, stateOverride) { - this.pointer = 0; - this.input = input; - this.base = base || null; - this.encodingOverride = encodingOverride || "utf-8"; - this.stateOverride = stateOverride; - this.url = url2; - this.failure = false; - this.parseError = false; - if (!this.url) { - this.url = { - scheme: "", - username: "", - password: "", - host: null, - port: null, - path: [], - query: null, - fragment: null - }; - const res2 = trimControlChars(this.input); - if (res2 !== this.input) { - this.parseError = true; - } - this.input = res2; - } - const res = trimTabAndNewline(this.input); - if (res !== this.input) { - this.parseError = true; - } - this.input = res; - this.state = stateOverride || "scheme start"; - this.buffer = ""; - this.atFlag = false; - this.arrFlag = false; - this.passwordTokenSeenFlag = false; - this.input = Array.from(this.input, (c) => c.codePointAt(0)); - for (; this.pointer <= this.input.length; ++this.pointer) { - const c = this.input[this.pointer]; - const cStr = isNaN(c) ? void 0 : String.fromCodePoint(c); - const ret = this[`parse ${this.state}`](c, cStr); - if (!ret) { - break; - } else if (ret === failure) { - this.failure = true; - break; - } - } - } - URLStateMachine.prototype["parse scheme start"] = function parseSchemeStart(c, cStr) { - if (infra.isASCIIAlpha(c)) { - this.buffer += cStr.toLowerCase(); - this.state = "scheme"; - } else if (!this.stateOverride) { - this.state = "no scheme"; - --this.pointer; - } else { - this.parseError = true; - return failure; - } - return true; - }; - URLStateMachine.prototype["parse scheme"] = function parseScheme(c, cStr) { - if (infra.isASCIIAlphanumeric(c) || c === p("+") || c === p("-") || c === p(".")) { - this.buffer += cStr.toLowerCase(); - } else if (c === p(":")) { - if (this.stateOverride) { - if (isSpecial(this.url) && !isSpecialScheme(this.buffer)) { - return false; - } - if (!isSpecial(this.url) && isSpecialScheme(this.buffer)) { - return false; - } - if ((includesCredentials(this.url) || this.url.port !== null) && this.buffer === "file") { - return false; - } - if (this.url.scheme === "file" && this.url.host === "") { - return false; - } - } - this.url.scheme = this.buffer; - if (this.stateOverride) { - if (this.url.port === defaultPort(this.url.scheme)) { - this.url.port = null; - } - return false; - } - this.buffer = ""; - if (this.url.scheme === "file") { - if (this.input[this.pointer + 1] !== p("/") || this.input[this.pointer + 2] !== p("/")) { - this.parseError = true; - } - this.state = "file"; - } else if (isSpecial(this.url) && this.base !== null && this.base.scheme === this.url.scheme) { - this.state = "special relative or authority"; - } else if (isSpecial(this.url)) { - this.state = "special authority slashes"; - } else if (this.input[this.pointer + 1] === p("/")) { - this.state = "path or authority"; - ++this.pointer; - } else { - this.url.path = ""; - this.state = "opaque path"; - } - } else if (!this.stateOverride) { - this.buffer = ""; - this.state = "no scheme"; - this.pointer = -1; - } else { - this.parseError = true; - return failure; - } - return true; - }; - URLStateMachine.prototype["parse no scheme"] = function parseNoScheme(c) { - if (this.base === null || hasAnOpaquePath(this.base) && c !== p("#")) { - return failure; - } else if (hasAnOpaquePath(this.base) && c === p("#")) { - this.url.scheme = this.base.scheme; - this.url.path = this.base.path; - this.url.query = this.base.query; - this.url.fragment = ""; - this.state = "fragment"; - } else if (this.base.scheme === "file") { - this.state = "file"; - --this.pointer; - } else { - this.state = "relative"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse special relative or authority"] = function parseSpecialRelativeOrAuthority(c) { - if (c === p("/") && this.input[this.pointer + 1] === p("/")) { - this.state = "special authority ignore slashes"; - ++this.pointer; - } else { - this.parseError = true; - this.state = "relative"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse path or authority"] = function parsePathOrAuthority(c) { - if (c === p("/")) { - this.state = "authority"; - } else { - this.state = "path"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse relative"] = function parseRelative(c) { - this.url.scheme = this.base.scheme; - if (c === p("/")) { - this.state = "relative slash"; - } else if (isSpecial(this.url) && c === p("\\")) { - this.parseError = true; - this.state = "relative slash"; - } else { - this.url.username = this.base.username; - this.url.password = this.base.password; - this.url.host = this.base.host; - this.url.port = this.base.port; - this.url.path = this.base.path.slice(); - this.url.query = this.base.query; - if (c === p("?")) { - this.url.query = ""; - this.state = "query"; - } else if (c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } else if (!isNaN(c)) { - this.url.query = null; - this.url.path.pop(); - this.state = "path"; - --this.pointer; - } - } - return true; - }; - URLStateMachine.prototype["parse relative slash"] = function parseRelativeSlash(c) { - if (isSpecial(this.url) && (c === p("/") || c === p("\\"))) { - if (c === p("\\")) { - this.parseError = true; - } - this.state = "special authority ignore slashes"; - } else if (c === p("/")) { - this.state = "authority"; - } else { - this.url.username = this.base.username; - this.url.password = this.base.password; - this.url.host = this.base.host; - this.url.port = this.base.port; - this.state = "path"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse special authority slashes"] = function parseSpecialAuthoritySlashes(c) { - if (c === p("/") && this.input[this.pointer + 1] === p("/")) { - this.state = "special authority ignore slashes"; - ++this.pointer; - } else { - this.parseError = true; - this.state = "special authority ignore slashes"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse special authority ignore slashes"] = function parseSpecialAuthorityIgnoreSlashes(c) { - if (c !== p("/") && c !== p("\\")) { - this.state = "authority"; - --this.pointer; - } else { - this.parseError = true; - } - return true; - }; - URLStateMachine.prototype["parse authority"] = function parseAuthority(c, cStr) { - if (c === p("@")) { - this.parseError = true; - if (this.atFlag) { - this.buffer = `%40${this.buffer}`; - } - this.atFlag = true; - const len = countSymbols(this.buffer); - for (let pointer = 0; pointer < len; ++pointer) { - const codePoint = this.buffer.codePointAt(pointer); - if (codePoint === p(":") && !this.passwordTokenSeenFlag) { - this.passwordTokenSeenFlag = true; - continue; - } - const encodedCodePoints = utf8PercentEncodeCodePoint(codePoint, isUserinfoPercentEncode); - if (this.passwordTokenSeenFlag) { - this.url.password += encodedCodePoints; - } else { - this.url.username += encodedCodePoints; - } - } - this.buffer = ""; - } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\")) { - if (this.atFlag && this.buffer === "") { - this.parseError = true; - return failure; - } - this.pointer -= countSymbols(this.buffer) + 1; - this.buffer = ""; - this.state = "host"; - } else { - this.buffer += cStr; - } - return true; - }; - URLStateMachine.prototype["parse hostname"] = URLStateMachine.prototype["parse host"] = function parseHostName(c, cStr) { - if (this.stateOverride && this.url.scheme === "file") { - --this.pointer; - this.state = "file host"; - } else if (c === p(":") && !this.arrFlag) { - if (this.buffer === "") { - this.parseError = true; - return failure; - } - if (this.stateOverride === "hostname") { - return false; - } - const host = parseHost(this.buffer, isNotSpecial(this.url)); - if (host === failure) { - return failure; - } - this.url.host = host; - this.buffer = ""; - this.state = "port"; - } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\")) { - --this.pointer; - if (isSpecial(this.url) && this.buffer === "") { - this.parseError = true; - return failure; - } else if (this.stateOverride && this.buffer === "" && (includesCredentials(this.url) || this.url.port !== null)) { - this.parseError = true; - return false; - } - const host = parseHost(this.buffer, isNotSpecial(this.url)); - if (host === failure) { - return failure; - } - this.url.host = host; - this.buffer = ""; - this.state = "path start"; - if (this.stateOverride) { - return false; - } - } else { - if (c === p("[")) { - this.arrFlag = true; - } else if (c === p("]")) { - this.arrFlag = false; - } - this.buffer += cStr; - } - return true; - }; - URLStateMachine.prototype["parse port"] = function parsePort(c, cStr) { - if (infra.isASCIIDigit(c)) { - this.buffer += cStr; - } else if (isNaN(c) || c === p("/") || c === p("?") || c === p("#") || isSpecial(this.url) && c === p("\\") || this.stateOverride) { - if (this.buffer !== "") { - const port = parseInt(this.buffer); - if (port > 2 ** 16 - 1) { - this.parseError = true; - return failure; - } - this.url.port = port === defaultPort(this.url.scheme) ? null : port; - this.buffer = ""; - } - if (this.stateOverride) { - return false; - } - this.state = "path start"; - --this.pointer; - } else { - this.parseError = true; - return failure; - } - return true; - }; - var fileOtherwiseCodePoints = /* @__PURE__ */ new Set([p("/"), p("\\"), p("?"), p("#")]); - function startsWithWindowsDriveLetter(input, pointer) { - const length = input.length - pointer; - return length >= 2 && isWindowsDriveLetterCodePoints(input[pointer], input[pointer + 1]) && (length === 2 || fileOtherwiseCodePoints.has(input[pointer + 2])); - } - URLStateMachine.prototype["parse file"] = function parseFile(c) { - this.url.scheme = "file"; - this.url.host = ""; - if (c === p("/") || c === p("\\")) { - if (c === p("\\")) { - this.parseError = true; - } - this.state = "file slash"; - } else if (this.base !== null && this.base.scheme === "file") { - this.url.host = this.base.host; - this.url.path = this.base.path.slice(); - this.url.query = this.base.query; - if (c === p("?")) { - this.url.query = ""; - this.state = "query"; - } else if (c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } else if (!isNaN(c)) { - this.url.query = null; - if (!startsWithWindowsDriveLetter(this.input, this.pointer)) { - shortenPath(this.url); - } else { - this.parseError = true; - this.url.path = []; - } - this.state = "path"; - --this.pointer; - } - } else { - this.state = "path"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse file slash"] = function parseFileSlash(c) { - if (c === p("/") || c === p("\\")) { - if (c === p("\\")) { - this.parseError = true; - } - this.state = "file host"; - } else { - if (this.base !== null && this.base.scheme === "file") { - if (!startsWithWindowsDriveLetter(this.input, this.pointer) && isNormalizedWindowsDriveLetterString(this.base.path[0])) { - this.url.path.push(this.base.path[0]); - } - this.url.host = this.base.host; - } - this.state = "path"; - --this.pointer; - } - return true; - }; - URLStateMachine.prototype["parse file host"] = function parseFileHost(c, cStr) { - if (isNaN(c) || c === p("/") || c === p("\\") || c === p("?") || c === p("#")) { - --this.pointer; - if (!this.stateOverride && isWindowsDriveLetterString(this.buffer)) { - this.parseError = true; - this.state = "path"; - } else if (this.buffer === "") { - this.url.host = ""; - if (this.stateOverride) { - return false; - } - this.state = "path start"; - } else { - let host = parseHost(this.buffer, isNotSpecial(this.url)); - if (host === failure) { - return failure; - } - if (host === "localhost") { - host = ""; - } - this.url.host = host; - if (this.stateOverride) { - return false; - } - this.buffer = ""; - this.state = "path start"; - } - } else { - this.buffer += cStr; - } - return true; - }; - URLStateMachine.prototype["parse path start"] = function parsePathStart(c) { - if (isSpecial(this.url)) { - if (c === p("\\")) { - this.parseError = true; - } - this.state = "path"; - if (c !== p("/") && c !== p("\\")) { - --this.pointer; - } - } else if (!this.stateOverride && c === p("?")) { - this.url.query = ""; - this.state = "query"; - } else if (!this.stateOverride && c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } else if (c !== void 0) { - this.state = "path"; - if (c !== p("/")) { - --this.pointer; - } - } else if (this.stateOverride && this.url.host === null) { - this.url.path.push(""); - } - return true; - }; - URLStateMachine.prototype["parse path"] = function parsePath(c) { - if (isNaN(c) || c === p("/") || isSpecial(this.url) && c === p("\\") || !this.stateOverride && (c === p("?") || c === p("#"))) { - if (isSpecial(this.url) && c === p("\\")) { - this.parseError = true; - } - if (isDoubleDot(this.buffer)) { - shortenPath(this.url); - if (c !== p("/") && !(isSpecial(this.url) && c === p("\\"))) { - this.url.path.push(""); - } - } else if (isSingleDot(this.buffer) && c !== p("/") && !(isSpecial(this.url) && c === p("\\"))) { - this.url.path.push(""); - } else if (!isSingleDot(this.buffer)) { - if (this.url.scheme === "file" && this.url.path.length === 0 && isWindowsDriveLetterString(this.buffer)) { - this.buffer = `${this.buffer[0]}:`; - } - this.url.path.push(this.buffer); - } - this.buffer = ""; - if (c === p("?")) { - this.url.query = ""; - this.state = "query"; - } - if (c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } - } else { - if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { - this.parseError = true; - } - this.buffer += utf8PercentEncodeCodePoint(c, isPathPercentEncode); - } - return true; - }; - URLStateMachine.prototype["parse opaque path"] = function parseOpaquePath(c) { - if (c === p("?")) { - this.url.query = ""; - this.state = "query"; - } else if (c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } else if (c === p(" ")) { - const remaining = this.input[this.pointer + 1]; - if (remaining === p("?") || remaining === p("#")) { - this.url.path += "%20"; - } else { - this.url.path += " "; - } - } else { - if (!isNaN(c) && c !== p("%")) { - this.parseError = true; - } - if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { - this.parseError = true; - } - if (!isNaN(c)) { - this.url.path += utf8PercentEncodeCodePoint(c, isC0ControlPercentEncode); - } - } - return true; - }; - URLStateMachine.prototype["parse query"] = function parseQuery(c, cStr) { - if (!isSpecial(this.url) || this.url.scheme === "ws" || this.url.scheme === "wss") { - this.encodingOverride = "utf-8"; - } - if (!this.stateOverride && c === p("#") || isNaN(c)) { - const queryPercentEncodePredicate = isSpecial(this.url) ? isSpecialQueryPercentEncode : isQueryPercentEncode; - this.url.query += utf8PercentEncodeString(this.buffer, queryPercentEncodePredicate); - this.buffer = ""; - if (c === p("#")) { - this.url.fragment = ""; - this.state = "fragment"; - } - } else if (!isNaN(c)) { - if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { - this.parseError = true; - } - this.buffer += cStr; - } - return true; - }; - URLStateMachine.prototype["parse fragment"] = function parseFragment(c) { - if (!isNaN(c)) { - if (c === p("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) { - this.parseError = true; - } - this.url.fragment += utf8PercentEncodeCodePoint(c, isFragmentPercentEncode); - } - return true; - }; - function serializeURL(url2, excludeFragment) { - let output = `${url2.scheme}:`; - if (url2.host !== null) { - output += "//"; - if (url2.username !== "" || url2.password !== "") { - output += url2.username; - if (url2.password !== "") { - output += `:${url2.password}`; - } - output += "@"; - } - output += serializeHost(url2.host); - if (url2.port !== null) { - output += `:${url2.port}`; - } - } - if (url2.host === null && !hasAnOpaquePath(url2) && url2.path.length > 1 && url2.path[0] === "") { - output += "/."; - } - output += serializePath(url2); - if (url2.query !== null) { - output += `?${url2.query}`; - } - if (!excludeFragment && url2.fragment !== null) { - output += `#${url2.fragment}`; - } - return output; - } - function serializeOrigin(tuple) { - let result = `${tuple.scheme}://`; - result += serializeHost(tuple.host); - if (tuple.port !== null) { - result += `:${tuple.port}`; - } - return result; - } - function serializePath(url2) { - if (hasAnOpaquePath(url2)) { - return url2.path; - } - let output = ""; - for (const segment of url2.path) { - output += `/${segment}`; - } - return output; - } - module3.exports.serializeURL = serializeURL; - module3.exports.serializePath = serializePath; - module3.exports.serializeURLOrigin = function(url2) { - switch (url2.scheme) { - case "blob": { - const pathURL = module3.exports.parseURL(serializePath(url2)); - if (pathURL === null) { - return "null"; - } - if (pathURL.scheme !== "http" && pathURL.scheme !== "https") { - return "null"; - } - return module3.exports.serializeURLOrigin(pathURL); - } - case "ftp": - case "http": - case "https": - case "ws": - case "wss": - return serializeOrigin({ - scheme: url2.scheme, - host: url2.host, - port: url2.port - }); - case "file": - return "null"; - default: - return "null"; - } - }; - module3.exports.basicURLParse = function(input, options2) { - if (options2 === void 0) { - options2 = {}; - } - const usm = new URLStateMachine(input, options2.baseURL, options2.encodingOverride, options2.url, options2.stateOverride); - if (usm.failure) { - return null; - } - return usm.url; - }; - module3.exports.setTheUsername = function(url2, username) { - url2.username = utf8PercentEncodeString(username, isUserinfoPercentEncode); - }; - module3.exports.setThePassword = function(url2, password) { - url2.password = utf8PercentEncodeString(password, isUserinfoPercentEncode); - }; - module3.exports.serializeHost = serializeHost; - module3.exports.cannotHaveAUsernamePasswordPort = cannotHaveAUsernamePasswordPort; - module3.exports.hasAnOpaquePath = hasAnOpaquePath; - module3.exports.serializeInteger = function(integer5) { - return String(integer5); - }; - module3.exports.parseURL = function(input, options2) { - if (options2 === void 0) { - options2 = {}; - } - return module3.exports.basicURLParse(input, { baseURL: options2.baseURL, encodingOverride: options2.encodingOverride }); - }; - } -}); - -// node_modules/whatwg-url/lib/urlencoded.js -var require_urlencoded = __commonJS({ - "node_modules/whatwg-url/lib/urlencoded.js"(exports2, module3) { - "use strict"; - var { utf8Encode, utf8DecodeWithoutBOM } = require_encoding(); - var { percentDecodeBytes, utf8PercentEncodeString, isURLEncodedPercentEncode } = require_percent_encoding(); - function p(char) { - return char.codePointAt(0); - } - function parseUrlencoded(input) { - const sequences = strictlySplitByteSequence(input, p("&")); - const output = []; - for (const bytes of sequences) { - if (bytes.length === 0) { - continue; - } - let name, value; - const indexOfEqual = bytes.indexOf(p("=")); - if (indexOfEqual >= 0) { - name = bytes.slice(0, indexOfEqual); - value = bytes.slice(indexOfEqual + 1); - } else { - name = bytes; - value = new Uint8Array(0); - } - name = replaceByteInByteSequence(name, 43, 32); - value = replaceByteInByteSequence(value, 43, 32); - const nameString = utf8DecodeWithoutBOM(percentDecodeBytes(name)); - const valueString = utf8DecodeWithoutBOM(percentDecodeBytes(value)); - output.push([nameString, valueString]); - } - return output; - } - function parseUrlencodedString(input) { - return parseUrlencoded(utf8Encode(input)); - } - function serializeUrlencoded(tuples) { - let output = ""; - for (const [i, tuple] of tuples.entries()) { - const name = utf8PercentEncodeString(tuple[0], isURLEncodedPercentEncode, true); - const value = utf8PercentEncodeString(tuple[1], isURLEncodedPercentEncode, true); - if (i !== 0) { - output += "&"; - } - output += `${name}=${value}`; - } - return output; - } - function strictlySplitByteSequence(buf, cp2) { - const list4 = []; - let last = 0; - let i = buf.indexOf(cp2); - while (i >= 0) { - list4.push(buf.slice(last, i)); - last = i + 1; - i = buf.indexOf(cp2, last); - } - if (last !== buf.length) { - list4.push(buf.slice(last)); - } - return list4; - } - function replaceByteInByteSequence(buf, from, to) { - let i = buf.indexOf(from); - while (i >= 0) { - buf[i] = to; - i = buf.indexOf(from, i + 1); - } - return buf; - } - module3.exports = { - parseUrlencodedString, - serializeUrlencoded - }; - } -}); - -// node_modules/whatwg-url/lib/Function.js -var require_Function = __commonJS({ - "node_modules/whatwg-url/lib/Function.js"(exports2) { - "use strict"; - var conversions = require_lib(); - var utils = require_utils(); - exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { - if (typeof value !== "function") { - throw new globalObject.TypeError(context + " is not a function"); - } - function invokeTheCallbackFunction(...args) { - const thisArg = utils.tryWrapperForImpl(this); - let callResult; - for (let i = 0; i < args.length; i++) { - args[i] = utils.tryWrapperForImpl(args[i]); - } - callResult = Reflect.apply(value, thisArg, args); - callResult = conversions["any"](callResult, { context, globals: globalObject }); - return callResult; - } - invokeTheCallbackFunction.construct = (...args) => { - for (let i = 0; i < args.length; i++) { - args[i] = utils.tryWrapperForImpl(args[i]); - } - let callResult = Reflect.construct(value, args); - callResult = conversions["any"](callResult, { context, globals: globalObject }); - return callResult; - }; - invokeTheCallbackFunction[utils.wrapperSymbol] = value; - invokeTheCallbackFunction.objectReference = value; - return invokeTheCallbackFunction; - }; - } -}); - -// node_modules/whatwg-url/lib/URLSearchParams-impl.js -var require_URLSearchParams_impl = __commonJS({ - "node_modules/whatwg-url/lib/URLSearchParams-impl.js"(exports2) { - "use strict"; - var urlencoded = require_urlencoded(); - exports2.implementation = class URLSearchParamsImpl { - constructor(globalObject, constructorArgs, { doNotStripQMark = false }) { - let init = constructorArgs[0]; - this._list = []; - this._url = null; - if (!doNotStripQMark && typeof init === "string" && init[0] === "?") { - init = init.slice(1); - } - if (Array.isArray(init)) { - for (const pair of init) { - if (pair.length !== 2) { - throw new TypeError("Failed to construct 'URLSearchParams': parameter 1 sequence's element does not contain exactly two elements."); - } - this._list.push([pair[0], pair[1]]); - } - } else if (typeof init === "object" && Object.getPrototypeOf(init) === null) { - for (const name of Object.keys(init)) { - const value = init[name]; - this._list.push([name, value]); - } - } else { - this._list = urlencoded.parseUrlencodedString(init); - } - } - _updateSteps() { - if (this._url !== null) { - let serializedQuery = urlencoded.serializeUrlencoded(this._list); - if (serializedQuery === "") { - serializedQuery = null; - } - this._url._url.query = serializedQuery; - } - } - get size() { - return this._list.length; - } - append(name, value) { - this._list.push([name, value]); - this._updateSteps(); - } - delete(name, value) { - let i = 0; - while (i < this._list.length) { - if (this._list[i][0] === name && (value === void 0 || this._list[i][1] === value)) { - this._list.splice(i, 1); - } else { - i++; - } - } - this._updateSteps(); - } - get(name) { - for (const tuple of this._list) { - if (tuple[0] === name) { - return tuple[1]; - } - } - return null; - } - getAll(name) { - const output = []; - for (const tuple of this._list) { - if (tuple[0] === name) { - output.push(tuple[1]); - } - } - return output; - } - has(name, value) { - for (const tuple of this._list) { - if (tuple[0] === name && (value === void 0 || tuple[1] === value)) { - return true; - } - } - return false; - } - set(name, value) { - let found = false; - let i = 0; - while (i < this._list.length) { - if (this._list[i][0] === name) { - if (found) { - this._list.splice(i, 1); - } else { - found = true; - this._list[i][1] = value; - i++; - } - } else { - i++; - } - } - if (!found) { - this._list.push([name, value]); - } - this._updateSteps(); - } - sort() { - this._list.sort((a, b) => { - if (a[0] < b[0]) { - return -1; - } - if (a[0] > b[0]) { - return 1; - } - return 0; - }); - this._updateSteps(); - } - [Symbol.iterator]() { - return this._list[Symbol.iterator](); - } - toString() { - return urlencoded.serializeUrlencoded(this._list); - } - }; - } -}); - -// node_modules/whatwg-url/lib/URLSearchParams.js -var require_URLSearchParams = __commonJS({ - "node_modules/whatwg-url/lib/URLSearchParams.js"(exports2) { - "use strict"; - var conversions = require_lib(); - var utils = require_utils(); - var Function2 = require_Function(); - var newObjectInRealm = utils.newObjectInRealm; - var implSymbol = utils.implSymbol; - var ctorRegistrySymbol = utils.ctorRegistrySymbol; - var interfaceName = "URLSearchParams"; - exports2.is = (value) => { - return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; - }; - exports2.isImpl = (value) => { - return utils.isObject(value) && value instanceof Impl.implementation; - }; - exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { - if (exports2.is(value)) { - return utils.implForWrapper(value); - } - throw new globalObject.TypeError(`${context} is not of type 'URLSearchParams'.`); - }; - exports2.createDefaultIterator = (globalObject, target, kind) => { - const ctorRegistry = globalObject[ctorRegistrySymbol]; - const iteratorPrototype = ctorRegistry["URLSearchParams Iterator"]; - const iterator = Object.create(iteratorPrototype); - Object.defineProperty(iterator, utils.iterInternalSymbol, { - value: { target, kind, index: 0 }, - configurable: true - }); - return iterator; - }; - function makeWrapper(globalObject, newTarget) { - let proto; - if (newTarget !== void 0) { - proto = newTarget.prototype; - } - if (!utils.isObject(proto)) { - proto = globalObject[ctorRegistrySymbol]["URLSearchParams"].prototype; - } - return Object.create(proto); - } - exports2.create = (globalObject, constructorArgs, privateData) => { - const wrapper = makeWrapper(globalObject); - return exports2.setup(wrapper, globalObject, constructorArgs, privateData); - }; - exports2.createImpl = (globalObject, constructorArgs, privateData) => { - const wrapper = exports2.create(globalObject, constructorArgs, privateData); - return utils.implForWrapper(wrapper); - }; - exports2._internalSetup = (wrapper, globalObject) => { - }; - exports2.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { - privateData.wrapper = wrapper; - exports2._internalSetup(wrapper, globalObject); - Object.defineProperty(wrapper, implSymbol, { - value: new Impl.implementation(globalObject, constructorArgs, privateData), - configurable: true - }); - wrapper[implSymbol][utils.wrapperSymbol] = wrapper; - if (Impl.init) { - Impl.init(wrapper[implSymbol]); - } - return wrapper; - }; - exports2.new = (globalObject, newTarget) => { - const wrapper = makeWrapper(globalObject, newTarget); - exports2._internalSetup(wrapper, globalObject); - Object.defineProperty(wrapper, implSymbol, { - value: Object.create(Impl.implementation.prototype), - configurable: true - }); - wrapper[implSymbol][utils.wrapperSymbol] = wrapper; - if (Impl.init) { - Impl.init(wrapper[implSymbol]); - } - return wrapper[implSymbol]; - }; - var exposed = /* @__PURE__ */ new Set(["Window", "Worker"]); - exports2.install = (globalObject, globalNames) => { - if (!globalNames.some((globalName) => exposed.has(globalName))) { - return; - } - const ctorRegistry = utils.initCtorRegistry(globalObject); - class URLSearchParams { - constructor() { - const args = []; - { - let curArg = arguments[0]; - if (curArg !== void 0) { - if (utils.isObject(curArg)) { - if (curArg[Symbol.iterator] !== void 0) { - if (!utils.isObject(curArg)) { - throw new globalObject.TypeError( - "Failed to construct 'URLSearchParams': parameter 1 sequence is not an iterable object." - ); - } else { - const V = []; - const tmp = curArg; - for (let nextItem of tmp) { - if (!utils.isObject(nextItem)) { - throw new globalObject.TypeError( - "Failed to construct 'URLSearchParams': parameter 1 sequence's element is not an iterable object." - ); - } else { - const V2 = []; - const tmp2 = nextItem; - for (let nextItem2 of tmp2) { - nextItem2 = conversions["USVString"](nextItem2, { - context: "Failed to construct 'URLSearchParams': parameter 1 sequence's element's element", - globals: globalObject - }); - V2.push(nextItem2); - } - nextItem = V2; - } - V.push(nextItem); - } - curArg = V; - } - } else { - if (!utils.isObject(curArg)) { - throw new globalObject.TypeError( - "Failed to construct 'URLSearchParams': parameter 1 record is not an object." - ); - } else { - const result = /* @__PURE__ */ Object.create(null); - for (const key2 of Reflect.ownKeys(curArg)) { - const desc = Object.getOwnPropertyDescriptor(curArg, key2); - if (desc && desc.enumerable) { - let typedKey = key2; - typedKey = conversions["USVString"](typedKey, { - context: "Failed to construct 'URLSearchParams': parameter 1 record's key", - globals: globalObject - }); - let typedValue = curArg[key2]; - typedValue = conversions["USVString"](typedValue, { - context: "Failed to construct 'URLSearchParams': parameter 1 record's value", - globals: globalObject - }); - result[typedKey] = typedValue; - } - } - curArg = result; - } - } - } else { - curArg = conversions["USVString"](curArg, { - context: "Failed to construct 'URLSearchParams': parameter 1", - globals: globalObject - }); - } - } else { - curArg = ""; - } - args.push(curArg); - } - return exports2.setup(Object.create(new.target.prototype), globalObject, args); - } - append(name, value) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError( - "'append' called on an object that is not a valid instance of URLSearchParams." - ); - } - if (arguments.length < 2) { - throw new globalObject.TypeError( - `Failed to execute 'append' on 'URLSearchParams': 2 arguments required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'append' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'append' on 'URLSearchParams': parameter 2", - globals: globalObject - }); - args.push(curArg); - } - return utils.tryWrapperForImpl(esValue[implSymbol].append(...args)); - } - delete(name) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError( - "'delete' called on an object that is not a valid instance of URLSearchParams." - ); - } - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'delete' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'delete' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - if (curArg !== void 0) { - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'delete' on 'URLSearchParams': parameter 2", - globals: globalObject - }); - } - args.push(curArg); - } - return utils.tryWrapperForImpl(esValue[implSymbol].delete(...args)); - } - get(name) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get' called on an object that is not a valid instance of URLSearchParams."); - } - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'get' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'get' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - return esValue[implSymbol].get(...args); - } - getAll(name) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError( - "'getAll' called on an object that is not a valid instance of URLSearchParams." - ); - } - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'getAll' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'getAll' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - return utils.tryWrapperForImpl(esValue[implSymbol].getAll(...args)); - } - has(name) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'has' called on an object that is not a valid instance of URLSearchParams."); - } - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'has' on 'URLSearchParams': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'has' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - if (curArg !== void 0) { - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'has' on 'URLSearchParams': parameter 2", - globals: globalObject - }); - } - args.push(curArg); - } - return esValue[implSymbol].has(...args); - } - set(name, value) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set' called on an object that is not a valid instance of URLSearchParams."); - } - if (arguments.length < 2) { - throw new globalObject.TypeError( - `Failed to execute 'set' on 'URLSearchParams': 2 arguments required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'set' on 'URLSearchParams': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'set' on 'URLSearchParams': parameter 2", - globals: globalObject - }); - args.push(curArg); - } - return utils.tryWrapperForImpl(esValue[implSymbol].set(...args)); - } - sort() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'sort' called on an object that is not a valid instance of URLSearchParams."); - } - return utils.tryWrapperForImpl(esValue[implSymbol].sort()); - } - toString() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError( - "'toString' called on an object that is not a valid instance of URLSearchParams." - ); - } - return esValue[implSymbol].toString(); - } - keys() { - if (!exports2.is(this)) { - throw new globalObject.TypeError("'keys' called on an object that is not a valid instance of URLSearchParams."); - } - return exports2.createDefaultIterator(globalObject, this, "key"); - } - values() { - if (!exports2.is(this)) { - throw new globalObject.TypeError( - "'values' called on an object that is not a valid instance of URLSearchParams." - ); - } - return exports2.createDefaultIterator(globalObject, this, "value"); - } - entries() { - if (!exports2.is(this)) { - throw new globalObject.TypeError( - "'entries' called on an object that is not a valid instance of URLSearchParams." - ); - } - return exports2.createDefaultIterator(globalObject, this, "key+value"); - } - forEach(callback) { - if (!exports2.is(this)) { - throw new globalObject.TypeError( - "'forEach' called on an object that is not a valid instance of URLSearchParams." - ); - } - if (arguments.length < 1) { - throw new globalObject.TypeError( - "Failed to execute 'forEach' on 'iterable': 1 argument required, but only 0 present." - ); - } - callback = Function2.convert(globalObject, callback, { - context: "Failed to execute 'forEach' on 'iterable': The callback provided as parameter 1" - }); - const thisArg = arguments[1]; - let pairs = Array.from(this[implSymbol]); - let i = 0; - while (i < pairs.length) { - const [key2, value] = pairs[i].map(utils.tryWrapperForImpl); - callback.call(thisArg, value, key2, this); - pairs = Array.from(this[implSymbol]); - i++; - } - } - get size() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError( - "'get size' called on an object that is not a valid instance of URLSearchParams." - ); - } - return esValue[implSymbol]["size"]; - } - } - Object.defineProperties(URLSearchParams.prototype, { - append: { enumerable: true }, - delete: { enumerable: true }, - get: { enumerable: true }, - getAll: { enumerable: true }, - has: { enumerable: true }, - set: { enumerable: true }, - sort: { enumerable: true }, - toString: { enumerable: true }, - keys: { enumerable: true }, - values: { enumerable: true }, - entries: { enumerable: true }, - forEach: { enumerable: true }, - size: { enumerable: true }, - [Symbol.toStringTag]: { value: "URLSearchParams", configurable: true }, - [Symbol.iterator]: { value: URLSearchParams.prototype.entries, configurable: true, writable: true } - }); - ctorRegistry[interfaceName] = URLSearchParams; - ctorRegistry["URLSearchParams Iterator"] = Object.create(ctorRegistry["%IteratorPrototype%"], { - [Symbol.toStringTag]: { - configurable: true, - value: "URLSearchParams Iterator" - } - }); - utils.define(ctorRegistry["URLSearchParams Iterator"], { - next() { - const internal = this && this[utils.iterInternalSymbol]; - if (!internal) { - throw new globalObject.TypeError("next() called on a value that is not a URLSearchParams iterator object"); - } - const { target, kind, index: index4 } = internal; - const values = Array.from(target[implSymbol]); - const len = values.length; - if (index4 >= len) { - return newObjectInRealm(globalObject, { value: void 0, done: true }); - } - const pair = values[index4]; - internal.index = index4 + 1; - return newObjectInRealm(globalObject, utils.iteratorResult(pair.map(utils.tryWrapperForImpl), kind)); - } - }); - Object.defineProperty(globalObject, interfaceName, { - configurable: true, - writable: true, - value: URLSearchParams - }); - }; - var Impl = require_URLSearchParams_impl(); - } -}); - -// node_modules/whatwg-url/lib/URL-impl.js -var require_URL_impl = __commonJS({ - "node_modules/whatwg-url/lib/URL-impl.js"(exports2) { - "use strict"; - var usm = require_url_state_machine(); - var urlencoded = require_urlencoded(); - var URLSearchParams = require_URLSearchParams(); - exports2.implementation = class URLImpl { - // Unlike the spec, we duplicate some code between the constructor and canParse, because we want to give useful error - // messages in the constructor that distinguish between the different causes of failure. - constructor(globalObject, [url2, base]) { - let parsedBase = null; - if (base !== void 0) { - parsedBase = usm.basicURLParse(base); - if (parsedBase === null) { - throw new TypeError(`Invalid base URL: ${base}`); - } - } - const parsedURL = usm.basicURLParse(url2, { baseURL: parsedBase }); - if (parsedURL === null) { - throw new TypeError(`Invalid URL: ${url2}`); - } - const query = parsedURL.query !== null ? parsedURL.query : ""; - this._url = parsedURL; - this._query = URLSearchParams.createImpl(globalObject, [query], { doNotStripQMark: true }); - this._query._url = this; - } - static parse(globalObject, input, base) { - try { - return new URLImpl(globalObject, [input, base]); - } catch { - return null; - } - } - static canParse(url2, base) { - let parsedBase = null; - if (base !== void 0) { - parsedBase = usm.basicURLParse(base); - if (parsedBase === null) { - return false; - } - } - const parsedURL = usm.basicURLParse(url2, { baseURL: parsedBase }); - if (parsedURL === null) { - return false; - } - return true; - } - get href() { - return usm.serializeURL(this._url); - } - set href(v) { - const parsedURL = usm.basicURLParse(v); - if (parsedURL === null) { - throw new TypeError(`Invalid URL: ${v}`); - } - this._url = parsedURL; - this._query._list.splice(0); - const { query } = parsedURL; - if (query !== null) { - this._query._list = urlencoded.parseUrlencodedString(query); - } - } - get origin() { - return usm.serializeURLOrigin(this._url); - } - get protocol() { - return `${this._url.scheme}:`; - } - set protocol(v) { - usm.basicURLParse(`${v}:`, { url: this._url, stateOverride: "scheme start" }); - } - get username() { - return this._url.username; - } - set username(v) { - if (usm.cannotHaveAUsernamePasswordPort(this._url)) { - return; - } - usm.setTheUsername(this._url, v); - } - get password() { - return this._url.password; - } - set password(v) { - if (usm.cannotHaveAUsernamePasswordPort(this._url)) { - return; - } - usm.setThePassword(this._url, v); - } - get host() { - const url2 = this._url; - if (url2.host === null) { - return ""; - } - if (url2.port === null) { - return usm.serializeHost(url2.host); - } - return `${usm.serializeHost(url2.host)}:${usm.serializeInteger(url2.port)}`; - } - set host(v) { - if (usm.hasAnOpaquePath(this._url)) { - return; - } - usm.basicURLParse(v, { url: this._url, stateOverride: "host" }); - } - get hostname() { - if (this._url.host === null) { - return ""; - } - return usm.serializeHost(this._url.host); - } - set hostname(v) { - if (usm.hasAnOpaquePath(this._url)) { - return; - } - usm.basicURLParse(v, { url: this._url, stateOverride: "hostname" }); - } - get port() { - if (this._url.port === null) { - return ""; - } - return usm.serializeInteger(this._url.port); - } - set port(v) { - if (usm.cannotHaveAUsernamePasswordPort(this._url)) { - return; - } - if (v === "") { - this._url.port = null; - } else { - usm.basicURLParse(v, { url: this._url, stateOverride: "port" }); - } - } - get pathname() { - return usm.serializePath(this._url); - } - set pathname(v) { - if (usm.hasAnOpaquePath(this._url)) { - return; - } - this._url.path = []; - usm.basicURLParse(v, { url: this._url, stateOverride: "path start" }); - } - get search() { - if (this._url.query === null || this._url.query === "") { - return ""; - } - return `?${this._url.query}`; - } - set search(v) { - const url2 = this._url; - if (v === "") { - url2.query = null; - this._query._list = []; - return; - } - const input = v[0] === "?" ? v.substring(1) : v; - url2.query = ""; - usm.basicURLParse(input, { url: url2, stateOverride: "query" }); - this._query._list = urlencoded.parseUrlencodedString(input); - } - get searchParams() { - return this._query; - } - get hash() { - if (this._url.fragment === null || this._url.fragment === "") { - return ""; - } - return `#${this._url.fragment}`; - } - set hash(v) { - if (v === "") { - this._url.fragment = null; - return; - } - const input = v[0] === "#" ? v.substring(1) : v; - this._url.fragment = ""; - usm.basicURLParse(input, { url: this._url, stateOverride: "fragment" }); - } - toJSON() { - return this.href; - } - }; - } -}); - -// node_modules/whatwg-url/lib/URL.js -var require_URL = __commonJS({ - "node_modules/whatwg-url/lib/URL.js"(exports2) { - "use strict"; - var conversions = require_lib(); - var utils = require_utils(); - var implSymbol = utils.implSymbol; - var ctorRegistrySymbol = utils.ctorRegistrySymbol; - var interfaceName = "URL"; - exports2.is = (value) => { - return utils.isObject(value) && utils.hasOwn(value, implSymbol) && value[implSymbol] instanceof Impl.implementation; - }; - exports2.isImpl = (value) => { - return utils.isObject(value) && value instanceof Impl.implementation; - }; - exports2.convert = (globalObject, value, { context = "The provided value" } = {}) => { - if (exports2.is(value)) { - return utils.implForWrapper(value); - } - throw new globalObject.TypeError(`${context} is not of type 'URL'.`); - }; - function makeWrapper(globalObject, newTarget) { - let proto; - if (newTarget !== void 0) { - proto = newTarget.prototype; - } - if (!utils.isObject(proto)) { - proto = globalObject[ctorRegistrySymbol]["URL"].prototype; - } - return Object.create(proto); - } - exports2.create = (globalObject, constructorArgs, privateData) => { - const wrapper = makeWrapper(globalObject); - return exports2.setup(wrapper, globalObject, constructorArgs, privateData); - }; - exports2.createImpl = (globalObject, constructorArgs, privateData) => { - const wrapper = exports2.create(globalObject, constructorArgs, privateData); - return utils.implForWrapper(wrapper); - }; - exports2._internalSetup = (wrapper, globalObject) => { - }; - exports2.setup = (wrapper, globalObject, constructorArgs = [], privateData = {}) => { - privateData.wrapper = wrapper; - exports2._internalSetup(wrapper, globalObject); - Object.defineProperty(wrapper, implSymbol, { - value: new Impl.implementation(globalObject, constructorArgs, privateData), - configurable: true - }); - wrapper[implSymbol][utils.wrapperSymbol] = wrapper; - if (Impl.init) { - Impl.init(wrapper[implSymbol]); - } - return wrapper; - }; - exports2.new = (globalObject, newTarget) => { - const wrapper = makeWrapper(globalObject, newTarget); - exports2._internalSetup(wrapper, globalObject); - Object.defineProperty(wrapper, implSymbol, { - value: Object.create(Impl.implementation.prototype), - configurable: true - }); - wrapper[implSymbol][utils.wrapperSymbol] = wrapper; - if (Impl.init) { - Impl.init(wrapper[implSymbol]); - } - return wrapper[implSymbol]; - }; - var exposed = /* @__PURE__ */ new Set(["Window", "Worker"]); - exports2.install = (globalObject, globalNames) => { - if (!globalNames.some((globalName) => exposed.has(globalName))) { - return; - } - const ctorRegistry = utils.initCtorRegistry(globalObject); - class URL2 { - constructor(url2) { - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to construct 'URL': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to construct 'URL': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - if (curArg !== void 0) { - curArg = conversions["USVString"](curArg, { - context: "Failed to construct 'URL': parameter 2", - globals: globalObject - }); - } - args.push(curArg); - } - return exports2.setup(Object.create(new.target.prototype), globalObject, args); - } - toJSON() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'toJSON' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol].toJSON(); - } - get href() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get href' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["href"]; - } - set href(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set href' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'href' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["href"] = V; - } - toString() { - const esValue = this; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'toString' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["href"]; - } - get origin() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get origin' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["origin"]; - } - get protocol() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get protocol' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["protocol"]; - } - set protocol(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set protocol' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'protocol' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["protocol"] = V; - } - get username() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get username' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["username"]; - } - set username(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set username' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'username' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["username"] = V; - } - get password() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get password' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["password"]; - } - set password(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set password' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'password' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["password"] = V; - } - get host() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get host' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["host"]; - } - set host(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set host' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'host' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["host"] = V; - } - get hostname() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get hostname' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["hostname"]; - } - set hostname(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set hostname' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'hostname' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["hostname"] = V; - } - get port() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get port' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["port"]; - } - set port(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set port' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'port' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["port"] = V; - } - get pathname() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get pathname' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["pathname"]; - } - set pathname(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set pathname' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'pathname' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["pathname"] = V; - } - get search() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get search' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["search"]; - } - set search(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set search' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'search' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["search"] = V; - } - get searchParams() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get searchParams' called on an object that is not a valid instance of URL."); - } - return utils.getSameObject(this, "searchParams", () => { - return utils.tryWrapperForImpl(esValue[implSymbol]["searchParams"]); - }); - } - get hash() { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'get hash' called on an object that is not a valid instance of URL."); - } - return esValue[implSymbol]["hash"]; - } - set hash(V) { - const esValue = this !== null && this !== void 0 ? this : globalObject; - if (!exports2.is(esValue)) { - throw new globalObject.TypeError("'set hash' called on an object that is not a valid instance of URL."); - } - V = conversions["USVString"](V, { - context: "Failed to set the 'hash' property on 'URL': The provided value", - globals: globalObject - }); - esValue[implSymbol]["hash"] = V; - } - static parse(url2) { - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'parse' on 'URL': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'parse' on 'URL': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - if (curArg !== void 0) { - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'parse' on 'URL': parameter 2", - globals: globalObject - }); - } - args.push(curArg); - } - return utils.tryWrapperForImpl(Impl.implementation.parse(globalObject, ...args)); - } - static canParse(url2) { - if (arguments.length < 1) { - throw new globalObject.TypeError( - `Failed to execute 'canParse' on 'URL': 1 argument required, but only ${arguments.length} present.` - ); - } - const args = []; - { - let curArg = arguments[0]; - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'canParse' on 'URL': parameter 1", - globals: globalObject - }); - args.push(curArg); - } - { - let curArg = arguments[1]; - if (curArg !== void 0) { - curArg = conversions["USVString"](curArg, { - context: "Failed to execute 'canParse' on 'URL': parameter 2", - globals: globalObject - }); - } - args.push(curArg); - } - return Impl.implementation.canParse(...args); - } - } - Object.defineProperties(URL2.prototype, { - toJSON: { enumerable: true }, - href: { enumerable: true }, - toString: { enumerable: true }, - origin: { enumerable: true }, - protocol: { enumerable: true }, - username: { enumerable: true }, - password: { enumerable: true }, - host: { enumerable: true }, - hostname: { enumerable: true }, - port: { enumerable: true }, - pathname: { enumerable: true }, - search: { enumerable: true }, - searchParams: { enumerable: true }, - hash: { enumerable: true }, - [Symbol.toStringTag]: { value: "URL", configurable: true } - }); - Object.defineProperties(URL2, { parse: { enumerable: true }, canParse: { enumerable: true } }); - ctorRegistry[interfaceName] = URL2; - Object.defineProperty(globalObject, interfaceName, { - configurable: true, - writable: true, - value: URL2 - }); - if (globalNames.includes("Window")) { - Object.defineProperty(globalObject, "webkitURL", { - configurable: true, - writable: true, - value: URL2 - }); - } - }; - var Impl = require_URL_impl(); - } -}); - -// node_modules/whatwg-url/webidl2js-wrapper.js -var require_webidl2js_wrapper = __commonJS({ - "node_modules/whatwg-url/webidl2js-wrapper.js"(exports2) { - "use strict"; - var URL2 = require_URL(); - var URLSearchParams = require_URLSearchParams(); - exports2.URL = URL2; - exports2.URLSearchParams = URLSearchParams; - } -}); - -// node_modules/whatwg-url/index.js -var require_whatwg_url = __commonJS({ - "node_modules/whatwg-url/index.js"(exports2) { - "use strict"; - var { URL: URL2, URLSearchParams } = require_webidl2js_wrapper(); - var urlStateMachine = require_url_state_machine(); - var percentEncoding = require_percent_encoding(); - var sharedGlobalObject = { Array, Object, Promise, String, TypeError }; - URL2.install(sharedGlobalObject, ["Window"]); - URLSearchParams.install(sharedGlobalObject, ["Window"]); - exports2.URL = sharedGlobalObject.URL; - exports2.URLSearchParams = sharedGlobalObject.URLSearchParams; - exports2.parseURL = urlStateMachine.parseURL; - exports2.basicURLParse = urlStateMachine.basicURLParse; - exports2.serializeURL = urlStateMachine.serializeURL; - exports2.serializePath = urlStateMachine.serializePath; - exports2.serializeHost = urlStateMachine.serializeHost; - exports2.serializeInteger = urlStateMachine.serializeInteger; - exports2.serializeURLOrigin = urlStateMachine.serializeURLOrigin; - exports2.setTheUsername = urlStateMachine.setTheUsername; - exports2.setThePassword = urlStateMachine.setThePassword; - exports2.cannotHaveAUsernamePasswordPort = urlStateMachine.cannotHaveAUsernamePasswordPort; - exports2.hasAnOpaquePath = urlStateMachine.hasAnOpaquePath; - exports2.percentDecodeString = percentEncoding.percentDecodeString; - exports2.percentDecodeBytes = percentEncoding.percentDecodeBytes; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/en.json -var en_exports = {}; -__export(en_exports, { - default: () => en_default -}); -var en_default; -var init_en = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/en.json"() { - en_default = { - array: "an array", - boolean: "a boolean", - "bug-of-mc": "Due to a bug of Minecraft (%0%), %1%. Please Mojang, fix your game", - "code-action.block-state-sort-keys": "Sort block state", - "code-action.command-replaceitem": "Update this command to /item \u2026 replace", - "code-action.fix-file": "Fix all auto-fixable problems in this file", - "code-action.fix-workspace": "Fix all auto-fixable problems in the workspace", - "code-action.id-attribute-datafix": "Update this attribute name to 1.16", - "code-action.add-default-namespace": "Add default namespace", - "code-action.add-leading-slash": "Add leading slash", - "code-action.create-undeclared-file": "Create %0% %1% in the same pack", - "code-action.id-omit-default-namespace": "Omit default namespace", - "code-action.id-zombified-piglin-datafix": "Change this ID to Zombified Piglin's", - "code-action.nbt-compound-sort-keys": "Sort NBT compound tag", - "code-action.nbt-type-to-byte": "Convert to an NBT byte tag", - "code-action.nbt-type-to-double": "Convert to an NBT double tag", - "code-action.nbt-type-to-float": "Convert to an NBT float tag", - "code-action.nbt-type-to-int": "Convert to an NBT int tag", - "code-action.nbt-type-to-long": "Convert to an NBT long tag", - "code-action.nbt-type-to-short": "Convert to an NBT short tag", - "code-action.nbt-uuid-datafix": "Update this UUID to 1.16", - "code-action.remove-leading-slash": "Remove leading slash", - "code-action.remove-trailing-separation": "Remove trailing separation", - "code-action.selector-sort-keys": "Sort selector argument", - "code-action.string-double-quote": "Quote this string with double quotation marks", - "code-action.string-single-quote": "Quote this string with single quotation marks", - "code-action.string-unquote": "Unquote this string", - "code-action.vector-align-0.0": "Align this vector to block origin", - "code-action.vector-align-0.5": "Align this vector to block center", - comment: "a comment starting with %0%", - "conjunction.and_2": " and ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", and ", - "conjunction.or_2": " or ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", or ", - "datafix.error.command-replaceitem": "/replaceitem was removed in 20w46a (the second snapshot of 1.17) in favour of /item", - "duplicate-key": "Duplicate key %0%", - "ending-quote": "an ending quote %0%", - entity: "an entity", - "error.unparseable-content": "Encountered unparseable content", - expected: "Expected %0%", - "expected-got": "Expected %0% but got %1%", - float: "a float", - "float.between": "a float between %0% and %1%", - integer: "an integer", - "integer.between": "an integer between %0% and %1%", - "invalid-key-combination": "Invalid combination of keys %0%", - "invalid-regex-pattern": "Invalid regex pattern: %0%", - "mismatching-regex-pattern": "Value does not match regex: %0%", - "java-edition.binder.wrong-folder": "Files in the %0% folder are not recognized in loaded version %1%, did you meant to use the %2% folder?", - "java-edition.binder.wrong-version": "Files in the %0% folder are not recognized in loaded version %1%", - "java-edition.translation-value.percent-escape-hint": "%0%. If you want to display a literal percent sign, use \u201C%%\u201D instead", - "json.doc.advancement.display": "Advancement display settings. If present, the advancement will be visible in the advancement tabs.", - "json.checker.array.length-between": "%0% with length between %1% and %2%", - "json.checker.object.field.union-empty-members": "Disallowed property", - "json.checker.item.duplicate": "Duplicate list item", - "json.checker.property.deprecated": "Property %0% is deprecated", - "json.checker.property.missing": "Missing property %0%", - "json.checker.property.unknown": "Unknown property %0%", - "json.checker.string.hex-color": "a 6-digit hexadecimal number", - "json.checker.tag-entry.duplicate": "Duplicate tag entry", - "json.checker.value": "a value", - "json.node.array": "an array", - "json.node.boolean": "a boolean", - "json.node.null": "a null", - "json.node.number": "a number", - "json.node.object": "an object", - "json.node.string": "a string", - "key-not-following-convention": "Invalid key %0% which doesn't follow %1% convention", - "linter.diagnostic-message-wrapper": "%0% (rule: %1%)", - "linter.name-convention.illegal": "Name %0% doesn't match %1%", - "linter.undeclared-symbol.message": "Cannot find %0% %1%", - "linter-config-validator.name-convention.type": "Expects a string that contains a regular expression describing the name", - "linter-config-validator.wrapper": "%0%. See [the documentation](%1) for more information", - long: "a long", - "long.between": "a long between %0% and %1%", - "mcdoc.binder.dispatcher-statement.duplicated-key": "Duplicated dispatcher case %0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% has already been dispatched here", - "mcdoc.binder.duplicated-declaration": "Duplicated declaration for %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% is already declared here", - "mcdoc.binder.out-of-root": "File %0% is not under the root directory of any mcdoc project; semantic checking will be skipped", - "mcdoc.binder.path.super-from-root": "Cannot access super of the project root", - "mcdoc.binder.path.unknown-identifier": "Identifier %0% does not exist in module %1%", - "mcdoc.binder.path.unknown-module": "Module %0% does not exist", - "mcdoc.checker.entry.empty-mod-seg": "You cannot put \u201Cmod.mcdoc\u201D under a root directly", - "mcdoc.checker.inject-clause.unmatched-injection": "Cannot inject %0% with %1%", - "mcdoc.checker.type-not-assignable": "Type %0% is not assignable to type %1%", - "mcdoc.checker.reference.unexpected-number-of-type-arguments": "Type %0% requires %1% type arguments, but received %2%", - "mcdoc.node.compound-definition": "a compound definition", - "mcdoc.node.enum-definition": "an enum definition", - "mcdoc.node.identifier": "an identifier", - "mcdoc.parser.compound-definition.field-type": "a field type", - "mcdoc.parser.float.illegal": "Encountered illegal float number", - "mcdoc.parser.identifier.reserved-word": "%0% is a reserved word and cannot be used as an identifier name", - "mcdoc.parser.identifier.illegal": "%0% doesn't follow the format of %1%", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "Dynamic indexing is not allowed", - "mcdoc.parser.inject-clause.definition-expected": "Expected either an enum inject or a compound inject", - "mcdoc.parser.keyword.separation": "a separation", - "mcdoc.parser.resource-location.colon-expected": "Expected the colon (%0%) of resource locations", - "mcdoc.parser.syntax.doc-comment-unexpected": "Doc comments are not allowed here; you might want to replace the three slashes with two slashes", - "mcdoc.runtime.checker.key-value-pair": "a key-value pair", - "mcdoc.runtime.checker.range.collection": "collection length to be %0%", - "mcdoc.runtime.checker.range.concat": "%0% and %1%", - "mcdoc.runtime.checker.range.left-exclusive": "above %0%", - "mcdoc.runtime.checker.range.left-inclusive": "at least %0%", - "mcdoc.runtime.checker.range.right-exclusive": "below %0%", - "mcdoc.runtime.checker.range.right-inclusive": "at most %0%", - "mcdoc.runtime.checker.range.number": "numeric value to be %0%", - "mcdoc.runtime.checker.range.string": "string length to be %0%", - "mcdoc.runtime.checker.some-missing-keys": "Missing at least one of the keys %0%", - "mcdoc.runtime.checker.trailing": "Trailing data encountered", - "mcdoc.runtime.checker.value": "a value", - "mcdoc.type.boolean": "a boolean", - "mcdoc.type.byte": "a byte", - "mcdoc.type.short": "a short", - "mcdoc.type.int": "an int", - "mcdoc.type.long": "a long", - "mcdoc.type.float": "a float", - "mcdoc.type.double": "a double", - "mcdoc.type.list": "a list", - "mcdoc.type.byte_array": "a byte array", - "mcdoc.type.int_array": "an int array", - "mcdoc.type.long_array": "a long array", - "mcdoc.type.string": "a string", - "mcdoc.type.struct": "a map-like", - "mcfunction.checker.command.data-modify-unapplicable-operation": "Operation %0% can only be used on %1%; the target path has type %2% instead", - "mcfunction.completer.block.states.default-value": "Default: %0%", - "mcfunction.parser.command-too-long": "Command with length %0% is longer than maximum length %1%", - "mcfunction.parser.duplicate-components": "Duplicate component", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% is not applicable here", - "mcfunction.parser.entity-selector.arguments.unknown": "Unknown entity selector argument %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "The selector contains non-player entities", - "mcfunction.parser.entity-selector.invalid": "Invalid entity selector: \u201C%0%\u201D", - "mcfunction.parser.entity-selector.multiple-disallowed": "The selector contains multiple entities", - "mcfunction.parser.entity-selector.player-name.too-long": "Player names cannot be longer than %0% characters", - "mcfunction.parser.eoc-unexpected": "Expected more arguments", - "mcfunction.parser.leading-slash": "a leading slash \u201C/\u201D", - "mcfunction.parser.leading-slash.unexpected": "Unexpected leading slash \u201C/\u201D", - "mcfunction.parser.macro.at-least-one": "at least one macro argument", - "mcfunction.parser.macro.disallowed": "Macro lines are only supported since 1.20.2", - "mcfunction.parser.macro.illegal-key": "Illegal key character: \u201C%0%\u201D", - "mcfunction.parser.macro.key": "a macro key", - "mcfunction.parser.no-permission": "Permission level %0% is required, which is higher than %1% defined in config", - "mcfunction.parser.objective.too-long": "Objective names cannot be longer than %0% characters", - "mcfunction.parser.range.min>max": "The minimum value %0% is larger than the maximum value %1%", - "mcfunction.parser.range.span-too-large": "The range size %0% is larger than the maximum %1%", - "mcfunction.parser.range.span-too-small": "The range size %0% is smaller than the minimum %1%", - "mcfunction.parser.score_holder.fake-name.too-long": "Fake names cannot be longer than %0% characters", - "mcfunction.parser.sep": "a space (%0%)", - "mcfunction.parser.trailing": "Trailing data encountered: %0%", - "mcfunction.parser.unknown-parser": "Parser %0% hasn't been supported yet", - "mcfunction.parser.uuid.invalid": "Invalid UUID format", - "mcfunction.parser.vector.local-disallowed": "Local coordinates disallowed", - "mcfunction.parser.vector.mixed": "Cannot mix local coordinates and world coordinates together", - "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: `%0%` command](https://minecraft.fandom.com/wiki/Commands/%0%)", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: `%0%` argument parser](https://minecraft.fandom.com/wiki/Argument_types#%0%)", - "missing-key": "Missing key %0%", - "nbt.checker.block-states.fake-boolean": "Boolean block state values should be quoted", - "nbt.checker.block-states.unexpected-value-type": "Block state values should be either a string or an int", - "nbt.checker.block-states.unknown-state": "Unknown block state %0% for the following block(s): %1%", - "nbt.checker.boolean.out-of-range": "A boolean value should be either %0% or %1%", - "nbt.checker.collection.length-between": "%0% with length between %1% and %2%", - "nbt.checker.compound.field.union-empty-members": "Disallowed property", - "nbt.checker.path.index-out-of-bound": "The provided index %0% is out of bound, as the collection can only have at most %1% elements", - "nbt.checker.path.unexpected-filter": "Compound filters can only be used on compound tags", - "nbt.checker.path.unexpected-index": "Indices can only be used on array or list tags", - "nbt.checker.path.unexpected-key": "String keys can only be specified for compound tags", - "nbt.node": "a tag", - "nbt.node.byte": "a byte tag", - "nbt.node.byte_array": "a byte array tag", - "nbt.node.compound": "a compound tag", - "nbt.node.double": "a double tag", - "nbt.node.float": "a float tag", - "nbt.node.int": "an int tag", - "nbt.node.int_array": "an int array tag", - "nbt.node.list": "a list tag", - "nbt.node.long": "a long tag", - "nbt.node.long_array": "a long array tag", - "nbt.node.path.end": "the end of path", - "nbt.node.path.filter": "a compound filter", - "nbt.node.path.index": "an index", - "nbt.node.path.key": "a key", - "nbt.node.short": "a short tag", - "nbt.node.string": "a string tag", - "nbt.path": "an NBT path", - "nbt.parser.number.out-of-range": "This looks like %0%, but it is actually %1% due to the numeral value being out of [%2%, %3%]", - "not-allowed-here": "Value %0% is not allowed here", - "not-divisible-by": "Value %0% is not divisible by %1%", - "not-matching-any-child": "Invalid argument type", - nothing: "nothing", - number: "a number", - "number-range": "a number range", - "number-range.missing-min-and-max": "Expected either a minimum value or a maximum value", - "number.<=": "a number smaller than or equal to %0%", - "number.>=": "a number greater than or equal to %0%", - "number.between": "a number between %0% and %1%", - object: "an object", - objective: "an objective", - "objective-not-following-convention": "Invalid objective %0% which doesn't follow %1% convention", - "parser.float.illegal": "Illegal float numeral that doesn't follow %0%", - "parser.integer.illegal": "Illegal integer that doesn't follow %0%", - "parser.line-continuation-end-of-file": "A line continuation cannot be the end of the file", - "parser.list.value": "a value", - "parser.list.trailing-sep": "Trailing separation", - "parser.long.illegal": "Illegal long numeral that doesn't follow %0%", - "parser.record.key": "a key", - "parser.record.trailing-end": "Trailing separation", - "parser.record.unexpected-char": "Unexpected character %0%", - "parser.record.value": "a value", - "parser.resource-location.illegal": "Illegal character(s): %0%", - "parser.resource-location.namespace-expected": "Namespaces cannot be omitted here", - "parser.resource-location.tag-disallowed": "Tags are not allowed here", - "parser.resource-location.tag-required": "Only tags are allowed here", - "parser.string.illegal-brigadier": "Encountered non-[0-9A-Za-z_.+-] characters in %0%", - "parser.string.illegal-escape": "Unexpected escape character %0%", - "parser.string.illegal-quote": "Only %0% can be used to quote strings here", - "parser.string.illegal-unicode-escape": "Hexadecimal digit expected", - "progress.initializing.title": "Initializing Spyglass\u2026", - "progress.reset-project-cache.title": "Resetting Project Cache\u2026", - "punc.period": ".", - "punc.quote": "\u201C%0%\u201D", - quote: `a quote (\u201C'\u201D or \u201C"\u201D)`, - quote_prefer_double: 'Double quote (\u201C"\u201D) is preferable here', - quote_prefer_single: "Single quote (\u201C'\u201D) is preferable here", - "resource-location": "a resource location", - "score-holder": "a score holder", - "scoreholder-not-following-convention": "Invalid score_holder %0% which doesn't follow %1% convention", - selector: "a selector", - "server.new-version": "The Data-pack Language Server has been updated to a newer version: %0%", - "server.progress.fixing-workspace.begin": "Fixing all auto-fixable problems in the workspace", - "server.progress.fixing-workspace.report": "fixing %0%", - "server.progress.preparing.title": "Preparing Spyglass language features", - "server.remove-cache-file": "The cache file of DHP was moved to a storage location provided by VSCode. You can safely delete the ugly \u201C.datapack\u201D folder in your workspace root.", - "server.show-release-notes": "Show Release Notes", - string: "a string", - tag: "a tag", - "tag-not-following-convention": "Invalid tag %0% which doesn't follow %1% convention", - team: "a team", - "team-not-following-convention": "Invalid team %0% which doesn't follow %1% convention", - "text-component": "a text component", - "time-unit": "a time unit", - "too-many-block-affected": "Too many blocks in the specified area (maximum %0%, specified %1%)", - "too-many-chunk-affected": "Too many chunks in the specified area (maximum %0%, specified %1%)", - "unexpected-character": "Found non [a-z0-9/._-] character(s)", - "unexpected-datapack-tag": "Tags are not allowed here", - "unexpected-default-namespace": "Default namespace should be omitted here", - "unexpected-local-coordinate": "Local coordinate %0% is not allowed", - "unexpected-nbt": "This tag doesn't exist here", - "unexpected-nbt-array-type": "Invalid array type %0%. Should be one of \u201CB\u201D, \u201CI\u201D, and \u201CL\u201D", - "unexpected-nbt-path-filter": "Compound filters are only used for compound tags", - "unexpected-nbt-path-index": "Indices are only used for lists/arrays tags", - "unexpected-nbt-path-key": "Keys are only used for compound tags", - "unexpected-nbt-path-sub": "The current tag doesn't have extra items", - "unexpected-omitted-default-namespace": "Default namespace shouldn't be omitted here", - "unexpected-relative-coordinate": "Relative coordinate %0% is not allowed", - "unexpected-scoreboard-sub-slot": "Only \u201Csidebar\u201D has sub slots", - "unknown-command": "Unknown command %0%", - "unknown-escape": "Unexpected escape character %0%", - "unknown-key": "Unknown key %0%", - "unquoted-string": "an unquoted string", - "unsorted-keys": "Unsorted keys", - uuid: "a UUID", - vector: "a vector" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/de.json -var de_exports = {}; -__export(de_exports, { - default: () => de_default -}); -var de_default; -var init_de = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/de.json"() { - de_default = { - array: "ein Array", - boolean: "einen Wahrheitswert", - "bug-of-mc": "Aufgrund eines Fehlers in Minecraft (%0%), %1%. Bitte beheben, Mojang danke", - "code-action.add-default-namespace": "Standardnamensraum hinzuf\xFCgen", - "code-action.add-leading-slash": "F\xFChrenden Schr\xE4gstrich hinzuf\xFCgen", - "code-action.block-state-sort-keys": "Blockzust\xE4nde sortieren", - "code-action.command-replaceitem": "Aktualisiere diesen Befehl zu /item ... replace", - "code-action.create-undeclared-file": "%0% %1% im selben Paket erstellen", - "code-action.fix-file": "Alle automatisch behebbaren Probleme in dieser Datei beheben", - "code-action.fix-workspace": "Alle automatisch behebbaren Probleme im Arbeitsbereich beheben", - "code-action.id-attribute-datafix": "Den Namen dieses Attributs auf Version 1.16 aktualisieren", - "code-action.id-complete-default-namespace": "Standardnamensraum vervollst\xE4ndigen", - "code-action.id-create-file": "%0% im selben Datenpaket erstellen", - "code-action.id-omit-default-namespace": "Standardnamensraum auslassen", - "code-action.id-zombified-piglin-datafix": "ID zu zombified_piglin \xE4ndern", - "code-action.nbt-compound-sort-keys": "NBT-Compound-Eigenschaften sortieren", - "code-action.nbt-type-to-byte": "In ein NBT-Byte-Tag umwandeln", - "code-action.nbt-type-to-double": "In ein NBT-Double-Tag umwandeln", - "code-action.nbt-type-to-float": "In ein NBT-Float-Tag umwandeln", - "code-action.nbt-type-to-int": "In ein NBT-Int-Tag umwandeln", - "code-action.nbt-type-to-long": "In ein NBT-Long-Tag umwandeln", - "code-action.nbt-type-to-short": "In ein NBT-Short-Tag umwandeln", - "code-action.nbt-uuid-datafix": "Diese UUID auf Version 1.16 aktualisieren", - "code-action.remove-leading-slash": "F\xFChrenden Schr\xE4gstrich entfernen", - "code-action.remove-trailing-separation": "Nachlaufende Trennung entfernen", - "code-action.selector-sort-keys": "Selektor-Argumente sortieren", - "code-action.string-double-quote": "Diese Zeichenkette in doppelte Anf\xFChrungszeichen setzen", - "code-action.string-single-quote": "Diese Zeichenkette in einfache Anf\xFChrungszeichen setzen", - "code-action.string-unquote": "Anf\xFChrungszeichen von dieser Zeichenkette entfernen", - "code-action.vector-align-0.0": "Diesen Vektor am Ursprung des Blocks ausrichten", - "code-action.vector-align-0.5": "Diesen Vektor am Zentrum des Blocks ausrichten", - comment: "ein Kommentar, der mit %0% beginnt", - "conjunction.and_2": " und ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", und ", - "conjunction.or_2": " oder ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", oder ", - "datafix.error.command-replaceitem": "/replaceitem wurde in 20w46a (dem zweiten Snapshot von 1.17) zugunsten von /item entfernt", - "duplicate-key": "Doppelter Schl\xFCssel %0%", - "ending-quote": "ein schlie\xDFendes Anf\xFChrungszeichen %0%", - entity: "eine Entit\xE4t", - "error.unparseable-content": "Nicht analysierbarer Inhalt gefunden", - expected: "%0% erwartet", - "expected-got": "%0% erwartet, aber %1% erhalten", - float: "eine Gleitkommazahl", - "float.between": "eine Gleitkommazahl zwischen %0% und %1%", - integer: "eine Ganzzahl", - "integer.between": "eine Ganzzahl zwischen %0% und %1%", - "invalid-key-combination": "Ung\xFCltige Schl\xFCsselkombination %0%", - "invalid-regex-pattern": "Ung\xFCltiges Regex-Muster: %0%", - "java-edition.binder.wrong-folder": "Dateien im Ordner %0% werden in der geladenen Version %1% nicht erkannt, wollten Sie den Ordner %2% verwenden?", - "java-edition.binder.wrong-version": "Dateien im Ordner %0% werden in der geladenen Version %1% nicht erkannt", - "java-edition.translation-value.percent-escape-hint": "%0%. Wenn Sie ein w\xF6rtliches Prozentzeichen anzeigen m\xF6chten, verwenden Sie stattdessen \u201E%%\u201C", - "json.checker.array.length-between": "%0% mit einer L\xE4nge zwischen %1% und %2%", - "json.checker.item.duplicate": "Gegenstand aus der Liste duplizieren", - "json.checker.object.field.union-empty-members": "Unerlaubte Eigenschaft", - "json.checker.property.deprecated": "Eigenschaft %0% ist veraltet", - "json.checker.property.missing": "Fehlende Eigenschaft %0%", - "json.checker.property.unknown": "Unbekannte Eigenschaft %0%", - "json.checker.string.hex-color": "eine sechstellige Hexadezimalzahl", - "json.checker.tag-entry.duplicate": "Tag-Eintrag duplizieren", - "json.checker.value": "ein Wert", - "json.doc.advancement.display": "Anzeigeeinstellungen f\xFCr Fortschritte. Falls vorhanden, wird der Fortschritt in den Fortschrittsregisterkarten angezeigt.", - "json.node.array": "ein Array", - "json.node.boolean": "ein Wahrheitswert", - "json.node.null": "ein null", - "json.node.number": "eine Zahl", - "json.node.object": "ein Objekt", - "json.node.string": "eine Zeichenkette", - "key-not-following-convention": "Der Schl\xFCssel %0% entspricht nicht der Namenskonvention %1%", - "linter-config-validator.name-convention.type": "Erwartet eine Zeichenkette, die einen Regex-Ausdruck enth\xE4lt, welcher den Bezeichner beschreibt", - "linter-config-validator.wrapper": "%0%. Siehe [die Dokumentation](%1) f\xFCr mehr Informationen", - "linter.diagnostic-message-wrapper": "%0% (Regel: %1%)", - "linter.name-convention.illegal": "Bezeichner %0% passt nicht zu %1%", - "linter.undeclared-symbol.message": "Kann %0% %1% nicht finden", - long: "eine lange Ganzzahl", - "long.between": "ein long zwischen %0% und %1%", - "mcdoc.binder.dispatcher-statement.duplicated-key": "Duplizierter Dispatcher-Fall %0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% wurde bereits hierher versandt", - "mcdoc.binder.duplicated-declaration": "Deklaration von %0% dupliziert", - "mcdoc.binder.duplicated-declaration.related": "%0% ist bereits deklariert", - "mcdoc.binder.out-of-root": "Datei %0% liegt nicht im root-Verzeichnis eines mcdoc-Projektes; Semantische \xDCberpr\xFCfung wird ausgelassen", - "mcdoc.binder.path.super-from-root": "Zugriff auf Superverzeichnis des Projektstamms nicht m\xF6glich", - "mcdoc.binder.path.unknown-identifier": "ID %0% existiert im Modul %1% nicht", - "mcdoc.binder.path.unknown-module": "Modul %0% existiert nicht", - "mcdoc.checker.entry.empty-mod-seg": "Sie k\xF6nnen \u201Emod.mcdoc\u201C nicht direkt unter einem Stammverzeichnis ablegen", - "mcdoc.checker.inject-clause.unmatched-injection": "%0% kann nicht mit %1% injiziert werden", - "mcdoc.checker.reference.unexpected-number-of-type-arguments": "Der Typ %0% erfordert Argumente vom Typ %1%, aber es wurden %2% empfangen", - "mcdoc.checker.type-not-assignable": "Typ %0% kann nicht dem Typ %1% zugewiesen werden", - "mcdoc.node.compound-definition": "eine zusammengesetzte Definition", - "mcdoc.node.enum-definition": "eine Enumerations-Definition", - "mcdoc.node.identifier": "ein Identifizierer", - "mcdoc.parser.compound-definition.field-type": "ein Feldtyp", - "mcdoc.parser.float.illegal": "Ung\xFCltige Flie\xDFkommazahl gefunden", - "mcdoc.parser.identifier.illegal": "%0% entspricht nicht dem Format von %1%", - "mcdoc.parser.identifier.reserved-word": "%0% ist ein reserviertes Wort und kann nicht als Identifizierungsname verwendet werden", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "Dynamische Indizierung ist nicht erlaubt", - "mcdoc.parser.inject-clause.definition-expected": "Erwartet wurde entweder ein Enum-Inject oder ein Compound-Inject", - "mcdoc.parser.keyword.separation": "eine Trennung", - "mcdoc.parser.resource-location.colon-expected": "Erwarteter Doppelpunkt (%0%) der Ressourcenstandorte", - "mcdoc.parser.syntax.doc-comment-unexpected": "Doc-Kommentare sind hier nicht erlaubt; Sie sollten die drei Schr\xE4gstriche durch zwei Schr\xE4gstriche ersetzen", - "mcdoc.runtime.checker.key-value-pair": "ein Schl\xFCssel-Wert-Paar", - "mcdoc.runtime.checker.range.collection": "Kollektionsl\xE4nge soll %0% betragen", - "mcdoc.runtime.checker.range.concat": "%0% und %1%", - "mcdoc.runtime.checker.range.left-exclusive": "\xFCber %0%", - "mcdoc.runtime.checker.range.left-inclusive": "mindestens %0%", - "mcdoc.runtime.checker.range.number": "numerischer Wert soll %0% sein", - "mcdoc.runtime.checker.range.right-exclusive": "unter %0%", - "mcdoc.runtime.checker.range.right-inclusive": "h\xF6chstens %0%", - "mcdoc.runtime.checker.range.string": "Zeichenkettenl\xE4nge soll %0% sein", - "mcdoc.runtime.checker.some-missing-keys": "Mindestens einer der Schl\xFCssel fehlt %0%", - "mcdoc.runtime.checker.trailing": "Nachgestellte Daten gefunden", - "mcdoc.runtime.checker.value": "ein Wert", - "mcdoc.type.boolean": "ein Boolescher Wert", - "mcdoc.type.byte": "ein Byte", - "mcdoc.type.byte_array": "ein Byte-Array", - "mcdoc.type.double": "ein Double", - "mcdoc.type.float": "ein Float", - "mcdoc.type.int": "ein Integer", - "mcdoc.type.int_array": "ein Integer-Array", - "mcdoc.type.list": "eine Liste", - "mcdoc.type.long": "ein Long", - "mcdoc.type.long_array": "ein Long-Array", - "mcdoc.type.short": "ein Short", - "mcdoc.type.string": "ein String", - "mcdoc.type.struct": "eine karten\xE4hnliche", - "mcfunction.checker.command.data-modify-unapplicable-operation": "Operation %0% kann nur auf %1% angewendet werden; Zielpfad hat stattdessen Type %2%", - "mcfunction.completer.block.states.default-value": "Standard: %0%", - "mcfunction.parser.command-too-long": "Befehl mit L\xE4nge %0% ist l\xE4nger als die maximale L\xE4nge %1%", - "mcfunction.parser.duplicate-components": "Doppelte Komponente", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% kann hier nicht angewendet werden", - "mcfunction.parser.entity-selector.arguments.unknown": "Unbekanntes Entit\xE4ts-Auswahl Argument %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "Der Selektor enth\xE4lt Nicht-Spieler-Entit\xE4ten", - "mcfunction.parser.entity-selector.invalid": "Ung\xFCltiger Entit\xE4tsselektor: \u201E%0%\u201C", - "mcfunction.parser.entity-selector.multiple-disallowed": "Der Selektor enth\xE4lt mehrere Entit\xE4ten", - "mcfunction.parser.entity-selector.player-name.too-long": "Spielernamen k\xF6nnen nicht l\xE4nger als %0% Zeichen sein", - "mcfunction.parser.eoc-unexpected": "Mehr Argumente erwartet", - "mcfunction.parser.leading-slash": "einen f\xFChrenden Schr\xE4gstrich \u201E/\u201C", - "mcfunction.parser.leading-slash.unexpected": "Unerwarteter f\xFChrender Schr\xE4gstrich \u201E/\u201C", - "mcfunction.parser.macro.at-least-one": "mindestens ein Makro-Argument", - "mcfunction.parser.macro.disallowed": "Makro-Zeilen werden erst seit Version 1.20.2 unterst\xFCtzt", - "mcfunction.parser.macro.illegal-key": "Unzul\xE4ssiges Schl\xFCsselzeichen: \u201E%0%\u201C", - "mcfunction.parser.macro.key": "eine Makro-Taste", - "mcfunction.parser.no-permission": "Die Berechtigungsstufe %0% ist erforderlich, die h\xF6her ist als die in der Konfiguration definierte Stufe %1%", - "mcfunction.parser.objective.too-long": "Objektivnamen d\xFCrfen nicht l\xE4nger als %0% Zeichen sein", - "mcfunction.parser.range.min>max": "Der Mindestwert %0% ist gr\xF6\xDFer als Maximalwert %1%", - "mcfunction.parser.range.span-too-large": "Der Bereichswert %0% ist gr\xF6\xDFer als der Maximalwert %1%", - "mcfunction.parser.range.span-too-small": "Der Bereichswert %0% ist kleiner als der Mindestwert %1%", - "mcfunction.parser.score_holder.fake-name.too-long": "Fake-Namen d\xFCrfen nicht l\xE4nger als %0% Zeichen sein", - "mcfunction.parser.sep": "ein Leerzeichen (%0%)", - "mcfunction.parser.trailing": "Nachgestellte Daten gefunden: %0%", - "mcfunction.parser.unknown-parser": "Der Parser %0% wird noch nicht unterst\xFCtzt", - "mcfunction.parser.uuid.invalid": "Ung\xFCltiges UUID Format", - "mcfunction.parser.vector.local-disallowed": "Lokale Koordinaten nicht zul\xE4ssig", - "mcfunction.parser.vector.mixed": "Lokale Koordinaten und Weltkoordinaten k\xF6nnen nicht miteinander kombiniert werden", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: Argument-Parser `%0%`](https://minecraft.fandom.com/wiki/Argument_types#%0%)", - "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: Befehl `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", - "mismatching-regex-pattern": "Wert stimmt nicht mit Regex \xFCberein: %0%", - "missing-key": "Fehlender Schl\xFCssel %0%", - "nbt.checker.block-states.fake-boolean": "Boolesche Blockzustandswerte sollten in Anf\xFChrungszeichen gesetzt werden", - "nbt.checker.block-states.unexpected-value-type": "Blockzustandswerte sollten entweder eine Zeichenkette oder eine Ganzzahl sein", - "nbt.checker.block-states.unknown-state": "Unbekannter Blockstatus %0% f\xFCr die folgenden Bl\xF6cke: %1%", - "nbt.checker.boolean.out-of-range": "Ein boolescher Wert sollte entweder %0% oder %1% sein", - "nbt.checker.collection.length-between": "%0% mit L\xE4nge zwischen %1% und %2%", - "nbt.checker.compound.field.union-empty-members": "Unerlaubte Eigenschaft", - "nbt.checker.path.index-out-of-bound": "Der angegebene Index %0% liegt au\xDFerhalb des Bereichs, da die Sammlung h\xF6chstens %1% Elemente enthalten kann", - "nbt.checker.path.unexpected-filter": "Zusammengesetzte Filter k\xF6nnen nur f\xFCr zusammengesetzte Tags verwendet werden", - "nbt.checker.path.unexpected-index": "Indizes k\xF6nnen nur f\xFCr Array- oder Listen-Tags verwendet werden", - "nbt.checker.path.unexpected-key": "String-Schl\xFCssel k\xF6nnen nur f\xFCr zusammengesetzte Tags angegeben werden", - "nbt.node": "ein Tag", - "nbt.node.byte": "ein Byte-Tag", - "nbt.node.byte_array": "ein Byte-Array-Tag", - "nbt.node.compound": "ein zusammengesetztes Tag", - "nbt.node.double": "ein Double-Tag", - "nbt.node.float": "ein Float-Tag", - "nbt.node.int": "ein Integer-Tag", - "nbt.node.int_array": "ein Integer-Array-Tag", - "nbt.node.list": "ein Listen-Tag", - "nbt.node.long": "ein Long-Tag", - "nbt.node.long_array": "ein Long-Array-Tag", - "nbt.node.path.end": "das Ende des Pfades", - "nbt.node.path.filter": "ein zusammengesetzter Filter", - "nbt.node.path.index": "ein Index", - "nbt.node.path.key": "ein Schl\xFCssel", - "nbt.node.short": "ein Short-Tag", - "nbt.node.string": "ein String-Tag", - "nbt.parser.number.out-of-range": "Dies sieht aus wie %0%, ist aber tats\xE4chlich %1%, da der Zahlenwert au\xDFerhalb von [%2%, %3%] liegt", - "nbt.path": "ein NBT-Pfad", - "not-allowed-here": "Der Wert %0% ist hier nicht erlaubt", - "not-divisible-by": "Der Wert %0% ist nicht durch %1% teilbar", - "not-matching-any-child": "Ung\xFCltiger Argumenttyp", - nothing: "nichts", - number: "eine Zahl", - "number-range": "einen Wertebereich", - "number-range.missing-min-and-max": "Minimaler oder maximaler Wert erwartet", - "number.<=": "eine Zahl kleiner oder gleich %0%", - "number.>=": "eine Zahl gr\xF6\xDFer oder gleich %0%", - "number.between": "eine Zahl zwischen %0% und %1%", - object: "ein Objekt", - objective: "ein Ziel", - "objective-not-following-convention": "Ung\xFCltiges Ziel %0%, das nicht der Konvention %1% entspricht", - "parser.float.illegal": "Unzul\xE4ssige Gleitkommazahl, die nicht %0% folgt", - "parser.integer.illegal": "Unzul\xE4ssige Ganzzahl, die nicht %0% folgt", - "parser.line-continuation-end-of-file": "Eine Zeilenfortsetzung darf nicht das Ende der Datei sein", - "parser.list.trailing-sep": "Nachlaufende Trennung", - "parser.list.value": "ein Wert", - "parser.long.illegal": "Unzul\xE4ssige Long Zahl, die nicht %0% folgt", - "parser.record.key": "ein Schl\xFCssel", - "parser.record.trailing-end": "Nachlaufende Trennung", - "parser.record.unexpected-char": "Unerwartetes Zeichen %0%", - "parser.record.value": "ein Wert", - "parser.resource-location.illegal": "Unzul\xE4ssige(s) Zeichen: %0%", - "parser.resource-location.namespace-expected": "Namensr\xE4ume d\xFCrfen hier nicht weggelassen werden", - "parser.resource-location.tag-disallowed": "Tags sind hier nicht erlaubt", - "parser.resource-location.tag-required": "Nur Tags sind hier erlaubt", - "parser.string.illegal-brigadier": "In %0% sind andere Zeichen als [0-9A-Za-z_.+-] aufgetreten", - "parser.string.illegal-escape": "Unerwartetes Escape-Zeichen %0%", - "parser.string.illegal-quote": "Nur %0% kann hier als Anf\xFChrungszeichen f\xFCr Zeichenketten verwendet werden", - "parser.string.illegal-unicode-escape": "Hexadezimalziffer erwartet", - "progress.initializing.title": "Spyglass wird initialisiert\u2026", - "progress.reset-project-cache.title": "Projekt-Cache wird zur\xFCckgesetzt\u2026", - "punc.period": ".", - "punc.quote": "\u201E%0%\u201C", - quote: "ein Anf\xFChrungszeichen (\u201E'\u201C oder \u201E'\u201C)", - quote_prefer_double: 'Doppelte Anf\xFChrungszeichen (\u201E"\u201C) sind hier zu bevorzugen', - quote_prefer_single: "Einfache Anf\xFChrungszeichen (\u201E'\u201C) sind hier zu bevorzugen", - "resource-location": "einen Ressourcenstandort", - "score-holder": "einen Punktehalter", - "scoreholder-not-following-convention": "Ung\xFCltiger Punktehalter %0%, der nicht der Konvention %1% entspricht", - selector: "einen Selektor", - "server.new-version": "Der Datapack Language Server wurde aktualisiert: %0%", - "server.progress.fixing-workspace.begin": "Behebe alle automatisch behebbaren Probleme im Arbeitsbereich", - "server.progress.fixing-workspace.report": "behebe %0%", - "server.progress.preparing.title": "Vorbereiten der Spyglass-Sprachfunktionen", - "server.remove-cache-file": "Der Cache von DHP wurde in ein Verzeichnis von VSCode verschoben. Der \u201E.datapack\u201C-Ordner im Arbeitsbereich kann nun gel\xF6scht werden.", - "server.show-release-notes": "Versionsinformationen anzeigen", - string: "eine Zeichenkette", - tag: "einen Tag", - "tag-not-following-convention": "Ung\xFCltiger Tag %0%, der nicht der Konvention %1% entspricht", - team: "ein Team", - "team-not-following-convention": "Ung\xFCltiges Team %0%, das nicht der Konvention %1% entspricht", - "text-component": "eine Textkomponente", - "time-unit": "eine Zeiteinheit", - "too-many-block-affected": "Zu viele Bl\xF6cke im angegebenen Bereich (maximal %0%, angegeben %1%)", - "too-many-chunk-affected": "Zu viele Chunks im angegebenen Bereich (maximal %0%, angegeben %1%)", - "unexpected-character": "Zeichen gefunden, die nicht [a-z0-9/._-] entsprechen", - "unexpected-datapack-tag": "Aliasse sind hier nicht erlaubt", - "unexpected-default-namespace": "Der Standardnamensraum sollte hier ausgelassen werden", - "unexpected-local-coordinate": "Lokale Koordinate %0% ist nicht erlaubt", - "unexpected-nbt": "Diese Eigenschaft existiert hier nicht", - "unexpected-nbt-array-type": "Ung\xFCltiger Array-Typ %0%. Sollte entweder \u201EB\u201C, \u201EI\u201C oder \u201EL\u201C sein", - "unexpected-nbt-path-filter": "Pfadfilter funktionieren nur mit Compound-Eigenschaften", - "unexpected-nbt-path-index": "Indizes funktionieren nur mit Listen oder Array-Eigenschaften", - "unexpected-nbt-path-key": "Schl\xFCssel funktionieren nur mit Compound-Eigenschaften", - "unexpected-nbt-path-sub": "Die aktuelle Eigenschaft hat keine weiteren Elemente", - "unexpected-omitted-default-namespace": "Der Standardnamensraum kann hier nicht ausgelassen werden", - "unexpected-relative-coordinate": "Die relative Koordinate %0% ist nicht erlaubt", - "unexpected-scoreboard-sub-slot": "Nur \u201Esidebar\u201C hat Unterkategorien", - "unknown-command": "Unbekannter Befehl %0%", - "unknown-escape": "Unerwartetes Escape-Zeichen %0%", - "unknown-key": "Unbekannter Schl\xFCssel %0%", - "unquoted-string": "eine Zeichenkette ohne Anf\xFChrungszeichen", - "unsorted-keys": "Unsortierte Schl\xFCssel", - uuid: "eine UUID", - vector: "einen Vektor" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/es.json -var es_exports = {}; -__export(es_exports, { - default: () => es_default -}); -var es_default; -var init_es = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/es.json"() { - es_default = { - array: "un array", - boolean: "un booleano", - "bug-of-mc": "Debido a un error de Minecraft (%0%), %1%. Por favor Mojang, arreglen su juego", - "code-action.block-state-sort-keys": "Discriminar estado de bloque (block state)", - "code-action.command-replaceitem": "Actualizar este commando a /item ... replace", - "code-action.fix-file": "Arreglar todos los problemas auto-arreglables en este archivo", - "code-action.fix-workspace": "Arreglar todos los problemas auto-arreglables en este espacio de trabajo", - "code-action.id-attribute-datafix": "Actualizar este nombre de atributo a la 1.16", - "code-action.id-complete-default-namespace": "Completar el namespace por defecto", - "code-action.id-create-file": "Crear %0% en el mismo paquete de datos", - "code-action.id-omit-default-namespace": "Omitir namespace por defecto", - "code-action.id-zombified-piglin-datafix": "Cambiar este identificador por el del Piglin Zombificado", - "code-action.nbt-compound-sort-keys": "Discriminar etiqueta compuesta de NBT", - "code-action.nbt-type-to-byte": "Convertir a una etiqueta NBT de octeto (byte)", - "code-action.nbt-type-to-double": "Convertir a una etiqueta NBT de coma flotante doble (double)", - "code-action.nbt-type-to-float": "Convertir a una etiqueta NBT de coma flotante (float)", - "code-action.nbt-type-to-int": "Convertir a una etiqueta NBT de n\xFAmero entero (int)", - "code-action.nbt-type-to-long": "Convertir a una etiqueta NBT de n\xFAmero largo (long)", - "code-action.nbt-type-to-short": "Convertir a una etiqueta NBT de n\xFAmero corto (short)", - "code-action.nbt-uuid-datafix": "Actualizar este Identificador \xDAnico a la 1.16", - "code-action.selector-sort-keys": "Discriminar por argumentos de selector", - "code-action.string-double-quote": 'A\xF1adir comillas dobles (") a esta cadena', - "code-action.string-single-quote": 'A\xF1adir comillas singular (") a esta cadena', - "code-action.string-unquote": "Remover comillas de esta cadena", - "code-action.vector-align-0.0": "Alinear este vector al punto de origen del bloque", - "code-action.vector-align-0.5": "Alinear este vector al centro del bloque", - comment: "un comentario comenzando con %0%", - "conjunction.and_2": " y ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", y ", - "conjunction.or_2": " o ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", o ", - "datafix.error.command-replaceitem": "/replaceitem fue removido en la 20w46a (segunda snapshot de la 1.17) en favor de /item", - "duplicate-key": "Llave duplicada %0%", - "ending-quote": "una comilla cerrando %0%", - entity: "una entidad", - "error.unparseable-content": "Contenido no analizable encontrado", - expected: "Esperado %0%", - "expected-got": "Esperado %0% pero se encontr\xF3 %0%", - float: "un n\xFAmero de coma flotante (float)", - "float.between": "un n\xFAmero de coma flotante (float) entre %0% y %1%", - integer: "un n\xFAmero entero", - "integer.between": "un n\xFAmero entero entre %0% y %1%", - "json.checker.item.duplicate": "Lista de objetos duplicados", - "json.checker.property.deprecated": "Propiedad %0% es obsoleta", - "json.checker.property.missing": "Propiedad %0% faltante", - "json.checker.property.unknown": "Propiedad %0% desconocida", - "json.checker.string.hex-color": "un n\xFAmero hexademical de 6 d\xEDgitos", - "json.checker.tag-entry.duplicate": "Entrada de etiqueta duplicada", - "json.doc.advancement.display": "Configuraci\xF3n de visualizaci\xF3n del avance. Si est\xE1 presenta, el avance ser\xE1 visible en la pesta\xF1a de Progresos.", - "key-not-following-convention": "Llave %0% invalida por no seguir la convenci\xF3n %1%", - "linter-config-validator.name-convention.type": "Espera una cadena que contenga una expresi\xF3n regular describiendo el nombre", - "linter-config-validator.wrapper": "%0%. Vea [la documentaci\xF3n](%1) para m\xE1s informaci\xF3n", - "linter.diagnostic-message-wrapper": "%0% (regla: %1%)", - "linter.name-convention.illegal": "El nombre %0% no coincide con %1%", - "linter.undeclared-symbol.message": "No se pudo encontrar %0% %1%", - long: "un n\xFAmero largo (long)", - "mcdoc.binder.duplicated-declaration": "Declaraci\xF3n duplicada para %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% ya ha sido declarado aqu\xED", - "mcdoc.binder.out-of-root": "El archivo %0% no esta bajo el directorio raiz de ning\xFAn proyecto de mcdoc; se omitir\xE1 el revisado de sem\xE1ntica", - "mcdoc.binder.path.super-from-root": "No se puede acceder a la super de la ra\xEDz del proyecto", - "mcdoc.binder.path.unknown-identifier": "El identificador %0% no existe en el m\xF3dulo %1%", - "mcdoc.binder.path.unknown-module": "El m\xF3dulo %0% no existe", - "mcdoc.checker.entry.empty-mod-seg": "No puedes colocar \u201Cmod.mcdoc\u201D bajo una ra\xEDz directamente", - "mcdoc.checker.inject-clause.unmatched-injection": "No se puede injectar %0% con %1%", - "mcdoc.checker.type-not-assignable": "Tipo %0% no es asignable a tipo %1%", - "mcdoc.node.compound-definition": "una definici\xF3n compuesta", - "mcdoc.node.identifier": "un identificador", - "mcdoc.parser.float.illegal": "Se econtr\xF3 un n\xFAmero de coma flotante (float) ilegal", - "mcdoc.parser.identifier.illegal": "%0% no sigue el formato de %1%", - "mcdoc.parser.identifier.reserved-word": "%0% es una palabra reservada y no puede ser usado como nombre identificador", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "El \xEDndexado din\xE1mico no est\xE1 permitido", - "mcdoc.parser.keyword.separation": "una separaci\xF3n", - "mcfunction.checker.command.data-modify-unapplicable-operation": "Operaci\xF3n %0% s\xF3lo puede ser usada con %1%; el camino del objetivo tiene, en cambio, %2%", - "mcfunction.completer.block.states.default-value": "For defecto: %0%", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% no es aplicable aqu\xED", - "mcfunction.parser.entity-selector.arguments.unknown": "Argumento de selector de entidades desconocido %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "El selector contiene entidades que no son jugadores", - "mcfunction.parser.entity-selector.multiple-disallowed": "El selector contiene multiples entidades", - "mcfunction.parser.entity-selector.player-name.too-long": "Los nombres de jugadores no pueden tener m\xE1s de %0% caracteres", - "mcfunction.parser.eoc-unexpected": "M\xE1s argumentos esperados", - "mcfunction.parser.no-permission": "Se requiere permiso de nivel %0%, el cual es mayor que el definido en configuraci\xF3n: %1%", - "mcfunction.parser.objective.too-long": "Los nombres de los objetivos no pueden tener m\xE1s de %0% caracteres", - "mcfunction.parser.range.min>max": "El valor m\xEDnimo (%0%) es m\xE1s largo que el valor m\xE1ximo (%1%)", - "mcfunction.parser.score_holder.fake-name.too-long": "Nombres falsos no pueden tener m\xE1s de %0% caracteres", - "mcfunction.parser.sep": "un espacio (%0%)", - "mcfunction.parser.unknown-parser": "El analizador %0% a\xFAn no es soportado", - "mcfunction.parser.uuid.invalid": "Formato de Identificador \xDAnico inv\xE1lido", - "mcfunction.parser.vector.local-disallowed": "No est\xE1n permitidas las coordenadas locales", - "mcfunction.parser.vector.mixed": "No se pueden mezclar juntas las coordenadas locales y coordenadas del mundo", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: argumento `%0%` de Brigadier](https://minecraft.fandom.com/wiki/Argument_types#%0%)", - "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: comando `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", - "missing-key": "Llave faltante %0%", - "nbt.checker.block-states.fake-boolean": "Valores de estado de bloque binarios deber\xEDan estar marcados con comillas", - "nbt.checker.block-states.unexpected-value-type": "Los valores de estado de bloque deber\xEDan ser, ya sea, una cadena o un n\xFAmero entero (int)", - "nbt.checker.block-states.unknown-state": "Estado de bloque %0% desconocido para el(los) siguiente(s) bloque(s): %1%", - "nbt.checker.boolean.out-of-range": "Un valor booleano deber\xEDa ser, ya sea, %0% o %1%", - "nbt.checker.collection.length-between": "%0% con una longitud de entre %1% y %2%", - "nbt.checker.compound.field.union-empty-members": "Propiedad no permitida", - "nbt.checker.path.index-out-of-bound": "El \xEDndice proporcionado (%0%) est\xE1 fuera de los l\xEDmites, ya que la colecci\xF3n s\xF3lo puede tener, al menos %1% elementos", - "nbt.checker.path.unexpected-filter": "Los filtros de datos compuestos s\xF3lo pueden ser usados en etiquetas compuestas", - "nbt.checker.path.unexpected-index": "\xCDndices s\xF3lo pueden ser usados en arrays o en listas con etiquetas", - "nbt.checker.path.unexpected-key": "S\xF3lo pueden especificarse llaves de cadena para etiquetas compuestas", - "nbt.node": "una etiqueta", - "nbt.node.byte": "una etiqueta de tipo octeto (byte)", - "nbt.node.byte_array": "una etiqueta de array de tipo octeto (byte)", - "nbt.node.compound": "una etiqueta compuesta", - "nbt.node.double": "una etiqueta de tipo coma flotante doble (double)", - "nbt.node.float": "una etiqueta de coma flotante (float)", - "nbt.node.int": "una etiqueta de n\xFAmero entero (int)", - "nbt.node.int_array": "una etiqueta de array de n\xFAmero entero (int)", - "nbt.node.list": "una etiqueta de lista", - "nbt.node.long": "una etiqueta de n\xFAmero largo (long)", - "nbt.node.long_array": "una etiqueta de array de n\xFAmero largo (long)", - "nbt.node.path.end": "el final del camino", - "nbt.node.path.filter": "un filtro compuesto", - "nbt.node.path.index": "un \xEDndice", - "nbt.node.path.key": "una llave", - "nbt.node.short": "una etiqueta de n\xFAmero corto (short)", - "nbt.node.string": "una etiqueta de cadena", - "nbt.parser.number.out-of-range": "Esto luce similar a %0%, pero de hecho es %1% debido al valor num\xE9rico estando fuera de [%2%, %3%]", - "not-matching-any-child": "Tipo de argumento inv\xE1lido", - nothing: "nada", - number: "un n\xFAmero", - "number-range": "un rango num\xE9rico", - "number-range.missing-min-and-max": "Se esperaba, ya sea, un valor m\xEDnimo o un valor m\xE1ximo", - "number.<=": "un n\xFAmero igual o menor a %0%", - "number.>=": "un n\xFAmero igual o mayor que %0%", - "number.between": "un n\xFAmero entre %0% y %1%", - object: "un objeto", - objective: "un objetivo", - "objective-not-following-convention": "Objetivo %0% inv\xE1lido que no sigue la convenci\xF3n %1%", - "parser.float.illegal": "N\xFAmero de coma flotante (float) illegal por no segu\xEDr %0%", - "parser.integer.illegal": "N\xFAmero entero (int) illegal por no segu\xEDr %0%", - "parser.list.value": "un valor", - "parser.record.key": "una llave", - "parser.record.unexpected-char": "Caracter %0% inesperado", - "parser.string.illegal-brigadier": "Se encontraron caracteres que no entran entre los caracteres permitidos [0-9A-Za-z_.+-] en %0%", - "parser.string.illegal-escape": "Escape de caracter %0% inesperado", - "parser.string.illegal-quote": "Solo %0% pueden ser usados para marcar cardenas aqu\xED", - "parser.string.illegal-unicode-escape": "D\xEDgito hexadecimal esperado", - "punc.period": ".", - "punc.quote": "\u201C%0%\u201D", - quote: `comillas (\u201C'\u201D o \u201C"\u201D)`, - quote_prefer_double: 'Comillas dobles (\u201C"\u201D) son preferidas aqu\xED', - quote_prefer_single: "Comillas singulares (\u201C'\u201D) son preferidas aqu\xED", - "resource-location": "posici\xF3n de recurso", - "score-holder": "una vacante de puntaje", - "scoreholder-not-following-convention": "Vacante de puntaje %0% inv\xE1lida por no seguir la convenci\xF3n %1%", - "server.new-version": "El Servidor del Lenguaje Data-pack ha sido actualizado a una nueva versi\xF3n: %0%", - "server.progress.fixing-workspace.begin": "Reparando todos los errors auto-reparables en el espacio de trabajo", - "server.progress.fixing-workspace.report": "arreglando %0%", - "server.progress.preparing.title": "Preparando funciones del lenguaje Spyglass", - "server.remove-cache-file": "El archivo cach\xE9 de DHP fue movido a una localizaci\xF3n provisionada por VSCode. Ahora puedes remover la fea carpeta \u201C.datapack\u201D en la ra\xEDz de tu espacio de trabajo.", - "server.show-release-notes": "Mostrar Notas de Lanzamientos", - string: "una cadena", - tag: "una etiqueta", - "tag-not-following-convention": "Etiqueta %0% inv\xE1lido" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/fr.json -var fr_exports = {}; -__export(fr_exports, { - default: () => fr_default -}); -var fr_default; -var init_fr = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/fr.json"() { - fr_default = { - array: "un tableau", - boolean: "un bool\xE9en", - "bug-of-mc": "\xC0 cause d'un bug de Minecraft (%0%), %1%. S'il vous pla\xEEt Mojang, corrigez votre jeu", - "code-action.add-default-namespace": "Ajouter un espace de nommage par d\xE9faut", - "code-action.block-state-sort-keys": "Trier les \xE9tats de bloc", - "code-action.command-replaceitem": "Mettre \xE0 jour cette commande sous la forme /item ... replace", - "code-action.create-undeclared-file": "Cr\xE9er %0% %1% dans le m\xEAme pack", - "code-action.fix-file": "Corriger tous les probl\xE8mes auto-corrigibles dans ce fichier", - "code-action.fix-workspace": "Corriger tous les probl\xE8mes auto-corrigibles dans l'espace de travail", - "code-action.id-attribute-datafix": "Mettre \xE0 jour ce nom d'attribut pour la 1.16", - "code-action.id-complete-default-namespace": "Compl\xE9ter l'espace de nommage par d\xE9faut", - "code-action.id-create-file": "Cr\xE9er %0% dans le m\xEAme pack de donn\xE9es", - "code-action.id-omit-default-namespace": "Omettre l'espace de nommage par d\xE9faut", - "code-action.id-zombified-piglin-datafix": "Changer cet ID en celui du Piglin zombifi\xE9", - "code-action.nbt-compound-sort-keys": "Trier les cl\xE9s du compound NBT", - "code-action.nbt-type-to-byte": "Convertir en octet NBT", - "code-action.nbt-type-to-double": "Convertir en double NBT", - "code-action.nbt-type-to-float": "Convertir en un flottant NBT", - "code-action.nbt-type-to-int": "Convertir en entier NBT", - "code-action.nbt-type-to-long": "Convertir en long NBT", - "code-action.nbt-type-to-short": "Convertir en short NBT", - "code-action.nbt-uuid-datafix": "Mettre \xE0 jour cet UUID pour la 1.16", - "code-action.selector-sort-keys": "Trier les arguments du s\xE9lecteur", - "code-action.string-double-quote": "Encadrer cette cha\xEEne de caract\xE8res avec des guillemets", - "code-action.string-single-quote": "Encadrer cette cha\xEEne de caract\xE8res avec des apostrophes", - "code-action.string-unquote": "Enlever les d\xE9limiteurs autour de cette cha\xEEne de caract\xE8res", - "code-action.vector-align-0.0": "Aligner ce vecteur \xE0 l'origine du bloc", - "code-action.vector-align-0.5": "Aligner ce vecteur au centre du bloc", - comment: "un commentaire commen\xE7ant par %0%", - "conjunction.and_2": " et ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", et ", - "conjunction.or_2": " ou ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", ou ", - "datafix.error.command-replaceitem": "/replaceitem a \xE9t\xE9 enlev\xE9 en 20w46a (la deuxi\xE8me snapshot de la 1.17) en faveur de /item", - "duplicate-key": "Cl\xE9 duplique %0%", - "ending-quote": "un guillemet de fermeture %0%", - entity: "une entit\xE9", - "error.unparseable-content": "Rencontr\xE9 du contenu non interpr\xE9table", - expected: "%0% attendu", - "expected-got": "Attendu %0% mais obtenu %1%", - float: "un flottant", - "float.between": "un flottant entre %0% et %1%", - integer: "un integer", - "integer.between": "un integer entre %0% et %1%", - "invalid-key-combination": "Combinaison de touches %0% invalide", - "invalid-regex-pattern": "Motif de regex invalide: %0%", - "java-edition.binder.wrong-folder": "Les fichiers dans le dossier %0% ne sont pas reconnus dans la version charg\xE9e %1%, ne vouliez vous pas plut\xF4t utiliser le dossier %2% ?", - "java-edition.binder.wrong-version": "Les fichiers dans le dossier %0% ne sont pas reconnus dans la version charg\xE9e %1%", - "java-edition.translation-value.percent-escape-hint": "%0%. Si vous voulez afficher un signe pourcent, utilisez \u201C%%\u201D \xE0 la place", - "json.checker.array.length-between": "%0% avec une longueur entre %1% et %2%", - "json.checker.item.duplicate": "Dupliquer la liste d'objets", - "json.checker.object.field.union-empty-members": "Propri\xE9t\xE9 refus\xE9e", - "json.checker.property.deprecated": "La propri\xE9t\xE9 %0% est obsol\xE8te", - "json.checker.property.missing": "Propri\xE9t\xE9 %0% manquante", - "json.checker.property.unknown": "Propri\xE9t\xE9 %0% inconnue", - "json.checker.string.hex-color": "un nombre hexad\xE9cimal \xE0 six chiffres", - "json.checker.tag-entry.duplicate": "Dupliquer la liste de tag", - "json.checker.value": "une valeur", - "json.doc.advancement.display": "Param\xE8tres d'affichages du progr\xE8s. Si pr\xE9sent, le progr\xE8s sera visible dans les onglets de progr\xE8s.", - "json.node.array": "un tableau", - "json.node.boolean": "un bool\xE9en", - "json.node.null": "un null", - "json.node.number": "un nombre", - "json.node.object": "un objet", - "json.node.string": "une cha\xEEne de caract\xE8res", - "key-not-following-convention": "Cl\xE9 invalide %0% qui ne suit pas la convention %1%", - "linter-config-validator.name-convention.type": "Attend un cha\xEEne de caract\xE8res contenant une expression r\xE9guli\xE8re qui d\xE9crit le nom", - "linter-config-validator.wrapper": "%0%. Lisez [la documentation](%1) pour plus d'informations", - "linter.diagnostic-message-wrapper": "%0% (r\xE8gle : %1%)", - "linter.name-convention.illegal": "Le nom %0% ne correspond pas \xE0 %1%", - "linter.undeclared-symbol.message": "N'arrive pas \xE0 trouver %0% %1%", - long: "un long", - "long.between": "un long entre %0% et %1%", - "mcdoc.binder.dispatcher-statement.duplicated-key": "Cas de r\xE9partiteur dupliqu\xE9 %0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% a d\xE9j\xE0 \xE9t\xE9 envoy\xE9 ici", - "mcdoc.binder.duplicated-declaration": "D\xE9claration dupliqu\xE9e pour %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% est d\xE9j\xE0 d\xE9clar\xE9 ici", - "mcdoc.binder.out-of-root": "Le fichier %0% ne se trouve pas dans le r\xE9pertoire racine d'un projet mcdoc ; la v\xE9rification s\xE9mantique sera ignor\xE9e", - "mcdoc.binder.path.super-from-root": "Impossible d'acc\xE9der au super de la racine du projet", - "mcdoc.binder.path.unknown-identifier": "L'identificateur %0% n'existe pas dans le module %1%", - "mcdoc.binder.path.unknown-module": "Le module %0% n'existe pas", - "mcdoc.checker.entry.empty-mod-seg": 'Vous ne pouvez pas mettre "mod.mcdoc" \xE0 la racine', - "mcdoc.checker.inject-clause.unmatched-injection": "Impossible d'injecter %0% avec %1%", - "mcdoc.checker.type-not-assignable": "Le type %0% n'est pas assignable au type %1%", - "mcdoc.node.compound-definition": "une d\xE9finition compos\xE9e", - "mcdoc.node.enum-definition": "une d\xE9finition \xE9num\xE9r\xE9e", - "mcdoc.node.identifier": "un identifiant", - "mcdoc.parser.compound-definition.field-type": "un type de champ", - "mcdoc.parser.float.illegal": "Nombre flottant ill\xE9gal rencontr\xE9", - "mcdoc.parser.identifier.illegal": "%0% ne respecte pas le format de %1%", - "mcdoc.parser.identifier.reserved-word": "%0% est un mot r\xE9serv\xE9 et ne peut \xEAtre utilis\xE9 comme nom d'identifiant", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "L'indexation dynamique n'est pas autoris\xE9e", - "mcdoc.parser.inject-clause.definition-expected": "Attendu soit une injection \xE9num\xE9r\xE9e, soit une injection compos\xE9e", - "mcdoc.parser.keyword.separation": "une s\xE9paration", - "mcdoc.parser.resource-location.colon-expected": "Attendu les deux-points (%0 %) aux emplacements de ressources", - "mcdoc.parser.syntax.doc-comment-unexpected": "Les commentaires de documentation ne sont pas autoris\xE9s ici\xA0; vous devrez peut-\xEAtre remplacer les trois barres obliques par deux barres obliques", - "mcdoc.runtime.checker.key-value-pair": "une paire cl\xE9-valeur", - "mcdoc.runtime.checker.range.concat": "%0% et %1%", - "mcdoc.runtime.checker.range.left-exclusive": "au-dessus de %0%", - "mcdoc.runtime.checker.range.left-inclusive": "au moins %0%", - "mcdoc.runtime.checker.range.right-exclusive": "en-dessous de %0%", - "mcdoc.runtime.checker.range.right-inclusive": "au plus %0%", - "mcdoc.runtime.checker.some-missing-keys": "Il manque au moins une des cl\xE9s %0%", - "mcdoc.runtime.checker.value": "une valeur", - "mcdoc.type.boolean": "un bool\xE9en", - "mcfunction.checker.command.data-modify-unapplicable-operation": "L'op\xE9ration %0% ne peut \xEAtre utilis\xE9 que sur %1%; le chemin cible a \xE0 la place un type %2%", - "mcfunction.completer.block.states.default-value": "D\xE9faut : %0%", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% n'est pas applicable ici", - "mcfunction.parser.entity-selector.arguments.unknown": "Argument de s\xE9lecteur d'entit\xE9 inconnu %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "Le s\xE9lecteur contient des entit\xE9s non joueur", - "mcfunction.parser.entity-selector.multiple-disallowed": "Le s\xE9lecteur contient plusieurs entit\xE9s", - "mcfunction.parser.entity-selector.player-name.too-long": "Les noms de joueurs ne peuvent pas avoir plus de %0% caract\xE8res", - "mcfunction.parser.eoc-unexpected": "Plus d'arguments attendus", - "mcfunction.parser.leading-slash": "une barre oblique \u201C/\u201D", - "mcfunction.parser.leading-slash.unexpected": "Slash \u201C/\u201D inattendu", - "mcfunction.parser.no-permission": "Le niveau de permission %0% est requis, mais le niveau de permission d\xE9fini en configuration est seulement %1%", - "mcfunction.parser.objective.too-long": "Les noms d'objectifs ne peuvent pas avoir plus que %0% caract\xE8res", - "mcfunction.parser.range.min>max": "La valeur minimale %0% est plus grande que la valeur maximale %1%", - "mcfunction.parser.score_holder.fake-name.too-long": "Les faux noms ne peuvent pas avoir plus que %0% caract\xE8res", - "mcfunction.parser.sep": "un espace (%0%)", - "mcfunction.parser.trailing": "Trouv\xE9 des donn\xE9es suppl\xE9mentaires \xE0 la fin", - "mcfunction.parser.unknown-parser": "L'analyseur %0% n'est pas support\xE9 pour le moment", - "mcfunction.parser.uuid.invalid": "Format d'UUID invalide", - "mcfunction.parser.vector.local-disallowed": "Coordonn\xE9es locales interdites", - "mcfunction.parser.vector.mixed": "Les coordonn\xE9es locales et absolues/relatives ne peuvent pas \xEAtre m\xE9lang\xE9es", - "mcfunction.signature-help.command-documentation": "[Wiki Minecraft : commande `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", - "mismatching-regex-pattern": "La valeur ne correspond pas \xE0 la regex: %0%", - "missing-key": "Cl\xE9 %0% manquante", - "nbt.checker.block-states.fake-boolean": "Les \xE9tats de blocs bool\xE9ens doivent \xEAtre mises entre guillemets", - "nbt.checker.block-states.unexpected-value-type": "Les valeurs des \xE9tats de blocs doivent \xEAtre soit une cha\xEEne de caract\xE8res soit un nombre entier", - "nbt.checker.block-states.unknown-state": "\xC9tat de bloc %0% inconnu pour le(s) bloc(s) suivant(s) : %1%", - "nbt.checker.boolean.out-of-range": "Une valeur bool\xE9enne devrait \xEAtre soit %0% soit %1%", - "nbt.checker.collection.length-between": "%0% de longueur comprise entre %1% et %2%", - "nbt.checker.compound.field.union-empty-members": "Propri\xE9t\xE9 interdite", - "nbt.checker.path.index-out-of-bound": "L'indice %0% fourni est hors limite, car la collection ne peut contenir que %1% d'\xE9l\xE9ments maximum", - "nbt.checker.path.unexpected-filter": "Les filtres compos\xE9s ne peuvent \xEAtre utilis\xE9s que sur des \xE9tiquettes compos\xE9es", - "nbt.checker.path.unexpected-index": "Les indices ne peuvent \xEAtre utilis\xE9s que dans des tableaux ou des listes", - "nbt.checker.path.unexpected-key": "Les cl\xE9s de type cha\xEEne ne peuvent \xEAtre sp\xE9cifi\xE9es que pour les \xE9tiquettes compos\xE9es", - "nbt.node": "un tag", - "nbt.node.byte": "un octet", - "nbt.node.byte_array": "un tableau d'octets", - "nbt.node.compound": "un tag compos\xE9", - "nbt.node.double": "un tag de nombre double", - "nbt.node.float": "un tag de nombre flottant", - "nbt.node.int": "un tag de nombre entier", - "nbt.node.int_array": "un tag de liste d'entier", - "nbt.node.list": "un tag de liste", - "nbt.node.long": "un tag d'entier long", - "nbt.node.long_array": "un tag de liste d'entier long", - "nbt.node.path.end": "La fin du chemin", - "nbt.node.path.filter": "un filtre compos\xE9", - "nbt.node.path.index": "un indice", - "nbt.node.path.key": "une cl\xE9", - "nbt.node.short": "une \xE9tiquette courte", - "nbt.node.string": "un tag \xE0 cha\xEEne de caract\xE8res", - "nbt.parser.number.out-of-range": "Cela ressemble \xE0 %0%, mais c'est en fait %1% car la valeur du chiffre est hors de [%2%, %3%]", - "not-matching-any-child": "Type d'argument invalide", - nothing: "rien", - number: "un nombre", - "number-range": "un intervalle de valeur", - "number-range.missing-min-and-max": "Attendu une valeure minimale ou une valeure maximale", - "number.<=": "un nombre inf\xE9rieur ou \xE9gal \xE0 %0%", - "number.>=": "un nombre sup\xE9rieur ou \xE9gal \xE0 %0%", - "number.between": "un nombre entre %0% et %1%", - object: "un objet", - objective: "un objectif", - "objective-not-following-convention": "L'objectif %0% est invalide car elle ne respecte pas la convention %1%", - "parser.float.illegal": "Chiffre flottant ill\xE9gal qui ne suit pas %0%", - "parser.integer.illegal": "Entier ill\xE9gal qui ne suit pas %0%", - "parser.list.trailing-sep": "S\xE9paration \xE0 la fin", - "parser.list.value": "une valeur", - "parser.record.key": "une cl\xE9", - "parser.record.trailing-end": "S\xE9paration \xE0 la fin", - "parser.record.unexpected-char": "Caract\xE8re %0% inattendu", - "parser.record.value": "une valeur", - "parser.resource-location.illegal": "Caract\xE8re(s) inattendu(s) : %0%", - "parser.resource-location.namespace-expected": "Les espaces de noms ne peuvent pas \xEAtre omis ici", - "parser.resource-location.tag-disallowed": "Les tags ne sont pas autoris\xE9s ici", - "parser.string.illegal-brigadier": "Des caract\xE8res autres que [0-9A-Za-z_.+-] ont \xE9t\xE9 rencontr\xE9s dans %0%", - "parser.string.illegal-escape": "Caract\xE8re d'\xE9chappement inattendu %0%", - "parser.string.illegal-quote": "Seuls %0% peuvent \xEAtre utilis\xE9s pour citer des cha\xEEnes de caract\xE8res", - "parser.string.illegal-unicode-escape": "Chiffre hexad\xE9cimal attendu", - "punc.period": ".", - "punc.quote": "\u201C%0%\u201D", - quote: `un guillemet (\u201C"\u201D) ou une apostrophe (\u201C'\u201D)`, - quote_prefer_double: 'Des guillemets (\u201C"\u201D) sont pr\xE9f\xE9rables ici', - quote_prefer_single: "Une apostrophe (\u201C'\u201D) est pr\xE9f\xE9rable ici", - "resource-location": "un emplacement de ressource", - "score-holder": "un score holder", - "scoreholder-not-following-convention": "Le score_holder %0% est invalide car il ne respecte pas la convention %1%", - "server.new-version": "Le Data-pack Language Server a \xE9t\xE9 mis \xE0 jour vers une version plus r\xE9cente : %0%", - "server.progress.fixing-workspace.begin": "Correction de tous les probl\xE8mes auto-corrigibles dans l'espace de travail", - "server.progress.fixing-workspace.report": "correction de %0%", - "server.progress.preparing.title": "Pr\xE9paration des caract\xE9ristiques du langage Spyglass", - "server.remove-cache-file": "Le fichier de cache a \xE9t\xE9 d\xE9plac\xE9 au chemin donn\xE9 par VSCode. Vous pouvez supprimer sans risque le dossier \u201C.datapack\u201D du dossier racine de votre espace de travail.", - "server.show-release-notes": "Afficher les notes de version", - string: "un string", - tag: "un tag", - "tag-not-following-convention": "Le tag %0% est invalide car il ne respecte pas la convention %1%", - team: "une \xE9quipe", - "team-not-following-convention": "L'\xE9quipe %0% est invalide car elle ne respecte pas la convention %1%", - "time-unit": "une unit\xE9 de temps", - "too-many-block-affected": "Trop de blocs dans la zone sp\xE9cifi\xE9e (%0% au maximum, %1% sp\xE9cifi\xE9s)", - "too-many-chunk-affected": "Trop de tron\xE7ons dans la zone sp\xE9cifi\xE9e (maximum %0%, sp\xE9cifi\xE9 %1%)", - "unexpected-character": "Trouv\xE9 un caract\xE8re(s) non-[a-z0-9/._-]", - "unexpected-datapack-tag": "Les tags ne sont pas admis ici", - "unexpected-default-namespace": "L'espace de nommage par d\xE9faut devrait \xEAtre omis ici", - "unexpected-local-coordinate": "La coordonn\xE9e locale %0% n'est pas admise", - "unexpected-nbt": "Ce tag n\u2019existe pas", - "unexpected-nbt-array-type": "Type de tableau invalide %0%. Devrait \xEAtre \u201CB\u201D, \u201CI\u201D, ou \u201CL\u201D", - "unexpected-nbt-path-filter": "Les filtres de champs sont seulement utilis\xE9s pour les tags de champs", - "unexpected-nbt-path-index": "Les indices sont seulement utilis\xE9s pour les tags de listes/tableaux", - "unexpected-nbt-path-key": "Les cl\xE9s sont seulement utilis\xE9es pour les tags de champs", - "unexpected-nbt-path-sub": "Ce tag n'a pas d'items suppl\xE9mentaires", - "unexpected-omitted-default-namespace": "L'espace de nom par d\xE9faut ne peut \xEAtre omis ici", - "unexpected-relative-coordinate": "La coordonn\xE9e relative %0% n'est pas admise", - "unexpected-scoreboard-sub-slot": "Seulement \u201Csidebar\u201D a des sous-emplacements", - "unknown-command": "Commande inconnue %0%", - "unknown-escape": "Caract\xE8re d'\xE9chappement %0% inattendu", - "unknown-key": "Cl\xE9 inconnue %0%", - "unquoted-string": "une cha\xEEne de caract\xE8res sans d\xE9limiteurs", - "unsorted-keys": "Cl\xE9s non tri\xE9es", - uuid: "un UUID", - vector: "un vecteur" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/it.json -var it_exports = {}; -__export(it_exports, { - default: () => it_default -}); -var it_default; -var init_it = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/it.json"() { - it_default = { - array: "un array", - boolean: "un booleano", - "code-action.block-state-sort-keys": "Ordina stato blocco", - "code-action.fix-file": "Aggiusta tutti i problemi auto-aggiustabili in questo file", - "code-action.fix-workspace": "Aggiusta tutti i problemi auto-aggiustabili nel spazio di lavoro", - "code-action.id-attribute-datafix": "Aggiorna il nome di questo attributo a 1.16", - "code-action.id-complete-default-namespace": "Completa il namespace predefinito", - "code-action.id-omit-default-namespace": "Ommetti il namespace predefinito", - "code-action.id-zombified-piglin-datafix": "Cambia questo ID a quello di un Piglin Zombificato", - "code-action.nbt-compound-sort-keys": "Ordina i tag NBT composti", - "code-action.nbt-type-to-byte": "Converti in un tag NBT di byte", - "code-action.nbt-type-to-double": "Converti in un tag NBT double", - "code-action.nbt-type-to-float": "Converti in un tag NBT float", - "code-action.nbt-type-to-int": "Converti in un tag NBT int", - "code-action.nbt-type-to-long": "Converti in un tag NBT long", - "code-action.nbt-type-to-short": "Converti in un tag NBT short", - "code-action.nbt-uuid-datafix": "Aggiorna questo UUID a 1.16", - "code-action.selector-sort-keys": "Ordina gli argomenti di selettore", - "code-action.string-double-quote": "Quota questa stringa con doppie virgolette", - "code-action.string-single-quote": "Quota questa stringa con singole virgolette", - "code-action.string-unquote": "De-quota questa stringa", - "code-action.vector-align-0.0": "Allinea questo vettore all'origine del blocco", - "code-action.vector-align-0.5": "Allinea questo vettore al centro del blocco", - "conjunction.and_2": " e ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", e ", - "conjunction.or_2": " o ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", o ", - "duplicate-key": "Chiave duplicate %0%", - "ending-quote": "quotazione finale %0%", - entity: "un'entit\xE0", - expected: "Previsto %0%", - "expected-got": "Aspettato %0% ma ricevuto %1%", - integer: "un numero intero", - "integer.between": "un numero intero da %0% a %1%", - "key-not-following-convention": "Chiave invalida %0% che non segue il convegno %1%", - long: "un long", - "mcfunction.parser.leading-slash.unexpected": "Barra '/' inaspettata", - "not-matching-any-child": "Fallito a combaciare con qualsiasi figli nell'albero del sintassi del commando", - nothing: "niente", - number: "un numero", - "number-range": "un intervallo di numeri", - "number-range.missing-min-and-max": "Aspettato un valore minimo o massimo", - "number.<=": "un numero meno o uguale a %0%", - "number.>=": "un numero maggiore o uguale a %0%", - "number.between": "un numero da %0% a %1%", - objective: "un oggettivo", - "punc.period": ".", - "punc.quote": "'%0%'", - quote: `una quotazione ('"o"')`, - "score-holder": "un contenitore di punteggio", - "server.new-version": "Il Server di Linguaggio Datapack \xE9 stato aggiornato a una nuova versione: %0%", - "server.remove-cache-file": "Il file del cache di DHP \xE8 stato spostato in un luogo in memoria da VSCose. Ora puoi tranquillamente cancellare il brutto file '.datapack' nel tuo spazio di lavoro.", - "server.show-release-notes": "Mostra appunti di pubblicazione", - string: "uno string", - tag: "un tag", - team: "una squadra", - "time-unit": "un unit\xE0 di tempo", - "too-many-block-affected": "Troppi blocchi nell'area (massimo: %0%, specificati: %1%)", - "unexpected-character": "Trovati caratteri che non sono da a-z, da 0-9 o [/._-]", - "unexpected-datapack-tag": "I tag non sono permessi qui", - "unexpected-default-namespace": "Namespace predefinito dovrebbe essere ommesso qui", - "unexpected-local-coordinate": "La coordinata locale %0% non \xE8 permessa", - "unexpected-nbt": "Questo tag non esiste qui", - "unexpected-nbt-array-type": "Tipo di array invalido %0%. Deve essere un tipo 'B', 'I' o 'L'", - "unexpected-nbt-path-filter": "Filtri composti sono esclusivamente usati per i tag composti", - "unexpected-nbt-path-index": "Gli indici sono solo usati per le liste, gli tag e gli array", - "unexpected-nbt-path-key": "Le chiavi sono solo usati per i tag composti", - "unexpected-nbt-path-sub": "Il tag corrente non ha elementi extra", - "unexpected-omitted-default-namespace": "Il namespace predefinito non pu\xF2 essere omesso qui", - "unexpected-relative-coordinate": "Coordinata %0% non \xE8 permessa", - "unexpected-scoreboard-sub-slot": "Solo il 'sidebar' ha sub-posti", - "unknown-command": "Commando sconosciuto", - "unknown-key": "Chiave sconisciuta", - "unquoted-string": "una stringa non quotata", - "unsorted-keys": "Chiavi non ordinati", - uuid: "un UUID", - vector: "Un vettore" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/ja.json -var ja_exports = {}; -__export(ja_exports, { - default: () => ja_default -}); -var ja_default; -var init_ja = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/ja.json"() { - ja_default = { - array: "\u914D\u5217\u578B", - boolean: "boolean\u578B", - "bug-of-mc": "Minecraft\uFF08%0%\uFF09\u306E\u30D0\u30B0\u306E\u305B\u3044\u3067\u3001%1%\u3002\u3069\u3046\u304BMojang\u3055\u3093\u3001\u30B2\u30FC\u30E0\u3092\u4FEE\u6B63\u3057\u3066\u304F\u3060\u3055\u3044", - "code-action.add-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u8FFD\u52A0", - "code-action.add-leading-slash": "\u5148\u982D\u306B\u30B9\u30E9\u30C3\u30B7\u30E5\u3092\u8FFD\u52A0", - "code-action.block-state-sort-keys": "block state\u3092\u30BD\u30FC\u30C8\u3059\u308B", - "code-action.command-replaceitem": "\u3053\u306E\u30B3\u30DE\u30F3\u30C9\u3092/item ... replace\u306B\u66F4\u65B0\u3057\u307E\u3059", - "code-action.create-undeclared-file": "\u540C\u3058\u30D1\u30C3\u30AF\u5185\u306B %0% \u306E %1% \u3092\u4F5C\u6210\u3059\u308B", - "code-action.fix-file": "\u3053\u306E\u30D5\u30A1\u30A4\u30EB\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", - "code-action.fix-workspace": "\u3053\u306E\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u5185\u306E\u3059\u3079\u3066\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", - "code-action.id-attribute-datafix": "\u3053\u306Eattribute\u306Ename\u30921.16\u306B\u66F4\u65B0\u3059\u308B", - "code-action.id-complete-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u88DC\u5B8C\u3059\u308B", - "code-action.id-create-file": "\u540C\u3058\u30C7\u30FC\u30BF\u30D1\u30C3\u30AF\u5185\u306B%0%\u3092\u4F5C\u6210", - "code-action.id-omit-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u3092\u7701\u7565\u3059\u308B", - "code-action.id-zombified-piglin-datafix": "\u3053\u306EID\u3092zombified_piglin\u306B\u5909\u66F4\u3057\u307E\u3059", - "code-action.nbt-compound-sort-keys": "NBT Compound\u30BF\u30B0\u3092\u30BD\u30FC\u30C8\u3059\u308B", - "code-action.nbt-type-to-byte": "byte\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-type-to-double": "double\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-type-to-float": "float\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-type-to-int": "int\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-type-to-long": "long\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-type-to-short": "short\u578B\u306ENBT\u30BF\u30B0\u306B\u5909\u63DB\u3059\u308B", - "code-action.nbt-uuid-datafix": "\u3053\u306EUUID\u30921.16\u306B\u66F4\u65B0\u3059\u308B", - "code-action.remove-leading-slash": "\u5148\u982D\u306E\u30B9\u30E9\u30C3\u30B7\u30E5\u3092\u524A\u9664", - "code-action.remove-trailing-separation": "\u672B\u5C3E\u306E\u533A\u5207\u308A\u3092\u524A\u9664\u3059\u308B", - "code-action.selector-sort-keys": "\u30BB\u30EC\u30AF\u30BF\u30FC\u306E\u5F15\u6570\u3092\u30BD\u30FC\u30C8\u3059\u308B", - "code-action.string-double-quote": "\u3053\u306E\u6587\u5B57\u5217\u3092\u4E8C\u91CD\u5F15\u7528\u7B26\u3067\u56F2\u3080", - "code-action.string-single-quote": "\u3053\u306E\u6587\u5B57\u5217\u3092\u4E00\u91CD\u5F15\u7528\u7B26\u3067\u56F2\u3080", - "code-action.string-unquote": "\u3053\u306E\u6587\u5B57\u5217\u306E\u5F15\u7528\u7B26\u3092\u5916\u3059", - "code-action.vector-align-0.0": "\u5EA7\u6A19\u306E\u5024\u3092\u30D6\u30ED\u30C3\u30AF\u306E\u539F\u70B9\u306B\u63C3\u3048\u308B", - "code-action.vector-align-0.5": "\u5EA7\u6A19\u306E\u5024\u3092\u30D6\u30ED\u30C3\u30AF\u306E\u4E2D\u5FC3\u306B\u63C3\u3048\u308B", - comment: "\u30B3\u30E1\u30F3\u30C8\u306F%0%\u3067\u59CB\u307E\u308A\u307E\u3059", - "conjunction.and_2": " \u3068 ", - "conjunction.and_3+_1": "\u3068 ", - "conjunction.and_3+_2": "\u3068 ", - "conjunction.or_2": " \u307E\u305F\u306F ", - "conjunction.or_3+_1": "\u304B ", - "conjunction.or_3+_2": "\u3082\u3057\u304F\u306F ", - "datafix.error.command-replaceitem": "/replaceitem\u306F20w46a (1.17\u306E2\u56DE\u76EE\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8)\u3067\u524A\u9664\u3055\u308C\u3001/item\u306B\u7F6E\u304D\u63DB\u308F\u308A\u307E\u3057\u305F", - "duplicate-key": "\u30AD\u30FC %0% \u306F\u91CD\u8907\u3057\u3066\u307E\u3059", - "ending-quote": "\u6587\u5B57\u5217\u3092\u9589\u3058\u308B\u5F15\u7528\u7B26 %0%", - entity: "\u30A8\u30F3\u30C6\u30A3\u30C6\u30A3", - "error.unparseable-content": "\u89E3\u91C8\u4E0D\u80FD\u306A\u5185\u5BB9\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F", - expected: "%0%\u304C\u5FC5\u8981\u3067\u3059", - "expected-got": "%0%\u304C\u5FC5\u8981\u3067\u3059\u304C%1%\u304C\u78BA\u8A8D\u3055\u308C\u307E\u3057\u305F", - float: "float\u578B", - "float.between": "float\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u3067\u3059", - integer: "int\u578B", - "integer.between": "int\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u306E\u5024\u3067\u3059", - "invalid-key-combination": "%0% \u3068\u3044\u3046\u30AD\u30FC\u306E\u7D44\u307F\u5408\u308F\u305B\u306F\u7121\u52B9\u3067\u3059", - "invalid-regex-pattern": "\u7121\u52B9\u306A\u6B63\u898F\u8868\u73FE\u3067\u3059: %0%", - "java-edition.binder.wrong-folder": "%0% \u30D5\u30A9\u30EB\u30C0\u5185\u306E\u30D5\u30A1\u30A4\u30EB\u306F\u3001\u8AAD\u307F\u8FBC\u307E\u308C\u305F\u30D0\u30FC\u30B8\u30E7\u30F3 %1% \u3067\u306F\u8A8D\u8B58\u3055\u308C\u307E\u305B\u3093\u3002%2% \u30D5\u30A9\u30EB\u30C0\u3092\u4F7F\u7528\u3059\u308B\u3064\u3082\u308A\u3067\u3057\u305F\u304B\uFF1F", - "java-edition.binder.wrong-version": "%0% \u30D5\u30A9\u30EB\u30C0\u5185\u306E\u30D5\u30A1\u30A4\u30EB\u306F\u3001\u8AAD\u307F\u8FBC\u307E\u308C\u305F\u30D0\u30FC\u30B8\u30E7\u30F3 %1% \u3067\u306F\u8A8D\u8B58\u3055\u308C\u307E\u305B\u3093", - "java-edition.translation-value.percent-escape-hint": '%0%\u3002\u30D1\u30FC\u30BB\u30F3\u30C8\u8A18\u53F7\u3092\u8868\u793A\u3057\u305F\u3044\u5834\u5408\u306F\u3001"%%"\u3092\u4F7F\u7528\u3059\u308B', - "json.checker.array.length-between": "%0%\u306E\u8981\u7D20\u6570\u306F%1%\u304B\u3089%2%\u306E\u9593\u307E\u3067\u3067\u3059", - "json.checker.item.duplicate": "\u91CD\u8907\u3057\u305F\u30EA\u30B9\u30C8\u9805\u76EE", - "json.checker.object.field.union-empty-members": "\u8A31\u53EF\u3055\u308C\u3066\u3044\u306A\u3044\u30D7\u30ED\u30D1\u30C6\u30A3\u3067\u3059", - "json.checker.property.deprecated": "\u30D7\u30ED\u30D1\u30C6\u30A3 %0% \u306F\u975E\u63A8\u5968\u3067\u3059", - "json.checker.property.missing": "\u30D7\u30ED\u30D1\u30C6\u30A3 %0% \u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093", - "json.checker.property.unknown": "\u4E0D\u660E\u306A\u30D7\u30ED\u30D1\u30C6\u30A3 %0%", - "json.checker.string.hex-color": "6\u6841\u306E16\u9032\u6570", - "json.checker.tag-entry.duplicate": "\u91CD\u8907\u3057\u305F\u30BF\u30B0\u9805\u76EE", - "json.checker.value": "\u5024", - "json.doc.advancement.display": "\u9032\u6357\u306E\u8868\u793A\u8A2D\u5B9A\u3002\u8A2D\u5B9A\u3057\u305F\u5834\u5408\u3001\u9032\u6357\u30BF\u30D6\u306B\u9032\u6357\u304C\u8868\u793A\u3055\u308C\u308B\u3088\u3046\u306B\u306A\u308B\u3002", - "json.node.array": "\u914D\u5217\u578B", - "json.node.boolean": "boolean\u578B", - "json.node.null": "null\u578B", - "json.node.number": "number\u578B", - "json.node.object": "object\u578B", - "json.node.string": "string\u578B", - "key-not-following-convention": "\u30AD\u30FC%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "linter-config-validator.name-convention.type": "\u540D\u524D\u3092\u8868\u3057\u3001\u6B63\u898F\u8868\u73FE\u3092\u542B\u3080\u6587\u5B57\u5217\u304C\u5FC5\u8981\u3067\u3059", - "linter-config-validator.wrapper": "%0%\u3002\u8A73\u7D30\u306F\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\uFF08%1\uFF09\u3092\u53C2\u7167\u3057\u3066\u304F\u3060\u3055\u3044", - "linter.diagnostic-message-wrapper": "%0%\uFF08\u30EB\u30FC\u30EB: %1%\uFF09", - "linter.name-convention.illegal": "\u540D\u524D %0% \u306F %1% \u3068\u4E00\u81F4\u3057\u307E\u305B\u3093", - "linter.undeclared-symbol.message": "%0% %1% \u304C\u898B\u3064\u304B\u308A\u307E\u305B\u3093", - long: "long\u578B", - "long.between": "long\u578B\u306F%0% ~ %1%\u306E\u7BC4\u56F2\u3067\u3059", - "mcdoc.binder.dispatcher-statement.duplicated-key": "%0% \u306E\u30C7\u30A3\u30B9\u30D1\u30C3\u30C1\u30E3\u30FC\u30B1\u30FC\u30B9\u304C\u91CD\u8907\u3057\u3066\u3044\u307E\u3059", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% \u306F\u3001\u3059\u3067\u306B\u30C7\u30A3\u30B9\u30D1\u30C3\u30C1\u3055\u308C\u3066\u3044\u307E\u3059", - "mcdoc.binder.duplicated-declaration": "%0% \u306E\u5BA3\u8A00\u304C\u91CD\u8907\u3057\u3066\u3044\u307E\u3059", - "mcdoc.binder.duplicated-declaration.related": "%0% \u306F\u3059\u3067\u306B\u5BA3\u8A00\u3055\u308C\u3066\u3044\u307E\u3059", - "mcdoc.binder.out-of-root": "\u30D5\u30A1\u30A4\u30EB%0%\u306F\u3069\u306Emcdoc\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u30EB\u30FC\u30C8\u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u306B\u3082\u3042\u308A\u307E\u305B\u3093\u3002\u30BB\u30DE\u30F3\u30C6\u30A3\u30C3\u30AF\u30C1\u30A7\u30C3\u30AF\u306F\u30B9\u30AD\u30C3\u30D7\u3055\u308C\u307E\u3059", - "mcdoc.binder.path.super-from-root": "\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u30EB\u30FC\u30C8\u306E super \u306B\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u305B\u3093", - "mcdoc.binder.path.unknown-identifier": "\u8B58\u5225\u5B50 %0% \u306F\u30E2\u30B8\u30E5\u30FC\u30EB %1% \u306B\u5B58\u5728\u3057\u307E\u305B\u3093", - "mcdoc.binder.path.unknown-module": "\u30E2\u30B8\u30E5\u30FC\u30EB %0% \u306F\u5B58\u5728\u3057\u307E\u305B\u3093", - "mcdoc.checker.entry.empty-mod-seg": '"mod.mcdoc" \u30D5\u30A1\u30A4\u30EB\u3092\u30EB\u30FC\u30C8\u76F4\u4E0B\u306B\u7F6E\u304F\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093', - "mcdoc.checker.inject-clause.unmatched-injection": "%0% \u306B %1% \u3092\u5165\u308C\u308B\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093", - "mcdoc.checker.type-not-assignable": "\u578B %0% \u306F\u578B %1% \u306B\u5272\u308A\u5F53\u3066\u3067\u304D\u307E\u305B\u3093", - "mcdoc.node.compound-definition": "\u8907\u5408\u7684\u306A\u5B9A\u7FA9", - "mcdoc.node.enum-definition": "\u5217\u6319\u578B\u306E\u5B9A\u7FA9", - "mcdoc.node.identifier": "\u8B58\u5225\u5B50", - "mcdoc.parser.compound-definition.field-type": "\u30D5\u30A3\u30FC\u30EB\u30C9\u30BF\u30A4\u30D7", - "mcdoc.parser.float.illegal": "\u4E0D\u6B63\u306A\u6D6E\u52D5\u5C0F\u6570\u70B9\u6570\u304C\u691C\u51FA\u3055\u308C\u307E\u3057\u305F", - "mcdoc.parser.identifier.illegal": "%0% \u306F %1% \u306E\u5F62\u5F0F\u306B\u5F93\u3063\u3066\u3044\u307E\u305B\u3093", - "mcdoc.parser.identifier.reserved-word": "%0% \u306F\u4E88\u7D04\u8A9E\u3067\u3042\u308A\u3001\u8B58\u5225\u5B50\u540D\u3068\u3057\u3066\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u52D5\u7684\u30A4\u30F3\u30C7\u30C3\u30AF\u30B9\u306E\u6307\u5B9A\u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093", - "mcdoc.parser.inject-clause.definition-expected": "\u5217\u6319\u578B\u304B\u8907\u5408\u578B\u304C\u5FC5\u8981\u3067\u3059", - "mcdoc.parser.keyword.separation": "\u533A\u5207\u308A", - "mcdoc.parser.resource-location.colon-expected": "\u30EA\u30BD\u30FC\u30B9\u306E\u5834\u6240\u306B\u30B3\u30ED\u30F3\uFF08%0%\uFF09\u304C\u5FC5\u8981\u3067\u3059", - "mcdoc.parser.syntax.doc-comment-unexpected": "\u3053\u3053\u3067\u306F\u30C9\u30AD\u30E5\u30E1\u30F3\u30C8\u30B3\u30E1\u30F3\u30C8\u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093\u3002\u4E09\u91CD\u30B9\u30E9\u30C3\u30B7\u30E5\uFF08///\uFF09\u3092\u4E8C\u91CD\u30B9\u30E9\u30C3\u30B7\u30E5\uFF08//\uFF09\u306B\u7F6E\u304D\u63DB\u3048\u308B\u3068\u3088\u3044\u3067\u3057\u3087\u3046", - "mcdoc.runtime.checker.key-value-pair": "\u30AD\u30FC\u3068\u5024\u306E\u30DA\u30A2", - "mcdoc.runtime.checker.range.collection": "\u30B3\u30EC\u30AF\u30B7\u30E7\u30F3\u306E\u9577\u3055\u304C %0% \u3067\u3042\u308B\u3053\u3068", - "mcdoc.runtime.checker.range.concat": "%0% \u3068 %1%", - "mcdoc.runtime.checker.range.left-exclusive": "%0% \u3088\u308A\u4E0A", - "mcdoc.runtime.checker.range.left-inclusive": "\u5C11\u306A\u304F\u3068\u3082 %0%", - "mcdoc.runtime.checker.range.number": "\u6570\u5024\u304C %0% \u3067\u3042\u308B\u3053\u3068", - "mcdoc.runtime.checker.range.right-exclusive": "%0% \u672A\u6E80", - "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u5927 %0%", - "mcdoc.runtime.checker.range.string": "\u6587\u5B57\u5217\u306E\u9577\u3055\u304C %0% \u3067\u3042\u308B\u3053\u3068", - "mcdoc.runtime.checker.some-missing-keys": "\u30AD\u30FC %0% \u306E\u3046\u3061\u5C11\u306A\u304F\u3068\u30821\u3064\u304C\u4E0D\u8DB3\u3057\u3066\u3044\u307E\u3059", - "mcdoc.runtime.checker.trailing": "\u672B\u5C3E\u306B\u4F59\u5206\u306A\u30C7\u30FC\u30BF\u304C\u898B\u3064\u304B\u308A\u307E\u3057\u305F", - "mcdoc.runtime.checker.value": "\u5024", - "mcdoc.type.boolean": "boolean\u578B", - "mcdoc.type.byte": "byte\u578B", - "mcdoc.type.byte_array": "byte\u914D\u5217\u578B", - "mcdoc.type.double": "double\u578B", - "mcdoc.type.float": "float\u578B", - "mcdoc.type.int": "int\u578B", - "mcdoc.type.int_array": "int\u914D\u5217\u578B", - "mcdoc.type.list": "list\u578B", - "mcdoc.type.long": "long\u578B", - "mcdoc.type.long_array": "long\u914D\u5217\u578B", - "mcdoc.type.short": "short\u578B", - "mcdoc.type.string": "string\u578B", - "mcdoc.type.struct": "\u69CB\u9020\u578B", - "mcfunction.parser.entity-selector.arguments.unknown": "%0% \u306F\u4E0D\u660E\u306A\u30BB\u30EC\u30AF\u30BF\u30FC\u5F15\u6570\u3067\u3059", - "mcfunction.parser.entity-selector.entities-disallowed": "\u3053\u306E\u30BB\u30EC\u30AF\u30BF\u30FC\u306F\u30D7\u30EC\u30A4\u30E4\u30FC\u3067\u306A\u3044\u30A8\u30F3\u30C6\u30A3\u30C6\u30A3\u3092\u542B\u307F\u307E\u3059", - "mcfunction.parser.leading-slash.unexpected": "\u201C/\u201D\u306F\u4E0D\u660E\u306A\u5148\u982D\u306E\u6587\u5B57\u3067\u3059", - "mismatching-regex-pattern": "\u5024\u304C\u6B63\u898F\u8868\u73FE\u3068\u4E00\u81F4\u3057\u307E\u305B\u3093: %0%", - "not-matching-any-child": "\u7121\u52B9\u306A\u5F15\u6570\u306E\u578B\u3067\u3059", - nothing: "\u672A\u8A18\u5165\u306E\u72B6\u6CC1", - number: "\u6570\u5024", - "number-range": "\u6570\u5024\u306E\u7BC4\u56F2", - "number-range.missing-min-and-max": "\u5C11\u306A\u304F\u3068\u3082\u6700\u5C0F\u5024\u307E\u305F\u306F\u6700\u5927\u5024\u306E\u3069\u3061\u3089\u304B\u3092\u8A18\u5165\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "number.<=": "%0%\u4EE5\u4E0B\u306E\u6570\u5024", - "number.>=": "%0%\u4EE5\u4E0A\u306E\u6570\u5024", - "number.between": "%0% ~ %1%\u306E\u7BC4\u56F2\u306E\u6570\u5024", - objective: "\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8\u540D", - "objective-not-following-convention": "\u30AA\u30D6\u30B8\u30A7\u30AF\u30C8%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "punc.period": "\u3002", - "punc.quote": "\u300C%0%\u300D", - quote: `\u5F15\u7528\u7B26 (\u2018'\u2019 \u304B \u2018"\u2019)`, - quote_prefer_double: '\u3053\u3053\u306F\u4E8C\u91CD\u5F15\u7528\u7B26(\u201C"\u201D)\u304C\u6700\u9069\u3067\u3059', - quote_prefer_single: "\u3053\u3053\u306F\u4E00\u91CD\u5F15\u7528\u7B26(\u201C'\u201D)\u304C\u6700\u9069\u3067\u3059", - "score-holder": "\u30B9\u30B3\u30A2\u4FDD\u6301\u8005", - "scoreholder-not-following-convention": "\u30B9\u30B3\u30A2\u4FDD\u6301\u8005%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "server.new-version": "Data-pack Language Server\u304C%0%\u306B\u66F4\u65B0\u3055\u308C\u307E\u3057\u305F", - "server.progress.fixing-workspace.begin": "\u3053\u306E\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u5185\u306E\u3059\u3079\u3066\u306E\u4FEE\u6B63\u53EF\u80FD\u306A\u554F\u984C\u3092\u4E00\u62EC\u4FEE\u6B63\u3059\u308B", - "server.progress.fixing-workspace.report": "\u6B21\u306E\u30D5\u30A1\u30A4\u30EB\u3092\u4FEE\u6B63\u4E2D: %0%", - "server.remove-cache-file": "DHP\u306E\u30AD\u30E3\u30C3\u30B7\u30E5\u30D5\u30A1\u30A4\u30EB\u306FVSCode\u306E\u63D0\u4F9B\u3059\u308B\u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u79FB\u52D5\u3055\u308C\u307E\u3057\u305F\u3002\u30EF\u30FC\u30AF\u30B9\u30DA\u30FC\u30B9\u30EB\u30FC\u30C8\u306E\u201C.datapack\u201D\u30D5\u30A9\u30EB\u30C0\u306F\u5B89\u5168\u306B\u6D88\u53BB\u3059\u308B\u3053\u3068\u304C\u53EF\u80FD\u3067\u3059\u3002", - "server.show-release-notes": "\u30EA\u30EA\u30FC\u30B9\u30CE\u30FC\u30C8\u3092\u898B\u308B", - string: "\u6587\u5B57\u5217", - tag: "tag", - "tag-not-following-convention": "tag%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - team: "\u30C1\u30FC\u30E0", - "team-not-following-convention": "\u30C1\u30FC\u30E0%0%\u306F\u547D\u540D\u898F\u5247\u306B\u5F93\u3044%1%\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "time-unit": "\u6642\u9593\u306E\u5358\u4F4D", - "too-many-block-affected": "\u6307\u5B9A\u3057\u305F\u9818\u57DF\u306B\u3042\u308B\u30D6\u30ED\u30C3\u30AF\u304C\u591A\u3059\u304E\u307E\u3059\uFF08\u6700\u5927 %0%\u3001\u6307\u5B9A %1%\uFF09", - "too-many-chunk-affected": "\u6307\u5B9A\u3057\u305F\u9818\u57DF\u306B\u3042\u308B\u30C1\u30E3\u30F3\u30AF\u304C\u591A\u3059\u304E\u307E\u3059\uFF08\u6700\u5927 %0%\u3001\u6307\u5B9A %1%\uFF09", - "unexpected-character": "[a-z0-9/._-] \u4EE5\u5916\u306E\u6587\u5B57\u304C\u5B58\u5728\u3057\u307E\u3059", - "unexpected-datapack-tag": "\u3053\u3053\u306B\u30BF\u30B0\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", - "unexpected-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u306E\u540D\u524D\u7A7A\u9593\u306F\u7701\u7565\u3057\u3066\u304F\u3060\u3055\u3044", - "unexpected-local-coordinate": "\u30ED\u30FC\u30AB\u30EB\u5EA7\u6A19 %0% \u306F\u8A31\u53EF\u3055\u308C\u3066\u3044\u307E\u305B\u3093", - "unexpected-nbt": "\u3053\u306E\u30BF\u30B0\u306F\u5B58\u5728\u3057\u307E\u305B\u3093", - "unexpected-nbt-array-type": "%0%\u306F\u7121\u52B9\u306A\u914D\u5217\u306E\u578B\u3067\u3059\u3002 \u201CB\u201D, \u201CI\u201D, \u201CL\u201D\u306E\u3069\u308C\u304B\u3067\u3042\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059", - "unexpected-nbt-path-filter": "Compound\u30D5\u30A3\u30EB\u30BF\u30FC\u306FCompound\u30BF\u30B0\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", - "unexpected-nbt-path-index": "\u30A4\u30F3\u30C7\u30C3\u30AF\u30B9\u306Flist\u30BF\u30B0/\u914D\u5217\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", - "unexpected-nbt-path-key": "\u30AD\u30FC\u306FCompound\u30BF\u30B0\u306B\u306E\u307F\u9069\u7528\u3055\u308C\u307E\u3059", - "unexpected-nbt-path-sub": "\u3053\u306E\u30BF\u30B0\u306B\u30B5\u30D6\u30A2\u30A4\u30C6\u30E0\u306F\u5B58\u5728\u3057\u307E\u305B\u3093", - "unexpected-omitted-default-namespace": "\u30C7\u30D5\u30A9\u30EB\u30C8\u540D\u524D\u7A7A\u9593\u306F\u3053\u3053\u3067\u306F\u7701\u7565\u3067\u304D\u307E\u305B\u3093", - "unexpected-relative-coordinate": "\u76F8\u5BFE\u5EA7\u6A19 %0% \u306F\u3053\u3053\u3067\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093", - "unexpected-scoreboard-sub-slot": "\u30B5\u30D6\u30B9\u30ED\u30C3\u30C8\u306F\u201Csidebar\u201D\u3067\u306E\u307F\u4F7F\u7528\u3067\u304D\u307E\u3059", - "unknown-command": "%0%\u306F\u4E0D\u660E\u306A\u30B3\u30DE\u30F3\u30C9\u3067\u3059", - "unknown-key": "%0%\u306F\u4E0D\u660E\u306A\u30AD\u30FC\u3067\u3059", - "unquoted-string": "\u5F15\u7528\u7B26\u3067\u56F2\u307E\u308C\u3066\u3044\u306A\u3044\u6587\u5B57\u5217", - "unsorted-keys": "\u30BD\u30FC\u30C8\u3055\u308C\u3066\u3044\u306A\u3044\u30AD\u30FC", - uuid: "UUID", - vector: "\u5EA7\u6A19\u306E\u5024" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/pt-br.json -var pt_br_exports = {}; -__export(pt_br_exports, { - default: () => pt_br_default -}); -var pt_br_default; -var init_pt_br = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/pt-br.json"() { - pt_br_default = { - array: "uma matriz", - boolean: "um boolean", - "bug-of-mc": "Devido a um bug do Minecraft (%0%), %1%. Por favor, Mojang, conserte o seu jogo", - "code-action.block-state-sort-keys": "Classificar estado do bloco", - "code-action.command-replaceitem": "Comando atualizado para /item \u2026 replace", - "code-action.fix-file": "Corrija todos os problemas auto corrig\xEDveis neste arquivo", - "code-action.fix-workspace": "Corrija todos os problemas auto corrig\xEDveis nesta \xE1rea de trabalho", - "code-action.id-attribute-datafix": "Nome de atributo atualizado para a 1.16", - "code-action.id-complete-default-namespace": "Espa\xE7o do nome completo por padr\xE3o", - "code-action.id-create-file": "Criar %0% no mesmo data pack", - "code-action.id-omit-default-namespace": "Omita o espa\xE7o de nome por padr\xE3o", - "code-action.id-zombified-piglin-datafix": "Altere este ID para Piglin Zumbificado", - "code-action.nbt-compound-sort-keys": "Classificar NBT da tag composta", - "code-action.nbt-type-to-byte": "Converter para uma tag de NBT byte", - "code-action.nbt-type-to-double": "Converter para uma tag de NBT double", - "code-action.nbt-type-to-float": "Converter para uma tag de NBT float", - "code-action.nbt-type-to-int": "Converter para uma tag de NBT int", - "code-action.nbt-type-to-long": "Converter para uma tag de NBT long", - "code-action.nbt-type-to-short": "Converter para uma tag de NBT short", - "code-action.nbt-uuid-datafix": "Atualizar este UUID para 1.16", - "code-action.selector-sort-keys": "Classificar argumento do seletor", - "code-action.string-double-quote": "Cite esta string com aspas duplas", - "code-action.string-single-quote": "Cite esta string com aspas simples", - "code-action.string-unquote": "Retire as aspas desta string", - "code-action.vector-align-0.0": "Alinhar este vetor para bloquear a origem", - "code-action.vector-align-0.5": "Alinhar este vetor para bloquear o centro", - comment: "um coment\xE1rio come\xE7ando com %0%", - "conjunction.and_2": " e ", - "conjunction.and_3+_1": ", ", - "conjunction.and_3+_2": ", e ", - "conjunction.or_2": " ou ", - "conjunction.or_3+_1": ", ", - "conjunction.or_3+_2": ", ou ", - "datafix.error.command-replaceitem": "/replaceitem foi removida na 20w46a (a segunda snapshot da 1.17) a favor de /item", - "duplicate-key": "Duplicar chave %0%", - "ending-quote": "uma cita\xE7\xE3o final %0%", - entity: "uma entidade", - "error.unparseable-content": "Conte\xFAdo n\xE3o analis\xE1vel encontrado", - expected: "Esperado %0%", - "expected-got": "Esperado %0% mas obteve %1%", - float: "um float", - "float.between": "um float entre %0% e %1%", - integer: "um inteiro", - "integer.between": "um inteiro entre %0% e %1%", - "json.checker.item.duplicate": "Duplicar lista de itens", - "json.checker.property.deprecated": "A propriedade %0% est\xE1 descontinuada", - "json.checker.property.missing": "Falta da propriedade %0%", - "json.checker.property.unknown": "Propriedade desconhecida %0%", - "json.checker.string.hex-color": "um n\xFAmero hexadecimal de 6-d\xEDgitos", - "json.checker.tag-entry.duplicate": "Duplicar tag de entrada", - "json.doc.advancement.display": "Configura\xE7\xF5es de exibi\xE7\xE3o de progressos. Se estiver presente, o progressos ser\xE1 vis\xEDvel nas guias de progressos.", - "key-not-following-convention": "Chave inv\xE1lida %0% que n\xE3o segue a conven\xE7\xE3o %1%", - "linter-config-validator.name-convention.type": "Espera uma string que cont\xE9m uma express\xE3o regular descrevendo o nome", - "linter-config-validator.wrapper": "%0%. Veja [a documenta\xE7\xE3o](%1) para mais informa\xE7\xF5es", - "linter.diagnostic-message-wrapper": "%0% (regras: %1%)", - "linter.name-convention.illegal": "Nome %0% n\xE3o corresponde %1%", - "linter.undeclared-symbol.message": "N\xE3o consigo encontrar %0% %1%", - long: "uma long", - "mcdoc.binder.dispatcher-statement.duplicated-key": "Caso de despachante duplicado %0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% j\xE1 foi despachado aqui", - "mcdoc.binder.duplicated-declaration": "Declara\xE7\xE3o duplicada para %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% j\xE1 est\xE1 declarado aqui", - "mcdoc.binder.out-of-root": "O arquivo %0% n\xE3o est\xE1 no diret\xF3rio raiz de nenhum projeto mcdoc; a verifica\xE7\xE3o sem\xE2ntica ser\xE1 ignorada", - "mcdoc.binder.path.super-from-root": "N\xE3o \xE9 poss\xEDvel acessar super da raiz do projeto", - "mcdoc.binder.path.unknown-identifier": "O identificador %0% n\xE3o existe no m\xF3dulo %1%", - "mcdoc.binder.path.unknown-module": "M\xF3dulo %0% n\xE3o existe", - "mcdoc.checker.entry.empty-mod-seg": "Voc\xEA n\xE3o pode colocar \u201Cmod.mcdoc\u201D em uma raiz diretamente", - "mcdoc.checker.inject-clause.unmatched-injection": "N\xE3o \xE9 poss\xEDvel injetar %0% com %1%", - "mcdoc.checker.type-not-assignable": "O tipo %0% n\xE3o pode ser atribu\xEDdo ao tipo %1%", - "mcdoc.node.compound-definition": "uma defini\xE7\xE3o composta", - "mcdoc.node.enum-definition": "uma defini\xE7\xE3o de enumera\xE7\xE3o", - "mcdoc.node.identifier": "um identificador", - "mcdoc.parser.compound-definition.field-type": "um tipo de campo", - "mcdoc.parser.float.illegal": "N\xFAmero float ilegal encontrado", - "mcdoc.parser.identifier.illegal": "%0% n\xE3o segue o formato de %1%", - "mcdoc.parser.identifier.reserved-word": "%0% \xE9 uma palavra reservada e n\xE3o pode ser usada como um nome identificador", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "A indexa\xE7\xE3o din\xE2mica n\xE3o \xE9 permitida", - "mcdoc.parser.inject-clause.definition-expected": "Esperado um enum inje\xE7\xE3o ou um compound inje\xE7\xE3o", - "mcdoc.parser.keyword.separation": "uma separa\xE7\xE3o", - "mcdoc.parser.resource-location.colon-expected": "Esperado os dois pontos (%0%) dos locais de recursos", - "mcdoc.parser.syntax.doc-comment-unexpected": "Coment\xE1rios de documentos n\xE3o s\xE3o permitidos aqui; voc\xEA pode querer substituir as tr\xEAs barras por duas barras", - "mcfunction.checker.command.data-modify-unapplicable-operation": "A opera\xE7\xE3o %0% s\xF3 pode ser usada em %1%; o caminho de destino tem o tipo %2% em vez disso", - "mcfunction.completer.block.states.default-value": "Padr\xE3o: %0%", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% n\xE3o \xE9 aplic\xE1vel aqui", - "mcfunction.parser.entity-selector.arguments.unknown": "Argumento do seletor de entidade desconhecido %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "O seletor cont\xE9m entidades n\xE3o-player", - "mcfunction.parser.entity-selector.multiple-disallowed": "O seletor cont\xE9m v\xE1rias entidades", - "mcfunction.parser.entity-selector.player-name.too-long": "Os nomes dos jogadores n\xE3o podem ter mais de %0% caracteres", - "mcfunction.parser.eoc-unexpected": "Esperava-se mais argumentos", - "mcfunction.parser.leading-slash": "uma barra inicial \u201C/\u201D", - "mcfunction.parser.leading-slash.unexpected": "Barra inicial inesperada \u201C/\u201D", - "mcfunction.parser.no-permission": "N\xEDvel de permiss\xE3o %0% \xE9 necess\xE1rio, que \xE9 superior a %1% definido na configura\xE7\xE3o", - "mcfunction.parser.objective.too-long": "Os nomes dos objetivos n\xE3o podem ter mais de %0% caracteres", - "mcfunction.parser.range.min>max": "O valor m\xEDnimo %0% \xE9 maior que o valor m\xE1ximo %1%", - "mcfunction.parser.score_holder.fake-name.too-long": "Nomes falsos n\xE3o podem ter mais de %0% caracteres", - "mcfunction.parser.sep": "um espa\xE7o (%0%)", - "mcfunction.parser.trailing": "Dados finais encontrados", - "mcfunction.parser.unknown-parser": "O analisador %0% ainda n\xE3o foi suportado", - "mcfunction.parser.uuid.invalid": "Formato UUID inv\xE1lido", - "mcfunction.parser.vector.local-disallowed": "Coordenadas locais n\xE3o permitidas", - "mcfunction.parser.vector.mixed": "N\xE3o \xE9 poss\xEDvel misturar coordenadas locais e coordenadas mundiais juntas", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki: analisador de argumentos `%0%`](https://minecraft.fandom.com/wiki/Argument_types#%0%)", - "mcfunction.signature-help.command-documentation": "[Minecraft Wiki: comando `%0%`](https://minecraft.fandom.com/wiki/Commands/%0%)", - "missing-key": "Falta a chave %0%", - "nbt.checker.block-states.fake-boolean": "Os valores do estado do bloco boolean devem ser citados", - "nbt.checker.block-states.unexpected-value-type": "Os valores do estado do bloco devem ser uma string ou um int", - "nbt.checker.block-states.unknown-state": "Estado de bloco desconhecido %0% para o(s) seguinte(s) bloco(s): %1%", - "nbt.checker.boolean.out-of-range": "Um valor boolean deve ser %0% ou %1%", - "nbt.checker.collection.length-between": "%0% com comprimento entre %1% e %2%", - "nbt.checker.compound.field.union-empty-members": "Propriedade proibida", - "nbt.checker.path.index-out-of-bound": "O \xEDndice fornecido %0% est\xE1 fora do limite, pois a cole\xE7\xE3o s\xF3 pode ter no m\xE1ximo %1% elementos", - "nbt.checker.path.unexpected-filter": "Filtros compostos s\xF3 podem ser usados em tags compostas", - "nbt.checker.path.unexpected-index": "Os \xEDndices s\xF3 podem ser usados em array ou lista de tags", - "nbt.checker.path.unexpected-key": "As chaves de string s\xF3 podem ser especificadas para tags compostas", - "nbt.node": "uma tag", - "nbt.node.byte": "uma byte tag", - "nbt.node.byte_array": "uma byte array tag", - "nbt.node.compound": "uma tag composta", - "nbt.node.double": "uma double tag", - "nbt.node.float": "uma float tag", - "nbt.node.int": "uma int tag", - "nbt.node.int_array": "uma int array tag", - "nbt.node.list": "uma lista de tag", - "nbt.node.long": "uma long tag", - "nbt.node.long_array": "uma long array tag", - "nbt.node.path.end": "fim do path", - "nbt.node.path.filter": "um filtro composto", - "nbt.node.path.index": "um \xEDndice", - "nbt.node.path.key": "uma chave", - "nbt.node.short": "uma short tag", - "nbt.node.string": "uma string tag", - "nbt.parser.number.out-of-range": "Parece que %0%, mas na verdade \xE9 %1% devido ao valor numeral estar fora de [%2%, %3%]", - "not-matching-any-child": "Tipo de argumento inv\xE1lido", - nothing: "nada", - number: "um n\xFAmero", - "number-range": "uma gama de n\xFAmeros", - "number-range.missing-min-and-max": "Esperado um valor m\xEDnimo ou um valor m\xE1ximo", - "number.<=": "um n\xFAmero menor ou igual a %0%", - "number.>=": "um n\xFAmero maior ou igual a %0%", - "number.between": "um n\xFAmero entre %0% e %1%", - object: "um objeto", - objective: "um objetivo", - "objective-not-following-convention": "Objetivo inv\xE1lido %0% que n\xE3o segue a conven\xE7\xE3o %1%", - "parser.float.illegal": "Numeral float ilegal que n\xE3o segue %0%", - "parser.integer.illegal": "Inteiro ilegal que n\xE3o segue %0%", - "parser.list.trailing-sep": "Separa\xE7\xE3o final", - "parser.list.value": "um valor", - "parser.record.key": "uma chave", - "parser.record.trailing-end": "Separa\xE7\xE3o final", - "parser.record.unexpected-char": "Caractere inesperado %0%", - "parser.record.value": "um valor", - "parser.resource-location.illegal": "Car\xE1ter(s) ilegal(is): %0%", - "parser.resource-location.namespace-expected": "Espa\xE7oDeNome n\xE3o podem ser omitidos aqui", - "parser.resource-location.tag-disallowed": "Tags n\xE3o s\xE3o permitidas aqui", - "parser.string.illegal-brigadier": "Encontrou n\xE3o-[0-9A-Za-z_.+-] caracteres em %0%", - "parser.string.illegal-escape": "Car\xE1ter de escape inesperado %0%", - "parser.string.illegal-quote": "Apenas %0% pode ser usado para citar strings aqui", - "parser.string.illegal-unicode-escape": "Espera-se um d\xEDgito hexadecimal", - "punc.period": ".", - "punc.quote": "\u201C%0%\u201D", - quote: `uma cita\xE7\xE3o (\u201C'\u201D ou \u201C"\u201D)`, - quote_prefer_double: 'Aspas duplas (\u201C"\u201D) s\xE3o prefer\xEDveis aqui', - quote_prefer_single: "Aspas simples (\u201C'\u201D) s\xE3o prefer\xEDveis aqui", - "resource-location": "um local de recurso", - "score-holder": "um marcador de pontos", - "scoreholder-not-following-convention": "Score_holder %0% inv\xE1lido que n\xE3o segue a conven\xE7\xE3o %1%", - "server.new-version": "O idioma do servidor do Data-pack foi atualizado para uma vers\xE3o mais recente: %0%", - "server.progress.fixing-workspace.begin": "Corrigindo todos os problemas auto corrig\xEDveis na mesa de trabalho", - "server.progress.fixing-workspace.report": "corrigindo %0%", - "server.progress.preparing.title": "Preparando recursos de linguagem do Spyglass", - "server.remove-cache-file": "O arquivo de cache do DHP foi movido para um local de armazenamento fornecido pelo VSCode. Voc\xEA pode excluir com seguran\xE7a a pasta \u201C.datapack\u201D desagrad\xE1vel na raiz do seu espa\xE7o de trabalho.", - "server.show-release-notes": "Mostrar Notas de Lan\xE7amento", - string: "uma string", - tag: "uma tag", - "tag-not-following-convention": "Tag inv\xE1lida %0% que n\xE3o segue a conven\xE7\xE3o %1%", - team: "um equipe", - "team-not-following-convention": "Equipe invalida %0% que n\xE3o segue a conven\xE7\xE3o %1%", - "time-unit": "uma unidade de tempo", - "too-many-block-affected": "Muitos blocos na \xE1rea especificada (m\xE1ximo %0%, especificado %1%)", - "too-many-chunk-affected": "Muitos peda\xE7os na \xE1rea especificada (m\xE1ximo %0%, especificado %1%)", - "unexpected-character": "N\xE3o foram encontrados caracteres [a-z0-9/._-]", - "unexpected-datapack-tag": "Tags n\xE3o s\xE3o permitidas aqui", - "unexpected-default-namespace": "O espa\xE7o-de-nome padr\xE3o deve ser omitido aqui", - "unexpected-local-coordinate": "Coordenada local %0% n\xE3o \xE9 permitida", - "unexpected-nbt": "Esta tag n\xE3o existe aqui", - "unexpected-nbt-array-type": "Tipo de array inv\xE1lida %0%. Deve ser um de \u201CB\u201D, \u201CI\u201D e \u201CL\u201D", - "unexpected-nbt-path-filter": "Filtros compostos s\xE3o usados apenas para tags compostas", - "unexpected-nbt-path-index": "Os \xEDndices s\xE3o usados apenas para listas de tags/arrays tags", - "unexpected-nbt-path-key": "As chaves s\xE3o usadas apenas para tags compostas", - "unexpected-nbt-path-sub": "A tag atual n\xE3o tem itens extras", - "unexpected-omitted-default-namespace": "O espa\xE7o-de-nome padr\xE3o n\xE3o deve ser omitido aqui", - "unexpected-relative-coordinate": "Coordenada relativa %0% n\xE3o \xE9 permitida", - "unexpected-scoreboard-sub-slot": "Apenas a \u201Csidebar\u201D tem sub slots", - "unknown-command": "Comando desconhecido %0%", - "unknown-escape": "Car\xE1ter de escape inesperado %0%", - "unknown-key": "Chave desconhecida %0%", - "unquoted-string": "uma string n\xE3o citada", - "unsorted-keys": "Chaves n\xE3o classificadas", - uuid: "um UUID", - vector: "um vetor" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/zh-cn.json -var zh_cn_exports = {}; -__export(zh_cn_exports, { - default: () => zh_cn_default -}); -var zh_cn_default; -var init_zh_cn = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/zh-cn.json"() { - zh_cn_default = { - array: "\u4E00\u4E2A\u6570\u7EC4", - boolean: "\u4E00\u4E2A\u5E03\u5C14\u503C", - "bug-of-mc": "\u7531\u4E8E\u4E00\u4E2AMinecraft\u7684\u6F0F\u6D1E\uFF08%0%\uFF09\uFF0C%1%\u3002\u8BF7\u62A5\u544AMojang\u4EE5\u4FEE\u590D", - "code-action.add-default-namespace": "\u6DFB\u52A0\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", - "code-action.add-leading-slash": "\u6DFB\u52A0\u524D\u5BFC\u659C\u6760", - "code-action.block-state-sort-keys": "\u5C06\u65B9\u5757\u72B6\u6001\u6309\u952E\u6392\u5E8F", - "code-action.command-replaceitem": "\u5C06\u8BE5\u547D\u4EE4\u5347\u7EA7\u4E3A /item ... replace", - "code-action.create-undeclared-file": "\u5728\u540C\u4E00\u4E2A\u5305\u4E2D\u521B\u5EFA %0% %1%", - "code-action.fix-file": "\u4FEE\u590D\u5F53\u524D\u6587\u4EF6\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", - "code-action.fix-workspace": "\u4FEE\u590D\u5F53\u524D\u5DE5\u4F5C\u7A7A\u95F4\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", - "code-action.id-attribute-datafix": "\u5C06\u8BE5\u5C5E\u6027\u540D\u66F4\u65B0\u5230 1.16", - "code-action.id-complete-default-namespace": "\u8865\u5168\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", - "code-action.id-create-file": "\u5728\u540C\u4E00\u4E2A\u6570\u636E\u5305\u4E2D\u521B\u5EFA%0%", - "code-action.id-omit-default-namespace": "\u7701\u7565\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", - "code-action.id-zombified-piglin-datafix": "\u6539\u4E3A\u50F5\u5C38\u732A\u7075\u7684ID", - "code-action.nbt-compound-sort-keys": "\u5C06 NBT \u590D\u5408\u6807\u7B7E\u6309\u952E\u6392\u5E8F", - "code-action.nbt-type-to-byte": "\u8F6C\u6362\u4E3A NBT \u5B57\u8282\u578B\uFF08byte\uFF09\u6807\u7B7E", - "code-action.nbt-type-to-double": "\u8F6C\u6362\u4E3A NBT \u53CC\u7CBE\u5EA6\u6D6E\u70B9\u6570\uFF08double\uFF09\u6807\u7B7E", - "code-action.nbt-type-to-float": "\u8F6C\u6362\u4E3A NBT \u5355\u7CBE\u5EA6\u6D6E\u70B9\u6570\uFF08float\uFF09\u6807\u7B7E", - "code-action.nbt-type-to-int": "\u8F6C\u6362\u4E3A NBT \u6574\u578B\uFF08int\uFF09\u6807\u7B7E", - "code-action.nbt-type-to-long": "\u8F6C\u6362\u4E3A NBT \u957F\u6574\u578B\uFF08long\uFF09\u6807\u7B7E", - "code-action.nbt-type-to-short": "\u8F6C\u6362\u4E3A NBT \u77ED\u6574\u578B\uFF08short\uFF09\u6807\u7B7E", - "code-action.nbt-uuid-datafix": "\u5C06\u8BE5 UUID \u66F4\u65B0\u5230 1.16", - "code-action.remove-leading-slash": "\u79FB\u9664\u524D\u5BFC\u659C\u6760", - "code-action.remove-trailing-separation": "\u79FB\u9664\u53E5\u5C3E\u5206\u9694\u7B26", - "code-action.selector-sort-keys": "\u5C06\u9009\u62E9\u5668\u53C2\u6570\u6309\u952E\u6392\u5E8F", - "code-action.string-double-quote": "\u4F7F\u7528\u534A\u89D2\u53CC\u5F15\u53F7\u5305\u88F9\u8BE5\u5B57\u7B26\u4E32", - "code-action.string-single-quote": "\u4F7F\u7528\u534A\u89D2\u5355\u5F15\u53F7\u5305\u88F9\u8BE5\u5B57\u7B26\u4E32", - "code-action.string-unquote": "\u79FB\u9664\u8BE5\u5B57\u7B26\u4E32\u7684\u5F15\u53F7", - "code-action.vector-align-0.0": "\u5C06\u8BE5\u5411\u91CF\u5BF9\u9F50\u81F3\u65B9\u5757\u539F\u70B9", - "code-action.vector-align-0.5": "\u5C06\u8BE5\u5411\u91CF\u5BF9\u9F50\u81F3\u65B9\u5757\u4E2D\u5FC3", - comment: "\u4EE5 %0% \u5F00\u59CB\u7684\u6CE8\u91CA", - "conjunction.and_2": " \u548C ", - "conjunction.and_3+_1": "\u3001 ", - "conjunction.and_3+_2": "\u548C ", - "conjunction.or_2": " \u6216 ", - "conjunction.or_3+_1": "\u3001 ", - "conjunction.or_3+_2": "\u6216 ", - "datafix.error.command-replaceitem": "/replaceitem \u5728 20w46a\uFF081.17 \u7684\u7B2C\u4E8C\u4E2A\u5FEB\u7167\uFF09\u4E2D\u88AB /item \u53D6\u4EE3", - "duplicate-key": "\u952E%0%\u91CD\u590D", - "ending-quote": "\u4E00\u4E2A\u7ED3\u5C3E\u5F15\u53F7%0%", - entity: "\u4E00\u4E2A\u5B9E\u4F53", - "error.unparseable-content": "\u9047\u5230\u4E86\u65E0\u6CD5\u89E3\u6790\u7684\u6587\u4EF6\u5185\u5BB9", - expected: "\u671F\u671B%0%", - "expected-got": "\u671F\u671B%0%\uFF0C\u4F46\u5F97\u5230\u4E86%1%", - float: "\u4E00\u4E2A\u6D6E\u70B9\u6570", - "float.between": "\u4E00\u4E2A\u5904\u4E8E %0% \u4E0E %1% \u4E4B\u95F4\u7684\u6D6E\u70B9\u578B\u6570\u5B57", - integer: "\u4E00\u4E2A\u6574\u578B\u6570\u5B57", - "integer.between": "\u4E00\u4E2A\u5904\u4E8E %0% \u4E0E %1% \u4E4B\u95F4\u7684\u6574\u578B\u6570\u5B57", - "invalid-key-combination": "\u952E\u7EC4\u5408 %0% \u65E0\u6548", - "invalid-regex-pattern": "\u65E0\u6548\u7684\u6B63\u5219\u6A21\u5F0F\u4E32\uFF1A%0%", - "java-edition.binder.wrong-folder": "\u5DF2\u52A0\u8F7D\u7684\u7248\u672C %1% \u65E0\u6CD5\u8BC6\u522B %0% \u6587\u4EF6\u5939\u4E2D\u7684\u6587\u4EF6\uFF0C\u4F60\u60F3\u4F7F\u7528\u7684\u662F %2% \u6587\u4EF6\u5939\u5417\uFF1F", - "java-edition.binder.wrong-version": "\u5728\u5DF2\u52A0\u8F7D\u7684\u7248\u672C %1% \u4E2D\u65E0\u6CD5\u8BC6\u522B %0% \u6587\u4EF6\u5939\u4E2D\u7684\u6587\u4EF6", - "java-edition.translation-value.percent-escape-hint": "%0%\u3002\u5982\u679C\u4F60\u60F3\u8981\u663E\u793A\u767E\u5206\u53F7\u7B26\u53F7\uFF0C\u8BF7\u6539\u7528\u201C%%\u201D", - "json.checker.array.length-between": "\u957F\u5EA6\u5728 %1% \u4E0E %2% \u4E4B\u95F4\u7684%0%", - "json.checker.item.duplicate": "\u91CD\u590D\u7684\u5217\u8868\u6761\u76EE", - "json.checker.object.field.union-empty-members": "\u7981\u7528\u5C5E\u6027", - "json.checker.property.deprecated": "\u5C5E\u6027 %0% \u5DF2\u88AB\u5F03\u7528", - "json.checker.property.missing": "\u7F3A\u5931\u5C5E\u6027 %0%", - "json.checker.property.unknown": "\u672A\u77E5\u5C5E\u6027 %0%", - "json.checker.string.hex-color": "\u4E00\u4E2A6\u4F4D\u7684\u5341\u516D\u8FDB\u5236\u6570\u5B57", - "json.checker.tag-entry.duplicate": "\u91CD\u590D\u7684\u6807\u7B7E\u6761\u76EE", - "json.checker.value": "\u4E00\u4E2A\u503C", - "json.doc.advancement.display": "\u8FDB\u5EA6\u7684\u663E\u793A\u8BBE\u7F6E\u3002\u5982\u679C\u5B58\u5728\uFF0C\u5219\u8BE5\u8FDB\u5EA6\u5C06\u5728\u8FDB\u5EA6\u9009\u9879\u5361\u4E2D\u53EF\u89C1\u3002", - "json.node.array": "\u4E00\u4E2A\u6570\u7EC4", - "json.node.boolean": "\u4E00\u4E2A\u5E03\u5C14\u503C", - "json.node.null": "\u4E00\u4E2A\u7A7A\u503C", - "json.node.number": "\u4E00\u4E2A\u6570\u5B57", - "json.node.object": "\u4E00\u4E2A\u5BF9\u8C61", - "json.node.string": "\u4E00\u4E2A\u5B57\u7B26\u4E32", - "key-not-following-convention": "\u65E0\u6548\u7684\u952E%0%\uFF0C\u56E0\u4E3A\u6CA1\u6709\u9075\u5FAA%1%\u547D\u540D\u89C4\u8303", - "linter-config-validator.name-convention.type": "\u671F\u671B\u4E00\u4E2A\u6B63\u5219\u8868\u8FBE\u5F0F\u5B57\u7B26\u4E32\u7528\u4E8E\u63CF\u8FF0\u547D\u540D\u89C4\u8303", - "linter-config-validator.wrapper": "%0%\u3002\u8BF7\u53C2\u9605[\u6587\u6863](%1)\u83B7\u53D6\u66F4\u591A\u4FE1\u606F", - "linter.diagnostic-message-wrapper": "%0%\uFF08\u89C4\u5219\uFF1A%1%\uFF09", - "linter.name-convention.illegal": "\u540D\u79F0 %0% \u4E0D\u5339\u914D\u914D\u7F6E\u7684\u6B63\u5219\u8868\u8FBE\u5F0F %1%", - "linter.undeclared-symbol.message": "\u627E\u4E0D\u5230%0%%1%", - long: "\u4E00\u4E2A\u957F\u6574\u578B\u6570\u5B57", - "long.between": "\u5728%0%\u548C%1%\u4E4B\u95F4\u7684\u957F\u6574\u578B", - "mcdoc.binder.dispatcher-statement.duplicated-key": "\u91CD\u590D\u7684\u8C03\u5EA6\u5668 %0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0% \u5DF2\u7ECF\u88AB\u8C03\u5EA6\u5230\u4E86\u8FD9\u91CC", - "mcdoc.binder.duplicated-declaration": "\u91CD\u590D\u58F0\u660E %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% \u5DF2\u5728\u8FD9\u91CC\u88AB\u58F0\u660E\u8FC7\u4E86", - "mcdoc.binder.out-of-root": "\u6587\u4EF6 %0% \u4E0D\u5728\u4EFB\u4F55 mcdoc \u9879\u76EE\u7684\u6839\u76EE\u5F55\u4E0B\uFF0C\u56E0\u6B64\u5C06\u8DF3\u8FC7\u8BED\u4E49\u68C0\u6D4B", - "mcdoc.binder.path.super-from-root": "\u65E0\u6CD5\u8BBF\u95EE\u9879\u76EE\u6839\u76EE\u5F55\u7684\u4E0A\u4E00\u7EA7\u76EE\u5F55\uFF08`super`\uFF09", - "mcdoc.binder.path.unknown-identifier": "\u6A21\u5757 %1% \u4E2D\u4E0D\u5B58\u5728\u6807\u8BC6\u7B26 %0%", - "mcdoc.binder.path.unknown-module": "\u6A21\u5757 %0% \u4E0D\u5B58\u5728", - "mcdoc.checker.entry.empty-mod-seg": "\u4F60\u4E0D\u80FD\u5C06\u201Cmod.mcdoc\u201D\u76F4\u63A5\u653E\u5728\u6839\u76EE\u5F55\u4E0B", - "mcdoc.checker.inject-clause.unmatched-injection": "\u4E0D\u80FD\u6CE8\u5165 %0% \u4EE5 %1%", - "mcdoc.checker.type-not-assignable": "\u7C7B\u578B %0% \u4E0D\u80FD\u5206\u914D\u7ED9\u7C7B\u578B %1%", - "mcdoc.node.compound-definition": "\u4E00\u4E2A\u590D\u5408\u5B9A\u4E49", - "mcdoc.node.enum-definition": "\u4E00\u4E2A\u679A\u4E3E\u5B9A\u4E49", - "mcdoc.node.identifier": "\u4E00\u4E2A\u6807\u8BC6\u7B26", - "mcdoc.parser.compound-definition.field-type": "\u4E00\u4E2A\u5B57\u6BB5\u7C7B\u578B", - "mcdoc.parser.float.illegal": "\u9047\u5230\u4E86\u65E0\u6548\u7684\u6D6E\u70B9\u6570", - "mcdoc.parser.identifier.illegal": "%0% \u4E0D\u9075\u5FAA\u683C\u5F0F %1%", - "mcdoc.parser.identifier.reserved-word": "%0% \u662F\u4FDD\u7559\u5B57\uFF0C\u65E0\u6CD5\u88AB\u7528\u4F5C\u6807\u8BC6\u7B26", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u4E0D\u5141\u8BB8\u52A8\u6001\u7D22\u5F15", - "mcdoc.parser.inject-clause.definition-expected": "\u671F\u671B\u4E00\u4E2A\u679A\u4E3E\u6CE8\u5165\u6216\u590D\u5408\u6CE8\u5165", - "mcdoc.parser.keyword.separation": "\u4E00\u4E2A\u5206\u9694\u7B26", - "mcdoc.parser.resource-location.colon-expected": "\u671F\u671B\u8D44\u6E90\u8DEF\u5F84\u4E2D\u7684\u5192\u53F7\uFF08%0%\uFF09", - "mcdoc.parser.syntax.doc-comment-unexpected": "\u6B64\u5904\u4E0D\u5141\u8BB8\u6587\u6863\u6CE8\u91CA\uFF1B\u4F60\u53EF\u80FD\u60F3\u5C06\u4E09\u4E2A\u659C\u6760\u66FF\u6362\u4E3A\u4E24\u4E2A\u659C\u6760", - "mcdoc.runtime.checker.key-value-pair": "\u4E00\u4E2A\u952E\u503C\u5BF9", - "mcdoc.runtime.checker.range.collection": "\u96C6\u5408\u957F\u5EA6\u5E94\u4E3A%0%", - "mcdoc.runtime.checker.range.concat": "%0%\u548C%1%", - "mcdoc.runtime.checker.range.left-exclusive": "\u5728%0%\u4EE5\u4E0A", - "mcdoc.runtime.checker.range.left-inclusive": "\u81F3\u5C11\u4E3A%0%", - "mcdoc.runtime.checker.range.number": "\u5E94\u4E3A\u6570\u503C%0%", - "mcdoc.runtime.checker.range.right-exclusive": "\u5728%0%\u4EE5\u4E0B", - "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u5927\u4E3A%0%", - "mcdoc.runtime.checker.range.string": "\u5B57\u7B26\u4E32\u957F\u5EA6\u5E94\u4E3A%0%", - "mcdoc.runtime.checker.some-missing-keys": "\u81F3\u5C11\u9700\u8981 %0% \u4E2D\u7684\u4E00\u4E2A\u952E", - "mcdoc.runtime.checker.trailing": "\u7A81\u9047\u53E5\u5C3E\u6570\u636E", - "mcfunction.checker.command.data-modify-unapplicable-operation": "\u4E0D\u80FD\u5728 %1% \u4E0A\u4F7F\u7528 %0% \u64CD\u4F5C\uFF1B\u76EE\u6807\u8DEF\u5F84\u7684\u7C7B\u578B\u4E3A %2%", - "mcfunction.completer.block.states.default-value": "\u9ED8\u8BA4\u503C\uFF1A%0%", - "mcfunction.parser.command-too-long": "\u547D\u4EE4\u957F\u5EA6\u4E3A %0% \uFF0C\u4E0D\u5141\u8BB8\u8D85\u8FC7\u5176\u957F\u5EA6\u4E0A\u9650 %1%", - "mcfunction.parser.duplicate-components": "\u7EC4\u4EF6\u91CD\u590D", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% \u4E0D\u9002\u7528\u4E8E\u6B64\u5904", - "mcfunction.parser.entity-selector.arguments.unknown": "\u672A\u77E5\u7684\u5B9E\u4F53\u9009\u62E9\u5668\u53C2\u6570 %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "\u8BE5\u9009\u62E9\u5668\u5305\u542B\u975E\u73A9\u5BB6\u5B9E\u4F53", - "mcfunction.parser.entity-selector.invalid": "\u65E0\u6548\u7684\u9009\u62E9\u5668\uFF1A\u201C%0%\u201D", - "mcfunction.parser.entity-selector.multiple-disallowed": "\u8BE5\u9009\u62E9\u5668\u5305\u542B\u591A\u4E2A\u5B9E\u4F53", - "mcfunction.parser.entity-selector.player-name.too-long": "\u73A9\u5BB6\u540D\u79F0\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", - "mcfunction.parser.eoc-unexpected": "\u671F\u671B\u66F4\u591A\u53C2\u6570", - "mcfunction.parser.leading-slash": "\u4E00\u4E2A\u524D\u5BFC\u659C\u6760 \u201C/\u201D", - "mcfunction.parser.leading-slash.unexpected": "\u4E0D\u80FD\u4EE5\u659C\u6760\u201C/\u201D\u5F00\u5934", - "mcfunction.parser.macro.at-least-one": "\u5E94\u81F3\u5C11\u5305\u542B\u4E00\u4E2A\u5B8F\u53C2\u6570", - "mcfunction.parser.macro.disallowed": "\u5B8F\u884C\u4EC5\u53D71.20.2\u4E4B\u540E\u7684\u7248\u672C\u652F\u6301", - "mcfunction.parser.macro.illegal-key": "\u952E\u5B57\u7B26\u8BED\u6CD5\u9519\u8BEF\uFF1A\u201C%0%\u201D", - "mcfunction.parser.macro.key": "\u4E00\u4E2A\u5B8F\u952E", - "mcfunction.parser.no-permission": "\u9700\u8981\u6743\u9650\u7B49\u7EA7 %0%\uFF0C\u9AD8\u4E8E\u8BBE\u7F6E\u4E2D\u5B9A\u4E49\u7684 %1%", - "mcfunction.parser.objective.too-long": "\u8BB0\u5206\u9879\u540D\u79F0\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", - "mcfunction.parser.range.min>max": "\u6700\u5C0F\u503C %0% \u5927\u4E8E\u6700\u5927\u503C %1%", - "mcfunction.parser.range.span-too-large": "\u8303\u56F4 %0% \u6BD4\u6700\u5927\u503C %1% \u8FD8\u5927", - "mcfunction.parser.range.span-too-small": "\u8303\u56F4 %0% \u6BD4\u6700\u5C0F\u503C %1% \u8FD8\u5C0F", - "mcfunction.parser.score_holder.fake-name.too-long": "\u5B9E\u4F53\u5047\u540D\u957F\u5EA6\u4E0D\u80FD\u591A\u4E8E %0% \u4E2A\u5B57\u7B26", - "mcfunction.parser.sep": "\u4E00\u4E2A\u7A7A\u683C (%0%)", - "mcfunction.parser.trailing": "\u9047\u5230\u5C3E\u968F\u7684\u6570\u636E\uFF1A%0%", - "mcfunction.parser.unknown-parser": "\u5C1A\u672A\u652F\u6301\u89E3\u6790\u5668 %0%", - "mcfunction.parser.uuid.invalid": "\u65E0\u6548\u7684UUID\u683C\u5F0F", - "mcfunction.parser.vector.local-disallowed": "\u5C40\u90E8\u5750\u6807\u4E0D\u5141\u8BB8\u5728\u6B64\u5904\u4F7F\u7528", - "mcfunction.parser.vector.mixed": "\u4E0D\u80FD\u5C06\u5C40\u90E8\u5750\u6807\u4E0E\u4E16\u754C\u5750\u6807\u6DF7\u5408\u4F7F\u7528", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki\uFF1A`%0%` \u53C2\u6570\u89E3\u6790\u5668](https://minecraft.fandom.com/zh/wiki/\u53C2\u6570\u7C7B\u578B#%0%)", - "mcfunction.signature-help.command-documentation": "[Minecraft Wiki\uFF1A`%0%` \u547D\u4EE4](https://minecraft.fandom.com/zh/wiki/Commands/%0%)", - "mismatching-regex-pattern": "\u503C\u65E0\u6CD5\u5339\u914D\u6B63\u5219\u8868\u8FBE\u5F0F\uFF1A%0%", - "missing-key": "\u7F3A\u5931\u952E %0%", - "nbt.checker.block-states.fake-boolean": "\u5E94\u7528\u5F15\u53F7\u5305\u88F9\u5E03\u5C14\u578B\u65B9\u5757\u72B6\u6001\u503C", - "nbt.checker.block-states.unexpected-value-type": "\u65B9\u5757\u72B6\u6001\u503C\u5E94\u4E3A\u5B57\u7B26\u4E32\u6216\u6574\u6570", - "nbt.checker.block-states.unknown-state": "\u4EE5\u4E0B\u65B9\u5757\u5177\u6709\u672A\u77E5\u65B9\u5757\u72B6\u6001 %0% \uFF1A%1%", - "nbt.checker.boolean.out-of-range": "\u5E03\u5C14\u503C\u5E94\u4E3A %0% \u6216 %1%", - "nbt.checker.collection.length-between": "%0% \u7684\u957F\u5EA6\u5728 %1% \u548C %2% \u4E4B\u95F4", - "nbt.checker.compound.field.union-empty-members": "\u4E0D\u5141\u8BB8\u7684\u5C5E\u6027", - "nbt.checker.path.index-out-of-bound": "\u63D0\u4F9B\u7684\u7D22\u5F15 %0% \u8D8A\u754C\uFF0C\u56E0\u4E3A\u96C6\u5408\u6700\u591A\u53EA\u80FD\u62E5\u6709 %1% \u4E2A\u5143\u7D20", - "nbt.checker.path.unexpected-filter": "\u590D\u5408\u6807\u7B7E\u8FC7\u6EE4\u5668\u53EA\u80FD\u7528\u4E8E\u590D\u5408\u6807\u7B7E", - "nbt.checker.path.unexpected-index": "\u7D22\u5F15\u53EA\u80FD\u7528\u4E8E\u6570\u7EC4\u6216\u5217\u8868\u6807\u7B7E", - "nbt.checker.path.unexpected-key": "\u5B57\u7B26\u4E32\u952E\u53EA\u80FD\u4E3A\u590D\u5408\u6807\u7B7E\u6307\u5B9A", - "nbt.node": "\u4E00\u4E2A\u6807\u7B7E", - "nbt.node.byte": "\u4E00\u4E2A\u5B57\u8282\u6807\u7B7E", - "nbt.node.byte_array": "\u4E00\u4E2A\u5B57\u8282\u6570\u7EC4\u6807\u7B7E", - "nbt.node.compound": "\u4E00\u4E2A\u590D\u5408\u6807\u7B7E", - "nbt.node.double": "\u4E00\u4E2A\u53CC\u7CBE\u5EA6\u6D6E\u70B9\u578B\u6807\u7B7E", - "nbt.node.float": "\u4E00\u4E2A\u6D6E\u70B9\u578B\u6807\u7B7E", - "nbt.node.int": "\u4E00\u4E2A\u6574\u578B\u6807\u7B7E", - "nbt.node.int_array": "\u4E00\u4E2A\u6574\u578B\u6570\u7EC4\u6807\u7B7E", - "nbt.node.list": "\u4E00\u4E2A\u5217\u8868\u6807\u7B7E", - "nbt.node.long": "\u4E00\u4E2A\u957F\u6574\u578B\u6807\u7B7E", - "nbt.node.long_array": "\u4E00\u4E2A\u957F\u6574\u578B\u6570\u7EC4\u6807\u7B7E", - "nbt.node.path.end": "\u8DEF\u5F84\u7ED3\u5C3E", - "nbt.node.path.filter": "\u4E00\u4E2A\u590D\u5408\u6807\u7B7E\u8FC7\u6EE4\u5668", - "nbt.node.path.index": "\u4E00\u4E2A\u7D22\u5F15", - "nbt.node.path.key": "\u4E00\u4E2A\u952E", - "nbt.node.short": "\u4E00\u4E2A\u77ED\u6574\u578B\u6807\u7B7E", - "nbt.node.string": "\u4E00\u4E2A\u5B57\u7B26\u4E32\u6807\u7B7E", - "nbt.parser.number.out-of-range": "\u8FD9\u770B\u8D77\u6765\u50CF %0%\uFF0C\u4F46\u5B9E\u9645\u4E0A\u662F %1%\uFF0C\u7531\u4E8E\u6570\u503C\u8D85\u51FA\u4E86 [%2%, %3%]", - "nbt.path": "\u4E00\u4E2ANBT\u8DEF\u5F84", - "not-allowed-here": "\u503C %0% \u4E0D\u5141\u8BB8\u5728\u8FD9\u91CC\u51FA\u73B0", - "not-divisible-by": "\u503C %0% \u4E0D\u80FD\u88AB %1% \u6574\u9664", - "not-matching-any-child": "\u65E0\u6548\u53C2\u6570", - nothing: "\u65E0", - number: "\u4E00\u4E2A\u6570\u5B57", - "number-range": "\u4E00\u4E2A\u6570\u5B57\u8303\u56F4", - "number-range.missing-min-and-max": "\u671F\u671B\u4E00\u4E2A\u6700\u5C0F\u503C\u6216\u4E00\u4E2A\u6700\u5927\u503C", - "number.<=": "\u4E00\u4E2A\u5C0F\u4E8E\u7B49\u4E8E %0% \u7684\u6570\u5B57", - "number.>=": "\u4E00\u4E2A\u5927\u4E8E\u7B49\u4E8E %0% \u7684\u6570\u5B57", - "number.between": "\u4E00\u4E2A\u4F4D\u4E8E %0% \u548C %1% \u4E4B\u95F4\u7684\u6570\u5B57", - object: "\u4E00\u4E2A\u5BF9\u8C61", - objective: "\u4E00\u4E2A\u8BB0\u5206\u9879", - "objective-not-following-convention": "\u8BE5\u8BB0\u5206\u9879%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", - "parser.float.illegal": "\u6D6E\u70B9\u6570\u7531\u4E8E\u672A\u8DDF\u968F %0% \u800C\u65E0\u6548", - "parser.integer.illegal": "\u65E0\u6548\u7684\u6574\u6570\u4E0D\u9075\u5FAA %0%", - "parser.line-continuation-end-of-file": "\u884C\u4E0D\u80FD\u4EE5\u6587\u4EF6\u7ED3\u675F\u7B26\u7EED\u63A5", - "parser.list.trailing-sep": "\u5C3E\u968F\u5206\u9694\u7B26", - "parser.list.value": "\u4E00\u4E2A\u503C", - "parser.long.illegal": "\u957F\u6574\u578B\u6570\u5B57\u56E0\u672A\u8DDF\u968F %0% \u800C\u65E0\u6548", - "parser.record.key": "\u4E00\u4E2A\u952E", - "parser.record.trailing-end": "\u5C3E\u968F\u5206\u9694\u7B26", - "parser.record.unexpected-char": "\u9884\u671F\u5916\u7684\u5B57\u7B26 %0%", - "parser.record.value": "\u4E00\u4E2A\u503C", - "parser.resource-location.illegal": "\u65E0\u6548\u5B57\u7B26\uFF1A%0%", - "parser.resource-location.namespace-expected": "\u4E0D\u53EF\u5728\u6B64\u7701\u7565\u547D\u540D\u7A7A\u95F4", - "parser.resource-location.tag-disallowed": "\u6B64\u5904\u4E0D\u5141\u8BB8\u4F7F\u7528\u6807\u7B7E", - "parser.resource-location.tag-required": "\u8FD9\u91CC\u53EA\u80FD\u4E3A\u6807\u7B7E", - "parser.string.illegal-brigadier": "\u5728 %0% \u4E2D\u9047\u5230\u4E86\u975E [0-9A-Za-z_.+-] \u5B57\u7B26", - "parser.string.illegal-escape": "\u9884\u671F\u5916\u7684\u8F6C\u4E49\u5B57\u7B26 %0%", - "parser.string.illegal-quote": "\u6B64\u5904\u53EA\u5141\u8BB8\u4F7F\u7528 %0% \u5305\u88F9\u5B57\u7B26\u4E32", - "parser.string.illegal-unicode-escape": "\u671F\u671B\u5341\u516D\u8FDB\u5236\u6570\u5B57", - "progress.initializing.title": "\u6B63\u5728\u521D\u59CB\u5316Spyglass\u2026\u2026", - "progress.reset-project-cache.title": "\u6B63\u5728\u91CD\u7F6E\u9879\u76EE\u7F13\u5B58\u2026", - "punc.period": "\u3002", - "punc.quote": "\u201C%0%\u201D", - quote: `\u4E00\u4E2A\u534A\u89D2\u5F15\u53F7\uFF08\u201C'\u201D\u6216\u201C"\u201D\uFF09`, - quote_prefer_double: '\u6B64\u5904\u8BF7\u4F18\u5148\u4F7F\u7528\u534A\u89D2\u53CC\u5F15\u53F7\uFF08\u201C"\u201D\uFF09', - quote_prefer_single: "\u6B64\u5904\u8BF7\u4F18\u5148\u4F7F\u7528\u534A\u89D2\u5355\u5F15\u53F7\uFF08\u201C'\u201D\uFF09", - "resource-location": "\u4E00\u4E2A\u8D44\u6E90\u4F4D\u7F6E", - "score-holder": "\u4E00\u4E2A\u5206\u6570\u6301\u6709\u8005", - "scoreholder-not-following-convention": "\u65E0\u6548\u7684\u5206\u6570\u6301\u6709\u8005 %0% \u4E0D\u9075\u5FAA %1% \u547D\u540D\u89C4\u5219", - selector: "\u4E00\u4E2A\u9009\u62E9\u5668", - "server.new-version": "\u5DF2\u66F4\u65B0\u6570\u636E\u5305\u8BED\u8A00\u670D\u52A1\u5668\u5230\u65B0\u7248\u672C\uFF1A%0%", - "server.progress.fixing-workspace.begin": "\u4FEE\u590D\u5F53\u524D\u5DE5\u4F5C\u7A7A\u95F4\u4E2D\u6240\u6709\u53EF\u81EA\u52A8\u4FEE\u590D\u7684\u95EE\u9898", - "server.progress.fixing-workspace.report": "\u6B63\u5728\u4FEE\u590D%0%", - "server.progress.preparing.title": "\u6B63\u5728\u51C6\u5907 Spyglass \u8BED\u8A00\u7279\u6027", - "server.remove-cache-file": "DHP \u7684\u7F13\u5B58\u6587\u4EF6\u88AB\u79FB\u52A8\u5230\u4E86\u4E00\u4E2A\u7531 VS Code \u63D0\u4F9B\u7684\u7F13\u5B58\u4F4D\u7F6E\u3002\u60A8\u73B0\u5728\u53EF\u4EE5\u653E\u5FC3\u5730\u5220\u9664\u5DE5\u4F5C\u533A\u6839\u6587\u4EF6\u5939\u4E2D\u7684\u201C.datapack\u201D\u6587\u4EF6\u5939\u3002", - "server.show-release-notes": "\u663E\u793A\u66F4\u65B0\u65E5\u5FD7", - string: "\u4E00\u4E2A\u5B57\u7B26\u4E32", - tag: "\u4E00\u4E2A\u6807\u7B7E", - "tag-not-following-convention": "\u8BE5\u6807\u7B7E%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", - team: "\u4E00\u4E2A\u961F\u4F0D", - "team-not-following-convention": "\u8BE5\u961F\u4F0D%0%\u6CA1\u6709\u8DDF\u968F\u547D\u540D\u89C4\u5219%1%", - "text-component": "\u4E00\u4E2A\u6587\u672C\u7EC4\u4EF6", - "time-unit": "\u4E00\u4E2A\u65F6\u95F4\u5355\u4F4D", - "too-many-block-affected": "\u6307\u5B9A\u533A\u57DF\u5185\u7684\u65B9\u5757\u592A\u591A\uFF08\u6700\u5927\u503C\u4E3A %0%\uFF0C\u6307\u5B9A\u503C\u4E3A %1%\uFF09", - "too-many-chunk-affected": "\u6307\u5B9A\u533A\u57DF\u5185\u7684\u533A\u5757\u592A\u591A\uFF08\u6700\u5927\u503C\u4E3A %0%\uFF0C\u6307\u5B9A\u503C\u4E3A %1%\uFF09", - "unexpected-character": "\u9047\u5230\u4E86\u975E [a-z0-9/._-] \u5B57\u7B26", - "unexpected-datapack-tag": "\u6B64\u5904\u4E0D\u5141\u8BB8\u4F7F\u7528\u6807\u7B7E", - "unexpected-default-namespace": "\u5E94\u5F53\u7701\u7565\u6B64\u5904\u7684\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", - "unexpected-local-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u5C40\u90E8\u5750\u6807%0%", - "unexpected-nbt": "\u6B64\u5904\u4E0D\u5E94\u4F7F\u7528\u8BE5 NBT \u6807\u7B7E", - "unexpected-nbt-array-type": "\u65E0\u6548\u7684\u6570\u7EC4\u7C7B\u578B%0%\u3002\u5E94\u5F53\u4E3A\u201CB\u201D\u201CI\u201D\u201CL\u201D\u4E2D\u7684\u4E00\u4E2A", - "unexpected-nbt-path-filter": "\u590D\u5408\u6807\u7B7E\u7B5B\u9009\u5668\u53EA\u80FD\u5BF9\u590D\u5408\u6807\u7B7E\u4F7F\u7528", - "unexpected-nbt-path-index": "\u7D22\u5F15\u53EA\u80FD\u5BF9\u5217\u8868\u6216\u6570\u7EC4\u6807\u7B7E\u4F7F\u7528", - "unexpected-nbt-path-key": "\u952E\u53EA\u80FD\u5BF9\u590D\u5408\u6807\u7B7E\u4F7F\u7528", - "unexpected-nbt-path-sub": "\u5F53\u524D\u7684\u6807\u7B7E\u5E76\u6CA1\u6709\u66F4\u591A\u7684\u5B50\u9879", - "unexpected-omitted-default-namespace": "\u6B64\u5904\u4E0D\u80FD\u7701\u7565\u9ED8\u8BA4\u547D\u540D\u7A7A\u95F4", - "unexpected-relative-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u76F8\u5BF9\u5750\u6807%0%", - "unexpected-scoreboard-sub-slot": "\u53EA\u6709\u201Csidebar\u201D\u6709\u5B50\u663E\u793A\u4F4D\u7F6E", - "unknown-command": "\u672A\u77E5\u7684\u547D\u4EE4%0%", - "unknown-escape": "\u9884\u671F\u5916\u7684\u8F6C\u4E49\u5B57\u7B26 %0%", - "unknown-key": "\u672A\u77E5\u7684\u952E%0%", - "unquoted-string": "\u4E00\u4E2A\u672A\u88AB\u5F15\u53F7\u5305\u88F9\u7684\u5B57\u7B26\u4E32", - "unsorted-keys": "\u952E\u672A\u6392\u5E8F", - uuid: "\u4E00\u4E2A UUID", - vector: "\u4E00\u4E2A\u5411\u91CF" - }; - } -}); - -// node_modules/@spyglassmc/locales/lib/locales/zh-tw.json -var zh_tw_exports = {}; -__export(zh_tw_exports, { - default: () => zh_tw_default -}); -var zh_tw_default; -var init_zh_tw = __esm({ - "node_modules/@spyglassmc/locales/lib/locales/zh-tw.json"() { - zh_tw_default = { - array: "\u4E00\u500B\u9663\u5217", - boolean: "\u4E00\u500B\u5E03\u6797\u503C", - "bug-of-mc": "\u7531\u65BC\u4E00\u500BMinecraft\u7684\u932F\u8AA4\uFF08%0%\uFF09\uFF0C%1%\u3002Mojang\uFF0C\u62DC\u8A17\u4FEE\u597D\u4F60\u7684\u904A\u6232", - "code-action.add-default-namespace": "\u589E\u52A0\u9810\u8A2D\u547D\u540D\u7A7A\u9593", - "code-action.add-leading-slash": "\u589E\u52A0\u958B\u982D\u7684\u659C\u7DDA", - "code-action.block-state-sort-keys": "\u5C07\u65B9\u584A\u72C0\u614B\u6309\u9375\u6392\u5E8F", - "code-action.command-replaceitem": "\u5C07\u8A72\u6307\u4EE4\u5347\u7D1A\u5230 /item ... replace", - "code-action.create-undeclared-file": "\u5EFA\u7ACB%0% %1%", - "code-action.fix-file": "\u4FEE\u5FA9\u7576\u524D\u6A94\u6848\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", - "code-action.fix-workspace": "\u4FEE\u5FA9\u7576\u524D\u5DE5\u4F5C\u5340\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", - "code-action.id-attribute-datafix": "\u5C07\u8A72\u5C6C\u6027\u540D\u66F4\u65B0\u81F3 1.16", - "code-action.id-complete-default-namespace": "\u88DC\u5B8C\u9810\u8A2D\u547D\u540D\u7A7A\u9593", - "code-action.id-create-file": "\u5728\u540C\u4E00\u500B\u8CC7\u6599\u5305\u4E2D\u5EFA\u7ACB%0%", - "code-action.id-omit-default-namespace": "\u7701\u7565\u9810\u8A2D\u547D\u540D\u7A7A\u9593", - "code-action.id-zombified-piglin-datafix": "\u5C07\u8A72 ID \u5347\u7D1A\u70BA\u6BAD\u5C4D\u5316\u8C6C\u5E03\u6797", - "code-action.nbt-compound-sort-keys": "\u5C07 NBT \u8907\u5408\u6A19\u7C64\u6309\u9375\u6392\u5E8F", - "code-action.nbt-type-to-byte": "\u8F49\u63DB\u70BA NBT \u4F4D\u5143\u7D44\uFF08byte\uFF09\u6A19\u7C64", - "code-action.nbt-type-to-double": "\u8F49\u63DB\u70BA NBT \u500D\u7CBE\u5EA6\u6D6E\u9EDE\u6578\uFF08double\uFF09\u6A19\u7C64", - "code-action.nbt-type-to-float": "\u8F49\u63DB\u70BA NBT \u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\uFF08float\uFF09\u6A19\u7C64", - "code-action.nbt-type-to-int": "\u8F49\u63DB\u70BA NBT \u6574\u6578\uFF08int\uFF09\u6A19\u7C64", - "code-action.nbt-type-to-long": "\u8F49\u63DB\u70BA NBT \u9577\u6574\u6578\uFF08long\uFF09\u6A19\u7C64", - "code-action.nbt-type-to-short": "\u8F49\u63DB\u70BA NBT \u77ED\u6574\u6578\uFF08short\uFF09\u6A19\u7C64", - "code-action.nbt-uuid-datafix": "\u5C07\u8A72 UUID \u66F4\u65B0\u81F3 1.16", - "code-action.remove-leading-slash": "\u79FB\u9664\u958B\u982D\u7684\u659C\u7DDA", - "code-action.remove-trailing-separation": "\u79FB\u9664\u7D50\u5C3E\u7684\u5206\u9694\u7B26\u865F", - "code-action.selector-sort-keys": "\u5C07\u9078\u64C7\u5668\u5F15\u6578\u6309\u9375\u6392\u5E8F", - "code-action.string-double-quote": "\u4F7F\u7528\u82F1\u6587\u96D9\u5F15\u865F\u5305\u88F9\u8A72\u5B57\u4E32", - "code-action.string-single-quote": "\u4F7F\u7528\u82F1\u6587\u55AE\u5F15\u865F\u5305\u88F9\u8A72\u5B57\u4E32", - "code-action.string-unquote": "\u79FB\u9664\u8A72\u5B57\u4E32\u7684\u5F15\u865F", - "code-action.vector-align-0.0": "\u5C07\u8A72\u5411\u91CF\u5C0D\u9F4A\u5230\u65B9\u584A\u539F\u9EDE", - "code-action.vector-align-0.5": "\u5C07\u8A72\u5411\u91CF\u5C0D\u9F4A\u5230\u65B9\u584A\u4E2D\u5FC3", - comment: "\u4EE5 %0% \u958B\u59CB\u7684\u8A3B\u89E3", - "conjunction.and_2": " \u548C ", - "conjunction.and_3+_1": "\u3001 ", - "conjunction.and_3+_2": "\u548C ", - "conjunction.or_2": " \u6216 ", - "conjunction.or_3+_1": "\u3001 ", - "conjunction.or_3+_2": "\u6216 ", - "datafix.error.command-replaceitem": "/replaceitem \u5728 20w46a\uFF081.17 \u7684\u7B2C\u4E8C\u500B\u5FEB\u7167\uFF09\u4E2D\u88AB /item \u53D6\u4EE3", - "duplicate-key": "\u9375%0%\u91CD\u8907", - "ending-quote": "\u4E00\u500B\u7D50\u5C3E\u5F15\u865F%0%", - entity: "\u4E00\u500B\u5BE6\u9AD4", - "error.unparseable-content": "\u9047\u5230\u4E86\u7121\u6CD5\u89E3\u6790\u7684\u5167\u5BB9", - expected: "\u671F\u671B%0%", - "expected-got": "\u671F\u671B%0%\uFF0C\u4F46\u5F97\u5230\u4E86%1%", - float: "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578", - "float.between": "\u4E00\u500B\u8655\u65BC %0% \u8207 %1% \u4E4B\u9593\u7684\u6D6E\u9EDE\u578B\u6578\u5B57", - integer: "\u4E00\u500B\u6574\u6578", - "integer.between": "\u4E00\u500B\u8655\u65BC %0% \u8207 %1% \u4E4B\u9593\u7684\u6574\u6578", - "invalid-key-combination": "\u7121\u6548\u7684\u7D44\u5408 %0%", - "invalid-regex-pattern": "\u7121\u6548\u7684regex\uFF1A%0%", - "java-edition.binder.wrong-folder": "\u5728%0%\u8CC7\u6599\u593E\u4E2D\u7684\u6A94\u6848\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09\uFF0C\u4F60\u9700\u8981\u7684\u662F%2%\u8CC7\u6599\u593E\u55CE\uFF1F", - "java-edition.binder.wrong-version": "\u5728%0%\u8CC7\u6599\u593E\u4E2D\u7684\u6A94\u6848\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09", - "java-edition.pack-format.not-loaded": "\u8CC7\u6599\u5305\u7248\u672C%0%\u4E0D\u5C6C\u65BC\u73FE\u5728\u8F09\u5165\u7684\u904A\u6232\u7248\u672C\uFF08%1%\uFF09\u3002\u4F60\u53EF\u80FD\u9700\u8981\u91CD\u65B0\u8F09\u5165Spyglass\u3002", - "java-edition.pack-format.unsupported": "\u8CC7\u6599\u5305\u7248\u672C%0%\u4E0D\u5C6C\u65BC\u6B63\u5F0F\u7248\u672C\u3002\u5FEB\u7167\u7248\u672C\u4E0D\u53D7\u652F\u63F4\u3002", - "java-edition.translation-value.percent-escape-hint": "%0%\u3002\u4F7F\u7528\u300C%%\u300D\u986F\u793A\u767E\u5206\u6BD4\u7B26\u865F", - "json.checker.array.length-between": "\u9577\u5EA6\u5728%1%\u548C%2%\u4E4B\u9593\u7684%0%", - "json.checker.item.duplicate": "\u91CD\u8907\u7684\u6E05\u55AE\u5167\u5BB9", - "json.checker.object.field.union-empty-members": "\u4E0D\u5141\u8A31\u7684\u5C6C\u6027", - "json.checker.property.deprecated": "\u5C6C\u6027 %0% \u5DF2\u88AB\u68C4\u7528", - "json.checker.property.missing": "\u7F3A\u5931\u5C6C\u6027 %0%", - "json.checker.property.unknown": "\u672A\u77E5\u5C6C\u6027 %0%", - "json.checker.string.hex-color": "\u4E00\u500B 6 \u4F4D\u7684\u5341\u516D\u9032\u4F4D\u6578\u5B57", - "json.checker.tag-entry.duplicate": "\u91CD\u8907\u7684\u503C", - "json.checker.value": "\u4E00\u500B\u503C", - "json.doc.advancement.display": "\u9032\u5EA6\u7684\u986F\u793A\u8A2D\u5B9A\u3002\u82E5\u5B58\u5728\uFF0C\u5247\u6B64\u9032\u5EA6\u6703\u5728\u9032\u5EA6\u756B\u9762\u4E2D\u53EF\u898B\u3002", - "json.node.array": "\u4E00\u500B\u9663\u5217", - "json.node.boolean": "\u4E00\u500B\u5E03\u6797\u503C", - "json.node.null": "null", - "json.node.number": "\u4E00\u500B\u6578\u5B57", - "json.node.object": "\u4E00\u500B\u7269\u4EF6", - "json.node.string": "\u4E00\u500B\u5B57\u4E32", - "key-not-following-convention": "\u7121\u6548\u7684\u9375%0%\uFF0C\u56E0\u70BA\u6C92\u6709\u9075\u5FAA%1%\u547D\u540D\u898F\u7BC4", - "linter-config-validator.name-convention.type": "\u671F\u671B\u4E00\u500B\u63CF\u8FF0\u540D\u5B57\u7684\u6B63\u898F\u8868\u793A\u5F0F\u5B57\u4E32", - "linter-config-validator.wrapper": "%0%\u3002 \u95B1\u8B80[\u6587\u4EF6]\uFF08%1\uFF09\u4EE5\u7372\u53D6\u66F4\u591A\u8CC7\u8A0A", - "linter.diagnostic-message-wrapper": "%0%\uFF08\u898F\u5247\uFF1A%1%\uFF09", - "linter.name-convention.illegal": "\u540D\u7A31 %0% \u8207\u7D44\u614B\u7684\u6B63\u898F\u8868\u793A\u5F0F %1% \u4E0D\u76F8\u7B26", - "linter.undeclared-symbol.message": "\u627E\u4E0D\u5230 %0% %1%", - long: "\u4E00\u500B\u9577\u6574\u6578", - "long.between": "\u4E00\u500B\u5728%0%\u548C%1%\u4E4B\u9593\u7684\u9577\u6574\u6578", - "mcdoc.binder.dispatcher-statement.duplicated-key": "\u91CD\u8907\u7684dispatcher\uFF1A%0%", - "mcdoc.binder.dispatcher-statement.duplicated-key.related": "%0%\u5DF2\u7D93\u5728\u9019\u88E1\u5B9A\u7FA9\u904E\u4E86", - "mcdoc.binder.duplicated-declaration": "\u91CD\u8907\u7684\u5BA3\u544A %0%", - "mcdoc.binder.duplicated-declaration.related": "%0% \u5DF2\u5728\u9019\u88E1\u5BA3\u544A\u904E\u4E86", - "mcdoc.binder.out-of-root": "\u6A94\u6848 %0% \u4E0D\u5728\u4EFB\u4F55 mcdoc \u5C08\u6848\u4E2D\u7684\u6839\u76EE\u9304\uFF1B\u8A9E\u610F\u6AA2\u67E5\u5C07\u88AB\u8DF3\u904E", - "mcdoc.binder.path.super-from-root": "\u4E0D\u53EF\u8A2A\u554F\u6839\u76EE\u9304\u7684\u7236\u7D1A\u76EE\u9304", - "mcdoc.binder.path.unknown-identifier": "\u6A19\u8B58\u7B26 %0% \u4E0D\u5B58\u5728\u65BC\u6A21\u7D44 %1%", - "mcdoc.binder.path.unknown-module": "\u6A21\u7D44 \uFF050% \u4E0D\u5B58\u5728", - "mcdoc.checker.entry.empty-mod-seg": "\u60A8\u4E0D\u80FD\u5C07\u300Cmod.mcdoc\u300D\u76F4\u63A5\u653E\u5728\u6839\u76EE\u9304\u4E0B", - "mcdoc.checker.inject-clause.unmatched-injection": "\u4E0D\u80FD\u7528 %1% \u6CE8\u78BC\u65BC %0%", - "mcdoc.checker.type-not-assignable": "\u985E\u578B %0% \u4E0D\u80FD\u5206\u914D\u7D66\u985E\u578B %1%", - "mcdoc.node.compound-definition": "\u4E00\u500B\u8907\u5408\u5B9A\u7FA9", - "mcdoc.node.enum-definition": "\u4E00\u500B\u5217\u8209\u5B9A\u7FA9", - "mcdoc.node.identifier": "\u4E00\u500B\u6A19\u8B58\u7B26", - "mcdoc.parser.compound-definition.field-type": "\u4E00\u500B\u6B04\u4F4D\u985E\u578B", - "mcdoc.parser.float.illegal": "\u9047\u5230\u4E86\u7121\u6548\u7684\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578", - "mcdoc.parser.identifier.illegal": "%0% \u4E0D\u9075\u5FAA\u683C\u5F0F %1%", - "mcdoc.parser.identifier.reserved-word": "%0% \u662F\u500B\u53CD\u8F49\u6587\u5B57\u4E14\u4E0D\u53EF\u88AB\u7528\u65BC\u6A19\u8B58\u7B26\u540D\u7A31", - "mcdoc.parser.index-body.dynamic-index-not-allowed": "\u52D5\u614B\u7D22\u5F15\u662F\u4E0D\u5141\u8A31\u7684", - "mcdoc.parser.inject-clause.definition-expected": "\u671F\u671B\u4E00\u500B\u5217\u8209\u6CE8\u78BC\u6216\u8907\u5408\u6CE8\u78BC", - "mcdoc.parser.keyword.separation": "\u4E00\u500B\u5206\u9694\u7B26", - "mcdoc.parser.resource-location.colon-expected": "\u8CC7\u6E90\u4F4D\u7F6E\u9810\u671F\u70BA\u5192\u865F (%0%)", - "mcdoc.parser.syntax.doc-comment-unexpected": "\u6B64\u8655\u4E0D\u5141\u8A31\u6587\u6A94\u8A3B\u89E3\uFF1B\u60A8\u53EF\u80FD\u60F3\u7528\u5169\u500B\u659C\u7DDA\u53D6\u4EE3\u4E09\u500B\u659C\u7DDA", - "mcdoc.runtime.checker.key-value-pair": "\u4E00\u500B\u9375\u503C\u5C0D", - "mcdoc.runtime.checker.range.collection": "\u96C6\u5408\u9577\u5EA6\u70BA %0%", - "mcdoc.runtime.checker.range.concat": "%0% \u548C %1%", - "mcdoc.runtime.checker.range.left-exclusive": "\u5927\u65BC %0%", - "mcdoc.runtime.checker.range.left-inclusive": "\u81F3\u5C11\u70BA %0%", - "mcdoc.runtime.checker.range.number": "\u61C9\u70BA\u6578\u503C %0%", - "mcdoc.runtime.checker.range.right-exclusive": "\u4F4E\u65BC %0%", - "mcdoc.runtime.checker.range.right-inclusive": "\u6700\u591A %0%", - "mcdoc.runtime.checker.range.string": "\u5B57\u4E32\u9577\u5EA6\u61C9\u70BA %0%", - "mcdoc.runtime.checker.some-missing-keys": "\u7F3A\u5C11 %0% \u4E2D\u7684\u81F3\u5C11\u4E00\u500B\u9375", - "mcdoc.runtime.checker.trailing": "\u767C\u73FE\u5C3E\u96A8\u8CC7\u6599", - "mcdoc.runtime.checker.value": "\u4E00\u500B\u503C", - "mcdoc.type.boolean": "\u4E00\u500B\u5E03\u6797\u503C", - "mcdoc.type.byte": "\u4E00\u500B\u5B57\u7BC0\u503C", - "mcdoc.type.byte_array": "\u4E00\u500B\u5B57\u7BC0\u9663\u5217", - "mcdoc.type.double": "\u4E00\u500B\u500D\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u503C", - "mcdoc.type.float": "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u503C", - "mcdoc.type.int": "\u4E00\u500B\u6574\u6578\u503C", - "mcdoc.type.int_array": "\u4E00\u500B\u6574\u6578\u9663\u5217", - "mcdoc.type.list": "\u4E00\u500B\u5217\u8868", - "mcdoc.type.long": "\u4E00\u500B\u9577\u6574\u6578\u503C", - "mcdoc.type.long_array": "\u4E00\u500B\u9577\u6574\u6578\u9663\u5217", - "mcdoc.type.short": "\u4E00\u500B\u77ED\u6574\u6578\u503C", - "mcdoc.type.string": "\u4E00\u500B\u5B57\u4E32\u503C", - "mcfunction.checker.command.data-modify-unapplicable-operation": "%0% \u64CD\u4F5C\u53EA\u80FD\u88AB\u7528\u65BC %1%\uFF1B\u76EE\u6A19\u8DEF\u5F91\u985E\u578B\u5247\u70BA %2%", - "mcfunction.completer.block.states.default-value": "\u9810\u8A2D\uFF1A %0%", - "mcfunction.parser.command-too-long": "\u6307\u4EE4\u9577\u5EA6 %0% \u7B46\u6700\u5927\u9577\u5EA6 %1% \u9577", - "mcfunction.parser.duplicate-components": "\u91CD\u8907\u7684\u7D44\u4EF6", - "mcfunction.parser.entity-selector.arguments.not-applicable": "%0% \u4E0D\u9069\u7528\u65BC\u6B64\u8655", - "mcfunction.parser.entity-selector.arguments.unknown": "\u672A\u77E5\u7684\u5BE6\u9AD4\u9078\u64C7\u5668\u5F15\u6578 %0%", - "mcfunction.parser.entity-selector.entities-disallowed": "\u6B64\u9078\u64C7\u5668\u5305\u542B\u975E\u73A9\u5BB6\u5BE6\u9AD4", - "mcfunction.parser.entity-selector.invalid": '\u7121\u6548\u7684\u76EE\u6A19\u9078\u64C7\u5668\uFF1A"%0%"', - "mcfunction.parser.entity-selector.multiple-disallowed": "\u6B64\u9078\u64C7\u5668\u5305\u542B\u591A\u500B\u5BE6\u9AD4", - "mcfunction.parser.entity-selector.player-name.too-long": "\u73A9\u5BB6\u540D\u7A31\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", - "mcfunction.parser.eoc-unexpected": "\u671F\u671B\u66F4\u591A\u5F15\u6578", - "mcfunction.parser.leading-slash": "\u4E00\u500B\u524D\u7F6E\u659C\u7DDA \u300C/\u300D", - "mcfunction.parser.leading-slash.unexpected": "\u4E0D\u80FD\u4EE5\u659C\u69D3\u300C/\u300D\u958B\u59CB\u6307\u4EE4", - "mcfunction.parser.macro.at-least-one": "\u81F3\u5C11\u4E00\u500B\u5DE8\u96C6\u53C3\u6578", - "mcfunction.parser.macro.disallowed": "\u5DE8\u96C6\u884C\u53EA\u652F\u63F4\u65BC 1.20.2 \u4E4B\u5F8C", - "mcfunction.parser.macro.illegal-key": '\u4E0D\u6B63\u78BA\u7684\u9375\u5B57\u7B26\uFF1A"%0%"', - "mcfunction.parser.macro.key": "\u4E00\u500B\u5DE8\u96C6\u9375", - "mcfunction.parser.no-permission": "\u9700\u8981\u6B0A\u9650\u7B49\u7D1A %0%\uFF0C\u9AD8\u65BC\u8A2D\u5B9A\u4E2D\u5B9A\u7FA9\u7684 %1%", - "mcfunction.parser.objective.too-long": "\u8A08\u5206\u677F\u76EE\u6A19\u540D\u7A31\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", - "mcfunction.parser.range.min>max": "\u6700\u5C0F\u503C %0% \u5927\u65BC\u6700\u5927\u503C %1%", - "mcfunction.parser.range.span-too-large": "\u7BC4\u570D\u5927\u5C0F %0% \u5927\u65BC\u6700\u5927\u503C %1%", - "mcfunction.parser.range.span-too-small": "\u7BC4\u570D\u5927\u5C0F %0% \u5C0F\u65BC\u6700\u5C0F\u503C %1%", - "mcfunction.parser.score_holder.fake-name.too-long": "\u5BE6\u9AD4\u5047\u540D\u9577\u5EA6\u4E0D\u80FD\u591A\u65BC %0% \u500B\u5B57\u5143", - "mcfunction.parser.sep": "\u4E00\u500B\u7A7A\u767D\u5B57\u5143\uFF08%0%\uFF09", - "mcfunction.parser.trailing": "\u9047\u5230\u5C3E\u96A8\u8CC7\u6599\uFF1A%0%", - "mcfunction.parser.unknown-parser": "\u5C1A\u672A\u652F\u63F4\u89E3\u6790\u5668 %0%", - "mcfunction.parser.uuid.invalid": "\u7121\u6548\u7684 UUID \u683C\u5F0F", - "mcfunction.parser.vector.local-disallowed": "\u5C40\u90E8\u5EA7\u6A19\u4E0D\u5141\u8A31\u5728\u6B64\u8655\u4F7F\u7528", - "mcfunction.parser.vector.mixed": "\u4E0D\u80FD\u6DF7\u7528\u5C40\u90E8\u5EA7\u6A19\u8207\u4E16\u754C\u5EA7\u6A19", - "mcfunction.signature-help.argument-parser-documentation": "[Minecraft Wiki\uFF1A `%0%` \u53C3\u6578\u985E\u578B](https://zh.minecraft.wiki/w/\u53C3\u6578\u985E\u578B#%0%)", - "mcfunction.signature-help.command-documentation": "[Minecraft \u7DAD\u57FA\uFF1A `%0%` \u6307\u4EE4](https://minecraft.fandom.com/zh/wiki/\u547D\u4EE4/%0%)", - "mismatching-regex-pattern": "\u503C\u4E0D\u7B26\u5408regex\uFF1A%0%", - "missing-key": "\u7F3A\u5931\u9375 %0%", - "nbt.checker.block-states.fake-boolean": "\u61C9\u7528\u5F15\u865F\u5305\u88F9\u5E03\u6797\u578B\u65B9\u584A\u72C0\u614B\u503C", - "nbt.checker.block-states.unexpected-value-type": "\u65B9\u584A\u72C0\u614B\u503C\u61C9\u70BA\u5B57\u4E32\u6216\u6574\u6578", - "nbt.checker.block-states.unknown-state": "\u4EE5\u4E0B\u65B9\u584A\u5177\u6709\u672A\u77E5\u7684\u65B9\u584A\u72C0\u614B %0%\uFF1A%1%", - "nbt.checker.boolean.out-of-range": "\u5E03\u6797\u503C\u61C9\u70BA %0% \u6216 %1%", - "nbt.checker.collection.length-between": "%0% \u7684\u9577\u5EA6\u5728 %1% \u548C %2% \u4E4B\u9593", - "nbt.checker.compound.field.union-empty-members": "\u4E0D\u5141\u8A31\u7684\u5C6C\u6027", - "nbt.checker.path.index-out-of-bound": "\u63D0\u4F9B\u7684\u7D22\u5F15 %0% \u8D8A\u754C\uFF0C\u56E0\u70BA\u96C6\u5408\u6700\u591A\u53EA\u80FD\u64C1\u6709 %1% \u500B\u5143\u7D20", - "nbt.checker.path.unexpected-filter": "\u8907\u5408\u6A19\u7C64\u904E\u6FFE\u5668\u53EA\u80FD\u7528\u65BC\u8907\u5408\u6A19\u7C64", - "nbt.checker.path.unexpected-index": "\u7D22\u5F15\u53EA\u80FD\u7528\u65BC\u9663\u5217\u6216\u4E32\u5217\u6A19\u7C64", - "nbt.checker.path.unexpected-key": "\u5B57\u4E32\u9375\u53EA\u80FD\u70BA\u8907\u5408\u6A19\u7C64\u6307\u5B9A", - "nbt.node": "\u4E00\u500B\u6A19\u7C64", - "nbt.node.byte": "\u4E00\u500B\u5B57\u5143\u7D44\u6A19\u7C64", - "nbt.node.byte_array": "\u4E00\u500B\u5B57\u5143\u7D44\u9663\u5217\u6A19\u7C64", - "nbt.node.compound": "\u4E00\u500B\u8907\u5408\u6A19\u7C64", - "nbt.node.double": "\u4E00\u500B\u500D\u7CBE\u5EA6\u6D6E\u9EDE\u578B\u6A19\u7C64", - "nbt.node.float": "\u4E00\u500B\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u578B\u6A19\u7C64", - "nbt.node.int": "\u4E00\u500B\u6574\u6578\u6A19\u7C64", - "nbt.node.int_array": "\u4E00\u500B\u6574\u6578\u9663\u5217\u6A19\u7C64", - "nbt.node.list": "\u4E00\u500B\u4E32\u5217\u6A19\u7C64", - "nbt.node.long": "\u4E00\u500B\u9577\u6574\u6578\u6A19\u7C64", - "nbt.node.long_array": "\u4E00\u500B\u9577\u6574\u6578\u9663\u5217\u6A19\u7C64", - "nbt.node.path.end": "\u8DEF\u5F91\u7D50\u5C3E", - "nbt.node.path.filter": "\u4E00\u500B\u8907\u5408\u6A19\u7C64\u904E\u6FFE\u5668", - "nbt.node.path.index": "\u4E00\u500B\u7D22\u5F15", - "nbt.node.path.key": "\u4E00\u500B\u9375", - "nbt.node.short": "\u4E00\u500B\u77ED\u6574\u6578\u6A19\u7C64", - "nbt.node.string": "\u4E00\u500B\u5B57\u4E32\u6A19\u7C64", - "nbt.parser.number.out-of-range": "\u9019\u770B\u8D77\u4F86\u50CF %0%\uFF0C\u4F46\u5BE6\u969B\u4E0A\u662F %1%\uFF0C\u56E0\u70BA\u6578\u503C\u8D85\u51FA\u4E86 [%2%, %3%]", - "not-matching-any-child": "\u7121\u6548\u5F15\u6578", - nothing: "\u7121", - number: "\u4E00\u500B\u6578\u5B57", - "number-range": "\u4E00\u500B\u6578\u5B57\u7BC4\u570D", - "number-range.missing-min-and-max": "\u671F\u671B\u4E00\u500B\u6700\u5C0F\u503C\u6216\u4E00\u500B\u6700\u5927\u503C", - "number.<=": "\u4E00\u500B\u5C0F\u65BC\u7B49\u65BC %0% \u7684\u6578\u5B57", - "number.>=": "\u4E00\u500B\u5927\u65BC\u7B49\u65BC %0% \u7684\u6578\u5B57", - "number.between": "\u4E00\u500B\u4F4D\u65BC %0% \u548C %1% \u4E4B\u9593\u7684\u6578\u5B57", - object: "\u4E00\u500B\u7269\u4EF6", - objective: "\u4E00\u500B\u8A08\u5206\u677F\u76EE\u6A19", - "objective-not-following-convention": "\u8A72\u8A08\u5206\u677F\u76EE\u6A19 %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", - "parser.float.illegal": "\u7121\u6548\u7684\u55AE\u7CBE\u5EA6\u6D6E\u9EDE\u6578\u4E0D\u9075\u5FAA %0%", - "parser.integer.illegal": "\u7121\u6548\u7684\u6574\u6578\u4E0D\u9075\u5FAA %0%", - "parser.list.trailing-sep": "\u5C3E\u96A8\u5206\u9694\u7B26", - "parser.list.value": "\u4E00\u500B\u503C", - "parser.record.key": "\u4E00\u500B\u9375", - "parser.record.trailing-end": "\u5C3E\u96A8\u5206\u9694\u7B26", - "parser.record.unexpected-char": "\u9810\u671F\u5916\u7684\u5B57\u5143 %0%", - "parser.record.value": "\u4E00\u500B\u503C", - "parser.resource-location.illegal": "\u7121\u6548\u5B57\u5143\uFF1A%0%", - "parser.resource-location.namespace-expected": "\u4E0D\u53EF\u5728\u6B64\u7701\u7565\u547D\u540D\u7A7A\u9593", - "parser.resource-location.tag-disallowed": "\u6B64\u8655\u4E0D\u5141\u8A31\u4F7F\u7528\u6A19\u7C64", - "parser.string.illegal-brigadier": "\u5728 %0% \u4E2D\u9047\u5230\u4E86\u975E [0-9A-Za-z_.+-] \u5B57\u5143", - "parser.string.illegal-escape": "\u9810\u671F\u5916\u7684\u8DF3\u812B\u5B57\u5143 %0%", - "parser.string.illegal-quote": "\u6B64\u8655\u53EA\u5141\u8A31\u4F7F\u7528 %0% \u5305\u88F9\u5B57\u4E32", - "parser.string.illegal-unicode-escape": "\u671F\u671B\u5341\u516D\u9032\u4F4D\u6578\u5B57", - "punc.period": "\u3002", - "punc.quote": "\u300C%0%\u300D", - quote: `\u4E00\u500B\u82F1\u6587\u5F15\u865F\uFF08\u300C'\u300D\u6216\u300C"\u300D\uFF09`, - quote_prefer_double: '\u6B64\u8655\u8ACB\u512A\u5148\u4F7F\u7528\u82F1\u6587\u96D9\u5F15\u865F\uFF08\u300C"\u300D\uFF09', - quote_prefer_single: "\u6B64\u8655\u8ACB\u512A\u5148\u4F7F\u7528\u82F1\u6587\u55AE\u5F15\u865F\uFF08\u300C'\u300D\uFF09", - "resource-location": "\u4E00\u500B\u8CC7\u6E90\u4F4D\u7F6E", - "score-holder": "\u4E00\u500B\u5206\u6578\u6301\u6709\u8005", - "scoreholder-not-following-convention": "\u7121\u6548\u7684\u5206\u6578\u6301\u6709\u8005 %0% \u4E0D\u9075\u5FAA %1% \u547D\u540D\u898F\u5247", - "server.new-version": "\u5DF2\u66F4\u65B0\u8CC7\u6599\u5305\u8A9E\u8A00\u4F3A\u670D\u5668\u5230\u65B0\u7248\u672C\uFF1A%0%", - "server.progress.fixing-workspace.begin": "\u4FEE\u5FA9\u7576\u524D\u5DE5\u4F5C\u5340\u4E2D\u6240\u6709\u53EF\u81EA\u52D5\u4FEE\u5FA9\u7684\u554F\u984C", - "server.progress.fixing-workspace.report": "\u6B63\u5728\u4FEE\u5FA9%0%", - "server.remove-cache-file": "DHP \u7684\u5FEB\u53D6\u6A94\u6848\u88AB\u79FB\u52D5\u5230\u4E86\u4E00\u500B\u7531 VSCode \u63D0\u4F9B\u7684\u5FEB\u53D6\u76EE\u9304\u3002\u60A8\u73FE\u5728\u53EF\u4EE5\u653E\u5FC3\u5730\u522A\u9664\u5DE5\u4F5C\u5340\u6839\u76EE\u9304\u4E0B\u7684\u300C.datapack\u300D\u6A94\u6848\u593E\u3002", - "server.show-release-notes": "\u986F\u793A\u66F4\u65B0\u65E5\u8A8C", - string: "\u4E00\u500B\u5B57\u4E32", - tag: "\u4E00\u500B\u6A19\u7C64", - "tag-not-following-convention": "\u8A72\u6A19\u7C64 %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", - team: "\u4E00\u500B\u968A\u4F0D", - "team-not-following-convention": "\u8A72\u968A\u4F0D %0% \u6C92\u6709\u8DDF\u96A8\u547D\u540D\u898F\u5247 %1%", - "time-unit": "\u4E00\u500B\u6642\u9593\u55AE\u4F4D", - "too-many-block-affected": "\u6307\u5B9A\u5340\u57DF\u5167\u7684\u65B9\u584A\u592A\u591A\uFF08\u6700\u5927\u503C\u70BA %0%\uFF0C\u6307\u5B9A\u70BA %1%\uFF09", - "too-many-chunk-affected": "\u6307\u5B9A\u5340\u57DF\u5167\u7684\u5340\u584A\u592A\u591A\uFF08\u6700\u5927\u503C\u70BA %0%\uFF0C\u6307\u5B9A\u503C\u70BA %1%\uFF09", - "unexpected-character": "\u9047\u5230\u4E86\u975E [a-z0-9/._-] \u5B57\u5143", - "unexpected-datapack-tag": "\u6B64\u8655\u4E0D\u5141\u8A31\u4F7F\u7528\u6A19\u7C64", - "unexpected-default-namespace": "\u61C9\u7576\u7701\u7565\u6B64\u8655\u7684\u9810\u8A2D\u547D\u540D\u7A7A\u9593", - "unexpected-local-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u5C40\u90E8\u5EA7\u6A19%0%", - "unexpected-nbt": "\u6B64\u8655\u4E0D\u61C9\u4F7F\u7528 NBT \u6A19\u7C64", - "unexpected-nbt-array-type": "\u7121\u6548\u7684\u9663\u5217\u985E\u578B%0%\u3002\u61C9\u70BA\u300CB\u300D\u3001\u300CI\u300D\u3001\u300CL\u300D\u4E2D\u7684\u4E00\u500B", - "unexpected-nbt-path-filter": "\u8907\u5408\u6A19\u7C64\u7BE9\u9078\u5668\u53EA\u80FD\u5C0D\u8907\u5408\u6A19\u7C64\u4F7F\u7528", - "unexpected-nbt-path-index": "\u7D22\u5F15\u53EA\u80FD\u5C0D\u4E32\u5217\u6216\u9663\u5217\u6A19\u7C64\u4F7F\u7528", - "unexpected-nbt-path-key": "\u9375\u53EA\u80FD\u5C0D\u8907\u5408\u6A19\u7C64\u4F7F\u7528", - "unexpected-nbt-path-sub": "\u7576\u524D\u7684\u6A19\u7C64\u4E26\u6C92\u6709\u66F4\u591A\u5B50\u9805\u76EE", - "unexpected-omitted-default-namespace": "\u6B64\u8655\u4E0D\u80FD\u7701\u7565\u9810\u8A2D\u547D\u540D\u7A7A\u9593", - "unexpected-relative-coordinate": "\u4E0D\u80FD\u4F7F\u7528\u76F8\u5C0D\u5EA7\u6A19%0%", - "unexpected-scoreboard-sub-slot": "\u53EA\u6709\u300Csidebar\u300D\u6709\u5B50\u6B04\u76EE", - "unknown-command": "\u672A\u77E5\u7684\u6307\u4EE4%0%", - "unknown-escape": "\u9810\u671F\u5916\u7684\u8DF3\u812B\u5B57\u5143 %0%", - "unknown-key": "\u672A\u77E5\u7684\u9375%0%", - "unquoted-string": "\u4E00\u500B\u672A\u88AB\u5F15\u865F\u5305\u88F9\u7684\u5B57\u4E32", - "unsorted-keys": "\u9375\u672A\u6392\u5E8F", - uuid: "\u4E00\u500B UUID", - vector: "\u4E00\u500B\u5411\u91CF" - }; - } -}); - -// node_modules/picomatch/lib/constants.js -var require_constants = __commonJS({ - "node_modules/picomatch/lib/constants.js"(exports2, module3) { - "use strict"; - var WIN_SLASH = "\\\\/"; - var WIN_NO_SLASH = `[^${WIN_SLASH}]`; - var DEFAULT_MAX_EXTGLOB_RECURSION = 0; - var DOT_LITERAL = "\\."; - var PLUS_LITERAL = "\\+"; - var QMARK_LITERAL = "\\?"; - var SLASH_LITERAL = "\\/"; - var ONE_CHAR = "(?=.)"; - var QMARK = "[^/]"; - var END_ANCHOR = `(?:${SLASH_LITERAL}|$)`; - var START_ANCHOR = `(?:^|${SLASH_LITERAL})`; - var DOTS_SLASH = `${DOT_LITERAL}{1,2}${END_ANCHOR}`; - var NO_DOT = `(?!${DOT_LITERAL})`; - var NO_DOTS = `(?!${START_ANCHOR}${DOTS_SLASH})`; - var NO_DOT_SLASH = `(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`; - var NO_DOTS_SLASH = `(?!${DOTS_SLASH})`; - var QMARK_NO_DOT = `[^.${SLASH_LITERAL}]`; - var STAR = `${QMARK}*?`; - var SEP = "/"; - var POSIX_CHARS = { - DOT_LITERAL, - PLUS_LITERAL, - QMARK_LITERAL, - SLASH_LITERAL, - ONE_CHAR, - QMARK, - END_ANCHOR, - DOTS_SLASH, - NO_DOT, - NO_DOTS, - NO_DOT_SLASH, - NO_DOTS_SLASH, - QMARK_NO_DOT, - STAR, - START_ANCHOR, - SEP - }; - var WINDOWS_CHARS = { - ...POSIX_CHARS, - SLASH_LITERAL: `[${WIN_SLASH}]`, - QMARK: WIN_NO_SLASH, - STAR: `${WIN_NO_SLASH}*?`, - DOTS_SLASH: `${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`, - NO_DOT: `(?!${DOT_LITERAL})`, - NO_DOTS: `(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, - NO_DOT_SLASH: `(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`, - NO_DOTS_SLASH: `(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`, - QMARK_NO_DOT: `[^.${WIN_SLASH}]`, - START_ANCHOR: `(?:^|[${WIN_SLASH}])`, - END_ANCHOR: `(?:[${WIN_SLASH}]|$)`, - SEP: "\\" - }; - var POSIX_REGEX_SOURCE = { - __proto__: null, - alnum: "a-zA-Z0-9", - alpha: "a-zA-Z", - ascii: "\\x00-\\x7F", - blank: " \\t", - cntrl: "\\x00-\\x1F\\x7F", - digit: "0-9", - graph: "\\x21-\\x7E", - lower: "a-z", - print: "\\x20-\\x7E ", - punct: "\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~", - space: " \\t\\r\\n\\v\\f", - upper: "A-Z", - word: "A-Za-z0-9_", - xdigit: "A-Fa-f0-9" - }; - module3.exports = { - DEFAULT_MAX_EXTGLOB_RECURSION, - MAX_LENGTH: 1024 * 64, - POSIX_REGEX_SOURCE, - // regular expressions - REGEX_BACKSLASH: /\\(?![*+?^${}(|)[\]])/g, - REGEX_NON_SPECIAL_CHARS: /^[^@![\].,$*+?^{}()|\\/]+/, - REGEX_SPECIAL_CHARS: /[-*+?.^${}(|)[\]]/, - REGEX_SPECIAL_CHARS_BACKREF: /(\\?)((\W)(\3*))/g, - REGEX_SPECIAL_CHARS_GLOBAL: /([-*+?.^${}(|)[\]])/g, - REGEX_REMOVE_BACKSLASH: /(?:\[.*?[^\\]\]|\\(?=.))/g, - // Replace globs with equivalent patterns to reduce parsing time. - REPLACEMENTS: { - __proto__: null, - "***": "*", - "**/**": "**", - "**/**/**": "**" - }, - // Digits - CHAR_0: 48, - /* 0 */ - CHAR_9: 57, - /* 9 */ - // Alphabet chars. - CHAR_UPPERCASE_A: 65, - /* A */ - CHAR_LOWERCASE_A: 97, - /* a */ - CHAR_UPPERCASE_Z: 90, - /* Z */ - CHAR_LOWERCASE_Z: 122, - /* z */ - CHAR_LEFT_PARENTHESES: 40, - /* ( */ - CHAR_RIGHT_PARENTHESES: 41, - /* ) */ - CHAR_ASTERISK: 42, - /* * */ - // Non-alphabetic chars. - CHAR_AMPERSAND: 38, - /* & */ - CHAR_AT: 64, - /* @ */ - CHAR_BACKWARD_SLASH: 92, - /* \ */ - CHAR_CARRIAGE_RETURN: 13, - /* \r */ - CHAR_CIRCUMFLEX_ACCENT: 94, - /* ^ */ - CHAR_COLON: 58, - /* : */ - CHAR_COMMA: 44, - /* , */ - CHAR_DOT: 46, - /* . */ - CHAR_DOUBLE_QUOTE: 34, - /* " */ - CHAR_EQUAL: 61, - /* = */ - CHAR_EXCLAMATION_MARK: 33, - /* ! */ - CHAR_FORM_FEED: 12, - /* \f */ - CHAR_FORWARD_SLASH: 47, - /* / */ - CHAR_GRAVE_ACCENT: 96, - /* ` */ - CHAR_HASH: 35, - /* # */ - CHAR_HYPHEN_MINUS: 45, - /* - */ - CHAR_LEFT_ANGLE_BRACKET: 60, - /* < */ - CHAR_LEFT_CURLY_BRACE: 123, - /* { */ - CHAR_LEFT_SQUARE_BRACKET: 91, - /* [ */ - CHAR_LINE_FEED: 10, - /* \n */ - CHAR_NO_BREAK_SPACE: 160, - /* \u00A0 */ - CHAR_PERCENT: 37, - /* % */ - CHAR_PLUS: 43, - /* + */ - CHAR_QUESTION_MARK: 63, - /* ? */ - CHAR_RIGHT_ANGLE_BRACKET: 62, - /* > */ - CHAR_RIGHT_CURLY_BRACE: 125, - /* } */ - CHAR_RIGHT_SQUARE_BRACKET: 93, - /* ] */ - CHAR_SEMICOLON: 59, - /* ; */ - CHAR_SINGLE_QUOTE: 39, - /* ' */ - CHAR_SPACE: 32, - /* */ - CHAR_TAB: 9, - /* \t */ - CHAR_UNDERSCORE: 95, - /* _ */ - CHAR_VERTICAL_LINE: 124, - /* | */ - CHAR_ZERO_WIDTH_NOBREAK_SPACE: 65279, - /* \uFEFF */ - /** - * Create EXTGLOB_CHARS - */ - extglobChars(chars) { - return { - "!": { type: "negate", open: "(?:(?!(?:", close: `))${chars.STAR})` }, - "?": { type: "qmark", open: "(?:", close: ")?" }, - "+": { type: "plus", open: "(?:", close: ")+" }, - "*": { type: "star", open: "(?:", close: ")*" }, - "@": { type: "at", open: "(?:", close: ")" } - }; - }, - /** - * Create GLOB_CHARS - */ - globChars(win32) { - return win32 === true ? WINDOWS_CHARS : POSIX_CHARS; - } - }; - } -}); - -// node_modules/picomatch/lib/utils.js -var require_utils2 = __commonJS({ - "node_modules/picomatch/lib/utils.js"(exports2) { - "use strict"; - var { - REGEX_BACKSLASH, - REGEX_REMOVE_BACKSLASH, - REGEX_SPECIAL_CHARS, - REGEX_SPECIAL_CHARS_GLOBAL - } = require_constants(); - exports2.isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val); - exports2.hasRegexChars = (str) => REGEX_SPECIAL_CHARS.test(str); - exports2.isRegexChar = (str) => str.length === 1 && exports2.hasRegexChars(str); - exports2.escapeRegex = (str) => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, "\\$1"); - exports2.toPosixSlashes = (str) => str.replace(REGEX_BACKSLASH, "/"); - exports2.isWindows = () => { - if (typeof navigator !== "undefined" && navigator.platform) { - const platform = navigator.platform.toLowerCase(); - return platform === "win32" || platform === "windows"; - } - if (typeof process !== "undefined" && process.platform) { - return process.platform === "win32"; - } - return false; - }; - exports2.removeBackslashes = (str) => { - return str.replace(REGEX_REMOVE_BACKSLASH, (match) => { - return match === "\\" ? "" : match; - }); - }; - exports2.escapeLast = (input, char, lastIdx) => { - const idx = input.lastIndexOf(char, lastIdx); - if (idx === -1) return input; - if (input[idx - 1] === "\\") return exports2.escapeLast(input, char, idx - 1); - return `${input.slice(0, idx)}\\${input.slice(idx)}`; - }; - exports2.removePrefix = (input, state = {}) => { - let output = input; - if (output.startsWith("./")) { - output = output.slice(2); - state.prefix = "./"; - } - return output; - }; - exports2.wrapOutput = (input, state = {}, options2 = {}) => { - const prepend = options2.contains ? "" : "^"; - const append = options2.contains ? "" : "$"; - let output = `${prepend}(?:${input})${append}`; - if (state.negated === true) { - output = `(?:^(?!${output}).*$)`; - } - return output; - }; - exports2.basename = (path6, { windows } = {}) => { - const segs = path6.split(windows ? /[\\/]/ : "/"); - const last = segs[segs.length - 1]; - if (last === "") { - return segs[segs.length - 2]; - } - return last; - }; - } -}); - -// node_modules/picomatch/lib/scan.js -var require_scan = __commonJS({ - "node_modules/picomatch/lib/scan.js"(exports2, module3) { - "use strict"; - var utils = require_utils2(); - var { - CHAR_ASTERISK, - /* * */ - CHAR_AT, - /* @ */ - CHAR_BACKWARD_SLASH, - /* \ */ - CHAR_COMMA, - /* , */ - CHAR_DOT, - /* . */ - CHAR_EXCLAMATION_MARK, - /* ! */ - CHAR_FORWARD_SLASH, - /* / */ - CHAR_LEFT_CURLY_BRACE, - /* { */ - CHAR_LEFT_PARENTHESES, - /* ( */ - CHAR_LEFT_SQUARE_BRACKET, - /* [ */ - CHAR_PLUS, - /* + */ - CHAR_QUESTION_MARK, - /* ? */ - CHAR_RIGHT_CURLY_BRACE, - /* } */ - CHAR_RIGHT_PARENTHESES, - /* ) */ - CHAR_RIGHT_SQUARE_BRACKET - /* ] */ - } = require_constants(); - var isPathSeparator = (code) => { - return code === CHAR_FORWARD_SLASH || code === CHAR_BACKWARD_SLASH; - }; - var depth = (token) => { - if (token.isPrefix !== true) { - token.depth = token.isGlobstar ? Infinity : 1; - } - }; - var scan = (input, options2) => { - const opts = options2 || {}; - const length = input.length - 1; - const scanToEnd = opts.parts === true || opts.scanToEnd === true; - const slashes = []; - const tokens = []; - const parts = []; - let str = input; - let index4 = -1; - let start = 0; - let lastIndex = 0; - let isBrace = false; - let isBracket = false; - let isGlob = false; - let isExtglob = false; - let isGlobstar = false; - let braceEscaped = false; - let backslashes = false; - let negated = false; - let negatedExtglob = false; - let finished = false; - let braces = 0; - let prev; - let code; - let token = { value: "", depth: 0, isGlob: false }; - const eos = () => index4 >= length; - const peek = () => str.charCodeAt(index4 + 1); - const advance = () => { - prev = code; - return str.charCodeAt(++index4); - }; - while (index4 < length) { - code = advance(); - let next; - if (code === CHAR_BACKWARD_SLASH) { - backslashes = token.backslashes = true; - code = advance(); - if (code === CHAR_LEFT_CURLY_BRACE) { - braceEscaped = true; - } - continue; - } - if (braceEscaped === true || code === CHAR_LEFT_CURLY_BRACE) { - braces++; - while (eos() !== true && (code = advance())) { - if (code === CHAR_BACKWARD_SLASH) { - backslashes = token.backslashes = true; - advance(); - continue; - } - if (code === CHAR_LEFT_CURLY_BRACE) { - braces++; - continue; - } - if (braceEscaped !== true && code === CHAR_DOT && (code = advance()) === CHAR_DOT) { - isBrace = token.isBrace = true; - isGlob = token.isGlob = true; - finished = true; - if (scanToEnd === true) { - continue; - } - break; - } - if (braceEscaped !== true && code === CHAR_COMMA) { - isBrace = token.isBrace = true; - isGlob = token.isGlob = true; - finished = true; - if (scanToEnd === true) { - continue; - } - break; - } - if (code === CHAR_RIGHT_CURLY_BRACE) { - braces--; - if (braces === 0) { - braceEscaped = false; - isBrace = token.isBrace = true; - finished = true; - break; - } - } - } - if (scanToEnd === true) { - continue; - } - break; - } - if (code === CHAR_FORWARD_SLASH) { - slashes.push(index4); - tokens.push(token); - token = { value: "", depth: 0, isGlob: false }; - if (finished === true) continue; - if (prev === CHAR_DOT && index4 === start + 1) { - start += 2; - continue; - } - lastIndex = index4 + 1; - continue; - } - if (opts.noext !== true) { - const isExtglobChar = code === CHAR_PLUS || code === CHAR_AT || code === CHAR_ASTERISK || code === CHAR_QUESTION_MARK || code === CHAR_EXCLAMATION_MARK; - if (isExtglobChar === true && peek() === CHAR_LEFT_PARENTHESES) { - isGlob = token.isGlob = true; - isExtglob = token.isExtglob = true; - finished = true; - if (code === CHAR_EXCLAMATION_MARK && index4 === start) { - negatedExtglob = true; - } - if (scanToEnd === true) { - while (eos() !== true && (code = advance())) { - if (code === CHAR_BACKWARD_SLASH) { - backslashes = token.backslashes = true; - code = advance(); - continue; - } - if (code === CHAR_RIGHT_PARENTHESES) { - isGlob = token.isGlob = true; - finished = true; - break; - } - } - continue; - } - break; - } - } - if (code === CHAR_ASTERISK) { - if (prev === CHAR_ASTERISK) isGlobstar = token.isGlobstar = true; - isGlob = token.isGlob = true; - finished = true; - if (scanToEnd === true) { - continue; - } - break; - } - if (code === CHAR_QUESTION_MARK) { - isGlob = token.isGlob = true; - finished = true; - if (scanToEnd === true) { - continue; - } - break; - } - if (code === CHAR_LEFT_SQUARE_BRACKET) { - while (eos() !== true && (next = advance())) { - if (next === CHAR_BACKWARD_SLASH) { - backslashes = token.backslashes = true; - advance(); - continue; - } - if (next === CHAR_RIGHT_SQUARE_BRACKET) { - isBracket = token.isBracket = true; - isGlob = token.isGlob = true; - finished = true; - break; - } - } - if (scanToEnd === true) { - continue; - } - break; - } - if (opts.nonegate !== true && code === CHAR_EXCLAMATION_MARK && index4 === start) { - negated = token.negated = true; - start++; - continue; - } - if (opts.noparen !== true && code === CHAR_LEFT_PARENTHESES) { - isGlob = token.isGlob = true; - if (scanToEnd === true) { - while (eos() !== true && (code = advance())) { - if (code === CHAR_LEFT_PARENTHESES) { - backslashes = token.backslashes = true; - code = advance(); - continue; - } - if (code === CHAR_RIGHT_PARENTHESES) { - finished = true; - break; - } - } - continue; - } - break; - } - if (isGlob === true) { - finished = true; - if (scanToEnd === true) { - continue; - } - break; - } - } - if (opts.noext === true) { - isExtglob = false; - isGlob = false; - } - let base = str; - let prefix = ""; - let glob = ""; - if (start > 0) { - prefix = str.slice(0, start); - str = str.slice(start); - lastIndex -= start; - } - if (base && isGlob === true && lastIndex > 0) { - base = str.slice(0, lastIndex); - glob = str.slice(lastIndex); - } else if (isGlob === true) { - base = ""; - glob = str; - } else { - base = str; - } - if (base && base !== "" && base !== "/" && base !== str) { - if (isPathSeparator(base.charCodeAt(base.length - 1))) { - base = base.slice(0, -1); - } - } - if (opts.unescape === true) { - if (glob) glob = utils.removeBackslashes(glob); - if (base && backslashes === true) { - base = utils.removeBackslashes(base); - } - } - const state = { - prefix, - input, - start, - base, - glob, - isBrace, - isBracket, - isGlob, - isExtglob, - isGlobstar, - negated, - negatedExtglob - }; - if (opts.tokens === true) { - state.maxDepth = 0; - if (!isPathSeparator(code)) { - tokens.push(token); - } - state.tokens = tokens; - } - if (opts.parts === true || opts.tokens === true) { - let prevIndex; - for (let idx = 0; idx < slashes.length; idx++) { - const n = prevIndex ? prevIndex + 1 : start; - const i = slashes[idx]; - const value = input.slice(n, i); - if (opts.tokens) { - if (idx === 0 && start !== 0) { - tokens[idx].isPrefix = true; - tokens[idx].value = prefix; - } else { - tokens[idx].value = value; - } - depth(tokens[idx]); - state.maxDepth += tokens[idx].depth; - } - if (idx !== 0 || value !== "") { - parts.push(value); - } - prevIndex = i; - } - if (prevIndex && prevIndex + 1 < input.length) { - const value = input.slice(prevIndex + 1); - parts.push(value); - if (opts.tokens) { - tokens[tokens.length - 1].value = value; - depth(tokens[tokens.length - 1]); - state.maxDepth += tokens[tokens.length - 1].depth; - } - } - state.slashes = slashes; - state.parts = parts; - } - return state; - }; - module3.exports = scan; - } -}); - -// node_modules/picomatch/lib/parse.js -var require_parse = __commonJS({ - "node_modules/picomatch/lib/parse.js"(exports2, module3) { - "use strict"; - var constants = require_constants(); - var utils = require_utils2(); - var { - MAX_LENGTH, - POSIX_REGEX_SOURCE, - REGEX_NON_SPECIAL_CHARS, - REGEX_SPECIAL_CHARS_BACKREF, - REPLACEMENTS - } = constants; - var expandRange = (args, options2) => { - if (typeof options2.expandRange === "function") { - return options2.expandRange(...args, options2); - } - args.sort(); - const value = `[${args.join("-")}]`; - try { - new RegExp(value); - } catch (ex) { - return args.map((v) => utils.escapeRegex(v)).join(".."); - } - return value; - }; - var syntaxError = (type2, char) => { - return `Missing ${type2}: "${char}" - use "\\\\${char}" to match literal characters`; - }; - var splitTopLevel = (input) => { - const parts = []; - let bracket = 0; - let paren = 0; - let quote2 = 0; - let value = ""; - let escaped = false; - for (const ch of input) { - if (escaped === true) { - value += ch; - escaped = false; - continue; - } - if (ch === "\\") { - value += ch; - escaped = true; - continue; - } - if (ch === '"') { - quote2 = quote2 === 1 ? 0 : 1; - value += ch; - continue; - } - if (quote2 === 0) { - if (ch === "[") { - bracket++; - } else if (ch === "]" && bracket > 0) { - bracket--; - } else if (bracket === 0) { - if (ch === "(") { - paren++; - } else if (ch === ")" && paren > 0) { - paren--; - } else if (ch === "|" && paren === 0) { - parts.push(value); - value = ""; - continue; - } - } - } - value += ch; - } - parts.push(value); - return parts; - }; - var isPlainBranch = (branch) => { - let escaped = false; - for (const ch of branch) { - if (escaped === true) { - escaped = false; - continue; - } - if (ch === "\\") { - escaped = true; - continue; - } - if (/[?*+@!()[\]{}]/.test(ch)) { - return false; - } - } - return true; - }; - var normalizeSimpleBranch = (branch) => { - let value = branch.trim(); - let changed = true; - while (changed === true) { - changed = false; - if (/^@\([^\\()[\]{}|]+\)$/.test(value)) { - value = value.slice(2, -1); - changed = true; - } - } - if (!isPlainBranch(value)) { - return; - } - return value.replace(/\\(.)/g, "$1"); - }; - var hasRepeatedCharPrefixOverlap = (branches) => { - const values = branches.map(normalizeSimpleBranch).filter(Boolean); - for (let i = 0; i < values.length; i++) { - for (let j = i + 1; j < values.length; j++) { - const a = values[i]; - const b = values[j]; - const char = a[0]; - if (!char || a !== char.repeat(a.length) || b !== char.repeat(b.length)) { - continue; - } - if (a === b || a.startsWith(b) || b.startsWith(a)) { - return true; - } - } - } - return false; - }; - var parseRepeatedExtglob = (pattern, requireEnd = true) => { - if (pattern[0] !== "+" && pattern[0] !== "*" || pattern[1] !== "(") { - return; - } - let bracket = 0; - let paren = 0; - let quote2 = 0; - let escaped = false; - for (let i = 1; i < pattern.length; i++) { - const ch = pattern[i]; - if (escaped === true) { - escaped = false; - continue; - } - if (ch === "\\") { - escaped = true; - continue; - } - if (ch === '"') { - quote2 = quote2 === 1 ? 0 : 1; - continue; - } - if (quote2 === 1) { - continue; - } - if (ch === "[") { - bracket++; - continue; - } - if (ch === "]" && bracket > 0) { - bracket--; - continue; - } - if (bracket > 0) { - continue; - } - if (ch === "(") { - paren++; - continue; - } - if (ch === ")") { - paren--; - if (paren === 0) { - if (requireEnd === true && i !== pattern.length - 1) { - return; - } - return { - type: pattern[0], - body: pattern.slice(2, i), - end: i - }; - } - } - } - }; - var getStarExtglobSequenceOutput = (pattern) => { - let index4 = 0; - const chars = []; - while (index4 < pattern.length) { - const match = parseRepeatedExtglob(pattern.slice(index4), false); - if (!match || match.type !== "*") { - return; - } - const branches = splitTopLevel(match.body).map((branch2) => branch2.trim()); - if (branches.length !== 1) { - return; - } - const branch = normalizeSimpleBranch(branches[0]); - if (!branch || branch.length !== 1) { - return; - } - chars.push(branch); - index4 += match.end + 1; - } - if (chars.length < 1) { - return; - } - const source = chars.length === 1 ? utils.escapeRegex(chars[0]) : `[${chars.map((ch) => utils.escapeRegex(ch)).join("")}]`; - return `${source}*`; - }; - var repeatedExtglobRecursion = (pattern) => { - let depth = 0; - let value = pattern.trim(); - let match = parseRepeatedExtglob(value); - while (match) { - depth++; - value = match.body.trim(); - match = parseRepeatedExtglob(value); - } - return depth; - }; - var analyzeRepeatedExtglob = (body, options2) => { - if (options2.maxExtglobRecursion === false) { - return { risky: false }; - } - const max2 = typeof options2.maxExtglobRecursion === "number" ? options2.maxExtglobRecursion : constants.DEFAULT_MAX_EXTGLOB_RECURSION; - const branches = splitTopLevel(body).map((branch) => branch.trim()); - if (branches.length > 1) { - if (branches.some((branch) => branch === "") || branches.some((branch) => /^[*?]+$/.test(branch)) || hasRepeatedCharPrefixOverlap(branches)) { - return { risky: true }; - } - } - for (const branch of branches) { - const safeOutput = getStarExtglobSequenceOutput(branch); - if (safeOutput) { - return { risky: true, safeOutput }; - } - if (repeatedExtglobRecursion(branch) > max2) { - return { risky: true }; - } - } - return { risky: false }; - }; - var parse = (input, options2) => { - if (typeof input !== "string") { - throw new TypeError("Expected a string"); - } - input = REPLACEMENTS[input] || input; - const opts = { ...options2 }; - const max2 = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; - let len = input.length; - if (len > max2) { - throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max2}`); - } - const bos = { type: "bos", value: "", output: opts.prepend || "" }; - const tokens = [bos]; - const capture = opts.capture ? "" : "?:"; - const PLATFORM_CHARS = constants.globChars(opts.windows); - const EXTGLOB_CHARS = constants.extglobChars(PLATFORM_CHARS); - const { - DOT_LITERAL, - PLUS_LITERAL, - SLASH_LITERAL, - ONE_CHAR, - DOTS_SLASH, - NO_DOT, - NO_DOT_SLASH, - NO_DOTS_SLASH, - QMARK, - QMARK_NO_DOT, - STAR, - START_ANCHOR - } = PLATFORM_CHARS; - const globstar = (opts2) => { - return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; - }; - const nodot = opts.dot ? "" : NO_DOT; - const qmarkNoDot = opts.dot ? QMARK : QMARK_NO_DOT; - let star = opts.bash === true ? globstar(opts) : STAR; - if (opts.capture) { - star = `(${star})`; - } - if (typeof opts.noext === "boolean") { - opts.noextglob = opts.noext; - } - const state = { - input, - index: -1, - start: 0, - dot: opts.dot === true, - consumed: "", - output: "", - prefix: "", - backtrack: false, - negated: false, - brackets: 0, - braces: 0, - parens: 0, - quotes: 0, - globstar: false, - tokens - }; - input = utils.removePrefix(input, state); - len = input.length; - const extglobs = []; - const braces = []; - const stack = []; - let prev = bos; - let value; - const eos = () => state.index === len - 1; - const peek = state.peek = (n = 1) => input[state.index + n]; - const advance = state.advance = () => input[++state.index] || ""; - const remaining = () => input.slice(state.index + 1); - const consume = (value2 = "", num = 0) => { - state.consumed += value2; - state.index += num; - }; - const append = (token) => { - state.output += token.output != null ? token.output : token.value; - consume(token.value); - }; - const negate = () => { - let count = 1; - while (peek() === "!" && (peek(2) !== "(" || peek(3) === "?")) { - advance(); - state.start++; - count++; - } - if (count % 2 === 0) { - return false; - } - state.negated = true; - state.start++; - return true; - }; - const increment = (type2) => { - state[type2]++; - stack.push(type2); - }; - const decrement = (type2) => { - state[type2]--; - stack.pop(); - }; - const push = (tok) => { - if (prev.type === "globstar") { - const isBrace = state.braces > 0 && (tok.type === "comma" || tok.type === "brace"); - const isExtglob = tok.extglob === true || extglobs.length && (tok.type === "pipe" || tok.type === "paren"); - if (tok.type !== "slash" && tok.type !== "paren" && !isBrace && !isExtglob) { - state.output = state.output.slice(0, -prev.output.length); - prev.type = "star"; - prev.value = "*"; - prev.output = star; - state.output += prev.output; - } - } - if (extglobs.length && tok.type !== "paren") { - extglobs[extglobs.length - 1].inner += tok.value; - } - if (tok.value || tok.output) append(tok); - if (prev && prev.type === "text" && tok.type === "text") { - prev.output = (prev.output || prev.value) + tok.value; - prev.value += tok.value; - return; - } - tok.prev = prev; - tokens.push(tok); - prev = tok; - }; - const extglobOpen = (type2, value2) => { - const token = { ...EXTGLOB_CHARS[value2], conditions: 1, inner: "" }; - token.prev = prev; - token.parens = state.parens; - token.output = state.output; - token.startIndex = state.index; - token.tokensIndex = tokens.length; - const output = (opts.capture ? "(" : "") + token.open; - increment("parens"); - push({ type: type2, value: value2, output: state.output ? "" : ONE_CHAR }); - push({ type: "paren", extglob: true, value: advance(), output }); - extglobs.push(token); - }; - const extglobClose = (token) => { - const literal9 = input.slice(token.startIndex, state.index + 1); - const body = input.slice(token.startIndex + 2, state.index); - const analysis = analyzeRepeatedExtglob(body, opts); - if ((token.type === "plus" || token.type === "star") && analysis.risky) { - const safeOutput = analysis.safeOutput ? (token.output ? "" : ONE_CHAR) + (opts.capture ? `(${analysis.safeOutput})` : analysis.safeOutput) : void 0; - const open = tokens[token.tokensIndex]; - open.type = "text"; - open.value = literal9; - open.output = safeOutput || utils.escapeRegex(literal9); - for (let i = token.tokensIndex + 1; i < tokens.length; i++) { - tokens[i].value = ""; - tokens[i].output = ""; - delete tokens[i].suffix; - } - state.output = token.output + open.output; - state.backtrack = true; - push({ type: "paren", extglob: true, value, output: "" }); - decrement("parens"); - return; - } - let output = token.close + (opts.capture ? ")" : ""); - let rest; - if (token.type === "negate") { - let extglobStar = star; - if (token.inner && token.inner.length > 1 && token.inner.includes("/")) { - extglobStar = globstar(opts); - } - if (extglobStar !== star || eos() || /^\)+$/.test(remaining())) { - output = token.close = `)$))${extglobStar}`; - } - if (token.inner.includes("*") && (rest = remaining()) && /^\.[^\\/.]+$/.test(rest)) { - const expression = parse(rest, { ...options2, fastpaths: false }).output; - output = token.close = `)${expression})${extglobStar})`; - } - if (token.prev.type === "bos") { - state.negatedExtglob = true; - } - } - push({ type: "paren", extglob: true, value, output }); - decrement("parens"); - }; - if (opts.fastpaths !== false && !/(^[*!]|[/()[\]{}"])/.test(input)) { - let backslashes = false; - let output = input.replace(REGEX_SPECIAL_CHARS_BACKREF, (m, esc, chars, first, rest, index4) => { - if (first === "\\") { - backslashes = true; - return m; - } - if (first === "?") { - if (esc) { - return esc + first + (rest ? QMARK.repeat(rest.length) : ""); - } - if (index4 === 0) { - return qmarkNoDot + (rest ? QMARK.repeat(rest.length) : ""); - } - return QMARK.repeat(chars.length); - } - if (first === ".") { - return DOT_LITERAL.repeat(chars.length); - } - if (first === "*") { - if (esc) { - return esc + first + (rest ? star : ""); - } - return star; - } - return esc ? m : `\\${m}`; - }); - if (backslashes === true) { - if (opts.unescape === true) { - output = output.replace(/\\/g, ""); - } else { - output = output.replace(/\\+/g, (m) => { - return m.length % 2 === 0 ? "\\\\" : m ? "\\" : ""; - }); - } - } - if (output === input && opts.contains === true) { - state.output = input; - return state; - } - state.output = utils.wrapOutput(output, state, options2); - return state; - } - while (!eos()) { - value = advance(); - if (value === "\0") { - continue; - } - if (value === "\\") { - const next = peek(); - if (next === "/" && opts.bash !== true) { - continue; - } - if (next === "." || next === ";") { - continue; - } - if (!next) { - value += "\\"; - push({ type: "text", value }); - continue; - } - const match = /^\\+/.exec(remaining()); - let slashes = 0; - if (match && match[0].length > 2) { - slashes = match[0].length; - state.index += slashes; - if (slashes % 2 !== 0) { - value += "\\"; - } - } - if (opts.unescape === true) { - value = advance(); - } else { - value += advance(); - } - if (state.brackets === 0) { - push({ type: "text", value }); - continue; - } - } - if (state.brackets > 0 && (value !== "]" || prev.value === "[" || prev.value === "[^")) { - if (opts.posix !== false && value === ":") { - const inner = prev.value.slice(1); - if (inner.includes("[")) { - prev.posix = true; - if (inner.includes(":")) { - const idx = prev.value.lastIndexOf("["); - const pre = prev.value.slice(0, idx); - const rest2 = prev.value.slice(idx + 2); - const posix = POSIX_REGEX_SOURCE[rest2]; - if (posix) { - prev.value = pre + posix; - state.backtrack = true; - advance(); - if (!bos.output && tokens.indexOf(prev) === 1) { - bos.output = ONE_CHAR; - } - continue; - } - } - } - } - if (value === "[" && peek() !== ":" || value === "-" && peek() === "]") { - value = `\\${value}`; - } - if (value === "]" && (prev.value === "[" || prev.value === "[^")) { - value = `\\${value}`; - } - if (opts.posix === true && value === "!" && prev.value === "[") { - value = "^"; - } - prev.value += value; - append({ value }); - continue; - } - if (state.quotes === 1 && value !== '"') { - value = utils.escapeRegex(value); - prev.value += value; - append({ value }); - continue; - } - if (value === '"') { - state.quotes = state.quotes === 1 ? 0 : 1; - if (opts.keepQuotes === true) { - push({ type: "text", value }); - } - continue; - } - if (value === "(") { - increment("parens"); - push({ type: "paren", value }); - continue; - } - if (value === ")") { - if (state.parens === 0 && opts.strictBrackets === true) { - throw new SyntaxError(syntaxError("opening", "(")); - } - const extglob = extglobs[extglobs.length - 1]; - if (extglob && state.parens === extglob.parens + 1) { - extglobClose(extglobs.pop()); - continue; - } - push({ type: "paren", value, output: state.parens ? ")" : "\\)" }); - decrement("parens"); - continue; - } - if (value === "[") { - if (opts.nobracket === true || !remaining().includes("]")) { - if (opts.nobracket !== true && opts.strictBrackets === true) { - throw new SyntaxError(syntaxError("closing", "]")); - } - value = `\\${value}`; - } else { - increment("brackets"); - } - push({ type: "bracket", value }); - continue; - } - if (value === "]") { - if (opts.nobracket === true || prev && prev.type === "bracket" && prev.value.length === 1) { - push({ type: "text", value, output: `\\${value}` }); - continue; - } - if (state.brackets === 0) { - if (opts.strictBrackets === true) { - throw new SyntaxError(syntaxError("opening", "[")); - } - push({ type: "text", value, output: `\\${value}` }); - continue; - } - decrement("brackets"); - const prevValue = prev.value.slice(1); - if (prev.posix !== true && prevValue[0] === "^" && !prevValue.includes("/")) { - value = `/${value}`; - } - prev.value += value; - append({ value }); - if (opts.literalBrackets === false || utils.hasRegexChars(prevValue)) { - continue; - } - const escaped = utils.escapeRegex(prev.value); - state.output = state.output.slice(0, -prev.value.length); - if (opts.literalBrackets === true) { - state.output += escaped; - prev.value = escaped; - continue; - } - prev.value = `(${capture}${escaped}|${prev.value})`; - state.output += prev.value; - continue; - } - if (value === "{" && opts.nobrace !== true) { - increment("braces"); - const open = { - type: "brace", - value, - output: "(", - outputIndex: state.output.length, - tokensIndex: state.tokens.length - }; - braces.push(open); - push(open); - continue; - } - if (value === "}") { - const brace = braces[braces.length - 1]; - if (opts.nobrace === true || !brace) { - push({ type: "text", value, output: value }); - continue; - } - let output = ")"; - if (brace.dots === true) { - const arr = tokens.slice(); - const range3 = []; - for (let i = arr.length - 1; i >= 0; i--) { - tokens.pop(); - if (arr[i].type === "brace") { - break; - } - if (arr[i].type !== "dots") { - range3.unshift(arr[i].value); - } - } - output = expandRange(range3, opts); - state.backtrack = true; - } - if (brace.comma !== true && brace.dots !== true) { - const out = state.output.slice(0, brace.outputIndex); - const toks = state.tokens.slice(brace.tokensIndex); - brace.value = brace.output = "\\{"; - value = output = "\\}"; - state.output = out; - for (const t of toks) { - state.output += t.output || t.value; - } - } - push({ type: "brace", value, output }); - decrement("braces"); - braces.pop(); - continue; - } - if (value === "|") { - if (extglobs.length > 0) { - extglobs[extglobs.length - 1].conditions++; - } - push({ type: "text", value }); - continue; - } - if (value === ",") { - let output = value; - const brace = braces[braces.length - 1]; - if (brace && stack[stack.length - 1] === "braces") { - brace.comma = true; - output = "|"; - } - push({ type: "comma", value, output }); - continue; - } - if (value === "/") { - if (prev.type === "dot" && state.index === state.start + 1) { - state.start = state.index + 1; - state.consumed = ""; - state.output = ""; - tokens.pop(); - prev = bos; - continue; - } - push({ type: "slash", value, output: SLASH_LITERAL }); - continue; - } - if (value === ".") { - if (state.braces > 0 && prev.type === "dot") { - if (prev.value === ".") prev.output = DOT_LITERAL; - const brace = braces[braces.length - 1]; - prev.type = "dots"; - prev.output += value; - prev.value += value; - brace.dots = true; - continue; - } - if (state.braces + state.parens === 0 && prev.type !== "bos" && prev.type !== "slash") { - push({ type: "text", value, output: DOT_LITERAL }); - continue; - } - push({ type: "dot", value, output: DOT_LITERAL }); - continue; - } - if (value === "?") { - const isGroup = prev && prev.value === "("; - if (!isGroup && opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { - extglobOpen("qmark", value); - continue; - } - if (prev && prev.type === "paren") { - const next = peek(); - let output = value; - if (prev.value === "(" && !/[!=<:]/.test(next) || next === "<" && !/<([!=]|\w+>)/.test(remaining())) { - output = `\\${value}`; - } - push({ type: "text", value, output }); - continue; - } - if (opts.dot !== true && (prev.type === "slash" || prev.type === "bos")) { - push({ type: "qmark", value, output: QMARK_NO_DOT }); - continue; - } - push({ type: "qmark", value, output: QMARK }); - continue; - } - if (value === "!") { - if (opts.noextglob !== true && peek() === "(") { - if (peek(2) !== "?" || !/[!=<:]/.test(peek(3))) { - extglobOpen("negate", value); - continue; - } - } - if (opts.nonegate !== true && state.index === 0) { - negate(); - continue; - } - } - if (value === "+") { - if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { - extglobOpen("plus", value); - continue; - } - if (prev && prev.value === "(" || opts.regex === false) { - push({ type: "plus", value, output: PLUS_LITERAL }); - continue; - } - if (prev && (prev.type === "bracket" || prev.type === "paren" || prev.type === "brace") || state.parens > 0) { - push({ type: "plus", value }); - continue; - } - push({ type: "plus", value: PLUS_LITERAL }); - continue; - } - if (value === "@") { - if (opts.noextglob !== true && peek() === "(" && peek(2) !== "?") { - push({ type: "at", extglob: true, value, output: "" }); - continue; - } - push({ type: "text", value }); - continue; - } - if (value !== "*") { - if (value === "$" || value === "^") { - value = `\\${value}`; - } - const match = REGEX_NON_SPECIAL_CHARS.exec(remaining()); - if (match) { - value += match[0]; - state.index += match[0].length; - } - push({ type: "text", value }); - continue; - } - if (prev && (prev.type === "globstar" || prev.star === true)) { - prev.type = "star"; - prev.star = true; - prev.value += value; - prev.output = star; - state.backtrack = true; - state.globstar = true; - consume(value); - continue; - } - let rest = remaining(); - if (opts.noextglob !== true && /^\([^?]/.test(rest)) { - extglobOpen("star", value); - continue; - } - if (prev.type === "star") { - if (opts.noglobstar === true) { - consume(value); - continue; - } - const prior = prev.prev; - const before = prior.prev; - const isStart = prior.type === "slash" || prior.type === "bos"; - const afterStar = before && (before.type === "star" || before.type === "globstar"); - if (opts.bash === true && (!isStart || rest[0] && rest[0] !== "/")) { - push({ type: "star", value, output: "" }); - continue; - } - const isBrace = state.braces > 0 && (prior.type === "comma" || prior.type === "brace"); - const isExtglob = extglobs.length && (prior.type === "pipe" || prior.type === "paren"); - if (!isStart && prior.type !== "paren" && !isBrace && !isExtglob) { - push({ type: "star", value, output: "" }); - continue; - } - while (rest.slice(0, 3) === "/**") { - const after = input[state.index + 4]; - if (after && after !== "/") { - break; - } - rest = rest.slice(3); - consume("/**", 3); - } - if (prior.type === "bos" && eos()) { - prev.type = "globstar"; - prev.value += value; - prev.output = globstar(opts); - state.output = prev.output; - state.globstar = true; - consume(value); - continue; - } - if (prior.type === "slash" && prior.prev.type !== "bos" && !afterStar && eos()) { - state.output = state.output.slice(0, -(prior.output + prev.output).length); - prior.output = `(?:${prior.output}`; - prev.type = "globstar"; - prev.output = globstar(opts) + (opts.strictSlashes ? ")" : "|$)"); - prev.value += value; - state.globstar = true; - state.output += prior.output + prev.output; - consume(value); - continue; - } - if (prior.type === "slash" && prior.prev.type !== "bos" && rest[0] === "/") { - const end = rest[1] !== void 0 ? "|$" : ""; - state.output = state.output.slice(0, -(prior.output + prev.output).length); - prior.output = `(?:${prior.output}`; - prev.type = "globstar"; - prev.output = `${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`; - prev.value += value; - state.output += prior.output + prev.output; - state.globstar = true; - consume(value + advance()); - push({ type: "slash", value: "/", output: "" }); - continue; - } - if (prior.type === "bos" && rest[0] === "/") { - prev.type = "globstar"; - prev.value += value; - prev.output = `(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`; - state.output = prev.output; - state.globstar = true; - consume(value + advance()); - push({ type: "slash", value: "/", output: "" }); - continue; - } - state.output = state.output.slice(0, -prev.output.length); - prev.type = "globstar"; - prev.output = globstar(opts); - prev.value += value; - state.output += prev.output; - state.globstar = true; - consume(value); - continue; - } - const token = { type: "star", value, output: star }; - if (opts.bash === true) { - token.output = ".*?"; - if (prev.type === "bos" || prev.type === "slash") { - token.output = nodot + token.output; - } - push(token); - continue; - } - if (prev && (prev.type === "bracket" || prev.type === "paren") && opts.regex === true) { - token.output = value; - push(token); - continue; - } - if (state.index === state.start || prev.type === "slash" || prev.type === "dot") { - if (prev.type === "dot") { - state.output += NO_DOT_SLASH; - prev.output += NO_DOT_SLASH; - } else if (opts.dot === true) { - state.output += NO_DOTS_SLASH; - prev.output += NO_DOTS_SLASH; - } else { - state.output += nodot; - prev.output += nodot; - } - if (peek() !== "*") { - state.output += ONE_CHAR; - prev.output += ONE_CHAR; - } - } - push(token); - } - while (state.brackets > 0) { - if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "]")); - state.output = utils.escapeLast(state.output, "["); - decrement("brackets"); - } - while (state.parens > 0) { - if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", ")")); - state.output = utils.escapeLast(state.output, "("); - decrement("parens"); - } - while (state.braces > 0) { - if (opts.strictBrackets === true) throw new SyntaxError(syntaxError("closing", "}")); - state.output = utils.escapeLast(state.output, "{"); - decrement("braces"); - } - if (opts.strictSlashes !== true && (prev.type === "star" || prev.type === "bracket")) { - push({ type: "maybe_slash", value: "", output: `${SLASH_LITERAL}?` }); - } - if (state.backtrack === true) { - state.output = ""; - for (const token of state.tokens) { - state.output += token.output != null ? token.output : token.value; - if (token.suffix) { - state.output += token.suffix; - } - } - } - return state; - }; - parse.fastpaths = (input, options2) => { - const opts = { ...options2 }; - const max2 = typeof opts.maxLength === "number" ? Math.min(MAX_LENGTH, opts.maxLength) : MAX_LENGTH; - const len = input.length; - if (len > max2) { - throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max2}`); - } - input = REPLACEMENTS[input] || input; - const { - DOT_LITERAL, - SLASH_LITERAL, - ONE_CHAR, - DOTS_SLASH, - NO_DOT, - NO_DOTS, - NO_DOTS_SLASH, - STAR, - START_ANCHOR - } = constants.globChars(opts.windows); - const nodot = opts.dot ? NO_DOTS : NO_DOT; - const slashDot = opts.dot ? NO_DOTS_SLASH : NO_DOT; - const capture = opts.capture ? "" : "?:"; - const state = { negated: false, prefix: "" }; - let star = opts.bash === true ? ".*?" : STAR; - if (opts.capture) { - star = `(${star})`; - } - const globstar = (opts2) => { - if (opts2.noglobstar === true) return star; - return `(${capture}(?:(?!${START_ANCHOR}${opts2.dot ? DOTS_SLASH : DOT_LITERAL}).)*?)`; - }; - const create = (str) => { - switch (str) { - case "*": - return `${nodot}${ONE_CHAR}${star}`; - case ".*": - return `${DOT_LITERAL}${ONE_CHAR}${star}`; - case "*.*": - return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; - case "*/*": - return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slashDot}${star}`; - case "**": - return nodot + globstar(opts); - case "**/*": - return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${ONE_CHAR}${star}`; - case "**/*.*": - return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${slashDot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`; - case "**/.*": - return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`; - default: { - const match = /^(.*?)\.(\w+)$/.exec(str); - if (!match) return; - const source2 = create(match[1]); - if (!source2) return; - return source2 + DOT_LITERAL + match[2]; - } - } - }; - const output = utils.removePrefix(input, state); - let source = create(output); - if (source && opts.strictSlashes !== true) { - source += `${SLASH_LITERAL}?`; - } - return source; - }; - module3.exports = parse; - } -}); - -// node_modules/picomatch/lib/picomatch.js -var require_picomatch = __commonJS({ - "node_modules/picomatch/lib/picomatch.js"(exports2, module3) { - "use strict"; - var scan = require_scan(); - var parse = require_parse(); - var utils = require_utils2(); - var constants = require_constants(); - var isObject2 = (val) => val && typeof val === "object" && !Array.isArray(val); - var picomatch2 = (glob, options2, returnState = false) => { - if (Array.isArray(glob)) { - const fns = glob.map((input) => picomatch2(input, options2, returnState)); - const arrayMatcher = (str) => { - for (const isMatch of fns) { - const state2 = isMatch(str); - if (state2) return state2; - } - return false; - }; - return arrayMatcher; - } - const isState = isObject2(glob) && glob.tokens && glob.input; - if (glob === "" || typeof glob !== "string" && !isState) { - throw new TypeError("Expected pattern to be a non-empty string"); - } - const opts = options2 || {}; - const posix = opts.windows; - const regex = isState ? picomatch2.compileRe(glob, options2) : picomatch2.makeRe(glob, options2, false, true); - const state = regex.state; - delete regex.state; - let isIgnored = () => false; - if (opts.ignore) { - const ignoreOpts = { ...options2, ignore: null, onMatch: null, onResult: null }; - isIgnored = picomatch2(opts.ignore, ignoreOpts, returnState); - } - const matcher = (input, returnObject = false) => { - const { isMatch, match, output } = picomatch2.test(input, regex, options2, { glob, posix }); - const result = { glob, state, regex, posix, input, output, match, isMatch }; - if (typeof opts.onResult === "function") { - opts.onResult(result); - } - if (isMatch === false) { - result.isMatch = false; - return returnObject ? result : false; - } - if (isIgnored(input)) { - if (typeof opts.onIgnore === "function") { - opts.onIgnore(result); - } - result.isMatch = false; - return returnObject ? result : false; - } - if (typeof opts.onMatch === "function") { - opts.onMatch(result); - } - return returnObject ? result : true; - }; - if (returnState) { - matcher.state = state; - } - return matcher; - }; - picomatch2.test = (input, regex, options2, { glob, posix } = {}) => { - if (typeof input !== "string") { - throw new TypeError("Expected input to be a string"); - } - if (input === "") { - return { isMatch: false, output: "" }; - } - const opts = options2 || {}; - const format = opts.format || (posix ? utils.toPosixSlashes : null); - let match = input === glob; - let output = match && format ? format(input) : input; - if (match === false) { - output = format ? format(input) : input; - match = output === glob; - } - if (match === false || opts.capture === true) { - if (opts.matchBase === true || opts.basename === true) { - match = picomatch2.matchBase(input, regex, options2, posix); - } else { - match = regex.exec(output); - } - } - return { isMatch: Boolean(match), match, output }; - }; - picomatch2.matchBase = (input, glob, options2) => { - const regex = glob instanceof RegExp ? glob : picomatch2.makeRe(glob, options2); - return regex.test(utils.basename(input)); - }; - picomatch2.isMatch = (str, patterns, options2) => picomatch2(patterns, options2)(str); - picomatch2.parse = (pattern, options2) => { - if (Array.isArray(pattern)) return pattern.map((p) => picomatch2.parse(p, options2)); - return parse(pattern, { ...options2, fastpaths: false }); - }; - picomatch2.scan = (input, options2) => scan(input, options2); - picomatch2.compileRe = (state, options2, returnOutput = false, returnState = false) => { - if (returnOutput === true) { - return state.output; - } - const opts = options2 || {}; - const prepend = opts.contains ? "" : "^"; - const append = opts.contains ? "" : "$"; - let source = `${prepend}(?:${state.output})${append}`; - if (state && state.negated === true) { - source = `^(?!${source}).*$`; - } - const regex = picomatch2.toRegex(source, options2); - if (returnState === true) { - regex.state = state; - } - return regex; - }; - picomatch2.makeRe = (input, options2 = {}, returnOutput = false, returnState = false) => { - if (!input || typeof input !== "string") { - throw new TypeError("Expected a non-empty string"); - } - let parsed = { negated: false, fastpaths: true }; - if (options2.fastpaths !== false && (input[0] === "." || input[0] === "*")) { - parsed.output = parse.fastpaths(input, options2); - } - if (!parsed.output) { - parsed = parse(input, options2); - } - return picomatch2.compileRe(parsed, options2, returnOutput, returnState); - }; - picomatch2.toRegex = (source, options2) => { - try { - const opts = options2 || {}; - return new RegExp(source, opts.flags || (opts.nocase ? "i" : "")); - } catch (err) { - if (options2 && options2.debug === true) throw err; - return /$^/; - } - }; - picomatch2.constants = constants; - module3.exports = picomatch2; - } -}); - -// node_modules/picomatch/index.js -var require_picomatch2 = __commonJS({ - "node_modules/picomatch/index.js"(exports2, module3) { - "use strict"; - var pico = require_picomatch(); - var utils = require_utils2(); - function picomatch2(glob, options2, returnState = false) { - if (options2 && (options2.windows === null || options2.windows === void 0)) { - options2 = { ...options2, windows: utils.isWindows() }; - } - return pico(glob, options2, returnState); - } - Object.assign(picomatch2, pico); - module3.exports = picomatch2; - } -}); - -// node_modules/graceful-fs/polyfills.js -var require_polyfills = __commonJS({ - "node_modules/graceful-fs/polyfills.js"(exports2, module3) { - var constants = require("constants"); - var origCwd = process.cwd; - var cwd = null; - var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform; - process.cwd = function() { - if (!cwd) - cwd = origCwd.call(process); - return cwd; - }; - try { - process.cwd(); - } catch (er) { - } - if (typeof process.chdir === "function") { - chdir = process.chdir; - process.chdir = function(d) { - cwd = null; - chdir.call(process, d); - }; - if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir); - } - var chdir; - module3.exports = patch; - function patch(fs2) { - if (constants.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) { - patchLchmod(fs2); - } - if (!fs2.lutimes) { - patchLutimes(fs2); - } - fs2.chown = chownFix(fs2.chown); - fs2.fchown = chownFix(fs2.fchown); - fs2.lchown = chownFix(fs2.lchown); - fs2.chmod = chmodFix(fs2.chmod); - fs2.fchmod = chmodFix(fs2.fchmod); - fs2.lchmod = chmodFix(fs2.lchmod); - fs2.chownSync = chownFixSync(fs2.chownSync); - fs2.fchownSync = chownFixSync(fs2.fchownSync); - fs2.lchownSync = chownFixSync(fs2.lchownSync); - fs2.chmodSync = chmodFixSync(fs2.chmodSync); - fs2.fchmodSync = chmodFixSync(fs2.fchmodSync); - fs2.lchmodSync = chmodFixSync(fs2.lchmodSync); - fs2.stat = statFix(fs2.stat); - fs2.fstat = statFix(fs2.fstat); - fs2.lstat = statFix(fs2.lstat); - fs2.statSync = statFixSync(fs2.statSync); - fs2.fstatSync = statFixSync(fs2.fstatSync); - fs2.lstatSync = statFixSync(fs2.lstatSync); - if (fs2.chmod && !fs2.lchmod) { - fs2.lchmod = function(path6, mode, cb) { - if (cb) process.nextTick(cb); - }; - fs2.lchmodSync = function() { - }; - } - if (fs2.chown && !fs2.lchown) { - fs2.lchown = function(path6, uid, gid, cb) { - if (cb) process.nextTick(cb); - }; - fs2.lchownSync = function() { - }; - } - if (platform === "win32") { - fs2.rename = typeof fs2.rename !== "function" ? fs2.rename : (function(fs$rename) { - function rename(from, to, cb) { - var start = Date.now(); - var backoff = 0; - fs$rename(from, to, function CB(er) { - if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) { - setTimeout(function() { - fs2.stat(to, function(stater, st) { - if (stater && stater.code === "ENOENT") - fs$rename(from, to, CB); - else - cb(er); - }); - }, backoff); - if (backoff < 100) - backoff += 10; - return; - } - if (cb) cb(er); - }); - } - if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename); - return rename; - })(fs2.rename); - } - fs2.read = typeof fs2.read !== "function" ? fs2.read : (function(fs$read) { - function read(fd, buffer, offset, length, position, callback_) { - var callback; - if (callback_ && typeof callback_ === "function") { - var eagCounter = 0; - callback = function(er, _, __) { - if (er && er.code === "EAGAIN" && eagCounter < 10) { - eagCounter++; - return fs$read.call(fs2, fd, buffer, offset, length, position, callback); - } - callback_.apply(this, arguments); - }; - } - return fs$read.call(fs2, fd, buffer, offset, length, position, callback); - } - if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read); - return read; - })(fs2.read); - fs2.readSync = typeof fs2.readSync !== "function" ? fs2.readSync : /* @__PURE__ */ (function(fs$readSync) { - return function(fd, buffer, offset, length, position) { - var eagCounter = 0; - while (true) { - try { - return fs$readSync.call(fs2, fd, buffer, offset, length, position); - } catch (er) { - if (er.code === "EAGAIN" && eagCounter < 10) { - eagCounter++; - continue; - } - throw er; - } - } - }; - })(fs2.readSync); - function patchLchmod(fs3) { - fs3.lchmod = function(path6, mode, callback) { - fs3.open( - path6, - constants.O_WRONLY | constants.O_SYMLINK, - mode, - function(err, fd) { - if (err) { - if (callback) callback(err); - return; - } - fs3.fchmod(fd, mode, function(err2) { - fs3.close(fd, function(err22) { - if (callback) callback(err2 || err22); - }); - }); - } - ); - }; - fs3.lchmodSync = function(path6, mode) { - var fd = fs3.openSync(path6, constants.O_WRONLY | constants.O_SYMLINK, mode); - var threw = true; - var ret; - try { - ret = fs3.fchmodSync(fd, mode); - threw = false; - } finally { - if (threw) { - try { - fs3.closeSync(fd); - } catch (er) { - } - } else { - fs3.closeSync(fd); - } - } - return ret; - }; - } - function patchLutimes(fs3) { - if (constants.hasOwnProperty("O_SYMLINK") && fs3.futimes) { - fs3.lutimes = function(path6, at, mt, cb) { - fs3.open(path6, constants.O_SYMLINK, function(er, fd) { - if (er) { - if (cb) cb(er); - return; - } - fs3.futimes(fd, at, mt, function(er2) { - fs3.close(fd, function(er22) { - if (cb) cb(er2 || er22); - }); - }); - }); - }; - fs3.lutimesSync = function(path6, at, mt) { - var fd = fs3.openSync(path6, constants.O_SYMLINK); - var ret; - var threw = true; - try { - ret = fs3.futimesSync(fd, at, mt); - threw = false; - } finally { - if (threw) { - try { - fs3.closeSync(fd); - } catch (er) { - } - } else { - fs3.closeSync(fd); - } - } - return ret; - }; - } else if (fs3.futimes) { - fs3.lutimes = function(_a, _b, _c, cb) { - if (cb) process.nextTick(cb); - }; - fs3.lutimesSync = function() { - }; - } - } - function chmodFix(orig) { - if (!orig) return orig; - return function(target, mode, cb) { - return orig.call(fs2, target, mode, function(er) { - if (chownErOk(er)) er = null; - if (cb) cb.apply(this, arguments); - }); - }; - } - function chmodFixSync(orig) { - if (!orig) return orig; - return function(target, mode) { - try { - return orig.call(fs2, target, mode); - } catch (er) { - if (!chownErOk(er)) throw er; - } - }; - } - function chownFix(orig) { - if (!orig) return orig; - return function(target, uid, gid, cb) { - return orig.call(fs2, target, uid, gid, function(er) { - if (chownErOk(er)) er = null; - if (cb) cb.apply(this, arguments); - }); - }; - } - function chownFixSync(orig) { - if (!orig) return orig; - return function(target, uid, gid) { - try { - return orig.call(fs2, target, uid, gid); - } catch (er) { - if (!chownErOk(er)) throw er; - } - }; - } - function statFix(orig) { - if (!orig) return orig; - return function(target, options2, cb) { - if (typeof options2 === "function") { - cb = options2; - options2 = null; - } - function callback(er, stats) { - if (stats) { - if (stats.uid < 0) stats.uid += 4294967296; - if (stats.gid < 0) stats.gid += 4294967296; - } - if (cb) cb.apply(this, arguments); - } - return options2 ? orig.call(fs2, target, options2, callback) : orig.call(fs2, target, callback); - }; - } - function statFixSync(orig) { - if (!orig) return orig; - return function(target, options2) { - var stats = options2 ? orig.call(fs2, target, options2) : orig.call(fs2, target); - if (stats) { - if (stats.uid < 0) stats.uid += 4294967296; - if (stats.gid < 0) stats.gid += 4294967296; - } - return stats; - }; - } - function chownErOk(er) { - if (!er) - return true; - if (er.code === "ENOSYS") - return true; - var nonroot = !process.getuid || process.getuid() !== 0; - if (nonroot) { - if (er.code === "EINVAL" || er.code === "EPERM") - return true; - } - return false; - } - } - } -}); - -// node_modules/graceful-fs/legacy-streams.js -var require_legacy_streams = __commonJS({ - "node_modules/graceful-fs/legacy-streams.js"(exports2, module3) { - var Stream = require("stream").Stream; - module3.exports = legacy; - function legacy(fs2) { - return { - ReadStream, - WriteStream - }; - function ReadStream(path6, options2) { - if (!(this instanceof ReadStream)) return new ReadStream(path6, options2); - Stream.call(this); - var self2 = this; - this.path = path6; - this.fd = null; - this.readable = true; - this.paused = false; - this.flags = "r"; - this.mode = 438; - this.bufferSize = 64 * 1024; - options2 = options2 || {}; - var keys = Object.keys(options2); - for (var index4 = 0, length = keys.length; index4 < length; index4++) { - var key2 = keys[index4]; - this[key2] = options2[key2]; - } - if (this.encoding) this.setEncoding(this.encoding); - if (this.start !== void 0) { - if ("number" !== typeof this.start) { - throw TypeError("start must be a Number"); - } - if (this.end === void 0) { - this.end = Infinity; - } else if ("number" !== typeof this.end) { - throw TypeError("end must be a Number"); - } - if (this.start > this.end) { - throw new Error("start must be <= end"); - } - this.pos = this.start; - } - if (this.fd !== null) { - process.nextTick(function() { - self2._read(); - }); - return; - } - fs2.open(this.path, this.flags, this.mode, function(err, fd) { - if (err) { - self2.emit("error", err); - self2.readable = false; - return; - } - self2.fd = fd; - self2.emit("open", fd); - self2._read(); - }); - } - function WriteStream(path6, options2) { - if (!(this instanceof WriteStream)) return new WriteStream(path6, options2); - Stream.call(this); - this.path = path6; - this.fd = null; - this.writable = true; - this.flags = "w"; - this.encoding = "binary"; - this.mode = 438; - this.bytesWritten = 0; - options2 = options2 || {}; - var keys = Object.keys(options2); - for (var index4 = 0, length = keys.length; index4 < length; index4++) { - var key2 = keys[index4]; - this[key2] = options2[key2]; - } - if (this.start !== void 0) { - if ("number" !== typeof this.start) { - throw TypeError("start must be a Number"); - } - if (this.start < 0) { - throw new Error("start must be >= zero"); - } - this.pos = this.start; - } - this.busy = false; - this._queue = []; - if (this.fd === null) { - this._open = fs2.open; - this._queue.push([this._open, this.path, this.flags, this.mode, void 0]); - this.flush(); - } - } - } - } -}); - -// node_modules/graceful-fs/clone.js -var require_clone = __commonJS({ - "node_modules/graceful-fs/clone.js"(exports2, module3) { - "use strict"; - module3.exports = clone; - var getPrototypeOf = Object.getPrototypeOf || function(obj) { - return obj.__proto__; - }; - function clone(obj) { - if (obj === null || typeof obj !== "object") - return obj; - if (obj instanceof Object) - var copy = { __proto__: getPrototypeOf(obj) }; - else - var copy = /* @__PURE__ */ Object.create(null); - Object.getOwnPropertyNames(obj).forEach(function(key2) { - Object.defineProperty(copy, key2, Object.getOwnPropertyDescriptor(obj, key2)); - }); - return copy; - } - } -}); - -// node_modules/graceful-fs/graceful-fs.js -var require_graceful_fs = __commonJS({ - "node_modules/graceful-fs/graceful-fs.js"(exports2, module3) { - var fs2 = require("fs"); - var polyfills = require_polyfills(); - var legacy = require_legacy_streams(); - var clone = require_clone(); - var util = require("util"); - var gracefulQueue; - var previousSymbol; - if (typeof Symbol === "function" && typeof Symbol.for === "function") { - gracefulQueue = Symbol.for("graceful-fs.queue"); - previousSymbol = Symbol.for("graceful-fs.previous"); - } else { - gracefulQueue = "___graceful-fs.queue"; - previousSymbol = "___graceful-fs.previous"; - } - function noop6() { - } - function publishQueue(context, queue2) { - Object.defineProperty(context, gracefulQueue, { - get: function() { - return queue2; - } - }); - } - var debug = noop6; - if (util.debuglog) - debug = util.debuglog("gfs4"); - else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) - debug = function() { - var m = util.format.apply(util, arguments); - m = "GFS4: " + m.split(/\n/).join("\nGFS4: "); - console.error(m); - }; - if (!fs2[gracefulQueue]) { - queue = global[gracefulQueue] || []; - publishQueue(fs2, queue); - fs2.close = (function(fs$close) { - function close(fd, cb) { - return fs$close.call(fs2, fd, function(err) { - if (!err) { - resetQueue(); - } - if (typeof cb === "function") - cb.apply(this, arguments); - }); - } - Object.defineProperty(close, previousSymbol, { - value: fs$close - }); - return close; - })(fs2.close); - fs2.closeSync = (function(fs$closeSync) { - function closeSync(fd) { - fs$closeSync.apply(fs2, arguments); - resetQueue(); - } - Object.defineProperty(closeSync, previousSymbol, { - value: fs$closeSync - }); - return closeSync; - })(fs2.closeSync); - if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) { - process.on("exit", function() { - debug(fs2[gracefulQueue]); - require("assert").equal(fs2[gracefulQueue].length, 0); - }); - } - } - var queue; - if (!global[gracefulQueue]) { - publishQueue(global, fs2[gracefulQueue]); - } - module3.exports = patch(clone(fs2)); - if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs2.__patched) { - module3.exports = patch(fs2); - fs2.__patched = true; - } - function patch(fs3) { - polyfills(fs3); - fs3.gracefulify = patch; - fs3.createReadStream = createReadStream; - fs3.createWriteStream = createWriteStream; - var fs$readFile = fs3.readFile; - fs3.readFile = readFile; - function readFile(path6, options2, cb) { - if (typeof options2 === "function") - cb = options2, options2 = null; - return go$readFile(path6, options2, cb); - function go$readFile(path7, options3, cb2, startTime) { - return fs$readFile(path7, options3, function(err) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([go$readFile, [path7, options3, cb2], err, startTime || Date.now(), Date.now()]); - else { - if (typeof cb2 === "function") - cb2.apply(this, arguments); - } - }); - } - } - var fs$writeFile = fs3.writeFile; - fs3.writeFile = writeFile; - function writeFile(path6, data, options2, cb) { - if (typeof options2 === "function") - cb = options2, options2 = null; - return go$writeFile(path6, data, options2, cb); - function go$writeFile(path7, data2, options3, cb2, startTime) { - return fs$writeFile(path7, data2, options3, function(err) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([go$writeFile, [path7, data2, options3, cb2], err, startTime || Date.now(), Date.now()]); - else { - if (typeof cb2 === "function") - cb2.apply(this, arguments); - } - }); - } - } - var fs$appendFile = fs3.appendFile; - if (fs$appendFile) - fs3.appendFile = appendFile; - function appendFile(path6, data, options2, cb) { - if (typeof options2 === "function") - cb = options2, options2 = null; - return go$appendFile(path6, data, options2, cb); - function go$appendFile(path7, data2, options3, cb2, startTime) { - return fs$appendFile(path7, data2, options3, function(err) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([go$appendFile, [path7, data2, options3, cb2], err, startTime || Date.now(), Date.now()]); - else { - if (typeof cb2 === "function") - cb2.apply(this, arguments); - } - }); - } - } - var fs$copyFile = fs3.copyFile; - if (fs$copyFile) - fs3.copyFile = copyFile; - function copyFile(src, dest, flags, cb) { - if (typeof flags === "function") { - cb = flags; - flags = 0; - } - return go$copyFile(src, dest, flags, cb); - function go$copyFile(src2, dest2, flags2, cb2, startTime) { - return fs$copyFile(src2, dest2, flags2, function(err) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([go$copyFile, [src2, dest2, flags2, cb2], err, startTime || Date.now(), Date.now()]); - else { - if (typeof cb2 === "function") - cb2.apply(this, arguments); - } - }); - } - } - var fs$readdir = fs3.readdir; - fs3.readdir = readdir; - var noReaddirOptionVersions = /^v[0-5]\./; - function readdir(path6, options2, cb) { - if (typeof options2 === "function") - cb = options2, options2 = null; - var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path7, options3, cb2, startTime) { - return fs$readdir(path7, fs$readdirCallback( - path7, - options3, - cb2, - startTime - )); - } : function go$readdir2(path7, options3, cb2, startTime) { - return fs$readdir(path7, options3, fs$readdirCallback( - path7, - options3, - cb2, - startTime - )); - }; - return go$readdir(path6, options2, cb); - function fs$readdirCallback(path7, options3, cb2, startTime) { - return function(err, files) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([ - go$readdir, - [path7, options3, cb2], - err, - startTime || Date.now(), - Date.now() - ]); - else { - if (files && files.sort) - files.sort(); - if (typeof cb2 === "function") - cb2.call(this, err, files); - } - }; - } - } - if (process.version.substr(0, 4) === "v0.8") { - var legStreams = legacy(fs3); - ReadStream = legStreams.ReadStream; - WriteStream = legStreams.WriteStream; - } - var fs$ReadStream = fs3.ReadStream; - if (fs$ReadStream) { - ReadStream.prototype = Object.create(fs$ReadStream.prototype); - ReadStream.prototype.open = ReadStream$open; - } - var fs$WriteStream = fs3.WriteStream; - if (fs$WriteStream) { - WriteStream.prototype = Object.create(fs$WriteStream.prototype); - WriteStream.prototype.open = WriteStream$open; - } - Object.defineProperty(fs3, "ReadStream", { - get: function() { - return ReadStream; - }, - set: function(val) { - ReadStream = val; - }, - enumerable: true, - configurable: true - }); - Object.defineProperty(fs3, "WriteStream", { - get: function() { - return WriteStream; - }, - set: function(val) { - WriteStream = val; - }, - enumerable: true, - configurable: true - }); - var FileReadStream = ReadStream; - Object.defineProperty(fs3, "FileReadStream", { - get: function() { - return FileReadStream; - }, - set: function(val) { - FileReadStream = val; - }, - enumerable: true, - configurable: true - }); - var FileWriteStream = WriteStream; - Object.defineProperty(fs3, "FileWriteStream", { - get: function() { - return FileWriteStream; - }, - set: function(val) { - FileWriteStream = val; - }, - enumerable: true, - configurable: true - }); - function ReadStream(path6, options2) { - if (this instanceof ReadStream) - return fs$ReadStream.apply(this, arguments), this; - else - return ReadStream.apply(Object.create(ReadStream.prototype), arguments); - } - function ReadStream$open() { - var that = this; - open(that.path, that.flags, that.mode, function(err, fd) { - if (err) { - if (that.autoClose) - that.destroy(); - that.emit("error", err); - } else { - that.fd = fd; - that.emit("open", fd); - that.read(); - } - }); - } - function WriteStream(path6, options2) { - if (this instanceof WriteStream) - return fs$WriteStream.apply(this, arguments), this; - else - return WriteStream.apply(Object.create(WriteStream.prototype), arguments); - } - function WriteStream$open() { - var that = this; - open(that.path, that.flags, that.mode, function(err, fd) { - if (err) { - that.destroy(); - that.emit("error", err); - } else { - that.fd = fd; - that.emit("open", fd); - } - }); - } - function createReadStream(path6, options2) { - return new fs3.ReadStream(path6, options2); - } - function createWriteStream(path6, options2) { - return new fs3.WriteStream(path6, options2); - } - var fs$open = fs3.open; - fs3.open = open; - function open(path6, flags, mode, cb) { - if (typeof mode === "function") - cb = mode, mode = null; - return go$open(path6, flags, mode, cb); - function go$open(path7, flags2, mode2, cb2, startTime) { - return fs$open(path7, flags2, mode2, function(err, fd) { - if (err && (err.code === "EMFILE" || err.code === "ENFILE")) - enqueue([go$open, [path7, flags2, mode2, cb2], err, startTime || Date.now(), Date.now()]); - else { - if (typeof cb2 === "function") - cb2.apply(this, arguments); - } - }); - } - } - return fs3; - } - function enqueue(elem) { - debug("ENQUEUE", elem[0].name, elem[1]); - fs2[gracefulQueue].push(elem); - retry(); - } - var retryTimer; - function resetQueue() { - var now = Date.now(); - for (var i = 0; i < fs2[gracefulQueue].length; ++i) { - if (fs2[gracefulQueue][i].length > 2) { - fs2[gracefulQueue][i][3] = now; - fs2[gracefulQueue][i][4] = now; - } - } - retry(); - } - function retry() { - clearTimeout(retryTimer); - retryTimer = void 0; - if (fs2[gracefulQueue].length === 0) - return; - var elem = fs2[gracefulQueue].shift(); - var fn = elem[0]; - var args = elem[1]; - var err = elem[2]; - var startTime = elem[3]; - var lastTime = elem[4]; - if (startTime === void 0) { - debug("RETRY", fn.name, args); - fn.apply(null, args); - } else if (Date.now() - startTime >= 6e4) { - debug("TIMEOUT", fn.name, args); - var cb = args.pop(); - if (typeof cb === "function") - cb.call(null, err); - } else { - var sinceAttempt = Date.now() - lastTime; - var sinceStart = Math.max(lastTime - startTime, 1); - var desiredDelay = Math.min(sinceStart * 1.2, 100); - if (sinceAttempt >= desiredDelay) { - debug("RETRY", fn.name, args); - fn.apply(null, args.concat([startTime])); - } else { - fs2[gracefulQueue].push(elem); - } - } - if (retryTimer === void 0) { - retryTimer = setTimeout(retry, 0); - } - } - } -}); - -// node_modules/file-type/index.js -var require_file_type = __commonJS({ - "node_modules/file-type/index.js"(exports2, module3) { - "use strict"; - module3.exports = (input) => { - const buf = new Uint8Array(input); - if (!(buf && buf.length > 1)) { - return null; - } - const check = (header, opts) => { - opts = Object.assign({ - offset: 0 - }, opts); - for (let i = 0; i < header.length; i++) { - if (header[i] !== buf[i + opts.offset]) { - return false; - } - } - return true; - }; - if (check([255, 216, 255])) { - return { - ext: "jpg", - mime: "image/jpeg" - }; - } - if (check([137, 80, 78, 71, 13, 10, 26, 10])) { - return { - ext: "png", - mime: "image/png" - }; - } - if (check([71, 73, 70])) { - return { - ext: "gif", - mime: "image/gif" - }; - } - if (check([87, 69, 66, 80], { offset: 8 })) { - return { - ext: "webp", - mime: "image/webp" - }; - } - if (check([70, 76, 73, 70])) { - return { - ext: "flif", - mime: "image/flif" - }; - } - if ((check([73, 73, 42, 0]) || check([77, 77, 0, 42])) && check([67, 82], { offset: 8 })) { - return { - ext: "cr2", - mime: "image/x-canon-cr2" - }; - } - if (check([73, 73, 42, 0]) || check([77, 77, 0, 42])) { - return { - ext: "tif", - mime: "image/tiff" - }; - } - if (check([66, 77])) { - return { - ext: "bmp", - mime: "image/bmp" - }; - } - if (check([73, 73, 188])) { - return { - ext: "jxr", - mime: "image/vnd.ms-photo" - }; - } - if (check([56, 66, 80, 83])) { - return { - ext: "psd", - mime: "image/vnd.adobe.photoshop" - }; - } - if (check([80, 75, 3, 4]) && check([109, 105, 109, 101, 116, 121, 112, 101, 97, 112, 112, 108, 105, 99, 97, 116, 105, 111, 110, 47, 101, 112, 117, 98, 43, 122, 105, 112], { offset: 30 })) { - return { - ext: "epub", - mime: "application/epub+zip" - }; - } - if (check([80, 75, 3, 4]) && check([77, 69, 84, 65, 45, 73, 78, 70, 47, 109, 111, 122, 105, 108, 108, 97, 46, 114, 115, 97], { offset: 30 })) { - return { - ext: "xpi", - mime: "application/x-xpinstall" - }; - } - if (check([80, 75]) && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { - return { - ext: "zip", - mime: "application/zip" - }; - } - if (check([117, 115, 116, 97, 114], { offset: 257 })) { - return { - ext: "tar", - mime: "application/x-tar" - }; - } - if (check([82, 97, 114, 33, 26, 7]) && (buf[6] === 0 || buf[6] === 1)) { - return { - ext: "rar", - mime: "application/x-rar-compressed" - }; - } - if (check([31, 139, 8])) { - return { - ext: "gz", - mime: "application/gzip" - }; - } - if (check([66, 90, 104])) { - return { - ext: "bz2", - mime: "application/x-bzip2" - }; - } - if (check([55, 122, 188, 175, 39, 28])) { - return { - ext: "7z", - mime: "application/x-7z-compressed" - }; - } - if (check([120, 1])) { - return { - ext: "dmg", - mime: "application/x-apple-diskimage" - }; - } - if (check([0, 0, 0]) && (buf[3] === 24 || buf[3] === 32) && check([102, 116, 121, 112], { offset: 4 }) || check([51, 103, 112, 53]) || check([0, 0, 0, 28, 102, 116, 121, 112, 109, 112, 52, 50]) && check([109, 112, 52, 49, 109, 112, 52, 50, 105, 115, 111, 109], { offset: 16 }) || check([0, 0, 0, 28, 102, 116, 121, 112, 105, 115, 111, 109]) || check([0, 0, 0, 28, 102, 116, 121, 112, 109, 112, 52, 50, 0, 0, 0, 0])) { - return { - ext: "mp4", - mime: "video/mp4" - }; - } - if (check([0, 0, 0, 28, 102, 116, 121, 112, 77, 52, 86])) { - return { - ext: "m4v", - mime: "video/x-m4v" - }; - } - if (check([77, 84, 104, 100])) { - return { - ext: "mid", - mime: "audio/midi" - }; - } - if (check([26, 69, 223, 163])) { - const sliced = buf.subarray(4, 4 + 4096); - const idPos = sliced.findIndex((el, i, arr) => arr[i] === 66 && arr[i + 1] === 130); - if (idPos >= 0) { - const docTypePos = idPos + 3; - const findDocType = (type2) => Array.from(type2).every((c, i) => sliced[docTypePos + i] === c.charCodeAt(0)); - if (findDocType("matroska")) { - return { - ext: "mkv", - mime: "video/x-matroska" - }; - } - if (findDocType("webm")) { - return { - ext: "webm", - mime: "video/webm" - }; - } - } - } - if (check([0, 0, 0, 20, 102, 116, 121, 112, 113, 116, 32, 32]) || check([102, 114, 101, 101], { offset: 4 }) || check([102, 116, 121, 112, 113, 116, 32, 32], { offset: 4 }) || check([109, 100, 97, 116], { offset: 4 }) || // MJPEG - check([119, 105, 100, 101], { offset: 4 })) { - return { - ext: "mov", - mime: "video/quicktime" - }; - } - if (check([82, 73, 70, 70]) && check([65, 86, 73], { offset: 8 })) { - return { - ext: "avi", - mime: "video/x-msvideo" - }; - } - if (check([48, 38, 178, 117, 142, 102, 207, 17, 166, 217])) { - return { - ext: "wmv", - mime: "video/x-ms-wmv" - }; - } - if (check([0, 0, 1, 186])) { - return { - ext: "mpg", - mime: "video/mpeg" - }; - } - if (check([73, 68, 51]) || check([255, 251])) { - return { - ext: "mp3", - mime: "audio/mpeg" - }; - } - if (check([102, 116, 121, 112, 77, 52, 65], { offset: 4 }) || check([77, 52, 65, 32])) { - return { - ext: "m4a", - mime: "audio/m4a" - }; - } - if (check([79, 112, 117, 115, 72, 101, 97, 100], { offset: 28 })) { - return { - ext: "opus", - mime: "audio/opus" - }; - } - if (check([79, 103, 103, 83])) { - return { - ext: "ogg", - mime: "audio/ogg" - }; - } - if (check([102, 76, 97, 67])) { - return { - ext: "flac", - mime: "audio/x-flac" - }; - } - if (check([82, 73, 70, 70]) && check([87, 65, 86, 69], { offset: 8 })) { - return { - ext: "wav", - mime: "audio/x-wav" - }; - } - if (check([35, 33, 65, 77, 82, 10])) { - return { - ext: "amr", - mime: "audio/amr" - }; - } - if (check([37, 80, 68, 70])) { - return { - ext: "pdf", - mime: "application/pdf" - }; - } - if (check([77, 90])) { - return { - ext: "exe", - mime: "application/x-msdownload" - }; - } - if ((buf[0] === 67 || buf[0] === 70) && check([87, 83], { offset: 1 })) { - return { - ext: "swf", - mime: "application/x-shockwave-flash" - }; - } - if (check([123, 92, 114, 116, 102])) { - return { - ext: "rtf", - mime: "application/rtf" - }; - } - if (check([0, 97, 115, 109])) { - return { - ext: "wasm", - mime: "application/wasm" - }; - } - if (check([119, 79, 70, 70]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { - return { - ext: "woff", - mime: "font/woff" - }; - } - if (check([119, 79, 70, 50]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { - return { - ext: "woff2", - mime: "font/woff2" - }; - } - if (check([76, 80], { offset: 34 }) && (check([0, 0, 1], { offset: 8 }) || check([1, 0, 2], { offset: 8 }) || check([2, 0, 2], { offset: 8 }))) { - return { - ext: "eot", - mime: "application/octet-stream" - }; - } - if (check([0, 1, 0, 0, 0])) { - return { - ext: "ttf", - mime: "font/ttf" - }; - } - if (check([79, 84, 84, 79, 0])) { - return { - ext: "otf", - mime: "font/otf" - }; - } - if (check([0, 0, 1, 0])) { - return { - ext: "ico", - mime: "image/x-icon" - }; - } - if (check([70, 76, 86, 1])) { - return { - ext: "flv", - mime: "video/x-flv" - }; - } - if (check([37, 33])) { - return { - ext: "ps", - mime: "application/postscript" - }; - } - if (check([253, 55, 122, 88, 90, 0])) { - return { - ext: "xz", - mime: "application/x-xz" - }; - } - if (check([83, 81, 76, 105])) { - return { - ext: "sqlite", - mime: "application/x-sqlite3" - }; - } - if (check([78, 69, 83, 26])) { - return { - ext: "nes", - mime: "application/x-nintendo-nes-rom" - }; - } - if (check([67, 114, 50, 52])) { - return { - ext: "crx", - mime: "application/x-google-chrome-extension" - }; - } - if (check([77, 83, 67, 70]) || check([73, 83, 99, 40])) { - return { - ext: "cab", - mime: "application/vnd.ms-cab-compressed" - }; - } - if (check([33, 60, 97, 114, 99, 104, 62, 10, 100, 101, 98, 105, 97, 110, 45, 98, 105, 110, 97, 114, 121])) { - return { - ext: "deb", - mime: "application/x-deb" - }; - } - if (check([33, 60, 97, 114, 99, 104, 62])) { - return { - ext: "ar", - mime: "application/x-unix-archive" - }; - } - if (check([237, 171, 238, 219])) { - return { - ext: "rpm", - mime: "application/x-rpm" - }; - } - if (check([31, 160]) || check([31, 157])) { - return { - ext: "Z", - mime: "application/x-compress" - }; - } - if (check([76, 90, 73, 80])) { - return { - ext: "lz", - mime: "application/x-lzip" - }; - } - if (check([208, 207, 17, 224, 161, 177, 26, 225])) { - return { - ext: "msi", - mime: "application/x-msi" - }; - } - if (check([6, 14, 43, 52, 2, 5, 1, 1, 13, 1, 2, 1, 1, 2])) { - return { - ext: "mxf", - mime: "application/mxf" - }; - } - if (check([71], { offset: 4 }) && (check([71], { offset: 192 }) || check([71], { offset: 196 }))) { - return { - ext: "mts", - mime: "video/mp2t" - }; - } - if (check([66, 76, 69, 78, 68, 69, 82])) { - return { - ext: "blend", - mime: "application/x-blender" - }; - } - if (check([66, 80, 71, 251])) { - return { - ext: "bpg", - mime: "image/bpg" - }; - } - return null; - }; - } -}); - -// node_modules/is-stream/index.js -var require_is_stream = __commonJS({ - "node_modules/is-stream/index.js"(exports2, module3) { - "use strict"; - var isStream = module3.exports = function(stream2) { - return stream2 !== null && typeof stream2 === "object" && typeof stream2.pipe === "function"; - }; - isStream.writable = function(stream2) { - return isStream(stream2) && stream2.writable !== false && typeof stream2._write === "function" && typeof stream2._writableState === "object"; - }; - isStream.readable = function(stream2) { - return isStream(stream2) && stream2.readable !== false && typeof stream2._read === "function" && typeof stream2._readableState === "object"; - }; - isStream.duplex = function(stream2) { - return isStream.writable(stream2) && isStream.readable(stream2); - }; - isStream.transform = function(stream2) { - return isStream.duplex(stream2) && typeof stream2._transform === "function" && typeof stream2._transformState === "object"; - }; - } -}); - -// node_modules/process-nextick-args/index.js -var require_process_nextick_args = __commonJS({ - "node_modules/process-nextick-args/index.js"(exports2, module3) { - "use strict"; - if (typeof process === "undefined" || !process.version || process.version.indexOf("v0.") === 0 || process.version.indexOf("v1.") === 0 && process.version.indexOf("v1.8.") !== 0) { - module3.exports = { nextTick }; - } else { - module3.exports = process; - } - function nextTick(fn, arg1, arg2, arg3) { - if (typeof fn !== "function") { - throw new TypeError('"callback" argument must be a function'); - } - var len = arguments.length; - var args, i; - switch (len) { - case 0: - case 1: - return process.nextTick(fn); - case 2: - return process.nextTick(function afterTickOne() { - fn.call(null, arg1); - }); - case 3: - return process.nextTick(function afterTickTwo() { - fn.call(null, arg1, arg2); - }); - case 4: - return process.nextTick(function afterTickThree() { - fn.call(null, arg1, arg2, arg3); - }); - default: - args = new Array(len - 1); - i = 0; - while (i < args.length) { - args[i++] = arguments[i]; - } - return process.nextTick(function afterTick() { - fn.apply(null, args); - }); - } - } - } -}); - -// node_modules/isarray/index.js -var require_isarray = __commonJS({ - "node_modules/isarray/index.js"(exports2, module3) { - var toString = {}.toString; - module3.exports = Array.isArray || function(arr) { - return toString.call(arr) == "[object Array]"; - }; - } -}); - -// node_modules/readable-stream/lib/internal/streams/stream.js -var require_stream = __commonJS({ - "node_modules/readable-stream/lib/internal/streams/stream.js"(exports2, module3) { - module3.exports = require("stream"); - } -}); - -// node_modules/readable-stream/node_modules/safe-buffer/index.js -var require_safe_buffer = __commonJS({ - "node_modules/readable-stream/node_modules/safe-buffer/index.js"(exports2, module3) { - var buffer = require("buffer"); - var Buffer3 = buffer.Buffer; - function copyProps(src, dst) { - for (var key2 in src) { - dst[key2] = src[key2]; - } - } - if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { - module3.exports = buffer; - } else { - copyProps(buffer, exports2); - exports2.Buffer = SafeBuffer; - } - function SafeBuffer(arg, encodingOrOffset, length) { - return Buffer3(arg, encodingOrOffset, length); - } - copyProps(Buffer3, SafeBuffer); - SafeBuffer.from = function(arg, encodingOrOffset, length) { - if (typeof arg === "number") { - throw new TypeError("Argument must not be a number"); - } - return Buffer3(arg, encodingOrOffset, length); - }; - SafeBuffer.alloc = function(size, fill, encoding) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - var buf = Buffer3(size); - if (fill !== void 0) { - if (typeof encoding === "string") { - buf.fill(fill, encoding); - } else { - buf.fill(fill); - } - } else { - buf.fill(0); - } - return buf; - }; - SafeBuffer.allocUnsafe = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return Buffer3(size); - }; - SafeBuffer.allocUnsafeSlow = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return buffer.SlowBuffer(size); - }; - } -}); - -// node_modules/core-util-is/lib/util.js -var require_util = __commonJS({ - "node_modules/core-util-is/lib/util.js"(exports2) { - function isArray(arg) { - if (Array.isArray) { - return Array.isArray(arg); - } - return objectToString(arg) === "[object Array]"; - } - exports2.isArray = isArray; - function isBoolean(arg) { - return typeof arg === "boolean"; - } - exports2.isBoolean = isBoolean; - function isNull(arg) { - return arg === null; - } - exports2.isNull = isNull; - function isNullOrUndefined(arg) { - return arg == null; - } - exports2.isNullOrUndefined = isNullOrUndefined; - function isNumber(arg) { - return typeof arg === "number"; - } - exports2.isNumber = isNumber; - function isString(arg) { - return typeof arg === "string"; - } - exports2.isString = isString; - function isSymbol(arg) { - return typeof arg === "symbol"; - } - exports2.isSymbol = isSymbol; - function isUndefined(arg) { - return arg === void 0; - } - exports2.isUndefined = isUndefined; - function isRegExp(re) { - return objectToString(re) === "[object RegExp]"; - } - exports2.isRegExp = isRegExp; - function isObject2(arg) { - return typeof arg === "object" && arg !== null; - } - exports2.isObject = isObject2; - function isDate(d) { - return objectToString(d) === "[object Date]"; - } - exports2.isDate = isDate; - function isError(e) { - return objectToString(e) === "[object Error]" || e instanceof Error; - } - exports2.isError = isError; - function isFunction(arg) { - return typeof arg === "function"; - } - exports2.isFunction = isFunction; - function isPrimitive(arg) { - return arg === null || typeof arg === "boolean" || typeof arg === "number" || typeof arg === "string" || typeof arg === "symbol" || // ES6 symbol - typeof arg === "undefined"; - } - exports2.isPrimitive = isPrimitive; - exports2.isBuffer = require("buffer").Buffer.isBuffer; - function objectToString(o) { - return Object.prototype.toString.call(o); - } - } -}); - -// node_modules/inherits/inherits_browser.js -var require_inherits_browser = __commonJS({ - "node_modules/inherits/inherits_browser.js"(exports2, module3) { - if (typeof Object.create === "function") { - module3.exports = function inherits(ctor, superCtor) { - if (superCtor) { - ctor.super_ = superCtor; - ctor.prototype = Object.create(superCtor.prototype, { - constructor: { - value: ctor, - enumerable: false, - writable: true, - configurable: true - } - }); - } - }; - } else { - module3.exports = function inherits(ctor, superCtor) { - if (superCtor) { - ctor.super_ = superCtor; - var TempCtor = function() { - }; - TempCtor.prototype = superCtor.prototype; - ctor.prototype = new TempCtor(); - ctor.prototype.constructor = ctor; - } - }; - } - } -}); - -// node_modules/inherits/inherits.js -var require_inherits = __commonJS({ - "node_modules/inherits/inherits.js"(exports2, module3) { - try { - util = require("util"); - if (typeof util.inherits !== "function") throw ""; - module3.exports = util.inherits; - } catch (e) { - module3.exports = require_inherits_browser(); - } - var util; - } -}); - -// node_modules/readable-stream/lib/internal/streams/BufferList.js -var require_BufferList = __commonJS({ - "node_modules/readable-stream/lib/internal/streams/BufferList.js"(exports2, module3) { - "use strict"; - function _classCallCheck(instance, Constructor) { - if (!(instance instanceof Constructor)) { - throw new TypeError("Cannot call a class as a function"); - } - } - var Buffer3 = require_safe_buffer().Buffer; - var util = require("util"); - function copyBuffer(src, target, offset) { - src.copy(target, offset); - } - module3.exports = (function() { - function BufferList() { - _classCallCheck(this, BufferList); - this.head = null; - this.tail = null; - this.length = 0; - } - BufferList.prototype.push = function push(v) { - var entry6 = { data: v, next: null }; - if (this.length > 0) this.tail.next = entry6; - else this.head = entry6; - this.tail = entry6; - ++this.length; - }; - BufferList.prototype.unshift = function unshift(v) { - var entry6 = { data: v, next: this.head }; - if (this.length === 0) this.tail = entry6; - this.head = entry6; - ++this.length; - }; - BufferList.prototype.shift = function shift() { - if (this.length === 0) return; - var ret = this.head.data; - if (this.length === 1) this.head = this.tail = null; - else this.head = this.head.next; - --this.length; - return ret; - }; - BufferList.prototype.clear = function clear() { - this.head = this.tail = null; - this.length = 0; - }; - BufferList.prototype.join = function join2(s) { - if (this.length === 0) return ""; - var p = this.head; - var ret = "" + p.data; - while (p = p.next) { - ret += s + p.data; - } - return ret; - }; - BufferList.prototype.concat = function concat(n) { - if (this.length === 0) return Buffer3.alloc(0); - var ret = Buffer3.allocUnsafe(n >>> 0); - var p = this.head; - var i = 0; - while (p) { - copyBuffer(p.data, ret, i); - i += p.data.length; - p = p.next; - } - return ret; - }; - return BufferList; - })(); - if (util && util.inspect && util.inspect.custom) { - module3.exports.prototype[util.inspect.custom] = function() { - var obj = util.inspect({ length: this.length }); - return this.constructor.name + " " + obj; - }; - } - } -}); - -// node_modules/readable-stream/lib/internal/streams/destroy.js -var require_destroy = __commonJS({ - "node_modules/readable-stream/lib/internal/streams/destroy.js"(exports2, module3) { - "use strict"; - var pna = require_process_nextick_args(); - function destroy(err, cb) { - var _this = this; - var readableDestroyed = this._readableState && this._readableState.destroyed; - var writableDestroyed = this._writableState && this._writableState.destroyed; - if (readableDestroyed || writableDestroyed) { - if (cb) { - cb(err); - } else if (err) { - if (!this._writableState) { - pna.nextTick(emitErrorNT, this, err); - } else if (!this._writableState.errorEmitted) { - this._writableState.errorEmitted = true; - pna.nextTick(emitErrorNT, this, err); - } - } - return this; - } - if (this._readableState) { - this._readableState.destroyed = true; - } - if (this._writableState) { - this._writableState.destroyed = true; - } - this._destroy(err || null, function(err2) { - if (!cb && err2) { - if (!_this._writableState) { - pna.nextTick(emitErrorNT, _this, err2); - } else if (!_this._writableState.errorEmitted) { - _this._writableState.errorEmitted = true; - pna.nextTick(emitErrorNT, _this, err2); - } - } else if (cb) { - cb(err2); - } - }); - return this; - } - function undestroy() { - if (this._readableState) { - this._readableState.destroyed = false; - this._readableState.reading = false; - this._readableState.ended = false; - this._readableState.endEmitted = false; - } - if (this._writableState) { - this._writableState.destroyed = false; - this._writableState.ended = false; - this._writableState.ending = false; - this._writableState.finalCalled = false; - this._writableState.prefinished = false; - this._writableState.finished = false; - this._writableState.errorEmitted = false; - } - } - function emitErrorNT(self2, err) { - self2.emit("error", err); - } - module3.exports = { - destroy, - undestroy - }; - } -}); - -// node_modules/util-deprecate/node.js -var require_node = __commonJS({ - "node_modules/util-deprecate/node.js"(exports2, module3) { - module3.exports = require("util").deprecate; - } -}); - -// node_modules/readable-stream/lib/_stream_writable.js -var require_stream_writable = __commonJS({ - "node_modules/readable-stream/lib/_stream_writable.js"(exports2, module3) { - "use strict"; - var pna = require_process_nextick_args(); - module3.exports = Writable; - function CorkedRequest(state) { - var _this = this; - this.next = null; - this.entry = null; - this.finish = function() { - onCorkedFinish(_this, state); - }; - } - var asyncWrite = !process.browser && ["v0.10", "v0.9."].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : pna.nextTick; - var Duplex; - Writable.WritableState = WritableState; - var util = Object.create(require_util()); - util.inherits = require_inherits(); - var internalUtil = { - deprecate: require_node() - }; - var Stream = require_stream(); - var Buffer3 = require_safe_buffer().Buffer; - var OurUint8Array = (typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : {}).Uint8Array || function() { - }; - function _uint8ArrayToBuffer(chunk) { - return Buffer3.from(chunk); - } - function _isUint8Array(obj) { - return Buffer3.isBuffer(obj) || obj instanceof OurUint8Array; - } - var destroyImpl = require_destroy(); - util.inherits(Writable, Stream); - function nop() { - } - function WritableState(options2, stream2) { - Duplex = Duplex || require_stream_duplex(); - options2 = options2 || {}; - var isDuplex = stream2 instanceof Duplex; - this.objectMode = !!options2.objectMode; - if (isDuplex) this.objectMode = this.objectMode || !!options2.writableObjectMode; - var hwm = options2.highWaterMark; - var writableHwm = options2.writableHighWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; - if (hwm || hwm === 0) this.highWaterMark = hwm; - else if (isDuplex && (writableHwm || writableHwm === 0)) this.highWaterMark = writableHwm; - else this.highWaterMark = defaultHwm; - this.highWaterMark = Math.floor(this.highWaterMark); - this.finalCalled = false; - this.needDrain = false; - this.ending = false; - this.ended = false; - this.finished = false; - this.destroyed = false; - var noDecode = options2.decodeStrings === false; - this.decodeStrings = !noDecode; - this.defaultEncoding = options2.defaultEncoding || "utf8"; - this.length = 0; - this.writing = false; - this.corked = 0; - this.sync = true; - this.bufferProcessing = false; - this.onwrite = function(er) { - onwrite(stream2, er); - }; - this.writecb = null; - this.writelen = 0; - this.bufferedRequest = null; - this.lastBufferedRequest = null; - this.pendingcb = 0; - this.prefinished = false; - this.errorEmitted = false; - this.bufferedRequestCount = 0; - this.corkedRequestsFree = new CorkedRequest(this); - } - WritableState.prototype.getBuffer = function getBuffer() { - var current = this.bufferedRequest; - var out = []; - while (current) { - out.push(current); - current = current.next; - } - return out; - }; - (function() { - try { - Object.defineProperty(WritableState.prototype, "buffer", { - get: internalUtil.deprecate(function() { - return this.getBuffer(); - }, "_writableState.buffer is deprecated. Use _writableState.getBuffer instead.", "DEP0003") - }); - } catch (_) { - } - })(); - var realHasInstance; - if (typeof Symbol === "function" && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] === "function") { - realHasInstance = Function.prototype[Symbol.hasInstance]; - Object.defineProperty(Writable, Symbol.hasInstance, { - value: function(object5) { - if (realHasInstance.call(this, object5)) return true; - if (this !== Writable) return false; - return object5 && object5._writableState instanceof WritableState; - } - }); - } else { - realHasInstance = function(object5) { - return object5 instanceof this; - }; - } - function Writable(options2) { - Duplex = Duplex || require_stream_duplex(); - if (!realHasInstance.call(Writable, this) && !(this instanceof Duplex)) { - return new Writable(options2); - } - this._writableState = new WritableState(options2, this); - this.writable = true; - if (options2) { - if (typeof options2.write === "function") this._write = options2.write; - if (typeof options2.writev === "function") this._writev = options2.writev; - if (typeof options2.destroy === "function") this._destroy = options2.destroy; - if (typeof options2.final === "function") this._final = options2.final; - } - Stream.call(this); - } - Writable.prototype.pipe = function() { - this.emit("error", new Error("Cannot pipe, not readable")); - }; - function writeAfterEnd(stream2, cb) { - var er = new Error("write after end"); - stream2.emit("error", er); - pna.nextTick(cb, er); - } - function validChunk(stream2, state, chunk, cb) { - var valid = true; - var er = false; - if (chunk === null) { - er = new TypeError("May not write null values to stream"); - } else if (typeof chunk !== "string" && chunk !== void 0 && !state.objectMode) { - er = new TypeError("Invalid non-string/buffer chunk"); - } - if (er) { - stream2.emit("error", er); - pna.nextTick(cb, er); - valid = false; - } - return valid; - } - Writable.prototype.write = function(chunk, encoding, cb) { - var state = this._writableState; - var ret = false; - var isBuf = !state.objectMode && _isUint8Array(chunk); - if (isBuf && !Buffer3.isBuffer(chunk)) { - chunk = _uint8ArrayToBuffer(chunk); - } - if (typeof encoding === "function") { - cb = encoding; - encoding = null; - } - if (isBuf) encoding = "buffer"; - else if (!encoding) encoding = state.defaultEncoding; - if (typeof cb !== "function") cb = nop; - if (state.ended) writeAfterEnd(this, cb); - else if (isBuf || validChunk(this, state, chunk, cb)) { - state.pendingcb++; - ret = writeOrBuffer(this, state, isBuf, chunk, encoding, cb); - } - return ret; - }; - Writable.prototype.cork = function() { - var state = this._writableState; - state.corked++; - }; - Writable.prototype.uncork = function() { - var state = this._writableState; - if (state.corked) { - state.corked--; - if (!state.writing && !state.corked && !state.bufferProcessing && state.bufferedRequest) clearBuffer(this, state); - } - }; - Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) { - if (typeof encoding === "string") encoding = encoding.toLowerCase(); - if (!(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((encoding + "").toLowerCase()) > -1)) throw new TypeError("Unknown encoding: " + encoding); - this._writableState.defaultEncoding = encoding; - return this; - }; - function decodeChunk(state, chunk, encoding) { - if (!state.objectMode && state.decodeStrings !== false && typeof chunk === "string") { - chunk = Buffer3.from(chunk, encoding); - } - return chunk; - } - Object.defineProperty(Writable.prototype, "writableHighWaterMark", { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function() { - return this._writableState.highWaterMark; - } - }); - function writeOrBuffer(stream2, state, isBuf, chunk, encoding, cb) { - if (!isBuf) { - var newChunk = decodeChunk(state, chunk, encoding); - if (chunk !== newChunk) { - isBuf = true; - encoding = "buffer"; - chunk = newChunk; - } - } - var len = state.objectMode ? 1 : chunk.length; - state.length += len; - var ret = state.length < state.highWaterMark; - if (!ret) state.needDrain = true; - if (state.writing || state.corked) { - var last = state.lastBufferedRequest; - state.lastBufferedRequest = { - chunk, - encoding, - isBuf, - callback: cb, - next: null - }; - if (last) { - last.next = state.lastBufferedRequest; - } else { - state.bufferedRequest = state.lastBufferedRequest; - } - state.bufferedRequestCount += 1; - } else { - doWrite(stream2, state, false, len, chunk, encoding, cb); - } - return ret; - } - function doWrite(stream2, state, writev, len, chunk, encoding, cb) { - state.writelen = len; - state.writecb = cb; - state.writing = true; - state.sync = true; - if (writev) stream2._writev(chunk, state.onwrite); - else stream2._write(chunk, encoding, state.onwrite); - state.sync = false; - } - function onwriteError(stream2, state, sync, er, cb) { - --state.pendingcb; - if (sync) { - pna.nextTick(cb, er); - pna.nextTick(finishMaybe, stream2, state); - stream2._writableState.errorEmitted = true; - stream2.emit("error", er); - } else { - cb(er); - stream2._writableState.errorEmitted = true; - stream2.emit("error", er); - finishMaybe(stream2, state); - } - } - function onwriteStateUpdate(state) { - state.writing = false; - state.writecb = null; - state.length -= state.writelen; - state.writelen = 0; - } - function onwrite(stream2, er) { - var state = stream2._writableState; - var sync = state.sync; - var cb = state.writecb; - onwriteStateUpdate(state); - if (er) onwriteError(stream2, state, sync, er, cb); - else { - var finished = needFinish(state); - if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) { - clearBuffer(stream2, state); - } - if (sync) { - asyncWrite(afterWrite, stream2, state, finished, cb); - } else { - afterWrite(stream2, state, finished, cb); - } - } - } - function afterWrite(stream2, state, finished, cb) { - if (!finished) onwriteDrain(stream2, state); - state.pendingcb--; - cb(); - finishMaybe(stream2, state); - } - function onwriteDrain(stream2, state) { - if (state.length === 0 && state.needDrain) { - state.needDrain = false; - stream2.emit("drain"); - } - } - function clearBuffer(stream2, state) { - state.bufferProcessing = true; - var entry6 = state.bufferedRequest; - if (stream2._writev && entry6 && entry6.next) { - var l = state.bufferedRequestCount; - var buffer = new Array(l); - var holder = state.corkedRequestsFree; - holder.entry = entry6; - var count = 0; - var allBuffers = true; - while (entry6) { - buffer[count] = entry6; - if (!entry6.isBuf) allBuffers = false; - entry6 = entry6.next; - count += 1; - } - buffer.allBuffers = allBuffers; - doWrite(stream2, state, true, state.length, buffer, "", holder.finish); - state.pendingcb++; - state.lastBufferedRequest = null; - if (holder.next) { - state.corkedRequestsFree = holder.next; - holder.next = null; - } else { - state.corkedRequestsFree = new CorkedRequest(state); - } - state.bufferedRequestCount = 0; - } else { - while (entry6) { - var chunk = entry6.chunk; - var encoding = entry6.encoding; - var cb = entry6.callback; - var len = state.objectMode ? 1 : chunk.length; - doWrite(stream2, state, false, len, chunk, encoding, cb); - entry6 = entry6.next; - state.bufferedRequestCount--; - if (state.writing) { - break; - } - } - if (entry6 === null) state.lastBufferedRequest = null; - } - state.bufferedRequest = entry6; - state.bufferProcessing = false; - } - Writable.prototype._write = function(chunk, encoding, cb) { - cb(new Error("_write() is not implemented")); - }; - Writable.prototype._writev = null; - Writable.prototype.end = function(chunk, encoding, cb) { - var state = this._writableState; - if (typeof chunk === "function") { - cb = chunk; - chunk = null; - encoding = null; - } else if (typeof encoding === "function") { - cb = encoding; - encoding = null; - } - if (chunk !== null && chunk !== void 0) this.write(chunk, encoding); - if (state.corked) { - state.corked = 1; - this.uncork(); - } - if (!state.ending) endWritable(this, state, cb); - }; - function needFinish(state) { - return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing; - } - function callFinal(stream2, state) { - stream2._final(function(err) { - state.pendingcb--; - if (err) { - stream2.emit("error", err); - } - state.prefinished = true; - stream2.emit("prefinish"); - finishMaybe(stream2, state); - }); - } - function prefinish(stream2, state) { - if (!state.prefinished && !state.finalCalled) { - if (typeof stream2._final === "function") { - state.pendingcb++; - state.finalCalled = true; - pna.nextTick(callFinal, stream2, state); - } else { - state.prefinished = true; - stream2.emit("prefinish"); - } - } - } - function finishMaybe(stream2, state) { - var need = needFinish(state); - if (need) { - prefinish(stream2, state); - if (state.pendingcb === 0) { - state.finished = true; - stream2.emit("finish"); - } - } - return need; - } - function endWritable(stream2, state, cb) { - state.ending = true; - finishMaybe(stream2, state); - if (cb) { - if (state.finished) pna.nextTick(cb); - else stream2.once("finish", cb); - } - state.ended = true; - stream2.writable = false; - } - function onCorkedFinish(corkReq, state, err) { - var entry6 = corkReq.entry; - corkReq.entry = null; - while (entry6) { - var cb = entry6.callback; - state.pendingcb--; - cb(err); - entry6 = entry6.next; - } - state.corkedRequestsFree.next = corkReq; - } - Object.defineProperty(Writable.prototype, "destroyed", { - get: function() { - if (this._writableState === void 0) { - return false; - } - return this._writableState.destroyed; - }, - set: function(value) { - if (!this._writableState) { - return; - } - this._writableState.destroyed = value; - } - }); - Writable.prototype.destroy = destroyImpl.destroy; - Writable.prototype._undestroy = destroyImpl.undestroy; - Writable.prototype._destroy = function(err, cb) { - this.end(); - cb(err); - }; - } -}); - -// node_modules/readable-stream/lib/_stream_duplex.js -var require_stream_duplex = __commonJS({ - "node_modules/readable-stream/lib/_stream_duplex.js"(exports2, module3) { - "use strict"; - var pna = require_process_nextick_args(); - var objectKeys = Object.keys || function(obj) { - var keys2 = []; - for (var key2 in obj) { - keys2.push(key2); - } - return keys2; - }; - module3.exports = Duplex; - var util = Object.create(require_util()); - util.inherits = require_inherits(); - var Readable = require_stream_readable(); - var Writable = require_stream_writable(); - util.inherits(Duplex, Readable); - { - keys = objectKeys(Writable.prototype); - for (v = 0; v < keys.length; v++) { - method = keys[v]; - if (!Duplex.prototype[method]) Duplex.prototype[method] = Writable.prototype[method]; - } - } - var keys; - var method; - var v; - function Duplex(options2) { - if (!(this instanceof Duplex)) return new Duplex(options2); - Readable.call(this, options2); - Writable.call(this, options2); - if (options2 && options2.readable === false) this.readable = false; - if (options2 && options2.writable === false) this.writable = false; - this.allowHalfOpen = true; - if (options2 && options2.allowHalfOpen === false) this.allowHalfOpen = false; - this.once("end", onend); - } - Object.defineProperty(Duplex.prototype, "writableHighWaterMark", { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function() { - return this._writableState.highWaterMark; - } - }); - function onend() { - if (this.allowHalfOpen || this._writableState.ended) return; - pna.nextTick(onEndNT, this); - } - function onEndNT(self2) { - self2.end(); - } - Object.defineProperty(Duplex.prototype, "destroyed", { - get: function() { - if (this._readableState === void 0 || this._writableState === void 0) { - return false; - } - return this._readableState.destroyed && this._writableState.destroyed; - }, - set: function(value) { - if (this._readableState === void 0 || this._writableState === void 0) { - return; - } - this._readableState.destroyed = value; - this._writableState.destroyed = value; - } - }); - Duplex.prototype._destroy = function(err, cb) { - this.push(null); - this.end(); - pna.nextTick(cb, err); - }; - } -}); - -// node_modules/string_decoder/node_modules/safe-buffer/index.js -var require_safe_buffer2 = __commonJS({ - "node_modules/string_decoder/node_modules/safe-buffer/index.js"(exports2, module3) { - var buffer = require("buffer"); - var Buffer3 = buffer.Buffer; - function copyProps(src, dst) { - for (var key2 in src) { - dst[key2] = src[key2]; - } - } - if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { - module3.exports = buffer; - } else { - copyProps(buffer, exports2); - exports2.Buffer = SafeBuffer; - } - function SafeBuffer(arg, encodingOrOffset, length) { - return Buffer3(arg, encodingOrOffset, length); - } - copyProps(Buffer3, SafeBuffer); - SafeBuffer.from = function(arg, encodingOrOffset, length) { - if (typeof arg === "number") { - throw new TypeError("Argument must not be a number"); - } - return Buffer3(arg, encodingOrOffset, length); - }; - SafeBuffer.alloc = function(size, fill, encoding) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - var buf = Buffer3(size); - if (fill !== void 0) { - if (typeof encoding === "string") { - buf.fill(fill, encoding); - } else { - buf.fill(fill); - } - } else { - buf.fill(0); - } - return buf; - }; - SafeBuffer.allocUnsafe = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return Buffer3(size); - }; - SafeBuffer.allocUnsafeSlow = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return buffer.SlowBuffer(size); - }; - } -}); - -// node_modules/string_decoder/lib/string_decoder.js -var require_string_decoder = __commonJS({ - "node_modules/string_decoder/lib/string_decoder.js"(exports2) { - "use strict"; - var Buffer3 = require_safe_buffer2().Buffer; - var isEncoding = Buffer3.isEncoding || function(encoding) { - encoding = "" + encoding; - switch (encoding && encoding.toLowerCase()) { - case "hex": - case "utf8": - case "utf-8": - case "ascii": - case "binary": - case "base64": - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - case "raw": - return true; - default: - return false; - } - }; - function _normalizeEncoding(enc) { - if (!enc) return "utf8"; - var retried; - while (true) { - switch (enc) { - case "utf8": - case "utf-8": - return "utf8"; - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return "utf16le"; - case "latin1": - case "binary": - return "latin1"; - case "base64": - case "ascii": - case "hex": - return enc; - default: - if (retried) return; - enc = ("" + enc).toLowerCase(); - retried = true; - } - } - } - function normalizeEncoding(enc) { - var nenc = _normalizeEncoding(enc); - if (typeof nenc !== "string" && (Buffer3.isEncoding === isEncoding || !isEncoding(enc))) throw new Error("Unknown encoding: " + enc); - return nenc || enc; - } - exports2.StringDecoder = StringDecoder; - function StringDecoder(encoding) { - this.encoding = normalizeEncoding(encoding); - var nb; - switch (this.encoding) { - case "utf16le": - this.text = utf16Text; - this.end = utf16End; - nb = 4; - break; - case "utf8": - this.fillLast = utf8FillLast; - nb = 4; - break; - case "base64": - this.text = base64Text; - this.end = base64End; - nb = 3; - break; - default: - this.write = simpleWrite; - this.end = simpleEnd; - return; - } - this.lastNeed = 0; - this.lastTotal = 0; - this.lastChar = Buffer3.allocUnsafe(nb); - } - StringDecoder.prototype.write = function(buf) { - if (buf.length === 0) return ""; - var r; - var i; - if (this.lastNeed) { - r = this.fillLast(buf); - if (r === void 0) return ""; - i = this.lastNeed; - this.lastNeed = 0; - } else { - i = 0; - } - if (i < buf.length) return r ? r + this.text(buf, i) : this.text(buf, i); - return r || ""; - }; - StringDecoder.prototype.end = utf8End; - StringDecoder.prototype.text = utf8Text; - StringDecoder.prototype.fillLast = function(buf) { - if (this.lastNeed <= buf.length) { - buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed); - return this.lastChar.toString(this.encoding, 0, this.lastTotal); - } - buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, buf.length); - this.lastNeed -= buf.length; - }; - function utf8CheckByte(byte) { - if (byte <= 127) return 0; - else if (byte >> 5 === 6) return 2; - else if (byte >> 4 === 14) return 3; - else if (byte >> 3 === 30) return 4; - return byte >> 6 === 2 ? -1 : -2; - } - function utf8CheckIncomplete(self2, buf, i) { - var j = buf.length - 1; - if (j < i) return 0; - var nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) self2.lastNeed = nb - 1; - return nb; - } - if (--j < i || nb === -2) return 0; - nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) self2.lastNeed = nb - 2; - return nb; - } - if (--j < i || nb === -2) return 0; - nb = utf8CheckByte(buf[j]); - if (nb >= 0) { - if (nb > 0) { - if (nb === 2) nb = 0; - else self2.lastNeed = nb - 3; - } - return nb; - } - return 0; - } - function utf8CheckExtraBytes(self2, buf, p) { - if ((buf[0] & 192) !== 128) { - self2.lastNeed = 0; - return "\uFFFD"; - } - if (self2.lastNeed > 1 && buf.length > 1) { - if ((buf[1] & 192) !== 128) { - self2.lastNeed = 1; - return "\uFFFD"; - } - if (self2.lastNeed > 2 && buf.length > 2) { - if ((buf[2] & 192) !== 128) { - self2.lastNeed = 2; - return "\uFFFD"; - } - } - } - } - function utf8FillLast(buf) { - var p = this.lastTotal - this.lastNeed; - var r = utf8CheckExtraBytes(this, buf, p); - if (r !== void 0) return r; - if (this.lastNeed <= buf.length) { - buf.copy(this.lastChar, p, 0, this.lastNeed); - return this.lastChar.toString(this.encoding, 0, this.lastTotal); - } - buf.copy(this.lastChar, p, 0, buf.length); - this.lastNeed -= buf.length; - } - function utf8Text(buf, i) { - var total = utf8CheckIncomplete(this, buf, i); - if (!this.lastNeed) return buf.toString("utf8", i); - this.lastTotal = total; - var end = buf.length - (total - this.lastNeed); - buf.copy(this.lastChar, 0, end); - return buf.toString("utf8", i, end); - } - function utf8End(buf) { - var r = buf && buf.length ? this.write(buf) : ""; - if (this.lastNeed) return r + "\uFFFD"; - return r; - } - function utf16Text(buf, i) { - if ((buf.length - i) % 2 === 0) { - var r = buf.toString("utf16le", i); - if (r) { - var c = r.charCodeAt(r.length - 1); - if (c >= 55296 && c <= 56319) { - this.lastNeed = 2; - this.lastTotal = 4; - this.lastChar[0] = buf[buf.length - 2]; - this.lastChar[1] = buf[buf.length - 1]; - return r.slice(0, -1); - } - } - return r; - } - this.lastNeed = 1; - this.lastTotal = 2; - this.lastChar[0] = buf[buf.length - 1]; - return buf.toString("utf16le", i, buf.length - 1); - } - function utf16End(buf) { - var r = buf && buf.length ? this.write(buf) : ""; - if (this.lastNeed) { - var end = this.lastTotal - this.lastNeed; - return r + this.lastChar.toString("utf16le", 0, end); - } - return r; - } - function base64Text(buf, i) { - var n = (buf.length - i) % 3; - if (n === 0) return buf.toString("base64", i); - this.lastNeed = 3 - n; - this.lastTotal = 3; - if (n === 1) { - this.lastChar[0] = buf[buf.length - 1]; - } else { - this.lastChar[0] = buf[buf.length - 2]; - this.lastChar[1] = buf[buf.length - 1]; - } - return buf.toString("base64", i, buf.length - n); - } - function base64End(buf) { - var r = buf && buf.length ? this.write(buf) : ""; - if (this.lastNeed) return r + this.lastChar.toString("base64", 0, 3 - this.lastNeed); - return r; - } - function simpleWrite(buf) { - return buf.toString(this.encoding); - } - function simpleEnd(buf) { - return buf && buf.length ? this.write(buf) : ""; - } - } -}); - -// node_modules/readable-stream/lib/_stream_readable.js -var require_stream_readable = __commonJS({ - "node_modules/readable-stream/lib/_stream_readable.js"(exports2, module3) { - "use strict"; - var pna = require_process_nextick_args(); - module3.exports = Readable; - var isArray = require_isarray(); - var Duplex; - Readable.ReadableState = ReadableState; - var EE = require("events").EventEmitter; - var EElistenerCount = function(emitter, type2) { - return emitter.listeners(type2).length; - }; - var Stream = require_stream(); - var Buffer3 = require_safe_buffer().Buffer; - var OurUint8Array = (typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : typeof self !== "undefined" ? self : {}).Uint8Array || function() { - }; - function _uint8ArrayToBuffer(chunk) { - return Buffer3.from(chunk); - } - function _isUint8Array(obj) { - return Buffer3.isBuffer(obj) || obj instanceof OurUint8Array; - } - var util = Object.create(require_util()); - util.inherits = require_inherits(); - var debugUtil = require("util"); - var debug = void 0; - if (debugUtil && debugUtil.debuglog) { - debug = debugUtil.debuglog("stream"); - } else { - debug = function() { - }; - } - var BufferList = require_BufferList(); - var destroyImpl = require_destroy(); - var StringDecoder; - util.inherits(Readable, Stream); - var kProxyEvents = ["error", "close", "destroy", "pause", "resume"]; - function prependListener(emitter, event, fn) { - if (typeof emitter.prependListener === "function") return emitter.prependListener(event, fn); - if (!emitter._events || !emitter._events[event]) emitter.on(event, fn); - else if (isArray(emitter._events[event])) emitter._events[event].unshift(fn); - else emitter._events[event] = [fn, emitter._events[event]]; - } - function ReadableState(options2, stream2) { - Duplex = Duplex || require_stream_duplex(); - options2 = options2 || {}; - var isDuplex = stream2 instanceof Duplex; - this.objectMode = !!options2.objectMode; - if (isDuplex) this.objectMode = this.objectMode || !!options2.readableObjectMode; - var hwm = options2.highWaterMark; - var readableHwm = options2.readableHighWaterMark; - var defaultHwm = this.objectMode ? 16 : 16 * 1024; - if (hwm || hwm === 0) this.highWaterMark = hwm; - else if (isDuplex && (readableHwm || readableHwm === 0)) this.highWaterMark = readableHwm; - else this.highWaterMark = defaultHwm; - this.highWaterMark = Math.floor(this.highWaterMark); - this.buffer = new BufferList(); - this.length = 0; - this.pipes = null; - this.pipesCount = 0; - this.flowing = null; - this.ended = false; - this.endEmitted = false; - this.reading = false; - this.sync = true; - this.needReadable = false; - this.emittedReadable = false; - this.readableListening = false; - this.resumeScheduled = false; - this.destroyed = false; - this.defaultEncoding = options2.defaultEncoding || "utf8"; - this.awaitDrain = 0; - this.readingMore = false; - this.decoder = null; - this.encoding = null; - if (options2.encoding) { - if (!StringDecoder) StringDecoder = require_string_decoder().StringDecoder; - this.decoder = new StringDecoder(options2.encoding); - this.encoding = options2.encoding; - } - } - function Readable(options2) { - Duplex = Duplex || require_stream_duplex(); - if (!(this instanceof Readable)) return new Readable(options2); - this._readableState = new ReadableState(options2, this); - this.readable = true; - if (options2) { - if (typeof options2.read === "function") this._read = options2.read; - if (typeof options2.destroy === "function") this._destroy = options2.destroy; - } - Stream.call(this); - } - Object.defineProperty(Readable.prototype, "destroyed", { - get: function() { - if (this._readableState === void 0) { - return false; - } - return this._readableState.destroyed; - }, - set: function(value) { - if (!this._readableState) { - return; - } - this._readableState.destroyed = value; - } - }); - Readable.prototype.destroy = destroyImpl.destroy; - Readable.prototype._undestroy = destroyImpl.undestroy; - Readable.prototype._destroy = function(err, cb) { - this.push(null); - cb(err); - }; - Readable.prototype.push = function(chunk, encoding) { - var state = this._readableState; - var skipChunkCheck; - if (!state.objectMode) { - if (typeof chunk === "string") { - encoding = encoding || state.defaultEncoding; - if (encoding !== state.encoding) { - chunk = Buffer3.from(chunk, encoding); - encoding = ""; - } - skipChunkCheck = true; - } - } else { - skipChunkCheck = true; - } - return readableAddChunk(this, chunk, encoding, false, skipChunkCheck); - }; - Readable.prototype.unshift = function(chunk) { - return readableAddChunk(this, chunk, null, true, false); - }; - function readableAddChunk(stream2, chunk, encoding, addToFront, skipChunkCheck) { - var state = stream2._readableState; - if (chunk === null) { - state.reading = false; - onEofChunk(stream2, state); - } else { - var er; - if (!skipChunkCheck) er = chunkInvalid(state, chunk); - if (er) { - stream2.emit("error", er); - } else if (state.objectMode || chunk && chunk.length > 0) { - if (typeof chunk !== "string" && !state.objectMode && Object.getPrototypeOf(chunk) !== Buffer3.prototype) { - chunk = _uint8ArrayToBuffer(chunk); - } - if (addToFront) { - if (state.endEmitted) stream2.emit("error", new Error("stream.unshift() after end event")); - else addChunk(stream2, state, chunk, true); - } else if (state.ended) { - stream2.emit("error", new Error("stream.push() after EOF")); - } else { - state.reading = false; - if (state.decoder && !encoding) { - chunk = state.decoder.write(chunk); - if (state.objectMode || chunk.length !== 0) addChunk(stream2, state, chunk, false); - else maybeReadMore(stream2, state); - } else { - addChunk(stream2, state, chunk, false); - } - } - } else if (!addToFront) { - state.reading = false; - } - } - return needMoreData(state); - } - function addChunk(stream2, state, chunk, addToFront) { - if (state.flowing && state.length === 0 && !state.sync) { - stream2.emit("data", chunk); - stream2.read(0); - } else { - state.length += state.objectMode ? 1 : chunk.length; - if (addToFront) state.buffer.unshift(chunk); - else state.buffer.push(chunk); - if (state.needReadable) emitReadable(stream2); - } - maybeReadMore(stream2, state); - } - function chunkInvalid(state, chunk) { - var er; - if (!_isUint8Array(chunk) && typeof chunk !== "string" && chunk !== void 0 && !state.objectMode) { - er = new TypeError("Invalid non-string/buffer chunk"); - } - return er; - } - function needMoreData(state) { - return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0); - } - Readable.prototype.isPaused = function() { - return this._readableState.flowing === false; - }; - Readable.prototype.setEncoding = function(enc) { - if (!StringDecoder) StringDecoder = require_string_decoder().StringDecoder; - this._readableState.decoder = new StringDecoder(enc); - this._readableState.encoding = enc; - return this; - }; - var MAX_HWM = 8388608; - function computeNewHighWaterMark(n) { - if (n >= MAX_HWM) { - n = MAX_HWM; - } else { - n--; - n |= n >>> 1; - n |= n >>> 2; - n |= n >>> 4; - n |= n >>> 8; - n |= n >>> 16; - n++; - } - return n; - } - function howMuchToRead(n, state) { - if (n <= 0 || state.length === 0 && state.ended) return 0; - if (state.objectMode) return 1; - if (n !== n) { - if (state.flowing && state.length) return state.buffer.head.data.length; - else return state.length; - } - if (n > state.highWaterMark) state.highWaterMark = computeNewHighWaterMark(n); - if (n <= state.length) return n; - if (!state.ended) { - state.needReadable = true; - return 0; - } - return state.length; - } - Readable.prototype.read = function(n) { - debug("read", n); - n = parseInt(n, 10); - var state = this._readableState; - var nOrig = n; - if (n !== 0) state.emittedReadable = false; - if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) { - debug("read: emitReadable", state.length, state.ended); - if (state.length === 0 && state.ended) endReadable(this); - else emitReadable(this); - return null; - } - n = howMuchToRead(n, state); - if (n === 0 && state.ended) { - if (state.length === 0) endReadable(this); - return null; - } - var doRead = state.needReadable; - debug("need readable", doRead); - if (state.length === 0 || state.length - n < state.highWaterMark) { - doRead = true; - debug("length less than watermark", doRead); - } - if (state.ended || state.reading) { - doRead = false; - debug("reading or ended", doRead); - } else if (doRead) { - debug("do read"); - state.reading = true; - state.sync = true; - if (state.length === 0) state.needReadable = true; - this._read(state.highWaterMark); - state.sync = false; - if (!state.reading) n = howMuchToRead(nOrig, state); - } - var ret; - if (n > 0) ret = fromList(n, state); - else ret = null; - if (ret === null) { - state.needReadable = true; - n = 0; - } else { - state.length -= n; - } - if (state.length === 0) { - if (!state.ended) state.needReadable = true; - if (nOrig !== n && state.ended) endReadable(this); - } - if (ret !== null) this.emit("data", ret); - return ret; - }; - function onEofChunk(stream2, state) { - if (state.ended) return; - if (state.decoder) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) { - state.buffer.push(chunk); - state.length += state.objectMode ? 1 : chunk.length; - } - } - state.ended = true; - emitReadable(stream2); - } - function emitReadable(stream2) { - var state = stream2._readableState; - state.needReadable = false; - if (!state.emittedReadable) { - debug("emitReadable", state.flowing); - state.emittedReadable = true; - if (state.sync) pna.nextTick(emitReadable_, stream2); - else emitReadable_(stream2); - } - } - function emitReadable_(stream2) { - debug("emit readable"); - stream2.emit("readable"); - flow(stream2); - } - function maybeReadMore(stream2, state) { - if (!state.readingMore) { - state.readingMore = true; - pna.nextTick(maybeReadMore_, stream2, state); - } - } - function maybeReadMore_(stream2, state) { - var len = state.length; - while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) { - debug("maybeReadMore read 0"); - stream2.read(0); - if (len === state.length) - break; - else len = state.length; - } - state.readingMore = false; - } - Readable.prototype._read = function(n) { - this.emit("error", new Error("_read() is not implemented")); - }; - Readable.prototype.pipe = function(dest, pipeOpts) { - var src = this; - var state = this._readableState; - switch (state.pipesCount) { - case 0: - state.pipes = dest; - break; - case 1: - state.pipes = [state.pipes, dest]; - break; - default: - state.pipes.push(dest); - break; - } - state.pipesCount += 1; - debug("pipe count=%d opts=%j", state.pipesCount, pipeOpts); - var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr; - var endFn = doEnd ? onend : unpipe; - if (state.endEmitted) pna.nextTick(endFn); - else src.once("end", endFn); - dest.on("unpipe", onunpipe); - function onunpipe(readable, unpipeInfo) { - debug("onunpipe"); - if (readable === src) { - if (unpipeInfo && unpipeInfo.hasUnpiped === false) { - unpipeInfo.hasUnpiped = true; - cleanup(); - } - } - } - function onend() { - debug("onend"); - dest.end(); - } - var ondrain = pipeOnDrain(src); - dest.on("drain", ondrain); - var cleanedUp = false; - function cleanup() { - debug("cleanup"); - dest.removeListener("close", onclose); - dest.removeListener("finish", onfinish); - dest.removeListener("drain", ondrain); - dest.removeListener("error", onerror); - dest.removeListener("unpipe", onunpipe); - src.removeListener("end", onend); - src.removeListener("end", unpipe); - src.removeListener("data", ondata); - cleanedUp = true; - if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain)) ondrain(); - } - var increasedAwaitDrain = false; - src.on("data", ondata); - function ondata(chunk) { - debug("ondata"); - increasedAwaitDrain = false; - var ret = dest.write(chunk); - if (false === ret && !increasedAwaitDrain) { - if ((state.pipesCount === 1 && state.pipes === dest || state.pipesCount > 1 && indexOf(state.pipes, dest) !== -1) && !cleanedUp) { - debug("false write response, pause", state.awaitDrain); - state.awaitDrain++; - increasedAwaitDrain = true; - } - src.pause(); - } - } - function onerror(er) { - debug("onerror", er); - unpipe(); - dest.removeListener("error", onerror); - if (EElistenerCount(dest, "error") === 0) dest.emit("error", er); - } - prependListener(dest, "error", onerror); - function onclose() { - dest.removeListener("finish", onfinish); - unpipe(); - } - dest.once("close", onclose); - function onfinish() { - debug("onfinish"); - dest.removeListener("close", onclose); - unpipe(); - } - dest.once("finish", onfinish); - function unpipe() { - debug("unpipe"); - src.unpipe(dest); - } - dest.emit("pipe", src); - if (!state.flowing) { - debug("pipe resume"); - src.resume(); - } - return dest; - }; - function pipeOnDrain(src) { - return function() { - var state = src._readableState; - debug("pipeOnDrain", state.awaitDrain); - if (state.awaitDrain) state.awaitDrain--; - if (state.awaitDrain === 0 && EElistenerCount(src, "data")) { - state.flowing = true; - flow(src); - } - }; - } - Readable.prototype.unpipe = function(dest) { - var state = this._readableState; - var unpipeInfo = { hasUnpiped: false }; - if (state.pipesCount === 0) return this; - if (state.pipesCount === 1) { - if (dest && dest !== state.pipes) return this; - if (!dest) dest = state.pipes; - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - if (dest) dest.emit("unpipe", this, unpipeInfo); - return this; - } - if (!dest) { - var dests = state.pipes; - var len = state.pipesCount; - state.pipes = null; - state.pipesCount = 0; - state.flowing = false; - for (var i = 0; i < len; i++) { - dests[i].emit("unpipe", this, { hasUnpiped: false }); - } - return this; - } - var index4 = indexOf(state.pipes, dest); - if (index4 === -1) return this; - state.pipes.splice(index4, 1); - state.pipesCount -= 1; - if (state.pipesCount === 1) state.pipes = state.pipes[0]; - dest.emit("unpipe", this, unpipeInfo); - return this; - }; - Readable.prototype.on = function(ev, fn) { - var res = Stream.prototype.on.call(this, ev, fn); - if (ev === "data") { - if (this._readableState.flowing !== false) this.resume(); - } else if (ev === "readable") { - var state = this._readableState; - if (!state.endEmitted && !state.readableListening) { - state.readableListening = state.needReadable = true; - state.emittedReadable = false; - if (!state.reading) { - pna.nextTick(nReadingNextTick, this); - } else if (state.length) { - emitReadable(this); - } - } - } - return res; - }; - Readable.prototype.addListener = Readable.prototype.on; - function nReadingNextTick(self2) { - debug("readable nexttick read 0"); - self2.read(0); - } - Readable.prototype.resume = function() { - var state = this._readableState; - if (!state.flowing) { - debug("resume"); - state.flowing = true; - resume(this, state); - } - return this; - }; - function resume(stream2, state) { - if (!state.resumeScheduled) { - state.resumeScheduled = true; - pna.nextTick(resume_, stream2, state); - } - } - function resume_(stream2, state) { - if (!state.reading) { - debug("resume read 0"); - stream2.read(0); - } - state.resumeScheduled = false; - state.awaitDrain = 0; - stream2.emit("resume"); - flow(stream2); - if (state.flowing && !state.reading) stream2.read(0); - } - Readable.prototype.pause = function() { - debug("call pause flowing=%j", this._readableState.flowing); - if (false !== this._readableState.flowing) { - debug("pause"); - this._readableState.flowing = false; - this.emit("pause"); - } - return this; - }; - function flow(stream2) { - var state = stream2._readableState; - debug("flow", state.flowing); - while (state.flowing && stream2.read() !== null) { - } - } - Readable.prototype.wrap = function(stream2) { - var _this = this; - var state = this._readableState; - var paused = false; - stream2.on("end", function() { - debug("wrapped end"); - if (state.decoder && !state.ended) { - var chunk = state.decoder.end(); - if (chunk && chunk.length) _this.push(chunk); - } - _this.push(null); - }); - stream2.on("data", function(chunk) { - debug("wrapped data"); - if (state.decoder) chunk = state.decoder.write(chunk); - if (state.objectMode && (chunk === null || chunk === void 0)) return; - else if (!state.objectMode && (!chunk || !chunk.length)) return; - var ret = _this.push(chunk); - if (!ret) { - paused = true; - stream2.pause(); - } - }); - for (var i in stream2) { - if (this[i] === void 0 && typeof stream2[i] === "function") { - this[i] = /* @__PURE__ */ (function(method) { - return function() { - return stream2[method].apply(stream2, arguments); - }; - })(i); - } - } - for (var n = 0; n < kProxyEvents.length; n++) { - stream2.on(kProxyEvents[n], this.emit.bind(this, kProxyEvents[n])); - } - this._read = function(n2) { - debug("wrapped _read", n2); - if (paused) { - paused = false; - stream2.resume(); - } - }; - return this; - }; - Object.defineProperty(Readable.prototype, "readableHighWaterMark", { - // making it explicit this property is not enumerable - // because otherwise some prototype manipulation in - // userland will fail - enumerable: false, - get: function() { - return this._readableState.highWaterMark; - } - }); - Readable._fromList = fromList; - function fromList(n, state) { - if (state.length === 0) return null; - var ret; - if (state.objectMode) ret = state.buffer.shift(); - else if (!n || n >= state.length) { - if (state.decoder) ret = state.buffer.join(""); - else if (state.buffer.length === 1) ret = state.buffer.head.data; - else ret = state.buffer.concat(state.length); - state.buffer.clear(); - } else { - ret = fromListPartial(n, state.buffer, state.decoder); - } - return ret; - } - function fromListPartial(n, list4, hasStrings) { - var ret; - if (n < list4.head.data.length) { - ret = list4.head.data.slice(0, n); - list4.head.data = list4.head.data.slice(n); - } else if (n === list4.head.data.length) { - ret = list4.shift(); - } else { - ret = hasStrings ? copyFromBufferString(n, list4) : copyFromBuffer(n, list4); - } - return ret; - } - function copyFromBufferString(n, list4) { - var p = list4.head; - var c = 1; - var ret = p.data; - n -= ret.length; - while (p = p.next) { - var str = p.data; - var nb = n > str.length ? str.length : n; - if (nb === str.length) ret += str; - else ret += str.slice(0, n); - n -= nb; - if (n === 0) { - if (nb === str.length) { - ++c; - if (p.next) list4.head = p.next; - else list4.head = list4.tail = null; - } else { - list4.head = p; - p.data = str.slice(nb); - } - break; - } - ++c; - } - list4.length -= c; - return ret; - } - function copyFromBuffer(n, list4) { - var ret = Buffer3.allocUnsafe(n); - var p = list4.head; - var c = 1; - p.data.copy(ret); - n -= p.data.length; - while (p = p.next) { - var buf = p.data; - var nb = n > buf.length ? buf.length : n; - buf.copy(ret, ret.length - n, 0, nb); - n -= nb; - if (n === 0) { - if (nb === buf.length) { - ++c; - if (p.next) list4.head = p.next; - else list4.head = list4.tail = null; - } else { - list4.head = p; - p.data = buf.slice(nb); - } - break; - } - ++c; - } - list4.length -= c; - return ret; - } - function endReadable(stream2) { - var state = stream2._readableState; - if (state.length > 0) throw new Error('"endReadable()" called on non-empty stream'); - if (!state.endEmitted) { - state.ended = true; - pna.nextTick(endReadableNT, state, stream2); - } - } - function endReadableNT(state, stream2) { - if (!state.endEmitted && state.length === 0) { - state.endEmitted = true; - stream2.readable = false; - stream2.emit("end"); - } - } - function indexOf(xs, x) { - for (var i = 0, l = xs.length; i < l; i++) { - if (xs[i] === x) return i; - } - return -1; - } - } -}); - -// node_modules/readable-stream/lib/_stream_transform.js -var require_stream_transform = __commonJS({ - "node_modules/readable-stream/lib/_stream_transform.js"(exports2, module3) { - "use strict"; - module3.exports = Transform; - var Duplex = require_stream_duplex(); - var util = Object.create(require_util()); - util.inherits = require_inherits(); - util.inherits(Transform, Duplex); - function afterTransform(er, data) { - var ts = this._transformState; - ts.transforming = false; - var cb = ts.writecb; - if (!cb) { - return this.emit("error", new Error("write callback called multiple times")); - } - ts.writechunk = null; - ts.writecb = null; - if (data != null) - this.push(data); - cb(er); - var rs = this._readableState; - rs.reading = false; - if (rs.needReadable || rs.length < rs.highWaterMark) { - this._read(rs.highWaterMark); - } - } - function Transform(options2) { - if (!(this instanceof Transform)) return new Transform(options2); - Duplex.call(this, options2); - this._transformState = { - afterTransform: afterTransform.bind(this), - needTransform: false, - transforming: false, - writecb: null, - writechunk: null, - writeencoding: null - }; - this._readableState.needReadable = true; - this._readableState.sync = false; - if (options2) { - if (typeof options2.transform === "function") this._transform = options2.transform; - if (typeof options2.flush === "function") this._flush = options2.flush; - } - this.on("prefinish", prefinish); - } - function prefinish() { - var _this = this; - if (typeof this._flush === "function") { - this._flush(function(er, data) { - done(_this, er, data); - }); - } else { - done(this, null, null); - } - } - Transform.prototype.push = function(chunk, encoding) { - this._transformState.needTransform = false; - return Duplex.prototype.push.call(this, chunk, encoding); - }; - Transform.prototype._transform = function(chunk, encoding, cb) { - throw new Error("_transform() is not implemented"); - }; - Transform.prototype._write = function(chunk, encoding, cb) { - var ts = this._transformState; - ts.writecb = cb; - ts.writechunk = chunk; - ts.writeencoding = encoding; - if (!ts.transforming) { - var rs = this._readableState; - if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark) this._read(rs.highWaterMark); - } - }; - Transform.prototype._read = function(n) { - var ts = this._transformState; - if (ts.writechunk !== null && ts.writecb && !ts.transforming) { - ts.transforming = true; - this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); - } else { - ts.needTransform = true; - } - }; - Transform.prototype._destroy = function(err, cb) { - var _this2 = this; - Duplex.prototype._destroy.call(this, err, function(err2) { - cb(err2); - _this2.emit("close"); - }); - }; - function done(stream2, er, data) { - if (er) return stream2.emit("error", er); - if (data != null) - stream2.push(data); - if (stream2._writableState.length) throw new Error("Calling transform done when ws.length != 0"); - if (stream2._transformState.transforming) throw new Error("Calling transform done when still transforming"); - return stream2.push(null); - } - } -}); - -// node_modules/readable-stream/lib/_stream_passthrough.js -var require_stream_passthrough = __commonJS({ - "node_modules/readable-stream/lib/_stream_passthrough.js"(exports2, module3) { - "use strict"; - module3.exports = PassThrough; - var Transform = require_stream_transform(); - var util = Object.create(require_util()); - util.inherits = require_inherits(); - util.inherits(PassThrough, Transform); - function PassThrough(options2) { - if (!(this instanceof PassThrough)) return new PassThrough(options2); - Transform.call(this, options2); - } - PassThrough.prototype._transform = function(chunk, encoding, cb) { - cb(null, chunk); - }; - } -}); - -// node_modules/readable-stream/readable.js -var require_readable = __commonJS({ - "node_modules/readable-stream/readable.js"(exports2, module3) { - var Stream = require("stream"); - if (process.env.READABLE_STREAM === "disable" && Stream) { - module3.exports = Stream; - exports2 = module3.exports = Stream.Readable; - exports2.Readable = Stream.Readable; - exports2.Writable = Stream.Writable; - exports2.Duplex = Stream.Duplex; - exports2.Transform = Stream.Transform; - exports2.PassThrough = Stream.PassThrough; - exports2.Stream = Stream; - } else { - exports2 = module3.exports = require_stream_readable(); - exports2.Stream = Stream || exports2; - exports2.Readable = exports2; - exports2.Writable = require_stream_writable(); - exports2.Duplex = require_stream_duplex(); - exports2.Transform = require_stream_transform(); - exports2.PassThrough = require_stream_passthrough(); - } - } -}); - -// node_modules/readable-stream/duplex.js -var require_duplex = __commonJS({ - "node_modules/readable-stream/duplex.js"(exports2, module3) { - module3.exports = require_readable().Duplex; - } -}); - -// node_modules/safe-buffer/index.js -var require_safe_buffer3 = __commonJS({ - "node_modules/safe-buffer/index.js"(exports2, module3) { - var buffer = require("buffer"); - var Buffer3 = buffer.Buffer; - function copyProps(src, dst) { - for (var key2 in src) { - dst[key2] = src[key2]; - } - } - if (Buffer3.from && Buffer3.alloc && Buffer3.allocUnsafe && Buffer3.allocUnsafeSlow) { - module3.exports = buffer; - } else { - copyProps(buffer, exports2); - exports2.Buffer = SafeBuffer; - } - function SafeBuffer(arg, encodingOrOffset, length) { - return Buffer3(arg, encodingOrOffset, length); - } - SafeBuffer.prototype = Object.create(Buffer3.prototype); - copyProps(Buffer3, SafeBuffer); - SafeBuffer.from = function(arg, encodingOrOffset, length) { - if (typeof arg === "number") { - throw new TypeError("Argument must not be a number"); - } - return Buffer3(arg, encodingOrOffset, length); - }; - SafeBuffer.alloc = function(size, fill, encoding) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - var buf = Buffer3(size); - if (fill !== void 0) { - if (typeof encoding === "string") { - buf.fill(fill, encoding); - } else { - buf.fill(fill); - } - } else { - buf.fill(0); - } - return buf; - }; - SafeBuffer.allocUnsafe = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return Buffer3(size); - }; - SafeBuffer.allocUnsafeSlow = function(size) { - if (typeof size !== "number") { - throw new TypeError("Argument must be a number"); - } - return buffer.SlowBuffer(size); - }; - } -}); - -// node_modules/bl/bl.js -var require_bl = __commonJS({ - "node_modules/bl/bl.js"(exports2, module3) { - var DuplexStream = require_duplex(); - var util = require("util"); - var Buffer3 = require_safe_buffer3().Buffer; - function BufferList(callback) { - if (!(this instanceof BufferList)) - return new BufferList(callback); - this._bufs = []; - this.length = 0; - if (typeof callback == "function") { - this._callback = callback; - var piper = function piper2(err) { - if (this._callback) { - this._callback(err); - this._callback = null; - } - }.bind(this); - this.on("pipe", function onPipe(src) { - src.on("error", piper); - }); - this.on("unpipe", function onUnpipe(src) { - src.removeListener("error", piper); - }); - } else { - this.append(callback); - } - DuplexStream.call(this); - } - util.inherits(BufferList, DuplexStream); - BufferList.prototype._offset = function _offset(offset) { - var tot = 0, i = 0, _t; - if (offset === 0) return [0, 0]; - for (; i < this._bufs.length; i++) { - _t = tot + this._bufs[i].length; - if (offset < _t || i == this._bufs.length - 1) - return [i, offset - tot]; - tot = _t; - } - }; - BufferList.prototype.append = function append(buf) { - var i = 0; - if (Buffer3.isBuffer(buf)) { - this._appendBuffer(buf); - } else if (Array.isArray(buf)) { - for (; i < buf.length; i++) - this.append(buf[i]); - } else if (buf instanceof BufferList) { - for (; i < buf._bufs.length; i++) - this.append(buf._bufs[i]); - } else if (buf != null) { - if (typeof buf == "number") - buf = buf.toString(); - this._appendBuffer(Buffer3.from(buf)); - } - return this; - }; - BufferList.prototype._appendBuffer = function appendBuffer(buf) { - this._bufs.push(buf); - this.length += buf.length; - }; - BufferList.prototype._write = function _write(buf, encoding, callback) { - this._appendBuffer(buf); - if (typeof callback == "function") - callback(); - }; - BufferList.prototype._read = function _read(size) { - if (!this.length) - return this.push(null); - size = Math.min(size, this.length); - this.push(this.slice(0, size)); - this.consume(size); - }; - BufferList.prototype.end = function end(chunk) { - DuplexStream.prototype.end.call(this, chunk); - if (this._callback) { - this._callback(null, this.slice()); - this._callback = null; - } - }; - BufferList.prototype.get = function get(index4) { - return this.slice(index4, index4 + 1)[0]; - }; - BufferList.prototype.slice = function slice(start, end) { - if (typeof start == "number" && start < 0) - start += this.length; - if (typeof end == "number" && end < 0) - end += this.length; - return this.copy(null, 0, start, end); - }; - BufferList.prototype.copy = function copy(dst, dstStart, srcStart, srcEnd) { - if (typeof srcStart != "number" || srcStart < 0) - srcStart = 0; - if (typeof srcEnd != "number" || srcEnd > this.length) - srcEnd = this.length; - if (srcStart >= this.length) - return dst || Buffer3.alloc(0); - if (srcEnd <= 0) - return dst || Buffer3.alloc(0); - var copy2 = !!dst, off = this._offset(srcStart), len = srcEnd - srcStart, bytes = len, bufoff = copy2 && dstStart || 0, start = off[1], l, i; - if (srcStart === 0 && srcEnd == this.length) { - if (!copy2) { - return this._bufs.length === 1 ? this._bufs[0] : Buffer3.concat(this._bufs, this.length); - } - for (i = 0; i < this._bufs.length; i++) { - this._bufs[i].copy(dst, bufoff); - bufoff += this._bufs[i].length; - } - return dst; - } - if (bytes <= this._bufs[off[0]].length - start) { - return copy2 ? this._bufs[off[0]].copy(dst, dstStart, start, start + bytes) : this._bufs[off[0]].slice(start, start + bytes); - } - if (!copy2) - dst = Buffer3.allocUnsafe(len); - for (i = off[0]; i < this._bufs.length; i++) { - l = this._bufs[i].length - start; - if (bytes > l) { - this._bufs[i].copy(dst, bufoff, start); - bufoff += l; - } else { - this._bufs[i].copy(dst, bufoff, start, start + bytes); - bufoff += l; - break; - } - bytes -= l; - if (start) - start = 0; - } - if (dst.length > bufoff) return dst.slice(0, bufoff); - return dst; - }; - BufferList.prototype.shallowSlice = function shallowSlice(start, end) { - start = start || 0; - end = end || this.length; - if (start < 0) - start += this.length; - if (end < 0) - end += this.length; - var startOffset = this._offset(start), endOffset = this._offset(end), buffers = this._bufs.slice(startOffset[0], endOffset[0] + 1); - if (endOffset[1] == 0) - buffers.pop(); - else - buffers[buffers.length - 1] = buffers[buffers.length - 1].slice(0, endOffset[1]); - if (startOffset[1] != 0) - buffers[0] = buffers[0].slice(startOffset[1]); - return new BufferList(buffers); - }; - BufferList.prototype.toString = function toString(encoding, start, end) { - return this.slice(start, end).toString(encoding); - }; - BufferList.prototype.consume = function consume(bytes) { - bytes = Math.trunc(bytes); - if (Number.isNaN(bytes) || bytes <= 0) return this; - while (this._bufs.length) { - if (bytes >= this._bufs[0].length) { - bytes -= this._bufs[0].length; - this.length -= this._bufs[0].length; - this._bufs.shift(); - } else { - this._bufs[0] = this._bufs[0].slice(bytes); - this.length -= bytes; - break; - } - } - return this; - }; - BufferList.prototype.duplicate = function duplicate() { - var i = 0, copy = new BufferList(); - for (; i < this._bufs.length; i++) - copy.append(this._bufs[i]); - return copy; - }; - BufferList.prototype.destroy = function destroy() { - this._bufs.length = 0; - this.length = 0; - this.push(null); - }; - (function() { - var methods = { - "readDoubleBE": 8, - "readDoubleLE": 8, - "readFloatBE": 4, - "readFloatLE": 4, - "readInt32BE": 4, - "readInt32LE": 4, - "readUInt32BE": 4, - "readUInt32LE": 4, - "readInt16BE": 2, - "readInt16LE": 2, - "readUInt16BE": 2, - "readUInt16LE": 2, - "readInt8": 1, - "readUInt8": 1 - }; - for (var m in methods) { - (function(m2) { - BufferList.prototype[m2] = function(offset) { - return this.slice(offset, offset + methods[m2])[m2](0); - }; - })(m); - } - })(); - module3.exports = BufferList; - } -}); - -// node_modules/xtend/immutable.js -var require_immutable = __commonJS({ - "node_modules/xtend/immutable.js"(exports2, module3) { - module3.exports = extend; - var hasOwnProperty = Object.prototype.hasOwnProperty; - function extend() { - var target = {}; - for (var i = 0; i < arguments.length; i++) { - var source = arguments[i]; - for (var key2 in source) { - if (hasOwnProperty.call(source, key2)) { - target[key2] = source[key2]; - } - } - } - return target; - } - } -}); - -// node_modules/to-buffer/node_modules/isarray/index.js -var require_isarray2 = __commonJS({ - "node_modules/to-buffer/node_modules/isarray/index.js"(exports2, module3) { - var toString = {}.toString; - module3.exports = Array.isArray || function(arr) { - return toString.call(arr) == "[object Array]"; - }; - } -}); - -// node_modules/es-errors/type.js -var require_type = __commonJS({ - "node_modules/es-errors/type.js"(exports2, module3) { - "use strict"; - module3.exports = TypeError; - } -}); - -// node_modules/es-object-atoms/index.js -var require_es_object_atoms = __commonJS({ - "node_modules/es-object-atoms/index.js"(exports2, module3) { - "use strict"; - module3.exports = Object; - } -}); - -// node_modules/es-errors/index.js -var require_es_errors = __commonJS({ - "node_modules/es-errors/index.js"(exports2, module3) { - "use strict"; - module3.exports = Error; - } -}); - -// node_modules/es-errors/eval.js -var require_eval = __commonJS({ - "node_modules/es-errors/eval.js"(exports2, module3) { - "use strict"; - module3.exports = EvalError; - } -}); - -// node_modules/es-errors/range.js -var require_range = __commonJS({ - "node_modules/es-errors/range.js"(exports2, module3) { - "use strict"; - module3.exports = RangeError; - } -}); - -// node_modules/es-errors/ref.js -var require_ref = __commonJS({ - "node_modules/es-errors/ref.js"(exports2, module3) { - "use strict"; - module3.exports = ReferenceError; - } -}); - -// node_modules/es-errors/syntax.js -var require_syntax = __commonJS({ - "node_modules/es-errors/syntax.js"(exports2, module3) { - "use strict"; - module3.exports = SyntaxError; - } -}); - -// node_modules/es-errors/uri.js -var require_uri = __commonJS({ - "node_modules/es-errors/uri.js"(exports2, module3) { - "use strict"; - module3.exports = URIError; - } -}); - -// node_modules/math-intrinsics/abs.js -var require_abs = __commonJS({ - "node_modules/math-intrinsics/abs.js"(exports2, module3) { - "use strict"; - module3.exports = Math.abs; - } -}); - -// node_modules/math-intrinsics/floor.js -var require_floor = __commonJS({ - "node_modules/math-intrinsics/floor.js"(exports2, module3) { - "use strict"; - module3.exports = Math.floor; - } -}); - -// node_modules/math-intrinsics/max.js -var require_max = __commonJS({ - "node_modules/math-intrinsics/max.js"(exports2, module3) { - "use strict"; - module3.exports = Math.max; - } -}); - -// node_modules/math-intrinsics/min.js -var require_min = __commonJS({ - "node_modules/math-intrinsics/min.js"(exports2, module3) { - "use strict"; - module3.exports = Math.min; - } -}); - -// node_modules/math-intrinsics/pow.js -var require_pow = __commonJS({ - "node_modules/math-intrinsics/pow.js"(exports2, module3) { - "use strict"; - module3.exports = Math.pow; - } -}); - -// node_modules/math-intrinsics/round.js -var require_round = __commonJS({ - "node_modules/math-intrinsics/round.js"(exports2, module3) { - "use strict"; - module3.exports = Math.round; - } -}); - -// node_modules/math-intrinsics/isNaN.js -var require_isNaN = __commonJS({ - "node_modules/math-intrinsics/isNaN.js"(exports2, module3) { - "use strict"; - module3.exports = Number.isNaN || function isNaN2(a) { - return a !== a; - }; - } -}); - -// node_modules/math-intrinsics/sign.js -var require_sign = __commonJS({ - "node_modules/math-intrinsics/sign.js"(exports2, module3) { - "use strict"; - var $isNaN = require_isNaN(); - module3.exports = function sign(number5) { - if ($isNaN(number5) || number5 === 0) { - return number5; - } - return number5 < 0 ? -1 : 1; - }; - } -}); - -// node_modules/gopd/gOPD.js -var require_gOPD = __commonJS({ - "node_modules/gopd/gOPD.js"(exports2, module3) { - "use strict"; - module3.exports = Object.getOwnPropertyDescriptor; - } -}); - -// node_modules/gopd/index.js -var require_gopd = __commonJS({ - "node_modules/gopd/index.js"(exports2, module3) { - "use strict"; - var $gOPD = require_gOPD(); - if ($gOPD) { - try { - $gOPD([], "length"); - } catch (e) { - $gOPD = null; - } - } - module3.exports = $gOPD; - } -}); - -// node_modules/es-define-property/index.js -var require_es_define_property = __commonJS({ - "node_modules/es-define-property/index.js"(exports2, module3) { - "use strict"; - var $defineProperty = Object.defineProperty || false; - if ($defineProperty) { - try { - $defineProperty({}, "a", { value: 1 }); - } catch (e) { - $defineProperty = false; - } - } - module3.exports = $defineProperty; - } -}); - -// node_modules/has-symbols/shams.js -var require_shams = __commonJS({ - "node_modules/has-symbols/shams.js"(exports2, module3) { - "use strict"; - module3.exports = function hasSymbols() { - if (typeof Symbol !== "function" || typeof Object.getOwnPropertySymbols !== "function") { - return false; - } - if (typeof Symbol.iterator === "symbol") { - return true; - } - var obj = {}; - var sym = Symbol("test"); - var symObj = Object(sym); - if (typeof sym === "string") { - return false; - } - if (Object.prototype.toString.call(sym) !== "[object Symbol]") { - return false; - } - if (Object.prototype.toString.call(symObj) !== "[object Symbol]") { - return false; - } - var symVal = 42; - obj[sym] = symVal; - for (var _ in obj) { - return false; - } - if (typeof Object.keys === "function" && Object.keys(obj).length !== 0) { - return false; - } - if (typeof Object.getOwnPropertyNames === "function" && Object.getOwnPropertyNames(obj).length !== 0) { - return false; - } - var syms = Object.getOwnPropertySymbols(obj); - if (syms.length !== 1 || syms[0] !== sym) { - return false; - } - if (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { - return false; - } - if (typeof Object.getOwnPropertyDescriptor === "function") { - var descriptor = ( - /** @type {PropertyDescriptor} */ - Object.getOwnPropertyDescriptor(obj, sym) - ); - if (descriptor.value !== symVal || descriptor.enumerable !== true) { - return false; - } - } - return true; - }; - } -}); - -// node_modules/has-symbols/index.js -var require_has_symbols = __commonJS({ - "node_modules/has-symbols/index.js"(exports2, module3) { - "use strict"; - var origSymbol = typeof Symbol !== "undefined" && Symbol; - var hasSymbolSham = require_shams(); - module3.exports = function hasNativeSymbols() { - if (typeof origSymbol !== "function") { - return false; - } - if (typeof Symbol !== "function") { - return false; - } - if (typeof origSymbol("foo") !== "symbol") { - return false; - } - if (typeof Symbol("bar") !== "symbol") { - return false; - } - return hasSymbolSham(); - }; - } -}); - -// node_modules/get-proto/Reflect.getPrototypeOf.js -var require_Reflect_getPrototypeOf = __commonJS({ - "node_modules/get-proto/Reflect.getPrototypeOf.js"(exports2, module3) { - "use strict"; - module3.exports = typeof Reflect !== "undefined" && Reflect.getPrototypeOf || null; - } -}); - -// node_modules/get-proto/Object.getPrototypeOf.js -var require_Object_getPrototypeOf = __commonJS({ - "node_modules/get-proto/Object.getPrototypeOf.js"(exports2, module3) { - "use strict"; - var $Object = require_es_object_atoms(); - module3.exports = $Object.getPrototypeOf || null; - } -}); - -// node_modules/function-bind/implementation.js -var require_implementation = __commonJS({ - "node_modules/function-bind/implementation.js"(exports2, module3) { - "use strict"; - var ERROR_MESSAGE = "Function.prototype.bind called on incompatible "; - var toStr = Object.prototype.toString; - var max2 = Math.max; - var funcType = "[object Function]"; - var concatty = function concatty2(a, b) { - var arr = []; - for (var i = 0; i < a.length; i += 1) { - arr[i] = a[i]; - } - for (var j = 0; j < b.length; j += 1) { - arr[j + a.length] = b[j]; - } - return arr; - }; - var slicy = function slicy2(arrLike, offset) { - var arr = []; - for (var i = offset || 0, j = 0; i < arrLike.length; i += 1, j += 1) { - arr[j] = arrLike[i]; - } - return arr; - }; - var joiny = function(arr, joiner) { - var str = ""; - for (var i = 0; i < arr.length; i += 1) { - str += arr[i]; - if (i + 1 < arr.length) { - str += joiner; - } - } - return str; - }; - module3.exports = function bind(that) { - var target = this; - if (typeof target !== "function" || toStr.apply(target) !== funcType) { - throw new TypeError(ERROR_MESSAGE + target); - } - var args = slicy(arguments, 1); - var bound; - var binder = function() { - if (this instanceof bound) { - var result = target.apply( - this, - concatty(args, arguments) - ); - if (Object(result) === result) { - return result; - } - return this; - } - return target.apply( - that, - concatty(args, arguments) - ); - }; - var boundLength = max2(0, target.length - args.length); - var boundArgs = []; - for (var i = 0; i < boundLength; i++) { - boundArgs[i] = "$" + i; - } - bound = Function("binder", "return function (" + joiny(boundArgs, ",") + "){ return binder.apply(this,arguments); }")(binder); - if (target.prototype) { - var Empty = function Empty2() { - }; - Empty.prototype = target.prototype; - bound.prototype = new Empty(); - Empty.prototype = null; - } - return bound; - }; - } -}); - -// node_modules/function-bind/index.js -var require_function_bind = __commonJS({ - "node_modules/function-bind/index.js"(exports2, module3) { - "use strict"; - var implementation = require_implementation(); - module3.exports = Function.prototype.bind || implementation; - } -}); - -// node_modules/call-bind-apply-helpers/functionCall.js -var require_functionCall = __commonJS({ - "node_modules/call-bind-apply-helpers/functionCall.js"(exports2, module3) { - "use strict"; - module3.exports = Function.prototype.call; - } -}); - -// node_modules/call-bind-apply-helpers/functionApply.js -var require_functionApply = __commonJS({ - "node_modules/call-bind-apply-helpers/functionApply.js"(exports2, module3) { - "use strict"; - module3.exports = Function.prototype.apply; - } -}); - -// node_modules/call-bind-apply-helpers/reflectApply.js -var require_reflectApply = __commonJS({ - "node_modules/call-bind-apply-helpers/reflectApply.js"(exports2, module3) { - "use strict"; - module3.exports = typeof Reflect !== "undefined" && Reflect && Reflect.apply; - } -}); - -// node_modules/call-bind-apply-helpers/actualApply.js -var require_actualApply = __commonJS({ - "node_modules/call-bind-apply-helpers/actualApply.js"(exports2, module3) { - "use strict"; - var bind = require_function_bind(); - var $apply = require_functionApply(); - var $call = require_functionCall(); - var $reflectApply = require_reflectApply(); - module3.exports = $reflectApply || bind.call($call, $apply); - } -}); - -// node_modules/call-bind-apply-helpers/index.js -var require_call_bind_apply_helpers = __commonJS({ - "node_modules/call-bind-apply-helpers/index.js"(exports2, module3) { - "use strict"; - var bind = require_function_bind(); - var $TypeError = require_type(); - var $call = require_functionCall(); - var $actualApply = require_actualApply(); - module3.exports = function callBindBasic(args) { - if (args.length < 1 || typeof args[0] !== "function") { - throw new $TypeError("a function is required"); - } - return $actualApply(bind, $call, args); - }; - } -}); - -// node_modules/dunder-proto/get.js -var require_get = __commonJS({ - "node_modules/dunder-proto/get.js"(exports2, module3) { - "use strict"; - var callBind = require_call_bind_apply_helpers(); - var gOPD = require_gopd(); - var hasProtoAccessor; - try { - hasProtoAccessor = /** @type {{ __proto__?: typeof Array.prototype }} */ - [].__proto__ === Array.prototype; - } catch (e) { - if (!e || typeof e !== "object" || !("code" in e) || e.code !== "ERR_PROTO_ACCESS") { - throw e; - } - } - var desc = !!hasProtoAccessor && gOPD && gOPD( - Object.prototype, - /** @type {keyof typeof Object.prototype} */ - "__proto__" - ); - var $Object = Object; - var $getPrototypeOf = $Object.getPrototypeOf; - module3.exports = desc && typeof desc.get === "function" ? callBind([desc.get]) : typeof $getPrototypeOf === "function" ? ( - /** @type {import('./get')} */ - function getDunder(value) { - return $getPrototypeOf(value == null ? value : $Object(value)); - } - ) : false; - } -}); - -// node_modules/get-proto/index.js -var require_get_proto = __commonJS({ - "node_modules/get-proto/index.js"(exports2, module3) { - "use strict"; - var reflectGetProto = require_Reflect_getPrototypeOf(); - var originalGetProto = require_Object_getPrototypeOf(); - var getDunderProto = require_get(); - module3.exports = reflectGetProto ? function getProto(O) { - return reflectGetProto(O); - } : originalGetProto ? function getProto(O) { - if (!O || typeof O !== "object" && typeof O !== "function") { - throw new TypeError("getProto: not an object"); - } - return originalGetProto(O); - } : getDunderProto ? function getProto(O) { - return getDunderProto(O); - } : null; - } -}); - -// node_modules/hasown/index.js -var require_hasown = __commonJS({ - "node_modules/hasown/index.js"(exports2, module3) { - "use strict"; - var call = Function.prototype.call; - var $hasOwn = Object.prototype.hasOwnProperty; - var bind = require_function_bind(); - module3.exports = bind.call(call, $hasOwn); - } -}); - -// node_modules/get-intrinsic/index.js -var require_get_intrinsic = __commonJS({ - "node_modules/get-intrinsic/index.js"(exports2, module3) { - "use strict"; - var undefined2; - var $Object = require_es_object_atoms(); - var $Error = require_es_errors(); - var $EvalError = require_eval(); - var $RangeError = require_range(); - var $ReferenceError = require_ref(); - var $SyntaxError = require_syntax(); - var $TypeError = require_type(); - var $URIError = require_uri(); - var abs = require_abs(); - var floor = require_floor(); - var max2 = require_max(); - var min2 = require_min(); - var pow = require_pow(); - var round = require_round(); - var sign = require_sign(); - var $Function = Function; - var getEvalledConstructor = function(expressionSyntax) { - try { - return $Function('"use strict"; return (' + expressionSyntax + ").constructor;")(); - } catch (e) { - } - }; - var $gOPD = require_gopd(); - var $defineProperty = require_es_define_property(); - var throwTypeError = function() { - throw new $TypeError(); - }; - var ThrowTypeError = $gOPD ? (function() { - try { - arguments.callee; - return throwTypeError; - } catch (calleeThrows) { - try { - return $gOPD(arguments, "callee").get; - } catch (gOPDthrows) { - return throwTypeError; - } - } - })() : throwTypeError; - var hasSymbols = require_has_symbols()(); - var getProto = require_get_proto(); - var $ObjectGPO = require_Object_getPrototypeOf(); - var $ReflectGPO = require_Reflect_getPrototypeOf(); - var $apply = require_functionApply(); - var $call = require_functionCall(); - var needsEval = {}; - var TypedArray = typeof Uint8Array === "undefined" || !getProto ? undefined2 : getProto(Uint8Array); - var INTRINSICS = { - __proto__: null, - "%AggregateError%": typeof AggregateError === "undefined" ? undefined2 : AggregateError, - "%Array%": Array, - "%ArrayBuffer%": typeof ArrayBuffer === "undefined" ? undefined2 : ArrayBuffer, - "%ArrayIteratorPrototype%": hasSymbols && getProto ? getProto([][Symbol.iterator]()) : undefined2, - "%AsyncFromSyncIteratorPrototype%": undefined2, - "%AsyncFunction%": needsEval, - "%AsyncGenerator%": needsEval, - "%AsyncGeneratorFunction%": needsEval, - "%AsyncIteratorPrototype%": needsEval, - "%Atomics%": typeof Atomics === "undefined" ? undefined2 : Atomics, - "%BigInt%": typeof BigInt === "undefined" ? undefined2 : BigInt, - "%BigInt64Array%": typeof BigInt64Array === "undefined" ? undefined2 : BigInt64Array, - "%BigUint64Array%": typeof BigUint64Array === "undefined" ? undefined2 : BigUint64Array, - "%Boolean%": Boolean, - "%DataView%": typeof DataView === "undefined" ? undefined2 : DataView, - "%Date%": Date, - "%decodeURI%": decodeURI, - "%decodeURIComponent%": decodeURIComponent, - "%encodeURI%": encodeURI, - "%encodeURIComponent%": encodeURIComponent, - "%Error%": $Error, - "%eval%": eval, - // eslint-disable-line no-eval - "%EvalError%": $EvalError, - "%Float16Array%": typeof Float16Array === "undefined" ? undefined2 : Float16Array, - "%Float32Array%": typeof Float32Array === "undefined" ? undefined2 : Float32Array, - "%Float64Array%": typeof Float64Array === "undefined" ? undefined2 : Float64Array, - "%FinalizationRegistry%": typeof FinalizationRegistry === "undefined" ? undefined2 : FinalizationRegistry, - "%Function%": $Function, - "%GeneratorFunction%": needsEval, - "%Int8Array%": typeof Int8Array === "undefined" ? undefined2 : Int8Array, - "%Int16Array%": typeof Int16Array === "undefined" ? undefined2 : Int16Array, - "%Int32Array%": typeof Int32Array === "undefined" ? undefined2 : Int32Array, - "%isFinite%": isFinite, - "%isNaN%": isNaN, - "%IteratorPrototype%": hasSymbols && getProto ? getProto(getProto([][Symbol.iterator]())) : undefined2, - "%JSON%": typeof JSON === "object" ? JSON : undefined2, - "%Map%": typeof Map === "undefined" ? undefined2 : Map, - "%MapIteratorPrototype%": typeof Map === "undefined" || !hasSymbols || !getProto ? undefined2 : getProto((/* @__PURE__ */ new Map())[Symbol.iterator]()), - "%Math%": Math, - "%Number%": Number, - "%Object%": $Object, - "%Object.getOwnPropertyDescriptor%": $gOPD, - "%parseFloat%": parseFloat, - "%parseInt%": parseInt, - "%Promise%": typeof Promise === "undefined" ? undefined2 : Promise, - "%Proxy%": typeof Proxy === "undefined" ? undefined2 : Proxy, - "%RangeError%": $RangeError, - "%ReferenceError%": $ReferenceError, - "%Reflect%": typeof Reflect === "undefined" ? undefined2 : Reflect, - "%RegExp%": RegExp, - "%Set%": typeof Set === "undefined" ? undefined2 : Set, - "%SetIteratorPrototype%": typeof Set === "undefined" || !hasSymbols || !getProto ? undefined2 : getProto((/* @__PURE__ */ new Set())[Symbol.iterator]()), - "%SharedArrayBuffer%": typeof SharedArrayBuffer === "undefined" ? undefined2 : SharedArrayBuffer, - "%String%": String, - "%StringIteratorPrototype%": hasSymbols && getProto ? getProto(""[Symbol.iterator]()) : undefined2, - "%Symbol%": hasSymbols ? Symbol : undefined2, - "%SyntaxError%": $SyntaxError, - "%ThrowTypeError%": ThrowTypeError, - "%TypedArray%": TypedArray, - "%TypeError%": $TypeError, - "%Uint8Array%": typeof Uint8Array === "undefined" ? undefined2 : Uint8Array, - "%Uint8ClampedArray%": typeof Uint8ClampedArray === "undefined" ? undefined2 : Uint8ClampedArray, - "%Uint16Array%": typeof Uint16Array === "undefined" ? undefined2 : Uint16Array, - "%Uint32Array%": typeof Uint32Array === "undefined" ? undefined2 : Uint32Array, - "%URIError%": $URIError, - "%WeakMap%": typeof WeakMap === "undefined" ? undefined2 : WeakMap, - "%WeakRef%": typeof WeakRef === "undefined" ? undefined2 : WeakRef, - "%WeakSet%": typeof WeakSet === "undefined" ? undefined2 : WeakSet, - "%Function.prototype.call%": $call, - "%Function.prototype.apply%": $apply, - "%Object.defineProperty%": $defineProperty, - "%Object.getPrototypeOf%": $ObjectGPO, - "%Math.abs%": abs, - "%Math.floor%": floor, - "%Math.max%": max2, - "%Math.min%": min2, - "%Math.pow%": pow, - "%Math.round%": round, - "%Math.sign%": sign, - "%Reflect.getPrototypeOf%": $ReflectGPO - }; - if (getProto) { - try { - null.error; - } catch (e) { - errorProto = getProto(getProto(e)); - INTRINSICS["%Error.prototype%"] = errorProto; - } - } - var errorProto; - var doEval = function doEval2(name) { - var value; - if (name === "%AsyncFunction%") { - value = getEvalledConstructor("async function () {}"); - } else if (name === "%GeneratorFunction%") { - value = getEvalledConstructor("function* () {}"); - } else if (name === "%AsyncGeneratorFunction%") { - value = getEvalledConstructor("async function* () {}"); - } else if (name === "%AsyncGenerator%") { - var fn = doEval2("%AsyncGeneratorFunction%"); - if (fn) { - value = fn.prototype; - } - } else if (name === "%AsyncIteratorPrototype%") { - var gen = doEval2("%AsyncGenerator%"); - if (gen && getProto) { - value = getProto(gen.prototype); - } - } - INTRINSICS[name] = value; - return value; - }; - var LEGACY_ALIASES = { - __proto__: null, - "%ArrayBufferPrototype%": ["ArrayBuffer", "prototype"], - "%ArrayPrototype%": ["Array", "prototype"], - "%ArrayProto_entries%": ["Array", "prototype", "entries"], - "%ArrayProto_forEach%": ["Array", "prototype", "forEach"], - "%ArrayProto_keys%": ["Array", "prototype", "keys"], - "%ArrayProto_values%": ["Array", "prototype", "values"], - "%AsyncFunctionPrototype%": ["AsyncFunction", "prototype"], - "%AsyncGenerator%": ["AsyncGeneratorFunction", "prototype"], - "%AsyncGeneratorPrototype%": ["AsyncGeneratorFunction", "prototype", "prototype"], - "%BooleanPrototype%": ["Boolean", "prototype"], - "%DataViewPrototype%": ["DataView", "prototype"], - "%DatePrototype%": ["Date", "prototype"], - "%ErrorPrototype%": ["Error", "prototype"], - "%EvalErrorPrototype%": ["EvalError", "prototype"], - "%Float32ArrayPrototype%": ["Float32Array", "prototype"], - "%Float64ArrayPrototype%": ["Float64Array", "prototype"], - "%FunctionPrototype%": ["Function", "prototype"], - "%Generator%": ["GeneratorFunction", "prototype"], - "%GeneratorPrototype%": ["GeneratorFunction", "prototype", "prototype"], - "%Int8ArrayPrototype%": ["Int8Array", "prototype"], - "%Int16ArrayPrototype%": ["Int16Array", "prototype"], - "%Int32ArrayPrototype%": ["Int32Array", "prototype"], - "%JSONParse%": ["JSON", "parse"], - "%JSONStringify%": ["JSON", "stringify"], - "%MapPrototype%": ["Map", "prototype"], - "%NumberPrototype%": ["Number", "prototype"], - "%ObjectPrototype%": ["Object", "prototype"], - "%ObjProto_toString%": ["Object", "prototype", "toString"], - "%ObjProto_valueOf%": ["Object", "prototype", "valueOf"], - "%PromisePrototype%": ["Promise", "prototype"], - "%PromiseProto_then%": ["Promise", "prototype", "then"], - "%Promise_all%": ["Promise", "all"], - "%Promise_reject%": ["Promise", "reject"], - "%Promise_resolve%": ["Promise", "resolve"], - "%RangeErrorPrototype%": ["RangeError", "prototype"], - "%ReferenceErrorPrototype%": ["ReferenceError", "prototype"], - "%RegExpPrototype%": ["RegExp", "prototype"], - "%SetPrototype%": ["Set", "prototype"], - "%SharedArrayBufferPrototype%": ["SharedArrayBuffer", "prototype"], - "%StringPrototype%": ["String", "prototype"], - "%SymbolPrototype%": ["Symbol", "prototype"], - "%SyntaxErrorPrototype%": ["SyntaxError", "prototype"], - "%TypedArrayPrototype%": ["TypedArray", "prototype"], - "%TypeErrorPrototype%": ["TypeError", "prototype"], - "%Uint8ArrayPrototype%": ["Uint8Array", "prototype"], - "%Uint8ClampedArrayPrototype%": ["Uint8ClampedArray", "prototype"], - "%Uint16ArrayPrototype%": ["Uint16Array", "prototype"], - "%Uint32ArrayPrototype%": ["Uint32Array", "prototype"], - "%URIErrorPrototype%": ["URIError", "prototype"], - "%WeakMapPrototype%": ["WeakMap", "prototype"], - "%WeakSetPrototype%": ["WeakSet", "prototype"] - }; - var bind = require_function_bind(); - var hasOwn = require_hasown(); - var $concat = bind.call($call, Array.prototype.concat); - var $spliceApply = bind.call($apply, Array.prototype.splice); - var $replace = bind.call($call, String.prototype.replace); - var $strSlice = bind.call($call, String.prototype.slice); - var $exec = bind.call($call, RegExp.prototype.exec); - var rePropName = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g; - var reEscapeChar = /\\(\\)?/g; - var stringToPath = function stringToPath2(string11) { - var first = $strSlice(string11, 0, 1); - var last = $strSlice(string11, -1); - if (first === "%" && last !== "%") { - throw new $SyntaxError("invalid intrinsic syntax, expected closing `%`"); - } else if (last === "%" && first !== "%") { - throw new $SyntaxError("invalid intrinsic syntax, expected opening `%`"); - } - var result = []; - $replace(string11, rePropName, function(match, number5, quote2, subString) { - result[result.length] = quote2 ? $replace(subString, reEscapeChar, "$1") : number5 || match; - }); - return result; - }; - var getBaseIntrinsic = function getBaseIntrinsic2(name, allowMissing) { - var intrinsicName = name; - var alias; - if (hasOwn(LEGACY_ALIASES, intrinsicName)) { - alias = LEGACY_ALIASES[intrinsicName]; - intrinsicName = "%" + alias[0] + "%"; - } - if (hasOwn(INTRINSICS, intrinsicName)) { - var value = INTRINSICS[intrinsicName]; - if (value === needsEval) { - value = doEval(intrinsicName); - } - if (typeof value === "undefined" && !allowMissing) { - throw new $TypeError("intrinsic " + name + " exists, but is not available. Please file an issue!"); - } - return { - alias, - name: intrinsicName, - value - }; - } - throw new $SyntaxError("intrinsic " + name + " does not exist!"); - }; - module3.exports = function GetIntrinsic(name, allowMissing) { - if (typeof name !== "string" || name.length === 0) { - throw new $TypeError("intrinsic name must be a non-empty string"); - } - if (arguments.length > 1 && typeof allowMissing !== "boolean") { - throw new $TypeError('"allowMissing" argument must be a boolean'); - } - if ($exec(/^%?[^%]*%?$/, name) === null) { - throw new $SyntaxError("`%` may not be present anywhere but at the beginning and end of the intrinsic name"); - } - var parts = stringToPath(name); - var intrinsicBaseName = parts.length > 0 ? parts[0] : ""; - var intrinsic = getBaseIntrinsic("%" + intrinsicBaseName + "%", allowMissing); - var intrinsicRealName = intrinsic.name; - var value = intrinsic.value; - var skipFurtherCaching = false; - var alias = intrinsic.alias; - if (alias) { - intrinsicBaseName = alias[0]; - $spliceApply(parts, $concat([0, 1], alias)); - } - for (var i = 1, isOwn = true; i < parts.length; i += 1) { - var part = parts[i]; - var first = $strSlice(part, 0, 1); - var last = $strSlice(part, -1); - if ((first === '"' || first === "'" || first === "`" || (last === '"' || last === "'" || last === "`")) && first !== last) { - throw new $SyntaxError("property names with quotes must have matching quotes"); - } - if (part === "constructor" || !isOwn) { - skipFurtherCaching = true; - } - intrinsicBaseName += "." + part; - intrinsicRealName = "%" + intrinsicBaseName + "%"; - if (hasOwn(INTRINSICS, intrinsicRealName)) { - value = INTRINSICS[intrinsicRealName]; - } else if (value != null) { - if (!(part in value)) { - if (!allowMissing) { - throw new $TypeError("base intrinsic for " + name + " exists, but the property is not available."); - } - return void undefined2; - } - if ($gOPD && i + 1 >= parts.length) { - var desc = $gOPD(value, part); - isOwn = !!desc; - if (isOwn && "get" in desc && !("originalValue" in desc.get)) { - value = desc.get; - } else { - value = value[part]; - } - } else { - isOwn = hasOwn(value, part); - value = value[part]; - } - if (isOwn && !skipFurtherCaching) { - INTRINSICS[intrinsicRealName] = value; - } - } - } - return value; - }; - } -}); - -// node_modules/call-bound/index.js -var require_call_bound = __commonJS({ - "node_modules/call-bound/index.js"(exports2, module3) { - "use strict"; - var GetIntrinsic = require_get_intrinsic(); - var callBindBasic = require_call_bind_apply_helpers(); - var $indexOf = callBindBasic([GetIntrinsic("%String.prototype.indexOf%")]); - module3.exports = function callBoundIntrinsic(name, allowMissing) { - var intrinsic = ( - /** @type {(this: unknown, ...args: unknown[]) => unknown} */ - GetIntrinsic(name, !!allowMissing) - ); - if (typeof intrinsic === "function" && $indexOf(name, ".prototype.") > -1) { - return callBindBasic( - /** @type {const} */ - [intrinsic] - ); - } - return intrinsic; - }; - } -}); - -// node_modules/is-callable/index.js -var require_is_callable = __commonJS({ - "node_modules/is-callable/index.js"(exports2, module3) { - "use strict"; - var fnToStr = Function.prototype.toString; - var reflectApply = typeof Reflect === "object" && Reflect !== null && Reflect.apply; - var badArrayLike; - var isCallableMarker; - if (typeof reflectApply === "function" && typeof Object.defineProperty === "function") { - try { - badArrayLike = Object.defineProperty({}, "length", { - get: function() { - throw isCallableMarker; - } - }); - isCallableMarker = {}; - reflectApply(function() { - throw 42; - }, null, badArrayLike); - } catch (_) { - if (_ !== isCallableMarker) { - reflectApply = null; - } - } - } else { - reflectApply = null; - } - var constructorRegex = /^\s*class\b/; - var isES6ClassFn = function isES6ClassFunction(value) { - try { - var fnStr = fnToStr.call(value); - return constructorRegex.test(fnStr); - } catch (e) { - return false; - } - }; - var tryFunctionObject = function tryFunctionToStr(value) { - try { - if (isES6ClassFn(value)) { - return false; - } - fnToStr.call(value); - return true; - } catch (e) { - return false; - } - }; - var toStr = Object.prototype.toString; - var objectClass = "[object Object]"; - var fnClass = "[object Function]"; - var genClass = "[object GeneratorFunction]"; - var ddaClass = "[object HTMLAllCollection]"; - var ddaClass2 = "[object HTML document.all class]"; - var ddaClass3 = "[object HTMLCollection]"; - var hasToStringTag = typeof Symbol === "function" && !!Symbol.toStringTag; - var isIE68 = !(0 in [,]); - var isDDA = function isDocumentDotAll() { - return false; - }; - if (typeof document === "object") { - all = document.all; - if (toStr.call(all) === toStr.call(document.all)) { - isDDA = function isDocumentDotAll(value) { - if ((isIE68 || !value) && (typeof value === "undefined" || typeof value === "object")) { - try { - var str = toStr.call(value); - return (str === ddaClass || str === ddaClass2 || str === ddaClass3 || str === objectClass) && value("") == null; - } catch (e) { - } - } - return false; - }; - } - } - var all; - module3.exports = reflectApply ? function isCallable(value) { - if (isDDA(value)) { - return true; - } - if (!value) { - return false; - } - if (typeof value !== "function" && typeof value !== "object") { - return false; - } - try { - reflectApply(value, null, badArrayLike); - } catch (e) { - if (e !== isCallableMarker) { - return false; - } - } - return !isES6ClassFn(value) && tryFunctionObject(value); - } : function isCallable(value) { - if (isDDA(value)) { - return true; - } - if (!value) { - return false; - } - if (typeof value !== "function" && typeof value !== "object") { - return false; - } - if (hasToStringTag) { - return tryFunctionObject(value); - } - if (isES6ClassFn(value)) { - return false; - } - var strClass = toStr.call(value); - if (strClass !== fnClass && strClass !== genClass && !/^\[object HTML/.test(strClass)) { - return false; - } - return tryFunctionObject(value); - }; - } -}); - -// node_modules/for-each/index.js -var require_for_each = __commonJS({ - "node_modules/for-each/index.js"(exports2, module3) { - "use strict"; - var isCallable = require_is_callable(); - var toStr = Object.prototype.toString; - var hasOwnProperty = Object.prototype.hasOwnProperty; - var forEachArray = function forEachArray2(array4, iterator, receiver) { - for (var i = 0, len = array4.length; i < len; i++) { - if (hasOwnProperty.call(array4, i)) { - if (receiver == null) { - iterator(array4[i], i, array4); - } else { - iterator.call(receiver, array4[i], i, array4); - } - } - } - }; - var forEachString = function forEachString2(string11, iterator, receiver) { - for (var i = 0, len = string11.length; i < len; i++) { - if (receiver == null) { - iterator(string11.charAt(i), i, string11); - } else { - iterator.call(receiver, string11.charAt(i), i, string11); - } - } - }; - var forEachObject = function forEachObject2(object5, iterator, receiver) { - for (var k in object5) { - if (hasOwnProperty.call(object5, k)) { - if (receiver == null) { - iterator(object5[k], k, object5); - } else { - iterator.call(receiver, object5[k], k, object5); - } - } - } - }; - function isArray(x) { - return toStr.call(x) === "[object Array]"; - } - module3.exports = function forEach(list4, iterator, thisArg) { - if (!isCallable(iterator)) { - throw new TypeError("iterator must be a function"); - } - var receiver; - if (arguments.length >= 3) { - receiver = thisArg; - } - if (isArray(list4)) { - forEachArray(list4, iterator, receiver); - } else if (typeof list4 === "string") { - forEachString(list4, iterator, receiver); - } else { - forEachObject(list4, iterator, receiver); - } - }; - } -}); - -// node_modules/possible-typed-array-names/index.js -var require_possible_typed_array_names = __commonJS({ - "node_modules/possible-typed-array-names/index.js"(exports2, module3) { - "use strict"; - module3.exports = [ - "Float16Array", - "Float32Array", - "Float64Array", - "Int8Array", - "Int16Array", - "Int32Array", - "Uint8Array", - "Uint8ClampedArray", - "Uint16Array", - "Uint32Array", - "BigInt64Array", - "BigUint64Array" - ]; - } -}); - -// node_modules/available-typed-arrays/index.js -var require_available_typed_arrays = __commonJS({ - "node_modules/available-typed-arrays/index.js"(exports2, module3) { - "use strict"; - var possibleNames = require_possible_typed_array_names(); - var g = typeof globalThis === "undefined" ? global : globalThis; - module3.exports = function availableTypedArrays() { - var out = []; - for (var i = 0; i < possibleNames.length; i++) { - if (typeof g[possibleNames[i]] === "function") { - out[out.length] = possibleNames[i]; - } - } - return out; - }; - } -}); - -// node_modules/define-data-property/index.js -var require_define_data_property = __commonJS({ - "node_modules/define-data-property/index.js"(exports2, module3) { - "use strict"; - var $defineProperty = require_es_define_property(); - var $SyntaxError = require_syntax(); - var $TypeError = require_type(); - var gopd = require_gopd(); - module3.exports = function defineDataProperty(obj, property, value) { - if (!obj || typeof obj !== "object" && typeof obj !== "function") { - throw new $TypeError("`obj` must be an object or a function`"); - } - if (typeof property !== "string" && typeof property !== "symbol") { - throw new $TypeError("`property` must be a string or a symbol`"); - } - if (arguments.length > 3 && typeof arguments[3] !== "boolean" && arguments[3] !== null) { - throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null"); - } - if (arguments.length > 4 && typeof arguments[4] !== "boolean" && arguments[4] !== null) { - throw new $TypeError("`nonWritable`, if provided, must be a boolean or null"); - } - if (arguments.length > 5 && typeof arguments[5] !== "boolean" && arguments[5] !== null) { - throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null"); - } - if (arguments.length > 6 && typeof arguments[6] !== "boolean") { - throw new $TypeError("`loose`, if provided, must be a boolean"); - } - var nonEnumerable = arguments.length > 3 ? arguments[3] : null; - var nonWritable = arguments.length > 4 ? arguments[4] : null; - var nonConfigurable = arguments.length > 5 ? arguments[5] : null; - var loose = arguments.length > 6 ? arguments[6] : false; - var desc = !!gopd && gopd(obj, property); - if ($defineProperty) { - $defineProperty(obj, property, { - configurable: nonConfigurable === null && desc ? desc.configurable : !nonConfigurable, - enumerable: nonEnumerable === null && desc ? desc.enumerable : !nonEnumerable, - value, - writable: nonWritable === null && desc ? desc.writable : !nonWritable - }); - } else if (loose || !nonEnumerable && !nonWritable && !nonConfigurable) { - obj[property] = value; - } else { - throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable."); - } - }; - } -}); - -// node_modules/has-property-descriptors/index.js -var require_has_property_descriptors = __commonJS({ - "node_modules/has-property-descriptors/index.js"(exports2, module3) { - "use strict"; - var $defineProperty = require_es_define_property(); - var hasPropertyDescriptors = function hasPropertyDescriptors2() { - return !!$defineProperty; - }; - hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBug() { - if (!$defineProperty) { - return null; - } - try { - return $defineProperty([], "length", { value: 1 }).length !== 1; - } catch (e) { - return true; - } - }; - module3.exports = hasPropertyDescriptors; - } -}); - -// node_modules/set-function-length/index.js -var require_set_function_length = __commonJS({ - "node_modules/set-function-length/index.js"(exports2, module3) { - "use strict"; - var GetIntrinsic = require_get_intrinsic(); - var define = require_define_data_property(); - var hasDescriptors = require_has_property_descriptors()(); - var gOPD = require_gopd(); - var $TypeError = require_type(); - var $floor = GetIntrinsic("%Math.floor%"); - module3.exports = function setFunctionLength(fn, length) { - if (typeof fn !== "function") { - throw new $TypeError("`fn` is not a function"); - } - if (typeof length !== "number" || length < 0 || length > 4294967295 || $floor(length) !== length) { - throw new $TypeError("`length` must be a positive 32-bit integer"); - } - var loose = arguments.length > 2 && !!arguments[2]; - var functionLengthIsConfigurable = true; - var functionLengthIsWritable = true; - if ("length" in fn && gOPD) { - var desc = gOPD(fn, "length"); - if (desc && !desc.configurable) { - functionLengthIsConfigurable = false; - } - if (desc && !desc.writable) { - functionLengthIsWritable = false; - } - } - if (functionLengthIsConfigurable || functionLengthIsWritable || !loose) { - if (hasDescriptors) { - define( - /** @type {Parameters[0]} */ - fn, - "length", - length, - true, - true - ); - } else { - define( - /** @type {Parameters[0]} */ - fn, - "length", - length - ); - } - } - return fn; - }; - } -}); - -// node_modules/call-bind-apply-helpers/applyBind.js -var require_applyBind = __commonJS({ - "node_modules/call-bind-apply-helpers/applyBind.js"(exports2, module3) { - "use strict"; - var bind = require_function_bind(); - var $apply = require_functionApply(); - var actualApply = require_actualApply(); - module3.exports = function applyBind() { - return actualApply(bind, $apply, arguments); - }; - } -}); - -// node_modules/call-bind/index.js -var require_call_bind = __commonJS({ - "node_modules/call-bind/index.js"(exports2, module3) { - "use strict"; - var setFunctionLength = require_set_function_length(); - var $defineProperty = require_es_define_property(); - var callBindBasic = require_call_bind_apply_helpers(); - var applyBind = require_applyBind(); - module3.exports = function callBind(originalFunction) { - var func = callBindBasic(arguments); - var adjustedLength = 1 + originalFunction.length - (arguments.length - 1); - return setFunctionLength( - func, - adjustedLength > 0 ? adjustedLength : 0, - true - ); - }; - if ($defineProperty) { - $defineProperty(module3.exports, "apply", { value: applyBind }); - } else { - module3.exports.apply = applyBind; - } - } -}); - -// node_modules/has-tostringtag/shams.js -var require_shams2 = __commonJS({ - "node_modules/has-tostringtag/shams.js"(exports2, module3) { - "use strict"; - var hasSymbols = require_shams(); - module3.exports = function hasToStringTagShams() { - return hasSymbols() && !!Symbol.toStringTag; - }; - } -}); - -// node_modules/which-typed-array/index.js -var require_which_typed_array = __commonJS({ - "node_modules/which-typed-array/index.js"(exports2, module3) { - "use strict"; - var forEach = require_for_each(); - var availableTypedArrays = require_available_typed_arrays(); - var callBind = require_call_bind(); - var callBound = require_call_bound(); - var gOPD = require_gopd(); - var getProto = require_get_proto(); - var $toString = callBound("Object.prototype.toString"); - var hasToStringTag = require_shams2()(); - var g = typeof globalThis === "undefined" ? global : globalThis; - var typedArrays = availableTypedArrays(); - var $slice = callBound("String.prototype.slice"); - var $indexOf = callBound("Array.prototype.indexOf", true) || function indexOf(array4, value) { - for (var i = 0; i < array4.length; i += 1) { - if (array4[i] === value) { - return i; - } - } - return -1; - }; - var cache = { __proto__: null }; - if (hasToStringTag && gOPD && getProto) { - forEach(typedArrays, function(typedArray) { - var arr = new g[typedArray](); - if (Symbol.toStringTag in arr && getProto) { - var proto = getProto(arr); - var descriptor = gOPD(proto, Symbol.toStringTag); - if (!descriptor && proto) { - var superProto = getProto(proto); - descriptor = gOPD(superProto, Symbol.toStringTag); - } - if (descriptor && descriptor.get) { - var bound = callBind(descriptor.get); - cache[ - /** @type {`$${TypedArrayName}`} */ - "$" + typedArray - ] = bound; - } - } - }); - } else { - forEach(typedArrays, function(typedArray) { - var arr = new g[typedArray](); - var fn = arr.slice || arr.set; - if (fn) { - var bound = ( - /** @type {BoundSlice | BoundSet} */ - // @ts-expect-error TODO FIXME - callBind(fn) - ); - cache[ - /** @type {`$${TypedArrayName}`} */ - "$" + typedArray - ] = bound; - } - }); - } - function tryTypedArrays(value) { - var found = false; - forEach( - /** @type {Record<`$${TypedArrayName}`, Getter>} */ - cache, - /** @param {Getter} getter @param {`$${TypedArrayName}`} typedArray */ - function(getter, typedArray) { - if (!found) { - try { - if ("$" + getter(value) === typedArray) { - found = /** @type {TypedArrayName} */ - $slice(typedArray, 1); - } - } catch (e) { - } - } - } - ); - return found; - } - function trySlices(value) { - var found = false; - forEach( - /** @type {Record<`$${TypedArrayName}`, Getter>} */ - cache, - /** @param {Getter} getter @param {`$${TypedArrayName}`} name */ - function(getter, name) { - if (!found) { - try { - getter(value); - found = /** @type {TypedArrayName} */ - $slice(name, 1); - } catch (e) { - } - } - } - ); - return found; - } - function isTATag(tag2) { - return $indexOf(typedArrays, tag2) > -1; - } - module3.exports = function whichTypedArray(value) { - if (!value || typeof value !== "object") { - return false; - } - if (!hasToStringTag) { - var tag2 = $slice($toString(value), 8, -1); - if (isTATag(tag2)) { - return tag2; - } - if (tag2 !== "Object") { - return false; - } - return trySlices(value); - } - if (!gOPD) { - return null; - } - return tryTypedArrays(value); - }; - } -}); - -// node_modules/is-typed-array/index.js -var require_is_typed_array = __commonJS({ - "node_modules/is-typed-array/index.js"(exports2, module3) { - "use strict"; - var whichTypedArray = require_which_typed_array(); - module3.exports = function isTypedArray(value) { - return !!whichTypedArray(value); - }; - } -}); - -// node_modules/typed-array-buffer/index.js -var require_typed_array_buffer = __commonJS({ - "node_modules/typed-array-buffer/index.js"(exports2, module3) { - "use strict"; - var $TypeError = require_type(); - var callBound = require_call_bound(); - var $typedArrayBuffer = callBound("TypedArray.prototype.buffer", true); - var isTypedArray = require_is_typed_array(); - module3.exports = $typedArrayBuffer || function typedArrayBuffer(x) { - if (!isTypedArray(x)) { - throw new $TypeError("Not a Typed Array"); - } - return x.buffer; - }; - } -}); - -// node_modules/to-buffer/index.js -var require_to_buffer = __commonJS({ - "node_modules/to-buffer/index.js"(exports2, module3) { - "use strict"; - var Buffer3 = require_safe_buffer3().Buffer; - var isArray = require_isarray2(); - var typedArrayBuffer = require_typed_array_buffer(); - var isView = ArrayBuffer.isView || function isView2(obj) { - try { - typedArrayBuffer(obj); - return true; - } catch (e) { - return false; - } - }; - var useUint8Array = typeof Uint8Array !== "undefined"; - var useArrayBuffer = typeof ArrayBuffer !== "undefined" && typeof Uint8Array !== "undefined"; - var useFromArrayBuffer = useArrayBuffer && (Buffer3.prototype instanceof Uint8Array || Buffer3.TYPED_ARRAY_SUPPORT); - module3.exports = function toBuffer(data, encoding) { - if (Buffer3.isBuffer(data)) { - if (data.constructor && !("isBuffer" in data)) { - return Buffer3.from(data); - } - return data; - } - if (typeof data === "string") { - return Buffer3.from(data, encoding); - } - if (useArrayBuffer && isView(data)) { - if (data.byteLength === 0) { - return Buffer3.alloc(0); - } - if (useFromArrayBuffer) { - var res = Buffer3.from(data.buffer, data.byteOffset, data.byteLength); - if (res.byteLength === data.byteLength) { - return res; - } - } - var uint8 = data instanceof Uint8Array ? data : new Uint8Array(data.buffer, data.byteOffset, data.byteLength); - var result = Buffer3.from(uint8); - if (result.length === data.byteLength) { - return result; - } - } - if (useUint8Array && data instanceof Uint8Array) { - return Buffer3.from(data); - } - var isArr = isArray(data); - if (isArr) { - for (var i = 0; i < data.length; i += 1) { - var x = data[i]; - if (typeof x !== "number" || x < 0 || x > 255 || ~~x !== x) { - throw new RangeError("Array items must be numbers in the range 0-255."); - } - } - } - if (isArr || Buffer3.isBuffer(data) && data.constructor && typeof data.constructor.isBuffer === "function" && data.constructor.isBuffer(data)) { - return Buffer3.from(data); - } - throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.'); - }; - } -}); - -// node_modules/buffer-fill/index.js -var require_buffer_fill = __commonJS({ - "node_modules/buffer-fill/index.js"(exports2, module3) { - var hasFullSupport = (function() { - try { - if (!Buffer.isEncoding("latin1")) { - return false; - } - var buf = Buffer.alloc ? Buffer.alloc(4) : new Buffer(4); - buf.fill("ab", "ucs2"); - return buf.toString("hex") === "61006200"; - } catch (_) { - return false; - } - })(); - function isSingleByte(val) { - return val.length === 1 && val.charCodeAt(0) < 256; - } - function fillWithNumber(buffer, val, start, end) { - if (start < 0 || end > buffer.length) { - throw new RangeError("Out of range index"); - } - start = start >>> 0; - end = end === void 0 ? buffer.length : end >>> 0; - if (end > start) { - buffer.fill(val, start, end); - } - return buffer; - } - function fillWithBuffer(buffer, val, start, end) { - if (start < 0 || end > buffer.length) { - throw new RangeError("Out of range index"); - } - if (end <= start) { - return buffer; - } - start = start >>> 0; - end = end === void 0 ? buffer.length : end >>> 0; - var pos = start; - var len = val.length; - while (pos <= end - len) { - val.copy(buffer, pos); - pos += len; - } - if (pos !== end) { - val.copy(buffer, pos, 0, end - pos); - } - return buffer; - } - function fill(buffer, val, start, end, encoding) { - if (hasFullSupport) { - return buffer.fill(val, start, end, encoding); - } - if (typeof val === "number") { - return fillWithNumber(buffer, val, start, end); - } - if (typeof val === "string") { - if (typeof start === "string") { - encoding = start; - start = 0; - end = buffer.length; - } else if (typeof end === "string") { - encoding = end; - end = buffer.length; - } - if (encoding !== void 0 && typeof encoding !== "string") { - throw new TypeError("encoding must be a string"); - } - if (encoding === "latin1") { - encoding = "binary"; - } - if (typeof encoding === "string" && !Buffer.isEncoding(encoding)) { - throw new TypeError("Unknown encoding: " + encoding); - } - if (val === "") { - return fillWithNumber(buffer, 0, start, end); - } - if (isSingleByte(val)) { - return fillWithNumber(buffer, val.charCodeAt(0), start, end); - } - val = new Buffer(val, encoding); - } - if (Buffer.isBuffer(val)) { - return fillWithBuffer(buffer, val, start, end); - } - return fillWithNumber(buffer, 0, start, end); - } - module3.exports = fill; - } -}); - -// node_modules/buffer-alloc-unsafe/index.js -var require_buffer_alloc_unsafe = __commonJS({ - "node_modules/buffer-alloc-unsafe/index.js"(exports2, module3) { - function allocUnsafe(size) { - if (typeof size !== "number") { - throw new TypeError('"size" argument must be a number'); - } - if (size < 0) { - throw new RangeError('"size" argument must not be negative'); - } - if (Buffer.allocUnsafe) { - return Buffer.allocUnsafe(size); - } else { - return new Buffer(size); - } - } - module3.exports = allocUnsafe; - } -}); - -// node_modules/buffer-alloc/index.js -var require_buffer_alloc = __commonJS({ - "node_modules/buffer-alloc/index.js"(exports2, module3) { - var bufferFill = require_buffer_fill(); - var allocUnsafe = require_buffer_alloc_unsafe(); - module3.exports = function alloc(size, fill, encoding) { - if (typeof size !== "number") { - throw new TypeError('"size" argument must be a number'); - } - if (size < 0) { - throw new RangeError('"size" argument must not be negative'); - } - if (Buffer.alloc) { - return Buffer.alloc(size, fill, encoding); - } - var buffer = allocUnsafe(size); - if (size === 0) { - return buffer; - } - if (fill === void 0) { - return bufferFill(buffer, 0); - } - if (typeof encoding !== "string") { - encoding = void 0; - } - return bufferFill(buffer, fill, encoding); - }; - } -}); - -// node_modules/tar-stream/headers.js -var require_headers = __commonJS({ - "node_modules/tar-stream/headers.js"(exports2) { - var toBuffer = require_to_buffer(); - var alloc = require_buffer_alloc(); - var ZEROS = "0000000000000000000"; - var SEVENS = "7777777777777777777"; - var ZERO_OFFSET = "0".charCodeAt(0); - var USTAR = "ustar\x0000"; - var MASK = parseInt("7777", 8); - var clamp = function(index4, len, defaultValue) { - if (typeof index4 !== "number") return defaultValue; - index4 = ~~index4; - if (index4 >= len) return len; - if (index4 >= 0) return index4; - index4 += len; - if (index4 >= 0) return index4; - return 0; - }; - var toType = function(flag) { - switch (flag) { - case 0: - return "file"; - case 1: - return "link"; - case 2: - return "symlink"; - case 3: - return "character-device"; - case 4: - return "block-device"; - case 5: - return "directory"; - case 6: - return "fifo"; - case 7: - return "contiguous-file"; - case 72: - return "pax-header"; - case 55: - return "pax-global-header"; - case 27: - return "gnu-long-link-path"; - case 28: - case 30: - return "gnu-long-path"; - } - return null; - }; - var toTypeflag = function(flag) { - switch (flag) { - case "file": - return 0; - case "link": - return 1; - case "symlink": - return 2; - case "character-device": - return 3; - case "block-device": - return 4; - case "directory": - return 5; - case "fifo": - return 6; - case "contiguous-file": - return 7; - case "pax-header": - return 72; - } - return 0; - }; - var indexOf = function(block4, num, offset, end) { - for (; offset < end; offset++) { - if (block4[offset] === num) return offset; - } - return end; - }; - var cksum = function(block4) { - var sum = 8 * 32; - for (var i = 0; i < 148; i++) sum += block4[i]; - for (var j = 156; j < 512; j++) sum += block4[j]; - return sum; - }; - var encodeOct = function(val, n) { - val = val.toString(8); - if (val.length > n) return SEVENS.slice(0, n) + " "; - else return ZEROS.slice(0, n - val.length) + val + " "; - }; - function parse256(buf) { - var positive; - if (buf[0] === 128) positive = true; - else if (buf[0] === 255) positive = false; - else return null; - var zero = false; - var tuple = []; - for (var i = buf.length - 1; i > 0; i--) { - var byte = buf[i]; - if (positive) tuple.push(byte); - else if (zero && byte === 0) tuple.push(0); - else if (zero) { - zero = false; - tuple.push(256 - byte); - } else tuple.push(255 - byte); - } - var sum = 0; - var l = tuple.length; - for (i = 0; i < l; i++) { - sum += tuple[i] * Math.pow(256, i); - } - return positive ? sum : -1 * sum; - } - var decodeOct = function(val, offset, length) { - val = val.slice(offset, offset + length); - offset = 0; - if (val[offset] & 128) { - return parse256(val); - } else { - while (offset < val.length && val[offset] === 32) offset++; - var end = clamp(indexOf(val, 32, offset, val.length), val.length, val.length); - while (offset < end && val[offset] === 0) offset++; - if (end === offset) return 0; - return parseInt(val.slice(offset, end).toString(), 8); - } - }; - var decodeStr = function(val, offset, length, encoding) { - return val.slice(offset, indexOf(val, 0, offset, offset + length)).toString(encoding); - }; - var addLength = function(str) { - var len = Buffer.byteLength(str); - var digits = Math.floor(Math.log(len) / Math.log(10)) + 1; - if (len + digits >= Math.pow(10, digits)) digits++; - return len + digits + str; - }; - exports2.decodeLongPath = function(buf, encoding) { - return decodeStr(buf, 0, buf.length, encoding); - }; - exports2.encodePax = function(opts) { - var result = ""; - if (opts.name) result += addLength(" path=" + opts.name + "\n"); - if (opts.linkname) result += addLength(" linkpath=" + opts.linkname + "\n"); - var pax = opts.pax; - if (pax) { - for (var key2 in pax) { - result += addLength(" " + key2 + "=" + pax[key2] + "\n"); - } - } - return toBuffer(result); - }; - exports2.decodePax = function(buf) { - var result = {}; - while (buf.length) { - var i = 0; - while (i < buf.length && buf[i] !== 32) i++; - var len = parseInt(buf.slice(0, i).toString(), 10); - if (!len) return result; - var b = buf.slice(i + 1, len - 1).toString(); - var keyIndex = b.indexOf("="); - if (keyIndex === -1) return result; - result[b.slice(0, keyIndex)] = b.slice(keyIndex + 1); - buf = buf.slice(len); - } - return result; - }; - exports2.encode = function(opts) { - var buf = alloc(512); - var name = opts.name; - var prefix = ""; - if (opts.typeflag === 5 && name[name.length - 1] !== "/") name += "/"; - if (Buffer.byteLength(name) !== name.length) return null; - while (Buffer.byteLength(name) > 100) { - var i = name.indexOf("/"); - if (i === -1) return null; - prefix += prefix ? "/" + name.slice(0, i) : name.slice(0, i); - name = name.slice(i + 1); - } - if (Buffer.byteLength(name) > 100 || Buffer.byteLength(prefix) > 155) return null; - if (opts.linkname && Buffer.byteLength(opts.linkname) > 100) return null; - buf.write(name); - buf.write(encodeOct(opts.mode & MASK, 6), 100); - buf.write(encodeOct(opts.uid, 6), 108); - buf.write(encodeOct(opts.gid, 6), 116); - buf.write(encodeOct(opts.size, 11), 124); - buf.write(encodeOct(opts.mtime.getTime() / 1e3 | 0, 11), 136); - buf[156] = ZERO_OFFSET + toTypeflag(opts.type); - if (opts.linkname) buf.write(opts.linkname, 157); - buf.write(USTAR, 257); - if (opts.uname) buf.write(opts.uname, 265); - if (opts.gname) buf.write(opts.gname, 297); - buf.write(encodeOct(opts.devmajor || 0, 6), 329); - buf.write(encodeOct(opts.devminor || 0, 6), 337); - if (prefix) buf.write(prefix, 345); - buf.write(encodeOct(cksum(buf), 6), 148); - return buf; - }; - exports2.decode = function(buf, filenameEncoding) { - var typeflag = buf[156] === 0 ? 0 : buf[156] - ZERO_OFFSET; - var name = decodeStr(buf, 0, 100, filenameEncoding); - var mode = decodeOct(buf, 100, 8); - var uid = decodeOct(buf, 108, 8); - var gid = decodeOct(buf, 116, 8); - var size = decodeOct(buf, 124, 12); - var mtime = decodeOct(buf, 136, 12); - var type2 = toType(typeflag); - var linkname = buf[157] === 0 ? null : decodeStr(buf, 157, 100, filenameEncoding); - var uname = decodeStr(buf, 265, 32); - var gname = decodeStr(buf, 297, 32); - var devmajor = decodeOct(buf, 329, 8); - var devminor = decodeOct(buf, 337, 8); - if (buf[345]) name = decodeStr(buf, 345, 155, filenameEncoding) + "/" + name; - if (typeflag === 0 && name && name[name.length - 1] === "/") typeflag = 5; - var c = cksum(buf); - if (c === 8 * 32) return null; - if (c !== decodeOct(buf, 148, 8)) throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?"); - return { - name, - mode, - uid, - gid, - size, - mtime: new Date(1e3 * mtime), - type: type2, - linkname, - uname, - gname, - devmajor, - devminor - }; - }; - } -}); - -// node_modules/tar-stream/extract.js -var require_extract = __commonJS({ - "node_modules/tar-stream/extract.js"(exports2, module3) { - var util = require("util"); - var bl = require_bl(); - var xtend = require_immutable(); - var headers = require_headers(); - var Writable = require_readable().Writable; - var PassThrough = require_readable().PassThrough; - var noop6 = function() { - }; - var overflow = function(size) { - size &= 511; - return size && 512 - size; - }; - var emptyStream = function(self2, offset) { - var s = new Source2(self2, offset); - s.end(); - return s; - }; - var mixinPax = function(header, pax) { - if (pax.path) header.name = pax.path; - if (pax.linkpath) header.linkname = pax.linkpath; - if (pax.size) header.size = parseInt(pax.size, 10); - header.pax = pax; - return header; - }; - var Source2 = function(self2, offset) { - this._parent = self2; - this.offset = offset; - PassThrough.call(this); - }; - util.inherits(Source2, PassThrough); - Source2.prototype.destroy = function(err) { - this._parent.destroy(err); - }; - var Extract = function(opts) { - if (!(this instanceof Extract)) return new Extract(opts); - Writable.call(this, opts); - opts = opts || {}; - this._offset = 0; - this._buffer = bl(); - this._missing = 0; - this._partial = false; - this._onparse = noop6; - this._header = null; - this._stream = null; - this._overflow = null; - this._cb = null; - this._locked = false; - this._destroyed = false; - this._pax = null; - this._paxGlobal = null; - this._gnuLongPath = null; - this._gnuLongLinkPath = null; - var self2 = this; - var b = self2._buffer; - var oncontinue = function() { - self2._continue(); - }; - var onunlock = function(err) { - self2._locked = false; - if (err) return self2.destroy(err); - if (!self2._stream) oncontinue(); - }; - var onstreamend = function() { - self2._stream = null; - var drain = overflow(self2._header.size); - if (drain) self2._parse(drain, ondrain); - else self2._parse(512, onheader); - if (!self2._locked) oncontinue(); - }; - var ondrain = function() { - self2._buffer.consume(overflow(self2._header.size)); - self2._parse(512, onheader); - oncontinue(); - }; - var onpaxglobalheader = function() { - var size = self2._header.size; - self2._paxGlobal = headers.decodePax(b.slice(0, size)); - b.consume(size); - onstreamend(); - }; - var onpaxheader = function() { - var size = self2._header.size; - self2._pax = headers.decodePax(b.slice(0, size)); - if (self2._paxGlobal) self2._pax = xtend(self2._paxGlobal, self2._pax); - b.consume(size); - onstreamend(); - }; - var ongnulongpath = function() { - var size = self2._header.size; - this._gnuLongPath = headers.decodeLongPath(b.slice(0, size), opts.filenameEncoding); - b.consume(size); - onstreamend(); - }; - var ongnulonglinkpath = function() { - var size = self2._header.size; - this._gnuLongLinkPath = headers.decodeLongPath(b.slice(0, size), opts.filenameEncoding); - b.consume(size); - onstreamend(); - }; - var onheader = function() { - var offset = self2._offset; - var header; - try { - header = self2._header = headers.decode(b.slice(0, 512), opts.filenameEncoding); - } catch (err) { - self2.emit("error", err); - } - b.consume(512); - if (!header) { - self2._parse(512, onheader); - oncontinue(); - return; - } - if (header.type === "gnu-long-path") { - self2._parse(header.size, ongnulongpath); - oncontinue(); - return; - } - if (header.type === "gnu-long-link-path") { - self2._parse(header.size, ongnulonglinkpath); - oncontinue(); - return; - } - if (header.type === "pax-global-header") { - self2._parse(header.size, onpaxglobalheader); - oncontinue(); - return; - } - if (header.type === "pax-header") { - self2._parse(header.size, onpaxheader); - oncontinue(); - return; - } - if (self2._gnuLongPath) { - header.name = self2._gnuLongPath; - self2._gnuLongPath = null; - } - if (self2._gnuLongLinkPath) { - header.linkname = self2._gnuLongLinkPath; - self2._gnuLongLinkPath = null; - } - if (self2._pax) { - self2._header = header = mixinPax(header, self2._pax); - self2._pax = null; - } - self2._locked = true; - if (!header.size || header.type === "directory") { - self2._parse(512, onheader); - self2.emit("entry", header, emptyStream(self2, offset), onunlock); - return; - } - self2._stream = new Source2(self2, offset); - self2.emit("entry", header, self2._stream, onunlock); - self2._parse(header.size, onstreamend); - oncontinue(); - }; - this._onheader = onheader; - this._parse(512, onheader); - }; - util.inherits(Extract, Writable); - Extract.prototype.destroy = function(err) { - if (this._destroyed) return; - this._destroyed = true; - if (err) this.emit("error", err); - this.emit("close"); - if (this._stream) this._stream.emit("close"); - }; - Extract.prototype._parse = function(size, onparse) { - if (this._destroyed) return; - this._offset += size; - this._missing = size; - if (onparse === this._onheader) this._partial = false; - this._onparse = onparse; - }; - Extract.prototype._continue = function() { - if (this._destroyed) return; - var cb = this._cb; - this._cb = noop6; - if (this._overflow) this._write(this._overflow, void 0, cb); - else cb(); - }; - Extract.prototype._write = function(data, enc, cb) { - if (this._destroyed) return; - var s = this._stream; - var b = this._buffer; - var missing = this._missing; - if (data.length) this._partial = true; - if (data.length < missing) { - this._missing -= data.length; - this._overflow = null; - if (s) return s.write(data, cb); - b.append(data); - return cb(); - } - this._cb = cb; - this._missing = 0; - var overflow2 = null; - if (data.length > missing) { - overflow2 = data.slice(missing); - data = data.slice(0, missing); - } - if (s) s.end(data); - else b.append(data); - this._overflow = overflow2; - this._onparse(); - }; - Extract.prototype._final = function(cb) { - if (this._partial) return this.destroy(new Error("Unexpected end of data")); - cb(); - }; - module3.exports = Extract; - } -}); - -// node_modules/fs-constants/index.js -var require_fs_constants = __commonJS({ - "node_modules/fs-constants/index.js"(exports2, module3) { - module3.exports = require("fs").constants || require("constants"); - } -}); - -// node_modules/wrappy/wrappy.js -var require_wrappy = __commonJS({ - "node_modules/wrappy/wrappy.js"(exports2, module3) { - module3.exports = wrappy; - function wrappy(fn, cb) { - if (fn && cb) return wrappy(fn)(cb); - if (typeof fn !== "function") - throw new TypeError("need wrapper function"); - Object.keys(fn).forEach(function(k) { - wrapper[k] = fn[k]; - }); - return wrapper; - function wrapper() { - var args = new Array(arguments.length); - for (var i = 0; i < args.length; i++) { - args[i] = arguments[i]; - } - var ret = fn.apply(this, args); - var cb2 = args[args.length - 1]; - if (typeof ret === "function" && ret !== cb2) { - Object.keys(cb2).forEach(function(k) { - ret[k] = cb2[k]; - }); - } - return ret; - } - } - } -}); - -// node_modules/once/once.js -var require_once = __commonJS({ - "node_modules/once/once.js"(exports2, module3) { - var wrappy = require_wrappy(); - module3.exports = wrappy(once); - module3.exports.strict = wrappy(onceStrict); - once.proto = once(function() { - Object.defineProperty(Function.prototype, "once", { - value: function() { - return once(this); - }, - configurable: true - }); - Object.defineProperty(Function.prototype, "onceStrict", { - value: function() { - return onceStrict(this); - }, - configurable: true - }); - }); - function once(fn) { - var f = function() { - if (f.called) return f.value; - f.called = true; - return f.value = fn.apply(this, arguments); - }; - f.called = false; - return f; - } - function onceStrict(fn) { - var f = function() { - if (f.called) - throw new Error(f.onceError); - f.called = true; - return f.value = fn.apply(this, arguments); - }; - var name = fn.name || "Function wrapped with `once`"; - f.onceError = name + " shouldn't be called more than once"; - f.called = false; - return f; - } - } -}); - -// node_modules/end-of-stream/index.js -var require_end_of_stream = __commonJS({ - "node_modules/end-of-stream/index.js"(exports2, module3) { - var once = require_once(); - var noop6 = function() { - }; - var qnt = global.Bare ? queueMicrotask : process.nextTick.bind(process); - var isRequest = function(stream2) { - return stream2.setHeader && typeof stream2.abort === "function"; - }; - var isChildProcess = function(stream2) { - return stream2.stdio && Array.isArray(stream2.stdio) && stream2.stdio.length === 3; - }; - var eos = function(stream2, opts, callback) { - if (typeof opts === "function") return eos(stream2, null, opts); - if (!opts) opts = {}; - callback = once(callback || noop6); - var ws = stream2._writableState; - var rs = stream2._readableState; - var readable = opts.readable || opts.readable !== false && stream2.readable; - var writable = opts.writable || opts.writable !== false && stream2.writable; - var cancelled = false; - var onlegacyfinish = function() { - if (!stream2.writable) onfinish(); - }; - var onfinish = function() { - writable = false; - if (!readable) callback.call(stream2); - }; - var onend = function() { - readable = false; - if (!writable) callback.call(stream2); - }; - var onexit = function(exitCode) { - callback.call(stream2, exitCode ? new Error("exited with error code: " + exitCode) : null); - }; - var onerror = function(err) { - callback.call(stream2, err); - }; - var onclose = function() { - qnt(onclosenexttick); - }; - var onclosenexttick = function() { - if (cancelled) return; - if (readable && !(rs && (rs.ended && !rs.destroyed))) return callback.call(stream2, new Error("premature close")); - if (writable && !(ws && (ws.ended && !ws.destroyed))) return callback.call(stream2, new Error("premature close")); - }; - var onrequest = function() { - stream2.req.on("finish", onfinish); - }; - if (isRequest(stream2)) { - stream2.on("complete", onfinish); - stream2.on("abort", onclose); - if (stream2.req) onrequest(); - else stream2.on("request", onrequest); - } else if (writable && !ws) { - stream2.on("end", onlegacyfinish); - stream2.on("close", onlegacyfinish); - } - if (isChildProcess(stream2)) stream2.on("exit", onexit); - stream2.on("end", onend); - stream2.on("finish", onfinish); - if (opts.error !== false) stream2.on("error", onerror); - stream2.on("close", onclose); - return function() { - cancelled = true; - stream2.removeListener("complete", onfinish); - stream2.removeListener("abort", onclose); - stream2.removeListener("request", onrequest); - if (stream2.req) stream2.req.removeListener("finish", onfinish); - stream2.removeListener("end", onlegacyfinish); - stream2.removeListener("close", onlegacyfinish); - stream2.removeListener("finish", onfinish); - stream2.removeListener("exit", onexit); - stream2.removeListener("end", onend); - stream2.removeListener("error", onerror); - stream2.removeListener("close", onclose); - }; - }; - module3.exports = eos; - } -}); - -// node_modules/tar-stream/pack.js -var require_pack = __commonJS({ - "node_modules/tar-stream/pack.js"(exports2, module3) { - var constants = require_fs_constants(); - var eos = require_end_of_stream(); - var util = require("util"); - var alloc = require_buffer_alloc(); - var toBuffer = require_to_buffer(); - var Readable = require_readable().Readable; - var Writable = require_readable().Writable; - var StringDecoder = require("string_decoder").StringDecoder; - var headers = require_headers(); - var DMODE = parseInt("755", 8); - var FMODE = parseInt("644", 8); - var END_OF_TAR = alloc(1024); - var noop6 = function() { - }; - var overflow = function(self2, size) { - size &= 511; - if (size) self2.push(END_OF_TAR.slice(0, 512 - size)); - }; - function modeToType(mode) { - switch (mode & constants.S_IFMT) { - case constants.S_IFBLK: - return "block-device"; - case constants.S_IFCHR: - return "character-device"; - case constants.S_IFDIR: - return "directory"; - case constants.S_IFIFO: - return "fifo"; - case constants.S_IFLNK: - return "symlink"; - } - return "file"; - } - var Sink = function(to) { - Writable.call(this); - this.written = 0; - this._to = to; - this._destroyed = false; - }; - util.inherits(Sink, Writable); - Sink.prototype._write = function(data, enc, cb) { - this.written += data.length; - if (this._to.push(data)) return cb(); - this._to._drain = cb; - }; - Sink.prototype.destroy = function() { - if (this._destroyed) return; - this._destroyed = true; - this.emit("close"); - }; - var LinkSink = function() { - Writable.call(this); - this.linkname = ""; - this._decoder = new StringDecoder("utf-8"); - this._destroyed = false; - }; - util.inherits(LinkSink, Writable); - LinkSink.prototype._write = function(data, enc, cb) { - this.linkname += this._decoder.write(data); - cb(); - }; - LinkSink.prototype.destroy = function() { - if (this._destroyed) return; - this._destroyed = true; - this.emit("close"); - }; - var Void = function() { - Writable.call(this); - this._destroyed = false; - }; - util.inherits(Void, Writable); - Void.prototype._write = function(data, enc, cb) { - cb(new Error("No body allowed for this entry")); - }; - Void.prototype.destroy = function() { - if (this._destroyed) return; - this._destroyed = true; - this.emit("close"); - }; - var Pack = function(opts) { - if (!(this instanceof Pack)) return new Pack(opts); - Readable.call(this, opts); - this._drain = noop6; - this._finalized = false; - this._finalizing = false; - this._destroyed = false; - this._stream = null; - }; - util.inherits(Pack, Readable); - Pack.prototype.entry = function(header, buffer, callback) { - if (this._stream) throw new Error("already piping an entry"); - if (this._finalized || this._destroyed) return; - if (typeof buffer === "function") { - callback = buffer; - buffer = null; - } - if (!callback) callback = noop6; - var self2 = this; - if (!header.size || header.type === "symlink") header.size = 0; - if (!header.type) header.type = modeToType(header.mode); - if (!header.mode) header.mode = header.type === "directory" ? DMODE : FMODE; - if (!header.uid) header.uid = 0; - if (!header.gid) header.gid = 0; - if (!header.mtime) header.mtime = /* @__PURE__ */ new Date(); - if (typeof buffer === "string") buffer = toBuffer(buffer); - if (Buffer.isBuffer(buffer)) { - header.size = buffer.length; - this._encode(header); - this.push(buffer); - overflow(self2, header.size); - process.nextTick(callback); - return new Void(); - } - if (header.type === "symlink" && !header.linkname) { - var linkSink = new LinkSink(); - eos(linkSink, function(err) { - if (err) { - self2.destroy(); - return callback(err); - } - header.linkname = linkSink.linkname; - self2._encode(header); - callback(); - }); - return linkSink; - } - this._encode(header); - if (header.type !== "file" && header.type !== "contiguous-file") { - process.nextTick(callback); - return new Void(); - } - var sink = new Sink(this); - this._stream = sink; - eos(sink, function(err) { - self2._stream = null; - if (err) { - self2.destroy(); - return callback(err); - } - if (sink.written !== header.size) { - self2.destroy(); - return callback(new Error("size mismatch")); - } - overflow(self2, header.size); - if (self2._finalizing) self2.finalize(); - callback(); - }); - return sink; - }; - Pack.prototype.finalize = function() { - if (this._stream) { - this._finalizing = true; - return; - } - if (this._finalized) return; - this._finalized = true; - this.push(END_OF_TAR); - this.push(null); - }; - Pack.prototype.destroy = function(err) { - if (this._destroyed) return; - this._destroyed = true; - if (err) this.emit("error", err); - this.emit("close"); - if (this._stream && this._stream.destroy) this._stream.destroy(); - }; - Pack.prototype._encode = function(header) { - if (!header.pax) { - var buf = headers.encode(header); - if (buf) { - this.push(buf); - return; - } - } - this._encodePax(header); - }; - Pack.prototype._encodePax = function(header) { - var paxHeader = headers.encodePax({ - name: header.name, - linkname: header.linkname, - pax: header.pax - }); - var newHeader = { - name: "PaxHeader", - mode: header.mode, - uid: header.uid, - gid: header.gid, - size: paxHeader.length, - mtime: header.mtime, - type: "pax-header", - linkname: header.linkname && "PaxHeader", - uname: header.uname, - gname: header.gname, - devmajor: header.devmajor, - devminor: header.devminor - }; - this.push(headers.encode(newHeader)); - this.push(paxHeader); - overflow(this, paxHeader.length); - newHeader.size = header.size; - newHeader.type = header.type; - this.push(headers.encode(newHeader)); - }; - Pack.prototype._read = function(n) { - var drain = this._drain; - this._drain = noop6; - drain(); - }; - module3.exports = Pack; - } -}); - -// node_modules/tar-stream/index.js -var require_tar_stream = __commonJS({ - "node_modules/tar-stream/index.js"(exports2) { - exports2.extract = require_extract(); - exports2.pack = require_pack(); - } -}); - -// node_modules/decompress-tar/index.js -var require_decompress_tar = __commonJS({ - "node_modules/decompress-tar/index.js"(exports2, module3) { - "use strict"; - var fileType = require_file_type(); - var isStream = require_is_stream(); - var tarStream = require_tar_stream(); - module3.exports = () => (input) => { - if (!Buffer.isBuffer(input) && !isStream(input)) { - return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); - } - if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "tar")) { - return Promise.resolve([]); - } - const extract = tarStream.extract(); - const files = []; - extract.on("entry", (header, stream2, cb) => { - const chunk = []; - stream2.on("data", (data) => chunk.push(data)); - stream2.on("end", () => { - const file9 = { - data: Buffer.concat(chunk), - mode: header.mode, - mtime: header.mtime, - path: header.name, - type: header.type - }; - if (header.type === "symlink" || header.type === "link") { - file9.linkname = header.linkname; - } - files.push(file9); - cb(); - }); - }); - const promise = new Promise((resolve2, reject) => { - if (!Buffer.isBuffer(input)) { - input.on("error", reject); - } - extract.on("finish", () => resolve2(files)); - extract.on("error", reject); - }); - extract.then = promise.then.bind(promise); - extract.catch = promise.catch.bind(promise); - if (Buffer.isBuffer(input)) { - extract.end(input); - } else { - input.pipe(extract); - } - return extract; - }; - } -}); - -// node_modules/decompress-tarbz2/node_modules/file-type/index.js -var require_file_type2 = __commonJS({ - "node_modules/decompress-tarbz2/node_modules/file-type/index.js"(exports2, module3) { - "use strict"; - var toBytes = (s) => Array.from(s).map((c) => c.charCodeAt(0)); - var xpiZipFilename = toBytes("META-INF/mozilla.rsa"); - var oxmlContentTypes = toBytes("[Content_Types].xml"); - var oxmlRels = toBytes("_rels/.rels"); - module3.exports = (input) => { - const buf = new Uint8Array(input); - if (!(buf && buf.length > 1)) { - return null; - } - const check = (header, opts) => { - opts = Object.assign({ - offset: 0 - }, opts); - for (let i = 0; i < header.length; i++) { - if (opts.mask) { - if (header[i] !== (opts.mask[i] & buf[i + opts.offset])) { - return false; - } - } else if (header[i] !== buf[i + opts.offset]) { - return false; - } - } - return true; - }; - if (check([255, 216, 255])) { - return { - ext: "jpg", - mime: "image/jpeg" - }; - } - if (check([137, 80, 78, 71, 13, 10, 26, 10])) { - return { - ext: "png", - mime: "image/png" - }; - } - if (check([71, 73, 70])) { - return { - ext: "gif", - mime: "image/gif" - }; - } - if (check([87, 69, 66, 80], { offset: 8 })) { - return { - ext: "webp", - mime: "image/webp" - }; - } - if (check([70, 76, 73, 70])) { - return { - ext: "flif", - mime: "image/flif" - }; - } - if ((check([73, 73, 42, 0]) || check([77, 77, 0, 42])) && check([67, 82], { offset: 8 })) { - return { - ext: "cr2", - mime: "image/x-canon-cr2" - }; - } - if (check([73, 73, 42, 0]) || check([77, 77, 0, 42])) { - return { - ext: "tif", - mime: "image/tiff" - }; - } - if (check([66, 77])) { - return { - ext: "bmp", - mime: "image/bmp" - }; - } - if (check([73, 73, 188])) { - return { - ext: "jxr", - mime: "image/vnd.ms-photo" - }; - } - if (check([56, 66, 80, 83])) { - return { - ext: "psd", - mime: "image/vnd.adobe.photoshop" - }; - } - if (check([80, 75, 3, 4])) { - if (check([109, 105, 109, 101, 116, 121, 112, 101, 97, 112, 112, 108, 105, 99, 97, 116, 105, 111, 110, 47, 101, 112, 117, 98, 43, 122, 105, 112], { offset: 30 })) { - return { - ext: "epub", - mime: "application/epub+zip" - }; - } - if (check(xpiZipFilename, { offset: 30 })) { - return { - ext: "xpi", - mime: "application/x-xpinstall" - }; - } - if (check(oxmlContentTypes, { offset: 30 }) || check(oxmlRels, { offset: 30 })) { - const sliced = buf.subarray(4, 4 + 2e3); - const nextZipHeaderIndex = (arr) => arr.findIndex((el, i, arr2) => arr2[i] === 80 && arr2[i + 1] === 75 && arr2[i + 2] === 3 && arr2[i + 3] === 4); - const header2Pos = nextZipHeaderIndex(sliced); - if (header2Pos !== -1) { - const slicedAgain = buf.subarray(header2Pos + 8, header2Pos + 8 + 1e3); - const header3Pos = nextZipHeaderIndex(slicedAgain); - if (header3Pos !== -1) { - const offset = 8 + header2Pos + header3Pos + 30; - if (check(toBytes("word/"), { offset })) { - return { - ext: "docx", - mime: "application/vnd.openxmlformats-officedocument.wordprocessingml.document" - }; - } - if (check(toBytes("ppt/"), { offset })) { - return { - ext: "pptx", - mime: "application/vnd.openxmlformats-officedocument.presentationml.presentation" - }; - } - if (check(toBytes("xl/"), { offset })) { - return { - ext: "xlsx", - mime: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" - }; - } - } - } - } - } - if (check([80, 75]) && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { - return { - ext: "zip", - mime: "application/zip" - }; - } - if (check([117, 115, 116, 97, 114], { offset: 257 })) { - return { - ext: "tar", - mime: "application/x-tar" - }; - } - if (check([82, 97, 114, 33, 26, 7]) && (buf[6] === 0 || buf[6] === 1)) { - return { - ext: "rar", - mime: "application/x-rar-compressed" - }; - } - if (check([31, 139, 8])) { - return { - ext: "gz", - mime: "application/gzip" - }; - } - if (check([66, 90, 104])) { - return { - ext: "bz2", - mime: "application/x-bzip2" - }; - } - if (check([55, 122, 188, 175, 39, 28])) { - return { - ext: "7z", - mime: "application/x-7z-compressed" - }; - } - if (check([120, 1])) { - return { - ext: "dmg", - mime: "application/x-apple-diskimage" - }; - } - if (check([51, 103, 112, 53]) || // 3gp5 - check([0, 0, 0]) && check([102, 116, 121, 112], { offset: 4 }) && (check([109, 112, 52, 49], { offset: 8 }) || // MP41 - check([109, 112, 52, 50], { offset: 8 }) || // MP42 - check([105, 115, 111, 109], { offset: 8 }) || // ISOM - check([105, 115, 111, 50], { offset: 8 }) || // ISO2 - check([109, 109, 112, 52], { offset: 8 }) || // MMP4 - check([77, 52, 86], { offset: 8 }) || // M4V - check([100, 97, 115, 104], { offset: 8 }))) { - return { - ext: "mp4", - mime: "video/mp4" - }; - } - if (check([77, 84, 104, 100])) { - return { - ext: "mid", - mime: "audio/midi" - }; - } - if (check([26, 69, 223, 163])) { - const sliced = buf.subarray(4, 4 + 4096); - const idPos = sliced.findIndex((el, i, arr) => arr[i] === 66 && arr[i + 1] === 130); - if (idPos !== -1) { - const docTypePos = idPos + 3; - const findDocType = (type2) => Array.from(type2).every((c, i) => sliced[docTypePos + i] === c.charCodeAt(0)); - if (findDocType("matroska")) { - return { - ext: "mkv", - mime: "video/x-matroska" - }; - } - if (findDocType("webm")) { - return { - ext: "webm", - mime: "video/webm" - }; - } - } - } - if (check([0, 0, 0, 20, 102, 116, 121, 112, 113, 116, 32, 32]) || check([102, 114, 101, 101], { offset: 4 }) || check([102, 116, 121, 112, 113, 116, 32, 32], { offset: 4 }) || check([109, 100, 97, 116], { offset: 4 }) || // MJPEG - check([119, 105, 100, 101], { offset: 4 })) { - return { - ext: "mov", - mime: "video/quicktime" - }; - } - if (check([82, 73, 70, 70]) && check([65, 86, 73], { offset: 8 })) { - return { - ext: "avi", - mime: "video/x-msvideo" - }; - } - if (check([48, 38, 178, 117, 142, 102, 207, 17, 166, 217])) { - return { - ext: "wmv", - mime: "video/x-ms-wmv" - }; - } - if (check([0, 0, 1, 186])) { - return { - ext: "mpg", - mime: "video/mpeg" - }; - } - for (let start = 0; start < 2 && start < buf.length - 16; start++) { - if (check([73, 68, 51], { offset: start }) || // ID3 header - check([255, 226], { offset: start, mask: [255, 226] })) { - return { - ext: "mp3", - mime: "audio/mpeg" - }; - } - } - if (check([102, 116, 121, 112, 77, 52, 65], { offset: 4 }) || check([77, 52, 65, 32])) { - return { - ext: "m4a", - mime: "audio/m4a" - }; - } - if (check([79, 112, 117, 115, 72, 101, 97, 100], { offset: 28 })) { - return { - ext: "opus", - mime: "audio/opus" - }; - } - if (check([79, 103, 103, 83])) { - return { - ext: "ogg", - mime: "audio/ogg" - }; - } - if (check([102, 76, 97, 67])) { - return { - ext: "flac", - mime: "audio/x-flac" - }; - } - if (check([82, 73, 70, 70]) && check([87, 65, 86, 69], { offset: 8 })) { - return { - ext: "wav", - mime: "audio/x-wav" - }; - } - if (check([35, 33, 65, 77, 82, 10])) { - return { - ext: "amr", - mime: "audio/amr" - }; - } - if (check([37, 80, 68, 70])) { - return { - ext: "pdf", - mime: "application/pdf" - }; - } - if (check([77, 90])) { - return { - ext: "exe", - mime: "application/x-msdownload" - }; - } - if ((buf[0] === 67 || buf[0] === 70) && check([87, 83], { offset: 1 })) { - return { - ext: "swf", - mime: "application/x-shockwave-flash" - }; - } - if (check([123, 92, 114, 116, 102])) { - return { - ext: "rtf", - mime: "application/rtf" - }; - } - if (check([0, 97, 115, 109])) { - return { - ext: "wasm", - mime: "application/wasm" - }; - } - if (check([119, 79, 70, 70]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { - return { - ext: "woff", - mime: "font/woff" - }; - } - if (check([119, 79, 70, 50]) && (check([0, 1, 0, 0], { offset: 4 }) || check([79, 84, 84, 79], { offset: 4 }))) { - return { - ext: "woff2", - mime: "font/woff2" - }; - } - if (check([76, 80], { offset: 34 }) && (check([0, 0, 1], { offset: 8 }) || check([1, 0, 2], { offset: 8 }) || check([2, 0, 2], { offset: 8 }))) { - return { - ext: "eot", - mime: "application/octet-stream" - }; - } - if (check([0, 1, 0, 0, 0])) { - return { - ext: "ttf", - mime: "font/ttf" - }; - } - if (check([79, 84, 84, 79, 0])) { - return { - ext: "otf", - mime: "font/otf" - }; - } - if (check([0, 0, 1, 0])) { - return { - ext: "ico", - mime: "image/x-icon" - }; - } - if (check([70, 76, 86, 1])) { - return { - ext: "flv", - mime: "video/x-flv" - }; - } - if (check([37, 33])) { - return { - ext: "ps", - mime: "application/postscript" - }; - } - if (check([253, 55, 122, 88, 90, 0])) { - return { - ext: "xz", - mime: "application/x-xz" - }; - } - if (check([83, 81, 76, 105])) { - return { - ext: "sqlite", - mime: "application/x-sqlite3" - }; - } - if (check([78, 69, 83, 26])) { - return { - ext: "nes", - mime: "application/x-nintendo-nes-rom" - }; - } - if (check([67, 114, 50, 52])) { - return { - ext: "crx", - mime: "application/x-google-chrome-extension" - }; - } - if (check([77, 83, 67, 70]) || check([73, 83, 99, 40])) { - return { - ext: "cab", - mime: "application/vnd.ms-cab-compressed" - }; - } - if (check([33, 60, 97, 114, 99, 104, 62, 10, 100, 101, 98, 105, 97, 110, 45, 98, 105, 110, 97, 114, 121])) { - return { - ext: "deb", - mime: "application/x-deb" - }; - } - if (check([33, 60, 97, 114, 99, 104, 62])) { - return { - ext: "ar", - mime: "application/x-unix-archive" - }; - } - if (check([237, 171, 238, 219])) { - return { - ext: "rpm", - mime: "application/x-rpm" - }; - } - if (check([31, 160]) || check([31, 157])) { - return { - ext: "Z", - mime: "application/x-compress" - }; - } - if (check([76, 90, 73, 80])) { - return { - ext: "lz", - mime: "application/x-lzip" - }; - } - if (check([208, 207, 17, 224, 161, 177, 26, 225])) { - return { - ext: "msi", - mime: "application/x-msi" - }; - } - if (check([6, 14, 43, 52, 2, 5, 1, 1, 13, 1, 2, 1, 1, 2])) { - return { - ext: "mxf", - mime: "application/mxf" - }; - } - if (check([71], { offset: 4 }) && (check([71], { offset: 192 }) || check([71], { offset: 196 }))) { - return { - ext: "mts", - mime: "video/mp2t" - }; - } - if (check([66, 76, 69, 78, 68, 69, 82])) { - return { - ext: "blend", - mime: "application/x-blender" - }; - } - if (check([66, 80, 71, 251])) { - return { - ext: "bpg", - mime: "image/bpg" - }; - } - return null; - }; - } -}); - -// node_modules/seek-bzip/lib/bitreader.js -var require_bitreader = __commonJS({ - "node_modules/seek-bzip/lib/bitreader.js"(exports2, module3) { - var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; - var BitReader = function(stream2) { - this.stream = stream2; - this.bitOffset = 0; - this.curByte = 0; - this.hasByte = false; - }; - BitReader.prototype._ensureByte = function() { - if (!this.hasByte) { - this.curByte = this.stream.readByte(); - this.hasByte = true; - } - }; - BitReader.prototype.read = function(bits) { - var result = 0; - while (bits > 0) { - this._ensureByte(); - var remaining = 8 - this.bitOffset; - if (bits >= remaining) { - result <<= remaining; - result |= BITMASK[remaining] & this.curByte; - this.hasByte = false; - this.bitOffset = 0; - bits -= remaining; - } else { - result <<= bits; - var shift = remaining - bits; - result |= (this.curByte & BITMASK[bits] << shift) >> shift; - this.bitOffset += bits; - bits = 0; - } - } - return result; - }; - BitReader.prototype.seek = function(pos) { - var n_bit = pos % 8; - var n_byte = (pos - n_bit) / 8; - this.bitOffset = n_bit; - this.stream.seek(n_byte); - this.hasByte = false; - }; - BitReader.prototype.pi = function() { - var buf = new Buffer(6), i; - for (i = 0; i < buf.length; i++) { - buf[i] = this.read(8); - } - return buf.toString("hex"); - }; - module3.exports = BitReader; - } -}); - -// node_modules/seek-bzip/lib/stream.js -var require_stream2 = __commonJS({ - "node_modules/seek-bzip/lib/stream.js"(exports2, module3) { - var Stream = function() { - }; - Stream.prototype.readByte = function() { - throw new Error("abstract method readByte() not implemented"); - }; - Stream.prototype.read = function(buffer, bufOffset, length) { - var bytesRead = 0; - while (bytesRead < length) { - var c = this.readByte(); - if (c < 0) { - return bytesRead === 0 ? -1 : bytesRead; - } - buffer[bufOffset++] = c; - bytesRead++; - } - return bytesRead; - }; - Stream.prototype.seek = function(new_pos) { - throw new Error("abstract method seek() not implemented"); - }; - Stream.prototype.writeByte = function(_byte) { - throw new Error("abstract method readByte() not implemented"); - }; - Stream.prototype.write = function(buffer, bufOffset, length) { - var i; - for (i = 0; i < length; i++) { - this.writeByte(buffer[bufOffset++]); - } - return length; - }; - Stream.prototype.flush = function() { - }; - module3.exports = Stream; - } -}); - -// node_modules/seek-bzip/lib/crc32.js -var require_crc32 = __commonJS({ - "node_modules/seek-bzip/lib/crc32.js"(exports2, module3) { - module3.exports = (function() { - var crc32Lookup = new Uint32Array([ - 0, - 79764919, - 159529838, - 222504665, - 319059676, - 398814059, - 445009330, - 507990021, - 638119352, - 583659535, - 797628118, - 726387553, - 890018660, - 835552979, - 1015980042, - 944750013, - 1276238704, - 1221641927, - 1167319070, - 1095957929, - 1595256236, - 1540665371, - 1452775106, - 1381403509, - 1780037320, - 1859660671, - 1671105958, - 1733955601, - 2031960084, - 2111593891, - 1889500026, - 1952343757, - 2552477408, - 2632100695, - 2443283854, - 2506133561, - 2334638140, - 2414271883, - 2191915858, - 2254759653, - 3190512472, - 3135915759, - 3081330742, - 3009969537, - 2905550212, - 2850959411, - 2762807018, - 2691435357, - 3560074640, - 3505614887, - 3719321342, - 3648080713, - 3342211916, - 3287746299, - 3467911202, - 3396681109, - 4063920168, - 4143685023, - 4223187782, - 4286162673, - 3779000052, - 3858754371, - 3904687514, - 3967668269, - 881225847, - 809987520, - 1023691545, - 969234094, - 662832811, - 591600412, - 771767749, - 717299826, - 311336399, - 374308984, - 453813921, - 533576470, - 25881363, - 88864420, - 134795389, - 214552010, - 2023205639, - 2086057648, - 1897238633, - 1976864222, - 1804852699, - 1867694188, - 1645340341, - 1724971778, - 1587496639, - 1516133128, - 1461550545, - 1406951526, - 1302016099, - 1230646740, - 1142491917, - 1087903418, - 2896545431, - 2825181984, - 2770861561, - 2716262478, - 3215044683, - 3143675388, - 3055782693, - 3001194130, - 2326604591, - 2389456536, - 2200899649, - 2280525302, - 2578013683, - 2640855108, - 2418763421, - 2498394922, - 3769900519, - 3832873040, - 3912640137, - 3992402750, - 4088425275, - 4151408268, - 4197601365, - 4277358050, - 3334271071, - 3263032808, - 3476998961, - 3422541446, - 3585640067, - 3514407732, - 3694837229, - 3640369242, - 1762451694, - 1842216281, - 1619975040, - 1682949687, - 2047383090, - 2127137669, - 1938468188, - 2001449195, - 1325665622, - 1271206113, - 1183200824, - 1111960463, - 1543535498, - 1489069629, - 1434599652, - 1363369299, - 622672798, - 568075817, - 748617968, - 677256519, - 907627842, - 853037301, - 1067152940, - 995781531, - 51762726, - 131386257, - 177728840, - 240578815, - 269590778, - 349224269, - 429104020, - 491947555, - 4046411278, - 4126034873, - 4172115296, - 4234965207, - 3794477266, - 3874110821, - 3953728444, - 4016571915, - 3609705398, - 3555108353, - 3735388376, - 3664026991, - 3290680682, - 3236090077, - 3449943556, - 3378572211, - 3174993278, - 3120533705, - 3032266256, - 2961025959, - 2923101090, - 2868635157, - 2813903052, - 2742672763, - 2604032198, - 2683796849, - 2461293480, - 2524268063, - 2284983834, - 2364738477, - 2175806836, - 2238787779, - 1569362073, - 1498123566, - 1409854455, - 1355396672, - 1317987909, - 1246755826, - 1192025387, - 1137557660, - 2072149281, - 2135122070, - 1912620623, - 1992383480, - 1753615357, - 1816598090, - 1627664531, - 1707420964, - 295390185, - 358241886, - 404320391, - 483945776, - 43990325, - 106832002, - 186451547, - 266083308, - 932423249, - 861060070, - 1041341759, - 986742920, - 613929101, - 542559546, - 756411363, - 701822548, - 3316196985, - 3244833742, - 3425377559, - 3370778784, - 3601682597, - 3530312978, - 3744426955, - 3689838204, - 3819031489, - 3881883254, - 3928223919, - 4007849240, - 4037393693, - 4100235434, - 4180117107, - 4259748804, - 2310601993, - 2373574846, - 2151335527, - 2231098320, - 2596047829, - 2659030626, - 2470359227, - 2550115596, - 2947551409, - 2876312838, - 2788305887, - 2733848168, - 3165939309, - 3094707162, - 3040238851, - 2985771188 - ]); - var CRC32 = function() { - var crc = 4294967295; - this.getCRC = function() { - return ~crc >>> 0; - }; - this.updateCRC = function(value) { - crc = crc << 8 ^ crc32Lookup[(crc >>> 24 ^ value) & 255]; - }; - this.updateCRCRun = function(value, count) { - while (count-- > 0) { - crc = crc << 8 ^ crc32Lookup[(crc >>> 24 ^ value) & 255]; - } - }; - }; - return CRC32; - })(); - } -}); - -// node_modules/seek-bzip/package.json -var require_package = __commonJS({ - "node_modules/seek-bzip/package.json"(exports2, module3) { - module3.exports = { - name: "seek-bzip", - version: "1.0.6", - contributors: [ - "C. Scott Ananian (http://cscott.net)", - "Eli Skeggs", - "Kevin Kwok", - "Rob Landley (http://landley.net)" - ], - description: "a pure-JavaScript Node.JS module for random-access decoding bzip2 data", - main: "./lib/index.js", - repository: { - type: "git", - url: "https://github.com/cscott/seek-bzip.git" - }, - license: "MIT", - bin: { - "seek-bunzip": "./bin/seek-bunzip", - "seek-table": "./bin/seek-bzip-table" - }, - directories: { - test: "test" - }, - dependencies: { - commander: "^2.8.1" - }, - devDependencies: { - fibers: "~1.0.6", - mocha: "~2.2.5" - }, - scripts: { - test: "mocha" - } - }; - } -}); - -// node_modules/seek-bzip/lib/index.js -var require_lib2 = __commonJS({ - "node_modules/seek-bzip/lib/index.js"(exports2, module3) { - var BitReader = require_bitreader(); - var Stream = require_stream2(); - var CRC32 = require_crc32(); - var pjson = require_package(); - var MAX_HUFCODE_BITS = 20; - var MAX_SYMBOLS = 258; - var SYMBOL_RUNA = 0; - var SYMBOL_RUNB = 1; - var MIN_GROUPS = 2; - var MAX_GROUPS = 6; - var GROUP_SIZE = 50; - var WHOLEPI = "314159265359"; - var SQRTPI = "177245385090"; - var mtf = function(array4, index4) { - var src = array4[index4], i; - for (i = index4; i > 0; i--) { - array4[i] = array4[i - 1]; - } - array4[0] = src; - return src; - }; - var Err = { - OK: 0, - LAST_BLOCK: -1, - NOT_BZIP_DATA: -2, - UNEXPECTED_INPUT_EOF: -3, - UNEXPECTED_OUTPUT_EOF: -4, - DATA_ERROR: -5, - OUT_OF_MEMORY: -6, - OBSOLETE_INPUT: -7, - END_OF_BLOCK: -8 - }; - var ErrorMessages = {}; - ErrorMessages[Err.LAST_BLOCK] = "Bad file checksum"; - ErrorMessages[Err.NOT_BZIP_DATA] = "Not bzip data"; - ErrorMessages[Err.UNEXPECTED_INPUT_EOF] = "Unexpected input EOF"; - ErrorMessages[Err.UNEXPECTED_OUTPUT_EOF] = "Unexpected output EOF"; - ErrorMessages[Err.DATA_ERROR] = "Data error"; - ErrorMessages[Err.OUT_OF_MEMORY] = "Out of memory"; - ErrorMessages[Err.OBSOLETE_INPUT] = "Obsolete (pre 0.9.5) bzip format not supported."; - var _throw = function(status, optDetail) { - var msg = ErrorMessages[status] || "unknown error"; - if (optDetail) { - msg += ": " + optDetail; - } - var e = new TypeError(msg); - e.errorCode = status; - throw e; - }; - var Bunzip = function(inputStream, outputStream) { - this.writePos = this.writeCurrent = this.writeCount = 0; - this._start_bunzip(inputStream, outputStream); - }; - Bunzip.prototype._init_block = function() { - var moreBlocks = this._get_next_block(); - if (!moreBlocks) { - this.writeCount = -1; - return false; - } - this.blockCRC = new CRC32(); - return true; - }; - Bunzip.prototype._start_bunzip = function(inputStream, outputStream) { - var buf = new Buffer(4); - if (inputStream.read(buf, 0, 4) !== 4 || String.fromCharCode(buf[0], buf[1], buf[2]) !== "BZh") - _throw(Err.NOT_BZIP_DATA, "bad magic"); - var level = buf[3] - 48; - if (level < 1 || level > 9) - _throw(Err.NOT_BZIP_DATA, "level out of range"); - this.reader = new BitReader(inputStream); - this.dbufSize = 1e5 * level; - this.nextoutput = 0; - this.outputStream = outputStream; - this.streamCRC = 0; - }; - Bunzip.prototype._get_next_block = function() { - var i, j, k; - var reader = this.reader; - var h = reader.pi(); - if (h === SQRTPI) { - return false; - } - if (h !== WHOLEPI) - _throw(Err.NOT_BZIP_DATA); - this.targetBlockCRC = reader.read(32) >>> 0; - this.streamCRC = (this.targetBlockCRC ^ (this.streamCRC << 1 | this.streamCRC >>> 31)) >>> 0; - if (reader.read(1)) - _throw(Err.OBSOLETE_INPUT); - var origPointer = reader.read(24); - if (origPointer > this.dbufSize) - _throw(Err.DATA_ERROR, "initial position out of bounds"); - var t = reader.read(16); - var symToByte = new Buffer(256), symTotal = 0; - for (i = 0; i < 16; i++) { - if (t & 1 << 15 - i) { - var o = i * 16; - k = reader.read(16); - for (j = 0; j < 16; j++) - if (k & 1 << 15 - j) - symToByte[symTotal++] = o + j; - } - } - var groupCount = reader.read(3); - if (groupCount < MIN_GROUPS || groupCount > MAX_GROUPS) - _throw(Err.DATA_ERROR); - var nSelectors = reader.read(15); - if (nSelectors === 0) - _throw(Err.DATA_ERROR); - var mtfSymbol = new Buffer(256); - for (i = 0; i < groupCount; i++) - mtfSymbol[i] = i; - var selectors = new Buffer(nSelectors); - for (i = 0; i < nSelectors; i++) { - for (j = 0; reader.read(1); j++) - if (j >= groupCount) _throw(Err.DATA_ERROR); - selectors[i] = mtf(mtfSymbol, j); - } - var symCount = symTotal + 2; - var groups = [], hufGroup; - for (j = 0; j < groupCount; j++) { - var length = new Buffer(symCount), temp = new Uint16Array(MAX_HUFCODE_BITS + 1); - t = reader.read(5); - for (i = 0; i < symCount; i++) { - for (; ; ) { - if (t < 1 || t > MAX_HUFCODE_BITS) _throw(Err.DATA_ERROR); - if (!reader.read(1)) - break; - if (!reader.read(1)) - t++; - else - t--; - } - length[i] = t; - } - var minLen, maxLen; - minLen = maxLen = length[0]; - for (i = 1; i < symCount; i++) { - if (length[i] > maxLen) - maxLen = length[i]; - else if (length[i] < minLen) - minLen = length[i]; - } - hufGroup = {}; - groups.push(hufGroup); - hufGroup.permute = new Uint16Array(MAX_SYMBOLS); - hufGroup.limit = new Uint32Array(MAX_HUFCODE_BITS + 2); - hufGroup.base = new Uint32Array(MAX_HUFCODE_BITS + 1); - hufGroup.minLen = minLen; - hufGroup.maxLen = maxLen; - var pp = 0; - for (i = minLen; i <= maxLen; i++) { - temp[i] = hufGroup.limit[i] = 0; - for (t = 0; t < symCount; t++) - if (length[t] === i) - hufGroup.permute[pp++] = t; - } - for (i = 0; i < symCount; i++) - temp[length[i]]++; - pp = t = 0; - for (i = minLen; i < maxLen; i++) { - pp += temp[i]; - hufGroup.limit[i] = pp - 1; - pp <<= 1; - t += temp[i]; - hufGroup.base[i + 1] = pp - t; - } - hufGroup.limit[maxLen + 1] = Number.MAX_VALUE; - hufGroup.limit[maxLen] = pp + temp[maxLen] - 1; - hufGroup.base[minLen] = 0; - } - var byteCount = new Uint32Array(256); - for (i = 0; i < 256; i++) - mtfSymbol[i] = i; - var runPos = 0, dbufCount = 0, selector3 = 0, uc; - var dbuf = this.dbuf = new Uint32Array(this.dbufSize); - symCount = 0; - for (; ; ) { - if (!symCount--) { - symCount = GROUP_SIZE - 1; - if (selector3 >= nSelectors) { - _throw(Err.DATA_ERROR); - } - hufGroup = groups[selectors[selector3++]]; - } - i = hufGroup.minLen; - j = reader.read(i); - for (; ; i++) { - if (i > hufGroup.maxLen) { - _throw(Err.DATA_ERROR); - } - if (j <= hufGroup.limit[i]) - break; - j = j << 1 | reader.read(1); - } - j -= hufGroup.base[i]; - if (j < 0 || j >= MAX_SYMBOLS) { - _throw(Err.DATA_ERROR); - } - var nextSym = hufGroup.permute[j]; - if (nextSym === SYMBOL_RUNA || nextSym === SYMBOL_RUNB) { - if (!runPos) { - runPos = 1; - t = 0; - } - if (nextSym === SYMBOL_RUNA) - t += runPos; - else - t += 2 * runPos; - runPos <<= 1; - continue; - } - if (runPos) { - runPos = 0; - if (dbufCount + t > this.dbufSize) { - _throw(Err.DATA_ERROR); - } - uc = symToByte[mtfSymbol[0]]; - byteCount[uc] += t; - while (t--) - dbuf[dbufCount++] = uc; - } - if (nextSym > symTotal) - break; - if (dbufCount >= this.dbufSize) { - _throw(Err.DATA_ERROR); - } - i = nextSym - 1; - uc = mtf(mtfSymbol, i); - uc = symToByte[uc]; - byteCount[uc]++; - dbuf[dbufCount++] = uc; - } - if (origPointer < 0 || origPointer >= dbufCount) { - _throw(Err.DATA_ERROR); - } - j = 0; - for (i = 0; i < 256; i++) { - k = j + byteCount[i]; - byteCount[i] = j; - j = k; - } - for (i = 0; i < dbufCount; i++) { - uc = dbuf[i] & 255; - dbuf[byteCount[uc]] |= i << 8; - byteCount[uc]++; - } - var pos = 0, current = 0, run = 0; - if (dbufCount) { - pos = dbuf[origPointer]; - current = pos & 255; - pos >>= 8; - run = -1; - } - this.writePos = pos; - this.writeCurrent = current; - this.writeCount = dbufCount; - this.writeRun = run; - return true; - }; - Bunzip.prototype._read_bunzip = function(outputBuffer, len) { - var copies, previous, outbyte; - if (this.writeCount < 0) { - return 0; - } - var gotcount = 0; - var dbuf = this.dbuf, pos = this.writePos, current = this.writeCurrent; - var dbufCount = this.writeCount, outputsize = this.outputsize; - var run = this.writeRun; - while (dbufCount) { - dbufCount--; - previous = current; - pos = dbuf[pos]; - current = pos & 255; - pos >>= 8; - if (run++ === 3) { - copies = current; - outbyte = previous; - current = -1; - } else { - copies = 1; - outbyte = current; - } - this.blockCRC.updateCRCRun(outbyte, copies); - while (copies--) { - this.outputStream.writeByte(outbyte); - this.nextoutput++; - } - if (current != previous) - run = 0; - } - this.writeCount = dbufCount; - if (this.blockCRC.getCRC() !== this.targetBlockCRC) { - _throw(Err.DATA_ERROR, "Bad block CRC (got " + this.blockCRC.getCRC().toString(16) + " expected " + this.targetBlockCRC.toString(16) + ")"); - } - return this.nextoutput; - }; - var coerceInputStream = function(input) { - if ("readByte" in input) { - return input; - } - var inputStream = new Stream(); - inputStream.pos = 0; - inputStream.readByte = function() { - return input[this.pos++]; - }; - inputStream.seek = function(pos) { - this.pos = pos; - }; - inputStream.eof = function() { - return this.pos >= input.length; - }; - return inputStream; - }; - var coerceOutputStream = function(output) { - var outputStream = new Stream(); - var resizeOk = true; - if (output) { - if (typeof output === "number") { - outputStream.buffer = new Buffer(output); - resizeOk = false; - } else if ("writeByte" in output) { - return output; - } else { - outputStream.buffer = output; - resizeOk = false; - } - } else { - outputStream.buffer = new Buffer(16384); - } - outputStream.pos = 0; - outputStream.writeByte = function(_byte) { - if (resizeOk && this.pos >= this.buffer.length) { - var newBuffer = new Buffer(this.buffer.length * 2); - this.buffer.copy(newBuffer); - this.buffer = newBuffer; - } - this.buffer[this.pos++] = _byte; - }; - outputStream.getBuffer = function() { - if (this.pos !== this.buffer.length) { - if (!resizeOk) - throw new TypeError("outputsize does not match decoded input"); - var newBuffer = new Buffer(this.pos); - this.buffer.copy(newBuffer, 0, 0, this.pos); - this.buffer = newBuffer; - } - return this.buffer; - }; - outputStream._coerced = true; - return outputStream; - }; - Bunzip.Err = Err; - Bunzip.decode = function(input, output, multistream) { - var inputStream = coerceInputStream(input); - var outputStream = coerceOutputStream(output); - var bz = new Bunzip(inputStream, outputStream); - while (true) { - if ("eof" in inputStream && inputStream.eof()) break; - if (bz._init_block()) { - bz._read_bunzip(); - } else { - var targetStreamCRC = bz.reader.read(32) >>> 0; - if (targetStreamCRC !== bz.streamCRC) { - _throw(Err.DATA_ERROR, "Bad stream CRC (got " + bz.streamCRC.toString(16) + " expected " + targetStreamCRC.toString(16) + ")"); - } - if (multistream && "eof" in inputStream && !inputStream.eof()) { - bz._start_bunzip(inputStream, outputStream); - } else break; - } - } - if ("getBuffer" in outputStream) - return outputStream.getBuffer(); - }; - Bunzip.decodeBlock = function(input, pos, output) { - var inputStream = coerceInputStream(input); - var outputStream = coerceOutputStream(output); - var bz = new Bunzip(inputStream, outputStream); - bz.reader.seek(pos); - var moreBlocks = bz._get_next_block(); - if (moreBlocks) { - bz.blockCRC = new CRC32(); - bz.writeCopies = 0; - bz._read_bunzip(); - } - if ("getBuffer" in outputStream) - return outputStream.getBuffer(); - }; - Bunzip.table = function(input, callback, multistream) { - var inputStream = new Stream(); - inputStream.delegate = coerceInputStream(input); - inputStream.pos = 0; - inputStream.readByte = function() { - this.pos++; - return this.delegate.readByte(); - }; - if (inputStream.delegate.eof) { - inputStream.eof = inputStream.delegate.eof.bind(inputStream.delegate); - } - var outputStream = new Stream(); - outputStream.pos = 0; - outputStream.writeByte = function() { - this.pos++; - }; - var bz = new Bunzip(inputStream, outputStream); - var blockSize = bz.dbufSize; - while (true) { - if ("eof" in inputStream && inputStream.eof()) break; - var position = inputStream.pos * 8 + bz.reader.bitOffset; - if (bz.reader.hasByte) { - position -= 8; - } - if (bz._init_block()) { - var start = outputStream.pos; - bz._read_bunzip(); - callback(position, outputStream.pos - start); - } else { - var crc = bz.reader.read(32); - if (multistream && "eof" in inputStream && !inputStream.eof()) { - bz._start_bunzip(inputStream, outputStream); - console.assert( - bz.dbufSize === blockSize, - "shouldn't change block size within multistream file" - ); - } else break; - } - } - }; - Bunzip.Stream = Stream; - Bunzip.version = pjson.version; - Bunzip.license = pjson.license; - module3.exports = Bunzip; - } -}); - -// node_modules/through/index.js -var require_through = __commonJS({ - "node_modules/through/index.js"(exports2, module3) { - var Stream = require("stream"); - exports2 = module3.exports = through; - through.through = through; - function through(write, end, opts) { - write = write || function(data) { - this.queue(data); - }; - end = end || function() { - this.queue(null); - }; - var ended = false, destroyed = false, buffer = [], _ended = false; - var stream2 = new Stream(); - stream2.readable = stream2.writable = true; - stream2.paused = false; - stream2.autoDestroy = !(opts && opts.autoDestroy === false); - stream2.write = function(data) { - write.call(this, data); - return !stream2.paused; - }; - function drain() { - while (buffer.length && !stream2.paused) { - var data = buffer.shift(); - if (null === data) - return stream2.emit("end"); - else - stream2.emit("data", data); - } - } - stream2.queue = stream2.push = function(data) { - if (_ended) return stream2; - if (data === null) _ended = true; - buffer.push(data); - drain(); - return stream2; - }; - stream2.on("end", function() { - stream2.readable = false; - if (!stream2.writable && stream2.autoDestroy) - process.nextTick(function() { - stream2.destroy(); - }); - }); - function _end() { - stream2.writable = false; - end.call(stream2); - if (!stream2.readable && stream2.autoDestroy) - stream2.destroy(); - } - stream2.end = function(data) { - if (ended) return; - ended = true; - if (arguments.length) stream2.write(data); - _end(); - return stream2; - }; - stream2.destroy = function() { - if (destroyed) return; - destroyed = true; - ended = true; - buffer.length = 0; - stream2.writable = stream2.readable = false; - stream2.emit("close"); - return stream2; - }; - stream2.pause = function() { - if (stream2.paused) return; - stream2.paused = true; - return stream2; - }; - stream2.resume = function() { - if (stream2.paused) { - stream2.paused = false; - stream2.emit("resume"); - } - drain(); - if (!stream2.paused) - stream2.emit("drain"); - return stream2; - }; - return stream2; - } - } -}); - -// node_modules/unbzip2-stream/lib/bzip2.js -var require_bzip2 = __commonJS({ - "node_modules/unbzip2-stream/lib/bzip2.js"(exports2, module3) { - function Bzip2Error(message3) { - this.name = "Bzip2Error"; - this.message = message3; - this.stack = new Error().stack; - } - Bzip2Error.prototype = new Error(); - var message2 = { - Error: function(message3) { - throw new Bzip2Error(message3); - } - }; - var bzip2 = {}; - bzip2.Bzip2Error = Bzip2Error; - bzip2.crcTable = [ - 0, - 79764919, - 159529838, - 222504665, - 319059676, - 398814059, - 445009330, - 507990021, - 638119352, - 583659535, - 797628118, - 726387553, - 890018660, - 835552979, - 1015980042, - 944750013, - 1276238704, - 1221641927, - 1167319070, - 1095957929, - 1595256236, - 1540665371, - 1452775106, - 1381403509, - 1780037320, - 1859660671, - 1671105958, - 1733955601, - 2031960084, - 2111593891, - 1889500026, - 1952343757, - 2552477408, - 2632100695, - 2443283854, - 2506133561, - 2334638140, - 2414271883, - 2191915858, - 2254759653, - 3190512472, - 3135915759, - 3081330742, - 3009969537, - 2905550212, - 2850959411, - 2762807018, - 2691435357, - 3560074640, - 3505614887, - 3719321342, - 3648080713, - 3342211916, - 3287746299, - 3467911202, - 3396681109, - 4063920168, - 4143685023, - 4223187782, - 4286162673, - 3779000052, - 3858754371, - 3904687514, - 3967668269, - 881225847, - 809987520, - 1023691545, - 969234094, - 662832811, - 591600412, - 771767749, - 717299826, - 311336399, - 374308984, - 453813921, - 533576470, - 25881363, - 88864420, - 134795389, - 214552010, - 2023205639, - 2086057648, - 1897238633, - 1976864222, - 1804852699, - 1867694188, - 1645340341, - 1724971778, - 1587496639, - 1516133128, - 1461550545, - 1406951526, - 1302016099, - 1230646740, - 1142491917, - 1087903418, - 2896545431, - 2825181984, - 2770861561, - 2716262478, - 3215044683, - 3143675388, - 3055782693, - 3001194130, - 2326604591, - 2389456536, - 2200899649, - 2280525302, - 2578013683, - 2640855108, - 2418763421, - 2498394922, - 3769900519, - 3832873040, - 3912640137, - 3992402750, - 4088425275, - 4151408268, - 4197601365, - 4277358050, - 3334271071, - 3263032808, - 3476998961, - 3422541446, - 3585640067, - 3514407732, - 3694837229, - 3640369242, - 1762451694, - 1842216281, - 1619975040, - 1682949687, - 2047383090, - 2127137669, - 1938468188, - 2001449195, - 1325665622, - 1271206113, - 1183200824, - 1111960463, - 1543535498, - 1489069629, - 1434599652, - 1363369299, - 622672798, - 568075817, - 748617968, - 677256519, - 907627842, - 853037301, - 1067152940, - 995781531, - 51762726, - 131386257, - 177728840, - 240578815, - 269590778, - 349224269, - 429104020, - 491947555, - 4046411278, - 4126034873, - 4172115296, - 4234965207, - 3794477266, - 3874110821, - 3953728444, - 4016571915, - 3609705398, - 3555108353, - 3735388376, - 3664026991, - 3290680682, - 3236090077, - 3449943556, - 3378572211, - 3174993278, - 3120533705, - 3032266256, - 2961025959, - 2923101090, - 2868635157, - 2813903052, - 2742672763, - 2604032198, - 2683796849, - 2461293480, - 2524268063, - 2284983834, - 2364738477, - 2175806836, - 2238787779, - 1569362073, - 1498123566, - 1409854455, - 1355396672, - 1317987909, - 1246755826, - 1192025387, - 1137557660, - 2072149281, - 2135122070, - 1912620623, - 1992383480, - 1753615357, - 1816598090, - 1627664531, - 1707420964, - 295390185, - 358241886, - 404320391, - 483945776, - 43990325, - 106832002, - 186451547, - 266083308, - 932423249, - 861060070, - 1041341759, - 986742920, - 613929101, - 542559546, - 756411363, - 701822548, - 3316196985, - 3244833742, - 3425377559, - 3370778784, - 3601682597, - 3530312978, - 3744426955, - 3689838204, - 3819031489, - 3881883254, - 3928223919, - 4007849240, - 4037393693, - 4100235434, - 4180117107, - 4259748804, - 2310601993, - 2373574846, - 2151335527, - 2231098320, - 2596047829, - 2659030626, - 2470359227, - 2550115596, - 2947551409, - 2876312838, - 2788305887, - 2733848168, - 3165939309, - 3094707162, - 3040238851, - 2985771188 - ]; - bzip2.array = function(bytes) { - var bit = 0, byte = 0; - var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; - return function(n) { - var result = 0; - while (n > 0) { - var left = 8 - bit; - if (n >= left) { - result <<= left; - result |= BITMASK[left] & bytes[byte++]; - bit = 0; - n -= left; - } else { - result <<= n; - result |= (bytes[byte] & BITMASK[n] << 8 - n - bit) >> 8 - n - bit; - bit += n; - n = 0; - } - } - return result; - }; - }; - bzip2.simple = function(srcbuffer, stream2) { - var bits = bzip2.array(srcbuffer); - var size = bzip2.header(bits); - var ret = false; - var bufsize = 1e5 * size; - var buf = new Int32Array(bufsize); - do { - ret = bzip2.decompress(bits, stream2, buf, bufsize); - } while (!ret); - }; - bzip2.header = function(bits) { - this.byteCount = new Int32Array(256); - this.symToByte = new Uint8Array(256); - this.mtfSymbol = new Int32Array(256); - this.selectors = new Uint8Array(32768); - if (bits(8 * 3) != 4348520) message2.Error("No magic number found"); - var i = bits(8) - 48; - if (i < 1 || i > 9) message2.Error("Not a BZIP archive"); - return i; - }; - bzip2.decompress = function(bits, stream2, buf, bufsize, streamCRC) { - var MAX_HUFCODE_BITS = 20; - var MAX_SYMBOLS = 258; - var SYMBOL_RUNA = 0; - var SYMBOL_RUNB = 1; - var GROUP_SIZE = 50; - var crc = 0 ^ -1; - for (var h = "", i = 0; i < 6; i++) h += bits(8).toString(16); - if (h == "177245385090") { - var finalCRC = bits(32) | 0; - if (finalCRC !== streamCRC) message2.Error("Error in bzip2: crc32 do not match"); - bits(null); - return null; - } - if (h != "314159265359") message2.Error("eek not valid bzip data"); - var crcblock = bits(32) | 0; - if (bits(1)) message2.Error("unsupported obsolete version"); - var origPtr = bits(24); - if (origPtr > bufsize) message2.Error("Initial position larger than buffer size"); - var t = bits(16); - var symTotal = 0; - for (i = 0; i < 16; i++) { - if (t & 1 << 15 - i) { - var k = bits(16); - for (j = 0; j < 16; j++) { - if (k & 1 << 15 - j) { - this.symToByte[symTotal++] = 16 * i + j; - } - } - } - } - var groupCount = bits(3); - if (groupCount < 2 || groupCount > 6) message2.Error("another error"); - var nSelectors = bits(15); - if (nSelectors == 0) message2.Error("meh"); - for (var i = 0; i < groupCount; i++) this.mtfSymbol[i] = i; - for (var i = 0; i < nSelectors; i++) { - for (var j = 0; bits(1); j++) if (j >= groupCount) message2.Error("whoops another error"); - var uc = this.mtfSymbol[j]; - for (var k = j - 1; k >= 0; k--) { - this.mtfSymbol[k + 1] = this.mtfSymbol[k]; - } - this.mtfSymbol[0] = uc; - this.selectors[i] = uc; - } - var symCount = symTotal + 2; - var groups = []; - var length = new Uint8Array(MAX_SYMBOLS), temp = new Uint16Array(MAX_HUFCODE_BITS + 1); - var hufGroup; - for (var j = 0; j < groupCount; j++) { - t = bits(5); - for (var i = 0; i < symCount; i++) { - while (true) { - if (t < 1 || t > MAX_HUFCODE_BITS) message2.Error("I gave up a while ago on writing error messages"); - if (!bits(1)) break; - if (!bits(1)) t++; - else t--; - } - length[i] = t; - } - var minLen, maxLen; - minLen = maxLen = length[0]; - for (var i = 1; i < symCount; i++) { - if (length[i] > maxLen) maxLen = length[i]; - else if (length[i] < minLen) minLen = length[i]; - } - hufGroup = groups[j] = {}; - hufGroup.permute = new Int32Array(MAX_SYMBOLS); - hufGroup.limit = new Int32Array(MAX_HUFCODE_BITS + 1); - hufGroup.base = new Int32Array(MAX_HUFCODE_BITS + 1); - hufGroup.minLen = minLen; - hufGroup.maxLen = maxLen; - var base = hufGroup.base; - var limit = hufGroup.limit; - var pp = 0; - for (var i = minLen; i <= maxLen; i++) - for (var t = 0; t < symCount; t++) - if (length[t] == i) hufGroup.permute[pp++] = t; - for (i = minLen; i <= maxLen; i++) temp[i] = limit[i] = 0; - for (i = 0; i < symCount; i++) temp[length[i]]++; - pp = t = 0; - for (i = minLen; i < maxLen; i++) { - pp += temp[i]; - limit[i] = pp - 1; - pp <<= 1; - base[i + 1] = pp - (t += temp[i]); - } - limit[maxLen] = pp + temp[maxLen] - 1; - base[minLen] = 0; - } - for (var i = 0; i < 256; i++) { - this.mtfSymbol[i] = i; - this.byteCount[i] = 0; - } - var runPos, count, symCount, selector3; - runPos = count = symCount = selector3 = 0; - while (true) { - if (!symCount--) { - symCount = GROUP_SIZE - 1; - if (selector3 >= nSelectors) message2.Error("meow i'm a kitty, that's an error"); - hufGroup = groups[this.selectors[selector3++]]; - base = hufGroup.base; - limit = hufGroup.limit; - } - i = hufGroup.minLen; - j = bits(i); - while (true) { - if (i > hufGroup.maxLen) message2.Error("rawr i'm a dinosaur"); - if (j <= limit[i]) break; - i++; - j = j << 1 | bits(1); - } - j -= base[i]; - if (j < 0 || j >= MAX_SYMBOLS) message2.Error("moo i'm a cow"); - var nextSym = hufGroup.permute[j]; - if (nextSym == SYMBOL_RUNA || nextSym == SYMBOL_RUNB) { - if (!runPos) { - runPos = 1; - t = 0; - } - if (nextSym == SYMBOL_RUNA) t += runPos; - else t += 2 * runPos; - runPos <<= 1; - continue; - } - if (runPos) { - runPos = 0; - if (count + t > bufsize) message2.Error("Boom."); - uc = this.symToByte[this.mtfSymbol[0]]; - this.byteCount[uc] += t; - while (t--) buf[count++] = uc; - } - if (nextSym > symTotal) break; - if (count >= bufsize) message2.Error("I can't think of anything. Error"); - i = nextSym - 1; - uc = this.mtfSymbol[i]; - for (var k = i - 1; k >= 0; k--) { - this.mtfSymbol[k + 1] = this.mtfSymbol[k]; - } - this.mtfSymbol[0] = uc; - uc = this.symToByte[uc]; - this.byteCount[uc]++; - buf[count++] = uc; - } - if (origPtr < 0 || origPtr >= count) message2.Error("I'm a monkey and I'm throwing something at someone, namely you"); - var j = 0; - for (var i = 0; i < 256; i++) { - k = j + this.byteCount[i]; - this.byteCount[i] = j; - j = k; - } - for (var i = 0; i < count; i++) { - uc = buf[i] & 255; - buf[this.byteCount[uc]] |= i << 8; - this.byteCount[uc]++; - } - var pos = 0, current = 0, run = 0; - if (count) { - pos = buf[origPtr]; - current = pos & 255; - pos >>= 8; - run = -1; - } - count = count; - var copies, previous, outbyte; - while (count) { - count--; - previous = current; - pos = buf[pos]; - current = pos & 255; - pos >>= 8; - if (run++ == 3) { - copies = current; - outbyte = previous; - current = -1; - } else { - copies = 1; - outbyte = current; - } - while (copies--) { - crc = (crc << 8 ^ this.crcTable[(crc >> 24 ^ outbyte) & 255]) & 4294967295; - stream2(outbyte); - } - if (current != previous) run = 0; - } - crc = (crc ^ -1) >>> 0; - if ((crc | 0) != (crcblock | 0)) message2.Error("Error in bzip2: crc32 do not match"); - streamCRC = (crc ^ (streamCRC << 1 | streamCRC >>> 31)) & 4294967295; - return streamCRC; - }; - module3.exports = bzip2; - } -}); - -// node_modules/unbzip2-stream/lib/bit_iterator.js -var require_bit_iterator = __commonJS({ - "node_modules/unbzip2-stream/lib/bit_iterator.js"(exports2, module3) { - var BITMASK = [0, 1, 3, 7, 15, 31, 63, 127, 255]; - module3.exports = function bitIterator(nextBuffer) { - var bit = 0, byte = 0; - var bytes = nextBuffer(); - var f = function(n) { - if (n === null && bit != 0) { - bit = 0; - byte++; - return; - } - var result = 0; - while (n > 0) { - if (byte >= bytes.length) { - byte = 0; - bytes = nextBuffer(); - } - var left = 8 - bit; - if (bit === 0 && n > 0) - f.bytesRead++; - if (n >= left) { - result <<= left; - result |= BITMASK[left] & bytes[byte++]; - bit = 0; - n -= left; - } else { - result <<= n; - result |= (bytes[byte] & BITMASK[n] << 8 - n - bit) >> 8 - n - bit; - bit += n; - n = 0; - } - } - return result; - }; - f.bytesRead = 0; - return f; - }; - } -}); - -// node_modules/unbzip2-stream/index.js -var require_unbzip2_stream = __commonJS({ - "node_modules/unbzip2-stream/index.js"(exports2, module3) { - var through = require_through(); - var bz2 = require_bzip2(); - var bitIterator = require_bit_iterator(); - module3.exports = unbzip2Stream; - function unbzip2Stream() { - var bufferQueue = []; - var hasBytes = 0; - var blockSize = 0; - var broken = false; - var done = false; - var bitReader = null; - var streamCRC = null; - function decompressBlock(push) { - if (!blockSize) { - blockSize = bz2.header(bitReader); - streamCRC = 0; - return true; - } else { - var bufsize = 1e5 * blockSize; - var buf = new Int32Array(bufsize); - var chunk = []; - var f = function(b) { - chunk.push(b); - }; - streamCRC = bz2.decompress(bitReader, f, buf, bufsize, streamCRC); - if (streamCRC === null) { - blockSize = 0; - return false; - } else { - push(Buffer.from(chunk)); - return true; - } - } - } - var outlength = 0; - function decompressAndQueue(stream2) { - if (broken) return; - try { - return decompressBlock(function(d) { - stream2.queue(d); - if (d !== null) { - outlength += d.length; - } else { - } - }); - } catch (e) { - stream2.emit("error", e); - broken = true; - return false; - } - } - return through( - function write(data) { - bufferQueue.push(data); - hasBytes += data.length; - if (bitReader === null) { - bitReader = bitIterator(function() { - return bufferQueue.shift(); - }); - } - while (!broken && hasBytes - bitReader.bytesRead + 1 >= (25e3 + 1e5 * blockSize || 4)) { - decompressAndQueue(this); - } - }, - function end(x) { - while (!broken && bitReader && hasBytes > bitReader.bytesRead) { - decompressAndQueue(this); - } - if (!broken) { - if (streamCRC !== null) - this.emit("error", new Error("input stream ended prematurely")); - this.queue(null); - } - } - ); - } - } -}); - -// node_modules/decompress-tarbz2/index.js -var require_decompress_tarbz2 = __commonJS({ - "node_modules/decompress-tarbz2/index.js"(exports2, module3) { - "use strict"; - var decompressTar = require_decompress_tar(); - var fileType = require_file_type2(); - var isStream = require_is_stream(); - var seekBzip = require_lib2(); - var unbzip2Stream = require_unbzip2_stream(); - module3.exports = () => (input) => { - if (!Buffer.isBuffer(input) && !isStream(input)) { - return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); - } - if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "bz2")) { - return Promise.resolve([]); - } - if (Buffer.isBuffer(input)) { - return decompressTar()(seekBzip.decode(input)); - } - return decompressTar()(input.pipe(unbzip2Stream())); - }; - } -}); - -// node_modules/decompress-targz/index.js -var require_decompress_targz = __commonJS({ - "node_modules/decompress-targz/index.js"(exports2, module3) { - "use strict"; - var zlib = require("zlib"); - var decompressTar = require_decompress_tar(); - var fileType = require_file_type(); - var isStream = require_is_stream(); - module3.exports = () => (input) => { - if (!Buffer.isBuffer(input) && !isStream(input)) { - return Promise.reject(new TypeError(`Expected a Buffer or Stream, got ${typeof input}`)); - } - if (Buffer.isBuffer(input) && (!fileType(input) || fileType(input).ext !== "gz")) { - return Promise.resolve([]); - } - const unzip = zlib.createGunzip(); - const result = decompressTar()(unzip); - if (Buffer.isBuffer(input)) { - unzip.end(input); - } else { - input.pipe(unzip); - } - return result; - }; - } -}); - -// node_modules/decompress-unzip/node_modules/file-type/index.js -var require_file_type3 = __commonJS({ - "node_modules/decompress-unzip/node_modules/file-type/index.js"(exports2, module3) { - "use strict"; - module3.exports = function(buf) { - if (!(buf && buf.length > 1)) { - return null; - } - if (buf[0] === 255 && buf[1] === 216 && buf[2] === 255) { - return { - ext: "jpg", - mime: "image/jpeg" - }; - } - if (buf[0] === 137 && buf[1] === 80 && buf[2] === 78 && buf[3] === 71) { - return { - ext: "png", - mime: "image/png" - }; - } - if (buf[0] === 71 && buf[1] === 73 && buf[2] === 70) { - return { - ext: "gif", - mime: "image/gif" - }; - } - if (buf[8] === 87 && buf[9] === 69 && buf[10] === 66 && buf[11] === 80) { - return { - ext: "webp", - mime: "image/webp" - }; - } - if (buf[0] === 70 && buf[1] === 76 && buf[2] === 73 && buf[3] === 70) { - return { - ext: "flif", - mime: "image/flif" - }; - } - if ((buf[0] === 73 && buf[1] === 73 && buf[2] === 42 && buf[3] === 0 || buf[0] === 77 && buf[1] === 77 && buf[2] === 0 && buf[3] === 42) && buf[8] === 67 && buf[9] === 82) { - return { - ext: "cr2", - mime: "image/x-canon-cr2" - }; - } - if (buf[0] === 73 && buf[1] === 73 && buf[2] === 42 && buf[3] === 0 || buf[0] === 77 && buf[1] === 77 && buf[2] === 0 && buf[3] === 42) { - return { - ext: "tif", - mime: "image/tiff" - }; - } - if (buf[0] === 66 && buf[1] === 77) { - return { - ext: "bmp", - mime: "image/bmp" - }; - } - if (buf[0] === 73 && buf[1] === 73 && buf[2] === 188) { - return { - ext: "jxr", - mime: "image/vnd.ms-photo" - }; - } - if (buf[0] === 56 && buf[1] === 66 && buf[2] === 80 && buf[3] === 83) { - return { - ext: "psd", - mime: "image/vnd.adobe.photoshop" - }; - } - if (buf[0] === 80 && buf[1] === 75 && buf[2] === 3 && buf[3] === 4 && buf[30] === 109 && buf[31] === 105 && buf[32] === 109 && buf[33] === 101 && buf[34] === 116 && buf[35] === 121 && buf[36] === 112 && buf[37] === 101 && buf[38] === 97 && buf[39] === 112 && buf[40] === 112 && buf[41] === 108 && buf[42] === 105 && buf[43] === 99 && buf[44] === 97 && buf[45] === 116 && buf[46] === 105 && buf[47] === 111 && buf[48] === 110 && buf[49] === 47 && buf[50] === 101 && buf[51] === 112 && buf[52] === 117 && buf[53] === 98 && buf[54] === 43 && buf[55] === 122 && buf[56] === 105 && buf[57] === 112) { - return { - ext: "epub", - mime: "application/epub+zip" - }; - } - if (buf[0] === 80 && buf[1] === 75 && buf[2] === 3 && buf[3] === 4 && buf[30] === 77 && buf[31] === 69 && buf[32] === 84 && buf[33] === 65 && buf[34] === 45 && buf[35] === 73 && buf[36] === 78 && buf[37] === 70 && buf[38] === 47 && buf[39] === 109 && buf[40] === 111 && buf[41] === 122 && buf[42] === 105 && buf[43] === 108 && buf[44] === 108 && buf[45] === 97 && buf[46] === 46 && buf[47] === 114 && buf[48] === 115 && buf[49] === 97) { - return { - ext: "xpi", - mime: "application/x-xpinstall" - }; - } - if (buf[0] === 80 && buf[1] === 75 && (buf[2] === 3 || buf[2] === 5 || buf[2] === 7) && (buf[3] === 4 || buf[3] === 6 || buf[3] === 8)) { - return { - ext: "zip", - mime: "application/zip" - }; - } - if (buf[257] === 117 && buf[258] === 115 && buf[259] === 116 && buf[260] === 97 && buf[261] === 114) { - return { - ext: "tar", - mime: "application/x-tar" - }; - } - if (buf[0] === 82 && buf[1] === 97 && buf[2] === 114 && buf[3] === 33 && buf[4] === 26 && buf[5] === 7 && (buf[6] === 0 || buf[6] === 1)) { - return { - ext: "rar", - mime: "application/x-rar-compressed" - }; - } - if (buf[0] === 31 && buf[1] === 139 && buf[2] === 8) { - return { - ext: "gz", - mime: "application/gzip" - }; - } - if (buf[0] === 66 && buf[1] === 90 && buf[2] === 104) { - return { - ext: "bz2", - mime: "application/x-bzip2" - }; - } - if (buf[0] === 55 && buf[1] === 122 && buf[2] === 188 && buf[3] === 175 && buf[4] === 39 && buf[5] === 28) { - return { - ext: "7z", - mime: "application/x-7z-compressed" - }; - } - if (buf[0] === 120 && buf[1] === 1) { - return { - ext: "dmg", - mime: "application/x-apple-diskimage" - }; - } - if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && (buf[3] === 24 || buf[3] === 32) && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 || buf[0] === 51 && buf[1] === 103 && buf[2] === 112 && buf[3] === 53 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 109 && buf[9] === 112 && buf[10] === 52 && buf[11] === 50 && buf[16] === 109 && buf[17] === 112 && buf[18] === 52 && buf[19] === 49 && buf[20] === 109 && buf[21] === 112 && buf[22] === 52 && buf[23] === 50 && buf[24] === 105 && buf[25] === 115 && buf[26] === 111 && buf[27] === 109 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 105 && buf[9] === 115 && buf[10] === 111 && buf[11] === 109 || buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 109 && buf[9] === 112 && buf[10] === 52 && buf[11] === 50 && buf[12] === 0 && buf[13] === 0 && buf[14] === 0 && buf[15] === 0) { - return { - ext: "mp4", - mime: "video/mp4" - }; - } - if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 28 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 77 && buf[9] === 52 && buf[10] === 86) { - return { - ext: "m4v", - mime: "video/x-m4v" - }; - } - if (buf[0] === 77 && buf[1] === 84 && buf[2] === 104 && buf[3] === 100) { - return { - ext: "mid", - mime: "audio/midi" - }; - } - if (buf[31] === 109 && buf[32] === 97 && buf[33] === 116 && buf[34] === 114 && buf[35] === 111 && buf[36] === 115 && buf[37] === 107 && buf[38] === 97) { - return { - ext: "mkv", - mime: "video/x-matroska" - }; - } - if (buf[0] === 26 && buf[1] === 69 && buf[2] === 223 && buf[3] === 163) { - return { - ext: "webm", - mime: "video/webm" - }; - } - if (buf[0] === 0 && buf[1] === 0 && buf[2] === 0 && buf[3] === 20 && buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112) { - return { - ext: "mov", - mime: "video/quicktime" - }; - } - if (buf[0] === 82 && buf[1] === 73 && buf[2] === 70 && buf[3] === 70 && buf[8] === 65 && buf[9] === 86 && buf[10] === 73) { - return { - ext: "avi", - mime: "video/x-msvideo" - }; - } - if (buf[0] === 48 && buf[1] === 38 && buf[2] === 178 && buf[3] === 117 && buf[4] === 142 && buf[5] === 102 && buf[6] === 207 && buf[7] === 17 && buf[8] === 166 && buf[9] === 217) { - return { - ext: "wmv", - mime: "video/x-ms-wmv" - }; - } - if (buf[0] === 0 && buf[1] === 0 && buf[2] === 1 && buf[3].toString(16)[0] === "b") { - return { - ext: "mpg", - mime: "video/mpeg" - }; - } - if (buf[0] === 73 && buf[1] === 68 && buf[2] === 51 || buf[0] === 255 && buf[1] === 251) { - return { - ext: "mp3", - mime: "audio/mpeg" - }; - } - if (buf[4] === 102 && buf[5] === 116 && buf[6] === 121 && buf[7] === 112 && buf[8] === 77 && buf[9] === 52 && buf[10] === 65 || buf[0] === 77 && buf[1] === 52 && buf[2] === 65 && buf[3] === 32) { - return { - ext: "m4a", - mime: "audio/m4a" - }; - } - if (buf[28] === 79 && buf[29] === 112 && buf[30] === 117 && buf[31] === 115 && buf[32] === 72 && buf[33] === 101 && buf[34] === 97 && buf[35] === 100) { - return { - ext: "opus", - mime: "audio/opus" - }; - } - if (buf[0] === 79 && buf[1] === 103 && buf[2] === 103 && buf[3] === 83) { - return { - ext: "ogg", - mime: "audio/ogg" - }; - } - if (buf[0] === 102 && buf[1] === 76 && buf[2] === 97 && buf[3] === 67) { - return { - ext: "flac", - mime: "audio/x-flac" - }; - } - if (buf[0] === 82 && buf[1] === 73 && buf[2] === 70 && buf[3] === 70 && buf[8] === 87 && buf[9] === 65 && buf[10] === 86 && buf[11] === 69) { - return { - ext: "wav", - mime: "audio/x-wav" - }; - } - if (buf[0] === 35 && buf[1] === 33 && buf[2] === 65 && buf[3] === 77 && buf[4] === 82 && buf[5] === 10) { - return { - ext: "amr", - mime: "audio/amr" - }; - } - if (buf[0] === 37 && buf[1] === 80 && buf[2] === 68 && buf[3] === 70) { - return { - ext: "pdf", - mime: "application/pdf" - }; - } - if (buf[0] === 77 && buf[1] === 90) { - return { - ext: "exe", - mime: "application/x-msdownload" - }; - } - if ((buf[0] === 67 || buf[0] === 70) && buf[1] === 87 && buf[2] === 83) { - return { - ext: "swf", - mime: "application/x-shockwave-flash" - }; - } - if (buf[0] === 123 && buf[1] === 92 && buf[2] === 114 && buf[3] === 116 && buf[4] === 102) { - return { - ext: "rtf", - mime: "application/rtf" - }; - } - if (buf[0] === 119 && buf[1] === 79 && buf[2] === 70 && buf[3] === 70 && (buf[4] === 0 && buf[5] === 1 && buf[6] === 0 && buf[7] === 0 || buf[4] === 79 && buf[5] === 84 && buf[6] === 84 && buf[7] === 79)) { - return { - ext: "woff", - mime: "application/font-woff" - }; - } - if (buf[0] === 119 && buf[1] === 79 && buf[2] === 70 && buf[3] === 50 && (buf[4] === 0 && buf[5] === 1 && buf[6] === 0 && buf[7] === 0 || buf[4] === 79 && buf[5] === 84 && buf[6] === 84 && buf[7] === 79)) { - return { - ext: "woff2", - mime: "application/font-woff" - }; - } - if (buf[34] === 76 && buf[35] === 80 && (buf[8] === 0 && buf[9] === 0 && buf[10] === 1 || buf[8] === 1 && buf[9] === 0 && buf[10] === 2 || buf[8] === 2 && buf[9] === 0 && buf[10] === 2)) { - return { - ext: "eot", - mime: "application/octet-stream" - }; - } - if (buf[0] === 0 && buf[1] === 1 && buf[2] === 0 && buf[3] === 0 && buf[4] === 0) { - return { - ext: "ttf", - mime: "application/font-sfnt" - }; - } - if (buf[0] === 79 && buf[1] === 84 && buf[2] === 84 && buf[3] === 79 && buf[4] === 0) { - return { - ext: "otf", - mime: "application/font-sfnt" - }; - } - if (buf[0] === 0 && buf[1] === 0 && buf[2] === 1 && buf[3] === 0) { - return { - ext: "ico", - mime: "image/x-icon" - }; - } - if (buf[0] === 70 && buf[1] === 76 && buf[2] === 86 && buf[3] === 1) { - return { - ext: "flv", - mime: "video/x-flv" - }; - } - if (buf[0] === 37 && buf[1] === 33) { - return { - ext: "ps", - mime: "application/postscript" - }; - } - if (buf[0] === 253 && buf[1] === 55 && buf[2] === 122 && buf[3] === 88 && buf[4] === 90 && buf[5] === 0) { - return { - ext: "xz", - mime: "application/x-xz" - }; - } - if (buf[0] === 83 && buf[1] === 81 && buf[2] === 76 && buf[3] === 105) { - return { - ext: "sqlite", - mime: "application/x-sqlite3" - }; - } - if (buf[0] === 78 && buf[1] === 69 && buf[2] === 83 && buf[3] === 26) { - return { - ext: "nes", - mime: "application/x-nintendo-nes-rom" - }; - } - if (buf[0] === 67 && buf[1] === 114 && buf[2] === 50 && buf[3] === 52) { - return { - ext: "crx", - mime: "application/x-google-chrome-extension" - }; - } - if (buf[0] === 77 && buf[1] === 83 && buf[2] === 67 && buf[3] === 70 || buf[0] === 73 && buf[1] === 83 && buf[2] === 99 && buf[3] === 40) { - return { - ext: "cab", - mime: "application/vnd.ms-cab-compressed" - }; - } - if (buf[0] === 33 && buf[1] === 60 && buf[2] === 97 && buf[3] === 114 && buf[4] === 99 && buf[5] === 104 && buf[6] === 62 && buf[7] === 10 && buf[8] === 100 && buf[9] === 101 && buf[10] === 98 && buf[11] === 105 && buf[12] === 97 && buf[13] === 110 && buf[14] === 45 && buf[15] === 98 && buf[16] === 105 && buf[17] === 110 && buf[18] === 97 && buf[19] === 114 && buf[20] === 121) { - return { - ext: "deb", - mime: "application/x-deb" - }; - } - if (buf[0] === 33 && buf[1] === 60 && buf[2] === 97 && buf[3] === 114 && buf[4] === 99 && buf[5] === 104 && buf[6] === 62) { - return { - ext: "ar", - mime: "application/x-unix-archive" - }; - } - if (buf[0] === 237 && buf[1] === 171 && buf[2] === 238 && buf[3] === 219) { - return { - ext: "rpm", - mime: "application/x-rpm" - }; - } - if (buf[0] === 31 && buf[1] === 160 || buf[0] === 31 && buf[1] === 157) { - return { - ext: "Z", - mime: "application/x-compress" - }; - } - if (buf[0] === 76 && buf[1] === 90 && buf[2] === 73 && buf[3] === 80) { - return { - ext: "lz", - mime: "application/x-lzip" - }; - } - if (buf[0] === 208 && buf[1] === 207 && buf[2] === 17 && buf[3] === 224 && buf[4] === 161 && buf[5] === 177 && buf[6] === 26 && buf[7] === 225) { - return { - ext: "msi", - mime: "application/x-msi" - }; - } - return null; - }; - } -}); - -// node_modules/pinkie/index.js -var require_pinkie = __commonJS({ - "node_modules/pinkie/index.js"(exports2, module3) { - "use strict"; - var PENDING = "pending"; - var SETTLED = "settled"; - var FULFILLED = "fulfilled"; - var REJECTED = "rejected"; - var NOOP = function() { - }; - var isNode = typeof global !== "undefined" && typeof global.process !== "undefined" && typeof global.process.emit === "function"; - var asyncSetTimer = typeof setImmediate === "undefined" ? setTimeout : setImmediate; - var asyncQueue = []; - var asyncTimer; - function asyncFlush() { - for (var i = 0; i < asyncQueue.length; i++) { - asyncQueue[i][0](asyncQueue[i][1]); - } - asyncQueue = []; - asyncTimer = false; - } - function asyncCall(callback, arg) { - asyncQueue.push([callback, arg]); - if (!asyncTimer) { - asyncTimer = true; - asyncSetTimer(asyncFlush, 0); - } - } - function invokeResolver(resolver, promise) { - function resolvePromise(value) { - resolve2(promise, value); - } - function rejectPromise(reason) { - reject(promise, reason); - } - try { - resolver(resolvePromise, rejectPromise); - } catch (e) { - rejectPromise(e); - } - } - function invokeCallback(subscriber) { - var owner = subscriber.owner; - var settled = owner._state; - var value = owner._data; - var callback = subscriber[settled]; - var promise = subscriber.then; - if (typeof callback === "function") { - settled = FULFILLED; - try { - value = callback(value); - } catch (e) { - reject(promise, e); - } - } - if (!handleThenable(promise, value)) { - if (settled === FULFILLED) { - resolve2(promise, value); - } - if (settled === REJECTED) { - reject(promise, value); - } - } - } - function handleThenable(promise, value) { - var resolved; - try { - if (promise === value) { - throw new TypeError("A promises callback cannot return that same promise."); - } - if (value && (typeof value === "function" || typeof value === "object")) { - var then = value.then; - if (typeof then === "function") { - then.call(value, function(val) { - if (!resolved) { - resolved = true; - if (value === val) { - fulfill(promise, val); - } else { - resolve2(promise, val); - } - } - }, function(reason) { - if (!resolved) { - resolved = true; - reject(promise, reason); - } - }); - return true; - } - } - } catch (e) { - if (!resolved) { - reject(promise, e); - } - return true; - } - return false; - } - function resolve2(promise, value) { - if (promise === value || !handleThenable(promise, value)) { - fulfill(promise, value); - } - } - function fulfill(promise, value) { - if (promise._state === PENDING) { - promise._state = SETTLED; - promise._data = value; - asyncCall(publishFulfillment, promise); - } - } - function reject(promise, reason) { - if (promise._state === PENDING) { - promise._state = SETTLED; - promise._data = reason; - asyncCall(publishRejection, promise); - } - } - function publish(promise) { - promise._then = promise._then.forEach(invokeCallback); - } - function publishFulfillment(promise) { - promise._state = FULFILLED; - publish(promise); - } - function publishRejection(promise) { - promise._state = REJECTED; - publish(promise); - if (!promise._handled && isNode) { - global.process.emit("unhandledRejection", promise._data, promise); - } - } - function notifyRejectionHandled(promise) { - global.process.emit("rejectionHandled", promise); - } - function Promise2(resolver) { - if (typeof resolver !== "function") { - throw new TypeError("Promise resolver " + resolver + " is not a function"); - } - if (this instanceof Promise2 === false) { - throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function."); - } - this._then = []; - invokeResolver(resolver, this); - } - Promise2.prototype = { - constructor: Promise2, - _state: PENDING, - _then: null, - _data: void 0, - _handled: false, - then: function(onFulfillment, onRejection) { - var subscriber = { - owner: this, - then: new this.constructor(NOOP), - fulfilled: onFulfillment, - rejected: onRejection - }; - if ((onRejection || onFulfillment) && !this._handled) { - this._handled = true; - if (this._state === REJECTED && isNode) { - asyncCall(notifyRejectionHandled, this); - } - } - if (this._state === FULFILLED || this._state === REJECTED) { - asyncCall(invokeCallback, subscriber); - } else { - this._then.push(subscriber); - } - return subscriber.then; - }, - catch: function(onRejection) { - return this.then(null, onRejection); - } - }; - Promise2.all = function(promises) { - if (!Array.isArray(promises)) { - throw new TypeError("You must pass an array to Promise.all()."); - } - return new Promise2(function(resolve3, reject2) { - var results = []; - var remaining = 0; - function resolver(index4) { - remaining++; - return function(value) { - results[index4] = value; - if (!--remaining) { - resolve3(results); - } - }; - } - for (var i = 0, promise; i < promises.length; i++) { - promise = promises[i]; - if (promise && typeof promise.then === "function") { - promise.then(resolver(i), reject2); - } else { - results[i] = promise; - } - } - if (!remaining) { - resolve3(results); - } - }); - }; - Promise2.race = function(promises) { - if (!Array.isArray(promises)) { - throw new TypeError("You must pass an array to Promise.race()."); - } - return new Promise2(function(resolve3, reject2) { - for (var i = 0, promise; i < promises.length; i++) { - promise = promises[i]; - if (promise && typeof promise.then === "function") { - promise.then(resolve3, reject2); - } else { - resolve3(promise); - } - } - }); - }; - Promise2.resolve = function(value) { - if (value && typeof value === "object" && value.constructor === Promise2) { - return value; - } - return new Promise2(function(resolve3) { - resolve3(value); - }); - }; - Promise2.reject = function(reason) { - return new Promise2(function(resolve3, reject2) { - reject2(reason); - }); - }; - module3.exports = Promise2; - } -}); - -// node_modules/pinkie-promise/index.js -var require_pinkie_promise = __commonJS({ - "node_modules/pinkie-promise/index.js"(exports2, module3) { - "use strict"; - module3.exports = typeof Promise === "function" ? Promise : require_pinkie(); - } -}); - -// node_modules/object-assign/index.js -var require_object_assign = __commonJS({ - "node_modules/object-assign/index.js"(exports2, module3) { - "use strict"; - var getOwnPropertySymbols = Object.getOwnPropertySymbols; - var hasOwnProperty = Object.prototype.hasOwnProperty; - var propIsEnumerable = Object.prototype.propertyIsEnumerable; - function toObject(val) { - if (val === null || val === void 0) { - throw new TypeError("Object.assign cannot be called with null or undefined"); - } - return Object(val); - } - function shouldUseNative() { - try { - if (!Object.assign) { - return false; - } - var test1 = new String("abc"); - test1[5] = "de"; - if (Object.getOwnPropertyNames(test1)[0] === "5") { - return false; - } - var test2 = {}; - for (var i = 0; i < 10; i++) { - test2["_" + String.fromCharCode(i)] = i; - } - var order2 = Object.getOwnPropertyNames(test2).map(function(n) { - return test2[n]; - }); - if (order2.join("") !== "0123456789") { - return false; - } - var test3 = {}; - "abcdefghijklmnopqrst".split("").forEach(function(letter) { - test3[letter] = letter; - }); - if (Object.keys(Object.assign({}, test3)).join("") !== "abcdefghijklmnopqrst") { - return false; - } - return true; - } catch (err) { - return false; - } - } - module3.exports = shouldUseNative() ? Object.assign : function(target, source) { - var from; - var to = toObject(target); - var symbols; - for (var s = 1; s < arguments.length; s++) { - from = Object(arguments[s]); - for (var key2 in from) { - if (hasOwnProperty.call(from, key2)) { - to[key2] = from[key2]; - } - } - if (getOwnPropertySymbols) { - symbols = getOwnPropertySymbols(from); - for (var i = 0; i < symbols.length; i++) { - if (propIsEnumerable.call(from, symbols[i])) { - to[symbols[i]] = from[symbols[i]]; - } - } - } - } - return to; - }; - } -}); - -// node_modules/get-stream/buffer-stream.js -var require_buffer_stream = __commonJS({ - "node_modules/get-stream/buffer-stream.js"(exports2, module3) { - var PassThrough = require("stream").PassThrough; - var objectAssign = require_object_assign(); - module3.exports = function(opts) { - opts = objectAssign({}, opts); - var array4 = opts.array; - var encoding = opts.encoding; - var buffer = encoding === "buffer"; - var objectMode = false; - if (array4) { - objectMode = !(encoding || buffer); - } else { - encoding = encoding || "utf8"; - } - if (buffer) { - encoding = null; - } - var len = 0; - var ret = []; - var stream2 = new PassThrough({ objectMode }); - if (encoding) { - stream2.setEncoding(encoding); - } - stream2.on("data", function(chunk) { - ret.push(chunk); - if (objectMode) { - len = ret.length; - } else { - len += chunk.length; - } - }); - stream2.getBufferedValue = function() { - if (array4) { - return ret; - } - return buffer ? Buffer.concat(ret, len) : ret.join(""); - }; - stream2.getBufferedLength = function() { - return len; - }; - return stream2; - }; - } -}); - -// node_modules/get-stream/index.js -var require_get_stream = __commonJS({ - "node_modules/get-stream/index.js"(exports2, module3) { - "use strict"; - var Promise2 = require_pinkie_promise(); - var objectAssign = require_object_assign(); - var bufferStream = require_buffer_stream(); - function getStream(inputStream, opts) { - if (!inputStream) { - return Promise2.reject(new Error("Expected a stream")); - } - opts = objectAssign({ maxBuffer: Infinity }, opts); - var maxBuffer = opts.maxBuffer; - var stream2; - var clean; - var p = new Promise2(function(resolve2, reject) { - stream2 = bufferStream(opts); - inputStream.once("error", error4); - inputStream.pipe(stream2); - stream2.on("data", function() { - if (stream2.getBufferedLength() > maxBuffer) { - reject(new Error("maxBuffer exceeded")); - } - }); - stream2.once("error", error4); - stream2.on("end", resolve2); - clean = function() { - if (inputStream.unpipe) { - inputStream.unpipe(stream2); - } - }; - function error4(err) { - if (err) { - err.bufferedData = stream2.getBufferedValue(); - } - reject(err); - } - }); - p.then(clean, clean); - return p.then(function() { - return stream2.getBufferedValue(); - }); - } - module3.exports = getStream; - module3.exports.buffer = function(stream2, opts) { - return getStream(stream2, objectAssign({}, opts, { encoding: "buffer" })); - }; - module3.exports.array = function(stream2, opts) { - return getStream(stream2, objectAssign({}, opts, { array: true })); - }; - } -}); - -// node_modules/pify/index.js -var require_pify = __commonJS({ - "node_modules/pify/index.js"(exports2, module3) { - "use strict"; - var processFn = function(fn, P, opts) { - return function() { - var that = this; - var args = new Array(arguments.length); - for (var i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - return new P(function(resolve2, reject) { - args.push(function(err, result) { - if (err) { - reject(err); - } else if (opts.multiArgs) { - var results = new Array(arguments.length - 1); - for (var i2 = 1; i2 < arguments.length; i2++) { - results[i2 - 1] = arguments[i2]; - } - resolve2(results); - } else { - resolve2(result); - } - }); - fn.apply(that, args); - }); - }; - }; - var pify = module3.exports = function(obj, P, opts) { - if (typeof P !== "function") { - opts = P; - P = Promise; - } - opts = opts || {}; - opts.exclude = opts.exclude || [/.+Sync$/]; - var filter2 = function(key2) { - var match = function(pattern) { - return typeof pattern === "string" ? key2 === pattern : pattern.test(key2); - }; - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - var ret = typeof obj === "function" ? function() { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - return processFn(obj, P, opts).apply(this, arguments); - } : {}; - return Object.keys(obj).reduce(function(ret2, key2) { - var x = obj[key2]; - ret2[key2] = typeof x === "function" && filter2(key2) ? processFn(x, P, opts) : x; - return ret2; - }, ret); - }; - pify.all = pify; - } -}); - -// node_modules/pend/index.js -var require_pend = __commonJS({ - "node_modules/pend/index.js"(exports2, module3) { - module3.exports = Pend; - function Pend() { - this.pending = 0; - this.max = Infinity; - this.listeners = []; - this.waiting = []; - this.error = null; - } - Pend.prototype.go = function(fn) { - if (this.pending < this.max) { - pendGo(this, fn); - } else { - this.waiting.push(fn); - } - }; - Pend.prototype.wait = function(cb) { - if (this.pending === 0) { - cb(this.error); - } else { - this.listeners.push(cb); - } - }; - Pend.prototype.hold = function() { - return pendHold(this); - }; - function pendHold(self2) { - self2.pending += 1; - var called = false; - return onCb; - function onCb(err) { - if (called) throw new Error("callback called twice"); - called = true; - self2.error = self2.error || err; - self2.pending -= 1; - if (self2.waiting.length > 0 && self2.pending < self2.max) { - pendGo(self2, self2.waiting.shift()); - } else if (self2.pending === 0) { - var listeners = self2.listeners; - self2.listeners = []; - listeners.forEach(cbListener); - } - } - function cbListener(listener) { - listener(self2.error); - } - } - function pendGo(self2, fn) { - fn(pendHold(self2)); - } - } -}); - -// node_modules/fd-slicer/index.js -var require_fd_slicer = __commonJS({ - "node_modules/fd-slicer/index.js"(exports2) { - var fs2 = require("fs"); - var util = require("util"); - var stream2 = require("stream"); - var Readable = stream2.Readable; - var Writable = stream2.Writable; - var PassThrough = stream2.PassThrough; - var Pend = require_pend(); - var EventEmitter = require("events").EventEmitter; - exports2.createFromBuffer = createFromBuffer; - exports2.createFromFd = createFromFd; - exports2.BufferSlicer = BufferSlicer; - exports2.FdSlicer = FdSlicer; - util.inherits(FdSlicer, EventEmitter); - function FdSlicer(fd, options2) { - options2 = options2 || {}; - EventEmitter.call(this); - this.fd = fd; - this.pend = new Pend(); - this.pend.max = 1; - this.refCount = 0; - this.autoClose = !!options2.autoClose; - } - FdSlicer.prototype.read = function(buffer, offset, length, position, callback) { - var self2 = this; - self2.pend.go(function(cb) { - fs2.read(self2.fd, buffer, offset, length, position, function(err, bytesRead, buffer2) { - cb(); - callback(err, bytesRead, buffer2); - }); - }); - }; - FdSlicer.prototype.write = function(buffer, offset, length, position, callback) { - var self2 = this; - self2.pend.go(function(cb) { - fs2.write(self2.fd, buffer, offset, length, position, function(err, written, buffer2) { - cb(); - callback(err, written, buffer2); - }); - }); - }; - FdSlicer.prototype.createReadStream = function(options2) { - return new ReadStream(this, options2); - }; - FdSlicer.prototype.createWriteStream = function(options2) { - return new WriteStream(this, options2); - }; - FdSlicer.prototype.ref = function() { - this.refCount += 1; - }; - FdSlicer.prototype.unref = function() { - var self2 = this; - self2.refCount -= 1; - if (self2.refCount > 0) return; - if (self2.refCount < 0) throw new Error("invalid unref"); - if (self2.autoClose) { - fs2.close(self2.fd, onCloseDone); - } - function onCloseDone(err) { - if (err) { - self2.emit("error", err); - } else { - self2.emit("close"); - } - } - }; - util.inherits(ReadStream, Readable); - function ReadStream(context, options2) { - options2 = options2 || {}; - Readable.call(this, options2); - this.context = context; - this.context.ref(); - this.start = options2.start || 0; - this.endOffset = options2.end; - this.pos = this.start; - this.destroyed = false; - } - ReadStream.prototype._read = function(n) { - var self2 = this; - if (self2.destroyed) return; - var toRead = Math.min(self2._readableState.highWaterMark, n); - if (self2.endOffset != null) { - toRead = Math.min(toRead, self2.endOffset - self2.pos); - } - if (toRead <= 0) { - self2.destroyed = true; - self2.push(null); - self2.context.unref(); - return; - } - self2.context.pend.go(function(cb) { - if (self2.destroyed) return cb(); - var buffer = new Buffer(toRead); - fs2.read(self2.context.fd, buffer, 0, toRead, self2.pos, function(err, bytesRead) { - if (err) { - self2.destroy(err); - } else if (bytesRead === 0) { - self2.destroyed = true; - self2.push(null); - self2.context.unref(); - } else { - self2.pos += bytesRead; - self2.push(buffer.slice(0, bytesRead)); - } - cb(); - }); - }); - }; - ReadStream.prototype.destroy = function(err) { - if (this.destroyed) return; - err = err || new Error("stream destroyed"); - this.destroyed = true; - this.emit("error", err); - this.context.unref(); - }; - util.inherits(WriteStream, Writable); - function WriteStream(context, options2) { - options2 = options2 || {}; - Writable.call(this, options2); - this.context = context; - this.context.ref(); - this.start = options2.start || 0; - this.endOffset = options2.end == null ? Infinity : +options2.end; - this.bytesWritten = 0; - this.pos = this.start; - this.destroyed = false; - this.on("finish", this.destroy.bind(this)); - } - WriteStream.prototype._write = function(buffer, encoding, callback) { - var self2 = this; - if (self2.destroyed) return; - if (self2.pos + buffer.length > self2.endOffset) { - var err = new Error("maximum file length exceeded"); - err.code = "ETOOBIG"; - self2.destroy(); - callback(err); - return; - } - self2.context.pend.go(function(cb) { - if (self2.destroyed) return cb(); - fs2.write(self2.context.fd, buffer, 0, buffer.length, self2.pos, function(err2, bytes) { - if (err2) { - self2.destroy(); - cb(); - callback(err2); - } else { - self2.bytesWritten += bytes; - self2.pos += bytes; - self2.emit("progress"); - cb(); - callback(); - } - }); - }); - }; - WriteStream.prototype.destroy = function() { - if (this.destroyed) return; - this.destroyed = true; - this.context.unref(); - }; - util.inherits(BufferSlicer, EventEmitter); - function BufferSlicer(buffer, options2) { - EventEmitter.call(this); - options2 = options2 || {}; - this.refCount = 0; - this.buffer = buffer; - this.maxChunkSize = options2.maxChunkSize || Number.MAX_SAFE_INTEGER; - } - BufferSlicer.prototype.read = function(buffer, offset, length, position, callback) { - var end = position + length; - var delta = end - this.buffer.length; - var written = delta > 0 ? delta : length; - this.buffer.copy(buffer, offset, position, end); - setImmediate(function() { - callback(null, written); - }); - }; - BufferSlicer.prototype.write = function(buffer, offset, length, position, callback) { - buffer.copy(this.buffer, position, offset, offset + length); - setImmediate(function() { - callback(null, length, buffer); - }); - }; - BufferSlicer.prototype.createReadStream = function(options2) { - options2 = options2 || {}; - var readStream = new PassThrough(options2); - readStream.destroyed = false; - readStream.start = options2.start || 0; - readStream.endOffset = options2.end; - readStream.pos = readStream.endOffset || this.buffer.length; - var entireSlice = this.buffer.slice(readStream.start, readStream.pos); - var offset = 0; - while (true) { - var nextOffset = offset + this.maxChunkSize; - if (nextOffset >= entireSlice.length) { - if (offset < entireSlice.length) { - readStream.write(entireSlice.slice(offset, entireSlice.length)); - } - break; - } - readStream.write(entireSlice.slice(offset, nextOffset)); - offset = nextOffset; - } - readStream.end(); - readStream.destroy = function() { - readStream.destroyed = true; - }; - return readStream; - }; - BufferSlicer.prototype.createWriteStream = function(options2) { - var bufferSlicer = this; - options2 = options2 || {}; - var writeStream = new Writable(options2); - writeStream.start = options2.start || 0; - writeStream.endOffset = options2.end == null ? this.buffer.length : +options2.end; - writeStream.bytesWritten = 0; - writeStream.pos = writeStream.start; - writeStream.destroyed = false; - writeStream._write = function(buffer, encoding, callback) { - if (writeStream.destroyed) return; - var end = writeStream.pos + buffer.length; - if (end > writeStream.endOffset) { - var err = new Error("maximum file length exceeded"); - err.code = "ETOOBIG"; - writeStream.destroyed = true; - callback(err); - return; - } - buffer.copy(bufferSlicer.buffer, writeStream.pos, 0, buffer.length); - writeStream.bytesWritten += buffer.length; - writeStream.pos = end; - writeStream.emit("progress"); - callback(); - }; - writeStream.destroy = function() { - writeStream.destroyed = true; - }; - return writeStream; - }; - BufferSlicer.prototype.ref = function() { - this.refCount += 1; - }; - BufferSlicer.prototype.unref = function() { - this.refCount -= 1; - if (this.refCount < 0) { - throw new Error("invalid unref"); - } - }; - function createFromBuffer(buffer, options2) { - return new BufferSlicer(buffer, options2); - } - function createFromFd(fd, options2) { - return new FdSlicer(fd, options2); - } - } -}); - -// node_modules/buffer-crc32/index.js -var require_buffer_crc32 = __commonJS({ - "node_modules/buffer-crc32/index.js"(exports2, module3) { - var Buffer3 = require("buffer").Buffer; - var CRC_TABLE = [ - 0, - 1996959894, - 3993919788, - 2567524794, - 124634137, - 1886057615, - 3915621685, - 2657392035, - 249268274, - 2044508324, - 3772115230, - 2547177864, - 162941995, - 2125561021, - 3887607047, - 2428444049, - 498536548, - 1789927666, - 4089016648, - 2227061214, - 450548861, - 1843258603, - 4107580753, - 2211677639, - 325883990, - 1684777152, - 4251122042, - 2321926636, - 335633487, - 1661365465, - 4195302755, - 2366115317, - 997073096, - 1281953886, - 3579855332, - 2724688242, - 1006888145, - 1258607687, - 3524101629, - 2768942443, - 901097722, - 1119000684, - 3686517206, - 2898065728, - 853044451, - 1172266101, - 3705015759, - 2882616665, - 651767980, - 1373503546, - 3369554304, - 3218104598, - 565507253, - 1454621731, - 3485111705, - 3099436303, - 671266974, - 1594198024, - 3322730930, - 2970347812, - 795835527, - 1483230225, - 3244367275, - 3060149565, - 1994146192, - 31158534, - 2563907772, - 4023717930, - 1907459465, - 112637215, - 2680153253, - 3904427059, - 2013776290, - 251722036, - 2517215374, - 3775830040, - 2137656763, - 141376813, - 2439277719, - 3865271297, - 1802195444, - 476864866, - 2238001368, - 4066508878, - 1812370925, - 453092731, - 2181625025, - 4111451223, - 1706088902, - 314042704, - 2344532202, - 4240017532, - 1658658271, - 366619977, - 2362670323, - 4224994405, - 1303535960, - 984961486, - 2747007092, - 3569037538, - 1256170817, - 1037604311, - 2765210733, - 3554079995, - 1131014506, - 879679996, - 2909243462, - 3663771856, - 1141124467, - 855842277, - 2852801631, - 3708648649, - 1342533948, - 654459306, - 3188396048, - 3373015174, - 1466479909, - 544179635, - 3110523913, - 3462522015, - 1591671054, - 702138776, - 2966460450, - 3352799412, - 1504918807, - 783551873, - 3082640443, - 3233442989, - 3988292384, - 2596254646, - 62317068, - 1957810842, - 3939845945, - 2647816111, - 81470997, - 1943803523, - 3814918930, - 2489596804, - 225274430, - 2053790376, - 3826175755, - 2466906013, - 167816743, - 2097651377, - 4027552580, - 2265490386, - 503444072, - 1762050814, - 4150417245, - 2154129355, - 426522225, - 1852507879, - 4275313526, - 2312317920, - 282753626, - 1742555852, - 4189708143, - 2394877945, - 397917763, - 1622183637, - 3604390888, - 2714866558, - 953729732, - 1340076626, - 3518719985, - 2797360999, - 1068828381, - 1219638859, - 3624741850, - 2936675148, - 906185462, - 1090812512, - 3747672003, - 2825379669, - 829329135, - 1181335161, - 3412177804, - 3160834842, - 628085408, - 1382605366, - 3423369109, - 3138078467, - 570562233, - 1426400815, - 3317316542, - 2998733608, - 733239954, - 1555261956, - 3268935591, - 3050360625, - 752459403, - 1541320221, - 2607071920, - 3965973030, - 1969922972, - 40735498, - 2617837225, - 3943577151, - 1913087877, - 83908371, - 2512341634, - 3803740692, - 2075208622, - 213261112, - 2463272603, - 3855990285, - 2094854071, - 198958881, - 2262029012, - 4057260610, - 1759359992, - 534414190, - 2176718541, - 4139329115, - 1873836001, - 414664567, - 2282248934, - 4279200368, - 1711684554, - 285281116, - 2405801727, - 4167216745, - 1634467795, - 376229701, - 2685067896, - 3608007406, - 1308918612, - 956543938, - 2808555105, - 3495958263, - 1231636301, - 1047427035, - 2932959818, - 3654703836, - 1088359270, - 936918e3, - 2847714899, - 3736837829, - 1202900863, - 817233897, - 3183342108, - 3401237130, - 1404277552, - 615818150, - 3134207493, - 3453421203, - 1423857449, - 601450431, - 3009837614, - 3294710456, - 1567103746, - 711928724, - 3020668471, - 3272380065, - 1510334235, - 755167117 - ]; - if (typeof Int32Array !== "undefined") { - CRC_TABLE = new Int32Array(CRC_TABLE); - } - function ensureBuffer(input) { - if (Buffer3.isBuffer(input)) { - return input; - } - var hasNewBufferAPI = typeof Buffer3.alloc === "function" && typeof Buffer3.from === "function"; - if (typeof input === "number") { - return hasNewBufferAPI ? Buffer3.alloc(input) : new Buffer3(input); - } else if (typeof input === "string") { - return hasNewBufferAPI ? Buffer3.from(input) : new Buffer3(input); - } else { - throw new Error("input must be buffer, number, or string, received " + typeof input); - } - } - function bufferizeInt(num) { - var tmp = ensureBuffer(4); - tmp.writeInt32BE(num, 0); - return tmp; - } - function _crc32(buf, previous) { - buf = ensureBuffer(buf); - if (Buffer3.isBuffer(previous)) { - previous = previous.readUInt32BE(0); - } - var crc = ~~previous ^ -1; - for (var n = 0; n < buf.length; n++) { - crc = CRC_TABLE[(crc ^ buf[n]) & 255] ^ crc >>> 8; - } - return crc ^ -1; - } - function crc32() { - return bufferizeInt(_crc32.apply(null, arguments)); - } - crc32.signed = function() { - return _crc32.apply(null, arguments); - }; - crc32.unsigned = function() { - return _crc32.apply(null, arguments) >>> 0; - }; - module3.exports = crc32; - } -}); - -// node_modules/yauzl/index.js -var require_yauzl = __commonJS({ - "node_modules/yauzl/index.js"(exports2) { - var fs2 = require("fs"); - var zlib = require("zlib"); - var fd_slicer = require_fd_slicer(); - var crc32 = require_buffer_crc32(); - var util = require("util"); - var EventEmitter = require("events").EventEmitter; - var Transform = require("stream").Transform; - var PassThrough = require("stream").PassThrough; - var Writable = require("stream").Writable; - exports2.open = open; - exports2.fromFd = fromFd; - exports2.fromBuffer = fromBuffer; - exports2.fromRandomAccessReader = fromRandomAccessReader; - exports2.dosDateTimeToDate = dosDateTimeToDate; - exports2.validateFileName = validateFileName; - exports2.ZipFile = ZipFile; - exports2.Entry = Entry; - exports2.RandomAccessReader = RandomAccessReader; - function open(path6, options2, callback) { - if (typeof options2 === "function") { - callback = options2; - options2 = null; - } - if (options2 == null) options2 = {}; - if (options2.autoClose == null) options2.autoClose = true; - if (options2.lazyEntries == null) options2.lazyEntries = false; - if (options2.decodeStrings == null) options2.decodeStrings = true; - if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; - if (options2.strictFileNames == null) options2.strictFileNames = false; - if (callback == null) callback = defaultCallback; - fs2.open(path6, "r", function(err, fd) { - if (err) return callback(err); - fromFd(fd, options2, function(err2, zipfile) { - if (err2) fs2.close(fd, defaultCallback); - callback(err2, zipfile); - }); - }); - } - function fromFd(fd, options2, callback) { - if (typeof options2 === "function") { - callback = options2; - options2 = null; - } - if (options2 == null) options2 = {}; - if (options2.autoClose == null) options2.autoClose = false; - if (options2.lazyEntries == null) options2.lazyEntries = false; - if (options2.decodeStrings == null) options2.decodeStrings = true; - if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; - if (options2.strictFileNames == null) options2.strictFileNames = false; - if (callback == null) callback = defaultCallback; - fs2.fstat(fd, function(err, stats) { - if (err) return callback(err); - var reader = fd_slicer.createFromFd(fd, { autoClose: true }); - fromRandomAccessReader(reader, stats.size, options2, callback); - }); - } - function fromBuffer(buffer, options2, callback) { - if (typeof options2 === "function") { - callback = options2; - options2 = null; - } - if (options2 == null) options2 = {}; - options2.autoClose = false; - if (options2.lazyEntries == null) options2.lazyEntries = false; - if (options2.decodeStrings == null) options2.decodeStrings = true; - if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; - if (options2.strictFileNames == null) options2.strictFileNames = false; - var reader = fd_slicer.createFromBuffer(buffer, { maxChunkSize: 65536 }); - fromRandomAccessReader(reader, buffer.length, options2, callback); - } - function fromRandomAccessReader(reader, totalSize, options2, callback) { - if (typeof options2 === "function") { - callback = options2; - options2 = null; - } - if (options2 == null) options2 = {}; - if (options2.autoClose == null) options2.autoClose = true; - if (options2.lazyEntries == null) options2.lazyEntries = false; - if (options2.decodeStrings == null) options2.decodeStrings = true; - var decodeStrings = !!options2.decodeStrings; - if (options2.validateEntrySizes == null) options2.validateEntrySizes = true; - if (options2.strictFileNames == null) options2.strictFileNames = false; - if (callback == null) callback = defaultCallback; - if (typeof totalSize !== "number") throw new Error("expected totalSize parameter to be a number"); - if (totalSize > Number.MAX_SAFE_INTEGER) { - throw new Error("zip file too large. only file sizes up to 2^52 are supported due to JavaScript's Number type being an IEEE 754 double."); - } - reader.ref(); - var eocdrWithoutCommentSize = 22; - var maxCommentSize = 65535; - var bufferSize = Math.min(eocdrWithoutCommentSize + maxCommentSize, totalSize); - var buffer = newBuffer(bufferSize); - var bufferReadStart = totalSize - buffer.length; - readAndAssertNoEof(reader, buffer, 0, bufferSize, bufferReadStart, function(err) { - if (err) return callback(err); - for (var i = bufferSize - eocdrWithoutCommentSize; i >= 0; i -= 1) { - if (buffer.readUInt32LE(i) !== 101010256) continue; - var eocdrBuffer = buffer.slice(i); - var diskNumber = eocdrBuffer.readUInt16LE(4); - if (diskNumber !== 0) { - return callback(new Error("multi-disk zip files are not supported: found disk number: " + diskNumber)); - } - var entryCount = eocdrBuffer.readUInt16LE(10); - var centralDirectoryOffset = eocdrBuffer.readUInt32LE(16); - var commentLength = eocdrBuffer.readUInt16LE(20); - var expectedCommentLength = eocdrBuffer.length - eocdrWithoutCommentSize; - if (commentLength !== expectedCommentLength) { - return callback(new Error("invalid comment length. expected: " + expectedCommentLength + ". found: " + commentLength)); - } - var comment6 = decodeStrings ? decodeBuffer(eocdrBuffer, 22, eocdrBuffer.length, false) : eocdrBuffer.slice(22); - if (!(entryCount === 65535 || centralDirectoryOffset === 4294967295)) { - return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames)); - } - var zip64EocdlBuffer = newBuffer(20); - var zip64EocdlOffset = bufferReadStart + i - zip64EocdlBuffer.length; - readAndAssertNoEof(reader, zip64EocdlBuffer, 0, zip64EocdlBuffer.length, zip64EocdlOffset, function(err2) { - if (err2) return callback(err2); - if (zip64EocdlBuffer.readUInt32LE(0) !== 117853008) { - return callback(new Error("invalid zip64 end of central directory locator signature")); - } - var zip64EocdrOffset = readUInt64LE(zip64EocdlBuffer, 8); - var zip64EocdrBuffer = newBuffer(56); - readAndAssertNoEof(reader, zip64EocdrBuffer, 0, zip64EocdrBuffer.length, zip64EocdrOffset, function(err3) { - if (err3) return callback(err3); - if (zip64EocdrBuffer.readUInt32LE(0) !== 101075792) { - return callback(new Error("invalid zip64 end of central directory record signature")); - } - entryCount = readUInt64LE(zip64EocdrBuffer, 32); - centralDirectoryOffset = readUInt64LE(zip64EocdrBuffer, 48); - return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames)); - }); - }); - return; - } - callback(new Error("end of central directory record signature not found")); - }); - } - util.inherits(ZipFile, EventEmitter); - function ZipFile(reader, centralDirectoryOffset, fileSize, entryCount, comment6, autoClose, lazyEntries, decodeStrings, validateEntrySizes, strictFileNames) { - var self2 = this; - EventEmitter.call(self2); - self2.reader = reader; - self2.reader.on("error", function(err) { - emitError(self2, err); - }); - self2.reader.once("close", function() { - self2.emit("close"); - }); - self2.readEntryCursor = centralDirectoryOffset; - self2.fileSize = fileSize; - self2.entryCount = entryCount; - self2.comment = comment6; - self2.entriesRead = 0; - self2.autoClose = !!autoClose; - self2.lazyEntries = !!lazyEntries; - self2.decodeStrings = !!decodeStrings; - self2.validateEntrySizes = !!validateEntrySizes; - self2.strictFileNames = !!strictFileNames; - self2.isOpen = true; - self2.emittedError = false; - if (!self2.lazyEntries) self2._readEntry(); - } - ZipFile.prototype.close = function() { - if (!this.isOpen) return; - this.isOpen = false; - this.reader.unref(); - }; - function emitErrorAndAutoClose(self2, err) { - if (self2.autoClose) self2.close(); - emitError(self2, err); - } - function emitError(self2, err) { - if (self2.emittedError) return; - self2.emittedError = true; - self2.emit("error", err); - } - ZipFile.prototype.readEntry = function() { - if (!this.lazyEntries) throw new Error("readEntry() called without lazyEntries:true"); - this._readEntry(); - }; - ZipFile.prototype._readEntry = function() { - var self2 = this; - if (self2.entryCount === self2.entriesRead) { - setImmediate(function() { - if (self2.autoClose) self2.close(); - if (self2.emittedError) return; - self2.emit("end"); - }); - return; - } - if (self2.emittedError) return; - var buffer = newBuffer(46); - readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, self2.readEntryCursor, function(err) { - if (err) return emitErrorAndAutoClose(self2, err); - if (self2.emittedError) return; - var entry6 = new Entry(); - var signature = buffer.readUInt32LE(0); - if (signature !== 33639248) return emitErrorAndAutoClose(self2, new Error("invalid central directory file header signature: 0x" + signature.toString(16))); - entry6.versionMadeBy = buffer.readUInt16LE(4); - entry6.versionNeededToExtract = buffer.readUInt16LE(6); - entry6.generalPurposeBitFlag = buffer.readUInt16LE(8); - entry6.compressionMethod = buffer.readUInt16LE(10); - entry6.lastModFileTime = buffer.readUInt16LE(12); - entry6.lastModFileDate = buffer.readUInt16LE(14); - entry6.crc32 = buffer.readUInt32LE(16); - entry6.compressedSize = buffer.readUInt32LE(20); - entry6.uncompressedSize = buffer.readUInt32LE(24); - entry6.fileNameLength = buffer.readUInt16LE(28); - entry6.extraFieldLength = buffer.readUInt16LE(30); - entry6.fileCommentLength = buffer.readUInt16LE(32); - entry6.internalFileAttributes = buffer.readUInt16LE(36); - entry6.externalFileAttributes = buffer.readUInt32LE(38); - entry6.relativeOffsetOfLocalHeader = buffer.readUInt32LE(42); - if (entry6.generalPurposeBitFlag & 64) return emitErrorAndAutoClose(self2, new Error("strong encryption is not supported")); - self2.readEntryCursor += 46; - buffer = newBuffer(entry6.fileNameLength + entry6.extraFieldLength + entry6.fileCommentLength); - readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, self2.readEntryCursor, function(err2) { - if (err2) return emitErrorAndAutoClose(self2, err2); - if (self2.emittedError) return; - var isUtf8 = (entry6.generalPurposeBitFlag & 2048) !== 0; - entry6.fileName = self2.decodeStrings ? decodeBuffer(buffer, 0, entry6.fileNameLength, isUtf8) : buffer.slice(0, entry6.fileNameLength); - var fileCommentStart = entry6.fileNameLength + entry6.extraFieldLength; - var extraFieldBuffer = buffer.slice(entry6.fileNameLength, fileCommentStart); - entry6.extraFields = []; - var i = 0; - while (i < extraFieldBuffer.length - 3) { - var headerId = extraFieldBuffer.readUInt16LE(i + 0); - var dataSize = extraFieldBuffer.readUInt16LE(i + 2); - var dataStart = i + 4; - var dataEnd = dataStart + dataSize; - if (dataEnd > extraFieldBuffer.length) return emitErrorAndAutoClose(self2, new Error("extra field length exceeds extra field buffer size")); - var dataBuffer = newBuffer(dataSize); - extraFieldBuffer.copy(dataBuffer, 0, dataStart, dataEnd); - entry6.extraFields.push({ - id: headerId, - data: dataBuffer - }); - i = dataEnd; - } - entry6.fileComment = self2.decodeStrings ? decodeBuffer(buffer, fileCommentStart, fileCommentStart + entry6.fileCommentLength, isUtf8) : buffer.slice(fileCommentStart, fileCommentStart + entry6.fileCommentLength); - entry6.comment = entry6.fileComment; - self2.readEntryCursor += buffer.length; - self2.entriesRead += 1; - if (entry6.uncompressedSize === 4294967295 || entry6.compressedSize === 4294967295 || entry6.relativeOffsetOfLocalHeader === 4294967295) { - var zip64EiefBuffer = null; - for (var i = 0; i < entry6.extraFields.length; i++) { - var extraField = entry6.extraFields[i]; - if (extraField.id === 1) { - zip64EiefBuffer = extraField.data; - break; - } - } - if (zip64EiefBuffer == null) { - return emitErrorAndAutoClose(self2, new Error("expected zip64 extended information extra field")); - } - var index4 = 0; - if (entry6.uncompressedSize === 4294967295) { - if (index4 + 8 > zip64EiefBuffer.length) { - return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include uncompressed size")); - } - entry6.uncompressedSize = readUInt64LE(zip64EiefBuffer, index4); - index4 += 8; - } - if (entry6.compressedSize === 4294967295) { - if (index4 + 8 > zip64EiefBuffer.length) { - return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include compressed size")); - } - entry6.compressedSize = readUInt64LE(zip64EiefBuffer, index4); - index4 += 8; - } - if (entry6.relativeOffsetOfLocalHeader === 4294967295) { - if (index4 + 8 > zip64EiefBuffer.length) { - return emitErrorAndAutoClose(self2, new Error("zip64 extended information extra field does not include relative header offset")); - } - entry6.relativeOffsetOfLocalHeader = readUInt64LE(zip64EiefBuffer, index4); - index4 += 8; - } - } - if (self2.decodeStrings) { - for (var i = 0; i < entry6.extraFields.length; i++) { - var extraField = entry6.extraFields[i]; - if (extraField.id === 28789) { - if (extraField.data.length < 6) { - continue; - } - if (extraField.data.readUInt8(0) !== 1) { - continue; - } - var oldNameCrc32 = extraField.data.readUInt32LE(1); - if (crc32.unsigned(buffer.slice(0, entry6.fileNameLength)) !== oldNameCrc32) { - continue; - } - entry6.fileName = decodeBuffer(extraField.data, 5, extraField.data.length, true); - break; - } - } - } - if (self2.validateEntrySizes && entry6.compressionMethod === 0) { - var expectedCompressedSize = entry6.uncompressedSize; - if (entry6.isEncrypted()) { - expectedCompressedSize += 12; - } - if (entry6.compressedSize !== expectedCompressedSize) { - var msg = "compressed/uncompressed size mismatch for stored file: " + entry6.compressedSize + " != " + entry6.uncompressedSize; - return emitErrorAndAutoClose(self2, new Error(msg)); - } - } - if (self2.decodeStrings) { - if (!self2.strictFileNames) { - entry6.fileName = entry6.fileName.replace(/\\/g, "/"); - } - var errorMessage = validateFileName(entry6.fileName, self2.validateFileNameOptions); - if (errorMessage != null) return emitErrorAndAutoClose(self2, new Error(errorMessage)); - } - self2.emit("entry", entry6); - if (!self2.lazyEntries) self2._readEntry(); - }); - }); - }; - ZipFile.prototype.openReadStream = function(entry6, options2, callback) { - var self2 = this; - var relativeStart = 0; - var relativeEnd = entry6.compressedSize; - if (callback == null) { - callback = options2; - options2 = {}; - } else { - if (options2.decrypt != null) { - if (!entry6.isEncrypted()) { - throw new Error("options.decrypt can only be specified for encrypted entries"); - } - if (options2.decrypt !== false) throw new Error("invalid options.decrypt value: " + options2.decrypt); - if (entry6.isCompressed()) { - if (options2.decompress !== false) throw new Error("entry is encrypted and compressed, and options.decompress !== false"); - } - } - if (options2.decompress != null) { - if (!entry6.isCompressed()) { - throw new Error("options.decompress can only be specified for compressed entries"); - } - if (!(options2.decompress === false || options2.decompress === true)) { - throw new Error("invalid options.decompress value: " + options2.decompress); - } - } - if (options2.start != null || options2.end != null) { - if (entry6.isCompressed() && options2.decompress !== false) { - throw new Error("start/end range not allowed for compressed entry without options.decompress === false"); - } - if (entry6.isEncrypted() && options2.decrypt !== false) { - throw new Error("start/end range not allowed for encrypted entry without options.decrypt === false"); - } - } - if (options2.start != null) { - relativeStart = options2.start; - if (relativeStart < 0) throw new Error("options.start < 0"); - if (relativeStart > entry6.compressedSize) throw new Error("options.start > entry.compressedSize"); - } - if (options2.end != null) { - relativeEnd = options2.end; - if (relativeEnd < 0) throw new Error("options.end < 0"); - if (relativeEnd > entry6.compressedSize) throw new Error("options.end > entry.compressedSize"); - if (relativeEnd < relativeStart) throw new Error("options.end < options.start"); - } - } - if (!self2.isOpen) return callback(new Error("closed")); - if (entry6.isEncrypted()) { - if (options2.decrypt !== false) return callback(new Error("entry is encrypted, and options.decrypt !== false")); - } - self2.reader.ref(); - var buffer = newBuffer(30); - readAndAssertNoEof(self2.reader, buffer, 0, buffer.length, entry6.relativeOffsetOfLocalHeader, function(err) { - try { - if (err) return callback(err); - var signature = buffer.readUInt32LE(0); - if (signature !== 67324752) { - return callback(new Error("invalid local file header signature: 0x" + signature.toString(16))); - } - var fileNameLength = buffer.readUInt16LE(26); - var extraFieldLength = buffer.readUInt16LE(28); - var localFileHeaderEnd = entry6.relativeOffsetOfLocalHeader + buffer.length + fileNameLength + extraFieldLength; - var decompress2; - if (entry6.compressionMethod === 0) { - decompress2 = false; - } else if (entry6.compressionMethod === 8) { - decompress2 = options2.decompress != null ? options2.decompress : true; - } else { - return callback(new Error("unsupported compression method: " + entry6.compressionMethod)); - } - var fileDataStart = localFileHeaderEnd; - var fileDataEnd = fileDataStart + entry6.compressedSize; - if (entry6.compressedSize !== 0) { - if (fileDataEnd > self2.fileSize) { - return callback(new Error("file data overflows file bounds: " + fileDataStart + " + " + entry6.compressedSize + " > " + self2.fileSize)); - } - } - var readStream = self2.reader.createReadStream({ - start: fileDataStart + relativeStart, - end: fileDataStart + relativeEnd - }); - var endpointStream = readStream; - if (decompress2) { - var destroyed = false; - var inflateFilter = zlib.createInflateRaw(); - readStream.on("error", function(err2) { - setImmediate(function() { - if (!destroyed) inflateFilter.emit("error", err2); - }); - }); - readStream.pipe(inflateFilter); - if (self2.validateEntrySizes) { - endpointStream = new AssertByteCountStream(entry6.uncompressedSize); - inflateFilter.on("error", function(err2) { - setImmediate(function() { - if (!destroyed) endpointStream.emit("error", err2); - }); - }); - inflateFilter.pipe(endpointStream); - } else { - endpointStream = inflateFilter; - } - endpointStream.destroy = function() { - destroyed = true; - if (inflateFilter !== endpointStream) inflateFilter.unpipe(endpointStream); - readStream.unpipe(inflateFilter); - readStream.destroy(); - }; - } - callback(null, endpointStream); - } finally { - self2.reader.unref(); - } - }); - }; - function Entry() { - } - Entry.prototype.getLastModDate = function() { - return dosDateTimeToDate(this.lastModFileDate, this.lastModFileTime); - }; - Entry.prototype.isEncrypted = function() { - return (this.generalPurposeBitFlag & 1) !== 0; - }; - Entry.prototype.isCompressed = function() { - return this.compressionMethod === 8; - }; - function dosDateTimeToDate(date, time2) { - var day = date & 31; - var month = (date >> 5 & 15) - 1; - var year = (date >> 9 & 127) + 1980; - var millisecond = 0; - var second = (time2 & 31) * 2; - var minute = time2 >> 5 & 63; - var hour = time2 >> 11 & 31; - return new Date(year, month, day, hour, minute, second, millisecond); - } - function validateFileName(fileName) { - if (fileName.indexOf("\\") !== -1) { - return "invalid characters in fileName: " + fileName; - } - if (/^[a-zA-Z]:/.test(fileName) || /^\//.test(fileName)) { - return "absolute path: " + fileName; - } - if (fileName.split("/").indexOf("..") !== -1) { - return "invalid relative path: " + fileName; - } - return null; - } - function readAndAssertNoEof(reader, buffer, offset, length, position, callback) { - if (length === 0) { - return setImmediate(function() { - callback(null, newBuffer(0)); - }); - } - reader.read(buffer, offset, length, position, function(err, bytesRead) { - if (err) return callback(err); - if (bytesRead < length) { - return callback(new Error("unexpected EOF")); - } - callback(); - }); - } - util.inherits(AssertByteCountStream, Transform); - function AssertByteCountStream(byteCount) { - Transform.call(this); - this.actualByteCount = 0; - this.expectedByteCount = byteCount; - } - AssertByteCountStream.prototype._transform = function(chunk, encoding, cb) { - this.actualByteCount += chunk.length; - if (this.actualByteCount > this.expectedByteCount) { - var msg = "too many bytes in the stream. expected " + this.expectedByteCount + ". got at least " + this.actualByteCount; - return cb(new Error(msg)); - } - cb(null, chunk); - }; - AssertByteCountStream.prototype._flush = function(cb) { - if (this.actualByteCount < this.expectedByteCount) { - var msg = "not enough bytes in the stream. expected " + this.expectedByteCount + ". got only " + this.actualByteCount; - return cb(new Error(msg)); - } - cb(); - }; - util.inherits(RandomAccessReader, EventEmitter); - function RandomAccessReader() { - EventEmitter.call(this); - this.refCount = 0; - } - RandomAccessReader.prototype.ref = function() { - this.refCount += 1; - }; - RandomAccessReader.prototype.unref = function() { - var self2 = this; - self2.refCount -= 1; - if (self2.refCount > 0) return; - if (self2.refCount < 0) throw new Error("invalid unref"); - self2.close(onCloseDone); - function onCloseDone(err) { - if (err) return self2.emit("error", err); - self2.emit("close"); - } - }; - RandomAccessReader.prototype.createReadStream = function(options2) { - var start = options2.start; - var end = options2.end; - if (start === end) { - var emptyStream = new PassThrough(); - setImmediate(function() { - emptyStream.end(); - }); - return emptyStream; - } - var stream2 = this._readStreamForRange(start, end); - var destroyed = false; - var refUnrefFilter = new RefUnrefFilter(this); - stream2.on("error", function(err) { - setImmediate(function() { - if (!destroyed) refUnrefFilter.emit("error", err); - }); - }); - refUnrefFilter.destroy = function() { - stream2.unpipe(refUnrefFilter); - refUnrefFilter.unref(); - stream2.destroy(); - }; - var byteCounter = new AssertByteCountStream(end - start); - refUnrefFilter.on("error", function(err) { - setImmediate(function() { - if (!destroyed) byteCounter.emit("error", err); - }); - }); - byteCounter.destroy = function() { - destroyed = true; - refUnrefFilter.unpipe(byteCounter); - refUnrefFilter.destroy(); - }; - return stream2.pipe(refUnrefFilter).pipe(byteCounter); - }; - RandomAccessReader.prototype._readStreamForRange = function(start, end) { - throw new Error("not implemented"); - }; - RandomAccessReader.prototype.read = function(buffer, offset, length, position, callback) { - var readStream = this.createReadStream({ start: position, end: position + length }); - var writeStream = new Writable(); - var written = 0; - writeStream._write = function(chunk, encoding, cb) { - chunk.copy(buffer, offset + written, 0, chunk.length); - written += chunk.length; - cb(); - }; - writeStream.on("finish", callback); - readStream.on("error", function(error4) { - callback(error4); - }); - readStream.pipe(writeStream); - }; - RandomAccessReader.prototype.close = function(callback) { - setImmediate(callback); - }; - util.inherits(RefUnrefFilter, PassThrough); - function RefUnrefFilter(context) { - PassThrough.call(this); - this.context = context; - this.context.ref(); - this.unreffedYet = false; - } - RefUnrefFilter.prototype._flush = function(cb) { - this.unref(); - cb(); - }; - RefUnrefFilter.prototype.unref = function(cb) { - if (this.unreffedYet) return; - this.unreffedYet = true; - this.context.unref(); - }; - var cp437 = "\0\u263A\u263B\u2665\u2666\u2663\u2660\u2022\u25D8\u25CB\u25D9\u2642\u2640\u266A\u266B\u263C\u25BA\u25C4\u2195\u203C\xB6\xA7\u25AC\u21A8\u2191\u2193\u2192\u2190\u221F\u2194\u25B2\u25BC !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u2302\xC7\xFC\xE9\xE2\xE4\xE0\xE5\xE7\xEA\xEB\xE8\xEF\xEE\xEC\xC4\xC5\xC9\xE6\xC6\xF4\xF6\xF2\xFB\xF9\xFF\xD6\xDC\xA2\xA3\xA5\u20A7\u0192\xE1\xED\xF3\xFA\xF1\xD1\xAA\xBA\xBF\u2310\xAC\xBD\xBC\xA1\xAB\xBB\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255D\u255C\u255B\u2510\u2514\u2534\u252C\u251C\u2500\u253C\u255E\u255F\u255A\u2554\u2569\u2566\u2560\u2550\u256C\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256B\u256A\u2518\u250C\u2588\u2584\u258C\u2590\u2580\u03B1\xDF\u0393\u03C0\u03A3\u03C3\xB5\u03C4\u03A6\u0398\u03A9\u03B4\u221E\u03C6\u03B5\u2229\u2261\xB1\u2265\u2264\u2320\u2321\xF7\u2248\xB0\u2219\xB7\u221A\u207F\xB2\u25A0\xA0"; - function decodeBuffer(buffer, start, end, isUtf8) { - if (isUtf8) { - return buffer.toString("utf8", start, end); - } else { - var result = ""; - for (var i = start; i < end; i++) { - result += cp437[buffer[i]]; - } - return result; - } - } - function readUInt64LE(buffer, offset) { - var lower32 = buffer.readUInt32LE(offset); - var upper32 = buffer.readUInt32LE(offset + 4); - return upper32 * 4294967296 + lower32; - } - var newBuffer; - if (typeof Buffer.allocUnsafe === "function") { - newBuffer = function(len) { - return Buffer.allocUnsafe(len); - }; - } else { - newBuffer = function(len) { - return new Buffer(len); - }; - } - function defaultCallback(err) { - if (err) throw err; - } - } -}); - -// node_modules/decompress-unzip/index.js -var require_decompress_unzip = __commonJS({ - "node_modules/decompress-unzip/index.js"(exports2, module3) { - "use strict"; - var fileType = require_file_type3(); - var getStream = require_get_stream(); - var pify = require_pify(); - var yauzl = require_yauzl(); - var getType = (entry6, mode) => { - const IFMT = 61440; - const IFDIR = 16384; - const IFLNK = 40960; - const madeBy = entry6.versionMadeBy >> 8; - if ((mode & IFMT) === IFLNK) { - return "symlink"; - } - if ((mode & IFMT) === IFDIR || madeBy === 0 && entry6.externalFileAttributes === 16) { - return "directory"; - } - return "file"; - }; - var extractEntry = (entry6, zip) => { - const file9 = { - mode: entry6.externalFileAttributes >> 16 & 65535, - mtime: entry6.getLastModDate(), - path: entry6.fileName - }; - file9.type = getType(entry6, file9.mode); - if (file9.mode === 0 && file9.type === "directory") { - file9.mode = 493; - } - if (file9.mode === 0) { - file9.mode = 420; - } - return pify(zip.openReadStream.bind(zip))(entry6).then(getStream.buffer).then((buf) => { - file9.data = buf; - if (file9.type === "symlink") { - file9.linkname = buf.toString(); - } - return file9; - }).catch((err) => { - zip.close(); - throw err; - }); - }; - var extractFile = (zip) => new Promise((resolve2, reject) => { - const files = []; - zip.readEntry(); - zip.on("entry", (entry6) => { - extractEntry(entry6, zip).catch(reject).then((file9) => { - files.push(file9); - zip.readEntry(); - }); - }); - zip.on("error", reject); - zip.on("end", () => resolve2(files)); - }); - module3.exports = () => (buf) => { - if (!Buffer.isBuffer(buf)) { - return Promise.reject(new TypeError(`Expected a Buffer, got ${typeof buf}`)); - } - if (!fileType(buf) || fileType(buf).ext !== "zip") { - return Promise.resolve([]); - } - return pify(yauzl.fromBuffer)(buf, { lazyEntries: true }).then(extractFile); - }; - } -}); - -// node_modules/make-dir/node_modules/pify/index.js -var require_pify2 = __commonJS({ - "node_modules/make-dir/node_modules/pify/index.js"(exports2, module3) { - "use strict"; - var processFn = (fn, opts) => function() { - const P = opts.promiseModule; - const args = new Array(arguments.length); - for (let i = 0; i < arguments.length; i++) { - args[i] = arguments[i]; - } - return new P((resolve2, reject) => { - if (opts.errorFirst) { - args.push(function(err, result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - for (let i = 1; i < arguments.length; i++) { - results[i - 1] = arguments[i]; - } - if (err) { - results.unshift(err); - reject(results); - } else { - resolve2(results); - } - } else if (err) { - reject(err); - } else { - resolve2(result); - } - }); - } else { - args.push(function(result) { - if (opts.multiArgs) { - const results = new Array(arguments.length - 1); - for (let i = 0; i < arguments.length; i++) { - results[i] = arguments[i]; - } - resolve2(results); - } else { - resolve2(result); - } - }); - } - fn.apply(this, args); - }); - }; - module3.exports = (obj, opts) => { - opts = Object.assign({ - exclude: [/.+(Sync|Stream)$/], - errorFirst: true, - promiseModule: Promise - }, opts); - const filter2 = (key2) => { - const match = (pattern) => typeof pattern === "string" ? key2 === pattern : pattern.test(key2); - return opts.include ? opts.include.some(match) : !opts.exclude.some(match); - }; - let ret; - if (typeof obj === "function") { - ret = function() { - if (opts.excludeMain) { - return obj.apply(this, arguments); - } - return processFn(obj, opts).apply(this, arguments); - }; - } else { - ret = Object.create(Object.getPrototypeOf(obj)); - } - for (const key2 in obj) { - const x = obj[key2]; - ret[key2] = typeof x === "function" && filter2(key2) ? processFn(x, opts) : x; - } - return ret; - }; - } -}); - -// node_modules/make-dir/index.js -var require_make_dir = __commonJS({ - "node_modules/make-dir/index.js"(exports2, module3) { - "use strict"; - var fs2 = require("fs"); - var path6 = require("path"); - var pify = require_pify2(); - var defaults = { - mode: 511 & ~process.umask(), - fs: fs2 - }; - var checkPath = (pth) => { - if (process.platform === "win32") { - const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path6.parse(pth).root, "")); - if (pathHasInvalidWinCharacters) { - const err = new Error(`Path contains invalid characters: ${pth}`); - err.code = "EINVAL"; - throw err; - } - } - }; - module3.exports = (input, opts) => Promise.resolve().then(() => { - checkPath(input); - opts = Object.assign({}, defaults, opts); - const mkdir = pify(opts.fs.mkdir); - const stat = pify(opts.fs.stat); - const make = (pth) => { - return mkdir(pth, opts.mode).then(() => pth).catch((err) => { - if (err.code === "ENOENT") { - if (err.message.includes("null bytes") || path6.dirname(pth) === pth) { - throw err; - } - return make(path6.dirname(pth)).then(() => make(pth)); - } - return stat(pth).then((stats) => stats.isDirectory() ? pth : Promise.reject()).catch(() => { - throw err; - }); - }); - }; - return make(path6.resolve(input)); - }); - module3.exports.sync = (input, opts) => { - checkPath(input); - opts = Object.assign({}, defaults, opts); - const make = (pth) => { - try { - opts.fs.mkdirSync(pth, opts.mode); - } catch (err) { - if (err.code === "ENOENT") { - if (err.message.includes("null bytes") || path6.dirname(pth) === pth) { - throw err; - } - make(path6.dirname(pth)); - return make(pth); - } - try { - if (!opts.fs.statSync(pth).isDirectory()) { - throw new Error("The path is not a directory"); - } - } catch (_) { - throw err; - } - } - return pth; - }; - return make(path6.resolve(input)); - }; - } -}); - -// node_modules/is-natural-number/index.js -var require_is_natural_number = __commonJS({ - "node_modules/is-natural-number/index.js"(exports2, module3) { - "use strict"; - module3.exports = function isNaturalNumber(val, option) { - if (option) { - if (typeof option !== "object") { - throw new TypeError( - String(option) + " is not an object. Expected an object that has boolean `includeZero` property." - ); - } - if ("includeZero" in option) { - if (typeof option.includeZero !== "boolean") { - throw new TypeError( - String(option.includeZero) + " is neither true nor false. `includeZero` option must be a Boolean value." - ); - } - if (option.includeZero && val === 0) { - return true; - } - } - } - return Number.isSafeInteger(val) && val >= 1; - }; - } -}); - -// node_modules/strip-dirs/index.js -var require_strip_dirs = __commonJS({ - "node_modules/strip-dirs/index.js"(exports2, module3) { - "use strict"; - var path6 = require("path"); - var util = require("util"); - var isNaturalNumber = require_is_natural_number(); - module3.exports = function stripDirs(pathStr, count, option) { - if (typeof pathStr !== "string") { - throw new TypeError( - util.inspect(pathStr) + " is not a string. First argument to strip-dirs must be a path string." - ); - } - if (path6.posix.isAbsolute(pathStr) || path6.win32.isAbsolute(pathStr)) { - throw new Error(`${pathStr} is an absolute path. strip-dirs requires a relative path.`); - } - if (!isNaturalNumber(count, { includeZero: true })) { - throw new Error( - "The Second argument of strip-dirs must be a natural number or 0, but received " + util.inspect(count) + "." - ); - } - if (option) { - if (typeof option !== "object") { - throw new TypeError( - util.inspect(option) + " is not an object. Expected an object with a boolean `disallowOverflow` property." - ); - } - if (Array.isArray(option)) { - throw new TypeError( - util.inspect(option) + " is an array. Expected an object with a boolean `disallowOverflow` property." - ); - } - if ("disallowOverflow" in option && typeof option.disallowOverflow !== "boolean") { - throw new TypeError( - util.inspect(option.disallowOverflow) + " is neither true nor false. `disallowOverflow` option must be a Boolean value." - ); - } - } else { - option = { disallowOverflow: false }; - } - const pathComponents = path6.normalize(pathStr).split(path6.sep); - if (pathComponents.length > 1 && pathComponents[0] === ".") { - pathComponents.shift(); - } - if (count > pathComponents.length - 1) { - if (option.disallowOverflow) { - throw new RangeError("Cannot strip more directories than there are."); - } - count = pathComponents.length - 1; - } - return path6.join.apply(null, pathComponents.slice(count)); - }; - } -}); - -// node_modules/decompress/index.js -var require_decompress = __commonJS({ - "node_modules/decompress/index.js"(exports2, module3) { - "use strict"; - var path6 = require("path"); - var fs2 = require_graceful_fs(); - var decompressTar = require_decompress_tar(); - var decompressTarbz2 = require_decompress_tarbz2(); - var decompressTargz = require_decompress_targz(); - var decompressUnzip = require_decompress_unzip(); - var makeDir = require_make_dir(); - var pify = require_pify(); - var stripDirs = require_strip_dirs(); - var fsP = pify(fs2); - var runPlugins = (input, opts) => { - if (opts.plugins.length === 0) { - return Promise.resolve([]); - } - return Promise.all(opts.plugins.map((x) => x(input, opts))).then((files) => files.reduce((a, b) => a.concat(b))); - }; - var safeMakeDir = (dir, realOutputPath) => { - return fsP.realpath(dir).catch((_) => { - const parent = path6.dirname(dir); - return safeMakeDir(parent, realOutputPath); - }).then((realParentPath) => { - if (realParentPath.indexOf(realOutputPath) !== 0) { - throw new Error("Refusing to create a directory outside the output path."); - } - return makeDir(dir).then(fsP.realpath); - }); - }; - var preventWritingThroughSymlink = (destination, realOutputPath) => { - return fsP.readlink(destination).catch((_) => { - return null; - }).then((symlinkPointsTo) => { - if (symlinkPointsTo) { - throw new Error("Refusing to write into a symlink"); - } - return realOutputPath; - }); - }; - var extractFile = (input, output, opts) => runPlugins(input, opts).then((files) => { - if (opts.strip > 0) { - files = files.map((x) => { - x.path = stripDirs(x.path, opts.strip); - return x; - }).filter((x) => x.path !== "."); - } - if (typeof opts.filter === "function") { - files = files.filter(opts.filter); - } - if (typeof opts.map === "function") { - files = files.map(opts.map); - } - if (!output) { - return files; - } - return Promise.all(files.map((x) => { - const dest = path6.join(output, x.path); - const mode = x.mode & ~process.umask(); - const now = /* @__PURE__ */ new Date(); - if (x.type === "directory") { - return makeDir(output).then((outputPath) => fsP.realpath(outputPath)).then((realOutputPath) => safeMakeDir(dest, realOutputPath)).then(() => fsP.utimes(dest, now, x.mtime)).then(() => x); - } - return makeDir(output).then((outputPath) => fsP.realpath(outputPath)).then((realOutputPath) => { - return safeMakeDir(path6.dirname(dest), realOutputPath).then(() => realOutputPath); - }).then((realOutputPath) => { - if (x.type === "file") { - return preventWritingThroughSymlink(dest, realOutputPath); - } - return realOutputPath; - }).then((realOutputPath) => { - return fsP.realpath(path6.dirname(dest)).then((realDestinationDir) => { - if (realDestinationDir.indexOf(realOutputPath) !== 0) { - throw new Error("Refusing to write outside output directory: " + realDestinationDir); - } - }); - }).then(() => { - if (x.type === "link") { - return fsP.link(x.linkname, dest); - } - if (x.type === "symlink" && process.platform === "win32") { - return fsP.link(x.linkname, dest); - } - if (x.type === "symlink") { - return fsP.symlink(x.linkname, dest); - } - return fsP.writeFile(dest, x.data, { mode }); - }).then(() => x.type === "file" && fsP.utimes(dest, now, x.mtime)).then(() => x); - })); - }); - module3.exports = (input, output, opts) => { - if (typeof input !== "string" && !Buffer.isBuffer(input)) { - return Promise.reject(new TypeError("Input file required")); - } - if (typeof output === "object") { - opts = output; - output = null; - } - opts = Object.assign({ plugins: [ - decompressTar(), - decompressTarbz2(), - decompressTargz(), - decompressUnzip() - ] }, opts); - const read = typeof input === "string" ? fsP.readFile(input) : Promise.resolve(input); - return read.then((buf) => extractFile(buf, output, opts)); - }; - } -}); - -// mcs-spyglass-validate.mjs -var import_node_fs2 = require("node:fs"); -var import_node_os2 = require("node:os"); -var import_node_path = require("node:path"); -var import_node_url2 = require("node:url"); - -// node_modules/@spyglassmc/core/lib/common/Dev.js -var Dev; -(function(Dev2) { - function assertDefined(value) { - if (value === void 0) { - throw new Error(`'${Dev2.stringify(value)}' is 'undefined'`); - } - } - Dev2.assertDefined = assertDefined; - function assertNever(value) { - throw new Error(`'${Dev2.stringify(value)}' is not of type 'never'`); - } - Dev2.assertNever = assertNever; - function assertTrue(value, message2) { - if (!value) { - throw new Error(`Assertion failed: ${message2}. '${Dev2.stringify(value)}' should be true.`); - } - } - Dev2.assertTrue = assertTrue; - function estimateMemoryUsage(value) { - const ByteToBits = 8; - const PointerSize = 8; - let ans = 0; - const calculatedObjects = /* @__PURE__ */ new Set(); - const stack = [value]; - while (stack.length) { - const current = stack.pop(); - switch (typeof current) { - case "bigint": { - const bits = Math.ceil(Math.log2(Number(current))); - ans += (2 + Math.ceil(bits / (ByteToBits * PointerSize))) * PointerSize; - break; - } - case "boolean": - ans += PointerSize; - break; - case "number": - ans += 8; - break; - case "object": - ans += PointerSize; - if (!current || calculatedObjects.has(current)) { - break; - } - ans += PointerSize; - for (const value2 of Object.values(current)) { - stack.push(value2); - ans += PointerSize; - } - calculatedObjects.add(current); - break; - case "string": - ans += current.length * 2; - break; - case "symbol": - ans += PointerSize; - break; - default: - break; - } - } - return ans; - } - Dev2.estimateMemoryUsage = estimateMemoryUsage; - function stringify(value) { - if (value && typeof value === "object") { - try { - const seen = /* @__PURE__ */ new Set(); - return JSON.stringify(value, (k, v) => { - if (v && typeof v === "object") { - return seen.has(v) ? "[Circular]" : (seen.add(v), v); - } else { - return bigintJsonNumberReplacer(k, v); - } - }); - } catch (ignored) { - return `{ ${Object.entries(value).map(([k, v]) => `'${k}': '${String(v)}'`).join(", ")} }`; - } - } else if (typeof value === "symbol") { - return String(value); - } else { - return `${value}`; - } - } - Dev2.stringify = stringify; -})(Dev || (Dev = {})); - -// node_modules/@spyglassmc/core/lib/common/EventDispatcher.js -var EventDispatcher = class { - #target = new EventTarget(); - emit(name, data) { - this.#target.dispatchEvent(new CustomEvent(name, { detail: data })); - } - on(name, listener, options2) { - this.#target.addEventListener(name, (event) => { - Dev.assertTrue(event instanceof CustomEvent, "event must be an instance of CustomEvent"); - listener(event.detail); - }, options2); - return this; - } -}; - -// node_modules/@spyglassmc/core/lib/common/json.js -function bigintJsonLosslessReplacer(_key, value) { - return typeof value === "bigint" ? `$$type:bigint;$$value:${value}` : value; -} -function bigintJsonLosslessReviver(_key, value) { - return typeof value === "string" && value.startsWith("$$type:bigint;$$value:") ? BigInt(value.substring(22)) : value; -} -function bigintJsonNumberReplacer(_key, value) { - return typeof value === "bigint" ? JSON.rawJSON(value.toString()) : value; -} -function bigintJsonNumberReviver(_key, value, data) { - return typeof value === "number" && data?.source !== void 0 && !data.source.includes(".") && !data.source.includes("e") && !data.source.includes("E") && BigInt(value).toString() !== data.source ? BigInt(data.source) : value; -} - -// node_modules/@spyglassmc/core/lib/common/Logger.js -var Logger; -(function(Logger2) { - function create() { - return console; - } - Logger2.create = create; - function noop6() { - return new NoopLogger(); - } - Logger2.noop = noop6; -})(Logger || (Logger = {})); -var NoopLogger = class { - error() { - } - info() { - } - log() { - } - warn() { - } -}; - -// node_modules/@spyglassmc/core/lib/common/Operations.js -var Operations = class { - parent; - constructor(parent) { - this.parent = parent; - } - undoOps = []; - redoOps = []; - addUndoOp(op) { - this.undoOps.push(op); - this.parent?.addUndoOp(op); - } - addRedoOp(op) { - this.redoOps.push(op); - this.parent?.addRedoOp(op); - } - set(obj, key2, value, receiver = obj) { - const oldValue = Reflect.get(obj, key2, receiver); - const op = () => { - Reflect.set(obj, key2, value, receiver); - }; - const undoOp = () => { - Reflect.set(obj, key2, oldValue, receiver); - }; - this.addRedoOp(op); - this.addUndoOp(undoOp); - op(); - } - undo() { - for (let i = this.undoOps.length - 1; i >= 0; i--) { - this.undoOps[i](); - } - } - redo() { - this.redoOps.forEach((op) => op()); - } -}; - -// node_modules/@spyglassmc/core/lib/common/util.js -var import_binary_search = __toESM(require_binary_search(), 1); -var import_rfdc = __toESM(require_rfdc(), 1); -var import_whatwg_url = __toESM(require_whatwg_url(), 1); -var Uri = isBuiltInURLGood() ? URL : import_whatwg_url.URL; -function isBuiltInURLGood() { - try { - return new URL("archive://mcdoc.tar.gz/foo.mcdoc").host === "mcdoc.tar.gz"; - } catch { - return false; - } -} -function SingletonPromise(getKey = (args) => args[0]) { - return (_target, _key, descripter) => { - const promises = /* @__PURE__ */ new Map(); - const decoratedMethod = descripter.value; - descripter.value = function(...args) { - const key2 = getKey(args); - if (promises.has(key2)) { - return promises.get(key2); - } - const ans = decoratedMethod.apply(this, args).then((ans2) => (promises.delete(key2), ans2), (e) => (promises.delete(key2), Promise.reject(e))); - promises.set(key2, ans); - return ans; - }; - return descripter; - }; -} -var ResourceLocation; -(function(ResourceLocation2) { - ResourceLocation2.TagPrefix = "#"; - ResourceLocation2.NamespacePathSep = ":"; - ResourceLocation2.PathSep = "/"; - ResourceLocation2.DefaultNamespace = "minecraft"; - function lengthen(value) { - switch (value.indexOf(ResourceLocation2.NamespacePathSep)) { - case -1: - return `${ResourceLocation2.DefaultNamespace}${ResourceLocation2.NamespacePathSep}${value}`; - case 0: - return `${ResourceLocation2.DefaultNamespace}${value}`; - default: - return value; - } - } - ResourceLocation2.lengthen = lengthen; - function shorten(value) { - return value.replace(/^(?:minecraft)?:/, ""); - } - ResourceLocation2.shorten = shorten; -})(ResourceLocation || (ResourceLocation = {})); -function bufferToString(buffer) { - const ans = new TextDecoder().decode(buffer); - return ans; -} -var Arrayable; -(function(Arrayable2) { - function is(value, isT) { - return Array.isArray(value) ? value.every((e) => isT(e)) : isT(value); - } - Arrayable2.is = is; - function toArray(value) { - return Array.isArray(value) ? value : [value]; - } - Arrayable2.toArray = toArray; -})(Arrayable || (Arrayable = {})); -var TypePredicates; -(function(TypePredicates2) { - function isString(value) { - return typeof value === "string"; - } - TypePredicates2.isString = isString; -})(TypePredicates || (TypePredicates = {})); -function isPojo(value) { - return !!value && typeof value === "object" && !Array.isArray(value); -} -function merge(a, b) { - const ans = (0, import_rfdc.default)()(a); - for (const [key2, value] of Object.entries(b)) { - if (isPojo(ans[key2]) && isPojo(value)) { - ans[key2] = merge(ans[key2], value); - } else if (value === void 0) { - delete ans[key2]; - } else { - ans[key2] = value; - } - } - return ans; -} -var Lazy; -(function(Lazy2) { - const LazyDiscriminator = Symbol("LazyDiscriminator"); - function create(getter) { - return { discriminator: LazyDiscriminator, getter }; - } - Lazy2.create = create; - function isComplex(lazy) { - return lazy?.discriminator === LazyDiscriminator; - } - Lazy2.isComplex = isComplex; - function isUnresolved(lazy) { - return isComplex(lazy) && !("value" in lazy); - } - Lazy2.isUnresolved = isUnresolved; - function resolve2(lazy) { - return isUnresolved(lazy) ? lazy.value = lazy.getter() : lazy; - } - Lazy2.resolve = resolve2; -})(Lazy || (Lazy = {})); -function getStates(category, ids, ctx) { - const ans = {}; - ids = ids.map(ResourceLocation.lengthen); - for (const id of ids) { - ctx.symbols.query(ctx.doc, category, id).forEachMember((state, stateQuery) => { - const values = Object.keys(stateQuery.visibleMembers); - const set = ans[state] ??= /* @__PURE__ */ new Set(); - const defaultValue = stateQuery.symbol?.relations?.default; - if (defaultValue) { - set.add(defaultValue.path[defaultValue.path.length - 1]); - } - for (const value of values) { - set.add(value); - } - }); - } - return Object.fromEntries(Object.entries(ans).map(([k, v]) => [k, [...v]])); -} -var binarySearch = import_binary_search.default; -function isIterable(value) { - return !!value[Symbol.iterator]; -} -function getOrInsertComputed(map3, key2, callbackFunction) { - if (!map3.has(key2)) { - map3.set(key2, callbackFunction(key2)); - } - return map3.get(key2); -} -function bytesToHex(bytes) { - if ("Buffer" in globalThis && bytes instanceof Buffer) { - return bytes.toString("hex"); - } else if ("toHex" in Uint8Array.prototype && typeof Uint8Array.prototype.toHex === "function") { - return Uint8Array.prototype.toHex.call(bytes); - } - let ans = ""; - for (const v of bytes) { - ans += v.toString(16).padStart(2, "0"); - } - return ans; -} -function isObject(val) { - return typeof val === "function" || !!val && typeof val === "object"; -} -function normalizeUriPathname(pathname) { - return pathname.replace(/%3A/gi, ":").replace(/^\/[A-Z]:\//, (match) => match.toLowerCase()); -} -function normalizeUri(uri) { - const obj = new Uri(uri); - obj.pathname = normalizeUriPathname(obj.pathname); - return obj.toString(); -} -async function getSha1(data) { - if (typeof data === "string") { - data = new TextEncoder().encode(data); - } - const hash = await crypto.subtle.digest("SHA-1", data.buffer); - return bytesToHex(new Uint8Array(hash)); -} -function compressBytes(bytes, algorithm) { - return streamToBytes(compressStream(bytesToStream(bytes), algorithm)); -} -function compressStream(stream2, algorithm) { - return stream2.pipeThrough(new CompressionStream(algorithm)); -} -function decompressBytes(bytes, algorithm) { - return streamToBytes(decompressStream(bytesToStream(bytes), algorithm)); -} -function decompressStream(stream2, algorithm) { - return stream2.pipeThrough(new DecompressionStream(algorithm)); -} -function bytesToStream(bytes) { - return new Blob([bytes]).stream(); -} -function streamToBytes(stream2) { - return new Response(stream2).bytes(); -} -function numericEquals(a, b) { - return tryConvertToNumberWithoutPrecisionLoss(a) === tryConvertToNumberWithoutPrecisionLoss(b); -} -function tryConvertToNumberWithoutPrecisionLoss(n) { - if (typeof n === "bigint") { - const num = Number(n); - if (BigInt(num) === n) { - return num; - } - } - return n; -} -function min(a, b) { - return a < b ? a : b; -} -function max(a, b) { - return a > b ? a : b; -} - -// node_modules/@spyglassmc/core/lib/common/ReadonlyProxy.js -var ReadonlyProxy; -(function(ReadonlyProxy2) { - function create(obj) { - return new Proxy(obj, new ReadonlyProxyHandler()); - } - ReadonlyProxy2.create = create; -})(ReadonlyProxy || (ReadonlyProxy = {})); -var ReadonlyProxyHandler = class { - map = /* @__PURE__ */ new Map(); - get(target, p, receiver) { - const value = Reflect.get(target, p, receiver); - if (p !== "prototype" && isObject(value)) { - return getOrInsertComputed(this.map, p, () => ReadonlyProxy.create(value)); - } - return value; - } - set(_target, p, _value, _receiver) { - throw new TypeError(`Cannot set property '${String(p)}' on a readonly proxy`); - } - deleteProperty(_target, p) { - throw new TypeError(`Cannot delete property '${String(p)}' on a readonly proxy`); - } -}; - -// node_modules/@spyglassmc/core/lib/common/StateProxy.js -var BranchOff = Symbol("StateBranchOff"); -var Is = Symbol("IsStateProxy"); -var Origin = Symbol("OriginState"); -var Redo = Symbol("RedoStateChanges"); -var Undo = Symbol("UndoStateChanges"); -var StateProxy; -(function(StateProxy2) { - function branchOff(proxy) { - return proxy[BranchOff](); - } - StateProxy2.branchOff = branchOff; - function create(obj) { - if (StateProxy2.is(obj)) { - throw new TypeError("Cannot create a proxy over a proxy. You might want to use branchOff instead."); - } - return _createStateProxy(obj, new Operations()); - } - StateProxy2.create = create; - function dereference(value) { - return StateProxy2.is(value) ? value[Origin] : value; - } - StateProxy2.dereference = dereference; - function is(obj) { - return obj?.[Is]; - } - StateProxy2.is = is; - function redoChanges(proxy) { - proxy[Redo](); - } - StateProxy2.redoChanges = redoChanges; - function undoChanges(proxy) { - proxy[Undo](); - } - StateProxy2.undoChanges = undoChanges; -})(StateProxy || (StateProxy = {})); -var StateProxyHandler = class { - rootOps; - map = /* @__PURE__ */ new Map(); - constructor(rootOps) { - this.rootOps = rootOps; - } - #branchOff(target) { - return _createStateProxy(target, new Operations(this.rootOps)); - } - get(target, p, receiver) { - switch (p) { - case BranchOff: - return () => this.#branchOff(target); - case Is: - return true; - case Origin: - return target; - case Redo: - return () => this.rootOps.redo(); - case Undo: - return () => this.rootOps.undo(); - } - const value = Reflect.get(target, p, receiver); - if (p !== "prototype" && isObject(value)) { - return getOrInsertComputed(this.map, p, () => _createStateProxy(value, this.rootOps)); - } - return value; - } - set(target, p, value, receiver) { - if (p === BranchOff || p === Is || p === Origin || p === Redo || p === Undo) { - throw new TypeError(`Cannot set ${String(p)}`); - } - this.rootOps.set(target, p, StateProxy.dereference(value), receiver); - return true; - } -}; -function _createStateProxy(target, operations) { - return new Proxy(target, new StateProxyHandler(operations)); -} - -// node_modules/@spyglassmc/core/lib/common/TwoWayMap.js -var TwoWayMap = class { - _map = /* @__PURE__ */ new Map(); - _reversedMap = /* @__PURE__ */ new Map(); - constructor(values = []) { - for (const [k, v] of values) { - this._map.set(k, v); - this._reversedMap.set(v, k); - } - } - get size() { - return this._map.size; - } - clear() { - this._map.clear(); - this._reversedMap.clear(); - } - delete(key2) { - const value = this._map.get(key2); - const ans = this._map.delete(key2); - if (value !== void 0) { - this._reversedMap.delete(value); - } - return ans; - } - deleteValue(value) { - const key2 = this._reversedMap.get(value); - const ans = this._reversedMap.delete(value); - if (key2 !== void 0) { - this._map.delete(key2); - } - return ans; - } - get(key2) { - return this._map.get(key2); - } - getKey(value) { - return this._reversedMap.get(value); - } - has(key2) { - return this._map.has(key2); - } - hasValue(value) { - return this._reversedMap.has(value); - } - set(key2, value) { - this._map.set(key2, value); - this._reversedMap.set(value, key2); - return this; - } - forEach(callbackfn, thisArg) { - for (const [key2, value] of this._map) { - callbackfn.apply(thisArg, [value, key2, this]); - } - } - entries() { - return this._map.entries(); - } - keys() { - return this._map.keys(); - } - values() { - return this._map.values(); - } - [Symbol.iterator]() { - return this._map.entries(); - } - [Symbol.toStringTag] = "TwoWayMap"; -}; - -// node_modules/@spyglassmc/core/lib/common/UriStore.js -var UriStore = class _UriStore { - #trie = /* @__PURE__ */ new Map(); - /** - * Adds a file URI or a directory URI to the store. - * Directory URIs must end with a slash (`/`), otherwise it will be treated as a file URI. - */ - add(uri) { - const [parts, isDir] = this.#dissectUri(uri); - let node = this.#trie; - for (const [i, part] of parts.entries()) { - const isLast = i === parts.length - 1; - const shouldAddDir = !isLast || isDir; - if (!node.has(part)) { - node.set(part, shouldAddDir ? /* @__PURE__ */ new Map() : {}); - } - if (!isLast) { - const next = node.get(part); - if (next instanceof Map) { - node = next; - } else { - throw new Error(`Cannot add '${uri}' because ${parts.slice(0, i + 1).join("/")} is a file`); - } - } - } - } - /** - * Returns true if the specified URI exists in the store and is of the expected type. - * Directory URIs must end with a slash (`/`), otherwise it will be treated as a file URI. - */ - has(uri) { - const [parts, isDir] = this.#dissectUri(uri); - let node = this.#trie; - for (const part of parts) { - if (!(node instanceof Map)) { - return false; - } - node = node.get(part); - } - return isDir ? node instanceof Map : !!node && typeof node === "object" && !(node instanceof Map); - } - /** - * Deletes a URI from the store if it exists. - * For directories, all sub URIs under them will be recursively removed. - */ - delete(uri) { - const [parts, _isDir] = this.#dissectUri(uri); - let node = this.#trie; - for (const [i, part] of parts.entries()) { - if (!(node instanceof Map)) { - return; - } - if (i === parts.length - 1) { - node.delete(part); - } else { - node = node.get(part); - } - } - } - /** - * Returns names of all direct children of the URI. - * An empty result is generated if the directory URI does not exist. - */ - *getChildrenNames(uri) { - const [parts, _isDir] = this.#dissectUri(uri); - let node = this.#trie; - for (const part of parts) { - if (!(node instanceof Map)) { - return; - } - node = node.get(part); - } - if (!(node instanceof Map)) { - return; - } - yield* node.keys(); - } - /** - * Returns URIs of all files under a directory and its subdirectories. - * An empty result is generated if the directory URI does not exist. - */ - *getSubFiles(uri) { - const [parts, _isDir] = this.#dissectUri(uri); - let node = this.#trie; - for (const part of parts) { - if (!(node instanceof Map)) { - return; - } - node = node.get(part); - } - if (!(node instanceof Map)) { - return; - } - yield* this.#collect(node, parts); - } - /** - * Removes all URIs from the store. - */ - clear() { - this.#trie.clear(); - } - /** - * Creates a deep copy of this store. - */ - clone() { - const clonedStore = new _UriStore(); - clonedStore.#trie = structuredClone(this.#trie); - return clonedStore; - } - [Symbol.iterator]() { - return this.#collect(this.#trie, []); - } - /** - * Dissects a URI string into parts that can be used as edges in the trie. - */ - #dissectUri(uriString) { - const uri = new Uri(uriString); - const isDir = uriString.endsWith("/"); - const parts = [ - uri.protocol, - uri.host || "localhost", - ...normalizeUriPathname(uri.pathname).split("/").filter((p) => p).map(decodeURIComponent) - ]; - return [parts, isDir]; - } - /** - * Reconstructs a URI string from its parts. - * - * This is the inverse of `#dissectUri`. - * It handles special cases like omitting the host when it's 'localhost' and adding a trailing - * slash for directory URIs. - */ - #buildUri(parts, isDir) { - const [protocol, host, ...segments] = parts; - const pathname = normalizeUriPathname(`/${segments.map(encodeURIComponent).join("/")}`); - const trailingSlash = isDir && segments.length ? "/" : ""; - return `${protocol}//${host === "localhost" ? "" : host}${pathname}${trailingSlash}`; - } - /** - * Returns a generator that yields all URIs under a DirectoryNode recursively. - * @param currentParts Parts corresponding to the URI of the DirectoryNode. - */ - *#collect(node, currentParts) { - for (const [key2, value] of node) { - const nextParts = [...currentParts, key2]; - if (value instanceof Map) { - yield* this.#collect(value, nextParts); - } else { - yield this.#buildUri(nextParts, false); - } - } - } -}; - -// node_modules/@spyglassmc/core/lib/node/AstNode.js -var import_binary_search2 = __toESM(require_binary_search(), 1); - -// node_modules/@spyglassmc/core/lib/source/Source.js -var CRLF = "\r\n"; -var CR = "\r"; -var LF = "\n"; -var Whitespaces = Object.freeze([" ", "\n", "\r", " "]); -var ReadonlySource = class { - string; - indexMap; - innerCursor = 0; - constructor(string11, indexMap = []) { - this.string = string11; - this.indexMap = indexMap; - } - get cursor() { - return IndexMap.toOuterOffset(this.indexMap, this.innerCursor); - } - /** - * @param offset The index to offset from cursor. Defaults to 0. - * - * @returns The range of the specified character. - * - * @example - * getCharRange(-1) // Returns the range of the character before cursor. - * getCharRange() // Returns the range of the character at cursor. - * getCharRange(1) // Returns the range of the character after cursor. - */ - getCharRange(offset = 0) { - return IndexMap.toOuterRange(this.indexMap, Range.create(this.innerCursor + offset, this.innerCursor + offset + 1)); - } - /** - * Returns a string that helps visualize this `Source`'s index map. - * Primarily intended for debugging purposes. - */ - visualizeIndexMap() { - let res = this.string; - const adjustments = []; - for (const { inner, outer } of this.indexMap) { - const innerLength = inner.end - inner.start; - const outerLength = outer.end - outer.start; - const { char, count } = outerLength > innerLength ? { - count: outerLength - innerLength, - char: "\u2190" - // ← - } : { count: outer.start - inner.start, char: "\u2017" }; - adjustments.push({ idx: inner.start, str: char.repeat(count) }); - } - for (const { idx, str } of adjustments.reverse()) { - res = `${res.slice(0, idx)}${str}${res.slice(idx)}`; - } - return res; - } - /** - * Peeks a substring from the current cursor. - * @param length The length of the substring. Defaults to 1 - * @param offset The index to offset from cursor. Defaults to 0 - */ - peek(length = 1, offset = 0) { - return this.string.slice(this.innerCursor + offset, this.innerCursor + offset + length); - } - canRead(length = 1) { - const needed = this.innerCursor + length; - const available = this.string.length; - return this.innerCursor + length <= this.string.length; - } - canReadInLine() { - return this.canRead() && this.peek() !== CR && this.peek() !== LF; - } - /** - * If the `expectedValue` is right after the cursor, returns `true`. Otherwise returns `false`. - * - * @param offset Defaults to 0. - * - * @see {@link Source.trySkip} - */ - tryPeek(expectedValue, offset = 0) { - return this.peek(expectedValue.length, offset) === expectedValue; - } - tryPeekAfterWhitespace(expectedValue) { - const maxOffset = this.string.length - this.innerCursor; - let offset = 0; - while (offset < maxOffset && Source.isWhitespace(this.peek(1, offset))) { - offset++; - } - return this.tryPeek(expectedValue, offset); - } - peekUntil(...terminators) { - let ans = ""; - for (let cursor = this.innerCursor; cursor < this.string.length; cursor++) { - const c = this.string.charAt(cursor); - if (terminators.includes(c)) { - return ans; - } else { - ans += c; - } - } - return ans; - } - peekLine() { - return this.peekUntil(CR, LF); - } - peekRemaining(offset = 0) { - return this.string.slice(this.innerCursor + offset); - } - matchPattern(regex, offset = 0) { - return regex.test(this.peekRemaining(offset)); - } - /** - * If there is a non-space character between `cursor + offset` (inclusive) and the next newline, returns `true`. Otherwise returns `false`. - * - * @param offset Defaults to 0. - */ - hasNonSpaceAheadInLine(offset = 0) { - for (let cursor = this.innerCursor + offset; cursor < this.string.length; cursor++) { - const c = this.string.charAt(cursor); - if (Source.isNewline(c)) { - break; - } - if (!Source.isSpace(c)) { - return true; - } - } - return false; - } - slice(param0, end) { - if (typeof param0 === "number") { - const innerStart = IndexMap.toInnerOffset(this.indexMap, param0); - const innerEnd = end !== void 0 ? IndexMap.toInnerOffset(this.indexMap, end) : void 0; - return this.string.slice(innerStart, innerEnd); - } - const range3 = IndexMap.toInnerRange(this.indexMap, Range.get(param0)); - return this.string.slice(range3.start, range3.end); - } - sliceToCursor(start) { - const innerStart = IndexMap.toInnerOffset(this.indexMap, start); - return this.string.slice(innerStart, this.innerCursor); - } -}; -var Source = class _Source extends ReadonlySource { - string; - indexMap; - constructor(string11, indexMap = []) { - super(string11, indexMap); - this.string = string11; - this.indexMap = indexMap; - } - get cursor() { - return super.cursor; - } - set cursor(cursor) { - this.innerCursor = IndexMap.toInnerOffset(this.indexMap, cursor); - } - clone() { - const ans = new _Source(this.string, this.indexMap); - ans.innerCursor = this.innerCursor; - return ans; - } - read() { - return this.string.charAt(this.innerCursor++); - } - /** - * Skips the current character. - * @param step The step to skip. Defaults to 1 - */ - skip(step = 1) { - this.innerCursor += step; - return this; - } - /** - * If the `expectedValue` is right after the cursor, skips it and returns `true`. Otherwise returns `false`. - * - * This is a shortcut for the following piece of code: - * ```typescript - * declare const src: Source - * if (src.peek(expectedValue.length) === expectedValue) { - * src.skip(expectedValue.length) - * // Do something here. - * } - * ``` - * - * @see {@link Source.tryPeek} - */ - trySkip(expectedValue) { - if (this.peek(expectedValue.length) === expectedValue) { - this.skip(expectedValue.length); - return true; - } - return false; - } - /** - * Reads until the end of this line. - */ - readLine() { - return this.readUntil(CR, LF); - } - /** - * Skips until the end of this line. - */ - skipLine() { - this.readLine(); - return this; - } - /** - * Jumps to the beginning of the next line. - */ - nextLine() { - this.skipLine(); - if (this.peek(2) === CRLF) { - this.skip(2); - } else if (this.peek() === CR || this.peek() === LF) { - this.skip(); - } - return this; - } - readSpace() { - const start = this.innerCursor; - this.skipSpace(); - return this.string.slice(start, this.innerCursor); - } - skipSpace() { - while (this.canRead() && _Source.isSpace(this.peek())) { - this.skip(); - } - return this; - } - readWhitespace() { - const start = this.innerCursor; - this.skipWhitespace(); - return this.string.slice(start, this.innerCursor); - } - skipWhitespace() { - while (this.canRead() && _Source.isWhitespace(this.peek())) { - this.skip(); - } - return this; - } - readIf(predicate) { - let ans = ""; - while (this.canRead()) { - const c = this.peek(); - if (predicate(c)) { - this.skip(); - ans += c; - } else { - break; - } - } - return ans; - } - skipIf(predicate) { - this.readIf(predicate); - return this; - } - /** - * @param terminators Ending character. Will not be skipped or included in the result. - */ - readUntil(...terminators) { - let ans = ""; - while (this.canRead()) { - const c = this.peek(); - if (terminators.includes(c)) { - return ans; - } else { - ans += c; - } - this.skip(); - } - return ans; - } - /** - * @param terminators Ending character. Will not be skipped. - */ - skipUntilOrEnd(...terminators) { - this.readUntil(...terminators); - return this; - } - readUntilLineEnd() { - return this.readUntil(CR, LF); - } - skipUntilLineEnd() { - return this.skipUntilOrEnd(CR, LF); - } - readRemaining() { - const start = this.innerCursor; - this.innerCursor = this.string.length; - return this.string.slice(start); - } - skipRemaining() { - this.readRemaining(); - return this; - } -}; -(function(Source2) { - function isDigit(c) { - return c >= "0" && c <= "9"; - } - Source2.isDigit = isDigit; - function isBrigadierQuote(c) { - return c === '"' || c === "'"; - } - Source2.isBrigadierQuote = isBrigadierQuote; - function isNewline(c) { - return c === "\r\n" || c === "\r" || c === "\n"; - } - Source2.isNewline = isNewline; - function isSpace(c) { - return c === " " || c === " "; - } - Source2.isSpace = isSpace; - function isWhitespace(c) { - return Source2.isSpace(c) || Source2.isNewline(c); - } - Source2.isWhitespace = isWhitespace; -})(Source || (Source = {})); - -// node_modules/@spyglassmc/core/lib/source/Offset.js -var Offset; -(function(Offset2) { - function get(offset) { - if (typeof offset === "function") { - offset = offset(); - } - if (offset instanceof ReadonlySource) { - offset = offset.cursor; - } - return offset; - } - Offset2.get = get; -})(Offset || (Offset = {})); - -// node_modules/@spyglassmc/core/lib/source/Range.js -var Range; -(function(Range2) { - function get(range3) { - const evaluated = typeof range3 === "function" ? range3() : range3; - if (Range2.is(evaluated)) { - return Range2.create(evaluated.start, evaluated.end); - } - if (RangeContainer.is(evaluated)) { - return Range2.create(evaluated.range.start, evaluated.range.end); - } - return Range2.create(evaluated); - } - Range2.get = get; - function create(start, end) { - start = Offset.get(start); - return { start, end: end !== void 0 ? Offset.get(end) : start }; - } - Range2.create = create; - function span(from, to) { - return { start: Range2.get(from).start, end: Range2.get(to).end }; - } - Range2.span = span; - function is(obj) { - return !!obj && typeof obj === "object" && typeof obj.start === "number" && typeof obj.end === "number"; - } - Range2.is = is; - Range2.Beginning = Object.freeze(Range2.create(0, 1)); - Range2.Full = Object.freeze(Range2.create(0, Number.POSITIVE_INFINITY)); - function toString(range3) { - return `[${range3.start}, ${range3.end})`; - } - Range2.toString = toString; - function contains(range3, offset, endInclusive = false) { - range3 = get(range3); - return range3.start <= offset && (endInclusive ? offset <= range3.end : offset < range3.end); - } - Range2.contains = contains; - function containsRange(a, b, endInclusive = false) { - a = get(a); - b = get(b); - return contains(a, b.start, endInclusive) && contains(a, b.end, true); - } - Range2.containsRange = containsRange; - function intersects(a, b) { - return Range2.contains(a, b.start) || Range2.contains(b, a.start); - } - Range2.intersects = intersects; - function equals(a, b) { - return a.start === b.start && a.end === b.end; - } - Range2.equals = equals; - function endsBefore(range3, target, endInclusive = false) { - return endInclusive ? range3.end < Range2.get(target).start : range3.end <= Range2.get(target).start; - } - Range2.endsBefore = endsBefore; - function isEmpty(range3) { - range3 = get(range3); - return range3.start === range3.end; - } - Range2.isEmpty = isEmpty; - function length(range3) { - return range3.end - range3.start; - } - Range2.length = length; - function compare(a, b, endInclusive = false) { - if (endInclusive ? a.end < b.start : a.end <= b.start) { - return -1; - } else if (endInclusive ? a.start > b.end : a.start >= b.end) { - return 1; - } else { - return 0; - } - } - Range2.compare = compare; - function compareOffset(range3, offset, endInclusive = false) { - if (endInclusive ? range3.end < offset : range3.end <= offset) { - return -1; - } else if (range3.start > offset) { - return 1; - } else { - return 0; - } - } - Range2.compareOffset = compareOffset; - function translate(range3, startOffset, endOffset = startOffset) { - range3 = get(range3); - return { start: range3.start + startOffset, end: range3.end + endOffset }; - } - Range2.translate = translate; -})(Range || (Range = {})); -var RangeContainer; -(function(RangeContainer2) { - function is(obj) { - return !!obj && typeof obj === "object" && Range.is(obj.range); - } - RangeContainer2.is = is; -})(RangeContainer || (RangeContainer = {})); - -// node_modules/@spyglassmc/core/lib/source/IndexMap.js -var IndexMap; -(function(IndexMap2) { - function convertOffset(map3, offset, from, to) { - let ans = offset; - for (const pair of map3) { - if (Range.contains(pair[from], offset)) { - return pair[to].start; - } else if (Range.endsBefore(pair[from], offset)) { - ans = offset - pair[from].end + pair[to].end; - } else { - break; - } - } - return ans; - } - function toInnerOffset(map3, offset) { - return convertOffset(map3, offset, "outer", "inner"); - } - IndexMap2.toInnerOffset = toInnerOffset; - function toInnerRange(map3, outer) { - return Range.create(toInnerOffset(map3, outer.start), toInnerOffset(map3, outer.end)); - } - IndexMap2.toInnerRange = toInnerRange; - function toOuterOffset(map3, offset) { - return convertOffset(map3, offset, "inner", "outer"); - } - IndexMap2.toOuterOffset = toOuterOffset; - function toOuterRange(map3, inner) { - return Range.create(toOuterOffset(map3, inner.start), toOuterOffset(map3, inner.end)); - } - IndexMap2.toOuterRange = toOuterRange; -})(IndexMap || (IndexMap = {})); - -// node_modules/@spyglassmc/core/lib/source/Position.js -var Position; -(function(Position2) { - function create(param1, param2) { - if (typeof param1 === "object") { - return _createFromPartial(param1); - } else { - return _createFromNumbers(param1, param2); - } - } - Position2.create = create; - function _createFromPartial(partial) { - return { line: partial.line ?? 0, character: partial.character ?? 0 }; - } - function _createFromNumbers(line, character) { - return _createFromPartial({ line, character }); - } - Position2.Beginning = Position2.create(0, 0); - Position2.Infinity = Position2.create(Number.POSITIVE_INFINITY, Number.POSITIVE_INFINITY); - function toString(pos) { - return `<${pos.line}, ${pos.character}>`; - } - Position2.toString = toString; - function isBefore(pos1, pos2) { - return pos1.line < pos2.line || pos1.line === pos2.line && pos1.character < pos2.character; - } - Position2.isBefore = isBefore; -})(Position || (Position = {})); - -// node_modules/@spyglassmc/core/lib/source/PositionRange.js -var PositionRange; -(function(PositionRange2) { - function create(param1, param2, param3, param4) { - if (typeof param1 === "number") { - return { - start: Position.create(param1, param2), - end: Position.create(param3, param4) - }; - } else if (param2 !== void 0) { - return { - start: Position.create(param1), - end: Position.create(param2) - }; - } else { - const partial = param1; - return { - start: Position.create(partial.start ?? {}), - end: Position.create(partial.end ?? {}) - }; - } - } - PositionRange2.create = create; - function from(rangeLike, doc) { - const range3 = Range.get(rangeLike); - const ans = { - start: doc.positionAt(range3.start), - end: doc.positionAt(range3.end) - }; - return ans; - } - PositionRange2.from = from; - PositionRange2.Beginning = Object.freeze(PositionRange2.create(0, 0, 0, 1)); - PositionRange2.Full = Object.freeze(PositionRange2.create(Position.Beginning, Position.Infinity)); - function toString(range3) { - return `[${Position.toString(range3.start)}, ${Position.toString(range3.end)})`; - } - PositionRange2.toString = toString; - function contains(range3, pos) { - const { start, end } = range3; - if (pos.line < start.line || pos.line > end.line) { - return false; - } - if (start.line < pos.line && pos.line < end.line) { - return true; - } - return (pos.line === start.line ? pos.character >= start.character : true) && (pos.line === end.line ? pos.character < end.character : true); - } - PositionRange2.contains = contains; - function endsBefore(range3, pos) { - return Position.isBefore(Position.create(range3.end.line, range3.end.character - 1), pos); - } - PositionRange2.endsBefore = endsBefore; -})(PositionRange || (PositionRange = {})); - -// node_modules/@spyglassmc/core/lib/source/LanguageError.js -var LanguageError; -(function(LanguageError2) { - function create(message2, range3, severity = ErrorSeverity.Error, info, source) { - const ans = { range: range3, message: message2, severity }; - if (info) { - ans.info = info; - } - if (source) { - ans.source = source; - } - return ans; - } - LanguageError2.create = create; - function withPosRange(error4, doc) { - return { - posRange: PositionRange.from(error4.range, doc), - message: error4.message, - severity: error4.severity, - ...error4.info && { info: error4.info }, - ...error4.source && { source: error4.source } - }; - } - LanguageError2.withPosRange = withPosRange; -})(LanguageError || (LanguageError = {})); -var ErrorSeverity; -(function(ErrorSeverity2) { - ErrorSeverity2[ErrorSeverity2["Hint"] = 0] = "Hint"; - ErrorSeverity2[ErrorSeverity2["Information"] = 1] = "Information"; - ErrorSeverity2[ErrorSeverity2["Warning"] = 2] = "Warning"; - ErrorSeverity2[ErrorSeverity2["Error"] = 3] = "Error"; -})(ErrorSeverity || (ErrorSeverity = {})); - -// node_modules/@spyglassmc/core/lib/source/Location.js -var Location; -(function(Location2) { - function get(partial) { - return { - uri: partial.uri ?? "", - range: Range.get(partial.range ?? { start: 0, end: 0 }), - posRange: partial.posRange ?? { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } } - }; - } - Location2.get = get; - function create(doc, range3) { - return Location2.get({ uri: doc.uri, range: range3, posRange: PositionRange.from(range3, doc) }); - } - Location2.create = create; -})(Location || (Location = {})); - -// node_modules/@spyglassmc/core/lib/node/AstNode.js -var AstNode; -(function(AstNode2) { - function is(obj) { - return !!obj && typeof obj === "object" && typeof obj.type === "string" && Range.is(obj.range); - } - AstNode2.is = is; - function setParents(node) { - for (const child of node.children ?? []) { - child.parent = node; - setParents(child); - } - } - AstNode2.setParents = setParents; - function findChildIndex(node, needle, endInclusive = false) { - if (!node.children) { - return -1; - } - const comparator = typeof needle === "number" ? Range.compareOffset : Range.compare; - return (0, import_binary_search2.default)(node.children, needle, (a, b) => comparator(a.range, b, endInclusive)); - } - AstNode2.findChildIndex = findChildIndex; - function findChild(node, needle, endInclusive = false) { - return node.children?.[findChildIndex(node, needle, endInclusive)]; - } - AstNode2.findChild = findChild; - function findLastChildIndex(node, needle, endInclusive = false) { - if (!node.children) { - return -1; - } - let ans = -1; - for (const [i, childNode] of node.children.entries()) { - if (Range.endsBefore(childNode.range, needle, endInclusive)) { - ans = i; - } else { - break; - } - } - return ans; - } - AstNode2.findLastChildIndex = findLastChildIndex; - function findLastChild(node, needle, endInclusive = false) { - return node.children?.[findLastChildIndex(node, needle, endInclusive)]; - } - AstNode2.findLastChild = findLastChild; - function findDeepestChild({ node, needle, endInclusive = false, predicate = () => true }) { - let last; - let head = Range.contains(node, needle, endInclusive) ? node : void 0; - while (head && predicate(head)) { - last = head; - head = findChild(head, needle, endInclusive); - } - return last; - } - AstNode2.findDeepestChild = findDeepestChild; - function findShallowestChild({ node, needle, endInclusive = false, predicate = () => true }) { - let head = Range.contains(node, needle, endInclusive) ? node : void 0; - while (head && !predicate(head)) { - head = findChild(head, needle, endInclusive); - } - return head; - } - AstNode2.findShallowestChild = findShallowestChild; - function* getLocalsToRoot(node) { - let head = node; - while (head) { - if (head.locals) { - yield head.locals; - } - head = node.parent; - } - } - AstNode2.getLocalsToRoot = getLocalsToRoot; - function* getLocalsToLeaves(node) { - if (node.locals) { - yield node.locals; - } - for (const child of node.children ?? []) { - yield* getLocalsToLeaves(child); - } - } - AstNode2.getLocalsToLeaves = getLocalsToLeaves; -})(AstNode || (AstNode = {})); - -// node_modules/@spyglassmc/core/lib/node/BooleanNode.js -var BooleanNode; -(function(BooleanNode2) { - function is(obj) { - return obj.type === "boolean"; - } - BooleanNode2.is = is; - function mock(range3) { - return { type: "boolean", range: Range.get(range3) }; - } - BooleanNode2.mock = mock; -})(BooleanNode || (BooleanNode = {})); - -// node_modules/@spyglassmc/core/lib/node/CommentNode.js -var CommentNode; -(function(CommentNode2) { - function is(obj) { - return obj?.type === "comment"; - } - CommentNode2.is = is; -})(CommentNode || (CommentNode = {})); - -// node_modules/@spyglassmc/core/lib/node/ErrorNode.js -var ErrorNode; -(function(ErrorNode2) { - function is(obj) { - return obj.type === "error"; - } - ErrorNode2.is = is; -})(ErrorNode || (ErrorNode = {})); - -// node_modules/@spyglassmc/core/lib/node/FileNode.js -var FileNode; -(function(FileNode2) { - function getErrors(node) { - return [ - ...node.parserErrors, - ...node.binderErrors ?? [], - ...node.checkerErrors ?? [], - ...node.linterErrors ?? [] - ]; - } - FileNode2.getErrors = getErrors; -})(FileNode || (FileNode = {})); - -// node_modules/@spyglassmc/core/lib/node/FloatNode.js -var FloatNode; -(function(FloatNode2) { - function is(obj) { - return obj.type === "float"; - } - FloatNode2.is = is; - function mock(range3) { - return { type: "float", range: Range.get(range3), value: 0 }; - } - FloatNode2.mock = mock; -})(FloatNode || (FloatNode = {})); - -// node_modules/@spyglassmc/core/lib/node/IntegerNode.js -var IntegerNode; -(function(IntegerNode2) { - function is(obj) { - return obj.type === "integer"; - } - IntegerNode2.is = is; - function mock(range3) { - return { type: "integer", range: Range.get(range3), value: 0 }; - } - IntegerNode2.mock = mock; -})(IntegerNode || (IntegerNode = {})); - -// node_modules/@spyglassmc/core/lib/node/ListNode.js -var ItemNode; -(function(ItemNode2) { - function is(node) { - return node?.type === "item"; - } - ItemNode2.is = is; -})(ItemNode || (ItemNode = {})); - -// node_modules/@spyglassmc/core/lib/node/LiteralNode.js -var LiteralNode; -(function(LiteralNode3) { - function is(obj) { - return obj?.type === "literal"; - } - LiteralNode3.is = is; - function mock(range3, options2) { - return { type: "literal", range: Range.get(range3), options: options2, value: "" }; - } - LiteralNode3.mock = mock; -})(LiteralNode || (LiteralNode = {})); - -// node_modules/@spyglassmc/core/lib/node/LongNode.js -var LongNode; -(function(LongNode2) { - function is(obj) { - return obj.type === "long"; - } - LongNode2.is = is; - function mock(range3) { - return { type: "long", range: Range.get(range3), value: 0n }; - } - LongNode2.mock = mock; -})(LongNode || (LongNode = {})); - -// node_modules/@spyglassmc/core/lib/node/PrefixedNode.js -var PrefixedNode; -(function(PrefixedNode2) { - function is(obj) { - return obj.type === "prefixed"; - } - PrefixedNode2.is = is; - function mock(range3, prefix, child) { - return { - type: "prefixed", - range: Range.get(range3), - prefix, - children: [ - LiteralNode.mock(range3, { pool: [prefix] }), - child - ] - }; - } - PrefixedNode2.mock = mock; -})(PrefixedNode || (PrefixedNode = {})); - -// node_modules/@spyglassmc/core/lib/node/RecordNode.js -var PairNode; -(function(PairNode2) { - function is(node) { - return node?.type === "pair"; - } - PairNode2.is = is; -})(PairNode || (PairNode = {})); - -// node_modules/@spyglassmc/core/lib/node/ResourceLocationNode.js -var ResourceLocationNode; -(function(ResourceLocationNode2) { - const TagPrefix = ResourceLocation.TagPrefix; - const NamespacePathSep = ResourceLocation.NamespacePathSep; - const PathSep = ResourceLocation.PathSep; - const DefaultNamespace = ResourceLocation.DefaultNamespace; - function is(obj) { - return obj?.type === "resource_location"; - } - ResourceLocationNode2.is = is; - function mock(range3, options2) { - return { type: "resource_location", range: Range.get(range3), options: options2 }; - } - ResourceLocationNode2.mock = mock; - function toString(node, type2 = "origin", includesTagPrefix = false) { - const path6 = node.path ? node.path.join(PathSep) : ""; - let id; - switch (type2) { - case "origin": - id = node.namespace !== void 0 ? `${node.namespace}${NamespacePathSep}${path6}` : path6; - break; - case "full": - id = `${node.namespace || DefaultNamespace}${NamespacePathSep}${path6}`; - break; - case "short": - id = node.namespace && node.namespace !== DefaultNamespace ? `${node.namespace}${NamespacePathSep}${path6}` : path6; - break; - } - return includesTagPrefix && node.isTag ? `${TagPrefix}${id}` : id; - } - ResourceLocationNode2.toString = toString; -})(ResourceLocationNode || (ResourceLocationNode = {})); - -// node_modules/@spyglassmc/core/lib/node/Sequence.js -var SequenceUtilDiscriminator = Symbol("SequenceUtilDiscriminator"); -var SequenceUtil; -(function(SequenceUtil2) { - function is(obj) { - return !!obj && obj[SequenceUtilDiscriminator]; - } - SequenceUtil2.is = is; -})(SequenceUtil || (SequenceUtil = {})); - -// node_modules/@spyglassmc/core/lib/node/StringNode.js -var EscapeChar; -(function(EscapeChar2) { - function is(expected, c) { - return expected ? expected.includes(c) : false; - } - EscapeChar2.is = is; -})(EscapeChar || (EscapeChar = {})); -var EscapeTable = /* @__PURE__ */ new Map([ - ['"', '"'], - ["'", "'"], - ["\\", "\\"], - ["b", "\b"], - ["f", "\f"], - ["n", "\n"], - ["r", "\r"], - ["s", " "], - ["t", " "] -]); -var StringBaseNode; -(function(StringBaseNode2) { - function is(obj) { - return Array.isArray(obj?.valueMap) && typeof obj?.options === "object"; - } - StringBaseNode2.is = is; -})(StringBaseNode || (StringBaseNode = {})); -var StringNode; -(function(StringNode2) { - function is(obj) { - return obj?.type === "string"; - } - StringNode2.is = is; - function mock(range3, options2) { - range3 = Range.get(range3); - return { - type: "string", - range: range3, - options: options2, - value: "", - valueMap: [{ inner: Range.create(0), outer: Range.create(range3.start) }] - }; - } - StringNode2.mock = mock; -})(StringNode || (StringNode = {})); - -// node_modules/@spyglassmc/core/lib/node/SymbolNode.js -var SymbolNode; -(function(SymbolNode2) { - function is(obj) { - return obj?.type === "symbol"; - } - SymbolNode2.is = is; - function mock(range3, options2) { - return { type: "symbol", range: Range.get(range3), options: options2, value: "" }; - } - SymbolNode2.mock = mock; -})(SymbolNode || (SymbolNode = {})); - -// node_modules/@spyglassmc/locales/lib/index.js -init_en(); - -// import("./locales/**/*.json") in node_modules/@spyglassmc/locales/lib/index.js -var globImport_locales_json = __glob({ - "./locales/de.json": () => Promise.resolve().then(() => (init_de(), de_exports)), - "./locales/en.json": () => Promise.resolve().then(() => (init_en(), en_exports)), - "./locales/es.json": () => Promise.resolve().then(() => (init_es(), es_exports)), - "./locales/fr.json": () => Promise.resolve().then(() => (init_fr(), fr_exports)), - "./locales/it.json": () => Promise.resolve().then(() => (init_it(), it_exports)), - "./locales/ja.json": () => Promise.resolve().then(() => (init_ja(), ja_exports)), - "./locales/pt-br.json": () => Promise.resolve().then(() => (init_pt_br(), pt_br_exports)), - "./locales/zh-cn.json": () => Promise.resolve().then(() => (init_zh_cn(), zh_cn_exports)), - "./locales/zh-tw.json": () => Promise.resolve().then(() => (init_zh_tw(), zh_tw_exports)) -}); - -// node_modules/@spyglassmc/locales/lib/index.js -var Locales = { en: en_default }; -var language = "en"; -function localize(key2, ...params) { - const value = Locales[language][key2] ?? Locales.en[key2]; - return _resolveLocalePlaceholders(value, params) ?? key2; -} -function localeQuote(content) { - return localize("punc.quote", content); -} -function _resolveLocalePlaceholders(val, params) { - return val?.replace(/%\d+%/g, (match) => { - const index4 = parseInt(match.slice(1, -1)); - let param = params[index4]; - if (typeof param !== "string" && param?.[Symbol.iterator]) { - param = arrayToMessage(param); - } - return `${param ?? match}`; - }); -} -function arrayToMessage(param, quoted = true, conjunction = "or") { - const getPart = (str) => quoted ? localeQuote(str) : str; - const arr = (typeof param === "string" ? [param] : Array.from(param)).map(getPart); - switch (arr.length) { - case 0: - return localize("nothing"); - case 1: - return arr[0]; - case 2: - return arr[0] + localize(`conjunction.${conjunction}_2`) + arr[1]; - default: - return `${arr.slice(0, -1).join(localize(`conjunction.${conjunction}_3+_1`))}${localize(`conjunction.${conjunction}_3+_2`)}${arr[arr.length - 1]}`; - } -} - -// node_modules/@spyglassmc/core/lib/parser/literal.js -function literal(...param) { - const options2 = getOptions(param); - return (src, ctx) => { - const ans = { type: "literal", range: Range.create(src), options: options2, value: "" }; - for (const expected of options2.pool) { - if (src.trySkip(expected)) { - ans.value = expected; - ans.range.end = src.cursor; - return ans; - } - } - ctx.err.report(localize("expected", options2.pool), ans); - return ans; - }; -} -function getOptions(param) { - let ans; - if (typeof param[0] === "object") { - ans = param[0]; - } else { - ans = { pool: param }; - } - ans.pool = ans.pool.sort((a, b) => b.length - a.length); - return ans; -} - -// node_modules/@spyglassmc/core/lib/symbol/Symbol.js -var import_rfdc2 = __toESM(require_rfdc(), 1); -var McdocCategories = Object.freeze(["mcdoc", "mcdoc/dispatcher"]); -var RegistryCategories = Object.freeze([ - "activity", - "armor_material", - // Removed - "attribute", - "attribute_type", - "block", - "block_entity_type", - "block_predicate_type", - "block_type", - "chunk_status", - "command_argument_type", - "consume_effect_type", - "creative_mode_tab", - "custom_stat", - "data_component_predicate_type", - "data_component_type", - "debug_subscription", - "decorated_pot_pattern", - "decorated_pot_patterns", - // Removed - "dialog_action_type", - "dialog_body_type", - "dialog_type", - "enchantment_effect_component_type", - "enchantment_entity_effect_type", - "enchantment_level_based_value_type", - "enchantment_location_based_effect_type", - "enchantment_provider_type", - "enchantment_value_effect_type", - "entity_sub_predicate_type", - "entity_type", - "environment_attribute", - "float_provider_type", - "fluid", - "game_event", - "game_rule", - "height_provider_type", - "incoming_rpc_methods", - "input_control_type", - "instrument", - "int_provider_type", - "item", - "item_sub_predicate_type", - // Removed - "loot_condition_type", - "loot_function_type", - "loot_nbt_provider_type", - "loot_number_provider_type", - "loot_pool_entry_type", - "loot_score_provider_type", - "map_decoration_type", - "memory_module_type", - "menu", - "mob_effect", - "motive", - // Removed - "number_format_type", - "outgoing_rpc_methods", - "particle_type", - "permission_check_type", - "permission_type", - "point_of_interest_type", - "pos_rule_test", - "position_source_type", - "potion", - "recipe_book_category", - "recipe_display", - "recipe_serializer", - "recipe_type", - "rule_block_entity_modifier", - "rule_test", - "schedule", - // Removed - "sensor_type", - "slot_display", - "slot_source_type", - "sound_event", - "spawn_condition_type", - "stat_type", - "test_environment_definition_type", - "test_function", - "test_instance_type", - "trigger_type", - "ticket_type", - "villager_profession", - "villager_type", - "worldgen/biome_source", - "worldgen/block_placer_type", - // Removed - "worldgen/block_state_provider_type", - "worldgen/carver", - "worldgen/chunk_generator", - "worldgen/decorator", - // Removed - "worldgen/density_function_type", - "worldgen/feature", - "worldgen/feature_size_type", - "worldgen/foliage_placer_type", - "worldgen/material_condition", - "worldgen/material_rule", - "worldgen/placement_modifier_type", - "worldgen/pool_alias_binding", - "worldgen/root_placer_type", - "worldgen/structure_feature", - // Removed - "worldgen/structure_piece", - "worldgen/structure_placement", - "worldgen/structure_pool_element", - "worldgen/structure_processor", - "worldgen/structure_type", - "worldgen/surface_builder", - // Removed - "worldgen/tree_decorator_type", - "worldgen/trunk_placer_type" -]); -var NormalFileCategories = Object.freeze([ - "advancement", - "banner_pattern", - "cat_variant", - "chat_type", - "chicken_variant", - "cow_variant", - "damage_type", - "dialog", - "dimension", - "dimension_type", - "enchantment", - "enchantment_provider", - "frog_variant", - "function", - "instrument", - "item_modifier", - "jukebox_song", - "loot_table", - "painting_variant", - "pig_variant", - "predicate", - "recipe", - "structure", - "sulfur_cube_archetype", - "test_environment", - "test_instance", - "timeline", - "trade_set", - "trial_spawner", - "trim_material", - "trim_pattern", - "villager_trade", - "wolf_sound_variant", - "wolf_variant", - "world_clock", - "zombie_nautilus_variant" -]); -var WorldgenFileCategories = Object.freeze([ - "worldgen/biome", - "worldgen/configured_carver", - "worldgen/configured_feature", - "worldgen/configured_structure_feature", - "worldgen/configured_surface_builder", - "worldgen/density_function", - "worldgen/flat_level_generator_preset", - "worldgen/multi_noise_biome_source_parameter_list", - "worldgen/noise", - "worldgen/noise_settings", - "worldgen/placed_feature", - "worldgen/processor_list", - "worldgen/structure", - "worldgen/structure_set", - "worldgen/template_pool", - "worldgen/world_preset" -]); -var TaggableResourceLocationCategories = Object.freeze([...NormalFileCategories, ...RegistryCategories, ...WorldgenFileCategories]); -var TaggableResourceLocationCategory; -(function(TaggableResourceLocationCategory2) { - function is(category) { - return TaggableResourceLocationCategories.includes(category); - } - TaggableResourceLocationCategory2.is = is; -})(TaggableResourceLocationCategory || (TaggableResourceLocationCategory = {})); -var TagFileCategories = Object.freeze(TaggableResourceLocationCategories.map((key2) => `tag/${key2}`)); -var DataFileCategories = Object.freeze([...NormalFileCategories, ...TagFileCategories, ...WorldgenFileCategories]); -var DataMiscCategories = Object.freeze([ - "attribute_modifier", - "bossbar", - "jigsaw_block_name", - "random_sequence", - "storage", - "stopwatch" -]); -var DatapackCategories = Object.freeze([ - "attribute_modifier_uuid", - "objective", - "player_uuid", - "score_holder", - "tag", - "team", - ...DataFileCategories, - ...DataMiscCategories -]); -var AssetsFileCategories = Object.freeze([ - "atlas", - "block_definition", - // blockstates - "equipment", - "font", - "font/ttf", - "font/otf", - "font/unihex", - "gpu_warnlist", - "item_definition", - // items - "lang", - "lang/deprecated", - "model", - "particle", - "post_effect", - "regional_compliancies", - "shader", - "shader/fragment", - "shader/vertex", - "sound", - "sounds", - // sounds.json - "texture", - "texture_meta", - // *.png.mcmeta - "waypoint_style" -]); -var AssetsMiscCategories = Object.freeze([ - "texture_slot", - "shader_target", - "translation_key" -]); -var ResourcepackCategories = Object.freeze([ - ...AssetsMiscCategories, - ...AssetsFileCategories -]); -var FileCategories = Object.freeze([...DataFileCategories, ...AssetsFileCategories]); -var AllCategories = Object.freeze([ - ...DatapackCategories, - ...ResourcepackCategories, - ...McdocCategories, - ...RegistryCategories -]); -var ResourceLocationCategories = Object.freeze([ - "mcdoc/dispatcher", - ...DataMiscCategories, - ...AssetsMiscCategories, - ...FileCategories, - ...RegistryCategories -]); -var ResourceLocationCategory; -(function(ResourceLocationCategory2) { - function is(category) { - return ResourceLocationCategories.includes(category); - } - ResourceLocationCategory2.is = is; -})(ResourceLocationCategory || (ResourceLocationCategory = {})); -var SymbolPath; -(function(SymbolPath2) { - function fromSymbol(symbol7) { - return symbol7 ? { category: symbol7.category, path: symbol7.path } : void 0; - } - SymbolPath2.fromSymbol = fromSymbol; - function toString(path6) { - return JSON.stringify({ category: path6.category, path: path6.path }); - } - SymbolPath2.toString = toString; - function fromString(value) { - return JSON.parse(value); - } - SymbolPath2.fromString = fromString; -})(SymbolPath || (SymbolPath = {})); -var SymbolUsageTypes = Object.freeze(["definition", "declaration", "implementation", "reference", "typeDefinition"]); -var SymbolUsageType; -(function(SymbolUsageType2) { - function is(value) { - return SymbolUsageTypes.includes(value); - } - SymbolUsageType2.is = is; -})(SymbolUsageType || (SymbolUsageType = {})); -var Symbol2; -(function(Symbol3) { - function get(table, category, ...path6) { - if (isIterable(table)) { - for (const t of table) { - const result = get(t, category, ...path6); - if (result) { - return result; - } - } - return void 0; - } - const map3 = table[category]; - for (const p of path6) { - } - return void 0; - } - Symbol3.get = get; -})(Symbol2 || (Symbol2 = {})); -var SymbolLocation; -(function(SymbolLocation2) { - function create(doc, range3, fullRange, contributor, additional) { - return { - ...Location.create(doc, range3), - ...fullRange ? { fullRange: Range.get(fullRange), fullPosRange: PositionRange.from(fullRange, doc) } : {}, - ...contributor ? { contributor } : {}, - ...additional ? additional : {} - }; - } - SymbolLocation2.create = create; -})(SymbolLocation || (SymbolLocation = {})); -var SymbolTable; -(function(SymbolTable2) { - function link(table) { - const linkSymbol = (symbol7, parentMap, parentSymbol, category, path6) => { - symbol7.category = category; - symbol7.identifier = path6[path6.length - 1]; - symbol7.path = path6; - symbol7.parentMap = parentMap; - if (parentSymbol) { - symbol7.parentSymbol = parentSymbol; - } - if (symbol7.members) { - linkSymbolMap(symbol7.members, symbol7, category, path6); - } - }; - const linkSymbolMap = (map3, parentSymbol, category, path6) => { - for (const [identifier4, childSymbol] of Object.entries(map3)) { - linkSymbol(childSymbol, map3, parentSymbol, category, [...path6, identifier4]); - } - }; - const ans = (0, import_rfdc2.default)()(table); - for (const [category, map3] of Object.entries(ans)) { - linkSymbolMap(map3, void 0, category, []); - } - return ans; - } - SymbolTable2.link = link; - function unlink(table) { - const unlinkSymbol = (symbol7) => { - delete symbol7.category; - delete symbol7.identifier; - delete symbol7.parentMap; - delete symbol7.parentSymbol; - delete symbol7.path; - if (symbol7.members) { - unlinkSymbolMap(symbol7.members); - } - }; - const unlinkSymbolMap = (map3) => { - for (const childSymbol of Object.values(map3)) { - unlinkSymbol(childSymbol); - } - }; - const ans = (0, import_rfdc2.default)({ circles: true })(table); - for (const map3 of Object.values(ans)) { - unlinkSymbolMap(map3); - } - return ans; - } - SymbolTable2.unlink = unlink; - function serialize(table) { - return JSON.stringify(unlink(table), bigintJsonLosslessReplacer); - } - SymbolTable2.serialize = serialize; - function deserialize(json) { - return link(JSON.parse(json, bigintJsonLosslessReviver)); - } - SymbolTable2.deserialize = deserialize; -})(SymbolTable || (SymbolTable = {})); - -// node_modules/vscode-languageserver-textdocument/lib/esm/main.js -var FullTextDocument = class _FullTextDocument { - constructor(uri, languageId, version, content) { - this._uri = uri; - this._languageId = languageId; - this._version = version; - this._content = content; - this._lineOffsets = void 0; - } - get uri() { - return this._uri; - } - get languageId() { - return this._languageId; - } - get version() { - return this._version; - } - getText(range3) { - if (range3) { - const start = this.offsetAt(range3.start); - const end = this.offsetAt(range3.end); - return this._content.substring(start, end); - } - return this._content; - } - update(changes, version) { - for (const change of changes) { - if (_FullTextDocument.isIncremental(change)) { - const range3 = getWellformedRange(change.range); - const startOffset = this.offsetAt(range3.start); - const endOffset = this.offsetAt(range3.end); - this._content = this._content.substring(0, startOffset) + change.text + this._content.substring(endOffset, this._content.length); - const startLine = Math.max(range3.start.line, 0); - const endLine = Math.max(range3.end.line, 0); - let lineOffsets = this._lineOffsets; - const addedLineOffsets = computeLineOffsets(change.text, false, startOffset); - if (endLine - startLine === addedLineOffsets.length) { - for (let i = 0, len = addedLineOffsets.length; i < len; i++) { - lineOffsets[i + startLine + 1] = addedLineOffsets[i]; - } - } else { - if (addedLineOffsets.length < 1e4) { - lineOffsets.splice(startLine + 1, endLine - startLine, ...addedLineOffsets); - } else { - this._lineOffsets = lineOffsets = lineOffsets.slice(0, startLine + 1).concat(addedLineOffsets, lineOffsets.slice(endLine + 1)); - } - } - const diff = change.text.length - (endOffset - startOffset); - if (diff !== 0) { - for (let i = startLine + 1 + addedLineOffsets.length, len = lineOffsets.length; i < len; i++) { - lineOffsets[i] = lineOffsets[i] + diff; - } - } - } else if (_FullTextDocument.isFull(change)) { - this._content = change.text; - this._lineOffsets = void 0; - } else { - throw new Error("Unknown change event received"); - } - } - this._version = version; - } - getLineOffsets() { - if (this._lineOffsets === void 0) { - this._lineOffsets = computeLineOffsets(this._content, true); - } - return this._lineOffsets; - } - positionAt(offset) { - offset = Math.max(Math.min(offset, this._content.length), 0); - const lineOffsets = this.getLineOffsets(); - let low = 0, high = lineOffsets.length; - if (high === 0) { - return { line: 0, character: offset }; - } - while (low < high) { - const mid = Math.floor((low + high) / 2); - if (lineOffsets[mid] > offset) { - high = mid; - } else { - low = mid + 1; - } - } - const line = low - 1; - offset = this.ensureBeforeEOL(offset, lineOffsets[line]); - return { line, character: offset - lineOffsets[line] }; - } - offsetAt(position) { - const lineOffsets = this.getLineOffsets(); - if (position.line >= lineOffsets.length) { - return this._content.length; - } else if (position.line < 0) { - return 0; - } - const lineOffset = lineOffsets[position.line]; - if (position.character <= 0) { - return lineOffset; - } - const nextLineOffset = position.line + 1 < lineOffsets.length ? lineOffsets[position.line + 1] : this._content.length; - const offset = Math.min(lineOffset + position.character, nextLineOffset); - return this.ensureBeforeEOL(offset, lineOffset); - } - ensureBeforeEOL(offset, lineOffset) { - while (offset > lineOffset && isEOL(this._content.charCodeAt(offset - 1))) { - offset--; - } - return offset; - } - get lineCount() { - return this.getLineOffsets().length; - } - static isIncremental(event) { - const candidate = event; - return candidate !== void 0 && candidate !== null && typeof candidate.text === "string" && candidate.range !== void 0 && (candidate.rangeLength === void 0 || typeof candidate.rangeLength === "number"); - } - static isFull(event) { - const candidate = event; - return candidate !== void 0 && candidate !== null && typeof candidate.text === "string" && candidate.range === void 0 && candidate.rangeLength === void 0; - } -}; -var TextDocument; -(function(TextDocument2) { - function create(uri, languageId, version, content) { - return new FullTextDocument(uri, languageId, version, content); - } - TextDocument2.create = create; - function update(document2, changes, version) { - if (document2 instanceof FullTextDocument) { - document2.update(changes, version); - return document2; - } else { - throw new Error("TextDocument.update: document must be created by TextDocument.create"); - } - } - TextDocument2.update = update; - function applyEdits(document2, edits) { - const text = document2.getText(); - const sortedEdits = mergeSort(edits.map(getWellformedEdit), (a, b) => { - const diff = a.range.start.line - b.range.start.line; - if (diff === 0) { - return a.range.start.character - b.range.start.character; - } - return diff; - }); - let lastModifiedOffset = 0; - const spans = []; - for (const e of sortedEdits) { - const startOffset = document2.offsetAt(e.range.start); - if (startOffset < lastModifiedOffset) { - throw new Error("Overlapping edit"); - } else if (startOffset > lastModifiedOffset) { - spans.push(text.substring(lastModifiedOffset, startOffset)); - } - if (e.newText.length) { - spans.push(e.newText); - } - lastModifiedOffset = document2.offsetAt(e.range.end); - } - spans.push(text.substr(lastModifiedOffset)); - return spans.join(""); - } - TextDocument2.applyEdits = applyEdits; -})(TextDocument || (TextDocument = {})); -function mergeSort(data, compare) { - if (data.length <= 1) { - return data; - } - const p = data.length / 2 | 0; - const left = data.slice(0, p); - const right = data.slice(p); - mergeSort(left, compare); - mergeSort(right, compare); - let leftIdx = 0; - let rightIdx = 0; - let i = 0; - while (leftIdx < left.length && rightIdx < right.length) { - const ret = compare(left[leftIdx], right[rightIdx]); - if (ret <= 0) { - data[i++] = left[leftIdx++]; - } else { - data[i++] = right[rightIdx++]; - } - } - while (leftIdx < left.length) { - data[i++] = left[leftIdx++]; - } - while (rightIdx < right.length) { - data[i++] = right[rightIdx++]; - } - return data; -} -function computeLineOffsets(text, isAtLineStart, textOffset = 0) { - const result = isAtLineStart ? [textOffset] : []; - for (let i = 0; i < text.length; i++) { - const ch = text.charCodeAt(i); - if (isEOL(ch)) { - if (ch === 13 && i + 1 < text.length && text.charCodeAt(i + 1) === 10) { - i++; - } - result.push(textOffset + i + 1); - } - } - return result; -} -function isEOL(char) { - return char === 13 || char === 10; -} -function getWellformedRange(range3) { - const start = range3.start; - const end = range3.end; - if (start.line > end.line || start.line === end.line && start.character > end.character) { - return { start: end, end: start }; - } - return range3; -} -function getWellformedEdit(textEdit) { - const range3 = getWellformedRange(textEdit.range); - if (range3 !== textEdit.range) { - return { newText: textEdit.newText, range: range3 }; - } - return textEdit; -} - -// node_modules/@spyglassmc/core/lib/symbol/SymbolUtil.js -var __decorate = function(decorators, target, key2, desc) { - var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key2) : desc, d; - if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key2, desc); - else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key2, r) : d(target, key2)) || r; - return c > 3 && r && Object.defineProperty(target, key2, r), r; -}; -var SymbolUtil = class _SymbolUtil extends EventDispatcher { - #global; - #trimmableSymbols = /* @__PURE__ */ new Set(); - #cache = /* @__PURE__ */ Object.create(null); - #currentContributor; - /** - * @internal - */ - _delayedOps = []; - /** - * @internal - */ - _inDelayMode; - get global() { - return this.#global; - } - constructor(global2, _currentContributor, _inDelayMode = false) { - super(); - this.#global = global2; - this.#currentContributor = _currentContributor; - this._inDelayMode = _inDelayMode; - this.on("symbolCreated", ({ symbol: symbol7 }) => { - this.#trimmableSymbols.add(SymbolPath.toString(symbol7)); - }).on("symbolRemoved", ({ symbol: symbol7 }) => { - this.#trimmableSymbols.delete(SymbolPath.toString(symbol7)); - }).on("symbolLocationCreated", ({ symbol: symbol7, location }) => { - const cache = this.#cache[location.contributor ?? "undefined"] ??= /* @__PURE__ */ Object.create(null); - const fileSymbols = cache[location.uri] ??= /* @__PURE__ */ new Set(); - const path6 = SymbolPath.toString(symbol7); - fileSymbols.add(path6); - this.#trimmableSymbols.delete(path6); - }).on("symbolLocationRemoved", ({ symbol: symbol7 }) => { - const path6 = SymbolPath.toString(symbol7); - this.#trimmableSymbols.add(path6); - }); - } - /** - * Build the internal cache of the SymbolUtil according to the current global symbol table. - */ - buildCache() { - _SymbolUtil.forEachSymbol(this.global, (symbol7) => { - this.emit("symbolCreated", { symbol: symbol7 }); - _SymbolUtil.forEachLocationOfSymbol(symbol7, ({ type: type2, location }) => { - this.emit("symbolLocationCreated", { symbol: symbol7, type: type2, location }); - }); - }); - } - /** - * @returns A clone of this SymbolUtil that is in delay mode: changes to the symbol table happened in the clone will - * not take effect until the {@link SymbolUtil.applyDelayedEdits} method is called on that clone. - * - * The clone shares the same reference of the global symbol table and symbol stacks, meaning that after - * `applyDelayedEdits` is called, the original SymbolUtil will also be modified. - */ - clone() { - return new _SymbolUtil(this.#global, this.#currentContributor, true); - } - /** - * Apply edits done during the delay mode. - */ - applyDelayedEdits() { - this._delayedOps.forEach((f) => f()); - this._delayedOps = []; - this._inDelayMode = false; - } - contributeAs(contributor, fn) { - const originalValue = this.#currentContributor; - this.#currentContributor = contributor; - try { - fn(); - } finally { - this.#currentContributor = originalValue; - } - return this; - } - async contributeAsAsync(contributor, fn) { - const originalValue = this.#currentContributor; - this.#currentContributor = contributor; - try { - await fn(); - } finally { - this.#currentContributor = originalValue; - } - return this; - } - /** - * @param - * - `contributor` - clear symbol locations contributed by this contributor. Pass in `undefined` - * to select all symbol locations that don't have a contributor. - * - `uri` - clear symbol locations associated with this URI. - * - `predicate` - clear symbol locations matching this predicate - */ - clear({ uri, contributor, predicate = () => true }) { - const getCaches = () => { - if (contributor) { - return this.#cache[contributor] ? [this.#cache[contributor]] : []; - } else { - return Object.values(this.#cache); - } - }; - const getPaths = () => { - const caches = getCaches(); - const sets = uri ? caches.map((cache) => cache[uri] ?? /* @__PURE__ */ new Set()) : caches.map((cache) => Object.values(cache)).flat(); - return sets.map((s) => [...s]).flat().map(SymbolPath.fromString); - }; - const getTables = () => { - return uri ? [this.#global] : [this.#global]; - }; - const paths = getPaths(); - const tables = getTables(); - for (const table of tables) { - for (const path6 of paths) { - const { symbol: symbol7 } = _SymbolUtil.lookupTable(table, path6.category, path6.path); - if (!symbol7) { - continue; - } - this.removeLocationsFromSymbol(symbol7, (data) => (!uri || data.location.uri === uri) && (!contributor || data.location.contributor === contributor) && predicate(data)); - } - this.trim(table); - } - } - lookup(category, path6, node) { - while (node) { - if (node.locals) { - const result = _SymbolUtil.lookupTable(node.locals, category, path6); - if (result.symbol) { - return result; - } - } - node = node.parent; - } - return _SymbolUtil.lookupTable(this.global, category, path6); - } - query(doc, category, ...path6) { - const uri = _SymbolUtil.toUri(doc); - const { parentSymbol, parentMap, symbol: symbol7 } = this.lookup(category, path6, isDocAndNode(doc) ? doc.node : void 0); - const visible = symbol7 ? _SymbolUtil.isVisible(symbol7, uri) : true; - return new SymbolQuery({ - category, - doc, - contributor: this.#currentContributor, - map: visible ? parentMap : void 0, - parentSymbol, - path: path6, - symbol: visible ? symbol7 : void 0, - util: this - }); - } - getVisibleSymbols(category, uri) { - const map3 = this.lookup(category, [], void 0).parentMap ?? void 0; - return _SymbolUtil.filterVisibleSymbols(uri, map3); - } - static toUri(uri) { - if (typeof uri === "string") { - return uri; - } - if (isDocAndNode(uri)) { - return uri.doc.uri; - } - return uri.uri; - } - /** - * @see {@link SymbolUtil.trimMap} - */ - trim(table) { - const trimSymbol = (symbol7) => { - if (!symbol7) { - return; - } - if (_SymbolUtil.isTrimmable(symbol7)) { - delete symbol7.parentMap[symbol7.identifier]; - this.emit("symbolRemoved", { symbol: symbol7 }); - trimSymbol(symbol7.parentSymbol); - } - }; - for (const pathString of this.#trimmableSymbols) { - const path6 = SymbolPath.fromString(pathString); - const { symbol: symbol7 } = _SymbolUtil.lookupTable(table, path6.category, path6.path); - trimSymbol(symbol7); - } - } - removeLocationsFromSymbol(symbol7, predicate) { - for (const type2 of SymbolUsageTypes) { - if (!symbol7[type2]) { - continue; - } - symbol7[type2] = symbol7[type2].reduce((result, location) => { - if (predicate({ location, symbol: symbol7, type: type2 })) { - this.emit("symbolLocationRemoved", { symbol: symbol7, type: type2, location }); - } else { - result.push(location); - } - return result; - }, []); - } - } - enterMap(parentSymbol, map3, category, path6, identifier4, addition, doc, contributor) { - let ans = map3[identifier4]; - if (ans) { - this.amendSymbol(ans, addition, doc, contributor); - } else { - ans = this.createSymbol(category, parentSymbol, map3, path6, identifier4, addition, doc, contributor); - } - this.emit("symbolAmended", { symbol: ans }); - return ans; - } - static lookupTable(table, category, path6) { - let parentMap = table[category]; - let parentSymbol; - let symbol7; - for (let i = 0; i < path6.length; i++) { - symbol7 = parentMap?.[path6[i]]; - if (!symbol7) { - if (i !== path6.length - 1) { - parentSymbol = void 0; - parentMap = void 0; - } - break; - } - if (i === path6.length - 1) { - break; - } - parentSymbol = symbol7; - parentMap = symbol7.members; - } - return { parentSymbol, parentMap, symbol: symbol7 }; - } - static lookupTables(tables, category, path6) { - let parentMap; - let parentSymbol; - for (let i = tables.length - 1; i >= 0; i--) { - const table = tables[i]; - const result = this.lookupTable(table, category, path6); - if (result.symbol) { - return result; - } - if (!parentSymbol && !parentMap && (result.parentSymbol || result.parentMap)) { - parentSymbol = result.parentSymbol; - parentMap = result.parentMap; - } - } - return { parentSymbol, parentMap, symbol: void 0 }; - } - createSymbol(category, parentSymbol, parentMap, path6, identifier4, addition, doc, contributor) { - const ans = parentMap[identifier4] = { - category, - identifier: identifier4, - ...parentSymbol ? { parentSymbol } : {}, - parentMap, - path: path6, - ...addition.data - }; - this.emit("symbolCreated", { symbol: ans }); - this.amendSymbolUsage(ans, addition.usage, doc, contributor); - return ans; - } - amendSymbol(symbol7, addition, doc, contributor) { - this.amendSymbolMetadata(symbol7, addition.data); - this.amendSymbolUsage(symbol7, addition.usage, doc, contributor); - } - amendSymbolMetadata(symbol7, addition) { - if (addition) { - if ("data" in addition) { - symbol7.data = addition.data; - } - if ("desc" in addition) { - symbol7.desc = addition.desc; - } - if (addition.relations && Object.keys(addition.relations).length) { - symbol7.relations ??= {}; - for (const relationship of Object.keys(addition.relations)) { - symbol7.relations[relationship] = addition.relations[relationship]; - } - } - if ("subcategory" in addition) { - symbol7.subcategory = addition.subcategory; - } - if ("visibility" in addition) { - const inGlobalTable = (v) => v === void 0 || v === 2 || v === 3; - if (symbol7.visibility === addition.visibility || inGlobalTable(symbol7.visibility) && inGlobalTable(addition.visibility)) { - symbol7.visibility = addition.visibility; - } else { - throw new Error(`Cannot change visibility from ${symbol7.visibility} to ${addition.visibility}: ${JSON.stringify(SymbolPath.fromSymbol(symbol7))}`); - } - } - if (addition.visibilityRestriction?.length) { - symbol7.visibilityRestriction = (symbol7.visibilityRestriction ?? []).concat(addition.visibilityRestriction); - } - } - } - amendSymbolUsage(symbol7, addition, doc, contributor) { - if (addition) { - const type2 = addition.type ?? "reference"; - const arr = symbol7[type2] ??= []; - const range3 = Range.get((SymbolAdditionUsageWithNode.is(addition) ? addition.node : addition.range) ?? 0); - const location = SymbolLocation.create(doc, range3, addition.fullRange, contributor, { - accessType: addition.accessType, - skipRenaming: addition.skipRenaming - }); - if (!doc.uri.startsWith("file:")) { - delete location.range; - delete location.posRange; - delete location.fullRange; - delete location.fullPosRange; - } - arr.push(location); - this.emit("symbolLocationCreated", { symbol: symbol7, type: type2, location }); - } - } - /** - * @returns The ultimate symbol being pointed by the passed-in `symbol`'s alias. - */ - resolveAlias(symbol7) { - return symbol7?.relations?.aliasOf ? this.resolveAlias(this.lookup(symbol7.relations.aliasOf.category, symbol7.relations.aliasOf.path).symbol) : symbol7; - } - static filterVisibleSymbols(uri, map3 = {}) { - const ans = {}; - for (const [identifier4, symbol7] of Object.entries(map3)) { - if (_SymbolUtil.isVisible(symbol7, uri)) { - ans[identifier4] = symbol7; - } - } - return ans; - } - static isTrimmable(symbol7) { - return !Object.keys(symbol7.members ?? {}).length && !symbol7.declaration?.length && !symbol7.definition?.length && !symbol7.implementation?.length && !symbol7.reference?.length && !symbol7.typeDefinition?.length; - } - static isVisible(symbol7, _uri) { - switch (symbol7.visibility) { - case 3: - return false; - // FIXME: check with workspace root URIs. - case 0: - case 1: - case 2: - default: - return true; - } - } - /** - * @returns If the symbol has declarations or definitions. - */ - static isDeclared(symbol7) { - return !!(symbol7?.declaration?.length || symbol7?.definition?.length); - } - /** - * @returns If the symbol has definitions, or declarations and implementations. - */ - static isDefined(symbol7) { - return !!(symbol7?.definition?.length || symbol7?.definition?.length && symbol7?.implementation?.length); - } - /** - * @returns If the symbol has implementations or definitions. - */ - static isImplemented(symbol7) { - return !!(symbol7?.implementation?.length || symbol7?.definition?.length); - } - /** - * @returns If the symbol has references. - */ - static isReferenced(symbol7) { - return !!symbol7?.reference?.length; - } - /** - * @returns If the symbol has type definitions. - */ - static isTypeDefined(symbol7) { - return !!symbol7?.typeDefinition?.length; - } - /** - * @throws If the symbol does not have any declarations or definitions. - */ - static getDeclaredLocation(symbol7) { - return symbol7.declaration?.[0] ?? symbol7.definition?.[0] ?? (() => { - throw new Error(`Cannot get declared location of ${JSON.stringify(SymbolPath.fromSymbol(symbol7))}`); - })(); - } - static forEachSymbolInMap(map3, fn) { - for (const symbol7 of Object.values(map3)) { - fn(symbol7); - if (symbol7.members) { - this.forEachSymbolInMap(symbol7.members, fn); - } - } - } - static forEachSymbol(table, fn) { - for (const map3 of Object.values(table)) { - this.forEachSymbolInMap(map3, fn); - } - } - static forEachLocationOfSymbol(symbol7, fn) { - for (const type2 of SymbolUsageTypes) { - symbol7[type2]?.forEach((location) => fn({ type: type2, location })); - } - } - static isVisibilityInGlobal(v) { - return v === void 0 || v === 2 || v === 3; - } - static areVisibilitiesCompatible(v1, v2) { - return this.isVisibilityInGlobal(v1) && this.isVisibilityInGlobal(v2) || v1 === 0 && v2 === 0 || v1 === 1 && v2 === 1; - } -}; -__decorate([ - DelayModeSupport() -], SymbolUtil.prototype, "clear", null); -__decorate([ - DelayModeSupport() -], SymbolUtil.prototype, "trim", null); -__decorate([ - DelayModeSupport() -], SymbolUtil.prototype, "removeLocationsFromSymbol", null); -var SymbolAdditionUsageWithRange; -(function(SymbolAdditionUsageWithRange2) { - function is(usage) { - return !!usage?.range; - } - SymbolAdditionUsageWithRange2.is = is; -})(SymbolAdditionUsageWithRange || (SymbolAdditionUsageWithRange = {})); -var SymbolAdditionUsageWithNode; -(function(SymbolAdditionUsageWithNode2) { - function is(usage) { - return !!usage?.node; - } - SymbolAdditionUsageWithNode2.is = is; -})(SymbolAdditionUsageWithNode || (SymbolAdditionUsageWithNode = {})); -var SymbolQuery = class _SymbolQuery { - category; - path; - #doc; - #node; - /** - * If only a string URI (instead of a {@link TextDocument}) is provided when constructing this class. - * - * If this is `true`, {@link SymbolAdditionUsageWithRange.range} is ignored and treated as `[0, 0)` when entering symbols through this class. - */ - #createdWithUri; - #currentContributor; - #hasTriggeredIf = false; - /** - * The map where the queried symbol is stored. `undefined` if the map hasn't been created yet. - */ - #map; - #parentSymbol; - /** - * The queried symbol. `undefined` if the symbol hasn't been created yet. - */ - #symbol; - /** - * The {@link SymbolUtil} where this query was created. - */ - util; - get symbol() { - return this.#symbol; - } - get visibleMembers() { - return SymbolUtil.filterVisibleSymbols(this.#doc.uri, this.path.length === 0 ? this.#map : this.#symbol?.members); - } - constructor({ category, contributor, doc, map: map3, parentSymbol, path: path6, symbol: symbol7, util }) { - this.category = category; - this.path = path6; - if (typeof doc === "string") { - doc = TextDocument.create(doc, "", 0, ""); - this.#createdWithUri = true; - } else if (isDocAndNode(doc)) { - this.#node = doc.node; - doc = doc.doc; - } - this.#doc = doc; - this.#currentContributor = contributor; - this.#map = map3; - this.#parentSymbol = parentSymbol; - this.#symbol = symbol7; - this.util = util; - } - heyGimmeDaSymbol() { - return this.#symbol; - } - getData(predicate) { - const data = this.#symbol?.data; - return predicate(data) ? data : void 0; - } - with(fn) { - fn(this); - return this; - } - if(predicate, fn) { - if (predicate.call(this, this.#symbol, this)) { - fn.call(this, this.#symbol, this); - this.#hasTriggeredIf = true; - } - return this; - } - /** - * Calls `fn` if the queried symbol does not exist. - */ - ifUnknown(fn) { - return this.if((s) => s === void 0, fn); - } - /** - * Calls `fn` if the queried symbol exists (i.e. has any of declarations/definitions/implementations/references/typeDefinitions). - */ - ifKnown(fn) { - return this.if((s) => s !== void 0, fn); - } - /** - * Calls `fn` if the queried symbol has declarations or definitions. - */ - ifDeclared(fn) { - return this.if((s) => SymbolUtil.isDeclared(s), fn); - } - /** - * Calls `fn` if the queried symbol has definitions, or both declarations and implementations. - */ - ifDefined(fn) { - return this.if(SymbolUtil.isDefined, fn); - } - /** - * Calls `fn` if the queried symbol has implementations or definitions. - */ - ifImplemented(fn) { - return this.if(SymbolUtil.isImplemented, fn); - } - /** - * Calls `fn` if the queried symbol has references. - */ - ifReferenced(fn) { - return this.if(SymbolUtil.isReferenced, fn); - } - /** - * Calls `fn` if the queried symbol has type definitions. - */ - ifTypeDefined(fn) { - return this.if(SymbolUtil.isTypeDefined, fn); - } - /** - * Calls `fn` if none of the former `if` conditions are met. - */ - else(fn) { - if (!this.#hasTriggeredIf) { - fn.call(this, this.#symbol, this); - } - return this; - } - /** - * Enters the queried symbol if none of the former `if` conditions are met. - */ - elseEnter(symbol7) { - return this.else(() => this.enter(symbol7)); - } - /** - * Resolves the queried symbol if it is an alias and if none of the former `if` conditions are met. - * - * @throws If the current symbol points to an non-existent symbol. - */ - elseResolveAlias() { - return this.else(() => this.resolveAlias()); - } - _enter(addition) { - const getAdditionVisibility = (addition2) => { - return addition2.data?.visibility ?? this.symbol?.visibility ?? 2; - }; - const getMap = (addition2) => { - const additionVisibility = getAdditionVisibility(addition2); - if (this.#map && SymbolUtil.areVisibilitiesCompatible(additionVisibility, this.#symbol?.visibility)) { - return this.#map; - } - if (this.path.length > 1) { - if (this.#parentSymbol) { - if (!SymbolUtil.areVisibilitiesCompatible(additionVisibility, this.#parentSymbol.visibility)) { - throw new Error(`Cannot enter member \u201C${this.getPath()}\u201D of ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility to parent of ${SymbolFormatter.stringifyVisibility(this.#parentSymbol.visibility)} visibility`); - } - return this.#parentSymbol.members ??= {}; - } - } else { - let table; - if (SymbolUtil.isVisibilityInGlobal(additionVisibility)) { - table = this.util.global; - } else if (additionVisibility === 1) { - if (!this.#node) { - throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node is supplied`); - } - let node = this.#node; - while (node) { - if (node.type === "file") { - table = node.locals; - break; - } - node = node.parent; - } - if (!table) { - throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no file node is supplied`); - } - } else { - if (!this.#node) { - throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node is supplied`); - } - let node = this.#node; - while (node) { - if (node.locals) { - table = node.locals; - break; - } - node = node.parent; - } - if (!table) { - throw new Error(`Cannot enter \u201C${this.getPath()}\u201D with ${SymbolFormatter.stringifyVisibility(additionVisibility)} visibility as no node with locals is supplied`); - } - } - return table[this.category] ??= {}; - } - throw new Error(`Cannot create the symbol map for \u201C${this.getPath()}\u201D`); - }; - if (this.#createdWithUri && SymbolAdditionUsageWithRange.is(addition.usage)) { - addition.usage.range = Range.create(0, 0); - } - this.#map = getMap(addition); - this.#symbol = this.util.enterMap(this.#parentSymbol, this.#map, this.category, this.path, this.path[this.path.length - 1], addition, this.#doc, this.#currentContributor); - if (addition.usage?.node) { - addition.usage.node.symbol = this.#symbol; - } - } - /** - * Enters the queried symbol. - * - * @throws If the parent of this symbol doesn't exist either. - */ - enter(addition) { - this._enter(addition); - return this; - } - /** - * Amends the queried symbol if the queried symbol exists (i.e. has any of declarations/definitions/implementations/references/typeDefinitions) and is visible at the current scope. - * - * This is equivalent to calling - * ```typescript - * query.ifKnown(function () { - * this.enter(symbol) - * }) - * ``` - * - * Therefore, if the symbol is successfully amended, `elseX` methods afterwards will **not** be executed. - */ - amend(symbol7) { - return this.ifKnown(() => this.enter(symbol7)); - } - /** - * Resolves this symbol if it exists and is an alias. - * - * @throws If the current symbol points to an non-existent symbol. The state of this object will not be changed - * after the error is thrown. - */ - resolveAlias() { - if (this.#symbol) { - const result = this.util.resolveAlias(this.#symbol); - if (!result) { - throw new Error("The current symbol points to an non-existent symbol."); - } - this.#symbol = result; - this.#map = result.parentMap; - this.#parentSymbol = result.parentSymbol; - this.path = result.path; - } - return this; - } - member() { - let doc, identifier4, fn; - if (arguments.length === 2) { - doc = this.#createdWithUri ? this.#doc.uri : this.#doc; - identifier4 = arguments[0]; - fn = arguments[1]; - } else { - doc = arguments[0]; - identifier4 = arguments[1]; - fn = arguments[2]; - } - if (this.#symbol === void 0) { - throw new Error(`Tried to query member symbol \u201C${identifier4}\u201D from an undefined symbol (path \u201C${this.path.join(".")}\u201D)`); - } - const memberDoc = typeof doc === "string" && doc === this.#doc.uri && !this.#createdWithUri ? this.#doc : doc; - const memberMap = this.#symbol.members; - const memberSymbol = memberMap?.[identifier4]; - const memberQueryResult = new _SymbolQuery({ - category: this.category, - doc: memberDoc, - contributor: this.#currentContributor, - map: memberMap, - parentSymbol: this.#symbol, - path: [...this.path, identifier4], - symbol: memberSymbol, - util: this.util - }); - fn(memberQueryResult); - return this; - } - /** - * Do something with this query on each value in a given iterable. The query itself will be included - * in the callback function as the second parameter. - */ - onEach(values, fn) { - for (const value of values) { - fn.call(this, value, this); - } - return this; - } - forEachMember(fn) { - return this.onEach(Object.keys(this.visibleMembers), (identifier4) => this.member(identifier4, (query) => fn(identifier4, query))); - } - getPath() { - return `${this.category}.${this.path.join("/")}`; - } -}; -__decorate([ - DelayModeSupport((self2) => self2.util) -], SymbolQuery.prototype, "_enter", null); -var SymbolFormatter; -(function(SymbolFormatter2) { - const IndentChar = "+ "; - function assertEqual(a, b) { - if (a !== b) { - throw new Error(`Assertion error: ${a} !== ${b}`); - } - } - function stringifySymbolStack(stack) { - return stack.map((table) => stringifySymbolTable(table)).join("\n------------\n"); - } - SymbolFormatter2.stringifySymbolStack = stringifySymbolStack; - function stringifySymbolTable(table, indent = "") { - const ans = []; - for (const category of Object.keys(table)) { - const map3 = table[category]; - ans.push([category, stringifySymbolMap(map3, `${indent}${IndentChar}`)]); - } - return ans.map((v) => `CATEGORY ${v[0]} -${v[1]}`).join(` -${indent}------------ -`) || "EMPTY TABLE"; - } - SymbolFormatter2.stringifySymbolTable = stringifySymbolTable; - function stringifySymbolMap(map3, indent = "") { - if (!map3) { - return "undefined"; - } - const ans = []; - for (const identifier4 of Object.keys(map3)) { - const symbol7 = map3[identifier4]; - assertEqual(identifier4, symbol7.identifier); - ans.push(stringifySymbol(symbol7, indent)); - } - return ans.join(` -${indent}------------ -`); - } - SymbolFormatter2.stringifySymbolMap = stringifySymbolMap; - function stringifySymbol(symbol7, indent = "") { - if (!symbol7) { - return "undefined"; - } - const ans = []; - assertEqual(symbol7.path[symbol7.path.length - 1], symbol7.identifier); - ans.push(`SYMBOL ${symbol7.path.join(".")} {${symbol7.category}${symbol7.subcategory ? ` (${symbol7.subcategory})` : ""}} [${stringifyVisibility(symbol7.visibility, symbol7.visibilityRestriction)}]`); - if (symbol7.data) { - ans.push(`${IndentChar}data: ${JSON.stringify(symbol7.data, bigintJsonNumberReplacer)}`); - } - if (symbol7.desc) { - ans.push(`${IndentChar}description: ${symbol7.desc}`); - } - for (const type2 of SymbolUsageTypes) { - if (symbol7[type2]) { - ans.push(`${IndentChar}${type2}: -${symbol7[type2].map((v) => `${indent}${IndentChar.repeat(2)}${JSON.stringify(v)}`).join(` -${indent}${IndentChar.repeat(2)}------------ -`)}`); - } - } - if (symbol7.relations) { - ans.push(`${IndentChar}relations: ${JSON.stringify(symbol7.relations)}`); - } - if (symbol7.members) { - ans.push(`${IndentChar}members: -${stringifySymbolMap(symbol7.members, `${indent}${IndentChar.repeat(2)}`)}`); - } - return ans.map((v) => `${indent}${v}`).join("\n"); - } - SymbolFormatter2.stringifySymbol = stringifySymbol; - function stringifyVisibility(visibility, visibilityRestriction) { - let stringVisibility; - switch (visibility) { - case 0: - stringVisibility = "Block"; - break; - case 1: - stringVisibility = "File"; - break; - case 3: - stringVisibility = "Restricted"; - break; - default: - stringVisibility = "Public"; - break; - } - return `${stringVisibility}${visibilityRestriction ? ` ${visibilityRestriction.map((v) => `\u201C${v}\u201D`).join(", ")}` : ""}`; - } - SymbolFormatter2.stringifyVisibility = stringifyVisibility; - function stringifyLookupResult(result) { - return `parentSymbol: -${stringifySymbol(result.parentSymbol, IndentChar)} -parentMap: -${stringifySymbolMap(result.parentMap, IndentChar)} -symbol: -${stringifySymbol(result.symbol, IndentChar)}`; - } - SymbolFormatter2.stringifyLookupResult = stringifyLookupResult; -})(SymbolFormatter || (SymbolFormatter = {})); -function DelayModeSupport(getUtil = (self2) => self2) { - return (_target, _key, descripter) => { - const decoratedMethod = descripter.value; - descripter.value = function(...args) { - const util = getUtil(this); - if (util._inDelayMode) { - util._delayedOps.push(decoratedMethod.bind(this, ...args)); - } else { - decoratedMethod.apply(this, args); - } - }; - return descripter; - }; -} -function isDocAndNode(doc) { - return !!doc.doc; -} - -// node_modules/@spyglassmc/core/lib/service/fileUtil.js -var fileUtil; -(function(fileUtil2) { - function getRelativeUriFromBase(target, base) { - const baseUri = new Uri(base); - const targetUri = new Uri(target); - if (baseUri.origin !== targetUri.origin) { - return void 0; - } - const baseComponents = baseUri.pathname.split("/").filter((v) => !!v); - const targetComponents = targetUri.pathname.split("/").filter((v) => !!v); - if (baseComponents.length > targetComponents.length || baseComponents.some((bc, i) => decodeURIComponent(bc) !== decodeURIComponent(targetComponents[i]))) { - return void 0; - } - return targetComponents.slice(baseComponents.length).map(encodeURIComponent).join("/"); - } - fileUtil2.getRelativeUriFromBase = getRelativeUriFromBase; - function isSubUriOf(uri, base) { - return getRelativeUriFromBase(uri, base) !== void 0; - } - fileUtil2.isSubUriOf = isSubUriOf; - function* getRels2(uri, rootUris) { - for (const root of rootUris) { - const rel = getRelativeUriFromBase(uri, root); - if (rel !== void 0) { - yield rel; - } - } - return void 0; - } - fileUtil2.getRels = getRels2; - function getRel(uri, rootUris) { - return getRels2(uri, rootUris).next().value; - } - fileUtil2.getRel = getRel; - function* getRoots2(uri, rootUris) { - for (const root of rootUris) { - const rel = getRelativeUriFromBase(uri, root); - if (rel !== void 0) { - yield root; - } - } - return void 0; - } - fileUtil2.getRoots = getRoots2; - function getRoot(uri, rootUris) { - return getRoots2(uri, rootUris).next().value; - } - fileUtil2.getRoot = getRoot; - function isRootUri(uri) { - return uri.endsWith("/"); - } - fileUtil2.isRootUri = isRootUri; - function ensureEndingSlash(uri) { - return isRootUri(uri) ? uri : `${uri}/`; - } - fileUtil2.ensureEndingSlash = ensureEndingSlash; - function trimEndingSlash(uri) { - return isRootUri(uri) ? uri.slice(0, -1) : uri; - } - fileUtil2.trimEndingSlash = trimEndingSlash; - function join2(fromUri, toUri) { - return ensureEndingSlash(fromUri) + (toUri.startsWith("/") ? toUri.slice(1) : toUri); - } - fileUtil2.join = join2; - function isFileUri(uri) { - return uri.startsWith("file:"); - } - fileUtil2.isFileUri = isFileUri; - function extname(value) { - const i = value.lastIndexOf("."); - return i >= 0 ? value.slice(i) : void 0; - } - fileUtil2.extname = extname; - function basename(uri) { - const i = uri.lastIndexOf("/"); - return i >= 0 ? uri.slice(i + 1) : uri; - } - fileUtil2.basename = basename; - function dirname(uri) { - const i = uri.lastIndexOf("/"); - return i >= 0 ? uri.slice(0, i) : uri; - } - fileUtil2.dirname = dirname; - function getParentOfUri(uri) { - return new Uri(".", trimEndingSlash(uri.toString())); - } - fileUtil2.getParentOfUri = getParentOfUri; - async function ensureDir(externals, path6, mode = 511) { - try { - await externals.fs.mkdir(path6, { mode, recursive: true }); - } catch (e) { - if (!externals.error.isKind(e, "EEXIST")) { - throw e; - } - } - } - fileUtil2.ensureDir = ensureDir; - async function ensureParentOfFile(externals, path6, mode = 511) { - return ensureDir(externals, getParentOfUri(path6), mode); - } - fileUtil2.ensureParentOfFile = ensureParentOfFile; - async function chmod(externals, path6, mode) { - return externals.fs.chmod(path6, mode); - } - fileUtil2.chmod = chmod; - async function ensureWritable(externals, path6) { - try { - await chmod(externals, path6, 438); - } catch (e) { - if (!externals.error.isKind(e, "ENOENT")) { - throw e; - } - } - } - fileUtil2.ensureWritable = ensureWritable; - async function getAllFiles(externals, root, depth = Number.POSITIVE_INFINITY) { - async function walk(path6, level) { - if (level > depth) { - return []; - } - const entries = await externals.fs.readdir(path6); - return (await Promise.all(entries.map(async (e) => { - const entryPath = fileUtil2.join(path6.toString(), e.name); - if (e.isDirectory()) { - return await walk(entryPath, level + 1); - } else if (e.isFile()) { - return entryPath; - } else { - return []; - } - }))).flat(); - } - return walk(root, 0); - } - fileUtil2.getAllFiles = getAllFiles; - async function markReadOnly(externals, path6) { - return chmod(externals, path6, 292); - } - fileUtil2.markReadOnly = markReadOnly; - async function unlink(externals, path6) { - return externals.fs.unlink(path6); - } - fileUtil2.unlink = unlink; - async function readFile(externals, path6) { - return externals.fs.readFile(path6); - } - fileUtil2.readFile = readFile; - async function writeFile(externals, path6, data, mode = 438) { - await ensureParentOfFile(externals, path6); - await ensureWritable(externals, path6); - return externals.fs.writeFile(path6, data, { mode }); - } - fileUtil2.writeFile = writeFile; - async function readJson(externals, path6) { - return JSON.parse(bufferToString(await readFile(externals, path6)), bigintJsonNumberReviver); - } - fileUtil2.readJson = readJson; - async function writeJson(externals, path6, data) { - return writeFile(externals, path6, JSON.stringify(data, bigintJsonNumberReplacer)); - } - fileUtil2.writeJson = writeJson; - async function readGzippedFile(externals, path6) { - return decompressBytes(await readFile(externals, path6), "gzip"); - } - fileUtil2.readGzippedFile = readGzippedFile; - async function writeGzippedFile(externals, path6, buffer) { - if (typeof buffer === "string") { - buffer = new TextEncoder().encode(buffer); - } - return writeFile(externals, path6, await compressBytes(buffer, "gzip")); - } - fileUtil2.writeGzippedFile = writeGzippedFile; - async function readGzippedJson(externals, path6, reviver) { - return JSON.parse(bufferToString(await readGzippedFile(externals, path6)), reviver ?? bigintJsonNumberReviver); - } - fileUtil2.readGzippedJson = readGzippedJson; - async function writeGzippedJson(externals, path6, data, replacer) { - return writeGzippedFile(externals, path6, JSON.stringify(data, replacer ?? bigintJsonNumberReplacer)); - } - fileUtil2.writeGzippedJson = writeGzippedJson; -})(fileUtil || (fileUtil = {})); - -// node_modules/@spyglassmc/core/lib/service/FileService.js -var FileService; -(function(FileService2) { - function create(externals, cacheRoot) { - const virtualUrisRoot = fileUtil.ensureEndingSlash(new Uri("virtual-uris/", cacheRoot).toString()); - return new FileServiceImpl(externals, virtualUrisRoot); - } - FileService2.create = create; -})(FileService || (FileService = {})); -var FileServiceImpl = class { - externals; - virtualUrisRoot; - supporters = /* @__PURE__ */ new Map(); - /** - * A two-way map from mapped physical URIs to virtual URIs. - */ - map = new TwoWayMap(); - constructor(externals, virtualUrisRoot) { - this.externals = externals; - this.virtualUrisRoot = virtualUrisRoot; - } - register(protocol, supporter, force = false) { - if (!force && this.supporters.has(protocol)) { - throw new Error(`The protocol \u201C${protocol}\u201D is already associated with another supporter.`); - } - this.supporters.set(protocol, supporter); - } - unregister(protocol) { - this.supporters.delete(protocol); - } - /** - * @throws If the protocol of `uri` isn't supported. - * - * @returns The protocol if it's supported. - */ - getSupportedProtocol(uri) { - const protocol = new Uri(uri).protocol; - if (!this.supporters.has(protocol)) { - throw new Error(`The protocol \u201C${protocol}\u201D is unsupported.`); - } - return protocol; - } - /** - * @throws - */ - async hash(uri) { - const protocol = this.getSupportedProtocol(uri); - return this.supporters.get(protocol).hash(uri); - } - /** - * @throws - */ - readFile(uri) { - const protocol = this.getSupportedProtocol(uri); - return this.supporters.get(protocol).readFile(uri); - } - *listFiles() { - for (const supporter of this.supporters.values()) { - yield* supporter.listFiles(); - } - } - *listRoots() { - for (const supporter of this.supporters.values()) { - yield* supporter.listRoots(); - } - } - async mapToDisk(virtualUri) { - if (fileUtil.isFileUri(virtualUri)) { - return virtualUri; - } - if (!this.virtualUrisRoot) { - return void 0; - } - try { - let mappedUri = this.map.getKey(virtualUri); - if (mappedUri === void 0) { - mappedUri = `${this.virtualUrisRoot}${await getSha1(virtualUri)}/${fileUtil.basename(virtualUri)}`; - try { - await fileUtil.unlink(this.externals, mappedUri); - } catch (e) { - if (!this.externals.error.isKind(e, "ENOENT")) { - throw e; - } - } - const buffer = await this.readFile(virtualUri); - await fileUtil.writeFile(this.externals, mappedUri, buffer, 292); - this.map.set(mappedUri, virtualUri); - } - return mappedUri; - } catch (e) { - } - return void 0; - } - mapFromDisk(mappedUri) { - if (!this.virtualUrisRoot) { - return mappedUri; - } - return this.map.get(mappedUri) ?? mappedUri; - } -}; -var FileUriSupporter = class _FileUriSupporter { - externals; - roots; - files; - protocol = "file:"; - constructor(externals, roots, files) { - this.externals = externals; - this.roots = roots; - this.files = files; - } - async hash(uri) { - return hashFile(this.externals, uri); - } - readFile(uri) { - return this.externals.fs.readFile(uri); - } - *listFiles() { - for (const files of this.files.values()) { - yield* files; - } - } - listRoots() { - return this.roots; - } - async mapToDisk(uri) { - return uri; - } - static async create(dependencies, externals, logger) { - const roots = []; - const files = /* @__PURE__ */ new Map(); - for (const dependency of dependencies) { - if (dependency.type !== "directory") { - continue; - } - let { uri } = dependency; - try { - if (fileUtil.isFileUri(uri) && (await externals.fs.stat(uri)).isDirectory()) { - uri = fileUtil.ensureEndingSlash(uri); - roots.push(uri); - files.set(uri, await fileUtil.getAllFiles(externals, uri)); - } - } catch (e) { - logger.error(`[FileUriSupporter#create] Bad dependency ${uri}`, e); - } - } - return new _FileUriSupporter(externals, roots, files); - } -}; -var ArchiveUriSupporter = class _ArchiveUriSupporter { - externals; - logger; - archiveHashes; - entries; - static Protocol = "archive:"; - protocol = _ArchiveUriSupporter.Protocol; - /** - * @param entries A map from archive names to unzipped entries. - */ - constructor(externals, logger, archiveHashes, entries) { - this.externals = externals; - this.logger = logger; - this.archiveHashes = archiveHashes; - this.entries = entries; - } - async hash(uri) { - const { archiveName, pathInArchive } = _ArchiveUriSupporter.decodeUri(new Uri(uri)); - if (!pathInArchive) { - if (!this.archiveHashes.has(archiveName)) { - throw new Error(`No archiveHashes entry for ${archiveName}`); - } - return this.archiveHashes.get(archiveName); - } else { - return getSha1(this.getDataInArchive(archiveName, pathInArchive)); - } - } - async readFile(uri) { - const { archiveName, pathInArchive } = _ArchiveUriSupporter.decodeUri(new Uri(uri)); - return this.getDataInArchive(archiveName, pathInArchive); - } - /** - * @throws - */ - getDataInArchive(archiveName, pathInArchive) { - const entries = this.entries.get(archiveName); - if (!entries) { - throw this.externals.error.createKind("ENOENT", `Archive \u201C${archiveName}\u201D has not been loaded into the memory`); - } - const entry6 = entries.get(pathInArchive); - if (!entry6) { - throw this.externals.error.createKind("ENOENT", `Path \u201C${pathInArchive}\u201D does not exist in archive \u201C${archiveName}\u201D`); - } - if (entry6.type !== "file") { - throw this.externals.error.createKind("EISDIR", `Path \u201C${pathInArchive}\u201D in archive \u201C${archiveName}\u201D is not a file`); - } - return entry6.data; - } - *listFiles() { - for (const [archiveName, entries] of this.entries.entries()) { - this.logger.info(`[ArchiveUriSupporter#listFiles] Listing ${entries.size} entries from ${archiveName}`); - for (const entry6 of entries.values()) { - if (entry6.type === "file") { - yield _ArchiveUriSupporter.getUri(archiveName, entry6.path); - } - } - } - } - *listRoots() { - for (const archiveName of this.entries.keys()) { - yield _ArchiveUriSupporter.getUri(archiveName); - } - } - static getUri(archiveName, pathInArchive = "") { - return `${_ArchiveUriSupporter.Protocol}//${archiveName}/${pathInArchive.replace(/\\/g, "/")}`; - } - /** - * @throws When `uri` has the wrong protocol or hostname. - */ - static decodeUri(uri) { - if (uri.protocol !== _ArchiveUriSupporter.Protocol) { - throw new Error(`Expected protocol \u201C${_ArchiveUriSupporter.Protocol}\u201D in ${uri}`); - } - const path6 = uri.pathname; - if (!path6) { - throw new Error(`Missing path in archive uri ${uri}`); - } - return { archiveName: uri.host, pathInArchive: path6.charAt(0) === "/" ? path6.slice(1) : path6 }; - } - static async create(dependencies, externals, logger) { - const archiveHashes = /* @__PURE__ */ new Map(); - const entries = /* @__PURE__ */ new Map(); - for (const dependency of dependencies) { - if (dependency.type === "directory") { - continue; - } - const archiveName = dependency.type === "tarball-file" ? fileUtil.basename(dependency.uri) : dependency.name; - try { - if (entries.has(archiveName)) { - throw new Error(`A different archive with ${archiveName} already exists`); - } - const bytes = dependency.type === "tarball-file" ? await externals.fs.readFile(dependency.uri) : dependency.data; - const files = await externals.archive.decompressBall(bytes, { stripLevel: dependency.stripLevel ?? 0 }); - logger.info(`[ArchiveUriSupporter#create] Extracted ${files.length} files from ${archiveName}`); - const hash = await getSha1(bytes); - archiveHashes.set(archiveName, hash); - entries.set(archiveName, new Map(files.map((f) => [f.path.replace(/\\/g, "/"), f]))); - } catch (e) { - logger.error(`[ArchiveUriSupporter#create] Bad dependency ${archiveName}`, e); - } - } - return new _ArchiveUriSupporter(externals, logger, archiveHashes, entries); - } -}; -async function hashFile(externals, uri) { - return getSha1(await externals.fs.readFile(uri)); -} - -// node_modules/@spyglassmc/core/lib/service/CacheService.js -var LatestCacheVersion = 7; -var Checksums; -(function(Checksums2) { - function create() { - return { files: {}, roots: {}, symbolRegistrars: {} }; - } - Checksums2.create = create; -})(Checksums || (Checksums = {})); -var CacheService = class { - cacheRoot; - project; - checksums = Checksums.create(); - errors = {}; - #hasValidatedFiles = false; - /** - * @param cacheRoot File path to the directory where cache files by Spyglass should be stored. - * @param project - */ - constructor(cacheRoot, project) { - this.cacheRoot = cacheRoot; - this.project = project; - this.project.on("documentUpdated", async ({ doc }) => { - if (!this.#hasValidatedFiles || !(doc.uri.startsWith(ArchiveUriSupporter.Protocol) || doc.uri.startsWith("file:"))) { - return; - } - try { - this.checksums.files[doc.uri] = await getSha1(doc.getText()); - } catch (e) { - if (!this.project.externals.error.isKind(e, "EISDIR")) { - this.project.logger.error(`[CacheService#hash-file] ${doc.uri}`); - } - } - }); - this.project.on("rootsUpdated", async ({ roots }) => { - if (!this.#hasValidatedFiles) { - return; - } - for (const root of roots) { - try { - this.checksums.roots[root] = await this.project.fs.hash(root); - } catch (e) { - if (!this.project.externals.error.isKind(e, "EISDIR")) { - this.project.logger.error(`[CacheService#hash-root] ${root}`, e); - } - } - } - }); - this.project.on("symbolRegistrarExecuted", ({ id, checksum }) => { - if (checksum !== void 0) { - this.checksums.symbolRegistrars[id] = checksum; - } - }); - this.project.on("documentErrored", ({ uri, errors }) => { - this.errors[uri] = errors; - }); - } - #cacheFilePath; - async getCacheFileUri() { - if (!this.#cacheFilePath) { - const sortedRoots = [...this.project.projectRoots].sort(); - const hash = await getSha1(sortedRoots.join(":")); - this.#cacheFilePath = new Uri(`symbols/${hash}.json.gz`, this.cacheRoot).toString(); - } - return this.#cacheFilePath; - } - async load() { - const ans = { symbols: {} }; - if (this.project.projectRoots.length === 0) { - return ans; - } - const __profiler = this.project.profilers.get("cache#load"); - let filePath; - try { - filePath = await this.getCacheFileUri(); - this.project.logger.info(`[CacheService#load] symbolCachePath = ${filePath}`); - const cache = await fileUtil.readGzippedJson(this.project.externals, filePath, bigintJsonLosslessReviver); - __profiler.task("Read File"); - if (cache.version === LatestCacheVersion) { - this.checksums = cache.checksums; - this.errors = cache.errors; - ans.symbols = SymbolTable.link(cache.symbols); - __profiler.task("Link Symbols"); - } else { - this.project.logger.info(`[CacheService#load] Unsupported cache format ${cache.version}; expected ${LatestCacheVersion}`); - } - } catch (e) { - if (!this.project.externals.error.isKind(e, "ENOENT")) { - this.project.logger.error("[CacheService#load] ", e); - } - } - __profiler.finalize(); - return ans; - } - async validate() { - const ans = { - addedFiles: [], - changedFiles: [], - removedFiles: [], - unchangedFiles: [] - }; - const unchangedRoots = []; - for (const [uri, checksum] of Object.entries(this.checksums.roots)) { - try { - const hash = await this.project.fs.hash(uri); - if (hash === checksum) { - unchangedRoots.push(uri); - } - } catch (e) { - if (!this.project.externals.error.isKind(e, "EISDIR")) { - this.project.logger.error(`[CacheService#hash-file] ${uri}`); - } - } - } - for (const [uri, checksum] of Object.entries(this.checksums.files)) { - if (unchangedRoots.some((root) => fileUtil.isSubUriOf(uri, root))) { - ans.unchangedFiles.push(uri); - continue; - } - if (this.project.shouldExclude(uri)) { - ans.removedFiles.push(uri); - continue; - } - try { - const hash = await this.project.fs.hash(uri); - if (hash === checksum) { - ans.unchangedFiles.push(uri); - } else { - ans.changedFiles.push(uri); - } - } catch (e) { - if (this.project.externals.error.isKind(e, "ENOENT") || this.project.externals.error.isKind(e, "EISDIR")) { - ans.removedFiles.push(uri); - } else { - this.project.logger.error(`[CacheService#validate] ${uri}`, e); - ans.changedFiles.push(uri); - } - } - } - for (const uri of this.project.getTrackedFiles()) { - if (!(uri in this.checksums.files)) { - ans.addedFiles.push(uri); - } - } - this.#hasValidatedFiles = true; - return ans; - } - /** - * @returns If the cache file was saved successfully. - */ - async save() { - if (this.project.projectRoots.length === 0) { - return false; - } - const __profiler = this.project.profilers.get("cache#save"); - let filePath; - try { - filePath = await this.getCacheFileUri(); - const cache = { - version: LatestCacheVersion, - projectRoots: this.project.projectRoots, - checksums: this.checksums, - symbols: SymbolTable.unlink(this.project.symbols.global), - errors: this.errors - }; - __profiler.task("Unlink Symbols"); - await fileUtil.writeGzippedJson(this.project.externals, filePath, cache, bigintJsonLosslessReplacer); - __profiler.task("Write File").finalize(); - return true; - } catch (e) { - this.project.logger.error(`[CacheService#save] path = ${filePath}`, e); - } - return false; - } - async hasFileChangedSinceCache(doc) { - return this.checksums.files[doc.uri] !== await getSha1(doc.getText()); - } - reset() { - this.#hasValidatedFiles = false; - this.checksums = Checksums.create(); - this.errors = {}; - return { symbols: {} }; - } -}; - -// node_modules/@spyglassmc/core/lib/service/Config.js -var import_rfdc3 = __toESM(require_rfdc(), 1); -var LinterSeverity; -(function(LinterSeverity2) { - function is(value) { - return value === "hint" || value === "information" || value === "warning" || value === "error"; - } - LinterSeverity2.is = is; - function toErrorSeverity(value) { - switch (value) { - case "error": - return ErrorSeverity.Error; - case "hint": - return ErrorSeverity.Hint; - case "information": - return ErrorSeverity.Information; - case "warning": - return ErrorSeverity.Warning; - } - } - LinterSeverity2.toErrorSeverity = toErrorSeverity; -})(LinterSeverity || (LinterSeverity = {})); -var LinterConfigValue; -(function(LinterConfigValue2) { - function destruct(value) { - if (value === null || value === void 0) { - return void 0; - } - if (LinterSeverity.is(value)) { - return { ruleSeverity: LinterSeverity.toErrorSeverity(value), ruleValue: true }; - } - if (Array.isArray(value) && LinterSeverity.is(value[0])) { - return { ruleSeverity: LinterSeverity.toErrorSeverity(value[0]), ruleValue: value[1] }; - } - return { ruleSeverity: ErrorSeverity.Warning, ruleValue: value }; - } - LinterConfigValue2.destruct = destruct; -})(LinterConfigValue || (LinterConfigValue = {})); -var SymbolLinterConfig; -(function(SymbolLinterConfig2) { - function is(value) { - return Arrayable.is(value, Complex.is) || Action.is(value); - } - SymbolLinterConfig2.is = is; - let Complex; - (function(Complex2) { - function is2(v) { - if (!v || typeof v !== "object") { - return false; - } - const value = v; - return (value.if === void 0 || Arrayable.is(value.if, Condition.is)) && (value.then === void 0 || Action.is(value.then)) && (value.override === void 0 || Arrayable.is(value.override, Complex2.is)); - } - Complex2.is = is2; - })(Complex = SymbolLinterConfig2.Complex || (SymbolLinterConfig2.Complex = {})); - let Condition; - (function(Condition2) { - function is2(v) { - if (!v || typeof v !== "object") { - return false; - } - const value = v; - return (value.category === void 0 || Arrayable.is(value.category, TypePredicates.isString)) && (value.pattern === void 0 || Arrayable.is(value.pattern, TypePredicates.isString)) && (value.excludePattern === void 0 || Arrayable.is(value.excludePattern, TypePredicates.isString)) && (value.namespace === void 0 || Arrayable.is(value.namespace, TypePredicates.isString)) && (value.excludeNamespace === void 0 || Arrayable.is(value.excludeNamespace, TypePredicates.isString)); - } - Condition2.is = is2; - })(Condition = SymbolLinterConfig2.Condition || (SymbolLinterConfig2.Condition = {})); - let Action; - (function(Action2) { - function isDeclare(value) { - return value !== void 0 && ["block", "file", "public"].includes(value.declare); - } - Action2.isDeclare = isDeclare; - function isReport(value) { - return value !== void 0 && ["inherit", "hint", "information", "warning", "error"].includes(value.report); - } - Action2.isReport = isReport; - function is2(v) { - if (!v || typeof v !== "object") { - return false; - } - const value = v; - return isDeclare(value) || isReport(value); - } - Action2.is = is2; - })(Action = SymbolLinterConfig2.Action || (SymbolLinterConfig2.Action = {})); -})(SymbolLinterConfig || (SymbolLinterConfig = {})); -var VanillaConfig = { - env: { - dependencies: ["@vanilla-datapack", "@vanilla-resourcepack", "@vanilla-mcdoc"], - exclude: [ - ".*/**", - "**/node_modules/**", - "**/__pycache__/**" - ], - customResources: {}, - feature: { - codeActions: true, - colors: true, - completions: true, - documentHighlighting: true, - documentLinks: true, - foldingRanges: true, - formatting: true, - hover: true, - inlayHint: { - enabledNodes: [ - "boolean", - "double", - "float", - "integer", - "long", - "mcfunction:coordinate", - "mcfunction:vector", - "mcfunction:command_child/unknown" - ] - }, - semanticColoring: true, - selectionRanges: true, - signatures: true - }, - gameVersion: "Auto", - permissionLevel: 2, - plugins: [], - mcmetaSummaryOverrides: {}, - enableMcdocCaching: false - }, - format: { - blockStateBracketSpacing: { inside: 0 }, - blockStateCommaSpacing: { before: 0, after: 1 }, - blockStateEqualSpacing: { before: 0, after: 0 }, - blockStateTrailingComma: false, - eol: "auto", - nbtArrayBracketSpacing: { inside: 0 }, - nbtArrayCommaSpacing: { before: 0, after: 1 }, - nbtArraySemicolonSpacing: { after: 1 }, - nbtArrayTrailingComma: false, - nbtByteSuffix: "b", - nbtCompoundBracketSpacing: { inside: 0 }, - nbtCompoundColonSpacing: { before: 0, after: 1 }, - nbtCompoundCommaSpacing: { before: 0, after: 1 }, - nbtCompoundTrailingComma: false, - nbtDoubleOmitSuffix: false, - nbtDoubleSuffix: "d", - nbtFloatSuffix: "f", - nbtListBracketSpacing: { inside: 0 }, - nbtListCommaSpacing: { before: 0, after: 1 }, - nbtListTrailingComma: false, - nbtLongSuffix: "L", - nbtShortSuffix: "s", - selectorBracketSpacing: { inside: 0 }, - selectorCommaSpacing: { before: 0, after: 1 }, - selectorEqualSpacing: { before: 0, after: 0 }, - selectorTrailingComma: false, - timeOmitTickUnit: false - }, - lint: { - blockStateSortKeys: null, - nbtCompoundSortKeys: null, - selectorSortKeys: null, - commandStringQuote: null, - nbtKeyQuote: null, - nbtPathQuote: null, - nbtStringQuote: null, - selectorKeyQuote: null, - idOmitDefaultNamespace: null, - nameOfNbtKey: null, - nameOfObjective: null, - nameOfScoreHolder: null, - nameOfTag: null, - nameOfTeam: null, - nbtArrayLengthCheck: true, - nbtBoolean: null, - nbtListLengthCheck: null, - nbtTypeCheck: "loosely", - undeclaredSymbol: [ - { - if: [ - { category: RegistryCategories, namespace: "minecraft" }, - { category: [...DataFileCategories, "bossbar", "objective", "stopwatch", "team"] } - ], - then: { report: "warning" } - }, - { - if: { category: ["attribute_modifier", "attribute_modifier_uuid", "tag"] }, - then: { declare: "public" } - }, - { - then: { declare: "block" } - } - ] - }, - snippet: { - executeIfScoreSet: "execute if score ${1:score_holder} ${2:objective} = ${1:score_holder} ${2:objective} $0", - summonAec: 'summon minecraft:area_effect_cloud ~ ~ ~ {Age: -2147483648, Duration: -1, WaitTime: -2147483648, Tags: ["${1:tag}"]}' - } -}; -var PartialConfig; -(function(PartialConfig2) { - function buildConfigFromEditorSettingsSafe(spyglassmcConfiguration) { - const result = {}; - if (!spyglassmcConfiguration || typeof spyglassmcConfiguration !== "object") { - return result; - } - if (spyglassmcConfiguration.env && typeof spyglassmcConfiguration.env === "object") { - result.env = {}; - if (typeof spyglassmcConfiguration.env.gameVersion === "string") { - result.env.gameVersion = spyglassmcConfiguration.env.gameVersion; - } - if (typeof spyglassmcConfiguration.env.enableMcdocCaching === "boolean") { - result.env.enableMcdocCaching = spyglassmcConfiguration.env.enableMcdocCaching; - } - if (spyglassmcConfiguration.env.feature && typeof spyglassmcConfiguration.env.feature === "object") { - result.env.feature = {}; - if (typeof spyglassmcConfiguration.env.feature.codeActions === "boolean") { - result.env.feature.codeActions = spyglassmcConfiguration.env.feature.codeActions; - } - if (typeof spyglassmcConfiguration.env.feature.colors === "boolean") { - result.env.feature.colors = spyglassmcConfiguration.env.feature.colors; - } - if (typeof spyglassmcConfiguration.env.feature.completions === "boolean") { - result.env.feature.completions = spyglassmcConfiguration.env.feature.completions; - } - if (typeof spyglassmcConfiguration.env.feature.documentHighlighting === "boolean") { - result.env.feature.documentHighlighting = spyglassmcConfiguration.env.feature.documentHighlighting; - } - if (typeof spyglassmcConfiguration.env.feature.documentLinks === "boolean") { - result.env.feature.documentLinks = spyglassmcConfiguration.env.feature.documentLinks; - } - if (typeof spyglassmcConfiguration.env.feature.foldingRanges === "boolean") { - result.env.feature.foldingRanges = spyglassmcConfiguration.env.feature.foldingRanges; - } - if (typeof spyglassmcConfiguration.env.feature.formatting === "boolean") { - result.env.feature.formatting = spyglassmcConfiguration.env.feature.formatting; - } - if (typeof spyglassmcConfiguration.env.feature.hover === "boolean") { - result.env.feature.hover = spyglassmcConfiguration.env.feature.hover; - } - if (spyglassmcConfiguration.env.feature.inlayHint && typeof spyglassmcConfiguration.env.feature.inlayHint === "object" && Array.isArray(spyglassmcConfiguration.env.feature.inlayHint.enabledNodes)) { - result.env.feature.inlayHint = { - enabledNodes: spyglassmcConfiguration.env.feature.inlayHint.enabledNodes.filter((element) => typeof element === "string") - }; - } - if (typeof spyglassmcConfiguration.env.feature.semanticColoring === "boolean") { - result.env.feature.semanticColoring = spyglassmcConfiguration.env.feature.semanticColoring; - } - if (spyglassmcConfiguration.env.feature.semanticColoring && typeof spyglassmcConfiguration.env.feature.semanticColoring === "object" && Array.isArray(spyglassmcConfiguration.env.feature.semanticColoring.disabledLanguages)) { - result.env.feature.semanticColoring = { - disabledLanguages: spyglassmcConfiguration.env.feature.semanticColoring.disabledLanguages.filter((element) => typeof element === "string") - }; - } - if (typeof spyglassmcConfiguration.env.feature.selectionRanges === "boolean") { - result.env.feature.selectionRanges = spyglassmcConfiguration.env.feature.selectionRanges; - } - if (typeof spyglassmcConfiguration.env.feature.signatures === "boolean") { - result.env.feature.signatures = spyglassmcConfiguration.env.feature.signatures; - } - } - } - return result; - } - PartialConfig2.buildConfigFromEditorSettingsSafe = buildConfigFromEditorSettingsSafe; -})(PartialConfig || (PartialConfig = {})); -var ConfigService = class _ConfigService extends EventDispatcher { - project; - defaultConfig; - static ConfigFileNames = Object.freeze(["spyglass.json", ".spyglassrc", ".spyglassrc.json"]); - currentEditorConfiguration = {}; - constructor(project, defaultConfig = VanillaConfig) { - super(); - this.project = project; - this.defaultConfig = defaultConfig; - const handler = async ({ uri }) => { - if (_ConfigService.isConfigFile(uri)) { - this.emit("changed", { config: await this.load() }); - } - }; - project.on("fileCreated", handler); - project.on("fileModified", handler); - project.on("fileDeleted", handler); - } - async onEditorConfigurationUpdate(editorConfiguration) { - this.currentEditorConfiguration = editorConfiguration; - this.emit("changed", { config: await this.load() }); - } - async load() { - const overrides = []; - for (const projectRoot of this.project.projectRoots) { - for (const name of _ConfigService.ConfigFileNames) { - const uri = projectRoot + name; - try { - const contents = await this.project.externals.fs.readFile(uri); - overrides.push(JSON.parse(bufferToString(contents))); - } catch (e) { - if (this.project.externals.error.isKind(e, "ENOENT")) { - continue; - } - this.emit("error", { error: e, uri }); - } - break; - } - } - return _ConfigService.merge(this.defaultConfig, this.currentEditorConfiguration, ...overrides); - } - static isConfigFile(uri) { - return _ConfigService.ConfigFileNames.some((n) => uri.endsWith(`/${n}`)); - } - static merge(base, ...overrides) { - return overrides.reduce(merge, (0, import_rfdc3.default)()(base)); - } -}; - -// node_modules/@spyglassmc/core/lib/processor/binder/Binder.js -var IsAsync = Symbol("IsAsyncBinder"); -var SyncBinder; -(function(SyncBinder2) { - function create(binder) { - return binder; - } - SyncBinder2.create = create; - function is(binder) { - return !binder[IsAsync]; - } - SyncBinder2.is = is; -})(SyncBinder || (SyncBinder = {})); -var AsyncBinder; -(function(AsyncBinder2) { - function create(binder) { - return Object.assign(binder, { [IsAsync]: true }); - } - AsyncBinder2.create = create; - function is(binder) { - return binder[IsAsync]; - } - AsyncBinder2.is = is; -})(AsyncBinder || (AsyncBinder = {})); - -// node_modules/@spyglassmc/core/lib/processor/binder/builtin.js -var builtin_exports = {}; -__export(builtin_exports, { - any: () => any, - attempt: () => attempt, - dispatchSync: () => dispatchSync, - fallback: () => fallback, - fallbackSync: () => fallbackSync, - noop: () => noop, - registerBinders: () => registerBinders, - resourceLocation: () => resourceLocation, - symbol: () => symbol -}); - -// node_modules/@spyglassmc/core/lib/processor/util.js -function traversePreOrder(node, shouldContinue, shouldCallFn, fn) { - traversePreOrderImpl(node, shouldContinue, shouldCallFn, fn, []); -} -function traversePreOrderImpl(node, shouldContinue, shouldCallFn, fn, parents) { - if (shouldCallFn(node, parents)) { - fn(node, parents); - } - if (!node.children || !shouldContinue(node, parents)) { - return; - } - for (const child of node.children ?? []) { - parents.unshift(node); - traversePreOrderImpl(child, shouldContinue, shouldCallFn, fn, parents); - parents.shift(); - } -} - -// node_modules/@spyglassmc/core/lib/processor/binder/builtin.js -function attempt(binder, node, ctx) { - const tempCtx = { - ...ctx, - err: new ErrorReporter(ctx.err.source), - symbols: ctx.symbols.clone() - }; - const processAfterBinder = () => { - StateProxy.undoChanges(node); - const totalErrorSpan = tempCtx.err.errors.map((e) => e.range.end - e.range.start).reduce((a, b) => a + b, 0); - return { - errorAmount: tempCtx.err.errors.length, - totalErrorSpan, - updateNodeAndCtx: () => { - ctx.err.absorb(tempCtx.err); - StateProxy.redoChanges(node); - tempCtx.symbols.applyDelayedEdits(); - } - }; - }; - if (SyncBinder.is(binder)) { - binder(node, tempCtx); - return processAfterBinder(); - } else { - return (async () => { - await binder(node, tempCtx); - return processAfterBinder(); - })(); - } -} -function any(binders) { - if (binders.length === 0) { - throw new Error("Expected at least one binder"); - } - const attemptSorter = (a, b) => a.errorAmount - b.errorAmount || a.totalErrorSpan - b.totalErrorSpan; - if (binders.every(SyncBinder.is)) { - return SyncBinder.create((node, ctx) => { - const attempts = binders.map((binder) => attempt(binder, node, ctx)).sort(attemptSorter); - attempts[0].updateNodeAndCtx(); - }); - } else { - return AsyncBinder.create(async (node, ctx) => { - const attempts = (await Promise.all(binders.map((binder) => attempt(binder, node, ctx)))).sort(attemptSorter); - attempts[0].updateNodeAndCtx(); - }); - } -} -var noop = SyncBinder.create(() => { -}); -var fallback = AsyncBinder.create(async (node, ctx) => { - const promises = []; - traversePreOrder(node, (node2) => !ctx.meta.hasBinder(node2.type), (node2) => ctx.meta.hasBinder(node2.type), (node2) => { - const binder = ctx.meta.getBinder(node2.type); - const result = binder(node2, ctx); - if (result instanceof Promise) { - promises.push(result); - } - }); - await Promise.all(promises); -}); -var fallbackSync = SyncBinder.create((node, ctx) => { - traversePreOrder(node, (node2) => !ctx.meta.hasBinder(node2.type), (node2) => ctx.meta.hasBinder(node2.type), (node2) => { - const binder = ctx.meta.getBinder(node2.type); - if (SyncBinder.is(binder)) { - binder(node2, ctx); - } else { - ctx.logger.warn(`[fallbackSync] Trying to run async binder for "${node2.type}"`); - } - }); -}); -var dispatchSync = SyncBinder.create((node, ctx) => { - for (const child of node.children ?? []) { - if (ctx.meta.hasBinder(child.type)) { - const binder = ctx.meta.getBinder(child.type); - binder(child, ctx); - } - } -}); -var resourceLocation = SyncBinder.create((node, ctx) => { - const raw = ResourceLocationNode.toString(node, "full"); - let sanitizedRaw = ResourceLocation.lengthen(node.options.namespacePathSep === "." ? raw.replace(/\./g, ResourceLocation.NamespacePathSep) : raw); - if (node.options.implicitPath) { - const sepIndex = sanitizedRaw.indexOf(ResourceLocation.NamespacePathSep); - sanitizedRaw = sanitizedRaw.substring(0, sepIndex + 1) + node.options.implicitPath + sanitizedRaw.substring(sepIndex + 1); - } - if (node.options.category) { - ctx.symbols.query(ctx.doc, node.isTag ? `tag/${node.options.category}` : node.options.category, sanitizedRaw).enter({ - usage: { type: node.options.usageType, node, accessType: node.options.accessType } - }); - } - if (node.options.pool && !node.options.allowUnknown) { - if (!node.options.pool.includes(sanitizedRaw)) { - ctx.err.report(localize("expected", node.options.pool), node, ErrorSeverity.Error); - } - return; - } -}); -var symbol = SyncBinder.create((node, ctx) => { - if (node.value) { - const path6 = node.options.parentPath ? [...node.options.parentPath, node.value] : [node.value]; - ctx.symbols.query(ctx.doc, node.options.category, ...path6).enter({ - data: { subcategory: node.options.subcategory }, - usage: { type: node.options.usageType, node, accessType: node.options.accessType } - }); - } -}); -function registerBinders(meta) { - meta.registerBinder("resource_location", resourceLocation); - meta.registerBinder("symbol", symbol); -} - -// node_modules/@spyglassmc/core/lib/processor/checker/builtin.js -var builtin_exports2 = {}; -__export(builtin_exports2, { - any: () => any2, - attempt: () => attempt2, - dispatchSync: () => dispatchSync2, - fallback: () => fallback2, - fallbackSync: () => fallbackSync2, - noop: () => noop2, - registerCheckers: () => registerCheckers, - resourceLocation: () => resourceLocation2, - symbol: () => symbol2 -}); -function attempt2(checker, node, ctx) { - const tempCtx = { - ...ctx, - err: new ErrorReporter(ctx.err.source), - symbols: ctx.symbols.clone() - }; - checker(node, tempCtx); - StateProxy.undoChanges(node); - const totalErrorSpan = tempCtx.err.errors.map((e) => e.range.end - e.range.start).reduce((a, b) => a + b, 0); - return { - errorAmount: tempCtx.err.errors.length, - totalErrorSpan, - updateNodeAndCtx: () => { - ctx.err.absorb(tempCtx.err); - StateProxy.redoChanges(node); - tempCtx.symbols.applyDelayedEdits(); - } - }; -} -function any2(checkers) { - if (checkers.length === 0) { - throw new Error("Expected at least one checker"); - } - return (node, ctx) => { - const attempts = checkers.map((checker) => attempt2(checker, node, ctx)).sort((a, b) => a.errorAmount - b.errorAmount || a.totalErrorSpan - b.totalErrorSpan); - attempts[0].updateNodeAndCtx(); - }; -} -var noop2 = () => { -}; -var fallback2 = async (node, ctx) => { - const promises = []; - traversePreOrder(node, (node2) => !ctx.meta.hasChecker(node2.type), (node2) => ctx.meta.hasChecker(node2.type), (node2) => { - const checker = ctx.meta.getChecker(node2.type); - const result = checker(node2, ctx); - if (result instanceof Promise) { - promises.push(result); - } - }); - await Promise.all(promises); -}; -var fallbackSync2 = async (node, ctx) => { - const promises = []; - traversePreOrder(node, (node2) => !ctx.meta.hasChecker(node2.type), (node2) => ctx.meta.hasChecker(node2.type), (node2) => { - const checker = ctx.meta.getChecker(node2.type); - const result = checker(node2, ctx); - if (result instanceof Promise) { - ctx.logger.warn(`[fallbackSync] Trying to run async checker for "${node2.type}"`); - } - }); - await Promise.all(promises); -}; -var dispatchSync2 = (node, ctx) => { - for (const child of node.children ?? []) { - if (ctx.meta.hasChecker(child.type)) { - const checker = ctx.meta.getChecker(child.type); - checker(child, ctx); - } - } -}; -var resourceLocation2 = (node, ctx) => { -}; -var symbol2 = (_node, _ctx) => { -}; -function registerCheckers(meta) { - meta.registerChecker("resource_location", resourceLocation2); - meta.registerChecker("symbol", symbol2); -} - -// node_modules/@spyglassmc/core/lib/processor/codeActions/builtin.js -var builtin_exports3 = {}; -__export(builtin_exports3, { - fallback: () => fallback3, - file: () => file, - registerProviders: () => registerProviders -}); -var fallback3 = (node, ctx) => { - const ans = []; - traversePreOrder(node, (node2) => Range.containsRange(node2.range, ctx.range, true), (node2) => ctx.meta.hasCodeActionProvider(node2.type), (node2) => ans.push(...ctx.meta.getCodeActionProvider(node2.type)(node2, ctx))); - return ans; -}; -var file = (node, ctx) => { - const ans = []; - for (const error4 of FileNode.getErrors(node)) { - const action = error4.info?.codeAction; - if (!action) { - continue; - } - if (!Range.containsRange(error4.range, ctx.range, true)) { - continue; - } - ans.push({ - ...action, - errors: [error4] - }); - } - return ans; -}; -function registerProviders(meta) { - meta.registerCodeActionProvider("file", file); -} - -// node_modules/@spyglassmc/core/lib/processor/ColorInfoProvider.js -var Color; -(function(Color2) { - Color2.NamedColors = /* @__PURE__ */ new Map([ - ["aqua", 5636095], - ["black", 0], - ["blue", 5592575], - ["dark_aqua", 43690], - ["dark_blue", 170], - ["dark_gray", 5592405], - ["dark_green", 43520], - ["dark_purple", 11141290], - ["dark_red", 11141120], - ["gold", 16755200], - ["gray", 11184810], - ["green", 5635925], - ["light_purple", 16733695], - ["red", 16733525], - ["white", 16777215], - ["yellow", 16777045] - ]); - Color2.ColorNames = [...Color2.NamedColors.keys()]; - function fromNamed(value) { - const composite = Color2.NamedColors.get(value); - if (composite === void 0) { - return void 0; - } - return fromCompositeRGB(composite); - } - Color2.fromNamed = fromNamed; - function fromDecRGBA(r, g, b, a) { - return [r, g, b, a]; - } - Color2.fromDecRGBA = fromDecRGBA; - function fromDecRGB(r, g, b) { - return fromDecRGBA(r, g, b, 1); - } - Color2.fromDecRGB = fromDecRGB; - function fromIntRGBA(r, g, b, a) { - return fromDecRGBA(r / 255, g / 255, b / 255, a / 255); - } - Color2.fromIntRGBA = fromIntRGBA; - function fromIntRGB(r, g, b) { - return fromIntRGBA(r, g, b, 255); - } - Color2.fromIntRGB = fromIntRGB; - function fromHexRGB(value) { - var bigint = parseInt(value.slice(1), 16); - var r = bigint >> 16 & 255; - var g = bigint >> 8 & 255; - var b = bigint & 255; - return fromIntRGB(r, g, b); - } - Color2.fromHexRGB = fromHexRGB; - function fromCompositeRGB(value) { - const r = value >> 16 & 255; - const g = value >> 8 & 255; - const b = value & 255; - return fromIntRGB(r, g, b); - } - Color2.fromCompositeRGB = fromCompositeRGB; - function fromCompositeARGB(value) { - value |= 0; - const a = value >>> 24 & 255; - const r = value >>> 16 & 255; - const g = value >>> 8 & 255; - const b = value & 255; - return fromIntRGBA(r, g, b, a); - } - Color2.fromCompositeARGB = fromCompositeARGB; -})(Color || (Color = {})); -var ColorFormat; -(function(ColorFormat2) { - ColorFormat2[ColorFormat2["DecRGBA"] = 0] = "DecRGBA"; - ColorFormat2[ColorFormat2["DecRGB"] = 1] = "DecRGB"; - ColorFormat2[ColorFormat2["IntRGBA"] = 2] = "IntRGBA"; - ColorFormat2[ColorFormat2["IntRGB"] = 3] = "IntRGB"; - ColorFormat2[ColorFormat2["HexRGBA"] = 4] = "HexRGBA"; - ColorFormat2[ColorFormat2["HexRGB"] = 5] = "HexRGB"; - ColorFormat2[ColorFormat2["CompositeRGB"] = 6] = "CompositeRGB"; - ColorFormat2[ColorFormat2["CompositeARGB"] = 7] = "CompositeARGB"; -})(ColorFormat || (ColorFormat = {})); -var ColorPresentation; -(function(ColorPresentation2) { - function fromColorFormat(format, color, range3) { - const presentation = colorPresentation(format, color); - return { label: presentation, text: presentation, range: range3 }; - } - ColorPresentation2.fromColorFormat = fromColorFormat; - function colorPresentation(format, color) { - const round = (num) => parseFloat(num.toFixed(3)); - switch (format) { - case ColorFormat.DecRGBA: - return color.map((c) => round(c)).join(" "); - case ColorFormat.DecRGB: - return color.slice(0, 3).map((c) => round(c)).join(" "); - case ColorFormat.IntRGBA: - return color.map((c) => Math.round(c * 255)).join(" "); - case ColorFormat.IntRGB: - return color.slice(0, 3).map((c) => Math.round(c * 255)).join(" "); - case ColorFormat.HexRGBA: - return `#${Math.round((color[0] * 255 << 24) + (color[1] * 255 << 16) + color[2] * 255 << 8 + color[3] * 255).toString(16).padStart(8, "0")}`; - case ColorFormat.HexRGB: - return `#${Math.round((color[0] * 255 << 16) + (color[1] * 255 << 8) + color[2] * 255).toString(16).padStart(6, "0")}`; - case ColorFormat.CompositeRGB: - return `${Math.round((color[0] * 255 << 16) + (color[1] * 255 << 8) + color[2] * 255)}`; - case ColorFormat.CompositeARGB: - return `${Number((BigInt(Math.round(color[3] * 255)) << 24n) + (BigInt(Math.round(color[0] * 255)) << 16n) + (BigInt(Math.round(color[1] * 255)) << 8n) + BigInt(Math.round(color[2] * 255))) << 0}`; - } - } -})(ColorPresentation || (ColorPresentation = {})); - -// node_modules/@spyglassmc/core/lib/processor/colorizer/builtin.js -var builtin_exports4 = {}; -__export(builtin_exports4, { - boolean: () => boolean, - comment: () => comment, - error: () => error, - fallback: () => fallback4, - literal: () => literal2, - number: () => number, - registerColorizers: () => registerColorizers, - resourceLocation: () => resourceLocation3, - string: () => string, - symbol: () => symbol3 -}); - -// node_modules/@spyglassmc/core/lib/processor/colorizer/Colorizer.js -var ColorToken; -(function(ColorToken2) { - function create(range3, type2, modifiers) { - return { range: Range.get(range3), type: type2, modifiers }; - } - ColorToken2.create = create; - function fillGap(tokens, targetRange, type2, modifiers) { - const ans = []; - let nextStart = Math.min(targetRange.start, tokens[0]?.range.start ?? Infinity); - for (const t of tokens) { - if (t.range.start > nextStart) { - ans.push(ColorToken2.create(Range.create(nextStart, t.range.start), type2, modifiers)); - } - ans.push(t); - nextStart = t.range.end; - } - if (nextStart < targetRange.end) { - ans.push(ColorToken2.create(Range.create(nextStart, targetRange.end), type2, modifiers)); - } - return ans; - } - ColorToken2.fillGap = fillGap; -})(ColorToken || (ColorToken = {})); -var ColorTokenTypes = Object.freeze([ - "comment", - "enum", - "enumMember", - "escape", - "function", - "keyword", - "modifier", - "number", - "property", - "string", - "struct", - "type", - "variable", - // Below are custom types. - "error", - "literal", - "operator", - "resourceLocation", - "vector" -]); -var ColorTokenModifiers = Object.freeze([ - "declaration", - "defaultLibrary", - "definition", - "deprecated", - "documentation", - "modification", - "readonly" - // Below are custom modifiers. -]); - -// node_modules/@spyglassmc/core/lib/processor/colorizer/builtin.js -var fallback4 = (node, ctx) => { - const ans = []; - traversePreOrder(node, (node2) => !ctx.meta.hasColorizer(node2.type) && (!ctx.range || Range.intersects(node2.range, ctx.range)), (node2) => ctx.meta.hasColorizer(node2.type), (node2) => { - const colorizer = ctx.meta.getColorizer(node2.type); - const result = colorizer(node2, ctx); - ans.push(...result); - }); - return Object.freeze(ans); -}; -var boolean = (node) => { - return [ColorToken.create(node, "literal")]; -}; -var comment = (node) => { - return [ColorToken.create(node, "comment")]; -}; -var error = (node) => { - return []; -}; -var literal2 = (node) => { - return [ColorToken.create(node, node.options.colorTokenType ?? "literal")]; -}; -var number = (node) => { - return [ColorToken.create(node, "number")]; -}; -var resourceLocation3 = (node, _ctx) => { - let type2; - switch (node.options.category) { - case "function": - case "tag/function": - type2 = "function"; - break; - default: - type2 = "resourceLocation"; - break; - } - return [ColorToken.create(node, type2)]; -}; -var string = (node, ctx) => { - if (node.children) { - const colorizer = ctx.meta.getColorizer(node.children[0].type); - const result = colorizer(node.children[0], ctx); - return ColorToken.fillGap(result, node.range, node.options.colorTokenType ?? "string"); - } else { - return [ColorToken.create(node, node.options.colorTokenType ?? "string")]; - } -}; -var symbol3 = (node) => { - return [ColorToken.create(node, "variable")]; -}; -function registerColorizers(meta) { - meta.registerColorizer("boolean", boolean); - meta.registerColorizer("comment", comment); - meta.registerColorizer("error", error); - meta.registerColorizer("float", number); - meta.registerColorizer("integer", number); - meta.registerColorizer("long", number); - meta.registerColorizer("literal", literal2); - meta.registerColorizer("resource_location", resourceLocation3); - meta.registerColorizer("string", string); - meta.registerColorizer("symbol", symbol3); -} - -// node_modules/@spyglassmc/core/lib/processor/completer/builtin.js -var builtin_exports5 = {}; -__export(builtin_exports5, { - boolean: () => boolean2, - dispatch: () => dispatch, - escapeString: () => escapeString, - fallback: () => fallback5, - file: () => file2, - literal: () => literal3, - noop: () => noop3, - record: () => record, - registerCompleters: () => registerCompleters, - resourceLocation: () => resourceLocation4, - string: () => string2, - symbol: () => symbol4 -}); -var import_binary_search3 = __toESM(require_binary_search(), 1); - -// node_modules/@spyglassmc/core/lib/processor/completer/Completer.js -var CompletionItem; -(function(CompletionItem2) { - function create(label, range3, other) { - const shouldEscape = other?.insertText === void 0 && needsEscape(label); - return { - ...other, - label, - range: Range.get(range3), - ...shouldEscape ? { insertText: escape(label) } : {} - }; - } - CompletionItem2.create = create; - function needsEscape(textToInsert) { - return /[\\$}]/.test(textToInsert); - } - CompletionItem2.needsEscape = needsEscape; - function escape(textToInsert) { - return textToInsert.replace(/([\\$}])/g, "\\$1"); - } - CompletionItem2.escape = escape; - function unescape(textToInsert) { - return textToInsert.replace(/\\([\\$}])/g, "$1"); - } - CompletionItem2.unescape = unescape; -})(CompletionItem || (CompletionItem = {})); -var InsertTextBuilder = class { - #ans = ""; - #nextPlaceholder = 1; - literal(str) { - this.#ans += CompletionItem.escape(str); - return this; - } - placeholder(...defaultValues) { - if (defaultValues.length === 0) { - this.#ans += `\${${this.#nextPlaceholder}}`; - } else if (defaultValues.length === 1) { - this.#ans += `\${${this.#nextPlaceholder}:${CompletionItem.escape(defaultValues[0])}}`; - } else { - this.#ans += `\${${this.#nextPlaceholder}|${defaultValues.map((v) => v.replace(/([\\$},|])/g, "\\$1")).join(",")}|}`; - } - this.#nextPlaceholder += 1; - return this; - } - exitPlace() { - this.#ans += "$0"; - return this; - } - build() { - return this.#ans; - } - if(condition, callback) { - if (condition) { - callback(this); - } - return this; - } -}; - -// node_modules/@spyglassmc/core/lib/processor/completer/builtin.js -var dispatch = (node, ctx) => { - const child = AstNode.findShallowestChild({ - node, - needle: ctx.offset, - endInclusive: true, - predicate: (n) => ctx.meta.hasCompleter(n.type) - }); - return child ? ctx.meta.getCompleter(child.type)(child, ctx) : []; -}; -var fallback5 = dispatch; -var boolean2 = (node, ctx) => { - return [ - CompletionItem.create("false", node, { - kind: 21 - /* CompletionKind.Constant */ - }), - CompletionItem.create("true", node, { - kind: 21 - /* CompletionKind.Constant */ - }) - ]; -}; -var file2 = (node, ctx) => { - const completer = ctx.meta.getCompleterForLanguageID(ctx.doc.languageId); - return completer(node.children[0], ctx); -}; -var literal3 = (node) => { - const kind = (/* @__PURE__ */ new Map([ - [ - "enum", - 13 - /* CompletionKind.Enum */ - ], - [ - "enumMember", - 20 - /* CompletionKind.EnumMember */ - ], - [ - "function", - 3 - /* CompletionKind.Function */ - ], - [ - "keyword", - 14 - /* CompletionKind.Keyword */ - ], - [ - "literal", - 14 - /* CompletionKind.Keyword */ - ], - [ - "number", - 21 - /* CompletionKind.Constant */ - ], - [ - "operator", - 24 - /* CompletionKind.Operator */ - ], - [ - "property", - 10 - /* CompletionKind.Property */ - ], - [ - "resourceLocation", - 17 - /* CompletionKind.File */ - ], - [ - "variable", - 6 - /* CompletionKind.Variable */ - ] - ])).get(node.options.colorTokenType ?? "keyword") ?? 14; - return node.options.pool.map((v) => CompletionItem.create(v, node, { kind })) ?? []; -}; -var noop3 = () => []; -var prefixed = (node, ctx) => { - const child = node.children.find((c) => c.type !== "literal"); - if (!child) { - return [CompletionItem.create("!", node)]; - } - const childItems = dispatch(child, ctx); - return childItems.map((item) => ({ - ...item, - label: node.prefix + item.label, - filterText: node.prefix + (item.filterText ?? item.label), - insertText: node.prefix + (item.insertText ?? item.label) - })); -}; -function record(o) { - return (node, ctx) => { - if (!node.innerRange || !Range.contains(node.innerRange, ctx.offset, true)) { - return []; - } - const completeKeys = (pair2) => o.key(node, pair2, ctx, pair2?.key ?? ctx.offset, false, false, existingKeys); - const completePairs = (pair2) => o.key(node, pair2, ctx, pair2 ?? ctx.offset, true, hasNextPair || !!pair2?.end, existingKeys); - const existingKeys = node.children.filter((n) => !!n.key).map((n) => n.key); - const index4 = (0, import_binary_search3.default)(node.children, ctx.offset, (n, o2) => n.end ? Range.compareOffset(Range.translate(n, 0, -1), o2, true) : Range.compareOffset(n.range, o2, true)); - const pair = index4 >= 0 ? node.children[index4] : void 0; - const hasNextPair = !!node.children.find((n) => n.range.start > ctx.offset); - if (!pair) { - return completePairs(void 0); - } - const { key: key2, sep: sep2, value } = pair; - if (!key2 && !sep2 && !value) { - return completePairs(void 0); - } - if (key2 && Range.contains(key2, ctx.offset, true) || sep2 && ctx.offset <= sep2.start) { - if (!value || Range.isEmpty(value.range)) { - return completePairs(pair); - } - return completeKeys(pair); - } - if (value && ctx.offset < value.range.start) { - return o.value(node, pair, ctx, ctx.offset); - } - if (value && Range.contains(value, ctx.offset, true) || sep2 && ctx.offset >= sep2.end || key2 && ctx.offset > key2.range.end) { - return o.value(node, pair, ctx, value ?? ctx.offset); - } - return []; - }; -} -var resourceLocation4 = (node, ctx) => { - const config = LinterConfigValue.destruct(ctx.config.lint.idOmitDefaultNamespace); - const includeEmptyNamespace = !node.options.requireCanonical && node.namespace === ""; - const includeDefaultNamespace = node.options.requireCanonical || config?.ruleValue !== true; - const excludeDefaultNamespace = !node.options.requireCanonical && config?.ruleValue !== false; - const getPool = (category) => { - const symbols = ctx.symbols.getVisibleSymbols(category, ctx.doc.uri); - const declarations = Object.entries(symbols).flatMap(([key2, symbol7]) => SymbolUtil.isDeclared(symbol7) ? [key2] : []); - return optimizePool(declarations); - }; - const optimizePool = (pool2) => { - const defaultNsPrefix = ResourceLocation.DefaultNamespace + ResourceLocation.NamespacePathSep; - const defaultNsIds = []; - const otherIds = []; - for (const id of filterPool(pool2)) { - if (id.startsWith(defaultNsPrefix)) { - defaultNsIds.push(id); - } else { - otherIds.push(id); - } - } - const ans = [ - ...otherIds, - ...includeDefaultNamespace ? defaultNsIds : [], - ...excludeDefaultNamespace ? defaultNsIds.map((id) => id.slice(defaultNsPrefix.length)) : [], - ...includeEmptyNamespace ? defaultNsIds.map((id) => id.slice(ResourceLocation.DefaultNamespace.length)) : [] - ]; - if (node.options.namespacePathSep === ".") { - return ans.map((v) => v.replace(ResourceLocation.NamespacePathSep, ".")); - } - return ans; - }; - const filterPool = (pool2) => { - if (!node.options.implicitPath) { - return pool2; - } - const ans = []; - for (const id of pool2) { - const sep2 = id.indexOf(ResourceLocation.NamespacePathSep); - const path6 = id.slice(sep2 + 1); - if (path6.startsWith(node.options.implicitPath)) { - ans.push(id.slice(0, sep2 + 1) + path6.slice(node.options.implicitPath.length)); - } - } - return ans; - }; - const pool = node.options.pool ? optimizePool(node.options.pool) : [ - ...!node.options.requireTag ? getPool(node.options.category) : [], - ...node.options.allowTag ? getPool(`tag/${node.options.category}`).map((v) => `${ResourceLocation.TagPrefix}${v}`) : [] - ]; - const items = pool.map((v) => CompletionItem.create(v, node, { - kind: 3 - /* CompletionKind.Function */ - })); - if (node.options.category) { - const symbols = ctx.symbols.getVisibleSymbols(node.options.category, ctx.doc.uri); - const thisKey = Object.entries(symbols).flatMap(([key2, symbol7]) => { - if ((symbol7.declaration?.[0] ?? symbol7.definition?.[0])?.uri === ctx.doc.uri) { - return [key2]; - } - return []; - }); - if (thisKey.length > 0) { - items.push(CompletionItem.create("THIS", node, { - kind: 15, - insertText: thisKey[0], - detail: thisKey[0] - })); - } - } - return items; -}; -var string2 = (node, ctx) => { - if (node.children?.length) { - return dispatch(node.children[0], ctx).map((item) => ({ - ...item, - filterText: escapeString(item.filterText ?? item.label, node.quote), - insertText: escapeString(item.insertText ?? item.label, node.quote) - })); - } - if (node.options.quotes && node.value === "") { - return node.options.quotes.map((q) => CompletionItem.create(`${q}${q}`, node, { - insertText: `${q}$1${q}`, - kind: 12 - })); - } - return []; -}; -function escapeString(value, quote2) { - if (!quote2) { - return value; - } - value = CompletionItem.unescape(value); - value = value.replaceAll("\\", "\\\\").replaceAll(quote2, '\\"'); - return CompletionItem.escape(value); -} -var symbol4 = (node, ctx) => { - const path6 = node.options.parentPath ?? []; - const symbols = ctx.symbols.query(ctx.doc, node.options.category, ...path6).visibleMembers; - return Object.entries(symbols).filter(([k, v]) => SymbolUtil.isDeclared(v)).map(([k, v]) => CompletionItem.create(k, node, { - kind: 6 - /* CompletionKind.Variable */ - })); -}; -function registerCompleters(meta) { - meta.registerCompleter("boolean", boolean2); - meta.registerCompleter("comment", noop3); - meta.registerCompleter("float", noop3); - meta.registerCompleter("integer", noop3); - meta.registerCompleter("long", noop3); - meta.registerCompleter("literal", literal3); - meta.registerCompleter("prefixed", prefixed); - meta.registerCompleter("resource_location", resourceLocation4); - meta.registerCompleter("string", string2); - meta.registerCompleter("symbol", symbol4); -} - -// node_modules/@spyglassmc/core/lib/processor/formatter/builtin.js -var builtin_exports6 = {}; -__export(builtin_exports6, { - boolean: () => boolean3, - comment: () => comment2, - error: () => error2, - fallback: () => fallback6, - file: () => file3, - float: () => float, - integer: () => integer, - literal: () => literal4, - long: () => long, - registerFormatters: () => registerFormatters, - resourceLocation: () => resourceLocation5, - string: () => string3 -}); -var fallback6 = (node) => { - throw new Error(`No formatter registered for type ${node.type}`); -}; -var error2 = (node) => { - return ""; -}; -var file3 = (node, ctx) => { - return node.children.map((child) => { - return ctx.meta.getFormatter(child.type)(child, ctx); - }).join(""); -}; -var boolean3 = (node) => { - return node.value ? "true" : "false"; -}; -var comment2 = (node) => { - return node.prefix + node.comment; -}; -var float = (node) => { - return node.value.toString(); -}; -var integer = (node) => { - return node.value.toFixed(); -}; -var literal4 = (node) => { - return node.value; -}; -var long = (node) => { - return node.value.toString(); -}; -var resourceLocation5 = (node) => { - return ResourceLocationNode.toString(node, "origin", true); -}; -var string3 = (node) => { - return `"${node.value}"`; -}; -function registerFormatters(meta) { - meta.registerFormatter("error", error2); - meta.registerFormatter("file", file3); - meta.registerFormatter("boolean", boolean3); - meta.registerFormatter("comment", comment2); - meta.registerFormatter("float", float); - meta.registerFormatter("integer", integer); - meta.registerFormatter("long", long); - meta.registerFormatter("literal", literal4); - meta.registerFormatter("resource_location", resourceLocation5); - meta.registerFormatter("string", string3); -} - -// node_modules/@spyglassmc/core/lib/processor/formatter/Formatter.js -function formatterContextIndentation(ctx, additionalLevels = 0) { - const total = ctx.indentLevel + additionalLevels; - return ctx.insertSpaces ? " ".repeat(total * ctx.tabSize) : " ".repeat(total); -} -function indentFormatter(ctx, additionalLevels = 1) { - return { - ...ctx, - indentLevel: ctx.indentLevel + additionalLevels, - indent(additionalLevels2) { - return formatterContextIndentation(this, additionalLevels2); - } - }; -} - -// node_modules/@spyglassmc/core/lib/processor/linter/builtin.js -var builtin_exports7 = {}; -__export(builtin_exports7, { - configValidator: () => configValidator, - nameConvention: () => nameConvention, - noop: () => noop4, - quote: () => quote, - registerLinters: () => registerLinters -}); - -// node_modules/@spyglassmc/core/lib/processor/linter/builtin/undeclaredSymbol.js -var undeclaredSymbol = (node, ctx) => { - if (!node.symbol || SymbolUtil.isDeclared(node.symbol)) { - return; - } - const action = getAction(ctx.ruleValue, node.symbol, ctx); - if (SymbolLinterConfig.Action.isDeclare(action)) { - ctx.symbols.query({ doc: ctx.doc, node }, node.symbol.category, ...node.symbol.path).amend({ - data: { visibility: getVisibility(action.declare) }, - usage: { type: "declaration", node } - }); - } - if (SymbolLinterConfig.Action.isReport(action)) { - const info = {}; - const uriBuilder2 = ctx.meta.getUriBuilder(node.symbol.category); - if (uriBuilder2) { - const uri = uriBuilder2(node.symbol.identifier, ctx); - if (uri) { - info.codeAction = { - title: localize("code-action.create-undeclared-file", node.symbol.category, localeQuote(node.symbol.identifier)), - changes: [{ type: "create", uri }] - }; - } - } - const severityOverride = action.report === "inherit" ? void 0 : LinterSeverity.toErrorSeverity(action.report); - ctx.err.lint(localize("linter.undeclared-symbol.message", node.symbol.category, localeQuote(node.symbol.identifier)), node, info, severityOverride); - } -}; -function getAction(config, symbol7, ctx) { - if (SymbolLinterConfig.Action.is(config)) { - return config; - } - function test(conditions) { - function testSingleCondition(condition) { - const resourceLocation7 = ResourceLocation.lengthen(symbol7.identifier); - const namespace = resourceLocation7.slice(0, resourceLocation7.indexOf(ResourceLocation.NamespacePathSep)); - return (condition.category ? Arrayable.toArray(condition.category).includes(symbol7.category) : true) && (condition.namespace ? Arrayable.toArray(condition.namespace).includes(namespace) : true) && (condition.excludeNamespace ? !Arrayable.toArray(condition.excludeNamespace).includes(namespace) : true) && (condition.pattern ? Arrayable.toArray(condition.pattern).some((p) => new RegExp(p).test(symbol7.identifier)) : true) && (condition.excludePattern ? !Arrayable.toArray(condition.excludePattern).some((p) => new RegExp(p).test(symbol7.identifier)) : true); - } - try { - return Arrayable.toArray(conditions).some(testSingleCondition); - } catch (e) { - ctx.logger.error("[undeclaredSymbol#getAction] Likely encountered an illegal regular expression in the config", e); - return false; - } - } - function evaluateComplexes(complexes) { - for (const complex of Arrayable.toArray(complexes)) { - if (complex.if && !test(complex.if)) { - continue; - } - return complex.override ? evaluateComplexes(complex.override) ?? complex.then : complex.then; - } - return void 0; - } - return evaluateComplexes(config); -} -function getVisibility(input) { - switch (input) { - case "block": - return 0; - case "file": - return 1; - case "public": - return 2; - } -} - -// node_modules/@spyglassmc/core/lib/processor/linter/builtin.js -var noop4 = () => { -}; -function nameConvention(key2) { - return (node, ctx) => { - if (typeof node[key2] !== "string") { - throw new Error(`Trying to access property "${key2}" of node type "${node.type}"`); - } - const name = node[key2]; - try { - const regex = new RegExp(ctx.ruleValue); - if (!name.match(regex)) { - ctx.err.lint(localize("linter.name-convention.illegal", localeQuote(name), localeQuote(ctx.ruleValue)), node); - } - } catch (e) { - ctx.logger.error(`[nameConvention linter] The value \u201C${ctx.ruleValue}\u201D set for rule \u201C${ctx.ruleName}\u201D is not a valid regular expression.`, e); - } - }; -} -var quote = (node, ctx) => { - const config = ctx.ruleValue; - const mustValueBeQuoted = node.options.unquotable ? [...node.value].some((c) => !isAllowedCharacter(c, node.options.unquotable)) : true; - const isQuoteRequired = config.always || mustValueBeQuoted; - const isQuoteProhibited = config.always === false && !mustValueBeQuoted; - const firstChar = ctx.src.slice(node.range.start, node.range.start + 1); - const isFirstCharQuote = !!node.options.quotes?.includes(firstChar); - if (isQuoteRequired) { - if (isFirstCharQuote) { - config.avoidEscape; - config.type; - } else { - } - } else if (isQuoteProhibited && isFirstCharQuote) { - } -}; -var configValidator; -(function(configValidator2) { - function getDocLink(name) { - return `https://spyglassmc.com/user/lint/${name}`; - } - function wrapError(name, msg) { - return `[Invalid Linter Config] [${name}] ${localize("linter-config-validator.wrapper", msg, getDocLink(name))}`; - } - function nameConvention2(name, val, logger) { - if (typeof val !== "string") { - logger.error(wrapError(name, localize("linter-config-validator.name-convention.type"))); - return false; - } - try { - new RegExp(val); - } catch (e) { - logger.error(wrapError(name, localize("")), e); - return false; - } - return true; - } - configValidator2.nameConvention = nameConvention2; - function symbolLinterConfig(_name, value, _logger) { - return SymbolLinterConfig.is(value); - } - configValidator2.symbolLinterConfig = symbolLinterConfig; -})(configValidator || (configValidator = {})); -function registerLinters(meta) { - meta.registerLinter("nameOfObjective", { - configValidator: configValidator.nameConvention, - linter: nameConvention("value"), - nodePredicate: (n) => n.symbol && n.symbol.category === "objective" - }); - meta.registerLinter("nameOfScoreHolder", { - configValidator: configValidator.nameConvention, - linter: nameConvention("value"), - nodePredicate: (n) => n.symbol && n.symbol.category === "score_holder" - }); - meta.registerLinter("nameOfTag", { - configValidator: configValidator.nameConvention, - linter: nameConvention("value"), - nodePredicate: (n) => n.symbol && n.symbol.category === "tag" - }); - meta.registerLinter("nameOfTeam", { - configValidator: configValidator.nameConvention, - linter: nameConvention("value"), - nodePredicate: (n) => n.symbol && n.symbol.category === "team" - }); - meta.registerLinter("undeclaredSymbol", { - configValidator: configValidator.symbolLinterConfig, - linter: undeclaredSymbol, - nodePredicate: (n) => n.symbol && !McdocCategories.includes(n.symbol.category) - }); -} - -// node_modules/@spyglassmc/core/lib/service/ErrorReporter.js -var ErrorReporter = class { - source; - errors = []; - constructor(source) { - this.source = source; - } - /** - * Reports a new error. - */ - report(message2, range3, severity = ErrorSeverity.Error, info) { - if (message2.trim() === "") { - throw new Error("Tried to report an error with no message"); - } - this.errors.push(LanguageError.create(message2, Range.get(range3), severity, info, this.source)); - } - /** - * @returns All reported errors, and then clears the error stack. - */ - dump() { - const ans = Object.freeze(this.errors); - this.errors = []; - return ans; - } - /** - * Adds all errors from another reporter's error stack to the current reporter. - * This method does not affect the passed-in reporter. - */ - absorb(reporter) { - this.errors.push(...reporter.errors); - } -}; -var LinterErrorReporter = class _LinterErrorReporter extends ErrorReporter { - ruleName; - ruleSeverity; - constructor(ruleName, ruleSeverity, source) { - super(source); - this.ruleName = ruleName; - this.ruleSeverity = ruleSeverity; - } - lint(message2, range3, info, severityOverride) { - return this.report(localize("linter.diagnostic-message-wrapper", message2, this.ruleName), range3, severityOverride ?? this.ruleSeverity, info); - } - static fromErrorReporter(reporter, ruleName, ruleSeverity) { - const ans = new _LinterErrorReporter(ruleName, ruleSeverity, reporter.source); - ans.errors = reporter.errors; - return ans; - } -}; - -// node_modules/@spyglassmc/core/lib/service/Context.js -var ContextBase; -(function(ContextBase2) { - function create(project) { - return { - fs: project.fs, - isDebugging: project.isDebugging, - logger: project.logger, - meta: project.meta, - profilers: project.profilers, - roots: project.roots, - project: project.ctx - }; - } - ContextBase2.create = create; -})(ContextBase || (ContextBase = {})); -var ParserContext; -(function(ParserContext2) { - function create(project, opts) { - return { - ...ContextBase.create(project), - config: project.config, - doc: opts.doc, - err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]) - }; - } - ParserContext2.create = create; -})(ParserContext || (ParserContext = {})); -var ProcessorContext; -(function(ProcessorContext2) { - function create(project, opts) { - return { - ...ContextBase.create(project), - config: project.config, - doc: opts.doc, - src: opts.src ?? new ReadonlySource(opts.doc.getText()), - symbols: project.symbols - }; - } - ProcessorContext2.create = create; -})(ProcessorContext || (ProcessorContext = {})); -var ProcessorWithRangeContext; -(function(ProcessorWithRangeContext2) { - function create(project, opts) { - return { ...ProcessorContext.create(project, opts), range: opts.range }; - } - ProcessorWithRangeContext2.create = create; -})(ProcessorWithRangeContext || (ProcessorWithRangeContext = {})); -var ProcessorWithOffsetContext; -(function(ProcessorWithOffsetContext2) { - function create(project, opts) { - return { ...ProcessorContext.create(project, opts), offset: opts.offset }; - } - ProcessorWithOffsetContext2.create = create; -})(ProcessorWithOffsetContext || (ProcessorWithOffsetContext = {})); -var BinderContext; -(function(BinderContext2) { - function create(project, opts) { - return { - ...ProcessorContext.create(project, opts), - err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]), - ensureBindingStarted: project.ensureBindingStarted?.bind(project) - }; - } - BinderContext2.create = create; -})(BinderContext || (BinderContext = {})); -var CheckerContext; -(function(CheckerContext2) { - function create(project, opts) { - return { - ...ProcessorContext.create(project, opts), - err: opts.err ?? new ErrorReporter(project.ctx["errorSource"]), - ensureBindingStarted: project.ensureBindingStarted?.bind(project) - }; - } - CheckerContext2.create = create; -})(CheckerContext || (CheckerContext = {})); -var LinterContext; -(function(LinterContext2) { - function create(project, opts) { - return { - ...ProcessorContext.create(project, opts), - err: opts.err, - ruleName: opts.ruleName, - ruleValue: opts.ruleValue - }; - } - LinterContext2.create = create; -})(LinterContext || (LinterContext = {})); -var FormatterContext; -(function(FormatterContext2) { - function create(project, opts) { - return { - ...ProcessorContext.create(project, opts), - ...opts, - indentLevel: 0, - indent(additionalLevels) { - return formatterContextIndentation(this, additionalLevels); - } - }; - } - FormatterContext2.create = create; -})(FormatterContext || (FormatterContext = {})); -var CodeActionProviderContext; -(function(CodeActionProviderContext2) { - function create(project, opts) { - return { ...ProcessorContext.create(project, opts), range: opts.range }; - } - CodeActionProviderContext2.create = create; -})(CodeActionProviderContext || (CodeActionProviderContext = {})); -var ColorizerContext; -(function(ColorizerContext2) { - function create(project, opts) { - return ProcessorWithRangeContext.create(project, opts); - } - ColorizerContext2.create = create; -})(ColorizerContext || (ColorizerContext = {})); -var CompleterContext; -(function(CompleterContext2) { - function create(project, opts) { - return { - ...ProcessorContext.create(project, opts), - offset: opts.offset, - triggerCharacter: opts.triggerCharacter - }; - } - CompleterContext2.create = create; -})(CompleterContext || (CompleterContext = {})); -var SignatureHelpProviderContext; -(function(SignatureHelpProviderContext2) { - function create(project, opts) { - return ProcessorWithOffsetContext.create(project, opts); - } - SignatureHelpProviderContext2.create = create; -})(SignatureHelpProviderContext || (SignatureHelpProviderContext = {})); -var UriBinderContext; -(function(UriBinderContext2) { - function create(project) { - return { ...ContextBase.create(project), config: project.config, symbols: project.symbols }; - } - UriBinderContext2.create = create; -})(UriBinderContext || (UriBinderContext = {})); -var UriPredicateContext; -(function(UriPredicateContext2) { - function create(project) { - return { ...ContextBase.create(project) }; - } - UriPredicateContext2.create = create; -})(UriPredicateContext || (UriPredicateContext = {})); - -// node_modules/@spyglassmc/core/lib/service/Dependency.js -var DependencyKey; -(function(DependencyKey2) { - function is(value) { - return value.startsWith("@"); - } - DependencyKey2.is = is; -})(DependencyKey || (DependencyKey = {})); - -// node_modules/@spyglassmc/core/lib/service/fetcher.js -var FETCH_TIMEOUT_MS = 3e4; -async function fetchWithCache({ web }, logger, input, init) { - const cache = await web.getCache(); - const request = new Request(input, init); - const cachedResponse = await cache.match(request); - const cachedEtag = cachedResponse?.headers.get("ETag"); - if (cachedEtag) { - request.headers.set("If-None-Match", cachedEtag); - } - request.headers.set("User-Agent", "SpyglassMC (+https://spyglassmc.com)"); - try { - const response = await fetch(request, { signal: AbortSignal.timeout(FETCH_TIMEOUT_MS) }); - if (response.status === 304) { - Dev.assertDefined(cachedResponse); - logger.info(`[fetchWithCache] reusing cache for ${request.url}`); - return cachedResponse; - } else if (!response.ok) { - let message2 = response.statusText; - try { - message2 = (await response.json()).message; - } catch { - } - throw new TypeError(`${response.status} ${message2}`); - } else { - try { - await cache.put(request, response.clone()); - logger.info(`[fetchWithCache] updated cache for ${request.url}`); - } catch (e) { - logger.warn("[fetchWithCache] put cache", e); - } - return response; - } - } catch (e) { - logger.warn("[fetchWithCache] fetch", e); - if (cachedResponse) { - logger.info(`[fetchWithCache] falling back to cache for ${request.url}`); - return cachedResponse; - } - throw e; - } -} - -// node_modules/@spyglassmc/core/lib/service/Hover.js -var Hover; -(function(Hover2) { - function create(range3, markdown) { - return { range: Range.get(range3), markdown }; - } - Hover2.create = create; -})(Hover || (Hover = {})); - -// node_modules/@spyglassmc/core/lib/service/MetaRegistry.js -var MetaRegistry = class { - /** - * A map from language IDs to language options. - */ - #languages = /* @__PURE__ */ new Map(); - #binders = /* @__PURE__ */ new Map(); - #checkers = /* @__PURE__ */ new Map(); - #colorizers = /* @__PURE__ */ new Map(); - #codeActionProviders = /* @__PURE__ */ new Map(); - #completers = /* @__PURE__ */ new Map(); - #dependencyProviders = /* @__PURE__ */ new Map(); - #formatters = /* @__PURE__ */ new Map(); - #inlayHintProviders = /* @__PURE__ */ new Set(); - #linters = /* @__PURE__ */ new Map(); - #parsers = /* @__PURE__ */ new Map(); - #signatureHelpProviders = /* @__PURE__ */ new Set(); - #symbolRegistrars = /* @__PURE__ */ new Map(); - #custom = /* @__PURE__ */ new Map(); - #uriBinders = /* @__PURE__ */ new Set(); - #uriBuilders = /* @__PURE__ */ new Map(); - #uriSorter = () => 0; - constructor() { - builtin_exports.registerBinders(this); - builtin_exports2.registerCheckers(this); - builtin_exports3.registerProviders(this); - builtin_exports4.registerColorizers(this); - builtin_exports5.registerCompleters(this); - builtin_exports6.registerFormatters(this); - builtin_exports7.registerLinters(this); - } - /** - * Registers a new language. - * @param languageID The language ID. e.g. `"mcfunction"` - * @param options The language options for this language. - */ - registerLanguage(languageID, options2) { - this.#languages.set(languageID, options2); - } - /** - * An array of all registered language IDs. - */ - getLanguages() { - return Array.from(this.#languages.keys()); - } - getLanguageOptions(language2) { - return this.#languages.get(language2); - } - /** - * An array of characters that trigger a completion request. - */ - getTriggerCharacters() { - return Array.from(this.#languages.values()).flatMap((v) => v.triggerCharacters ?? []); - } - /** - * @param fileExtension The file extension including the leading dot. e.g. `".mcfunction"`. - * @returns The language ID registered for the file extension, or `undefined`. - */ - getLanguageID(fileExtension) { - for (const [languageID, { extensions }] of this.#languages) { - if (extensions.includes(fileExtension)) { - return languageID; - } - } - return void 0; - } - hasBinder(type2) { - return this.#binders.has(type2); - } - getBinder(type2) { - return this.#binders.get(type2) ?? builtin_exports.fallback; - } - registerBinder(type2, binder) { - this.#binders.set(type2, binder); - } - hasChecker(type2) { - return this.#checkers.has(type2); - } - getChecker(type2) { - return this.#checkers.get(type2) ?? builtin_exports2.fallback; - } - registerChecker(type2, checker) { - this.#checkers.set(type2, checker); - } - hasCodeActionProvider(type2) { - return this.#codeActionProviders.has(type2); - } - getCodeActionProvider(type2) { - return this.#codeActionProviders.get(type2) ?? builtin_exports3.fallback; - } - registerCodeActionProvider(type2, codeActionProvider) { - this.#codeActionProviders.set(type2, codeActionProvider); - } - hasColorizer(type2) { - return this.#colorizers.has(type2); - } - getColorizer(type2) { - return this.#colorizers.get(type2) ?? builtin_exports4.fallback; - } - registerColorizer(type2, colorizer) { - this.#colorizers.set(type2, colorizer); - } - hasCompleter(type2) { - return this.#completers.has(type2); - } - getCompleter(type2) { - return this.#completers.get(type2) ?? builtin_exports5.fallback; - } - registerCompleter(type2, completer) { - this.#completers.set(type2, completer); - } - shouldComplete(languageID, triggerCharacter) { - const language2 = this.#languages.get(languageID); - return !triggerCharacter || !!language2?.triggerCharacters?.includes(triggerCharacter); - } - getCompleterForLanguageID(languageID) { - return this.#languages.get(languageID)?.completer ?? builtin_exports5.fallback; - } - getDependencyProvider(key2) { - return this.#dependencyProviders.get(key2); - } - registerDependencyProvider(key2, provider) { - this.#dependencyProviders.set(key2, provider); - } - hasFormatter(type2) { - return this.#formatters.has(type2); - } - getFormatter(type2) { - return this.#formatters.get(type2) ?? builtin_exports6.fallback; - } - registerFormatter(type2, formatter) { - this.#formatters.set(type2, formatter); - } - registerInlayHintProvider(provider) { - this.#inlayHintProviders.add(provider); - } - get inlayHintProviders() { - return this.#inlayHintProviders; - } - getLinter(ruleName) { - return this.#linters.get(ruleName) ?? { configValidator: () => false, linter: builtin_exports7.noop, nodePredicate: () => false }; - } - registerLinter(ruleName, options2) { - this.#linters.set(ruleName, options2); - } - hasParser(id) { - return this.#parsers.has(id); - } - getParser(id) { - const ans = this.#parsers.get(id); - if (!ans) { - throw new Error(`There is no parser '${id}'`); - } - return ans; - } - getParserLazily(id) { - return Lazy.create(() => this.getParser(id)); - } - registerParser(id, parser) { - this.#parsers.set(id, parser); - } - /** - * @returns The corresponding `Parser` for the language ID. - * @throws If there's no such language in the registry. - */ - getParserForLanguageId(languageID) { - if (this.#languages.has(languageID)) { - return this.#languages.get(languageID).parser; - } - throw new Error(`There is no parser registered for language ID '${languageID}'`); - } - registerSignatureHelpProvider(provider) { - this.#signatureHelpProviders.add(provider); - } - get signatureHelpProviders() { - return this.#signatureHelpProviders; - } - registerSymbolRegistrar(id, registrar) { - this.#symbolRegistrars.set(id, registrar); - } - get symbolRegistrars() { - return this.#symbolRegistrars; - } - registerCustom(group, id, object5) { - let groupRegistry = this.#custom.get(group); - if (!groupRegistry) { - groupRegistry = /* @__PURE__ */ new Map(); - this.#custom.set(group, groupRegistry); - } - groupRegistry.set(id, object5); - } - getCustom(group) { - return this.#custom.get(group); - } - registerUriBinder(uriBinder3) { - this.#uriBinders.add(uriBinder3); - } - get uriBinders() { - return this.#uriBinders; - } - hasUriBuilder(category) { - return this.#uriBuilders.has(category); - } - getUriBuilder(category) { - return this.#uriBuilders.get(category); - } - registerUriBuilder(category, builder) { - this.#uriBuilders.set(category, builder); - } - setUriSorter(uriSorter2) { - const nextSorter = this.#uriSorter; - this.#uriSorter = (a, b) => uriSorter2(a, b, nextSorter); - } - get uriSorter() { - return this.#uriSorter; - } -}; - -// node_modules/@spyglassmc/core/lib/service/Profiler.js -var TopNImpl = class { - id; - logger; - n; - #finalized = false; - #startTime; - #lastTime; - #taskCount = 0; - #topTasks = []; - #minTime = Infinity; - #maxTime = 0; - constructor(id, logger, n) { - this.id = id; - this.logger = logger; - this.n = n; - this.#startTime = this.#lastTime = performance.now(); - } - task(name) { - if (this.#finalized) { - throw new Error("The profiler has already been finalized"); - } - this.#taskCount++; - const time2 = performance.now(); - const duration = time2 - this.#lastTime; - this.#lastTime = time2; - this.#minTime = Math.min(this.#minTime, duration); - this.#maxTime = Math.max(this.#maxTime, duration); - this.#topTasks.push([name, duration]); - this.#topTasks.sort((a, b) => b[1] - a[1]); - if (this.#topTasks.length > this.n) { - this.#topTasks = this.#topTasks.slice(0, -1); - } - return this; - } - finalize() { - this.#finalized = true; - const longestTaskNameLength = this.#topTasks.reduce((length, [name]) => Math.max(length, name.length), 0); - const totalDuration = this.#lastTime - this.#startTime; - this.logger.info(`[Profiler: ${this.id}] == Summary ==`); - this.logger.info(`[Profiler: ${this.id}] Total tasks: ${this.#taskCount} done in ${totalDuration} ms`); - this.logger.info(`[Profiler: ${this.id}] Min/Avg/Max: ${this.#minTime} / ${totalDuration / this.#taskCount} / ${this.#maxTime} ms`); - this.logger.info(`[Profiler: ${this.id}] Top ${Math.min(this.n, this.#topTasks.length)} task(s):`); - for (const [name, time2] of this.#topTasks) { - this.logger.info(`[Profiler: ${this.id}] ${name}${" ".repeat(longestTaskNameLength - name.length)} - ${time2} ms (${time2 / totalDuration * 100}%)`); - } - } -}; -var TotalTaskName = "Total"; -var TotalImpl = class { - id; - logger; - #finalized = false; - #startTime; - #lastTime; - #tasks = []; - #longestTaskNameLength = 0; - constructor(id, logger) { - this.id = id; - this.logger = logger; - this.#startTime = this.#lastTime = performance.now(); - } - task(name) { - if (this.#finalized) { - throw new Error("The profiler is finalized."); - } - const time2 = performance.now(); - const duration = time2 - this.#lastTime; - this.#lastTime = time2; - this.#tasks.push([name, duration]); - this.#longestTaskNameLength = Math.max(this.#longestTaskNameLength, name.length); - this.logger.info(`[Profiler: ${this.id}] Done: ${name} in ${duration} ms`); - return this; - } - finalize() { - this.#finalized = true; - this.#tasks.push([TotalTaskName, this.#lastTime - this.#startTime]); - this.#longestTaskNameLength = Math.max(this.#longestTaskNameLength, TotalTaskName.length); - this.logger.info(`[Profiler: ${this.id}] == Summary ==`); - for (const [name, time2] of this.#tasks) { - this.logger.info(`[Profiler: ${this.id}] ${name}${" ".repeat(this.#longestTaskNameLength - name.length)} - ${time2} ms`); - } - } -}; -var NoopImpl = class { - task() { - return this; - } - finalize() { - } -}; -var ProfilerFactory = class _ProfilerFactory { - logger; - #enabledProfilers; - constructor(logger, enabledProfilers) { - this.logger = logger; - this.#enabledProfilers = new Set(enabledProfilers); - } - get(id, style = "total", n) { - if (this.#enabledProfilers.has(id)) { - switch (style) { - case "top-n": - return new TopNImpl(id, this.logger, n); - case "total": - return new TotalImpl(id, this.logger); - default: - return Dev.assertNever(style); - } - } else { - return new NoopImpl(); - } - } - static noop() { - return new _ProfilerFactory(Logger.noop(), []); - } -}; - -// node_modules/@spyglassmc/core/lib/service/Project.js -var import_picomatch = __toESM(require_picomatch2(), 1); -var __decorate2 = function(decorators, target, key2, desc) { - var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key2) : desc, d; - if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key2, desc); - else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key2, r) : d(target, key2)) || r; - return c > 3 && r && Object.defineProperty(target, key2, r), r; -}; -var CacheAutoSaveInterval = 6e5; -var Project = class _Project extends EventDispatcher { - static RootSuffix = "/pack.mcmeta"; - /** Prevent circular binding. */ - #bindingInProgressUris = /* @__PURE__ */ new Set(); - #cacheSaverIntervalId; - cacheService; - /** URI of files that are currently managed by the language client. */ - #clientManagedUris = /* @__PURE__ */ new Set(); - #clientManagedDocAndNodes = /* @__PURE__ */ new Map(); - #configService; - #symbolUpToDateUris = /* @__PURE__ */ new Set(); - #initializers; - #watcher; - get watchedFiles() { - return this.#watcher?.watchedFiles ?? new UriStore(); - } - #initPromise; - #readyPromise; - #isInitialized = false; - #isReady = false; - get isReady() { - return this.#isReady; - } - config; - externals; - fs; - isDebugging; - logger; - meta = new MetaRegistry(); - profilers; - projectRoots; - symbols; - #dependencyRoots; - #dependencyFiles; - #roots = []; - /** - * All tracked root URIs. Each URI in this array is guaranteed to end with a slash (`/`). - * - * Includes the roots of all dependencies, the project root, and all data pack roots identified - * by `pack.mcmeta` files. - * - * Some URIs in the array may overlap with each other. In such cases, the deeper ones are guaranteed to come - * before the shallower ones (e.g. `file:///foo/bar/` will come before `file:///foo/`). - */ - get roots() { - return this.#roots; - } - #ctx; - /** - * Arbitrary information that will be included in the `project` property of all `Context`s. - */ - get ctx() { - return this.#ctx; - } - #cacheRoot; - /** - * File URI to a directory where all cache files of Spyglass should be stored. - */ - get cacheRoot() { - return this.#cacheRoot; - } - updateRoots() { - const rawRoots = [...this.#dependencyRoots ?? [], ...this.projectRoots]; - const ans = new Set(rawRoots); - for (const file9 of this.getTrackedFiles()) { - if (file9.endsWith(_Project.RootSuffix) && rawRoots.some((r) => file9.startsWith(r))) { - ans.add(file9.slice(0, 1 - _Project.RootSuffix.length)); - } - } - this.#roots = [...ans].sort((a, b) => b.length - a.length); - this.emit("rootsUpdated", { roots: this.#roots }); - } - /** - * Get all files that are tracked and supported. - * - * Files in cached archives may not show up in the result as those files - * are not loaded into the memory. - */ - getTrackedFiles() { - const supportedFiles = [...this.#dependencyFiles ?? [], ...this.watchedFiles]; - this.logger.info(`[Project#getTrackedFiles] Listed ${supportedFiles.length} supported files`); - return supportedFiles; - } - constructor({ cacheRoot, defaultConfig, externals, fs: fs2 = FileService.create(externals, cacheRoot), initializers = [], isDebugging = false, logger = Logger.create(), profilers = ProfilerFactory.noop(), projectRoots }) { - super(); - this.#cacheRoot = cacheRoot; - this.externals = externals; - this.fs = fs2; - this.#initializers = initializers; - this.isDebugging = isDebugging; - this.logger = logger; - this.profilers = profilers; - this.projectRoots = projectRoots; - this.cacheService = new CacheService(cacheRoot, this); - this.#configService = new ConfigService(this, defaultConfig); - this.symbols = new SymbolUtil({}); - this.#ctx = {}; - this.logger.info(`[Project] [init] cacheRoot = ${cacheRoot}`); - this.logger.info(`[Project] [init] projectRoots = ${projectRoots.join(" ")}`); - this.#configService.on("changed", ({ config }) => { - const oldConfig = this.config; - this.config = config; - this.logger.info("[Project] [Config] Changed"); - this.emit("configChanged", { oldConfig, newConfig: config }); - }).on("error", ({ error: error4, uri }) => this.logger.error(`[Project] [Config] Failed loading ${uri}`, error4)); - this.#cacheSaverIntervalId = setInterval(() => this.cacheService.save(), CacheAutoSaveInterval); - this.on("documentUpdated", ({ doc, node }) => { - this.emit("documentErrored", { - errors: FileNode.getErrors(node).map((e) => LanguageError.withPosRange(e, doc)), - uri: doc.uri, - version: doc.version - }); - }).on("documentRemoved", ({ uri }) => { - this.emit("documentErrored", { errors: [], uri }); - }).on("fileCreated", async ({ uri }) => { - if (uri.endsWith(_Project.RootSuffix)) { - this.updateRoots(); - } - this.bindUri(uri); - return this.ensureBindingStarted(uri); - }).on("fileModified", async ({ uri }) => { - this.#symbolUpToDateUris.delete(uri); - if (this.isOnlyWatched(uri)) { - await this.ensureBindingStarted(uri); - } - }).on("fileDeleted", ({ uri }) => { - if (uri.endsWith(_Project.RootSuffix)) { - this.updateRoots(); - } - this.#symbolUpToDateUris.delete(uri); - this.symbols.clear({ uri }); - this.tryClearingCache(uri); - }).on("ready", () => { - this.#isReady = true; - const promises = []; - for (const { doc, node } of this.#clientManagedDocAndNodes.values()) { - promises.push(this.bind(doc, node).then(() => this.check(doc, node))); - } - Promise.all(promises).catch((e) => this.logger.error("[Project#ready] Error occurred when rechecking client managed files after READY", e)); - }); - } - /** - * Load the config file and initialize parsers and processors. - */ - async init() { - return this.#initPromise ??= this.#init(); - } - async #init() { - this.#isInitialized = false; - const callIntializers = async () => { - const initCtx = { - cacheRoot: this.cacheRoot, - config: this.config, - externals: this.externals, - isDebugging: this.isDebugging, - logger: this.logger, - meta: this.meta, - projectRoots: this.projectRoots - }; - const results = await Promise.allSettled(this.#initializers.map((init) => init(initCtx))); - let ctx = {}; - results.forEach(async (r, i) => { - if (r.status === "rejected") { - this.logger.error(`[Project] [callInitializers] [${i}] \u201C${this.#initializers[i].name}\u201D`, r.reason); - } else if (r.value) { - ctx = { ...ctx, ...r.value }; - } - }); - this.#ctx = ctx; - }; - const __profiler = this.profilers.get("project#init"); - const { symbols } = await this.cacheService.load(); - this.symbols = new SymbolUtil(symbols); - this.symbols.buildCache(); - __profiler.task("Load Cache"); - this.config = await this.#configService.load(); - __profiler.task("Load Config"); - await callIntializers(); - __profiler.task("Initialize").finalize(); - this.#isInitialized = true; - return this; - } - /** - * Finish the initial run of parsing, binding, and checking the entire project. - */ - async ready(options2 = {}) { - return this.#readyPromise ??= this.#ready(options2); - } - async #ready({ projectRootsWatcher } = {}) { - if (!this.#isInitialized) { - throw new Error("Project.ready() must be called after Project.init() resolves"); - } - this.#isReady = false; - this.#watcher = projectRootsWatcher; - const getDependencies = async () => { - const dependencies = []; - for (const input of this.config.env.dependencies) { - try { - if (DependencyKey.is(input)) { - const provider = this.meta.getDependencyProvider(input); - if (!provider) { - throw new Error(`No provider for ${input}`); - } - dependencies.push(await provider()); - this.logger.info(`[Project] [getDependencies] Executed provider \u201C${input}\u201D`); - } else { - const stats = await this.externals.fs.stat(input); - if (stats.isDirectory()) { - dependencies.push({ type: "directory", uri: input }); - } else if (stats.isFile()) { - dependencies.push({ type: "tarball-file", uri: input }); - } else { - throw new Error("Unsupported file entry type"); - } - } - } catch (e) { - this.logger.error(`[Project] [getDependencies] Bad dependency \u201C${input}\u201D`, e); - } - } - return dependencies; - }; - const listDependencyFiles = async () => { - const dependencies = await getDependencies(); - const fileUriSupporter = await FileUriSupporter.create(dependencies, this.externals, this.logger); - const archiveUriSupporter = await ArchiveUriSupporter.create(dependencies, this.externals, this.logger); - this.fs.register("file:", fileUriSupporter, true); - this.fs.register(ArchiveUriSupporter.Protocol, archiveUriSupporter, true); - }; - const listProjectFiles = async () => { - if (!this.#watcher) { - return; - } - this.#watcher.on("add", (uri) => { - if (this.shouldExclude(uri)) { - return; - } - this.emit("fileCreated", { uri }); - }).on("change", (uri) => { - if (this.shouldExclude(uri)) { - return; - } - this.emit("fileModified", { uri }); - }).on("unlink", (uri) => { - this.emit("fileDeleted", { uri }); - }).on("error", (e) => { - this.logger.error("[Project#watcher]", e); - }); - await this.#watcher.ready(); - }; - const __profiler = this.profilers.get("project#ready"); - await Promise.all([listDependencyFiles(), listProjectFiles()]); - this.#dependencyFiles = new Set([...this.fs.listFiles()].filter((uri) => !this.shouldExclude(uri))); - this.#dependencyRoots = new Set(this.fs.listRoots()); - this.updateRoots(); - __profiler.task("List URIs"); - for (const [id, { checksum, registrar }] of this.meta.symbolRegistrars) { - const cacheChecksum = this.cacheService.checksums.symbolRegistrars[id]; - if (cacheChecksum === void 0 || checksum !== cacheChecksum) { - this.symbols.clear({ contributor: `symbol_registrar/${id}` }); - this.symbols.contributeAs(`symbol_registrar/${id}`, () => { - registrar(this.symbols, { logger: this.logger }); - }); - this.emit("symbolRegistrarExecuted", { id, checksum }); - } else { - this.logger.info(`[SymbolRegistrar] Skipped \u201C${id}\u201D thanks to cache ${checksum}`); - } - } - __profiler.task("Register Symbols"); - for (const [uri, values] of Object.entries(this.cacheService.errors)) { - this.emit("documentErrored", { errors: values, uri }); - } - __profiler.task("Pop Errors"); - const { addedFiles, changedFiles, removedFiles } = await this.cacheService.validate(); - this.logger.info(`[Project#ready] Files added/changed/removed: ${addedFiles.length}/${changedFiles.length}/${removedFiles.length}`); - for (const uri of removedFiles) { - this.emit("fileDeleted", { uri }); - } - __profiler.task("Validate Cache"); - if (addedFiles.length > 0) { - this.bindUri(addedFiles); - } - __profiler.task("Bind URIs"); - const files = [...addedFiles, ...changedFiles].sort(this.meta.uriSorter); - __profiler.task("Sort URIs"); - const fileCountByExtension = /* @__PURE__ */ new Map(); - for (const file9 of files) { - const ext = fileUtil.extname(file9)?.replace(/^\./, ""); - if (ext) { - fileCountByExtension.set(ext, (fileCountByExtension.get(ext) ?? 0) + 1); - } - } - this.logger.info(`[Project#ready] == Files to bind ==`); - for (const [ext, count] of fileCountByExtension.entries()) { - this.logger.info(`[Project#ready] File extension ${ext}: ${count}`); - } - const __bindProfiler = this.profilers.get("project#ready#bind", "top-n", 50); - for (const uri of files) { - await this.ensureBindingStarted(uri); - __bindProfiler.task(uri); - } - __bindProfiler.finalize(); - __profiler.task("Bind Files"); - __profiler.finalize(); - this.emit("ready", {}); - this.#isReady = true; - return this; - } - /** - * Behavior of the `Project` instance is undefined after this function has settled. - */ - async close() { - clearInterval(this.#cacheSaverIntervalId); - await this.#watcher?.close(); - await this.cacheService.save(); - } - async restart() { - try { - this.#bindingInProgressUris.clear(); - this.#symbolUpToDateUris.clear(); - this.#readyPromise = void 0; - await this.ready(); - } catch (e) { - this.logger.error("[Project#reset]", e); - } - } - resetCache() { - this.logger.info("[Project#resetCache] Initiated..."); - for (const uri of Object.keys(this.cacheService.errors)) { - this.emit("documentErrored", { errors: [], uri }); - } - const { symbols } = this.cacheService.reset(); - this.symbols = new SymbolUtil(symbols); - this.symbols.buildCache(); - return this.restart(); - } - normalizeUri(uri) { - return this.fs.mapFromDisk(normalizeUri(uri)); - } - static TextDocumentCacheMaxLength = 268435456; - #textDocumentCache = /* @__PURE__ */ new Map(); - #textDocumentCacheLength = 0; - removeCachedTextDocument(uri) { - const doc = this.#textDocumentCache.get(uri); - if (doc && !(doc instanceof Promise)) { - this.#textDocumentCacheLength -= doc.getText().length; - } - this.#textDocumentCache.delete(uri); - } - async read(uri) { - const createTextDocument = async (uri2) => { - const languageId = this.guessLanguageID(uri2); - if (!this.isSupportedLanguage(uri2, languageId)) { - return void 0; - } - try { - const content = bufferToString(await this.fs.readFile(uri2)); - return TextDocument.create(uri2, languageId, -1, content); - } catch (e) { - this.logger.warn(`[Project] [read] Failed creating TextDocument for ${uri2}`, e); - return void 0; - } - }; - const trimCache = () => { - const iterator = this.#textDocumentCache.keys(); - while (this.#textDocumentCacheLength > _Project.TextDocumentCacheMaxLength) { - const result = iterator.next(); - if (result.done) { - throw new Error(`[Project] [read] Cache is too large with length ${this.#textDocumentCacheLength} even though it's empty; make sure to call 'removeCachedTextDocument()' instead of 'this.#textDocumentCache.delete()'`); - } - this.removeCachedTextDocument(result.value); - } - }; - const getCacheHandlingPromise = async (uri2) => { - if (this.#textDocumentCache.has(uri2)) { - const ans = this.#textDocumentCache.get(uri2); - this.#textDocumentCache.delete(uri2); - this.#textDocumentCache.set(uri2, ans); - return ans; - } else { - const promise = createTextDocument(uri2); - this.#textDocumentCache.set(uri2, promise); - const doc = await promise; - if (this.#textDocumentCache.get(uri2) === promise) { - if (doc) { - this.#textDocumentCache.set(uri2, doc); - this.#textDocumentCacheLength += doc.getText().length; - trimCache(); - } else { - this.#textDocumentCache.delete(uri2); - } - } - return doc; - } - }; - uri = this.normalizeUri(uri); - if (this.#clientManagedUris.has(uri)) { - const result = this.#clientManagedDocAndNodes.get(uri); - if (result) { - return result.doc; - } - throw new Error(`[Project] [read] Client-managed URI ${uri} does not have a TextDocument in the cache`); - } - return getCacheHandlingPromise(uri); - } - parse(doc) { - const ctx = ParserContext.create(this, { doc }); - const parser = ctx.meta.getParserForLanguageId(ctx.doc.languageId); - if (!parser) { - return { - type: "file", - range: Range.create(0), - children: [], - locals: /* @__PURE__ */ Object.create(null), - parserErrors: [] - }; - } - const src = new Source(doc.getText()); - return file4(parser)(src, ctx); - } - async bind(doc, node) { - if (node.binderErrors) { - return; - } - try { - this.#bindingInProgressUris.add(doc.uri); - const binder = this.meta.getBinder(node.type); - const ctx = BinderContext.create(this, { doc }); - ctx.symbols.clear({ contributor: "binder", uri: doc.uri }); - await ctx.symbols.contributeAsAsync("binder", async () => { - const proxy = StateProxy.create(node); - await binder(proxy, ctx); - node.binderErrors = ctx.err.dump(); - }); - this.#bindingInProgressUris.delete(doc.uri); - this.#symbolUpToDateUris.add(doc.uri); - } catch (e) { - this.logger.error(`[Project] [bind] Failed for ${doc.uri} # ${doc.version}`, e); - } - } - async check(doc, node) { - if (node.checkerErrors) { - return; - } - try { - const checker = this.meta.getChecker(node.type); - const ctx = CheckerContext.create(this, { doc }); - ctx.symbols.clear({ contributor: "checker", uri: doc.uri }); - await ctx.symbols.contributeAsAsync("checker", async () => { - await checker(StateProxy.create(node), ctx); - node.checkerErrors = ctx.err.dump(); - this.lint(doc, node); - }); - } catch (e) { - this.logger.error(`[Project] [check] Failed for ${doc.uri} # ${doc.version}`, e); - } - } - lint(doc, node) { - if (node.linterErrors) { - return; - } - node.linterErrors = []; - try { - for (const [ruleName, rawValue] of Object.entries(this.config.lint)) { - const result = LinterConfigValue.destruct(rawValue); - if (!result) { - continue; - } - const { ruleSeverity, ruleValue } = result; - const { configValidator: configValidator2, linter, nodePredicate } = this.meta.getLinter(ruleName); - if (!configValidator2(ruleName, ruleValue, this.logger)) { - continue; - } - const ctx = LinterContext.create(this, { - doc, - err: new LinterErrorReporter(ruleName, ruleSeverity, this.ctx["errorSource"]), - ruleName, - ruleValue - }); - traversePreOrder(node, () => true, () => true, (node2) => { - if (nodePredicate(node2)) { - const proxy = StateProxy.create(node2); - linter(proxy, ctx); - } - }); - node.linterErrors.push(...ctx.err.dump()); - } - } catch (e) { - this.logger.error(`[Project] [lint] Failed for ${doc.uri} # ${doc.version}`, e); - } - } - // @SingletonPromise() - async ensureBindingStarted(uri) { - uri = this.normalizeUri(uri); - if (this.#symbolUpToDateUris.has(uri) || this.#bindingInProgressUris.has(uri)) { - return; - } - this.#bindingInProgressUris.add(uri); - const doc = await this.read(uri); - if (!doc || !await this.cacheService.hasFileChangedSinceCache(doc)) { - return; - } - const node = this.parse(doc); - await this.bind(doc, node); - this.emit("documentUpdated", { doc, node }); - } - bindUri(param) { - const ctx = UriBinderContext.create(this); - if (typeof param === "string") { - ctx.symbols.clear({ contributor: "uri_binder", uri: param }); - } - ctx.symbols.contributeAs("uri_binder", () => { - const uris = Array.isArray(param) ? param : [param]; - for (const binder of this.meta.uriBinders) { - binder(uris, ctx); - } - }); - } - /** - * Notify that a new document was opened in the editor. - */ - async onDidOpen(uri, languageID, version, content) { - uri = this.normalizeUri(uri); - if (uri.startsWith(ArchiveUriSupporter.Protocol)) { - return; - } - if (this.shouldExclude(uri, languageID)) { - return; - } - const doc = TextDocument.create(uri, languageID, version, content); - const node = this.parse(doc); - this.#clientManagedUris.add(uri); - this.#clientManagedDocAndNodes.set(uri, { doc, node }); - if (this.#isReady) { - await this.bind(doc, node); - await this.check(doc, node); - } - } - /** - * Notify that an existing document was changed in the editor. - * @throws If there is no `TextDocument` corresponding to the URI. - */ - async onDidChange(uri, changes, version) { - uri = this.normalizeUri(uri); - this.#symbolUpToDateUris.delete(uri); - if (uri.startsWith(ArchiveUriSupporter.Protocol)) { - return; - } - const doc = this.#clientManagedDocAndNodes.get(uri)?.doc; - if (!doc || this.shouldExclude(uri, doc.languageId)) { - return; - } - TextDocument.update(doc, changes, version); - const node = this.parse(doc); - this.#clientManagedDocAndNodes.set(uri, { doc, node }); - if (this.#isReady) { - await this.bind(doc, node); - await this.check(doc, node); - } - } - /** - * Notify that an existing document was closed in the editor. - */ - onDidClose(uri) { - uri = this.normalizeUri(uri); - if (uri.startsWith(ArchiveUriSupporter.Protocol)) { - return; - } - this.#clientManagedUris.delete(uri); - this.#clientManagedDocAndNodes.delete(uri); - this.tryClearingCache(uri); - } - async ensureClientManagedChecked(uri) { - uri = this.normalizeUri(uri); - const result = this.#clientManagedDocAndNodes.get(uri); - if (result) { - const { doc, node } = result; - if (this.#isReady) { - await this.bind(doc, node); - await this.check(doc, node); - this.emit("documentUpdated", result); - } - return result; - } - return void 0; - } - getClientManaged(uri) { - uri = this.normalizeUri(uri); - return this.#clientManagedDocAndNodes.get(uri); - } - async showCacheRoot() { - if (!this.#cacheRoot) { - return; - } - try { - await fileUtil.ensureDir(this.externals, this.#cacheRoot); - await this.externals.fs.showFile(this.#cacheRoot); - } catch (e) { - this.logger.error("[Service#showCacheRoot]", e); - } - } - /** - * Returns true iff the URI should be excluded from all Spyglass language support. - * - * @param language Optional. If ommitted, a language will be derived from the URI according to - * its file extension. - */ - shouldExclude(uri, language2) { - return !this.isSupportedLanguage(uri, language2) && !ConfigService.isConfigFile(uri) || this.isUserExcluded(uri); - } - isSupportedLanguage(uri, language2) { - language2 ??= this.guessLanguageID(uri); - const languageOptions = this.meta.getLanguageOptions(language2); - if (!languageOptions) { - return false; - } - const { uriPredicate } = languageOptions; - return uriPredicate?.(uri, UriPredicateContext.create(this)) ?? true; - } - /** - * Guess a language ID from a URI. The guessed language ID may or may not actually be supported. - */ - guessLanguageID(uri) { - const ext = fileUtil.extname(uri) ?? ".spyglassmc-unknown"; - return this.meta.getLanguageID(ext) ?? ext.slice(1); - } - isUserExcluded(uri) { - if (this.config.env.exclude.length === 0) { - return false; - } - for (const rel of fileUtil.getRels(uri, this.projectRoots)) { - if ((0, import_picomatch.default)(this.config.env.exclude, { dot: true, posixSlashes: false })(rel)) { - return true; - } - } - return false; - } - tryClearingCache(uri) { - if (this.shouldRemove(uri)) { - this.removeCachedTextDocument(uri); - this.emit("documentRemoved", { uri }); - } - } - shouldRemove(uri) { - return !this.#clientManagedUris.has(uri) && !this.#dependencyFiles?.has(uri) && !this.watchedFiles.has(uri); - } - isOnlyWatched(uri) { - return this.watchedFiles.has(uri) && !this.#clientManagedUris.has(uri) && !this.#dependencyFiles?.has(uri); - } - async onEditorConfigurationUpdate(editorConfiguration) { - await this.#configService.onEditorConfigurationUpdate(editorConfiguration); - } -}; -__decorate2([ - SingletonPromise() -], Project.prototype, "bind", null); -__decorate2([ - SingletonPromise() -], Project.prototype, "check", null); -__decorate2([ - SingletonPromise() -], Project.prototype, "ensureClientManagedChecked", null); - -// node_modules/@spyglassmc/core/lib/service/SymbolLocations.js -var SymbolLocations; -(function(SymbolLocations2) { - function create(range3, locations) { - return { range: Range.get(range3), locations }; - } - SymbolLocations2.create = create; -})(SymbolLocations || (SymbolLocations = {})); - -// node_modules/@spyglassmc/core/lib/parser/Parser.js -var Failure = Symbol("Failure"); - -// node_modules/@spyglassmc/core/lib/parser/util.js -function attempt3(parser, src, ctx) { - const tmpSrc = src.clone(); - const tmpCtx = { ...ctx, err: new ErrorReporter(ctx.err.source) }; - const result = parser(tmpSrc, tmpCtx); - return { - result, - endCursor: tmpSrc.cursor, - errorAmount: tmpCtx.err.errors.length, - updateSrcAndCtx: () => { - src.innerCursor = tmpSrc.innerCursor; - ctx.err.absorb(tmpCtx.err); - } - }; -} -function sequence(parsers, parseGap) { - return (src, ctx) => { - const ans = { - [SequenceUtilDiscriminator]: true, - children: [], - range: Range.create(src) - }; - for (const [i, p] of parsers.entries()) { - const parser = typeof p === "function" ? p : p.get(ans); - if (parser === void 0) { - continue; - } - if (i > 0 && parseGap) { - ans.children.push(...parseGap(src, ctx)); - } - const result = parser(src, ctx); - if (result === Failure) { - return Failure; - } else if (result === void 0) { - continue; - } else if (SequenceUtil.is(result)) { - ans.children.push(...result.children); - } else { - ans.children.push(result); - } - } - ans.range.end = src.cursor; - return ans; - }; -} -function repeat(parser, parseGap) { - return (src, ctx) => { - const ans = { - [SequenceUtilDiscriminator]: true, - children: [], - range: Range.create(src) - }; - while (src.canRead()) { - if (parseGap) { - ans.children.push(...parseGap(src, ctx)); - } - const { result, updateSrcAndCtx } = attempt3(parser, src, ctx); - if (result === Failure) { - break; - } - updateSrcAndCtx(); - if (SequenceUtil.is(result)) { - ans.children.push(...result.children); - } else { - ans.children.push(result); - } - } - ans.range.end = src.cursor; - return ans; - }; -} -function any3(parsers, out) { - return (src, ctx) => { - const results = parsers.map((parser, i) => ({ attempt: attempt3(parser, src, ctx), index: i })).filter(({ attempt: attempt4 }) => attempt4.result !== Failure).sort((a, b) => b.attempt.endCursor - a.attempt.endCursor || a.attempt.errorAmount - b.attempt.errorAmount); - if (results.length === 0) { - if (out) { - out.index = -1; - } - return Failure; - } - results[0].attempt.updateSrcAndCtx(); - if (out) { - out.index = results[0].index; - } - return results[0].attempt.result; - }; -} -function failOnEmpty(parser) { - return (src, ctx) => { - const start = src.cursor; - const { endCursor, updateSrcAndCtx, result } = attempt3(parser, src, ctx); - if (endCursor - start > 0) { - updateSrcAndCtx(); - return result; - } - return Failure; - }; -} -function failOnError(parser) { - return (src, ctx) => { - const start = src.cursor; - const { errorAmount, updateSrcAndCtx, result } = attempt3(parser, src, ctx); - if (!errorAmount) { - updateSrcAndCtx(); - return result; - } - return Failure; - }; -} -function optional(parser) { - return ((src, ctx) => { - const { result, updateSrcAndCtx } = attempt3(parser, src, ctx); - if (result === Failure) { - return void 0; - } else { - updateSrcAndCtx(); - return result; - } - }); -} -function select(cases) { - return (src, ctx) => { - for (const { predicate, prefix, parser, regex } of cases) { - if (predicate?.(src) ?? (prefix !== void 0 ? src.tryPeek(prefix) : void 0) ?? (regex && src.matchPattern(regex)) ?? true) { - const callableParser = typeof parser === "object" ? parser.get() : parser; - return callableParser(src, ctx); - } - } - throw new Error("The select parser util was called with non-exhaustive cases"); - }; -} -function map(parser, fn) { - return (src, ctx) => { - const result = parser(src, ctx); - if (result === Failure) { - return Failure; - } - const ans = fn(result, src, ctx); - return ans; - }; -} -function setType(type2, parser) { - return map(parser, (res) => { - const { type: _type, ...restResult } = res; - const ans = { type: type2, ...restResult }; - delete ans[SequenceUtilDiscriminator]; - return ans; - }); -} -function validate(parser, validator4, message2, severity) { - return map(parser, (res, src, ctx) => { - const isLegal = validator4(res, src, ctx); - if (!isLegal) { - ctx.err.report(message2, res.range, severity); - } - return res; - }); -} -function stopBefore(parser, ...terminators) { - const flatTerminators = terminators.flat(); - return (src, ctx) => { - const tmpSrc = src.clone(); - tmpSrc.string = tmpSrc.string.slice(0, flatTerminators.reduce((p, c) => { - const index4 = tmpSrc.string.indexOf(c, tmpSrc.innerCursor); - return Math.min(p, index4 === -1 ? Infinity : index4); - }, Infinity)); - const ans = parser(tmpSrc, ctx); - src.cursor = tmpSrc.cursor; - return ans; - }; -} -function concatOnTrailingBackslash(parser) { - return (src, ctx) => { - let wrappedStr = src.sliceToCursor(0); - const wrappedSrcCursor = wrappedStr.length; - const indexMap = []; - while (src.canRead()) { - wrappedStr += src.readUntil("\\"); - if (!src.canRead()) { - break; - } - if (src.hasNonSpaceAheadInLine(1)) { - wrappedStr += src.read(); - continue; - } - const from = src.getCharRange(); - src.nextLine(); - if (!src.canRead()) { - const ans2 = { type: "error", range: Range.span(from, src) }; - ctx.err.report(localize("parser.line-continuation-end-of-file"), ans2); - } - src.skipSpace(); - const to = src.getCharRange(-1); - indexMap.push({ inner: Range.create(wrappedStr.length), outer: Range.span(from, to) }); - } - const wrappedSrc = new Source(wrappedStr, indexMap); - wrappedSrc.innerCursor = wrappedSrcCursor; - const ans = parser(wrappedSrc, ctx); - src.cursor = wrappedSrc.cursor; - return ans; - }; -} -function dumpErrors(parser) { - return ((src, ctx) => { - const ans = parser(src, ctx); - ctx.err.dump(); - return ans; - }); -} - -// node_modules/@spyglassmc/core/lib/parser/boolean.js -var boolean4 = map(literal("false", "true"), (res) => ({ - type: "boolean", - range: res.range, - value: res.value === "" ? void 0 : res.value === "true" -})); - -// node_modules/@spyglassmc/core/lib/parser/comment.js -function comment3({ singleLinePrefixes, includesEol }) { - return (src, _ctx) => { - const start = src.cursor; - const ans = { - type: "comment", - range: Range.create(start), - comment: "", - prefix: "" - }; - for (const prefix of singleLinePrefixes) { - if (src.peek(prefix.length) === prefix) { - if (includesEol) { - src.nextLine(); - } else { - src.skipLine(); - } - ans.range.end = src.cursor; - ans.comment = src.sliceToCursor(start + prefix.length); - ans.prefix = prefix; - return ans; - } - } - return Failure; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/error.js -var error3 = (src, ctx) => { - if (!src.canRead()) { - return void 0; - } - const ans = { type: "error", range: Range.create(src, () => src.skipRemaining()) }; - ctx.err.report(localize("error.unparseable-content"), ans); - return ans; -}; - -// node_modules/@spyglassmc/core/lib/parser/file.js -function file4(parser) { - return (src, ctx) => { - const fullRange = Range.create(src, src.string.length); - const ans = { - type: "file", - range: fullRange, - children: [], - locals: /* @__PURE__ */ Object.create(null), - parserErrors: [] - }; - src.skipWhitespace(); - const result = parser(src, ctx); - if (result && result !== Failure) { - ans.children.push(result); - } - if (src.skipWhitespace().canRead()) { - ans.children.push(error3(src, ctx)); - } - AstNode.setParents(ans); - ans.parserErrors = ctx.err.dump(); - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/float.js -var fallbackOnOutOfRange = (ans, _src, ctx, options2) => { - ctx.err.report(localize("expected", localize("float.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); -}; -function float2(options2) { - return (src, ctx) => { - const ans = { type: "float", range: Range.create(src), value: 0 }; - if (src.peek() === "-" || src.peek() === "+") { - src.skip(); - } - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - } - if (src.trySkip(".")) { - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - } - } - if (src.peek().toLowerCase() === "e") { - src.skip(); - if (src.peek() === "-" || src.peek() === "+") { - src.skip(); - } - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - } - } - ans.range.end = src.cursor; - const raw = src.sliceToCursor(ans.range.start); - ans.value = parseFloat(raw) || 0; - if (!raw) { - if (options2.failsOnEmpty) { - return Failure; - } - ctx.err.report(localize("expected", localize("float")), ans); - } else if (!options2.pattern.test(raw)) { - ctx.err.report(localize("parser.float.illegal", options2.pattern), ans); - } else if (options2.min && ans.value < options2.min || options2.max && ans.value > options2.max) { - const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange; - onOutOfRange(ans, src, ctx, options2); - } - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/integer.js -var fallbackOnOutOfRange2 = (ans, _src, ctx, options2) => { - ctx.err.report(localize("expected", localize("integer.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); -}; -function integer2(options2) { - return (src, ctx) => { - const ans = { type: "integer", range: Range.create(src), value: 0 }; - if (src.peek() === "-" || src.peek() === "+") { - src.skip(); - } - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - } - ans.range.end = src.cursor; - const raw = src.sliceToCursor(ans.range.start); - const isOnlySign = raw === "-" || raw === "+"; - if (!isOnlySign) { - ans.value = Number(raw); - } - if (!raw) { - if (options2.failsOnEmpty) { - return Failure; - } - ctx.err.report(localize("expected", localize("integer")), ans); - } else if (!options2.pattern.test(raw) || isOnlySign) { - ctx.err.report(localize("parser.integer.illegal", options2.pattern), ans); - } else if (options2.min !== void 0 && ans.value < options2.min || options2.max !== void 0 && ans.value > options2.max) { - const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange2; - onOutOfRange(ans, src, ctx, options2); - } - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/list.js -function list({ start, value, sep: sep2, trailingSep, end }) { - return (src, ctx) => { - const ans = { type: "list", range: Range.create(src), children: [] }; - if (src.trySkip(start)) { - src.skipWhitespace(); - let requiresValueSep = false; - let hasValueSep = false; - while (src.canRead() && src.peek(end.length) !== end) { - const itemStart = src.cursor; - let valueNode; - if (requiresValueSep && !hasValueSep) { - ctx.err.report(localize("expected", localeQuote(sep2)), src); - } - src.skipWhitespace(); - const { result, endCursor, updateSrcAndCtx } = attempt3(value, src, ctx); - if (result === Failure || endCursor === src.cursor) { - ctx.err.report(localize("expected", localize("parser.list.value")), Range.create(src, () => src.skipUntilOrEnd(sep2, end, "\r", "\n"))); - } else { - updateSrcAndCtx(); - valueNode = result; - } - let sepRange = void 0; - src.skipWhitespace(); - requiresValueSep = true; - if (hasValueSep = src.peek(sep2.length) === sep2) { - sepRange = Range.create(src, () => src.skip(sep2.length)); - } - ans.children.push({ - type: "item", - range: Range.create(itemStart, src), - ...valueNode ? { children: [valueNode] } : {}, - value: valueNode, - sep: sepRange - }); - src.skipWhitespace(); - } - if (hasValueSep && !trailingSep) { - const trailingRange = ans.children[ans.children.length - 1].sep; - ctx.err.report(localize("parser.list.trailing-sep"), trailingRange, ErrorSeverity.Error, { - codeAction: { - title: localize("code-action.remove-trailing-separation"), - isPreferred: true, - changes: [ - { - type: "edit", - range: trailingRange, - text: "" - } - ] - } - }); - } - if (!src.trySkip(end)) { - ctx.err.report(localize("expected", localeQuote(end)), src); - } - } else { - ctx.err.report(localize("expected", localeQuote(start)), src); - } - ans.range.end = src.cursor; - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/long.js -var fallbackOnOutOfRange3 = (ans, _src, ctx, options2) => { - ctx.err.report(localize("expected", localize("long.between", options2.min ?? "-\u221E", options2.max ?? "+\u221E")), ans, ErrorSeverity.Error); -}; -function long2(options2) { - return (src, ctx) => { - const ans = { type: "long", range: Range.create(src), value: 0n }; - if (src.peek() === "-" || src.peek() === "+") { - src.skip(); - } - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - } - ans.range.end = src.cursor; - const raw = src.sliceToCursor(ans.range.start); - let isOnlySign = false; - try { - ans.value = BigInt(raw); - } catch (_) { - isOnlySign = true; - } - if (!raw) { - if (options2.failsOnEmpty) { - return Failure; - } - ctx.err.report(localize("expected", localize("long")), ans); - } else if (!options2.pattern.test(raw) || isOnlySign) { - ctx.err.report(localize("parser.long.illegal", options2.pattern), ans); - } else if (options2.min && ans.value < options2.min || options2.max && ans.value > options2.max) { - const onOutOfRange = options2.onOutOfRange ?? fallbackOnOutOfRange3; - onOutOfRange(ans, src, ctx, options2); - } - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/prefixed.js -function prefixed2(options2) { - return (src, ctx) => { - const ans = { - type: "prefixed", - range: Range.create(src), - prefix: options2.prefix, - children: [] - }; - const prefix = literal(options2.prefix)(src, ctx); - ans.children.push(prefix); - ans.range.end = src.cursor; - const child = options2.child(src, ctx); - if (child !== Failure) { - ans.children.push(child); - } - ans.range.end = src.cursor; - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/record.js -function record2({ start, pair, end }) { - return (src, ctx) => { - const ans = { type: "record", range: Range.create(src), children: [] }; - if (src.trySkip(start)) { - ans.innerRange = Range.create(src); - src.skipWhitespace(); - let requiresPairEnd = false; - let hasPairEnd = false; - while (src.canRead() && src.peek(end.length) !== end) { - const pairStart = src.cursor; - let key2; - let value; - if (requiresPairEnd && !hasPairEnd) { - ctx.err.report(localize("expected", localeQuote(pair.end)), src); - } - const keyStart = src.cursor; - const { result: keyResult, updateSrcAndCtx: updateForKey, endCursor: keyEnd } = attempt3(pair.key, src, ctx); - if (keyResult === Failure || keyEnd - keyStart === 0 && ![pair.sep, pair.end, end, "\r", "\n", " ", " "].includes(src.peek())) { - ctx.err.report(localize("expected", localize("parser.record.key")), Range.create(src, () => src.skipUntilOrEnd(pair.sep, pair.end, end, "\r", "\n"))); - } else { - updateForKey(); - key2 = keyResult; - } - let sepCharRange = void 0; - src.skipWhitespace(); - if (src.peek(pair.sep.length) === pair.sep) { - sepCharRange = Range.create(src, () => src.skip(pair.sep.length)); - } else { - ctx.err.report(localize("expected", localeQuote(pair.sep)), src); - } - src.skipWhitespace(); - const valueParser = typeof pair.value === "function" ? pair.value : pair.value.get(ans, key2); - const valueStart = src.cursor; - const { result: valueResult, updateSrcAndCtx: updateForValue, endCursor: valueEnd } = attempt3(valueParser, src, ctx); - if (valueResult === Failure || valueEnd - valueStart === 0 && ![pair.sep, pair.end, end, "\r", "\n", " ", " "].includes(src.peek())) { - ctx.err.report(localize("expected", localize("parser.record.value")), Range.create(src, () => src.skipUntilOrEnd(pair.sep, pair.end, end, "\r", "\n"))); - } else { - updateForValue(); - value = valueResult; - } - let endCharRange = void 0; - src.skipWhitespace(); - requiresPairEnd = true; - if (hasPairEnd = src.peek(pair.end.length) === pair.end) { - endCharRange = Range.create(src, () => src.skip(pair.end.length)); - } - ans.children.push({ - type: "pair", - range: Range.create(pairStart, src), - ...key2 || value ? { children: [key2, value].filter((v) => !!v) } : {}, - key: key2, - sep: sepCharRange, - value, - end: endCharRange - }); - src.skipWhitespace(); - } - if (hasPairEnd && !pair.trailingEnd) { - const trailingRange = ans.children[ans.children.length - 1].end; - ctx.err.report(localize("parser.record.trailing-end"), trailingRange, ErrorSeverity.Error, { - codeAction: { - title: localize("code-action.remove-trailing-separation"), - isPreferred: true, - changes: [ - { - type: "edit", - range: trailingRange, - text: "" - } - ] - } - }); - } - ans.innerRange.end = src.cursor; - if (!src.trySkip(end)) { - ctx.err.report(localize("expected", localeQuote(end)), src); - } - } else { - ctx.err.report(localize("expected", localeQuote(start)), src); - } - ans.range.end = src.cursor; - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/resourceLocation.js -var Terminators = /* @__PURE__ */ new Set([ - " ", - "\r", - "\n", - "=", - "~", - ",", - '"', - "'", - "{", - "}", - "[", - "]", - "(", - ")", - ";", - "|" -]); -var LegalResourceLocationCharacters = /* @__PURE__ */ new Set([ - "a", - "b", - "c", - "d", - "e", - "f", - "g", - "h", - "i", - "j", - "k", - "l", - "m", - "n", - "o", - "p", - "q", - "r", - "s", - "t", - "u", - "v", - "w", - "x", - "y", - "z", - "0", - "1", - "2", - "3", - "4", - "5", - "6", - "7", - "8", - "9", - "_", - "-", - "." -]); -function resourceLocation6(options2) { - return (src, ctx) => { - const ans = { - type: "resource_location", - range: Range.create(src), - options: options2 - }; - if (src.trySkip(ResourceLocation.TagPrefix)) { - ans.isTag = true; - } - const start = src.cursor; - while (src.canReadInLine() && !Terminators.has(src.peek())) { - src.skip(); - } - const raw = src.sliceToCursor(start); - ans.range.end = src.cursor; - if (raw.length === 0) { - ctx.err.report(localize("expected", localize("resource-location")), ans); - } else { - const sepIndex = raw.indexOf(options2.namespacePathSep ?? ResourceLocation.NamespacePathSep); - if (sepIndex >= 0) { - ans.namespace = raw.slice(0, sepIndex); - } - const rawPath = raw.slice(sepIndex + 1); - ans.path = rawPath.split(ResourceLocation.PathSep); - const illegalChars = [ - .../* @__PURE__ */ new Set([ - ...[...ans.namespace ?? []].filter((c) => !LegalResourceLocationCharacters.has(c)), - ...[...rawPath].filter((c) => c !== "/" && !LegalResourceLocationCharacters.has(c)) - ]) - ]; - if (illegalChars.length) { - ctx.err.report(localize("parser.resource-location.illegal", arrayToMessage(illegalChars, true, "and")), ans); - } - if (ans.isTag && !options2.allowTag) { - ctx.err.report(localize("parser.resource-location.tag-disallowed"), ans); - } - if (!ans.isTag && options2.requireTag) { - ctx.err.report(localize("parser.resource-location.tag-required"), ans); - } - if (!ans.namespace && options2.requireCanonical) { - ctx.err.report(localize("parser.resource-location.namespace-expected"), ans, ErrorSeverity.Error, { - codeAction: { - title: localize("code-action.add-default-namespace"), - isPreferred: true, - changes: [ - { - type: "edit", - range: Range.create(start), - text: ResourceLocation.DefaultNamespace + ResourceLocation.NamespacePathSep - } - ] - } - }); - } - } - return ans; - }; -} - -// node_modules/@spyglassmc/core/lib/parser/string.js -function string4(options2) { - return (src, ctx) => { - const ans = { - type: "string", - range: Range.create(src), - options: options2, - value: "", - valueMap: [] - }; - let start; - if (options2.quotes?.length && (src.peek() === '"' || src.peek() === "'")) { - const currentQuote = src.read(); - ans.quote = currentQuote; - let cStart = src.cursor; - start = cStart; - while (src.canRead() && src.peek() !== currentQuote) { - const c = src.peek(); - if (options2.escapable && c === "\\") { - src.skip(); - const c2 = src.read(); - if (c2 === "\\" || c2 === currentQuote || EscapeChar.is(options2.escapable.characters, c2)) { - ans.valueMap.push({ - inner: Range.create(ans.value.length, ans.value.length + 1), - outer: Range.create(cStart, src) - }); - ans.value += EscapeTable.get(c2); - } else if (options2.escapable.unicode && c2 === "u") { - const hex = src.peek(4); - if (/^[0-9a-f]{4}$/i.test(hex)) { - src.skip(4); - ans.valueMap.push({ - inner: Range.create(ans.value.length, ans.value.length + 1), - outer: Range.create(cStart, src) - }); - ans.value += String.fromCharCode(parseInt(hex, 16)); - } else { - ctx.err.report(localize("parser.string.illegal-unicode-escape"), Range.create(src, src.getCharRange(3).end)); - ans.valueMap.push({ - inner: Range.create(ans.value.length, ans.value.length + 1), - outer: Range.create(cStart, src) - }); - ans.value += c2; - } - } else { - if (!options2.escapable.allowUnknown) { - ctx.err.report(localize("parser.string.illegal-escape", localeQuote(c2)), src.getCharRange(-1)); - } - ans.valueMap.push({ - inner: Range.create(ans.value.length, ans.value.length + 1), - outer: Range.create(cStart, src) - }); - ans.value += c2; - } - cStart = src.cursor; - } else { - src.skip(); - const cEnd = src.cursor; - if (cEnd - cStart > 1) { - ans.valueMap.push({ - inner: Range.create(ans.value.length, ans.value.length + 1), - outer: Range.create(cStart, cEnd) - }); - } - ans.value += c; - cStart = cEnd; - } - } - if (!src.trySkip(currentQuote)) { - ctx.err.report(localize("expected", localeQuote(currentQuote)), src); - } - if (!options2.quotes.includes(currentQuote)) { - ctx.err.report(localize("parser.string.illegal-quote", options2.quotes), ans); - } - } else if (options2.unquotable) { - start = src.cursor; - while (src.canRead() && isAllowedCharacter(src.peek(), options2.unquotable)) { - ans.value += src.read(); - } - if (!ans.value && !options2.unquotable.allowEmpty) { - ctx.err.report(localize("expected", localize("string")), src); - } - } else { - start = src.cursor; - ctx.err.report(localize("expected", options2.quotes), src); - } - ans.valueMap.unshift({ inner: Range.create(0), outer: Range.create(start) }); - if (options2.value?.parser) { - const valueResult = parseStringValue(options2.value.parser, ans.value, ans.valueMap, ctx); - if (valueResult !== Failure) { - ans.children = [valueResult]; - } - } - ans.range.end = src.cursor; - return ans; - }; -} -function parseStringValue(parser, value, map3, ctx) { - const valueSrc = new Source(value, map3); - const valueCtx = { - ...ctx, - doc: TextDocument.create(ctx.doc.uri, ctx.doc.languageId, ctx.doc.version, value) - }; - return parser(valueSrc, valueCtx); -} -var BrigadierUnquotableCharacters = Object.freeze([ - "0", - "1", - "2", - "3", - "4", - "5", - "6", - "7", - "8", - "9", - "A", - "B", - "C", - "D", - "E", - "F", - "G", - "H", - "I", - "J", - "K", - "L", - "M", - "N", - "O", - "P", - "Q", - "R", - "S", - "T", - "U", - "V", - "W", - "X", - "Y", - "Z", - "a", - "b", - "c", - "d", - "e", - "f", - "g", - "h", - "i", - "j", - "k", - "l", - "m", - "n", - "o", - "p", - "q", - "r", - "s", - "t", - "u", - "v", - "w", - "x", - "y", - "z", - "_", - ".", - "+", - "-" -]); -var BrigadierUnquotableCharacterSet = new Set(BrigadierUnquotableCharacters); -var BrigadierUnquotablePattern = /^[0-9A-Za-z_\.\+\-]*$/; -var BrigadierUnquotableOption = { - allowEmpty: true, - allowList: BrigadierUnquotableCharacterSet -}; -var BrigadierStringOptions = { - escapable: {}, - quotes: ['"', "'"], - unquotable: BrigadierUnquotableOption -}; -var brigadierString = string4(BrigadierStringOptions); -function isAllowedCharacter(c, options2) { - return options2.allowList?.has(c) ?? !options2.blockList?.has(c); -} - -// node_modules/@spyglassmc/core/lib/parser/symbol.js -function symbol5(param) { - const options2 = getOptions2(param); - return (src, _ctx) => { - const ans = { - type: "symbol", - range: Range.create(src), - options: options2, - value: src.readRemaining() - }; - ans.range.end = src.cursor; - return ans; - }; -} -function getOptions2(param) { - if (typeof param === "string") { - return { category: param }; - } else { - return param; - } -} - -// node_modules/@spyglassmc/core/lib/common/externals/NodeJsExternals.js -var import_decompress = __toESM(require_decompress(), 1); -var import_node_buffer = require("node:buffer"); -var import_node_child_process = __toESM(require("node:child_process"), 1); -var import_node_fs = __toESM(require("node:fs"), 1); -var import_node_os = __toESM(require("node:os"), 1); -var import_node_process = __toESM(require("node:process"), 1); -var import_node_stream = __toESM(require("node:stream"), 1); -var import_node_url = __toESM(require("node:url"), 1); -var import_node_util = require("node:util"); -function getNodeJsExternals({ cacheRoot, nodeFsp = import_node_fs.promises } = {}) { - return Object.freeze({ - archive: { - decompressBall(buffer, options2) { - if (!(buffer instanceof import_node_buffer.Buffer)) { - buffer = import_node_buffer.Buffer.from(buffer); - } - return (0, import_decompress.default)(buffer, { strip: options2?.stripLevel }); - } - }, - error: { - createKind(kind, message2) { - const error4 = new Error(message2); - error4.code = kind; - return error4; - }, - isKind(e, kind) { - return e instanceof Error && e.code === kind; - } - }, - fs: { - chmod(location, mode) { - return nodeFsp.chmod(toFsPathLike(location), mode); - }, - async mkdir(location, options2) { - return void await nodeFsp.mkdir(toFsPathLike(location), options2); - }, - readdir(location) { - return nodeFsp.readdir(toFsPathLike(location), { - encoding: "utf-8", - withFileTypes: true - }); - }, - readFile(location) { - return nodeFsp.readFile(toFsPathLike(location)); - }, - rm(location, options2) { - return nodeFsp.rm(toFsPathLike(location), options2); - }, - async showFile(location) { - const execFile = (0, import_node_util.promisify)(import_node_child_process.default.execFile); - let command4; - switch (import_node_process.default.platform) { - case "darwin": - command4 = "open"; - break; - case "win32": - command4 = "explorer"; - break; - default: - command4 = "xdg-open"; - break; - } - return void await execFile(command4, [toPath(location)]); - }, - stat(location) { - return nodeFsp.stat(toFsPathLike(location)); - }, - unlink(location) { - return nodeFsp.unlink(toFsPathLike(location)); - }, - writeFile(location, data, options2) { - return nodeFsp.writeFile(toFsPathLike(location), data, options2); - } - }, - web: { - getCache: async () => { - return new HttpCache(cacheRoot); - } - } - }); -} -var NodeJsExternals = getNodeJsExternals(); -function toFsPathLike(path6) { - if (typeof path6 === "string" && path6.startsWith("file:")) { - return new import_node_url.default.URL(path6); - } - return path6; -} -function toPath(path6) { - if (typeof path6 === "string" && !path6.startsWith("file:")) { - return path6; - } - return uriToPath(path6); -} -var uriToPath = (uri) => import_node_url.default.fileURLToPath(uri); -var HttpCache = class { - #cacheRoot; - constructor(cacheRoot) { - if (cacheRoot) { - this.#cacheRoot = `${cacheRoot}http/`; - } - } - async match(request, _options) { - if (!this.#cacheRoot) { - return void 0; - } - const fileName = this.#getFileName(request); - try { - const etag = (await import_node_fs.promises.readFile(new URL(`${fileName}.etag`, this.#cacheRoot), "utf8")).trim(); - const bodyStream = import_node_fs.default.createReadStream(new URL(`${fileName}.bin`, this.#cacheRoot)); - return new Response( - import_node_stream.default.Readable.toWeb(bodyStream), - // \___/ - // stream Readable -> stream/web ReadableStream - // \_______________/ - // stream/web ReadableStream -> DOM ReadableStream - { headers: { etag } } - ); - } catch (e) { - if (e?.code === "ENOENT") { - return void 0; - } - throw e; - } - } - async put(request, response) { - const etag = response.headers.get("etag"); - if (!(this.#cacheRoot && response.body && etag)) { - return; - } - const fileName = this.#getFileName(request); - await import_node_fs.promises.mkdir(new URL(this.#cacheRoot), { recursive: true }); - await Promise.all([ - import_node_fs.promises.writeFile(new URL(`${fileName}.bin`, this.#cacheRoot), import_node_stream.default.Readable.fromWeb(response.body)), - import_node_fs.promises.writeFile(new URL(`${fileName}.etag`, this.#cacheRoot), `${etag}${import_node_os.default.EOL}`) - ]); - } - #getFileName(request) { - const uriString = request instanceof Request ? request.url : request.toString(); - return import_node_buffer.Buffer.from(uriString, "utf8").toString("base64url"); - } - async add() { - throw new Error("Method not implemented."); - } - async addAll() { - throw new Error("Method not implemented."); - } - async delete() { - throw new Error("Method not implemented."); - } - async keys() { - throw new Error("Method not implemented."); - } - async matchAll() { - throw new Error("Method not implemented."); - } -}; - -// node_modules/@spyglassmc/json/lib/checker/index.js -var checker_exports3 = {}; -__export(checker_exports3, { - index: () => index, - register: () => register, - typed: () => typed -}); - -// node_modules/@spyglassmc/mcdoc/lib/node/index.js -var ModuleNode; -(function(ModuleNode2) { - function is(node) { - return node?.type === "mcdoc:module"; - } - ModuleNode2.is = is; -})(ModuleNode || (ModuleNode = {})); -var TopLevelNode; -(function(TopLevelNode2) { - function is(node) { - return CommentNode.is(node) || DispatchStatementNode.is(node) || EnumNode.is(node) || InjectionNode.is(node) || StructNode.is(node) || TypeAliasNode.is(node) || UseStatementNode.is(node); - } - TopLevelNode2.is = is; -})(TopLevelNode || (TopLevelNode = {})); -var DispatchStatementNode; -(function(DispatchStatementNode2) { - function destruct(node) { - return { - attributes: node.children.filter(AttributeNode.is), - location: node.children.find(ResourceLocationNode.is), - index: node.children.find(IndexBodyNode.is), - target: node.children.find(TypeNode.is), - typeParams: node.children.find(TypeParamBlockNode.is) - }; - } - DispatchStatementNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:dispatch_statement"; - } - DispatchStatementNode2.is = is; -})(DispatchStatementNode || (DispatchStatementNode = {})); -var LiteralNode2; -(function(LiteralNode3) { - function is(node) { - return node?.type === "mcdoc:literal"; - } - LiteralNode3.is = is; -})(LiteralNode2 || (LiteralNode2 = {})); -var IndexBodyNode; -(function(IndexBodyNode2) { - function destruct(node) { - return { parallelIndices: node.children.filter(IndexNode.is) }; - } - IndexBodyNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:index_body"; - } - IndexBodyNode2.is = is; -})(IndexBodyNode || (IndexBodyNode = {})); -var IndexNode; -(function(IndexNode2) { - function is(node) { - return StaticIndexNode.is(node) || DynamicIndexNode.is(node); - } - IndexNode2.is = is; -})(IndexNode || (IndexNode = {})); -var StaticIndexNode; -(function(StaticIndexNode2) { - function is(node) { - return LiteralNode2.is(node) || IdentifierNode.is(node) || StringNode.is(node) || ResourceLocationNode.is(node); - } - StaticIndexNode2.is = is; -})(StaticIndexNode || (StaticIndexNode = {})); -var IdentifierNode; -(function(IdentifierNode2) { - function is(node) { - return node?.type === "mcdoc:identifier"; - } - IdentifierNode2.is = is; -})(IdentifierNode || (IdentifierNode = {})); -var DynamicIndexNode; -(function(DynamicIndexNode2) { - function destruct(node) { - return { keys: node.children.filter(AccessorKeyNode.is) }; - } - DynamicIndexNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:dynamic_index"; - } - DynamicIndexNode2.is = is; -})(DynamicIndexNode || (DynamicIndexNode = {})); -var AccessorKeyNode; -(function(AccessorKeyNode2) { - function is(node) { - return LiteralNode2.is(node) || IdentifierNode.is(node) || StringNode.is(node); - } - AccessorKeyNode2.is = is; -})(AccessorKeyNode || (AccessorKeyNode = {})); -var TypeNode; -(function(TypeNode2) { - function is(node) { - return AnyTypeNode.is(node) || BooleanTypeNode.is(node) || StringTypeNode.is(node) || LiteralTypeNode.is(node) || NumericTypeNode.is(node) || PrimitiveArrayTypeNode.is(node) || ListTypeNode.is(node) || TupleTypeNode.is(node) || EnumNode.is(node) || StructNode.is(node) || ReferenceTypeNode.is(node) || DispatcherTypeNode.is(node) || UnionTypeNode.is(node); - } - TypeNode2.is = is; -})(TypeNode || (TypeNode = {})); -var TypeBaseNode; -(function(TypeBaseNode2) { - function destruct(node) { - return { - appendixes: node.children.filter((n) => IndexBodyNode.is(n) || TypeArgBlockNode.is(n)), - attributes: node.children.filter(AttributeNode.is) - }; - } - TypeBaseNode2.destruct = destruct; -})(TypeBaseNode || (TypeBaseNode = {})); -var AttributeNode; -(function(AttributeNode2) { - function destruct(node) { - return { - name: node.children.find(IdentifierNode.is), - value: node.children.find(AttributeValueNode.is) - }; - } - AttributeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:attribute"; - } - AttributeNode2.is = is; -})(AttributeNode || (AttributeNode = {})); -var AttributeValueNode; -(function(AttributeValueNode2) { - function is(node) { - return TypeNode.is(node) || AttributeTreeNode.is(node); - } - AttributeValueNode2.is = is; -})(AttributeValueNode || (AttributeValueNode = {})); -var AttributeTreeNode; -(function(AttributeTreeNode2) { - function destruct(node) { - return { - positional: node.children.find(AttributeTreePosValuesNode.is), - named: node.children.find(AttributeTreeNamedValuesNode.is) - }; - } - AttributeTreeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:attribute/tree"; - } - AttributeTreeNode2.is = is; -})(AttributeTreeNode || (AttributeTreeNode = {})); -var AttributeTreePosValuesNode; -(function(AttributeTreePosValuesNode2) { - function destruct(node) { - return { values: node.children.filter(AttributeValueNode.is) }; - } - AttributeTreePosValuesNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:attribute/tree/pos"; - } - AttributeTreePosValuesNode2.is = is; -})(AttributeTreePosValuesNode || (AttributeTreePosValuesNode = {})); -var AttributeTreeNamedValuesNode; -(function(AttributeTreeNamedValuesNode2) { - function destruct(node) { - const ans = { values: [] }; - let key2; - for (const child of node.children) { - if (CommentNode.is(child)) { - continue; - } - if (IdentifierNode.is(child) || StringNode.is(child)) { - key2 = child; - } else if (key2) { - ans.values.push({ key: key2, value: child }); - key2 = void 0; - } - } - return ans; - } - AttributeTreeNamedValuesNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:attribute/tree/named"; - } - AttributeTreeNamedValuesNode2.is = is; -})(AttributeTreeNamedValuesNode || (AttributeTreeNamedValuesNode = {})); -var TypeArgBlockNode; -(function(TypeArgBlockNode2) { - function destruct(node) { - return { args: node.children.filter(TypeNode.is) }; - } - TypeArgBlockNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type_arg_block"; - } - TypeArgBlockNode2.is = is; -})(TypeArgBlockNode || (TypeArgBlockNode = {})); -var AnyTypeNode; -(function(AnyTypeNode2) { - function is(node) { - return node?.type === "mcdoc:type/any"; - } - AnyTypeNode2.is = is; -})(AnyTypeNode || (AnyTypeNode = {})); -var BooleanTypeNode; -(function(BooleanTypeNode2) { - function is(node) { - return node?.type === "mcdoc:type/boolean"; - } - BooleanTypeNode2.is = is; -})(BooleanTypeNode || (BooleanTypeNode = {})); -var IntRangeNode; -(function(IntRangeNode3) { - function destruct(node) { - return destructRangeNode(node); - } - IntRangeNode3.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:int_range"; - } - IntRangeNode3.is = is; -})(IntRangeNode || (IntRangeNode = {})); -var LongRangeNode; -(function(LongRangeNode2) { - function destruct(node) { - return destructRangeNode(node); - } - LongRangeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:long_range"; - } - LongRangeNode2.is = is; -})(LongRangeNode || (LongRangeNode = {})); -var LiteralTypeNode; -(function(LiteralTypeNode2) { - function destruct(node) { - return { value: node.children.find(LiteralTypeValueNode.is) }; - } - LiteralTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/literal"; - } - LiteralTypeNode2.is = is; -})(LiteralTypeNode || (LiteralTypeNode = {})); -var LiteralTypeValueNode; -(function(LiteralTypeValueNode2) { - function is(node) { - return LiteralNode2.is(node) || TypedNumberNode.is(node) || StringNode.is(node); - } - LiteralTypeValueNode2.is = is; -})(LiteralTypeValueNode || (LiteralTypeValueNode = {})); -var TypedNumberNode; -(function(TypedNumberNode2) { - function destruct(node) { - return { - value: node.children.find(FloatNode.is) ?? node.children.find(IntegerNode.is) ?? node.children.find(LongNode.is), - suffix: node.children.find(LiteralNode2.is) - }; - } - TypedNumberNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:typed_number"; - } - TypedNumberNode2.is = is; -})(TypedNumberNode || (TypedNumberNode = {})); -var NumericTypeNode; -(function(NumericTypeNode2) { - function destruct(node) { - return { - numericKind: node.children.find(LiteralNode2.is), - valueRange: node.children.find(FloatRangeNode.is) || node.children.find(IntRangeNode.is) || node.children.find(LongRangeNode.is) - }; - } - NumericTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/numeric_type"; - } - NumericTypeNode2.is = is; -})(NumericTypeNode || (NumericTypeNode = {})); -var RangeExclusiveChar = "<"; -var RangeKind; -(function(RangeKind2) { - function isLeftExclusive(rangeKind) { - return (rangeKind & 2) !== 0; - } - RangeKind2.isLeftExclusive = isLeftExclusive; - function isRightExclusive(rangeKind) { - return (rangeKind & 1) !== 0; - } - RangeKind2.isRightExclusive = isRightExclusive; -})(RangeKind || (RangeKind = {})); -function getRangeDelimiter(kind) { - const prefix = kind & 2 ? RangeExclusiveChar : ""; - const suffix = kind & 1 ? RangeExclusiveChar : ""; - return `${prefix}..${suffix}`; -} -function destructRangeNode(node) { - let kind; - let min2; - let max2; - if (node.children.length === 1) { - kind = 0; - min2 = max2 = node.children[0]; - } else if (node.children.length === 3) { - kind = getKind(node.children[1]); - min2 = node.children[0]; - max2 = node.children[2]; - } else if (LiteralNode2.is(node.children[0])) { - kind = getKind(node.children[0]); - max2 = node.children[1]; - } else { - kind = getKind(node.children[1]); - min2 = node.children[0]; - } - return { kind, min: min2, max: max2 }; - function getKind(delimiter) { - let ans = 0; - if (delimiter.value.startsWith(RangeExclusiveChar)) { - ans |= 2; - } - if (delimiter.value.endsWith(RangeExclusiveChar)) { - ans |= 1; - } - return ans; - } -} -var FloatRangeNode; -(function(FloatRangeNode2) { - function destruct(node) { - return destructRangeNode(node); - } - FloatRangeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:float_range"; - } - FloatRangeNode2.is = is; -})(FloatRangeNode || (FloatRangeNode = {})); -var PrimitiveArrayTypeNode; -(function(PrimitiveArrayTypeNode2) { - function destruct(node) { - let lengthRange; - let valueRange; - let afterBrackets = false; - for (const child of node.children) { - if (LiteralNode2.is(child) && child.value === "[]") { - afterBrackets = true; - } else if (LongRangeNode.is(child)) { - valueRange = child; - } else if (IntRangeNode.is(child)) { - if (afterBrackets) { - lengthRange = child; - } else { - valueRange = child; - } - } - } - return { arrayKind: node.children.find(LiteralNode2.is), lengthRange, valueRange }; - } - PrimitiveArrayTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/primitive_array"; - } - PrimitiveArrayTypeNode2.is = is; -})(PrimitiveArrayTypeNode || (PrimitiveArrayTypeNode = {})); -var ListTypeNode; -(function(ListTypeNode2) { - function destruct(node) { - return { - item: node.children.find(TypeNode.is), - lengthRange: node.children.find(IntRangeNode.is) - }; - } - ListTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/list"; - } - ListTypeNode2.is = is; -})(ListTypeNode || (ListTypeNode = {})); -var StringTypeNode; -(function(StringTypeNode2) { - function destruct(node) { - return { lengthRange: node.children.find(IntRangeNode.is) }; - } - StringTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/string"; - } - StringTypeNode2.is = is; -})(StringTypeNode || (StringTypeNode = {})); -var TupleTypeNode; -(function(TupleTypeNode2) { - function destruct(node) { - return { items: node.children.filter(TypeNode.is) }; - } - TupleTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/tuple"; - } - TupleTypeNode2.is = is; -})(TupleTypeNode || (TupleTypeNode = {})); -var EnumNode; -(function(EnumNode2) { - EnumNode2.Kinds = /* @__PURE__ */ new Set(["byte", "short", "int", "long", "float", "double", "string"]); - function destruct(node) { - return { - block: node.children.find(EnumBlockNode.is), - docComments: node.children.find(DocCommentsNode.is), - enumKind: getEnumKind(node), - identifier: node.children.find(IdentifierNode.is), - keyword: node.children.find(LiteralNode2.is) - }; - function getEnumKind(node2) { - for (const literal9 of node2.children.filter(LiteralNode2.is)) { - if (EnumNode2.Kinds.has(literal9.value)) { - return literal9.value; - } - } - return void 0; - } - } - EnumNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:enum"; - } - EnumNode2.is = is; -})(EnumNode || (EnumNode = {})); -var DocCommentsNode; -(function(DocCommentsNode2) { - function asText(node) { - if (!node) { - return void 0; - } - let comments = node.children.map((doc) => doc.comment); - if (comments.every((s) => !s.trim() || s.startsWith(" "))) { - comments = comments.map((s) => s.replace(/^ /, "")); - } - return comments.join("").trimEnd(); - } - DocCommentsNode2.asText = asText; - function is(node) { - return node?.type === "mcdoc:doc_comments"; - } - DocCommentsNode2.is = is; -})(DocCommentsNode || (DocCommentsNode = {})); -var EnumBlockNode; -(function(EnumBlockNode2) { - function destruct(node) { - return { fields: node.children.filter(EnumFieldNode.is) }; - } - EnumBlockNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:enum/block"; - } - EnumBlockNode2.is = is; -})(EnumBlockNode || (EnumBlockNode = {})); -var EnumFieldNode; -(function(EnumFieldNode2) { - function destruct(node) { - return { - attributes: node.children.filter(AttributeNode.is), - docComments: node.children.find(DocCommentsNode.is), - identifier: node.children.find(IdentifierNode.is), - value: node.children.find(EnumValueNode.is) - }; - } - EnumFieldNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:enum/field"; - } - EnumFieldNode2.is = is; -})(EnumFieldNode || (EnumFieldNode = {})); -var EnumValueNode; -(function(EnumValueNode2) { - function is(node) { - return TypedNumberNode.is(node) || StringNode.is(node); - } - EnumValueNode2.is = is; -})(EnumValueNode || (EnumValueNode = {})); -var PrelimNode; -(function(PrelimNode2) { - function is(node) { - return AttributeNode.is(node) || DocCommentsNode.is(node); - } - PrelimNode2.is = is; -})(PrelimNode || (PrelimNode = {})); -var StructNode; -(function(StructNode2) { - function destruct(node) { - return { - block: node.children.find(StructBlockNode.is), - docComments: node.children.find(DocCommentsNode.is), - identifier: node.children.find(IdentifierNode.is), - keyword: node.children.find(LiteralNode2.is) - }; - } - StructNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:struct"; - } - StructNode2.is = is; -})(StructNode || (StructNode = {})); -var ReferenceTypeNode; -(function(ReferenceTypeNode2) { - function destruct(node) { - return { path: node.children.find(PathNode.is) }; - } - ReferenceTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/reference"; - } - ReferenceTypeNode2.is = is; -})(ReferenceTypeNode || (ReferenceTypeNode = {})); -var TypeParamBlockNode; -(function(TypeParamBlockNode2) { - function destruct(node) { - return { params: node.children.filter(TypeParamNode.is) }; - } - TypeParamBlockNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type_param_block"; - } - TypeParamBlockNode2.is = is; -})(TypeParamBlockNode || (TypeParamBlockNode = {})); -var TypeParamNode; -(function(TypeParamNode2) { - function destruct(node) { - return { - // constraint: node.children.find(TypeNode.is), - identifier: node.children.find(IdentifierNode.is) - }; - } - TypeParamNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type_param"; - } - TypeParamNode2.is = is; -})(TypeParamNode || (TypeParamNode = {})); -var PathNode; -(function(PathNode2) { - function destruct(node) { - const lastChild = node?.children.at(-1); - return { - children: node?.children ?? [], - isAbsolute: node?.isAbsolute, - lastIdentifier: IdentifierNode.is(lastChild) ? lastChild : void 0 - }; - } - PathNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:path"; - } - PathNode2.is = is; -})(PathNode || (PathNode = {})); -var StructBlockNode; -(function(StructBlockNode2) { - function destruct(node) { - return { fields: node.children.filter(StructFieldNode.is) }; - } - StructBlockNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:struct/block"; - } - StructBlockNode2.is = is; -})(StructBlockNode || (StructBlockNode = {})); -var StructFieldNode; -(function(StructFieldNode2) { - function is(node) { - return StructPairFieldNode.is(node) || StructSpreadFieldNode.is(node); - } - StructFieldNode2.is = is; -})(StructFieldNode || (StructFieldNode = {})); -var StructPairFieldNode; -(function(StructPairFieldNode2) { - function destruct(node) { - return { - attributes: node.children.filter(AttributeNode.is), - docComments: node.children.find(DocCommentsNode.is), - key: node.children.find(StructKeyNode.is), - type: node.children.find(TypeNode.is), - isOptional: node.isOptional - }; - } - StructPairFieldNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:struct/field/pair"; - } - StructPairFieldNode2.is = is; -})(StructPairFieldNode || (StructPairFieldNode = {})); -var StructKeyNode; -(function(StructKeyNode2) { - function is(node) { - return StringNode.is(node) || IdentifierNode.is(node) || StructMapKeyNode.is(node); - } - StructKeyNode2.is = is; -})(StructKeyNode || (StructKeyNode = {})); -var StructMapKeyNode; -(function(StructMapKeyNode2) { - function destruct(node) { - return { type: node.children.find(TypeNode.is) }; - } - StructMapKeyNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:struct/map_key"; - } - StructMapKeyNode2.is = is; -})(StructMapKeyNode || (StructMapKeyNode = {})); -var StructSpreadFieldNode; -(function(StructSpreadFieldNode2) { - function destruct(node) { - return { - attributes: node.children.filter(AttributeNode.is), - type: node.children.find(TypeNode.is) - }; - } - StructSpreadFieldNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:struct/field/spread"; - } - StructSpreadFieldNode2.is = is; -})(StructSpreadFieldNode || (StructSpreadFieldNode = {})); -var DispatcherTypeNode; -(function(DispatcherTypeNode2) { - function destruct(node) { - return { - location: node.children.find(ResourceLocationNode.is), - index: node.children.find(IndexBodyNode.is) - }; - } - DispatcherTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/dispatcher"; - } - DispatcherTypeNode2.is = is; -})(DispatcherTypeNode || (DispatcherTypeNode = {})); -var UnionTypeNode; -(function(UnionTypeNode2) { - function destruct(node) { - return { members: node.children.filter(TypeNode.is) }; - } - UnionTypeNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type/union"; - } - UnionTypeNode2.is = is; -})(UnionTypeNode || (UnionTypeNode = {})); -var InjectionNode; -(function(InjectionNode2) { - function destruct(node) { - return { injection: node.children.find(InjectionContentNode.is) }; - } - InjectionNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:injection"; - } - InjectionNode2.is = is; -})(InjectionNode || (InjectionNode = {})); -var InjectionContentNode; -(function(InjectionContentNode2) { - function is(node) { - return EnumInjectionNode.is(node) || StructInjectionNode.is(node); - } - InjectionContentNode2.is = is; -})(InjectionContentNode || (InjectionContentNode = {})); -var EnumInjectionNode; -(function(EnumInjectionNode2) { - function is(node) { - return node?.type === "mcdoc:injection/enum"; - } - EnumInjectionNode2.is = is; -})(EnumInjectionNode || (EnumInjectionNode = {})); -var StructInjectionNode; -(function(StructInjectionNode2) { - function is(node) { - return node?.type === "mcdoc:injection/struct"; - } - StructInjectionNode2.is = is; -})(StructInjectionNode || (StructInjectionNode = {})); -var TypeAliasNode; -(function(TypeAliasNode2) { - function destruct(node) { - return { - attributes: node.children.filter(AttributeNode.is), - docComments: node.children.find(DocCommentsNode.is), - identifier: node.children.find(IdentifierNode.is), - keyword: node.children.find(LiteralNode2.is), - typeParams: node.children.find(TypeParamBlockNode.is), - rhs: node.children.find(TypeNode.is) - }; - } - TypeAliasNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:type_alias"; - } - TypeAliasNode2.is = is; -})(TypeAliasNode || (TypeAliasNode = {})); -var UseStatementNode; -(function(UseStatementNode2) { - function destruct(node) { - return { - binding: node.children.find(IdentifierNode.is), - path: node.children.find(PathNode.is) - }; - } - UseStatementNode2.destruct = destruct; - function is(node) { - return node?.type === "mcdoc:use_statement"; - } - UseStatementNode2.is = is; -})(UseStatementNode || (UseStatementNode = {})); - -// node_modules/@spyglassmc/mcdoc/lib/binder/index.js -var ModuleSymbolData; -(function(ModuleSymbolData2) { - function is(data) { - return !!data && typeof data === "object" && typeof data.nextAnonymousIndex === "number"; - } - ModuleSymbolData2.is = is; -})(ModuleSymbolData || (ModuleSymbolData = {})); -var TypeDefSymbolData; -(function(TypeDefSymbolData2) { - function is(data) { - return !!data && typeof data === "object" && typeof data.typeDef === "object"; - } - TypeDefSymbolData2.is = is; -})(TypeDefSymbolData || (TypeDefSymbolData = {})); -var fileModule = AsyncBinder.create(async (node, ctx) => { - const moduleIdentifier = uriToIdentifier(ctx.doc.uri, ctx); - if (!moduleIdentifier) { - ctx.err.report(localize("mcdoc.binder.out-of-root", localeQuote(ctx.doc.uri)), Range.Beginning, ErrorSeverity.Hint); - return; - } - const mcdocCtx = { ...ctx, moduleIdentifier }; - return module_(node, mcdocCtx); -}); -async function module_(node, ctx) { - const data = { nextAnonymousIndex: 0 }; - ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ctx.moduleIdentifier).amend({ - data: { data } - }); - hoist(node, { ...ctx, isHoisting: true }); - for (const child of node.children) { - switch (child.type) { - case "mcdoc:dispatch_statement": - await bindDispatchStatement(child, ctx); - break; - case "mcdoc:enum": - bindEnum(child, ctx); - break; - case "mcdoc:injection": - await bindInjection(child, ctx); - break; - case "mcdoc:struct": - await bindStruct(child, ctx); - break; - case "mcdoc:type_alias": - await bindTypeAlias(child, ctx); - break; - case "mcdoc:use_statement": - await bindUseStatement(child, ctx); - break; - } - } -} -function hoist(node, ctx) { - traversePreOrder(node, () => true, TopLevelNode.is, (child) => { - switch (child.type) { - case "mcdoc:enum": - hoistEnum(child); - break; - case "mcdoc:struct": - hoistStruct(child); - break; - case "mcdoc:type_alias": - hoistTypeAlias(child); - break; - case "mcdoc:use_statement": - hoistUseStatement(child); - break; - } - }); - function hoistEnum(node2) { - hoistFor("enum", node2, EnumNode.destruct, (n) => ({ typeDef: convertEnum(n, ctx) })); - } - function hoistStruct(node2) { - hoistFor("struct", node2, StructNode.destruct, (n) => ({ typeDef: convertStruct(n, ctx) })); - } - function hoistTypeAlias(node2) { - hoistFor("type_alias", node2, TypeAliasNode.destruct, (n) => { - const { attributes: attributes2, rhs, typeParams } = TypeAliasNode.destruct(n); - if (!rhs) { - return void 0; - } - const ans = { typeDef: convertType(rhs, ctx) }; - if (typeParams) { - bindTypeParamBlock(node2, typeParams, ans, ctx); - } - appendAttributes(ans.typeDef, attributes2, ctx); - return ans; - }); - } - function hoistUseStatement(node2) { - const { binding, path: path6 } = UseStatementNode.destruct(node2); - if (!path6) { - return; - } - const { lastIdentifier } = PathNode.destruct(path6); - const identifier4 = binding ?? lastIdentifier; - if (!identifier4) { - return; - } - const target = resolvePath(path6, ctx); - ctx.symbols.query({ doc: ctx.doc, node: node2 }, "mcdoc", `${ctx.moduleIdentifier}::${identifier4.value}`).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4)).elseEnter({ - data: { - subcategory: "use_statement_binding", - visibility: 1, - data: target ? { target } : void 0 - }, - usage: { type: "definition", node: identifier4, fullRange: node2 } - }); - } - function hoistFor(subcategory, node2, destructor, getData) { - const { docComments: docComments3, identifier: identifier4, keyword: keyword2 } = destructor(node2); - const name = identifier4?.value ?? nextAnonymousIdentifier(node2, ctx); - ctx.symbols.query({ doc: ctx.doc, node: node2 }, "mcdoc", `${ctx.moduleIdentifier}::${name}`).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4 ?? node2)).elseEnter({ - data: { data: getData(node2), desc: DocCommentsNode.asText(docComments3), subcategory }, - // If the current syntax structure is named, then the identifier node is entered as a definition; - // otherwise, an anonymous identifier is generated for the symbol and the keyword node is entered as a definition. - usage: { - type: "definition", - node: identifier4 ?? keyword2, - fullRange: identifier4 && node2 - } - }); - } - function nextAnonymousIndex(node2, ctx2) { - const data = ctx2.symbols.query({ doc: ctx2.doc, node: node2 }, "mcdoc", ctx2.moduleIdentifier).getData(ModuleSymbolData.is); - if (!data) { - throw new Error(`No symbol data for module '${ctx2.moduleIdentifier}'`); - } - return data.nextAnonymousIndex++; - } - function nextAnonymousIdentifier(node2, ctx2) { - return ``; - } -} -function bindTypeParamBlock(node, typeParams, data, ctx) { - node.locals = /* @__PURE__ */ Object.create(null); - data.typeDef = { kind: "template", child: data.typeDef, typeParams: [] }; - const { params } = TypeParamBlockNode.destruct(typeParams); - for (const param of params) { - const { identifier: paramIdentifier } = TypeParamNode.destruct(param); - if (paramIdentifier.value) { - const paramPath = `${ctx.moduleIdentifier}::${paramIdentifier.value}`; - ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", paramPath).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, paramIdentifier)).elseEnter({ - data: { - visibility: 0 - /* SymbolVisibility.Block */ - }, - usage: { type: "declaration", node: paramIdentifier, fullRange: param } - }); - data.typeDef.typeParams.push({ path: paramPath }); - } - } -} -async function bindDispatchStatement(node, ctx) { - const { attributes: attributes2, location, index: index4, target, typeParams } = DispatchStatementNode.destruct(node); - if (!(location && index4 && target)) { - return; - } - const locationStr = ResourceLocationNode.toString(location, "full"); - ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr).enter({ - usage: { type: "reference", node: location, fullRange: node } - }); - const { parallelIndices } = IndexBodyNode.destruct(index4); - if (parallelIndices.length) { - const data = { typeDef: convertType(target, ctx) }; - if (typeParams) { - bindTypeParamBlock(node, typeParams, data, ctx); - } - appendAttributes(data.typeDef, attributes2, ctx); - for (const key2 of parallelIndices) { - if (DynamicIndexNode.is(key2)) { - continue; - } - ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr, asString(key2)).ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, key2, { - localeString: "mcdoc.binder.dispatcher-statement.duplicated-key" - })).elseEnter({ data: { data }, usage: { type: "definition", node: key2, fullRange: node } }); - } - } - await bindType(target, ctx); -} -async function bindType(node, ctx) { - if (DispatcherTypeNode.is(node)) { - await bindDispatcherType(node, ctx); - } else if (EnumNode.is(node)) { - bindEnum(node, ctx); - } else if (ListTypeNode.is(node)) { - const { item } = ListTypeNode.destruct(node); - await bindType(item, ctx); - } else if (ReferenceTypeNode.is(node)) { - const { path: path6 } = ReferenceTypeNode.destruct(node); - await bindPath(path6, ctx); - } else if (StructNode.is(node)) { - await bindStruct(node, ctx); - } else if (TupleTypeNode.is(node)) { - const { items } = TupleTypeNode.destruct(node); - for (const item of items) { - await bindType(item, ctx); - } - } else if (UnionTypeNode.is(node)) { - const { members } = UnionTypeNode.destruct(node); - for (const member of members) { - await bindType(member, ctx); - } - } - const { appendixes } = TypeBaseNode.destruct(node); - for (const appendix of appendixes) { - if (TypeArgBlockNode.is(appendix)) { - const { args } = TypeArgBlockNode.destruct(appendix); - for (const arg of args) { - await bindType(arg, ctx); - } - } - } -} -async function bindDispatcherType(node, ctx) { - const { index: index4, location } = DispatcherTypeNode.destruct(node); - const locationStr = ResourceLocationNode.toString(location, "full"); - ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr).enter({ - usage: { type: "reference", node: location, fullRange: node } - }); - const { parallelIndices } = IndexBodyNode.destruct(index4); - for (const key2 of parallelIndices) { - if (DynamicIndexNode.is(key2)) { - continue; - } - ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", locationStr, asString(key2)).enter({ - usage: { type: "reference", node: key2, fullRange: node } - }); - } -} -async function bindPath(node, ctx) { - for (const { identifiers, node: identNode, indexRight } of resolvePathByStep(node, ctx, { - reportErrors: true - })) { - if (!identifiers?.length) { - continue; - } - if (indexRight === 1) { - const referencedModuleFile = pathArrayToString(identifiers); - const referencedModuleUri = identifierToUri(referencedModuleFile, ctx); - if (!referencedModuleUri) { - ctx.err.report(localize("mcdoc.binder.path.unknown-module", localeQuote(referencedModuleFile)), node, ErrorSeverity.Warning); - return; - } - await ctx.ensureBindingStarted(referencedModuleUri); - } - ctx.symbols.query({ doc: ctx.doc, node: identNode }, "mcdoc", pathArrayToString(identifiers)).ifDeclared((_, query) => query.enter({ - usage: { - type: "reference", - node: identNode, - fullRange: node, - skipRenaming: LiteralNode2.is(identNode) - } - })).else(() => { - if (indexRight === 0) { - ctx.err.report(localize("mcdoc.binder.path.unknown-identifier", localeQuote(identifiers.at(-1)), localeQuote(pathArrayToString(identifiers.slice(0, -1)))), node, ErrorSeverity.Warning); - } - }); - } -} -function bindEnum(node, ctx) { - const { block: block4, identifier: identifier4, keyword: keyword2 } = EnumNode.destruct(node); - const symbol7 = identifier4?.symbol ?? keyword2.symbol; - if (symbol7?.subcategory !== "enum") { - return; - } - const query = ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ...symbol7.path); - Dev.assertDefined(query.symbol); - bindEnumBlock(block4, ctx, query); -} -function bindEnumBlock(node, ctx, query, options2 = {}) { - const { fields } = EnumBlockNode.destruct(node); - for (const field of fields) { - const { identifier: identifier4 } = EnumFieldNode.destruct(field); - query.member(identifier4.value, (fieldQuery) => fieldQuery.ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, identifier4)).elseEnter({ usage: { type: "definition", node: identifier4, fullRange: field } })); - } -} -async function bindInjection(node, ctx) { - const { injection: injection3 } = InjectionNode.destruct(node); - if (EnumInjectionNode.is(injection3)) { - } -} -async function bindStruct(node, ctx) { - const { block: block4, identifier: identifier4, keyword: keyword2 } = StructNode.destruct(node); - const symbol7 = identifier4?.symbol ?? keyword2.symbol; - if (symbol7?.subcategory !== "struct") { - return; - } - const query = ctx.symbols.query({ doc: ctx.doc, node }, "mcdoc", ...symbol7.path); - Dev.assertDefined(query.symbol); - await bindStructBlock(block4, ctx, query); -} -async function bindStructBlock(node, ctx, query, options2 = {}) { - const { fields } = StructBlockNode.destruct(node); - for (const field of fields) { - if (StructPairFieldNode.is(field)) { - const { key: key2, type: type2 } = StructPairFieldNode.destruct(field); - if (!StructMapKeyNode.is(key2)) { - query.member(key2.value, (fieldQuery) => fieldQuery.ifDeclared((symbol7) => reportDuplicatedDeclaration(ctx, symbol7, key2)).elseEnter({ usage: { type: "definition", node: key2, fullRange: field } })); - } - await bindType(type2, ctx); - } else { - const { type: type2 } = StructSpreadFieldNode.destruct(field); - await bindType(type2, ctx); - } - } -} -async function bindTypeAlias(node, ctx) { - const { identifier: identifier4, rhs, typeParams } = TypeAliasNode.destruct(node); - if (!identifier4?.value) { - return; - } - if (rhs) { - await bindType(rhs, ctx); - } -} -async function bindUseStatement(node, ctx) { - const { path: path6 } = UseStatementNode.destruct(node); - if (!path6) { - return; - } - return bindPath(path6, ctx); -} -function registerMcdocBinders(meta) { - meta.registerBinder("mcdoc:module", fileModule); -} -function reportDuplicatedDeclaration(ctx, symbol7, range3, options2 = { localeString: "mcdoc.binder.duplicated-declaration" }) { - ctx.err.report(localize(options2.localeString, localeQuote(symbol7.identifier)), range3, ErrorSeverity.Warning, { - related: [{ - location: SymbolUtil.getDeclaredLocation(symbol7), - message: localize(`${options2.localeString}.related`, localeQuote(symbol7.identifier)) - }] - }); -} -function* resolvePathByStep(path6, ctx, options2 = {}) { - const { children, isAbsolute } = PathNode.destruct(path6); - let identifiers = isAbsolute ? [] : pathStringToArray(ctx.moduleIdentifier); - for (const [i, child] of children.entries()) { - const indexRight = children.length - 1 - i; - switch (child.type) { - case "mcdoc:identifier": - identifiers.push(child.value); - if (indexRight === 0) { - ctx.symbols.query({ doc: ctx.doc, node: child }, "mcdoc", pathArrayToString(identifiers)).ifDeclared((symbol7) => { - const data = symbol7.data; - if (data?.target) { - identifiers = [...data.target]; - } - }); - } - break; - case "mcdoc:literal": - if (identifiers.length === 0) { - if (options2.reportErrors) { - ctx.err.report(localize("mcdoc.binder.path.super-from-root"), child); - } - return; - } - identifiers.pop(); - break; - default: - Dev.assertNever(child); - } - yield { identifiers, node: child, index: i, indexRight }; - } -} -function resolvePath(path6, ctx, options2 = {}) { - return [...resolvePathByStep(path6, ctx, options2)].at(-1)?.identifiers; -} -function identifierToUri(module3, ctx) { - return ctx.symbols.global.mcdoc?.[module3]?.definition?.[0]?.uri; -} -function uriToIdentifier(uri, ctx) { - return Object.values(ctx.symbols.global.mcdoc ?? {}).find((symbol7) => { - return symbol7.subcategory === "module" && symbol7.definition?.some((loc) => loc.uri === uri); - })?.identifier; -} -function pathArrayToString(path6) { - return path6 ? `::${path6.join("::")}` : void 0; -} -function pathStringToArray(path6) { - if (!path6.startsWith("::")) { - throw new Error("Only absolute paths are supported"); - } - return path6.slice(2).split("::"); -} -function convertType(node, ctx) { - switch (node.type) { - case "mcdoc:enum": - return convertEnum(node, ctx); - case "mcdoc:struct": - return convertStruct(node, ctx); - case "mcdoc:type/any": - return convertAny(node, ctx); - case "mcdoc:type/boolean": - return convertBoolean(node, ctx); - case "mcdoc:type/dispatcher": - return convertDispatcher(node, ctx); - case "mcdoc:type/list": - return convertList(node, ctx); - case "mcdoc:type/literal": - return convertLiteral(node, ctx); - case "mcdoc:type/numeric_type": - return convertNumericType(node, ctx); - case "mcdoc:type/primitive_array": - return convertPrimitiveArray(node, ctx); - case "mcdoc:type/string": - return convertString(node, ctx); - case "mcdoc:type/reference": - return convertReference(node, ctx); - case "mcdoc:type/tuple": - return convertTuple(node, ctx); - case "mcdoc:type/union": - return convertUnion(node, ctx); - default: - return Dev.assertNever(node); - } -} -function wrapType(node, type2, ctx, options2 = {}) { - const { attributes: attributes2, appendixes } = TypeBaseNode.destruct(node); - let ans = type2; - for (const appendix of appendixes) { - if (IndexBodyNode.is(appendix)) { - if (options2.skipFirstIndexBody) { - options2.skipFirstIndexBody = false; - continue; - } - ans = { kind: "indexed", child: ans, parallelIndices: convertIndexBody(appendix, ctx) }; - } else { - ans = { kind: "concrete", child: ans, typeArgs: convertTypeArgBlock(appendix, ctx) }; - } - } - ans.attributes = convertAttributes(attributes2, ctx); - return ans; -} -function appendAttributes(typeDef, attributes2, ctx) { - const convertedAttributes = convertAttributes(attributes2, ctx); - if (convertedAttributes) { - if (typeDef.attributes) { - typeDef.attributes = [...typeDef.attributes, ...convertedAttributes]; - } else { - typeDef.attributes = convertedAttributes; - } - } -} -function convertAttributes(nodes, ctx) { - return undefineEmptyArray(nodes.map((n) => convertAttribute(n, ctx))); -} -function undefineEmptyArray(array4) { - return array4.length ? array4 : void 0; -} -function convertAttribute(node, ctx) { - const { name, value } = AttributeNode.destruct(node); - return { name: name.value, value: value && convertAttributeValue(value, ctx) }; -} -function convertAttributeValue(node, ctx) { - if (node.type === "mcdoc:attribute/tree") { - return { kind: "tree", values: convertAttributeTree(node, ctx) }; - } else { - return convertType(node, ctx); - } -} -function convertAttributeTree(node, ctx) { - const ans = {}; - const { named, positional } = AttributeTreeNode.destruct(node); - if (positional) { - const { values } = AttributeTreePosValuesNode.destruct(positional); - for (const [i, child] of values.entries()) { - ans[i] = convertAttributeValue(child, ctx); - } - } - if (named) { - const { values } = AttributeTreeNamedValuesNode.destruct(named); - for (const { key: key2, value } of values) { - ans[key2.value] = convertAttributeValue(value, ctx); - } - } - return ans; -} -function convertIndexBody(node, ctx) { - const { parallelIndices } = IndexBodyNode.destruct(node); - return parallelIndices.map((n) => convertIndex(n, ctx)); -} -function convertIndex(node, ctx) { - return StaticIndexNode.is(node) ? convertStaticIndex(node, ctx) : convertDynamicIndex(node, ctx); -} -function convertStaticIndex(node, ctx) { - return { kind: "static", value: asString(node) }; -} -function convertDynamicIndex(node, ctx) { - const { keys } = DynamicIndexNode.destruct(node); - return { - kind: "dynamic", - accessor: keys.map((key2) => { - if (LiteralNode2.is(key2) && key2.value.startsWith("%")) { - return { keyword: key2.value.slice(1) }; - } - return asString(key2); - }) - }; -} -function convertTypeArgBlock(node, ctx) { - const { args } = TypeArgBlockNode.destruct(node); - return args.map((a) => convertType(a, ctx)); -} -function convertEnum(node, ctx) { - const { block: block4, enumKind, identifier: identifier4 } = EnumNode.destruct(node); - if (identifier4 && !ctx.isHoisting) { - return wrapType(node, { - kind: "reference", - path: `${ctx.moduleIdentifier}::${identifier4.value}` - }, ctx); - } - const symbol7 = identifier4?.symbol ?? node.symbol; - if (symbol7 && TypeDefSymbolData.is(symbol7.data) && symbol7.data.typeDef.kind === "enum") { - return symbol7.data.typeDef; - } - switch (enumKind) { - case "byte": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumIntValue(enumKind, "b"), ctx) - }, ctx); - case "short": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumIntValue(enumKind, "s"), ctx) - }, ctx); - case "int": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumIntValue(enumKind), ctx) - }, ctx); - case "long": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumLongValue, ctx) - }, ctx); - case "float": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumFloatValue(enumKind, "f"), ctx) - }, ctx); - case "double": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumFloatValue(enumKind, "d"), ctx) - }, ctx); - case "string": - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumStringValue, ctx) - }, ctx); - case void 0: - return wrapType(node, { - kind: "enum", - enumKind, - values: convertEnumBlock(block4, convertEnumValue, ctx) - }, ctx); - } -} -function convertEnumBlock(node, getEnumFieldValue, ctx) { - const { fields } = EnumBlockNode.destruct(node); - return fields.map((n) => convertEnumField(n, getEnumFieldValue, ctx)); -} -function convertEnumField(node, getEnumFieldValue, ctx) { - const { attributes: attributes2, docComments: docComments3, identifier: identifier4, value } = EnumFieldNode.destruct(node); - return { - attributes: convertAttributes(attributes2, ctx), - desc: DocCommentsNode.asText(docComments3), - identifier: identifier4.value, - value: getEnumFieldValue(value, ctx) - }; -} -function convertEnumIntValue(expected, expectedSuffix) { - return (node, ctx) => { - const { value: valueNode, suffix: suffixNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; - const value = Math.floor(typeof valueNode.value === "string" ? Number.parseFloat(valueNode.value) : Number(valueNode.value)); - const suffix = suffixNode?.value.toLowerCase(); - if (suffix !== expectedSuffix || !IntegerNode.is(valueNode)) { - ctx.err.report(localize("expected", localize(expected)), node); - } - return value; - }; -} -function convertEnumFloatValue(expected, expectedSuffix) { - return (node, ctx) => { - const { value: valueNode, suffix: suffixNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; - const value = typeof valueNode.value === "string" ? Number.parseFloat(valueNode.value) : Number(valueNode.value); - const suffix = suffixNode?.value.toLowerCase(); - if (suffix !== expectedSuffix && (expectedSuffix !== "d" || suffix !== void 0 || !FloatNode.is(valueNode))) { - ctx.err.report(localize("expected", localize(expected)), node); - } - return value; - }; -} -function convertEnumStringValue(node, ctx) { - const { value: valueNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; - const value = typeof valueNode.value === "string" ? valueNode.value : valueNode.value.toString(); - if (!StringNode.is(valueNode)) { - ctx.err.report(localize("expected", localize("string")), node); - } - return value; -} -function convertEnumLongValue(node, ctx) { - const { value: valueNode } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; - let value = valueNode.value; - if (typeof value === "string") { - if (/^-?\d+$/.test(value)) { - value = BigInt(value); - } else { - value = parseFloat(value); - } - } - if (typeof value === "number") { - if (isNaN(value) || !isFinite(value)) { - value = 0n; - } else { - value = BigInt(Math.floor(value)); - } - } - if (!LongNode.is(valueNode)) { - ctx.err.report(localize("expected", localize("long")), node); - } - return value; -} -function convertEnumValue(node, ctx) { - const { value } = TypedNumberNode.is(node) ? TypedNumberNode.destruct(node) : { value: node }; - return value.value; -} -function convertStruct(node, ctx) { - const { block: block4, identifier: identifier4 } = StructNode.destruct(node); - if (identifier4 && !ctx.isHoisting) { - return wrapType(node, { - kind: "reference", - path: `${ctx.moduleIdentifier}::${identifier4.value}` - }, ctx); - } - const symbol7 = identifier4?.symbol ?? node.symbol; - if (symbol7 && TypeDefSymbolData.is(symbol7.data) && symbol7.data.typeDef.kind === "struct") { - return symbol7.data.typeDef; - } - return wrapType(node, { kind: "struct", fields: convertStructBlock(block4, ctx) }, ctx); -} -function convertStructBlock(node, ctx) { - const { fields } = StructBlockNode.destruct(node); - return fields.map((n) => convertStructField(n, ctx)); -} -function convertStructField(node, ctx) { - return StructPairFieldNode.is(node) ? convertStructPairField(node, ctx) : convertStructSpreadField(node, ctx); -} -function convertStructPairField(node, ctx) { - const { attributes: attributes2, docComments: docComments3, key: key2, type: type2, isOptional } = StructPairFieldNode.destruct(node); - return { - kind: "pair", - attributes: convertAttributes(attributes2, ctx), - desc: DocCommentsNode.asText(docComments3), - key: convertStructKey(key2, ctx), - type: convertType(type2, ctx), - optional: isOptional - }; -} -function convertStructKey(node, ctx) { - if (StructMapKeyNode.is(node)) { - const { type: type2 } = StructMapKeyNode.destruct(node); - return convertType(type2, ctx); - } else { - return asString(node); - } -} -function convertStructSpreadField(node, ctx) { - const { attributes: attributes2, type: type2 } = StructSpreadFieldNode.destruct(node); - return { - kind: "spread", - attributes: convertAttributes(attributes2, ctx), - type: convertType(type2, ctx) - }; -} -function convertAny(node, ctx) { - return wrapType(node, { kind: "any" }, ctx); -} -function convertBoolean(node, ctx) { - return wrapType(node, { kind: "boolean" }, ctx); -} -function convertDispatcher(node, ctx) { - const { index: index4, location } = DispatcherTypeNode.destruct(node); - return wrapType(node, { - kind: "dispatcher", - parallelIndices: convertIndexBody(index4, ctx), - registry: ResourceLocationNode.toString(location, "full") - }, ctx, { skipFirstIndexBody: true }); -} -function convertList(node, ctx) { - const { item, lengthRange } = ListTypeNode.destruct(node); - return wrapType(node, { - kind: "list", - item: convertType(item, ctx), - lengthRange: convertRange(lengthRange) - }, ctx); -} -function convertRange(node) { - if (!node) { - return void 0; - } - if (LongRangeNode.is(node)) { - const { kind: kind2, min: min3, max: max3 } = LongRangeNode.destruct(node); - return { kind: kind2, min: min3?.value, max: max3?.value }; - } - const { kind, min: min2, max: max2 } = FloatRangeNode.is(node) ? FloatRangeNode.destruct(node) : IntRangeNode.destruct(node); - return { kind, min: min2?.value, max: max2?.value }; -} -function convertLiteral(node, ctx) { - const { value } = LiteralTypeNode.destruct(node); - return wrapType(node, { kind: "literal", value: convertLiteralValue(value, ctx) }, ctx); -} -function convertLiteralValue(node, ctx) { - if (LiteralNode2.is(node)) { - return { kind: "boolean", value: node.value === "true" }; - } else if (TypedNumberNode.is(node)) { - const { suffix, value } = TypedNumberNode.destruct(node); - return { - kind: convertLiteralNumberSuffix(suffix, ctx) ?? (value.type === "integer" ? "int" : "double"), - value: value.value - }; - } else { - return { kind: "string", value: node.value }; - } -} -function convertLiteralNumberSuffix(node, ctx) { - const suffix = node?.value; - switch (suffix?.toLowerCase()) { - case "b": - return "byte"; - case "s": - return "short"; - case "l": - return "long"; - case "f": - return "float"; - case "d": - return "double"; - default: - return void 0; - } -} -function convertNumericType(node, ctx) { - const { numericKind, valueRange } = NumericTypeNode.destruct(node); - return wrapType(node, { - kind: numericKind.value, - valueRange: convertRange(valueRange) - }, ctx); -} -function convertPrimitiveArray(node, ctx) { - const { arrayKind, lengthRange, valueRange } = PrimitiveArrayTypeNode.destruct(node); - return wrapType(node, { - kind: `${arrayKind.value}_array`, - lengthRange: convertRange(lengthRange), - valueRange: convertRange(valueRange) - }, ctx); -} -function convertString(node, ctx) { - const { lengthRange } = StringTypeNode.destruct(node); - return wrapType(node, { kind: "string", lengthRange: convertRange(lengthRange) }, ctx); -} -function convertReference(node, ctx) { - const { path: path6 } = ReferenceTypeNode.destruct(node); - return wrapType(node, { kind: "reference", path: pathArrayToString(resolvePath(path6, ctx)) }, ctx); -} -function convertTuple(node, ctx) { - const { items } = TupleTypeNode.destruct(node); - return wrapType(node, { kind: "tuple", items: items.map((n) => convertType(n, ctx)) }, ctx); -} -function convertUnion(node, ctx) { - const { members } = UnionTypeNode.destruct(node); - return wrapType(node, { kind: "union", members: members.map((n) => convertType(n, ctx)) }, ctx); -} -function asString(node) { - if (ResourceLocationNode.is(node)) { - return ResourceLocationNode.toString(node, "short"); - } - return node.value; -} - -// node_modules/@spyglassmc/mcdoc/lib/checker/index.js -var reference = (node, ctx) => { - const { path: path6 } = ReferenceTypeNode.destruct(node); - const { children } = PathNode.destruct(path6); - const symbol7 = children.findLast((c) => c.symbol && c.symbol.category === "mcdoc" && c.symbol.subcategory !== "module")?.symbol; - if (!TypeDefSymbolData.is(symbol7?.data)) { - return; - } - const { appendixes } = TypeBaseNode.destruct(node); - let typeArgs = []; - if (TypeArgBlockNode.is(appendixes[0])) { - const { args } = TypeArgBlockNode.destruct(appendixes[0]); - typeArgs = args; - } - let typeParams = []; - if (symbol7.data.typeDef.kind === "template") { - typeParams = symbol7.data.typeDef.typeParams; - } - if (typeParams.length !== typeArgs.length) { - ctx.err.report(localize("mcdoc.checker.reference.unexpected-number-of-type-arguments", symbol7.identifier, typeParams.length, typeArgs.length), node); - } -}; -function registerMcdocChecker(meta) { - meta.registerChecker("mcdoc:type/reference", reference); -} - -// node_modules/@spyglassmc/mcdoc/lib/colorizer/index.js -var identifier = (node) => { - return [ColorToken.create(node, "variable")]; -}; -var literal5 = (node) => { - return [ColorToken.create(node, node.colorTokenType ?? "literal")]; -}; -function registerMcdocColorizer(meta) { - meta.registerColorizer("mcdoc:literal", literal5); - meta.registerColorizer("mcdoc:identifier", identifier); -} - -// node_modules/@spyglassmc/mcdoc/lib/type/index.js -var Attributes; -(function(Attributes2) { - function equals(a, b) { - if (a?.length !== b?.length) { - return false; - } - if (!a || !b) { - return true; - } - for (let i = 0; i < a.length; i++) { - if (!Attribute.equals(a[i], b[i])) { - return false; - } - } - return true; - } - Attributes2.equals = equals; -})(Attributes || (Attributes = {})); -var Attribute; -(function(Attribute2) { - function equals(a, b) { - if (a.name !== b.name) { - return false; - } - if (a.value && b.value) { - return AttributeValue.equals(a.value, b.value); - } - return a.value === b.value; - } - Attribute2.equals = equals; -})(Attribute || (Attribute = {})); -var AttributeValue; -(function(AttributeValue2) { - function equals(a, b) { - if (a.kind !== b.kind) { - return false; - } - if (a.kind === "tree") { - if (Object.keys(a.values).length !== Object.keys(b.values).length) { - return false; - } - for (const kvp of Object.entries(a.values)) { - const other = b.values[kvp[0]]; - if (!other) { - return false; - } - if (!equals(kvp[1], other)) { - return false; - } - } - return true; - } else { - return McdocType.equals(a, b); - } - } - AttributeValue2.equals = equals; -})(AttributeValue || (AttributeValue = {})); -var NumericRange; -(function(NumericRange2) { - function isInRange(range3, val) { - const { min: min2 = -Infinity, max: max2 = Infinity } = range3; - if (RangeKind.isLeftExclusive(range3.kind) ? val <= min2 : val < min2) { - return false; - } - if (RangeKind.isRightExclusive(range3.kind) ? val >= max2 : val > max2) { - return false; - } - return true; - } - NumericRange2.isInRange = isInRange; - function equals(a, b) { - return a.kind === b.kind && numericEquals(a.min, b.min) && numericEquals(a.max, b.max); - } - NumericRange2.equals = equals; - function intersect(a, b) { - const rangeMin = a.min !== void 0 && b.min !== void 0 ? max(a.min, b.min) : a.min ?? b.min; - const rangeMax = a.max !== void 0 && b.max !== void 0 ? min(a.max, b.max) : a.max ?? b.max; - let kind = 0; - if (numericEquals(rangeMin, a.min) && RangeKind.isLeftExclusive(a.kind)) { - kind |= 2; - } else if (numericEquals(rangeMin, b.min) && RangeKind.isLeftExclusive(b.kind)) { - kind |= 2; - } - if (numericEquals(rangeMax, a.max) && RangeKind.isRightExclusive(a.kind)) { - kind |= 1; - } else if (numericEquals(rangeMax, b.max) && RangeKind.isRightExclusive(b.kind)) { - kind |= 1; - } - return { kind, min: rangeMin, max: rangeMax }; - } - NumericRange2.intersect = intersect; - function toString({ kind, min: min2, max: max2 }) { - return min2 === max2 && kind === 0 ? min2 !== void 0 ? `${min2}` : getRangeDelimiter(kind) : `${min2 ?? ""}${getRangeDelimiter(kind)}${max2 ?? ""}`; - } - NumericRange2.toString = toString; -})(NumericRange || (NumericRange = {})); -var StaticIndexKeywords = Object.freeze(["fallback", "none", "unknown", "spawnitem", "blockitem"]); -var ParallelIndices; -(function(ParallelIndices2) { - function equals(a, b) { - if (a.length !== b.length) { - return false; - } - for (let i = 0; i < a.length; i++) { - const first = a[i]; - const second = b[i]; - if (first.kind !== second.kind) { - return false; - } - if (first.kind === "static") { - return first.value !== second.value; - } - if (first.accessor.length !== second.accessor.length) { - return false; - } - for (let j = 0; j < first.accessor.length; j++) { - const firstAcc = first.accessor[j]; - const secondAcc = second.accessor[j]; - if (typeof firstAcc === "string" || typeof secondAcc === "string") { - if (firstAcc !== secondAcc) { - return false; - } - } else if (firstAcc.keyword !== secondAcc.keyword) { - return false; - } - } - } - return true; - } - ParallelIndices2.equals = equals; -})(ParallelIndices || (ParallelIndices = {})); -var EmptyUnion = Object.freeze({ kind: "union", members: [] }); -var LiteralNumericValue; -(function(LiteralNumericValue2) { - function makeIfValid(kind, value, allowInt = true, allowFloat = true) { - value = Number(value); - switch (kind) { - case "byte": - if (allowInt && value >= -128 && value < 128) { - return { kind: "byte", value }; - } - break; - case "short": - if (allowInt && value >= -32768 && value < 32768) { - return { kind: "short", value }; - } - break; - case "int": - if (allowInt && value >= -2147483648 && value < 2147483648) { - return { kind: "int", value }; - } - break; - case "long": - if (allowInt && value >= -9223372036854775808n && value < 9223372036854775808n) { - return { kind: "long", value: BigInt(value) }; - } - break; - case "float": - if (allowFloat) { - return { kind: "float", value }; - } - break; - case "double": - if (allowFloat) { - return { kind: "double", value }; - } - break; - } - return void 0; - } - LiteralNumericValue2.makeIfValid = makeIfValid; -})(LiteralNumericValue || (LiteralNumericValue = {})); -var NumericTypeIntKinds = Object.freeze(["byte", "short", "int", "long"]); -var NumericTypeFloatKinds = Object.freeze(["float", "double"]); -var NumericTypeKinds = Object.freeze([...NumericTypeIntKinds, ...NumericTypeFloatKinds]); -var PrimitiveArrayValueKinds = Object.freeze(["byte", "int", "long"]); -var PrimitiveArrayKinds = Object.freeze(PrimitiveArrayValueKinds.map((kind) => `${kind}_array`)); -var McdocType; -(function(McdocType2) { - function equals(a, b) { - if (a.kind !== b.kind) { - return false; - } - if (!Attributes.equals(a.attributes, b.attributes)) { - return false; - } - switch (a.kind) { - case "literal": - return a.value.kind === b.value.kind && a.value.value === b.value.value; - case "byte": - case "short": - case "int": - case "long": - case "float": - case "double": - return a.valueRange === b.valueRange; - case "string": - return a.lengthRange === b.lengthRange; - case "byte_array": - case "int_array": - case "long_array": - return a.lengthRange === b.lengthRange && a.valueRange === b.valueRange; - case "list": - return a.lengthRange === b.lengthRange && equals(a.item, b.item); - case "tuple": - if (a.items.length !== b.items.length) { - return false; - } - for (let i = 0; i < a.items.length; i++) { - if (!equals(a.items[i], b.items[i])) { - return false; - } - } - return true; - case "struct": - return a.fields.length === b.fields.length && !a.fields.some((f) => { - if (f.kind === "pair") { - return !b.fields.some((of) => of.kind === "pair" && f.optional === of.optional && f.deprecated === of.deprecated && Attributes.equals(f.attributes, of.attributes) && (typeof f.key === "string" || typeof of.key === "string" ? f.key === of.key : equals(f.key, of.key)) && equals(f.type, of.type)); - } - return !b.fields.some((of) => of.kind === "spread" && Attributes.equals(f.attributes, of.attributes) && equals(f.type, of.type)); - }); - case "union": - if (a.members.length !== b.members.length) { - return false; - } - for (let i = 0; i < a.members.length; i++) { - if (!equals(a.members[i], b.members[i])) { - return false; - } - } - return true; - case "enum": - if (a.enumKind !== b.enumKind || a.values.length !== b.values.length) { - return false; - } - for (let i = 0; i < a.values.length; i++) { - const first = a.values[i]; - const second = b.values[i]; - if (first.identifier !== second.identifier || first.value !== second.value || !Attributes.equals(first.attributes, second.attributes)) { - return false; - } - } - return true; - case "reference": - return a.path === b.path; - case "template": - if (a.typeParams.length !== b.typeParams.length) { - return false; - } - for (let i = 0; i < a.typeParams.length; i++) { - if (a.typeParams[i].path !== b.typeParams[i].path) { - return false; - } - } - return equals(a.child, b.child); - case "concrete": - if (a.typeArgs.length !== b.typeArgs.length) { - return false; - } - for (let i = 0; i < a.typeArgs.length; i++) { - if (!equals(a.typeArgs[i], b.typeArgs[i])) { - return false; - } - } - return equals(a.child, b.child); - case "indexed": - if (ParallelIndices.equals(a.parallelIndices, b.parallelIndices)) { - return false; - } - return equals(a.child, b.child); - case "dispatcher": - if (a.registry !== b.registry) { - return false; - } - return ParallelIndices.equals(a.parallelIndices, b.parallelIndices); - case "mapped": - if (Object.keys(a.mapping).length !== Object.keys(b.mapping).length) { - return false; - } - for (const kvp of Object.entries(a.mapping)) { - const other = b.mapping[kvp[0]]; - if (!other) { - return false; - } - if (!equals(kvp[1], other)) { - return false; - } - } - return equals(a.child, b.child); - default: - return true; - } - } - McdocType2.equals = equals; - function toString(type2) { - const rangeToString = (range3) => { - return range3 ? ` @ ${NumericRange.toString(range3)}` : ""; - }; - const indicesToString = (indices) => { - const strings = []; - for (const index4 of Arrayable.toArray(indices)) { - if (index4 === void 0) { - strings.push("()"); - } else { - strings.push(index4.kind === "static" ? `[${index4.value}]` : `[[${index4.accessor.map((v) => typeof v === "string" ? v : v.keyword).join(".")}]]`); - } - } - return `[${strings.join(", ")}]`; - }; - if (type2 === void 0) { - return ""; - } - let attributesString = ""; - if (type2.attributes?.length) { - for (const attribute3 of type2.attributes) { - attributesString += `#[${attribute3.name}${attribute3.value ? "=" : ""}] `; - } - } - let typeString; - switch (type2.kind) { - case "any": - case "boolean": - typeString = type2.kind; - break; - case "byte": - typeString = `byte${rangeToString(type2.valueRange)}`; - break; - case "byte_array": - typeString = `byte${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; - break; - case "concrete": - typeString = `${toString(type2.child)}${type2.typeArgs.length ? `<${type2.typeArgs.map(toString).join(", ")}>` : ""}`; - break; - case "dispatcher": - typeString = `${type2.registry ?? "spyglass:unknown"}[${indicesToString(type2.parallelIndices)}]`; - break; - case "double": - typeString = `double${rangeToString(type2.valueRange)}`; - break; - case "enum": - typeString = ""; - break; - case "float": - typeString = `float${rangeToString(type2.valueRange)}`; - break; - case "indexed": - typeString = `${toString(type2.child)}${indicesToString(type2.parallelIndices)}`; - break; - case "int": - typeString = `int${rangeToString(type2.valueRange)}`; - break; - case "int_array": - typeString = `int${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; - break; - case "list": - typeString = `[${toString(type2.item)}]${rangeToString(type2.lengthRange)}`; - break; - case "literal": - typeString = `${type2.value.value}`; - break; - case "long": - typeString = `long${rangeToString(type2.valueRange)}`; - break; - case "long_array": - typeString = `long${rangeToString(type2.valueRange)}[]${rangeToString(type2.lengthRange)}`; - break; - case "mapped": - typeString = toString(type2.child); - break; - case "reference": - typeString = type2.path ?? ""; - break; - case "short": - typeString = `short${rangeToString(type2.valueRange)}`; - break; - case "string": - typeString = `string${rangeToString(type2.lengthRange)}`; - break; - case "struct": - typeString = ""; - break; - case "template": - typeString = `${toString(type2.child)}${type2.typeParams.length ? `<${type2.typeParams.map((v) => `?${v.path}`).join(", ")}>` : ""}`; - break; - case "tuple": - typeString = `[${type2.items.map((v) => toString(v)).join(",")}${type2.items.length === 1 ? "," : ""}]`; - break; - case "union": - typeString = `(${type2.members.map(toString).join(" | ")})`; - break; - case "unsafe": - typeString = "unsafe"; - break; - default: - Dev.assertNever(type2); - } - return attributesString + typeString; - } - McdocType2.toString = toString; -})(McdocType || (McdocType = {})); - -// node_modules/@spyglassmc/mcdoc/lib/parser/index.js -var comment4 = validate(comment3({ singleLinePrefixes: /* @__PURE__ */ new Set(["//"]) }), (res, src) => !src.slice(res).startsWith("///"), localize("mcdoc.parser.syntax.doc-comment-unexpected")); -function syntaxGap(delegatesDocComments = false) { - return (src, ctx) => { - const ans = []; - src.skipWhitespace(); - while (src.canRead() && src.peek(2) === "//" && (!delegatesDocComments || src.peek(3) !== "///")) { - const result = comment4(src, ctx); - ans.push(result); - src.skipWhitespace(); - } - return ans; - }; -} -function syntax(parsers, delegatesDocComments = false) { - return (src, ctx) => { - src.skipWhitespace(); - const ans = sequence(parsers, syntaxGap(delegatesDocComments))(src, ctx); - src.skipWhitespace(); - return ans; - }; -} -function syntaxRepeat(parser, delegatesDocComments = false) { - return repeat(parser, syntaxGap(delegatesDocComments)); -} -function literal6(literal9, options2) { - return (src, ctx) => { - const ans = { - type: "mcdoc:literal", - range: Range.create(src), - value: "", - colorTokenType: options2?.colorTokenType - }; - ans.value = src.readIf((c) => options2?.allowedChars?.has(c) ?? (options2?.specialChars?.has(c) || /[a-z]/i.test(c))); - ans.range.end = src.cursor; - if (Arrayable.toArray(literal9).every((l) => l !== ans.value)) { - ctx.err.report(localize("expected-got", arrayToMessage(literal9), localeQuote(ans.value)), ans); - } - return ans; - }; -} -function keyword(keyword2, options2 = { colorTokenType: "keyword" }) { - return (src, ctx) => { - const result = literal6(keyword2, options2)(src, ctx); - if (!Arrayable.toArray(keyword2).includes(result.value)) { - return Failure; - } - return result; - }; -} -function punctuation(punctuation2) { - return (src, ctx) => { - src.skipWhitespace(); - if (!src.trySkip(punctuation2)) { - ctx.err.report(localize("expected-got", localeQuote(punctuation2), localeQuote(src.peek())), src); - } - return void 0; - }; -} -function marker(punctuation2) { - return (src, _ctx) => { - src.skipWhitespace(); - if (!src.trySkip(punctuation2)) { - return Failure; - } - return void 0; - }; -} -function resLoc(options2) { - return validate(resourceLocation6(options2), (res) => res.namespace !== void 0, localize("mcdoc.parser.resource-location.colon-expected", localeQuote(ResourceLocation.NamespacePathSep))); -} -var UnicodeControlCharacters = Object.freeze([ - "\0", - "", - "", - "", - "", - "", - "", - "\x07", - "\b", - " ", - "\n", - "\v", - "\f", - "\r", - "", - "", - "\x7F" -]); -var string5 = stopBefore(string4({ - escapable: { characters: ["b", "f", "n", "r", "t", "\\", '"'], unicode: true }, - quotes: ['"'] -}), ...UnicodeControlCharacters); -var identifier2 = (src, ctx) => { - const IdentifierStart = /^[\p{L}\p{Nl}]$/u; - const IdentifierContinue = /^[\p{L}\p{Nl}\u200C\u200D\p{Mn}\p{Mc}\p{Nd}\p{Pc}]$/u; - const ReservedWords = /* @__PURE__ */ new Set([ - "any", - "boolean", - "byte", - "double", - "enum", - "false", - "float", - "int", - "long", - "short", - "string", - "struct", - "super", - "true" - ]); - const ans = { - type: "mcdoc:identifier", - range: Range.create(src), - options: { category: "mcdoc" }, - value: "" - }; - const start = src.innerCursor; - if (IdentifierStart.test(src.peek())) { - src.skip(); - while (IdentifierContinue.test(src.peek())) { - src.skip(); - } - } else { - ctx.err.report(localize("expected", localize("mcdoc.node.identifier")), src); - } - ans.value = src.string.slice(start, src.innerCursor); - ans.range.end = src.cursor; - if (ReservedWords.has(ans.value)) { - ctx.err.report(localize("mcdoc.parser.identifier.reserved-word", localeQuote(ans.value)), ans); - } - return ans; -}; -function indexBody(options2) { - const accessorKey = select([ - { prefix: "%", parser: literal6(["%key", "%parent"], { specialChars: /* @__PURE__ */ new Set(["%"]) }) }, - { prefix: '"', parser: string5 }, - { parser: identifier2 } - ]); - const dynamicIndex2 = setType("mcdoc:dynamic_index", syntax([ - punctuation("["), - accessorKey, - repeat(sequence([marker("."), accessorKey])), - punctuation("]") - ])); - const index4 = select([ - { - prefix: "%", - parser: literal6(StaticIndexKeywords.map((v) => `%${v}`), { specialChars: /* @__PURE__ */ new Set(["%"]) }) - }, - { prefix: '"', parser: string5 }, - { - prefix: "[", - parser: options2?.noDynamic ? validate(dynamicIndex2, () => false, localize("mcdoc.parser.index-body.dynamic-index-not-allowed")) : dynamicIndex2 - }, - { - parser: any3([ - resLoc({ category: "mcdoc/dispatcher", accessType: options2?.accessType }), - identifier2 - ]) - } - ]); - return setType("mcdoc:index_body", syntax([ - punctuation("["), - index4, - syntaxRepeat(syntax([marker(","), failOnEmpty(index4)])), - optional(marker(",")), - punctuation("]") - ])); -} -var pathSegment = select([{ - prefix: "super", - parser: literal6("super") -}, { parser: identifier2 }]); -var path = (src, ctx) => { - let isAbsolute; - if (src.trySkip("::")) { - isAbsolute = true; - } - return map(sequence([pathSegment, repeat(sequence([marker("::"), pathSegment]))]), (res) => { - const ans = { - type: "mcdoc:path", - children: res.children, - range: res.range, - isAbsolute - }; - return ans; - })(src, ctx); -}; -var attributeTreePosValues = setType("mcdoc:attribute/tree/pos", syntax([ - { get: () => attributeValue }, - syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(attributeValue) }], true), true) -], true)); -var attributeNamedValue = syntax([ - select([{ prefix: '"', parser: string5 }, { parser: identifier2 }]), - select([{ - prefix: "=", - parser: syntax([punctuation("="), { get: () => attributeValue }], true) - }, { parser: { get: () => attributeTree } }]) -], true); -var attributeTreeNamedValues = setType("mcdoc:attribute/tree/named", syntax([ - attributeNamedValue, - syntaxRepeat(syntax([marker(","), failOnEmpty(attributeNamedValue)], true), true) -], true)); -var treeBody = any3([ - syntax([attributeTreeNamedValues, optional(marker(","))]), - syntax([ - attributeTreePosValues, - punctuation(","), - attributeTreeNamedValues, - optional(marker(",")) - ]), - syntax([attributeTreePosValues, optional(marker(","))]) -]); -var AttributeTreeClosure = Object.freeze({ "(": ")", "[": "]", "{": "}" }); -var attributeTree = (src, ctx) => { - const delim = src.trySkip("(") ? "(" : src.trySkip("[") ? "[" : src.trySkip("{") ? "{" : void 0; - if (!delim) { - return Failure; - } - const res = treeBody(src, ctx); - const ans = { - type: "mcdoc:attribute/tree", - range: res.range, - children: res.children, - delim - }; - src.trySkip(AttributeTreeClosure[delim]); - return ans; -}; -var attributeValue = select([{ - predicate: (src) => ["(", "[", "{"].includes(src.peek()), - parser: attributeTree -}, { parser: { get: () => type } }]); -var attribute = setType("mcdoc:attribute", syntax([ - marker("#["), - identifier2, - select([{ - prefix: "=", - parser: syntax([punctuation("="), attributeValue, punctuation("]")], true) - }, { - predicate: (src) => ["(", "[", "{"].includes(src.peek()), - parser: syntax([attributeTree, punctuation("]")], true) - }, { parser: punctuation("]") }]) -], true)); -var attributes = repeat(attribute); -var typeParam = setType("mcdoc:type_param", syntax([ - identifier2 - // optional(syntax([failOnError(literal('extends')), { get: () => type }])), -])); -var typeParamBlock = setType("mcdoc:type_param_block", syntax([ - punctuation("<"), - select([{ prefix: ">", parser: punctuation(">") }, { - parser: syntax([ - typeParam, - syntaxRepeat(syntax([marker(","), failOnEmpty(typeParam)])), - optional(marker(",")), - punctuation(">") - ]) - }]) -])); -var noop5 = () => void 0; -var docComment = comment3({ - singleLinePrefixes: /* @__PURE__ */ new Set(["///"]), - includesEol: true -}); -var docComments = setType("mcdoc:doc_comments", repeat(docComment, (src) => { - src.skipWhitespace(); - return []; -})); -var prelim = syntax([ - optional(failOnEmpty(docComments)), - attributes -]); -var optionalTypeParamBlock = select([{ - prefix: "<", - parser: typeParamBlock -}, { parser: noop5 }]); -var dispatchStatement = setType("mcdoc:dispatch_statement", syntax([ - prelim, - keyword("dispatch"), - resLoc({ - category: "mcdoc/dispatcher", - accessType: 1 - /* SymbolAccessType.Write */ - }), - indexBody({ noDynamic: true }), - optionalTypeParamBlock, - literal6("to"), - { get: () => type } -], true)); -var enumType = literal6([ - "byte", - "short", - "int", - "long", - "string", - "float", - "double" -], { colorTokenType: "type" }); -var float3 = float2({ - pattern: /^[-+]?(?:[0-9]+(?:[eE][-+]?[0-9]+)?|[0-9]*\.[0-9]+(?:[eE][-+]?[0-9]+)?)$/ -}); -var integer3 = integer2({ - pattern: /^(?:0|[-+]?[1-9][0-9]*)$/ -}); -var long3 = long2({ - pattern: /^(?:0|[-+]?[1-9][0-9]*)$/ -}); -var LiteralIntSuffixes = Object.freeze(["b", "s", "l"]); -var LiteralIntCaseInsensitiveSuffixes = Object.freeze([...LiteralIntSuffixes, "B", "S", "L"]); -var LiteralFloatSuffixes = Object.freeze(["f", "d"]); -var LiteralFloatCaseInsensitiveSuffixes = Object.freeze([...LiteralFloatSuffixes, "F", "D"]); -var LiteralNumberSuffixes = Object.freeze([...LiteralIntSuffixes, ...LiteralFloatSuffixes]); -var LiteralNumberCaseInsensitiveSuffixes = Object.freeze([ - ...LiteralNumberSuffixes, - ...LiteralIntCaseInsensitiveSuffixes, - ...LiteralFloatCaseInsensitiveSuffixes -]); -var typedNumber = setType("mcdoc:typed_number", select([{ - regex: /^(?:\+|-)?\d+L/i, - parser: sequence([ - long3, - optional(failOnEmpty(literal6(LiteralIntCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) - ]) -}, { - regex: /^(?:\+|-)?\d+(?!\d|[.dfe])/i, - parser: sequence([ - integer3, - optional(failOnEmpty(literal6(LiteralIntCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) - ]) -}, { - parser: sequence([ - float3, - optional(failOnEmpty(literal6(LiteralFloatCaseInsensitiveSuffixes, { colorTokenType: "keyword" }))) - ]) -}])); -var failableTypedNumber = (src, ctx) => { - const { updateSrcAndCtx, result, errorAmount } = attempt3(typedNumber, src, ctx); - if (errorAmount > 0) { - if (result.children.length !== 2) { - return Failure; - } - const { errorAmount: numberErrors } = attempt3(float3, src, ctx); - if (numberErrors > 0) { - return Failure; - } - } - updateSrcAndCtx(); - return result; -}; -var enumValue = select([{ prefix: '"', parser: string5 }, { - parser: typedNumber -}]); -var enumField = setType("mcdoc:enum/field", syntax([prelim, identifier2, punctuation("="), enumValue], true)); -var enumBlock = setType("mcdoc:enum/block", syntax([ - punctuation("{"), - select([{ prefix: "}", parser: punctuation("}") }, { - parser: syntax([ - enumField, - syntaxRepeat(syntax([marker(","), failOnEmpty(enumField)], true), true), - optional(marker(",")), - punctuation("}") - ], true) - }]) -], true)); -var enum_ = setType("mcdoc:enum", syntax([ - prelim, - keyword("enum"), - punctuation("("), - enumType, - punctuation(")"), - optional(failOnError(identifier2)), - enumBlock -], true)); -var structMapKey = setType("mcdoc:struct/map_key", syntax([punctuation("["), { get: () => type }, punctuation("]")], true)); -var structKey = select([{ prefix: '"', parser: string5 }, { - prefix: "[", - parser: structMapKey -}, { parser: identifier2 }]); -var structPairField = (src, ctx) => { - let isOptional; - const result0 = syntax([prelim, structKey], true)(src, ctx); - if (src.trySkip("?")) { - isOptional = true; - } - const result1 = syntax([punctuation(":"), { get: () => type }], true)(src, ctx); - const ans = { - type: "mcdoc:struct/field/pair", - children: [...result0.children, ...result1.children], - range: Range.span(result0, result1), - isOptional - }; - return ans; -}; -var structSpreadField = setType("mcdoc:struct/field/spread", syntax([attributes, marker("..."), { get: () => type }], true)); -var structField = any3([ - structSpreadField, - structPairField -]); -var structBlock = setType("mcdoc:struct/block", syntax([ - punctuation("{"), - select([{ prefix: "}", parser: punctuation("}") }, { - parser: syntax([ - structField, - syntaxRepeat(syntax([marker(","), failOnEmpty(structField)], true), true), - optional(marker(",")), - punctuation("}") - ], true) - }]) -], true)); -var struct = setType("mcdoc:struct", syntax([prelim, keyword("struct"), optional(failOnEmpty(identifier2)), structBlock], true)); -var enumInjection = setType("mcdoc:injection/enum", syntax([literal6("enum"), punctuation("("), enumType, punctuation(")"), path, enumBlock])); -var structInjection = setType("mcdoc:injection/struct", syntax([literal6("struct"), path, structBlock])); -var injection = setType("mcdoc:injection", syntax([ - keyword("inject"), - select([{ prefix: "enum", parser: enumInjection }, { parser: structInjection }]) -])); -var typeAliasStatement = setType("mcdoc:type_alias", syntax([prelim, keyword("type"), identifier2, optionalTypeParamBlock, punctuation("="), { - get: () => type -}], true)); -var useStatement = setType("mcdoc:use_statement", syntax([ - keyword("use"), - path, - select([{ prefix: "as", parser: syntax([literal6("as"), identifier2]) }, { parser: noop5 }]) -], true)); -var topLevel = any3([ - comment4, - dispatchStatement, - enum_, - injection, - struct, - typeAliasStatement, - useStatement -]); -var module_2 = setType("mcdoc:module", syntaxRepeat(topLevel, true)); -var typeArgBlock = setType("mcdoc:type_arg_block", syntax([ - marker("<"), - select([{ prefix: ">", parser: punctuation(">") }, { - parser: syntax([ - { get: () => type }, - syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(type) }], true), true), - optional(marker(",")), - punctuation(">") - ], true) - }]) -])); -function typeBase(type2, parser) { - return setType(type2, syntax([ - attributes, - parser, - syntaxRepeat(select([{ prefix: "<", parser: typeArgBlock }, { parser: failOnError(indexBody()) }]), true) - ], true)); -} -var anyType = typeBase("mcdoc:type/any", keyword("any", { colorTokenType: "type" })); -var booleanType = typeBase("mcdoc:type/boolean", keyword("boolean", { colorTokenType: "type" })); -function range(type2, number5) { - const delimiterPredicate = (src) => src.tryPeek("..") || src.tryPeek(`${RangeExclusiveChar}..`); - const delimiterParser = literal6([ - "..", - `..${RangeExclusiveChar}`, - `${RangeExclusiveChar}..`, - `${RangeExclusiveChar}..${RangeExclusiveChar}` - ], { allowedChars: /* @__PURE__ */ new Set([".", RangeExclusiveChar]) }); - return setType(type2, select([{ predicate: delimiterPredicate, parser: sequence([delimiterParser, number5]) }, { - parser: sequence([ - stopBefore(number5, ".."), - select([{ - predicate: delimiterPredicate, - parser: sequence([delimiterParser, optional(failOnEmpty(number5))]) - }, { parser: noop5 }]) - ]) - }])); -} -function atRange(parser) { - return optional((src, ctx) => { - if (!src.trySkip("@")) { - return Failure; - } - src.skipWhitespace(); - return parser(src, ctx); - }); -} -var intRange = range("mcdoc:int_range", integer3); -var longRange = range("mcdoc:long_range", long3); -var floatRange = range("mcdoc:float_range", float3); -var atIntRange = atRange(intRange); -var atLongRange = atRange(longRange); -var atFloatRange = atRange(floatRange); -var stringType = typeBase("mcdoc:type/string", syntax([ - keyword("string", { colorTokenType: "type" }), - atIntRange -], true)); -var literalType = typeBase("mcdoc:type/literal", select([ - { - predicate: (src) => src.tryPeek("false") || src.tryPeek("true"), - parser: keyword(["false", "true"], { colorTokenType: "type" }) - }, - { prefix: '"', parser: failOnEmpty(string5) }, - { parser: failableTypedNumber } -])); -var numericType = typeBase("mcdoc:type/numeric_type", select([{ - predicate: (src) => NumericTypeFloatKinds.some((k) => src.tryPeek(k)), - parser: syntax([keyword(NumericTypeFloatKinds, { colorTokenType: "type" }), atFloatRange], true) -}, { - predicate: (src) => src.tryPeek("long"), - parser: syntax([keyword("long", { colorTokenType: "type" }), atLongRange], true) -}, { - parser: syntax([keyword(NumericTypeIntKinds, { colorTokenType: "type" }), atIntRange], true) -}])); -var primitiveArrayType = typeBase("mcdoc:type/primitive_array", syntax([ - select([{ - predicate: (src) => src.tryPeek("long"), - parser: syntax([literal6("long"), atLongRange], true) - }, { - parser: syntax([literal6(PrimitiveArrayValueKinds), atIntRange], true) - }]), - keyword("[]", { allowedChars: /* @__PURE__ */ new Set(["[", "]"]), colorTokenType: "type" }), - atIntRange -])); -var listType = typeBase("mcdoc:type/list", syntax([marker("["), { get: () => type }, punctuation("]"), atIntRange], true)); -var tupleType = typeBase("mcdoc:type/tuple", syntax([ - marker("["), - { get: () => type }, - marker(","), - select([{ prefix: "]", parser: punctuation("]") }, { - parser: syntax([ - { get: () => type }, - syntaxRepeat(syntax([marker(","), { get: () => failOnEmpty(type) }], true), true), - optional(marker(",")), - punctuation("]") - ], true) - }]) -], true)); -var dispatcherType = typeBase("mcdoc:type/dispatcher", syntax([failOnError(resLoc({ category: "mcdoc/dispatcher" })), indexBody()])); -var unionType = typeBase("mcdoc:type/union", syntax([ - marker("("), - select([{ prefix: ")", parser: punctuation(")") }, { - parser: syntax([ - { get: () => type }, - syntaxRepeat(syntax([marker("|"), { get: () => failOnEmpty(type) }], true), true), - optional(marker("|")), - punctuation(")") - ], true) - }]) -])); -var referenceType = typeBase("mcdoc:type/reference", syntax([path])); -var type = any3([ - anyType, - booleanType, - dispatcherType, - enum_, - listType, - literalType, - numericType, - primitiveArrayType, - stringType, - struct, - tupleType, - unionType, - referenceType -]); - -// node_modules/@spyglassmc/mcdoc/lib/formatter/index.js -var nodeTypesAllowingComments = /* @__PURE__ */ new Set([ - "mcdoc:module", - "mcdoc:struct/block", - "mcdoc:enum/block", - "mcdoc:doc_comments", - "mcdoc:type/tuple", - "mcdoc:type/union" -]); -var nodeTypesAllowingTrailingComments = /* @__PURE__ */ new Set([ - "mcdoc:module", - "mcdoc:struct/block", - "mcdoc:enum/block", - "mcdoc:doc_comments" -]); -var prelimNodeTypes = /* @__PURE__ */ new Set([ - "mcdoc:attribute", - "mcdoc:doc_comments" -]); -function formatChildren(node, ctx, childFormatInfo, excludeLastChildSuffix = false, onlyFormatPrelimType) { - const allowsComments = nodeTypesAllowingComments.has(node.type); - const allowsTrailingComments = nodeTypesAllowingTrailingComments.has(node.type); - const children = allowsComments ? liftChildComments(node.children) : node.children; - const lastNonComment = children.findLastIndex((child) => child.type !== "comment"); - const lastFormattedChild = onlyFormatPrelimType !== void 0 ? children.findLastIndex((child) => child.type === onlyFormatPrelimType) : children.findLastIndex((child) => child.type !== "comment"); - const content = children.map((child, i) => { - if (onlyFormatPrelimType !== void 0 && child.type !== onlyFormatPrelimType) { - return ""; - } - if (onlyFormatPrelimType === void 0 && prelimNodeTypes.has(child.type)) { - return ""; - } - if (child.type === "comment" && !allowsComments) { - return ""; - } - if (i > lastNonComment && !allowsTrailingComments) { - return ""; - } - const info = childFormatInfo[child.type]; - const value = ctx.meta.getFormatter(child.type)(child, info?.indentSelf ? indentFormatter(ctx) : ctx); - const prefix = info?.prefix ?? ""; - const hasSuffix = info?.suffix !== void 0 && (!excludeLastChildSuffix || lastFormattedChild !== i); - const suffix = hasSuffix ? info.suffix : ""; - const formatted = `${prefix}${value}${suffix}`; - return formatted; - }).join(""); - return content; -} -var formatterIgnoreAttributeName = "formatter_ignore"; -function shouldFormatterIgnore(node) { - return node.children?.some((child) => { - if (child.type !== "mcdoc:attribute") { - return false; - } - return child.children.some((attributeChild) => { - return attributeChild.type === "mcdoc:identifier" && attributeChild.value === formatterIgnoreAttributeName; - }); - }) ?? false; -} -function getUnformatted(node, ctx) { - return ctx.doc.getText({ - start: ctx.doc.positionAt(node.range.start), - end: ctx.doc.positionAt(node.range.end) - }); -} -function hasMultilineChild(node, isRecursiveCall = false, alwaysIncludeComments = false) { - if (!node.children) { - return false; - } - for (let i = 0; i < node.children.length; i++) { - const child = node.children[i]; - if (child.type === "comment") { - if (alwaysIncludeComments) { - return true; - } - if (nodeTypesAllowingComments.has(node.type)) { - if (nodeTypesAllowingTrailingComments.has(node.type)) { - return true; - } - if (i < node.children.length - 1 && node.children[i + 1].type !== "comment") { - return true; - } - } - } - if (child.type === "mcdoc:struct") { - return true; - } - if (child.type === "mcdoc:enum") { - return true; - } - if (isRecursiveCall && child.type === "mcdoc:attribute") { - return true; - } - if (hasMultilineChild(child, true, alwaysIncludeComments || i < node.children.length - 1)) { - return true; - } - } - return false; -} -var maxDynamicInlineLength = 80; -function formatDynamicMultiline(node, formatter) { - if (hasMultilineChild(node)) { - return formatter(true); - } - const inlineFormat = formatter(false); - if (inlineFormat.length > maxDynamicInlineLength) { - return formatter(true); - } - return inlineFormat; -} -function formatWithPrelim(node, ctx, putAttributesOnSeparateLine, putDocOnSeparateLine, contentFormatter) { - if (shouldFormatterIgnore(node)) { - return getUnformatted(node, ctx); - } - function attributeFormatter(doMultiline, attributeCtx) { - const childFormatInfo = { - "mcdoc:attribute": { - suffix: doMultiline ? ` -${attributeCtx.indent()}` : " " - } - }; - return formatChildren( - node, - attributeCtx, - childFormatInfo, - // Last suffix is excluded, because it is specified separately through `putAttributesOnSeparateLine`. - // This makes it possible to put all attributes on one line but still add a newline at the end. - true, - "mcdoc:attribute" - ); - } - const shouldIndentPrelim = !putDocOnSeparateLine && node.children.some((child) => child.type === "mcdoc:doc_comments"); - function processFormattedAttributes(formattedAttributes, areAttributesMultiline) { - const formattedDocComments = formatChildren(node, putDocOnSeparateLine ? ctx : indentFormatter(ctx), {}, false, "mcdoc:doc_comments"); - const hasAdditionalIndent = shouldIndentPrelim || !putAttributesOnSeparateLine && areAttributesMultiline; - if (formattedAttributes !== "") { - if (hasAdditionalIndent) { - formattedAttributes += ` -${ctx.indent(1)}`; - } else if (putAttributesOnSeparateLine) { - formattedAttributes += ` -${ctx.indent()}`; - } else { - formattedAttributes += " "; - } - } - const prelim2 = (hasAdditionalIndent ? ` -${ctx.indent(1)}` : "") + formattedDocComments + formattedAttributes; - const content = contentFormatter(hasAdditionalIndent ? indentFormatter(ctx) : ctx); - return prelim2 + content; - } - const multilineChild = node.children?.some((child) => { - child.type === "mcdoc:attribute" && hasMultilineChild(child); - }); - if (multilineChild) { - return processFormattedAttributes(attributeFormatter(true, putAttributesOnSeparateLine ? ctx : indentFormatter(ctx)), true); - } - const inlineAttributes = attributeFormatter(false, ctx); - if (inlineAttributes.length > maxDynamicInlineLength) { - return processFormattedAttributes(attributeFormatter(true, putAttributesOnSeparateLine ? ctx : indentFormatter(ctx)), true); - } - return processFormattedAttributes((shouldIndentPrelim ? ctx.indent(1) : "") + inlineAttributes, false); -} -function liftChildComments(children) { - const mutableChildren = [...children]; - for (let i = 0; i < mutableChildren.length; i++) { - const child = mutableChildren[i]; - const { beforeNode, afterNode } = findComments(child); - mutableChildren.splice(i, 0, ...beforeNode); - i += beforeNode.length; - mutableChildren.splice(i + 1, 0, ...afterNode); - i += afterNode.length; - } - return mutableChildren; -} -function findComments(node) { - const result = { - beforeNode: [], - afterNode: [] - }; - if (!node.children) { - return result; - } - let currentCommentSequence = []; - node.children.forEach((child) => { - if (child.type === "comment") { - currentCommentSequence.push(child); - return; - } - result.beforeNode.push(...currentCommentSequence); - currentCommentSequence = []; - const childComments = findComments(child); - if (nodeTypesAllowingComments.has(child.type)) { - if (!nodeTypesAllowingTrailingComments.has(child.type)) { - currentCommentSequence = childComments.afterNode; - } - return; - } - result.beforeNode.push(...childComments.beforeNode); - currentCommentSequence = childComments.afterNode; - }); - result.afterNode.push(...currentCommentSequence); - return result; -} -function getTypeNodes(children) { - return children.filter((child) => child.type.startsWith("mcdoc:type/") || child.type === "mcdoc:enum" || child.type === "mcdoc:struct"); -} -var module2 = (node, ctx) => { - const children = liftChildComments(node.children); - return children.map((child, i) => { - function addNewlineSeparator(formatted2) { - if (i === children.length - 1) { - return formatted2; - } - return `${formatted2} -`; - } - const formatted = ctx.meta.getFormatter(child.type)(child, ctx); - if (shouldFormatterIgnore(child)) { - return formatted; - } - if (child.type === "comment") { - return `${formatted} -`; - } - if (child.type === "mcdoc:use_statement" && children[i + 1]?.type === "mcdoc:use_statement") { - return `${formatted} -`; - } - return addNewlineSeparator(`${formatted} -`); - }).join(""); -}; -var useStatement2 = (node, ctx) => { - const hasAlias = node.children.some((child) => child.type === "mcdoc:identifier"); - return formatChildren(node, ctx, { - "mcdoc:literal": { suffix: " " }, - "mcdoc:path": { suffix: hasAlias ? " " : "" } - }); -}; -var injection2 = (node, ctx) => { - return formatChildren(node, ctx, { - "mcdoc:literal": { suffix: " " } - }); -}; -var struct2 = (node, ctx) => { - const isTopLevel = node.parent?.type === "mcdoc:module"; - return formatWithPrelim(node, ctx, isTopLevel, isTopLevel, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:literal": { suffix: " " }, - "mcdoc:identifier": { suffix: " " } - }); - }); -}; -var structInjection2 = (node, ctx) => { - return formatChildren(node, ctx, { - "mcdoc:literal": { suffix: " " }, - "mcdoc:path": { suffix: " " } - }); -}; -var structBlock2 = (node, ctx) => { - if (node.children.length === 0) { - return "{}"; - } - const content = formatChildren(node, ctx, { - "comment": { prefix: ctx.indent(1), suffix: "\n", indentSelf: true }, - "mcdoc:struct/field/pair": { suffix: ",\n", indentSelf: true }, - "mcdoc:struct/field/spread": { suffix: ",\n", indentSelf: true } - }); - return `{ -${content}${ctx.indent()}}`; -}; -var structPairField2 = (node, ctx) => { - const keySuffix = `${node.isOptional ? "?" : ""}: `; - return ctx.indent() + formatWithPrelim(node, ctx, true, true, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:struct/map_key": { suffix: keySuffix }, - "mcdoc:identifier": { suffix: keySuffix }, - "string": { suffix: keySuffix } - }); - }); -}; -var structMapKey2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children)[0]; - return formatChildren(node, ctx, { - [typeNode.type]: { prefix: "[", suffix: "]" } - }); -}; -var structSpreadField2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children)[0]; - return ctx.indent() + formatWithPrelim(node, ctx, true, true, (contentCtx) => { - return formatChildren(node, contentCtx, { - [typeNode.type]: { prefix: "..." } - }); - }); -}; -var _enum = (node, ctx) => { - const isTopLevel = node.parent?.type === "mcdoc:module"; - return formatWithPrelim(node, ctx, isTopLevel, isTopLevel, (contentCtx) => { - return node.children.map((child) => { - if (child.type === "comment") { - return ""; - } - if (child.type === "mcdoc:attribute") { - return ""; - } - const formatted = contentCtx.meta.getFormatter(child.type)(child, contentCtx); - if (child.type === "mcdoc:identifier") { - return formatted + " "; - } - if (child.type !== "mcdoc:literal" || child.value === "enum") { - return formatted; - } - return `(${formatted}) `; - }).join(""); - }); -}; -var enumInjection2 = (node, ctx) => { - return node.children.map((child) => { - if (child.type === "comment") { - return ""; - } - const formatted = ctx.meta.getFormatter(child.type)(child, ctx); - if (child.type === "mcdoc:path") { - return formatted + " "; - } - if (child.type !== "mcdoc:literal" || child.value === "enum") { - return formatted; - } - return `(${formatted}) `; - }).join(""); -}; -var enumBlock2 = (node, ctx) => { - if (node.children.length === 0) { - return "{}"; - } - const content = formatChildren(node, ctx, { - "comment": { prefix: ctx.indent(1), suffix: "\n", indentSelf: true }, - "mcdoc:enum/field": { prefix: ctx.indent(1), suffix: ",\n", indentSelf: true } - }); - return `{ -${content}${ctx.indent()}}`; -}; -var enumField2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, true, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:identifier": { suffix: " = " } - }); - }); -}; -var tupleType2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children); - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatDynamicMultiline(node, (doMultiline) => { - const childFormatInfo = { - "comment": { - prefix: contentCtx.indent(1), - suffix: ` -` - } - }; - const typeFormatInfo = { - prefix: doMultiline ? contentCtx.indent(1) : "", - suffix: "," + (doMultiline ? ` -` : " "), - indentSelf: true - }; - for (const child of typeNode) { - childFormatInfo[child.type] = typeFormatInfo; - } - const content = formatChildren(node, contentCtx, childFormatInfo, !doMultiline); - return doMultiline ? `[ -${content}${contentCtx.indent()}]` : `[${content}]`; - }); - }); -}; -var unionType2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children); - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatDynamicMultiline(node, (doMultiline) => { - const childFormatInfo = { - "comment": { - prefix: contentCtx.indent(1), - suffix: ` -` - } - }; - const typeFormatInfo = { - prefix: doMultiline ? contentCtx.indent(1) : "", - suffix: " |" + (doMultiline ? ` -` : " "), - indentSelf: true - }; - for (const child of typeNode) { - childFormatInfo[child.type] = typeFormatInfo; - } - const content = formatChildren(node, contentCtx, childFormatInfo, !doMultiline); - return doMultiline ? `( -${content}${contentCtx.indent()})` : `(${content})`; - }); - }); -}; -var referenceType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, {}); - }); -}; -var path2 = (node, ctx) => { - const formatted = formatChildren(node, ctx, { - "mcdoc:literal": { prefix: "::" }, - "mcdoc:identifier": { prefix: "::" } - }); - if (!node.isAbsolute) { - return formatted.substring(2); - } - return formatted; -}; -var stringType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:int_range": { prefix: " @ " } - }); - }); -}; -var primitiveArrayType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:int_range": { prefix: " @ " } - }); - }); -}; -var listType2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children)[0]; - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, { - [typeNode.type]: { prefix: "[", suffix: "]" }, - "mcdoc:int_range": { prefix: " @ " } - }); - }); -}; -var typeAlias = (node, ctx) => { - const typeNode = getTypeNodes(node.children)[0]; - return formatWithPrelim(node, ctx, true, true, (contentCtx) => { - return formatChildren(node, contentCtx, { - [typeNode.type]: { prefix: " = " }, - "mcdoc:literal": { suffix: " " } - }); - }); -}; -var dispatcherType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, true, true, (contentCtx) => { - return formatChildren(node, contentCtx, {}); - }); -}; -var dispatchStatement2 = (node, ctx) => { - return formatWithPrelim(node, ctx, true, true, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:literal": { suffix: " " }, - "mcdoc:index_body": { suffix: " " } - }); - }); -}; -var indexBody2 = (node, ctx) => { - return formatDynamicMultiline(node, (doMultiline) => { - const indexFormatInfo = { - prefix: doMultiline ? ctx.indent(1) : "", - suffix: "," + (doMultiline ? ` -` : " "), - indentSelf: true - }; - const content = formatChildren(node, ctx, { - "mcdoc:dynamic_index": indexFormatInfo, - "mcdoc:identifier": indexFormatInfo, - "mcdoc:literal": indexFormatInfo, - "resource_location": indexFormatInfo, - "string": indexFormatInfo - }, !doMultiline); - return doMultiline ? `[ -${content}${ctx.indent()}]` : `[${content}]`; - }); -}; -var dynamicIndex = (node, ctx) => { - const path6 = node.children.map((child) => { - if (child.type === "comment") { - return ""; - } - return ctx.meta.getFormatter(child.type)(child, ctx); - }).join("."); - return `[${path6}]`; -}; -var attribute2 = (node, ctx) => { - const hasTypeValue = getTypeNodes(node.children).length !== 0; - return formatChildren(node, ctx, { - "mcdoc:identifier": { prefix: "#[", suffix: hasTypeValue ? "=" : "" } - }) + "]"; -}; -var attributeTree2 = (node, ctx) => { - const content = formatChildren(node, ctx, {}); - return `${node.delim}${content}${AttributeTreeClosure[node.delim]}`; -}; -var attributeTreePosValues2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children); - return formatDynamicMultiline(node, (doMultiline) => { - const childFormatInfo = { - prefix: doMultiline ? ctx.indent(1) : "", - suffix: "," + (doMultiline ? ` -` : " "), - indentSelf: true - }; - const childFormatInfoMap = { - "mcdoc:attribute/tree": childFormatInfo - }; - for (const child of typeNode) { - childFormatInfoMap[child.type] = childFormatInfo; - } - const content = formatChildren(node, ctx, childFormatInfoMap, !doMultiline); - return doMultiline ? ` -${content}${ctx.indent()}` : content; - }); -}; -var attributeTreeNamedValues2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children); - return formatDynamicMultiline(node, (doMultiline) => { - const childFormatInfo = { - prefix: "=", - suffix: "," + (doMultiline ? ` -` : " "), - indentSelf: true - }; - const childFormatInfoMap = { - "mcdoc:attribute/tree": childFormatInfo, - "mcdoc:identifier": { prefix: doMultiline ? ctx.indent(1) : "" }, - "string": { prefix: doMultiline ? ctx.indent(1) : "" } - }; - for (const child of typeNode) { - childFormatInfoMap[child.type] = childFormatInfo; - } - const content = formatChildren(node, ctx, childFormatInfoMap, !doMultiline); - return doMultiline ? ` -${content}${ctx.indent()}` : content; - }); -}; -var typeArgBlock2 = (node, ctx) => { - const typeNode = getTypeNodes(node.children); - const childFormatInfo = {}; - for (const child of typeNode) { - childFormatInfo[child.type] = { suffix: ", " }; - } - const content = formatChildren(node, ctx, childFormatInfo, true); - return `<${content}>`; -}; -var typeParamBlock2 = (node, ctx) => { - const content = formatChildren(node, ctx, { - "mcdoc:type_param": { suffix: ", " } - }, true); - return `<${content}>`; -}; -var typeParam2 = (node, ctx) => { - return formatChildren(node, ctx, {}); -}; -var literalType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, {}); - }); -}; -var typedNumber2 = (node, ctx) => { - return formatChildren(node, ctx, {}); -}; -var numericType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, { - "mcdoc:int_range": { prefix: " @ " }, - "mcdoc:float_range": { prefix: " @ " } - }); - }); -}; -var intRange2 = (node, ctx) => { - return formatChildren(node, ctx, {}); -}; -var floatRange2 = (node, ctx) => { - return formatChildren(node, ctx, {}); -}; -var anyType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, {}); - }); -}; -var booleanType2 = (node, ctx) => { - return formatWithPrelim(node, ctx, false, false, (contentCtx) => { - return formatChildren(node, contentCtx, {}); - }); -}; -var literal7 = (node) => { - return node.value; -}; -var identifier3 = (node) => { - return node.value; -}; -var docComments2 = (node, ctx) => { - if (node.children.length === 0) { - return ""; - } - return formatChildren(node, ctx, { - comment: { suffix: ctx.indent() } - // No need to add new lines, because DocCommentNodes include them - }); -}; -function registerMcdocFormatter(meta) { - meta.registerFormatter("mcdoc:module", module2); - meta.registerFormatter("mcdoc:use_statement", useStatement2); - meta.registerFormatter("mcdoc:injection", injection2); - meta.registerFormatter("mcdoc:struct", struct2); - meta.registerFormatter("mcdoc:injection/struct", structInjection2); - meta.registerFormatter("mcdoc:struct/block", structBlock2); - meta.registerFormatter("mcdoc:struct/field/pair", structPairField2); - meta.registerFormatter("mcdoc:struct/map_key", structMapKey2); - meta.registerFormatter("mcdoc:struct/field/spread", structSpreadField2); - meta.registerFormatter("mcdoc:enum", _enum); - meta.registerFormatter("mcdoc:injection/enum", enumInjection2); - meta.registerFormatter("mcdoc:enum/block", enumBlock2); - meta.registerFormatter("mcdoc:enum/field", enumField2); - meta.registerFormatter("mcdoc:type/tuple", tupleType2); - meta.registerFormatter("mcdoc:type/union", unionType2); - meta.registerFormatter("mcdoc:type/reference", referenceType2); - meta.registerFormatter("mcdoc:path", path2); - meta.registerFormatter("mcdoc:type/string", stringType2); - meta.registerFormatter("mcdoc:type/primitive_array", primitiveArrayType2); - meta.registerFormatter("mcdoc:type/list", listType2); - meta.registerFormatter("mcdoc:type_alias", typeAlias); - meta.registerFormatter("mcdoc:type/dispatcher", dispatcherType2); - meta.registerFormatter("mcdoc:dispatch_statement", dispatchStatement2); - meta.registerFormatter("mcdoc:index_body", indexBody2); - meta.registerFormatter("mcdoc:dynamic_index", dynamicIndex); - meta.registerFormatter("mcdoc:attribute", attribute2); - meta.registerFormatter("mcdoc:attribute/tree", attributeTree2); - meta.registerFormatter("mcdoc:attribute/tree/pos", attributeTreePosValues2); - meta.registerFormatter("mcdoc:attribute/tree/named", attributeTreeNamedValues2); - meta.registerFormatter("mcdoc:type_arg_block", typeArgBlock2); - meta.registerFormatter("mcdoc:type_param_block", typeParamBlock2); - meta.registerFormatter("mcdoc:type_param", typeParam2); - meta.registerFormatter("mcdoc:type/literal", literalType2); - meta.registerFormatter("mcdoc:typed_number", typedNumber2); - meta.registerFormatter("mcdoc:type/numeric_type", numericType2); - meta.registerFormatter("mcdoc:int_range", intRange2); - meta.registerFormatter("mcdoc:float_range", floatRange2); - meta.registerFormatter("mcdoc:type/any", anyType2); - meta.registerFormatter("mcdoc:type/boolean", booleanType2); - meta.registerFormatter("mcdoc:literal", literal7); - meta.registerFormatter("mcdoc:identifier", identifier3); - meta.registerFormatter("mcdoc:doc_comments", docComments2); -} - -// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/index.js -var attribute_exports = {}; -__export(attribute_exports, { - getAttribute: () => getAttribute, - handleAttributes: () => handleAttributes, - registerAttribute: () => registerAttribute, - shouldKeepAccordingToAttributeFilters: () => shouldKeepAccordingToAttributeFilters, - validator: () => validator_exports -}); - -// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/validator.js -var validator_exports = {}; -__export(validator_exports, { - alternatives: () => alternatives, - boolean: () => boolean5, - list: () => list2, - map: () => map2, - number: () => number2, - optional: () => optional2, - options: () => options, - string: () => string6, - tree: () => tree -}); -var string6 = (value) => { - if (value === void 0) { - return Failure; - } - if (value.kind === "literal" && value.value.kind === "string") { - return value.value.value; - } - if (value.kind === "reference" && value.path) { - return value.path.replace(/.*::/, ""); - } - return Failure; -}; -var number2 = (value) => { - if (value === void 0) { - return Failure; - } - if (value.kind === "literal" && typeof value.value.value === "number") { - return value.value.value; - } - return Failure; -}; -var boolean5 = (value) => { - if (value === void 0) { - return Failure; - } - if (value.kind === "literal" && value.value.kind === "boolean") { - return value.value.value; - } - return Failure; -}; -function options(...options2) { - return (value, ctx) => { - const stringValue = string6(value, ctx); - if (stringValue === Failure) { - return Failure; - } - if (options2.includes(stringValue)) { - return stringValue; - } - return Failure; - }; -} -function tree(properties) { - return (value, ctx) => { - if (value?.kind !== "tree") { - return Failure; - } - const result = {}; - for (const key2 in properties) { - const validator4 = properties[key2]; - const propValue = value.values[key2]; - const property = validator4(propValue, ctx); - if (property === Failure) { - return Failure; - } - result[key2] = property; - } - return result; - }; -} -function list2(itemValidator) { - return (value, ctx) => { - if (value?.kind !== "tree") { - return Failure; - } - const result = []; - for (const element of Object.values(value.values)) { - const item = itemValidator(element, ctx); - if (item === Failure) { - return Failure; - } - result.push(item); - } - return result; - }; -} -function optional2(validator4) { - return (value, ctx) => { - const config = validator4(value, ctx); - return config === Failure ? void 0 : config; - }; -} -function map2(validator4, mapper) { - return (value, ctx) => { - const config = validator4(value, ctx); - return config === Failure ? Failure : mapper(config); - }; -} -function alternatives(...validators) { - return (value, ctx) => { - for (const validator4 of validators) { - const result = validator4(value, ctx); - if (result !== Failure) { - return result; - } - } - return Failure; - }; -} - -// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/index.js -function registerAttribute(meta, name, validator4, attribute3) { - meta.registerCustom("mcdoc:attribute", name, { validator: validator4, attribute: attribute3 }); -} -function getAttribute(meta, name) { - return meta.getCustom("mcdoc:attribute")?.get(name); -} -function handleAttributes(attributes2, ctx, fn) { - for (const { name, value } of attributes2 ?? []) { - const handler = getAttribute(ctx.meta, name); - if (!handler) { - continue; - } - const config = handler.validator(value, ctx); - if (config === Failure) { - continue; - } - fn(handler.attribute, config); - } -} -function shouldKeepAccordingToAttributeFilters(attributes2, ctx) { - let keep = true; - handleAttributes(attributes2, ctx, (handler, config) => { - if (!keep || !handler.filterElement) { - return; - } - if (!handler.filterElement(config, ctx)) { - keep = false; - } - }); - return keep; -} - -// node_modules/@spyglassmc/mcdoc/lib/runtime/attribute/builtin.js -var idValidator = validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => ({ registry: v })), validator_exports.tree({ - registry: validator_exports.string, - tags: validator_exports.optional(validator_exports.options("allowed", "implicit", "required")), - definition: validator_exports.optional(validator_exports.boolean), - prefix: validator_exports.optional(validator_exports.options("!")), - path: validator_exports.optional(validator_exports.string), - empty: validator_exports.optional(validator_exports.options("allowed")), - exclude: validator_exports.optional(validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => [v]), validator_exports.list(validator_exports.string))) -}), () => ({})); -var matchRegexValidator = validator_exports.alternatives(validator_exports.map(validator_exports.string, (v) => ({ pattern: v })), validator_exports.tree({ - pattern: validator_exports.string, - message: validator_exports.optional(validator_exports.string) -})); -function getResourceLocationOptions({ registry, tags, definition, path: path6 }, requireCanonical, ctx, typeDef) { - if (!registry) { - if (typeDef?.kind === "enum" && typeDef.enumKind === "string") { - return { - pool: typeDef.values.map((v) => ResourceLocation.lengthen(`${v.value}`)), - allowUnknown: true - // the mcdoc checker will already report errors for this - }; - } - if (typeDef?.kind === "literal" && typeDef.value.kind === "string") { - return { - pool: [ResourceLocation.lengthen(typeDef.value.value)], - allowUnknown: true - }; - } - return { pool: [], allowUnknown: true }; - } - if (tags === "implicit") { - registry = `tag/${registry}`; - } - if (tags === "allowed" || tags === "required") { - return { - category: registry, - requireCanonical, - allowTag: true, - requireTag: tags === "required", - implicitPath: path6 - }; - } - return { - category: registry, - requireCanonical, - usageType: definition ? "definition" : "reference", - implicitPath: path6 - }; -} -var integerValidator = validator_exports.alternatives(validator_exports.tree({ - min: validator_exports.optional(validator_exports.number), - max: validator_exports.optional(validator_exports.number) -}), () => ({})); -function registerBuiltinAttributes(meta) { - registerAttribute(meta, "canonical", () => void 0, { - // Has hardcoded behavior in the runtime checker - }); - registerAttribute(meta, "dispatcher_key", validator_exports.string, { - stringMocker: (config, _, ctx) => { - const symbol7 = ctx.symbols.query(ctx.doc, "mcdoc/dispatcher", config).symbol; - const keys = Object.entries(symbol7?.members ?? {}).filter(([k, v]) => { - if (k.startsWith("%")) { - return false; - } - if (!TypeDefSymbolData.is(v.data)) { - return false; - } - return shouldKeepAccordingToAttributeFilters(v.data.typeDef.attributes, ctx); - }).map(([k, _2]) => k); - return LiteralNode.mock(ctx.offset, { pool: keys }); - } - }); - registerAttribute(meta, "divisible_by", validator_exports.number, { - checker(config, typeDef) { - if (typeDef.kind !== "literal" || typeDef.value.kind === "string" || typeDef.value.kind === "boolean") { - return void 0; - } - const value = typeDef.value.value; - return (node, ctx) => { - const moduloResult = typeof value === "number" ? value % config : value % BigInt(config); - if (moduloResult !== 0 && moduloResult !== 0n) { - ctx.err.report(localize("not-divisible-by", value, config), node, ErrorSeverity.Warning); - } - }; - } - }); - registerAttribute(meta, "id", idValidator, { - checkInferred: (config, inferred, ctx) => { - if (inferred.kind === "string") { - const idAttr = inferred.attributes?.find((a) => a.name === "id"); - if (idAttr) { - const inferredConfig = idValidator(idAttr.value, ctx); - return inferredConfig === Failure || inferredConfig.prefix === config.prefix; - } - } - if (inferred.kind !== "literal" || inferred.value.kind !== "string") { - return true; - } - if (config.prefix && !inferred.value.value.startsWith(config.prefix)) { - return false; - } - if (!config.prefix && inferred.value.value.startsWith("!")) { - return false; - } - if (!inferred.value.value.includes(":")) { - if (config.prefix) { - inferred.value.value = config.prefix + "minecraft:" + inferred.value.value.slice(config.prefix.length); - } else { - inferred.value.value = "minecraft:" + inferred.value.value; - } - } - return true; - }, - mapType: (config, typeDef, ctx) => { - if (typeDef.kind === "literal" && typeDef.value.kind === "string") { - const value = ResourceLocation.lengthen(typeDef.value.value); - return { ...typeDef, value: { kind: "string", value } }; - } - if (typeDef.kind === "enum" && typeDef.enumKind === "string") { - const values = typeDef.values.map((v) => ({ - ...v, - value: ResourceLocation.lengthen(`${v.value}`) - })); - return { ...typeDef, values }; - } - return typeDef; - }, - stringParser: (config, typeDef, ctx) => { - const options2 = getResourceLocationOptions(config, ctx.requireCanonical, ctx, typeDef); - if (!options2) { - return; - } - const resourceLocation7 = resourceLocation6(options2); - return (src, ctx2) => { - if (config.empty && !src.canRead()) { - return string4({ - unquotable: { blockList: /* @__PURE__ */ new Set(), allowEmpty: true } - })(src, ctx2); - } - if (config.prefix) { - return prefixed2({ prefix: config.prefix, child: resourceLocation7 })(src, ctx2); - } - const node = resourceLocation7(src, ctx2); - if (config.exclude) { - const resourceLocation8 = ResourceLocationNode.toString(node, "full"); - for (const e of config.exclude ?? []) { - const excluded = ResourceLocation.lengthen(e); - if (resourceLocation8 === excluded) { - ctx2.err.report(localize("not-allowed-here", localeQuote(excluded)), node, ErrorSeverity.Warning); - } - } - } - return node; - }; - }, - stringMocker: (config, typeDef, ctx) => { - const options2 = getResourceLocationOptions(config, ctx.requireCanonical ?? false, ctx, typeDef); - if (!options2) { - return void 0; - } - const resourceLocation7 = ResourceLocationNode.mock(ctx.offset, options2); - if (config.prefix) { - return PrefixedNode.mock(ctx.offset, config.prefix, resourceLocation7); - } - return resourceLocation7; - } - }); - registerAttribute(meta, "integer", integerValidator, { - stringParser: (config) => { - return integer2({ pattern: /^-?\d+$/, min: config.min, max: config.max }); - } - }); - registerAttribute(meta, "color", validator_exports.string, { - checkInferred: (config, inferred, ctx) => { - if (config === "hex_rgb" && inferred.kind === "literal" && inferred.value.kind === "string") { - return inferred.value.value.startsWith("#"); - } - return true; - }, - checker: (config, inferred) => { - return (node, ctx) => { - switch (config) { - case "named": - if (inferred.kind !== "literal" || inferred.value.kind !== "string") { - return; - } - node.color = Color.fromNamed(inferred.value.value); - return; - case "hex_rgb": - if (inferred.kind !== "literal" || inferred.value.kind !== "string") { - return; - } - let range3 = node.range; - if (StringBaseNode.is(node) && node.quote) { - range3 = Range.translate(range3, 1, -1); - } - if (!inferred.value.value.startsWith("#")) { - ctx.err.report(localize("expected", localeQuote("#")), range3, ErrorSeverity.Warning); - return; - } - node.color = { - value: Color.fromHexRGB(inferred.value.value), - format: [ColorFormat.HexRGB], - range: range3 - }; - return; - case "composite_rgb": - if (inferred.kind !== "literal" || typeof inferred.value.value !== "number") { - return; - } - node.color = { - value: Color.fromCompositeRGB(inferred.value.value), - format: [ColorFormat.CompositeRGB], - range: node.range - }; - return; - case "composite_argb": - if (inferred.kind !== "literal" || typeof inferred.value.value !== "number") { - return; - } - node.color = { - value: Color.fromCompositeARGB(inferred.value.value), - format: [ColorFormat.CompositeARGB], - range: node.range - }; - return; - default: - return; - } - }; - } - }); - registerAttribute(meta, "regex_pattern", () => void 0, { - checker: (_, typeDef) => { - if (typeDef.kind !== "literal" || typeDef.value.kind !== "string") { - return void 0; - } - const pattern = typeDef.value.value; - return (node, ctx) => { - try { - RegExp(pattern); - } catch (e) { - const message2 = e instanceof Error ? e.message : `${e}`; - const error4 = message2.replace(/^Invalid regular expression: /, "").replace(/^\/.+\/: /, ""); - ctx.err.report(localize("invalid-regex-pattern", error4), node, ErrorSeverity.Warning); - } - }; - } - }); - registerAttribute(meta, "match_regex", matchRegexValidator, { - checker: (config, typeDef, _) => { - if (typeDef.kind !== "literal" || typeDef.value.kind !== "string") { - return void 0; - } - const pattern = config.pattern; - const value = typeDef.value.value; - return (node, ctx) => { - try { - const regex = RegExp(pattern); - if (!regex.test(value)) { - const message2 = config.message ?? localize("mismatching-regex-pattern", pattern); - ctx.err.report(message2, node, ErrorSeverity.Warning); - } - } catch (e) { - ctx.logger.warn(`Invalid regular expression in "match_regex" mcdoc attribute: ${pattern}`); - } - }; - } - }); -} - -// node_modules/@spyglassmc/mcdoc/lib/common.js -function segToIdentifier(seg) { - return `::${seg.join("::")}`; -} - -// node_modules/@spyglassmc/mcdoc/lib/uri_processors.js -var Extension = ".mcdoc"; -var McdocRootPrefix = "mcdoc/"; -var uriBinder = (uris, ctx) => { - let urisAndRels = []; - for (const uri of uris) { - if (!uri.endsWith(Extension)) { - continue; - } - let rel = fileUtil.getRel(uri, ctx.roots); - if (!rel) { - continue; - } - rel = rel.slice(0, -Extension.length).replace(/(^|\/)mod$/, ""); - urisAndRels.push([uri, rel]); - } - if (urisAndRels.every(([_, rel]) => rel.startsWith(McdocRootPrefix))) { - urisAndRels = urisAndRels.map(([uri, rel]) => [uri, rel.slice(McdocRootPrefix.length)]); - } - for (const [uri, rel] of urisAndRels) { - ctx.symbols.query(uri, "mcdoc", segToIdentifier(rel.split("/"))).ifDefined(() => { - }).elseEnter({ - data: { subcategory: "module" }, - usage: { type: "definition" } - }); - } -}; -var uriSorter = (a, b, next) => { - if (a.endsWith(Extension) && !b.endsWith(Extension)) { - return -1; - } else if (!a.endsWith(Extension) && b.endsWith(Extension)) { - return 1; - } else { - return next(a, b); - } -}; - -// node_modules/@spyglassmc/mcdoc/lib/runtime/index.js -var runtime_exports = {}; -__export(runtime_exports, { - attribute: () => attribute_exports, - checker: () => checker_exports, - completer: () => completer_exports, - registerAttribute: () => registerAttribute -}); - -// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/index.js -var checker_exports = {}; -__export(checker_exports, { - McdocCheckerContext: () => McdocCheckerContext, - MissingKeyError: () => MissingKeyError, - RangeError: () => RangeError2, - SimpleError: () => SimpleError, - TypeMismatchError: () => TypeMismatchError, - UnknownKeyError: () => UnknownKeyError, - condenseAndPropagate: () => condenseAndPropagate, - dispatcher: () => dispatcher, - getDefaultErrorRange: () => getDefaultErrorRange, - getDefaultErrorReporter: () => getDefaultErrorReporter, - getPossibleTypes: () => getPossibleTypes, - isAssignable: () => isAssignable, - reference: () => reference2, - simplify: () => simplify, - typeDefinition: () => typeDefinition -}); - -// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/context.js -var McdocCheckerContext; -(function(McdocCheckerContext2) { - function create(ctx, options2) { - return { - ...ctx, - allowMissingKeys: options2.allowMissingKeys ?? false, - requireCanonical: options2.requireCanonical ?? false, - tryConvertTo: options2.tryConvertTo ?? (() => void 0), - getChildren: options2.getChildren ?? (() => []), - reportError: options2.reportError ?? (() => { - }), - attachTypeInfo: options2.attachTypeInfo, - nodeAttacher: options2.nodeAttacher, - stringAttacher: options2.stringAttacher - }; - } - McdocCheckerContext2.create = create; -})(McdocCheckerContext || (McdocCheckerContext = {})); - -// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/error.js -var SimpleError; -(function(SimpleError2) { - function is(error4) { - return error4?.kind === "duplicate_key" || error4?.kind === "unknown_key" || error4?.kind === "expected_key_value_pair" || error4?.kind === "unknown_tuple_element" || error4?.kind === "internal"; - } - SimpleError2.is = is; -})(SimpleError || (SimpleError = {})); -var UnknownKeyError; -(function(UnknownKeyError2) { - function is(error4) { - return error4?.kind === "unknown_key"; - } - UnknownKeyError2.is = is; -})(UnknownKeyError || (UnknownKeyError = {})); -var RangeError2; -(function(RangeError3) { - function is(error4) { - return error4?.kind === "invalid_collection_length" || error4?.kind === "invalid_string_length" || error4?.kind === "number_out_of_range"; - } - RangeError3.is = is; -})(RangeError2 || (RangeError2 = {})); -var MissingKeyError; -(function(MissingKeyError2) { - function is(error4) { - return error4?.kind === "missing_key"; - } - MissingKeyError2.is = is; -})(MissingKeyError || (MissingKeyError = {})); -var TypeMismatchError; -(function(TypeMismatchError2) { - function is(error4) { - return error4?.kind === "type_mismatch"; - } - TypeMismatchError2.is = is; -})(TypeMismatchError || (TypeMismatchError = {})); -function condenseAndPropagate(definitionGroup, definitionErrors) { - const queue = [{ node: definitionGroup, errorsOnLayer: definitionErrors, depth: 0 }]; - while (queue.length) { - const { node, errorsOnLayer, depth } = queue.shift(); - const stillValidDefinitions = []; - const { definitions, condensedErrors } = condenseErrorsAndFilterSiblings(errorsOnLayer); - stillValidDefinitions.push(...definitions); - node.condensedErrors.push(condensedErrors); - if (node.validDefinitions.length !== stillValidDefinitions.length) { - filterChildDefinitions(node.validDefinitions.filter((d) => !stillValidDefinitions.includes(d)), node.runtimeNode.children); - node.validDefinitions = stillValidDefinitions; - } - const parents = node.parents.filter((parent) => { - const lastDefWithNode = parent.groupNode.validDefinitions.findLast((d) => d.children.includes(node)); - if (lastDefWithNode !== parent) { - return false; - } - const lastChild = parent.groupNode.validDefinitions.flatMap((d) => d.children).findLast((v) => { - if (v.condensedErrors.length > depth) { - return true; - } - let children = [v]; - for (let i = 0; i < depth; i++) { - children = children.flatMap((v2) => v2.validDefinitions).flatMap((v2) => v2.children); - } - return children.length > 0; - }); - if (lastChild !== node) { - return false; - } - return true; - }).map((parent) => ({ - node: parent.groupNode, - depth: depth + 1, - errorsOnLayer: parent.groupNode.validDefinitions.flatMap((d) => ({ - definition: d, - errors: d.children.flatMap((c) => c.condensedErrors.length > depth ? c.condensedErrors[depth] : []) - })) - })); - queue.push(...parents); - } -} -function filterChildDefinitions(removedDefs, children) { - for (const child of children) { - for (const childValue of child.possibleValues) { - const removedChildDefs = []; - for (let i = 0; i < childValue.definitionsByParent.length; i++) { - const definitionGroup = childValue.definitionsByParent[i]; - definitionGroup.parents = definitionGroup.parents.filter((p) => !removedDefs.includes(p)); - if (definitionGroup.parents.length === 0) { - removedChildDefs.push(...definitionGroup.validDefinitions); - childValue.definitionsByParent.splice(i, 1); - i--; - } - } - if (removedChildDefs.length > 0) { - filterChildDefinitions(removedChildDefs, childValue.children); - } - } - } -} -function condenseErrorsAndFilterSiblings(definitions) { - if (definitions.length === 0) { - return { definitions: [], condensedErrors: [] }; - } - let validDefinitions = definitions; - const errors = []; - const typeMismatchResult = condense(validDefinitions, TypeMismatchError.is, (a, b) => a.expected.length === b.expected.length && !a.expected.some((d) => !b.expected.some((od) => McdocType.equals(d, od))), (errors2) => ({ - kind: "type_mismatch", - node: errors2[0].node, - expected: deduplicateGroups(errors2.map((e) => e.expected), McdocType.equals) - })); - validDefinitions = typeMismatchResult.filteredDefinitions; - errors.push(...typeMismatchResult.condensedErrors); - for (const kind of [ - "unknown_key", - "expected_key_value_pair", - "unknown_tuple_element" - ]) { - const simpleErrorResult = condense(validDefinitions, (e) => e.kind === kind, (_) => true); - validDefinitions = simpleErrorResult.filteredDefinitions; - errors.push(...simpleErrorResult.condensedErrors); - } - const missingKeyResult = condense(validDefinitions, MissingKeyError.is, (a, b) => !a.keys.some((k) => !b.keys.includes(k)), (errors2) => ({ - kind: "missing_key", - node: errors2[0].node, - keys: deduplicateGroups(errors2.map((e) => e.keys)) - })); - validDefinitions = missingKeyResult.filteredDefinitions; - errors.push(...missingKeyResult.condensedErrors); - for (const kind of [ - "invalid_collection_length", - "invalid_string_length", - "number_out_of_range" - ]) { - const rangeErrorResult = condense( - validDefinitions, - (e) => e.kind === kind, - (a, b) => a.ranges.length === b.ranges.length && !a.ranges.some((r) => !b.ranges.some((or) => NumericRange.equals(r, or))), - // TODO merge overlapping ranges better? - (errors2) => ({ - kind, - node: errors2[0].node, - ranges: deduplicateGroups(errors2.map((e) => e.ranges), NumericRange.equals) - }) - ); - validDefinitions = rangeErrorResult.filteredDefinitions; - errors.push(...rangeErrorResult.condensedErrors); - } - validDefinitions[0].errors.filter((e) => e.kind === "duplicate_key"); - const internalErrorResult = condense(validDefinitions, (e) => e.kind === "internal", (_) => false); - validDefinitions = internalErrorResult.filteredDefinitions; - errors.push(...internalErrorResult.condensedErrors); - return { - definitions: validDefinitions.map((d) => d.definition), - condensedErrors: errors - }; -} -function condense(validDefinitions, is, equals, combineAlternatives) { - const errorsOfType = validDefinitions.map((def) => ({ def, errors: def.errors.filter(is) })); - const definitionsWithoutError = errorsOfType.filter((d) => d.errors.length === 0).map((e) => e.def); - if (definitionsWithoutError.length > 0) { - return { condensedErrors: [], filteredDefinitions: definitionsWithoutError }; - } - const distinctErrorsPerNode = errorsOfType.flatMap((d) => d.errors.map((e) => ({ definition: d.def, error: e }))).reduce((entries, e) => { - const entry6 = entries.find((oe) => oe.errors[0].error.node === e.error.node); - if (entry6) { - const error4 = entry6.errors.find((oe) => equals(e.error, oe.error)); - if (error4) { - error4.definitions.push(e.definition); - } else { - entry6.errors.push({ error: e.error, definitions: [e.definition] }); - } - } else { - entries.push({ errors: [{ error: e.error, definitions: [e.definition] }] }); - } - return entries; - }, []); - const distinctErrors = distinctErrorsPerNode.flatMap((e) => e.errors); - const commonErrors = distinctErrors.filter((e) => e.definitions.length === validDefinitions.length).map((e) => e.error); - const definitionsWithUncommonErrors = distinctErrors.filter((e) => e.definitions.length < validDefinitions.length).flatMap((e) => e.definitions); - const definitionsWithOnlyCommonErrors = validDefinitions.filter((d) => !definitionsWithUncommonErrors.includes(d)); - if (definitionsWithOnlyCommonErrors.length > 0) { - return { - filteredDefinitions: definitionsWithOnlyCommonErrors, - condensedErrors: commonErrors - }; - } - const combinedErrors = combineAlternatives ? distinctErrorsPerNode.map((e) => { - const uniqueDefinitions = deduplicateGroups(e.errors.map((e2) => e2.definitions), (a, b) => McdocType.equals(a.definition.typeDef, b.definition.typeDef)); - const ans = { - definitions: uniqueDefinitions, - error: combineAlternatives(e.errors.filter((e2) => !commonErrors.includes(e2.error)).map((e2) => e2.error)) - }; - ans.error.nodesWithConflictingErrors = deduplicateGroups(e.errors.map((e2) => e2.error.nodesWithConflictingErrors ?? [])); - if (ans.error.nodesWithConflictingErrors.length === 0) { - ans.error.nodesWithConflictingErrors = void 0; - } - return ans; - }) : distinctErrorsPerNode.flatMap((e) => e.errors.map((ee) => ({ definitions: ee.definitions, error: ee.error }))); - const conflictingErrors = combinedErrors.filter((e) => e.definitions.length < validDefinitions.length); - const nodesWithConflictingErrors = conflictingErrors.map((e) => e.error.node).filter((n, i, arr) => arr.indexOf(n) === i); - for (const error4 of conflictingErrors) { - error4.error.nodesWithConflictingErrors = nodesWithConflictingErrors; - } - return { - filteredDefinitions: validDefinitions, - condensedErrors: [...commonErrors, ...combinedErrors.map((e) => e.error)] - }; -} -function deduplicateGroups(definitionGroups, predicate) { - const definitions = []; - for (let i = 0; i < definitionGroups.length; i++) { - const group = definitionGroups[i]; - if (group.length === 1) { - definitions.push(group[0]); - continue; - } - definitions.push(...group.filter((v) => !definitionGroups.some((og, oi) => (oi > i || og.length === 1) && predicate ? og.some((ov) => predicate(v, ov)) : og.includes(v)))); - } - return definitions; -} -function getDefaultErrorRange(node, error4) { - const { range: range3 } = node.originalNode; - if (error4 === "missing_key" || error4 === "invalid_collection_length") { - return { start: range3.start, end: range3.start + 1 }; - } - return range3; -} -function getDefaultErrorReporter(ctx, getErrorRange) { - return (error4) => { - const defaultTranslationKey = error4.kind.replaceAll("_", "-"); - let localizedText; - let severity = ErrorSeverity.Error; - switch (error4.kind) { - case "unknown_tuple_element": - localizedText = localize("expected", localize("nothing")); - break; - case "unknown_key": - if (error4.nodesWithConflictingErrors) { - localizedText = localize("invalid-key-combination", arrayToMessage(error4.nodesWithConflictingErrors.map((n) => McdocType.toString(n.inferredType)), true, "and")); - } else { - localizedText = localize(defaultTranslationKey, error4.node.inferredType.kind === "literal" ? localeQuote(error4.node.inferredType.value.value.toString()) : `<${localize(`mcdoc.type.${error4.node.inferredType.kind}`)}>`); - severity = ErrorSeverity.Warning; - } - break; - case "missing_key": - if (error4.keys.length === 1) { - localizedText = localize(defaultTranslationKey, localeQuote(error4.keys[0])); - } else { - localizedText = localize("mcdoc.runtime.checker.some-missing-keys", arrayToMessage(error4.keys)); - } - break; - case "invalid_collection_length": - case "invalid_string_length": - case "number_out_of_range": - const baseKey = error4.kind === "invalid_collection_length" ? "mcdoc.runtime.checker.range.collection" : error4.kind === "invalid_string_length" ? "mcdoc.runtime.checker.range.string" : "mcdoc.runtime.checker.range.number"; - const rangeMessages = error4.ranges.map((r) => { - const left = r.min !== void 0 ? localize(RangeKind.isLeftExclusive(r.kind) ? "mcdoc.runtime.checker.range.left-exclusive" : "mcdoc.runtime.checker.range.left-inclusive", r.min) : void 0; - const right = r.max !== void 0 ? localize(RangeKind.isLeftExclusive(r.kind) ? "mcdoc.runtime.checker.range.right-exclusive" : "mcdoc.runtime.checker.range.right-inclusive", r.max) : void 0; - if (left !== void 0 && right !== void 0) { - return localize("mcdoc.runtime.checker.range.concat", left, right); - } - return left ?? right; - }).filter((r) => r !== void 0); - localizedText = localize("expected", localize(baseKey, arrayToMessage(rangeMessages, false))); - break; - case "type_mismatch": - localizedText = localize("expected", arrayToMessage(error4.expected.map((e) => e.kind === "enum" ? arrayToMessage(e.values.map((v) => ResourceLocation.shorten(v.value.toString()))) : e.kind === "literal" ? localeQuote(e.value.value.toString()) : localize(`mcdoc.type.${e.kind}`)), false)); - break; - case "expected_key_value_pair": - localizedText = localize(`mcdoc.runtime.checker.${defaultTranslationKey}`); - break; - case "internal": - return; - default: - localizedText = localize(defaultTranslationKey); - } - ctx.err.report(localizedText, getErrorRange(error4.node, error4.kind), severity); - }; -} - -// node_modules/@spyglassmc/mcdoc/lib/runtime/checker/index.js -function reference2(node, path6, ctx) { - typeDefinition(node, { kind: "reference", path: path6 }, ctx); -} -function dispatcher(node, registry, index4, ctx) { - const parallelIndices = typeof index4 === "string" ? [{ kind: "static", value: index4 }] : Array.isArray(index4) ? index4 : [index4]; - typeDefinition(node, { kind: "dispatcher", registry, parallelIndices }, ctx); -} -function isAssignable(assignValue, typeDef, ctx, convert) { - if (assignValue.kind === "literal" && typeDef.kind === "literal" && assignValue.value.kind === typeDef.value.kind && !assignValue.attributes && !typeDef.attributes) { - return assignValue.value.value === typeDef.value.value; - } - let ans = true; - const newCtx = McdocCheckerContext.create(ctx, { - tryConvertTo: convert, - getChildren: (_, d) => { - switch (d.kind) { - case "list": - const vals = getPossibleTypes(d.item); - return [vals.map((v) => ({ originalNode: v, inferredType: v }))]; - case "byte_array": - return [[{ - originalNode: { kind: "byte" }, - inferredType: { kind: "byte" } - }]]; - case "int_array": - return [[{ - originalNode: { kind: "int" }, - inferredType: { kind: "int" } - }]]; - case "long_array": - return [[{ - originalNode: { kind: "long" }, - inferredType: { kind: "long" } - }]]; - case "struct": - return d.fields.map((f) => { - const vals2 = getPossibleTypes(f.type); - return { - attributes: f.attributes, - key: { originalNode: f.key, inferredType: f.key }, - possibleValues: vals2.map((v) => ({ originalNode: v, inferredType: v })) - }; - }); - case "tuple": - return d.items.map((f) => { - const vals2 = getPossibleTypes(f); - return vals2.map((v) => ({ originalNode: v, inferredType: v })); - }); - default: - return []; - } - }, - reportError: () => { - ans = false; - } - }); - const node = { - parent: void 0, - runtimeKey: void 0, - possibleValues: [] - }; - node.possibleValues = getPossibleTypes(typeDef).map((v) => ({ - entryNode: node, - node: { originalNode: v, inferredType: v }, - children: [], - definitionsByParent: [] - })); - typeDefinition(getPossibleTypes(assignValue).map((v) => ({ originalNode: v, inferredType: v })), typeDef, newCtx); - return ans; -} -function typeDefinition(runtimeValues, typeDef, ctx) { - const rootNode = { - parent: void 0, - runtimeKey: void 0, - possibleValues: [] - }; - rootNode.possibleValues = runtimeValues.map((n) => ({ - node: n, - entryNode: rootNode, - definitionsByParent: [], - children: [] - })); - for (const value of rootNode.possibleValues) { - const simplifiedRoot = simplify(typeDef, { ctx, node: value }).typeDef; - const validRootDefinitions = simplifiedRoot.kind === "union" ? simplifiedRoot.members : [simplifiedRoot]; - if (validRootDefinitions.length === 0 && (typeDef.kind !== "union" || typeDef.members.length > 0)) { - validRootDefinitions.push({ kind: "any" }); - } - value.definitionsByParent = [{ - parents: [], - keyDefinition: void 0, - runtimeNode: value, - originalTypeDef: typeDef, - condensedErrors: [], - validDefinitions: [] - }]; - value.definitionsByParent[0].validDefinitions = validRootDefinitions.map((d) => ({ - groupNode: value.definitionsByParent[0], - typeDef: d, - children: [] - })); - } - const nodeQueue = [rootNode]; - while (nodeQueue.length !== 0) { - const node = nodeQueue.shift(); - for (const value of node.possibleValues) { - const inferredSimplified = simplify(value.node.inferredType, { ctx, node: value }).typeDef; - const children = ctx.getChildren(value.node.originalNode, inferredSimplified); - const childNodes = children.map((c) => { - const ans = { - parent: value, - runtimeKey: !Array.isArray(c) ? c.key : void 0, - possibleValues: [] - }; - ans.possibleValues = (Array.isArray(c) ? c : c.possibleValues).map((v) => ({ - entryNode: ans, - node: v, - definitionsByParent: [], - condensedErrors: [], - children: [] - })); - return ans; - }); - for (const definitionGroup of value.definitionsByParent) { - const definitionErrors = []; - if (definitionGroup.validDefinitions.length === 0) { - definitionGroup.condensedErrors = [[{ - kind: "type_mismatch", - node: value.node, - expected: [] - }]]; - } - for (const def of definitionGroup.validDefinitions) { - const { errors, childDefinitions } = checkShallowly(value.node, inferredSimplified, children, def.typeDef, ctx); - definitionErrors.push({ definition: def, errors }); - for (let i = 0; i < childDefinitions.length; i++) { - const childDef = childDefinitions[i]; - if (!childDef) { - continue; - } - const child = childNodes[i]; - const existingDef = child.possibleValues.length > 0 ? child.possibleValues[0].definitionsByParent.find((d) => (d.keyDefinition === void 0 || childDef.keyType === void 0 ? d.keyDefinition === void 0 : McdocType.equals(d.keyDefinition, childDef.keyType)) && McdocType.equals(d.originalTypeDef, childDef.type)) : void 0; - for (const childValue of child.possibleValues) { - if (existingDef) { - existingDef.parents.push(def); - def.children.push(existingDef); - continue; - } - const simplified = simplify(childDef.type, { ctx, node: childValue }).typeDef; - const childDefinitionGroup = { - parents: [def], - runtimeNode: childValue, - keyDefinition: childDef.keyType, - originalTypeDef: childDef.type, - validDefinitions: [], - condensedErrors: [], - desc: childDef.desc - }; - childDefinitionGroup.validDefinitions = (simplified.kind === "union" ? simplified.members : [simplified]).map((d) => ({ - groupNode: childDefinitionGroup, - typeDef: d, - children: [] - })); - childValue.definitionsByParent.push(childDefinitionGroup); - def.children.push(childDefinitionGroup); - } - } - } - condenseAndPropagate(definitionGroup, definitionErrors); - } - value.children = childNodes; - nodeQueue.push(...childNodes); - } - } - if (ctx.attachTypeInfo) { - for (const node of rootNode.possibleValues) { - attachTypeInfo(node, ctx); - } - } - for (const error4 of rootNode.possibleValues.flatMap((v) => v.definitionsByParent).flatMap((d) => d.condensedErrors).flat()) { - if (error4) { - ctx.reportError(error4); - } - } -} -function attachTypeInfo(node, ctx) { - const definitions = node.definitionsByParent.flatMap((d) => d.validDefinitions); - if (definitions.length === 1) { - const { typeDef, groupNode } = definitions[0]; - ctx.attachTypeInfo?.(node.node.originalNode, typeDef, groupNode.desc); - handleNodeAttachers(node.node, typeDef, ctx); - if (node.entryNode.runtimeKey && groupNode.keyDefinition) { - ctx.attachTypeInfo?.(node.entryNode.runtimeKey.originalNode, groupNode.keyDefinition, groupNode.desc); - handleNodeAttachers(node.entryNode.runtimeKey, groupNode.keyDefinition, ctx); - } - } else if (definitions.length > 1) { - ctx.attachTypeInfo?.(node.node.originalNode, { - kind: "union", - members: definitions.map((d) => d.typeDef) - }); - if (node.entryNode.runtimeKey) { - ctx.attachTypeInfo?.(node.entryNode.runtimeKey.originalNode, { - kind: "union", - members: node.definitionsByParent.map((d) => d.keyDefinition).filter((d) => d !== void 0) - }); - } - } - for (const child of node.children.flatMap((c) => c.possibleValues)) { - attachTypeInfo(child, ctx); - } -} -function handleNodeAttachers(runtimeValue, typeDef, ctx) { - const { nodeAttacher, stringAttacher } = ctx; - if (!nodeAttacher && !stringAttacher) { - return; - } - handleAttributes(typeDef.attributes, ctx, (handler, config) => { - const parser = handler.stringParser?.(config, typeDef, ctx); - if (parser && stringAttacher) { - stringAttacher(runtimeValue.originalNode, (node) => { - const src = new Source(node.value, node.valueMap); - const start = src.cursor; - const child = parser(src, ctx); - if (!child) { - ctx.err.report(localize("expected", localize("mcdoc.runtime.checker.value")), Range.create(start, src.skipRemaining())); - return; - } else if (src.canRead()) { - ctx.err.report(localize("mcdoc.runtime.checker.trailing"), Range.create(src.cursor, src.skipRemaining())); - } - node.children = [child]; - }); - } - const checker = handler.checker?.(config, runtimeValue.inferredType, ctx); - if (checker && nodeAttacher) { - nodeAttacher(runtimeValue.originalNode, (node) => { - checker(node, ctx); - }); - } - }); -} -function checkShallowly(runtimeNode, simplifiedInferred, children, typeDef, ctx) { - const childDefinitions = Array(children.length).fill(void 0); - if (typeDef.kind === "any" || typeDef.kind === "unsafe" || simplifiedInferred.kind === "unsafe") { - return { childDefinitions, errors: [] }; - } - const typeDefValueType = getValueType(typeDef); - let runtimeValueType = getValueType(simplifiedInferred); - if (runtimeValueType.kind !== typeDefValueType.kind) { - simplifiedInferred = ctx.tryConvertTo(runtimeNode.originalNode, typeDefValueType) ?? simplifiedInferred; - runtimeValueType = getValueType(simplifiedInferred); - } - if (runtimeValueType.kind !== typeDefValueType.kind) { - return { - childDefinitions, - errors: [{ kind: "type_mismatch", node: runtimeNode, expected: [typeDef] }] - }; - } - const errors = []; - let assignable = true; - handleAttributes(typeDef.attributes, ctx, (handler, config) => { - if (handler.checkInferred?.(config, simplifiedInferred, ctx) === false) { - assignable = false; - } - }); - if (!assignable) { - errors.push({ kind: "internal", node: runtimeNode }); - } - if (typeDef.kind === "literal" && (simplifiedInferred.kind !== "literal" || typeDef.value.value !== simplifiedInferred.value.value) || typeDef.kind === "enum" && (simplifiedInferred.kind !== "literal" || !typeDef.values.some((v) => v.value === simplifiedInferred.value.value))) { - return { - childDefinitions, - errors: [{ kind: "type_mismatch", node: runtimeNode, expected: [typeDef] }] - }; - } - switch (typeDef.kind) { - case "byte": - case "short": - case "int": - case "long": - case "float": - case "double": - if (typeDef.valueRange && simplifiedInferred.kind === "literal" && simplifiedInferred.value.kind !== "string" && simplifiedInferred.value.kind !== "boolean" && !NumericRange.isInRange(typeDef.valueRange, simplifiedInferred.value.value)) { - errors.push({ - kind: "number_out_of_range", - node: runtimeNode, - ranges: [typeDef.valueRange] - }); - } - break; - case "string": - if (typeDef.lengthRange && simplifiedInferred.kind === "literal" && simplifiedInferred.value.kind === "string" && !NumericRange.isInRange(typeDef.lengthRange, [...simplifiedInferred.value.value].length)) { - errors.push({ - kind: "invalid_string_length", - node: runtimeNode, - ranges: [typeDef.lengthRange] - }); - } - break; - case "struct": { - const literalKvps = /* @__PURE__ */ new Map(); - const otherKvps = []; - for (let i = 0; i < children.length; i++) { - const child = children[i]; - if (Array.isArray(child)) { - continue; - } - if (child.key.inferredType.kind === "literal" && child.key.inferredType.value.kind === "string") { - const existing = literalKvps.get(child.key.inferredType.value.value); - if (existing) { - existing.values.push({ pair: child, index: i }); - } else { - literalKvps.set(child.key.inferredType.value.value, { - values: [{ pair: child, index: i }], - definition: void 0 - }); - } - } else { - otherKvps.push({ value: child, index: i }); - } - } - const missingKeys = /* @__PURE__ */ new Set(); - for (const pair of typeDef.fields) { - const otherKvpMatches = []; - let foundMatch = false; - if (pair.key.kind === "literal" && pair.key.value.kind === "string") { - const runtimeChild = literalKvps.get(pair.key.value.value); - if (runtimeChild) { - foundMatch = true; - runtimeChild.definition = { keyType: pair.key, type: pair.type, desc: pair.desc }; - } - } - if (!foundMatch) { - for (const kvp of otherKvps) { - if (isAssignable(kvp.value.key.inferredType, pair.key, ctx, (type2, target) => type2 === kvp.value.key.inferredType ? ctx.tryConvertTo(kvp.value.key.originalNode, target) : void 0)) { - foundMatch = true; - otherKvpMatches.push(kvp.index); - } - } - for (const kvp of literalKvps.entries()) { - const literalType3 = { - kind: "literal", - value: { kind: "string", value: kvp[0] } - }; - if ((!kvp[1].definition || kvp[1].definition.keyType?.kind !== "literal") && kvp[1].values.some((v) => isAssignable(literalType3, pair.key, ctx, (type2, target) => type2 === literalType3 ? ctx.tryConvertTo(v.pair.key.originalNode, target) : void 0))) { - foundMatch = true; - kvp[1].definition = { keyType: pair.key, type: pair.type, desc: pair.desc }; - } - } - } - for (const match of otherKvpMatches) { - childDefinitions[match] = { keyType: pair.key, type: pair.type, desc: pair.desc }; - } - if (!foundMatch && !ctx.allowMissingKeys && pair.key.kind === "literal" && pair.key.value.kind === "string" && pair.optional !== true) { - missingKeys.add(pair.key.value.value); - } - } - errors.push(...Array.from(missingKeys).map((key2) => ({ - kind: "missing_key", - node: runtimeNode, - keys: [key2] - }))); - for (const kvp of literalKvps.values()) { - for (const value of kvp.values) { - childDefinitions[value.index] = kvp.definition; - if (kvp.values.length > 1) { - errors.push({ kind: "duplicate_key", node: value.pair.key }); - } - } - } - for (let i = 0; i < children.length; i++) { - const childDef = childDefinitions[i]; - const child = children[i]; - if (childDef === void 0) { - if (Array.isArray(child)) { - errors.push(...child.map((v) => ({ - kind: "expected_key_value_pair", - node: v - }))); - } else { - errors.push({ kind: "unknown_key", node: child.key }); - } - } - } - break; - } - case "list": - case "byte_array": - case "int_array": - case "long_array": { - let itemType; - switch (typeDef.kind) { - case "list": - itemType = typeDef.item; - break; - case "byte_array": - itemType = { kind: "byte", valueRange: typeDef.valueRange }; - break; - case "int_array": - itemType = { kind: "int", valueRange: typeDef.valueRange }; - break; - case "long_array": - itemType = { kind: "long", valueRange: typeDef.valueRange }; - break; - } - for (let i = 0; i < childDefinitions.length; i++) { - childDefinitions[i] = { type: itemType }; - } - if (typeDef.lengthRange && !NumericRange.isInRange(typeDef.lengthRange, children.length)) { - errors.push({ - kind: "invalid_collection_length", - node: runtimeNode, - ranges: [typeDef.lengthRange] - }); - } - break; - } - case "tuple": { - for (let i = 0; i < children.length; i++) { - const child = children[i]; - if (i < typeDef.items.length) { - childDefinitions[i] = { type: typeDef.items[i] }; - } else { - const values = Array.isArray(child) ? child : [...child.possibleValues, child.key]; - errors.push(...values.map((v) => ({ - kind: "unknown_tuple_element", - node: v - }))); - } - } - if (typeDef.items.length > children.length) { - errors.push({ - kind: "invalid_collection_length", - node: runtimeNode, - ranges: [{ kind: 0, max: typeDef.items.length, min: typeDef.items.length }] - }); - } - break; - } - } - return { childDefinitions, errors }; -} -function getPossibleTypes(typeDef) { - return typeDef.kind === "union" ? typeDef.members.flatMap((m) => getPossibleTypes(m)) : [typeDef]; -} -function simplify(typeDef, context) { - function wrap(result) { - if (!result.typeDef.attributes?.length) { - return result; - } - handleAttributes(typeDef.attributes, context.ctx, (handler, config) => { - if (handler.mapType) { - result.typeDef = handler.mapType(config, result.typeDef, context.ctx); - } - }); - return result; - } - switch (typeDef.kind) { - case "reference": - return wrap(simplifyReference(typeDef, context)); - case "dispatcher": - return wrap(simplifyDispatcher(typeDef, context)); - case "indexed": - return wrap(simplifyIndexed(typeDef, context)); - case "union": - return wrap(simplifyUnion(typeDef, context)); - case "struct": - return wrap(simplifyStruct(typeDef, context)); - case "list": - return wrap(simplifyList(typeDef, context)); - case "tuple": - return wrap(simplifyTuple(typeDef, context)); - case "enum": - return wrap(simplifyEnum(typeDef, context)); - case "concrete": - return wrap(simplifyConcrete(typeDef, context)); - case "template": - return wrap(simplifyTemplate(typeDef, context)); - case "mapped": - return wrap(simplifyMapped(typeDef, context)); - default: - return wrap({ typeDef }); - } -} -function simplifyReference(typeDef, context) { - if (!typeDef.path) { - context.ctx.logger.warn(`Tried to access empty reference`); - return { typeDef: { kind: "union", members: [] } }; - } - const mapped = context.typeMapping?.[typeDef.path]; - if (mapped) { - return { typeDef: mapped, dynamicData: true }; - } - const symbol7 = context.ctx.symbols.query(context.ctx.doc, "mcdoc", typeDef.path); - const data = symbol7.getData(TypeDefSymbolData.is); - if (!data?.typeDef) { - context.ctx.logger.warn(`Tried to access unknown reference ${typeDef.path}`); - return { typeDef: { kind: "union", members: [] } }; - } - if (context.ctx.config.env.enableMcdocCaching && data.simplifiedTypeDef) { - return { typeDef: data.simplifiedTypeDef }; - } - const simplifiedResult = simplify(data.typeDef, context); - if (typeDef.attributes?.length) { - simplifiedResult.typeDef = { - ...simplifiedResult.typeDef, - attributes: [...typeDef.attributes, ...simplifiedResult.typeDef.attributes ?? []] - }; - } - if (context.ctx.config.env.enableMcdocCaching && !simplifiedResult.dynamicData) { - symbol7.amend({ - data: { - data: { - ...data, - simplifiedTypeDef: simplifiedResult.typeDef - } - } - }); - } - return simplifiedResult; -} -function simplifyDispatcher(typeDef, context) { - const dispatcherQuery = context.ctx.symbols.query(context.ctx.doc, "mcdoc/dispatcher", typeDef.registry); - const dispatcher2 = dispatcherQuery.symbol?.members; - if (!dispatcher2) { - context.ctx.logger.warn(`Tried to access unknown dispatcher ${typeDef.registry}`); - return { typeDef: { kind: "union", members: [] } }; - } - const result = resolveIndices(typeDef.parallelIndices, dispatcher2, dispatcherQuery, context); - return result; -} -function simplifyIndexed(typeDef, context) { - const childResult = simplify(typeDef.child, { - ...context, - typeArgs: [] - }); - const child = childResult.typeDef; - if (child.kind !== "struct") { - context.ctx.logger.warn(`Tried to index un-indexable type ${child.kind}`); - return { typeDef: { kind: "union", members: [] }, dynamicData: childResult.dynamicData }; - } - const symbolMap = {}; - for (const field of child.fields) { - if (field.key.kind === "literal" && field.key.value.kind === "string") { - symbolMap[field.key.value.value] = { - data: { - typeDef: field.type - } - }; - } - } - const simplified = resolveIndices(typeDef.parallelIndices, symbolMap, void 0, context); - return { ...simplified, dynamicData: childResult.dynamicData ?? simplified.dynamicData }; -} -function resolveIndices(parallelIndices, symbolMap, symbolQuery, context) { - let dynamicData = false; - let values = []; - function pushValue(key2, data) { - if (!shouldKeepAccordingToAttributeFilters(data.typeDef.attributes, context.ctx)) { - return; - } - if (context.ctx.config.env.enableMcdocCaching && data.simplifiedTypeDef) { - if (data.simplifiedTypeDef.kind === "union") { - values.push(...data.simplifiedTypeDef.members); - } else { - values.push(data.simplifiedTypeDef); - } - } else { - const simplifiedResult = simplify(data.typeDef, context); - if (simplifiedResult.dynamicData) { - dynamicData = true; - } else if (context.ctx.config.env.enableMcdocCaching && symbolQuery) { - symbolQuery.member(key2, (s) => s.amend({ - data: { data: { ...data, simplifiedTypeDef: simplifiedResult.typeDef } } - })); - } - if (simplifiedResult.typeDef.kind === "union") { - values.push(...simplifiedResult.typeDef.members); - } else { - values.push(simplifiedResult.typeDef); - } - } - } - let unkownTypeDef = false; - function getUnknownTypeDef() { - if (unkownTypeDef === false) { - const data = symbolMap["%unknown"]?.data; - unkownTypeDef = TypeDefSymbolData.is(data) ? data : void 0; - } - return unkownTypeDef; - } - for (const index4 of parallelIndices) { - let lookup = []; - if (index4.kind === "static") { - if (index4.value === "%fallback") { - values = []; - for (const [key2, value] of Object.entries(symbolMap)) { - if (TypeDefSymbolData.is(value.data)) { - pushValue(key2, value.data); - } - } - break; - } - if (index4.value.startsWith("minecraft:")) { - lookup.push(index4.value.substring(10)); - } else { - lookup.push(index4.value); - } - } else { - dynamicData = true; - let possibilities = context.isMember ? [{ value: context.node, key: context.node.entryNode.runtimeKey }] : [{ - value: context.node.entryNode.parent, - key: context.node.entryNode.runtimeKey - }]; - for (const entry6 of index4.accessor) { - if (typeof entry6 !== "string" && entry6.keyword === "parent") { - possibilities = possibilities.map((n) => ({ - value: n.value?.entryNode.parent, - key: n.value?.entryNode.runtimeKey - })); - } else if (typeof entry6 !== "string" && entry6.keyword === "key") { - possibilities = possibilities.map((p) => ({ - value: p.key ? { node: p.key, entryNode: { parent: p.value, runtimeKey: p.key } } : void 0, - key: void 0 - })); - break; - } else if (typeof entry6 === "string") { - const newPossibilities = []; - for (const node of possibilities) { - const possibleChildren = node.value ? context.ctx.getChildren(node.value.node.originalNode, simplify(node.value.node.inferredType, { ...context, node: node.value }).typeDef).filter((child) => { - if (!Array.isArray(child)) { - return child.key.inferredType.kind === "literal" && child.key.inferredType.value.kind === "string" && child.key.inferredType.value.value === entry6; - } - return false; - }).flatMap((c) => c.possibleValues.map((v) => ({ - value: { - node: v, - entryNode: { parent: node.value, runtimeKey: c.key } - }, - key: void 0 - }))) : [{ value: void 0, key: void 0 }]; - newPossibilities.push(...possibleChildren); - } - possibilities = newPossibilities; - } else { - lookup.push("%none"); - break; - } - } - for (const value of possibilities.map((p) => p.value?.node)) { - if (value?.inferredType.kind === "literal" && value.inferredType.value.kind === "string") { - const ans = value.inferredType.value.value; - if (ans.startsWith("minecraft:")) { - lookup.push(ans.substring(10)); - } else { - lookup.push(ans); - } - } else { - lookup.push("%none"); - } - } - } - if (lookup.length === 0) { - lookup = ["%none"]; - } - const currentValues = lookup.map((v) => { - const data = symbolMap[v]?.data; - return { value: v, data: TypeDefSymbolData.is(data) ? data : getUnknownTypeDef() }; - }); - const missing = currentValues.find((v) => !v.data); - if (missing) { - return { typeDef: { kind: "any" }, dynamicData }; - } else { - for (const entry6 of currentValues) { - pushValue(entry6.value, entry6.data); - } - } - } - if (values.length === 1) { - return { typeDef: values[0], dynamicData }; - } - return { typeDef: { kind: "union", members: values }, dynamicData }; -} -function simplifyUnion(typeDef, context) { - let dynamicData = false; - let validMembers = typeDef.members.filter((member) => shouldKeepAccordingToAttributeFilters(member.attributes, context.ctx)); - const filterCanonical = context.ctx.requireCanonical && validMembers.some((m) => m.attributes?.some((a) => a.name === "canonical")); - if (filterCanonical) { - validMembers = validMembers.filter((member) => member.attributes?.some((a) => a.name === "canonical")); - } - if (validMembers.length === 1) { - return simplify(validMembers[0], context); - } - const members = []; - for (const member of validMembers) { - const { typeDef: simplified, dynamicData: memberDynamic } = simplify(member, context); - if (memberDynamic) { - dynamicData = true; - } - if (simplified.kind === "union") { - members.push(...simplified.members); - } else { - members.push(simplified); - } - } - if (members.length === 1) { - return { typeDef: members[0], dynamicData }; - } - return { typeDef: { kind: "union", members }, dynamicData }; -} -function simplifyStruct(typeDef, context) { - const fields = []; - let dynamicData = false; - function addField(key2, field) { - handleAttributes(field.attributes, context.ctx, (handler, config) => { - if (handler.mapField) { - field = handler.mapField(config, field, context.ctx); - } - }); - if (typeof key2 === "string") { - fields.push({ - ...field, - key: { kind: "literal", value: { kind: "string", value: key2 } } - }); - } else if (key2.kind === "union") { - key2.members.forEach((m) => addField(m, { ...field, optional: true })); - } else { - fields.push({ ...field, key: key2 }); - } - } - for (const field of typeDef.fields) { - if (!shouldKeepAccordingToAttributeFilters(field.attributes, context.ctx)) { - continue; - } - if (field.kind === "pair") { - let structKey2; - if (typeof field.key === "string") { - structKey2 = field.key; - } else { - const simplifiedKeyResult = simplify(field.key, { - ...context, - isMember: true, - typeArgs: [] - }); - if (simplifiedKeyResult.dynamicData) { - dynamicData = true; - } - structKey2 = simplifiedKeyResult.typeDef; - } - let mappedField; - if (context.typeMapping) { - mappedField = { - ...field, - type: { - kind: "mapped", - child: field.type, - mapping: context.typeMapping - } - }; - dynamicData = true; - } else { - mappedField = field; - } - addField(structKey2, mappedField); - } else { - const simplifiedSpread = simplify(field.type, { - ...context, - isMember: true, - typeArgs: [] - }); - if (simplifiedSpread.dynamicData) { - dynamicData = true; - } - if (simplifiedSpread.typeDef.kind === "any") { - fields.push({ kind: "pair", key: { kind: "any" }, type: { kind: "any" } }); - } else if (simplifiedSpread.typeDef.kind === "struct") { - fields.push(...simplifiedSpread.typeDef.fields); - } - } - } - return { - typeDef: { kind: "struct", fields }, - dynamicData - }; -} -function simplifyList(typeDef, context) { - if (!context.typeMapping) { - return { typeDef }; - } - return { - typeDef: { - ...typeDef, - item: { kind: "mapped", child: typeDef.item, mapping: context.typeMapping } - }, - // Don't cache mapped field data - // TODO find a better way to handle mapped types with caching - dynamicData: true - }; -} -function simplifyTuple(typeDef, context) { - if (!context.typeMapping) { - return { typeDef }; - } - return { - typeDef: { - ...typeDef, - items: typeDef.items.map((item) => ({ - kind: "mapped", - child: item, - mapping: context.typeMapping - })) - }, - // Don't cache mapped field data - // TODO find a better way to handle mapped types with caching - dynamicData: true - }; -} -function simplifyEnum(typeDef, context) { - const filteredValues = typeDef.values.filter((value) => shouldKeepAccordingToAttributeFilters(value.attributes, context.ctx)); - return { typeDef: { ...typeDef, values: filteredValues } }; -} -function simplifyConcrete(typeDef, context) { - let dynamicData = false; - const simplifiedArgs = typeDef.typeArgs.map((arg) => { - const ans = simplify(arg, context); - if (ans.dynamicData) { - dynamicData = true; - } - return ans.typeDef; - }); - const result = simplify(typeDef.child, { ...context, typeArgs: simplifiedArgs }); - return { typeDef: result.typeDef, dynamicData: dynamicData || result.dynamicData }; -} -function simplifyTemplate(typeDef, context) { - if (context.typeArgs?.length !== typeDef.typeParams.length) { - context.ctx.logger.warn(`Expected ${typeDef.typeParams.length} mcdoc type args for ${McdocType.toString(typeDef.child)}, but got ${context.typeArgs?.length ?? 0}`); - } - const mapping = Object.fromEntries(typeDef.typeParams.map((param, i) => { - const arg = context.typeArgs?.[i] ?? { kind: "union", members: [] }; - return [param.path, arg]; - })); - return simplify(typeDef.child, { ...context, typeArgs: [], typeMapping: mapping }); -} -function simplifyMapped(typeDef, context) { - let dynamicData = false; - const simplifiedMapping = Object.fromEntries(Object.entries(typeDef.mapping).map(([path6, param]) => { - const ans2 = simplify(param, context); - if (ans2.dynamicData) { - dynamicData = true; - } - return [path6, ans2.typeDef]; - })); - const ans = simplify(typeDef.child, { ...context, typeMapping: simplifiedMapping }); - return { typeDef: ans.typeDef, dynamicData: dynamicData || ans.dynamicData }; -} -function getValueType(type2) { - switch (type2.kind) { - case "literal": - return { kind: type2.value.kind }; - case "enum": - if (type2.enumKind === void 0) { - return { kind: "any" }; - } - return { kind: type2.enumKind }; - default: - return type2; - } -} - -// node_modules/@spyglassmc/mcdoc/lib/runtime/completer/index.js -var completer_exports = {}; -__export(completer_exports, { - getFields: () => getFields, - getValues: () => getValues -}); -function getFields(typeDef, ctx) { - switch (typeDef.kind) { - case "union": - const allFields = /* @__PURE__ */ new Map(); - for (const member of typeDef.members) { - for (const field of getFields(member, ctx)) { - allFields.set(field.key, field); - } - } - return [...allFields.values()]; - case "struct": - return typeDef.fields.flatMap((field) => { - if (typeof field.key === "string") { - return [{ key: field.key, field }]; - } - if (field.key.kind === "string" || field.key.kind === "literal" && field.key.value.kind === "string" || field.key.kind === "enum" && field.key.enumKind === "string") { - const ans = getStringCompletions(field.key, ctx); - if (ans.length > 0) { - return ans.map((c) => ({ key: c.value, field })); - } - } - if (field.key.kind === "literal") { - return [{ key: `${field.key.value.value}`, field }]; - } - if (field.key.kind === "string") { - return getStringCompletions(field.key, ctx).map((c) => ({ key: c.value, field })); - } - return getValues(field.key, ctx).map((c) => ({ key: c.value, field })); - }); - default: - return []; - } -} -function getValues(typeDef, ctx) { - if (typeDef.kind === "string" || typeDef.kind === "literal" && typeDef.value.kind === "string" || typeDef.kind === "enum" && typeDef.enumKind === "string") { - const ans = getStringCompletions(typeDef, ctx); - if (ans.length > 0) { - return ans; - } - } - switch (typeDef.kind) { - case "union": - const allValues = /* @__PURE__ */ new Map(); - for (const member of typeDef.members) { - for (const value of getValues(member, ctx)) { - allValues.set(value.value, value); - } - } - return [...allValues.values()]; - case "reference": - if (!typeDef.path) { - return []; - } - const symbol7 = ctx.symbols.query(ctx.doc, "mcdoc", typeDef.path); - const def = symbol7.getData(TypeDefSymbolData.is)?.typeDef; - if (!def) { - return []; - } - if (typeDef.attributes?.length) { - return getValues({ - ...def, - attributes: [...typeDef.attributes, ...def.attributes ?? []] - }, ctx); - } - return getValues(def, ctx); - case "literal": - return [{ value: `${typeDef.value.value}`, kind: typeDef.value.kind }]; - case "boolean": - return ["false", "true"].map((v) => ({ value: v, kind: "boolean" })); - case "enum": - const filteredValues = typeDef.values.filter((value) => shouldKeepAccordingToAttributeFilters(value.attributes, ctx)); - return filteredValues.map((v) => ({ - value: `${v.value}`, - detail: v.identifier, - kind: typeDef.enumKind ?? "string", - documentation: v.desc - })); - case "byte": - case "short": - case "int": - case "long": - case "float": - case "double": - return getNumericCompletions(typeDef, ctx); - default: - return []; - } -} -function getStringCompletions(typeDef, ctx) { - const ans = []; - handleAttributes(typeDef.attributes, ctx, (handler, config) => { - const mock = handler.stringMocker?.(config, typeDef, ctx); - if (!mock) { - return; - } - const items = ctx.meta.getCompleter(mock.type)(mock, ctx); - ans.push(...items.map((item) => ({ - value: item.label, - kind: "string", - labelSuffix: item.labelSuffix, - detail: item.detail, - completionKind: item.kind, - insertText: item.insertText, - sortText: item.sortText - }))); - }); - if (ans.length === 0 && typeDef.kind === "literal") { - ans.push({ value: `${typeDef.value.value}`, kind: "string" }); - } - return ans; -} -function getNumericCompletions(typeDef, ctx) { - const ans = []; - handleAttributes(typeDef.attributes, ctx, (handler, config) => { - const items = handler.numericCompleter?.(config, ctx); - if (!items) { - return; - } - ans.push(...items.map((item) => ({ - value: item.label, - kind: typeDef.kind, - labelSuffix: item.labelSuffix, - detail: item.detail, - completionKind: item.kind, - insertText: item.insertText, - sortText: item.sortText - }))); - }); - return ans; -} - -// node_modules/@spyglassmc/mcdoc/lib/index.js -var initialize = ({ meta }) => { - meta.registerLanguage("mcdoc", { extensions: [".mcdoc"], parser: module_2 }); - registerBuiltinAttributes(meta); - meta.registerUriBinder(uriBinder); - meta.setUriSorter(uriSorter); - registerMcdocBinders(meta); - registerMcdocColorizer(meta); - registerMcdocFormatter(meta); - registerMcdocChecker(meta); -}; - -// node_modules/@spyglassmc/json/lib/parser/index.js -var parser_exports2 = {}; -__export(parser_exports2, { - JsonStringOptions: () => JsonStringOptions, - array: () => array, - boolean: () => boolean6, - entry: () => entry, - file: () => file5, - null_: () => null_, - number: () => number3, - object: () => object, - string: () => string7 -}); - -// node_modules/@spyglassmc/json/lib/parser/boolean.js -var boolean6 = (src, _ctx) => { - const start = src.cursor; - if (src.trySkip("false")) { - return { type: "json:boolean", range: Range.create(start, src), value: false }; - } - if (src.trySkip("true")) { - return { type: "json:boolean", range: Range.create(start, src), value: true }; - } - return Failure; -}; - -// node_modules/@spyglassmc/json/lib/parser/null.js -var null_ = (src, ctx) => { - const start = src.cursor; - if (src.trySkip("null")) { - return { type: "json:null", range: Range.create(start, src) }; - } - return Failure; -}; - -// node_modules/@spyglassmc/json/lib/parser/number.js -var number3 = (src, ctx) => { - const value = select([{ - regex: /^-?(?:0|[1-9]\d*)(?!\d|[.eE])/, - parser: long2({ pattern: /^-?(?:0|[1-9]\d*)$/ }) - }, { - parser: float2({ - // Regex form of the chart from https://www.json.org. - pattern: /^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][-+]?\d+)?$/ - }) - }])(src, ctx); - return { type: "json:number", children: [value], value, range: value.range }; -}; - -// node_modules/@spyglassmc/json/lib/parser/string.js -var JsonStringOptions = { - escapable: { characters: ["b", "f", "n", "r", "t"], unicode: true }, - quotes: ['"'] -}; -var string7 = (src, ctx) => setType("json:string", string4(JsonStringOptions))(src, ctx); - -// node_modules/@spyglassmc/json/lib/parser/object.js -var object = (src, ctx) => setType("json:object", record2({ - start: "{", - pair: { key: string7, sep: ":", value: entry, end: ",", trailingEnd: false }, - end: "}" -}))(src, ctx); - -// node_modules/@spyglassmc/json/lib/parser/entry.js -var LegalNumberStart = /* @__PURE__ */ new Set(["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "-"]); -var entry = (src, ctx) => select([ - { predicate: (src2) => src2.tryPeek("["), parser: array }, - { predicate: (src2) => src2.tryPeek("false") || src2.tryPeek("true"), parser: boolean6 }, - { predicate: (src2) => src2.tryPeek("null"), parser: null_ }, - { predicate: (src2) => LegalNumberStart.has(src2.peek()), parser: number3 }, - { - predicate: (src2) => src2.tryPeek("{"), - parser: object - }, - { parser: string7 } -])(src, ctx); - -// node_modules/@spyglassmc/json/lib/parser/array.js -var array = (ctx, src) => setType("json:array", list({ start: "[", value: entry, sep: ",", trailingSep: false, end: "]" }))(ctx, src); - -// node_modules/@spyglassmc/json/lib/parser/file.js -var file5 = map(dumpErrors(entry), (res) => ({ type: "json:file", range: res.range, children: [res] })); - -// node_modules/@spyglassmc/json/lib/node/index.js -var JsonFileNode; -(function(JsonFileNode2) { - function is(obj) { - return obj?.type === "json:file"; - } - JsonFileNode2.is = is; -})(JsonFileNode || (JsonFileNode = {})); -var JsonNode; -(function(JsonNode2) { - function is(node) { - return JsonObjectNode.is(node) || JsonArrayNode.is(node) || JsonStringNode.is(node) || JsonNumberNode.is(node) || JsonBooleanNode.is(node) || JsonNullNode.is(node); - } - JsonNode2.is = is; -})(JsonNode || (JsonNode = {})); -var JsonObjectNode; -(function(JsonObjectNode2) { - function is(obj) { - return obj?.type === "json:object"; - } - JsonObjectNode2.is = is; - function mock(range3) { - return { type: "json:object", range: Range.get(range3), children: [] }; - } - JsonObjectNode2.mock = mock; -})(JsonObjectNode || (JsonObjectNode = {})); -var JsonPairNode; -(function(JsonPairNode2) { - function is(obj) { - return obj.type === "pair"; - } - JsonPairNode2.is = is; -})(JsonPairNode || (JsonPairNode = {})); -var JsonArrayNode; -(function(JsonArrayNode2) { - function is(obj) { - return obj?.type === "json:array"; - } - JsonArrayNode2.is = is; - function mock(range3) { - return { type: "json:array", range: Range.get(range3), children: [] }; - } - JsonArrayNode2.mock = mock; -})(JsonArrayNode || (JsonArrayNode = {})); -var JsonStringNode; -(function(JsonStringNode2) { - function is(obj) { - return obj?.type === "json:string"; - } - JsonStringNode2.is = is; - function mock(range3) { - return { ...StringNode.mock(range3, JsonStringOptions), type: "json:string" }; - } - JsonStringNode2.mock = mock; -})(JsonStringNode || (JsonStringNode = {})); -var JsonNumberNode; -(function(JsonNumberNode2) { - function is(obj) { - return obj.type === "json:number"; - } - JsonNumberNode2.is = is; -})(JsonNumberNode || (JsonNumberNode = {})); -var JsonBooleanNode; -(function(JsonBooleanNode2) { - function is(obj) { - return obj.type === "json:boolean"; - } - JsonBooleanNode2.is = is; -})(JsonBooleanNode || (JsonBooleanNode = {})); -var JsonNullNode; -(function(JsonNullNode2) { - function is(obj) { - return obj.type === "json:null"; - } - JsonNullNode2.is = is; -})(JsonNullNode || (JsonNullNode = {})); -var TypedJsonNode; -(function(TypedJsonNode2) { - function is(obj) { - return obj.type === "json:typed"; - } - TypedJsonNode2.is = is; -})(TypedJsonNode || (TypedJsonNode = {})); - -// node_modules/@spyglassmc/json/lib/checker/index.js -var typed = (node, ctx) => { - index(node.targetType)(node.children[0], ctx); -}; -function register(meta) { - meta.registerChecker("json:typed", typed); -} -function index(type2, options2) { - return (node, ctx) => { - runtime_exports.checker.typeDefinition([{ originalNode: node, inferredType: inferType(node) }], type2, runtime_exports.checker.McdocCheckerContext.create(ctx, { - tryConvertTo: (node2, target) => { - switch (node2.type) { - case "json:array": - switch (target.kind) { - case "list": - return { kind: "list", item: { kind: "any" } }; - case "byte_array": - case "int_array": - case "long_array": - return { kind: target.kind }; - case "tuple": - return { kind: "tuple", items: [] }; - } - break; - case "json:number": - const literalValue = LiteralNumericValue.makeIfValid(target.kind, node2.value.value, true, true); - if (literalValue !== void 0) { - return { kind: "literal", value: literalValue }; - } - } - return void 0; - }, - getChildren: (node2) => { - if (node2.type === "json:array") { - return node2.children.filter((n) => n.value).map((n) => [{ originalNode: n.value, inferredType: inferType(n.value) }]); - } - if (node2.type === "json:object") { - return node2.children.filter((kvp) => kvp.key).map((kvp) => ({ - key: { originalNode: kvp.key, inferredType: inferType(kvp.key) }, - possibleValues: kvp.value ? [{ originalNode: kvp.value, inferredType: inferType(kvp.value) }] : [] - })); - } - return []; - }, - reportError: (err) => { - if (err.kind === "duplicate_key" && options2?.discardDuplicateKeyErrors) { - return; - } - runtime_exports.checker.getDefaultErrorReporter(ctx, runtime_exports.checker.getDefaultErrorRange)(err); - }, - attachTypeInfo: (node2, definition, desc = "") => { - node2.typeDef = definition; - if (node2.parent && JsonPairNode?.is(node2.parent)) { - if (node2.parent.key?.typeDef && node2.parent.value?.typeDef) { - const valueString = McdocType.toString(node2.parent.value.typeDef); - let keyString = McdocType.toString(node2.parent.key.typeDef); - if (node2.parent.key.typeDef.kind !== "literal") { - keyString = `[${keyString}]`; - } - const hover = `\`\`\`typescript -${keyString}: ${valueString} -\`\`\` -${desc}`; - node2.parent.key.hover = hover; - if (node2.parent.value.type !== "json:array" && node2.parent.value.type !== "json:object") { - node2.parent.value.hover = `\`\`\`typescript -${valueString} -\`\`\` -${desc}`; - } - } - } else if (node2.type !== "json:array" && node2.type !== "json:object") { - node2.hover = `\`\`\`typescript -${McdocType.toString(definition)} -\`\`\` -${desc}`; - } - }, - nodeAttacher: (node2, attacher) => attacher(node2), - stringAttacher: (node2, attacher) => { - if (!JsonStringNode.is(node2)) { - return; - } - attacher(node2); - if (node2.children) { - AstNode.setParents(node2); - builtin_exports.fallbackSync(node2, ctx); - builtin_exports2.fallbackSync(node2, ctx); - } - } - })); - }; -} -function inferType(node) { - switch (node.type) { - case "json:boolean": - return { kind: "literal", value: { kind: "boolean", value: node.value } }; - case "json:number": - return { - kind: "literal", - value: { - kind: node.value.type, - value: node.value.value - } - }; - case "json:null": - return { kind: "any" }; - // null is always invalid? - case "json:string": - return { kind: "literal", value: { kind: "string", value: node.value } }; - case "json:array": - return { kind: "list", item: { kind: "any" } }; - case "json:object": - return { kind: "struct", fields: [] }; - } -} - -// node_modules/@spyglassmc/json/lib/colorizer/index.js -var boolean7 = (node) => { - return [ColorToken.create(node, "literal")]; -}; -var null_2 = (node) => { - return [ColorToken.create(node, "literal")]; -}; -var object2 = (node, ctx) => { - const ans = []; - for (const pair of node.children) { - if (pair.key) { - ans.push(ColorToken.create(pair.key, "property")); - } - if (pair.value) { - const colorizer = ctx.meta.getColorizer(pair.value.type); - ans.push(...colorizer(pair.value, ctx)); - } - } - return ans; -}; -var string8 = (node, ctx) => { - if (node.children && node.children?.length > 0) { - const child = node.children[0]; - const colorizer = ctx.meta.getColorizer(child.type); - return colorizer(child, ctx); - } - return builtin_exports4.string(node, ctx); -}; -function register2(meta) { - meta.registerColorizer("json:boolean", boolean7); - meta.registerColorizer("json:null", null_2); - meta.registerColorizer("json:number", builtin_exports4.number); - meta.registerColorizer("json:object", object2); - meta.registerColorizer("json:string", string8); -} - -// node_modules/@spyglassmc/json/lib/completer/index.js -var array2 = (node, ctx) => { - const index4 = binarySearch(node.children, ctx.offset, (n, o) => { - return Range.compareOffset(n.range, o, true); - }); - const item = index4 >= 0 ? node.children[index4] : void 0; - if (item?.value) { - return ctx.meta.getCompleter(item.value.type)(item.value, ctx); - } - if (node.typeDef?.kind === "list") { - const completions = getValues2(node.typeDef.item, ctx.offset, ctx); - if (ctx.offset < (node.children[node.children.length - 1]?.range.start ?? 0)) { - return completions.map((c) => ({ ...c, insertText: c.insertText + "," })); - } - return completions; - } - return []; -}; -var object3 = builtin_exports5.record({ - key: (record3, pair, ctx, range3, iv, ipe, exitingKeys) => { - if (!record3.typeDef) { - return []; - } - const keySet = new Set(exitingKeys.map((n) => n.value)); - return runtime_exports.completer.getFields(record3.typeDef, ctx).filter(({ key: key2 }) => !keySet.has(key2)).map(({ key: key2, field }) => CompletionItem.create(key2, pair?.key ?? range3, { - kind: 5, - detail: McdocType.toString(field.type), - documentation: field.desc, - deprecated: field.deprecated, - sortText: field.optional ? "$b" : "$a", - // sort above hardcoded $schema - filterText: `"${key2}"`, - insertText: `"${key2}"${iv ? ": " : ""}${ipe ? "$1," : ""}` - })); - }, - value: (record3, pair, ctx, range3) => { - if (pair.value) { - return ctx.meta.getCompleter(pair.value.type)(pair.value, ctx); - } - if (pair.key && record3.typeDef) { - const pairKey = pair.key.value; - const field = runtime_exports.completer.getFields(record3.typeDef, ctx).find(({ key: key2 }) => key2 === pairKey)?.field.type; - if (field) { - return getValues2(field, range3, ctx); - } - } - return []; - } -}); -var primitive = (node, ctx) => { - const insideRange = Range.contains(node, ctx.offset, true); - if (node.type === "json:string" && node.children?.length && insideRange) { - const childItems = builtin_exports5.string(node, ctx); - if (childItems.length > 0) { - return childItems; - } - } - if (!node.typeDef) { - return []; - } - return getValues2(node.typeDef, insideRange ? node : ctx.offset, ctx); -}; -function getValues2(typeDef, range3, ctx) { - return runtime_exports.completer.getValues(typeDef, ctx).map(({ value, labelSuffix, detail, documentation, kind, completionKind, insertText, sortText }) => CompletionItem.create(value, range3, { - kind: completionKind ?? 12, - labelSuffix, - detail, - documentation, - filterText: kind === "string" ? `"${value}"` : value, - insertText: kind === "string" ? `"${insertText ?? value}"` : insertText ?? value, - sortText - })); -} -function register3(meta) { - meta.registerCompleter("json:array", array2); - meta.registerCompleter("json:boolean", primitive); - meta.registerCompleter("json:number", primitive); - meta.registerCompleter("json:null", primitive); - meta.registerCompleter("json:object", object3); - meta.registerCompleter("json:string", primitive); -} - -// node_modules/@spyglassmc/json/lib/formatter/index.js -var file6 = (node, ctx) => { - const child = node.children[0]; - return ctx.meta.getFormatter(child.type)(child, ctx); -}; -var array3 = (node, ctx) => { - if (node.children.length === 0) { - return "[]"; - } - const values = node.children.map((child) => { - const value = child.value && ctx.meta.getFormatter(child.value.type)(child.value, indentFormatter(ctx)); - return `${ctx.indent(1)}${value ?? ""}`; - }); - return `[ -${values.join(",\n")} -${ctx.indent()}]`; -}; -var object4 = (node, ctx) => { - if (node.children.length === 0) { - return "{}"; - } - const fields = node.children.map((child) => { - const key2 = child.key && string9(child.key, ctx); - const value = child.value && ctx.meta.getFormatter(child.value.type)(child.value, indentFormatter(ctx)); - return `${ctx.indent(1)}${key2 ?? ""}: ${value ?? ""}`; - }); - return `{ -${fields.join(",\n")} -${ctx.indent()}}`; -}; -var number4 = (node, ctx) => { - return ctx.meta.getFormatter(node.value.type)(node.value, ctx); -}; -var string9 = (node, ctx) => { - return JSON.stringify(node.value); -}; -function register4(meta) { - meta.registerFormatter("json:file", file6); - meta.registerFormatter("json:array", array3); - meta.registerFormatter("json:boolean", builtin_exports6.boolean); - meta.registerFormatter("json:null", () => "null"); - meta.registerFormatter("json:number", number4); - meta.registerFormatter("json:object", object4); - meta.registerFormatter("json:string", string9); -} - -// node_modules/@spyglassmc/json/lib/index.js -function getInitializer(jsonUriPredicate) { - return ({ meta }) => { - meta.registerLanguage("json", { - extensions: [".json"], - uriPredicate: jsonUriPredicate, - triggerCharacters: ["\n", ":", '"'], - parser: file5 - }); - meta.registerLanguage("mcmeta", { - extensions: [".mcmeta"], - triggerCharacters: ["\n", ":", '"'], - parser: file5 - }); - meta.registerParser("json:entry", entry); - register(meta); - register2(meta); - register3(meta); - register4(meta); - }; -} - -// node_modules/@spyglassmc/nbt/lib/checker/index.js -var checker_exports4 = {}; -__export(checker_exports4, { - blockStates: () => blockStates, - index: () => index2, - path: () => path3, - register: () => register5, - typeDefinition: () => typeDefinition2, - typed: () => typed2 -}); - -// node_modules/@spyglassmc/nbt/lib/node/index.js -var NbtNode; -(function(NbtNode3) { - function is(node) { - return NbtPrimitiveNode.is(node) || NbtCompoundNode.is(node) || NbtCollectionNode.is(node); - } - NbtNode3.is = is; -})(NbtNode || (NbtNode = {})); -var NbtPrimitiveNode; -(function(NbtPrimitiveNode2) { - function is(node) { - return NbtNumberNode.is(node) || NbtStringNode.is(node); - } - NbtPrimitiveNode2.is = is; -})(NbtPrimitiveNode || (NbtPrimitiveNode = {})); -var NbtStringNode; -(function(NbtStringNode2) { - function is(obj) { - return obj?.type === "nbt:string"; - } - NbtStringNode2.is = is; -})(NbtStringNode || (NbtStringNode = {})); -var NbtNumberNode; -(function(NbtNumberNode2) { - function is(node) { - return NbtIntegerAlikeNode.is(node) || NbtFloatAlikeNode.is(node); - } - NbtNumberNode2.is = is; -})(NbtNumberNode || (NbtNumberNode = {})); -var NbtIntegerAlikeNode; -(function(NbtIntegerAlikeNode2) { - function is(node) { - return NbtByteNode.is(node) || NbtShortNode.is(node) || NbtIntNode.is(node) || NbtLongNode.is(node); - } - NbtIntegerAlikeNode2.is = is; -})(NbtIntegerAlikeNode || (NbtIntegerAlikeNode = {})); -var NbtByteNode; -(function(NbtByteNode2) { - function is(node) { - return node?.type === "nbt:byte"; - } - NbtByteNode2.is = is; -})(NbtByteNode || (NbtByteNode = {})); -var NbtShortNode; -(function(NbtShortNode2) { - function is(node) { - return node?.type === "nbt:short"; - } - NbtShortNode2.is = is; -})(NbtShortNode || (NbtShortNode = {})); -var NbtIntNode; -(function(NbtIntNode2) { - function is(node) { - return node?.type === "nbt:int"; - } - NbtIntNode2.is = is; -})(NbtIntNode || (NbtIntNode = {})); -var NbtLongNode; -(function(NbtLongNode2) { - function is(node) { - return node?.type === "nbt:long"; - } - NbtLongNode2.is = is; -})(NbtLongNode || (NbtLongNode = {})); -var NbtFloatAlikeNode; -(function(NbtFloatAlikeNode2) { - function is(node) { - return NbtFloatNode.is(node) || NbtDoubleNode.is(node); - } - NbtFloatAlikeNode2.is = is; -})(NbtFloatAlikeNode || (NbtFloatAlikeNode = {})); -var NbtFloatNode; -(function(NbtFloatNode2) { - function is(node) { - return node?.type === "nbt:float"; - } - NbtFloatNode2.is = is; -})(NbtFloatNode || (NbtFloatNode = {})); -var NbtDoubleNode; -(function(NbtDoubleNode2) { - function is(node) { - return node?.type === "nbt:double"; - } - NbtDoubleNode2.is = is; -})(NbtDoubleNode || (NbtDoubleNode = {})); -var NbtCompoundNode; -(function(NbtCompoundNode2) { - function is(node) { - return node?.type === "nbt:compound"; - } - NbtCompoundNode2.is = is; -})(NbtCompoundNode || (NbtCompoundNode = {})); -var NbtCollectionNode; -(function(NbtCollectionNode2) { - function is(node) { - return NbtListNode.is(node) || NbtPrimitiveArrayNode.is(node); - } - NbtCollectionNode2.is = is; -})(NbtCollectionNode || (NbtCollectionNode = {})); -var NbtListNode; -(function(NbtListNode2) { - function is(node) { - return node?.type === "nbt:list"; - } - NbtListNode2.is = is; -})(NbtListNode || (NbtListNode = {})); -var NbtPrimitiveArrayNode; -(function(NbtPrimitiveArrayNode2) { - function is(node) { - return NbtByteArrayNode.is(node) || NbtIntArrayNode.is(node) || NbtLongArrayNode.is(node); - } - NbtPrimitiveArrayNode2.is = is; -})(NbtPrimitiveArrayNode || (NbtPrimitiveArrayNode = {})); -var NbtByteArrayNode; -(function(NbtByteArrayNode2) { - function is(node) { - return node?.type === "nbt:byte_array"; - } - NbtByteArrayNode2.is = is; -})(NbtByteArrayNode || (NbtByteArrayNode = {})); -var NbtIntArrayNode; -(function(NbtIntArrayNode2) { - function is(node) { - return node?.type === "nbt:int_array"; - } - NbtIntArrayNode2.is = is; -})(NbtIntArrayNode || (NbtIntArrayNode = {})); -var NbtLongArrayNode; -(function(NbtLongArrayNode2) { - function is(node) { - return node?.type === "nbt:long_array"; - } - NbtLongArrayNode2.is = is; -})(NbtLongArrayNode || (NbtLongArrayNode = {})); -var NbtPathNode; -(function(NbtPathNode3) { - function is(node) { - return node?.type === "nbt:path"; - } - NbtPathNode3.is = is; -})(NbtPathNode || (NbtPathNode = {})); -var NbtPathKeyNode; -(function(NbtPathKeyNode2) { - function is(node) { - return node?.type === "nbt:path/key"; - } - NbtPathKeyNode2.is = is; -})(NbtPathKeyNode || (NbtPathKeyNode = {})); -var NbtPathFilterNode; -(function(NbtPathFilterNode2) { - function is(node) { - return node?.type === "nbt:path/filter"; - } - NbtPathFilterNode2.is = is; -})(NbtPathFilterNode || (NbtPathFilterNode = {})); -var NbtPathIndexNode; -(function(NbtPathIndexNode2) { - function is(node) { - return node?.type === "nbt:path/index"; - } - NbtPathIndexNode2.is = is; -})(NbtPathIndexNode || (NbtPathIndexNode = {})); -var TypedNbtNode; -(function(TypedNbtNode2) { - function is(node) { - return node?.type === "nbt:typed"; - } - TypedNbtNode2.is = is; -})(TypedNbtNode || (TypedNbtNode = {})); - -// node_modules/@spyglassmc/nbt/lib/checker/mcdocUtil.js -var BlockItems = { - // Coral fans. - "minecraft:brain_coral_fan": ["minecraft:brain_coral_fan", "minecraft:brain_coral_wall_fan"], - "minecraft:bubble_coral_fan": ["minecraft:bubble_coral_fan", "minecraft:bubble_coral_wall_fan"], - "minecraft:fire_coral_fan": ["minecraft:fire_coral_fan", "minecraft:fire_coral_wall_fan"], - "minecraft:horn_coral_fan": ["minecraft:horn_coral_fan", "minecraft:horn_coral_wall_fan"], - "minecraft:tube_coral_fan": ["minecraft:tube_coral_fan", "minecraft:tube_coral_wall_fan"], - // Heads and skulls. - "minecraft:creeper_head": ["minecraft:creeper_head", "minecraft:creeper_wall_head"], - "minecraft:dragon_head": ["minecraft:dragon_head", "minecraft:dragon_wall_head"], - "minecraft:player_head": ["minecraft:player_head", "minecraft:player_wall_head"], - "minecraft:skeleton_skull": ["minecraft:skeleton_skull", "minecraft:skeleton_wall_skull"], - "minecraft:wither_skeleton_skull": [ - "minecraft:wither_skeleton_skull", - "minecraft:wither_skeleton_wall_skull" - ], - // Dead coral fans. - "minecraft:dead_brain_coral_fan": [ - "minecraft:dead_brain_coral_fan", - "minecraft:dead_brain_coral_wall_fan" - ], - "minecraft:dead_bubble_coral_fan": [ - "minecraft:dead_bubble_coral_fan", - "minecraft:dead_bubble_coral_wall_fan" - ], - "minecraft:dead_fire_coral_fan": [ - "minecraft:dead_fire_coral_fan", - "minecraft:dead_fire_coral_wall_fan" - ], - "minecraft:dead_horn_coral_fan": [ - "minecraft:dead_horn_coral_fan", - "minecraft:dead_horn_coral_wall_fan" - ], - "minecraft:dead_tube_coral_fan": [ - "minecraft:dead_tube_coral_fan", - "minecraft:dead_tube_coral_wall_fan" - ], - // Torches. - "minecraft:torch": ["minecraft:torch", "minecraft:wall_torch"], - "minecraft:soul_torch": ["minecraft:soul_torch", "minecraft:soul_wall_torch"], - "minecraft:redstone_torch": ["minecraft:redstone_torch", "minecraft:redstone_wall_torch"], - "minecraft:beetroot_seeds": ["minecraft:beetroots"], - "minecraft:carrot": ["minecraft:carrots"], - "minecraft:cocoa_beans": ["minecraft:cocoa"], - "minecraft:glow_berries": ["minecraft:cave_vines"], - "minecraft:melon_seeds": ["minecraft:melon_stem"], - "minecraft:potato": ["minecraft:potatoes"], - "minecraft:pumpkin_seeds": ["minecraft:pumpkin_stem"], - "minecraft:redstone": ["minecraft:redstone_wire"], - "minecraft:string": ["minecraft:tripwire"], - "minecraft:sweat_berries": ["minecraft:sweat_berry_bush"], - "minecraft:wheat_seeds": ["minecraft:wheat"] -}; -function getBlocksFromItem(item) { - return BlockItems[item]; -} -function getEntityFromItem(item) { - if (item === "minecraft:armor_stand") { - return item; - } - const result = item.match(/^minecraft:([a-z0-9_]+)_spawn_egg$/); - if (result) { - return `minecraft:${result[1]}`; - } - return void 0; -} - -// node_modules/@spyglassmc/nbt/lib/checker/index.js -var typed2 = (node, ctx) => { - typeDefinition2(node.targetType)(node.children[0], ctx); -}; -function register5(meta) { - meta.registerChecker("nbt:typed", typed2); -} -function index2(registry, id, options2 = {}) { - switch (registry) { - case "custom:blockitemstates": - const blockIds = getBlocksFromItem(id); - return blockIds ? blockStates(blockIds, options2) : builtin_exports2.noop; - case "custom:blockstates": - return blockStates([id], options2); - case "custom:spawnitemtag": - const entityId = getEntityFromItem(id); - return entityId ? index2("minecraft:entity", entityId, options2) : builtin_exports2.noop; - default: - const typeDef = { - kind: "dispatcher", - registry, - parallelIndices: getIndices(id) - }; - return (node, ctx) => { - typeDefinition2(typeDef, options2)(node, ctx); - }; - } -} -function getIndices(id) { - if (typeof id === "string") { - return [{ kind: "static", value: id }]; - } else if (id === void 0 || id.length === 0) { - return [{ kind: "static", value: "%fallback" }]; - } else { - return id.map((i) => ({ kind: "static", value: i })); - } -} -function typeDefinition2(typeDef, options2 = {}) { - return (node, ctx) => { - runtime_exports.checker.typeDefinition([{ originalNode: node, inferredType: inferType2(node) }], typeDef, runtime_exports.checker.McdocCheckerContext.create(ctx, { - allowMissingKeys: options2.isPredicate || options2.isMerge, - requireCanonical: options2.isPredicate, - tryConvertTo: (node2, target) => { - if (target.kind === "boolean" && NbtByteNode.is(node2)) { - if (node2.value === 0) { - return { kind: "literal", value: { kind: "boolean", value: false } }; - } else if (node2.value === 1) { - return { kind: "literal", value: { kind: "boolean", value: true } }; - } - } - if (target.kind === "tuple" && NbtListNode.is(node2)) { - return { - kind: "tuple", - items: [] - }; - } - if (!options2.isPredicate) { - if (NbtNumberNode.is(node2)) { - const literalValue = LiteralNumericValue.makeIfValid(target.kind, node2.value, NbtIntegerAlikeNode.is(node2), true); - if (literalValue !== void 0) { - return { kind: "literal", value: literalValue }; - } - } - if (NbtCollectionNode.is(node2)) { - switch (target.kind) { - case "list": - return { kind: "list", item: { kind: "any" } }; - case "byte_array": - case "int_array": - case "long_array": - return { kind: target.kind }; - case "tuple": - return { kind: "tuple", items: [] }; - } - } - } - return void 0; - }, - getChildren: (node2) => { - const { type: type2 } = node2; - if (type2 === "nbt:list" || type2 === "nbt:byte_array" || type2 === "nbt:int_array" || type2 === "nbt:long_array") { - return node2.children.filter((n) => n.value).map((n) => [{ originalNode: n.value, inferredType: inferType2(n.value) }]); - } - if (type2 === "nbt:compound") { - return node2.children.filter((kvp) => kvp.key).map((kvp) => ({ - key: { originalNode: kvp.key, inferredType: inferType2(kvp.key) }, - possibleValues: kvp.value ? [{ originalNode: kvp.value, inferredType: inferType2(kvp.value) }] : [] - })); - } - return []; - }, - reportError: (error4) => { - if (options2.isPredicate && error4.kind === "invalid_collection_length") { - return; - } - runtime_exports.checker.getDefaultErrorReporter(ctx, runtime_exports.checker.getDefaultErrorRange)(error4); - }, - attachTypeInfo: (node2, definition, desc = "") => { - node2.typeDef = definition; - node2.requireCanonical = options2.isPredicate; - if (node2.parent && PairNode?.is(node2.parent) && NbtNode.is(node2.parent.key) && NbtNode.is(node2.parent.value)) { - if (node2.parent.key?.typeDef && node2.parent.value?.typeDef) { - const valueString = McdocType.toString(node2.parent.value.typeDef); - let keyString = McdocType.toString(node2.parent.key.typeDef); - if (node2.parent.key.typeDef.kind !== "literal") { - keyString = `[${keyString}]`; - } - node2.parent.key.hover = `\`\`\`typescript -${keyString}: ${valueString} -\`\`\` -${desc}`; - if (NbtPrimitiveNode.is(node2.parent.value)) { - node2.parent.value.hover = `\`\`\`typescript -${valueString} -\`\`\` -${desc}`; - } - } - } else if (NbtPrimitiveNode.is(node2)) { - node2.hover = `\`\`\`typescript -${McdocType.toString(definition)} -\`\`\` -${desc}`; - } - }, - nodeAttacher: (node2, attacher) => attacher(node2), - stringAttacher: (node2, attacher) => { - if (!NbtStringNode.is(node2)) { - return; - } - attacher(node2); - if (node2.children) { - AstNode.setParents(node2); - builtin_exports.fallbackSync(node2, ctx); - builtin_exports2.fallbackSync(node2, ctx); - } - } - })); - }; -} -function inferType2(node) { - switch (node.type) { - case "nbt:byte": - return { kind: "literal", value: { kind: "byte", value: node.value } }; - case "nbt:double": - return { kind: "literal", value: { kind: "double", value: node.value } }; - case "nbt:float": - return { kind: "literal", value: { kind: "float", value: node.value } }; - case "nbt:long": - return { kind: "literal", value: { kind: "long", value: node.value } }; - case "nbt:int": - return { kind: "literal", value: { kind: "int", value: node.value } }; - case "nbt:short": - return { kind: "literal", value: { kind: "short", value: node.value } }; - case "nbt:string": - return { kind: "literal", value: { kind: "string", value: node.value } }; - case "nbt:list": - return { kind: "list", item: { kind: "any" } }; - case "nbt:compound": - return { kind: "struct", fields: [] }; - case "nbt:byte_array": - return { kind: "byte_array" }; - case "nbt:long_array": - return { kind: "long_array" }; - case "nbt:int_array": - return { kind: "int_array" }; - } -} -function blockStates(blocks, _options = {}) { - return (node, ctx) => { - if (!NbtCompoundNode.is(node)) { - return; - } - const states = getStates("block", blocks, ctx); - for (const { key: keyNode, value: valueNode } of node.children) { - if (!keyNode || !valueNode) { - continue; - } - if (valueNode.type === "nbt:byte" && (ctx.src.slice(valueNode.range).toLowerCase() === "false" || ctx.src.slice(valueNode.range).toLowerCase() === "true")) { - ctx.err.report(localize("nbt.checker.block-states.fake-boolean"), valueNode, ErrorSeverity.Warning); - continue; - } else if (valueNode.type !== "nbt:string" && valueNode.type !== "nbt:int") { - ctx.err.report(localize("nbt.checker.block-states.unexpected-value-type"), valueNode, ErrorSeverity.Warning); - continue; - } - if (Object.keys(states).includes(keyNode.value)) { - const stateValues = states[keyNode.value]; - if (!stateValues.includes(valueNode.value.toString())) { - ctx.err.report(localize("expected-got", stateValues, localeQuote(valueNode.value.toString())), valueNode, ErrorSeverity.Warning); - } - } else { - ctx.err.report(localize("nbt.checker.block-states.unknown-state", localeQuote(keyNode.value), blocks), keyNode, ErrorSeverity.Warning); - } - } - }; -} -function path3(registry, id) { - return (node, ctx) => { - const typeDef = { - kind: "dispatcher", - registry, - parallelIndices: getIndices(id) - }; - const leaf = { type: "leaf", range: Range.create(node.range.end) }; - let link = { path: node, node: leaf }; - for (let i = node.children.length - 1; i >= 0; i -= 1) { - link = { path: node, node: node.children[i], next: link }; - } - let prev = link; - while (prev.next) { - prev.next.prev = prev; - prev = prev.next; - } - runtime_exports.checker.typeDefinition([{ originalNode: link, inferredType: inferPath(link) }], typeDef, runtime_exports.checker.McdocCheckerContext.create(ctx, { - allowMissingKeys: true, - requireCanonical: true, - tryConvertTo: (node2, target) => { - if (NbtPathIndexNode.is(node2.node)) { - switch (target.kind) { - case "list": - return { kind: "list", item: { kind: "any" } }; - case "byte_array": - case "int_array": - case "long_array": - return { kind: target.kind }; - case "tuple": - return { kind: "tuple", items: [] }; - } - } - return void 0; - }, - getChildren: (link2) => { - while (link2.next && link2.node.type !== "leaf" && NbtPathFilterNode.is(link2.node)) { - link2 = link2.next; - } - if (!link2.next || link2.node.type === "leaf") { - return []; - } - if (NbtPathIndexNode.is(link2.node)) { - return [[{ originalNode: link2.next, inferredType: inferPath(link2.next) }]]; - } - if (NbtPathKeyNode.is(link2.node)) { - return [{ - key: { - originalNode: link2, - inferredType: { - kind: "literal", - value: { kind: "string", value: link2.node.children[0].value } - } - }, - possibleValues: [{ - originalNode: link2.next, - inferredType: inferPath(link2.next) - }] - }]; - } - return []; - }, - reportError: (error4) => { - if (error4.kind === "invalid_collection_length") { - return; - } - runtime_exports.checker.getDefaultErrorReporter(ctx, ({ originalNode: link2 }) => link2.node.range)(error4); - }, - attachTypeInfo: (link2, definition, desc = "") => { - if (definition.kind === "literal" && !definition.attributes?.length) { - return; - } - if (link2.node.type === "leaf") { - link2.path.endTypeDef = definition; - } else { - link2.node.typeDef = definition; - } - if (NbtPathKeyNode.is(link2.prev?.node)) { - link2.prev.node.hover = `\`\`\`typescript -${link2.prev.node.children[0].value}: ${McdocType.toString(definition)} -\`\`\` -${desc}`; - } - }, - nodeAttacher: (link2, attacher) => { - if (link2.node.type !== "leaf") { - attacher(link2.node); - } - }, - stringAttacher: (link2, attacher) => { - if (!NbtPathKeyNode.is(link2.node)) { - return; - } - attacher(link2.node.children[0]); - if (link2.node.children[0].children) { - AstNode.setParents(link2.node.children[0]); - builtin_exports.fallbackSync(link2.node.children[0], ctx); - builtin_exports2.fallbackSync(link2.node.children[0], ctx); - } - } - })); - }; -} -function inferPath(link) { - if (link.node.type === "leaf") { - return { kind: "unsafe" }; - } - if (NbtPathIndexNode.is(link.node)) { - return { kind: "list", item: { kind: "any" } }; - } - return { kind: "struct", fields: [] }; -} - -// node_modules/@spyglassmc/nbt/lib/colorizer/index.js -function register6(meta) { - meta.registerColorizer("nbt:string", builtin_exports4.string); - meta.registerColorizer("nbt:byte", builtin_exports4.number); - meta.registerColorizer("nbt:short", builtin_exports4.number); - meta.registerColorizer("nbt:int", builtin_exports4.number); - meta.registerColorizer("nbt:long", builtin_exports4.number); - meta.registerColorizer("nbt:float", builtin_exports4.number); - meta.registerColorizer("nbt:double", builtin_exports4.number); -} - -// node_modules/@spyglassmc/nbt/lib/completer/index.js -var collection = (node, ctx) => { - const index4 = binarySearch(node.children, ctx.offset, (n, o) => { - return Range.compareOffset(n.range, o, true); - }); - const item = index4 >= 0 ? node.children[index4] : void 0; - if (item?.value) { - return ctx.meta.getCompleter(item.value.type)(item.value, ctx); - } - if (node.typeDef?.kind === "list") { - const completions = getValues3(node.typeDef.item, ctx.offset, { - ...ctx, - requireCanonical: node.requireCanonical - }); - if (ctx.offset < (node.children[node.children.length - 1]?.range.start ?? 0)) { - return completions.map((c) => ({ ...c, insertText: c.insertText + "," })); - } - return completions; - } - return []; -}; -var compound = builtin_exports5.record({ - key: (record3, pair, ctx, range3, iv, ipe, exitingKeys) => { - if (!record3.typeDef) { - return []; - } - const keySet = new Set(exitingKeys.map((n) => n.value)); - return runtime_exports.completer.getFields(record3.typeDef, { ...ctx, requireCanonical: record3.requireCanonical }).filter(({ key: key2 }) => !keySet.has(key2)).map(({ key: key2, field }) => CompletionItem.create(key2, pair?.key ?? range3, { - kind: 5, - detail: McdocType.toString(field.type), - documentation: field.desc, - deprecated: field.deprecated, - sortText: field.optional ? "$b" : "$a", - // sort above hardcoded $schema - filterText: formatKey(key2, pair?.key?.quote), - insertText: `${formatKey(key2, pair?.key?.quote)}${iv ? ":" : ""}${ipe ? "$1," : ""}` - })); - }, - value: (record3, pair, ctx, range3) => { - if (pair.value) { - return ctx.meta.getCompleter(pair.value.type)(pair.value, ctx); - } - if (pair.key && record3.typeDef) { - const pairKey = pair.key.value; - const field = runtime_exports.completer.getFields(record3.typeDef, ctx).find(({ key: key2 }) => key2 === pairKey)?.field.type; - if (field) { - return getValues3(field, range3, { - ...ctx, - requireCanonical: record3.requireCanonical - }); - } - } - return []; - } -}); -var primitive2 = (node, ctx) => { - const insideRange = Range.contains(node, ctx.offset, true); - if (node.type === "nbt:string" && node.children?.length && insideRange) { - const childItems = builtin_exports5.string(node, ctx); - if (childItems.length > 0) { - return childItems; - } - } - if (!node.typeDef) { - return []; - } - return getValues3(node.typeDef, insideRange ? node : ctx.offset, { - ...ctx, - requireCanonical: node.requireCanonical - }); -}; -var path4 = (node, ctx) => { - const index4 = binarySearch(node.children, ctx.offset, (n, o) => { - return Range.compareOffset(n.range, o, true); - }); - const item = index4 >= 0 ? node.children[index4] : void 0; - if (item) { - return ctx.meta.getCompleter(item.type)(item, ctx); - } - if (!node.endTypeDef) { - return []; - } - return getPathKeys(node.endTypeDef, ctx.offset, void 0, ctx); -}; -var pathKey = (node, ctx) => { - if (!node.typeDef) { - return []; - } - const child = node.children[0]; - if (child.children?.length) { - return builtin_exports5.dispatch(child.children[0], ctx); - } - return getPathKeys(node.typeDef, node, child.quote, ctx); -}; -function getPathKeys(typeDef, range3, quote2, ctx) { - return runtime_exports.completer.getFields(typeDef, { ...ctx, requireCanonical: true }).map(({ key: key2, field }) => CompletionItem.create(key2, range3, { - kind: 5, - detail: McdocType.toString(field.type), - documentation: field.desc, - deprecated: field.deprecated, - sortText: field.optional ? "$b" : "$a", - // sort above hardcoded $schema - filterText: formatKey(key2, quote2), - insertText: formatKey(key2, quote2) - })); -} -function getValues3(typeDef, range3, ctx) { - return runtime_exports.completer.getValues(typeDef, ctx).map(({ value, labelSuffix, detail, documentation, kind, completionKind, insertText, sortText }) => CompletionItem.create(value, range3, { - kind: completionKind ?? 12, - labelSuffix, - detail, - documentation, - filterText: formatValue(value, kind), - insertText: formatValue(insertText ?? value, kind), - sortText - })); -} -function formatKey(key2, quote2) { - if (!quote2 && BrigadierUnquotablePattern.test(key2)) { - return key2; - } - const q = quote2 ?? '"'; - return q + builtin_exports5.escapeString(key2, q) + q; -} -function formatValue(value, kind) { - switch (kind) { - case "string": - return `"${builtin_exports5.escapeString(value, '"')}"`; - case "byte": - return `${value}b`; - case "short": - return `${value}s`; - case "long": - return `${value}L`; - case "float": - return `${value}f`; - default: - return value; - } -} -function register7(meta) { - meta.registerCompleter("nbt:byte", primitive2); - meta.registerCompleter("nbt:byte_array", collection); - meta.registerCompleter("nbt:compound", compound); - meta.registerCompleter("nbt:double", primitive2); - meta.registerCompleter("nbt:int", primitive2); - meta.registerCompleter("nbt:int_array", collection); - meta.registerCompleter("nbt:list", collection); - meta.registerCompleter("nbt:long", primitive2); - meta.registerCompleter("nbt:long_array", collection); - meta.registerCompleter("nbt:string", primitive2); - meta.registerCompleter("nbt:short", primitive2); - meta.registerCompleter("nbt:float", primitive2); - meta.registerCompleter("nbt:path", path4); - meta.registerCompleter("nbt:path/key", pathKey); -} - -// node_modules/@spyglassmc/nbt/lib/util.js -function localizeTag(type2) { - return localize(`nbt.node.${type2.replace(/^nbt:/, "")}`); -} -function newSyntax(ctx) { - const release = ctx.project["loadedVersion"]; - if (!release) { - return true; - } - const [majorA, minorA, patchA = 0] = release.split("."); - const [majorB, minorB, patchB = 0] = "1.21.5".split("."); - if (majorA !== majorB) { - return Number(majorA) >= Number(majorB); - } - if (minorA !== minorB) { - return Number(minorA) >= Number(minorB); - } - return Number(patchA) >= Number(patchB); -} - -// node_modules/@spyglassmc/nbt/lib/parser/primitive.js -var FloatMaximum = (2 - 2 ** -23) * 2 ** 127; -var NumeralPatterns = [ - { - pattern: /^[-+]?(?:0|[1-9][0-9]*)b$/i, - type: "nbt:byte", - hasSuffix: true, - group: 2, - min: -128, - max: 127 - }, - { - pattern: /^[-+]?(?:0|[1-9][0-9]*)s$/i, - type: "nbt:short", - hasSuffix: true, - group: 2, - min: -32768, - max: 32767 - }, - { - pattern: /^[-+]?(?:0|[1-9][0-9]*)$/, - type: "nbt:int", - hasSuffix: false, - group: 2, - min: -2147483648, - max: 2147483647 - }, - { - pattern: /^[-+]?(?:0|[1-9][0-9]*)l$/i, - type: "nbt:long", - hasSuffix: true, - group: 3, - min: -9223372036854775808n, - max: 9223372036854775807n - }, - { - pattern: /^[-+]?(?:[0-9]+\.?|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?f$/i, - type: "nbt:float", - hasSuffix: true, - group: 1, - min: -FloatMaximum, - max: FloatMaximum - }, - { - pattern: /^[-+]?(?:[0-9]+\.|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?$/i, - type: "nbt:double", - hasSuffix: false, - group: 1, - min: -Number.MAX_VALUE, - max: Number.MAX_VALUE - }, - { - pattern: /^[-+]?(?:[0-9]+\.?|[0-9]*\.[0-9]+)(?:e[-+]?[0-9]+)?d$/i, - type: "nbt:double", - hasSuffix: true, - group: 1, - min: -Number.MAX_VALUE, - max: Number.MAX_VALUE - }, - { - pattern: /^true$/i, - type: "nbt:byte", - value: 1, - group: 0 - /* Group.Boolean */ - }, - { - pattern: /^false$/i, - type: "nbt:byte", - value: 0, - group: 0 - /* Group.Boolean */ - } -]; -var NbtStringOptions = { - escapable: { characters: ["b", "f", "n", "r", "s", "t"], unicode: true }, - quotes: ['"', "'"], - unquotable: BrigadierUnquotableOption -}; -var string10 = (src, ctx) => { - const options2 = newSyntax(ctx) ? NbtStringOptions : BrigadierStringOptions; - return setType("nbt:string", string4(options2))(src, ctx); -}; -var primitive3 = (src, ctx) => { - if (Source.isBrigadierQuote(src.peek())) { - return string10(src, ctx); - } - const { result: unquotedResult, updateSrcAndCtx: updateUnquoted } = attempt3(string10, src, ctx); - for (const e of NumeralPatterns) { - if (e.pattern.test(unquotedResult.value)) { - if (e.group === 0) { - const ans = { - type: "nbt:byte", - range: unquotedResult.range, - value: e.value - }; - updateUnquoted(); - return ans; - } - let isOutOfRange = false; - const onOutOfRange = () => isOutOfRange = true; - const numeralParser = e.group === 2 ? integer2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }) : e.group === 3 ? long2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }) : float2({ pattern: /./, min: e.min, max: e.max, onOutOfRange }); - const { result: numeralResult, updateSrcAndCtx: updateNumeral } = attempt3(numeralParser, src, ctx); - if (isOutOfRange) { - ctx.err.report(localize("nbt.parser.number.out-of-range", localizeTag(e.type), localize("nbt.node.string"), e.min, e.max), unquotedResult, ErrorSeverity.Warning); - break; - } - updateNumeral(); - if (e.hasSuffix) { - src.skip(); - numeralResult.range.end++; - } - return { ...numeralResult, type: e.type }; - } - } - updateUnquoted(); - return unquotedResult; -}; - -// node_modules/@spyglassmc/nbt/lib/parser/collection.js -var list3 = (src, ctx) => { - const parser = list({ - start: "[", - value: entry2, - sep: ",", - trailingSep: true, - end: "]" - }); - const ans = parser(src, ctx); - ans.type = "nbt:list"; - ans.valueType = ans.children[0]?.value?.type; - if (ans.valueType && !newSyntax(ctx)) { - for (const { value } of ans.children) { - if (value && value.type !== ans.valueType) { - ctx.err.report(localize("expected-got", localizeTag(ans.valueType), localizeTag(value.type)), value); - } - } - } - return ans; -}; -var byteArray = (src, ctx) => { - const parser = list({ - start: "[B;", - value: primitive3, - sep: ",", - trailingSep: true, - end: "]" - }); - const ans = parser(src, ctx); - ans.type = "nbt:byte_array"; - for (const { value } of ans.children) { - if (value && value.type !== "nbt:byte") { - ctx.err.report(localize("expected-got", localize("nbt.node.byte"), localizeTag(value.type)), value); - } - } - return ans; -}; -var intArray = (src, ctx) => { - const parser = list({ - start: "[I;", - value: primitive3, - sep: ",", - trailingSep: true, - end: "]" - }); - const ans = parser(src, ctx); - ans.type = "nbt:int_array"; - for (const { value } of ans.children) { - if (value && value.type !== "nbt:int") { - ctx.err.report(localize("expected-got", localize("nbt.node.int"), localizeTag(value.type)), value); - } - } - return ans; -}; -var longArray = (src, ctx) => { - const parser = list({ - start: "[L;", - value: primitive3, - sep: ",", - trailingSep: true, - end: "]" - }); - const ans = parser(src, ctx); - ans.type = "nbt:long_array"; - for (const { value } of ans.children) { - if (value && value.type !== "nbt:long") { - ctx.err.report(localize("expected-got", localize("nbt.node.long"), localizeTag(value.type)), value); - } - } - return ans; -}; - -// node_modules/@spyglassmc/nbt/lib/parser/compound.js -var compound2 = (src, ctx) => { - return setType("nbt:compound", record2({ - start: "{", - pair: { - key: failOnEmpty(setType("nbt:string", string4({ ...BrigadierStringOptions, colorTokenType: "property" }))), - sep: ":", - value: entry2, - end: ",", - trailingEnd: true - }, - end: "}" - }))(src, ctx); -}; - -// node_modules/@spyglassmc/nbt/lib/parser/entry.js -var entry2 = (src, ctx) => failOnEmpty(select([ - { predicate: (src2) => src2.tryPeek("[B;"), parser: byteArray }, - { - predicate: (src2) => src2.tryPeek("[I;"), - parser: intArray - }, - { predicate: (src2) => src2.tryPeek("[L;"), parser: longArray }, - { predicate: (src2) => src2.tryPeek("["), parser: list3 }, - { predicate: (src2) => src2.tryPeek("{"), parser: compound2 }, - { parser: primitive3 } -]))(src, ctx); - -// node_modules/@spyglassmc/nbt/lib/parser/path.js -var path5 = (src, ctx) => { - const ans = { type: "nbt:path", children: [], range: Range.create(src) }; - let expectedParts = ["filter", "key"]; - let currentPart = nextPart(src); - let cursor; - while (cursor !== src.cursor) { - if (!expectedParts.includes(currentPart)) { - ctx.err.report(localize("expected-got", arrayToMessage(expectedParts.map(localizePart), false, "or"), localizePart(currentPart)), src); - } - if (currentPart === "end") { - break; - } - cursor = src.cursor; - expectedParts = PartParsers[currentPart](ans.children, src, ctx); - currentPart = nextPart(src); - } - ans.range.end = src.cursor; - return ans; -}; -var filter = (children, src, ctx) => { - const node = compound2(src, ctx); - children.push({ - type: "nbt:path/filter", - range: node.range, - children: [node] - }); - return src.trySkip(".") ? ["key"] : ["end"]; -}; -var index3 = (children, src, ctx) => { - const node = { - type: "nbt:path/index", - children: void 0, - range: Range.create(src) - }; - if (!src.trySkip("[")) { - throw new Error(`NBT path index parser called at illegal position: \u201C${src.peek()}\u201D at ${src.cursor}`); - } - const c = src.peek(); - if (c === "{") { - node.children = [compound2(src, ctx)]; - } else if (c !== "]") { - node.children = [integer2({ pattern: /^-?\d+$/ })(src, ctx)]; - } - if (!src.trySkip("]")) { - ctx.err.report(localize("expected-got", localeQuote("]"), localeQuote(src.peek())), src); - } - node.range.end = src.cursor; - children.push(node); - return src.trySkip(".") ? ["index", "key"] : ["end", "index"]; -}; -var key = (children, src, ctx) => { - const node = setType("nbt:string", string4({ - colorTokenType: "property", - escapable: {}, - // Single quotes supported since 1.20 Pre-release 2 (roughly pack format 15) - // https://bugs.mojang.com/browse/MC-175504 - quotes: ['"', "'"], - unquotable: { blockList: /* @__PURE__ */ new Set(["\n", "\r", " ", " ", '"', "[", "]", ".", "{", "}"]) } - }))(src, ctx); - children.push({ - type: "nbt:path/key", - range: node.range, - children: [node] - }); - return src.trySkip(".") ? ["index", "key"] : ["end", "filter", "index"]; -}; -function nextPart(src) { - switch (src.peek()) { - case "": - case " ": - case "\n": - case "\r": - return "end"; - case "{": - return "filter"; - case "[": - return "index"; - default: - return "key"; - } -} -function localizePart(part) { - return localize(`nbt.node.path.${part}`); -} -var PartParsers = { filter, index: index3, key }; - -// node_modules/@spyglassmc/nbt/lib/mcdocAttributes.js -var nbtValidator = (value) => { - if (!value || value?.kind === "tree") { - return Failure; - } - return value; -}; -function registerMcdocAttributes(meta) { - runtime_exports.registerAttribute(meta, "nbt", nbtValidator, { - stringParser: (config) => makeInfallible(map(entry2, (res) => ({ - type: "nbt:typed", - range: res.range, - children: [res], - targetType: config - })), localize("nbt.node")) - }); - runtime_exports.registerAttribute(meta, "nbt_path", nbtValidator, { - stringParser: () => makeInfallible(path5, localize("nbt.path")) - }); -} -function makeInfallible(parser, message2) { - return (src, ctx) => { - const start = src.cursor; - const res = parser(src, ctx); - if (res === Failure) { - ctx.err.report(localize("expected", message2), Range.create(start, src.skipRemaining())); - return void 0; - } - return res; - }; -} - -// node_modules/@spyglassmc/nbt/lib/parser/index.js -var parser_exports3 = {}; -__export(parser_exports3, { - byteArray: () => byteArray, - compound: () => compound2, - entry: () => entry2, - intArray: () => intArray, - list: () => list3, - longArray: () => longArray, - path: () => path5, - primitive: () => primitive3, - string: () => string10 -}); - -// node_modules/@spyglassmc/nbt/lib/index.js -var initialize2 = ({ meta }) => { - meta.registerLanguage("snbt", { - extensions: [".snbt"], - parser: entry2 - }); - meta.registerLanguage("nbt", { - extensions: [".nbt"] - }); - meta.registerParser("nbt:entry", entry2); - meta.registerParser("nbt:compound", compound2); - meta.registerParser("nbt:path", path5); - register5(meta); - register6(meta); - register7(meta); - registerMcdocAttributes(meta); -}; - -// node_modules/@spyglassmc/java-edition/lib/dependency/common.js -var ReleaseVersion; -(function(ReleaseVersion2) { - function cmp(a, b) { - const [majorA, minorA, patchA = 0] = a.split("."); - const [majorB, minorB, patchB = 0] = b.split("."); - if (majorA !== majorB) { - return Math.sign(Number(majorA) - Number(majorB)); - } - if (minorA !== minorB) { - return Math.sign(Number(minorA) - Number(minorB)); - } - return Math.sign(Number(patchA) - Number(patchB)); - } - ReleaseVersion2.cmp = cmp; - function isBetween(version, since, until) { - return cmp(version, since) >= 0 && cmp(version, until) < 0; - } - ReleaseVersion2.isBetween = isBetween; -})(ReleaseVersion || (ReleaseVersion = {})); -var PackMcmeta; -(function(PackMcmeta2) { - function readPackFormat(data) { - const max2 = data?.pack?.max_format; - if (Array.isArray(max2) && max2.length >= 1 && typeof max2[0] === "number") { - return max2[0]; - } - if (typeof max2 === "number") { - return max2; - } - const supported = data?.pack?.supported_formats; - if (Array.isArray(supported) && supported.length === 2 && typeof supported[1] === "number") { - return supported[1]; - } - if (typeof supported === "object" && typeof supported?.max_inclusive === "number") { - return supported.max_inclusive; - } - const format = data?.pack?.pack_format; - if (typeof format === "number") { - return format; - } - throw new Error("No pack format found"); - } - PackMcmeta2.readPackFormat = readPackFormat; - async function getType(packRoot, externals) { - const dir = await externals.fs.readdir(packRoot); - const isResourcePack = dir.some((e) => e.isDirectory() && e.name === "assets") && !dir.some((e) => e.isDirectory() && e.name === "data"); - return isResourcePack ? "assets" : "data"; - } - PackMcmeta2.getType = getType; -})(PackMcmeta || (PackMcmeta = {})); - -// node_modules/@spyglassmc/java-edition/lib/dependency/mcmeta.js -var DevelopmentVersionPattern = /^(\d\d\.\d(?:\.\d?\d)?)\-\w+\-\d+$/; -function toVersionInfo(version, release) { - return { - id: version.id, - name: version.name, - release: release ?? version.id, - data_pack_version: version.data_pack_version, - resource_pack_version: version.resource_pack_version - }; -} -function getLatestSnapshot(versions) { - for (const version of versions) { - if (version.type === "release") { - return toVersionInfo(version); - } - const matches = version.id.match(DevelopmentVersionPattern); - if (matches) { - return toVersionInfo(version, matches[1]); - } - } - throw new Error("no next release version found"); -} -function resolveConfiguredVersion(inputVersion, versions, packs, logger) { - function getReleaseVersion(version) { - if (version.type === "release") { - return version.id; - } - const matches = version.id.match(DevelopmentVersionPattern); - if (matches) { - return matches[1]; - } - const index4 = versions.findIndex((v) => v.id === version.id); - for (let i = index4; i >= 0; i -= 1) { - if (versions[i].type === "release") { - return versions[i].id; - } - } - return void 0; - } - if (versions.length === 0) { - throw new Error("mcmeta version list is empty"); - } - if (inputVersion === void 0) { - logger.warn('[resolveConfiguredVersion] Input version was undefined! Falling back to "auto"'); - inputVersion = "auto"; - } - inputVersion = inputVersion.toLowerCase(); - versions = versions.sort((a, b) => b.data_version - a.data_version); - const latestReleaseMcmeta = versions.find((v) => v.type === "release"); - if (latestReleaseMcmeta === void 0) { - throw new Error("mcmeta version list does not contain any releases"); - } - const latestRelease = toVersionInfo(latestReleaseMcmeta); - const latestSnaphot = getLatestSnapshot(versions); - if (inputVersion === "auto") { - if (packs.length === 0) { - logger.info(`[resolveConfiguredVersion] No pack format detected, selecting latest release ${latestRelease?.id}`); - return latestRelease; - } - packs.sort((a, b) => b.format - a.format); - const maxData = packs.filter((p) => p.type === "data")[0]; - const maxAssets = packs.filter((p) => p.type === "assets")[0]; - let nextReleaseVersionInfo = latestSnaphot; - const releases = versions.filter((v) => v.type === "release"); - for (const version of releases) { - if (maxData && maxData.format > version.data_pack_version) { - logger.info(`[resolveConfiguredVersion] Detected data pack format ${maxData.format} in ${maxData.packRoot}, selecting version ${nextReleaseVersionInfo.id}`); - return nextReleaseVersionInfo; - } - if (maxAssets && maxAssets.format > version.resource_pack_version) { - logger.info(`[resolveConfiguredVersion] Detected resource pack format ${maxAssets.format} in ${maxAssets.packRoot}, selecting version ${nextReleaseVersionInfo.id}`); - return nextReleaseVersionInfo; - } - if (maxData && maxData.format === version.data_pack_version) { - logger.info(`[resolveConfiguredVersion] Detected data pack format ${maxData.format} in ${maxData.packRoot}, selecting version ${version.id}`); - return toVersionInfo(version); - } - if (maxAssets && maxAssets.format === version.resource_pack_version) { - logger.info(`[resolveConfiguredVersion] Detected resource pack format ${maxAssets.format} in ${maxAssets.packRoot}, selecting version ${version.id}`); - return toVersionInfo(version); - } - nextReleaseVersionInfo = toVersionInfo(version); - } - logger.info(`[resolveConfiguredVersion] Detected pack format too low, selecting oldest supported release ${nextReleaseVersionInfo?.id}`); - return nextReleaseVersionInfo; - } else if (inputVersion === "latest release") { - logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${latestRelease.id}`); - return latestRelease; - } else if (inputVersion === "latest snapshot") { - logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${latestSnaphot.id}`); - return latestSnaphot; - } - const configVersion = versions.find((v) => inputVersion === v.id.toLowerCase() || inputVersion === v.name.toLowerCase()); - if (configVersion === void 0) { - logger.info(`[resolveConfiguredVersion] Could not find config version "${inputVersion}", selecting version ${latestSnaphot.id}`); - return latestSnaphot; - } - const configReleaseVersion = getReleaseVersion(configVersion); - if (configReleaseVersion === void 0) { - logger.info(`[resolveConfiguredVersion] Could not determine release version of config "${inputVersion}", selecting version ${latestSnaphot.id}`); - return latestSnaphot; - } - logger.info(`[resolveConfiguredVersion] Using config "${inputVersion}", selecting version ${configVersion?.id}`); - return toVersionInfo(configVersion, configReleaseVersion); -} -function symbolRegistrar(summary, release) { - const McmetaSummaryUri = "mcmeta://summary/registries.json"; - function addStatesSymbols(category, states, symbols) { - const capitalizedCategory = `${category[0].toUpperCase()}${category.slice(1)}`; - for (const [id, [properties, defaults]] of Object.entries(states)) { - const uri = McmetaSummaryUri; - symbols.query(uri, category, ResourceLocation.lengthen(id)).onEach(Object.entries(properties), ([state, values], blockQuery) => { - const defaultValue = defaults[state]; - blockQuery.member(`${uri}#${capitalizedCategory}_states`, state, (stateQuery) => { - stateQuery.enter({ - data: { subcategory: "state" }, - usage: { type: "declaration" } - }).onEach(values, (value) => { - stateQuery.member(value, (valueQuery) => { - valueQuery.enter({ - data: { subcategory: "state_value" }, - usage: { type: "declaration" } - }); - if (value === defaultValue) { - stateQuery.amend({ - data: { relations: { default: { category, path: valueQuery.path } } } - }); - } - }); - }); - }); - }); - } - const stateTypes = { block: summary.blocks, fluid: summary.fluids }; - for (const [type2, states2] of Object.entries(stateTypes)) { - symbols.query(McmetaSummaryUri, "mcdoc/dispatcher", `mcdoc:${type2}_states`).enter({ usage: { type: "declaration" } }).onEach(Object.entries(states2), ([id, [properties]], query) => { - const data = { - typeDef: { - kind: "struct", - fields: Object.entries(properties).map(([propKey, propValues]) => ({ - kind: "pair", - key: propKey, - optional: true, - type: { - kind: "union", - members: propValues.map((value) => ({ - kind: "literal", - value: { kind: "string", value } - })) - } - })) - } - }; - query.member(id, (stateQuery) => { - stateQuery.enter({ - data: { data }, - usage: { type: "declaration" } - }); - }); - }); - symbols.query(McmetaSummaryUri, "mcdoc/dispatcher", `mcdoc:${type2}_state_keys`).enter({ usage: { type: "declaration" } }).onEach(Object.entries(states2), ([id, [properties]], query) => { - const data = { - typeDef: { - kind: "union", - members: Object.keys(properties).map((propKey) => ({ - kind: "literal", - value: { kind: "string", value: propKey } - })) - } - }; - query.member(id, (stateQuery) => { - stateQuery.enter({ - data: { data }, - usage: { type: "declaration" } - }); - }); - }); - } - } - function addRegistriesSymbols(registries, symbols) { - function isCategory(str) { - return FileCategories.includes(str) || RegistryCategories.includes(str); - } - for (const [registryId, registry] of Object.entries(registries)) { - if (isCategory(registryId)) { - for (const entryId of registry) { - symbols.query(McmetaSummaryUri, registryId, ResourceLocation.lengthen(entryId)).enter({ usage: { type: "declaration" } }); - } - } - } - } - function addBuiltinSymbols(symbols) { - if (ReleaseVersion.cmp(release, "1.21.2") < 0) { - symbols.query(McmetaSummaryUri, "loot_table", "minecraft:empty").enter({ usage: { type: "declaration" } }); - } - symbols.query(McmetaSummaryUri, "model", "minecraft:builtin/generated").enter({ usage: { type: "declaration" } }); - if (ReleaseVersion.cmp(release, "1.21.4") < 0) { - symbols.query(McmetaSummaryUri, "model", "minecraft:builtin/entity").enter({ usage: { type: "declaration" } }); - } - } - return (symbols) => { - addRegistriesSymbols(summary.registries, symbols); - addStatesSymbols("block", summary.blocks, symbols); - addStatesSymbols("fluid", summary.fluids, symbols); - addBuiltinSymbols(symbols); - }; -} -var Fluids = { - flowing_lava: [{ falling: ["false", "true"], level: ["1", "2", "3", "4", "5", "6", "7", "8"] }, { - falling: "false", - level: "1" - }], - flowing_water: [ - { falling: ["false", "true"], level: ["1", "2", "3", "4", "5", "6", "7", "8"] }, - { falling: "false", level: "1" } - ], - lava: [{ falling: ["false", "true"] }, { falling: "false" }], - water: [{ falling: ["false", "true"] }, { falling: "false" }] -}; - -// node_modules/@spyglassmc/java-edition/lib/dependency/index.js -async function getVersions(externals, logger) { - return (await fetchWithCache(externals, logger, "https://api.spyglassmc.com/mcje/versions")).json(); -} -async function getMcmetaSummary(externals, logger, version, overridePaths = {}) { - async function handleOverride(currentValue, overrideConfig) { - if (overrideConfig) { - try { - const override = await fileUtil.readJson(externals, overrideConfig.path); - if (overrideConfig.replace) { - return override; - } else { - return merge(currentValue, override); - } - } catch (e) { - logger.error(`[je] [mcmeta-overrides] Failed loading customized mcmeta summary file \u201C${overrideConfig.path}\u201D`, e); - } - } - return currentValue; - } - const getResource = async (type2, overrideConfig) => { - const response = await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/${type2}`); - return { - data: await handleOverride(await response.json(), overrideConfig), - checksum: response.headers.get("etag") ?? "" - }; - }; - const [blocks, commands, fluids, registries] = [ - await getResource("block_states", overridePaths.blocks), - await getResource("commands", overridePaths.commands), - { - data: await handleOverride(Fluids, overridePaths.fluids), - checksum: "v1" - }, - await getResource("registries", overridePaths.registries) - ]; - return { - blocks: blocks.data, - commands: commands.data, - fluids: fluids.data, - registries: registries.data, - checksum: `${blocks.checksum}-${commands.checksum}-${fluids.checksum}-${registries.checksum}` - }; -} -async function getVanillaDatapack(externals, logger, version) { - return { - type: "tarball-ram", - name: "vanilla-datapack", - data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/vanilla-data/tarball`)).arrayBuffer()), - stripLevel: 0 - }; -} -async function getVanillaResourcepack(externals, logger, version) { - return { - type: "tarball-ram", - name: "vanilla-assets-tiny", - data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/mcje/versions/${encodeURIComponent(version)}/vanilla-assets-tiny/tarball`)).arrayBuffer()), - stripLevel: 0 - }; -} -async function getVanillaMcdoc(externals, logger) { - return { - type: "tarball-ram", - name: "vanilla-mcdoc", - data: new Uint8Array(await (await fetchWithCache(externals, logger, `https://api.spyglassmc.com/vanilla-mcdoc/tarball`)).arrayBuffer()), - stripLevel: 0 - }; -} - -// node_modules/@spyglassmc/java-edition/lib/binder/index.js -var Resources = /* @__PURE__ */ new Map(); -function resource(path6, resource2 = {}) { - const previous = Resources.get(path6) ?? []; - Resources.set(path6, [ - ...previous, - { - path: path6, - category: resource2.category ?? path6, - ext: resource2.ext ?? ".json", - pack: resource2.pack ?? "data", - ...resource2 - } - ]); -} -resource("advancements", { category: "advancement", until: "1.21" }); -resource("functions", { category: "function", until: "1.21", ext: ".mcfunction" }); -resource("item_modifiers", { category: "item_modifier", since: "1.17", until: "1.21" }); -resource("loot_tables", { category: "loot_table", until: "1.21" }); -resource("predicates", { category: "predicate", until: "1.21" }); -resource("recipes", { category: "recipe", until: "1.21" }); -resource("structures", { category: "structure", until: "1.21", ext: ".nbt" }); -resource("tags/blocks", { category: "tag/block", until: "1.21" }); -resource("tags/entity_types", { category: "tag/entity_type", until: "1.21" }); -resource("tags/fluids", { category: "tag/fluid", until: "1.21" }); -resource("tags/functions", { category: "tag/function", until: "1.21" }); -resource("tags/game_events", { category: "tag/game_event", since: "1.17", until: "1.21" }); -resource("tags/items", { category: "tag/item", until: "1.21" }); -resource("advancement", { since: "1.21" }); -resource("function", { since: "1.21", ext: ".mcfunction" }); -resource("item_modifier", { since: "1.21" }); -resource("loot_table", { since: "1.21" }); -resource("predicate", { since: "1.21" }); -resource("recipe", { since: "1.21" }); -resource("structure", { since: "1.21", ext: ".nbt" }); -resource("tags/block", { category: "tag/block", since: "1.21" }); -resource("tags/entity_type", { category: "tag/entity_type", since: "1.21" }); -resource("tags/fluid", { category: "tag/fluid", since: "1.21" }); -resource("tags/function", { category: "tag/function", since: "1.21" }); -resource("tags/game_event", { category: "tag/game_event", since: "1.21" }); -resource("tags/item", { category: "tag/item", since: "1.21" }); -resource("banner_pattern", { since: "1.20.5" }); -resource("cat_variant", { since: "1.21.5" }); -resource("chat_type", { since: "1.19" }); -resource("chicken_variant", { since: "1.21.5" }); -resource("cow_variant", { since: "1.21.5" }); -resource("damage_type", { since: "1.19.4" }); -resource("dialog", { since: "1.21.6" }); -resource("enchantment", { since: "1.21" }); -resource("enchantment_provider", { since: "1.21" }); -resource("frog_variant", { since: "1.21.5" }); -resource("instrument", { since: "1.21.2" }); -resource("jukebox_song", { since: "1.21" }); -resource("painting_variant", { since: "1.21" }); -resource("pig_variant", { since: "1.21.5" }); -resource("sulfur_cube_archetype", { since: "26.2" }); -resource("test_instance", { since: "1.21.5" }); -resource("test_environment", { since: "1.21.5" }); -resource("timeline", { since: "1.21.11" }); -resource("trade_set", { since: "26.1" }); -resource("trial_spawner", { since: "1.21.2" }); -resource("trim_pattern", { since: "1.19.4" }); -resource("trim_material", { since: "1.19.4" }); -resource("villager_trade", { since: "26.1" }); -resource("wolf_sound_variant", { since: "1.21.5" }); -resource("wolf_variant", { since: "1.20.5" }); -resource("world_clock", { since: "26.1" }); -resource("zombie_nautilus_variant", { since: "1.21.11" }); -resource("dimension", { since: "1.16" }); -resource("dimension_type", { since: "1.16" }); -resource("worldgen/biome", { since: "1.16.2" }); -resource("worldgen/configured_carver", { since: "1.16.2" }); -resource("worldgen/configured_feature", { since: "1.16.2" }); -resource("worldgen/configured_structure_feature", { since: "1.16.2", until: "1.19" }); -resource("worldgen/density_function", { since: "1.18.2" }); -resource("worldgen/flat_level_generator_preset", { since: "1.19" }); -resource("worldgen/multi_noise_biome_source_parameter_list", { since: "1.19.4" }); -resource("worldgen/noise", { since: "1.18" }); -resource("worldgen/noise_settings", { since: "1.16.2" }); -resource("worldgen/placed_feature", { since: "1.18" }); -resource("worldgen/processor_list", { since: "1.16.2" }); -resource("worldgen/configured_surface_builder", { since: "1.16.2", until: "1.18" }); -resource("worldgen/structure", { since: "1.19" }); -resource("worldgen/structure_set", { since: "1.18.2" }); -resource("worldgen/template_pool", { since: "1.16.2" }); -resource("worldgen/world_preset", { since: "1.19" }); -var NonTaggableRegistries = /* @__PURE__ */ new Set([ - // Legacy plural paths - "block", - "fluid", - "function", - "game_event", - "item", - // Removed before 1.18 - "worldgen/block_placer_type", - "worldgen/surface_builder" -]); -for (const registry of TaggableResourceLocationCategories) { - if (NonTaggableRegistries.has(registry)) { - continue; - } - resource(`tags/${registry}`, { category: `tag/${registry}`, since: "1.18" }); -} -resource("atlases", { pack: "assets", category: "atlas", since: "1.19.3" }); -resource("blockstates", { pack: "assets", category: "block_definition" }); -resource("equipment", { pack: "assets", since: "1.21.4" }); -resource("font", { pack: "assets", since: "1.16" }); -resource("font", { pack: "assets", category: "font/ttf", since: "1.16", ext: ".ttf" }); -resource("font", { pack: "assets", category: "font/otf", since: "1.16", ext: ".otf" }); -resource("font", { pack: "assets", category: "font/unihex", since: "1.20", ext: ".zip" }); -resource("items", { pack: "assets", category: "item_definition", since: "1.21.4" }); -resource("lang", { pack: "assets" }); -resource("models", { pack: "assets", category: "model" }); -resource("models/equipment", { - pack: "assets", - category: "equipment", - since: "1.21.2", - until: "1.21.4" -}); -resource("particles", { pack: "assets", category: "particle" }); -resource("post_effect", { pack: "assets", since: "1.21.2" }); -resource("shaders/post", { pack: "assets", category: "post_effect", until: "1.21.2" }); -resource("shaders", { pack: "assets", category: "shader" }); -resource("shaders", { pack: "assets", category: "shader/fragment", ext: ".fsh" }); -resource("shaders", { pack: "assets", category: "shader/vertex", ext: ".vsh" }); -resource("sounds", { pack: "assets", category: "sound", ext: ".ogg" }); -resource("textures", { pack: "assets", category: "texture", ext: ".png" }); -resource("textures", { pack: "assets", category: "texture_meta", ext: ".png.mcmeta" }); -resource("waypoint_style", { pack: "assets", since: "1.21.6" }); -resource("lang", { pack: "assets", category: "lang/deprecated", identifier: "deprecated" }); -resource("", { pack: "assets", category: "sounds", identifier: "sounds" }); -resource("", { - pack: "assets", - category: "regional_compliancies", - identifier: "regional_compliancies" -}); -resource("", { pack: "assets", category: "gpu_warnlist", identifier: "gpu_warnlist" }); -function* getResources() { - for (const resources of Resources.values()) { - yield* resources; - } - return void 0; -} -function* getRels(uri, rootUris) { - yield* fileUtil.getRels(uri, rootUris); - const parts = uri.split("/"); - for (let i = parts.length - 2; i >= 0; i--) { - if (parts[i] === "data" || parts[i] === "assets") { - yield parts.slice(i).join("/"); - } - } - return void 0; -} -function* getRoots(uri, rootUris) { - yield* fileUtil.getRoots(uri, rootUris); - const parts = uri.split("/"); - for (let i = parts.length - 2; i >= 0; i--) { - if (parts[i] === "data" || parts[i] === "assets") { - yield `${parts.slice(0, i).join("/")}/`; - } - } - return void 0; -} -function getCandidateResourcesForRel(rel) { - const parts = rel.split("/"); - if (parts.length < 3) { - return []; - } - const [pack, namespace, ...rest] = parts; - if (pack !== "data" && pack !== "assets") { - return []; - } - const candidateResources = []; - if (rest.length === 1) { - const resources = Resources.get(""); - for (const res of resources ?? []) { - if (res.pack !== pack) { - continue; - } - let identifier4 = rest[0]; - if (!identifier4.endsWith(res.ext)) { - continue; - } - identifier4 = identifier4.slice(0, -res.ext.length); - if (res.identifier && identifier4 !== res.identifier) { - continue; - } - candidateResources.push({ ...res, namespace, identifier: identifier4 }); - } - } - for (let i = 1; i < rest.length; i += 1) { - const resources = Resources.get(rest.slice(0, i).join("/")); - for (const res of resources ?? []) { - if (res.pack !== pack) { - continue; - } - let identifier4 = rest.slice(i).join("/"); - if (!identifier4.endsWith(res.ext)) { - continue; - } - identifier4 = identifier4.slice(0, -res.ext.length); - if (res.identifier && identifier4 !== res.identifier) { - continue; - } - candidateResources.push({ ...res, namespace, identifier: identifier4 }); - } - } - return candidateResources; -} -function dissectUri(uri, ctx) { - const rels = getRels(uri, ctx.roots); - const release = ctx.project["loadedVersion"]; - if (!release) { - return void 0; - } - for (const rel of rels) { - const candidateResources = getCandidateResourcesForRel(rel); - if (candidateResources.length === 0) { - continue; - } - let res = candidateResources.findLast((res2) => matchVersion(release, res2.since, res2.until)); - if (res !== void 0) { - return { ok: true, ...res, expected: void 0 }; - } - res = candidateResources[candidateResources.length - 1]; - let expected = void 0; - for (const [path6, others] of Resources) { - for (const other of others) { - if (other.category !== res.category) { - continue; - } - if (matchVersion(release, other.since, other.until)) { - expected = path6; - break; - } - } - } - return { ok: false, ...res, expected }; - } - return void 0; -} -var uriBinder2 = (uris, ctx) => { - for (const uri of uris) { - const parts = dissectUri(uri, ctx); - if (parts) { - ctx.symbols.query(uri, parts.category, `${parts.namespace}:${parts.identifier}`).enter({ - usage: { type: "definition" } - }); - } - } -}; -function registerCustomResources(config) { - for (const [path6, res] of Object.entries(config.env.customResources)) { - resource(path6, { ...res, category: res.category }); - } -} -function matchVersion(target, since, until) { - if (since && ReleaseVersion.cmp(target, since) < 0) { - return false; - } - if (until && ReleaseVersion.cmp(until, target) <= 0) { - return false; - } - return true; -} -function reportDissectError(realPath, expectedPath, ctx) { - const release = ctx.project["loadedVersion"]; - if (!release) { - return; - } - if (expectedPath) { - ctx.err.report(localize("java-edition.binder.wrong-folder", localeQuote(realPath), release, localeQuote(expectedPath)), Range.Beginning, ErrorSeverity.Hint); - } else { - ctx.err.report(localize("java-edition.binder.wrong-version", localeQuote(realPath), release), Range.Beginning, ErrorSeverity.Hint); - } -} -function uriBuilder(resources) { - return (identifier4, ctx) => { - const root = getRoots(ctx.doc.uri, ctx.roots).next().value; - if (!root) { - return void 0; - } - const release = ctx.project["loadedVersion"]; - if (!release) { - return void 0; - } - const resource2 = resources.find((r) => matchVersion(release, r.since, r.until)); - if (!resource2) { - return void 0; - } - const sepIndex = identifier4.indexOf(":"); - const namespace = sepIndex > 0 ? identifier4.slice(0, sepIndex) : "minecraft"; - const path6 = identifier4.slice(sepIndex + 1); - return `${root}${resource2.pack}/${namespace}/${resource2.path}/${path6}${resource2.ext}`; - }; -} -function registerUriBuilders(meta) { - const resourcesByCategory = /* @__PURE__ */ new Map(); - for (const resource2 of getResources()) { - resourcesByCategory.set(resource2.category, [ - ...resourcesByCategory.get(resource2.category) ?? [], - resource2 - ]); - } - for (const [category, resources] of resourcesByCategory.entries()) { - meta.registerUriBuilder(category, uriBuilder(resources)); - } -} -var jeFileUriPredicate = (uri, ctx) => { - const rels = [...getRels(uri, ctx.roots)]; - return rels.some((rel) => getCandidateResourcesForRel(rel).length > 0); -}; - -// node_modules/@spyglassmc/java-edition/lib/json/binder/index.js -function bindDeprecated(node, ctx) { - const renamed = node.children.find((p) => p.key?.value === "renamed")?.value; - if (JsonObjectNode.is(renamed)) { - for (const pair of renamed.children) { - if (JsonStringNode.is(pair.value)) { - const range3 = Range.translate(pair.value.range, 1, -1); - ctx.symbols.query(ctx.doc, "translation_key", pair.value.value).enter({ - usage: { type: "definition", range: range3, fullRange: pair } - }); - } - } - } -} -function bindLanguage(node, ctx) { - const isEnglish = ctx.doc.uri.endsWith("/en_us.json"); - for (const pair of node.children) { - if (pair.key) { - const desc = JsonStringNode.is(pair.value) ? pair.value.value : void 0; - const range3 = Range.translate(pair.key.range, 1, -1); - ctx.symbols.query(ctx.doc, "translation_key", pair.key.value).enter({ - data: { desc: isEnglish ? desc : void 0 }, - usage: { type: "definition", range: range3, fullRange: pair } - }); - } - } -} -var file7 = (node, ctx) => { - if (ctx.doc.uri.match(/\/lang\/[a-z_]+.json$/)) { - const child = node.children[0]; - if (JsonObjectNode.is(child)) { - if (ctx.doc.uri.endsWith("/deprecated.json")) { - bindDeprecated(child, ctx); - } else { - bindLanguage(child, ctx); - } - } - } -}; -function register8(meta) { - meta.registerBinder("json:file", file7); -} - -// node_modules/@spyglassmc/java-edition/lib/json/checker/index.js -function createTagDefinition(registry) { - const id = { - kind: "tree", - values: { - registry: { kind: "literal", value: { kind: "string", value: registry } }, - tags: { kind: "literal", value: { kind: "string", value: "allowed" } } - } - }; - return { - kind: "concrete", - child: { kind: "reference", path: "::java::data::tag::Tag" }, - typeArgs: [{ kind: "string", attributes: [{ name: "id", value: id }] }] - }; -} -var file8 = (node, ctx) => { - const child = node.children[0]; - if (ctx.doc.uri.endsWith("/pack.mcmeta")) { - const type2 = { kind: "reference", path: "::java::pack::Pack" }; - return checker_exports3.index(type2)(child, ctx); - } - const parts = dissectUri(ctx.doc.uri, ctx); - if (parts?.ok) { - if (parts.category.startsWith("tag/")) { - const type3 = createTagDefinition(parts.category.slice(4)); - return checker_exports3.index(type3)(child, ctx); - } - const type2 = { - kind: "dispatcher", - registry: "minecraft:resource", - parallelIndices: [{ kind: "static", value: parts.category }] - }; - return checker_exports3.index(type2, { discardDuplicateKeyErrors: true })(child, ctx); - } else if (parts?.ok === false) { - reportDissectError(parts.path, parts.expected, ctx); - } -}; -function register9(meta) { - meta.registerChecker("json:file", file8); -} - -// node_modules/@spyglassmc/java-edition/lib/json/completer/index.js -var textureSlot = (node, ctx) => { - const slot = node.slot ?? SymbolNode.mock(node, { - category: "texture_slot", - usageType: node.kind === "definition" ? "definition" : "reference" - }); - const slotItems = builtin_exports5.symbol(slot, ctx); - if (node.kind === "definition") { - return slotItems; - } - if (node.kind === "reference") { - return slotItems.map((item) => ({ - ...item, - range: node.range, - label: "#" + item.label, - insertText: "#" + (item.insertText ?? item.label) - })); - } - const id = node.id ?? ResourceLocationNode.mock(node, { category: "texture" }); - return builtin_exports5.resourceLocation(id, ctx); -}; -function register10(meta) { - meta.registerCompleter("java_edition:texture_slot", textureSlot); -} - -// node_modules/@spyglassmc/java-edition/lib/json/parser/index.js -function textureSlotParser(kind) { - return (src, ctx) => { - const start = src.cursor; - const ans = { - type: "java_edition:texture_slot", - range: Range.create(start), - kind, - children: [] - }; - if (kind === "definition") { - const slot = symbol5({ category: "texture_slot", usageType: "definition" })(src, ctx); - ans.children.push(slot); - ans.slot = slot; - } else if (src.tryPeek("#")) { - ans.children.push(literal("#")(src, ctx)); - const slot = symbol5({ category: "texture_slot", usageType: "reference" })(src, ctx); - ans.children.push(slot); - ans.slot = slot; - } else if (kind === "reference") { - ctx.err.report(localize("expected", localeQuote("#")), src); - } else { - const id = resourceLocation6({ category: "texture", usageType: "reference" })(src, ctx); - ans.children.push(id); - ans.id = id; - } - ans.range = Range.create(start, src); - return ans; - }; -} -var translationValueParser = (src, ctx) => { - const start = src.cursor; - const ans = { - type: "java_edition:translation_value", - range: Range.create(start), - children: [], - value: "" - }; - while (src.canRead()) { - src.skipUntilOrEnd("%"); - const argStart = src.cursor; - if (src.trySkip("%")) { - if (src.trySkip("%")) { - const token2 = src.sliceToCursor(argStart); - ans.children.push({ - type: "literal", - range: Range.create(argStart, src), - options: { pool: [token2], colorTokenType: "escape" }, - value: token2 - }); - continue; - } - let hasInteger = false; - while (src.canRead() && Source.isDigit(src.peek())) { - src.skip(); - hasInteger = true; - } - if (hasInteger && !src.trySkip("$")) { - ctx.err.report(localize("java-edition.translation-value.percent-escape-hint", localize("expected", localeQuote("$"))), src); - } - if (!src.trySkip("s")) { - ctx.err.report(localize("java-edition.translation-value.percent-escape-hint", localize("expected", localeQuote("s"))), src); - } - const token = src.sliceToCursor(argStart); - ans.children.push({ - type: "literal", - range: Range.create(argStart, src), - options: { pool: [token] }, - value: token - }); - } - } - ans.value = src.sliceToCursor(start); - ans.range = Range.create(start, src); - return ans; -}; - -// node_modules/@spyglassmc/java-edition/lib/json/mcdocAttributes.js -var validator = runtime_exports.attribute.validator; -var criterionValidator = validator.alternatives(validator.tree({ - definition: validator.boolean -}), () => ({ definition: false })); -var textureSlotValidator = validator.alternatives(validator.tree({ - kind: validator.options("definition", "value", "reference") -}), () => ({ kind: "value" })); -var translationKeyValidator = validator.alternatives(validator.tree({ - definition: validator.boolean -}), () => ({ definition: false })); -function registerMcdocAttributes2(meta) { - runtime_exports.registerAttribute(meta, "criterion", criterionValidator, { - stringParser: (config, _, ctx) => { - const parts = dissectUri(ctx.doc.uri, ctx); - if (!parts || !parts.ok || parts.category !== "advancement") { - return void 0; - } - return symbol5({ - category: "advancement", - subcategory: "criterion", - parentPath: [`${parts.namespace}:${parts.identifier}`], - usageType: config.definition ? "definition" : "reference" - }); - }, - stringMocker: (config, _, ctx) => { - const parts = dissectUri(ctx.doc.uri, ctx); - if (!parts || !parts.ok || parts.category !== "advancement") { - return void 0; - } - return SymbolNode.mock(ctx.offset, { - category: "advancement", - subcategory: "criterion", - parentPath: [`${parts.namespace}:${parts.identifier}`] - }); - } - }); - runtime_exports.registerAttribute(meta, "texture_slot", textureSlotValidator, { - stringParser: (config, _, ctx) => { - return textureSlotParser(config.kind); - }, - stringMocker: (config, _, ctx) => { - return { - type: "java_edition:texture_slot", - range: Range.create(ctx.offset), - kind: config.kind, - children: [] - }; - } - }); - runtime_exports.registerAttribute(meta, "translation_key", translationKeyValidator, { - stringParser: (config, _, ctx) => { - return symbol5({ - category: "translation_key", - usageType: config.definition ? "definition" : "reference" - }); - }, - stringMocker: (config, _, ctx) => { - return SymbolNode.mock(ctx.offset, { - category: "translation_key", - usageType: config.definition ? "definition" : "reference" - }); - } - }); - runtime_exports.registerAttribute(meta, "translation_value", () => void 0, { - stringParser: () => translationValueParser - }); -} - -// node_modules/@spyglassmc/java-edition/lib/json/index.js -var initialize3 = (ctx) => { - registerMcdocAttributes2(ctx.meta); - register8(ctx.meta); - register9(ctx.meta); - register10(ctx.meta); -}; - -// node_modules/@spyglassmc/java-edition/lib/mcdocAttributes.js -var validator2 = runtime_exports.attribute.validator; -var gameRuleValidator = validator2.tree({ - type: validator2.options("boolean", "int") -}); -function registerMcdocAttributes3(meta, commands, release) { - runtime_exports.registerAttribute(meta, "since", validator2.string, { - filterElement: (config, ctx) => { - return ReleaseVersion.cmp(release, config) >= 0; - } - }); - runtime_exports.registerAttribute(meta, "until", validator2.string, { - filterElement: (config, ctx) => { - return ReleaseVersion.cmp(release, config) < 0; - } - }); - runtime_exports.registerAttribute(meta, "deprecated", validator2.optional(validator2.string), { - mapField: (config, field, ctx) => { - if (!config || ReleaseVersion.cmp(release, config) >= 0) { - return { ...field, deprecated: true }; - } - return field; - } - }); - const gameRuleNode = commands.children.gamerule?.children; - if (gameRuleNode) { - const [boolGameRules, intGameRules] = ["brigadier:bool", "brigadier:integer"].map((type2) => Object.entries(gameRuleNode).flatMap(([key2, node]) => node.children?.value?.type === "argument" && node.children.value.parser === type2 ? [key2] : [])); - runtime_exports.registerAttribute(meta, "game_rule", gameRuleValidator, { - stringParser: (config, _, ctx) => { - return literal({ - pool: config.type === "boolean" ? boolGameRules : intGameRules, - colorTokenType: "string" - }); - }, - stringMocker: (config, _, ctx) => { - return LiteralNode.mock(ctx.offset, { - pool: config.type === "boolean" ? boolGameRules : intGameRules - }); - } - }); - } -} -function registerPackFormatAttribute(meta, versions, packs) { - const dataFormats = /* @__PURE__ */ new Map(); - const assetsFormats = /* @__PURE__ */ new Map(); - const latestSnapshot = getLatestSnapshot(versions); - if (latestSnapshot.release !== latestSnapshot.id) { - dataFormats.set(latestSnapshot.data_pack_version, [latestSnapshot.release]); - assetsFormats.set(latestSnapshot.resource_pack_version, [latestSnapshot.release]); - } - for (const version of versions) { - if (version.type === "release") { - dataFormats.set(version.data_pack_version, [ - ...dataFormats.get(version.data_pack_version) ?? [], - version.id - ]); - assetsFormats.set(version.resource_pack_version, [ - ...assetsFormats.get(version.resource_pack_version) ?? [], - version.id - ]); - } - } - function getFormats(packMcmetaUri) { - const thisPack = packs.find((p) => fileUtil.isSubUriOf(packMcmetaUri, p.packRoot)); - return thisPack?.type === "assets" ? assetsFormats : dataFormats; - } - runtime_exports.registerAttribute(meta, "pack_format", () => void 0, { - numericCompleter: (_, ctx) => { - return [...getFormats(ctx.doc.uri).entries()].map(([k, v], i) => ({ - range: Range.create(ctx.offset), - label: `${k}`, - labelSuffix: ` (${v[0]})`, - sortText: `${i}`.padStart(4, "0") - })); - } - }); -} - -// node_modules/@spyglassmc/mcfunction/lib/colorizer/macro.js -var macro = (node, ctx) => { - const tokens = []; - for (const child of node.children) { - if (child.type === "mcfunction:macro/prefix") { - tokens.push(ColorToken.create(child.range, "literal")); - } else if (child.type === "mcfunction:macro/other") { - tokens.push(ColorToken.create(child.range, "string")); - } else { - const { start, end } = child.range; - tokens.push(ColorToken.create(Range.create(start, start + 2), "literal")); - tokens.push(ColorToken.create(Range.create(start + 2, end - 1), "property")); - tokens.push(ColorToken.create(Range.create(end - 1, end), "literal")); - } - } - return tokens; -}; - -// node_modules/@spyglassmc/mcfunction/lib/colorizer/index.js -function register11(meta) { - meta.registerColorizer("mcfunction:command_child/literal", builtin_exports4.literal); - meta.registerColorizer("mcfunction:command_child/trailing", builtin_exports4.error); - meta.registerColorizer("mcfunction:macro", macro); -} - -// node_modules/@spyglassmc/mcfunction/lib/completer/index.js -var completer_exports5 = {}; -__export(completer_exports5, { - command: () => command, - entry: () => entry3 -}); - -// node_modules/@spyglassmc/mcfunction/lib/node/command.js -var CommandNode; -(function(CommandNode2) { - function is(node) { - return node?.type === "mcfunction:command"; - } - CommandNode2.is = is; - function mock(range3, options2 = {}) { - return { type: "mcfunction:command", range: Range.get(range3), children: [], options: options2 }; - } - CommandNode2.mock = mock; -})(CommandNode || (CommandNode = {})); -var CommandChildNode; -(function(CommandChildNode2) { - function is(node) { - return node.type === "mcfunction:command_child"; - } - CommandChildNode2.is = is; -})(CommandChildNode || (CommandChildNode = {})); -var LiteralCommandChildNode; -(function(LiteralCommandChildNode2) { - function is(node) { - return node?.type === "mcfunction:command_child/literal"; - } - LiteralCommandChildNode2.is = is; -})(LiteralCommandChildNode || (LiteralCommandChildNode = {})); - -// node_modules/@spyglassmc/mcfunction/lib/node/entry.js -var McfunctionNode; -(function(McfunctionNode2) { - function is(node) { - return node?.type === "mcfunction:entry"; - } - McfunctionNode2.is = is; -})(McfunctionNode || (McfunctionNode = {})); - -// node_modules/@spyglassmc/mcfunction/lib/node/macro.js -var MacroNode; -(function(MacroNode2) { - function is(obj) { - return obj?.type === "mcfunction:macro"; - } - MacroNode2.is = is; - function mock(range3) { - return { type: "mcfunction:macro", range: Range.get(range3), children: [] }; - } - MacroNode2.mock = mock; -})(MacroNode || (MacroNode = {})); - -// node_modules/@spyglassmc/mcfunction/lib/tree/util.js -function redirect(rootTreeNode, path6) { - return path6.reduce((p, c) => p?.children?.[c], rootTreeNode); -} -function resolveParentTreeNode(parentTreeNode, rootTreeNode, parentPath) { - if (parentTreeNode?.redirect) { - return { - treeNode: redirect(rootTreeNode, parentTreeNode.redirect), - path: [...parentTreeNode.redirect] - }; - } else if (parentTreeNode && !parentTreeNode.children && !parentTreeNode.executable) { - return { treeNode: rootTreeNode, path: [] }; - } else { - return { treeNode: parentTreeNode, path: parentPath }; - } -} -function categorizeTreeChildren(children) { - const ans = { - literalTreeNodes: [], - argumentTreeNodes: [] - }; - for (const e of Object.entries(children)) { - if (e[1].type === "literal") { - ans.literalTreeNodes.push(e); - } else if (e[1].type === "argument") { - ans.argumentTreeNodes.push(e); - } - } - return ans; -} - -// node_modules/@spyglassmc/mcfunction/lib/completer/index.js -function entry3(tree2, getMockNodes2) { - return (node, ctx) => { - const childNode = AstNode.findChild(node, ctx.offset, true); - if (CommandNode.is(childNode)) { - return command(tree2, getMockNodes2)(childNode ?? CommandNode.mock(ctx.offset), ctx); - } else { - return []; - } - }; -} -function command(tree2, getMockNodes2) { - return (node, ctx) => { - const index4 = AstNode.findChildIndex(node, ctx.offset, true); - const selectedChildNode = node.children[index4]?.children[0]; - if (selectedChildNode) { - return builtin_exports5.dispatch(selectedChildNode, ctx); - } - const lastChildNode = AstNode.findLastChild(node, ctx.offset); - if (!lastChildNode) { - return Object.keys(tree2.children ?? {}).map((v) => CompletionItem.create(v, ctx.offset, { - kind: 14 - /* core.CompletionKind.Keyword */ - })); - } - const treePath = lastChildNode.path; - const { treeNode: parentTreeNode } = resolveParentTreeNode(redirect(tree2, treePath), tree2); - if (!parentTreeNode?.children) { - return []; - } - const { literalTreeNodes, argumentTreeNodes } = categorizeTreeChildren(parentTreeNode.children); - const lastIndex = node.children.indexOf(lastChildNode); - const prevNodes = node.children.slice(0, lastIndex + 1); - return [ - ...literalTreeNodes.map(([name]) => CompletionItem.create(name, ctx.offset, { - kind: 14 - /* core.CompletionKind.Keyword */ - })), - ...argumentTreeNodes.flatMap(([_name, treeNode]) => Arrayable.toArray(getMockNodes2(treeNode, prevNodes, ctx)).flatMap((n) => builtin_exports5.dispatch(n, ctx))) - ]; - }; -} - -// node_modules/@spyglassmc/mcfunction/lib/parser/argument.js -function argumentTreeNodeToString(name, treeNode) { - const parserName = treeNode.parser.slice(treeNode.parser.indexOf(":") + 1); - return `<${name}: ${parserName}>`; -} - -// node_modules/@spyglassmc/mcfunction/lib/parser/common.js -var sep = (src, ctx) => { - const start = src.cursor; - const ans = src.readSpace(); - if (ans !== " ") { - ctx.err.report(localize("expected", localize("mcfunction.parser.sep", localeQuote(" "))), Range.create(start, src)); - } - return ans; -}; - -// node_modules/@spyglassmc/mcfunction/lib/parser/literal.js -function literal8(names, isRoot = false) { - const options2 = { - pool: names, - colorTokenType: isRoot ? "keyword" : "literal" - }; - return (src, ctx) => { - const start = src.cursor; - const value = src.readUntil(" ", "\r", "\n"); - if (!value.length) { - return Failure; - } - const ans = { - type: "mcfunction:command_child/literal", - range: Range.create(start, src), - options: options2, - value - }; - if (!names.includes(value)) { - ctx.err.report(localize("expected", names), ans); - } - return ans; - }; -} - -// node_modules/@spyglassmc/mcfunction/lib/parser/command.js -function command2(tree2, argument2, options2 = {}) { - return (src, ctx) => { - const ans = { - type: "mcfunction:command", - range: Range.create(src), - children: [], - options: options2 - }; - const start = src.cursor; - const innerStart = src.innerCursor; - if (src.trySkip("/")) { - ans.slash = Range.create(start, src.cursor); - if (!options2.slash) { - ctx.err.report(localize("mcfunction.parser.leading-slash.unexpected"), ans.slash, ErrorSeverity.Error, { - codeAction: { - title: localize("code-action.remove-leading-slash"), - isPreferred: true, - changes: [ - { - type: "edit", - range: ans.slash, - text: "" - } - ] - } - }); - } - } else if (options2.slash === "required") { - ctx.err.report(localize("expected", localize("mcfunction.parser.leading-slash")), Range.create(start, start + 1), ErrorSeverity.Error, { - codeAction: { - title: localize("code-action.add-leading-slash"), - isPreferred: true, - changes: [ - { - type: "edit", - range: Range.create(start), - text: "/" - } - ] - } - }); - } - dispatch2(ans.children, src, ctx, [], tree2, tree2, argument2); - if (src.canReadInLine()) { - const node = trailing(src, ctx); - ans.children.push({ - type: "mcfunction:command_child", - range: node.range, - children: [node], - path: [] - }); - } - ans.range.end = src.cursor; - if (options2.maxLength) { - const commandLength = src.innerCursor - innerStart; - if (commandLength > options2.maxLength) { - ctx.err.report(localize("mcfunction.parser.command-too-long", commandLength, options2.maxLength), ans); - } - } - return ans; - }; -} -function dispatch2(ans, src, ctx, path6, rootTreeNode, parentTreeNode, argument2) { - function _dispatch(path7, parentTreeNode2) { - const { treeNode: parent, path: resolvedPath } = resolveParentTreeNode(parentTreeNode2, rootTreeNode, path7); - path7 = resolvedPath; - const children = parent?.children; - if (!children) { - return false; - } - const { literalTreeNodes, argumentTreeNodes } = categorizeTreeChildren(children); - const argumentParsers = argumentTreeNodes.map(([name, treeNode]) => ({ name, parser: argument2(treeNode, ans) ?? unknown(treeNode) })); - const literalParser = literalTreeNodes.length ? literal8(literalTreeNodes.map(([name, _treeNode]) => name), parent.type === "root") : void 0; - const parsers = [ - ...literalParser ? [literalParser] : [], - ...argumentParsers.map((v) => v.parser) - ]; - const out = { index: 0 }; - if (parsers.length === 0) { - return false; - } - const parser = parsers.length > 1 ? any3(parsers, out) : parsers[0]; - const result2 = parser(src, ctx); - if (result2 !== Failure) { - const takenName = argumentParsers[out.index - (literalParser ? 1 : 0)]?.name ?? result2.value; - const childPath = [...path7, takenName]; - ans.push({ - type: "mcfunction:command_child", - range: result2.range, - children: [result2], - path: childPath - }); - const childTreeNode = children[takenName]; - if (!childTreeNode) { - return false; - } - const requiredPermissionLevel = childTreeNode.permission ?? 2; - if (ctx.config.env.permissionLevel < requiredPermissionLevel) { - ctx.err.report(localize("mcfunction.parser.no-permission", requiredPermissionLevel, ctx.config.env.permissionLevel), result2); - } - if (result2.type === "mcfunction:command_child/unknown") { - return false; - } - if (src.canReadInLine()) { - sep(src, ctx); - return { childPath, childTreeNode }; - } else { - if (!childTreeNode.executable) { - ctx.err.report(localize("mcfunction.parser.eoc-unexpected"), src); - } - } - } else { - ctx.err.report(localize("expected", treeNodeChildrenToString(children)), Range.create(src)); - } - return false; - } - let result = _dispatch(path6, parentTreeNode); - while (result) { - result = _dispatch(result.childPath, result.childTreeNode); - } -} -function unknown(treeNode) { - return (src, ctx) => { - const start = src.cursor; - const value = src.readUntilLineEnd(); - const range3 = Range.create(start, src); - ctx.err.report(localize("mcfunction.parser.unknown-parser", localeQuote(treeNode.parser)), range3, ErrorSeverity.Hint); - return { type: "mcfunction:command_child/unknown", range: range3, value }; - }; -} -var trailing = (src, ctx) => { - const start = src.cursor; - const value = src.readUntilLineEnd(); - const range3 = Range.create(start, src); - ctx.err.report(localize("mcfunction.parser.trailing", localeQuote(value)), range3); - return { type: "mcfunction:command_child/trailing", range: range3, value }; -}; -function wrapWithBrackets(syntax2, executable) { - return executable ? `[${syntax2}]` : syntax2; -} -function treeNodeChildrenToStringArray(children, executable = false) { - const entries = Object.entries(children).map(([name, treeNode]) => wrapWithBrackets(treeNodeToString(name, treeNode), executable)); - return entries; -} -function treeNodeChildrenToString(children) { - const entries = treeNodeChildrenToStringArray(children); - return entries.length > 5 ? `${entries.slice(0, 3).join("|")}|...|${entries.slice(-2).join("|")}` : entries.join("|"); -} -function treeNodeToString(name, treeNode) { - if (treeNode.type === "argument") { - return argumentTreeNodeToString(name, treeNode); - } else { - return name; - } -} - -// node_modules/@spyglassmc/mcfunction/lib/parser/macro.js -function macro2(hasPrefix = true) { - return (src, ctx) => { - const ans = { - type: "mcfunction:macro", - range: Range.create(src.cursor), - children: [] - }; - let start = src.cursor; - let hasMacroArgs = false; - if (hasPrefix) { - if (src.trySkip("$")) { - ans.children.push({ - type: "mcfunction:macro/prefix", - range: Range.create(start, src) - }); - start = src.cursor; - } else { - ctx.err.report(localize("expected", localeQuote("$")), ans); - } - } - while (src.canReadInLine()) { - src.skipUntilOrEnd(LF, CR, "$"); - if (src.peek(2) === "$(") { - hasMacroArgs = true; - const other = src.sliceToCursor(start); - if (other.length > 0) { - ans.children.push({ - type: "mcfunction:macro/other", - range: Range.create(start, src), - value: other - }); - start = src.cursor; - } - const key2 = validateMacroArgument(src, ctx, start); - ans.children.push({ - type: "mcfunction:macro/argument", - range: Range.create(start, src.cursor), - value: key2 - }); - start = src.cursor; - } else { - if (src.peek() === "$") { - src.skip(); - } - if (!src.canReadInLine()) { - ans.children.push({ - type: "mcfunction:macro/other", - range: Range.create(start, src), - value: src.sliceToCursor(start) - }); - } - } - } - if (!hasMacroArgs) { - ctx.err.report(localize("expected", localize("mcfunction.parser.macro.at-least-one")), Range.create(start, src)); - } - ans.range.end = src.cursor; - return ans; - }; -} -function validateMacroArgument(src, ctx, start) { - src.skip(2); - const keyStart = src.cursor; - src.skipUntilOrEnd(LF, CR, ")"); - if (src.peek() !== ")") { - ctx.err.report(localize("expected", localeQuote(")")), Range.create(keyStart, src.cursor)); - } else if (src.cursor <= keyStart) { - ctx.err.report(localize("expected", localize("mcfunction.parser.macro.key")), Range.create(start, src.cursor + 1)); - } - const key2 = src.sliceToCursor(keyStart); - const matchedInvalid = key2.replace(/[a-zA-Z0-9_]*/, ""); - if (matchedInvalid.length > 0) { - ctx.err.report(localize("mcfunction.parser.macro.illegal-key", matchedInvalid.charAt(0)), Range.create(keyStart, src.cursor)); - } - src.skip(); - return key2; -} - -// node_modules/@spyglassmc/mcfunction/lib/parser/entry.js -function mcfunction(commandTree, argument2, options2) { - return (src, ctx) => { - const ans = { - type: "mcfunction:entry", - range: Range.create(src), - children: [] - }; - while (src.skipWhitespace().canReadInLine()) { - let result; - if (src.peek() === "#") { - result = comment5(src, ctx); - } else if (src.peek() === "$") { - const start = src.cursor; - if (options2.macros) { - result = macro2()(src, ctx); - } else { - src.skipLine(); - ans.range.end = src.cursor; - result = { - type: "error", - range: Range.create(start, src) - }; - ctx.err.report(localize("mcfunction.parser.macro.disallowed"), result); - } - } else { - result = command2(commandTree, argument2, options2.commandOptions)(src, ctx); - } - ans.children.push(result); - src.nextLine(); - } - ans.range.end = src.cursor; - return ans; - }; -} -var comment5 = comment3({ singleLinePrefixes: /* @__PURE__ */ new Set(["#"]) }); -var entry4 = (commandTree, argument2, options2 = {}) => { - const parser = mcfunction(commandTree, argument2, options2); - return options2.lineContinuation ? concatOnTrailingBackslash(parser) : parser; -}; - -// node_modules/@spyglassmc/mcfunction/lib/index.js -var initialize4 = ({ meta }) => { - register11(meta); - meta.registerCompleter("mcfunction:command_child/literal", builtin_exports5.literal); -}; - -// node_modules/@spyglassmc/java-edition/lib/common/index.js -function getUris(category, id, ctx) { - return ctx.symbols.query(ctx.doc, category, ResourceLocation.lengthen(id)).symbol?.definition?.map((v) => v.uri) ?? []; -} -function getTagValues(category, id, ctx) { - const resolveValueNode = (node) => JsonStringNode.is(node) ? node.value : node.children.find((n) => n.key?.value === "id").value.value; - const set = getUris(category, id, ctx).reduce((ans, uri) => { - const result = void 0; - if (!result || result.node.parserErrors.length || result.node.checkerErrors?.length) { - return ans; - } - const rootNode = result.node.children[0]; - const replaceNode = rootNode.children.find((n) => n.key?.value === "replace")?.value; - const valuesNode = rootNode.children.find((n) => n.key?.value === "values")?.value; - const replace = replaceNode?.value; - const values = valuesNode.children.map((n) => ResourceLocation.lengthen(resolveValueNode(n.value))); - if (replace) { - ans = /* @__PURE__ */ new Set(); - } - for (const value of values) { - ans.add(value); - } - return ans; - }, /* @__PURE__ */ new Set()); - return [...set]; -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/node/argument.js -var BlockStatesNode; -(function(BlockStatesNode2) { - function is(node) { - return node.type === "mcfunction:block/states"; - } - BlockStatesNode2.is = is; -})(BlockStatesNode || (BlockStatesNode = {})); -var BlockNode; -(function(BlockNode2) { - function is(node) { - return node?.type === "mcfunction:block"; - } - BlockNode2.is = is; - function mock(range3, isPredicate) { - const id = ResourceLocationNode.mock(range3, { category: "block", allowTag: isPredicate }); - return { - type: "mcfunction:block", - range: Range.get(range3), - children: [id], - id, - isPredicate: false - }; - } - BlockNode2.mock = mock; -})(BlockNode || (BlockNode = {})); -var CoordinateNode; -(function(CoordinateNode2) { - function mock(range3) { - return { type: "mcfunction:coordinate", range: Range.get(range3), notation: "", value: 0 }; - } - CoordinateNode2.mock = mock; - function toDegree(node) { - const value = node.value % 360; - return value >= 180 ? value - 360 : value < -180 ? value + 360 : value; - } - CoordinateNode2.toDegree = toDegree; -})(CoordinateNode || (CoordinateNode = {})); -var EntitySelectorArgumentsNode; -(function(EntitySelectorArgumentsNode2) { - function is(node) { - return node.type === "mcfunction:entity_selector/arguments"; - } - EntitySelectorArgumentsNode2.is = is; -})(EntitySelectorArgumentsNode || (EntitySelectorArgumentsNode = {})); -var EntitySelectorVariables = ["a", "e", "p", "r", "s", "n"]; -var EntitySelectorVariable; -(function(EntitySelectorVariable2) { - function is(value) { - return EntitySelectorVariables.includes(value); - } - EntitySelectorVariable2.is = is; -})(EntitySelectorVariable || (EntitySelectorVariable = {})); -var EntitySelectorAtVariables = EntitySelectorVariables.map((v) => `@${v}`); -var EntitySelectorAtVariable; -(function(EntitySelectorAtVariable2) { - function is(value) { - return EntitySelectorAtVariables.includes(value); - } - EntitySelectorAtVariable2.is = is; - function filterAvailable(ctx) { - const release = ctx.project["loadedVersion"]; - return EntitySelectorAtVariables.filter((variable) => !(variable === "@n" && release && ReleaseVersion.cmp(release, "1.21") < 0)); - } - EntitySelectorAtVariable2.filterAvailable = filterAvailable; -})(EntitySelectorAtVariable || (EntitySelectorAtVariable = {})); -var EntitySelectorNode; -(function(EntitySelectorNode2) { - function is(node) { - return node?.type === "mcfunction:entity_selector"; - } - EntitySelectorNode2.is = is; - function mock(range3, options2) { - const literal9 = LiteralNode.mock(range3, options2); - return { - type: "mcfunction:entity_selector", - range: Range.get(range3), - children: [literal9], - variable: "e" - }; - } - EntitySelectorNode2.mock = mock; - EntitySelectorNode2.ArgumentKeys = /* @__PURE__ */ new Set([ - "advancements", - "distance", - "gamemode", - "level", - "limit", - "name", - "nbt", - "predicate", - "scores", - "sort", - "tag", - "team", - "type", - "x", - "y", - "z", - "dx", - "dy", - "dz", - "x_rotation", - "y_rotation" - ]); - function canKeyExist(selector3, argument2, key2) { - const hasKey = (key3) => !!argument2.children.find((p) => p.key?.value === key3); - const hasNonInvertedKey = (key3) => !!argument2.children.find((p) => p.key?.value === key3 && !p.value?.inverted); - switch (key2) { - case "advancements": - case "distance": - case "level": - case "scores": - case "x": - case "y": - case "z": - case "dx": - case "dy": - case "dz": - case "x_rotation": - case "y_rotation": - return hasKey(key2) ? 1 : 0; - case "gamemode": - case "name": - case "team": - return hasNonInvertedKey(key2) ? 1 : 0; - case "limit": - case "sort": - return selector3.currentEntity ? 2 : hasKey(key2) ? 1 : 0; - case "type": - return selector3.typeLimited ? hasKey(key2) ? 1 : 2 : 0; - } - return 0; - } - EntitySelectorNode2.canKeyExist = canKeyExist; -})(EntitySelectorNode || (EntitySelectorNode = {})); -var EntityNode; -(function(EntityNode2) { - function is(node) { - return node?.type === "mcfunction:entity"; - } - EntityNode2.is = is; -})(EntityNode || (EntityNode = {})); -var ItemStackNode; -(function(ItemStackNode2) { - function is(node) { - return node?.type === "mcfunction:item_stack"; - } - ItemStackNode2.is = is; - function mock(range3) { - const id = ResourceLocationNode.mock(range3, { category: "item" }); - return { type: "mcfunction:item_stack", range: Range.get(range3), children: [id], id }; - } - ItemStackNode2.mock = mock; -})(ItemStackNode || (ItemStackNode = {})); -var ComponentListNode; -(function(ComponentListNode2) { - function is(node) { - return node.type === "mcfunction:component_list"; - } - ComponentListNode2.is = is; -})(ComponentListNode || (ComponentListNode = {})); -var ComponentNode; -(function(ComponentNode2) { - function is(node) { - return node.type === "mcfunction:component"; - } - ComponentNode2.is = is; -})(ComponentNode || (ComponentNode = {})); -var ComponentRemovalNode; -(function(ComponentRemovalNode2) { - function is(node) { - return node.type === "mcfunction:component_removal"; - } - ComponentRemovalNode2.is = is; -})(ComponentRemovalNode || (ComponentRemovalNode = {})); -var ItemPredicateNode; -(function(ItemPredicateNode2) { - function is(node) { - return node?.type === "mcfunction:item_predicate"; - } - ItemPredicateNode2.is = is; - function mock(range3) { - const id = ResourceLocationNode.mock(range3, { category: "item", allowTag: true }); - return { type: "mcfunction:item_predicate", range: Range.get(range3), children: [id], id }; - } - ItemPredicateNode2.mock = mock; -})(ItemPredicateNode || (ItemPredicateNode = {})); -var ComponentTestsNode; -(function(ComponentTestsNode2) { - function is(node) { - return node.type === "mcfunction:component_tests"; - } - ComponentTestsNode2.is = is; -})(ComponentTestsNode || (ComponentTestsNode = {})); -var ComponentTestsAnyOfNode; -(function(ComponentTestsAnyOfNode2) { - function is(node) { - return node.type === "mcfunction:component_tests_any_of"; - } - ComponentTestsAnyOfNode2.is = is; -})(ComponentTestsAnyOfNode || (ComponentTestsAnyOfNode = {})); -var ComponentTestsAllOfNode; -(function(ComponentTestsAllOfNode2) { - function is(node) { - return node.type === "mcfunction:component_tests_all_of"; - } - ComponentTestsAllOfNode2.is = is; -})(ComponentTestsAllOfNode || (ComponentTestsAllOfNode = {})); -var ComponentTestExactNode; -(function(ComponentTestExactNode2) { - function is(node) { - return node.type === "mcfunction:component_test_exact"; - } - ComponentTestExactNode2.is = is; -})(ComponentTestExactNode || (ComponentTestExactNode = {})); -var ComponentTestExistsNode; -(function(ComponentTestExistsNode2) { - function is(node) { - return node.type === "mcfunction:component_test_exists"; - } - ComponentTestExistsNode2.is = is; -})(ComponentTestExistsNode || (ComponentTestExistsNode = {})); -var ComponentTestSubpredicateNode; -(function(ComponentTestSubpredicateNode2) { - function is(node) { - return node.type === "mcfunction:component_test_sub_predicate"; - } - ComponentTestSubpredicateNode2.is = is; -})(ComponentTestSubpredicateNode || (ComponentTestSubpredicateNode = {})); -var IntRangeNode2; -(function(IntRangeNode3) { - function mock(range3) { - return { - type: "mcfunction:int_range", - range: Range.get(range3), - children: [], - value: [void 0, void 0] - }; - } - IntRangeNode3.mock = mock; -})(IntRangeNode2 || (IntRangeNode2 = {})); -var NbtNode2; -(function(NbtNode3) { - function is(node) { - return node.type === "mcfunction:nbt"; - } - NbtNode3.is = is; -})(NbtNode2 || (NbtNode2 = {})); -var NbtPathNode2; -(function(NbtPathNode3) { - function is(node) { - return node.type === "mcfunction:nbt_path"; - } - NbtPathNode3.is = is; -})(NbtPathNode2 || (NbtPathNode2 = {})); -var NbtResourceNode; -(function(NbtResourceNode2) { - function is(node) { - return node.type === "mcfunction:nbt_resource"; - } - NbtResourceNode2.is = is; -})(NbtResourceNode || (NbtResourceNode = {})); -var ObjectiveCriteriaNode; -(function(ObjectiveCriteriaNode2) { - ObjectiveCriteriaNode2.SimpleValues = [ - "air", - "armor", - "deathCount", - "dummy", - "food", - "health", - "level", - "playerKillCount", - "totalKillCount", - "trigger", - "xp", - ...Color.ColorNames.map((n) => `killedByTeam.${n}`), - ...Color.ColorNames.map((n) => `teamkill.${n}`) - ]; - ObjectiveCriteriaNode2.ComplexCategories = /* @__PURE__ */ new Map([ - ["broken", "item"], - ["crafted", "item"], - ["custom", "custom_stat"], - ["dropped", "item"], - ["killed", "entity_type"], - ["killed_by", "entity_type"], - ["mined", "block"], - ["picked_up", "item"], - ["used", "item"] - ]); - ObjectiveCriteriaNode2.ComplexSep = ":"; - function mock(range3) { - return { type: "mcfunction:objective_criteria", range: Range.get(range3) }; - } - ObjectiveCriteriaNode2.mock = mock; -})(ObjectiveCriteriaNode || (ObjectiveCriteriaNode = {})); -var ParticleNode; -(function(ParticleNode2) { - const SpecialTypes = /* @__PURE__ */ new Set([ - "block", - "block_marker", - "dust", - "dust_color_transition", - "falling_dust", - "item", - "sculk_charge", - "shriek", - "vibration" - ]); - function isSpecialType(type2) { - return SpecialTypes.has(type2); - } - ParticleNode2.isSpecialType = isSpecialType; - const OptionTypes = /* @__PURE__ */ new Set([ - ...SpecialTypes, - "block_crumble", - "dust_pillar", - "entity_effect", - "trail" - ]); - function requiresOptions(type2, release) { - if (type2 === "flash" && ReleaseVersion.cmp(release, "1.21.9") >= 0) { - return true; - } - return OptionTypes.has(type2); - } - ParticleNode2.requiresOptions = requiresOptions; - function is(node) { - return node?.type === "mcfunction:particle"; - } - ParticleNode2.is = is; - function mock(range3) { - const id = ResourceLocationNode.mock(range3, { category: "particle_type" }); - return { type: "mcfunction:particle", range: Range.get(range3), children: [id], id }; - } - ParticleNode2.mock = mock; -})(ParticleNode || (ParticleNode = {})); -var ScoreHolderNode; -(function(ScoreHolderNode2) { - function mock(range3) { - const fakeName = SymbolNode.mock(range3, { category: "score_holder" }); - return { - type: "mcfunction:score_holder", - range: Range.get(range3), - children: [fakeName], - fakeName - }; - } - ScoreHolderNode2.mock = mock; -})(ScoreHolderNode || (ScoreHolderNode = {})); -var TimeNode; -(function(TimeNode2) { - TimeNode2.UnitToTicks = /* @__PURE__ */ new Map([["", 1], ["t", 1], ["s", 20], ["d", 24e3]]); - TimeNode2.Units = [...TimeNode2.UnitToTicks.keys()]; -})(TimeNode || (TimeNode = {})); -var VectorNode; -(function(VectorNode2) { - function mock(range3, options2) { - return { - type: "mcfunction:vector", - range: Range.get(range3), - children: [], - options: options2, - system: 0 - }; - } - VectorNode2.mock = mock; -})(VectorNode || (VectorNode = {})); - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/checker/index.js -var entry5 = (node, ctx) => { - const parts = dissectUri(ctx.doc.uri, ctx); - if (parts?.ok === false) { - reportDissectError(parts.path, parts.expected, ctx); - } - builtin_exports2.dispatchSync(node, ctx); -}; -var command3 = (node, ctx) => { - rootCommand(node.children, 0, ctx); -}; -function getEarlierNode(nodes, before, name) { - if (name === void 0) { - return void 0; - } - for (let i = before - 1; i > 0; i -= 1) { - if (nodes[i].path[nodes[i].path.length - 1] === name) { - return nodes[i].children[0]; - } - } - return void 0; -} -var rootCommand = (nodes, index4, ctx) => { - for (let i = 0; i < nodes.length; i += 1) { - const node = nodes[i].children[0]; - if (BlockNode.is(node)) { - block(node, ctx); - } else if (EntityNode.is(node)) { - entity(node, ctx); - } else if (ItemPredicateNode.is(node)) { - itemPredicate(node, ctx); - } else if (ItemStackNode.is(node)) { - itemStack(node, ctx); - } else if (ParticleNode.is(node)) { - particle(node, ctx); - } else if (NbtResourceNode.is(node)) { - nbtResource(node, ctx); - } else if (TypedJsonNode.is(node)) { - checker_exports3.typed(node, ctx); - } else if (TypedNbtNode.is(node)) { - checker_exports4.typed(node, ctx); - } else if (NbtNode2.is(node) && node.properties) { - const dispatchedBy = getEarlierNode(nodes, i, node.properties.dispatchedBy); - const indexedBy = getEarlierNode(nodes, i, node.properties.indexedBy); - nbtChecker(dispatchedBy, indexedBy)(node, ctx); - } else if (NbtPathNode2.is(node) && node.properties) { - const dispatchedBy = getEarlierNode(nodes, i, node.properties.dispatchedBy); - nbtPathChecker(dispatchedBy)(node, ctx); - } - } -}; -var block = (node, ctx) => { - if (!node.nbt) { - return; - } - const type2 = ResourceLocationNode.toString(node.id, "full"); - checker_exports4.index("minecraft:block", type2, { isPredicate: node.isPredicate })(node.nbt, ctx); -}; -var entity = (node, ctx) => { - for (const pair of node.selector?.arguments?.children ?? []) { - if (pair.key?.value !== "nbt" || !pair.value) { - continue; - } - const types = getTypesFromEntity(node, ctx); - if (!NbtCompoundNode.is(pair.value.value)) { - continue; - } - checker_exports4.index("minecraft:entity", types, { isPredicate: true })(pair.value.value, ctx); - } -}; -var itemPredicate = (node, ctx) => { - if (node.nbt) { - const type2 = ResourceLocationNode.toString(node.id, "full"); - checker_exports4.index("minecraft:item", type2, { isPredicate: true })(node.nbt, ctx); - } - if (!node.tests?.children) { - return; - } - const anyOfTest = node.tests.children[0]; - for (const allOfTest of anyOfTest.children) { - for (const test of allOfTest.children) { - const key2 = ResourceLocationNode.toString(test.key, "full"); - if (key2 === "minecraft:count" && !ComponentTestExistsNode.is(test) && test.value) { - const validInt = { kind: "int", valueRange: { kind: 0, min: 0 } }; - const type2 = { - kind: "union", - members: [ - validInt, - { - kind: "struct", - fields: [ - { kind: "pair", key: "min", optional: true, type: validInt }, - { kind: "pair", key: "max", optional: true, type: validInt } - ] - } - ] - }; - checker_exports4.typeDefinition(type2)(test.value, ctx); - } else if (ComponentTestExactNode.is(test) && test.value) { - checker_exports4.index("minecraft:data_component", key2)(test.value, ctx); - } else if (ComponentTestSubpredicateNode.is(test) && test.value) { - checker_exports4.index("minecraft:data_component_predicate", key2)(test.value, ctx); - } - } - } -}; -var itemStack = (node, ctx) => { - const itemId = ResourceLocationNode.toString(node.id, "full"); - if (node.nbt) { - checker_exports4.index("minecraft:item", itemId)(node.nbt, ctx); - } - if (!node.components) { - return; - } - const groupedComponents = /* @__PURE__ */ new Map(); - for (const child of node.components.children) { - if (!child.key) { - continue; - } - const componentId = ResourceLocationNode.toString(child.key, "full"); - if (!groupedComponents.has(componentId)) { - groupedComponents.set(componentId, []); - } - groupedComponents.get(componentId).push(child.key); - if (child.type === "mcfunction:component" && child.value) { - checker_exports4.index("minecraft:data_component", componentId)(child.value, ctx); - } - } - for (const [_, group] of groupedComponents) { - if (group.length > 1) { - for (const node2 of group) { - ctx.err.report(localize("mcfunction.parser.duplicate-components"), node2.range, ErrorSeverity.Warning); - } - } - } -}; -var nbtResource = (node, ctx) => { - const type2 = { - kind: "dispatcher", - registry: "minecraft:resource", - parallelIndices: [{ kind: "static", value: ResourceLocation.lengthen(node.category) }] - }; - checker_exports4.typeDefinition(type2)(node.children[0], ctx); -}; -function nbtChecker(dispatchedBy, indexedBy) { - return (node, ctx) => { - if (!node.properties) { - return; - } - const tag2 = node.children[0]; - if (indexedBy) { - if (NbtPathNode2.is(indexedBy)) { - const indexedByTypedef = indexedBy.children[0].endTypeDef; - const typeDef = indexedByTypedef && node.properties.isListIndex ? getListLikeChild(indexedByTypedef) : indexedByTypedef; - if (typeDef) { - checker_exports4.typeDefinition(typeDef, node.properties)(tag2, ctx); - } - } - return; - } - switch (node.properties.dispatcher) { - case "minecraft:entity": - if (NbtCompoundNode.is(tag2)) { - const types = EntityNode.is(dispatchedBy) || ResourceLocationNode.is(dispatchedBy) ? getTypesFromEntity(dispatchedBy, ctx) : void 0; - checker_exports4.index("minecraft:entity", types, { - isPredicate: node.properties.isPredicate, - isMerge: node.properties.isMerge - })(tag2, ctx); - } - break; - case "minecraft:block": - if (NbtCompoundNode.is(tag2)) { - checker_exports4.index("minecraft:block", void 0, { - isPredicate: node.properties.isPredicate, - isMerge: node.properties.isMerge - })(tag2, ctx); - } - break; - case "minecraft:storage": - if (NbtCompoundNode.is(tag2)) { - const storage = ResourceLocationNode.is(dispatchedBy) ? ResourceLocationNode.toString(dispatchedBy) : void 0; - checker_exports4.index("minecraft:storage", storage, { - isPredicate: node.properties.isPredicate, - isMerge: node.properties.isMerge - })(tag2, ctx); - } - break; - } - }; -} -function getListLikeChild(typeDef) { - switch (typeDef.kind) { - case "list": - return typeDef.item; - case "byte_array": - return { kind: "byte" }; - case "int_array": - return { kind: "int" }; - case "long_array": - return { kind: "long" }; - case "union": - const members = typeDef.members.map((m) => getListLikeChild(m)).filter((m) => m !== void 0); - if (members.length === 0) { - return void 0; - } - if (members.length === 1) { - return members[0]; - } - return { kind: "union", members }; - default: - return void 0; - } -} -function nbtPathChecker(dispatchedBy) { - return (node, ctx) => { - if (!node.properties) { - return; - } - const path6 = node.children[0]; - switch (node.properties.dispatcher) { - case "minecraft:entity": - const types = EntityNode.is(dispatchedBy) || ResourceLocationNode.is(dispatchedBy) ? getTypesFromEntity(dispatchedBy, ctx) : void 0; - checker_exports4.path("minecraft:entity", types)(path6, ctx); - break; - case "minecraft:block": - checker_exports4.path("minecraft:block", void 0)(path6, ctx); - break; - case "minecraft:storage": - const storage = ResourceLocationNode.is(dispatchedBy) ? ResourceLocationNode.toString(dispatchedBy) : void 0; - checker_exports4.path("minecraft:storage", storage)(path6, ctx); - break; - } - }; -} -var particle = (node, ctx) => { - const id = ResourceLocationNode.toString(node.id, "short"); - const release = ctx.project["loadedVersion"]; - if (!release || ReleaseVersion.cmp(release, "1.20.5") < 0) { - return; - } - const options2 = node.children?.find(NbtCompoundNode.is); - if (options2) { - checker_exports4.index("minecraft:particle", ResourceLocation.lengthen(id))(options2, ctx); - } else if (ParticleNode.requiresOptions(id, release)) { - ctx.err.report(localize("expected", localize("nbt.node.compound")), Range.create(node.id.range.end, node.id.range.end + 1)); - } -}; -function getTypesFromEntity(entity3, ctx) { - if (ResourceLocationNode.is(entity3)) { - const value = ResourceLocationNode.toString(entity3, "full", true); - if (value.startsWith(ResourceLocation.TagPrefix)) { - return getTagValues("tag/entity_type", value.slice(1), ctx); - } else { - return [value]; - } - } else if (entity3.playerName !== void 0 || entity3.selector?.playersOnly) { - return ["minecraft:player"]; - } else if (entity3.selector) { - const argumentsNode = entity3.selector.arguments; - if (!argumentsNode) { - return void 0; - } - let types = void 0; - for (const pairNode of argumentsNode.children) { - if (pairNode.key?.value !== "type") { - continue; - } - const valueNode = pairNode.value; - if (!valueNode || valueNode.inverted) { - continue; - } - const value = ResourceLocationNode.toString(valueNode.value, "full", true); - if (value.startsWith(ResourceLocation.TagPrefix)) { - const tagValues = getTagValues("tag/entity_type", value.slice(1), ctx); - if (types === void 0) { - types = tagValues.map(ResourceLocation.lengthen); - } else { - types = types.filter((t) => tagValues.includes(t)); - } - } else { - types = [value]; - } - } - return types; - } - return void 0; -} -function register12(meta) { - meta.registerChecker("mcfunction:entry", entry5); - meta.registerChecker("mcfunction:command", command3); - meta.registerChecker("mcfunction:block", block); - meta.registerChecker("mcfunction:entity", entity); - meta.registerChecker("mcfunction:item_stack", itemStack); - meta.registerChecker("mcfunction:item_predicate", itemPredicate); - meta.registerChecker("mcfunction:particle", particle); -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/colorizer/index.js -var objectiveCriterion = (node) => [ColorToken.create(node, "type")]; -var vector = (node) => { - return [ColorToken.create(node, "vector")]; -}; -function register13(meta) { - meta.registerColorizer("mcfunction:coordinate", builtin_exports4.number); - meta.registerColorizer("mcfunction:vector", vector); - meta.registerColorizer("mcfunction:objective_criteria", objectiveCriterion); -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/common/index.js -var ColorArgumentValues = [...Color.ColorNames, "reset"]; -var EntityAnchorArgumentValues = ["feet", "eyes"]; -var GamemodeArgumentValues = ["adventure", "survival", "creative", "spectator"]; -function getItemSlotArgumentValues(ctx) { - const release = ctx.project["loadedVersion"]; - const output = [ - ...[...Array(54).keys()].map((n) => `container.${n}`), - ...[...Array(27).keys()].map((n) => `enderchest.${n}`), - ...[...Array(15).keys()].map((n) => `horse.${n}`), - ...[...Array(9).keys()].map((n) => `hotbar.${n}`), - ...[...Array(27).keys()].map((n) => `inventory.${n}`), - "armor.chest", - "armor.feet", - "armor.head", - "armor.legs", - "horse.chest", - "weapon", - "weapon.mainhand", - "weapon.offhand" - ]; - if (ReleaseVersion.cmp(release, "1.20.5") >= 0) { - output.push(...[...Array(4).keys()].map((n) => `player.crafting.${n}`), "armor.body", "contents", "player.cursor"); - } else { - output.push("horse.armor"); - } - if (ReleaseVersion.cmp(release, "1.21.5") >= 0) { - output.push("saddle"); - } else { - output.push("horse.saddle"); - } - if (ReleaseVersion.cmp(release, "26.1") >= 0) { - output.push(...[...Array(8).keys()].map((n) => `mob.inventory.${n}`)); - } else { - output.push(...[...Array(8).keys()].map((n) => `villager.${n}`)); - } - return output; -} -function getItemSlotsArgumentValues(ctx) { - const release = ctx.project["loadedVersion"]; - const output = [ - ...getItemSlotArgumentValues(ctx), - "armor.*", - "container.*", - "enderchest.*", - "horse.*", - "hotbar.*", - "inventory.*", - "player.crafting.*", - "weapon.*" - ]; - if (ReleaseVersion.cmp(release, "26.1") >= 0) { - output.push("mob.inventory.*"); - } else { - output.push("villager.*"); - } - return output; -} -var OperationArgumentValues = ["=", "+=", "-=", "*=", "/=", "%=", "<", ">", "><"]; -function getScoreboardSlotArgumentValues(ctx) { - const release = ctx.project["loadedVersion"]; - return [ - ReleaseVersion.cmp(release, "1.20.2") < 0 ? "belowName" : "below_name", - "list", - "sidebar", - ...Color.ColorNames.map((n) => `sidebar.team.${n}`) - ]; -} -var SwizzleArgumentValues = [ - "x", - "xy", - "xz", - "xyz", - "xzy", - "y", - "yx", - "yz", - "yxz", - "yzx", - "z", - "zx", - "zy", - "zxy", - "zyx" -]; -var HeightmapValues = [ - "motion_blocking", - "motion_blocking_no_leaves", - "ocean_floor", - "world_surface" -]; -var RotationValues = ["none", "clockwise_90", "180", "counterclockwise_90"]; -var MirrorValues = ["none", "left_right", "front_back"]; - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/completer/argument.js -var getMockNodes = (rawTreeNode, prevNodes, ctx) => { - const range3 = ctx.offset; - const treeNode = rawTreeNode; - switch (treeNode.parser) { - case "brigadier:bool": - return BooleanNode.mock(range3); - case "brigadier:double": - case "brigadier:float": - case "brigadier:integer": - case "brigadier:long": - case "minecraft:float_range": - case "minecraft:message": - case "minecraft:time": - case "minecraft:uuid": - return []; - case "brigadier:string": - return treeNode.properties.type === "phrase" ? StringNode.mock(range3, BrigadierStringOptions) : []; - case "minecraft:angle": - return CoordinateNode.mock(range3); - case "minecraft:block_pos": - return VectorNode.mock(range3, { dimension: 3, integersOnly: true }); - case "minecraft:block_predicate": - return BlockNode.mock(range3, true); - case "minecraft:block_state": - return BlockNode.mock(range3, false); - case "minecraft:color": - return LiteralNode.mock(range3, { pool: ColorArgumentValues }); - case "minecraft:column_pos": - return VectorNode.mock(range3, { dimension: 2, integersOnly: true }); - case "minecraft:component": - return [ - JsonArrayNode.mock(range3), - JsonObjectNode.mock(range3), - JsonStringNode.mock(range3) - ]; - case "minecraft:dialog": - return ResourceLocationNode.mock(range3, { category: "dialog" }); - case "minecraft:dimension": - return ResourceLocationNode.mock(range3, { category: "dimension" }); - case "minecraft:entity": - case "minecraft:game_profile": - return EntitySelectorNode.mock(range3, { - pool: EntitySelectorAtVariable.filterAvailable(ctx) - }); - case "minecraft:heightmap": - return LiteralNode.mock(range3, { pool: HeightmapValues }); - case "minecraft:entity_anchor": - return LiteralNode.mock(range3, { pool: EntityAnchorArgumentValues }); - case "minecraft:entity_summon": - return ResourceLocationNode.mock(range3, { category: "entity_type" }); - case "minecraft:function": - return ResourceLocationNode.mock(range3, { category: "function" }); - case "minecraft:gamemode": - return LiteralNode.mock(range3, { pool: GamemodeArgumentValues }); - case "minecraft:int_range": - return IntRangeNode2.mock(range3); - case "minecraft:item_enchantment": - return ResourceLocationNode.mock(range3, { category: "enchantment" }); - case "minecraft:item_predicate": - return ItemPredicateNode.mock(range3); - case "minecraft:item_slot": - return LiteralNode.mock(range3, { pool: getItemSlotArgumentValues(ctx) }); - case "minecraft:item_slots": - return LiteralNode.mock(range3, { pool: getItemSlotsArgumentValues(ctx) }); - case "minecraft:item_stack": - return ItemStackNode.mock(range3); - case "minecraft:loot_modifier": - return ResourceLocationNode.mock(range3, { category: "item_modifier" }); - case "minecraft:loot_predicate": - return ResourceLocationNode.mock(range3, { category: "predicate" }); - case "minecraft:loot_table": - return ResourceLocationNode.mock(range3, { category: "loot_table" }); - case "minecraft:mob_effect": - return ResourceLocationNode.mock(range3, { category: "mob_effect" }); - case "minecraft:objective": - return SymbolNode.mock(range3, { category: "objective" }); - case "minecraft:objective_criteria": - return ObjectiveCriteriaNode.mock(range3); - case "minecraft:operation": - return LiteralNode.mock(range3, { - pool: OperationArgumentValues, - colorTokenType: "operator" - }); - case "minecraft:particle": - return ParticleNode.mock(range3); - case "minecraft:resource": - case "minecraft:resource_key": - case "minecraft:resource_or_tag": - case "minecraft:resource_or_tag_key": - const allowTag = treeNode.parser === "minecraft:resource_or_tag" || treeNode.parser === "minecraft:resource_or_tag_key"; - return ResourceLocationNode.mock(range3, { - category: ResourceLocation.shorten(treeNode.properties.registry), - allowTag - }); - case "minecraft:resource_location": - return ResourceLocationNode.mock(range3, treeNode.properties ?? { pool: [], allowUnknown: true }); - case "minecraft:rotation": - return VectorNode.mock(range3, { dimension: 2, noLocal: true }); - case "minecraft:scoreboard_slot": - return LiteralNode.mock(range3, { pool: getScoreboardSlotArgumentValues(ctx) }); - case "minecraft:score_holder": - return ScoreHolderNode.mock(range3); - case "minecraft:style": - return JsonObjectNode.mock(range3); - case "minecraft:swizzle": - return LiteralNode.mock(range3, { pool: SwizzleArgumentValues }); - case "minecraft:team": - return SymbolNode.mock(range3, { category: "team" }); - case "minecraft:team_color": - return LiteralNode.mock(range3, { pool: Color.ColorNames }); - case "minecraft:template_mirror": - return LiteralNode.mock(range3, { pool: MirrorValues }); - case "minecraft:template_rotation": - return LiteralNode.mock(range3, { pool: RotationValues }); - case "minecraft:vec2": - return VectorNode.mock(range3, { dimension: 2, integersOnly: true }); - case "minecraft:vec3": - return VectorNode.mock(range3, { dimension: 3 }); - case "spyglassmc:criterion": - const advancementNode = prevNodes.length > 0 ? prevNodes[prevNodes.length - 1].children[0] : void 0; - if (ResourceLocationNode.is(advancementNode)) { - return SymbolNode.mock(range3, { - category: "advancement", - subcategory: "criterion", - parentPath: [ResourceLocationNode.toString(advancementNode, "full")] - }); - } - return []; - case "spyglassmc:tag": - return SymbolNode.mock(range3, { category: "tag" }); - // ==== Unimplemented ==== - case "minecraft:nbt_compound_tag": - case "minecraft:nbt_path": - case "minecraft:nbt_tag": - default: - return []; - } -}; -var block2 = (node, ctx) => { - const ans = []; - if (Range.contains(node.id, ctx.offset, true)) { - ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); - } - if (node.states?.innerRange && Range.contains(node.states.innerRange, ctx.offset, true)) { - ans.push(...blockStates2(node.states, ctx)); - } - if (node.nbt?.innerRange && Range.contains(node.nbt.innerRange, ctx.offset, true)) { - ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); - } - return ans; -}; -var blockStates2 = (node, ctx) => { - if (!BlockNode.is(node.parent)) { - return []; - } - const idNode = node.parent.id; - const id = ResourceLocationNode.toString(idNode, "full"); - const blocks = idNode.isTag ? getTagValues("tag/block", id, ctx) : [id]; - const states = getStates("block", blocks, ctx); - return builtin_exports5.record({ - key: (_record, pair, _ctx, range3, insertValue, insertComma, existingKeys) => { - return Object.keys(states).filter((k) => pair?.key?.value === k || !existingKeys.some((ek) => ek.value === k)).map((k) => CompletionItem.create(k, range3, { - kind: 10, - detail: localize("mcfunction.completer.block.states.default-value", localeQuote(states[k][0])), - insertText: new InsertTextBuilder().literal(k).if(insertValue, (b) => b.literal("=").placeholder(...states[k])).if(insertComma, (b) => b.literal(",")).build() - })); - }, - value: (_record, pair, ctx2) => { - if (pair.key && states[pair.key.value]) { - return states[pair.key.value].map((v) => CompletionItem.create(v, pair.value ?? ctx2.offset, { - kind: 12 - /* CompletionKind.Value */ - })); - } - return []; - } - })(node, ctx); -}; -var componentList = (node, ctx) => { - if (!node.innerRange || !Range.contains(node.innerRange, ctx.offset, true)) { - return []; - } - const completeKey = (key2) => { - const id = key2 ?? ResourceLocationNode.mock(key2 ?? ctx.offset, { category: "data_component_type" }); - return builtin_exports5.resourceLocation(id, ctx); - }; - const index4 = binarySearch(node.children, ctx.offset, (n, o) => Range.compareOffset(n.range, o, true)); - const child = index4 >= 0 ? node.children[index4] : void 0; - if (!child) { - return [ - ...builtin_exports5.literal(LiteralNode.mock(ctx.offset, { pool: ["!"] }), ctx), - ...completeKey(void 0) - ]; - } - if (child.type === "mcfunction:component_removal") { - return completeKey(child.key); - } - if (child.key && Range.contains(child.key, ctx.offset, true)) { - return completeKey(child.key); - } - if (child.value && Range.contains(child.value, ctx.offset, true)) { - return builtin_exports5.dispatch(child.value, ctx); - } - return []; -}; -var componentTests = (node, ctx) => { - const test = AstNode.findShallowestChild({ - node, - needle: ctx.offset, - endInclusive: true, - predicate: (n) => ComponentTestExactNode.is(n) || ComponentTestSubpredicateNode.is(n) - }); - if (test && ComponentTestExactNode.is(test) && test.value) { - return builtin_exports5.dispatch(test.value, ctx); - } else if (test && ComponentTestSubpredicateNode.is(test) && test.value) { - return builtin_exports5.dispatch(test.value, ctx); - } - return []; -}; -var coordinate = (node, _ctx) => { - return [CompletionItem.create("~", node)]; -}; -var itemStack2 = (node, ctx) => { - const ans = []; - if (Range.contains(node.id, ctx.offset, true)) { - ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); - } - if (node.components && Range.contains(node.components, ctx.offset, true)) { - ans.push(...componentList(node.components, ctx)); - } - if (node.nbt && Range.contains(node.nbt, ctx.offset, true)) { - ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); - } - return ans; -}; -var itemPredicate2 = (node, ctx) => { - const ans = []; - if (Range.contains(node.id, ctx.offset, true)) { - ans.push(CompletionItem.create("*", node, { sortText: "##" })); - if (node.id.type === "resource_location") { - ans.push(...builtin_exports5.resourceLocation(node.id, ctx)); - } - } - if (node.tests && Range.contains(node.tests, ctx.offset, true)) { - ans.push(...componentTests(node.tests, ctx)); - } - if (node.nbt && Range.contains(node.nbt, ctx.offset, true)) { - ans.push(...builtin_exports5.dispatch(node.nbt, ctx)); - } - return ans; -}; -var objectiveCriteria = (node, ctx) => { - const ans = ObjectiveCriteriaNode.SimpleValues.map((v) => CompletionItem.create(v, node)); - if (!node.children?.[0] || Range.contains(node.children[0], ctx.offset, true)) { - ans.push(...builtin_exports5.resourceLocation(node.children?.[0] ?? ResourceLocationNode.mock(node, { category: "stat_type", namespacePathSep: "." }), ctx)); - } - if (node.children?.[1] && Range.contains(node.children[1], ctx.offset, true)) { - ans.push(...builtin_exports5.resourceLocation(node.children[1], ctx)); - } - return ans; -}; -var particle2 = (node, ctx) => { - const child = AstNode.findChild(node, ctx.offset, true); - if (child) { - return builtin_exports5.dispatch(child, ctx); - } - const release = ctx.project["loadedVersion"]; - if (!release || ReleaseVersion.cmp(release, "1.20.5") >= 0) { - return []; - } - const id = ResourceLocationNode.toString(node.id, "short"); - const map3 = { - block: [BlockNode.mock(ctx.offset, false)], - block_marker: [BlockNode.mock(ctx.offset, false)], - dust: [VectorNode.mock(ctx.offset, { dimension: 3 }), FloatNode.mock(ctx.offset)], - dust_color_transition: [ - VectorNode.mock(ctx.offset, { dimension: 3 }), - FloatNode.mock(ctx.offset), - VectorNode.mock(ctx.offset, { dimension: 3 }) - ], - falling_dust: [BlockNode.mock(ctx.offset, false)], - item: [ItemStackNode.mock(ctx.offset)], - sculk_charge: [FloatNode.mock(ctx.offset)], - shriek: [IntegerNode.mock(ctx.offset)], - vibration: [ - VectorNode.mock(ctx.offset, { dimension: 3 }), - VectorNode.mock(ctx.offset, { dimension: 3 }), - IntegerNode.mock(ctx.offset) - ] - }; - if (ParticleNode.isSpecialType(id)) { - const numParamsBefore = node.children?.slice(1).filter((n) => n.range.end < ctx.offset).length ?? 0; - const mock = map3[id][numParamsBefore]; - if (mock) { - return builtin_exports5.dispatch(mock, ctx); - } - } - return []; -}; -var scoreHolder = (node, ctx) => { - let ans; - if (node.selector && Range.contains(node.selector, ctx.offset, true)) { - ans = selector(node.selector, ctx); - if (Range.contains(node.children[0], ctx.offset, true)) { - ans.push(...builtin_exports5.symbol(SymbolNode.mock(node, { category: "score_holder" }), ctx)); - } - } else { - ans = builtin_exports5.symbol(node.fakeName ?? SymbolNode.mock(node, { category: "score_holder" }), ctx); - ans.push(...builtin_exports5.literal(LiteralNode.mock(node, { pool: ["*"] }), ctx), ...selector(EntitySelectorNode.mock(node, { pool: EntitySelectorAtVariable.filterAvailable(ctx) }), ctx)); - } - return ans; -}; -var selector = (node, ctx) => { - if (Range.contains(node.children[0], ctx.offset, true)) { - return builtin_exports5.literal(node.children[0], ctx); - } - if (node.arguments?.innerRange && Range.contains(node.arguments.innerRange, ctx.offset, true)) { - return selectorArguments(node.arguments, ctx); - } - return []; -}; -var selectorArguments = (node, ctx) => { - const selector3 = node.parent; - if (!EntitySelectorNode.is(selector3)) { - return []; - } - return builtin_exports5.record({ - key: (record3, pair, _ctx, range3, insertValue, insertComma) => { - return [...EntitySelectorNode.ArgumentKeys].filter( - (k) => EntitySelectorNode.canKeyExist(selector3, record3, k) === 0 - /* EntitySelectorNode.Result.Ok */ - ).map((k) => CompletionItem.create(k, range3, { - kind: 10, - insertText: new InsertTextBuilder().literal(k).if(insertValue, (b) => b.literal("=").placeholder()).if(insertComma, (b) => b.literal(",")).build() - })); - }, - value: (_record, pair, ctx2) => { - if (pair.value) { - return builtin_exports5.dispatch(pair.value, ctx2); - } - return []; - } - })(node, ctx); -}; -var intRange3 = (node, _ctx) => { - return [ - CompletionItem.create("-2147483648..2147483647", node, { - kind: 21 - /* CompletionKind.Constant */ - }) - ]; -}; -var vector2 = (node, _ctx) => { - const createCompletion = (coordinate3, sortText) => CompletionItem.create(new Array(node.options.dimension).fill(coordinate3).join(" "), node, { - sortText - }); - const ans = []; - ans.push(createCompletion("~", "a")); - if (!node.options.noLocal) { - ans.push(createCompletion("^", "b")); - } - ans.push(createCompletion("0.0", "c")); - return ans; -}; -function register14(meta) { - meta.registerCompleter("mcfunction:block", block2); - meta.registerCompleter("mcfunction:component_list", componentList); - meta.registerCompleter("mcfunction:component_tests", componentTests); - meta.registerCompleter("mcfunction:coordinate", coordinate); - meta.registerCompleter("mcfunction:entity_selector", selector); - meta.registerCompleter("mcfunction:entity_selector/arguments", selectorArguments); - meta.registerCompleter("mcfunction:int_range", intRange3); - meta.registerCompleter("mcfunction:item_stack", itemStack2); - meta.registerCompleter("mcfunction:item_predicate", itemPredicate2); - meta.registerCompleter("mcfunction:objective_criteria", objectiveCriteria); - meta.registerCompleter("mcfunction:particle", particle2); - meta.registerCompleter("mcfunction:score_holder", scoreHolder); - meta.registerCompleter("mcfunction:vector", vector2); -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/inlayHintProvider.js -var inlayHintProvider = (node, ctx) => { - if (node.children[0]?.type !== "mcfunction:entry") { - return []; - } - const ans = []; - traversePreOrder(node, (_) => true, CommandChildNode.is, (n) => { - const node2 = n; - const config = ctx.config.env.feature.inlayHint; - if (config === true || typeof config === "object" && config.enabledNodes.includes(node2.children[0].type)) { - ans.push({ - offset: node2.range.start, - label: `${node2.path[node2.path.length - 1]}:`, - paddingRight: true - }); - } - }); - return ans; -}; - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/parser/argument.js -var IntegerPattern = /^-?\d+$/; -var FloatPattern = /^-?(?:\d+\.?\d*|\.\d+)$/; -var DoubleMax = Number.MAX_VALUE; -var DoubleMin = -DoubleMax; -var FloatMax = (2 - 2 ** -23) * 2 ** 127; -var FloatMin = -FloatMax; -var IntegerMax = 2 ** 31 - 1; -var IntegerMin = -(2 ** 31); -var LongMax = 9223372036854775807n; -var LongMin = -9223372036854775808n; -var FakeNameMaxLength = 40; -var ObjectiveMaxLength = 16; -var PlayerNameMaxLength = 16; -function shouldValidateLength(ctx) { - const release = ctx.project["loadedVersion"]; - return !release || ReleaseVersion.cmp(release, "1.18") < 0; -} -function shouldUseOldItemStackFormat(ctx) { - const release = ctx.project["loadedVersion"]; - return !release || ReleaseVersion.cmp(release, "1.20.5") < 0; -} -var argument = (rawTreeNode, prevNodes) => { - const treeNode = rawTreeNode; - const wrap = (parser) => failOnEmpty(stopBefore(parser, "\r", "\n")); - switch (treeNode.parser) { - case "brigadier:bool": - return wrap(boolean4); - case "brigadier:double": - return wrap(double(treeNode.properties?.min, treeNode.properties?.max)); - case "brigadier:float": - return wrap(float4(treeNode.properties?.min, treeNode.properties?.max)); - case "brigadier:integer": - return wrap(integer4(treeNode.properties?.min, treeNode.properties?.max)); - case "brigadier:long": - return wrap(long4(treeNode.properties?.min, treeNode.properties?.max)); - case "brigadier:string": - switch (treeNode.properties.type) { - case "word": - return wrap(unquotedString); - case "phrase": - return wrap(brigadierString); - case "greedy": - default: - return wrap(greedyString); - } - case "minecraft:angle": - return wrap(validate(coordinate2(), (res) => res.notation !== "^", localize("mcfunction.parser.vector.local-disallowed"))); - case "minecraft:block_pos": - return wrap(vector3({ dimension: 3, integersOnly: true })); - case "minecraft:block_predicate": - return wrap(blockPredicate); - case "minecraft:block_state": - return wrap(blockState); - case "minecraft:color": - return wrap(map(commandLiteral({ pool: ColorArgumentValues }), (res) => ({ - ...res, - color: Color.NamedColors.has(res.value) ? Color.fromCompositeRGB(Color.NamedColors.get(res.value)) : void 0 - }))); - case "minecraft:column_pos": - return wrap(vector3({ dimension: 2, integersOnly: true })); - case "minecraft:component": - return wrap(typeRefParser("::java::server::util::text::Text")); - case "minecraft:dialog": - return wrap(resourceOrInline("dialog")); - case "minecraft:dimension": - return wrap(resourceLocation6({ category: "dimension" })); - case "minecraft:entity": - return wrap(entity2(treeNode.properties.amount, treeNode.properties.type)); - case "minecraft:entity_anchor": - return wrap(commandLiteral({ pool: EntityAnchorArgumentValues })); - case "minecraft:entity_summon": - return wrap(resourceLocation6({ category: "entity_type" })); - case "minecraft:float_range": - return wrap(range2("float", treeNode.properties?.min, treeNode.properties?.max, treeNode.properties?.minSpan, treeNode.properties?.maxSpan)); - case "minecraft:function": - return wrap(resourceLocation6({ category: "function", allowTag: true })); - case "minecraft:gamemode": - return wrap(commandLiteral({ pool: GamemodeArgumentValues })); - case "minecraft:game_profile": - return wrap(entity2("multiple", "players")); - case "minecraft:heightmap": - return wrap(commandLiteral({ pool: HeightmapValues })); - case "minecraft:int_range": - return wrap(range2("integer", treeNode.properties?.min, treeNode.properties?.max, treeNode.properties?.minSpan, treeNode.properties?.maxSpan)); - case "minecraft:item_enchantment": - return wrap(resourceLocation6({ category: "enchantment" })); - case "minecraft:item_predicate": - return wrap(itemPredicate3); - case "minecraft:item_slot": - return wrap((src, ctx) => { - return commandLiteral({ pool: getItemSlotArgumentValues(ctx) })(src, ctx); - }); - case "minecraft:item_slots": - return wrap((src, ctx) => { - return commandLiteral({ pool: getItemSlotsArgumentValues(ctx) })(src, ctx); - }); - case "minecraft:item_stack": - return wrap(itemStack3); - case "minecraft:loot_modifier": - return wrap(resourceOrInline("item_modifier")); - case "minecraft:loot_predicate": - return wrap(resourceOrInline("predicate")); - case "minecraft:loot_table": - return wrap(resourceOrInline("loot_table")); - case "minecraft:message": - return wrap(message); - case "minecraft:mob_effect": - return wrap(resourceLocation6({ category: "mob_effect" })); - case "minecraft:nbt_compound_tag": - return wrap(nbtDispatchedParser(parser_exports3.compound, treeNode.properties)); - case "minecraft:nbt_path": - return wrap(nbtPathParser(parser_exports3.path, treeNode.properties)); - case "minecraft:nbt_tag": - return wrap(nbtDispatchedParser(parser_exports3.entry, treeNode.properties)); - case "minecraft:objective": - return wrap(objective(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); - case "minecraft:objective_criteria": - return wrap(objectiveCriteria2); - case "minecraft:operation": - return wrap(commandLiteral({ pool: OperationArgumentValues, colorTokenType: "operator" })); - case "minecraft:particle": - return wrap(particle3); - case "minecraft:resource": - case "minecraft:resource_key": - case "minecraft:resource_or_tag": - case "minecraft:resource_or_tag_key": - const allowTag = treeNode.parser === "minecraft:resource_or_tag" || treeNode.parser === "minecraft:resource_or_tag_key"; - return wrap(resourceLocation6({ - category: ResourceLocation.shorten(treeNode.properties.registry), - allowTag - })); - case "minecraft:resource_location": - return wrap(resourceLocation6(treeNode.properties ?? { pool: [], allowUnknown: true })); - case "minecraft:resource_selector": - return wrap(resourceSelector(treeNode.properties.registry)); - case "minecraft:rotation": - return wrap(vector3({ dimension: 2, noLocal: true })); - case "minecraft:score_holder": - return wrap(scoreHolder2(treeNode.properties.usageType, treeNode.properties.amount)); - case "minecraft:scoreboard_slot": - return wrap((src, ctx) => { - return commandLiteral({ pool: getScoreboardSlotArgumentValues(ctx) })(src, ctx); - }); - case "minecraft:style": - return wrap(typeRefParser("::java::server::util::text::TextStyle")); - case "minecraft:swizzle": - return wrap(commandLiteral({ pool: SwizzleArgumentValues })); - case "minecraft:team": - return wrap(team(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); - case "minecraft:team_color": - return wrap(map(commandLiteral({ pool: Color.ColorNames }), (res) => ({ - ...res, - color: Color.NamedColors.has(res.value) ? Color.fromCompositeRGB(Color.NamedColors.get(res.value)) : void 0 - }))); - case "minecraft:template_mirror": - return wrap(commandLiteral({ pool: MirrorValues })); - case "minecraft:template_rotation": - return wrap(commandLiteral({ pool: RotationValues })); - case "minecraft:time": - return wrap(time); - case "minecraft:uuid": - return wrap(uuid); - case "minecraft:vec2": - return wrap(vector3({ dimension: 2, noLocal: true })); - case "minecraft:vec3": - return wrap(vector3({ dimension: 3 })); - case "spyglassmc:criterion": - const advancementNode = prevNodes.length > 0 ? prevNodes[prevNodes.length - 1].children[0] : void 0; - if (ResourceLocationNode.is(advancementNode)) { - return wrap(criterion(ResourceLocationNode.toString(advancementNode, "full"), SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); - } - return wrap(greedyString); - case "spyglassmc:tag": - return wrap(tag(SymbolUsageType.is(treeNode.properties?.usageType) ? treeNode.properties?.usageType : void 0)); - default: - return void 0; - } -}; -function block3(isPredicate) { - return map(sequence([ - resourceLocation6({ category: "block", allowTag: isPredicate }), - optional(map(failOnEmpty(record2({ - start: "[", - pair: { - key: string4({ - ...BrigadierStringOptions, - colorTokenType: "property" - }), - sep: "=", - value: brigadierString, - end: ",", - trailingEnd: true - }, - end: "]" - })), (res) => ({ ...res, type: "mcfunction:block/states" }))), - optional(failOnEmpty(parser_exports3.compound)) - ]), (res) => { - const ans = { - type: "mcfunction:block", - range: res.range, - children: res.children, - id: res.children.find(ResourceLocationNode.is), - states: res.children.find(BlockStatesNode.is), - nbt: res.children.find(NbtCompoundNode.is), - isPredicate - }; - return ans; - }); -} -var blockState = block3(false); -var blockPredicate = block3(true); -function double(min2 = DoubleMin, max2 = DoubleMax) { - return float2({ pattern: FloatPattern, min: min2, max: max2 }); -} -function float4(min2 = FloatMin, max2 = FloatMax) { - return float2({ pattern: FloatPattern, min: min2, max: max2 }); -} -function integer4(min2 = IntegerMin, max2 = IntegerMax) { - return integer2({ pattern: IntegerPattern, min: min2, max: max2 }); -} -function long4(min2, max2) { - return long2({ - pattern: IntegerPattern, - min: BigInt(min2 ?? LongMin), - max: BigInt(max2 ?? LongMax) - }); -} -function coordinate2(integerOnly = false) { - return (src, ctx) => { - const ans = { - type: "mcfunction:coordinate", - notation: "", - range: Range.create(src), - value: 0 - }; - if (src.trySkip("^")) { - ans.notation = "^"; - } else if (src.trySkip("~")) { - ans.notation = "~"; - } - if (src.canReadInLine() && src.peek() !== " " || ans.notation === "") { - const result = (integerOnly && ans.notation === "" ? integer4 : double)()(src, ctx); - ans.value = Number(result.value); - } - ans.range.end = src.cursor; - return ans; - }; -} -function criterion(advancement, usageType, terminators = []) { - return unquotableSymbol({ category: "advancement", subcategory: "criterion", parentPath: [advancement], usageType }, terminators); -} -function entity2(amount, type2) { - return map(select([{ predicate: (src) => src.peek() === "@", parser: selector2() }, { - parser: any3([ - failOnError(uuid), - validateLength(brigadierString, PlayerNameMaxLength, "mcfunction.parser.entity-selector.player-name.too-long") - ]) - }]), (res, _src, ctx) => { - const ans = { type: "mcfunction:entity", range: res.range, children: [res] }; - if (StringNode.is(res)) { - ans.playerName = res; - } else if (EntitySelectorNode.is(res)) { - ans.selector = res; - } else { - ans.uuid = res; - } - if (amount === "single" && ans.selector && !ans.selector.single) { - ctx.err.report(localize("mcfunction.parser.entity-selector.multiple-disallowed"), ans); - } - if (type2 === "players" && (ans.uuid || ans.selector && !ans.selector.playersOnly && !ans.selector.currentEntity)) { - ctx.err.report(localize("mcfunction.parser.entity-selector.entities-disallowed"), ans); - } - return ans; - }); -} -var greedyString = string4({ - unquotable: { blockList: /* @__PURE__ */ new Set(["\n", "\r"]) } -}); -var itemStack3 = (src, ctx) => { - const oldFormat = shouldUseOldItemStackFormat(ctx); - return map(sequence([ - resourceLocation6({ category: "item" }), - oldFormat ? optional(failOnEmpty(parser_exports3.compound)) : optional(failOnEmpty(components)) - ]), (res) => { - const ans = { - type: "mcfunction:item_stack", - range: res.range, - children: res.children, - id: res.children.find(ResourceLocationNode.is), - components: res.children.find(ComponentListNode.is), - nbt: res.children.find(NbtCompoundNode.is) - }; - return ans; - })(src, ctx); -}; -var itemPredicate3 = (src, ctx) => { - const oldFormat = shouldUseOldItemStackFormat(ctx); - return map(sequence([ - oldFormat ? resourceLocation6({ category: "item", allowTag: true }) : any3([ - resourceLocation6({ category: "item", allowTag: true }), - literal("*") - ]), - oldFormat ? optional(failOnEmpty(parser_exports3.compound)) : optional(componentTests2) - ]), (res) => { - const ans = { - type: "mcfunction:item_predicate", - range: res.range, - children: res.children, - id: res.children.find(ResourceLocationNode.is) || res.children.find(LiteralNode.is), - tests: res.children.find(ComponentTestsNode.is), - nbt: res.children.find(NbtCompoundNode.is) - }; - return ans; - })(src, ctx); -}; -function typeRefParser(typeRef) { - return (src, ctx) => { - const release = ctx.project["loadedVersion"]; - if (!release || ReleaseVersion.cmp(release, "1.21.5") < 0) { - return jsonParser(typeRef)(src, ctx); - } - return nbtParser(typeRef)(src, ctx); - }; -} -function jsonParser(typeRef) { - return map(parser_exports2.entry, (res) => ({ - type: "json:typed", - range: res.range, - children: [res], - targetType: { kind: "reference", path: typeRef } - })); -} -function nbtParser(typeRef) { - return map(parser_exports3.entry, (res) => ({ - type: "nbt:typed", - range: res.range, - children: [res], - targetType: { kind: "reference", path: typeRef } - })); -} -function commandLiteral(options2) { - return (src, ctx) => { - const ans = literal(options2)(src, ctx); - if (ans.value.length === 0) { - ans.value = src.readUntil(...Whitespaces); - ans.range = Range.create(ans.range.start, src); - } - return ans; - }; -} -var message = (src, ctx) => { - const ans = { - type: "mcfunction:message", - range: Range.create(src), - children: [] - }; - while (src.canReadInLine()) { - if (EntitySelectorAtVariable.is(src.peek(2))) { - ans.children.push(selector2(true)(src, ctx)); - } else { - ans.children.push(stopBefore(greedyString, ...EntitySelectorAtVariable.filterAvailable(ctx))(src, ctx)); - } - } - return ans; -}; -function nbtDispatchedParser(parser, properties) { - return map(parser, (res) => { - const ans = { type: "mcfunction:nbt", range: res.range, children: [res], properties }; - return ans; - }); -} -function nbtPathParser(parser, properties) { - return map(parser, (res) => { - const ans = { - type: "mcfunction:nbt_path", - range: res.range, - children: [res], - properties - }; - return ans; - }); -} -var particle3 = (src, ctx) => { - const release = ctx.project["loadedVersion"]; - if (!release || ReleaseVersion.cmp(release, "1.20.5") >= 0) { - return map(sequence([ - resourceLocation6({ category: "particle_type" }), - optional(failOnEmpty(parser_exports3.compound)) - ]), (res) => { - const ans = { - type: "mcfunction:particle", - range: res.range, - children: res.children, - id: res.children.find(ResourceLocationNode.is) - }; - return ans; - })(src, ctx); - } - const sep2 = map(sep, () => []); - const vec = vector3({ dimension: 3 }); - const color = map(vec, (res) => ({ - ...res, - color: res.children.length === 3 ? { - value: Color.fromDecRGB(res.children[0].value, res.children[1].value, res.children[2].value), - format: [ColorFormat.DecRGB] - } : void 0 - })); - const map3 = { - block: blockState, - block_marker: blockState, - dust: sequence([color, float4()], sep2), - dust_color_transition: sequence([color, float4(), color], sep2), - falling_dust: blockState, - item: itemStack3, - sculk_charge: float4(), - shriek: integer4(), - vibration: sequence([vec, integer4()], sep2) - }; - return map(sequence([resourceLocation6({ category: "particle_type" }), { - get: (res) => { - return map3[ResourceLocationNode.toString(res.children[0], "short")]; - } - }], sep2), (res) => { - const ans = { - type: "mcfunction:particle", - range: res.range, - children: res.children, - id: res.children.find(ResourceLocationNode.is) - }; - return ans; - })(src, ctx); -}; -function range2(type2, min2, max2, minSpan, maxSpan, cycleable) { - const number5 = type2 === "float" ? float4(min2, max2) : integer4(min2, max2); - const low = failOnEmpty(stopBefore(number5, "..")); - const sep2 = failOnEmpty(literal({ pool: [".."], colorTokenType: "keyword" })); - const high = failOnEmpty(number5); - return map(any3([ - /* exactly */ - sequence([low]), - /* atLeast */ - sequence([low, sep2]), - /* atMost */ - sequence([sep2, high]), - /* between */ - sequence([low, sep2, high]) - ]), (res, _src, ctx) => { - const valueNodes = type2 === "float" ? res.children.filter(FloatNode.is) : res.children.filter(IntegerNode.is); - const sepNode = res.children.find(LiteralNode.is); - const ans = { - type: type2 === "float" ? "mcfunction:float_range" : "mcfunction:int_range", - range: res.range, - children: res.children, - value: sepNode ? valueNodes.length === 2 ? [valueNodes[0].value, valueNodes[1].value] : Range.endsBefore(valueNodes[0].range, sepNode.range.start) ? [valueNodes[0].value, void 0] : [void 0, valueNodes[0].value] : [valueNodes[0].value, valueNodes[0].value] - }; - if (!cycleable && ans.value[0] !== void 0 && ans.value[1] !== void 0 && ans.value[0] > ans.value[1]) { - ctx.err.report(localize("mcfunction.parser.range.min>max", ans.value[0], ans.value[1]), res); - } else if (minSpan !== void 0 || maxSpan !== void 0) { - const span = ans.value[0] !== void 0 && ans.value[1] !== void 0 ? Math.abs(ans.value[0] - ans.value[1]) : ans.value[0] ?? ans.value[1] ?? Infinity; - if (minSpan !== void 0 && span < minSpan) { - ctx.err.report(localize("mcfunction.parser.range.span-too-small", span, minSpan), res); - } else if (maxSpan !== void 0 && span > maxSpan) { - ctx.err.report(localize("mcfunction.parser.range.span-too-large", span, maxSpan), res); - } - } - return ans; - }); -} -function resourceOrInline(category) { - return select([{ - predicate: (src) => LegalResourceLocationCharacters.has(src.peek()), - parser: resourceLocation6({ category }) - }, { - parser: map(parser_exports3.entry, (res) => { - const ans = { - type: "mcfunction:nbt_resource", - range: res.range, - children: [res], - category - }; - return ans; - }) - }]); -} -var LegalResourceSelectorCharacters = /* @__PURE__ */ new Set([ - ...LegalResourceLocationCharacters, - ":", - "/", - "*", - "?" -]); -function resourceSelector(registry) { - return string4({ - colorTokenType: "resourceLocation", - unquotable: { allowList: LegalResourceSelectorCharacters } - }); -} -function selectorPrefix(ignoreInvalidPrefix) { - return (src, ctx) => { - const start = src.cursor; - let value; - if (ignoreInvalidPrefix) { - value = src.peek(2); - src.skip(2); - } else { - value = src.readUntil(" ", "\r", "\n", "["); - } - const allowedVariables = EntitySelectorAtVariable.filterAvailable(ctx); - const ans = { - type: "literal", - range: Range.create(start, src), - options: { pool: allowedVariables }, - value - }; - if (!allowedVariables.includes(value) && !ignoreInvalidPrefix) { - ctx.err.report(localize("mcfunction.parser.entity-selector.invalid", ans.value), ans); - } - return ans; - }; -} -function selector2(ignoreInvalidPrefix = false) { - let chunkLimited; - let currentEntity; - let dimensionLimited; - let playersOnly; - let predicates; - let single; - let typeLimited; - return map(sequence([failOnEmpty(selectorPrefix(ignoreInvalidPrefix)), { - get: (res) => { - const variable = LiteralNode.is(res.children?.[0]) ? res.children[0].value : void 0; - currentEntity = variable ? variable === "@s" : void 0; - playersOnly = variable ? variable === "@p" || variable === "@a" || variable === "@r" : void 0; - predicates = variable === "@e" ? ["Entity::isAlive"] : void 0; - single = variable ? ["@p", "@r", "@s", "@n"].includes(variable) : void 0; - typeLimited = playersOnly; - function invertable(parser) { - return map(sequence([ - optional(failOnEmpty(literal({ pool: ["!"], colorTokenType: "keyword" }))), - (src) => { - src.skipSpace(); - return void 0; - }, - parser - ]), (res2) => { - const ans = { - type: "mcfunction:entity_selector/arguments/value/invertable", - range: res2.range, - children: res2.children, - inverted: !!res2.children.find((n) => LiteralNode.is(n) && n.value === "!"), - value: res2.children.find((n) => !LiteralNode.is(n) || n.value !== "!") - }; - return ans; - }); - } - return optional(map(failOnEmpty(record2({ - start: "[", - pair: { - key: string4({ - ...BrigadierStringOptions, - value: { - parser: literal({ - pool: [...EntitySelectorNode.ArgumentKeys], - colorTokenType: "property" - }), - type: "literal" - } - }), - sep: "=", - value: { - get: (record3, key2) => { - const hasKey = (key3) => !!record3.children.find((p) => p.key?.value === key3); - const hasNonInvertedKey = (key3) => !!record3.children.find((p) => p.key?.value === key3 && !p.value?.inverted); - switch (key2?.value) { - case "advancements": - return map(record2({ - start: "{", - pair: { - key: resourceLocation6({ - category: "advancement" - }), - sep: "=", - value: { - get: (_, key3) => select([{ - predicate: (src) => src.peek() === "{", - parser: map(record2({ - start: "{", - pair: { - key: key3 ? criterion(ResourceLocationNode.toString(key3, "full"), "reference", ["}", ",", "="]) : unquotedString, - sep: "=", - value: boolean4, - end: ",", - trailingEnd: true - }, - end: "}" - }), (res2) => { - const ans = { - ...res2, - type: "mcfunction:entity_selector/arguments/advancements/criteria" - }; - return ans; - }) - }, { parser: boolean4 }]) - }, - end: ",", - trailingEnd: true - }, - end: "}" - }), (res2, _, ctx) => { - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - const ans = { - ...res2, - type: "mcfunction:entity_selector/arguments/advancements" - }; - return ans; - }); - case "distance": - return map(range2("float", 0), (res2, _, ctx) => { - dimensionLimited = true; - chunkLimited ??= !playersOnly && res2.value[1] !== void 0; - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "gamemode": - return map(invertable(string4({ - unquotable: BrigadierUnquotableOption, - value: { - type: "literal", - parser: literal(...GamemodeArgumentValues) - } - })), (res2, _, ctx) => { - playersOnly = true; - if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "limit": - return map(integer4(0), (res2, _, ctx) => { - single = res2.value <= 1; - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - if (currentEntity) { - ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); - } - return res2; - }); - case "level": - return map(range2("integer", 0), (res2, _, ctx) => { - playersOnly = true; - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "name": - return map(invertable(brigadierString), (res2, _, ctx) => { - if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "nbt": - return invertable(parser_exports3.compound); - case "predicate": - return invertable(resourceLocation6({ category: "predicate" })); - case "scores": - return map(record2({ - start: "{", - pair: { - key: objective("reference", [ - "[", - "=", - ",", - "]", - "{", - "}" - ]), - sep: "=", - value: range2("integer"), - end: ",", - trailingEnd: true - }, - end: "}" - }), (res2, _, ctx) => { - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - const ans = { - ...res2, - type: "mcfunction:entity_selector/arguments/scores" - }; - return ans; - }); - case "sort": - return map(string4({ - unquotable: BrigadierUnquotableOption, - value: { - type: "literal", - parser: literal("arbitrary", "furthest", "nearest", "random") - } - }), (res2, _, ctx) => { - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - if (currentEntity) { - ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); - } - return res2; - }); - case "tag": - return invertable(tag("reference", ["[", "=", ",", "]", "{", "}"])); - case "team": - return map(invertable(team("reference", ["[", "=", ",", "]", "{", "}"])), (res2, _, ctx) => { - if (res2.inverted ? hasNonInvertedKey(key2.value) : hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "type": - return map(invertable(resourceLocation6({ - category: "entity_type", - allowTag: true - })), (res2, _, ctx) => { - if (typeLimited) { - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } else { - ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.not-applicable", localeQuote(key2.value)), key2); - } - } else if (!res2.inverted && !res2.value.isTag) { - typeLimited = true; - if (ResourceLocationNode.toString(res2.value, "short") === "player") { - playersOnly = true; - } - } - return res2; - }); - case "x": - case "y": - case "z": - return map(double(), (res2, _, ctx) => { - dimensionLimited = true; - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "dx": - case "dy": - case "dz": - return map(double(), (res2, _, ctx) => { - dimensionLimited = true; - chunkLimited = !playersOnly; - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case "x_rotation": - case "y_rotation": - return map(range2("float", void 0, void 0, void 0, void 0, true), (res2, _, ctx) => { - if (hasKey(key2.value)) { - ctx.err.report(localize("duplicate-key", localeQuote(key2.value)), key2); - } - return res2; - }); - case void 0: - return () => Failure; - default: - return (_src, ctx) => { - ctx.err.report(localize("mcfunction.parser.entity-selector.arguments.unknown", localeQuote(key2.value)), key2); - return Failure; - }; - } - } - }, - end: ",", - trailingEnd: true - }, - end: "]" - })), (res2) => { - const ans = { - ...res2, - type: "mcfunction:entity_selector/arguments" - }; - return ans; - })); - } - }]), (res) => { - const ans = { - type: "mcfunction:entity_selector", - range: res.range, - children: res.children, - variable: res.children.find(LiteralNode.is).value.slice(1), - arguments: res.children.find(EntitySelectorArgumentsNode.is), - chunkLimited, - currentEntity, - dimensionLimited, - playersOnly, - predicates, - single, - typeLimited - }; - ans.hover = getEntitySelectorHover(ans); - return ans; - }); -} -function getEntitySelectorHover(node) { - const grades = /* @__PURE__ */ new Map([ - [0, "\u{1F922}"], - // Bad - [1, "\u{1F605}"], - // Normal - [2, "Good"], - // Good - [3, "Great"], - // Great - [4, "\u{1F60C}\u{1F44C}"] - // Excellent - ]); - let ans; - if (node.currentEntity) { - ans = `**Performance**: ${grades.get(4)} -- \`currentEntity\`: \`${node.currentEntity}\``; - } else { - const amountOfTrue = [node.chunkLimited, node.dimensionLimited, node.playersOnly, node.typeLimited].filter((v) => v).length; - ans = `**Performance**: ${grades.get(amountOfTrue)} -- \`chunkLimited\`: \`${!!node.chunkLimited}\` -- \`dimensionLimited\`: \`${!!node.dimensionLimited}\` -- \`playersOnly\`: \`${!!node.playersOnly}\` -- \`typeLimited\`: \`${!!node.typeLimited}\``; - } - if (node.predicates?.length) { - ans += ` - ------- -**Predicates**: -${node.predicates.map((p) => `- \`${p}\``).join("\n")}`; - } - return ans; -} -function scoreHolderFakeName(usageType) { - return validateLength(symbol6({ category: "score_holder", usageType }), FakeNameMaxLength, "mcfunction.parser.score_holder.fake-name.too-long"); -} -function scoreHolder2(usageType, amount) { - return map(select([ - { - predicate: (src) => src.peek() === "*" && (!src.canRead(2) || src.matchPattern(/^\s/, 1)), - parser: literal("*") - }, - { prefix: "@", parser: selector2() }, - { parser: scoreHolderFakeName(usageType) } - ]), (res, _src, ctx) => { - const ans = { - type: "mcfunction:score_holder", - range: res.range, - children: [res] - }; - if (SymbolNode.is(res)) { - ans.fakeName = res; - } else if (EntitySelectorNode.is(res)) { - ans.selector = res; - } else { - ans.wildcard = res; - } - if (amount === "single" && ans.selector && !ans.selector.single) { - ctx.err.report(localize("mcfunction.parser.entity-selector.multiple-disallowed"), ans); - } - return ans; - }); -} -function symbol6(options2, terminators = []) { - return stopBefore(symbol5(options2), Whitespaces, terminators); -} -function objective(usageType, terminators = []) { - return validateLength(unquotableSymbol({ category: "objective", usageType }, terminators), ObjectiveMaxLength, "mcfunction.parser.objective.too-long"); -} -var objectiveCriteria2 = map(any3([ - sequence([ - stopBefore(resourceLocation6({ category: "stat_type", namespacePathSep: "." }), ":"), - failOnEmpty(literal(":")), - { - get: (res) => { - if (ResourceLocationNode.is(res.children[0])) { - const category = ObjectiveCriteriaNode.ComplexCategories.get(ResourceLocationNode.toString(res.children[0], "short")); - if (category) { - return resourceLocation6({ category, namespacePathSep: "." }); - } - } - return resourceLocation6({ pool: [], allowUnknown: true, namespacePathSep: "." }); - } - } - ]), - literal(...ObjectiveCriteriaNode.SimpleValues) -]), (res) => { - const ans = { type: "mcfunction:objective_criteria", range: res.range }; - if (LiteralNode.is(res)) { - ans.simpleValue = res.value; - } else { - ans.children = res.children.filter(ResourceLocationNode.is); - } - return ans; -}); -function tag(usageType, terminators = []) { - return unquotableSymbol({ category: "tag", usageType }, terminators); -} -function team(usageType, terminators = []) { - return unquotableSymbol({ category: "team", usageType }, terminators); -} -function unquotableSymbol(options2, terminators) { - return validateUnquotable(symbol6(options2, terminators)); -} -var time = map(sequence([ - float4(0, void 0), - optional(failOnEmpty(literal(...TimeNode.Units))) -]), (res) => { - const valueNode = res.children.find(FloatNode.is); - const unitNode = res.children.find(LiteralNode.is); - const ans = { - type: "mcfunction:time", - range: res.range, - children: res.children, - value: valueNode.value, - unit: unitNode?.value - }; - return ans; -}); -var unquotedString = string4({ - unquotable: BrigadierUnquotableOption -}); -var UuidPattern = /^[0-9a-f]+-[0-9a-f]+-[0-9a-f]+-[0-9a-f]+-[0-9a-f]+$/i; -var uuid = (src, ctx) => { - const ans = { type: "mcfunction:uuid", range: Range.create(src), bits: [0n, 0n] }; - const raw = src.readUntil(" ", "\r", "\n", "\r"); - let isLegal = false; - if (raw.match(UuidPattern)) { - try { - const parts = raw.split("-").map((p) => BigInt(`0x${p}`)); - if (parts.every((p) => p <= LongMax)) { - isLegal = true; - ans.bits[0] = BigInt.asIntN(64, parts[0] << 32n | parts[1] << 16n | parts[2]); - ans.bits[1] = BigInt.asIntN(64, parts[3] << 48n | parts[4]); - } - } catch { - } - } - ans.range.end = src.cursor; - if (!isLegal) { - ctx.err.report(localize("mcfunction.parser.uuid.invalid"), ans); - } - return ans; -}; -function validateLength(parser, maxLength, localeKey) { - return (src, ctx) => { - if (!shouldValidateLength(ctx)) { - return parser(src, ctx); - } - return map(parser, (res, _src, ctx2) => { - if (res.value.length > maxLength) { - ctx2.err.report(localize(localeKey, maxLength), res); - } - return res; - })(src, ctx); - }; -} -function validateUnquotable(parser) { - return map(parser, (res, _src, ctx) => { - if (!res.value.match(BrigadierUnquotablePattern)) { - ctx.err.report(localize("parser.string.illegal-brigadier", localeQuote(res.value)), res); - } - return res; - }); -} -function vector3(options2) { - return (src, ctx) => { - const ans = { - type: "mcfunction:vector", - range: Range.create(src), - children: [], - options: options2, - system: 0 - }; - if (src.peek() === "^") { - ans.system = 1; - } - for (let i = 0; i < options2.dimension; i++) { - if (i > 0) { - sep(src, ctx); - } - const coord = options2.integersOnly ? coordinate2(options2.integersOnly)(src, ctx) : coordinate2(options2.integersOnly)(src, ctx); - ans.children.push(coord); - if (ans.system === 1 !== (coord.notation === "^")) { - ctx.err.report(localize("mcfunction.parser.vector.mixed"), coord); - } - } - if (options2.noLocal && ans.system === 1) { - ctx.err.report(localize("mcfunction.parser.vector.local-disallowed"), ans); - } - ans.range.end = src.cursor; - return ans; - }; -} -var components = (src, ctx) => { - const release = ctx.project["loadedVersion"]; - const allowComponentRemoval = !release || ReleaseVersion.cmp(release, "1.21") >= 0; - const ans = { - type: "mcfunction:component_list", - range: Range.create(src), - children: [] - }; - if (!src.trySkip("[")) { - return Failure; - } - ans.innerRange = Range.create(src); - src.skipWhitespace(); - while (src.canRead() && src.peek() !== "]") { - const start = src.cursor; - if (allowComponentRemoval && src.tryPeek("!")) { - const prefix = literal("!")(src, ctx); - src.skipWhitespace(); - const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); - ans.children.push({ - type: "mcfunction:component_removal", - range: Range.create(start, src), - children: [prefix, key2], - prefix, - key: key2 - }); - src.skipWhitespace(); - } else { - const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); - src.skipWhitespace(); - literal("=")(src, ctx); - src.skipWhitespace(); - const value = parser_exports3.entry(src, ctx); - if (value === Failure) { - ctx.err.report(localize("expected", localize("parser.record.value")), Range.create(src, () => src.skipUntilOrEnd(",", "]", "\r", "\n"))); - ans.children.push({ - type: "mcfunction:component", - range: Range.create(start, src), - children: [key2], - key: key2, - value: void 0 - }); - } else { - ans.children.push({ - type: "mcfunction:component", - range: Range.create(start, src), - children: [key2, value], - key: key2, - value - }); - } - src.skipWhitespace(); - } - if (src.trySkip(",")) { - src.skipWhitespace(); - if (src.peek() === "]") { - break; - } - } else { - break; - } - } - src.skipWhitespace(); - ans.innerRange.end = src.cursor; - literal("]")(src, ctx); - ans.range.end = src.cursor; - return ans; -}; -var componentTest = (src, ctx) => { - const start = src.cursor; - src.skipWhitespace(); - const negated = src.trySkip("!"); - src.skipWhitespace(); - const key2 = resourceLocation6({ category: "data_component_type" })(src, ctx); - src.skipWhitespace(); - if (ResourceLocationNode.toString(key2, "full") === "minecraft:count") { - key2.options.category = void 0; - key2.options.pool = ["minecraft:count"]; - } - if (src.trySkip("=")) { - src.skipWhitespace(); - const ans2 = { - type: "mcfunction:component_test_exact", - range: Range.create(start, src), - children: [key2], - key: key2, - negated - }; - const value = parser_exports3.entry(src, ctx); - if (value === Failure) { - ctx.err.report(localize("expected", localize("nbt.node")), src); - src.skipUntilOrEnd(",", "|", "]"); - } else { - ans2.children.push(value); - ans2.value = value; - } - src.skipWhitespace(); - ans2.range.end = src.cursor; - return ans2; - } - if (src.trySkip("~")) { - src.skipWhitespace(); - if (key2.options.category !== void 0) { - const release = ctx.project["loadedVersion"]; - if (release && ReleaseVersion.cmp(release, "1.21.5") < 0) { - key2.options.category = "item_sub_predicate_type"; - } else { - key2.options.category = "data_component_predicate_type"; - } - } - const ans2 = { - type: "mcfunction:component_test_sub_predicate", - range: Range.create(start, src), - children: [key2], - key: key2, - negated - }; - const predicate = parser_exports3.entry(src, ctx); - if (predicate === Failure) { - ctx.err.report(localize("expected", localize("nbt.node")), src); - src.skipUntilOrEnd(",", "|", "]"); - } else { - ans2.children.push(predicate); - ans2.value = predicate; - } - src.skipWhitespace(); - ans2.range.end = src.cursor; - return ans2; - } - const ans = { - type: "mcfunction:component_test_exists", - range: Range.create(start, src), - children: [key2], - key: key2, - negated - }; - return ans; -}; -var componentTestsAllOf = (src, ctx) => { - const ans = { - type: "mcfunction:component_tests_all_of", - range: Range.create(src), - children: [] - }; - while (src.canRead()) { - src.skipWhitespace(); - const testNode = componentTest(src, ctx); - ans.children.push(testNode); - src.skipWhitespace(); - if (src.peek() === ",") { - src.skip(); - } else if (src.peek() === "|" || src.peek() === "]") { - break; - } else { - ctx.err.report(localize("expected", localeQuote("]")), src); - src.skipUntilOrEnd(",", "|", "]"); - } - } - ans.range.end = src.cursor; - return ans; -}; -var componentTestsAnyOf = (src, ctx) => { - const ans = { - type: "mcfunction:component_tests_any_of", - range: Range.create(src), - children: [] - }; - while (src.canRead()) { - src.skipWhitespace(); - const allOfNode = componentTestsAllOf(src, ctx); - ans.children.push(allOfNode); - src.skipWhitespace(); - if (src.peek() === "|") { - src.skip(); - } else if (src.peek() === "]") { - break; - } else { - ctx.err.report(localize("expected", localeQuote("]")), src); - src.skipUntilOrEnd("|", "]"); - } - } - ans.range.end = src.cursor; - return ans; -}; -var componentTests2 = (src, ctx) => { - const ans = { - type: "mcfunction:component_tests", - range: Range.create(src) - }; - if (!src.trySkip("[")) { - return Failure; - } - src.skipWhitespace(); - const tests = optional(failOnEmpty(componentTestsAnyOf))(src, ctx); - if (tests) { - ans.children = [tests]; - } - src.skipWhitespace(); - literal("]")(src, ctx); - ans.range.end = src.cursor; - return ans; -}; - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/mcdocAttributes.js -var validator3 = runtime_exports.attribute.validator; -var commandValidator = validator3.alternatives(validator3.tree({ - slash: validator3.optional(validator3.options("allowed", "required", "chat")), - macro: validator3.optional(validator3.options("implicit")), - max_length: validator3.optional(validator3.number), - empty: validator3.optional(validator3.options("allowed")), - incomplete: validator3.optional(validator3.options("allowed")) -}), () => ({})); -var entityValidator = validator3.alternatives(validator3.tree({ - amount: validator3.options("multiple", "single"), - type: validator3.options("entities", "players") -}), () => ({ amount: "multiple", type: "entities" })); -var scoreHolderValidator = validator3.alternatives(validator3.tree({ - amount: validator3.options("multiple", "single") -}), () => ({ amount: "multiple" })); -function registerMcdocAttributes4(meta, rootTreeNode) { - runtime_exports.registerAttribute(meta, "command", commandValidator, { - // TODO: fix completer inside commands - stringParser: ({ slash, macro: macro3, max_length, empty, incomplete }) => { - return (src, ctx) => { - if (macro3) { - return macro2(false)(src, ctx); - } - if (empty && !src.canRead() || slash === "chat" && src.peek() !== "/") { - return string4({ - unquotable: { blockList: /* @__PURE__ */ new Set(), allowEmpty: true } - })(src, ctx); - } - const tmpCtx = { ...ctx, err: new ErrorReporter(ctx.err.source) }; - const result = command2(rootTreeNode, argument, { - slash: slash === "chat" ? "allowed" : slash, - maxLength: max_length - })(src, tmpCtx); - if (incomplete) { - tmpCtx.err.errors = tmpCtx.err.errors.filter((e) => e.range.end < result.range.end); - } - ctx.err.absorb(tmpCtx.err); - return result; - }; - } - }); - runtime_exports.registerAttribute(meta, "text_component", () => void 0, { - stringParser: () => makeInfallible2(map(parser_exports2.entry, (res) => ({ - type: "json:typed", - range: res.range, - children: [res], - targetType: { kind: "reference", path: "::java::server::util::text::Text" } - })), localize("text-component")) - }); - runtime_exports.registerAttribute(meta, "objective", () => void 0, { - stringParser: () => objective("reference"), - stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "objective" }) - }); - runtime_exports.registerAttribute(meta, "team", () => void 0, { - stringParser: () => team("reference"), - stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "team" }) - }); - runtime_exports.registerAttribute(meta, "score_holder", scoreHolderValidator, { - stringParser: (config) => makeInfallible2(scoreHolder2("reference", config.amount), localize("score-holder")), - stringMocker: (_, __, ctx) => ScoreHolderNode.mock(ctx.offset) - }); - runtime_exports.registerAttribute(meta, "tag", () => void 0, { - stringParser: () => tag("reference"), - stringMocker: (_, __, ctx) => SymbolNode.mock(ctx.offset, { category: "tag" }) - }); - runtime_exports.registerAttribute(meta, "block_predicate", () => void 0, { - stringParser: () => blockPredicate, - stringMocker: (_, __, ctx) => BlockNode.mock(ctx.offset, true) - }); - runtime_exports.registerAttribute(meta, "entity", entityValidator, { - stringParser: (config) => makeInfallible2(entity2(config.amount, config.type), localize("selector")), - stringMocker: (_, __, ctx) => EntitySelectorNode.mock(ctx.offset, { - pool: EntitySelectorAtVariable.filterAvailable(ctx) - }) - }); - runtime_exports.registerAttribute(meta, "item_slots", () => void 0, { - stringParser: (_, __, ctx) => literal({ pool: getItemSlotsArgumentValues(ctx) }), - stringMocker: (_, __, ctx) => LiteralNode.mock(ctx.offset, { pool: getItemSlotsArgumentValues(ctx) }) - }); - runtime_exports.registerAttribute(meta, "uuid", () => void 0, { - stringParser: () => uuid - }); -} -function makeInfallible2(parser, message2) { - return (src, ctx) => { - const start = src.cursor; - const res = parser(src, ctx); - if (res === Failure) { - ctx.err.report(localize("expected", message2), Range.create(start, src.skipRemaining())); - return void 0; - } - return res; - }; -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/signatureHelpProvider.js -function signatureHelpProvider(rootTreeNode) { - return (fileNode, ctx) => { - if (fileNode.children[0]?.type !== "mcfunction:entry") { - return void 0; - } - const node = getSelectedCommandNode(fileNode, ctx.offset); - if (!CommandNode.is(node)) { - return void 0; - } - const argumentNodes = node ? node.children : []; - const options2 = getOptions3(rootTreeNode, argumentNodes); - if (options2.length === 0) { - return void 0; - } - let selectedIndex = 0; - for (const child of argumentNodes) { - if (ctx.offset > child.range.end) { - selectedIndex += 1; - } else { - break; - } - } - if (selectedIndex >= options2[0].length) { - return void 0; - } - const ans = { activeSignature: 0, signatures: [] }; - ans.signatures = options2.map((v) => { - const part1 = v[selectedIndex]; - const part2 = selectedIndex + 1 < v.length ? ` ${v[selectedIndex + 1]}` : ""; - const label = `${part1}${part2}`; - return { - label, - activeParameter: 0, - // documentation: localize('mcfunction.signature-help.command-documentation', v[0]), - parameters: [{ label: [0, part1.length] }, { label: [part1.length, label.length] }] - }; - }); - return ans; - }; -} -function getSelectedCommandNode(fileNode, offset) { - return AstNode.findChild(fileNode.children[0], offset, true); -} -function getOptions3(rootTreeNode, argumentNodes) { - const current = []; - let treeNode = rootTreeNode; - for (const argumentNode of argumentNodes) { - const name = argumentNode.path[argumentNode.path.length - 1]; - if (!name) { - break; - } - treeNode = resolveParentTreeNode(treeNode, rootTreeNode).treeNode?.children?.[name]; - if (!treeNode) { - break; - } - current.push(treeNodeToString(name, treeNode)); - } - if (treeNode) { - treeNode = resolveParentTreeNode(treeNode, rootTreeNode).treeNode; - if (treeNode?.children) { - return treeNodeChildrenToStringArray(treeNode.children, treeNode.executable).map((v) => [...current, v]); - } - } - return current.length ? [current] : []; -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/tree/patch.js -function getPatch(release) { - return { - children: { - advancement: { - children: { - grant: AdvancementTargets, - revoke: AdvancementTargets - } - }, - ...ReleaseVersion.cmp(release, "1.16") >= 0 ? { - attribute: { - children: { - target: { - children: { - attribute: { - properties: { - category: "attribute" - }, - children: { - modifier: { - children: { - add: { - children: { - id: { - properties: { - category: "attribute_modifier" - } - }, - uuid: { - properties: { - category: "attribute_modifier_uuid" - } - } - } - }, - remove: { - children: { - id: { - properties: { - category: "attribute_modifier" - } - }, - uuid: { - properties: { - category: "attribute_modifier_uuid" - } - } - } - }, - value: { - children: { - get: { - children: { - id: { - properties: { - category: "attribute_modifier" - } - }, - uuid: { - properties: { - category: "attribute_modifier_uuid" - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } : {}, - ban: { - permission: 3 - }, - "ban-ip": { - permission: 3 - }, - banlist: { - permission: 3 - }, - bossbar: { - children: { - add: { - children: { - id: { - properties: { - category: "bossbar", - usageType: "definition" - } - } - } - }, - get: { - children: { - id: { - properties: { - category: "bossbar" - } - } - } - }, - remove: { - children: { - id: { - properties: { - category: "bossbar" - } - } - } - }, - set: { - children: { - id: { - properties: { - category: "bossbar", - accessType: 1 - } - } - } - } - } - }, - data: { - children: { - get: getDataPatch("target", "path"), - merge: getDataPatch("target", "nbt", { - isMerge: true, - vaultAccessType: 1 - }), - modify: getDataPatch("target", "targetPath", { - nbtAccessType: 1, - vaultAccessType: 1, - children: (type2) => ({ - append: getDataModifySource(type2, { - isListIndex: true - }), - insert: { - children: { - index: getDataModifySource(type2, { - isListIndex: true - }) - } - }, - merge: getDataModifySource(type2, { - isMerge: true - }), - prepend: getDataModifySource(type2, { - isListIndex: true - }), - set: getDataModifySource(type2) - }) - }), - remove: getDataPatch("target", "path", { - nbtAccessType: 1, - vaultAccessType: 1 - }) - } - }, - datapack: { - children: { - ...ReleaseVersion.cmp(release, "1.21.6") >= 0 ? { - // Added in 21w15a (1.21.6, pack format 72) - create: { - permission: 4 - } - } : {} - } - }, - debug: { - permission: 3 - }, - deop: { - permission: 3 - }, - execute: { - children: { - if: ExecuteCondition, - store: { - children: { - result: ExecuteStoreTarget, - success: ExecuteStoreTarget - } - }, - unless: ExecuteCondition - } - }, - ...ReleaseVersion.cmp(release, "1.21.9") >= 0 ? { - fetchprofile: { - children: { - id: { - children: { - id: { - properties: { - category: "player_uuid" - } - } - } - } - } - } - } : {}, - function: { - children: { - name: { - ...ReleaseVersion.cmp(release, "1.20.2") >= 0 ? { - children: { - // Added in 23w31a (1.20.2, pack format 16) - arguments: { - properties: { - dispatcher: "minecraft:macro_function", - dispatchedBy: "name" - } - }, - with: getDataPatch("source", "path") - } - } : {} - } - } - }, - ...ReleaseVersion.cmp(release, "1.17") >= 0 ? { - // Added in 20w46a (1.17, pack format 7) - item: { - children: { - replace: { - children: { - block: { - children: { - pos: { - children: { - slot: { - children: { - from: { - children: { - block: { - children: { - source: { - children: { - sourceSlot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - }, - entity: { - children: { - source: { - children: { - sourceSlot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - }, - entity: { - children: { - targets: { - children: { - slot: { - children: { - from: { - children: { - block: { - children: { - source: { - children: { - sourceSlot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - }, - entity: { - children: { - source: { - children: { - sourceSlot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - }, - modify: { - children: { - block: { - children: { - pos: { - children: { - slot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - }, - entity: { - children: { - targets: { - children: { - slot: { - children: { - modifier: { - properties: { - category: "item_modifier" - } - } - } - } - } - } - } - } - } - } - } - } - } : {}, - help: { - permission: 0 - }, - ...ReleaseVersion.cmp(release, "1.18") >= 0 ? { - // Added in 21w37a (1.18, pack format 8) - jfr: { - permission: 4 - } - } : {}, - kick: { - permission: 3 - }, - list: { - permission: 0 - }, - ...ReleaseVersion.isBetween(release, "1.16", "1.19") ? { - // Added in 20w06a (1.16, pack format 5) - // Removed in 22w19a (1.19, pack format 10) - locatebiome: { - children: { - biome: { - properties: { - category: "worldgen/biome", - // Allowed in 1.18.2-pre1 (1.18.2, pack format 9) - allowTag: ReleaseVersion.cmp(release, "1.18.2") >= 0 - } - } - } - } - } : {}, - loot: { - children: { - give: { - children: { - players: LootSource - } - }, - insert: { - children: { - targetPos: LootSource - } - }, - replace: { - children: { - block: { - children: { - targetPos: { - children: { - slot: { - children: { - ...LootSource.children, - count: LootSource - } - } - } - } - } - }, - entity: { - children: { - entities: { - children: { - slot: { - children: { - ...LootSource.children, - count: LootSource - } - } - } - } - } - } - } - }, - spawn: { - children: { - targetPos: LootSource - } - } - } - }, - me: { - permission: 0 - }, - msg: { - permission: 0 - }, - op: { - permission: 3 - }, - pardon: { - permission: 3 - }, - "pardon-ip": { - permission: 3 - }, - ...ReleaseVersion.cmp(release, "1.17") >= 0 ? { - // Added in 1.17 Pre-release 1 (1.17, pack format 7) - perf: { - permission: 4 - } - } : {}, - ...ReleaseVersion.cmp(release, "1.19") >= 0 ? { - // Added in 22w18a (1.19, pack format 10) - place: { - children: { - jigsaw: { - children: { - pool: { - children: { - target: { - properties: { - category: "jigsaw_block_name", - allowUnknown: true - } - } - } - } - } - }, - template: { - children: { - template: { - properties: { - category: "structure" - } - } - } - } - } - } - } : {}, - playsound: Sound, - publish: { - permission: 4 - }, - ...ReleaseVersion.cmp(release, "1.20.2") >= 0 ? { - // Added in 23w31a (1.20.2, pack format 16) - random: { - children: { - reset: { - children: { - sequence: { - properties: { - category: "random_sequence", - allowUnknown: true - } - } - } - }, - roll: { - children: { - range: { - properties: { - minSpan: 1, - maxSpan: 2147483646 - }, - children: { - sequence: { - properties: { - category: "random_sequence", - allowUnknown: true - } - } - } - } - } - }, - value: { - children: { - range: { - properties: { - minSpan: 1, - maxSpan: 2147483646 - }, - children: { - sequence: { - properties: { - category: "random_sequence", - allowUnknown: true - } - } - } - } - } - } - } - } - } : {}, - recipe: { - children: { - give: RecipeTargets, - take: RecipeTargets - } - }, - "save-all": { - permission: 4 - }, - "save-off": { - permission: 4 - }, - "save-on": { - permission: 4 - }, - schedule: { - children: { - clear: { - children: { - function: { - parser: "minecraft:function", - properties: void 0 - } - } - } - } - }, - scoreboard: { - children: { - objectives: { - children: { - add: { - children: { - objective: { - parser: "minecraft:objective", - properties: { - usageType: "definition" - } - } - } - } - } - }, - players: { - children: { - add: ObjectiveWriteTargets, - operation: ObjectiveWriteTargets, - remove: ObjectiveWriteTargets, - reset: ObjectiveWriteTargets, - set: ObjectiveWriteTargets - } - } - } - }, - setidletimeout: { - permission: 3 - }, - stop: { - permission: 4 - }, - stopsound: { - children: { - targets: { - children: { - "*": Sound, - ambient: Sound, - block: Sound, - hostile: Sound, - master: Sound, - music: Sound, - neutral: Sound, - player: Sound, - record: Sound, - ...ReleaseVersion.cmp(release, "1.21.9") >= 0 ? { - ui: Sound - } : {}, - voice: Sound, - weather: Sound - } - } - } - }, - ...ReleaseVersion.cmp(release, "1.21.11") >= 0 ? { - stopwatch: { - children: { - create: { - children: { - id: { - properties: { - category: "stopwatch", - usageType: "definition" - } - } - } - }, - query: { - children: { - id: { - properties: { - category: "stopwatch" - } - } - } - }, - remove: { - children: { - id: { - properties: { - category: "stopwatch" - } - } - } - }, - restart: { - children: { - id: { - properties: { - category: "stopwatch" - } - } - } - } - } - } - } : {}, - summon: { - children: { - entity: { - children: { - pos: { - children: { - nbt: { - properties: { - dispatcher: "minecraft:entity", - dispatchedBy: "entity" - } - } - } - } - } - } - } - }, - tag: { - children: { - targets: { - children: { - add: { - children: { - name: { - parser: "spyglassmc:tag" - } - } - }, - remove: { - children: { - name: { - parser: "spyglassmc:tag" - } - } - } - } - } - } - }, - team: { - children: { - add: { - children: { - team: { - parser: "minecraft:team", - properties: { - usageType: "definition" - } - } - } - } - } - }, - teammsg: { - permission: 0 - }, - /** - * Original command syntax: - * 1. `teleport ` - * 2. `teleport ` - * 3. `teleport <...arguments>` - * - * It is impossible for Spyglass to differentiate between (1) and (3) when it encounters a single entity - * at the position of the first argument, due to its lack of ability to backtrack. - * - * Therefore, we have compromised to patch the trees to something like this: - * - `teleport ` - * - `teleport [<...arguments>]` - * - * Diff: - * - Removed (1) `teleport `. - * - Marked `<...arguments>` in (3) as optional. - * - * The downside of this patch is that entity selectors tracking multiple entities can now be used as the - * `` argument. We will see how this work. - */ - teleport: { - children: { - destination: void 0, - targets: { - executable: true - } - } - }, - tell: { - permission: 0 - }, - ...ReleaseVersion.cmp(release, "1.21.5") >= 0 ? { - test: { - children: { - create: { - children: { - id: { - properties: { - category: "test_instance", - allowUnknown: true - } - } - } - } - } - } - } : {}, - ...ReleaseVersion.cmp(release, "1.20.3") >= 0 ? { - // Added in 23w43a (1.20.3, pack format 22) - tick: { - permission: 3 - } - } : {}, - tm: { - permission: 0 - }, - ...ReleaseVersion.cmp(release, "1.20.5") >= 0 ? { - // Added in 24w04a (1.20.5, pack format 29) - transfer: { - permission: 3 - } - } : {}, - trigger: { - permission: 0, - children: { - objective: { - properties: { - category: "objective", - accessType: 1 - } - } - } - }, - w: { - permission: 0 - }, - ...ReleaseVersion.cmp(release, "1.21.6") >= 0 ? { - waypoint: { - children: { - modify: { - children: { - waypoint: { - children: { - style: { - children: { - set: { - children: { - style: { - properties: { - category: "waypoint_style" - } - } - } - } - } - } - } - } - } - } - } - } - } : {}, - whitelist: { - permission: 3 - } - } - }; -} -var AdvancementTargets = Object.freeze({ - children: { - targets: { - children: { - from: { - children: { - advancement: { - properties: { - category: "advancement" - } - } - } - }, - only: { - children: { - advancement: { - properties: { - category: "advancement" - }, - children: { - criterion: { - parser: "spyglassmc:criterion", - properties: { - usageType: "reference" - } - } - } - } - } - }, - through: { - children: { - advancement: { - properties: { - category: "advancement" - } - } - } - }, - until: { - children: { - advancement: { - properties: { - category: "advancement" - } - } - } - } - } - } - } -}); -function getDataPatch(vaultKey, nbtKey, { children, isPredicate = false, isMerge = false, nbtAccessType = 0, vaultAccessType = 0 } = {}) { - return Object.freeze({ - children: { - block: { - children: { - [`${vaultKey}Pos`]: { - children: { - [nbtKey]: { - properties: { - dispatcher: "minecraft:block", - dispatchedBy: `${vaultKey}Pos`, - accessType: nbtAccessType, - isPredicate, - isMerge - }, - ...children ? { children: children("block") } : {} - } - } - } - } - }, - entity: { - children: { - [vaultKey]: { - children: { - [nbtKey]: { - properties: { - dispatcher: "minecraft:entity", - dispatchedBy: vaultKey, - accessType: nbtAccessType, - isPredicate, - isMerge - }, - ...children ? { children: children("entity") } : {} - } - } - } - } - }, - storage: { - children: { - [vaultKey]: { - properties: { - category: "storage", - accessType: vaultAccessType, - usageType: "definition" - }, - children: { - [nbtKey]: { - properties: { - dispatcher: "minecraft:storage", - dispatchedBy: vaultKey, - accessType: nbtAccessType, - isPredicate, - isMerge - }, - ...children ? { children: children("storage") } : {} - } - } - } - } - } - } - }); -} -var getDataModifySource = (type2, { isMerge = false, isListIndex = false } = {}) => Object.freeze({ - children: { - from: getDataPatch("source", "sourcePath"), - string: getDataPatch("source", "sourcePath"), - value: { - children: { - value: { - properties: { - dispatcher: `minecraft:${type2}`, - dispatchedBy: type2 === "block" ? "targetPos" : "target", - indexedBy: "targetPath", - isMerge, - isListIndex - } - } - } - } - } -}); -var ExecuteCondition = Object.freeze({ - children: { - data: getDataPatch("source", "path", { - isPredicate: true - }), - predicate: { - children: { - predicate: { - properties: { - category: "predicate" - } - } - } - }, - stopwatch: { - children: { - id: { - properties: { - category: "stopwatch" - } - } - } - } - } -}); -var ExecuteStoreTarget = Object.freeze({ - children: { - ...getDataPatch("target", "path", { - nbtAccessType: 1, - vaultAccessType: 1 - }).children, - bossbar: { - children: { - id: { - properties: { - category: "bossbar", - accessType: 1 - } - } - } - }, - score: { - children: { - targets: { - properties: { - usageType: "definition" - }, - children: { - objective: { - properties: { - accessType: 1 - } - } - } - } - } - } - } -}); -var LootSource = Object.freeze({ - children: { - fish: { - children: { - loot_table: { - properties: { - category: "loot_table" - } - } - } - }, - loot: { - children: { - loot_table: { - properties: { - category: "loot_table" - } - } - } - } - } -}); -var ObjectiveWriteTargets = Object.freeze({ - children: { - targets: { - properties: { - usageType: "definition" - }, - children: { - objective: { - properties: { - accessType: 1 - } - } - } - } - } -}); -var RecipeTargets = Object.freeze({ - children: { - targets: { - children: { - recipe: { - properties: { - category: "recipe" - } - } - } - } - } -}); -var Sound = Object.freeze({ - children: { - sound: { - properties: { - category: "sound_event" - } - } - } -}); - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/tree/patchValidator.js -var PatchRequiredParsers = /* @__PURE__ */ new Set([ - "minecraft:nbt_compound_tag", - "minecraft:nbt_path", - "minecraft:nbt_tag", - "minecraft:resource_location", - "minecraft:uuid" -]); -function validatePatchedTree(tree2, logger) { - walk(tree2, []); - function walk(node, path6) { - if (node.type === "argument" && PatchRequiredParsers.has(node.parser) && !node.properties) { - logger.warn(`[validatePatchedTree] Patch required: ${node.parser} at ${path6.join(".")}`); - } - for (const [key2, value] of Object.entries(node.children ?? {})) { - walk(value, [...path6, key2]); - } - } -} - -// node_modules/@spyglassmc/java-edition/lib/mcfunction/index.js -var initialize5 = (ctx, commands, releaseVersion) => { - const { meta } = ctx; - registerCustomResources(ctx.config); - const tree2 = merge(commands, getPatch(releaseVersion)); - if (ctx.isDebugging) { - validatePatchedTree(tree2, ctx.logger); - } - initialize4(ctx); - const mcfunctionOptions = { - lineContinuation: ReleaseVersion.cmp(releaseVersion, "1.20.2") >= 0, - macros: ReleaseVersion.cmp(releaseVersion, "1.20.2") >= 0, - commandOptions: ReleaseVersion.cmp(releaseVersion, "1.20.5") >= 0 ? { maxLength: 2e6 } : {} - }; - meta.registerLanguage("mcfunction", { - extensions: [".mcfunction"], - parser: entry4(tree2, argument, mcfunctionOptions), - completer: completer_exports5.entry(tree2, getMockNodes), - triggerCharacters: [" ", "[", "=", "!", ",", "{", ":", "/", ".", '"', "'"] - }); - meta.registerParser("mcfunction:block_predicate", blockPredicate); - meta.registerParser("mcfunction:particle", particle3); - meta.registerParser("mcfunction:tag", tag()); - meta.registerParser("mcfunction:team", team()); - meta.registerParser("mcfunction:command", command2(tree2, argument)); - registerMcdocAttributes4(meta, tree2); - register12(meta); - register13(meta); - register14(meta); - meta.registerInlayHintProvider(inlayHintProvider); - meta.registerSignatureHelpProvider(signatureHelpProvider(tree2)); -}; - -// node_modules/@spyglassmc/java-edition/lib/index.js -var initialize6 = async (ctx) => { - const { config, externals, logger, meta, projectRoots } = ctx; - async function readPackFormat(uri) { - try { - const data = await fileUtil.readJson(externals, uri); - return PackMcmeta.readPackFormat(data); - } catch (e) { - if (!externals.error.isKind(e, "ENOENT")) { - logger.error(`[je.initialize] Failed loading pack.mcmeta ${uri}`, e); - } - } - return void 0; - } - async function findPackMcmetas() { - const searchedUris = /* @__PURE__ */ new Set(); - const packs2 = []; - for (let depth = 0; depth <= 2; depth += 1) { - for (const projectRoot of projectRoots) { - const files = await fileUtil.getAllFiles(externals, projectRoot, depth + 1); - for (const uri of files.filter((uri2) => uri2.endsWith("/pack.mcmeta"))) { - if (searchedUris.has(uri)) { - continue; - } - searchedUris.add(uri); - const packRoot = fileUtil.dirname(uri); - const [format, type2] = await Promise.all([ - readPackFormat(uri), - PackMcmeta.getType(packRoot, externals) - ]); - if (format !== void 0) { - packs2.push({ type: type2, packRoot, format }); - } - } - } - } - return packs2; - } - meta.registerUriBinder(uriBinder2); - registerUriBuilders(meta); - const [versions, packs] = await Promise.all([ - getVersions(externals, logger), - findPackMcmetas() - ]); - if (!versions) { - ctx.logger.error("[je-initialize] Failed loading game version list. Expect everything to be broken."); - return; - } - const version = resolveConfiguredVersion(config.env.gameVersion, versions, packs, logger); - const release = version.release; - meta.registerDependencyProvider("@vanilla-datapack", () => getVanillaDatapack(externals, logger, version.id)); - meta.registerDependencyProvider("@vanilla-resourcepack", () => getVanillaResourcepack(externals, logger, version.id)); - meta.registerDependencyProvider("@vanilla-mcdoc", () => getVanillaMcdoc(externals, logger)); - const summary = await getMcmetaSummary(ctx.externals, logger, version.id, config.env.mcmetaSummaryOverrides); - if (!summary.blocks || !summary.commands || !summary.fluids || !summary.registries) { - ctx.logger.error("[je-initialize] Failed loading mcmeta summaries. Expect everything to be broken."); - return; - } - meta.registerSymbolRegistrar("mcmeta-summary", { - checksum: `${summary.checksum}-v4`, - registrar: symbolRegistrar(summary, release) - }); - meta.registerLinter("nameOfNbtKey", { - configValidator: builtin_exports7.configValidator.nameConvention, - linter: builtin_exports7.nameConvention("value"), - nodePredicate: (n) => ( - // nbt compound keys without mcdoc definition. - !n.symbol && n.parent?.parent?.type === "nbt:compound" && PairNode.is(n.parent) && n.type === "string" && n.parent.key === n || !n.symbol && n.parent?.type === "nbt:path" && n.type === "string" || StructFieldNode.is(n.parent) && StructKeyNode.is(n) && !n.symbol?.path[0]?.startsWith("::minecraft") - ) - }); - registerMcdocAttributes3(meta, summary.commands, release); - registerPackFormatAttribute(meta, versions, packs); - meta.registerLanguage("zip", { extensions: [".zip"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("png", { extensions: [".png"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("ogg", { extensions: [".ogg"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("ttf", { extensions: [".ttf"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("otf", { extensions: [".otf"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("fsh", { extensions: [".fsh"], uriPredicate: jeFileUriPredicate }); - meta.registerLanguage("vsh", { extensions: [".vsh"], uriPredicate: jeFileUriPredicate }); - getInitializer(jeFileUriPredicate)(ctx); - initialize3(ctx); - initialize5(ctx, summary.commands, release); - initialize2(ctx); - return { loadedVersion: release, errorSource: release }; -}; - -// mcs-spyglass-validate.mjs -function parseArgs(argv) { - const flags = { - json: false, - mcVersion: null - }; - const positional = []; - for (let index4 = 0; index4 < argv.length; index4 += 1) { - const arg = argv[index4]; - if (arg === "--json") { - flags.json = true; - continue; - } - if (arg === "--mc-version") { - flags.mcVersion = argv[index4 + 1]; - index4 += 1; - continue; - } - if (arg.startsWith("--mc-version=")) { - flags.mcVersion = arg.slice("--mc-version=".length); - continue; - } - positional.push(arg); - } - if (positional.length < 1) { - throw new Error("Usage: node mcs-spyglass-validate.js [--json] [--mc-version ] "); - } - return { flags, datapackDir: (0, import_node_path.resolve)(positional[0]) }; -} -function toRootUri(path6) { - const normalized = (0, import_node_path.resolve)(path6).replace(/\\/g, "/"); - return (0, import_node_url2.pathToFileURL)(`${normalized}/`).href; -} -function severityName(severity) { - switch (severity) { - case ErrorSeverity.Hint: - return "hint"; - case ErrorSeverity.Information: - return "information"; - case ErrorSeverity.Warning: - return "warning"; - case ErrorSeverity.Error: - return "error"; - default: - return "error"; - } -} -function walkFiles(rootDir) { - const files = []; - const stack = [rootDir]; - while (stack.length > 0) { - const current = stack.pop(); - for (const entry6 of (0, import_node_fs2.readdirSync)(current)) { - const fullPath = (0, import_node_path.join)(current, entry6); - const stats = (0, import_node_fs2.statSync)(fullPath); - if (stats.isDirectory()) { - stack.push(fullPath); - continue; - } - files.push(fullPath); - } - } - return files; -} -function languageIdFor(path6) { - if (path6.endsWith(".mcfunction")) return "mcfunction"; - if (path6.endsWith(".json")) return "json"; - if (path6.endsWith(".nbt")) return "nbt"; - return null; -} -async function main() { - const { flags, datapackDir } = parseArgs(process.argv.slice(2)); - const packMetaPath = (0, import_node_path.join)(datapackDir, "pack.mcmeta"); - if (!(0, import_node_fs2.statSync)(datapackDir).isDirectory() || !(0, import_node_fs2.statSync)(packMetaPath).isFile()) { - throw new Error(`Expected a datapack directory containing pack.mcmeta at ${datapackDir}`); - } - const cacheDir = (0, import_node_fs2.mkdtempSync)((0, import_node_path.join)((0, import_node_os2.tmpdir)(), "mcs-spyglass-")); - const cacheRoot = toRootUri(cacheDir); - (0, import_node_fs2.mkdirSync)(new URL(cacheRoot), { recursive: true }); - const projectRoot = toRootUri(datapackDir); - const gameVersion = flags.mcVersion; - const diagnostics = []; - try { - const project = new Project({ - cacheRoot, - defaultConfig: { - ...VanillaConfig, - env: { - ...VanillaConfig.env, - ...gameVersion ? { gameVersion } : {} - } - }, - externals: getNodeJsExternals({ cacheRoot }), - initializers: [initialize, initialize6], - isDebugging: false, - logger: Logger.create("warn"), - projectRoots: [projectRoot] - }); - project.on("documentErrored", ({ uri, errors }) => { - for (const error4 of errors) { - const filePath = decodeURIComponent(new URL(uri).pathname.replace(/^\/([A-Za-z]:)/, "$1")); - const relativePath = (0, import_node_path.relative)(datapackDir, filePath).replace(/\\/g, "/"); - const start = error4.posRange?.start; - diagnostics.push({ - file: relativePath, - line: (start?.line ?? 0) + 1, - column: (start?.character ?? 0) + 1, - message: error4.message, - severity: severityName(error4.severity) - }); - } - }); - await project.init(); - await project.ready(); - for (const filePath of walkFiles(datapackDir)) { - const languageId = languageIdFor(filePath); - if (!languageId) continue; - const uri = (0, import_node_url2.pathToFileURL)(filePath).href; - const content = (0, import_node_fs2.readFileSync)(filePath, "utf8"); - await project.onDidOpen(uri, languageId, 1, content); - const managed = await project.ensureClientManagedChecked(uri); - if (!managed) continue; - for (const error4 of FileNode.getErrors(managed.node)) { - diagnostics.push({ - file: (0, import_node_path.relative)(datapackDir, filePath).replace(/\\/g, "/"), - line: error4.range.start.line + 1, - column: error4.range.start.character + 1, - message: error4.message, - severity: severityName(error4.severity) - }); - } - } - await project.close(); - } finally { - (0, import_node_fs2.rmSync)(cacheDir, { recursive: true, force: true }); - } - const unique = /* @__PURE__ */ new Map(); - for (const diagnostic of diagnostics) { - const key2 = `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}:${diagnostic.message}`; - unique.set(key2, diagnostic); - } - const result = [...unique.values()].sort((left, right) => { - if (left.file !== right.file) return left.file.localeCompare(right.file); - if (left.line !== right.line) return left.line - right.line; - return left.column - right.column; - }); - if (flags.json) { - process.stdout.write(`${JSON.stringify(result)} -`); - } else { - for (const diagnostic of result) { - process.stdout.write( - `${diagnostic.file}:${diagnostic.line}:${diagnostic.column}: ${diagnostic.message} -` - ); - } - } - const hasErrors = result.some((diagnostic) => diagnostic.severity === "error"); - process.exitCode = hasErrors ? 1 : 0; -} -main().catch((error4) => { - const message2 = error4 instanceof Error ? error4.stack ?? error4.message : String(error4); - if (process.argv.includes("--json")) { - process.stdout.write(`${JSON.stringify([{ file: "", line: 0, column: 0, message: message2, severity: "error" }])} -`); - } else { - process.stderr.write(`${message2} -`); - } - process.exitCode = 1; -}); -/*! Bundled license information: - -safe-buffer/index.js: - (*! safe-buffer. MIT License. Feross Aboukhadijeh *) - -object-assign/index.js: - (* - object-assign - (c) Sindre Sorhus - @license MIT - *) - -is-natural-number/index.js: - (*! - * is-natural-number.js | MIT (c) Shinnosuke Watanabe - * https://github.com/shinnn/is-natural-number.js - *) - -strip-dirs/index.js: - (*! - * strip-dirs | MIT (c) Shinnosuke Watanabe - * https://github.com/shinnn/node-strip-dirs - *) -*/ diff --git a/mod/gradle/wrapper/gradle-wrapper.properties b/mod/gradle/wrapper/gradle-wrapper.properties index c43ecd6..cae6a80 100644 --- a/mod/gradle/wrapper/gradle-wrapper.properties +++ b/mod/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,7 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-bin.zip -distributionSha256Sum=7a00d51fb93147819aab76024feece20b6b84e420694101f276be952e08bef03 +distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.5-bin.zip +distributionSha256Sum=6f74b601422d6d6fc4e1f9a1ab6522f642c2fdcbc15ae33ebd30ba3d7198e854 networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME From ed7875907b782d4754081d4ab7b4aa30d96bea5c Mon Sep 17 00:00:00 2001 From: Carter Stach Date: Wed, 10 Jun 2026 14:22:12 -0400 Subject: [PATCH 12/12] Update Forge version in manifest.json for compatibility with new game releases - Updated `forge_version` from 57.0.0 to 58.1.0 for game versions 1.21.8. - Updated `forge_version` from 58.0.0 to 60.1.0 for game versions 1.21.10, ensuring support for the latest features and improvements. --- mod/versions/manifest.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod/versions/manifest.json b/mod/versions/manifest.json index 222da9b..24f142f 100644 --- a/mod/versions/manifest.json +++ b/mod/versions/manifest.json @@ -47,7 +47,7 @@ "supported_game_versions": ["1.21.7", "1.21.8"], "fabric_loader_version": "0.17.2", "fabric_api_version": "0.131.0+1.21.8", - "forge_version": "57.0.0", + "forge_version": "58.1.0", "neoforge_version": "21.8.4-beta", "architectury_api_version": "15.0.3" }, @@ -57,7 +57,7 @@ "supported_game_versions": ["1.21.9", "1.21.10"], "fabric_loader_version": "0.17.2", "fabric_api_version": "0.136.0+1.21.10", - "forge_version": "58.0.0", + "forge_version": "60.1.0", "neoforge_version": "21.10.4-beta", "architectury_api_version": "16.0.3" },