diff --git a/.config/KDE/UserFeedback.conf b/.config/KDE/UserFeedback.conf index 3694674..c0c8b3f 100644 --- a/.config/KDE/UserFeedback.conf +++ b/.config/KDE/UserFeedback.conf @@ -1,2 +1,2 @@ [UserFeedback] -LastEncouragement=@DateTime(\0\0\0\x10\0\0\0\0\0\0%\x8dM\x3\xb0&\xf9\0) +LastEncouragement=@DateTime(\0\0\0\x10\0\0\0\0\0\0%\x8d\x8b\x2w/\x18\0) diff --git a/.config/MangoHud/MangoHud.conf b/.config/MangoHud/MangoHud.conf deleted file mode 100644 index cf87475..0000000 --- a/.config/MangoHud/MangoHud.conf +++ /dev/null @@ -1,382 +0,0 @@ -### MangoHud configuration file -### Uncomment any options you wish to enable. Default options are left uncommented -### Use some_parameter=0 to disable a parameter (only works with on/off parameters) -### Everything below can be used / overridden with the environment variable MANGOHUD_CONFIG instead - -################ INFORMATIONAL ################# -## prints possible options on stdout -# help - -################ PERFORMANCE ################# - -### Limit the application FPS. Comma-separated list of one or more FPS values (e.g. 0,30,60). 0 means unlimited (unless VSynced) -fps_limit=180 - -### early = wait before present, late = wait after present -# fps_limit_method= - -### VSync [0-3] 0 = adaptive; 1 = off; 2 = mailbox; 3 = on -# vsync=-1 - -### OpenGL VSync [0-N] 0 = off; >=1 = wait for N v-blanks, N > 1 acts as a FPS limiter (FPS = display refresh rate / N) -# gl_vsync=-2 - -### Mip-map LoD bias. Negative values will increase texture sharpness (and aliasing) -## Positive values will increase texture blurriness (-16 to 16) -# picmip=-17 - -### Anisotropic filtering level. Improves sharpness of textures viewed at an angle (0 to 16) -# af=-1 - -### Force bicubic filtering -# bicubic - -### Force trilinear filtering -# trilinear - -### Disable linear texture filtering. Makes textures look blocky -# retro - -################### VISUAL ################### - -### Legacy layout -# legacy_layout=0 - -### pre defined presets -# -1 = default -# 0 = no display -# 1 = fps only -# 2 = horizontal view -# 3 = extended -# 4 = high detailed information -preset=0 - -### Enable most of the toggleable parameters (currently excludes `histogram`) -# full - -### Show FPS only. ***Not meant to be used with other display params*** -# fps_only - -### Display custom centered text, useful for a header -# custom_text_center= - -### Display the current system time -# time -## removes the time label -# time_no_label - -### Time formatting examples -## %H:%M -## [ %T %F ] -## %X # locally formatted time, because of limited glyph range, missing characters may show as '?' (e.g. Japanese) -# time_format="%T" - -### Display MangoHud version -# version - -### Display the current GPU information -## Note: gpu_mem_clock and gpu_mem_temp also need "vram" to be enabled -gpu_stats -# gpu_temp -# gpu_junction_temp -# gpu_core_clock -# gpu_mem_temp -# gpu_mem_clock -# gpu_power -# gpu_text= -# gpu_load_change -# gpu_load_value=60,90 -# gpu_load_color=39F900,FDFD09,B22222 -## GPU fan in rpm on AMD, FAN in percent on NVIDIA -# gpu_fan -## gpu_voltage only works on AMD GPUs -# gpu_voltage -## Select list of GPUs to display -# gpu_list=0,1 - -### Display the current CPU information -cpu_stats -# cpu_temp -# cpu_power -# cpu_text= -# cpu_mhz -# cpu_load_change -# cpu_load_value=60,90 -# cpu_load_color=39F900,FDFD09,B22222 - -### Display the current CPU load & frequency for each core -# core_load -# core_load_change -# core_bars - -### Display IO read and write for the app (not system) -# io_read -# io_write - -### Display system vram / ram / swap space usage -# vram -# ram -# swap - -### Display per process memory usage -## Show resident memory and other types, if enabled -# procmem -# procmem_shared -# procmem_virt - -### Display battery information -# battery -# battery_icon -# device_battery=gamepad,mouse -# device_battery_icon -# battery_watt -# battery_time - -### Display FPS and frametime -fps -# fps_sampling_period=500 -# fps_color_change -# fps_value=30,60 -# fps_color=B22222,FDFD09,39F900 -# fps_text="" -frametime -# frame_count -## fps_metrics takes a list of decimal values or the value avg -# fps_metrics=avg,0.01 - -### Display GPU throttling status based on Power, current, temp or "other" -## Only shows if throttling is currently happening -throttling_status -## Same as throttling_status but displays throttling on the frametime graph -#throttling_status_graph - -### Display miscellaneous information -# engine_version -# engine_short_names -# gpu_name -# vulkan_driver -# wine -# exec_name -# winesync -# present_mode - -### Display loaded MangoHud architecture -# arch - -### Display the frametime line graph -frame_timing -# frame_timing_detailed -# dynamic_frame_timing -# histogram - -### Display GameMode / vkBasalt running status -# gamemode -# vkbasalt - -### Gamescope related options -## Display the status of FSR (only works in gamescope) -# fsr -## Hides the sharpness info for the `fsr` option (only available in gamescope) -# hide_fsr_sharpness -## Shows the graph of gamescope app frametimes and latency (only on gamescope obviously) -# debug -## Display the status of HDR (only works in gamescope) -# hdr -## Display the current refresh rate (only works in gamescope) -# refresh_rate - - -### graphs displays one or more graphs that you chose -## separated by ",", available graphs are -## gpu_load,cpu_load,gpu_core_clock,gpu_mem_clock,vram,ram,cpu_temp,gpu_temp -# graphs= - -### mangoapp related options -## Enables mangoapp to be displayed above the Steam UI -# mangoapp_steam - -### Steam Deck options -## Shows the Steam Deck fan rpm -# fan - -### Display current FPS limit -# show_fps_limit - -### Display the current resolution -# resolution - -### Display current display session -# display_server - -### Display temperature in fahrenheit -# temp_fahrenheit - -### Display custom text -# custom_text= -### Display output of Bash command in next column -# exec= - -### Display media player metadata -# media_player -## for example spotify -# media_player_name= -## Format metadata, lines are delimited by ; (wip) -## example: {title};{artist};{album} -## example: Track:;{title};By:;{artist};From:;{album} -# media_player_format=title,artist,album - -### Network interface throughput -# network -## Network can take arguments but it's not required. -## without arguments it shows all interfaces -## arguments set which interfaces will be displayed -# network=eth0,wlo1 - - -### Change the hud font size -# font_size=24 -# font_scale=1.0 -# font_size_text=24 -# font_scale_media_player=0.55 -# no_small_font - -### Change default font (set location to TTF/OTF file) -## Set font for the whole hud -# font_file= - -## Set font only for text like media player metadata -# font_file_text= - -## Set font glyph ranges. Defaults to Latin-only. Don't forget to set font_file/font_file_text to font that supports these -## Probably don't enable all at once because of memory usage and hardware limits concerns -## If you experience crashes or text is just squares, reduce glyph range or reduce font size -# font_glyph_ranges=korean,chinese,chinese_simplified,japanese,cyrillic,thai,vietnamese,latin_ext_a,latin_ext_b - -### Outline text -text_outline -# text_outline_color = 000000 -# text_outline_thickness = 1.5 - -### Change the hud position -# position=top-left - -### Change the corner roundness -# round_corners=0 - -### Remove margins around MangoHud -# hud_no_margin - -### Display compact version of MangoHud -# hud_compact - -### Display MangoHud in a horizontal position -# horizontal -# horizontal_stretch - -### Disable / hide the hud by default -# no_display - -### Show FEX-Emu statistics -## Only useful for Arm64 devices running applications under emulation -# fex_stats - -### Hud position offset -# offset_x=0 -# offset_y=0 - -### Hud dimensions -# width=0 -# height=140 -# table_columns=3 -# cellpadding_y=-0.085 - -### Hud transparency / alpha -# background_alpha=0.5 -# alpha=1.0 - -### FCAT overlay -### This enables an FCAT overlay to perform frametime analysis on the final image stream. -### Enable the overlay -# fcat -### Set the width of the FCAT overlay. -### 24 is a performance optimization on AMD GPUs that should not have adverse effects on nVidia GPUs. -### A minimum of 20 pixels is recommended by nVidia. -# fcat_overlay_width=24 -### Set the screen edge, this can be useful for special displays that don't update from top edge to bottom. This goes from 0 (left side) to 3 (top edge), counter-clockwise. -# fcat_screen_edge=0 - -### Color customization -# text_color=FFFFFF -# gpu_color=2E9762 -# cpu_color=2E97CB -# vram_color=AD64C1 -# ram_color=C26693 -# engine_color=EB5B5B -# io_color=A491D3 -# frametime_color=00FF00 -# background_color=020202 -# media_player_color=FFFFFF -# wine_color=EB5B5B -# battery_color=FF9078 -# network_color=E07B85 - -### Specify GPU with PCI bus ID -### Set to 'domain:bus:slot.function' -### Example: -### $ lspci | grep A770 -### 03:00.0 VGA compatible controller: Intel Corporation DG2 [Arc A770] (rev 08) -# pci_dev=0000:03:00.0 - -### Blacklist -# blacklist= - -### Control over socket -### Enable and set socket name, '%p' is replaced with process id -## example: mangohud -## example: mangohud-%p -# control = -1 - -################ WORKAROUNDS ################# -### Options starting with "gl_*" are for OpenGL -### Specify what to use for getting display size. Options are "viewport", "scissorbox" or disabled. Defaults to using glXQueryDrawable -# gl_size_query=viewport - -### (Re)bind given framebuffer before MangoHud gets drawn. Helps with Crusader Kings III -# gl_bind_framebuffer=0 - -### Don't swap origin if using GL_UPPER_LEFT. Helps with Ryujinx -# gl_dont_flip=1 - -################ INTERACTION ################# - -### Change toggle keybinds for the hud & logging -# toggle_hud=Shift_R+F12 -# toggle_hud_position=Shift_R+F11 -# toggle_preset=Shift_R+F10 -# toggle_fps_limit=Shift_L+F1 -# toggle_logging=Shift_L+F2 -# reload_cfg=Shift_L+F4 -# upload_log=Shift_L+F3 -# reset_fps_metrics=Shift_R+f9 - -#################### LOG ##################### -### Automatically start the log after X seconds -# autostart_log= -### Set amount of time in seconds that the logging will run for -# log_duration= -### Change the default log interval, 0 is default -# log_interval=0 -### Set location of the output files (required for logging) -# output_folder=/home//mangologs -### Permit uploading logs directly to FlightlessMango.com -## set to 1 to enable -# permit_upload=0 -### Define a '+'-separated list of percentiles shown in the benchmark results -### Use "AVG" to get a mean average. Default percentiles are 97+AVG+1+0.1 -## example: ['97', 'AVG', '1', '0.1'] -# benchmark_percentiles=97,AVG -## Adds more headers and information such as versioning to the log. This format is not supported on flightlessmango.com (yet) -# log_versioning -## Enable automatic uploads of logs to flightlessmango.com -# upload_logs -# output_file="" diff --git a/.config/PlasmaDiscoverUpdates b/.config/PlasmaDiscoverUpdates index f06b255..7ad50e8 100644 --- a/.config/PlasmaDiscoverUpdates +++ b/.config/PlasmaDiscoverUpdates @@ -1,2 +1,2 @@ [Global] -LastNotificationTime=2025,12,16,22,11,34.91,UTC +LastNotificationTime=2026,2,7,23,52,37.581,UTC diff --git a/.config/aliases b/.config/aliases index ec1db75..9b8ff1a 100644 --- a/.config/aliases +++ b/.config/aliases @@ -13,6 +13,7 @@ alias gpu="inxi -Gxz" alias box="SHELL=/usr/bin/fish toolbox enter" alias reload="clear; source ~/.config/fish/config.fish" alias exe="chmod +x" +alias py="python3" # Directory Shortcuts alias gosteam="cd ~/.local/share/Steam/steamapps/common/" @@ -23,6 +24,8 @@ alias goentries="cd ~/.local/share/applications/" alias aliasconf="nvim ~/dotfiles/.config/aliases" alias fishconf="nvim ~/dotfiles/.config/fish/config.fish" alias nvimconf="nvim ~/dotfiles/.config/nvim/init.lua" +alias kittyconf="nvim ~/dotfiles/.config/kitty/kitty.conf" +alias ghosttyconf="nvim ~/dotfiles/.config/ghostty/config" # Toolbox Commands alias in="sudo nala install -y" @@ -30,4 +33,5 @@ alias up="sudo nala update" alias upg="up && sudo nala upgrade" alias se="nala search" alias re="sudo nala remove" +alias purge="sudo nala purge" alias rein="sudo nala reinstall" diff --git a/.config/bluedevilglobalrc b/.config/bluedevilglobalrc new file mode 100644 index 0000000..54e18f7 --- /dev/null +++ b/.config/bluedevilglobalrc @@ -0,0 +1,9 @@ +[Adapters] +02:00:45:E6:E8:36_powered=false +50:C2:E8:EE:B5:3C_powered=false + +[Devices] +connectedDevices= + +[General] +launchState=enable diff --git a/.config/dolphinrc b/.config/dolphinrc index 468ded5..6420917 100644 --- a/.config/dolphinrc +++ b/.config/dolphinrc @@ -1,3 +1,6 @@ +[ContextMenu] +ShowAddToPlaces=false + [General] Version=202 ViewPropsTimestamp=2025,11,25,17,7,8.294 @@ -8,3 +11,9 @@ Places Icons Static Size=22 [MainWindow] MenuBar=Disabled + +[PreviewSettings] +Plugins=appimagethumbnail,opendocumentthumbnail,rawthumbnail,cursorthumbnail,imagethumbnail,ffmpegthumbs,exrthumbnail,windowsimagethumbnail,gsthumbnail,jpegthumbnail,mltpreview,blenderthumbnail,palathumbcreator,windowsexethumbnail,svgthumbnail,audiothumbnail,comicbookthumbnail,kraorathumbnail,fontthumbnail,djvuthumbnail,mobithumbnail,ebookthumbnail,directorythumbnail,gdk-pixbuf-thumbnailer,librsvg + +[VersionControl] +enabledPlugins=Git diff --git a/.config/filetypesrc b/.config/filetypesrc index cf07dfd..0fbf1c7 100644 --- a/.config/filetypesrc +++ b/.config/filetypesrc @@ -1,11 +1,19 @@ [EmbedSettings] +embed-application/json=false embed-application/vnd.debian.binary-package=false embed-application/vnd.microsoft.portable-executable=false embed-application/x-blender=false +embed-application/x-docbook+xml=false embed-application/x-msdownload=false embed-application/x-msi=false embed-application/x-nes-rom=false +embed-application/x-yaml=false +embed-application/x-zerosize=false embed-application/zip=false +embed-text/markdown=false +embed-text/plain=false embed-text/rust=false +embed-text/x-cmake=false embed-x-scheme-handler/http=false embed-x-scheme-handler/https=false +embed-x-scheme-handler/nxm=false diff --git a/.config/fish/config.fish b/.config/fish/config.fish index f573e99..941a48f 100644 --- a/.config/fish/config.fish +++ b/.config/fish/config.fish @@ -6,7 +6,7 @@ if status is-interactive end fish_add_path ~/.spicetify -fish_add_path ~/.bin +fish_add_path ~/Scripts/ # Created by `pipx` on 2025-12-14 01:29:13 set PATH $PATH /home/cory/.local/bin diff --git a/.config/fish/fish_variables b/.config/fish/fish_variables index 9fa475e..33110cc 100644 --- a/.config/fish/fish_variables +++ b/.config/fish/fish_variables @@ -33,4 +33,4 @@ SETUVAR fish_pager_color_description:yellow\x1e\x2di SETUVAR fish_pager_color_prefix:normal\x1e\x2d\x2dbold\x1e\x2d\x2dunderline SETUVAR fish_pager_color_progress:brwhite\x1e\x2d\x2dbackground\x3dcyan SETUVAR fish_pager_color_selected_background:\x2dr -SETUVAR fish_user_paths:/home/cory/\x2ebin\x1e/var/home/cory/Scripts\x1e/home/cory/\x2espicetify +SETUVAR fish_user_paths:/home/cory/Scripts\x1e/home/cory/\x2ebin\x1e/var/home/cory/Scripts\x1e/home/cory/\x2espicetify diff --git a/.config/ghostty/config b/.config/ghostty/config new file mode 100644 index 0000000..6da0557 --- /dev/null +++ b/.config/ghostty/config @@ -0,0 +1,14 @@ +font-family = "CaskaydiaMonoNerdFont" +font-size = 16 +window-padding-x = 4 +background-opacity = 0.05 +background-opacity = 0.5 +background-blur = true +window-theme = light +cursor-color = red +command = fish +theme = Everforest Light Med +theme = Everforest Dark Hard +custom-shader = shaders/cursor_blaze.glsl +# custom-shader = shaders/cursor_sweep.glsl +custom-shader = shaders/ripple_rectangle_cursor.glsl diff --git a/.config/ghostty/shaders/Readme.md b/.config/ghostty/shaders/Readme.md new file mode 100644 index 0000000..3ea6c87 --- /dev/null +++ b/.config/ghostty/shaders/Readme.md @@ -0,0 +1,20 @@ +## Installation + +Clone the repository: + +```sh +git clone --depth 1 https://github.com/hackr-sh/ghostty-shaders +cd ghostty-shaders +``` + +Copy your preferred shader file to the Ghostty config directory: + +```sh +cp .glsl ~/.config/ghostty/shaders/shader.glsl +``` + +Add the following line to your `~/.config/ghostty/config` file to enable the custom shader: + +```ini +custom-shader = ~/.config/ghostty/shaders/shader.glsl +``` diff --git a/.config/ghostty/shaders/animated-gradient-shader.glsl b/.config/ghostty/shaders/animated-gradient-shader.glsl new file mode 100644 index 0000000..01b541c --- /dev/null +++ b/.config/ghostty/shaders/animated-gradient-shader.glsl @@ -0,0 +1,40 @@ +// credits: https://github.com/unkn0wncode +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = fragCoord.xy / iResolution.xy; + + // Create seamless gradient animation + float speed = 0.2; + float gradientFactor = (uv.x + uv.y) / 2.0; + + // Use smoothstep and multiple sin waves for smoother transition + float t = sin(iTime * speed) * 0.5 + 0.5; + gradientFactor = smoothstep(0.0, 1.0, gradientFactor); + + // Create smooth circular animation + float angle = iTime * speed; + vec3 color1 = vec3(0.1, 0.1, 0.5); + vec3 color2 = vec3(0.5, 0.1, 0.1); + vec3 color3 = vec3(0.1, 0.5, 0.1); + + // Smooth interpolation between colors using multiple mix operations + vec3 gradientStartColor = mix( + mix(color1, color2, smoothstep(0.0, 1.0, sin(angle) * 0.5 + 0.5)), + color3, + smoothstep(0.0, 1.0, sin(angle + 2.0) * 0.5 + 0.5) + ); + + vec3 gradientEndColor = mix( + mix(color2, color3, smoothstep(0.0, 1.0, sin(angle + 1.0) * 0.5 + 0.5)), + color1, + smoothstep(0.0, 1.0, sin(angle + 3.0) * 0.5 + 0.5) + ); + + vec3 gradientColor = mix(gradientStartColor, gradientEndColor, gradientFactor); + + vec4 terminalColor = texture(iChannel0, uv); + float mask = 1.0 - step(0.5, dot(terminalColor.rgb, vec3(1.0))); + vec3 blendedColor = mix(terminalColor.rgb, gradientColor, mask); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/auto-tracking-spotlight b/.config/ghostty/shaders/auto-tracking-spotlight new file mode 100644 index 0000000..016dfec --- /dev/null +++ b/.config/ghostty/shaders/auto-tracking-spotlight @@ -0,0 +1,64 @@ +// Spotlight that follows the terminal caret (cursor) with correct bright-in/dark-out +// Fix: bright inside circle (=1.0), darkened outside by AMBIENT_LIGHT; fallback to random wander when no cursor + +// ---------- Parameters ---------- +const float SPOTLIGHT_RADIUS = 0.25; // Radius (normalized distance based on short edge) +const float EDGE_WIDTH = 0.020; // Edge transition width (0.01~0.04 for more natural effect) +const float AMBIENT_LIGHT = 0.50; // Minimum brightness outside circle (0=pure black, 1=no darkening) +const float FOLLOW_DURATION = 0.18; // Follow transition duration (seconds) +// -------------------------- + +float easeOutExpo(float t) { + return (t <= 0.0) ? 0.0 : 1.0 - pow(2.0, -10.0 * t); +} + +vec2 fallbackWanderCenter() { + float t = iTime; + return vec2( + 0.5 + 0.4 * sin(t * 1.0 + 0.0), + 0.5 + 0.4 * sin(t * 1.3 + 3.14159265) + ); +} + +// Note: cursor rect in repo defines y as "top edge" → center y = y - h/2 +vec2 rectCenterPx(vec4 r) { return vec2(r.x + 0.5*r.z, r.y - 0.5*r.w); } + +// Returns UV center (0..1), or vec2(-1) if invalid +vec2 cursorCenterUV_smooth() { + vec4 cur = iCurrentCursor; + vec4 prv = iPreviousCursor; + bool usable = (cur.z > 0.0 && cur.w > 0.0); + if (!usable) return vec2(-1.0); + + vec2 c0 = rectCenterPx(prv) / iResolution.xy; + vec2 c1 = rectCenterPx(cur) / iResolution.xy; + + float t = clamp((iTime - iTimeCursorChange) / FOLLOW_DURATION, 0.0, 1.0); + float k = easeOutExpo(t); + vec2 c = mix(c0, c1, k); + return clamp(c, vec2(0.0), vec2(1.0)); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord / iResolution.xy; + vec4 tex = texture(iChannel0, uv); + + // Calculate center: prioritize cursor, otherwise random wander + vec2 center = cursorCenterUV_smooth(); + if (center.x < 0.0) { + center = fallbackWanderCenter(); + } + + // "Circular distance" after aspect ratio correction + vec2 ratio = vec2(iResolution.x / iResolution.y, 1.0); + float d = length((uv - center) * ratio); + + // Key fix: use canonical smoothstep order to get "inside circle mask" (center=1, outside=0) + // maskInside = 1 - smoothstep(R, R+W, d) + float maskInside = 1.0 - smoothstep(SPOTLIGHT_RADIUS, SPOTLIGHT_RADIUS + EDGE_WIDTH, d); + + // Brightness: inside circle=1.0, outside=AMBIENT_LIGHT + float brightness = mix(AMBIENT_LIGHT, 1.0, maskInside); + + fragColor = vec4(tex.rgb * brightness, tex.a); +} diff --git a/.config/ghostty/shaders/bettercrt.glsl b/.config/ghostty/shaders/bettercrt.glsl new file mode 100644 index 0000000..8f58b89 --- /dev/null +++ b/.config/ghostty/shaders/bettercrt.glsl @@ -0,0 +1,33 @@ +// Original shader collected from: https://www.shadertoy.com/view/WsVSzV +// Licensed under Shadertoy's default since the original creator didn't provide any license. (CC BY NC SA 3.0) +// Slight modifications were made to give a green-ish effect. + +// This shader was modified by April Hall (arithefirst) +// Sourced from https://github.com/m-ahdal/ghostty-shaders/blob/main/retro-terminal.glsl +// Changes made: +// - Removed tint +// - Made the boundaries match ghostty's background color + +float warp = 0.25; // simulate curvature of CRT monitor +float scan = 0.50; // simulate darkness between scanlines + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + // squared distance from center + vec2 uv = fragCoord / iResolution.xy; + vec2 dc = abs(0.5 - uv); + dc *= dc; + + // warp the fragment coordinates + uv.x -= 0.5; uv.x *= 1.0 + (dc.y * (0.3 * warp)); uv.x += 0.5; + uv.y -= 0.5; uv.y *= 1.0 + (dc.x * (0.4 * warp)); uv.y += 0.5; + + // determine if we are drawing in a scanline + float apply = abs(sin(fragCoord.y) * 0.25 * scan); + + // sample the texture + vec3 color = texture(iChannel0, uv).rgb; + + // mix the sampled color with the scanline intensity + fragColor = vec4(mix(color, vec3(0.0), apply), 1.0); +} diff --git a/.config/ghostty/shaders/bloom.glsl b/.config/ghostty/shaders/bloom.glsl new file mode 100644 index 0000000..ad22448 --- /dev/null +++ b/.config/ghostty/shaders/bloom.glsl @@ -0,0 +1,52 @@ +// source: https://gist.github.com/qwerasd205/c3da6c610c8ffe17d6d2d3cc7068f17f +// credits: https://github.com/qwerasd205 +// Golden spiral samples, [x, y, weight] weight is inverse of distance. +const vec3[24] samples = { + vec3(0.1693761725038636, 0.9855514761735895, 1), + vec3(-1.333070830962943, 0.4721463328627773, 0.7071067811865475), + vec3(-0.8464394909806497, -1.51113870578065, 0.5773502691896258), + vec3(1.554155680728463, -1.2588090085709776, 0.5), + vec3(1.681364377589461, 1.4741145918052656, 0.4472135954999579), + vec3(-1.2795157692199817, 2.088741103228784, 0.4082482904638631), + vec3(-2.4575847530631187, -0.9799373355024756, 0.3779644730092272), + vec3(0.5874641440200847, -2.7667464429345077, 0.35355339059327373), + vec3(2.997715703369726, 0.11704939884745152, 0.3333333333333333), + vec3(0.41360842451688395, 3.1351121305574803, 0.31622776601683794), + vec3(-3.167149933769243, 0.9844599011770256, 0.30151134457776363), + vec3(-1.5736713846521535, -3.0860263079123245, 0.2886751345948129), + vec3(2.888202648340422, -2.1583061557896213, 0.2773500981126146), + vec3(2.7150778983300325, 2.5745586041105715, 0.2672612419124244), + vec3(-2.1504069972377464, 3.2211410627650165, 0.2581988897471611), + vec3(-3.6548858794907493, -1.6253643308191343, 0.25), + vec3(1.0130775986052671, -3.9967078676335834, 0.24253562503633297), + vec3(4.229723673607257, 0.33081361055181563, 0.23570226039551587), + vec3(0.40107790291173834, 4.340407413572593, 0.22941573387056174), + vec3(-4.319124570236028, 1.159811599693438, 0.22360679774997896), + vec3(-1.9209044802827355, -4.160543952132907, 0.2182178902359924), + vec3(3.8639122286635708, -2.6589814382925123, 0.21320071635561041), + vec3(3.3486228404946234, 3.4331800232609, 0.20851441405707477), + vec3(-2.8769733643574344, 3.9652268864187157, 0.20412414523193154) + }; + +float lum(vec4 c) { + return 0.299 * c.r + 0.587 * c.g + 0.114 * c.b; +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord.xy / iResolution.xy; + + vec4 color = texture(iChannel0, uv); + + vec2 step = vec2(1.414) / iResolution.xy; + + for (int i = 0; i < 24; i++) { + vec3 s = samples[i]; + vec4 c = texture(iChannel0, uv + s.xy * step); + float l = lum(c); + if (l > 0.2) { + color += l * s.z * c * 0.2; + } + } + + fragColor = color; +} \ No newline at end of file diff --git a/.config/ghostty/shaders/cineShader-Lava.glsl b/.config/ghostty/shaders/cineShader-Lava.glsl new file mode 100644 index 0000000..224a2ce --- /dev/null +++ b/.config/ghostty/shaders/cineShader-Lava.glsl @@ -0,0 +1,79 @@ +// INFO: This shader is a port of https://www.shadertoy.com/view/3sySRK + +// INFO: Change these variables to create some variation in the animation +#define BLACK_BLEND_THRESHOLD .4 // This is controls the dim of the screen +#define COLOR_SPEED 0.1 // This controls the speed at which the colors change +#define MOVEMENT_SPEED 0.1 // This controls the speed at which the balls move + +float opSmoothUnion( float d1, float d2, float k ) +{ + float h = clamp( 0.5 + 0.5*(d2-d1)/k, 0.0, 1.0 ); + return mix( d2, d1, h ) - k*h*(1.0-h); +} + +float sdSphere( vec3 p, float s ) +{ + return length(p)-s; +} + +float map(vec3 p) +{ + float d = 2.0; + for (int i = 0; i < 16; i++) { + float fi = float(i); + float time = iTime * (fract(fi * 412.531 + 0.513) - 0.5) * 2.0; + d = opSmoothUnion( + sdSphere(p + sin(time*MOVEMENT_SPEED + fi * vec3(52.5126, 64.62744, 632.25)) * vec3(2.0, 2.0, 0.8), mix(0.5, 1.0, fract(fi * 412.531 + 0.5124))), + d, + 0.4 + ); + } + return d; +} + +vec3 calcNormal( in vec3 p ) +{ + const float h = 1e-5; // or some other value + const vec2 k = vec2(1,-1); + return normalize( k.xyy*map( p + k.xyy*h ) + + k.yyx*map( p + k.yyx*h ) + + k.yxy*map( p + k.yxy*h ) + + k.xxx*map( p + k.xxx*h ) ); +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 uv = fragCoord/iResolution.xy; + + vec3 rayOri = vec3((uv - 0.5) * vec2(iResolution.x/iResolution.y, 1.0) * 6.0, 3.0); + vec3 rayDir = vec3(0.0, 0.0, -1.0); + + float depth = 0.0; + vec3 p; + + for(int i = 0; i < 64; i++) { + p = rayOri + rayDir * depth; + float dist = map(p); + depth += dist; + if (dist < 1e-6) { + break; + } + } + + depth = min(6.0, depth); + vec3 n = calcNormal(p); + float b = max(0.0, dot(n, vec3(0.577))); + vec3 col = (0.5 + 0.5 * cos((b + iTime*COLOR_SPEED * 3.0) + uv.xyx * 2.0 + vec3(0,2,4))) * (0.85 + b * 0.35); + col *= exp( -depth * 0.15 ); + + + vec2 termUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, termUV); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb * 1.0, col.rgb * 0.3, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); + +} + diff --git a/.config/ghostty/shaders/crt.glsl b/.config/ghostty/shaders/crt.glsl new file mode 100644 index 0000000..d34a188 --- /dev/null +++ b/.config/ghostty/shaders/crt.glsl @@ -0,0 +1,310 @@ +// source: https://gist.github.com/qwerasd205/c3da6c610c8ffe17d6d2d3cc7068f17f +// credits: https://github.com/qwerasd205 +//============================================================== +// +// [CRTS] PUBLIC DOMAIN CRT-STYLED SCALAR by Timothy Lottes +// +// [+] Adapted with alterations for use in Ghostty by Qwerasd. +// For more information on changes, see comment below license. +// +//============================================================== +// +// LICENSE = UNLICENSE (aka PUBLIC DOMAIN) +// +//-------------------------------------------------------------- +// This is free and unencumbered software released into the +// public domain. +//-------------------------------------------------------------- +// Anyone is free to copy, modify, publish, use, compile, sell, +// or distribute this software, either in source code form or as +// a compiled binary, for any purpose, commercial or +// non-commercial, and by any means. +//-------------------------------------------------------------- +// In jurisdictions that recognize copyright laws, the author or +// authors of this software dedicate any and all copyright +// interest in the software to the public domain. We make this +// dedication for the benefit of the public at large and to the +// detriment of our heirs and successors. We intend this +// dedication to be an overt act of relinquishment in perpetuity +// of all present and future rights to this software under +// copyright law. +//-------------------------------------------------------------- +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY +// KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE +// WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +// AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT +// OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +// DEALINGS IN THE SOFTWARE. +//-------------------------------------------------------------- +// For more information, please refer to +// +//============================================================== + +// This shader is a modified version of the excellent +// FixingPixelArtFast by Timothy Lottes on Shadertoy. +// +// The original shader can be found at: +// https://www.shadertoy.com/view/MtSfRK +// +// Modifications have been made to reduce the verbosity, +// and many of the comments have been removed / reworded. +// Additionally, the license has been moved to the top of +// the file, and can be read above. I (Qwerasd) choose to +// release the modified version under the same license. + +// The appearance of this shader can be altered +// by adjusting the parameters defined below. + +// "Scanlines" per real screen pixel. +// e.g. SCALE 0.5 means each scanline is 2 pixels. +// Recommended values: +// o High DPI displays: 0.33333333 +// - Low DPI displays: 0.66666666 +#define SCALE 0.33333333 + +// "Tube" warp +#define CRTS_WARP 1 + +// Darkness of vignette in corners after warping +// 0.0 = completely black +// 1.0 = no vignetting +#define MIN_VIN 0.5 + +// Try different masks +// #define CRTS_MASK_GRILLE 1 +// #define CRTS_MASK_GRILLE_LITE 1 +// #define CRTS_MASK_NONE 1 +#define CRTS_MASK_SHADOW 1 + +// Scanline thinness +// 0.50 = fused scanlines +// 0.70 = recommended default +// 1.00 = thinner scanlines (too thin) +#define INPUT_THIN 0.75 + +// Horizonal scan blur +// -3.0 = pixely +// -2.5 = default +// -2.0 = smooth +// -1.0 = too blurry +#define INPUT_BLUR -2.75 + +// Shadow mask effect, ranges from, +// 0.25 = large amount of mask (not recommended, too dark) +// 0.50 = recommended default +// 1.00 = no shadow mask +#define INPUT_MASK 0.65 + +float FromSrgb1(float c) { + return (c <= 0.04045) ? c * (1.0 / 12.92) : + pow(c * (1.0 / 1.055) + (0.055 / 1.055), 2.4); +} +vec3 FromSrgb(vec3 c) { + return vec3( + FromSrgb1(c.r), FromSrgb1(c.g), FromSrgb1(c.b)); +} + +vec3 CrtsFetch(vec2 uv) { + return FromSrgb(texture(iChannel0, uv.xy).rgb); +} + +#define CrtsRcpF1(x) (1.0/(x)) +#define CrtsSatF1(x) clamp((x),0.0,1.0) + +float CrtsMax3F1(float a, float b, float c) { + return max(a, max(b, c)); +} + +vec2 CrtsTone( + float thin, + float mask) { + #ifdef CRTS_MASK_NONE + mask = 1.0; + #endif + + #ifdef CRTS_MASK_GRILLE_LITE + // Normal R mask is {1.0,mask,mask} + // LITE R mask is {mask,1.0,1.0} + mask = 0.5 + mask * 0.5; + #endif + + vec2 ret; + float midOut = 0.18 / ((1.5 - thin) * (0.5 * mask + 0.5)); + float pMidIn = 0.18; + ret.x = ((-pMidIn) + midOut) / ((1.0 - pMidIn) * midOut); + ret.y = ((-pMidIn) * midOut + pMidIn) / (midOut * (-pMidIn) + midOut); + + return ret; +} + +vec3 CrtsMask(vec2 pos, float dark) { + #ifdef CRTS_MASK_GRILLE + vec3 m = vec3(dark, dark, dark); + float x = fract(pos.x * (1.0 / 3.0)); + if (x < (1.0 / 3.0)) m.r = 1.0; + else if (x < (2.0 / 3.0)) m.g = 1.0; + else m.b = 1.0; + return m; + #endif + + #ifdef CRTS_MASK_GRILLE_LITE + vec3 m = vec3(1.0, 1.0, 1.0); + float x = fract(pos.x * (1.0 / 3.0)); + if (x < (1.0 / 3.0)) m.r = dark; + else if (x < (2.0 / 3.0)) m.g = dark; + else m.b = dark; + return m; + #endif + + #ifdef CRTS_MASK_NONE + return vec3(1.0, 1.0, 1.0); + #endif + + #ifdef CRTS_MASK_SHADOW + pos.x += pos.y * 3.0; + vec3 m = vec3(dark, dark, dark); + float x = fract(pos.x * (1.0 / 6.0)); + if (x < (1.0 / 3.0)) m.r = 1.0; + else if (x < (2.0 / 3.0)) m.g = 1.0; + else m.b = 1.0; + return m; + #endif +} + +vec3 CrtsFilter( + vec2 ipos, + vec2 inputSizeDivOutputSize, + vec2 halfInputSize, + vec2 rcpInputSize, + vec2 rcpOutputSize, + vec2 twoDivOutputSize, + float inputHeight, + vec2 warp, + float thin, + float blur, + float mask, + vec2 tone +) { + // Optional apply warp + vec2 pos; + #ifdef CRTS_WARP + // Convert to {-1 to 1} range + pos = ipos * twoDivOutputSize - vec2(1.0, 1.0); + + // Distort pushes image outside {-1 to 1} range + pos *= vec2( + 1.0 + (pos.y * pos.y) * warp.x, + 1.0 + (pos.x * pos.x) * warp.y); + + // TODO: Vignette needs optimization + float vin = 1.0 - ( + (1.0 - CrtsSatF1(pos.x * pos.x)) * (1.0 - CrtsSatF1(pos.y * pos.y))); + vin = CrtsSatF1((-vin) * inputHeight + inputHeight); + + // Leave in {0 to inputSize} + pos = pos * halfInputSize + halfInputSize; + #else + pos = ipos * inputSizeDivOutputSize; + #endif + + // Snap to center of first scanline + float y0 = floor(pos.y - 0.5) + 0.5; + // Snap to center of one of four pixels + float x0 = floor(pos.x - 1.5) + 0.5; + + // Inital UV position + vec2 p = vec2(x0 * rcpInputSize.x, y0 * rcpInputSize.y); + // Fetch 4 nearest texels from 2 nearest scanlines + vec3 colA0 = CrtsFetch(p); + p.x += rcpInputSize.x; + vec3 colA1 = CrtsFetch(p); + p.x += rcpInputSize.x; + vec3 colA2 = CrtsFetch(p); + p.x += rcpInputSize.x; + vec3 colA3 = CrtsFetch(p); + p.y += rcpInputSize.y; + vec3 colB3 = CrtsFetch(p); + p.x -= rcpInputSize.x; + vec3 colB2 = CrtsFetch(p); + p.x -= rcpInputSize.x; + vec3 colB1 = CrtsFetch(p); + p.x -= rcpInputSize.x; + vec3 colB0 = CrtsFetch(p); + + // Vertical filter + // Scanline intensity is using sine wave + // Easy filter window and integral used later in exposure + float off = pos.y - y0; + float pi2 = 6.28318530717958; + float hlf = 0.5; + float scanA = cos(min(0.5, off * thin) * pi2) * hlf + hlf; + float scanB = cos(min(0.5, (-off) * thin + thin) * pi2) * hlf + hlf; + + // Horizontal kernel is simple gaussian filter + float off0 = pos.x - x0; + float off1 = off0 - 1.0; + float off2 = off0 - 2.0; + float off3 = off0 - 3.0; + float pix0 = exp2(blur * off0 * off0); + float pix1 = exp2(blur * off1 * off1); + float pix2 = exp2(blur * off2 * off2); + float pix3 = exp2(blur * off3 * off3); + float pixT = CrtsRcpF1(pix0 + pix1 + pix2 + pix3); + + #ifdef CRTS_WARP + // Get rid of wrong pixels on edge + pixT *= max(MIN_VIN, vin); + #endif + + scanA *= pixT; + scanB *= pixT; + + // Apply horizontal and vertical filters + vec3 color = + (colA0 * pix0 + colA1 * pix1 + colA2 * pix2 + colA3 * pix3) * scanA + + (colB0 * pix0 + colB1 * pix1 + colB2 * pix2 + colB3 * pix3) * scanB; + + // Apply phosphor mask + color *= CrtsMask(ipos, mask); + + // Tonal control, start by protecting from /0 + float peak = max(1.0 / (256.0 * 65536.0), + CrtsMax3F1(color.r, color.g, color.b)); + // Compute the ratios of {R,G,B} + vec3 ratio = color * CrtsRcpF1(peak); + // Apply tonal curve to peak value + peak = peak * CrtsRcpF1(peak * tone.x + tone.y); + // Reconstruct color + return ratio * peak; +} + +float ToSrgb1(float c) { + return (c < 0.0031308 ? c * 12.92 : 1.055 * pow(c, 0.41666) - 0.055); +} +vec3 ToSrgb(vec3 c) { + return vec3( + ToSrgb1(c.r), ToSrgb1(c.g), ToSrgb1(c.b)); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + float aspect = iResolution.x / iResolution.y; + fragColor.rgb = CrtsFilter( + fragCoord.xy, + vec2(1.0), + iResolution.xy * SCALE * 0.5, + 1.0 / (iResolution.xy * SCALE), + 1.0 / iResolution.xy, + 2.0 / iResolution.xy, + iResolution.y, + vec2(1.0 / (50.0 * aspect), 1.0 / 50.0), + INPUT_THIN, + INPUT_BLUR, + INPUT_MASK, + CrtsTone(INPUT_THIN, INPUT_MASK) + ); + + // Linear to SRGB for output. + fragColor = vec4(ToSrgb(fragColor.rgb), 1.0); +} diff --git a/.config/ghostty/shaders/cubes.glsl b/.config/ghostty/shaders/cubes.glsl new file mode 100644 index 0000000..2a09505 --- /dev/null +++ b/.config/ghostty/shaders/cubes.glsl @@ -0,0 +1,114 @@ +// credits: https://github.com/rymdlego + +const float speed = 0.2; +const float cube_size = 1.0; +const float cube_brightness = 1.0; +const float cube_rotation_speed = 2.8; +const float camera_rotation_speed = 0.1; + + + +mat3 rotationMatrix(vec3 m,float a) { + m = normalize(m); + float c = cos(a),s=sin(a); + return mat3(c+(1.-c)*m.x*m.x, + (1.-c)*m.x*m.y-s*m.z, + (1.-c)*m.x*m.z+s*m.y, + (1.-c)*m.x*m.y+s*m.z, + c+(1.-c)*m.y*m.y, + (1.-c)*m.y*m.z-s*m.x, + (1.-c)*m.x*m.z-s*m.y, + (1.-c)*m.y*m.z+s*m.x, + c+(1.-c)*m.z*m.z); +} + +float sphere(vec3 pos, float radius) +{ + return length(pos) - radius; +} + +float box(vec3 pos, vec3 size) +{ + float t = iTime; + pos = pos * 0.9 * rotationMatrix(vec3(sin(t/4.0*speed)*10.,cos(t/4.0*speed)*12.,2.7), t*2.4/4.0*speed*cube_rotation_speed); + return length(max(abs(pos) - size, 0.0)); +} + + +float distfunc(vec3 pos) +{ + float t = iTime; + + float size = 0.45 + 0.25*abs(16.0*sin(t*speed/4.0)); + // float size = 2.3 + 1.8*tan((t-5.4)*6.549); + size = cube_size * 0.16 * clamp(size, 2.0, 4.0); + + //pos = pos * rotationMatrix(vec3(0.,-3.,0.7), 3.3 * mod(t/30.0, 4.0)); + vec3 q = mod(pos, 5.0) - 2.5; + float obj1 = box(q, vec3(size)); + return obj1; +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + float t = iTime; + vec2 screenPos = -1.0 + 2.0 * fragCoord.xy / iResolution.xy; + screenPos.x *= iResolution.x / iResolution.y; + vec3 cameraOrigin = vec3(t*1.0*speed, 0.0, 0.0); + // vec3 cameraOrigin = vec3(t*1.8*speed, 3.0+t*0.02*speed, 0.0); + vec3 cameraTarget = vec3(t*100., 0.0, 0.0); + cameraTarget = vec3(t*20.0,0.0,0.0) * rotationMatrix(vec3(0.0,0.0,1.0), t*speed*camera_rotation_speed); + + vec3 upDirection = vec3(0.5, 1.0, 0.6); + + vec3 cameraDir = normalize(cameraTarget - cameraOrigin); + vec3 cameraRight = normalize(cross(upDirection, cameraOrigin)); + vec3 cameraUp = cross(cameraDir, cameraRight); + + vec3 rayDir = normalize(cameraRight * screenPos.x + cameraUp * screenPos.y + cameraDir); + + const int MAX_ITER = 64; + const float MAX_DIST = 48.0; + const float EPSILON = 0.001; + + float totalDist = 0.0; + vec3 pos = cameraOrigin; + float dist = EPSILON; + + for (int i = 0; i < MAX_ITER; i++) + { + if (dist < EPSILON || totalDist > MAX_DIST) + break; + dist = distfunc(pos); + totalDist += dist; + pos += dist*rayDir; + } + + vec4 cubes; + + if (dist < EPSILON) + { + // Lighting Code + vec2 eps = vec2(0.0, EPSILON); + vec3 normal = normalize(vec3( + distfunc(pos + eps.yxx) - distfunc(pos - eps.yxx), + distfunc(pos + eps.xyx) - distfunc(pos - eps.xyx), + distfunc(pos + eps.xxy) - distfunc(pos - eps.xxy))); + float diffuse = max(0., dot(-rayDir, normal)); + float specular = pow(diffuse, 32.0); + vec3 color = vec3(diffuse + specular); + vec3 cubeColor = vec3(abs(screenPos),0.5+0.5*sin(t*2.0))*0.8; + cubeColor = mix(cubeColor.rgb, vec3(0.0,0.0,0.0), 1.0); + color += cubeColor; + cubes = vec4(color, 1.0) * vec4(1.0 - (totalDist/MAX_DIST)); + cubes = vec4(cubes.rgb*0.02*cube_brightness, 0.1); + } + else { + cubes = vec4(0.0); + } + + vec2 uv = fragCoord/iResolution.xy; + vec4 terminalColor = texture(iChannel0, uv); + vec3 blendedColor = terminalColor.rgb + cubes.rgb; + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/cursor_blaze.glsl b/.config/ghostty/shaders/cursor_blaze.glsl new file mode 100644 index 0000000..2bb9a12 --- /dev/null +++ b/.config/ghostty/shaders/cursor_blaze.glsl @@ -0,0 +1,142 @@ +// Based on https://gist.github.com/chardskarth/95874c54e29da6b5a36ab7b50ae2d088 +float ease(float x) { + return pow(1.0 - x, 10.0); +} + +float sdBox(in vec2 p, in vec2 xy, in vec2 b) +{ + vec2 d = abs(p - xy) - b; + return length(max(d, 0.0)) + min(max(d.x, d.y), 0.0); +} + +float getSdfRectangle(in vec2 p, in vec2 xy, in vec2 b) +{ + vec2 d = abs(p - xy) - b; + return length(max(d, 0.0)) + min(max(d.x, d.y), 0.0); +} +// Based on Inigo Quilez's 2D distance functions article: https://iquilezles.org/articles/distfunctions2d/ +// Potencially optimized by eliminating conditionals and loops to enhance performance and reduce branching +float seg(in vec2 p, in vec2 a, in vec2 b, inout float s, float d) { + vec2 e = b - a; + vec2 w = p - a; + vec2 proj = a + e * clamp(dot(w, e) / dot(e, e), 0.0, 1.0); + float segd = dot(p - proj, p - proj); + d = min(d, segd); + + float c0 = step(0.0, p.y - a.y); + float c1 = 1.0 - step(0.0, p.y - b.y); + float c2 = 1.0 - step(0.0, e.x * w.y - e.y * w.x); + float allCond = c0 * c1 * c2; + float noneCond = (1.0 - c0) * (1.0 - c1) * (1.0 - c2); + float flip = mix(1.0, -1.0, step(0.5, allCond + noneCond)); + s *= flip; + return d; +} + +float getSdfParallelogram(in vec2 p, in vec2 v0, in vec2 v1, in vec2 v2, in vec2 v3) { + float s = 1.0; + float d = dot(p - v0, p - v0); + + d = seg(p, v0, v3, s, d); + d = seg(p, v1, v0, s, d); + d = seg(p, v2, v1, s, d); + d = seg(p, v3, v2, s, d); + + return s * sqrt(d); +} + +vec2 normalize(vec2 value, float isPosition) { + return (value * 2.0 - (iResolution.xy * isPosition)) / iResolution.y; +} + +float blend(float t) +{ + float sqr = t * t; + return sqr / (2.0 * (sqr - t) + 1.0); +} + +float antialising(float distance) { + return 1. - smoothstep(0., normalize(vec2(2., 2.), 0.).x, distance); +} + +float determineStartVertexFactor(vec2 a, vec2 b) { + // Conditions using step + float condition1 = step(b.x, a.x) * step(a.y, b.y); // a.x < b.x && a.y > b.y + float condition2 = step(a.x, b.x) * step(b.y, a.y); // a.x > b.x && a.y < b.y + + // If neither condition is met, return 1 (else case) + return 1.0 - max(condition1, condition2); +} +vec2 getRectangleCenter(vec4 rectangle) { + return vec2(rectangle.x + (rectangle.z / 2.), rectangle.y - (rectangle.w / 2.)); +} + +const vec4 TRAIL_COLOR = vec4(1.0, 0.725, 0.161, 1.0); // yellow +const vec4 CURRENT_CURSOR_COLOR = TRAIL_COLOR; +const vec4 PREVIOUS_CURSOR_COLOR = TRAIL_COLOR; +const vec4 TRAIL_COLOR_ACCENT = vec4(1.0, 0., 0., 1.0); // red-orange +const float DURATION = .5; +const float OPACITY = .2; +// Don't draw trail within that distance * cursor size. +// This prevents trails from appearing when typing. +const float DRAW_THRESHOLD = 1.5; +// Don't draw trails within the same line: same line jumps are usually where +// people expect them. +const bool HIDE_TRAILS_ON_THE_SAME_LINE = false; + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + #if !defined(WEB) + fragColor = texture(iChannel0, fragCoord.xy / iResolution.xy); + #endif + //Normalization for fragCoord to a space of -1 to 1; + vec2 vu = normalize(fragCoord, 1.); + vec2 offsetFactor = vec2(-.5, 0.5); + + //Normalization for cursor position and size; + //cursor xy has the postion in a space of -1 to 1; + //zw has the width and height + vec4 currentCursor = vec4(normalize(iCurrentCursor.xy, 1.), normalize(iCurrentCursor.zw, 0.)); + vec4 previousCursor = vec4(normalize(iPreviousCursor.xy, 1.), normalize(iPreviousCursor.zw, 0.)); + + //When drawing a parellelogram between cursors for the trail i need to determine where to start at the top-left or top-right vertex of the cursor + float vertexFactor = determineStartVertexFactor(currentCursor.xy, previousCursor.xy); + float invertedVertexFactor = 1.0 - vertexFactor; + + //Set every vertex of my parellogram + vec2 v0 = vec2(currentCursor.x + currentCursor.z * vertexFactor, currentCursor.y - currentCursor.w); + vec2 v1 = vec2(currentCursor.x + currentCursor.z * invertedVertexFactor, currentCursor.y); + vec2 v2 = vec2(previousCursor.x + currentCursor.z * invertedVertexFactor, previousCursor.y); + vec2 v3 = vec2(previousCursor.x + currentCursor.z * vertexFactor, previousCursor.y - previousCursor.w); + + vec4 newColor = vec4(fragColor); + + float progress = blend(clamp((iTime - iTimeCursorChange) / DURATION, 0.0, 1)); + float easedProgress = ease(progress); + + //Distance between cursors determine the total length of the parallelogram; + vec2 centerCC = getRectangleCenter(currentCursor); + vec2 centerCP = getRectangleCenter(previousCursor); + float cursorSize = max(currentCursor.z, currentCursor.w); + float trailThreshold = DRAW_THRESHOLD * cursorSize; + float lineLength = distance(centerCC, centerCP); + // + bool isFarEnough = lineLength > trailThreshold; + bool isOnSeparateLine = HIDE_TRAILS_ON_THE_SAME_LINE ? currentCursor.y != previousCursor.y : true; + if (isFarEnough && isOnSeparateLine) { + float distanceToEnd = distance(vu.xy, centerCC); + float alphaModifier = distanceToEnd / (lineLength * (easedProgress)); + + if (alphaModifier > 1.0) { // this change fixed it for me. + alphaModifier = 1.0; + } + + float sdfCursor = getSdfRectangle(vu, currentCursor.xy - (currentCursor.zw * offsetFactor), currentCursor.zw * 0.5); + float sdfTrail = getSdfParallelogram(vu, v0, v1, v2, v3); + + newColor = mix(newColor, TRAIL_COLOR_ACCENT, 1.0 - smoothstep(sdfTrail, -0.01, 0.001)); + newColor = mix(newColor, TRAIL_COLOR, antialising(sdfTrail)); + newColor = mix(fragColor, newColor, 1.0 - alphaModifier); + fragColor = mix(newColor, fragColor, step(sdfCursor, 0)); + } +} diff --git a/.config/ghostty/shaders/cursor_sweep.glsl b/.config/ghostty/shaders/cursor_sweep.glsl new file mode 100644 index 0000000..871f3d2 --- /dev/null +++ b/.config/ghostty/shaders/cursor_sweep.glsl @@ -0,0 +1,216 @@ +// -- CONFIGURATION --- +vec4 TRAIL_COLOR = iCurrentCursorColor; // can change to eg: vec4(0.2, 0.6, 1.0, 0.5); +const float DURATION = 0.2; // in seconds +const float TRAIL_LENGTH = 0.5; +const float BLUR = 2.0; // blur size in pixels (for antialiasing) + +// --- CONSTANTS for easing functions --- +const float PI = 3.14159265359; +const float C1_BACK = 1.70158; +const float C2_BACK = C1_BACK * 1.525; +const float C3_BACK = C1_BACK + 1.0; +const float C4_ELASTIC = (2.0 * PI) / 3.0; +const float C5_ELASTIC = (2.0 * PI) / 4.5; +const float SPRING_STIFFNESS = 9.0; +const float SPRING_DAMPING = 0.9; + +// --- EASING FUNCTIONS --- + +// // Linear +// float ease(float x) { +// return x; +// } + +// // EaseOutQuad +// float ease(float x) { +// return 1.0 - (1.0 - x) * (1.0 - x); +// } + +// EaseOutCubic +float ease(float x) { + return 1.0 - pow(1.0 - x, 3.0); +} + +// // EaseOutQuart +// float ease(float x) { +// return 1.0 - pow(1.0 - x, 4.0); +// } + +// // EaseOutQuint +// float ease(float x) { +// return 1.0 - pow(1.0 - x, 5.0); +// } + +// EaseOutSine +// float ease(float x) { +// return sin((x * PI) / 2.0); +// } + +// // EaseOutExpo +// float ease(float x) { +// return x == 1.0 ? 1.0 : 1.0 - pow(2.0, -10.0 * x); +// } + +// // EaseOutCirc +// float ease(float x) { +// return sqrt(1.0 - pow(x - 1.0, 2.0)); +// } + +// // EaseOutBack +// float ease(float x) { +// return 1.0 + C3_BACK * pow(x - 1.0, 3.0) + C1_BACK * pow(x - 1.0, 2.0); +// } + +// // EaseOutElastic +// float ease(float x) { +// return x == 0.0 ? 0.0 +// : x == 1.0 ? 1.0 +// : pow(2.0, -10.0 * x) * sin((x * 10.0 - 0.75) * C4_ELASTIC) + 1.0; +// } + +// Parametric Spring +// float ease(float x) { +// x = clamp(x, 0.0, 1.0); +// float decay = exp(-SPRING_DAMPING * SPRING_STIFFNESS * x); +// float freq = sqrt(SPRING_STIFFNESS * (1.0 - SPRING_DAMPING * SPRING_DAMPING)); +// float osc = cos(freq * 6.283185 * x) + (SPRING_DAMPING * sqrt(SPRING_STIFFNESS) / freq) * sin(freq * 6.283185 * x); +// return 1.0 - decay * osc; +// } + +float getSdfRectangle(in vec2 point, in vec2 center, in vec2 halfSize) +{ + vec2 d = abs(point - center) - halfSize; + return length(max(d, 0.0)) + min(max(d.x, d.y), 0.0); +} + +// Based on Inigo Quilez's 2D distance functions article: https://iquilezles.org/articles/distfunctions2d/ +// Potencially optimized by eliminating conditionals and loops to enhance performance and reduce branching + +float seg(in vec2 p, in vec2 a, in vec2 b, inout float s, float d) { + vec2 e = b - a; + vec2 w = p - a; + vec2 proj = a + e * clamp(dot(w, e) / dot(e, e), 0.0, 1.0); + float segd = dot(p - proj, p - proj); + d = min(d, segd); + + float c0 = step(0.0, p.y - a.y); + float c1 = 1.0 - step(0.0, p.y - b.y); + float c2 = 1.0 - step(0.0, e.x * w.y - e.y * w.x); + float allCond = c0 * c1 * c2; + float noneCond = (1.0 - c0) * (1.0 - c1) * (1.0 - c2); + float flip = mix(1.0, -1.0, step(0.5, allCond + noneCond)); + s *= flip; + return d; +} + +float getSdfParallelogram(in vec2 p, in vec2 v0, in vec2 v1, in vec2 v2, in vec2 v3) { + float s = 1.0; + float d = dot(p - v0, p - v0); + + d = seg(p, v0, v3, s, d); + d = seg(p, v1, v0, s, d); + d = seg(p, v2, v1, s, d); + d = seg(p, v3, v2, s, d); + + return s * sqrt(d); +} + +vec2 normalize(vec2 value, float isPosition) { + return (value * 2.0 - (iResolution.xy * isPosition)) / iResolution.y; +} + +float antialising(float distance) { + return 1. - smoothstep(0., normalize(vec2(BLUR, BLUR), 0.).x, distance); +} + +float getTopVertexFlag(vec2 a, vec2 b) { + float condition1 = step(b.x, a.x) * step(a.y, b.y); // a.x < b.x && a.y > b.y + float condition2 = step(a.x, b.x) * step(b.y, a.y); // a.x > b.x && a.y < b.y + + // if neither condition is met, return 1 (else case) + return 1.0 - max(condition1, condition2); +} + +vec2 getRectangleCenter(vec4 rectangle) { + return vec2(rectangle.x + (rectangle.z / 2.), rectangle.y - (rectangle.w / 2.)); +} + + +void mainImage(out vec4 fragColor, in vec2 fragCoord){ + #if !defined(WEB) + fragColor = texture(iChannel0, fragCoord.xy / iResolution.xy); + #endif + + // normalization & setup(-1, 1 coords) + vec2 vu = normalize(fragCoord, 1.); + vec2 offsetFactor = vec2(-.5, 0.5); + + vec4 currentCursor = vec4(normalize(iCurrentCursor.xy, 1.), normalize(iCurrentCursor.zw, 0.)); + vec4 previousCursor = vec4(normalize(iPreviousCursor.xy, 1.), normalize(iPreviousCursor.zw, 0.)); + + vec2 centerCC = currentCursor.xy - (currentCursor.zw * offsetFactor); + vec2 centerCP = previousCursor.xy - (previousCursor.zw * offsetFactor); + + float sdfCurrentCursor = getSdfRectangle(vu, centerCC, currentCursor.zw * 0.5); + + float lineLength = distance(centerCC, centerCP); + + vec4 newColor = vec4(fragColor); + + float minDist = currentCursor.w * 1.5; + float progress = clamp((iTime - iTimeCursorChange) / DURATION, 0.0, 1.0); + if (lineLength > minDist) { + // --- Animation Logic --- + float shrinkFactor = ease(progress); + + // detect straight moves + vec2 delta = abs(centerCC - centerCP); + float threshold = 0.001; + float isHorizontal = step(delta.y, threshold); + float isVertical = step(delta.x, threshold); + float isStraightMove = max(isHorizontal, isVertical); + + // -- Making parallelogram sdf (diagonal moves) --- + float topVertexFlag = getTopVertexFlag(currentCursor.xy, previousCursor.xy); + float bottomVertexFlag = 1.0 - topVertexFlag; + vec2 v0 = vec2(currentCursor.x + currentCursor.z * topVertexFlag, currentCursor.y - currentCursor.w); + vec2 v1 = vec2(currentCursor.x + currentCursor.z * bottomVertexFlag, currentCursor.y); + vec2 v2_full = vec2(previousCursor.x + currentCursor.z * bottomVertexFlag, previousCursor.y); + vec2 v3_full = vec2(previousCursor.x + currentCursor.z * topVertexFlag, previousCursor.y - previousCursor.w); + + vec2 v2_start = mix(v1, v2_full, TRAIL_LENGTH); + vec2 v3_start = mix(v0, v3_full, TRAIL_LENGTH); + vec2 v2_anim = mix(v2_start, v1, shrinkFactor); + vec2 v3_anim = mix(v3_start, v0, shrinkFactor); + + float sdfTrail_diag = getSdfParallelogram(vu, v0, v1, v2_anim, v3_anim); + + // --- Making rectangle sdf (straight moves) --- + vec2 min_center = min(centerCP, centerCC); + vec2 max_center = max(centerCP, centerCC); + + vec2 bBoxSize_full = (max_center - min_center) + currentCursor.zw; + vec2 bBoxCenter_full = (min_center + max_center) * 0.5; + + vec2 bBoxSize_start = mix(currentCursor.zw, bBoxSize_full, TRAIL_LENGTH); + vec2 bBoxCenter_start = mix(centerCC, bBoxCenter_full, TRAIL_LENGTH); + + vec2 animSize = mix(bBoxSize_start, currentCursor.zw, shrinkFactor); + vec2 animCenter = mix(bBoxCenter_start, centerCC, shrinkFactor); + + float sdfTrail_rect = getSdfRectangle(vu, animCenter, animSize * 0.5); + + // -- Selecting and drawing the trail sdf -- + float sdfTrail = mix(sdfTrail_diag, sdfTrail_rect, isStraightMove); + + vec4 trail = TRAIL_COLOR; + float trailAlpha = antialising(sdfTrail); + newColor = mix(newColor, trail, trailAlpha); + + // Punch hole + newColor = mix(newColor, fragColor, step(sdfCurrentCursor, 0.)); + } + + + fragColor = newColor; +} diff --git a/.config/ghostty/shaders/dither.glsl b/.config/ghostty/shaders/dither.glsl new file mode 100644 index 0000000..7bfe740 --- /dev/null +++ b/.config/ghostty/shaders/dither.glsl @@ -0,0 +1,30 @@ +// Simple "dithering" effect +// (c) moni-dz (https://github.com/moni-dz) +// CC BY-NC-SA 4.0 (https://creativecommons.org/licenses/by-nc-sa/4.0/) + +// Packed bayer pattern using bit manipulation +const float bayerPattern[4] = float[4]( + 0x0514, // Encoding 0,8,2,10 + 0xC4E6, // Encoding 12,4,14,6 + 0x3B19, // Encoding 3,11,1,9 + 0xF7D5 // Encoding 15,7,13,5 +); + +float getBayerFromPacked(int x, int y) { + int idx = (x & 3) + ((y & 3) << 2); + return float((int(bayerPattern[y & 3]) >> ((x & 3) << 2)) & 0xF) * (1.0 / 16.0); +} + +#define LEVELS 2.0 // Available color steps per channel +#define INV_LEVELS (1.0 / LEVELS) + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = fragCoord * (1.0 / iResolution.xy); + vec3 color = texture(iChannel0, uv).rgb; + + float threshold = getBayerFromPacked(int(fragCoord.x), int(fragCoord.y)); + vec3 dithered = floor(color * LEVELS + threshold) * INV_LEVELS; + + fragColor = vec4(dithered, 1.0); +} diff --git a/.config/ghostty/shaders/drunkard.glsl b/.config/ghostty/shaders/drunkard.glsl new file mode 100644 index 0000000..e900d4a --- /dev/null +++ b/.config/ghostty/shaders/drunkard.glsl @@ -0,0 +1,68 @@ +// Drunken stupor effect using fractal Brownian motion and Perlin noise +// (c) moni-dz (https://github.com/moni-dz) +// CC BY-NC-SA 4.0 (https://creativecommons.org/licenses/by-nc-sa/4.0/) + +vec2 hash2(vec2 p) { + uvec2 q = uvec2(floatBitsToUint(p.x), floatBitsToUint(p.y)); + q = (q * uvec2(1597334673U, 3812015801U)) ^ (q.yx * uvec2(2798796415U, 1979697793U)); + return vec2(q) * (1.0/float(0xffffffffU)) * 2.0 - 1.0; +} + +float perlin2d(vec2 p) { + vec2 i = floor(p); + vec2 f = fract(p); + vec2 u = f*f*(3.0-2.0*f); + + return mix(mix(dot(hash2(i + vec2(0.0,0.0)), f - vec2(0.0,0.0)), + dot(hash2(i + vec2(1.0,0.0)), f - vec2(1.0,0.0)), u.x), + mix(dot(hash2(i + vec2(0.0,1.0)), f - vec2(0.0,1.0)), + dot(hash2(i + vec2(1.0,1.0)), f - vec2(1.0,1.0)), u.x), u.y); +} + +#define OCTAVES 10 // How many passes of fractal Brownian motion to perform +#define GAIN 0.5 // How much should each pixel move +#define LACUNARITY 2.0 // How fast should each ripple be per pass + +float fbm(vec2 p) { + float sum = 0.0; + float amp = 0.5; + float freq = 1.0; + + for(int i = 0; i < OCTAVES; i++) { + sum += amp * perlin2d(p * freq); + freq *= LACUNARITY; + amp *= GAIN; + } + + return sum; +} + + +#define NOISE_SCALE 1.0 // How distorted the image you want to be +#define NOISE_INTENSITY 0.05 // How strong the noise effect is +#define ABERRATION true // Chromatic aberration +#define ABERRATION_DELTA 0.1 // How strong the chromatic aberration effect is +#define ANIMATE true +#define SPEED 0.4 // Animation speed + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = fragCoord/iResolution.xy; + float time = ANIMATE ? iTime * SPEED : 0.0; + + vec2 noisePos = uv * NOISE_SCALE + vec2(time); + float noise = fbm(noisePos) * NOISE_INTENSITY; + + vec3 col; + + if (ABERRATION) { + col.r = texture(iChannel0, uv + vec2(noise * (1.0 + ABERRATION_DELTA))).r; + col.g = texture(iChannel0, uv + vec2(noise)).g; + col.b = texture(iChannel0, uv + vec2(noise * (1.0 - ABERRATION_DELTA))).b; + } else { + vec2 distortedUV = uv + vec2(noise); + col = texture(iChannel0, distortedUV).rgb; + } + + fragColor = vec4(col, 1.0); +} diff --git a/.config/ghostty/shaders/fireworks-rockets.glsl b/.config/ghostty/shaders/fireworks-rockets.glsl new file mode 100644 index 0000000..e2f0b5a --- /dev/null +++ b/.config/ghostty/shaders/fireworks-rockets.glsl @@ -0,0 +1,109 @@ +// This Ghostty shader is a lightly modified port of https://www.shadertoy.com/view/4dBGRw + +#define BLACK_BLEND_THRESHOLD .4 + +//Creates a diagonal red-and-white striped pattern. +vec3 barberpole(vec2 pos, vec2 rocketpos) { + float d = (pos.x - rocketpos.x) + (pos.y - rocketpos.y); + vec3 col = vec3(1.0); + + d = mod(d * 20., 2.0); + if (d > 1.0) { + col = vec3(1.0, 0.0, 0.0); + } + + return col; +} + +vec3 rocket(vec2 pos, vec2 rocketpos) { + vec3 col = vec3(0.0); + float f = 0.; + float absx = abs(rocketpos.x - pos.x); + float absy = abs(rocketpos.y - pos.y); + + // Wooden stick + if (absx < 0.01 && absy < 0.22) { + col = vec3(1.0, 0.5, 0.5); + } + + // Barberpole + if (absx < 0.05 && absy < 0.15) { + col = barberpole(pos, rocketpos); + } + + // Rocket Point + float pointw = (rocketpos.y - pos.y - 0.25) * -0.7; + if ((rocketpos.y - pos.y) > 0.1) { + f = smoothstep(pointw - 0.001, pointw + 0.001, absx); + + col = mix(vec3(1.0, 0.0, 0.0), col, f); + } + + // Shadow + f = -.5 + smoothstep(-0.05, 0.05, (rocketpos.x - pos.x)); + col *= 0.7 + f; + + return col; +} + +float rand(float val, float seed) { + return cos(val * sin(val * seed) * seed); +} + +float distance2(in vec2 a, in vec2 b) { + return dot(a - b, a - b); +} + +mat2 rr = mat2(cos(1.0), -sin(1.0), sin(1.0), cos(1.0)); + +vec3 drawParticles(vec2 pos, vec3 particolor, float time, vec2 cpos, float gravity, float seed, float timelength) { + vec3 col = vec3(0.0); + vec2 pp = vec2(1.0, 0.0); + for (float i = 1.0; i <= 128.0; i++) { + float d = rand(i, seed); + float fade = (i / 128.0) * time; + vec2 particpos = cpos + time * pp * d; + pp = rr * pp; + col = mix(particolor / fade, col, smoothstep(0.0, 0.0001, distance2(particpos, pos))); + } + col *= smoothstep(0.0, 1.0, (timelength - time) / timelength); + + return col; +} +vec3 drawFireworks(float time, vec2 uv, vec3 particolor, float seed) { + float timeoffset = 2.0; + vec3 col = vec3(0.0); + if (time <= 0.) { + return col; + } + if (mod(time, 6.0) > timeoffset) { + col = drawParticles(uv, particolor, mod(time, 6.0) - timeoffset, vec2(rand(ceil(time / 6.0), seed), -0.5), 0.5, ceil(time / 6.0), seed); + } else { + col = rocket(uv * 3., vec2(3. * rand(ceil(time / 6.0), seed), 3. * (-0.5 + (timeoffset - mod(time, 6.0))))); + } + return col; +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = 1.0 - 2.0 * fragCoord.xy / iResolution.xy; + uv.x *= iResolution.x / iResolution.y; + vec3 col = vec3(0.1, 0.1, 0.2); + + // Flip the y-axis so that the rocket is drawn from the bottom of the screen + uv.y = -uv.y; + + col += 0.1 * uv.y; + + col += drawFireworks(iTime, uv, vec3(1.0, 0.1, 0.1), 1.); + col += drawFireworks(iTime - 2.0, uv, vec3(0.0, 1.0, 0.5), 2.); + col += drawFireworks(iTime - 4.0, uv, vec3(1.0, 1.0, 0.1), 3.); + + vec2 termUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, termUV); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb * 1.0, col.rgb * 0.3, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/fireworks.glsl b/.config/ghostty/shaders/fireworks.glsl new file mode 100644 index 0000000..42bc98d --- /dev/null +++ b/.config/ghostty/shaders/fireworks.glsl @@ -0,0 +1,116 @@ +// This Ghostty shader is a port of https://www.shadertoy.com/view/lscGRl + +// "Fireworks" by Martijn Steinrucken aka BigWings - 2015 +// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. +// Email:countfrolic@gmail.com Twitter:@The_ArtOfCode + +#define BLACK_BLEND_THRESHOLD .4 +#define PI 3.141592653589793238 +#define TWOPI 6.283185307179586 +#define S(x,y,z) smoothstep(x,y,z) +#define B(x,y,z,w) S(x-z, x+z, w)*S(y+z, y-z, w) +#define saturate(x) clamp(x,0.,1.) + +#define NUM_EXPLOSIONS 3. +#define NUM_PARTICLES 42. + +// Noise functions by Dave Hoskins +#define MOD3 vec3(.1031,.11369,.13787) +vec3 hash31(float p) { + vec3 p3 = fract(vec3(p) * MOD3); + p3 += dot(p3, p3.yzx + 19.19); + return fract(vec3((p3.x + p3.y) * p3.z, (p3.x + p3.z) * p3.y, (p3.y + p3.z) * p3.x)); +} +float hash12(vec2 p) { + vec3 p3 = fract(vec3(p.xyx) * MOD3); + p3 += dot(p3, p3.yzx + 19.19); + return fract((p3.x + p3.y) * p3.z); +} + +float circ(vec2 uv, vec2 pos, float size) { + uv -= pos; + + size *= size; + return S(size * 1.1, size, dot(uv, uv)); +} + +float light(vec2 uv, vec2 pos, float size) { + uv -= pos; + + size *= size; + return size / dot(uv, uv); +} + +vec3 explosion(vec2 uv, vec2 p, float seed, float t) { + vec3 col = vec3(0.); + + vec3 en = hash31(seed); + vec3 baseCol = en; + for (float i = 0.; i < NUM_PARTICLES; i++) { + vec3 n = hash31(i) - .5; + + vec2 startP = p - vec2(0., t * t * .1); + vec2 endP = startP + normalize(n.xy) * n.z - vec2(0., t * .2); + + float pt = 1. - pow(t - 1., 2.); + vec2 pos = mix(p, endP, pt); + float size = mix(.01, .005, S(0., .1, pt)); + size *= S(1., .1, pt); + + float sparkle = (sin((pt + n.z) * 21.) * .5 + .5); + sparkle = pow(sparkle, pow(en.x, 3.) * 50.) * mix(0.01, .01, en.y * n.y); + + //size += sparkle*B(.6, 1., .1, t); + size += sparkle * B(en.x, en.y, en.z, t); + + col += baseCol * light(uv, pos, size); + } + + return col; +} + +vec3 Rainbow(vec3 c) { + float t = iTime; + + float avg = (c.r + c.g + c.b) / 3.; + c = avg + (c - avg) * sin(vec3(0., .333, .666) + t); + + c += sin(vec3(.4, .3, .3) * t + vec3(1.1244, 3.43215, 6.435)) * vec3(.4, .1, .5); + + return c; +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = fragCoord.xy / iResolution.xy; + uv.x -= .5; + uv.x *= iResolution.x / iResolution.y; + + // Flip the y-axis so that the gravity is downwards + uv.y = -uv.y + 1.; + + float n = hash12(uv + 10.); + float t = iTime * .5; + + vec3 c = vec3(0.); + + for (float i = 0.; i < NUM_EXPLOSIONS; i++) { + float et = t + i * 1234.45235; + float id = floor(et); + et -= id; + + vec2 p = hash31(id).xy; + p.x -= .5; + p.x *= 1.6; + c += explosion(uv, p, id, et); + } + c = Rainbow(c); + + vec2 termUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, termUV); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb * 1.0, c.rgb * 0.3, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/galaxy.glsl b/.config/ghostty/shaders/galaxy.glsl new file mode 100644 index 0000000..8a7eda9 --- /dev/null +++ b/.config/ghostty/shaders/galaxy.glsl @@ -0,0 +1,139 @@ +float triangle(float x, float period) { + return 2.0 * abs(3.0* ((x / period) - floor((x / period) + 0.5))) - 1.0; +} + +float field(in vec3 position) { + float strength = 7.0 + 0.03 * log(1.0e-6 + fract(sin(iTime) * 373.11)); + float accumulated = 0.0; + float previousMagnitude = 0.0; + float totalWeight = 0.0; + + for (int i = 0; i < 6; ++i) { + float magnitude = dot(position, position); + position = abs(position) / magnitude + vec3(-0.5, -0.8 + 0.1 * sin(-iTime * 0.1 + 2.0), -1.1 + 0.3 * cos(iTime * 0.3)); + float weight = exp(-float(i) / 7.0); + accumulated += weight * exp(-strength * pow(abs(magnitude - previousMagnitude), 2.3)); + totalWeight += weight; + previousMagnitude = magnitude; + } + + return max(0.0, 5.0 * accumulated / totalWeight - 0.7); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + const float baseSpeed = 0.02; + const int maxIterations = 16; + const float formulaParameter = 0.79; + const float volumeSteps = 7.0; + const float stepSize = 0.24; + const float zoomFactor = 0.1; + const float tilingFactor = 0.85; + const float baseBrightness = 0.0008; + const float darkMatter = 0.2; + const float distanceFading = 0.56; + const float colorSaturation = 0.9; + const float transverseMotion = 0.2; + const float cloudOpacity = 0.48; + const float zoomSpeed = 0.0002; + + vec2 normalizedCoordinates = 2.0 * fragCoord.xy / vec2(512) - 1.0; + vec2 scaledCoordinates = normalizedCoordinates * vec2(512) / 512.0; + + float timeElapsed = iTime; + float speedAdjustment = -baseSpeed; + float formulaAdjustment = formulaParameter; + + speedAdjustment = zoomSpeed * cos(iTime * 0.02 + 3.1415926 / 4.0); + + vec2 uvCoordinates = scaledCoordinates; + + float rotationXZ = 0.9; + float rotationYZ = -0.6; + float rotationXY = 0.9 + iTime * 0.08; + + mat2 rotationMatrixXZ = mat2(vec2(cos(rotationXZ), sin(rotationXZ)), vec2(-sin(rotationXZ), cos(rotationXZ))); + mat2 rotationMatrixYZ = mat2(vec2(cos(rotationYZ), sin(rotationYZ)), vec2(-sin(rotationYZ), cos(rotationYZ))); + mat2 rotationMatrixXY = mat2(vec2(cos(rotationXY), sin(rotationXY)), vec2(-sin(rotationXY), cos(rotationXY))); + + vec2 canvasCenter = vec2(0.5, 0.5); + vec3 rayDirection = vec3(uvCoordinates * zoomFactor, 1.0); + vec3 cameraPosition = vec3(0.0, 0.0, 0.0); + cameraPosition.x -= 2.0 * (canvasCenter.x - 0.5); + cameraPosition.y -= 2.0 * (canvasCenter.y - 0.5); + + vec3 forwardVector = vec3(0.0, 0.0, 1.0); + cameraPosition.x += transverseMotion * cos(0.01 * iTime) + 0.001 * iTime; + cameraPosition.y += transverseMotion * sin(0.01 * iTime) + 0.001 * iTime; + cameraPosition.z += 0.003 * iTime; + + rayDirection.xz *= rotationMatrixXZ; + forwardVector.xz *= rotationMatrixXZ; + rayDirection.yz *= rotationMatrixYZ; + forwardVector.yz *= rotationMatrixYZ; + + cameraPosition.xy *= -1.0 * rotationMatrixXY; + cameraPosition.xz *= rotationMatrixXZ; + cameraPosition.yz *= rotationMatrixYZ; + + float zoomOffset = (timeElapsed - 3311.0) * speedAdjustment; + cameraPosition += forwardVector * zoomOffset; + float sampleOffset = mod(zoomOffset, stepSize); + float normalizedSampleOffset = sampleOffset / stepSize; + + float stepDistance = 0.24; + float secondaryStepDistance = stepDistance + stepSize / 2.0; + vec3 accumulatedColor = vec3(0.0); + float fieldContribution = 0.0; + vec3 backgroundColor = vec3(0.0); + + for (float stepIndex = 0.0; stepIndex < volumeSteps; ++stepIndex) { + vec3 primaryPosition = cameraPosition + (stepDistance + sampleOffset) * rayDirection; + vec3 secondaryPosition = cameraPosition + (secondaryStepDistance + sampleOffset) * rayDirection; + + primaryPosition = abs(vec3(tilingFactor) - mod(primaryPosition, vec3(tilingFactor * 2.0))); + secondaryPosition = abs(vec3(tilingFactor) - mod(secondaryPosition, vec3(tilingFactor * 2.0))); + + fieldContribution = field(secondaryPosition); + + float particleAccumulator = 0.0, particleDistance = 0.0; + for (int i = 0; i < maxIterations; ++i) { + primaryPosition = abs(primaryPosition) / dot(primaryPosition, primaryPosition) - formulaAdjustment; + float distanceChange = abs(length(primaryPosition) - particleDistance); + particleAccumulator += i > 2 ? min(12.0, distanceChange) : distanceChange; + particleDistance = length(primaryPosition); + } + particleAccumulator *= particleAccumulator * particleAccumulator; + + float fadeFactor = pow(distanceFading, max(0.0, float(stepIndex) - normalizedSampleOffset)); + accumulatedColor += vec3(stepDistance, stepDistance * stepDistance, stepDistance * stepDistance * stepDistance * stepDistance) + * particleAccumulator * baseBrightness * fadeFactor; + backgroundColor += mix(0.4, 1.0, cloudOpacity) * vec3(1.8 * fieldContribution * fieldContribution * fieldContribution, + 1.4 * fieldContribution * fieldContribution, fieldContribution) * fadeFactor; + stepDistance += stepSize; + secondaryStepDistance += stepSize; + } + + accumulatedColor = mix(vec3(length(accumulatedColor)), accumulatedColor, colorSaturation); + + vec4 foregroundColor = vec4(accumulatedColor * 0.01, 1.0); + backgroundColor *= cloudOpacity; + backgroundColor.b *= 1.8; + backgroundColor.r *= 0.05; + + backgroundColor.b = 0.5 * mix(backgroundColor.g, backgroundColor.b, 0.8); + backgroundColor.g = 0.0; + backgroundColor.bg = mix(backgroundColor.gb, backgroundColor.bg, 0.5 * (cos(iTime * 0.01) + 1.0)); + + vec2 terminalUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, terminalUV); + + float brightnessThreshold = 0.1; + float terminalBrightness = dot(terminalColor.rgb, vec3(0.2126, 0.7152, 0.0722)); + + if (terminalBrightness < brightnessThreshold) { + fragColor = mix(terminalColor, vec4(foregroundColor.rgb + backgroundColor, 1.0), 0.24); + } else { + fragColor = terminalColor; + } +} + diff --git a/.config/ghostty/shaders/gears-and-belts.glsl b/.config/ghostty/shaders/gears-and-belts.glsl new file mode 100644 index 0000000..9976b34 --- /dev/null +++ b/.config/ghostty/shaders/gears-and-belts.glsl @@ -0,0 +1,377 @@ +// sligltly modified version of https://www.shadertoy.com/view/DsVSDV +// The only changes are done in the mainImage function +// Ive added comments on what to modify +// works really well with most colorschemes + +#define Rot(a) mat2(cos(a),-sin(a),sin(a),cos(a)) +#define antialiasing(n) n/min(iResolution.y,iResolution.x) +#define S(d,b) smoothstep(antialiasing(3.0),b,d) +#define B(p,s) max(abs(p).x-s.x,abs(p).y-s.y) +#define deg45 .707 +#define R45(p) (( p + vec2(p.y,-p.x) ) *deg45) +#define Tri(p,s) max(R45(p).x,max(R45(p).y,B(p,s))) +#define DF(a,b) length(a) * cos( mod( atan(a.y,a.x)+6.28/(b*8.0), 6.28/((b*8.0)*0.5))+(b-1.)*6.28/(b*8.0) + vec2(0,11) ) + +float random (vec2 p) { + return fract(sin(dot(p.xy, vec2(12.9898,78.233)))* 43758.5453123); +} + +float innerGear(vec2 p, float dir){ + p*=Rot(radians(-iTime*45.+45.)*dir); + vec2 prevP = p; + + //p*=Rot(radians(iTime*45.+20.)); + p = DF(p,7.); + p-=vec2(0.24); + p*=Rot(deg45); + float d = B(p,vec2(0.01,0.06)); + p = prevP; + float d2 = abs(length(p)-0.42)-0.02; + d = min(d,d2); + d2 = abs(length(p)-0.578)-0.02; + d = min(d,d2); + d2 = abs(length(p)-0.499)-0.005; + d = min(d,d2); + + p = DF(p,7.); + p-=vec2(0.43); + p*=Rot(deg45); + d2 = B(p,vec2(0.01,0.04)); + d = min(d,d2); + + return d; +} + +vec3 pattern1(vec2 p, vec3 col, float dir){ + vec2 prevP = p; + float size = 0.499; + float thick = 0.15; + + p+=vec2(size); + float d = abs(length(p)-size)-thick; + d = max(d,innerGear(p,dir)); + col = mix(col,vec3(1.),S(d,0.0)); + + p = prevP; + p-=vec2(size); + d = abs(length(p)-size)-thick; + d = max(d,innerGear(p,dir)); + col = mix(col,vec3(1.),S(d,0.0)); + + return col; +} + +vec3 pattern2(vec2 p, vec3 col, float dir){ + + vec2 prevP = p; + float size = 0.33; + float thick = 0.15; + float thift = 0.0; + float speed = 0.3; + + p-=vec2(size,0.); + float d = B(p,vec2(size,thick)); + + p.x+=thift; + p.x-=iTime*speed*dir; + p.x=mod(p.x,0.08)-0.04; + d = max(d,B(p,vec2(0.011,thick))); + p = prevP; + d = max(-(abs(p.y)-0.1),d); + //d = min(B(p,vec2(1.,0.1)),d); + p.y=abs(p.y)-0.079; + d = min(B(p,vec2(1.,0.02)),d); + + p = prevP; + p-=vec2(0.0,size); + float d2 = B(p,vec2(thick,size)); + + p.y+=thift; + p.y+=iTime*speed*dir; + p.y=mod(p.y,0.08)-0.04; + d2 = max(d2,B(p,vec2(thick,0.011))); + + p = prevP; + d2 = max(-(abs(p.x)-0.1),d2); + d2 = min(B(p,vec2(0.005,1.)),d2); + p.x=abs(p.x)-0.079; + d2 = min(B(p,vec2(0.02,1.)),d2); + + d = min(d,d2); + + p = prevP; + p+=vec2(0.0,size); + d2 = B(p,vec2(thick,size)); + + p.y+=thift; + p.y-=iTime*speed*dir; + p.y=mod(p.y,0.08)-0.04; + d2 = max(d2,B(p,vec2(thick,0.011))); + + p = prevP; + d2 = max(-(abs(p.x)-0.1),d2); + d2 = min(B(p,vec2(0.005,1.)),d2); + p.x=abs(p.x)-0.079; + d2 = min(B(p,vec2(0.02,1.)),d2); + + d = min(d,d2); + + p = prevP; + p+=vec2(size,0.0); + d2 = B(p,vec2(size,thick)); + + p.x+=thift; + p.x+=iTime*speed*dir; + p.x=mod(p.x,0.08)-0.04; + d2 = max(d2,B(p,vec2(0.011,thick))); + d = min(d,d2); + p = prevP; + d = max(-(abs(p.y)-0.1),d); + d = min(B(p,vec2(1.,0.005)),d); + p.y=abs(p.y)-0.079; + d = min(B(p,vec2(1.,0.02)),d); + + p = prevP; + d2 = abs(B(p,vec2(size*0.3)))-0.05; + d = min(d,d2); + + col = mix(col,vec3(1.),S(d,0.0)); + + d = B(p,vec2(0.08)); + col = mix(col,vec3(0.),S(d,0.0)); + + p*=Rot(radians(60.*iTime*dir)); + d = B(p,vec2(0.03)); + col = mix(col,vec3(1.),S(d,0.0)); + + return col; +} + +vec3 drawBelt(vec2 p, vec3 col, float size){ + vec2 prevP = p; + + p*=size; + vec2 id = floor(p); + vec2 gr = fract(p)-0.5; + float dir = mod(id.x+id.y,2.)*2.-1.; + float n = random(id); + + if(n<0.5){ + if(n<0.25){ + gr.x*=-1.; + } + col = pattern1(gr,col,dir); + } else { + if(n>0.75){ + gr.x*=-1.; + } + col = pattern2(gr,col,dir); + } + + return col; +} + +vec3 gear(vec2 p, vec3 col, float dir){ + vec2 prevP = p; + + p*=Rot(radians(iTime*45.+13.)*-dir); + p = DF(p,7.); + p-=vec2(0.23); + p*=Rot(deg45); + float d = B(p,vec2(0.01,0.04)); + p = prevP; + float d2 = abs(length(p)-0.29)-0.02; + d = min(d,d2); + col = mix(col,vec3(1.),S(d,0.0)); + + p*=Rot(radians(iTime*30.-30.)*dir); + p = DF(p,6.); + p-=vec2(0.14); + p*=Rot(radians(45.)); + d = B(p,vec2(0.01,0.03)); + p = prevP; + d2 =abs( length(p)-0.1)-0.02; + p*=Rot(radians(iTime*25.+30.)*-dir); + d2 = max(-(abs(p.x)-0.05),d2); + d = min(d,d2); + col = mix(col,vec3(1.),S(d,0.0)); + + return col; +} + +vec3 item0(vec2 p, vec3 col, float dir){ + vec2 prevP = p; + p.x*=dir; + p*=Rot(radians(iTime*30.+30.)); + float d = abs(length(p)-0.2)-0.05; + col = mix(col,vec3(0.3),S(d,0.0)); + + d = abs(length(p)-0.2)-0.05; + d = max(-p.x,d); + float a = clamp(atan(p.x,p.y)*0.5,0.3,1.); + + col = mix(col,vec3(a),S(d,0.0)); + + return col; +} + + +vec3 item1(vec2 p, vec3 col, float dir){ + p.x*=dir; + vec2 prevP = p; + p*=Rot(radians(iTime*30.+30.)); + float d = abs(length(p)-0.25)-0.04; + d = abs(max((abs(p.y)-0.15),d))-0.005; + float d2 = abs(length(p)-0.25)-0.01; + d2 = max((abs(p.y)-0.12),d2); + d = min(d,d2); + + d2 = abs(length(p)-0.27)-0.01; + d2 = max(-(abs(p.y)-0.22),d2); + d = min(d,d2); + d2 = B(p,vec2(0.01,0.32)); + d2 = max(-(abs(p.y)-0.22),d2); + d = min(d,d2); + + p = prevP; + p*=Rot(radians(iTime*-20.+30.)); + p = DF(p,2.); + p-=vec2(0.105); + p*=Rot(radians(45.)); + d2 = B(p,vec2(0.03,0.01)); + d = min(d,d2); + + p = prevP; + d2 = abs(length(p)-0.09)-0.005; + d2 = max(-(abs(p.x)-0.03),d2); + d2 = max(-(abs(p.y)-0.03),d2); + d = min(d,d2); + + col = mix(col,vec3(0.6),S(d,0.0)); + + return col; +} + +vec3 item2(vec2 p, vec3 col, float dir){ + p.x*=dir; + p*=Rot(radians(iTime*50.-10.)); + vec2 prevP = p; + float d = abs(length(p)-0.15)-0.005; + float d2 = abs(length(p)-0.2)-0.01; + d2 = max((abs(p.y)-0.15),d2); + d = min(d,d2); + + p = DF(p,1.); + p-=vec2(0.13); + p*=Rot(radians(45.)); + d2 = B(p,vec2(0.008,0.1)); + d = min(d,d2); + + p = prevP; + p = DF(p,4.); + p-=vec2(0.18); + p*=Rot(radians(45.)); + d2 = B(p,vec2(0.005,0.02)); + d = min(d,d2); + + col = mix(col,vec3(0.6),S(d,0.0)); + + return col; +} + +float needle(vec2 p){ + p.y-=0.05; + p*=1.5; + vec2 prevP = p; + p.y-=0.3; + p.x*=6.; + float d = Tri(p,vec2(0.3)); + p = prevP; + p.y+=0.1; + p.x*=2.; + p.y*=-1.; + float d2 = Tri(p,vec2(0.1)); + d = min(d,d2); + return d; +} + +vec3 item3(vec2 p, vec3 col, float dir){ + + p*=Rot(radians(sin(iTime*dir)*120.)); + vec2 prevP = p; + + p.y= abs(p.y)-0.05; + float d = needle(p); + p = prevP; + float d2 = abs(length(p)-0.1)-0.003; + d2 = max(-(abs(p.x)-0.05),d2); + d = min(d,d2); + d2 = abs(length(p)-0.2)-0.005; + d2 = max(-(abs(p.x)-0.08),d2); + d = min(d,d2); + + p = DF(p,4.); + p-=vec2(0.18); + d2 = length(p)-0.01; + p = prevP; + d2 = max(-(abs(p.x)-0.03),d2); + d = min(d,d2); + + col = mix(col,vec3(0.6),S(d,0.0)); + + return col; +} + +vec3 drawGearsAndItems(vec2 p, vec3 col, float size){ + vec2 prevP = p; + p*=size; + p+=vec2(0.5); + + vec2 id = floor(p); + vec2 gr = fract(p)-0.5; + + float n = random(id); + float dir = mod(id.x+id.y,2.)*2.-1.; + if(n<0.3){ + col = gear(gr,col,dir); + } else if(n>=0.3 && n<0.5){ + col = item0(gr,col,dir); + } else if(n>=0.5 && n<0.7){ + col = item1(gr,col,dir); + } else if(n>=0.7 && n<0.8) { + col = item2(gr,col,dir); + } else if(n>=0.8){ + col = item3(gr,col,dir); + } + + return col; +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 p = (fragCoord-0.5*iResolution.xy)/iResolution.y; + // set speed of downwards motion + p.y+=iTime*0.02; + + float size = 4.; + vec3 col = vec3(0.); + + // Modify the colors to be darker by multiplying with a small factor + vec3 darkFactor = vec3(.5); // This makes everything 50% as bright + + // Get the original colors but make them darker + col = drawBelt(p, col, size) * darkFactor; + col = drawGearsAndItems(p, col, size) * darkFactor; + + // Additional option: you can add a color tint to make it less stark white + vec3 tint = vec3(0.1, 0.12, 0.15); // Slight blue-ish dark tint + col = col * tint; + + vec2 uv = fragCoord/iResolution.xy; + vec4 terminalColor = texture(iChannel0, uv); + + // Blend with reduced opacity for the shader elements + vec3 blendedColor = terminalColor.rgb + col.rgb * 0.7; // Reduced blend factor + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/glitchy.glsl b/.config/ghostty/shaders/glitchy.glsl new file mode 100644 index 0000000..603e3ec --- /dev/null +++ b/.config/ghostty/shaders/glitchy.glsl @@ -0,0 +1,117 @@ +// modified version of https://www.shadertoy.com/view/wld3WN +// amount of seconds for which the glitch loop occurs +#define DURATION 10. +// percentage of the duration for which the glitch is triggered +#define AMT .1 + +#define SS(a, b, x) (smoothstep(a, b, x) * smoothstep(b, a, x)) + +#define UI0 1597334673U +#define UI1 3812015801U +#define UI2 uvec2(UI0, UI1) +#define UI3 uvec3(UI0, UI1, 2798796415U) +#define UIF (1. / float(0xffffffffU)) + +// Hash by David_Hoskins +vec3 hash33(vec3 p) +{ + uvec3 q = uvec3(ivec3(p)) * UI3; + q = (q.x ^ q.y ^ q.z)*UI3; + return -1. + 2. * vec3(q) * UIF; +} + +// Gradient noise by iq +float gnoise(vec3 x) +{ + // grid + vec3 p = floor(x); + vec3 w = fract(x); + + // quintic interpolant + vec3 u = w * w * w * (w * (w * 6. - 15.) + 10.); + + // gradients + vec3 ga = hash33(p + vec3(0., 0., 0.)); + vec3 gb = hash33(p + vec3(1., 0., 0.)); + vec3 gc = hash33(p + vec3(0., 1., 0.)); + vec3 gd = hash33(p + vec3(1., 1., 0.)); + vec3 ge = hash33(p + vec3(0., 0., 1.)); + vec3 gf = hash33(p + vec3(1., 0., 1.)); + vec3 gg = hash33(p + vec3(0., 1., 1.)); + vec3 gh = hash33(p + vec3(1., 1., 1.)); + + // projections + float va = dot(ga, w - vec3(0., 0., 0.)); + float vb = dot(gb, w - vec3(1., 0., 0.)); + float vc = dot(gc, w - vec3(0., 1., 0.)); + float vd = dot(gd, w - vec3(1., 1., 0.)); + float ve = dot(ge, w - vec3(0., 0., 1.)); + float vf = dot(gf, w - vec3(1., 0., 1.)); + float vg = dot(gg, w - vec3(0., 1., 1.)); + float vh = dot(gh, w - vec3(1., 1., 1.)); + + // interpolation + float gNoise = va + u.x * (vb - va) + + u.y * (vc - va) + + u.z * (ve - va) + + u.x * u.y * (va - vb - vc + vd) + + u.y * u.z * (va - vc - ve + vg) + + u.z * u.x * (va - vb - ve + vf) + + u.x * u.y * u.z * (-va + vb + vc - vd + ve - vf - vg + vh); + + return 2. * gNoise; +} + +// gradient noise in range [0, 1] +float gnoise01(vec3 x) +{ + return .5 + .5 * gnoise(x); +} + +// warp uvs for the crt effect +vec2 crt(vec2 uv) +{ + float tht = atan(uv.y, uv.x); + float r = length(uv); + // curve without distorting the center + r /= (1. - .1 * r * r); + uv.x = r * cos(tht); + uv.y = r * sin(tht); + return .5 * (uv + 1.); +} + + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 uv = fragCoord / iResolution.xy; + float t = iTime; + + // smoothed interval for which the glitch gets triggered + float glitchAmount = SS(DURATION * .001, DURATION * AMT, mod(t, DURATION)); + float displayNoise = 0.; + vec3 col = vec3(0.); + vec2 eps = vec2(5. / iResolution.x, 0.); + vec2 st = vec2(0.); + + // analog distortion + float y = uv.y * iResolution.y; + float distortion = gnoise(vec3(0., y * .01, t * 500.)) * (glitchAmount * 4. + .1); + distortion *= gnoise(vec3(0., y * .02, t * 250.)) * (glitchAmount * 2. + .025); + + ++displayNoise; + distortion += smoothstep(.999, 1., sin((uv.y + t * 1.6) * 2.)) * .02; + distortion -= smoothstep(.999, 1., sin((uv.y + t) * 2.)) * .02; + st = uv + vec2(distortion, 0.); + // chromatic aberration + col.r += textureLod(iChannel0, st + eps + distortion, 0.).r; + col.g += textureLod(iChannel0, st, 0.).g; + col.b += textureLod(iChannel0, st - eps - distortion, 0.).b; + + // white noise + scanlines + displayNoise = 0.2 * clamp(displayNoise, 0., 1.); + col += (.15 + .65 * glitchAmount) * (hash33(vec3(fragCoord, mod(float(iFrame), + 1000.))).r) * displayNoise; + col -= (.25 + .75 * glitchAmount) * (sin(4. * t + uv.y * iResolution.y * 1.75)) + * displayNoise; + fragColor = vec4(col, 1.0); +} diff --git a/.config/ghostty/shaders/glow-rgbsplit-twitchy.glsl b/.config/ghostty/shaders/glow-rgbsplit-twitchy.glsl new file mode 100644 index 0000000..9411e4e --- /dev/null +++ b/.config/ghostty/shaders/glow-rgbsplit-twitchy.glsl @@ -0,0 +1,144 @@ +// First it does a "chromatic aberration" by splitting the rgb signals by a product of sin functions +// over time, then it does a glow effect in a perceptual color space +// Based on kalgynirae's Ghostty passable glow shader and NickWest's Chromatic Aberration shader demo +// Passable glow: https://github.com/kalgynirae/dotfiles/blob/main/ghostty/glow.glsl +// "Chromatic Aberration": https://www.shadertoy.com/view/Mds3zn + +// sRGB linear -> nonlinear transform from https://bottosson.github.io/posts/colorwrong/ +float f(float x) { + if (x >= 0.0031308) { + return 1.055 * pow(x, 1.0 / 2.4) - 0.055; + } else { + return 12.92 * x; + } +} + +float f_inv(float x) { + if (x >= 0.04045) { + return pow((x + 0.055) / 1.055, 2.4); + } else { + return x / 12.92; + } +} + +// Oklab <-> linear sRGB conversions from https://bottosson.github.io/posts/oklab/ +vec4 toOklab(vec4 rgb) { + vec3 c = vec3(f_inv(rgb.r), f_inv(rgb.g), f_inv(rgb.b)); + float l = 0.4122214708 * c.r + 0.5363325363 * c.g + 0.0514459929 * c.b; + float m = 0.2119034982 * c.r + 0.6806995451 * c.g + 0.1073969566 * c.b; + float s = 0.0883024619 * c.r + 0.2817188376 * c.g + 0.6299787005 * c.b; + float l_ = pow(l, 1.0 / 3.0); + float m_ = pow(m, 1.0 / 3.0); + float s_ = pow(s, 1.0 / 3.0); + return vec4( + 0.2104542553 * l_ + 0.7936177850 * m_ - 0.0040720468 * s_, + 1.9779984951 * l_ - 2.4285922050 * m_ + 0.4505937099 * s_, + 0.0259040371 * l_ + 0.7827717662 * m_ - 0.8086757660 * s_, + rgb.a + ); +} + +vec4 toRgb(vec4 oklab) { + vec3 c = oklab.rgb; + float l_ = c.r + 0.3963377774 * c.g + 0.2158037573 * c.b; + float m_ = c.r - 0.1055613458 * c.g - 0.0638541728 * c.b; + float s_ = c.r - 0.0894841775 * c.g - 1.2914855480 * c.b; + float l = l_ * l_ * l_; + float m = m_ * m_ * m_; + float s = s_ * s_ * s_; + vec3 linear_srgb = vec3( + 4.0767416621 * l - 3.3077115913 * m + 0.2309699292 * s, + -1.2684380046 * l + 2.6097574011 * m - 0.3413193965 * s, + -0.0041960863 * l - 0.7034186147 * m + 1.7076147010 * s + ); + return vec4( + clamp(f(linear_srgb.r), 0.0, 1.0), + clamp(f(linear_srgb.g), 0.0, 1.0), + clamp(f(linear_srgb.b), 0.0, 1.0), + oklab.a + ); +} + +// Bloom samples from https://gist.github.com/qwerasd205/c3da6c610c8ffe17d6d2d3cc7068f17f +const vec3[24] samples = { + vec3(0.1693761725038636, 0.9855514761735895, 1), + vec3(-1.333070830962943, 0.4721463328627773, 0.7071067811865475), + vec3(-0.8464394909806497, -1.51113870578065, 0.5773502691896258), + vec3(1.554155680728463, -1.2588090085709776, 0.5), + vec3(1.681364377589461, 1.4741145918052656, 0.4472135954999579), + vec3(-1.2795157692199817, 2.088741103228784, 0.4082482904638631), + vec3(-2.4575847530631187, -0.9799373355024756, 0.3779644730092272), + vec3(0.5874641440200847, -2.7667464429345077, 0.35355339059327373), + vec3(2.997715703369726, 0.11704939884745152, 0.3333333333333333), + vec3(0.41360842451688395, 3.1351121305574803, 0.31622776601683794), + vec3(-3.167149933769243, 0.9844599011770256, 0.30151134457776363), + vec3(-1.5736713846521535, -3.0860263079123245, 0.2886751345948129), + vec3(2.888202648340422, -2.1583061557896213, 0.2773500981126146), + vec3(2.7150778983300325, 2.5745586041105715, 0.2672612419124244), + vec3(-2.1504069972377464, 3.2211410627650165, 0.2581988897471611), + vec3(-3.6548858794907493, -1.6253643308191343, 0.25), + vec3(1.0130775986052671, -3.9967078676335834, 0.24253562503633297), + vec3(4.229723673607257, 0.33081361055181563, 0.23570226039551587), + vec3(0.40107790291173834, 4.340407413572593, 0.22941573387056174), + vec3(-4.319124570236028, 1.159811599693438, 0.22360679774997896), + vec3(-1.9209044802827355, -4.160543952132907, 0.2182178902359924), + vec3(3.8639122286635708, -2.6589814382925123, 0.21320071635561041), + vec3(3.3486228404946234, 3.4331800232609, 0.20851441405707477), + vec3(-2.8769733643574344, 3.9652268864187157, 0.20412414523193154) +}; + +float offsetFunction(float iTime) { + float amount = 1.0; + const float periods[4] = {6.0, 16.0, 19.0, 27.0}; + for (int i = 0; i < 4; i++) { + amount *= 1.0 + 0.5 * sin(iTime*periods[i]); + } + //return amount; + return amount * periods[3]; +} + +const float DIM_CUTOFF = 0.35; +const float BRIGHT_CUTOFF = 0.65; +const float ABBERATION_FACTOR = 0.05; + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord.xy / iResolution.xy; + + float amount = offsetFunction(iTime); + + vec3 col; + col.r = texture( iChannel0, vec2(uv.x-ABBERATION_FACTOR*amount / iResolution.x, uv.y) ).r; + col.g = texture( iChannel0, uv ).g; + col.b = texture( iChannel0, vec2(uv.x+ABBERATION_FACTOR*amount / iResolution.x, uv.y) ).b; + + vec4 splittedColor = vec4(col, 1.0); + vec4 source = toOklab(splittedColor); + vec4 dest = source; + + if (source.x > DIM_CUTOFF) { + dest.x *= 1.2; + // dest.x = 1.2; + } else { + vec2 step = vec2(1.414) / iResolution.xy; + vec3 glow = vec3(0.0); + for (int i = 0; i < 24; i++) { + vec3 s = samples[i]; + float weight = s.z; + vec4 c = toOklab(texture(iChannel0, uv + s.xy * step)); + if (c.x > DIM_CUTOFF) { + glow.yz += c.yz * weight * 0.3; + if (c.x <= BRIGHT_CUTOFF) { + glow.x += c.x * weight * 0.05; + } else { + glow.x += c.x * weight * 0.10; + } + } + } + // float lightness_diff = clamp(glow.x - dest.x, 0.0, 1.0); + // dest.x = lightness_diff; + // dest.yz = dest.yz * (1.0 - lightness_diff) + glow.yz * lightness_diff; + dest.xyz += glow.xyz; + } + + fragColor = toRgb(dest); +} diff --git a/.config/ghostty/shaders/gradient-background.glsl b/.config/ghostty/shaders/gradient-background.glsl new file mode 100644 index 0000000..beae0cf --- /dev/null +++ b/.config/ghostty/shaders/gradient-background.glsl @@ -0,0 +1,25 @@ +// credits: https://github.com/unkn0wncode +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + // Normalize pixel coordinates (range from 0 to 1) + vec2 uv = fragCoord.xy / iResolution.xy; + + // Create a gradient from bottom right to top left as a function (x + y)/2 + float gradientFactor = (uv.x + uv.y) / 2.0; + + // Define gradient colors (adjust to your preference) + vec3 gradientStartColor = vec3(0.1, 0.1, 0.5); // Start color (e.g., dark blue) + vec3 gradientEndColor = vec3(0.5, 0.1, 0.1); // End color (e.g., dark red) + + vec3 gradientColor = mix(gradientStartColor, gradientEndColor, gradientFactor); + + // Sample the terminal screen texture including alpha channel + vec4 terminalColor = texture(iChannel0, uv); + + // Make a mask that is 1.0 where the terminal content is not black + float mask = 1 - step(0.5, dot(terminalColor.rgb, vec3(1.0))); + vec3 blendedColor = mix(terminalColor.rgb, gradientColor, mask); + + // Apply terminal's alpha to control overall opacity + fragColor = vec4(blendedColor, terminalColor.a); +} \ No newline at end of file diff --git a/.config/ghostty/shaders/in-game-crt-cursor.glsl b/.config/ghostty/shaders/in-game-crt-cursor.glsl new file mode 100644 index 0000000..8570cf1 --- /dev/null +++ b/.config/ghostty/shaders/in-game-crt-cursor.glsl @@ -0,0 +1,157 @@ +// In-game CRT shader +// Author: sarphiv +// License: CC BY-NC-SA 4.0 +// Description: +// Cursor shader for Ghostty designed to be applied before the accompanying in-game CRT shader. +// Highlights the cursor whenever it changes (line/block) or moves, and draws a glowing trail for large movements. +// The glow is colored based on cursor colors with an override for white-grey colors. + + +// Settings: +// Minimum distance in UV coordinates before drawing trail +// [0, sqrt(2)] +#define TRAIL_MIN_DISTANCE 0.1 +// Use override colors when color channel brightness standard deviation is below threshold +// [0, sqrt(2)/3] +#define GLOW_COLOR_OVERRIDE_THRESHOLD 0.1 +// Override color for current cursor +// [0, 1]^3 +#define GLOW_COLOR_OVERRIDE_CURRENT 0.2, 0.4, 1.0 +// Override color for previous cursor +// [0, 1]^3 +#define GLOW_COLOR_OVERRIDE_PREVIOUS 0.4, 0.1, 1.0 +// Brightness offset for glow effect +// [0, 1] +#define GLOW_COLOR_OFFSET_BRIGHTNESS 0.5 +// Time slowdown factor for animations +// x \in R : x > 0 +#define TIME_DURATION_FACTOR 1.0 + + + +// Constants: +#define EPS 1e-9 + + + +// Functions: +float min_(float a, float b, float c) { return min(a, min(b, c)); } +float max_(float a, float b, float c) { return max(a, max(b, c)); } + +float sdRectangle(vec2 p, vec2 topLeft, vec2 size) { + vec2 center = topLeft + vec2(size.x, -size.y) * 0.5; + vec2 d = abs(p - center) - size * 0.5; + return length(max(d, 0.0)) + min(max(d.x, d.y), 0.0); +} + +float sdSeg(vec2 p, vec2 a) +{ + vec2 c = a * clamp(dot(p, a) / (dot(a, a) + EPS), 0., 1.) - p; + return sqrt(dot(c, c)); +} + +float sdTriangle(vec2 p, vec2 a, vec2 b, vec2 c) +{ + a -= p; b -= p; c -= p; + + vec3 t = cross(vec3(a.x, b.x, c.x), vec3(a.y, b.y, c.y)); + vec2 m = vec2(min_(t.x, t.y, t.z), max_(t.x, t.y, t.z)); + float s = -1. + 2. * step(m.x, 0.) * step(0., m.y); + + return s * min_( + sdSeg(a, a - b), + sdSeg(b, b - c), + sdSeg(c, c - a) + ); +} + +float sdTrail(vec2 p, vec2 currPos, vec2 currSize, vec2 prevPos, vec2 prevSize, float t) { + // Initialize points + vec2 currWidth = vec2(currSize.x, 0.0), currHeight = vec2(0.0, -currSize.y); + vec2 currTopLeft = currPos; + vec2 currTopRight = currTopLeft + currWidth; + vec2 currBottomLeft = currTopLeft + currHeight; + vec2 currBottomRight = currBottomLeft + currWidth; + vec2 currCenter = (currTopLeft + currBottomRight) * 0.5; + + vec2 prevWidth = vec2(prevSize.x, 0.0), prevHeight = vec2(0.0, -prevSize.y); + vec2 prevTopLeft = prevPos; + vec2 prevTopRight = prevTopLeft + prevWidth; + vec2 prevBottomLeft = prevTopLeft + prevHeight; + vec2 prevBottomRight = prevBottomLeft + prevWidth; + vec2 prevCenter = (prevTopLeft + prevBottomRight) * 0.5; + + // Check whether to only draw cursor + bool nearbyPrev = distance(currCenter, prevCenter) < TRAIL_MIN_DISTANCE; + bool insidePrev = ( + currCenter.x >= prevTopLeft.x && currCenter.x <= prevTopRight.x && + currCenter.y <= prevTopLeft.y && currCenter.y >= prevBottomLeft.y + ); + + float rectDist = max(sdRectangle(p, currTopLeft, currSize), 0.0); + + if (nearbyPrev || insidePrev) + return rectDist; + + // Draw trail and cursor + vec2[4] corners = { currTopLeft, currTopRight, currBottomRight, currBottomLeft }; + vec2 triB = corners[0], triC = corners[0], dir = normalize(currCenter - prevCenter); + float minRel = 1/EPS, maxRel = -minRel; + + for (int i = 0; i < 4; ++i) { + vec2 delta = corners[i] - prevCenter; + float rel = atan(dir.x * delta.y - dir.y * delta.x, dot(dir, delta)); + + if (rel < minRel) + minRel = rel, triB = corners[i]; + if (rel > maxRel) + maxRel = rel, triC = corners[i]; + } + + float triDist = max(sdTriangle(p, prevCenter, triB, triC), 0.0); + + + return min(rectDist, mix(triDist, rectDist, t)); +} + +vec4 colorOverride(vec4 baseColor, vec4 overrideColor) { + if (sqrt(pow(distance(baseColor.rgb, vec3(dot(baseColor.rgb, vec3(1.0)) / 3.0)), 2) / 3.0) < GLOW_COLOR_OVERRIDE_THRESHOLD) + return overrideColor; + else + return baseColor; +} + + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord.xy / iResolution.xy; + fragColor = texture(iChannel0, uv); + + vec2 currPos = iCurrentCursor.xy / iResolution.xy, currSize = iCurrentCursor.zw / iResolution.xy; + vec2 prevPos = iPreviousCursor.xy / iResolution.xy, prevSize = iPreviousCursor.zw / iResolution.xy; + vec2 currCenter = currPos + currSize * vec2(0.5, -0.5); + vec2 prevCenter = prevPos + prevSize * vec2(0.5, -0.5); + + float dCenter = distance(currCenter, prevCenter); + float dSeg = dot(uv - prevCenter, currCenter - prevCenter) * pow(dCenter + EPS, -2); + bool nearbyPrev = dCenter < TRAIL_MIN_DISTANCE; + + float tShape = 1.0 - pow(1.0 - clamp((iTime - iTimeCursorChange) / TIME_DURATION_FACTOR, 0.0, 1.0), 3); + float tVisible = exp(-(iTime - iTimeCursorChange) / TIME_DURATION_FACTOR * 50.0); + + float dTrail = sdTrail(uv, currPos, currSize, prevPos, prevSize, tShape); + float dTip = nearbyPrev ? 0.0 : clamp(1.0 - abs(dSeg - 1.0), 0.0, 1.0); + + vec4 currColor = colorOverride(iCurrentCursorColor, vec4(GLOW_COLOR_OVERRIDE_CURRENT, 1.0)); + vec4 prevColor = colorOverride(iPreviousCursorColor, vec4(GLOW_COLOR_OVERRIDE_PREVIOUS, 1.0)); + vec4 glowColor = mix(fragColor, mix(prevColor, currColor, dTip) + GLOW_COLOR_OFFSET_BRIGHTNESS, pow(dTip, 3)); + glowColor = mix(glowColor, fragColor, pow(smoothstep(0.0, 0.3, dTrail), 0.1)); + + vec4 trailColor = mix(vec4(1.0), glowColor, pow(smoothstep(0.0, 0.01, dTrail), 0.2)); + vec4 trail = mix(trailColor, fragColor, pow(smoothstep(0.0, nearbyPrev ? 0.01 : 0.1, dTrail), 0.2)); + if (!nearbyPrev) { + trail = mix(trailColor, trail, pow(smoothstep(0.0, 6.0, dTip), 0.05)); + trail = mix(trailColor, trail, pow(smoothstep(0.0, 8.0, dTip), 0.005)); + } + + fragColor = mix(fragColor, trail, tVisible); +} diff --git a/.config/ghostty/shaders/in-game-crt.glsl b/.config/ghostty/shaders/in-game-crt.glsl new file mode 100644 index 0000000..4c88566 --- /dev/null +++ b/.config/ghostty/shaders/in-game-crt.glsl @@ -0,0 +1,308 @@ +// In-game CRT shader +// Author: sarphiv +// License: CC BY-NC-SA 4.0 +// Description: +// Shader for Ghostty with a focus on being usable while looking like a stylized CRT terminal from a modern video game. + +// Based on: +// 1. https://gist.github.com/mitchellh/39d62186910dcc27cad097fed16eb882 (forces the choice of license) +// 2. https://gist.github.com/qwerasd205/c3da6c610c8ffe17d6d2d3cc7068f17f +// 3. https://gist.github.com/seanwcom/0fbe6b270aaa5f28823e053d3dbb14ca +// 4. https://www.shadertoy.com/view/ltB3zD + + + +// Settings: +// How straight the terminal is in each axis +// (x, y) \in R^2 : x, y > 0 +#define CURVE 13.0, 11.0 + +// How far apart the different colors are from each other +// x \in R +#define COLOR_FRINGING_SPREAD 0.1 + +// How much the ghost images are spread out +// x \in R : x >= 0 +#define GHOSTING_SPREAD 0.75 +// How visible ghost images are +// x \in R : x >= 0 +#define GHOSTING_STRENGTH 0.1 + +// How much of the non-linearly darkened colors are mixed in +// [0, 1] +#define DARKEN_MIX 0.4 + +// How far in the vignette spreads +// x \in R : x >= 0 +#define VIGNETTE_SPREAD 0.4 +// How bright the vignette is +// x \in R : x >= 0 +#define VIGNETTE_BRIGHTNESS 20.0 + +// Tint all colors +// [0, 1]^3 +#define TINT 0.93, 1.00, 0.96 + +// How visible the scan line effect is +// NOTE: Technically these are not scan lines, but rather the lack of them +// [0, 1] +#define SCAN_LINES_STRENGTH 0.20 +// How bright the spaces between the lines are +// [0, 1] +#define SCAN_LINES_VARIANCE 0.35 +// Pixels per scan line effect +// x \in R : x > 0 +#define SCAN_LINES_PERIOD 4.0 + +// How visible the aperture grille is +// x \in R : x >= 0 +#define APERTURE_GRILLE_STRENGTH 0.3 +// Pixels per aperture grille +// x \in R : x > 0 +#define APERTURE_GRILLE_PERIOD 2.0 + +// How much the screen flickers +// x \in R : x >= 0 +#define FLICKER_STRENGTH 0.04 +// How fast the screen flickers +// x \in R : x > 0 +#define FLICKER_FREQUENCY 15.0 + +// How much noise is added to filled areas +// [0, 1] +#define NOISE_CONTENT_STRENGTH 0.25 +// How much noise is added everywhere +// [0, 1] +#define NOISE_UNIFORM_STRENGTH 0.25 + +// How big the bloom is +// x \in R : x >= 0 +#define BLOOM_SPREAD 8.0 +// How visible the bloom is +// [0, 1] +#define BLOOM_STRENGTH 0.004 + +// Backgrond opacity +// [0, 1] +#define BACKGROUND_OPACITY 0.8 + + +// Disabled values for when the settings are not defined +#ifndef COLOR_FRINGING_SPREAD +#define COLOR_FRINGING_SPREAD 0.0 +#endif + +#if !defined(GHOSTING_SPREAD) || !defined(GHOSTING_STRENGTH) +#undef GHOSTING_SPREAD +#undef GHOSTING_STRENGTH +#define GHOSTING_SPREAD 0.0 +#define GHOSTING_STRENGTH 0.0 +#endif + +#ifndef DARKEN_MIX +#define DARKEN_MIX 0.0 +#endif + +#if !defined(VIGNETTE_SPREAD) || !defined(VIGNETTE_BRIGHTNESS) +#undef VIGNETTE_SPREAD +#undef VIGNETTE_BRIGHTNESS +#define VIGNETTE_SPREAD 0.0 +#define VIGNETTE_BRIGHTNESS 1.0 +#endif + +#ifndef TINT +#define TINT 1.00, 1.00, 1.00 +#endif + +#if !defined(SCAN_LINES_STRENGTH) || !defined(SCAN_LINES_VARIANCE) || !defined(SCAN_LINES_PERIOD) +#undef SCAN_LINES_STRENGTH +#undef SCAN_LINES_VARIANCE +#undef SCAN_LINES_PERIOD +#define SCAN_LINES_STRENGTH 0.0 +#define SCAN_LINES_VARIANCE 1.0 +#define SCAN_LINES_PERIOD 1.0 +#endif + +#if !defined(APERTURE_GRILLE_STRENGTH) || !defined(APERTURE_GRILLE_PERIOD) +#undef APERTURE_GRILLE_STRENGTH +#undef APERTURE_GRILLE_PERIOD +#define APERTURE_GRILLE_STRENGTH 0.0 +#define APERTURE_GRILLE_PERIOD 1.0 +#endif + +#if !defined(FLICKER_STRENGTH) || !defined(FLICKER_FREQUENCY) +#undef FLICKER_STRENGTH +#undef FLICKER_FREQUENCY +#define FLICKER_STRENGTH 0.0 +#define FLICKER_FREQUENCY 1.0 +#endif + +#if !defined(NOISE_CONTENT_STRENGTH) || !defined(NOISE_UNIFORM_STRENGTH) +#undef NOISE_CONTENT_STRENGTH +#undef NOISE_UNIFORM_STRENGTH +#define NOISE_CONTENT_STRENGTH 0.0 +#define NOISE_UNIFORM_STRENGTH 0.0 +#endif + +#if !defined(BLOOM_SPREAD) || !defined(BLOOM_STRENGTH) +#undef BLOOM_SPREAD +#undef BLOOM_STRENGTH +#define BLOOM_SPREAD 0.0 +#define BLOOM_STRENGTH 0.0 +#endif + +#ifndef BACKGROUND_OPACITY +#define BACKGROUND_OPACITY 1.0 +#endif + + + +// Constants: +#define PI 3.1415926535897932384626433832795 +#define PHI 1.61803398874989484820459 + +#ifdef BLOOM_SPREAD +// Golden spiral samples used for bloom. +// [x, y, weight] weight is inverse of distance. +const vec3[24] bloomSamples = { + vec3( 0.1693761725038636, 0.9855514761735895, 1), + vec3(-1.333070830962943, 0.4721463328627773, 0.7071067811865475), + vec3(-0.8464394909806497, -1.51113870578065, 0.5773502691896258), + vec3( 1.554155680728463, -1.2588090085709776, 0.5), + vec3( 1.681364377589461, 1.4741145918052656, 0.4472135954999579), + vec3(-1.2795157692199817, 2.088741103228784, 0.4082482904638631), + vec3(-2.4575847530631187, -0.9799373355024756, 0.3779644730092272), + vec3( 0.5874641440200847, -2.7667464429345077, 0.35355339059327373), + vec3( 2.997715703369726, 0.11704939884745152, 0.3333333333333333), + vec3( 0.41360842451688395, 3.1351121305574803, 0.31622776601683794), + vec3(-3.167149933769243, 0.9844599011770256, 0.30151134457776363), + vec3(-1.5736713846521535, -3.0860263079123245, 0.2886751345948129), + vec3( 2.888202648340422, -2.1583061557896213, 0.2773500981126146), + vec3( 2.7150778983300325, 2.5745586041105715, 0.2672612419124244), + vec3(-2.1504069972377464, 3.2211410627650165, 0.2581988897471611), + vec3(-3.6548858794907493, -1.6253643308191343, 0.25), + vec3( 1.0130775986052671, -3.9967078676335834, 0.24253562503633297), + vec3( 4.229723673607257, 0.33081361055181563, 0.23570226039551587), + vec3( 0.40107790291173834, 4.340407413572593, 0.22941573387056174), + vec3(-4.319124570236028, 1.159811599693438, 0.22360679774997896), + vec3(-1.9209044802827355, -4.160543952132907, 0.2182178902359924), + vec3( 3.8639122286635708, -2.6589814382925123, 0.21320071635561041), + vec3( 3.3486228404946234, 3.4331800232609, 0.20851441405707477), + vec3(-2.8769733643574344, 3.9652268864187157, 0.20412414523193154) +}; +#endif + + + +// Functions: +float gold_v2_noise(in vec2 xy, in float seed) +{ + return fract(sin(distance(xy*PHI, xy)*seed)*xy.x*xy.y); +} + + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + // Get texture coordinates + vec2 uv = fragCoord.xy / iResolution.xy; + +#ifdef CURVE + // Curve texture coordinates to mimic non-flat CRT monior + uv = (uv - 0.5) * 2.0; + uv.xy *= 1.0 + pow((abs(vec2(uv.y, uv.x)) / vec2(CURVE)), vec2(2.0)); + uv = (uv / 2.0) + 0.5; +#endif + + + // Retrieve colors from appropriate locations + fragColor.r = texture(iChannel0, vec2(uv.x + 0.0003 * COLOR_FRINGING_SPREAD, uv.y + 0.0003 * COLOR_FRINGING_SPREAD)).x; + fragColor.g = texture(iChannel0, vec2(uv.x + 0.0000 * COLOR_FRINGING_SPREAD, uv.y - 0.0006 * COLOR_FRINGING_SPREAD)).y; + fragColor.b = texture(iChannel0, vec2(uv.x - 0.0006 * COLOR_FRINGING_SPREAD, uv.y + 0.0000 * COLOR_FRINGING_SPREAD)).z; + fragColor.a = texture(iChannel0, uv).a; + + + // Add faint ghost images + fragColor.r += 0.04 * GHOSTING_STRENGTH * texture(iChannel0, GHOSTING_SPREAD * vec2(+0.025, -0.027) + uv.xy).x; + fragColor.g += 0.02 * GHOSTING_STRENGTH * texture(iChannel0, GHOSTING_SPREAD * vec2(-0.022, -0.020) + uv.xy).y; + fragColor.b += 0.04 * GHOSTING_STRENGTH * texture(iChannel0, GHOSTING_SPREAD * vec2(-0.020, -0.018) + uv.xy).z; + + + // Quadratically darken everything + fragColor.rgb = mix(fragColor.rgb, fragColor.rgb*fragColor.rgb, DARKEN_MIX); + + + // Vignette effect + // NOTE: Clamp necessary because of curve effect + fragColor.rgb *= VIGNETTE_BRIGHTNESS * pow(clamp(uv.x * uv.y * (1.0-uv.x) * (1.0-uv.y), 0.0, 1.0), VIGNETTE_SPREAD); + + + // Tint all colors + fragColor.rgb *= vec3(TINT); + + + // NOTE: At this point, RGB values may be above 1 + + + // Add scan lines effect + fragColor.rgb *= mix( + 1.0, + SCAN_LINES_VARIANCE/2.0*(1.0 + sin(2*PI* uv.y * iResolution.y/SCAN_LINES_PERIOD)), + SCAN_LINES_STRENGTH + ); + + + // Add aperture grille + int apertureGrilleStep = int(8 * mod(fragCoord.x, APERTURE_GRILLE_PERIOD) / APERTURE_GRILLE_PERIOD); + float apertureGrilleMask; + + if (apertureGrilleStep < 3) + apertureGrilleMask = 0.0; + else if (apertureGrilleStep < 4) + apertureGrilleMask = mod(8*fragCoord.x, APERTURE_GRILLE_PERIOD) / APERTURE_GRILLE_PERIOD; + else if (apertureGrilleStep < 7) + apertureGrilleMask = 1.0; + else if (apertureGrilleStep < 8) + apertureGrilleMask = mod(-8*fragCoord.x, APERTURE_GRILLE_PERIOD) / APERTURE_GRILLE_PERIOD; + + fragColor.rgb *= 1.0 - APERTURE_GRILLE_STRENGTH*apertureGrilleMask; + + + // Add flicker + fragColor *= 1.0 - FLICKER_STRENGTH/2.0*(1.0 + sin(2*PI*FLICKER_FREQUENCY*iTime)); + + + // Add noise + // NOTE: Hard-coded noise distributions + float noise = smoothstep(0.4, 0.6, gold_v2_noise(fragCoord.xy, fract(iTime*0.001))); + fragColor.rgb *= clamp(noise + 1.0 - NOISE_CONTENT_STRENGTH, 0.0, 1.0); + fragColor.rgb = clamp(fragColor.rgb + noise * NOISE_UNIFORM_STRENGTH / 100, 0.0, 1.0); + + + // NOTE: At this point, RGB values are again within [0, 1] + + + // Remove output outside of screen bounds + // if (uv.x < 0.0 || uv.x > 1.0) + // fragColor.rgb *= 0.0; + // if (uv.y < 0.0 || uv.y > 1.0) + // fragColor.rgb *= 0.0; + + +#ifdef BLOOM_SPREAD + // Add bloom + vec2 step = BLOOM_SPREAD * vec2(1.414) / iResolution.xy; + + for (int i = 0; i < 24; i++) { + vec3 bloomSample = bloomSamples[i]; + vec4 neighbor = texture(iChannel0, uv + bloomSample.xy * step); + float luminance = 0.299 * neighbor.r + 0.587 * neighbor.g + 0.114 * neighbor.b; + + fragColor += luminance * bloomSample.z * neighbor * BLOOM_STRENGTH; + } + + fragColor = clamp(fragColor, 0.0, 1.0); +#endif + + + // Set background opacity + fragColor = vec4(fragColor.rgb*fragColor.a, BACKGROUND_OPACITY); +} diff --git a/.config/ghostty/shaders/inside-the-matrix.glsl b/.config/ghostty/shaders/inside-the-matrix.glsl new file mode 100644 index 0000000..4ff4232 --- /dev/null +++ b/.config/ghostty/shaders/inside-the-matrix.glsl @@ -0,0 +1,409 @@ +/* + Feel free to do anything you want with this code. + This shader uses "runes" code by FabriceNeyret2 (https://www.shadertoy.com/view/4ltyDM) + which is based on "runes" by otaviogood (https://shadertoy.com/view/MsXSRn). + These random runes look good as matrix symbols and have acceptable performance. + + @pkazmier modified this shader to work in Ghostty. +*/ + +const int ITERATIONS = 40; //use less value if you need more performance +const float SPEED = .5; + +const float STRIP_CHARS_MIN = 7.; +const float STRIP_CHARS_MAX = 40.; +const float STRIP_CHAR_HEIGHT = 0.15; +const float STRIP_CHAR_WIDTH = 0.10; +const float ZCELL_SIZE = 1. * (STRIP_CHAR_HEIGHT * STRIP_CHARS_MAX); //the multiplier can't be less than 1. +const float XYCELL_SIZE = 12. * STRIP_CHAR_WIDTH; //the multiplier can't be less than 1. + +const int BLOCK_SIZE = 10; //in cells +const int BLOCK_GAP = 2; //in cells + +const float WALK_SPEED = 0.5 * XYCELL_SIZE; +const float BLOCKS_BEFORE_TURN = 3.; + +const float PI = 3.14159265359; + +// ---- random ---- + +float hash(float v) { + return fract(sin(v)*43758.5453123); +} + +float hash(vec2 v) { + return hash(dot(v, vec2(5.3983, 5.4427))); +} + +vec2 hash2(vec2 v) +{ + v = vec2(v * mat2(127.1, 311.7, 269.5, 183.3)); + return fract(sin(v)*43758.5453123); +} + +vec4 hash4(vec2 v) +{ + vec4 p = vec4(v * mat4x2( 127.1, 311.7, + 269.5, 183.3, + 113.5, 271.9, + 246.1, 124.6 )); + return fract(sin(p)*43758.5453123); +} + +vec4 hash4(vec3 v) +{ + vec4 p = vec4(v * mat4x3( 127.1, 311.7, 74.7, + 269.5, 183.3, 246.1, + 113.5, 271.9, 124.6, + 271.9, 269.5, 311.7 ) ); + return fract(sin(p)*43758.5453123); +} + +// ---- symbols ---- +// Slightly modified version of "runes" by FabriceNeyret2 - https://www.shadertoy.com/view/4ltyDM +// Which is based on "runes" by otaviogood - https://shadertoy.com/view/MsXSRn + +float rune_line(vec2 p, vec2 a, vec2 b) { // from https://www.shadertoy.com/view/4dcfW8 + p -= a, b -= a; + float h = clamp(dot(p, b) / dot(b, b), 0., 1.); // proj coord on line + return length(p - b * h); // dist to segment +} + +float rune(vec2 U, vec2 seed, float highlight) +{ + float d = 1e5; + for (int i = 0; i < 4; i++) // number of strokes + { + vec4 pos = hash4(seed); + seed += 1.; + + // each rune touches the edge of its box on all 4 sides + if (i == 0) pos.y = .0; + if (i == 1) pos.x = .999; + if (i == 2) pos.x = .0; + if (i == 3) pos.y = .999; + // snap the random line endpoints to a grid 2x3 + vec4 snaps = vec4(2, 3, 2, 3); + pos = ( floor(pos * snaps) + .5) / snaps; + + if (pos.xy != pos.zw) //filter out single points (when start and end are the same) + d = min(d, rune_line(U, pos.xy, pos.zw + .001) ); // closest line + } + return smoothstep(0.1, 0., d) + highlight*smoothstep(0.4, 0., d); +} + +float random_char(vec2 outer, vec2 inner, float highlight) { + vec2 seed = vec2(dot(outer, vec2(269.5, 183.3)), dot(outer, vec2(113.5, 271.9))); + return rune(inner, seed, highlight); +} + +// ---- digital rain ---- + +// xy - horizontal, z - vertical +vec3 rain(vec3 ro3, vec3 rd3, float time) { + vec4 result = vec4(0.); + + // normalized 2d projection + vec2 ro2 = vec2(ro3); + vec2 rd2 = normalize(vec2(rd3)); + + // we use formulas `ro3 + rd3 * t3` and `ro2 + rd2 * t2`, `t3_to_t2` is a multiplier to convert t3 to t2 + bool prefer_dx = abs(rd2.x) > abs(rd2.y); + float t3_to_t2 = prefer_dx ? rd3.x / rd2.x : rd3.y / rd2.y; + + // at first, horizontal space (xy) is divided into cells (which are columns in 3D) + // then each xy-cell is divided into vertical cells (along z) - each of these cells contains one raindrop + + ivec3 cell_side = ivec3(step(0., rd3)); //for positive rd.x use cell side with higher x (1) as the next side, for negative - with lower x (0), the same for y and z + ivec3 cell_shift = ivec3(sign(rd3)); //shift to move to the next cell + + // move through xy-cells in the ray direction + float t2 = 0.; // the ray formula is: ro2 + rd2 * t2, where t2 is positive as the ray has a direction. + ivec2 next_cell = ivec2(floor(ro2/XYCELL_SIZE)); //first cell index where ray origin is located + for (int i=0; i= t2s && tmin <= t2) { + float u = s.x * rd2.y - s.y * rd2.x; //horizontal coord in the matrix strip + if (abs(u) < target_rad) { + u = (u/target_rad + 1.) / 2.; + float z = ro3.z + rd3.z * tmin/t3_to_t2; + float v = (z - target_z) / target_length; //vertical coord in the matrix strip + if (v >= 0.0 && v < 1.0) { + float c = floor(v * chars_count); //symbol index relative to the start of the strip, with addition of char_z_shift it becomes an index relative to the whole cell + float q = fract(v * chars_count); + vec2 char_hash = hash2(vec2(c+char_z_shift, cell_hash2.x)); + if (char_hash.x >= 0.1 || c == 0.) { //10% of missed symbols + float time_factor = floor(c == 0. ? time : //first symbol is changed fast + time*(1.0*cell_hash2.z + //strips are changed sometime with different speed + cell_hash2.w*cell_hash2.w*4.*pow(char_hash.y, 4.))); //some symbols in some strips are changed relatively often + float a = random_char(vec2(char_hash.x, time_factor), vec2(u,q), max(1., 3. - c/2.)*0.2); //alpha + a *= clamp((chars_count - 0.5 - c) / 2., 0., 1.); //tail fade + if (a > 0.) { + float attenuation = 1. + pow(0.06*tmin/t3_to_t2, 2.); + vec3 col = (c == 0. ? vec3(0.67, 1.0, 0.82) : vec3(0.25, 0.80, 0.40)) / attenuation; + float a1 = result.a; + result.a = a1 + (1. - a1) * a; + result.xyz = (result.xyz * a1 + col * (1. - a1) * a) / result.a; + if (result.a > 0.98) + return result.xyz; + } + } + } + } + } + // not found in this cell - go to next vertical cell + zcell += cell_shift.z; + } + // go to next horizontal cell + } + + return result.xyz * result.a; +} + +// ---- main, camera ---- + +vec2 rotate(vec2 v, float a) { + float s = sin(a); + float c = cos(a); + mat2 m = mat2(c, -s, s, c); + return m * v; +} + +vec3 rotateX(vec3 v, float a) { + float s = sin(a); + float c = cos(a); + return mat3(1.,0.,0.,0.,c,-s,0.,s,c) * v; +} + +vec3 rotateY(vec3 v, float a) { + float s = sin(a); + float c = cos(a); + return mat3(c,0.,-s,0.,1.,0.,s,0.,c) * v; +} + +vec3 rotateZ(vec3 v, float a) { + float s = sin(a); + float c = cos(a); + return mat3(c,-s,0.,s,c,0.,0.,0.,1.) * v; +} + +float smoothstep1(float x) { + return smoothstep(0., 1., x); +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + if (STRIP_CHAR_WIDTH > XYCELL_SIZE || STRIP_CHAR_HEIGHT * STRIP_CHARS_MAX > ZCELL_SIZE) { + // error + fragColor = vec4(1., 0., 0., 1.); + return; + } + + vec2 uv = fragCoord.xy / iResolution.xy; + + float time = mod(iTime, 300) * SPEED; //reset time every 5 minutes, as large values lead to the same (and eventually no) rune(s) + + const float turn_rad = 0.25 / BLOCKS_BEFORE_TURN; //0 .. 0.5 + const float turn_abs_time = (PI/2.*turn_rad) * 1.5; //multiplier different than 1 means a slow down on turns + const float turn_time = turn_abs_time / (1. - 2.*turn_rad + turn_abs_time); //0..1, but should be <= 0.5 + + float level1_size = float(BLOCK_SIZE) * BLOCKS_BEFORE_TURN * XYCELL_SIZE; + float level2_size = 4. * level1_size; + float gap_size = float(BLOCK_GAP) * XYCELL_SIZE; + + vec3 ro = vec3(gap_size/2., gap_size/2., 0.); + vec3 rd = vec3(uv.x, 2.0, uv.y); + + float tq = fract(time / (level2_size*4.) * WALK_SPEED); //the whole cycle time counter + float t8 = fract(tq*4.); //time counter while walking on one of the four big sides + float t1 = fract(t8*8.); //time counter while walking on one of the eight sides of the big side + + vec2 prev; + vec2 dir; + if (tq < 0.25) { + prev = vec2(0.,0.); + dir = vec2(0.,1.); + } else if (tq < 0.5) { + prev = vec2(0.,1.); + dir = vec2(1.,0.); + } else if (tq < 0.75) { + prev = vec2(1.,1.); + dir = vec2(0.,-1.); + } else { + prev = vec2(1.,0.); + dir = vec2(-1.,0.); + } + float angle = floor(tq * 4.); //0..4 wich means 0..2*PI + + prev *= 4.; + + const float first_turn_look_angle = 0.4; + const float second_turn_drift_angle = 0.5; + const float fifth_turn_drift_angle = 0.25; + + vec2 turn; + float turn_sign = 0.; + vec2 dirL = rotate(dir, -PI/2.); + vec2 dirR = -dirL; + float up_down = 0.; + float rotate_on_turns = 1.; + float roll_on_turns = 1.; + float add_angel = 0.; + if (t8 < 0.125) { + turn = dirL; + //dir = dir; + turn_sign = -1.; + angle -= first_turn_look_angle * (max(0., t1 - (1. - turn_time*2.)) / turn_time - max(0., t1 - (1. - turn_time)) / turn_time * 2.5); + roll_on_turns = 0.; + } else if (t8 < 0.250) { + prev += dir; + turn = dir; + dir = dirL; + angle -= 1.; + turn_sign = 1.; + add_angel += first_turn_look_angle*0.5 + (-first_turn_look_angle*0.5+1.0+second_turn_drift_angle)*t1; + rotate_on_turns = 0.; + roll_on_turns = 0.; + } else if (t8 < 0.375) { + prev += dir + dirL; + turn = dirR; + //dir = dir; + turn_sign = 1.; + add_angel += second_turn_drift_angle*sqrt(1.-t1); + //roll_on_turns = 0.; + } else if (t8 < 0.5) { + prev += dir + dir + dirL; + turn = dirR; + dir = dirR; + angle += 1.; + turn_sign = 0.; + up_down = sin(t1*PI) * 0.37; + } else if (t8 < 0.625) { + prev += dir + dir; + turn = dir; + dir = dirR; + angle += 1.; + turn_sign = -1.; + up_down = sin(-min(1., t1/(1.-turn_time))*PI) * 0.37; + } else if (t8 < 0.750) { + prev += dir + dir + dirR; + turn = dirL; + //dir = dir; + turn_sign = -1.; + add_angel -= (fifth_turn_drift_angle + 1.) * smoothstep1(t1); + rotate_on_turns = 0.; + roll_on_turns = 0.; + } else if (t8 < 0.875) { + prev += dir + dir + dir + dirR; + turn = dir; + dir = dirL; + angle -= 1.; + turn_sign = 1.; + add_angel -= fifth_turn_drift_angle - smoothstep1(t1) * (fifth_turn_drift_angle * 2. + 1.); + rotate_on_turns = 0.; + roll_on_turns = 0.; + } else { + prev += dir + dir + dir; + turn = dirR; + //dir = dir; + turn_sign = 1.; + angle += fifth_turn_drift_angle * (1.5*min(1., (1.-t1)/turn_time) - 0.5*smoothstep1(1. - min(1.,t1/(1.-turn_time)))); + } + + if (iMouse.x > 10. || iMouse.y > 10.) { + vec2 mouse = iMouse.xy / iResolution.xy * 2. - 1.; + up_down = -0.7 * mouse.y; + angle += mouse.x; + rotate_on_turns = 1.; + roll_on_turns = 0.; + } else { + angle += add_angel; + } + + rd = rotateX(rd, up_down); + + vec2 p; + if (turn_sign == 0.) { + // move forward + p = prev + dir * (turn_rad + 1. * t1); + } + else if (t1 > (1. - turn_time)) { + // turn + float tr = (t1 - (1. - turn_time)) / turn_time; + vec2 c = prev + dir * (1. - turn_rad) + turn * turn_rad; + p = c + turn_rad * rotate(dir, (tr - 1.) * turn_sign * PI/2.); + angle += tr * turn_sign * rotate_on_turns; + rd = rotateY(rd, sin(tr*turn_sign*PI) * 0.2 * roll_on_turns); //roll + } else { + // move forward + t1 /= (1. - turn_time); + p = prev + dir * (turn_rad + (1. - turn_rad*2.) * t1); + } + + rd = rotateZ(rd, angle * PI/2.); + + ro.xy += level1_size * p; + + rd = normalize(rd); + ro += rd * 0.2; + + // vec3 col = rain(ro, rd, time); + vec3 col = rain(ro, rd, time) * 0.25; + + // Sample the terminal screen texture including alpha channel + vec4 terminalColor = texture(iChannel0, uv); + + // Combine the matrix effect with the terminal color + // vec3 blendedColor = terminalColor.rgb + col; + + // Make a mask that is 1.0 where the terminal content is not black + float mask = 1.2 - step(0.5, dot(terminalColor.rgb, vec3(1.0))); + vec3 blendedColor = mix(terminalColor.rgb * 1.2, col, mask); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/just-snow.glsl b/.config/ghostty/shaders/just-snow.glsl new file mode 100644 index 0000000..0eb7c80 --- /dev/null +++ b/.config/ghostty/shaders/just-snow.glsl @@ -0,0 +1,52 @@ +// Copyright (c) 2013 Andrew Baldwin (twitter: baldand, www: http://thndl.com) +// License = Attribution-NonCommercial-ShareAlike (http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_US) + +// "Just snow" +// Simple (but not cheap) snow made from multiple parallax layers with randomly positioned +// flakes and directions. Also includes a DoF effect. Pan around with mouse. + +#define LIGHT_SNOW // Comment this out for a blizzard + +#ifdef LIGHT_SNOW + #define LAYERS 50 + #define DEPTH .5 + #define WIDTH .3 + #define SPEED .6 +#else // BLIZZARD + #define LAYERS 200 + #define DEPTH .1 + #define WIDTH .8 + #define SPEED 1.5 +#endif + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + const mat3 p = mat3(13.323122,23.5112,21.71123,21.1212,28.7312,11.9312,21.8112,14.7212,61.3934); + vec2 uv = fragCoord.xy / iResolution.xy; + + vec3 acc = vec3(0.0); + float dof = 5.0 * sin(iTime * 0.1); + for (int i = 0; i < LAYERS; i++) { + float fi = float(i); + vec2 q =-uv*(1.0 + fi * DEPTH); + q += vec2(q.y * (WIDTH * mod(fi * 7.238917, 1.0) - WIDTH * 0.5), SPEED * iTime / (1.0 + fi * DEPTH * 0.03)); + vec3 n = vec3(floor(q), 31.189 + fi); + vec3 m = floor(n) * 0.00001 + fract(n); + vec3 mp = (31415.9 + m) / fract(p * m); + vec3 r = fract(mp); + vec2 s = abs(mod(q, 1.0) - 0.5 + 0.9 * r.xy - 0.45); + s += 0.01 * abs(2.0 * fract(10.0 * q.yx) - 1.0); + float d = 0.6 * max(s.x - s.y, s.x + s.y) + max(s.x, s.y) - 0.01; + float edge = 0.005 + 0.05 * min(0.5 * abs(fi - 5.0 - dof), 1.0); + acc += vec3(smoothstep(edge, -edge, d) * (r.x / (1.0 + 0.02 * fi * DEPTH))); + } + + // Sample the terminal screen texture including alpha channel + vec4 terminalColor = texture(iChannel0, uv); + + // Combine the snow effect with the terminal color + vec3 blendedColor = terminalColor.rgb + acc; + + // Use the terminal's original alpha + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/matrix-hallway.glsl b/.config/ghostty/shaders/matrix-hallway.glsl new file mode 100644 index 0000000..2bbee86 --- /dev/null +++ b/.config/ghostty/shaders/matrix-hallway.glsl @@ -0,0 +1,40 @@ +// based on the following Shader Toy entry +// +// [SH17A] Matrix rain. Created by Reinder Nijhoff 2017 +// Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. +// @reindernijhoff +// +// https://www.shadertoy.com/view/ldjBW1 +// + +#define SPEED_MULTIPLIER 1. +#define GREEN_ALPHA .33 + +#define BLACK_BLEND_THRESHOLD .4 + +#define R fract(1e2 * sin(p.x * 8. + p.y)) + +void mainImage(out vec4 fragColor, vec2 fragCoord) { + vec3 v = vec3(fragCoord, 1) / iResolution - .5; + // vec3 s = .5 / abs(v); + // scale? + vec3 s = .9 / abs(v); + s.z = min(s.y, s.x); + vec3 i = ceil( 8e2 * s.z * ( s.y < s.x ? v.xzz : v.zyz ) ) * .1; + vec3 j = fract(i); + i -= j; + vec3 p = vec3(9, int(iTime * SPEED_MULTIPLIER * (9. + 8. * sin(i).x)), 0) + i; + vec3 col = fragColor.rgb; + col.g = R / s.z; + p *= j; + col *= (R >.5 && j.x < .6 && j.y < .8) ? GREEN_ALPHA : 0.; + + // Sample the terminal screen texture including alpha channel + vec2 uv = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, uv); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb * 1.2, col, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/mnoise.glsl b/.config/ghostty/shaders/mnoise.glsl new file mode 100644 index 0000000..a414a46 --- /dev/null +++ b/.config/ghostty/shaders/mnoise.glsl @@ -0,0 +1,119 @@ +vec3 mod289(vec3 x) { return x - floor(x * (1.0 / 289.0)) * 289.0; } +vec4 mod289(vec4 x) { return x - floor(x * (1.0 / 289.0)) * 289.0; } +vec4 permute(vec4 x) { return mod289(((x * 34.0) + 10.0) * x); } +vec4 taylorInvSqrt(vec4 r) { return 1.79284291400159 - 0.85373472095314 * r; } +float snoise(vec3 v) { + const vec2 C = vec2(1.0 / 6.0, 1.0 / 3.0); + const vec4 D = vec4(0.0, 0.5, 1.0, 2.0); + + // First corner + vec3 i = floor(v + dot(v, C.yyy)); + vec3 x0 = v - i + dot(i, C.xxx); + + // Other corners + vec3 g = step(x0.yzx, x0.xyz); + vec3 l = 1.0 - g; + vec3 i1 = min(g.xyz, l.zxy); + vec3 i2 = max(g.xyz, l.zxy); + + // x0 = x0 - 0.0 + 0.0 * C.xxx; + // x1 = x0 - i1 + 1.0 * C.xxx; + // x2 = x0 - i2 + 2.0 * C.xxx; + // x3 = x0 - 1.0 + 3.0 * C.xxx; + vec3 x1 = x0 - i1 + C.xxx; + vec3 x2 = x0 - i2 + C.yyy; // 2.0*C.x = 1/3 = C.y + vec3 x3 = x0 - D.yyy; // -1.0+3.0*C.x = -0.5 = -D.y + + // Permutations + i = mod289(i); + vec4 p = permute(permute(permute(i.z + vec4(0.0, i1.z, i2.z, 1.0)) + i.y + + vec4(0.0, i1.y, i2.y, 1.0)) + + i.x + vec4(0.0, i1.x, i2.x, 1.0)); + + // Gradients: 7x7 points over a square, mapped onto an octahedron. + // The ring size 17*17 = 289 is close to a multiple of 49 (49*6 = 294) + float n_ = 0.142857142857; // 1.0/7.0 + vec3 ns = n_ * D.wyz - D.xzx; + + vec4 j = p - 49.0 * floor(p * ns.z * ns.z); // mod(p,7*7) + + vec4 x_ = floor(j * ns.z); + vec4 y_ = floor(j - 7.0 * x_); // mod(j,N) + + vec4 x = x_ * ns.x + ns.yyyy; + vec4 y = y_ * ns.x + ns.yyyy; + vec4 h = 1.0 - abs(x) - abs(y); + + vec4 b0 = vec4(x.xy, y.xy); + vec4 b1 = vec4(x.zw, y.zw); + + // vec4 s0 = vec4(lessThan(b0,0.0))*2.0 - 1.0; + // vec4 s1 = vec4(lessThan(b1,0.0))*2.0 - 1.0; + vec4 s0 = floor(b0) * 2.0 + 1.0; + vec4 s1 = floor(b1) * 2.0 + 1.0; + vec4 sh = -step(h, vec4(0.0)); + + vec4 a0 = b0.xzyw + s0.xzyw * sh.xxyy; + vec4 a1 = b1.xzyw + s1.xzyw * sh.zzww; + + vec3 p0 = vec3(a0.xy, h.x); + vec3 p1 = vec3(a0.zw, h.y); + vec3 p2 = vec3(a1.xy, h.z); + vec3 p3 = vec3(a1.zw, h.w); + + // Normalise gradients + vec4 norm = + taylorInvSqrt(vec4(dot(p0, p0), dot(p1, p1), dot(p2, p2), dot(p3, p3))); + p0 *= norm.x; + p1 *= norm.y; + p2 *= norm.z; + p3 *= norm.w; + + // Mix final noise value + vec4 m = + max(0.5 - vec4(dot(x0, x0), dot(x1, x1), dot(x2, x2), dot(x3, x3)), 0.0); + m = m * m; + return 105.0 * + dot(m * m, vec4(dot(p0, x0), dot(p1, x1), dot(p2, x2), dot(p3, x3))); +} + +float noise2D(vec2 uv) { + uvec2 pos = uvec2(floor(uv * 1000.)); + return float((pos.x * 68657387u ^ pos.y * 361524851u + pos.x) % 890129u) * + (1.0 / 890128.0); +} + +float roundRectSDF(vec2 center, vec2 size, float radius) { + return length(max(abs(center) - size + radius, 0.)) - radius; +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord / iResolution.xy, sd = vec2(2.), sdh = vec2(1.); + vec4 ghosttyCol = texture(iChannel0, uv); + float ratio = iResolution.y / iResolution.x, + fw = max(fwidth(uv.x), fwidth(uv.y)); + + vec2 puv = floor(uv * vec2(60., 60. * ratio)) / 60.; + puv += + (smoothstep(0., 0.7, noise2D(puv)) - 0.5) * 0.05 - vec2(0., iTime * 0.08); + + uv = fract(vec2(uv.x, uv.y * ratio) * 10.); + float d = roundRectSDF((sd + 0.01) * (uv - .5), sdh, 0.075), + d2 = roundRectSDF((sd + 0.065) * (fract(uv * 6.) - .5), sdh, 0.2), + noiseTime = iTime * 0.03, noise = snoise(vec3(puv, noiseTime)); + + noise += snoise(vec3(puv * 1.1, noiseTime + 0.5)) + .1; + noise += snoise(vec3(puv * 2., noiseTime + 0.8)); + noise = pow(noise, 2.); + + vec3 col1 = vec3(0.), col2 = vec3(0.), col3 = vec3(0.07898), + col4 = vec3(0.089184), + fcol = mix(mix(mix(col1, col3, smoothstep(0.0, 0.3, noise)), col2, + smoothstep(0.0, 0.5, noise)), + col4, smoothstep(0.0, 1.0, noise)); + + fragColor = vec4( + ghosttyCol.rgb + + mix(col4, fcol, smoothstep(fw, -fw, d) * smoothstep(fw, -fw, d2)), + ghosttyCol.a); +} diff --git a/.config/ghostty/shaders/negative.glsl b/.config/ghostty/shaders/negative.glsl new file mode 100644 index 0000000..48101f6 --- /dev/null +++ b/.config/ghostty/shaders/negative.glsl @@ -0,0 +1,8 @@ + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 uv = fragCoord/iResolution.xy; + vec4 color = texture(iChannel0, uv); + fragColor = vec4(1.0 - color.x, 1.0 - color.y, 1.0 - color.z, color.w); +} + diff --git a/.config/ghostty/shaders/retro-terminal.glsl b/.config/ghostty/shaders/retro-terminal.glsl new file mode 100644 index 0000000..c5f315a --- /dev/null +++ b/.config/ghostty/shaders/retro-terminal.glsl @@ -0,0 +1,34 @@ +// Original shader collected from: https://www.shadertoy.com/view/WsVSzV +// Licensed under Shadertoy's default since the original creator didn't provide any license. (CC BY NC SA 3.0) +// Slight modifications were made to give a green-ish effect. + +float warp = 0.25; // simulate curvature of CRT monitor +float scan = 0.50; // simulate darkness between scanlines + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + // squared distance from center + vec2 uv = fragCoord / iResolution.xy; + vec2 dc = abs(0.5 - uv); + dc *= dc; + + // warp the fragment coordinates + uv.x -= 0.5; uv.x *= 1.0 + (dc.y * (0.3 * warp)); uv.x += 0.5; + uv.y -= 0.5; uv.y *= 1.0 + (dc.x * (0.4 * warp)); uv.y += 0.5; + + // sample inside boundaries, otherwise set to black + if (uv.y > 1.0 || uv.x < 0.0 || uv.x > 1.0 || uv.y < 0.0) + fragColor = vec4(0.0, 0.0, 0.0, 1.0); + else + { + // determine if we are drawing in a scanline + float apply = abs(sin(fragCoord.y) * 0.5 * scan); + + // sample the texture and apply a teal tint + vec3 color = texture(iChannel0, uv).rgb; + vec3 tealTint = vec3(0.0, 0.8, 0.6); // teal color (slightly more green than blue) + + // mix the sampled color with the teal tint based on scanline intensity + fragColor = vec4(mix(color * tealTint, vec3(0.0), apply), 1.0); + } +} diff --git a/.config/ghostty/shaders/ripple_rectangle_cursor.glsl b/.config/ghostty/shaders/ripple_rectangle_cursor.glsl new file mode 100644 index 0000000..7b1aa34 --- /dev/null +++ b/.config/ghostty/shaders/ripple_rectangle_cursor.glsl @@ -0,0 +1,138 @@ +// CONFIGURATION +const float DURATION = 0.15; // How long the ripple animates (seconds) +const float MAX_SIZE = 0.05; // Max radius in normalized coords (0.5 = 1/4 screen height) +const float RING_THICKNESS = 0.02; // Ring width in normalized coords +const float CURSOR_WIDTH_CHANGE_THRESHOLD = 0.5; // Triggers ripple if cursor width changes by this fraction +vec4 COLOR = vec4(0.35, 0.36, 0.44, 1.0); // change to iCurrentCursorColor for your cursor's color +const float BLUR = 1.0; // Blur level in pixels +const float ANIMATION_START_OFFSET = 0.0; // Start the ripple slightly progressed (0.0 - 1.0) + + +// Easing functions +float easeOutQuad(float t) { + return 1.0 - (1.0 - t) * (1.0 - t); +} +float easeInOutQuad(float t) { + return t < 0.5 ? 2.0 * t * t : 1.0 - pow(-2.0 * t + 2.0, 2.0) / 2.0; +} +float easeOutCubic(float t) { + return 1.0 - pow(1.0 - t, 3.0); +} +float easeOutQuart(float t) { + return 1.0 - pow(1.0 - t, 4.0); +} +float easeOutQuint(float t) { + return 1.0 - pow(1.0 - t, 5.0); +} +float easeOutExpo(float t) { + return t == 1.0 ? 1.0 : 1.0 - pow(2.0, -10.0 * t); +} +float easeOutCirc(float t) { + return sqrt(1.0 - pow(t - 1.0, 2.0)); +} +float easeOutSine(float t) { + return sin((t * 3.1415916) / 2.0); +} +float easeOutElastic(float t) { + const float c4 = (2.0 * 3.1415916) / 3.0; + return t == 0.0 ? 0.0 : t == 1.0 ? 1.0 : pow(2.0, -10.0 * t) * sin((t * 10.0 - 0.75) * c4) + 1.0; +} +float easeOutBounce(float t) { + const float n1 = 7.5625; + const float d1 = 2.75; + if (t < 1.0 / d1) { + return n1 * t * t; + } else if (t < 2.0 / d1) { + return n1 * (t -= 1.5 / d1) * t + 0.75; + } else if (t < 2.5 / d1) { + return n1 * (t -= 2.25 / d1) * t + 0.9375; + } else { + return n1 * (t -= 2.625 / d1) * t + 0.984375; + } +} +float easeOutBack(float t) { + const float c1 = 1.70158; + const float c3 = c1 + 1.0; + return 1.0 + c3 * pow(t - 1.0, 3.0) + c1 * pow(t - 1.0, 2.0); +} + +// Pulse fade functions +float easeOutPulse(float t) { + return t * (2.0 - t); +} +float exponentialDecayPulse(float t) { + return exp(-3.0 * t) * sin(t * 3.1415916); +} + +vec2 normalize(vec2 value, float isPosition) { + return (value * 2.0 - (iResolution.xy * isPosition)) / iResolution.y; +} + +float getSdfRectangle(in vec2 p, in vec2 xy, in vec2 b){ + vec2 d = abs(p - xy) - b; + return length(max(d, 0.0)) + min(max(d.x, d.y), 0.0); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord){ + #if !defined(WEB) + fragColor = texture(iChannel0, fragCoord.xy / iResolution.xy); + #endif + + // Normalization & setup (-1 to 1 coords) + vec2 vu = normalize(fragCoord, 1.); + vec2 offsetFactor = vec2(-.5, 0.5); + + vec4 currentCursor = vec4(normalize(iCurrentCursor.xy, 1.), normalize(iCurrentCursor.zw, 0.)); + vec4 previousCursor = vec4(normalize(iPreviousCursor.xy, 1.), normalize(iPreviousCursor.zw, 0.)); + + vec2 centerCC = currentCursor.xy - (currentCursor.zw * offsetFactor); + + float cellWidth = max(currentCursor.z, previousCursor.z); // width of the 'block' cursor + + // check for significant width change + float widthChange = abs(currentCursor.z - previousCursor.z); + float widthThresholdNorm = cellWidth * CURSOR_WIDTH_CHANGE_THRESHOLD; + float isModeChange = step(widthThresholdNorm, widthChange); + + + // ANIMATION + float rippleProgress = (iTime - iTimeCursorChange) / DURATION + ANIMATION_START_OFFSET; + // don't clamp yet; we need to know if it's > 1.0 (finished) + float isAnimating = 1.0 - step(1.0, rippleProgress); // progress < 1.0 ? 1.0: 0.0 + + if (isModeChange > 0.0 && isAnimating > 0.0) { + // Apply easing to progress + // float easedProgress = rippleProgress; + // float easedProgress = easeOutQuad(rippleProgress); + // float easedProgress = easeInOutQuad(rippleProgress); + // float easedProgress = easeOutCubic(rippleProgress); + // float easedProgress = easeOutQuart(rippleProgress); + // float easedProgress = easeOutQuint(rippleProgress); + // float easedProgress = easeOutExpo(rippleProgress); + float easedProgress = easeOutCirc(rippleProgress); + // float easedProgress = easeOutSine(rippleProgress); + // float easedProgress = easeOutBack(rippleProgress); + + // RIPPLE CALCULATION + float rippleExpansion = easedProgress * MAX_SIZE; + + // float fade = 1.0; // no fade + // float fade = 1.0 - easedProgress; // linear fade + float fade = 1.0 - easeOutPulse(rippleProgress); + // float fade = 1.0 - exponentialDecayPulse(rippleProgress); + + // Calculate distance from frag to cursor center + // float dist = distance(vu, centerCC); + + // float sdfRing = abs(dist - rippleExpansion) - RING_THICKNESS * 0.5; + vec2 halfSizeCC = vec2(currentCursor.z, currentCursor.w) * 0.5 + vec2(rippleExpansion); + float sdfRectRing = abs(getSdfRectangle(vu, centerCC, halfSizeCC)) - RING_THICKNESS * 0.5; + // Antialias (1-pixel width in normalized coords) + float antiAliasSize = normalize(vec2(BLUR, BLUR), 0.0).x; + float ripple = (1.0 - smoothstep(-antiAliasSize, antiAliasSize, sdfRectRing)) * fade; + + // Apply ripple effect + fragColor = mix(fragColor, COLOR, ripple * COLOR.a); + } + // else: do nothing, keep original fragColor +} diff --git a/.config/ghostty/shaders/sin-interference.glsl b/.config/ghostty/shaders/sin-interference.glsl new file mode 100644 index 0000000..a1b9a40 --- /dev/null +++ b/.config/ghostty/shaders/sin-interference.glsl @@ -0,0 +1,28 @@ +// Based on https://www.shadertoy.com/view/ms3cWn +float map(float value, float min1, float max1, float min2, float max2) { + return min2 + (value - min1) * (max2 - min2) / (max1 - min1); +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 uv = fragCoord / iResolution.xy; + float d = length(uv - 0.5) * 2.0; + float t = d * d * 25.0 - iTime * 2.0; + vec3 col = 0.5 + 0.5 * cos(t / 20.0 + uv.xyx + vec3(0.0,2.0,4.0)); + + vec2 center = iResolution.xy * 0.5; + float distCentre = distance(fragCoord.xy, center); + float dCSin = sin(distCentre * 0.05); + + vec2 anim = vec2(map(sin(iTime),-1.0,1.0,0.0,iResolution.x),map(sin(iTime*1.25),-1.0,1.0,0.0,iResolution.y)); + float distMouse = distance(fragCoord.xy, anim); + float dMSin = sin(distMouse * 0.05); + + float greycol = (((dMSin * dCSin) + 1.0) * 0.5); + greycol = greycol * map(d, 0.0, 1.4142135623730951, 0.5, 0.0); + + vec4 terminalColor = texture(iChannel0, uv); + vec3 blendedColor = mix(terminalColor.rgb, vec3(greycol * col.x, greycol * col.y, greycol * col.z), 0.25); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/smoke-and-ghost.glsl b/.config/ghostty/shaders/smoke-and-ghost.glsl new file mode 100644 index 0000000..a11f8dc --- /dev/null +++ b/.config/ghostty/shaders/smoke-and-ghost.glsl @@ -0,0 +1,193 @@ +// Settings for detection +#define TARGET_COLOR vec3(0.0, 0.0, 0.0) // RGB target pixels to transform +#define REPLACE_COLOR vec3(0.0, 0.0, 0.0) // Color to replace target pixels +#define COLOR_TOLERANCE 0.001 // Color matching tolerance + +// Smoke effect settings +#define SMOKE_COLOR vec3(1., 1., 1.0) // Base color of smoke +#define SMOKE_RADIUS 0.011 // How far the smoke spreads +#define SMOKE_SPEED 0.5 // Speed of smoke movement +#define SMOKE_SCALE 25.0 // Scale of smoke detail +#define SMOKE_INTENSITY 0.2 // Intensity of the smoke effect +#define SMOKE_RISE_HEIGHT 0.14 // How high the smoke rises +#define ALPHA_MAX 0.5 // Maximum opacity for smoke +#define VERTICAL_BIAS 1.0 + +// Ghost face settings +#define FACE_COUNT 1 // Number of ghost faces +#define FACE_SCALE vec2(0.03, 0.05) // Size of faces, can be wider/elongated +#define FACE_DURATION 1.2 // How long faces last, can be wider/elongated +#define FACE_TRANSITION 1.5 // Face fade in/out duration +#define FACE_COLOR vec3(0.0, 0.0, 0.0) +#define GHOST_BG_COLOR vec3(1.0, 1.0, 1.0) +#define GHOST_BG_SCALE vec2(0.03, 0.06) + +float random(vec2 st) { + return fract(sin(dot(st.xy, vec2(12.9898,78.233))) * 43758.5453123); +} + +float random1(float n) { + return fract(sin(n) * 43758.5453123); +} + +vec2 random2(float n) { + return vec2( + random1(n), + random1(n + 1234.5678) + ); +} + +float noise(vec2 st) { + vec2 i = floor(st); + vec2 f = fract(st); + + float a = random(i); + float b = random(i + vec2(1.0, 0.0)); + float c = random(i + vec2(0.0, 1.0)); + float d = random(i + vec2(1.0, 1.0)); + + vec2 u = f * f * (3.0 - 2.0 * f); + return mix(a, b, u.x) + (c - a)* u.y * (1.0 - u.x) + (d - b) * u.x * u.y; +} + +// Modified elongated ellipse for more cartoon-like shapes +float cartoonEllipse(vec2 uv, vec2 center, vec2 scale) { + vec2 d = (uv - center) / scale; + float len = length(d); + // Add cartoon-like falloff + return smoothstep(1.0, 0.8, len); +} + +// Function to create ghost background shape +float ghostBackground(vec2 uv, vec2 center) { + vec2 d = (uv - center) / GHOST_BG_SCALE; + float baseShape = length(d * vec2(1.0, 0.8)); // Slightly oval + + // Add wavy bottom + float wave = sin(d.x * 6.28 + iTime) * 0.2; + float bottomWave = smoothstep(0.0, -0.5, d.y + wave); + + return smoothstep(1.0, 0.8, baseShape) + bottomWave; +} + +float ghostFace(vec2 uv, vec2 center, float time, float seed) { + vec2 faceUV = (uv - center) / FACE_SCALE; + + float eyeSize = 0.25 + random1(seed) * 0.05; + float eyeSpacing = 0.35; + vec2 leftEyePos = vec2(-eyeSpacing, 0.2); + vec2 rightEyePos = vec2(eyeSpacing, 0.2); + + float leftEye = cartoonEllipse(faceUV, leftEyePos, vec2(eyeSize)); + float rightEye = cartoonEllipse(faceUV, rightEyePos, vec2(eyeSize)); + + // Add simple eye highlights + float leftHighlight = cartoonEllipse(faceUV, leftEyePos + vec2(0.1, 0.1), vec2(eyeSize * 0.3)); + float rightHighlight = cartoonEllipse(faceUV, rightEyePos + vec2(0.1, 0.1), vec2(eyeSize * 0.3)); + + vec2 mouthUV = faceUV - vec2(0.0, -0.9); + float mouthWidth = 0.5 + random1(seed + 3.0) * 0.1; + float mouthHeight = 0.8 + random1(seed + 7.0) * 0.1; + + float mouth = cartoonEllipse(mouthUV, vec2(0.0), vec2(mouthWidth, mouthHeight)); + + // Combine features + float face = max(max(leftEye, rightEye), mouth); + face = max(face, max(leftHighlight, rightHighlight)); + + // Add border falloff + face *= smoothstep(1.2, 0.8, length(faceUV)); + + return face; +} + +float calculateSmoke(vec2 uv, vec2 sourcePos) { + float verticalDisp = (uv.y - sourcePos.y) * VERTICAL_BIAS; + vec2 smokeUV = uv * SMOKE_SCALE; + smokeUV.y -= iTime * SMOKE_SPEED * (1.0 + verticalDisp); + smokeUV.x += sin(iTime * 0.5 + uv.y * 4.0) * 0.1; + + float n = noise(smokeUV) * 0.5 + 0.5; + n += noise(smokeUV * 2.0 + iTime * 0.1) * 0.25; + + float verticalFalloff = 1.0 - smoothstep(0.0, SMOKE_RISE_HEIGHT, verticalDisp); + return n * verticalFalloff; +} + +float isTargetPixel(vec2 uv) { + vec4 color = texture(iChannel0, uv); + return float(all(lessThan(abs(color.rgb - TARGET_COLOR), vec3(COLOR_TOLERANCE)))); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = fragCoord/iResolution.xy; + vec4 originalColor = texture(iChannel0, uv); + + // Calculate smoke effect + float smokeAccum = 0.0; + float targetInfluence = 0.0; + + float stepSize = SMOKE_RADIUS / 4.0; + for (float x = -SMOKE_RADIUS; x <= SMOKE_RADIUS; x += stepSize) { + for (float y = -SMOKE_RADIUS; y <= 0.0; y += stepSize) { + vec2 offset = vec2(x, y); + vec2 sampleUV = uv + offset; + + if (sampleUV.x >= 0.0 && sampleUV.x <= 1.0 && + sampleUV.y >= 0.0 && sampleUV.y <= 1.0) { + float isTarget = isTargetPixel(sampleUV); + if (isTarget > 0.0) { + float dist = length(offset); + float falloff = 1.0 - smoothstep(0.0, SMOKE_RADIUS, dist); + float smoke = calculateSmoke(uv, sampleUV); + smokeAccum += smoke * falloff; + targetInfluence += falloff; + } + } + } + } + + smokeAccum /= max(targetInfluence, 1.0); + targetInfluence = smoothstep(0.0, 1.0, targetInfluence); + float smokePresence = smokeAccum * targetInfluence; + + // Calculate ghost faces with backgrounds + float faceAccum = 0.0; + float bgAccum = 0.0; + float timeBlock = floor(iTime / FACE_DURATION); + + if (smokePresence > 0.2) { + for (int i = 0; i < FACE_COUNT; i++) { + vec2 facePos = random2(timeBlock + float(i) * 1234.5); + facePos = facePos * 0.8 + 0.1; + + float faceTime = mod(iTime, FACE_DURATION); + float fadeFactor = smoothstep(0.0, FACE_TRANSITION, faceTime) * + (1.0 - smoothstep(FACE_DURATION - FACE_TRANSITION, FACE_DURATION, faceTime)); + + // Add ghost background + float ghostBg = ghostBackground(uv, facePos) * fadeFactor; + bgAccum = max(bgAccum, ghostBg); + + // Add face features + float face = ghostFace(uv, facePos, iTime, timeBlock + float(i) * 100.0) * fadeFactor; + faceAccum = max(faceAccum, face); + } + + bgAccum *= smoothstep(0.2, 0.4, smokePresence); + faceAccum *= smoothstep(0.2, 0.4, smokePresence); + } + + // Combine all elements + bool isTarget = all(lessThan(abs(originalColor.rgb - TARGET_COLOR), vec3(COLOR_TOLERANCE))); + vec3 baseColor = isTarget ? REPLACE_COLOR : originalColor.rgb; + + // Layer the effects: base -> smoke -> ghost background -> face features + vec3 smokeEffect = mix(baseColor, SMOKE_COLOR, smokeAccum * SMOKE_INTENSITY * targetInfluence * (1.0 - faceAccum)); + vec3 withBackground = mix(smokeEffect, GHOST_BG_COLOR, bgAccum * 0.7); + vec3 finalColor = mix(withBackground, FACE_COLOR, faceAccum); + + float alpha = mix(originalColor.a, ALPHA_MAX, max(smokePresence, max(bgAccum, faceAccum) * smokePresence)); + + fragColor = vec4(finalColor, alpha); +} diff --git a/.config/ghostty/shaders/sparks-from-fire.glsl b/.config/ghostty/shaders/sparks-from-fire.glsl new file mode 100644 index 0000000..4adb791 --- /dev/null +++ b/.config/ghostty/shaders/sparks-from-fire.glsl @@ -0,0 +1,242 @@ +// adapted by Alex Sherwin for Ghstty from https://www.shadertoy.com/view/wl2Gzc + +//Shader License: CC BY 3.0 +//Author: Jan Mróz (jaszunio15) + +#define SMOKE_INTENSITY_MULTIPLIER 0.9 +#define PARTICLES_ALPHA_MOD 0.9 +#define SMOKE_ALPHA_MOD 0.5 +#define LAYERS_COUNT 8 + +#define BLACK_BLEND_THRESHOLD .4 + +#define VEC3_1 (vec3(1.0)) + +#define PI 3.1415927 +#define TWO_PI 6.283185 + +#define ANIMATION_SPEED 1.0 +#define MOVEMENT_SPEED .33 +#define MOVEMENT_DIRECTION vec2(0.7, 1.0) + +#define PARTICLE_SIZE 0.0025 + +#define PARTICLE_SCALE (vec2(0.5, 1.6)) +#define PARTICLE_SCALE_VAR (vec2(0.25, 0.2)) + +#define PARTICLE_BLOOM_SCALE (vec2(0.5, 0.8)) +#define PARTICLE_BLOOM_SCALE_VAR (vec2(0.3, 0.1)) + +#define SPARK_COLOR vec3(1.0, 0.4, 0.05) * 1.5 +#define BLOOM_COLOR vec3(1.0, 0.4, 0.05) * 0.8 +#define SMOKE_COLOR vec3(1.0, 0.43, 0.1) * 0.8 + +#define SIZE_MOD 1.05 + + +float hash1_2(in vec2 x) +{ + return fract(sin(dot(x, vec2(52.127, 61.2871))) * 521.582); +} + +vec2 hash2_2(in vec2 x) +{ + return fract(sin(x * mat2x2(20.52, 24.1994, 70.291, 80.171)) * 492.194); +} + +//Simple interpolated noise +vec2 noise2_2(vec2 uv) +{ + //vec2 f = fract(uv); + vec2 f = smoothstep(0.0, 1.0, fract(uv)); + + vec2 uv00 = floor(uv); + vec2 uv01 = uv00 + vec2(0,1); + vec2 uv10 = uv00 + vec2(1,0); + vec2 uv11 = uv00 + 1.0; + vec2 v00 = hash2_2(uv00); + vec2 v01 = hash2_2(uv01); + vec2 v10 = hash2_2(uv10); + vec2 v11 = hash2_2(uv11); + + vec2 v0 = mix(v00, v01, f.y); + vec2 v1 = mix(v10, v11, f.y); + vec2 v = mix(v0, v1, f.x); + + return v; +} + +//Simple interpolated noise +float noise1_2(in vec2 uv) +{ + // vec2 f = fract(uv); + vec2 f = smoothstep(0.0, 1.0, fract(uv)); + + vec2 uv00 = floor(uv); + vec2 uv01 = uv00 + vec2(0,1); + vec2 uv10 = uv00 + vec2(1,0); + vec2 uv11 = uv00 + 1.0; + + float v00 = hash1_2(uv00); + float v01 = hash1_2(uv01); + float v10 = hash1_2(uv10); + float v11 = hash1_2(uv11); + + float v0 = mix(v00, v01, f.y); + float v1 = mix(v10, v11, f.y); + float v = mix(v0, v1, f.x); + + return v; +} + + +float layeredNoise1_2(in vec2 uv, in float sizeMod, in float alphaMod, in int layers, in float animation) +{ + float noise = 0.0; + float alpha = 1.0; + float size = 1.0; + vec2 offset; + for (int i = 0; i < layers; i++) + { + offset += hash2_2(vec2(alpha, size)) * 10.0; + + //Adding noise with movement + noise += noise1_2(uv * size + iTime * animation * 8.0 * MOVEMENT_DIRECTION * MOVEMENT_SPEED + offset) * alpha; + alpha *= alphaMod; + size *= sizeMod; + } + + noise *= (1.0 - alphaMod)/(1.0 - pow(alphaMod, float(layers))); + return noise; +} + +//Rotates point around 0,0 +vec2 rotate(in vec2 point, in float deg) +{ + float s = sin(deg); + float c = cos(deg); + return mat2x2(s, c, -c, s) * point; +} + +//Cell center from point on the grid +vec2 voronoiPointFromRoot(in vec2 root, in float deg) +{ + vec2 point = hash2_2(root) - 0.5; + float s = sin(deg); + float c = cos(deg); + point = mat2x2(s, c, -c, s) * point * 0.66; + point += root + 0.5; + return point; +} + +//Voronoi cell point rotation degrees +float degFromRootUV(in vec2 uv) +{ + return iTime * ANIMATION_SPEED * (hash1_2(uv) - 0.5) * 2.0; +} + +vec2 randomAround2_2(in vec2 point, in vec2 range, in vec2 uv) +{ + return point + (hash2_2(uv) - 0.5) * range; +} + + +vec3 fireParticles(in vec2 uv, in vec2 originalUV) +{ + vec3 particles = vec3(0.0); + vec2 rootUV = floor(uv); + float deg = degFromRootUV(rootUV); + vec2 pointUV = voronoiPointFromRoot(rootUV, deg); + float dist = 2.0; + float distBloom = 0.0; + + //UV manipulation for the faster particle movement + vec2 tempUV = uv + (noise2_2(uv * 2.0) - 0.5) * 0.1; + tempUV += -(noise2_2(uv * 3.0 + iTime) - 0.5) * 0.07; + + //Sparks sdf + dist = length(rotate(tempUV - pointUV, 0.7) * randomAround2_2(PARTICLE_SCALE, PARTICLE_SCALE_VAR, rootUV)); + + //Bloom sdf + distBloom = length(rotate(tempUV - pointUV, 0.7) * randomAround2_2(PARTICLE_BLOOM_SCALE, PARTICLE_BLOOM_SCALE_VAR, rootUV)); + + //Add sparks + particles += (1.0 - smoothstep(PARTICLE_SIZE * 0.6, PARTICLE_SIZE * 3.0, dist)) * SPARK_COLOR; + + //Add bloom + particles += pow((1.0 - smoothstep(0.0, PARTICLE_SIZE * 6.0, distBloom)) * 1.0, 3.0) * BLOOM_COLOR; + + //Upper disappear curve randomization + float border = (hash1_2(rootUV) - 0.5) * 2.0; + float disappear = 1.0 - smoothstep(border, border + 0.5, originalUV.y); + + //Lower appear curve randomization + border = (hash1_2(rootUV + 0.214) - 1.8) * 0.7; + float appear = smoothstep(border, border + 0.4, originalUV.y); + + return particles * disappear * appear; +} + + +//Layering particles to imitate 3D view +vec3 layeredParticles(in vec2 uv, in float sizeMod, in float alphaMod, in int layers, in float smoke) +{ + vec3 particles = vec3(0); + float size = 1.0; + // float alpha = 1.0; + float alpha = 1.0; + vec2 offset = vec2(0.0); + vec2 noiseOffset; + vec2 bokehUV; + + for (int i = 0; i < layers; i++) + { + //Particle noise movement + noiseOffset = (noise2_2(uv * size * 2.0 + 0.5) - 0.5) * 0.15; + + //UV with applied movement + bokehUV = (uv * size + iTime * MOVEMENT_DIRECTION * MOVEMENT_SPEED) + offset + noiseOffset; + + //Adding particles if there is more smoke, remove smaller particles + particles += fireParticles(bokehUV, uv) * alpha * (1.0 - smoothstep(0.0, 1.0, smoke) * (float(i) / float(layers))); + + //Moving uv origin to avoid generating the same particles + offset += hash2_2(vec2(alpha, alpha)) * 10.0; + + alpha *= alphaMod; + size *= sizeMod; + } + + return particles; +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + vec2 uv = (2.0 * fragCoord - iResolution.xy) / iResolution.x; + + // float vignette = 1.1 - smoothstep(0.4, 1.4, length(uv + vec2(0.0, 0.3))); + float vignette = 1.3 - smoothstep(0.4, 1.4, length(uv + vec2(0.0, 0.3))); + + uv *= 2.5; + + float smokeIntensity = layeredNoise1_2(uv * 10.0 + iTime * 4.0 * MOVEMENT_DIRECTION * MOVEMENT_SPEED, 1.7, 0.7, 6, 0.2); + smokeIntensity *= pow(smoothstep(-1.0, 1.6, uv.y), 2.0); + vec3 smoke = smokeIntensity * SMOKE_COLOR * vignette * SMOKE_INTENSITY_MULTIPLIER * SMOKE_ALPHA_MOD; + + //Cutting holes in smoke + smoke *= pow(layeredNoise1_2(uv * 4.0 + iTime * 0.5 * MOVEMENT_DIRECTION * MOVEMENT_SPEED, 1.8, 0.5, 3, 0.2), 2.0) * 1.5; + + vec3 particles = layeredParticles(uv, SIZE_MOD, PARTICLES_ALPHA_MOD, LAYERS_COUNT, smokeIntensity); + + vec3 col = particles + smoke + SMOKE_COLOR * 0.02; + col *= vignette; + + col = smoothstep(-0.08, 1.0, col); + + vec2 termUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, termUV); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb, col, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/spotlight.glsl b/.config/ghostty/shaders/spotlight.glsl new file mode 100644 index 0000000..19f457a --- /dev/null +++ b/.config/ghostty/shaders/spotlight.glsl @@ -0,0 +1,42 @@ +// Created by Paul Robello + + +// Smooth oscillating function that varies over time +float smoothOscillation(float t, float frequency, float phase) { + return sin(t * frequency + phase); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) { + // Resolution and UV coordinates + vec2 uv = fragCoord.xy / iResolution.xy; + + // Used to fix distortion when calculating distance to circle center + vec2 ratio = vec2(iResolution.x / iResolution.y, 1.0); + + // Get the texture from iChannel0 + vec4 texColor = texture(iChannel0, uv); + + // Spotlight center moving based on a smooth random pattern + float time = iTime * 1.0; // Control speed of motion + vec2 spotlightCenter = vec2( + 0.5 + 0.4 * smoothOscillation(time, 1.0, 0.0), // Smooth X motion + 0.5 + 0.4 * smoothOscillation(time, 1.3, 3.14159) // Smooth Y motion with different frequency and phase + ); + + // Distance from the spotlight center + float distanceToCenter = distance(uv * ratio, spotlightCenter); + + // Spotlight intensity based on distance + float spotlightRadius = 0.25; // Spotlight radius + float softness = 20.0; // Spotlight edge softness. Higher values have sharper edge + float spotlightIntensity = smoothstep(spotlightRadius, spotlightRadius - (1.0 / softness), distanceToCenter); + + // Ambient light level + float ambientLight = 0.5; // Controls the minimum brightness across the texture + + // Combine the spotlight effect with the texture + vec3 spotlightEffect = texColor.rgb * mix(vec3(ambientLight), vec3(1.0), spotlightIntensity); + + // Final color output + fragColor = vec4(spotlightEffect, texColor.a); +} \ No newline at end of file diff --git a/.config/ghostty/shaders/starfield-colors.glsl b/.config/ghostty/shaders/starfield-colors.glsl new file mode 100644 index 0000000..d4e0d14 --- /dev/null +++ b/.config/ghostty/shaders/starfield-colors.glsl @@ -0,0 +1,158 @@ +// transparent background +const bool transparent = false; + +// terminal contents luminance threshold to be considered background (0.0 to 1.0) +const float threshold = 0.15; + +// divisions of grid +const float repeats = 30.; + +// number of layers +const float layers = 21.; + +// star colours +const vec3 blue = vec3(51., 64., 195.) / 255.; +const vec3 cyan = vec3(117., 250., 254.) / 255.; +const vec3 white = vec3(255., 255., 255.) / 255.; +const vec3 yellow = vec3(251., 245., 44.) / 255.; +const vec3 red = vec3(247, 2., 20.) / 255.; + +float luminance(vec3 color) { + return dot(color, vec3(0.2126, 0.7152, 0.0722)); +} + +// spectrum function +vec3 spectrum(vec2 pos) { + pos.x *= 4.; + vec3 outCol = vec3(0); + if (pos.x > 0.) { + outCol = mix(blue, cyan, fract(pos.x)); + } + if (pos.x > 1.) { + outCol = mix(cyan, white, fract(pos.x)); + } + if (pos.x > 2.) { + outCol = mix(white, yellow, fract(pos.x)); + } + if (pos.x > 3.) { + outCol = mix(yellow, red, fract(pos.x)); + } + + return 1. - (pos.y * (1. - outCol)); +} + +float N21(vec2 p) { + p = fract(p * vec2(233.34, 851.73)); + p += dot(p, p + 23.45); + return fract(p.x * p.y); +} + +vec2 N22(vec2 p) { + float n = N21(p); + return vec2(n, N21(p + n)); +} + +mat2 scale(vec2 _scale) { + return mat2(_scale.x, 0.0, + 0.0, _scale.y); +} + +// 2D Noise based on Morgan McGuire +float noise(in vec2 st) { + vec2 i = floor(st); + vec2 f = fract(st); + + // Four corners in 2D of a tile + float a = N21(i); + float b = N21(i + vec2(1.0, 0.0)); + float c = N21(i + vec2(0.0, 1.0)); + float d = N21(i + vec2(1.0, 1.0)); + + // Smooth Interpolation + vec2 u = f * f * (3.0 - 2.0 * f); // Cubic Hermite Curve + + // Mix 4 corners percentages + return mix(a, b, u.x) + + (c - a) * u.y * (1.0 - u.x) + + (d - b) * u.x * u.y; +} + +float perlin2(vec2 uv, int octaves, float pscale) { + float col = 1.; + float initScale = 4.; + for (int l; l < octaves; l++) { + float val = noise(uv * initScale); + if (col <= 0.01) { + col = 0.; + break; + } + val -= 0.01; + val *= 0.5; + col *= val; + initScale *= pscale; + } + return col; +} + +vec3 stars(vec2 uv, float offset) { + float timeScale = -(iTime + offset) / layers; + float trans = fract(timeScale); + float newRnd = floor(timeScale); + vec3 col = vec3(0.); + + // Translate uv then scale for center + uv -= vec2(0.5); + uv = scale(vec2(trans)) * uv; + uv += vec2(0.5); + + // Create square aspect ratio + uv.x *= iResolution.x / iResolution.y; + + // Create boxes + uv *= repeats; + + // Get position + vec2 ipos = floor(uv); + + // Return uv as 0 to 1 + uv = fract(uv); + + // Calculate random xy and size + vec2 rndXY = N22(newRnd + ipos * (offset + 1.)) * 0.9 + 0.05; + float rndSize = N21(ipos) * 100. + 200.; + + vec2 j = (rndXY - uv) * rndSize; + float sparkle = 1. / dot(j, j); + + // Set stars to be pure white + col += spectrum(fract(rndXY * newRnd * ipos)) * vec3(sparkle); + + col *= smoothstep(1., 0.8, trans); + return col; // Return pure white stars only +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + // Normalized pixel coordinates (from 0 to 1) + vec2 uv = fragCoord / iResolution.xy; + + vec3 col = vec3(0.); + + for (float i = 0.; i < layers; i++) { + col += stars(uv, i); + } + + // Sample the terminal screen texture including alpha channel + vec4 terminalColor = texture(iChannel0, uv); + + if (transparent) { + col += terminalColor.rgb; + } + + // Make a mask that is 1.0 where the terminal content is not black + float mask = 1 - step(threshold, luminance(terminalColor.rgb)); + vec3 blendedColor = mix(terminalColor.rgb, col, mask); + + // Apply terminal's alpha to control overall opacity + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/starfield.glsl b/.config/ghostty/shaders/starfield.glsl new file mode 100644 index 0000000..f82b5d3 --- /dev/null +++ b/.config/ghostty/shaders/starfield.glsl @@ -0,0 +1,135 @@ +// transparent background +const bool transparent = false; + +// terminal contents luminance threshold to be considered background (0.0 to 1.0) +const float threshold = 0.15; + +// divisions of grid +const float repeats = 30.; + +// number of layers +const float layers = 21.; + +// star colors +const vec3 white = vec3(1.0); // Set star color to pure white + +float luminance(vec3 color) { + return dot(color, vec3(0.2126, 0.7152, 0.0722)); +} + +float N21(vec2 p) { + p = fract(p * vec2(233.34, 851.73)); + p += dot(p, p + 23.45); + return fract(p.x * p.y); +} + +vec2 N22(vec2 p) { + float n = N21(p); + return vec2(n, N21(p + n)); +} + +mat2 scale(vec2 _scale) { + return mat2(_scale.x, 0.0, + 0.0, _scale.y); +} + +// 2D Noise based on Morgan McGuire +float noise(in vec2 st) { + vec2 i = floor(st); + vec2 f = fract(st); + + // Four corners in 2D of a tile + float a = N21(i); + float b = N21(i + vec2(1.0, 0.0)); + float c = N21(i + vec2(0.0, 1.0)); + float d = N21(i + vec2(1.0, 1.0)); + + // Smooth Interpolation + vec2 u = f * f * (3.0 - 2.0 * f); // Cubic Hermite Curve + + // Mix 4 corners percentages + return mix(a, b, u.x) + + (c - a) * u.y * (1.0 - u.x) + + (d - b) * u.x * u.y; +} + +float perlin2(vec2 uv, int octaves, float pscale) { + float col = 1.; + float initScale = 4.; + for (int l; l < octaves; l++) { + float val = noise(uv * initScale); + if (col <= 0.01) { + col = 0.; + break; + } + val -= 0.01; + val *= 0.5; + col *= val; + initScale *= pscale; + } + return col; +} + +vec3 stars(vec2 uv, float offset) { + float timeScale = -(iTime + offset) / layers; + float trans = fract(timeScale); + float newRnd = floor(timeScale); + vec3 col = vec3(0.); + + // Translate uv then scale for center + uv -= vec2(0.5); + uv = scale(vec2(trans)) * uv; + uv += vec2(0.5); + + // Create square aspect ratio + uv.x *= iResolution.x / iResolution.y; + + // Create boxes + uv *= repeats; + + // Get position + vec2 ipos = floor(uv); + + // Return uv as 0 to 1 + uv = fract(uv); + + // Calculate random xy and size + vec2 rndXY = N22(newRnd + ipos * (offset + 1.)) * 0.9 + 0.05; + float rndSize = N21(ipos) * 100. + 200.; + + vec2 j = (rndXY - uv) * rndSize; + float sparkle = 1. / dot(j, j); + + // Set stars to be pure white + col += white * sparkle; + + col *= smoothstep(1., 0.8, trans); + return col; // Return pure white stars only +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + // Normalized pixel coordinates (from 0 to 1) + vec2 uv = fragCoord / iResolution.xy; + + vec3 col = vec3(0.); + + for (float i = 0.; i < layers; i++) { + col += stars(uv, i); + } + + // Sample the terminal screen texture including alpha channel + vec4 terminalColor = texture(iChannel0, uv); + + if (transparent) { + col += terminalColor.rgb; + } + + // Make a mask that is 1.0 where the terminal content is not black + float mask = 1 - step(threshold, luminance(terminalColor.rgb)); + + vec3 blendedColor = mix(terminalColor.rgb, col, mask); + + // Apply terminal's alpha to control overall opacity + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/tft.glsl b/.config/ghostty/shaders/tft.glsl new file mode 100644 index 0000000..3d77443 --- /dev/null +++ b/.config/ghostty/shaders/tft.glsl @@ -0,0 +1,23 @@ +/** Size of TFT "pixels" */ +float resolution = 4.0; + +/** Strength of effect */ +float strength = 0.5; + +void _scanline(inout vec3 color, vec2 uv) +{ + float scanline = step(1.2, mod(uv.y * iResolution.y, resolution)); + float grille = step(1.2, mod(uv.x * iResolution.x, resolution)); + color *= max(1.0 - strength, scanline * grille); +} + +void mainImage(out vec4 fragColor, in vec2 fragCoord) +{ + vec2 uv = fragCoord.xy / iResolution.xy; + vec3 color = texture(iChannel0, uv).rgb; + + _scanline(color, uv); + + fragColor.xyz = color; + fragColor.w = 1.0; +} diff --git a/.config/ghostty/shaders/theme/bettercrt.png b/.config/ghostty/shaders/theme/bettercrt.png new file mode 100644 index 0000000..ae7bb97 Binary files /dev/null and b/.config/ghostty/shaders/theme/bettercrt.png differ diff --git a/.config/ghostty/shaders/theme/bloom.png b/.config/ghostty/shaders/theme/bloom.png new file mode 100644 index 0000000..818705a Binary files /dev/null and b/.config/ghostty/shaders/theme/bloom.png differ diff --git a/.config/ghostty/shaders/theme/cineShader-Lava.png b/.config/ghostty/shaders/theme/cineShader-Lava.png new file mode 100644 index 0000000..fe13333 Binary files /dev/null and b/.config/ghostty/shaders/theme/cineShader-Lava.png differ diff --git a/.config/ghostty/shaders/theme/crt.png b/.config/ghostty/shaders/theme/crt.png new file mode 100644 index 0000000..551b3f3 Binary files /dev/null and b/.config/ghostty/shaders/theme/crt.png differ diff --git a/.config/ghostty/shaders/theme/cubes.png b/.config/ghostty/shaders/theme/cubes.png new file mode 100644 index 0000000..a876d3f Binary files /dev/null and b/.config/ghostty/shaders/theme/cubes.png differ diff --git a/.config/ghostty/shaders/theme/dither.png b/.config/ghostty/shaders/theme/dither.png new file mode 100644 index 0000000..7660ba7 Binary files /dev/null and b/.config/ghostty/shaders/theme/dither.png differ diff --git a/.config/ghostty/shaders/theme/drunkard.png b/.config/ghostty/shaders/theme/drunkard.png new file mode 100644 index 0000000..d163c81 Binary files /dev/null and b/.config/ghostty/shaders/theme/drunkard.png differ diff --git a/.config/ghostty/shaders/theme/fireworks-rocket.png b/.config/ghostty/shaders/theme/fireworks-rocket.png new file mode 100644 index 0000000..83311f7 Binary files /dev/null and b/.config/ghostty/shaders/theme/fireworks-rocket.png differ diff --git a/.config/ghostty/shaders/theme/fireworks.png b/.config/ghostty/shaders/theme/fireworks.png new file mode 100644 index 0000000..7c6f0e0 Binary files /dev/null and b/.config/ghostty/shaders/theme/fireworks.png differ diff --git a/.config/ghostty/shaders/theme/gears-and-belts.png b/.config/ghostty/shaders/theme/gears-and-belts.png new file mode 100644 index 0000000..4e294df Binary files /dev/null and b/.config/ghostty/shaders/theme/gears-and-belts.png differ diff --git a/.config/ghostty/shaders/theme/glitchy.png b/.config/ghostty/shaders/theme/glitchy.png new file mode 100644 index 0000000..16d3dfb Binary files /dev/null and b/.config/ghostty/shaders/theme/glitchy.png differ diff --git a/.config/ghostty/shaders/underwater.glsl b/.config/ghostty/shaders/underwater.glsl new file mode 100644 index 0000000..8c2fb22 --- /dev/null +++ b/.config/ghostty/shaders/underwater.glsl @@ -0,0 +1,74 @@ +// adapted by Alex Sherwin for Ghostty from https://www.shadertoy.com/view/lljGDt + +#define BLACK_BLEND_THRESHOLD .4 + +float hash21(vec2 p) { + p = fract(p * vec2(233.34, 851.73)); + p += dot(p, p + 23.45); + return fract(p.x * p.y); +} + +float rayStrength(vec2 raySource, vec2 rayRefDirection, vec2 coord, float seedA, float seedB, float speed) +{ + vec2 sourceToCoord = coord - raySource; + float cosAngle = dot(normalize(sourceToCoord), rayRefDirection); + + // Add subtle dithering based on screen coordinates + float dither = hash21(coord) * 0.015 - 0.0075; + + float ray = clamp( + (0.45 + 0.15 * sin(cosAngle * seedA + iTime * speed)) + + (0.3 + 0.2 * cos(-cosAngle * seedB + iTime * speed)) + dither, + 0.0, 1.0); + + // Smoothstep the distance falloff + float distFade = smoothstep(0.0, iResolution.x, iResolution.x - length(sourceToCoord)); + return ray * mix(0.5, 1.0, distFade); +} + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec2 uv = fragCoord.xy / iResolution.xy; + + uv.y = 1.0 - uv.y; + vec2 coord = vec2(fragCoord.x, iResolution.y - fragCoord.y); + + // Set the parameters of the sun rays + vec2 rayPos1 = vec2(iResolution.x * 0.7, iResolution.y * 1.1); + vec2 rayRefDir1 = normalize(vec2(1.0, 0.116)); + float raySeedA1 = 36.2214; + float raySeedB1 = 21.11349; + float raySpeed1 = 1.1; + + vec2 rayPos2 = vec2(iResolution.x * 0.8, iResolution.y * 1.2); + vec2 rayRefDir2 = normalize(vec2(1.0, -0.241)); + const float raySeedA2 = 22.39910; + const float raySeedB2 = 18.0234; + const float raySpeed2 = 0.9; + + // Calculate the colour of the sun rays on the current fragment + vec4 rays1 = + vec4(1.0, 1.0, 1.0, 0.0) * + rayStrength(rayPos1, rayRefDir1, coord, raySeedA1, raySeedB1, raySpeed1); + + vec4 rays2 = + vec4(1.0, 1.0, 1.0, 0.0) * + rayStrength(rayPos2, rayRefDir2, coord, raySeedA2, raySeedB2, raySpeed2); + + vec4 col = rays1 * 0.5 + rays2 * 0.4; + + // Attenuate brightness towards the bottom, simulating light-loss due to depth. + // Give the whole thing a blue-green tinge as well. + float brightness = 1.0 - (coord.y / iResolution.y); + col.r *= 0.05 + (brightness * 0.8); + col.g *= 0.15 + (brightness * 0.6); + col.b *= 0.3 + (brightness * 0.5); + + vec2 termUV = fragCoord.xy / iResolution.xy; + vec4 terminalColor = texture(iChannel0, termUV); + + float alpha = step(length(terminalColor.rgb), BLACK_BLEND_THRESHOLD); + vec3 blendedColor = mix(terminalColor.rgb * 1.0, col.rgb * 0.3, alpha); + + fragColor = vec4(blendedColor, terminalColor.a); +} diff --git a/.config/ghostty/shaders/water.glsl b/.config/ghostty/shaders/water.glsl new file mode 100644 index 0000000..c240b58 --- /dev/null +++ b/.config/ghostty/shaders/water.glsl @@ -0,0 +1,35 @@ + +#define TAU 6.28318530718 +#define MAX_ITER 6 + +void mainImage( out vec4 fragColor, in vec2 fragCoord ) +{ + vec3 water_color = vec3(1.0, 1.0, 1.0) * 0.5; + float time = iTime * 0.5+23.0; + vec2 uv = fragCoord.xy / iResolution.xy; + + vec2 p = mod(uv*TAU, TAU)-250.0; + vec2 i = vec2(p); + float c = 1.0; + float inten = 0.005; + + for (int n = 0; n < MAX_ITER; n++) + { + float t = time * (1.0 - (3.5 / float(n+1))); + i = p + vec2(cos(t - i.x) + sin(t + i.y), sin(t - i.y) + cos(t + i.x)); + c += 1.0/length(vec2(p.x / (sin(i.x+t)/inten),p.y / (cos(i.y+t)/inten))); + } + c /= float(MAX_ITER); + c = 1.17-pow(c, 1.4); + vec3 color = vec3(pow(abs(c), 15.0)); + color = clamp((color + water_color)*1.2, 0.0, 1.0); + + // perterb uv based on value of c from caustic calc above + vec2 tc = vec2(cos(c)-0.75,sin(c)-0.75)*0.04; + uv = clamp(uv + tc,0.0,1.0); + + fragColor = texture(iChannel0, uv); + // give transparent pixels a color + if ( fragColor.a == 0.0 ) fragColor=vec4(1.0,1.0,1.0,1.0); + fragColor *= vec4(color, 1.0); +} \ No newline at end of file diff --git a/.config/gtkrc b/.config/gtkrc index f4a4888..a1701c6 100644 --- a/.config/gtkrc +++ b/.config/gtkrc @@ -1,4 +1,4 @@ -# created by KDE Plasma, Tue Dec 16 00:23:11 2025 +# created by KDE Plasma, Sat Feb 7 19:00:05 2026 # include "/usr/share/themes/Breeze/gtk-2.0/gtkrc" diff --git a/.config/gtkrc-2.0 b/.config/gtkrc-2.0 index 03d096b..f96f12d 100644 --- a/.config/gtkrc-2.0 +++ b/.config/gtkrc-2.0 @@ -1,4 +1,4 @@ -# created by KDE Plasma, Tue Dec 16 00:23:11 2025 +# created by KDE Plasma, Sat Feb 7 19:00:05 2026 # gtk-alternative-button-order = 1 diff --git a/.config/gwenviewrc b/.config/gwenviewrc index e62ab24..fb1fcbe 100644 --- a/.config/gwenviewrc +++ b/.config/gwenviewrc @@ -1,22 +1,33 @@ [General] LastUsedVersion=210800 +SideBarPage=operations [MainWindow] MenuBar=Disabled [Recent Files] -File1[$e]=$HOME/.local/share/Steam/steamapps/common/Half-Life/valve/models/player/gordon/gordon.bmp -File2[$e]=$HOME/Downloads/IMG_2205.jpg -File3[$e]=$HOME/Documents/krita/dbd2025/dbd2025.png -File4[$e]=$HOME/Documents/Blender/paper-boat.png -File5[$e]=mtp:/HD1901/Internal shared storage/DCIM/Snapchat/Snapchat-1004382467.mp4 -File6[$e]=$HOME/Desktop/phone-backup/Pictures/.gs_fs0/.5.jpg -Name1[$e]=gordon.bmp -Name2[$e]=IMG_2205.jpg -Name3[$e]=dbd2025.png -Name4[$e]=paper-boat.png -Name5[$e]=Snapchat-1004382467.mp4 -Name6[$e]=.5.jpg +File1[$e]=$HOME/Downloads/TG-63-19-1.jpg +File10[$e]=$HOME/Downloads/download20260101180443.png +File2[$e]=$HOME/Documents/Krita/mbd2026/mbd2026.png +File3[$e]=$HOME/Desktop/Ubunchu/cover.jpg +File4[$e]=$HOME/Pictures/Endfield/ENDFIELD_SHARE_1769117324.png +File5[$e]=$HOME/Desktop/preview.gif +File6[$e]=$HOME/Desktop/wp5746605.jpg +File7[$e]=$HOME/Desktop/2601189.jpg +File8[$e]=$HOME/Desktop/wp8254196-yellow-clouds-wallpapers.jpg +File9[$e]=$HOME/Downloads/download20260101171035.png +Name1[$e]=TG-63-19-1.jpg +Name10[$e]=download20260101180443.png +Name2[$e]=mbd2026.png +Name3[$e]=cover.jpg +Name4[$e]=ENDFIELD_SHARE_1769117324.png +Name5[$e]=preview.gif +Name6[$e]=wp5746605.jpg +Name7[$e]=2601189.jpg +Name8[$e]=wp8254196-yellow-clouds-wallpapers.jpg +Name9[$e]=download20260101171035.png [SideBar] -InformationSplitterSizes=211,244 +InformationSplitterSizes=220,255 +IsVisible ViewMode=true +SideBarSplitterSizes=213,610 diff --git a/.config/kactivitymanagerd-statsrc b/.config/kactivitymanagerd-statsrc index 48f3657..9a46254 100644 --- a/.config/kactivitymanagerd-statsrc +++ b/.config/kactivitymanagerd-statsrc @@ -3,3 +3,15 @@ ordering=preferred://browser,applications:systemsettings.desktop,applications:or [Favorites-org.kde.plasma.kickoff.favorites.instance-3-global] ordering=preferred://browser,applications:systemsettings.desktop,applications:org.kde.dolphin.desktop,applications:org.kde.konsole.desktop,applications:org.kde.discover.desktop,applications:org.kde.plasma-systemmonitor.desktop,applications:org.kde.kate.desktop + +[Favorites-org.kde.plasma.kickoff.favorites.instance-33-dc7cfc1e-da2d-4ff2-977f-a1a4449080f6] +ordering=applications:com.usebottles.bottles.desktop,applications:org.kde.discover.desktop,applications:org.kde.dolphin.desktop,applications:org.kde.kate.desktop,applications:org.kde.konsole.desktop,applications:org.kde.plasma-systemmonitor.desktop,applications:systemsettings.desktop,preferred://browser,applications:org.kde.korganizer.desktop,applications:org.kde.kdeconnect.app.desktop,applications:com.heroicgameslauncher.hgl.desktop + +[Favorites-org.kde.plasma.kickoff.favorites.instance-33-global] +ordering=applications:com.usebottles.bottles.desktop,applications:org.kde.discover.desktop,applications:org.kde.dolphin.desktop,applications:org.kde.kate.desktop,applications:org.kde.konsole.desktop,applications:org.kde.plasma-systemmonitor.desktop,applications:systemsettings.desktop,preferred://browser,applications:org.kde.korganizer.desktop,applications:org.kde.kdeconnect.app.desktop,applications:com.heroicgameslauncher.hgl.desktop + +[Favorites-org.kde.plasma.kickoff.favorites.instance-39-dc7cfc1e-da2d-4ff2-977f-a1a4449080f6] +ordering=applications:com.usebottles.bottles.desktop,applications:org.kde.discover.desktop,applications:org.kde.dolphin.desktop,applications:org.kde.kate.desktop,applications:org.kde.plasma-systemmonitor.desktop,applications:systemsettings.desktop,preferred://browser,applications:org.kde.korganizer.desktop,applications:org.kde.kdeconnect.app.desktop,applications:com.heroicgameslauncher.hgl.desktop + +[Favorites-org.kde.plasma.kickoff.favorites.instance-39-global] +ordering=applications:com.usebottles.bottles.desktop,applications:org.kde.discover.desktop,applications:org.kde.dolphin.desktop,applications:org.kde.kate.desktop,applications:org.kde.plasma-systemmonitor.desktop,applications:systemsettings.desktop,preferred://browser,applications:org.kde.korganizer.desktop,applications:org.kde.kdeconnect.app.desktop,applications:com.heroicgameslauncher.hgl.desktop diff --git a/.config/kactivitymanagerdrc b/.config/kactivitymanagerdrc index 52bb8b1..ba1238d 100644 --- a/.config/kactivitymanagerdrc +++ b/.config/kactivitymanagerdrc @@ -1,5 +1,9 @@ [activities] +18f515e7-cf8b-4327-80ee-9f74afa20678=Work dc7cfc1e-da2d-4ff2-977f-a1a4449080f6=Default +[activities-icons] +18f515e7-cf8b-4327-80ee-9f74afa20678=preferences-system-network-ldap + [main] currentActivity=dc7cfc1e-da2d-4ff2-977f-a1a4449080f6 diff --git a/.config/katerc b/.config/katerc index 6b797d7..606a3a3 100644 --- a/.config/katerc +++ b/.config/katerc @@ -1,7 +1,14 @@ +[BuildConfig] +AllowedCommandLines= +AutoSwitchToOutput=true +BlockedCommandLines= +ShowBuildProgress=false +UseDiagnosticsOutput=true + [General] Allow Tab Scrolling=true Auto Hide Tabs=false -Close After Last=false +Close After Last=true Close documents with window=true Cycle To First Tab=true Days Meta Infos=30 @@ -17,6 +24,8 @@ Mouse forward button action=0 Open New Tab To The Right Of Current=false Output History Limit=100 Output With Date=false +Quickopen Filter Mode=0 +Quickopen List Mode=true Recent File List Entry Count=10 Restore Window Configuration=true SDI Mode=false @@ -26,7 +35,7 @@ Show Menu Bar=true Show Status Bar=true Show Symbol In Navigation Bar=true Show Tab Bar=true -Show Tabs Close Button=true +Show Tabs Close Button=false Show Url Nav Bar=true Show output view for message type=1 Show text for left and right sidebar=false @@ -83,8 +92,8 @@ Word Wrap Column=80 [KTextEditor Renderer] Animate Bracket Matching=false -Auto Color Theme Selection=true -Color Theme=Breeze Light +Auto Color Theme Selection=false +Color Theme=gruvbox Light Line Height Multiplier=1 Show Indentation Lines=false Show Whole Bracket Expression=false @@ -148,7 +157,7 @@ Smart Copy Cut=true Statusbar Line Column Compact Mode=true Text Drag And Drop=true User Sets Of Chars To Enclose Selection= -Vi Input Mode Steal Keys=false +Vi Input Mode Steal Keys=true Vi Relative Line Numbers=false Word Completion=true Word Completion Minimal Word Length=3 @@ -163,8 +172,16 @@ RunPrefix= SetEditor=false [MainWindow] -2560x1440 screen: Height=601 -2560x1440 screen: Width=759 +2560x1440 screen: Height=912 +2560x1440 screen: Width=1284 + +[Shortcuts] +kate_mdi_focus_toolview_kate_plugin_katebuildplugin=;\s +kate_mdi_focus_toolview_kateprojectinfo=Alt+. +kate_mdi_toolview_kate_plugin_katebuildplugin=Alt+? + +[UiSettings] +ColorScheme=Krita dark [filetree] editShade=48,203,229 @@ -178,7 +195,7 @@ sortRole=0 viewShade=162,201,252 [lspclient] -AllowedServerCommandLines= +AllowedServerCommandLines=/snap/bin/marksman server,/usr/bin/rust-analyzer AutoHover=true AutoImport=true BlockedServerCommandLines= diff --git a/.config/katevirc b/.config/katevirc index 2b67f52..68b306c 100644 --- a/.config/katevirc +++ b/.config/katevirc @@ -12,8 +12,8 @@ Map Leader=\\ Normal Mode Mapping Keys= Normal Mode Mappings= Normal Mode Mappings Recursion= -ViRegisterContents=something Im curious about or looking forward to\n\n,o, -ViRegisterFlags=1,0,0 +ViRegisterContents=,, +ViRegisterFlags=0,0,0 ViRegisterNames=",-,^ Visual Mode Mapping Keys= Visual Mode Mappings= diff --git a/.config/kde.org/UserFeedback.org.kde.discover.conf b/.config/kde.org/UserFeedback.org.kde.discover.conf index cad73d3..dbc1cfe 100644 --- a/.config/kde.org/UserFeedback.org.kde.discover.conf +++ b/.config/kde.org/UserFeedback.org.kde.discover.conf @@ -26,5 +26,6 @@ dataSourceCommonSettings\activeState=true dataSourceCommonSettings\activeState=true [UserFeedback] -ApplicationStartCount=40 -ApplicationTime=39717 +ApplicationStartCount=143 +ApplicationTime=192245 +LastEncouragement=@DateTime(\0\0\0\x10\0\0\0\0\0\0%\x8d\x8b\x2w/\x18\0) diff --git a/.config/kde.org/UserFeedback.org.kde.dolphin.conf b/.config/kde.org/UserFeedback.org.kde.dolphin.conf index 7bfd684..25eb217 100644 --- a/.config/kde.org/UserFeedback.org.kde.dolphin.conf +++ b/.config/kde.org/UserFeedback.org.kde.dolphin.conf @@ -26,5 +26,5 @@ dataSourceCommonSettings\activeState=true dataSourceCommonSettings\activeState=true [UserFeedback] -ApplicationStartCount=52 -ApplicationTime=120089 +ApplicationStartCount=367 +ApplicationTime=1033838 diff --git a/.config/kde.org/UserFeedback.org.kde.kate.conf b/.config/kde.org/UserFeedback.org.kde.kate.conf index 0bce88a..4f59a28 100644 --- a/.config/kde.org/UserFeedback.org.kde.kate.conf +++ b/.config/kde.org/UserFeedback.org.kde.kate.conf @@ -17,5 +17,5 @@ dataSourceCommonSettings\activeState=true dataSourceCommonSettings\activeState=true [UserFeedback] -ApplicationStartCount=12 -ApplicationTime=14164 +ApplicationStartCount=78 +ApplicationTime=93025 diff --git a/.config/kde.org/UserFeedback.org.kde.korganizer.conf b/.config/kde.org/UserFeedback.org.kde.korganizer.conf new file mode 100644 index 0000000..0541547 --- /dev/null +++ b/.config/kde.org/UserFeedback.org.kde.korganizer.conf @@ -0,0 +1,24 @@ +[Source-applicationVersion] +dataSourceCommonSettings\activeState=true + +[Source-locale] +dataSourceCommonSettings\activeState=true + +[Source-platform] +dataSourceCommonSettings\activeState=true + +[Source-qtVersion] +dataSourceCommonSettings\activeState=true + +[Source-screens] +dataSourceCommonSettings\activeState=true + +[Source-startCount] +dataSourceCommonSettings\activeState=true + +[Source-usageTime] +dataSourceCommonSettings\activeState=true + +[UserFeedback] +ApplicationStartCount=2 +ApplicationTime=147 diff --git a/.config/kde.org/UserFeedback.org.kde.kwrite.conf b/.config/kde.org/UserFeedback.org.kde.kwrite.conf new file mode 100644 index 0000000..f781261 --- /dev/null +++ b/.config/kde.org/UserFeedback.org.kde.kwrite.conf @@ -0,0 +1,21 @@ +[Source-applicationVersion] +dataSourceCommonSettings\activeState=true + +[Source-platform] +dataSourceCommonSettings\activeState=true + +[Source-qtVersion] +dataSourceCommonSettings\activeState=true + +[Source-screens] +dataSourceCommonSettings\activeState=true + +[Source-startCount] +dataSourceCommonSettings\activeState=true + +[Source-usageTime] +dataSourceCommonSettings\activeState=true + +[UserFeedback] +ApplicationStartCount=31 +ApplicationTime=6613 diff --git a/.config/kde.org/UserFeedback.org.kde.plasmashell.conf b/.config/kde.org/UserFeedback.org.kde.plasmashell.conf index 4d872e6..b83a057 100644 --- a/.config/kde.org/UserFeedback.org.kde.plasmashell.conf +++ b/.config/kde.org/UserFeedback.org.kde.plasmashell.conf @@ -26,5 +26,5 @@ dataSourceCommonSettings\activeState=true dataSourceCommonSettings\activeState=true [UserFeedback] -ApplicationStartCount=10 -ApplicationTime=265163 +ApplicationStartCount=113 +ApplicationTime=2352883 diff --git a/.config/kdeconnect/config b/.config/kdeconnect/config index b463081..6240e9b 100644 --- a/.config/kdeconnect/config +++ b/.config/kdeconnect/config @@ -1,3 +1,3 @@ [General] keyAlgorithm=EC -name=fedora +name=kubuntu diff --git a/.config/kdeconnect/trusted_devices b/.config/kdeconnect/trusted_devices index e229b93..7fc50a7 100644 --- a/.config/kdeconnect/trusted_devices +++ b/.config/kdeconnect/trusted_devices @@ -1,11 +1,5 @@ -[67985dbaf5484787a8f69626d4f8b113] -certificate=-----BEGIN CERTIFICATE-----\nMIIBizCCATGgAwIBAgIBATAKBggqhkjOPQQDBDBPMSkwJwYDVQQDDCA2Nzk4NWRi\nYWY1NDg0Nzg3YThmNjk2MjZkNGY4YjExMzEUMBIGA1UECwwLS0RFIENvbm5lY3Qx\nDDAKBgNVBAoMA0tERTAeFw0yNDEyMTUwNjAwMDBaFw0zNTEyMTUwNjAwMDBaME8x\nKTAnBgNVBAMMIDY3OTg1ZGJhZjU0ODQ3ODdhOGY2OTYyNmQ0ZjhiMTEzMRQwEgYD\nVQQLDAtLREUgQ29ubmVjdDEMMAoGA1UECgwDS0RFMFkwEwYHKoZIzj0CAQYIKoZI\nzj0DAQcDQgAE/rbwC0RnwSFOl0BKPVJEkx4rJHT9h/ih5I8ZGze9kMwB64H7fS95\nIiQd+XNpbaorAp1l1sRJOffRP31aKOi7+zAKBggqhkjOPQQDBANIADBFAiEAi6ae\ngHauXc5pfTXhEj9QQHgI2f+vlO3OMFdjzhV+uD8CIAXtndsCQ+512VbXEkUa4kzR\nCyiLOI1Vg+LIkrOpvg7G\n-----END CERTIFICATE-----\n -name=OnePlus 7T -protocolVersion=8 -type=phone - -[eb546ffd_efc1_48f1_929c_a3b2d918522c] -certificate="-----BEGIN CERTIFICATE-----\nMIIBkjCCATmgAwIBAgIBATAKBggqhkjOPQQDBDBTMS0wKwYDVQQDDCRlYjU0NmZm\nZF9lZmMxXzQ4ZjFfOTI5Y19hM2IyZDkxODUyMmMxFDASBgNVBAsMC0tERSBDb25u\nZWN0MQwwCgYDVQQKDANLREUwHhcNMjMxMjA1MDYwMDAwWhcNMzQxMjA1MDYwMDAw\nWjBTMS0wKwYDVQQDDCRlYjU0NmZmZF9lZmMxXzQ4ZjFfOTI5Y19hM2IyZDkxODUy\nMmMxFDASBgNVBAsMC0tERSBDb25uZWN0MQwwCgYDVQQKDANLREUwWTATBgcqhkjO\nPQIBBggqhkjOPQMBBwNCAAQop70yLtqkhYvdpvfo7jDibnO3gfSuj9CXZDpLc0i0\niC36+aMnSSeT7iRWTFxu1nyvWaHPWjJ2N7kwpvTHdANRMAoGCCqGSM49BAMEA0cA\nMEQCIB5aczt2NA5Dy9W6fWym4eJ/OLAB5BQFvD7Oa0OmwZcDAiBLHdcXA9iqEFwG\nDTKzrnh+koKomXCHooGkbbjdpmfMUA==\n-----END CERTIFICATE-----\n" +[48596f5997c34d2db1af4e7c7c1ae4ab] +certificate="-----BEGIN CERTIFICATE-----\nMIIBjDCCATGgAwIBAgIBATAKBggqhkjOPQQDBDBPMSkwJwYDVQQDDCA0ODU5NmY1\nOTk3YzM0ZDJkYjFhZjRlN2M3YzFhZTRhYjEUMBIGA1UECwwLS0RFIENvbm5lY3Qx\nDDAKBgNVBAoMA0tERTAeFw0yNDEyMjIwNjAwMDBaFw0zNTEyMjIwNjAwMDBaME8x\nKTAnBgNVBAMMIDQ4NTk2ZjU5OTdjMzRkMmRiMWFmNGU3YzdjMWFlNGFiMRQwEgYD\nVQQLDAtLREUgQ29ubmVjdDEMMAoGA1UECgwDS0RFMFkwEwYHKoZIzj0CAQYIKoZI\nzj0DAQcDQgAEeCv5ADYuy0Ai1iXD7qlcT9Afa9Ky//Qtsnc7b0Xsd36eqX/o2/Se\nX9bAFzWSfPhck1X+I/sr57nGKTZDUO1bizAKBggqhkjOPQQDBANJADBGAiEAzK7W\nsgKQmSxyHHYhKmC5tQqGmxb0feYXiKH5qk4cUW0CIQDfkcjA/PtREzHDd/pJ3x89\nPrTmmdfjuY0Smd+tF3jTzw==\n-----END CERTIFICATE-----\n" name=OnePlus 7T protocolVersion=8 type=phone diff --git a/.config/kded5rc b/.config/kded5rc index a005860..3f445e1 100644 --- a/.config/kded5rc +++ b/.config/kded5rc @@ -1,2 +1,5 @@ +[Module-browserintegrationreminder] +autoload=false + [Module-device_automounter] autoload=false diff --git a/.config/kdedefaults/kdeglobals b/.config/kdedefaults/kdeglobals index 4cf0f75..5bdede9 100644 --- a/.config/kdedefaults/kdeglobals +++ b/.config/kdedefaults/kdeglobals @@ -1,8 +1,8 @@ [General] -ColorScheme=LeafLight +ColorScheme=BreezeDark [Icons] -Theme=breeze +Theme=breeze-dark [KDE] widgetStyle=Breeze diff --git a/.config/kdedefaults/ksplashrc b/.config/kdedefaults/ksplashrc index 6f69bc8..56a8fb1 100644 --- a/.config/kdedefaults/ksplashrc +++ b/.config/kdedefaults/ksplashrc @@ -1,3 +1,3 @@ [KSplash] Engine=KSplashQML -Theme=org.kde.breeze.desktop +Theme=org.kde.breezedark.desktop diff --git a/.config/kdedefaults/package b/.config/kdedefaults/package index bceddbc..c188391 100644 --- a/.config/kdedefaults/package +++ b/.config/kdedefaults/package @@ -1 +1 @@ -org.kde.breeze.desktop \ No newline at end of file +org.kde.breezedark.desktop \ No newline at end of file diff --git a/.config/kdeglobals b/.config/kdeglobals index 3abed50..2f123ba 100644 --- a/.config/kdeglobals +++ b/.config/kdeglobals @@ -44,10 +44,37 @@ ForegroundInactive=166,172,186 ForegroundLink=0,149,179 ForegroundNegative=218,68,83 ForegroundNeutral=255,255,127 +ForegroundNormal[$d] ForegroundPositive=0,170,127 +ForegroundVisited[$d] [Colors:Header] BackgroundAlternate=211,214,206 +BackgroundNormal[$d] +DecorationFocus[$d] +DecorationHover[$d] +ForegroundActive[$d] +ForegroundInactive[$d] +ForegroundLink[$d] +ForegroundNegative[$d] +ForegroundNeutral[$d] +ForegroundNormal[$d] +ForegroundPositive[$d] +ForegroundVisited[$d] + +[Colors:Header][Inactive] +BackgroundAlternate[$d] +BackgroundNormal[$d] +DecorationFocus[$d] +DecorationHover[$d] +ForegroundActive[$d] +ForegroundInactive[$d] +ForegroundLink[$d] +ForegroundNegative[$d] +ForegroundNeutral[$d] +ForegroundNormal[$d] +ForegroundPositive[$d] +ForegroundVisited[$d] [Colors:Selection] BackgroundAlternate=128,175,136 @@ -106,21 +133,30 @@ ForegroundPositive=114,155,121 ForegroundVisited=61,111,171 [DirSelect Dialog] -DirSelectDialog Size=1280,720 -History Items[$e]=file:$HOME/Games/Mod-Profiles/Morrowind,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Programs/nsui,file:$HOME/.bottles,file:$HOME/.bottles,file:$HOME/Games/Roms/GBA,file:$HOME/Music,file:///mnt,file:$HOME,file:///media/cory/5d17c3cd-cd6b-4207-be1f-be40d0a86e2b/home-backups,file:$HOME/Desktop/test,file:///media/cory/5d17c3cd-cd6b-4207-be1f-be40d0a86e2b +DirSelectDialog Size=1514,975 +History Items[$e]=file:$HOME/Games/Heroic/Prefixes/default/Fallout 3 Game of the Year Edition/drive_c/users/cory/Documents/My Games/Fallout3,file:$HOME/Games/Mod-Profiles/F3,file:$HOME/Games/Heroic/Fallout 3,file:$HOME/Games/Heroic/Fallout 3/Data,file:$HOME/Games/Heroic/Fallout 3,file:$HOME/Games/sse-mo2,file:$HOME/.config/VintagestoryData,file:$HOME/.local/share/Steam/steamapps/compatdata/4026215239/pfx/drive_c/Program Files/Punishing Gray Raven,file:$HOME/.local/share/Steam/steamapps/compatdata/4195709487/pfx/drive_c/users/steamuser/Pictures/ENDFIELD,file:$HOME/.local/share/Steam/steamapps/common,file:$HOME/Games/Mod-Profiles/Undertale,file:$HOME/Games/PGR,file:$HOME/Games/PGR,file:$HOME/Games/Mod-Profiles/FF7,file:$HOME/Games/Mod-Profiles/FNV,file:$HOME/Projects/Renpy,file:$HOME/Games/Mod-Profiles/MHW,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/RE2,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE-MO2,file:$HOME/Games/Mod-Profiles/7thDeck,file:///media/cory/KOBOeReader,file:$HOME/Books,file:$HOME/Desktop/test-proj,file:$HOME/Games/Mod-Profiles/FF7,file:$HOME/Documents/ludusavi-backup,file:$HOME/Games/Mod-Profiles/SSE-MO2,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/RE4,file:$HOME/Games/Mod-Profiles/MHW,file:$HOME/.local/share/Steam/steamapps/compatdata/489830/pfx/drive_c/users/steamuser/Documents/My Games/Skyrim Special Edition,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/Games/Mod-Profiles/SSE/35,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/Games/Mod-Profiles/SSE1,file:$HOME/Games/Mod-Profiles/SSE1,file:$HOME/Games/Mod-Profiles/SSE1,file:$HOME/Games/Mod-Profiles/SSE1,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/.local/share/Steam/steamapps/common/Skyrim Special Edition/Data,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE,file:$HOME/Games/Mod-Profiles/SSE1,file:$HOME/Games/Mod-Profiles/SSE Splitter State=\x00\x00\x00\xff\x00\x00\x00\x01\x00\x00\x00\x02\x00\x00\x00\xb0\x00\x00\x02\x81\x00\xff\xff\xff\xff\x01\x00\x00\x00\x01\x00 [General] +AccentColor=0,0,0,0 +ColorScheme=LeafLight ColorSchemeHash=3c1fe2294ac4de052dbb549c48aa4c026ce1610c +LastUsedCustomAccentColor=61,174,233 UseSystemBell=true +accentColorFromWallpaper=false + +[Icons] +Theme=breeze [KDE] -LookAndFeelPackage=org.kde.breeze.desktop +LookAndFeelPackage=org.kde.breezedark.desktop +ShowDeleteCommand=false +widgetStyle=Breeze [KFileDialog Settings] Allow Expansion=false Automatically select filename extension=true -Breadcrumb Navigation=true +Breadcrumb Navigation=false Decoration position=2 LocationCombo Completionmode=5 PathCombo Completionmode=5 @@ -134,12 +170,16 @@ Sort by=Name Sort directories first=true Sort hidden files last=false Sort reversed=false -Speedbar Width=140 +Speedbar Width=158 View Style=DetailTree [KShortcutsDialog Settings] Dialog Size=1199,890 +[PreviewSettings] +EnableRemoteFolderThumbnail=false +MaximumRemoteSize=0 + [WM] activeBackground=225,228,220 activeBlend=225,228,220 diff --git a/.config/kglobalshortcutsrc b/.config/kglobalshortcutsrc index f44cc6d..b77d3d4 100644 --- a/.config/kglobalshortcutsrc +++ b/.config/kglobalshortcutsrc @@ -1,5 +1,6 @@ [ActivityManager] _k_friendly_name=Activity Manager +switch-to-activity-18f515e7-cf8b-4327-80ee-9f74afa20678=none,none,Switch to activity "Work" switch-to-activity-dc7cfc1e-da2d-4ff2-977f-a1a4449080f6=none,none,Switch to activity "Default" [KDE Keyboard Layout Switcher] @@ -102,6 +103,7 @@ Switch to Screen to the Left=none,,Switch to Screen to the Left Switch to Screen to the Right=none,,Switch to Screen to the Right Toggle Night Color=none,none,Suspend/Resume Night Light Toggle Window Raise/Lower=none,,Toggle Window Raise/Lower +ToggleMouseClick=Meta+*,Meta+*,Toggle Mouse Click Animation Walk Through Windows=Meta+Tab\tAlt+Tab,Meta+Tab\tAlt+Tab,Walk Through Windows Walk Through Windows (Reverse)=Meta+Shift+Tab\tAlt+Shift+Tab,Meta+Shift+Tab\tAlt+Shift+Tab,Walk Through Windows (Reverse) Walk Through Windows Alternative=none,none,Walk Through Windows Alternative @@ -117,7 +119,7 @@ Window Custom Quick Tile Bottom=none,,Custom Quick Tile Window to the Bottom Window Custom Quick Tile Left=none,,Custom Quick Tile Window to the Left Window Custom Quick Tile Right=none,,Custom Quick Tile Window to the Right Window Custom Quick Tile Top=none,,Custom Quick Tile Window to the Top -Window Fullscreen=none,,Make Window Fullscreen +Window Fullscreen=Alt+Return,,Make Window Fullscreen Window Grow Horizontal=none,,Expand Window Horizontally Window Grow Vertical=none,,Expand Window Vertically Window Lower=none,,Lower Window @@ -234,7 +236,7 @@ activate task manager entry 6=Meta+6,Meta+6,Activate Task Manager Entry 6 activate task manager entry 7=Meta+7,Meta+7,Activate Task Manager Entry 7 activate task manager entry 8=Meta+8,Meta+8,Activate Task Manager Entry 8 activate task manager entry 9=Meta+9,Meta+9,Activate Task Manager Entry 9 -activate widget 33=,none,Activate Application Launcher Widget +activate widget 35=none,none,Activate Application Launcher Widget clear-history=none,,Clear Clipboard History clipboard_action=Meta+Ctrl+X,Meta+Ctrl+X,Automatic Action Popup Menu cycle-panels=Meta+Alt+P,Meta+Alt+P,Move keyboard focus between panels @@ -254,7 +256,13 @@ switch to previous activity=none,,Switch to Previous Activity toggle do not disturb=none,,Toggle do not disturb [services][com.mitchellh.ghostty.desktop] -_launch=none +_launch=Alt+T + +[services][kitty.desktop] +_launch=Alt+T + +[services][neovide.desktop] +_launch=Meta+N [services][net.local.disconnect-xboxcon.sh.desktop] _launch=Meta+Ctrl+Alt+Shift+X @@ -282,3 +290,6 @@ _launch=Meta+Ctrl+Alt+$ [services][net.local.python3.desktop] _launch=Meta+Ctrl+Alt+! + +[services][org.kde.konsole.desktop] +NewWindow=Alt+T diff --git a/.config/kiorc b/.config/kiorc index 5865ac0..562c9ad 100644 --- a/.config/kiorc +++ b/.config/kiorc @@ -1,6 +1,7 @@ [Confirmations] ConfirmDelete=true ConfirmEmptyTrash=true +ConfirmTrash=false [Executable scripts] behaviourOnLaunch=execute diff --git a/.config/kitty/current-theme.conf b/.config/kitty/current-theme.conf index fa60335..cda16f7 100644 --- a/.config/kitty/current-theme.conf +++ b/.config/kitty/current-theme.conf @@ -1,40 +1,40 @@ # vim:ft=kitty -## name: Everforest Light Hard +## name: Everforest Light Medium ## author: Sainnhe Park ## license: MIT -## upstream: https://github.com/ewal/kitty-everforest/blob/master/themes/everforest_light_hard.conf +## upstream: https://github.com/ewal/kitty-everforest/blob/master/themes/everforest_light_medium.conf ## blurb: A green based color scheme designed to be warm and soft foreground #5c6a72 -background #fffbef +background #fdf6e3 selection_foreground #829181 -selection_background #f0f2d4 +selection_background #eaedc8 cursor #5c6a72 -cursor_text_color #f8f5e4 +cursor_text_color #f4f0d9 url_color #3a94c5 active_border_color #8da101 -inactive_border_color #bec5b2 +inactive_border_color #bdc3af bell_border_color #f57d26 visual_bell_color none wayland_titlebar_color system macos_titlebar_color system -active_tab_background #fffbef +active_tab_background #fdf6e3 active_tab_foreground #5c6a72 -inactive_tab_background #f2efdf +inactive_tab_background #fdf6e3 inactive_tab_foreground #939f91 -tab_bar_background #f8f5e4 +tab_bar_background #fdf6e3 tab_bar_margin_color none -mark1_foreground #fffbef +mark1_foreground #fdf6e3 mark1_background #3a94c5 -mark2_foreground #fffbef +mark2_foreground #fdf6e3 mark2_background #d3c6aa -mark3_foreground #fffbef +mark3_foreground #fdf6e3 mark3_background #df69ba #: black diff --git a/.config/kitty/dank-tabs.conf b/.config/kitty/dank-tabs.conf new file mode 100644 index 0000000..576b0e7 --- /dev/null +++ b/.config/kitty/dank-tabs.conf @@ -0,0 +1,23 @@ +tab_bar_edge top +tab_bar_style powerline +tab_powerline_style slanted +tab_bar_align left +tab_bar_min_tabs 2 +tab_bar_margin_width 0.0 +tab_bar_margin_height 2.5 1.5 +tab_bar_margin_color #141218 + +tab_bar_background #141218 + +active_tab_foreground #381e72 +active_tab_background #d0bcff +active_tab_font_style bold + +inactive_tab_foreground #cac4cf +inactive_tab_background #141218 +inactive_tab_font_style normal + +tab_activity_symbol " ● " + +tab_title_template "{fmt.fg.red}{bell_symbol}{activity_symbol}{fmt.fg.tab}{title[:30]}{title[30:] and '…'} [{index}]" +active_tab_title_template "{fmt.fg.red}{bell_symbol}{activity_symbol}{fmt.fg.tab}{title[:30]}{title[30:] and '…'} [{index}]" diff --git a/.config/kitty/dank-theme.conf b/.config/kitty/dank-theme.conf new file mode 100644 index 0000000..659f5f2 --- /dev/null +++ b/.config/kitty/dank-theme.conf @@ -0,0 +1,25 @@ +cursor #e6e0e9 +cursor_text_color #cac4cf + +foreground #e6e0e9 +background #141218 +selection_foreground #381e72 +selection_background #ccc2dc +url_color #d0bcff + +color0 #141218 +color1 #df5141 +color2 #6ed675 +color3 #dbd97b +color4 #926ce2 +color5 #a397bf +color6 #D0BCFF +color7 #abb2bf +color8 #5c6370 +color9 #e06a5f +color10 #86e08b +color11 #e8e697 +color12 #dfc9ff +color13 #7c6acd +color14 #8b6ab5 +color15 #ffffff diff --git a/.config/kitty/kitty.conf b/.config/kitty/kitty.conf index a8f20e9..6dda989 100644 --- a/.config/kitty/kitty.conf +++ b/.config/kitty/kitty.conf @@ -1,17 +1,18 @@ # vim:fileencoding=utf-8:foldmethod=marker -background_opacity 1 +background_opacity 0.05 +background_blur 1 font_family CaskaydiaMonoNerdFont font_size 16 shell /usr/bin/fish cursor_trail 3 cursor_trail_decay 0.1 0.25 dynamic_background_opacity true -map f11 kitten focus_mode.py +# map f11 kitten focus_mode.py # BEGIN_KITTY_THEME -# Everforest Light Hard +# Everforest Light Medium include current-theme.conf # END_KITTY_THEME diff --git a/.config/kitty/kitty.conf.bak b/.config/kitty/kitty.conf.bak index 853120d..1488df2 100644 --- a/.config/kitty/kitty.conf.bak +++ b/.config/kitty/kitty.conf.bak @@ -1,11 +1,18 @@ # vim:fileencoding=utf-8:foldmethod=marker -background_opacity 0.85 -font_size 14 +background_opacity 0.3 +background_blur 1 +font_family CaskaydiaMonoNerdFont +font_size 16 shell /usr/bin/fish cursor_trail 3 +cursor_trail_decay 0.1 0.25 +dynamic_background_opacity true +# map f11 kitten focus_mode.py + + # BEGIN_KITTY_THEME -# Everforest Light Medium +# Everforest Dark Soft include current-theme.conf # END_KITTY_THEME diff --git a/.config/kritarc b/.config/kritarc index f02d2c6..d4627e5 100644 --- a/.config/kritarc +++ b/.config/kritarc @@ -1,13 +1,13 @@ AlsoSaveAsKra=false ArtColorSel.ColorSpace=0 ArtColorSel.InversedSaturation=false -ArtColorSel.Light=0 +ArtColorSel.Light=0.5191804866243429 ArtColorSel.LightPieces=11 ArtColorSel.NumRings=7 ArtColorSel.RingPieces=12 -ArtColorSel.SelColorH=0 -ArtColorSel.SelColorS=0 -ArtColorSel.SelColorX=0 +ArtColorSel.SelColorH=0.5965637989874973 +ArtColorSel.SelColorS=0.9923312024516796 +ArtColorSel.SelColorX=0.5191804866243429 ArtColorSel.defaultHueSteps=12 ArtColorSel.defaultSaturationSteps=7 ArtColorSel.defaultValueScaleSteps=11 @@ -22,7 +22,9 @@ BackgroundColorForNewImage=255,255,255 BackgroundOpacityForNewImage=255 BackgroundStyleForNewImage=0 CanvasOnlyActive=false -ExportConfiguration-image/png=\n\n true\n 3\n false\n true\n false\n false\n false\n false\n false\n false\n \n\n \n\n]]>\n\n +ExportConfiguration-image/jpeg=\n\n true\n true\n \n false\n true\n true\n false\n 80\n true\n 0\n false\n false\n 0\n \n\n \n\n]]>\n true\n\n +ExportConfiguration-image/png=\n\n true\n 3\n false\n true\n false\n false\n false\n false\n false\n false\n \n\n \n\n]]>\n\n +FilterSelector/LastUsedFilter=colortoalpha GamutMasks.viewMode=0 Krita/Ocio/DisplayDevice=sRGB Krita/Ocio/DisplayLook=None @@ -33,10 +35,10 @@ Krita/Ocio/OcioConfigPath= Krita/Ocio/OcioLockColorVisualRepresentation=false Krita/Ocio/OcioLutPath= Krita/Ocio/UseOcio=false -LastBackGroundColor=\n\n \n\n -LastForeGroundColor=\n\n \n\n -LastPreset=u) Pixel Art -LastPreset_-1=u) Pixel Art +LastBackGroundColor=\n\n \n\n +LastForeGroundColor=\n\n \n\n +LastPreset=b) Basic-5 Size +LastPreset_-1=b) Basic-5 Size LineSmoothingDelayDistance=50 LineSmoothingDistance=50 LineSmoothingFinishStabilizedCurve=true @@ -47,6 +49,7 @@ LineSmoothingTailAggressiveness=0.15 LineSmoothingType=1 LineSmoothingUseDelayDistance=true NumberOfLayersForNewImage=2 +PinnedFonts=URW Bookman [urw],Ubuntu,Trebuchet MS,Times New Roman,Serif SpecificColorSelector/HsxMode=0 SpecificColorSelector/UseHsx=false SpecificColorSelector/UsePercentage=false @@ -57,6 +60,8 @@ colorDepthDef=U8 colorModelDef=RGBA colorProfileDef=sRGB-elle-V2-srgbtrc.icc defaultPalette=Default +filterdialog/geometry=\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x01\xde\x00\x00\x01\xea\x00\x00\x04\x0c\x00\x00\x03~\x00\x00\x01\xdf\x00\x00\x02\x06\x00\x00\x04\x0b\x00\x00\x03}\x00\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x01\xdf\x00\x00\x02\x06\x00\x00\x04\x0b\x00\x00\x03} +filterdialog/rememberlastpreset=false globalSnapBoundingBox=false globalSnapExtension=false globalSnapImageBounds=true @@ -71,9 +76,9 @@ gridsubdivisioncolor=150,150,150 gridsubdivisionstyle=1 guidesColor=99,99,99 guidesLineStyle=0 -imageHeightDef=200 +imageHeightDef=2000 imageResolutionDef=300 -imageWidthDef=200 +imageWidthDef=2000 levelOfDetailEnabled=false logviewer_enabled=false moveToolUnit=0 @@ -124,9 +129,10 @@ onionSkinState_9=false onionSkinTintColorBackward=255,0,0 onionSkinTintFactor=191 preferredVectorImportResolution=100 -presethistory=b) Basic-5 Size Opacity,b) Airbrush Soft,x) Filter Blur,x) Filter Sharpen,b) Basic-1,u) Pixel Art,u) Pixel Art Fill +presethistory=f) Bristles-4 Glaze,v) Texture Impressionism,y) Texture Large Splat,v) Texture Pointillism,j) Waterpaint Soft Edges,g) Dry Bristles Eroded,g) Dry Bristles,b) Airbrush Soft,j) Waterpaint Hard Edges,b) Basic-5 Size scratchpadVisible=true showAdditionalOnionSkinsSettings=true +showFilterGallery=false showPaletteBottomBar=true toolbarslider_1=opacity toolbarslider_2=size @@ -135,7 +141,7 @@ toolbarslider_4=flow [File Dialogs] OpenDocument=/home/cory/Documents/krita/fd2025 -SaveAs=/home/cory/Documents/krita/dbd2025 +SaveAs=/home/cory/Desktop [FileDialogSize] 2560x1440 screen: Height=674 @@ -147,8 +153,8 @@ global/itemSizeCustom=32 global/viewMode=icon [KFileDialog Settings] -Recent Files[$e]=fd2025.kra,file:$HOME/Documents/krita/dbd2025/dbd2025.png,file:$HOME/Documents/krita/fd2025/fd2025.kra -Recent URLs[$e]=file:$HOME/Documents/krita/fd2025/,file:$HOME/Documents/krita/dbd2025/ +Recent Files[$e]=fd2025.kra,file:$HOME/Desktop/blue.jpeg,file:$HOME/Documents/Krita/mbd2026/mbd2026.png +Recent URLs[$e]=file:$HOME/Documents/Krita/mbd2026/,file:$HOME/Desktop/ detailViewIconSize=16 [KisAssistantTool] @@ -163,7 +169,9 @@ roundCornersX=0 roundCornersY=0 [KritaFill/KisToolFill] -growSelection=3 +growSelection=0 +opacitySpread=100 +thresholdAmount=26 [KritaShape/KisToolRectangle] outlineType=1 @@ -175,9 +183,9 @@ roundCornersY=0 2560x1440 screen: Height=639 2560x1440 screen: Width=988 2560x1440 screen: Window-Maximized=true -State=AAAA/wAAAAD9AAAABAAAAAAAAABCAAAE5/wCAAAAA/sAAAAOAFQAbwBvAGwAQgBvAHgBAAAASgAABOcAAAAzAP////sAAAAkAEYAbABvAHcAUwBoAGEAcABlAEIAbwB4AEQAbwBjAGsAZQByAAAAA2oAAADHAAAAAAAAAAD7AAAAKABGAGwAbwB3AFMAdABlAG4AYwBpAGwAQgBvAHgARABvAGMAawBlAHIAAAADfQAAAMcAAAAAAAAAAAAAAAEAAAG0AAAE5/wCAAAARvsAAAAaAEsAaQBzAEIAaQByAGQAZQB5AGUAQgBvAHgAAAAAAP////8AAAAAAAAAAPsAAAAgAEsAaQBzAFAAYQBsAGUAdAB0AGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAaAEsAbwBDAG8AbABvAHIARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAwAEsAaQBzAFQAcgBpAGEAbgBnAGwAZQBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAAAAAAAD7AAAAIgBTAGgAYQBkAG8AdwAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAAgAFMAaABhAHAAZQAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAAaAFMAaABhAHAAZQBTAGUAbABlAGMAdABvAHIAAAAASAAAAEQAAAAAAAAAAPsAAAAkAFMAaQBtAHAAbABlACAAVABlAHgAdAAgAEUAZABpAHQAbwByAAAAAAD/////AAAAAAAAAAD8AAAASgAAAV0AAACSAQAAHfoAAAAAAQAAAAf7AAAAHgBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAE4AZwEAAAAA/////wAAAFgA////+wAAACAAcwBoAGEAcgBlAGQAdABvAG8AbABkAG8AYwBrAGUAcgEAAAAA/////wAAAFgA////+wAAABwATwB2AGUAcgB2AGkAZQB3AEQAbwBjAGsAZQByAAAAAAD/////AAAAWAD////7AAAAKgBTAHAAZQBjAGkAZgBpAGMAQwBvAGwAbwByAFMAZQBsAGUAYwB0AG8AcgAAAAAA/////wAAAHQA////+wAAABYAQwBvAGwAbwByAFMAbABpAGQAZQByAAAAAAD/////AAAAAAAAAAD7AAAAFgBJAG0AYQBnAGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAqAFMAaABhAHAAZQBDAG8AbABsAGUAYwB0AGkAbwBuAEQAbwBjAGsAZQByAAAABkgAAAEoAAAAAAAAAAD7AAAARgBLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABEAHkAbgBhAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQBAAAAUgAAABIAAAAAAAAAAPsAAAAsAEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAEwAaQBuAGUBAAAAPAAAAGkAAAAAAAAAAPsAAAAyAEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAEUAbABsAGkAcABzAGUBAAAAkQAAABIAAAAAAAAAAPsAAAAcAEsAaQBzAFQAbwBvAGwAUABvAGwAeQBnAG8AbgEAAACmAAAAEgAAAAAAAAAA+wAAAB4ASwBpAHMAVABvAG8AbABQAG8AbAB5AGwAaQBuAGUBAAAAuwAAABIAAAAAAAAAAPsAAAAWAEsAaQBzAFQAbwBvAGwAUwB0AGEAcgEAAADQAAAAEwAAAAAAAAAA+wAAACoAUwBuAGEAcABHAHUAaQBkAGUAQwBvAG4AZgBpAGcAVwBpAGQAZwBlAHQAAAAA7wAAAHEAAAAAAAAAAPsAAAAyAEsAaQBzAFQAbwBvAGwAQwByAG8AcAAgAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQBAAAA+wAAABIAAAAAAAAAAPsAAABQAEsAcgBpAHQAYQBUAHIAYQBuAHMAZgBvAHIAbQAvAEsAaQBzAFQAbwBvAGwATQBvAHYAZQAgAE8AcAB0AGkAbwBuACAAVwBpAGQAZwBlAHQBAAABEAAAABIAAAAAAAAAAPsAAAA8AEsAaQBzAFQAbwBvAGwAVAByAGEAbgBzAGYAbwByAG0AIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAADwAAAAvAAAAAAAAAAD7AAAATgBLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABNAGUAYQBzAHUAcgBlACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAA8AAAAQgAAAAAAAAAA+wAAAFwASwByAGkAdABhAFMAZQBsAGUAYwB0AGUAZAAvAEsAaQBzAFQAbwBvAGwAQwBvAGwAbwByAFAAaQBjAGsAZQByACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAA8AAAA/wAAAAAAAAAA+wAAAEYASwBpAHMAUgB1AGwAZQByAEEAcwBzAGkAcwB0AGEAbgB0AFQAbwBvAGwAIABPAHAAdABpAG8AbgAgAFcAaQBkAGcAZQB0AQAAADwAAAASAAAAAAAAAAD7AAAASABLAGkAcwBUAG8AbwBsAFAAZQByAHMAcABlAGMAdABpAHYAZQBHAHIAaQBkACAATwBwAHQAaQBvAG4AIABXAGkAZABnAGUAdAEAAAGjAAAAEgAAAAAAAAAA+wAAADIASwBpAHMAVABvAG8AbABHAHIAaQBkACAATwBwAHQAaQBvAG4AIABXAGkAZABnAGUAdAEAAAG4AAAAEwAAAAAAAAAA+wAAAEwASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABSAGUAYwB0AGEAbgBnAHUAbABhAHIAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAAc4AAAASAAAAAAAAAAD7AAAASgBLAGkAcwBUAG8AbwBsAFMAZQBsAGUAYwB0AEUAbABsAGkAcAB0AGkAYwBhAGwAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAAeMAAAASAAAAAAAAAAD7AAAASABLAGkAcwBUAG8AbwBsAFMAZQBsAGUAYwB0AFAAbwBsAHkAZwBvAG4AYQBsACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAH4AAAAEgAAAAAAAAAA+wAAAEQASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABPAHUAdABsAGkAbgBlACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAINAAAAEgAAAAAAAAAA+wAAAEoASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABDAG8AbgB0AGkAZwB1AG8AdQBzACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAIiAAAAEgAAAAAAAAAA+wAAAEQASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABTAGkAbQBpAGwAYQByACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAI3AAAAEgAAAAAAAAAA/AAAAbYAAABaAAAAAAD////6AAAAAAEAAAAC+wAAAC4ASwBvAFMAaABhAHAAZQBDAG8AbABsAGUAYwB0AGkAbwBuAEQAbwBjAGsAZQByAQAAAAD/////AAAAAAAAAAD7AAAAJABTAG0AYQBsAGwAQwBvAGwAbwByAFMAZQBsAGUAYwB0AG8AcgAAAANuAAABBAAAAFgA/////AAAAagAAAHjAAAAygD////6AAAAAAEAAAAD+wAAABYASwBpAHMATABhAHkAZQByAEIAbwB4AQAAAAD/////AAABAgD////7AAAAGgBDAGgAYQBuAG4AZQBsAEQAbwBjAGsAZQByAAAAAAD/////AAAAWAD////7AAAALgBLAGkAcwBQAGEAaQBuAHQAZQByAGwAeQBNAGkAeABlAHIARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPwAAAOMAAABpQAAADkA////+gAAAAABAAAAAvsAAAAYAFAAcgBlAHMAZQB0AEQAbwBjAGsAZQByAQAAAAD/////AAAAZgD////7AAAAGgBQAHIAZQBzAGUAdABIAGkAcwB0AG8AcgB5AAAACPoAAAEGAAAAWAD////7AAAASABLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABCAHIAdQBzAGgAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAPcAAAAaAAAAAAAAAAA+wAAACIAUwB0AHIAbwBrAGUAIABQAHIAbwBwAGUAcgB0AGkAZQBzAAAAAAD/////AAAAAAAAAAD7AAAAFgBTAHQAeQBsAGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAgAEsAaQBzAEgAaQBzAHQAbwBnAHIAYQBtAEQAbwBjAGsAAAAAAP////8AAAAAAAAAAPsAAAASAFMAYwByAGkAcAB0AGkAbgBnAAAAAAD/////AAAAAAAAAAD7AAAAMABEAGUAZgBhAHUAbAB0AFQAbwBvAGwAQQByAHIAYQBuAGcAZQBXAGkAZABnAGUAdAAAAAK8AAAAUgAAAAAAAAAA+wAAACIARABlAGYAYQB1AGwAdABUAG8AbwBsAFcAaQBkAGcAZQB0AAAAAxEAAABbAAAAAAAAAAD7AAAAJABLAGkAcwBIAGkAcwB0AG8AZwByAGEAbQBEAG8AYwBrAGUAcgAAAAJCAAAAewAAAAAAAAAA+wAAABgARABpAGcAaQB0AGEAbABNAGkAeABlAHIAAAAAAP////8AAADNAP////sAAAAOAEgAaQBzAHQAbwByAHkAAAADkAAAALQAAABpAP////sAAABOAEsAcgBpAHQAYQBGAGkAbABsAC8ASwBpAHMAVABvAG8AbABHAHIAYQBkAGkAZQBuAHQAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AAAABCgAAAAcAAAAAAAAAAD7AAAARgBLAHIAaQB0AGEARgBpAGwAbAAvAEsAaQBzAFQAbwBvAGwARgBpAGwAbAAgAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQAAAADUAAAABwAAAAAAAAAAPsAAAA2AEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAFIAZQBjAHQAYQBuAGcAbABlAAAAAwUAAABnAAAAAAAAAAD7AAAAIgBDAG8AbQBwAG8AcwBpAHQAaQBvAG4ARABvAGMAawBlAHIAAAAAAP////8AAACQAP////sAAAAqAEEAcgB0AGkAcwB0AGkAYwBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAegD////7AAAAGgBQAGEAdAB0AGUAcgBuAEQAbwBjAGsAZQByAAAAAtkAAAFJAAABMwAIABX7AAAAGgBUAGEAcwBrAHMAZQB0AEQAbwBjAGsAZQByAAAAAAD/////AAAAkQD////7AAAAKABTAG4AYQBwAEcAdQBpAGQAZQAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAA4AFQAZQB4AHQARABvAGMAdQBtAGUAbgB0AEkAbgBzAHAAZQBjAHQAaQBvAG4ARABvAGMAawBlAHICAAAEmgAAAhUAAAEqAAAArvsAAAASAEwAdQB0AEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAGgBQAGEAbABlAHQAdABlAEQAbwBjAGsAZQByAAAAAAD/////AAAAfAD////7AAAAFABHAHIAaQBkAEQAbwBjAGsAZQByAAAAAAD/////AAABMAD////7AAAAHgBIAGkAcwB0AG8AZwByAGEAbQBEAG8AYwBrAGUAcgAAAAAA/////wAAAEoA////+wAAACoAQQBuAGkAbQBhAHQAaQBvAG4AQwB1AHIAdgBlAHMARABvAGMAawBlAHIAAAAAAP////8AAAB1AP////sAAAAyAFMAdgBnAFMAeQBtAGIAbwBsAEMAbwBsAGwAZQBjAHQAaQBvAG4ARABvAGMAawBlAHIAAAAAAP////8AAACRAP////sAAAAWAFQAbwB1AGMAaABEAG8AYwBrAGUAcgAAAAJMAAABMQAAABgA////+wAAABoAQQByAHIAYQBuAGcAZQBEAG8AYwBrAGUAcgAAAAAA/////wAAADUA////+wAAADoAYwBvAG0AaQBjAHMAXwBwAHIAbwBqAGUAYwB0AF8AbQBhAG4AYQBnAGUAcgBfAGQAbwBjAGsAZQByAAAAAAD/////AAAA4wD////7AAAAKgBxAHUAaQBjAGsAXwBzAGUAdAB0AGkAbgBnAHMAXwBkAG8AYwBrAGUAcgAAAAAA/////wAAAI8A////+wAAABYAUABhAGcAZQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAJgBsAGEAcwB0AGQAbwBjAHUAbQBlAG4AdABzAGQAbwBjAGsAZQByAAAAAAD/////AAAAlwD////7AAAAEgBHAGEAbQB1AHQATQBhAHMAawAAAAAA/////wAAAM0A////+wAAABAAUwBuAGEAcABzAGgAbwB0AAAAAt8AAACkAAAAkQD////7AAAAEgBMAG8AZwBEAG8AYwBrAGUAcgAAAAAA/////wAAAJMA////+wAAACAAUwB0AG8AcgB5AGIAbwBhAHIAZABEAG8AYwBrAGUAcgAAAAAA/////wAAALoA////+wAAABwAUgBlAGMAbwByAGQAZQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAawD////7AAAALABXAGkAZABlAEcAYQBtAHUAdABDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAtwD///8AAAACAAAKAAAAALz8AQAAAAH7AAAAGgBUAG8AbwBsAEIAYQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAAAAAADAAAAAAAAAAD8AQAAAAT7AAAAHABGAGwAaQBwAGIAbwBvAGsARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAeAEEAbgBpAG0AYQB0AGkAbwBuAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAIABPAG4AaQBvAG4AUwBrAGkAbgBzAEQAbwBjAGsAZQByAAAAAAD/////AAABRgD////7AAAAHABUAGkAbQBlAGwAaQBuAGUARABvAGMAawBlAHIAAAAAAP////8AAAOxAP///wAACAgAAATnAAAABAAAAAQAAAAIAAAACPwAAAABAAAAAgAAAAMAAAAWAG0AYQBpAG4AVABvAG8AbABCAGEAcgEAAAAA/////wAAAAAAAAAAAAAAHgBCAHIAdQBzAGgAZQBzAEEAbgBkAFMAdAB1AGYAZgEAAABs/////wAAAAAAAAAAAAAAFgBlAGQAaQB0AFQAbwBvAGwAQgBhAHIAAAAAAP////8AAAAAAAAAAA== +State=AAAA/wAAAAD9AAAABAAAAAAAAABCAAAE4/wCAAAAA/sAAAAOAFQAbwBvAGwAQgBvAHgBAAAASgAABOMAAAAzAP////sAAAAkAEYAbABvAHcAUwBoAGEAcABlAEIAbwB4AEQAbwBjAGsAZQByAAAAA2oAAADHAAAAAAAAAAD7AAAAKABGAGwAbwB3AFMAdABlAG4AYwBpAGwAQgBvAHgARABvAGMAawBlAHIAAAADfQAAAMcAAAAAAAAAAAAAAAEAAAGrAAAE4/wCAAAARvsAAAAaAEsAaQBzAEIAaQByAGQAZQB5AGUAQgBvAHgAAAAAAP////8AAAAAAAAAAPsAAAAgAEsAaQBzAFAAYQBsAGUAdAB0AGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAaAEsAbwBDAG8AbABvAHIARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAwAEsAaQBzAFQAcgBpAGEAbgBnAGwAZQBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAAAAAAAD7AAAAIgBTAGgAYQBkAG8AdwAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAAgAFMAaABhAHAAZQAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAAaAFMAaABhAHAAZQBTAGUAbABlAGMAdABvAHIAAAAASAAAAEQAAAAAAAAAAPsAAAAkAFMAaQBtAHAAbABlACAAVABlAHgAdAAgAEUAZABpAHQAbwByAAAAAAD/////AAAAAAAAAAD8AAAASgAAAVwAAACSAQAAHfoAAAABAQAAAAf7AAAAHgBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAE4AZwEAAAAA/////wAAAFgA////+wAAACAAcwBoAGEAcgBlAGQAdABvAG8AbABkAG8AYwBrAGUAcgEAAAAA/////wAAAFgA////+wAAABwATwB2AGUAcgB2AGkAZQB3AEQAbwBjAGsAZQByAAAAAAD/////AAAAWAD////7AAAAKgBTAHAAZQBjAGkAZgBpAGMAQwBvAGwAbwByAFMAZQBsAGUAYwB0AG8AcgAAAAAA/////wAAAHQA////+wAAABYAQwBvAGwAbwByAFMAbABpAGQAZQByAAAAAAD/////AAAAAAAAAAD7AAAAFgBJAG0AYQBnAGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAqAFMAaABhAHAAZQBDAG8AbABsAGUAYwB0AGkAbwBuAEQAbwBjAGsAZQByAAAABkgAAAEoAAAAAAAAAAD7AAAARgBLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABEAHkAbgBhAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQBAAAAUgAAABIAAAAAAAAAAPsAAAAsAEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAEwAaQBuAGUBAAAAPAAAAGkAAAAAAAAAAPsAAAAyAEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAEUAbABsAGkAcABzAGUBAAAAkQAAABIAAAAAAAAAAPsAAAAcAEsAaQBzAFQAbwBvAGwAUABvAGwAeQBnAG8AbgEAAACmAAAAEgAAAAAAAAAA+wAAAB4ASwBpAHMAVABvAG8AbABQAG8AbAB5AGwAaQBuAGUBAAAAuwAAABIAAAAAAAAAAPsAAAAWAEsAaQBzAFQAbwBvAGwAUwB0AGEAcgEAAADQAAAAEwAAAAAAAAAA+wAAACoAUwBuAGEAcABHAHUAaQBkAGUAQwBvAG4AZgBpAGcAVwBpAGQAZwBlAHQAAAAA7wAAAHEAAAAAAAAAAPsAAAAyAEsAaQBzAFQAbwBvAGwAQwByAG8AcAAgAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQBAAAA+wAAABIAAAAAAAAAAPsAAABQAEsAcgBpAHQAYQBUAHIAYQBuAHMAZgBvAHIAbQAvAEsAaQBzAFQAbwBvAGwATQBvAHYAZQAgAE8AcAB0AGkAbwBuACAAVwBpAGQAZwBlAHQBAAABEAAAABIAAAAAAAAAAPsAAAA8AEsAaQBzAFQAbwBvAGwAVAByAGEAbgBzAGYAbwByAG0AIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAADwAAAAvAAAAAAAAAAD7AAAATgBLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABNAGUAYQBzAHUAcgBlACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAA8AAAAQgAAAAAAAAAA+wAAAFwASwByAGkAdABhAFMAZQBsAGUAYwB0AGUAZAAvAEsAaQBzAFQAbwBvAGwAQwBvAGwAbwByAFAAaQBjAGsAZQByACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAA8AAAA/wAAAAAAAAAA+wAAAEYASwBpAHMAUgB1AGwAZQByAEEAcwBzAGkAcwB0AGEAbgB0AFQAbwBvAGwAIABPAHAAdABpAG8AbgAgAFcAaQBkAGcAZQB0AQAAADwAAAASAAAAAAAAAAD7AAAASABLAGkAcwBUAG8AbwBsAFAAZQByAHMAcABlAGMAdABpAHYAZQBHAHIAaQBkACAATwBwAHQAaQBvAG4AIABXAGkAZABnAGUAdAEAAAGjAAAAEgAAAAAAAAAA+wAAADIASwBpAHMAVABvAG8AbABHAHIAaQBkACAATwBwAHQAaQBvAG4AIABXAGkAZABnAGUAdAEAAAG4AAAAEwAAAAAAAAAA+wAAAEwASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABSAGUAYwB0AGEAbgBnAHUAbABhAHIAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAAc4AAAASAAAAAAAAAAD7AAAASgBLAGkAcwBUAG8AbwBsAFMAZQBsAGUAYwB0AEUAbABsAGkAcAB0AGkAYwBhAGwAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AQAAAeMAAAASAAAAAAAAAAD7AAAASABLAGkAcwBUAG8AbwBsAFMAZQBsAGUAYwB0AFAAbwBsAHkAZwBvAG4AYQBsACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAH4AAAAEgAAAAAAAAAA+wAAAEQASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABPAHUAdABsAGkAbgBlACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAINAAAAEgAAAAAAAAAA+wAAAEoASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABDAG8AbgB0AGkAZwB1AG8AdQBzACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAIiAAAAEgAAAAAAAAAA+wAAAEQASwBpAHMAVABvAG8AbABTAGUAbABlAGMAdABTAGkAbQBpAGwAYQByACAAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAI3AAAAEgAAAAAAAAAA/AAAAbYAAABaAAAAAAD////6AAAAAAEAAAAC+wAAAC4ASwBvAFMAaABhAHAAZQBDAG8AbABsAGUAYwB0AGkAbwBuAEQAbwBjAGsAZQByAQAAAAD/////AAAAAAAAAAD7AAAAJABTAG0AYQBsAGwAQwBvAGwAbwByAFMAZQBsAGUAYwB0AG8AcgAAAANuAAABBAAAAFgA/////AAAAacAAAHhAAAAygD////6AAAAAAEAAAAD+wAAABYASwBpAHMATABhAHkAZQByAEIAbwB4AQAAAAD/////AAABAgD////7AAAAGgBDAGgAYQBuAG4AZQBsAEQAbwBjAGsAZQByAAAAAAD/////AAAAWAD////7AAAALgBLAGkAcwBQAGEAaQBuAHQAZQByAGwAeQBNAGkAeABlAHIARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPwAAAOJAAABpAAAADkA////+gAAAAABAAAAAvsAAAAYAFAAcgBlAHMAZQB0AEQAbwBjAGsAZQByAQAAAAD/////AAAAZgD////7AAAAGgBQAHIAZQBzAGUAdABIAGkAcwB0AG8AcgB5AAAACPoAAAEGAAAAWAD////7AAAASABLAHIAaQB0AGEAUwBoAGEAcABlAC8ASwBpAHMAVABvAG8AbABCAHIAdQBzAGgAbwBwAHQAaQBvAG4AIAB3AGkAZABnAGUAdAEAAAPcAAAAaAAAAAAAAAAA+wAAACIAUwB0AHIAbwBrAGUAIABQAHIAbwBwAGUAcgB0AGkAZQBzAAAAAAD/////AAAAAAAAAAD7AAAAFgBTAHQAeQBsAGUARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAgAEsAaQBzAEgAaQBzAHQAbwBnAHIAYQBtAEQAbwBjAGsAAAAAAP////8AAAAAAAAAAPsAAAASAFMAYwByAGkAcAB0AGkAbgBnAAAAAAD/////AAAAAAAAAAD7AAAAMABEAGUAZgBhAHUAbAB0AFQAbwBvAGwAQQByAHIAYQBuAGcAZQBXAGkAZABnAGUAdAAAAAK8AAAAUgAAAAAAAAAA+wAAACIARABlAGYAYQB1AGwAdABUAG8AbwBsAFcAaQBkAGcAZQB0AAAAAxEAAABbAAAAAAAAAAD7AAAAJABLAGkAcwBIAGkAcwB0AG8AZwByAGEAbQBEAG8AYwBrAGUAcgAAAAJCAAAAewAAAAAAAAAA+wAAABgARABpAGcAaQB0AGEAbABNAGkAeABlAHIAAAAAAP////8AAADNAP////sAAAAOAEgAaQBzAHQAbwByAHkAAAADkAAAALQAAABpAP////sAAABOAEsAcgBpAHQAYQBGAGkAbABsAC8ASwBpAHMAVABvAG8AbABHAHIAYQBkAGkAZQBuAHQAIABvAHAAdABpAG8AbgAgAHcAaQBkAGcAZQB0AAAABCgAAAAcAAAAAAAAAAD7AAAARgBLAHIAaQB0AGEARgBpAGwAbAAvAEsAaQBzAFQAbwBvAGwARgBpAGwAbAAgAG8AcAB0AGkAbwBuACAAdwBpAGQAZwBlAHQAAAADUAAAABwAAAAAAAAAAPsAAAA2AEsAcgBpAHQAYQBTAGgAYQBwAGUALwBLAGkAcwBUAG8AbwBsAFIAZQBjAHQAYQBuAGcAbABlAAAAAwUAAABnAAAAAAAAAAD7AAAAIgBDAG8AbQBwAG8AcwBpAHQAaQBvAG4ARABvAGMAawBlAHIAAAAAAP////8AAACQAP////sAAAAqAEEAcgB0AGkAcwB0AGkAYwBDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAegD////7AAAAGgBQAGEAdAB0AGUAcgBuAEQAbwBjAGsAZQByAAAAAtkAAAFJAAABMwAIABX7AAAAGgBUAGEAcwBrAHMAZQB0AEQAbwBjAGsAZQByAAAAAAD/////AAAAkQD////7AAAAKABTAG4AYQBwAEcAdQBpAGQAZQAgAFAAcgBvAHAAZQByAHQAaQBlAHMAAAAAAP////8AAAAAAAAAAPsAAAA4AFQAZQB4AHQARABvAGMAdQBtAGUAbgB0AEkAbgBzAHAAZQBjAHQAaQBvAG4ARABvAGMAawBlAHICAAAEmgAAAhUAAAEqAAAArvsAAAASAEwAdQB0AEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAGgBQAGEAbABlAHQAdABlAEQAbwBjAGsAZQByAAAAAAD/////AAAAfAD////7AAAAFABHAHIAaQBkAEQAbwBjAGsAZQByAAAAAAD/////AAABMAD////7AAAAHgBIAGkAcwB0AG8AZwByAGEAbQBEAG8AYwBrAGUAcgAAAAAA/////wAAAEoA////+wAAACoAQQBuAGkAbQBhAHQAaQBvAG4AQwB1AHIAdgBlAHMARABvAGMAawBlAHIAAAAAAP////8AAAB1AP////sAAAAyAFMAdgBnAFMAeQBtAGIAbwBsAEMAbwBsAGwAZQBjAHQAaQBvAG4ARABvAGMAawBlAHIAAAAAAP////8AAACRAP////sAAAAWAFQAbwB1AGMAaABEAG8AYwBrAGUAcgAAAAJMAAABMQAAABgA////+wAAABoAQQByAHIAYQBuAGcAZQBEAG8AYwBrAGUAcgAAAAAA/////wAAADUA////+wAAADoAYwBvAG0AaQBjAHMAXwBwAHIAbwBqAGUAYwB0AF8AbQBhAG4AYQBnAGUAcgBfAGQAbwBjAGsAZQByAAAAAAD/////AAAA4wD////7AAAAKgBxAHUAaQBjAGsAXwBzAGUAdAB0AGkAbgBnAHMAXwBkAG8AYwBrAGUAcgAAAAAA/////wAAAI8A////+wAAABYAUABhAGcAZQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAJgBsAGEAcwB0AGQAbwBjAHUAbQBlAG4AdABzAGQAbwBjAGsAZQByAAAAAAD/////AAAAlwD////7AAAAEgBHAGEAbQB1AHQATQBhAHMAawAAAAAA/////wAAAM0A////+wAAABAAUwBuAGEAcABzAGgAbwB0AAAAAt8AAACkAAAAkQD////7AAAAEgBMAG8AZwBEAG8AYwBrAGUAcgAAAAAA/////wAAAJMA////+wAAACAAUwB0AG8AcgB5AGIAbwBhAHIAZABEAG8AYwBrAGUAcgAAAAAA/////wAAALoA////+wAAABwAUgBlAGMAbwByAGQAZQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAawD////7AAAALABXAGkAZABlAEcAYQBtAHUAdABDAG8AbABvAHIAUwBlAGwAZQBjAHQAbwByAAAAAAD/////AAAAtwD///8AAAACAAAKAAAAALz8AQAAAAH7AAAAGgBUAG8AbwBsAEIAYQByAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAAAAAADAAAAAAAAAAD8AQAAAAT7AAAAHABGAGwAaQBwAGIAbwBvAGsARABvAGMAawBlAHIAAAAAAP////8AAAAAAAAAAPsAAAAeAEEAbgBpAG0AYQB0AGkAbwBuAEQAbwBjAGsAZQByAAAAAAD/////AAAAAAAAAAD7AAAAIABPAG4AaQBvAG4AUwBrAGkAbgBzAEQAbwBjAGsAZQByAAAAAAD/////AAABRgD////7AAAAHABUAGkAbQBlAGwAaQBuAGUARABvAGMAawBlAHIAAAAAAP////8AAAOxAP///wAACBEAAATjAAAABAAAAAQAAAAIAAAACPwAAAABAAAAAgAAAAMAAAAWAG0AYQBpAG4AVABvAG8AbABCAGEAcgEAAAAA/////wAAAAAAAAAAAAAAHgBCAHIAdQBzAGgAZQBzAEEAbgBkAFMAdAB1AGYAZgEAAABs/////wAAAAAAAAAAAAAAFgBlAGQAaQB0AFQAbwBvAGwAQgBhAHIAAAAAAP////8AAAAAAAAAAA== ToolBarsMovable=Disabled -ko_geometry=AdnQywADAAAAAAAAAAAAAAAACf8AAAVzAAACtAAAAREAAAaPAAADjwAAAAACAAAACgAAAAAAAAAAHAAACf8AAAVz +ko_geometry=AdnQywADAAAAAAAAAAAAAAAACf8AAAVvAAAEfv///3YAAAhZAAAB9AAAAAACAAAACgAAAAAAAAAAHAAACf8AAAVv [MainWindow][DockWidget AnimationCurvesDocker] DockArea=2 @@ -214,8 +222,8 @@ yPosition=0 [MainWindow][DockWidget ColorSelectorNg] DockArea=2 Locked=false -height=297 -width=436 +height=296 +width=427 xPosition=0 yPosition=22 @@ -270,8 +278,8 @@ yPosition=22 [MainWindow][DockWidget KisLayerBox] DockArea=2 Locked=false -height=461 -width=436 +height=459 +width=427 xPosition=0 yPosition=22 @@ -326,8 +334,8 @@ yPosition=0 [MainWindow][DockWidget PresetDocker] DockArea=2 Locked=false -height=399 -width=436 +height=398 +width=427 xPosition=0 yPosition=22 @@ -406,7 +414,7 @@ yPosition=0 [MainWindow][DockWidget ToolBox] DockArea=1 Locked=false -height=1236 +height=1232 width=66 xPosition=0 yPosition=19 @@ -454,8 +462,8 @@ yPosition=22 [MainWindow][DockWidget sharedtooldocker] DockArea=2 Locked=false -height=458 -width=640 +height=296 +width=427 xPosition=0 yPosition=22 @@ -463,15 +471,15 @@ yPosition=22 pinControls=true [RecentFiles] -File1[$e]=$HOME/Desktop/phone-backup/ScannedDocs/DocScanner Jan 6, 2024 6-30 PM.pdf -Name1=DocScanner Jan 6, 2024 6-30 PM.pdf +File1[$e]=$HOME/Desktop/Resident Evil Character Art.jpeg +Name1=Resident Evil Character Art.jpeg maxRecentFileItems=100 [SelectedTags] brushes=All gamutmasks=All gradients=All -paintoppresets=Pixel Art +paintoppresets=Digital palettes=All patterns=All tasksets=All @@ -481,6 +489,10 @@ workspaces=All [SvgSymbolCollection] currentCollection=0 +[SvgTextTool] +Geometry=AdnQywADAAAAAAUSAAAB6AAACeAAAAUIAAAFEwAAAgQAAAnfAAAFBwAAAAAAAAAACgAAAAUTAAACBAAACd8AAAUH +windowState=AAAA/wAAAAD9AAAAAAAABM0AAAJiAAAABAAAAAQAAAAIAAAACPwAAAADAAAAAgAAAAEAAAAWAG0AYQBpAG4AVABvAG8AbABCAGEAcgEAAAAA/////wAAAAAAAAAAAAAAAgAAAAEAAAAYAGYAbwBuAHQAUwBlAHQAdABpAG4AZwBzAQAAAAD/////AAAAAAAAAAAAAAACAAAAAQAAABQAZgBvAHIAbQBhAHQAdABpAG4AZwEAAAAA/////wAAAAAAAAAA + [advancedColorSelector] customSelectorBackgroundColor=160,160,164 gamma=2.2 @@ -490,9 +502,15 @@ minimalShadeSelectorLineConfig=0|0.2|0|0|0|0|0;1|0|1|1|0|0|0;2|0|-1|1|0|0|0 showColorSelector=true useCustomColorForBackground=false +[colortoalpha_filter_bookmarks] +Last Used=\n\n #ffffff\n 37\n\n + [crashprevention] CreatingCanvas=false +[filterdialog] +showPreview=true + [krita] ColorSpaceExtensionsPlugins=\\0 ColorSpaceExtensionsPluginsDisabled= @@ -508,7 +526,7 @@ ToolPlugins=,,,,,,,,,,,,, ToolPluginsDisabled= [theme] -Theme=Krita dark +Theme=Krita bright [tool_color_sampler] ColorSamplerDefaultActivation=\n\n false\n 100\n false\n 1\n true\n true\n true\n\n diff --git a/.config/krunnerrc b/.config/krunnerrc index 774df41..05b61e8 100644 --- a/.config/krunnerrc +++ b/.config/krunnerrc @@ -1,3 +1,6 @@ +[General] +FreeFloating=true + [Plugins] baloosearchEnabled=false browserhistoryEnabled=false @@ -16,10 +19,10 @@ krunner_recentdocumentsEnabled=false krunner_sessionsEnabled=false krunner_shellEnabled=true krunner_spellcheckEnabled=false -krunner_webshortcutsEnabled=false +krunner_webshortcutsEnabled=true org.kde.datetimeEnabled=false unitconverterEnabled=false windowsEnabled=true [Plugins][Favorites] -plugins=krunner_sessions,krunner_powerdevil,krunner_services,krunner_placesrunner,krunner_systemsettings +plugins=krunner_sessions,krunner_webshortcuts,krunner_powerdevil,krunner_services,krunner_placesrunner,krunner_systemsettings diff --git a/.config/kscreenlockerrc b/.config/kscreenlockerrc index f7781f7..7d46647 100644 --- a/.config/kscreenlockerrc +++ b/.config/kscreenlockerrc @@ -3,3 +3,7 @@ Autolock=false LockOnResume=false RequirePassword=false Timeout=0 + +[Greeter][Wallpaper][org.kde.image][General] +Image=/home/cory/Desktop/sunset between the clouds by exobiologyart.jpg +PreviewImage=/home/cory/Desktop/sunset between the clouds by exobiologyart.jpg diff --git a/.config/ksmserverrc b/.config/ksmserverrc index b093731..821f628 100644 --- a/.config/ksmserverrc +++ b/.config/ksmserverrc @@ -1,3 +1,6 @@ +[General] +confirmLogout=false + [LegacySession: saved at previous logout] count=0 diff --git a/.config/kwinoutputconfig.json b/.config/kwinoutputconfig.json index bae30a9..edb8938 100644 --- a/.config/kwinoutputconfig.json +++ b/.config/kwinoutputconfig.json @@ -5,7 +5,7 @@ "allowDdcCi": true, "allowSdrSoftwareBrightness": true, "autoRotation": "InTabletMode", - "brightness": 0.6, + "brightness": 1, "colorPowerTradeoff": "PreferEfficiency", "colorProfileSource": "sRGB", "connectorName": "DP-1", @@ -25,8 +25,8 @@ "overscan": 0, "rgbRange": "Automatic", "scale": 1, - "sdrBrightness": 450, - "sdrGamutWideness": 0, + "sdrBrightness": 350, + "sdrGamutWideness": 0.5, "transform": "Normal", "uuid": "65840ce5-c6bf-4108-abe1-899510a19500", "vrrPolicy": "Automatic", diff --git a/.config/kwinrc b/.config/kwinrc index c54519b..1601e25 100644 --- a/.config/kwinrc +++ b/.config/kwinrc @@ -1,5 +1,6 @@ [Activities][LastVirtualDesktop] -dc7cfc1e-da2d-4ff2-977f-a1a4449080f6=f4bd76ec-75ca-4ce6-bfdc-a72a1e8178e1 +18f515e7-cf8b-4327-80ee-9f74afa20678=cc557718-d230-4008-b457-5762574b13df +dc7cfc1e-da2d-4ff2-977f-a1a4449080f6=cc557718-d230-4008-b457-5762574b13df [Desktops] Id_1=cc557718-d230-4008-b457-5762574b13df @@ -12,19 +13,30 @@ Rows=1 [Effect-fadedesktop] AnimationDuration=100 +[Effect-kwin6_effect_aura_glow] +Duration=400 + [Effect-overview] BorderActivate=9 +[Effect-windowview] +BorderActivateAll=7 + [ElectricBorders] BottomLeft=ApplicationLauncher -[MouseBindings] -CommandAllKey=Alt - [Plugins] +blurEnabled=true fadedesktopEnabled=true -shakecursorEnabled=false +magiclampEnabled=true slideEnabled=false +squashEnabled=false + +[TabBox] +DesktopMode=0 + +[TabBoxAlternative] +DesktopMode=0 [Tiling] padding=4 @@ -53,9 +65,18 @@ tiles={"layoutDirection":"horizontal","tiles":[{"width":0.25},{"width":0.5},{"wi [Tiling][f4bd76ec-75ca-4ce6-bfdc-a72a1e8178e1][65f001c2-d3c6-4d0c-be1c-d7e2820ac050] tiles={"layoutDirection":"horizontal","tiles":[{"width":0.25},{"width":0.5},{"width":0.25}]} +[Wayland] +InputMethod[$e]=/usr/share/applications/org.freedesktop.IBus.Panel.Wayland.Gtk3.desktop +VirtualKeyboardEnabled=false + [Windows] ElectricBorderCooldown=200 ElectricBorderDelay=0 [Xwayland] Scale=1 + +[org.kde.kdecoration2] +BorderSize=Normal +library=org.kde.breeze +theme=Breeze diff --git a/.config/kwinrulesrc b/.config/kwinrulesrc index 7eacbbb..77276fe 100644 --- a/.config/kwinrulesrc +++ b/.config/kwinrulesrc @@ -16,6 +16,10 @@ types=1 wmclass=spotify wmclassmatch=1 +[2739d8d4-b20f-48d2-9e33-a6d95fdbd228] +desktopsrule=3 +skippagerrule=3 + [5a3d3e7e-7075-410d-8951-691857124709] Description=Settings for dolphin-emu desktops=f4bd76ec-75ca-4ce6-bfdc-a72a1e8178e1 @@ -41,25 +45,69 @@ types=1 wmclass=google-chrome wmclassmatch=1 -[808f492f-47d2-404b-ba4d-6b332a5cd630] +[7cc84c7f-04f4-4a5c-852e-1f57a535b2e6] +Description=Settings for qemu-system-x86_64 Emulator +desktops=d92ab4bd-1818-437f-832f-743c12f16afe +desktopsrule=3 +title=Android Emulator - Desktop:5554 +wmclass=qemu-system-x86_64 Emulator +wmclasscomplete=true +wmclassmatch=1 + +[7f5b3fcb-8c8a-42b0-9214-24b05bf6e6a8] +Description=Sunamu Lyrics +acceptfocusrule=2 +desktops=\\0 +desktopsrule=3 +fpplevel=4 +fpplevelrule=2 +fsplevel=4 +fsplevelrule=2 +layer=overlay +layerrule=2 +position=0,948 +positionrule=3 +size=2577,648 +sizerule=3 +skippager=true +skippagerrule=3 +skiptaskbar=true +skiptaskbarrule=3 +wmclass=sunamu +wmclassmatch=1 + +[8b870cb0-cd7a-45fc-90a5-8e582b3ae63e] +Description=Window settings for LibreWolf +desktops=cc557718-d230-4008-b457-5762574b13df +desktopsrule=3 +title=LibreWolf +titlematch=1 +wmclass=librewolf +wmclassmatch=1 + +[96fa5e26-3cfb-4a9d-8160-d970188f5457] +above=true +aboverule=3 + +[General] +count=12 +rules=f110a92a-8318-4694-bc7d-0965d0e6cd45,6b374827-d34e-4440-a2ac-588ac51864fb,25639534-b946-4898-a84b-f3cffaf09865,09896aad-7cf6-44f4-abf6-b4fb1078079a,76837bda-0f0b-44a4-a2d5-247bfcb409d3,5a3d3e7e-7075-410d-8951-691857124709,dc115368-7cd7-4c86-84a2-92506f94a7f7,8b870cb0-cd7a-45fc-90a5-8e582b3ae63e,dcbfa8c1-66dd-44a4-aaef-f79588fabb4c,7f5b3fcb-8c8a-42b0-9214-24b05bf6e6a8,7cc84c7f-04f4-4a5c-852e-1f57a535b2e6,c1265023-1942-47b0-91d3-eb147f0776bb + +[c1265023-1942-47b0-91d3-eb147f0776bb] Description=Window settings for Picture-in-Picture desktops=\\0 desktopsrule=3 layer=overlay layerrule=2 -position=2029,0 +position=2020,0 positionrule=3 -size=531,299 +size=540,303 sizerule=3 title=Picture-in-Picture -titlematch=2 +titlematch=1 wmclass=app.zen_browser.zen wmclassmatch=1 -[General] -count=8 -rules=f110a92a-8318-4694-bc7d-0965d0e6cd45,6b374827-d34e-4440-a2ac-588ac51864fb,25639534-b946-4898-a84b-f3cffaf09865,09896aad-7cf6-44f4-abf6-b4fb1078079a,808f492f-47d2-404b-ba4d-6b332a5cd630,76837bda-0f0b-44a4-a2d5-247bfcb409d3,5a3d3e7e-7075-410d-8951-691857124709,dc115368-7cd7-4c86-84a2-92506f94a7f7 - [dc115368-7cd7-4c86-84a2-92506f94a7f7] Description=Settings for Cornerpond below=true @@ -72,6 +120,22 @@ types=1 wmclass=Cornerpond wmclassmatch=1 +[dcbfa8c1-66dd-44a4-aaef-f79588fabb4c] +Description=Window settings for Picture-in-Picture +acceptfocusrule=2 +desktops=\\0 +desktopsrule=3 +layer=overlay +layerrule=2 +position=1891,0 +positionrule=3 +size=287,161 +sizerule=3 +title=Picture-in-Picture +titlematch=1 +wmclass=librewolf +wmclassmatch=1 + [f110a92a-8318-4694-bc7d-0965d0e6cd45] Description=Settings for steam desktops=f4bd76ec-75ca-4ce6-bfdc-a72a1e8178e1 diff --git a/.config/kwritemetainfos b/.config/kwritemetainfos index 6c5173b..692487d 100644 --- a/.config/kwritemetainfos +++ b/.config/kwritemetainfos @@ -1,11 +1,11 @@ -[file:///home/cory/Desktop/rogue-dawn/Rogue Dawn 1_21 Read Me.txt] -Checksum=1f3bde3c4e3e7992e13c8c396c458a20fd2b1b11 +[file:///home/cory/Desktop/Hytale/Hytale/package/game/latest/Client/HytaleClient.exe] +Checksum=1415760fe3c8f28e7af4ec37af1ee23e0914332d Encoding=ISO-8859-1 -Time=2025,11,27,1,17,13.067,UTC -URL=file:///home/cory/Desktop/rogue-dawn/Rogue Dawn 1_21 Read Me.txt +Time=2026,1,16,5,18,15.487,UTC +URL=file:///home/cory/Desktop/Hytale/Hytale/package/game/latest/Client/HytaleClient.exe -[file:///home/cory/Downloads/jack_113773_linux_x64.run] -Checksum=86aa8e9a29118079cf9c1ac922c7a96b5f04e4fb +[file:///home/cory/Desktop/neovide.AppImage.zsync] +Checksum=96e235b5570d1e3f902d476dec703d437002fd80 Encoding=ISO-8859-1 -Time=2025,11,30,20,59,59.821,UTC -URL=file:///home/cory/Downloads/jack_113773_linux_x64.run +Time=2026,1,26,19,0,30.444,UTC +URL=file:///home/cory/Desktop/neovide.AppImage.zsync diff --git a/.config/kwriterc b/.config/kwriterc index f01d09f..4a5e2c9 100644 --- a/.config/kwriterc +++ b/.config/kwriterc @@ -34,6 +34,48 @@ Tab Double Click New Document=true Tab Middle Click Close Document=true Tabbar Tab Limit=0 +[KTextEditor Document] +Allow End of Line Detection=true +Auto Detect Indent=true +Auto Reload If Any External Changes Occurs=false +Auto Reload If State Is In Version Control=true +Auto Save=false +Auto Save Interval=0 +Auto Save On Focus Out=false +BOM=false +Backup Local=false +Backup Prefix= +Backup Remote=false +Backup Suffix=~ +Camel Cursor=true +Encoding=UTF-8 +End of Line=0 +Indent On Backspace=true +Indent On Tab=true +Indent On Text Paste=true +Indentation Mode=normal +Indentation Width=4 +Keep Extra Spaces=false +Line Length Limit=10000 +Newline at End of File=true +On-The-Fly Spellcheck=false +Overwrite Mode=false +PageUp/PageDown Moves Cursor=false +Remove Spaces=1 +ReplaceTabsDyn=true +Show Spaces=0 +Show Tabs=true +Smart Home=true +Swap Directory= +Swap File Mode=1 +Swap Sync Interval=15 +Tab Handling=2 +Tab Width=4 +Trailing Marker Size=1 +Use Editor Config=true +Word Wrap=false +Word Wrap Column=80 + [KTextEditor Renderer] Animate Bracket Matching=false Auto Color Theme Selection=true @@ -41,7 +83,7 @@ Color Theme=Breeze Light Line Height Multiplier=1 Show Indentation Lines=false Show Whole Bracket Expression=false -Text Font=Noto Sans Mono,12,-1,5,400,0,0,0,0,0,0,0,0,0,0,1 +Text Font=Noto Sans Mono,14,-1,5,400,0,0,0,0,0,0,0,0,0,0,1 Text Font Features= Word Wrap Marker=false @@ -103,12 +145,12 @@ Smart Copy Cut=true Statusbar Line Column Compact Mode=true Text Drag And Drop=true User Sets Of Chars To Enclose Selection= -Vi Input Mode Steal Keys=false +Vi Input Mode Steal Keys=true Vi Relative Line Numbers=false Word Completion=true Word Completion Minimal Word Length=3 Word Completion Remove Tail=true [MainWindow] -2560x1440 screen: Height=807 -2560x1440 screen: Width=1302 +2560x1440 screen: Height=626 +2560x1440 screen: Width=955 diff --git a/.config/mimeapps.list b/.config/mimeapps.list index f2180e7..4c0021e 100644 --- a/.config/mimeapps.list +++ b/.config/mimeapps.list @@ -1,25 +1,41 @@ [Added Associations] +application/json=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop; application/vnd.debian.binary-package=org.kde.discover.desktop; application/vnd.microsoft.portable-executable=com.usebottles.bottles.desktop;wine.desktop;winetricks.desktop;org.winehq.Wine.desktop; application/x-blender=Blender.desktop; +application/x-docbook+xml=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop; application/x-msdownload=com.usebottles.bottles.desktop;wine.desktop; application/x-msi=com.usebottles.bottles.desktop;wine.desktop;winetricks.desktop; application/x-nes-rom=nestopia.desktop; +application/x-yaml=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop; +application/x-zerosize=Neovim.desktop; application/zip=org.kde.ark.desktop; +text/markdown=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop; +text/plain=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop;com.vscodium.codium.desktop; text/rust=neovide.desktop; -x-scheme-handler/http=app.zen_browser.zen.desktop; -x-scheme-handler/https=app.zen_browser.zen.desktop; +text/x-cmake=nvim_nvim.desktop;org.kde.kwrite.desktop;org.kde.kate.desktop; +x-scheme-handler/http=librewolf.desktop;app.zen_browser.zen.desktop; +x-scheme-handler/https=librewolf.desktop;app.zen_browser.zen.desktop; +x-scheme-handler/nxm=io.github.limo_app.limo.desktop; [Default Applications] +application/json=nvim_nvim.desktop; application/vnd.debian.binary-package=org.kde.discover.desktop; application/vnd.microsoft.portable-executable=com.usebottles.bottles.desktop; application/x-blender=Blender.desktop; +application/x-docbook+xml=nvim_nvim.desktop; application/x-msdownload=com.usebottles.bottles.desktop; application/x-msi=com.usebottles.bottles.desktop; application/x-nes-rom=nestopia.desktop; +application/x-yaml=nvim_nvim.desktop; +application/x-zerosize=Neovim.desktop; application/zip=org.kde.ark.desktop; +text/markdown=nvim_nvim.desktop; +text/plain=nvim_nvim.desktop; text/rust=neovide.desktop; +text/x-cmake=nvim_nvim.desktop; x-scheme-handler/betterdiscord=discord.desktop x-scheme-handler/discord-1361252452329848892=discord-1361252452329848892.desktop -x-scheme-handler/http=app.zen_browser.zen.desktop; -x-scheme-handler/https=app.zen_browser.zen.desktop; +x-scheme-handler/http=librewolf.desktop; +x-scheme-handler/https=librewolf.desktop; +x-scheme-handler/nxm=modorganizer2-nxm-handler.desktop diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua index 90a2648..2e056e1 100755 --- a/.config/nvim/init.lua +++ b/.config/nvim/init.lua @@ -3,18 +3,19 @@ vim.g.mapleader = '' vim.o.number = true vim.o.relativenumber = false vim.o.termguicolors = true -vim.o.background = light +vim.o.background = "light" +vim.o.background = "dark" vim.o.wrap = true vim.o.tabstop = 4 vim.o.shiftwidth = 4 -vim.o.clipboard = 'unnamedplus' +vim.o.clipboard = 'unnamed' vim.o.mouse = 'a' vim.o.ignorecase = true vim.o.smartcase = true vim.o.smartindent = false vim.o.undofile = true vim.o.swapfile = true -vim.o.autochdir = false +vim.o.autochdir = true vim.o.scrolloff = 15 --vim.o.winborder = "solid" vim.o.cursorline = true @@ -32,11 +33,13 @@ vim.api.nvim_set_hl(0, 'Pmenu', { bg = 'none' }) --Neovide Options vim.o.guifont = "CaskaydiaMono Nerd Font:h18" -vim.g.neovide_window_blurred = false -vim.g.neovide_opacity = 1.0 +vim.g.neovide_window_blurred = true +vim.g.neovide_opacity = 0.7 vim.g.neovide_normal_opacity = 1.0 -vim.g.neovide_background_color = "orange" vim.g.neovide_cursor_animation_length = 0.08 +if vim.g.neovide then + vim.o.background = 'dark' +end -- Autocompletion vim.diagnostic.config({ virtual_text = { current_line = true } }) diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json index 4d04e94..1b4e27d 100644 --- a/.config/nvim/lazy-lock.json +++ b/.config/nvim/lazy-lock.json @@ -1,40 +1,42 @@ { "Comment.nvim": { "branch": "master", "commit": "e30b7f2008e52442154b66f7c519bfd2f1e32acb" }, - "alpha-nvim": { "branch": "main", "commit": "a35468cd72645dbd52c0624ceead5f301c566dff" }, + "alpha-nvim": { "branch": "main", "commit": "3979b01cb05734331c7873049001d3f2bb8477f4" }, + "base16-nvim": { "branch": "master", "commit": "5f140bdbb07c0767f0785c71407330c8c96e9bcf" }, "blink-cmp-spell": { "branch": "master", "commit": "2bd0e0d5e7735c047e72b6918a0458f3e8fadaba" }, - "blink.cmp": { "branch": "main", "commit": "022521a8910a5543b0251b21c9e1a1e989745796" }, - "everforest-nvim": { "branch": "main", "commit": "2eb7c348f880ba93de4d98cae049c9441f5d4d49" }, + "blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" }, + "everforest-nvim": { "branch": "main", "commit": "557bce922401e247a596583679bc181d4d688554" }, "focus.nvim": { "branch": "main", "commit": "0f51cb7ff2640737858249015b6af0ea6cb28904" }, - "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, - "fzf-lua": { "branch": "main", "commit": "ce5a5fa2902933e7b4563ca78210254169463cb6" }, + "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, + "fzf-lua": { "branch": "main", "commit": "d59f857c76eb474ec00debcf043f14fd001805cc" }, "indent-blankline.nvim": { "branch": "master", "commit": "005b56001b2cb30bfa61b7986bc50657816ba4ba" }, - "lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" }, - "lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" }, - "live-preview.nvim": { "branch": "main", "commit": "35ddc5a99499d1d2f4adefb7e92d0c537353fdec" }, + "lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" }, + "lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" }, + "live-preview.nvim": { "branch": "main", "commit": "f056b4b859d54595afce53e67129f7684380d3ba" }, "lualine-macro-recording.nvim": { "branch": "main", "commit": "e2dcf63ba74e6111b53e1520a4f8a17a3d7427a1" }, - "lualine.nvim": { "branch": "master", "commit": "0c6cca9f2c63dadeb9225c45bc92bb95a151d4af" }, - "mason.nvim": { "branch": "main", "commit": "8024d64e1330b86044fed4c8494ef3dcd483a67c" }, - "maximizer.nvim": { "branch": "main", "commit": "8e2e71ce705400b10ef02a25ef2528bb078514a2" }, - "mini.icons": { "branch": "main", "commit": "397ed3807e96b59709ef3292f0a3e253d5c1dc0a" }, - "mini.pick": { "branch": "main", "commit": "be6490ae9d7038b9f5185d95a8060054f9b23666" }, - "mini.surround": { "branch": "main", "commit": "88c52297ed3e69ecf9f8652837888ecc727a28ee" }, - "noice.nvim": { "branch": "main", "commit": "0427460c2d7f673ad60eb02b35f5e9926cf67c59" }, - "nui.nvim": { "branch": "main", "commit": "7cd18e73cfbd70e1546931b7268b3eebaeff9391" }, - "nvim-autopairs": { "branch": "master", "commit": "4d74e75913832866aa7de35e4202463ddf6efd1b" }, - "nvim-lint": { "branch": "master", "commit": "cc26ae6a620298bb3f33b0e0681f99a10ae57781" }, - "nvim-lspconfig": { "branch": "master", "commit": "a182334ba933e58240c2c45e6ae2d9c7ae313e00" }, + "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, + "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, + "maximizer.nvim": { "branch": "main", "commit": "d565201bae4b6ca4328ecd693b21b77132bfe02f" }, + "mini.icons": { "branch": "main", "commit": "efc85e42262cd0c9e1fdbf806c25cb0be6de115c" }, + "mini.pick": { "branch": "main", "commit": "7c0a674f620ddc701903b887b2dade836b23ea79" }, + "mini.surround": { "branch": "main", "commit": "f9358544ed06bc10197e698b7fc8dc5963be3f4b" }, + "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, + "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, + "nvim-autopairs": { "branch": "master", "commit": "c2a0dd0d931d0fb07665e1fedb1ea688da3b80b4" }, + "nvim-lint": { "branch": "master", "commit": "ca6ea12daf0a4d92dc24c5c9ae22a1f0418ade37" }, + "nvim-lspconfig": { "branch": "master", "commit": "4044b8544a6cea57179d5a29c203b6b65d2b6ac4" }, "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, - "nvim-ts-autotag": { "branch": "main", "commit": "a1d526af391f6aebb25a8795cbc05351ed3620b5" }, - "nvim-web-devicons": { "branch": "master", "commit": "1fb58cca9aebbc4fd32b086cb413548ce132c127" }, - "oil.nvim": { "branch": "master", "commit": "08c2bce8b00fd780fb7999dbffdf7cd174e896fb" }, - "plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" }, - "snacks.nvim": { "branch": "main", "commit": "bc0630e43be5699bb94dadc302c0d21615421d93" }, + "nvim-ts-autotag": { "branch": "main", "commit": "db15f2e0df2f5db916e511e3fffb682ef2f6354f" }, + "nvim-web-devicons": { "branch": "master", "commit": "803353450c374192393f5387b6a0176d0972b848" }, + "oil.nvim": { "branch": "master", "commit": "f55b25e493a7df76371cfadd0ded5004cb9cd48a" }, + "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, + "project-cli-commands.nvim": { "branch": "main", "commit": "9a2a2fdfd38a3d71cc927e3a398ac0ddfa846b3d" }, + "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, "solarized.nvim": { "branch": "main", "commit": "c0dfe1cbfabd93b546baf5f1408f5df7e02e2050" }, - "telescope.nvim": { "branch": "master", "commit": "b4da76be54691e854d3e0e02c36b0245f945c2c7" }, + "telescope.nvim": { "branch": "master", "commit": "ad7d9580338354ccc136e5b8f0aa4f880434dcdc" }, "toggleterm.nvim": { "branch": "main", "commit": "9a88eae817ef395952e08650b3283726786fb5fb" }, - "tokyonight.nvim": { "branch": "main", "commit": "057ef5d260c1931f1dffd0f052c685dcd14100a3" }, - "twilight.nvim": { "branch": "main", "commit": "1584c0b0a979b71fd86b18d302ba84e9aba85b1b" }, + "tokyonight.nvim": { "branch": "main", "commit": "5da1b76e64daf4c5d410f06bcb6b9cb640da7dfd" }, + "twilight.nvim": { "branch": "main", "commit": "664e752f4a219801265cc3fc18782b457b58c1e1" }, "vim-illuminate": { "branch": "master", "commit": "0d1e93684da00ab7c057410fecfc24f434698898" }, - "which-key.nvim": { "branch": "main", "commit": "370ec46f710e058c9c1646273e6b225acf47cbed" }, - "yazi.nvim": { "branch": "main", "commit": "e2ddbaa88ec61d0b96e3d53ba851b0e7a0b36f14" } + "which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" }, + "yazi.nvim": { "branch": "main", "commit": "8992f08270a008ab7638ccfb0cf07bb6e9e69f5e" } } diff --git a/.config/nvim/lua/config/lazy.lua b/.config/nvim/lua/config/lazy.lua index c381a4b..40bf158 100644 --- a/.config/nvim/lua/config/lazy.lua +++ b/.config/nvim/lua/config/lazy.lua @@ -31,5 +31,5 @@ require("lazy").setup({ -- colorscheme that will be used when installing plugins. install = { colorscheme = { "habamax" } }, -- automatically check for plugin updates - checker = { enabled = true }, + checker = { enabled = true, notify = false }, }) diff --git a/.config/nvim/lua/plugins/alpha.lua b/.config/nvim/lua/plugins/alpha.lua index 7c8fe05..fdab641 100644 --- a/.config/nvim/lua/plugins/alpha.lua +++ b/.config/nvim/lua/plugins/alpha.lua @@ -5,27 +5,49 @@ return { 'nvim-lua/plenary.nvim', "nvim-telescope/telescope.nvim" }, + +-- dashboard.section.header.val = { +-- " ", +-- " ███████████ █████ ██", +-- " ███████████ █████ ", +-- " ████████████████ ███████████ ███ ███████", +-- " ████████████████ ████████████ █████ ██████████████", +-- " █████████████████████████████ █████ █████ ████ █████", +-- " ██████████████████████████████████ █████ █████ ████ █████", +-- " ██████ ███ █████████████████ ████ █████ █████ ████ ██████", +-- " ██████ ██ ███████████████ ██ █████████████████" +-- } + config = function () + -- local alpha = require("alpha") + -- local theta = require("alpha.themes.theta") + -- theta.header.val = { + -- "▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄", + -- "██ ▀██ ██ ▄▄▄██ ▄▄▄ ██ ███ █▄ ▄██ ▄▀▄ ██", + -- "██ █ █ ██ ▄▄▄██ ███ ███ █ ███ ███ █ █ ██", + -- "██ ██▄ ██ ▀▀▀██ ▀▀▀ ███▄▀▄██▀ ▀██ ███ ██", + -- "▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀" + -- } + -- theta.header.opts.hl = "Red" + -- alpha.setup(theta.config) + local alpha = require("alpha") local dashboard = require("alpha.themes.dashboard") dashboard.section.header.val = { - " ", - " ███╗ ██╗███████╗ ██████╗ ██╗ ██╗██╗███╗ ███╗ ", - " ████╗ ██║██╔════╝██╔═══██╗██║ ██║██║████╗ ████║ ", - " ██╔██╗ ██║█████╗ ██║ ██║██║ ██║██║██╔████╔██║ ", - " ██║╚██╗██║██╔══╝ ██║ ██║╚██╗ ██╔╝██║██║╚██╔╝██║ ", - " ██║ ╚████║███████╗╚██████╔╝ ╚████╔╝ ██║██║ ╚═╝ ██║ ", - " ╚═╝ ╚═══╝╚══════╝ ╚═════╝ ╚═══╝ ╚═╝╚═╝ ╚═╝ ", - " ", + "▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄", + "██ ▀██ ██ ▄▄▄██ ▄▄▄ ██ ███ █▄ ▄██ ▄▀▄ ██", + "██ █ █ ██ ▄▄▄██ ███ ███ █ ███ ███ █ █ ██", + "██ ██▄ ██ ▀▀▀██ ▀▀▀ ███▄▀▄██▀ ▀██ ███ ██", + "▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀" } dashboard.section.header.opts.hl = "Red" + dashboard.section.buttons.val = { - dashboard.button( "e", " > New file" , ":ene startinsert "), - dashboard.button( "f", " > Find file", ":cd $HOME | Telescope find_files"), - dashboard.button( "r", " > Recent" , ":Telescope oldfiles"), - dashboard.button( "s", " > Settings" , ":e $MYVIMRC | :cd %:p:h"), - dashboard.button( "q", " > Quit NVIM", ":qa"), + dashboard.button("", "󰊄 Recent files"), + dashboard.button("e", " New file", "ene "), + dashboard.button(",", "󰈞 Find file"), + dashboard.button("Alt-,", "󰈬 Find word"), } alpha.setup(dashboard.opts) end diff --git a/.config/nvim/lua/plugins/dankcolors.lua b/.config/nvim/lua/plugins/dankcolors.lua new file mode 100644 index 0000000..1d7d783 --- /dev/null +++ b/.config/nvim/lua/plugins/dankcolors.lua @@ -0,0 +1,91 @@ +return { + { + "RRethy/base16-nvim", + priority = 1000, + config = function() + require('base16-colorscheme').setup({ + base00 = '#141218', + base01 = '#141218', + base02 = '#5c6370', + base03 = '#5c6370', + base04 = '#abb2bf', + base05 = '#ffffff', + base06 = '#ffffff', + base07 = '#ffffff', + base08 = '#e06a5f', + base09 = '#e06a5f', + base0A = '#dfc9ff', + base0B = '#86e08b', + base0C = '#8b6ab5', + base0D = '#dfc9ff', + base0E = '#7c6acd', + base0F = '#7c6acd', + }) + + vim.api.nvim_set_hl(0, 'Visual', { + bg = '#5c6370', + fg = '#ffffff', + bold = true + }) + vim.api.nvim_set_hl(0, 'Statusline', { + bg = '#dfc9ff', + fg = '#141218', + }) + vim.api.nvim_set_hl(0, 'LineNr', { fg = '#5c6370' }) + vim.api.nvim_set_hl(0, 'CursorLineNr', { fg = '#8b6ab5', bold = true }) + + vim.api.nvim_set_hl(0, 'Statement', { + fg = '#7c6acd', + bold = true + }) + vim.api.nvim_set_hl(0, 'Keyword', { link = 'Statement' }) + vim.api.nvim_set_hl(0, 'Repeat', { link = 'Statement' }) + vim.api.nvim_set_hl(0, 'Conditional', { link = 'Statement' }) + + vim.api.nvim_set_hl(0, 'Function', { + fg = '#dfc9ff', + bold = true + }) + vim.api.nvim_set_hl(0, 'Macro', { + fg = '#dfc9ff', + italic = true + }) + vim.api.nvim_set_hl(0, '@function.macro', { link = 'Macro' }) + + vim.api.nvim_set_hl(0, 'Type', { + fg = '#8b6ab5', + bold = true, + italic = true + }) + vim.api.nvim_set_hl(0, 'Structure', { link = 'Type' }) + + vim.api.nvim_set_hl(0, 'String', { + fg = '#86e08b', + italic = true + }) + + vim.api.nvim_set_hl(0, 'Operator', { fg = '#abb2bf' }) + vim.api.nvim_set_hl(0, 'Delimiter', { fg = '#abb2bf' }) + vim.api.nvim_set_hl(0, '@punctuation.bracket', { link = 'Delimiter' }) + vim.api.nvim_set_hl(0, '@punctuation.delimiter', { link = 'Delimiter' }) + + vim.api.nvim_set_hl(0, 'Comment', { + fg = '#5c6370', + italic = true + }) + + local current_file_path = vim.fn.stdpath("config") .. "/lua/plugins/dankcolors.lua" + if not _G._matugen_theme_watcher then + local uv = vim.uv or vim.loop + _G._matugen_theme_watcher = uv.new_fs_event() + _G._matugen_theme_watcher:start(current_file_path, {}, vim.schedule_wrap(function() + local new_spec = dofile(current_file_path) + if new_spec and new_spec[1] and new_spec[1].config then + new_spec[1].config() + print("Theme reload") + end + end)) + end + end + } +} diff --git a/.config/nvim/lua/plugins/everforest.lua b/.config/nvim/lua/plugins/everforest.lua index bfeeda9..3043ca5 100644 --- a/.config/nvim/lua/plugins/everforest.lua +++ b/.config/nvim/lua/plugins/everforest.lua @@ -3,7 +3,7 @@ return { lazy = true, priority = 1000, config = function () - background = "soft" + background = "Hard" ui_contrast = "low" transparent = true end diff --git a/.config/nvim/lua/plugins/project-cli-commands.lua b/.config/nvim/lua/plugins/project-cli-commands.lua new file mode 100644 index 0000000..dd05b84 --- /dev/null +++ b/.config/nvim/lua/plugins/project-cli-commands.lua @@ -0,0 +1,45 @@ +return { + "dimaportenko/project-cli-commands.nvim", + + dependencies = { + "akinsho/toggleterm.nvim", + "nvim-telescope/telescope.nvim", + }, + + + keys = { + {"", "Telescope project_cli_commands open", mode = {"n","v","i","t"}, desc = "Open project commands list"}, + }, + + -- optional keymap config + config = function() + local OpenActions = require('project_cli_commands.open_actions') + local RunActions = require('project_cli_commands.actions') + + local config = { + -- Key mappings bound inside the telescope window + running_telescope_mapping = { + [''] = RunActions.exit_terminal, + [''] = RunActions.open_float, + [''] = RunActions.open_vertical, + [''] = RunActions.open_horizontal, + }, + open_telescope_mapping = { + { mode = 'i', key = '', action = OpenActions.execute_script_vertical }, + { mode = 'n', key = '', action = OpenActions.execute_script_vertical }, + { mode = 'i', key = '', action = OpenActions.execute_script }, + { mode = 'n', key = '', action = OpenActions.execute_script }, + { mode = 'i', key = '', action = OpenActions.execute_script_with_input }, + { mode = 'n', key = '', action = OpenActions.execute_script_with_input }, + { mode = 'i', key = '', action = OpenActions.copy_command_clipboard }, + { mode = 'n', key = '', action = OpenActions.copy_command_clipboard }, + { mode = 'i', key = '', action = OpenActions.execute_script_float }, + { mode = 'n', key = '', action = OpenActions.execute_script_float }, + { mode = 'i', key = '', action = OpenActions.execute_script_vertical }, + { mode = 'n', key = '', action = OpenActions.execute_script_vertical }, + } + } + + require('project_cli_commands').setup(config) + end +} diff --git a/.config/nvim/lua/plugins/solarized.lua b/.config/nvim/lua/plugins/solarized.lua index d460772..103bddb 100644 --- a/.config/nvim/lua/plugins/solarized.lua +++ b/.config/nvim/lua/plugins/solarized.lua @@ -6,7 +6,7 @@ return { opts = {}, config = function(_, opts) vim.o.termguicolors = true - vim.o.background = 'light' + -- vim.o.background = 'light' require('solarized').setup(opts) vim.cmd.colorscheme 'solarized' end, diff --git a/.config/nvim/lua/plugins/telescope.lua b/.config/nvim/lua/plugins/telescope.lua index 32ff300..fe11d16 100644 --- a/.config/nvim/lua/plugins/telescope.lua +++ b/.config/nvim/lua/plugins/telescope.lua @@ -3,8 +3,17 @@ return { keys = { {',', "Telescope find_files", desc = "Telescope find files"}, {'', "Telescope live_grep", desc = "Telescope live grep"}, - {'o', "Telescope oldfiles", desc = "Telescope live grep"} + {'', "Telescope oldfiles", desc = "Telescope live grep"} }, requires = { "nvim-lua/plenary.nvim", "BurntSushi/ripgrep" }, - opts = {} + opts = { + defaults = { + mappings = { + i = { + [""] = "move_selection_previous", + [""] = "move_selection_next", + } + } + } + } } diff --git a/.config/partitionmanagerrc b/.config/partitionmanagerrc index 6b479c4..af3f90f 100644 --- a/.config/partitionmanagerrc +++ b/.config/partitionmanagerrc @@ -4,7 +4,7 @@ firstRun=false treeLogColumnWidths=49,192,800 [applyProgressDialog] -Geometry=\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x00\xbc\x00\x00\x00\xa4\x00\x00\x03\x9f\x00\x00\x02A\x00\x00\x00\xbc\x00\x00\x00\xa4\x00\x00\x03\x9f\x00\x00\x02A\x00\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x00\xbc\x00\x00\x00\xa4\x00\x00\x03\x9f\x00\x00\x02A +Geometry=\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xe3\x00\x00\x02\x18\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xe3\x00\x00\x02\x18\x00\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xe3\x00\x00\x02\x18 [resizeDialog] Geometry=\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\xf5\x00\x00\x01O\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\xf5\x00\x00\x01O\x00\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\xf5\x00\x00\x01O diff --git a/.config/plasma-org.kde.plasma.desktop-appletsrc b/.config/plasma-org.kde.plasma.desktop-appletsrc index 5b5847e..c8039dc 100644 --- a/.config/plasma-org.kde.plasma.desktop-appletsrc +++ b/.config/plasma-org.kde.plasma.desktop-appletsrc @@ -1,12 +1,55 @@ [ActionPlugins][0] +MiddleButton;NoModifier=switchwindow RightButton;NoModifier=org.kde.contextmenu +[ActionPlugins][0][MiddleButton;NoModifier] +_add panel=false +_context=true +_display_settings=true +_lock_screen=false +_logout=false +_open_terminal=false +_run_command=false +_sep1=true +_sep2=true +_sep3=true +_sep4=true +_wallpaper=true +add widgets=false +configure=true +configure shortcuts=false +desktop edit mode=true +manage activities=true +mode=1 +remove=true +showAppsByName=true + +[ActionPlugins][0][RightButton;NoModifier] +_add panel=false +_context=true +_display_settings=true +_lock_screen=false +_logout=false +_open_terminal=false +_run_command=false +_sep1=true +_sep2=true +_sep3=true +_sep4=true +_wallpaper=true +add widgets=false +configure=true +configure shortcuts=false +desktop edit mode=true +manage activities=true +remove=true + [ActionPlugins][1] RightButton;NoModifier=org.kde.contextmenu -[Containments][1] -ItemGeometries-2560x1440= -ItemGeometriesHorizontal= +[Containments][37] +ItemGeometries-2560x1440=Applet-83:432,976,464,320,0; +ItemGeometriesHorizontal=Applet-83:432,976,464,320,0; activityId=dc7cfc1e-da2d-4ff2-977f-a1a4449080f6 formfactor=0 immutability=1 @@ -15,15 +58,31 @@ location=0 plugin=org.kde.plasma.folder wallpaperplugin=org.kde.image -[Containments][1][General] -positions={"2560x1440":["12","23","desktop:/daily.txt","11","22"]} +[Containments][37][Applets][83] +immutability=1 +plugin=org.kde.plasma.yesplaymusic-lyrics + +[Containments][37][Applets][83][Configuration][Appearance] +text_color=#ffffff +text_font=Noto Sans,10,-1,0,400,0,0,0,0,0,0,0,0,0,0,1 + +[Containments][37][Applets][83][Configuration][ConfigDialog] +DialogHeight=540 +DialogWidth=720 + +[Containments][37][ConfigDialog] +DialogHeight=810 +DialogWidth=1334 + +[Containments][37][General] +positions={"2560x1440":["12","23","desktop:/medicine.md","10","22","desktop:/accounts to add.md","11","22"]} sortMode=-1 -[Containments][1][Wallpaper][org.kde.image][General] -Image=file:///home/cory/.wallpapers/sky.jpg +[Containments][37][Wallpaper][org.kde.image][General] +Image=/home/cory/.wallpapers/sunset between the clouds by exobiologyart.jpg SlidePaths=/usr/share/wallpapers/ -[Containments][2] +[Containments][38] activityId= formfactor=2 immutability=1 @@ -32,201 +91,239 @@ location=4 plugin=org.kde.panel wallpaperplugin=org.kde.image -[Containments][2][Applets][21] -immutability=1 -plugin=org.kde.plasma.digitalclock - -[Containments][2][Applets][21][Configuration] -popupHeight=400 -popupWidth=560 - -[Containments][2][Applets][21][Configuration][Appearance] -fontWeight=400 - -[Containments][2][Applets][27] -immutability=1 -plugin=org.kde.plasma.panelspacer - -[Containments][2][Applets][28] -immutability=1 -plugin=org.kde.plasma.panelspacer - -[Containments][2][Applets][29] -immutability=1 -plugin=org.kde.plasma.colorpicker - -[Containments][2][Applets][29][Configuration] -PreloadWeight=55 -popupHeight=325 -popupWidth=324 - -[Containments][2][Applets][29][Configuration][General] -history=#fdf6e3 - -[Containments][2][Applets][31] -immutability=1 -plugin=com.dv.fokus - -[Containments][2][Applets][31][Configuration] -PreloadWeight=55 -popupHeight=324 -popupWidth=324 - -[Containments][2][Applets][33] +[Containments][38][Applets][39] immutability=1 plugin=org.kde.plasma.kickoff -[Containments][2][Applets][33][Configuration] +[Containments][38][Applets][39][Configuration] PreloadWeight=100 -popupHeight=508 -popupWidth=647 +popupHeight=561 +popupWidth=689 -[Containments][2][Applets][33][Configuration][ConfigDialog] -DialogHeight=630 -DialogWidth=810 - -[Containments][2][Applets][33][Configuration][General] +[Containments][38][Applets][39][Configuration][General] favoritesPortedToKAstats=true -icon=start-here-kubuntu -systemFavorites=suspend\\,hibernate\\,reboot\\,shutdown -[Containments][2][Applets][4] +[Containments][38][Applets][40] immutability=1 plugin=org.kde.plasma.pager -[Containments][2][Applets][4][Configuration][ConfigDialog] -DialogHeight=630 -DialogWidth=810 +[Containments][38][Applets][40][Configuration][ConfigDialog] +DialogHeight=540 +DialogWidth=720 -[Containments][2][Applets][4][Configuration][General] +[Containments][38][Applets][40][Configuration][General] showWindowIcons=true -[Containments][2][Applets][5] +[Containments][38][Applets][41] immutability=1 plugin=org.kde.plasma.icontasks -[Containments][2][Applets][5][Configuration][General] -launchers=preferred://browser,applications:discord.desktop,applications:steam.desktop,applications:spotify.desktop,preferred://filemanager,applications:org.kde.konsole.desktop +[Containments][38][Applets][41][Configuration][ConfigDialog] +DialogHeight=540 +DialogWidth=720 -[Containments][2][Applets][6] +[Containments][38][Applets][41][Configuration][General] +launchers=[dc7cfc1e-da2d-4ff2-977f-a1a4449080f6]\napplications:app.zen_browser.zen.desktop,[dc7cfc1e-da2d-4ff2-977f-a1a4449080f6]\napplications:discord.desktop,[dc7cfc1e-da2d-4ff2-977f-a1a4449080f6]\napplications:steam.desktop,applications:spotify.desktop,preferred://filemanager,applications:com.mitchellh.ghostty.desktop,[18f515e7-cf8b-4327-80ee-9f74afa20678]\napplications:com.google.Chrome.desktop +showOnlyCurrentDesktop=false + +[Containments][38][Applets][42] immutability=1 plugin=org.kde.plasma.marginsseparator -[Containments][2][Applets][7] +[Containments][38][Applets][43] activityId= formfactor=0 immutability=1 lastScreen=-1 location=0 plugin=org.kde.plasma.systemtray -popupHeight=432 -popupWidth=432 +popupHeight=446 +popupWidth=447 wallpaperplugin=org.kde.image -[Containments][2][Applets][7][Applets][10] -immutability=1 -plugin=org.kde.plasma.clipboard - -[Containments][2][Applets][7][Applets][11] -immutability=1 -plugin=org.kde.plasma.devicenotifier - -[Containments][2][Applets][7][Applets][11][Configuration] -PreloadWeight=100 - -[Containments][2][Applets][7][Applets][12][Configuration] -PreloadWeight=42 - -[Containments][2][Applets][7][Applets][13][Configuration] -PreloadWeight=42 - -[Containments][2][Applets][7][Applets][14][Configuration] -PreloadWeight=42 - -[Containments][2][Applets][7][Applets][15] +[Containments][38][Applets][43][Applets][44] immutability=1 plugin=org.kde.plasma.notifications -[Containments][2][Applets][7][Applets][15][Configuration] -PreloadWeight=100 +[Containments][38][Applets][43][Applets][44][Configuration] +PreloadWeight=80 -[Containments][2][Applets][7][Applets][16] +[Containments][38][Applets][43][Applets][45][Configuration] +PreloadWeight=42 + +[Containments][38][Applets][43][Applets][46][Configuration] +PreloadWeight=42 + +[Containments][38][Applets][43][Applets][47][Configuration] +PreloadWeight=42 + +[Containments][38][Applets][43][Applets][48] immutability=1 plugin=org.kde.plasma.printmanager -[Containments][2][Applets][7][Applets][17][Configuration] +[Containments][38][Applets][43][Applets][49][Configuration] PreloadWeight=42 -[Containments][2][Applets][7][Applets][18][Configuration] -PreloadWeight=42 - -[Containments][2][Applets][7][Applets][19] +[Containments][38][Applets][43][Applets][50] immutability=1 -plugin=org.kde.kscreen +plugin=org.kde.plasma.devicenotifier -[Containments][2][Applets][7][Applets][20] -immutability=1 -plugin=org.kde.plasma.volume - -[Containments][2][Applets][7][Applets][20][Configuration] -PreloadWeight=95 - -[Containments][2][Applets][7][Applets][20][Configuration][General] -currentTab=streams -migrated=true - -[Containments][2][Applets][7][Applets][23] -immutability=1 -plugin=org.kde.plasma.battery - -[Containments][2][Applets][7][Applets][23][Configuration] +[Containments][38][Applets][43][Applets][50][Configuration] PreloadWeight=100 -[Containments][2][Applets][7][Applets][24] +[Containments][38][Applets][43][Applets][51] immutability=1 -plugin=org.kde.plasma.brightness +plugin=org.kde.plasma.clipboard -[Containments][2][Applets][7][Applets][24][Configuration] -PreloadWeight=0 +[Containments][38][Applets][43][Applets][51][Configuration] +PreloadWeight=60 -[Containments][2][Applets][7][Applets][25] -immutability=1 -plugin=org.kde.plasma.bluetooth - -[Containments][2][Applets][7][Applets][25][Configuration] -PreloadWeight=81 - -[Containments][2][Applets][7][Applets][26] -immutability=1 -plugin=org.kde.plasma.networkmanagement - -[Containments][2][Applets][7][Applets][26][Configuration] -PreloadWeight=55 - -[Containments][2][Applets][7][Applets][32][Configuration] -PreloadWeight=42 - -[Containments][2][Applets][7][Applets][8] +[Containments][38][Applets][43][Applets][52] immutability=1 plugin=org.kde.kdeconnect -[Containments][2][Applets][7][Applets][9] +[Containments][38][Applets][43][Applets][53] immutability=1 plugin=org.kde.plasma.cameraindicator -[Containments][2][Applets][7][ConfigDialog] -DialogHeight=630 -DialogWidth=810 +[Containments][38][Applets][43][Applets][54][Configuration] +PreloadWeight=42 -[Containments][2][Applets][7][General] -extraItems=org.kde.plasma.bluetooth,org.kde.plasma.cameraindicator,org.kde.plasma.clipboard,org.kde.plasma.devicenotifier,org.kde.plasma.networkmanagement,org.kde.plasma.notifications,org.kde.kscreen,org.kde.plasma.volume,org.kde.plasma.brightness,org.kde.plasma.battery,org.kde.plasma.printmanager,org.kde.kupapplet,org.kde.kdeconnect -hiddenItems=org.kde.plasma.brightness,org.kde.kdeconnect,org.kde.plasma.printmanager,Xwayland Video Bridge_pipewireToXProxy,ibus-ui-gtk3 -knownItems=org.kde.plasma.battery,org.kde.plasma.bluetooth,org.kde.plasma.brightness,org.kde.plasma.cameraindicator,org.kde.plasma.clipboard,org.kde.plasma.devicenotifier,org.kde.plasma.keyboardindicator,org.kde.plasma.keyboardlayout,org.kde.plasma.manage-inputmethod,org.kde.plasma.networkmanagement,org.kde.plasma.notifications,org.kde.plasma.printmanager,org.kde.plasma.vault,org.kde.plasma.weather,org.kde.kscreen,org.kde.plasma.mediacontroller,org.kde.plasma.volume,org.kde.kupapplet,org.kde.kdeconnect -shownItems=org.kde.plasma.battery +[Containments][38][Applets][43][Applets][55][Configuration] +PreloadWeight=42 -[Containments][2][General] -AppletOrder=33;4;27;5;28;6;7;29;31;21 +[Containments][38][Applets][43][Applets][56][Configuration] +PreloadWeight=42 + +[Containments][38][Applets][43][Applets][59] +immutability=1 +plugin=org.kde.plasma.networkmanagement + +[Containments][38][Applets][43][Applets][60] +immutability=1 +plugin=org.kde.plasma.bluetooth + +[Containments][38][Applets][43][Applets][60][Configuration] +PreloadWeight=3 + +[Containments][38][Applets][43][Applets][61][Configuration] +PreloadWeight=42 + +[Containments][38][Applets][43][Applets][62] +immutability=1 +plugin=org.kde.plasma.brightness + +[Containments][38][Applets][43][Applets][62][Configuration] +PreloadWeight=0 + +[Containments][38][Applets][43][Applets][63] +immutability=1 +plugin=org.kde.plasma.battery + +[Containments][38][Applets][43][Applets][63][Configuration] +PreloadWeight=0 + +[Containments][38][Applets][43][ConfigDialog] +DialogHeight=540 +DialogWidth=720 + +[Containments][38][Applets][43][General] +extraItems=org.kde.plasma.notifications,org.kde.plasma.printmanager,org.kde.plasma.devicenotifier,org.kde.kupapplet,org.kde.plasma.cameraindicator,org.kde.kdeconnect,org.kde.plasma.brightness,org.kde.plasma.battery,org.kde.plasma.networkmanagement,org.kde.plasma.clipboard,org.kde.plasma.bluetooth +hiddenItems=org.kde.kdeconnect,ibus-ui-gtk3,org.kde.plasma.brightness,org.kde.plasma.networkmanagement,org.kde.plasma.clipboard +knownItems=org.kde.plasma.notifications,org.kde.plasma.battery,org.kde.plasma.weather,org.kde.plasma.vault,org.kde.plasma.bluetooth,org.kde.plasma.keyboardindicator,org.kde.plasma.networkmanagement,org.kde.plasma.printmanager,org.kde.plasma.manage-inputmethod,org.kde.plasma.devicenotifier,org.kde.plasma.clipboard,org.kde.kupapplet,org.kde.kdeconnect,org.kde.plasma.brightness,org.kde.plasma.cameraindicator,org.kde.plasma.keyboardlayout,org.kde.plasma.mediacontroller,org.kde.plasma.volume,org.kde.kscreen +shownItems=org.kde.plasma.battery,org.kde.plasma.bluetooth + +[Containments][38][Applets][57] +immutability=1 +plugin=org.kde.plasma.digitalclock + +[Containments][38][Applets][57][Configuration] +PreloadWeight=95 +popupHeight=484 +popupWidth=560 + +[Containments][38][Applets][64] +immutability=1 +plugin=org.kde.plasma.panelspacer + +[Containments][38][Applets][65] +immutability=1 +plugin=org.kde.plasma.panelspacer + +[Containments][38][Applets][66] +immutability=1 +plugin=org.kde.plasma.colorpicker + +[Containments][38][Applets][66][Configuration] +PreloadWeight=65 +popupHeight=324 +popupWidth=324 + +[Containments][38][Applets][66][Configuration][General] +history=#69a444 + +[Containments][38][Applets][88] +immutability=1 +plugin=org.kde.plasma.systemmonitor.memory + +[Containments][38][Applets][88][Configuration] +CurrentPreset=org.kde.plasma.systemmonitor +PreloadWeight=75 +popupHeight=234 +popupWidth=238 + +[Containments][38][Applets][88][Configuration][Appearance] +chartFace=org.kde.ksysguard.piechart +title=Memory Usage + +[Containments][38][Applets][88][Configuration][ConfigDialog] +DialogHeight=540 +DialogWidth=720 + +[Containments][38][Applets][88][Configuration][SensorColors] +memory/physical/used=114,155,121 + +[Containments][38][Applets][88][Configuration][Sensors] +highPrioritySensorIds=["memory/physical/used"] +lowPrioritySensorIds=["memory/physical/total"] +totalSensors=["memory/physical/usedPercent"] + +[Containments][38][Applets][90] +immutability=1 +plugin=com.dv.fokus + +[Containments][38][Applets][90][Configuration] +PreloadWeight=55 +popupHeight=324 +popupWidth=324 + +[Containments][38][General] +AppletOrder=39;88;40;64;41;65;42;43;66;90;57 + +[Containments][89] +ItemGeometries-2560x1440= +ItemGeometriesHorizontal= +activityId=18f515e7-cf8b-4327-80ee-9f74afa20678 +formfactor=0 +immutability=1 +lastScreen=0 +location=0 +plugin=org.kde.plasma.folder +wallpaperplugin=org.kde.image + +[Containments][89][ConfigDialog] +DialogHeight=540 +DialogWidth=720 + +[Containments][89][General] +positions={"0x0":["1","23"]} +sortMode=-1 +url=file:///home/cory/Work + +[Containments][89][Wallpaper][org.kde.image][General] +Image=/home/cory/.wallpapers/sky.jpg +SlidePaths=/usr/share/wallpapers/ [ScreenMapping] -itemsOnDisabledScreens= -screenMapping=desktop:/2ce5a999-22a5-497b-8c25-152f7a1f1a98.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20230801_160336.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220423_212529.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/barb.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220306_143904.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/daily.txt,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/6d8433f9-9bac-4307-b506-cf0a730b2c94.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-09-15-07-45-582.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20231001_153549.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/222926ad-3eab-4ce2-8623-d35bfcf44781.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-12-23-21-09-44-698.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20210602_151020.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_8885.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_2603.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/cachedImage.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/433f864a-a982-4669-a702-330bc5a0151e.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_4330.mov,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220401_151416.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20240809_011454.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3850.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20210829_162122.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220427_154834.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_5222.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-19-16-41-53-282.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3815.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/unnamed.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/1dc8208e-3767-4be7-92bc-c378453b4301.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/18966fe6-caa3-4852-abba-53c498ae2ae6.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3816.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-07-24-20-16-52-708.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_2205.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-09-15-07-42-442.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/ab5ff78b-84c1-457a-acbb-6569f9519c2f.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6 +itemsOnDisabledScreens=0,18f515e7-cf8b-4327-80ee-9f74afa20678,3,desktop:/medicine.md,desktop:/c-project,desktop:/accounts to add.md +screenMapping=desktop:/ab5ff78b-84c1-457a-acbb-6569f9519c2f.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-09-15-07-42-442.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/Text File.txt,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/cachedImage.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20210602_151020.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20210829_162122.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3815.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/daewfr9-978729bb-070b-4c48-b877-7e13529ba580.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220401_151416.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/222926ad-3eab-4ce2-8623-d35bfcf44781.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3850.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/1dc8208e-3767-4be7-92bc-c378453b4301.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_8885.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_5222.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/unnamed.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-12-23-21-09-44-698.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220306_143904.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/sunset between the clouds.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_2603.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_4330.mov,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/foods.csv (1),0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/6d8433f9-9bac-4307-b506-cf0a730b2c94.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220427_154834.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/433f864a-a982-4669-a702-330bc5a0151e.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20230801_160336.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_2205.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-07-24-20-16-52-708.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/Ubunchu_English_01_RtL_Edition_by_C_quel.pdf,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-09-15-07-45-582.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/18966fe6-caa3-4852-abba-53c498ae2ae6.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/medicine.md,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/fitbook.sqlite (1),0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20220423_212529.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20231001_153549.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_3816.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/barb.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/accounts to add.md,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2024-05-19-16-41-53-282.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/FSCK0000.REC,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/diary.csv (1),0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/2ce5a999-22a5-497b-8c25-152f7a1f1a98.png,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6,desktop:/IMG_20240809_011454.jpg,0,dc7cfc1e-da2d-4ff2-977f-a1a4449080f6 diff --git a/.config/plasmanotifyrc b/.config/plasmanotifyrc index 2a31ece..348c065 100644 --- a/.config/plasmanotifyrc +++ b/.config/plasmanotifyrc @@ -1,5 +1,23 @@ +[Applications][com.nextcloud.desktopclient.nextcloud] +Seen=true + [Applications][com.usebottles.bottles] Seen=true [Applications][discord] Seen=true + +[Applications][firefox_firefox] +Seen=true + +[Applications][google-chrome] +Seen=true + +[Applications][heroic] +Seen=true + +[Applications][librewolf] +Seen=true + +[Applications][vs-launcher] +Seen=true diff --git a/.config/plasmarc b/.config/plasmarc index 8b5c43c..4633357 100644 --- a/.config/plasmarc +++ b/.config/plasmarc @@ -1,5 +1,5 @@ [Theme] -name=leaf-dark +name=breeze-dark [Wallpapers] -usersWallpapers=/home/cory/.wallpapers/sky.jpg +usersWallpapers=/home/cory/.wallpapers/sky.jpg,/home/cory/.wallpapers/sunset between the clouds by exobiologyart.jpg diff --git a/.config/plasmashellrc b/.config/plasmashellrc index 573012a..deaa346 100644 --- a/.config/plasmashellrc +++ b/.config/plasmashellrc @@ -1,9 +1,8 @@ -[PlasmaTransientsConfig] -PreloadWeight=84 - [PlasmaViews][Panel 2] +alignment=132 floating=1 panelLengthMode=2 +panelOpacity=0 [PlasmaViews][Panel 2][Defaults] maxLength=1566 @@ -14,5 +13,18 @@ thickness=44 maxLength=1566 minLength=1562 +[PlasmaViews][Panel 38] +floating=1 +panelLengthMode=2 + +[PlasmaViews][Panel 38][Defaults] +maxLength=1429 +minLength=1427 +thickness=48 + +[PlasmaViews][Panel 38][Horizontal2560] +maxLength=1429 +minLength=1427 + [Updates] performed=/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/00-start-here-2.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/containmentactions_middlebutton.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/digitalclock_migrate_font_settings.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/digitalclock_migrate_showseconds_setting.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/digitalclock_rename_timezonedisplay_key.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/folderview_fix_recursive_screenmapping.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/keyboardlayout_migrateiconsetting.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/keyboardlayout_remove_shortcut.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/klipper_clear_config.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/maintain_existing_desktop_icon_sizes.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/mediaframe_migrate_useBackground_setting.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/migrate_font_weights.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/move_desktop_layout_config.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/no_middle_click_paste_on_panels.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/systemloadviewer_systemmonitor.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/taskmanager_configUpdate_wheelEnabled.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/unlock_widgets.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/kicker-kickoff-icon.js diff --git a/.config/powerdevilrc b/.config/powerdevilrc index 675c771..c63bba1 100644 --- a/.config/powerdevilrc +++ b/.config/powerdevilrc @@ -5,6 +5,10 @@ AutoSuspendIdleTimeoutSec=1800 InhibitScreenManagement=false InhibitSuspend=false +[Activities][18f515e7-cf8b-4327-80ee-9f74afa20678] +InhibitScreenManagement=false +InhibitSuspend=false + [Activities][5ec0183d-c2cf-482c-b224-e28bffad138c] InhibitScreenManagement=false InhibitSuspend=false @@ -12,3 +16,6 @@ InhibitSuspend=false [Activities][ea1e4e8d-678f-4685-a83f-438525d44bb7] InhibitScreenManagement=false InhibitSuspend=false + +[Inhibitions] +BlockedInhibitions=librewolf:Playing audio diff --git a/.config/session/kwin_saved at previous logout_ b/.config/session/kwin_saved at previous logout_ new file mode 100644 index 0000000..2c49074 --- /dev/null +++ b/.config/session/kwin_saved at previous logout_ @@ -0,0 +1,29 @@ +[Session] +active=-1 +activities1= +count=1 +desktop=1 +desktop1=1 +fsrestore1=0,0,0,0 +fullscreen1=0 +geometry1=0,99,100,100 +iconified1=false +keepBelow1=false +maximize1=0 +opacity1=0 +resourceClass1=xwaylandvideobridge +resourceName1=xwaylandvideobridge +restore1=0,99,1,1 +sessionId1=10d4dbe8ca000177051240600000020090002 +shaded1=false +shortcut1= +skipPager1=true +skipSwitcher1=true +skipTaskbar1=true +stackingOrder1=1 +staysOnTop1=false +sticky1=false +userNoBorder1=true +windowRole1= +windowType1=Normal +wmCommand1= diff --git a/.config/spectaclerc b/.config/spectaclerc index b242834..35ad13d 100644 --- a/.config/spectaclerc +++ b/.config/spectaclerc @@ -2,7 +2,12 @@ annotationToolType=3 highlighterStrokeWidth=30 +[GuiConfig] +quitAfterSaveCopyExport=true +videoIncludePointer=false + [ImageSave] +lastImageSaveLocation=file:///home/cory/Pictures/Screenshots/Screenshot_20260127_040240.png translatedScreenshotsFolder=Screenshots [VideoSave] diff --git a/.config/spicetify/CustomApps/marketplace-dist.zip b/.config/spicetify/CustomApps/marketplace-dist.zip deleted file mode 100644 index ba12cdb..0000000 Binary files a/.config/spicetify/CustomApps/marketplace-dist.zip and /dev/null differ diff --git a/.config/spicetify/CustomApps/marketplace/README.md b/.config/spicetify/CustomApps/marketplace/README.md deleted file mode 100644 index b680fcf..0000000 --- a/.config/spicetify/CustomApps/marketplace/README.md +++ /dev/null @@ -1,35 +0,0 @@ -# Spicetify Marketplace - -

- - - - - - - - - - - - -

- -Customize your Spotify client directly from within [Spicetify](https://github.com/spicetify/cli)! - -Marketplace allows you to **browse, download, and install** extensions, themes, and CSS snippets with ease. You can also browse custom apps, but will need to do some manual installation to get them working. - -Made with [Spicetify Creator](https://github.com/spicetify/spicetify-creator) - -Head to the [wiki](https://github.com/spicetify/marketplace/wiki) to get started! - ---- - -## Links -- [Overview](https://github.com/spicetify/marketplace/wiki) -- [Installation](https://github.com/spicetify/marketplace/wiki/Installation) -- [Publishing to Marketplace](https://github.com/spicetify/marketplace/wiki/Publishing-to-Marketplace) -- [Contributions](https://github.com/spicetify/marketplace/wiki/Contributions) -- [Development](https://github.com/spicetify/marketplace/wiki/Development) -- [Translating/Localizing Marketplace](https://github.com/spicetify/marketplace/wiki/Localizing-Marketplace) - diff --git a/.config/spicetify/CustomApps/marketplace/extension.js b/.config/spicetify/CustomApps/marketplace/extension.js deleted file mode 100644 index a45ba49..0000000 --- a/.config/spicetify/CustomApps/marketplace/extension.js +++ /dev/null @@ -1,10 +0,0 @@ -!async function(){for(;!Spicetify.React||!Spicetify.ReactDOM;)await new Promise(e=>setTimeout(e,10));(()=>{var _,M=e=>"string"==typeof e,U=()=>{let r,a;var e=new Promise((e,t)=>{r=e,a=t});return e.resolve=r,e.reject=a,e},F=e=>null==e?"":""+e,T=(e,t,r)=>{e.forEach(e=>{t[e]&&(r[e]=t[e])})},B=/###/g,V=e=>e&&-1!e||M(e),K=(e,t,r)=>{var a=M(t)?t.split("."):t;let s=0;for(;s{var{obj:e,k:t}=K(a,s,Object);if(void 0!==e||1===s.length)e[t]=n;else{let e=s[s.length-1],t=s.slice(0,s.length-1),r=K(a,t,Object);for(;void 0===r.obj&&t.length;)e=t[t.length-1]+"."+e,t=t.slice(0,t.length-1),(r=K(a,t,Object))?.obj&&void 0!==r.obj[r.k+"."+e]&&(r.obj=void 0);r.obj[r.k+"."+e]=n}},z=(e,t,r,a)=>{var{obj:e,k:t}=K(e,t,Object);e[t]=e[t]||[],e[t].push(r)},W=(e,t)=>{var{obj:e,k:t}=K(e,t);if(e&&Object.prototype.hasOwnProperty.call(e,t))return e[t]},H=(e,t,r)=>{e=W(e,r);return void 0!==e?e:W(t,r)},Y=(e,t,r)=>{for(const a in t)"__proto__"!==a&&"constructor"!==a&&(a in e?M(e[a])||e[a]instanceof String||M(t[a])||t[a]instanceof String?r&&(e[a]=t[a]):Y(e[a],t[a],r):e[a]=t[a]);return e},b=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),G={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},J=e=>M(e)?e.replace(/[&<>"'\/]/g,e=>G[e]):e,X=[" ",",","?","!",";"],Z=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){var t=this.regExpMap.get(e);return void 0!==t||(t=new RegExp(e),this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,t),this.regExpQueue.push(e)),t}}(20),Q=(e,t,r)=>{t=t||"",r=r||"";var a=X.filter(e=>t.indexOf(e)<0&&r.indexOf(e)<0);if(0===a.length)return!0;var s,a=Z.getRegExp(`(${a.map(e=>"?"===e?"\\?":e).join("|")})`);let n=!a.test(e);return n||0<(s=e.indexOf(r))&&!a.test(e.substring(0,s))&&(n=!0),n},ee=(e,t,n=".")=>{if(e){if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;var i=t.split(n);let s=e;for(let a=0;ae?.replace("_","-"),re={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){console?.[e]?.apply?.(console,t)}},ae=class{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||"i18next:",this.logger=e||re,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,"log","",!0)}warn(...e){return this.forward(e,"warn","",!0)}error(...e){return this.forward(e,"error","")}deprecate(...e){return this.forward(e,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,r,a){return a&&!this.debug?null:(M(e[0])&&(e[0]=""+r+this.prefix+" "+e[0]),this.logger[t](e))}create(e){return new ae(this.logger,{prefix:this.prefix+`:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new ae(this.logger,e)}},o=new ae,e=class{constructor(){this.observers={}}on(e,r){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);var t=this.observers[e].get(r)||0;this.observers[e].set(r,t+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(a,...s){this.observers[a]&&Array.from(this.observers[a].entries()).forEach(([t,r])=>{for(let e=0;e{for(let e=0;et[e]&&0{t=this.processors[e]?.process(t,r,a,s)??t}),t}},ie={},oe=e=>!M(e)&&"boolean"!=typeof e&&"number"!=typeof e,le=class extends e{constructor(e,t={}){super(),T(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=o.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){t={...t};return null!=e&&void 0!==this.resolve(e,t)?.res}extractFromKey(e,t){let r=(void 0!==t.nsSeparator?t:this.options).nsSeparator;void 0===r&&(r=":");var a=(void 0!==t.keySeparator?t:this.options).keySeparator;let s=t.ns||this.options.defaultNS||[];var n=r&&-1{r=b&&r!==h?r:N;this.options.missingKeyHandler?this.options.missingKeyHandler(e,o,t,r,C,s):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,o,t,r,C,s),this.emit("missingKey",e,o,t,h)};this.options.saveMissing&&(this.options.saveMissingPlurals&&m?t.forEach(t=>{var e=this.pluralResolver.getSuffixes(t,s);w&&s[`defaultValue${this.options.pluralSeparator}zero`]&&e.indexOf(this.options.pluralSeparator+"zero")<0&&e.push(this.options.pluralSeparator+"zero"),e.forEach(e=>{j([t],i+e,s["defaultValue"+e]||k)})}):j(t,i,k))}h=this.extendTranslation(h,r,s,u,a),t&&h===i&&this.options.appendNamespaceToMissingKey&&(h=""+o+l+i),(t||e)&&this.options.parseMissingKeyHandler&&(h=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?""+o+l+i:i,e?h:void 0,s))}else{if(!s.returnObjects&&!this.options.returnObjects)return this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!"),y=this.options.returnedObjectHandler?this.options.returnedObjectHandler(f,x,{...s,ns:t}):`key '${i} (${this.language})' returned an object instead of string.`,e?(u.res=y,u.usedParams=this.getUsedParamsDetails(s),u):y;if(n){var L,g=Array.isArray(x),O=g?[]:{},R=g?d:f;for(const P in x)Object.prototype.hasOwnProperty.call(x,P)&&(L=""+R+n+P,b&&!h?O[P]=this.translate(L,{...s,defaultValue:oe(k)?k[P]:void 0,joinArrays:!1,ns:t}):O[P]=this.translate(L,{...s,joinArrays:!1,ns:t}),O[P]===L)&&(O[P]=x[P]);h=O}}return e?(u.res=h,u.usedParams=this.getUsedParamsDetails(s),u):h}extendTranslation(r,a,s,n,i){if(this.i18nFormat?.parse)r=this.i18nFormat.parse(r,{...this.options.interpolation.defaultVariables,...s},s.lng||this.language||n.usedLng,n.usedNS,n.usedKey,{resolved:n});else if(!s.skipInterpolation){s.interpolation&&this.interpolator.init({...s,interpolation:{...this.options.interpolation,...s.interpolation}});var o=M(r)&&(void 0!==s?.interpolation?.skipOnVariables?s:this.options).interpolation.skipOnVariables;let e,t=(o&&(l=r.match(this.interpolator.nestingRegexp),e=l&&l.length),s.replace&&!M(s.replace)?s.replace:s);this.options.interpolation.defaultVariables&&(t={...this.options.interpolation.defaultVariables,...t}),r=this.interpolator.interpolate(r,t,s.lng||this.language||n.usedLng,s),o&&(o=(l=r.match(this.interpolator.nestingRegexp))&&l.length,ei?.[0]!==e[0]||s.context?this.translate(...e,a):(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: `+a[0]),null),s)),s.interpolation&&this.interpolator.reset()}var l=s.postProcess||this.options.postProcess,o=M(l)?[l]:l;return r=null!=r&&o?.length&&!1!==s.applyPostProcessor?ne.handle(o,r,a,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...n,usedParams:this.getUsedParamsDetails(s)},...s}:s,this):r}resolve(e,h={}){let f,a,d,p,s;return(e=M(e)?[e]:e).forEach(t=>{if(!this.isValidLookup(f)){t=this.extractFromKey(t,h);const o=t.key;a=o;let e=t.namespaces;this.options.fallbackNS&&(e=e.concat(this.options.fallbackNS));const l=void 0!==h.count&&!M(h.count),c=l&&!h.ordinal&&0===h.count,u=void 0!==h.context&&(M(h.context)||"number"==typeof h.context)&&""!==h.context,r=h.lngs||this.languageUtils.toResolveHierarchy(h.lng||this.language,h.fallbackLng);e.forEach(i=>{this.isValidLookup(f)||(s=i,ie[r[0]+"-"+i]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(s)||(ie[r[0]+"-"+i]=!0,this.logger.warn(`key "${a}" for languages "${r.join(", ")}" won't get resolved as namespace "${s}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),r.forEach(t=>{if(!this.isValidLookup(f)){p=t;var e,r=[o];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(r,o,t,i,h);else{let e;l&&(e=this.pluralResolver.getSuffix(t,h.count,h));var a,s=this.options.pluralSeparator+"zero",n=this.options.pluralSeparator+"ordinal"+this.options.pluralSeparator;l&&(r.push(o+e),h.ordinal&&0===e.indexOf(n)&&r.push(o+e.replace(n,this.options.pluralSeparator)),c)&&r.push(o+s),u&&(a=""+o+this.options.contextSeparator+h.context,r.push(a),l)&&(r.push(a+e),h.ordinal&&0===e.indexOf(n)&&r.push(a+e.replace(n,this.options.pluralSeparator)),c)&&r.push(a+s)}for(;e=r.pop();)this.isValidLookup(f)||(d=e,f=this.getResource(t,i,e,h))}}))})}}),{res:f,usedKey:a,exactUsedKey:d,usedLng:p,usedNS:s}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,r,a={}){return(this.i18nFormat?.getResource?this.i18nFormat:this.resourceStore).getResource(e,t,r,a)}getUsedParamsDetails(e={}){var t=e.replace&&!M(e.replace);let r=t?e.replace:e;if(t&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!t){r={...r};for(const a of["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"])delete r[a]}return r}static hasDefaultValue(e){var t="defaultValue";for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)&&t===r.substring(0,t.length)&&void 0!==e[r])return!0;return!1}},ce=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=o.create("languageUtils")}getScriptPartFromCode(e){return!(e=te(e))||e.indexOf("-")<0||2===(e=e.split("-")).length||(e.pop(),"x"===e[e.length-1].toLowerCase())?null:this.formatLanguageCode(e.join("-"))}getLanguagePartFromCode(e){return!(e=te(e))||e.indexOf("-")<0?e:(e=e.split("-"),this.formatLanguageCode(e[0]))}formatLanguageCode(t){if(M(t)&&-1{a||(e=this.formatLanguageCode(e),this.options.supportedLngs&&!this.isSupportedCode(e))||(a=e)}),!a&&this.options.supportedLngs&&e.forEach(e=>{if(!a){var t=this.getScriptPartFromCode(e);if(this.isSupportedCode(t))return a=t;const r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return a=r;a=this.options.supportedLngs.find(e=>e===r||!(e.indexOf("-")<0&&r.indexOf("-")<0)&&(0{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn("rejecting language code not found in supportedLngs: "+e))};return M(e)&&(-1{r.indexOf(e)<0&&a(this.formatLanguageCode(e))}),r}},ue={zero:0,one:1,two:2,few:3,many:4,other:5},he={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})},fe=class{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=o.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(t,r={}){var a=te("dev"===t?"en":t),e=r.ordinal?"ordinal":"cardinal",s=JSON.stringify({cleanedCode:a,type:e});if(s in this.pluralRulesCache)return this.pluralRulesCache[s];let n;try{n=new Intl.PluralRules(a,{type:e})}catch(e){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),he;if(!t.match(/-|_/))return he;a=this.languageUtils.getLanguagePartFromCode(t);n=this.getRule(a,r)}return this.pluralRulesCache[s]=n}needsPlural(e,t={}){let r=this.getRule(e,t);return 1<(r=r||this.getRule("dev",t))?.resolvedOptions().pluralCategories.length}getPluralFormsOfKey(e,t,r={}){return this.getSuffixes(e,r).map(e=>""+t+e)}getSuffixes(e,t={}){let r=this.getRule(e,t);return(r=r||this.getRule("dev",t))?r.resolvedOptions().pluralCategories.sort((e,t)=>ue[e]-ue[t]).map(e=>""+this.options.prepend+(t.ordinal?"ordinal"+this.options.prepend:"")+e):[]}getSuffix(e,t,r={}){var a=this.getRule(e,r);return a?""+this.options.prepend+(r.ordinal?"ordinal"+this.options.prepend:"")+a.select(t):(this.logger.warn("no plural rule found for: "+e),this.getSuffix("dev",t,r))}},de=(e,t,r,a=".",s=!0)=>{let n=H(e,t,r);return n=!n&&s&&M(r)&&void 0===(n=ee(e,r,a))?ee(t,r,a):n},pe=e=>e.replace(/\$/g,"$$$$"),ge=class{constructor(e={}){this.logger=o.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||(e.interpolation={escapeValue:!0});var{escape:e,escapeValue:t,useRawValueToEscape:r,prefix:a,prefixEscaped:s,suffix:n,suffixEscaped:i,formatSeparator:o,unescapeSuffix:l,unescapePrefix:c,nestingPrefix:u,nestingPrefixEscaped:h,nestingSuffix:f,nestingSuffixEscaped:d,nestingOptionsSeparator:p,maxReplaces:g,alwaysFormat:m}=e.interpolation;this.escape=void 0!==e?e:J,this.escapeValue=void 0===t||t,this.useRawValueToEscape=void 0!==r&&r,this.prefix=a?b(a):s||"{{",this.suffix=n?b(n):i||"}}",this.formatSeparator=o||",",this.unescapePrefix=l?"":c||"-",this.unescapeSuffix=!this.unescapePrefix&&l||"",this.nestingPrefix=u?b(u):h||b("$t("),this.nestingSuffix=f?b(f):d||b(")"),this.nestingOptionsSeparator=p||",",this.maxReplaces=g||1e3,this.alwaysFormat=void 0!==m&&m,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){var e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,this.prefix+"(.+?)"+this.suffix),this.regexpUnescape=e(this.regexpUnescape,""+this.prefix+this.unescapePrefix+"(.+?)"+this.unescapeSuffix+this.suffix),this.nestingRegexp=e(this.nestingRegexp,this.nestingPrefix+"(.+?)"+this.nestingSuffix)}interpolate(a,r,s,n){let i,o,l;const c=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},u=e=>{var t;return e.indexOf(this.formatSeparator)<0?(t=de(r,c,e,this.options.keySeparator,this.options.ignoreJSONStructure),this.alwaysFormat?this.format(t,void 0,s,{...n,...r,interpolationkey:e}):t):(e=(t=e.split(this.formatSeparator)).shift().trim(),t=t.join(this.formatSeparator).trim(),this.format(de(r,c,e,this.options.keySeparator,this.options.ignoreJSONStructure),t,s,{...n,...r,interpolationkey:e}))},h=(this.resetRegExp(),n?.missingInterpolationHandler||this.options.missingInterpolationHandler),f=(void 0!==n?.interpolation?.skipOnVariables?n:this.options).interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>pe(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?pe(this.escape(e)):pe(e)}].forEach(e=>{for(l=0;i=e.regex.exec(a);){var t=i[1].trim();if(void 0===(o=u(t)))if("function"==typeof h){var r=h(a,i,n);o=M(r)?r:""}else{if(!n||!Object.prototype.hasOwnProperty.call(n,t)){if(f){o=i[0];continue}this.logger.warn(`missed to pass in variable ${t} for interpolating `+a)}o=""}else M(o)||this.useRawValueToEscape||(o=F(o));r=e.safeValue(o);if(a=a.replace(i[0],r),f?(e.regex.lastIndex+=o.length,e.regex.lastIndex-=i[0].length):e.regex.lastIndex=0,++l>=this.maxReplaces)break}}),a}nest(t,r,a={}){let s,n,i;for(var o=(r,e)=>{var a=this.nestingOptionsSeparator;if(!(r.indexOf(a)<0)){var s=r.split(new RegExp(a+"[ ]*{"));let t="{"+s[1];r=s[0];var s=(t=this.interpolate(t,i)).match(/'/g),n=t.match(/"/g);((s?.length??0)%2!=0||n)&&n.length%2==0||(t=t.replace(/'/g,'"'));try{i=JSON.parse(t),e&&(i={...e,...i})}catch(e){return this.logger.warn("failed parsing options string in nesting for key "+r,e),""+r+a+t}i.defaultValue&&-1e.trim()).filter(Boolean),s[1]=s[1].slice(0,l)),(n=r(o.call(this,s[1].trim(),i),i))&&s[0]===t&&!M(n))return n;(n=M(n)?n:F(n))||(this.logger.warn(`missed to resolve ${s[1]} for nesting `+t),n=""),e.length&&(n=e.reduce((e,t)=>this.format(e,t,a.lng,{...a,interpolationkey:s[1].trim()}),n.trim())),t=t.replace(s[0],n),this.regexp.lastIndex=0}return t}},me=e=>{let t=e.toLowerCase().trim();const r={};return-1{var t;e&&([e,...t]=e.split(":"),t=t.join(":").trim().replace(/^'+|'+$/g,""),e=e.trim(),r[e]||(r[e]=t),"false"===t&&(r[e]=!1),"true"===t&&(r[e]=!0),isNaN(t)||(r[e]=parseInt(t,10)))})),{formatName:t,formatOptions:r}},be=i=>{const o={};return(e,t,r)=>{let a=r;r&&r.interpolationkey&&r.formatParams&&r.formatParams[r.interpolationkey]&&r[r.interpolationkey]&&(a={...a,[r.interpolationkey]:void 0});var s=t+JSON.stringify(a);let n=o[s];return n||(n=i(te(t),r),o[s]=n),n(e)}},ve=a=>(e,t,r)=>a(te(t),r)(e),ye=class{constructor(e={}){this.logger=o.create("formatter"),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||",";t=t.cacheInBuiltFormats?be:ve;this.formats={number:t((e,t)=>{const r=new Intl.NumberFormat(e,{...t});return e=>r.format(e)}),currency:t((e,t)=>{const r=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>r.format(e)}),datetime:t((e,t)=>{const r=new Intl.DateTimeFormat(e,{...t});return e=>r.format(e)}),relativetime:t((e,t)=>{const r=new Intl.RelativeTimeFormat(e,{...t});return e=>r.format(e,t.range||"day")}),list:t((e,t)=>{const r=new Intl.ListFormat(e,{...t});return e=>r.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=be(t)}format(e,t,i,o={}){var t=t.split(this.formatSeparator),r=(1-1-1{var{formatName:r,formatOptions:a}=me(r);if(this.formats[r]){let e=t;try{var s=o?.formatParams?.[o.interpolationkey]||{},n=s.locale||s.lng||o.locale||o.lng||i;e=this.formats[r](t,n,{...a,...o,...s})}catch(e){this.logger.warn(e)}return e}return this.logger.warn("there was no format function for "+r),t},e));return r}},we=(e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)},ke=class extends e{constructor(e,t,r,a={}){super(),this.backend=e,this.store=t,this.services=r,this.languageUtils=r.languageUtils,this.options=a,this.logger=o.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=a.maxParallelReads||10,this.readingCalls=0,this.maxRetries=0<=a.maxRetries?a.maxRetries:5,this.retryTimeout=1<=a.retryTimeout?a.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(r,a.backend,a)}queueLoad(e,t,s,r){const n={},i={},o={},l={};return e.forEach(r=>{let a=!0;t.forEach(e=>{var t=r+"|"+e;!s.reload&&this.store.hasResourceBundle(r,e)?this.state[t]=2:this.state[t]<0||(1===this.state[t]?void 0===i[t]&&(i[t]=!0):(this.state[t]=1,a=!1,void 0===i[t]&&(i[t]=!0),void 0===n[t]&&(n[t]=!0),void 0===l[e]&&(l[e]=!0)))}),a||(o[r]=!0)}),(Object.keys(n).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(n),pending:Object.keys(i),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(l)}}loaded(e,t,r){var a=e.split("|");const s=a[0],n=a[1],i=(t&&this.emit("failedLoading",s,n,t),!t&&r&&this.store.addResourceBundle(s,n,r,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&r&&(this.state[e]=0),{});this.queue.forEach(r=>{z(r.loaded,[s],n),we(r,e),t&&r.errors.push(t),0!==r.pendingCount||r.done||(Object.keys(r.loaded).forEach(t=>{i[t]||(i[t]={});var e=r.loaded[t];e.length&&e.forEach(e=>{void 0===i[t][e]&&(i[t][e]=!0)})}),r.done=!0,r.errors.length?r.callback(r.errors):r.callback())}),this.emit("loaded",i),this.queue=this.queue.filter(e=>!e.done)}read(a,s,n,i=0,o=this.retryTimeout,l){if(!a.length)return l(null,{});if(this.readingCalls>=this.maxParallelReads)this.waitingReads.push({lng:a,ns:s,fcName:n,tried:i,wait:o,callback:l});else{this.readingCalls++;const r=(e,t)=>{var r;this.readingCalls--,0{this.read.call(this,a,s,n,i+1,2*o,l)},o):l(e,t)};var e=this.backend[n].bind(this.backend);if(2!==e.length)return e(a,s,r);try{var t=e(a,s);t&&"function"==typeof t.then?t.then(e=>r(null,e)).catch(r):r(null,t)}catch(e){r(e)}}}prepareLoading(e,t,r={},a){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),a&&a();M(e)&&(e=this.languageUtils.toResolveHierarchy(e)),M(t)&&(t=[t]);e=this.queueLoad(e,t,r,a);if(!e.toLoad.length)return e.pending.length||a(),null;e.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,r){this.prepareLoading(e,t,{},r)}reload(e,t,r){this.prepareLoading(e,t,{reload:!0},r)}loadOne(r,a=""){var e=r.split("|");const s=e[0],n=e[1];this.read(s,n,"read",void 0,void 0,(e,t)=>{e&&this.logger.warn(`${a}loading namespace ${n} for language ${s} failed`,e),!e&&t&&this.logger.log(`${a}loaded namespace ${n} for language `+s,t),this.loaded(r,e,t)})}saveMissing(t,r,a,s,n,i={},o=()=>{}){if(this.services?.utils?.hasLoadedNamespace&&!this.services?.utils?.hasLoadedNamespace(r))this.logger.warn(`did not save key "${a}" as the namespace "${r}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");else if(null!=a&&""!==a){if(this.backend?.create){i={...i,isUpdate:n},n=this.backend.create.bind(this.backend);if(n.length<6)try{let e;(e=5===n.length?n(t,r,a,s,i):n(t,r,a,s))&&"function"==typeof e.then?e.then(e=>o(null,e)).catch(o):o(null,e)}catch(e){o(e)}else n(t,r,a,s,o,i)}t&&t[0]&&this.store.addResource(t[0],r,a,s)}}},xe=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),M(e[1])&&(t.defaultValue=e[1]),M(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const r=e[3]||e[2];Object.keys(r).forEach(e=>{t[e]=r[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Se=e=>(M(e.ns)&&(e.ns=[e.ns]),M(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),M(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),Le=()=>{},Oe=t=>{Object.getOwnPropertyNames(Object.getPrototypeOf(t)).forEach(e=>{"function"==typeof t[e]&&(t[e]=t[e].bind(t))})},Re=class extends e{constructor(e={},t){if(super(),this.options=Se(e),this.services={},this.logger=o,this.modules={external:[]},Oe(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(t={},r){this.isInitializing=!0,"function"==typeof t&&(r=t,t={}),null==t.defaultNS&&t.ns&&(M(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));var a=xe(),t=(this.options={...a,...this.options,...Se(t)},this.options.interpolation={...a.interpolation,...this.options.interpolation},void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator),e=>e?"function"==typeof e?new e:e:null);if(!this.options.isClone){this.modules.logger?o.init(t(this.modules.logger),this.options):o.init(null,this.options);let e;e=this.modules.formatter||ye;var s=new ce(this.options),n=(this.store=new se(this.options.resources,this.options),this.services);n.logger=o,n.resourceStore=this.store,n.languageUtils=s,n.pluralResolver=new fe(s,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!e||this.options.interpolation.format&&this.options.interpolation.format!==a.interpolation.format||(n.formatter=t(e),n.formatter.init(n,this.options),this.options.interpolation.format=n.formatter.format.bind(n.formatter)),n.interpolator=new ge(this.options),n.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},n.backendConnector=new ke(t(this.modules.backend),n.resourceStore,n,this.options),n.backendConnector.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(n.languageDetector=t(this.modules.languageDetector),n.languageDetector.init)&&n.languageDetector.init(n,this.options.detection,this.options),this.modules.i18nFormat&&(n.i18nFormat=t(this.modules.i18nFormat),n.i18nFormat.init)&&n.i18nFormat.init(this),this.translator=new le(this.services,this.options),this.translator.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}this.format=this.options.interpolation.format,r=r||Le,!this.options.fallbackLng||this.services.languageDetector||this.options.lng||0<(s=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng)).length&&"dev"!==s[0]&&(this.options.lng=s[0]),this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(t=>{this[t]=(...e)=>this.store[t](...e)});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(t=>{this[t]=(...e)=>(this.store[t](...e),this)});const i=U();a=()=>{var e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),r(e,t)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e,t=Le){let r=t;t=M(e)?e:this.language;if("function"==typeof e&&(r=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===t?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return r();const a=[],s=e=>{e&&"cimode"!==e&&this.services.languageUtils.toResolveHierarchy(e).forEach(e=>{"cimode"!==e&&a.indexOf(e)<0&&a.push(e)})};t?s(t):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>s(e)),this.options.preload?.forEach?.(e=>s(e)),this.services.backendConnector.load(a,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),r(e)})}else r(null)}reloadResources(e,t,r){const a=U();return"function"==typeof e&&(r=e,e=void 0),"function"==typeof t&&(r=t,t=void 0),e=e||this.languages,t=t||this.options.ns,r=r||Le,this.services.backendConnector.reload(e,t,e=>{a.resolve(),r(e)}),a}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(e.type)return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&ne.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this;throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()")}setResolvedLanguage(e){if(e&&this.languages&&!(-1<["cimode","dev"].indexOf(e))){for(let e=0;e{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)}),i=(e,t)=>{t?this.isLanguageChangingTo===a&&(n(t),this.translator.changeLanguage(t),this.isLanguageChangingTo=void 0,this.emit("languageChanged",t),this.logger.log("languageChanged",t)):this.isLanguageChangingTo=void 0,s.resolve((...e)=>this.t(...e)),r&&r(e,(...e)=>this.t(...e))};var e=e=>{a||e||!this.services.languageDetector||(e=[]);var t=M(e)?e:e&&e[0];const r=this.store.hasLanguageSomeTranslations(t)?t:this.services.languageUtils.getBestMatchFromCodes(M(e)?[e]:e);r&&(this.language||n(r),this.translator.language||this.translator.changeLanguage(r),this.services.languageDetector?.cacheUserLanguage?.(r)),this.loadResources(r,e=>{i(e,r)})};return a||!this.services.languageDetector||this.services.languageDetector.async?!a&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(e):this.services.languageDetector.detect(e):e(a):e(this.services.languageDetector.detect()),s}getFixedT(e,t,i){const o=(e,t,...r)=>{let a;(a="object"!=typeof t?this.options.overloadTranslationOptionHandler([e,t].concat(r)):{...t}).lng=a.lng||o.lng,a.lngs=a.lngs||o.lngs,a.ns=a.ns||o.ns,""!==a.keyPrefix&&(a.keyPrefix=a.keyPrefix||i||o.keyPrefix);const s=this.options.keySeparator||".";let n;return n=a.keyPrefix&&Array.isArray(e)?e.map(e=>""+a.keyPrefix+s+e):a.keyPrefix?""+a.keyPrefix+s+e:e,this.t(n,a)};return M(e)?o.lng=e:o.lngs=e,o.ns=t,o.keyPrefix=i,o}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var r=t.lng||this.resolvedLanguage||this.languages[0],a=!!this.options&&this.options.fallbackLng,s=this.languages[this.languages.length-1];if("cimode"===r.toLowerCase())return!0;var n=(e,t)=>{e=this.services.backendConnector.state[e+"|"+t];return-1===e||0===e||2===e};if(t.precheck){t=t.precheck(this,n);if(void 0!==t)return t}return!!this.hasResourceBundle(r,e)||!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages)&&(!n(r,e)||a&&!n(s,e)))}loadNamespaces(e,t){const r=U();return this.options.ns?((e=M(e)?[e]:e).forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{r.resolve(),t&&t(e)}),r):(t&&t(),Promise.resolve())}loadLanguages(e,t){const r=U(),a=(M(e)&&(e=[e]),this.options.preload||[]);e=e.filter(e=>a.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return e.length?(this.options.preload=a.concat(e),this.loadResources(e=>{r.resolve(),t&&t(e)}),r):(t&&t(),Promise.resolve())}dir(e){if(!(e=e||this.resolvedLanguage||(0{s[e]=this[e]}),s.services={...this.services},s.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},r&&(e=Object.keys(this.store.data).reduce((r,a)=>(r[a]={...this.store.data[a]},r[a]=Object.keys(r[a]).reduce((e,t)=>(e[t]={...r[a][t]},e),r[a]),r),{}),s.store=new se(e,a),s.services.resourceStore=s.store),s.translator=new le(s.services,a),s.translator.on("*",(e,...t)=>{s.emit(e,...t)}),s.init(a,t),s.translator.options=a,s.translator.backendConnector.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},s}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}},e=Re.createInstance(),Ne=(e.createInstance=Re.createInstance,e.createInstance,e.dir,e.init,e.loadResources,e.reloadResources,e.use,e.changeLanguage,e.getFixedT,e.t),e=(e.exists,e.setDefaultNamespace,e.hasLoadedNamespace,e.loadNamespaces,e.loadLanguages,"marketplace"),g={installedExtensions:e+":installed-extensions",installedSnippets:e+":installed-snippets",installedThemes:e+":installed-themes",activeTab:e+":active-tab",tabs:e+":tabs",sort:e+":sort",themeInstalled:e+":theme-installed",localTheme:e+":local-theme",albumArtBasedColor:e+":albumArtBasedColors",albumArtBasedColorMode:e+":albumArtBasedColorsMode",albumArtBasedColorVibrancy:e+":albumArtBasedColorsVibrancy",colorShift:e+":colorShift"},Ce=100,{min:je,max:Pe}=Math,L=(e,t=0,r=1)=>je(Pe(t,e),r),Me=t=>{t._clipped=!1,t._unclipped=t.slice(0);for(let e=0;e<=3;e++)e<3?((t[e]<0||2553<=t.length?Array.prototype.slice.call(t):"object"==O(t[0])&&e?e.split("").filter(e=>void 0!==t[0][e]).map(e=>t[0][e]):t[0].slice(0),l=e=>{var t;return!(e.length<2)&&"string"==O(e[t=e.length-1])?e[t].toLowerCase():null},{PI:e,min:$e,max:Ae}=Math,a=e=>Math.round(100*e)/100,Ie=e=>Math.round(100*e)/100,h=2*e,_e=e/3,Ue=e/180,Fe=180/e,i={format:{},autodetect:[]},m=class{constructor(...e){if("object"===O(e[0])&&e[0].constructor&&e[0].constructor===this.constructor)return e[0];let t=l(e),r=!1;if(!t){r=!0,i.sorted||(i.autodetect=i.autodetect.sort((e,t)=>t.p-e.p),i.sorted=!0);for(var a of i.autodetect)if(t=a.test(...e))break}if(!i.format[t])throw new Error("unknown format: "+e);var s=i.format[t].apply(null,r?e:e.slice(0,-1));this._rgb=Me(s),3===this._rgb.length&&this._rgb.push(1)}toString(){return"function"==O(this.hex)?this.hex():`[${this._rgb.join(",")}]`}},e=(...e)=>new m(...e),R=(e.version="3.1.1",e),r={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},Te=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,Be=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,Ve=e=>{var t;if(e.match(Te))return 3===(e=4!==e.length&&7!==e.length?e:e.substr(1)).length&&(e=(e=e.split(""))[0]+e[0]+e[1]+e[1]+e[2]+e[2]),[(t=parseInt(e,16))>>16,t>>8&255,255&t,1];if(e.match(Be))return 4===(e=5!==e.length&&9!==e.length?e:e.substr(1)).length&&(e=(e=e.split(""))[0]+e[0]+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]),[(t=parseInt(e,16))>>24&255,t>>16&255,t>>8&255,Math.round((255&t)/255*100)/100];throw new Error("unknown hex color: "+e)},De=Math["round"],Ke=(...e)=>{let[t,r,a,s]=p(e,"rgba"),n=l(e)||"auto";void 0===s&&(s=1),"auto"===n&&(n=s<1?"rgba":"rgb");let i="000000"+(De(t)<<16|De(r)<<8|De(a)).toString(16),o=(i=i.substr(i.length-6),"0"+De(255*s).toString(16));switch(o=o.substr(o.length-2),n.toLowerCase()){case"rgba":return"#"+i+o;case"argb":return"#"+o+i;default:return"#"+i}},qe=(m.prototype.name=function(){var e,t=Ke(this._rgb,"rgb");for(e of Object.keys(r))if(r[e]===t)return e.toLowerCase();return t},i.format.named=e=>{if(e=e.toLowerCase(),r[e])return Ve(r[e]);throw new Error("unknown color name: "+e)},i.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&"string"===O(e)&&r[e.toLowerCase()])return"named"}}),m.prototype.alpha=function(e,t=!1){return void 0!==e&&"number"===O(e)?t?(this._rgb[3]=e,this):new m([this._rgb[0],this._rgb[1],this._rgb[2],e],"rgb"):this._rgb[3]},m.prototype.clipped=function(){return this._rgb._clipped||!1},{Kn:18,labWhitePoint:"d65",Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452,kE:216/24389,kKE:8,kK:24389/27,RefWhiteRGB:{X:.95047,Y:1,Z:1.08883},MtxRGB2XYZ:{m00:.4124564390896922,m01:.21267285140562253,m02:.0193338955823293,m10:.357576077643909,m11:.715152155287818,m12:.11919202588130297,m20:.18043748326639894,m21:.07217499330655958,m22:.9503040785363679},MtxXYZ2RGB:{m00:3.2404541621141045,m01:-.9692660305051868,m02:.055643430959114726,m10:-1.5371385127977166,m11:1.8760108454466942,m12:-.2040259135167538,m20:-.498531409556016,m21:.041556017530349834,m22:1.0572251882231791},As:.9414285350000001,Bs:1.040417467,Cs:1.089532651,MtxAdaptMa:{m00:.8951,m01:-.7502,m02:.0389,m10:.2664,m11:1.7135,m12:-.0685,m20:-.1614,m21:.0367,m22:1.0296},MtxAdaptMaI:{m00:.9869929054667123,m01:.43230526972339456,m02:-.008528664575177328,m10:-.14705425642099013,m11:.5183602715367776,m12:.04004282165408487,m20:.15996265166373125,m21:.0492912282128556,m22:.9684866957875502}}),w=qe,ze=new Map([["a",[1.0985,.35585]],["b",[1.0985,.35585]],["c",[.98074,1.18232]],["d50",[.96422,.82521]],["d55",[.95682,.92149]],["d65",[.95047,1.08883]],["e",[1,1,1]],["f2",[.99186,.67393]],["f7",[.95041,1.08747]],["f11",[1.00962,.6435]],["icc",[.96422,.82521]]]);function c(e){var t=ze.get(String(e).toLowerCase());if(!t)throw new Error("unknown Lab illuminant "+e);qe.labWhitePoint=e,qe.Xn=t[0],qe.Zn=t[1]}function We(){return qe.labWhitePoint}var He=e=>{var t=Math.sign(e);return((e=Math.abs(e))<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)*t},Ye=(e,t,r)=>{var{MtxAdaptMa:a,MtxAdaptMaI:s,MtxXYZ2RGB:n,RefWhiteRGB:i,Xn:o,Yn:l,Zn:c}=w,u=o*a.m00+l*a.m10+c*a.m20,h=o*a.m01+l*a.m11+c*a.m21,o=o*a.m02+l*a.m12+c*a.m22,l=i.X*a.m00+i.Y*a.m10+i.Z*a.m20,c=i.X*a.m01+i.Y*a.m11+i.Z*a.m21,i=i.X*a.m02+i.Y*a.m12+i.Z*a.m22,l=(e*a.m00+t*a.m10+r*a.m20)*(l/u),u=(e*a.m01+t*a.m11+r*a.m21)*(c/h),c=(e*a.m02+t*a.m12+r*a.m22)*(i/o),h=l*s.m00+u*s.m10+c*s.m20,e=l*s.m01+u*s.m11+c*s.m21,t=l*s.m02+u*s.m12+c*s.m22;return[255*He(h*n.m00+e*n.m10+t*n.m20),255*He(h*n.m01+e*n.m11+t*n.m21),255*He(h*n.m02+e*n.m12+t*n.m22)]},Ge=(...e)=>{var[t,r,a]=e=p(e,"lab"),[t,r,a]=((e,t,r)=>{const{kE:a,kK:s,kKE:n,Xn:i,Yn:o,Zn:l}=w,c=(e+16)/116,u=.002*t+c,h=c-.005*r,f=u*u*u,d=h*h*h,p=f>a?f:(116*u-16)/s,g=e>n?Math.pow((e+16)/116,3):e/s,m=d>a?d:(116*h-16)/s,b=p*i,v=g*o,y=m*l;return[b,v,y]})(t,r,a),[t,r,a]=Ye(t,r,a);return[t,r,a,3{e=Je(e/255),t=Je(t/255),r=Je(r/255);var{MtxRGB2XYZ:a,MtxAdaptMa:s,MtxAdaptMaI:n,Xn:i,Yn:o,Zn:l,As:c,Bs:u,Cs:h}=w,f=e*a.m00+t*a.m10+r*a.m20,d=e*a.m01+t*a.m11+r*a.m21,e=e*a.m02+t*a.m12+r*a.m22,t=i*s.m00+o*s.m10+l*s.m20,r=i*s.m01+o*s.m11+l*s.m21,a=i*s.m02+o*s.m12+l*s.m22,i=f*s.m00+d*s.m10+e*s.m20,o=f*s.m01+d*s.m11+e*s.m21,l=f*s.m02+d*s.m12+e*s.m22;return[(i*=t/c)*n.m00+(o*=r/u)*n.m10+(l*=a/h)*n.m20,i*n.m01+o*n.m11+l*n.m21,i*n.m02+o*n.m12+l*n.m22]},Ze=(...e)=>{var[e,t,r,...a]=p(e,"rgb"),[e,t,r]=Xe(e,t,r),[e,t,r]=function(e,t,r){var{Xn:a,Yn:s,Zn:n,kE:i,kK:o}=w,e=e/a,a=t/s,t=r/n,s=inew m(...e,"lab"),getLabWhitePoint:We,setLabWhitePoint:c}),i.format.lab=Ge,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"lab"))&&3===e.length)return"lab"}}),m.prototype.darken=function(e=1){var t=this.lab();return t[0]-=w.Kn*e,new m(t,"lab").alpha(this.alpha(),!0)},m.prototype.brighten=function(e=1){return this.darken(-e)},m.prototype.darker=m.prototype.darken,m.prototype.brighter=m.prototype.brighten,m.prototype.get=function(e){var[e,t]=e.split("."),r=this[e]();if(t){var a=e.indexOf(t)-("ok"===e.substr(0,2)?2:0);if(-1{var r=e.interpolate(t,.5,i),a=r.luminance();return Math.abs(n-a)<1e-7||!s--?r:n.2126*(e=tt(e))+.7152*(t=tt(t))+.0722*(r=tt(r))),tt=e=>(e/=255)<=.03928?e/12.92:Qe((e+.055)/1.055,2.4),n={},s=(e,t,r=.5,...a)=>{let s=a[0]||"lrgb";if(n[s]||a.length||(s=Object.keys(n)[0]),n[s])return"object"!==O(e)&&(e=new m(e)),"object"!==O(t)&&(t=new m(t)),n[s](e,t,r).alpha(e.alpha()+r*(t.alpha()-e.alpha()));throw new Error(`interpolation mode ${s} is not defined`)},{sin:rt,cos:at}=(m.prototype.mix=m.prototype.interpolate=function(e,t=.5,...r){return s(this,e,t,...r)},m.prototype.premultiply=function(e=!1){var t=this._rgb,r=t[3];return e?(this._rgb=[t[0]*r,t[1]*r,t[2]*r,r],this):new m([t[0]*r,t[1]*r,t[2]*r,r],"rgb")},Math),st=(...e)=>{let[t,r,a]=p(e,"lch");return isNaN(a)&&(a=0),a*=Ue,[t,at(a)*r,rt(a)*r]},nt=(...e)=>{var[t,r,a]=e=p(e,"lch"),[t,r,a]=st(t,r,a),[t,r,a]=Ge(t,r,a);return[t,r,a,3{e=p(e,"hcl").reverse();return nt(...e)},{sqrt:it,atan2:ot,round:lt}=Math,ct=(...e)=>{var[e,t,r]=p(e,"lab"),a=it(t*t+r*r);let s=(ot(r,t)*Fe+360)%360;return[e,a,s=0===lt(1e4*a)?Number.NaN:s]},ut=(...e)=>{var[e,t,r,...a]=p(e,"rgb"),[e,t,r]=Ze(e,t,r),[e,t,r]=ct(e,t,r);return[e,t,r,...0new m(...e,"lch"),hcl:(...e)=>new m(...e,"hcl")}),i.format.lch=nt,i.format.hcl=e,["lch","hcl"].forEach(t=>i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,t))&&3===e.length)return t}})),m.prototype.saturate=function(e=1){var t=this.lch();return t[1]+=w.Kn*e,t[1]<0&&(t[1]=0),new m(t,"lch").alpha(this.alpha(),!0)},m.prototype.desaturate=function(e=1){return this.saturate(-e)},m.prototype.set=function(e,t,r=!1){var[e,a]=e.split("."),s=this[e]();if(a){var n=e.indexOf(a)-("ok"===e.substr(0,2)?2:0);if(-1{e=e._rgb,t=t._rgb;return new m(e[0]+r*(t[0]-e[0]),e[1]+r*(t[1]-e[1]),e[2]+r*(t[2]-e[2]),"rgb")},Math),f=(n.lrgb=(e,t,r)=>{var[e,a,s]=e._rgb,[t,n,i]=t._rgb;return new m(ht(u(e,2)*(1-r)+u(t,2)*r),ht(u(a,2)*(1-r)+u(n,2)*r),ht(u(s,2)*(1-r)+u(i,2)*r),"rgb")},n.lab=(e,t,r)=>{e=e.lab(),t=t.lab();return new m(e[0]+r*(t[0]-e[0]),e[1]+r*(t[1]-e[1]),e[2]+r*(t[2]-e[2]),"lab")},(e,t,r,a)=>{let s,n;"hsl"===a?(s=e.hsl(),n=t.hsl()):"hsv"===a?(s=e.hsv(),n=t.hsv()):"hcg"===a?(s=e.hcg(),n=t.hcg()):"hsi"===a?(s=e.hsi(),n=t.hsi()):"lch"===a||"hcl"===a?(a="hcl",s=e.hcl(),n=t.hcl()):"oklch"===a&&(s=e.oklch().reverse(),n=t.oklch().reverse());let i,o,l,c,u,h;"h"!==a.substr(0,1)&&"oklch"!==a||([i,l,u]=s,[o,c,h]=n);let f,d,p,g;return isNaN(i)||isNaN(o)?isNaN(i)?isNaN(o)?d=Number.NaN:(d=o,1!=u&&0!=u||"hsv"==a||(f=c)):(d=i,1!=h&&0!=h||"hsv"==a||(f=l)):(g=o>i&&180f(e,t,r,"lch"),e=(n.lch=e,n.hcl=e,e=>{if("number"==O(e)&&0<=e&&e<=16777215)return[e>>16,e>>8&255,255&e,1];throw new Error("unknown num color: "+e)}),ft=(...e)=>{var[e,t,r]=p(e,"rgb");return(e<<16)+(t<<8)+r},dt=(m.prototype.num=function(){return ft(this._rgb)},Object.assign(R,{num:(...e)=>new m(...e,"num")}),i.format.num=e,i.autodetect.push({p:5,test:(...e)=>{if(1===e.length&&"number"===O(e[0])&&0<=e[0]&&e[0]<=16777215)return"num"}}),(n.num=(e,t,r)=>{e=e.num(),t=t.num();return new m(e+r*(t-e),"num")},Math)["floor"]),e=(...e)=>{let[t,r,a]=e=p(e,"hcg"),s,n,i;a*=255;var o=255*r;if(0===r)s=n=i=a;else{360<(t=360===t?0:t)&&(t-=360),t<0&&(t+=360),t/=60;var l=dt(t),c=t-l,u=a*(1-r),h=u+o*(1-c),f=u+o*c,d=u+o;switch(l){case 0:[s,n,i]=[d,f,u];break;case 1:[s,n,i]=[h,d,u];break;case 2:[s,n,i]=[u,d,f];break;case 3:[s,n,i]=[u,h,d];break;case 4:[s,n,i]=[f,u,d];break;case 5:[s,n,i]=[d,u,h]}}return[s,n,i,3{var[e,t,r]=p(e,"rgb"),a=$e(e,t,r),s=Ae(e,t,r),n=s-a;let i;return 0==n?i=Number.NaN:(e===s&&(i=(t-r)/n),t===s&&(i=2+(r-e)/n),r===s&&(i=4+(e-t)/n),(i*=60)<0&&(i+=360)),[i,100*n/255,a/(255-n)*100]},d=(m.prototype.hcg=function(){return pt(this._rgb)},R.hcg=(...e)=>new m(...e,"hcg"),i.format.hcg=e,i.autodetect.push({p:1,test:(...e)=>{if("array"===O(e=p(e,"hcg"))&&3===e.length)return"hcg"}}),(n.hcg=(e,t,r)=>f(e,t,r,"hcg"),Math)["cos"]),e=(...e)=>{let[t,r,a]=e=p(e,"hsi"),s,n,i;return isNaN(t)&&(t=0),isNaN(r)&&(r=0),360{var[e,t,r]=p(e,"rgb");let a;var s=gt(e/=255,t/=255,r/=255),n=(e+t+r)/3,s=0new m(...e,"hsi"),i.format.hsi=e,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"hsi"))&&3===e.length)return"hsi"}}),n.hsi=(e,t,r)=>f(e,t,r,"hsi"),(...e)=>{var[t,r,a]=e=p(e,"hsl");let s,n,i;if(0===r)s=n=i=255*a;else{var o=[0,0,0],l=[0,0,0],c=a<.5?a*(1+r):a+r-a*r,u=2*a-c,r=t/360;o[0]=r+1/3,o[1]=r,o[2]=r-1/3;for(let e=0;e<3;e++)o[e]<0&&(o[e]+=1),1{var[t,r,a]=e=p(e,"rgba"),s=$e(t/=255,r/=255,a/=255),n=Ae(t,r,a),i=(n+s)/2;let o,l;return n===s?(o=0,l=Number.NaN):o=i<.5?(n-s)/(n+s):(n-s)/(2-n-s),t==n?l=(r-a)/(n-s):r==n?l=2+(a-t)/(n-s):a==n&&(l=4+(t-r)/(n-s)),(l*=60)<0&&(l+=360),3new m(...e,"hsl"),i.format.hsl=yt,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"hsl"))&&3===e.length)return"hsl"}}),(n.hsl=(e,t,r)=>f(e,t,r,"hsl"),Math)["floor"]),e=(...e)=>{let[t,r,a]=e=p(e,"hsv"),s,n,i;if(a*=255,0===r)s=n=i=a;else{360<(t=360===t?0:t)&&(t-=360),t<0&&(t+=360),t/=60;var o=kt(t),l=t-o,c=a*(1-r),u=a*(1-r*l),h=a*(1-r*(1-l));switch(o){case 0:[s,n,i]=[a,h,c];break;case 1:[s,n,i]=[u,a,c];break;case 2:[s,n,i]=[c,a,h];break;case 3:[s,n,i]=[c,u,a];break;case 4:[s,n,i]=[h,c,a];break;case 5:[s,n,i]=[a,c,u]}}return[s,n,i,3{var[e,t,r]=e=p(e,"rgb"),a=xt(e,t,r),s=St(e,t,r),a=s-a;let n,i;return 0===s?(n=Number.NaN,i=0):(i=a/s,e===s&&(n=(t-r)/a),t===s&&(n=2+(r-e)/a),r===s&&(n=4+(e-t)/a),(n*=60)<0&&(n+=360)),[n,i,s/255]};m.prototype.hsv=function(){return Lt(this._rgb)},R.hsv=(...e)=>new m(...e,"hsv"),i.format.hsv=e,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"hsv"))&&3===e.length)return"hsv"}});function Ot(e,r){var t=e.length,a=(Array.isArray(e[0])||(e=[e]),(r=Array.isArray(r[0])?r:r.map(e=>[e]))[0].length);let s=r[0].map((e,t)=>r.map(e=>e[t])),n=e.map(r=>s.map(a=>Array.isArray(r)?r.reduce((e,t,r)=>e+t*(a[r]||0),0):a.reduce((e,t)=>e+t*r,0)));return 1===t&&(n=n[0]),1===a?n.map(e=>e[0]):n}n.hsv=(e,t,r)=>f(e,t,r,"hsv");var Rt=(...e)=>{var[e,t,r,...a]=e=p(e,"lab"),[e,t,r]=function(e){e=Ot([[1,.3963377773761749,.2158037573099136],[1,-.1055613458156586,-.0638541728258133],[1,-.0894841775298119,-1.2914855480194092]],e);return Ot([[1.2268798758459243,-.5578149944602171,.2813910456659647],[-.0405757452148008,1.112286803280317,-.0717110580655164],[-.0763729366746601,-.4214933324022432,1.5869240198367816]],e.map(e=>e**3))}([e,t,r]),[e,t,r]=Ye(e,t,r);return[e,t,r,...0{var[e,t,r,...a]=p(e,"rgb");return[...function(e){e=Ot([[.819022437996703,.3619062600528904,-.1288737815209879],[.0329836539323885,.9292868615863434,.0361446663506424],[.0481771893596242,.2642395317527308,.6335478284694309]],e);return Ot([[.210454268309314,.7936177747023054,-.0040720430116193],[1.9779985324311684,-2.42859224204858,.450593709617411],[.0259040424655478,.7827717124575296,-.8086757549230774]],e.map(e=>Math.cbrt(e)))}(Xe(e,t,r)),...0new m(...e,"oklab")}),i.format.oklab=Rt,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"oklab"))&&3===e.length)return"oklab"}}),n.oklab=(e,t,r)=>{e=e.oklab(),t=t.oklab();return new m(e[0]+r*(t[0]-e[0]),e[1]+r*(t[1]-e[1]),e[2]+r*(t[2]-e[2]),"oklab")},n.oklch=(e,t,r)=>f(e,t,r,"oklch"),Math),At=Math["pow"];function It(n){let i="rgb",o=R("#ccc"),t=0,l=[0,1],c=[],u=[0,0],h=!1,f=[],r=!1,d=0,p=1,a,g={},m=!0,b=1;function s(t){if((t=t||["#fff","#000"])&&"string"===O(t)&&R.brewer&&R.brewer[t.toLowerCase()]&&(t=R.brewer[t.toLowerCase()]),"array"===O(t)){t=(t=1===t.length?[t[0],t[0]]:t).slice(0);for(let e=0;e=h[e];)e++;return e-1}};let y=e=>e,w=e=>e;function k(e,t){let r,a;if(null==t&&(t=!1),isNaN(e)||null===e)return o;if(a=t?e:h&&2=s&&e===c.length-1){r=f[e];break}if(a>s&&ag={};s(n);function S(e){return e=R(k(e)),r&&e[r]?e[r]():e}return S.classes=function(e){var t;return null!=e?("array"===O(e)?(h=e,l=[e[0],e[e.length-1]]):(t=R.analyze(l),h=0===e?[t.min,t.max]:R.limits(t,"e",e)),S):h},S.domain=function(r){if(!arguments.length)return l;d=r[0],p=r[r.length-1],c=[];var t=f.length;if(r.length===t&&d!==p)for(var e of Array.from(r))c.push((e-d)/(p-d));else{for(let e=0;et/(r.length-1)),s=r.map(e=>(e-d)/(p-d));s.every((e,t)=>a[t]===e)||(w=e=>{if(e<=0||1<=e)return e;let t=0;for(;e>=s[t+1];)t++;var r=(e-s[t])/(s[t+1]-s[t]);return a[t]+r*(a[t+1]-a[t])})}}return l=[d,p],S},S.mode=function(e){return arguments.length?(i=e,x(),S):i},S.range=function(e,t){return s(e),S},S.out=function(e){return r=e,S},S.spread=function(e){return arguments.length?(t=e,S):t},S.correctLightness=function(e){return null==e&&(e=!0),a=e,x(),y=a?function(e){var t=k(0,!0).lab()[0],r=k(1,!0).lab()[0];const a=re,S},S.padding=function(e){return null!=e?("number"===O(e)&&(e=[e,e]),u=e,S):u},S.colors=function(t,r){arguments.length<2&&(r="hex");let e=[];if(0===arguments.length)e=f.slice(0);else if(1===t)e=[S(.5)];else if(1n;s?e++:e--)a.push(e);return a}(0,t,!1).map(e=>S(a+e/(t-1)*s))}else{n=[];let a=[];if(h&&2t;r?e++:e--)a.push(.5*(h[e-1]+h[e]));else a=l;e=a.map(e=>S(e))}return e=R[r]?e.map(e=>e[r]()):e},S.cache=function(e){return null!=e?(m=e,S):m},S.gamma=function(e){return null!=e?(b=e,S):b},S.nodata=function(e){return null!=e?(o=R(e),S):o},S}var _t=function(t){let r=[1,1];for(let e=1;e!(t<3)||!1===r?e:Ut(e))},Object.assign(R,{rgb:(...e)=>new m(...e,"rgb")}),i.format.rgb=(...e)=>{e=p(e,"rgba");return void 0===e[3]&&(e[3]=1),e},i.autodetect.push({p:3,test:(...e)=>{if("array"===O(e=p(e,"rgba"))&&(3===e.length||4===e.length&&"number"==O(e[3])&&0<=e[3]&&e[3]<=1))return"rgb"}}),(e,t,r)=>{if(v[r])return v[r](e,t);throw new Error("unknown blend mode "+r)}),e=r=>(e,t)=>{t=R(t).rgb(),e=R(e).rgb();return R.rgb(r(t,e))},t=a=>(e,t)=>{var r=[];return r[0]=a(e[0],t[0]),r[1]=a(e[1],t[1]),r[2]=a(e[2],t[2]),r},e=(v.normal=e(t(e=>e)),v.multiply=e(t((e,t)=>e*t/255)),v.screen=e(t((e,t)=>255*(1-(1-e/255)*(1-t/255)))),v.overlay=e(t((e,t)=>t<128?2*e*t/255:255*(1-2*(1-e/255)*(1-t/255)))),v.darken=e(t((e,t)=>tt255===e||255<(e=t/255*255/(1-e/255))?255:e)),v.burn=e(t((e,t)=>255*(1-(1-t/255)/(e/255)))),v),{pow:Ft,sin:Tt,cos:Bt}=Math;var{floor:Vt,random:Dt}=Math,{log:Kt,pow:qt,floor:zt,abs:Wt}=Math;function Ht(e,t=null){const r={min:Number.MAX_VALUE,max:-1*Number.MAX_VALUE,sum:0,values:[],count:0};return(e="object"===O(e)?Object.values(e):e).forEach(e=>{null==(e=t&&"object"===O(e)?e[t]:e)||isNaN(e)||(r.values.push(e),r.sum+=e,er.max&&(r.max=e),r.count+=1)}),r.domain=[r.min,r.max],r.limits=(e,t)=>Yt(r,e,t),r}function Yt(e,t="equal",n=7){var{min:i,max:o}=e="array"==O(e)?Ht(e):e,l=e.values.sort((e,t)=>e-t);if(1===n)return[i,o];var c=[];if("c"===t.substr(0,1)&&(c.push(i),c.push(o)),"e"===t.substr(0,1)){c.push(i);for(let e=1;e 0");var r=Math.LOG10E*Kt(i),a=Math.LOG10E*Kt(o);c.push(i);for(let e=1;ee-t),c.push(a[0]);for(let e=1;e[e.toLowerCase(),e])),sr="function"==typeof Proxy?new Proxy(sr,{get(e,t){t=t.toLowerCase();if(ir.has(t))return e[ir.get(t)]},getOwnPropertyNames(){return Object.getOwnPropertyNames(nr)}}):sr,x=(...e)=>{var[t,r,a,s]=e=p(e,"cmyk"),e=4{var[e,t,r]=p(e,"rgb"),a=1-or(e/=255,or(t/=255,r/=255)),s=a<1?1/(1-a):0;return[(1-e-a)*s,(1-t-a)*s,(1-r-a)*s,a]},cr=(m.prototype.cmyk=function(){return lr(this._rgb)},Object.assign(R,{cmyk:(...e)=>new m(...e,"cmyk")}),i.format.cmyk=x,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"cmyk"))&&4===e.length)return"cmyk"}}),(...e)=>{var t=p(e,"hsla");let r=l(e)||"lsa";return t[0]=a(t[0]||0)+"deg",t[1]=a(100*t[1])+"%",t[2]=a(100*t[2])+"%","hsla"===r||3{var t=p(e,"lab"),e=l(e)||"lab";return t[0]=a(t[0])+"%",t[1]=a(t[1]),t[2]=a(t[2]),"laba"===e||3{var t=p(e,"lch"),e=l(e)||"lab";return t[0]=a(t[0])+"%",t[1]=a(t[1]),t[2]=isNaN(t[2])?"none":a(t[2])+"deg","lcha"===e||3{e=p(e,"lab");return e[0]=a(100*e[0])+"%",e[1]=Ie(e[1]),e[2]=Ie(e[2]),3{var[e,t,r,...a]=p(e,"rgb"),[e,t,r]=Nt(e,t,r),[e,t,r]=ct(e,t,r);return[e,t,r,...0{e=p(e,"lch");return e[0]=a(100*e[0])+"%",e[1]=Ie(e[1]),e[2]=isNaN(e[2])?"none":a(e[2])+"deg",3{var t,r=p(e,"rgba");let a=l(e)||"rgb";return"hsl"===a.substr(0,3)?cr(wt(r),a):"lab"===a.substr(0,3)?(e=We(),c("d50"),t=ur(Ze(r),a),c(e),t):"lch"===a.substr(0,3)?(e=We(),c("d50"),t=hr(ut(r),a),c(e),t):"oklab"===a.substr(0,5)?fr(Nt(r)):"oklch"===a.substr(0,5)?pr(dr(r)):(r[0]=gr(r[0]),r[1]=gr(r[1]),r[2]=gr(r[2]),("rgba"===a||3{var[e,t,r,...a]=e=p(e,"lch"),[e,t,r]=st(e,t,r),[e,t,r]=Rt(e,t,r);return[e,t,r,...0e.map((e,t)=>t<=2?L(Pr(e),0,255):e),$=(e,t=0,r=100,a=!1)=>("string"==typeof e&&e.endsWith("%")&&(e=parseFloat(e.substring(0,e.length-1))/100,e=a?t+.5*(e+1)*(r-t):t+e*(r-t)),+e),A=(e,t)=>"none"===e?t:e,x=e=>{if("transparent"===(e=e.toLowerCase().trim()))return[0,0,0,0];let r;if(i.format.named)try{return i.format.named(e)}catch(e){}if(r=(r=e.match(wr))||e.match(kr)){let t=r.slice(1,4);for(let e=0;e<3;e++)t[e]=+$(A(t[e],0),0,255);t=E(t);var a=void 0!==r[4]?+$(r[4],0,1):1;return t[3]=a,t}if(r=e.match(xr)){var t=r.slice(1,5);for(let e=0;e<4;e++)t[e]=+$(t[e],0,255);return t}if(r=(r=e.match(Sr))||e.match(Lr))return(a=r.slice(1,4))[0]=+A(a[0].replace("deg",""),0),a[1]=.01*+$(A(a[1],0),0,100),a[2]=.01*+$(A(a[2],0),0,100),a=E(yt(a)),s=void 0!==r[4]?+$(r[4],0,1):1,a[3]=s,a;if(r=e.match(Or)){var s=r.slice(1,4),n=(s[1]*=.01,s[2]*=.01,yt(s));for(let e=0;e<3;e++)n[e]=Pr(n[e]);return n[3]=+r[4],n}return(r=e.match(Rr))?((a=r.slice(1,4))[0]=$(A(a[0],0),0,100),a[1]=$(A(a[1],0),-125,125,!0),a[2]=$(A(a[2],0),-125,125,!0),s=We(),c("d50"),a=E(Ge(a)),c(s),s=void 0!==r[4]?+$(r[4],0,1):1,a[3]=s,a):(r=e.match(Nr))?((s=r.slice(1,4))[0]=$(s[0],0,100),s[1]=$(A(s[1],0),0,150,!1),s[2]=+A(s[2].replace("deg",""),0),a=We(),c("d50"),s=E(nt(s)),c(a),a=void 0!==r[4]?+$(r[4],0,1):1,s[3]=a,s):(r=e.match(Cr))?((a=r.slice(1,4))[0]=$(A(a[0],0),0,1),a[1]=$(A(a[1],0),-.4,.4,!0),a[2]=$(A(a[2],0),-.4,.4,!0),s=E(Rt(a)),a=void 0!==r[4]?+$(r[4],0,1):1,s[3]=a,s):(r=e.match(jr))?((a=r.slice(1,4))[0]=$(A(a[0],0),0,1),a[1]=$(A(a[1],0),0,.4,!1),a[2]=+A(a[2].replace("deg",""),0),s=E(br(a)),e=void 0!==r[4]?+$(r[4],0,1):1,s[3]=e,s):void 0},Mr=(x.test=e=>wr.test(e)||Sr.test(e)||Rr.test(e)||Nr.test(e)||Cr.test(e)||jr.test(e)||kr.test(e)||xr.test(e)||Lr.test(e)||Or.test(e)||"transparent"===e,x),Er=(m.prototype.css=function(e){return mr(this._rgb,e)},R.css=(...e)=>new m(...e,"css"),i.format.css=Mr,i.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&"string"===O(e)&&Mr.test(e))return"css"}}),i.format.gl=(...e)=>{e=p(e,"rgba");return e[0]*=255,e[1]*=255,e[2]*=255,e},R.gl=(...e)=>new m(...e,"gl"),m.prototype.gl=function(){var e=this._rgb;return[e[0]/255,e[1]/255,e[2]/255,e[3]]},m.prototype.hex=function(e){return Ke(this._rgb,e)},(R.hex=(...e)=>new m(...e,"hex"),i.format.hex=Ve,i.autodetect.push({p:4,test:(e,...t)=>{if(!t.length&&"string"===O(e)&&0<=[3,4,5,6,7,8,9].indexOf(e.length))return"hex"}}),Math)["log"]),$r=e=>{e/=100;let t,r,a;return a=e<66?(t=255,r=e<6?0:-155.25485562709179-.44596950469579133*(r=e-2)+104.49216199393888*Er(r),e<20?0:.8274096064007395*(a=e-10)-254.76935184120902+115.67994401066147*Er(a)):(t=351.97690566805693+.114206453784165*(t=e-55)-40.25366309332127*Er(t),r=325.4494125711974+.07943456536662342*(r=e-50)-28.0852963507957*Er(r),255),[t,r,a,1]},Ar=Math["round"],Ir=(...e)=>{var e=p(e,"rgb"),t=e[0],r=e[2];let a=1e3,s=4e4;let n;for(;.4=r/t?s=n:a=n}return Ar(n)},N=(m.prototype.temp=m.prototype.kelvin=m.prototype.temperature=function(){return Ir(this._rgb)},(...e)=>new m(...e,"temp")),_r=(Object.assign(R,{temp:N,kelvin:N,temperature:N}),i.format.temp=i.format.kelvin=i.format.temperature=$r,m.prototype.oklch=function(){return dr(this._rgb)},Object.assign(R,{oklch:(...e)=>new m(...e,"oklch")}),i.format.oklch=br,i.autodetect.push({p:2,test:(...e)=>{if("array"===O(e=p(e,"oklch"))&&3===e.length)return"oklch"}}),Object.assign(R,{analyze:Ht,average:(e,o="lrgb",l=null)=>{var t=e.length;const r=t/(l=l||Array.from(new Array(t)).map(()=>1)).reduce(function(e,t){return e+t});if(l.forEach((e,t)=>{l[t]*=r}),e=e.map(e=>new m(e)),"lrgb"===o){var a=e,s=l,n=a.length,i=[0,0,0,0];for(let e=0;e{var r,a=e.get(o);i+=e.alpha()*l[t+1];for(let e=0;e{const t=function(e){let a,s,n,i;if(2===(e=e.map(e=>new m(e))).length)[s,n]=e.map(e=>e.lab()),a=function(t){var e=[0,1,2].map(e=>s[e]+t*(n[e]-s[e]));return new m(e,"lab")};else if(3===e.length)[s,n,i]=e.map(e=>e.lab()),a=function(t){var e=[0,1,2].map(e=>(1-t)*(1-t)*s[e]+2*(1-t)*t*n[e]+t*t*i[e]);return new m(e,"lab")};else if(4===e.length){let r;[s,n,i,r]=e.map(e=>e.lab()),a=function(t){var e=[0,1,2].map(e=>(1-t)*(1-t)*(1-t)*s[e]+3*(1-t)*(1-t)*t*n[e]+3*(1-t)*t*t*i[e]+t*t*t*r[e]);return new m(e,"lab")}}else{if(!(5<=e.length))throw new RangeError("No point in running bezier with only one color.");{let t,i,o;t=e.map(e=>e.lab()),o=e.length-1,i=_t(o),a=function(s){const n=1-s;var e=[0,1,2].map(a=>t.reduce((e,t,r)=>e+i[r]*n**(o-r)*s**r*t[a],0));return new m(e,"lab")}}}return a}(e);return t.scale=()=>It(t),t},blend:e,brewer:sr,Color:m,colors:r,contrast:(e,t)=>{e=new m(e),t=new m(t);e=e.luminance(),t=t.luminance();return t{e=new m(e),t=new m(t);var e=Gt(...(e=e.alpha()<1?s(t,e,e.alpha(),"rgb"):e).rgb()),t=Gt(...t.rgb()),e=.022<=e?e:e+Math.pow(.022-e,1.414),t=.022<=t?t:t+Math.pow(.022-t,1.414),r=Math.pow(t,.56)-Math.pow(e,.57),a=Math.pow(t,.65)-Math.pow(e,.62),e=Math.abs(t-e)<5e-4?0:eR.scale(t),t.hue(i),t},deltaE:function(e,t,r=1,a=1,s=1){function n(e){return 360*e/(2*ar)}function i(e){return 2*ar*e/360}e=new m(e),t=new m(t);var[e,o,l]=Array.from(e.lab()),[t,c,u]=Array.from(t.lab()),h=(e+t)/2,f=(y(k(o,2)+k(l,2))+y(k(c,2)+k(u,2)))/2,f=.5*(1-y(k(f,7)/(k(f,7)+k(25,7)))),c=c*(1+f),f=y(k(o=o*(1+f),2)+k(l,2)),d=y(k(c,2)+k(u,2)),p=(f+d)/2,l=n(Zt(l,o)),o=n(Zt(u,c)),l=180{let t="#";for(let e=0;e<6;e++)t+="0123456789abcdef".charAt(Vt(16*Dt()));return new m(t,"hex")},scale:It,scales:t,valid:(...e)=>{try{return new m(...e),!0}catch(e){return!1}}}),R),I=(e,t)=>{e=localStorage.getItem(e);if(!e)return t;try{return JSON.parse(e)}catch{return e}},Ur=e=>{e=3===e.length?e.split("").map(e=>e+e).join(""):e;if(6!==e.length)throw"Only 3- or 6-digit hex colours are allowed.";if(e.match(/[^0-9a-f]/i))throw"Only hex colours are allowed.";e=e.match(/.{1,2}/g);if(e&&3===e.length)return[Number.parseInt(e[0],16),Number.parseInt(e[1],16),Number.parseInt(e[2],16)];throw"Could not parse hex colour."},Fr=(e,t)=>{let r=[];return e&&0({name:e.name,url:Yr(e.url)})):r.push({name:t,url:"https://github.com/"+t}),r},Tr=(...e)=>{console.debug("Resetting Marketplace");var t=[];if(0===e.length)for(const r in localStorage)r.startsWith("marketplace:")&&t.push(r);for(const a of e)switch(a){case"extensions":t.push(...I(g.installedExtensions,[])),t.push(g.installedExtensions);break;case"snippets":t.push(...I(g.installedSnippets,[])),t.push(g.installedSnippets);break;case"theme":t.push(...I(g.installedThemes,[])),t.push(g.installedThemes),t.push(g.themeInstalled);break;default:console.error("Unknown category: "+a)}for(const s of t)localStorage.removeItem(s),console.debug("Removed "+s);console.debug("Marketplace has been reset"),location.reload()},Br=()=>{var e={};for(const t in localStorage)t.startsWith("marketplace:")&&(e[t]=localStorage.getItem(t));return e},Vr=t=>{var r=document.querySelector("style.marketplaceCSS.marketplaceScheme");if(r&&r.remove(),t){r=document.createElement("style");r.classList.add("marketplaceCSS"),r.classList.add("marketplaceScheme");let e=":root {";for(const a of Object.keys(t))e=(e+=`--spice-${a}: #${t[a]};`)+`--spice-rgb-${a}: ${Ur(t[a])};`;e+="}",r.innerHTML=e,document.body.appendChild(r)}},Dr=async e=>{let t=I(g.albumArtBasedColorVibrancy);return t=t.replace(/([A-Z])/g,"_$1").toUpperCase(),(await Spicetify.colorExtractor(e))[t].substring(1)},Kr=async(e,t)=>{var r=I(g.albumArtBasedColorMode).replace(/([A-Z])/g,"-$1").toLowerCase();return(await fetch(`https://www.thecolorapi.com/scheme?hex=${e}&mode=${r}&count=`+t).then(e=>e.json())).colors.map(e=>e.hex.value.substring(1))};var qr=f=>{Spicetify.Player.addEventListener("songchange",async()=>{var t;t=1e3,await new Promise(e=>setTimeout(e,t));let r=Spicetify.Player.data?.item?.metadata?.image_xlarge_url;if(r=null==r?await new Promise(t=>{setInterval(()=>{var e=Spicetify.Player.data?.item?.metadata?.image_xlarge_url;e&&t(e)},50)}):r){var a,s,n=new Set(Object.values(f)).size,i=await Dr(r),o=await Kr(i,n);let e=new Map;for([a,s]of Object.entries(f))e.has(s)?e.get(s).push(a):e.set(s,[a]);var l,i=new Map([...e.entries()].sort((e,t)=>{e=_r(e[0]),t=_r(t[0]);return e.get("lab.l")-t.get("lab.l")})),c={};for([,l]of(e=i).entries()){var u=o.shift();if(u)for(const h of l)c[h]=u}Vr(c)}})},zr=e=>{e=new URL(e);return e.host,"raw.githubusercontent.com"===e.host},Wr=e=>{e=e.match(/https:\/\/raw\.githubusercontent\.com\/(?[^/]+)\/(?[^/]+)\/(?[^/]+)\/(?.+$)/);return{user:e?e.groups?.user:null,repo:e?e.groups?.repo:null,branch:e?e.groups?.branch:null,filePath:e?e.groups?.filePath:null}};function Hr(e,t){if(e)for(const s of e){var r=t||s.user+"-"+s.repo,a=window.sessionStorage.getItem(r),a=a?JSON.parse(a):[];a.push(s),window.sessionStorage.setItem(r,JSON.stringify(a))}}var Yr=e=>{var t=decodeURI(e).trim().toLowerCase();return t.startsWith("javascript:")||t.startsWith("data:")||t.startsWith("vbscript:")?"about:blank":e},Gr=e=>{e&&(e=e.split("/").pop())&&-1===Spicetify.Config.extensions.indexOf(e)&&Spicetify.Config.extensions.push(e)};async function Jr(){for(const e of["net","xyz"])try{if("opaqueredirect"===(await fetch("https://cdn.jsdelivr."+e,{redirect:"manual",cache:"no-cache"})).type)return e}catch(e){console.error(e)}}var vr=new Blob([` - self.addEventListener('message', async (event) => { - const url = event.data; - const response = await fetch(url); - const data = await response.json().catch(() => null); - self.postMessage(data); - }); -`],{type:"application/javascript"}),Xr=URL.createObjectURL(vr);async function Zr(e,t,r){var a=e+"-"+t,s=window.sessionStorage.getItem(a),n=JSON.parse(window.sessionStorage.getItem("noManifests")||"[]");if(s)return JSON.parse(s);s=`https://raw.githubusercontent.com/${e}/${t}/${r}/manifest.json`;if(n.includes(s))return null;let i=await async function(e){const a=new Worker(Xr);return new Promise(t=>{const r=e=>{a.terminate(),t(e)};a.postMessage(e),a.addEventListener("message",e=>r(e.data),{once:!0}),a.addEventListener("error",()=>r(null),{once:!0})})}(s);return i?(Hr(i=Array.isArray(i)?i:[i],a),i):Hr([s],"noManifests")}async function Qr(e,t){var r=await async function(e,t=1){const r=window.sessionStorage.getItem("marketplace:blacklist");let a=`https://api.github.com/search/repositories?per_page=${Ce}&q=`+encodeURIComponent(`topic:spicetify-${e}s`);t&&(a+="&page="+t);var s=JSON.parse(window.sessionStorage.getItem(`spicetify-${e}s-page-`+t)||"null")||await fetch(a).then(e=>e.json()).catch(()=>null);return s?.items?(window.sessionStorage.setItem(`spicetify-${e}s-page-`+t,JSON.stringify(s)),{...s,page_count:s.items.length,items:s.items.filter(e=>!r?.includes(e.html_url))}):(Spicetify.showNotification(Ne("notifications.tooManyRequests"),!0,5e3),{items:[]})}(e,t),a=(!async function(e,t){for(const r of e.items)"theme"===t?await async function(e,a,s){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return;const{user:n,repo:i}=t.groups;return(await Zr(n,i,a)).reduce((e,t)=>{var r;return t?.name&&t?.usercss&&t?.description&&(r=t.branch||a,r={manifest:t,title:t.name,subtitle:t.description,authors:Fr(t.authors,n),user:n,repo:i,branch:r,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.preview,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.readme,stars:s,tags:t.tags,cssURL:t.usercss.startsWith("http")?t.usercss:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.usercss,schemesURL:t.schemes?t.schemes.startsWith("http")?t.schemes:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.schemes:null,include:t.include},e.push(r)),e},[])}catch{return}}(r.contents_url,r.default_branch,r.stargazers_count):"extension"===t?await async function(e,a,s,n=!1){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return;const{user:i,repo:o}=t.groups;return(await Zr(i,o,a)).reduce((e,t)=>{var r;return t?.name&&t.description&&t.main&&(r=t.branch||a,r={manifest:t,title:t.name,subtitle:t.description,authors:Fr(t.authors,i),user:i,repo:o,branch:r,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${i}/${o}/${r}/`+t.preview,extensionURL:t.main.startsWith("http")?t.main:`https://raw.githubusercontent.com/${i}/${o}/${r}/`+t.main,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${i}/${o}/${r}/`+t.readme,stars:s,tags:t.tags},n&&localStorage.getItem(`marketplace:installed:${i}/${o}/`+t.main)||e.push(r)),e},[])}catch{return}}(r.contents_url,r.default_branch,r.stargazers_count):"app"===t&&await async function(e,a,s){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return;const{user:n,repo:i}=t.groups;return(await Zr(n,i,a)).reduce((e,t)=>{var r;return t?.name&&t.description&&!t.main&&!t.usercss&&(r=t.branch||a,r={manifest:t,title:t.name,subtitle:t.description,authors:Fr(t.authors,n),user:n,repo:i,branch:r,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.preview,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${n}/${i}/${r}/`+t.readme,stars:s,tags:t.tags},e.push(r)),e},[])}catch{return}}(r.contents_url,r.default_branch,r.stargazers_count)}(r,e),Ce*t+r.page_count),s=(console.debug({pageOfRepos:r}),r.total_count-a);if(console.debug(`Parsed ${a}/${r.total_count} ${e}s`),0{t=I(t);if(t){if(console.debug("Initializing theme: ",t),t.schemes){var e=t.schemes[t.activeScheme];if(Vr(e),Spicetify.Config.color_scheme=t.activeScheme,"true"===localStorage.getItem(g.albumArtBasedColor))qr(e);else if("true"===localStorage.getItem(g.colorShift)){var r=t.schemes;let e=0;const f=Object.keys(r).length;setInterval(()=>{e%=f,Vr(Object.values(r)[e]),e++},6e4)}}else console.warn("No schemes found for theme");e=document.querySelector("link.marketplaceCSS"),e=(e&&e.remove(),await(async(e,t)=>{if(!e.cssURL)throw new Error("No CSS URL provided");var t=t||await Jr(),t=zr(e.cssURL)?`https://cdn.jsdelivr.${t}/gh/${e.user}/${e.repo}@${e.branch}/`+e.manifest.usercss:e.cssURL,r=t.replace("/user.css","/assets/");console.debug("Parsing CSS: ",t);let a=await fetch(t+"?time="+Date.now()).then(e=>e.text());for(const i of a.matchAll(/url\(['|"](?.+?)['|"]\)/gm)||[]){var s,n=i?.groups?.path;!n||n.startsWith("http")||n.startsWith("data")||(s=r+n.replace(/\.\//g,""),a=a.replace(n,s))}return a})(t,p));try{var a,s,n=document.querySelector("link[href='user.css']"),i=(n&&n.remove(),document.querySelector("style.marketplaceCSS.marketplaceUserCSS"));i&&i.remove(),e?((a=document.createElement("style")).classList.add("marketplaceCSS"),a.classList.add("marketplaceUserCSS"),a.innerHTML=e,document.body.appendChild(a)):((s=document.createElement("link")).setAttribute("rel","stylesheet"),s.setAttribute("href","user.css"),s.classList.add("userCSS"),document.body.appendChild(s))}catch(e){console.warn(e)}if(Spicetify.Config.current_theme=t.manifest?.name,t.include?.length)for(const d of t.include){var o=document.createElement("script");let e=d;if(zr(d)){var{user:l,repo:c,branch:u,filePath:h}=Wr(d);if(!(l&&c&&u&&h))return;e=`https://cdn.jsdelivr.${p}/gh/${l}/${c}@${u}/`+h,h.endsWith(".mjs")&&(o.type="module")}o.src=e+"?time="+Date.now(),o.classList.add("marketplaceScript"),document.body.appendChild(o),Gr(d)}}else console.debug("No theme manifest found")};console.log("Loaded Marketplace extension");var r=I(g.installedSnippets,[]).map(e=>I(e));if(r=r,(a=document.querySelector("style.marketplaceSnippets"))&&a.remove(),a=document.createElement("style"),r=r.reduce((e,t)=>`${e}/* ${t.title} - ${t.description} */ -${t.code} -`,""),a.innerHTML=r,a.classList.add("marketplaceSnippets"),document.body.appendChild(a),p){window.sessionStorage.setItem("marketplace-request-tld",p);for(const s of I(g.installedExtensions,[]))(e=>{e=I(e);if(e&&e.extensionURL){console.debug("Initializing extension: ",e);var t=document.createElement("script");if(t.defer=!0,t.src=e.extensionURL,zr(t.src)){var{user:r,repo:a,branch:s,filePath:n}=Wr(e.extensionURL);if(!(r&&a&&s&&n))return;t.src=`https://cdn.jsdelivr.${p}/gh/${r}/${a}@${s}/`+n,n.endsWith(".mjs")&&(t.type="module")}t.src=t.src+"?time="+Date.now(),document.body.appendChild(t),Gr(e.manifest?.main)}})(s);var r=Spicetify.Config["current_theme"],a=(localStorage.setItem(g.localTheme,r),localStorage.getItem(g.themeInstalled));a&&("marketplace"!==r.toLocaleLowerCase()?Spicetify.showNotification(Ne("notifications.wrongLocalTheme"),!0,5e3):t(a))}else window.navigator.onLine?(console.error(new Error("Unable to connect to the CDN, please check your Internet configuration.")),Spicetify.showNotification(Ne("notifications.noCdnConnection"),!0,5e3)):window.addEventListener("online",e,{once:!0})}else setTimeout(e,100)}(),async function(){console.debug("Preloading extensions and themes..."),window.sessionStorage.clear();var e=await(await fetch("https://raw.githubusercontent.com/spicetify/marketplace/main/resources/blacklist.json").then(e=>e.json()).catch(()=>({}))).repos;window.sessionStorage.setItem("marketplace:blacklist",JSON.stringify(e)),await Promise.all([Qr("extension",0),Qr("theme",0),Qr("app",0)])}()})()}(); \ No newline at end of file diff --git a/.config/spicetify/CustomApps/marketplace/index.js b/.config/spicetify/CustomApps/marketplace/index.js deleted file mode 100644 index 5c33814..0000000 --- a/.config/spicetify/CustomApps/marketplace/index.js +++ /dev/null @@ -1,180 +0,0 @@ -var marketplace=(()=>{var k,E=Object.create,A=Object.defineProperty,T=Object.getOwnPropertyDescriptor,O=Object.getOwnPropertyNames,P=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty,e=(e,t)=>function(){return t||(0,e[O(e)[0]])((t={exports:{}}).exports,t),t.exports},R=(t,a,r,n)=>{if(a&&"object"==typeof a||"function"==typeof a)for(let e of O(a))M.call(t,e)||e===r||A(t,e,{get:()=>a[e],enumerable:!(n=T(a,e))||n.enumerable});return t},t=(e,t,a)=>(a=null!=e?E(P(e)):{},R(!t&&e&&e.__esModule?a:A(a,"default",{value:e,enumerable:!0}),e)),a=e({"external-global-plugin:react"(e,t){t.exports=Spicetify.React}}),_=e({"node_modules/.pnpm/void-elements@3.1.0/node_modules/void-elements/index.js"(e,t){t.exports={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0}}}),V=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/constants.js"(e,t){"use strict";var a=Number.MAX_SAFE_INTEGER||9007199254740991;t.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:a,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}}}),B=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/debug.js"(e,t){"use strict";var a="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};t.exports=a}}),X=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/re.js"(e,t){"use strict";var{MAX_SAFE_COMPONENT_LENGTH:a,MAX_SAFE_BUILD_LENGTH:r,MAX_LENGTH:n}=V(),o=B(),i=(e=t.exports={}).re=[],s=e.safeRe=[],l=e.src=[],c=e.safeSrc=[],d=e.t={},u=0,t="[a-zA-Z0-9-]",p=[["\\s",1],["\\d",n],[t,r]],n=(e,t,a)=>{var r=(e=>{for(var[t,a]of p)e=e.split(t+"*").join(`${t}{0,${a}}`).split(t+"+").join(`${t}{1,${a}}`);return e})(t),n=u++;o(e,n,t),d[e]=n,l[n]=t,c[n]=r,i[n]=new RegExp(t,a?"g":void 0),s[n]=new RegExp(r,a?"g":void 0)};n("NUMERICIDENTIFIER","0|[1-9]\\d*"),n("NUMERICIDENTIFIERLOOSE","\\d+"),n("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${t}*`),n("MAINVERSION",`(${l[d.NUMERICIDENTIFIER]})\\.(${l[d.NUMERICIDENTIFIER]})\\.(${l[d.NUMERICIDENTIFIER]})`),n("MAINVERSIONLOOSE",`(${l[d.NUMERICIDENTIFIERLOOSE]})\\.(${l[d.NUMERICIDENTIFIERLOOSE]})\\.(${l[d.NUMERICIDENTIFIERLOOSE]})`),n("PRERELEASEIDENTIFIER",`(?:${l[d.NONNUMERICIDENTIFIER]}|${l[d.NUMERICIDENTIFIER]})`),n("PRERELEASEIDENTIFIERLOOSE",`(?:${l[d.NONNUMERICIDENTIFIER]}|${l[d.NUMERICIDENTIFIERLOOSE]})`),n("PRERELEASE",`(?:-(${l[d.PRERELEASEIDENTIFIER]}(?:\\.${l[d.PRERELEASEIDENTIFIER]})*))`),n("PRERELEASELOOSE",`(?:-?(${l[d.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${l[d.PRERELEASEIDENTIFIERLOOSE]})*))`),n("BUILDIDENTIFIER",t+"+"),n("BUILD",`(?:\\+(${l[d.BUILDIDENTIFIER]}(?:\\.${l[d.BUILDIDENTIFIER]})*))`),n("FULLPLAIN",`v?${l[d.MAINVERSION]}${l[d.PRERELEASE]}?${l[d.BUILD]}?`),n("FULL",`^${l[d.FULLPLAIN]}$`),n("LOOSEPLAIN",`[v=\\s]*${l[d.MAINVERSIONLOOSE]}${l[d.PRERELEASELOOSE]}?${l[d.BUILD]}?`),n("LOOSE",`^${l[d.LOOSEPLAIN]}$`),n("GTLT","((?:<|>)?=?)"),n("XRANGEIDENTIFIERLOOSE",l[d.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*"),n("XRANGEIDENTIFIER",l[d.NUMERICIDENTIFIER]+"|x|X|\\*"),n("XRANGEPLAIN",`[v=\\s]*(${l[d.XRANGEIDENTIFIER]})(?:\\.(${l[d.XRANGEIDENTIFIER]})(?:\\.(${l[d.XRANGEIDENTIFIER]})(?:${l[d.PRERELEASE]})?${l[d.BUILD]}?)?)?`),n("XRANGEPLAINLOOSE",`[v=\\s]*(${l[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${l[d.XRANGEIDENTIFIERLOOSE]})(?:${l[d.PRERELEASELOOSE]})?${l[d.BUILD]}?)?)?`),n("XRANGE",`^${l[d.GTLT]}\\s*${l[d.XRANGEPLAIN]}$`),n("XRANGELOOSE",`^${l[d.GTLT]}\\s*${l[d.XRANGEPLAINLOOSE]}$`),n("COERCEPLAIN",`(^|[^\\d])(\\d{1,${a}})(?:\\.(\\d{1,${a}}))?(?:\\.(\\d{1,${a}}))?`),n("COERCE",l[d.COERCEPLAIN]+"(?:$|[^\\d])"),n("COERCEFULL",l[d.COERCEPLAIN]+`(?:${l[d.PRERELEASE]})?(?:${l[d.BUILD]})?(?:$|[^\\d])`),n("COERCERTL",l[d.COERCE],!0),n("COERCERTLFULL",l[d.COERCEFULL],!0),n("LONETILDE","(?:~>?)"),n("TILDETRIM",`(\\s*)${l[d.LONETILDE]}\\s+`,!0),e.tildeTrimReplace="$1~",n("TILDE",`^${l[d.LONETILDE]}${l[d.XRANGEPLAIN]}$`),n("TILDELOOSE",`^${l[d.LONETILDE]}${l[d.XRANGEPLAINLOOSE]}$`),n("LONECARET","(?:\\^)"),n("CARETTRIM",`(\\s*)${l[d.LONECARET]}\\s+`,!0),e.caretTrimReplace="$1^",n("CARET",`^${l[d.LONECARET]}${l[d.XRANGEPLAIN]}$`),n("CARETLOOSE",`^${l[d.LONECARET]}${l[d.XRANGEPLAINLOOSE]}$`),n("COMPARATORLOOSE",`^${l[d.GTLT]}\\s*(${l[d.LOOSEPLAIN]})$|^$`),n("COMPARATOR",`^${l[d.GTLT]}\\s*(${l[d.FULLPLAIN]})$|^$`),n("COMPARATORTRIM",`(\\s*)${l[d.GTLT]}\\s*(${l[d.LOOSEPLAIN]}|${l[d.XRANGEPLAIN]})`,!0),e.comparatorTrimReplace="$1$2$3",n("HYPHENRANGE",`^\\s*(${l[d.XRANGEPLAIN]})\\s+-\\s+(${l[d.XRANGEPLAIN]})\\s*$`),n("HYPHENRANGELOOSE",`^\\s*(${l[d.XRANGEPLAINLOOSE]})\\s+-\\s+(${l[d.XRANGEPLAINLOOSE]})\\s*$`),n("STAR","(<|>)?=?\\s*\\*"),n("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),n("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")}}),j=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/parse-options.js"(e,t){"use strict";var a=Object.freeze({loose:!0}),r=Object.freeze({});t.exports=e=>e?"object"!=typeof e?a:e:r}}),Q=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/identifiers.js"(e,t){"use strict";var n=/^[0-9]+$/,a=(e,t)=>{var a=n.test(e),r=n.test(t);return a&&r&&(e=+e,t=+t),e===t?0:a&&!r||(!r||a)&&ea(t,e)}}}),G=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/classes/semver.js"(e,t){"use strict";var n=B(),{MAX_LENGTH:a,MAX_SAFE_INTEGER:r}=V(),{safeRe:o,t:i}=X(),s=j(),l=Q()["compareIdentifiers"],c=class{constructor(e,t){if(t=s(t),e instanceof c){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if("string"!=typeof e)throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>a)throw new TypeError(`version is longer than ${a} characters`);n("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;t=e.trim().match(t.loose?o[i.LOOSE]:o[i.FULL]);if(!t)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+t[1],this.minor=+t[2],this.patch=+t[3],this.major>r||this.major<0)throw new TypeError("Invalid major version");if(this.minor>r||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>r||this.patch<0)throw new TypeError("Invalid patch version");t[4]?this.prerelease=t[4].split(".").map(e=>{if(/^[0-9]+$/.test(e)){var t=+e;if(0<=t&&t{if(e instanceof r)return e;try{return new r(e,t)}catch(e){if(a)throw e;return null}}}}),te=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/valid.js"(e,t){"use strict";var a=ee();t.exports=(e,t)=>{e=a(e,t);return e?e.version:null}}}),ae=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/clean.js"(e,t){"use strict";var a=ee();t.exports=(e,t)=>{e=a(e.trim().replace(/^[=v]+/,""),t);return e?e.version:null}}}),re=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/inc.js"(e,t){"use strict";var o=G();t.exports=(e,t,a,r,n)=>{"string"==typeof a&&(n=r,r=a,a=void 0);try{return new o(e instanceof o?e.version:e,a).inc(t,r,n).version}catch(e){return null}}}}),ne=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/diff.js"(e,t){"use strict";var o=ee();t.exports=(e,t)=>{var e=o(e,null,!0),t=o(t,null,!0),a=e.compare(t);if(0===a)return null;var a=0new a(e,t).major}}),ie=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/minor.js"(e,t){"use strict";var a=G();t.exports=(e,t)=>new a(e,t).minor}}),se=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/patch.js"(e,t){"use strict";var a=G();t.exports=(e,t)=>new a(e,t).patch}}),le=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/prerelease.js"(e,t){"use strict";var a=ee();t.exports=(e,t)=>{e=a(e,t);return e&&e.prerelease.length?e.prerelease:null}}}),ce=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/compare.js"(e,t){"use strict";var r=G();t.exports=(e,t,a)=>new r(e,a).compare(new r(t,a))}}),de=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/rcompare.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>r(t,e,a)}}),ue=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/compare-loose.js"(e,t){"use strict";var a=ce();t.exports=(e,t)=>a(e,t,!0)}}),pe=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/compare-build.js"(e,t){"use strict";var r=G();t.exports=(e,t,a)=>{e=new r(e,a),t=new r(t,a);return e.compare(t)||e.compareBuild(t)}}}),me=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/sort.js"(e,t){"use strict";var r=pe();t.exports=(e,a)=>e.sort((e,t)=>r(e,t,a))}}),he=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/rsort.js"(e,t){"use strict";var r=pe();t.exports=(e,a)=>e.sort((e,t)=>r(t,e,a))}}),ge=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/gt.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>0r(e,t,a)<0}}),be=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/eq.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>0===r(e,t,a)}}),ve=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/neq.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>0!==r(e,t,a)}}),ye=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/gte.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>0<=r(e,t,a)}}),Se=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/lte.js"(e,t){"use strict";var r=ce();t.exports=(e,t,a)=>r(e,t,a)<=0}}),we=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/cmp.js"(e,t){"use strict";var n=be(),o=ve(),i=ge(),s=ye(),l=fe(),c=Se();t.exports=(e,t,a,r)=>{switch(t){case"===":return(e="object"==typeof e?e.version:e)===(a="object"==typeof a?a.version:a);case"!==":return(e="object"==typeof e?e.version:e)!==(a="object"==typeof a?a.version:a);case"":case"=":case"==":return n(e,a,r);case"!=":return o(e,a,r);case">":return i(e,a,r);case">=":return s(e,a,r);case"<":return l(e,a,r);case"<=":return c(e,a,r);default:throw new TypeError("Invalid operator: "+t)}}}}),ke=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/coerce.js"(e,t){"use strict";var d=G(),u=ee(),{safeRe:p,t:m}=X();t.exports=(e,t)=>{if(e instanceof d)return e;if("string"!=typeof(e="number"==typeof e?String(e):e))return null;let a=null;if((t=t||{}).rtl){for(var r,n=t.includePrerelease?p[m.COERCERTLFULL]:p[m.COERCERTL];(r=n.exec(e))&&(!a||a.index+a[0].length!==e.length);)a&&r.index+r[0].length===a.index+a[0].length||(a=r),n.lastIndex=r.index+r[1].length+r[2].length;n.lastIndex=-1}else a=e.match(t.includePrerelease?p[m.COERCEFULL]:p[m.COERCE]);var o,i,s,l,c;return null===a?null:(o=a[2],i=a[3]||"0",s=a[4]||"0",l=t.includePrerelease&&a[5]?"-"+a[5]:"",c=t.includePrerelease&&a[6]?"+"+a[6]:"",u(o+`.${i}.`+s+l+c,t))}}}),$=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/internal/lrucache.js"(e,t){"use strict";t.exports=class{constructor(){this.max=1e3,this.map=new Map}get(e){var t=this.map.get(e);if(void 0!==t)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){var a;return this.delete(e)||void 0===t||(this.map.size>=this.max&&(a=this.map.keys().next().value,this.delete(a)),this.map.set(e,t)),this}}}}),Ee=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/classes/range.js"(e,t){"use strict";var r=/\s+/g,n=class{constructor(e,t){if(t=o(t),e instanceof n)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new n(e.raw,t);if(e instanceof l)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(r," "),this.set=this.raw.split("||").map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);if(1!b(e[0])),0===this.set.length)this.set=[t];else if(1y(e,this.options)).join(" ").split(/\s+/).map(e=>A(e,this.options));a&&(n=n.filter(e=>(u("loose invalid filter",e,this.options),!!e.match(p[m.COMPARATORLOOSE])))),u("range list",n);var o=new Map;for(const i of n.map(e=>new l(e,this.options))){if(b(i))return[i];o.set(i.value,i)}1v(t,a)&&e.set.some(e=>v(e,a)&&t.every(t=>e.every(e=>t.intersects(e,a)))));throw new TypeError("a Range is required")}test(t){if(t){if("string"==typeof t)try{t=new a(t,this.options)}catch(e){return!1}for(let e=0;e"<0.0.0-0"===e.value,i=e=>""===e.value,v=(e,t)=>{let a=!0;var r=e.slice();let n=r.pop();for(;a&&r.length;)a=r.every(e=>n.intersects(e,t)),n=r.pop();return a},y=(e,t)=>(u("comp",e,t),e=E(e,t),u("caret",e),e=w(e,t),u("tildes",e),e=I(e,t),u("xrange",e),e=N(e,t),u("stars",e),e),S=e=>!e||"x"===e.toLowerCase()||"*"===e,w=(e,t)=>e.trim().split(/\s+/).map(e=>k(e,t)).join(" "),k=(i,e)=>{e=e.loose?p[m.TILDELOOSE]:p[m.TILDE];return i.replace(e,(e,t,a,r,n)=>{u("tilde",i,e,t,a,r,n);let o;return o=S(t)?"":S(a)?`>=${t}.0.0 <${+t+1}.0.0-0`:S(r)?`>=${t}.${a}.0 <${t}.${+a+1}.0-0`:n?(u("replaceTilde pr",n),`>=${t}.${a}.${r}-${n} <${t}.${+a+1}.0-0`):`>=${t}.${a}.${r} <${t}.${+a+1}.0-0`,u("tilde return",o),o})},E=(e,t)=>e.trim().split(/\s+/).map(e=>C(e,t)).join(" "),C=(i,e)=>{u("caret",i,e);var t=e.loose?p[m.CARETLOOSE]:p[m.CARET];const s=e.includePrerelease?"-0":"";return i.replace(t,(e,t,a,r,n)=>{u("caret",i,e,t,a,r,n);let o;return o=S(t)?"":S(a)?`>=${t}.0.0${s} <${+t+1}.0.0-0`:S(r)?"0"===t?`>=${t}.${a}.0${s} <${t}.${+a+1}.0-0`:`>=${t}.${a}.0${s} <${+t+1}.0.0-0`:n?(u("replaceCaret pr",n),"0"===t?"0"===a?`>=${t}.${a}.${r}-${n} <${t}.${a}.${+r+1}-0`:`>=${t}.${a}.${r}-${n} <${t}.${+a+1}.0-0`:`>=${t}.${a}.${r}-${n} <${+t+1}.0.0-0`):(u("no pr"),"0"===t?"0"===a?`>=${t}.${a}.${r}${s} <${t}.${a}.${+r+1}-0`:`>=${t}.${a}.${r}${s} <${t}.${+a+1}.0-0`:`>=${t}.${a}.${r} <${+t+1}.0.0-0`),u("caret return",o),o})},I=(e,t)=>(u("replaceXRanges",e,t),e.split(/\s+/).map(e=>x(e,t)).join(" ")),x=(c,d)=>{c=c.trim();var e=d.loose?p[m.XRANGELOOSE]:p[m.XRANGE];return c.replace(e,(e,t,a,r,n,o)=>{u("xRange",c,e,t,a,r,n,o);var i=S(a),s=i||S(r),l=s||S(n);return"="===t&&l&&(t=""),o=d.includePrerelease?"-0":"",i?e=">"===t||"<"===t?"<0.0.0-0":"*":t&&l?(s&&(r=0),n=0,">"===t?(t=">=",n=s?(a=+a+1,r=0):(r=+r+1,0)):"<="===t&&(t="<",s?a=+a+1:r=+r+1),e=t+a+`.${r}.`+n+(o="<"===t?"-0":o)):s?e=`>=${a}.0.0${o} <${+a+1}.0.0-0`:l&&(e=`>=${a}.${r}.0${o} <${a}.${+r+1}.0-0`),u("xRange return",e),e})},N=(e,t)=>(u("replaceStars",e,t),e.trim().replace(p[m.STAR],"")),A=(e,t)=>(u("replaceGTE0",e,t),e.trim().replace(p[t.includePrerelease?m.GTE0PRE:m.GTE0],"")),T=p=>(e,t,a,r,n,o,i,s,l,c,d,u)=>((t=S(a)?"":S(r)?`>=${a}.0.0`+(p?"-0":""):S(n)?`>=${a}.${r}.0`+(p?"-0":""):o?">="+t:">="+t+(p?"-0":""))+" "+(s=S(l)?"":S(c)?`<${+l+1}.0.0-0`:S(d)?`<${l}.${+c+1}.0-0`:u?`<=${l}.${c}.${d}-`+u:p?`<${l}.${c}.${+d+1}-0`:"<="+s)).trim(),O=(t,a,e)=>{for(let e=0;e")||!e.operator.startsWith(">"))&&!(this.operator.startsWith("<")&&e.operator.startsWith("<")||this.semver.version===e.semver.version&&this.operator.includes("=")&&e.operator.includes("=")||s(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<")||s(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">")));throw new TypeError("a Comparator is required")}},n=(t.exports=r,j()),{safeRe:o,t:i}=X(),s=we(),l=B(),c=G(),d=Ee()}}),Ie=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/functions/satisfies.js"(e,t){"use strict";var r=Ee();t.exports=(e,t,a)=>{try{t=new r(t,a)}catch(e){return!1}return t.test(e)}}}),xe=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/to-comparators.js"(e,t){"use strict";var a=Ee();t.exports=(e,t)=>new a(e,t).set.map(e=>e.map(e=>e.value).join(" ").trim().split(" "))}}),Ne=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/max-satisfying.js"(e,t){"use strict";var i=G(),s=Ee();t.exports=(e,t,a)=>{let r=null,n=null,o=null;try{o=new s(t,a)}catch(e){return null}return e.forEach(e=>{!o.test(e)||r&&-1!==n.compare(e)||(r=e,n=new i(r,a))}),r}}}),Ae=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/min-satisfying.js"(e,t){"use strict";var i=G(),s=Ee();t.exports=(e,t,a)=>{let r=null,n=null,o=null;try{o=new s(t,a)}catch(e){return null}return e.forEach(e=>{!o.test(e)||r&&1!==n.compare(e)||(r=e,n=new i(r,a))}),r}}}),Te=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/min-version.js"(e,t){"use strict";var o=G(),a=Ee(),i=ge();t.exports=(t,e)=>{t=new a(t,e);let r=new o("0.0.0");if(t.test(r))return r;if(r=new o("0.0.0-0"),t.test(r))return r;r=null;for(let e=0;e{var t=new o(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":a&&!i(t,a)||(a=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}),!a||r&&!i(r,a)||(r=a)}return r&&t.test(r)?r:null}}}),Oe=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/valid.js"(e,t){"use strict";var a=Ee();t.exports=(e,t)=>{try{return new a(e,t).range||"*"}catch(e){return null}}}}),Le=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/outside.js"(e,t){"use strict";var a=G(),p=Ce(),m=p["ANY"],h=Ee(),g=Ie(),f=ge(),b=fe(),v=Se(),y=ye();t.exports=(r,n,e,o)=>{r=new a(r,o),n=new h(n,o);let i,s,l,c,d;switch(e){case">":i=f,s=v,l=b,c=">",d=">=";break;case"<":i=b,s=y,l=f,c="<",d="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(g(r,n,o))return!1;for(let e=0;e{e.semver===m&&(e=new p(">=0.0.0")),t=t||e,a=a||e,i(e.semver,t.semver,o)?t=e:l(e.semver,a.semver,o)&&(a=e)}),t.operator===c||t.operator===d)return!1;if((!a.operator||a.operator===c)&&s(r,a.semver))return!1;if(a.operator===d&&l(r,a.semver))return!1}return!0}}}),De=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/gtr.js"(e,t){"use strict";var r=Le();t.exports=(e,t,a)=>r(e,t,">",a)}}),Pe=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/ltr.js"(e,t){"use strict";var r=Le();t.exports=(e,t,a)=>r(e,t,"<",a)}}),Me=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/intersects.js"(e,t){"use strict";var r=Ee();t.exports=(e,t,a)=>(e=new r(e,a),t=new r(t,a),e.intersects(t,a))}}),Re=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/ranges/simplify.js"(e,t){"use strict";var m=Ie(),h=ce();t.exports=(e,t,a)=>{var r=[];let n=null,o=null;var i=e.sort((e,t)=>h(e,t,a));for(const p of i){var s=m(p,t,a);n=s?(o=p,n||p):(o&&r.push([n,o]),o=null)}n&&r.push([n,null]);var l,c,d=[];for([l,c]of r)l===c?d.push(l):c||l!==i[0]?c?l===i[0]?d.push("<="+c):d.push(l+" - "+c):d.push(">="+l):d.push("*");var e=d.join(" || "),u="string"==typeof t.raw?t.raw:String(t);return e.length=0.0.0-0")],w=[new a(">=0.0.0")],k=(e,t,a)=>{return!e||!(0<(a=y(e.semver,t.semver,a)))&&(a<0||">"===t.operator&&">="===e.operator)?t:e},E=(e,t,a)=>{return!e||!((a=y(e.semver,t.semver,a))<0)&&(0{if(t!==a){t=new s(t,r),a=new s(a,r);let e=!1;e:for(const o of t.set){for(const i of a.set){var n=((s,l,c)=>{if(s!==l){if(1===s.length&&s[0].semver===b){if(1===l.length&&l[0].semver===b)return!0;s=c.includePrerelease?S:w}if(1===l.length&&l[0].semver===b){if(c.includePrerelease)return!0;l=w}var d=new Set,u,p;let e,t;for(const m of s)">"===m.operator||">="===m.operator?e=k(e,m,c):"<"===m.operator||"<="===m.operator?t=E(t,m,c):d.add(m.semver);if(1="!==e.operator||"<="!==t.operator))return null}for(const h of d){if(e&&!v(h,String(e),c))return null;if(t&&!v(h,String(t),c))return null;for(const g of l)if(!v(h,String(g),c))return!1;return!0}let r,n,o=!(!t||c.includePrerelease||!t.semver.prerelease.length)&&t.semver,i=!(!e||c.includePrerelease||!e.semver.prerelease.length)&&e.semver;o&&1===o.prerelease.length&&"<"===t.operator&&0===o.prerelease[0]&&(o=!1);for(const f of l){if(n=n||">"===f.operator||">="===f.operator,r=r||"<"===f.operator||"<="===f.operator,e)if(i&&f.semver.prerelease&&f.semver.prerelease.length&&f.semver.major===i.major&&f.semver.minor===i.minor&&f.semver.patch===i.patch&&(i=!1),">"===f.operator||">="===f.operator){if((u=k(e,f,c))===f&&u!==e)return!1}else if(">="===e.operator&&!v(e.semver,String(f),c))return!1;if(t)if(o&&f.semver.prerelease&&f.semver.prerelease.length&&f.semver.major===o.major&&f.semver.minor===o.minor&&f.semver.patch===o.patch&&(o=!1),"<"===f.operator||"<="===f.operator){if((p=E(t,f,c))===f&&p!==t)return!1}else if("<="===t.operator&&!v(t.semver,String(f),c))return!1;if(!f.operator&&(t||e)&&0!==a)return!1}if(e&&r&&!t&&0!==a)return!1;if(t&&n&&!e&&0!==a)return!1;if(i||o)return!1}return true})(o,i,r);if(e=e||null!==n,n)continue e}if(e)return!1}}return!0}}}),r=e({"node_modules/.pnpm/semver@7.7.2/node_modules/semver/index.js"(_,e){"use strict";var t=X(),a=V(),r=G(),n=Q(),o=ee(),i=te(),s=ae(),l=re(),c=ne(),d=oe(),u=ie(),p=se(),m=le(),h=ce(),g=de(),f=ue(),b=pe(),v=me(),y=he(),S=ge(),w=fe(),k=be(),E=ve(),C=ye(),I=Se(),x=we(),N=ke(),A=Ce(),T=Ee(),O=Ie(),L=xe(),D=Ne(),P=Ae(),M=Te(),R=Oe(),B=Le(),j=De(),$=Pe(),z=Me(),U=Re(),F=_e();e.exports={parse:o,valid:i,clean:s,inc:l,diff:c,major:d,minor:u,patch:p,prerelease:m,compare:h,rcompare:g,compareLoose:f,compareBuild:b,sort:v,rsort:y,gt:S,lt:w,eq:k,neq:E,gte:C,lte:I,cmp:x,coerce:N,Comparator:A,Range:T,satisfies:O,toComparators:L,maxSatisfying:D,minSatisfying:P,minVersion:M,validRange:R,outside:B,gtr:j,ltr:$,intersects:z,simplifyRange:U,subset:F,SemVer:r,re:t.re,src:t.src,tokens:t.t,SEMVER_SPEC_VERSION:a.SEMVER_SPEC_VERSION,RELEASE_TYPES:a.RELEASE_TYPES,compareIdentifiers:n.compareIdentifiers,rcompareIdentifiers:n.rcompareIdentifiers}}}),z=e({"node_modules/.pnpm/prismjs@1.30.0/node_modules/prismjs/components/prism-core.js"(e,t){var l,a,r,n,O,o="undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{},o=(a=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,r=0,n={},O={manual:(l=o).Prism&&l.Prism.manual,disableWorkerMessageHandler:l.Prism&&l.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof L?new L(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,"&").replace(/=i.reach);v+=b.value.length,b=b.next){var y=b.value;if(a.length>t.length)return;if(!(y instanceof L)){var S,w=1;if(h){if(!(S=D(f,v,t,m))||S.index>=t.length)break;var k=S.index,E=S.index+S[0].length,C=v;for(C+=b.value.length;C<=k;)b=b.next,C+=b.value.length;if(C-=b.value.length,v=C,b.value instanceof L)continue;for(var I=b;I!==a.tail&&(Ci.reach&&(i.reach=y),b.prev),N=(N&&(T=P(a,T,N),v+=N.length),M(a,T,w),new L(s,p?O.tokenize(x,p):x,g,x));b=P(a,T,N),A&&P(a,b,A),1i.reach&&(i.reach=x.reach)}}}}}(e,n,t,n.head,0),n),i=[],s=o.head.next;s!==o.tail;)i.push(s.value),s=s.next;return i},hooks:{all:{},add:function(e,t){var a=O.hooks.all;a[e]=a[e]||[],a[e].push(t)},run:function(e,t){var a=O.hooks.all[e];if(a&&a.length)for(var r,n=0;r=a[n++];)r(t)}},Token:L},l.Prism=O,L.stringify=function t(e,a){if("string"==typeof e)return e;var r;if(Array.isArray(e))return r="",e.forEach(function(e){r+=t(e,a)}),r;var n,o={type:e.type,content:t(e.content,a),tag:"span",classes:["token",e.type],attributes:{},language:a},e=e.alias,i=(e&&(Array.isArray(e)?Array.prototype.push.apply(o.classes,e):o.classes.push(e)),O.hooks.run("wrap",o),"");for(n in o.attributes)i+=" "+n+'="'+(o.attributes[n]||"").replace(/"/g,""")+'"';return"<"+o.tag+' class="'+o.classes.join(" ")+'"'+i+">"+o.content+""},l.document?((n=O.util.currentScript())&&(O.filename=n.src,n.hasAttribute("data-manual"))&&(O.manual=!0),O.manual||("loading"===(o=document.readyState)||"interactive"===o&&n&&n.defer?document.addEventListener("DOMContentLoaded",i):window.requestAnimationFrame?window.requestAnimationFrame(i):window.setTimeout(i,16))):l.addEventListener&&!O.disableWorkerMessageHandler&&l.addEventListener("message",function(e){var e=JSON.parse(e.data),t=e.language,a=e.code,e=e.immediateClose;l.postMessage(O.highlight(a,O.languages[t],t)),e&&l.close()},!1),O);function L(e,t,a,r){this.type=e,this.content=t,this.alias=a,this.length=0|(r||"").length}function D(e,t,a,r){e.lastIndex=t;t=e.exec(a);return t&&r&&t[1]&&(e=t[1].length,t.index+=e,t[0]=t[0].slice(e)),t}function c(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function P(e,t,a){var r=t.next,a={value:a,prev:t,next:r};return t.next=a,r.prev=a,e.length++,a}function M(e,t,a){for(var r=t.next,n=0;n"}}:{children:y})),$.createElement("textarea",{ref:function(e){return O.current=e},style:B(B(B({},V.editor),V.textarea),L),className:F+(I?" ".concat(I):""),id:N,value:A,onChange:function(e){var e=e.currentTarget,t=e.value,a=e.selectionStart,e=e.selectionEnd;P({value:t,selectionStart:a,selectionEnd:e},!0),v(t)},onKeyDown:function(e){var t,a,r,n,o,i,s,l,c,d,u,p;b&&(b(e),e.defaultPrevented)||("Escape"===e.key&&e.currentTarget.blur(),d=(a=e.currentTarget).value,t=a.selectionStart,a=a.selectionEnd,r=(f?" ":"\t").repeat(x),"Tab"===e.key&&!g&&D?(e.preventDefault(),e.shiftKey?(n=(c=m(d,t)).length-1,o=m(d,a).length-1,p=d.split("\n").map(function(e,t){return n<=t&&t<=o&&e.startsWith(r)?e.substring(r.length):e}).join("\n"),d!==p&&(u=c[n],h({value:p,selectionStart:null!=u&&u.startsWith(r)?t-r.length:t,selectionEnd:a-(d.length-p.length)}))):t!==a?(i=(c=m(d,t)).length-1,s=m(d,a).length-1,u=c[i],h({value:d.split("\n").map(function(e,t){return i<=t&&t<=s?r+e:e}).join("\n"),selectionStart:u&&/\S/.test(u)?t+r.length:t,selectionEnd:a+r.length*(s-i+1)})):(l=t+r.length,h({value:d.substring(0,t)+r+d.substring(a),selectionStart:l,selectionEnd:l}))):"Backspace"===e.key?(p=t!==a,d.substring(0,t).endsWith(r)&&!p&&(e.preventDefault(),l=t-r.length,h({value:d.substring(0,t-r.length)+d.substring(a),selectionStart:l,selectionEnd:l}))):"Enter"===e.key?t===a&&null!=(u=null==(c=m(d,t).pop())?void 0:c.match(/^\s+/))&&u[0]&&(e.preventDefault(),l=t+(p="\n"+u[0]).length,h({value:d.substring(0,t)+p+d.substring(a),selectionStart:l,selectionEnd:l})):57===e.keyCode||219===e.keyCode||222===e.keyCode||192===e.keyCode?(c=void 0,57===e.keyCode&&e.shiftKey?c=["(",")"]:219===e.keyCode?c=e.shiftKey?["{","}"]:["[","]"]:222===e.keyCode?c=e.shiftKey?['"','"']:["'","'"]:192!==e.keyCode||e.shiftKey||(c=["`","`"]),t!==a&&c&&(e.preventDefault(),h({value:d.substring(0,t)+c[0]+d.substring(t,a)+c[1]+d.substring(a),selectionStart:t,selectionEnd:a+2}))):(U?e.metaKey&&90===e.keyCode:e.ctrlKey&&90===e.keyCode)&&!e.shiftKey&&!e.altKey?(e.preventDefault(),u=T.current,p=u.stack,u=u.offset,(p=p[u-1])&&(R(p),T.current.offset=Math.max(u-1,0))):(U?e.metaKey&&90===e.keyCode&&e.shiftKey:z?e.ctrlKey&&89===e.keyCode:e.ctrlKey&&90===e.keyCode&&e.shiftKey)&&!e.altKey?(e.preventDefault(),l=T.current,c=l.stack,l=l.offset,(d=c[l+1])&&(R(d),T.current.offset=Math.min(l+1,c.length-1))):77!==e.keyCode||!e.ctrlKey||U&&!e.shiftKey||(e.preventDefault(),_(function(e){return!e})))},onClick:d,onKeyUp:p,onFocus:u,onBlur:c,disabled:r,form:n,maxLength:i,minLength:s,name:l,placeholder:S,readOnly:k,required:E,autoFocus:a,autoCapitalize:"off",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"data-gramm":!1}),$.createElement("style",{dangerouslySetInnerHTML:{__html:G}}))}),V={container:{position:"relative",textAlign:"left",boxSizing:"border-box",padding:0,overflow:"hidden"},textarea:{position:"absolute",top:0,left:0,height:"100%",width:"100%",resize:"none",color:"inherit",overflow:"hidden",MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",WebkitTextFillColor:"transparent"},highlight:{position:"relative",pointerEvents:"none"},editor:{margin:0,border:0,background:"none",boxSizing:"inherit",display:"inherit",fontFamily:"inherit",fontSize:"inherit",fontStyle:"inherit",fontVariantLigatures:"inherit",fontWeight:"inherit",letterSpacing:"inherit",lineHeight:"inherit",tabSize:"inherit",textIndent:"inherit",textRendering:"inherit",textTransform:"inherit",whiteSpace:"pre-wrap",wordBreak:"keep-all",overflowWrap:"break-word"}};e.default=t}}),F=e({"node_modules/.pnpm/classnames@2.3.2/node_modules/classnames/index.js"(e,t){!function(){"use strict";var i={}.hasOwnProperty;function s(){for(var e=[],t=0;tfunction(){return zm.default.createElement($m,null)}};for(k in Fe)A(Ue,k,{get:Fe[k],enumerable:!0});var L=e=>"string"==typeof e,Ge=()=>{let a,r;var e=new Promise((e,t)=>{a=e,r=t});return e.resolve=a,e.reject=r,e},Ve=e=>null==e?"":""+e,He=(e,t,a)=>{e.forEach(e=>{t[e]&&(a[e]=t[e])})},qe=/###/g,We=e=>e&&-1!e||L(e),Je=(e,t,a)=>{var r=L(t)?t.split("."):t;let n=0;for(;n{var{obj:e,k:t}=Je(r,n,Object);if(void 0!==e||1===n.length)e[t]=o;else{let e=n[n.length-1],t=n.slice(0,n.length-1),a=Je(r,t,Object);for(;void 0===a.obj&&t.length;)e=t[t.length-1]+"."+e,t=t.slice(0,t.length-1),(a=Je(r,t,Object))?.obj&&void 0!==a.obj[a.k+"."+e]&&(a.obj=void 0);a.obj[a.k+"."+e]=o}},Ze=(e,t,a,r)=>{var{obj:e,k:t}=Je(e,t,Object);e[t]=e[t]||[],e[t].push(a)},Xe=(e,t)=>{var{obj:e,k:t}=Je(e,t);if(e&&Object.prototype.hasOwnProperty.call(e,t))return e[t]},Qe=(e,t,a)=>{e=Xe(e,a);return void 0!==e?e:Xe(t,a)},et=(e,t,a)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?L(e[r])||e[r]instanceof String||L(t[r])||t[r]instanceof String?a&&(e[r]=t[r]):et(e[r],t[r],a):e[r]=t[r]);return e},tt=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),at={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},rt=e=>L(e)?e.replace(/[&<>"'\/]/g,e=>at[e]):e,nt=[" ",",","?","!",";"],ot=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){var t=this.regExpMap.get(e);return void 0!==t||(t=new RegExp(e),this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,t),this.regExpQueue.push(e)),t}}(20),it=(e,t,a)=>{t=t||"",a=a||"";var r=nt.filter(e=>t.indexOf(e)<0&&a.indexOf(e)<0);if(0===r.length)return!0;var n,r=ot.getRegExp(`(${r.map(e=>"?"===e?"\\?":e).join("|")})`);let o=!r.test(e);return o||0<(n=e.indexOf(a))&&!r.test(e.substring(0,n))&&(o=!0),o},st=(e,t,o=".")=>{if(e){if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;var i=t.split(o);let n=e;for(let r=0;re?.replace("_","-"),ct={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){console?.[e]?.apply?.(console,t)}},dt=class{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||"i18next:",this.logger=e||ct,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,"log","",!0)}warn(...e){return this.forward(e,"warn","",!0)}error(...e){return this.forward(e,"error","")}deprecate(...e){return this.forward(e,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,a,r){return r&&!this.debug?null:(L(e[0])&&(e[0]=""+a+this.prefix+" "+e[0]),this.logger[t](e))}create(e){return new dt(this.logger,{prefix:this.prefix+`:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new dt(this.logger,e)}},ut=new dt,n=class{constructor(){this.observers={}}on(e,a){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);var t=this.observers[e].get(a)||0;this.observers[e].set(a,t+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(r,...n){this.observers[r]&&Array.from(this.observers[r].entries()).forEach(([t,a])=>{for(let e=0;e{for(let e=0;et[e]&&0{t=this.processors[e]?.process(t,a,r,n)??t}),t}},ht={},gt=e=>!L(e)&&"boolean"!=typeof e&&"number"!=typeof e,ft=class extends n{constructor(e,t={}){super(),He(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=ut.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){t={...t};return null!=e&&void 0!==this.resolve(e,t)?.res}extractFromKey(e,t){let a=(void 0!==t.nsSeparator?t:this.options).nsSeparator;void 0===a&&(a=":");var r=(void 0!==t.keySeparator?t:this.options).keySeparator;let n=t.ns||this.options.defaultNS||[];var o=a&&-1{a=b&&a!==u?a:N;this.options.missingKeyHandler?this.options.missingKeyHandler(e,s,t,a,A,n):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,s,t,a,A,n),this.emit("missingKey",e,s,t,u)};this.options.saveMissing&&(this.options.saveMissingPlurals&&f?t.forEach(t=>{var e=this.pluralResolver.getSuffixes(t,n);S&&n[`defaultValue${this.options.pluralSeparator}zero`]&&e.indexOf(this.options.pluralSeparator+"zero")<0&&e.push(this.options.pluralSeparator+"zero"),e.forEach(e=>{T([t],i+e,n["defaultValue"+e]||w)})}):T(t,i,w))}u=this.extendTranslation(u,a,n,d,r),t&&u===i&&this.options.appendNamespaceToMissingKey&&(u=""+s+l+i),(t||e)&&this.options.parseMissingKeyHandler&&(u=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?""+s+l+i:i,e?u:void 0,n))}else{if(!n.returnObjects&&!this.options.returnObjects)return this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!"),y=this.options.returnedObjectHandler?this.options.returnedObjectHandler(p,k,{...n,ns:t}):`key '${i} (${this.language})' returned an object instead of string.`,e?(d.res=y,d.usedParams=this.getUsedParamsDetails(n),d):y;if(o){var C,g=Array.isArray(k),I=g?[]:{},x=g?m:p;for(const O in k)Object.prototype.hasOwnProperty.call(k,O)&&(C=""+x+o+O,b&&!u?I[O]=this.translate(C,{...n,defaultValue:gt(w)?w[O]:void 0,joinArrays:!1,ns:t}):I[O]=this.translate(C,{...n,joinArrays:!1,ns:t}),I[O]===C)&&(I[O]=k[O]);u=I}}return e?(d.res=u,d.usedParams=this.getUsedParamsDetails(n),d):u}extendTranslation(a,r,n,o,i){if(this.i18nFormat?.parse)a=this.i18nFormat.parse(a,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||o.usedLng,o.usedNS,o.usedKey,{resolved:o});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});var s=L(a)&&(void 0!==n?.interpolation?.skipOnVariables?n:this.options).interpolation.skipOnVariables;let e,t=(s&&(l=a.match(this.interpolator.nestingRegexp),e=l&&l.length),n.replace&&!L(n.replace)?n.replace:n);this.options.interpolation.defaultVariables&&(t={...this.options.interpolation.defaultVariables,...t}),a=this.interpolator.interpolate(a,t,n.lng||this.language||o.usedLng,n),s&&(s=(l=a.match(this.interpolator.nestingRegexp))&&l.length,ei?.[0]!==e[0]||n.context?this.translate(...e,r):(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: `+r[0]),null),n)),n.interpolation&&this.interpolator.reset()}var l=n.postProcess||this.options.postProcess,s=L(l)?[l]:l;return a=null!=a&&s?.length&&!1!==n.applyPostProcessor?mt.handle(s,a,r,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...o,usedParams:this.getUsedParamsDetails(n)},...n}:n,this):a}resolve(e,u={}){let p,r,m,h,n;return(e=L(e)?[e]:e).forEach(t=>{if(!this.isValidLookup(p)){t=this.extractFromKey(t,u);const s=t.key;r=s;let e=t.namespaces;this.options.fallbackNS&&(e=e.concat(this.options.fallbackNS));const l=void 0!==u.count&&!L(u.count),c=l&&!u.ordinal&&0===u.count,d=void 0!==u.context&&(L(u.context)||"number"==typeof u.context)&&""!==u.context,a=u.lngs||this.languageUtils.toResolveHierarchy(u.lng||this.language,u.fallbackLng);e.forEach(i=>{this.isValidLookup(p)||(n=i,ht[a[0]+"-"+i]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(n)||(ht[a[0]+"-"+i]=!0,this.logger.warn(`key "${r}" for languages "${a.join(", ")}" won't get resolved as namespace "${n}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),a.forEach(t=>{if(!this.isValidLookup(p)){h=t;var e,a=[s];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(a,s,t,i,u);else{let e;l&&(e=this.pluralResolver.getSuffix(t,u.count,u));var r,n=this.options.pluralSeparator+"zero",o=this.options.pluralSeparator+"ordinal"+this.options.pluralSeparator;l&&(a.push(s+e),u.ordinal&&0===e.indexOf(o)&&a.push(s+e.replace(o,this.options.pluralSeparator)),c)&&a.push(s+n),d&&(r=""+s+this.options.contextSeparator+u.context,a.push(r),l)&&(a.push(r+e),u.ordinal&&0===e.indexOf(o)&&a.push(r+e.replace(o,this.options.pluralSeparator)),c)&&a.push(r+n)}for(;e=a.pop();)this.isValidLookup(p)||(m=e,p=this.getResource(t,i,e,u))}}))})}}),{res:p,usedKey:r,exactUsedKey:m,usedLng:h,usedNS:n}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,a,r={}){return(this.i18nFormat?.getResource?this.i18nFormat:this.resourceStore).getResource(e,t,a,r)}getUsedParamsDetails(e={}){var t=e.replace&&!L(e.replace);let a=t?e.replace:e;if(t&&void 0!==e.count&&(a.count=e.count),this.options.interpolation.defaultVariables&&(a={...this.options.interpolation.defaultVariables,...a}),!t){a={...a};for(const r of["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"])delete a[r]}return a}static hasDefaultValue(e){var t="defaultValue";for(const a in e)if(Object.prototype.hasOwnProperty.call(e,a)&&t===a.substring(0,t.length)&&void 0!==e[a])return!0;return!1}},bt=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=ut.create("languageUtils")}getScriptPartFromCode(e){return!(e=lt(e))||e.indexOf("-")<0||2===(e=e.split("-")).length||(e.pop(),"x"===e[e.length-1].toLowerCase())?null:this.formatLanguageCode(e.join("-"))}getLanguagePartFromCode(e){return!(e=lt(e))||e.indexOf("-")<0?e:(e=e.split("-"),this.formatLanguageCode(e[0]))}formatLanguageCode(t){if(L(t)&&-1{r||(e=this.formatLanguageCode(e),this.options.supportedLngs&&!this.isSupportedCode(e))||(r=e)}),!r&&this.options.supportedLngs&&e.forEach(e=>{if(!r){var t=this.getScriptPartFromCode(e);if(this.isSupportedCode(t))return r=t;const a=this.getLanguagePartFromCode(e);if(this.isSupportedCode(a))return r=a;r=this.options.supportedLngs.find(e=>e===a||!(e.indexOf("-")<0&&a.indexOf("-")<0)&&(0{e&&(this.isSupportedCode(e)?a.push(e):this.logger.warn("rejecting language code not found in supportedLngs: "+e))};return L(e)&&(-1{a.indexOf(e)<0&&r(this.formatLanguageCode(e))}),a}},vt={zero:0,one:1,two:2,few:3,many:4,other:5},yt={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})},St=class{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=ut.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(t,a={}){var r=lt("dev"===t?"en":t),e=a.ordinal?"ordinal":"cardinal",n=JSON.stringify({cleanedCode:r,type:e});if(n in this.pluralRulesCache)return this.pluralRulesCache[n];let o;try{o=new Intl.PluralRules(r,{type:e})}catch(e){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),yt;if(!t.match(/-|_/))return yt;r=this.languageUtils.getLanguagePartFromCode(t);o=this.getRule(r,a)}return this.pluralRulesCache[n]=o}needsPlural(e,t={}){let a=this.getRule(e,t);return 1<(a=a||this.getRule("dev",t))?.resolvedOptions().pluralCategories.length}getPluralFormsOfKey(e,t,a={}){return this.getSuffixes(e,a).map(e=>""+t+e)}getSuffixes(e,t={}){let a=this.getRule(e,t);return(a=a||this.getRule("dev",t))?a.resolvedOptions().pluralCategories.sort((e,t)=>vt[e]-vt[t]).map(e=>""+this.options.prepend+(t.ordinal?"ordinal"+this.options.prepend:"")+e):[]}getSuffix(e,t,a={}){var r=this.getRule(e,a);return r?""+this.options.prepend+(a.ordinal?"ordinal"+this.options.prepend:"")+r.select(t):(this.logger.warn("no plural rule found for: "+e),this.getSuffix("dev",t,a))}},wt=(e,t,a,r=".",n=!0)=>{let o=Qe(e,t,a);return o=!o&&n&&L(a)&&void 0===(o=st(e,a,r))?st(t,a,r):o},kt=e=>e.replace(/\$/g,"$$$$"),Et=class{constructor(e={}){this.logger=ut.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||(e.interpolation={escapeValue:!0});var{escape:e,escapeValue:t,useRawValueToEscape:a,prefix:r,prefixEscaped:n,suffix:o,suffixEscaped:i,formatSeparator:s,unescapeSuffix:l,unescapePrefix:c,nestingPrefix:d,nestingPrefixEscaped:u,nestingSuffix:p,nestingSuffixEscaped:m,nestingOptionsSeparator:h,maxReplaces:g,alwaysFormat:f}=e.interpolation;this.escape=void 0!==e?e:rt,this.escapeValue=void 0===t||t,this.useRawValueToEscape=void 0!==a&&a,this.prefix=r?tt(r):n||"{{",this.suffix=o?tt(o):i||"}}",this.formatSeparator=s||",",this.unescapePrefix=l?"":c||"-",this.unescapeSuffix=!this.unescapePrefix&&l||"",this.nestingPrefix=d?tt(d):u||tt("$t("),this.nestingSuffix=p?tt(p):m||tt(")"),this.nestingOptionsSeparator=h||",",this.maxReplaces=g||1e3,this.alwaysFormat=void 0!==f&&f,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){var e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,this.prefix+"(.+?)"+this.suffix),this.regexpUnescape=e(this.regexpUnescape,""+this.prefix+this.unescapePrefix+"(.+?)"+this.unescapeSuffix+this.suffix),this.nestingRegexp=e(this.nestingRegexp,this.nestingPrefix+"(.+?)"+this.nestingSuffix)}interpolate(r,a,n,o){let i,s,l;const c=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},d=e=>{var t;return e.indexOf(this.formatSeparator)<0?(t=wt(a,c,e,this.options.keySeparator,this.options.ignoreJSONStructure),this.alwaysFormat?this.format(t,void 0,n,{...o,...a,interpolationkey:e}):t):(e=(t=e.split(this.formatSeparator)).shift().trim(),t=t.join(this.formatSeparator).trim(),this.format(wt(a,c,e,this.options.keySeparator,this.options.ignoreJSONStructure),t,n,{...o,...a,interpolationkey:e}))},u=(this.resetRegExp(),o?.missingInterpolationHandler||this.options.missingInterpolationHandler),p=(void 0!==o?.interpolation?.skipOnVariables?o:this.options).interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>kt(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?kt(this.escape(e)):kt(e)}].forEach(e=>{for(l=0;i=e.regex.exec(r);){var t=i[1].trim();if(void 0===(s=d(t)))if("function"==typeof u){var a=u(r,i,o);s=L(a)?a:""}else{if(!o||!Object.prototype.hasOwnProperty.call(o,t)){if(p){s=i[0];continue}this.logger.warn(`missed to pass in variable ${t} for interpolating `+r)}s=""}else L(s)||this.useRawValueToEscape||(s=Ve(s));a=e.safeValue(s);if(r=r.replace(i[0],a),p?(e.regex.lastIndex+=s.length,e.regex.lastIndex-=i[0].length):e.regex.lastIndex=0,++l>=this.maxReplaces)break}}),r}nest(t,a,r={}){let n,o,i;for(var s=(a,e)=>{var r=this.nestingOptionsSeparator;if(!(a.indexOf(r)<0)){var n=a.split(new RegExp(r+"[ ]*{"));let t="{"+n[1];a=n[0];var n=(t=this.interpolate(t,i)).match(/'/g),o=t.match(/"/g);((n?.length??0)%2!=0||o)&&o.length%2==0||(t=t.replace(/'/g,'"'));try{i=JSON.parse(t),e&&(i={...e,...i})}catch(e){return this.logger.warn("failed parsing options string in nesting for key "+a,e),""+a+r+t}i.defaultValue&&-1e.trim()).filter(Boolean),n[1]=n[1].slice(0,l)),(o=a(s.call(this,n[1].trim(),i),i))&&n[0]===t&&!L(o))return o;(o=L(o)?o:Ve(o))||(this.logger.warn(`missed to resolve ${n[1]} for nesting `+t),o=""),e.length&&(o=e.reduce((e,t)=>this.format(e,t,r.lng,{...r,interpolationkey:n[1].trim()}),o.trim())),t=t.replace(n[0],o),this.regexp.lastIndex=0}return t}},Ct=e=>{let t=e.toLowerCase().trim();const a={};return-1{var t;e&&([e,...t]=e.split(":"),t=t.join(":").trim().replace(/^'+|'+$/g,""),e=e.trim(),a[e]||(a[e]=t),"false"===t&&(a[e]=!1),"true"===t&&(a[e]=!0),isNaN(t)||(a[e]=parseInt(t,10)))})),{formatName:t,formatOptions:a}},It=i=>{const s={};return(e,t,a)=>{let r=a;a&&a.interpolationkey&&a.formatParams&&a.formatParams[a.interpolationkey]&&a[a.interpolationkey]&&(r={...r,[a.interpolationkey]:void 0});var n=t+JSON.stringify(r);let o=s[n];return o||(o=i(lt(t),a),s[n]=o),o(e)}},xt=r=>(e,t,a)=>r(lt(t),a)(e),Nt=class{constructor(e={}){this.logger=ut.create("formatter"),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||",";t=t.cacheInBuiltFormats?It:xt;this.formats={number:t((e,t)=>{const a=new Intl.NumberFormat(e,{...t});return e=>a.format(e)}),currency:t((e,t)=>{const a=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>a.format(e)}),datetime:t((e,t)=>{const a=new Intl.DateTimeFormat(e,{...t});return e=>a.format(e)}),relativetime:t((e,t)=>{const a=new Intl.RelativeTimeFormat(e,{...t});return e=>a.format(e,t.range||"day")}),list:t((e,t)=>{const a=new Intl.ListFormat(e,{...t});return e=>a.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=It(t)}format(e,t,i,s={}){var t=t.split(this.formatSeparator),a=(1-1-1{var{formatName:a,formatOptions:r}=Ct(a);if(this.formats[a]){let e=t;try{var n=s?.formatParams?.[s.interpolationkey]||{},o=n.locale||n.lng||s.locale||s.lng||i;e=this.formats[a](t,o,{...r,...s,...n})}catch(e){this.logger.warn(e)}return e}return this.logger.warn("there was no format function for "+a),t},e));return a}},At=(e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)},Tt=class extends n{constructor(e,t,a,r={}){super(),this.backend=e,this.store=t,this.services=a,this.languageUtils=a.languageUtils,this.options=r,this.logger=ut.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=0<=r.maxRetries?r.maxRetries:5,this.retryTimeout=1<=r.retryTimeout?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(a,r.backend,r)}queueLoad(e,t,n,a){const o={},i={},s={},l={};return e.forEach(a=>{let r=!0;t.forEach(e=>{var t=a+"|"+e;!n.reload&&this.store.hasResourceBundle(a,e)?this.state[t]=2:this.state[t]<0||(1===this.state[t]?void 0===i[t]&&(i[t]=!0):(this.state[t]=1,r=!1,void 0===i[t]&&(i[t]=!0),void 0===o[t]&&(o[t]=!0),void 0===l[e]&&(l[e]=!0)))}),r||(s[a]=!0)}),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:a}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(s),toLoadNamespaces:Object.keys(l)}}loaded(e,t,a){var r=e.split("|");const n=r[0],o=r[1],i=(t&&this.emit("failedLoading",n,o,t),!t&&a&&this.store.addResourceBundle(n,o,a,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&a&&(this.state[e]=0),{});this.queue.forEach(a=>{Ze(a.loaded,[n],o),At(a,e),t&&a.errors.push(t),0!==a.pendingCount||a.done||(Object.keys(a.loaded).forEach(t=>{i[t]||(i[t]={});var e=a.loaded[t];e.length&&e.forEach(e=>{void 0===i[t][e]&&(i[t][e]=!0)})}),a.done=!0,a.errors.length?a.callback(a.errors):a.callback())}),this.emit("loaded",i),this.queue=this.queue.filter(e=>!e.done)}read(r,n,o,i=0,s=this.retryTimeout,l){if(!r.length)return l(null,{});if(this.readingCalls>=this.maxParallelReads)this.waitingReads.push({lng:r,ns:n,fcName:o,tried:i,wait:s,callback:l});else{this.readingCalls++;const a=(e,t)=>{var a;this.readingCalls--,0{this.read.call(this,r,n,o,i+1,2*s,l)},s):l(e,t)};var e=this.backend[o].bind(this.backend);if(2!==e.length)return e(r,n,a);try{var t=e(r,n);t&&"function"==typeof t.then?t.then(e=>a(null,e)).catch(a):a(null,t)}catch(e){a(e)}}}prepareLoading(e,t,a={},r){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();L(e)&&(e=this.languageUtils.toResolveHierarchy(e)),L(t)&&(t=[t]);e=this.queueLoad(e,t,a,r);if(!e.toLoad.length)return e.pending.length||r(),null;e.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,a){this.prepareLoading(e,t,{},a)}reload(e,t,a){this.prepareLoading(e,t,{reload:!0},a)}loadOne(a,r=""){var e=a.split("|");const n=e[0],o=e[1];this.read(n,o,"read",void 0,void 0,(e,t)=>{e&&this.logger.warn(`${r}loading namespace ${o} for language ${n} failed`,e),!e&&t&&this.logger.log(`${r}loaded namespace ${o} for language `+n,t),this.loaded(a,e,t)})}saveMissing(t,a,r,n,o,i={},s=()=>{}){if(this.services?.utils?.hasLoadedNamespace&&!this.services?.utils?.hasLoadedNamespace(a))this.logger.warn(`did not save key "${r}" as the namespace "${a}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");else if(null!=r&&""!==r){if(this.backend?.create){i={...i,isUpdate:o},o=this.backend.create.bind(this.backend);if(o.length<6)try{let e;(e=5===o.length?o(t,a,r,n,i):o(t,a,r,n))&&"function"==typeof e.then?e.then(e=>s(null,e)).catch(s):s(null,e)}catch(e){s(e)}else o(t,a,r,n,s,i)}t&&t[0]&&this.store.addResource(t[0],a,r,n)}}},Ot=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),L(e[1])&&(t.defaultValue=e[1]),L(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const a=e[3]||e[2];Object.keys(a).forEach(e=>{t[e]=a[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Lt=e=>(L(e.ns)&&(e.ns=[e.ns]),L(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),L(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),Dt=()=>{},Pt=t=>{Object.getOwnPropertyNames(Object.getPrototypeOf(t)).forEach(e=>{"function"==typeof t[e]&&(t[e]=t[e].bind(t))})},Mt=class extends n{constructor(e={},t){if(super(),this.options=Lt(e),this.services={},this.logger=ut,this.modules={external:[]},Pt(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(t={},a){this.isInitializing=!0,"function"==typeof t&&(a=t,t={}),null==t.defaultNS&&t.ns&&(L(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));var r=Ot(),t=(this.options={...r,...this.options,...Lt(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator),e=>e?"function"==typeof e?new e:e:null);if(!this.options.isClone){this.modules.logger?ut.init(t(this.modules.logger),this.options):ut.init(null,this.options);let e;e=this.modules.formatter||Nt;var n=new bt(this.options),o=(this.store=new pt(this.options.resources,this.options),this.services);o.logger=ut,o.resourceStore=this.store,o.languageUtils=n,o.pluralResolver=new St(n,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!e||this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format||(o.formatter=t(e),o.formatter.init(o,this.options),this.options.interpolation.format=o.formatter.format.bind(o.formatter)),o.interpolator=new Et(this.options),o.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},o.backendConnector=new Tt(t(this.modules.backend),o.resourceStore,o,this.options),o.backendConnector.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(o.languageDetector=t(this.modules.languageDetector),o.languageDetector.init)&&o.languageDetector.init(o,this.options.detection,this.options),this.modules.i18nFormat&&(o.i18nFormat=t(this.modules.i18nFormat),o.i18nFormat.init)&&o.i18nFormat.init(this),this.translator=new ft(this.services,this.options),this.translator.on("*",(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}this.format=this.options.interpolation.format,a=a||Dt,!this.options.fallbackLng||this.services.languageDetector||this.options.lng||0<(n=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng)).length&&"dev"!==n[0]&&(this.options.lng=n[0]),this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(t=>{this[t]=(...e)=>this.store[t](...e)});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(t=>{this[t]=(...e)=>(this.store[t](...e),this)});const i=Ge();r=()=>{var e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),a(e,t)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?r():setTimeout(r,0),i}loadResources(e,t=Dt){let a=t;t=L(e)?e:this.language;if("function"==typeof e&&(a=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===t?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return a();const r=[],n=e=>{e&&"cimode"!==e&&this.services.languageUtils.toResolveHierarchy(e).forEach(e=>{"cimode"!==e&&r.indexOf(e)<0&&r.push(e)})};t?n(t):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>n(e)),this.options.preload?.forEach?.(e=>n(e)),this.services.backendConnector.load(r,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),a(e)})}else a(null)}reloadResources(e,t,a){const r=Ge();return"function"==typeof e&&(a=e,e=void 0),"function"==typeof t&&(a=t,t=void 0),e=e||this.languages,t=t||this.options.ns,a=a||Dt,this.services.backendConnector.reload(e,t,e=>{r.resolve(),a(e)}),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(e.type)return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&mt.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this;throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()")}setResolvedLanguage(e){if(e&&this.languages&&!(-1<["cimode","dev"].indexOf(e))){for(let e=0;e{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)}),i=(e,t)=>{t?this.isLanguageChangingTo===r&&(o(t),this.translator.changeLanguage(t),this.isLanguageChangingTo=void 0,this.emit("languageChanged",t),this.logger.log("languageChanged",t)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),a&&a(e,(...e)=>this.t(...e))};var e=e=>{r||e||!this.services.languageDetector||(e=[]);var t=L(e)?e:e&&e[0];const a=this.store.hasLanguageSomeTranslations(t)?t:this.services.languageUtils.getBestMatchFromCodes(L(e)?[e]:e);a&&(this.language||o(a),this.translator.language||this.translator.changeLanguage(a),this.services.languageDetector?.cacheUserLanguage?.(a)),this.loadResources(a,e=>{i(e,a)})};return r||!this.services.languageDetector||this.services.languageDetector.async?!r&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(e):this.services.languageDetector.detect(e):e(r):e(this.services.languageDetector.detect()),n}getFixedT(e,t,i){const s=(e,t,...a)=>{let r;(r="object"!=typeof t?this.options.overloadTranslationOptionHandler([e,t].concat(a)):{...t}).lng=r.lng||s.lng,r.lngs=r.lngs||s.lngs,r.ns=r.ns||s.ns,""!==r.keyPrefix&&(r.keyPrefix=r.keyPrefix||i||s.keyPrefix);const n=this.options.keySeparator||".";let o;return o=r.keyPrefix&&Array.isArray(e)?e.map(e=>""+r.keyPrefix+n+e):r.keyPrefix?""+r.keyPrefix+n+e:e,this.t(o,r)};return L(e)?s.lng=e:s.lngs=e,s.ns=t,s.keyPrefix=i,s}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var a=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,n=this.languages[this.languages.length-1];if("cimode"===a.toLowerCase())return!0;var o=(e,t)=>{e=this.services.backendConnector.state[e+"|"+t];return-1===e||0===e||2===e};if(t.precheck){t=t.precheck(this,o);if(void 0!==t)return t}return!!this.hasResourceBundle(a,e)||!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages)&&(!o(a,e)||r&&!o(n,e)))}loadNamespaces(e,t){const a=Ge();return this.options.ns?((e=L(e)?[e]:e).forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{a.resolve(),t&&t(e)}),a):(t&&t(),Promise.resolve())}loadLanguages(e,t){const a=Ge(),r=(L(e)&&(e=[e]),this.options.preload||[]);e=e.filter(e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return e.length?(this.options.preload=r.concat(e),this.loadResources(e=>{a.resolve(),t&&t(e)}),a):(t&&t(),Promise.resolve())}dir(e){if(!(e=e||this.resolvedLanguage||(0{n[e]=this[e]}),n.services={...this.services},n.services.utils={hasLoadedNamespace:n.hasLoadedNamespace.bind(n)},a&&(e=Object.keys(this.store.data).reduce((a,r)=>(a[r]={...this.store.data[r]},a[r]=Object.keys(a[r]).reduce((e,t)=>(e[t]={...a[r][t]},e),a[r]),a),{}),n.store=new pt(e,r),n.services.resourceStore=n.store),n.translator=new ft(n.services,r),n.translator.on("*",(e,...t)=>{n.emit(e,...t)}),n.init(r,t),n.translator.options=r,n.translator.backendConnector.services.utils={hasLoadedNamespace:n.hasLoadedNamespace.bind(n)},n}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}},n=Mt.createInstance(),y=(n.createInstance=Mt.createInstance,n.createInstance,n.dir,n.init,n.loadResources,n.reloadResources,n.use,n.changeLanguage,n.getFixedT,n.t),{slice:Rt,forEach:_t}=(n.exists,n.setDefaultNamespace,n.hasLoadedNamespace,n.loadNamespaces,n.loadLanguages,[]);function Bt(a){return _t.call(Rt.call(arguments,1),e=>{if(e)for(const t in e)void 0===a[t]&&(a[t]=e[t])}),a}function jt(t){if("string"==typeof t)return[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(e=>e.test(t))}var $t=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,zt=function(e,t,a,r){var n=4{if(null===Ht)try{if(!(Ht="undefined"!=typeof window&&null!==window.localStorage))return!1;var e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch(e){Ht=!1}return Ht},Wt={name:"localStorage",lookup(e){e=e.lookupLocalStorage;if(e&&qt())return window.localStorage.getItem(e)||void 0},cacheUserLanguage(e,t){t=t.lookupLocalStorage;t&&qt()&&window.localStorage.setItem(t,e)}},Kt=null,Jt=()=>{if(null===Kt)try{if(!(Kt="undefined"!=typeof window&&null!==window.sessionStorage))return!1;var e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch(e){Kt=!1}return Kt},Yt={name:"sessionStorage",lookup(e){e=e.lookupSessionStorage;if(e&&Jt())return window.sessionStorage.getItem(e)||void 0},cacheUserLanguage(e,t){t=t.lookupSessionStorage;t&&Jt()&&window.sessionStorage.setItem(t,e)}},Zt={name:"navigator",lookup(e){var t=[];if("undefined"!=typeof navigator){var{languages:a,userLanguage:r,language:n}=navigator;if(a)for(let e=0;e({order:na,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e})),ta=class{constructor(e){var t=1e.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=a,this.addDetector(Ft),this.addDetector(Gt),this.addDetector(Wt),this.addDetector(Yt),this.addDetector(Zt),this.addDetector(Xt),this.addDetector(Qt),this.addDetector(ea),this.addDetector(Vt)}addDetector(e){return this.detectors[e.name]=e,this}detect(){var e=0{if(this.detectors[t]){let e=this.detectors[t].lookup(this.options);(e=e&&"string"==typeof e?[e]:e)&&(a=a.concat(e))}}),a=a.filter(e=>null!=e&&!jt(e)).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?a:0{this.detectors[e]&&this.detectors[e].cacheUserLanguage(t,this.options)})}},ia=(ta.type="languageDetector",t(a())),sa=(t(a(),1),t(a(),1),t(_()),{}),la=(e,t,a,r)=>{ma(a)&&sa[a]||(ma(a)&&(sa[a]=new Date),e=e,a=[a=a,{code:t,...r||{}}],e?.services?.logger?.forward?e.services.logger.forward(a,"warn","react-i18next::",!0):(ma(a[0])&&(a[0]="react-i18next:: "+a[0]),e?.services?.logger?.warn?e.services.logger.warn(...a):console?.warn&&console.warn(...a)))},ca=(t,a)=>()=>{if(t.isInitialized)a();else{const e=()=>{setTimeout(()=>{t.off("initialized",e)},0),a()};t.on("initialized",e)}},da=(e,t,a)=>{e.loadNamespaces(t,ca(e,a))},ua=(t,e,a,r)=>{if(ma(a)&&(a=[a]),t.options.preload&&-1{t.options.ns.indexOf(e)<0&&t.options.ns.push(e)}),t.loadLanguages(e,ca(t,r))},pa=(a,e,r={})=>e.languages&&e.languages.length?e.hasLoadedNamespace(a,{lng:r.lng,precheck:(e,t)=>{if(-1"string"==typeof e,ha=e=>"object"==typeof e&&null!==e,ga=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,fa={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},ba=e=>fa[e],va={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:e=>e.replace(ga,ba)},ya=()=>va,Sa=()=>aa,_={type:"3rdParty",init(e){var t;[t={}]=[e.options.react],va={...va,...t},aa=e}},wa=(0,t(a(),1).createContext)(),ka=class{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}},Ea=t(a(),1),Ca=(e,t)=>{const a=(0,Ea.useRef)();return(0,Ea.useEffect)(()=>{a.current=t?a.current:e},[e,t]),a.current},Ia=(e,t,a,r)=>e.getFixedT(t,a,r),xa=(e,t,a,r)=>(0,Ea.useCallback)(Ia(e,t,a,r),[e,t,a,r]),Na=t(a(),1),Aa=(i,s={})=>function(o){function a({forwardedRef:e,...t}){var[a,r,n]=((e,r)=>{var t=r["i18n"],{i18n:a,defaultNS:n}=(0,Ea.useContext)(wa)||{};const o=t||a||Sa();if(o&&!o.reportNamespaces&&(o.reportNamespaces=new ka),!o)return la(o,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next"),(a=[t=(e,t)=>ma(t)?t:ha(t)&&ma(t.defaultValue)?t.defaultValue:Array.isArray(e)?e[e.length-1]:e,{},!1]).t=t,a.i18n={},a.ready=!1,a;o.options.react?.wait&&la(o,"DEPRECATED_OPTION","useTranslation: It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const i={...ya(),...o.options.react,...r},{useSuspense:s,keyPrefix:l}=i;let c=e||n||o.options?.defaultNS;c=ma(c)?[c]:c||["translation"],o.reportNamespaces.addUsedNamespaces?.(c);const d=(o.isInitialized||o.initializedStoreOnce)&&c.every(e=>pa(e,o,i)),u=xa(o,r.lng||null,"fallback"===i.nsMode?c:c[0],l),p=()=>u,m=()=>Ia(o,r.lng||null,"fallback"===i.nsMode?c:c[0],l),[h,g]=(0,Ea.useState)(p);let f=c.join();r.lng&&(f=""+r.lng+f);const b=Ca(f),v=(0,Ea.useRef)(!0);(0,Ea.useEffect)(()=>{const{bindI18n:e,bindI18nStore:t}=i,a=(v.current=!0,d||s||(r.lng?ua(o,r.lng,c,()=>{v.current&&g(m)}):da(o,c,()=>{v.current&&g(m)})),d&&b&&b!==f&&v.current&&g(m),()=>{v.current&&g(m)});return e&&o?.on(e,a),t&&o?.store.on(t,a),()=>{v.current=!1,o&&e?.split(" ").forEach(e=>o.off(e,a)),t&&o&&t.split(" ").forEach(e=>o.store.off(e,a))}},[o,f]),(0,Ea.useEffect)(()=>{v.current&&d&&g(p)},[o,l,d]);t=[h,o,d];if(t.t=h,t.i18n=o,(t.ready=d)||!d&&!s)return t;throw new Promise(e=>{r.lng?ua(o,r.lng,c,()=>e()):da(o,c,()=>e())})})(i,{...t,keyPrefix:s.keyPrefix}),t={...t,t:a,i18n:r,tReady:n};return s.withRef&&e?t.ref=e:!s.withRef&&e&&(t.forwardedRef=e),(0,Na.createElement)(o,t)}var e;a.displayName=`withI18nextTranslation(${e=o,e.displayName||e.name||(ma(e)&&0(0,Na.createElement)(a,Object.assign({},e,{forwardedRef:t}))):a},o=(t(a(),1),t(a(),1),t(a(),1),t(a())),Ta=t(r()),Oa="1.0.7",r="marketplace",I={installedExtensions:r+":installed-extensions",installedSnippets:r+":installed-snippets",installedThemes:r+":installed-themes",activeTab:r+":active-tab",tabs:r+":tabs",sort:r+":sort",themeInstalled:r+":theme-installed",localTheme:r+":local-theme",albumArtBasedColor:r+":albumArtBasedColors",albumArtBasedColorMode:r+":albumArtBasedColorsMode",albumArtBasedColorVibrancy:r+":albumArtBasedColorsVibrancy",colorShift:r+":colorShift"},La=[{name:"Extensions",enabled:!0},{name:"Themes",enabled:!0},{name:"Snippets",enabled:!0},{name:"Apps",enabled:!0},{name:"Installed",enabled:!0}],Da=100,Pa="/marketplace",Ma="https://github.com/spicetify/marketplace/releases",Ra="https://api.github.com/repos/spicetify/marketplace/releases/latest",{min:_a,max:Ba}=Math,ja=(e,t=0,a=1)=>_a(Ba(t,e),a),$a=t=>{t._clipped=!1,t._unclipped=t.slice(0);for(let e=0;e<=3;e++)e<3?((t[e]<0||2553<=t.length?Array.prototype.slice.call(t):"object"==C(t[0])&&e?e.split("").filter(e=>void 0!==t[0][e]).map(e=>t[0][e]):t[0].slice(0),Ua=e=>{var t;return!(e.length<2)&&"string"==C(e[t=e.length-1])?e[t].toLowerCase():null},{PI:r,min:Fa,max:Ga}=Math,Va=e=>Math.round(100*e)/100,Ha=e=>Math.round(100*e)/100,qa=2*r,Wa=r/3,Ka=r/180,Ja=180/r,i={format:{},autodetect:[]},f=class{constructor(...e){if("object"===C(e[0])&&e[0].constructor&&e[0].constructor===this.constructor)return e[0];let t=Ua(e),a=!1;if(!t){a=!0,i.sorted||(i.autodetect=i.autodetect.sort((e,t)=>t.p-e.p),i.sorted=!0);for(var r of i.autodetect)if(t=r.test(...e))break}if(!i.format[t])throw new Error("unknown format: "+e);var n=i.format[t].apply(null,a?e:e.slice(0,-1));this._rgb=$a(n),3===this._rgb.length&&this._rgb.push(1)}toString(){return"function"==C(this.hex)?this.hex():`[${this._rgb.join(",")}]`}},r=(...e)=>new f(...e),x=(r.version="3.1.1",r),Ya={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",laserlemon:"#ffff54",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrod:"#fafad2",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",maroon2:"#7f0000",maroon3:"#b03060",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",purple2:"#7f007f",purple3:"#a020f0",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},Za=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,Xa=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,Qa=e=>{var t;if(e.match(Za))return 3===(e=4!==e.length&&7!==e.length?e:e.substr(1)).length&&(e=(e=e.split(""))[0]+e[0]+e[1]+e[1]+e[2]+e[2]),[(t=parseInt(e,16))>>16,t>>8&255,255&t,1];if(e.match(Xa))return 4===(e=5!==e.length&&9!==e.length?e:e.substr(1)).length&&(e=(e=e.split(""))[0]+e[0]+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]),[(t=parseInt(e,16))>>24&255,t>>16&255,t>>8&255,Math.round((255&t)/255*100)/100];throw new Error("unknown hex color: "+e)},er=Math["round"],tr=(...e)=>{let[t,a,r,n]=h(e,"rgba"),o=Ua(e)||"auto";void 0===n&&(n=1),"auto"===o&&(o=n<1?"rgba":"rgb");let i="000000"+(er(t)<<16|er(a)<<8|er(r)).toString(16),s=(i=i.substr(i.length-6),"0"+er(255*n).toString(16));switch(s=s.substr(s.length-2),o.toLowerCase()){case"rgba":return"#"+i+s;case"argb":return"#"+s+i;default:return"#"+i}},ar=(f.prototype.name=function(){var e,t=tr(this._rgb,"rgb");for(e of Object.keys(Ya))if(Ya[e]===t)return e.toLowerCase();return t},i.format.named=e=>{if(e=e.toLowerCase(),Ya[e])return Qa(Ya[e]);throw new Error("unknown color name: "+e)},i.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&"string"===C(e)&&Ya[e.toLowerCase()])return"named"}}),f.prototype.alpha=function(e,t=!1){return void 0!==e&&"number"===C(e)?t?(this._rgb[3]=e,this):new f([this._rgb[0],this._rgb[1],this._rgb[2],e],"rgb"):this._rgb[3]},f.prototype.clipped=function(){return this._rgb._clipped||!1},{Kn:18,labWhitePoint:"d65",Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452,kE:216/24389,kKE:8,kK:24389/27,RefWhiteRGB:{X:.95047,Y:1,Z:1.08883},MtxRGB2XYZ:{m00:.4124564390896922,m01:.21267285140562253,m02:.0193338955823293,m10:.357576077643909,m11:.715152155287818,m12:.11919202588130297,m20:.18043748326639894,m21:.07217499330655958,m22:.9503040785363679},MtxXYZ2RGB:{m00:3.2404541621141045,m01:-.9692660305051868,m02:.055643430959114726,m10:-1.5371385127977166,m11:1.8760108454466942,m12:-.2040259135167538,m20:-.498531409556016,m21:.041556017530349834,m22:1.0572251882231791},As:.9414285350000001,Bs:1.040417467,Cs:1.089532651,MtxAdaptMa:{m00:.8951,m01:-.7502,m02:.0389,m10:.2664,m11:1.7135,m12:-.0685,m20:-.1614,m21:.0367,m22:1.0296},MtxAdaptMaI:{m00:.9869929054667123,m01:.43230526972339456,m02:-.008528664575177328,m10:-.14705425642099013,m11:.5183602715367776,m12:.04004282165408487,m20:.15996265166373125,m21:.0492912282128556,m22:.9684866957875502}}),rr=ar,nr=new Map([["a",[1.0985,.35585]],["b",[1.0985,.35585]],["c",[.98074,1.18232]],["d50",[.96422,.82521]],["d55",[.95682,.92149]],["d65",[.95047,1.08883]],["e",[1,1,1]],["f2",[.99186,.67393]],["f7",[.95041,1.08747]],["f11",[1.00962,.6435]],["icc",[.96422,.82521]]]);function or(e){var t=nr.get(String(e).toLowerCase());if(!t)throw new Error("unknown Lab illuminant "+e);ar.labWhitePoint=e,ar.Xn=t[0],ar.Zn=t[1]}function ir(){return ar.labWhitePoint}var sr=e=>{var t=Math.sign(e);return((e=Math.abs(e))<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)*t},lr=(e,t,a)=>{var{MtxAdaptMa:r,MtxAdaptMaI:n,MtxXYZ2RGB:o,RefWhiteRGB:i,Xn:s,Yn:l,Zn:c}=rr,d=s*r.m00+l*r.m10+c*r.m20,u=s*r.m01+l*r.m11+c*r.m21,s=s*r.m02+l*r.m12+c*r.m22,l=i.X*r.m00+i.Y*r.m10+i.Z*r.m20,c=i.X*r.m01+i.Y*r.m11+i.Z*r.m21,i=i.X*r.m02+i.Y*r.m12+i.Z*r.m22,l=(e*r.m00+t*r.m10+a*r.m20)*(l/d),d=(e*r.m01+t*r.m11+a*r.m21)*(c/u),c=(e*r.m02+t*r.m12+a*r.m22)*(i/s),u=l*n.m00+d*n.m10+c*n.m20,e=l*n.m01+d*n.m11+c*n.m21,t=l*n.m02+d*n.m12+c*n.m22;return[255*sr(u*o.m00+e*o.m10+t*o.m20),255*sr(u*o.m01+e*o.m11+t*o.m21),255*sr(u*o.m02+e*o.m12+t*o.m22)]},cr=(...e)=>{var[t,a,r]=e=h(e,"lab"),[t,a,r]=((e,t,a)=>{const{kE:r,kK:n,kKE:o,Xn:i,Yn:s,Zn:l}=rr,c=(e+16)/116,d=.002*t+c,u=c-.005*a,p=d*d*d,m=u*u*u,h=p>r?p:(116*d-16)/n,g=e>o?Math.pow((e+16)/116,3):e/n,f=m>r?m:(116*u-16)/n,b=h*i,v=g*s,y=f*l;return[b,v,y]})(t,a,r),[t,a,r]=lr(t,a,r);return[t,a,r,3{e=dr(e/255),t=dr(t/255),a=dr(a/255);var{MtxRGB2XYZ:r,MtxAdaptMa:n,MtxAdaptMaI:o,Xn:i,Yn:s,Zn:l,As:c,Bs:d,Cs:u}=rr,p=e*r.m00+t*r.m10+a*r.m20,m=e*r.m01+t*r.m11+a*r.m21,e=e*r.m02+t*r.m12+a*r.m22,t=i*n.m00+s*n.m10+l*n.m20,a=i*n.m01+s*n.m11+l*n.m21,r=i*n.m02+s*n.m12+l*n.m22,i=p*n.m00+m*n.m10+e*n.m20,s=p*n.m01+m*n.m11+e*n.m21,l=p*n.m02+m*n.m12+e*n.m22;return[(i*=t/c)*o.m00+(s*=a/d)*o.m10+(l*=r/u)*o.m20,i*o.m01+s*o.m11+l*o.m21,i*o.m02+s*o.m12+l*o.m22]},pr=(...e)=>{var[e,t,a,...r]=h(e,"rgb"),[e,t,a]=ur(e,t,a),[e,t,a]=function(e,t,a){var{Xn:r,Yn:n,Zn:o,kE:i,kK:s}=rr,e=e/r,r=t/n,t=a/o,n=inew f(...e,"lab"),getLabWhitePoint:ir,setLabWhitePoint:or}),i.format.lab=cr,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"lab"))&&3===e.length)return"lab"}}),f.prototype.darken=function(e=1){var t=this.lab();return t[0]-=rr.Kn*e,new f(t,"lab").alpha(this.alpha(),!0)},f.prototype.brighten=function(e=1){return this.darken(-e)},f.prototype.darker=f.prototype.darken,f.prototype.brighter=f.prototype.brighten,f.prototype.get=function(e){var[e,t]=e.split("."),a=this[e]();if(t){var r=e.indexOf(t)-("ok"===e.substr(0,2)?2:0);if(-1{var a=e.interpolate(t,.5,i),r=a.luminance();return Math.abs(o-r)<1e-7||!n--?a:o.2126*(e=gr(e))+.7152*(t=gr(t))+.0722*(a=gr(a))),gr=e=>(e/=255)<=.03928?e/12.92:mr((e+.055)/1.055,2.4),s={},fr=(e,t,a=.5,...r)=>{let n=r[0]||"lrgb";if(s[n]||r.length||(n=Object.keys(s)[0]),s[n])return"object"!==C(e)&&(e=new f(e)),"object"!==C(t)&&(t=new f(t)),s[n](e,t,a).alpha(e.alpha()+a*(t.alpha()-e.alpha()));throw new Error(`interpolation mode ${n} is not defined`)},{sin:br,cos:vr}=(f.prototype.mix=f.prototype.interpolate=function(e,t=.5,...a){return fr(this,e,t,...a)},f.prototype.premultiply=function(e=!1){var t=this._rgb,a=t[3];return e?(this._rgb=[t[0]*a,t[1]*a,t[2]*a,a],this):new f([t[0]*a,t[1]*a,t[2]*a,a],"rgb")},Math),yr=(...e)=>{let[t,a,r]=h(e,"lch");return isNaN(r)&&(r=0),r*=Ka,[t,vr(r)*a,br(r)*a]},Sr=(...e)=>{var[t,a,r]=e=h(e,"lch"),[t,a,r]=yr(t,a,r),[t,a,r]=cr(t,a,r);return[t,a,r,3{e=h(e,"hcl").reverse();return Sr(...e)},{sqrt:wr,atan2:kr,round:Er}=Math,Cr=(...e)=>{var[e,t,a]=h(e,"lab"),r=wr(t*t+a*a);let n=(kr(a,t)*Ja+360)%360;return[e,r,n=0===Er(1e4*r)?Number.NaN:n]},Ir=(...e)=>{var[e,t,a,...r]=h(e,"rgb"),[e,t,a]=pr(e,t,a),[e,t,a]=Cr(e,t,a);return[e,t,a,...0new f(...e,"lch"),hcl:(...e)=>new f(...e,"hcl")}),i.format.lch=Sr,i.format.hcl=r,["lch","hcl"].forEach(t=>i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,t))&&3===e.length)return t}})),f.prototype.saturate=function(e=1){var t=this.lch();return t[1]+=rr.Kn*e,t[1]<0&&(t[1]=0),new f(t,"lch").alpha(this.alpha(),!0)},f.prototype.desaturate=function(e=1){return this.saturate(-e)},f.prototype.set=function(e,t,a=!1){var[e,r]=e.split("."),n=this[e]();if(r){var o=e.indexOf(r)-("ok"===e.substr(0,2)?2:0);if(-1{e=e._rgb,t=t._rgb;return new f(e[0]+a*(t[0]-e[0]),e[1]+a*(t[1]-e[1]),e[2]+a*(t[2]-e[2]),"rgb")},Math),Ar=(s.lrgb=(e,t,a)=>{var[e,r,n]=e._rgb,[t,o,i]=t._rgb;return new f(xr(Nr(e,2)*(1-a)+Nr(t,2)*a),xr(Nr(r,2)*(1-a)+Nr(o,2)*a),xr(Nr(n,2)*(1-a)+Nr(i,2)*a),"rgb")},s.lab=(e,t,a)=>{e=e.lab(),t=t.lab();return new f(e[0]+a*(t[0]-e[0]),e[1]+a*(t[1]-e[1]),e[2]+a*(t[2]-e[2]),"lab")},(e,t,a,r)=>{let n,o;"hsl"===r?(n=e.hsl(),o=t.hsl()):"hsv"===r?(n=e.hsv(),o=t.hsv()):"hcg"===r?(n=e.hcg(),o=t.hcg()):"hsi"===r?(n=e.hsi(),o=t.hsi()):"lch"===r||"hcl"===r?(r="hcl",n=e.hcl(),o=t.hcl()):"oklch"===r&&(n=e.oklch().reverse(),o=t.oklch().reverse());let i,s,l,c,d,u;"h"!==r.substr(0,1)&&"oklch"!==r||([i,l,d]=n,[s,c,u]=o);let p,m,h,g;return isNaN(i)||isNaN(s)?isNaN(i)?isNaN(s)?m=Number.NaN:(m=s,1!=d&&0!=d||"hsv"==r||(p=c)):(m=i,1!=u&&0!=u||"hsv"==r||(p=l)):(g=s>i&&180Ar(e,t,a,"lch"),r=(s.lch=r,s.hcl=r,e=>{if("number"==C(e)&&0<=e&&e<=16777215)return[e>>16,e>>8&255,255&e,1];throw new Error("unknown num color: "+e)}),Tr=(...e)=>{var[e,t,a]=h(e,"rgb");return(e<<16)+(t<<8)+a},Or=(f.prototype.num=function(){return Tr(this._rgb)},Object.assign(x,{num:(...e)=>new f(...e,"num")}),i.format.num=r,i.autodetect.push({p:5,test:(...e)=>{if(1===e.length&&"number"===C(e[0])&&0<=e[0]&&e[0]<=16777215)return"num"}}),(s.num=(e,t,a)=>{e=e.num(),t=t.num();return new f(e+a*(t-e),"num")},Math)["floor"]),r=(...e)=>{let[t,a,r]=e=h(e,"hcg"),n,o,i;r*=255;var s=255*a;if(0===a)n=o=i=r;else{360<(t=360===t?0:t)&&(t-=360),t<0&&(t+=360),t/=60;var l=Or(t),c=t-l,d=r*(1-a),u=d+s*(1-c),p=d+s*c,m=d+s;switch(l){case 0:[n,o,i]=[m,p,d];break;case 1:[n,o,i]=[u,m,d];break;case 2:[n,o,i]=[d,m,p];break;case 3:[n,o,i]=[d,u,m];break;case 4:[n,o,i]=[p,d,m];break;case 5:[n,o,i]=[m,d,u]}}return[n,o,i,3{var[e,t,a]=h(e,"rgb"),r=Fa(e,t,a),n=Ga(e,t,a),o=n-r;let i;return 0==o?i=Number.NaN:(e===n&&(i=(t-a)/o),t===n&&(i=2+(a-e)/o),a===n&&(i=4+(e-t)/o),(i*=60)<0&&(i+=360)),[i,100*o/255,r/(255-o)*100]},Dr=(f.prototype.hcg=function(){return Lr(this._rgb)},x.hcg=(...e)=>new f(...e,"hcg"),i.format.hcg=r,i.autodetect.push({p:1,test:(...e)=>{if("array"===C(e=h(e,"hcg"))&&3===e.length)return"hcg"}}),(s.hcg=(e,t,a)=>Ar(e,t,a,"hcg"),Math)["cos"]),r=(...e)=>{let[t,a,r]=e=h(e,"hsi"),n,o,i;return isNaN(t)&&(t=0),isNaN(a)&&(a=0),360{var[e,t,a]=h(e,"rgb");let r;var n=Pr(e/=255,t/=255,a/=255),o=(e+t+a)/3,n=0new f(...e,"hsi"),i.format.hsi=r,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"hsi"))&&3===e.length)return"hsi"}}),s.hsi=(e,t,a)=>Ar(e,t,a,"hsi"),(...e)=>{var[t,a,r]=e=h(e,"hsl");let n,o,i;if(0===a)n=o=i=255*r;else{var s=[0,0,0],l=[0,0,0],c=r<.5?r*(1+a):r+a-r*a,d=2*r-c,a=t/360;s[0]=a+1/3,s[1]=a,s[2]=a-1/3;for(let e=0;e<3;e++)s[e]<0&&(s[e]+=1),1{var[t,a,r]=e=h(e,"rgba"),n=Fa(t/=255,a/=255,r/=255),o=Ga(t,a,r),i=(o+n)/2;let s,l;return o===n?(s=0,l=Number.NaN):s=i<.5?(o-n)/(o+n):(o-n)/(2-o-n),t==o?l=(a-r)/(o-n):a==o?l=2+(r-t)/(o-n):r==o&&(l=4+(t-a)/(o-n)),(l*=60)<0&&(l+=360),3new f(...e,"hsl"),i.format.hsl=Br,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"hsl"))&&3===e.length)return"hsl"}}),(s.hsl=(e,t,a)=>Ar(e,t,a,"hsl"),Math)["floor"]),r=(...e)=>{let[t,a,r]=e=h(e,"hsv"),n,o,i;if(r*=255,0===a)n=o=i=r;else{360<(t=360===t?0:t)&&(t-=360),t<0&&(t+=360),t/=60;var s=$r(t),l=t-s,c=r*(1-a),d=r*(1-a*l),u=r*(1-a*(1-l));switch(s){case 0:[n,o,i]=[r,u,c];break;case 1:[n,o,i]=[d,r,c];break;case 2:[n,o,i]=[c,r,u];break;case 3:[n,o,i]=[c,d,r];break;case 4:[n,o,i]=[u,c,r];break;case 5:[n,o,i]=[r,c,d]}}return[n,o,i,3{var[e,t,a]=e=h(e,"rgb"),r=zr(e,t,a),n=Ur(e,t,a),r=n-r;let o,i;return 0===n?(o=Number.NaN,i=0):(i=r/n,e===n&&(o=(t-a)/r),t===n&&(o=2+(a-e)/r),a===n&&(o=4+(e-t)/r),(o*=60)<0&&(o+=360)),[o,i,n/255]};f.prototype.hsv=function(){return Fr(this._rgb)},x.hsv=(...e)=>new f(...e,"hsv"),i.format.hsv=r,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"hsv"))&&3===e.length)return"hsv"}});function Gr(e,a){var t=e.length,r=(Array.isArray(e[0])||(e=[e]),(a=Array.isArray(a[0])?a:a.map(e=>[e]))[0].length);let n=a[0].map((e,t)=>a.map(e=>e[t])),o=e.map(a=>n.map(r=>Array.isArray(a)?a.reduce((e,t,a)=>e+t*(r[a]||0),0):r.reduce((e,t)=>e+t*a,0)));return 1===t&&(o=o[0]),1===r?o.map(e=>e[0]):o}s.hsv=(e,t,a)=>Ar(e,t,a,"hsv");var Vr=(...e)=>{var[e,t,a,...r]=e=h(e,"lab"),[e,t,a]=function(e){e=Gr([[1,.3963377773761749,.2158037573099136],[1,-.1055613458156586,-.0638541728258133],[1,-.0894841775298119,-1.2914855480194092]],e);return Gr([[1.2268798758459243,-.5578149944602171,.2813910456659647],[-.0405757452148008,1.112286803280317,-.0717110580655164],[-.0763729366746601,-.4214933324022432,1.5869240198367816]],e.map(e=>e**3))}([e,t,a]),[e,t,a]=lr(e,t,a);return[e,t,a,...0{var[e,t,a,...r]=h(e,"rgb");return[...function(e){e=Gr([[.819022437996703,.3619062600528904,-.1288737815209879],[.0329836539323885,.9292868615863434,.0361446663506424],[.0481771893596242,.2642395317527308,.6335478284694309]],e);return Gr([[.210454268309314,.7936177747023054,-.0040720430116193],[1.9779985324311684,-2.42859224204858,.450593709617411],[.0259040424655478,.7827717124575296,-.8086757549230774]],e.map(e=>Math.cbrt(e)))}(ur(e,t,a)),...0new f(...e,"oklab")}),i.format.oklab=Vr,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"oklab"))&&3===e.length)return"oklab"}}),s.oklab=(e,t,a)=>{e=e.oklab(),t=t.oklab();return new f(e[0]+a*(t[0]-e[0]),e[1]+a*(t[1]-e[1]),e[2]+a*(t[2]-e[2]),"oklab")},s.oklch=(e,t,a)=>Ar(e,t,a,"oklch"),Math),Xr=Math["pow"];function Qr(o){let i="rgb",s=x("#ccc"),t=0,l=[0,1],c=[],d=[0,0],u=!1,p=[],a=!1,m=0,h=1,r,g={},f=!0,b=1;function n(t){if((t=t||["#fff","#000"])&&"string"===C(t)&&x.brewer&&x.brewer[t.toLowerCase()]&&(t=x.brewer[t.toLowerCase()]),"array"===C(t)){t=(t=1===t.length?[t[0],t[0]]:t).slice(0);for(let e=0;e=u[e];)e++;return e-1}};let y=e=>e,S=e=>e;function w(e,t){let a,r;if(null==t&&(t=!1),isNaN(e)||null===e)return s;if(r=t?e:u&&2=n&&e===c.length-1){a=p[e];break}if(r>n&&rg={};n(o);function E(e){return e=x(w(e)),a&&e[a]?e[a]():e}return E.classes=function(e){var t;return null!=e?("array"===C(e)?(u=e,l=[e[0],e[e.length-1]]):(t=x.analyze(l),u=0===e?[t.min,t.max]:x.limits(t,"e",e)),E):u},E.domain=function(a){if(!arguments.length)return l;m=a[0],h=a[a.length-1],c=[];var t=p.length;if(a.length===t&&m!==h)for(var e of Array.from(a))c.push((e-m)/(h-m));else{for(let e=0;et/(a.length-1)),n=a.map(e=>(e-m)/(h-m));n.every((e,t)=>r[t]===e)||(S=e=>{if(e<=0||1<=e)return e;let t=0;for(;e>=n[t+1];)t++;var a=(e-n[t])/(n[t+1]-n[t]);return r[t]+a*(r[t+1]-r[t])})}}return l=[m,h],E},E.mode=function(e){return arguments.length?(i=e,k(),E):i},E.range=function(e,t){return n(e),E},E.out=function(e){return a=e,E},E.spread=function(e){return arguments.length?(t=e,E):t},E.correctLightness=function(e){return null==e&&(e=!0),r=e,k(),y=r?function(e){var t=w(0,!0).lab()[0],a=w(1,!0).lab()[0];const r=ae,E},E.padding=function(e){return null!=e?("number"===C(e)&&(e=[e,e]),d=e,E):d},E.colors=function(t,a){arguments.length<2&&(a="hex");let e=[];if(0===arguments.length)e=p.slice(0);else if(1===t)e=[E(.5)];else if(1o;n?e++:e--)r.push(e);return r}(0,t,!1).map(e=>E(r+e/(t-1)*n))}else{o=[];let r=[];if(u&&2t;a?e++:e--)r.push(.5*(u[e-1]+u[e]));else r=l;e=r.map(e=>E(e))}return e=x[a]?e.map(e=>e[a]()):e},E.cache=function(e){return null!=e?(f=e,E):f},E.gamma=function(e){return null!=e?(b=e,E):b},E.nodata=function(e){return null!=e?(s=x(e),E):s},E}var en=function(t){let a=[1,1];for(let e=1;e!(t<3)||!1===a?e:tn(e))},Object.assign(x,{rgb:(...e)=>new f(...e,"rgb")}),i.format.rgb=(...e)=>{e=h(e,"rgba");return void 0===e[3]&&(e[3]=1),e},i.autodetect.push({p:3,test:(...e)=>{if("array"===C(e=h(e,"rgba"))&&(3===e.length||4===e.length&&"number"==C(e[3])&&0<=e[3]&&e[3]<=1))return"rgb"}}),(e,t,a)=>{if(an[a])return an[a](e,t);throw new Error("unknown blend mode "+a)}),r=a=>(e,t)=>{t=x(t).rgb(),e=x(e).rgb();return x.rgb(a(t,e))},rn=r=>(e,t)=>{var a=[];return a[0]=r(e[0],t[0]),a[1]=r(e[1],t[1]),a[2]=r(e[2],t[2]),a},r=(an.normal=r(rn(e=>e)),an.multiply=r(rn((e,t)=>e*t/255)),an.screen=r(rn((e,t)=>255*(1-(1-e/255)*(1-t/255)))),an.overlay=r(rn((e,t)=>t<128?2*e*t/255:255*(1-2*(1-e/255)*(1-t/255)))),an.darken=r(rn((e,t)=>tt255===e||255<(e=t/255*255/(1-e/255))?255:e)),an.burn=r(rn((e,t)=>255*(1-(1-t/255)/(e/255)))),an),{pow:nn,sin:on,cos:sn}=Math;var{floor:ln,random:cn}=Math,{log:dn,pow:un,floor:pn,abs:mn}=Math;function hn(e,t=null){const a={min:Number.MAX_VALUE,max:-1*Number.MAX_VALUE,sum:0,values:[],count:0};return(e="object"===C(e)?Object.values(e):e).forEach(e=>{null==(e=t&&"object"===C(e)?e[t]:e)||isNaN(e)||(a.values.push(e),a.sum+=e,ea.max&&(a.max=e),a.count+=1)}),a.domain=[a.min,a.max],a.limits=(e,t)=>gn(a,e,t),a}function gn(e,t="equal",o=7){var{min:i,max:s}=e="array"==C(e)?hn(e):e,l=e.values.sort((e,t)=>e-t);if(1===o)return[i,s];var c=[];if("c"===t.substr(0,1)&&(c.push(i),c.push(s)),"e"===t.substr(0,1)){c.push(i);for(let e=1;e 0");var a=Math.LOG10E*dn(i),r=Math.LOG10E*dn(s);c.push(i);for(let e=1;ee-t),c.push(r[0]);for(let e=1;e[e.toLowerCase(),e])),xn="function"==typeof Proxy?new Proxy(xn,{get(e,t){t=t.toLowerCase();if(An.has(t))return e[An.get(t)]},getOwnPropertyNames(){return Object.getOwnPropertyNames(Nn)}}):xn,l=(...e)=>{var[t,a,r,n]=e=h(e,"cmyk"),e=4{var[e,t,a]=h(e,"rgb"),r=1-Tn(e/=255,Tn(t/=255,a/=255)),n=r<1?1/(1-r):0;return[(1-e-r)*n,(1-t-r)*n,(1-a-r)*n,r]},Ln=(f.prototype.cmyk=function(){return On(this._rgb)},Object.assign(x,{cmyk:(...e)=>new f(...e,"cmyk")}),i.format.cmyk=l,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"cmyk"))&&4===e.length)return"cmyk"}}),(...e)=>{var t=h(e,"hsla");let a=Ua(e)||"lsa";return t[0]=Va(t[0]||0)+"deg",t[1]=Va(100*t[1])+"%",t[2]=Va(100*t[2])+"%","hsla"===a||3{var t=h(e,"lab"),e=Ua(e)||"lab";return t[0]=Va(t[0])+"%",t[1]=Va(t[1]),t[2]=Va(t[2]),"laba"===e||3{var t=h(e,"lch"),e=Ua(e)||"lab";return t[0]=Va(t[0])+"%",t[1]=Va(t[1]),t[2]=isNaN(t[2])?"none":Va(t[2])+"deg","lcha"===e||3{e=h(e,"lab");return e[0]=Va(100*e[0])+"%",e[1]=Ha(e[1]),e[2]=Ha(e[2]),3{var[e,t,a,...r]=h(e,"rgb"),[e,t,a]=Hr(e,t,a),[e,t,a]=Cr(e,t,a);return[e,t,a,...0{e=h(e,"lch");return e[0]=Va(100*e[0])+"%",e[1]=Ha(e[1]),e[2]=isNaN(e[2])?"none":Va(e[2])+"deg",3{var t,a=h(e,"rgba");let r=Ua(e)||"rgb";return"hsl"===r.substr(0,3)?Ln(jr(a),r):"lab"===r.substr(0,3)?(e=ir(),or("d50"),t=Dn(pr(a),r),or(e),t):"lch"===r.substr(0,3)?(e=ir(),or("d50"),t=Pn(Ir(a),r),or(e),t):"oklab"===r.substr(0,5)?Mn(Hr(a)):"oklch"===r.substr(0,5)?_n(Rn(a)):(a[0]=Bn(a[0]),a[1]=Bn(a[1]),a[2]=Bn(a[2]),("rgba"===r||3{var[e,t,a,...r]=e=h(e,"lch"),[e,t,a]=yr(e,t,a),[e,t,a]=Vr(e,t,a);return[e,t,a,...0e.map((e,t)=>t<=2?ja(ao(e),0,255):e),d=(e,t=0,a=100,r=!1)=>("string"==typeof e&&e.endsWith("%")&&(e=parseFloat(e.substring(0,e.length-1))/100,e=r?t+.5*(e+1)*(a-t):t+e*(a-t)),+e),no=(e,t)=>"none"===e?t:e,l=e=>{if("transparent"===(e=e.toLowerCase().trim()))return[0,0,0,0];let a;if(i.format.named)try{return i.format.named(e)}catch(e){}if(a=(a=e.match(qn))||e.match(Wn)){let t=a.slice(1,4);for(let e=0;e<3;e++)t[e]=+d(no(t[e],0),0,255);t=ro(t);var r=void 0!==a[4]?+d(a[4],0,1):1;return t[3]=r,t}if(a=e.match(Kn)){var t=a.slice(1,5);for(let e=0;e<4;e++)t[e]=+d(t[e],0,255);return t}if(a=(a=e.match(Jn))||e.match(Yn))return(r=a.slice(1,4))[0]=+no(r[0].replace("deg",""),0),r[1]=.01*+d(no(r[1],0),0,100),r[2]=.01*+d(no(r[2],0),0,100),r=ro(Br(r)),n=void 0!==a[4]?+d(a[4],0,1):1,r[3]=n,r;if(a=e.match(Zn)){var n=a.slice(1,4),o=(n[1]*=.01,n[2]*=.01,Br(n));for(let e=0;e<3;e++)o[e]=ao(o[e]);return o[3]=+a[4],o}return(a=e.match(Xn))?((r=a.slice(1,4))[0]=d(no(r[0],0),0,100),r[1]=d(no(r[1],0),-125,125,!0),r[2]=d(no(r[2],0),-125,125,!0),n=ir(),or("d50"),r=ro(cr(r)),or(n),n=void 0!==a[4]?+d(a[4],0,1):1,r[3]=n,r):(a=e.match(Qn))?((n=a.slice(1,4))[0]=d(n[0],0,100),n[1]=d(no(n[1],0),0,150,!1),n[2]=+no(n[2].replace("deg",""),0),r=ir(),or("d50"),n=ro(Sr(n)),or(r),r=void 0!==a[4]?+d(a[4],0,1):1,n[3]=r,n):(a=e.match(eo))?((r=a.slice(1,4))[0]=d(no(r[0],0),0,1),r[1]=d(no(r[1],0),-.4,.4,!0),r[2]=d(no(r[2],0),-.4,.4,!0),n=ro(Vr(r)),r=void 0!==a[4]?+d(a[4],0,1):1,n[3]=r,n):(a=e.match(to))?((r=a.slice(1,4))[0]=d(no(r[0],0),0,1),r[1]=d(no(r[1],0),0,.4,!1),r[2]=+no(r[2].replace("deg",""),0),n=ro($n(r)),e=void 0!==a[4]?+d(a[4],0,1):1,n[3]=e,n):void 0},oo=(l.test=e=>qn.test(e)||Jn.test(e)||Xn.test(e)||Qn.test(e)||eo.test(e)||to.test(e)||Wn.test(e)||Kn.test(e)||Yn.test(e)||Zn.test(e)||"transparent"===e,l),io=(f.prototype.css=function(e){return jn(this._rgb,e)},x.css=(...e)=>new f(...e,"css"),i.format.css=oo,i.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&"string"===C(e)&&oo.test(e))return"css"}}),i.format.gl=(...e)=>{e=h(e,"rgba");return e[0]*=255,e[1]*=255,e[2]*=255,e},x.gl=(...e)=>new f(...e,"gl"),f.prototype.gl=function(){var e=this._rgb;return[e[0]/255,e[1]/255,e[2]/255,e[3]]},f.prototype.hex=function(e){return tr(this._rgb,e)},(x.hex=(...e)=>new f(...e,"hex"),i.format.hex=Qa,i.autodetect.push({p:4,test:(e,...t)=>{if(!t.length&&"string"===C(e)&&0<=[3,4,5,6,7,8,9].indexOf(e.length))return"hex"}}),Math)["log"]),so=e=>{e/=100;let t,a,r;return r=e<66?(t=255,a=e<6?0:-155.25485562709179-.44596950469579133*(a=e-2)+104.49216199393888*io(a),e<20?0:.8274096064007395*(r=e-10)-254.76935184120902+115.67994401066147*io(r)):(t=351.97690566805693+.114206453784165*(t=e-55)-40.25366309332127*io(t),a=325.4494125711974+.07943456536662342*(a=e-50)-28.0852963507957*io(a),255),[t,a,r,1]},lo=Math["round"],co=(...e)=>{var e=h(e,"rgb"),t=e[0],a=e[2];let r=1e3,n=4e4;let o;for(;.4=a/t?n=o:r=o}return lo(o)},Un=(f.prototype.temp=f.prototype.kelvin=f.prototype.temperature=function(){return co(this._rgb)},(...e)=>new f(...e,"temp")),N=(Object.assign(x,{temp:Un,kelvin:Un,temperature:Un}),i.format.temp=i.format.kelvin=i.format.temperature=so,f.prototype.oklch=function(){return Rn(this._rgb)},Object.assign(x,{oklch:(...e)=>new f(...e,"oklch")}),i.format.oklch=$n,i.autodetect.push({p:2,test:(...e)=>{if("array"===C(e=h(e,"oklch"))&&3===e.length)return"oklch"}}),Object.assign(x,{analyze:hn,average:(e,s="lrgb",l=null)=>{var t=e.length;const a=t/(l=l||Array.from(new Array(t)).map(()=>1)).reduce(function(e,t){return e+t});if(l.forEach((e,t)=>{l[t]*=a}),e=e.map(e=>new f(e)),"lrgb"===s){var r=e,n=l,o=r.length,i=[0,0,0,0];for(let e=0;e{var a,r=e.get(s);i+=e.alpha()*l[t+1];for(let e=0;e{const t=function(e){let r,n,o,i;if(2===(e=e.map(e=>new f(e))).length)[n,o]=e.map(e=>e.lab()),r=function(t){var e=[0,1,2].map(e=>n[e]+t*(o[e]-n[e]));return new f(e,"lab")};else if(3===e.length)[n,o,i]=e.map(e=>e.lab()),r=function(t){var e=[0,1,2].map(e=>(1-t)*(1-t)*n[e]+2*(1-t)*t*o[e]+t*t*i[e]);return new f(e,"lab")};else if(4===e.length){let a;[n,o,i,a]=e.map(e=>e.lab()),r=function(t){var e=[0,1,2].map(e=>(1-t)*(1-t)*(1-t)*n[e]+3*(1-t)*(1-t)*t*o[e]+3*(1-t)*t*t*i[e]+t*t*t*a[e]);return new f(e,"lab")}}else{if(!(5<=e.length))throw new RangeError("No point in running bezier with only one color.");{let t,i,s;t=e.map(e=>e.lab()),s=e.length-1,i=en(s),r=function(n){const o=1-n;var e=[0,1,2].map(r=>t.reduce((e,t,a)=>e+i[a]*o**(s-a)*n**a*t[r],0));return new f(e,"lab")}}}return r}(e);return t.scale=()=>Qr(t),t},blend:r,brewer:xn,Color:f,colors:Ya,contrast:(e,t)=>{e=new f(e),t=new f(t);e=e.luminance(),t=t.luminance();return t{e=new f(e),t=new f(t);var e=fn(...(e=e.alpha()<1?fr(t,e,e.alpha(),"rgb"):e).rgb()),t=fn(...t.rgb()),e=.022<=e?e:e+Math.pow(.022-e,1.414),t=.022<=t?t:t+Math.pow(.022-t,1.414),a=Math.pow(t,.56)-Math.pow(e,.57),r=Math.pow(t,.65)-Math.pow(e,.62),e=Math.abs(t-e)<5e-4?0:ex.scale(t),t.hue(i),t},deltaE:function(e,t,a=1,r=1,n=1){function o(e){return 360*e/(2*In)}function i(e){return 2*In*e/360}e=new f(e),t=new f(t);var[e,s,l]=Array.from(e.lab()),[t,c,d]=Array.from(t.lab()),u=(e+t)/2,p=(bn(b(s,2)+b(l,2))+bn(b(c,2)+b(d,2)))/2,p=.5*(1-bn(b(p,7)/(b(p,7)+b(25,7)))),c=c*(1+p),p=bn(b(s=s*(1+p),2)+b(l,2)),m=bn(b(c,2)+b(d,2)),h=(p+m)/2,l=o(Sn(l,s)),s=o(Sn(d,c)),l=180{let t="#";for(let e=0;e<6;e++)t+="0123456789abcdef".charAt(ln(16*cn()));return new f(t,"hex")},scale:Qr,scales:rn,valid:(...e)=>{try{return new f(...e),!0}catch(e){return!1}}}),(e,t)=>{e=localStorage.getItem(e);if(!e)return t;try{return JSON.parse(e)}catch{return e}}),uo=e=>{var t,a,r={section:/^\s*\[\s*([^\]]*)\s*\]\s*$/,param:/^\s*([^=]+?)\s*=\s*(.*?)\s*$/,comment:/^\s*;.*$/},n={};let o=null;for(const i of e.split(/[\r\n]+/))r.comment.test(i)||(r.param.test(i)?i.includes("xrdb")||(t=i.match(r.param),o&&t&&3===t.length&&(a=t[1].trim(),t=t[2].split(";")[0].trim(),n[o]||(n[o]={}),n[o][a]=t)):r.section.test(i)&&(a=i.match(r.section))&&(n[o=a[1]]={}));return n},po=e=>{var t=document.querySelector("style.marketplaceSnippets"),t=(t&&t.remove(),document.createElement("style")),e=e.reduce((e,t)=>`${e}/* ${t.title} - ${t.description} */ -${t.code} -`,"");t.innerHTML=e,t.classList.add("marketplaceSnippets"),document.body.appendChild(t)},mo=(e,t)=>{let a=[];return e&&0({name:e.name,url:Eo(e.url)})):a.push({name:t,url:"https://github.com/"+t}),a},ho=e=>e?Object.keys(e).map(e=>({key:e,value:e})):[],go=e=>[{key:"stars",value:e("grid.sort.stars")},{key:"newest",value:e("grid.sort.newest")},{key:"oldest",value:e("grid.sort.oldest")},{key:"lastUpdated",value:e("grid.sort.lastUpdated")},{key:"mostStale",value:e("grid.sort.mostStale")},{key:"a-z",value:e("grid.sort.aToZ")},{key:"z-a",value:e("grid.sort.zToA")}],fo=(...e)=>{console.debug("Resetting Marketplace");var t=[];if(0===e.length)for(const a in localStorage)a.startsWith("marketplace:")&&t.push(a);for(const r of e)switch(r){case"extensions":t.push(...N(I.installedExtensions,[])),t.push(I.installedExtensions);break;case"snippets":t.push(...N(I.installedSnippets,[])),t.push(I.installedSnippets);break;case"theme":t.push(...N(I.installedThemes,[])),t.push(I.installedThemes),t.push(I.themeInstalled);break;default:console.error("Unknown category: "+r)}for(const n of t)localStorage.removeItem(n),console.debug("Removed "+n);console.debug("Marketplace has been reset"),location.reload()},bo=t=>{var a=document.querySelector("style.marketplaceCSS.marketplaceScheme");if(a&&a.remove(),t){a=document.createElement("style");a.classList.add("marketplaceCSS"),a.classList.add("marketplaceScheme");let e=":root {";for(const r of Object.keys(t))e=(e+=`--spice-${r}: #${t[r]};`)+`--spice-rgb-${r}: ${(e=>{e=3===e.length?e.split("").map(e=>e+e).join(""):e;if(6!==e.length)throw"Only 3- or 6-digit hex colours are allowed.";if(e.match(/[^0-9a-f]/i))throw"Only hex colours are allowed.";e=e.match(/.{1,2}/g);if(e&&3===e.length)return[Number.parseInt(e[0],16),Number.parseInt(e[1],16),Number.parseInt(e[2],16)];throw"Could not parse hex colour."})(t[r])};`;e+="}",a.innerHTML=e,document.body.appendChild(a)}},vo=e=>{try{var t,a,r=document.querySelector("link[href='user.css']"),n=(r&&r.remove(),document.querySelector("style.marketplaceCSS.marketplaceUserCSS"));n&&n.remove(),e?((t=document.createElement("style")).classList.add("marketplaceCSS"),t.classList.add("marketplaceUserCSS"),t.innerHTML=e,document.body.appendChild(t)):((a=document.createElement("link")).setAttribute("rel","stylesheet"),a.setAttribute("href","user.css"),a.classList.add("userCSS"),document.body.appendChild(a))}catch(e){console.warn(e)}},yo=async(e,t)=>{if(!e.cssURL)throw new Error("No CSS URL provided");var t=t||await async function(){for(const e of["net","xyz"])try{if("opaqueredirect"===(await fetch("https://cdn.jsdelivr."+e,{redirect:"manual",cache:"no-cache"})).type)return e}catch(e){console.error(e)}}(),t=(e=>{const t=new URL(e);return t.host,t.host==="raw.githubusercontent.com"})(e.cssURL)?`https://cdn.jsdelivr.${t}/gh/${e.user}/${e.repo}@${e.branch}/`+e.manifest.usercss:e.cssURL,a=t.replace("/user.css","/assets/");console.debug("Parsing CSS: ",t);let r=await fetch(t+"?time="+Date.now()).then(e=>e.text());for(const i of r.matchAll(/url\(['|"](?.+?)['|"]\)/gm)||[]){var n,o=i?.groups?.path;!o||o.startsWith("http")||o.startsWith("data")||(n=a+o.replace(/\.\//g,""),r=r.replace(o,n))}return r};function So(e,t){if(e)for(const n of e){var a=t||n.user+"-"+n.repo,r=window.sessionStorage.getItem(a),r=r?JSON.parse(r):[];r.push(n),window.sessionStorage.setItem(a,JSON.stringify(r))}}async function wo(e,t,a){try{var r={text:e,context:t+"/"+a,mode:"gfm"},n=await fetch("https://api.github.com/markdown",{method:"POST",body:JSON.stringify(r)});if(n.ok)return await n.text();throw Spicetify.showNotification(y("notifications.markdownParsingError",{status:n.status}),!0)}catch{return null}}function ko(e){var t="snippet"===e.type?"snippet:":`${e.item.user}/${e.item.repo}/`;let a;switch(e.type){case"snippet":a=e.item.title.replaceAll(" ","-");break;case"theme":a=e.item.manifest?.usercss||"";break;case"extension":a=e.item.manifest?.main||"";break;case"app":a=e.item.manifest?.name?.replaceAll(" ","-")||""}return"marketplace:installed:"+t+a}var Eo=e=>{var t=decodeURI(e).trim().toLowerCase();return t.startsWith("javascript:")||t.startsWith("data:")||t.startsWith("vbscript:")?"about:blank":e},Co=(e,t)=>{e=e.title||e?.manifest?.name||"",t=t.title||t?.manifest?.name||"";return e.localeCompare(t)},Io=(e,t)=>{return void 0===e.created||void 0===t.created?0:(e=new Date(e.created),new Date(t.created).getTime()-e.getTime())},xo=(e,t)=>{return void 0===e.lastUpdated||void 0===t.lastUpdated?0:(e=new Date(e.lastUpdated),new Date(t.lastUpdated).getTime()-e.getTime())},No=(e,t)=>{switch(t){case"a-z":e.sort((e,t)=>Co(e,t));break;case"z-a":e.sort((e,t)=>Co(t,e));break;case"newest":e.sort((e,t)=>Io(e,t));break;case"oldest":e.sort((e,t)=>Io(t,e));break;case"lastUpdated":e.sort((e,t)=>xo(e,t));break;case"mostStale":e.sort((e,t)=>xo(t,e));break;default:e.sort((e,t)=>t.stars-e.stars)}};async function Ao(e,t=1,a=[],r=!1){let n=`https://api.github.com/search/repositories?q=${encodeURIComponent("topic:"+e)}&per_page=100`;t&&(n+="&page="+t);var o=JSON.parse(window.sessionStorage.getItem(e+"-page-"+t)||"null")||await fetch(n).then(e=>e.json()).catch(()=>null);return o?.items?(window.sessionStorage.setItem(e+"-page-"+t,JSON.stringify(o)),{...o,page_count:o.items.length,items:o.items.filter(e=>!a.includes(e.html_url)&&(r||!e.archived))}):(Spicetify.showNotification(y("notifications.tooManyRequests"),!0,5e3),{items:[]})}var Gn=new Blob([` - self.addEventListener('message', async (event) => { - const url = event.data; - const response = await fetch(url); - const data = await response.json().catch(() => null); - self.postMessage(data); - }); -`],{type:"application/javascript"}),To=URL.createObjectURL(Gn);async function Oo(e,t,a){var r=e+"-"+t,n=window.sessionStorage.getItem(r),o=JSON.parse(window.sessionStorage.getItem("noManifests")||"[]");if(n)return JSON.parse(n);n=`https://raw.githubusercontent.com/${e}/${t}/${a}/manifest.json`;if(o.includes(n))return null;let i=await async function(e){const r=new Worker(To);return new Promise(t=>{const a=e=>{r.terminate(),t(e)};r.postMessage(e),r.addEventListener("message",e=>a(e.data),{once:!0}),r.addEventListener("error",()=>a(null),{once:!0})})}(n);return i?(So(i=Array.isArray(i)?i:[i],r),i):So([n],"noManifests")}async function Lo(e,r,n,o=!1){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return null;const{user:i,repo:s}=t.groups;return(await Oo(i,s,r)).reduce((e,t)=>{var a;return t?.name&&t.description&&t.main&&(a=t.branch||r,a={manifest:t,title:t.name,subtitle:t.description,authors:mo(t.authors,i),user:i,repo:s,branch:a,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${i}/${s}/${a}/`+t.preview,extensionURL:t.main.startsWith("http")?t.main:`https://raw.githubusercontent.com/${i}/${s}/${a}/`+t.main,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${i}/${s}/${a}/`+t.readme,stars:n,tags:t.tags},o&&localStorage.getItem(`marketplace:installed:${i}/${s}/`+t.main)||e.push(a)),e},[])}catch{return null}}async function Do(e,r,n){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return null;const{user:o,repo:i}=t.groups;return(await Oo(o,i,r)).reduce((e,t)=>{var a;return t?.name&&t?.usercss&&t?.description&&(a=t.branch||r,a={manifest:t,title:t.name,subtitle:t.description,authors:mo(t.authors,o),user:o,repo:i,branch:a,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.preview,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.readme,stars:n,tags:t.tags,cssURL:t.usercss.startsWith("http")?t.usercss:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.usercss,schemesURL:t.schemes?t.schemes.startsWith("http")?t.schemes:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.schemes:null,include:t.include},e.push(a)),e},[])}catch{return null}}async function Po(e,r,n){try{var t=e.match(/https:\/\/api\.github\.com\/repos\/(?.+)\/(?.+)\/contents/);if(!t||!t.groups)return null;const{user:o,repo:i}=t.groups;return(await Oo(o,i,r)).reduce((e,t)=>{var a;return t?.name&&t.description&&!t.main&&!t.usercss&&(a=t.branch||r,a={manifest:t,title:t.name,subtitle:t.description,authors:mo(t.authors,o),user:o,repo:i,branch:a,imageURL:t.preview?.startsWith("http")?t.preview:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.preview,readmeURL:t.readme?.startsWith("http")?t.readme:`https://raw.githubusercontent.com/${o}/${i}/${a}/`+t.readme,stars:n,tags:t.tags},e.push(a)),e},[])}catch{return null}}var Mo=async()=>{return(await fetch("https://raw.githubusercontent.com/spicetify/marketplace/main/resources/blacklist.json").then(e=>e.json()).catch(()=>({}))).repos},Ro=async(a=!1)=>{var e=await fetch("https://raw.githubusercontent.com/spicetify/marketplace/main/resources/snippets.json").then(e=>e.json()).catch(()=>[]);return e.length?e.reduce((e,t)=>{t={...t};return t.preview&&(t.imageURL=t.preview.startsWith("http")?t.preview:"https://raw.githubusercontent.com/spicetify/spicetify-marketplace/main/"+t.preview,t.preview=void 0),a&&localStorage.getItem("marketplace:installed:snippet:"+t.title.replaceAll(" ","-"))||e.push(t),e},[]):[]},_o=t(a()),Bo=t(z()),jo=t(a()),$o=t(U()),zo=(Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},Prism.languages.webmanifest=Prism.languages.json,t(a())),Uo="button-module__button___hf2qg_marketplace",Fo="button-module__circle___EZ88P_marketplace",Go=e=>{var t=e.type||"round",a=[Uo];return"circle"===t&&a.push(Fo),e.classes&&a.push(...e.classes),zo.default.createElement("button",{className:a.join(" "),onClick:e.onClick,"aria-label":e.label||"",disabled:e.disabled},e.children)},Vo=()=>{const[e,t]=jo.default.useState("");const a=t=>{if(t){let e;try{e=JSON.parse(t)}catch{return void Spicetify.showNotification(y("backupModal.invalidJSON"))}var a=e;console.debug("Importing Marketplace"),fo();for(const r in a)localStorage.setItem(r,a[r]),console.debug("Imported "+r);location.reload()}else Spicetify.showNotification(y("backupModal.noDataPasted"))};return jo.default.createElement("div",{id:"marketplace-backup-container"},jo.default.createElement("div",{className:"marketplace-backup-input-container"},jo.default.createElement("label",{htmlFor:"marketplace-backup"},y("backupModal.inputLabel")),jo.default.createElement("div",{className:"marketplace-code-editor-wrapper marketplace-code-editor"},jo.default.createElement($o.default,{value:e,onValueChange:e=>t(e),highlight:e=>(0,Bo.highlight)(e,Bo.languages.css),textareaId:"marketplace-import-text",textareaClassName:"import-textarea",readOnly:!1,className:"marketplace-code-editor-textarea",placeholder:y("backupModal.inputPlaceholder"),style:{}}))),jo.default.createElement(Go,{classes:["marketplace-backup-button"],onClick:async()=>{var e,t,a=(()=>{var e={};for(const t in localStorage)t.startsWith("marketplace:")&&(e[t]=localStorage.getItem(t));return e})();try{e=JSON.stringify(a,null,2),t=new Date,await(t=await(await window.showSaveFilePicker({id:"marketplace-settings-backup",suggestedName:`marketplace-settings-${t.toISOString()}.json`,excludeAcceptAllOption:!0,types:[{description:"JSON files",accept:{"application/json":[".json"]}}]})).createWritable()).write(e),await t.close(),Spicetify.showNotification(y("backupModal.settingsSaved"))}catch(e){"AbortError"!==e.name&&(console.error("Failed to save file, copying to clipboard instead:",e),Spicetify.Platform.ClipboardAPI.copy(JSON.stringify(a)),Spicetify.showNotification(y("backupModal.settingsCopied")))}Spicetify.PopupModal.hide()}},y("backupModal.exportBtn")),jo.default.createElement(Go,{classes:["marketplace-backup-button"],onClick:()=>{a(e)}},y("backupModal.importBtn")),jo.default.createElement(Go,{classes:["marketplace-backup-button"],onClick:async()=>{var e=await(await(await window.showOpenFilePicker())[0].getFile()).text();a(e)}},y("backupModal.fileImportBtn")))},Ho=t(a()),qo=()=>Ho.default.createElement("div",{id:"marketplace-reload-container"},Ho.default.createElement("p",null,y("reloadModal.description")),Ho.default.createElement("div",{className:"marketplace-reload-modal__button-container"},Ho.default.createElement(Go,{onClick:()=>{Spicetify.PopupModal.hide(),location.reload()}},y("reloadModal.reloadNow")),Ho.default.createElement(Go,{onClick:()=>{Spicetify.PopupModal.hide()}},y("reloadModal.reloadLater")))),u=t(a()),Wo=t(a()),Ko=t(a()),Jo=()=>Ko.default.createElement("svg",{height:"16",width:"16",className:"Svg-sc-ytk21e-0 uPxdw nW1RKQOkzcJcX6aDCZB4",viewBox:"0 0 16 16",role:"img","aria-label":"Tooltip Icon"},Ko.default.createElement("path",{d:"M8 1.5a6.5 6.5 0 100 13 6.5 6.5 0 000-13zM0 8a8 8 0 1116 0A8 8 0 010 8z"}),Ko.default.createElement("path",{d:"M7.25 12.026v-1.5h1.5v1.5h-1.5zm.884-7.096A1.125 1.125 0 007.06 6.39l-1.431.448a2.625 2.625 0 115.13-.784c0 .54-.156 1.015-.503 1.488-.3.408-.7.652-.973.818l-.112.068c-.185.116-.26.203-.302.283-.046.087-.097.245-.097.57h-1.5c0-.47.072-.898.274-1.277.206-.385.507-.645.827-.846l.147-.092c.285-.177.413-.257.526-.41.169-.23.213-.397.213-.602 0-.622-.503-1.125-1.125-1.125z"})),Yo=t(a()),Zo=t(Be()),Xo=t=>{var e=t.sortBoxOptions.map(e=>({value:e.key,label:e.value})),a=t.sortBoxOptions.find(t.sortBySelectedFn);return Yo.default.createElement("div",{className:"marketplace-sortBox"},Yo.default.createElement("div",{className:"marketplace-sortBox-header"},Yo.default.createElement("div",{className:"marketplace-sortBox-header-title"}),Yo.default.createElement(Zo.default,{placeholder:"Select an option",options:e,value:a?.key,onChange:e=>{t.onChange(e.value)}})))},Qo=t(a()),ei="toggle-module__toggle-wrapper___ocE5z_marketplace",ti="toggle-module__disabled___OYAYf_marketplace",ai="toggle-module__toggle-input___ceLM4_marketplace",ri="toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace",ni="toggle-module__toggle-indicator___nCxwE_marketplace",oi=e=>{var t="toggle:"+e.storageKey,a=[ei];return!1===e.clickable&&a.push(ti),Qo.default.createElement("label",{className:a.join(" ")},Qo.default.createElement("input",{className:ai,type:"checkbox",checked:e.enabled,"data-storage-key":e.storageKey,id:t,title:"Toggle for "+e.storageKey,onChange:e.onChange}),Qo.default.createElement("span",{className:ri},Qo.default.createElement("span",{className:ni})))},ii=t(a());function si({children:e,...t}){return Spicetify.ReactComponent.TooltipWrapper?ii.default.createElement(Spicetify.ReactComponent.TooltipWrapper,{...t},e):e}var li=a=>{var e=a.type,t="dropdown"===e?"dropdown:"+a.storageKey:"toggle:"+a.storageKey,r=!!a.modalConfig.visual[a.storageKey];return void 0!==a.description&&null!==a.description||(a.description=""),"dropdown"===e&&a.options?Wo.default.createElement("div",{className:"settings-row"},Wo.default.createElement("label",{htmlFor:t,className:"col description"},a.name),Wo.default.createElement("div",{className:"col action"},Wo.default.createElement(Xo,{sortBoxOptions:a.options.map(e=>({key:e,value:e})),onChange:e=>{return e=e,t=a.storageKey,a.modalConfig.visual[t]=e,localStorage.setItem("marketplace:"+t,String(e)),void a.updateConfig(a.modalConfig);var t},sortBySelectedFn:e=>e.key===a.modalConfig.visual[a.storageKey]}),Wo.default.createElement(si,{label:a.description.split("\n").map(e=>Wo.default.createElement("span",{key:e},e,Wo.default.createElement("br",null))),renderInline:!0,showDelay:10,placement:"top",labelClassName:"marketplace-settings-tooltip",disabled:!1},Wo.default.createElement("div",{className:"marketplace-tooltip-icon"},Wo.default.createElement(Jo,null))))):Wo.default.createElement("div",{className:"settings-row"},Wo.default.createElement("label",{htmlFor:t,className:"col description"},a.name),Wo.default.createElement("div",{className:"col action"},Wo.default.createElement(oi,{name:a.name,storageKey:a.storageKey,enabled:r,onChange:e=>{var t=e.target.checked,e=e.target.dataset.storageKey;a.modalConfig.visual[e]=t,console.debug(`toggling ${e} to `+t),localStorage.setItem("marketplace:"+e,String(t)),a.updateConfig(a.modalConfig)}})))},H=t(a()),ci=t(je()),di=(()=>"function"==typeof Symbol&&Symbol.observable||"@@observable")(),ui=()=>Math.random().toString(36).substring(7).split("").join("."),pi={INIT:"@@redux/INIT"+ui(),REPLACE:"@@redux/REPLACE"+ui(),PROBE_UNKNOWN_ACTION:()=>"@@redux/PROBE_UNKNOWN_ACTION"+ui()};function mi(e){if(void 0===e)return"undefined";if(null===e)return"null";var t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if((a=e)instanceof Date||"function"==typeof a.toDateString&&"function"==typeof a.getDate&&"function"==typeof a.setDate)return"date";if((a=e)instanceof Error||"string"==typeof a.message&&a.constructor&&"number"==typeof a.constructor.stackTraceLimit)return"error";var a,r="function"==typeof(a=e).constructor?a.constructor.name:null;switch(r){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return r}return Object.prototype.toString.call(e).slice(8,-1).toLowerCase().replace(/\s/g,"")}function hi(e){let t=typeof e;return t=mi(e)}function gi(e,t,a){if("function"!=typeof e)throw new Error(`Expected the root reducer to be a function. Instead, received: '${hi(e)}'`);if("function"==typeof t&&"function"==typeof a||"function"==typeof a&&"function"==typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if("function"==typeof t&&void 0===a&&(a=t,t=void 0),void 0!==a){if("function"!=typeof a)throw new Error(`Expected the enhancer to be a function. Instead, received: '${hi(a)}'`);return a(gi)(e,t)}let r=e,n=t,o=new Map,i=o,s=0,l=!1;function c(){i===o&&(i=new Map,o.forEach((e,t)=>{i.set(t,e)}))}function d(){if(l)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return n}function u(e){if("function"!=typeof e)throw new Error(`Expected the listener to be a function. Instead, received: '${hi(e)}'`);if(l)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");let t=!0;c();const a=s++;return i.set(a,e),function(){if(t){if(l)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");t=!1,c(),i.delete(a),o=null}}}function p(e){if(!function(t){if("object"==typeof t&&null!==t){let e=t;for(;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e||null===Object.getPrototypeOf(t)}}(e))throw new Error(`Actions must be plain objects. Instead, the actual type was: '${hi(e)}'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.`);if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if("string"!=typeof e.type)throw new Error(`Action "type" property must be a string. Instead, the actual type was: '${hi(e.type)}'. Value was: '${e.type}' (stringified)`);if(l)throw new Error("Reducers may not dispatch actions.");try{l=!0,n=r(n,e)}finally{l=!1}o=i;return o.forEach(e=>{e()}),e}return p({type:pi.INIT}),{dispatch:p,subscribe:u,getState:d,replaceReducer:function(e){if("function"!=typeof e)throw new Error("Expected the nextReducer to be a function. Instead, received: '"+hi(e));r=e,p({type:pi.REPLACE})},[di]:function(){const a=u;return{subscribe(t){if("object"!=typeof t||null===t)throw new Error(`Expected the observer to be an object. Instead, received: '${hi(t)}'`);function e(){var e=t;e.next&&e.next(d())}return e(),{unsubscribe:a(e)}},[di](){return this}}}}}function fi(t,a){return function(...e){return a(t.apply(this,e))}}function bi(e,t){if("function"==typeof e)return fi(e,t);if("object"!=typeof e||null===e)throw new Error(`bindActionCreators expected an object or a function, but instead received: '${hi(e)}'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?`);var a={};for(const n in e){var r=e[n];"function"==typeof r&&(a[n]=fi(r,t))}return a}function vi(...e){return 0===e.length?e=>e:1===e.length?e[0]:e.reduce((t,a)=>(...e)=>t(a(...e)))}var D=t(a(),1),yi=(t(e(),1),D.version.startsWith("19")),Si=Symbol.for(yi?"react.transitional.element":"react.element"),wi=Symbol.for("react.portal"),ki=Symbol.for("react.fragment"),Ei=Symbol.for("react.strict_mode"),Ci=Symbol.for("react.profiler"),Ii=Symbol.for("react.consumer"),xi=Symbol.for("react.context"),Ni=Symbol.for("react.forward_ref"),Ai=Symbol.for("react.suspense"),Ti=Symbol.for("react.suspense_list"),Oi=Symbol.for("react.memo"),Li=Symbol.for("react.lazy"),Di=Symbol.for("react.offscreen"),Pi=Symbol.for("react.client.reference");function Mi(e){return"string"==typeof e||"function"==typeof e||e===ki||e===Ci||e===Ei||e===Ai||e===Ti||e===Di||"object"==typeof e&&null!==e&&(e.$$typeof===Li||e.$$typeof===Oi||e.$$typeof===xi||e.$$typeof===Ii||e.$$typeof===Ni||e.$$typeof===Pi||void 0!==e.getModuleId)}function Ri(e){if("object"==typeof e&&null!==e){var t=e["$$typeof"];switch(t){case Si:switch(e=e.type){case ki:case Ci:case Ei:case Ai:case Ti:return e;default:switch(e=e&&e.$$typeof){case xi:case Ni:case Li:case Oi:case Ii:return e;default:return t}}case wi:return t}}}function _i(e){return yi?Ri(e)===Ii:Ri(e)===xi}function Bi(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}function ji(e,t){if(!e)throw new Error(`Unexpected value for ${t} in connect.`);"mapStateToProps"!==t&&"mapDispatchToProps"!==t||Object.prototype.hasOwnProperty.call(e,"dependsOnOwnProps")||Bi(`The selector for ${t} of connect did not specify a value for dependsOnOwnProps.`)}function $i(n,o,i,s,{areStatesEqual:l,areOwnPropsEqual:c,areStatePropsEqual:d}){let a=!1,u,p,m,h,g;function r(e,t){var a=!c(t,p),r=!l(e,u,t,p);return u=e,p=t,a&&r?(m=n(u,p),o.dependsOnOwnProps&&(h=o(s,p)),g=i(m,h,p)):a?(n.dependsOnOwnProps&&(m=n(u,p)),o.dependsOnOwnProps&&(h=o(s,p)),g=i(m,h,p)):r?(e=n(u,p),t=!d(e,m),m=e,g=t?i(m,h,p):g):g}return function(e,t){return a?r(e,t):(e=e,t=t,u=e,p=t,m=n(u,p),h=o(s,p),g=i(m,h,p),a=!0,g)}}function zi(e,{initMapStateToProps:t,initMapDispatchToProps:a,initMergeProps:r,...n}){var o,i,t=t(e,n),a=a(e,n),r=r(e,n);return o=a,i=r,ji(t,"mapStateToProps"),ji(o,"mapDispatchToProps"),ji(i,"mergeProps"),$i(t,a,r,e,n)}function Ui(e,t,a){!function(t){if("object"==typeof t&&null!==t){t=Object.getPrototypeOf(t);if(null===t)return 1;let e=t;for(;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return t===e}}(e)&&Bi(a+`() in ${t} must return a plain object. Instead received ${e}.`)}function Fi(r){return function(e){const t=r(e);function a(){return t}return a.dependsOnOwnProps=!1,a}}function Gi(e){return e.dependsOnOwnProps?Boolean(e.dependsOnOwnProps):1!==e.length}function Vi(o,i){return function(e,{displayName:r}){const n=function(e,t){return n.dependsOnOwnProps?n.mapToProps(e,t):n.mapToProps(e,void 0)};return n.dependsOnOwnProps=!0,n.mapToProps=function(e,t){n.mapToProps=o,n.dependsOnOwnProps=Gi(o);let a=n(e,t);return"function"==typeof a&&(n.mapToProps=a,n.dependsOnOwnProps=Gi(a),a=n(e,t)),Ui(a,r,i),a},n}}function Hi(a,r){return(e,t)=>{throw new Error(`Invalid value of type ${typeof a} for ${r} argument when connecting component ${t.wrappedComponentName}.`)}}function qi(i){return i&&"object"==typeof i?Fi(e=>{var t=i,a=e,r={};for(const n in t){const o=t[n];"function"==typeof o&&(r[n]=(...e)=>a(o(...e)))}return r}):i?("function"==typeof i?Vi:Hi)(i,"mapDispatchToProps"):Fi(e=>({dispatch:e}))}function Wi(e){return e?"function"==typeof e?(s=e,function(e,{displayName:r,areMergedPropsEqual:n}){let o=!1,i;return function(e,t,a){e=s(e,t,a);return o?n(e,i)||(i=e):(o=!0,Ui(i=e,r,"mergeProps")),i}}):Hi(e,"mergeProps"):()=>function(e,t,a){return{...a,...e,...t}};var s}function Ki(){let r=null,n=null;return{clear(){r=null,n=null},notify(){{let e=r;for(;e;)e.callback(),e=e.next}},get(){var e=[];let t=r;for(;t;)e.push(t),t=t.next;return e},subscribe(e){let t=!0;const a=n={callback:e,next:null,prev:n};return a.prev?a.prev.next=a:r=a,function(){t&&null!==r&&(t=!1,a.next?a.next.prev=a.prev:n=a.prev,a.prev?a.prev.next=a.next:r=a.next)}}}}var Ji={notify(){},get:()=>[]};function Yi(e,t){let a,r=Ji,n=0,o=!1;function i(){c.onStateChange&&c.onStateChange()}function s(){n++,a||(a=t?t.addNestedSub(i):e.subscribe(i),r=Ki())}function l(){n--,a&&0===n&&(a(),a=void 0,r.clear(),r=Ji)}const c={addNestedSub:function(e){s();const t=r.subscribe(e);let a=!1;return()=>{a||(a=!0,t(),l())}},notifyNestedSubs:function(){r.notify()},handleChangeWrapper:i,isSubscribed:function(){return o},trySubscribe:function(){o||(o=!0,s())},tryUnsubscribe:function(){o&&(o=!1,l())},getListeners:()=>r};return c}var Zi=(()=>!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement))(),Xi=(()=>"undefined"!=typeof navigator&&"ReactNative"===navigator.product)(),Qi=(()=>Zi||Xi?D.useLayoutEffect:D.useEffect)();function es(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!=e&&t!=t}function ts(t,a){if(!es(t,a)){if("object"!=typeof t||null===t||"object"!=typeof a||null===a)return!1;var r=Object.keys(t),e=Object.keys(a);if(r.length!==e.length)return!1;for(let e=0;e({})),u=qi(t),p=Wi(a),O=Boolean(e);return x=>{if(!Mi(x))throw new Error("You must pass a component to the function returned by connect. Instead received "+(t=>{try{return JSON.stringify(t)}catch(e){return String(t)}})(x));var e=x.displayName||x.name||"Component";const N=`Connect(${e})`,A={shouldHandleStateChanges:O,displayName:N,wrappedComponentName:e,WrappedComponent:x,initMapStateToProps:d,initMapDispatchToProps:u,initMergeProps:p,areStatesEqual:n,areStatePropsEqual:i,areOwnPropsEqual:o,areMergedPropsEqual:s};function t(a){const[t,e,r]=D.useMemo(()=>{const{reactReduxForwardedRef:e,...t}=a;return[a.context,e,t]},[a]),n=D.useMemo(()=>{let e=T;if(t?.Consumer){if(!_i(D.createElement(t.Consumer,null)))throw new Error("You must pass a valid React context consumer as `props.context`");e=t}return e},[t,T]),o=D.useContext(n),i=Boolean(a.store)&&Boolean(a.store.getState)&&Boolean(a.store.dispatch);var s=Boolean(o)&&Boolean(o.store);if(!i&&!s)throw new Error(`Could not find "store" in the context of "${N}". Either wrap the root component in a , or pass a custom React context provider to and the corresponding React context consumer to ${N} in connect options.`);const h=(i?a:o).store,l=s?o.getServerState:h.getState,g=D.useMemo(()=>zi(h.dispatch,A),[h]),[f,b]=D.useMemo(()=>{var e,t;return O?(t=(e=Yi(h,i?void 0:o.subscription)).notifyNestedSubs.bind(e),[e,t]):vs},[h,i,o]),c=D.useMemo(()=>i?o:{...o,subscription:f},[i,o,f]),v=D.useRef(void 0),y=D.useRef(r),S=D.useRef(void 0),w=D.useRef(!1),k=D.useRef(!1),d=D.useRef(void 0);Qi(()=>(k.current=!0,()=>{k.current=!1}),[]);var u,p,m,s=D.useMemo(()=>{return()=>S.current&&r===y.current?S.current:g(h.getState(),r)},[h,r]),E=D.useMemo(()=>{return t=>{if(f){var a=O;var n=h;var o=f;var i=g;var s=y;var l=v;var c=w;var d=k;var u=S;var p=b;var m=t;if(!a)return()=>{};let e=!1,r=null;return a=()=>{if(!e&&d.current){var a=n.getState();let e,t;try{e=i(a,s.current)}catch(e){t=e,r=e}t||(r=null),e===l.current?c.current||p():(l.current=e,u.current=e,c.current=!0,m())}},o.onStateChange=a,o.trySubscribe(),a(),()=>{if(e=!0,o.tryUnsubscribe(),o.onStateChange=null,r)throw r}}return()=>{}}},[f]);u=ys,p=[y,v,w,r,S,b],Qi(()=>u(...p),m);let C;try{C=D.useSyncExternalStore(E,s,l?()=>g(l(),r):s)}catch(e){throw d.current&&(e.message+=` -The error may be correlated with this previous error: -${d.current.stack} - -`),e}Qi(()=>{d.current=void 0,S.current=void 0,v.current=C});const I=D.useMemo(()=>D.createElement(x,{...C,ref:e}),[e,x,C]);return D.useMemo(()=>O?D.createElement(n.Provider,{value:c},I):I,[n,I,c])}const a=D.memo(t);return a.WrappedComponent=x,a.displayName=t.displayName=N,l?((e=D.forwardRef(function(e,t){return D.createElement(a,{...e,reactReduxForwardedRef:t})})).displayName=N,e.WrappedComponent=x,ms(e,x)):ms(a,x)}};var ws=function(r){const{children:e,context:t,serverState:n,store:o}=r,a=D.useMemo(()=>{var e=Yi(o),e={store:o,subscription:e,getServerState:n?()=>n:void 0},{identityFunctionCheck:t="once",stabilityCheck:a="once"}=r;return Object.assign(e,{stabilityCheck:a,identityFunctionCheck:t})},[o,n]),i=D.useMemo(()=>o.getState(),[o]);return Qi(()=>{const e=a["subscription"];return e.onStateChange=e.notifyNestedSubs,e.trySubscribe(),i!==o.getState()&&e.notifyNestedSubs(),()=>{e.tryUnsubscribe(),e.onStateChange=void 0}},[a,i]),D.createElement((t||bs).Provider,{value:a},e)},ks="Invariant failed";function Es(e,t){if(!e)throw t=(e="function"==typeof t?t():t)?"".concat(ks,": ").concat(e):ks,new Error(t)}function Cs(e,t){return{top:e.top-t.top,left:e.left-t.left,bottom:e.bottom+t.bottom,right:e.right+t.right}}function Is(e,t){return{top:e.top+t.top,left:e.left+t.left,bottom:e.bottom-t.bottom,right:e.right-t.right}}function xs(e,t){return void 0===t&&(t=Ps()),Ms(e,t)}function Ns(e,t){var a={top:Ds(t.marginTop),right:Ds(t.marginRight),bottom:Ds(t.marginBottom),left:Ds(t.marginLeft)},r={top:Ds(t.paddingTop),right:Ds(t.paddingRight),bottom:Ds(t.paddingBottom),left:Ds(t.paddingLeft)},t={top:Ds(t.borderTopWidth),right:Ds(t.borderRightWidth),bottom:Ds(t.borderBottomWidth),left:Ds(t.borderLeftWidth)};return Ls({borderBox:e,margin:a,padding:r,border:t})}function As(e){var t=e.getBoundingClientRect(),e=window.getComputedStyle(e);return Ns(t,e)}var Ts=function(e){var t=e.top,a=e.right,r=e.bottom,e=e.left;return{top:t,right:a,bottom:r,left:e,width:a-e,height:r-t,x:e,y:t,center:{x:(a+e)/2,y:(r+t)/2}}},Os={top:0,right:0,bottom:0,left:0},Ls=function(e){var t=e.borderBox,a=e.margin,a=void 0===a?Os:a,r=e.border,r=void 0===r?Os:r,e=e.padding,e=void 0===e?Os:e,n=Ts(Cs(t,a)),o=Ts(Is(t,r)),i=Ts(Is(o,e));return{marginBox:n,borderBox:Ts(t),paddingBox:o,contentBox:i,margin:a,border:r,padding:e}},Ds=function(e){var t,a=e.slice(0,-2);return"px"!==e.slice(-2)?0:(t=Number(a),isNaN(t)&&Es(!1,"Could not parse value [raw: "+e+", without suffix: "+a+"]"),t)},Ps=function(){return{x:window.pageXOffset,y:window.pageYOffset}},Ms=function(e,t){var a=e.borderBox,r=e.border,n=e.margin,e=e.padding,a={top:a.top+t.y,left:a.left+t.x,bottom:a.bottom+t.y,right:a.right+t.x};return Ls({borderBox:a,border:r,margin:n,padding:e})},Rs=function(r){function e(){for(var e=arguments.length,t=new Array(e),a=0;ae.replace(Bs," ").replace(js,"").trim(),zs=e=>$s(` - %c@hello-pangea/dnd - - %c${$s(e)} - - %c👷‍ This is a development only message. It will be removed in production builds. -`);function Us(e,t){"undefined"!=typeof window&&window["__@hello-pangea/dnd-disable-dev-warnings"]||console[e](...[zs(t),"color: #00C584; font-size: 1.2em; font-weight: bold;","line-height: 1.5","color: #723874;"])}var q=Us.bind(null,"warn"),Fs=Us.bind(null,"error");function Gs(){}function Vs(r,e,n){const t=e.map(e=>{a=e.options;const t={...n,...a};var a;return r.addEventListener(e.eventName,e.fn,t),function(){r.removeEventListener(e.eventName,e.fn,t)}});return function(){t.forEach(e=>{e()})}}var Hs=!1,qs="Invariant failed",Ws=class extends Error{};function W(e,t){throw new Ws(Hs?qs:qs+": "+(t||""))}Ws.prototype.toString=function(){return this.message};var Ks=class extends H.default.Component{constructor(...e){super(...e),this.callbacks=null,this.unbind=Gs,this.onWindowError=e=>{var t=this.getCallbacks(),t=(t.isDragging()&&(t.tryAbort(),q(` - An error was caught by our window 'error' event listener while a drag was occurring. - The active drag has been aborted. - `)),e.error);t instanceof Ws&&(e.preventDefault(),Fs(t.message))},this.getCallbacks=()=>{if(this.callbacks)return this.callbacks;throw new Error("Unable to find AppCallbacks in ")},this.setCallbacks=e=>{this.callbacks=e}}componentDidMount(){this.unbind=Vs(window,[{eventName:"error",fn:this.onWindowError}])}componentDidCatch(e){if(!(e instanceof Ws))throw e;Fs(e.message),this.setState({})}componentWillUnmount(){this.unbind()}render(){return this.props.children(this.setCallbacks)}},Js=e=>e+1,Ys=(e,t)=>{var a=e.droppableId===t.droppableId,r=Js(e.index),n=Js(t.index);return a?` - You have moved the item from position ${r} - to position ${n} - `:` - You have moved the item from position ${r} - in list ${e.droppableId} - to list ${t.droppableId} - in position ${n} - `},Zs=(e,t,a)=>{return t.droppableId===a.droppableId?` - The item ${e} - has been combined with `+a.draggableId:` - The item ${e} - in list ${t.droppableId} - has been combined with ${a.draggableId} - in list ${a.droppableId} - `},Xs=e=>` - The item has returned to its starting position - of ${Js(e.index)} -`,Qs={dragHandleUsageInstructions:` - Press space bar to start a drag. - When dragging you can use the arrow keys to move the item around and escape to cancel. - Some screen readers may require you to be in focus mode or to use your pass through key -`,onDragStart:e=>` - You have lifted an item in position ${Js(e.source.index)} -`,onDragUpdate:e=>{var t=e.destination;return t?Ys(e.source,t):(t=e.combine)?Zs(e.draggableId,e.source,t):"You are over an area that cannot be dropped on"},onDragEnd:e=>{var t,a;return"CANCEL"===e.reason?` - Movement cancelled. - ${Xs(e.source)} - `:(t=e.destination,a=e.combine,t?` - You have dropped the item. - ${Ys(e.source,t)} - `:a?` - You have dropped the item. - ${Zs(e.draggableId,e.source,a)} - `:` - The item has been dropped while not over a drop area. - ${Xs(e.source)} - `)}};function el(t,a){if(t.length!==a.length)return!1;for(let e=0;e({inputs:t,result:e()}))[0];const r=(0,H.useRef)(!0),n=(0,H.useRef)(a),o=r.current||Boolean(t&&n.current.inputs&&el(t,n.current.inputs))?n.current:{inputs:t,result:e()};return(0,H.useEffect)(()=>{r.current=!1,n.current=o},[o]),o.result}function J(e,t){return K(()=>e,t)}var Y={x:0,y:0},p=(e,t)=>({x:e.x+t.x,y:e.y+t.y}),tl=(e,t)=>({x:e.x-t.x,y:e.y-t.y}),al=(e,t)=>e.x===t.x&&e.y===t.y,rl=e=>({x:0!==e.x?-e.x:0,y:0!==e.y?-e.y:0}),nl=(e,t,a=0)=>"x"===e?{x:t,y:a}:{x:a,y:t},ol=(e,t)=>Math.sqrt((t.x-e.x)**2+(t.y-e.y)**2),il=(t,e)=>Math.min(...e.map(e=>ol(t,e))),zn=t=>e=>({x:t(e.x),y:t(e.y)}),sl=(e,t)=>({top:e.top+t.y,left:e.left+t.x,bottom:e.bottom+t.y,right:e.right+t.x}),ll=e=>[{x:e.left,y:e.top},{x:e.right,y:e.top},{x:e.left,y:e.bottom},{x:e.right,y:e.bottom}],cl=(e,t)=>{var a;return t&&t.shouldClipSubject?(t=t.pageMarginBox,a=e,(a=Ts({top:Math.max(a.top,t.top),right:Math.min(a.right,t.right),bottom:Math.min(a.bottom,t.bottom),left:Math.max(a.left,t.left)})).width<=0||a.height<=0?null:a):Ts(e)},dl=({page:e,withPlaceholder:t,axis:a,frame:r})=>{n=e.marginBox;var n,o=(o=r)?sl(n,o.scroll.diff.displacement):n,a=(n=o,o=a,(a=t)&&a.increasedBy?{...n,[o.end]:n[o.end]+a.increasedBy[o.line]}:n);return{page:e,withPlaceholder:t,active:cl(a,r)}},ul=(e,t)=>{e.frame||W();var a=e.frame,r=tl(t,a.scroll.initial),n=rl(r),t={...a,scroll:{initial:a.scroll.initial,current:t,diff:{value:r,displacement:n},max:a.scroll.max}},r=dl({page:e.subject.page,withPlaceholder:e.subject.withPlaceholder,axis:e.axis,frame:t});return{...e,frame:t,subject:r}};function Z(a,r=el){let n=null;function e(...e){var t;return n&&n.lastThis===this&&r(e,n.lastArgs)?n.lastResult:(t=a.apply(this,e),n={lastResult:t,lastArgs:e,lastThis:this},t)}return e.clear=function(){n=null},e}var pl=Z(e=>e.reduce((e,t)=>(e[t.descriptor.id]=t,e),{})),ml=Z(e=>e.reduce((e,t)=>(e[t.descriptor.id]=t,e),{})),hl=Z(e=>Object.values(e)),gl=Z(e=>Object.values(e)),fl=Z((t,e)=>{return gl(e).filter(e=>t===e.descriptor.droppableId).sort((e,t)=>e.descriptor.index-t.descriptor.index)});function bl(e){return e.at&&"REORDER"===e.at.type?e.at.destination:null}function vl(e){return e.at&&"COMBINE"===e.at.type?e.at.combine:null}var yl=Z((t,e)=>e.filter(e=>e.descriptor.id!==t.descriptor.id)),Sl=(e,t)=>e.descriptor.droppableId===t.descriptor.id,wl={point:Y,value:0},kl={invisible:{},visible:{},all:[]},El={displaced:kl,displacedBy:wl,at:null},Cl=(t,a)=>e=>t<=e&&e<=a,Il=n=>{const o=Cl(n.top,n.bottom),i=Cl(n.left,n.right);return e=>{var t,a,r;return!!(o(e.top)&&o(e.bottom)&&i(e.left)&&i(e.right))||(t=o(e.top)||o(e.bottom),a=i(e.left)||i(e.right),!(!t||!a))||(r=e.topn.bottom,e=e.leftn.right,r&&e)||r&&a||e&&t}},xl=e=>{const t=Cl(e.top,e.bottom),a=Cl(e.left,e.right);return e=>{return t(e.top)&&t(e.bottom)&&a(e.left)&&a(e.right)}},Nl={direction:"vertical",line:"y",crossAxisLine:"x",start:"top",end:"bottom",size:"height",crossAxisStart:"left",crossAxisEnd:"right",crossAxisSize:"width"},Al={direction:"horizontal",line:"x",crossAxisLine:"y",start:"left",end:"right",size:"width",crossAxisStart:"top",crossAxisEnd:"bottom",crossAxisSize:"height"},Tl=({target:e,destination:t,viewport:a,withDroppableDisplacement:r,isVisibleThroughFrameFn:n})=>{var o,r=r?((e,t)=>{t=t.frame?t.frame.scroll.diff.displacement:Y;return sl(e,t)})(e,t):e;return e=r,o=n,!!(t=t).subject.active&&o(t.subject.active)(e)&&(o=r,n(a)(o))},Ol=e=>Tl({...e,isVisibleThroughFrameFn:xl}),Ll=e=>{return Tl({...e,isVisibleThroughFrameFn:(r=e.destination.axis,e=>{const t=Cl(e.top,e.bottom),a=Cl(e.left,e.right);return e=>r===Nl?t(e.top)&&t(e.bottom):a(e.left)&&a(e.right)})});var r};function Dl({afterDragging:e,destination:i,displacedBy:s,viewport:l,forceShouldAnimate:c,last:d}){return e.reduce(function(e,t){o=s,n=(n=t).page.marginBox,o={top:s.point.y,right:0,bottom:0,left:s.point.x};var a,r,n=Ts(Cs(n,o)),o=t.descriptor.id,n=(e.all.push(o),Tl({...{target:n,destination:i,viewport:l,withDroppableDisplacement:!0},isVisibleThroughFrameFn:Il}));return n?(a=(n=o,a=d,"boolean"==typeof(r=c)?r:!a||({invisible:r,visible:a}=a,!r[n]&&(!(r=a[n])||r.shouldAnimate))),e.visible[o]={draggableId:o,shouldAnimate:a}):e.invisible[t.descriptor.id]=!0,e},{all:[],visible:{},invisible:{}})}function Pl({insideDestination:e,inHomeList:t,displacedBy:a,destination:r}){t={inHomeList:t};t=(e=e).length?(e=e[e.length-1].descriptor.index,t.inHomeList?e:e+1):0;return{displaced:kl,displacedBy:a,at:{type:"REORDER",destination:{droppableId:r.descriptor.id,index:t}}}}function Ml({draggable:e,insideDestination:t,destination:a,viewport:r,displacedBy:n,last:o,index:i,forceShouldAnimate:s}){var l,c=Sl(e,a);return null!=i&&(l=t.find(e=>e.descriptor.index===i))?(e=yl(e,t),l=t.indexOf(l),{displaced:Dl({afterDragging:e.slice(l),destination:a,displacedBy:n,last:o,viewport:r.frame,forceShouldAnimate:s}),displacedBy:n,at:{type:"REORDER",destination:{droppableId:a.descriptor.id,index:i}}}):Pl({insideDestination:t,inHomeList:c,displacedBy:n,destination:a})}function Rl(e,t){return Boolean(t.effected[e])}var _l=({isMovingForward:e,isInHomeList:t,draggable:a,draggables:r,destination:n,insideDestination:o,previousImpact:i,viewport:s,afterCritical:l})=>{var c,d,u,p,m=i.at;return m||W(0,"Cannot move in direction without previous impact location"),"REORDER"===m.type?({isMovingForward:t,isInHomeList:d,insideDestination:u,location:p}=[{isMovingForward:e,isInHomeList:t,location:m.destination,insideDestination:o}][0],null==(p=!u.length||(p=p.index,c=u[0].descriptor.index,u=u[u.length-1].descriptor.index,(t=t?p+1:p-1){var r=vl(t),r=(r||W(),r.draggableId),a=a[r].page.borderBox.center,e=(({displaced:e,afterCritical:t,combineWith:a,displacedBy:r})=>{e=Boolean(e.visible[a]||e.invisible[a]);return Rl(a,t)?e?Y:rl(r.point):e?r.point:Y})({displaced:t.displaced,afterCritical:e,combineWith:r,displacedBy:t.displacedBy});return p(a,e)},jl=(e,t)=>t.margin[e.start]+t.borderBox[e.size]/2,$l=(e,t,a)=>t[e.crossAxisStart]+a.margin[e.crossAxisStart]+a.borderBox[e.crossAxisSize]/2,zl=({axis:e,moveRelativeTo:t,isMoving:a})=>nl(e.line,t.marginBox[e.end]+jl(e,a),$l(e,t.marginBox,a)),Ul=({axis:e,moveRelativeTo:t,isMoving:a})=>{return nl(e.line,t.marginBox[e.start]-(a.margin[e.end]+a.borderBox[e.size]/2),$l(e,t.marginBox,a))},Fl=({impact:e,draggable:t,draggables:a,droppable:r,afterCritical:n})=>{var o,i=fl(r.descriptor.id,a),s=t.page,l=r.axis;return i.length?({displaced:e,displacedBy:o}=e,(e=e.all[0])?(a=a[e],Rl(e,n)?Ul({axis:l,moveRelativeTo:a.page,isMoving:s}):(e=Ms(a.page,o.point),Ul({axis:l,moveRelativeTo:e,isMoving:s}))):(a=i[i.length-1]).descriptor.id===t.descriptor.id?s.borderBox.center:Rl(a.descriptor.id,n)?(o=Ms(a.page,rl(n.displacedBy.point)),zl({axis:l,moveRelativeTo:o,isMoving:s})):zl({axis:l,moveRelativeTo:a.page,isMoving:s})):({axis:e,moveInto:i,isMoving:t}=[{axis:l,moveInto:r.page,isMoving:s}][0],nl(e.line,i.contentBox[e.start]+jl(e,t),$l(e,i.contentBox,t)))},Gl=(e,t)=>{e=e.frame;return e?p(t,e.scroll.diff.displacement):t},Vl=e=>{({impact:t,draggable:s,droppable:a,draggables:r,afterCritical:n}=e),o=s.page.borderBox.center,i=t.at;var t,a,r,n,o,i=a&&i?"REORDER"===i.type?Fl({impact:t,draggable:s,draggables:r,droppable:a,afterCritical:n}):Bl({impact:t,draggables:r,afterCritical:n}):o,s=e.droppable;return s?Gl(s,i):i},Hl=(e,t)=>{var a=tl(t,e.scroll.initial),r=rl(a);return{frame:Ts({top:t.y,bottom:t.y+e.frame.height,left:t.x,right:t.x+e.frame.width}),scroll:{initial:e.scroll.initial,max:e.scroll.max,current:t,diff:{value:a,displacement:r}}}};function ql(e,t){return e.map(e=>t[e])}var Wl=({impact:e,viewport:t,destination:a,draggables:r,maxScrollChange:n})=>{var o=Hl(t,p(t.scroll.current,n)),n=a.frame?ul(a,p(a.frame.scroll.current,n)):a,i=e.displaced,a=Dl({afterDragging:ql(i.all,r),destination:a,displacedBy:e.displacedBy,viewport:o.frame,last:i,forceShouldAnimate:!1}),o=Dl({afterDragging:ql(i.all,r),destination:n,displacedBy:e.displacedBy,viewport:t.frame,last:i,forceShouldAnimate:!1});const s={},l={},c=[i,a,o];return i.all.forEach(e=>{var t=function(t,a){for(let e=0;e{a=p(a.scroll.diff.displacement,e),e=tl(a,t.page.borderBox.center);return p(t.client.borderBox.center,e)},Jl=({draggable:e,destination:t,newPageBorderBoxCenter:a,viewport:r,withDroppableDisplacement:n,onlyOnMainAxis:o=!1})=>{a=tl(a,e.page.borderBox.center),e={target:sl(e.page.borderBox,a),destination:t,withDroppableDisplacement:n,viewport:r};return(o?Ll:Ol)(e)},Yl=({isMovingForward:e,draggable:t,destination:a,draggables:r,previousImpact:n,viewport:o,previousPageBorderBoxCenter:i,previousClientSelection:s,afterCritical:l})=>{var c,d;return a.isEnabled&&(d=fl(a.descriptor.id,r),c=Sl(t,a),e=(({isMovingForward:e,draggable:t,destination:a,insideDestination:r,previousImpact:n})=>{if(!a.isCombineEnabled)return null;if(!bl(n))return null;function o(e){e={type:"COMBINE",combine:{draggableId:e,droppableId:a.descriptor.id}};return{...n,at:e}}var i=n.displaced.all;const s=i.length?i[0]:null;return e?s?o(s):null:(i=yl(t,r),s?(-1===(e=i.findIndex(e=>e.descriptor.id===s))&&W(0,"Could not find displaced item in set"),(t=e-1)<0?null:o(i[t].descriptor.id)):i.length?o(i[i.length-1].descriptor.id):null)})({isMovingForward:e,draggable:t,destination:a,insideDestination:d,previousImpact:n})||_l({isMovingForward:e,isInHomeList:c,draggable:t,draggables:r,destination:a,insideDestination:d,previousImpact:n,viewport:o,afterCritical:l}))?(c=Vl({impact:e,draggable:t,droppable:a,draggables:r,afterCritical:l}),Jl({draggable:t,destination:a,newPageBorderBoxCenter:c,viewport:o.frame,withDroppableDisplacement:!1,onlyOnMainAxis:!0})?{clientSelection:Kl({pageBorderBoxCenter:c,draggable:t,viewport:o}),impact:e,scrollJumpRequest:null}:(d=tl(c,i),{clientSelection:s,impact:Wl({impact:e,viewport:o,destination:a,draggables:r,maxScrollChange:d}),scrollJumpRequest:d})):null},Zl=e=>{e=e.subject.active;return e||W(0,"Cannot get clipped area from droppable"),e},Xl=(e,t)=>{var a=e.page.borderBox.center;return Rl(e.descriptor.id,t)?tl(a,t.displacedBy.point):a},Ql=({pageBorderBoxCenter:n,viewport:r,destination:o,insideDestination:e,afterCritical:i})=>{return e.filter(e=>{return Ol({target:(t=i,a=e.page.borderBox,Rl(e.descriptor.id,t)?sl(a,rl(t.displacedBy.point)):a),destination:o,viewport:r.frame,withDroppableDisplacement:!0});var t,a}).sort((e,t)=>{var a=ol(n,Gl(o,Xl(e,i))),r=ol(n,Gl(o,Xl(t,i)));return a({...e,scroll:{...e.scroll,max:t}}),ac=(e,t,a)=>{var r=e.frame,t=(Sl(t,e)&&W(0,"Should not add placeholder space to home list"),e.subject.withPlaceholder&&W(0,"Cannot add placeholder size to a subject when it already has one"),ec(e.axis,t.displaceBy).point),a=((e,t,a)=>{const r=e.axis;var n;return"virtual"===e.descriptor.mode?nl(r.line,t[r.line]):(n=e.subject.page.contentBox[r.size],(e=fl(e.descriptor.id,a).reduce((e,t)=>e+t.client.marginBox[r.size],0)+t[r.line]-n)<=0?null:nl(r.line,e))})(e,t,a),t={placeholderSize:t,increasedBy:a,oldFrameMaxScroll:e.frame?e.frame.scroll.max:null};return r?(a=a?p(r.scroll.max,a):r.scroll.max,r=tc(r,a),a=dl({page:e.subject.page,withPlaceholder:t,axis:e.axis,frame:r}),{...e,subject:a,frame:r}):(a=dl({page:e.subject.page,withPlaceholder:t,axis:e.axis,frame:e.frame}),{...e,subject:a})},rc=({isMovingForward:e,previousPageBorderBoxCenter:t,draggable:a,isOver:r,draggables:n,droppables:o,viewport:i,afterCritical:s})=>{e=(({isMovingForward:a,pageBorderBoxCenter:n,source:t,droppables:e,viewport:r})=>{const o=t.subject.active;if(!o)return null;const i=t.axis,s=Cl(o[i.start],o[i.end]);var l,e=hl(e).filter(e=>e!==t).filter(e=>e.isEnabled).filter(e=>Boolean(e.subject.active)).filter(e=>Il(r.frame)(Zl(e))).filter(e=>{e=Zl(e);return a?o[i.crossAxisEnd]{var e=Zl(e),t=Cl(e[i.start],e[i.end]);return s(e[i.start])||s(e[i.end])||t(o[i.start])||t(o[i.end])}).sort((e,t)=>{e=Zl(e)[i.crossAxisStart],t=Zl(t)[i.crossAxisStart];return a?e-t:t-e}).filter((e,t,a)=>Zl(e)[i.crossAxisStart]===Zl(a[0])[i.crossAxisStart]);return e.length?(1===e.length?e:1===(l=e.filter(e=>{return Cl(Zl(e)[i.start],Zl(e)[i.end])(n[i.line])})).length?l:1Zl(e)[i.start]-Zl(t)[i.start]):e.sort((e,t)=>{var a=il(n,ll(Zl(e))),r=il(n,ll(Zl(t)));return a!==r?a-r:Zl(e)[i.start]-Zl(t)[i.start]}))[0]:null})({isMovingForward:e,pageBorderBoxCenter:t,source:r,droppables:o,viewport:i});return e&&(r=fl(e.descriptor.id,n),o=(({previousPageBorderBoxCenter:e,moveRelativeTo:t,insideDestination:a,draggable:r,draggables:n,destination:o,viewport:i,afterCritical:s})=>{if(!t)return!a.length&&(c={displaced:kl,displacedBy:wl,at:{type:"REORDER",destination:{droppableId:o.descriptor.id,index:0}}},s=Vl({impact:c,draggable:r,droppable:o,draggables:n,afterCritical:s}),n=Sl(r,o)?o:ac(o,r,n),Jl({draggable:r,destination:n,newPageBorderBoxCenter:s,viewport:i.frame,withDroppableDisplacement:!1,onlyOnMainAxis:!0}))?c:null;const l=Boolean(e[o.axis.line]<=t.page.borderBox.center[o.axis.line]);n=t.descriptor.index;var s=t.descriptor.id===r.descriptor.id||l?n:n+1,c=ec(o.axis,r.displaceBy);return Ml({draggable:r,insideDestination:a,destination:o,viewport:i,displacedBy:c,last:kl,index:s})})({previousPageBorderBoxCenter:t,destination:e,draggable:a,draggables:n,moveRelativeTo:Ql({pageBorderBoxCenter:t,viewport:i,destination:e,insideDestination:r,afterCritical:s}),insideDestination:r,viewport:i,afterCritical:s}))?(t=Vl({impact:o,draggable:a,droppable:e,draggables:n,afterCritical:s}),{clientSelection:Kl({pageBorderBoxCenter:t,draggable:a,viewport:i}),impact:o,scrollJumpRequest:null}):null},nc=e=>{e=e.at;return e?("REORDER"===e.type?e.destination:e.combine).droppableId:null},oc=({state:e,type:t})=>{var a,r,n,o=((e,t)=>{e=nc(e);return e?t[e]:null})(e.impact,e.dimensions.droppables),i=Boolean(o),s=e.dimensions.droppables[e.critical.droppable.id],o=o||s,s=o.axis.direction,s="vertical"===s&&("MOVE_UP"===t||"MOVE_DOWN"===t)||"horizontal"===s&&("MOVE_LEFT"===t||"MOVE_RIGHT"===t);return s&&!i?null:(i="MOVE_DOWN"===t||"MOVE_RIGHT"===t,t=e.dimensions.draggables[e.critical.draggable.id],a=e.current.page.borderBoxCenter,{draggables:r,droppables:n}=e.dimensions,s?Yl({isMovingForward:i,previousPageBorderBoxCenter:a,draggable:t,destination:o,draggables:r,viewport:e.viewport,previousClientSelection:e.current.client.selection,previousImpact:e.impact,afterCritical:e.afterCritical}):rc({isMovingForward:i,previousPageBorderBoxCenter:a,draggable:t,isOver:o,draggables:r,droppables:n,viewport:e.viewport,afterCritical:e.afterCritical}))};function ic(e){return"DRAGGING"===e.phase||"COLLECTING"===e.phase}function sc(e){const t=Cl(e.top,e.bottom),a=Cl(e.left,e.right);return function(e){return t(e.y)&&a(e.x)}}function lc({pageBorderBox:o,draggable:e,droppables:t}){t=hl(t).filter(e=>{var t,a,r,n;return!!e.isEnabled&&!!(n=e.subject.active)&&(t=n,(r=o).leftt.left&&r.topt.top&&(!!sc(n)(o.center)||(r=e.axis,t=n.center[r.crossAxisLine],e=o[r.crossAxisStart],a=o[r.crossAxisEnd],r=(n=Cl(n[r.crossAxisStart],n[r.crossAxisEnd]))(e),n=n(a),!r&&!n)||(r?e{var t=e.axis,t=nl(e.axis.line,a.center[t.line],e.page.borderBox.center[t.crossAxisLine]);return{id:e.descriptor.id,distance:ol(r,t)}}).sort((e,t)=>t.distance-e.distance))[0]?e[0].id:null;return}}var cc=(e,t)=>Ts(sl(e,t));function dc({displaced:e,id:t}){return Boolean(e.visible[t]||e.invisible[t])}var uc=({pageOffset:e,draggable:t,draggables:a,droppables:r,previousImpact:n,viewport:o,afterCritical:i})=>{var e=cc(t.page.borderBox,e),s=lc({pageBorderBox:e,draggable:t,droppables:r});return s?(r=r[s],s=fl(r.descriptor.id,a),(({draggable:e,pageBorderBoxWithDroppableScroll:t,previousImpact:n,destination:a,insideDestination:r,afterCritical:o})=>{if(!a.isCombineEnabled)return null;const i=a.axis;var s=ec(a.axis,e.displaceBy);const l=s.value,c=t[i.start],d=t[i.end];t=yl(e,r).find(e=>{var t=e.descriptor.id,e=e.page.borderBox,a=e[i.size]/4,r=Rl(t,o),t=dc({displaced:n.displaced,id:t});return r?t?d>e[i.start]+a&&de[i.start]-l+a&&ce[i.start]+l+a&&de[i.start]+a&&c{e=e.frame;return e?cc(t,e.scroll.diff.value):t})(r,e),draggable:t,previousImpact:n,destination:r,insideDestination:s,afterCritical:i})||(({pageBorderBoxWithDroppableScroll:e,draggable:t,destination:a,insideDestination:r,last:n,viewport:o,afterCritical:i})=>{const s=a.axis;var l=ec(a.axis,t.displaceBy);const c=l.value,d=e[s.start],u=e[s.end];var p,e=yl(t,r).find(e=>{var t=e.descriptor.id,e=e.page.borderBox.center[s.line],a=Rl(t,i),t=dc({displaced:n,id:t});return a?t?u<=e:de.descriptor.index?p.descriptor.index-1:p.descriptor.index:null);return Ml({draggable:t,insideDestination:r,destination:a,viewport:o,last:n,displacedBy:l,index:m})})({pageBorderBoxWithDroppableScroll:a,draggable:t,destination:r,insideDestination:s,last:n.displaced,viewport:o,afterCritical:i})):El},pc=(e,t)=>({...e,[t.descriptor.id]:t}),mc=({previousImpact:e,impact:t,droppables:a})=>{var r,e=nc(e),t=nc(t);return e&&e!==t&&(t=a[e]).subject.withPlaceholder?((t=(e=t).subject.withPlaceholder)||W(0,"Cannot remove placeholder form subject when there was none"),r=(r=e.frame)?((t=t.oldFrameMaxScroll)||W(0,"Expected droppable with frame to have old max frame scroll when removing placeholder"),r=tc(r,t),t=dl({page:e.subject.page,axis:e.axis,frame:r,withPlaceholder:null}),{...e,subject:t,frame:r}):(t=dl({page:e.subject.page,axis:e.axis,frame:null,withPlaceholder:null}),{...e,subject:t}),pc(a,r)):a},hc=({state:e,clientSelection:t,dimensions:a,viewport:r,impact:n,scrollJumpRequest:o})=>{var i,s,l,c,r=r||e.viewport,a=a||e.dimensions,t=t||e.current.client.selection,d=tl(t,e.initial.client.selection),t={offset:d,selection:t,borderBoxCenter:p(e.initial.client.borderBoxCenter,d)},d={selection:p(t.selection,r.scroll.current),borderBoxCenter:p(t.borderBoxCenter,r.scroll.current),offset:p(t.offset,r.scroll.diff.value)},t={client:t,page:d};return"COLLECTING"===e.phase?{...e,dimensions:a,viewport:r,current:t}:(i=a.draggables[e.critical.draggable.id],n=n||uc({pageOffset:d.offset,draggable:i,draggables:a.draggables,droppables:a.droppables,previousImpact:e.impact,viewport:r,afterCritical:e.afterCritical}),{draggable:d,draggables:i,droppables:s,previousImpact:l,impact:c}=[{draggable:i,impact:n,previousImpact:e.impact,draggables:a.draggables,droppables:a.droppables}][0],l=mc({previousImpact:l,impact:c,droppables:s}),s=!(c=nc(c))||(s=s[c],Sl(d,s))||s.subject.withPlaceholder?l:(c=ac(s,d,i),pc(l,c)),{...e,current:t,dimensions:{draggables:a.draggables,droppables:s},impact:n,viewport:r,scrollJumpRequest:o||null,forceShouldAnimate:!o&&null})};var gc=({impact:e,viewport:t,draggables:a,destination:r,forceShouldAnimate:n})=>{var o=e.displaced;i=o.all,s=a;var i,s,a=Dl({afterDragging:i.map(e=>s[e]),destination:r,displacedBy:e.displacedBy,viewport:t.frame,forceShouldAnimate:n,last:o});return{...e,displaced:a}},fc=({impact:e,draggable:t,droppable:a,draggables:r,viewport:n,afterCritical:o})=>{e=Vl({impact:e,draggable:t,draggables:r,droppable:a,afterCritical:o});return Kl({pageBorderBoxCenter:e,draggable:t,viewport:n})},bc=({state:e,dimensions:t,viewport:a})=>{"SNAP"!==e.movementMode&&W();var r=e.impact,a=a||e.viewport,t=t||e.dimensions,{draggables:n,droppables:o}=t,i=n[e.critical.draggable.id],s=nc(r),o=(s||W(0,"Must be over a destination in SNAP movement mode"),o[s]),s=gc({impact:r,viewport:a,destination:o,draggables:n}),r=fc({impact:s,draggable:i,droppable:o,draggables:n,viewport:a,afterCritical:e.afterCritical});return hc({impact:s,clientSelection:r,state:e,dimensions:t,viewport:a})},vc=({draggable:e,home:t,draggables:a,viewport:r})=>{var n=ec(t.axis,e.displaceBy),a=fl(t.descriptor.id,a),o=a.indexOf(e),a=(-1===o&&W(0,"Expected draggable to be inside home list"),a.slice(o+1)),o=a.reduce((e,t)=>(e[t.descriptor.id]=!0,e),{}),o={inVirtualList:"virtual"===t.descriptor.mode,displacedBy:n,effected:o};return{impact:{displaced:Dl({afterDragging:a,destination:t,displacedBy:n,last:null,viewport:r.frame,forceShouldAnimate:!1}),displacedBy:n,at:{type:"REORDER",destination:{index:(a=e.descriptor).index,droppableId:a.droppableId}}},afterCritical:o}},yc=({additions:e,updatedDroppables:r,viewport:n})=>{const o=n.scroll.diff.value;return e.map(e=>{var t=e.descriptor.droppableId,t=(e=>{e=e.frame;return e||W(0,"Expected Droppable to have a frame"),e})(r[t]).scroll.diff.value,{draggable:e,offset:t,initialWindowScroll:a}=[{draggable:e,offset:p(o,t),initialWindowScroll:n.scroll.initial}][0];return t=Ms(e.client,t),a=xs(t,a),{...e,placeholder:{...e.placeholder,client:t},client:t,page:a}})},Sc=e=>"SNAP"===e.movementMode,wc=(e,t,a)=>{var r={draggables:(r=e.dimensions).draggables,droppables:pc(r.droppables,t)};return(!Sc(e)||a?hc:bc)({state:e,dimensions:r})};function kc(e){return e.isDragging&&"SNAP"===e.movementMode?{...e,scrollJumpRequest:null}:e}var Ec={phase:"IDLE",completed:null,shouldFlush:!1},Cc=(e=Ec,t)=>{if("FLUSH"===t.type)return{...Ec,shouldFlush:!0};if("INITIAL_PUBLISH"===t.type)return"IDLE"!==e.phase&&W(0,"INITIAL_PUBLISH must come after a IDLE phase"),{critical:r,clientSelection:i,viewport:d,dimensions:o,movementMode:n}=t.payload,c=o.draggables[r.draggable.id],l=o.droppables[r.droppable.id],i={client:i={selection:i,borderBoxCenter:c.client.borderBox.center,offset:Y},page:{selection:p(i.selection,d.scroll.initial),borderBoxCenter:p(i.selection,d.scroll.initial),offset:p(i.selection,d.scroll.diff.value)}},s=hl(o.droppables).every(e=>!e.isFixedOnPage),{impact:c,afterCritical:l}=vc({draggable:c,home:l,draggables:o.draggables,viewport:d}),{phase:"DRAGGING",isDragging:!0,critical:r,movementMode:n,dimensions:o,initial:i,current:i,isWindowScrollAllowed:s,impact:c,afterCritical:l,onLiftImpact:c,viewport:d,scrollJumpRequest:null,forceShouldAnimate:null};if("COLLECTION_STARTING"===t.type)return"COLLECTING"===e.phase||"DROP_PENDING"===e.phase?e:("DRAGGING"!==e.phase&&W(0,"Collection cannot start from phase "+e.phase),{...e,phase:"COLLECTING"});if("PUBLISH_WHILE_DRAGGING"===t.type){"COLLECTING"!==e.phase&&"DROP_PENDING"!==e.phase&&W(0,`Unexpected ${t.type} received in phase `+e.phase);{var{state:a,published:r}=[{state:e,published:t.payload}][0],n=r.modified.map(e=>{var t=a.dimensions.droppables[e.droppableId];return ul(t,e.scroll)}),n={...a.dimensions.droppables,...pl(n)},o=ml(yc({additions:r.additions,updatedDroppables:n,viewport:a.viewport}));const u={...a.dimensions.draggables,...o};r.removals.forEach(e=>{delete u[e]});var o={droppables:n,draggables:u},n=(r=nc(a.impact))?o.droppables[r]:null,r=o.draggables[a.critical.draggable.id],i=o.droppables[a.critical.droppable.id],{impact:r,afterCritical:i}=vc({draggable:r,home:i,draggables:u,viewport:a.viewport}),n=n&&n.isCombineEnabled?a.impact:r,n=uc({pageOffset:a.current.page.offset,draggable:o.draggables[a.critical.draggable.id],draggables:o.draggables,droppables:o.droppables,previousImpact:n,viewport:a.viewport,afterCritical:i}),n={...a,phase:"DRAGGING",impact:n,onLiftImpact:r,dimensions:o,afterCritical:i,forceShouldAnimate:!1};return"COLLECTING"===a.phase?n:{...n,phase:"DROP_PENDING",reason:a.reason,isWaiting:!1}}}if("MOVE"===t.type){if("DROP_PENDING"===e.phase)return e;ic(e)||W(0,t.type+" not permitted in phase "+e.phase);var s=t.payload["client"];return al(s,e.current.client.selection)?e:hc({state:e,clientSelection:s,impact:Sc(e)?e.impact:null})}if("UPDATE_DROPPABLE_SCROLL"===t.type){if("DROP_PENDING"===e.phase)return kc(e);if("COLLECTING"===e.phase)return kc(e);ic(e)||W(0,t.type+" not permitted in phase "+e.phase);var{id:l,newScroll:c}=t.payload,d=e.dimensions.droppables[l];return d?(s=ul(d,c),wc(e,s,!1)):e}if("UPDATE_DROPPABLE_IS_ENABLED"===t.type){if("DROP_PENDING"===e.phase)return e;ic(e)||W(0,"Attempting to move in an unsupported phase "+e.phase);var{id:l,isEnabled:d}=t.payload,c=e.dimensions.droppables[l],s=(c||W(0,`Cannot find Droppable[id: ${l}] to toggle its enabled state`),c.isEnabled===d&&W(0,`Trying to set droppable isEnabled to ${String(d)} - but it is already `+String(c.isEnabled)),{...c,isEnabled:d});return wc(e,s,!0)}if("UPDATE_DROPPABLE_IS_COMBINE_ENABLED"===t.type){if("DROP_PENDING"===e.phase)return e;ic(e)||W(0,"Attempting to move in an unsupported phase "+e.phase);var{id:l,isCombineEnabled:c}=t.payload,d=e.dimensions.droppables[l],s=(d||W(0,`Cannot find Droppable[id: ${l}] to toggle its isCombineEnabled state`),d.isCombineEnabled===c&&W(0,`Trying to set droppable isCombineEnabled to ${String(c)} - but it is already `+String(d.isCombineEnabled)),{...d,isCombineEnabled:c});return wc(e,s,!0)}if("MOVE_BY_WINDOW_SCROLL"===t.type){if("DROP_PENDING"===e.phase||"DROP_ANIMATING"===e.phase)return e;ic(e)||W(0,"Cannot move by window in phase "+e.phase),e.isWindowScrollAllowed||W(0,"Window scrolling is currently not supported for fixed lists");l=t.payload.newScroll;return al(e.viewport.scroll.current,l)?kc(e):(d=Hl(e.viewport,l),(Sc(e)?bc:hc)({state:e,viewport:d}))}if("UPDATE_VIEWPORT_MAX_SCROLL"===t.type)return!ic(e)||(c=t.payload.maxScroll,al(c,e.viewport.scroll.max))?e:(s={...e.viewport,scroll:{...e.viewport.scroll,max:c}},{...e,viewport:s});if("MOVE_UP"!==t.type&&"MOVE_DOWN"!==t.type&&"MOVE_LEFT"!==t.type&&"MOVE_RIGHT"!==t.type)return"DROP_PENDING"===t.type?(l=t.payload.reason,"COLLECTING"!==e.phase&&W(0,"Can only move into the DROP_PENDING phase from the COLLECTING phase"),{...e,phase:"DROP_PENDING",isWaiting:!0,reason:l}):"DROP_ANIMATE"===t.type?({completed:d,dropDuration:c,newHomeClientOffset:s}=t.payload,"DRAGGING"!==e.phase&&"DROP_PENDING"!==e.phase&&W(0,"Cannot animate drop from phase "+e.phase),{phase:"DROP_ANIMATING",completed:d,dropDuration:c,newHomeClientOffset:s,dimensions:e.dimensions}):"DROP_COMPLETE"===t.type?(l=t.payload["completed"],{phase:"IDLE",completed:l,shouldFlush:!1}):e;if("COLLECTING"===e.phase||"DROP_PENDING"===e.phase)return e;"DRAGGING"!==e.phase&&W(0,t.type+" received while not in DRAGGING phase");d=oc({state:e,type:t.type});return d?hc({state:e,impact:d.impact,clientSelection:d.clientSelection,scrollJumpRequest:d.scrollJumpRequest}):e};function g(e,t){return e instanceof Object&&"type"in e&&e.type===t}var Ic=e=>({type:"PUBLISH_WHILE_DRAGGING",payload:e}),xc=()=>({type:"COLLECTION_STARTING",payload:null}),Nc=e=>({type:"UPDATE_DROPPABLE_SCROLL",payload:e}),Ac=e=>({type:"UPDATE_DROPPABLE_IS_ENABLED",payload:e}),Tc=e=>({type:"UPDATE_DROPPABLE_IS_COMBINE_ENABLED",payload:e}),Oc=e=>({type:"MOVE",payload:e}),Lc=()=>({type:"MOVE_UP",payload:null}),Dc=()=>({type:"MOVE_DOWN",payload:null}),Pc=()=>({type:"MOVE_RIGHT",payload:null}),Mc=()=>({type:"MOVE_LEFT",payload:null}),Rc=()=>({type:"FLUSH",payload:null}),_c=e=>({type:"DROP_COMPLETE",payload:e}),Bc=e=>({type:"DROP",payload:e}),jc=()=>({type:"DROP_ANIMATION_FINISHED",payload:null});function $c(e,t){e=fl(e.droppable.id,t.draggables);if(!(e.length<=1)){var a=e.map(e=>e.descriptor.index);const n={};for(let e=1;e{return Boolean(n[e])?`[🔥${e}]`:""+e}).join(", "),q(` - Detected non-consecutive indexes. - - (This can cause unexpected bugs) - - ${e} - `))}}var zc=c=>({getState:s,dispatch:l})=>i=>e=>{var t,a,r,n,o;g(e,"LIFT")?({id:n,clientSelection:t,movementMode:a}=e.payload,"DROP_ANIMATING"===(r=s()).phase&&l(_c({completed:r.completed})),"IDLE"!==s().phase&&W(0,"Unexpected phase to start a drag"),l(Rc()),l({type:"BEFORE_INITIAL_CAPTURE",payload:{draggableId:n,movementMode:a}}),{critical:r,dimensions:n,viewport:o}=c.startPublishing({draggableId:n,scrollOptions:{shouldPublishImmediately:"SNAP"===a}}),$c(r,n),l({type:"INITIAL_PUBLISH",payload:{critical:r,dimensions:n,clientSelection:t,movementMode:a,viewport:o}})):i(e)},Uc=a=>()=>t=>e=>{g(e,"INITIAL_PUBLISH")&&a.dragging(),g(e,"DROP_ANIMATE")&&a.dropping(e.payload.completed.result.reason),(g(e,"FLUSH")||g(e,"DROP_COMPLETE"))&&a.resting(),t(e)},Fc={outOfTheWay:"cubic-bezier(0.2, 0, 0, 1)",drop:"cubic-bezier(.2,1,.1,1)"},Gc={opacity:{drop:0,combining:.7},scale:{drop:.75}},Vn={outOfTheWay:.2,minDropTime:.33,maxDropTime:.55},Fn=Vn.outOfTheWay+"s "+Fc.outOfTheWay,Vc={fluid:"opacity "+Fn,snap:`transform ${Fn}, opacity `+Fn,drop:e=>{e=e+"s "+Fc.drop;return`transform ${e}, opacity `+e},outOfTheWay:"transform "+Fn,placeholder:`height ${Fn}, width ${Fn}, margin `+Fn},Hc=e=>al(e,Y)?void 0:`translate(${e.x}px, ${e.y}px)`,qc={moveTo:Hc,drop:(e,t)=>{e=Hc(e);if(e)return t?`${e} scale(${Gc.scale.drop})`:e}},{minDropTime:Wc,maxDropTime:Kc}=Vn,Jc=Kc-Wc,Yc=({getState:m,dispatch:h})=>p=>e=>{var t,a,r,n,o,i,s,l,c,d,u;g(e,"DROP")?(t=m(),a=e.payload.reason,"COLLECTING"===t.phase?h({type:"DROP_PENDING",payload:{reason:a}}):"IDLE"!==t.phase&&("DROP_PENDING"===t.phase&&t.isWaiting&&W(0,"A DROP action occurred while DROP_PENDING and still waiting"),"DRAGGING"!==t.phase&&"DROP_PENDING"!==t.phase&&W(0,"Cannot drop in phase: "+t.phase),d=t.critical,n=(r=t.dimensions).draggables[t.critical.draggable.id],{impact:o,didDropInsideDroppable:c}=({draggables:i,reason:o,lastImpact:c,home:u,viewport:l,onLiftImpact:s}=[{reason:a,lastImpact:t.impact,afterCritical:t.afterCritical,onLiftImpact:t.onLiftImpact,home:t.dimensions.droppables[t.critical.droppable.id],viewport:t.viewport,draggables:t.dimensions.draggables}][0],c.at&&"DROP"===o?"REORDER"===c.at.type?{impact:c,didDropInsideDroppable:!0}:{impact:{...c,displaced:kl},didDropInsideDroppable:!0}:{impact:gc({draggables:i,impact:s,destination:u,viewport:l,forceShouldAnimate:!0}),didDropInsideDroppable:!1}),i=c?bl(o):null,s=c?vl(o):null,u={index:d.draggable.index,droppableId:d.droppable.id},l={draggableId:n.descriptor.id,type:n.descriptor.type,source:u,reason:a,mode:t.movementMode,destination:i,combine:s},c=(({impact:e,draggable:t,dimensions:a,viewport:r,afterCritical:n})=>{var{draggables:a,droppables:o}=a,i=nc(e),i=i?o[i]:null,o=o[t.descriptor.droppableId],e=fc({impact:e,draggable:t,draggables:a,afterCritical:n,droppable:i||o,viewport:r});return tl(e,t.client.borderBox.center)})({impact:o,draggable:n,dimensions:r,viewport:t.viewport,afterCritical:t.afterCritical}),d={critical:t.critical,afterCritical:t.afterCritical,result:l,impact:o},!al(t.current.client.offset,c)||Boolean(l.combine)?(u=(({current:e,destination:t,reason:a})=>{e=ol(e,t);return e<=0?Wc:1500<=e?Kc:(t=Wc+Jc*(e/1500),Number(("CANCEL"===a?.6*t:t).toFixed(2)))})({current:t.current.client.offset,destination:c,reason:a}),h({type:"DROP_ANIMATE",payload:{newHomeClientOffset:c,dropDuration:u,completed:d}})):h(_c({completed:d})))):p(e)},Zc=()=>({x:window.pageXOffset,y:window.pageYOffset});function Xc({onWindowScroll:e}){const t=Rs(function(){e(Zc())}),a=(r=t,{eventName:"scroll",options:{passive:!0,capture:!1},fn:e=>{e.target!==window&&e.target!==window.document||r()}});var r;let n=Gs;function o(){return n!==Gs}return{start:function(){o()&&W(0,"Cannot start scroll listener when already active"),n=Vs(window,[a])},stop:function(){o()||W(0,"Cannot stop scroll listener when not active"),t.cancel(),n(),n=Gs},isActive:o}}var Qc=t=>{const r=Xc({onWindowScroll:e=>{t.dispatch({type:"MOVE_BY_WINDOW_SCROLL",payload:{newScroll:e}})}});return a=>e=>{var t;!r.isActive()&&g(e,"INITIAL_PUBLISH")&&r.start(),r.isActive()&&(g(t=e,"DROP_COMPLETE")||g(t,"DROP_ANIMATE")||g(t,"FLUSH"))&&r.stop(),a(e)}},ed=()=>{const r=[];return{add:e=>{const a=setTimeout(()=>{var t=a,[e]=(-1===(e=r.findIndex(e=>e.timerId===t))&&W(0,"Could not find timer"),r.splice(e,1));e.callback()});e={timerId:a,callback:e};r.push(e)},flush:()=>{var e;r.length&&(e=[...r],r.length=0,e.forEach(e=>{clearTimeout(e.timerId),e.callback()}))}}},td=(e,t)=>{t()},ad=(e,t)=>({draggableId:e.draggable.id,type:e.droppable.type,source:{droppableId:e.droppable.id,index:e.draggable.index},mode:t});function rd(e,t,a,r){e&&(e(t,{announce:e=(t=>{let a=!1,r=!1;const n=setTimeout(()=>{r=!0});var e=e=>{a?q("Announcement already made. Not making a second announcement"):r?q(` - Announcements cannot be made asynchronously. - Default message has already been announced. - `):(a=!0,t(e),clearTimeout(n))};return e.wasCalled=()=>a,e})(a)}),e.wasCalled())||a(r(t))}var nd=(c,d)=>{const u=ed();let p=null;const t=e=>{p||W(0,"Cannot fire onDragEnd when there is no matching onDragStart"),p=null,td(0,()=>rd(c().onDragEnd,e,d,Qs.onDragEnd))};return{beforeCapture:(t,a)=>{p&&W(0,"Cannot fire onBeforeCapture as a drag start has already been published"),td(0,()=>{var e=c().onBeforeCapture;e&&e({draggableId:t,mode:a})})},beforeStart:(t,a)=>{p&&W(0,"Cannot fire onBeforeDragStart as a drag start has already been published"),td(0,()=>{var e=c().onBeforeDragStart;e&&e(ad(t,a))})},start:(e,t)=>{p&&W(0,"Cannot fire onBeforeDragStart as a drag start has already been published");const a=ad(e,t);p={mode:t,lastCritical:e,lastLocation:a.source,lastCombine:null},u.add(()=>{td(0,()=>rd(c().onDragStart,a,d,Qs.onDragStart))})},update:(e,t)=>{var a,r,n=bl(t),t=vl(t),o=(p||W(0,"Cannot fire onDragMove when onDragStart has not been called"),i=e,o=p.lastCritical,!(i===o||(a=i.draggable.id===o.draggable.id&&i.draggable.droppableId===o.draggable.droppableId&&i.draggable.type===o.draggable.type&&i.draggable.index===o.draggable.index,i=i.droppable.id===o.droppable.id&&i.droppable.type===o.droppable.type,a&&i))),i=(o&&(p.lastCritical=e),a=p.lastLocation,i=n,!(null==a&&null==i||null!=a&&null!=i&&a.droppableId===i.droppableId&&a.index===i.index)),s=(i&&(p.lastLocation=n),s=p.lastCombine,r=t,!(null==s&&null==r||null!=s&&null!=r&&s.draggableId===r.draggableId&&s.droppableId===r.droppableId));if(s&&(p.lastCombine=t),o||i||s){const l={...ad(e,p.mode),combine:t,destination:n};u.add(()=>{td(0,()=>rd(c().onDragUpdate,l,d,Qs.onDragUpdate))})}},flush:()=>{p||W(0,"Can only flush responders while dragging"),u.flush()},drop:t,abort:()=>{var e;p&&(e={...ad(p.lastCritical,p.mode),combine:null,destination:null,reason:"CANCEL"},t(e))}}},od=(e,t)=>{const n=nd(e,t);return r=>a=>e=>{var t;g(e,"BEFORE_INITIAL_CAPTURE")?n.beforeCapture(e.payload.draggableId,e.payload.movementMode):g(e,"INITIAL_PUBLISH")?(t=e.payload.critical,n.beforeStart(t,e.payload.movementMode),a(e),n.start(t,e.payload.movementMode)):g(e,"DROP_COMPLETE")?(t=e.payload.completed.result,n.flush(),a(e),n.drop(t)):(a(e),g(e,"FLUSH")?n.abort():"DRAGGING"===(t=r.getState()).phase&&n.update(t.critical,t.impact))}},id=r=>a=>e=>{var t;g(e,"DROP_ANIMATION_FINISHED")?("DROP_ANIMATING"!==(t=r.getState()).phase&&W(0,"Cannot finish a drop animating when no drop is occurring"),r.dispatch(_c({completed:t.completed}))):a(e)},sd=r=>{let n=null,o=null;return a=>e=>{if((g(e,"FLUSH")||g(e,"DROP_COMPLETE")||g(e,"DROP_ANIMATION_FINISHED"))&&(o&&(cancelAnimationFrame(o),o=null),n)&&(n(),n=null),a(e),g(e,"DROP_ANIMATE")){const t={eventName:"scroll",options:{capture:!0,passive:!1,once:!0},fn:function(){"DROP_ANIMATING"===r.getState().phase&&r.dispatch(jc())}};o=requestAnimationFrame(()=>{o=null,n=Vs(window,[t])})}}},ld=a=>()=>t=>e=>{(g(e,"DROP_COMPLETE")||g(e,"FLUSH")||g(e,"DROP_ANIMATE"))&&a.stopPublishing(),t(e)},cd=a=>{let r=!1;return()=>t=>e=>{g(e,"INITIAL_PUBLISH")?(r=!0,a.tryRecordFocus(e.payload.critical.draggable.id),t(e),a.tryRestoreFocusRecorded()):(t(e),r&&(g(e,"FLUSH")?(r=!1,a.tryRestoreFocusRecorded()):g(e,"DROP_COMPLETE")&&(r=!1,(e=e.payload.completed.result).combine&&a.tryShiftRecord(e.draggableId,e.combine.draggableId),a.tryRestoreFocusRecorded())))}},dd=n=>r=>a=>e=>{var t;g(t=e,"DROP_COMPLETE")||g(t,"DROP_ANIMATE")||g(t,"FLUSH")?(n.stop(),a(e)):g(e,"INITIAL_PUBLISH")?(a(e),"DRAGGING"!==(t=r.getState()).phase&&W(0,"Expected phase to be DRAGGING after INITIAL_PUBLISH"),n.start(t)):(a(e),n.scroll(r.getState()))},ud=a=>t=>e=>{t(e),!g(e,"PUBLISH_WHILE_DRAGGING")||"DROP_PENDING"!==(e=a.getState()).phase||e.isWaiting||a.dispatch(Bc({reason:e.reason}))},pd="undefined"!=typeof window&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({name:"@hello-pangea/dnd"}):vi,md=({dimensionMarshal:e,focusMarshal:t,styleMarshal:a,getResponders:r,announce:n,autoScroller:o})=>{return gi(Cc,pd((i=[Uc(a),ld(e),zc(e),Yc,id,sd,ud,dd(o),Qc,cd(t),od(r,n)],n=>(e,t)=>{e=n(e,t);let a=()=>{throw new Error("Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")};const r={getState:e.getState,dispatch:(e,...t)=>a(e,...t)};t=i.map(e=>e(r));return a=vi(...t)(e.dispatch),{...e,dispatch:a}})));var i},hd=()=>({additions:{},removals:{},modified:{}});var gd=({scrollHeight:e,scrollWidth:t,height:a,width:r})=>{t=tl({x:t,y:e},{x:r,y:a});return{x:Math.max(0,t.x),y:Math.max(0,t.y)}},fd=()=>{var e=document.documentElement;return e||W(0,"Cannot find document.documentElement"),e},bd=()=>{var e=fd();return gd({scrollHeight:e.scrollHeight,scrollWidth:e.scrollWidth,width:e.clientWidth,height:e.clientHeight})},vd=({critical:e,scrollOptions:t,registry:a})=>{r=Zc(),n=bd(),l=r.y,o=r.x,c=fd(),s=c.clientWidth,c=c.clientHeight;var r,n,o={frame:Ts({top:l,left:o,right:o+s,bottom:l+c}),scroll:{initial:r,current:r,max:n,diff:{value:Y,displacement:Y}}};const i=o.scroll.current;var s=e.droppable,l=a.droppable.getAllByType(s.type).map(e=>e.callbacks.getDimensionAndWatchScroll(i,t)),c=a.draggable.getAllByType(e.draggable.type).map(e=>e.getDimension(i));return{dimensions:{draggables:ml(c),droppables:pl(l)},critical:e,viewport:o}};function yd(e,t,a){if(a.descriptor.id!==t.id&&a.descriptor.type===t.type){if("virtual"===e.droppable.getById(a.descriptor.droppableId).descriptor.mode)return 1;q(` - You are attempting to add or remove a Draggable [id: ${a.descriptor.id}] - while a drag is occurring. This is only supported for virtual lists. - - See https://github.com/hello-pangea/dnd/blob/main/docs/patterns/virtual-lists.md - `)}}var Sd=(r,a)=>{let n=null;const o=function({registry:r,callbacks:n}){let o=hd(),i=null;const a=()=>{i||(n.collectionStarting(),i=requestAnimationFrame(()=>{i=null;var{additions:e,removals:t,modified:a}=o,e=Object.keys(e).map(e=>r.draggable.getById(e).getDimension(Y)).sort((e,t)=>e.descriptor.index-t.descriptor.index),a=Object.keys(a).map(e=>{return{droppableId:e,scroll:r.droppable.getById(e).callbacks.getScrollWhileDragging()}}),e={additions:e,removals:Object.keys(t),modified:a};o=hd(),n.publish(e)}))};return{add:e=>{var t=e.descriptor.id;o.additions[t]=e,o.modified[e.descriptor.droppableId]=!0,o.removals[t]&&delete o.removals[t],a()},remove:e=>{e=e.descriptor;o.removals[e.id]=!0,o.modified[e.droppableId]=!0,o.additions[e.id]&&delete o.additions[e.id],a()},stop:()=>{i&&(cancelAnimationFrame(i),i=null,o=hd())}}}({callbacks:{publish:a.publishWhileDragging,collectionStarting:a.collectionStarting},registry:r});const i=e=>{n||W(0,"Should only be subscribed when a collection is occurring");var t=n.critical.draggable;"ADDITION"===e.type&&yd(r,t,e.value)&&o.add(e.value),"REMOVAL"===e.type&&yd(r,t,e.value)&&o.remove(e.value)};return{updateDroppableIsEnabled:(e,t)=>{r.droppable.exists(e)||W(0,`Cannot update is enabled flag of Droppable ${e} as it is not registered`),n&&a.updateDroppableIsEnabled({id:e,isEnabled:t})},updateDroppableIsCombineEnabled:(e,t)=>{n&&(r.droppable.exists(e)||W(0,`Cannot update isCombineEnabled flag of Droppable ${e} as it is not registered`),a.updateDroppableIsCombineEnabled({id:e,isCombineEnabled:t}))},scrollDroppable:(e,t)=>{n&&r.droppable.getById(e).callbacks.scroll(t)},updateDroppableScroll:(e,t)=>{n&&(r.droppable.exists(e)||W(0,`Cannot update the scroll on Droppable ${e} as it is not registered`),a.updateDroppableScroll({id:e,newScroll:t}))},startPublishing:e=>{n&&W(0,"Cannot start capturing critical dimensions as there is already a collection");var t=r.draggable.getById(e.draggableId),a=r.droppable.getById(t.descriptor.droppableId),t={draggable:t.descriptor,droppable:a.descriptor},a=r.subscribe(i);return n={critical:t,unsubscribe:a},vd({critical:t,registry:r,scrollOptions:e.scrollOptions})},stopPublishing:()=>{var e;n&&(o.stop(),e=n.critical.droppable,r.droppable.getAllByType(e.type).forEach(e=>e.callbacks.dragStopped()),n.unsubscribe(),n=null)}}},wd=(e,t)=>"IDLE"===e.phase||"DROP_ANIMATING"===e.phase&&e.completed.result.draggableId!==t&&"DROP"===e.completed.result.reason,kd=e=>{window.scrollBy(e.x,e.y)},Ed=Z(e=>hl(e).filter(e=>!!e.isEnabled&&!!e.frame)),Cd=({center:e,destination:t,droppables:a})=>{var r;return t?(t=a[t]).frame?t:null:(r=e,Ed(a).find(e=>(e.frame||W(0,"Invalid result"),sc(e.frame.pageMarginBox)(r)))||null)},Id={startFromPercentage:.25,maxScrollAtPercentage:.05,maxPixelScroll:28,ease:e=>e**2,durationDampening:{stopDampeningAt:1200,accelerateAt:360},disabled:!1},xd=({startOfRange:e,endOfRange:t,current:a})=>{t-=e;return 0==t?(q(` - Detected distance range of 0 in the fluid auto scroller - This is unexpected and would cause a divide by 0 issue. - Not allowing an auto scroll - `),0):(a-e)/t},Nd=({distanceToEdge:e,thresholds:t,dragStartTime:a,shouldUseTimeDampening:r,getAutoScrollerOptions:n})=>{var o,i,e=((e,t,a=()=>Id)=>{a=a();return e>t.startScrollingFrom?0:e<=t.maxScrollValueAt?a.maxPixelScroll:e===t.startScrollingFrom?1:(t=xd({startOfRange:t.maxScrollValueAt,endOfRange:t.startScrollingFrom,current:e}),e=a.maxPixelScroll*a.ease(1-t),Math.ceil(e))})(e,t,n);return 0===e?0:r?Math.max((t=e,r=a,a=(a=n)(),n=a.durationDampening.accelerateAt,o=a.durationDampening.stopDampeningAt,i=o,r=Date.now()-r,o<=r?t:r{e=((e,t,a=()=>Id)=>{a=a();return{startScrollingFrom:e[t.size]*a.startFromPercentage,maxScrollValueAt:e[t.size]*a.maxScrollAtPercentage}})(e,r,o);return t[r.end]0===e?0:e),Od=({dragStartTime:e,container:t,subject:a,center:r,shouldUseTimeDampening:n,getAutoScrollerOptions:o})=>{var r={top:r.y-t.top,right:t.right-r.x,bottom:t.bottom-r.y,left:r.x-t.left},i=Ad({container:t,distanceToEdges:r,dragStartTime:e,axis:Nl,shouldUseTimeDampening:n,getAutoScrollerOptions:o}),r=Ad({container:t,distanceToEdges:r,dragStartTime:e,axis:Al,shouldUseTimeDampening:n,getAutoScrollerOptions:o}),e=Td({x:r,y:i});return al(e,Y)||({container:n,subject:o,proposedScroll:r}={container:t,subject:a,proposedScroll:e},i=o.height>n.height,!(t=(o=o.width>n.width)||i?o&&i?null:{x:o?0:r.x,y:i?0:r.y}:r))||al(t,Y)?null:t},Ld=zn(e=>0===e?0:0{const r=(e,t)=>e<0?e:t{e=p(e,a),a={x:r(e.x,t.x),y:r(e.y,t.y)};return al(a,Y)?null:a}})(),Pd=({max:e,current:t,change:a})=>{e={x:Math.max(t.x,e.x),y:Math.max(t.y,e.y)},a=Ld(a),e=Dd({max:e,current:t,change:a});return!e||0!==a.x&&0===e.x||0!==a.y&&0===e.y},Md=(e,t)=>Pd({current:e.scroll.current,max:e.scroll.max,change:t}),Rd=(e,t)=>{e=e.frame;return!!e&&Pd({current:e.scroll.current,max:e.scroll.max,change:t})},_d=({state:e,dragStartTime:t,shouldUseTimeDampening:a,scrollWindow:r,scrollDroppable:n,getAutoScrollerOptions:o})=>{var i=e.current.page.borderBoxCenter,s=e.dimensions.draggables[e.critical.draggable.id].page.marginBox;if(e.isWindowScrollAllowed){var l=(({viewport:e,subject:t,center:a,dragStartTime:r,shouldUseTimeDampening:n,getAutoScrollerOptions:o})=>{r=Od({dragStartTime:r,container:e.frame,subject:t,center:a,shouldUseTimeDampening:n,getAutoScrollerOptions:o});return r&&Md(e,r)?r:null})({dragStartTime:t,viewport:e.viewport,subject:s,center:i,shouldUseTimeDampening:a,getAutoScrollerOptions:o});if(l)return void r(l)}r=Cd({center:i,destination:nc(e.impact),droppables:e.dimensions.droppables});r&&({droppable:l,subject:e,center:t,dragStartTime:s,shouldUseTimeDampening:i,getAutoScrollerOptions:a}=[{dragStartTime:t,droppable:r,subject:s,center:i,shouldUseTimeDampening:a,getAutoScrollerOptions:o}][0],o=(o=l.frame)&&(s=Od({dragStartTime:s,container:o.pageMarginBox,subject:e,center:t,shouldUseTimeDampening:i,getAutoScrollerOptions:a}))&&Rd(l,s)?s:null)&&n(r.descriptor.id,o)},Bd=({scrollWindow:e,scrollDroppable:t,getAutoScrollerOptions:n=()=>Id})=>{const r=Rs(e),o=Rs(t);let i=null;const s=e=>{i||W(0,"Cannot fluid scroll if not dragging");var{shouldUseTimeDampening:t,dragStartTime:a}=i;_d({state:e,scrollWindow:r,scrollDroppable:o,dragStartTime:a,shouldUseTimeDampening:t,getAutoScrollerOptions:n})};return{start:e=>{i&&W(0,"Cannot start auto scrolling when already started");var t=Date.now();let a=!1;var r=()=>{a=!0};_d({state:e,dragStartTime:0,shouldUseTimeDampening:!1,scrollWindow:r,scrollDroppable:r,getAutoScrollerOptions:n}),i={dragStartTime:t,shouldUseTimeDampening:a},a&&s(e)},stop:()=>{i&&(r.cancel(),o.cancel(),i=null)},scroll:s}},jd=({move:r,scrollDroppable:o,scrollWindow:n})=>{const i=(e,t)=>{var a,r,n;return Rd(e,t)?(r=t,(a=(n=(a=e).frame)&&Rd(a,r)?Dd({current:n.scroll.current,max:n.scroll.max,change:r}):null)?(n=tl(t,a),o(e.descriptor.id,n),tl(t,n)):(o(e.descriptor.id,t),null)):t},s=(e,t,a)=>{var r;return e&&Md(t,a)?(e=Md(e=t,t=a)?(r=e.scroll.max,e=e.scroll.current,Dd({current:e,max:r,change:t})):null)?(r=tl(a,e),n(r),tl(a,r)):(n(a),null):a};return e=>{var t,a=e.scrollJumpRequest;a&&((t=nc(e.impact))||W(0,"Cannot perform a jump scroll when there is no destination"),t=i(e.dimensions.droppables[t],a))&&(a=e.viewport,a=s(e.isWindowScrollAllowed,a,t))&&(t=p((t=e).current.client.selection,a),r({client:t}))}},$d=({scrollDroppable:e,scrollWindow:t,move:a,getAutoScrollerOptions:r})=>{const n=Bd({scrollWindow:t,scrollDroppable:e,getAutoScrollerOptions:r}),o=jd({move:a,scrollWindow:t,scrollDroppable:e});return{scroll:e=>{r().disabled||"DRAGGING"!==e.phase||("FLUID"===e.movementMode?n.scroll(e):e.scrollJumpRequest&&o(e))},start:n.start,stop:n.stop}},zd="data-rfd",Ud={base:Hn=zd+"-drag-handle",draggableId:Hn+"-draggable-id",contextId:Hn+"-context-id"},Fd={base:l=zd+"-draggable",contextId:l+"-context-id",id:l+"-id"},Gd={base:Un=zd+"-droppable",contextId:Un+"-context-id",id:Un+"-id"},Vd={contextId:zd+"-scroll-container-context-id"},Hd=t=>e=>`[${e}="${t}"]`,qd=(e,a)=>e.map(e=>{var t=e.styles[a];return t?e.selector+` { ${t} }`:""}).join(" "),Wd="pointer-events: none;",Kd="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?H.useLayoutEffect:H.useEffect,Jd=()=>{var e=document.querySelector("head");return e||W(0,"Cannot find the head to append a style to"),e},Yd=e=>{var t=document.createElement("style");return e&&t.setAttribute("nonce",e),t.type="text/css",t};function Zd(r,a){const n=K(()=>{{var e=r;const a=Hd(e);e=` - cursor: -webkit-grab; - cursor: grab; - `,e={selector:a(Ud.contextId),styles:{always:` - -webkit-touch-callout: none; - -webkit-tap-highlight-color: rgba(0,0,0,0); - touch-action: manipulation; - `,resting:e,dragging:Wd,dropAnimating:e}},t=` - transition: ${Vc.outOfTheWay}; - `;var t=[{selector:a(Fd.contextId),styles:{dragging:t,dropAnimating:t,userCancel:t}},e,{selector:a(Gd.contextId),styles:{always:"overflow-anchor: none;"}},{selector:"body",styles:{dragging:` - cursor: grabbing; - cursor: -webkit-grabbing; - user-select: none; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - overflow-anchor: none; - `}}];return{always:qd(t,"always"),resting:qd(t,"resting"),dragging:qd(t,"dragging"),dropAnimating:qd(t,"dropAnimating"),userCancel:qd(t,"userCancel")}}},[r]),o=(0,H.useRef)(null),i=(0,H.useRef)(null),s=J(Z(e=>{var t=i.current;t||W(0,"Cannot set dynamic style element if it is not set"),t.textContent=e}),[]),l=J(e=>{var t=o.current;t||W(0,"Cannot set dynamic style element if it is not set"),t.textContent=e},[]),e=(Kd(()=>{(o.current||i.current)&&W(0,"style elements already mounted");var e=Yd(a),t=Yd(a);return o.current=e,i.current=t,e.setAttribute(zd+"-always",r),t.setAttribute(zd+"-dynamic",r),Jd().appendChild(e),Jd().appendChild(t),l(n.always),s(n.resting),()=>{var e=e=>{var t=e.current;t||W(0,"Cannot unmount ref as it is not set"),Jd().removeChild(t),e.current=null};e(o),e(i)}},[a,l,s,n.always,n.resting,r]),J(()=>s(n.dragging),[s,n.dragging])),t=J(e=>{"DROP"===e?s(n.dropAnimating):s(n.userCancel)},[s,n.dropAnimating,n.userCancel]),c=J(()=>{i.current&&s(n.resting)},[s,n.resting]);return K(()=>({dragging:e,dropping:t,resting:c}),[e,t,c])}function Xd(e,t){return Array.from(e.querySelectorAll(t))}var Qd=e=>e&&e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView:window;function eu(e){return e instanceof Qd(e).HTMLElement}function tu(e,t){var a=`[${Ud.contextId}="${e}"]`,a=Xd(document,a);return a.length?(a=a.find(e=>e.getAttribute(Ud.draggableId)===t))?eu(a)?a:(q("drag handle needs to be a HTMLElement"),null):(q(`Unable to find drag handle with id "${t}" as no handle with a matching id was found`),null):(q(`Unable to find any drag handles in the context "${e}"`),null)}function au(){const r={draggables:{},droppables:{}},a=[];function n(t){a.length&&a.forEach(e=>e(t))}function o(e){return r.draggables[e]||null}function i(e){return r.droppables[e]||null}return{draggable:{register:e=>{n({type:"ADDITION",value:r.draggables[e.descriptor.id]=e})},update:(e,t)=>{var a=r.draggables[t.descriptor.id];a&&a.uniqueId===e.uniqueId&&(delete r.draggables[t.descriptor.id],r.draggables[e.descriptor.id]=e)},unregister:e=>{var t=e.descriptor.id,a=o(t);a&&e.uniqueId===a.uniqueId&&(delete r.draggables[t],r.droppables[e.descriptor.droppableId])&&n({type:"REMOVAL",value:e})},getById:function(e){var t=o(e);return t||W(0,`Cannot find draggable entry with id [${e}]`),t},findById:o,exists:e=>Boolean(o(e)),getAllByType:t=>Object.values(r.draggables).filter(e=>e.descriptor.type===t)},droppable:{register:e=>{r.droppables[e.descriptor.id]=e},unregister:e=>{var t=i(e.descriptor.id);t&&e.uniqueId===t.uniqueId&&delete r.droppables[e.descriptor.id]},getById:function(e){var t=i(e);return t||W(0,`Cannot find droppable entry with id [${e}]`),t},findById:i,exists:e=>Boolean(i(e)),getAllByType:t=>Object.values(r.droppables).filter(e=>e.descriptor.type===t)},subscribe:function(t){return a.push(t),function(){var e=a.indexOf(t);-1!==e&&a.splice(e,1)}},clean:function(){r.draggables={},r.droppables={},a.length=0}}}var ru=H.default.createContext(null),nu=()=>{var e=document.body;return e||W(0,"Cannot find document.body"),e},ou={position:"absolute",width:"1px",height:"1px",margin:"-1px",border:"0",padding:"0",overflow:"hidden",clip:"rect(0 0 0 0)","clip-path":"inset(100%)"};var iu={separator:"::"};function su(e,t=iu){const a=H.default.useId();return K(()=>""+e+t.separator+a,[t.separator,e,a])}function lu({contextId:a,text:e}){const r=su("hidden-text",{separator:"-"}),n=K(()=>{return{contextId:e,uniqueId:t}=[{contextId:a,uniqueId:r}][0],`rfd-hidden-text-${e}-`+t;var e,t},[r,a]);return(0,H.useEffect)(function(){const t=document.createElement("div");return t.id=n,t.textContent=e,t.style.display="none",nu().appendChild(t),function(){var e=nu();e.contains(t)&&e.removeChild(t)}},[n,e]),n}var cu=H.default.createContext(null),du="^18.0.0 || ^19.0.0",uu=/(\d+)\.(\d+)\.(\d+)/,pu=e=>{var t=uu.exec(e),a=(null==t&&W(0,"Unable to parse React version "+e),Number(t[1]));return{major:a,minor:Number(t[2]),patch:Number(t[3]),raw:e}},mu=(e,t)=>t.major>e.major||!(t.majore.minor||!(t.minor=e.patch),hu=` - We expect a html5 doctype: - This is to ensure consistent browser layout and measurement - - More information: https://github.com/hello-pangea/dnd/blob/main/docs/guides/doctype.md -`;function gu(e){e()}function fu(e,t){gu(()=>{(0,H.useEffect)(()=>{try{e()}catch(e){Fs(` - A setup problem was encountered. - - > ${e.message} - `)}},t)})}function bu(){fu(()=>{var e=du,t=H.default.version,t=(e=pu(e),t=pu(t),mu(e,t)||q(` - React version: [${t.raw}] - does not satisfy expected peer dependency version: [${e.raw}] - - This can result in run time bugs, and even fatal crashes - `),document);(t=t.doctype)?("html"!==t.name.toLowerCase()&&q(` - Unexpected found: (${t.name}) - - ${hu} - `),""!==t.publicId&&q(` - Unexpected publicId found: (${t.publicId}) - A html5 doctype does not have a publicId - - ${hu} - `)):q(` - No found. - - ${hu} - `)},[])}function vu(e){const t=(0,H.useRef)(e);return(0,H.useEffect)(()=>{t.current=e}),t}function yu(){let t=null;function e(){t||W(0,"Cannot release lock when there is no lock"),t=null}return{isClaimed:function(){return Boolean(t)},isActive:function(e){return e===t},claim:function(e){return t&&W(0,"Cannot claim lock as it is already claimed"),e={abandon:e},t=e},release:e,tryAbandon:function(){t&&(t.abandon(),e())}}}function Su(e){return"IDLE"!==e.phase&&"DROP_ANIMATING"!==e.phase&&e.isDragging}var wu=27,ku=32,Eu=37,Cu=38,Iu=39,xu=40,Nu={[13]:!0,9:!0},Au=e=>{Nu[e.keyCode]&&e.preventDefault()},Tu=(r="visibilitychange","undefined"!=typeof document&&[r,"ms"+r,"webkit"+r,"moz"+r,"o"+r].find(e=>"on"+e in document)||r),Ou=0,Lu=5;var Du={type:"IDLE"};function Pu({cancel:a,completed:r,getPhase:o,setPhase:i}){return[{eventName:"mousemove",fn:e=>{var t,{button:a,clientX:r,clientY:n}=e;a===Ou&&(a={x:r,y:n},"DRAGGING"===(r=o()).type?(e.preventDefault(),r.actions.move(a)):("PENDING"!==r.type&&W(0,"Cannot be IDLE"),n=r.point,n=n,t=a,(Math.abs(t.x-n.x)>=Lu||Math.abs(t.y-n.y)>=Lu)&&(e.preventDefault(),t=r.actions.fluidLift(a),i({type:"DRAGGING",actions:t}))))}},{eventName:"mouseup",fn:e=>{var t=o();("DRAGGING"!==t.type?a:(e.preventDefault(),t.actions.drop({shouldBlockNextClick:!0}),r))()}},{eventName:"mousedown",fn:e=>{"DRAGGING"===o().type&&e.preventDefault(),a()}},{eventName:"keydown",fn:e=>{"PENDING"===o().type?a():e.keyCode===wu?(e.preventDefault(),a()):Au(e)}},{eventName:"resize",fn:a},{eventName:"scroll",options:{passive:!0,capture:!1},fn:()=>{"PENDING"===o().type&&a()}},{eventName:"webkitmouseforcedown",fn:e=>{var t=o();"IDLE"===t.type&&W(0,"Unexpected phase"),t.actions.shouldRespectForcePress()?a():e.preventDefault()}},{eventName:Tu,fn:a}]}function Mu(){}var Ru={[34]:!0,33:!0,36:!0,35:!0};function _u(t,a){function r(){a(),t.cancel()}return[{eventName:"keydown",fn:e=>{e.keyCode===wu?(e.preventDefault(),r()):e.keyCode===ku?(e.preventDefault(),a(),t.drop()):e.keyCode===xu?(e.preventDefault(),t.moveDown()):e.keyCode===Cu?(e.preventDefault(),t.moveUp()):e.keyCode===Iu?(e.preventDefault(),t.moveRight()):e.keyCode===Eu?(e.preventDefault(),t.moveLeft()):Ru[e.keyCode]?e.preventDefault():Au(e)}},{eventName:"mousedown",fn:r},{eventName:"mouseup",fn:r},{eventName:"click",fn:r},{eventName:"touchstart",fn:r},{eventName:"resize",fn:r},{eventName:"wheel",fn:r,options:{passive:!0}},{eventName:Tu,fn:r}]}var Bu={type:"IDLE"},ju=.15;var $u=["input","button","textarea","select","option","optgroup","video","audio"];function zu(e,t){t=t.target;return eu(t)&&function e(t,a){var r;return null!=a&&(!!$u.includes(a.tagName.toLowerCase())||"true"===(r=a.getAttribute("contenteditable"))||""===r||a!==t&&e(t,a.parentElement))}(e,t)}xn="matches";var Uu="undefined"!=typeof document&&[xn,"msMatchesSelector","webkitMatchesSelector"].find(e=>e in Element.prototype)||xn;function Fu(e,t){return e.closest?e.closest(t):function e(t,a){return null==t?null:t[Uu](a)?t:e(t.parentElement,a)}(e,t)}function Gu(e,t){var t=t.target;return t instanceof Qd(t).Element?(e=`[${Ud.contextId}="${e}"]`,(t=Fu(t,e))?eu(t)?t:(q("drag handle must be a HTMLElement"),null):null):(q("event.target must be a Element"),null)}function Vu(e){e.preventDefault()}function Hu({expected:e,phase:t,isLockActive:a,shouldWarn:r}){return a()?e===t||(r&&q(` - Cannot perform action. - The actions you used belong to an outdated phase - - Current phase: ${e} - You called an action from outdated phase: ${t} - - Tips: - - - Do not use preDragActions actions after calling preDragActions.lift() - `),!1):(r&&q(` - Cannot perform action. - The sensor no longer has an action lock. - - Tips: - - - Throw away your action handlers when forceStop() is called - - Check actions.isActive() if you really need to - `),!1)}function qu({lockAPI:e,store:t,registry:a,draggableId:r}){return!(e.isClaimed()||((e=a.draggable.findById(r))?!e.options.isEnabled||!wd(t.getState(),r):(q("Unable to find draggable with id: "+r),1)))}function Wu({lockAPI:e,contextId:t,store:n,registry:a,draggableId:r,forceSensorStop:o,sourceEvent:i}){var s;if(!qu({lockAPI:e,store:n,registry:a,draggableId:r}))return null;const l=a.draggable.getById(r),c=(a=t,s=l.descriptor.id,a=`[${Fd.contextId}="${a}"]`,(a=Xd(document,a).find(e=>e.getAttribute(Fd.id)===s))?eu(a)?a:(q("Draggable element is not a HTMLElement"),null):null);if(!c)return q("Unable to find draggable element with id: "+r),null;if(i&&!l.options.canDragInteractiveElements&&zu(c,i))return null;const d=e.claim(o||Gs);let u="PRE_DRAG";function p(){return l.options.shouldRespectForcePress}function m(){return e.isActive(d)}const h=function(e,t){Hu({expected:e,phase:u,isLockActive:m,shouldWarn:!0})&&n.dispatch(t())}.bind(null,"DRAGGING");function g(a){function r(){e.release(),u="COMPLETED"}function t(e,t={shouldBlockNextClick:!1}){a.cleanup(),t.shouldBlockNextClick&&(t=Vs(window,[{eventName:"click",fn:Vu,options:{once:!0,passive:!1,capture:!0}}]),setTimeout(t)),r(),n.dispatch(Bc({reason:e}))}return"PRE_DRAG"!==u&&(r(),W(0,"Cannot lift in phase "+u)),n.dispatch({type:"LIFT",payload:a.liftActionArgs}),u="DRAGGING",{isActive:()=>Hu({expected:"DRAGGING",phase:u,isLockActive:m,shouldWarn:!1}),shouldRespectForcePress:p,drop:e=>t("DROP",e),cancel:e=>t("CANCEL",e),...a.actions}}return{isActive:()=>Hu({expected:"PRE_DRAG",phase:u,isLockActive:m,shouldWarn:!1}),shouldRespectForcePress:p,fluidLift:function(e){const t=Rs(e=>{h(()=>Oc({client:e}))});return{...g({liftActionArgs:{id:r,clientSelection:e,movementMode:"FLUID"},cleanup:()=>t.cancel(),actions:{move:t}}),move:t}},snapLift:function(){var e,t={moveUp:()=>h(Lc),moveRight:()=>h(Pc),moveDown:()=>h(Dc),moveLeft:()=>h(Mc)};return g({liftActionArgs:{id:r,clientSelection:(e=c,Ts(e.getBoundingClientRect()).center),movementMode:"SNAP"},cleanup:Gs,actions:t})},abort:function(){Hu({expected:"PRE_DRAG",phase:u,isLockActive:m,shouldWarn:!0})&&e.release()}}}var Ku=[function(r){const a=(0,H.useRef)(Du),n=(0,H.useRef)(Gs),e=K(()=>({eventName:"mousedown",fn:function(e){var t;e.defaultPrevented||e.button!==Ou||e.ctrlKey||e.metaKey||e.shiftKey||e.altKey||(t=r.findClosestDraggableId(e))&&(t=r.tryGetLock(t,i,{sourceEvent:e}))&&(e.preventDefault(),e={x:e.clientX,y:e.clientY},n.current(),c(t,e))}}),[r]),t=K(()=>({eventName:"webkitmouseforcewillbegin",fn:e=>{var t,a;e.defaultPrevented||(t=r.findClosestDraggableId(e))&&(a=r.findOptionsForDraggable(t))&&!a.shouldRespectForcePress&&r.canGetLock(t)&&e.preventDefault()}}),[r]),o=J(function(){n.current=Vs(window,[t,e],{passive:!1,capture:!0})},[t,e]),i=J(()=>{"IDLE"!==a.current.type&&(a.current=Du,n.current(),o())},[o]),s=J(()=>{var e=a.current;i(),"DRAGGING"===e.type&&e.actions.cancel({shouldBlockNextClick:!0}),"PENDING"===e.type&&e.actions.abort()},[i]),l=J(function(){var e=Pu({cancel:s,completed:i,getPhase:()=>a.current,setPhase:e=>{a.current=e}});n.current=Vs(window,e,{capture:!0,passive:!1})},[s,i]),c=J(function(e,t){"IDLE"!==a.current.type&&W(0,"Expected to move from IDLE to PENDING drag"),a.current={type:"PENDING",point:t,actions:e},l()},[l]);Kd(function(){return o(),function(){n.current()}},[o])},function(e){const n=(0,H.useRef)(Mu),t=K(()=>({eventName:"keydown",fn:function(t){if(!t.defaultPrevented&&t.keyCode===ku){var a=e.findClosestDraggableId(t);if(a){a=e.tryGetLock(a,r,{sourceEvent:t});if(a){t.preventDefault();let e=!0;t=a.snapLift();function r(){e||W(0,"Cannot stop capturing a keyboard drag when not capturing"),e=!1,n.current(),o()}n.current(),n.current=Vs(window,_u(t,r),{capture:!0,passive:!1})}}}}}),[e]),o=J(function(){n.current=Vs(window,[t],{passive:!1,capture:!0})},[t]);Kd(function(){return o(),function(){n.current()}},[o])},function(r){const t=(0,H.useRef)(Bu),c=(0,H.useRef)(Gs),d=J(function(){return t.current},[]),n=J(function(e){t.current=e},[]),e=K(()=>({eventName:"touchstart",fn:function(e){var t,a;e.defaultPrevented||(t=r.findClosestDraggableId(e))&&(t=r.tryGetLock(t,u,{sourceEvent:e}))&&({clientX:e,clientY:a}=e.touches[0],e={x:e,y:a},c.current(),s(t,e))}}),[r]),a=J(function(){c.current=Vs(window,[e],{capture:!0,passive:!1})},[e]),u=J(()=>{var e=t.current;"IDLE"!==e.type&&("PENDING"===e.type&&clearTimeout(e.longPressTimerId),n(Bu),c.current(),a())},[a,n]),p=J(()=>{var e=t.current;u(),"DRAGGING"===e.type&&e.actions.cancel({shouldBlockNextClick:!0}),"PENDING"===e.type&&e.actions.abort()},[u]),o=J(function(){var n,a,o,t,r,e={capture:!0,passive:!1},i={cancel:p,completed:u,getPhase:d};const s=Vs(window,({cancel:n,completed:a,getPhase:o}=[i][0],[{eventName:"touchmove",options:{capture:!1},fn:e=>{var t,a,r=o();"DRAGGING"!==r.type?n():(r.hasMoved=!0,{clientX:a,clientY:t}=e.touches[0],a={x:a,y:t},e.preventDefault(),r.actions.move(a))}},{eventName:"touchend",fn:e=>{var t=o();("DRAGGING"!==t.type?n:(e.preventDefault(),t.actions.drop({shouldBlockNextClick:!0}),a))()}},{eventName:"touchcancel",fn:e=>{"DRAGGING"!==o().type||e.preventDefault(),n()}},{eventName:"touchforcechange",fn:e=>{var t=o(),a=("IDLE"===t.type&&W(),e.touches[0]);if(a&&a.force>=ju){a=t.actions.shouldRespectForcePress();if("PENDING"!==t.type)return!a||t.hasMoved?void e.preventDefault():void n();a&&n()}}},{eventName:Tu,fn:n}]),e),l=Vs(window,({cancel:t,getPhase:r}=[i][0],[{eventName:"orientationchange",fn:t},{eventName:"resize",fn:t},{eventName:"contextmenu",fn:e=>{e.preventDefault()}},{eventName:"keydown",fn:e=>{"DRAGGING"!==r().type||e.keyCode===wu&&e.preventDefault(),t()}},{eventName:Tu,fn:t}]),e);c.current=function(){s(),l()}},[p,d,u]),i=J(function(){var e=d(),e=("PENDING"!==e.type&&W(0,"Cannot start dragging from phase "+e.type),e.actions.fluidLift(e.point));n({type:"DRAGGING",actions:e,hasMoved:!1})},[d,n]),s=J(function(e,t){"IDLE"!==d().type&&W(0,"Expected to move from IDLE to PENDING drag");var a=setTimeout(i,120);n({type:"PENDING",point:t,actions:e,longPressTimerId:a}),o()},[o,d,n,i]);Kd(function(){return a(),function(){c.current();var e=d();"PENDING"===e.type&&(clearTimeout(e.longPressTimerId),n(Bu))}},[d,a,n]),Kd(function(){return Vs(window,[{eventName:"touchmove",fn:()=>{},options:{capture:!1,passive:!1}}])},[])}];function Ju({contextId:r,store:n,registry:o,customSensors:e,enableDefaultSensors:t}){var a=[...t?Ku:[],...e||[]];const i=(0,H.useState)(()=>yu())[0],s=J(function(e,t){Su(e)&&!Su(t)&&i.tryAbandon()},[i]),l=(Kd(function(){let t=n.getState();return n.subscribe(()=>{var e=n.getState();s(t,e),t=e})},[i,n,s]),Kd(()=>i.tryAbandon,[i.tryAbandon]),J(e=>qu({lockAPI:i,registry:o,store:n,draggableId:e}),[i,o,n])),c=J((e,t,a)=>Wu({lockAPI:i,registry:o,contextId:r,store:n,draggableId:e,forceSensorStop:t||null,sourceEvent:a&&a.sourceEvent?a.sourceEvent:null}),[r,i,o,n]),d=J(e=>{return(t=Gu(t=r,e))?t.getAttribute(Ud.draggableId):null;var t},[r]),u=J(e=>{e=o.draggable.findById(e);return e?e.options:null},[o.draggable]),p=J(function(){i.isClaimed()&&(i.tryAbandon(),"IDLE"!==n.getState().phase)&&n.dispatch(Rc())},[i,n]),m=J(()=>i.isClaimed(),[i]);var h,g=K(()=>({canGetLock:l,tryGetLock:c,findClosestDraggableId:d,findOptionsForDraggable:u,tryReleaseLock:p,isLockClaimed:m}),[l,c,d,u,p,m]);h=a,gu(()=>{const e=vu(h);fu(()=>{e.current.length!==h.length&&W(0,"Cannot change the amount of sensor hooks after mounting")})});for(let e=0;e({onBeforeCapture:e=>{(0,ci.flushSync)(()=>{t.onBeforeCapture&&t.onBeforeCapture(e)})},onBeforeDragStart:t.onBeforeDragStart,onDragStart:t.onDragStart,onDragEnd:t.onDragEnd,onDragUpdate:t.onDragUpdate}),Zu=e=>({...Id,...e.autoScrollerOptions,durationDampening:{...Id.durationDampening,...e.autoScrollerOptions}});function Xu(e){return e.current||W(0,"Could not find store from lazy ref"),e.current}function Qu(e){const{contextId:t,setCallbacks:a,sensors:r,nonce:n,dragHandleUsageInstructions:o}=e,i=(0,H.useRef)(null),s=(bu(),vu(e)),l=J(()=>Yu(s.current),[s]),c=J(()=>Zu(s.current),[s]),d=function(e){const a=K(()=>"rfd-announcement-"+e,[e]),r=(0,H.useRef)(null);return(0,H.useEffect)(function(){const t=document.createElement("div");return(r.current=t).id=a,t.setAttribute("aria-live","assertive"),t.setAttribute("aria-atomic","true"),_s(t.style,ou),nu().appendChild(t),function(){setTimeout(function(){var e=nu();e.contains(t)&&e.removeChild(t),t===r.current&&(r.current=null)})}},[a]),J(e=>{var t=r.current;t?t.textContent=e:q(` - A screen reader message was trying to be announced but it was unable to do so. - This can occur if you unmount your in your onDragEnd. - Consider calling provided.announce() before the unmount so that the instruction will - not be lost for users relying on a screen reader. - - Message not passed to screen reader: - - "${e}" - `)},[])}(t),u=lu({contextId:t,text:o}),p=Zd(t,n),m=J(e=>{Xu(i).dispatch(e)},[]),h=K(()=>bi({publishWhileDragging:Ic,updateDroppableScroll:Nc,updateDroppableIsEnabled:Ac,updateDroppableIsCombineEnabled:Tc,collectionStarting:xc},m),[m]),g=function(){const e=K(au,[]);return(0,H.useEffect)(()=>function(){e.clean()},[e]),e}(),f=K(()=>Sd(g,h),[g,h]),b=K(()=>$d({scrollWindow:kd,scrollDroppable:f.scrollDroppable,getAutoScrollerOptions:c,...bi({move:Oc},m)}),[f.scrollDroppable,m,c]),v=function(t){const r=(0,H.useRef)({}),a=(0,H.useRef)(null),n=(0,H.useRef)(null),o=(0,H.useRef)(!1),e=J(function(t,e){const a={id:t,focus:e};return r.current[t]=a,function(){var e=r.current;e[t]!==a&&delete e[t]}},[]),i=J(function(e){e=tu(t,e);e&&e!==document.activeElement&&e.focus()},[t]),s=J(function(e,t){a.current===e&&(a.current=t)},[]),l=J(function(){n.current||o.current&&(n.current=requestAnimationFrame(()=>{n.current=null;var e=a.current;e&&i(e)}))},[i]),c=J(function(e){a.current=null;var t=document.activeElement;t&&t.getAttribute(Ud.draggableId)===e&&(a.current=e)},[]);return Kd(()=>(o.current=!0,function(){o.current=!1;var e=n.current;e&&cancelAnimationFrame(e)}),[]),K(()=>({register:e,tryRecordFocus:c,tryRestoreFocusRecorded:l,tryShiftRecord:s}),[e,c,l,s])}(t);var y=K(()=>md({announce:d,autoScroller:b,dimensionMarshal:f,focusMarshal:v,getResponders:l,styleMarshal:p}),[d,b,f,v,l,p]);i.current&&i.current!==y&&q("unexpected store change"),i.current=y;const S=J(()=>{var e=Xu(i);"IDLE"!==e.getState().phase&&e.dispatch(Rc())},[]),w=J(()=>{var e=Xu(i).getState();return"DROP_ANIMATING"===e.phase||"IDLE"!==e.phase&&e.isDragging},[]);var k=K(()=>({isDragging:w,tryAbort:S}),[w,S]);a(k);const E=J(e=>wd(Xu(i).getState(),e),[]),C=J(()=>ic(Xu(i).getState()),[]);k=K(()=>({marshal:f,focus:v,contextId:t,canLift:E,isMovementAllowed:C,dragHandleUsageInstructionsId:u,registry:g}),[t,f,u,v,E,C,g]);return Ju({contextId:t,store:y,registry:g,customSensors:r||null,enableDefaultSensors:!1!==e.enableDefaultSensors}),(0,H.useEffect)(()=>S,[S]),H.default.createElement(cu.Provider,{value:k},H.default.createElement(ws,{context:ru,store:y},e.children))}function ep(t){const a=H.default.useId(),r=t.dragHandleUsageInstructions||Qs.dragHandleUsageInstructions;return H.default.createElement(Ks,null,e=>H.default.createElement(Qu,{nonce:t.nonce,contextId:a,setCallbacks:e,dragHandleUsageInstructions:r,enableDefaultSensors:t.enableDefaultSensors,sensors:t.sensors,onBeforeCapture:t.onBeforeCapture,onBeforeDragStart:t.onBeforeDragStart,onDragStart:t.onDragStart,onDragUpdate:t.onDragUpdate,onDragEnd:t.onDragEnd,autoScrollerOptions:t.autoScrollerOptions},t.children))}var tp={dragging:5e3,dropAnimating:4500},ap=(e,t)=>t?Vc.drop(t.duration):e?Vc.snap:Vc.fluid,rp=(e,t)=>{if(e)return t?Gc.opacity.drop:Gc.opacity.combining},np=e=>null!=e.forceShouldAnimate?e.forceShouldAnimate:"SNAP"===e.mode;function op(e){var t,a,r,n,o,i;return"DRAGGING"===e.type?(i=(r=e).dimension.client,{offset:o,combineWith:a,dropping:t}=r,a=Boolean(a),r=np(r),n=Boolean(t),o=n?qc.drop(o,a):qc.moveTo(o),{position:"fixed",top:i.marginBox.top,left:i.marginBox.left,boxSizing:"border-box",width:i.borderBox.width,height:i.borderBox.height,transition:ap(r,t),transform:o,opacity:rp(a,n),zIndex:n?tp.dropAnimating:tp.dragging,pointerEvents:"none"}):(i=e,{transform:qc.moveTo(i.offset),transition:i.shouldAnimateDisplacement?void 0:"none"})}function ip(e){const t=su("draggable"),{descriptor:o,registry:a,getDraggableRef:i,canDragInteractiveElements:r,shouldRespectForcePress:n,isEnabled:s}=e,l=K(()=>({canDragInteractiveElements:r,shouldRespectForcePress:n,isEnabled:s}),[r,s,n]),c=J(e=>{var t,a,r,n=i();return n||W(0,"Cannot get dimension when no ref is set"),[n,e,t=Y]=[o,n,e],a=window.getComputedStyle(e),r=e.getBoundingClientRect(),r=Ns(r,a),t=xs(r,t),{descriptor:n,placeholder:{client:r,tagName:e.tagName.toLowerCase(),display:a.display},displaceBy:{x:r.marginBox.width,y:r.marginBox.height},client:r,page:t}},[o,i]),d=K(()=>({uniqueId:t,descriptor:o,options:l,getDimension:c}),[o,c,l,t]),u=(0,H.useRef)(d),p=(0,H.useRef)(!0);Kd(()=>(a.draggable.register(u.current),()=>a.draggable.unregister(u.current)),[a.draggable]),Kd(()=>{var e;p.current?p.current=!1:(e=u.current,u.current=d,a.draggable.update(d,e))},[d,a.draggable])}var sp=H.default.createContext(null);function lp(e){e&&eu(e)||W(0,` - provided.innerRef has not been provided with a HTMLElement. - - You can find a guide on using the innerRef callback functions at: - https://github.com/hello-pangea/dnd/blob/main/docs/guides/using-inner-ref.md - `)}function cp(e){e=(0,H.useContext)(e);return e||W(0,"Could not find required context"),e}var rn=(e,t)=>e===t,dp=e=>{var{combine:e,destination:t}=e;return t?t.droppableId:e?e.droppableId:null},up=e=>e.combine?e.combine.draggableId:null,pp=e=>e.at&&"COMBINE"===e.at.type?e.at.combine.draggableId:null;function mp(e=null){return{isDragging:!1,isDropAnimating:!1,isClone:!1,dropAnimation:null,mode:null,draggingOver:null,combineTargetFor:e,combineWith:null}}var hp={mapped:{type:"SECONDARY",offset:Y,combineTargetFor:null,shouldAnimateDisplacement:!0,snapshot:mp(null)}};var gp=c(()=>{const a=function(){const s=Z((e,t)=>({x:e,y:t})),l=Z((e,t,a=null,r=null,n=null)=>({isDragging:!0,isClone:t,isDropAnimating:Boolean(n),dropAnimation:n,mode:e,draggingOver:a,combineWith:r,combineTargetFor:null})),c=Z((e,t,a,r,n=null,o=null,i=null)=>({mapped:{type:"DRAGGING",dropping:null,draggingOver:n,combineWith:o,mode:t,offset:e,dimension:a,forceShouldAnimate:i,snapshot:l(t,r,n,o,null)}}));return(e,t)=>{var a,r,n,o,i;return Su(e)?e.critical.draggable.id!==t.draggableId?null:(o=e.current.client.offset,a=e.dimensions.draggables[t.draggableId],r=nc(e.impact),i=pp(e.impact),n=e.forceShouldAnimate,c(s(o.x,o.y),e.movementMode,a,t.isClone,r,i,n)):"DROP_ANIMATING"!==e.phase||(o=e.completed).result.draggableId!==t.draggableId?null:(a=t.isClone,r=e.dimensions.draggables[t.draggableId],n=(i=o.result).mode,t=dp(i),o=up(i),i={duration:e.dropDuration,curve:Fc.drop,moveTo:e.newHomeClientOffset,opacity:o?Gc.opacity.drop:null,scale:o?Gc.scale.drop:null},{mapped:{type:"DRAGGING",offset:e.newHomeClientOffset,dimension:r,dropping:i,draggingOver:t,combineWith:o,mode:n,forceShouldAnimate:null,snapshot:l(n,a,t,o,i)}})}}(),r=function(){const s=Z((e,t)=>({x:e,y:t})),r=Z(mp),l=Z((e,t=null,a)=>({mapped:{type:"SECONDARY",offset:e,combineTargetFor:t,shouldAnimateDisplacement:a,snapshot:r(t)}})),c=e=>e?l(Y,e,!0):null,a=(e,t,a,r)=>{var n=a.displaced.visible[e],o=Boolean(r.inVirtualList&&r.effected[e]),i=vl(a),i=i&&i.draggableId===e?t:null;return n?o?c(i):(t=a.displacedBy.point,t=s(t.x,t.y),l(t,i,n.shouldAnimate)):o?a.displaced.invisible[e]?null:(t=rl(r.displacedBy.point),n=s(t.x,t.y),l(n,i,!0)):c(i)};return(e,t)=>{return Su(e)?e.critical.draggable.id===t.draggableId?null:a(t.draggableId,e.critical.draggable.id,e.impact,e.afterCritical):"DROP_ANIMATING"!==e.phase||(e=e.completed).result.draggableId===t.draggableId?null:a(t.draggableId,e.result.draggableId,e.impact,e.afterCritical)}}();return(e,t)=>a(e,t)||r(e,t)||hp},{dropAnimationFinished:jc},null,{context:ru,areStatePropsEqual:rn})(e=>{const t=(0,H.useRef)(null),a=J((e=null)=>{t.current=e},[]),r=J(()=>t.current,[]),{contextId:n,dragHandleUsageInstructionsId:o,registry:i}=cp(cu),{type:s,droppableId:l}=cp(sp),c=K(()=>({id:e.draggableId,index:e.index,type:s,droppableId:l}),[e.draggableId,e.index,s,l]),{children:d,draggableId:u,isEnabled:p,shouldRespectForcePress:m,canDragInteractiveElements:h,isClone:g,mapped:f,dropAnimationFinished:b}=e;var v,y,S,w;v=e,y=n,S=r,fu(()=>{function e(e){return`Draggable[id: ${e}]: `}var t=v.draggableId;t||W(0,"Draggable requires a draggableId"),"string"!=typeof t&&W(0,`Draggable requires a [string] draggableId. - Provided: [type: ${typeof t}] (value: ${t})`),Number.isInteger(v.index)||W(0,e(t)+" requires an integer index prop"),"DRAGGING"!==v.mapped.type&&(lp(S()),v.isEnabled)&&!tu(y,t)&&W(0,e(t)+" Unable to find drag handle")}),w=g,gu(()=>{const e=(0,H.useRef)(w);fu(()=>{w!==e.current&&W(0,"Draggable isClone prop value changed during component life")},[w])}),g||ip(K(()=>({descriptor:c,registry:i,getDraggableRef:r,canDragInteractiveElements:h,shouldRespectForcePress:m,isEnabled:p}),[c,i,r,h,m,p]));const k=K(()=>p?{tabIndex:0,role:"button","aria-describedby":o,"data-rfd-drag-handle-draggable-id":u,"data-rfd-drag-handle-context-id":n,draggable:!1,onDragStart:function(e){e.preventDefault()}}:null,[n,o,u,p]),E=J(e=>{"DRAGGING"===f.type&&f.dropping&&"transform"===e.propertyName&&(0,ci.flushSync)(b)},[b,f]);var C=K(()=>{var e=op(f),t="DRAGGING"===f.type&&f.dropping?E:void 0;return{innerRef:a,draggableProps:{"data-rfd-draggable-context-id":n,"data-rfd-draggable-id":u,style:e,onTransitionEnd:t},dragHandleProps:k}},[n,k,u,f,E,a]),I=K(()=>({draggableId:c.id,type:c.type,source:{index:c.index,droppableId:c.droppableId}}),[c.droppableId,c.id,c.index,c.type]);return H.default.createElement(H.default.Fragment,null,d(C,f.snapshot,I))});function fp(e){return cp(sp).isUsingCloneFor!==e.draggableId||e.isClone?H.default.createElement(gp,e):null}function bp(e){var t="boolean"!=typeof e.isDragDisabled||!e.isDragDisabled,a=Boolean(e.disableInteractiveElementBlocking),r=Boolean(e.shouldRespectForcePress);return H.default.createElement(fp,_s({},e,{isClone:!1,isEnabled:t,canDragInteractiveElements:a,shouldRespectForcePress:r}))}var Gn=t=>e=>t===e,vp=Gn("scroll"),yp=Gn("auto"),Sp=Gn("visible"),wp=(e,t)=>t(e.overflowX)||t(e.overflowY),kp=e=>{e=window.getComputedStyle(e),e={overflowX:e.overflowX,overflowY:e.overflowY};return wp(e,vp)||wp(e,yp)},Ep=e=>{var t,a;return null==e?null:e===document.body?(t=nu(),(a=document.documentElement)||W(),kp(t)&&(t=window.getComputedStyle(a),a={overflowX:t.overflowX,overflowY:t.overflowY},(t=Sp)((a=a).overflowX)&&t(a.overflowY)||q(` - We have detected that your element might be a scroll container. - We have found no reliable way of detecting whether the element is a scroll container. - Under most circumstances a scroll bar will be on the element (document.documentElement) - - Because we cannot determine if the is a scroll container, and generally it is not one, - we will be treating the as *not* a scroll container - - More information: https://github.com/hello-pangea/dnd/blob/main/docs/guides/how-we-detect-scroll-containers.md - `)),null):e===document.documentElement?null:kp(e)?e:Ep(e.parentElement)},Cp=e=>{e&&Ep(e.parentElement)&&q(` - Droppable: unsupported nested scroll container detected. - A Droppable can only have one scroll parent (which can be itself) - Nested scroll containers are currently not supported. - - We hope to support nested scroll containers soon: https://github.com/atlassian/react-beautiful-dnd/issues/131 - `)},Ip=e=>({x:e.scrollLeft,y:e.scrollTop}),xp=e=>{return!!e&&("fixed"===window.getComputedStyle(e).position||xp(e.parentElement))},Np=e=>{return{closestScrollable:Ep(e),isFixedOnPage:xp(e)}},Ap=({ref:e,descriptor:t,env:a,windowScroll:r,direction:n,isDropDisabled:o,isCombineEnabled:i,shouldClipSubject:s})=>{const l=a.closestScrollable;p=l,h=As(e=e);var c,d,u,p=!p||e!==p?h:(e=h.paddingBox.top-p.scrollTop,c=h.paddingBox.left-p.scrollLeft,m=e+p.scrollHeight,p=c+p.scrollWidth,e=Cs({top:e,right:p,bottom:m,left:c},h.border),Ls({borderBox:e,margin:h.margin,border:h.border,padding:h.padding})),m=xs(p,r),h=l?(c=As(l),e={scrollHeight:l.scrollHeight,scrollWidth:l.scrollWidth},{client:c,page:xs(c,r),scroll:Ip(l),scrollSize:e,shouldClipSubject:s}):null;return{descriptor:r,isEnabled:e,isCombineEnabled:s,isFixedOnPage:t,direction:o,client:i,page:a,closest:n}=[{descriptor:t,isEnabled:!o,isCombineEnabled:i,isFixedOnPage:a.isFixedOnPage,direction:n,client:p,page:m,closest:h}][0],d=n?({scrollSize:u,client:d}=n,p=gd({scrollHeight:u.scrollHeight,scrollWidth:u.scrollWidth,height:d.paddingBox.height,width:d.paddingBox.width}),{pageMarginBox:n.page.marginBox,frameClient:d,scrollSize:u,shouldClipSubject:n.shouldClipSubject,scroll:{initial:n.scroll,current:n.scroll,max:p,diff:{value:Y,displacement:Y}}}):null,{descriptor:r,isCombineEnabled:s,isFixedOnPage:t,axis:u="vertical"===o?Nl:Al,isEnabled:e,client:i,page:a,frame:d,subject:dl({page:a,withPlaceholder:null,axis:u,frame:d})}},Tp={passive:!1},Op={passive:!0},Lp=e=>e.shouldPublishImmediately?Tp:Op,Dp=e=>e&&e.env.closestScrollable||null;function Pp(){}var Mp={width:0,height:0,margin:{top:0,right:0,bottom:0,left:0}},Rp=({isAnimatingOpenOnMount:e,placeholder:t,animate:a})=>e||"close"===a?Mp:{height:t.client.borderBox.height,width:t.client.borderBox.width,margin:t.client.margin},_p=H.default.memo(e=>{const t=(0,H.useRef)(null),a=J(()=>{t.current&&(clearTimeout(t.current),t.current=null)},[]),{animate:r,onTransitionEnd:n,onClose:o,contextId:i}=e,[s,l]=(0,H.useState)("open"===e.animate);(0,H.useEffect)(()=>s?"open"!==r?(a(),l(!1),Pp):t.current?Pp:(t.current=setTimeout(()=>{t.current=null,l(!1)}),a):Pp,[r,s,a]);var c=J(e=>{"height"===e.propertyName&&(n(),"close"===r)&&o()},[r,o,n]),d=(({isAnimatingOpenOnMount:e,placeholder:t,animate:a})=>{e=Rp({isAnimatingOpenOnMount:e,placeholder:t,animate:a});return{display:t.display,boxSizing:"border-box",width:e.width,height:e.height,marginTop:e.margin.top,marginRight:e.margin.right,marginBottom:e.margin.bottom,marginLeft:e.margin.left,flexShrink:"0",flexGrow:"0",pointerEvents:"none",transition:"none"!==a?Vc.placeholder:null}})({isAnimatingOpenOnMount:s,animate:e.animate,placeholder:e.placeholder});return H.default.createElement(e.placeholder.tagName,{style:d,"data-rfd-placeholder-context-id":i,onTransitionEnd:c,ref:e.innerRef})});function Bp(e){return"boolean"==typeof e}function jp(t,e){e.forEach(e=>e(t))}var $p=[function({props:e}){e.droppableId||W(0,"A Droppable requires a droppableId prop"),"string"!=typeof e.droppableId&&W(0,`A Droppable requires a [string] droppableId. Provided: [${typeof e.droppableId}]`)},function({props:e}){Bp(e.isDropDisabled)||W(0,"isDropDisabled must be a boolean"),Bp(e.isCombineEnabled)||W(0,"isCombineEnabled must be a boolean"),Bp(e.ignoreContainerClipping)||W(0,"ignoreContainerClipping must be a boolean")},function({getDroppableRef:e}){lp(e())}],zp=[function({props:e,getPlaceholderRef:t}){e.placeholder&&!t()&&q(` - Droppable setup issue [droppableId: "${e.droppableId}"]: - DroppableProvided > placeholder could not be found. - - Please be sure to add the {provided.placeholder} React Node as a child of your Droppable. - More information: https://github.com/hello-pangea/dnd/blob/main/docs/api/droppable.md - `)}],Up=[function({props:e}){e.renderClone||W(0,"Must provide a clone render function (renderClone) for virtual lists")},function({getPlaceholderRef:e}){e()&&W(0,"Expected virtual list to not have a placeholder")}];var Fp=class extends H.default.PureComponent{constructor(...e){super(...e),this.state={isVisible:Boolean(this.props.on),data:this.props.on,animate:this.props.shouldAnimate&&this.props.on?"open":"none"},this.onClose=()=>{"close"===this.state.animate&&this.setState({isVisible:!1})}}static getDerivedStateFromProps(e,t){return e.shouldAnimate?e.on?{isVisible:!0,data:e.on,animate:"open"}:t.isVisible?{isVisible:!0,data:t.data,animate:"close"}:{isVisible:!1,animate:"close",data:null}:{isVisible:Boolean(e.on),data:e.on,animate:"none"}}render(){var e;return this.state.isVisible?(e={onClose:this.onClose,data:this.state.data,animate:this.state.animate},this.props.children(e)):null}};var Gp={mode:"standard",type:"DEFAULT",direction:"vertical",isDropDisabled:!1,isCombineEnabled:!1,ignoreContainerClipping:!1,renderClone:null,getContainerForClone:function(){return document.body||W(0,"document.body is not ready"),document.body}},Vp=e=>{let t={...e},a;for(a in Gp)void 0===e[a]&&(t={...t,[a]:Gp[a]});return t},Hp=(e,t)=>e===t.droppable.type,qp=(e,t)=>t.draggables[e.draggable.id],Wp=c(()=>{const s={placeholder:null,shouldAnimatePlaceholder:!0,snapshot:{isDraggingOver:!1,draggingOverWith:null,draggingFromThisWith:null,isUsingPlaceholder:!1},useClone:null},l={...s,shouldAnimatePlaceholder:!1},c=Z(e=>({draggableId:e.id,type:e.type,source:{index:e.index,droppableId:e.droppableId}})),d=Z((e,t,a,r,n,o)=>{var i=n.descriptor.id;return n.descriptor.droppableId===e?(e=o?{render:o,dragging:c(n.descriptor)}:null,{placeholder:n.placeholder,shouldAnimatePlaceholder:!1,snapshot:{isDraggingOver:a,draggingOverWith:a?i:null,draggingFromThisWith:i,isUsingPlaceholder:!0},useClone:e}):t?r?{placeholder:n.placeholder,shouldAnimatePlaceholder:!0,snapshot:{isDraggingOver:a,draggingOverWith:i,draggingFromThisWith:null,isUsingPlaceholder:!0},useClone:null}:s:l});return(e,t)=>{var a,r,t=Vp(t),n=t.droppableId,o=t.type,i=!t.isDropDisabled,t=t.renderClone;return Su(e)?(r=e.critical,Hp(o,r)?(r=qp(r,e.dimensions),a=nc(e.impact)===n,d(n,i,a,a,r,t)):l):"DROP_ANIMATING"===e.phase?(a=e.completed,Hp(o,a.critical)?(r=qp(a.critical,e.dimensions),d(n,i,dp(a.result)===n,nc(a.impact)===n,r,t)):l):"IDLE"===e.phase&&e.completed&&!e.shouldFlush&&(i=e.completed,Hp(o,i.critical))?(a=nc(i.impact)===n,r=Boolean(i.impact.at&&"COMBINE"===i.impact.at.type),t=i.critical.droppable.id===n,a?r?s:l:t?s:l):l}},{updateViewportMaxScroll:e=>({type:"UPDATE_VIEWPORT_MAX_SCROLL",payload:e})},(e,t,a)=>({...Vp(a),...e,...t}),{context:ru,areStatePropsEqual:rn})(e=>{var t=(0,H.useContext)(cu);t||W(0,"Could not find app context");const{contextId:r,isMovementAllowed:a}=t,n=(0,H.useRef)(null),o=(0,H.useRef)(null),{children:_,droppableId:i,type:s,mode:B,direction:j,ignoreContainerClipping:$,isDropDisabled:z,isCombineEnabled:U,snapshot:F,useClone:l,updateViewportMaxScroll:c,getContainerForClone:G}=e;t=J(()=>n.current,[]);const d=J((e=null)=>{n.current=e},[]);var u,p=J(()=>o.current,[]);const m=J((e=null)=>{o.current=e},[]),h=(u={props:e,getDroppableRef:t,getPlaceholderRef:p},fu(()=>{jp(u,$p),"standard"===u.props.mode&&jp(u,zp),"virtual"===u.props.mode&&jp(u,Up)}),J(()=>{a()&&c({maxScroll:bd()})},[a,c]));{var g={droppableId:i,type:s,mode:B,direction:j,isDropDisabled:z,isCombineEnabled:U,ignoreContainerClipping:$,getDroppableRef:t};const b=(0,H.useRef)(null),v=cp(cu),y=su("droppable"),{registry:S,marshal:w}=v,k=vu(g),E=K(()=>({id:g.droppableId,type:g.type,mode:g.mode}),[g.droppableId,g.mode,g.type]),C=(0,H.useRef)(E),I=K(()=>Z((e,t)=>{b.current||W(0,"Can only update scroll when dragging");e={x:e,y:t};w.updateDroppableScroll(E.id,e)}),[E.id,w]),x=J(()=>{var e=b.current;return e&&e.env.closestScrollable?Ip(e.env.closestScrollable):Y},[]),N=J(()=>{var e=x();I(e.x,e.y)},[x,I]),A=K(()=>Rs(N),[N]),T=J(()=>{var e=b.current,t=Dp(e),t=(e&&t||W(0,"Could not find scroll options while scrolling"),e.scrollOptions);(t.shouldPublishImmediately?N:A)()},[A,N]),O=J((e,t)=>{b.current&&W(0,"Cannot collect a droppable while a drag is occurring");var a=k.current,r=a.getDroppableRef(),n=(r||W(0,"Cannot collect without a droppable ref"),Np(r)),t={ref:r,descriptor:E,env:n,scrollOptions:t},r=(b.current=t,Ap({ref:r,descriptor:E,env:n,windowScroll:e,direction:a.direction,isDropDisabled:a.isDropDisabled,isCombineEnabled:a.isCombineEnabled,shouldClipSubject:!a.ignoreContainerClipping})),e=n.closestScrollable;return e&&(e.setAttribute(Vd.contextId,v.contextId),e.addEventListener("scroll",T,Lp(t.scrollOptions)),Cp(e)),r},[v.contextId,E,T,k]),L=J(()=>{var e=b.current,t=Dp(e);return e&&t||W(0,"Can only recollect Droppable client for Droppables that have a scroll container"),Ip(t)},[]),D=J(()=>{var e=b.current,t=(e||W(0,"Cannot stop drag when no active drag"),Dp(e));b.current=null,t&&(A.cancel(),t.removeAttribute(Vd.contextId),t.removeEventListener("scroll",T,Lp(e.scrollOptions)))},[T,A]),P=J(e=>{var t=b.current,t=(t||W(0,"Cannot scroll when there is no drag"),Dp(t));t||W(0,"Cannot scroll a droppable with no closest scrollable"),t.scrollTop+=e.y,t.scrollLeft+=e.x},[]),M=K(()=>({getDimensionAndWatchScroll:O,getScrollWhileDragging:L,dragStopped:D,scroll:P}),[D,O,L,P]),R=K(()=>({uniqueId:y,descriptor:E,callbacks:M}),[M,E,y]);Kd(()=>(C.current=R.descriptor,S.droppable.register(R),()=>{b.current&&(q("Unsupported: changing the droppableId or type of a Droppable during a drag"),D()),S.droppable.unregister(R)}),[M,E,D,R,w,S.droppable]),Kd(()=>{b.current&&w.updateDroppableIsEnabled(C.current.id,!g.isDropDisabled)},[g.isDropDisabled,w]),Kd(()=>{b.current&&w.updateDroppableIsCombineEnabled(C.current.id,g.isCombineEnabled)},[g.isCombineEnabled,w])}const f=K(()=>H.default.createElement(Fp,{on:e.placeholder,shouldAnimate:e.shouldAnimatePlaceholder},({onClose:e,data:t,animate:a})=>H.default.createElement(_p,{placeholder:t,onClose:e,innerRef:m,animate:a,contextId:r,onTransitionEnd:h})),[r,h,e.placeholder,e.shouldAnimatePlaceholder,m]);p=K(()=>({innerRef:d,placeholder:f,droppableProps:{"data-rfd-droppable-id":i,"data-rfd-droppable-context-id":r}}),[r,i,f,d]);const V=l?l.dragging.draggableId:null;t=K(()=>({droppableId:i,type:s,isUsingCloneFor:V}),[i,V,s]);return H.default.createElement(sp.Provider,{value:t},_(p,F),function(){if(!l)return null;const{dragging:a,render:r}=l;var e=H.default.createElement(fp,{draggableId:a.draggableId,index:a.source.index,isClone:!0,isEnabled:!0,shouldRespectForcePress:!1,canDragInteractiveElements:!0},(e,t)=>r(e,t,a));return ci.default.createPortal(e,G())}())}),Kp=t(a()),Jp=n=>{const o=getComputedStyle(document.body).getPropertyValue("--spice-button-disabled");return Kp.default.createElement(ep,{onDragEnd:e=>{var t,{source:e,destination:a}=e;a&&(t=n.modalConfig.tabs,e=e.index,a=a.index,[e]=(t=Array.from(t)).splice(e,1),t.splice(a,0,e),n.modalConfig.tabs=t,localStorage.setItem(I.tabs,JSON.stringify(n.modalConfig.tabs)),n.updateConfig(n.modalConfig))}},Kp.default.createElement(Wp,{droppableId:"droppable",direction:"horizontal"},e=>Kp.default.createElement("div",{ref:e.innerRef,style:{display:"flex",paddingTop:8,paddingBottom:8,gap:8},...e.droppableProps},n.modalConfig.tabs.map((r,e)=>Kp.default.createElement(bp,{key:r.name,draggableId:r.name,index:e},(e,t)=>{return Kp.default.createElement("div",{ref:e.innerRef,...e.draggableProps,style:(t.isDragging,t=e.draggableProps.style,{borderRadius:"5px",border:(a=r.enabled)?"2px solid "+o:"2px solid red",userSelect:"none",paddingTop:12,paddingBottom:12,width:"110px",display:"flex",alignItems:"center",justifyContent:"center",textDecoration:a?"none":"line-through",cursor:"pointer",...t})},Kp.default.createElement("div",{className:"dnd-box",...e.dragHandleProps,onClick:()=>{return t=r.name,e=n.modalConfig.tabs.map(e=>e.name===t?{...e,enabled:!e.enabled}:e),n.modalConfig.tabs=e,localStorage.setItem(I.tabs,JSON.stringify(n.modalConfig.tabs)),void n.updateConfig(n.modalConfig);var t,e}},Kp.default.createElement("svg",{className:"dnd-icon",fill:"currentColor",width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg","aria-label":"Drag icon",role:"img"},Kp.default.createElement("path",{"fill-rule":"evenodd",d:"M7.375 3.67c0-.645-.56-1.17-1.25-1.17s-1.25.525-1.25 1.17c0 .646.56 1.17 1.25 1.17s1.25-.524 1.25-1.17zm0 8.66c0-.646-.56-1.17-1.25-1.17s-1.25.524-1.25 1.17c0 .645.56 1.17 1.25 1.17s1.25-.525 1.25-1.17zm-1.25-5.5c.69 0 1.25.525 1.25 1.17 0 .645-.56 1.17-1.25 1.17S4.875 8.645 4.875 8c0-.645.56-1.17 1.25-1.17zm5-3.16c0-.645-.56-1.17-1.25-1.17s-1.25.525-1.25 1.17c0 .646.56 1.17 1.25 1.17s1.25-.524 1.25-1.17zm-1.25 7.49c.69 0 1.25.524 1.25 1.17 0 .645-.56 1.17-1.25 1.17s-1.25-.525-1.25-1.17c0-.646.56-1.17 1.25-1.17zM11.125 8c0-.645-.56-1.17-1.25-1.17s-1.25.525-1.25 1.17c0 .645.56 1.17 1.25 1.17s1.25-.525 1.25-1.17z"})),"Extensions"===r.name?"Extens.":r.name));var a})),e.placeholder)))},Yp=async()=>{const e=new MutationObserver(async()=>{var t;document.querySelector(".GenericModal[aria-label='Settings']")||(t=100,await new Promise(e=>setTimeout(e,t)),lm("BACKUP"),e.disconnect())});e.observe(document.body,{childList:!0,subtree:!0}),Spicetify.PopupModal.hide()},Zp=({CONFIG:e,updateAppConfig:t})=>{const[a,r]=u.default.useState({...e}),[n,o]=u.default.useState(y("settings.versionBtn"));var e=e=>{t({...e}),r({...e})},i=document.querySelector("body > generic-modal button.main-trackCreditsModal-closeBtn");const s=document.querySelector("body > generic-modal > div");i&&s&&(i.onclick=()=>location.reload(),i.setAttribute("style","cursor: pointer;"),s.onclick=e=>{e.target===s&&location.reload()});i=N(I.albumArtBasedColor)?u.default.createElement(u.default.Fragment,null,u.default.createElement(li,{name:y("settings.albumArtBasedColorsMode"),storageKey:"albumArtBasedColorsMode",modalConfig:a,updateConfig:e,type:"dropdown",options:["monochromeDark","monochromeLight","analogicComplement","analogic","triad","quad"],description:y("settings.albumArtColorsModeToolTip")}),u.default.createElement(li,{name:y("settings.albumArtBasedColorsVibrancy"),storageKey:"albumArtBasedColorsVibrancy",modalConfig:a,updateConfig:e,type:"dropdown",options:["desaturated","lightVibrant","prominent","vibrant"],description:y("settings.albumArtBasedColorsVibrancyToolTip")})):null;return u.default.createElement("div",{id:"marketplace-config-container"},u.default.createElement("div",{className:"settings-block-top"},u.default.createElement("h2",{className:"settings-heading"},y("settings.optionsHeading")),u.default.createElement(li,{name:y("settings.starCountLabel"),storageKey:"stars",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.tagsLabel"),storageKey:"tags",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.showArchived"),storageKey:"showArchived",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.devToolsLabel"),storageKey:"themeDevTools",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.hideInstalledLabel"),storageKey:"hideInstalled",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.colourShiftLabel"),storageKey:"colorShift",modalConfig:a,updateConfig:e}),u.default.createElement(li,{name:y("settings.albumArtBasedColors"),storageKey:"albumArtBasedColors",modalConfig:a,updateConfig:e}),i),u.default.createElement("div",{className:"settings-block"},u.default.createElement("h2",{className:"settings-heading"},y("settings.tabsHeading")),u.default.createElement(Jp,{modalConfig:a,updateConfig:e}),u.default.createElement("p",{className:"settings-tabs-description"},"(",y("settings.tabsDescription"),")")),u.default.createElement("div",{className:"settings-block"},u.default.createElement("h2",{className:"settings-heading"},y("settings.resetHeading")),u.default.createElement("div",{className:"settings-row"},u.default.createElement("span",{className:"col description"},y("settings.resetDescription")),u.default.createElement("div",{className:"col action"},u.default.createElement(Go,{onClick:()=>fo()},y("settings.resetBtn"))))),u.default.createElement("div",{className:"settings-block"},u.default.createElement("h2",{className:"settings-heading"},y("settings.backupHeading")),u.default.createElement("div",{className:"settings-row"},u.default.createElement("span",{className:"col description"},y("settings.backupLabel")),u.default.createElement("div",{className:"col action"},u.default.createElement(Go,{onClick:Yp},y("settings.backupBtn"))))),u.default.createElement("div",{className:"settings-block-bottom"},u.default.createElement("div",{className:"settings-row"},u.default.createElement("span",{className:"col description"},y("grid.spicetifyMarketplace")," ",y("settings.versionHeading")," ",Oa),u.default.createElement("div",{className:"col action"},u.default.createElement(Go,{onClick:()=>{Spicetify.Platform.ClipboardAPI.copy(Oa),o(y("settings.versionCopied")),setTimeout(()=>o(y("settings.versionBtn")),3e3)},classes:["small"]},n)))))},Xp=t(z()),v=t(a()),Qp=t(U()),em=(je=Prism,e=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,je.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+e.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+e.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+e.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+e.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:e,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},je.languages.css.atrule.inside.rest=je.languages.css,(e=je.languages.markup)&&(e.tag.addInlined("style","css"),e.tag.addAttribute("style","css")),r=>{var e="marketplace-customCSS-preview";const[n,t]=v.default.useState("ADD_SNIPPET"!==r.type&&r.content?.item.code||""),[a,o]=v.default.useState("ADD_SNIPPET"!==r.type&&r.content?.item.title||""),[i,s]=v.default.useState("ADD_SNIPPET"!==r.type&&r.content?.item.description||""),[l,c]=v.default.useState("ADD_SNIPPET"!==r.type&&r.content?.item.imageURL||""),d=()=>a.replace(/\n/g,"").replaceAll(" ","-");const u="marketplace:installed:snippet:"+d(),[p,m]=v.default.useState(!!N(u));let h;return v.default.createElement("div",{id:"marketplace-add-snippet-container"},v.default.createElement("div",{className:"marketplace-customCSS-input-container"},v.default.createElement("label",{htmlFor:"marketplace-custom-css"},y("snippets.customCSS")),v.default.createElement("div",{className:"marketplace-code-editor-wrapper marketplace-code-editor"},v.default.createElement(Qp.default,{value:n,onValueChange:e=>t(e),highlight:e=>(0,Xp.highlight)(e,Xp.languages.css),textareaId:"marketplace-custom-css",textareaClassName:"snippet-code-editor",readOnly:"VIEW_SNIPPET"===r.type,placeholder:y("snippets.customCSSPlaceholder"),style:{}}))),v.default.createElement("div",{className:"marketplace-customCSS-input-container"},v.default.createElement("label",{htmlFor:"marketplace-customCSS-name-submit"},y("snippets.snippetName")),v.default.createElement("input",{id:"marketplace-customCSS-name-submit",className:"marketplace-code-editor",value:a,onChange:e=>{"VIEW_SNIPPET"!==r.type&&o(e.target.value)},placeholder:y("snippets.snippetNamePlaceholder")})),v.default.createElement("div",{className:"marketplace-customCSS-input-container"},v.default.createElement("label",{htmlFor:"marketplace-customCSS-description-submit"},y("snippets.snippetDesc")),v.default.createElement("input",{id:"marketplace-customCSS-description-submit",className:"marketplace-code-editor",value:i,onChange:e=>{"VIEW_SNIPPET"!==r.type&&s(e.target.value)},placeholder:y("snippets.snippetDescPlaceholder")})),v.default.createElement("div",{className:"marketplace-customCSS-input-container"},v.default.createElement("label",{htmlFor:e},y("snippets.snippetPreview")," ","VIEW_SNIPPET"!==r.type&&`(${y("snippets.optional")})`),l&&v.default.createElement("label",{htmlFor:e,style:{textAlign:"center"}},v.default.createElement("img",{className:"marketplace-customCSS-image-preview",src:l,alt:"Preview"}))),"VIEW_SNIPPET"!==r.type&&v.default.createElement(v.default.Fragment,null,v.default.createElement(Go,{onClick:()=>{h.click()}},l.length?y("snippets.changeImage"):y("snippets.addImage"),v.default.createElement("input",{id:e,type:"file",style:{display:"none"},ref:e=>h=e,onChange:async e=>{if(e.target.files?.[0])try{r=e.target.files?.[0];var t=await new Promise((e,t)=>{const a=new FileReader;a.readAsDataURL(r),a.onload=()=>{e(a.result)},a.onerror=e=>{t(e)}});t&&c(t)}catch(e){console.error(e)}var r}})),v.default.createElement(Go,{onClick:()=>{var e,t=d(),a=i.trim();p&&"EDIT_SNIPPET"!==r.type?Spicetify.showNotification(y("snippets.duplicateName"),!0):(console.debug("Installing snippet: "+t),r.content&&r.content.item.title!==t&&(console.debug("Deleting outdated snippet: "+r.content.item.title),localStorage.removeItem("marketplace:installed:snippet:"+r.content.item.title),e=N(I.installedSnippets,[]).filter(e=>e!=="marketplace:installed:snippet:"+r.content?.item.title),localStorage.setItem(I.installedSnippets,JSON.stringify(e))),localStorage.setItem(u,JSON.stringify({title:t,code:n,description:a,imageURL:l,custom:!0})),-1===(e=N(I.installedSnippets,[])).indexOf(u)&&(e.push(u),localStorage.setItem(I.installedSnippets,JSON.stringify(e))),t=e.map(e=>N(e)),po(t),Spicetify.PopupModal.hide(),"EDIT_SNIPPET"===r.type&&location.reload())},disabled:!d()||!n.replace(/\n/g,"\\n")},y("snippets.saveCSS"))),"VIEW_SNIPPET"===r.type&&v.default.createElement(Go,{onClick:()=>{r.callback?.(),m(!p)}},p?y("remove"):y("install")))}),tm=t(z()),am=t(a()),rm=t(U()),nm=(Prism.languages.ini={comment:{pattern:/(^[ \f\t\v]*)[#;][^\n\r]*/m,lookbehind:!0},section:{pattern:/(^[ \f\t\v]*)\[[^\n\r\]]*\]?/m,lookbehind:!0,inside:{"section-name":{pattern:/(^\[[ \f\t\v]*)[^ \f\t\v\]]+(?:[ \f\t\v]+[^ \f\t\v\]]+)*/,lookbehind:!0,alias:"selector"},punctuation:/\[|\]/}},key:{pattern:/(^[ \f\t\v]*)[^ \f\n\r\t\v=]+(?:[ \f\t\v]+[^ \f\n\r\t\v=]+)*(?=[ \f\t\v]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/(=[ \f\t\v]*)[^ \f\n\r\t\v]+(?:[ \f\t\v]+[^ \f\n\r\t\v]+)*/,lookbehind:!0,alias:"attr-value",inside:{"inner-value":{pattern:/^("|').+(?=\1$)/,lookbehind:!0}}},punctuation:/=/},localStorage.getItem(I.themeInstalled)),om=nm?N(nm):null,im=()=>{const[a,t]=am.default.useState(om?(e=>{let t="";for(const a in e)if(Object.hasOwn(e,a))if("object"==typeof e[a]){t+=`[${a}] -`;for(const r in e[a])Object.hasOwn(e[a],r)&&(t+=`${r}=${e[a][r]} -`)}else t+=`${a}=${e[a]} -`;return t})(om.schemes):y("devTools.noThemeInstalled"));return am.default.createElement("div",{id:"marketplace-theme-dev-tools-container",className:"marketplace-theme-dev-tools-container"},am.default.createElement("div",{className:"devtools-column"},am.default.createElement("label",{htmlFor:"color-ini-editor"},am.default.createElement("h2",{className:"devtools-heading"},y("devTools.colorIniEditor"))),am.default.createElement("div",{className:"marketplace-code-editor-wrapper marketplace-code-editor"},am.default.createElement(rm.default,{value:a,onValueChange:e=>t(e),highlight:e=>(0,tm.highlight)(e,tm.languages.ini),textareaId:"color-ini-editor",textareaClassName:"color-ini-editor",readOnly:!om,placeholder:y("devTools.colorIniEditorPlaceholder"),style:{fontFamily:"monospace",resize:"none"}})),am.default.createElement(Go,{onClick:()=>{var e=a;{var t;nm?(t=uo(e),om.schemes=t,localStorage.setItem(nm,JSON.stringify(om))):Spicetify.showNotification(y("devTools.noThemeManifest"),!0)}}},y("save"))),am.default.createElement("div",{className:"devtools-column"},am.default.createElement("h2",{className:"devtools-heading"},y("devTools.invalidCSS")),am.default.createElement("div",{className:"marketplace-code-editor-wrapper marketplace-code-editor"},function(){var e=document.querySelector("body > style.marketplaceCSS.marketplaceUserCSS")?.innerHTML;if(!e)return["Error: Class name list not found; please create an issue"];var a=[];for(const o of e.matchAll(/.-?[_a-zA-Z]+[_a-zA-Z0-9-]*\s*{/g)){var r=o[0].replace(/{/g,"").trim(),n=r.split(" ");let t;for(let e=0;eam.default.createElement("div",{key:t,className:"invalid-css-text"},e)))))},m=t(a());var sm=function(){const[e,t]=m.default.useState(null);return m.default.useEffect(()=>{!async function(){try{var{body:e,tag_name:t,message:a}=await(await fetch(Ra)).json();return e&&t&&!a?{version:t.replace("v",""),changelog:await wo(e.match(/## What's Changed([\s\S]*?)(\r\n\r|\n\n##)/)[1],"spicetify","marketplace")}:null}catch(e){return console.error(e),null}}().then(e=>t(e))},[]),m.default.createElement("div",{id:"marketplace-update-container"},m.default.createElement("div",{id:"marketplace-update-description"},m.default.createElement("h4",null,y("updateModal.description")),m.default.createElement("a",{href:Ma+"/tag/v1.0.7"},y("updateModal.currentVersion",{version:Oa})),m.default.createElement("a",{href:Ma+"/tag/v"+e?.version},y("updateModal.latestVersion",{version:e?.version}))),m.default.createElement("hr",null),m.default.createElement("div",{id:"marketplace-update-whats-changed"},m.default.createElement("h3",{className:"marketplace-update-header"},y("updateModal.whatsChanged")),m.default.createElement("details",null,m.default.createElement("summary",null,y("updateModal.seeChangelog")),m.default.createElement("ul",{dangerouslySetInnerHTML:{__html:e?.changelog??""}}))),m.default.createElement("hr",null),m.default.createElement("div",{id:"marketplace-update-guide"},m.default.createElement("h3",{className:"marketplace-update-header"},y("updateModal.howToUpgrade")),m.default.createElement("a",{href:"https://github.com/spicetify/marketplace/wiki/Installation"},y("updateModal.viewGuide"))))},lm=(e,t,a,r,n)=>{e=((e,t,a,r,n)=>{switch(e){case"ADD_SNIPPET":return{title:y("snippets.addTitle"),content:_o.default.createElement(em,{type:e}),isLarge:!0};case"EDIT_SNIPPET":return{title:y("snippets.editTitle"),content:_o.default.createElement(em,{type:e,content:r}),isLarge:!0};case"VIEW_SNIPPET":return{title:y("snippets.viewTitle"),content:_o.default.createElement(em,{type:e,content:r,callback:n}),isLarge:!0};case"RELOAD":return{title:y("reloadModal.title"),content:_o.default.createElement(qo,null),isLarge:!1};case"SETTINGS":return{title:y("settings.title"),content:_o.default.createElement(Zp,{CONFIG:t,updateAppConfig:a}),isLarge:!0};case"THEME_DEV_TOOLS":return{title:y("devTools.title"),content:_o.default.createElement(im,null),isLarge:!0};case"BACKUP":return{title:y("backupModal.title"),content:_o.default.createElement(Vo,null),isLarge:!0};case"UPDATE":return{title:y("updateModal.title"),content:_o.default.createElement(sm,null),isLarge:!0};default:return{title:"",content:_o.default.createElement("div",null),isLarge:!1}}})(e,t,a,r,n),Spicetify.PopupModal.display(e)},S=t(a()),cm=t(a()),dm=()=>cm.default.createElement("svg",{role:"img",width:"16",height:"16",viewBox:"0 0 512 512","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},cm.default.createElement("path",{d:"M480 352h-133.5l-45.25 45.25C289.2 409.3 273.1 416 256 416s-33.16-6.656-45.25-18.75L165.5 352H32c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h448c17.67 0 32-14.33 32-32v-96C512 366.3 497.7 352 480 352zM432 456c-13.2 0-24-10.8-24-24c0-13.2 10.8-24 24-24s24 10.8 24 24C456 445.2 445.2 456 432 456zM233.4 374.6C239.6 380.9 247.8 384 256 384s16.38-3.125 22.62-9.375l128-128c12.49-12.5 12.49-32.75 0-45.25c-12.5-12.5-32.76-12.5-45.25 0L288 274.8V32c0-17.67-14.33-32-32-32C238.3 0 224 14.33 224 32v242.8L150.6 201.4c-12.49-12.5-32.75-12.5-45.25 0c-12.49 12.5-12.49 32.75 0 45.25L233.4 374.6z",fill:"currentColor"})),um=t(a()),pm=()=>um.default.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",role:"img","aria-label":"GitHub Icon"},um.default.createElement("path",{d:"M12 0c-6.626 0-12 5.373-12 12 0 5.302 3.438 9.8 8.207 11.387.599.111.793-.261.793-.577v-2.234c-3.338.726-4.033-1.416-4.033-1.416-.546-1.387-1.333-1.756-1.333-1.756-1.089-.745.083-.729.083-.729 1.205.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492.997.107-.775.418-1.305.762-1.604-2.665-.305-5.467-1.334-5.467-5.931 0-1.311.469-2.381 1.236-3.221-.124-.303-.535-1.524.117-3.176 0 0 1.008-.322 3.301 1.23.957-.266 1.983-.399 3.003-.404 1.02.005 2.047.138 3.006.404 2.291-1.552 3.297-1.23 3.297-1.23.653 1.653.242 2.874.118 3.176.77.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921.43.372.823 1.102.823 2.222v3.293c0 .319.192.694.801.576 4.765-1.589 8.199-6.086 8.199-11.386 0-6.627-5.373-12-12-12z",fill:"currentColor"})),mm=t(a()),hm=()=>mm.default.createElement("svg",{role:"img",width:"16",height:"16",viewBox:"0 0 448 512","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},mm.default.createElement("path",{d:"M53.21 467c1.562 24.84 23.02 45 47.9 45h245.8c24.88 0 46.33-20.16 47.9-45L416 128H32L53.21 467zM432 32H320l-11.58-23.16c-2.709-5.42-8.25-8.844-14.31-8.844H153.9c-6.061 0-11.6 3.424-14.31 8.844L128 32H16c-8.836 0-16 7.162-16 16V80c0 8.836 7.164 16 16 16h416c8.838 0 16-7.164 16-16V48C448 39.16 440.8 32 432 32z",fill:"currentColor"})),gm=t(a()),fm=e=>{return gm.default.createElement("div",{className:"marketplace-card__authors"},e.authors.map(e=>gm.default.createElement("a",{title:e.name,className:"marketplace-card__author",href:e.url,draggable:"false",dir:"auto",target:"_blank",rel:"noopener noreferrer",onClick:e=>e.stopPropagation(),key:e.name+e.url},e.name)))},bm=t(a()),vm=r=>{const[e,t]=bm.default.useState(!1),n={[y("grid.externalJS")]:"external JS",[y("grid.archived")]:"archived",[y("grid.dark")]:"dark",[y("grid.light")]:"light"};var a=e=>{return e.filter((e,t,a)=>a.indexOf(e)===t).reduce((e,t)=>{var a=n[t]||t;return!r.showTags&&t!==y("grid.externalJS")&&t!==y("grid.archived")||e.push(bm.default.createElement("li",{className:"marketplace-card__tag",draggable:!1,"data-tag":a},t)),e},[])};let o=[...r.tags??[]].sort(e=>e===y("grid.externalJS")||e===y("grid.archived")?-1:1),i=[];return 1{e.stopPropagation(),t(!0)}},"..."):null)},ym=window.Spicetify,Sm=class extends S.default.Component{tags;menuType;localStorageKey;key=null;type=Sm;constructor(e){super(e),this.menuType=ym.ReactComponent.Menu,this.localStorageKey=ko(e),Object.assign(this,e),this.tags=e.item.tags||[],e.item.include&&this.tags.push(y("grid.externalJS")),e.item.archived&&this.tags.push(y("grid.archived")),this.state={installed:null!==localStorage.getItem(this.localStorageKey),stars:this.props.item.stars||0,tagsExpanded:!1,externalUrl:this.props.item.user&&this.props.item.repo?`https://github.com/${this.props.item.user}/`+this.props.item.repo:"",lastUpdated:this.props.item.user&&this.props.item.repo?this.props.item.lastUpdated:void 0,created:this.props.item.user&&this.props.item.repo?this.props.item.created:void 0}}isInstalled(){return null!==localStorage.getItem(this.localStorageKey)}async componentDidMount(){if("Installed"===this.props.CONFIG.activeTab&&"snippet"!==this.props.type){var e=`https://api.github.com/repos/${this.props.item.user}/`+this.props.item.repo,{stargazers_count:e,pushed_at:t}=await fetch(e).then(e=>e.json());if(this.state.stars!==e&&this.props.CONFIG.visual.stars&&console.debug("Stars updated to: "+e),this.state.lastUpdated!==t)switch(console.debug("New update pushed at: "+t),this.props.type){case"extension":this.installExtension();break;case"theme":this.installTheme(!0)}}}buttonClicked(){if("extension"===this.props.type)this.isInstalled()?(console.debug("Extension already installed, removing"),this.removeExtension()):this.installExtension(),lm("RELOAD");else if("theme"===this.props.type){var e=localStorage.getItem(I.themeInstalled),e=e?N(e,{}):{};if(this.isInstalled())console.debug("Theme already installed, removing"),this.removeTheme(this.localStorageKey);else{var t=localStorage.getItem(I.localTheme);if(null!=t&&"marketplace"!==t.toLowerCase())return void ym.showNotification(y("notifications.wrongLocalTheme"),!0,5e3);this.removeTheme(),this.installTheme()}(this.props.item.manifest?.include||e.include)&&lm("RELOAD")}else"app"===this.props.type?window.open(this.state.externalUrl,"_blank"):"snippet"===this.props.type?this.isInstalled()?(console.debug("Snippet already installed, removing"),this.removeSnippet()):this.installSnippet():console.error("Unknown card type")}installExtension(){var e,t,a,r,n,o,i,s,l,c,d,u;console.debug("Installing extension "+this.localStorageKey),this.props.item?({manifest:u,title:e,subtitle:t,authors:a,user:r,repo:n,branch:o,imageURL:i,extensionURL:s,readmeURL:l,lastUpdated:c,created:d}=this.props.item,localStorage.setItem(this.localStorageKey,JSON.stringify({manifest:u,type:this.props.type,title:e,subtitle:t,authors:a,user:r,repo:n,branch:o,imageURL:i,extensionURL:s,readmeURL:l,stars:this.state.stars,lastUpdated:c,created:d})),-1===(u=N(I.installedExtensions,[])).indexOf(this.localStorageKey)&&(u.push(this.localStorageKey),localStorage.setItem(I.installedExtensions,JSON.stringify(u))),console.debug("Installed"),this.setState({installed:!0})):ym.showNotification(y("notifications.extensionInstallationError"),!0)}removeExtension(){var e;localStorage.getItem(this.localStorageKey)&&(console.debug("Removing extension "+this.localStorageKey),localStorage.removeItem(this.localStorageKey),e=N(I.installedExtensions,[]).filter(e=>e!==this.localStorageKey),localStorage.setItem(I.installedExtensions,JSON.stringify(e)),console.debug("Removed"),this.setState({installed:!1}))}async installTheme(a=!1){var r=this.props["item"];if(r){console.debug("Installing theme "+this.localStorageKey);let e={},t=null;a?({schemes:a,activeScheme:n}=N(this.localStorageKey,{}),e=a,t=n):r.schemesURL&&(a=await(await fetch(r.schemesURL)).text(),e=uo(a));var n=t||Object.keys(e)[0]||null,{manifest:a,title:o,subtitle:i,authors:s,user:l,repo:c,branch:d,imageURL:u,extensionURL:p,readmeURL:m,cssURL:h,schemesURL:g,include:f,lastUpdated:b,created:v}=(console.debug(e,n),r),a=(localStorage.setItem(this.localStorageKey,JSON.stringify({manifest:a,type:this.props.type,title:o,subtitle:i,authors:s,user:l,repo:c,branch:d,imageURL:u,extensionURL:p,readmeURL:m,stars:this.state.stars,tags:this.tags,cssURL:h,schemesURL:g,include:f,schemes:e,activeScheme:n,lastUpdated:b,created:v})),N(I.installedThemes,[]));-1===a.indexOf(this.localStorageKey)&&(a.push(this.localStorageKey),localStorage.setItem(I.installedThemes,JSON.stringify(a)),localStorage.setItem(I.themeInstalled,this.localStorageKey)),console.debug("Installed"),r.include||(this.fetchAndInjectUserCSS(this.localStorageKey),this.props.updateActiveTheme(this.localStorageKey),this.props.updateColourSchemes(e,n),(o=this.props.item.manifest?.name)&&(ym.Config.current_theme=o),n&&(ym.Config.color_scheme=n)),this.setState({installed:!0})}else ym.showNotification(y("notifications.themeInstallationError"),!0)}removeTheme(e){const t=e||localStorage.getItem(I.themeInstalled);var e=t&&localStorage.getItem(t);t&&e&&(console.debug("Removing theme "+t),localStorage.removeItem(t),localStorage.removeItem(I.themeInstalled),e=N(I.installedThemes,[]).filter(e=>e!==t),localStorage.setItem(I.installedThemes,JSON.stringify(e)),console.debug("Removed"),this.fetchAndInjectUserCSS(null),this.props.updateActiveTheme(null),this.props.updateColourSchemes(null,null),ym.Config.current_theme="marketplace",ym.Config.color_scheme="marketplace",this.setState({installed:!1}))}installSnippet(){console.debug("Installing snippet "+this.localStorageKey),localStorage.setItem(this.localStorageKey,JSON.stringify({code:this.props.item.code,title:this.props.item.title,description:this.props.item.description,imageURL:this.props.item.imageURL}));var e=N(I.installedSnippets,[]),e=(-1===e.indexOf(this.localStorageKey)&&(e.push(this.localStorageKey),localStorage.setItem(I.installedSnippets,JSON.stringify(e))),e.map(e=>N(e)));po(e),this.setState({installed:!0})}removeSnippet(){localStorage.removeItem(this.localStorageKey);var e=N(I.installedSnippets,[]).filter(e=>e!==this.localStorageKey),e=(localStorage.setItem(I.installedSnippets,JSON.stringify(e)),e.map(e=>N(e)));po(e),this.setState({installed:!1})}async fetchAndInjectUserCSS(e){try{var t=window.sessionStorage.getItem("marketplace-request-tld")||void 0,a=e?await yo(this.props.item,t):void 0;vo(a)}catch(e){console.warn(e)}}openReadme(){this.props.item?.manifest?.readme?ym.Platform.History.push({pathname:Pa+"/readme",state:{data:{title:this.props.item.title,user:this.props.item.user,repo:this.props.item.repo,branch:this.props.item.branch,readmeURL:this.props.item.readmeURL,type:this.props.type,install:this.buttonClicked.bind(this),isInstalled:this.isInstalled.bind(this)}}}):ym.showNotification(y("notifications.noReadmeFile"),!0)}render(){var e,t,a=this.isInstalled();return"Installed"!==this.props.CONFIG.activeTab||a?(e=["main-card-card","marketplace-card--"+this.props.type],a&&e.push("marketplace-card--installed"),t=[],"snippet"!==this.props.type&&this.props.visual.stars&&t.push("★ "+this.state.stars),S.default.createElement("div",{className:e.join(" "),onClick:()=>{if("snippet"===this.props.type){var e=this.props.item.title.replace(/\n/g,"");if(N("marketplace:installed:snippet:"+e)?.custom)return lm("EDIT_SNIPPET",void 0,void 0,this.props);lm("VIEW_SNIPPET",void 0,void 0,this.props,this.buttonClicked.bind(this))}else this.openReadme()}},S.default.createElement("div",{className:"main-card-draggable",draggable:"true"},S.default.createElement("div",{className:"main-card-imageContainer"},S.default.createElement("div",{className:"main-cardImage-imageWrapper"},S.default.createElement("div",null,S.default.createElement("img",{alt:"","aria-hidden":"false",draggable:"false",loading:"lazy",src:this.props.item.imageURL,className:"main-image-image main-cardImage-image",onError:e=>{e.currentTarget.setAttribute("src","data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII"),e.currentTarget.closest(".main-cardImage-imageWrapper")?.classList.add("main-cardImage-imageWrapper--error")}})))),S.default.createElement("div",{className:"main-card-cardMetadata"},S.default.createElement("a",{draggable:"false",title:"snippet"===this.props.type?this.props.item.title:this.props.item.manifest?.name,className:"main-cardHeader-link",dir:"auto",href:"snippet"!==this.props.type?this.state.externalUrl:"https://github.com/spicetify/marketplace/blob/main/resources/snippets.json",target:"_blank",rel:"noopener noreferrer",onClick:e=>e.stopPropagation()},S.default.createElement("div",{className:"main-cardHeader-text main-type-balladBold"},this.props.item.title)),S.default.createElement("div",{className:"main-cardSubHeader-root main-type-mestoBold marketplace-cardSubHeader"},this.props.item.authors&&S.default.createElement(fm,{authors:this.props.item.authors}),S.default.createElement("span",null,t.join(" ‒ "))),S.default.createElement("p",{className:"marketplace-card-desc"},"snippet"===this.props.type?this.props.item.description:this.props.item.manifest?.description),this.props.item.lastUpdated&&S.default.createElement("p",{className:"marketplace-card-desc"},y("grid.lastUpdated",{val:new Date(this.props.item.lastUpdated),formatParams:{val:{year:"numeric",month:"long",day:"numeric"}}})),this.tags.length?S.default.createElement("div",{className:"marketplace-card__bottom-meta main-type-mestoBold"},S.default.createElement(vm,{tags:this.tags,showTags:this.props.CONFIG.visual.tags})):null,a&&S.default.createElement("div",{className:"marketplace-card__bottom-meta main-type-mestoBold"},"✓ ",y("grid.installed")),S.default.createElement(si,{label:"app"===this.props.type?y("github"):y(a?"remove":"install"),renderInline:!0},S.default.createElement("div",{className:"main-card-PlayButtonContainer"},S.default.createElement(Go,{classes:["marketplace-installButton"],type:"circle",label:"app"===this.props.type?y("github"):y(a?"remove":"install"),onClick:e=>{e.stopPropagation(),this.buttonClicked()}},"app"===this.props.type?S.default.createElement(pm,null):a?S.default.createElement(hm,null):S.default.createElement(dm,null)))))))):(console.debug("Card item not installed"),null)}},wm=Aa()(Sm),km=t(a()),Em=()=>km.default.createElement("svg",{style:{marginTop:"60px"},width:"100px",height:"100px",viewBox:"0 0 100 100",preserveAspectRatio:"xMidYMid",role:"img","aria-label":"Loading Icon"},km.default.createElement("circle",{cx:"50",cy:"50",r:"0",fill:"none",stroke:"currentColor",strokeWidth:"2"},km.default.createElement("animate",{attributeName:"r",repeatCount:"indefinite",dur:"1s",values:"0;40",keyTimes:"0;1",keySplines:"0 0.2 0.8 1",calcMode:"spline",begin:"0s"}),km.default.createElement("animate",{attributeName:"opacity",repeatCount:"indefinite",dur:"1s",values:"1;0",keyTimes:"0;1",keySplines:"0.2 0 0.8 1",calcMode:"spline",begin:"0s"})),km.default.createElement("circle",{cx:"50",cy:"50",r:"0",fill:"none",stroke:"currentColor",strokeWidth:"2"},km.default.createElement("animate",{attributeName:"r",repeatCount:"indefinite",dur:"1s",values:"0;40",keyTimes:"0;1",keySplines:"0 0.2 0.8 1",calcMode:"spline",begin:"-0.5s"}),km.default.createElement("animate",{attributeName:"opacity",repeatCount:"indefinite",dur:"1s",values:"1;0",keyTimes:"0;1",keySplines:"0.2 0 0.8 1",calcMode:"spline",begin:"-0.5s"}))),Cm=t(a()),Im=class extends Cm.default.Component{render(){return Cm.default.createElement("button",{style:{marginTop:"60px",border:"none",backgroundColor:"transparent",cursor:"pointer"},onClick:this.props.onClick},Cm.default.createElement("p",{style:{fontSize:100,lineHeight:"65px"}},"»"),Cm.default.createElement("span",{style:{fontSize:20}},"Load more"))}},xm=t(a()),Nm=()=>xm.default.createElement("svg",{role:"img",width:"16",height:"16",viewBox:"0 0 24 24","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg"},xm.default.createElement("path",{d:"M24 13.616v-3.232c-1.651-.587-2.694-.752-3.219-2.019v-.001c-.527-1.271.1-2.134.847-3.707l-2.285-2.285c-1.561.742-2.433 1.375-3.707.847h-.001c-1.269-.526-1.435-1.576-2.019-3.219h-3.232c-.582 1.635-.749 2.692-2.019 3.219h-.001c-1.271.528-2.132-.098-3.707-.847l-2.285 2.285c.745 1.568 1.375 2.434.847 3.707-.527 1.271-1.584 1.438-3.219 2.02v3.232c1.632.58 2.692.749 3.219 2.019.53 1.282-.114 2.166-.847 3.707l2.285 2.286c1.562-.743 2.434-1.375 3.707-.847h.001c1.27.526 1.436 1.579 2.019 3.219h3.232c.582-1.636.75-2.69 2.027-3.222h.001c1.262-.524 2.12.101 3.698.851l2.285-2.286c-.744-1.563-1.375-2.433-.848-3.706.527-1.271 1.588-1.44 3.221-2.021zm-12 2.384c-2.209 0-4-1.791-4-4s1.791-4 4-4 4 1.791 4 4-1.791 4-4 4z",fill:"currentColor"})),Am=t(a()),Tm=()=>Am.default.createElement("svg",{className:"devtools-icon",version:"1.1",viewBox:"1 1 22 22",xmlSpace:"preserve",xmlns:"http://www.w3.org/2000/svg",role:"img","aria-label":"Developer Tools Icon"},Am.default.createElement("g",{className:"devtools-icon-internal",id:"grid_system"}),Am.default.createElement("g",{id:"_icons"},Am.default.createElement("path",{d:"M18,12v-0.9l0.7-5.7C18.8,4.5,18.6,3.7,18,3c-0.6-0.6-1.4-1-2.2-1H8.3C7.4,2,6.6,2.4,6,3C5.4,3.7,5.2,4.5,5.3,5.4L6,11.1 V12c0,1.6,1.3,2.9,2.8,3l-0.4,2.9c-0.1,1,0.2,2.1,0.8,2.9S11,22,12,22s2-0.5,2.7-1.2s1-1.8,0.8-2.9L15.2,15 C16.7,14.9,18,13.6,18,12z M7.5,4.3C7.7,4.1,8,4,8.3,4H13v2c0,0.6,0.4,1,1,1s1-0.4,1-1V4h0.7c0.3,0,0.6,0.1,0.8,0.3 c0.2,0.2,0.3,0.5,0.2,0.8L16.1,10H7.9L7.3,5.1C7.2,4.8,7.3,4.6,7.5,4.3z M13.2,19.4c-0.6,0.7-1.8,0.7-2.4,0 c-0.3-0.4-0.4-0.8-0.4-1.3l0.5-3.2h2.3l0.5,3.2C13.7,18.6,13.5,19.1,13.2,19.4z M15,13h-1h-4H9c-0.6,0-1-0.4-1-1h8 C16,12.6,15.6,13,15,13z"}))),w=t(a()),Om=t(Be()),Lm=Aa()(class extends w.default.Component{render(){var e=this.props["t"];return this.props.item.enabled?w.default.createElement("li",{className:"marketplace-tabBar-headerItem","data-tab":this.props.item.value,onClick:e=>{e.preventDefault(),this.props.switchTo(this.props.item)}},w.default.createElement("a",{"aria-current":"page",className:"marketplace-tabBar-headerItemLink "+(this.props.item.active?"marketplace-tabBar-active":""),draggable:"false",href:"##"},w.default.createElement("span",{className:"main-type-mestoBold"},e("tabs."+this.props.item.value)))):null}}),Dm=w.default.memo(function({items:e,switchTo:t}){return w.default.createElement("li",{className:"marketplace-tabBar-headerItem"},w.default.createElement(Om.default,{className:"main-type-mestoBold",options:e,value:"More",placeholder:"More",onChange:t}))}),Pm=e=>{const t=(0,w.useRef)(null),a=(0,w.useCallback)(()=>{var e=document.querySelector(".main-topBar-topbarContentWrapper");t?.current&&e?e.appendChild(t.current):setTimeout(a,100)},[t.current]);return(0,w.useEffect)(()=>(a(),()=>(t.current||document.querySelector(".marketplace-tabBar"))?.remove())),w.default.createElement(Mm,{ref:t,links:e.links,activeLink:e.activeLink,switchCallback:e.switchCallback})},Mm=w.default.forwardRef(({links:e,activeLink:a,switchCallback:t},r)=>{const n=(0,w.useRef)(null),[o,i]=(0,w.useState)([0]),[s,l]=(0,w.useState)(0),[c,d]=(0,w.useState)([0]),u=e.map(({name:e,enabled:t})=>{return{label:e,value:e,active:e===a,enabled:t}});return(0,w.useEffect)(()=>{if(n.current){const e=new ResizeObserver(e=>l(e[0].contentRect.width));return e.observe(n.current),()=>{e.disconnect()}}},[n.current]),(0,w.useEffect)(()=>{var e;n.current&&(e=Array.from(n.current.children).map(e=>e.clientWidth),i(e))},[e]),(0,w.useEffect)(()=>{if(n.current)if(o.reduce((e,t)=>e+t,0)<=s)d([]);else{var e=Math.max(...o);const r=[];let a=e;o.forEach((e,t)=>{s>=a+e?a+=e:r.push(t)}),d(r)}},[s,o]),w.default.createElement("nav",{className:"marketplace-tabBar marketplace-tabBar-nav",ref:r},w.default.createElement("ul",{className:"marketplace-tabBar-header",ref:n},u.filter((e,t)=>!c.includes(t)).map(e=>w.default.createElement(Lm,{key:e.value,item:e,switchTo:t})),c.length||0===o.length?w.default.createElement(Dm,{items:c.map(e=>u[e]).filter(e=>e),switchTo:t}):null))}),Rm=window.Spicetify,_m=Aa()(class extends o.default.Component{constructor(e){super(e),Object.assign(this,e),this.updateAppConfig=e.updateAppConfig.bind(this),this.sortConfig={by:N(I.sort,"top")},this.state={version:Oa,newUpdate:!1,searchValue:"",cards:[],tabs:e.CONFIG.tabs,rest:!0,endOfList:!1,schemes:e.CONFIG.theme.schemes,activeScheme:e.CONFIG.theme.activeScheme,activeThemeKey:e.CONFIG.theme.activeThemeKey}}searchRequested;endOfList=!1;lastScroll=0;requestQueue=[];requestPage=0;cardList=[];sortConfig;gridUpdateTabs;gridUpdatePostsVisual;checkScroll;CONFIG;updateAppConfig;BLACKLIST;SNIPPETS;getInstalledTheme(){var e=localStorage.getItem(I.themeInstalled);return(e=e&&localStorage.getItem(e))?JSON.parse(e):null}newRequest(e){this.cardList=[];var t=[];this.requestQueue.unshift(t),this.loadAmount(t,e)}appendCard(e,t,a){a===this.props.CONFIG.activeTab&&(a=o.default.createElement(wm,{item:e,key:`${this.props.CONFIG.activeTab}:${e.user}:`+e.title,CONFIG:this.CONFIG,visual:this.props.CONFIG.visual,type:t,activeThemeKey:this.state.activeThemeKey,updateColourSchemes:this.updateColourSchemes.bind(this),updateActiveTheme:this.setActiveTheme.bind(this)}),this.cardList.push(a))}updateSort(e){e&&(this.sortConfig.by=e,localStorage.setItem(I.sort,e)),this.requestPage=0,this.cardList=[],this.setState({cards:[],rest:!1,endOfList:!1}),this.endOfList=!1,this.newRequest(Da)}updateTabs(){this.setState({tabs:[...this.props.CONFIG.tabs]})}updatePostsVisual(){this.cardList=this.cardList.map((e,t)=>o.default.createElement(wm,{...e.props,key:t.toString(),CONFIG:this.CONFIG})),this.setState({cards:[...this.cardList]})}switchTo(e){this.CONFIG.activeTab=e.value,localStorage.setItem(I.activeTab,e.value),this.cardList=[],this.requestPage=0,this.setState({cards:[],rest:!1,endOfList:!1}),this.endOfList=!1,this.newRequest(Da)}async loadPage(e){var t=this.CONFIG.activeTab;switch(t){case"Extensions":var a=await Ao("spicetify-extensions",this.requestPage,this.BLACKLIST,this.CONFIG.visual.showArchived),r=[];for(const g of a.items){var n=await Lo(g.contents_url,g.default_branch,g.stargazers_count,this.CONFIG.visual.hideInstalled);if(1({...e,archived:g.archived,lastUpdated:g.pushed_at,created:g.created_at})))}No(r,localStorage.getItem("marketplace:sort")||"stars");for(const f of r)this.appendCard(f,"extension",t);this.setState({cards:this.cardList});var o=-1({...e,archived:S.archived,lastUpdated:S.pushed_at,created:S.created_at})))}this.setState({cards:this.cardList}),No(u,localStorage.getItem("marketplace:sort")||"stars");for(const w of u)this.appendCard(w,"theme",t);a=-1({...e,archived:k.archived,lastUpdated:k.pushed_at,created:k.created_at})))}this.setState({cards:this.cardList}),No(m,localStorage.getItem("marketplace:sort")||"stars");for(const E of m)this.appendCard(E,"app",t);i=-1e!==t):(this.requestQueue.shift(),this.setState({rest:!0}))}loadMore(){this.state.rest&&!this.endOfList&&this.loadAmount(this.requestQueue[0],Da)}updateColourSchemes(e,t){console.debug("updateColourSchemes",e,t),this.CONFIG.theme.schemes=e,(this.CONFIG.theme.activeScheme=t)&&(Rm.Config.color_scheme=t),e&&t&&e[t]?bo(this.CONFIG.theme.schemes[t]):bo(null);var a=N(I.themeInstalled),r=N(a);r?(r.activeScheme=t,console.debug(r),localStorage.setItem(a,JSON.stringify(r))):console.debug("No installed theme data"),this.setState({schemes:e,activeScheme:t})}async componentDidMount(){fetch(Ra).then(e=>e.json()).then(e=>{if(e.message)throw e;this.setState({version:e.name});try{this.setState({newUpdate:Ta.default.gt(e.name,Oa)})}catch(e){console.error(e)}},e=>{console.error("Failed to check for updates",e)}),this.gridUpdateTabs=this.updateTabs.bind(this),this.gridUpdatePostsVisual=this.updatePostsVisual.bind(this);var e=document.querySelector(".os-viewport")??document.querySelector("#main .main-view-container__scroll-node");this.checkScroll=this.isScrolledBottom.bind(this),e&&(e.addEventListener("scroll",this.checkScroll),this.cardList.length)?0=e.scrollHeight&&this.loadMore()}setActiveTheme(e){this.CONFIG.theme.activeThemeKey=e,this.setState({activeThemeKey:e})}getActiveScheme(){return this.state.activeScheme}render(){const a=this.props["t"];return o.default.createElement("section",{className:"contentSpacing"},o.default.createElement("div",{className:"marketplace-header"},o.default.createElement("div",{className:"marketplace-header__left"},this.state.newUpdate?o.default.createElement("button",{type:"button",title:a("grid.newUpdate"),className:"marketplace-header-icon-button",id:"marketplace-update",onClick:()=>lm("UPDATE")},o.default.createElement(dm,null)," ",this.state.version):null,o.default.createElement("h2",{className:"marketplace-header__label"},a("grid.sort.label")),o.default.createElement(Xo,{onChange:e=>this.updateSort(e),sortBoxOptions:go(a),sortBySelectedFn:e=>e.key===this.CONFIG.sort})),o.default.createElement("div",{className:"marketplace-header__right"},this.CONFIG.visual.themeDevTools?o.default.createElement(si,{label:a("devTools.title"),renderInline:!0,placement:"bottom"},o.default.createElement("button",{type:"button","aria-label":a("devTools.title"),className:"marketplace-header-icon-button",onClick:()=>lm("THEME_DEV_TOOLS")},o.default.createElement(Tm,null))):null,this.state.activeScheme?o.default.createElement(Xo,{onChange:e=>this.updateColourSchemes(this.state.schemes,e),sortBoxOptions:ho(this.state.schemes),sortBySelectedFn:e=>e.key===this.getActiveScheme()}):null,o.default.createElement("div",{className:"searchbar--bar__wrapper"},o.default.createElement("input",{className:"searchbar-bar",type:"text",placeholder:`${a("grid.search")} ${a("tabs."+this.CONFIG.activeTab)}...`,value:this.state.searchValue,onChange:e=>{this.setState({searchValue:e.target.value})}})),o.default.createElement(si,{label:a("settings.title"),renderInline:!0,placement:"bottom"},o.default.createElement("button",{type:"button","aria-label":a("settings.title"),className:"marketplace-header-icon-button",id:"marketplace-settings-button",onClick:()=>lm("SETTINGS",this.CONFIG,this.updateAppConfig)},o.default.createElement(Nm,null))))),[{handle:"extension",name:"Extensions"},{handle:"theme",name:"Themes"},{handle:"snippet",name:"Snippets"},{handle:"app",name:"Apps"}].map(t=>{var e=this.cardList.filter(e=>e.props.type===t.handle).filter(e=>{const t=this.state.searchValue.trim().toLowerCase();var{title:e,user:a,authors:r,tags:n}=e.props.item;return!t||e.toLowerCase().includes(t)||a?.toLowerCase().includes(t)||r?.some(e=>e.name.toLowerCase().includes(t))||[...n??[]].some(e=>e.toLowerCase().includes(t))}).map(e=>o.default.cloneElement(e,{activeThemeKey:this.state.activeThemeKey,key:e.key})).filter((t,e,a)=>a.findIndex(e=>e.key===t.key)===e);return e.length?o.default.createElement("div",{className:"marketplace-content"},o.default.createElement("h2",{className:"marketplace-card-type-heading"},a("tabs."+t.name)),o.default.createElement("div",{className:"marketplace-grid main-gridContainer-gridContainer main-gridContainer-fixedWidth","data-tab":this.CONFIG.activeTab,"data-card-type":a("tabs."+t.name)},e)):null}),"Snippets"===this.CONFIG.activeTab?o.default.createElement(Go,{classes:["marketplace-add-snippet-btn"],onClick:()=>lm("ADD_SNIPPET")},"+ ",a("grid.addCSS")):null,o.default.createElement("footer",{className:"marketplace-footer"},this.state.endOfList?o.default.createElement("div",{style:{height:"64px"}}):this.state.rest&&0${this.props.t("readmePage.loading")}

`};getReadmeHTML=async()=>fetch(this.props.data.readmeURL).then(e=>{if(e.ok)return e.text();throw Spicetify.showNotification(`${this.props.t("readmePage.errorLoading")} (HTTP ${e.status})`,!0)}).then(e=>wo(e,this.props.data.user,this.props.data.repo)).then(e=>(e||Spicetify.Platform.History.goBack(),e)).catch(e=>(console.error(e),Spicetify.Platform.History.goBack(),null));componentDidMount(){this.getReadmeHTML().then(e=>{null!=e&&this.setState({html:e})})}componentDidUpdate(){const e=document.querySelector("#marketplace-readme")?.closest("main");if(e){const t=setInterval(()=>{document.querySelector("#marketplace-readme")?(e.style.overflowY="visible",e.style.overflowY="auto"):(clearInterval(t),e.style.removeProperty("overflow-y"))},1e3)}document.querySelectorAll("#marketplace-readme img").forEach(e=>{e.addEventListener("error",e=>{var e=e.target,t=e.getAttribute("src"),t="/"===t?.charAt(0)?`https://raw.githubusercontent.com/${this.props.data.user}/${this.props.data.repo}/${this.props.data.branch}/`+t?.slice(1):this.props.data.readmeURL.substring(0,this.props.data.readmeURL.lastIndexOf("/"))+"/"+t;e.setAttribute("src",t)},{once:!0})})}buttonContent(){return"app"===this.props.data.type?{icon:Bm.default.createElement(pm,null),text:this.props.t("github")}:this.state.isInstalled?{icon:Bm.default.createElement(hm,null),text:this.props.t("remove")}:{icon:Bm.default.createElement(dm,null),text:this.props.t("install")}}render(){var e="control"!==JSON.parse(localStorage.getItem("spicetify-exp-features")||"{}").enableGlobalNavBar?.value&&!0;return Bm.default.createElement("section",{className:"contentSpacing"},Bm.default.createElement("div",{className:"marketplace-header",style:{marginTop:e?"60px":"0px"}},Bm.default.createElement("div",{className:"marketplace-header__left"},Bm.default.createElement("h1",null,this.props.title)),Bm.default.createElement("div",{className:"marketplace-header__right"},Bm.default.createElement(Go,{classes:["marketplace-header__button"],onClick:e=>{e.preventDefault(),this.props.data.install(),this.setState({isInstalled:!this.state.isInstalled})},label:this.buttonContent().text},this.buttonContent().icon," ",this.buttonContent().text))),"

Loading...

"===this.state.html?Bm.default.createElement("footer",{className:"marketplace-footer"},Bm.default.createElement(Em,null)):Bm.default.createElement("div",{id:"marketplace-readme",className:"marketplace-readme__container",dangerouslySetInnerHTML:{__html:this.state.html}}))}}),Fn={ar:{translation:{settings:{title:"إعدادات المتجر",optionsHeading:"خيارات",starCountLabel:"عدد النجوم",tagsLabel:"العلامات",showArchived:"إظهار المستودعات المؤرشفة",devToolsLabel:"أدوات مطوري السمات",hideInstalledLabel:"إخفاء المثبتة عند التصفح",colourShiftLabel:"تغيير الألوان كل دقيقة",albumArtBasedColors:"تغيير الألوان بناءً على غلاف الألبوم",albumArtBasedColorsMode:"وضع نظام الألوان (واجهة برمجة التطبيقات الملونة (API))",albumArtBasedColorsVibrancy:"اللون المأخوذ من غلاف الألبوم",albumArtBasedColorsVibrancyToolTip:"مشبع قليلًا: اللون الأكثر بروزًا ولكن مع سطوع أقل بكثير \n ساطع خفيف: اللون الأكثر حيوية ولكن مع زيادة السطوع قليلًا \n بارز: اللون الأكثر بروزًا في غلاف الألبوم \n حيوي: اللون الأكثر حيوية في غلاف الألبوم",albumArtColorsModeToolTip:"أحادي اللون الداكن: نظام ألوان يعتمد بشكل مباشر على اللون الرئيسي المحدد، باستخدام ظلال مختلفة من اللون الرئيسي ودمج درجات الرمادي لإنشاء نظام ألوان، وهذا هو عكس نظام أحادي اللون الفاتح. \n أحادي اللون الفاتح: نظام ألوان يعتمد بشكل مباشر على اللون الرئيسي المحدد، باستخدام ظلال مختلفة من اللون الرئيسي ودمج درجات الرمادي لإنشاء نظام ألوان. ستكون خلفية أحادي اللون الفاتح هي لون المقدمة أو النص في نظام أحادي اللون الداكن والعكس صحيح. \n تناظري: نظام ألوان يعتمد على اللون الرئيسي المحدد، باستخدام الألوان المجاورة للون الرئيسي على عجلة الألوان. \n تناظري تكميلي: نظام ألوان يعتمد على اللون الرئيسي المحدد، باستخدام الألوان المجاورة للون الرئيسي على عجلة الألوان واللون التكميلي. \n ثلاثي: نظام ألوان يعتمد على اللون الرئيسي المحدد، باستخدام الألوان الموجودة على عجلة الألوان والتي تكون متساوية البعد عن اللون الرئيسي. \n رباعي: نظام ألوان يعتمد على اللون الرئيسي المحدد، باستخدام الألوان الموجودة على عجلة الألوان والتي تبعد 90 درجة عن اللون الرئيسي.",tabsHeading:"علامات التبويب",tabsDescription:"اسحب وأفلت لإعادة الترتيب، انقر للتمكين/التعطيل",resetHeading:"إعادة الضبط",resetBtn:"$t(settings.resetHeading)",resetDescription:"إلغاء تثبيت جميع الإضافات والسمات، وإعادة ضبط التفضيلات",backupHeading:"نسخ احتياطي/استعادة",backupLabel:"نسخ احتياطي أو استعادة جميع بيانات المتجر. لا يتضمن ذلك إعدادات أي شيء تم تثبيته عبر المتجر.",backupBtn:"فتح",versionHeading:"الإصدار",versionBtn:"نسخ",versionCopied:"تم النسخ"},tabs:{Extensions:"الإضافات",Themes:"السمات",Snippets:"المقتطفات",Apps:"التطبيقات",Installed:"المثبتة"},snippets:{addTitle:"إضافة مقتطف",duplicateName:"هذا الاسم مستخدم بالفعل!",editTitle:"تعديل مقتطف",viewTitle:"عرض مقتطف",customCSS:"CSS مخصص",customCSSPlaceholder:"أدخل CSS المخصص الخاص بك هنا! يمكنك العثور عليها في علامة التبويب المثبتة للإدارة.",snippetName:"اسم المقتطف",snippetNamePlaceholder:"أدخل اسمًا للمقتطف المخصص الخاص بك",snippetDesc:"وصف المقتطف",snippetDescPlaceholder:"أدخل وصفًا للمقتطف المخصص الخاص بك",snippetPreview:"معاينة المقتطف",optional:"اختياري",addImage:"إضافة صورة",changeImage:"تغيير الصورة",saveCSS:"حفظ CSS"},reloadModal:{title:"إعادة التحميل",description:"يجب إعادة تحميل الصفحة لإكمال هذه العملية.",reloadNow:"إعادة التحميل الآن",reloadLater:"إعادة التحميل لاحقًا"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"تم نسخ الإعدادات إلى الحافظة",noDataPasted:"لم يتم لصق أي بيانات",invalidJSON:"JSON غير صالح",inputLabel:"إعدادات المتجر",inputPlaceholder:"انسخ/ألصق إعداداتك هنا",exportBtn:"تصدير",importBtn:"استيراد",fileImportBtn:"استيراد من ملف"},devTools:{title:"أدوات تطوير السمات",noThemeInstalled:"خطأ: لم يتم تثبيت أي سمة من المتجر",noThemeManifest:"خطأ: لم يتم العثور على بيان السمة",colorIniEditor:"محرر Color.ini",colorIniEditorPlaceholder:"[اسم-نظام-الألوان-الخاص-بك]",invalidCSS:"CSS غير صالح"},updateModal:{title:"تحديث المتجر",description:"قم بتحديث متجر سبياسيتيفي لتلقي ميزات جديدة وإصلاح الأخطاء.",currentVersion:"الإصدار الحالي: {{إصدار}}",latestVersion:"أحدث إصدار: {{إصدار}}",whatsChanged:"ما الذي تغير",seeChangelog:"عرض سجل التغييرات",howToUpgrade:"كيفية الترقية",viewGuide:"عرض الدليل"},grid:{spicetifyMarketplace:"متجر سبياسيتيفي",newUpdate:"تحديث جديد",addCSS:"إضافة CSS",search:"بحث",installed:"مثبتة",lastUpdated:"آخر تحديث {{val, datetime}}",externalJS:"JS خارجي",archived:"مؤرشفة",dark:"داكن",light:"فاتح",sort:{label:"فرز حسب:",stars:"النجوم",newest:"الأحدث",oldest:"الأقدم",lastUpdated:"آخر تحديث",mostStale:"الأكثر تقادمًا",aToZ:"أ-ي",zToA:"ي-أ"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - اقرأني",loading:"جارٍ التحميل...",errorLoading:"README خطأ في تحميل ملف اقرأني"},github:"غيثب",install:"تثبيت",remove:"إزالة",save:"حفظ",colour_one:"لون",colour_other:"ألوان",favourite:"مفضل",notifications:{wrongLocalTheme:"يُرجى ضبط السمة الحالية في config-xpui.ini على ” المتجر“ لتثبيت السمات باستخدام المتجر",tooManyRequests:"عدد كبير جدًا من الطلبات، يرجى الانتظار",noCdnConnection:"المتجر غير قادر على الاتصال بشبكة CDN. يرجى التحقق من إعدادات الإنترنت الخاصة بك",markdownParsingError:"خطأ في تحليل Markdown (HTTP {{status}})",noReadmeFile:"لم يتم العثور على ملف اقرأني README",themeInstallationError:"حدث خطأ أثناء تثبيت السمة",extensionInstallationError:"حدث خطأ أثناء تثبيت الإضافة"}}},ca:{translation:{settings:{title:"Configuració",optionsHeading:"Opcions",starCountLabel:"Número d'estrelles",tagsLabel:"Etiquetes",devToolsLabel:"Eines per a desenvolupadors de temes",hideInstalledLabel:"Amagar instal·lats",colourShiftLabel:"Canviar colors cada minut",albumArtBasedColors:"Canviar colors a partir de la portada de l'àlbum",albumArtBasedColorsMode:"Mode esquema de colors (ColorApi)",albumArtBasedColorsVibrancy:"Colors agafats de la portada de l'àlbum",albumArtBasedColorsVibrancyToolTip:"Desaturat:El color més destacat però amb molta menys bror \n Vibrant Clar: El color més villantibrant amb la brillantor augmentada una mica \n Prominent: El color més destacat a la portada de l'Àlbum \n Vibrant: El color més vibrant a la portada de l'Àlbum",albumArtColorsModeToolTip:"Monochrome Dark: Un esquema de colors basat en el color principal seleccionat, emprant diferentes tonalitats i barrejant tons grisos per crear l'esquema de colors, aquest és l'invers de Monochrome Light. \n Monochrome Light: Un esquema de colors basat en el color principal seleccionat, emprant diferentes tonalitats i barrejant tons grisos per crear l'esquema de colors. El colors del fins de Monochrome light seria el color de primer pla en Monochrome Dark i viceversa. \n Analògic: Un esquema de colors basat en el color principal seleccionat, emprant els colors adjacents en la roda de colors. \n Analògic Complementari: Un esquema de colors basat en el color principal seleccionat, emprant els colors adjacents en la roda de colors i el color complementari. \n Tríada: Un esquema de colors basat en el color principal seleccionat, emprant els colors de la roda de colors que estan separats de manera equidistant del color principal. \n Quad: Un esquema de colors basat en el color principal seleccionat, emprant els colors que es troben separats 90 graus entre si en la roda de colors.",tabsHeading:"Pestanyes",tabsDescription:"Arrossegueu i deixeu anar per canviar l'ordre, feu clic per activar/desactivar",resetHeading:"Restablir",resetBtn:"$t(settings.resetHeading)",resetDescription:"Borrar totes les extensions, temes i preferències",backupHeading:"Fer una còpia/Reestablir des d'una còpia",backupLabel:"Fer una còpia o restablir totes les dades de Marketplace des d'una còpia. Això no inclou la configuració per els elements instal·lats amb Marketplace.",backupBtn:"Obrir",versionHeading:"Versió",versionBtn:"Copiar",versionCopied:"Copiat"},tabs:{Extensions:"Extensions",Themes:"Temes",Snippets:"Fragments",Apps:"Aplicacions",Installed:"Instal·lats"},snippets:{addTitle:"Afegir fragment",editTitle:"Editar fragment",viewTitle:"Veure fragment",customCSS:"CSS personalitzat",customCSSPlaceholder:"Crea el teu propi CSS aqui! Pots trobar-los a la pestanya d'instal·lats per administrar-los.",snippetName:"Nom del fragment de codi",snippetNamePlaceholder:"Afegeix un nom al teu codi personalitzat",snippetDesc:"Descripció del codi",snippetDescPlaceholder:"Crea una descripció per al teu codi personalitzat",snippetPreview:"Vista prèvia del fragment",optional:"Opcional",addImage:"Afegir imatge",changeImage:"Canviar imatge",saveCSS:"Guardar CSS"},reloadModal:{title:"Recarregar",description:"És necessari recarregar la finestra per completar aquesta operació.",reloadNow:"Fes-ho ara",reloadLater:"Després"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Configuració copiada al portapapers",noDataPasted:"No s'han enganxat dades",invalidJSON:"JSON invàlid",inputLabel:"Configuració de Marketplace",inputPlaceholder:"Còpia/enganxa la teva configuració aquí",exportBtn:"Exportar",importBtn:"Importar",fileImportBtn:"Importar des d'un arxiu"},devTools:{title:"Eines de desenvolupador de temes",noThemeInstalled:"Error: No hi ha cap tema de Marketplace instal·lat",noThemeManifest:"Error: No s'ha trobat el manifest",colorIniEditor:"Editor de Color.ini",colorIniEditorPlaceholder:"[nom-de-esquema-de-color]",invalidCSS:"CSS invàlid"},grid:{spicetifyMarketplace:"Marketplace de Spicetify",newUpdate:"Nova Actualització",addCSS:"Afegir CSS",search:"Buscar",installed:"Instal·lat",lastUpdated:"Última actualizació {{val, datetime}}",externalJS:"JS extern",dark:"fosc",light:"clar"},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Carregant...",errorLoading:"Error carregant el README"},github:"GitHub",install:"Instal·lar",remove:"Borrar",save:"Guardar",colour_one:"color",colour_other:"colors",favourite:"preferit"}},"de-DE":{translation:{settings:{title:"Marketplace Einstellungen",optionsHeading:"Optionen",starCountLabel:"Sterne Anzahl",tagsLabel:"Schlagwörter",showArchived:"Archivierte repos anzeigen",devToolsLabel:"Design Entwicklerwerkzeuge",hideInstalledLabel:"Versteckt installierte beim durchsuchen",colourShiftLabel:"Jede Minute Farbe wechseln",albumArtBasedColors:"Farbe basierend auf Album Cover wechseln",albumArtBasedColorsMode:"Farbschema (ColorApi) Modus",albumArtBasedColorsVibrancy:"Farbe vom Album Cover übernommen",albumArtBasedColorsVibrancyToolTip:"Entsättigt: Die am stärksten ausgeprägte Farbe, aber mit viel weniger Helligkeit \n Leicht lebhaft: Die am stärksten leuchtende Farbe, aber mit etwas mehr Helligkeit \n Prominent: Die Farbe, die im Albumcover am stärksten hervortritt \n Lebendig: Die lebendigste Farbe im Albumcover",albumArtColorsModeToolTip:"Monochrom Dunkel: Ein Farbschema, das direkt auf der ausgewählten Hauptfarbe basiert, wobei verschiedene Schattierungen der Hauptfarbe verwendet und Grautöne beigemischt werden, um ein Farbschema zu erstellen; dies ist das Gegenteil von Monochrom Hell. \n Monochrom Hell: Ein Farbschema, das direkt auf der ausgewählten Hauptfarbe basiert, wobei verschiedene Schattierungen der Hauptfarbe verwendet und Grautöne beigemischt werden, um ein Farbschema zu erstellen. Der Hintergrund von Monochrom hell wäre die Vordergrund- oder Textfarbe bei Monochrom dunkel und umgekehrt. \n Analogisch: Ein Farbschema, das auf der ausgewählten Hauptfarbe basiert und die Farben verwendet, die auf dem Farbkreis neben der Hauptfarbe liegen. \n Analogisch Komplementär: Ein Farbschema, das auf der ausgewählten Hauptfarbe basiert, wobei die Farben neben der Hauptfarbe auf dem Farbkreis und die Komplementärfarbe verwendet werden. \n Dreiklang: Ein Farbschema auf der Grundlage der ausgewählten Hauptfarbe, bei dem die Farben auf dem Farbkreis verwendet werden, die gleich weit von der Hauptfarbe entfernt sind. \n Vierer: Ein Farbschema auf der Grundlage der ausgewählten Hauptfarbe, bei dem die Farben auf dem Farbkreis verwendet werden, die 90 Grad von der Hauptfarbe entfernt sind.",tabsHeading:"Register",tabsDescription:"Ziehen und Ablegen zum Ändern der Reihenfolge, Klicken zum Aktivieren/Deaktivieren",resetHeading:"Zurücksetzen",resetBtn:"$t(settings.resetHeading)",resetDescription:"Deinstalliere alle Erweiterungen und Themes und setze Präferenzen zurück",backupHeading:"Sicherung erstellen / Wiederherstellen",backupLabel:"Sichern Sie alle Marketplace-Daten oder stellen Sie sie wieder her. Dies umfasst nicht die Einstellungen für alles, was über den Marketplace installiert wurde.",backupBtn:"Öffnen",versionHeading:"Version",versionBtn:"Kopieren",versionCopied:"Kopiert"},tabs:{Extensions:"Erweiterungen",Themes:"Designs",Snippets:"Snippets",Apps:"Apps",Installed:"Installiert"},snippets:{addTitle:"Snippet hinzufügen",duplicateName:"Dieser Name ist bereits vergeben!",editTitle:"Snippet bearbeiten",viewTitle:"Snippet ansehen",customCSS:"Benutzerdefiniertes CSS",customCSSPlaceholder:"Geben Sie hier Ihre eigenen benutzerdefinierten CSS ein! Sie finden sie auf der Registerkarte „Installiert“ für die Verwaltung.",snippetName:"Snippet Name",snippetNamePlaceholder:"Geben Sie einen Namen für ihr benutzerdefiniertes Snippet ein",snippetDesc:"Snippet Beschreibung",snippetDescPlaceholder:"Geben sie eine Beschreibung für ihr benutzerdefiniertes Snippet ein",snippetPreview:"Snippet Vorschau",optional:"Optional",addImage:"Foto hinzufügen",changeImage:"Foto ändern",saveCSS:"CSS speichern"},reloadModal:{title:"Neu laden",description:"Um diesen Vorgang abzuschließen, muss die Seite neu geladen werden.",reloadNow:"Jetzt neu laden",reloadLater:"Später neu laden"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Einstellungen in die Zwischenablage kopiert",noDataPasted:"Keine Daten eingefügt",invalidJSON:"Ungültiges JSON",inputLabel:"Marketplace Einstellungen",inputPlaceholder:"Kopieren Sie Ihre Einstellungen und fügen Sie sie hier ein",exportBtn:"Export",importBtn:"Import",fileImportBtn:"Von Datei importieren"},devTools:{title:"Design Entwicklerwerkzeug",noThemeInstalled:"Fehler: Kein Marketplace Design installed",noThemeManifest:"Fehler: Kein Design-Manifest gefunden",colorIniEditor:"Color.ini Bearbeitung",colorIniEditorPlaceholder:"[your-colour-scheme-name]",invalidCSS:"Ungültiges CSS"},updateModal:{title:"Aktualisieren Sie den Marketplace",description:"Aktualisieren Sie den Spicetify Marketplace um neue Funktionen und Fehlerbehebungen zu erhalten.",currentVersion:"Derzeitige Version: {{version}}",latestVersion:"Neueste Version: {{version}}",whatsChanged:"Was hat sich geändert?",seeChangelog:"Änderungsverlauf ansehen",howToUpgrade:"Wie man aktualisiert",viewGuide:"Anleitung ansehen"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Neues Update",addCSS:"CSS hinzufügen",search:"Suchen",installed:"Installiert",lastUpdated:"Zuletzt aktualisiert {{val, datetime}}",externalJS:"Externes JS",archived:"archiviert",dark:"dunkel",light:"hell",sort:{label:"Sortieren nach:",stars:"Sterne",newest:"Neueste",oldest:"Älteste",lastUpdated:"Zuletzt aktualisiert",mostStale:"Am abgestandensten",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Les mich",loading:"Laden...",errorLoading:"Fehler beim laden von README"},github:"GitHub",install:"Installieren",remove:"Entfernen",save:"Speichern",colour_one:"Farbe",colour_other:"Farben",favourite:"Favorit",notifications:{wrongLocalTheme:"Bitte setzen Sie current_theme in config-xpui.ini auf 'marketplace', um Themen über den Marketplace zu installieren",tooManyRequests:"Zu viele Anfragen, beruhigen Sie sich",noCdnConnection:"Marketplace kann sich nicht mit dem CDN verbinden. Bitte überprüfen Sie Ihre Internetkonfiguration",markdownParsingError:"Fehler beim Parsen von Markdown (HTTP {{status}})",noReadmeFile:"README wurde nicht gefunden",themeInstallationError:"Beim Installieren von einem Design ist ein Fehler aufgetreten",extensionInstallationError:"Beim Installieren einer Erweiterung ist ein Fehler aufgetreten"}}},"en-US":{translation:{settings:{colourShiftLabel:"Shift colors every minute",albumArtBasedColors:"Change colors based on album art",albumArtBasedColorsMode:"Color scheme (ColorApi) mode",albumArtBasedColorsVibrancy:"Color grabbed from album art",albumArtBasedColorsVibrancyToolTip:"Desaturated: The color that is the most prominent but with much less brightness \n Light Vibrant: The most Vibrant color but with the brightness amped up a tad \n Prominent: The color that pops the most in the album art \n Vibrant: The most vibrant color in the album art",albumArtColorsModeToolTip:"Monochrome Dark: A color scheme based directly on the main color selected, using different shades of the main color and mixing in greys to create a color scheme, this is the inverse of Monochrome Light. \n Monochrome Light: A color scheme based directly on the main color selected, using different shades of the main color and mixing in greys to create a color scheme. The background of monochrome light would be the foreground or text color on Monochrome Dark and vice versa. \n Analogic: A color scheme based on the main color selected, using the colors adjacent to the main color on the color wheel. \n Analogic Complementary: A color scheme based on the main color selected, using the colors adjacent to the main color on the color wheel and the complementary color. \n Triad: A color scheme based on the main color selected, using the colors on the color wheel that are equidistant from the main color. \n Quad: A color scheme based on the main color selected, using the colors on the color wheel that are 90 degrees from the main color."},devTools:{colorIniEditorPlaceholder:"[your-color-scheme-name]"},colour_one:"color",colour_other:"colors",favourite:"favorite"}},en:{translation:{settings:{title:"Marketplace Settings",optionsHeading:"Options",starCountLabel:"Stars count",tagsLabel:"Tags",showArchived:"Show archived repos",devToolsLabel:"Theme developer tools",hideInstalledLabel:"Hide installed when browsing",colourShiftLabel:"Shift colours every minute",albumArtBasedColors:"Change colours based on album art",albumArtBasedColorsMode:"Colour scheme (ColorApi) mode",albumArtBasedColorsVibrancy:"Colour grabbed from album art",albumArtBasedColorsVibrancyToolTip:"Desaturated: The colour that is the most prominent but with much less brightness \n Light Vibrant: The most Vibrant colour but with the brightness amped up a tad \n Prominent: The colour that pops the most in the album art \n Vibrant: The most vibrant colour in the album art",albumArtColorsModeToolTip:"Monochrome Dark: A colour scheme based directly on the main colour selected, using different shades of the main colour and mixing in greys to create a colour scheme, this is the inverse of Monochrome Light. \n Monochrome Light: A colour scheme based directly on the main colour selected, using different shades of the main colour and mixing in greys to create a colour scheme. The background of monochrome light would be the foreground or text colour on Monochrome Dark and vice versa. \n Analogic: A colour scheme based on the main colour selected, using the colours adjacent to the main colour on the colour wheel. \n Analogic Complementary: A colour scheme based on the main colour selected, using the colours adjacent to the main colour on the colour wheel and the complementary colour. \n Triad: A colour scheme based on the main colour selected, using the colours on the colour wheel that are equidistant from the main colour. \n Quad: A colour scheme based on the main colour selected, using the colours on the colour wheel that are 90 degrees from the main colour.",tabsHeading:"Tabs",tabsDescription:"Drag and drop to reorder, click to enable/disable",resetHeading:"Reset",resetBtn:"$t(settings.resetHeading)",resetDescription:"Uninstall all extensions and themes, and reset preferences",backupHeading:"Back up/Restore",backupLabel:"Back up or restore all Marketplace data. This does not include settings for anything installed via Marketplace.",backupBtn:"Open",versionHeading:"Version",versionBtn:"Copy",versionCopied:"Copied"},tabs:{Extensions:"Extensions",Themes:"Themes",Snippets:"Snippets",Apps:"Apps",Installed:"Installed"},snippets:{addTitle:"Add Snippet",duplicateName:"That name is already taken!",editTitle:"Edit Snippet",viewTitle:"View Snippet",customCSS:"Custom CSS",customCSSPlaceholder:"Input your own custom CSS here! You can find them in the installed tab for management.",snippetName:"Snippet Name",snippetNamePlaceholder:"Enter a name for your custom snippet",snippetDesc:"Snippet Description",snippetDescPlaceholder:"Enter a description for your custom snippet",snippetPreview:"Snippet Preview",optional:"Optional",addImage:"Add image",changeImage:"Change image",saveCSS:"Save CSS"},reloadModal:{title:"Reload",description:"A page reload is required to complete this operation.",reloadNow:"Reload now",reloadLater:"Reload later"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Settings copied to clipboard",settingsSaved:"Settings saved to file",noDataPasted:"No data pasted",invalidJSON:"Invalid JSON",inputLabel:"Marketplace Settings",inputPlaceholder:"Copy/paste your settings here",exportBtn:"Export",importBtn:"Import",fileImportBtn:"Import from file"},devTools:{title:"Theme Dev Tools",noThemeInstalled:"Error: No marketplace theme installed",noThemeManifest:"Error: No theme manifest found",colorIniEditor:"Color.ini Editor",colorIniEditorPlaceholder:"[your-colour-scheme-name]",invalidCSS:"Invalid CSS"},updateModal:{title:"Update the Marketplace",description:"Update Spicetify Marketplace to receive new features and bug fixes.",currentVersion:"Current version: {{version}}",latestVersion:"Latest version: {{version}}",whatsChanged:"What's Changed",seeChangelog:"See changelog",howToUpgrade:"How to upgrade",viewGuide:"View guide"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"New update",addCSS:"Add CSS",search:"Search",installed:"Installed",lastUpdated:"Last updated {{val, datetime}}",externalJS:"external JS",archived:"archived",dark:"dark",light:"light",sort:{label:"Sort by:",stars:"Stars",newest:"Newest",oldest:"Oldest",lastUpdated:"Last Updated",mostStale:"Most Stale",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Loading...",errorLoading:"Error loading README"},github:"GitHub",install:"Install",remove:"Remove",save:"Save",colour_one:"colour",colour_other:"colours",favourite:"favourite",notifications:{wrongLocalTheme:"Please set current_theme in config-xpui.ini to 'marketplace' to install themes using the Marketplace",tooManyRequests:"Too many requests, cool down",noCdnConnection:"Marketplace is unable to connect to the CDN. Please check your Internet configuration",markdownParsingError:"Error parsing markdown (HTTP {{status}})",noReadmeFile:"No README was found",themeInstallationError:"There was an error installing theme",extensionInstallationError:"There was an error installing extension"}}},es:{translation:{settings:{title:"Ajustes de Marketplace",optionsHeading:"Opciones",starCountLabel:"Número de estrellas",tagsLabel:"Etiquetas",showArchived:"Mostrar repositorios archivados",devToolsLabel:"Herramientas para desarrolladores de temas",hideInstalledLabel:"Ocultar lo instalado al navegar",colourShiftLabel:"Cambiar colores cada minuto",albumArtBasedColors:"Cambiar los colores según la portada del álbum",albumArtBasedColorsMode:"Modo de esquema de colores (ColorApi)",albumArtBasedColorsVibrancy:"Color obtenido de la portada del álbum",albumArtBasedColorsVibrancyToolTip:"Desaturado: El color más prominente pero con mucha menos brillo \n Vibrante claro: El color más vibrante pero con el brillo aumentado un poco \n Prominente: El color que más destaca en la portada del álbum \n Vibrante: El color más vibrante en la portada del álbum",albumArtColorsModeToolTip:"Monocromo oscuro: Un esquema de color basado directamente en el color principal seleccionado, usando diferentes tonos del color principal y mezclando con grises para crear un esquema de color, esto es lo inverso de Monocromo claro. \n Monocromo claro: Un esquema de color basado directamente en el color principal seleccionado, usando diferentes tonos del color principal y mezclando con grises para crear un esquema de color. El fondo del monocromo claro sería el primer plano o color de texto en Monocromo oscuro y viceversa. \n Analógico: Un esquema de color basado en el color principal seleccionado, usando los colores adyacentes al color principal en la rueda de colores. \n Complementario analógico: Un esquema de color basado en el color principal seleccionado, usando los colores adyacentes al color principal en la rueda de colores y el color complementario. \n Tríada: Un esquema de color basado en el color principal seleccionado, usando los colores en la rueda de colores que están equidistantes del color principal. \n Cuádruple: Un esquema de color basado en el color principal seleccionado, usando los colores en la rueda de colores que están a 90 grados del color principal.",tabsHeading:"Pestañas",tabsDescription:"Arrastre y suelte para cambiar el orden, haga clic para activar/desactivar",resetHeading:"Restablecer",resetBtn:"$t(settings.resetHeading)",resetDescription:"Borrar todas extensiones y temas, y borrar preferencias",backupHeading:"Copia de seguridad/Restauración",backupLabel:"Haz una copia de seguridad o restaura todos los datos de Marketplace. Esto no incluye la configuración de nada instalado a través de Marketplace.",backupBtn:"Abrir",versionHeading:"Versión",versionBtn:"Copiar",versionCopied:"Copiado"},tabs:{Extensions:"Extensiones",Themes:"Temas",Snippets:"Códigos",Apps:"Aplicaciones",Installed:"Instalados"},snippets:{addTitle:"Añadir Código",duplicateName:"¡Ese nombre ya está en uso!",editTitle:"Editar Código",viewTitle:"Ver Código",customCSS:"Custom CSS",customCSSPlaceholder:"¡Crea tu propio CSS aquí! Puedes encontrarlos en la pestaña de instalados para administrarlos.",snippetName:"Nombre del código",snippetNamePlaceholder:"Asígnale un nombre para tu código personalizado",snippetDesc:"Descripción del código",snippetDescPlaceholder:"Crea una descripción para tu código personalizado",snippetPreview:"Código",optional:"Opcional",addImage:"Añadir imagen",changeImage:"Cambiar imagen",saveCSS:"Guardar CSS"},reloadModal:{title:"Recargar",description:"Es necesario recargar la página para completar esta operación.",reloadNow:"Recargar ahora",reloadLater:"Recargar después"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Ajustes copiados al portapapeles",noDataPasted:"No hay datos pegados",invalidJSON:"JSON inválido",inputLabel:"Ajustes de Marketplace",inputPlaceholder:"Copia/pega tus ajustes aquí",exportBtn:"Exportar",importBtn:"Importar",fileImportBtn:"Importar desde un archivo"},devTools:{title:"Herramientas de desarrollador de temas",noThemeInstalled:"Error: No se ha instalado el tema del marketplace",noThemeManifest:"Error: No se ha encontrado el manifiesto del tema",colorIniEditor:"Editor de Color.ini",colorIniEditorPlaceholder:"[nombre-de-esquema-de-color]",invalidCSS:"CSS inválido"},updateModal:{title:"Actualizar el Marketplace",description:"Actualiza Spicetify Marketplace para recibir nuevas funciones y correcciones de errores.",currentVersion:"Versión actual: {{version}}",latestVersion:"Última versión: {{version}}",whatsChanged:"Qué ha cambiado",seeChangelog:"Ver registro de cambios",howToUpgrade:"Cómo actualizar",viewGuide:"Ver guía"},grid:{spicetifyMarketplace:"Marketplace de Spicetify",newUpdate:"Nueva actualización",addCSS:"Añadir CSS",search:"Buscar",installed:"Instalado",lastUpdated:"Última actualización {{val, datetime}}",externalJS:"JS externo",archived:"archivado",dark:"oscuro",light:"claro",sort:{label:"Ordenar por:",stars:"Estrellas",newest:"Más nuevo",oldest:"Más antiguo",lastUpdated:"Última actualización",mostStale:"Más desactualizado",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Cargando...",errorLoading:"Error al cargar el README"},github:"GitHub",install:"Instalar",remove:"Borrar",save:"Guardar",colour_one:"color",colour_other:"colores",favourite:"favorito",notifications:{wrongLocalTheme:"Por favor, establece current_theme en config-xpui.ini como 'marketplace' para instalar temas usando el Marketplace",tooManyRequests:"Demasiadas solicitudes, espera un momento",noCdnConnection:"Marketplace no puede conectarse al CDN. Por favor, revisa tu configuración de Internet",markdownParsingError:"Error al analizar markdown (HTTP {{status}})",noReadmeFile:"No se encontró el archivo README",themeInstallationError:"Hubo un error al instalar el tema",extensionInstallationError:"Hubo un error al instalar la extensión"}}},et:{translation:{settings:{title:"Turu seaded",optionsHeading:"Seaded",starCountLabel:"Tähtede arv",tagsLabel:"Sildid",devToolsLabel:"Teema arendaja tööriistad",hideInstalledLabel:"Peida sirvimisel paigaldatud",colourShiftLabel:"Muutke värve iga minut",albumArtBasedColors:"Muutke värve albumipildi põhjal",albumArtBasedColorsMode:"Värviskeemi (ColorApi) režiim",albumArtBasedColorsVibrancy:"Albumipildilt haaratud värv",albumArtBasedColorsVibrancyToolTip:"Desaturated: Värv, mis on kõige silmatorkavam, kuid palju väiksema heledusega \n Light vibrant: Kõige erksam värv, kuid veidi suurendatud heledusega \n Prominent: Värv, mis ilmub albumi kujunduses kõige rohkem \n Vibrant: Albumipildi kõige elavam värv",albumArtColorsModeToolTip:"Monochrome dark: Värvilahendus, mis põhineb otse valitud põhivärvil, kasutades põhivärvi erinevaid toone ja segades värviskeemi loomiseks halle, see on ühevärvlise heleda pöördväärtus. \n Monochrome light: Värvilahendus, mis põhineb otse valitud põhivärvil, kasutades põhivärvi erinevaid toone ja segades värviskeemi loomiseks halle. Ühevärvilise valguse taust oleks ühevärvilise tumeda esiplaani või teksti värv ja vastupidi. \n Analogic: Valitud põhivärvil põhinev värviskeem, kasutades värviratta põhivärviga külgnevaid värve. \n Analogic complement: Valitud põhivärvil põhinev värviskeem, kasutades värviratta põhivärviga külgnevaid värve ja lisavärvi. \n Triad: Valitud põhivärvil põhinev värviskeem, kasutades põhivärvist võrdsel kaugusel asuvaid värviratta värve. \n Quad: Valitud põhivärvil põhinev värviskeem, kasutades värvirattal olevaid värve, mis on põhivärvist 90 kraadi.",tabsHeading:"Vahekaardid",tabsDescription:"Järjekorra muutmiseks lohista ja eemalda, lubamiseks/välja lülitamiseks klõpsa",resetHeading:"Reset",resetBtn:"$t(settings.resetHeading)",resetDescription:"Uninstall all extensions and themes, and reset preferences",backupHeading:"Varunda/Taasta",backupLabel:"Varunda või taasta kõik turu andmed. See ei hõlma turu kaudu paigaldatud elementide seadeid.",backupBtn:"Ava",versionHeading:"Versioon",versionBtn:"Kopeeri",versionCopied:"Kopeeritud"},tabs:{Extensions:"Lisad",Themes:"Teemad",Snippets:"Katked",Apps:"Rakendused",Installed:"Paigaldatud"},snippets:{addTitle:"Lisa katkend",editTitle:"Muuda katkendit",viewTitle:"Vaata katkendit",customCSS:"Kohandatud CSS",customCSSPlaceholder:"Paigalda Kohandatud CSS siia! Haldamiseks leiate need paigaldatud vahekaardilt.",snippetName:"Katkendi nimi",snippetNamePlaceholder:"Lisa kohandatud katkendi nimi",snippetDesc:"Katkendi kirjeldus",snippetDescPlaceholder:"Lisa kohandatud katkendi kirjeldus",snippetPreview:"Katkendi eelvaade",optional:"valikuline",addImage:"Lisa pilt",changeImage:"Muuda pilti",saveCSS:"Salvesta CSS"},reloadModal:{title:"Laadi uuesti",description:"Selle toimingu lõpuleviimiseks on vaja leht uuesti laadida.",reloadNow:"Laadige kohe uuesti",reloadLater:"Laadige hiljem uuesti"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Seaded kopeeriti lõikelauale",noDataPasted:"Andmeid pole kleebitud",invalidJSON:"Vale JSON",inputLabel:"Turu Seaded",inputPlaceholder:"Kopeeri/kleebi enda seaded siia",exportBtn:"Ekspordi",importBtn:"Impordi",fileImportBtn:"Impordi failist"},devTools:{title:"Teema arendustööriistad",noThemeInstalled:"Viga: Turu teemat pole installitud",noThemeManifest:"Viga: Teema manifesti ei leitud",colorIniEditor:"Color.ini redaktor",colorIniEditorPlaceholder:"[teie-värviskeemi-nimi]",invalidCSS:"Vigane CSS"},grid:{spicetifyMarketplace:"Spicetify Turg",newUpdate:"Uus värskendus",addCSS:"Lisa CSS",search:"Otsi",installed:"Paigaldatud",lastUpdated:"Viimati uuendatud {{val, datetime}}",externalJS:"väline JS",dark:"tume",light:"hele"},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Laadimine...",errorLoading:"Viga README laadimisel"},github:"GitHub",install:"Paigalda",remove:"Eemalda",save:"Salvesta",colour_one:"värv",colour_other:"värvid",favourite:"lemmik"}},fi:{translation:{settings:{title:"Marketplacen asetukset",optionsHeading:"Valinnat",starCountLabel:"Tähdet",tagsLabel:"Tagit",showArchived:"Näytä arkistoituja lähdekoodivarastoja",devToolsLabel:"Teeman kehittäjätyökalut",hideInstalledLabel:"Piilota asennetut",colourShiftLabel:"Väriä muutetaan joka minuutti",albumArtBasedColors:"Muuta väriä albumin perusteella",albumArtBasedColorsMode:"Värityyli (ColorApi) tila",albumArtBasedColorsVibrancy:"Väri otettu albumista",albumArtBasedColorsVibrancyToolTip:"Kyllästelemätön: Väri, joka on näkyvin, mutta jonka kirkkaus on paljon pienempi \n Valoisa eloisa: Eloisin väri, jonka kirkkautta on hieman lisätty \n Merkittävä: Väri, joka erottuu eniten albumin kuvituksessa \n Eloisa: Albumin kuvituksen eloisin väri",albumArtColorsModeToolTip:"Tumma yksiväri: Suoraan valittuun pääväriin perustuva värimaailma, jossa käytetään päävärin eri sävyjä ja harmaita sekoittamalla värimaailman luomiseksi. Tämä on vaalean yksivärisen käänteinen värimaailma. \n Vaalea yksiväri: Suoraan valittuun pääväriin perustuva värimaailma, jossa käytetään päävärin eri sävyjä ja harmaita sekoittamalla värimaailman luomiseksi. Vaalean yksivärisen värimaailman tausta olisi tumman yksivärisen värimaailman etualan tai tekstin väri ja päinvastoin. \n Analoginen: Valittuun pääväriin perustuva värimaailma, jossa käytetään väriympyrässä päävärin viereisiä värejä. \n Analoginen komplementtiväri: Valittuun pääväriin perustuva värimaailma, jossa käytetään väriympyrässä päävärin viereisiä värejä ja komplementtiväriä. \n Kolmio: Valittuun pääväriin perustuva värimaailma, jossa käytetään väriympyrän värejä, jotka ovat yhtä kaukana pääväristä. \n Neliväri: Valittuun pääväriin perustuva värimaailma, jossa käytetään väriympyrän värejä, jotka ovat 90 asteen etäisyydellä pääväristä.",tabsHeading:"Sivut",tabsDescription:"Vedä ja pudota uudelleen järjestykseen, napsauta käyttöön/pois käytöstä",resetHeading:"Palauta",resetBtn:"$t(settings.resetHeading)",resetDescription:"Poista kaikki laajennukset ja teemat ja palauta asetukset",backupHeading:"Varmuuskopioi/Palauta",backupLabel:"Varmuuskopioi tai palauta kaikki Marketplacen data. Tämä ei sisällä asetuksia mitään, joka on asennettu Marketplacein kautta.",backupBtn:"Avaa",versionHeading:"Versio",versionBtn:"Kopioi",versionCopied:"Kopioitu"},tabs:{Extensions:"Laajennukset",Themes:"Teemat",Snippets:"Koodin pätkät",Apps:"Sovellukset",Installed:"Asennetut"},snippets:{addTitle:"Lisää koodin pätkä",duplicateName:"Nimi on jo käytössä!",editTitle:"Muokkaa koodin pätkää",viewTitle:"Näytä koodin pätkä",customCSS:"Oma CSS",customCSSPlaceholder:"Syötä oma mukautettu CSS-koodisi tähän! Löydät ne hallintaa varten asennetut-välilehdeltä.",snippetName:"Koodin pätkän nimi",snippetNamePlaceholder:"Anna nimi koodin pätkälle",snippetDesc:"Koodin pätkän kuvaus",snippetDescPlaceholder:"Anna kuvaus koodin pätkälle",snippetPreview:"Koodin pätkän esikatselu",optional:"Valinnainen",addImage:"Lisää kuva",changeImage:"Vaihda kuva",saveCSS:"Tallenna CSS"},reloadModal:{title:"Lataa uudelleen",description:"Sivun lataaminen uudelleen on vaadittava tämän toiminnon suorittamiseksi.",reloadNow:"Lataa uudelleen nyt",reloadLater:"Lataa uudelleen myöhemmin"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Asetukset kopioitu leikepöydälle",noDataPasted:"Ei dataa liitetty",invalidJSON:"Virheellinen JSON",inputLabel:"Marketplacen asetukset",inputPlaceholder:"Kopioi/liitä asetuksesi tähän",exportBtn:"Vie",importBtn:"Tuo",fileImportBtn:"Tuo tiedostosta"},devTools:{title:"Teeman kehittäjätyökalut",noThemeInstalled:"Virhe: Ei Marketplace-teemaa asennettu",noThemeManifest:"Virhe: Ei teeman manifestia",colorIniEditor:"Color.ini-editori",colorIniEditorPlaceholder:"[sinun-värityylisi-nimi]",invalidCSS:"Virheellinen CSS"},updateModal:{title:"Päivitä Marketplace",description:"Päivitä Spicetify Marketplace saadaksesi uusia ominaisuuksia ja bugikorjauksia.",currentVersion:"Nykyinen versio: {{version}}",latestVersion:"Uusin versio: {{version}}",whatsChanged:"Mitä on muuttunut",seeChangelog:"Katso muutosloki",howToUpgrade:"Kuinka päivittää",viewGuide:"Näytä opas"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Uusi päivitys",addCSS:"Lisää CSS",search:"Haku",installed:"Asennettu",lastUpdated:"Viimeisin päivitys {{val, datetime}}",externalJS:"ulkoiset JS-skriptit",archived:"arkistoitu",dark:"tumma",light:"vaalea",sort:{label:"Järjestä:",stars:"Tähdet",newest:"Uusin",oldest:"Vanhin",lastUpdated:"Viimeisin päivitys",mostStale:"Eniten vanhentunut",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Ladataan...",errorLoading:"Virhe ladattaessa README"},github:"GitHub",install:"Asenna",remove:"Poista",save:"Tallenna",colour_one:"väri",colour_other:"värit",favourite:"suosikki",notifications:{wrongLocalTheme:"Aseta current_theme config-xpui.ini-tiedostossa 'marketplace'-arvoon käyttääksesi Marketplace-teemoja",tooManyRequests:"Liian monta pyyntöä, odota hetki",noCdnConnection:"Marketplace ei pysty yhdistämään CDN:ään. Tarkista internetyhteys",markdownParsingError:"Virhe jäsentämässä markdownia (HTTP {{status}})",noReadmeFile:"Ei README-tiedostoa löytynyt",themeInstallationError:"Teeman asentamisessa tapahtui virhe",extensionInstallationError:"Laajennuksen asentamisessa tapahtui virhe"}}},fr:{translation:{settings:{title:"Réglages Marché Spicetify",optionsHeading:"Options",starCountLabel:"Nombres d’étoiles",tagsLabel:"Tags",devToolsLabel:"Outils pour les développeurs de thèmes",hideInstalledLabel:"Masquer ceux étant installés lors de la navigation",colourShiftLabel:"Changer de couleur chaque minutes",albumArtBasedColors:"Changement des couleurs basé sur les pochettes d'albums",albumArtBasedColorsMode:"Mode de schéma de couleur (ColorApi)",albumArtBasedColorsVibrancy:"Couleur saisie depuis les pochettes d'albums",albumArtBasedColorsVibrancyToolTip:"Désaturé: La couleur qui est la plus proéminente mais avec beaucoup moins de luminosité\nVibrations Claires: La couleur la plus vibrante, mais avec une luminosité un peu plus forte\nPrometteur: La couleur qui ressort le plus dans la pochette de l'album\nVibrations: La couleur la plus vibrante dans la pochette de l'album",albumArtColorsModeToolTip:"Monochrome foncé: une palette de couleurs basée directement sur la couleur principale sélectionnée, en utilisant différentes nuances de la couleur principale et en mélangeant des gris pour créer une palette de couleurs, c'est l'inverse du monochrome clair.\nMonochrome clair: Une palette de couleurs basée directement sur la couleur principale sélectionnée, en utilisant différentes nuances de la couleur principale et en mélangeant les gris pour créer une palette de couleurs. L'arrière-plan d'un monochrome clair sera le premier plan ou la couleur du texte d'un monochrome foncé et vice versa.\nAnalogique: Schéma de couleurs basé sur la couleur principale sélectionnée, utilisant les couleurs adjacentes à la couleur principale sur le cercle chromatique.\nAnalogique complémentaire: Un schéma de couleurs basé sur la couleur principale sélectionnée, utilisant les couleurs adjacentes à la couleur principale sur le cercle chromatique et la couleur complémentaire.\nTriade: Un schéma de couleurs basé sur la couleur principale sélectionnée, utilisant les couleurs équidistantes de la couleur principale sur le cercle chromatique.\nQuad: Un schéma de couleurs basé sur la couleur principale sélectionnée, utilisant les couleurs du cercle chromatique qui sont à 90 degrés de la couleur principale.",tabsHeading:"Onglets",tabsDescription:"Glisser-déposer pour modifier l'ordre, cliquer pour activer/désactiver",resetHeading:"Réinitialiser",resetBtn:"$t(settings.resetHeading)",resetDescription:"Désinstaller toutes les extensions et tous les thèmes, ainsi que l’ensemble des réglages",backupHeading:"Sauvegarde/Restauration",backupLabel:"Sauvegarder ou restaurer toutes les données du Marché. Celà n'inclue pas les réglages pour quoi que ce soit installé depuis le Marché.",backupBtn:"Ouvrir",versionHeading:"Version",versionBtn:"Copier",versionCopied:"Copié"},tabs:{Extensions:"Extensions",Themes:"Thèmes",Snippets:"Bribes",Apps:"Applications",Installed:"Installé(s)"},snippets:{addTitle:"Ajouter Bribe",editTitle:"Éditer Bribe",viewTitle:"Voir Bribe",customCSS:"CSS personnalisé",customCSSPlaceholder:"Insérez votre propre CSS personnalisé ici! Vous pouvez les retrouver dans l’onglet Installé pour les gérer.",snippetName:"Nom de la bribe",snippetNamePlaceholder:"Entrer un nom pour votre bribe personnalisée",snippetDesc:"Description de la bribe",snippetDescPlaceholder:"Entrez une description pour votre bribe personnalisée",snippetPreview:"Prévisualiser la bribe",optional:"Optionnel",addImage:"Ajouter une image",changeImage:"Changer l’image",saveCSS:"Enregistrer le CSS"},reloadModal:{title:"Recharger",description:"Un rechargement de la page est requis pour finaliser cette opération.",reloadNow:"Recharger maintenant",reloadLater:"Recharger plus tard"},backupModal:{title:"Sauvegarder/Restaurer",settingsCopied:"Réglages copiés dans le presse-papier",noDataPasted:"Aucune donnée collée",invalidJSON:"JSON invalide",inputLabel:"Réglages du Marché",inputPlaceholder:"Copier/coller vos réglages ici",exportBtn:"Exporter",importBtn:"Importer",fileImportBtn:"Importer depuis un fichier"},devTools:{title:"Outils de développeurs de thèmes",noThemeInstalled:"Erreur: Aucun thème du marché n’est installé",noThemeManifest:"Erreur: Aucun manifeste de thème trouvé",colorIniEditor:"Éditeur Color.ini",colorIniEditorPlaceholder:"[nom-de-votre-schéma-de-couleur]",invalidCSS:"CSS invalide"},grid:{spicetifyMarketplace:"Marché Spicetify",newUpdate:"Nouvelle mise à jour",addCSS:"Ajouter CSS",search:"Rechercher",installed:"Installé",lastUpdated:"Dernière mise à jour {{val, datetime}}",externalJS:"JS externe",dark:"sombre",light:"clair",sort:{label:"Trier par:",stars:"Étoiles",newest:"Nouveauté",oldest:"Ancienneté",lastUpdated:"Dernière mise à jour",mostStale:"Le plus périmé",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Chargement…",errorLoading:"Erreur lors du chargement du README"},github:"GitHub",install:"Installer",remove:"Supprimer",save:"Enregistrer",colour_one:"couleur",colour_other:"couleurs",favourite:"favoris"}},it:{translation:{settings:{title:"Impostazioni Marketplace",optionsHeading:"Opzioni",starCountLabel:"Contatore stelle",tagsLabel:"Tag",showArchived:"Mostra repository archiviati",devToolsLabel:"Strumenti di sviluppo del tema",hideInstalledLabel:"Nascondi i pacchetti già installati durante la navigazione",colourShiftLabel:"Cambia colori ogni minuto",albumArtBasedColors:"Cambia i colori in base alla copertina dell'album",albumArtBasedColorsMode:"Schema colori modalità (ColorApi)",albumArtBasedColorsVibrancy:"Colore preso dalla copertina dell'album",albumArtBasedColorsVibrancyToolTip:"Desaturato: Il colore predominante ma con molta meno luminosità \n Vibrante Chiaro: Il colore più intenso ma con la luminosità aumentata leggermente \n Predominante: Il colore che spicca di più nella copertina dell'album \n Vibrante: Il colore più intenso nella copertina dell'album",albumArtColorsModeToolTip:"Monocromo Scuro: Uno schema di colori basato direttamente sul colore principale selezionato, utilizzando diverse sfumature del colore principale e mescolando i grigi per creare uno schema di colori; questo è l'inverso di Monocromo Chiaro. \n Monocromo Chiaro: Uno schema di colori basato direttamente sul colore principale selezionato, utilizzando diverse sfumature del colore principale e mescolando i grigi per creare uno schema di colori. Lo sfondo di Monocromo Chiaro sarebbe il colore del testo o di quello in primo piano su Monocromo Scuro e viceversa. \n Armonico: Uno schema di colori basato sul colore principale selezionato, utilizzando i colori adiacenti al colore principale sulla ruota dei colori.\n Armonico Complementare: Uno schema di colori basato sul colore principale selezionato, utilizzando i colori adiacenti al colore principale sulla ruota dei colori e il colore complementare. \n Ternario: Uno schema di colori basato sul colore principale selezionato, utilizzando i colori sulla ruota dei colori che sono equidistanti dal colore principale. \n Quaternario: Uno schema di colori basato sul colore principale selezionato, utilizzando i colori sulla ruota dei colori che sono a 90 gradi dal colore principale.",tabsHeading:"Schede",tabsDescription:"Trascinare e rilasciare per cambiare l'ordine, cliccare per attivare/disattivare",resetHeading:"Reimposta",resetBtn:"$t(settings.resetHeading)",resetDescription:"Disinstalla tutte le estensioni e i temi, e ripristina le preferenze",backupHeading:"Backup/Ripristino",backupLabel:"Effettua il backup o ripristina tutti i dati del Marketplace. Questo non include le impostazioni per qualsiasi elemento installato tramite Marketplace.",backupBtn:"Apri",versionHeading:"Versione",versionBtn:"Copia",versionCopied:"Copiato"},tabs:{Extensions:"Estensioni",Themes:"Temi",Snippets:"Moduli",Apps:"Applicazioni",Installed:"Installato"},snippets:{addTitle:"Aggiungi Modulo",duplicateName:"Questo nome è già stato utilizzato!",editTitle:"Modifica Modulo",viewTitle:"Visualizza Modulo",customCSS:"CSS personalizzato",customCSSPlaceholder:"Scrivi qui il tuo CSS personalizzato! Puoi trovarli nella scheda degli installati per la gestione.",snippetName:"Nome Modulo",snippetNamePlaceholder:"Inserisci un nome per il tuo modulo personalizzato",snippetDesc:"Descrizione Modulo",snippetDescPlaceholder:"Inserisci una descrizione per il tuo modulo personalizzato",snippetPreview:"Anteprima Modulo",optional:"Opzionale",addImage:"Aggiungi immagine",changeImage:"Cambia immagine",saveCSS:"Salva CSS"},reloadModal:{title:"Ricarica",description:"È necessario ricaricare la pagina per completare questa operazione.",reloadNow:"Ricarica",reloadLater:"Più tardi"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Impostazioni copiate negli appunti",noDataPasted:"Nessun dato incollato",invalidJSON:"JSON non valido",inputLabel:"Impostazioni Marketplace",inputPlaceholder:"Copia/incolla qui le tue impostazioni",exportBtn:"Esporta",importBtn:"Importa",fileImportBtn:"Importa da file"},devTools:{title:"Strumenti di sviluppo del tema",noThemeInstalled:"Errore: Nessun tema del Marketplace installato",noThemeManifest:"Errore: Nessun manifest del tema trovato",colorIniEditor:"Editor Color.ini",colorIniEditorPlaceholder:"[nome-del-tuo-schema-colori]",invalidCSS:"Classi CSS non valide"},updateModal:{title:"Aggiorna il Marketplace",description:"Aggiorna Spicetify Marketplace per ricevere nuove funzionalità e correzioni dei bug.",currentVersion:"Versione attuale: {{version}}",latestVersion:"Ultima versione: {{version}}",whatsChanged:"Cos'è Cambiato",seeChangelog:"Guarda il changelog",howToUpgrade:"Come effettuare l'aggiornamento",viewGuide:"Visualizza guida"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Nuovo aggiornamento",addCSS:"Aggiungi CSS",search:"Cerca",installed:"Installato",lastUpdated:"Ultimo aggiornamento {{val, datetime}}",externalJS:"jS esterno",archived:"archiviato",dark:"scuro",light:"chiaro",sort:{label:"Ordina per:",stars:"Valutazione",newest:"Più recente",oldest:"Meno recenti",lastUpdated:"Ultimo aggiornamento",mostStale:"Meno Aggiornato",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Caricamento...",errorLoading:"Errore nel caricamento del README"},github:"GitHub",install:"Installa",remove:"Rimuovi",save:"Salva",colour_one:"colore",colour_other:"colori",favourite:"preferito",notifications:{wrongLocalTheme:"Si prega d'impostare current_theme in config-xpui.ini su 'marketplace' per installare temi utilizzando il Marketplace",tooManyRequests:"Troppe richieste, attendi un momento",noCdnConnection:"Il Marketplace non riesce a connettersi al CDN. Si prega di controllare la configurazione Internet",markdownParsingError:"Errore durante l'analisi del Markdown (HTTP {{status}})",noReadmeFile:"Nessun README trovato",themeInstallationError:"Si è verificato un errore durante l'installazione del tema",extensionInstallationError:"Si è verificato un errore durante l'installazione dell'estensione"}}},ja:{translation:{settings:{title:"マーケットプレイスの設定",optionsHeading:"オプション",starCountLabel:"スターの数",tagsLabel:"タグ",showArchived:"アーカイブされたリポジトリを表示",devToolsLabel:"テーマ開発者ツール",hideInstalledLabel:"ブラウジング時にインストール済みを非表示にする",colourShiftLabel:"1分ごとに色を変更",albumArtBasedColors:"アルバムアートに基づいて色を変更",albumArtBasedColorsMode:"カラースキーム(ColorApi)モード",albumArtBasedColorsVibrancy:"アルバムアートから取得した色",albumArtBasedColorsVibrancyToolTip:"Desaturated: 最も目立つ色だが、明るさがはるかに抑えられています \n Light Vibrant: 最も活気ある色ですが、明るさが少し増しています \n Prominent: アルバムアートで最も目立つ色です \n Vibrant: アルバムアートで最も鮮やかな色です",albumArtColorsModeToolTip:"Monochrome Dark: 選択したメインカラーを基にした色の配色スキームで、メインカラーの異なる濃淡やグレーを混ぜて配色することで、これはMonochrome Lightの反対です。 \n Monochrome Light: 選択したメインカラーを直接基にした色の配色スキームで、メインカラーの異なる濃淡やグレーを混ぜて配色します。Monochrome Lightの背景色は、Monochrome Darkの前景色やテキスト色となり、その逆も同様です。 \n Analogic: 選択されたメインカラーを基に、カラーホイール上でメインカラーに隣接する色を使用した配色スキームです。 \n Analogic Complementary: 選択したメインカラーを基に、カラーホイール上でメインカラーに隣接する色と補色を使用した配色スキームです。 \n Triad: 選択したメインカラーを基に、カラーホイール上でメインカラーから等距離にある色を使用した配色スキームです。 \n Quad: 選択されたメインカラーを基に、カラーホイール上でメインカラーから90度離れた色を使用した配色スキームです。",tabsHeading:"タブ",tabsDescription:"ドラッグ&ドロップで順序を変更し、クリックで有効/無効を切り替える",resetHeading:"リセット",resetBtn:"$t(settings.resetHeading)",resetDescription:"すべての拡張機能とテーマをアンインストールし、設定をリセットします",backupHeading:"バックアップ/リストア",backupLabel:"すべてのマーケットプレイスデータのバックアップまたはリストアを行います。これには、マーケットプレイスを介してインストールされた設定は含まれません。",backupBtn:"開く",versionHeading:"バージョン",versionBtn:"コピー",versionCopied:"コピーされました"},tabs:{Extensions:"拡張機能",Themes:"テーマ",Snippets:"スニペット",Apps:"アプリ",Installed:"インストール済み"},snippets:{addTitle:"スニペットを追加",duplicateName:"その名前は既に使われています!",editTitle:"スニペットを編集",viewTitle:"スニペットを表示",customCSS:"カスタムCSS",customCSSPlaceholder:"ここにカスタムCSSを入力してください! 管理用のインストール済みタブで見つけることができます。",snippetName:"スニペット名",snippetNamePlaceholder:"カスタムスニペットの名前を入力してください",snippetDesc:"スニペットの説明",snippetDescPlaceholder:"カスタムスニペットの説明を入力してください",snippetPreview:"スニペットプレビュー",optional:"オプション",addImage:"画像を追加",changeImage:"画像を変更",saveCSS:"CSSを保存"},reloadModal:{title:"リロード",description:"この操作を完了するにはページのリロードが必要です。",reloadNow:"今すぐ読み込む",reloadLater:"後で読み込む"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"設定がクリップボードにコピーされました",noDataPasted:"データが貼り付けられていません",invalidJSON:"無効なJSON",inputLabel:"マーケットプレイスの設定",inputPlaceholder:"ここに設定をコピー&ペーストしてください",exportBtn:"エクスポート",importBtn:"インポート",fileImportBtn:"ファイルからインポート"},devTools:{title:"テーマ開発ツール",noThemeInstalled:"エラー:マーケットプレイスのテーマがインストールされていません",noThemeManifest:"エラー:テーママニフェストが見つかりませんでした",colorIniEditor:"Color.ini Editor",colorIniEditorPlaceholder:"[your-colour-scheme-name]",invalidCSS:"無効なCSS"},updateModal:{title:"マーケットプレイスの更新",description:"新機能やバグ修正を受け取るために、Spicetify Marketplaceを更新してください。",currentVersion:"現在のバージョン: {{version}}",latestVersion:"最新のバージョン: {{version}}",whatsChanged:"変更内容",seeChangelog:"変更履歴を見る",howToUpgrade:"アップグレード方法",viewGuide:"ガイドを見る"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"新しいアップデート",addCSS:"CSSを追加",search:"検索",installed:"インストール済み",lastUpdated:"{{val, datetime}}に最終更新",externalJS:"外部JS",archived:"アーカイブ済み",dark:"ダーク",light:"ライト",sort:{label:"並べ替え:",stars:"スター",newest:"最新",oldest:"最古",lastUpdated:"最終更新",mostStale:"最も古い",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - README",loading:"読み込み中...",errorLoading:"READMEの読み込み中にエラーが発生しました"},github:"GitHub",install:"インストール",remove:"削除",save:"保存",colour_one:"色",colour_other:"色",favourite:"お気に入り",notifications:{wrongLocalTheme:"config-xpui.iniのcurrent_themeを 'marketplace' に設定して、マーケットプレイスを使用してテーマをインストールしてください",tooManyRequests:"リクエストが多すぎます。時間をおいて再試行してください",noCdnConnection:"マーケットプレイスがCDNに接続できません。インターネットの設定を確認してください",markdownParsingError:"Markdownの解析エラー(HTTP {{status}})",noReadmeFile:"READMEが見つかりませんでした",themeInstallationError:"テーマのインストール中にエラーが発生しました",extensionInstallationError:"拡張機能のインストール中にエラーが発生しました"}}},ko:{translation:{settings:{title:"마켓플레이스 설정",optionsHeading:"설정",starCountLabel:"별점 개수",tagsLabel:"태그",showArchived:"보관된 리포지스토리 보기",devToolsLabel:"테마 개발자 도구",hideInstalledLabel:"설치된 기능은 탐색 결과에서 숨기기",colourShiftLabel:"매 분마다 색상 변경",albumArtBasedColors:"앨범 표지에 따라 색상 변경",albumArtBasedColorsMode:"색상 구성표 (색상Api) 모드",albumArtBasedColorsVibrancy:"앨범 표지에서 색상 추출",albumArtBasedColorsVibrancyToolTip:"탁색 (Desaturated): 가장 두드러지지만 밝기가 낮은 색상입니다.\n쨍한 백색 (Light Vibrant): 가장 생생하게 느껴지면서도 밝기가 조금 더 높아진 색상입니다.\n강조색 (Prominent): 앨범 아트에서 가장 눈에 띄는 색상입니다, 앨범 아트에서 가장 돋보이는 색이라고 할 수 있죠.\n높은 채도색 (Vibrant): 앨범 아트에서 가장 생생한 색상입니다.",albumArtColorsModeToolTip:"모노크롬 다크 (Monochrome Dark): 선택한 메인 색상을 기준으로 다양한 명암들과 회색을 섞어 만든 색상입니다. 이는 Monochrome Light의 반대 개념이죠.\n모노크롬 라이트 (Monochrome Light): 선택한 메인 색상을 기준으로 다양한 명암과 회색을 섞어 만든 색상입니다. Monochrome Light의 배경색은 Monochrome Dark의 전경색(배경색) 또는 텍스트의 색상이 되며, 그 반대도 마찬가지입니다.\n유사색 (Analogic): 선택한 메인 색상을 기준으로 색 팔레트에서 메인 색상에 인접한 색상들을 이용하여 만든 색상입니다.\n유사 보색 (Analogic Complementary): 선택한 메인 색상을 기준으로 색 팔레트에서 메인 색상에 인접한 색상들과 보색들을 함께 사용하여 만든 색입니다.\n트라이드 (Triad): 선택한 메인 색상을 기준으로 색팔레트에서 메인 색상으로부터 동일한 간격으로 떨어져 있는 세 가지 색상을 사용하여 만든 색상 구성표입니다.\n쿼드 (Quad): 선택한 메인 색상을 기준으로 색팔레트에서 메인 색상으로부터 90도 간격으로 떨어져 있는 네 가지 색상을 사용하여 만든 색상 구성표입니다.",tabsHeading:"탭",tabsDescription:"끌어 놓아 순서를 변경하고, 클릭하여 활성화 및 비활성화 합니다.",resetHeading:"\n초기화",resetBtn:"$t(settings.resetHeading)",resetDescription:"모든 확장 프로그램들과 테마들을 제거하고, 기본 설정으로 되돌립니다.",backupHeading:"백업/복구",backupLabel:"모든 마켓플레이스 데이터를 백업하거나 복원합니다.여기에는 마켓플레이스를 통해 설치된 항목들의 설정은 포함되지 않습니다.",backupBtn:"열기",versionHeading:"버전",versionBtn:"복사",versionCopied:"복사됨"},tabs:{Extensions:"확장 프로그램",Themes:"테마 목록",Snippets:"추가 기능",Apps:"앱 목록",Installed:"설치 목록"},snippets:{addTitle:"추가 기능 등록",duplicateName:"이 이름은 이미 사용되고 있습니다!",editTitle:"추가 기능 수정",viewTitle:"추가 기능",customCSS:"Custom CSS",customCSSPlaceholder:"자신의 CSS 파일을 이곳에 첨부하세요! 설치 목록 탭에서 찾을 수 있습니다.",snippetName:"추가 기능 이름",snippetNamePlaceholder:"추가 기능 이름을 이곳에 입력하세요!",snippetDesc:"추가 기능 설명",snippetDescPlaceholder:"추가 기능 설명을 이곳에 입력하세요!",snippetPreview:"추가 기능 미리보기 이미지",optional:"선택사항",addImage:"이미지 추가",changeImage:"이미지 바꾸기",saveCSS:"CSS 저장"},reloadModal:{title:"번경 사항 적용",description:"이 작업을 완료하려면 페이지를 재시작해야 합니다.",reloadNow:"지금 재시작",reloadLater:"나중에 재시작"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"설정이 클립보드에 저장되었습니다.",noDataPasted:"붙여넣어진 데이터가 없습니다",invalidJSON:"유효하지 않은 JSON",inputLabel:"마켓 플레이스 설정",inputPlaceholder:"이곳에 설정을 복사/붙여넣기 하세요",exportBtn:"내보내기",importBtn:"가져오기",fileImportBtn:"파일에서 가져오기"},devTools:{title:"테마 개발자 도구",noThemeInstalled:"오류: 어떤 마켓플레이스 테마도 설치되지 않았습니다",noThemeManifest:"오류: 테마 매니페스트 찾을 수 없음",colorIniEditor:"Colour.ini 편집기",colorIniEditorPlaceholder:"[당신의-색상-구성표-이름]",invalidCSS:"유효치 않은 CSS"},updateModal:{title:"마켓플레이스 업데이트",description:"spicetify 마켓 플레이스를 업데이트 하여 새로운 기능들과 버그 픽스들을 제공받습니다.",currentVersion:"현재 버전: {{version}}",latestVersion:"지난 버전: {{version}}",whatsChanged:"새로운 기능",seeChangelog:"패치노트 보기",howToUpgrade:"업데이트 방법",viewGuide:"가이드 보기"},grid:{spicetifyMarketplace:"Spicetify 마켓플레이스",newUpdate:"새로운 업데이트",addCSS:"CSS 등록",search:"검색",installed:"설치됨",lastUpdated:"마지막 업데이트일 {{val, datetime}}",externalJS:"external JS",archived:"만료됨",dark:"다크 모드",light:"라이트 모드",sort:{label:"나열 기준:",stars:"별점",newest:"신규",oldest:"오래된 순",lastUpdated:"가장 최신 순",mostStale:"가장 오래된 순",aToZ:"A-Z 까지",zToA:"Z-A 까지"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"로딩중...",errorLoading:"README를 불러오는 중 오류 발생"},github:"GitHub",install:"설치",remove:"제거",save:"저장",colour_one:"색상",colour_other:"색상들",favourite:"즐겨찾기",notifications:{wrongLocalTheme:"마켓플레이스를 사용하여 테마를 설치하려면 config-xpui.ini에서 current_theme를 'marketplace'로 설정하세요.",tooManyRequests:"요청이 너무 빈번합니다, 잠시 뒤 시도하세요",noCdnConnection:"마켓플레이스가 CDN에 접속할 수 없습니다. 현재 인터넷 구성을 확인해주세요.",markdownParsingError:"Markdown 구문 분석 오류 (HTTP {{status}})",noReadmeFile:"README 파일이 존재하지 않습니다",themeInstallationError:"테마를 설치하는데 오류가 있었습니다",extensionInstallationError:"확장 프로그램을 설치하는 데 오류가 발생했습니다"}}},pl:{translation:{settings:{title:"Ustawienia Marketplace",optionsHeading:"Opcje",starCountLabel:"Ilość gwiazdek",tagsLabel:"Tagi",showArchived:"Pokaż archiwalne repozytoria",devToolsLabel:"Narzędzia do tworzenia motywów",hideInstalledLabel:"Ukryj zainstalowane podczas przeglądania",colourShiftLabel:"Zmieniaj kolory co minutę",albumArtBasedColors:"Zmień kolory bazując na okładce albumu",albumArtBasedColorsMode:"Tryb schematu kolorów (ColorApi)",albumArtBasedColorsVibrancy:"Kolor pobrany z okładki albumu",albumArtBasedColorsVibrancyToolTip:"Nasycony: Kolor, który jest najbardziej widoczny, ale o znacznie mniejszej jasności. \nJasny wibrujący: Najbardziej żywy kolor, ale z nieco zwiększoną jasnością. \nWyraźny: Kolor, który najbardziej rzuca się w oczy na okładce albumu. \nWibrujący: Najbardziej żywy kolor na okładce albumu",albumArtColorsModeToolTip:"Monochromatyczny ciemny: Schemat kolorów oparty bezpośrednio na wybranym głównym kolorze, wykorzystujący różne odcienie głównego koloru i mieszający szarości w celu stworzenia schematu kolorów, jest to odwrotność Monochromatycznego jasnego. \nMonochromatyczny jasny: Schemat kolorów oparty bezpośrednio na wybranym głównym kolorze, wykorzystujący różne odcienie głównego koloru i mieszanie szarości w celu utworzenia schematu kolorów. Tło monochromatycznego światła będzie na pierwszym planie lub kolorem tekstu w monochromatycznym ciemnym i odwrotnie. \nAnalogowy: Schemat kolorów oparty na wybranym głównym kolorze, wykorzystujący kolory sąsiadujące z głównym kolorem na kole kolorów. \nUzupełnienie analogowe: Schemat kolorów oparty na wybranym głównym kolorze, wykorzystujący kolory sąsiadujące z głównym kolorem na kole kolorów i kolorem uzupełniającym. \nTriada: Schemat kolorów oparty na wybranym głównym kolorze, wykorzystujący kolory na kole kolorów, które są w równej odległości od głównego koloru. \nQuad: Schemat kolorów oparty na wybranym głównym kolorze, wykorzystujący kolory na kole kolorów, które są oddalone o 90 stopni od głównego koloru.",tabsHeading:"Karty",tabsDescription:"Przeciągnij i upuść, aby zmienić kolejność, kliknij, aby włączyć/wyłączyć",resetHeading:"Reset",resetBtn:"Zresetuj",resetDescription:"Odinstaluj wszystkie rozszerzenia, motywy i zresetuj preferencje",backupHeading:"Kopia zapasowa/Przywracanie kopii",backupLabel:"Utwórz kopię zapasową lub przywróć wszystkie dane Marketplace. Kopia nie zawiera ustawień dla rzeczy zainstalowanych poprzez Marketplace.",backupBtn:"Otwórz",versionHeading:"Wersja",versionBtn:"Skopiuj",versionCopied:"Skopiowano"},tabs:{Extensions:"Rozszerzenia",Themes:"Motywy",Snippets:"Snippety",Apps:"Aplikacje",Installed:"Zainstalowane"},snippets:{addTitle:"Dodaj Snippet",duplicateName:"Ta nazwa jest już zajęta!",editTitle:"Edytuj Snippet",viewTitle:"Pokaż Snippet",customCSS:"Niestandardowy CSS",customCSSPlaceholder:"Wprowadź tutaj swój własny CSS! Możesz go znaleźć w zakładce 'Zainstalowane' aby nim zarządzać.",snippetName:"Nazwa snippetu",snippetNamePlaceholder:"Wprowadź nazwę swojego niestandardowego snippetu",snippetDesc:"Opis snippetu",snippetDescPlaceholder:"Wpisz opis swojego snippetu",snippetPreview:"Podgląd snippetu",optional:"Opcjonalne",addImage:"Dodaj obraz",changeImage:"Zmień obraz",saveCSS:"Zapisz CSS"},reloadModal:{title:"Przeładuj",description:"Do ukończenia tej operacji wymagane jest przeładowanie strony.",reloadNow:"Przeładuj teraz",reloadLater:"Przeładuj póżniej"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Skopiowano do schowka",noDataPasted:"Dane nie zostały wklejone",invalidJSON:"Nieprawidłowy JSON",inputLabel:"Ustawienia Marketplace",inputPlaceholder:"Skopiuj/wklej tu swoje ustawienia",exportBtn:"Eksportuj",importBtn:"Importuj",fileImportBtn:"Importuj z pliku"},devTools:{title:"Narzędzia developerskie do motywów",noThemeInstalled:"Błąd: Nie zainstalowano motywu",noThemeManifest:"Błąd: Nie znaleziono pliku manifestu motywu",colorIniEditor:"Edytor color.ini",colorIniEditorPlaceholder:"[nazwa-twojego-koloru]",invalidCSS:"Nieprawidłowy CSS"},updateModal:{title:"Zaktualizuj Marketplace",description:"Zaktualizuj Spicetify Marketplace, aby otrzymywać nowe funkcje i poprawki błędów.",currentVersion:"Obecna wersja: {{version}}",latestVersion:"Najnowsza wersja: {{version}}",whatsChanged:"Co się zmieniło",seeChangelog:"Zobacz zmiany",howToUpgrade:"Jak zaktualizować",viewGuide:"Zobacz przewodnik"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Nowa aktualizacja",addCSS:"Dodaj CSS",search:"Wyszukaj",installed:"Zainstalowane",lastUpdated:"Ostatnio zaktualizowane {{val, datetime}}",externalJS:"zewnętrzny JS",archived:"archiwalny",dark:"ciemny",light:"jasny",sort:{label:"Sortuj po:",stars:"Ilość gwiazdek",newest:"Najnowsze",oldest:"Najstarsze",lastUpdated:"Ostatnio zaktualizowane",mostStale:"Najrzadziej aktualizowane",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Ładowanie...",errorLoading:"Błąd podczas ładowania README"},github:"GitHub",install:"Zainstaluj",remove:"Odinstaluj",save:"Zapisz",colour_one:"kolor",colour_other:"kolory",favourite:"ulubione",notifications:{wrongLocalTheme:'Ustaw current_theme w config-xpui.ini na "marketplace", aby instalować motywy za pomocą Marketplace.',tooManyRequests:"Za dużo żądań, spokojnie",noCdnConnection:"Marketplace nie może połączyć się z CDN. Sprawdź swoją konfigurację internetową",markdownParsingError:"Błąd podczas parsowania markdownu (HTTP {{status}})",noReadmeFile:"Nie znaleziono README",themeInstallationError:"Wystąpił błąd podczas instalacji motywu",extensionInstallationError:"Wystąpił błąd podczas instalacji rozszerzenia"}}},"pt-BR":{translation:{settings:{title:"Opções do Marketplace",optionsHeading:"Opções",starCountLabel:"Quantidade de Estrelas",tagsLabel:"Tags",showArchived:"Exibir repositórios arquivados",devToolsLabel:"Ferramentas para desenvolvedores de temas",hideInstalledLabel:"Ocultar a instalação durante a navegação",colourShiftLabel:"Mudança de cores a cada minuto",albumArtBasedColors:"Alterar as cores com base na arte do álbum",albumArtBasedColorsMode:"Modo de esquema de cores (ColorApi)",albumArtBasedColorsVibrancy:"Cor extraída da arte do álbum",albumArtBasedColorsVibrancyToolTip:"Desaturada: A cor que é a mais proeminente, mas com muito menos brilho \n Vibrante claro: A cor mais vibrante, mas com o brilho um pouco mais intenso \n Proeminente: A cor que mais se destaca na arte do álbum \n Vibrante: A cor mais vibrante na arte do álbum",albumArtColorsModeToolTip:"Monocromático Escuro: um esquema de cores baseado diretamente na cor principal selecionada, usando diferentes tons da cor principal e misturando cinzas para criar um esquema de cores; esse é o inverso do Monocromático claro. \n Monocromática Leve: Um esquema de cores baseado diretamente na cor principal selecionada, usando diferentes tons da cor principal e misturando cinzas para criar um esquema de cores. O plano de fundo do monocromático claro seria o primeiro plano ou a cor do texto no Monocromático Escuro e vice-versa. \n Analogic: A colour scheme based on the main colour selected, using the colours adjacent to the main colour on the colour wheel. \n Analogic Complementary: A colour scheme based on the main colour selected, using the colours adjacent to the main colour on the colour wheel and the complementary colour. \n Triad: A colour scheme based on the main colour selected, using the colours on the colour wheel that are equidistant from the main colour. \n Quad: A colour scheme based on the main colour selected, using the colours on the colour wheel that are 90 degrees from the main colour.",tabsHeading:"Tabs",tabsDescription:"Arraste e solte para reordenar, clique para ativar/desativar",resetHeading:"Resetar",resetBtn:"$t(settings.resetHeading)",resetDescription:"Desinstale todas as extensões e temas e redefina as preferências",backupHeading:"Back up/Restaurar",backupLabel:"Faça backup ou restaure todos os dados do Marketplace. Isto não inclui definições para qualquer coisa instalada através do Marketplace.",backupBtn:"Abrir",versionHeading:"Versão",versionBtn:"Copiar",versionCopied:"Copiado"},tabs:{Extensions:"Extensões",Themes:"Temas",Snippets:"Snippets",Apps:"Aplicativos",Installed:"Instalados"},snippets:{addTitle:"Adicionar Snippet",duplicateName:"Esse nome já está sendo usado!",editTitle:"Editar Snippet",viewTitle:"Ver Snippet",customCSS:"Personalizar CSS",customCSSPlaceholder:"Insira seu próprio CSS personalizado aqui! Você pode encontrá-los na guia instalada para gerenciamento.",snippetName:"Nome do Snippet",snippetNamePlaceholder:"Digite um nome para seu snippet personalizado",snippetDesc:"Descrição do Snippet",snippetDescPlaceholder:"Digite uma descrição para seu snippet personalizado",snippetPreview:"Visualizar Snippets",optional:"Opcional",addImage:"Adicionar Imagem",changeImage:"Mudar imagem",saveCSS:"Salvar o CSS"},reloadModal:{title:"Recarregar",description:"É necessário recarregar a página para concluir essa operação.",reloadNow:"Recarregar agora",reloadLater:"Recarregar mais tarde"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Configurações copiadas para a área de transferência",noDataPasted:"Nenhum dado foi colado",invalidJSON:"JSON inválido",inputLabel:"Configurações do Marketplace",inputPlaceholder:"Copie/cole suas configurações aqui",exportBtn:"Exportar",importBtn:"Importar",fileImportBtn:"Importar de um arquivo"},devTools:{title:"Ferramentas de desenvolvimento de temas",noThemeInstalled:"Erro: Nenhum tema do mercado instalado",noThemeManifest:"Erro: Nenhum manifesto de tema encontrado",colorIniEditor:"Color.ini Editor",colorIniEditorPlaceholder:"[your-colour-scheme-name]",invalidCSS:"CSS inválido"},updateModal:{title:"Atualizar o Marketplace",description:"Atualize o Spicetify Marketplace para receber novos recursos e correções de bugs.",currentVersion:"Versão atual: {{version}}",latestVersion:"Versão mais recente: {{version}}",whatsChanged:"O que mudou",seeChangelog:"Veja o registro de mudanças",howToUpgrade:"Como atualizar",viewGuide:"Ver o guia"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Nova atualização",addCSS:"Adicionar CSS.",search:"Pesquisar",installed:"Instalador",lastUpdated:"Última atualização {{val, datetime}}",externalJS:"external JS",archived:"arquivado",dark:"dark",light:"light",sort:{label:"Classificar por:",stars:"Estrelas",newest:"Mais recente",oldest:"Mais antigo",lastUpdated:"Última atualização",mostStale:"Mais obsoleto",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Carregando...",errorLoading:"Error loading README"},github:"GitHub",install:"Instalar",remove:"Remove-r",save:"Salvar",colour_one:"cor",colour_other:"cores",favourite:"favoritos",notifications:{wrongLocalTheme:"Por favor, defina current_theme em config-xpui.ini para 'marketplace' para instalar temas usando o Marketplace",tooManyRequests:"Muitas solicitações, acalme-se",noCdnConnection:"Marketplace não consegue se conectar à CDN. Verifique sua configuração de Internet",markdownParsingError:"Error parsing markdown (HTTP {{status}})",noReadmeFile:"No README was found",themeInstallationError:"Ocorreu um erro ao instalar o tema",extensionInstallationError:"Ocorreu um erro ao instalar a extensão"}}},ru:{translation:{settings:{title:"Настройки",optionsHeading:"Основные",starCountLabel:"Отображать количество звезд",tagsLabel:"Отображать теги",showArchived:"Отображать архивные репозитории",devToolsLabel:"Включить инструменты разработчика тем",hideInstalledLabel:"Скрывать установленное в других вкладках",colourShiftLabel:"Менять цвета каждую минуту",albumArtBasedColors:"Использовать цвета на основе обложки альбома",albumArtBasedColorsMode:"Тип цвета",albumArtBasedColorsVibrancy:"Тип цветовой схемы на основе обложки альбома",albumArtBasedColorsVibrancyToolTip:"Desaturated: наиболее часто встречаемый в обложке цвет с малой яркостью \n Light Vibrant: самый насыщенный цвет с повышенной яркостью \n Prominent: наиболее часто встречаемый цвет в обложке альбома \n Vibrant: самый насыщенный цвет в обложке альбома",albumArtColorsModeToolTip:"Monochrome Dark, Monochrome Light: основаны иcключительно на выбранном цвете, дополнительные цвета создаются путем изменения яркости основого. Противоположны друг другу: цвет, являющийся фоновым в Monochrome Light, в Monochrome Dark будет цветом переднего плана и наоборот. \n Analogic: палитра определяется выбранным и цветами, смежными с ним на цветовом круге. \n Analogic Complementary: схожа c Analogic, но сожержит также дополнительный цвет. \n Triad: палитра определяется основным цветом и цветами, равноудаленными от него. \n Quad: палитра определяется выбранным цветом и цветами, расположенных под углом 90 градусов к нему.",tabsHeading:"Вкладки",tabsDescription:"Перетаскивание для изменения порядка, щелчок для включения/выключения",resetHeading:"Сброс",resetBtn:"Сбросить",resetDescription:"Удалить все и сбросить настройки",backupHeading:"Резервное копирование и восстановление",backupLabel:"Сохранить или восстановить все данные Маркетплейса, за исключением настроек установленных тем и расширений.",backupBtn:"Открыть",versionHeading:"Версия",versionBtn:"Копировать",versionCopied:"Скопировано"},tabs:{Extensions:"Расширения",Themes:"Темы",Snippets:"Сниппеты",Apps:"Приложения",Installed:"Установленное"},snippets:{addTitle:"Добавление сниппета",duplicateName:"Сниппет с таким названием уже существует",editTitle:"Редактирование сниппета",viewTitle:"Просмотр сниппета",customCSS:"CSS",customCSSPlaceholder:"Вставьте сюда CSS вашего сниппета",snippetName:"Название",snippetNamePlaceholder:"Введите название для вашего сниппета",snippetDesc:"Описание",snippetDescPlaceholder:"Введите описание для вашего сниппета",snippetPreview:"Превью",optional:"необязательно",addImage:"Добавить изображение",changeImage:"Изменить изображение",saveCSS:"Сохранить"},reloadModal:{title:"Перезагрузка",description:"Необходима перезагрузка страницы для применения изменений",reloadNow:"Перезагрузить сейчас",reloadLater:"Перезагрузить позже"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Настройки скопированы в буфер обмена",noDataPasted:"Ничего не вставлено",invalidJSON:"Неверный JSON",inputLabel:"Настройки Маркетплейса",inputPlaceholder:"Вставьте ваши настройки сюда",exportBtn:"Экспортировать",importBtn:"Импортировать",fileImportBtn:"Импортировать из файла"},devTools:{title:"Инструменты разработчика тем",noThemeInstalled:"Ошибка: Не установлена тема из Маркетплейса",noThemeManifest:"Ошибка: Не найден манифест темы",colorIniEditor:"Редактор color.ini",colorIniEditorPlaceholder:"[название-вашей-цветовой-схемы]",invalidCSS:"Неверный CSS"},updateModal:{title:"Обновление Маркетплейса",description:"Обновите Маркетплейс для получения новых функций и исправлений.",currentVersion:"Текущая версия: {{version}}",latestVersion:"Последняя версия: {{version}}",whatsChanged:"Что нового",seeChangelog:"Посмотреть изменения",howToUpgrade:"Инструкция по обновлению",viewGuide:"Посмотреть инструкцию"},grid:{spicetifyMarketplace:"Маркетплейс Spicetify",newUpdate:"Доступно обновление",addCSS:"Добавить CSS",search:"Искать",installed:"Установлено",lastUpdated:"Обновлено: {{val, datetime}}",externalJS:"содержит JS",archived:"архивировано",dark:"темный",light:"светлый",sort:{label:"Сортировать:",stars:"по количеству звезд",newest:"сначала новые",oldest:"сначала старые",lastUpdated:"сначала недавно обновленные",mostStale:"сначала давно не обновлявшиеся",aToZ:"по названию (A-Z)",zToA:"по названию (Z-A)"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Загрузка...",errorLoading:"Ошибка загрузки README"},github:"GitHub",install:"Установить",remove:"Удалить",save:"Сохранить",colour_one:"цвет",colour_other:"цвета",favourite:"избранное",notifications:{wrongLocalTheme:"Пожалуйста, измените значение current_theme в config-xpui.ini на 'marketplace', чтобы использовать темы из Маркетплейса",tooManyRequests:"Слишком много запросов. Пожалуйста, попробуйте позже",noCdnConnection:"Маркетплейс не может подключиться к CDN. Пожалуйста, попробуйте позже",markdownParsingError:"Ошибка при парсинге Markdown (HTTP {{status}})",noReadmeFile:"README не найден",themeInstallationError:"Ошибка при установке темы",extensionInstallationError:"Ошибка при установке расширения"}}},tr:{translation:{settings:{title:"Marketplace Ayarları",optionsHeading:"Seçenekler",starCountLabel:"Yıldız sayısı",tagsLabel:"Etiketler",showArchived:"Arşivlenmiş repoları göster",devToolsLabel:"Tema geliştirici araçları",hideInstalledLabel:"Göz atarken yüklü olanları gizle",colourShiftLabel:"Renkleri her dakika değiştir",albumArtBasedColors:"Albüm kapağına göre renkleri değiştir",albumArtBasedColorsMode:"Renk şeması (ColorApi) modu",albumArtBasedColorsVibrancy:"Albüm kapağından alınan renk",albumArtBasedColorsVibrancyToolTip:"Doygunluğu Azaltılmış: En belirgin olan ancak çok daha az parlaklığa sahip renk \n Açık Canlı: En canlı renk, ancak parlaklığı bir miktar artırılmış \n Öne Çıkan: Albüm kapağında en çok göze çarpan renk \n Canlı: Albüm kapağındaki en canlı renk",albumArtColorsModeToolTip:"Monokrom Koyu: Seçilen ana renge dayalı, ana rengin farklı tonlarını kullanan ve gri tonlarıyla karıştırarak bir renk şeması oluşturan bir düzen. Monokrom Açık'ın tersidir. \n Monokrom Açık: Seçilen ana renge dayalı, ana rengin farklı tonlarını kullanan ve gri tonlarıyla karıştırarak bir renk şeması oluşturan bir düzen. Monokrom Açık'ın arka planı, Monokrom Koyu'daki ön plan veya metin rengi olacaktır ve tam tersi. \n Analog: Seçilen ana renge dayalı, renk çarkında ana rengin bitişiğindeki renkleri kullanan bir renk şeması. \n Analog Tamamlayıcı: Seçilen ana renge dayalı, renk çarkında ana rengin bitişiğindeki renkleri ve tamamlayıcı rengi kullanan bir renk şeması. \n Üçlü: Seçilen ana renge dayalı, renk çarkında ana renge eşit uzaklıktaki renkleri kullanan bir renk şeması. \n Dörtlü: Seçilen ana renge dayalı, renk çarkında ana renge 90 derece uzaklıktaki renkleri kullanan bir renk şeması.",tabsHeading:"Sekmeler",tabsDescription:"Yeniden sıralamak için sürükleyip bırakın, etkinleştirmek/devre dışı bırakmak için tıklayın",resetHeading:"Sıfırla",resetBtn:"$t(settings.resetHeading)",resetDescription:"Tüm eklentileri ve temaları kaldırıp tercihleri sıfırla",backupHeading:"Yedekle/Geri Yükle",backupLabel:"Tüm Marketplace verilerini yedekleyin veya geri yükleyin. Bu, Marketplace ile yüklenen öğelerin ayarlarını kapsamaz.",backupBtn:"Aç",versionHeading:"Sürüm",versionBtn:"Kopyala",versionCopied:"Kopyalandı"},tabs:{Extensions:"Eklentiler",Themes:"Temalar",Snippets:"Snippet'ler",Apps:"Uygulamalar",Installed:"Yüklenenler"},snippets:{addTitle:"Snippet Ekle",duplicateName:"Bu isim zaten alınmış!",editTitle:"Snippet'i Düzenle",viewTitle:"Snippet'i Görüntüle",customCSS:"Özel CSS",customCSSPlaceholder:"Kendi özel CSS'inizi buraya girin. Yönetim için snippet'leri Yüklenenler sekmesinde bulabilirsiniz.",snippetName:"Snippet Adı",snippetNamePlaceholder:"Özel snippet'iniz için bir ad girin",snippetDesc:"Snippet Açıklaması",snippetDescPlaceholder:"Özel snippet'iniz için bir açıklama girin",snippetPreview:"Snippet Önizlemesi",optional:"İsteğe Bağlı",addImage:"Resim ekle",changeImage:"Resmi değiştir",saveCSS:"CSS'i Kaydet"},reloadModal:{title:"Yeniden Yükle",description:"Bu işlemi tamamlamak için sayfanın yeniden yüklenmesi gerekiyor.",reloadNow:"Şimdi yeniden yükle",reloadLater:"Daha sonra yeniden yükle"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Ayarlar panoya kopyalandı",noDataPasted:"Yapıştırılan veri yok",invalidJSON:"Geçersiz JSON",inputLabel:"Marketplace Ayarları",inputPlaceholder:"Ayarlarınızı buraya kopyalayıp yapıştırın",exportBtn:"Dışa Aktar",importBtn:"İçe Aktar",fileImportBtn:"Dosyadan içe aktar"},devTools:{title:"Tema Geliştirici Araçları",noThemeInstalled:"Hata: Yüklü bir marketplace teması yok",noThemeManifest:"Hata: Tema manifestosu bulunamadı",colorIniEditor:"Color.ini Düzenleyici",colorIniEditorPlaceholder:"[renk-semanızın-adı]",invalidCSS:"Geçersiz CSS"},updateModal:{title:"Marketplace'i Güncelle",description:"Yeni özellikleri ve hata düzeltmelerini almak için Spicetify Marketplace'i güncelleyin.",currentVersion:"Mevcut sürüm: {{version}}",latestVersion:"En son sürüm: {{version}}",whatsChanged:"Neler Değişti",seeChangelog:"Değişiklik günlüğünü gör",howToUpgrade:"Nasıl yükseltilir",viewGuide:"Rehberi görüntüle"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"Yeni güncelleme",addCSS:"CSS Ekle",search:"Ara",installed:"Yüklü",lastUpdated:"Son güncelleme: {{val, datetime}}",externalJS:"harici JS",archived:"arşivlenmiş",dark:"koyu",light:"açık",sort:{label:"Sırala:",stars:"Yıldız",newest:"En Yeni",oldest:"En Eski",lastUpdated:"Son Güncellenen",mostStale:"En Eski Güncelleme",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Benioku",loading:"Yükleniyor...",errorLoading:"README yüklenirken hata oluştu"},github:"GitHub",install:"Yükle",remove:"Kaldır",save:"Kaydet",colour_one:"renk",colour_other:"renkler",favourite:"favori",notifications:{wrongLocalTheme:"Marketplace kullanarak tema yüklemek için lütfen config-xpui.ini dosyasındaki current_theme ayarını 'marketplace' olarak değiştir",tooManyRequests:"Çok fazla istek gönderildi, lütfen bekleyin",noCdnConnection:"Marketplace, CDN'e bağlanamıyor. Lütfen internet bağlantınızı kontrol edin",markdownParsingError:"Markdown ayrıştırılırken hata oluştu (HTTP {{status}})",noReadmeFile:"README dosyası bulunamadı",themeInstallationError:"Tema yüklenirken bir hata oluştu",extensionInstallationError:"Eklenti yüklenirken bir hata oluştu"}}},uk:{translation:{settings:{title:"Налаштування Маркетплейсу",optionsHeading:"Налаштування",starCountLabel:"Кількість зірок",tagsLabel:"Теги",showArchived:"Показати заархівовані репозиторії",devToolsLabel:"Інструменти розробника тем",hideInstalledLabel:"Сховати встановлені",colourShiftLabel:"Змінювати колір кожну хвилину",albumArtBasedColors:"Змінювати колір в залежності від обкладинки альбому",albumArtBasedColorsMode:"Кольорова схема (ColorApi)",albumArtBasedColorsVibrancy:"Колір взято з обкладинки альбому",albumArtBasedColorsVibrancyToolTip:"Насичений: Колір, який є найбільш помітним, але з набагато меншою яскравістю \n Light Vibrant (Яскравий): Найяскравіший колір, але з дещо підвищеною яскравістю \n Виразний: Колір, який найбільше виділяється на обкладинці альбому \n Яскравий: Найяскравіший колір на обкладинці альбому",albumArtColorsModeToolTip:"Монохромний темний: кольорова схема, що базується безпосередньо на вибраному основному кольорі, з використанням різних відтінків основного кольору та змішуванням сірих кольорів для створення кольорової схеми, це протилежність монохромного світлого. \n Монохромний світлий: Кольорова схема, що базується безпосередньо на вибраному основному кольорі, з використанням різних відтінків основного кольору та змішуванням сірих кольорів для створення кольорової схеми. Тло монохромного світлого буде переднім планом або кольором тексту на монохромному темному, і навпаки. \n Аналоговий: Кольорова схема, заснована на вибраному основному кольорі з використанням кольорів, суміжних з основним кольором на колірному колі. \n Аналогово-доповнювальна: Кольорова схема на основі вибраного основного кольору з використанням сусідніх з ним кольорів на колірному колі та додаткового кольору. \n Тріада: Кольорова схема на основі вибраного основного кольору з використанням кольорів на колі кольорів, рівновіддалених від основного кольору. \n Квадрат: Кольорова схема на основі вибраного основного кольору з використанням кольорів на колі кольорів, розташованих під кутом 90 градусів до основного кольору.",tabsHeading:"Вкладки",tabsDescription:"Перетягніть, щоб змінити порядок, натисніть, щоб увімкнути/вимкнути",resetHeading:"Скинути",resetBtn:"$t(settings.resetHeading)",resetDescription:"Видалити усі розширення і теми, та скинути налаштування",backupHeading:"Резервне копіювання/Відновлення",backupLabel:"Копіювати або відновити всі дані Маркетплейсу. Це не включає в себе налаштування всього, що встановлено через Маркетплейс",backupBtn:"Відкрити",versionHeading:"Версія",versionBtn:"Копіювати",versionCopied:"Скопійовано"},tabs:{Extensions:"Розширення",Themes:"Теми",Snippets:"Фрагменти",Apps:"Застосунки",Installed:"Встановлено"},snippets:{addTitle:"Додати фрагмент",duplicateName:"Ця назва вже зайнята!",editTitle:"Редагувати фрагмент",viewTitle:"Переглянути фрагмент",customCSS:"Користувацький CSS",customCSSPlaceholder:"Введіть свій власний CSS тут! Ви можете знайти їх у вкладці управління встановленими файлами.",snippetName:"Назва фрагменту",snippetNamePlaceholder:"Введіть ім'я для вашого користувацького фрагменту",snippetDesc:"Опис фрагменту",snippetDescPlaceholder:"Введіть опис для вашого користувацького фрагменту",snippetPreview:"Перегляд фрагменту",optional:"Необов'язковий",addImage:"Додати світлину",changeImage:"Змінити світлину",saveCSS:"Зберегти CSS"},reloadModal:{title:"Перезавантажити",description:"Для завершення цієї операції потрібно перезавантажити сторінку",reloadNow:"Перезавантажити зараз",reloadLater:"Перезавантажити пізніше"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"Налаштування скопійовано у буфер обміну",noDataPasted:"Дані не вставлено",invalidJSON:"Недійсний JSON",inputLabel:"Налаштування Маркетплейсу",inputPlaceholder:"Скопіювати/вставити свої налаштування сюди",exportBtn:"Експорт",importBtn:"Імпорт",fileImportBtn:"Імпортувати з файлу"},devTools:{title:"Інструменти розробника тем",noThemeInstalled:"Помилка: Тему Маркетплейсу не встановлено",noThemeManifest:"Помилка: маніфест теми не знайдено",colorIniEditor:"Редактор Color.ini",colorIniEditorPlaceholder:"[your-colour-scheme-name]",invalidCSS:"Недійсний CSS"},updateModal:{title:"Оновити Маркетплейс",description:"Оновіть Spicetify Marketplace щоб отримувати нові функції і багфікси.",currentVersion:"Поточна версія: {{version}}",latestVersion:"Остання версія: {{version}}",whatsChanged:"Що змінилося",seeChangelog:"Переглянути список змін",howToUpgrade:"Як оновлюватися",viewGuide:"Переглянути посібник"},grid:{spicetifyMarketplace:"Маркетплейс Spicetify",newUpdate:"Нове оновлення",addCSS:"Додати CSS",search:"Пошук",installed:"Встановлено",lastUpdated:"Востаннє оновлено {{val, datetime}}",externalJS:"зовнішній JS",archived:"заархівоване",dark:"темний",light:"світлий",sort:{label:"Сортувати за:",stars:"Зірки",newest:"Новіші",oldest:"Старіші",lastUpdated:"Останнє оновлене",mostStale:"Найнесвіжіший",aToZ:"A-Z",zToA:"Z-A"}},readmePage:{title:"$t(grid.spicetifyMarketplace) - Readme",loading:"Завантаження...",errorLoading:"Помилка завантаження README"},github:"GitHub",install:"Встановити",remove:"Видалити",save:"Зберегти",colour_one:"колір",colour_other:"кольори",favourite:"улюблене",notifications:{wrongLocalTheme:"Будь ласка, поставте 'marketplace' у змінну current_theme у файлі config-xpui.ini щоб встановлювати теми за допомогою Маркетплейсу",tooManyRequests:"Забагато запитів, зачекайте",noCdnConnection:"Маркетплейс не може зв'язатися з CDN. Будь ласка, перевірте вашу конфігурацію Інтернету",markdownParsingError:"Помилка розбору markdown (HTTP {{status}})",noReadmeFile:"README не знайдено",themeInstallationError:"Сталася помилка при встановленні теми",extensionInstallationError:"Сталася помилка при встановленні розширення"}}},"zh-CN":{translation:{settings:{title:"设置",optionsHeading:"选项",starCountLabel:"收藏数",tagsLabel:"标签",devToolsLabel:"主題开发者工具",hideInstalledLabel:"浏览时隐藏已安装项目",colourShiftLabel:"每分钟进行色调偏移",tabsHeading:"分页",tabsDescription:"拖放更改顺序,点击启用/禁用",resetHeading:"重置",resetBtn:"$t(settings.resetHeading)",resetDescription:"卸载所有扩展插件和主题,并重置设置"},tabs:{Extensions:"扩展插件",Themes:"主题",Snippets:"微调片段",Apps:"功能模组",Installed:"已安裝项目"},snippets:{addTitle:"加入微调片段",editTitle:"编辑微调片段",viewTitle:"检视微调片段",customCSS:"自定义 CSS",customCSSPlaceholder:"这里可以输入您的自定义 CSS!您可以在「已安裝项目」标签页中看到这些片段,进而进行管理。",snippetName:"微调片段名称",snippetNamePlaceholder:"输入自定义微调片段的名称",snippetDesc:"微调片段描述",snippetDescPlaceholder:"输入自定义微调片段的描述",snippetPreview:"微调片段预览图",optional:"非必要",addImage:"加入影像",changeImage:"更改影像",saveCSS:"保存 CSS"},reloadModal:{title:"重新加载",description:"需要重新加载页面,才能完成这个操作。",reloadNow:"立即重新加载",reloadLater:"稍后重新加载"},devTools:{title:"主題开发者工具",noThemeInstalled:"错误:未安装商场主题",noThemeManifest:"错误:找不到主题内容清单",colorIniEditor:"Color.ini 编辑器",colorIniEditorPlaceholder:"[您的色彩配置名称]",invalidCSS:"CSS 无效"},grid:{spicetifyMarketplace:"Spicetify 商场",newUpdate:"有更新",addCSS:"加入 CSS",search:"搜索",installed:"已安装",lastUpdated:"上次更新于 {{val, datetime}}",externalJS:"有外部 JS",dark:"暗色模式",light:"亮色模式"},readmePage:{title:"$t(grid.spicetifyMarketplace) – 说明",loading:"正在加载……",errorLoading:"加载 README 时发生错误"},github:"GitHub",install:"安裝",remove:"移除",save:"保存",colour_one:"色彩",colour_other:"色彩",favourite:"收藏"}},"zh-TW":{translation:{settings:{title:"設定",optionsHeading:"選項",starCountLabel:"收藏數",tagsLabel:"標籤",devToolsLabel:"主題開發者工具",hideInstalledLabel:"瀏覽時隱藏已安裝項目",colourShiftLabel:"每分鐘進行色調偏移",tabsHeading:"分頁",tabsDescription:"拖放更改顺序,点击启用/禁用",resetHeading:"重設",resetBtn:"$t(settings.resetHeading)",resetDescription:"解除安裝所有擴充套件和主題, 並重設偏好設定",backupHeading:"備份與還原",backupLabel:"備份或還原所有 Marketplace 中的資料(不包含從 Marketplace 安裝的擴充元件的設定)。",backupBtn:"開啟",albumArtBasedColors:"根據專輯封面選色",albumArtBasedColorsMode:"色彩方案 (ColorApi) 模式",albumArtBasedColorsVibrancy:"已從專輯封面抽取顏色",albumArtBasedColorsVibrancyToolTip:"Desaturated:最突出但亮度較低的顏色 \n Light Vibrant:最接近 Vibrant 的色彩,但亮度稍微提升一些 \n Prominent:專輯封面裡面出現最多的色彩 \n Vibrant:專輯中最明亮的色彩",albumArtColorsModeToolTip:"Monochrome Dark:這個色彩方案直接以選擇的主色彩為基礎,但使用比較不一樣的色調並且融入灰色。這和 Monochrome Light 正好相反。 \n Monochrome Light:這個色彩方案直接以選擇的主色彩為基礎,但使用比較不一樣的色調並且融入灰色。這和 Monochrome Light 正好相反。Monochrome Light 的背景色會是 Monochrome Dark 的前景或文字顏色,反之亦然。 \n Analogic:這個色彩方案以選擇的主色彩為基礎,使用色環上主色彩鄰近的色彩。 \n Analogic Complementary:這個色彩方案以選擇的主色彩為基礎,使用色環上主色彩鄰近的色彩以及互補色。 \n Triad:這個色彩方案以選擇的主色彩為基礎,使用色環上和主色彩距離相等的顏色。 \n Quad:這個色彩方案以選擇的主色彩為基礎,使用色環上和主色彩差 90 度的顏色。",versionHeading:"版本",versionBtn:"複製",versionCopied:"已複製"},tabs:{Extensions:"擴充套件",Themes:"主題",Snippets:"微調片段",Apps:"功能模組",Installed:"已安裝項目"},snippets:{addTitle:"加入微調片段",editTitle:"編輯微調片段",viewTitle:"檢視微調片段",customCSS:"自訂 CSS",customCSSPlaceholder:"這裡可以輸入您的自訂 CSS!您可以在「已安裝項目」分頁中看到這些片段,進而進行管理。",snippetName:"微調片段名稱",snippetNamePlaceholder:"輸入自訂微調片段的名稱",snippetDesc:"微調片段描述",snippetDescPlaceholder:"輸入自訂微調片段的描述",snippetPreview:"微調片段預覽圖",optional:"非必須",addImage:"加入影像",changeImage:"更改影像",saveCSS:"儲存 CSS"},reloadModal:{title:"重新載入",description:"需要重新載入頁面,才能完成這個操作。",reloadNow:"立即重新載入",reloadLater:"稍後重新載入"},backupModal:{title:"$t(settings.backupHeading)",settingsCopied:"已將設定複製至剪貼簿",noDataPasted:"沒有貼上資料",invalidJSON:"JSON 無效",inputLabel:"Marketplace 設定",inputPlaceholder:"在此複製或貼上設定",exportBtn:"匯出",importBtn:"匯入",fileImportBtn:"從檔案匯入"},devTools:{title:"主題開發者工具",noThemeInstalled:"錯誤:沒有安裝 Marketplace 主題",noThemeManifest:"錯誤:找不到主題資訊清單",colorIniEditor:"Color.ini 編輯器",colorIniEditorPlaceholder:"[您的色彩配置名稱]",invalidCSS:"CSS 無效"},grid:{spicetifyMarketplace:"Spicetify Marketplace",newUpdate:"有更新",addCSS:"加入 CSS",search:"搜尋",installed:"已經安裝",lastUpdated:"上次更新於 {{val, datetime}}",externalJS:"有外部 JS",dark:"暗色",light:"亮色"},readmePage:{title:"$t(grid.spicetifyMarketplace) – 說明",loading:"正在載入……",errorLoading:"載入 README 時發生錯誤"},github:"GitHub",install:"安裝",remove:"移除",save:"儲存",colour_one:"色彩",colour_other:"色彩",favourite:"收藏"}}};n.use(_).use(ta).init({resources:Fn,detection:{order:["navigator","htmlTag"]},fallbackLng:"en",interpolation:{escapeValue:!1}});var $m=Aa()(class extends ia.default.Component{state={count:0,CONFIG:{}};CONFIG;constructor(e){super(e);e=N(I.tabs,null);let t=[];try{if(t=e,!Array.isArray(t))throw new Error("Could not parse marketplace tabs key");if(0===t.length)throw new Error("Empty marketplace tabs key");if(0!e).length)throw new Error("Falsey marketplace tabs key")}catch{t=La,localStorage.setItem(I.tabs,JSON.stringify(t))}let a={},r=null;try{var n=N(I.themeInstalled,null);if(n){var o=N(n,null);if(!o)throw new Error("No installed theme data");a=o.schemes,r=o.activeScheme}else console.debug("No theme set as installed")}catch(e){console.error(e)}this.CONFIG={visual:{stars:JSON.parse(N("marketplace:stars",!0)),tags:JSON.parse(N("marketplace:tags",!0)),showArchived:JSON.parse(N("marketplace:showArchived",!1)),hideInstalled:JSON.parse(N("marketplace:hideInstalled",!1)),colorShift:JSON.parse(N("marketplace:colorShift",!1)),themeDevTools:JSON.parse(N("marketplace:themeDevTools",!1)),albumArtBasedColors:JSON.parse(N("marketplace:albumArtBasedColors",!1)),albumArtBasedColorsMode:N("marketplace:albumArtBasedColorsMode")||"monochrome-light",albumArtBasedColorsVibrancy:N("marketplace:albumArtBasedColorsVibrancy")||"PROMINENT",type:JSON.parse(N("marketplace:type",!1)),followers:JSON.parse(N("marketplace:followers",!1))},tabs:t,activeTab:N(I.activeTab,t[0]),theme:{activeThemeKey:N(I.themeInstalled,null),schemes:a,activeScheme:r},sort:N(I.sort,"stars")},this.CONFIG.activeTab&&this.CONFIG.tabs.filter(e=>e.name===this.CONFIG.activeTab).length||(this.CONFIG.activeTab=this.CONFIG.tabs[0].name)}updateConfig=e=>{this.CONFIG={...e},console.debug("updated config",this.CONFIG),this.setState({CONFIG:{...e}})};render(){var{location:e,replace:t}=Spicetify.Platform.History;return e.pathname===Pa+"/readme"?e.state?.data?ia.default.createElement(jm,{title:y("readmePage.title"),data:e.state.data}):(t(Pa),null):ia.default.createElement(_m,{title:y("grid.spicetifyMarketplace"),CONFIG:this.CONFIG,updateAppConfig:this.updateConfig})}}),zm=t(a());return Vn=ze,R(A({},"__esModule",{value:!0}),Vn)})();const render=()=>marketplace.default(); \ No newline at end of file diff --git a/.config/spicetify/CustomApps/marketplace/manifest.json b/.config/spicetify/CustomApps/marketplace/manifest.json deleted file mode 100644 index 0ce32b5..0000000 --- a/.config/spicetify/CustomApps/marketplace/manifest.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "name": { - "en": "Marketplace", - "ru": "Маркетплейс" - }, - "icon": "\n", - "active-icon": "\n", - "subfiles": [], - "subfiles_extension": [ - "extension.js" - ] -} \ No newline at end of file diff --git a/.config/spicetify/CustomApps/marketplace/style.css b/.config/spicetify/CustomApps/marketplace/style.css deleted file mode 100644 index 2df65a8..0000000 --- a/.config/spicetify/CustomApps/marketplace/style.css +++ /dev/null @@ -1 +0,0 @@ -@charset "UTF-8";code[class*=language-],pre[class*=language-]{color:#ccc;background:0 0;font-family:Consolas,Monaco,"Andale Mono","Ubuntu Mono",monospace;font-size:1em;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;hyphens:none}pre[class*=language-]{padding:1em;margin:.5em 0;overflow:auto}:not(pre)>code[class*=language-],pre[class*=language-]{background:#2d2d2d}:not(pre)>code[class*=language-]{padding:.1em;border-radius:.3em;white-space:normal}.token.block-comment,.token.cdata,.token.comment,.token.doctype,.token.prolog{color:#999}.token.punctuation{color:#ccc}.token.attr-name,.token.deleted,.token.namespace,.token.tag{color:#e2777a}.token.function-name{color:#6196cc}.token.boolean,.token.function,.token.number{color:#f08d49}.token.class-name,.token.constant,.token.property,.token.symbol{color:#f8c555}.token.atrule,.token.builtin,.token.important,.token.keyword,.token.selector{color:#cc99cd}.token.attr-value,.token.char,.token.regex,.token.string,.token.variable{color:#7ec699}.token.entity,.token.operator,.token.url{color:#67cdcc}.token.bold,.token.important{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.token.inserted{color:green}#marketplace-add-snippet-container{display:flex;flex-direction:column;gap:16px}#marketplace-add-snippet-container #marketplace-custom-css:focus-visible{outline:0}.marketplace-customCSS-input-container{display:flex;flex-direction:column}img.marketplace-customCSS-image-preview{aspect-ratio:1;width:100%;height:auto;max-width:400px;-o-object-fit:cover;object-fit:cover;margin:0 auto}#marketplace-customCSS-submit{margin-left:auto}.marketplace-backup-button{padding:10px;margin:10px}.marketplace-card-type-heading{margin:1em 0 .5em;color:var(--spice-subtext);font-size:1.3em}.marketplace-grid .main-card-draggable{display:flex;flex-direction:column}.marketplace-grid .main-card-draggable .main-card-cardMetadata{flex-grow:1;display:flex;flex-direction:column}.marketplace-grid .main-card-draggable .main-card-cardMetadata .main-cardHeader-link:hover{text-decoration:underline}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__author~.marketplace-card__author::before{content:", "}.marketplace-grid .main-card-draggable .main-card-cardMetadata ul.marketplace-card__tags{display:flex;flex-wrap:wrap;gap:8px}.marketplace-grid .main-card-draggable .main-card-cardMetadata li.marketplace-card__tag{background-color:var(--spice-tab-active);border-radius:4px;padding:0 9px 2px}.marketplace-grid .main-card-draggable .main-card-cardMetadata li.marketplace-card__tag[data-tag="external JS"],.marketplace-grid .main-card-draggable .main-card-cardMetadata li.marketplace-card__tag[data-tag=archived]{background-color:#db3737;color:#fff}.marketplace-grid .main-card-draggable .main-card-cardMetadata li.marketplace-card__tag[data-tag=dark]{background-color:#000;color:#fff}.marketplace-grid .main-card-draggable .main-card-cardMetadata li.marketplace-card__tag[data-tag=light]{background-color:#fff;color:#333}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__tags-more-btn{background-color:var(--spice-tab-active);border-radius:4px;padding:0 9px 2px;margin-top:8px;border:none}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__tags-more-btn:focus,.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__tags-more-btn:hover{filter:brightness(1.4)}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card-desc{font:-webkit-small-control;margin:12px 0;display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:3}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__bottom-meta{margin-top:auto;margin-bottom:0}.marketplace-grid .main-card-draggable .main-card-cardMetadata .marketplace-card__bottom-meta+.marketplace-card__bottom-meta{margin-top:8px}.marketplace-grid[data-tab=Installed]:empty::after{content:"No installed " attr(data-card-type);display:block}.main-cardImage-imageWrapper--error::before{content:"";display:block;position:absolute;overflow:hidden;top:0;left:0;bottom:0;right:0;height:100%;width:100%;background-color:var(--spice-subtext);filter:brightness(50%);clip-path:path("M41.20833,21.5c-2.54758,0.00136 -4.90298,1.35492 -6.18685,3.55534l-12.54167,21.5c-0.64062,1.09578 -0.97875,2.34203 -0.97982,3.61133v86c0,7.83362 6.49972,14.33333 14.33333,14.33333h100.33333c7.83362,0 14.33333,-6.49972 14.33333,-14.33333v-86c-0.00107,-1.2693 -0.3392,-2.51555 -0.97982,-3.61133l-12.54167,-21.5c-1.28387,-2.20042 -3.63926,-3.55398 -6.18685,-3.55534zM45.32357,35.83333h81.35286l8.35645,14.33333h-98.06576zM35.83333,64.5h100.33333v71.66667h-100.33333zM64.5,78.83333v14.33333h43v-14.33333z");clip-rule:nonzero;transform:scale(.5)}.main-cardImage-imageWrapper--error{box-shadow:none}.main-card-card:hover .main-cardImage-imageWrapper--error::before{filter:brightness(100%)}.marketplace-cardSubHeader,.marketplace-card__bottom-meta{margin-top:4px;white-space:normal;color:var(--spice-subtext)}.marketplace-cardSubHeader{display:flex;flex-direction:column;gap:8px}.marketplace-card--installed{flex:0!important;-webkit-box-flex:0!important;border:1px solid var(--spice-button)}.marketplace-installButton{cursor:pointer;--size:40px}.marketplace-code-editor{width:100%;margin-bottom:10px;padding:3px 5px;background-color:var(--spice-main);color:var(--spice-text);font-size:14px;border:1px solid var(--spice-button);border-radius:4px}.devtools-column{height:570px;width:50%;position:relative;background-color:var(--spice-sidebar);color:var(--spice-text);overflow:scroll;padding:1rem}.color-ini-editor{height:70%;width:100%;background-color:var(--spice-sidebar);color:var(--spice-text);overflow:scroll;padding:1rem;resize:none;font-family:monospace}.marketplace-theme-dev-tools-container{justify-content:flex-end;display:flex}.marketplace-theme-dev-tools-container .marketplace-code-editor-wrapper{height:400px;margin-bottom:16px;overflow:auto}.devtools-heading,.invalid-css-heading{font-size:1.5rem;font-weight:700;text-decoration:underline;margin-bottom:1rem}.invalid-css-text{margin-bottom:1.5rem;font-family:monospace;-webkit-user-select:text;-moz-user-select:text;user-select:text}.devtools-icon{width:18px;fill:var(--spice-button)}.arrow-closed,.arrow-open{border:solid rgba(var(--spice-rgb-text),.7);border-width:0 2px 2px 0;display:inline-block;padding:4px;position:absolute;right:10px}.arrow-closed{top:10px;transform:rotate(45deg);-webkit-transform:rotate(45deg)}.arrow-open{top:14px;transform:rotate(-135deg);-webkit-transform:rotate(-135deg)}.Dropdown-root{position:relative}.Dropdown-root.is-open .Dropdown-control{border-bottom-left-radius:0;border-bottom-right-radius:0}.Dropdown-root.is-open .Dropdown-control:hover .Dropdown-arrow{border-color:transparent transparent rgb(var(--spice-rgb-text))}.Dropdown-root.is-open .Dropdown-arrow{border-color:transparent transparent rgba(var(--spice-rgb-text),.7);border-width:0 5px 5px}.Dropdown-root.is-open .Dropdown-menu{border-top-left-radius:0;border-top-right-radius:0;width:-moz-max-content;width:max-content}.Dropdown-control{position:relative;overflow:hidden;background-color:var(--spice-sidebar);border:0;border-radius:8px;box-sizing:border-box;color:rgba(var(--spice-rgb-text),.7);cursor:default;outline:0;padding:8px 36px 8px 16px;transition:all .2s ease}.Dropdown-control:hover{color:rgb(var(--spice-rgb-text));background-color:var(--spice-button-disabled)}.Dropdown-control:hover .Dropdown-arrow{border-color:rgb(var(--spice-rgb-text)) transparent transparent}.Dropdown-arrow{border-color:rgba(var(--spice-rgb-text),.7) transparent transparent;border-style:solid;border-width:5px 5px 0;content:" ";display:block;height:0;margin-top:-ceil(2.5);position:absolute;right:16px;top:18px;width:0}.Dropdown-menu{background-color:var(--spice-sidebar);border:0;border-radius:8px;box-shadow:0 1px 0 rgba(0,0,0,.06);box-sizing:border-box;margin-top:-1px;max-height:200px;overflow-y:auto;position:absolute;top:100%;width:100%;z-index:1000;-webkit-overflow-scrolling:touch}.Dropdown-menu .Dropdown-group>.Dropdown-title{padding:8px 10px;color:#333;font-weight:700;text-transform:capitalize}.Dropdown-option{box-sizing:border-box;color:rgba(var(--spice-rgb-text),.7);cursor:pointer;display:block;padding:8px 10px}.Dropdown-option:last-child{border-bottom-right-radius:8px;border-bottom-left-radius:8px}.Dropdown-option.is-selected{background-color:rgba(var(--spice-rgb-text),.7);color:var(--spice-sidebar)}.Dropdown-option:hover{background-color:rgb(var(--spice-rgb-text));color:var(--spice-sidebar)}.Dropdown-noresults{box-sizing:border-box;color:#ccc;cursor:default;display:block;padding:8px 10px}.GenericModal{background-color:var(--spice-player)}.main-topBar-container:has(.marketplace-tabBar){contain:unset}.marketplace-header{-webkit-box-pack:justify;-webkit-box-align:center;align-content:space-between;align-items:center;color:var(--spice-text);background-color:var(--spice-main);display:flex;justify-content:space-between;padding-bottom:8px;position:sticky;flex-direction:row;top:64px;z-index:1}.contentSpacing:has(#marketplace-readme) .marketplace-header{top:0}.marketplace-header__left,.marketplace-header__right{display:flex}.marketplace-header__left>:is(div,button),.marketplace-header__right>:is(div,button){margin-left:8px}.marketplace-header__label{display:inline-flex;align-self:center}.marketplace-grid{--minimumColumnWidth:180px;--column-width:minmax(var(--minimumColumnWidth), 1fr);--column-count:auto-fill;--grid-gap:24px}.marketplace-sort-bar{align-items:center;display:flex}.marketplace-sort-container{position:relative;display:flex}.marketplace-tabBar-headerItem{-webkit-app-region:no-drag;display:inline-block;pointer-events:auto;vertical-align:middle}.marketplace-tabBar-active{background-color:var(--spice-tab-active);border-radius:4px}.marketplace-tabBar-headerItemLink{border-radius:4px;color:var(--spice-text);display:inline-block;margin:0 8px 0 0;padding:8px 16px;position:relative;text-decoration:none!important;cursor:pointer}.marketplace-tabBar-nav{-webkit-app-region:drag;pointer-events:none;width:100%}.marketplace-tabBar-headerItem .optionsMenu-dropBox{color:var(--spice-text);border:0;max-width:150px;height:42px;padding:0 30px 0 12px;background-color:initial;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.marketplace-tabBar-headerItem .optionsMenu-dropBox svg{position:absolute;margin-left:8px}.marketplace-header-icon-button{border-radius:8px;color:var(--spice-text);display:inline-block;padding:10px 14px 6px;font-weight:700;position:relative;text-decoration:none!important;cursor:pointer;background-color:transparent;border:none;background-color:var(--spice-sidebar);transition-duration:.2s}.marketplace-header-icon-button:hover{background-color:var(--spice-button-disabled)}#marketplace-update{margin-left:0;margin-right:16px}.searchbar--bar__wrapper{display:flex;flex-direction:column;align-items:flex-end;flex-grow:1}.searchbar-bar{border-style:solid;border-color:var(--spice-sidebar);background-color:var(--spice-sidebar)!important;border-radius:8px;padding:10px 12px;color:var(--spice-text)!important}.marketplace-footer{margin:auto;text-align:center}.marketplace-add-snippet-btn{position:sticky!important;bottom:32px;left:100%}.marketplace-content{margin-top:60px}.spicetify-root-vars{--spice-shadow:#1f1525;--spice-text:#ffffff;--spice-sidebar:#0a0e14;--spice-button-disabled:#535353;--spice-main:#0a0e14;--spice-misc:#bfbfbf;--spice-selected-row:#909090;--spice-subtext:#f0f0f0;--spice-tab-active:#795b84;--spice-button:#6f3c89;--spice-notification:#6f3c89;--spice-player:#0a0e14;--spice-notification-error:#e22134;--spice-card:#6f3c89;--spice-button-active:#795b84}:root{--background-body:var(--spice-main);--background:var(--spice-main);--background-alt:var(--spice-shadow);--selection:#1c76c5;--text-main:var(--spice-subtext);--text-bright:var(--spice-text);--text-muted:#a9b1ba;--links:#41adff;--focus:#0096bfab;--border:#526980;--code:#ffbe85;--animation-duration:0.1s;--button-base:#0c151c;--button-hover:#040a0f;--scrollbar-thumb:var(--button-hover);--scrollbar-thumb-hover:rgb(0, 0, 0);--form-placeholder:#a9a9a9;--form-text:#fff;--variable:#d941e2;--highlight:#efdb43;--select-arrow:url("data:image/svg+xml;charset=utf-8,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' height='62.5' width='116.9' fill='%23efefef'%3E %3Cpath d='M115.3,1.6 C113.7,0 111.1,0 109.5,1.6 L58.5,52.7 L7.4,1.6 C5.8,0 3.2,0 1.6,1.6 C0,3.2 0,5.8 1.6,7.4 L55.5,61.3 C56.3,62.1 57.3,62.5 58.4,62.5 C59.4,62.5 60.5,62.1 61.3,61.3 L115.2,7.4 C116.9,5.8 116.9,3.2 115.3,1.6Z'/%3E %3C/svg%3E")}#marketplace-readme{-webkit-user-select:text;-moz-user-select:text;user-select:text;font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen,Ubuntu,Cantarell,"Fira Sans","Droid Sans","Helvetica Neue","Segoe UI Emoji","Apple Color Emoji","Noto Color Emoji",sans-serif;line-height:1.4;max-width:800px;margin:20px auto;padding:0 10px;word-wrap:break-word;color:#dbdbdb;color:var(--text-main);background:#202b38;background:var(--background-body);text-rendering:optimizeLegibility}#marketplace-readme button{transition:background-color .1s linear,border-color .1s linear,color .1s linear,box-shadow .1s linear,transform .1s ease;transition:background-color var(--animation-duration) linear,border-color var(--animation-duration) linear,color var(--animation-duration) linear,box-shadow var(--animation-duration) linear,transform var(--animation-duration) ease}#marketplace-readme input{transition:background-color .1s linear,border-color .1s linear,color .1s linear,box-shadow .1s linear,transform .1s ease;transition:background-color var(--animation-duration) linear,border-color var(--animation-duration) linear,color var(--animation-duration) linear,box-shadow var(--animation-duration) linear,transform var(--animation-duration) ease}#marketplace-readme textarea{transition:background-color .1s linear,border-color .1s linear,color .1s linear,box-shadow .1s linear,transform .1s ease;transition:background-color var(--animation-duration) linear,border-color var(--animation-duration) linear,color var(--animation-duration) linear,box-shadow var(--animation-duration) linear,transform var(--animation-duration) ease}#marketplace-readme h1{font-size:2.2em;margin-top:0}#marketplace-readme h1,#marketplace-readme h2,#marketplace-readme h3,#marketplace-readme h4,#marketplace-readme h5,#marketplace-readme h6{margin-bottom:12px;margin-top:24px}#marketplace-readme h1{color:#fff;color:var(--text-bright)}#marketplace-readme h2{color:#fff;color:var(--text-bright)}#marketplace-readme h3{color:#fff;color:var(--text-bright)}#marketplace-readme h4{color:#fff;color:var(--text-bright)}#marketplace-readme h5{color:#fff;color:var(--text-bright)}#marketplace-readme h6{color:#fff;color:var(--text-bright)}#marketplace-readme strong{color:#fff;color:var(--text-bright)}#marketplace-readme b,#marketplace-readme h1,#marketplace-readme h2,#marketplace-readme h3,#marketplace-readme h4,#marketplace-readme h5,#marketplace-readme h6,#marketplace-readme strong,#marketplace-readme th{font-weight:600}#marketplace-readme q::before{content:none}#marketplace-readme q::after{content:none}#marketplace-readme blockquote{border-left:4px solid rgba(0,150,191,.6705882353);border-left:4px solid var(--focus);margin:1.5em 0;padding:.5em 1em;font-style:italic}#marketplace-readme q{border-left:4px solid rgba(0,150,191,.6705882353);border-left:4px solid var(--focus);margin:1.5em 0;padding:.5em 1em;font-style:italic}#marketplace-readme blockquote>footer{font-style:normal;border:0}#marketplace-readme blockquote cite{font-style:normal}#marketplace-readme address{font-style:normal}#marketplace-readme a[href^="mailto:"]::before{content:"\1f4e7 "}#marketplace-readme a[href^="tel:"]::before{content:"\1f4de "}#marketplace-readme a[href^="sms:"]::before{content:"\1f4ac "}#marketplace-readme mark{background-color:#efdb43;background-color:var(--highlight);border-radius:2px;padding:0 2px 0 2px;color:#000}#marketplace-readme a>code,#marketplace-readme a>strong{color:inherit}#marketplace-readme button,#marketplace-readme input[type=button],#marketplace-readme input[type=checkbox],#marketplace-readme input[type=radio],#marketplace-readme input[type=range],#marketplace-readme input[type=reset],#marketplace-readme input[type=submit],#marketplace-readme select{cursor:pointer}#marketplace-readme input,#marketplace-readme select{display:block}#marketplace-readme [type=checkbox],#marketplace-readme [type=radio]{display:initial}#marketplace-readme input{color:#fff;color:var(--form-text);background-color:#161f27;background-color:var(--background);font-family:inherit;font-size:inherit;margin-right:6px;margin-bottom:6px;padding:10px;border:none;border-radius:6px;outline:0}#marketplace-readme button{color:#fff;color:var(--form-text);background-color:#161f27;background-color:var(--background);font-family:inherit;font-size:inherit;margin-right:6px;margin-bottom:6px;padding:10px;border:none;border-radius:6px;outline:0}#marketplace-readme textarea{color:#fff;color:var(--form-text);background-color:#161f27;background-color:var(--background);font-family:inherit;font-size:inherit;margin-right:6px;margin-bottom:6px;padding:10px;border:none;border-radius:6px;outline:0}#marketplace-readme select{color:#fff;color:var(--form-text);background-color:#161f27;background-color:var(--background);font-family:inherit;font-size:inherit;margin-right:6px;margin-bottom:6px;padding:10px;border:none;border-radius:6px;outline:0}#marketplace-readme button{background-color:#0c151c;background-color:var(--button-base);padding-right:30px;padding-left:30px}#marketplace-readme input[type=submit]{background-color:#0c151c;background-color:var(--button-base);padding-right:30px;padding-left:30px}#marketplace-readme input[type=reset]{background-color:#0c151c;background-color:var(--button-base);padding-right:30px;padding-left:30px}#marketplace-readme input[type=button]{background-color:#0c151c;background-color:var(--button-base);padding-right:30px;padding-left:30px}#marketplace-readme button:hover{background:#040a0f;background:var(--button-hover)}#marketplace-readme input[type=submit]:hover{background:#040a0f;background:var(--button-hover)}#marketplace-readme input[type=reset]:hover{background:#040a0f;background:var(--button-hover)}#marketplace-readme input[type=button]:hover{background:#040a0f;background:var(--button-hover)}#marketplace-readme input[type=color]{min-height:2rem;padding:8px;cursor:pointer}#marketplace-readme input[type=checkbox],#marketplace-readme input[type=radio]{height:1em;width:1em}#marketplace-readme input[type=radio]{border-radius:100%}#marketplace-readme input{vertical-align:top}#marketplace-readme label{vertical-align:middle;margin-bottom:4px;display:inline-block}#marketplace-readme button,#marketplace-readme input:not([type=checkbox]):not([type=radio]),#marketplace-readme input[type=range],#marketplace-readme select,#marketplace-readme textarea{-webkit-appearance:none}#marketplace-readme textarea{display:block;margin-right:0;box-sizing:border-box;resize:vertical}#marketplace-readme textarea:not([cols]){width:100%}#marketplace-readme textarea:not([rows]){min-height:40px;height:140px}#marketplace-readme select{background:#161f27 url("data:image/svg+xml;charset=utf-8,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' height='62.5' width='116.9' fill='%23efefef'%3E %3Cpath d='M115.3,1.6 C113.7,0 111.1,0 109.5,1.6 L58.5,52.7 L7.4,1.6 C5.8,0 3.2,0 1.6,1.6 C0,3.2 0,5.8 1.6,7.4 L55.5,61.3 C56.3,62.1 57.3,62.5 58.4,62.5 C59.4,62.5 60.5,62.1 61.3,61.3 L115.2,7.4 C116.9,5.8 116.9,3.2 115.3,1.6Z'/%3E %3C/svg%3E") calc(100% - 12px) 50%/12px no-repeat;background:var(--background) var(--select-arrow) calc(100% - 12px) 50%/12px no-repeat;padding-right:35px}#marketplace-readme select::-ms-expand{display:none}#marketplace-readme select[multiple]{padding-right:10px;background-image:none;overflow-y:auto}#marketplace-readme input:focus{box-shadow:0 0 0 2px rgba(0,150,191,.6705882353);box-shadow:0 0 0 2px var(--focus)}#marketplace-readme select:focus{box-shadow:0 0 0 2px rgba(0,150,191,.6705882353);box-shadow:0 0 0 2px var(--focus)}#marketplace-readme button:focus{box-shadow:0 0 0 2px rgba(0,150,191,.6705882353);box-shadow:0 0 0 2px var(--focus)}#marketplace-readme textarea:focus{box-shadow:0 0 0 2px rgba(0,150,191,.6705882353);box-shadow:0 0 0 2px var(--focus)}#marketplace-readme button:active,#marketplace-readme input[type=button]:active,#marketplace-readme input[type=checkbox]:active,#marketplace-readme input[type=radio]:active,#marketplace-readme input[type=range]:active,#marketplace-readme input[type=reset]:active,#marketplace-readme input[type=submit]:active{transform:translateY(2px)}#marketplace-readme button:disabled,#marketplace-readme input:disabled,#marketplace-readme select:disabled,#marketplace-readme textarea:disabled{cursor:not-allowed;opacity:.5}#marketplace-readme ::-moz-placeholder{color:#a9a9a9;color:var(--form-placeholder)}#marketplace-readme ::placeholder{color:#a9a9a9;color:var(--form-placeholder)}#marketplace-readme fieldset{border:1px rgba(0,150,191,.6705882353) solid;border:1px var(--focus) solid;border-radius:6px;margin:0;margin-bottom:12px;padding:10px}#marketplace-readme legend{font-size:.9em;font-weight:600}#marketplace-readme input[type=range]{margin:10px 0;padding:10px 0;background:0 0}#marketplace-readme input[type=range]:focus{outline:0}#marketplace-readme input[type=range]::-webkit-slider-runnable-track{width:100%;height:9.5px;-webkit-transition:.2s;transition:.2s;background:#161f27;background:var(--background);border-radius:3px}#marketplace-readme input[type=range]::-webkit-slider-thumb{box-shadow:0 1px 1px #000,0 0 1px #0d0d0d;height:20px;width:20px;border-radius:50%;background:#526980;background:var(--border);-webkit-appearance:none;margin-top:-7px}#marketplace-readme input[type=range]:focus::-webkit-slider-runnable-track{background:#161f27;background:var(--background)}#marketplace-readme input[type=range]::-moz-range-track{width:100%;height:9.5px;-moz-transition:.2s;transition:.2s;background:#161f27;background:var(--background);border-radius:3px}#marketplace-readme input[type=range]::-moz-range-thumb{box-shadow:1px 1px 1px #000,0 0 1px #0d0d0d;height:20px;width:20px;border-radius:50%;background:#526980;background:var(--border)}#marketplace-readme input[type=range]::-ms-track{width:100%;height:9.5px;background:0 0;border-color:transparent;border-width:16px 0;color:transparent}#marketplace-readme input[type=range]::-ms-fill-lower{background:#161f27;background:var(--background);border:.2px solid #010101;border-radius:3px;box-shadow:1px 1px 1px #000,0 0 1px #0d0d0d}#marketplace-readme input[type=range]::-ms-fill-upper{background:#161f27;background:var(--background);border:.2px solid #010101;border-radius:3px;box-shadow:1px 1px 1px #000,0 0 1px #0d0d0d}#marketplace-readme input[type=range]::-ms-thumb{box-shadow:1px 1px 1px #000,0 0 1px #0d0d0d;border:1px solid #000;height:20px;width:20px;border-radius:50%;background:#526980;background:var(--border)}#marketplace-readme input[type=range]:focus::-ms-fill-lower{background:#161f27;background:var(--background)}#marketplace-readme input[type=range]:focus::-ms-fill-upper{background:#161f27;background:var(--background)}#marketplace-readme a{text-decoration:none;color:#41adff;color:var(--links)}#marketplace-readme a:hover{text-decoration:underline}#marketplace-readme code{background:#161f27;background:var(--background);color:#ffbe85;color:var(--code);padding:2.5px 5px;border-radius:6px;font-size:1em}#marketplace-readme samp{background:#161f27;background:var(--background);color:#ffbe85;color:var(--code);padding:2.5px 5px;border-radius:6px;font-size:1em}#marketplace-readme time{background:#161f27;background:var(--background);color:#ffbe85;color:var(--code);padding:2.5px 5px;border-radius:6px;font-size:1em}#marketplace-readme pre>code{padding:10px;display:block;overflow-x:auto}#marketplace-readme var{color:#d941e2;color:var(--variable);font-style:normal;font-family:monospace}#marketplace-readme kbd{background:#161f27;background:var(--background);border:1px solid #526980;border:1px solid var(--border);border-radius:2px;color:#dbdbdb;color:var(--text-main);padding:2px 4px 2px 4px}#marketplace-readme img,#marketplace-readme video{max-width:100%;height:auto}#marketplace-readme hr{border:none;border-top:1px solid #526980;border-top:1px solid var(--border)}#marketplace-readme table{border-collapse:collapse;margin-bottom:10px;width:100%;table-layout:fixed}#marketplace-readme table caption{text-align:left}#marketplace-readme td,#marketplace-readme th{padding:6px;text-align:left;vertical-align:top;word-wrap:break-word}#marketplace-readme thead{border-bottom:1px solid #526980;border-bottom:1px solid var(--border)}#marketplace-readme tfoot{border-top:1px solid #526980;border-top:1px solid var(--border)}#marketplace-readme tbody tr:nth-child(2n){background-color:#161f27;background-color:var(--background)}#marketplace-readme tbody tr:nth-child(2n) button{background-color:#1a242f;background-color:var(--background-alt)}#marketplace-readme tbody tr:nth-child(2n) button:hover{background-color:#202b38;background-color:var(--background-body)}#marketplace-readme ::-webkit-scrollbar{height:10px;width:10px}#marketplace-readme ::-webkit-scrollbar-track{background:#161f27;background:var(--background);border-radius:6px}#marketplace-readme ::-webkit-scrollbar-thumb{background:#040a0f;background:var(--scrollbar-thumb);border-radius:6px}#marketplace-readme ::-webkit-scrollbar-thumb:hover{background:#000;background:var(--scrollbar-thumb-hover)}#marketplace-readme ::-moz-selection{background-color:#1c76c5;background-color:var(--selection);color:#fff;color:var(--text-bright)}#marketplace-readme ::selection{background-color:#1c76c5;background-color:var(--selection);color:#fff;color:var(--text-bright)}#marketplace-readme details{display:flex;flex-direction:column;align-items:flex-start;background-color:#1a242f;background-color:var(--background-alt);padding:10px 10px 0;margin:1em 0;border-radius:6px;overflow:hidden}#marketplace-readme details[open]{padding:10px}#marketplace-readme details>:last-child{margin-bottom:0}#marketplace-readme details[open] summary{margin-bottom:10px}#marketplace-readme summary{display:list-item;background-color:#161f27;background-color:var(--background);padding:10px;margin:-10px -10px 0;cursor:pointer;outline:0}#marketplace-readme summary:focus,#marketplace-readme summary:hover{text-decoration:underline}#marketplace-readme details>:not(summary){margin-top:0}#marketplace-readme summary::-webkit-details-marker{color:#dbdbdb;color:var(--text-main)}#marketplace-readme dialog{background-color:#1a242f;background-color:var(--background-alt);color:#dbdbdb;color:var(--text-main);border:none;border-radius:6px;border-color:#526980;border-color:var(--border);padding:10px 30px}#marketplace-readme dialog>header:first-child{background-color:#161f27;background-color:var(--background);border-radius:6px 6px 0 0;margin:-10px -30px 10px;padding:10px;text-align:center}#marketplace-readme dialog::backdrop{background:rgba(0,0,0,.6117647059);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}#marketplace-readme footer{border-top:1px solid #526980;border-top:1px solid var(--border);padding-top:10px;color:#a9b1ba;color:var(--text-muted)}#marketplace-readme body>footer{margin-top:40px}@media print{#marketplace-readme body,#marketplace-readme button,#marketplace-readme code,#marketplace-readme details,#marketplace-readme input,#marketplace-readme pre,#marketplace-readme summary,#marketplace-readme textarea{background-color:#fff}#marketplace-readme button,#marketplace-readme input,#marketplace-readme textarea{border:1px solid #000}#marketplace-readme body,#marketplace-readme button,#marketplace-readme code,#marketplace-readme footer,#marketplace-readme h1,#marketplace-readme h2,#marketplace-readme h3,#marketplace-readme h4,#marketplace-readme h5,#marketplace-readme h6,#marketplace-readme input,#marketplace-readme pre,#marketplace-readme strong,#marketplace-readme summary,#marketplace-readme textarea{color:#000}#marketplace-readme summary::marker{color:#000}#marketplace-readme summary::-webkit-details-marker{color:#000}#marketplace-readme tbody tr:nth-child(2n){background-color:#f2f2f2}#marketplace-readme a{color:#00f;text-decoration:underline}}#marketplace-readme code{border:1px solid var(--spice-button-disabled)}#marketplace-readme li,#marketplace-readme ul{list-style-position:inside}#marketplace-readme li li,#marketplace-readme ul li{margin-bottom:8px}#marketplace-readme ul{list-style-type:disc}#marketplace-readme ol{list-style-type:auto}#marketplace-readme code,#marketplace-readme p,#marketplace-readme pre{margin:8px 0}#marketplace-readme pre{overflow-x:auto}#marketplace-readme table{table-layout:auto}#marketplace-readme table td,#marketplace-readme table th{border:1px solid var(--spice-button-disabled)}.GenericModal[aria-label="Reload required"]{height:240px!important}.marketplace-reload-modal__button-container{display:flex;justify-content:center;padding-top:18px}.marketplace-reload-modal__button-container button{margin:18px;padding:8px 24px}#marketplace-config-container .settings-block{padding-top:10px;padding-bottom:10px}#marketplace-config-container .settings-block-top{padding-bottom:10px}#marketplace-config-container .settings-block-bottom{padding-top:10px}#marketplace-config-container .settings-tabs-description{font-style:italic;font-size:12px}#marketplace-config-container .settings-row{display:flex;justify-content:space-between}#marketplace-config-container .settings-row .col{display:flex;padding:8px 0;align-items:center}#marketplace-config-container .settings-row .col.action{text-align:right;margin-inline-start:8px}#marketplace-config-container .settings-row .col.action .marketplace-sortBox+.marketplace-tooltip-icon{margin-inline-start:8px}#marketplace-config-container .settings-heading{position:relative;border-bottom:2px solid var(--spice-button-disabled);padding:0 0 4px;margin:0 0 4px}.marketplace-tooltip-icon{position:relative;display:inline-flex;align-items:center;justify-content:center;cursor:pointer}.marketplace-tooltip-icon+[data-tippy-root]{text-align:start}button.arrow-btn{align-items:center;border:0;border-radius:50%;background-color:rgba(var(--spice-rgb-shadow),.7);color:var(--spice-text);cursor:pointer;display:flex;margin-inline-end:12px;padding:8px}button.arrow-btn.small{width:24px;height:24px;padding:5px}button.arrow-btn.disabled,button.arrow-btn[disabled]{color:rgba(var(--spice-rgb-text),.3);cursor:not-allowed}.dnd-box{display:flex;align-items:center;justify-content:center;position:relative;width:100%}.dnd-icon{position:absolute;left:4px}#marketplace-add-snippet-container input,textarea{width:100%;margin-bottom:10px;padding:3px 5px;background-color:var(--spice-main);color:var(--spice-text);font-size:14px;border:1px solid var(--spice-button);border-radius:4px}#marketplace-update-container .marketplace-update-header{margin-bottom:.25rem;margin-top:.5rem}#marketplace-update-description>h4{margin-bottom:.5rem}#marketplace-update-description a{display:block}#marketplace-update-whats-changed li{list-style-type:disc}#marketplace-update-whats-changed li::marker{unicode-bidi:isolate;font-variant-numeric:tabular-nums;text-transform:none;text-indent:0!important;text-align:start!important;-moz-text-align-last:start!important;text-align-last:start!important}#marketplace-update-whats-changed>details>ul{padding-left:1.25rem}.button-module__button___hf2qg_marketplace{box-sizing:border-box;font-family:var(--font-family, spotify-circular),Helvetica,Arial,sans-serif;-webkit-tap-highlight-color:transparent;font-size:1rem;line-height:1.5rem;font-weight:700;background-color:transparent;border:0;border-radius:500px;display:inline-block;position:relative;text-align:center;text-decoration:none;text-transform:none;touch-action:manipulation;transition-duration:33ms;transition-property:background-color,border-color,color,box-shadow,filter,transform;-webkit-user-select:none;-moz-user-select:none;user-select:none;vertical-align:middle;transform:translate3d(0,0,0);padding:0;min-inline-size:0px;align-self:center;position:relative;background-color:var(--spice-text);color:var(--spice-main);border-radius:500px;font-size:inherit;padding-block:12px;padding-inline:32px}@media screen and (min-width:768px){.button-module__button___hf2qg_marketplace{font-size:1rem;line-height:1.5rem;text-transform:none;letter-spacing:normal}}.button-module__button___hf2qg_marketplace:hover{transform:scale(1.04)}.button-module__button___hf2qg_marketplace:active{background-color:var(--spice-subtext);box-shadow:none;transform:scale(1)}.button-module__button___hf2qg_marketplace:disabled{opacity:.5;cursor:not-allowed}.button-module__circle___EZ88P_marketplace{padding-inline:16px;width:48px;height:48px}.button-module__circle___EZ88P_marketplace svg{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.toggle-module__toggle-wrapper___ocE5z_marketplace{display:inline-flex;position:relative;align-items:center;cursor:pointer}.toggle-module__disabled___OYAYf_marketplace{opacity:0;pointer-events:none}.toggle-module__toggle-input___ceLM4_marketplace{opacity:0;pointer-events:none;position:absolute}.toggle-module__toggle-input___ceLM4_marketplace:checked~.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace{background-color:var(--spice-text)}.toggle-module__toggle-input___ceLM4_marketplace:checked~.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace .toggle-module__toggle-indicator___nCxwE_marketplace{background-color:#fff;left:auto;right:2px;right:3px}.toggle-module__toggle-input___ceLM4_marketplace:hover~.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace{filter:brightness(1.3)}.toggle-module__toggle-input___ceLM4_marketplace:hover:checked~.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace{filter:brightness(1.15)}.toggle-module__toggle-input___ceLM4_marketplace:active:not([disabled])~.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace .toggle-module__toggle-indicator___nCxwE_marketplace{width:20px}.toggle-module__toggle-indicator-wrapper___6Lcp0_marketplace{background-color:#535353;border-radius:24px;height:24px;position:relative;width:42px}.toggle-module__toggle-indicator___nCxwE_marketplace{background:#fff;border-radius:inherit;height:20px;left:2px;position:absolute;top:2px;transition:background-color,left,right,width .1s ease;width:20px;height:18px;width:18px;top:3px;left:3px;background:var(--spice-shadow)!important} \ No newline at end of file diff --git a/.config/spicetify/Themes/Dribbblish/README.md b/.config/spicetify/Themes/Dribbblish/README.md deleted file mode 100644 index 287e1cd..0000000 --- a/.config/spicetify/Themes/Dribbblish/README.md +++ /dev/null @@ -1,110 +0,0 @@ -# Dribbblish - -### Base -![base](base.png) -### White -![white](white.png) -### Dark -![dark](dark.png) -### Nord-Light -![nord-light](nord-light.png) -### Nord-Dark -![nord-dark](nord-dark.png) -### Beach-Sunset -![beach-sunset](beach-sunset.png) -### Purple -![purple](purple.png) -### Samurai -![samurai](samurai.png) -### Gruvbox -![gruvbox](gruvbox.png) -### Gruvbox Material Dark -![gruvbox-material-dark](gruvbox-material-dark.png) -### Rosé Pine -![rosepine](rosepine.png) -### Lunar -![lunar](lunar.png) -### Catppuccin Latte -![catppuccin-latte](catppuccin-latte.png) -### Catppuccin Frappe -![catppuccin-frappe](catppuccin-frappe.png) -### Catppuccin Macchiato -![catppuccin-macchiato](catppuccin-macchiato.png) -### Catppuccin Mocha -![catppuccin-mocha](catppuccin-mocha.png) - -## Features -### Resizable sidebar - -img - -### Customizable sidebar -Rearrange icons positions, stick icons to header or hide unnecessary to save space. -Turn on "Sidebar config" mode in Profile menu and hover on icon to show control buttons. -After you finish customizing, turn off Config mode in Profile menu to save. - -img - -### Playlist Folder image -Right click at folder and choose images for your playlist folder. Every image formats supported by Chrome can be used, but do keep image size small and in compressed format. - -img - -### Left/Right expanded cover -In profile menu, toggle option "Right expanded cover" to change expaned current track cover image to left or right side, whereever you prefer. - -## Auto-install -Make sure you are using spicetify >= v2.5.0 and Spotify >= v1.1.56. -### Windows -```powershell -Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/spicetify/spicetify-themes/master/Dribbblish/install.ps1" | Invoke-Expression -``` - -## Manual Install -Run these commands: - -### Linux and MacOS: -In **Bash**: -```bash -cd "$(dirname "$(spicetify -c)")/Themes/Dribbblish" -spicetify config current_theme Dribbblish color_scheme base -spicetify config inject_css 1 replace_colors 1 overwrite_assets 1 inject_theme_js 1 -spicetify apply -``` - -### Windows -In **Powershell**: -```powershell -cd "$(spicetify -c | Split-Path)\Themes\Dribbblish" -spicetify config current_theme Dribbblish color_scheme base -spicetify config inject_css 1 replace_colors 1 overwrite_assets 1 inject_theme_js 1 -spicetify apply -``` - -From Spotify > v1.1.62, in sidebar, they use an adaptive render mechanic to actively show and hide items on scroll. It helps reducing number of items to render, hence there is significant performance boost if you have a large playlists collection. But the drawbacks is that item height is hard-coded, it messes up user interaction when we explicity change, in CSS, playlist item height bigger than original value. So you need to add these 2 lines in Patch section in config file: -```ini -[Patch] -xpui.js_find_8008 = ,(\w+=)32, -xpui.js_repl_8008 = ,${1}56, -``` - -## Change Color Schemes -There are 9 color schemes you can choose: `base`, `white`, `dark`, `dracula`, `nord-dark`, `nord-light`, `beach-sunset`, `samurai`, `purple`, `gruvbox`, `gruvbox-material-dark`, `catppuccin-latte`, `catppuccin-frappe`, `catppuccin-macchiato`, and `catppuccin-mocha`. Change scheme with commands: -``` -spicetify config color_scheme -spicetify apply -``` - -## Auto-uninstall -### Windows -```powershell -Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/spicetify/spicetify-themes/v2/Dribbblish/uninstall.ps1" | Invoke-Expression -``` - -## Manual uninstall -Remove the dribbblish theme with the following commands - -``` -spicetify config current_theme " " color_scheme " " -spicetify apply -``` diff --git a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayMedium.woff2 b/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayMedium.woff2 deleted file mode 100644 index 2430944..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayMedium.woff2 and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayRegular.woff2 b/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayRegular.woff2 deleted file mode 100644 index 911e5f8..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/GoogleSansDisplayRegular.woff2 and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/Roboto.woff2 b/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/Roboto.woff2 deleted file mode 100644 index 9a0064e..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/Roboto.woff2 and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/RobotoMedium.woff2 b/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/RobotoMedium.woff2 deleted file mode 100644 index 6a88805..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/assets/glue-resources/fonts/RobotoMedium.woff2 and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/base.png b/.config/spicetify/Themes/Dribbblish/base.png deleted file mode 100644 index ce56373..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/base.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/beach-sunset.png b/.config/spicetify/Themes/Dribbblish/beach-sunset.png deleted file mode 100644 index 3cf9f78..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/beach-sunset.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/catppuccin-frappe.png b/.config/spicetify/Themes/Dribbblish/catppuccin-frappe.png deleted file mode 100644 index b411d1b..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/catppuccin-frappe.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/catppuccin-latte.png b/.config/spicetify/Themes/Dribbblish/catppuccin-latte.png deleted file mode 100644 index 1f69c47..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/catppuccin-latte.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/catppuccin-macchiato.png b/.config/spicetify/Themes/Dribbblish/catppuccin-macchiato.png deleted file mode 100644 index 3861ca1..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/catppuccin-macchiato.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/catppuccin-mocha.png b/.config/spicetify/Themes/Dribbblish/catppuccin-mocha.png deleted file mode 100644 index 08392c9..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/catppuccin-mocha.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/color.ini b/.config/spicetify/Themes/Dribbblish/color.ini deleted file mode 100644 index 200e152..0000000 --- a/.config/spicetify/Themes/Dribbblish/color.ini +++ /dev/null @@ -1,344 +0,0 @@ -[base] -text = FFFFFF -subtext = F0F0F0 -sidebar-text = FFFFFF -main = 000000 -sidebar = 24b558 -player = 000000 -card = 000000 -shadow = 202020 -selected-row = 797979 -button = 24b558 -button-active = 24b558 -button-disabled = 535353 -tab-active = 166632 -notification = 1db954 -notification-error = e22134 -misc = BFBFBF - - -[white] -text = 363636 -subtext = 3D3D3D -sidebar-text = FFF9F4 -main = FFF9F4 -sidebar = FFA789 -player = FFF9F4 -card = FFF9F4 -shadow = d3d3d3 -selected-row = 6D6D6D -button = ff8367 -button-active = ff8367 -button-disabled = 535353 -tab-active = ffdace -notification = FFA789 -notification-error = e22134 -misc = BFBFBF - -[dark] -text = F0F0F0 -subtext = F0F0F0 -sidebar-text = 0a0e14 -main = 0a0e14 -sidebar = C2D935 -player = 0a0e14 -card = 0a0e14 -shadow = 202020 -selected-row = DEDEDE -button = C2D935 -button-active = C2D935 -button-disabled = 535353 -tab-active = 727d2b -notification = C2D935 -notification-error = e22134 -misc = BFBFBF - -[dracula] -text = f8f8f2 -subtext = f8f8f2 -sidebar-text = F0F0F0 -main = 44475a -sidebar = 6272a4 -player = 44475a -card = 6272a4 -shadow = 000000 -selected-row = bd93f9 -button = ffb86c -button-active = 8be9fd -button-disabled = 535353 -tab-active = 6272a4 -notification = bd93f9 -notification-error = e22134 -misc = BFBFBF - -[nord-light] -text = 2e3440 -subtext = 3b4252 -sidebar-text = ECEFF4 -main = ECEFF4 -sidebar = 5E81AC -player = ECEFF4 -card = ebcb8b -shadow = eceff4 -selected-row = 4c566a -button = 81a1c1 -button-active = 81a1c1 -button-disabled = c0c0c0 -tab-active = ebcb8b -notification = a3be8c -notification-error = bf616a -misc = BFBFBF - -[nord-dark] -text = ECEFF4 -subtext = E5E9F0 -sidebar-text = 434c5e -main = 2e3440 -sidebar = 88C0D0 -player = 2e3440 -card = 2e3440 -shadow = 2E3440 -selected-row = D8DEE9 -button = 81A1C1 -button-active = 81A1C1 -button-disabled = 434C5E -tab-active = 434C5E -notification = A3BE8C -notification-error = BF616A -misc = BFBFBF - -[purple] -text = f1eaff -subtext = f1eaff -sidebar-text = e0d0ff -main = 0A0E14 -sidebar = 6F3C89 -player = 0A0E14 -card = 0A0E14 -shadow = 3a2645 -selected-row = 645275 -button = c76af6 -button-active = 6F3C89 -button-disabled = 535353 -tab-active = 58306D -notification = ff9e00 -notification-error = f61379 -misc = DEDEDE - -[samurai] -text = ebdbb2 -subtext = ebdbb2 -sidebar-text = 461217 -main = 461217 -sidebar = ebdbb2 -player = 461217 -card = 461217 -shadow = 000000 -selected-row = 909090 -button = e7a52d -button-active = e7a52d -button-disabled = 535353 -tab-active = e7a52d -notification = e7a52d -notification-error = e22134 -misc = BFBFBF - -[beach-sunset] -text = FFFFFF -subtext = F0F0F0 -sidebar-text = F0F0F0 -main = 262626 -sidebar = bd3e3e -player = 262626 -card = 262626 -shadow = 000000 -selected-row = d1d6e2 -button = f1a84f -button-active = c98430 -button-disabled = 535353 -tab-active = f1a84f -notification = c98430 -notification-error = e22134 -misc = BFBFBF - -[gruvbox] -text = fbf1c7 -subtext = d5c4a1 -sidebar-text = ebe1b7 -main = 292828 -sidebar = 689d6a -player = 292828 -card = 3c3836 -shadow = 202020 -selected-row = d5c4a1 -button = fb4934 -button-active = cc241d -button-disabled = bdae93 -tab-active = fb4934 -notification = 8ec07c -notification-error = d79921 -misc = BFBFBF - -[gruvbox-material-dark] -text = fbf1c7 -subtext = d5c4a1 -sidebar-text = 716e5f -main = 292828 -sidebar = 1d2021 -player = 292828 -card = 3c3836 -shadow = 202020 -selected-row = d5c4a1 -button = a9b665 -button-active = a9b665 -button-disabled = bdae93 -tab-active = a9b665 -notification = 8ec07c -notification-error = d79921 -misc = BFBFBF - -[rosepine] -text = ebbcba -subtext = F0F0F0 -sidebar-text = e0def4 -main = 191724 -sidebar = 2a2837 -player = 191724 -card = 191724 -shadow = 1f1d2e -selected-row = 797979 -button = 31748f -button-active = 31748f -button-disabled = 555169 -tab-active = 31748f -notification = 1db954 -notification-error = eb6f92 -misc = 6e6a86 - -[lunar] -text = f3f3f3 -subtext = cecece -sidebar-text = f3f3f3 -main = 161616 -sidebar = 202020 -player = 161616 -card = 161616 -shadow = 252525 -selected-row = 202020 -button = 3281ea -button-active = 0284e8 -button-disabled = 303030 -tab-active = ebbcba -notification = 3281ea -notification-error = b10c0c -misc = 252525 - -; Comments below correspond to the labeling of the colors on the Catppuccin GitHub page. - -[catppuccin-latte] -text = 4c4f69 ; Text -subtext = 5c5f77 ; Subtext1 -sidebar-text = 4c4f69 ; Text -main = eff1f5 ; Base -sidebar = e6e9ef ; Mantle -player = eff1f5 ; Base -card = eff1f5 ; Base -shadow = e6e9ef ; Mantle -selected-row = 7c7f93 ; Overlay2 -button = 8c8fa1 ; Overlay1 -button-active = 7c7f93 ; Overlay2 -button-disabled = 9ca0b0 ; Overlay0 -tab-active = ccd0da ; Surface0 -notification = ccd0da ; Surface0 -notification-error = d20f39 ; Red -misc = bcc0cc ; Surface1 - -[catppuccin-frappe] -text = c6d0f5 ; Text -subtext = b5bfe2 ; Subtext1 -sidebar-text = c6d0f5 ; Text -main = 303446 ; Base -sidebar = 292c3c ; Mantle -player = 303446 ; Base -card = 303446 ; Base -shadow = 292c3c ; Mantle -selected-row = 949cbb ; Overlay2 -button = 838ba7 ; Overlay1 -button-active = 949cbb ; Overlay2 -button-disabled = 737994 ; Overlay0 -tab-active = 414559 ; Surface0 -notification = 414559 ; Surface0 -notification-error = e78284 ; Red -misc = 51576d ; Surface1 - -[catppuccin-macchiato] -text = cad3f5 ; Text -subtext = b8c0e0 ; Subtext1 -sidebar-text = cad3f5 ; Text -main = 24273a ; Base -sidebar = 1e2030 ; Mantle -player = 24273a ; Base -card = 24273a ; Base -shadow = 1e2030 ; Mantle -selected-row = 939ab7 ; Overlay2 -button = 8087a2 ; Overlay1 -button-active = 939ab7 ; Overlay2 -button-disabled = 6e738d ; Overlay0 -tab-active = 363a4f ; Surface0 -notification = 363a4f ; Surface0 -notification-error = ed8796 ; Red -misc = 494d64 ; Surface1 - -[catppuccin-mocha] -text = cdd6f4 ; Text -subtext = bac2de ; Subtext1 -sidebar-text = cdd6f4 ; Text -main = 1e1e2e ; Base -sidebar = 181825 ; Mantle -player = 1e1e2e ; Base -card = 1e1e2e ; Base -shadow = 181825 ; Mantle -selected-row = 9399b2 ; Overlay2 -button = 7f849c ; Overlay1 -button-active = 9399b2 ; Overlay2 -button-disabled = 6c7086 ; Overlay0 -tab-active = 313244 ; Surface0 -notification = 313244 ; Surface0 -notification-error = f38ba8 ; Red -misc = 45475a ; Surface1 - -[tokyo-night] -text = 7aa2f7 ; Text -subtext = bb9af7 ; Subtext1 -sidebar-text = c0caf5 ; Text -main = 1a1b26 ; Base -sidebar = 16161e ; Mantle -player = 1a1b26 ; Base -card = 1a1b26 ; Base -shadow = 14141b ; Mantle -selected-row = c0caf5 ; Overlay2 -button = 9ece6a ; Overlay1 -button-active = ff9e64 ; Overlay2 -button-disabled = f7768e ; Overlay0 -tab-active = 14141b ; Surface0 -notification = 1a1b26 ; Surface0 -notification-error = f7768e ; Red -misc = ff9e64 ; Surface1 - -[kanagawa] -text = dcd7ba ; Text -subtext = c8c093 ; Subtext1 -sidebar-text = dcd7ba ; Text -main = 1f1f28 ; Base -sidebar = 16161d ; Mantle -player = 1f1f28 ; Base -card = 1f1f28 ; Base -shadow = 16161d ; Mantle -selected-row = 9cabca ; Overlay2 -button = 7e9cd8 ; Overlay1 -button-active = 9cabca ; Overlay2 -button-disabled = 54546d ; Overlay0 -tab-active = 363646 ; Surface0 -notification = 363646 ; Surface0 -notification-error = e46876 ; Red -misc = 54546d ; Surface1 diff --git a/.config/spicetify/Themes/Dribbblish/dark.png b/.config/spicetify/Themes/Dribbblish/dark.png deleted file mode 100644 index 00dbb78..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/dark.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/gruvbox-material-dark.png b/.config/spicetify/Themes/Dribbblish/gruvbox-material-dark.png deleted file mode 100644 index ceb1a9f..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/gruvbox-material-dark.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/gruvbox.png b/.config/spicetify/Themes/Dribbblish/gruvbox.png deleted file mode 100644 index f94bbe4..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/gruvbox.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/images/tracklist-row-song-fallback.svg b/.config/spicetify/Themes/Dribbblish/images/tracklist-row-song-fallback.svg deleted file mode 100644 index 40980a7..0000000 --- a/.config/spicetify/Themes/Dribbblish/images/tracklist-row-song-fallback.svg +++ /dev/null @@ -1 +0,0 @@ -Playlist Icon \ No newline at end of file diff --git a/.config/spicetify/Themes/Dribbblish/install.ps1 b/.config/spicetify/Themes/Dribbblish/install.ps1 deleted file mode 100644 index 2d8a626..0000000 --- a/.config/spicetify/Themes/Dribbblish/install.ps1 +++ /dev/null @@ -1,55 +0,0 @@ -$checkSpice = Get-Command spicetify -ErrorAction Silent -if ($null -eq $checkSpice) { - Write-Host -ForegroundColor Red "Spicetify not found" - Write-Host "Follow instruction on:", "https://spicetify.app/docs/getting-started/simple-installation#windows" - return -} - -Write-Host "Downloading themes package:" -ForegroundColor Green -$zipFile = "$env:TEMP\spicetify-themes.zip" -Invoke-WebRequest "https://github.com/spicetify/spicetify-themes/archive/refs/heads/master.zip" -OutFile $zipFile - -Write-Host "Extracting themes package:" -ForegroundColor Green -$extractPath = "$env:TEMP\spicetify-themes-master" -if (Test-Path $extractPath) { - Remove-Item $extractPath -Recurse -Force -} -Expand-Archive $zipFile -DestinationPath $env:TEMP - -# Copy to personal Themes folder -$spicePath = spicetify -c | Split-Path -$dribPath = "$extractPath\Dribbblish" - -$destPath = "$spicePath\Themes\Dribbblish" -if (Test-Path $destPath) { - Remove-Item $destPath -Recurse -Force -} -Copy-Item $dribPath $destPath -Recurse - -Write-Host "Configuring:" -ForegroundColor Green -spicetify -spicetify config inject_css 1 replace_colors 1 overwrite_assets 1 inject_theme_js 1 current_theme Dribbblish - -# Add patch -$configFile = Get-Content "$spicePath\config-xpui.ini" -if (-not ($configFile -match "xpui.js_find_8008")) { - $rep = @" -[Patch] -xpui.js_find_8008=,(\w+=)32, -xpui.js_repl_8008=,`${1}56, -"@ - # In case missing Patch section - if (-not ($configFile -match "\[Patch\]")) { - $configFile += "`n[Patch]`n" - } - $configFile = $configFile -replace "\[Patch\]",$rep - Set-Content "$spicePath\config-xpui.ini" $configFile -} - -$backupVer = $configFile -match "^version" -$version = ConvertFrom-StringData $backupVer[0] -if ($version.version.Length -gt 0) { - spicetify apply -} else { - spicetify backup apply -} diff --git a/.config/spicetify/Themes/Dribbblish/lunar.png b/.config/spicetify/Themes/Dribbblish/lunar.png deleted file mode 100644 index 655d871..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/lunar.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/nord-dark.png b/.config/spicetify/Themes/Dribbblish/nord-dark.png deleted file mode 100644 index 3f01074..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/nord-dark.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/nord-light.png b/.config/spicetify/Themes/Dribbblish/nord-light.png deleted file mode 100644 index 26aceb6..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/nord-light.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/purple.png b/.config/spicetify/Themes/Dribbblish/purple.png deleted file mode 100644 index 230311f..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/purple.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/rosepine.png b/.config/spicetify/Themes/Dribbblish/rosepine.png deleted file mode 100644 index 9c7e4e3..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/rosepine.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/samurai.png b/.config/spicetify/Themes/Dribbblish/samurai.png deleted file mode 100644 index fa9505c..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/samurai.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/theme.js b/.config/spicetify/Themes/Dribbblish/theme.js deleted file mode 100644 index bcbdc20..0000000 --- a/.config/spicetify/Themes/Dribbblish/theme.js +++ /dev/null @@ -1,256 +0,0 @@ -function waitForElement(els, func, timeout = 100) { - const queries = els.map(el => document.querySelector(el)); - if (queries.every(a => a)) { - func(queries); - } else if (timeout > 0) { - setTimeout(waitForElement, 300, els, func, --timeout); - } -} - -let DribbblishShared = {}; - -// back shadow -waitForElement([".Root__top-container"], ([topContainer]) => { - const shadow = document.createElement("div"); - shadow.id = "dribbblish-back-shadow"; - topContainer.prepend(shadow); -}); - -// Spicetify.Platform.ConnectAPI.state.connectionStatus; - -// add fade effect on playlist/folder list -waitForElement([".main-navBar-mainNav .os-viewport.os-viewport-native-scrollbars-invisible"], ([scrollNode]) => { - scrollNode.setAttribute("fade", "bottom"); - scrollNode.addEventListener("scroll", () => { - if (scrollNode.scrollTop == 0) { - scrollNode.setAttribute("fade", "bottom"); - } else if (scrollNode.scrollHeight - scrollNode.clientHeight - scrollNode.scrollTop == 0) { - scrollNode.setAttribute("fade", "top"); - } else { - scrollNode.setAttribute("fade", "full"); - } - }); -}); - -// adjust topbar margin with left sidebar width -waitForElement([".Root__nav-bar, #Desktop_LeftSidebar_Id"], ([resizer]) => { - function updateVariable() { - const computedStyle = getComputedStyle(resizer); - const value = Number(computedStyle.getPropertyValue("--left-sidebar-width").trim()) || resizer.clientWidth; - waitForElement([".Root__globalNav"], ([globalNav]) => { - globalNav.style.setProperty("--left-sidebar-width", value); - }); - } - const observer = new ResizeObserver(updateVariable); - observer.observe(resizer); - updateVariable(); -}); - -let version; -let ylx; - -(function Dribbblish() { - // dynamic playback time tooltip - const progBar = document.querySelector(".playback-bar"); - const root = document.querySelector(".Root"); - - if (!Spicetify.Player.origin || !progBar || !root) { - setTimeout(Dribbblish, 300); - return; - } - - version = Spicetify.Platform.PlatformData.event_sender_context_information.client_version_int; - - if (version < 121200000) { - document.documentElement.classList.add("legacy"); - legacy(); - } else if (version >= 121200000 && version < 121400000) { - document.documentElement.classList.add("legacy-gridChange"); - legacy(); - } else if (version >= 121400000) { - document.documentElement.classList.add("ylx"); - ylx = true; - } - - const tooltip = document.createElement("div"); - tooltip.className = "prog-tooltip"; - progBar.append(tooltip); - - function updateProgTime({ data: e }) { - const maxWidth = progBar.offsetWidth; - const curWidth = Spicetify.Player.getProgressPercent() * maxWidth; - const ttWidth = tooltip.offsetWidth / 2; - if (curWidth < ttWidth + 12) { - tooltip.style.left = "12px"; - } else if (curWidth > maxWidth - ttWidth - 12) { - tooltip.style.left = String(maxWidth - ttWidth * 2 - 12) + "px"; - } else { - tooltip.style.left = String(curWidth - ttWidth) + "px"; - } - tooltip.innerText = Spicetify.Player.formatTime(e) + " / " + Spicetify.Player.formatTime(Spicetify.Player.getDuration()); - } - Spicetify.Player.addEventListener("onprogress", updateProgTime); - updateProgTime({ data: Spicetify.Player.getProgress() }); - - // filepicker for custom folder images - const filePickerForm = document.createElement("form"); - filePickerForm.setAttribute("aria-hidden", true); - filePickerForm.innerHTML = ''; - /** @type {HTMLInputElement} */ - const filePickerInput = filePickerForm.childNodes[0]; - filePickerInput.accept = ["image/jpeg", "image/apng", "image/avif", "image/gif", "image/png", "image/svg+xml", "image/webp"].join(","); - - filePickerInput.onchange = () => { - if (!filePickerInput.files.length) return; - - const file = filePickerInput.files[0]; - const reader = new FileReader(); - reader.onload = event => { - const result = event.target.result; - const id = Spicetify.URI.from(filePickerInput.uri).id; - try { - localStorage.setItem("dribbblish:folder-image:" + id, result); - } catch { - Spicetify.showNotification("File too large"); - } - DribbblishShared.loadPlaylistImage?.call(); - }; - reader.readAsDataURL(file); - }; - - // context menu items for custom folder images - new Spicetify.ContextMenu.Item( - "Remove folder image", - ([uri]) => { - const id = Spicetify.URI.from(uri).id; - localStorage.removeItem("dribbblish:folder-image:" + id); - DribbblishShared.loadPlaylistImage?.call(); - }, - ([uri]) => Spicetify.URI.isFolder(uri) && !ylx, - "x" - ).register(); - new Spicetify.ContextMenu.Item( - "Choose folder image", - ([uri]) => { - filePickerInput.uri = uri; - filePickerForm.reset(); - filePickerInput.click(); - }, - ([uri]) => Spicetify.URI.isFolder(uri) && !ylx, - "edit" - ).register(); -})(); - -// LEGACY NAVBAR ONLY -function legacy() { - if (!Spicetify.Platform) { - setTimeout(legacy, 300); - return; - } - - // allow resizing of the navbar - waitForElement([".Root__nav-bar .LayoutResizer__input"], ([resizer]) => { - const observer = new MutationObserver(updateVariable); - observer.observe(resizer, { attributes: true, attributeFilter: ["value"] }); - function updateVariable() { - let value = resizer.value; - if (value < 121) { - value = 72; - document.documentElement.classList.add("left-sidebar-collapsed"); - } else { - document.documentElement.classList.remove("left-sidebar-collapsed"); - } - document.documentElement.style.setProperty("--nav-bar-width", value + "px"); - } - updateVariable(); - }); - - // allow resizing of the buddy feed - waitForElement([".Root__right-sidebar .LayoutResizer__input"], ([resizer]) => { - const observer = new MutationObserver(updateVariable); - observer.observe(resizer, { attributes: true, attributeFilter: ["value"] }); - function updateVariable() { - let value = resizer.value; - let min_value = version < 121200000 ? 321 : 281; - if (value < min_value) { - value = 72; - document.documentElement.classList.add("buddyFeed-hide-text"); - } else { - document.documentElement.classList.remove("buddyFeed-hide-text"); - } - } - updateVariable(); - }); - - waitForElement([".main-nowPlayingBar-container"], ([nowPlayingBar]) => { - const observer = new MutationObserver(updateVariable); - observer.observe(nowPlayingBar, { childList: true }); - function updateVariable() { - if (nowPlayingBar.childElementCount === 2) { - document.documentElement.classList.add("connected"); - } else { - document.documentElement.classList.remove("connected"); - } - } - updateVariable(); - }); - - // add fade effect on playlist/folder list - waitForElement([".main-navBar-navBar .os-viewport.os-viewport-native-scrollbars-invisible"], ([scrollNode]) => { - scrollNode.setAttribute("fade", "bottom"); - scrollNode.addEventListener("scroll", () => { - if (scrollNode.scrollTop == 0) { - scrollNode.setAttribute("fade", "bottom"); - } else if (scrollNode.scrollHeight - scrollNode.clientHeight - scrollNode.scrollTop == 0) { - scrollNode.setAttribute("fade", "top"); - } else { - scrollNode.setAttribute("fade", "full"); - } - }); - }); - - waitForElement([`ul[tabindex="0"]`, `ul[tabindex="0"] .GlueDropTarget--playlists.GlueDropTarget--folders`], ([root, firstItem]) => { - const listElem = firstItem.parentElement; - root.classList.add("dribs-playlist-list"); - - /** Replace Playlist name with their pictures */ - function loadPlaylistImage() { - for (const item of listElem.children) { - let link = item.querySelector("a"); - if (!link) continue; - - let [_, app, uid] = link.pathname.split("/"); - let uri; - if (app === "playlist") { - uri = `spotify:playlist:${uid}`; - } else if (app === "folder") { - const base64 = localStorage.getItem("dribbblish:folder-image:" + uid); - let img = link.querySelector("img"); - if (!img) { - img = document.createElement("img"); - img.classList.add("playlist-picture"); - link.prepend(img); - } - img.src = base64 || "https://cdn.jsdelivr.net/gh/spicetify/spicetify-themes@master/Dribbblish/images/tracklist-row-song-fallback.svg"; - continue; - } - - Spicetify.CosmosAsync.get(`sp://core-playlist/v1/playlist/${uri}/metadata`, { policy: { picture: true } }).then(res => { - const meta = res.metadata; - let img = link.querySelector("img"); - if (!img) { - img = document.createElement("img"); - img.classList.add("playlist-picture"); - link.prepend(img); - } - img.src = meta.picture || "https://cdn.jsdelivr.net/gh/spicetify/spicetify-themes@master/Dribbblish/images/tracklist-row-song-fallback.svg"; - }); - } - } - - DribbblishShared.loadPlaylistImage = loadPlaylistImage; - loadPlaylistImage(); - - new MutationObserver(loadPlaylistImage).observe(listElem, { childList: true }); - }); -} diff --git a/.config/spicetify/Themes/Dribbblish/uninstall.ps1 b/.config/spicetify/Themes/Dribbblish/uninstall.ps1 deleted file mode 100644 index df48c8c..0000000 --- a/.config/spicetify/Themes/Dribbblish/uninstall.ps1 +++ /dev/null @@ -1,15 +0,0 @@ -spicetify config current_theme " " - -$configPath = spicetify -c -$configFile = Get-Content $configPath -$find = $configFile -match "xpui.js_find_8008" -if ($find) { - $configFile = $configFile -replace [regex]::escape($find),"" -} -$repl = $configFile -match "xpui.js_repl_8008" -if ($repl) { - $configFile = $configFile -replace [regex]::escape($repl),"" -} -Set-Content $configPath $configFile - -spicetify apply diff --git a/.config/spicetify/Themes/Dribbblish/user.css b/.config/spicetify/Themes/Dribbblish/user.css deleted file mode 100644 index d687a9f..0000000 --- a/.config/spicetify/Themes/Dribbblish/user.css +++ /dev/null @@ -1,939 +0,0 @@ -:root { - --corner-radius: 10px; - --bar-cover-art-size: 40px; - --scrollbar-vertical-size: 10px; - --scrollbar-horizontal-size: 10px; - --bar-height: 90px; - --main-gap: 10px; -} - -@font-face { - font-family: "Google Sans Display"; - src: url("glue-resources/fonts/GoogleSansDisplayRegular.woff2") format("woff2"); - font-style: normal; - font-weight: 400; -} - -@font-face { - font-family: "Google Sans Display"; - src: url("glue-resources/fonts/GoogleSansDisplayMedium.woff2") format("woff2"); - font-style: normal; - font-weight: 500; -} - -@font-face { - font-family: "Roboto"; - src: url("glue-resources/fonts/Roboto.woff2") format("woff2"); - font-style: normal; - font-weight: 400; -} - -@font-face { - font-family: "Roboto"; - src: url("glue-resources/fonts/RobotoMedium.woff2") format("woff2"); - font-style: normal; - font-weight: 500; -} - -body { - --glue-font-family: "Google Sans Display", "Roboto", spotify-circular, spotify-circular-cyrillic, spotify-circular-arabic, spotify-circular-hebrew, - Helvetica Neue, helvetica, arial, Hiragino Kaku Gothic Pro, Meiryo, MS Gothic, sans-serif; - --info-font-family: "Roboto", spotify-circular, spotify-circular-cyrillic, spotify-circular-arabic, spotify-circular-hebrew, Helvetica Neue, helvetica, - arial, Hiragino Kaku Gothic Pro, Meiryo, MS Gothic, sans-serif; - font-family: var(--glue-font-family); - letter-spacing: normal; -} - -.global-nav .Root__top-container { - grid-template-areas: - "top-banner top-banner top-banner" - "global-nav global-nav global-nav" - "left-sidebar main-view right-sidebar" - "left-sidebar now-playing-bar now-playing-bar" !important; - grid-template-rows: auto auto 1fr auto; -} - -.main-yourLibraryX-libraryContainer { - background: none !important; -} - -.Root__top-container { - grid-template-areas: - "left-sidebar main-view right-sidebar" - "left-sidebar now-playing-bar right-sidebar" !important; - gap: 0; - padding-left: 0 !important; -} - -.global-nav #Desktop_PanelContainer_Id { - border-radius: 0 !important; -} - -.Root__now-playing-bar { - background-color: var(--spice-player); - border-radius: 0 0 var(--corner-radius) var(--corner-radius) !important; - grid-area: now-playing-bar !important; - margin: 0 !important; - padding: 0 !important; -} - -.Root__globalNav { - --left-sidebar-width: 72; - background-color: var(--spice-main) !important; - border-radius: var(--corner-radius) var(--corner-radius) 0 0 !important; - margin: 0; - grid-area: top-banner/1/global-nav/-1; - margin-left: calc(var(--left-sidebar-width) * 1px); - z-index: 10; -} - -.Root__globalNav .main-globalNav-historyButtonsContainer, -.Root__globalNav .main-globalNav-searchSection, -.Root__globalNav .main-topBar-topbarContentRight { - -webkit-transform: scale(0.75); - transform: scale(0.75); -} - -.main-home-filterChipsSection { - background-color: var(--spice-main) !important; -} - -.global-nav .Root__main-view { - border-radius: 0 !important; -} - -.Root__main-view { - border-radius: var(--corner-radius) var(--corner-radius) 0 0 !important; - grid-area: main-view !important; -} - -.legacy .Root__top-container:not(:has(> .Root__right-sidebar)) { - padding-right: var(--main-gap); -} - -.ylx .Root__top-container:not(:has(> .Root__right-sidebar > aside)) { - padding-right: var(--main-gap); -} - -.Root__right-sidebar:not(:has(> aside)) { - padding-left: 0; -} - -.Root__nav-bar { - grid-area: left-sidebar !important; -} - -/* move the progress bar to the top */ -.playback-bar { - position: absolute; - left: 0; - top: -5px; -} - -.main-nowPlayingBar-nowPlayingBar { - position: relative; - padding-inline-end: 16px !important; -} - -.progress-bar { - --progress-bar-height: 2px; - --progress-bar-radius: 0; - --fg-color: var(--spice-button); - --bg-color: rgba(var(--spice-rgb-text), 0.2); -} - -/* add gradient to player bar */ -.main-nowPlayingBar-container { - background-color: unset; - background: radial-gradient(ellipse at right 50% bottom -80px, rgba(var(--spice-rgb-sidebar), 0.55), var(--spice-main) 60%) !important; - border-radius: 0 0 var(--corner-radius) var(--corner-radius) !important; - border-top: 0; - padding: 8px; - min-width: 518px; -} - -/* rearrange player bar */ -.main-nowPlayingBar-left { - order: 1; - flex: 1; - width: auto; - min-width: 0 !important; -} - -.main-nowPlayingBar-center { - order: 0; - flex: 1; - width: auto; - min-width: unset !important; -} - -.main-nowPlayingBar-right { - order: 2; - flex: 1; - width: auto; - min-width: unset !important; -} - -/* hide time elapsed */ -.main-playbackBarRemainingTime-container, -.playback-bar__progress-time-elapsed { - display: none; -} - -/* custom dynamic prog tooltip */ -.playback-bar .prog-tooltip { - position: absolute; - min-width: 100px; - width: unset; - height: 25px; - top: -35px; - padding: 0 5px; - border-radius: 4px; - text-align: center; - color: var(--spice-text); - background-color: var(--spice-button); - opacity: 0; - transition: opacity 0.2s linear, left 0.2s linear; -} - -.playback-bar:hover .prog-tooltip { - opacity: 1; -} - -/* customise player controls buttons */ -.player-controls__buttons { - position: relative; - margin-bottom: 0; -} - -.main-shuffleButton-button { - position: absolute; - left: 200px; -} - -.main-skipForwardButton-button, -.main-repeatButton-button, -.main-skipBackButton-button, -.main-shuffleButton-button { - color: var(--spice-text); -} - -.player-controls__left, -.player-controls__right { - gap: 16px; - flex: 0; -} - -.player-controls__right svg, -.player-controls__left svg { - width: 14px; - height: 14px; -} - -/* customise play button */ -.main-playPauseButton-button { - background-color: transparent !important; -} - -.main-playPauseButton-button svg { - width: 32px !important; - height: 32px !important; - color: var(--spice-button); -} - -/* customise right side player buttons */ -.control-button { - color: var(--spice-text); -} - -.main-genericButton-button { - color: var(--spice-text); -} - -/* customise cards hover play button */ -.main-card-PlayButtonContainer .ButtonInner-medium-iconOnly { - background-color: var(--background-base); - color: var(--spice-text); -} - -/* top welcome box viz. good morning */ -.view-homeShortcutsGrid-PlayButtonContainer .ButtonInner-small-iconOnly, -.view-homeShortcutsGrid-PlayButtonContainer .ButtonInner-medium-iconOnly, -.view-homeShortcutsGrid-PlayButtonContainer .ButtonInner-large-iconOnly { - background-color: var(--background-base); - color: var(--spice-text); -} - -/* top bar sponsored ads */ -.Button-medium-buttonPrimary-useBrowserDefaultFocusStyle .ButtonInner-medium { - background-color: var(--background-base); - color: var(--spice-text); -} - - -/* customise player cover art */ -.main-nowPlayingWidget-coverArt .cover-art { - width: var(--bar-cover-art-size) !important; - height: var(--bar-cover-art-size) !important; - background-color: transparent; -} - -.main-nowPlayingWidget-nowPlaying { - justify-content: center; -} - -/* style navbar */ -.main-navBar-mainNav { - gap: 0 !important; -} - -.main-navBar-mainNav>div { - background-color: var(--spice-sidebar); -} - -.main-yourLibraryX-navLink { - height: 48px; -} - -/* change tab colours */ -.main-navBar-mainNav .link-subtle, -.main-navBar-mainNav .link-subtle svg { - color: var(--spice-sidebar-text) !important; -} - -/* give active nav tab a background */ -.main-navBar-mainNav li:has(> .active) { - background-color: var(--spice-tab-active); - border-radius: 4px; -} - -/* align library button with other nav items */ -.main-yourLibraryX-header { - padding-top: 4px !important; -} - -.main-yourLibraryX-navItems { - padding-bottom: 0 !important; - padding: 8px; -} - -.main-yourLibraryX-navItems li { - padding-left: 16px; -} - -/* remove built in scrolllist shadow */ -.main-yourLibraryX-isScrolled { - box-shadow: none !important; -} - -/* round playlist images */ -.x-entityImage-imageContainer { - border-radius: 50% !important; - background-color: transparent; - width: 40px !important; - height: 40px !important; - align-self: center; - box-shadow: none !important; -} - -li div:has(> .x-entityImage-imageContainer), -li div:has(> .main-yourLibraryX-rowCover) { - justify-content: center; - width: 48px; -} - -/* folder items */ -.x-entityImage-imagePlaceholder { - background-color: transparent; - color: var(--spice-sidebar-text); -} - -/* local files item */ -.main-yourLibraryX-rowCover { - width: 40px; - height: 40px; -} - -.fRZRXRIV2YBCFLYgwDAr { - border-radius: 50% !important; -} - -.fRZRXRIV2YBCFLYgwDAr>svg { - width: 15px; - height: 15px; -} - -/* remove hover effect */ -li>div>div::after { - background-color: transparent !important; -} - -li>div::after { - background-color: transparent !important; -} - -/* give background to active playlist */ -.BoxComponent-group-tinted-listRow-isInteractive-hasLeadingOrMedia-paddingBlockStart_8px-paddingBlockEnd_8px-minBlockSize_56px-padding_8px, -.BoxComponent-group-tinted-listRow-isInteractive-hasFocus-hasLeadingOrMedia-paddingBlockStart_8px-paddingBlockEnd_8px-minBlockSize_56px-padding_8px { - background-color: var(--spice-tab-active); -} - -/* fix scrolllist item colours */ -.main-navBar-mainNav li p { - color: var(--spice-sidebar-text) !important; -} - -.main-navBar-mainNav li p svg { - fill: var(--spice-sidebar-text) !important; -} - -.main-yourLibraryX-listRowIconWrapper { - fill: var(--spice-sidebar-text) !important; -} - -/* reduce spacing between playlist name and subtitle */ -.main-yourLibraryX-listRowSubtitle { - margin-top: -8px; -} - -.main-yourLibraryX-collapseButton>button { - gap: 8px; - color: var(--spice-sidebar-text) !important; -} - -/* expanded sidebar buttons */ -.search-searchCategory-carouselButton { - background-color: transparent; -} - -.search-searchCategory-carouselButton:hover { - background-color: var(--spice-tab-active); -} - -.search-searchCategory-carouselButton svg { - fill: var(--spice-sidebar-text) !important; -} - -.main-yourLibraryX-iconOnly { - color: var(--spice-sidebar-text) !important; -} - -.main-yourLibraryX-iconOnly:hover { - background-color: var(--spice-tab-active); -} - -.main-yourLibraryX-filterArea>div>div:first-child button { - background-color: var(--spice-tab-active) !important; -} - -.main-yourLibraryX-filterArea>div>div:first-child button>span { - background-color: var(--spice-tab-active) !important; - color: var(--spice-text) !important; -} - -.main-yourLibraryX-libraryFilter .x-sortBox-sortDropdown, -.main-yourLibraryX-libraryFilter .x-filterBox-expandButton, -.main-yourLibraryX-libraryFilter .x-filterBox-searchIconContainer, -.main-yourLibraryX-libraryFilter .x-filterBox-filterInput, -.main-yourLibraryX-libraryFilter .x-filterBox-clearButton { - color: var(--spice-sidebar-text); -} - -/* hide main view backgound gradient */ -.main-entityHeader-backgroundColor, -.main-actionBarBackground-background, -.main-topBar-background, -.main-home-homeHeader { - background-color: var(--spice-main) !important; - background-image: none !important; -} - -.main-topBar-background { - border-radius: var(--corner-radius); -} - -.main-topBar-overlay, -.main-trackList-trackListHeader { - background-color: var(--spice-main) !important; -} - -/* fix play button icon colour */ -.main-playButton-PlayButton svg { - color: var(--spice-text); -} - -/* fix playlist action bar buttons colour */ -.main-actionBar-ActionBarRow button, -.main-actionBar-ActionBarRow svg:not(.main-playButton-PlayButton svg) { - color: rgba(var(--spice-rgb-text), 0.7); -} - -.main-actionBar-ActionBarRow button:hover, -.main-actionBar-ActionBarRow button:hover svg:not(.main-playButton-PlayButton svg) { - color: var(--spice-text); -} - -/* change playing icon from gif to svg */ -.main-trackList-playingIcon { - -webkit-mask-image: url("data:image/svg+xml,%3Csvg id='playing-icon' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 24'%3E%3Cdefs%3E%3Cstyle%3E %23playing-icon %7B fill: %2320BC54; %7D @keyframes play %7B 0%25 %7Btransform: scaleY(1);%7D 3.3%25 %7Btransform: scaleY(0.9583);%7D 6.6%25 %7Btransform: scaleY(0.9166);%7D 9.9%25 %7Btransform: scaleY(0.8333);%7D 13.3%25 %7Btransform: scaleY(0.7083);%7D 16.6%25 %7Btransform: scaleY(0.5416);%7D 19.9%25 %7Btransform: scaleY(0.4166);%7D 23.3%25 %7Btransform: scaleY(0.25);%7D 26.6%25 %7Btransform: scaleY(0.1666);%7D 29.9%25 %7Btransform: scaleY(0.125);%7D 33.3%25 %7Btransform: scaleY(0.125);%7D 36.6%25 %7Btransform: scaleY(0.1666);%7D 39.9%25 %7Btransform: scaleY(0.1666);%7D 43.3%25 %7Btransform: scaleY(0.2083);%7D 46.6%25 %7Btransform: scaleY(0.2916);%7D 49.9%25 %7Btransform: scaleY(0.375);%7D 53.3%25 %7Btransform: scaleY(0.5);%7D 56.6%25 %7Btransform: scaleY(0.5833);%7D 59.9%25 %7Btransform: scaleY(0.625);%7D 63.3%25 %7Btransform: scaleY(0.6666);%7D 66.6%25 %7Btransform: scaleY(0.6666);%7D 69.9%25 %7Btransform: scaleY(0.6666);%7D 73.3%25 %7Btransform: scaleY(0.6666);%7D 76.6%25 %7Btransform: scaleY(0.7083);%7D 79.9%25 %7Btransform: scaleY(0.75);%7D 83.3%25 %7Btransform: scaleY(0.8333);%7D 86.6%25 %7Btransform: scaleY(0.875);%7D 89.9%25 %7Btransform: scaleY(0.9166);%7D 93.3%25 %7Btransform: scaleY(0.9583);%7D 96.6%25 %7Btransform: scaleY(1);%7D %7D %23bar1 %7B transform-origin: bottom; animation: play 0.9s -0.51s infinite; %7D %23bar2 %7B transform-origin: bottom; animation: play 0.9s infinite; %7D %23bar3 %7B transform-origin: bottom; animation: play 0.9s -0.15s infinite; %7D %23bar4 %7B transform-origin: bottom; animation: play 0.9s -0.75s infinite; %7D %3C/style%3E%3C/defs%3E%3Ctitle%3Eplaying-icon%3C/title%3E%3Crect id='bar1' class='cls-1' width='4' height='24'/%3E%3Crect id='bar2' class='cls-1' x='6' width='4' height='24'/%3E%3Crect id='bar3' class='cls-1' x='12' width='4' height='24'/%3E%3Crect id='bar4' class='cls-1' x='18' width='4' height='24'/%3E%3C/svg%3E"); - background: var(--spice-button); - content-visibility: hidden; - -webkit-mask-repeat: no-repeat; -} - -/* full screen artists background */ -.main-entityHeader-container.main-entityHeader-withBackgroundImage, -.main-entityHeader-background, -.main-entityHeader-background.main-entityHeader-overlay:after { - height: 100vh; -} - -.artist-artistOverview-overview .main-entityHeader-withBackgroundImage h1 { - font-size: 120px !important; - line-height: 120px !important; -} - -.contentSpacing, -.artist-artistDiscography-headerContainer { - padding-left: 64px; - padding-right: 64px; -} - -.artist-artistOverview-overview .main-entityHeader-headerText { - justify-content: center; -} - -/* progress bar moves smoothly */ -.x-progressBar-fillColor { - transition: transform 1s linear; -} - -.progress-bar__slider { - transition: left 1s linear; -} - -/* progress bar moves instant if clicked */ -*:has(.x-progressBar-fillColor, .progress-bar__slider):active :is(.x-progressBar-fillColor, .progress-bar__slider) { - transition-duration: 0.001s; -} - -/* right sidebar text */ -.Root__right-sidebar { - --text-base: var(--spice-sidebar-text); - --background-tinted-base: var(--spice-tab-active); -} - -.Root__right-sidebar a, -.Root__right-sidebar .main-trackInfo-artists a, -.artist-artistOnTour-timeAndVenue.artist-artistOnTour-condensed, -.Root__right-sidebar .main-nowPlayingView-creditsSource, -.Root__right-sidebar .main-nowPlayingView-playNextButton, -.Root__right-sidebar .main-nowPlayingView-playNext { - color: var(--spice-sidebar-text); -} - -.main-nowPlayingView-content { - --text-subdued: var(--spice-sidebar-text); -} - -/* add main backshadow */ -#dribbblish-back-shadow { - z-index: 5; - grid-area: main-view / main-view / now-playing-bar / main-view; - box-shadow: 0 0 10px 3px #0000003b; - border-radius: var(--corner-radius); - pointer-events: none; -} - -/* add fade effect to playlist scrolllist */ -.os-viewport.os-viewport-native-scrollbars-invisible[fade="full"] { - -webkit-mask-image: linear-gradient(transparent 0%, black 10%, black 90%, transparent 100%); - mask-image: linear-gradient(transparent 0%, black 10%, black 90%, transparent 100%); -} - -.os-viewport.os-viewport-native-scrollbars-invisible[fade="top"] { - -webkit-mask-image: linear-gradient(transparent 0%, black 10%); - mask-image: linear-gradient(transparent 0%, black 10%); -} - -.os-viewport.os-viewport-native-scrollbars-invisible[fade="bottom"] { - -webkit-mask-image: linear-gradient(black 90%, transparent 100%); - mask-image: linear-gradient(black 90%, transparent 100%); -} - -/* style input els */ -input { - background-color: unset !important; - border-bottom: solid 1px var(--spice-text) !important; - border-radius: 0 !important; - padding: 6px 10px 6px 48px; - color: var(--spice-text) !important; -} - -.Root__nav-bar input { - border-bottom: solid 1px var(--spice-sidebar-text) !important; - color: var(--spice-sidebar-text) !important; -} - -.Root__nav-bar input::placeholder { - color: rgba(var(--spice-rgb-sidebar-text), 0.5) !important; -} - -/* fix connect bar styles */ -.main-connectBar-connectBar { - color: var(--spice-main) !important; - border-radius: 0 0 var(--corner-radius) var(--corner-radius); -} - -/* topbar play button */ -.main-topBar-topbarContent .main-playButton-PlayButton>button>span { - inline-size: 32px; - block-size: 32px; - min-block-size: auto; -} - -.main-topBar-topbarContent .main-playButton-PlayButton svg { - width: 18px; - height: 18px; -} - -.main-topBar-topbarContent .main-playButton-PlayButton>button>span>span { - position: initial; - height: 18px; -} - -/* disable dynamic lyrics background */ -.lyrics-lyrics-container { - --lyrics-color-inactive: rgba(var(--spice-rgb-text), 0.3) !important; -} - -.lyrics-lyrics-background { - background-color: var(--spice-main); -} - -/* v1.2.14 */ -.main-yourLibraryX-libraryContainer.main-yourLibraryX-libraryIsExpanded.main-yourLibraryX-libraryIsCollapsed, -.main-yourLibraryX-libraryRootlist.main-yourLibraryX-libraryIsExpanded:not(.main-yourLibraryX-libraryIsCollapsed) { - padding-bottom: 0; -} - -[dir="ltr"] .main-nowPlayingWidget-coverExpanded { - transform: none; -} - -.ylx .main-coverSlotExpanded-container { - bottom: calc(var(--main-gap) + 70px + 10px); - left: calc(var(--nav-bar-width) + 10px); -} - -.ylx.connected .main-coverSlotExpanded-container { - bottom: calc(var(--main-gap) + 70px + 24px + 10px); -} - -/* v1.2.12 -> 1.2.13 */ -.main-buddyFeed-container { - background-color: inherit; - box-shadow: none; - overflow: initial; -} - -.legacy-gridChange .main-coverSlotExpanded-container { - left: calc(var(--nav-bar-width) + 10px); -} - -/* v1.2.0 --> 1.2.11 */ -.legacy .Root__top-container { - grid-template-areas: - "left-sidebar top-bar right-sidebar" - "left-sidebar main-view right-sidebar" - "left-sidebar now-playing-bar right-sidebar" !important; -} - -.Root__top-container { - padding: 10px 0; - background-color: var(--spice-sidebar); -} - -.Root__right-sidebar { - background-color: var(--spice-sidebar); -} - -.Root__main-view { - background-color: var(--spice-main); -} - -.main-rootlist-rootlistDivider { - background-color: transparent; -} - -.main-buddyFeed-activityMetadata .main-buddyFeed-username a, -.main-buddyFeed-activityMetadata .main-buddyFeed-artistAndTrackName a, -.main-buddyFeed-activityMetadata .main-buddyFeed-usernameAndTimestamp, -.main-buddyFeed-activityMetadata .main-buddyFeed-playbackContextLink { - color: var(--spice-sidebar-text) !important; -} - -.main-buddyFeed-activityMetadata .main-buddyFeed-artistAndTrackName { - color: var(--spice-sidebar-text); -} - -.collection-icon, -.premiumSpotifyIcon, -.search-icon { - color: var(--spice-sidebar-text) !important; -} - -.main-confirmDialog-container { - background-color: var(--spice-card); -} - -.main-confirmDialog-container .TypeElement-canon-textBase { - color: var(--spice-text); -} - -.main-confirmDialog-buttonContainer button span { - color: var(--spice-card); -} - -.main-coverSlotExpanded-container { - position: fixed; - z-index: 2; - width: 250px; - height: 250px; - bottom: calc(var(--main-gap) + var(--bar-height) + 10px); - left: calc(var(--nav-bar-width) + 20px); -} - -.connected .main-coverSlotExpanded-container { - bottom: calc(var(--main-gap) + var(--bar-height) + 24px + 10px); -} - -.left-sidebar-collapsed .main-coverSlotExpanded-container { - left: 82px; -} - -.main-coverSlotExpanded-container img { - border-radius: 4px; -} - -.cover-art { - border-radius: 4px; -} - -.left-sidebar-collapsed .Root__nav-bar { - width: 72px; -} - -.left-sidebar-collapsed .main-rootlist-statusIcons { - display: none; -} - -.main-navBar-navBarLinkActive { - background-color: var(--spice-tab-active); -} - -.Root__nav-bar .main-rootlist-rootlist .os-scrollbar-handle { - display: none; -} - -.Root__top-container:has(> .Root__top-container--right-sidebar-hidden) { - padding-right: 10px; -} - -/* buddy feed w/ hidden text*/ -.buddyFeed-hide-text .Root__top-container:not(:has(> .Root__top-container--right-sidebar-hidden)) .Root__right-sidebar { - width: 72px !important; -} - -.buddyFeed-hide-text .NdQkQZhcYIEcJnRdAYcQ, -.buddyFeed-hide-text .main-buddyFeed-header { - display: none; -} - -.buddyFeed-hide-text .main-buddyFeed-friendActivity { - padding: 0 0 0 4px; -} - -.buddyFeed-hide-text .main-buddyFeed-activityMetadata { - visibility: hidden; -} - -.buddyFeed-hide-text .main-avatar-avatar>div>div>div { - display: flex; - justify-content: center; - padding-top: 7px; -} - -.buddyFeed-hide-text .main-avatar-avatar, -.buddyFeed-hide-text .main-avatar-avatar div, -.buddyFeed-hide-text .main-buddyFeed-overlay { - width: 32px !important; - height: 32px !important; -} - -.main-rootlist-rootlistDividerGradient { - background: none; -} - -.main-collectionLinkButton-collectionLinkButton .main-collectionLinkButton-icon, -.main-collectionLinkButton-collectionLinkButton .main-collectionLinkButton-collectionLinkText { - opacity: 1; -} - -.main-collectionLinkButton-collectionLinkButton, -.main-createPlaylistButton-button { - color: var(--spice-sidebar-text); - opacity: 1; -} - -.main-likedSongsButton-likedSongsIcon { - background: none; -} - -.main-likedSongsButton-likedSongsIcon>svg { - height: 20px !important; - width: 20px !important; -} - -/* style added sidebar images */ -.main-rootlist-rootlistItem a { - align-items: center; - border-radius: 4px; - display: flex; - height: 56px; - gap: 12px; -} - -img.playlist-picture { - width: 32px; - height: 32px; - flex: 0 0 32px; - background-size: cover; - background-position: center; - border-radius: 50%; -} - -img.playlist-picture[src$=".svg"] { - width: 24px; - height: 24px; - border-radius: 0; -} - -.legacy .Root__nav-bar .main-rootlist-wrapper, -.legacy-gridChange .Root__nav-bar .main-rootlist-wrapper { - height: fit-content !important; - contain: none !important; -} - -.main-navBar-mainNav li:has(> div > .active) { - background-color: var(--spice-tab-active); -} - -.main-collectionLinkButton-selected.active { - background-color: var(--spice-tab-active) !important; -} - -.legacy .main-navBar-mainNav li, -.legacy-gridChange .main-navBar-mainNav li { - background-color: transparent !important; -} - -/* a.active { - background-color: var(--spice-tab-active) !important; -} */ -.main-rootlist-rootlistItem:has(> .main-rootlist-rootlistItemLinkActive) { - background-color: var(--spice-tab-active) !important; -} - -.main-rootlist-rootlistItemLink { - padding-left: 12px; -} - -.main-rootlist-rootlistItem { - margin-left: 8px; - margin-right: 8px; - padding-left: 0 !important; - padding-right: 8px !important; - border-radius: 4px; -} - -.dribs-playlist-list { - overflow: hidden; -} - -.left-sidebar-collapsed .main-rootlist-expandArrow { - display: none; -} - -.main-navBar-navBarLink, -.main-collectionLinkButton-collectionLinkButton, -.main-createPlaylistButton-button { - height: 56px !important; -} - -.Button-md-buttonSecondary-useBrowserDefaultFocusStyle { - border: 1px solid var(--spice-text); -} - -.Button-md-buttonPrimary-useBrowserDefaultFocusStyle .ButtonInner-md { - color: var(--spice-text); -} - -/* sidebar speaker icon */ -.CCeu9OfWSwIAJqA49n84 { - color: var(--spice-sidebar-text); -} - -.legacy .Root__right-sidebar .os-content { - overflow-x: hidden; -} - -.Root__right-sidebar .os-scrollbar-horizontal { - display: none; -} - -.UyzJidwrGk3awngSGIwv, -.poz9gZKE7xqFwgk231J4, -.xWm_uA0Co4SXVxaO7wlB { - color: var(--spice-text); -} - -.main-navBar-navBarLink { - color: var(--spice-sidebar-text); -} - -.main-navBar-navBarLink:focus, -.main-navBar-navBarLink:hover { - color: var(--spice-sidebar-text); -} - -.main-createPlaylistButton-createPlaylistIcon { - background-color: var(--spice-sidebar-text); -} - -.main-rootlist-rootlistItemLink:link, -.main-rootlist-rootlistItemLink:visited { - color: var(--spice-sidebar-text) !important; -} - -.main-rootlist-expandArrow { - color: var(--spice-sidebar-text); -} - -.main-buddyFeed-actions button, -.main-buddyFeed-titleContainer { - color: var(--spice-sidebar-text) !important; -} - -.main-tag-container { - background-color: var(--spice-subtext); -} - -.main-buddyFeed-content { - height: 100%; -} - -/* bottom scroll-bar popup fix */ -.Root__main-view-overlay { - width: 100%; -} diff --git a/.config/spicetify/Themes/Dribbblish/white.png b/.config/spicetify/Themes/Dribbblish/white.png deleted file mode 100644 index 07d6db6..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/white.png and /dev/null differ diff --git a/.config/spicetify/Themes/Dribbblish/windows-shortcut-instruction.png b/.config/spicetify/Themes/Dribbblish/windows-shortcut-instruction.png deleted file mode 100644 index cb1d39d..0000000 Binary files a/.config/spicetify/Themes/Dribbblish/windows-shortcut-instruction.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/README.md b/.config/spicetify/Themes/Matte/README.md deleted file mode 100644 index 6ed1259..0000000 --- a/.config/spicetify/Themes/Matte/README.md +++ /dev/null @@ -1,111 +0,0 @@ -# Matte - -## Screenshots - -### Matte - -![Matte](screenshots/ylx-matte.png) - -### Periwinkle - -![Periwinkle](screenshots/ylx-periwinkle.png) - -### Periwinkle-Dark - -![Periwkinle Dark](screenshots/ylx-periwinkle-dark.png) - -### Porcelain - -![Porcelain](screenshots/ylx-porcelain.png) - -### Gray-Dark1 - -![Gray Dark 1](screenshots/ylx-gray-dark1.png) - -### Gray-Dark2 - -![Gray Dark 2](screenshots/ylx-gray-dark2.png) - -### Gray-Dark3 - -![Gray Dark 3](screenshots/ylx-gray-dark3.png) - -### Gray - -![Gray](screenshots/ylx-gray.png) - -### Gray-Light - -![Gray Light](screenshots/ylx-gray-light.png) - -## More - -### Description - -a Spicetify theme which features a distinct top bar, quick-to-edit CSS variables, and color schemes from Windows visual styles by KDr3w - -### Credits - -- Based on [Matte by KDr3w](https://www.deviantart.com/kdr3w/art/Matte-758699852) and their [other themes](https://www.deviantart.com/kdr3w/gallery/68078309/windows-10-themes) - -- Created by [darkthemer](https://github.com/darkthemer) - -### Notes - -- Check the very top of `user.css` for quick configs - - - If you use the Marketplace, go to `Marketplace > Snippets > + Add CSS` and then paste the quick configs found in `user.css`. Edit these as you wish. - -```css -/* ================================ - USER-EDITABLE VARIABLES - ================================ */ - -:root { - /* top bar vars */ - --top-bar-padding-top: 45px; - --top-bar-padding-right: 20px; - --top-bar-padding-bottom: 5px; - --top-bar-padding-left: 20px; - --tab-border-radius: 6px; - --top-bar-border-width: 2px; - - /* sidebar vars */ - --sidebar-button-border-radius: 4px; - --sidebar-border-width: 2px; - - /* player vars */ - --player-height: 90px; - --player-padding: 0 20px; - --player-border-width: 2px; - - /* scrollbar vars */ - --scrollbar-border-radius: 4px; - --scrollbar-width: 6px; - --scrollbar-width-hover: 6px; -} -``` - -- For Windows users, here's how to make the window controls' background match with the topbar background - - - Enable [CEF/Spotify Tweaks](https://windhawk.net/mods/cef-titlebar-enabler-universal) in Windhawk (recommended) - - - Put this snippet into your `user.css` (or through the Marketplace's custom CSS feature) (alternative) - -```css -/* transparent window controls background */ -.spotify__container--is-desktop:not(.fullscreen) body::after { - content: ""; - position: absolute; - right: 0; - z-index: 999; - backdrop-filter: brightness(2.12); - /* page zoom [ctrl][+] or [ctrl][-] - edit width and height accordingly - */ - width: 135px; - height: 48px; -} -``` - -![Window Controls](screenshots/winctrl.png) diff --git a/.config/spicetify/Themes/Matte/color.ini b/.config/spicetify/Themes/Matte/color.ini deleted file mode 100644 index 19e9e12..0000000 --- a/.config/spicetify/Themes/Matte/color.ini +++ /dev/null @@ -1,575 +0,0 @@ -; COLORS' KEY DESCRIPTIONS - -; topbar = background -; topbar-text = title, enabled history button -; topbar-subtext = unselected tabs, disabled history button -; tab-active = selected tab item, search bar background -; tab-active-text = selected tab item, search bar text -; tab-hover = hovered tab item, hovered search bar -; topbar-border = bottom border - -; sidebar = background -; sidebar-text = primary text (home, search, library, playlists, etc) -; link-hover-text = hovered link item text -; link-active = selected link item background -; link-active-text = selected link item text -; sidebar-border = left or right border - -; main = background -; text = primary text (heading, title, some name, song count, button text, etc) -; subtext = secondary text (description, some name, duration, tracklist album, play count, etc) -; selected-row = some details, border, button (heart, download, options in playlist or album) - -; player = background -; player-text = song title, hovered text -; player-subtext = artist name, time duration -; player-selected-row = progress bar (background, duration, volume), button (playback, extra) -; player-border = top border - -; button = button (lyrics, queue in player bar, on toggle in settings) -; button-active = button (play-pause button, current song title in queue, active heart, hovered button and toggle) -; button-disabled = button (off toggle and dropdown menu in settings) -; scrollbar = default -; scrollbar-hover = hovered -; context-menu = background -; context-menu-text = primary text -; context-menu-hover = hovered item backgrond -; card = hovered card, tracks in queue or playlist, etc -; shadow = context menu shadow, popup background dim, popup button background (close, carousel), toast shadow -; notification = toast background, private session indicator -; notification-error = error toast background -; misc = idk - -; main-elevated = ylx carousel buttons, etc -; highlight-elevated = ylx hovered carousel buttons, etc -; highlight = ylx hovered playlist link, etc - -[matte] -; topbar -topbar = 232b32 -topbar-text = d0d2d9 -topbar-subtext = 4a5460 -tab-active = 1c2228 -tab-active-text = d0d2d9 -tab-hover = 131b20 -topbar-border = 232b32 - -; sidebars -sidebar = 181e23 -sidebar-text = 7e8596 -link-active-text = 181e23 -sidebar-border = 181e23 - -; main view -main = 1c2228 -text = b9bcc6 -subtext = 7e8596 -selected-row = 5b6b79 - -; player bar -player = 141b1f -player-text = 969aa9 -player-subtext = 6d8392 -player-selected-row = 6d8392 -player-border = 141b1f - -; accent colors -link-hover-text = 009587 -link-active = 009587 -button = 01bfa5 -button-active = 01bfa5 -scrollbar-hover = 009688 - -; others -button-disabled = 2c353e -scrollbar = 39454f -context-menu = 232b32 -context-menu-text = d0d2d9 -context-menu-hover = 343e47 -card = 232d35 -shadow = 101418 -notification = 1c2228 -notification-error = b73434 -misc = 39454f - -; ylx -main-elevated = 1c2228 -highlight-elevated = 232d35 -highlight = 20272d - -[periwinkle] -; topbar -topbar-text = ffffff -topbar-subtext = aaa5e4 -tab-active-text = d0ccff -tab-hover = ffffff - -; sidebars -sidebar = ffffff -sidebar-text = 010101 -link-active-text = ffffff -sidebar-border = ffffff - -; main view -main = ffffff -text = 010101 -subtext = 6d6d6d -selected-row = 6d6d6d - -; player bar -player = ffffff -player-text = 010101 -player-subtext = 6d6d6d -player-selected-row = 6d6d6d -player-border = d9d9d9 - -; accent colors -topbar = 7269d2 -tab-active = 7269d2 -topbar-border = 7269d2 -link-hover-text = 8c84da -link-active = 7269d2 -button = 7269d2 -button-active = 8c84da -scrollbar-hover = 8a82e0 -context-menu-hover = 7269d2 - -; others -button-disabled = ebebeb -scrollbar = d9d9d9 -context-menu = ffffff -context-menu-text = 010101 -card = ebebeb -shadow = 363163 -notification = ffffff -notification-error = ff4264 -misc = 6d6d6d - -; ylx -main-elevated = ffffff -highlight-elevated = ebebeb -highlight = ebebeb - -[periwinkle-dark] -; topbar -topbar-text = f6f6f6 -topbar-subtext = aaa5e4 -tab-active-text = d0ccff -tab-hover = 383838 - -; sidebars -sidebar = 383838 -sidebar-text = d0d0d0 -link-hover-text = 8c84da -link-active-text = f6f6f6 -sidebar-border = 383838 - -; main view -main = 383838 -text = f6f6f6 -subtext = d0d0d0 -selected-row = d0d0d0 - -; player bar -player = 343434 -player-text = f6f6f6 -player-subtext = d0d0d0 -player-selected-row = d0d0d0 -player-border = 2e2e2e - -; accent colors -topbar = 7269d2 -tab-active = 7269d2 -topbar-border = 7269d2 -link-active = 7269d2 -button = 7269d2 -button-active = 8c84da -scrollbar-hover = 8a82e0 -context-menu-hover = 7269d2 - -; others -button-disabled = 444444 -scrollbar = 494949 -context-menu = 343434 -context-menu-text = f6f6f6 -card = 444444 -shadow = 2e2e2e -notification = 343434 -notification-error = ff4264 -misc = d0d0d0 - -; ylx -main-elevated = 383838 -highlight-elevated = 444444 -highlight = 444444 - -[porcelain] -; topbar -topbar = e8eaf0 -topbar-text = 242b31 -topbar-subtext = 899099 -tab-active = e8eaf0 -tab-active-text = 242b31 -tab-hover = ffffff -topbar-border = e8eaf0 - -; sidebars -sidebar = dfe1e8 -sidebar-text = 3f4b56 -link-hover-text = 6a7495 -link-active-text = dfe1e8 -sidebar-border = dfe1e8 - -; main view -main = f9f9fb -text = 3f4b56 -subtext = 70828f -selected-row = 70828f - -; player bar -player = d5d8df -player-text = 364049 -player-subtext = 4e5a67 -player-selected-row = 4e5a67 -player-border = cdd0d8 - -; accent colors -link-active = 43a8ff -button = 43a8ff -button-active = 038aff -scrollbar-hover = 43a8ff - -; others -button-disabled = c0c5ce -scrollbar = d6dbdf -context-menu = e8eaf0 -context-menu-text = 2f353c -context-menu-hover = ced2db -card = e3e6ea -shadow = 6d6e71 -notification = f9f9fb -notification-error = e6395f -misc = 4e5a67 - -; ylx -main-elevated = f9f9fb -highlight-elevated = e3e6ea -highlight = ced1db - -[rose-pine-moon] -; topbar -topbar = 141428 -topbar-text = e0def4 -topbar-subtext = 7a7a7a -tab-active = 1f1f1f -tab-active-text = d4d4d4 -tab-hover = 272727 -topbar-border = 191919 - -; sidebars -sidebar = 232136 -sidebar-text = e0def4 -link-hover-text = 6d6d6d -link-active = 423d67 -link-active-text = e8e8e8 -sidebar-border = 191919 - -; main view -main = 232136 -text = e0def4 -subtext = 908caa -selected-row = ebbcba - -; player bar -player = 232136 -player-text = e0def4 -player-subtext = e0def4 -player-selected-row = ebbcba -player-border = 191919 - -; accent colors -button-active = ebbcba - -; others -button = ebbcba -button-disabled = 2a273f -scrollbar = 2a273f -scrollbar-hover = dddbf1 -context-menu = 141428 -context-menu-text = e0def4 -context-menu-hover = 3b385c -card = 393552 -shadow = 393552 -notification = 393552 -notification-error = eb6f92 -misc = 232136 - -; ylx -main-elevated = 202020 -highlight-elevated = 2d2d2d -highlight = 2d2d2d - -[gray-dark1] -; topbar -topbar = 191919 -topbar-text = d4d4d4 -topbar-subtext = 7a7a7a -tab-active = 1f1f1f -tab-active-text = d4d4d4 -tab-hover = 272727 -topbar-border = 191919 - -; sidebars -sidebar = 202020 -sidebar-text = d4d4d4 -link-hover-text = 6d6d6d -link-active = 2d2d2d -link-active-text = e8e8e8 -sidebar-border = 191919 - -; main view -main = 202020 -text = d4d4d4 -subtext = 959595 -selected-row = 6d6d6d - -; player bar -player = 202020 -player-text = d4d4d4 -player-subtext = 959595 -player-selected-row = 959595 -player-border = 191919 - -; accent colors -button-active = 2080df - -; others -button = 404040 -button-disabled = 252525 -scrollbar = 353535 -scrollbar-hover = 999999 -context-menu = 202020 -context-menu-text = d4d4d4 -context-menu-hover = 2d2d2d -card = 2d2d2d -shadow = 0c0c0c -notification = 202020 -notification-error = d32635 -misc = 959595 - -; ylx -main-elevated = 202020 -highlight-elevated = 2d2d2d -highlight = 2d2d2d - -[gray-dark2] -; topbar -topbar = 191919 -topbar-text = d4d4d4 -topbar-subtext = 535353 -tab-active = 191919 -tab-active-text = d4d4d4 -tab-hover = 1f1f1f -topbar-border = 191919 - -; sidebars -sidebar = 161616 -sidebar-text = d4d4d4 -link-hover-text = 6c6c6c -link-active = 1c1c1c -link-active-text = d4d4d4 -sidebar-border = 161616 - -; main view -main = 202020 -text = d4d4d4 -subtext = 959595 -selected-row = 6d6d6d - -; player bar -player = 1a1a1a -player-text = d4d4d4 -player-subtext = 959595 -player-selected-row = 959595 -player-border = 1a1a1a - -; accent colors -button-active = 2080df - -; others -button = 404040 -button-disabled = 252525 -scrollbar = 353535 -scrollbar-hover = 999999 -context-menu = 202020 -context-menu-text = d4d4d4 -context-menu-hover = 2d2d2d -card = 2d2d2d -shadow = 0c0c0c -notification = 202020 -notification-error = d32635 -misc = 959595 - -; ylx -main-elevated = 202020 -highlight-elevated = 2d2d2d -highlight = 2d2d2d - -[gray-dark3] -; topbar -topbar = 191919 -topbar-text = d4d4d4 -topbar-subtext = 7a7a7a -tab-active = 191919 -tab-active-text = d4d4d4 -tab-hover = 1f1f1f -topbar-border = 191919 - -; sidebars -sidebar = 131313 -sidebar-text = d4d4d4 -link-hover-text = 6c6c6c -link-active = 1e1e1e -link-active-text = d4d4d4 -sidebar-border = 131313 - -; main view -main = 161616 -text = d4d4d4 -subtext = 959595 -selected-row = 6d6d6d - -; player bar -player = 101010 -player-text = d4d4d4 -player-subtext = 959595 -player-selected-row = 959595 -player-border = 101010 - -; accent colors -button-active = 2080df - -; others -button = 404040 -button-disabled = 252525 -scrollbar = 353535 -scrollbar-hover = 999999 -context-menu = 202020 -context-menu-text = d4d4d4 -context-menu-hover = 2d2d2d -card = 2d2d2d -shadow = 0c0c0c -notification = 202020 -notification-error = d32635 -misc = 959595 - -; ylx -main-elevated = 161616 -highlight-elevated = 2d2d2d -highlight = 2d2d2d - -[gray] -; topbar -topbar = 404040 -topbar-text = e9e9e9 -topbar-subtext = 646464 -tab-active = 333333 -tab-active-text = e9e9e9 -tab-hover = 303030 -topbar-border = 404040 - -; sidebars -sidebar = 383838 -sidebar-text = d4d4d4 -link-hover-text = e9e9e9 -link-active = 4c4c4c -link-active-text = e9e9e9 -sidebar-border = 2f2f2f - -; main view -main = 383838 -text = e9e9e9 -subtext = aaaaaa -selected-row = 6d6d6d - -; player bar -player = 343434 -player-text = d4d4d4 -player-subtext = 7f7f7f -player-selected-row = 7f7f7f -player-border = 2e2e2e - -; accent colors -button-active = 2888d7 - -; others -button = 898989 -button-disabled = 404040 -scrollbar = 494949 -scrollbar-hover = a3a3a3 -context-menu = 383838 -context-menu-text = d4d4d4 -context-menu-hover = 4c4c4c -card = 4c4c4c -shadow = 1e1e1e -notification = 383838 -notification-error = e35b5b -misc = 959595 - -; ylx -main-elevated = 383838 -highlight-elevated = 4c4c4c -highlight = 444444 - -[gray-light] -; topbar -topbar = 404040 -topbar-text = e9e9e9 -topbar-subtext = 646464 -tab-active = 333333 -tab-active-text = e9e9e9 -tab-hover = 303030 -topbar-border = 404040 - -; sidebars -sidebar = ffffff -sidebar-text = 010101 -link-hover-text = 010101 -link-active = e1e1e1 -link-active-text = 010101 -sidebar-border = e9e9e9 - -; main view -main = ffffff -text = 010101 -subtext = 6d6d6d -selected-row = 6d6d6d - -; player bar -player = ffffff -player-text = 010101 -player-subtext = 6d6d6d -player-selected-row = 6d6d6d -player-border = e9e9e9 - -; accent colors -button = 2888d7 -button-active = 2888d7 - -; others -button-disabled = dfdfdf -scrollbar = d9d9d9 -scrollbar-hover = 4d4d4d -context-menu = ffffff -context-menu-text = 010101 -context-menu-hover = ebebeb -card = ebebeb -shadow = 1e1e1e -notification = ffffff -notification-error = e35b5b -misc = 6d6d6d - -; ylx -main-elevated = ffffff -highlight-elevated = ebebeb -highlight = ebebeb diff --git a/.config/spicetify/Themes/Matte/screenshots/winctrl.png b/.config/spicetify/Themes/Matte/screenshots/winctrl.png deleted file mode 100644 index 991c6f9..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/winctrl.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark1.png b/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark1.png deleted file mode 100644 index dfd2a05..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark1.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark2.png b/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark2.png deleted file mode 100644 index 8389342..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark2.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark3.png b/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark3.png deleted file mode 100644 index e39d8a0..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-dark3.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-light.png b/.config/spicetify/Themes/Matte/screenshots/ylx-gray-light.png deleted file mode 100644 index 6f98a19..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-gray-light.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-gray.png b/.config/spicetify/Themes/Matte/screenshots/ylx-gray.png deleted file mode 100644 index dfdcd87..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-gray.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-matte.png b/.config/spicetify/Themes/Matte/screenshots/ylx-matte.png deleted file mode 100644 index be5b718..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-matte.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle-dark.png b/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle-dark.png deleted file mode 100644 index 55f3569..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle-dark.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle.png b/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle.png deleted file mode 100644 index 0cb02ba..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-periwinkle.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/screenshots/ylx-porcelain.png b/.config/spicetify/Themes/Matte/screenshots/ylx-porcelain.png deleted file mode 100644 index a4cb82f..0000000 Binary files a/.config/spicetify/Themes/Matte/screenshots/ylx-porcelain.png and /dev/null differ diff --git a/.config/spicetify/Themes/Matte/user.css b/.config/spicetify/Themes/Matte/user.css deleted file mode 100644 index aa2a53f..0000000 --- a/.config/spicetify/Themes/Matte/user.css +++ /dev/null @@ -1,546 +0,0 @@ -/* ================================ - USER-EDITABLE VARIABLES - ================================ */ - -:root { - /* top bar vars */ - --top-bar-padding-top: 45px; - --top-bar-padding-right: 20px; - --top-bar-padding-bottom: 5px; - --top-bar-padding-left: 20px; - --tab-border-radius: 6px; - --top-bar-border-width: 2px; - - /* sidebar vars */ - --sidebar-button-border-radius: 4px; - --sidebar-border-width: 2px; - - /* player vars */ - --player-height: 90px; - --player-padding: 0 20px; - --player-border-width: 2px; - - /* scrollbar vars */ - --scrollbar-border-radius: 4px; - --scrollbar-width: 6px; - --scrollbar-width-hover: 6px; -} - -/* ================================ - GLOBAL NAV - ================================ */ - -.Root__globalNav { - /* add nav padding */ - padding: var(--top-bar-padding-top) var(--top-bar-padding-right) - var(--top-bar-padding-bottom) var(--top-bar-padding-left) !important; - border-bottom: var(--top-bar-border-width) solid var(--spice-topbar-border); -} -.Root__globalNav .main-globalNav-link-icon { - border-radius: var(--tab-border-radius); - background-color: var(--spice-topbar); - color: var(--spice-topbar-subtext); -} -.Root__globalNav .main-globalNav-navLinkActive { - background-color: var(--spice-tab-active); - color: var(--spice-topbar-text); -} -form .main-topBar-searchBar { - /* style seaerch bar */ - border-radius: var(--tab-border-radius) !important; -} -form:hover .main-topBar-searchBar, -form .main-topBar-searchBar:focus { - background: var(--spice-tab-hover) !important; - -webkit-box-shadow: none !important; - box-shadow: none !important; -} - -/* fix spacing */ -.main-globalNav-historyButtonsContainer > div { - gap: 0; - -webkit-padding-start: 0; - padding-inline-start: 0; - -webkit-margin-start: 0; - margin-inline-start: 0; -} -.main-globalNav-historyButtonsContainer > div > div:nth-child(1), -.Root__globalNav > div:nth-child(3) > div:nth-child(2) { - height: 0; - width: 0; -} -.Root__globalNav > div:nth-child(3) { - -webkit-margin-end: 0; - margin-inline-end: 0; -} -.main-globalNav-historyButtons { - gap: 0 !important; - padding-inline: 0 !important; -} -.main-globalNav-historyButtons > button { - padding-inline: var(--encore-spacing-tighter, 12px); -} - -/* ================================ - NAVBAR / LEFT SIDEBAR - ================================ */ - -.Root__nav-bar { - /* add border */ - border-right: var(--sidebar-border-width) solid var(--spice-sidebar-border); -} -.LayoutResizer__resize-bar--resizing, -.LayoutResizer__resize-bar:focus-within, -.LayoutResizer__resize-bar:hover { - /* remove border on hovering layout resizer */ - opacity: 0; -} -.LayoutResizer__resize-bar { - /* replace cursor on layout resize */ - cursor: w-resize; - width: 2px; -} -.LayoutResizer__inline-end { - inset-inline-end: 0; -} -.main-yourLibraryX-entryPoints, -.Root__main-view { - border-radius: 0; -} -.main-yourLibraryX-navItems { - padding-bottom: 0; -} -.main-yourLibraryX-navItem, -.main-yourLibraryX-headerContent { - padding: 4px 0; -} -.main-yourLibraryX-navItem { - padding: 4px 0; -} -.main-yourLibraryX-navLink { - padding: 12px; - text-decoration: none !important; -} -.main-yourLibraryX-navLink, -.main-yourLibraryX-header .main-yourLibraryX-collapseButtonWrapper { - gap: 20px; -} -.Wrapper-md-leading { - margin-inline-end: 0; -} -.main-yourLibraryX-libraryRootlist { - padding: 0 16px 16px; -} -.main-rootlist-wrapper .LineClamp { - -webkit-line-clamp: 1; - line-clamp: 1; -} -.main-yourLibraryX-libraryContainer { - background-color: var(--spice-sidebar); -} - -/* ================================ - MAIN VIEW - ================================ */ - -.main-view-container__scroll-node-child-spacer { - /* remove main view padding */ - display: none; -} -.marketplace-header, -.main-home-filterChipsContainer, -.main-trackList-trackListHeader, -.search-searchCategory-SearchCategory, -.artist-artistDiscography-topBar { - /* fix home filter, track list header, search category, artist discography */ - top: -1px !important; - height: auto; -} -.LVMjmN2CaPruPAo62RAY { - height: unset !important; -} -.marketplace-header, -.main-home-filterChipsContainer, -.search-searchCategory-SearchCategory { - /* home filter, fix search category */ - border-bottom: 1px solid rgba(var(--spice-rgb-selected-row), 0.1); - padding: 16px 0; -} -.search-searchCategory-catergoryGrid button { - margin-bottom: 0 !important; -} -.search-searchCategory-catergoryGrid button[aria-checked="true"] span { - /* customize active search category */ - border-radius: var(--tab-border-radius); -} -.main-trackList-trackListHeader, -.artist-artistDiscography-topBar { - /* fix track list header & artist discography */ - padding: 16px 32px 0 32px; -} -.main-trackList-trackListHeaderStuck.main-trackList-trackListHeader, -.artist-artistDiscography-topBar.artist-artistDiscography-topBarScrolled { - /* fix tracklist header & artist discography */ - box-shadow: none; - border-bottom: 1px solid rgba(var(--spice-rgb-selected-row), 0.1); -} -.search-recentSearches-searchPageGrid - .main-trackList-trackListHeader.main-trackList-trackListHeaderStuck { - /* fix tracklist header in search */ - top: 64px !important; -} -.main-home-homeHeader, -.x-entityHeader-overlay, -.x-actionBarBackground-background, -.main-actionBarBackground-background, -.main-entityHeader-overlay, -.main-entityHeader-backgroundColor { - /* remove background gradient */ - background-color: unset !important; - background-image: unset !important; -} - -/* full window artist background */ -.main-entityHeader-background.main-entityHeader-gradient, -.under-main-view > div > div { - opacity: 0.3 !important; -} -.main-entityHeader-container.main-entityHeader-withBackgroundImage, -.main-entityHeader-background, -.main-entityHeader-background.main-entityHeader-overlay:after, -.under-main-view > div > div { - height: 100vh; -} -.main-entityHeader-withBackgroundImage .main-entityHeader-headerText { - justify-content: center; -} -.main-entityHeader-container.main-entityHeader-nonWrapped.main-entityHeader-withBackgroundImage { - padding-left: 9%; -} -.main-entityHeader-background.main-entityHeader-overlay:after { - background-image: linear-gradient(transparent, transparent), - linear-gradient(var(--spice-main), var(--spice-main)); -} -.artist-artistOverview-overview .main-entityHeader-withBackgroundImage h1 { - font-size: 20vh !important; - line-height: 20vh !important; -} -/* cards */ -.main-cardImage-imageWrapper { - background-color: transparent; -} -.main-card-card { - background: none; -} -.main-cardImage-image { - border-radius: 12px; -} -.main-cardImage-imageWrapper, -.main-entityHeader-shadow { - /* remove drop shadows from images */ - -webkit-box-shadow: none; - box-shadow: none; -} -/* popup modal */ -.main-trackCreditsModal-container { - background-color: var(--spice-main); -} -.main-trackCreditsModal-closeBtn svg path { - fill: var(--spice-subtext); -} -/* lyrics */ -.lyrics-lyrics-background { - background-color: var(--spice-main); -} -.lyrics-lyrics-container.lyrics-lyrics-coverTopBar { - --lyrics-color-active: var(--spice-text) !important; - --lyrics-color-inactive: var(--spice-subtext) !important; - --lyrics-color-passed: var(--spice-subtext) !important; - --lyrics-color-messaging: var(--spice-subtext) !important; -} -.lyrics-lyricsContent-lyric { - opacity: 0.3; -} -.lyrics-lyricsContent-lyric.lyrics-lyricsContent-highlight { - opacity: 0.7; -} -.lyrics-lyricsContent-lyric.lyrics-lyricsContent-isInteractive.lyrics-lyricsContent-active { - text-shadow: 0 0 10px var(--lyrics-color-background), - -2px 1px 0 var(--spice-main), -3px 2px 0 var(--lyrics-color-background), - 2px -1px 0 var(--spice-main), 3px -2px 0 var(--lyrics-color-background); - opacity: 1; -} - -/* ================================ - RIGHT SIDEBAR - ================================ */ - -.Root__right-sidebar { - border-left: var(--sidebar-border-width) solid var(--spice-sidebar-border); -} -.Root__right-sidebar aside::before { - background-color: var(--spice-sidebar) !important; -} - -/* ================================ - NOW PLAYING BAR - ================================ */ - -.Root__now-playing-bar { - border-top: var(--player-border-width) solid var(--spice-player-border); -} -.main-nowPlayingBar-nowPlayingBar { - /* customize now playing bar */ - height: var(--player-height); - padding: var(--player-padding); -} -.main-nowPlayingBar-container { - /* customize now playing bar*/ - border-top: none; -} -[dir="ltr"] .main-nowPlayingWidget-coverExpanded { - transform: translateX(-76px); -} -.x-progressBar-fillColor { - /* fluid progress bars */ - transition: transform, 0s, ease, 0.25s; -} -.progress-bar__slider { - /* fluid progress bars */ - transition: left, 0s, ease, 0.25s; -} - -/* ================================ - MISC & FIXES - ================================ */ - -/* root - -------------------------------- */ -.Root { - --panel-gap: 0 !important; -} -.spotify__container--is-desktop .Root__top-container { - padding-top: 0 !important; -} - -/* scrollbar - -------------------------------- */ -.os-scrollbar-handle { - /* customize scrollbar */ - border-radius: var(--scrollbar-border-radius) !important; - width: var(--scrollbar-width) !important; - margin: 0 6px !important; -} -.os-scrollbar-handle:hover { - /* customize hovered scrollbar */ - border-radius: var(--scrollbar-border-radius) !important; - width: var(--scrollbar-width-hover) !important; -} -.os-scrollbar-handle { - /* increase size from right to left */ - position: absolute; - top: 0; - right: 0; -} - -/* tooltip - -------------------------------- */ -.main-contextMenu-tippy { - /* position below the element */ - transform: translate(0, 65px); -} - -/* placeholder - -------------------------------- */ -.T7WHRub8pynnWPXERh8e, -.rOgsguaurlHVlgCTY0P7, -.eC25_w41L83mXDCqdm_A { - /* playlists loading placeholder */ - opacity: 0.05; - filter: contrast(0.1); -} - -/* color reassignment - -------------------------------- */ -.encore-dark-theme, -.encore-dark-theme .encore-base-set, -*[style*="subdued"] { - /* song duration & queue button & folder arrow & settings desc text */ - --text-subdued: var(--spice-subtext) !important; - --essential-subdued: var(--spice-subtext) !important; -} -.encore-dark-theme .encore-bright-accent-set { - --background-highlight: var(--spice-button-active); - --background-press: var(--spice-button-active); - --background-elevated-base: var(--spice-button-active); - --background-elevated-highlight: var(--spice-button-active); - --background-elevated-press: var(--spice-button-active); -} -.search-searchCategory-contentArea { - --carousel-start-chevron-gradient: var(--spice-main); - --carousel-end-chevron-gradient: var(--spice-main); -} - -/* ====global nav==== */ -.Root__globalNav { - background-color: var(--spice-topbar); -} - -/* ====left sidebar==== */ -.main-yourLibraryX-entryPoints { - background-color: var(--spice-sidebar); -} -.main-yourLibraryX-navLinkActive, -.main-yourLibraryX-navLinkActive .home-active-icon, -.main-yourLibraryX-navLinkActive .search-active-icon { - color: var(--spice-link-active-text) !important; - background-color: var(--spice-link-active); - border-radius: var(--tab-border-radius); -} -.link-subtle { - transition-property: none; - color: var(--spice-sidebar-text); -} -.link-subtle:focus, -.link-subtle:hover { - color: var(--spice-link-hover-text); -} -.Button-md-24-buttonTertiary-iconLeading-condensed-useBrowserDefaultFocusStyle, -.Button-md-24-buttonTertiary-iconLeading-condensed-isUsingKeyboard-useBrowserDefaultFocusStyle { - color: var(--spice-sidebar-text); -} - -/* ====main view==== */ -div[style*="background-base"], -div[style*="background-color"], -div[style*="background-color"] + div { - --background-base: var(--spice-main) !important; - background-color: var(--spice-main) !important; - background-image: none !important; -} -.main-topBar-overlay { - background-color: transparent; -} -.main-trackList-trackListRow.main-trackList-selected, -.main-trackList-trackListRow.main-trackList-selected:hover, -.main-trackList-trackListRow:focus-within, -.main-trackList-trackListRow:hover { - background-color: var(--spice-card); -} -.main-trackList-trackListHeaderStuck.main-trackList-trackListHeader, -.artist-artistDiscography-topBar.artist-artistDiscography-topBarScrolled { - background: var(--spice-main) !important; -} -.main-trackList-placeholder { - /* recolor loading tracklist */ - opacity: 0.05; - filter: contrast(0.1); -} -.view-homeShortcutsGrid-equaliser, -.main-trackList-playingIcon, -.main-devicePicker-nowPlayingActiveIcon { - /* change playing icon color to theme color */ - filter: grayscale(1) opacity(0.2) - drop-shadow(0 0 0 var(--spice-button-active)) - drop-shadow(0 0 0 var(--spice-button-active)) - drop-shadow(0 0 0 var(--spice-button-active)); -} -.main-home-filterChipsSection, -.main-home-filterChipsSection:after { - background-color: var(--spice-main) !important; -} -.search-searchCategory-catergoryGrid button[aria-checked="true"] span { - color: var(--spice-main); - background-color: var(--spice-button-active) !important; -} -.search-searchCategory-catergoryGrid span { - border-radius: var(--tab-border-radius); - color: var(--spice-subtext); -} -.artist-artistAbout-container.artist-artistAbout-backgroundImage - .artist-artistAbout-content - > div { - /* change about artist text color */ - color: #fff; -} -.main-dropDown-dropDown, -.x-settings-input { - background-color: var(--spice-button-disabled); - color: var(--spice-text); -} - -/* ====right sidebar==== */ -.TypeElement-balladBold-textBase-type, -.main-buddyFeed-activityMetadata .main-buddyFeed-artistAndTrackName { - color: var(--spice-sidebar-text); -} - -/* ====now playing bar==== */ -.main-nowPlayingBar-container { - background-color: var(--spice-player); -} -.main-trackInfo-name, -.main-trackInfo-artists a:active, -.main-trackInfo-artists a:focus, -.main-trackInfo-artists a:hover { - color: var(--spice-player-text) !important; -} -.main-trackInfo-artists a:link, -.main-trackInfo-artists a:visited { - color: var(--spice-player-subtext); -} -.main-playPauseButton-button { - color: var(--spice-player); - background-color: var(--spice-button-active); -} -.Button-textBrightAccent-small-small-buttonTertiary-iconOnly-useBrowserDefaultFocusStyle, -.Button-textBrightAccent-small-small-buttonTertiary-iconOnly-isUsingKeyboard-useBrowserDefaultFocusStyle { - color: var(--spice-button) !important; -} -.progress-bar { - --bg-color: rgba(var(--spice-rgb-player-selected-row), 0.3); - --fg-color: var(--spice-player-selected-row); -} - -/* ====misc==== */ - -/* ----scrollbar---- */ -.os-scrollbar-handle { - background-color: var(--spice-scrollbar) !important; -} -.os-scrollbar-handle:hover, -.os-scrollbar-handle:active { - background-color: var(--spice-scrollbar-hover) !important; -} - -/* ----context menu---- */ -.main-contextMenu-menu { - background-color: var(--spice-context-menu); -} -.main-contextMenu-menuHeading, -.main-contextMenu-menuItemButton, -.main-contextMenu-menuItemButton:not(.main-contextMenu-disabled):focus, -.main-contextMenu-menuItemButton:not(.main-contextMenu-disabled):hover { - color: var(--spice-context-menu-text); -} -.main-contextMenu-menuItemButton:not(.main-contextMenu-disabled):focus, -.main-contextMenu-menuItemButton:not(.main-contextMenu-disabled):hover { - background-color: var(--spice-context-menu-hover); -} - -/* ----button---- */ -#_R_G *:not([fill="none"]) { - /* fix heart color on click */ - fill: var(--spice-button-active) !important; -} -#_R_G *:not([stroke="none"]) { - stroke: var(--spice-button-active); -} -.ButtonInner-md-iconOnly { - /* base play/pause icon color on player instead of sidebar */ - color: var(--spice-player); -} -.Button-sm-16-buttonTertiary-iconOnly-condensedAll-useBrowserDefaultFocusStyle { - /* base play/pause icon color on sidebar text instead of subtext */ - color: var(--spice-sidebar-text); -} diff --git a/.config/spicetify/Themes/marketplace/color.ini b/.config/spicetify/Themes/marketplace/color.ini deleted file mode 100644 index fcea565..0000000 --- a/.config/spicetify/Themes/marketplace/color.ini +++ /dev/null @@ -1,2 +0,0 @@ -[Marketplace] - diff --git a/.config/spicetify/config-xpui.ini b/.config/spicetify/config-xpui.ini deleted file mode 100644 index d78270e..0000000 --- a/.config/spicetify/config-xpui.ini +++ /dev/null @@ -1,32 +0,0 @@ -[Setting] -always_enable_devtools = 0 -current_theme = Matte -color_scheme = Porcelain -inject_theme_js = 1 -inject_css = 1 -overwrite_assets = 0 -spotify_path = /usr/share/spotify/ -prefs_path = /home/cory/.config/spotify/prefs -replace_colors = 1 -spotify_launch_flags = -check_spicetify_update = 1 - -[Preprocesses] -disable_sentry = 1 -disable_ui_logging = 1 -remove_rtl_rule = 1 -expose_apis = 1 - -[AdditionalOptions] -extensions = -custom_apps = marketplace -sidebar_config = 0 -home_config = 1 -experimental_features = 1 - -[Patch] - -; DO NOT CHANGE! -[Backup] -version = 1.2.77.358.g4339a634 -with = 2.42.5 diff --git a/.config/systemmonitorrc b/.config/systemmonitorrc index e55ee4a..a383d4f 100644 --- a/.config/systemmonitorrc +++ b/.config/systemmonitorrc @@ -1,2 +1,2 @@ [General] -lastVisitedPage=processes.page +lastVisitedPage=overview.page diff --git a/.config/xdg-desktop-portal-kderc b/.config/xdg-desktop-portal-kderc index 5d3e52d..aafb29a 100644 --- a/.config/xdg-desktop-portal-kderc +++ b/.config/xdg-desktop-portal-kderc @@ -1,6 +1,6 @@ [FileDialogSize] -2560x1440 screen: Height=720 -2560x1440 screen: Width=1280 +2560x1440 screen: Height=779 +2560x1440 screen: Width=1053 [KFileDialog Settings] detailViewIconSize=64 diff --git a/.fonts/.uuid b/.fonts/.uuid new file mode 100644 index 0000000..16bf28f --- /dev/null +++ b/.fonts/.uuid @@ -0,0 +1 @@ +be656a01-3548-40d5-bfd6-949154131a73 \ No newline at end of file diff --git a/.fonts/CaskaydiaMonoNerdFont/.uuid b/.fonts/CaskaydiaMonoNerdFont/.uuid index 86b72c9..de14534 100644 --- a/.fonts/CaskaydiaMonoNerdFont/.uuid +++ b/.fonts/CaskaydiaMonoNerdFont/.uuid @@ -1 +1 @@ -495111cc-8ea0-4d99-8b4d-13237930b19f \ No newline at end of file +6667c4ef-9767-4628-8f4d-0b6d4cb8b26d \ No newline at end of file diff --git a/.fonts/IBMPlexMono/.uuid b/.fonts/IBMPlexMono/.uuid index e4a942d..d37a507 100644 --- a/.fonts/IBMPlexMono/.uuid +++ b/.fonts/IBMPlexMono/.uuid @@ -1 +1 @@ -b84d288e-5713-4163-956c-c58925fa3d63 \ No newline at end of file +b743830c-f2ea-4b1a-85f8-5970bd2f8251 \ No newline at end of file diff --git a/.fonts/Terminus/.uuid b/.fonts/Terminus/.uuid index 7bebac4..fca0b2b 100644 --- a/.fonts/Terminus/.uuid +++ b/.fonts/Terminus/.uuid @@ -1 +1 @@ -3e0d7114-4a80-4b88-ae30-0e91f2cfe35c \ No newline at end of file +09f48f51-cd46-4d20-b071-09456b6d16dd \ No newline at end of file diff --git a/.vaults/.obsidian/app.json b/.vaults/.obsidian/app.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/.vaults/.obsidian/app.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/.vaults/.obsidian/appearance.json b/.vaults/.obsidian/appearance.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/.vaults/.obsidian/appearance.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/.vaults/.obsidian/community-plugins.json b/.vaults/.obsidian/community-plugins.json new file mode 100644 index 0000000..c7e81a8 --- /dev/null +++ b/.vaults/.obsidian/community-plugins.json @@ -0,0 +1,3 @@ +[ + "remotely-save" +] \ No newline at end of file diff --git a/.vaults/.obsidian/core-plugins.json b/.vaults/.obsidian/core-plugins.json new file mode 100644 index 0000000..639b90d --- /dev/null +++ b/.vaults/.obsidian/core-plugins.json @@ -0,0 +1,33 @@ +{ + "file-explorer": true, + "global-search": true, + "switcher": true, + "graph": true, + "backlink": true, + "canvas": true, + "outgoing-link": true, + "tag-pane": true, + "footnotes": false, + "properties": true, + "page-preview": true, + "daily-notes": true, + "templates": true, + "note-composer": true, + "command-palette": true, + "slash-command": false, + "editor-status": true, + "bookmarks": true, + "markdown-importer": false, + "zk-prefixer": false, + "random-note": false, + "outline": true, + "word-count": true, + "slides": false, + "audio-recorder": false, + "workspaces": false, + "file-recovery": true, + "publish": false, + "sync": true, + "bases": true, + "webviewer": false +} \ No newline at end of file diff --git a/.vaults/.obsidian/plugins/remotely-save/.gitignore b/.vaults/.obsidian/plugins/remotely-save/.gitignore new file mode 100644 index 0000000..2d46485 --- /dev/null +++ b/.vaults/.obsidian/plugins/remotely-save/.gitignore @@ -0,0 +1 @@ +data.json diff --git a/.vaults/.obsidian/plugins/remotely-save/main.js b/.vaults/.obsidian/plugins/remotely-save/main.js new file mode 100644 index 0000000..c080112 --- /dev/null +++ b/.vaults/.obsidian/plugins/remotely-save/main.js @@ -0,0 +1,235 @@ +(()=>{var __webpack_modules__={66339:(e,t,r)=>{"use strict";var i=r(67526),n=r(251),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null; +/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */t.hp=l,t.IS=50;var s=2147483647;function a(e){if(e>s)throw new RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return u(e)}return d(e,t,r)}function d(e,t,r){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!l.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var r=0|m(e,t),i=a(r),n=i.write(e,t);n!==r&&(i=i.slice(0,n));return i}(e,t);if(ArrayBuffer.isView(e))return p(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(j(e,ArrayBuffer)||e&&j(e.buffer,ArrayBuffer))return h(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(j(e,SharedArrayBuffer)||e&&j(e.buffer,SharedArrayBuffer)))return h(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var i=e.valueOf&&e.valueOf();if(null!=i&&i!==e)return l.from(i,t,r);var n=function(e){if(l.isBuffer(e)){var t=0|f(e.length),r=a(t);return 0===r.length||e.copy(r,0,0,t),r}if(void 0!==e.length)return"number"!=typeof e.length||H(e.length)?a(0):p(e);if("Buffer"===e.type&&Array.isArray(e.data))return p(e.data)}(e);if(n)return n;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return l.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function c(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return c(e),a(e<0?0:0|f(e))}function p(e){for(var t=e.length<0?0:0|f(e.length),r=a(t),i=0;i=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|e}function m(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||j(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var r=e.length,i=arguments.length>2&&!0===arguments[2];if(!i&&0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return q(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return U(e).length;default:if(n)return i?-1:q(e).length;t=(""+t).toLowerCase(),n=!0}}function g(e,t,r){var i=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return F(this,t,r);case"utf8":case"utf-8":return B(this,t,r);case"ascii":return I(this,t,r);case"latin1":case"binary":return A(this,t,r);case"base64":return T(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,t,r);default:if(i)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),i=!0}}function y(e,t,r){var i=e[t];e[t]=e[r],e[r]=i}function v(e,t,r,i,n){if(0===e.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),H(r=+r)&&(r=n?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(n)return-1;r=e.length-1}else if(r<0){if(!n)return-1;r=0}if("string"==typeof t&&(t=l.from(t,i)),l.isBuffer(t))return 0===t.length?-1:b(e,t,r,i,n);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,i,n);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,i,n){var o,s=1,a=e.length,l=t.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(e.length<2||t.length<2)return-1;s=2,a/=2,l/=2,r/=2}function d(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(n){var c=-1;for(o=r;oa&&(r=a-l),o=r;o>=0;o--){for(var u=!0,p=0;pn&&(i=n):i=n;var o=t.length;i>o/2&&(i=o/2);for(var s=0;s>8,n=r%256,o.push(n),o.push(i);return o}(t,e.length-r),e,r,i)}function T(e,t,r){return 0===t&&r===e.length?i.fromByteArray(e):i.fromByteArray(e.slice(t,r))}function B(e,t,r){r=Math.min(e.length,r);for(var i=[],n=t;n239?4:d>223?3:d>191?2:1;if(n+u<=r)switch(u){case 1:d<128&&(c=d);break;case 2:128==(192&(o=e[n+1]))&&(l=(31&d)<<6|63&o)>127&&(c=l);break;case 3:o=e[n+1],s=e[n+2],128==(192&o)&&128==(192&s)&&(l=(15&d)<<12|(63&o)<<6|63&s)>2047&&(l<55296||l>57343)&&(c=l);break;case 4:o=e[n+1],s=e[n+2],a=e[n+3],128==(192&o)&&128==(192&s)&&128==(192&a)&&(l=(15&d)<<18|(63&o)<<12|(63&s)<<6|63&a)>65535&&l<1114112&&(c=l)}null===c?(c=65533,u=1):c>65535&&(c-=65536,i.push(c>>>10&1023|55296),c=56320|1023&c),i.push(c),n+=u}return function(e){var t=e.length;if(t<=C)return String.fromCharCode.apply(String,e);var r="",i=0;for(;ir&&(e+=" ... "),""},o&&(l.prototype[o]=l.prototype.inspect),l.prototype.compare=function(e,t,r,i,n){if(j(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),t<0||r>e.length||i<0||n>this.length)throw new RangeError("out of range index");if(i>=n&&t>=r)return 0;if(i>=n)return-1;if(t>=r)return 1;if(this===e)return 0;for(var o=(n>>>=0)-(i>>>=0),s=(r>>>=0)-(t>>>=0),a=Math.min(o,s),d=this.slice(i,n),c=e.slice(t,r),u=0;u>>=0,isFinite(r)?(r>>>=0,void 0===i&&(i="utf8")):(i=r,r=void 0)}var n=this.length-t;if((void 0===r||r>n)&&(r=n),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var o=!1;;)switch(i){case"hex":return w(this,e,t,r);case"utf8":case"utf-8":return _(this,e,t,r);case"ascii":return x(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return k(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return E(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),o=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var C=4096;function I(e,t,r){var i="";r=Math.min(e.length,r);for(var n=t;ni)&&(r=i);for(var n="",o=t;or)throw new RangeError("Trying to access beyond buffer length")}function R(e,t,r,i,n,o){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||te.length)throw new RangeError("Index out of range")}function P(e,t,r,i,n,o){if(r+i>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function O(e,t,r,i,o){return t=+t,r>>>=0,o||P(e,0,r,4),n.write(e,t,r,i,23,4),r+4}function z(e,t,r,i,o){return t=+t,r>>>=0,o||P(e,0,r,8),n.write(e,t,r,i,52,8),r+8}l.prototype.slice=function(e,t){var r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||D(e,t,this.length);for(var i=this[e],n=1,o=0;++o>>=0,t>>>=0,r||D(e,t,this.length);for(var i=this[e+--t],n=1;t>0&&(n*=256);)i+=this[e+--t]*n;return i},l.prototype.readUInt8=function(e,t){return e>>>=0,t||D(e,1,this.length),this[e]},l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||D(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||D(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||D(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||D(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||D(e,t,this.length);for(var i=this[e],n=1,o=0;++o=(n*=128)&&(i-=Math.pow(2,8*t)),i},l.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||D(e,t,this.length);for(var i=t,n=1,o=this[e+--i];i>0&&(n*=256);)o+=this[e+--i]*n;return o>=(n*=128)&&(o-=Math.pow(2,8*t)),o},l.prototype.readInt8=function(e,t){return e>>>=0,t||D(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||D(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},l.prototype.readInt16BE=function(e,t){e>>>=0,t||D(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||D(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||D(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readFloatLE=function(e,t){return e>>>=0,t||D(e,4,this.length),n.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||D(e,4,this.length),n.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||D(e,8,this.length),n.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||D(e,8,this.length),n.read(this,e,!1,52,8)},l.prototype.writeUIntLE=function(e,t,r,i){(e=+e,t>>>=0,r>>>=0,i)||R(this,e,t,r,Math.pow(2,8*r)-1,0);var n=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,i)||R(this,e,t,r,Math.pow(2,8*r)-1,0);var n=r-1,o=1;for(this[t+n]=255&e;--n>=0&&(o*=256);)this[t+n]=e/o&255;return t+r},l.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,1,255,0),this[t]=255&e,t+1},l.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},l.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeIntLE=function(e,t,r,i){if(e=+e,t>>>=0,!i){var n=Math.pow(2,8*r-1);R(this,e,t,r,n-1,-n)}var o=0,s=1,a=0;for(this[t]=255&e;++o>>=0,!i){var n=Math.pow(2,8*r-1);R(this,e,t,r,n-1,-n)}var o=r-1,s=1,a=0;for(this[t+o]=255&e;--o>=0&&(s*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/s|0)-a&255;return t+r},l.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},l.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||R(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeFloatLE=function(e,t,r){return O(this,e,t,!0,r)},l.prototype.writeFloatBE=function(e,t,r){return O(this,e,t,!1,r)},l.prototype.writeDoubleLE=function(e,t,r){return z(this,e,t,!0,r)},l.prototype.writeDoubleBE=function(e,t,r){return z(this,e,t,!1,r)},l.prototype.copy=function(e,t,r,i){if(!l.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),i||0===i||(i=this.length),t>=e.length&&(t=e.length),t||(t=0),i>0&&i=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-t=0;--o)e[o+t]=this[o+r];else Uint8Array.prototype.set.call(e,this.subarray(r,i),t);return n},l.prototype.fill=function(e,t,r,i){if("string"==typeof e){if("string"==typeof t?(i=t,t=0,r=this.length):"string"==typeof r&&(i=r,r=this.length),void 0!==i&&"string"!=typeof i)throw new TypeError("encoding must be a string");if("string"==typeof i&&!l.isEncoding(i))throw new TypeError("Unknown encoding: "+i);if(1===e.length){var n=e.charCodeAt(0);("utf8"===i&&n<128||"latin1"===i)&&(e=n)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o55295&&r<57344){if(!n){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===i){(t-=3)>-1&&o.push(239,191,189);continue}n=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),n=r;continue}r=65536+(n-55296<<10|r-56320)}else n&&(t-=3)>-1&&o.push(239,191,189);if(n=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function U(e){return i.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(N,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function L(e,t,r,i){for(var n=0;n=t.length||n>=e.length);++n)t[n+r]=e[n];return n}function j(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function H(e){return e!=e}var $=function(){for(var e="0123456789abcdef",t=new Array(256),r=0;r<16;++r)for(var i=16*r,n=0;n<16;++n)t[i+n]=e[r]+e[n];return t}()},64114:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.AESCipherBlock=t.EMECipher=void 0;const n=r(80469);function o(e,t){if(16!==t.length)throw Error("len must be 16");const r=new Uint8Array(16);r[0]=2*t[0],t[15]>=128&&(r[0]=135^r[0]);for(let e=1;e<16;e++)r[e]=2*t[e],t[e-1]>=128&&(r[e]=r[e]+1);e.set(r)}function s(e,t,r){if(t.length!==r.length)throw Error(`input1.length=${t.length} is not equal to input2.length=${r.length}`);for(let i=0;i128)throw Error(`EME operates on 1 to 128 block-cipher blocks, you passed ${c}`);const u=new Uint8Array(d.length),p=yield function(e,t){return i(this,void 0,void 0,(function*(){const r=new Uint8Array(16),i=new Uint8Array(16);yield e.encrypt(i,r);const n=new Array(t);for(let e=0;e=r)break}}function _(e){return w(0,e)}function x(e){const t=Math.floor(e/y),r=e%y;let i=32+t*(g+y);return 0!==r&&(i+=g+r),i}function S(e){let r=e;if(r-=32,r<0)throw new Error(t.msgErrorEncryptedFileTooShort);const i=Math.floor(r/v);let n=r%v,o=i*y;if(0!==n&&(n-=g,n<=0))throw new Error(t.msgErrorEncryptedFileBadHeader);return o+=n,o}t.Cipher=class{constructor(e){this.dataKey=new Uint8Array(32),this.nameKey=new Uint8Array(32),this.nameTweak=new Uint8Array(16),this.dirNameEncrypt=!0,this.fileNameEnc=e}toString(){return`\ndataKey=${this.dataKey} \nnameKey=${this.nameKey}\nnameTweak=${this.nameTweak}\ndirNameEncrypt=${this.dirNameEncrypt}\nfileNameEnc=${this.fileNameEnc}\n`}encodeToString(e){if("base32"===this.fileNameEnc)return p.base32hex.stringify(e,{pad:!1}).toLowerCase();if("base64"===this.fileNameEnc)return p.base64url.stringify(e,{pad:!1});if("base32768"===this.fileNameEnc)return h.encode(e);throw Error(`unknown fileNameEnc=${this.fileNameEnc}`)}decodeString(e){if("base32"===this.fileNameEnc){if(e.endsWith("="))throw new Error(t.msgErrorBadBase32Encoding);return p.base32hex.parse(e.toUpperCase(),{loose:!0})}if("base64"===this.fileNameEnc)return p.base64url.parse(e,{loose:!0});if("base32768"===this.fileNameEnc)return h.decode(e);throw Error(`unknown fileNameEnc=${this.fileNameEnc}`)}key(e,t){return s(this,void 0,void 0,(function*(){const r=this.dataKey.length+this.nameKey.length+this.nameTweak.length;let i,n=b;return""!==t&&(n=(new TextEncoder).encode(t)),i=""===e?new Uint8Array(r):yield(0,a.scryptAsync)((new TextEncoder).encode(e),n,{N:16384,r:8,p:1,dkLen:r}),this.dataKey.set(i.slice(0,this.dataKey.length)),this.nameKey.set(i.slice(this.dataKey.length,this.dataKey.length+this.nameKey.length)),this.nameTweak.set(i.slice(this.dataKey.length+this.nameKey.length)),this}))}updateInternalKey(e,t,r){return this.dataKey=e,this.nameKey=t,this.nameTweak=r,this}getInternalKey(){return{dataKey:this.dataKey,nameKey:this.nameKey,nameTweak:this.nameTweak}}encryptSegment(e){return s(this,void 0,void 0,(function*(){if(""===e)return"";const t=(0,c.pad)((new TextEncoder).encode(e),16),r=new u.AESCipherBlock(this.nameKey),i=new u.EMECipher(r),n=yield i.encrypt(this.nameTweak,t);return this.encodeToString(n)}))}encryptFileName(e){return s(this,void 0,void 0,(function*(){const t=e.split("/");for(let e=0;e>=BigInt(8),i=i+BigInt(n)+BigInt(o),t[e]=Number(i),i>>=BigInt(8)}i!==BigInt(0)&&w(8,t)},t.encryptedSize=x,t.decryptedSize=S},19409:(e,t)=>{"use strict";t.op=void 0;t.op=class{constructor(e){if(void 0===e)this.stackBack=[],this.stackFront=[],this.length=0;else{this.stackFront=[];for(let t=e.length-1;t>=0;t--)this.stackFront.push(e[t]);this.stackBack=[],this.length=this.stackFront.length}}push(e){this.stackBack.push(e),this.length+=1}pop(){if(0!==this.length){if(0===this.stackFront.length)for(;this.stackBack.length>0;)this.stackFront.push(this.stackBack.pop());return this.length-=1,this.stackFront.pop()}}shift(){return this.pop()}size(){return this.length}front(){if(0!==this.length){if(0===this.stackFront.length)for(;this.stackBack.length>0;)this.stackFront.push(this.stackBack.pop());return this.stackFront[this.stackFront.length-1]}}back(){if(0!==this.length)return this.stackBack.length>0?this.stackBack[this.stackBack.length-1]:this.stackFront[0]}}},32506:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCipher=t.rotl=t.sigma=void 0;const i=r(24605),n=r(36527),o=e=>Uint8Array.from(e.split("").map((e=>e.charCodeAt(0)))),s=o("expand 16-byte k"),a=o("expand 32-byte k"),l=(0,n.u32)(s),d=(0,n.u32)(a);function c(e){return e.byteOffset%4==0}t.sigma=d.slice(),t.rotl=function(e,t){return e<>>32-t};const u=2**32-1,p=new Uint32Array;t.createCipher=function(e,t){const{allowShortKeys:r,extendNonceFn:o,counterLength:s,counterRight:a,rounds:h}=(0,n.checkOpts)({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},t);if("function"!=typeof e)throw new Error("core must be a function");return(0,i.number)(s),(0,i.number)(h),(0,i.bool)(a),(0,i.bool)(r),(t,f,m,g,y=0)=>{(0,i.bytes)(t),(0,i.bytes)(f),(0,i.bytes)(m);const v=m.length;if(g||(g=new Uint8Array(v)),(0,i.bytes)(g),(0,i.number)(y),y<0||y>=u)throw new Error("arx: counter overflow");if(g.length=u)throw new Error("arx: counter overflow");const c=Math.min(64,d-n);if(m&&64===c){const e=n/4;if(n%4!=0)throw new Error("arx: invalid block position");for(let t,r=0;r<16;r++)t=e+r,y[t]=g[t]^f[r];n+=64}else{for(let e,t=0;t0;)b.pop().fill(0);return g}}},24605:(e,t)=>{"use strict";function r(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`positive integer expected, not ${e}`)}function i(e){if("boolean"!=typeof e)throw new Error(`boolean expected, not ${e}`)}function n(e){return e instanceof Uint8Array||null!=e&&"object"==typeof e&&"Uint8Array"===e.constructor.name}function o(e,...t){if(!n(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error(`Uint8Array expected of length ${t}, not of length=${e.length}`)}function s(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("hash must be wrapped by utils.wrapConstructor");r(e.outputLen),r(e.blockLen)}function a(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function l(e,t){o(e);const r=t.outputLen;if(e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.poly1305=t.wrapConstructorWithKey=void 0;const i=r(24605),n=r(36527),o=(e,t)=>255&e[t++]|(255&e[t++])<<8;class s{constructor(e){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,e=(0,n.toBytes)(e),(0,i.bytes)(e,32);const t=o(e,0),r=o(e,2),s=o(e,4),a=o(e,6),l=o(e,8),d=o(e,10),c=o(e,12),u=o(e,14);this.r[0]=8191&t,this.r[1]=8191&(t>>>13|r<<3),this.r[2]=7939&(r>>>10|s<<6),this.r[3]=8191&(s>>>7|a<<9),this.r[4]=255&(a>>>4|l<<12),this.r[5]=l>>>1&8190,this.r[6]=8191&(l>>>14|d<<2),this.r[7]=8065&(d>>>11|c<<5),this.r[8]=8191&(c>>>8|u<<8),this.r[9]=u>>>5&127;for(let t=0;t<8;t++)this.pad[t]=o(e,16+2*t)}process(e,t,r=!1){const i=r?0:2048,{h:n,r:s}=this,a=s[0],l=s[1],d=s[2],c=s[3],u=s[4],p=s[5],h=s[6],f=s[7],m=s[8],g=s[9],y=o(e,t+0),v=o(e,t+2),b=o(e,t+4),w=o(e,t+6),_=o(e,t+8),x=o(e,t+10),S=o(e,t+12),k=o(e,t+14);let E=n[0]+(8191&y),T=n[1]+(8191&(y>>>13|v<<3)),B=n[2]+(8191&(v>>>10|b<<6)),C=n[3]+(8191&(b>>>7|w<<9)),I=n[4]+(8191&(w>>>4|_<<12)),A=n[5]+(_>>>1&8191),F=n[6]+(8191&(_>>>14|x<<2)),M=n[7]+(8191&(x>>>11|S<<5)),D=n[8]+(8191&(S>>>8|k<<8)),R=n[9]+(k>>>5|i),P=0,O=P+E*a+T*(5*g)+B*(5*m)+C*(5*f)+I*(5*h);P=O>>>13,O&=8191,O+=A*(5*p)+F*(5*u)+M*(5*c)+D*(5*d)+R*(5*l),P+=O>>>13,O&=8191;let z=P+E*l+T*a+B*(5*g)+C*(5*m)+I*(5*f);P=z>>>13,z&=8191,z+=A*(5*h)+F*(5*p)+M*(5*u)+D*(5*c)+R*(5*d),P+=z>>>13,z&=8191;let N=P+E*d+T*l+B*a+C*(5*g)+I*(5*m);P=N>>>13,N&=8191,N+=A*(5*f)+F*(5*h)+M*(5*p)+D*(5*u)+R*(5*c),P+=N>>>13,N&=8191;let q=P+E*c+T*d+B*l+C*a+I*(5*g);P=q>>>13,q&=8191,q+=A*(5*m)+F*(5*f)+M*(5*h)+D*(5*p)+R*(5*u),P+=q>>>13,q&=8191;let U=P+E*u+T*c+B*d+C*l+I*a;P=U>>>13,U&=8191,U+=A*(5*g)+F*(5*m)+M*(5*f)+D*(5*h)+R*(5*p),P+=U>>>13,U&=8191;let L=P+E*p+T*u+B*c+C*d+I*l;P=L>>>13,L&=8191,L+=A*a+F*(5*g)+M*(5*m)+D*(5*f)+R*(5*h),P+=L>>>13,L&=8191;let j=P+E*h+T*p+B*u+C*c+I*d;P=j>>>13,j&=8191,j+=A*l+F*a+M*(5*g)+D*(5*m)+R*(5*f),P+=j>>>13,j&=8191;let H=P+E*f+T*h+B*p+C*u+I*c;P=H>>>13,H&=8191,H+=A*d+F*l+M*a+D*(5*g)+R*(5*m),P+=H>>>13,H&=8191;let $=P+E*m+T*f+B*h+C*p+I*u;P=$>>>13,$&=8191,$+=A*c+F*d+M*l+D*a+R*(5*g),P+=$>>>13,$&=8191;let G=P+E*g+T*m+B*f+C*h+I*p;P=G>>>13,G&=8191,G+=A*u+F*c+M*d+D*l+R*a,P+=G>>>13,G&=8191,P=(P<<2)+P|0,P=P+O|0,O=8191&P,P>>>=13,z+=P,n[0]=O,n[1]=z,n[2]=N,n[3]=q,n[4]=U,n[5]=L,n[6]=j,n[7]=H,n[8]=$,n[9]=G}finalize(){const{h:e,pad:t}=this,r=new Uint16Array(10);let i=e[1]>>>13;e[1]&=8191;for(let t=2;t<10;t++)e[t]+=i,i=e[t]>>>13,e[t]&=8191;e[0]+=5*i,i=e[0]>>>13,e[0]&=8191,e[1]+=i,i=e[1]>>>13,e[1]&=8191,e[2]+=i,r[0]=e[0]+5,i=r[0]>>>13,r[0]&=8191;for(let t=1;t<10;t++)r[t]=e[t]+i,i=r[t]>>>13,r[t]&=8191;r[9]-=8192;let n=(1^i)-1;for(let e=0;e<10;e++)r[e]&=n;n=~n;for(let t=0;t<10;t++)e[t]=e[t]&n|r[t];e[0]=65535&(e[0]|e[1]<<13),e[1]=65535&(e[1]>>>3|e[2]<<10),e[2]=65535&(e[2]>>>6|e[3]<<7),e[3]=65535&(e[3]>>>9|e[4]<<4),e[4]=65535&(e[4]>>>12|e[5]<<1|e[6]<<14),e[5]=65535&(e[6]>>>2|e[7]<<11),e[6]=65535&(e[7]>>>5|e[8]<<8),e[7]=65535&(e[8]>>>8|e[9]<<5);let o=e[0]+t[0];e[0]=65535&o;for(let r=1;r<8;r++)o=(e[r]+t[r]|0)+(o>>>16)|0,e[r]=65535&o}update(e){(0,i.exists)(this);const{buffer:t,blockLen:r}=this,o=(e=(0,n.toBytes)(e)).length;for(let i=0;i>>0,e[o++]=r[t]>>>8;return e}digest(){const{buffer:e,outputLen:t}=this;this.digestInto(e);const r=e.slice(0,t);return this.destroy(),r}}function a(e){const t=(t,r)=>e(r).update((0,n.toBytes)(t)).digest(),r=e(new Uint8Array(32));return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t}t.wrapConstructorWithKey=a,t.poly1305=a((e=>new s(e)))},60022:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.polyval=t.ghash=t._toGHASHKey=void 0;const i=r(36527),n=r(24605),o=16,s=new Uint8Array(16),a=(0,i.u32)(s),l=e=>(e>>>0&255)<<24|(e>>>8&255)<<16|(e>>>16&255)<<8|e>>>24&255;function d(e){e.reverse();const t=1&e[15];let r=0;for(let t=0;t>>1|r,r=(1&i)<<7}return e[0]^=225&-t,e}t._toGHASHKey=d;class c{constructor(e,t){this.blockLen=o,this.outputLen=o,this.s0=0,this.s1=0,this.s2=0,this.s3=0,this.finished=!1,e=(0,i.toBytes)(e),(0,n.bytes)(e,16);const r=(0,i.createView)(e);let s=r.getUint32(0,!1),a=r.getUint32(4,!1),d=r.getUint32(8,!1),c=r.getUint32(12,!1);const u=[];for(let e=0;e<128;e++)u.push({s0:l(s),s1:l(a),s2:l(d),s3:l(c)}),({s0:s,s1:a,s2:d,s3:c}={s3:(f=d)<<31|(m=c)>>>1,s2:(h=a)<<31|f>>>1,s1:(p=s)<<31|h>>>1,s0:p>>>1^225<<24&-(1&m)});var p,h,f,m;const g=(y=t||1024)>65536?8:y>1024?4:2;var y;if(![1,2,4,8].includes(g))throw new Error(`ghash: wrong window size=${g}, should be 2, 4 or 8`);this.W=g;const v=128/g,b=this.windowSize=2**g,w=[];for(let e=0;e>>g-s-1&1))continue;const{s0:a,s1:l,s2:d,s3:c}=u[g*e+s];r^=a,i^=l,n^=d,o^=c}w.push({s0:r,s1:i,s2:n,s3:o})}this.t=w}_updateBlock(e,t,r,i){e^=this.s0,t^=this.s1,r^=this.s2,i^=this.s3;const{W:n,t:o,windowSize:s}=this;let a=0,l=0,d=0,c=0;const u=(1<>>8*e&255;for(let e=8/n-1;e>=0;e--){const r=t>>>n*e&u,{s0:i,s1:h,s2:f,s3:m}=o[p*s+r];a^=i,l^=h,d^=f,c^=m,p+=1}}this.s0=a,this.s1=l,this.s2=d,this.s3=c}update(e){e=(0,i.toBytes)(e),(0,n.exists)(this);const t=(0,i.u32)(e),r=Math.floor(e.length/o),l=e.length%o;for(let e=0;ee(r,t.length).update((0,i.toBytes)(t)).digest(),r=e(new Uint8Array(16),0);return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=(t,r)=>e(t,r),t}t.ghash=p(((e,t)=>new c(e,t))),t.polyval=p(((e,t)=>new u(e,t)))},80469:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.unsafe=t.siv=t.gcm=t.cfb=t.cbc=t.ecb=t.ctr=t.expandKeyDecLE=t.expandKeyLE=void 0;const i=r(36527),n=r(60022),o=r(24605),s=16,a=new Uint8Array(s);function l(e){return e<<1^283&-(e>>7)}function d(e,t){let r=0;for(;t>0;t>>=1)r^=e&-(1&t),e=l(e);return r}const c=(()=>{let e=new Uint8Array(256);for(let t=0,r=1;t<256;t++,r^=l(r))e[t]=r;const t=new Uint8Array(256);t[0]=99;for(let r=0;r<255;r++){let i=e[255-r];i|=i<<8,t[e[r]]=255&(i^i>>4^i>>5^i>>6^i>>7^99)}return t})(),u=c.map(((e,t)=>c.indexOf(t))),p=e=>e<<8|e>>>24;function h(e,t){if(256!==e.length)throw new Error("Wrong sbox length");const r=new Uint32Array(256).map(((r,i)=>t(e[i]))),i=r.map(p),n=i.map(p),o=n.map(p),s=new Uint32Array(65536),a=new Uint32Array(65536),l=new Uint16Array(65536);for(let t=0;t<256;t++)for(let d=0;d<256;d++){const c=256*t+d;s[c]=r[t]^i[d],a[c]=n[t]^o[d],l[c]=e[t]<<8|e[d]}return{sbox:e,sbox2:l,T0:r,T1:i,T2:n,T3:o,T01:s,T23:a}}const f=h(c,(e=>d(e,3)<<24|e<<16|e<<8|d(e,2))),m=h(u,(e=>d(e,11)<<24|d(e,13)<<16|d(e,9)<<8|d(e,14))),g=(()=>{const e=new Uint8Array(16);for(let t=0,r=1;t<16;t++,r=l(r))e[t]=r;return e})();function y(e){(0,o.bytes)(e);const t=e.length;if(![16,24,32].includes(t))throw new Error(`aes: wrong key size: should be 16, 24 or 32, got: ${t}`);const{sbox2:r}=f,n=(0,i.u32)(e),s=n.length,a=e=>w(r,e,e,e,e),l=new Uint32Array(t+28);l.set(n);for(let e=s;e>>8)^g[e/s-1]:s>6&&e%s==4&&(t=a(t)),l[e]=l[e-s]^t}var d;return l}function v(e){const t=y(e),r=t.slice(),i=t.length,{sbox2:n}=f,{T0:o,T1:s,T2:a,T3:l}=m;for(let e=0;e>>8&255]^a[i>>>16&255]^l[i>>>24]}return r}function b(e,t,r,i,n,o){return e[r<<8&65280|i>>>8&255]^t[n>>>8&65280|o>>>24&255]}function w(e,t,r,i,n){return e[255&t|65280&r]|e[i>>>16&255|n>>>16&65280]<<16}function _(e,t,r,i,n){const{sbox2:o,T01:s,T23:a}=f;let l=0;t^=e[l++],r^=e[l++],i^=e[l++],n^=e[l++];const d=e.length/4-2;for(let o=0;o=0;e--)r=r+(255&l[e])|0,l[e]=255&r,r>>>=8;({s0:c,s1:u,s2:p,s3:h}=_(e,d[0],d[1],d[2],d[3]))}const g=s*Math.floor(f.length/4);if(g>>0,c.setUint32(h,m,t),({s0:g,s1:y,s2:v,s3:b}=_(e,d[0],d[1],d[2],d[3]));const w=s*Math.floor(u.length/4);if(w16)throw new Error(`aes/pcks5: wrong padding byte: ${i}`);const n=e.subarray(0,-i);for(let t=0;tr(e,t),decrypt:(e,t)=>r(e,t)}})),t.ecb=(0,i.wrapCipher)({blockSize:16},(function(e,t={}){(0,o.bytes)(e);const r=!t.disablePadding;return{encrypt:(t,i)=>{(0,o.bytes)(t);const{b:n,o:s,out:a}=B(t,r,i),l=y(e);let d=0;for(;d+4<=n.length;){const{s0:e,s1:t,s2:r,s3:i}=_(l,n[d+0],n[d+1],n[d+2],n[d+3]);s[d++]=e,s[d++]=t,s[d++]=r,s[d++]=i}if(r){const e=I(t.subarray(4*d)),{s0:r,s1:i,s2:n,s3:o}=_(l,e[0],e[1],e[2],e[3]);s[d++]=r,s[d++]=i,s[d++]=n,s[d++]=o}return l.fill(0),a},decrypt:(t,n)=>{T(t);const o=v(e),s=S(t.length,n),a=(0,i.u32)(t),l=(0,i.u32)(s);for(let e=0;e+4<=a.length;){const{s0:t,s1:r,s2:i,s3:n}=x(o,a[e+0],a[e+1],a[e+2],a[e+3]);l[e++]=t,l[e++]=r,l[e++]=i,l[e++]=n}return o.fill(0),C(s,r)}}})),t.cbc=(0,i.wrapCipher)({blockSize:16,nonceLength:16},(function(e,t,r={}){(0,o.bytes)(e),(0,o.bytes)(t,16);const n=!r.disablePadding;return{encrypt:(r,o)=>{const s=y(e),{b:a,o:l,out:d}=B(r,n,o),c=(0,i.u32)(t);let u=c[0],p=c[1],h=c[2],f=c[3],m=0;for(;m+4<=a.length;)u^=a[m+0],p^=a[m+1],h^=a[m+2],f^=a[m+3],({s0:u,s1:p,s2:h,s3:f}=_(s,u,p,h,f)),l[m++]=u,l[m++]=p,l[m++]=h,l[m++]=f;if(n){const e=I(r.subarray(4*m));u^=e[0],p^=e[1],h^=e[2],f^=e[3],({s0:u,s1:p,s2:h,s3:f}=_(s,u,p,h,f)),l[m++]=u,l[m++]=p,l[m++]=h,l[m++]=f}return s.fill(0),d},decrypt:(r,o)=>{T(r);const s=v(e),a=(0,i.u32)(t),l=S(r.length,o),d=(0,i.u32)(r),c=(0,i.u32)(l);let u=a[0],p=a[1],h=a[2],f=a[3];for(let e=0;e+4<=d.length;){const t=u,r=p,i=h,n=f;u=d[e+0],p=d[e+1],h=d[e+2],f=d[e+3];const{s0:o,s1:a,s2:l,s3:m}=x(s,u,p,h,f);c[e++]=o^t,c[e++]=a^r,c[e++]=l^i,c[e++]=m^n}return s.fill(0),C(l,n)}}})),t.cfb=(0,i.wrapCipher)({blockSize:16,nonceLength:16},(function(e,t){function r(r,n,o){const a=y(e),l=r.length;o=S(l,o);const d=(0,i.u32)(r),c=(0,i.u32)(o),u=n?c:d,p=(0,i.u32)(t);let h=p[0],f=p[1],m=p[2],g=p[3];for(let e=0;e+4<=d.length;){const{s0:t,s1:r,s2:i,s3:n}=_(a,h,f,m,g);c[e+0]=d[e+0]^t,c[e+1]=d[e+1]^r,c[e+2]=d[e+2]^i,c[e+3]=d[e+3]^n,h=u[e++],f=u[e++],m=u[e++],g=u[e++]}const v=s*Math.floor(d.length/4);if(vr(e,!0,t),decrypt:(e,t)=>r(e,!1,t)}})),t.gcm=(0,i.wrapCipher)({blockSize:16,nonceLength:12,tagLength:16},(function(e,t,r){if((0,o.bytes)(t),0===t.length)throw new Error("aes/gcm: empty nonce");const s=16;function l(e,t,i){const o=A(n.ghash,!1,e,i,r);for(let e=0;e{(0,o.bytes)(e);const{xk:t,authKey:r,counter:i,tagMask:n}=d(),a=new Uint8Array(e.length+s);E(t,!1,i,e,a);const c=l(r,n,a.subarray(0,a.length-s));return a.set(c,e.length),t.fill(0),a},decrypt:e=>{if((0,o.bytes)(e),e.lengthi=>{if(!Number.isSafeInteger(i)||t>i||i>r)throw new Error(`${e}: invalid value=${i}, must be [${t}..${r}]`)};function M(e){return null!=e&&"object"==typeof e&&(e instanceof Uint32Array||"Uint32Array"===e.constructor.name)}t.siv=(0,i.wrapCipher)({blockSize:16,nonceLength:12,tagLength:16},(function(e,t,r){const s=F("AAD",0,2**36),a=F("plaintext",0,2**36),l=F("nonce",12,12),d=F("ciphertext",16,2**36+16);function c(){const r=e.length;if(16!==r&&24!==r&&32!==r)throw new Error(`key length must be 16, 24 or 32 bytes, got: ${r} bytes`);const n=y(e),o=new Uint8Array(r),s=new Uint8Array(16),a=(0,i.u32)(t);let l=0,d=a[0],c=a[1],u=a[2],p=0;for(const e of[s,o].map(i.u32)){const t=(0,i.u32)(e);for(let e=0;e{(0,o.bytes)(e),a(e.length);const{encKey:t,authKey:r}=c(),i=u(t,r,e),n=new Uint8Array(e.length+16);return n.set(i,e.length),n.set(p(t,i,e)),t.fill(0),r.fill(0),n},decrypt:e=>{(0,o.bytes)(e),d(e.length);const t=e.subarray(-16),{encKey:r,authKey:n}=c(),s=p(r,t,e.subarray(0,-16)),a=u(r,n,s);if(r.fill(0),n.fill(0),!(0,i.equalBytes)(t,a))throw new Error("invalid polyval tag");return s}}})),t.unsafe={expandKeyLE:y,expandKeyDecLE:v,encrypt:_,decrypt:x,encryptBlock:function(e,t){if((0,o.bytes)(t,16),!M(e))throw new Error("_encryptBlock accepts result of expandKeyLE");const r=(0,i.u32)(t);let{s0:n,s1:s,s2:a,s3:l}=_(e,r[0],r[1],r[2],r[3]);return r[0]=n,r[1]=s,r[2]=a,r[3]=l,t},decryptBlock:function(e,t){if((0,o.bytes)(t,16),!M(e))throw new Error("_decryptBlock accepts result of expandKeyLE");const r=(0,i.u32)(t);let{s0:n,s1:s,s2:a,s3:l}=x(e,r[0],r[1],r[2],r[3]);return r[0]=n,r[1]=s,r[2]=a,r[3]=l,t},ctrCounter:k,ctr32:E}},25297:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getWebcryptoSubtle=t.randomBytes=void 0;const r="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0;t.randomBytes=function(e=32){if(r&&"function"==typeof r.getRandomValues)return r.getRandomValues(new Uint8Array(e));throw new Error("crypto.getRandomValues must be defined")},t.getWebcryptoSubtle=function(){if(r&&"object"==typeof r.subtle&&null!=r.subtle)return r.subtle;throw new Error("crypto.subtle must be defined")}},71190:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.secretbox=t.xsalsa20poly1305=t.xsalsa20=t.salsa20=t.hsalsa=void 0;const i=r(24605),n=r(32506),o=r(8829),s=r(36527);function a(e,t,r,i,o,s=20){let a=e[0],l=t[0],d=t[1],c=t[2],u=t[3],p=e[1],h=r[0],f=r[1],m=o,g=e[2],y=t[4],v=t[5],b=t[6],w=t[7],_=e[3],x=a,S=l,k=d,E=c,T=u,B=p,C=h,I=f,A=m,F=0,M=g,D=y,R=v,P=b,O=w,z=_;for(let e=0;e{const n=16;return(0,i.bytes)(e,32),(0,i.bytes)(r,24),{encrypt:(s,a)=>{(0,i.bytes)(s);const l=s.length+32;a?(0,i.bytes)(a,l):a=new Uint8Array(l),a.set(s,32),(0,t.xsalsa20)(e,r,a,a);const d=a.subarray(0,32),c=(0,o.poly1305)(a.subarray(32),d);return a.set(c,n),a.subarray(0,n).fill(0),a.subarray(n)},decrypt:a=>{(0,i.bytes)(a);const l=a.length;if(l{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.u64Lengths=t.setBigUint64=t.wrapCipher=t.Hash=t.equalBytes=t.checkOpts=t.concatBytes=t.toBytes=t.bytesToUtf8=t.utf8ToBytes=t.asyncLoop=t.nextTick=t.numberToBytesBE=t.bytesToNumberBE=t.hexToNumber=t.hexToBytes=t.bytesToHex=t.isLE=t.createView=t.u32=t.u16=t.u8=void 0; +/*! noble-ciphers - MIT License (c) 2023 Paul Miller (paulmillr.com) */ +const i=r(24605);t.u8=e=>new Uint8Array(e.buffer,e.byteOffset,e.byteLength);t.u16=e=>new Uint16Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/2));t.u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4));if(t.createView=e=>new DataView(e.buffer,e.byteOffset,e.byteLength),t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!t.isLE)throw new Error("Non little-endian hardware is not supported");const n=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));function o(e){(0,i.bytes)(e);let t="";for(let r=0;r=s&&e<=a?e-s:e>=l&&e<=d?e-(l-10):e>=c&&e<=u?e-(c-10):void 0}function h(e){if("string"!=typeof e)throw new Error("hex string expected, got "+typeof e);const t=e.length,r=t/2;if(t%2)throw new Error("padded hex string expected, got unpadded hex of length "+t);const i=new Uint8Array(r);for(let t=0,n=0;t{},t.asyncLoop=async function(e,r,i){let n=Date.now();for(let o=0;o=0&&e>n&o),a=Number(r&o),l=i?4:0,d=i?0:4;e.setUint32(t+l,s,i),e.setUint32(t+d,a,i)}t.wrapCipher=(e,t)=>(Object.assign(t,e),t),t.setBigUint64=g,t.u64Lengths=function(e,r){const i=new Uint8Array(16),n=(0,t.createView)(i);return g(n,0,BigInt(r?r.length:0),!0),g(n,8,BigInt(e.length),!0),i}},68489:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.gcm=t.ctr=t.cbc=t.utils=t.managedNonce=t.getWebcryptoSubtle=t.randomBytes=void 0;const i=r(25297);Object.defineProperty(t,"randomBytes",{enumerable:!0,get:function(){return i.randomBytes}}),Object.defineProperty(t,"getWebcryptoSubtle",{enumerable:!0,get:function(){return i.getWebcryptoSubtle}});const n=r(36527),o=r(24605);t.managedNonce=function(e){return(0,o.number)(e.nonceLength),(t,...r)=>({encrypt:(o,...s)=>{const{nonceLength:a}=e,l=(0,i.randomBytes)(a),d=e(t,l,...r).encrypt(o,...s),c=(0,n.concatBytes)(l,d);return d.fill(0),c},decrypt:(i,...n)=>{const{nonceLength:o}=e,s=i.subarray(0,o),a=i.subarray(o);return e(t,s,...r).decrypt(a,...n)}})},t.utils={async encrypt(e,t,r,n){const o=(0,i.getWebcryptoSubtle)(),s=await o.importKey("raw",e,t,!0,["encrypt"]),a=await o.encrypt(r,s,n);return new Uint8Array(a)},async decrypt(e,t,r,n){const o=(0,i.getWebcryptoSubtle)(),s=await o.importKey("raw",e,t,!0,["decrypt"]),a=await o.decrypt(r,s,n);return new Uint8Array(a)}};const s="AES-CBC",a="AES-CTR",l="AES-GCM";function d(e){return(r,i,n)=>{(0,o.bytes)(r),(0,o.bytes)(i);const d={name:e,length:8*r.length},c=function(e,t,r){if(e===s)return{name:s,iv:t};if(e===a)return{name:a,counter:t,length:64};if(e===l)return r?{name:l,iv:t,additionalData:r}:{name:l,iv:t};throw new Error("unknown aes block mode")}(e,i,n);return{encrypt:e=>((0,o.bytes)(e),t.utils.encrypt(r,d,c,e)),decrypt:e=>((0,o.bytes)(e),t.utils.decrypt(r,d,c,e))}}}t.cbc=d(s),t.ctr=d(a),t.gcm=d(l)},67557:(e,t)=>{"use strict";function r(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`positive integer expected, not ${e}`)}function i(e){if("boolean"!=typeof e)throw new Error(`boolean expected, not ${e}`)}function n(e){return e instanceof Uint8Array||null!=e&&"object"==typeof e&&"Uint8Array"===e.constructor.name}function o(e,...t){if(!n(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error(`Uint8Array expected of length ${t}, not of length=${e.length}`)}function s(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");r(e.outputLen),r(e.blockLen)}function a(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function l(e,t){o(e);const r=t.outputLen;if(e.length{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HashMD=t.Maj=t.Chi=void 0;const i=r(67557),n=r(99175);t.Chi=(e,t,r)=>e&t^~e&r;t.Maj=(e,t,r)=>e&t^e&r^t&r;class o extends n.Hash{constructor(e,t,r,i){super(),this.blockLen=e,this.outputLen=t,this.padOffset=r,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(e),this.view=(0,n.createView)(this.buffer)}update(e){(0,i.exists)(this);const{view:t,buffer:r,blockLen:o}=this,s=(e=(0,n.toBytes)(e)).length;for(let i=0;io-a&&(this.process(r,0),a=0);for(let e=a;e>n&o),a=Number(r&o),l=i?4:0,d=i?0:4;e.setUint32(t+l,s,i),e.setUint32(t+d,a,i)}(r,o-8,BigInt(8*this.length),s),this.process(r,0);const l=(0,n.createView)(e),d=this.outputLen;if(d%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const c=d/4,u=this.get();if(c>u.length)throw new Error("_sha2: outputLen bigger than state");for(let e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.crypto=void 0,t.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0},39615:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hmac=t.HMAC=void 0;const i=r(67557),n=r(99175);class o extends n.Hash{constructor(e,t){super(),this.finished=!1,this.destroyed=!1,(0,i.hash)(e);const r=(0,n.toBytes)(t);if(this.iHash=e.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const o=this.blockLen,s=new Uint8Array(o);s.set(r.length>o?e.create().update(r).digest():r);for(let e=0;enew o(e,t).update(r).digest(),t.hmac.create=(e,t)=>new o(e,t)},18941:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pbkdf2=function(e,t,r,i){const{c:n,dkLen:l,DK:d,PRF:c,PRFSalt:u}=s(e,t,r,i);let p;const h=new Uint8Array(4),f=(0,o.createView)(h),m=new Uint8Array(c.outputLen);for(let e=1,t=0;t{u._cloneInto(h).update(g).digestInto(g);for(let e=0;e= 1");const u=(0,o.toBytes)(t),p=(0,o.toBytes)(r),h=new Uint8Array(d),f=n.hmac.create(e,u),m=f._cloneInto().update(p);return{c:l,dkLen:d,asyncTick:c,DK:h,PRF:f,PRFSalt:m}}function a(e,t,r,i,n){return e.destroy(),t.destroy(),i&&i.destroy(),n.fill(0),r}},25663:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.scrypt=function(e,t,r){const{N:i,r:n,p:o,dkLen:a,blockSize32:u,V:p,B32:h,B:f,tmp:m,blockMixCb:g}=d(e,t,r);s.isLE||(0,s.byteSwap32)(h);for(let e=0;e{l(p,r,p,r+=u,n),g()})),l(p,(i-1)*u,h,t,n),g(),await(0,s.asyncLoop)(i,y,(()=>{const e=h[t+u-16]%i;for(let r=0;r0&&(s+=16),a(r,o,e,t+=16,r,s)}function d(e,t,r){const a=(0,s.checkOpts)({dkLen:32,asyncTick:10,maxmem:1073742848},r),{N:l,r:d,p:c,dkLen:u,asyncTick:p,maxmem:h,onProgress:f}=a;if((0,i.number)(l),(0,i.number)(d),(0,i.number)(c),(0,i.number)(u),(0,i.number)(p),(0,i.number)(h),void 0!==f&&"function"!=typeof f)throw new Error("progressCb should be function");const m=128*d,g=m/4;if(l<=1||l&l-1||l>2**32)throw new Error("Scrypt: N must be larger than 1, a power of 2, and less than 2^32");if(c<0||c>137438953440/m)throw new Error("Scrypt: p must be a positive integer less than or equal to ((2^32 - 1) * 32) / (128 * r)");if(u<0||u>137438953440)throw new Error("Scrypt: dkLen should be positive integer less than or equal to (2^32 - 1) * 32");const y=m*(l+c);if(y>h)throw new Error(`Scrypt: parameters too large, ${y} (128 * r * (N + p)) > ${h} (maxmem)`);const v=(0,o.pbkdf2)(n.sha256,e,t,{c:1,dkLen:m*c}),b=(0,s.u32)(v),w=(0,s.u32)(new Uint8Array(m*l)),_=(0,s.u32)(new Uint8Array(m));let x=()=>{};if(f){const e=2*l*c,t=Math.max(Math.floor(e/1e4),1);let r=0;x=()=>{r++,!f||r%t&&r!==e||f(r/e)}}return{N:l,r:d,p:c,dkLen:u,blockSize32:g,V:w,B32:b,B:v,tmp:_,blockMixCb:x,asyncTick:p}}function c(e,t,r,i,s){const a=(0,o.pbkdf2)(n.sha256,e,r,{c:1,dkLen:t});return r.fill(0),i.fill(0),s.fill(0),a}},22623:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sha224=t.sha256=t.SHA256=void 0;const i=r(37202),n=r(99175),o=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),s=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),a=new Uint32Array(64);class l extends i.HashMD{constructor(){super(64,32,8,!1),this.A=0|s[0],this.B=0|s[1],this.C=0|s[2],this.D=0|s[3],this.E=0|s[4],this.F=0|s[5],this.G=0|s[6],this.H=0|s[7]}get(){const{A:e,B:t,C:r,D:i,E:n,F:o,G:s,H:a}=this;return[e,t,r,i,n,o,s,a]}set(e,t,r,i,n,o,s,a){this.A=0|e,this.B=0|t,this.C=0|r,this.D=0|i,this.E=0|n,this.F=0|o,this.G=0|s,this.H=0|a}process(e,t){for(let r=0;r<16;r++,t+=4)a[r]=e.getUint32(t,!1);for(let e=16;e<64;e++){const t=a[e-15],r=a[e-2],i=(0,n.rotr)(t,7)^(0,n.rotr)(t,18)^t>>>3,o=(0,n.rotr)(r,17)^(0,n.rotr)(r,19)^r>>>10;a[e]=o+a[e-7]+i+a[e-16]|0}let{A:r,B:s,C:l,D:d,E:c,F:u,G:p,H:h}=this;for(let e=0;e<64;e++){const t=h+((0,n.rotr)(c,6)^(0,n.rotr)(c,11)^(0,n.rotr)(c,25))+(0,i.Chi)(c,u,p)+o[e]+a[e]|0,f=((0,n.rotr)(r,2)^(0,n.rotr)(r,13)^(0,n.rotr)(r,22))+(0,i.Maj)(r,s,l)|0;h=p,p=u,u=c,c=d+t|0,d=l,l=s,s=r,r=t+f|0}r=r+this.A|0,s=s+this.B|0,l=l+this.C|0,d=d+this.D|0,c=c+this.E|0,u=u+this.F|0,p=p+this.G|0,h=h+this.H|0,this.set(r,s,l,d,c,u,p,h)}roundClean(){a.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}t.SHA256=l;class d extends l{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}t.sha256=(0,n.wrapConstructor)((()=>new l)),t.sha224=(0,n.wrapConstructor)((()=>new d))},99175:(e,t,r)=>{"use strict"; +/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */Object.defineProperty(t,"__esModule",{value:!0}),t.Hash=t.nextTick=t.byteSwapIfBE=t.byteSwap=t.isLE=t.rotl=t.rotr=t.createView=t.u32=t.u8=void 0,t.isBytes=function(e){return e instanceof Uint8Array||null!=e&&"object"==typeof e&&"Uint8Array"===e.constructor.name},t.byteSwap32=function(e){for(let r=0;r=0&&ee().update(d(t)).digest(),r=e();return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=()=>e(),t},t.wrapConstructorWithOpts=function(e){const t=(t,r)=>e(r).update(d(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t},t.wrapXOFConstructorWithOpts=function(e){const t=(t,r)=>e(r).update(d(t)).digest(),r=e({});return t.outputLen=r.outputLen,t.blockLen=r.blockLen,t.create=t=>e(t),t},t.randomBytes=function(e=32){if(i.crypto&&"function"==typeof i.crypto.getRandomValues)return i.crypto.getRandomValues(new Uint8Array(e));if(i.crypto&&"function"==typeof i.crypto.randomBytes)return i.crypto.randomBytes(e);throw new Error("crypto.getRandomValues must be defined")};const i=r(25145),n=r(67557);t.u8=e=>new Uint8Array(e.buffer,e.byteOffset,e.byteLength);t.u32=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4));t.createView=e=>new DataView(e.buffer,e.byteOffset,e.byteLength);t.rotr=(e,t)=>e<<32-t|e>>>t;t.rotl=(e,t)=>e<>>32-t>>>0,t.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];t.byteSwap=e=>e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255,t.byteSwapIfBE=t.isLE?e=>e:e=>(0,t.byteSwap)(e);const o=Array.from({length:256},((e,t)=>t.toString(16).padStart(2,"0")));const s={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function a(e){return e>=s._0&&e<=s._9?e-s._0:e>=s._A&&e<=s._F?e-(s._A-10):e>=s._a&&e<=s._f?e-(s._a-10):void 0}function l(e){if("string"!=typeof e)throw new Error("utf8ToBytes expected string, got "+typeof e);return new Uint8Array((new TextEncoder).encode(e))}function d(e){return"string"==typeof e&&(e=l(e)),(0,n.bytes)(e),e}t.nextTick=async()=>{};t.Hash=class{clone(){return this._cloneInto()}};const c={}.toString},87568:(e,t,r)=>{var i=t;i.bignum=r(72344),i.define=r(47363).define,i.base=r(9673),i.constants=r(22153),i.decoders=r(22853),i.encoders=r(24669)},47363:(e,t,r)=>{var i=r(87568),n=r(56698);function o(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new o(e,t)},o.prototype._createNamed=function(e){var t;try{t=r(18950).runInThisContext("(function "+this.name+"(entity) {\n this._initNamed(entity);\n})")}catch(e){t=function(e){this._initNamed(e)}}return n(t,e),t.prototype._initNamed=function(t){e.call(this,t)},new t(this)},o.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(i.decoders[e])),this.decoders[e]},o.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},o.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(i.encoders[e])),this.encoders[e]},o.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},47227:(e,t,r)=>{var i=r(56698),n=r(9673).Reporter,o=r(48287).Buffer;function s(e,t){n.call(this,t),o.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function a(e,t){if(Array.isArray(e))this.length=0,this.value=e.map((function(e){return e instanceof a||(e=new a(e,t)),this.length+=e.length,e}),this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=o.byteLength(e);else{if(!o.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}i(s,n),t.t=s,s.prototype.save=function(){return{offset:this.offset,reporter:n.prototype.save.call(this)}},s.prototype.restore=function(e){var t=new s(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,n.prototype.restore.call(this,e.reporter),t},s.prototype.isEmpty=function(){return this.offset===this.length},s.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},s.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var r=new s(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},s.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.d=a,a.prototype.join=function(e,t){return e||(e=new o(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach((function(r){r.join(e,t),t+=r.length})):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):o.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},9673:(e,t,r)=>{var i=t;i.Reporter=r(89220).a,i.DecoderBuffer=r(47227).t,i.EncoderBuffer=r(47227).d,i.Node=r(90993)},90993:(e,t,r)=>{var i=r(9673).Reporter,n=r(9673).EncoderBuffer,o=r(9673).DecoderBuffer,s=r(43349),a=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],l=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(a);function d(e,t){var r={};this._baseState=r,r.enc=e,r.parent=t||null,r.children=null,r.tag=null,r.args=null,r.reverseArgs=null,r.choice=null,r.optional=!1,r.any=!1,r.obj=!1,r.use=null,r.useDecoder=null,r.key=null,r.default=null,r.explicit=null,r.implicit=null,r.contains=null,r.parent||(r.children=[],this._wrap())}e.exports=d;var c=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];d.prototype.clone=function(){var e=this._baseState,t={};c.forEach((function(r){t[r]=e[r]}));var r=new this.constructor(t.parent);return r._baseState=t,r},d.prototype._wrap=function(){var e=this._baseState;l.forEach((function(t){this[t]=function(){var r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}}),this)},d.prototype._init=function(e){var t=this._baseState;s(null===t.parent),e.call(this),t.children=t.children.filter((function(e){return e._baseState.parent===this}),this),s.equal(t.children.length,1,"Root node can have only one child")},d.prototype._useArgs=function(e){var t=this._baseState,r=e.filter((function(e){return e instanceof this.constructor}),this);e=e.filter((function(e){return!(e instanceof this.constructor)}),this),0!==r.length&&(s(null===t.children),t.children=r,r.forEach((function(e){e._baseState.parent=this}),this)),0!==e.length&&(s(null===t.args),t.args=e,t.reverseArgs=e.map((function(e){if("object"!=typeof e||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach((function(r){r==(0|r)&&(r|=0);var i=e[r];t[i]=r})),t})))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach((function(e){d.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}})),a.forEach((function(e){d.prototype[e]=function(){var t=this._baseState,r=Array.prototype.slice.call(arguments);return s(null===t.tag),t.tag=e,this._useArgs(r),this}})),d.prototype.use=function(e){s(e);var t=this._baseState;return s(null===t.use),t.use=e,this},d.prototype.optional=function(){return this._baseState.optional=!0,this},d.prototype.def=function(e){var t=this._baseState;return s(null===t.default),t.default=e,t.optional=!0,this},d.prototype.explicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.explicit=e,this},d.prototype.implicit=function(e){var t=this._baseState;return s(null===t.explicit&&null===t.implicit),t.implicit=e,this},d.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},d.prototype.key=function(e){var t=this._baseState;return s(null===t.key),t.key=e,this},d.prototype.any=function(){return this._baseState.any=!0,this},d.prototype.choice=function(e){var t=this._baseState;return s(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map((function(t){return e[t]}))),this},d.prototype.contains=function(e){var t=this._baseState;return s(null===t.use),t.contains=e,this},d.prototype._decode=function(e,t){var r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));var i,n=r.default,s=!0,a=null;if(null!==r.key&&(a=e.enterKey(r.key)),r.optional){var l=null;if(null!==r.explicit?l=r.explicit:null!==r.implicit?l=r.implicit:null!==r.tag&&(l=r.tag),null!==l||r.any){if(s=this._peekTag(e,l,r.any),e.isError(s))return s}else{var d=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),s=!0}catch(e){s=!1}e.restore(d)}}if(r.obj&&s&&(i=e.enterObject()),s){if(null!==r.explicit){var c=this._decodeTag(e,r.explicit);if(e.isError(c))return c;e=c}var u=e.offset;if(null===r.use&&null===r.choice){if(r.any)d=e.save();var p=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(p))return p;r.any?n=e.raw(d):e=p}if(t&&t.track&&null!==r.tag&&t.track(e.path(),u,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),r.any||(n=null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t)),e.isError(n))return n;if(r.any||null!==r.choice||null===r.children||r.children.forEach((function(r){r._decode(e,t)})),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){var h=new o(n);n=this._getUse(r.contains,e._reporterState.obj)._decode(h,t)}}return r.obj&&s&&(n=e.leaveObject(i)),null===r.key||null===n&&!0!==s?null!==a&&e.exitKey(a):e.leaveKey(a,r.key,n),n},d.prototype._decodeGeneric=function(e,t,r){var i=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,i.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&i.args?this._decodeObjid(t,i.args[0],i.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,i.args&&i.args[0],r):null!==i.use?this._getUse(i.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},d.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),s(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},d.prototype._decodeChoice=function(e,t){var r=this._baseState,i=null,n=!1;return Object.keys(r.choice).some((function(o){var s=e.save(),a=r.choice[o];try{var l=a._decode(e,t);if(e.isError(l))return!1;i={type:o,value:l},n=!0}catch(t){return e.restore(s),!1}return!0}),this),n?i:e.error("Choice not matched")},d.prototype._createEncoderBuffer=function(e){return new n(e,this.reporter)},d.prototype._encode=function(e,t,r){var i=this._baseState;if(null===i.default||i.default!==e){var n=this._encodeValue(e,t,r);if(void 0!==n&&!this._skipDefault(n,t,r))return n}},d.prototype._encodeValue=function(e,t,r){var n=this._baseState;if(null===n.parent)return n.children[0]._encode(e,t||new i);var o=null;if(this.reporter=t,n.optional&&void 0===e){if(null===n.default)return;e=n.default}var s=null,a=!1;if(n.any)o=this._createEncoderBuffer(e);else if(n.choice)o=this._encodeChoice(e,t);else if(n.contains)s=this._getUse(n.contains,r)._encode(e,t),a=!0;else if(n.children)s=n.children.map((function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");var i=t.enterKey(r._baseState.key);if("object"!=typeof e)return t.error("Child expected, but input is not object");var n=r._encode(e[r._baseState.key],t,e);return t.leaveKey(i),n}),this).filter((function(e){return e})),s=this._createEncoderBuffer(s);else if("seqof"===n.tag||"setof"===n.tag){if(!n.args||1!==n.args.length)return t.error("Too many args for : "+n.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var l=this.clone();l._baseState.implicit=null,s=this._createEncoderBuffer(e.map((function(r){var i=this._baseState;return this._getUse(i.args[0],e)._encode(r,t)}),l))}else null!==n.use?o=this._getUse(n.use,r)._encode(e,t):(s=this._encodePrimitive(n.tag,e),a=!0);if(!n.any&&null===n.choice){var d=null!==n.implicit?n.implicit:n.tag,c=null===n.implicit?"universal":"context";null===d?null===n.use&&t.error("Tag could be omitted only for .use()"):null===n.use&&(o=this._encodeComposite(d,a,c,s))}return null!==n.explicit&&(o=this._encodeComposite(n.explicit,!1,"context",o)),o},d.prototype._encodeChoice=function(e,t){var r=this._baseState,i=r.choice[e.type];return i||s(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),i._encode(e.value,t)},d.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},d.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},d.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(e)}},89220:(e,t,r)=>{var i=r(56698);function n(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.a=n,n.prototype.isError=function(e){return e instanceof o},n.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},n.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},n.prototype.enterKey=function(e){return this._reporterState.path.push(e)},n.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},n.prototype.leaveKey=function(e,t,r){var i=this._reporterState;this.exitKey(e),null!==i.obj&&(i.obj[t]=r)},n.prototype.path=function(){return this._reporterState.path.join("/")},n.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},n.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},n.prototype.error=function(e){var t,r=this._reporterState,i=e instanceof o;if(t=i?e:new o(r.path.map((function(e){return"["+JSON.stringify(e)+"]"})).join(""),e.message||e,e.stack),!r.options.partial)throw t;return i||r.errors.push(t),t},n.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},i(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},74598:(e,t,r)=>{var i=r(22153);t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=i._reverse(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=i._reverse(t.tag)},22153:(e,t,r)=>{var i=t;i._reverse=function(e){var t={};return Object.keys(e).forEach((function(r){(0|r)==r&&(r|=0);var i=e[r];t[i]=r})),t},i.der=r(74598)},62010:(e,t,r)=>{var i=r(56698),n=r(87568),o=n.base,s=n.bignum,a=n.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new d,this.tree._init(e.body)}function d(e){o.Node.call(this,"der",e)}function c(e,t){var r=e.readUInt8(t);if(e.isError(r))return r;var i=a.tagClass[r>>6],n=!(32&r);if(31&~r)r&=31;else{var o=r;for(r=0;!(128&~o);){if(o=e.readUInt8(t),e.isError(o))return o;r<<=7,r|=127&o}}return{cls:i,primitive:n,tag:r,tagStr:a.tag[r]}}function u(e,t,r){var i=e.readUInt8(r);if(e.isError(i))return i;if(!t&&128===i)return null;if(!(128&i))return i;var n=127&i;if(n>4)return e.error("length octect is too long");i=0;for(var o=0;o{var i=t;i.der=r(62010),i.pem=r(58903)},58903:(e,t,r)=>{var i=r(56698),n=r(48287).Buffer,o=r(62010);function s(e){o.call(this,e),this.enc="pem"}i(s,o),e.exports=s,s.prototype.decode=function(e,t){for(var r=e.toString().split(/[\r\n]+/g),i=t.label.toUpperCase(),s=/^-----(BEGIN|END) ([^-]+)-----$/,a=-1,l=-1,d=0;d{var i=r(56698),n=r(48287).Buffer,o=r(87568),s=o.base,a=o.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new d,this.tree._init(e.body)}function d(e){s.Node.call(this,"der",e)}function c(e){return e<10?"0"+e:e}e.exports=l,l.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},i(d,s.Node),d.prototype._encodeComposite=function(e,t,r,i){var o,s=function(e,t,r,i){var n;"seqof"===e?e="seq":"setof"===e&&(e="set");if(a.tagByName.hasOwnProperty(e))n=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return i.error("Unknown tag: "+e);n=e}if(n>=31)return i.error("Multi-octet tag encoding unsupported");t||(n|=32);return n|=a.tagClassByName[r||"universal"]<<6,n}(e,t,r,this.reporter);if(i.length<128)return(o=new n(2))[0]=s,o[1]=i.length,this._createEncoderBuffer([o,i]);for(var l=1,d=i.length;d>=256;d>>=8)l++;(o=new n(2+l))[0]=s,o[1]=128|l;d=1+l;for(var c=i.length;c>0;d--,c>>=8)o[d]=255&c;return this._createEncoderBuffer([o,i])},d.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=new n(2*e.length),i=0;i=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}var o=0;for(i=0;i=128;s>>=7)o++}var a=new n(o),l=a.length-1;for(i=e.length-1;i>=0;i--){s=e[i];for(a[l--]=127&s;(s>>=7)>0;)a[l--]=128|127&s}return this._createEncoderBuffer(a)},d.prototype._encodeTime=function(e,t){var r,i=new Date(e);return"gentime"===t?r=[c(i.getFullYear()),c(i.getUTCMonth()+1),c(i.getUTCDate()),c(i.getUTCHours()),c(i.getUTCMinutes()),c(i.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[c(i.getFullYear()%100),c(i.getUTCMonth()+1),c(i.getUTCDate()),c(i.getUTCHours()),c(i.getUTCMinutes()),c(i.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},d.prototype._encodeNull=function(){return this._createEncoderBuffer("")},d.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!n.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=new n(r)}if(n.isBuffer(e)){var i=e.length;0===e.length&&i++;var o=new n(i);return e.copy(o),0===e.length&&(o[0]=0),this._createEncoderBuffer(o)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);i=1;for(var s=e;s>=256;s>>=8)i++;for(s=(o=new Array(i)).length-1;s>=0;s--)o[s]=255&e,e>>=8;return 128&o[0]&&o.unshift(0),this._createEncoderBuffer(new n(o))},d.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},d.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},d.prototype._skipDefault=function(e,t,r){var i,n=this._baseState;if(null===n.default)return!1;var o=e.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,t,r).join()),o.length!==n.defaultBuffer.length)return!1;for(i=0;i{var i=t;i.der=r(70082),i.pem=r(90735)},90735:(e,t,r)=>{var i=r(56698),n=r(70082);function o(e){n.call(this,e),this.enc="pem"}i(o,n),e.exports=o,o.prototype.encode=function(e,t){for(var r=n.prototype.encode.call(this,e).toString("base64"),i=["-----BEGIN "+t.label+"-----"],o=0;o=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},67526:(e,t)=>{"use strict";t.byteLength=function(e){var t=a(e),r=t[0],i=t[1];return 3*(r+i)/4-i},t.toByteArray=function(e){var t,r,o=a(e),s=o[0],l=o[1],d=new n(function(e,t,r){return 3*(t+r)/4-r}(0,s,l)),c=0,u=l>0?s-4:s;for(r=0;r>16&255,d[c++]=t>>8&255,d[c++]=255&t;2===l&&(t=i[e.charCodeAt(r)]<<2|i[e.charCodeAt(r+1)]>>4,d[c++]=255&t);1===l&&(t=i[e.charCodeAt(r)]<<10|i[e.charCodeAt(r+1)]<<4|i[e.charCodeAt(r+2)]>>2,d[c++]=t>>8&255,d[c++]=255&t);return d},t.fromByteArray=function(e){for(var t,i=e.length,n=i%3,o=[],s=16383,a=0,d=i-n;ad?d:a+s));1===n?(t=e[i-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===n&&(t=(e[i-2]<<8)+e[i-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return o.join("")};for(var r=[],i=[],n="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0;s<64;++s)r[s]=o[s],i[o.charCodeAt(s)]=s;function a(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function l(e,t,i){for(var n,o,s=[],a=t;a>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return s.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},39404:function(e,t,r){!function(e,t){"use strict";function i(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var s;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(47790).Buffer}catch(e){}function a(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void i(!1,"Invalid character in "+e)}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,n){for(var o=0,s=0,a=Math.min(e.length,r),l=t;l=49?d-49+10:d>=17?d-17+10:d,i(d>=0&&s0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=u}catch(e){o.prototype.inspect=u}else o.prototype.inspect=u;function u(){return(this.red?""}var p=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],h=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],f=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215,(n+=2)>=26&&(n-=26,s--),r=0!==o||s!==this.length-1?p[6-l.length]+l+r:l+r}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=h[e],c=f[e];r="";var u=this.clone();for(u.negative=0;!u.isZero();){var m=u.modrn(c).toString(e);r=(u=u.idivn(c)).isZero()?m+r:p[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},s&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(s,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function m(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r._strip()}o.prototype.toArrayLike=function(e,t,r){this._strip();var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0");var s=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](s,n),s},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,i=0,n=0,o=0;n>8&255),r>16&255),6===o?(r>24&255),i=0,o=0):(i=s>>>24,o+=2)}if(r=0&&(e[r--]=s>>8&255),r>=0&&(e[r--]=s>>16&255),6===o?(r>=0&&(e[r--]=s>>24&255),i=0,o=0):(i=s>>>24,o+=2)}if(r>=0)for(e[r--]=i;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function y(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r._strip()}function v(e,t,r){return y(e,t,r)}function b(e,t){this.x=e,this.y=t}Math.imul||(g=m),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?g(this,e,t):r<63?m(this,e,t):r<1024?y(this,e,t):v(this,e,t)},b.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},b.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,r+=o/67108864|0,r+=s>>>26,this.words[n]=67108863&s}return 0!==r&&(this.words[n]=r,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this._strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a._strip(),i._strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=(1<<26)%e,n=0,o=this.length-1;o>=0;o--)n=(r*n+(0|this.words[o]))%e;return t?-n:n},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),i(e<=67108863);for(var r=0,n=this.length-1;n>=0;n--){var o=(0|this.words[n])+67108864*r;this.words[n]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new T(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var w={k256:null,p224:null,p192:null,p25519:null};function _(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){_.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function S(){_.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function k(){_.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function E(){_.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function T(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function B(e){T.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}_.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},_.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},_.prototype.split=function(e,t){e.iushrn(this.n,0,t)},_.prototype.imulK=function(e){return e.imul(this.k)},n(x,_),x.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(w[e])return w[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new S;else if("p192"===e)t=new k;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new E}return w[e]=t,t},T.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},T.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},T.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(c(e,e.umod(this.m)._forceRed(this)),e)},T.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},T.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},T.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},T.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},T.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},T.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},T.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},T.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},T.prototype.isqr=function(e){return this.imul(e,e.clone())},T.prototype.sqr=function(e){return this.mul(e,e)},T.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},T.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},T.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new B(e)},n(B,T),B.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},B.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},B.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},B.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},B.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},46880:function(e){e.exports=function(e){var t={};function r(i){if(t[i])return t[i].exports;var n=t[i]={i,l:!1,exports:{}};return e[i].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.d=function(e,t,i){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(i,n,function(t){return e[t]}.bind(null,n));return i},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=90)}({17:function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var i=r(18),n=function(){function e(){}return e.getFirstMatch=function(e,t){var r=t.match(e);return r&&r.length>0&&r[1]||""},e.getSecondMatch=function(e,t){var r=t.match(e);return r&&r.length>1&&r[2]||""},e.matchAndReturnConst=function(e,t,r){if(e.test(t))return r},e.getWindowsVersionName=function(e){switch(e){case"NT":return"NT";case"XP":case"NT 5.1":return"XP";case"NT 5.0":return"2000";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}},e.getMacOSVersionName=function(e){var t=e.split(".").splice(0,2).map((function(e){return parseInt(e,10)||0}));if(t.push(0),10===t[0])switch(t[1]){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}},e.getAndroidVersionName=function(e){var t=e.split(".").splice(0,2).map((function(e){return parseInt(e,10)||0}));if(t.push(0),!(1===t[0]&&t[1]<5))return 1===t[0]&&t[1]<6?"Cupcake":1===t[0]&&t[1]>=6?"Donut":2===t[0]&&t[1]<2?"Eclair":2===t[0]&&2===t[1]?"Froyo":2===t[0]&&t[1]>2?"Gingerbread":3===t[0]?"Honeycomb":4===t[0]&&t[1]<1?"Ice Cream Sandwich":4===t[0]&&t[1]<4?"Jelly Bean":4===t[0]&&t[1]>=4?"KitKat":5===t[0]?"Lollipop":6===t[0]?"Marshmallow":7===t[0]?"Nougat":8===t[0]?"Oreo":9===t[0]?"Pie":void 0},e.getVersionPrecision=function(e){return e.split(".").length},e.compareVersions=function(t,r,i){void 0===i&&(i=!1);var n=e.getVersionPrecision(t),o=e.getVersionPrecision(r),s=Math.max(n,o),a=0,l=e.map([t,r],(function(t){var r=s-e.getVersionPrecision(t),i=t+new Array(r+1).join(".0");return e.map(i.split("."),(function(e){return new Array(20-e.length).join("0")+e})).reverse()}));for(i&&(a=s-Math.min(n,o)),s-=1;s>=a;){if(l[0][s]>l[1][s])return 1;if(l[0][s]===l[1][s]){if(s===a)return 0;s-=1}else if(l[0][s]1?n-1:0),s=1;s0){var s=Object.keys(r),l=a.default.find(s,(function(e){return t.isOS(e)}));if(l){var d=this.satisfies(r[l]);if(void 0!==d)return d}var c=a.default.find(s,(function(e){return t.isPlatform(e)}));if(c){var u=this.satisfies(r[c]);if(void 0!==u)return u}}if(o>0){var p=Object.keys(n),h=a.default.find(p,(function(e){return t.isBrowser(e,!0)}));if(void 0!==h)return this.compareVersion(n[h])}},t.isBrowser=function(e,t){void 0===t&&(t=!1);var r=this.getBrowserName().toLowerCase(),i=e.toLowerCase(),n=a.default.getBrowserTypeByAlias(i);return t&&n&&(i=n.toLowerCase()),i===r},t.compareVersion=function(e){var t=[0],r=e,i=!1,n=this.getBrowserVersion();if("string"==typeof n)return">"===e[0]||"<"===e[0]?(r=e.substr(1),"="===e[1]?(i=!0,r=e.substr(2)):t=[],">"===e[0]?t.push(1):t.push(-1)):"="===e[0]?r=e.substr(1):"~"===e[0]&&(i=!0,r=e.substr(1)),t.indexOf(a.default.compareVersions(n,r,i))>-1},t.isOS=function(e){return this.getOSName(!0)===String(e).toLowerCase()},t.isPlatform=function(e){return this.getPlatformType(!0)===String(e).toLowerCase()},t.isEngine=function(e){return this.getEngineName(!0)===String(e).toLowerCase()},t.is=function(e,t){return void 0===t&&(t=!1),this.isBrowser(e,t)||this.isOS(e)||this.isPlatform(e)},t.some=function(e){var t=this;return void 0===e&&(e=[]),e.some((function(e){return t.is(e)}))},e}();t.default=d,e.exports=t.default},92:function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var i,n=(i=r(17))&&i.__esModule?i:{default:i},o=/version\/(\d+(\.?_?\d+)+)/i,s=[{test:[/googlebot/i],describe:function(e){var t={name:"Googlebot"},r=n.default.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/opera/i],describe:function(e){var t={name:"Opera"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/opr\/|opios/i],describe:function(e){var t={name:"Opera"},r=n.default.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/SamsungBrowser/i],describe:function(e){var t={name:"Samsung Internet for Android"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/Whale/i],describe:function(e){var t={name:"NAVER Whale Browser"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/MZBrowser/i],describe:function(e){var t={name:"MZ Browser"},r=n.default.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/focus/i],describe:function(e){var t={name:"Focus"},r=n.default.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/swing/i],describe:function(e){var t={name:"Swing"},r=n.default.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/coast/i],describe:function(e){var t={name:"Opera Coast"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe:function(e){var t={name:"Opera Touch"},r=n.default.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/yabrowser/i],describe:function(e){var t={name:"Yandex Browser"},r=n.default.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/ucbrowser/i],describe:function(e){var t={name:"UC Browser"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/Maxthon|mxios/i],describe:function(e){var t={name:"Maxthon"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/epiphany/i],describe:function(e){var t={name:"Epiphany"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/puffin/i],describe:function(e){var t={name:"Puffin"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/sleipnir/i],describe:function(e){var t={name:"Sleipnir"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/k-meleon/i],describe:function(e){var t={name:"K-Meleon"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/micromessenger/i],describe:function(e){var t={name:"WeChat"},r=n.default.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/qqbrowser/i],describe:function(e){var t={name:/qqbrowserlite/i.test(e)?"QQ Browser Lite":"QQ Browser"},r=n.default.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/msie|trident/i],describe:function(e){var t={name:"Internet Explorer"},r=n.default.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/\sedg\//i],describe:function(e){var t={name:"Microsoft Edge"},r=n.default.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/edg([ea]|ios)/i],describe:function(e){var t={name:"Microsoft Edge"},r=n.default.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/vivaldi/i],describe:function(e){var t={name:"Vivaldi"},r=n.default.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/seamonkey/i],describe:function(e){var t={name:"SeaMonkey"},r=n.default.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/sailfish/i],describe:function(e){var t={name:"Sailfish"},r=n.default.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,e);return r&&(t.version=r),t}},{test:[/silk/i],describe:function(e){var t={name:"Amazon Silk"},r=n.default.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/phantom/i],describe:function(e){var t={name:"PhantomJS"},r=n.default.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/slimerjs/i],describe:function(e){var t={name:"SlimerJS"},r=n.default.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(e){var t={name:"BlackBerry"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/(web|hpw)[o0]s/i],describe:function(e){var t={name:"WebOS Browser"},r=n.default.getFirstMatch(o,e)||n.default.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/bada/i],describe:function(e){var t={name:"Bada"},r=n.default.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/tizen/i],describe:function(e){var t={name:"Tizen"},r=n.default.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/qupzilla/i],describe:function(e){var t={name:"QupZilla"},r=n.default.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/firefox|iceweasel|fxios/i],describe:function(e){var t={name:"Firefox"},r=n.default.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/electron/i],describe:function(e){var t={name:"Electron"},r=n.default.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/MiuiBrowser/i],describe:function(e){var t={name:"Miui"},r=n.default.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/chromium/i],describe:function(e){var t={name:"Chromium"},r=n.default.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/chrome|crios|crmo/i],describe:function(e){var t={name:"Chrome"},r=n.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/GSA/i],describe:function(e){var t={name:"Google Search"},r=n.default.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:function(e){var t=!e.test(/like android/i),r=e.test(/android/i);return t&&r},describe:function(e){var t={name:"Android Browser"},r=n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/playstation 4/i],describe:function(e){var t={name:"PlayStation 4"},r=n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/safari|applewebkit/i],describe:function(e){var t={name:"Safari"},r=n.default.getFirstMatch(o,e);return r&&(t.version=r),t}},{test:[/.*/i],describe:function(e){var t=-1!==e.search("\\(")?/^(.*)\/(.*)[ \t]\((.*)/:/^(.*)\/(.*) /;return{name:n.default.getFirstMatch(t,e),version:n.default.getSecondMatch(t,e)}}}];t.default=s,e.exports=t.default},93:function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var i,n=(i=r(17))&&i.__esModule?i:{default:i},o=r(18),s=[{test:[/Roku\/DVP/],describe:function(e){var t=n.default.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,e);return{name:o.OS_MAP.Roku,version:t}}},{test:[/windows phone/i],describe:function(e){var t=n.default.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,e);return{name:o.OS_MAP.WindowsPhone,version:t}}},{test:[/windows /i],describe:function(e){var t=n.default.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,e),r=n.default.getWindowsVersionName(t);return{name:o.OS_MAP.Windows,version:t,versionName:r}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(e){var t={name:o.OS_MAP.iOS},r=n.default.getSecondMatch(/(Version\/)(\d[\d.]+)/,e);return r&&(t.version=r),t}},{test:[/macintosh/i],describe:function(e){var t=n.default.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,e).replace(/[_\s]/g,"."),r=n.default.getMacOSVersionName(t),i={name:o.OS_MAP.MacOS,version:t};return r&&(i.versionName=r),i}},{test:[/(ipod|iphone|ipad)/i],describe:function(e){var t=n.default.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,e).replace(/[_\s]/g,".");return{name:o.OS_MAP.iOS,version:t}}},{test:function(e){var t=!e.test(/like android/i),r=e.test(/android/i);return t&&r},describe:function(e){var t=n.default.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,e),r=n.default.getAndroidVersionName(t),i={name:o.OS_MAP.Android,version:t};return r&&(i.versionName=r),i}},{test:[/(web|hpw)[o0]s/i],describe:function(e){var t=n.default.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,e),r={name:o.OS_MAP.WebOS};return t&&t.length&&(r.version=t),r}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(e){var t=n.default.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,e)||n.default.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,e)||n.default.getFirstMatch(/\bbb(\d+)/i,e);return{name:o.OS_MAP.BlackBerry,version:t}}},{test:[/bada/i],describe:function(e){var t=n.default.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,e);return{name:o.OS_MAP.Bada,version:t}}},{test:[/tizen/i],describe:function(e){var t=n.default.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,e);return{name:o.OS_MAP.Tizen,version:t}}},{test:[/linux/i],describe:function(){return{name:o.OS_MAP.Linux}}},{test:[/CrOS/],describe:function(){return{name:o.OS_MAP.ChromeOS}}},{test:[/PlayStation 4/],describe:function(e){var t=n.default.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,e);return{name:o.OS_MAP.PlayStation4,version:t}}}];t.default=s,e.exports=t.default},94:function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var i,n=(i=r(17))&&i.__esModule?i:{default:i},o=r(18),s=[{test:[/googlebot/i],describe:function(){return{type:"bot",vendor:"Google"}}},{test:[/huawei/i],describe:function(e){var t=n.default.getFirstMatch(/(can-l01)/i,e)&&"Nova",r={type:o.PLATFORMS_MAP.mobile,vendor:"Huawei"};return t&&(r.model=t),r}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(e){var t=e.test(/ipod|iphone/i),r=e.test(/like (ipod|iphone)/i);return t&&!r},describe:function(e){var t=n.default.getFirstMatch(/(ipod|iphone)/i,e);return{type:o.PLATFORMS_MAP.mobile,vendor:"Apple",model:t}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Nexus"}}},{test:[/[^-]mobi/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(e){return"blackberry"===e.getBrowserName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"BlackBerry"}}},{test:function(e){return"bada"===e.getBrowserName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(e){return"windows phone"===e.getBrowserName()},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Microsoft"}}},{test:function(e){var t=Number(String(e.getOSVersion()).split(".")[0]);return"android"===e.getOSName(!0)&&t>=3},describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(e){return"android"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(e){return"macos"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop,vendor:"Apple"}}},{test:function(e){return"windows"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(e){return"linux"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(e){return"playstation 4"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.tv}}},{test:function(e){return"roku"===e.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.tv}}}];t.default=s,e.exports=t.default},95:function(e,t,r){"use strict";t.__esModule=!0,t.default=void 0;var i,n=(i=r(17))&&i.__esModule?i:{default:i},o=r(18),s=[{test:function(e){return"microsoft edge"===e.getBrowserName(!0)},describe:function(e){if(/\sedg\//i.test(e))return{name:o.ENGINE_MAP.Blink};var t=n.default.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,e);return{name:o.ENGINE_MAP.EdgeHTML,version:t}}},{test:[/trident/i],describe:function(e){var t={name:o.ENGINE_MAP.Trident},r=n.default.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:function(e){return e.test(/presto/i)},describe:function(e){var t={name:o.ENGINE_MAP.Presto},r=n.default.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:function(e){var t=e.test(/gecko/i),r=e.test(/like gecko/i);return t&&!r},describe:function(e){var t={name:o.ENGINE_MAP.Gecko},r=n.default.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}},{test:[/(apple)?webkit\/537\.36/i],describe:function(){return{name:o.ENGINE_MAP.Blink}}},{test:[/(apple)?webkit/i],describe:function(e){var t={name:o.ENGINE_MAP.WebKit},r=n.default.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,e);return r&&(t.version=r),t}}];t.default=s,e.exports=t.default}})},72322:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BoxDeveloperTokenAuth=void 0;const n=r(31210),o=r(72631),s=r(30893),a=r(46067);t.BoxDeveloperTokenAuth=class{constructor(e){this.config={},e.token&&(this.token=e.token),e.config&&(this.config=e.config),this.tokenStorage=new s.InMemoryTokenStorage({token:{accessToken:this.token}})}retrieveToken(e){return i(this,void 0,void 0,(function*(){const e=yield this.tokenStorage.get();if(null==e)throw new o.BoxSdkError({message:"No access token is available."});return e}))}refreshToken(e){return i(this,void 0,void 0,(function*(){throw new o.BoxSdkError({message:"Developer token has expired. Please provide a new one."})}))}retrieveAuthorizationHeader(e){return i(this,void 0,void 0,(function*(){const t=yield this.retrieveToken(e);return"".concat("Bearer ",t.accessToken)}))}revokeToken(e){return i(this,void 0,void 0,(function*(){const t=yield this.tokenStorage.get();if(null==t)return;const r=new a.AuthorizationManager({networkSession:null!=e?e:new n.NetworkSession({})});yield r.revokeAccessToken({clientId:this.config.clientId,clientSecret:this.config.clientSecret,token:t.accessToken}),yield this.tokenStorage.clear()}))}downscopeToken(e,t,r,s){return i(this,void 0,void 0,(function*(){const i=yield this.tokenStorage.get();if(null==i||null==i.accessToken)throw new o.BoxSdkError({message:"No access token is available."});const l=new a.AuthorizationManager({networkSession:null!=s?s:new n.NetworkSession({})});return yield l.requestAccessToken({grantType:"urn:ietf:params:oauth:grant-type:token-exchange",subjectToken:i.accessToken,subjectTokenType:"urn:ietf:params:oauth:token-type:access_token",scope:e.join(" "),resource:t,boxSharedLink:r})}))}}},72631:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BoxApiError=t.BoxSdkError=void 0;class r extends Error{constructor(e){super(e.message),this.name="BoxSDKError",Object.assign(this,e),this.message=JSON.stringify(e,void 0,2)}}t.BoxSdkError=r;t.BoxApiError=class extends r{constructor(e){super(e)}}},80070:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.BoxOAuth=t.OAuthConfig=void 0;const n=r(31210),o=r(46067),s=r(30893),a=r(50793),l=r(93845),d=r(72631);t.OAuthConfig=class{constructor(e){this.tokenStorage=new s.InMemoryTokenStorage({}),e.clientId&&(this.clientId=e.clientId),e.clientSecret&&(this.clientSecret=e.clientSecret),e.tokenStorage&&(this.tokenStorage=e.tokenStorage)}};t.BoxOAuth=class{constructor(e){e.config&&(this.config=e.config),this.tokenStorage=this.config.tokenStorage}getAuthorizeUrl(e={}){const t=(0,l.prepareParams)({client_id:null!=e.clientId?e.clientId:this.config.clientId,response_type:null!=e.responseType?e.responseType:"code",redirect_uri:e.redirectUri,state:e.state,scope:e.scope});return"".concat("https://account.box.com/api/oauth2/authorize?",(0,a.sdToUrlParams)(JSON.stringify(t)))}getTokensAuthorizationCodeGrant(e,t){return i(this,void 0,void 0,(function*(){const r=new o.AuthorizationManager({networkSession:null!=t?t:new n.NetworkSession({})}),i=yield r.requestAccessToken({grantType:"authorization_code",clientId:this.config.clientId,clientSecret:this.config.clientSecret,code:e});return yield this.tokenStorage.store(i),i}))}retrieveToken(e){return i(this,void 0,void 0,(function*(){const e=yield this.tokenStorage.get();if(null==e)throw new d.BoxSdkError({message:"Access and refresh tokens not available. Authenticate before making any API call first."});return e}))}refreshToken(e){return i(this,void 0,void 0,(function*(){const t=yield this.tokenStorage.get(),r=null!=t?t.refreshToken:void 0,i=new o.AuthorizationManager({networkSession:null!=e?e:new n.NetworkSession({})}),s=yield i.requestAccessToken({grantType:"refresh_token",clientId:this.config.clientId,clientSecret:this.config.clientSecret,refreshToken:r});return yield this.tokenStorage.store(s),s}))}retrieveAuthorizationHeader(e){return i(this,void 0,void 0,(function*(){const t=yield this.retrieveToken(e);return"".concat("Bearer ",t.accessToken)}))}revokeToken(e){return i(this,void 0,void 0,(function*(){const t=yield this.tokenStorage.get();if(null==t)return;const r=new o.AuthorizationManager({networkSession:null!=e?e:new n.NetworkSession({})});yield r.revokeAccessToken({clientId:this.config.clientId,clientSecret:this.config.clientSecret,token:t.accessToken})}))}downscopeToken(e,t,r,s){return i(this,void 0,void 0,(function*(){const i=yield this.tokenStorage.get();if(null==i||null==i.accessToken)throw new d.BoxSdkError({message:"No access token is available."});const a=new o.AuthorizationManager({networkSession:null!=s?s:new n.NetworkSession({})});return yield a.requestAccessToken({grantType:"urn:ietf:params:oauth:grant-type:token-exchange",subjectToken:i.accessToken,subjectTokenType:"urn:ietf:params:oauth:token-type:access_token",scope:e.join(" "),resource:t,boxSharedLink:r})}))}}},30893:function(e,t){"use strict";var r=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.InMemoryTokenStorage=void 0;t.InMemoryTokenStorage=class{constructor(e){this.token=void 0,e.token&&(this.token=e.token)}store(e){return r(this,void 0,void 0,(function*(){this.token=e}))}get(){return r(this,void 0,void 0,(function*(){return this.token}))}clear(){return r(this,void 0,void 0,(function*(){this.token=void 0}))}}},58686:(e,t,r)=>{"use strict";t.r=void 0;const i=r(46067),n=r(98425),o=r(45244),s=r(34638),a=r(82083),l=r(25052),d=r(17256),c=r(69496),u=r(78812),p=r(13612),h=r(67749),f=r(69085),m=r(96913),g=r(55040),y=r(14703),v=r(25318),b=r(1307),w=r(79434),_=r(53799),x=r(69023),S=r(91475),k=r(90269),E=r(63942),T=r(3670),B=r(40463),C=r(35561),I=r(92102),A=r(54991),F=r(81495),M=r(68567),D=r(59417),R=r(71305),P=r(57634),O=r(82415),z=r(70174),N=r(49888),q=r(80824),U=r(87653),L=r(16822),j=r(19631),H=r(64200),$=r(49534),G=r(40656),W=r(31591),K=r(98355),V=r(31395),J=r(95566),Y=r(30004),Q=r(92536),Z=r(22678),X=r(73859),ee=r(99681),te=r(22195),re=r(99253),ie=r(90072),ne=r(81194),oe=r(85180),se=r(72865),ae=r(61020),le=r(52162),de=r(86008),ce=r(99871),ue=r(59465),pe=r(32537),he=r(54270),fe=r(39797),me=r(16360),ge=r(41014),ye=r(58555),ve=r(27856),be=r(31210),we=r(42575);class _e{constructor(e){this.networkSession=new be.NetworkSession({baseUrls:new we.BaseUrls({})}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession),this.authorization=new i.AuthorizationManager({auth:this.auth,networkSession:this.networkSession}),this.files=new n.FilesManager({auth:this.auth,networkSession:this.networkSession}),this.trashedFiles=new o.TrashedFilesManager({auth:this.auth,networkSession:this.networkSession}),this.appItemAssociations=new s.AppItemAssociationsManager({auth:this.auth,networkSession:this.networkSession}),this.downloads=new a.DownloadsManager({auth:this.auth,networkSession:this.networkSession}),this.uploads=new l.UploadsManager({auth:this.auth,networkSession:this.networkSession}),this.chunkedUploads=new d.ChunkedUploadsManager({auth:this.auth,networkSession:this.networkSession}),this.listCollaborations=new c.ListCollaborationsManager({auth:this.auth,networkSession:this.networkSession}),this.comments=new u.CommentsManager({auth:this.auth,networkSession:this.networkSession}),this.tasks=new p.TasksManager({auth:this.auth,networkSession:this.networkSession}),this.fileVersions=new h.FileVersionsManager({auth:this.auth,networkSession:this.networkSession}),this.fileMetadata=new f.FileMetadataManager({auth:this.auth,networkSession:this.networkSession}),this.fileClassifications=new m.FileClassificationsManager({auth:this.auth,networkSession:this.networkSession}),this.skills=new g.SkillsManager({auth:this.auth,networkSession:this.networkSession}),this.fileWatermarks=new y.FileWatermarksManager({auth:this.auth,networkSession:this.networkSession}),this.fileRequests=new v.FileRequestsManager({auth:this.auth,networkSession:this.networkSession}),this.folders=new b.FoldersManager({auth:this.auth,networkSession:this.networkSession}),this.trashedFolders=new w.TrashedFoldersManager({auth:this.auth,networkSession:this.networkSession}),this.folderMetadata=new _.FolderMetadataManager({auth:this.auth,networkSession:this.networkSession}),this.folderClassifications=new x.FolderClassificationsManager({auth:this.auth,networkSession:this.networkSession}),this.trashedItems=new S.TrashedItemsManager({auth:this.auth,networkSession:this.networkSession}),this.folderWatermarks=new k.FolderWatermarksManager({auth:this.auth,networkSession:this.networkSession}),this.folderLocks=new E.FolderLocksManager({auth:this.auth,networkSession:this.networkSession}),this.metadataTemplates=new T.MetadataTemplatesManager({auth:this.auth,networkSession:this.networkSession}),this.classifications=new B.ClassificationsManager({auth:this.auth,networkSession:this.networkSession}),this.metadataCascadePolicies=new C.MetadataCascadePoliciesManager({auth:this.auth,networkSession:this.networkSession}),this.search=new I.SearchManager({auth:this.auth,networkSession:this.networkSession}),this.userCollaborations=new A.UserCollaborationsManager({auth:this.auth,networkSession:this.networkSession}),this.taskAssignments=new F.TaskAssignmentsManager({auth:this.auth,networkSession:this.networkSession}),this.sharedLinksFiles=new M.SharedLinksFilesManager({auth:this.auth,networkSession:this.networkSession}),this.sharedLinksFolders=new D.SharedLinksFoldersManager({auth:this.auth,networkSession:this.networkSession}),this.webLinks=new R.WebLinksManager({auth:this.auth,networkSession:this.networkSession}),this.trashedWebLinks=new P.TrashedWebLinksManager({auth:this.auth,networkSession:this.networkSession}),this.sharedLinksWebLinks=new O.SharedLinksWebLinksManager({auth:this.auth,networkSession:this.networkSession}),this.users=new z.UsersManager({auth:this.auth,networkSession:this.networkSession}),this.sessionTermination=new N.SessionTerminationManager({auth:this.auth,networkSession:this.networkSession}),this.avatars=new q.AvatarsManager({auth:this.auth,networkSession:this.networkSession}),this.transfer=new U.TransferManager({auth:this.auth,networkSession:this.networkSession}),this.emailAliases=new L.EmailAliasesManager({auth:this.auth,networkSession:this.networkSession}),this.memberships=new j.MembershipsManager({auth:this.auth,networkSession:this.networkSession}),this.invites=new H.InvitesManager({auth:this.auth,networkSession:this.networkSession}),this.groups=new $.GroupsManager({auth:this.auth,networkSession:this.networkSession}),this.webhooks=new G.WebhooksManager({auth:this.auth,networkSession:this.networkSession}),this.events=new W.EventsManager({auth:this.auth,networkSession:this.networkSession}),this.collections=new K.CollectionsManager({auth:this.auth,networkSession:this.networkSession}),this.recentItems=new V.RecentItemsManager({auth:this.auth,networkSession:this.networkSession}),this.retentionPolicies=new J.RetentionPoliciesManager({auth:this.auth,networkSession:this.networkSession}),this.retentionPolicyAssignments=new Y.RetentionPolicyAssignmentsManager({auth:this.auth,networkSession:this.networkSession}),this.legalHoldPolicies=new Q.LegalHoldPoliciesManager({auth:this.auth,networkSession:this.networkSession}),this.legalHoldPolicyAssignments=new Z.LegalHoldPolicyAssignmentsManager({auth:this.auth,networkSession:this.networkSession}),this.fileVersionRetentions=new X.FileVersionRetentionsManager({auth:this.auth,networkSession:this.networkSession}),this.fileVersionLegalHolds=new ee.FileVersionLegalHoldsManager({auth:this.auth,networkSession:this.networkSession}),this.shieldInformationBarriers=new te.ShieldInformationBarriersManager({auth:this.auth,networkSession:this.networkSession}),this.shieldInformationBarrierReports=new re.ShieldInformationBarrierReportsManager({auth:this.auth,networkSession:this.networkSession}),this.shieldInformationBarrierSegments=new ie.ShieldInformationBarrierSegmentsManager({auth:this.auth,networkSession:this.networkSession}),this.shieldInformationBarrierSegmentMembers=new ne.ShieldInformationBarrierSegmentMembersManager({auth:this.auth,networkSession:this.networkSession}),this.shieldInformationBarrierSegmentRestrictions=new oe.ShieldInformationBarrierSegmentRestrictionsManager({auth:this.auth,networkSession:this.networkSession}),this.devicePinners=new se.DevicePinnersManager({auth:this.auth,networkSession:this.networkSession}),this.termsOfServices=new ae.TermsOfServicesManager({auth:this.auth,networkSession:this.networkSession}),this.termsOfServiceUserStatuses=new le.TermsOfServiceUserStatusesManager({auth:this.auth,networkSession:this.networkSession}),this.collaborationAllowlistEntries=new de.CollaborationAllowlistEntriesManager({auth:this.auth,networkSession:this.networkSession}),this.collaborationAllowlistExemptTargets=new ce.CollaborationAllowlistExemptTargetsManager({auth:this.auth,networkSession:this.networkSession}),this.storagePolicies=new ue.StoragePoliciesManager({auth:this.auth,networkSession:this.networkSession}),this.storagePolicyAssignments=new pe.StoragePolicyAssignmentsManager({auth:this.auth,networkSession:this.networkSession}),this.zipDownloads=new he.ZipDownloadsManager({auth:this.auth,networkSession:this.networkSession}),this.signRequests=new fe.SignRequestsManager({auth:this.auth,networkSession:this.networkSession}),this.workflows=new me.WorkflowsManager({auth:this.auth,networkSession:this.networkSession}),this.signTemplates=new ge.SignTemplatesManager({auth:this.auth,networkSession:this.networkSession}),this.integrationMappings=new ye.IntegrationMappingsManager({auth:this.auth,networkSession:this.networkSession}),this.ai=new ve.AiManager({auth:this.auth,networkSession:this.networkSession})}withAsUserHeader(e){return new _e({auth:this.auth,networkSession:this.networkSession.withAdditionalHeaders({"As-User":e})})}withSuppressedNotifications(){return new _e({auth:this.auth,networkSession:this.networkSession.withAdditionalHeaders({"Box-Notifications":"off"})})}withExtraHeaders(e={}){return new _e({auth:this.auth,networkSession:this.networkSession.withAdditionalHeaders(e)})}withCustomBaseUrls(e){const t=new we.BaseUrls({baseUrl:e.baseUrl,uploadUrl:e.uploadUrl,oauth2Url:e.oauth2Url});return new _e({auth:this.auth,networkSession:this.networkSession.withCustomBaseUrls(t)})}withProxy(e){return new _e({auth:this.auth,networkSession:this.networkSession.withProxy(e)})}withCustomAgentOptions(e){return new _e({auth:this.auth,networkSession:this.networkSession.withCustomAgentOptions(e)})}withInterceptors(e){return new _e({auth:this.auth,networkSession:this.networkSession.withInterceptors(e)})}}t.r=_e},93845:function(__unused_webpack_module,exports,__webpack_require__){"use strict";var process=__webpack_require__(65606),__awaiter=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))},__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,t,r,i,n){if("m"===i)throw new TypeError("Private method is not writable");if("a"===i&&!n)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!n:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===i?n.call(e,r):n?n.value=r:t.set(e,r),r},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,t,r,i){if("a"===r&&!i)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?i:"a"===r?i.call(e):i?i.value:t.get(e)},__asyncValues=this&&this.__asyncValues||function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},i("next"),i("throw"),i("return"),t[Symbol.asyncIterator]=function(){return this},t);function i(r){t[r]=e[r]&&function(t){return new Promise((function(i,n){(function(e,t,r,i){Promise.resolve(i).then((function(t){e({value:t,done:r})}),t)})(i,n,(t=e[r](t)).done,t.value)}))}}},__await=this&&this.__await||function(e){return this instanceof __await?(this.v=e,this):new __await(e)},__asyncGenerator=this&&this.__asyncGenerator||function(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i,n=r.apply(e,t||[]),o=[];return i=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),s("next"),s("throw"),s("return",(function(e){return function(t){return Promise.resolve(t).then(e,d)}})),i[Symbol.asyncIterator]=function(){return this},i;function s(e,t){n[e]&&(i[e]=function(t){return new Promise((function(r,i){o.push([e,t,r,i])>1||a(e,t)}))},t&&(i[e]=t(i[e])))}function a(e,t){try{(r=n[e](t)).value instanceof __await?Promise.resolve(r.value.v).then(l,d):c(o[0][2],r)}catch(e){c(o[0][3],e)}var r}function l(e){a("next",e)}function d(e){a("throw",e)}function c(e,t){e(t),o.shift(),o.length&&a(o[0][0],o[0][1])}},_Hash_hash,_Hash_chunks;Object.defineProperty(exports,"__esModule",{value:!0}),exports.Hash=exports.DateTime=exports.Date=exports.Buffer=void 0,exports.isBrowser=isBrowser,exports.getUuid=getUuid,exports.decodeBase64=decodeBase64,exports.hexToBase64=hexToBase64,exports.dateFromString=dateFromString,exports.deserializeDate=dateFromString,exports.dateToString=dateToString,exports.serializeDate=dateToString,exports.dateTimeFromString=dateTimeFromString,exports.deserializeDateTime=dateTimeFromString,exports.dateTimeToString=dateTimeToString,exports.serializeDateTime=dateTimeToString,exports.hexStrToBase64=hexStrToBase64,exports.getEnvVar=getEnvVar,exports.generateByteBuffer=generateByteBuffer,exports.generateByteStreamFromBuffer=generateByteStreamFromBuffer,exports.generateByteStream=generateByteStream,exports.bufferEquals=bufferEquals,exports.bufferLength=bufferLength,exports.decodeBase64ByteStream=decodeBase64ByteStream,exports.stringToByteStream=stringToByteStream,exports.readByteStream=readByteStream,exports.iterateChunks=iterateChunks,exports.reduceIterator=reduceIterator,exports.prepareParams=prepareParams,exports.toString=toString,exports.createTokenAndCancelAfter=createTokenAndCancelAfter,exports.createJwtAssertion=createJwtAssertion,exports.readTextFromFile=readTextFromFile,exports.getEpochTimeInSeconds=getEpochTimeInSeconds,exports.createAgent=createAgent,exports.delayInSeconds=delayInSeconds,exports.getValueFromObjectRawData=getValueFromObjectRawData;const buffer_1=__webpack_require__(48287);Object.defineProperty(exports,"Buffer",{enumerable:!0,get:function(){return buffer_1.Buffer}});const uuid_1=__webpack_require__(16882),jose_1=__webpack_require__(25948);function isBrowser(){return"object"==typeof window&&"object"==typeof document&&window.crypto}function getUuid(){return(0,uuid_1.v4)()}function decodeBase64(e){return buffer_1.Buffer.from(e,"base64").toString("utf8")}function hexToBase64(e){return buffer_1.Buffer.from(e,"hex").toString("base64")}class DateWrapper{constructor(e){this.value=e}}exports.Date=DateWrapper;class DateTimeWrapper{constructor(e){this.value=e}}function dateFromString(e){return new DateWrapper(new Date(e))}function dateToString(e){return e.value.toISOString().match(/^\d{4}-\d{2}-\d{2}/)[0]}function dateTimeFromString(e){return new DateTimeWrapper(new Date(e))}function dateTimeToString(e){return e.value.toISOString().match(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/)[0]+"+00:00"}function hexStrToBase64(e){const t=e.toString(),r=new Uint8Array(t.length/2);for(let e=0;ee.toString(16).padStart(2,"0"))).join("");return"base64"===e?hexStrToBase64(t):t}return __classPrivateFieldGet(this,_Hash_hash,"f").digest(e)}))}}function getEnvVar(e){return process.env[e]||""}function generateByteBuffer(size){if(isBrowser()){const e=new Uint8Array(size);return window.crypto.getRandomValues(e),buffer_1.Buffer.from(e)}const crypto=eval("require")("crypto");return crypto.randomBytes(size)}function generateByteStreamFromBuffer(buffer){return isBrowser()?new ReadableStream({start(e){e.enqueue(new Uint8Array(buffer)),e.close()}}):eval("require")("stream").Readable.from(buffer_1.Buffer.from(buffer))}function generateByteStream(e){return generateByteStreamFromBuffer(generateByteBuffer(e))}function bufferEquals(e,t){return 0===buffer_1.Buffer.compare(e,t)}function bufferLength(e){return e.length}function decodeBase64ByteStream(data){return isBrowser()?new ReadableStream({start(e){const t=atob(data),r=new ArrayBuffer(t.length),i=new Uint8Array(r);for(let e=0;e=t;)yield yield __await(generateByteStreamFromBuffer(r.subarray(i,i+t))),i+=t,l-=t;a=l>0?[r.subarray(i)]:[]}}catch(e){n={error:e}}finally{try{u||i||!(o=p.return)||(yield __await(o.call(p)))}finally{if(n)throw n.error}}if(d!==r)throw new Error(`Stream size ${d} does not match expected file size ${r}`);l>0&&(yield yield __await(generateByteStreamFromBuffer(buffer_1.Buffer.concat(a))))}))}function reduceIterator(e,t,r){return __awaiter(this,void 0,void 0,(function*(){let i=r,n=yield e.next();for(;!n.done;)i=yield t(i,n.value),n=yield e.next();return i}))}function prepareParams(e){if(!e||"object"!=typeof e)throw new Error("Expecting obj to be an object in prepareParams");return Object.fromEntries(Object.entries(e).filter((e=>"string"==typeof e[1])))}function toString(e){return"string"==typeof e||null==e?e:String(e)}function createTokenAndCancelAfter(e){return AbortSignal.timeout(e)}function createJwtAssertion(claims,key,options){return __awaiter(this,void 0,void 0,(function*(){const crypto=eval("require")("crypto"),privateKey=crypto.createPrivateKey({key:key.key,format:"pem",type:"pkcs8",passphrase:key.passphrase}),pem=privateKey.export({type:"pkcs8",format:"pem"}).toString(),pkcs8=yield(0,jose_1.importPKCS8)(pem,options.algorithm||"RS256");let signer=new jose_1.SignJWT(claims);return signer=options.audience?signer.setAudience(options.audience):signer,signer=options.expiresIn?signer.setExpirationTime(options.expiresIn):signer,signer=options.issuer?signer.setIssuer(options.issuer):signer,signer=options.jwtid?signer.setJti(options.jwtid):signer,signer=options.notBefore?signer.setNotBefore(options.notBefore):signer,signer=options.subject?signer.setSubject(options.subject):signer,signer=options.algorithm?signer.setProtectedHeader({alg:options.algorithm}):signer,signer=signer.setIssuedAt(),yield signer.sign(pkcs8)}))}function readTextFromFile(filepath){return eval("require")("fs").readFileSync(filepath,"utf8")}function getEpochTimeInSeconds(){return Math.floor(Date.now()/1e3)}function createAgent(options,proxyConfig){if(isBrowser())return;const ProxyAgent=eval("require")("proxy-agent").ProxyAgent;let agentOptions=options;if(proxyConfig&&proxyConfig.url){if(!proxyConfig.url.startsWith("http"))throw new Error("Invalid proxy URL");const e=proxyConfig.url.split("//")[1],t=proxyConfig.username&&proxyConfig.password?`${proxyConfig.username}:${proxyConfig.password}@`:"",r=`http://${t}${e}`;agentOptions=Object.assign({getProxyForUrl:e=>r},options||{})}return agentOptions?new ProxyAgent(agentOptions):new ProxyAgent}function delayInSeconds(e){return __awaiter(this,void 0,void 0,(function*(){return yield new Promise((t=>setTimeout(t,1e3*e)))}))}function getValueFromObjectRawData(e,t){if(e&&"object"==typeof e&&e.rawData)return e.rawData[t]}exports.Hash=Hash,_Hash_hash=new WeakMap,_Hash_chunks=new WeakMap},27856:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.AiManager=t.CreateAiExtractStructuredHeaders=t.CreateAiExtractHeaders=t.GetAiAgentDefaultConfigHeaders=t.CreateAiTextGenHeaders=t.CreateAiAskHeaders=t.CreateAiExtractStructuredOptionals=t.CreateAiExtractOptionals=t.GetAiAgentDefaultConfigOptionals=t.CreateAiTextGenOptionals=t.CreateAiAskOptionals=void 0,t.serializeGetAiAgentDefaultConfigQueryParamsModeField=function(e){return e},t.deserializeGetAiAgentDefaultConfigQueryParamsModeField=function(e){if("ask"==e)return e;if("text_gen"==e)return e;if("extract"==e)return e;if("extract_structured"==e)return e;throw new g.BoxSdkError({message:"Can't deserialize GetAiAgentDefaultConfigQueryParamsModeField"})};const n=r(89820),o=r(90791),s=r(67713),a=r(82469),l=r(62180),d=r(62519),c=r(84948),u=r(65888),p=r(31210),h=r(93845),f=r(93845),m=r(84143),g=r(72631);class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateAiAskOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateAiTextGenOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetAiAgentDefaultConfigOptionals=b;class w{constructor(e){this.headers=new E({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateAiExtractOptionals=w;class _{constructor(e){this.headers=new T({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateAiExtractStructuredOptionals=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateAiAskHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateAiTextGenHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetAiAgentDefaultConfigHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateAiExtractHeaders=E;class T{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateAiExtractStructuredHeaders=T;t.AiManager=class{constructor(e){this.networkSession=new p.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}createAiAsk(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,s=r.cancellationToken,a=(0,h.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,m.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/ai/ask"),method:"POST",headers:a,data:(0,o.serializeAiAsk)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeAiResponseFull)(l.data)),{rawData:l.data})}))}createAiTextGen(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,h.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,m.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/ai/text_gen"),method:"POST",headers:o,data:(0,a.serializeAiTextGen)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,s.deserializeAiResponse)(l.data)),{rawData:l.data})}))}getAiAgentDefaultConfig(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,h.prepareParams)({mode:(0,f.toString)(e.mode),language:(0,f.toString)(e.language),model:(0,f.toString)(e.model)}),s=(0,h.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,m.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/ai_agent_default"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,l.deserializeAiAgentAskOrAiAgentExtractOrAiAgentExtractStructuredOrAiAgentTextGen)(a.data)),{rawData:a.data})}))}createAiExtract(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,h.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,m.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/ai/extract"),method:"POST",headers:o,data:(0,d.serializeAiExtract)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,s.deserializeAiResponse)(a.data)),{rawData:a.data})}))}createAiExtractStructured(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new _({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,h.prepareParams)(Object.assign({},i.extraHeaders)),s=yield(0,m.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/ai/extract_structured"),method:"POST",headers:o,data:(0,u.serializeAiExtractStructured)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,c.deserializeAiExtractResponse)(s.data)),{rawData:s.data})}))}}},34638:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.AppItemAssociationsManager=t.GetFolderAppItemAssociationsHeaders=t.GetFileAppItemAssociationsHeaders=t.GetFolderAppItemAssociationsOptionals=t.GetFileAppItemAssociationsOptionals=void 0;const n=r(98292),o=r(31210),s=r(93845),a=r(93845),l=r(84143);class d{constructor(e){this.queryParams={},this.headers=new u({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileAppItemAssociationsOptionals=d;class c{constructor(e){this.queryParams={},this.headers=new p({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderAppItemAssociationsOptionals=c;class u{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileAppItemAssociationsHeaders=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderAppItemAssociationsHeaders=p;t.AppItemAssociationsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileAppItemAssociations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new d({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,c=r.cancellationToken,u=(0,s.prepareParams)({limit:(0,a.toString)(i.limit),marker:(0,a.toString)(i.marker),application_type:(0,a.toString)(i.applicationType)}),p=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),h=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/app_item_associations"),method:"GET",params:u,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,n.deserializeAppItemAssociations)(h.data)),{rawData:h.data})}))}getFolderAppItemAssociations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,u=(0,s.prepareParams)({limit:(0,a.toString)(i.limit),marker:(0,a.toString)(i.marker),application_type:(0,a.toString)(i.applicationType)}),p=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),h=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/app_item_associations"),method:"GET",params:u,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeAppItemAssociations)(h.data)),{rawData:h.data})}))}}},46067:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationManager=t.RevokeAccessTokenHeaders=t.RefreshAccessTokenHeaders=t.RequestAccessTokenHeaders=t.AuthorizeUserHeaders=t.RevokeAccessTokenOptionals=t.RefreshAccessTokenOptionals=t.RequestAccessTokenOptionals=t.AuthorizeUserOptionals=void 0,t.serializeAuthorizeUserQueryParamsResponseTypeField=function(e){return e},t.deserializeAuthorizeUserQueryParamsResponseTypeField=function(e){if("code"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize AuthorizeUserQueryParamsResponseTypeField"})};const n=r(28403),o=r(61734),s=r(67028),a=r(31227),l=r(67028),d=r(31210),c=r(93845),u=r(93845),p=r(84143),h=r(72631);class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AuthorizeUserOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RequestAccessTokenOptionals=m;class g{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RefreshAccessTokenOptionals=g;class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RevokeAccessTokenOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AuthorizeUserHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RequestAccessTokenHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RefreshAccessTokenHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RevokeAccessTokenHeaders=_;t.AuthorizationManager=class{constructor(e){this.networkSession=new d.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}authorizeUser(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,c.prepareParams)({response_type:(0,u.toString)(e.responseType),client_id:(0,u.toString)(e.clientId),redirect_uri:(0,u.toString)(e.redirectUri),state:(0,u.toString)(e.state),scope:(0,u.toString)(e.scope)}),s=(0,c.prepareParams)(Object.assign({},i.extraHeaders));yield(0,p.fetch)({url:"".concat(this.networkSession.baseUrls.oauth2Url,"/authorize"),method:"GET",params:o,headers:s,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}requestAccessToken(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,s=r.cancellationToken,a=(0,c.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,p.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/oauth2/token"),method:"POST",headers:a,data:(0,o.serializePostOAuth2Token)(e),contentType:"application/x-www-form-urlencoded",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeAccessToken)(l.data)),{rawData:l.data})}))}refreshAccessToken(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new l.PostOAuth2TokenRefreshAccessToken({grantType:e.grantType,clientId:e.clientId,clientSecret:e.clientSecret,refreshToken:e.refreshToken}),i=new g({headers:t.headers,cancellationToken:t.cancellationToken}),o=i.headers,a=i.cancellationToken,d=(0,c.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,p.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/oauth2/token#refresh"),method:"POST",headers:d,data:(0,s.serializePostOAuth2TokenRefreshAccessToken)(r),contentType:"application/x-www-form-urlencoded",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeAccessToken)(u.data)),{rawData:u.data})}))}revokeAccessToken(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,c.prepareParams)(Object.assign({},i.extraHeaders));yield(0,p.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/oauth2/revoke"),method:"POST",headers:o,data:(0,a.serializePostOAuth2Revoke)(e),contentType:"application/x-www-form-urlencoded",responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},80824:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.AvatarsManager=t.DeleteUserAvatarHeaders=t.CreateUserAvatarHeaders=t.GetUserAvatarHeaders=t.DeleteUserAvatarOptionals=t.CreateUserAvatarOptionals=t.GetUserAvatarOptionals=void 0;const n=r(59730),o=r(31210),s=r(93845),a=r(93845),l=r(84143);class d{constructor(e){this.headers=new p({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetUserAvatarOptionals=d;class c{constructor(e){this.headers=new h({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateUserAvatarOptionals=c;class u{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteUserAvatarOptionals=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUserAvatarHeaders=p;class h{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateUserAvatarHeaders=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteUserAvatarHeaders=f;t.AvatarsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getUserAvatar(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new d({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));return(yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,a.toString)(e),"/avatar"),method:"GET",headers:o,responseFormat:"binary",auth:this.auth,networkSession:this.networkSession,cancellationToken:n})).content}))}createUserAvatar(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new c({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,d=i.cancellationToken,u=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,a.toString)(e),"/avatar"),method:"POST",headers:u,multipartData:[{partName:"pic",fileStream:t.pic,fileName:t.picFileName,contentType:t.picContentType}],contentType:"multipart/form-data",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeUserAvatar)(p.data)),{rawData:p.data})}))}deleteUserAvatar(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,a.toString)(e),"/avatar"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},17256:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ChunkedUploadsManager=t.CreateFileUploadSessionCommitHeaders=t.CreateFileUploadSessionCommitByUrlHeaders=t.GetFileUploadSessionPartsHeaders=t.GetFileUploadSessionPartsByUrlHeaders=t.DeleteFileUploadSessionByIdHeaders=t.DeleteFileUploadSessionByUrlHeaders=t.UploadFilePartHeaders=t.UploadFilePartByUrlHeaders=t.GetFileUploadSessionByIdHeaders=t.GetFileUploadSessionByUrlHeaders=t.CreateFileUploadSessionForExistingFileHeaders=t.CreateFileUploadSessionHeaders=t.CreateFileUploadSessionCommitOptionals=t.CreateFileUploadSessionCommitByUrlOptionals=t.GetFileUploadSessionPartsOptionals=t.GetFileUploadSessionPartsByUrlOptionals=t.DeleteFileUploadSessionByIdOptionals=t.DeleteFileUploadSessionByUrlOptionals=t.UploadFilePartOptionals=t.UploadFilePartByUrlOptionals=t.GetFileUploadSessionByIdOptionals=t.GetFileUploadSessionByUrlOptionals=t.CreateFileUploadSessionForExistingFileOptionals=t.CreateFileUploadSessionOptionals=void 0,t.serializeCreateFileUploadSessionRequestBody=Y,t.deserializeCreateFileUploadSessionRequestBody=function(e){if(!(0,E.sdIsMap)(e))throw new _.BoxSdkError({message:'Expecting a map for "CreateFileUploadSessionRequestBody"'});if(null==e.folder_id)throw new _.BoxSdkError({message:'Expecting "folder_id" of type "CreateFileUploadSessionRequestBody" to be defined'});if(!(0,S.sdIsString)(e.folder_id))throw new _.BoxSdkError({message:'Expecting string for "folder_id" of type "CreateFileUploadSessionRequestBody"'});const t=e.folder_id;if(null==e.file_size)throw new _.BoxSdkError({message:'Expecting "file_size" of type "CreateFileUploadSessionRequestBody" to be defined'});if(!(0,x.sdIsNumber)(e.file_size))throw new _.BoxSdkError({message:'Expecting number for "file_size" of type "CreateFileUploadSessionRequestBody"'});const r=e.file_size;if(null==e.file_name)throw new _.BoxSdkError({message:'Expecting "file_name" of type "CreateFileUploadSessionRequestBody" to be defined'});if(!(0,S.sdIsString)(e.file_name))throw new _.BoxSdkError({message:'Expecting string for "file_name" of type "CreateFileUploadSessionRequestBody"'});const i=e.file_name;return{folderId:t,fileSize:r,fileName:i}},t.serializeCreateFileUploadSessionForExistingFileRequestBody=Q,t.deserializeCreateFileUploadSessionForExistingFileRequestBody=function(e){if(!(0,E.sdIsMap)(e))throw new _.BoxSdkError({message:'Expecting a map for "CreateFileUploadSessionForExistingFileRequestBody"'});if(null==e.file_size)throw new _.BoxSdkError({message:'Expecting "file_size" of type "CreateFileUploadSessionForExistingFileRequestBody" to be defined'});if(!(0,x.sdIsNumber)(e.file_size))throw new _.BoxSdkError({message:'Expecting number for "file_size" of type "CreateFileUploadSessionForExistingFileRequestBody"'});const t=e.file_size;if(null!=e.file_name&&!(0,S.sdIsString)(e.file_name))throw new _.BoxSdkError({message:'Expecting string for "file_name" of type "CreateFileUploadSessionForExistingFileRequestBody"'});const r=null==e.file_name?void 0:e.file_name;return{fileSize:t,fileName:r}},t.serializeCreateFileUploadSessionCommitByUrlRequestBody=function(e){return{parts:e.parts.map((function(e){return(0,l.serializeUploadPart)(e)}))}},t.deserializeCreateFileUploadSessionCommitByUrlRequestBody=function(e){if(!(0,E.sdIsMap)(e))throw new _.BoxSdkError({message:'Expecting a map for "CreateFileUploadSessionCommitByUrlRequestBody"'});if(null==e.parts)throw new _.BoxSdkError({message:'Expecting "parts" of type "CreateFileUploadSessionCommitByUrlRequestBody" to be defined'});if(!(0,k.sdIsList)(e.parts))throw new _.BoxSdkError({message:'Expecting array for "parts" of type "CreateFileUploadSessionCommitByUrlRequestBody"'});return{parts:(0,k.sdIsList)(e.parts)?e.parts.map((function(e){return(0,d.deserializeUploadPart)(e)})):[]}},t.serializeCreateFileUploadSessionCommitRequestBody=Z,t.deserializeCreateFileUploadSessionCommitRequestBody=function(e){if(!(0,E.sdIsMap)(e))throw new _.BoxSdkError({message:'Expecting a map for "CreateFileUploadSessionCommitRequestBody"'});if(null==e.parts)throw new _.BoxSdkError({message:'Expecting "parts" of type "CreateFileUploadSessionCommitRequestBody" to be defined'});if(!(0,k.sdIsList)(e.parts))throw new _.BoxSdkError({message:'Expecting array for "parts" of type "CreateFileUploadSessionCommitRequestBody"'});return{parts:(0,k.sdIsList)(e.parts)?e.parts.map((function(e){return(0,d.deserializeUploadPart)(e)})):[]}};const n=r(26391),o=r(31621),s=r(2001),a=r(379),l=r(3868),d=r(3868),c=r(31210),u=r(93845),p=r(93845),h=r(84143),f=r(93845),m=r(93845),g=r(93845),y=r(93845),v=r(93845),b=r(93845),w=r(93845),_=r(72631),x=r(50793),S=r(50793),k=r(50793),E=r(50793);class T{constructor(e){this.headers=new N({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileUploadSessionOptionals=T;class B{constructor(e){this.headers=new q({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileUploadSessionForExistingFileOptionals=B;class C{constructor(e){this.headers=new U({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileUploadSessionByUrlOptionals=C;class I{constructor(e){this.headers=new L({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileUploadSessionByIdOptionals=I;class A{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UploadFilePartByUrlOptionals=A;class F{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UploadFilePartOptionals=F;class M{constructor(e){this.headers=new $({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileUploadSessionByUrlOptionals=M;class D{constructor(e){this.headers=new G({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileUploadSessionByIdOptionals=D;class R{constructor(e){this.queryParams={},this.headers=new W({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileUploadSessionPartsByUrlOptionals=R;class P{constructor(e){this.queryParams={},this.headers=new K({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileUploadSessionPartsOptionals=P;class O{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileUploadSessionCommitByUrlOptionals=O;class z{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileUploadSessionCommitOptionals=z;class N{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileUploadSessionHeaders=N;class q{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileUploadSessionForExistingFileHeaders=q;class U{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileUploadSessionByUrlHeaders=U;class L{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileUploadSessionByIdHeaders=L;class j{constructor(e){this.extraHeaders={},e.digest&&(this.digest=e.digest),e.contentRange&&(this.contentRange=e.contentRange),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UploadFilePartByUrlHeaders=j;class H{constructor(e){this.extraHeaders={},e.digest&&(this.digest=e.digest),e.contentRange&&(this.contentRange=e.contentRange),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UploadFilePartHeaders=H;class ${constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileUploadSessionByUrlHeaders=$;class G{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileUploadSessionByIdHeaders=G;class W{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileUploadSessionPartsByUrlHeaders=W;class K{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileUploadSessionPartsHeaders=K;class V{constructor(e){this.extraHeaders={},e.digest&&(this.digest=e.digest),e.ifMatch&&(this.ifMatch=e.ifMatch),e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileUploadSessionCommitByUrlHeaders=V;class J{constructor(e){this.extraHeaders={},e.digest&&(this.digest=e.digest),e.ifMatch&&(this.ifMatch=e.ifMatch),e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileUploadSessionCommitHeaders=J;function Y(e){return{folder_id:e.folderId,file_size:e.fileSize,file_name:e.fileName}}function Q(e){return{file_size:e.fileSize,file_name:null==e.fileName?void 0:e.fileName}}function Z(e){return{parts:e.parts.map((function(e){return(0,l.serializeUploadPart)(e)}))}}t.ChunkedUploadsManager=class{constructor(e){this.networkSession=new c.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}createFileUploadSession(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new T({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions"),method:"POST",headers:s,data:Y(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeUploadSession)(a.data)),{rawData:a.data})}))}createFileUploadSessionForExistingFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new B({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,u.prepareParams)(Object.assign({},o.extraHeaders)),l=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/",(0,p.toString)(e),"/upload_sessions"),method:"POST",headers:a,data:Q(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeUploadSession)(l.data)),{rawData:l.data})}))}getFileUploadSessionByUrl(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new C({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:e,method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeUploadSession)(a.data)),{rawData:a.data})}))}getFileUploadSessionById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new I({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions/",(0,p.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeUploadSession)(a.data)),{rawData:a.data})}))}uploadFilePartByUrl(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new j({digest:r.digest,contentRange:r.contentRange,extraHeaders:r.extraHeaders}),s=new A({cancellationToken:i.cancellationToken}).cancellationToken,a=(0,u.prepareParams)(Object.assign({digest:(0,p.toString)(n.digest),"content-range":(0,p.toString)(n.contentRange)},n.extraHeaders)),l=yield(0,h.fetch)({url:e,method:"PUT",headers:a,fileStream:t,contentType:"application/octet-stream",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeUploadedPart)(l.data)),{rawData:l.data})}))}uploadFilePart(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new H({digest:r.digest,contentRange:r.contentRange,extraHeaders:r.extraHeaders}),s=new F({cancellationToken:i.cancellationToken}).cancellationToken,a=(0,u.prepareParams)(Object.assign({digest:(0,p.toString)(n.digest),"content-range":(0,p.toString)(n.contentRange)},n.extraHeaders)),l=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions/",(0,p.toString)(e)),method:"PUT",headers:a,fileStream:t,contentType:"application/octet-stream",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeUploadedPart)(l.data)),{rawData:l.data})}))}deleteFileUploadSessionByUrl(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new M({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,u.prepareParams)(Object.assign({},i.extraHeaders));yield(0,h.fetch)({url:e,method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}deleteFileUploadSessionById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new D({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,u.prepareParams)(Object.assign({},i.extraHeaders));yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions/",(0,p.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getFileUploadSessionPartsByUrl(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new R({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,a=(0,u.prepareParams)({offset:(0,p.toString)(i.offset),limit:(0,p.toString)(i.limit)}),l=(0,u.prepareParams)(Object.assign({},n.extraHeaders)),d=yield(0,h.fetch)({url:e,method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,s.deserializeUploadParts)(d.data)),{rawData:d.data})}))}getFileUploadSessionParts(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new P({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,a=(0,u.prepareParams)({offset:(0,p.toString)(i.offset),limit:(0,p.toString)(i.limit)}),l=(0,u.prepareParams)(Object.assign({},n.extraHeaders)),d=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions/",(0,p.toString)(e),"/parts"),method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,s.deserializeUploadParts)(d.data)),{rawData:d.data})}))}createFileUploadSessionCommitByUrl(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new V({digest:r.digest,ifMatch:r.ifMatch,ifNoneMatch:r.ifNoneMatch,extraHeaders:r.extraHeaders}),o=new O({cancellationToken:i.cancellationToken}).cancellationToken,s=(0,u.prepareParams)(Object.assign({digest:(0,p.toString)(n.digest),"if-match":(0,p.toString)(n.ifMatch),"if-none-match":(0,p.toString)(n.ifNoneMatch)},n.extraHeaders)),l=yield(0,h.fetch)({url:e,method:"POST",headers:s,data:Z(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,a.deserializeFiles)(l.data)),{rawData:l.data})}))}createFileUploadSessionCommit(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new J({digest:r.digest,ifMatch:r.ifMatch,ifNoneMatch:r.ifNoneMatch,extraHeaders:r.extraHeaders}),o=new z({cancellationToken:i.cancellationToken}).cancellationToken,s=(0,u.prepareParams)(Object.assign({digest:(0,p.toString)(n.digest),"if-match":(0,p.toString)(n.ifMatch),"if-none-match":(0,p.toString)(n.ifNoneMatch)},n.extraHeaders)),l=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/upload_sessions/",(0,p.toString)(e),"/commit"),method:"POST",headers:s,data:Z(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,a.deserializeFiles)(l.data)),{rawData:l.data})}))}reducer(e,t){return i(this,void 0,void 0,(function*(){const r=e.lastIndex,i=e.parts,n=yield(0,y.readByteStream)(t),o=new b.Hash({algorithm:"sha1"});o.updateHash(n);const s=yield o.digestHash("base64"),a="".concat("sha=",s),l=(0,w.bufferLength)(n),d=r+1,c=r+l,u="".concat("bytes ",(0,p.toString)(d),"-",(0,p.toString)(c),"/",(0,p.toString)(e.fileSize)),h=(yield this.uploadFilePartByUrl(e.uploadPartUrl,(0,f.generateByteStreamFromBuffer)(n),{digest:a,contentRange:u})).part;if((0,m.hexToBase64)(h.sha1)!=s)throw new Error("Assertion failed");if(h.size!=l)throw new Error("Assertion failed");if(h.offset!=d)throw new Error("Assertion failed");return e.fileHash.updateHash(n),{lastIndex:c,parts:i.concat([h]),fileSize:e.fileSize,uploadPartUrl:e.uploadPartUrl,fileHash:e.fileHash}}))}uploadBigFile(e,t,r,n,o){return i(this,void 0,void 0,(function*(){const i=yield this.createFileUploadSession({fileName:t,fileSize:r,folderId:n},{headers:new N({}),cancellationToken:o}),s=i.sessionEndpoints.uploadPart,a=i.sessionEndpoints.commit,l=i.sessionEndpoints.listParts,d=i.partSize,c=i.totalParts;if(!(d*c>=r))throw new Error("Assertion failed");if(0!=i.numPartsProcessed)throw new Error("Assertion failed");const u=new b.Hash({algorithm:"sha1"}),p=(0,g.iterateChunks)(e,d,r),h=(yield(0,v.reduceIterator)(p,this.reducer.bind(this),{lastIndex:-1,parts:[],fileSize:r,uploadPartUrl:s,fileHash:u})).parts;if((yield this.getFileUploadSessionPartsByUrl(l,{queryParams:{},headers:new W({}),cancellationToken:o})).totalCount!=c)throw new Error("Assertion failed");const f=yield u.digestHash("base64"),m="".concat("sha=",f);return(yield this.createFileUploadSessionCommitByUrl(a,{parts:h},{digest:m},{cancellationToken:o})).entries[0]}))}}},40463:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ClassificationsManager=t.CreateClassificationTemplateHeaders=t.CreateClassificationTemplateRequestBody=t.CreateClassificationTemplateRequestBodyFieldsField=t.UpdateClassificationHeaders=t.UpdateClassificationRequestBody=t.AddClassificationHeaders=t.AddClassificationRequestBody=t.GetClassificationTemplateHeaders=t.CreateClassificationTemplateOptionals=t.UpdateClassificationOptionals=t.AddClassificationOptionals=void 0,t.serializeAddClassificationRequestBodyOpField=x,t.deserializeAddClassificationRequestBodyOpField=S,t.serializeAddClassificationRequestBodyFieldKeyField=k,t.deserializeAddClassificationRequestBodyFieldKeyField=E,t.serializeAddClassificationRequestBodyDataStaticConfigClassificationField=T,t.deserializeAddClassificationRequestBodyDataStaticConfigClassificationField=B,t.serializeAddClassificationRequestBodyDataStaticConfigField=C,t.deserializeAddClassificationRequestBodyDataStaticConfigField=I,t.serializeAddClassificationRequestBodyDataField=A,t.deserializeAddClassificationRequestBodyDataField=F,t.serializeAddClassificationRequestBody=M,t.deserializeAddClassificationRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "AddClassificationRequestBody"'});if(null==e.op)throw new l.BoxSdkError({message:'Expecting "op" of type "AddClassificationRequestBody" to be defined'});const t=S(e.op);if(null==e.fieldKey)throw new l.BoxSdkError({message:'Expecting "fieldKey" of type "AddClassificationRequestBody" to be defined'});const r=E(e.fieldKey);if(null==e.data)throw new l.BoxSdkError({message:'Expecting "data" of type "AddClassificationRequestBody" to be defined'});const i=F(e.data);return{op:t,fieldKey:r,data:i}},t.serializeAddClassificationRequestBodyInput=function(e){return{op:null==e.op?void 0:e.op,fieldKey:null==e.fieldKey?void 0:e.fieldKey,data:A(e.data)}},t.deserializeAddClassificationRequestBodyInput=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "AddClassificationRequestBodyInput"'});const t=null==e.op?void 0:S(e.op),r=null==e.fieldKey?void 0:E(e.fieldKey);if(null==e.data)throw new l.BoxSdkError({message:'Expecting "data" of type "AddClassificationRequestBodyInput" to be defined'});const i=F(e.data);return{op:t,fieldKey:r,data:i}},t.serializeUpdateClassificationRequestBodyOpField=D,t.deserializeUpdateClassificationRequestBodyOpField=R,t.serializeUpdateClassificationRequestBodyFieldKeyField=P,t.deserializeUpdateClassificationRequestBodyFieldKeyField=O,t.serializeUpdateClassificationRequestBodyDataStaticConfigClassificationField=z,t.deserializeUpdateClassificationRequestBodyDataStaticConfigClassificationField=N,t.serializeUpdateClassificationRequestBodyDataStaticConfigField=q,t.deserializeUpdateClassificationRequestBodyDataStaticConfigField=U,t.serializeUpdateClassificationRequestBodyDataField=L,t.deserializeUpdateClassificationRequestBodyDataField=j,t.serializeUpdateClassificationRequestBody=H,t.deserializeUpdateClassificationRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UpdateClassificationRequestBody"'});if(null==e.op)throw new l.BoxSdkError({message:'Expecting "op" of type "UpdateClassificationRequestBody" to be defined'});const t=R(e.op);if(null==e.fieldKey)throw new l.BoxSdkError({message:'Expecting "fieldKey" of type "UpdateClassificationRequestBody" to be defined'});const r=O(e.fieldKey);if(null==e.enumOptionKey)throw new l.BoxSdkError({message:'Expecting "enumOptionKey" of type "UpdateClassificationRequestBody" to be defined'});if(!(0,u.sdIsString)(e.enumOptionKey))throw new l.BoxSdkError({message:'Expecting string for "enumOptionKey" of type "UpdateClassificationRequestBody"'});const i=e.enumOptionKey;if(null==e.data)throw new l.BoxSdkError({message:'Expecting "data" of type "UpdateClassificationRequestBody" to be defined'});const n=j(e.data);return{op:t,fieldKey:r,enumOptionKey:i,data:n}},t.serializeUpdateClassificationRequestBodyInput=function(e){return{op:null==e.op?void 0:e.op,fieldKey:null==e.fieldKey?void 0:e.fieldKey,enumOptionKey:e.enumOptionKey,data:L(e.data)}},t.deserializeUpdateClassificationRequestBodyInput=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UpdateClassificationRequestBodyInput"'});const t=null==e.op?void 0:R(e.op),r=null==e.fieldKey?void 0:O(e.fieldKey);if(null==e.enumOptionKey)throw new l.BoxSdkError({message:'Expecting "enumOptionKey" of type "UpdateClassificationRequestBodyInput" to be defined'});if(!(0,u.sdIsString)(e.enumOptionKey))throw new l.BoxSdkError({message:'Expecting string for "enumOptionKey" of type "UpdateClassificationRequestBodyInput"'});const i=e.enumOptionKey;if(null==e.data)throw new l.BoxSdkError({message:'Expecting "data" of type "UpdateClassificationRequestBodyInput" to be defined'});const n=j(e.data);return{op:t,fieldKey:r,enumOptionKey:i,data:n}},t.serializeCreateClassificationTemplateRequestBodyScopeField=$,t.deserializeCreateClassificationTemplateRequestBodyScopeField=G,t.serializeCreateClassificationTemplateRequestBodyTemplateKeyField=W,t.deserializeCreateClassificationTemplateRequestBodyTemplateKeyField=K,t.serializeCreateClassificationTemplateRequestBodyDisplayNameField=V,t.deserializeCreateClassificationTemplateRequestBodyDisplayNameField=J,t.serializeCreateClassificationTemplateRequestBodyFieldsTypeField=Y,t.deserializeCreateClassificationTemplateRequestBodyFieldsTypeField=Q,t.serializeCreateClassificationTemplateRequestBodyFieldsKeyField=Z,t.deserializeCreateClassificationTemplateRequestBodyFieldsKeyField=X,t.serializeCreateClassificationTemplateRequestBodyFieldsDisplayNameField=ee,t.deserializeCreateClassificationTemplateRequestBodyFieldsDisplayNameField=te,t.serializeCreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigClassificationField=re,t.deserializeCreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigClassificationField=ie,t.serializeCreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigField=ne,t.deserializeCreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigField=oe,t.serializeCreateClassificationTemplateRequestBodyFieldsOptionsField=se,t.deserializeCreateClassificationTemplateRequestBodyFieldsOptionsField=ae,t.serializeCreateClassificationTemplateRequestBodyFieldsField=le,t.deserializeCreateClassificationTemplateRequestBodyFieldsField=de,t.serializeCreateClassificationTemplateRequestBodyFieldsFieldInput=function(e){return{type:null==e.type?void 0:e.type,key:null==e.key?void 0:e.key,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,options:e.options.map((function(e){return se(e)}))}},t.deserializeCreateClassificationTemplateRequestBodyFieldsFieldInput=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyFieldsFieldInput"'});const t=null==e.type?void 0:Q(e.type),r=null==e.key?void 0:X(e.key),i=null==e.displayName?void 0:te(e.displayName);if(null!=e.hidden&&!(0,d.sdIsBoolean)(e.hidden))throw new l.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateClassificationTemplateRequestBodyFieldsFieldInput"'});const n=null==e.hidden?void 0:e.hidden;if(null==e.options)throw new l.BoxSdkError({message:'Expecting "options" of type "CreateClassificationTemplateRequestBodyFieldsFieldInput" to be defined'});if(!(0,p.sdIsList)(e.options))throw new l.BoxSdkError({message:'Expecting array for "options" of type "CreateClassificationTemplateRequestBodyFieldsFieldInput"'});const o=(0,p.sdIsList)(e.options)?e.options.map((function(e){return ae(e)})):[];return{type:t,key:r,displayName:i,hidden:n,options:o}},t.serializeCreateClassificationTemplateRequestBody=ce,t.deserializeCreateClassificationTemplateRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBody"'});if(null==e.scope)throw new l.BoxSdkError({message:'Expecting "scope" of type "CreateClassificationTemplateRequestBody" to be defined'});const t=G(e.scope);if(null==e.templateKey)throw new l.BoxSdkError({message:'Expecting "templateKey" of type "CreateClassificationTemplateRequestBody" to be defined'});const r=K(e.templateKey);if(null==e.displayName)throw new l.BoxSdkError({message:'Expecting "displayName" of type "CreateClassificationTemplateRequestBody" to be defined'});const i=J(e.displayName);if(null!=e.hidden&&!(0,d.sdIsBoolean)(e.hidden))throw new l.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateClassificationTemplateRequestBody"'});const n=null==e.hidden?void 0:e.hidden;if(null!=e.copyInstanceOnItemCopy&&!(0,d.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new l.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "CreateClassificationTemplateRequestBody"'});const o=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;if(null==e.fields)throw new l.BoxSdkError({message:'Expecting "fields" of type "CreateClassificationTemplateRequestBody" to be defined'});if(!(0,p.sdIsList)(e.fields))throw new l.BoxSdkError({message:'Expecting array for "fields" of type "CreateClassificationTemplateRequestBody"'});const s=(0,p.sdIsList)(e.fields)?e.fields.map((function(e){return de(e)})):[];return{scope:t,templateKey:r,displayName:i,hidden:n,copyInstanceOnItemCopy:o,fields:s}},t.serializeCreateClassificationTemplateRequestBodyInput=function(e){return{scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy,fields:e.fields.map((function(e){return le(e)}))}},t.deserializeCreateClassificationTemplateRequestBodyInput=function(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyInput"'});const t=null==e.scope?void 0:G(e.scope),r=null==e.templateKey?void 0:K(e.templateKey),i=null==e.displayName?void 0:J(e.displayName);if(null!=e.hidden&&!(0,d.sdIsBoolean)(e.hidden))throw new l.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateClassificationTemplateRequestBodyInput"'});const n=null==e.hidden?void 0:e.hidden;if(null!=e.copyInstanceOnItemCopy&&!(0,d.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new l.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "CreateClassificationTemplateRequestBodyInput"'});const o=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;if(null==e.fields)throw new l.BoxSdkError({message:'Expecting "fields" of type "CreateClassificationTemplateRequestBodyInput" to be defined'});if(!(0,p.sdIsList)(e.fields))throw new l.BoxSdkError({message:'Expecting array for "fields" of type "CreateClassificationTemplateRequestBodyInput"'});const s=(0,p.sdIsList)(e.fields)?e.fields.map((function(e){return de(e)})):[];return{scope:t,templateKey:r,displayName:i,hidden:n,copyInstanceOnItemCopy:o,fields:s}};const n=r(73146),o=r(31210),s=r(93845),a=r(84143),l=r(72631),d=r(50793),c=r(50793),u=r(50793),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddClassificationOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateClassificationOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateClassificationTemplateOptionals=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetClassificationTemplateHeaders=y;t.AddClassificationRequestBody=class{constructor(e){this.op="addEnumOption",this.fieldKey="Box__Security__Classification__Key",e.op&&(this.op=e.op),e.fieldKey&&(this.fieldKey=e.fieldKey),e.data&&(this.data=e.data),e.rawData&&(this.rawData=e.rawData)}};class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddClassificationHeaders=v;t.UpdateClassificationRequestBody=class{constructor(e){this.op="editEnumOption",this.fieldKey="Box__Security__Classification__Key",e.op&&(this.op=e.op),e.fieldKey&&(this.fieldKey=e.fieldKey),e.enumOptionKey&&(this.enumOptionKey=e.enumOptionKey),e.data&&(this.data=e.data),e.rawData&&(this.rawData=e.rawData)}};class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateClassificationHeaders=b;t.CreateClassificationTemplateRequestBodyFieldsField=class{constructor(e){this.type="enum",this.key="Box__Security__Classification__Key",this.displayName="Classification",e.type&&(this.type=e.type),e.key&&(this.key=e.key),e.displayName&&(this.displayName=e.displayName),e.hidden&&(this.hidden=e.hidden),e.options&&(this.options=e.options),e.rawData&&(this.rawData=e.rawData)}};class w{constructor(e){this.scope="enterprise",this.templateKey="securityClassification-6VMVochwUWo",this.displayName="Classification",e.scope&&(this.scope=e.scope),e.templateKey&&(this.templateKey=e.templateKey),e.displayName&&(this.displayName=e.displayName),e.hidden&&(this.hidden=e.hidden),e.copyInstanceOnItemCopy&&(this.copyInstanceOnItemCopy=e.copyInstanceOnItemCopy),e.fields&&(this.fields=e.fields),e.rawData&&(this.rawData=e.rawData)}}t.CreateClassificationTemplateRequestBody=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateClassificationTemplateHeaders=_;function x(e){return e}function S(e){if("addEnumOption"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize AddClassificationRequestBodyOpField"})}function k(e){return e}function E(e){if("Box__Security__Classification__Key"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize AddClassificationRequestBodyFieldKeyField"})}function T(e){return{classificationDefinition:null==e.classificationDefinition?void 0:e.classificationDefinition,colorID:null==e.colorId?void 0:e.colorId}}function B(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "AddClassificationRequestBodyDataStaticConfigClassificationField"'});if(null!=e.classificationDefinition&&!(0,u.sdIsString)(e.classificationDefinition))throw new l.BoxSdkError({message:'Expecting string for "classificationDefinition" of type "AddClassificationRequestBodyDataStaticConfigClassificationField"'});const t=null==e.classificationDefinition?void 0:e.classificationDefinition;if(null!=e.colorID&&!(0,c.sdIsNumber)(e.colorID))throw new l.BoxSdkError({message:'Expecting number for "colorID" of type "AddClassificationRequestBodyDataStaticConfigClassificationField"'});return{classificationDefinition:t,colorId:null==e.colorID?void 0:e.colorID}}function C(e){return{classification:null==e.classification?void 0:T(e.classification)}}function I(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "AddClassificationRequestBodyDataStaticConfigField"'});return{classification:null==e.classification?void 0:B(e.classification)}}function A(e){return{key:e.key,staticConfig:null==e.staticConfig?void 0:C(e.staticConfig)}}function F(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "AddClassificationRequestBodyDataField"'});if(null==e.key)throw new l.BoxSdkError({message:'Expecting "key" of type "AddClassificationRequestBodyDataField" to be defined'});if(!(0,u.sdIsString)(e.key))throw new l.BoxSdkError({message:'Expecting string for "key" of type "AddClassificationRequestBodyDataField"'});return{key:e.key,staticConfig:null==e.staticConfig?void 0:I(e.staticConfig)}}function M(e){return{op:e.op,fieldKey:e.fieldKey,data:A(e.data)}}function D(e){return e}function R(e){if("editEnumOption"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize UpdateClassificationRequestBodyOpField"})}function P(e){return e}function O(e){if("Box__Security__Classification__Key"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize UpdateClassificationRequestBodyFieldKeyField"})}function z(e){return{classificationDefinition:null==e.classificationDefinition?void 0:e.classificationDefinition,colorID:null==e.colorId?void 0:e.colorId}}function N(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UpdateClassificationRequestBodyDataStaticConfigClassificationField"'});if(null!=e.classificationDefinition&&!(0,u.sdIsString)(e.classificationDefinition))throw new l.BoxSdkError({message:'Expecting string for "classificationDefinition" of type "UpdateClassificationRequestBodyDataStaticConfigClassificationField"'});const t=null==e.classificationDefinition?void 0:e.classificationDefinition;if(null!=e.colorID&&!(0,c.sdIsNumber)(e.colorID))throw new l.BoxSdkError({message:'Expecting number for "colorID" of type "UpdateClassificationRequestBodyDataStaticConfigClassificationField"'});return{classificationDefinition:t,colorId:null==e.colorID?void 0:e.colorID}}function q(e){return{classification:null==e.classification?void 0:z(e.classification)}}function U(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UpdateClassificationRequestBodyDataStaticConfigField"'});return{classification:null==e.classification?void 0:N(e.classification)}}function L(e){return{key:e.key,staticConfig:null==e.staticConfig?void 0:q(e.staticConfig)}}function j(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UpdateClassificationRequestBodyDataField"'});if(null==e.key)throw new l.BoxSdkError({message:'Expecting "key" of type "UpdateClassificationRequestBodyDataField" to be defined'});if(!(0,u.sdIsString)(e.key))throw new l.BoxSdkError({message:'Expecting string for "key" of type "UpdateClassificationRequestBodyDataField"'});return{key:e.key,staticConfig:null==e.staticConfig?void 0:U(e.staticConfig)}}function H(e){return{op:e.op,fieldKey:e.fieldKey,enumOptionKey:e.enumOptionKey,data:L(e.data)}}function $(e){return e}function G(e){if("enterprise"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyScopeField"})}function W(e){return e}function K(e){if("securityClassification-6VMVochwUWo"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyTemplateKeyField"})}function V(e){return e}function J(e){if("Classification"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyDisplayNameField"})}function Y(e){return e}function Q(e){if("enum"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyFieldsTypeField"})}function Z(e){return e}function X(e){if("Box__Security__Classification__Key"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyFieldsKeyField"})}function ee(e){return e}function te(e){if("Classification"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize CreateClassificationTemplateRequestBodyFieldsDisplayNameField"})}function re(e){return{classificationDefinition:null==e.classificationDefinition?void 0:e.classificationDefinition,colorID:null==e.colorId?void 0:e.colorId}}function ie(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigClassificationField"'});if(null!=e.classificationDefinition&&!(0,u.sdIsString)(e.classificationDefinition))throw new l.BoxSdkError({message:'Expecting string for "classificationDefinition" of type "CreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigClassificationField"'});const t=null==e.classificationDefinition?void 0:e.classificationDefinition;if(null!=e.colorID&&!(0,c.sdIsNumber)(e.colorID))throw new l.BoxSdkError({message:'Expecting number for "colorID" of type "CreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigClassificationField"'});return{classificationDefinition:t,colorId:null==e.colorID?void 0:e.colorID}}function ne(e){return{classification:null==e.classification?void 0:re(e.classification)}}function oe(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyFieldsOptionsStaticConfigField"'});return{classification:null==e.classification?void 0:ie(e.classification)}}function se(e){return{key:e.key,staticConfig:null==e.staticConfig?void 0:ne(e.staticConfig)}}function ae(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyFieldsOptionsField"'});if(null==e.key)throw new l.BoxSdkError({message:'Expecting "key" of type "CreateClassificationTemplateRequestBodyFieldsOptionsField" to be defined'});if(!(0,u.sdIsString)(e.key))throw new l.BoxSdkError({message:'Expecting string for "key" of type "CreateClassificationTemplateRequestBodyFieldsOptionsField"'});return{key:e.key,staticConfig:null==e.staticConfig?void 0:oe(e.staticConfig)}}function le(e){return{type:e.type,key:e.key,displayName:e.displayName,hidden:null==e.hidden?void 0:e.hidden,options:e.options.map((function(e){return se(e)}))}}function de(e){if(!(0,h.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CreateClassificationTemplateRequestBodyFieldsField"'});if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "CreateClassificationTemplateRequestBodyFieldsField" to be defined'});const t=Q(e.type);if(null==e.key)throw new l.BoxSdkError({message:'Expecting "key" of type "CreateClassificationTemplateRequestBodyFieldsField" to be defined'});const r=X(e.key);if(null==e.displayName)throw new l.BoxSdkError({message:'Expecting "displayName" of type "CreateClassificationTemplateRequestBodyFieldsField" to be defined'});const i=te(e.displayName);if(null!=e.hidden&&!(0,d.sdIsBoolean)(e.hidden))throw new l.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateClassificationTemplateRequestBodyFieldsField"'});const n=null==e.hidden?void 0:e.hidden;if(null==e.options)throw new l.BoxSdkError({message:'Expecting "options" of type "CreateClassificationTemplateRequestBodyFieldsField" to be defined'});if(!(0,p.sdIsList)(e.options))throw new l.BoxSdkError({message:'Expecting array for "options" of type "CreateClassificationTemplateRequestBodyFieldsField"'});return{type:t,key:r,displayName:i,hidden:n,options:(0,p.sdIsList)(e.options)?e.options.map((function(e){return ae(e)})):[]}}function ce(e){return{scope:e.scope,templateKey:e.templateKey,displayName:e.displayName,hidden:null==e.hidden?void 0:e.hidden,copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy,fields:e.fields.map((function(e){return le(e)}))}}t.ClassificationsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getClassificationTemplate(){return i(this,arguments,void 0,(function*(e=new y({}),t){const r=new y({extraHeaders:e.extraHeaders}),i=(0,s.prepareParams)(Object.assign({},r.extraHeaders)),o=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/enterprise/securityClassification-6VMVochwUWo/schema"),method:"GET",headers:i,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:t});return Object.assign(Object.assign({},(0,n.deserializeClassificationTemplate)(o.data)),{rawData:o.data})}))}addClassification(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,l=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/enterprise/securityClassification-6VMVochwUWo/schema#add"),method:"PUT",headers:l,data:e.map(M),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeClassificationTemplate)(d.data)),{rawData:d.data})}))}updateClassification(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,l=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/enterprise/securityClassification-6VMVochwUWo/schema#update"),method:"PUT",headers:l,data:e.map(H),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeClassificationTemplate)(d.data)),{rawData:d.data})}))}createClassificationTemplate(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({scope:e.scope,templateKey:e.templateKey,displayName:e.displayName,hidden:e.hidden,copyInstanceOnItemCopy:e.copyInstanceOnItemCopy,fields:e.fields}),i=new g({headers:t.headers,cancellationToken:t.cancellationToken}),o=i.headers,l=i.cancellationToken,d=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),c=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/schema#classifications"),method:"POST",headers:d,data:ce(r),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:l});return Object.assign(Object.assign({},(0,n.deserializeClassificationTemplate)(c.data)),{rawData:c.data})}))}}},86008:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.CollaborationAllowlistEntriesManager=t.DeleteCollaborationWhitelistEntryByIdHeaders=t.GetCollaborationWhitelistEntryByIdHeaders=t.CreateCollaborationWhitelistEntryHeaders=t.GetCollaborationWhitelistEntriesHeaders=t.DeleteCollaborationWhitelistEntryByIdOptionals=t.GetCollaborationWhitelistEntryByIdOptionals=t.CreateCollaborationWhitelistEntryOptionals=void 0,t.serializeCreateCollaborationWhitelistEntryRequestBodyDirectionField=w,t.deserializeCreateCollaborationWhitelistEntryRequestBodyDirectionField=_,t.serializeCreateCollaborationWhitelistEntryRequestBody=x,t.deserializeCreateCollaborationWhitelistEntryRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateCollaborationWhitelistEntryRequestBody"'});if(null==e.domain)throw new c.BoxSdkError({message:'Expecting "domain" of type "CreateCollaborationWhitelistEntryRequestBody" to be defined'});if(!(0,u.sdIsString)(e.domain))throw new c.BoxSdkError({message:'Expecting string for "domain" of type "CreateCollaborationWhitelistEntryRequestBody"'});const t=e.domain;if(null==e.direction)throw new c.BoxSdkError({message:'Expecting "direction" of type "CreateCollaborationWhitelistEntryRequestBody" to be defined'});const r=_(e.direction);return{domain:t,direction:r}};const n=r(36958),o=r(66774),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateCollaborationWhitelistEntryOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCollaborationWhitelistEntryByIdOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteCollaborationWhitelistEntryByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationWhitelistEntriesHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateCollaborationWhitelistEntryHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationWhitelistEntryByIdHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteCollaborationWhitelistEntryByIdHeaders=b;function w(e){return e}function _(e){if("inbound"==e)return e;if("outbound"==e)return e;if("both"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateCollaborationWhitelistEntryRequestBodyDirectionField"})}function x(e){return{domain:e.domain,direction:e.direction}}t.CollaborationAllowlistEntriesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getCollaborationWhitelistEntries(){return i(this,arguments,void 0,(function*(e={},t=new g({}),r){const i=new g({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_entries"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeCollaborationAllowlistEntries)(c.data)),{rawData:c.data})}))}createCollaborationWhitelistEntry(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_entries"),method:"POST",headers:s,data:x(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeCollaborationAllowlistEntry)(l.data)),{rawData:l.data})}))}getCollaborationWhitelistEntryById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_entries/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeCollaborationAllowlistEntry)(c.data)),{rawData:c.data})}))}deleteCollaborationWhitelistEntryById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_entries/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},99871:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.CollaborationAllowlistExemptTargetsManager=t.DeleteCollaborationWhitelistExemptTargetByIdHeaders=t.GetCollaborationWhitelistExemptTargetByIdHeaders=t.CreateCollaborationWhitelistExemptTargetHeaders=t.GetCollaborationWhitelistExemptTargetsHeaders=t.DeleteCollaborationWhitelistExemptTargetByIdOptionals=t.GetCollaborationWhitelistExemptTargetByIdOptionals=t.CreateCollaborationWhitelistExemptTargetOptionals=void 0,t.serializeCreateCollaborationWhitelistExemptTargetRequestBodyUserField=w,t.deserializeCreateCollaborationWhitelistExemptTargetRequestBodyUserField=_,t.serializeCreateCollaborationWhitelistExemptTargetRequestBody=x,t.deserializeCreateCollaborationWhitelistExemptTargetRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateCollaborationWhitelistExemptTargetRequestBody"'});if(null==e.user)throw new c.BoxSdkError({message:'Expecting "user" of type "CreateCollaborationWhitelistExemptTargetRequestBody" to be defined'});return{user:_(e.user)}};const n=r(38333),o=r(92720),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateCollaborationWhitelistExemptTargetOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCollaborationWhitelistExemptTargetByIdOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteCollaborationWhitelistExemptTargetByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationWhitelistExemptTargetsHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateCollaborationWhitelistExemptTargetHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationWhitelistExemptTargetByIdHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteCollaborationWhitelistExemptTargetByIdHeaders=b;function w(e){return{id:e.id}}function _(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateCollaborationWhitelistExemptTargetRequestBodyUserField"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateCollaborationWhitelistExemptTargetRequestBodyUserField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateCollaborationWhitelistExemptTargetRequestBodyUserField"'});return{id:e.id}}function x(e){return{user:w(e.user)}}t.CollaborationAllowlistExemptTargetsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getCollaborationWhitelistExemptTargets(){return i(this,arguments,void 0,(function*(e={},t=new g({}),r){const i=new g({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_exempt_targets"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeCollaborationAllowlistExemptTargets)(c.data)),{rawData:c.data})}))}createCollaborationWhitelistExemptTarget(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_exempt_targets"),method:"POST",headers:s,data:x(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeCollaborationAllowlistExemptTarget)(l.data)),{rawData:l.data})}))}getCollaborationWhitelistExemptTargetById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_exempt_targets/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeCollaborationAllowlistExemptTarget)(c.data)),{rawData:c.data})}))}deleteCollaborationWhitelistExemptTargetById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaboration_whitelist_exempt_targets/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},98355:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.CollectionsManager=t.GetCollectionItemsHeaders=t.GetCollectionsHeaders=t.GetCollectionItemsOptionals=void 0;const n=r(6421),o=r(61664),s=r(31210),a=r(93845),l=r(93845),d=r(84143);class c{constructor(e){this.queryParams={},this.headers=new p({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCollectionItemsOptionals=c;class u{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollectionsHeaders=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollectionItemsHeaders=p;t.CollectionsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getCollections(){return i(this,arguments,void 0,(function*(e={},t=new u({}),r){const i=new u({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({fields:e.fields?e.fields.map(l.toString).join(","):void 0,offset:(0,l.toString)(e.offset),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collections"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeCollections)(c.data)),{rawData:c.data})}))}getCollectionItems(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,u=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0,offset:(0,l.toString)(i.offset),limit:(0,l.toString)(i.limit)}),p=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collections/",(0,l.toString)(e),"/items"),method:"GET",params:u,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeItems)(h.data)),{rawData:h.data})}))}}},78812:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.CommentsManager=t.CreateCommentHeaders=t.DeleteCommentByIdHeaders=t.UpdateCommentByIdHeaders=t.GetCommentByIdHeaders=t.GetFileCommentsHeaders=t.CreateCommentOptionals=t.DeleteCommentByIdOptionals=t.UpdateCommentByIdOptionals=t.GetCommentByIdOptionals=t.GetFileCommentsOptionals=void 0,t.serializeUpdateCommentByIdRequestBody=S,t.deserializeUpdateCommentByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateCommentByIdRequestBody"'});if(null!=e.message&&!(0,u.sdIsString)(e.message))throw new c.BoxSdkError({message:'Expecting string for "message" of type "UpdateCommentByIdRequestBody"'});return{message:null==e.message?void 0:e.message}},t.serializeCreateCommentRequestBodyItemTypeField=k,t.deserializeCreateCommentRequestBodyItemTypeField=E,t.serializeCreateCommentRequestBodyItemField=T,t.deserializeCreateCommentRequestBodyItemField=B,t.serializeCreateCommentRequestBody=C,t.deserializeCreateCommentRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateCommentRequestBody"'});if(null==e.message)throw new c.BoxSdkError({message:'Expecting "message" of type "CreateCommentRequestBody" to be defined'});if(!(0,u.sdIsString)(e.message))throw new c.BoxSdkError({message:'Expecting string for "message" of type "CreateCommentRequestBody"'});const t=e.message;if(null!=e.tagged_message&&!(0,u.sdIsString)(e.tagged_message))throw new c.BoxSdkError({message:'Expecting string for "tagged_message" of type "CreateCommentRequestBody"'});const r=null==e.tagged_message?void 0:e.tagged_message;if(null==e.item)throw new c.BoxSdkError({message:'Expecting "item" of type "CreateCommentRequestBody" to be defined'});const i=B(e.item);return{message:t,taggedMessage:r,item:i}};const n=r(2346),o=r(83496),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.queryParams={},this.headers=new v({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileCommentsOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new b({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCommentByIdOptionals=f;class m{constructor(e){this.requestBody={},this.queryParams={},this.headers=new w({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateCommentByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteCommentByIdOptionals=g;class y{constructor(e){this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateCommentOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileCommentsHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCommentByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateCommentByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteCommentByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateCommentHeaders=x;function S(e){return{message:null==e.message?void 0:e.message}}function k(e){return e}function E(e){if("file"==e)return e;if("comment"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateCommentRequestBodyItemTypeField"})}function T(e){return{id:e.id,type:e.type}}function B(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateCommentRequestBodyItemField"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateCommentRequestBodyItemField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateCommentRequestBodyItemField"'});const t=e.id;if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateCommentRequestBodyItemField" to be defined'});return{id:t,type:E(e.type)}}function C(e){return{message:e.message,tagged_message:null==e.taggedMessage?void 0:e.taggedMessage,item:T(e.item)}}t.CommentsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileComments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0,limit:(0,l.toString)(i.limit),offset:(0,l.toString)(i.offset)}),u=(0,a.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/comments"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeComments)(p.data)),{rawData:p.data})}))}getCommentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/comments/",(0,l.toString)(e)),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeCommentFull)(p.data)),{rawData:p.data})}))}updateCommentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:n.fields?n.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/comments/",(0,l.toString)(e)),method:"PUT",params:u,headers:p,data:S(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeCommentFull)(h.data)),{rawData:h.data})}))}deleteCommentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/comments/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}createComment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/comments"),method:"POST",params:c,headers:u,data:C(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeCommentFull)(p.data)),{rawData:p.data})}))}}},72865:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.DevicePinnersManager=t.GetEnterpriseDevicePinnersHeaders=t.DeleteDevicePinnerByIdHeaders=t.GetDevicePinnerByIdHeaders=t.GetEnterpriseDevicePinnersOptionals=t.DeleteDevicePinnerByIdOptionals=t.GetDevicePinnerByIdOptionals=void 0,t.serializeGetEnterpriseDevicePinnersQueryParamsDirectionField=function(e){return e},t.deserializeGetEnterpriseDevicePinnersQueryParamsDirectionField=function(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetEnterpriseDevicePinnersQueryParamsDirectionField"})};const n=r(1294),o=r(10931),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631);class u{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetDevicePinnerByIdOptionals=u;class p{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteDevicePinnerByIdOptionals=p;class h{constructor(e){this.queryParams={},this.headers=new g({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetEnterpriseDevicePinnersOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetDevicePinnerByIdHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteDevicePinnerByIdHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetEnterpriseDevicePinnersHeaders=g;t.DevicePinnersManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getDevicePinnerById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/device_pinners/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeDevicePinner)(c.data)),{rawData:c.data})}))}deleteDevicePinnerById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/device_pinners/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getEnterpriseDevicePinners(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({marker:(0,l.toString)(i.marker),limit:(0,l.toString)(i.limit),direction:(0,l.toString)(i.direction)}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/enterprises/",(0,l.toString)(e),"/device_pinners"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeDevicePinners)(p.data)),{rawData:p.data})}))}}},82083:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.DownloadsManager=t.DownloadFileHeaders=t.DownloadFileOptionals=void 0;const n=r(31210),o=r(93845),s=r(93845),a=r(84143);class l{constructor(e){this.queryParams={},this.headers=new d({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DownloadFileOptionals=l;class d{constructor(e){this.extraHeaders={},e.range&&(this.range=e.range),e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DownloadFileHeaders=d;t.DownloadsManager=class{constructor(e){this.networkSession=new n.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}downloadFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new l({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,d=r.cancellationToken,c=(0,o.prepareParams)({version:(0,s.toString)(i.version),access_token:(0,s.toString)(i.accessToken)}),u=(0,o.prepareParams)(Object.assign({range:(0,s.toString)(n.range),boxapi:(0,s.toString)(n.boxapi)},n.extraHeaders));return(yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,s.toString)(e),"/content"),method:"GET",params:c,headers:u,responseFormat:"binary",auth:this.auth,networkSession:this.networkSession,cancellationToken:d})).content}))}}},16822:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.EmailAliasesManager=t.DeleteUserEmailAliasByIdHeaders=t.CreateUserEmailAliasHeaders=t.GetUserEmailAliasesHeaders=t.DeleteUserEmailAliasByIdOptionals=t.CreateUserEmailAliasOptionals=t.GetUserEmailAliasesOptionals=void 0,t.serializeCreateUserEmailAliasRequestBody=b,t.deserializeCreateUserEmailAliasRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateUserEmailAliasRequestBody"'});if(null==e.email)throw new c.BoxSdkError({message:'Expecting "email" of type "CreateUserEmailAliasRequestBody" to be defined'});if(!(0,u.sdIsString)(e.email))throw new c.BoxSdkError({message:'Expecting string for "email" of type "CreateUserEmailAliasRequestBody"'});return{email:e.email}};const n=r(50756),o=r(99152),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetUserEmailAliasesOptionals=h;class f{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateUserEmailAliasOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteUserEmailAliasByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUserEmailAliasesHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateUserEmailAliasHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteUserEmailAliasByIdHeaders=v;function b(e){return{email:e.email}}t.EmailAliasesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getUserEmailAliases(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,l.toString)(e),"/email_aliases"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeEmailAliases)(c.data)),{rawData:c.data})}))}createUserEmailAlias(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new f({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,s=i.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,l.toString)(e),"/email_aliases"),method:"POST",headers:c,data:b(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeEmailAlias)(u.data)),{rawData:u.data})}))}deleteUserEmailAliasById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new m({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,a.prepareParams)(Object.assign({},n.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,l.toString)(e),"/email_aliases/",(0,l.toString)(t)),method:"DELETE",headers:s,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}}},31591:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.EventsManager=t.GetEventsHeaders=t.GetEventsWithLongPollingHeaders=void 0,t.serializeGetEventsQueryParamsStreamTypeField=function(e){return e},t.deserializeGetEventsQueryParamsStreamTypeField=function(e){if("all"==e)return e;if("changes"==e)return e;if("sync"==e)return e;if("admin_logs"==e)return e;if("admin_logs_streaming"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize GetEventsQueryParamsStreamTypeField"})},t.serializeGetEventsQueryParamsEventTypeField=function(e){return e},t.deserializeGetEventsQueryParamsEventTypeField=function(e){if("ACCESS_GRANTED"==e)return e;if("ACCESS_REVOKED"==e)return e;if("ADD_DEVICE_ASSOCIATION"==e)return e;if("ADD_LOGIN_ACTIVITY_DEVICE"==e)return e;if("ADMIN_LOGIN"==e)return e;if("APPLICATION_CREATED"==e)return e;if("APPLICATION_PUBLIC_KEY_ADDED"==e)return e;if("APPLICATION_PUBLIC_KEY_DELETED"==e)return e;if("CHANGE_ADMIN_ROLE"==e)return e;if("CHANGE_FOLDER_PERMISSION"==e)return e;if("COLLABORATION_ACCEPT"==e)return e;if("COLLABORATION_EXPIRATION"==e)return e;if("COLLABORATION_INVITE"==e)return e;if("COLLABORATION_REMOVE"==e)return e;if("COLLABORATION_ROLE_CHANGE"==e)return e;if("COMMENT_CREATE"==e)return e;if("COMMENT_DELETE"==e)return e;if("CONTENT_WORKFLOW_ABNORMAL_DOWNLOAD_ACTIVITY"==e)return e;if("CONTENT_WORKFLOW_AUTOMATION_ADD"==e)return e;if("CONTENT_WORKFLOW_AUTOMATION_DELETE"==e)return e;if("CONTENT_WORKFLOW_POLICY_ADD"==e)return e;if("CONTENT_WORKFLOW_SHARING_POLICY_VIOLATION"==e)return e;if("CONTENT_WORKFLOW_UPLOAD_POLICY_VIOLATION"==e)return e;if("COPY"==e)return e;if("DATA_RETENTION_CREATE_RETENTION"==e)return e;if("DATA_RETENTION_REMOVE_RETENTION"==e)return e;if("DELETE"==e)return e;if("DELETE_USER"==e)return e;if("DEVICE_TRUST_CHECK_FAILED"==e)return e;if("DOWNLOAD"==e)return e;if("EDIT"==e)return e;if("EDIT_USER"==e)return e;if("EMAIL_ALIAS_CONFIRM"==e)return e;if("EMAIL_ALIAS_REMOVE"==e)return e;if("ENTERPRISE_APP_AUTHORIZATION_UPDATE"==e)return e;if("EXTERNAL_COLLAB_SECURITY_SETTINGS"==e)return e;if("FAILED_LOGIN"==e)return e;if("FILE_MARKED_MALICIOUS"==e)return e;if("FILE_WATERMARKED_DOWNLOAD"==e)return e;if("GROUP_ADD_ITEM"==e)return e;if("GROUP_ADD_USER"==e)return e;if("GROUP_CREATION"==e)return e;if("GROUP_DELETION"==e)return e;if("GROUP_EDITED"==e)return e;if("GROUP_REMOVE_ITEM"==e)return e;if("GROUP_REMOVE_USER"==e)return e;if("ITEM_EMAIL_SEND"==e)return e;if("ITEM_MODIFY"==e)return e;if("ITEM_OPEN"==e)return e;if("ITEM_SHARED_UPDATE"==e)return e;if("ITEM_SYNC"==e)return e;if("ITEM_UNSYNC"==e)return e;if("LEGAL_HOLD_ASSIGNMENT_CREATE"==e)return e;if("LEGAL_HOLD_ASSIGNMENT_DELETE"==e)return e;if("LEGAL_HOLD_POLICY_CREATE"==e)return e;if("LEGAL_HOLD_POLICY_DELETE"==e)return e;if("LEGAL_HOLD_POLICY_UPDATE"==e)return e;if("LOCK"==e)return e;if("LOGIN"==e)return e;if("METADATA_INSTANCE_CREATE"==e)return e;if("METADATA_INSTANCE_DELETE"==e)return e;if("METADATA_INSTANCE_UPDATE"==e)return e;if("METADATA_TEMPLATE_CREATE"==e)return e;if("METADATA_TEMPLATE_DELETE"==e)return e;if("METADATA_TEMPLATE_UPDATE"==e)return e;if("MOVE"==e)return e;if("NEW_USER"==e)return e;if("OAUTH2_ACCESS_TOKEN_REVOKE"==e)return e;if("PREVIEW"==e)return e;if("REMOVE_DEVICE_ASSOCIATION"==e)return e;if("REMOVE_LOGIN_ACTIVITY_DEVICE"==e)return e;if("RENAME"==e)return e;if("RETENTION_POLICY_ASSIGNMENT_ADD"==e)return e;if("SHARE"==e)return e;if("SHARED_LINK_SEND"==e)return e;if("SHARE_EXPIRATION"==e)return e;if("SHIELD_ALERT"==e)return e;if("SHIELD_EXTERNAL_COLLAB_ACCESS_BLOCKED"==e)return e;if("SHIELD_EXTERNAL_COLLAB_ACCESS_BLOCKED_MISSING_JUSTIFICATION"==e)return e;if("SHIELD_EXTERNAL_COLLAB_INVITE_BLOCKED"==e)return e;if("SHIELD_EXTERNAL_COLLAB_INVITE_BLOCKED_MISSING_JUSTIFICATION"==e)return e;if("SHIELD_JUSTIFICATION_APPROVAL"==e)return e;if("SHIELD_SHARED_LINK_ACCESS_BLOCKED"==e)return e;if("SHIELD_SHARED_LINK_STATUS_RESTRICTED_ON_CREATE"==e)return e;if("SHIELD_SHARED_LINK_STATUS_RESTRICTED_ON_UPDATE"==e)return e;if("SIGN_DOCUMENT_ASSIGNED"==e)return e;if("SIGN_DOCUMENT_CANCELLED"==e)return e;if("SIGN_DOCUMENT_COMPLETED"==e)return e;if("SIGN_DOCUMENT_CONVERTED"==e)return e;if("SIGN_DOCUMENT_CREATED"==e)return e;if("SIGN_DOCUMENT_DECLINED"==e)return e;if("SIGN_DOCUMENT_EXPIRED"==e)return e;if("SIGN_DOCUMENT_SIGNED"==e)return e;if("SIGN_DOCUMENT_VIEWED_BY_SIGNED"==e)return e;if("SIGNER_DOWNLOADED"==e)return e;if("SIGNER_FORWARDED"==e)return e;if("STORAGE_EXPIRATION"==e)return e;if("TASK_ASSIGNMENT_CREATE"==e)return e;if("TASK_ASSIGNMENT_DELETE"==e)return e;if("TASK_ASSIGNMENT_UPDATE"==e)return e;if("TASK_CREATE"==e)return e;if("TASK_UPDATE"==e)return e;if("TERMS_OF_SERVICE_ACCEPT"==e)return e;if("TERMS_OF_SERVICE_REJECT"==e)return e;if("UNDELETE"==e)return e;if("UNLOCK"==e)return e;if("UNSHARE"==e)return e;if("UPDATE_COLLABORATION_EXPIRATION"==e)return e;if("UPDATE_SHARE_EXPIRATION"==e)return e;if("UPLOAD"==e)return e;if("USER_AUTHENTICATE_OAUTH2_ACCESS_TOKEN_CREATE"==e)return e;if("WATERMARK_LABEL_CREATE"==e)return e;if("WATERMARK_LABEL_DELETE"==e)return e;if((0,p.sdIsString)(e))return e;throw new u.BoxSdkError({message:"Can't deserialize GetEventsQueryParamsEventTypeField"})};const n=r(15135),o=r(3025),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793);class h{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetEventsWithLongPollingHeaders=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetEventsHeaders=f;t.EventsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getEventsWithLongPolling(){return i(this,arguments,void 0,(function*(e=new h({}),t){const r=new h({extraHeaders:e.extraHeaders}),i=(0,l.prepareParams)(Object.assign({},r.extraHeaders)),o=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/events"),method:"OPTIONS",headers:i,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:t});return Object.assign(Object.assign({},(0,n.deserializeRealtimeServers)(o.data)),{rawData:o.data})}))}getEvents(){return i(this,arguments,void 0,(function*(e={},t=new f({}),r){const i=new f({extraHeaders:t.extraHeaders}),n=(0,l.prepareParams)({stream_type:(0,d.toString)(e.streamType),stream_position:(0,d.toString)(e.streamPosition),limit:(0,d.toString)(e.limit),event_type:e.eventType?e.eventType.map(d.toString).join(","):void 0,created_after:e.createdAfter?(0,s.serializeDateTime)(e.createdAfter):void 0,created_before:e.createdBefore?(0,s.serializeDateTime)(e.createdBefore):void 0}),a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/events"),method:"GET",params:n,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,o.deserializeEvents)(u.data)),{rawData:u.data})}))}}},96913:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileClassificationsManager=t.DeleteClassificationFromFileHeaders=t.UpdateClassificationOnFileHeaders=t.UpdateClassificationOnFileRequestBody=t.AddClassificationToFileHeaders=t.GetClassificationOnFileHeaders=t.DeleteClassificationFromFileOptionals=t.UpdateClassificationOnFileOptionals=t.AddClassificationToFileOptionals=t.GetClassificationOnFileOptionals=void 0,t.serializeAddClassificationToFileRequestBody=w,t.deserializeAddClassificationToFileRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "AddClassificationToFileRequestBody"'});if(null!=e.Box__Security__Classification__Key&&!(0,c.sdIsString)(e.Box__Security__Classification__Key))throw new d.BoxSdkError({message:'Expecting string for "Box__Security__Classification__Key" of type "AddClassificationToFileRequestBody"'});return{boxSecurityClassificationKey:null==e.Box__Security__Classification__Key?void 0:e.Box__Security__Classification__Key}},t.serializeUpdateClassificationOnFileRequestBodyOpField=_,t.deserializeUpdateClassificationOnFileRequestBodyOpField=x,t.serializeUpdateClassificationOnFileRequestBodyPathField=S,t.deserializeUpdateClassificationOnFileRequestBodyPathField=k,t.serializeUpdateClassificationOnFileRequestBody=E,t.deserializeUpdateClassificationOnFileRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateClassificationOnFileRequestBody"'});if(null==e.op)throw new d.BoxSdkError({message:'Expecting "op" of type "UpdateClassificationOnFileRequestBody" to be defined'});const t=x(e.op);if(null==e.path)throw new d.BoxSdkError({message:'Expecting "path" of type "UpdateClassificationOnFileRequestBody" to be defined'});const r=k(e.path);if(null==e.value)throw new d.BoxSdkError({message:'Expecting "value" of type "UpdateClassificationOnFileRequestBody" to be defined'});if(!(0,c.sdIsString)(e.value))throw new d.BoxSdkError({message:'Expecting string for "value" of type "UpdateClassificationOnFileRequestBody"'});const i=e.value;return{op:t,path:r,value:i}},t.serializeUpdateClassificationOnFileRequestBodyInput=function(e){return{op:null==e.op?void 0:e.op,path:null==e.path?void 0:e.path,value:e.value}},t.deserializeUpdateClassificationOnFileRequestBodyInput=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateClassificationOnFileRequestBodyInput"'});const t=null==e.op?void 0:x(e.op),r=null==e.path?void 0:k(e.path);if(null==e.value)throw new d.BoxSdkError({message:'Expecting "value" of type "UpdateClassificationOnFileRequestBodyInput" to be defined'});if(!(0,c.sdIsString)(e.value))throw new d.BoxSdkError({message:'Expecting string for "value" of type "UpdateClassificationOnFileRequestBodyInput"'});const i=e.value;return{op:t,path:r,value:i}};const n=r(78748),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793),u=r(50793);class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetClassificationOnFileOptionals=p;class h{constructor(e){this.requestBody={},this.headers=new y({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddClassificationToFileOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateClassificationOnFileOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteClassificationFromFileOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetClassificationOnFileHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddClassificationToFileHeaders=y;t.UpdateClassificationOnFileRequestBody=class{constructor(e){this.op="replace",this.path="/Box__Security__Classification__Key",e.op&&(this.op=e.op),e.path&&(this.path=e.path),e.value&&(this.value=e.value),e.rawData&&(this.rawData=e.rawData)}};class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateClassificationOnFileHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteClassificationFromFileHeaders=b;function w(e){return{Box__Security__Classification__Key:null==e.boxSecurityClassificationKey?void 0:e.boxSecurityClassificationKey}}function _(e){return e}function x(e){if("replace"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateClassificationOnFileRequestBodyOpField"})}function S(e){return e}function k(e){if("/Box__Security__Classification__Key"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateClassificationOnFileRequestBodyPathField"})}function E(e){return{op:e.op,path:e.path,value:e.value}}t.FileClassificationsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getClassificationOnFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,d=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"GET",headers:d,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeClassification)(c.data)),{rawData:c.data})}))}addClassificationToFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"POST",headers:c,data:w(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeClassification)(u.data)),{rawData:u.data})}))}updateClassificationOnFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new f({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,d=i.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"PUT",headers:c,data:t.map(E),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeClassification)(u.data)),{rawData:u.data})}))}deleteClassificationFromFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},69085:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileMetadataManager=t.DeleteFileMetadataByIdHeaders=t.UpdateFileMetadataByIdHeaders=t.CreateFileMetadataByIdHeaders=t.GetFileMetadataByIdHeaders=t.GetFileMetadataHeaders=t.DeleteFileMetadataByIdOptionals=t.UpdateFileMetadataByIdOptionals=t.CreateFileMetadataByIdOptionals=t.GetFileMetadataByIdOptionals=t.GetFileMetadataOptionals=void 0,t.serializeGetFileMetadataByIdScope=function(e){return e},t.deserializeGetFileMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetFileMetadataByIdScope"})},t.serializeCreateFileMetadataByIdScope=function(e){return e},t.deserializeCreateFileMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateFileMetadataByIdScope"})},t.serializeCreateFileMetadataByIdRequestBody=S,t.deserializeCreateFileMetadataByIdRequestBody=function(e){return(0,p.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t]))):{}},t.serializeUpdateFileMetadataByIdScope=function(e){return e},t.deserializeUpdateFileMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateFileMetadataByIdScope"})},t.serializeUpdateFileMetadataByIdRequestBodyOpField=k,t.deserializeUpdateFileMetadataByIdRequestBodyOpField=E,t.serializeUpdateFileMetadataByIdRequestBody=T,t.deserializeUpdateFileMetadataByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateFileMetadataByIdRequestBody"'});const t=null==e.op?void 0:E(e.op);if(null!=e.path&&!(0,u.sdIsString)(e.path))throw new c.BoxSdkError({message:'Expecting string for "path" of type "UpdateFileMetadataByIdRequestBody"'});const r=null==e.path?void 0:e.path;if(null!=e.value&&!(0,u.sdIsString)(e.value))throw new c.BoxSdkError({message:'Expecting string for "value" of type "UpdateFileMetadataByIdRequestBody"'});const i=null==e.value?void 0:e.value;if(null!=e.from&&!(0,u.sdIsString)(e.from))throw new c.BoxSdkError({message:'Expecting string for "from" of type "UpdateFileMetadataByIdRequestBody"'});const n=null==e.from?void 0:e.from;return{op:t,path:r,value:i,from:n}},t.serializeDeleteFileMetadataByIdScope=function(e){return e},t.deserializeDeleteFileMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize DeleteFileMetadataByIdScope"})};const n=r(37418),o=r(70376),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileMetadataOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileMetadataByIdOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileMetadataByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFileMetadataByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileMetadataByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileMetadataHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileMetadataByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileMetadataByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFileMetadataByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileMetadataByIdHeaders=x;function S(e){return Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t])))}function k(e){return e}function E(e){if("add"==e)return e;if("replace"==e)return e;if("remove"==e)return e;if("test"==e)return e;if("move"==e)return e;if("copy"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateFileMetadataByIdRequestBodyOpField"})}function T(e){return{op:null==e.op?void 0:e.op,path:null==e.path?void 0:e.path,value:null==e.value?void 0:e.value,from:null==e.from?void 0:e.from}}t.FileMetadataManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileMetadata(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/metadata"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeMetadatas)(c.data)),{rawData:c.data})}))}getFileMetadataById(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new f({headers:i.headers,cancellationToken:i.cancellationToken}),s=n.headers,c=n.cancellationToken,u=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"GET",headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(p.data)),{rawData:p.data})}))}createFileMetadataById(e,t,r,n){return i(this,arguments,void 0,(function*(e,t,r,i,n={}){const s=new m({headers:n.headers,cancellationToken:n.cancellationToken}),c=s.headers,u=s.cancellationToken,p=(0,a.prepareParams)(Object.assign({},c.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"POST",headers:p,data:S(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:u});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(h.data)),{rawData:h.data})}))}updateFileMetadataById(e,t,r,n){return i(this,arguments,void 0,(function*(e,t,r,i,n={}){const s=new g({headers:n.headers,cancellationToken:n.cancellationToken}),c=s.headers,u=s.cancellationToken,p=(0,a.prepareParams)(Object.assign({},c.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"PUT",headers:p,data:i.map(T),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:u});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(h.data)),{rawData:h.data})}))}deleteFileMetadataById(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new y({headers:i.headers,cancellationToken:i.cancellationToken}),o=n.headers,s=n.cancellationToken,c=(0,a.prepareParams)(Object.assign({},o.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"DELETE",headers:c,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:s})}))}}},25318:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileRequestsManager=t.CreateFileRequestCopyHeaders=t.DeleteFileRequestByIdHeaders=t.UpdateFileRequestByIdHeaders=t.GetFileRequestByIdHeaders=t.CreateFileRequestCopyOptionals=t.DeleteFileRequestByIdOptionals=t.UpdateFileRequestByIdOptionals=t.GetFileRequestByIdOptionals=void 0;const n=r(58575),o=r(24387),s=r(31419),a=r(31210),l=r(93845),d=r(93845),c=r(84143);class u{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileRequestByIdOptionals=u;class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFileRequestByIdOptionals=p;class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileRequestByIdOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFileRequestCopyOptionals=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileRequestByIdHeaders=m;class g{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFileRequestByIdHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileRequestByIdHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFileRequestCopyHeaders=v;t.FileRequestsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileRequestById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_requests/",(0,d.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeFileRequest)(a.data)),{rawData:a.data})}))}updateFileRequestById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new p({headers:r.headers,cancellationToken:r.cancellationToken}),s=i.headers,a=i.cancellationToken,u=(0,l.prepareParams)(Object.assign({"if-match":(0,d.toString)(s.ifMatch)},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_requests/",(0,d.toString)(e)),method:"PUT",headers:u,data:(0,o.serializeFileRequestUpdateRequest)(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileRequest)(h.data)),{rawData:h.data})}))}deleteFileRequestById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_requests/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}createFileRequestCopy(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new f({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,a=i.cancellationToken,u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_requests/",(0,d.toString)(e),"/copy"),method:"POST",headers:u,data:(0,s.serializeFileRequestCopyRequest)(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileRequest)(p.data)),{rawData:p.data})}))}}},99681:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionLegalHoldsManager=t.GetFileVersionLegalHoldsHeaders=t.GetFileVersionLegalHoldByIdHeaders=t.GetFileVersionLegalHoldsOptionals=t.GetFileVersionLegalHoldByIdOptionals=void 0;const n=r(16754),o=r(2031),s=r(31210),a=r(93845),l=r(93845),d=r(84143);class c{constructor(e){this.headers=new p({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileVersionLegalHoldByIdOptionals=c;class u{constructor(e){this.headers=new h({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileVersionLegalHoldsOptionals=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionLegalHoldByIdHeaders=p;class h{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionLegalHoldsHeaders=h;t.FileVersionLegalHoldsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileVersionLegalHoldById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_version_legal_holds/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeFileVersionLegalHold)(u.data)),{rawData:u.data})}))}getFileVersionLegalHolds(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)({policy_id:(0,l.toString)(e.policyId),marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_version_legal_holds"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeFileVersionLegalHolds)(p.data)),{rawData:p.data})}))}}},73859:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionRetentionsManager=t.GetFileVersionRetentionByIdHeaders=t.GetFileVersionRetentionsHeaders=t.GetFileVersionRetentionByIdOptionals=void 0,t.serializeGetFileVersionRetentionsQueryParamsDispositionActionField=function(e){return e},t.deserializeGetFileVersionRetentionsQueryParamsDispositionActionField=function(e){if("permanently_delete"==e)return e;if("remove_retention"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetFileVersionRetentionsQueryParamsDispositionActionField"})};const n=r(1801),o=r(76804),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631);class u{constructor(e){this.headers=new h({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileVersionRetentionByIdOptionals=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionRetentionsHeaders=p;class h{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionRetentionByIdHeaders=h;t.FileVersionRetentionsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileVersionRetentions(){return i(this,arguments,void 0,(function*(e={},t=new p({}),r){const i=new p({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({file_id:(0,l.toString)(e.fileId),file_version_id:(0,l.toString)(e.fileVersionId),policy_id:(0,l.toString)(e.policyId),disposition_action:(0,l.toString)(e.dispositionAction),disposition_before:(0,l.toString)(e.dispositionBefore),disposition_after:(0,l.toString)(e.dispositionAfter),limit:(0,l.toString)(e.limit),marker:(0,l.toString)(e.marker)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_version_retentions"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeFileVersionRetentions)(c.data)),{rawData:c.data})}))}getFileVersionRetentionById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/file_version_retentions/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeFileVersionRetention)(c.data)),{rawData:c.data})}))}}},67749:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionsManager=t.PromoteFileVersionHeaders=t.UpdateFileVersionByIdHeaders=t.DeleteFileVersionByIdHeaders=t.GetFileVersionByIdHeaders=t.GetFileVersionsHeaders=t.PromoteFileVersionOptionals=t.UpdateFileVersionByIdOptionals=t.DeleteFileVersionByIdOptionals=t.GetFileVersionByIdOptionals=t.GetFileVersionsOptionals=void 0,t.serializeUpdateFileVersionByIdRequestBody=S,t.deserializeUpdateFileVersionByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateFileVersionByIdRequestBody"'});if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new c.BoxSdkError({message:'Expecting string for "trashed_at" of type "UpdateFileVersionByIdRequestBody"'});return{trashedAt:null==e.trashed_at?void 0:e.trashed_at}},t.serializePromoteFileVersionRequestBodyTypeField=k,t.deserializePromoteFileVersionRequestBodyTypeField=E,t.serializePromoteFileVersionRequestBody=T,t.deserializePromoteFileVersionRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "PromoteFileVersionRequestBody"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "PromoteFileVersionRequestBody"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:E(e.type);return{id:t,type:r}};const n=r(13919),o=r(44215),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.queryParams={},this.headers=new v({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileVersionsOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new b({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileVersionByIdOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileVersionByIdOptionals=m;class g{constructor(e){this.requestBody={},this.headers=new _({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFileVersionByIdOptionals=g;class y{constructor(e){this.requestBody={},this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.PromoteFileVersionOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionsHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileVersionByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileVersionByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFileVersionByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.PromoteFileVersionHeaders=x;function S(e){return{trashed_at:null==e.trashedAt?void 0:e.trashedAt}}function k(e){return e}function E(e){if("file_version"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize PromoteFileVersionRequestBodyTypeField"})}function T(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}t.FileVersionsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileVersions(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0,limit:(0,l.toString)(i.limit),offset:(0,l.toString)(i.offset)}),u=(0,a.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/versions"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFileVersions)(p.data)),{rawData:p.data})}))}getFileVersionById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new f({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),n=i.queryParams,s=i.headers,c=i.cancellationToken,u=(0,a.prepareParams)({fields:n.fields?n.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/versions/",(0,l.toString)(t)),method:"GET",params:u,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeFileVersionFull)(h.data)),{rawData:h.data})}))}deleteFileVersionById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new m({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,a.prepareParams)(Object.assign({"if-match":(0,l.toString)(n.ifMatch)},n.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/versions/",(0,l.toString)(t)),method:"DELETE",headers:s,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}updateFileVersionById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({requestBody:r.requestBody,headers:r.headers,cancellationToken:r.cancellationToken}),n=i.requestBody,s=i.headers,c=i.cancellationToken,u=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/versions/",(0,l.toString)(t)),method:"PUT",headers:u,data:S(n),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeFileVersionFull)(p.data)),{rawData:p.data})}))}promoteFileVersion(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:n.fields?n.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/versions/current"),method:"POST",params:u,headers:p,data:T(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeFileVersionFull)(h.data)),{rawData:h.data})}))}}},14703:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FileWatermarksManager=t.DeleteFileWatermarkHeaders=t.UpdateFileWatermarkHeaders=t.UpdateFileWatermarkRequestBodyWatermarkField=t.GetFileWatermarkHeaders=t.DeleteFileWatermarkOptionals=t.UpdateFileWatermarkOptionals=t.GetFileWatermarkOptionals=void 0,t.serializeUpdateFileWatermarkRequestBodyWatermarkImprintField=y,t.deserializeUpdateFileWatermarkRequestBodyWatermarkImprintField=v,t.serializeUpdateFileWatermarkRequestBodyWatermarkField=b,t.deserializeUpdateFileWatermarkRequestBodyWatermarkField=w,t.serializeUpdateFileWatermarkRequestBodyWatermarkFieldInput=function(e){return{imprint:null==e.imprint?void 0:e.imprint}},t.deserializeUpdateFileWatermarkRequestBodyWatermarkFieldInput=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFileWatermarkRequestBodyWatermarkFieldInput"'});return{imprint:null==e.imprint?void 0:v(e.imprint)}},t.serializeUpdateFileWatermarkRequestBody=_,t.deserializeUpdateFileWatermarkRequestBody=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFileWatermarkRequestBody"'});if(null==e.watermark)throw new d.BoxSdkError({message:'Expecting "watermark" of type "UpdateFileWatermarkRequestBody" to be defined'});return{watermark:w(e.watermark)}};const n=r(99698),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793);class u{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileWatermarkOptionals=u;class p{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFileWatermarkOptionals=p;class h{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileWatermarkOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileWatermarkHeaders=f;t.UpdateFileWatermarkRequestBodyWatermarkField=class{constructor(e){this.imprint="default",e.imprint&&(this.imprint=e.imprint),e.rawData&&(this.rawData=e.rawData)}};class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFileWatermarkHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileWatermarkHeaders=g;function y(e){return e}function v(e){if("default"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateFileWatermarkRequestBodyWatermarkImprintField"})}function b(e){return{imprint:e.imprint}}function w(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFileWatermarkRequestBodyWatermarkField"'});if(null==e.imprint)throw new d.BoxSdkError({message:'Expecting "imprint" of type "UpdateFileWatermarkRequestBodyWatermarkField" to be defined'});return{imprint:v(e.imprint)}}function _(e){return{watermark:b(e.watermark)}}t.FileWatermarksManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileWatermark(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,d=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/watermark"),method:"GET",headers:d,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWatermark)(c.data)),{rawData:c.data})}))}updateFileWatermark(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new p({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,d=i.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/watermark"),method:"PUT",headers:c,data:_(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeWatermark)(u.data)),{rawData:u.data})}))}deleteFileWatermark(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/watermark"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},98425:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FilesManager=t.GetFileThumbnailByIdHeaders=t.CopyFileHeaders=t.DeleteFileByIdHeaders=t.UpdateFileByIdHeaders=t.GetFileByIdHeaders=t.GetFileThumbnailByIdOptionals=t.CopyFileOptionals=t.DeleteFileByIdOptionals=t.UpdateFileByIdOptionals=t.GetFileByIdOptionals=void 0,t.serializeUpdateFileByIdRequestBodyParentField=T,t.deserializeUpdateFileByIdRequestBodyParentField=B,t.serializeUpdateFileByIdRequestBodySharedLinkAccessField=C,t.deserializeUpdateFileByIdRequestBodySharedLinkAccessField=I,t.serializeUpdateFileByIdRequestBodySharedLinkPermissionsField=A,t.deserializeUpdateFileByIdRequestBodySharedLinkPermissionsField=F,t.serializeUpdateFileByIdRequestBodySharedLinkField=M,t.deserializeUpdateFileByIdRequestBodySharedLinkField=D,t.serializeUpdateFileByIdRequestBodyLockAccessField=R,t.deserializeUpdateFileByIdRequestBodyLockAccessField=P,t.serializeUpdateFileByIdRequestBodyLockField=O,t.deserializeUpdateFileByIdRequestBodyLockField=z,t.serializeUpdateFileByIdRequestBodyPermissionsCanDownloadField=N,t.deserializeUpdateFileByIdRequestBodyPermissionsCanDownloadField=q,t.serializeUpdateFileByIdRequestBodyPermissionsField=U,t.deserializeUpdateFileByIdRequestBodyPermissionsField=L,t.serializeUpdateFileByIdRequestBodyCollectionsField=j,t.deserializeUpdateFileByIdRequestBodyCollectionsField=H,t.serializeUpdateFileByIdRequestBody=$,t.deserializeUpdateFileByIdRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBody"'});if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "UpdateFileByIdRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.description&&!(0,h.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "UpdateFileByIdRequestBody"'});const r=null==e.description?void 0:e.description,i=null==e.parent?void 0:B(e.parent),n=null==e.shared_link?void 0:D(e.shared_link),o=null==e.lock?void 0:z(e.lock);if(null!=e.disposition_at&&!(0,h.sdIsString)(e.disposition_at))throw new u.BoxSdkError({message:'Expecting string for "disposition_at" of type "UpdateFileByIdRequestBody"'});const a=null==e.disposition_at?void 0:(0,s.deserializeDateTime)(e.disposition_at),l=null==e.permissions?void 0:L(e.permissions);if(null!=e.collections&&!(0,f.sdIsList)(e.collections))throw new u.BoxSdkError({message:'Expecting array for "collections" of type "UpdateFileByIdRequestBody"'});const d=null==e.collections?void 0:(0,f.sdIsList)(e.collections)?e.collections.map((function(e){return H(e)})):[];if(null!=e.tags&&!(0,f.sdIsList)(e.tags))throw new u.BoxSdkError({message:'Expecting array for "tags" of type "UpdateFileByIdRequestBody"'});const c=null==e.tags?void 0:(0,f.sdIsList)(e.tags)?e.tags.map((function(e){if(!(0,h.sdIsString)(e))throw new u.BoxSdkError({message:'Expecting string for "UpdateFileByIdRequestBody"'});return e})):[];return{name:t,description:r,parent:i,sharedLink:n,lock:o,dispositionAt:a,permissions:l,collections:d,tags:c}},t.serializeCopyFileRequestBodyParentField=G,t.deserializeCopyFileRequestBodyParentField=W,t.serializeCopyFileRequestBody=K,t.deserializeCopyFileRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CopyFileRequestBody"'});if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "CopyFileRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.version&&!(0,h.sdIsString)(e.version))throw new u.BoxSdkError({message:'Expecting string for "version" of type "CopyFileRequestBody"'});const r=null==e.version?void 0:e.version;if(null==e.parent)throw new u.BoxSdkError({message:'Expecting "parent" of type "CopyFileRequestBody" to be defined'});const i=W(e.parent);return{name:t,version:r,parent:i}},t.serializeGetFileThumbnailByIdExtension=function(e){return e},t.deserializeGetFileThumbnailByIdExtension=function(e){if("png"==e)return e;if("jpg"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize GetFileThumbnailByIdExtension"})};const n=r(49579),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793);class g{constructor(e){this.queryParams={},this.headers=new _({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileByIdOptionals=g;class y{constructor(e){this.requestBody={},this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFileByIdOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFileByIdOptionals=v;class b{constructor(e){this.queryParams={},this.headers=new k({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CopyFileOptionals=b;class w{constructor(e){this.queryParams={},this.headers=new E({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileThumbnailByIdOptionals=w;class _{constructor(e){this.extraHeaders={},e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.boxapi&&(this.boxapi=e.boxapi),e.xRepHints&&(this.xRepHints=e.xRepHints),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFileByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFileByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CopyFileHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileThumbnailByIdHeaders=E;function T(e){return{id:null==e.id?void 0:e.id}}function B(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodyParentField"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UpdateFileByIdRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function C(e){return e}function I(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateFileByIdRequestBodySharedLinkAccessField"})}function A(e){return{can_download:null==e.canDownload?void 0:e.canDownload}}function F(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "UpdateFileByIdRequestBodySharedLinkPermissionsField"'});return{canDownload:null==e.can_download?void 0:e.can_download}}function M(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:A(e.permissions)}}function D(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodySharedLinkField"'});const t=null==e.access?void 0:I(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "UpdateFileByIdRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateFileByIdRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateFileByIdRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:F(e.permissions)}}function R(e){return e}function P(e){if("lock"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateFileByIdRequestBodyLockAccessField"})}function O(e){return{access:null==e.access?void 0:e.access,expires_at:null==e.expiresAt?void 0:(0,o.serializeDateTime)(e.expiresAt),is_download_prevented:null==e.isDownloadPrevented?void 0:e.isDownloadPrevented}}function z(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodyLockField"'});const t=null==e.access?void 0:P(e.access);if(null!=e.expires_at&&!(0,h.sdIsString)(e.expires_at))throw new u.BoxSdkError({message:'Expecting string for "expires_at" of type "UpdateFileByIdRequestBodyLockField"'});const r=null==e.expires_at?void 0:(0,s.deserializeDateTime)(e.expires_at);if(null!=e.is_download_prevented&&!(0,p.sdIsBoolean)(e.is_download_prevented))throw new u.BoxSdkError({message:'Expecting boolean for "is_download_prevented" of type "UpdateFileByIdRequestBodyLockField"'});return{access:t,expiresAt:r,isDownloadPrevented:null==e.is_download_prevented?void 0:e.is_download_prevented}}function N(e){return e}function q(e){if("open"==e)return e;if("company"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateFileByIdRequestBodyPermissionsCanDownloadField"})}function U(e){return{can_download:null==e.canDownload?void 0:e.canDownload}}function L(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodyPermissionsField"'});return{canDownload:null==e.can_download?void 0:q(e.can_download)}}function j(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function H(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateFileByIdRequestBodyCollectionsField"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UpdateFileByIdRequestBodyCollectionsField"'});const t=null==e.id?void 0:e.id;if(null!=e.type&&!(0,h.sdIsString)(e.type))throw new u.BoxSdkError({message:'Expecting string for "type" of type "UpdateFileByIdRequestBodyCollectionsField"'});return{id:t,type:null==e.type?void 0:e.type}}function $(e){return{name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description,parent:null==e.parent?void 0:T(e.parent),shared_link:null==e.sharedLink?void 0:M(e.sharedLink),lock:null==e.lock?void 0:O(e.lock),disposition_at:null==e.dispositionAt?void 0:(0,o.serializeDateTime)(e.dispositionAt),permissions:null==e.permissions?void 0:U(e.permissions),collections:null==e.collections?void 0:e.collections.map((function(e){return j(e)})),tags:null==e.tags?void 0:e.tags.map((function(e){return e}))}}function G(e){return{id:e.id}}function W(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CopyFileRequestBodyParentField"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "CopyFileRequestBodyParentField" to be defined'});if(!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CopyFileRequestBodyParentField"'});return{id:e.id}}function K(e){return{name:null==e.name?void 0:e.name,version:null==e.version?void 0:e.version,parent:G(e.parent)}}t.FilesManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)({fields:i.fields?i.fields.map(d.toString).join(","):void 0}),u=(0,l.prepareParams)(Object.assign({"if-none-match":(0,d.toString)(o.ifNoneMatch),boxapi:(0,d.toString)(o.boxapi),"x-rep-hints":(0,d.toString)(o.xRepHints)},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e)),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(p.data)),{rawData:p.data})}))}updateFileById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.queryParams,s=r.headers,a=r.cancellationToken,u=(0,l.prepareParams)({fields:o.fields?o.fields.map(d.toString).join(","):void 0}),p=(0,l.prepareParams)(Object.assign({"if-match":(0,d.toString)(s.ifMatch)},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e)),method:"PUT",params:u,headers:p,data:$(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(h.data)),{rawData:h.data})}))}deleteFileById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({"if-match":(0,d.toString)(i.ifMatch)},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}copyFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new b({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),o=i.queryParams,s=i.headers,a=i.cancellationToken,u=(0,l.prepareParams)({fields:o.fields?o.fields.map(d.toString).join(","):void 0}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/copy"),method:"POST",params:u,headers:p,data:K(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(h.data)),{rawData:h.data})}))}getFileThumbnailById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new w({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),n=i.queryParams,o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)({min_height:(0,d.toString)(n.minHeight),min_width:(0,d.toString)(n.minWidth),max_height:(0,d.toString)(n.maxHeight),max_width:(0,d.toString)(n.maxWidth)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders));return(yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/thumbnail.",(0,d.toString)(t)),method:"GET",params:a,headers:u,responseFormat:"binary",auth:this.auth,networkSession:this.networkSession,cancellationToken:s})).content}))}}},69023:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FolderClassificationsManager=t.DeleteClassificationFromFolderHeaders=t.UpdateClassificationOnFolderHeaders=t.UpdateClassificationOnFolderRequestBody=t.AddClassificationToFolderHeaders=t.GetClassificationOnFolderHeaders=t.DeleteClassificationFromFolderOptionals=t.UpdateClassificationOnFolderOptionals=t.AddClassificationToFolderOptionals=t.GetClassificationOnFolderOptionals=void 0,t.serializeAddClassificationToFolderRequestBody=w,t.deserializeAddClassificationToFolderRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "AddClassificationToFolderRequestBody"'});if(null!=e.Box__Security__Classification__Key&&!(0,c.sdIsString)(e.Box__Security__Classification__Key))throw new d.BoxSdkError({message:'Expecting string for "Box__Security__Classification__Key" of type "AddClassificationToFolderRequestBody"'});return{boxSecurityClassificationKey:null==e.Box__Security__Classification__Key?void 0:e.Box__Security__Classification__Key}},t.serializeUpdateClassificationOnFolderRequestBodyOpField=_,t.deserializeUpdateClassificationOnFolderRequestBodyOpField=x,t.serializeUpdateClassificationOnFolderRequestBodyPathField=S,t.deserializeUpdateClassificationOnFolderRequestBodyPathField=k,t.serializeUpdateClassificationOnFolderRequestBody=E,t.deserializeUpdateClassificationOnFolderRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateClassificationOnFolderRequestBody"'});if(null==e.op)throw new d.BoxSdkError({message:'Expecting "op" of type "UpdateClassificationOnFolderRequestBody" to be defined'});const t=x(e.op);if(null==e.path)throw new d.BoxSdkError({message:'Expecting "path" of type "UpdateClassificationOnFolderRequestBody" to be defined'});const r=k(e.path);if(null==e.value)throw new d.BoxSdkError({message:'Expecting "value" of type "UpdateClassificationOnFolderRequestBody" to be defined'});if(!(0,c.sdIsString)(e.value))throw new d.BoxSdkError({message:'Expecting string for "value" of type "UpdateClassificationOnFolderRequestBody"'});const i=e.value;return{op:t,path:r,value:i}},t.serializeUpdateClassificationOnFolderRequestBodyInput=function(e){return{op:null==e.op?void 0:e.op,path:null==e.path?void 0:e.path,value:e.value}},t.deserializeUpdateClassificationOnFolderRequestBodyInput=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateClassificationOnFolderRequestBodyInput"'});const t=null==e.op?void 0:x(e.op),r=null==e.path?void 0:k(e.path);if(null==e.value)throw new d.BoxSdkError({message:'Expecting "value" of type "UpdateClassificationOnFolderRequestBodyInput" to be defined'});if(!(0,c.sdIsString)(e.value))throw new d.BoxSdkError({message:'Expecting string for "value" of type "UpdateClassificationOnFolderRequestBodyInput"'});const i=e.value;return{op:t,path:r,value:i}};const n=r(78748),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793),u=r(50793);class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetClassificationOnFolderOptionals=p;class h{constructor(e){this.requestBody={},this.headers=new y({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddClassificationToFolderOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateClassificationOnFolderOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteClassificationFromFolderOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetClassificationOnFolderHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddClassificationToFolderHeaders=y;t.UpdateClassificationOnFolderRequestBody=class{constructor(e){this.op="replace",this.path="/Box__Security__Classification__Key",e.op&&(this.op=e.op),e.path&&(this.path=e.path),e.value&&(this.value=e.value),e.rawData&&(this.rawData=e.rawData)}};class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateClassificationOnFolderHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteClassificationFromFolderHeaders=b;function w(e){return{Box__Security__Classification__Key:null==e.boxSecurityClassificationKey?void 0:e.boxSecurityClassificationKey}}function _(e){return e}function x(e){if("replace"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateClassificationOnFolderRequestBodyOpField"})}function S(e){return e}function k(e){if("/Box__Security__Classification__Key"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateClassificationOnFolderRequestBodyPathField"})}function E(e){return{op:e.op,path:e.path,value:e.value}}t.FolderClassificationsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getClassificationOnFolder(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,d=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"GET",headers:d,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeClassification)(c.data)),{rawData:c.data})}))}addClassificationToFolder(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"POST",headers:c,data:w(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeClassification)(u.data)),{rawData:u.data})}))}updateClassificationOnFolder(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new f({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,d=i.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"PUT",headers:c,data:t.map(E),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeClassification)(u.data)),{rawData:u.data})}))}deleteClassificationFromFolder(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/metadata/enterprise/securityClassification-6VMVochwUWo"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},63942:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FolderLocksManager=t.DeleteFolderLockByIdHeaders=t.CreateFolderLockHeaders=t.GetFolderLocksHeaders=t.DeleteFolderLockByIdOptionals=t.CreateFolderLockOptionals=t.GetFolderLocksOptionals=void 0,t.serializeCreateFolderLockRequestBodyLockedOperationsField=w,t.deserializeCreateFolderLockRequestBodyLockedOperationsField=_,t.serializeCreateFolderLockRequestBodyFolderField=x,t.deserializeCreateFolderLockRequestBodyFolderField=S,t.serializeCreateFolderLockRequestBody=k,t.deserializeCreateFolderLockRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateFolderLockRequestBody"'});const t=null==e.locked_operations?void 0:_(e.locked_operations);if(null==e.folder)throw new c.BoxSdkError({message:'Expecting "folder" of type "CreateFolderLockRequestBody" to be defined'});const r=S(e.folder);return{lockedOperations:t,folder:r}};const n=r(90716),o=r(10687),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderLocksOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFolderLockOptionals=m;class g{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFolderLockByIdOptionals=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderLocksHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFolderLockHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFolderLockByIdHeaders=b;function w(e){return{move:e.move,delete:e.delete}}function _(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateFolderLockRequestBodyLockedOperationsField"'});if(null==e.move)throw new c.BoxSdkError({message:'Expecting "move" of type "CreateFolderLockRequestBodyLockedOperationsField" to be defined'});if(!(0,u.sdIsBoolean)(e.move))throw new c.BoxSdkError({message:'Expecting boolean for "move" of type "CreateFolderLockRequestBodyLockedOperationsField"'});const t=e.move;if(null==e.delete)throw new c.BoxSdkError({message:'Expecting "delete" of type "CreateFolderLockRequestBodyLockedOperationsField" to be defined'});if(!(0,u.sdIsBoolean)(e.delete))throw new c.BoxSdkError({message:'Expecting boolean for "delete" of type "CreateFolderLockRequestBodyLockedOperationsField"'});return{move:t,delete:e.delete}}function x(e){return{type:e.type,id:e.id}}function S(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateFolderLockRequestBodyFolderField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateFolderLockRequestBodyFolderField" to be defined'});if(!(0,p.sdIsString)(e.type))throw new c.BoxSdkError({message:'Expecting string for "type" of type "CreateFolderLockRequestBodyFolderField"'});const t=e.type;if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateFolderLockRequestBodyFolderField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateFolderLockRequestBodyFolderField"'});return{type:t,id:e.id}}function k(e){return{locked_operations:null==e.lockedOperations?void 0:w(e.lockedOperations),folder:x(e.folder)}}t.FolderLocksManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFolderLocks(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)({folder_id:(0,l.toString)(e.folderId)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folder_locks"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeFolderLocks)(u.data)),{rawData:u.data})}))}createFolderLock(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folder_locks"),method:"POST",headers:s,data:k(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeFolderLock)(l.data)),{rawData:l.data})}))}deleteFolderLockById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folder_locks/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},53799:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FolderMetadataManager=t.DeleteFolderMetadataByIdHeaders=t.UpdateFolderMetadataByIdHeaders=t.CreateFolderMetadataByIdHeaders=t.GetFolderMetadataByIdHeaders=t.GetFolderMetadataHeaders=t.DeleteFolderMetadataByIdOptionals=t.UpdateFolderMetadataByIdOptionals=t.CreateFolderMetadataByIdOptionals=t.GetFolderMetadataByIdOptionals=t.GetFolderMetadataOptionals=void 0,t.serializeGetFolderMetadataByIdScope=function(e){return e},t.deserializeGetFolderMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetFolderMetadataByIdScope"})},t.serializeCreateFolderMetadataByIdScope=function(e){return e},t.deserializeCreateFolderMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateFolderMetadataByIdScope"})},t.serializeCreateFolderMetadataByIdRequestBody=S,t.deserializeCreateFolderMetadataByIdRequestBody=function(e){return(0,p.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t]))):{}},t.serializeUpdateFolderMetadataByIdScope=function(e){return e},t.deserializeUpdateFolderMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateFolderMetadataByIdScope"})},t.serializeUpdateFolderMetadataByIdRequestBodyOpField=k,t.deserializeUpdateFolderMetadataByIdRequestBodyOpField=E,t.serializeUpdateFolderMetadataByIdRequestBody=T,t.deserializeUpdateFolderMetadataByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateFolderMetadataByIdRequestBody"'});const t=null==e.op?void 0:E(e.op);if(null!=e.path&&!(0,u.sdIsString)(e.path))throw new c.BoxSdkError({message:'Expecting string for "path" of type "UpdateFolderMetadataByIdRequestBody"'});const r=null==e.path?void 0:e.path;if(null!=e.value&&!(0,u.sdIsString)(e.value))throw new c.BoxSdkError({message:'Expecting string for "value" of type "UpdateFolderMetadataByIdRequestBody"'});const i=null==e.value?void 0:e.value;if(null!=e.from&&!(0,u.sdIsString)(e.from))throw new c.BoxSdkError({message:'Expecting string for "from" of type "UpdateFolderMetadataByIdRequestBody"'});const n=null==e.from?void 0:e.from;return{op:t,path:r,value:i,from:n}},t.serializeDeleteFolderMetadataByIdScope=function(e){return e},t.deserializeDeleteFolderMetadataByIdScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize DeleteFolderMetadataByIdScope"})};const n=r(37418),o=r(70376),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderMetadataOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderMetadataByIdOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFolderMetadataByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFolderMetadataByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFolderMetadataByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderMetadataHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderMetadataByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFolderMetadataByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFolderMetadataByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFolderMetadataByIdHeaders=x;function S(e){return Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t])))}function k(e){return e}function E(e){if("add"==e)return e;if("replace"==e)return e;if("remove"==e)return e;if("test"==e)return e;if("move"==e)return e;if("copy"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateFolderMetadataByIdRequestBodyOpField"})}function T(e){return{op:null==e.op?void 0:e.op,path:null==e.path?void 0:e.path,value:null==e.value?void 0:e.value,from:null==e.from?void 0:e.from}}t.FolderMetadataManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFolderMetadata(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/metadata"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeMetadatas)(c.data)),{rawData:c.data})}))}getFolderMetadataById(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new f({headers:i.headers,cancellationToken:i.cancellationToken}),s=n.headers,c=n.cancellationToken,u=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"GET",headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(p.data)),{rawData:p.data})}))}createFolderMetadataById(e,t,r,n){return i(this,arguments,void 0,(function*(e,t,r,i,n={}){const s=new m({headers:n.headers,cancellationToken:n.cancellationToken}),c=s.headers,u=s.cancellationToken,p=(0,a.prepareParams)(Object.assign({},c.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"POST",headers:p,data:S(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:u});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(h.data)),{rawData:h.data})}))}updateFolderMetadataById(e,t,r,n){return i(this,arguments,void 0,(function*(e,t,r,i,n={}){const s=new g({headers:n.headers,cancellationToken:n.cancellationToken}),c=s.headers,u=s.cancellationToken,p=(0,a.prepareParams)(Object.assign({},c.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"PUT",headers:p,data:i.map(T),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:u});return Object.assign(Object.assign({},(0,o.deserializeMetadataFull)(h.data)),{rawData:h.data})}))}deleteFolderMetadataById(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new y({headers:i.headers,cancellationToken:i.cancellationToken}),o=n.headers,s=n.cancellationToken,c=(0,a.prepareParams)(Object.assign({},o.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/metadata/",(0,l.toString)(t),"/",(0,l.toString)(r)),method:"DELETE",headers:c,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:s})}))}}},90269:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FolderWatermarksManager=t.DeleteFolderWatermarkHeaders=t.UpdateFolderWatermarkHeaders=t.UpdateFolderWatermarkRequestBodyWatermarkField=t.GetFolderWatermarkHeaders=t.DeleteFolderWatermarkOptionals=t.UpdateFolderWatermarkOptionals=t.GetFolderWatermarkOptionals=void 0,t.serializeUpdateFolderWatermarkRequestBodyWatermarkImprintField=y,t.deserializeUpdateFolderWatermarkRequestBodyWatermarkImprintField=v,t.serializeUpdateFolderWatermarkRequestBodyWatermarkField=b,t.deserializeUpdateFolderWatermarkRequestBodyWatermarkField=w,t.serializeUpdateFolderWatermarkRequestBodyWatermarkFieldInput=function(e){return{imprint:null==e.imprint?void 0:e.imprint}},t.deserializeUpdateFolderWatermarkRequestBodyWatermarkFieldInput=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFolderWatermarkRequestBodyWatermarkFieldInput"'});return{imprint:null==e.imprint?void 0:v(e.imprint)}},t.serializeUpdateFolderWatermarkRequestBody=_,t.deserializeUpdateFolderWatermarkRequestBody=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFolderWatermarkRequestBody"'});if(null==e.watermark)throw new d.BoxSdkError({message:'Expecting "watermark" of type "UpdateFolderWatermarkRequestBody" to be defined'});return{watermark:w(e.watermark)}};const n=r(99698),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793);class u{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderWatermarkOptionals=u;class p{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFolderWatermarkOptionals=p;class h{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFolderWatermarkOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderWatermarkHeaders=f;t.UpdateFolderWatermarkRequestBodyWatermarkField=class{constructor(e){this.imprint="default",e.imprint&&(this.imprint=e.imprint),e.rawData&&(this.rawData=e.rawData)}};class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFolderWatermarkHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFolderWatermarkHeaders=g;function y(e){return e}function v(e){if("default"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize UpdateFolderWatermarkRequestBodyWatermarkImprintField"})}function b(e){return{imprint:e.imprint}}function w(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "UpdateFolderWatermarkRequestBodyWatermarkField"'});if(null==e.imprint)throw new d.BoxSdkError({message:'Expecting "imprint" of type "UpdateFolderWatermarkRequestBodyWatermarkField" to be defined'});return{imprint:v(e.imprint)}}function _(e){return{watermark:b(e.watermark)}}t.FolderWatermarksManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFolderWatermark(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,d=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/watermark"),method:"GET",headers:d,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWatermark)(c.data)),{rawData:c.data})}))}updateFolderWatermark(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new p({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,d=i.cancellationToken,c=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/watermark"),method:"PUT",headers:c,data:_(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeWatermark)(u.data)),{rawData:u.data})}))}deleteFolderWatermark(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,s.prepareParams)(Object.assign({},i.extraHeaders));yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/watermark"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},1307:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.FoldersManager=t.CopyFolderHeaders=t.CreateFolderHeaders=t.GetFolderItemsHeaders=t.DeleteFolderByIdHeaders=t.UpdateFolderByIdHeaders=t.GetFolderByIdHeaders=t.CopyFolderOptionals=t.CreateFolderOptionals=t.GetFolderItemsOptionals=t.DeleteFolderByIdOptionals=t.UpdateFolderByIdOptionals=t.GetFolderByIdOptionals=void 0,t.serializeGetFolderByIdQueryParamsSortField=function(e){return e},t.deserializeGetFolderByIdQueryParamsSortField=function(e){if("id"==e)return e;if("name"==e)return e;if("date"==e)return e;if("size"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize GetFolderByIdQueryParamsSortField"})},t.serializeGetFolderByIdQueryParamsDirectionField=function(e){return e},t.deserializeGetFolderByIdQueryParamsDirectionField=function(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize GetFolderByIdQueryParamsDirectionField"})},t.serializeUpdateFolderByIdRequestBodySyncStateField=I,t.deserializeUpdateFolderByIdRequestBodySyncStateField=A,t.serializeUpdateFolderByIdRequestBodyParentField=F,t.deserializeUpdateFolderByIdRequestBodyParentField=M,t.serializeUpdateFolderByIdRequestBodySharedLinkAccessField=D,t.deserializeUpdateFolderByIdRequestBodySharedLinkAccessField=R,t.serializeUpdateFolderByIdRequestBodySharedLinkPermissionsField=P,t.deserializeUpdateFolderByIdRequestBodySharedLinkPermissionsField=O,t.serializeUpdateFolderByIdRequestBodySharedLinkField=z,t.deserializeUpdateFolderByIdRequestBodySharedLinkField=N,t.serializeUpdateFolderByIdRequestBodyFolderUploadEmailAccessField=q,t.deserializeUpdateFolderByIdRequestBodyFolderUploadEmailAccessField=U,t.serializeUpdateFolderByIdRequestBodyFolderUploadEmailField=L,t.deserializeUpdateFolderByIdRequestBodyFolderUploadEmailField=j,t.serializeUpdateFolderByIdRequestBodyCollectionsField=H,t.deserializeUpdateFolderByIdRequestBodyCollectionsField=$,t.serializeUpdateFolderByIdRequestBody=G,t.deserializeUpdateFolderByIdRequestBody=function(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBody"'});if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "UpdateFolderByIdRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.description&&!(0,f.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "UpdateFolderByIdRequestBody"'});const r=null==e.description?void 0:e.description,i=null==e.sync_state?void 0:A(e.sync_state);if(null!=e.can_non_owners_invite&&!(0,h.sdIsBoolean)(e.can_non_owners_invite))throw new p.BoxSdkError({message:'Expecting boolean for "can_non_owners_invite" of type "UpdateFolderByIdRequestBody"'});const n=null==e.can_non_owners_invite?void 0:e.can_non_owners_invite,o=null==e.parent?void 0:M(e.parent),s=null==e.shared_link?void 0:N(e.shared_link),a=null==e.folder_upload_email?void 0:j(e.folder_upload_email);if(null!=e.tags&&!(0,m.sdIsList)(e.tags))throw new p.BoxSdkError({message:'Expecting array for "tags" of type "UpdateFolderByIdRequestBody"'});const l=null==e.tags?void 0:(0,m.sdIsList)(e.tags)?e.tags.map((function(e){if(!(0,f.sdIsString)(e))throw new p.BoxSdkError({message:'Expecting string for "UpdateFolderByIdRequestBody"'});return e})):[];if(null!=e.is_collaboration_restricted_to_enterprise&&!(0,h.sdIsBoolean)(e.is_collaboration_restricted_to_enterprise))throw new p.BoxSdkError({message:'Expecting boolean for "is_collaboration_restricted_to_enterprise" of type "UpdateFolderByIdRequestBody"'});const d=null==e.is_collaboration_restricted_to_enterprise?void 0:e.is_collaboration_restricted_to_enterprise;if(null!=e.collections&&!(0,m.sdIsList)(e.collections))throw new p.BoxSdkError({message:'Expecting array for "collections" of type "UpdateFolderByIdRequestBody"'});const c=null==e.collections?void 0:(0,m.sdIsList)(e.collections)?e.collections.map((function(e){return $(e)})):[];if(null!=e.can_non_owners_view_collaborators&&!(0,h.sdIsBoolean)(e.can_non_owners_view_collaborators))throw new p.BoxSdkError({message:'Expecting boolean for "can_non_owners_view_collaborators" of type "UpdateFolderByIdRequestBody"'});const u=null==e.can_non_owners_view_collaborators?void 0:e.can_non_owners_view_collaborators;return{name:t,description:r,syncState:i,canNonOwnersInvite:n,parent:o,sharedLink:s,folderUploadEmail:a,tags:l,isCollaborationRestrictedToEnterprise:d,collections:c,canNonOwnersViewCollaborators:u}},t.serializeGetFolderItemsQueryParamsSortField=function(e){return e},t.deserializeGetFolderItemsQueryParamsSortField=function(e){if("id"==e)return e;if("name"==e)return e;if("date"==e)return e;if("size"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize GetFolderItemsQueryParamsSortField"})},t.serializeGetFolderItemsQueryParamsDirectionField=function(e){return e},t.deserializeGetFolderItemsQueryParamsDirectionField=function(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize GetFolderItemsQueryParamsDirectionField"})},t.serializeCreateFolderRequestBodyParentField=W,t.deserializeCreateFolderRequestBodyParentField=K,t.serializeCreateFolderRequestBodyFolderUploadEmailAccessField=V,t.deserializeCreateFolderRequestBodyFolderUploadEmailAccessField=J,t.serializeCreateFolderRequestBodyFolderUploadEmailField=Y,t.deserializeCreateFolderRequestBodyFolderUploadEmailField=Q,t.serializeCreateFolderRequestBodySyncStateField=Z,t.deserializeCreateFolderRequestBodySyncStateField=X,t.serializeCreateFolderRequestBody=ee,t.deserializeCreateFolderRequestBody=function(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateFolderRequestBody"'});if(null==e.name)throw new p.BoxSdkError({message:'Expecting "name" of type "CreateFolderRequestBody" to be defined'});if(!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "CreateFolderRequestBody"'});const t=e.name;if(null==e.parent)throw new p.BoxSdkError({message:'Expecting "parent" of type "CreateFolderRequestBody" to be defined'});const r=K(e.parent),i=null==e.folder_upload_email?void 0:Q(e.folder_upload_email),n=null==e.sync_state?void 0:X(e.sync_state);return{name:t,parent:r,folderUploadEmail:i,syncState:n}},t.serializeCopyFolderRequestBodyParentField=te,t.deserializeCopyFolderRequestBodyParentField=re,t.serializeCopyFolderRequestBody=ie,t.deserializeCopyFolderRequestBody=function(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CopyFolderRequestBody"'});if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "CopyFolderRequestBody"'});const t=null==e.name?void 0:e.name;if(null==e.parent)throw new p.BoxSdkError({message:'Expecting "parent" of type "CopyFolderRequestBody" to be defined'});const r=re(e.parent);return{name:t,parent:r}};const n=r(34537),o=r(61664),s=r(93845),a=r(93845),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793),m=r(50793),g=r(50793);class y{constructor(e){this.queryParams={},this.headers=new S({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderByIdOptionals=y;class v{constructor(e){this.requestBody={},this.queryParams={},this.headers=new k({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateFolderByIdOptionals=v;class b{constructor(e){this.queryParams={},this.headers=new E({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteFolderByIdOptionals=b;class w{constructor(e){this.queryParams={},this.headers=new T({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderItemsOptionals=w;class _{constructor(e){this.queryParams={},this.headers=new B({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateFolderOptionals=_;class x{constructor(e){this.queryParams={},this.headers=new C({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CopyFolderOptionals=x;class S{constructor(e){this.extraHeaders={},e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateFolderByIdHeaders=k;class E{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteFolderByIdHeaders=E;class T{constructor(e){this.extraHeaders={},e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderItemsHeaders=T;class B{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateFolderHeaders=B;class C{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CopyFolderHeaders=C;function I(e){return e}function A(e){if("synced"==e)return e;if("not_synced"==e)return e;if("partially_synced"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateFolderByIdRequestBodySyncStateField"})}function F(e){return{id:null==e.id?void 0:e.id}}function M(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBodyParentField"'});if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "UpdateFolderByIdRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function D(e){return e}function R(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateFolderByIdRequestBodySharedLinkAccessField"})}function P(e){return{can_download:null==e.canDownload?void 0:e.canDownload}}function O(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,h.sdIsBoolean)(e.can_download))throw new p.BoxSdkError({message:'Expecting boolean for "can_download" of type "UpdateFolderByIdRequestBodySharedLinkPermissionsField"'});return{canDownload:null==e.can_download?void 0:e.can_download}}function z(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,s.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:P(e.permissions)}}function N(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBodySharedLinkField"'});const t=null==e.access?void 0:R(e.access);if(null!=e.password&&!(0,f.sdIsString)(e.password))throw new p.BoxSdkError({message:'Expecting string for "password" of type "UpdateFolderByIdRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,f.sdIsString)(e.vanity_name))throw new p.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateFolderByIdRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,f.sdIsString)(e.unshared_at))throw new p.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateFolderByIdRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,a.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:O(e.permissions)}}function q(e){return e}function U(e){if("open"==e)return e;if("collaborators"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateFolderByIdRequestBodyFolderUploadEmailAccessField"})}function L(e){return{access:null==e.access?void 0:e.access}}function j(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBodyFolderUploadEmailField"'});return{access:null==e.access?void 0:U(e.access)}}function H(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function $(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateFolderByIdRequestBodyCollectionsField"'});if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "UpdateFolderByIdRequestBodyCollectionsField"'});const t=null==e.id?void 0:e.id;if(null!=e.type&&!(0,f.sdIsString)(e.type))throw new p.BoxSdkError({message:'Expecting string for "type" of type "UpdateFolderByIdRequestBodyCollectionsField"'});return{id:t,type:null==e.type?void 0:e.type}}function G(e){return{name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description,sync_state:null==e.syncState?void 0:e.syncState,can_non_owners_invite:null==e.canNonOwnersInvite?void 0:e.canNonOwnersInvite,parent:null==e.parent?void 0:F(e.parent),shared_link:null==e.sharedLink?void 0:z(e.sharedLink),folder_upload_email:null==e.folderUploadEmail?void 0:L(e.folderUploadEmail),tags:null==e.tags?void 0:e.tags.map((function(e){return e})),is_collaboration_restricted_to_enterprise:null==e.isCollaborationRestrictedToEnterprise?void 0:e.isCollaborationRestrictedToEnterprise,collections:null==e.collections?void 0:e.collections.map((function(e){return H(e)})),can_non_owners_view_collaborators:null==e.canNonOwnersViewCollaborators?void 0:e.canNonOwnersViewCollaborators}}function W(e){return{id:e.id}}function K(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateFolderRequestBodyParentField"'});if(null==e.id)throw new p.BoxSdkError({message:'Expecting "id" of type "CreateFolderRequestBodyParentField" to be defined'});if(!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "CreateFolderRequestBodyParentField"'});return{id:e.id}}function V(e){return e}function J(e){if("open"==e)return e;if("collaborators"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateFolderRequestBodyFolderUploadEmailAccessField"})}function Y(e){return{access:null==e.access?void 0:e.access}}function Q(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateFolderRequestBodyFolderUploadEmailField"'});return{access:null==e.access?void 0:J(e.access)}}function Z(e){return e}function X(e){if("synced"==e)return e;if("not_synced"==e)return e;if("partially_synced"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateFolderRequestBodySyncStateField"})}function ee(e){return{name:e.name,parent:W(e.parent),folder_upload_email:null==e.folderUploadEmail?void 0:Y(e.folderUploadEmail),sync_state:null==e.syncState?void 0:e.syncState}}function te(e){return{id:e.id}}function re(e){if(!(0,g.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CopyFolderRequestBodyParentField"'});if(null==e.id)throw new p.BoxSdkError({message:'Expecting "id" of type "CopyFolderRequestBodyParentField" to be defined'});if(!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "CopyFolderRequestBodyParentField"'});return{id:e.id}}function ie(e){return{name:null==e.name?void 0:e.name,parent:te(e.parent)}}t.FoldersManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFolderById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0,sort:(0,c.toString)(i.sort),direction:(0,c.toString)(i.direction),offset:(0,c.toString)(i.offset),limit:(0,c.toString)(i.limit)}),l=(0,d.prepareParams)(Object.assign({"if-none-match":(0,c.toString)(o.ifNoneMatch),boxapi:(0,c.toString)(o.boxapi)},o.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,c.toString)(e)),method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(p.data)),{rawData:p.data})}))}updateFolderById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.queryParams,s=r.headers,a=r.cancellationToken,l=(0,d.prepareParams)({fields:o.fields?o.fields.map(c.toString).join(","):void 0}),p=(0,d.prepareParams)(Object.assign({"if-match":(0,c.toString)(s.ifMatch)},s.extraHeaders)),h=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,c.toString)(e)),method:"PUT",params:l,headers:p,data:G(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(h.data)),{rawData:h.data})}))}deleteFolderById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)({recursive:(0,c.toString)(i.recursive)}),a=(0,d.prepareParams)(Object.assign({"if-match":(0,c.toString)(n.ifMatch)},n.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,c.toString)(e)),method:"DELETE",params:s,headers:a,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}getFolderItems(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0,usemarker:(0,c.toString)(i.usemarker),marker:(0,c.toString)(i.marker),offset:(0,c.toString)(i.offset),limit:(0,c.toString)(i.limit),sort:(0,c.toString)(i.sort),direction:(0,c.toString)(i.direction)}),l=(0,d.prepareParams)(Object.assign({boxapi:(0,c.toString)(n.boxapi)},n.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,c.toString)(e),"/items"),method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeItems)(p.data)),{rawData:p.data})}))}createFolder(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new _({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0}),l=(0,d.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders"),method:"POST",params:a,headers:l,data:ee(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(p.data)),{rawData:p.data})}))}copyFolder(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new x({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),o=i.queryParams,s=i.headers,a=i.cancellationToken,l=(0,d.prepareParams)({fields:o.fields?o.fields.map(c.toString).join(","):void 0}),p=(0,d.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,c.toString)(e),"/copy"),method:"POST",params:l,headers:p,data:ie(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(h.data)),{rawData:h.data})}))}}},49534:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.GroupsManager=t.DeleteGroupByIdHeaders=t.UpdateGroupByIdHeaders=t.GetGroupByIdHeaders=t.CreateGroupHeaders=t.GetGroupsHeaders=t.DeleteGroupByIdOptionals=t.UpdateGroupByIdOptionals=t.GetGroupByIdOptionals=t.CreateGroupOptionals=void 0,t.serializeCreateGroupRequestBodyInvitabilityLevelField=x,t.deserializeCreateGroupRequestBodyInvitabilityLevelField=S,t.serializeCreateGroupRequestBodyMemberViewabilityLevelField=k,t.deserializeCreateGroupRequestBodyMemberViewabilityLevelField=E,t.serializeCreateGroupRequestBody=T,t.deserializeCreateGroupRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateGroupRequestBody"'});if(null==e.name)throw new c.BoxSdkError({message:'Expecting "name" of type "CreateGroupRequestBody" to be defined'});if(!(0,u.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "CreateGroupRequestBody"'});const t=e.name;if(null!=e.provenance&&!(0,u.sdIsString)(e.provenance))throw new c.BoxSdkError({message:'Expecting string for "provenance" of type "CreateGroupRequestBody"'});const r=null==e.provenance?void 0:e.provenance;if(null!=e.external_sync_identifier&&!(0,u.sdIsString)(e.external_sync_identifier))throw new c.BoxSdkError({message:'Expecting string for "external_sync_identifier" of type "CreateGroupRequestBody"'});const i=null==e.external_sync_identifier?void 0:e.external_sync_identifier;if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new c.BoxSdkError({message:'Expecting string for "description" of type "CreateGroupRequestBody"'});const n=null==e.description?void 0:e.description,o=null==e.invitability_level?void 0:S(e.invitability_level),s=null==e.member_viewability_level?void 0:E(e.member_viewability_level);return{name:t,provenance:r,externalSyncIdentifier:i,description:n,invitabilityLevel:o,memberViewabilityLevel:s}},t.serializeUpdateGroupByIdRequestBodyInvitabilityLevelField=B,t.deserializeUpdateGroupByIdRequestBodyInvitabilityLevelField=C,t.serializeUpdateGroupByIdRequestBodyMemberViewabilityLevelField=I,t.deserializeUpdateGroupByIdRequestBodyMemberViewabilityLevelField=A,t.serializeUpdateGroupByIdRequestBody=F,t.deserializeUpdateGroupByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateGroupByIdRequestBody"'});if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "UpdateGroupByIdRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.provenance&&!(0,u.sdIsString)(e.provenance))throw new c.BoxSdkError({message:'Expecting string for "provenance" of type "UpdateGroupByIdRequestBody"'});const r=null==e.provenance?void 0:e.provenance;if(null!=e.external_sync_identifier&&!(0,u.sdIsString)(e.external_sync_identifier))throw new c.BoxSdkError({message:'Expecting string for "external_sync_identifier" of type "UpdateGroupByIdRequestBody"'});const i=null==e.external_sync_identifier?void 0:e.external_sync_identifier;if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new c.BoxSdkError({message:'Expecting string for "description" of type "UpdateGroupByIdRequestBody"'});const n=null==e.description?void 0:e.description,o=null==e.invitability_level?void 0:C(e.invitability_level),s=null==e.member_viewability_level?void 0:A(e.member_viewability_level);return{name:t,provenance:r,externalSyncIdentifier:i,description:n,invitabilityLevel:o,memberViewabilityLevel:s}};const n=r(55604),o=r(26718),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.queryParams={},this.headers=new v({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateGroupOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new b({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetGroupByIdOptionals=f;class m{constructor(e){this.requestBody={},this.queryParams={},this.headers=new w({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateGroupByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteGroupByIdOptionals=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGroupsHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateGroupHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGroupByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateGroupByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteGroupByIdHeaders=_;function x(e){return e}function S(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateGroupRequestBodyInvitabilityLevelField"})}function k(e){return e}function E(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateGroupRequestBodyMemberViewabilityLevelField"})}function T(e){return{name:e.name,provenance:null==e.provenance?void 0:e.provenance,external_sync_identifier:null==e.externalSyncIdentifier?void 0:e.externalSyncIdentifier,description:null==e.description?void 0:e.description,invitability_level:null==e.invitabilityLevel?void 0:e.invitabilityLevel,member_viewability_level:null==e.memberViewabilityLevel?void 0:e.memberViewabilityLevel}}function B(e){return e}function C(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateGroupByIdRequestBodyInvitabilityLevelField"})}function I(e){return e}function A(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateGroupByIdRequestBodyMemberViewabilityLevelField"})}function F(e){return{name:null==e.name?void 0:e.name,provenance:null==e.provenance?void 0:e.provenance,external_sync_identifier:null==e.externalSyncIdentifier?void 0:e.externalSyncIdentifier,description:null==e.description?void 0:e.description,invitability_level:null==e.invitabilityLevel?void 0:e.invitabilityLevel,member_viewability_level:null==e.memberViewabilityLevel?void 0:e.memberViewabilityLevel}}t.GroupsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getGroups(){return i(this,arguments,void 0,(function*(e={},t=new y({}),r){const i=new y({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({filter_term:(0,l.toString)(e.filterTerm),fields:e.fields?e.fields.map(l.toString).join(","):void 0,limit:(0,l.toString)(e.limit),offset:(0,l.toString)(e.offset)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeGroups)(c.data)),{rawData:c.data})}))}createGroup(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups"),method:"POST",params:c,headers:u,data:T(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeGroupFull)(p.data)),{rawData:p.data})}))}getGroupById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/",(0,l.toString)(e)),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeGroupFull)(p.data)),{rawData:p.data})}))}updateGroupById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:n.fields?n.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/",(0,l.toString)(e)),method:"PUT",params:u,headers:p,data:F(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeGroupFull)(h.data)),{rawData:h.data})}))}deleteGroupById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},58555:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.IntegrationMappingsManager=t.DeleteSlackIntegrationMappingByIdHeaders=t.UpdateSlackIntegrationMappingByIdHeaders=t.CreateSlackIntegrationMappingHeaders=t.GetSlackIntegrationMappingHeaders=t.DeleteSlackIntegrationMappingByIdOptionals=t.UpdateSlackIntegrationMappingByIdOptionals=t.CreateSlackIntegrationMappingOptionals=void 0,t.serializeGetSlackIntegrationMappingQueryParamsPartnerItemTypeField=function(e){return e},t.deserializeGetSlackIntegrationMappingQueryParamsPartnerItemTypeField=function(e){if("channel"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize GetSlackIntegrationMappingQueryParamsPartnerItemTypeField"})},t.serializeGetSlackIntegrationMappingQueryParamsBoxItemTypeField=function(e){return e},t.deserializeGetSlackIntegrationMappingQueryParamsBoxItemTypeField=function(e){if("folder"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize GetSlackIntegrationMappingQueryParamsBoxItemTypeField"})},t.serializeUpdateSlackIntegrationMappingByIdRequestBody=k,t.deserializeUpdateSlackIntegrationMappingByIdRequestBody=function(e){if(!(0,g.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "UpdateSlackIntegrationMappingByIdRequestBody"'});const t=null==e.box_item?void 0:(0,l.deserializeIntegrationMappingBoxItemSlack)(e.box_item),r=null==e.options?void 0:(0,c.deserializeIntegrationMappingSlackOptions)(e.options);return{boxItem:t,options:r}};const n=r(17213),o=r(7152),s=r(95665),a=r(88838),l=r(88838),d=r(77954),c=r(77954),u=r(31210),p=r(93845),h=r(93845),f=r(84143),m=r(72631),g=r(50793);class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateSlackIntegrationMappingOptionals=y;class v{constructor(e){this.requestBody={},this.headers=new x({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateSlackIntegrationMappingByIdOptionals=v;class b{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteSlackIntegrationMappingByIdOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSlackIntegrationMappingHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateSlackIntegrationMappingHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateSlackIntegrationMappingByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteSlackIntegrationMappingByIdHeaders=S;function k(e){return{box_item:null==e.boxItem?void 0:(0,a.serializeIntegrationMappingBoxItemSlack)(e.boxItem),options:null==e.options?void 0:(0,d.serializeIntegrationMappingSlackOptions)(e.options)}}t.IntegrationMappingsManager=class{constructor(e){this.networkSession=new u.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getSlackIntegrationMapping(){return i(this,arguments,void 0,(function*(e={},t=new w({}),r){const i=new w({extraHeaders:t.extraHeaders}),o=(0,p.prepareParams)({marker:(0,h.toString)(e.marker),limit:(0,h.toString)(e.limit),partner_item_type:(0,h.toString)(e.partnerItemType),partner_item_id:(0,h.toString)(e.partnerItemId),box_item_id:(0,h.toString)(e.boxItemId),box_item_type:(0,h.toString)(e.boxItemType),is_manually_created:(0,h.toString)(e.isManuallyCreated)}),s=(0,p.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,f.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/integration_mappings/slack"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeIntegrationMappings)(a.data)),{rawData:a.data})}))}createSlackIntegrationMapping(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,a=(0,p.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,f.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/integration_mappings/slack"),method:"POST",headers:a,data:(0,s.serializeIntegrationMappingSlackCreateRequest)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeIntegrationMapping)(l.data)),{rawData:l.data})}))}updateSlackIntegrationMappingById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,a=(0,p.prepareParams)(Object.assign({},n.extraHeaders)),l=yield(0,f.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/integration_mappings/slack/",(0,h.toString)(e)),method:"PUT",headers:a,data:k(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeIntegrationMapping)(l.data)),{rawData:l.data})}))}deleteSlackIntegrationMappingById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,p.prepareParams)(Object.assign({},i.extraHeaders));yield(0,f.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/integration_mappings/slack/",(0,h.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},64200:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.InvitesManager=t.GetInviteByIdHeaders=t.CreateInviteHeaders=t.GetInviteByIdOptionals=t.CreateInviteOptionals=void 0,t.serializeCreateInviteRequestBodyEnterpriseField=g,t.deserializeCreateInviteRequestBodyEnterpriseField=y,t.serializeCreateInviteRequestBodyActionableByField=v,t.deserializeCreateInviteRequestBodyActionableByField=b,t.serializeCreateInviteRequestBody=w,t.deserializeCreateInviteRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "CreateInviteRequestBody"'});if(null==e.enterprise)throw new d.BoxSdkError({message:'Expecting "enterprise" of type "CreateInviteRequestBody" to be defined'});const t=y(e.enterprise);if(null==e.actionable_by)throw new d.BoxSdkError({message:'Expecting "actionable_by" of type "CreateInviteRequestBody" to be defined'});const r=b(e.actionable_by);return{enterprise:t,actionableBy:r}};const n=r(6265),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793),u=r(50793);class p{constructor(e){this.queryParams={},this.headers=new f({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateInviteOptionals=p;class h{constructor(e){this.queryParams={},this.headers=new m({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetInviteByIdOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateInviteHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetInviteByIdHeaders=m;function g(e){return{id:e.id}}function y(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "CreateInviteRequestBodyEnterpriseField"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "CreateInviteRequestBodyEnterpriseField" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "CreateInviteRequestBodyEnterpriseField"'});return{id:e.id}}function v(e){return{login:null==e.login?void 0:e.login}}function b(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "CreateInviteRequestBodyActionableByField"'});if(null!=e.login&&!(0,c.sdIsString)(e.login))throw new d.BoxSdkError({message:'Expecting string for "login" of type "CreateInviteRequestBodyActionableByField"'});return{login:null==e.login?void 0:e.login}}function w(e){return{enterprise:g(e.enterprise),actionable_by:v(e.actionableBy)}}t.InvitesManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}createInvite(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)({fields:i.fields?i.fields.map(a.toString).join(","):void 0}),u=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),h=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/invites"),method:"POST",params:c,headers:u,data:w(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeInvite)(h.data)),{rawData:h.data})}))}getInviteById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)({fields:i.fields?i.fields.map(a.toString).join(","):void 0}),u=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/invites/",(0,a.toString)(e)),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeInvite)(p.data)),{rawData:p.data})}))}}},92536:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.LegalHoldPoliciesManager=t.DeleteLegalHoldPolicyByIdHeaders=t.UpdateLegalHoldPolicyByIdHeaders=t.GetLegalHoldPolicyByIdHeaders=t.CreateLegalHoldPolicyHeaders=t.GetLegalHoldPoliciesHeaders=t.DeleteLegalHoldPolicyByIdOptionals=t.UpdateLegalHoldPolicyByIdOptionals=t.GetLegalHoldPolicyByIdOptionals=t.CreateLegalHoldPolicyOptionals=void 0,t.serializeCreateLegalHoldPolicyRequestBody=E,t.deserializeCreateLegalHoldPolicyRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateLegalHoldPolicyRequestBody"'});if(null==e.policy_name)throw new p.BoxSdkError({message:'Expecting "policy_name" of type "CreateLegalHoldPolicyRequestBody" to be defined'});if(!(0,f.sdIsString)(e.policy_name))throw new p.BoxSdkError({message:'Expecting string for "policy_name" of type "CreateLegalHoldPolicyRequestBody"'});const t=e.policy_name;if(null!=e.description&&!(0,f.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "CreateLegalHoldPolicyRequestBody"'});const r=null==e.description?void 0:e.description;if(null!=e.filter_started_at&&!(0,f.sdIsString)(e.filter_started_at))throw new p.BoxSdkError({message:'Expecting string for "filter_started_at" of type "CreateLegalHoldPolicyRequestBody"'});const i=null==e.filter_started_at?void 0:(0,a.deserializeDateTime)(e.filter_started_at);if(null!=e.filter_ended_at&&!(0,f.sdIsString)(e.filter_ended_at))throw new p.BoxSdkError({message:'Expecting string for "filter_ended_at" of type "CreateLegalHoldPolicyRequestBody"'});const n=null==e.filter_ended_at?void 0:(0,a.deserializeDateTime)(e.filter_ended_at);if(null!=e.is_ongoing&&!(0,h.sdIsBoolean)(e.is_ongoing))throw new p.BoxSdkError({message:'Expecting boolean for "is_ongoing" of type "CreateLegalHoldPolicyRequestBody"'});const o=null==e.is_ongoing?void 0:e.is_ongoing;return{policyName:t,description:r,filterStartedAt:i,filterEndedAt:n,isOngoing:o}},t.serializeUpdateLegalHoldPolicyByIdRequestBody=T,t.deserializeUpdateLegalHoldPolicyByIdRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateLegalHoldPolicyByIdRequestBody"'});if(null!=e.policy_name&&!(0,f.sdIsString)(e.policy_name))throw new p.BoxSdkError({message:'Expecting string for "policy_name" of type "UpdateLegalHoldPolicyByIdRequestBody"'});const t=null==e.policy_name?void 0:e.policy_name;if(null!=e.description&&!(0,f.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "UpdateLegalHoldPolicyByIdRequestBody"'});const r=null==e.description?void 0:e.description;if(null!=e.release_notes&&!(0,f.sdIsString)(e.release_notes))throw new p.BoxSdkError({message:'Expecting string for "release_notes" of type "UpdateLegalHoldPolicyByIdRequestBody"'});const i=null==e.release_notes?void 0:e.release_notes;return{policyName:t,description:r,releaseNotes:i}};const n=r(48910),o=r(83750),s=r(93845),a=r(93845),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793),m=r(50793);class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateLegalHoldPolicyOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetLegalHoldPolicyByIdOptionals=y;class v{constructor(e){this.requestBody={},this.headers=new S({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateLegalHoldPolicyByIdOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteLegalHoldPolicyByIdOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetLegalHoldPoliciesHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateLegalHoldPolicyHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetLegalHoldPolicyByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateLegalHoldPolicyByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteLegalHoldPolicyByIdHeaders=k;function E(e){return{policy_name:e.policyName,description:null==e.description?void 0:e.description,filter_started_at:null==e.filterStartedAt?void 0:(0,s.serializeDateTime)(e.filterStartedAt),filter_ended_at:null==e.filterEndedAt?void 0:(0,s.serializeDateTime)(e.filterEndedAt),is_ongoing:null==e.isOngoing?void 0:e.isOngoing}}function T(e){return{policy_name:null==e.policyName?void 0:e.policyName,description:null==e.description?void 0:e.description,release_notes:null==e.releaseNotes?void 0:e.releaseNotes}}t.LegalHoldPoliciesManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getLegalHoldPolicies(){return i(this,arguments,void 0,(function*(e={},t=new w({}),r){const i=new w({extraHeaders:t.extraHeaders}),o=(0,d.prepareParams)({policy_name:(0,c.toString)(e.policyName),fields:e.fields?e.fields.map(c.toString).join(","):void 0,marker:(0,c.toString)(e.marker),limit:(0,c.toString)(e.limit)}),s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policies"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeLegalHoldPolicies)(a.data)),{rawData:a.data})}))}createLegalHoldPolicy(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policies"),method:"POST",headers:s,data:E(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeLegalHoldPolicy)(a.data)),{rawData:a.data})}))}getLegalHoldPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policies/",(0,c.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeLegalHoldPolicy)(a.data)),{rawData:a.data})}))}updateLegalHoldPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)(Object.assign({},n.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policies/",(0,c.toString)(e)),method:"PUT",headers:a,data:T(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeLegalHoldPolicy)(l.data)),{rawData:l.data})}))}deleteLegalHoldPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,d.prepareParams)(Object.assign({},i.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policies/",(0,c.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},22678:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.LegalHoldPolicyAssignmentsManager=t.GetLegalHoldPolicyAssignmentFileOnHoldHeaders=t.DeleteLegalHoldPolicyAssignmentByIdHeaders=t.GetLegalHoldPolicyAssignmentByIdHeaders=t.CreateLegalHoldPolicyAssignmentHeaders=t.GetLegalHoldPolicyAssignmentsHeaders=t.GetLegalHoldPolicyAssignmentFileOnHoldOptionals=t.DeleteLegalHoldPolicyAssignmentByIdOptionals=t.GetLegalHoldPolicyAssignmentByIdOptionals=t.CreateLegalHoldPolicyAssignmentOptionals=t.GetLegalHoldPolicyAssignmentsOptionals=void 0,t.serializeGetLegalHoldPolicyAssignmentsQueryParamsAssignToTypeField=function(e){return e},t.deserializeGetLegalHoldPolicyAssignmentsQueryParamsAssignToTypeField=function(e){if("file"==e)return e;if("file_version"==e)return e;if("folder"==e)return e;if("user"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize GetLegalHoldPolicyAssignmentsQueryParamsAssignToTypeField"})},t.serializeCreateLegalHoldPolicyAssignmentRequestBodyAssignToTypeField=k,t.deserializeCreateLegalHoldPolicyAssignmentRequestBodyAssignToTypeField=E,t.serializeCreateLegalHoldPolicyAssignmentRequestBodyAssignToField=T,t.deserializeCreateLegalHoldPolicyAssignmentRequestBodyAssignToField=B,t.serializeCreateLegalHoldPolicyAssignmentRequestBody=C,t.deserializeCreateLegalHoldPolicyAssignmentRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateLegalHoldPolicyAssignmentRequestBody"'});if(null==e.policy_id)throw new u.BoxSdkError({message:'Expecting "policy_id" of type "CreateLegalHoldPolicyAssignmentRequestBody" to be defined'});if(!(0,p.sdIsString)(e.policy_id))throw new u.BoxSdkError({message:'Expecting string for "policy_id" of type "CreateLegalHoldPolicyAssignmentRequestBody"'});const t=e.policy_id;if(null==e.assign_to)throw new u.BoxSdkError({message:'Expecting "assign_to" of type "CreateLegalHoldPolicyAssignmentRequestBody" to be defined'});const r=B(e.assign_to);return{policyId:t,assignTo:r}};const n=r(44212),o=r(55047),s=r(94983),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetLegalHoldPolicyAssignmentsOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateLegalHoldPolicyAssignmentOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetLegalHoldPolicyAssignmentByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteLegalHoldPolicyAssignmentByIdOptionals=y;class v{constructor(e){this.queryParams={},this.headers=new S({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetLegalHoldPolicyAssignmentFileOnHoldOptionals=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetLegalHoldPolicyAssignmentsHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateLegalHoldPolicyAssignmentHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetLegalHoldPolicyAssignmentByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteLegalHoldPolicyAssignmentByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetLegalHoldPolicyAssignmentFileOnHoldHeaders=S;function k(e){return e}function E(e){if("file"==e)return e;if("file_version"==e)return e;if("folder"==e)return e;if("user"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize CreateLegalHoldPolicyAssignmentRequestBodyAssignToTypeField"})}function T(e){return{type:e.type,id:e.id}}function B(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateLegalHoldPolicyAssignmentRequestBodyAssignToField"'});if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "CreateLegalHoldPolicyAssignmentRequestBodyAssignToField" to be defined'});const t=E(e.type);if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "CreateLegalHoldPolicyAssignmentRequestBodyAssignToField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CreateLegalHoldPolicyAssignmentRequestBodyAssignToField"'});return{type:t,id:e.id}}function C(e){return{policy_id:e.policyId,assign_to:T(e.assignTo)}}t.LegalHoldPolicyAssignmentsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getLegalHoldPolicyAssignments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)({policy_id:(0,d.toString)(e.policyId),assign_to_type:(0,d.toString)(e.assignToType),assign_to_id:(0,d.toString)(e.assignToId),marker:(0,d.toString)(e.marker),limit:(0,d.toString)(e.limit),fields:e.fields?e.fields.map(d.toString).join(","):void 0}),a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policy_assignments"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeLegalHoldPolicyAssignments)(u.data)),{rawData:u.data})}))}createLegalHoldPolicyAssignment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policy_assignments"),method:"POST",headers:s,data:C(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeLegalHoldPolicyAssignment)(a.data)),{rawData:a.data})}))}getLegalHoldPolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policy_assignments/",(0,d.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeLegalHoldPolicyAssignment)(a.data)),{rawData:a.data})}))}deleteLegalHoldPolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policy_assignments/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getLegalHoldPolicyAssignmentFileOnHold(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,a=(0,l.prepareParams)({marker:(0,d.toString)(i.marker),limit:(0,d.toString)(i.limit),fields:i.fields?i.fields.map(d.toString).join(","):void 0}),u=(0,l.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/legal_hold_policy_assignments/",(0,d.toString)(e),"/files_on_hold"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,s.deserializeFilesOnHold)(p.data)),{rawData:p.data})}))}}},69496:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ListCollaborationsManager=t.GetGroupCollaborationsHeaders=t.GetCollaborationsHeaders=t.GetFolderCollaborationsHeaders=t.GetFileCollaborationsHeaders=t.GetGroupCollaborationsOptionals=t.GetCollaborationsOptionals=t.GetFolderCollaborationsOptionals=t.GetFileCollaborationsOptionals=void 0,t.serializeGetCollaborationsQueryParamsStatusField=function(e){return e},t.deserializeGetCollaborationsQueryParamsStatusField=function(e){if("pending"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize GetCollaborationsQueryParamsStatusField"})};const n=r(7546),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631);class c{constructor(e){this.queryParams={},this.headers=new f({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileCollaborationsOptionals=c;class u{constructor(e){this.queryParams={},this.headers=new m({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFolderCollaborationsOptionals=u;class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCollaborationsOptionals=p;class h{constructor(e){this.queryParams={},this.headers=new y({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetGroupCollaborationsOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileCollaborationsHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFolderCollaborationsHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationsHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGroupCollaborationsHeaders=y;t.ListCollaborationsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileCollaborations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,u=(0,s.prepareParams)({fields:i.fields?i.fields.map(a.toString).join(","):void 0,limit:(0,a.toString)(i.limit),marker:(0,a.toString)(i.marker)}),p=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),h=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,a.toString)(e),"/collaborations"),method:"GET",params:u,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeCollaborations)(h.data)),{rawData:h.data})}))}getFolderCollaborations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)({fields:i.fields?i.fields.map(a.toString).join(","):void 0}),p=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),h=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,a.toString)(e),"/collaborations"),method:"GET",params:c,headers:p,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeCollaborations)(h.data)),{rawData:h.data})}))}getCollaborations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,d=(0,s.prepareParams)({status:(0,a.toString)(e.status),fields:e.fields?e.fields.map(a.toString).join(","):void 0,offset:(0,a.toString)(e.offset),limit:(0,a.toString)(e.limit)}),c=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaborations"),method:"GET",params:d,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeCollaborations)(u.data)),{rawData:u.data})}))}getGroupCollaborations(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,d=r.cancellationToken,c=(0,s.prepareParams)({limit:(0,a.toString)(i.limit),offset:(0,a.toString)(i.offset)}),u=(0,s.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/",(0,a.toString)(e),"/collaborations"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:d});return Object.assign(Object.assign({},(0,n.deserializeCollaborations)(p.data)),{rawData:p.data})}))}}},19631:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.MembershipsManager=t.DeleteGroupMembershipByIdHeaders=t.UpdateGroupMembershipByIdHeaders=t.GetGroupMembershipByIdHeaders=t.CreateGroupMembershipHeaders=t.GetGroupMembershipsHeaders=t.GetUserMembershipsHeaders=t.DeleteGroupMembershipByIdOptionals=t.UpdateGroupMembershipByIdOptionals=t.GetGroupMembershipByIdOptionals=t.CreateGroupMembershipOptionals=t.GetGroupMembershipsOptionals=t.GetUserMembershipsOptionals=void 0,t.serializeCreateGroupMembershipRequestBodyUserField=T,t.deserializeCreateGroupMembershipRequestBodyUserField=B,t.serializeCreateGroupMembershipRequestBodyGroupField=C,t.deserializeCreateGroupMembershipRequestBodyGroupField=I,t.serializeCreateGroupMembershipRequestBodyRoleField=A,t.deserializeCreateGroupMembershipRequestBodyRoleField=F,t.serializeCreateGroupMembershipRequestBody=M,t.deserializeCreateGroupMembershipRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateGroupMembershipRequestBody"'});if(null==e.user)throw new c.BoxSdkError({message:'Expecting "user" of type "CreateGroupMembershipRequestBody" to be defined'});const t=B(e.user);if(null==e.group)throw new c.BoxSdkError({message:'Expecting "group" of type "CreateGroupMembershipRequestBody" to be defined'});const r=I(e.group),i=null==e.role?void 0:F(e.role);if(null!=e.configurable_permissions&&!(0,h.sdIsMap)(e.configurable_permissions))throw new c.BoxSdkError({message:'Expecting object for "configurable_permissions" of type "CreateGroupMembershipRequestBody"'});const n=null==e.configurable_permissions?void 0:(0,h.sdIsMap)(e.configurable_permissions)?Object.fromEntries(Object.entries(e.configurable_permissions).map((([e,t])=>[e,function(e){if(!(0,u.sdIsBoolean)(e))throw new c.BoxSdkError({message:'Expecting boolean for "CreateGroupMembershipRequestBody"'});return e}(t)]))):{};return{user:t,group:r,role:i,configurablePermissions:n}},t.serializeUpdateGroupMembershipByIdRequestBodyRoleField=D,t.deserializeUpdateGroupMembershipByIdRequestBodyRoleField=R,t.serializeUpdateGroupMembershipByIdRequestBody=P,t.deserializeUpdateGroupMembershipByIdRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateGroupMembershipByIdRequestBody"'});const t=null==e.role?void 0:R(e.role);if(null!=e.configurable_permissions&&!(0,h.sdIsMap)(e.configurable_permissions))throw new c.BoxSdkError({message:'Expecting object for "configurable_permissions" of type "UpdateGroupMembershipByIdRequestBody"'});const r=null==e.configurable_permissions?void 0:(0,h.sdIsMap)(e.configurable_permissions)?Object.fromEntries(Object.entries(e.configurable_permissions).map((([e,t])=>[e,function(e){if(!(0,u.sdIsBoolean)(e))throw new c.BoxSdkError({message:'Expecting boolean for "UpdateGroupMembershipByIdRequestBody"'});return e}(t)]))):{};return{role:t,configurablePermissions:r}};const n=r(34812),o=r(93695),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f{constructor(e){this.queryParams={},this.headers=new w({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetUserMembershipsOptionals=f;class m{constructor(e){this.queryParams={},this.headers=new _({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetGroupMembershipsOptionals=m;class g{constructor(e){this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateGroupMembershipOptionals=g;class y{constructor(e){this.queryParams={},this.headers=new S({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetGroupMembershipByIdOptionals=y;class v{constructor(e){this.requestBody={},this.queryParams={},this.headers=new k({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateGroupMembershipByIdOptionals=v;class b{constructor(e){this.headers=new E({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteGroupMembershipByIdOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUserMembershipsHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGroupMembershipsHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateGroupMembershipHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGroupMembershipByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateGroupMembershipByIdHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteGroupMembershipByIdHeaders=E;function T(e){return{id:e.id}}function B(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateGroupMembershipRequestBodyUserField"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateGroupMembershipRequestBodyUserField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateGroupMembershipRequestBodyUserField"'});return{id:e.id}}function C(e){return{id:e.id}}function I(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateGroupMembershipRequestBodyGroupField"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateGroupMembershipRequestBodyGroupField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateGroupMembershipRequestBodyGroupField"'});return{id:e.id}}function A(e){return e}function F(e){if("member"==e)return e;if("admin"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateGroupMembershipRequestBodyRoleField"})}function M(e){return{user:T(e.user),group:C(e.group),role:null==e.role?void 0:e.role,configurable_permissions:null==e.configurablePermissions?void 0:e.configurablePermissions}}function D(e){return e}function R(e){if("member"==e)return e;if("admin"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateGroupMembershipByIdRequestBodyRoleField"})}function P(e){return{role:null==e.role?void 0:e.role,configurable_permissions:null==e.configurablePermissions?void 0:e.configurablePermissions}}t.MembershipsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getUserMemberships(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({limit:(0,l.toString)(i.limit),offset:(0,l.toString)(i.offset)}),u=(0,a.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,l.toString)(e),"/memberships"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeGroupMemberships)(p.data)),{rawData:p.data})}))}getGroupMemberships(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({limit:(0,l.toString)(i.limit),offset:(0,l.toString)(i.offset)}),u=(0,a.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/",(0,l.toString)(e),"/memberships"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeGroupMemberships)(p.data)),{rawData:p.data})}))}createGroupMembership(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/group_memberships"),method:"POST",params:c,headers:u,data:M(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeGroupMembership)(p.data)),{rawData:p.data})}))}getGroupMembershipById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/group_memberships/",(0,l.toString)(e)),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeGroupMembership)(p.data)),{rawData:p.data})}))}updateGroupMembershipById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:n.fields?n.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/group_memberships/",(0,l.toString)(e)),method:"PUT",params:u,headers:p,data:P(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeGroupMembership)(h.data)),{rawData:h.data})}))}deleteGroupMembershipById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/group_memberships/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},35561:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.MetadataCascadePoliciesManager=t.ApplyMetadataCascadePolicyHeaders=t.DeleteMetadataCascadePolicyByIdHeaders=t.GetMetadataCascadePolicyByIdHeaders=t.CreateMetadataCascadePolicyHeaders=t.GetMetadataCascadePoliciesHeaders=t.ApplyMetadataCascadePolicyOptionals=t.DeleteMetadataCascadePolicyByIdOptionals=t.GetMetadataCascadePolicyByIdOptionals=t.CreateMetadataCascadePolicyOptionals=t.GetMetadataCascadePoliciesOptionals=void 0,t.serializeCreateMetadataCascadePolicyRequestBodyScopeField=S,t.deserializeCreateMetadataCascadePolicyRequestBodyScopeField=k,t.serializeCreateMetadataCascadePolicyRequestBody=E,t.deserializeCreateMetadataCascadePolicyRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateMetadataCascadePolicyRequestBody"'});if(null==e.folder_id)throw new c.BoxSdkError({message:'Expecting "folder_id" of type "CreateMetadataCascadePolicyRequestBody" to be defined'});if(!(0,u.sdIsString)(e.folder_id))throw new c.BoxSdkError({message:'Expecting string for "folder_id" of type "CreateMetadataCascadePolicyRequestBody"'});const t=e.folder_id;if(null==e.scope)throw new c.BoxSdkError({message:'Expecting "scope" of type "CreateMetadataCascadePolicyRequestBody" to be defined'});const r=k(e.scope);if(null==e.templateKey)throw new c.BoxSdkError({message:'Expecting "templateKey" of type "CreateMetadataCascadePolicyRequestBody" to be defined'});if(!(0,u.sdIsString)(e.templateKey))throw new c.BoxSdkError({message:'Expecting string for "templateKey" of type "CreateMetadataCascadePolicyRequestBody"'});const i=e.templateKey;return{folderId:t,scope:r,templateKey:i}},t.serializeApplyMetadataCascadePolicyRequestBodyConflictResolutionField=T,t.deserializeApplyMetadataCascadePolicyRequestBodyConflictResolutionField=B,t.serializeApplyMetadataCascadePolicyRequestBody=C,t.deserializeApplyMetadataCascadePolicyRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "ApplyMetadataCascadePolicyRequestBody"'});if(null==e.conflict_resolution)throw new c.BoxSdkError({message:'Expecting "conflict_resolution" of type "ApplyMetadataCascadePolicyRequestBody" to be defined'});return{conflictResolution:B(e.conflict_resolution)}};const n=r(93267),o=r(45243),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetMetadataCascadePoliciesOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateMetadataCascadePolicyOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetMetadataCascadePolicyByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteMetadataCascadePolicyByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.ApplyMetadataCascadePolicyOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetMetadataCascadePoliciesHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateMetadataCascadePolicyHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetMetadataCascadePolicyByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteMetadataCascadePolicyByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.ApplyMetadataCascadePolicyHeaders=x;function S(e){return e}function k(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateMetadataCascadePolicyRequestBodyScopeField"})}function E(e){return{folder_id:e.folderId,scope:e.scope,templateKey:e.templateKey}}function T(e){return e}function B(e){if("none"==e)return e;if("overwrite"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize ApplyMetadataCascadePolicyRequestBodyConflictResolutionField"})}function C(e){return{conflict_resolution:e.conflictResolution}}t.MetadataCascadePoliciesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getMetadataCascadePolicies(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)({folder_id:(0,l.toString)(e.folderId),owner_enterprise_id:(0,l.toString)(e.ownerEnterpriseId),marker:(0,l.toString)(e.marker),offset:(0,l.toString)(e.offset)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_cascade_policies"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeMetadataCascadePolicies)(u.data)),{rawData:u.data})}))}createMetadataCascadePolicy(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_cascade_policies"),method:"POST",headers:s,data:E(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeMetadataCascadePolicy)(l.data)),{rawData:l.data})}))}getMetadataCascadePolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_cascade_policies/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeMetadataCascadePolicy)(c.data)),{rawData:c.data})}))}deleteMetadataCascadePolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_cascade_policies/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}applyMetadataCascadePolicy(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new y({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,a.prepareParams)(Object.assign({},n.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_cascade_policies/",(0,l.toString)(e),"/apply"),method:"POST",headers:s,data:C(t),contentType:"application/json",responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}}},3670:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.MetadataTemplatesManager=t.CreateMetadataTemplateHeaders=t.GetEnterpriseMetadataTemplatesHeaders=t.GetGlobalMetadataTemplatesHeaders=t.GetMetadataTemplateByIdHeaders=t.DeleteMetadataTemplateHeaders=t.UpdateMetadataTemplateHeaders=t.GetMetadataTemplateHeaders=t.GetMetadataTemplatesByInstanceIdHeaders=t.CreateMetadataTemplateOptionals=t.GetMetadataTemplateByIdOptionals=t.DeleteMetadataTemplateOptionals=t.UpdateMetadataTemplateOptionals=t.GetMetadataTemplateOptionals=t.GetMetadataTemplatesByInstanceIdOptionals=void 0,t.serializeGetMetadataTemplateScope=function(e){return e},t.deserializeGetMetadataTemplateScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetMetadataTemplateScope"})},t.serializeUpdateMetadataTemplateScope=function(e){return e},t.deserializeUpdateMetadataTemplateScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateMetadataTemplateScope"})},t.serializeUpdateMetadataTemplateRequestBodyOpField=I,t.deserializeUpdateMetadataTemplateRequestBodyOpField=A,t.serializeUpdateMetadataTemplateRequestBody=F,t.deserializeUpdateMetadataTemplateRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateMetadataTemplateRequestBody"'});if(null==e.op)throw new c.BoxSdkError({message:'Expecting "op" of type "UpdateMetadataTemplateRequestBody" to be defined'});const t=A(e.op);if(null!=e.data&&!(0,f.sdIsMap)(e.data))throw new c.BoxSdkError({message:'Expecting object for "data" of type "UpdateMetadataTemplateRequestBody"'});const r=null==e.data?void 0:(0,f.sdIsMap)(e.data)?Object.fromEntries(Object.entries(e.data).map((([e,t])=>[e,t]))):{};if(null!=e.fieldKey&&!(0,p.sdIsString)(e.fieldKey))throw new c.BoxSdkError({message:'Expecting string for "fieldKey" of type "UpdateMetadataTemplateRequestBody"'});const i=null==e.fieldKey?void 0:e.fieldKey;if(null!=e.fieldKeys&&!(0,h.sdIsList)(e.fieldKeys))throw new c.BoxSdkError({message:'Expecting array for "fieldKeys" of type "UpdateMetadataTemplateRequestBody"'});const n=null==e.fieldKeys?void 0:(0,h.sdIsList)(e.fieldKeys)?e.fieldKeys.map((function(e){if(!(0,p.sdIsString)(e))throw new c.BoxSdkError({message:'Expecting string for "UpdateMetadataTemplateRequestBody"'});return e})):[];if(null!=e.enumOptionKey&&!(0,p.sdIsString)(e.enumOptionKey))throw new c.BoxSdkError({message:'Expecting string for "enumOptionKey" of type "UpdateMetadataTemplateRequestBody"'});const o=null==e.enumOptionKey?void 0:e.enumOptionKey;if(null!=e.enumOptionKeys&&!(0,h.sdIsList)(e.enumOptionKeys))throw new c.BoxSdkError({message:'Expecting array for "enumOptionKeys" of type "UpdateMetadataTemplateRequestBody"'});const s=null==e.enumOptionKeys?void 0:(0,h.sdIsList)(e.enumOptionKeys)?e.enumOptionKeys.map((function(e){if(!(0,p.sdIsString)(e))throw new c.BoxSdkError({message:'Expecting string for "UpdateMetadataTemplateRequestBody"'});return e})):[];if(null!=e.multiSelectOptionKey&&!(0,p.sdIsString)(e.multiSelectOptionKey))throw new c.BoxSdkError({message:'Expecting string for "multiSelectOptionKey" of type "UpdateMetadataTemplateRequestBody"'});const a=null==e.multiSelectOptionKey?void 0:e.multiSelectOptionKey;if(null!=e.multiSelectOptionKeys&&!(0,h.sdIsList)(e.multiSelectOptionKeys))throw new c.BoxSdkError({message:'Expecting array for "multiSelectOptionKeys" of type "UpdateMetadataTemplateRequestBody"'});const l=null==e.multiSelectOptionKeys?void 0:(0,h.sdIsList)(e.multiSelectOptionKeys)?e.multiSelectOptionKeys.map((function(e){if(!(0,p.sdIsString)(e))throw new c.BoxSdkError({message:'Expecting string for "UpdateMetadataTemplateRequestBody"'});return e})):[];return{op:t,data:r,fieldKey:i,fieldKeys:n,enumOptionKey:o,enumOptionKeys:s,multiSelectOptionKey:a,multiSelectOptionKeys:l}},t.serializeDeleteMetadataTemplateScope=function(e){return e},t.deserializeDeleteMetadataTemplateScope=function(e){if("global"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize DeleteMetadataTemplateScope"})},t.serializeCreateMetadataTemplateRequestBodyFieldsTypeField=M,t.deserializeCreateMetadataTemplateRequestBodyFieldsTypeField=D,t.serializeCreateMetadataTemplateRequestBodyFieldsOptionsField=R,t.deserializeCreateMetadataTemplateRequestBodyFieldsOptionsField=P,t.serializeCreateMetadataTemplateRequestBodyFieldsField=O,t.deserializeCreateMetadataTemplateRequestBodyFieldsField=z,t.serializeCreateMetadataTemplateRequestBody=N,t.deserializeCreateMetadataTemplateRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateMetadataTemplateRequestBody"'});if(null==e.scope)throw new c.BoxSdkError({message:'Expecting "scope" of type "CreateMetadataTemplateRequestBody" to be defined'});if(!(0,p.sdIsString)(e.scope))throw new c.BoxSdkError({message:'Expecting string for "scope" of type "CreateMetadataTemplateRequestBody"'});const t=e.scope;if(null!=e.templateKey&&!(0,p.sdIsString)(e.templateKey))throw new c.BoxSdkError({message:'Expecting string for "templateKey" of type "CreateMetadataTemplateRequestBody"'});const r=null==e.templateKey?void 0:e.templateKey;if(null==e.displayName)throw new c.BoxSdkError({message:'Expecting "displayName" of type "CreateMetadataTemplateRequestBody" to be defined'});if(!(0,p.sdIsString)(e.displayName))throw new c.BoxSdkError({message:'Expecting string for "displayName" of type "CreateMetadataTemplateRequestBody"'});const i=e.displayName;if(null!=e.hidden&&!(0,u.sdIsBoolean)(e.hidden))throw new c.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateMetadataTemplateRequestBody"'});const n=null==e.hidden?void 0:e.hidden;if(null!=e.fields&&!(0,h.sdIsList)(e.fields))throw new c.BoxSdkError({message:'Expecting array for "fields" of type "CreateMetadataTemplateRequestBody"'});const o=null==e.fields?void 0:(0,h.sdIsList)(e.fields)?e.fields.map((function(e){return z(e)})):[];if(null!=e.copyInstanceOnItemCopy&&!(0,u.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new c.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "CreateMetadataTemplateRequestBody"'});const s=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;return{scope:t,templateKey:r,displayName:i,hidden:n,fields:o,copyInstanceOnItemCopy:s}};const n=r(12444),o=r(81631),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetMetadataTemplatesByInstanceIdOptionals=m;class g{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetMetadataTemplateOptionals=g;class y{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateMetadataTemplateOptionals=y;class v{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteMetadataTemplateOptionals=v;class b{constructor(e){this.headers=new E({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetMetadataTemplateByIdOptionals=b;class w{constructor(e){this.headers=new C({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateMetadataTemplateOptionals=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetMetadataTemplatesByInstanceIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetMetadataTemplateHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateMetadataTemplateHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteMetadataTemplateHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetMetadataTemplateByIdHeaders=E;class T{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetGlobalMetadataTemplatesHeaders=T;class B{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetEnterpriseMetadataTemplatesHeaders=B;class C{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateMetadataTemplateHeaders=C;function I(e){return e}function A(e){if("editTemplate"==e)return e;if("addField"==e)return e;if("reorderFields"==e)return e;if("addEnumOption"==e)return e;if("reorderEnumOptions"==e)return e;if("reorderMultiSelectOptions"==e)return e;if("addMultiSelectOption"==e)return e;if("editField"==e)return e;if("removeField"==e)return e;if("editEnumOption"==e)return e;if("removeEnumOption"==e)return e;if("editMultiSelectOption"==e)return e;if("removeMultiSelectOption"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateMetadataTemplateRequestBodyOpField"})}function F(e){return{op:e.op,data:null==e.data?void 0:Object.fromEntries(Object.entries(e.data).map((([e,t])=>[e,t]))),fieldKey:null==e.fieldKey?void 0:e.fieldKey,fieldKeys:null==e.fieldKeys?void 0:e.fieldKeys.map((function(e){return e})),enumOptionKey:null==e.enumOptionKey?void 0:e.enumOptionKey,enumOptionKeys:null==e.enumOptionKeys?void 0:e.enumOptionKeys.map((function(e){return e})),multiSelectOptionKey:null==e.multiSelectOptionKey?void 0:e.multiSelectOptionKey,multiSelectOptionKeys:null==e.multiSelectOptionKeys?void 0:e.multiSelectOptionKeys.map((function(e){return e}))}}function M(e){return e}function D(e){if("string"==e)return e;if("float"==e)return e;if("date"==e)return e;if("enum"==e)return e;if("multiSelect"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateMetadataTemplateRequestBodyFieldsTypeField"})}function R(e){return{key:e.key}}function P(e){if(!(0,f.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateMetadataTemplateRequestBodyFieldsOptionsField"'});if(null==e.key)throw new c.BoxSdkError({message:'Expecting "key" of type "CreateMetadataTemplateRequestBodyFieldsOptionsField" to be defined'});if(!(0,p.sdIsString)(e.key))throw new c.BoxSdkError({message:'Expecting string for "key" of type "CreateMetadataTemplateRequestBodyFieldsOptionsField"'});return{key:e.key}}function O(e){return{type:e.type,key:e.key,displayName:e.displayName,description:null==e.description?void 0:e.description,hidden:null==e.hidden?void 0:e.hidden,options:null==e.options?void 0:e.options.map((function(e){return R(e)}))}}function z(e){if(!(0,f.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateMetadataTemplateRequestBodyFieldsField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateMetadataTemplateRequestBodyFieldsField" to be defined'});const t=D(e.type);if(null==e.key)throw new c.BoxSdkError({message:'Expecting "key" of type "CreateMetadataTemplateRequestBodyFieldsField" to be defined'});if(!(0,p.sdIsString)(e.key))throw new c.BoxSdkError({message:'Expecting string for "key" of type "CreateMetadataTemplateRequestBodyFieldsField"'});const r=e.key;if(null==e.displayName)throw new c.BoxSdkError({message:'Expecting "displayName" of type "CreateMetadataTemplateRequestBodyFieldsField" to be defined'});if(!(0,p.sdIsString)(e.displayName))throw new c.BoxSdkError({message:'Expecting string for "displayName" of type "CreateMetadataTemplateRequestBodyFieldsField"'});const i=e.displayName;if(null!=e.description&&!(0,p.sdIsString)(e.description))throw new c.BoxSdkError({message:'Expecting string for "description" of type "CreateMetadataTemplateRequestBodyFieldsField"'});const n=null==e.description?void 0:e.description;if(null!=e.hidden&&!(0,u.sdIsBoolean)(e.hidden))throw new c.BoxSdkError({message:'Expecting boolean for "hidden" of type "CreateMetadataTemplateRequestBodyFieldsField"'});const o=null==e.hidden?void 0:e.hidden;if(null!=e.options&&!(0,h.sdIsList)(e.options))throw new c.BoxSdkError({message:'Expecting array for "options" of type "CreateMetadataTemplateRequestBodyFieldsField"'});return{type:t,key:r,displayName:i,description:n,hidden:o,options:null==e.options?void 0:(0,h.sdIsList)(e.options)?e.options.map((function(e){return P(e)})):[]}}function N(e){return{scope:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,displayName:e.displayName,hidden:null==e.hidden?void 0:e.hidden,fields:null==e.fields?void 0:e.fields.map((function(e){return O(e)})),copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy}}t.MetadataTemplatesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getMetadataTemplatesByInstanceId(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)({metadata_instance_id:(0,l.toString)(e.metadataInstanceId)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeMetadataTemplates)(u.data)),{rawData:u.data})}))}getMetadataTemplate(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,s=i.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/",(0,l.toString)(e),"/",(0,l.toString)(t),"/schema"),method:"GET",headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeMetadataTemplate)(u.data)),{rawData:u.data})}))}updateMetadataTemplate(e,t,r){return i(this,arguments,void 0,(function*(e,t,r,i={}){const n=new y({headers:i.headers,cancellationToken:i.cancellationToken}),s=n.headers,c=n.cancellationToken,u=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/",(0,l.toString)(e),"/",(0,l.toString)(t),"/schema"),method:"PUT",headers:u,data:r.map(F),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,o.deserializeMetadataTemplate)(p.data)),{rawData:p.data})}))}deleteMetadataTemplate(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new v({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,a.prepareParams)(Object.assign({},n.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/",(0,l.toString)(e),"/",(0,l.toString)(t),"/schema"),method:"DELETE",headers:s,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}getMetadataTemplateById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeMetadataTemplate)(c.data)),{rawData:c.data})}))}getGlobalMetadataTemplates(){return i(this,arguments,void 0,(function*(e={},t=new T({}),r){const i=new T({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/global"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeMetadataTemplates)(c.data)),{rawData:c.data})}))}getEnterpriseMetadataTemplates(){return i(this,arguments,void 0,(function*(e={},t=new B({}),r){const i=new B({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/enterprise"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeMetadataTemplates)(c.data)),{rawData:c.data})}))}createMetadataTemplate(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_templates/schema"),method:"POST",headers:s,data:N(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeMetadataTemplate)(l.data)),{rawData:l.data})}))}}},31395:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.RecentItemsManager=t.GetRecentItemsHeaders=void 0;const n=r(62325),o=r(31210),s=r(93845),a=r(93845),l=r(84143);class d{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetRecentItemsHeaders=d;t.RecentItemsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getRecentItems(){return i(this,arguments,void 0,(function*(e={},t=new d({}),r){const i=new d({extraHeaders:t.extraHeaders}),o=(0,s.prepareParams)({fields:e.fields?e.fields.map(a.toString).join(","):void 0,limit:(0,a.toString)(e.limit),marker:(0,a.toString)(e.marker)}),c=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/recent_items"),method:"GET",params:o,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeRecentItems)(u.data)),{rawData:u.data})}))}}},95566:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPoliciesManager=t.DeleteRetentionPolicyByIdHeaders=t.UpdateRetentionPolicyByIdHeaders=t.GetRetentionPolicyByIdHeaders=t.CreateRetentionPolicyHeaders=t.GetRetentionPoliciesHeaders=t.DeleteRetentionPolicyByIdOptionals=t.UpdateRetentionPolicyByIdOptionals=t.GetRetentionPolicyByIdOptionals=t.CreateRetentionPolicyOptionals=void 0,t.serializeGetRetentionPoliciesQueryParamsPolicyTypeField=function(e){return e},t.deserializeGetRetentionPoliciesQueryParamsPolicyTypeField=function(e){if("finite"==e)return e;if("indefinite"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize GetRetentionPoliciesQueryParamsPolicyTypeField"})},t.serializeCreateRetentionPolicyRequestBodyPolicyTypeField=C,t.deserializeCreateRetentionPolicyRequestBodyPolicyTypeField=I,t.serializeCreateRetentionPolicyRequestBodyDispositionActionField=A,t.deserializeCreateRetentionPolicyRequestBodyDispositionActionField=F,t.serializeCreateRetentionPolicyRequestBodyRetentionTypeField=M,t.deserializeCreateRetentionPolicyRequestBodyRetentionTypeField=D,t.serializeCreateRetentionPolicyRequestBody=R,t.deserializeCreateRetentionPolicyRequestBody=function(e){if(!(0,v.sdIsMap)(e))throw new f.BoxSdkError({message:'Expecting a map for "CreateRetentionPolicyRequestBody"'});if(null==e.policy_name)throw new f.BoxSdkError({message:'Expecting "policy_name" of type "CreateRetentionPolicyRequestBody" to be defined'});if(!(0,g.sdIsString)(e.policy_name))throw new f.BoxSdkError({message:'Expecting string for "policy_name" of type "CreateRetentionPolicyRequestBody"'});const t=e.policy_name;if(null!=e.description&&!(0,g.sdIsString)(e.description))throw new f.BoxSdkError({message:'Expecting string for "description" of type "CreateRetentionPolicyRequestBody"'});const r=null==e.description?void 0:e.description;if(null==e.policy_type)throw new f.BoxSdkError({message:'Expecting "policy_type" of type "CreateRetentionPolicyRequestBody" to be defined'});const i=I(e.policy_type);if(null==e.disposition_action)throw new f.BoxSdkError({message:'Expecting "disposition_action" of type "CreateRetentionPolicyRequestBody" to be defined'});const n=F(e.disposition_action);if(null!=e.retention_length&&!(0,g.sdIsString)(e.retention_length))throw new f.BoxSdkError({message:'Expecting string for "retention_length" of type "CreateRetentionPolicyRequestBody"'});const o=null==e.retention_length?void 0:e.retention_length,s=null==e.retention_type?void 0:D(e.retention_type);if(null!=e.can_owner_extend_retention&&!(0,m.sdIsBoolean)(e.can_owner_extend_retention))throw new f.BoxSdkError({message:'Expecting boolean for "can_owner_extend_retention" of type "CreateRetentionPolicyRequestBody"'});const l=null==e.can_owner_extend_retention?void 0:e.can_owner_extend_retention;if(null!=e.are_owners_notified&&!(0,m.sdIsBoolean)(e.are_owners_notified))throw new f.BoxSdkError({message:'Expecting boolean for "are_owners_notified" of type "CreateRetentionPolicyRequestBody"'});const d=null==e.are_owners_notified?void 0:e.are_owners_notified;if(null!=e.custom_notification_recipients&&!(0,y.sdIsList)(e.custom_notification_recipients))throw new f.BoxSdkError({message:'Expecting array for "custom_notification_recipients" of type "CreateRetentionPolicyRequestBody"'});const c=null==e.custom_notification_recipients?void 0:(0,y.sdIsList)(e.custom_notification_recipients)?e.custom_notification_recipients.map((function(e){return(0,a.deserializeUserMini)(e)})):[];return{policyName:t,description:r,policyType:i,dispositionAction:n,retentionLength:o,retentionType:s,canOwnerExtendRetention:l,areOwnersNotified:d,customNotificationRecipients:c}},t.serializeUpdateRetentionPolicyByIdRequestBody=P,t.deserializeUpdateRetentionPolicyByIdRequestBody=function(e){if(!(0,v.sdIsMap)(e))throw new f.BoxSdkError({message:'Expecting a map for "UpdateRetentionPolicyByIdRequestBody"'});if(null!=e.policy_name&&!(0,g.sdIsString)(e.policy_name))throw new f.BoxSdkError({message:'Expecting string for "policy_name" of type "UpdateRetentionPolicyByIdRequestBody"'});const t=null==e.policy_name?void 0:e.policy_name;if(null!=e.description&&!(0,g.sdIsString)(e.description))throw new f.BoxSdkError({message:'Expecting string for "description" of type "UpdateRetentionPolicyByIdRequestBody"'});const r=null==e.description?void 0:e.description;if(null!=e.disposition_action&&!(0,g.sdIsString)(e.disposition_action))throw new f.BoxSdkError({message:'Expecting string for "disposition_action" of type "UpdateRetentionPolicyByIdRequestBody"'});const i=null==e.disposition_action?void 0:e.disposition_action;if(null!=e.retention_type&&!(0,g.sdIsString)(e.retention_type))throw new f.BoxSdkError({message:'Expecting string for "retention_type" of type "UpdateRetentionPolicyByIdRequestBody"'});const n=null==e.retention_type?void 0:e.retention_type;if(null!=e.retention_length&&!(0,g.sdIsString)(e.retention_length))throw new f.BoxSdkError({message:'Expecting string for "retention_length" of type "UpdateRetentionPolicyByIdRequestBody"'});const o=null==e.retention_length?void 0:e.retention_length;if(null!=e.status&&!(0,g.sdIsString)(e.status))throw new f.BoxSdkError({message:'Expecting string for "status" of type "UpdateRetentionPolicyByIdRequestBody"'});const s=null==e.status?void 0:e.status;if(null!=e.can_owner_extend_retention&&!(0,m.sdIsBoolean)(e.can_owner_extend_retention))throw new f.BoxSdkError({message:'Expecting boolean for "can_owner_extend_retention" of type "UpdateRetentionPolicyByIdRequestBody"'});const a=null==e.can_owner_extend_retention?void 0:e.can_owner_extend_retention;if(null!=e.are_owners_notified&&!(0,m.sdIsBoolean)(e.are_owners_notified))throw new f.BoxSdkError({message:'Expecting boolean for "are_owners_notified" of type "UpdateRetentionPolicyByIdRequestBody"'});const l=null==e.are_owners_notified?void 0:e.are_owners_notified;if(null!=e.custom_notification_recipients&&!(0,y.sdIsList)(e.custom_notification_recipients))throw new f.BoxSdkError({message:'Expecting array for "custom_notification_recipients" of type "UpdateRetentionPolicyByIdRequestBody"'});const c=null==e.custom_notification_recipients?void 0:(0,y.sdIsList)(e.custom_notification_recipients)?e.custom_notification_recipients.map((function(e){return(0,d.deserializeUserBase)(e)})):[];return{policyName:t,description:r,dispositionAction:i,retentionType:n,retentionLength:o,status:s,canOwnerExtendRetention:a,areOwnersNotified:l,customNotificationRecipients:c}};const n=r(6756),o=r(60960),s=r(95408),a=r(95408),l=r(78366),d=r(78366),c=r(31210),u=r(93845),p=r(93845),h=r(84143),f=r(72631),m=r(50793),g=r(50793),y=r(50793),v=r(50793);class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateRetentionPolicyOptionals=b;class w{constructor(e){this.queryParams={},this.headers=new E({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetRetentionPolicyByIdOptionals=w;class _{constructor(e){this.requestBody={},this.headers=new T({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateRetentionPolicyByIdOptionals=_;class x{constructor(e){this.headers=new B({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteRetentionPolicyByIdOptionals=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetRetentionPoliciesHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateRetentionPolicyHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetRetentionPolicyByIdHeaders=E;class T{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateRetentionPolicyByIdHeaders=T;class B{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteRetentionPolicyByIdHeaders=B;function C(e){return e}function I(e){if("finite"==e)return e;if("indefinite"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize CreateRetentionPolicyRequestBodyPolicyTypeField"})}function A(e){return e}function F(e){if("permanently_delete"==e)return e;if("remove_retention"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize CreateRetentionPolicyRequestBodyDispositionActionField"})}function M(e){return e}function D(e){if("modifiable"==e)return e;if("non_modifiable"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize CreateRetentionPolicyRequestBodyRetentionTypeField"})}function R(e){return{policy_name:e.policyName,description:null==e.description?void 0:e.description,policy_type:e.policyType,disposition_action:e.dispositionAction,retention_length:null==e.retentionLength?void 0:e.retentionLength,retention_type:null==e.retentionType?void 0:e.retentionType,can_owner_extend_retention:null==e.canOwnerExtendRetention?void 0:e.canOwnerExtendRetention,are_owners_notified:null==e.areOwnersNotified?void 0:e.areOwnersNotified,custom_notification_recipients:null==e.customNotificationRecipients?void 0:e.customNotificationRecipients.map((function(e){return(0,s.serializeUserMini)(e)}))}}function P(e){return{policy_name:null==e.policyName?void 0:e.policyName,description:null==e.description?void 0:e.description,disposition_action:null==e.dispositionAction?void 0:e.dispositionAction,retention_type:null==e.retentionType?void 0:e.retentionType,retention_length:null==e.retentionLength?void 0:e.retentionLength,status:null==e.status?void 0:e.status,can_owner_extend_retention:null==e.canOwnerExtendRetention?void 0:e.canOwnerExtendRetention,are_owners_notified:null==e.areOwnersNotified?void 0:e.areOwnersNotified,custom_notification_recipients:null==e.customNotificationRecipients?void 0:e.customNotificationRecipients.map((function(e){return(0,l.serializeUserBase)(e)}))}}t.RetentionPoliciesManager=class{constructor(e){this.networkSession=new c.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getRetentionPolicies(){return i(this,arguments,void 0,(function*(e={},t=new S({}),r){const i=new S({extraHeaders:t.extraHeaders}),o=(0,u.prepareParams)({policy_name:(0,p.toString)(e.policyName),policy_type:(0,p.toString)(e.policyType),created_by_user_id:(0,p.toString)(e.createdByUserId),fields:e.fields?e.fields.map(p.toString).join(","):void 0,limit:(0,p.toString)(e.limit),marker:(0,p.toString)(e.marker)}),s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeRetentionPolicies)(a.data)),{rawData:a.data})}))}createRetentionPolicy(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies"),method:"POST",headers:s,data:R(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeRetentionPolicy)(a.data)),{rawData:a.data})}))}getRetentionPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,a=(0,u.prepareParams)({fields:i.fields?i.fields.map(p.toString).join(","):void 0}),l=(0,u.prepareParams)(Object.assign({},n.extraHeaders)),d=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies/",(0,p.toString)(e)),method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeRetentionPolicy)(d.data)),{rawData:d.data})}))}updateRetentionPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new _({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,a=(0,u.prepareParams)(Object.assign({},n.extraHeaders)),l=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies/",(0,p.toString)(e)),method:"PUT",headers:a,data:P(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeRetentionPolicy)(l.data)),{rawData:l.data})}))}deleteRetentionPolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new x({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,u.prepareParams)(Object.assign({},i.extraHeaders));yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies/",(0,p.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},30004:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPolicyAssignmentsManager=t.GetFilesUnderRetentionPolicyAssignmentHeaders=t.DeleteRetentionPolicyAssignmentByIdHeaders=t.GetRetentionPolicyAssignmentByIdHeaders=t.CreateRetentionPolicyAssignmentHeaders=t.GetRetentionPolicyAssignmentsHeaders=t.GetFilesUnderRetentionPolicyAssignmentOptionals=t.DeleteRetentionPolicyAssignmentByIdOptionals=t.GetRetentionPolicyAssignmentByIdOptionals=t.CreateRetentionPolicyAssignmentOptionals=t.GetRetentionPolicyAssignmentsOptionals=void 0,t.serializeGetRetentionPolicyAssignmentsQueryParamsTypeField=function(e){return e},t.deserializeGetRetentionPolicyAssignmentsQueryParamsTypeField=function(e){if("folder"==e)return e;if("enterprise"==e)return e;if("metadata_template"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize GetRetentionPolicyAssignmentsQueryParamsTypeField"})},t.serializeCreateRetentionPolicyAssignmentRequestBodyAssignToTypeField=E,t.deserializeCreateRetentionPolicyAssignmentRequestBodyAssignToTypeField=T,t.serializeCreateRetentionPolicyAssignmentRequestBodyAssignToField=B,t.deserializeCreateRetentionPolicyAssignmentRequestBodyAssignToField=C,t.serializeCreateRetentionPolicyAssignmentRequestBodyFilterFieldsField=I,t.deserializeCreateRetentionPolicyAssignmentRequestBodyFilterFieldsField=A,t.serializeCreateRetentionPolicyAssignmentRequestBody=F,t.deserializeCreateRetentionPolicyAssignmentRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateRetentionPolicyAssignmentRequestBody"'});if(null==e.policy_id)throw new u.BoxSdkError({message:'Expecting "policy_id" of type "CreateRetentionPolicyAssignmentRequestBody" to be defined'});if(!(0,p.sdIsString)(e.policy_id))throw new u.BoxSdkError({message:'Expecting string for "policy_id" of type "CreateRetentionPolicyAssignmentRequestBody"'});const t=e.policy_id;if(null==e.assign_to)throw new u.BoxSdkError({message:'Expecting "assign_to" of type "CreateRetentionPolicyAssignmentRequestBody" to be defined'});const r=C(e.assign_to);if(null!=e.filter_fields&&!(0,h.sdIsList)(e.filter_fields))throw new u.BoxSdkError({message:'Expecting array for "filter_fields" of type "CreateRetentionPolicyAssignmentRequestBody"'});const i=null==e.filter_fields?void 0:(0,h.sdIsList)(e.filter_fields)?e.filter_fields.map((function(e){return A(e)})):[];if(null!=e.start_date_field&&!(0,p.sdIsString)(e.start_date_field))throw new u.BoxSdkError({message:'Expecting string for "start_date_field" of type "CreateRetentionPolicyAssignmentRequestBody"'});const n=null==e.start_date_field?void 0:e.start_date_field;return{policyId:t,assignTo:r,filterFields:i,startDateField:n}};const n=r(86162),o=r(62261),s=r(8391),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.queryParams={},this.headers=new w({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetRetentionPolicyAssignmentsOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateRetentionPolicyAssignmentOptionals=g;class y{constructor(e){this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetRetentionPolicyAssignmentByIdOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteRetentionPolicyAssignmentByIdOptionals=v;class b{constructor(e){this.queryParams={},this.headers=new k({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFilesUnderRetentionPolicyAssignmentOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetRetentionPolicyAssignmentsHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateRetentionPolicyAssignmentHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetRetentionPolicyAssignmentByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteRetentionPolicyAssignmentByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFilesUnderRetentionPolicyAssignmentHeaders=k;function E(e){return e}function T(e){if("enterprise"==e)return e;if("folder"==e)return e;if("metadata_template"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize CreateRetentionPolicyAssignmentRequestBodyAssignToTypeField"})}function B(e){return{type:e.type,id:null==e.id?void 0:e.id}}function C(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateRetentionPolicyAssignmentRequestBodyAssignToField"'});if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "CreateRetentionPolicyAssignmentRequestBodyAssignToField" to be defined'});const t=T(e.type);if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CreateRetentionPolicyAssignmentRequestBodyAssignToField"'});return{type:t,id:null==e.id?void 0:e.id}}function I(e){return{field:null==e.field?void 0:e.field,value:null==e.value?void 0:e.value}}function A(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateRetentionPolicyAssignmentRequestBodyFilterFieldsField"'});if(null!=e.field&&!(0,p.sdIsString)(e.field))throw new u.BoxSdkError({message:'Expecting string for "field" of type "CreateRetentionPolicyAssignmentRequestBodyFilterFieldsField"'});const t=null==e.field?void 0:e.field;if(null!=e.value&&!(0,p.sdIsString)(e.value))throw new u.BoxSdkError({message:'Expecting string for "value" of type "CreateRetentionPolicyAssignmentRequestBodyFilterFieldsField"'});return{field:t,value:null==e.value?void 0:e.value}}function F(e){return{policy_id:e.policyId,assign_to:B(e.assignTo),filter_fields:null==e.filterFields?void 0:e.filterFields.map((function(e){return I(e)})),start_date_field:null==e.startDateField?void 0:e.startDateField}}t.RetentionPolicyAssignmentsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getRetentionPolicyAssignments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)({type:(0,d.toString)(i.type),fields:i.fields?i.fields.map(d.toString).join(","):void 0,marker:(0,d.toString)(i.marker),limit:(0,d.toString)(i.limit)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policies/",(0,d.toString)(e),"/assignments"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeRetentionPolicyAssignments)(p.data)),{rawData:p.data})}))}createRetentionPolicyAssignment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policy_assignments"),method:"POST",headers:s,data:F(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeRetentionPolicyAssignment)(a.data)),{rawData:a.data})}))}getRetentionPolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)({fields:i.fields?i.fields.map(d.toString).join(","):void 0}),u=(0,l.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policy_assignments/",(0,d.toString)(e)),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeRetentionPolicyAssignment)(p.data)),{rawData:p.data})}))}deleteRetentionPolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policy_assignments/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getFilesUnderRetentionPolicyAssignment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,a=(0,l.prepareParams)({marker:(0,d.toString)(i.marker),limit:(0,d.toString)(i.limit)}),u=(0,l.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/retention_policy_assignments/",(0,d.toString)(e),"/files_under_retention"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,s.deserializeFilesUnderRetention)(p.data)),{rawData:p.data})}))}}},92102:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SearchManager=t.SearchForContentHeaders=t.SearchByMetadataQueryHeaders=t.SearchByMetadataQueryOptionals=void 0,t.serializeSearchForContentQueryParamsScopeField=function(e){return e},t.deserializeSearchForContentQueryParamsScopeField=function(e){if("user_content"==e)return e;if("enterprise_content"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsScopeField"})},t.serializeSearchForContentQueryParamsContentTypesField=function(e){return e},t.deserializeSearchForContentQueryParamsContentTypesField=function(e){if("name"==e)return e;if("description"==e)return e;if("file_content"==e)return e;if("comments"==e)return e;if("tag"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsContentTypesField"})},t.serializeSearchForContentQueryParamsTypeField=function(e){return e},t.deserializeSearchForContentQueryParamsTypeField=function(e){if("file"==e)return e;if("folder"==e)return e;if("web_link"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsTypeField"})},t.serializeSearchForContentQueryParamsTrashContentField=function(e){return e},t.deserializeSearchForContentQueryParamsTrashContentField=function(e){if("non_trashed_only"==e)return e;if("trashed_only"==e)return e;if("all_items"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsTrashContentField"})},t.serializeSearchForContentQueryParamsSortField=function(e){return e},t.deserializeSearchForContentQueryParamsSortField=function(e){if("modified_at"==e)return e;if("relevance"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsSortField"})},t.serializeSearchForContentQueryParamsDirectionField=function(e){return e},t.deserializeSearchForContentQueryParamsDirectionField=function(e){if("DESC"==e)return e;if("ASC"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize SearchForContentQueryParamsDirectionField"})};const n=r(90863),o=r(26775),s=r(76427),a=r(56211),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(50793),h=r(72631);class f{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.SearchByMetadataQueryOptionals=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.SearchByMetadataQueryHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.SearchForContentHeaders=g;t.SearchManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}searchByMetadataQuery(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/metadata_queries/execute_read"),method:"POST",headers:a,data:(0,o.serializeMetadataQuery)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeMetadataQueryResults)(l.data)),{rawData:l.data})}))}searchForContent(){return i(this,arguments,void 0,(function*(e={},t=new g({}),r){const i=new g({extraHeaders:t.extraHeaders}),n=(0,d.prepareParams)({query:(0,c.toString)(e.query),scope:(0,c.toString)(e.scope),file_extensions:e.fileExtensions?e.fileExtensions.map(c.toString).join(","):void 0,created_at_range:e.createdAtRange?e.createdAtRange.map(c.toString).join(","):void 0,updated_at_range:e.updatedAtRange?e.updatedAtRange.map(c.toString).join(","):void 0,size_range:e.sizeRange?e.sizeRange.map(c.toString).join(","):void 0,owner_user_ids:e.ownerUserIds?e.ownerUserIds.map(c.toString).join(","):void 0,recent_updater_user_ids:e.recentUpdaterUserIds?e.recentUpdaterUserIds.map(c.toString).join(","):void 0,ancestor_folder_ids:e.ancestorFolderIds?e.ancestorFolderIds.map(c.toString).join(","):void 0,content_types:e.contentTypes?e.contentTypes.map(c.toString).join(","):void 0,type:(0,c.toString)(e.type),trash_content:(0,c.toString)(e.trashContent),mdfilters:e.mdfilters?(0,p.sdToJson)(e.mdfilters.map(a.serializeMetadataFilter)):void 0,sort:(0,c.toString)(e.sort),direction:(0,c.toString)(e.direction),limit:(0,c.toString)(e.limit),include_recent_shared_links:(0,c.toString)(e.includeRecentSharedLinks),fields:e.fields?e.fields.map(c.toString).join(","):void 0,offset:(0,c.toString)(e.offset),deleted_user_ids:e.deletedUserIds?e.deletedUserIds.map(c.toString).join(","):void 0,deleted_at_range:e.deletedAtRange?e.deletedAtRange.map(c.toString).join(","):void 0}),o=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/search"),method:"GET",params:n,headers:o,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,s.deserializeSearchResultsOrSearchResultsWithSharedLinks)(l.data)),{rawData:l.data})}))}}},49888:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SessionTerminationManager=t.TerminateGroupsSessionsHeaders=t.TerminateUsersSessionsHeaders=t.TerminateGroupsSessionsOptionals=t.TerminateUsersSessionsOptionals=void 0,t.serializeTerminateUsersSessionsRequestBody=g,t.deserializeTerminateUsersSessionsRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "TerminateUsersSessionsRequestBody"'});if(null==e.user_ids)throw new l.BoxSdkError({message:'Expecting "user_ids" of type "TerminateUsersSessionsRequestBody" to be defined'});if(!(0,c.sdIsList)(e.user_ids))throw new l.BoxSdkError({message:'Expecting array for "user_ids" of type "TerminateUsersSessionsRequestBody"'});const t=(0,c.sdIsList)(e.user_ids)?e.user_ids.map((function(e){if(!(0,d.sdIsString)(e))throw new l.BoxSdkError({message:'Expecting string for "TerminateUsersSessionsRequestBody"'});return e})):[];if(null==e.user_logins)throw new l.BoxSdkError({message:'Expecting "user_logins" of type "TerminateUsersSessionsRequestBody" to be defined'});if(!(0,c.sdIsList)(e.user_logins))throw new l.BoxSdkError({message:'Expecting array for "user_logins" of type "TerminateUsersSessionsRequestBody"'});const r=(0,c.sdIsList)(e.user_logins)?e.user_logins.map((function(e){if(!(0,d.sdIsString)(e))throw new l.BoxSdkError({message:'Expecting string for "TerminateUsersSessionsRequestBody"'});return e})):[];return{userIds:t,userLogins:r}},t.serializeTerminateGroupsSessionsRequestBody=y,t.deserializeTerminateGroupsSessionsRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "TerminateGroupsSessionsRequestBody"'});if(null==e.group_ids)throw new l.BoxSdkError({message:'Expecting "group_ids" of type "TerminateGroupsSessionsRequestBody" to be defined'});if(!(0,c.sdIsList)(e.group_ids))throw new l.BoxSdkError({message:'Expecting array for "group_ids" of type "TerminateGroupsSessionsRequestBody"'});return{groupIds:(0,c.sdIsList)(e.group_ids)?e.group_ids.map((function(e){if(!(0,d.sdIsString)(e))throw new l.BoxSdkError({message:'Expecting string for "TerminateGroupsSessionsRequestBody"'});return e})):[]}};const n=r(19801),o=r(31210),s=r(93845),a=r(84143),l=r(72631),d=r(50793),c=r(50793),u=r(50793);class p{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.TerminateUsersSessionsOptionals=p;class h{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.TerminateGroupsSessionsOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.TerminateUsersSessionsHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.TerminateGroupsSessionsHeaders=m;function g(e){return{user_ids:e.userIds.map((function(e){return e})),user_logins:e.userLogins.map((function(e){return e}))}}function y(e){return{group_ids:e.groupIds.map((function(e){return e}))}}t.SessionTerminationManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}terminateUsersSessions(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,l=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/terminate_sessions"),method:"POST",headers:l,data:g(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSessionTerminationMessage)(d.data)),{rawData:d.data})}))}terminateGroupsSessions(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,l=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,a.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/groups/terminate_sessions"),method:"POST",headers:l,data:y(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSessionTerminationMessage)(d.data)),{rawData:d.data})}))}}},68567:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SharedLinksFilesManager=t.RemoveSharedLinkFromFileHeaders=t.UpdateSharedLinkOnFileHeaders=t.AddShareLinkToFileHeaders=t.GetSharedLinkForFileHeaders=t.FindFileForSharedLinkHeaders=t.RemoveSharedLinkFromFileOptionals=t.UpdateSharedLinkOnFileOptionals=t.AddShareLinkToFileOptionals=t.GetSharedLinkForFileOptionals=t.FindFileForSharedLinkOptionals=void 0,t.serializeAddShareLinkToFileRequestBodySharedLinkAccessField=E,t.deserializeAddShareLinkToFileRequestBodySharedLinkAccessField=T,t.serializeAddShareLinkToFileRequestBodySharedLinkPermissionsField=B,t.deserializeAddShareLinkToFileRequestBodySharedLinkPermissionsField=C,t.serializeAddShareLinkToFileRequestBodySharedLinkField=I,t.deserializeAddShareLinkToFileRequestBodySharedLinkField=A,t.serializeAddShareLinkToFileRequestBody=F,t.deserializeAddShareLinkToFileRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFileRequestBody"'});return{sharedLink:null==e.shared_link?void 0:A(e.shared_link)}},t.serializeUpdateSharedLinkOnFileRequestBodySharedLinkAccessField=M,t.deserializeUpdateSharedLinkOnFileRequestBodySharedLinkAccessField=D,t.serializeUpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField=R,t.deserializeUpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField=P,t.serializeUpdateSharedLinkOnFileRequestBodySharedLinkField=O,t.deserializeUpdateSharedLinkOnFileRequestBodySharedLinkField=z,t.serializeUpdateSharedLinkOnFileRequestBody=N,t.deserializeUpdateSharedLinkOnFileRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFileRequestBody"'});return{sharedLink:null==e.shared_link?void 0:z(e.shared_link)}},t.serializeRemoveSharedLinkFromFileRequestBodySharedLinkField=q,t.deserializeRemoveSharedLinkFromFileRequestBodySharedLinkField=U,t.serializeRemoveSharedLinkFromFileRequestBody=L,t.deserializeRemoveSharedLinkFromFileRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromFileRequestBody"'});return{sharedLink:null==e.shared_link?void 0:U(e.shared_link)}};const n=r(49579),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.FindFileForSharedLinkOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetSharedLinkForFileOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddShareLinkToFileOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateSharedLinkOnFileOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RemoveSharedLinkFromFileOptionals=b;class w{constructor(e){this.extraHeaders={},e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.FindFileForSharedLinkHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSharedLinkForFileHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddShareLinkToFileHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateSharedLinkOnFileHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RemoveSharedLinkFromFileHeaders=k;function E(e){return e}function T(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize AddShareLinkToFileRequestBodySharedLinkAccessField"})}function B(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function C(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFileRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "AddShareLinkToFileRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "AddShareLinkToFileRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "AddShareLinkToFileRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function I(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:B(e.permissions)}}function A(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFileRequestBodySharedLinkField"'});const t=null==e.access?void 0:T(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "AddShareLinkToFileRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "AddShareLinkToFileRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "AddShareLinkToFileRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:C(e.permissions)}}function F(e){return{shared_link:null==e.sharedLink?void 0:I(e.sharedLink)}}function M(e){return e}function D(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateSharedLinkOnFileRequestBodySharedLinkAccessField"})}function R(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function P(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "UpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "UpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "UpdateSharedLinkOnFileRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function O(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:R(e.permissions)}}function z(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFileRequestBodySharedLinkField"'});const t=null==e.access?void 0:D(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "UpdateSharedLinkOnFileRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateSharedLinkOnFileRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateSharedLinkOnFileRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:P(e.permissions)}}function N(e){return{shared_link:null==e.sharedLink?void 0:O(e.sharedLink)}}function q(e){return{}}function U(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromFileRequestBodySharedLinkField"'});return{}}function L(e){return{shared_link:null==e.sharedLink?void 0:(e.sharedLink,{})}}t.SharedLinksFilesManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}findFileForSharedLink(){return i(this,arguments,void 0,(function*(e={},t,r={}){const i=new w({ifNoneMatch:t.ifNoneMatch,boxapi:t.boxapi,extraHeaders:t.extraHeaders}),o=new m({cancellationToken:r.cancellationToken}).cancellationToken,s=(0,l.prepareParams)({fields:e.fields?e.fields.map(d.toString).join(","):void 0}),a=(0,l.prepareParams)(Object.assign({"if-none-match":(0,d.toString)(i.ifNoneMatch),boxapi:(0,d.toString)(i.boxapi)},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shared_items"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(u.data)),{rawData:u.data})}))}getSharedLinkForFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)({fields:(0,d.toString)(t.fields)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"#get_shared_link"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(p.data)),{rawData:p.data})}))}addShareLinkToFile(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new y({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"#add_shared_link"),method:"PUT",params:u,headers:p,data:F(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(h.data)),{rawData:h.data})}))}updateSharedLinkOnFile(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new v({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"#update_shared_link"),method:"PUT",params:u,headers:p,data:N(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(h.data)),{rawData:h.data})}))}removeSharedLinkFromFile(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new b({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"#remove_shared_link"),method:"PUT",params:u,headers:p,data:L(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFileFull)(h.data)),{rawData:h.data})}))}}},59417:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SharedLinksFoldersManager=t.RemoveSharedLinkFromFolderHeaders=t.UpdateSharedLinkOnFolderHeaders=t.AddShareLinkToFolderHeaders=t.GetSharedLinkForFolderHeaders=t.FindFolderForSharedLinkHeaders=t.RemoveSharedLinkFromFolderOptionals=t.UpdateSharedLinkOnFolderOptionals=t.AddShareLinkToFolderOptionals=t.GetSharedLinkForFolderOptionals=t.FindFolderForSharedLinkOptionals=void 0,t.serializeAddShareLinkToFolderRequestBodySharedLinkAccessField=E,t.deserializeAddShareLinkToFolderRequestBodySharedLinkAccessField=T,t.serializeAddShareLinkToFolderRequestBodySharedLinkPermissionsField=B,t.deserializeAddShareLinkToFolderRequestBodySharedLinkPermissionsField=C,t.serializeAddShareLinkToFolderRequestBodySharedLinkField=I,t.deserializeAddShareLinkToFolderRequestBodySharedLinkField=A,t.serializeAddShareLinkToFolderRequestBody=F,t.deserializeAddShareLinkToFolderRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFolderRequestBody"'});return{sharedLink:null==e.shared_link?void 0:A(e.shared_link)}},t.serializeUpdateSharedLinkOnFolderRequestBodySharedLinkAccessField=M,t.deserializeUpdateSharedLinkOnFolderRequestBodySharedLinkAccessField=D,t.serializeUpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField=R,t.deserializeUpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField=P,t.serializeUpdateSharedLinkOnFolderRequestBodySharedLinkField=O,t.deserializeUpdateSharedLinkOnFolderRequestBodySharedLinkField=z,t.serializeUpdateSharedLinkOnFolderRequestBody=N,t.deserializeUpdateSharedLinkOnFolderRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFolderRequestBody"'});return{sharedLink:null==e.shared_link?void 0:z(e.shared_link)}},t.serializeRemoveSharedLinkFromFolderRequestBodySharedLinkField=q,t.deserializeRemoveSharedLinkFromFolderRequestBodySharedLinkField=U,t.serializeRemoveSharedLinkFromFolderRequestBody=L,t.deserializeRemoveSharedLinkFromFolderRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromFolderRequestBody"'});return{sharedLink:null==e.shared_link?void 0:U(e.shared_link)}};const n=r(34537),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.FindFolderForSharedLinkOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetSharedLinkForFolderOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddShareLinkToFolderOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateSharedLinkOnFolderOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RemoveSharedLinkFromFolderOptionals=b;class w{constructor(e){this.extraHeaders={},e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.FindFolderForSharedLinkHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSharedLinkForFolderHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddShareLinkToFolderHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateSharedLinkOnFolderHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RemoveSharedLinkFromFolderHeaders=k;function E(e){return e}function T(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize AddShareLinkToFolderRequestBodySharedLinkAccessField"})}function B(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function C(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFolderRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "AddShareLinkToFolderRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "AddShareLinkToFolderRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "AddShareLinkToFolderRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function I(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:B(e.permissions)}}function A(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToFolderRequestBodySharedLinkField"'});const t=null==e.access?void 0:T(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "AddShareLinkToFolderRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "AddShareLinkToFolderRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "AddShareLinkToFolderRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:C(e.permissions)}}function F(e){return{shared_link:null==e.sharedLink?void 0:I(e.sharedLink)}}function M(e){return e}function D(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateSharedLinkOnFolderRequestBodySharedLinkAccessField"})}function R(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function P(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function O(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:R(e.permissions)}}function z(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnFolderRequestBodySharedLinkField"'});const t=null==e.access?void 0:D(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateSharedLinkOnFolderRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:P(e.permissions)}}function N(e){return{shared_link:null==e.sharedLink?void 0:O(e.sharedLink)}}function q(e){return{}}function U(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromFolderRequestBodySharedLinkField"'});return{}}function L(e){return{shared_link:null==e.sharedLink?void 0:(e.sharedLink,{})}}t.SharedLinksFoldersManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}findFolderForSharedLink(){return i(this,arguments,void 0,(function*(e={},t,r={}){const i=new w({ifNoneMatch:t.ifNoneMatch,boxapi:t.boxapi,extraHeaders:t.extraHeaders}),o=new m({cancellationToken:r.cancellationToken}).cancellationToken,s=(0,l.prepareParams)({fields:e.fields?e.fields.map(d.toString).join(","):void 0}),a=(0,l.prepareParams)(Object.assign({"if-none-match":(0,d.toString)(i.ifNoneMatch),boxapi:(0,d.toString)(i.boxapi)},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shared_items#folders"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(u.data)),{rawData:u.data})}))}getSharedLinkForFolder(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)({fields:(0,d.toString)(t.fields)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,d.toString)(e),"#get_shared_link"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(p.data)),{rawData:p.data})}))}addShareLinkToFolder(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new y({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,d.toString)(e),"#add_shared_link"),method:"PUT",params:u,headers:p,data:F(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(h.data)),{rawData:h.data})}))}updateSharedLinkOnFolder(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new v({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,d.toString)(e),"#update_shared_link"),method:"PUT",params:u,headers:p,data:N(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(h.data)),{rawData:h.data})}))}removeSharedLinkFromFolder(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new b({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,d.toString)(e),"#remove_shared_link"),method:"PUT",params:u,headers:p,data:L(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(h.data)),{rawData:h.data})}))}}},82415:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SharedLinksWebLinksManager=t.RemoveSharedLinkFromWebLinkHeaders=t.UpdateSharedLinkOnWebLinkHeaders=t.AddShareLinkToWebLinkHeaders=t.GetSharedLinkForWebLinkHeaders=t.FindWebLinkForSharedLinkHeaders=t.RemoveSharedLinkFromWebLinkOptionals=t.UpdateSharedLinkOnWebLinkOptionals=t.AddShareLinkToWebLinkOptionals=t.GetSharedLinkForWebLinkOptionals=t.FindWebLinkForSharedLinkOptionals=void 0,t.serializeAddShareLinkToWebLinkRequestBodySharedLinkAccessField=E,t.deserializeAddShareLinkToWebLinkRequestBodySharedLinkAccessField=T,t.serializeAddShareLinkToWebLinkRequestBodySharedLinkPermissionsField=B,t.deserializeAddShareLinkToWebLinkRequestBodySharedLinkPermissionsField=C,t.serializeAddShareLinkToWebLinkRequestBodySharedLinkField=I,t.deserializeAddShareLinkToWebLinkRequestBodySharedLinkField=A,t.serializeAddShareLinkToWebLinkRequestBody=F,t.deserializeAddShareLinkToWebLinkRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToWebLinkRequestBody"'});return{sharedLink:null==e.shared_link?void 0:A(e.shared_link)}},t.serializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkAccessField=M,t.deserializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkAccessField=D,t.serializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField=R,t.deserializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField=P,t.serializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkField=O,t.deserializeUpdateSharedLinkOnWebLinkRequestBodySharedLinkField=z,t.serializeUpdateSharedLinkOnWebLinkRequestBody=N,t.deserializeUpdateSharedLinkOnWebLinkRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnWebLinkRequestBody"'});return{sharedLink:null==e.shared_link?void 0:z(e.shared_link)}},t.serializeRemoveSharedLinkFromWebLinkRequestBodySharedLinkField=q,t.deserializeRemoveSharedLinkFromWebLinkRequestBodySharedLinkField=U,t.serializeRemoveSharedLinkFromWebLinkRequestBody=L,t.deserializeRemoveSharedLinkFromWebLinkRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromWebLinkRequestBody"'});return{sharedLink:null==e.shared_link?void 0:U(e.shared_link)}};const n=r(60238),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.cancellationToken=void 0,e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.FindWebLinkForSharedLinkOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetSharedLinkForWebLinkOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.AddShareLinkToWebLinkOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateSharedLinkOnWebLinkOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RemoveSharedLinkFromWebLinkOptionals=b;class w{constructor(e){this.extraHeaders={},e.ifNoneMatch&&(this.ifNoneMatch=e.ifNoneMatch),e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.FindWebLinkForSharedLinkHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSharedLinkForWebLinkHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.AddShareLinkToWebLinkHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateSharedLinkOnWebLinkHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RemoveSharedLinkFromWebLinkHeaders=k;function E(e){return e}function T(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize AddShareLinkToWebLinkRequestBodySharedLinkAccessField"})}function B(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function C(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToWebLinkRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "AddShareLinkToWebLinkRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "AddShareLinkToWebLinkRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "AddShareLinkToWebLinkRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function I(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:B(e.permissions)}}function A(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AddShareLinkToWebLinkRequestBodySharedLinkField"'});const t=null==e.access?void 0:T(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "AddShareLinkToWebLinkRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "AddShareLinkToWebLinkRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "AddShareLinkToWebLinkRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:C(e.permissions)}}function F(e){return{shared_link:null==e.sharedLink?void 0:I(e.sharedLink)}}function M(e){return e}function D(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateSharedLinkOnWebLinkRequestBodySharedLinkAccessField"})}function R(e){return{can_download:null==e.canDownload?void 0:e.canDownload,can_preview:null==e.canPreview?void 0:e.canPreview,can_edit:null==e.canEdit?void 0:e.canEdit}}function P(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField"'});if(null!=e.can_download&&!(0,p.sdIsBoolean)(e.can_download))throw new u.BoxSdkError({message:'Expecting boolean for "can_download" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField"'});const t=null==e.can_download?void 0:e.can_download;if(null!=e.can_preview&&!(0,p.sdIsBoolean)(e.can_preview))throw new u.BoxSdkError({message:'Expecting boolean for "can_preview" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField"'});const r=null==e.can_preview?void 0:e.can_preview;if(null!=e.can_edit&&!(0,p.sdIsBoolean)(e.can_edit))throw new u.BoxSdkError({message:'Expecting boolean for "can_edit" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:null==e.can_edit?void 0:e.can_edit}}function O(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt),permissions:null==e.permissions?void 0:R(e.permissions)}}function z(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateSharedLinkOnWebLinkRequestBodySharedLinkField"'});const t=null==e.access?void 0:D(e.access);if(null!=e.password&&!(0,h.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,h.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,h.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateSharedLinkOnWebLinkRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at),permissions:null==e.permissions?void 0:P(e.permissions)}}function N(e){return{shared_link:null==e.sharedLink?void 0:O(e.sharedLink)}}function q(e){return{}}function U(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RemoveSharedLinkFromWebLinkRequestBodySharedLinkField"'});return{}}function L(e){return{shared_link:null==e.sharedLink?void 0:(e.sharedLink,{})}}t.SharedLinksWebLinksManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}findWebLinkForSharedLink(){return i(this,arguments,void 0,(function*(e={},t,r={}){const i=new w({ifNoneMatch:t.ifNoneMatch,boxapi:t.boxapi,extraHeaders:t.extraHeaders}),o=new m({cancellationToken:r.cancellationToken}).cancellationToken,s=(0,l.prepareParams)({fields:e.fields?e.fields.map(d.toString).join(","):void 0}),a=(0,l.prepareParams)(Object.assign({"if-none-match":(0,d.toString)(i.ifNoneMatch),boxapi:(0,d.toString)(i.boxapi)},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shared_items#web_links"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(u.data)),{rawData:u.data})}))}getSharedLinkForWebLink(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)({fields:(0,d.toString)(t.fields)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e),"#get_shared_link"),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(p.data)),{rawData:p.data})}))}addShareLinkToWebLink(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new y({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e),"#add_shared_link"),method:"PUT",params:u,headers:p,data:F(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(h.data)),{rawData:h.data})}))}updateSharedLinkOnWebLink(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new v({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e),"#update_shared_link"),method:"PUT",params:u,headers:p,data:N(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(h.data)),{rawData:h.data})}))}removeSharedLinkFromWebLink(e){return i(this,arguments,void 0,(function*(e,t={},r,i={}){const o=new b({headers:i.headers,cancellationToken:i.cancellationToken}),s=o.headers,a=o.cancellationToken,u=(0,l.prepareParams)({fields:(0,d.toString)(r.fields)}),p=(0,l.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e),"#remove_shared_link"),method:"PUT",params:u,headers:p,data:L(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(h.data)),{rawData:h.data})}))}}},99253:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ShieldInformationBarrierReportsManager=t.GetShieldInformationBarrierReportByIdHeaders=t.CreateShieldInformationBarrierReportHeaders=t.GetShieldInformationBarrierReportsHeaders=t.GetShieldInformationBarrierReportByIdOptionals=t.CreateShieldInformationBarrierReportOptionals=t.GetShieldInformationBarrierReportsOptionals=void 0;const n=r(89275),o=r(65382),s=r(44345),a=r(31210),l=r(93845),d=r(93845),c=r(84143);class u{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierReportsOptionals=u;class p{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateShieldInformationBarrierReportOptionals=p;class h{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierReportByIdOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierReportsHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateShieldInformationBarrierReportHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierReportByIdHeaders=g;t.ShieldInformationBarrierReportsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getShieldInformationBarrierReports(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)({shield_information_barrier_id:(0,d.toString)(e.shieldInformationBarrierId),marker:(0,d.toString)(e.marker),limit:(0,d.toString)(e.limit)}),a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_reports"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierReports)(p.data)),{rawData:p.data})}))}createShieldInformationBarrierReport(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_reports"),method:"POST",headers:a,data:(0,s.serializeShieldInformationBarrierReference)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarrierReport)(d.data)),{rawData:d.data})}))}getShieldInformationBarrierReportById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_reports/",(0,d.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarrierReport)(a.data)),{rawData:a.data})}))}}},81194:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ShieldInformationBarrierSegmentMembersManager=t.CreateShieldInformationBarrierSegmentMemberHeaders=t.GetShieldInformationBarrierSegmentMembersHeaders=t.DeleteShieldInformationBarrierSegmentMemberByIdHeaders=t.GetShieldInformationBarrierSegmentMemberByIdHeaders=t.CreateShieldInformationBarrierSegmentMemberOptionals=t.GetShieldInformationBarrierSegmentMembersOptionals=t.DeleteShieldInformationBarrierSegmentMemberByIdOptionals=t.GetShieldInformationBarrierSegmentMemberByIdOptionals=void 0,t.serializeCreateShieldInformationBarrierSegmentMemberRequestBodyTypeField=E,t.deserializeCreateShieldInformationBarrierSegmentMemberRequestBodyTypeField=T,t.serializeCreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentTypeField=B,t.deserializeCreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentTypeField=C,t.serializeCreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentField=I,t.deserializeCreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentField=A,t.serializeCreateShieldInformationBarrierSegmentMemberRequestBody=F,t.deserializeCreateShieldInformationBarrierSegmentMemberRequestBody=function(e){if(!(0,g.sdIsMap)(e))throw new f.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentMemberRequestBody"'});const t=null==e.type?void 0:T(e.type),r=null==e.shield_information_barrier?void 0:(0,a.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null==e.shield_information_barrier_segment)throw new f.BoxSdkError({message:'Expecting "shield_information_barrier_segment" of type "CreateShieldInformationBarrierSegmentMemberRequestBody" to be defined'});const i=A(e.shield_information_barrier_segment);if(null==e.user)throw new f.BoxSdkError({message:'Expecting "user" of type "CreateShieldInformationBarrierSegmentMemberRequestBody" to be defined'});const n=(0,d.deserializeUserBase)(e.user);return{type:t,shieldInformationBarrier:r,shieldInformationBarrierSegment:i,user:n}};const n=r(17935),o=r(48620),s=r(945),a=r(945),l=r(78366),d=r(78366),c=r(31210),u=r(93845),p=r(93845),h=r(84143),f=r(72631),m=r(50793),g=r(50793);class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentMemberByIdOptionals=y;class v{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteShieldInformationBarrierSegmentMemberByIdOptionals=v;class b{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentMembersOptionals=b;class w{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateShieldInformationBarrierSegmentMemberOptionals=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentMemberByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteShieldInformationBarrierSegmentMemberByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentMembersHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateShieldInformationBarrierSegmentMemberHeaders=k;function E(e){return e}function T(e){if("shield_information_barrier_segment_member"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize CreateShieldInformationBarrierSegmentMemberRequestBodyTypeField"})}function B(e){return e}function C(e){if("shield_information_barrier_segment"==e)return e;throw new f.BoxSdkError({message:"Can't deserialize CreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentTypeField"})}function I(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function A(e){if(!(0,g.sdIsMap)(e))throw new f.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentField"'});if(null!=e.id&&!(0,m.sdIsString)(e.id))throw new f.BoxSdkError({message:'Expecting string for "id" of type "CreateShieldInformationBarrierSegmentMemberRequestBodyShieldInformationBarrierSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:C(e.type)}}function F(e){return{type:null==e.type?void 0:e.type,shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,s.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),shield_information_barrier_segment:I(e.shieldInformationBarrierSegment),user:(0,l.serializeUserBase)(e.user)}}t.ShieldInformationBarrierSegmentMembersManager=class{constructor(e){this.networkSession=new c.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getShieldInformationBarrierSegmentMemberById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_members/",(0,p.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegmentMember)(a.data)),{rawData:a.data})}))}deleteShieldInformationBarrierSegmentMemberById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,u.prepareParams)(Object.assign({},i.extraHeaders));yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_members/",(0,p.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getShieldInformationBarrierSegmentMembers(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,u.prepareParams)({shield_information_barrier_segment_id:(0,p.toString)(e.shieldInformationBarrierSegmentId),marker:(0,p.toString)(e.marker),limit:(0,p.toString)(e.limit)}),a=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_members"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarrierSegmentMembers)(l.data)),{rawData:l.data})}))}createShieldInformationBarrierSegmentMember(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,u.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,h.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_members"),method:"POST",headers:s,data:F(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegmentMember)(a.data)),{rawData:a.data})}))}}},85180:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ShieldInformationBarrierSegmentRestrictionsManager=t.CreateShieldInformationBarrierSegmentRestrictionHeaders=t.CreateShieldInformationBarrierSegmentRestrictionRequestBody=t.GetShieldInformationBarrierSegmentRestrictionsHeaders=t.DeleteShieldInformationBarrierSegmentRestrictionByIdHeaders=t.GetShieldInformationBarrierSegmentRestrictionByIdHeaders=t.CreateShieldInformationBarrierSegmentRestrictionOptionals=t.GetShieldInformationBarrierSegmentRestrictionsOptionals=t.DeleteShieldInformationBarrierSegmentRestrictionByIdOptionals=t.GetShieldInformationBarrierSegmentRestrictionByIdOptionals=void 0,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyTypeField=k,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyTypeField=E,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentTypeField=T,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentTypeField=B,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentField=C,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentField=I,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentTypeField=A,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentTypeField=F,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentField=M,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentField=D,t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBody=R,t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentRestrictionRequestBody"'});if(null==e.type)throw new p.BoxSdkError({message:'Expecting "type" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBody" to be defined'});const t=E(e.type),r=null==e.shield_information_barrier?void 0:(0,a.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null==e.shield_information_barrier_segment)throw new p.BoxSdkError({message:'Expecting "shield_information_barrier_segment" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBody" to be defined'});const i=I(e.shield_information_barrier_segment);if(null==e.restricted_segment)throw new p.BoxSdkError({message:'Expecting "restricted_segment" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBody" to be defined'});const n=D(e.restricted_segment);return{type:t,shieldInformationBarrier:r,shieldInformationBarrierSegment:i,restrictedSegment:n}},t.serializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyInput=function(e){return{type:null==e.type?void 0:e.type,shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,s.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),shield_information_barrier_segment:C(e.shieldInformationBarrierSegment),restricted_segment:M(e.restrictedSegment)}},t.deserializeCreateShieldInformationBarrierSegmentRestrictionRequestBodyInput=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentRestrictionRequestBodyInput"'});const t=null==e.type?void 0:E(e.type),r=null==e.shield_information_barrier?void 0:(0,a.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null==e.shield_information_barrier_segment)throw new p.BoxSdkError({message:'Expecting "shield_information_barrier_segment" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBodyInput" to be defined'});const i=I(e.shield_information_barrier_segment);if(null==e.restricted_segment)throw new p.BoxSdkError({message:'Expecting "restricted_segment" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBodyInput" to be defined'});const n=D(e.restricted_segment);return{type:t,shieldInformationBarrier:r,shieldInformationBarrierSegment:i,restrictedSegment:n}};const n=r(51325),o=r(10),s=r(945),a=r(945),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentRestrictionByIdOptionals=m;class g{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteShieldInformationBarrierSegmentRestrictionByIdOptionals=g;class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentRestrictionsOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateShieldInformationBarrierSegmentRestrictionOptionals=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentRestrictionByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteShieldInformationBarrierSegmentRestrictionByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentRestrictionsHeaders=_;class x{constructor(e){this.type="shield_information_barrier_segment_restriction",e.type&&(this.type=e.type),e.shieldInformationBarrier&&(this.shieldInformationBarrier=e.shieldInformationBarrier),e.shieldInformationBarrierSegment&&(this.shieldInformationBarrierSegment=e.shieldInformationBarrierSegment),e.restrictedSegment&&(this.restrictedSegment=e.restrictedSegment),e.rawData&&(this.rawData=e.rawData)}}t.CreateShieldInformationBarrierSegmentRestrictionRequestBody=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateShieldInformationBarrierSegmentRestrictionHeaders=S;function k(e){return e}function E(e){if("shield_information_barrier_segment_restriction"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateShieldInformationBarrierSegmentRestrictionRequestBodyTypeField"})}function T(e){return e}function B(e){if("shield_information_barrier_segment"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentTypeField"})}function C(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function I(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentField"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBodyShieldInformationBarrierSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:B(e.type)}}function A(e){return e}function F(e){if("shield_information_barrier_segment"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentTypeField"})}function M(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function D(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentField"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "CreateShieldInformationBarrierSegmentRestrictionRequestBodyRestrictedSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:F(e.type)}}function R(e){return{type:e.type,shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,s.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),shield_information_barrier_segment:C(e.shieldInformationBarrierSegment),restricted_segment:M(e.restrictedSegment)}}t.ShieldInformationBarrierSegmentRestrictionsManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getShieldInformationBarrierSegmentRestrictionById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_restrictions/",(0,c.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegmentRestriction)(a.data)),{rawData:a.data})}))}deleteShieldInformationBarrierSegmentRestrictionById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,d.prepareParams)(Object.assign({},i.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_restrictions/",(0,c.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getShieldInformationBarrierSegmentRestrictions(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)({shield_information_barrier_segment_id:(0,c.toString)(e.shieldInformationBarrierSegmentId),marker:(0,c.toString)(e.marker),limit:(0,c.toString)(e.limit)}),a=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_restrictions"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarrierSegmentRestrictions)(l.data)),{rawData:l.data})}))}createShieldInformationBarrierSegmentRestriction(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new x({type:e.type,shieldInformationBarrier:e.shieldInformationBarrier,shieldInformationBarrierSegment:e.shieldInformationBarrierSegment,restrictedSegment:e.restrictedSegment}),i=new v({headers:t.headers,cancellationToken:t.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,d.prepareParams)(Object.assign({},o.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segment_restrictions"),method:"POST",headers:a,data:R(r),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegmentRestriction)(l.data)),{rawData:l.data})}))}}},90072:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ShieldInformationBarrierSegmentsManager=t.CreateShieldInformationBarrierSegmentHeaders=t.GetShieldInformationBarrierSegmentsHeaders=t.UpdateShieldInformationBarrierSegmentByIdHeaders=t.DeleteShieldInformationBarrierSegmentByIdHeaders=t.GetShieldInformationBarrierSegmentByIdHeaders=t.CreateShieldInformationBarrierSegmentOptionals=t.GetShieldInformationBarrierSegmentsOptionals=t.UpdateShieldInformationBarrierSegmentByIdOptionals=t.DeleteShieldInformationBarrierSegmentByIdOptionals=t.GetShieldInformationBarrierSegmentByIdOptionals=void 0,t.serializeUpdateShieldInformationBarrierSegmentByIdRequestBody=E,t.deserializeUpdateShieldInformationBarrierSegmentByIdRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateShieldInformationBarrierSegmentByIdRequestBody"'});if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "UpdateShieldInformationBarrierSegmentByIdRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.description&&!(0,h.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "UpdateShieldInformationBarrierSegmentByIdRequestBody"'});const r=null==e.description?void 0:e.description;return{name:t,description:r}},t.serializeCreateShieldInformationBarrierSegmentRequestBody=T,t.deserializeCreateShieldInformationBarrierSegmentRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierSegmentRequestBody"'});if(null==e.shield_information_barrier)throw new p.BoxSdkError({message:'Expecting "shield_information_barrier" of type "CreateShieldInformationBarrierSegmentRequestBody" to be defined'});const t=(0,a.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null==e.name)throw new p.BoxSdkError({message:'Expecting "name" of type "CreateShieldInformationBarrierSegmentRequestBody" to be defined'});if(!(0,h.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "CreateShieldInformationBarrierSegmentRequestBody"'});const r=e.name;if(null!=e.description&&!(0,h.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "CreateShieldInformationBarrierSegmentRequestBody"'});const i=null==e.description?void 0:e.description;return{shieldInformationBarrier:t,name:r,description:i}};const n=r(77749),o=r(59410),s=r(945),a=r(945),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteShieldInformationBarrierSegmentByIdOptionals=g;class y{constructor(e){this.requestBody={},this.headers=new x({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateShieldInformationBarrierSegmentByIdOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierSegmentsOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateShieldInformationBarrierSegmentOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteShieldInformationBarrierSegmentByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateShieldInformationBarrierSegmentByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierSegmentsHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateShieldInformationBarrierSegmentHeaders=k;function E(e){return{name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description}}function T(e){return{shield_information_barrier:(0,s.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),name:e.name,description:null==e.description?void 0:e.description}}t.ShieldInformationBarrierSegmentsManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getShieldInformationBarrierSegmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segments/",(0,c.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegment)(a.data)),{rawData:a.data})}))}deleteShieldInformationBarrierSegmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,d.prepareParams)(Object.assign({},i.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segments/",(0,c.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}updateShieldInformationBarrierSegmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)(Object.assign({},o.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segments/",(0,c.toString)(e)),method:"PUT",headers:a,data:E(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegment)(l.data)),{rawData:l.data})}))}getShieldInformationBarrierSegments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)({shield_information_barrier_id:(0,c.toString)(e.shieldInformationBarrierId),marker:(0,c.toString)(e.marker),limit:(0,c.toString)(e.limit)}),a=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segments"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarrierSegments)(l.data)),{rawData:l.data})}))}createShieldInformationBarrierSegment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barrier_segments"),method:"POST",headers:s,data:T(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrierSegment)(a.data)),{rawData:a.data})}))}}},22195:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ShieldInformationBarriersManager=t.CreateShieldInformationBarrierHeaders=t.GetShieldInformationBarriersHeaders=t.UpdateShieldInformationBarrierStatusHeaders=t.GetShieldInformationBarrierByIdHeaders=t.CreateShieldInformationBarrierOptionals=t.UpdateShieldInformationBarrierStatusOptionals=t.GetShieldInformationBarrierByIdOptionals=void 0,t.serializeUpdateShieldInformationBarrierStatusRequestBodyStatusField=x,t.deserializeUpdateShieldInformationBarrierStatusRequestBodyStatusField=S,t.serializeUpdateShieldInformationBarrierStatusRequestBody=k,t.deserializeUpdateShieldInformationBarrierStatusRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateShieldInformationBarrierStatusRequestBody"'});if(null==e.id)throw new p.BoxSdkError({message:'Expecting "id" of type "UpdateShieldInformationBarrierStatusRequestBody" to be defined'});if(!(0,h.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "UpdateShieldInformationBarrierStatusRequestBody"'});const t=e.id;if(null==e.status)throw new p.BoxSdkError({message:'Expecting "status" of type "UpdateShieldInformationBarrierStatusRequestBody" to be defined'});const r=S(e.status);return{id:t,status:r}},t.serializeCreateShieldInformationBarrierRequestBody=E,t.deserializeCreateShieldInformationBarrierRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateShieldInformationBarrierRequestBody"'});if(null==e.enterprise)throw new p.BoxSdkError({message:'Expecting "enterprise" of type "CreateShieldInformationBarrierRequestBody" to be defined'});return{enterprise:(0,a.deserializeEnterpriseBase)(e.enterprise)}};const n=r(91616),o=r(38317),s=r(75762),a=r(75762),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetShieldInformationBarrierByIdOptionals=m;class g{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateShieldInformationBarrierStatusOptionals=g;class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateShieldInformationBarrierOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarrierByIdHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateShieldInformationBarrierStatusHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetShieldInformationBarriersHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateShieldInformationBarrierHeaders=_;function x(e){return e}function S(e){if("pending"==e)return e;if("disabled"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateShieldInformationBarrierStatusRequestBodyStatusField"})}function k(e){return{id:e.id,status:e.status}}function E(e){return{enterprise:(0,s.serializeEnterpriseBase)(e.enterprise)}}t.ShieldInformationBarriersManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getShieldInformationBarrierById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barriers/",(0,c.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrier)(a.data)),{rawData:a.data})}))}updateShieldInformationBarrierStatus(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barriers/change_status"),method:"POST",headers:s,data:k(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrier)(a.data)),{rawData:a.data})}))}getShieldInformationBarriers(){return i(this,arguments,void 0,(function*(e={},t=new w({}),r){const i=new w({extraHeaders:t.extraHeaders}),n=(0,d.prepareParams)({marker:(0,c.toString)(e.marker),limit:(0,c.toString)(e.limit)}),s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barriers"),method:"GET",params:n,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,o.deserializeShieldInformationBarriers)(a.data)),{rawData:a.data})}))}createShieldInformationBarrier(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/shield_information_barriers"),method:"POST",headers:s,data:E(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeShieldInformationBarrier)(a.data)),{rawData:a.data})}))}}},39797:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SignRequestsManager=t.CreateSignRequestHeaders=t.GetSignRequestsHeaders=t.GetSignRequestByIdHeaders=t.ResendSignRequestHeaders=t.CancelSignRequestHeaders=t.CreateSignRequestOptionals=t.GetSignRequestByIdOptionals=t.ResendSignRequestOptionals=t.CancelSignRequestOptionals=void 0;const n=r(86982),o=r(58267),s=r(32571),a=r(31210),l=r(93845),d=r(93845),c=r(84143);class u{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CancelSignRequestOptionals=u;class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.ResendSignRequestOptionals=p;class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetSignRequestByIdOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateSignRequestOptionals=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CancelSignRequestHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.ResendSignRequestHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSignRequestByIdHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSignRequestsHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateSignRequestHeaders=b;t.SignRequestsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}cancelSignRequest(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_requests/",(0,d.toString)(e),"/cancel"),method:"POST",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSignRequest)(a.data)),{rawData:a.data})}))}resendSignRequest(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_requests/",(0,d.toString)(e),"/resend"),method:"POST",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}getSignRequestById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_requests/",(0,d.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSignRequest)(a.data)),{rawData:a.data})}))}getSignRequests(){return i(this,arguments,void 0,(function*(e={},t=new v({}),r){const i=new v({extraHeaders:t.extraHeaders}),n=(0,l.prepareParams)({marker:(0,d.toString)(e.marker),limit:(0,d.toString)(e.limit)}),s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_requests"),method:"GET",params:n,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,o.deserializeSignRequests)(a.data)),{rawData:a.data})}))}createSignRequest(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),d=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_requests"),method:"POST",headers:a,data:(0,s.serializeSignRequestCreateRequest)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSignRequest)(d.data)),{rawData:d.data})}))}}},41014:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SignTemplatesManager=t.GetSignTemplateByIdHeaders=t.GetSignTemplatesHeaders=t.GetSignTemplateByIdOptionals=void 0;const n=r(55064),o=r(15139),s=r(31210),a=r(93845),l=r(93845),d=r(84143);class c{constructor(e){this.headers=new p({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetSignTemplateByIdOptionals=c;class u{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSignTemplatesHeaders=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetSignTemplateByIdHeaders=p;t.SignTemplatesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getSignTemplates(){return i(this,arguments,void 0,(function*(e={},t=new u({}),r){const i=new u({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_templates"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeSignTemplates)(c.data)),{rawData:c.data})}))}getSignTemplateById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/sign_templates/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeSignTemplate)(u.data)),{rawData:u.data})}))}}},55040:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.SkillsManager=t.UpdateAllSkillCardsOnFileHeaders=t.DeleteBoxSkillCardsFromFileHeaders=t.UpdateBoxSkillCardsOnFileHeaders=t.CreateBoxSkillCardsOnFileHeaders=t.GetBoxSkillCardsOnFileHeaders=t.UpdateAllSkillCardsOnFileOptionals=t.DeleteBoxSkillCardsFromFileOptionals=t.UpdateBoxSkillCardsOnFileOptionals=t.CreateBoxSkillCardsOnFileOptionals=t.GetBoxSkillCardsOnFileOptionals=void 0,t.serializeCreateBoxSkillCardsOnFileRequestBody=T,t.deserializeCreateBoxSkillCardsOnFileRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateBoxSkillCardsOnFileRequestBody"'});if(null==e.cards)throw new u.BoxSdkError({message:'Expecting "cards" of type "CreateBoxSkillCardsOnFileRequestBody" to be defined'});if(!(0,f.sdIsList)(e.cards))throw new u.BoxSdkError({message:'Expecting array for "cards" of type "CreateBoxSkillCardsOnFileRequestBody"'});return{cards:(0,f.sdIsList)(e.cards)?e.cards.map((function(e){return(0,s.deserializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)})):[]}},t.serializeUpdateBoxSkillCardsOnFileRequestBodyOpField=B,t.deserializeUpdateBoxSkillCardsOnFileRequestBodyOpField=C,t.serializeUpdateBoxSkillCardsOnFileRequestBody=I,t.deserializeUpdateBoxSkillCardsOnFileRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateBoxSkillCardsOnFileRequestBody"'});const t=null==e.op?void 0:C(e.op);if(null!=e.path&&!(0,h.sdIsString)(e.path))throw new u.BoxSdkError({message:'Expecting string for "path" of type "UpdateBoxSkillCardsOnFileRequestBody"'});const r=null==e.path?void 0:e.path,i=null==e.value?void 0:(0,s.deserializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e.value);return{op:t,path:r,value:i}},t.serializeUpdateAllSkillCardsOnFileRequestBodyStatusField=A,t.deserializeUpdateAllSkillCardsOnFileRequestBodyStatusField=F,t.serializeUpdateAllSkillCardsOnFileRequestBodyMetadataField=M,t.deserializeUpdateAllSkillCardsOnFileRequestBodyMetadataField=D,t.serializeUpdateAllSkillCardsOnFileRequestBodyFileTypeField=R,t.deserializeUpdateAllSkillCardsOnFileRequestBodyFileTypeField=P,t.serializeUpdateAllSkillCardsOnFileRequestBodyFileField=O,t.deserializeUpdateAllSkillCardsOnFileRequestBodyFileField=z,t.serializeUpdateAllSkillCardsOnFileRequestBodyFileVersionTypeField=N,t.deserializeUpdateAllSkillCardsOnFileRequestBodyFileVersionTypeField=q,t.serializeUpdateAllSkillCardsOnFileRequestBodyFileVersionField=U,t.deserializeUpdateAllSkillCardsOnFileRequestBodyFileVersionField=L,t.serializeUpdateAllSkillCardsOnFileRequestBodyUsageField=j,t.deserializeUpdateAllSkillCardsOnFileRequestBodyUsageField=H,t.serializeUpdateAllSkillCardsOnFileRequestBody=$,t.deserializeUpdateAllSkillCardsOnFileRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateAllSkillCardsOnFileRequestBody"'});if(null==e.status)throw new u.BoxSdkError({message:'Expecting "status" of type "UpdateAllSkillCardsOnFileRequestBody" to be defined'});const t=F(e.status);if(null==e.metadata)throw new u.BoxSdkError({message:'Expecting "metadata" of type "UpdateAllSkillCardsOnFileRequestBody" to be defined'});const r=D(e.metadata);if(null==e.file)throw new u.BoxSdkError({message:'Expecting "file" of type "UpdateAllSkillCardsOnFileRequestBody" to be defined'});const i=z(e.file),n=null==e.file_version?void 0:L(e.file_version),o=null==e.usage?void 0:H(e.usage);return{status:t,metadata:r,file:i,fileVersion:n,usage:o}};const n=r(75897),o=r(20633),s=r(20633),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793);class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetBoxSkillCardsOnFileOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateBoxSkillCardsOnFileOptionals=y;class v{constructor(e){this.headers=new S({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateBoxSkillCardsOnFileOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteBoxSkillCardsFromFileOptionals=b;class w{constructor(e){this.headers=new E({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateAllSkillCardsOnFileOptionals=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetBoxSkillCardsOnFileHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateBoxSkillCardsOnFileHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateBoxSkillCardsOnFileHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteBoxSkillCardsFromFileHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateAllSkillCardsOnFileHeaders=E;function T(e){return{cards:e.cards.map((function(e){return(0,o.serializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)}))}}function B(e){return e}function C(e){if("replace"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateBoxSkillCardsOnFileRequestBodyOpField"})}function I(e){return{op:null==e.op?void 0:e.op,path:null==e.path?void 0:e.path,value:null==e.value?void 0:(0,o.serializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e.value)}}function A(e){return e}function F(e){if("invoked"==e)return e;if("processing"==e)return e;if("success"==e)return e;if("transient_failure"==e)return e;if("permanent_failure"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateAllSkillCardsOnFileRequestBodyStatusField"})}function M(e){return{cards:null==e.cards?void 0:e.cards.map((function(e){return(0,o.serializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)}))}}function D(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateAllSkillCardsOnFileRequestBodyMetadataField"'});if(null!=e.cards&&!(0,f.sdIsList)(e.cards))throw new u.BoxSdkError({message:'Expecting array for "cards" of type "UpdateAllSkillCardsOnFileRequestBodyMetadataField"'});return{cards:null==e.cards?void 0:(0,f.sdIsList)(e.cards)?e.cards.map((function(e){return(0,s.deserializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)})):[]}}function R(e){return e}function P(e){if("file"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateAllSkillCardsOnFileRequestBodyFileTypeField"})}function O(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function z(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateAllSkillCardsOnFileRequestBodyFileField"'});const t=null==e.type?void 0:P(e.type);if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UpdateAllSkillCardsOnFileRequestBodyFileField"'});return{type:t,id:null==e.id?void 0:e.id}}function N(e){return e}function q(e){if("file_version"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateAllSkillCardsOnFileRequestBodyFileVersionTypeField"})}function U(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function L(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateAllSkillCardsOnFileRequestBodyFileVersionField"'});const t=null==e.type?void 0:q(e.type);if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UpdateAllSkillCardsOnFileRequestBodyFileVersionField"'});return{type:t,id:null==e.id?void 0:e.id}}function j(e){return{unit:null==e.unit?void 0:e.unit,value:null==e.value?void 0:e.value}}function H(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateAllSkillCardsOnFileRequestBodyUsageField"'});if(null!=e.unit&&!(0,h.sdIsString)(e.unit))throw new u.BoxSdkError({message:'Expecting string for "unit" of type "UpdateAllSkillCardsOnFileRequestBodyUsageField"'});const t=null==e.unit?void 0:e.unit;if(null!=e.value&&!(0,p.sdIsNumber)(e.value))throw new u.BoxSdkError({message:'Expecting number for "value" of type "UpdateAllSkillCardsOnFileRequestBodyUsageField"'});return{unit:t,value:null==e.value?void 0:e.value}}function $(e){return{status:e.status,metadata:M(e.metadata),file:O(e.file),file_version:null==e.fileVersion?void 0:U(e.fileVersion),usage:null==e.usage?void 0:j(e.usage)}}t.SkillsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getBoxSkillCardsOnFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/metadata/global/boxSkillsCards"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeSkillCardsMetadata)(a.data)),{rawData:a.data})}))}createBoxSkillCardsOnFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new y({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/metadata/global/boxSkillsCards"),method:"POST",headers:a,data:T(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeSkillCardsMetadata)(u.data)),{rawData:u.data})}))}updateBoxSkillCardsOnFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new v({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/metadata/global/boxSkillsCards"),method:"PUT",headers:a,data:t.map(I),contentType:"application/json-patch+json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeSkillCardsMetadata)(u.data)),{rawData:u.data})}))}deleteBoxSkillCardsFromFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,d.toString)(e),"/metadata/global/boxSkillsCards"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}updateAllSkillCardsOnFile(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new w({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,l.prepareParams)(Object.assign({},n.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/skill_invocations/",(0,d.toString)(e)),method:"PUT",headers:s,data:$(t),contentType:"application/json",responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}}},59465:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.StoragePoliciesManager=t.GetStoragePolicyByIdHeaders=t.GetStoragePoliciesHeaders=t.GetStoragePolicyByIdOptionals=void 0;const n=r(95199),o=r(32735),s=r(31210),a=r(93845),l=r(93845),d=r(84143);class c{constructor(e){this.headers=new p({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetStoragePolicyByIdOptionals=c;class u{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetStoragePoliciesHeaders=u;class p{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetStoragePolicyByIdHeaders=p;t.StoragePoliciesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getStoragePolicies(){return i(this,arguments,void 0,(function*(e={},t=new u({}),r){const i=new u({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({fields:e.fields?e.fields.map(l.toString).join(","):void 0,marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policies"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeStoragePolicies)(c.data)),{rawData:c.data})}))}getStoragePolicyById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policies/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeStoragePolicy)(u.data)),{rawData:u.data})}))}}},32537:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.StoragePolicyAssignmentsManager=t.DeleteStoragePolicyAssignmentByIdHeaders=t.UpdateStoragePolicyAssignmentByIdHeaders=t.UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField=t.GetStoragePolicyAssignmentByIdHeaders=t.CreateStoragePolicyAssignmentHeaders=t.CreateStoragePolicyAssignmentRequestBodyStoragePolicyField=t.GetStoragePolicyAssignmentsHeaders=t.DeleteStoragePolicyAssignmentByIdOptionals=t.UpdateStoragePolicyAssignmentByIdOptionals=t.GetStoragePolicyAssignmentByIdOptionals=t.CreateStoragePolicyAssignmentOptionals=t.GetStoragePolicyAssignmentsOptionals=void 0,t.serializeGetStoragePolicyAssignmentsQueryParamsResolvedForTypeField=function(e){return e},t.deserializeGetStoragePolicyAssignmentsQueryParamsResolvedForTypeField=function(e){if("user"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetStoragePolicyAssignmentsQueryParamsResolvedForTypeField"})},t.serializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyTypeField=S,t.deserializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyTypeField=k,t.serializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyField=E,t.deserializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyField=T,t.serializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeCreateStoragePolicyAssignmentRequestBodyStoragePolicyFieldInput=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateStoragePolicyAssignmentRequestBodyStoragePolicyFieldInput"'});const t=null==e.type?void 0:k(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateStoragePolicyAssignmentRequestBodyStoragePolicyFieldInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateStoragePolicyAssignmentRequestBodyStoragePolicyFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeCreateStoragePolicyAssignmentRequestBodyAssignedToTypeField=B,t.deserializeCreateStoragePolicyAssignmentRequestBodyAssignedToTypeField=C,t.serializeCreateStoragePolicyAssignmentRequestBodyAssignedToField=I,t.deserializeCreateStoragePolicyAssignmentRequestBodyAssignedToField=A,t.serializeCreateStoragePolicyAssignmentRequestBody=F,t.deserializeCreateStoragePolicyAssignmentRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateStoragePolicyAssignmentRequestBody"'});if(null==e.storage_policy)throw new c.BoxSdkError({message:'Expecting "storage_policy" of type "CreateStoragePolicyAssignmentRequestBody" to be defined'});const t=T(e.storage_policy);if(null==e.assigned_to)throw new c.BoxSdkError({message:'Expecting "assigned_to" of type "CreateStoragePolicyAssignmentRequestBody" to be defined'});const r=A(e.assigned_to);return{storagePolicy:t,assignedTo:r}},t.serializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyTypeField=M,t.deserializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyTypeField=D,t.serializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField=R,t.deserializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField=P,t.serializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeUpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyFieldInput=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyFieldInput"'});const t=null==e.type?void 0:D(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyFieldInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeUpdateStoragePolicyAssignmentByIdRequestBody=O,t.deserializeUpdateStoragePolicyAssignmentByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateStoragePolicyAssignmentByIdRequestBody"'});if(null==e.storage_policy)throw new c.BoxSdkError({message:'Expecting "storage_policy" of type "UpdateStoragePolicyAssignmentByIdRequestBody" to be defined'});return{storagePolicy:P(e.storage_policy)}};const n=r(87335),o=r(66778),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetStoragePolicyAssignmentsOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateStoragePolicyAssignmentOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetStoragePolicyAssignmentByIdOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateStoragePolicyAssignmentByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteStoragePolicyAssignmentByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetStoragePolicyAssignmentsHeaders=v;t.CreateStoragePolicyAssignmentRequestBodyStoragePolicyField=class{constructor(e){this.type="storage_policy",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateStoragePolicyAssignmentHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetStoragePolicyAssignmentByIdHeaders=w;t.UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField=class{constructor(e){this.type="storage_policy",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateStoragePolicyAssignmentByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteStoragePolicyAssignmentByIdHeaders=x;function S(e){return e}function k(e){if("storage_policy"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateStoragePolicyAssignmentRequestBodyStoragePolicyTypeField"})}function E(e){return{type:e.type,id:e.id}}function T(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateStoragePolicyAssignmentRequestBodyStoragePolicyField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateStoragePolicyAssignmentRequestBodyStoragePolicyField" to be defined'});const t=k(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateStoragePolicyAssignmentRequestBodyStoragePolicyField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateStoragePolicyAssignmentRequestBodyStoragePolicyField"'});return{type:t,id:e.id}}function B(e){return e}function C(e){if("user"==e)return e;if("enterprise"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateStoragePolicyAssignmentRequestBodyAssignedToTypeField"})}function I(e){return{type:e.type,id:e.id}}function A(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateStoragePolicyAssignmentRequestBodyAssignedToField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateStoragePolicyAssignmentRequestBodyAssignedToField" to be defined'});const t=C(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateStoragePolicyAssignmentRequestBodyAssignedToField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateStoragePolicyAssignmentRequestBodyAssignedToField"'});return{type:t,id:e.id}}function F(e){return{storage_policy:E(e.storagePolicy),assigned_to:I(e.assignedTo)}}function M(e){return e}function D(e){if("storage_policy"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyTypeField"})}function R(e){return{type:e.type,id:e.id}}function P(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField" to be defined'});const t=D(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "UpdateStoragePolicyAssignmentByIdRequestBodyStoragePolicyField"'});return{type:t,id:e.id}}function O(e){return{storage_policy:R(e.storagePolicy)}}t.StoragePolicyAssignmentsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getStoragePolicyAssignments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),resolved_for_type:(0,l.toString)(e.resolvedForType),resolved_for_id:(0,l.toString)(e.resolvedForId)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policy_assignments"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeStoragePolicyAssignments)(u.data)),{rawData:u.data})}))}createStoragePolicyAssignment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policy_assignments"),method:"POST",headers:s,data:F(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeStoragePolicyAssignment)(l.data)),{rawData:l.data})}))}getStoragePolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policy_assignments/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeStoragePolicyAssignment)(c.data)),{rawData:c.data})}))}updateStoragePolicyAssignmentById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,s=i.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policy_assignments/",(0,l.toString)(e)),method:"PUT",headers:c,data:O(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeStoragePolicyAssignment)(u.data)),{rawData:u.data})}))}deleteStoragePolicyAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/storage_policy_assignments/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},81495:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TaskAssignmentsManager=t.DeleteTaskAssignmentByIdHeaders=t.UpdateTaskAssignmentByIdHeaders=t.GetTaskAssignmentByIdHeaders=t.CreateTaskAssignmentHeaders=t.CreateTaskAssignmentRequestBodyTaskField=t.GetTaskAssignmentsHeaders=t.DeleteTaskAssignmentByIdOptionals=t.UpdateTaskAssignmentByIdOptionals=t.GetTaskAssignmentByIdOptionals=t.CreateTaskAssignmentOptionals=t.GetTaskAssignmentsOptionals=void 0,t.serializeCreateTaskAssignmentRequestBodyTaskTypeField=S,t.deserializeCreateTaskAssignmentRequestBodyTaskTypeField=k,t.serializeCreateTaskAssignmentRequestBodyTaskField=E,t.deserializeCreateTaskAssignmentRequestBodyTaskField=T,t.serializeCreateTaskAssignmentRequestBodyTaskFieldInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeCreateTaskAssignmentRequestBodyTaskFieldInput=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTaskAssignmentRequestBodyTaskFieldInput"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTaskAssignmentRequestBodyTaskFieldInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTaskAssignmentRequestBodyTaskFieldInput"'});const t=e.id,r=null==e.type?void 0:k(e.type);return{id:t,type:r}},t.serializeCreateTaskAssignmentRequestBodyAssignToField=B,t.deserializeCreateTaskAssignmentRequestBodyAssignToField=C,t.serializeCreateTaskAssignmentRequestBody=I,t.deserializeCreateTaskAssignmentRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTaskAssignmentRequestBody"'});if(null==e.task)throw new c.BoxSdkError({message:'Expecting "task" of type "CreateTaskAssignmentRequestBody" to be defined'});const t=T(e.task);if(null==e.assign_to)throw new c.BoxSdkError({message:'Expecting "assign_to" of type "CreateTaskAssignmentRequestBody" to be defined'});const r=C(e.assign_to);return{task:t,assignTo:r}},t.serializeUpdateTaskAssignmentByIdRequestBodyResolutionStateField=A,t.deserializeUpdateTaskAssignmentByIdRequestBodyResolutionStateField=F,t.serializeUpdateTaskAssignmentByIdRequestBody=M,t.deserializeUpdateTaskAssignmentByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateTaskAssignmentByIdRequestBody"'});if(null!=e.message&&!(0,u.sdIsString)(e.message))throw new c.BoxSdkError({message:'Expecting string for "message" of type "UpdateTaskAssignmentByIdRequestBody"'});const t=null==e.message?void 0:e.message,r=null==e.resolution_state?void 0:F(e.resolution_state);return{message:t,resolutionState:r}};const n=r(85065),o=r(6884),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTaskAssignmentsOptionals=h;class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateTaskAssignmentOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTaskAssignmentByIdOptionals=m;class g{constructor(e){this.requestBody={},this.headers=new _({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateTaskAssignmentByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteTaskAssignmentByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTaskAssignmentsHeaders=v;t.CreateTaskAssignmentRequestBodyTaskField=class{constructor(e){this.type="task",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}};class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateTaskAssignmentHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTaskAssignmentByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateTaskAssignmentByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteTaskAssignmentByIdHeaders=x;function S(e){return e}function k(e){if("task"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateTaskAssignmentRequestBodyTaskTypeField"})}function E(e){return{id:e.id,type:e.type}}function T(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTaskAssignmentRequestBodyTaskField"'});if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTaskAssignmentRequestBodyTaskField" to be defined'});if(!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTaskAssignmentRequestBodyTaskField"'});const t=e.id;if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateTaskAssignmentRequestBodyTaskField" to be defined'});return{id:t,type:k(e.type)}}function B(e){return{id:null==e.id?void 0:e.id,login:null==e.login?void 0:e.login}}function C(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTaskAssignmentRequestBodyAssignToField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTaskAssignmentRequestBodyAssignToField"'});const t=null==e.id?void 0:e.id;if(null!=e.login&&!(0,u.sdIsString)(e.login))throw new c.BoxSdkError({message:'Expecting string for "login" of type "CreateTaskAssignmentRequestBodyAssignToField"'});return{id:t,login:null==e.login?void 0:e.login}}function I(e){return{task:E(e.task),assign_to:B(e.assignTo)}}function A(e){return e}function F(e){if("completed"==e)return e;if("incomplete"==e)return e;if("approved"==e)return e;if("rejected"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateTaskAssignmentByIdRequestBodyResolutionStateField"})}function M(e){return{message:null==e.message?void 0:e.message,resolution_state:null==e.resolutionState?void 0:e.resolutionState}}t.TaskAssignmentsManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getTaskAssignments(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/tasks/",(0,l.toString)(e),"/assignments"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeTaskAssignments)(c.data)),{rawData:c.data})}))}createTaskAssignment(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/task_assignments"),method:"POST",headers:s,data:I(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTaskAssignment)(l.data)),{rawData:l.data})}))}getTaskAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/task_assignments/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTaskAssignment)(c.data)),{rawData:c.data})}))}updateTaskAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/task_assignments/",(0,l.toString)(e)),method:"PUT",headers:c,data:M(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTaskAssignment)(u.data)),{rawData:u.data})}))}deleteTaskAssignmentById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/task_assignments/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},13612:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TasksManager=t.DeleteTaskByIdHeaders=t.UpdateTaskByIdHeaders=t.GetTaskByIdHeaders=t.CreateTaskHeaders=t.GetFileTasksHeaders=t.DeleteTaskByIdOptionals=t.UpdateTaskByIdOptionals=t.GetTaskByIdOptionals=t.CreateTaskOptionals=t.GetFileTasksOptionals=void 0,t.serializeCreateTaskRequestBodyItemTypeField=E,t.deserializeCreateTaskRequestBodyItemTypeField=T,t.serializeCreateTaskRequestBodyItemField=B,t.deserializeCreateTaskRequestBodyItemField=C,t.serializeCreateTaskRequestBodyActionField=I,t.deserializeCreateTaskRequestBodyActionField=A,t.serializeCreateTaskRequestBodyCompletionRuleField=F,t.deserializeCreateTaskRequestBodyCompletionRuleField=M,t.serializeCreateTaskRequestBody=D,t.deserializeCreateTaskRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateTaskRequestBody"'});if(null==e.item)throw new p.BoxSdkError({message:'Expecting "item" of type "CreateTaskRequestBody" to be defined'});const t=C(e.item),r=null==e.action?void 0:A(e.action);if(null!=e.message&&!(0,h.sdIsString)(e.message))throw new p.BoxSdkError({message:'Expecting string for "message" of type "CreateTaskRequestBody"'});const i=null==e.message?void 0:e.message;if(null!=e.due_at&&!(0,h.sdIsString)(e.due_at))throw new p.BoxSdkError({message:'Expecting string for "due_at" of type "CreateTaskRequestBody"'});const n=null==e.due_at?void 0:(0,a.deserializeDateTime)(e.due_at),o=null==e.completion_rule?void 0:M(e.completion_rule);return{item:t,action:r,message:i,dueAt:n,completionRule:o}},t.serializeUpdateTaskByIdRequestBodyActionField=R,t.deserializeUpdateTaskByIdRequestBodyActionField=P,t.serializeUpdateTaskByIdRequestBodyCompletionRuleField=O,t.deserializeUpdateTaskByIdRequestBodyCompletionRuleField=z,t.serializeUpdateTaskByIdRequestBody=N,t.deserializeUpdateTaskByIdRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateTaskByIdRequestBody"'});const t=null==e.action?void 0:P(e.action);if(null!=e.message&&!(0,h.sdIsString)(e.message))throw new p.BoxSdkError({message:'Expecting string for "message" of type "UpdateTaskByIdRequestBody"'});const r=null==e.message?void 0:e.message;if(null!=e.due_at&&!(0,h.sdIsString)(e.due_at))throw new p.BoxSdkError({message:'Expecting string for "due_at" of type "UpdateTaskByIdRequestBody"'});const i=null==e.due_at?void 0:(0,a.deserializeDateTime)(e.due_at),n=null==e.completion_rule?void 0:z(e.completion_rule);return{action:t,message:r,dueAt:i,completionRule:n}};const n=r(46682),o=r(62125),s=r(93845),a=r(93845),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetFileTasksOptionals=m;class g{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateTaskOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTaskByIdOptionals=y;class v{constructor(e){this.requestBody={},this.headers=new S({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateTaskByIdOptionals=v;class b{constructor(e){this.headers=new k({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteTaskByIdOptionals=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetFileTasksHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateTaskHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTaskByIdHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateTaskByIdHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteTaskByIdHeaders=k;function E(e){return e}function T(e){if("file"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateTaskRequestBodyItemTypeField"})}function B(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function C(e){if(!(0,f.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateTaskRequestBodyItemField"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "CreateTaskRequestBodyItemField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:T(e.type)}}function I(e){return e}function A(e){if("review"==e)return e;if("complete"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateTaskRequestBodyActionField"})}function F(e){return e}function M(e){if("all_assignees"==e)return e;if("any_assignee"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateTaskRequestBodyCompletionRuleField"})}function D(e){return{item:B(e.item),action:null==e.action?void 0:e.action,message:null==e.message?void 0:e.message,due_at:null==e.dueAt?void 0:(0,s.serializeDateTime)(e.dueAt),completion_rule:null==e.completionRule?void 0:e.completionRule}}function R(e){return e}function P(e){if("review"==e)return e;if("complete"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateTaskByIdRequestBodyActionField"})}function O(e){return e}function z(e){if("all_assignees"==e)return e;if("any_assignee"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateTaskByIdRequestBodyCompletionRuleField"})}function N(e){return{action:null==e.action?void 0:e.action,message:null==e.message?void 0:e.message,due_at:null==e.dueAt?void 0:(0,s.serializeDateTime)(e.dueAt),completion_rule:null==e.completionRule?void 0:e.completionRule}}t.TasksManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getFileTasks(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,c.toString)(e),"/tasks"),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeTasks)(a.data)),{rawData:a.data})}))}createTask(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/tasks"),method:"POST",headers:s,data:D(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTask)(a.data)),{rawData:a.data})}))}getTaskById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/tasks/",(0,c.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTask)(a.data)),{rawData:a.data})}))}updateTaskById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)(Object.assign({},n.extraHeaders)),l=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/tasks/",(0,c.toString)(e)),method:"PUT",headers:a,data:N(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTask)(l.data)),{rawData:l.data})}))}deleteTaskById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,d.prepareParams)(Object.assign({},i.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/tasks/",(0,c.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},52162:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TermsOfServiceUserStatusesManager=t.UpdateTermsOfServiceStatusForUserByIdHeaders=t.CreateTermsOfServiceStatusForUserHeaders=t.CreateTermsOfServiceStatusForUserRequestBodyUserField=t.CreateTermsOfServiceStatusForUserRequestBodyTosField=t.GetTermsOfServiceUserStatusesHeaders=t.UpdateTermsOfServiceStatusForUserByIdOptionals=t.CreateTermsOfServiceStatusForUserOptionals=t.GetTermsOfServiceUserStatusesOptionals=void 0,t.serializeCreateTermsOfServiceStatusForUserRequestBodyTosTypeField=w,t.deserializeCreateTermsOfServiceStatusForUserRequestBodyTosTypeField=_,t.serializeCreateTermsOfServiceStatusForUserRequestBodyTosField=x,t.deserializeCreateTermsOfServiceStatusForUserRequestBodyTosField=S,t.serializeCreateTermsOfServiceStatusForUserRequestBodyTosFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeCreateTermsOfServiceStatusForUserRequestBodyTosFieldInput=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceStatusForUserRequestBodyTosFieldInput"'});const t=null==e.type?void 0:_(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTermsOfServiceStatusForUserRequestBodyTosFieldInput" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTermsOfServiceStatusForUserRequestBodyTosFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeCreateTermsOfServiceStatusForUserRequestBodyUserTypeField=k,t.deserializeCreateTermsOfServiceStatusForUserRequestBodyUserTypeField=E,t.serializeCreateTermsOfServiceStatusForUserRequestBodyUserField=T,t.deserializeCreateTermsOfServiceStatusForUserRequestBodyUserField=B,t.serializeCreateTermsOfServiceStatusForUserRequestBodyUserFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeCreateTermsOfServiceStatusForUserRequestBodyUserFieldInput=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceStatusForUserRequestBodyUserFieldInput"'});const t=null==e.type?void 0:E(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTermsOfServiceStatusForUserRequestBodyUserFieldInput" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTermsOfServiceStatusForUserRequestBodyUserFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeCreateTermsOfServiceStatusForUserRequestBody=C,t.deserializeCreateTermsOfServiceStatusForUserRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceStatusForUserRequestBody"'});if(null==e.tos)throw new c.BoxSdkError({message:'Expecting "tos" of type "CreateTermsOfServiceStatusForUserRequestBody" to be defined'});const t=S(e.tos);if(null==e.user)throw new c.BoxSdkError({message:'Expecting "user" of type "CreateTermsOfServiceStatusForUserRequestBody" to be defined'});const r=B(e.user);if(null==e.is_accepted)throw new c.BoxSdkError({message:'Expecting "is_accepted" of type "CreateTermsOfServiceStatusForUserRequestBody" to be defined'});if(!(0,u.sdIsBoolean)(e.is_accepted))throw new c.BoxSdkError({message:'Expecting boolean for "is_accepted" of type "CreateTermsOfServiceStatusForUserRequestBody"'});const i=e.is_accepted;return{tos:t,user:r,isAccepted:i}},t.serializeUpdateTermsOfServiceStatusForUserByIdRequestBody=I,t.deserializeUpdateTermsOfServiceStatusForUserByIdRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateTermsOfServiceStatusForUserByIdRequestBody"'});if(null==e.is_accepted)throw new c.BoxSdkError({message:'Expecting "is_accepted" of type "UpdateTermsOfServiceStatusForUserByIdRequestBody" to be defined'});if(!(0,u.sdIsBoolean)(e.is_accepted))throw new c.BoxSdkError({message:'Expecting boolean for "is_accepted" of type "UpdateTermsOfServiceStatusForUserByIdRequestBody"'});return{isAccepted:e.is_accepted}};const n=r(32228),o=r(60848),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTermsOfServiceUserStatusesOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateTermsOfServiceStatusForUserOptionals=m;class g{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateTermsOfServiceStatusForUserByIdOptionals=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTermsOfServiceUserStatusesHeaders=y;t.CreateTermsOfServiceStatusForUserRequestBodyTosField=class{constructor(e){this.type="terms_of_service",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};t.CreateTermsOfServiceStatusForUserRequestBodyUserField=class{constructor(e){this.type="user",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateTermsOfServiceStatusForUserHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateTermsOfServiceStatusForUserByIdHeaders=b;function w(e){return e}function _(e){if("terms_of_service"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateTermsOfServiceStatusForUserRequestBodyTosTypeField"})}function x(e){return{type:e.type,id:e.id}}function S(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceStatusForUserRequestBodyTosField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateTermsOfServiceStatusForUserRequestBodyTosField" to be defined'});const t=_(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTermsOfServiceStatusForUserRequestBodyTosField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTermsOfServiceStatusForUserRequestBodyTosField"'});return{type:t,id:e.id}}function k(e){return e}function E(e){if("user"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateTermsOfServiceStatusForUserRequestBodyUserTypeField"})}function T(e){return{type:e.type,id:e.id}}function B(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceStatusForUserRequestBodyUserField"'});if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "CreateTermsOfServiceStatusForUserRequestBodyUserField" to be defined'});const t=E(e.type);if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "CreateTermsOfServiceStatusForUserRequestBodyUserField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateTermsOfServiceStatusForUserRequestBodyUserField"'});return{type:t,id:e.id}}function C(e){return{tos:x(e.tos),user:T(e.user),is_accepted:e.isAccepted}}function I(e){return{is_accepted:e.isAccepted}}t.TermsOfServiceUserStatusesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getTermsOfServiceUserStatuses(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,a.prepareParams)({tos_id:(0,l.toString)(e.tosId),user_id:(0,l.toString)(e.userId)}),c=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_service_user_statuses"),method:"GET",params:s,headers:c,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeTermsOfServiceUserStatuses)(u.data)),{rawData:u.data})}))}createTermsOfServiceStatusForUser(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_service_user_statuses"),method:"POST",headers:s,data:C(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTermsOfServiceUserStatus)(l.data)),{rawData:l.data})}))}updateTermsOfServiceStatusForUserById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,s=i.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_service_user_statuses/",(0,l.toString)(e)),method:"PUT",headers:c,data:I(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTermsOfServiceUserStatus)(u.data)),{rawData:u.data})}))}}},61020:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TermsOfServicesManager=t.UpdateTermsOfServiceByIdHeaders=t.GetTermsOfServiceByIdHeaders=t.CreateTermsOfServiceHeaders=t.GetTermsOfServiceHeaders=t.UpdateTermsOfServiceByIdOptionals=t.GetTermsOfServiceByIdOptionals=t.CreateTermsOfServiceOptionals=void 0,t.serializeGetTermsOfServiceQueryParamsTosTypeField=function(e){return e},t.deserializeGetTermsOfServiceQueryParamsTosTypeField=function(e){if("external"==e)return e;if("managed"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize GetTermsOfServiceQueryParamsTosTypeField"})},t.serializeCreateTermsOfServiceRequestBodyStatusField=w,t.deserializeCreateTermsOfServiceRequestBodyStatusField=_,t.serializeCreateTermsOfServiceRequestBodyTosTypeField=x,t.deserializeCreateTermsOfServiceRequestBodyTosTypeField=S,t.serializeCreateTermsOfServiceRequestBody=k,t.deserializeCreateTermsOfServiceRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateTermsOfServiceRequestBody"'});if(null==e.status)throw new c.BoxSdkError({message:'Expecting "status" of type "CreateTermsOfServiceRequestBody" to be defined'});const t=_(e.status),r=null==e.tos_type?void 0:S(e.tos_type);if(null==e.text)throw new c.BoxSdkError({message:'Expecting "text" of type "CreateTermsOfServiceRequestBody" to be defined'});if(!(0,u.sdIsString)(e.text))throw new c.BoxSdkError({message:'Expecting string for "text" of type "CreateTermsOfServiceRequestBody"'});const i=e.text;return{status:t,tosType:r,text:i}},t.serializeUpdateTermsOfServiceByIdRequestBodyStatusField=E,t.deserializeUpdateTermsOfServiceByIdRequestBodyStatusField=T,t.serializeUpdateTermsOfServiceByIdRequestBody=B,t.deserializeUpdateTermsOfServiceByIdRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateTermsOfServiceByIdRequestBody"'});if(null==e.status)throw new c.BoxSdkError({message:'Expecting "status" of type "UpdateTermsOfServiceByIdRequestBody" to be defined'});const t=T(e.status);if(null==e.text)throw new c.BoxSdkError({message:'Expecting "text" of type "UpdateTermsOfServiceByIdRequestBody" to be defined'});if(!(0,u.sdIsString)(e.text))throw new c.BoxSdkError({message:'Expecting string for "text" of type "UpdateTermsOfServiceByIdRequestBody"'});const r=e.text;return{status:t,text:r}};const n=r(67426),o=r(13669),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateTermsOfServiceOptionals=h;class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTermsOfServiceByIdOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateTermsOfServiceByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTermsOfServiceHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateTermsOfServiceHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTermsOfServiceByIdHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateTermsOfServiceByIdHeaders=b;function w(e){return e}function _(e){if("enabled"==e)return e;if("disabled"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateTermsOfServiceRequestBodyStatusField"})}function x(e){return e}function S(e){if("external"==e)return e;if("managed"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateTermsOfServiceRequestBodyTosTypeField"})}function k(e){return{status:e.status,tos_type:null==e.tosType?void 0:e.tosType,text:e.text}}function E(e){return e}function T(e){if("enabled"==e)return e;if("disabled"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateTermsOfServiceByIdRequestBodyStatusField"})}function B(e){return{status:e.status,text:e.text}}t.TermsOfServicesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getTermsOfService(){return i(this,arguments,void 0,(function*(e={},t=new g({}),r){const i=new g({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({tos_type:(0,l.toString)(e.tosType)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_services"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeTermsOfServices)(c.data)),{rawData:c.data})}))}createTermsOfService(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_services"),method:"POST",headers:s,data:k(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTermsOfService)(l.data)),{rawData:l.data})}))}getTermsOfServiceById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_services/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeTermsOfService)(c.data)),{rawData:c.data})}))}updateTermsOfServiceById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new m({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,s=i.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/terms_of_services/",(0,l.toString)(e)),method:"PUT",headers:c,data:B(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTermsOfService)(u.data)),{rawData:u.data})}))}}},87653:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TransferManager=t.TransferOwnedFolderHeaders=t.TransferOwnedFolderOptionals=void 0,t.serializeTransferOwnedFolderRequestBodyOwnedByField=f,t.deserializeTransferOwnedFolderRequestBodyOwnedByField=m,t.serializeTransferOwnedFolderRequestBody=g,t.deserializeTransferOwnedFolderRequestBody=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TransferOwnedFolderRequestBody"'});if(null==e.owned_by)throw new d.BoxSdkError({message:'Expecting "owned_by" of type "TransferOwnedFolderRequestBody" to be defined'});return{ownedBy:m(e.owned_by)}};const n=r(34537),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631),c=r(50793),u=r(50793);class p{constructor(e){this.queryParams={},this.headers=new h({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.TransferOwnedFolderOptionals=p;class h{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.TransferOwnedFolderHeaders=h;function f(e){return{id:e.id}}function m(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TransferOwnedFolderRequestBodyOwnedByField"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "TransferOwnedFolderRequestBodyOwnedByField" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TransferOwnedFolderRequestBodyOwnedByField"'});return{id:e.id}}function g(e){return{owned_by:f(e.ownedBy)}}t.TransferManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}transferOwnedFolder(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new p({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),o=i.queryParams,d=i.headers,c=i.cancellationToken,u=(0,s.prepareParams)({fields:o.fields?o.fields.map(a.toString).join(","):void 0,notify:(0,a.toString)(o.notify)}),h=(0,s.prepareParams)(Object.assign({},d.extraHeaders)),f=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,a.toString)(e),"/folders/0"),method:"PUT",params:u,headers:h,data:g(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,n.deserializeFolderFull)(f.data)),{rawData:f.data})}))}}},45244:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TrashedFilesManager=t.DeleteTrashedFileByIdHeaders=t.GetTrashedFileByIdHeaders=t.RestoreFileFromTrashHeaders=t.DeleteTrashedFileByIdOptionals=t.GetTrashedFileByIdOptionals=t.RestoreFileFromTrashOptionals=void 0,t.serializeRestoreFileFromTrashRequestBodyParentField=b,t.deserializeRestoreFileFromTrashRequestBodyParentField=w,t.serializeRestoreFileFromTrashRequestBody=_,t.deserializeRestoreFileFromTrashRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreFileFromTrashRequestBody"'});if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "RestoreFileFromTrashRequestBody"'});const t=null==e.name?void 0:e.name,r=null==e.parent?void 0:w(e.parent);return{name:t,parent:r}};const n=r(40950),o=r(37416),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.requestBody={},this.queryParams={},this.headers=new g({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RestoreFileFromTrashOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new y({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTrashedFileByIdOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteTrashedFileByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RestoreFileFromTrashHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTrashedFileByIdHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteTrashedFileByIdHeaders=v;function b(e){return{id:null==e.id?void 0:e.id}}function w(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreFileFromTrashRequestBodyParentField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "RestoreFileFromTrashRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function _(e){return{name:null==e.name?void 0:e.name,parent:null==e.parent?void 0:b(e.parent)}}t.TrashedFilesManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}restoreFileFromTrash(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:o.fields?o.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),f=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e)),method:"POST",params:u,headers:p,data:_(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,n.deserializeTrashFileRestored)(f.data)),{rawData:f.data})}))}getTrashedFileById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/trash"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTrashFile)(p.data)),{rawData:p.data})}))}deleteTrashedFileById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/",(0,l.toString)(e),"/trash"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},79434:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TrashedFoldersManager=t.DeleteTrashedFolderByIdHeaders=t.GetTrashedFolderByIdHeaders=t.RestoreFolderFromTrashHeaders=t.DeleteTrashedFolderByIdOptionals=t.GetTrashedFolderByIdOptionals=t.RestoreFolderFromTrashOptionals=void 0,t.serializeRestoreFolderFromTrashRequestBodyParentField=b,t.deserializeRestoreFolderFromTrashRequestBodyParentField=w,t.serializeRestoreFolderFromTrashRequestBody=_,t.deserializeRestoreFolderFromTrashRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreFolderFromTrashRequestBody"'});if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "RestoreFolderFromTrashRequestBody"'});const t=null==e.name?void 0:e.name,r=null==e.parent?void 0:w(e.parent);return{name:t,parent:r}};const n=r(84064),o=r(4346),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.requestBody={},this.queryParams={},this.headers=new g({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RestoreFolderFromTrashOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new y({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTrashedFolderByIdOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteTrashedFolderByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RestoreFolderFromTrashHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTrashedFolderByIdHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteTrashedFolderByIdHeaders=v;function b(e){return{id:null==e.id?void 0:e.id}}function w(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreFolderFromTrashRequestBodyParentField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "RestoreFolderFromTrashRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function _(e){return{name:null==e.name?void 0:e.name,parent:null==e.parent?void 0:b(e.parent)}}t.TrashedFoldersManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}restoreFolderFromTrash(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:o.fields?o.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),f=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e)),method:"POST",params:u,headers:p,data:_(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,n.deserializeTrashFolderRestored)(f.data)),{rawData:f.data})}))}getTrashedFolderById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/trash"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTrashFolder)(p.data)),{rawData:p.data})}))}deleteTrashedFolderById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/",(0,l.toString)(e),"/trash"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},91475:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TrashedItemsManager=t.GetTrashedItemsHeaders=void 0,t.serializeGetTrashedItemsQueryParamsDirectionField=function(e){return e},t.deserializeGetTrashedItemsQueryParamsDirectionField=function(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize GetTrashedItemsQueryParamsDirectionField"})},t.serializeGetTrashedItemsQueryParamsSortField=function(e){return e},t.deserializeGetTrashedItemsQueryParamsSortField=function(e){if("name"==e)return e;if("date"==e)return e;if("size"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize GetTrashedItemsQueryParamsSortField"})};const n=r(61664),o=r(31210),s=r(93845),a=r(93845),l=r(84143),d=r(72631);class c{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTrashedItemsHeaders=c;t.TrashedItemsManager=class{constructor(e){this.networkSession=new o.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getTrashedItems(){return i(this,arguments,void 0,(function*(e={},t=new c({}),r){const i=new c({extraHeaders:t.extraHeaders}),o=(0,s.prepareParams)({fields:e.fields?e.fields.map(a.toString).join(","):void 0,limit:(0,a.toString)(e.limit),offset:(0,a.toString)(e.offset),usemarker:(0,a.toString)(e.usemarker),marker:(0,a.toString)(e.marker),direction:(0,a.toString)(e.direction),sort:(0,a.toString)(e.sort)}),d=(0,s.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,l.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/folders/trash/items"),method:"GET",params:o,headers:d,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeItems)(u.data)),{rawData:u.data})}))}}},57634:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.TrashedWebLinksManager=t.DeleteTrashedWebLinkByIdHeaders=t.GetTrashedWebLinkByIdHeaders=t.RestoreWeblinkFromTrashHeaders=t.DeleteTrashedWebLinkByIdOptionals=t.GetTrashedWebLinkByIdOptionals=t.RestoreWeblinkFromTrashOptionals=void 0,t.serializeRestoreWeblinkFromTrashRequestBodyParentField=b,t.deserializeRestoreWeblinkFromTrashRequestBodyParentField=w,t.serializeRestoreWeblinkFromTrashRequestBody=_,t.deserializeRestoreWeblinkFromTrashRequestBody=function(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreWeblinkFromTrashRequestBody"'});if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "RestoreWeblinkFromTrashRequestBody"'});const t=null==e.name?void 0:e.name,r=null==e.parent?void 0:w(e.parent);return{name:t,parent:r}};const n=r(49238),o=r(13640),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793);class h{constructor(e){this.requestBody={},this.queryParams={},this.headers=new g({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.RestoreWeblinkFromTrashOptionals=h;class f{constructor(e){this.queryParams={},this.headers=new y({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetTrashedWebLinkByIdOptionals=f;class m{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteTrashedWebLinkByIdOptionals=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.RestoreWeblinkFromTrashHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetTrashedWebLinkByIdHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteTrashedWebLinkByIdHeaders=v;function b(e){return{id:null==e.id?void 0:e.id}}function w(e){if(!(0,p.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "RestoreWeblinkFromTrashRequestBodyParentField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "RestoreWeblinkFromTrashRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function _(e){return{name:null==e.name?void 0:e.name,parent:null==e.parent?void 0:b(e.parent)}}t.TrashedWebLinksManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}restoreWeblinkFromTrash(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.queryParams,s=r.headers,c=r.cancellationToken,u=(0,a.prepareParams)({fields:o.fields?o.fields.map(l.toString).join(","):void 0}),p=(0,a.prepareParams)(Object.assign({},s.extraHeaders)),f=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,l.toString)(e)),method:"POST",params:u,headers:p,data:_(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:c});return Object.assign(Object.assign({},(0,n.deserializeTrashWebLinkRestored)(f.data)),{rawData:f.data})}))}getTrashedWebLinkById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)({fields:i.fields?i.fields.map(l.toString).join(","):void 0}),u=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,l.toString)(e),"/trash"),method:"GET",params:c,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeTrashWebLink)(p.data)),{rawData:p.data})}))}deleteTrashedWebLinkById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,l.toString)(e),"/trash"),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},25052:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.UploadsManager=t.UploadFileHeaders=t.PreflightFileUploadCheckHeaders=t.UploadFileVersionHeaders=t.UploadFileOptionals=t.UploadFileVersionOptionals=void 0,t.serializeUploadFileVersionRequestBodyAttributesField=_,t.deserializeUploadFileVersionRequestBodyAttributesField=function(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UploadFileVersionRequestBodyAttributesField"'});if(null==e.name)throw new p.BoxSdkError({message:'Expecting "name" of type "UploadFileVersionRequestBodyAttributesField" to be defined'});if(!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "UploadFileVersionRequestBodyAttributesField"'});const t=e.name;if(null!=e.content_modified_at&&!(0,f.sdIsString)(e.content_modified_at))throw new p.BoxSdkError({message:'Expecting string for "content_modified_at" of type "UploadFileVersionRequestBodyAttributesField"'});const r=null==e.content_modified_at?void 0:(0,a.deserializeDateTime)(e.content_modified_at);return{name:t,contentModifiedAt:r}},t.serializePreflightFileUploadCheckRequestBodyParentField=x,t.deserializePreflightFileUploadCheckRequestBodyParentField=S,t.serializePreflightFileUploadCheckRequestBody=k,t.deserializePreflightFileUploadCheckRequestBody=function(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "PreflightFileUploadCheckRequestBody"'});if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "PreflightFileUploadCheckRequestBody"'});const t=null==e.name?void 0:e.name;if(null!=e.size&&!(0,h.sdIsNumber)(e.size))throw new p.BoxSdkError({message:'Expecting number for "size" of type "PreflightFileUploadCheckRequestBody"'});const r=null==e.size?void 0:e.size,i=null==e.parent?void 0:S(e.parent);return{name:t,size:r,parent:i}},t.serializeUploadFileRequestBodyAttributesParentField=E,t.deserializeUploadFileRequestBodyAttributesParentField=T,t.serializeUploadFileRequestBodyAttributesField=B,t.deserializeUploadFileRequestBodyAttributesField=function(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UploadFileRequestBodyAttributesField"'});if(null==e.name)throw new p.BoxSdkError({message:'Expecting "name" of type "UploadFileRequestBodyAttributesField" to be defined'});if(!(0,f.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "UploadFileRequestBodyAttributesField"'});const t=e.name;if(null==e.parent)throw new p.BoxSdkError({message:'Expecting "parent" of type "UploadFileRequestBodyAttributesField" to be defined'});const r=T(e.parent);if(null!=e.content_created_at&&!(0,f.sdIsString)(e.content_created_at))throw new p.BoxSdkError({message:'Expecting string for "content_created_at" of type "UploadFileRequestBodyAttributesField"'});const i=null==e.content_created_at?void 0:(0,a.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,f.sdIsString)(e.content_modified_at))throw new p.BoxSdkError({message:'Expecting string for "content_modified_at" of type "UploadFileRequestBodyAttributesField"'});const n=null==e.content_modified_at?void 0:(0,a.deserializeDateTime)(e.content_modified_at);return{name:t,parent:r,contentCreatedAt:i,contentModifiedAt:n}};const n=r(379),o=r(2090),s=r(93845),a=r(93845),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793),m=r(50793);class g{constructor(e){this.queryParams={},this.headers=new v({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UploadFileVersionOptionals=g;class y{constructor(e){this.queryParams={},this.headers=new w({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UploadFileOptionals=y;class v{constructor(e){this.extraHeaders={},e.ifMatch&&(this.ifMatch=e.ifMatch),e.contentMd5&&(this.contentMd5=e.contentMd5),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UploadFileVersionHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.PreflightFileUploadCheckHeaders=b;class w{constructor(e){this.extraHeaders={},e.contentMd5&&(this.contentMd5=e.contentMd5),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UploadFileHeaders=w;function _(e){return{name:e.name,content_modified_at:null==e.contentModifiedAt?void 0:(0,s.serializeDateTime)(e.contentModifiedAt)}}function x(e){return{id:null==e.id?void 0:e.id}}function S(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "PreflightFileUploadCheckRequestBodyParentField"'});if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "PreflightFileUploadCheckRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function k(e){return{name:null==e.name?void 0:e.name,size:null==e.size?void 0:e.size,parent:null==e.parent?void 0:x(e.parent)}}function E(e){return{id:e.id}}function T(e){if(!(0,m.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UploadFileRequestBodyAttributesParentField"'});if(null==e.id)throw new p.BoxSdkError({message:'Expecting "id" of type "UploadFileRequestBodyAttributesParentField" to be defined'});if(!(0,f.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "UploadFileRequestBodyAttributesParentField"'});return{id:e.id}}function B(e){return{name:e.name,parent:E(e.parent),content_created_at:null==e.contentCreatedAt?void 0:(0,s.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,s.serializeDateTime)(e.contentModifiedAt)}}t.UploadsManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}uploadFileVersion(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({queryParams:r.queryParams,headers:r.headers,cancellationToken:r.cancellationToken}),o=i.queryParams,s=i.headers,a=i.cancellationToken,l=(0,d.prepareParams)({fields:o.fields?o.fields.map(c.toString).join(","):void 0}),p=(0,d.prepareParams)(Object.assign({"if-match":(0,c.toString)(s.ifMatch),"content-md5":(0,c.toString)(s.contentMd5)},s.extraHeaders)),h=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/",(0,c.toString)(e),"/content"),method:"POST",params:l,headers:p,multipartData:[{partName:"attributes",data:_(t.attributes)},{partName:"file",fileStream:t.file,fileName:t.fileFileName,contentType:t.fileContentType}],contentType:"multipart/form-data",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,n.deserializeFiles)(h.data)),{rawData:h.data})}))}preflightFileUploadCheck(){return i(this,arguments,void 0,(function*(e={},t=new b({}),r){const i=new b({extraHeaders:t.extraHeaders}),n=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),s=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/files/content"),method:"OPTIONS",headers:n,data:k(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,o.deserializeUploadUrl)(s.data)),{rawData:s.data})}))}uploadFile(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0}),l=(0,d.prepareParams)(Object.assign({"content-md5":(0,c.toString)(o.contentMd5)},o.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.uploadUrl,"/2.0/files/content"),method:"POST",params:a,headers:l,multipartData:[{partName:"attributes",data:B(e.attributes)},{partName:"file",fileStream:e.file,fileName:e.fileFileName,contentType:e.fileContentType}],contentType:"multipart/form-data",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeFiles)(p.data)),{rawData:p.data})}))}}},54991:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.UserCollaborationsManager=t.CreateCollaborationHeaders=t.DeleteCollaborationByIdHeaders=t.UpdateCollaborationByIdHeaders=t.GetCollaborationByIdHeaders=t.CreateCollaborationOptionals=t.DeleteCollaborationByIdOptionals=t.UpdateCollaborationByIdOptionals=t.GetCollaborationByIdOptionals=void 0,t.serializeUpdateCollaborationByIdRequestBodyRoleField=S,t.deserializeUpdateCollaborationByIdRequestBodyRoleField=k,t.serializeUpdateCollaborationByIdRequestBodyStatusField=E,t.deserializeUpdateCollaborationByIdRequestBodyStatusField=T,t.serializeUpdateCollaborationByIdRequestBody=B,t.deserializeUpdateCollaborationByIdRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateCollaborationByIdRequestBody"'});if(null==e.role)throw new u.BoxSdkError({message:'Expecting "role" of type "UpdateCollaborationByIdRequestBody" to be defined'});const t=k(e.role),r=null==e.status?void 0:T(e.status);if(null!=e.expires_at&&!(0,h.sdIsString)(e.expires_at))throw new u.BoxSdkError({message:'Expecting string for "expires_at" of type "UpdateCollaborationByIdRequestBody"'});const i=null==e.expires_at?void 0:(0,s.deserializeDateTime)(e.expires_at);if(null!=e.can_view_path&&!(0,p.sdIsBoolean)(e.can_view_path))throw new u.BoxSdkError({message:'Expecting boolean for "can_view_path" of type "UpdateCollaborationByIdRequestBody"'});const n=null==e.can_view_path?void 0:e.can_view_path;return{role:t,status:r,expiresAt:i,canViewPath:n}},t.serializeCreateCollaborationRequestBodyItemTypeField=C,t.deserializeCreateCollaborationRequestBodyItemTypeField=I,t.serializeCreateCollaborationRequestBodyItemField=A,t.deserializeCreateCollaborationRequestBodyItemField=F,t.serializeCreateCollaborationRequestBodyAccessibleByTypeField=M,t.deserializeCreateCollaborationRequestBodyAccessibleByTypeField=D,t.serializeCreateCollaborationRequestBodyAccessibleByField=R,t.deserializeCreateCollaborationRequestBodyAccessibleByField=P,t.serializeCreateCollaborationRequestBodyRoleField=O,t.deserializeCreateCollaborationRequestBodyRoleField=z,t.serializeCreateCollaborationRequestBody=N,t.deserializeCreateCollaborationRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateCollaborationRequestBody"'});if(null==e.item)throw new u.BoxSdkError({message:'Expecting "item" of type "CreateCollaborationRequestBody" to be defined'});const t=F(e.item);if(null==e.accessible_by)throw new u.BoxSdkError({message:'Expecting "accessible_by" of type "CreateCollaborationRequestBody" to be defined'});const r=P(e.accessible_by);if(null==e.role)throw new u.BoxSdkError({message:'Expecting "role" of type "CreateCollaborationRequestBody" to be defined'});const i=z(e.role);if(null!=e.is_access_only&&!(0,p.sdIsBoolean)(e.is_access_only))throw new u.BoxSdkError({message:'Expecting boolean for "is_access_only" of type "CreateCollaborationRequestBody"'});const n=null==e.is_access_only?void 0:e.is_access_only;if(null!=e.can_view_path&&!(0,p.sdIsBoolean)(e.can_view_path))throw new u.BoxSdkError({message:'Expecting boolean for "can_view_path" of type "CreateCollaborationRequestBody"'});const o=null==e.can_view_path?void 0:e.can_view_path;if(null!=e.expires_at&&!(0,h.sdIsString)(e.expires_at))throw new u.BoxSdkError({message:'Expecting string for "expires_at" of type "CreateCollaborationRequestBody"'});const a=null==e.expires_at?void 0:(0,s.deserializeDateTime)(e.expires_at);return{item:t,accessibleBy:r,role:i,isAccessOnly:n,canViewPath:o,expiresAt:a}};const n=r(10189),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.queryParams={},this.headers=new b({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetCollaborationByIdOptionals=m;class g{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateCollaborationByIdOptionals=g;class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteCollaborationByIdOptionals=y;class v{constructor(e){this.queryParams={},this.headers=new x({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateCollaborationOptionals=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetCollaborationByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateCollaborationByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteCollaborationByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateCollaborationHeaders=x;function S(e){return e}function k(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;if("owner"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateCollaborationByIdRequestBodyRoleField"})}function E(e){return e}function T(e){if("pending"==e)return e;if("accepted"==e)return e;if("rejected"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateCollaborationByIdRequestBodyStatusField"})}function B(e){return{role:e.role,status:null==e.status?void 0:e.status,expires_at:null==e.expiresAt?void 0:(0,o.serializeDateTime)(e.expiresAt),can_view_path:null==e.canViewPath?void 0:e.canViewPath}}function C(e){return e}function I(e){if("file"==e)return e;if("folder"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize CreateCollaborationRequestBodyItemTypeField"})}function A(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function F(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateCollaborationRequestBodyItemField"'});const t=null==e.type?void 0:I(e.type);if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CreateCollaborationRequestBodyItemField"'});return{type:t,id:null==e.id?void 0:e.id}}function M(e){return e}function D(e){if("user"==e)return e;if("group"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize CreateCollaborationRequestBodyAccessibleByTypeField"})}function R(e){return{type:e.type,id:null==e.id?void 0:e.id,login:null==e.login?void 0:e.login}}function P(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateCollaborationRequestBodyAccessibleByField"'});if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "CreateCollaborationRequestBodyAccessibleByField" to be defined'});const t=D(e.type);if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CreateCollaborationRequestBodyAccessibleByField"'});const r=null==e.id?void 0:e.id;if(null!=e.login&&!(0,h.sdIsString)(e.login))throw new u.BoxSdkError({message:'Expecting string for "login" of type "CreateCollaborationRequestBodyAccessibleByField"'});return{type:t,id:r,login:null==e.login?void 0:e.login}}function O(e){return e}function z(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize CreateCollaborationRequestBodyRoleField"})}function N(e){return{item:A(e.item),accessible_by:R(e.accessibleBy),role:e.role,is_access_only:null==e.isAccessOnly?void 0:e.isAccessOnly,can_view_path:null==e.canViewPath?void 0:e.canViewPath,expires_at:null==e.expiresAt?void 0:(0,o.serializeDateTime)(e.expiresAt)}}t.UserCollaborationsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getCollaborationById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)({fields:i.fields?i.fields.map(d.toString).join(","):void 0}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaborations/",(0,d.toString)(e)),method:"GET",params:a,headers:u,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeCollaboration)(p.data)),{rawData:p.data})}))}updateCollaborationById(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),o=i.headers,s=i.cancellationToken,a=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaborations/",(0,d.toString)(e)),method:"PUT",headers:a,data:B(t),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeCollaboration)(u.data)),{rawData:u.data})}))}deleteCollaborationById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaborations/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}createCollaboration(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,o=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)({fields:i.fields?i.fields.map(d.toString).join(","):void 0,notify:(0,d.toString)(i.notify)}),u=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),p=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/collaborations"),method:"POST",params:a,headers:u,data:N(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeCollaboration)(p.data)),{rawData:p.data})}))}}},70174:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.UsersManager=t.DeleteUserByIdHeaders=t.UpdateUserByIdHeaders=t.GetUserByIdHeaders=t.GetUserMeHeaders=t.CreateUserHeaders=t.GetUsersHeaders=t.DeleteUserByIdOptionals=t.UpdateUserByIdOptionals=t.GetUserByIdOptionals=t.CreateUserOptionals=void 0,t.serializeGetUsersQueryParamsUserTypeField=function(e){return e},t.deserializeGetUsersQueryParamsUserTypeField=function(e){if("all"==e)return e;if("managed"==e)return e;if("external"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize GetUsersQueryParamsUserTypeField"})},t.serializeCreateUserRequestBodyRoleField=C,t.deserializeCreateUserRequestBodyRoleField=I,t.serializeCreateUserRequestBodyStatusField=A,t.deserializeCreateUserRequestBodyStatusField=F,t.serializeCreateUserRequestBody=M,t.deserializeCreateUserRequestBody=function(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "CreateUserRequestBody"'});if(null==e.name)throw new p.BoxSdkError({message:'Expecting "name" of type "CreateUserRequestBody" to be defined'});if(!(0,m.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "CreateUserRequestBody"'});const t=e.name;if(null!=e.login&&!(0,m.sdIsString)(e.login))throw new p.BoxSdkError({message:'Expecting string for "login" of type "CreateUserRequestBody"'});const r=null==e.login?void 0:e.login;if(null!=e.is_platform_access_only&&!(0,h.sdIsBoolean)(e.is_platform_access_only))throw new p.BoxSdkError({message:'Expecting boolean for "is_platform_access_only" of type "CreateUserRequestBody"'});const i=null==e.is_platform_access_only?void 0:e.is_platform_access_only,n=null==e.role?void 0:I(e.role);if(null!=e.language&&!(0,m.sdIsString)(e.language))throw new p.BoxSdkError({message:'Expecting string for "language" of type "CreateUserRequestBody"'});const o=null==e.language?void 0:e.language;if(null!=e.is_sync_enabled&&!(0,h.sdIsBoolean)(e.is_sync_enabled))throw new p.BoxSdkError({message:'Expecting boolean for "is_sync_enabled" of type "CreateUserRequestBody"'});const s=null==e.is_sync_enabled?void 0:e.is_sync_enabled;if(null!=e.job_title&&!(0,m.sdIsString)(e.job_title))throw new p.BoxSdkError({message:'Expecting string for "job_title" of type "CreateUserRequestBody"'});const l=null==e.job_title?void 0:e.job_title;if(null!=e.phone&&!(0,m.sdIsString)(e.phone))throw new p.BoxSdkError({message:'Expecting string for "phone" of type "CreateUserRequestBody"'});const d=null==e.phone?void 0:e.phone;if(null!=e.address&&!(0,m.sdIsString)(e.address))throw new p.BoxSdkError({message:'Expecting string for "address" of type "CreateUserRequestBody"'});const c=null==e.address?void 0:e.address;if(null!=e.space_amount&&!(0,f.sdIsNumber)(e.space_amount))throw new p.BoxSdkError({message:'Expecting number for "space_amount" of type "CreateUserRequestBody"'});const u=null==e.space_amount?void 0:e.space_amount;if(null!=e.tracking_codes&&!(0,g.sdIsList)(e.tracking_codes))throw new p.BoxSdkError({message:'Expecting array for "tracking_codes" of type "CreateUserRequestBody"'});const v=null==e.tracking_codes?void 0:(0,g.sdIsList)(e.tracking_codes)?e.tracking_codes.map((function(e){return(0,a.deserializeTrackingCode)(e)})):[];if(null!=e.can_see_managed_users&&!(0,h.sdIsBoolean)(e.can_see_managed_users))throw new p.BoxSdkError({message:'Expecting boolean for "can_see_managed_users" of type "CreateUserRequestBody"'});const b=null==e.can_see_managed_users?void 0:e.can_see_managed_users;if(null!=e.timezone&&!(0,m.sdIsString)(e.timezone))throw new p.BoxSdkError({message:'Expecting string for "timezone" of type "CreateUserRequestBody"'});const w=null==e.timezone?void 0:e.timezone;if(null!=e.is_external_collab_restricted&&!(0,h.sdIsBoolean)(e.is_external_collab_restricted))throw new p.BoxSdkError({message:'Expecting boolean for "is_external_collab_restricted" of type "CreateUserRequestBody"'});const _=null==e.is_external_collab_restricted?void 0:e.is_external_collab_restricted;if(null!=e.is_exempt_from_device_limits&&!(0,h.sdIsBoolean)(e.is_exempt_from_device_limits))throw new p.BoxSdkError({message:'Expecting boolean for "is_exempt_from_device_limits" of type "CreateUserRequestBody"'});const x=null==e.is_exempt_from_device_limits?void 0:e.is_exempt_from_device_limits;if(null!=e.is_exempt_from_login_verification&&!(0,h.sdIsBoolean)(e.is_exempt_from_login_verification))throw new p.BoxSdkError({message:'Expecting boolean for "is_exempt_from_login_verification" of type "CreateUserRequestBody"'});const S=null==e.is_exempt_from_login_verification?void 0:e.is_exempt_from_login_verification,k=null==e.status?void 0:F(e.status);if(null!=e.external_app_user_id&&!(0,m.sdIsString)(e.external_app_user_id))throw new p.BoxSdkError({message:'Expecting string for "external_app_user_id" of type "CreateUserRequestBody"'});const E=null==e.external_app_user_id?void 0:e.external_app_user_id;return{name:t,login:r,isPlatformAccessOnly:i,role:n,language:o,isSyncEnabled:s,jobTitle:l,phone:d,address:c,spaceAmount:u,trackingCodes:v,canSeeManagedUsers:b,timezone:w,isExternalCollabRestricted:_,isExemptFromDeviceLimits:x,isExemptFromLoginVerification:S,status:k,externalAppUserId:E}},t.serializeUpdateUserByIdRequestBodyRoleField=D,t.deserializeUpdateUserByIdRequestBodyRoleField=R,t.serializeUpdateUserByIdRequestBodyStatusField=P,t.deserializeUpdateUserByIdRequestBodyStatusField=O,t.serializeUpdateUserByIdRequestBodyNotificationEmailField=z,t.deserializeUpdateUserByIdRequestBodyNotificationEmailField=N,t.serializeUpdateUserByIdRequestBody=q,t.deserializeUpdateUserByIdRequestBody=function(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateUserByIdRequestBody"'});if(null!=e.enterprise&&!(0,m.sdIsString)(e.enterprise))throw new p.BoxSdkError({message:'Expecting string for "enterprise" of type "UpdateUserByIdRequestBody"'});const t=null==e.enterprise?void 0:e.enterprise;if(null!=e.notify&&!(0,h.sdIsBoolean)(e.notify))throw new p.BoxSdkError({message:'Expecting boolean for "notify" of type "UpdateUserByIdRequestBody"'});const r=null==e.notify?void 0:e.notify;if(null!=e.name&&!(0,m.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "UpdateUserByIdRequestBody"'});const i=null==e.name?void 0:e.name;if(null!=e.login&&!(0,m.sdIsString)(e.login))throw new p.BoxSdkError({message:'Expecting string for "login" of type "UpdateUserByIdRequestBody"'});const n=null==e.login?void 0:e.login,o=null==e.role?void 0:R(e.role);if(null!=e.language&&!(0,m.sdIsString)(e.language))throw new p.BoxSdkError({message:'Expecting string for "language" of type "UpdateUserByIdRequestBody"'});const s=null==e.language?void 0:e.language;if(null!=e.is_sync_enabled&&!(0,h.sdIsBoolean)(e.is_sync_enabled))throw new p.BoxSdkError({message:'Expecting boolean for "is_sync_enabled" of type "UpdateUserByIdRequestBody"'});const l=null==e.is_sync_enabled?void 0:e.is_sync_enabled;if(null!=e.job_title&&!(0,m.sdIsString)(e.job_title))throw new p.BoxSdkError({message:'Expecting string for "job_title" of type "UpdateUserByIdRequestBody"'});const d=null==e.job_title?void 0:e.job_title;if(null!=e.phone&&!(0,m.sdIsString)(e.phone))throw new p.BoxSdkError({message:'Expecting string for "phone" of type "UpdateUserByIdRequestBody"'});const c=null==e.phone?void 0:e.phone;if(null!=e.address&&!(0,m.sdIsString)(e.address))throw new p.BoxSdkError({message:'Expecting string for "address" of type "UpdateUserByIdRequestBody"'});const u=null==e.address?void 0:e.address;if(null!=e.tracking_codes&&!(0,g.sdIsList)(e.tracking_codes))throw new p.BoxSdkError({message:'Expecting array for "tracking_codes" of type "UpdateUserByIdRequestBody"'});const v=null==e.tracking_codes?void 0:(0,g.sdIsList)(e.tracking_codes)?e.tracking_codes.map((function(e){return(0,a.deserializeTrackingCode)(e)})):[];if(null!=e.can_see_managed_users&&!(0,h.sdIsBoolean)(e.can_see_managed_users))throw new p.BoxSdkError({message:'Expecting boolean for "can_see_managed_users" of type "UpdateUserByIdRequestBody"'});const b=null==e.can_see_managed_users?void 0:e.can_see_managed_users;if(null!=e.timezone&&!(0,m.sdIsString)(e.timezone))throw new p.BoxSdkError({message:'Expecting string for "timezone" of type "UpdateUserByIdRequestBody"'});const w=null==e.timezone?void 0:e.timezone;if(null!=e.is_external_collab_restricted&&!(0,h.sdIsBoolean)(e.is_external_collab_restricted))throw new p.BoxSdkError({message:'Expecting boolean for "is_external_collab_restricted" of type "UpdateUserByIdRequestBody"'});const _=null==e.is_external_collab_restricted?void 0:e.is_external_collab_restricted;if(null!=e.is_exempt_from_device_limits&&!(0,h.sdIsBoolean)(e.is_exempt_from_device_limits))throw new p.BoxSdkError({message:'Expecting boolean for "is_exempt_from_device_limits" of type "UpdateUserByIdRequestBody"'});const x=null==e.is_exempt_from_device_limits?void 0:e.is_exempt_from_device_limits;if(null!=e.is_exempt_from_login_verification&&!(0,h.sdIsBoolean)(e.is_exempt_from_login_verification))throw new p.BoxSdkError({message:'Expecting boolean for "is_exempt_from_login_verification" of type "UpdateUserByIdRequestBody"'});const S=null==e.is_exempt_from_login_verification?void 0:e.is_exempt_from_login_verification;if(null!=e.is_password_reset_required&&!(0,h.sdIsBoolean)(e.is_password_reset_required))throw new p.BoxSdkError({message:'Expecting boolean for "is_password_reset_required" of type "UpdateUserByIdRequestBody"'});const k=null==e.is_password_reset_required?void 0:e.is_password_reset_required,E=null==e.status?void 0:O(e.status);if(null!=e.space_amount&&!(0,f.sdIsNumber)(e.space_amount))throw new p.BoxSdkError({message:'Expecting number for "space_amount" of type "UpdateUserByIdRequestBody"'});const T=null==e.space_amount?void 0:e.space_amount,B=null==e.notification_email?void 0:N(e.notification_email);if(null!=e.external_app_user_id&&!(0,m.sdIsString)(e.external_app_user_id))throw new p.BoxSdkError({message:'Expecting string for "external_app_user_id" of type "UpdateUserByIdRequestBody"'});const C=null==e.external_app_user_id?void 0:e.external_app_user_id;return{enterprise:t,notify:r,name:i,login:n,role:o,language:s,isSyncEnabled:l,jobTitle:d,phone:c,address:u,trackingCodes:v,canSeeManagedUsers:b,timezone:w,isExternalCollabRestricted:_,isExemptFromDeviceLimits:x,isExemptFromLoginVerification:S,isPasswordResetRequired:k,status:E,spaceAmount:T,notificationEmail:B,externalAppUserId:C}};const n=r(57076),o=r(88510),s=r(55852),a=r(55852),l=r(31210),d=r(93845),c=r(93845),u=r(84143),p=r(72631),h=r(50793),f=r(50793),m=r(50793),g=r(50793),y=r(50793);class v{constructor(e){this.queryParams={},this.headers=new S({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateUserOptionals=v;class b{constructor(e){this.queryParams={},this.headers=new E({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetUserByIdOptionals=b;class w{constructor(e){this.requestBody={},this.queryParams={},this.headers=new T({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateUserByIdOptionals=w;class _{constructor(e){this.queryParams={},this.headers=new B({}),this.cancellationToken=void 0,e.queryParams&&(this.queryParams=e.queryParams),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteUserByIdOptionals=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUsersHeaders=x;class S{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateUserHeaders=S;class k{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUserMeHeaders=k;class E{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetUserByIdHeaders=E;class T{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateUserByIdHeaders=T;class B{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteUserByIdHeaders=B;function C(e){return e}function I(e){if("coadmin"==e)return e;if("user"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateUserRequestBodyRoleField"})}function A(e){return e}function F(e){if("active"==e)return e;if("inactive"==e)return e;if("cannot_delete_edit"==e)return e;if("cannot_delete_edit_upload"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize CreateUserRequestBodyStatusField"})}function M(e){return{name:e.name,login:null==e.login?void 0:e.login,is_platform_access_only:null==e.isPlatformAccessOnly?void 0:e.isPlatformAccessOnly,role:null==e.role?void 0:e.role,language:null==e.language?void 0:e.language,is_sync_enabled:null==e.isSyncEnabled?void 0:e.isSyncEnabled,job_title:null==e.jobTitle?void 0:e.jobTitle,phone:null==e.phone?void 0:e.phone,address:null==e.address?void 0:e.address,space_amount:null==e.spaceAmount?void 0:e.spaceAmount,tracking_codes:null==e.trackingCodes?void 0:e.trackingCodes.map((function(e){return(0,s.serializeTrackingCode)(e)})),can_see_managed_users:null==e.canSeeManagedUsers?void 0:e.canSeeManagedUsers,timezone:null==e.timezone?void 0:e.timezone,is_external_collab_restricted:null==e.isExternalCollabRestricted?void 0:e.isExternalCollabRestricted,is_exempt_from_device_limits:null==e.isExemptFromDeviceLimits?void 0:e.isExemptFromDeviceLimits,is_exempt_from_login_verification:null==e.isExemptFromLoginVerification?void 0:e.isExemptFromLoginVerification,status:null==e.status?void 0:e.status,external_app_user_id:null==e.externalAppUserId?void 0:e.externalAppUserId}}function D(e){return e}function R(e){if("coadmin"==e)return e;if("user"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateUserByIdRequestBodyRoleField"})}function P(e){return e}function O(e){if("active"==e)return e;if("inactive"==e)return e;if("cannot_delete_edit"==e)return e;if("cannot_delete_edit_upload"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize UpdateUserByIdRequestBodyStatusField"})}function z(e){return{email:null==e.email?void 0:e.email}}function N(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "UpdateUserByIdRequestBodyNotificationEmailField"'});if(null!=e.email&&!(0,m.sdIsString)(e.email))throw new p.BoxSdkError({message:'Expecting string for "email" of type "UpdateUserByIdRequestBodyNotificationEmailField"'});return{email:null==e.email?void 0:e.email}}function q(e){return{enterprise:null==e.enterprise?void 0:e.enterprise,notify:null==e.notify?void 0:e.notify,name:null==e.name?void 0:e.name,login:null==e.login?void 0:e.login,role:null==e.role?void 0:e.role,language:null==e.language?void 0:e.language,is_sync_enabled:null==e.isSyncEnabled?void 0:e.isSyncEnabled,job_title:null==e.jobTitle?void 0:e.jobTitle,phone:null==e.phone?void 0:e.phone,address:null==e.address?void 0:e.address,tracking_codes:null==e.trackingCodes?void 0:e.trackingCodes.map((function(e){return(0,s.serializeTrackingCode)(e)})),can_see_managed_users:null==e.canSeeManagedUsers?void 0:e.canSeeManagedUsers,timezone:null==e.timezone?void 0:e.timezone,is_external_collab_restricted:null==e.isExternalCollabRestricted?void 0:e.isExternalCollabRestricted,is_exempt_from_device_limits:null==e.isExemptFromDeviceLimits?void 0:e.isExemptFromDeviceLimits,is_exempt_from_login_verification:null==e.isExemptFromLoginVerification?void 0:e.isExemptFromLoginVerification,is_password_reset_required:null==e.isPasswordResetRequired?void 0:e.isPasswordResetRequired,status:null==e.status?void 0:e.status,space_amount:null==e.spaceAmount?void 0:e.spaceAmount,notification_email:null==e.notificationEmail?void 0:z(e.notificationEmail),external_app_user_id:null==e.externalAppUserId?void 0:e.externalAppUserId}}t.UsersManager=class{constructor(e){this.networkSession=new l.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getUsers(){return i(this,arguments,void 0,(function*(e={},t=new x({}),r){const i=new x({extraHeaders:t.extraHeaders}),o=(0,d.prepareParams)({filter_term:(0,c.toString)(e.filterTerm),user_type:(0,c.toString)(e.userType),external_app_user_id:(0,c.toString)(e.externalAppUserId),fields:e.fields?e.fields.map(c.toString).join(","):void 0,offset:(0,c.toString)(e.offset),limit:(0,c.toString)(e.limit),usemarker:(0,c.toString)(e.usemarker),marker:(0,c.toString)(e.marker)}),s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeUsers)(a.data)),{rawData:a.data})}))}createUser(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new v({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0}),l=(0,d.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users"),method:"POST",params:a,headers:l,data:M(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeUserFull)(p.data)),{rawData:p.data})}))}getUserMe(){return i(this,arguments,void 0,(function*(e={},t=new k({}),r){const i=new k({extraHeaders:t.extraHeaders}),n=(0,d.prepareParams)({fields:e.fields?e.fields.map(c.toString).join(","):void 0}),s=(0,d.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/me"),method:"GET",params:n,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,o.deserializeUserFull)(a.data)),{rawData:a.data})}))}getUserById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new b({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,s=r.cancellationToken,a=(0,d.prepareParams)({fields:i.fields?i.fields.map(c.toString).join(","):void 0}),l=(0,d.prepareParams)(Object.assign({},n.extraHeaders)),p=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,c.toString)(e)),method:"GET",params:a,headers:l,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeUserFull)(p.data)),{rawData:p.data})}))}updateUserById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new w({requestBody:t.requestBody,queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.queryParams,s=r.headers,a=r.cancellationToken,l=(0,d.prepareParams)({fields:n.fields?n.fields.map(c.toString).join(","):void 0}),p=(0,d.prepareParams)(Object.assign({},s.extraHeaders)),h=yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,c.toString)(e)),method:"PUT",params:l,headers:p,data:q(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:a});return Object.assign(Object.assign({},(0,o.deserializeUserFull)(h.data)),{rawData:h.data})}))}deleteUserById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new _({queryParams:t.queryParams,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.queryParams,n=r.headers,o=r.cancellationToken,s=(0,d.prepareParams)({notify:(0,c.toString)(i.notify),force:(0,c.toString)(i.force)}),a=(0,d.prepareParams)(Object.assign({},n.extraHeaders));yield(0,u.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/users/",(0,c.toString)(e)),method:"DELETE",params:s,headers:a,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}}},71305:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.WebLinksManager=t.DeleteWebLinkByIdHeaders=t.UpdateWebLinkByIdHeaders=t.GetWebLinkByIdHeaders=t.CreateWebLinkHeaders=t.DeleteWebLinkByIdOptionals=t.UpdateWebLinkByIdOptionals=t.GetWebLinkByIdOptionals=t.CreateWebLinkOptionals=void 0,t.serializeCreateWebLinkRequestBodyParentField=x,t.deserializeCreateWebLinkRequestBodyParentField=S,t.serializeCreateWebLinkRequestBody=k,t.deserializeCreateWebLinkRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateWebLinkRequestBody"'});if(null==e.url)throw new u.BoxSdkError({message:'Expecting "url" of type "CreateWebLinkRequestBody" to be defined'});if(!(0,p.sdIsString)(e.url))throw new u.BoxSdkError({message:'Expecting string for "url" of type "CreateWebLinkRequestBody"'});const t=e.url;if(null==e.parent)throw new u.BoxSdkError({message:'Expecting "parent" of type "CreateWebLinkRequestBody" to be defined'});const r=S(e.parent);if(null!=e.name&&!(0,p.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "CreateWebLinkRequestBody"'});const i=null==e.name?void 0:e.name;if(null!=e.description&&!(0,p.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "CreateWebLinkRequestBody"'});const n=null==e.description?void 0:e.description;return{url:t,parent:r,name:i,description:n}},t.serializeUpdateWebLinkByIdRequestBodyParentField=E,t.deserializeUpdateWebLinkByIdRequestBodyParentField=T,t.serializeUpdateWebLinkByIdRequestBodySharedLinkAccessField=B,t.deserializeUpdateWebLinkByIdRequestBodySharedLinkAccessField=C,t.serializeUpdateWebLinkByIdRequestBodySharedLinkField=I,t.deserializeUpdateWebLinkByIdRequestBodySharedLinkField=A,t.serializeUpdateWebLinkByIdRequestBody=F,t.deserializeUpdateWebLinkByIdRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateWebLinkByIdRequestBody"'});if(null!=e.url&&!(0,p.sdIsString)(e.url))throw new u.BoxSdkError({message:'Expecting string for "url" of type "UpdateWebLinkByIdRequestBody"'});const t=null==e.url?void 0:e.url,r=null==e.parent?void 0:T(e.parent);if(null!=e.name&&!(0,p.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "UpdateWebLinkByIdRequestBody"'});const i=null==e.name?void 0:e.name;if(null!=e.description&&!(0,p.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "UpdateWebLinkByIdRequestBody"'});const n=null==e.description?void 0:e.description,o=null==e.shared_link?void 0:A(e.shared_link);return{url:t,parent:r,name:i,description:n,sharedLink:o}};const n=r(60238),o=r(93845),s=r(93845),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateWebLinkOptionals=f;class m{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetWebLinkByIdOptionals=m;class g{constructor(e){this.requestBody={},this.headers=new w({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateWebLinkByIdOptionals=g;class y{constructor(e){this.headers=new _({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteWebLinkByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateWebLinkHeaders=v;class b{constructor(e){this.extraHeaders={},e.boxapi&&(this.boxapi=e.boxapi),e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetWebLinkByIdHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateWebLinkByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteWebLinkByIdHeaders=_;function x(e){return{id:e.id}}function S(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "CreateWebLinkRequestBodyParentField"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "CreateWebLinkRequestBodyParentField" to be defined'});if(!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "CreateWebLinkRequestBodyParentField"'});return{id:e.id}}function k(e){return{url:e.url,parent:x(e.parent),name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description}}function E(e){return{id:null==e.id?void 0:e.id}}function T(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateWebLinkByIdRequestBodyParentField"'});if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UpdateWebLinkByIdRequestBodyParentField"'});return{id:null==e.id?void 0:e.id}}function B(e){return e}function C(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UpdateWebLinkByIdRequestBodySharedLinkAccessField"})}function I(e){return{access:null==e.access?void 0:e.access,password:null==e.password?void 0:e.password,vanity_name:null==e.vanityName?void 0:e.vanityName,unshared_at:null==e.unsharedAt?void 0:(0,o.serializeDateTime)(e.unsharedAt)}}function A(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UpdateWebLinkByIdRequestBodySharedLinkField"'});const t=null==e.access?void 0:C(e.access);if(null!=e.password&&!(0,p.sdIsString)(e.password))throw new u.BoxSdkError({message:'Expecting string for "password" of type "UpdateWebLinkByIdRequestBodySharedLinkField"'});const r=null==e.password?void 0:e.password;if(null!=e.vanity_name&&!(0,p.sdIsString)(e.vanity_name))throw new u.BoxSdkError({message:'Expecting string for "vanity_name" of type "UpdateWebLinkByIdRequestBodySharedLinkField"'});const i=null==e.vanity_name?void 0:e.vanity_name;if(null!=e.unshared_at&&!(0,p.sdIsString)(e.unshared_at))throw new u.BoxSdkError({message:'Expecting string for "unshared_at" of type "UpdateWebLinkByIdRequestBodySharedLinkField"'});return{access:t,password:r,vanityName:i,unsharedAt:null==e.unshared_at?void 0:(0,s.deserializeDateTime)(e.unshared_at)}}function F(e){return{url:null==e.url?void 0:e.url,parent:null==e.parent?void 0:E(e.parent),name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description,shared_link:null==e.sharedLink?void 0:I(e.sharedLink)}}t.WebLinksManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}createWebLink(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links"),method:"POST",headers:s,data:k(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(a.data)),{rawData:a.data})}))}getWebLinkById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)(Object.assign({boxapi:(0,d.toString)(i.boxapi)},i.extraHeaders)),a=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(a.data)),{rawData:a.data})}))}updateWebLinkById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,o=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)(Object.assign({},o.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e)),method:"PUT",headers:a,data:F(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeWebLink)(u.data)),{rawData:u.data})}))}deleteWebLinkById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/web_links/",(0,d.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},40656:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.WebhooksManager=t.DeleteWebhookByIdHeaders=t.UpdateWebhookByIdHeaders=t.GetWebhookByIdHeaders=t.CreateWebhookHeaders=t.GetWebhooksHeaders=t.DeleteWebhookByIdOptionals=t.UpdateWebhookByIdOptionals=t.GetWebhookByIdOptionals=t.CreateWebhookOptionals=void 0,t.serializeCreateWebhookRequestBodyTargetTypeField=S,t.deserializeCreateWebhookRequestBodyTargetTypeField=k,t.serializeCreateWebhookRequestBodyTargetField=E,t.deserializeCreateWebhookRequestBodyTargetField=T,t.serializeCreateWebhookRequestBodyTriggersField=B,t.deserializeCreateWebhookRequestBodyTriggersField=C,t.serializeCreateWebhookRequestBody=I,t.deserializeCreateWebhookRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateWebhookRequestBody"'});if(null==e.target)throw new c.BoxSdkError({message:'Expecting "target" of type "CreateWebhookRequestBody" to be defined'});const t=T(e.target);if(null==e.address)throw new c.BoxSdkError({message:'Expecting "address" of type "CreateWebhookRequestBody" to be defined'});if(!(0,u.sdIsString)(e.address))throw new c.BoxSdkError({message:'Expecting string for "address" of type "CreateWebhookRequestBody"'});const r=e.address;if(null==e.triggers)throw new c.BoxSdkError({message:'Expecting "triggers" of type "CreateWebhookRequestBody" to be defined'});if(!(0,p.sdIsList)(e.triggers))throw new c.BoxSdkError({message:'Expecting array for "triggers" of type "CreateWebhookRequestBody"'});const i=(0,p.sdIsList)(e.triggers)?e.triggers.map((function(e){return C(e)})):[];return{target:t,address:r,triggers:i}},t.serializeUpdateWebhookByIdRequestBodyTargetTypeField=A,t.deserializeUpdateWebhookByIdRequestBodyTargetTypeField=F,t.serializeUpdateWebhookByIdRequestBodyTargetField=M,t.deserializeUpdateWebhookByIdRequestBodyTargetField=D,t.serializeUpdateWebhookByIdRequestBodyTriggersField=R,t.deserializeUpdateWebhookByIdRequestBodyTriggersField=P,t.serializeUpdateWebhookByIdRequestBody=O,t.deserializeUpdateWebhookByIdRequestBody=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateWebhookByIdRequestBody"'});const t=null==e.target?void 0:D(e.target);if(null!=e.address&&!(0,u.sdIsString)(e.address))throw new c.BoxSdkError({message:'Expecting string for "address" of type "UpdateWebhookByIdRequestBody"'});const r=null==e.address?void 0:e.address;if(null!=e.triggers&&!(0,p.sdIsList)(e.triggers))throw new c.BoxSdkError({message:'Expecting array for "triggers" of type "UpdateWebhookByIdRequestBody"'});const i=null==e.triggers?void 0:(0,p.sdIsList)(e.triggers)?e.triggers.map((function(e){return P(e)})):[];return{target:t,address:r,triggers:i}};const n=r(70934),o=r(36257),s=r(31210),a=r(93845),l=r(93845),d=r(84143),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f{constructor(e){this.headers=new b({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateWebhookOptionals=f;class m{constructor(e){this.headers=new w({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetWebhookByIdOptionals=m;class g{constructor(e){this.requestBody={},this.headers=new _({}),this.cancellationToken=void 0,e.requestBody&&(this.requestBody=e.requestBody),e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.UpdateWebhookByIdOptionals=g;class y{constructor(e){this.headers=new x({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DeleteWebhookByIdOptionals=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetWebhooksHeaders=v;class b{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateWebhookHeaders=b;class w{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetWebhookByIdHeaders=w;class _{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.UpdateWebhookByIdHeaders=_;class x{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DeleteWebhookByIdHeaders=x;function S(e){return e}function k(e){if("file"==e)return e;if("folder"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateWebhookRequestBodyTargetTypeField"})}function E(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function T(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "CreateWebhookRequestBodyTargetField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "CreateWebhookRequestBodyTargetField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:k(e.type)}}function B(e){return e}function C(e){if("FILE.UPLOADED"==e)return e;if("FILE.PREVIEWED"==e)return e;if("FILE.DOWNLOADED"==e)return e;if("FILE.TRASHED"==e)return e;if("FILE.DELETED"==e)return e;if("FILE.RESTORED"==e)return e;if("FILE.COPIED"==e)return e;if("FILE.MOVED"==e)return e;if("FILE.LOCKED"==e)return e;if("FILE.UNLOCKED"==e)return e;if("FILE.RENAMED"==e)return e;if("COMMENT.CREATED"==e)return e;if("COMMENT.UPDATED"==e)return e;if("COMMENT.DELETED"==e)return e;if("TASK_ASSIGNMENT.CREATED"==e)return e;if("TASK_ASSIGNMENT.UPDATED"==e)return e;if("METADATA_INSTANCE.CREATED"==e)return e;if("METADATA_INSTANCE.UPDATED"==e)return e;if("METADATA_INSTANCE.DELETED"==e)return e;if("FOLDER.CREATED"==e)return e;if("FOLDER.RENAMED"==e)return e;if("FOLDER.DOWNLOADED"==e)return e;if("FOLDER.RESTORED"==e)return e;if("FOLDER.DELETED"==e)return e;if("FOLDER.COPIED"==e)return e;if("FOLDER.MOVED"==e)return e;if("FOLDER.TRASHED"==e)return e;if("WEBHOOK.DELETED"==e)return e;if("COLLABORATION.CREATED"==e)return e;if("COLLABORATION.ACCEPTED"==e)return e;if("COLLABORATION.REJECTED"==e)return e;if("COLLABORATION.REMOVED"==e)return e;if("COLLABORATION.UPDATED"==e)return e;if("SHARED_LINK.DELETED"==e)return e;if("SHARED_LINK.CREATED"==e)return e;if("SHARED_LINK.UPDATED"==e)return e;if("SIGN_REQUEST.COMPLETED"==e)return e;if("SIGN_REQUEST.DECLINED"==e)return e;if("SIGN_REQUEST.EXPIRED"==e)return e;if("SIGN_REQUEST.SIGNER_EMAIL_BOUNCED"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize CreateWebhookRequestBodyTriggersField"})}function I(e){return{target:E(e.target),address:e.address,triggers:e.triggers.map((function(e){return e}))}}function A(e){return e}function F(e){if("file"==e)return e;if("folder"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateWebhookByIdRequestBodyTargetTypeField"})}function M(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function D(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "UpdateWebhookByIdRequestBodyTargetField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "UpdateWebhookByIdRequestBodyTargetField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:F(e.type)}}function R(e){return e}function P(e){if("FILE.UPLOADED"==e)return e;if("FILE.PREVIEWED"==e)return e;if("FILE.DOWNLOADED"==e)return e;if("FILE.TRASHED"==e)return e;if("FILE.DELETED"==e)return e;if("FILE.RESTORED"==e)return e;if("FILE.COPIED"==e)return e;if("FILE.MOVED"==e)return e;if("FILE.LOCKED"==e)return e;if("FILE.UNLOCKED"==e)return e;if("FILE.RENAMED"==e)return e;if("COMMENT.CREATED"==e)return e;if("COMMENT.UPDATED"==e)return e;if("COMMENT.DELETED"==e)return e;if("TASK_ASSIGNMENT.CREATED"==e)return e;if("TASK_ASSIGNMENT.UPDATED"==e)return e;if("METADATA_INSTANCE.CREATED"==e)return e;if("METADATA_INSTANCE.UPDATED"==e)return e;if("METADATA_INSTANCE.DELETED"==e)return e;if("FOLDER.CREATED"==e)return e;if("FOLDER.RENAMED"==e)return e;if("FOLDER.DOWNLOADED"==e)return e;if("FOLDER.RESTORED"==e)return e;if("FOLDER.DELETED"==e)return e;if("FOLDER.COPIED"==e)return e;if("FOLDER.MOVED"==e)return e;if("FOLDER.TRASHED"==e)return e;if("WEBHOOK.DELETED"==e)return e;if("COLLABORATION.CREATED"==e)return e;if("COLLABORATION.ACCEPTED"==e)return e;if("COLLABORATION.REJECTED"==e)return e;if("COLLABORATION.REMOVED"==e)return e;if("COLLABORATION.UPDATED"==e)return e;if("SHARED_LINK.DELETED"==e)return e;if("SHARED_LINK.CREATED"==e)return e;if("SHARED_LINK.UPDATED"==e)return e;if("SIGN_REQUEST.COMPLETED"==e)return e;if("SIGN_REQUEST.DECLINED"==e)return e;if("SIGN_REQUEST.EXPIRED"==e)return e;if("SIGN_REQUEST.SIGNER_EMAIL_BOUNCED"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize UpdateWebhookByIdRequestBodyTriggersField"})}function O(e){return{target:null==e.target?void 0:M(e.target),address:null==e.address?void 0:e.address,triggers:null==e.triggers?void 0:e.triggers.map((function(e){return e}))}}t.WebhooksManager=class{constructor(e){this.networkSession=new s.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getWebhooks(){return i(this,arguments,void 0,(function*(e={},t=new v({}),r){const i=new v({extraHeaders:t.extraHeaders}),o=(0,a.prepareParams)({marker:(0,l.toString)(e.marker),limit:(0,l.toString)(e.limit)}),s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/webhooks"),method:"GET",params:o,headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:r});return Object.assign(Object.assign({},(0,n.deserializeWebhooks)(c.data)),{rawData:c.data})}))}createWebhook(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new f({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),l=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/webhooks"),method:"POST",headers:s,data:I(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeWebhook)(l.data)),{rawData:l.data})}))}getWebhookById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,s=(0,a.prepareParams)(Object.assign({},i.extraHeaders)),c=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/webhooks/",(0,l.toString)(e)),method:"GET",headers:s,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,o.deserializeWebhook)(c.data)),{rawData:c.data})}))}updateWebhookById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new g({requestBody:t.requestBody,headers:t.headers,cancellationToken:t.cancellationToken}),i=r.requestBody,n=r.headers,s=r.cancellationToken,c=(0,a.prepareParams)(Object.assign({},n.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/webhooks/",(0,l.toString)(e)),method:"PUT",headers:c,data:O(i),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,o.deserializeWebhook)(u.data)),{rawData:u.data})}))}deleteWebhookById(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new y({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,a.prepareParams)(Object.assign({},i.extraHeaders));yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/webhooks/",(0,l.toString)(e)),method:"DELETE",headers:o,responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:n})}))}}},16360:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.WorkflowsManager=t.StartWorkflowHeaders=t.GetWorkflowsHeaders=t.StartWorkflowOptionals=t.GetWorkflowsOptionals=void 0,t.serializeStartWorkflowRequestBodyTypeField=b,t.deserializeStartWorkflowRequestBodyTypeField=w,t.serializeStartWorkflowRequestBodyFlowField=_,t.deserializeStartWorkflowRequestBodyFlowField=x,t.serializeStartWorkflowRequestBodyFilesTypeField=S,t.deserializeStartWorkflowRequestBodyFilesTypeField=k,t.serializeStartWorkflowRequestBodyFilesField=E,t.deserializeStartWorkflowRequestBodyFilesField=T,t.serializeStartWorkflowRequestBodyFolderTypeField=B,t.deserializeStartWorkflowRequestBodyFolderTypeField=C,t.serializeStartWorkflowRequestBodyFolderField=I,t.deserializeStartWorkflowRequestBodyFolderField=A,t.serializeStartWorkflowRequestBody=F,t.deserializeStartWorkflowRequestBody=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "StartWorkflowRequestBody"'});const t=null==e.type?void 0:w(e.type);if(null==e.flow)throw new u.BoxSdkError({message:'Expecting "flow" of type "StartWorkflowRequestBody" to be defined'});const r=x(e.flow);if(null==e.files)throw new u.BoxSdkError({message:'Expecting "files" of type "StartWorkflowRequestBody" to be defined'});if(!(0,h.sdIsList)(e.files))throw new u.BoxSdkError({message:'Expecting array for "files" of type "StartWorkflowRequestBody"'});const i=(0,h.sdIsList)(e.files)?e.files.map((function(e){return T(e)})):[];if(null==e.folder)throw new u.BoxSdkError({message:'Expecting "folder" of type "StartWorkflowRequestBody" to be defined'});const n=A(e.folder);if(null!=e.outcomes&&!(0,h.sdIsList)(e.outcomes))throw new u.BoxSdkError({message:'Expecting array for "outcomes" of type "StartWorkflowRequestBody"'});const o=null==e.outcomes?void 0:(0,h.sdIsList)(e.outcomes)?e.outcomes.map((function(e){return(0,s.deserializeOutcome)(e)})):[];return{type:t,flow:r,files:i,folder:n,outcomes:o}};const n=r(70018),o=r(24704),s=r(24704),a=r(31210),l=r(93845),d=r(93845),c=r(84143),u=r(72631),p=r(50793),h=r(50793),f=r(50793);class m{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetWorkflowsOptionals=m;class g{constructor(e){this.headers=new v({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.StartWorkflowOptionals=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetWorkflowsHeaders=y;class v{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.StartWorkflowHeaders=v;function b(e){return e}function w(e){if("workflow_parameters"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize StartWorkflowRequestBodyTypeField"})}function _(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function x(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "StartWorkflowRequestBodyFlowField"'});if(null!=e.type&&!(0,p.sdIsString)(e.type))throw new u.BoxSdkError({message:'Expecting string for "type" of type "StartWorkflowRequestBodyFlowField"'});const t=null==e.type?void 0:e.type;if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "StartWorkflowRequestBodyFlowField"'});return{type:t,id:null==e.id?void 0:e.id}}function S(e){return e}function k(e){if("file"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize StartWorkflowRequestBodyFilesTypeField"})}function E(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function T(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "StartWorkflowRequestBodyFilesField"'});const t=null==e.type?void 0:k(e.type);if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "StartWorkflowRequestBodyFilesField"'});return{type:t,id:null==e.id?void 0:e.id}}function B(e){return e}function C(e){if("folder"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize StartWorkflowRequestBodyFolderTypeField"})}function I(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function A(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "StartWorkflowRequestBodyFolderField"'});const t=null==e.type?void 0:C(e.type);if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "StartWorkflowRequestBodyFolderField"'});return{type:t,id:null==e.id?void 0:e.id}}function F(e){return{type:null==e.type?void 0:e.type,flow:_(e.flow),files:e.files.map((function(e){return E(e)})),folder:I(e.folder),outcomes:null==e.outcomes?void 0:e.outcomes.map((function(e){return(0,o.serializeOutcome)(e)}))}}t.WorkflowsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}getWorkflows(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new m({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,o=r.cancellationToken,s=(0,l.prepareParams)({folder_id:(0,d.toString)(e.folderId),trigger_type:(0,d.toString)(e.triggerType),limit:(0,d.toString)(e.limit),marker:(0,d.toString)(e.marker)}),a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/workflows"),method:"GET",params:s,headers:a,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:o});return Object.assign(Object.assign({},(0,n.deserializeWorkflows)(u.data)),{rawData:u.data})}))}startWorkflow(e,t){return i(this,arguments,void 0,(function*(e,t,r={}){const i=new g({headers:r.headers,cancellationToken:r.cancellationToken}),n=i.headers,o=i.cancellationToken,s=(0,l.prepareParams)(Object.assign({},n.extraHeaders));yield(0,c.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/workflows/",(0,d.toString)(e),"/start"),method:"POST",headers:s,data:F(t),contentType:"application/json",responseFormat:void 0,auth:this.auth,networkSession:this.networkSession,cancellationToken:o})}))}}},54270:function(e,t,r){"use strict";var i=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0}),t.ZipDownloadsManager=t.DownloadZipHeaders=t.GetZipDownloadStatusHeaders=t.GetZipDownloadContentHeaders=t.CreateZipDownloadHeaders=t.DownloadZipOptionals=t.GetZipDownloadStatusOptionals=t.GetZipDownloadContentOptionals=t.CreateZipDownloadOptionals=void 0;const n=r(63055),o=r(37248),s=r(47237),a=r(31210),l=r(93845),d=r(84143);class c{constructor(e){this.headers=new f({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.CreateZipDownloadOptionals=c;class u{constructor(e){this.headers=new m({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetZipDownloadContentOptionals=u;class p{constructor(e){this.headers=new g({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.GetZipDownloadStatusOptionals=p;class h{constructor(e){this.headers=new y({}),this.cancellationToken=void 0,e.headers&&(this.headers=e.headers),e.cancellationToken&&(this.cancellationToken=e.cancellationToken)}}t.DownloadZipOptionals=h;class f{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.CreateZipDownloadHeaders=f;class m{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetZipDownloadContentHeaders=m;class g{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.GetZipDownloadStatusHeaders=g;class y{constructor(e){this.extraHeaders={},e.extraHeaders&&(this.extraHeaders=e.extraHeaders)}}t.DownloadZipHeaders=y;t.ZipDownloadsManager=class{constructor(e){this.networkSession=new a.NetworkSession({}),e.auth&&(this.auth=e.auth),e.networkSession&&(this.networkSession=e.networkSession)}createZipDownload(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new c({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,s=r.cancellationToken,a=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),u=yield(0,d.fetch)({url:"".concat(this.networkSession.baseUrls.baseUrl,"/2.0/zip_downloads"),method:"POST",headers:a,data:(0,o.serializeZipDownloadRequest)(e),contentType:"application/json",responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:s});return Object.assign(Object.assign({},(0,n.deserializeZipDownload)(u.data)),{rawData:u.data})}))}getZipDownloadContent(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new u({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders));return(yield(0,d.fetch)({url:e,method:"GET",headers:o,responseFormat:"binary",auth:this.auth,networkSession:this.networkSession,cancellationToken:n})).content}))}getZipDownloadStatus(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new p({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=(0,l.prepareParams)(Object.assign({},i.extraHeaders)),a=yield(0,d.fetch)({url:e,method:"GET",headers:o,responseFormat:"json",auth:this.auth,networkSession:this.networkSession,cancellationToken:n});return Object.assign(Object.assign({},(0,s.deserializeZipDownloadStatus)(a.data)),{rawData:a.data})}))}downloadZip(e){return i(this,arguments,void 0,(function*(e,t={}){const r=new h({headers:t.headers,cancellationToken:t.cancellationToken}),i=r.headers,n=r.cancellationToken,o=yield this.createZipDownload({items:e.items,downloadFileName:e.downloadFileName},{headers:new f({extraHeaders:i.extraHeaders}),cancellationToken:n});return yield this.getZipDownloadContent(o.downloadUrl,{headers:new m({extraHeaders:i.extraHeaders}),cancellationToken:n})}))}}},42575:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseUrls=void 0,t.serializeBaseUrls=function(e){return{base_url:e.baseUrl,upload_url:e.uploadUrl,oauth2_url:e.oauth2Url}},t.deserializeBaseUrls=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "BaseUrls"'});if(null==e.base_url)throw new i.BoxSdkError({message:'Expecting "base_url" of type "BaseUrls" to be defined'});if(!(0,n.sdIsString)(e.base_url))throw new i.BoxSdkError({message:'Expecting string for "base_url" of type "BaseUrls"'});const t=e.base_url;if(null==e.upload_url)throw new i.BoxSdkError({message:'Expecting "upload_url" of type "BaseUrls" to be defined'});if(!(0,n.sdIsString)(e.upload_url))throw new i.BoxSdkError({message:'Expecting string for "upload_url" of type "BaseUrls"'});const r=e.upload_url;if(null==e.oauth2_url)throw new i.BoxSdkError({message:'Expecting "oauth2_url" of type "BaseUrls" to be defined'});if(!(0,n.sdIsString)(e.oauth2_url))throw new i.BoxSdkError({message:'Expecting string for "oauth2_url" of type "BaseUrls"'});const a=e.oauth2_url;return new s({baseUrl:t,uploadUrl:r,oauth2Url:a})},t.serializeBaseUrlsInput=function(e){return{baseUrl:null==e.baseUrl?void 0:e.baseUrl,uploadUrl:null==e.uploadUrl?void 0:e.uploadUrl,oauth2Url:null==e.oauth2Url?void 0:e.oauth2Url}},t.deserializeBaseUrlsInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "BaseUrlsInput"'});if(null!=e.baseUrl&&!(0,n.sdIsString)(e.baseUrl))throw new i.BoxSdkError({message:'Expecting string for "baseUrl" of type "BaseUrlsInput"'});const t=null==e.baseUrl?void 0:e.baseUrl;if(null!=e.uploadUrl&&!(0,n.sdIsString)(e.uploadUrl))throw new i.BoxSdkError({message:'Expecting string for "uploadUrl" of type "BaseUrlsInput"'});const r=null==e.uploadUrl?void 0:e.uploadUrl;if(null!=e.oauth2Url&&!(0,n.sdIsString)(e.oauth2Url))throw new i.BoxSdkError({message:'Expecting string for "oauth2Url" of type "BaseUrlsInput"'});const s=null==e.oauth2Url?void 0:e.oauth2Url;return{baseUrl:t,uploadUrl:r,oauth2Url:s}};const i=r(72631),n=r(50793),o=r(50793);class s{constructor(e){this.baseUrl="https://api.box.com",this.uploadUrl="https://upload.box.com/api",this.oauth2Url="https://account.box.com/api/oauth2",e.baseUrl&&(this.baseUrl=e.baseUrl),e.uploadUrl&&(this.uploadUrl=e.uploadUrl),e.oauth2Url&&(this.oauth2Url=e.oauth2Url),e.rawData&&(this.rawData=e.rawData)}}t.BaseUrls=s},84143:function(__unused_webpack_module,exports,__webpack_require__){"use strict";var process=__webpack_require__(65606),__awaiter=this&&this.__awaiter||function(e,t,r,i){return new(r||(r=Promise))((function(n,o){function s(e){try{l(i.next(e))}catch(e){o(e)}}function a(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((i=i.apply(e,t||[])).next())}))},__importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(exports,"__esModule",{value:!0}),exports.xBoxUaHeader=exports.userAgentHeader=void 0,exports.fetch=fetch;const node_fetch_1=__importDefault(__webpack_require__(43092)),errors_1=__webpack_require__(72631),utils_1=__webpack_require__(93845),version_1=__webpack_require__(57171),json_1=__webpack_require__(50793),getRetryTimeout_1=__webpack_require__(83106);function createRequestInit(options){return __awaiter(this,void 0,void 0,(function*(){var _a,_b;const{method="GET",headers={},contentType:contentTypeInput="application/json",data,fileStream}=options,{contentType,body}=yield(()=>__awaiter(this,void 0,void 0,(function*(){var _a,_b;if(options.multipartData){const FormData=(0,utils_1.isBrowser)()?window.FormData:eval("require")("form-data"),formData=new FormData;for(const e of options.multipartData)if(e.fileStream){const t=yield(0,utils_1.readByteStream)(e.fileStream),r=(0,utils_1.isBrowser)()?new Blob([t]):t;headers["content-md5"]=yield calculateMD5Hash(t),formData.append(e.partName,r,{filename:null!==(_a=e.fileName)&&void 0!==_a?_a:"file",contentType:null!==(_b=e.contentType)&&void 0!==_b?_b:"application/octet-stream"})}else{if(!e.data)throw new errors_1.BoxSdkError({message:"Multipart item must have either body or fileStream"});formData.append(e.partName,(0,json_1.sdToJson)(e.data))}return{contentType:(0,utils_1.isBrowser)()?void 0:`multipart/form-data; boundary=${formData.getBoundary()}`,body:formData}}const contentType=contentTypeInput;switch(contentType){case"application/json":case"application/json-patch+json":return{contentType,body:(0,json_1.sdToJson)(data)};case"application/x-www-form-urlencoded":return{contentType,body:(0,json_1.sdToUrlParams)(data)};case"application/octet-stream":if(!fileStream)throw new errors_1.BoxSdkError({message:"fileStream required for application/octet-stream content type"});return{contentType,body:fileStream};default:throw new errors_1.BoxSdkError({message:`Unsupported content type : ${contentType}`})}})))();return{method,headers:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},contentType&&{"Content-Type":contentType}),headers),options.auth&&{Authorization:yield options.auth.retrieveAuthorizationHeader(options.networkSession)}),{"User-Agent":exports.userAgentHeader,"X-Box-UA":exports.xBoxUaHeader}),null===(_a=options.networkSession)||void 0===_a?void 0:_a.additionalHeaders),body,signal:options.cancellationToken,agent:null===(_b=options.networkSession)||void 0===_b?void 0:_b.agent}}))}exports.userAgentHeader=`Box JavaScript generated SDK v${version_1.sdkVersion} (${(0,utils_1.isBrowser)()?navigator.userAgent:`Node ${process.version}`})`,exports.xBoxUaHeader=constructBoxUAHeader();const DEFAULT_MAX_ATTEMPTS=5,RETRY_BASE_INTERVAL=1,STATUS_CODE_ACCEPTED=202,STATUS_CODE_UNAUTHORIZED=401,STATUS_CODE_TOO_MANY_REQUESTS=429;function fetch(e){return __awaiter(this,void 0,void 0,(function*(){var t,r,i,n,o,s,a,l;const d=(null===(r=null===(t=e.networkSession)||void 0===t?void 0:t.interceptors)||void 0===r?void 0:r.length)?null===(i=e.networkSession)||void 0===i?void 0:i.interceptors.reduce(((e,t)=>t.beforeRequest(e)),e):e,c=d.fileStream?yield(0,utils_1.readByteStream)(d.fileStream):void 0,u=yield createRequestInit(Object.assign(Object.assign({},d),{fileStream:c?(0,utils_1.generateByteStreamFromBuffer)(c):void 0})),{params:p={}}=d,h=yield(0,node_fetch_1.default)("".concat(d.url,0===Object.keys(p).length||d.url.endsWith("?")?"":"?",new URLSearchParams(p).toString()),Object.assign(Object.assign({},u),{redirect:"manual"})),f=null!==(n=h.headers.get("content-type"))&&void 0!==n?n:"",m=yield h.arrayBuffer(),g=(()=>{if(f.includes("application/json")){const e=(new TextDecoder).decode(m);return(0,json_1.jsonToSerializedData)(e)}})(),y=(0,utils_1.generateByteStreamFromBuffer)(m);let v={status:h.status,data:g,content:y,headers:Object.fromEntries(Array.from(h.headers.entries()))};if((null===(s=null===(o=d.networkSession)||void 0===o?void 0:o.interceptors)||void 0===s?void 0:s.length)&&(v=null===(a=d.networkSession)||void 0===a?void 0:a.interceptors.reduce(((e,t)=>t.afterRequest(e)),v)),v.status>=300&&v.status<400){if(!v.headers.location)throw new errors_1.BoxSdkError({message:`Unable to follow redirect for ${d.url}`});return fetch(Object.assign(Object.assign({},e),{url:v.headers.location}))}const b=v.status===STATUS_CODE_ACCEPTED&&v.headers["retry-after"];if(v.status>=400||b){const{numRetries:t=0}=d;if(v.status==STATUS_CODE_UNAUTHORIZED&&d.auth)return yield d.auth.refreshToken(d.networkSession),fetch(Object.assign(Object.assign({},e),{numRetries:t+1,fileStream:c?(0,utils_1.generateByteStreamFromBuffer)(c):void 0}));if("application/x-www-form-urlencoded"!==d.contentType&&(v.status===STATUS_CODE_TOO_MANY_REQUESTS||b||v.status>=500)&&tsetTimeout(e,r))),fetch(Object.assign(Object.assign({},e),{numRetries:t+1}))}const[r,i,n,o]=(0,json_1.sdIsMap)(v.data)?[(0,json_1.sdToJson)(v.data.code),(0,json_1.sdIsMap)(v.data.context_info)?v.data.context_info:void 0,(0,json_1.sdToJson)(v.data.request_id),(0,json_1.sdToJson)(v.data.help_url)]:[];throw new errors_1.BoxApiError({message:`${v.status}`,timestamp:`${Date.now()}`,requestInfo:{method:u.method,url:d.url,queryParams:p,headers:null!==(l=u.headers)&&void 0!==l?l:{},body:"string"==typeof u.body?u.body:void 0},responseInfo:{statusCode:v.status,headers:v.headers,body:v.data,rawBody:(new TextDecoder).decode(m),code:r,contextInfo:i,requestId:n,helpUrl:o},name:"BoxApiError"})}return v}))}function calculateMD5Hash(data){return __awaiter(this,void 0,void 0,(function*(){let createHash;if((0,utils_1.isBrowser)()){let e="string"==typeof data?(new TextEncoder).encode(data):data,t=yield window.crypto.subtle.digest("SHA-1",e),r=Array.from(new Uint8Array(t)),i=r.map((e=>e.toString(16).padStart(2,"0"))).join("");return i}return createHash=eval("require")("crypto").createHash,createHash("sha1").update(data).digest("hex")}))}function constructBoxUAHeader(){const e={agent:`box-javascript-generated-sdk/${version_1.sdkVersion}`,env:(0,utils_1.isBrowser)()?navigator.userAgent:`Node/${process.version.replace("v","")}`};return Object.keys(e).map((t=>`${t}=${e[t]}`)).join("; ")}},83106:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getRetryTimeout=function(e,t){var i=1-r,n=1+r,o=Math.random()*(n-i)+i,s=Math.pow(2,e-1);return Math.ceil(s*t*o)};const r=.5},31210:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NetworkSession=void 0;const i=r(42575),n=r(93845);class o{constructor(e){this.additionalHeaders={},this.baseUrls=new i.BaseUrls({}),this.interceptors=[],this.agent=(0,n.createAgent)(void 0,void 0),e.additionalHeaders&&(this.additionalHeaders=e.additionalHeaders),e.baseUrls&&(this.baseUrls=e.baseUrls),e.interceptors&&(this.interceptors=e.interceptors),e.agent&&(this.agent=e.agent),e.agentOptions&&(this.agentOptions=e.agentOptions),e.proxyConfig&&(this.proxyConfig=e.proxyConfig)}withAdditionalHeaders(e={}){return new o({additionalHeaders:Object.assign(Object.assign({},this.additionalHeaders),e),baseUrls:this.baseUrls,interceptors:this.interceptors,agent:this.agent,agentOptions:this.agentOptions,proxyConfig:this.proxyConfig})}withCustomBaseUrls(e){return new o({additionalHeaders:this.additionalHeaders,baseUrls:e,interceptors:this.interceptors,agent:this.agent,agentOptions:this.agentOptions,proxyConfig:this.proxyConfig})}withCustomAgentOptions(e){return new o({additionalHeaders:this.additionalHeaders,baseUrls:this.baseUrls,interceptors:this.interceptors,agent:(0,n.createAgent)(e,this.proxyConfig),agentOptions:this.agentOptions,proxyConfig:this.proxyConfig})}withInterceptors(e){return new o({additionalHeaders:this.additionalHeaders,baseUrls:this.baseUrls,interceptors:this.interceptors.concat(e),agent:this.agent,agentOptions:this.agentOptions,proxyConfig:this.proxyConfig})}withProxy(e){return new o({additionalHeaders:this.additionalHeaders,baseUrls:this.baseUrls,interceptors:this.interceptors,agent:(0,n.createAgent)(this.agentOptions,e),agentOptions:this.agentOptions,proxyConfig:e})}}t.NetworkSession=o},57171:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sdkVersion=void 0,t.sdkVersion="1.7.0"},28403:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAccessTokenTokenTypeField=c,t.deserializeAccessTokenTokenTypeField=u,t.serializeAccessTokenIssuedTokenTypeField=p,t.deserializeAccessTokenIssuedTokenTypeField=h,t.serializeAccessToken=function(e){return{access_token:null==e.accessToken?void 0:e.accessToken,expires_in:null==e.expiresIn?void 0:e.expiresIn,token_type:null==e.tokenType?void 0:e.tokenType,restricted_to:null==e.restrictedTo?void 0:e.restrictedTo.map((function(e){return(0,i.serializeFileOrFolderScope)(e)})),refresh_token:null==e.refreshToken?void 0:e.refreshToken,issued_token_type:null==e.issuedTokenType?void 0:e.issuedTokenType}},t.deserializeAccessToken=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AccessToken"'});if(null!=e.access_token&&!(0,a.sdIsString)(e.access_token))throw new o.BoxSdkError({message:'Expecting string for "access_token" of type "AccessToken"'});const t=null==e.access_token?void 0:e.access_token;if(null!=e.expires_in&&!(0,s.sdIsNumber)(e.expires_in))throw new o.BoxSdkError({message:'Expecting number for "expires_in" of type "AccessToken"'});const r=null==e.expires_in?void 0:e.expires_in,i=null==e.token_type?void 0:u(e.token_type);if(null!=e.restricted_to&&!(0,l.sdIsList)(e.restricted_to))throw new o.BoxSdkError({message:'Expecting array for "restricted_to" of type "AccessToken"'});const c=null==e.restricted_to?void 0:(0,l.sdIsList)(e.restricted_to)?e.restricted_to.map((function(e){return(0,n.deserializeFileOrFolderScope)(e)})):[];if(null!=e.refresh_token&&!(0,a.sdIsString)(e.refresh_token))throw new o.BoxSdkError({message:'Expecting string for "refresh_token" of type "AccessToken"'});const p=null==e.refresh_token?void 0:e.refresh_token,f=null==e.issued_token_type?void 0:h(e.issued_token_type);return{accessToken:t,expiresIn:r,tokenType:i,restrictedTo:c,refreshToken:p,issuedTokenType:f}};const i=r(77733),n=r(77733),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("bearer"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize AccessTokenTokenTypeField"})}function p(e){return e}function h(e){if("urn:ietf:params:oauth:token-type:access_token"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize AccessTokenIssuedTokenTypeField"})}},7440:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiAgentAsk=void 0,t.serializeAiAgentAskTypeField=d,t.deserializeAiAgentAskTypeField=c,t.serializeAiAgentAsk=function(e){return{type:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText),long_text_multi:null==e.longTextMulti?void 0:(0,i.serializeAiAgentLongTextTool)(e.longTextMulti),basic_text_multi:null==e.basicTextMulti?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicTextMulti)}},t.deserializeAiAgentAsk=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentAsk"'});if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AiAgentAsk" to be defined'});const t=c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text),o=null==e.long_text_multi?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text_multi),d=null==e.basic_text_multi?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text_multi);return{type:t,longText:r,basicText:i,longTextMulti:o,basicTextMulti:d}},t.serializeAiAgentAskInput=function(e){return{type:null==e.type?void 0:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText),long_text_multi:null==e.longTextMulti?void 0:(0,i.serializeAiAgentLongTextTool)(e.longTextMulti),basic_text_multi:null==e.basicTextMulti?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicTextMulti)}},t.deserializeAiAgentAskInput=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentAskInput"'});const t=null==e.type?void 0:c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text),o=null==e.long_text_multi?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text_multi),d=null==e.basic_text_multi?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text_multi);return{type:t,longText:r,basicText:i,longTextMulti:o,basicTextMulti:d}};const i=r(40140),n=r(40140),o=r(89766),s=r(89766),a=r(72631),l=r(50793);function d(e){return e}function c(e){if("ai_agent_ask"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AiAgentAskTypeField"})}t.AiAgentAsk=class{constructor(e){this.type="ai_agent_ask",e.type&&(this.type=e.type),e.longText&&(this.longText=e.longText),e.basicText&&(this.basicText=e.basicText),e.longTextMulti&&(this.longTextMulti=e.longTextMulti),e.basicTextMulti&&(this.basicTextMulti=e.basicTextMulti),e.rawData&&(this.rawData=e.rawData)}}},62180:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentAskOrAiAgentExtractOrAiAgentExtractStructuredOrAiAgentTextGen=function(e){if("ai_agent_ask"==e.type)return(0,i.serializeAiAgentAsk)(e);if("ai_agent_extract"==e.type)return(0,o.serializeAiAgentExtract)(e);if("ai_agent_extract_structured"==e.type)return(0,a.serializeAiAgentExtractStructured)(e);if("ai_agent_text_gen"==e.type)return(0,d.serializeAiAgentTextGen)(e);throw new u.BoxSdkError({message:"unknown type"})},t.deserializeAiAgentAskOrAiAgentExtractOrAiAgentExtractStructuredOrAiAgentTextGen=function(e){if(!(0,p.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "AiAgentAskOrAiAgentExtractOrAiAgentExtractStructuredOrAiAgentTextGen"'});if("ai_agent_ask"==e.type)return(0,n.deserializeAiAgentAsk)(e);if("ai_agent_extract"==e.type)return(0,s.deserializeAiAgentExtract)(e);if("ai_agent_extract_structured"==e.type)return(0,l.deserializeAiAgentExtractStructured)(e);if("ai_agent_text_gen"==e.type)return(0,c.deserializeAiAgentTextGen)(e);throw new u.BoxSdkError({message:"Can't deserialize AiAgentAskOrAiAgentExtractOrAiAgentExtractStructuredOrAiAgentTextGen"})};const i=r(7440),n=r(7440),o=r(26268),s=r(26268),a=r(383),l=r(383),d=r(96390),c=r(96390),u=r(72631),p=r(50793)},59089:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentBasicGenTool=function(e){const t=(0,o.serializeAiAgentLongTextToolTextGen)(e);if(!(0,d.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "AiAgentBasicGenTool"'});return Object.assign(Object.assign({},t),{content_template:null==e.contentTemplate?void 0:e.contentTemplate})},t.deserializeAiAgentBasicGenTool=function(e){if(!(0,d.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "AiAgentBasicGenTool"'});if(null!=e.content_template&&!(0,l.sdIsString)(e.content_template))throw new s.BoxSdkError({message:'Expecting string for "content_template" of type "AiAgentBasicGenTool"'});const t=null==e.content_template?void 0:e.content_template,r=null==e.embeddings?void 0:(0,n.deserializeAiAgentLongTextToolTextGenEmbeddingsField)(e.embeddings);if(null!=e.system_message&&!(0,l.sdIsString)(e.system_message))throw new s.BoxSdkError({message:'Expecting string for "system_message" of type "AiAgentBasicGenTool"'});const o=null==e.system_message?void 0:e.system_message;if(null!=e.prompt_template&&!(0,l.sdIsString)(e.prompt_template))throw new s.BoxSdkError({message:'Expecting string for "prompt_template" of type "AiAgentBasicGenTool"'});const c=null==e.prompt_template?void 0:e.prompt_template;if(null!=e.model&&!(0,l.sdIsString)(e.model))throw new s.BoxSdkError({message:'Expecting string for "model" of type "AiAgentBasicGenTool"'});const u=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,a.sdIsNumber)(e.num_tokens_for_completion))throw new s.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentBasicGenTool"'});const p=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,h=null==e.llm_endpoint_params?void 0:(0,i.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{contentTemplate:t,embeddings:r,systemMessage:o,promptTemplate:c,model:u,numTokensForCompletion:p,llmEndpointParams:h}};const i=r(52852),n=r(97839),o=r(97839),s=r(72631),a=r(50793),l=r(50793),d=r(50793)},89766:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentBasicTextTool=function(e){const t=(0,n.serializeAiAgentBasicTextToolBase)(e);if(!(0,l.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentBasicTextTool"'});return Object.assign(Object.assign({},t),{system_message:null==e.systemMessage?void 0:e.systemMessage,prompt_template:null==e.promptTemplate?void 0:e.promptTemplate})},t.deserializeAiAgentBasicTextTool=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentBasicTextTool"'});if(null!=e.system_message&&!(0,a.sdIsString)(e.system_message))throw new o.BoxSdkError({message:'Expecting string for "system_message" of type "AiAgentBasicTextTool"'});const t=null==e.system_message?void 0:e.system_message;if(null!=e.prompt_template&&!(0,a.sdIsString)(e.prompt_template))throw new o.BoxSdkError({message:'Expecting string for "prompt_template" of type "AiAgentBasicTextTool"'});const r=null==e.prompt_template?void 0:e.prompt_template;if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentBasicTextTool"'});const n=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,s.sdIsNumber)(e.num_tokens_for_completion))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentBasicTextTool"'});const d=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,c=null==e.llm_endpoint_params?void 0:(0,i.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{systemMessage:t,promptTemplate:r,model:n,numTokensForCompletion:d,llmEndpointParams:c}};const i=r(52852),n=r(20415),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},20415:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentBasicTextToolBase=function(e){return{model:null==e.model?void 0:e.model,num_tokens_for_completion:null==e.numTokensForCompletion?void 0:e.numTokensForCompletion,llm_endpoint_params:null==e.llmEndpointParams?void 0:(0,i.serializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llmEndpointParams)}},t.deserializeAiAgentBasicTextToolBase=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentBasicTextToolBase"'});if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentBasicTextToolBase"'});const t=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,s.sdIsNumber)(e.num_tokens_for_completion))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentBasicTextToolBase"'});const r=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,i=null==e.llm_endpoint_params?void 0:(0,n.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{model:t,numTokensForCompletion:r,llmEndpointParams:i}};const i=r(52852),n=r(52852),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},79565:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentBasicTextToolTextGen=function(e){const t=(0,n.serializeAiAgentBasicTextToolBase)(e);if(!(0,l.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentBasicTextToolTextGen"'});return Object.assign(Object.assign({},t),{system_message:null==e.systemMessage?void 0:e.systemMessage,prompt_template:null==e.promptTemplate?void 0:e.promptTemplate})},t.deserializeAiAgentBasicTextToolTextGen=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentBasicTextToolTextGen"'});if(null!=e.system_message&&!(0,a.sdIsString)(e.system_message))throw new o.BoxSdkError({message:'Expecting string for "system_message" of type "AiAgentBasicTextToolTextGen"'});const t=null==e.system_message?void 0:e.system_message;if(null!=e.prompt_template&&!(0,a.sdIsString)(e.prompt_template))throw new o.BoxSdkError({message:'Expecting string for "prompt_template" of type "AiAgentBasicTextToolTextGen"'});const r=null==e.prompt_template?void 0:e.prompt_template;if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentBasicTextToolTextGen"'});const n=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,s.sdIsNumber)(e.num_tokens_for_completion))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentBasicTextToolTextGen"'});const d=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,c=null==e.llm_endpoint_params?void 0:(0,i.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{systemMessage:t,promptTemplate:r,model:n,numTokensForCompletion:d,llmEndpointParams:c}};const i=r(52852),n=r(20415),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},26268:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiAgentExtract=void 0,t.serializeAiAgentExtractTypeField=d,t.deserializeAiAgentExtractTypeField=c,t.serializeAiAgentExtract=function(e){return{type:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText)}},t.deserializeAiAgentExtract=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentExtract"'});if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AiAgentExtract" to be defined'});const t=c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text);return{type:t,longText:r,basicText:i}},t.serializeAiAgentExtractInput=function(e){return{type:null==e.type?void 0:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText)}},t.deserializeAiAgentExtractInput=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentExtractInput"'});const t=null==e.type?void 0:c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text);return{type:t,longText:r,basicText:i}};const i=r(40140),n=r(40140),o=r(89766),s=r(89766),a=r(72631),l=r(50793);function d(e){return e}function c(e){if("ai_agent_extract"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AiAgentExtractTypeField"})}t.AiAgentExtract=class{constructor(e){this.type="ai_agent_extract",e.type&&(this.type=e.type),e.longText&&(this.longText=e.longText),e.basicText&&(this.basicText=e.basicText),e.rawData&&(this.rawData=e.rawData)}}},383:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiAgentExtractStructured=void 0,t.serializeAiAgentExtractStructuredTypeField=d,t.deserializeAiAgentExtractStructuredTypeField=c,t.serializeAiAgentExtractStructured=function(e){return{type:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText)}},t.deserializeAiAgentExtractStructured=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentExtractStructured"'});if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AiAgentExtractStructured" to be defined'});const t=c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text);return{type:t,longText:r,basicText:i}},t.serializeAiAgentExtractStructuredInput=function(e){return{type:null==e.type?void 0:e.type,long_text:null==e.longText?void 0:(0,i.serializeAiAgentLongTextTool)(e.longText),basic_text:null==e.basicText?void 0:(0,o.serializeAiAgentBasicTextTool)(e.basicText)}},t.deserializeAiAgentExtractStructuredInput=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiAgentExtractStructuredInput"'});const t=null==e.type?void 0:c(e.type),r=null==e.long_text?void 0:(0,n.deserializeAiAgentLongTextTool)(e.long_text),i=null==e.basic_text?void 0:(0,s.deserializeAiAgentBasicTextTool)(e.basic_text);return{type:t,longText:r,basicText:i}};const i=r(40140),n=r(40140),o=r(89766),s=r(89766),a=r(72631),l=r(50793);function d(e){return e}function c(e){if("ai_agent_extract_structured"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AiAgentExtractStructuredTypeField"})}t.AiAgentExtractStructured=class{constructor(e){this.type="ai_agent_extract_structured",e.type&&(this.type=e.type),e.longText&&(this.longText=e.longText),e.basicText&&(this.basicText=e.basicText),e.rawData&&(this.rawData=e.rawData)}}},40140:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentLongTextToolEmbeddingsStrategyField=d,t.deserializeAiAgentLongTextToolEmbeddingsStrategyField=c,t.serializeAiAgentLongTextToolEmbeddingsField=u,t.deserializeAiAgentLongTextToolEmbeddingsField=p,t.serializeAiAgentLongTextTool=function(e){const t=(0,n.serializeAiAgentBasicTextTool)(e);if(!(0,l.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextTool"'});return Object.assign(Object.assign({},t),{embeddings:null==e.embeddings?void 0:u(e.embeddings)})},t.deserializeAiAgentLongTextTool=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextTool"'});const t=null==e.embeddings?void 0:p(e.embeddings);if(null!=e.system_message&&!(0,a.sdIsString)(e.system_message))throw new o.BoxSdkError({message:'Expecting string for "system_message" of type "AiAgentLongTextTool"'});const r=null==e.system_message?void 0:e.system_message;if(null!=e.prompt_template&&!(0,a.sdIsString)(e.prompt_template))throw new o.BoxSdkError({message:'Expecting string for "prompt_template" of type "AiAgentLongTextTool"'});const n=null==e.prompt_template?void 0:e.prompt_template;if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentLongTextTool"'});const d=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,s.sdIsNumber)(e.num_tokens_for_completion))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentLongTextTool"'});const c=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,u=null==e.llm_endpoint_params?void 0:(0,i.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{embeddings:t,systemMessage:r,promptTemplate:n,model:d,numTokensForCompletion:c,llmEndpointParams:u}};const i=r(52852),n=r(89766),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return{id:null==e.id?void 0:e.id,num_tokens_per_chunk:null==e.numTokensPerChunk?void 0:e.numTokensPerChunk}}function c(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolEmbeddingsStrategyField"'});if(null!=e.id&&!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "AiAgentLongTextToolEmbeddingsStrategyField"'});const t=null==e.id?void 0:e.id;if(null!=e.num_tokens_per_chunk&&!(0,s.sdIsNumber)(e.num_tokens_per_chunk))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_per_chunk" of type "AiAgentLongTextToolEmbeddingsStrategyField"'});return{id:t,numTokensPerChunk:null==e.num_tokens_per_chunk?void 0:e.num_tokens_per_chunk}}function u(e){return{model:null==e.model?void 0:e.model,strategy:null==e.strategy?void 0:d(e.strategy)}}function p(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolEmbeddingsField"'});if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentLongTextToolEmbeddingsField"'});return{model:null==e.model?void 0:e.model,strategy:null==e.strategy?void 0:c(e.strategy)}}},97839:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAgentLongTextToolTextGenEmbeddingsStrategyField=d,t.deserializeAiAgentLongTextToolTextGenEmbeddingsStrategyField=c,t.serializeAiAgentLongTextToolTextGenEmbeddingsField=u,t.deserializeAiAgentLongTextToolTextGenEmbeddingsField=p,t.serializeAiAgentLongTextToolTextGen=function(e){const t=(0,n.serializeAiAgentBasicTextToolTextGen)(e);if(!(0,l.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolTextGen"'});return Object.assign(Object.assign({},t),{embeddings:null==e.embeddings?void 0:u(e.embeddings)})},t.deserializeAiAgentLongTextToolTextGen=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolTextGen"'});const t=null==e.embeddings?void 0:p(e.embeddings);if(null!=e.system_message&&!(0,a.sdIsString)(e.system_message))throw new o.BoxSdkError({message:'Expecting string for "system_message" of type "AiAgentLongTextToolTextGen"'});const r=null==e.system_message?void 0:e.system_message;if(null!=e.prompt_template&&!(0,a.sdIsString)(e.prompt_template))throw new o.BoxSdkError({message:'Expecting string for "prompt_template" of type "AiAgentLongTextToolTextGen"'});const n=null==e.prompt_template?void 0:e.prompt_template;if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentLongTextToolTextGen"'});const d=null==e.model?void 0:e.model;if(null!=e.num_tokens_for_completion&&!(0,s.sdIsNumber)(e.num_tokens_for_completion))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_for_completion" of type "AiAgentLongTextToolTextGen"'});const c=null==e.num_tokens_for_completion?void 0:e.num_tokens_for_completion,u=null==e.llm_endpoint_params?void 0:(0,i.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi)(e.llm_endpoint_params);return{embeddings:t,systemMessage:r,promptTemplate:n,model:d,numTokensForCompletion:c,llmEndpointParams:u}};const i=r(52852),n=r(79565),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return{id:null==e.id?void 0:e.id,num_tokens_per_chunk:null==e.numTokensPerChunk?void 0:e.numTokensPerChunk}}function c(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolTextGenEmbeddingsStrategyField"'});if(null!=e.id&&!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "AiAgentLongTextToolTextGenEmbeddingsStrategyField"'});const t=null==e.id?void 0:e.id;if(null!=e.num_tokens_per_chunk&&!(0,s.sdIsNumber)(e.num_tokens_per_chunk))throw new o.BoxSdkError({message:'Expecting number for "num_tokens_per_chunk" of type "AiAgentLongTextToolTextGenEmbeddingsStrategyField"'});return{id:t,numTokensPerChunk:null==e.num_tokens_per_chunk?void 0:e.num_tokens_per_chunk}}function u(e){return{model:null==e.model?void 0:e.model,strategy:null==e.strategy?void 0:d(e.strategy)}}function p(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentLongTextToolTextGenEmbeddingsField"'});if(null!=e.model&&!(0,a.sdIsString)(e.model))throw new o.BoxSdkError({message:'Expecting string for "model" of type "AiAgentLongTextToolTextGenEmbeddingsField"'});return{model:null==e.model?void 0:e.model,strategy:null==e.strategy?void 0:c(e.strategy)}}},96390:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiAgentTextGen=void 0,t.serializeAiAgentTextGenTypeField=a,t.deserializeAiAgentTextGenTypeField=l,t.serializeAiAgentTextGen=function(e){return{type:e.type,basic_gen:null==e.basicGen?void 0:(0,i.serializeAiAgentBasicGenTool)(e.basicGen)}},t.deserializeAiAgentTextGen=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentTextGen"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "AiAgentTextGen" to be defined'});const t=l(e.type),r=null==e.basic_gen?void 0:(0,n.deserializeAiAgentBasicGenTool)(e.basic_gen);return{type:t,basicGen:r}},t.serializeAiAgentTextGenInput=function(e){return{type:null==e.type?void 0:e.type,basic_gen:null==e.basicGen?void 0:(0,i.serializeAiAgentBasicGenTool)(e.basicGen)}},t.deserializeAiAgentTextGenInput=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiAgentTextGenInput"'});const t=null==e.type?void 0:l(e.type),r=null==e.basic_gen?void 0:(0,n.deserializeAiAgentBasicGenTool)(e.basic_gen);return{type:t,basicGen:r}};const i=r(59089),n=r(59089),o=r(72631),s=r(50793);function a(e){return e}function l(e){if("ai_agent_text_gen"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize AiAgentTextGenTypeField"})}t.AiAgentTextGen=class{constructor(e){this.type="ai_agent_text_gen",e.type&&(this.type=e.type),e.basicGen&&(this.basicGen=e.basicGen),e.rawData&&(this.rawData=e.rawData)}}},90791:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiAskModeField=f,t.deserializeAiAskModeField=m,t.serializeAiAsk=function(e){return{mode:e.mode,prompt:e.prompt,items:e.items.map((function(e){return(0,i.serializeAiItemBase)(e)})),dialogue_history:null==e.dialogueHistory?void 0:e.dialogueHistory.map((function(e){return(0,o.serializeAiDialogueHistory)(e)})),include_citations:null==e.includeCitations?void 0:e.includeCitations,ai_agent:null==e.aiAgent?void 0:(0,a.serializeAiAgentAsk)(e.aiAgent)}},t.deserializeAiAsk=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "AiAsk"'});if(null==e.mode)throw new d.BoxSdkError({message:'Expecting "mode" of type "AiAsk" to be defined'});const t=m(e.mode);if(null==e.prompt)throw new d.BoxSdkError({message:'Expecting "prompt" of type "AiAsk" to be defined'});if(!(0,u.sdIsString)(e.prompt))throw new d.BoxSdkError({message:'Expecting string for "prompt" of type "AiAsk"'});const r=e.prompt;if(null==e.items)throw new d.BoxSdkError({message:'Expecting "items" of type "AiAsk" to be defined'});if(!(0,p.sdIsList)(e.items))throw new d.BoxSdkError({message:'Expecting array for "items" of type "AiAsk"'});const i=(0,p.sdIsList)(e.items)?e.items.map((function(e){return(0,n.deserializeAiItemBase)(e)})):[];if(null!=e.dialogue_history&&!(0,p.sdIsList)(e.dialogue_history))throw new d.BoxSdkError({message:'Expecting array for "dialogue_history" of type "AiAsk"'});const o=null==e.dialogue_history?void 0:(0,p.sdIsList)(e.dialogue_history)?e.dialogue_history.map((function(e){return(0,s.deserializeAiDialogueHistory)(e)})):[];if(null!=e.include_citations&&!(0,c.sdIsBoolean)(e.include_citations))throw new d.BoxSdkError({message:'Expecting boolean for "include_citations" of type "AiAsk"'});const a=null==e.include_citations?void 0:e.include_citations,f=null==e.ai_agent?void 0:(0,l.deserializeAiAgentAsk)(e.ai_agent);return{mode:t,prompt:r,items:i,dialogueHistory:o,includeCitations:a,aiAgent:f}};const i=r(90948),n=r(90948),o=r(70936),s=r(70936),a=r(7440),l=r(7440),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("multiple_item_qa"==e)return e;if("single_item_qa"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize AiAskModeField"})}},28655:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiCitationTypeField=s,t.deserializeAiCitationTypeField=a,t.serializeAiCitation=function(e){return{content:null==e.content?void 0:e.content,id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}},t.deserializeAiCitation=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiCitation"'});if(null!=e.content&&!(0,n.sdIsString)(e.content))throw new i.BoxSdkError({message:'Expecting string for "content" of type "AiCitation"'});const t=null==e.content?void 0:e.content;if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "AiCitation"'});const r=null==e.id?void 0:e.id,s=null==e.type?void 0:a(e.type);if(null!=e.name&&!(0,n.sdIsString)(e.name))throw new i.BoxSdkError({message:'Expecting string for "name" of type "AiCitation"'});const l=null==e.name?void 0:e.name;return{content:t,id:r,type:s,name:l}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("file"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize AiCitationTypeField"})}},70936:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiDialogueHistory=function(e){return{prompt:null==e.prompt?void 0:e.prompt,answer:null==e.answer?void 0:e.answer,created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt)}},t.deserializeAiDialogueHistory=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiDialogueHistory"'});if(null!=e.prompt&&!(0,s.sdIsString)(e.prompt))throw new o.BoxSdkError({message:'Expecting string for "prompt" of type "AiDialogueHistory"'});const t=null==e.prompt?void 0:e.prompt;if(null!=e.answer&&!(0,s.sdIsString)(e.answer))throw new o.BoxSdkError({message:'Expecting string for "answer" of type "AiDialogueHistory"'});const r=null==e.answer?void 0:e.answer;if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "AiDialogueHistory"'});const i=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);return{prompt:t,answer:r,createdAt:i}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793)},62519:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiExtract=function(e){return{prompt:e.prompt,items:e.items.map((function(e){return(0,i.serializeAiItemBase)(e)})),ai_agent:null==e.aiAgent?void 0:(0,o.serializeAiAgentExtract)(e.aiAgent)}},t.deserializeAiExtract=function(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiExtract"'});if(null==e.prompt)throw new a.BoxSdkError({message:'Expecting "prompt" of type "AiExtract" to be defined'});if(!(0,l.sdIsString)(e.prompt))throw new a.BoxSdkError({message:'Expecting string for "prompt" of type "AiExtract"'});const t=e.prompt;if(null==e.items)throw new a.BoxSdkError({message:'Expecting "items" of type "AiExtract" to be defined'});if(!(0,d.sdIsList)(e.items))throw new a.BoxSdkError({message:'Expecting array for "items" of type "AiExtract"'});const r=(0,d.sdIsList)(e.items)?e.items.map((function(e){return(0,n.deserializeAiItemBase)(e)})):[],i=null==e.ai_agent?void 0:(0,s.deserializeAiAgentExtract)(e.ai_agent);return{prompt:t,items:r,aiAgent:i}};const i=r(90948),n=r(90948),o=r(26268),s=r(26268),a=r(72631),l=r(50793),d=r(50793),c=r(50793)},84948:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiExtractResponse=function(e){return{}},t.deserializeAiExtractResponse=function(e){if(!(0,n.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiExtractResponse"'});return{}};const i=r(72631),n=r(50793)},65888:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiExtractStructuredMetadataTemplateTypeField=u,t.deserializeAiExtractStructuredMetadataTemplateTypeField=p,t.serializeAiExtractStructuredMetadataTemplateField=h,t.deserializeAiExtractStructuredMetadataTemplateField=f,t.serializeAiExtractStructuredFieldsOptionsField=m,t.deserializeAiExtractStructuredFieldsOptionsField=g,t.serializeAiExtractStructuredFieldsField=y,t.deserializeAiExtractStructuredFieldsField=v,t.serializeAiExtractStructured=function(e){return{items:e.items.map((function(e){return(0,i.serializeAiItemBase)(e)})),metadata_template:null==e.metadataTemplate?void 0:h(e.metadataTemplate),fields:null==e.fields?void 0:e.fields.map((function(e){return y(e)})),ai_agent:null==e.aiAgent?void 0:(0,o.serializeAiAgentExtractStructured)(e.aiAgent)}},t.deserializeAiExtractStructured=function(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiExtractStructured"'});if(null==e.items)throw new a.BoxSdkError({message:'Expecting "items" of type "AiExtractStructured" to be defined'});if(!(0,d.sdIsList)(e.items))throw new a.BoxSdkError({message:'Expecting array for "items" of type "AiExtractStructured"'});const t=(0,d.sdIsList)(e.items)?e.items.map((function(e){return(0,n.deserializeAiItemBase)(e)})):[],r=null==e.metadata_template?void 0:f(e.metadata_template);if(null!=e.fields&&!(0,d.sdIsList)(e.fields))throw new a.BoxSdkError({message:'Expecting array for "fields" of type "AiExtractStructured"'});const i=null==e.fields?void 0:(0,d.sdIsList)(e.fields)?e.fields.map((function(e){return v(e)})):[],o=null==e.ai_agent?void 0:(0,s.deserializeAiAgentExtractStructured)(e.ai_agent);return{items:t,metadataTemplate:r,fields:i,aiAgent:o}};const i=r(90948),n=r(90948),o=r(383),s=r(383),a=r(72631),l=r(50793),d=r(50793),c=r(50793);function u(e){return e}function p(e){if("metadata_template"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AiExtractStructuredMetadataTemplateTypeField"})}function h(e){return{template_key:null==e.templateKey?void 0:e.templateKey,type:null==e.type?void 0:e.type,scope:null==e.scope?void 0:e.scope}}function f(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiExtractStructuredMetadataTemplateField"'});if(null!=e.template_key&&!(0,l.sdIsString)(e.template_key))throw new a.BoxSdkError({message:'Expecting string for "template_key" of type "AiExtractStructuredMetadataTemplateField"'});const t=null==e.template_key?void 0:e.template_key,r=null==e.type?void 0:p(e.type);if(null!=e.scope&&!(0,l.sdIsString)(e.scope))throw new a.BoxSdkError({message:'Expecting string for "scope" of type "AiExtractStructuredMetadataTemplateField"'});return{templateKey:t,type:r,scope:null==e.scope?void 0:e.scope}}function m(e){return{key:e.key}}function g(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiExtractStructuredFieldsOptionsField"'});if(null==e.key)throw new a.BoxSdkError({message:'Expecting "key" of type "AiExtractStructuredFieldsOptionsField" to be defined'});if(!(0,l.sdIsString)(e.key))throw new a.BoxSdkError({message:'Expecting string for "key" of type "AiExtractStructuredFieldsOptionsField"'});return{key:e.key}}function y(e){return{key:e.key,description:null==e.description?void 0:e.description,displayName:null==e.displayName?void 0:e.displayName,prompt:null==e.prompt?void 0:e.prompt,type:null==e.type?void 0:e.type,options:null==e.options?void 0:e.options.map((function(e){return m(e)}))}}function v(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiExtractStructuredFieldsField"'});if(null==e.key)throw new a.BoxSdkError({message:'Expecting "key" of type "AiExtractStructuredFieldsField" to be defined'});if(!(0,l.sdIsString)(e.key))throw new a.BoxSdkError({message:'Expecting string for "key" of type "AiExtractStructuredFieldsField"'});const t=e.key;if(null!=e.description&&!(0,l.sdIsString)(e.description))throw new a.BoxSdkError({message:'Expecting string for "description" of type "AiExtractStructuredFieldsField"'});const r=null==e.description?void 0:e.description;if(null!=e.displayName&&!(0,l.sdIsString)(e.displayName))throw new a.BoxSdkError({message:'Expecting string for "displayName" of type "AiExtractStructuredFieldsField"'});const i=null==e.displayName?void 0:e.displayName;if(null!=e.prompt&&!(0,l.sdIsString)(e.prompt))throw new a.BoxSdkError({message:'Expecting string for "prompt" of type "AiExtractStructuredFieldsField"'});const n=null==e.prompt?void 0:e.prompt;if(null!=e.type&&!(0,l.sdIsString)(e.type))throw new a.BoxSdkError({message:'Expecting string for "type" of type "AiExtractStructuredFieldsField"'});const o=null==e.type?void 0:e.type;if(null!=e.options&&!(0,d.sdIsList)(e.options))throw new a.BoxSdkError({message:'Expecting array for "options" of type "AiExtractStructuredFieldsField"'});return{key:t,description:r,displayName:i,prompt:n,type:o,options:null==e.options?void 0:(0,d.sdIsList)(e.options)?e.options.map((function(e){return g(e)})):[]}}},90948:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiItemBase=void 0,t.serializeAiItemBaseTypeField=s,t.deserializeAiItemBaseTypeField=a,t.serializeAiItemBase=function(e){return{id:e.id,type:e.type,content:null==e.content?void 0:e.content}},t.deserializeAiItemBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiItemBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "AiItemBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "AiItemBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "AiItemBase" to be defined'});const r=a(e.type);if(null!=e.content&&!(0,n.sdIsString)(e.content))throw new i.BoxSdkError({message:'Expecting string for "content" of type "AiItemBase"'});const s=null==e.content?void 0:e.content;return{id:t,type:r,content:s}},t.serializeAiItemBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,content:null==e.content?void 0:e.content}},t.deserializeAiItemBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiItemBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "AiItemBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "AiItemBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);if(null!=e.content&&!(0,n.sdIsString)(e.content))throw new i.BoxSdkError({message:'Expecting string for "content" of type "AiItemBaseInput"'});const s=null==e.content?void 0:e.content;return{id:t,type:r,content:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("file"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize AiItemBaseTypeField"})}t.AiItemBase=class{constructor(e){this.type="file",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.content&&(this.content=e.content),e.rawData&&(this.rawData=e.rawData)}}},27685:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiLlmEndpointParamsGoogle=void 0,t.serializeAiLlmEndpointParamsGoogleTypeField=s,t.deserializeAiLlmEndpointParamsGoogleTypeField=a,t.serializeAiLlmEndpointParamsGoogle=function(e){return{type:e.type,temperature:null==e.temperature?void 0:e.temperature,top_p:null==e.topP?void 0:e.topP,top_k:null==e.topK?void 0:e.topK}},t.deserializeAiLlmEndpointParamsGoogle=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiLlmEndpointParamsGoogle"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "AiLlmEndpointParamsGoogle" to be defined'});const t=a(e.type);if(null!=e.temperature&&!(0,n.sdIsNumber)(e.temperature))throw new i.BoxSdkError({message:'Expecting number for "temperature" of type "AiLlmEndpointParamsGoogle"'});const r=null==e.temperature?void 0:e.temperature;if(null!=e.top_p&&!(0,n.sdIsNumber)(e.top_p))throw new i.BoxSdkError({message:'Expecting number for "top_p" of type "AiLlmEndpointParamsGoogle"'});const s=null==e.top_p?void 0:e.top_p;if(null!=e.top_k&&!(0,n.sdIsNumber)(e.top_k))throw new i.BoxSdkError({message:'Expecting number for "top_k" of type "AiLlmEndpointParamsGoogle"'});const l=null==e.top_k?void 0:e.top_k;return{type:t,temperature:r,topP:s,topK:l}},t.serializeAiLlmEndpointParamsGoogleInput=function(e){return{type:null==e.type?void 0:e.type,temperature:null==e.temperature?void 0:e.temperature,top_p:null==e.topP?void 0:e.topP,top_k:null==e.topK?void 0:e.topK}},t.deserializeAiLlmEndpointParamsGoogleInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiLlmEndpointParamsGoogleInput"'});const t=null==e.type?void 0:a(e.type);if(null!=e.temperature&&!(0,n.sdIsNumber)(e.temperature))throw new i.BoxSdkError({message:'Expecting number for "temperature" of type "AiLlmEndpointParamsGoogleInput"'});const r=null==e.temperature?void 0:e.temperature;if(null!=e.top_p&&!(0,n.sdIsNumber)(e.top_p))throw new i.BoxSdkError({message:'Expecting number for "top_p" of type "AiLlmEndpointParamsGoogleInput"'});const s=null==e.top_p?void 0:e.top_p;if(null!=e.top_k&&!(0,n.sdIsNumber)(e.top_k))throw new i.BoxSdkError({message:'Expecting number for "top_k" of type "AiLlmEndpointParamsGoogleInput"'});const l=null==e.top_k?void 0:e.top_k;return{type:t,temperature:r,topP:s,topK:l}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("google_params"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize AiLlmEndpointParamsGoogleTypeField"})}t.AiLlmEndpointParamsGoogle=class{constructor(e){this.type="google_params",e.type&&(this.type=e.type),e.temperature&&(this.temperature=e.temperature),e.topP&&(this.topP=e.topP),e.topK&&(this.topK=e.topK),e.rawData&&(this.rawData=e.rawData)}}},52852:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi=function(e){if("google_params"==e.type)return(0,i.serializeAiLlmEndpointParamsGoogle)(e);if("openai_params"==e.type)return(0,o.serializeAiLlmEndpointParamsOpenAi)(e);throw new a.BoxSdkError({message:"unknown type"})},t.deserializeAiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi"'});if("google_params"==e.type)return(0,n.deserializeAiLlmEndpointParamsGoogle)(e);if("openai_params"==e.type)return(0,s.deserializeAiLlmEndpointParamsOpenAi)(e);throw new a.BoxSdkError({message:"Can't deserialize AiLlmEndpointParamsGoogleOrAiLlmEndpointParamsOpenAi"})};const i=r(27685),n=r(27685),o=r(9968),s=r(9968),a=r(72631),l=r(50793)},9968:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiLlmEndpointParamsOpenAi=void 0,t.serializeAiLlmEndpointParamsOpenAiTypeField=a,t.deserializeAiLlmEndpointParamsOpenAiTypeField=l,t.serializeAiLlmEndpointParamsOpenAi=function(e){return{type:e.type,temperature:null==e.temperature?void 0:e.temperature,top_p:null==e.topP?void 0:e.topP,frequency_penalty:null==e.frequencyPenalty?void 0:e.frequencyPenalty,presence_penalty:null==e.presencePenalty?void 0:e.presencePenalty,stop:null==e.stop?void 0:e.stop}},t.deserializeAiLlmEndpointParamsOpenAi=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiLlmEndpointParamsOpenAi"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "AiLlmEndpointParamsOpenAi" to be defined'});const t=l(e.type);if(null!=e.temperature&&!(0,n.sdIsNumber)(e.temperature))throw new i.BoxSdkError({message:'Expecting number for "temperature" of type "AiLlmEndpointParamsOpenAi"'});const r=null==e.temperature?void 0:e.temperature;if(null!=e.top_p&&!(0,n.sdIsNumber)(e.top_p))throw new i.BoxSdkError({message:'Expecting number for "top_p" of type "AiLlmEndpointParamsOpenAi"'});const a=null==e.top_p?void 0:e.top_p;if(null!=e.frequency_penalty&&!(0,n.sdIsNumber)(e.frequency_penalty))throw new i.BoxSdkError({message:'Expecting number for "frequency_penalty" of type "AiLlmEndpointParamsOpenAi"'});const d=null==e.frequency_penalty?void 0:e.frequency_penalty;if(null!=e.presence_penalty&&!(0,n.sdIsNumber)(e.presence_penalty))throw new i.BoxSdkError({message:'Expecting number for "presence_penalty" of type "AiLlmEndpointParamsOpenAi"'});const c=null==e.presence_penalty?void 0:e.presence_penalty;if(null!=e.stop&&!(0,o.sdIsString)(e.stop))throw new i.BoxSdkError({message:'Expecting string for "stop" of type "AiLlmEndpointParamsOpenAi"'});const u=null==e.stop?void 0:e.stop;return{type:t,temperature:r,topP:a,frequencyPenalty:d,presencePenalty:c,stop:u}},t.serializeAiLlmEndpointParamsOpenAiInput=function(e){return{type:null==e.type?void 0:e.type,temperature:null==e.temperature?void 0:e.temperature,top_p:null==e.topP?void 0:e.topP,frequency_penalty:null==e.frequencyPenalty?void 0:e.frequencyPenalty,presence_penalty:null==e.presencePenalty?void 0:e.presencePenalty,stop:null==e.stop?void 0:e.stop}},t.deserializeAiLlmEndpointParamsOpenAiInput=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AiLlmEndpointParamsOpenAiInput"'});const t=null==e.type?void 0:l(e.type);if(null!=e.temperature&&!(0,n.sdIsNumber)(e.temperature))throw new i.BoxSdkError({message:'Expecting number for "temperature" of type "AiLlmEndpointParamsOpenAiInput"'});const r=null==e.temperature?void 0:e.temperature;if(null!=e.top_p&&!(0,n.sdIsNumber)(e.top_p))throw new i.BoxSdkError({message:'Expecting number for "top_p" of type "AiLlmEndpointParamsOpenAiInput"'});const a=null==e.top_p?void 0:e.top_p;if(null!=e.frequency_penalty&&!(0,n.sdIsNumber)(e.frequency_penalty))throw new i.BoxSdkError({message:'Expecting number for "frequency_penalty" of type "AiLlmEndpointParamsOpenAiInput"'});const d=null==e.frequency_penalty?void 0:e.frequency_penalty;if(null!=e.presence_penalty&&!(0,n.sdIsNumber)(e.presence_penalty))throw new i.BoxSdkError({message:'Expecting number for "presence_penalty" of type "AiLlmEndpointParamsOpenAiInput"'});const c=null==e.presence_penalty?void 0:e.presence_penalty;if(null!=e.stop&&!(0,o.sdIsString)(e.stop))throw new i.BoxSdkError({message:'Expecting string for "stop" of type "AiLlmEndpointParamsOpenAiInput"'});const u=null==e.stop?void 0:e.stop;return{type:t,temperature:r,topP:a,frequencyPenalty:d,presencePenalty:c,stop:u}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793);function a(e){return e}function l(e){if("openai_params"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize AiLlmEndpointParamsOpenAiTypeField"})}t.AiLlmEndpointParamsOpenAi=class{constructor(e){this.type="openai_params",e.type&&(this.type=e.type),e.temperature&&(this.temperature=e.temperature),e.topP&&(this.topP=e.topP),e.frequencyPenalty&&(this.frequencyPenalty=e.frequencyPenalty),e.presencePenalty&&(this.presencePenalty=e.presencePenalty),e.stop&&(this.stop=e.stop),e.rawData&&(this.rawData=e.rawData)}}},67713:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiResponse=function(e){return{answer:e.answer,created_at:(0,i.serializeDateTime)(e.createdAt),completion_reason:null==e.completionReason?void 0:e.completionReason}},t.deserializeAiResponse=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AiResponse"'});if(null==e.answer)throw new o.BoxSdkError({message:'Expecting "answer" of type "AiResponse" to be defined'});if(!(0,s.sdIsString)(e.answer))throw new o.BoxSdkError({message:'Expecting string for "answer" of type "AiResponse"'});const t=e.answer;if(null==e.created_at)throw new o.BoxSdkError({message:'Expecting "created_at" of type "AiResponse" to be defined'});if(!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "AiResponse"'});const r=(0,n.deserializeDateTime)(e.created_at);if(null!=e.completion_reason&&!(0,s.sdIsString)(e.completion_reason))throw new o.BoxSdkError({message:'Expecting string for "completion_reason" of type "AiResponse"'});const i=null==e.completion_reason?void 0:e.completion_reason;return{answer:t,createdAt:r,completionReason:i}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793)},89820:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAiResponseFull=function(e){const t=(0,n.serializeAiResponse)(e);if(!(0,c.sdIsMap)(t))throw new a.BoxSdkError({message:'Expecting a map for "AiResponseFull"'});return Object.assign(Object.assign({},t),{citations:null==e.citations?void 0:e.citations.map((function(e){return(0,o.serializeAiCitation)(e)}))})},t.deserializeAiResponseFull=function(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiResponseFull"'});if(null!=e.citations&&!(0,d.sdIsList)(e.citations))throw new a.BoxSdkError({message:'Expecting array for "citations" of type "AiResponseFull"'});const t=null==e.citations?void 0:(0,d.sdIsList)(e.citations)?e.citations.map((function(e){return(0,s.deserializeAiCitation)(e)})):[];if(null==e.answer)throw new a.BoxSdkError({message:'Expecting "answer" of type "AiResponseFull" to be defined'});if(!(0,l.sdIsString)(e.answer))throw new a.BoxSdkError({message:'Expecting string for "answer" of type "AiResponseFull"'});const r=e.answer;if(null==e.created_at)throw new a.BoxSdkError({message:'Expecting "created_at" of type "AiResponseFull" to be defined'});if(!(0,l.sdIsString)(e.created_at))throw new a.BoxSdkError({message:'Expecting string for "created_at" of type "AiResponseFull"'});const n=(0,i.deserializeDateTime)(e.created_at);if(null!=e.completion_reason&&!(0,l.sdIsString)(e.completion_reason))throw new a.BoxSdkError({message:'Expecting string for "completion_reason" of type "AiResponseFull"'});const o=null==e.completion_reason?void 0:e.completion_reason;return{citations:t,answer:r,createdAt:n,completionReason:o}};const i=r(93845),n=r(67713),o=r(28655),s=r(28655),a=r(72631),l=r(50793),d=r(50793),c=r(50793)},82469:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AiTextGenItemsField=void 0,t.serializeAiTextGenItemsTypeField=u,t.deserializeAiTextGenItemsTypeField=p,t.serializeAiTextGenItemsField=h,t.deserializeAiTextGenItemsField=f,t.serializeAiTextGenItemsFieldInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,content:null==e.content?void 0:e.content}},t.deserializeAiTextGenItemsFieldInput=function(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiTextGenItemsFieldInput"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AiTextGenItemsFieldInput" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AiTextGenItemsFieldInput"'});const t=e.id,r=null==e.type?void 0:p(e.type);if(null!=e.content&&!(0,l.sdIsString)(e.content))throw new a.BoxSdkError({message:'Expecting string for "content" of type "AiTextGenItemsFieldInput"'});const i=null==e.content?void 0:e.content;return{id:t,type:r,content:i}},t.serializeAiTextGen=function(e){return{prompt:e.prompt,items:e.items.map((function(e){return h(e)})),dialogue_history:null==e.dialogueHistory?void 0:e.dialogueHistory.map((function(e){return(0,i.serializeAiDialogueHistory)(e)})),ai_agent:null==e.aiAgent?void 0:(0,o.serializeAiAgentTextGen)(e.aiAgent)}},t.deserializeAiTextGen=function(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiTextGen"'});if(null==e.prompt)throw new a.BoxSdkError({message:'Expecting "prompt" of type "AiTextGen" to be defined'});if(!(0,l.sdIsString)(e.prompt))throw new a.BoxSdkError({message:'Expecting string for "prompt" of type "AiTextGen"'});const t=e.prompt;if(null==e.items)throw new a.BoxSdkError({message:'Expecting "items" of type "AiTextGen" to be defined'});if(!(0,d.sdIsList)(e.items))throw new a.BoxSdkError({message:'Expecting array for "items" of type "AiTextGen"'});const r=(0,d.sdIsList)(e.items)?e.items.map((function(e){return f(e)})):[];if(null!=e.dialogue_history&&!(0,d.sdIsList)(e.dialogue_history))throw new a.BoxSdkError({message:'Expecting array for "dialogue_history" of type "AiTextGen"'});const i=null==e.dialogue_history?void 0:(0,d.sdIsList)(e.dialogue_history)?e.dialogue_history.map((function(e){return(0,n.deserializeAiDialogueHistory)(e)})):[],o=null==e.ai_agent?void 0:(0,s.deserializeAiAgentTextGen)(e.ai_agent);return{prompt:t,items:r,dialogueHistory:i,aiAgent:o}};const i=r(70936),n=r(70936),o=r(96390),s=r(96390),a=r(72631),l=r(50793),d=r(50793),c=r(50793);function u(e){return e}function p(e){if("file"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AiTextGenItemsTypeField"})}function h(e){return{id:e.id,type:e.type,content:null==e.content?void 0:e.content}}function f(e){if(!(0,c.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AiTextGenItemsField"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AiTextGenItemsField" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AiTextGenItemsField"'});const t=e.id;if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AiTextGenItemsField" to be defined'});const r=p(e.type);if(null!=e.content&&!(0,l.sdIsString)(e.content))throw new a.BoxSdkError({message:'Expecting string for "content" of type "AiTextGenItemsField"'});return{id:t,type:r,content:null==e.content?void 0:e.content}}t.AiTextGenItemsField=class{constructor(e){this.type="file",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.content&&(this.content=e.content),e.rawData&&(this.rawData=e.rawData)}}},28920:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppItem=void 0,t.serializeAppItemTypeField=s,t.deserializeAppItemTypeField=a,t.serializeAppItem=function(e){return{id:e.id,type:e.type,application_type:e.applicationType}},t.deserializeAppItem=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AppItem"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "AppItem" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "AppItem"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "AppItem" to be defined'});const r=a(e.type);if(null==e.application_type)throw new i.BoxSdkError({message:'Expecting "application_type" of type "AppItem" to be defined'});if(!(0,n.sdIsString)(e.application_type))throw new i.BoxSdkError({message:'Expecting string for "application_type" of type "AppItem"'});const s=e.application_type;return{id:t,type:r,applicationType:s}},t.serializeAppItemInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,application_type:e.applicationType}},t.deserializeAppItemInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "AppItemInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "AppItemInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "AppItemInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);if(null==e.application_type)throw new i.BoxSdkError({message:'Expecting "application_type" of type "AppItemInput" to be defined'});if(!(0,n.sdIsString)(e.application_type))throw new i.BoxSdkError({message:'Expecting string for "application_type" of type "AppItemInput"'});const s=e.application_type;return{id:t,type:r,applicationType:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("app_item"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize AppItemTypeField"})}t.AppItem=class{constructor(e){this.type="app_item",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.applicationType&&(this.applicationType=e.applicationType),e.rawData&&(this.rawData=e.rawData)}}},64679:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppItemAssociation=void 0,t.serializeAppItemAssociationTypeField=c,t.deserializeAppItemAssociationTypeField=u,t.serializeAppItemAssociation=function(e){return{id:e.id,type:e.type,app_item:(0,i.serializeAppItem)(e.appItem),item:(0,o.serializeFileBaseOrFolderBaseOrWebLinkBase)(e.item)}},t.deserializeAppItemAssociation=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AppItemAssociation"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AppItemAssociation" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AppItemAssociation"'});const t=e.id;if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AppItemAssociation" to be defined'});const r=u(e.type);if(null==e.app_item)throw new a.BoxSdkError({message:'Expecting "app_item" of type "AppItemAssociation" to be defined'});const i=(0,n.deserializeAppItem)(e.app_item);if(null==e.item)throw new a.BoxSdkError({message:'Expecting "item" of type "AppItemAssociation" to be defined'});const o=(0,s.deserializeFileBaseOrFolderBaseOrWebLinkBase)(e.item);return{id:t,type:r,appItem:i,item:o}},t.serializeAppItemAssociationInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,app_item:(0,i.serializeAppItem)(e.appItem),item:(0,o.serializeFileBaseOrFolderBaseOrWebLinkBase)(e.item)}},t.deserializeAppItemAssociationInput=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AppItemAssociationInput"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AppItemAssociationInput" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AppItemAssociationInput"'});const t=e.id,r=null==e.type?void 0:u(e.type);if(null==e.app_item)throw new a.BoxSdkError({message:'Expecting "app_item" of type "AppItemAssociationInput" to be defined'});const i=(0,n.deserializeAppItem)(e.app_item);if(null==e.item)throw new a.BoxSdkError({message:'Expecting "item" of type "AppItemAssociationInput" to be defined'});const o=(0,s.deserializeFileBaseOrFolderBaseOrWebLinkBase)(e.item);return{id:t,type:r,appItem:i,item:o}};const i=r(28920),n=r(28920),o=r(1197),s=r(1197),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("app_item_association"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AppItemAssociationTypeField"})}t.AppItemAssociation=class{constructor(e){this.type="app_item_association",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.appItem&&(this.appItem=e.appItem),e.item&&(this.item=e.item),e.rawData&&(this.rawData=e.rawData)}}},98292:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAppItemAssociations=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeAppItemAssociation)(e)}))}},t.deserializeAppItemAssociations=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "AppItemAssociations"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "AppItemAssociations"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "AppItemAssociations"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "AppItemAssociations"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "AppItemAssociations"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeAppItemAssociation)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(64679),n=r(64679),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},3457:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppItemEventSource=void 0,t.serializeAppItemEventSourceTypeField=c,t.deserializeAppItemEventSourceTypeField=u,t.serializeAppItemEventSource=function(e){return{id:e.id,type:e.type,app_item_type:e.appItemType,user:null==e.user?void 0:(0,i.serializeUserMini)(e.user),group:null==e.group?void 0:(0,o.serializeGroupMini)(e.group)}},t.deserializeAppItemEventSource=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AppItemEventSource"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AppItemEventSource" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AppItemEventSource"'});const t=e.id;if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "AppItemEventSource" to be defined'});const r=u(e.type);if(null==e.app_item_type)throw new a.BoxSdkError({message:'Expecting "app_item_type" of type "AppItemEventSource" to be defined'});if(!(0,l.sdIsString)(e.app_item_type))throw new a.BoxSdkError({message:'Expecting string for "app_item_type" of type "AppItemEventSource"'});const i=e.app_item_type,o=null==e.user?void 0:(0,n.deserializeUserMini)(e.user),c=null==e.group?void 0:(0,s.deserializeGroupMini)(e.group);return{id:t,type:r,appItemType:i,user:o,group:c}},t.serializeAppItemEventSourceInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,app_item_type:e.appItemType,user:null==e.user?void 0:(0,i.serializeUserMini)(e.user),group:null==e.group?void 0:(0,o.serializeGroupMini)(e.group)}},t.deserializeAppItemEventSourceInput=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "AppItemEventSourceInput"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "AppItemEventSourceInput" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "AppItemEventSourceInput"'});const t=e.id,r=null==e.type?void 0:u(e.type);if(null==e.app_item_type)throw new a.BoxSdkError({message:'Expecting "app_item_type" of type "AppItemEventSourceInput" to be defined'});if(!(0,l.sdIsString)(e.app_item_type))throw new a.BoxSdkError({message:'Expecting string for "app_item_type" of type "AppItemEventSourceInput"'});const i=e.app_item_type,o=null==e.user?void 0:(0,n.deserializeUserMini)(e.user),c=null==e.group?void 0:(0,s.deserializeGroupMini)(e.group);return{id:t,type:r,appItemType:i,user:o,group:c}};const i=r(95408),n=r(95408),o=r(99248),s=r(99248),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("app_item"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize AppItemEventSourceTypeField"})}t.AppItemEventSource=class{constructor(e){this.type="app_item",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.appItemType&&(this.appItemType=e.appItemType),e.user&&(this.user=e.user),e.group&&(this.group=e.group),e.rawData&&(this.rawData=e.rawData)}}},93148:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeAppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser=function(e){if("app_item"==e.type)return(0,i.serializeAppItemEventSource)(e);if("file"==e.type)return(0,a.serializeFile)(e);if("folder"==e.type)return(0,d.serializeFolder)(e);if("user"==e.type)return(0,h.serializeUser)(e);if("file"==e.itemType)return(0,o.serializeEventSource)(e);if("folder"==e.itemType)return(0,o.serializeEventSource)(e);return(0,u.serializeGenericSource)(e)},t.deserializeAppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser=function(e){if(!(0,g.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "AppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser"'});if("app_item"==e.type)return(0,n.deserializeAppItemEventSource)(e);if("file"==e.type)return(0,l.deserializeFile)(e);if("folder"==e.type)return(0,c.deserializeFolder)(e);if("user"==e.type)return(0,f.deserializeUser)(e);if(!(0,g.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "AppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser"'});if("file"==e.item_type)return(0,s.deserializeEventSource)(e);if("folder"==e.item_type)return(0,s.deserializeEventSource)(e);try{return(0,p.deserializeGenericSource)(e)}catch(e){}throw new m.BoxSdkError({message:"Can't deserialize AppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser"})};const i=r(3457),n=r(3457),o=r(37973),s=r(37973),a=r(46022),l=r(46022),d=r(18272),c=r(18272),u=r(65284),p=r(65284),h=r(1543),f=r(1543),m=r(72631),g=r(50793)},78748:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeClassificationTemplateField=l,t.deserializeClassificationTemplateField=d,t.serializeClassification=function(e){return{Box__Security__Classification__Key:null==e.boxSecurityClassificationKey?void 0:e.boxSecurityClassificationKey,$parent:null==e.parent?void 0:e.parent,$template:null==e.template?void 0:e.template,$scope:null==e.scope?void 0:e.scope,$version:null==e.version?void 0:e.version,$type:null==e.type?void 0:e.type,$typeVersion:null==e.typeVersion?void 0:e.typeVersion,$canEdit:null==e.canEdit?void 0:e.canEdit}},t.deserializeClassification=function(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "Classification"'});if(null!=e.Box__Security__Classification__Key&&!(0,s.sdIsString)(e.Box__Security__Classification__Key))throw new i.BoxSdkError({message:'Expecting string for "Box__Security__Classification__Key" of type "Classification"'});const t=null==e.Box__Security__Classification__Key?void 0:e.Box__Security__Classification__Key;if(null!=e.$parent&&!(0,s.sdIsString)(e.$parent))throw new i.BoxSdkError({message:'Expecting string for "$parent" of type "Classification"'});const r=null==e.$parent?void 0:e.$parent,l=null==e.$template?void 0:d(e.$template);if(null!=e.$scope&&!(0,s.sdIsString)(e.$scope))throw new i.BoxSdkError({message:'Expecting string for "$scope" of type "Classification"'});const c=null==e.$scope?void 0:e.$scope;if(null!=e.$version&&!(0,o.sdIsNumber)(e.$version))throw new i.BoxSdkError({message:'Expecting number for "$version" of type "Classification"'});const u=null==e.$version?void 0:e.$version;if(null!=e.$type&&!(0,s.sdIsString)(e.$type))throw new i.BoxSdkError({message:'Expecting string for "$type" of type "Classification"'});const p=null==e.$type?void 0:e.$type;if(null!=e.$typeVersion&&!(0,o.sdIsNumber)(e.$typeVersion))throw new i.BoxSdkError({message:'Expecting number for "$typeVersion" of type "Classification"'});const h=null==e.$typeVersion?void 0:e.$typeVersion;if(null!=e.$canEdit&&!(0,n.sdIsBoolean)(e.$canEdit))throw new i.BoxSdkError({message:'Expecting boolean for "$canEdit" of type "Classification"'});const f=null==e.$canEdit?void 0:e.$canEdit;return{boxSecurityClassificationKey:t,parent:r,template:l,scope:c,version:u,type:p,typeVersion:h,canEdit:f}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("securityClassification-6VMVochwUWo"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateField"})}},73146:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ClassificationTemplate=t.ClassificationTemplateFieldsField=void 0,t.serializeClassificationTemplateTypeField=d,t.deserializeClassificationTemplateTypeField=c,t.serializeClassificationTemplateTemplateKeyField=u,t.deserializeClassificationTemplateTemplateKeyField=p,t.serializeClassificationTemplateDisplayNameField=h,t.deserializeClassificationTemplateDisplayNameField=f,t.serializeClassificationTemplateFieldsTypeField=m,t.deserializeClassificationTemplateFieldsTypeField=g,t.serializeClassificationTemplateFieldsKeyField=y,t.deserializeClassificationTemplateFieldsKeyField=v,t.serializeClassificationTemplateFieldsDisplayNameField=b,t.deserializeClassificationTemplateFieldsDisplayNameField=w,t.serializeClassificationTemplateFieldsOptionsStaticConfigClassificationField=_,t.deserializeClassificationTemplateFieldsOptionsStaticConfigClassificationField=x,t.serializeClassificationTemplateFieldsOptionsStaticConfigField=S,t.deserializeClassificationTemplateFieldsOptionsStaticConfigField=k,t.serializeClassificationTemplateFieldsOptionsField=E,t.deserializeClassificationTemplateFieldsOptionsField=T,t.serializeClassificationTemplateFieldsField=B,t.deserializeClassificationTemplateFieldsField=C,t.serializeClassificationTemplateFieldsFieldInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,key:null==e.key?void 0:e.key,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,options:e.options.map((function(e){return E(e)}))}},t.deserializeClassificationTemplateFieldsFieldInput=function(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateFieldsFieldInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ClassificationTemplateFieldsFieldInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ClassificationTemplateFieldsFieldInput"'});const t=e.id,r=null==e.type?void 0:g(e.type),o=null==e.key?void 0:v(e.key),d=null==e.displayName?void 0:w(e.displayName);if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "ClassificationTemplateFieldsFieldInput"'});const c=null==e.hidden?void 0:e.hidden;if(null==e.options)throw new i.BoxSdkError({message:'Expecting "options" of type "ClassificationTemplateFieldsFieldInput" to be defined'});if(!(0,a.sdIsList)(e.options))throw new i.BoxSdkError({message:'Expecting array for "options" of type "ClassificationTemplateFieldsFieldInput"'});const u=(0,a.sdIsList)(e.options)?e.options.map((function(e){return T(e)})):[];return{id:t,type:r,key:o,displayName:d,hidden:c,options:u}},t.serializeClassificationTemplate=function(e){return{id:e.id,type:e.type,scope:e.scope,templateKey:e.templateKey,displayName:e.displayName,hidden:null==e.hidden?void 0:e.hidden,copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy,fields:e.fields.map((function(e){return B(e)}))}},t.deserializeClassificationTemplate=function(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplate"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ClassificationTemplate" to be defined'});if(!(0,s.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ClassificationTemplate"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "ClassificationTemplate" to be defined'});const r=c(e.type);if(null==e.scope)throw new i.BoxSdkError({message:'Expecting "scope" of type "ClassificationTemplate" to be defined'});if(!(0,s.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "ClassificationTemplate"'});const o=e.scope;if(null==e.templateKey)throw new i.BoxSdkError({message:'Expecting "templateKey" of type "ClassificationTemplate" to be defined'});const d=p(e.templateKey);if(null==e.displayName)throw new i.BoxSdkError({message:'Expecting "displayName" of type "ClassificationTemplate" to be defined'});const u=f(e.displayName);if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "ClassificationTemplate"'});const h=null==e.hidden?void 0:e.hidden;if(null!=e.copyInstanceOnItemCopy&&!(0,n.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new i.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "ClassificationTemplate"'});const m=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;if(null==e.fields)throw new i.BoxSdkError({message:'Expecting "fields" of type "ClassificationTemplate" to be defined'});if(!(0,a.sdIsList)(e.fields))throw new i.BoxSdkError({message:'Expecting array for "fields" of type "ClassificationTemplate"'});const g=(0,a.sdIsList)(e.fields)?e.fields.map((function(e){return C(e)})):[];return{id:t,type:r,scope:o,templateKey:d,displayName:u,hidden:h,copyInstanceOnItemCopy:m,fields:g}},t.serializeClassificationTemplateInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,scope:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy,fields:e.fields.map((function(e){return B(e)}))}},t.deserializeClassificationTemplateInput=function(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ClassificationTemplateInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ClassificationTemplateInput"'});const t=e.id,r=null==e.type?void 0:c(e.type);if(null==e.scope)throw new i.BoxSdkError({message:'Expecting "scope" of type "ClassificationTemplateInput" to be defined'});if(!(0,s.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "ClassificationTemplateInput"'});const o=e.scope,d=null==e.templateKey?void 0:p(e.templateKey),u=null==e.displayName?void 0:f(e.displayName);if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "ClassificationTemplateInput"'});const h=null==e.hidden?void 0:e.hidden;if(null!=e.copyInstanceOnItemCopy&&!(0,n.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new i.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "ClassificationTemplateInput"'});const m=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;if(null==e.fields)throw new i.BoxSdkError({message:'Expecting "fields" of type "ClassificationTemplateInput" to be defined'});if(!(0,a.sdIsList)(e.fields))throw new i.BoxSdkError({message:'Expecting array for "fields" of type "ClassificationTemplateInput"'});const g=(0,a.sdIsList)(e.fields)?e.fields.map((function(e){return C(e)})):[];return{id:t,type:r,scope:o,templateKey:d,displayName:u,hidden:h,copyInstanceOnItemCopy:m,fields:g}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793),a=r(50793),l=r(50793);t.ClassificationTemplateFieldsField=class{constructor(e){this.type="enum",this.key="Box__Security__Classification__Key",this.displayName="Classification",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.key&&(this.key=e.key),e.displayName&&(this.displayName=e.displayName),e.hidden&&(this.hidden=e.hidden),e.options&&(this.options=e.options),e.rawData&&(this.rawData=e.rawData)}};function d(e){return e}function c(e){if("metadata_template"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateTypeField"})}function u(e){return e}function p(e){if("securityClassification-6VMVochwUWo"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateTemplateKeyField"})}function h(e){return e}function f(e){if("Classification"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateDisplayNameField"})}function m(e){return e}function g(e){if("enum"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateFieldsTypeField"})}function y(e){return e}function v(e){if("Box__Security__Classification__Key"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateFieldsKeyField"})}function b(e){return e}function w(e){if("Classification"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ClassificationTemplateFieldsDisplayNameField"})}function _(e){return{classificationDefinition:null==e.classificationDefinition?void 0:e.classificationDefinition,colorID:null==e.colorId?void 0:e.colorId}}function x(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateFieldsOptionsStaticConfigClassificationField"'});if(null!=e.classificationDefinition&&!(0,s.sdIsString)(e.classificationDefinition))throw new i.BoxSdkError({message:'Expecting string for "classificationDefinition" of type "ClassificationTemplateFieldsOptionsStaticConfigClassificationField"'});const t=null==e.classificationDefinition?void 0:e.classificationDefinition;if(null!=e.colorID&&!(0,o.sdIsNumber)(e.colorID))throw new i.BoxSdkError({message:'Expecting number for "colorID" of type "ClassificationTemplateFieldsOptionsStaticConfigClassificationField"'});return{classificationDefinition:t,colorId:null==e.colorID?void 0:e.colorID}}function S(e){return{classification:null==e.classification?void 0:_(e.classification)}}function k(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateFieldsOptionsStaticConfigField"'});return{classification:null==e.classification?void 0:x(e.classification)}}function E(e){return{id:e.id,key:e.key,staticConfig:null==e.staticConfig?void 0:S(e.staticConfig)}}function T(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateFieldsOptionsField"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ClassificationTemplateFieldsOptionsField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ClassificationTemplateFieldsOptionsField"'});const t=e.id;if(null==e.key)throw new i.BoxSdkError({message:'Expecting "key" of type "ClassificationTemplateFieldsOptionsField" to be defined'});if(!(0,s.sdIsString)(e.key))throw new i.BoxSdkError({message:'Expecting string for "key" of type "ClassificationTemplateFieldsOptionsField"'});return{id:t,key:e.key,staticConfig:null==e.staticConfig?void 0:k(e.staticConfig)}}function B(e){return{id:e.id,type:e.type,key:e.key,displayName:e.displayName,hidden:null==e.hidden?void 0:e.hidden,options:e.options.map((function(e){return E(e)}))}}function C(e){if(!(0,l.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ClassificationTemplateFieldsField"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ClassificationTemplateFieldsField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ClassificationTemplateFieldsField"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "ClassificationTemplateFieldsField" to be defined'});const r=g(e.type);if(null==e.key)throw new i.BoxSdkError({message:'Expecting "key" of type "ClassificationTemplateFieldsField" to be defined'});const o=v(e.key);if(null==e.displayName)throw new i.BoxSdkError({message:'Expecting "displayName" of type "ClassificationTemplateFieldsField" to be defined'});const d=w(e.displayName);if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "ClassificationTemplateFieldsField"'});const c=null==e.hidden?void 0:e.hidden;if(null==e.options)throw new i.BoxSdkError({message:'Expecting "options" of type "ClassificationTemplateFieldsField" to be defined'});if(!(0,a.sdIsList)(e.options))throw new i.BoxSdkError({message:'Expecting array for "options" of type "ClassificationTemplateFieldsField"'});return{id:t,type:r,key:o,displayName:d,hidden:c,options:(0,a.sdIsList)(e.options)?e.options.map((function(e){return T(e)})):[]}}t.ClassificationTemplate=class{constructor(e){this.type="metadata_template",this.templateKey="securityClassification-6VMVochwUWo",this.displayName="Classification",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.scope&&(this.scope=e.scope),e.templateKey&&(this.templateKey=e.templateKey),e.displayName&&(this.displayName=e.displayName),e.hidden&&(this.hidden=e.hidden),e.copyInstanceOnItemCopy&&(this.copyInstanceOnItemCopy=e.copyInstanceOnItemCopy),e.fields&&(this.fields=e.fields),e.rawData&&(this.rawData=e.rawData)}}},10189:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Collaboration=void 0,t.serializeCollaborationTypeField=b,t.deserializeCollaborationTypeField=w,t.serializeCollaborationRoleField=_,t.deserializeCollaborationRoleField=x,t.serializeCollaborationStatusField=S,t.deserializeCollaborationStatusField=k,t.serializeCollaborationAcceptanceRequirementsStatusTermsOfServiceRequirementField=E,t.deserializeCollaborationAcceptanceRequirementsStatusTermsOfServiceRequirementField=T,t.serializeCollaborationAcceptanceRequirementsStatusStrongPasswordRequirementField=B,t.deserializeCollaborationAcceptanceRequirementsStatusStrongPasswordRequirementField=C,t.serializeCollaborationAcceptanceRequirementsStatusTwoFactorAuthenticationRequirementField=I,t.deserializeCollaborationAcceptanceRequirementsStatusTwoFactorAuthenticationRequirementField=A,t.serializeCollaborationAcceptanceRequirementsStatusField=F,t.deserializeCollaborationAcceptanceRequirementsStatusField=M,t.serializeCollaboration=function(e){return{id:e.id,type:e.type,item:null==e.item?void 0:(0,i.serializeFileOrFolderOrWebLink)(e.item),app_item:null==e.appItem?void 0:(0,o.serializeAppItem)(e.appItem),accessible_by:null==e.accessibleBy?void 0:(0,a.serializeGroupMiniOrUserCollaborations)(e.accessibleBy),invite_email:null==e.inviteEmail?void 0:e.inviteEmail,role:null==e.role?void 0:e.role,expires_at:null==e.expiresAt?void 0:(0,h.serializeDateTime)(e.expiresAt),is_access_only:null==e.isAccessOnly?void 0:e.isAccessOnly,status:null==e.status?void 0:e.status,acknowledged_at:null==e.acknowledgedAt?void 0:(0,h.serializeDateTime)(e.acknowledgedAt),created_by:null==e.createdBy?void 0:(0,d.serializeUserCollaborations)(e.createdBy),created_at:null==e.createdAt?void 0:(0,h.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,h.serializeDateTime)(e.modifiedAt),acceptance_requirements_status:null==e.acceptanceRequirementsStatus?void 0:F(e.acceptanceRequirementsStatus)}},t.deserializeCollaboration=function(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "Collaboration"'});if(null==e.id)throw new m.BoxSdkError({message:'Expecting "id" of type "Collaboration" to be defined'});if(!(0,y.sdIsString)(e.id))throw new m.BoxSdkError({message:'Expecting string for "id" of type "Collaboration"'});const t=e.id;if(null==e.type)throw new m.BoxSdkError({message:'Expecting "type" of type "Collaboration" to be defined'});const r=w(e.type),i=null==e.item?void 0:(0,n.deserializeFileOrFolderOrWebLink)(e.item),o=null==e.app_item?void 0:(0,s.deserializeAppItem)(e.app_item),a=null==e.accessible_by?void 0:(0,l.deserializeGroupMiniOrUserCollaborations)(e.accessible_by);if(null!=e.invite_email&&!(0,y.sdIsString)(e.invite_email))throw new m.BoxSdkError({message:'Expecting string for "invite_email" of type "Collaboration"'});const d=null==e.invite_email?void 0:e.invite_email,u=null==e.role?void 0:x(e.role);if(null!=e.expires_at&&!(0,y.sdIsString)(e.expires_at))throw new m.BoxSdkError({message:'Expecting string for "expires_at" of type "Collaboration"'});const p=null==e.expires_at?void 0:(0,f.deserializeDateTime)(e.expires_at);if(null!=e.is_access_only&&!(0,g.sdIsBoolean)(e.is_access_only))throw new m.BoxSdkError({message:'Expecting boolean for "is_access_only" of type "Collaboration"'});const h=null==e.is_access_only?void 0:e.is_access_only,b=null==e.status?void 0:k(e.status);if(null!=e.acknowledged_at&&!(0,y.sdIsString)(e.acknowledged_at))throw new m.BoxSdkError({message:'Expecting string for "acknowledged_at" of type "Collaboration"'});const _=null==e.acknowledged_at?void 0:(0,f.deserializeDateTime)(e.acknowledged_at),S=null==e.created_by?void 0:(0,c.deserializeUserCollaborations)(e.created_by);if(null!=e.created_at&&!(0,y.sdIsString)(e.created_at))throw new m.BoxSdkError({message:'Expecting string for "created_at" of type "Collaboration"'});const E=null==e.created_at?void 0:(0,f.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,y.sdIsString)(e.modified_at))throw new m.BoxSdkError({message:'Expecting string for "modified_at" of type "Collaboration"'});const T=null==e.modified_at?void 0:(0,f.deserializeDateTime)(e.modified_at),B=null==e.acceptance_requirements_status?void 0:M(e.acceptance_requirements_status);return{id:t,type:r,item:i,appItem:o,accessibleBy:a,inviteEmail:d,role:u,expiresAt:p,isAccessOnly:h,status:b,acknowledgedAt:_,createdBy:S,createdAt:E,modifiedAt:T,acceptanceRequirementsStatus:B}},t.serializeCollaborationInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,item:null==e.item?void 0:(0,i.serializeFileOrFolderOrWebLink)(e.item),app_item:null==e.appItem?void 0:(0,o.serializeAppItem)(e.appItem),accessible_by:null==e.accessibleBy?void 0:(0,a.serializeGroupMiniOrUserCollaborations)(e.accessibleBy),invite_email:null==e.inviteEmail?void 0:e.inviteEmail,role:null==e.role?void 0:e.role,expires_at:null==e.expiresAt?void 0:(0,h.serializeDateTime)(e.expiresAt),is_access_only:null==e.isAccessOnly?void 0:e.isAccessOnly,status:null==e.status?void 0:e.status,acknowledged_at:null==e.acknowledgedAt?void 0:(0,h.serializeDateTime)(e.acknowledgedAt),created_by:null==e.createdBy?void 0:(0,d.serializeUserCollaborations)(e.createdBy),created_at:null==e.createdAt?void 0:(0,h.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,h.serializeDateTime)(e.modifiedAt),acceptance_requirements_status:null==e.acceptanceRequirementsStatus?void 0:F(e.acceptanceRequirementsStatus)}},t.deserializeCollaborationInput=function(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "CollaborationInput"'});if(null==e.id)throw new m.BoxSdkError({message:'Expecting "id" of type "CollaborationInput" to be defined'});if(!(0,y.sdIsString)(e.id))throw new m.BoxSdkError({message:'Expecting string for "id" of type "CollaborationInput"'});const t=e.id,r=null==e.type?void 0:w(e.type),i=null==e.item?void 0:(0,n.deserializeFileOrFolderOrWebLink)(e.item),o=null==e.app_item?void 0:(0,s.deserializeAppItem)(e.app_item),a=null==e.accessible_by?void 0:(0,l.deserializeGroupMiniOrUserCollaborations)(e.accessible_by);if(null!=e.invite_email&&!(0,y.sdIsString)(e.invite_email))throw new m.BoxSdkError({message:'Expecting string for "invite_email" of type "CollaborationInput"'});const d=null==e.invite_email?void 0:e.invite_email,u=null==e.role?void 0:x(e.role);if(null!=e.expires_at&&!(0,y.sdIsString)(e.expires_at))throw new m.BoxSdkError({message:'Expecting string for "expires_at" of type "CollaborationInput"'});const p=null==e.expires_at?void 0:(0,f.deserializeDateTime)(e.expires_at);if(null!=e.is_access_only&&!(0,g.sdIsBoolean)(e.is_access_only))throw new m.BoxSdkError({message:'Expecting boolean for "is_access_only" of type "CollaborationInput"'});const h=null==e.is_access_only?void 0:e.is_access_only,b=null==e.status?void 0:k(e.status);if(null!=e.acknowledged_at&&!(0,y.sdIsString)(e.acknowledged_at))throw new m.BoxSdkError({message:'Expecting string for "acknowledged_at" of type "CollaborationInput"'});const _=null==e.acknowledged_at?void 0:(0,f.deserializeDateTime)(e.acknowledged_at),S=null==e.created_by?void 0:(0,c.deserializeUserCollaborations)(e.created_by);if(null!=e.created_at&&!(0,y.sdIsString)(e.created_at))throw new m.BoxSdkError({message:'Expecting string for "created_at" of type "CollaborationInput"'});const E=null==e.created_at?void 0:(0,f.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,y.sdIsString)(e.modified_at))throw new m.BoxSdkError({message:'Expecting string for "modified_at" of type "CollaborationInput"'});const T=null==e.modified_at?void 0:(0,f.deserializeDateTime)(e.modified_at),B=null==e.acceptance_requirements_status?void 0:M(e.acceptance_requirements_status);return{id:t,type:r,item:i,appItem:o,accessibleBy:a,inviteEmail:d,role:u,expiresAt:p,isAccessOnly:h,status:b,acknowledgedAt:_,createdBy:S,createdAt:E,modifiedAt:T,acceptanceRequirementsStatus:B}};const i=r(94132),n=r(94132),o=r(28920),s=r(28920),a=r(48716),l=r(48716),d=r(21517),c=r(21517),u=r(10308),p=r(10308),h=r(93845),f=r(93845),m=r(72631),g=r(50793),y=r(50793),v=r(50793);function b(e){return e}function w(e){if("collaboration"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize CollaborationTypeField"})}function _(e){return e}function x(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;if("owner"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize CollaborationRoleField"})}function S(e){return e}function k(e){if("accepted"==e)return e;if("pending"==e)return e;if("rejected"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize CollaborationStatusField"})}function E(e){return{is_accepted:null==e.isAccepted?void 0:e.isAccepted,terms_of_service:null==e.termsOfService?void 0:(0,u.serializeTermsOfServiceBase)(e.termsOfService)}}function T(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "CollaborationAcceptanceRequirementsStatusTermsOfServiceRequirementField"'});if(null!=e.is_accepted&&!(0,g.sdIsBoolean)(e.is_accepted))throw new m.BoxSdkError({message:'Expecting boolean for "is_accepted" of type "CollaborationAcceptanceRequirementsStatusTermsOfServiceRequirementField"'});return{isAccepted:null==e.is_accepted?void 0:e.is_accepted,termsOfService:null==e.terms_of_service?void 0:(0,p.deserializeTermsOfServiceBase)(e.terms_of_service)}}function B(e){return{enterprise_has_strong_password_required_for_external_users:null==e.enterpriseHasStrongPasswordRequiredForExternalUsers?void 0:e.enterpriseHasStrongPasswordRequiredForExternalUsers,user_has_strong_password:null==e.userHasStrongPassword?void 0:e.userHasStrongPassword}}function C(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "CollaborationAcceptanceRequirementsStatusStrongPasswordRequirementField"'});if(null!=e.enterprise_has_strong_password_required_for_external_users&&!(0,g.sdIsBoolean)(e.enterprise_has_strong_password_required_for_external_users))throw new m.BoxSdkError({message:'Expecting boolean for "enterprise_has_strong_password_required_for_external_users" of type "CollaborationAcceptanceRequirementsStatusStrongPasswordRequirementField"'});const t=null==e.enterprise_has_strong_password_required_for_external_users?void 0:e.enterprise_has_strong_password_required_for_external_users;if(null!=e.user_has_strong_password&&!(0,g.sdIsBoolean)(e.user_has_strong_password))throw new m.BoxSdkError({message:'Expecting boolean for "user_has_strong_password" of type "CollaborationAcceptanceRequirementsStatusStrongPasswordRequirementField"'});return{enterpriseHasStrongPasswordRequiredForExternalUsers:t,userHasStrongPassword:null==e.user_has_strong_password?void 0:e.user_has_strong_password}}function I(e){return{enterprise_has_two_factor_auth_enabled:null==e.enterpriseHasTwoFactorAuthEnabled?void 0:e.enterpriseHasTwoFactorAuthEnabled,user_has_two_factor_authentication_enabled:null==e.userHasTwoFactorAuthenticationEnabled?void 0:e.userHasTwoFactorAuthenticationEnabled}}function A(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "CollaborationAcceptanceRequirementsStatusTwoFactorAuthenticationRequirementField"'});if(null!=e.enterprise_has_two_factor_auth_enabled&&!(0,g.sdIsBoolean)(e.enterprise_has_two_factor_auth_enabled))throw new m.BoxSdkError({message:'Expecting boolean for "enterprise_has_two_factor_auth_enabled" of type "CollaborationAcceptanceRequirementsStatusTwoFactorAuthenticationRequirementField"'});const t=null==e.enterprise_has_two_factor_auth_enabled?void 0:e.enterprise_has_two_factor_auth_enabled;if(null!=e.user_has_two_factor_authentication_enabled&&!(0,g.sdIsBoolean)(e.user_has_two_factor_authentication_enabled))throw new m.BoxSdkError({message:'Expecting boolean for "user_has_two_factor_authentication_enabled" of type "CollaborationAcceptanceRequirementsStatusTwoFactorAuthenticationRequirementField"'});return{enterpriseHasTwoFactorAuthEnabled:t,userHasTwoFactorAuthenticationEnabled:null==e.user_has_two_factor_authentication_enabled?void 0:e.user_has_two_factor_authentication_enabled}}function F(e){return{terms_of_service_requirement:null==e.termsOfServiceRequirement?void 0:E(e.termsOfServiceRequirement),strong_password_requirement:null==e.strongPasswordRequirement?void 0:B(e.strongPasswordRequirement),two_factor_authentication_requirement:null==e.twoFactorAuthenticationRequirement?void 0:I(e.twoFactorAuthenticationRequirement)}}function M(e){if(!(0,v.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "CollaborationAcceptanceRequirementsStatusField"'});return{termsOfServiceRequirement:null==e.terms_of_service_requirement?void 0:T(e.terms_of_service_requirement),strongPasswordRequirement:null==e.strong_password_requirement?void 0:C(e.strong_password_requirement),twoFactorAuthenticationRequirement:null==e.two_factor_authentication_requirement?void 0:A(e.two_factor_authentication_requirement)}}t.Collaboration=class{constructor(e){this.type="collaboration",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.item&&(this.item=e.item),e.appItem&&(this.appItem=e.appItem),e.accessibleBy&&(this.accessibleBy=e.accessibleBy),e.inviteEmail&&(this.inviteEmail=e.inviteEmail),e.role&&(this.role=e.role),e.expiresAt&&(this.expiresAt=e.expiresAt),e.isAccessOnly&&(this.isAccessOnly=e.isAccessOnly),e.status&&(this.status=e.status),e.acknowledgedAt&&(this.acknowledgedAt=e.acknowledgedAt),e.createdBy&&(this.createdBy=e.createdBy),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.acceptanceRequirementsStatus&&(this.acceptanceRequirementsStatus=e.acceptanceRequirementsStatus),e.rawData&&(this.rawData=e.rawData)}}},36958:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollaborationAllowlistEntries=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeCollaborationAllowlistEntry)(e)}))}},t.deserializeCollaborationAllowlistEntries=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistEntries"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "CollaborationAllowlistEntries"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "CollaborationAllowlistEntries"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "CollaborationAllowlistEntries"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "CollaborationAllowlistEntries"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeCollaborationAllowlistEntry)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(66774),n=r(66774),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},66774:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollaborationAllowlistEntryTypeField=l,t.deserializeCollaborationAllowlistEntryTypeField=d,t.serializeCollaborationAllowlistEntryDirectionField=c,t.deserializeCollaborationAllowlistEntryDirectionField=u,t.serializeCollaborationAllowlistEntryEnterpriseTypeField=p,t.deserializeCollaborationAllowlistEntryEnterpriseTypeField=h,t.serializeCollaborationAllowlistEntryEnterpriseField=f,t.deserializeCollaborationAllowlistEntryEnterpriseField=m,t.serializeCollaborationAllowlistEntry=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,domain:null==e.domain?void 0:e.domain,direction:null==e.direction?void 0:e.direction,enterprise:null==e.enterprise?void 0:f(e.enterprise),created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt)}},t.deserializeCollaborationAllowlistEntry=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistEntry"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "CollaborationAllowlistEntry"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:d(e.type);if(null!=e.domain&&!(0,s.sdIsString)(e.domain))throw new o.BoxSdkError({message:'Expecting string for "domain" of type "CollaborationAllowlistEntry"'});const i=null==e.domain?void 0:e.domain,l=null==e.direction?void 0:u(e.direction),c=null==e.enterprise?void 0:m(e.enterprise);if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "CollaborationAllowlistEntry"'});const p=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);return{id:t,type:r,domain:i,direction:l,enterprise:c,createdAt:p}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("collaboration_whitelist_entry"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CollaborationAllowlistEntryTypeField"})}function c(e){return e}function u(e){if("inbound"==e)return e;if("outbound"==e)return e;if("both"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CollaborationAllowlistEntryDirectionField"})}function p(e){return e}function h(e){if("enterprise"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CollaborationAllowlistEntryEnterpriseTypeField"})}function f(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}}function m(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistEntryEnterpriseField"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "CollaborationAllowlistEntryEnterpriseField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type);if(null!=e.name&&!(0,s.sdIsString)(e.name))throw new o.BoxSdkError({message:'Expecting string for "name" of type "CollaborationAllowlistEntryEnterpriseField"'});return{id:t,type:r,name:null==e.name?void 0:e.name}}},92720:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollaborationAllowlistExemptTargetTypeField=c,t.deserializeCollaborationAllowlistExemptTargetTypeField=u,t.serializeCollaborationAllowlistExemptTargetEnterpriseTypeField=p,t.deserializeCollaborationAllowlistExemptTargetEnterpriseTypeField=h,t.serializeCollaborationAllowlistExemptTargetEnterpriseField=f,t.deserializeCollaborationAllowlistExemptTargetEnterpriseField=m,t.serializeCollaborationAllowlistExemptTarget=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,enterprise:null==e.enterprise?void 0:f(e.enterprise),user:null==e.user?void 0:(0,i.serializeUserMini)(e.user),created_at:null==e.createdAt?void 0:(0,o.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,o.serializeDateTime)(e.modifiedAt)}},t.deserializeCollaborationAllowlistExemptTarget=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistExemptTarget"'});if(null!=e.id&&!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "CollaborationAllowlistExemptTarget"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:u(e.type),i=null==e.enterprise?void 0:m(e.enterprise),o=null==e.user?void 0:(0,n.deserializeUserMini)(e.user);if(null!=e.created_at&&!(0,l.sdIsString)(e.created_at))throw new a.BoxSdkError({message:'Expecting string for "created_at" of type "CollaborationAllowlistExemptTarget"'});const c=null==e.created_at?void 0:(0,s.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,l.sdIsString)(e.modified_at))throw new a.BoxSdkError({message:'Expecting string for "modified_at" of type "CollaborationAllowlistExemptTarget"'});const p=null==e.modified_at?void 0:(0,s.deserializeDateTime)(e.modified_at);return{id:t,type:r,enterprise:i,user:o,createdAt:c,modifiedAt:p}};const i=r(95408),n=r(95408),o=r(93845),s=r(93845),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("collaboration_whitelist_exempt_target"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize CollaborationAllowlistExemptTargetTypeField"})}function p(e){return e}function h(e){if("enterprise"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize CollaborationAllowlistExemptTargetEnterpriseTypeField"})}function f(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}}function m(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistExemptTargetEnterpriseField"'});if(null!=e.id&&!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "CollaborationAllowlistExemptTargetEnterpriseField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type);if(null!=e.name&&!(0,l.sdIsString)(e.name))throw new a.BoxSdkError({message:'Expecting string for "name" of type "CollaborationAllowlistExemptTargetEnterpriseField"'});return{id:t,type:r,name:null==e.name?void 0:e.name}}},38333:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollaborationAllowlistExemptTargets=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeCollaborationAllowlistExemptTarget)(e)}))}},t.deserializeCollaborationAllowlistExemptTargets=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollaborationAllowlistExemptTargets"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "CollaborationAllowlistExemptTargets"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "CollaborationAllowlistExemptTargets"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "CollaborationAllowlistExemptTargets"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "CollaborationAllowlistExemptTargets"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeCollaborationAllowlistExemptTarget)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(92720),n=r(92720),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},7546:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollaborationsOrderDirectionField=c,t.deserializeCollaborationsOrderDirectionField=u,t.serializeCollaborationsOrderField=p,t.deserializeCollaborationsOrderField=h,t.serializeCollaborations=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,total_count:null==e.totalCount?void 0:e.totalCount,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeCollaboration)(e)}))}},t.deserializeCollaborations=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Collaborations"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Collaborations"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "Collaborations"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "Collaborations"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Collaborations"'});const c=null==e.total_count?void 0:e.total_count;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Collaborations"'});const u=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Collaborations"'});const p=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Collaborations"'});const f=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeCollaboration)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,totalCount:c,offset:u,order:p,entries:f}};const i=r(10189),n=r(10189),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CollaborationsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollaborationsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "CollaborationsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},44432:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CollaboratorVariable=t.CollaboratorVariableVariableValueField=void 0,t.serializeCollaboratorVariableTypeField=a,t.deserializeCollaboratorVariableTypeField=l,t.serializeCollaboratorVariableVariableTypeField=d,t.deserializeCollaboratorVariableVariableTypeField=c,t.serializeCollaboratorVariableVariableValueTypeField=u,t.deserializeCollaboratorVariableVariableValueTypeField=p,t.serializeCollaboratorVariableVariableValueField=h,t.deserializeCollaboratorVariableVariableValueField=f,t.serializeCollaboratorVariableVariableValueFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeCollaboratorVariableVariableValueFieldInput=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CollaboratorVariableVariableValueFieldInput"'});const t=null==e.type?void 0:p(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "CollaboratorVariableVariableValueFieldInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "CollaboratorVariableVariableValueFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeCollaboratorVariable=function(e){return{type:e.type,variable_type:e.variableType,variable_value:e.variableValue.map((function(e){return h(e)}))}},t.deserializeCollaboratorVariable=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CollaboratorVariable"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "CollaboratorVariable" to be defined'});const t=l(e.type);if(null==e.variable_type)throw new i.BoxSdkError({message:'Expecting "variable_type" of type "CollaboratorVariable" to be defined'});const r=c(e.variable_type);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "CollaboratorVariable" to be defined'});if(!(0,o.sdIsList)(e.variable_value))throw new i.BoxSdkError({message:'Expecting array for "variable_value" of type "CollaboratorVariable"'});const n=(0,o.sdIsList)(e.variable_value)?e.variable_value.map((function(e){return f(e)})):[];return{type:t,variableType:r,variableValue:n}},t.serializeCollaboratorVariableInput=function(e){return{type:null==e.type?void 0:e.type,variableType:null==e.variableType?void 0:e.variableType,variable_value:e.variableValue.map((function(e){return h(e)}))}},t.deserializeCollaboratorVariableInput=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CollaboratorVariableInput"'});const t=null==e.type?void 0:l(e.type),r=null==e.variableType?void 0:c(e.variableType);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "CollaboratorVariableInput" to be defined'});if(!(0,o.sdIsList)(e.variable_value))throw new i.BoxSdkError({message:'Expecting array for "variable_value" of type "CollaboratorVariableInput"'});const n=(0,o.sdIsList)(e.variable_value)?e.variable_value.map((function(e){return f(e)})):[];return{type:t,variableType:r,variableValue:n}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793);t.CollaboratorVariableVariableValueField=class{constructor(e){this.type="user",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};function a(e){return e}function l(e){if("variable"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollaboratorVariableTypeField"})}function d(e){return e}function c(e){if("user_list"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollaboratorVariableVariableTypeField"})}function u(e){return e}function p(e){if("user"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollaboratorVariableVariableValueTypeField"})}function h(e){return{type:e.type,id:e.id}}function f(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CollaboratorVariableVariableValueField"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "CollaboratorVariableVariableValueField" to be defined'});const t=p(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "CollaboratorVariableVariableValueField" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "CollaboratorVariableVariableValueField"'});return{type:t,id:e.id}}t.CollaboratorVariable=class{constructor(e){this.type="variable",this.variableType="user_list",e.type&&(this.type=e.type),e.variableType&&(this.variableType=e.variableType),e.variableValue&&(this.variableValue=e.variableValue),e.rawData&&(this.rawData=e.rawData)}}},21048:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollectionTypeField=s,t.deserializeCollectionTypeField=a,t.serializeCollectionNameField=l,t.deserializeCollectionNameField=d,t.serializeCollectionCollectionTypeField=c,t.deserializeCollectionCollectionTypeField=u,t.serializeCollection=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name,collection_type:null==e.collectionType?void 0:e.collectionType}},t.deserializeCollection=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "Collection"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "Collection"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type),s=null==e.name?void 0:d(e.name),l=null==e.collection_type?void 0:u(e.collection_type);return{id:t,type:r,name:s,collectionType:l}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("collection"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollectionTypeField"})}function l(e){return e}function d(e){if("Favorites"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollectionNameField"})}function c(e){return e}function u(e){if("favorites"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CollectionCollectionTypeField"})}},6421:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCollectionsOrderDirectionField=c,t.deserializeCollectionsOrderDirectionField=u,t.serializeCollectionsOrderField=p,t.deserializeCollectionsOrderField=h,t.serializeCollections=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeCollection)(e)}))}},t.deserializeCollections=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Collections"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Collections"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Collections"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Collections"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Collections"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Collections"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeCollection)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(21048),n=r(21048),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CollectionsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CollectionsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "CollectionsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},87325:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCommentItemField=h,t.deserializeCommentItemField=f,t.serializeComment=function(e){const t=(0,n.serializeCommentBase)(e);if(!(0,p.sdIsMap)(t))throw new d.BoxSdkError({message:'Expecting a map for "Comment"'});return Object.assign(Object.assign({},t),{is_reply_comment:null==e.isReplyComment?void 0:e.isReplyComment,message:null==e.message?void 0:e.message,created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),item:null==e.item?void 0:h(e.item)})},t.deserializeComment=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "Comment"'});if(null!=e.is_reply_comment&&!(0,c.sdIsBoolean)(e.is_reply_comment))throw new d.BoxSdkError({message:'Expecting boolean for "is_reply_comment" of type "Comment"'});const t=null==e.is_reply_comment?void 0:e.is_reply_comment;if(null!=e.message&&!(0,u.sdIsString)(e.message))throw new d.BoxSdkError({message:'Expecting string for "message" of type "Comment"'});const r=null==e.message?void 0:e.message,n=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "Comment"'});const o=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "Comment"'});const a=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at),h=null==e.item?void 0:f(e.item);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "Comment"'});const m=null==e.id?void 0:e.id,g=null==e.type?void 0:(0,i.deserializeCommentBaseTypeField)(e.type);return{isReplyComment:t,message:r,createdBy:n,createdAt:o,modifiedAt:a,item:h,id:m,type:g}};const i=r(81564),n=r(81564),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793);function h(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function f(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "CommentItemField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "CommentItemField"'});const t=null==e.id?void 0:e.id;if(null!=e.type&&!(0,u.sdIsString)(e.type))throw new d.BoxSdkError({message:'Expecting string for "type" of type "CommentItemField"'});return{id:t,type:null==e.type?void 0:e.type}}},81564:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCommentBaseTypeField=s,t.deserializeCommentBaseTypeField=a,t.serializeCommentBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeCommentBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CommentBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "CommentBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("comment"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CommentBaseTypeField"})}},83496:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCommentFull=function(e){const t=(0,a.serializeComment)(e);if(!(0,u.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "CommentFull"'});return Object.assign(Object.assign({},t),{tagged_message:null==e.taggedMessage?void 0:e.taggedMessage})},t.deserializeCommentFull=function(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "CommentFull"'});if(null!=e.tagged_message&&!(0,c.sdIsString)(e.tagged_message))throw new l.BoxSdkError({message:'Expecting string for "tagged_message" of type "CommentFull"'});const t=null==e.tagged_message?void 0:e.tagged_message;if(null!=e.is_reply_comment&&!(0,d.sdIsBoolean)(e.is_reply_comment))throw new l.BoxSdkError({message:'Expecting boolean for "is_reply_comment" of type "CommentFull"'});const r=null==e.is_reply_comment?void 0:e.is_reply_comment;if(null!=e.message&&!(0,c.sdIsString)(e.message))throw new l.BoxSdkError({message:'Expecting string for "message" of type "CommentFull"'});const a=null==e.message?void 0:e.message,p=null==e.created_by?void 0:(0,n.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new l.BoxSdkError({message:'Expecting string for "created_at" of type "CommentFull"'});const h=null==e.created_at?void 0:(0,o.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,c.sdIsString)(e.modified_at))throw new l.BoxSdkError({message:'Expecting string for "modified_at" of type "CommentFull"'});const f=null==e.modified_at?void 0:(0,o.deserializeDateTime)(e.modified_at),m=null==e.item?void 0:(0,s.deserializeCommentItemField)(e.item);if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "CommentFull"'});const g=null==e.id?void 0:e.id,y=null==e.type?void 0:(0,i.deserializeCommentBaseTypeField)(e.type);return{taggedMessage:t,isReplyComment:r,message:a,createdBy:p,createdAt:h,modifiedAt:f,item:m,id:g,type:y}};const i=r(81564),n=r(95408),o=r(93845),s=r(87325),a=r(87325),l=r(72631),d=r(50793),c=r(50793),u=r(50793)},2346:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeCommentsOrderDirectionField=c,t.deserializeCommentsOrderDirectionField=u,t.serializeCommentsOrderField=p,t.deserializeCommentsOrderField=h,t.serializeComments=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeCommentFull)(e)}))}},t.deserializeComments=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Comments"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Comments"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Comments"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Comments"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Comments"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Comments"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeCommentFull)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(83496),n=r(83496),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize CommentsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "CommentsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "CommentsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},58524:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CompletionRuleVariable=void 0,t.serializeCompletionRuleVariableTypeField=o,t.deserializeCompletionRuleVariableTypeField=s,t.serializeCompletionRuleVariableVariableTypeField=a,t.deserializeCompletionRuleVariableVariableTypeField=l,t.serializeCompletionRuleVariableVariableValueField=d,t.deserializeCompletionRuleVariableVariableValueField=c,t.serializeCompletionRuleVariable=function(e){return{type:e.type,variable_type:e.variableType,variable_value:e.variableValue}},t.deserializeCompletionRuleVariable=function(e){if(!(0,n.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CompletionRuleVariable"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "CompletionRuleVariable" to be defined'});const t=s(e.type);if(null==e.variable_type)throw new i.BoxSdkError({message:'Expecting "variable_type" of type "CompletionRuleVariable" to be defined'});const r=l(e.variable_type);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "CompletionRuleVariable" to be defined'});const o=c(e.variable_value);return{type:t,variableType:r,variableValue:o}},t.serializeCompletionRuleVariableInput=function(e){return{type:null==e.type?void 0:e.type,variableType:null==e.variableType?void 0:e.variableType,variable_value:e.variableValue}},t.deserializeCompletionRuleVariableInput=function(e){if(!(0,n.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "CompletionRuleVariableInput"'});const t=null==e.type?void 0:s(e.type),r=null==e.variableType?void 0:l(e.variableType);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "CompletionRuleVariableInput" to be defined'});const o=c(e.variable_value);return{type:t,variableType:r,variableValue:o}};const i=r(72631),n=r(50793);function o(e){return e}function s(e){if("variable"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CompletionRuleVariableTypeField"})}function a(e){return e}function l(e){if("task_completion_rule"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CompletionRuleVariableVariableTypeField"})}function d(e){return e}function c(e){if("all_assignees"==e)return e;if("any_assignees"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize CompletionRuleVariableVariableValueField"})}t.CompletionRuleVariable=class{constructor(e){this.type="variable",this.variableType="task_completion_rule",e.type&&(this.type=e.type),e.variableType&&(this.variableType=e.variableType),e.variableValue&&(this.variableValue=e.variableValue),e.rawData&&(this.rawData=e.rawData)}}},1294:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeDevicePinnerTypeField=l,t.deserializeDevicePinnerTypeField=d,t.serializeDevicePinner=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,owned_by:null==e.ownedBy?void 0:(0,i.serializeUserMini)(e.ownedBy),product_name:null==e.productName?void 0:e.productName}},t.deserializeDevicePinner=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "DevicePinner"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "DevicePinner"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:d(e.type),i=null==e.owned_by?void 0:(0,n.deserializeUserMini)(e.owned_by);if(null!=e.product_name&&!(0,s.sdIsString)(e.product_name))throw new o.BoxSdkError({message:'Expecting string for "product_name" of type "DevicePinner"'});const l=null==e.product_name?void 0:e.product_name;return{id:t,type:r,ownedBy:i,productName:l}};const i=r(95408),n=r(95408),o=r(72631),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("device_pinner"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize DevicePinnerTypeField"})}},10931:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeDevicePinnersOrderByField=d,t.deserializeDevicePinnersOrderByField=c,t.serializeDevicePinnersOrderDirectionField=u,t.deserializeDevicePinnersOrderDirectionField=p,t.serializeDevicePinnersOrderField=h,t.deserializeDevicePinnersOrderField=f,t.serializeDevicePinners=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeDevicePinner)(e)})),limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,order:null==e.order?void 0:e.order.map((function(e){return h(e)}))}},t.deserializeDevicePinners=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "DevicePinners"'});if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "DevicePinners"'});const t=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeDevicePinner)(e)})):[];if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "DevicePinners"'});const r=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,s.sdIsNumber)(e.next_marker))throw new o.BoxSdkError({message:'Expecting number for "next_marker" of type "DevicePinners"'});const i=null==e.next_marker?void 0:e.next_marker;if(null!=e.order&&!(0,a.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "DevicePinners"'});const d=null==e.order?void 0:(0,a.sdIsList)(e.order)?e.order.map((function(e){return f(e)})):[];return{entries:t,limit:r,nextMarker:i,order:d}};const i=r(1294),n=r(1294),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("id"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize DevicePinnersOrderByField"})}function u(e){return e}function p(e){if("asc"==e)return e;if("desc"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize DevicePinnersOrderDirectionField"})}function h(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function f(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "DevicePinnersOrderField"'});return{by:null==e.by?void 0:c(e.by),direction:null==e.direction?void 0:p(e.direction)}}},99152:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEmailAliasTypeField=a,t.deserializeEmailAliasTypeField=l,t.serializeEmailAlias=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,email:null==e.email?void 0:e.email,is_confirmed:null==e.isConfirmed?void 0:e.isConfirmed}},t.deserializeEmailAlias=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "EmailAlias"'});if(null!=e.id&&!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "EmailAlias"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:l(e.type);if(null!=e.email&&!(0,o.sdIsString)(e.email))throw new i.BoxSdkError({message:'Expecting string for "email" of type "EmailAlias"'});const a=null==e.email?void 0:e.email;if(null!=e.is_confirmed&&!(0,n.sdIsBoolean)(e.is_confirmed))throw new i.BoxSdkError({message:'Expecting boolean for "is_confirmed" of type "EmailAlias"'});const d=null==e.is_confirmed?void 0:e.is_confirmed;return{id:t,type:r,email:a,isConfirmed:d}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793);function a(e){return e}function l(e){if("email_alias"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize EmailAliasTypeField"})}},50756:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEmailAliases=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeEmailAlias)(e)}))}},t.deserializeEmailAliases=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "EmailAliases"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "EmailAliases"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "EmailAliases"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeEmailAlias)(e)})):[];return{totalCount:t,entries:r}};const i=r(99152),n=r(99152),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},75762:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEnterpriseBaseTypeField=s,t.deserializeEnterpriseBaseTypeField=a,t.serializeEnterpriseBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeEnterpriseBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "EnterpriseBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "EnterpriseBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("enterprise"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize EnterpriseBaseTypeField"})}},93212:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEventEventTypeField=p,t.deserializeEventEventTypeField=h,t.serializeEventAdditionalDetailsField=f,t.deserializeEventAdditionalDetailsField=m,t.serializeEvent=function(e){return{type:null==e.type?void 0:e.type,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),recorded_at:null==e.recordedAt?void 0:(0,a.serializeDateTime)(e.recordedAt),event_id:null==e.eventId?void 0:e.eventId,created_by:null==e.createdBy?void 0:(0,i.serializeUserMini)(e.createdBy),event_type:null==e.eventType?void 0:e.eventType,session_id:null==e.sessionId?void 0:e.sessionId,source:null==e.source?void 0:(0,o.serializeAppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser)(e.source),additional_details:null==e.additionalDetails?void 0:(e.additionalDetails,{})}},t.deserializeEvent=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "Event"'});if(null!=e.type&&!(0,c.sdIsString)(e.type))throw new d.BoxSdkError({message:'Expecting string for "type" of type "Event"'});const t=null==e.type?void 0:e.type;if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "Event"'});const r=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.recorded_at&&!(0,c.sdIsString)(e.recorded_at))throw new d.BoxSdkError({message:'Expecting string for "recorded_at" of type "Event"'});const i=null==e.recorded_at?void 0:(0,l.deserializeDateTime)(e.recorded_at);if(null!=e.event_id&&!(0,c.sdIsString)(e.event_id))throw new d.BoxSdkError({message:'Expecting string for "event_id" of type "Event"'});const o=null==e.event_id?void 0:e.event_id,a=null==e.created_by?void 0:(0,n.deserializeUserMini)(e.created_by),p=null==e.event_type?void 0:h(e.event_type);if(null!=e.session_id&&!(0,c.sdIsString)(e.session_id))throw new d.BoxSdkError({message:'Expecting string for "session_id" of type "Event"'});const f=null==e.session_id?void 0:e.session_id,g=null==e.source?void 0:(0,s.deserializeAppItemEventSourceOrEventSourceOrFileOrFolderOrGenericSourceOrUser)(e.source),y=null==e.additional_details?void 0:m(e.additional_details);return{type:t,createdAt:r,recordedAt:i,eventId:o,createdBy:a,eventType:p,sessionId:f,source:g,additionalDetails:y}};const i=r(95408),n=r(95408),o=r(93148),s=r(93148),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793);function p(e){return e}function h(e){if("ACCESS_GRANTED"==e)return e;if("ACCESS_REVOKED"==e)return e;if("ADD_DEVICE_ASSOCIATION"==e)return e;if("ADD_LOGIN_ACTIVITY_DEVICE"==e)return e;if("ADMIN_LOGIN"==e)return e;if("APPLICATION_CREATED"==e)return e;if("APPLICATION_PUBLIC_KEY_ADDED"==e)return e;if("APPLICATION_PUBLIC_KEY_DELETED"==e)return e;if("CHANGE_ADMIN_ROLE"==e)return e;if("CHANGE_FOLDER_PERMISSION"==e)return e;if("COLLABORATION_ACCEPT"==e)return e;if("COLLABORATION_EXPIRATION"==e)return e;if("COLLABORATION_INVITE"==e)return e;if("COLLABORATION_REMOVE"==e)return e;if("COLLABORATION_ROLE_CHANGE"==e)return e;if("COLLAB_ADD_COLLABORATOR"==e)return e;if("COLLAB_INVITE_COLLABORATOR"==e)return e;if("COLLAB_REMOVE_COLLABORATOR"==e)return e;if("COLLAB_ROLE_CHANGE"==e)return e;if("COMMENT_CREATE"==e)return e;if("COMMENT_DELETE"==e)return e;if("CONTENT_ACCESS"==e)return e;if("CONTENT_WORKFLOW_ABNORMAL_DOWNLOAD_ACTIVITY"==e)return e;if("CONTENT_WORKFLOW_AUTOMATION_ADD"==e)return e;if("CONTENT_WORKFLOW_AUTOMATION_DELETE"==e)return e;if("CONTENT_WORKFLOW_POLICY_ADD"==e)return e;if("CONTENT_WORKFLOW_SHARING_POLICY_VIOLATION"==e)return e;if("CONTENT_WORKFLOW_UPLOAD_POLICY_VIOLATION"==e)return e;if("COPY"==e)return e;if("DATA_RETENTION_CREATE_RETENTION"==e)return e;if("DATA_RETENTION_REMOVE_RETENTION"==e)return e;if("DELETE"==e)return e;if("DELETE_USER"==e)return e;if("DEVICE_TRUST_CHECK_FAILED"==e)return e;if("DOWNLOAD"==e)return e;if("EDIT"==e)return e;if("EDIT_USER"==e)return e;if("EMAIL_ALIAS_CONFIRM"==e)return e;if("EMAIL_ALIAS_REMOVE"==e)return e;if("ENABLE_TWO_FACTOR_AUTH"==e)return e;if("ENTERPRISE_APP_AUTHORIZATION_UPDATE"==e)return e;if("FAILED_LOGIN"==e)return e;if("FILE_MARKED_MALICIOUS"==e)return e;if("FILE_WATERMARKED_DOWNLOAD"==e)return e;if("GROUP_ADD_ITEM"==e)return e;if("GROUP_ADD_USER"==e)return e;if("GROUP_CREATION"==e)return e;if("GROUP_DELETION"==e)return e;if("GROUP_EDITED"==e)return e;if("GROUP_REMOVE_ITEM"==e)return e;if("GROUP_REMOVE_USER"==e)return e;if("ITEM_COPY"==e)return e;if("ITEM_CREATE"==e)return e;if("ITEM_DOWNLOAD"==e)return e;if("ITEM_EMAIL_SEND"==e)return e;if("ITEM_MAKE_CURRENT_VERSION"==e)return e;if("ITEM_MODIFY"==e)return e;if("ITEM_MOVE"==e)return e;if("ITEM_OPEN"==e)return e;if("ITEM_PREVIEW"==e)return e;if("ITEM_RENAME"==e)return e;if("ITEM_SHARED"==e)return e;if("ITEM_SHARED_CREATE"==e)return e;if("ITEM_SHARED_UNSHARE"==e)return e;if("ITEM_SHARED_UPDATE"==e)return e;if("ITEM_SYNC"==e)return e;if("ITEM_TRASH"==e)return e;if("ITEM_UNDELETE_VIA_TRASH"==e)return e;if("ITEM_UNSYNC"==e)return e;if("ITEM_UPLOAD"==e)return e;if("LEGAL_HOLD_ASSIGNMENT_CREATE"==e)return e;if("LEGAL_HOLD_ASSIGNMENT_DELETE"==e)return e;if("LEGAL_HOLD_POLICY_CREATE"==e)return e;if("LEGAL_HOLD_POLICY_DELETE"==e)return e;if("LEGAL_HOLD_POLICY_UPDATE"==e)return e;if("LOCK"==e)return e;if("LOCK_CREATE"==e)return e;if("LOCK_DESTROY"==e)return e;if("LOGIN"==e)return e;if("MASTER_INVITE_ACCEPT"==e)return e;if("MASTER_INVITE_REJECT"==e)return e;if("METADATA_INSTANCE_CREATE"==e)return e;if("METADATA_INSTANCE_DELETE"==e)return e;if("METADATA_INSTANCE_UPDATE"==e)return e;if("METADATA_TEMPLATE_CREATE"==e)return e;if("METADATA_TEMPLATE_DELETE"==e)return e;if("METADATA_TEMPLATE_UPDATE"==e)return e;if("MOVE"==e)return e;if("NEW_USER"==e)return e;if("PREVIEW"==e)return e;if("REMOVE_DEVICE_ASSOCIATION"==e)return e;if("REMOVE_LOGIN_ACTIVITY_DEVICE"==e)return e;if("RENAME"==e)return e;if("RETENTION_POLICY_ASSIGNMENT_ADD"==e)return e;if("SHARE"==e)return e;if("SHARED_LINK_SEND"==e)return e;if("SHARE_EXPIRATION"==e)return e;if("SHIELD_ALERT"==e)return e;if("SHIELD_EXTERNAL_COLLAB_ACCESS_BLOCKED"==e)return e;if("SHIELD_EXTERNAL_COLLAB_ACCESS_BLOCKED_MISSING_JUSTIFICATION"==e)return e;if("SHIELD_EXTERNAL_COLLAB_INVITE_BLOCKED"==e)return e;if("SHIELD_EXTERNAL_COLLAB_INVITE_BLOCKED_MISSING_JUSTIFICATION"==e)return e;if("SHIELD_JUSTIFICATION_APPROVAL"==e)return e;if("SHIELD_SHARED_LINK_ACCESS_BLOCKED"==e)return e;if("SHIELD_SHARED_LINK_STATUS_RESTRICTED_ON_CREATE"==e)return e;if("SHIELD_SHARED_LINK_STATUS_RESTRICTED_ON_UPDATE"==e)return e;if("SIGN_DOCUMENT_ASSIGNED"==e)return e;if("SIGN_DOCUMENT_CANCELLED"==e)return e;if("SIGN_DOCUMENT_COMPLETED"==e)return e;if("SIGN_DOCUMENT_CONVERTED"==e)return e;if("SIGN_DOCUMENT_CREATED"==e)return e;if("SIGN_DOCUMENT_DECLINED"==e)return e;if("SIGN_DOCUMENT_EXPIRED"==e)return e;if("SIGN_DOCUMENT_SIGNED"==e)return e;if("SIGN_DOCUMENT_VIEWED_BY_SIGNED"==e)return e;if("SIGNER_DOWNLOADED"==e)return e;if("SIGNER_FORWARDED"==e)return e;if("STORAGE_EXPIRATION"==e)return e;if("TAG_ITEM_CREATE"==e)return e;if("TASK_ASSIGNMENT_CREATE"==e)return e;if("TASK_ASSIGNMENT_DELETE"==e)return e;if("TASK_ASSIGNMENT_UPDATE"==e)return e;if("TASK_CREATE"==e)return e;if("TASK_UPDATE"==e)return e;if("TERMS_OF_SERVICE_ACCEPT"==e)return e;if("TERMS_OF_SERVICE_REJECT"==e)return e;if("UNDELETE"==e)return e;if("UNLOCK"==e)return e;if("UNSHARE"==e)return e;if("UPDATE_COLLABORATION_EXPIRATION"==e)return e;if("UPDATE_SHARE_EXPIRATION"==e)return e;if("UPLOAD"==e)return e;if("USER_AUTHENTICATE_OAUTH2_ACCESS_TOKEN_CREATE"==e)return e;if("WATERMARK_LABEL_CREATE"==e)return e;if("WATERMARK_LABEL_DELETE"==e)return e;if((0,c.sdIsString)(e))return e;throw new d.BoxSdkError({message:"Can't deserialize EventEventTypeField"})}function f(e){return{}}function m(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "EventAdditionalDetailsField"'});return{}}},37973:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEventSourceItemTypeField=c,t.deserializeEventSourceItemTypeField=u,t.serializeEventSourceClassificationField=p,t.deserializeEventSourceClassificationField=h,t.serializeEventSource=function(e){return{item_type:e.itemType,item_id:e.itemId,item_name:e.itemName,classification:null==e.classification?void 0:p(e.classification),parent:null==e.parent?void 0:(0,i.serializeFolderMini)(e.parent),owned_by:null==e.ownedBy?void 0:(0,o.serializeUserMini)(e.ownedBy)}},t.deserializeEventSource=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "EventSource"'});if(null==e.item_type)throw new a.BoxSdkError({message:'Expecting "item_type" of type "EventSource" to be defined'});const t=u(e.item_type);if(null==e.item_id)throw new a.BoxSdkError({message:'Expecting "item_id" of type "EventSource" to be defined'});if(!(0,l.sdIsString)(e.item_id))throw new a.BoxSdkError({message:'Expecting string for "item_id" of type "EventSource"'});const r=e.item_id;if(null==e.item_name)throw new a.BoxSdkError({message:'Expecting "item_name" of type "EventSource" to be defined'});if(!(0,l.sdIsString)(e.item_name))throw new a.BoxSdkError({message:'Expecting string for "item_name" of type "EventSource"'});const i=e.item_name,o=null==e.classification?void 0:h(e.classification),c=null==e.parent?void 0:(0,n.deserializeFolderMini)(e.parent),p=null==e.owned_by?void 0:(0,s.deserializeUserMini)(e.owned_by);return{itemType:t,itemId:r,itemName:i,classification:o,parent:c,ownedBy:p}};const i=r(70343),n=r(70343),o=r(95408),s=r(95408),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("file"==e)return e;if("folder"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize EventSourceItemTypeField"})}function p(e){return{name:null==e.name?void 0:e.name}}function h(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "EventSourceClassificationField"'});if(null!=e.name&&!(0,l.sdIsString)(e.name))throw new a.BoxSdkError({message:'Expecting string for "name" of type "EventSourceClassificationField"'});return{name:null==e.name?void 0:e.name}}},3025:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeEventsNextStreamPositionField=c,t.deserializeEventsNextStreamPositionField=u,t.serializeEvents=function(e){return{chunk_size:null==e.chunkSize?void 0:e.chunkSize,next_stream_position:null==e.nextStreamPosition?void 0:e.nextStreamPosition,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeEvent)(e)}))}},t.deserializeEvents=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Events"'});if(null!=e.chunk_size&&!(0,s.sdIsNumber)(e.chunk_size))throw new o.BoxSdkError({message:'Expecting number for "chunk_size" of type "Events"'});const t=null==e.chunk_size?void 0:e.chunk_size,r=null==e.next_stream_position?void 0:u(e.next_stream_position);if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Events"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeEvent)(e)})):[];return{chunkSize:t,nextStreamPosition:r,entries:i}};const i=r(93212),n=r(93212),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if((0,a.sdIsString)(e))return e;if((0,s.sdIsNumber)(e))return e;throw new o.BoxSdkError({message:"Can't deserialize EventsNextStreamPositionField"})}},46022:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.File=void 0,t.serializeFilePathCollectionField=w,t.deserializeFilePathCollectionField=_,t.serializeFileSharedLinkAccessField=x,t.deserializeFileSharedLinkAccessField=S,t.serializeFileSharedLinkEffectiveAccessField=k,t.deserializeFileSharedLinkEffectiveAccessField=E,t.serializeFileSharedLinkEffectivePermissionField=T,t.deserializeFileSharedLinkEffectivePermissionField=B,t.serializeFileSharedLinkPermissionsField=C,t.deserializeFileSharedLinkPermissionsField=I,t.serializeFileSharedLinkField=A,t.deserializeFileSharedLinkField=F,t.serializeFileItemStatusField=M,t.deserializeFileItemStatusField=D,t.serializeFile=function(e){const t=(0,o.serializeFileMini)(e);if(!(0,v.sdIsMap)(t))throw new h.BoxSdkError({message:'Expecting a map for "File"'});return Object.assign(Object.assign({},t),{description:null==e.description?void 0:e.description,size:null==e.size?void 0:e.size,path_collection:null==e.pathCollection?void 0:w(e.pathCollection),created_at:null==e.createdAt?void 0:(0,c.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,c.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:(0,c.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,c.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,c.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,c.serializeDateTime)(e.contentModifiedAt),created_by:null==e.createdBy?void 0:(0,l.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,l.serializeUserMini)(e.modifiedBy),owned_by:null==e.ownedBy?void 0:(0,l.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:A(e.sharedLink),parent:null==e.parent?void 0:(0,s.serializeFolderMini)(e.parent),item_status:null==e.itemStatus?void 0:e.itemStatus})},t.deserializeFile=function(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "File"'});if(null!=e.description&&!(0,g.sdIsString)(e.description))throw new h.BoxSdkError({message:'Expecting string for "description" of type "File"'});const t=null==e.description?void 0:e.description;if(null!=e.size&&!(0,m.sdIsNumber)(e.size))throw new h.BoxSdkError({message:'Expecting number for "size" of type "File"'});const r=null==e.size?void 0:e.size,o=null==e.path_collection?void 0:_(e.path_collection);if(null!=e.created_at&&!(0,g.sdIsString)(e.created_at))throw new h.BoxSdkError({message:'Expecting string for "created_at" of type "File"'});const s=null==e.created_at?void 0:(0,u.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,g.sdIsString)(e.modified_at))throw new h.BoxSdkError({message:'Expecting string for "modified_at" of type "File"'});const l=null==e.modified_at?void 0:(0,u.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,g.sdIsString)(e.trashed_at))throw new h.BoxSdkError({message:'Expecting string for "trashed_at" of type "File"'});const c=null==e.trashed_at?void 0:(0,u.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,g.sdIsString)(e.purged_at))throw new h.BoxSdkError({message:'Expecting string for "purged_at" of type "File"'});const p=null==e.purged_at?void 0:(0,u.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,g.sdIsString)(e.content_created_at))throw new h.BoxSdkError({message:'Expecting string for "content_created_at" of type "File"'});const f=null==e.content_created_at?void 0:(0,u.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,g.sdIsString)(e.content_modified_at))throw new h.BoxSdkError({message:'Expecting string for "content_modified_at" of type "File"'});const y=null==e.content_modified_at?void 0:(0,u.deserializeDateTime)(e.content_modified_at),b=null==e.created_by?void 0:(0,d.deserializeUserMini)(e.created_by),w=null==e.modified_by?void 0:(0,d.deserializeUserMini)(e.modified_by),x=null==e.owned_by?void 0:(0,d.deserializeUserMini)(e.owned_by),S=null==e.shared_link?void 0:F(e.shared_link),k=null==e.parent?void 0:(0,a.deserializeFolderMini)(e.parent),E=null==e.item_status?void 0:D(e.item_status);if(null!=e.sequence_id&&!(0,g.sdIsString)(e.sequence_id))throw new h.BoxSdkError({message:'Expecting string for "sequence_id" of type "File"'});const T=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,g.sdIsString)(e.name))throw new h.BoxSdkError({message:'Expecting string for "name" of type "File"'});const B=null==e.name?void 0:e.name;if(null!=e.sha1&&!(0,g.sdIsString)(e.sha1))throw new h.BoxSdkError({message:'Expecting string for "sha1" of type "File"'});const C=null==e.sha1?void 0:e.sha1,I=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.id)throw new h.BoxSdkError({message:'Expecting "id" of type "File" to be defined'});if(!(0,g.sdIsString)(e.id))throw new h.BoxSdkError({message:'Expecting string for "id" of type "File"'});const A=e.id;if(null!=e.etag&&!(0,g.sdIsString)(e.etag))throw new h.BoxSdkError({message:'Expecting string for "etag" of type "File"'});const M=null==e.etag?void 0:e.etag;if(null==e.type)throw new h.BoxSdkError({message:'Expecting "type" of type "File" to be defined'});const R=(0,i.deserializeFileBaseTypeField)(e.type);return{description:t,size:r,pathCollection:o,createdAt:s,modifiedAt:l,trashedAt:c,purgedAt:p,contentCreatedAt:f,contentModifiedAt:y,createdBy:b,modifiedBy:w,ownedBy:x,sharedLink:S,parent:k,itemStatus:E,sequenceId:T,name:B,sha1:C,fileVersion:I,id:A,etag:M,type:R}};const i=r(39455),n=r(95053),o=r(62929),s=r(70343),a=r(70343),l=r(95408),d=r(95408),c=r(93845),u=r(93845),p=r(62929),h=r(72631),f=r(50793),m=r(50793),g=r(50793),y=r(50793),v=r(50793);class b extends p.FileMini{constructor(e){super(e)}}function w(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,s.serializeFolderMini)(e)}))}}function _(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FilePathCollectionField"'});if(null==e.total_count)throw new h.BoxSdkError({message:'Expecting "total_count" of type "FilePathCollectionField" to be defined'});if(!(0,m.sdIsNumber)(e.total_count))throw new h.BoxSdkError({message:'Expecting number for "total_count" of type "FilePathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new h.BoxSdkError({message:'Expecting "entries" of type "FilePathCollectionField" to be defined'});if(!(0,y.sdIsList)(e.entries))throw new h.BoxSdkError({message:'Expecting array for "entries" of type "FilePathCollectionField"'});return{totalCount:t,entries:(0,y.sdIsList)(e.entries)?e.entries.map((function(e){return(0,a.deserializeFolderMini)(e)})):[]}}function x(e){return e}function S(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FileSharedLinkAccessField"})}function k(e){return e}function E(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FileSharedLinkEffectiveAccessField"})}function T(e){return e}function B(e){if("can_edit"==e)return e;if("can_download"==e)return e;if("can_preview"==e)return e;if("no_access"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FileSharedLinkEffectivePermissionField"})}function C(e){return{can_download:e.canDownload,can_preview:e.canPreview,can_edit:e.canEdit}}function I(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FileSharedLinkPermissionsField"'});if(null==e.can_download)throw new h.BoxSdkError({message:'Expecting "can_download" of type "FileSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_download))throw new h.BoxSdkError({message:'Expecting boolean for "can_download" of type "FileSharedLinkPermissionsField"'});const t=e.can_download;if(null==e.can_preview)throw new h.BoxSdkError({message:'Expecting "can_preview" of type "FileSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_preview))throw new h.BoxSdkError({message:'Expecting boolean for "can_preview" of type "FileSharedLinkPermissionsField"'});const r=e.can_preview;if(null==e.can_edit)throw new h.BoxSdkError({message:'Expecting "can_edit" of type "FileSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_edit))throw new h.BoxSdkError({message:'Expecting boolean for "can_edit" of type "FileSharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:e.can_edit}}function A(e){return{url:e.url,download_url:null==e.downloadUrl?void 0:e.downloadUrl,vanity_url:null==e.vanityUrl?void 0:e.vanityUrl,vanity_name:null==e.vanityName?void 0:e.vanityName,access:null==e.access?void 0:e.access,effective_access:e.effectiveAccess,effective_permission:e.effectivePermission,unshared_at:null==e.unsharedAt?void 0:(0,c.serializeDateTime)(e.unsharedAt),is_password_enabled:e.isPasswordEnabled,permissions:null==e.permissions?void 0:C(e.permissions),download_count:e.downloadCount,preview_count:e.previewCount}}function F(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FileSharedLinkField"'});if(null==e.url)throw new h.BoxSdkError({message:'Expecting "url" of type "FileSharedLinkField" to be defined'});if(!(0,g.sdIsString)(e.url))throw new h.BoxSdkError({message:'Expecting string for "url" of type "FileSharedLinkField"'});const t=e.url;if(null!=e.download_url&&!(0,g.sdIsString)(e.download_url))throw new h.BoxSdkError({message:'Expecting string for "download_url" of type "FileSharedLinkField"'});const r=null==e.download_url?void 0:e.download_url;if(null!=e.vanity_url&&!(0,g.sdIsString)(e.vanity_url))throw new h.BoxSdkError({message:'Expecting string for "vanity_url" of type "FileSharedLinkField"'});const i=null==e.vanity_url?void 0:e.vanity_url;if(null!=e.vanity_name&&!(0,g.sdIsString)(e.vanity_name))throw new h.BoxSdkError({message:'Expecting string for "vanity_name" of type "FileSharedLinkField"'});const n=null==e.vanity_name?void 0:e.vanity_name,o=null==e.access?void 0:S(e.access);if(null==e.effective_access)throw new h.BoxSdkError({message:'Expecting "effective_access" of type "FileSharedLinkField" to be defined'});const s=E(e.effective_access);if(null==e.effective_permission)throw new h.BoxSdkError({message:'Expecting "effective_permission" of type "FileSharedLinkField" to be defined'});const a=B(e.effective_permission);if(null!=e.unshared_at&&!(0,g.sdIsString)(e.unshared_at))throw new h.BoxSdkError({message:'Expecting string for "unshared_at" of type "FileSharedLinkField"'});const l=null==e.unshared_at?void 0:(0,u.deserializeDateTime)(e.unshared_at);if(null==e.is_password_enabled)throw new h.BoxSdkError({message:'Expecting "is_password_enabled" of type "FileSharedLinkField" to be defined'});if(!(0,f.sdIsBoolean)(e.is_password_enabled))throw new h.BoxSdkError({message:'Expecting boolean for "is_password_enabled" of type "FileSharedLinkField"'});const d=e.is_password_enabled,c=null==e.permissions?void 0:I(e.permissions);if(null==e.download_count)throw new h.BoxSdkError({message:'Expecting "download_count" of type "FileSharedLinkField" to be defined'});if(!(0,m.sdIsNumber)(e.download_count))throw new h.BoxSdkError({message:'Expecting number for "download_count" of type "FileSharedLinkField"'});const p=e.download_count;if(null==e.preview_count)throw new h.BoxSdkError({message:'Expecting "preview_count" of type "FileSharedLinkField" to be defined'});if(!(0,m.sdIsNumber)(e.preview_count))throw new h.BoxSdkError({message:'Expecting number for "preview_count" of type "FileSharedLinkField"'});return{url:t,downloadUrl:r,vanityUrl:i,vanityName:n,access:o,effectiveAccess:s,effectivePermission:a,unsharedAt:l,isPasswordEnabled:d,permissions:c,downloadCount:p,previewCount:e.preview_count}}function M(e){return e}function D(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FileItemStatusField"})}t.File=b},39455:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileBase=void 0,t.serializeFileBaseTypeField=s,t.deserializeFileBaseTypeField=a,t.serializeFileBase=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:e.type}},t.deserializeFileBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FileBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FileBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FileBase"'});const t=e.id;if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "FileBase"'});const r=null==e.etag?void 0:e.etag;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "FileBase" to be defined'});const s=a(e.type);return{id:t,etag:r,type:s}},t.serializeFileBaseInput=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type}},t.deserializeFileBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FileBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FileBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FileBaseInput"'});const t=e.id;if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "FileBaseInput"'});const r=null==e.etag?void 0:e.etag,s=null==e.type?void 0:a(e.type);return{id:t,etag:r,type:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("file"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize FileBaseTypeField"})}t.FileBase=class{constructor(e){this.type="file",e.id&&(this.id=e.id),e.etag&&(this.etag=e.etag),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},1197:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileBaseOrFolderBaseOrWebLinkBase=function(e){if("file"==e.type)return(0,i.serializeFileBase)(e);if("folder"==e.type)return(0,o.serializeFolderBase)(e);if("web_link"==e.type)return(0,a.serializeWebLinkBase)(e);throw new d.BoxSdkError({message:"unknown type"})},t.deserializeFileBaseOrFolderBaseOrWebLinkBase=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileBaseOrFolderBaseOrWebLinkBase"'});if("file"==e.type)return(0,n.deserializeFileBase)(e);if("folder"==e.type)return(0,s.deserializeFolderBase)(e);if("web_link"==e.type)return(0,l.deserializeWebLinkBase)(e);throw new d.BoxSdkError({message:"Can't deserialize FileBaseOrFolderBaseOrWebLinkBase"})};const i=r(39455),n=r(39455),o=r(64145),s=r(64145),a=r(3719),l=r(3719),d=r(72631),c=r(50793)},49579:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileFull=void 0,t.serializeFileFullPermissionsField=E,t.deserializeFileFullPermissionsField=T,t.serializeFileFullLockTypeField=B,t.deserializeFileFullLockTypeField=C,t.serializeFileFullLockAppTypeField=I,t.deserializeFileFullLockAppTypeField=A,t.serializeFileFullLockField=F,t.deserializeFileFullLockField=M,t.serializeFileFullExpiringEmbedLinkTokenTypeField=D,t.deserializeFileFullExpiringEmbedLinkTokenTypeField=R,t.serializeFileFullExpiringEmbedLinkField=P,t.deserializeFileFullExpiringEmbedLinkField=O,t.serializeFileFullWatermarkInfoField=z,t.deserializeFileFullWatermarkInfoField=N,t.serializeFileFullAllowedInviteeRolesField=q,t.deserializeFileFullAllowedInviteeRolesField=U,t.serializeFileFullMetadataField=L,t.deserializeFileFullMetadataField=j,t.serializeFileFullRepresentationsEntriesContentField=H,t.deserializeFileFullRepresentationsEntriesContentField=$,t.serializeFileFullRepresentationsEntriesInfoField=G,t.deserializeFileFullRepresentationsEntriesInfoField=W,t.serializeFileFullRepresentationsEntriesPropertiesField=K,t.deserializeFileFullRepresentationsEntriesPropertiesField=V,t.serializeFileFullRepresentationsEntriesStatusStateField=J,t.deserializeFileFullRepresentationsEntriesStatusStateField=Y,t.serializeFileFullRepresentationsEntriesStatusField=Q,t.deserializeFileFullRepresentationsEntriesStatusField=Z,t.serializeFileFullRepresentationsEntriesField=X,t.deserializeFileFullRepresentationsEntriesField=ee,t.serializeFileFullRepresentationsField=te,t.deserializeFileFullRepresentationsField=re,t.serializeFileFullClassificationField=ie,t.deserializeFileFullClassificationField=ne,t.serializeFileFullSharedLinkPermissionOptionsField=oe,t.deserializeFileFullSharedLinkPermissionOptionsField=se,t.serializeFileFull=function(e){const t=(0,d.serializeFile)(e);if(!(0,S.sdIsMap)(t))throw new v.BoxSdkError({message:'Expecting a map for "FileFull"'});return Object.assign(Object.assign({},t),{version_number:null==e.versionNumber?void 0:e.versionNumber,comment_count:null==e.commentCount?void 0:e.commentCount,permissions:null==e.permissions?void 0:E(e.permissions),tags:null==e.tags?void 0:e.tags.map((function(e){return e})),lock:null==e.lock?void 0:F(e.lock),extension:null==e.extension?void 0:e.extension,is_package:null==e.isPackage?void 0:e.isPackage,expiring_embed_link:null==e.expiringEmbedLink?void 0:P(e.expiringEmbedLink),watermark_info:null==e.watermarkInfo?void 0:z(e.watermarkInfo),is_accessible_via_shared_link:null==e.isAccessibleViaSharedLink?void 0:e.isAccessibleViaSharedLink,allowed_invitee_roles:null==e.allowedInviteeRoles?void 0:e.allowedInviteeRoles.map((function(e){return e})),is_externally_owned:null==e.isExternallyOwned?void 0:e.isExternallyOwned,has_collaborations:null==e.hasCollaborations?void 0:e.hasCollaborations,metadata:null==e.metadata?void 0:L(e.metadata),expires_at:null==e.expiresAt?void 0:(0,m.serializeDateTime)(e.expiresAt),representations:null==e.representations?void 0:te(e.representations),classification:null==e.classification?void 0:ie(e.classification),uploader_display_name:null==e.uploaderDisplayName?void 0:e.uploaderDisplayName,disposition_at:null==e.dispositionAt?void 0:(0,m.serializeDateTime)(e.dispositionAt),shared_link_permission_options:null==e.sharedLinkPermissionOptions?void 0:e.sharedLinkPermissionOptions.map((function(e){return e})),is_associated_with_app_item:null==e.isAssociatedWithAppItem?void 0:e.isAssociatedWithAppItem})},t.deserializeFileFull=function(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFull"'});if(null!=e.version_number&&!(0,_.sdIsString)(e.version_number))throw new v.BoxSdkError({message:'Expecting string for "version_number" of type "FileFull"'});const t=null==e.version_number?void 0:e.version_number;if(null!=e.comment_count&&!(0,w.sdIsNumber)(e.comment_count))throw new v.BoxSdkError({message:'Expecting number for "comment_count" of type "FileFull"'});const r=null==e.comment_count?void 0:e.comment_count,d=null==e.permissions?void 0:T(e.permissions);if(null!=e.tags&&!(0,x.sdIsList)(e.tags))throw new v.BoxSdkError({message:'Expecting array for "tags" of type "FileFull"'});const c=null==e.tags?void 0:(0,x.sdIsList)(e.tags)?e.tags.map((function(e){if(!(0,_.sdIsString)(e))throw new v.BoxSdkError({message:'Expecting string for "FileFull"'});return e})):[],p=null==e.lock?void 0:M(e.lock);if(null!=e.extension&&!(0,_.sdIsString)(e.extension))throw new v.BoxSdkError({message:'Expecting string for "extension" of type "FileFull"'});const h=null==e.extension?void 0:e.extension;if(null!=e.is_package&&!(0,b.sdIsBoolean)(e.is_package))throw new v.BoxSdkError({message:'Expecting boolean for "is_package" of type "FileFull"'});const f=null==e.is_package?void 0:e.is_package,m=null==e.expiring_embed_link?void 0:O(e.expiring_embed_link),y=null==e.watermark_info?void 0:N(e.watermark_info);if(null!=e.is_accessible_via_shared_link&&!(0,b.sdIsBoolean)(e.is_accessible_via_shared_link))throw new v.BoxSdkError({message:'Expecting boolean for "is_accessible_via_shared_link" of type "FileFull"'});const k=null==e.is_accessible_via_shared_link?void 0:e.is_accessible_via_shared_link;if(null!=e.allowed_invitee_roles&&!(0,x.sdIsList)(e.allowed_invitee_roles))throw new v.BoxSdkError({message:'Expecting array for "allowed_invitee_roles" of type "FileFull"'});const E=null==e.allowed_invitee_roles?void 0:(0,x.sdIsList)(e.allowed_invitee_roles)?e.allowed_invitee_roles.map((function(e){return U(e)})):[];if(null!=e.is_externally_owned&&!(0,b.sdIsBoolean)(e.is_externally_owned))throw new v.BoxSdkError({message:'Expecting boolean for "is_externally_owned" of type "FileFull"'});const B=null==e.is_externally_owned?void 0:e.is_externally_owned;if(null!=e.has_collaborations&&!(0,b.sdIsBoolean)(e.has_collaborations))throw new v.BoxSdkError({message:'Expecting boolean for "has_collaborations" of type "FileFull"'});const C=null==e.has_collaborations?void 0:e.has_collaborations,I=null==e.metadata?void 0:j(e.metadata);if(null!=e.expires_at&&!(0,_.sdIsString)(e.expires_at))throw new v.BoxSdkError({message:'Expecting string for "expires_at" of type "FileFull"'});const A=null==e.expires_at?void 0:(0,g.deserializeDateTime)(e.expires_at),F=null==e.representations?void 0:re(e.representations),D=null==e.classification?void 0:ne(e.classification);if(null!=e.uploader_display_name&&!(0,_.sdIsString)(e.uploader_display_name))throw new v.BoxSdkError({message:'Expecting string for "uploader_display_name" of type "FileFull"'});const R=null==e.uploader_display_name?void 0:e.uploader_display_name;if(null!=e.disposition_at&&!(0,_.sdIsString)(e.disposition_at))throw new v.BoxSdkError({message:'Expecting string for "disposition_at" of type "FileFull"'});const P=null==e.disposition_at?void 0:(0,g.deserializeDateTime)(e.disposition_at);if(null!=e.shared_link_permission_options&&!(0,x.sdIsList)(e.shared_link_permission_options))throw new v.BoxSdkError({message:'Expecting array for "shared_link_permission_options" of type "FileFull"'});const z=null==e.shared_link_permission_options?void 0:(0,x.sdIsList)(e.shared_link_permission_options)?e.shared_link_permission_options.map((function(e){return se(e)})):[];if(null!=e.is_associated_with_app_item&&!(0,b.sdIsBoolean)(e.is_associated_with_app_item))throw new v.BoxSdkError({message:'Expecting boolean for "is_associated_with_app_item" of type "FileFull"'});const q=null==e.is_associated_with_app_item?void 0:e.is_associated_with_app_item;if(null!=e.description&&!(0,_.sdIsString)(e.description))throw new v.BoxSdkError({message:'Expecting string for "description" of type "FileFull"'});const L=null==e.description?void 0:e.description;if(null!=e.size&&!(0,w.sdIsNumber)(e.size))throw new v.BoxSdkError({message:'Expecting number for "size" of type "FileFull"'});const H=null==e.size?void 0:e.size,$=null==e.path_collection?void 0:(0,o.deserializeFilePathCollectionField)(e.path_collection);if(null!=e.created_at&&!(0,_.sdIsString)(e.created_at))throw new v.BoxSdkError({message:'Expecting string for "created_at" of type "FileFull"'});const G=null==e.created_at?void 0:(0,g.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,_.sdIsString)(e.modified_at))throw new v.BoxSdkError({message:'Expecting string for "modified_at" of type "FileFull"'});const W=null==e.modified_at?void 0:(0,g.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,_.sdIsString)(e.trashed_at))throw new v.BoxSdkError({message:'Expecting string for "trashed_at" of type "FileFull"'});const K=null==e.trashed_at?void 0:(0,g.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,_.sdIsString)(e.purged_at))throw new v.BoxSdkError({message:'Expecting string for "purged_at" of type "FileFull"'});const V=null==e.purged_at?void 0:(0,g.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,_.sdIsString)(e.content_created_at))throw new v.BoxSdkError({message:'Expecting string for "content_created_at" of type "FileFull"'});const J=null==e.content_created_at?void 0:(0,g.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,_.sdIsString)(e.content_modified_at))throw new v.BoxSdkError({message:'Expecting string for "content_modified_at" of type "FileFull"'});const Y=null==e.content_modified_at?void 0:(0,g.deserializeDateTime)(e.content_modified_at),Q=null==e.created_by?void 0:(0,u.deserializeUserMini)(e.created_by),Z=null==e.modified_by?void 0:(0,u.deserializeUserMini)(e.modified_by),X=null==e.owned_by?void 0:(0,u.deserializeUserMini)(e.owned_by),ee=null==e.shared_link?void 0:(0,s.deserializeFileSharedLinkField)(e.shared_link),te=null==e.parent?void 0:(0,a.deserializeFolderMini)(e.parent),ie=null==e.item_status?void 0:(0,l.deserializeFileItemStatusField)(e.item_status);if(null!=e.sequence_id&&!(0,_.sdIsString)(e.sequence_id))throw new v.BoxSdkError({message:'Expecting string for "sequence_id" of type "FileFull"'});const oe=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,_.sdIsString)(e.name))throw new v.BoxSdkError({message:'Expecting string for "name" of type "FileFull"'});const ae=null==e.name?void 0:e.name;if(null!=e.sha1&&!(0,_.sdIsString)(e.sha1))throw new v.BoxSdkError({message:'Expecting string for "sha1" of type "FileFull"'});const le=null==e.sha1?void 0:e.sha1,de=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.id)throw new v.BoxSdkError({message:'Expecting "id" of type "FileFull" to be defined'});if(!(0,_.sdIsString)(e.id))throw new v.BoxSdkError({message:'Expecting string for "id" of type "FileFull"'});const ce=e.id;if(null!=e.etag&&!(0,_.sdIsString)(e.etag))throw new v.BoxSdkError({message:'Expecting string for "etag" of type "FileFull"'});const ue=null==e.etag?void 0:e.etag;if(null==e.type)throw new v.BoxSdkError({message:'Expecting "type" of type "FileFull" to be defined'});const pe=(0,i.deserializeFileBaseTypeField)(e.type);return{versionNumber:t,commentCount:r,permissions:d,tags:c,lock:p,extension:h,isPackage:f,expiringEmbedLink:m,watermarkInfo:y,isAccessibleViaSharedLink:k,allowedInviteeRoles:E,isExternallyOwned:B,hasCollaborations:C,metadata:I,expiresAt:A,representations:F,classification:D,uploaderDisplayName:R,dispositionAt:P,sharedLinkPermissionOptions:z,isAssociatedWithAppItem:q,description:L,size:H,pathCollection:$,createdAt:G,modifiedAt:W,trashedAt:K,purgedAt:V,contentCreatedAt:J,contentModifiedAt:Y,createdBy:Q,modifiedBy:Z,ownedBy:X,sharedLink:ee,parent:te,itemStatus:ie,sequenceId:oe,name:ae,sha1:le,fileVersion:de,id:ce,etag:ue,type:pe}};const i=r(39455),n=r(95053),o=r(46022),s=r(46022),a=r(70343),l=r(46022),d=r(46022),c=r(95408),u=r(95408),p=r(77733),h=r(77733),f=r(70376),m=r(93845),g=r(93845),y=r(46022),v=r(72631),b=r(50793),w=r(50793),_=r(50793),x=r(50793),S=r(50793);class k extends y.File{constructor(e){super(e)}}function E(e){return{can_delete:e.canDelete,can_download:e.canDownload,can_invite_collaborator:e.canInviteCollaborator,can_rename:e.canRename,can_set_share_access:e.canSetShareAccess,can_share:e.canShare,can_annotate:e.canAnnotate,can_comment:e.canComment,can_preview:e.canPreview,can_upload:e.canUpload,can_view_annotations_all:e.canViewAnnotationsAll,can_view_annotations_self:e.canViewAnnotationsSelf}}function T(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullPermissionsField"'});if(null==e.can_delete)throw new v.BoxSdkError({message:'Expecting "can_delete" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_delete))throw new v.BoxSdkError({message:'Expecting boolean for "can_delete" of type "FileFullPermissionsField"'});const t=e.can_delete;if(null==e.can_download)throw new v.BoxSdkError({message:'Expecting "can_download" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_download))throw new v.BoxSdkError({message:'Expecting boolean for "can_download" of type "FileFullPermissionsField"'});const r=e.can_download;if(null==e.can_invite_collaborator)throw new v.BoxSdkError({message:'Expecting "can_invite_collaborator" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_invite_collaborator))throw new v.BoxSdkError({message:'Expecting boolean for "can_invite_collaborator" of type "FileFullPermissionsField"'});const i=e.can_invite_collaborator;if(null==e.can_rename)throw new v.BoxSdkError({message:'Expecting "can_rename" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_rename))throw new v.BoxSdkError({message:'Expecting boolean for "can_rename" of type "FileFullPermissionsField"'});const n=e.can_rename;if(null==e.can_set_share_access)throw new v.BoxSdkError({message:'Expecting "can_set_share_access" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_set_share_access))throw new v.BoxSdkError({message:'Expecting boolean for "can_set_share_access" of type "FileFullPermissionsField"'});const o=e.can_set_share_access;if(null==e.can_share)throw new v.BoxSdkError({message:'Expecting "can_share" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_share))throw new v.BoxSdkError({message:'Expecting boolean for "can_share" of type "FileFullPermissionsField"'});const s=e.can_share;if(null==e.can_annotate)throw new v.BoxSdkError({message:'Expecting "can_annotate" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_annotate))throw new v.BoxSdkError({message:'Expecting boolean for "can_annotate" of type "FileFullPermissionsField"'});const a=e.can_annotate;if(null==e.can_comment)throw new v.BoxSdkError({message:'Expecting "can_comment" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_comment))throw new v.BoxSdkError({message:'Expecting boolean for "can_comment" of type "FileFullPermissionsField"'});const l=e.can_comment;if(null==e.can_preview)throw new v.BoxSdkError({message:'Expecting "can_preview" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_preview))throw new v.BoxSdkError({message:'Expecting boolean for "can_preview" of type "FileFullPermissionsField"'});const d=e.can_preview;if(null==e.can_upload)throw new v.BoxSdkError({message:'Expecting "can_upload" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_upload))throw new v.BoxSdkError({message:'Expecting boolean for "can_upload" of type "FileFullPermissionsField"'});const c=e.can_upload;if(null==e.can_view_annotations_all)throw new v.BoxSdkError({message:'Expecting "can_view_annotations_all" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_view_annotations_all))throw new v.BoxSdkError({message:'Expecting boolean for "can_view_annotations_all" of type "FileFullPermissionsField"'});const u=e.can_view_annotations_all;if(null==e.can_view_annotations_self)throw new v.BoxSdkError({message:'Expecting "can_view_annotations_self" of type "FileFullPermissionsField" to be defined'});if(!(0,b.sdIsBoolean)(e.can_view_annotations_self))throw new v.BoxSdkError({message:'Expecting boolean for "can_view_annotations_self" of type "FileFullPermissionsField"'});return{canDelete:t,canDownload:r,canInviteCollaborator:i,canRename:n,canSetShareAccess:o,canShare:s,canAnnotate:a,canComment:l,canPreview:d,canUpload:c,canViewAnnotationsAll:u,canViewAnnotationsSelf:e.can_view_annotations_self}}function B(e){return e}function C(e){if("lock"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullLockTypeField"})}function I(e){return e}function A(e){if("gsuite"==e)return e;if("office_wopi"==e)return e;if("office_wopiplus"==e)return e;if("other"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullLockAppTypeField"})}function F(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,created_by:null==e.createdBy?void 0:(0,c.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,m.serializeDateTime)(e.createdAt),expired_at:null==e.expiredAt?void 0:(0,m.serializeDateTime)(e.expiredAt),is_download_prevented:null==e.isDownloadPrevented?void 0:e.isDownloadPrevented,app_type:null==e.appType?void 0:e.appType}}function M(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullLockField"'});if(null!=e.id&&!(0,_.sdIsString)(e.id))throw new v.BoxSdkError({message:'Expecting string for "id" of type "FileFullLockField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:C(e.type),i=null==e.created_by?void 0:(0,u.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,_.sdIsString)(e.created_at))throw new v.BoxSdkError({message:'Expecting string for "created_at" of type "FileFullLockField"'});const n=null==e.created_at?void 0:(0,g.deserializeDateTime)(e.created_at);if(null!=e.expired_at&&!(0,_.sdIsString)(e.expired_at))throw new v.BoxSdkError({message:'Expecting string for "expired_at" of type "FileFullLockField"'});const o=null==e.expired_at?void 0:(0,g.deserializeDateTime)(e.expired_at);if(null!=e.is_download_prevented&&!(0,b.sdIsBoolean)(e.is_download_prevented))throw new v.BoxSdkError({message:'Expecting boolean for "is_download_prevented" of type "FileFullLockField"'});return{id:t,type:r,createdBy:i,createdAt:n,expiredAt:o,isDownloadPrevented:null==e.is_download_prevented?void 0:e.is_download_prevented,appType:null==e.app_type?void 0:A(e.app_type)}}function D(e){return e}function R(e){if("bearer"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullExpiringEmbedLinkTokenTypeField"})}function P(e){return{access_token:null==e.accessToken?void 0:e.accessToken,expires_in:null==e.expiresIn?void 0:e.expiresIn,token_type:null==e.tokenType?void 0:e.tokenType,restricted_to:null==e.restrictedTo?void 0:e.restrictedTo.map((function(e){return(0,p.serializeFileOrFolderScope)(e)})),url:null==e.url?void 0:e.url}}function O(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullExpiringEmbedLinkField"'});if(null!=e.access_token&&!(0,_.sdIsString)(e.access_token))throw new v.BoxSdkError({message:'Expecting string for "access_token" of type "FileFullExpiringEmbedLinkField"'});const t=null==e.access_token?void 0:e.access_token;if(null!=e.expires_in&&!(0,w.sdIsNumber)(e.expires_in))throw new v.BoxSdkError({message:'Expecting number for "expires_in" of type "FileFullExpiringEmbedLinkField"'});const r=null==e.expires_in?void 0:e.expires_in,i=null==e.token_type?void 0:R(e.token_type);if(null!=e.restricted_to&&!(0,x.sdIsList)(e.restricted_to))throw new v.BoxSdkError({message:'Expecting array for "restricted_to" of type "FileFullExpiringEmbedLinkField"'});const n=null==e.restricted_to?void 0:(0,x.sdIsList)(e.restricted_to)?e.restricted_to.map((function(e){return(0,h.deserializeFileOrFolderScope)(e)})):[];if(null!=e.url&&!(0,_.sdIsString)(e.url))throw new v.BoxSdkError({message:'Expecting string for "url" of type "FileFullExpiringEmbedLinkField"'});return{accessToken:t,expiresIn:r,tokenType:i,restrictedTo:n,url:null==e.url?void 0:e.url}}function z(e){return{is_watermarked:null==e.isWatermarked?void 0:e.isWatermarked}}function N(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullWatermarkInfoField"'});if(null!=e.is_watermarked&&!(0,b.sdIsBoolean)(e.is_watermarked))throw new v.BoxSdkError({message:'Expecting boolean for "is_watermarked" of type "FileFullWatermarkInfoField"'});return{isWatermarked:null==e.is_watermarked?void 0:e.is_watermarked}}function q(e){return e}function U(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullAllowedInviteeRolesField"})}function L(e){return Object.assign({},e.extraData)}function j(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullMetadataField"'});if(null!=e&&!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting object for "extraData" of type "FileFullMetadataField"'});return{extraData:null==e?void 0:(0,S.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,function(e){return(0,S.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,(0,f.deserializeMetadataFull)(t)]))):{}}(t)]))):{}}}function H(e){return{url_template:null==e.urlTemplate?void 0:e.urlTemplate}}function $(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsEntriesContentField"'});if(null!=e.url_template&&!(0,_.sdIsString)(e.url_template))throw new v.BoxSdkError({message:'Expecting string for "url_template" of type "FileFullRepresentationsEntriesContentField"'});return{urlTemplate:null==e.url_template?void 0:e.url_template}}function G(e){return{url:null==e.url?void 0:e.url}}function W(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsEntriesInfoField"'});if(null!=e.url&&!(0,_.sdIsString)(e.url))throw new v.BoxSdkError({message:'Expecting string for "url" of type "FileFullRepresentationsEntriesInfoField"'});return{url:null==e.url?void 0:e.url}}function K(e){return{dimensions:null==e.dimensions?void 0:e.dimensions,paged:null==e.paged?void 0:e.paged,thumb:null==e.thumb?void 0:e.thumb}}function V(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsEntriesPropertiesField"'});if(null!=e.dimensions&&!(0,_.sdIsString)(e.dimensions))throw new v.BoxSdkError({message:'Expecting string for "dimensions" of type "FileFullRepresentationsEntriesPropertiesField"'});const t=null==e.dimensions?void 0:e.dimensions;if(null!=e.paged&&!(0,b.sdIsBoolean)(e.paged))throw new v.BoxSdkError({message:'Expecting boolean for "paged" of type "FileFullRepresentationsEntriesPropertiesField"'});const r=null==e.paged?void 0:e.paged;if(null!=e.thumb&&!(0,b.sdIsBoolean)(e.thumb))throw new v.BoxSdkError({message:'Expecting boolean for "thumb" of type "FileFullRepresentationsEntriesPropertiesField"'});return{dimensions:t,paged:r,thumb:null==e.thumb?void 0:e.thumb}}function J(e){return e}function Y(e){if("success"==e)return e;if("viewable"==e)return e;if("pending"==e)return e;if("none"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullRepresentationsEntriesStatusStateField"})}function Q(e){return{state:null==e.state?void 0:e.state}}function Z(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsEntriesStatusField"'});return{state:null==e.state?void 0:Y(e.state)}}function X(e){return{content:null==e.content?void 0:H(e.content),info:null==e.info?void 0:G(e.info),properties:null==e.properties?void 0:K(e.properties),representation:null==e.representation?void 0:e.representation,status:null==e.status?void 0:Q(e.status)}}function ee(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsEntriesField"'});const t=null==e.content?void 0:$(e.content),r=null==e.info?void 0:W(e.info),i=null==e.properties?void 0:V(e.properties);if(null!=e.representation&&!(0,_.sdIsString)(e.representation))throw new v.BoxSdkError({message:'Expecting string for "representation" of type "FileFullRepresentationsEntriesField"'});return{content:t,info:r,properties:i,representation:null==e.representation?void 0:e.representation,status:null==e.status?void 0:Z(e.status)}}function te(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return X(e)}))}}function re(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullRepresentationsField"'});if(null!=e.entries&&!(0,x.sdIsList)(e.entries))throw new v.BoxSdkError({message:'Expecting array for "entries" of type "FileFullRepresentationsField"'});return{entries:null==e.entries?void 0:(0,x.sdIsList)(e.entries)?e.entries.map((function(e){return ee(e)})):[]}}function ie(e){return{name:null==e.name?void 0:e.name,definition:null==e.definition?void 0:e.definition,color:null==e.color?void 0:e.color}}function ne(e){if(!(0,S.sdIsMap)(e))throw new v.BoxSdkError({message:'Expecting a map for "FileFullClassificationField"'});if(null!=e.name&&!(0,_.sdIsString)(e.name))throw new v.BoxSdkError({message:'Expecting string for "name" of type "FileFullClassificationField"'});const t=null==e.name?void 0:e.name;if(null!=e.definition&&!(0,_.sdIsString)(e.definition))throw new v.BoxSdkError({message:'Expecting string for "definition" of type "FileFullClassificationField"'});const r=null==e.definition?void 0:e.definition;if(null!=e.color&&!(0,_.sdIsString)(e.color))throw new v.BoxSdkError({message:'Expecting string for "color" of type "FileFullClassificationField"'});return{name:t,definition:r,color:null==e.color?void 0:e.color}}function oe(e){return e}function se(e){if("can_preview"==e)return e;if("can_download"==e)return e;if("can_edit"==e)return e;throw new v.BoxSdkError({message:"Can't deserialize FileFullSharedLinkPermissionOptionsField"})}t.FileFull=k},19291:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileFullOrFolderFull=function(e){if("file"==e.type)return(0,i.serializeFileFull)(e);if("folder"==e.type)return(0,o.serializeFolderFull)(e);throw new a.BoxSdkError({message:"unknown type"})},t.deserializeFileFullOrFolderFull=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "FileFullOrFolderFull"'});if("file"==e.type)return(0,n.deserializeFileFull)(e);if("folder"==e.type)return(0,s.deserializeFolderFull)(e);throw new a.BoxSdkError({message:"Can't deserialize FileFullOrFolderFull"})};const i=r(49579),n=r(49579),o=r(34537),s=r(34537),a=r(72631),l=r(50793)},58820:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileFullOrFolderFullOrWebLink=function(e){if("file"==e.type)return(0,i.serializeFileFull)(e);if("folder"==e.type)return(0,o.serializeFolderFull)(e);if("web_link"==e.type)return(0,a.serializeWebLink)(e);throw new d.BoxSdkError({message:"unknown type"})},t.deserializeFileFullOrFolderFullOrWebLink=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileFullOrFolderFullOrWebLink"'});if("file"==e.type)return(0,n.deserializeFileFull)(e);if("folder"==e.type)return(0,s.deserializeFolderFull)(e);if("web_link"==e.type)return(0,l.deserializeWebLink)(e);throw new d.BoxSdkError({message:"Can't deserialize FileFullOrFolderFullOrWebLink"})};const i=r(49579),n=r(49579),o=r(34537),s=r(34537),a=r(60238),l=r(60238),d=r(72631),c=r(50793)},36374:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileFullOrFolderMiniOrWebLink=function(e){if("file"==e.type)return(0,i.serializeFileFull)(e);if("folder"==e.type)return(0,o.serializeFolderMini)(e);if("web_link"==e.type)return(0,a.serializeWebLink)(e);throw new d.BoxSdkError({message:"unknown type"})},t.deserializeFileFullOrFolderMiniOrWebLink=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileFullOrFolderMiniOrWebLink"'});if("file"==e.type)return(0,n.deserializeFileFull)(e);if("folder"==e.type)return(0,s.deserializeFolderMini)(e);if("web_link"==e.type)return(0,l.deserializeWebLink)(e);throw new d.BoxSdkError({message:"Can't deserialize FileFullOrFolderMiniOrWebLink"})};const i=r(49579),n=r(49579),o=r(70343),s=r(70343),a=r(60238),l=r(60238),d=r(72631),c=r(50793)},62929:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileMini=void 0,t.serializeFileMini=function(e){const t=(0,n.serializeFileBase)(e);if(!(0,c.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "FileMini"'});return Object.assign(Object.assign({},t),{sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:null==e.name?void 0:e.name,sha1:null==e.sha1?void 0:e.sha1,file_version:null==e.fileVersion?void 0:(0,o.serializeFileVersionMini)(e.fileVersion)})},t.deserializeFileMini=function(e){if(!(0,c.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "FileMini"'});if(null!=e.sequence_id&&!(0,d.sdIsString)(e.sequence_id))throw new l.BoxSdkError({message:'Expecting string for "sequence_id" of type "FileMini"'});const t=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,d.sdIsString)(e.name))throw new l.BoxSdkError({message:'Expecting string for "name" of type "FileMini"'});const r=null==e.name?void 0:e.name;if(null!=e.sha1&&!(0,d.sdIsString)(e.sha1))throw new l.BoxSdkError({message:'Expecting string for "sha1" of type "FileMini"'});const n=null==e.sha1?void 0:e.sha1,o=null==e.file_version?void 0:(0,s.deserializeFileVersionMini)(e.file_version);if(null==e.id)throw new l.BoxSdkError({message:'Expecting "id" of type "FileMini" to be defined'});if(!(0,d.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "FileMini"'});const a=e.id;if(null!=e.etag&&!(0,d.sdIsString)(e.etag))throw new l.BoxSdkError({message:'Expecting string for "etag" of type "FileMini"'});const u=null==e.etag?void 0:e.etag;if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "FileMini" to be defined'});const p=(0,i.deserializeFileBaseTypeField)(e.type);return{sequenceId:t,name:r,sha1:n,fileVersion:o,id:a,etag:u,type:p}};const i=r(39455),n=r(39455),o=r(95053),s=r(95053),a=r(39455),l=r(72631),d=r(50793),c=r(50793);class u extends a.FileBase{constructor(e){super(e)}}t.FileMini=u},71503:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileMiniOrFolderMini=function(e){if("file"==e.type)return(0,i.serializeFileMini)(e);if("folder"==e.type)return(0,o.serializeFolderMini)(e);throw new a.BoxSdkError({message:"unknown type"})},t.deserializeFileMiniOrFolderMini=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "FileMiniOrFolderMini"'});if("file"==e.type)return(0,n.deserializeFileMini)(e);if("folder"==e.type)return(0,s.deserializeFolderMini)(e);throw new a.BoxSdkError({message:"Can't deserialize FileMiniOrFolderMini"})};const i=r(62929),n=r(62929),o=r(70343),s=r(70343),a=r(72631),l=r(50793)},94132:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileOrFolderOrWebLink=function(e){if("file"==e.type)return(0,i.serializeFile)(e);if("folder"==e.type)return(0,o.serializeFolder)(e);if("web_link"==e.type)return(0,a.serializeWebLink)(e);throw new d.BoxSdkError({message:"unknown type"})},t.deserializeFileOrFolderOrWebLink=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileOrFolderOrWebLink"'});if("file"==e.type)return(0,n.deserializeFile)(e);if("folder"==e.type)return(0,s.deserializeFolder)(e);if("web_link"==e.type)return(0,l.deserializeWebLink)(e);throw new d.BoxSdkError({message:"Can't deserialize FileOrFolderOrWebLink"})};const i=r(46022),n=r(46022),o=r(18272),s=r(18272),a=r(60238),l=r(60238),d=r(72631),c=r(50793)},77733:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileOrFolderScopeScopeField=a,t.deserializeFileOrFolderScopeScopeField=l,t.serializeFileOrFolderScope=function(e){return{scope:null==e.scope?void 0:e.scope,object:null==e.object?void 0:(0,i.serializeFileMiniOrFolderMini)(e.object)}},t.deserializeFileOrFolderScope=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileOrFolderScope"'});const t=null==e.scope?void 0:l(e.scope),r=null==e.object?void 0:(0,n.deserializeFileMiniOrFolderMini)(e.object);return{scope:t,object:r}};const i=r(71503),n=r(71503),o=r(72631),s=r(50793);function a(e){return e}function l(e){if("annotation_edit"==e)return e;if("annotation_view_all"==e)return e;if("annotation_view_self"==e)return e;if("base_explorer"==e)return e;if("base_picker"==e)return e;if("base_preview"==e)return e;if("base_upload"==e)return e;if("item_delete"==e)return e;if("item_download"==e)return e;if("item_preview"==e)return e;if("item_rename"==e)return e;if("item_share"==e)return e;if("item_upload"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize FileOrFolderScopeScopeField"})}},58575:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileRequest=void 0,t.serializeFileRequestTypeField=h,t.deserializeFileRequestTypeField=f,t.serializeFileRequestStatusField=m,t.deserializeFileRequestStatusField=g,t.serializeFileRequest=function(e){return{id:e.id,type:e.type,title:null==e.title?void 0:e.title,description:null==e.description?void 0:e.description,status:null==e.status?void 0:e.status,is_email_required:null==e.isEmailRequired?void 0:e.isEmailRequired,is_description_required:null==e.isDescriptionRequired?void 0:e.isDescriptionRequired,expires_at:null==e.expiresAt?void 0:(0,a.serializeDateTime)(e.expiresAt),folder:(0,i.serializeFolderMini)(e.folder),url:null==e.url?void 0:e.url,etag:null==e.etag?void 0:e.etag,created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),created_at:(0,a.serializeDateTime)(e.createdAt),updated_by:null==e.updatedBy?void 0:(0,o.serializeUserMini)(e.updatedBy),updated_at:(0,a.serializeDateTime)(e.updatedAt)}},t.deserializeFileRequest=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileRequest"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "FileRequest" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "FileRequest"'});const t=e.id;if(null==e.type)throw new d.BoxSdkError({message:'Expecting "type" of type "FileRequest" to be defined'});const r=f(e.type);if(null!=e.title&&!(0,u.sdIsString)(e.title))throw new d.BoxSdkError({message:'Expecting string for "title" of type "FileRequest"'});const i=null==e.title?void 0:e.title;if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "FileRequest"'});const o=null==e.description?void 0:e.description,a=null==e.status?void 0:g(e.status);if(null!=e.is_email_required&&!(0,c.sdIsBoolean)(e.is_email_required))throw new d.BoxSdkError({message:'Expecting boolean for "is_email_required" of type "FileRequest"'});const h=null==e.is_email_required?void 0:e.is_email_required;if(null!=e.is_description_required&&!(0,c.sdIsBoolean)(e.is_description_required))throw new d.BoxSdkError({message:'Expecting boolean for "is_description_required" of type "FileRequest"'});const m=null==e.is_description_required?void 0:e.is_description_required;if(null!=e.expires_at&&!(0,u.sdIsString)(e.expires_at))throw new d.BoxSdkError({message:'Expecting string for "expires_at" of type "FileRequest"'});const y=null==e.expires_at?void 0:(0,l.deserializeDateTime)(e.expires_at);if(null==e.folder)throw new d.BoxSdkError({message:'Expecting "folder" of type "FileRequest" to be defined'});const v=(0,n.deserializeFolderMini)(e.folder);if(null!=e.url&&!(0,u.sdIsString)(e.url))throw new d.BoxSdkError({message:'Expecting string for "url" of type "FileRequest"'});const b=null==e.url?void 0:e.url;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "FileRequest"'});const w=null==e.etag?void 0:e.etag,_=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null==e.created_at)throw new d.BoxSdkError({message:'Expecting "created_at" of type "FileRequest" to be defined'});if(!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "FileRequest"'});const x=(0,l.deserializeDateTime)(e.created_at),S=null==e.updated_by?void 0:(0,s.deserializeUserMini)(e.updated_by);if(null==e.updated_at)throw new d.BoxSdkError({message:'Expecting "updated_at" of type "FileRequest" to be defined'});if(!(0,u.sdIsString)(e.updated_at))throw new d.BoxSdkError({message:'Expecting string for "updated_at" of type "FileRequest"'});const k=(0,l.deserializeDateTime)(e.updated_at);return{id:t,type:r,title:i,description:o,status:a,isEmailRequired:h,isDescriptionRequired:m,expiresAt:y,folder:v,url:b,etag:w,createdBy:_,createdAt:x,updatedBy:S,updatedAt:k}},t.serializeFileRequestInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,title:null==e.title?void 0:e.title,description:null==e.description?void 0:e.description,status:null==e.status?void 0:e.status,is_email_required:null==e.isEmailRequired?void 0:e.isEmailRequired,is_description_required:null==e.isDescriptionRequired?void 0:e.isDescriptionRequired,expires_at:null==e.expiresAt?void 0:(0,a.serializeDateTime)(e.expiresAt),folder:(0,i.serializeFolderMini)(e.folder),url:null==e.url?void 0:e.url,etag:null==e.etag?void 0:e.etag,created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),created_at:(0,a.serializeDateTime)(e.createdAt),updated_by:null==e.updatedBy?void 0:(0,o.serializeUserMini)(e.updatedBy),updated_at:(0,a.serializeDateTime)(e.updatedAt)}},t.deserializeFileRequestInput=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FileRequestInput"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "FileRequestInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "FileRequestInput"'});const t=e.id,r=null==e.type?void 0:f(e.type);if(null!=e.title&&!(0,u.sdIsString)(e.title))throw new d.BoxSdkError({message:'Expecting string for "title" of type "FileRequestInput"'});const i=null==e.title?void 0:e.title;if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "FileRequestInput"'});const o=null==e.description?void 0:e.description,a=null==e.status?void 0:g(e.status);if(null!=e.is_email_required&&!(0,c.sdIsBoolean)(e.is_email_required))throw new d.BoxSdkError({message:'Expecting boolean for "is_email_required" of type "FileRequestInput"'});const h=null==e.is_email_required?void 0:e.is_email_required;if(null!=e.is_description_required&&!(0,c.sdIsBoolean)(e.is_description_required))throw new d.BoxSdkError({message:'Expecting boolean for "is_description_required" of type "FileRequestInput"'});const m=null==e.is_description_required?void 0:e.is_description_required;if(null!=e.expires_at&&!(0,u.sdIsString)(e.expires_at))throw new d.BoxSdkError({message:'Expecting string for "expires_at" of type "FileRequestInput"'});const y=null==e.expires_at?void 0:(0,l.deserializeDateTime)(e.expires_at);if(null==e.folder)throw new d.BoxSdkError({message:'Expecting "folder" of type "FileRequestInput" to be defined'});const v=(0,n.deserializeFolderMini)(e.folder);if(null!=e.url&&!(0,u.sdIsString)(e.url))throw new d.BoxSdkError({message:'Expecting string for "url" of type "FileRequestInput"'});const b=null==e.url?void 0:e.url;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "FileRequestInput"'});const w=null==e.etag?void 0:e.etag,_=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null==e.created_at)throw new d.BoxSdkError({message:'Expecting "created_at" of type "FileRequestInput" to be defined'});if(!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "FileRequestInput"'});const x=(0,l.deserializeDateTime)(e.created_at),S=null==e.updated_by?void 0:(0,s.deserializeUserMini)(e.updated_by);if(null==e.updated_at)throw new d.BoxSdkError({message:'Expecting "updated_at" of type "FileRequestInput" to be defined'});if(!(0,u.sdIsString)(e.updated_at))throw new d.BoxSdkError({message:'Expecting string for "updated_at" of type "FileRequestInput"'});const k=(0,l.deserializeDateTime)(e.updated_at);return{id:t,type:r,title:i,description:o,status:a,isEmailRequired:h,isDescriptionRequired:m,expiresAt:y,folder:v,url:b,etag:w,createdBy:_,createdAt:x,updatedBy:S,updatedAt:k}};const i=r(70343),n=r(70343),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793);function h(e){return e}function f(e){if("file_request"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize FileRequestTypeField"})}function m(e){return e}function g(e){if("active"==e)return e;if("inactive"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize FileRequestStatusField"})}t.FileRequest=class{constructor(e){this.type="file_request",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.title&&(this.title=e.title),e.description&&(this.description=e.description),e.status&&(this.status=e.status),e.isEmailRequired&&(this.isEmailRequired=e.isEmailRequired),e.isDescriptionRequired&&(this.isDescriptionRequired=e.isDescriptionRequired),e.expiresAt&&(this.expiresAt=e.expiresAt),e.folder&&(this.folder=e.folder),e.url&&(this.url=e.url),e.etag&&(this.etag=e.etag),e.createdBy&&(this.createdBy=e.createdBy),e.createdAt&&(this.createdAt=e.createdAt),e.updatedBy&&(this.updatedBy=e.updatedBy),e.updatedAt&&(this.updatedAt=e.updatedAt),e.rawData&&(this.rawData=e.rawData)}}},31419:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileRequestCopyRequestFolderTypeField=c,t.deserializeFileRequestCopyRequestFolderTypeField=u,t.serializeFileRequestCopyRequestFolderField=p,t.deserializeFileRequestCopyRequestFolderField=h,t.serializeFileRequestCopyRequest=function(e){const t=(0,o.serializeFileRequestUpdateRequest)(e);if(!(0,d.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "FileRequestCopyRequest"'});return Object.assign(Object.assign({},t),{folder:p(e.folder)})},t.deserializeFileRequestCopyRequest=function(e){if(!(0,d.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "FileRequestCopyRequest"'});if(null==e.folder)throw new s.BoxSdkError({message:'Expecting "folder" of type "FileRequestCopyRequest" to be defined'});const t=h(e.folder);if(null!=e.title&&!(0,l.sdIsString)(e.title))throw new s.BoxSdkError({message:'Expecting string for "title" of type "FileRequestCopyRequest"'});const r=null==e.title?void 0:e.title;if(null!=e.description&&!(0,l.sdIsString)(e.description))throw new s.BoxSdkError({message:'Expecting string for "description" of type "FileRequestCopyRequest"'});const o=null==e.description?void 0:e.description,c=null==e.status?void 0:(0,i.deserializeFileRequestUpdateRequestStatusField)(e.status);if(null!=e.is_email_required&&!(0,a.sdIsBoolean)(e.is_email_required))throw new s.BoxSdkError({message:'Expecting boolean for "is_email_required" of type "FileRequestCopyRequest"'});const u=null==e.is_email_required?void 0:e.is_email_required;if(null!=e.is_description_required&&!(0,a.sdIsBoolean)(e.is_description_required))throw new s.BoxSdkError({message:'Expecting boolean for "is_description_required" of type "FileRequestCopyRequest"'});const p=null==e.is_description_required?void 0:e.is_description_required;if(null!=e.expires_at&&!(0,l.sdIsString)(e.expires_at))throw new s.BoxSdkError({message:'Expecting string for "expires_at" of type "FileRequestCopyRequest"'});const f=null==e.expires_at?void 0:(0,n.deserializeDateTime)(e.expires_at);return{folder:t,title:r,description:o,status:c,isEmailRequired:u,isDescriptionRequired:p,expiresAt:f}};const i=r(24387),n=r(93845),o=r(24387),s=r(72631),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("folder"==e)return e;throw new s.BoxSdkError({message:"Can't deserialize FileRequestCopyRequestFolderTypeField"})}function p(e){return{type:null==e.type?void 0:e.type,id:e.id}}function h(e){if(!(0,d.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "FileRequestCopyRequestFolderField"'});const t=null==e.type?void 0:u(e.type);if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "FileRequestCopyRequestFolderField" to be defined'});if(!(0,l.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "FileRequestCopyRequestFolderField"'});return{type:t,id:e.id}}},24387:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileRequestUpdateRequestStatusField=d,t.deserializeFileRequestUpdateRequestStatusField=c,t.serializeFileRequestUpdateRequest=function(e){return{title:null==e.title?void 0:e.title,description:null==e.description?void 0:e.description,status:null==e.status?void 0:e.status,is_email_required:null==e.isEmailRequired?void 0:e.isEmailRequired,is_description_required:null==e.isDescriptionRequired?void 0:e.isDescriptionRequired,expires_at:null==e.expiresAt?void 0:(0,i.serializeDateTime)(e.expiresAt)}},t.deserializeFileRequestUpdateRequest=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileRequestUpdateRequest"'});if(null!=e.title&&!(0,a.sdIsString)(e.title))throw new o.BoxSdkError({message:'Expecting string for "title" of type "FileRequestUpdateRequest"'});const t=null==e.title?void 0:e.title;if(null!=e.description&&!(0,a.sdIsString)(e.description))throw new o.BoxSdkError({message:'Expecting string for "description" of type "FileRequestUpdateRequest"'});const r=null==e.description?void 0:e.description,i=null==e.status?void 0:c(e.status);if(null!=e.is_email_required&&!(0,s.sdIsBoolean)(e.is_email_required))throw new o.BoxSdkError({message:'Expecting boolean for "is_email_required" of type "FileRequestUpdateRequest"'});const d=null==e.is_email_required?void 0:e.is_email_required;if(null!=e.is_description_required&&!(0,s.sdIsBoolean)(e.is_description_required))throw new o.BoxSdkError({message:'Expecting boolean for "is_description_required" of type "FileRequestUpdateRequest"'});const u=null==e.is_description_required?void 0:e.is_description_required;if(null!=e.expires_at&&!(0,a.sdIsString)(e.expires_at))throw new o.BoxSdkError({message:'Expecting string for "expires_at" of type "FileRequestUpdateRequest"'});const p=null==e.expires_at?void 0:(0,n.deserializeDateTime)(e.expires_at);return{title:t,description:r,status:i,isEmailRequired:d,isDescriptionRequired:u,expiresAt:p}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("active"==e)return e;if("inactive"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize FileRequestUpdateRequestStatusField"})}},40354:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersion=void 0,t.serializeFileVersion=function(e){const t=(0,n.serializeFileVersionMini)(e);if(!(0,h.sdIsMap)(t))throw new c.BoxSdkError({message:'Expecting a map for "FileVersion"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name,size:null==e.size?void 0:e.size,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),modified_by:null==e.modifiedBy?void 0:(0,o.serializeUserMini)(e.modifiedBy),trashed_at:null==e.trashedAt?void 0:(0,a.serializeDateTime)(e.trashedAt),trashed_by:null==e.trashedBy?void 0:(0,o.serializeUserMini)(e.trashedBy),restored_at:null==e.restoredAt?void 0:(0,a.serializeDateTime)(e.restoredAt),restored_by:null==e.restoredBy?void 0:(0,o.serializeUserMini)(e.restoredBy),purged_at:null==e.purgedAt?void 0:(0,a.serializeDateTime)(e.purgedAt),uploader_display_name:null==e.uploaderDisplayName?void 0:e.uploaderDisplayName})},t.deserializeFileVersion=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "FileVersion"'});if(null!=e.name&&!(0,p.sdIsString)(e.name))throw new c.BoxSdkError({message:'Expecting string for "name" of type "FileVersion"'});const t=null==e.name?void 0:e.name;if(null!=e.size&&!(0,u.sdIsNumber)(e.size))throw new c.BoxSdkError({message:'Expecting number for "size" of type "FileVersion"'});const r=null==e.size?void 0:e.size;if(null!=e.created_at&&!(0,p.sdIsString)(e.created_at))throw new c.BoxSdkError({message:'Expecting string for "created_at" of type "FileVersion"'});const n=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,p.sdIsString)(e.modified_at))throw new c.BoxSdkError({message:'Expecting string for "modified_at" of type "FileVersion"'});const o=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at),a=null==e.modified_by?void 0:(0,s.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,p.sdIsString)(e.trashed_at))throw new c.BoxSdkError({message:'Expecting string for "trashed_at" of type "FileVersion"'});const d=null==e.trashed_at?void 0:(0,l.deserializeDateTime)(e.trashed_at),f=null==e.trashed_by?void 0:(0,s.deserializeUserMini)(e.trashed_by);if(null!=e.restored_at&&!(0,p.sdIsString)(e.restored_at))throw new c.BoxSdkError({message:'Expecting string for "restored_at" of type "FileVersion"'});const m=null==e.restored_at?void 0:(0,l.deserializeDateTime)(e.restored_at),g=null==e.restored_by?void 0:(0,s.deserializeUserMini)(e.restored_by);if(null!=e.purged_at&&!(0,p.sdIsString)(e.purged_at))throw new c.BoxSdkError({message:'Expecting string for "purged_at" of type "FileVersion"'});const y=null==e.purged_at?void 0:(0,l.deserializeDateTime)(e.purged_at);if(null!=e.uploader_display_name&&!(0,p.sdIsString)(e.uploader_display_name))throw new c.BoxSdkError({message:'Expecting string for "uploader_display_name" of type "FileVersion"'});const v=null==e.uploader_display_name?void 0:e.uploader_display_name;if(null!=e.sha1&&!(0,p.sdIsString)(e.sha1))throw new c.BoxSdkError({message:'Expecting string for "sha1" of type "FileVersion"'});const b=null==e.sha1?void 0:e.sha1;if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "FileVersion" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "FileVersion"'});const w=e.id;if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "FileVersion" to be defined'});const _=(0,i.deserializeFileVersionBaseTypeField)(e.type);return{name:t,size:r,createdAt:n,modifiedAt:o,modifiedBy:a,trashedAt:d,trashedBy:f,restoredAt:m,restoredBy:g,purgedAt:y,uploaderDisplayName:v,sha1:b,id:w,type:_}};const i=r(28899),n=r(95053),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(95053),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f extends d.FileVersionMini{constructor(e){super(e)}}t.FileVersion=f},28899:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionBase=void 0,t.serializeFileVersionBaseTypeField=s,t.deserializeFileVersionBaseTypeField=a,t.serializeFileVersionBase=function(e){return{id:e.id,type:e.type}},t.deserializeFileVersionBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FileVersionBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FileVersionBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FileVersionBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "FileVersionBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeFileVersionBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeFileVersionBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FileVersionBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FileVersionBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FileVersionBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("file_version"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize FileVersionBaseTypeField"})}t.FileVersionBase=class{constructor(e){this.type="file_version",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},44215:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionFull=void 0,t.serializeFileVersionFull=function(e){const t=(0,s.serializeFileVersion)(e);if(!(0,u.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "FileVersionFull"'});return Object.assign(Object.assign({},t),{version_number:null==e.versionNumber?void 0:e.versionNumber})},t.deserializeFileVersionFull=function(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "FileVersionFull"'});if(null!=e.version_number&&!(0,c.sdIsString)(e.version_number))throw new l.BoxSdkError({message:'Expecting string for "version_number" of type "FileVersionFull"'});const t=null==e.version_number?void 0:e.version_number;if(null!=e.name&&!(0,c.sdIsString)(e.name))throw new l.BoxSdkError({message:'Expecting string for "name" of type "FileVersionFull"'});const r=null==e.name?void 0:e.name;if(null!=e.size&&!(0,d.sdIsNumber)(e.size))throw new l.BoxSdkError({message:'Expecting number for "size" of type "FileVersionFull"'});const s=null==e.size?void 0:e.size;if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new l.BoxSdkError({message:'Expecting string for "created_at" of type "FileVersionFull"'});const a=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,c.sdIsString)(e.modified_at))throw new l.BoxSdkError({message:'Expecting string for "modified_at" of type "FileVersionFull"'});const p=null==e.modified_at?void 0:(0,n.deserializeDateTime)(e.modified_at),h=null==e.modified_by?void 0:(0,o.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,c.sdIsString)(e.trashed_at))throw new l.BoxSdkError({message:'Expecting string for "trashed_at" of type "FileVersionFull"'});const f=null==e.trashed_at?void 0:(0,n.deserializeDateTime)(e.trashed_at),m=null==e.trashed_by?void 0:(0,o.deserializeUserMini)(e.trashed_by);if(null!=e.restored_at&&!(0,c.sdIsString)(e.restored_at))throw new l.BoxSdkError({message:'Expecting string for "restored_at" of type "FileVersionFull"'});const g=null==e.restored_at?void 0:(0,n.deserializeDateTime)(e.restored_at),y=null==e.restored_by?void 0:(0,o.deserializeUserMini)(e.restored_by);if(null!=e.purged_at&&!(0,c.sdIsString)(e.purged_at))throw new l.BoxSdkError({message:'Expecting string for "purged_at" of type "FileVersionFull"'});const v=null==e.purged_at?void 0:(0,n.deserializeDateTime)(e.purged_at);if(null!=e.uploader_display_name&&!(0,c.sdIsString)(e.uploader_display_name))throw new l.BoxSdkError({message:'Expecting string for "uploader_display_name" of type "FileVersionFull"'});const b=null==e.uploader_display_name?void 0:e.uploader_display_name;if(null!=e.sha1&&!(0,c.sdIsString)(e.sha1))throw new l.BoxSdkError({message:'Expecting string for "sha1" of type "FileVersionFull"'});const w=null==e.sha1?void 0:e.sha1;if(null==e.id)throw new l.BoxSdkError({message:'Expecting "id" of type "FileVersionFull" to be defined'});if(!(0,c.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "FileVersionFull"'});const _=e.id;if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "FileVersionFull" to be defined'});const x=(0,i.deserializeFileVersionBaseTypeField)(e.type);return{versionNumber:t,name:r,size:s,createdAt:a,modifiedAt:p,modifiedBy:h,trashedAt:f,trashedBy:m,restoredAt:g,restoredBy:y,purgedAt:v,uploaderDisplayName:b,sha1:w,id:_,type:x}};const i=r(28899),n=r(93845),o=r(95408),s=r(40354),a=r(40354),l=r(72631),d=r(50793),c=r(50793),u=r(50793);class p extends a.FileVersion{constructor(e){super(e)}}t.FileVersionFull=p},16754:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileVersionLegalHoldTypeField=m,t.deserializeFileVersionLegalHoldTypeField=g,t.serializeFileVersionLegalHold=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),file:null==e.file?void 0:(0,o.serializeFileMini)(e.file),legal_hold_policy_assignments:null==e.legalHoldPolicyAssignments?void 0:e.legalHoldPolicyAssignments.map((function(e){return(0,a.serializeLegalHoldPolicyAssignment)(e)})),deleted_at:null==e.deletedAt?void 0:(0,d.serializeDateTime)(e.deletedAt)}},t.deserializeFileVersionLegalHold=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "FileVersionLegalHold"'});if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "FileVersionLegalHold"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:g(e.type),i=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version),o=null==e.file?void 0:(0,s.deserializeFileMini)(e.file);if(null!=e.legal_hold_policy_assignments&&!(0,h.sdIsList)(e.legal_hold_policy_assignments))throw new u.BoxSdkError({message:'Expecting array for "legal_hold_policy_assignments" of type "FileVersionLegalHold"'});const a=null==e.legal_hold_policy_assignments?void 0:(0,h.sdIsList)(e.legal_hold_policy_assignments)?e.legal_hold_policy_assignments.map((function(e){return(0,l.deserializeLegalHoldPolicyAssignment)(e)})):[];if(null!=e.deleted_at&&!(0,p.sdIsString)(e.deleted_at))throw new u.BoxSdkError({message:'Expecting string for "deleted_at" of type "FileVersionLegalHold"'});const d=null==e.deleted_at?void 0:(0,c.deserializeDateTime)(e.deleted_at);return{id:t,type:r,fileVersion:i,file:o,legalHoldPolicyAssignments:a,deletedAt:d}};const i=r(95053),n=r(95053),o=r(62929),s=r(62929),a=r(55047),l=r(55047),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793),f=r(50793);function m(e){return e}function g(e){if("file_version_legal_hold"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize FileVersionLegalHoldTypeField"})}},2031:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileVersionLegalHolds=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileVersionLegalHold)(e)}))}},t.deserializeFileVersionLegalHolds=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileVersionLegalHolds"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "FileVersionLegalHolds"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "FileVersionLegalHolds"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "FileVersionLegalHolds"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FileVersionLegalHolds"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileVersionLegalHold)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(16754),n=r(16754),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},95053:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileVersionMini=void 0,t.serializeFileVersionMini=function(e){const t=(0,n.serializeFileVersionBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "FileVersionMini"'});return Object.assign(Object.assign({},t),{sha1:null==e.sha1?void 0:e.sha1})},t.deserializeFileVersionMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "FileVersionMini"'});if(null!=e.sha1&&!(0,a.sdIsString)(e.sha1))throw new s.BoxSdkError({message:'Expecting string for "sha1" of type "FileVersionMini"'});const t=null==e.sha1?void 0:e.sha1;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "FileVersionMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "FileVersionMini"'});const r=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "FileVersionMini" to be defined'});const n=(0,i.deserializeFileVersionBaseTypeField)(e.type);return{sha1:t,id:r,type:n}};const i=r(28899),n=r(28899),o=r(28899),s=r(72631),a=r(50793),l=r(50793);class d extends o.FileVersionBase{constructor(e){super(e)}}t.FileVersionMini=d},76804:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileVersionRetentionTypeField=f,t.deserializeFileVersionRetentionTypeField=m,t.serializeFileVersionRetention=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),file:null==e.file?void 0:(0,o.serializeFileMini)(e.file),applied_at:null==e.appliedAt?void 0:(0,d.serializeDateTime)(e.appliedAt),disposition_at:null==e.dispositionAt?void 0:(0,d.serializeDateTime)(e.dispositionAt),winning_retention_policy:null==e.winningRetentionPolicy?void 0:(0,a.serializeRetentionPolicyMini)(e.winningRetentionPolicy)}},t.deserializeFileVersionRetention=function(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "FileVersionRetention"'});if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "FileVersionRetention"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:m(e.type),i=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version),o=null==e.file?void 0:(0,s.deserializeFileMini)(e.file);if(null!=e.applied_at&&!(0,p.sdIsString)(e.applied_at))throw new u.BoxSdkError({message:'Expecting string for "applied_at" of type "FileVersionRetention"'});const a=null==e.applied_at?void 0:(0,c.deserializeDateTime)(e.applied_at);if(null!=e.disposition_at&&!(0,p.sdIsString)(e.disposition_at))throw new u.BoxSdkError({message:'Expecting string for "disposition_at" of type "FileVersionRetention"'});const d=null==e.disposition_at?void 0:(0,c.deserializeDateTime)(e.disposition_at),f=null==e.winning_retention_policy?void 0:(0,l.deserializeRetentionPolicyMini)(e.winning_retention_policy);return{id:t,type:r,fileVersion:i,file:o,appliedAt:a,dispositionAt:d,winningRetentionPolicy:f}};const i=r(95053),n=r(95053),o=r(62929),s=r(62929),a=r(46855),l=r(46855),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("file_version_retention"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize FileVersionRetentionTypeField"})}},1801:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileVersionRetentions=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileVersionRetention)(e)}))}},t.deserializeFileVersionRetentions=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileVersionRetentions"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "FileVersionRetentions"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "FileVersionRetentions"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "FileVersionRetentions"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FileVersionRetentions"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileVersionRetention)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(76804),n=r(76804),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},13919:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFileVersionsOrderDirectionField=c,t.deserializeFileVersionsOrderDirectionField=u,t.serializeFileVersionsOrderField=p,t.deserializeFileVersionsOrderField=h,t.serializeFileVersions=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileVersionFull)(e)}))}},t.deserializeFileVersions=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileVersions"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "FileVersions"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "FileVersions"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "FileVersions"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "FileVersions"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FileVersions"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileVersionFull)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(44215),n=r(44215),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize FileVersionsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FileVersionsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "FileVersionsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},379:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFiles=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileFull)(e)}))}},t.deserializeFiles=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Files"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Files"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Files"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileFull)(e)})):[];return{totalCount:t,entries:r}};const i=r(49579),n=r(49579),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},94983:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFilesOnHold=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileMini)(e)}))}},t.deserializeFilesOnHold=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FilesOnHold"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "FilesOnHold"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "FilesOnHold"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "FilesOnHold"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FilesOnHold"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileMini)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(62929),n=r(62929),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},8391:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFilesUnderRetention=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileMini)(e)}))}},t.deserializeFilesUnderRetention=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FilesUnderRetention"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "FilesUnderRetention"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "FilesUnderRetention"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "FilesUnderRetention"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FilesUnderRetention"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileMini)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(62929),n=r(62929),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},18272:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Folder=void 0,t.serializeFolderPathCollectionField=w,t.deserializeFolderPathCollectionField=_,t.serializeFolderSharedLinkAccessField=x,t.deserializeFolderSharedLinkAccessField=S,t.serializeFolderSharedLinkEffectiveAccessField=k,t.deserializeFolderSharedLinkEffectiveAccessField=E,t.serializeFolderSharedLinkEffectivePermissionField=T,t.deserializeFolderSharedLinkEffectivePermissionField=B,t.serializeFolderSharedLinkPermissionsField=C,t.deserializeFolderSharedLinkPermissionsField=I,t.serializeFolderSharedLinkField=A,t.deserializeFolderSharedLinkField=F,t.serializeFolderFolderUploadEmailAccessField=M,t.deserializeFolderFolderUploadEmailAccessField=D,t.serializeFolderFolderUploadEmailField=R,t.deserializeFolderFolderUploadEmailField=P,t.serializeFolderItemStatusField=O,t.deserializeFolderItemStatusField=z,t.serializeFolder=function(e){const t=(0,n.serializeFolderMini)(e);if(!(0,v.sdIsMap)(t))throw new h.BoxSdkError({message:'Expecting a map for "Folder"'});return Object.assign(Object.assign({},t),{created_at:null==e.createdAt?void 0:(0,c.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,c.serializeDateTime)(e.modifiedAt),description:null==e.description?void 0:e.description,size:null==e.size?void 0:e.size,path_collection:null==e.pathCollection?void 0:w(e.pathCollection),created_by:null==e.createdBy?void 0:(0,s.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,s.serializeUserMini)(e.modifiedBy),trashed_at:null==e.trashedAt?void 0:(0,c.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,c.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,c.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,c.serializeDateTime)(e.contentModifiedAt),owned_by:null==e.ownedBy?void 0:(0,s.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:A(e.sharedLink),folder_upload_email:null==e.folderUploadEmail?void 0:R(e.folderUploadEmail),parent:null==e.parent?void 0:(0,n.serializeFolderMini)(e.parent),item_status:null==e.itemStatus?void 0:e.itemStatus,item_collection:null==e.itemCollection?void 0:(0,l.serializeItems)(e.itemCollection)})},t.deserializeFolder=function(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "Folder"'});if(null!=e.created_at&&!(0,g.sdIsString)(e.created_at))throw new h.BoxSdkError({message:'Expecting string for "created_at" of type "Folder"'});const t=null==e.created_at?void 0:(0,u.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,g.sdIsString)(e.modified_at))throw new h.BoxSdkError({message:'Expecting string for "modified_at" of type "Folder"'});const r=null==e.modified_at?void 0:(0,u.deserializeDateTime)(e.modified_at);if(null!=e.description&&!(0,g.sdIsString)(e.description))throw new h.BoxSdkError({message:'Expecting string for "description" of type "Folder"'});const n=null==e.description?void 0:e.description;if(null!=e.size&&!(0,m.sdIsNumber)(e.size))throw new h.BoxSdkError({message:'Expecting number for "size" of type "Folder"'});const s=null==e.size?void 0:e.size,l=null==e.path_collection?void 0:_(e.path_collection),c=null==e.created_by?void 0:(0,a.deserializeUserMini)(e.created_by),p=null==e.modified_by?void 0:(0,a.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,g.sdIsString)(e.trashed_at))throw new h.BoxSdkError({message:'Expecting string for "trashed_at" of type "Folder"'});const f=null==e.trashed_at?void 0:(0,u.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,g.sdIsString)(e.purged_at))throw new h.BoxSdkError({message:'Expecting string for "purged_at" of type "Folder"'});const y=null==e.purged_at?void 0:(0,u.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,g.sdIsString)(e.content_created_at))throw new h.BoxSdkError({message:'Expecting string for "content_created_at" of type "Folder"'});const b=null==e.content_created_at?void 0:(0,u.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,g.sdIsString)(e.content_modified_at))throw new h.BoxSdkError({message:'Expecting string for "content_modified_at" of type "Folder"'});const w=null==e.content_modified_at?void 0:(0,u.deserializeDateTime)(e.content_modified_at),x=null==e.owned_by?void 0:(0,a.deserializeUserMini)(e.owned_by),S=null==e.shared_link?void 0:F(e.shared_link),k=null==e.folder_upload_email?void 0:P(e.folder_upload_email),E=null==e.parent?void 0:(0,o.deserializeFolderMini)(e.parent),T=null==e.item_status?void 0:z(e.item_status),B=null==e.item_collection?void 0:(0,d.deserializeItems)(e.item_collection);if(null!=e.sequence_id&&!(0,g.sdIsString)(e.sequence_id))throw new h.BoxSdkError({message:'Expecting string for "sequence_id" of type "Folder"'});const C=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,g.sdIsString)(e.name))throw new h.BoxSdkError({message:'Expecting string for "name" of type "Folder"'});const I=null==e.name?void 0:e.name;if(null==e.id)throw new h.BoxSdkError({message:'Expecting "id" of type "Folder" to be defined'});if(!(0,g.sdIsString)(e.id))throw new h.BoxSdkError({message:'Expecting string for "id" of type "Folder"'});const A=e.id;if(null!=e.etag&&!(0,g.sdIsString)(e.etag))throw new h.BoxSdkError({message:'Expecting string for "etag" of type "Folder"'});const M=null==e.etag?void 0:e.etag;if(null==e.type)throw new h.BoxSdkError({message:'Expecting "type" of type "Folder" to be defined'});const D=(0,i.deserializeFolderBaseTypeField)(e.type);return{createdAt:t,modifiedAt:r,description:n,size:s,pathCollection:l,createdBy:c,modifiedBy:p,trashedAt:f,purgedAt:y,contentCreatedAt:b,contentModifiedAt:w,ownedBy:x,sharedLink:S,folderUploadEmail:k,parent:E,itemStatus:T,itemCollection:B,sequenceId:C,name:I,id:A,etag:M,type:D}};const i=r(64145),n=r(70343),o=r(70343),s=r(95408),a=r(95408),l=r(61664),d=r(61664),c=r(93845),u=r(93845),p=r(70343),h=r(72631),f=r(50793),m=r(50793),g=r(50793),y=r(50793),v=r(50793);class b extends p.FolderMini{constructor(e){super(e)}}function w(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,n.serializeFolderMini)(e)}))}}function _(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FolderPathCollectionField"'});if(null==e.total_count)throw new h.BoxSdkError({message:'Expecting "total_count" of type "FolderPathCollectionField" to be defined'});if(!(0,m.sdIsNumber)(e.total_count))throw new h.BoxSdkError({message:'Expecting number for "total_count" of type "FolderPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new h.BoxSdkError({message:'Expecting "entries" of type "FolderPathCollectionField" to be defined'});if(!(0,y.sdIsList)(e.entries))throw new h.BoxSdkError({message:'Expecting array for "entries" of type "FolderPathCollectionField"'});return{totalCount:t,entries:(0,y.sdIsList)(e.entries)?e.entries.map((function(e){return(0,o.deserializeFolderMini)(e)})):[]}}function x(e){return e}function S(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FolderSharedLinkAccessField"})}function k(e){return e}function E(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FolderSharedLinkEffectiveAccessField"})}function T(e){return e}function B(e){if("can_edit"==e)return e;if("can_download"==e)return e;if("can_preview"==e)return e;if("no_access"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FolderSharedLinkEffectivePermissionField"})}function C(e){return{can_download:e.canDownload,can_preview:e.canPreview,can_edit:e.canEdit}}function I(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FolderSharedLinkPermissionsField"'});if(null==e.can_download)throw new h.BoxSdkError({message:'Expecting "can_download" of type "FolderSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_download))throw new h.BoxSdkError({message:'Expecting boolean for "can_download" of type "FolderSharedLinkPermissionsField"'});const t=e.can_download;if(null==e.can_preview)throw new h.BoxSdkError({message:'Expecting "can_preview" of type "FolderSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_preview))throw new h.BoxSdkError({message:'Expecting boolean for "can_preview" of type "FolderSharedLinkPermissionsField"'});const r=e.can_preview;if(null==e.can_edit)throw new h.BoxSdkError({message:'Expecting "can_edit" of type "FolderSharedLinkPermissionsField" to be defined'});if(!(0,f.sdIsBoolean)(e.can_edit))throw new h.BoxSdkError({message:'Expecting boolean for "can_edit" of type "FolderSharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:e.can_edit}}function A(e){return{url:e.url,download_url:null==e.downloadUrl?void 0:e.downloadUrl,vanity_url:null==e.vanityUrl?void 0:e.vanityUrl,vanity_name:null==e.vanityName?void 0:e.vanityName,access:null==e.access?void 0:e.access,effective_access:e.effectiveAccess,effective_permission:e.effectivePermission,unshared_at:null==e.unsharedAt?void 0:(0,c.serializeDateTime)(e.unsharedAt),is_password_enabled:e.isPasswordEnabled,permissions:null==e.permissions?void 0:C(e.permissions),download_count:e.downloadCount,preview_count:e.previewCount}}function F(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FolderSharedLinkField"'});if(null==e.url)throw new h.BoxSdkError({message:'Expecting "url" of type "FolderSharedLinkField" to be defined'});if(!(0,g.sdIsString)(e.url))throw new h.BoxSdkError({message:'Expecting string for "url" of type "FolderSharedLinkField"'});const t=e.url;if(null!=e.download_url&&!(0,g.sdIsString)(e.download_url))throw new h.BoxSdkError({message:'Expecting string for "download_url" of type "FolderSharedLinkField"'});const r=null==e.download_url?void 0:e.download_url;if(null!=e.vanity_url&&!(0,g.sdIsString)(e.vanity_url))throw new h.BoxSdkError({message:'Expecting string for "vanity_url" of type "FolderSharedLinkField"'});const i=null==e.vanity_url?void 0:e.vanity_url;if(null!=e.vanity_name&&!(0,g.sdIsString)(e.vanity_name))throw new h.BoxSdkError({message:'Expecting string for "vanity_name" of type "FolderSharedLinkField"'});const n=null==e.vanity_name?void 0:e.vanity_name,o=null==e.access?void 0:S(e.access);if(null==e.effective_access)throw new h.BoxSdkError({message:'Expecting "effective_access" of type "FolderSharedLinkField" to be defined'});const s=E(e.effective_access);if(null==e.effective_permission)throw new h.BoxSdkError({message:'Expecting "effective_permission" of type "FolderSharedLinkField" to be defined'});const a=B(e.effective_permission);if(null!=e.unshared_at&&!(0,g.sdIsString)(e.unshared_at))throw new h.BoxSdkError({message:'Expecting string for "unshared_at" of type "FolderSharedLinkField"'});const l=null==e.unshared_at?void 0:(0,u.deserializeDateTime)(e.unshared_at);if(null==e.is_password_enabled)throw new h.BoxSdkError({message:'Expecting "is_password_enabled" of type "FolderSharedLinkField" to be defined'});if(!(0,f.sdIsBoolean)(e.is_password_enabled))throw new h.BoxSdkError({message:'Expecting boolean for "is_password_enabled" of type "FolderSharedLinkField"'});const d=e.is_password_enabled,c=null==e.permissions?void 0:I(e.permissions);if(null==e.download_count)throw new h.BoxSdkError({message:'Expecting "download_count" of type "FolderSharedLinkField" to be defined'});if(!(0,m.sdIsNumber)(e.download_count))throw new h.BoxSdkError({message:'Expecting number for "download_count" of type "FolderSharedLinkField"'});const p=e.download_count;if(null==e.preview_count)throw new h.BoxSdkError({message:'Expecting "preview_count" of type "FolderSharedLinkField" to be defined'});if(!(0,m.sdIsNumber)(e.preview_count))throw new h.BoxSdkError({message:'Expecting number for "preview_count" of type "FolderSharedLinkField"'});return{url:t,downloadUrl:r,vanityUrl:i,vanityName:n,access:o,effectiveAccess:s,effectivePermission:a,unsharedAt:l,isPasswordEnabled:d,permissions:c,downloadCount:p,previewCount:e.preview_count}}function M(e){return e}function D(e){if("open"==e)return e;if("collaborators"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FolderFolderUploadEmailAccessField"})}function R(e){return{access:null==e.access?void 0:e.access,email:null==e.email?void 0:e.email}}function P(e){if(!(0,v.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "FolderFolderUploadEmailField"'});const t=null==e.access?void 0:D(e.access);if(null!=e.email&&!(0,g.sdIsString)(e.email))throw new h.BoxSdkError({message:'Expecting string for "email" of type "FolderFolderUploadEmailField"'});return{access:t,email:null==e.email?void 0:e.email}}function O(e){return e}function z(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize FolderItemStatusField"})}t.Folder=b},64145:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FolderBase=void 0,t.serializeFolderBaseTypeField=s,t.deserializeFolderBaseTypeField=a,t.serializeFolderBase=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:e.type}},t.deserializeFolderBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FolderBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FolderBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FolderBase"'});const t=e.id;if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "FolderBase"'});const r=null==e.etag?void 0:e.etag;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "FolderBase" to be defined'});const s=a(e.type);return{id:t,etag:r,type:s}},t.serializeFolderBaseInput=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type}},t.deserializeFolderBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "FolderBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "FolderBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "FolderBaseInput"'});const t=e.id;if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "FolderBaseInput"'});const r=null==e.etag?void 0:e.etag,s=null==e.type?void 0:a(e.type);return{id:t,etag:r,type:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("folder"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize FolderBaseTypeField"})}t.FolderBase=class{constructor(e){this.type="folder",e.id&&(this.id=e.id),e.etag&&(this.etag=e.etag),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},34537:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FolderFull=void 0,t.serializeFolderFullSyncStateField=x,t.deserializeFolderFullSyncStateField=S,t.serializeFolderFullPermissionsField=k,t.deserializeFolderFullPermissionsField=E,t.serializeFolderFullMetadataField=T,t.deserializeFolderFullMetadataField=B,t.serializeFolderFullAllowedSharedLinkAccessLevelsField=C,t.deserializeFolderFullAllowedSharedLinkAccessLevelsField=I,t.serializeFolderFullAllowedInviteeRolesField=A,t.deserializeFolderFullAllowedInviteeRolesField=F,t.serializeFolderFullWatermarkInfoField=M,t.deserializeFolderFullWatermarkInfoField=D,t.serializeFolderFullClassificationField=R,t.deserializeFolderFullClassificationField=P,t.serializeFolderFull=function(e){const t=(0,p.serializeFolder)(e);if(!(0,w.sdIsMap)(t))throw new m.BoxSdkError({message:'Expecting a map for "FolderFull"'});return Object.assign(Object.assign({},t),{sync_state:null==e.syncState?void 0:e.syncState,has_collaborations:null==e.hasCollaborations?void 0:e.hasCollaborations,permissions:null==e.permissions?void 0:k(e.permissions),tags:null==e.tags?void 0:e.tags.map((function(e){return e})),can_non_owners_invite:null==e.canNonOwnersInvite?void 0:e.canNonOwnersInvite,is_externally_owned:null==e.isExternallyOwned?void 0:e.isExternallyOwned,metadata:null==e.metadata?void 0:T(e.metadata),is_collaboration_restricted_to_enterprise:null==e.isCollaborationRestrictedToEnterprise?void 0:e.isCollaborationRestrictedToEnterprise,allowed_shared_link_access_levels:null==e.allowedSharedLinkAccessLevels?void 0:e.allowedSharedLinkAccessLevels.map((function(e){return e})),allowed_invitee_roles:null==e.allowedInviteeRoles?void 0:e.allowedInviteeRoles.map((function(e){return e})),watermark_info:null==e.watermarkInfo?void 0:M(e.watermarkInfo),is_accessible_via_shared_link:null==e.isAccessibleViaSharedLink?void 0:e.isAccessibleViaSharedLink,can_non_owners_view_collaborators:null==e.canNonOwnersViewCollaborators?void 0:e.canNonOwnersViewCollaborators,classification:null==e.classification?void 0:R(e.classification),is_associated_with_app_item:null==e.isAssociatedWithAppItem?void 0:e.isAssociatedWithAppItem})},t.deserializeFolderFull=function(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "FolderFull"'});const t=null==e.sync_state?void 0:S(e.sync_state);if(null!=e.has_collaborations&&!(0,g.sdIsBoolean)(e.has_collaborations))throw new m.BoxSdkError({message:'Expecting boolean for "has_collaborations" of type "FolderFull"'});const r=null==e.has_collaborations?void 0:e.has_collaborations,p=null==e.permissions?void 0:E(e.permissions);if(null!=e.tags&&!(0,b.sdIsList)(e.tags))throw new m.BoxSdkError({message:'Expecting array for "tags" of type "FolderFull"'});const h=null==e.tags?void 0:(0,b.sdIsList)(e.tags)?e.tags.map((function(e){if(!(0,v.sdIsString)(e))throw new m.BoxSdkError({message:'Expecting string for "FolderFull"'});return e})):[];if(null!=e.can_non_owners_invite&&!(0,g.sdIsBoolean)(e.can_non_owners_invite))throw new m.BoxSdkError({message:'Expecting boolean for "can_non_owners_invite" of type "FolderFull"'});const f=null==e.can_non_owners_invite?void 0:e.can_non_owners_invite;if(null!=e.is_externally_owned&&!(0,g.sdIsBoolean)(e.is_externally_owned))throw new m.BoxSdkError({message:'Expecting boolean for "is_externally_owned" of type "FolderFull"'});const _=null==e.is_externally_owned?void 0:e.is_externally_owned,x=null==e.metadata?void 0:B(e.metadata);if(null!=e.is_collaboration_restricted_to_enterprise&&!(0,g.sdIsBoolean)(e.is_collaboration_restricted_to_enterprise))throw new m.BoxSdkError({message:'Expecting boolean for "is_collaboration_restricted_to_enterprise" of type "FolderFull"'});const k=null==e.is_collaboration_restricted_to_enterprise?void 0:e.is_collaboration_restricted_to_enterprise;if(null!=e.allowed_shared_link_access_levels&&!(0,b.sdIsList)(e.allowed_shared_link_access_levels))throw new m.BoxSdkError({message:'Expecting array for "allowed_shared_link_access_levels" of type "FolderFull"'});const T=null==e.allowed_shared_link_access_levels?void 0:(0,b.sdIsList)(e.allowed_shared_link_access_levels)?e.allowed_shared_link_access_levels.map((function(e){return I(e)})):[];if(null!=e.allowed_invitee_roles&&!(0,b.sdIsList)(e.allowed_invitee_roles))throw new m.BoxSdkError({message:'Expecting array for "allowed_invitee_roles" of type "FolderFull"'});const C=null==e.allowed_invitee_roles?void 0:(0,b.sdIsList)(e.allowed_invitee_roles)?e.allowed_invitee_roles.map((function(e){return F(e)})):[],A=null==e.watermark_info?void 0:D(e.watermark_info);if(null!=e.is_accessible_via_shared_link&&!(0,g.sdIsBoolean)(e.is_accessible_via_shared_link))throw new m.BoxSdkError({message:'Expecting boolean for "is_accessible_via_shared_link" of type "FolderFull"'});const M=null==e.is_accessible_via_shared_link?void 0:e.is_accessible_via_shared_link;if(null!=e.can_non_owners_view_collaborators&&!(0,g.sdIsBoolean)(e.can_non_owners_view_collaborators))throw new m.BoxSdkError({message:'Expecting boolean for "can_non_owners_view_collaborators" of type "FolderFull"'});const R=null==e.can_non_owners_view_collaborators?void 0:e.can_non_owners_view_collaborators,O=null==e.classification?void 0:P(e.classification);if(null!=e.is_associated_with_app_item&&!(0,g.sdIsBoolean)(e.is_associated_with_app_item))throw new m.BoxSdkError({message:'Expecting boolean for "is_associated_with_app_item" of type "FolderFull"'});const z=null==e.is_associated_with_app_item?void 0:e.is_associated_with_app_item;if(null!=e.created_at&&!(0,v.sdIsString)(e.created_at))throw new m.BoxSdkError({message:'Expecting string for "created_at" of type "FolderFull"'});const N=null==e.created_at?void 0:(0,o.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,v.sdIsString)(e.modified_at))throw new m.BoxSdkError({message:'Expecting string for "modified_at" of type "FolderFull"'});const q=null==e.modified_at?void 0:(0,o.deserializeDateTime)(e.modified_at);if(null!=e.description&&!(0,v.sdIsString)(e.description))throw new m.BoxSdkError({message:'Expecting string for "description" of type "FolderFull"'});const U=null==e.description?void 0:e.description;if(null!=e.size&&!(0,y.sdIsNumber)(e.size))throw new m.BoxSdkError({message:'Expecting number for "size" of type "FolderFull"'});const L=null==e.size?void 0:e.size,j=null==e.path_collection?void 0:(0,s.deserializeFolderPathCollectionField)(e.path_collection),H=null==e.created_by?void 0:(0,a.deserializeUserMini)(e.created_by),$=null==e.modified_by?void 0:(0,a.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,v.sdIsString)(e.trashed_at))throw new m.BoxSdkError({message:'Expecting string for "trashed_at" of type "FolderFull"'});const G=null==e.trashed_at?void 0:(0,o.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,v.sdIsString)(e.purged_at))throw new m.BoxSdkError({message:'Expecting string for "purged_at" of type "FolderFull"'});const W=null==e.purged_at?void 0:(0,o.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,v.sdIsString)(e.content_created_at))throw new m.BoxSdkError({message:'Expecting string for "content_created_at" of type "FolderFull"'});const K=null==e.content_created_at?void 0:(0,o.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,v.sdIsString)(e.content_modified_at))throw new m.BoxSdkError({message:'Expecting string for "content_modified_at" of type "FolderFull"'});const V=null==e.content_modified_at?void 0:(0,o.deserializeDateTime)(e.content_modified_at),J=null==e.owned_by?void 0:(0,a.deserializeUserMini)(e.owned_by),Y=null==e.shared_link?void 0:(0,l.deserializeFolderSharedLinkField)(e.shared_link),Q=null==e.folder_upload_email?void 0:(0,d.deserializeFolderFolderUploadEmailField)(e.folder_upload_email),Z=null==e.parent?void 0:(0,n.deserializeFolderMini)(e.parent),X=null==e.item_status?void 0:(0,c.deserializeFolderItemStatusField)(e.item_status),ee=null==e.item_collection?void 0:(0,u.deserializeItems)(e.item_collection);if(null!=e.sequence_id&&!(0,v.sdIsString)(e.sequence_id))throw new m.BoxSdkError({message:'Expecting string for "sequence_id" of type "FolderFull"'});const te=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,v.sdIsString)(e.name))throw new m.BoxSdkError({message:'Expecting string for "name" of type "FolderFull"'});const re=null==e.name?void 0:e.name;if(null==e.id)throw new m.BoxSdkError({message:'Expecting "id" of type "FolderFull" to be defined'});if(!(0,v.sdIsString)(e.id))throw new m.BoxSdkError({message:'Expecting string for "id" of type "FolderFull"'});const ie=e.id;if(null!=e.etag&&!(0,v.sdIsString)(e.etag))throw new m.BoxSdkError({message:'Expecting string for "etag" of type "FolderFull"'});const ne=null==e.etag?void 0:e.etag;if(null==e.type)throw new m.BoxSdkError({message:'Expecting "type" of type "FolderFull" to be defined'});const oe=(0,i.deserializeFolderBaseTypeField)(e.type);return{syncState:t,hasCollaborations:r,permissions:p,tags:h,canNonOwnersInvite:f,isExternallyOwned:_,metadata:x,isCollaborationRestrictedToEnterprise:k,allowedSharedLinkAccessLevels:T,allowedInviteeRoles:C,watermarkInfo:A,isAccessibleViaSharedLink:M,canNonOwnersViewCollaborators:R,classification:O,isAssociatedWithAppItem:z,createdAt:N,modifiedAt:q,description:U,size:L,pathCollection:j,createdBy:H,modifiedBy:$,trashedAt:G,purgedAt:W,contentCreatedAt:K,contentModifiedAt:V,ownedBy:J,sharedLink:Y,folderUploadEmail:Q,parent:Z,itemStatus:X,itemCollection:ee,sequenceId:te,name:re,id:ie,etag:ne,type:oe}};const i=r(64145),n=r(70343),o=r(93845),s=r(18272),a=r(95408),l=r(18272),d=r(18272),c=r(18272),u=r(61664),p=r(18272),h=r(70376),f=r(18272),m=r(72631),g=r(50793),y=r(50793),v=r(50793),b=r(50793),w=r(50793);class _ extends f.Folder{constructor(e){super(e)}}function x(e){return e}function S(e){if("synced"==e)return e;if("not_synced"==e)return e;if("partially_synced"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize FolderFullSyncStateField"})}function k(e){return{can_delete:e.canDelete,can_download:e.canDownload,can_invite_collaborator:e.canInviteCollaborator,can_rename:e.canRename,can_set_share_access:e.canSetShareAccess,can_share:e.canShare,can_upload:e.canUpload}}function E(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "FolderFullPermissionsField"'});if(null==e.can_delete)throw new m.BoxSdkError({message:'Expecting "can_delete" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_delete))throw new m.BoxSdkError({message:'Expecting boolean for "can_delete" of type "FolderFullPermissionsField"'});const t=e.can_delete;if(null==e.can_download)throw new m.BoxSdkError({message:'Expecting "can_download" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_download))throw new m.BoxSdkError({message:'Expecting boolean for "can_download" of type "FolderFullPermissionsField"'});const r=e.can_download;if(null==e.can_invite_collaborator)throw new m.BoxSdkError({message:'Expecting "can_invite_collaborator" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_invite_collaborator))throw new m.BoxSdkError({message:'Expecting boolean for "can_invite_collaborator" of type "FolderFullPermissionsField"'});const i=e.can_invite_collaborator;if(null==e.can_rename)throw new m.BoxSdkError({message:'Expecting "can_rename" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_rename))throw new m.BoxSdkError({message:'Expecting boolean for "can_rename" of type "FolderFullPermissionsField"'});const n=e.can_rename;if(null==e.can_set_share_access)throw new m.BoxSdkError({message:'Expecting "can_set_share_access" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_set_share_access))throw new m.BoxSdkError({message:'Expecting boolean for "can_set_share_access" of type "FolderFullPermissionsField"'});const o=e.can_set_share_access;if(null==e.can_share)throw new m.BoxSdkError({message:'Expecting "can_share" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_share))throw new m.BoxSdkError({message:'Expecting boolean for "can_share" of type "FolderFullPermissionsField"'});const s=e.can_share;if(null==e.can_upload)throw new m.BoxSdkError({message:'Expecting "can_upload" of type "FolderFullPermissionsField" to be defined'});if(!(0,g.sdIsBoolean)(e.can_upload))throw new m.BoxSdkError({message:'Expecting boolean for "can_upload" of type "FolderFullPermissionsField"'});return{canDelete:t,canDownload:r,canInviteCollaborator:i,canRename:n,canSetShareAccess:o,canShare:s,canUpload:e.can_upload}}function T(e){return Object.assign({},e.extraData)}function B(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "FolderFullMetadataField"'});if(null!=e&&!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting object for "extraData" of type "FolderFullMetadataField"'});return{extraData:null==e?void 0:(0,w.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,function(e){return(0,w.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,(0,h.deserializeMetadataFull)(t)]))):{}}(t)]))):{}}}function C(e){return e}function I(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize FolderFullAllowedSharedLinkAccessLevelsField"})}function A(e){return e}function F(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize FolderFullAllowedInviteeRolesField"})}function M(e){return{is_watermarked:null==e.isWatermarked?void 0:e.isWatermarked}}function D(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "FolderFullWatermarkInfoField"'});if(null!=e.is_watermarked&&!(0,g.sdIsBoolean)(e.is_watermarked))throw new m.BoxSdkError({message:'Expecting boolean for "is_watermarked" of type "FolderFullWatermarkInfoField"'});return{isWatermarked:null==e.is_watermarked?void 0:e.is_watermarked}}function R(e){return{name:null==e.name?void 0:e.name,definition:null==e.definition?void 0:e.definition,color:null==e.color?void 0:e.color}}function P(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "FolderFullClassificationField"'});if(null!=e.name&&!(0,v.sdIsString)(e.name))throw new m.BoxSdkError({message:'Expecting string for "name" of type "FolderFullClassificationField"'});const t=null==e.name?void 0:e.name;if(null!=e.definition&&!(0,v.sdIsString)(e.definition))throw new m.BoxSdkError({message:'Expecting string for "definition" of type "FolderFullClassificationField"'});const r=null==e.definition?void 0:e.definition;if(null!=e.color&&!(0,v.sdIsString)(e.color))throw new m.BoxSdkError({message:'Expecting string for "color" of type "FolderFullClassificationField"'});return{name:t,definition:r,color:null==e.color?void 0:e.color}}t.FolderFull=_},10687:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFolderLockLockedOperationsField=h,t.deserializeFolderLockLockedOperationsField=f,t.serializeFolderLock=function(e){return{folder:null==e.folder?void 0:(0,i.serializeFolderMini)(e.folder),id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,created_by:null==e.createdBy?void 0:(0,o.serializeUserBase)(e.createdBy),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),locked_operations:null==e.lockedOperations?void 0:h(e.lockedOperations),lock_type:null==e.lockType?void 0:e.lockType}},t.deserializeFolderLock=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FolderLock"'});const t=null==e.folder?void 0:(0,n.deserializeFolderMini)(e.folder);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "FolderLock"'});const r=null==e.id?void 0:e.id;if(null!=e.type&&!(0,u.sdIsString)(e.type))throw new d.BoxSdkError({message:'Expecting string for "type" of type "FolderLock"'});const i=null==e.type?void 0:e.type,o=null==e.created_by?void 0:(0,s.deserializeUserBase)(e.created_by);if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "FolderLock"'});const a=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at),c=null==e.locked_operations?void 0:f(e.locked_operations);if(null!=e.lock_type&&!(0,u.sdIsString)(e.lock_type))throw new d.BoxSdkError({message:'Expecting string for "lock_type" of type "FolderLock"'});const h=null==e.lock_type?void 0:e.lock_type;return{folder:t,id:r,type:i,createdBy:o,createdAt:a,lockedOperations:c,lockType:h}};const i=r(70343),n=r(70343),o=r(78366),s=r(78366),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793);function h(e){return{move:e.move,delete:e.delete}}function f(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "FolderLockLockedOperationsField"'});if(null==e.move)throw new d.BoxSdkError({message:'Expecting "move" of type "FolderLockLockedOperationsField" to be defined'});if(!(0,c.sdIsBoolean)(e.move))throw new d.BoxSdkError({message:'Expecting boolean for "move" of type "FolderLockLockedOperationsField"'});const t=e.move;if(null==e.delete)throw new d.BoxSdkError({message:'Expecting "delete" of type "FolderLockLockedOperationsField" to be defined'});if(!(0,c.sdIsBoolean)(e.delete))throw new d.BoxSdkError({message:'Expecting boolean for "delete" of type "FolderLockLockedOperationsField"'});return{move:t,delete:e.delete}}},90716:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeFolderLocks=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFolderLock)(e)})),limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker}},t.deserializeFolderLocks=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "FolderLocks"'});if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "FolderLocks"'});const t=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFolderLock)(e)})):[];if(null!=e.limit&&!(0,s.sdIsString)(e.limit))throw new o.BoxSdkError({message:'Expecting string for "limit" of type "FolderLocks"'});const r=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,s.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "FolderLocks"'});const i=null==e.next_marker?void 0:e.next_marker;return{entries:t,limit:r,nextMarker:i}};const i=r(10687),n=r(10687),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},70343:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FolderMini=void 0,t.serializeFolderMini=function(e){const t=(0,n.serializeFolderBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "FolderMini"'});return Object.assign(Object.assign({},t),{sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:null==e.name?void 0:e.name})},t.deserializeFolderMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "FolderMini"'});if(null!=e.sequence_id&&!(0,a.sdIsString)(e.sequence_id))throw new s.BoxSdkError({message:'Expecting string for "sequence_id" of type "FolderMini"'});const t=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "FolderMini"'});const r=null==e.name?void 0:e.name;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "FolderMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "FolderMini"'});const n=e.id;if(null!=e.etag&&!(0,a.sdIsString)(e.etag))throw new s.BoxSdkError({message:'Expecting string for "etag" of type "FolderMini"'});const o=null==e.etag?void 0:e.etag;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "FolderMini" to be defined'});const d=(0,i.deserializeFolderBaseTypeField)(e.type);return{sequenceId:t,name:r,id:n,etag:o,type:d}};const i=r(64145),n=r(64145),o=r(64145),s=r(72631),a=r(50793),l=r(50793);class d extends o.FolderBase{constructor(e){super(e)}}t.FolderMini=d},65284:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeGenericSource=function(e){return Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t])))},t.deserializeGenericSource=function(e){return(0,i.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t]))):{}};const i=r(50793)},75943:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Group=void 0,t.serializeGroup=function(e){const t=(0,o.serializeGroupMini)(e);if(!(0,u.sdIsMap)(t))throw new d.BoxSdkError({message:'Expecting a map for "Group"'});return Object.assign(Object.assign({},t),{created_at:null==e.createdAt?void 0:(0,s.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,s.serializeDateTime)(e.modifiedAt)})},t.deserializeGroup=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "Group"'});if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "Group"'});const t=null==e.created_at?void 0:(0,a.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,c.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "Group"'});const r=null==e.modified_at?void 0:(0,a.deserializeDateTime)(e.modified_at);if(null!=e.name&&!(0,c.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "Group"'});const o=null==e.name?void 0:e.name,s=null==e.group_type?void 0:(0,n.deserializeGroupMiniGroupTypeField)(e.group_type);if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "Group" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "Group"'});const l=e.id;if(null==e.type)throw new d.BoxSdkError({message:'Expecting "type" of type "Group" to be defined'});const p=(0,i.deserializeGroupBaseTypeField)(e.type);return{createdAt:t,modifiedAt:r,name:o,groupType:s,id:l,type:p}};const i=r(27870),n=r(99248),o=r(99248),s=r(93845),a=r(93845),l=r(99248),d=r(72631),c=r(50793),u=r(50793);class p extends l.GroupMini{constructor(e){super(e)}}t.Group=p},27870:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GroupBase=void 0,t.serializeGroupBaseTypeField=s,t.deserializeGroupBaseTypeField=a,t.serializeGroupBase=function(e){return{id:e.id,type:e.type}},t.deserializeGroupBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "GroupBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "GroupBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "GroupBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "GroupBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeGroupBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeGroupBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "GroupBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "GroupBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "GroupBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("group"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize GroupBaseTypeField"})}t.GroupBase=class{constructor(e){this.type="group",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},26718:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GroupFull=void 0,t.serializeGroupFullInvitabilityLevelField=h,t.deserializeGroupFullInvitabilityLevelField=f,t.serializeGroupFullMemberViewabilityLevelField=m,t.deserializeGroupFullMemberViewabilityLevelField=g,t.serializeGroupFullPermissionsField=y,t.deserializeGroupFullPermissionsField=v,t.serializeGroupFull=function(e){const t=(0,s.serializeGroup)(e);if(!(0,u.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "GroupFull"'});return Object.assign(Object.assign({},t),{provenance:null==e.provenance?void 0:e.provenance,external_sync_identifier:null==e.externalSyncIdentifier?void 0:e.externalSyncIdentifier,description:null==e.description?void 0:e.description,invitability_level:null==e.invitabilityLevel?void 0:e.invitabilityLevel,member_viewability_level:null==e.memberViewabilityLevel?void 0:e.memberViewabilityLevel,permissions:null==e.permissions?void 0:y(e.permissions)})},t.deserializeGroupFull=function(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "GroupFull"'});if(null!=e.provenance&&!(0,c.sdIsString)(e.provenance))throw new l.BoxSdkError({message:'Expecting string for "provenance" of type "GroupFull"'});const t=null==e.provenance?void 0:e.provenance;if(null!=e.external_sync_identifier&&!(0,c.sdIsString)(e.external_sync_identifier))throw new l.BoxSdkError({message:'Expecting string for "external_sync_identifier" of type "GroupFull"'});const r=null==e.external_sync_identifier?void 0:e.external_sync_identifier;if(null!=e.description&&!(0,c.sdIsString)(e.description))throw new l.BoxSdkError({message:'Expecting string for "description" of type "GroupFull"'});const s=null==e.description?void 0:e.description,a=null==e.invitability_level?void 0:f(e.invitability_level),d=null==e.member_viewability_level?void 0:g(e.member_viewability_level),p=null==e.permissions?void 0:v(e.permissions);if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new l.BoxSdkError({message:'Expecting string for "created_at" of type "GroupFull"'});const h=null==e.created_at?void 0:(0,o.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,c.sdIsString)(e.modified_at))throw new l.BoxSdkError({message:'Expecting string for "modified_at" of type "GroupFull"'});const m=null==e.modified_at?void 0:(0,o.deserializeDateTime)(e.modified_at);if(null!=e.name&&!(0,c.sdIsString)(e.name))throw new l.BoxSdkError({message:'Expecting string for "name" of type "GroupFull"'});const y=null==e.name?void 0:e.name,b=null==e.group_type?void 0:(0,n.deserializeGroupMiniGroupTypeField)(e.group_type);if(null==e.id)throw new l.BoxSdkError({message:'Expecting "id" of type "GroupFull" to be defined'});if(!(0,c.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "GroupFull"'});const w=e.id;if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "GroupFull" to be defined'});const _=(0,i.deserializeGroupBaseTypeField)(e.type);return{provenance:t,externalSyncIdentifier:r,description:s,invitabilityLevel:a,memberViewabilityLevel:d,permissions:p,createdAt:h,modifiedAt:m,name:y,groupType:b,id:w,type:_}};const i=r(27870),n=r(99248),o=r(93845),s=r(75943),a=r(75943),l=r(72631),d=r(50793),c=r(50793),u=r(50793);class p extends a.Group{constructor(e){super(e)}}function h(e){return e}function f(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize GroupFullInvitabilityLevelField"})}function m(e){return e}function g(e){if("admins_only"==e)return e;if("admins_and_members"==e)return e;if("all_managed_users"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize GroupFullMemberViewabilityLevelField"})}function y(e){return{can_invite_as_collaborator:null==e.canInviteAsCollaborator?void 0:e.canInviteAsCollaborator}}function v(e){if(!(0,u.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "GroupFullPermissionsField"'});if(null!=e.can_invite_as_collaborator&&!(0,d.sdIsBoolean)(e.can_invite_as_collaborator))throw new l.BoxSdkError({message:'Expecting boolean for "can_invite_as_collaborator" of type "GroupFullPermissionsField"'});return{canInviteAsCollaborator:null==e.can_invite_as_collaborator?void 0:e.can_invite_as_collaborator}}t.GroupFull=p},93695:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeGroupMembershipTypeField=p,t.deserializeGroupMembershipTypeField=h,t.serializeGroupMembershipRoleField=f,t.deserializeGroupMembershipRoleField=m,t.serializeGroupMembership=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,user:null==e.user?void 0:(0,i.serializeUserMini)(e.user),group:null==e.group?void 0:(0,o.serializeGroupMini)(e.group),role:null==e.role?void 0:e.role,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt)}},t.deserializeGroupMembership=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "GroupMembership"'});if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "GroupMembership"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type),i=null==e.user?void 0:(0,n.deserializeUserMini)(e.user),o=null==e.group?void 0:(0,s.deserializeGroupMini)(e.group),a=null==e.role?void 0:m(e.role);if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "GroupMembership"'});const p=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,c.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "GroupMembership"'});const f=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);return{id:t,type:r,user:i,group:o,role:a,createdAt:p,modifiedAt:f}};const i=r(95408),n=r(95408),o=r(99248),s=r(99248),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793);function p(e){return e}function h(e){if("group_membership"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize GroupMembershipTypeField"})}function f(e){return e}function m(e){if("member"==e)return e;if("admin"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize GroupMembershipRoleField"})}},34812:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeGroupMembershipsOrderDirectionField=c,t.deserializeGroupMembershipsOrderDirectionField=u,t.serializeGroupMembershipsOrderField=p,t.deserializeGroupMembershipsOrderField=h,t.serializeGroupMemberships=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeGroupMembership)(e)}))}},t.deserializeGroupMemberships=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "GroupMemberships"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "GroupMemberships"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "GroupMemberships"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "GroupMemberships"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "GroupMemberships"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "GroupMemberships"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeGroupMembership)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(93695),n=r(93695),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize GroupMembershipsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "GroupMembershipsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "GroupMembershipsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},99248:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GroupMini=void 0,t.serializeGroupMiniGroupTypeField=c,t.deserializeGroupMiniGroupTypeField=u,t.serializeGroupMini=function(e){const t=(0,n.serializeGroupBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "GroupMini"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name,group_type:null==e.groupType?void 0:e.groupType})},t.deserializeGroupMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "GroupMini"'});if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "GroupMini"'});const t=null==e.name?void 0:e.name,r=null==e.group_type?void 0:u(e.group_type);if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "GroupMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "GroupMini"'});const n=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "GroupMini" to be defined'});const o=(0,i.deserializeGroupBaseTypeField)(e.type);return{name:t,groupType:r,id:n,type:o}};const i=r(27870),n=r(27870),o=r(27870),s=r(72631),a=r(50793),l=r(50793);class d extends o.GroupBase{constructor(e){super(e)}}function c(e){return e}function u(e){if("managed_group"==e)return e;if("all_users_group"==e)return e;throw new s.BoxSdkError({message:"Can't deserialize GroupMiniGroupTypeField"})}t.GroupMini=d},48716:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeGroupMiniOrUserCollaborations=function(e){if("group"==e.type)return(0,i.serializeGroupMini)(e);if("user"==e.type)return(0,o.serializeUserCollaborations)(e);throw new a.BoxSdkError({message:"unknown type"})},t.deserializeGroupMiniOrUserCollaborations=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "GroupMiniOrUserCollaborations"'});if("group"==e.type)return(0,n.deserializeGroupMini)(e);if("user"==e.type)return(0,s.deserializeUserCollaborations)(e);throw new a.BoxSdkError({message:"Can't deserialize GroupMiniOrUserCollaborations"})};const i=r(99248),n=r(99248),o=r(21517),s=r(21517),a=r(72631),l=r(50793)},55604:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeGroupsOrderDirectionField=c,t.deserializeGroupsOrderDirectionField=u,t.serializeGroupsOrderField=p,t.deserializeGroupsOrderField=h,t.serializeGroups=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeGroupFull)(e)}))}},t.deserializeGroups=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Groups"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Groups"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Groups"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Groups"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Groups"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Groups"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeGroupFull)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(26718),n=r(26718),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize GroupsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "GroupsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "GroupsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},7152:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IntegrationMapping=void 0,t.serializeIntegrationMappingIntegrationTypeField=_,t.deserializeIntegrationMappingIntegrationTypeField=x,t.serializeIntegrationMapping=function(e){const t=(0,n.serializeIntegrationMappingBase)(e);if(!(0,b.sdIsMap)(t))throw new g.BoxSdkError({message:'Expecting a map for "IntegrationMapping"'});return Object.assign(Object.assign({},t),{integration_type:null==e.integrationType?void 0:e.integrationType,partner_item:(0,o.serializeIntegrationMappingPartnerItemSlackUnion)(e.partnerItem),box_item:(0,a.serializeFolderMini)(e.boxItem),is_manually_created:null==e.isManuallyCreated?void 0:e.isManuallyCreated,options:null==e.options?void 0:(0,d.serializeIntegrationMappingSlackOptions)(e.options),created_by:null==e.createdBy?void 0:(0,u.serializeUserIntegrationMappings)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,u.serializeUserIntegrationMappings)(e.modifiedBy),created_at:null==e.createdAt?void 0:(0,h.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,h.serializeDateTime)(e.modifiedAt)})},t.deserializeIntegrationMapping=function(e){if(!(0,b.sdIsMap)(e))throw new g.BoxSdkError({message:'Expecting a map for "IntegrationMapping"'});const t=null==e.integration_type?void 0:x(e.integration_type);if(null==e.partner_item)throw new g.BoxSdkError({message:'Expecting "partner_item" of type "IntegrationMapping" to be defined'});const r=(0,s.deserializeIntegrationMappingPartnerItemSlackUnion)(e.partner_item);if(null==e.box_item)throw new g.BoxSdkError({message:'Expecting "box_item" of type "IntegrationMapping" to be defined'});const n=(0,l.deserializeFolderMini)(e.box_item);if(null!=e.is_manually_created&&!(0,y.sdIsBoolean)(e.is_manually_created))throw new g.BoxSdkError({message:'Expecting boolean for "is_manually_created" of type "IntegrationMapping"'});const o=null==e.is_manually_created?void 0:e.is_manually_created,a=null==e.options?void 0:(0,c.deserializeIntegrationMappingSlackOptions)(e.options),d=null==e.created_by?void 0:(0,p.deserializeUserIntegrationMappings)(e.created_by),u=null==e.modified_by?void 0:(0,p.deserializeUserIntegrationMappings)(e.modified_by);if(null!=e.created_at&&!(0,v.sdIsString)(e.created_at))throw new g.BoxSdkError({message:'Expecting string for "created_at" of type "IntegrationMapping"'});const h=null==e.created_at?void 0:(0,f.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,v.sdIsString)(e.modified_at))throw new g.BoxSdkError({message:'Expecting string for "modified_at" of type "IntegrationMapping"'});const m=null==e.modified_at?void 0:(0,f.deserializeDateTime)(e.modified_at);if(null==e.id)throw new g.BoxSdkError({message:'Expecting "id" of type "IntegrationMapping" to be defined'});if(!(0,v.sdIsString)(e.id))throw new g.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMapping"'});const w=e.id;if(null==e.type)throw new g.BoxSdkError({message:'Expecting "type" of type "IntegrationMapping" to be defined'});const _=(0,i.deserializeIntegrationMappingBaseTypeField)(e.type);return{integrationType:t,partnerItem:r,boxItem:n,isManuallyCreated:o,options:a,createdBy:d,modifiedBy:u,createdAt:h,modifiedAt:m,id:w,type:_}};const i=r(91393),n=r(91393),o=r(5206),s=r(5206),a=r(70343),l=r(70343),d=r(77954),c=r(77954),u=r(80632),p=r(80632),h=r(93845),f=r(93845),m=r(91393),g=r(72631),y=r(50793),v=r(50793),b=r(50793);class w extends m.IntegrationMappingBase{constructor(e){super(e)}}function _(e){return e}function x(e){if("slack"==e)return e;throw new g.BoxSdkError({message:"Can't deserialize IntegrationMappingIntegrationTypeField"})}t.IntegrationMapping=w},91393:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IntegrationMappingBase=void 0,t.serializeIntegrationMappingBaseTypeField=s,t.deserializeIntegrationMappingBaseTypeField=a,t.serializeIntegrationMappingBase=function(e){return{id:e.id,type:e.type}},t.deserializeIntegrationMappingBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "IntegrationMappingBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeIntegrationMappingBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeIntegrationMappingBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("integration_mapping"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize IntegrationMappingBaseTypeField"})}t.IntegrationMappingBase=class{constructor(e){this.type="integration_mapping",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},88838:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IntegrationMappingBoxItemSlack=void 0,t.serializeIntegrationMappingBoxItemSlackTypeField=s,t.deserializeIntegrationMappingBoxItemSlackTypeField=a,t.serializeIntegrationMappingBoxItemSlack=function(e){return{type:e.type,id:e.id}},t.deserializeIntegrationMappingBoxItemSlack=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingBoxItemSlack"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "IntegrationMappingBoxItemSlack" to be defined'});const t=a(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingBoxItemSlack" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingBoxItemSlack"'});const r=e.id;return{type:t,id:r}},t.serializeIntegrationMappingBoxItemSlackInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeIntegrationMappingBoxItemSlackInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingBoxItemSlackInput"'});const t=null==e.type?void 0:a(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingBoxItemSlackInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingBoxItemSlackInput"'});const r=e.id;return{type:t,id:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("folder"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize IntegrationMappingBoxItemSlackTypeField"})}t.IntegrationMappingBoxItemSlack=class{constructor(e){this.type="folder",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}}},67019:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IntegrationMappingPartnerItemSlack=void 0,t.serializeIntegrationMappingPartnerItemSlackTypeField=s,t.deserializeIntegrationMappingPartnerItemSlackTypeField=a,t.serializeIntegrationMappingPartnerItemSlack=function(e){return{type:e.type,id:e.id,slack_workspace_id:null==e.slackWorkspaceId?void 0:e.slackWorkspaceId,slack_org_id:null==e.slackOrgId?void 0:e.slackOrgId}},t.deserializeIntegrationMappingPartnerItemSlack=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingPartnerItemSlack"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "IntegrationMappingPartnerItemSlack" to be defined'});const t=a(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingPartnerItemSlack" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingPartnerItemSlack"'});const r=e.id;if(null!=e.slack_workspace_id&&!(0,n.sdIsString)(e.slack_workspace_id))throw new i.BoxSdkError({message:'Expecting string for "slack_workspace_id" of type "IntegrationMappingPartnerItemSlack"'});const s=null==e.slack_workspace_id?void 0:e.slack_workspace_id;if(null!=e.slack_org_id&&!(0,n.sdIsString)(e.slack_org_id))throw new i.BoxSdkError({message:'Expecting string for "slack_org_id" of type "IntegrationMappingPartnerItemSlack"'});const l=null==e.slack_org_id?void 0:e.slack_org_id;return{type:t,id:r,slackWorkspaceId:s,slackOrgId:l}},t.serializeIntegrationMappingPartnerItemSlackInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id,slack_workspace_id:null==e.slackWorkspaceId?void 0:e.slackWorkspaceId,slack_org_id:null==e.slackOrgId?void 0:e.slackOrgId}},t.deserializeIntegrationMappingPartnerItemSlackInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingPartnerItemSlackInput"'});const t=null==e.type?void 0:a(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "IntegrationMappingPartnerItemSlackInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "IntegrationMappingPartnerItemSlackInput"'});const r=e.id;if(null!=e.slack_workspace_id&&!(0,n.sdIsString)(e.slack_workspace_id))throw new i.BoxSdkError({message:'Expecting string for "slack_workspace_id" of type "IntegrationMappingPartnerItemSlackInput"'});const s=null==e.slack_workspace_id?void 0:e.slack_workspace_id;if(null!=e.slack_org_id&&!(0,n.sdIsString)(e.slack_org_id))throw new i.BoxSdkError({message:'Expecting string for "slack_org_id" of type "IntegrationMappingPartnerItemSlackInput"'});const l=null==e.slack_org_id?void 0:e.slack_org_id;return{type:t,id:r,slackWorkspaceId:s,slackOrgId:l}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("channel"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize IntegrationMappingPartnerItemSlackTypeField"})}t.IntegrationMappingPartnerItemSlack=class{constructor(e){this.type="channel",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.slackWorkspaceId&&(this.slackWorkspaceId=e.slackWorkspaceId),e.slackOrgId&&(this.slackOrgId=e.slackOrgId),e.rawData&&(this.rawData=e.rawData)}}},5206:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeIntegrationMappingPartnerItemSlackUnion=function(e){if("channel"==e.type)return(0,i.serializeIntegrationMappingPartnerItemSlack)(e);throw new o.BoxSdkError({message:"unknown type"})},t.deserializeIntegrationMappingPartnerItemSlackUnion=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "IntegrationMappingPartnerItemSlackUnion"'});if("channel"==e.type)return(0,n.deserializeIntegrationMappingPartnerItemSlack)(e);throw new o.BoxSdkError({message:"Can't deserialize IntegrationMappingPartnerItemSlackUnion"})};const i=r(67019),n=r(67019),o=r(72631),s=r(50793)},95665:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeIntegrationMappingSlackCreateRequest=function(e){return{partner_item:(0,i.serializeIntegrationMappingPartnerItemSlack)(e.partnerItem),box_item:(0,o.serializeIntegrationMappingBoxItemSlack)(e.boxItem),options:null==e.options?void 0:(0,a.serializeIntegrationMappingSlackOptions)(e.options)}},t.deserializeIntegrationMappingSlackCreateRequest=function(e){if(!(0,c.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "IntegrationMappingSlackCreateRequest"'});if(null==e.partner_item)throw new d.BoxSdkError({message:'Expecting "partner_item" of type "IntegrationMappingSlackCreateRequest" to be defined'});const t=(0,n.deserializeIntegrationMappingPartnerItemSlack)(e.partner_item);if(null==e.box_item)throw new d.BoxSdkError({message:'Expecting "box_item" of type "IntegrationMappingSlackCreateRequest" to be defined'});const r=(0,s.deserializeIntegrationMappingBoxItemSlack)(e.box_item),i=null==e.options?void 0:(0,l.deserializeIntegrationMappingSlackOptions)(e.options);return{partnerItem:t,boxItem:r,options:i}};const i=r(67019),n=r(67019),o=r(88838),s=r(88838),a=r(77954),l=r(77954),d=r(72631),c=r(50793)},77954:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeIntegrationMappingSlackOptions=function(e){return{is_access_management_disabled:null==e.isAccessManagementDisabled?void 0:e.isAccessManagementDisabled}},t.deserializeIntegrationMappingSlackOptions=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "IntegrationMappingSlackOptions"'});if(null!=e.is_access_management_disabled&&!(0,n.sdIsBoolean)(e.is_access_management_disabled))throw new i.BoxSdkError({message:'Expecting boolean for "is_access_management_disabled" of type "IntegrationMappingSlackOptions"'});return{isAccessManagementDisabled:null==e.is_access_management_disabled?void 0:e.is_access_management_disabled}};const i=r(72631),n=r(50793),o=r(50793)},17213:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeIntegrationMappings=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeIntegrationMapping)(e)}))}},t.deserializeIntegrationMappings=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "IntegrationMappings"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "IntegrationMappings"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "IntegrationMappings"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "IntegrationMappings"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeIntegrationMapping)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(7152),n=r(7152),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},6265:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Invite=void 0,t.serializeInviteTypeField=c,t.deserializeInviteTypeField=u,t.serializeInviteInvitedToTypeField=p,t.deserializeInviteInvitedToTypeField=h,t.serializeInviteInvitedToField=f,t.deserializeInviteInvitedToField=m,t.serializeInvite=function(e){return{id:e.id,type:e.type,invited_to:null==e.invitedTo?void 0:f(e.invitedTo),actionable_by:null==e.actionableBy?void 0:(0,i.serializeUserMini)(e.actionableBy),invited_by:null==e.invitedBy?void 0:(0,i.serializeUserMini)(e.invitedBy),status:null==e.status?void 0:e.status,created_at:null==e.createdAt?void 0:(0,o.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,o.serializeDateTime)(e.modifiedAt)}},t.deserializeInvite=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "Invite"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "Invite" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "Invite"'});const t=e.id;if(null==e.type)throw new a.BoxSdkError({message:'Expecting "type" of type "Invite" to be defined'});const r=u(e.type),i=null==e.invited_to?void 0:m(e.invited_to),o=null==e.actionable_by?void 0:(0,n.deserializeUserMini)(e.actionable_by),c=null==e.invited_by?void 0:(0,n.deserializeUserMini)(e.invited_by);if(null!=e.status&&!(0,l.sdIsString)(e.status))throw new a.BoxSdkError({message:'Expecting string for "status" of type "Invite"'});const p=null==e.status?void 0:e.status;if(null!=e.created_at&&!(0,l.sdIsString)(e.created_at))throw new a.BoxSdkError({message:'Expecting string for "created_at" of type "Invite"'});const h=null==e.created_at?void 0:(0,s.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,l.sdIsString)(e.modified_at))throw new a.BoxSdkError({message:'Expecting string for "modified_at" of type "Invite"'});const f=null==e.modified_at?void 0:(0,s.deserializeDateTime)(e.modified_at);return{id:t,type:r,invitedTo:i,actionableBy:o,invitedBy:c,status:p,createdAt:h,modifiedAt:f}},t.serializeInviteInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,invited_to:null==e.invitedTo?void 0:f(e.invitedTo),actionable_by:null==e.actionableBy?void 0:(0,i.serializeUserMini)(e.actionableBy),invited_by:null==e.invitedBy?void 0:(0,i.serializeUserMini)(e.invitedBy),status:null==e.status?void 0:e.status,created_at:null==e.createdAt?void 0:(0,o.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,o.serializeDateTime)(e.modifiedAt)}},t.deserializeInviteInput=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "InviteInput"'});if(null==e.id)throw new a.BoxSdkError({message:'Expecting "id" of type "InviteInput" to be defined'});if(!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "InviteInput"'});const t=e.id,r=null==e.type?void 0:u(e.type),i=null==e.invited_to?void 0:m(e.invited_to),o=null==e.actionable_by?void 0:(0,n.deserializeUserMini)(e.actionable_by),c=null==e.invited_by?void 0:(0,n.deserializeUserMini)(e.invited_by);if(null!=e.status&&!(0,l.sdIsString)(e.status))throw new a.BoxSdkError({message:'Expecting string for "status" of type "InviteInput"'});const p=null==e.status?void 0:e.status;if(null!=e.created_at&&!(0,l.sdIsString)(e.created_at))throw new a.BoxSdkError({message:'Expecting string for "created_at" of type "InviteInput"'});const h=null==e.created_at?void 0:(0,s.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,l.sdIsString)(e.modified_at))throw new a.BoxSdkError({message:'Expecting string for "modified_at" of type "InviteInput"'});const f=null==e.modified_at?void 0:(0,s.deserializeDateTime)(e.modified_at);return{id:t,type:r,invitedTo:i,actionableBy:o,invitedBy:c,status:p,createdAt:h,modifiedAt:f}};const i=r(95408),n=r(95408),o=r(93845),s=r(93845),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("invite"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize InviteTypeField"})}function p(e){return e}function h(e){if("enterprise"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize InviteInvitedToTypeField"})}function f(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}}function m(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "InviteInvitedToField"'});if(null!=e.id&&!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "InviteInvitedToField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type);if(null!=e.name&&!(0,l.sdIsString)(e.name))throw new a.BoxSdkError({message:'Expecting string for "name" of type "InviteInvitedToField"'});return{id:t,type:r,name:null==e.name?void 0:e.name}}t.Invite=class{constructor(e){this.type="invite",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.invitedTo&&(this.invitedTo=e.invitedTo),e.actionableBy&&(this.actionableBy=e.actionableBy),e.invitedBy&&(this.invitedBy=e.invitedBy),e.status&&(this.status=e.status),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.rawData&&(this.rawData=e.rawData)}}},61664:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeItemsOrderDirectionField=c,t.deserializeItemsOrderDirectionField=u,t.serializeItemsOrderField=p,t.deserializeItemsOrderField=h,t.serializeItems=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,total_count:null==e.totalCount?void 0:e.totalCount,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileFullOrFolderMiniOrWebLink)(e)}))}},t.deserializeItems=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Items"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Items"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "Items"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "Items"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Items"'});const c=null==e.total_count?void 0:e.total_count;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Items"'});const u=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Items"'});const p=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Items"'});const f=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileFullOrFolderMiniOrWebLink)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,totalCount:c,offset:u,order:p,entries:f}};const i=r(36374),n=r(36374),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize ItemsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ItemsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "ItemsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},64350:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KeywordSkillCard=t.KeywordSkillCardInvocationField=t.KeywordSkillCardSkillField=void 0,t.serializeKeywordSkillCardTypeField=d,t.deserializeKeywordSkillCardTypeField=c,t.serializeKeywordSkillCardSkillCardTypeField=u,t.deserializeKeywordSkillCardSkillCardTypeField=p,t.serializeKeywordSkillCardSkillCardTitleField=h,t.deserializeKeywordSkillCardSkillCardTitleField=f,t.serializeKeywordSkillCardSkillTypeField=m,t.deserializeKeywordSkillCardSkillTypeField=g,t.serializeKeywordSkillCardSkillField=y,t.deserializeKeywordSkillCardSkillField=v,t.serializeKeywordSkillCardSkillFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeKeywordSkillCardSkillFieldInput=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardSkillFieldInput"'});const t=null==e.type?void 0:g(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "KeywordSkillCardSkillFieldInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "KeywordSkillCardSkillFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeKeywordSkillCardInvocationTypeField=b,t.deserializeKeywordSkillCardInvocationTypeField=w,t.serializeKeywordSkillCardInvocationField=_,t.deserializeKeywordSkillCardInvocationField=x,t.serializeKeywordSkillCardInvocationFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeKeywordSkillCardInvocationFieldInput=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardInvocationFieldInput"'});const t=null==e.type?void 0:w(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "KeywordSkillCardInvocationFieldInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "KeywordSkillCardInvocationFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeKeywordSkillCardEntriesField=S,t.deserializeKeywordSkillCardEntriesField=k,t.serializeKeywordSkillCard=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:e.type,skill_card_type:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:h(e.skillCardTitle),skill:y(e.skill),invocation:_(e.invocation),entries:e.entries.map((function(e){return S(e)}))}},t.deserializeKeywordSkillCard=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCard"'});if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "KeywordSkillCard"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "KeywordSkillCard" to be defined'});const r=c(e.type);if(null==e.skill_card_type)throw new o.BoxSdkError({message:'Expecting "skill_card_type" of type "KeywordSkillCard" to be defined'});const i=p(e.skill_card_type),d=null==e.skill_card_title?void 0:f(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "KeywordSkillCard" to be defined'});const u=v(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "KeywordSkillCard" to be defined'});const h=x(e.invocation);if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "KeywordSkillCard" to be defined'});if(!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "KeywordSkillCard"'});const m=(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return k(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:d,skill:u,invocation:h,entries:m}},t.serializeKeywordSkillCardInput=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:null==e.type?void 0:e.type,skillCardType:null==e.skillCardType?void 0:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:h(e.skillCardTitle),skill:y(e.skill),invocation:_(e.invocation),entries:e.entries.map((function(e){return S(e)}))}},t.deserializeKeywordSkillCardInput=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardInput"'});if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "KeywordSkillCardInput"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at),r=null==e.type?void 0:c(e.type),i=null==e.skillCardType?void 0:p(e.skillCardType),d=null==e.skill_card_title?void 0:f(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "KeywordSkillCardInput" to be defined'});const u=v(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "KeywordSkillCardInput" to be defined'});const h=x(e.invocation);if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "KeywordSkillCardInput" to be defined'});if(!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "KeywordSkillCardInput"'});const m=(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return k(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:d,skill:u,invocation:h,entries:m}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793);t.KeywordSkillCardSkillField=class{constructor(e){this.type="service",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};t.KeywordSkillCardInvocationField=class{constructor(e){this.type="skill_invocation",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};function d(e){return e}function c(e){if("skill_card"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize KeywordSkillCardTypeField"})}function u(e){return e}function p(e){if("keyword"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize KeywordSkillCardSkillCardTypeField"})}function h(e){return{code:null==e.code?void 0:e.code,message:e.message}}function f(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardSkillCardTitleField"'});if(null!=e.code&&!(0,s.sdIsString)(e.code))throw new o.BoxSdkError({message:'Expecting string for "code" of type "KeywordSkillCardSkillCardTitleField"'});const t=null==e.code?void 0:e.code;if(null==e.message)throw new o.BoxSdkError({message:'Expecting "message" of type "KeywordSkillCardSkillCardTitleField" to be defined'});if(!(0,s.sdIsString)(e.message))throw new o.BoxSdkError({message:'Expecting string for "message" of type "KeywordSkillCardSkillCardTitleField"'});return{code:t,message:e.message}}function m(e){return e}function g(e){if("service"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize KeywordSkillCardSkillTypeField"})}function y(e){return{type:e.type,id:e.id}}function v(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardSkillField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "KeywordSkillCardSkillField" to be defined'});const t=g(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "KeywordSkillCardSkillField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "KeywordSkillCardSkillField"'});return{type:t,id:e.id}}function b(e){return e}function w(e){if("skill_invocation"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize KeywordSkillCardInvocationTypeField"})}function _(e){return{type:e.type,id:e.id}}function x(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardInvocationField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "KeywordSkillCardInvocationField" to be defined'});const t=w(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "KeywordSkillCardInvocationField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "KeywordSkillCardInvocationField"'});return{type:t,id:e.id}}function S(e){return{text:null==e.text?void 0:e.text}}function k(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "KeywordSkillCardEntriesField"'});if(null!=e.text&&!(0,s.sdIsString)(e.text))throw new o.BoxSdkError({message:'Expecting string for "text" of type "KeywordSkillCardEntriesField"'});return{text:null==e.text?void 0:e.text}}t.KeywordSkillCard=class{constructor(e){this.type="skill_card",this.skillCardType="keyword",e.createdAt&&(this.createdAt=e.createdAt),e.type&&(this.type=e.type),e.skillCardType&&(this.skillCardType=e.skillCardType),e.skillCardTitle&&(this.skillCardTitle=e.skillCardTitle),e.skill&&(this.skill=e.skill),e.invocation&&(this.invocation=e.invocation),e.entries&&(this.entries=e.entries),e.rawData&&(this.rawData=e.rawData)}}},20633:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard=function(e){if("keyword"==e.skillCardType)return(0,i.serializeKeywordSkillCard)(e);if("status"==e.skillCardType)return(0,o.serializeStatusSkillCard)(e);if("timeline"==e.skillCardType)return(0,a.serializeTimelineSkillCard)(e);if("transcript"==e.skillCardType)return(0,d.serializeTranscriptSkillCard)(e);throw new u.BoxSdkError({message:"unknown type"})},t.deserializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard=function(e){if(!(0,p.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "KeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard"'});if("keyword"==e.skill_card_type)return(0,n.deserializeKeywordSkillCard)(e);if("status"==e.skill_card_type)return(0,s.deserializeStatusSkillCard)(e);if("timeline"==e.skill_card_type)return(0,l.deserializeTimelineSkillCard)(e);if("transcript"==e.skill_card_type)return(0,c.deserializeTranscriptSkillCard)(e);throw new u.BoxSdkError({message:"Can't deserialize KeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard"})};const i=r(64350),n=r(64350),o=r(77421),s=r(77421),a=r(37086),l=r(37086),d=r(20749),c=r(20749),u=r(72631),p=r(50793)},48910:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeLegalHoldPolicies=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeLegalHoldPolicy)(e)}))}},t.deserializeLegalHoldPolicies=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "LegalHoldPolicies"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "LegalHoldPolicies"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "LegalHoldPolicies"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "LegalHoldPolicies"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "LegalHoldPolicies"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeLegalHoldPolicy)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(83750),n=r(83750),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},83750:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LegalHoldPolicy=void 0,t.serializeLegalHoldPolicyStatusField=m,t.deserializeLegalHoldPolicyStatusField=g,t.serializeLegalHoldPolicyAssignmentCountsField=y,t.deserializeLegalHoldPolicyAssignmentCountsField=v,t.serializeLegalHoldPolicy=function(e){const t=(0,n.serializeLegalHoldPolicyMini)(e);if(!(0,h.sdIsMap)(t))throw new c.BoxSdkError({message:'Expecting a map for "LegalHoldPolicy"'});return Object.assign(Object.assign({},t),{policy_name:null==e.policyName?void 0:e.policyName,description:null==e.description?void 0:e.description,status:null==e.status?void 0:e.status,assignment_counts:null==e.assignmentCounts?void 0:y(e.assignmentCounts),created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),deleted_at:null==e.deletedAt?void 0:(0,a.serializeDateTime)(e.deletedAt),filter_started_at:null==e.filterStartedAt?void 0:(0,a.serializeDateTime)(e.filterStartedAt),filter_ended_at:null==e.filterEndedAt?void 0:(0,a.serializeDateTime)(e.filterEndedAt),release_notes:null==e.releaseNotes?void 0:e.releaseNotes})},t.deserializeLegalHoldPolicy=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "LegalHoldPolicy"'});if(null!=e.policy_name&&!(0,p.sdIsString)(e.policy_name))throw new c.BoxSdkError({message:'Expecting string for "policy_name" of type "LegalHoldPolicy"'});const t=null==e.policy_name?void 0:e.policy_name;if(null!=e.description&&!(0,p.sdIsString)(e.description))throw new c.BoxSdkError({message:'Expecting string for "description" of type "LegalHoldPolicy"'});const r=null==e.description?void 0:e.description,n=null==e.status?void 0:g(e.status),o=null==e.assignment_counts?void 0:v(e.assignment_counts),a=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,p.sdIsString)(e.created_at))throw new c.BoxSdkError({message:'Expecting string for "created_at" of type "LegalHoldPolicy"'});const d=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,p.sdIsString)(e.modified_at))throw new c.BoxSdkError({message:'Expecting string for "modified_at" of type "LegalHoldPolicy"'});const u=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null!=e.deleted_at&&!(0,p.sdIsString)(e.deleted_at))throw new c.BoxSdkError({message:'Expecting string for "deleted_at" of type "LegalHoldPolicy"'});const f=null==e.deleted_at?void 0:(0,l.deserializeDateTime)(e.deleted_at);if(null!=e.filter_started_at&&!(0,p.sdIsString)(e.filter_started_at))throw new c.BoxSdkError({message:'Expecting string for "filter_started_at" of type "LegalHoldPolicy"'});const m=null==e.filter_started_at?void 0:(0,l.deserializeDateTime)(e.filter_started_at);if(null!=e.filter_ended_at&&!(0,p.sdIsString)(e.filter_ended_at))throw new c.BoxSdkError({message:'Expecting string for "filter_ended_at" of type "LegalHoldPolicy"'});const y=null==e.filter_ended_at?void 0:(0,l.deserializeDateTime)(e.filter_ended_at);if(null!=e.release_notes&&!(0,p.sdIsString)(e.release_notes))throw new c.BoxSdkError({message:'Expecting string for "release_notes" of type "LegalHoldPolicy"'});const b=null==e.release_notes?void 0:e.release_notes;if(null==e.id)throw new c.BoxSdkError({message:'Expecting "id" of type "LegalHoldPolicy" to be defined'});if(!(0,p.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "LegalHoldPolicy"'});const w=e.id;if(null==e.type)throw new c.BoxSdkError({message:'Expecting "type" of type "LegalHoldPolicy" to be defined'});const _=(0,i.deserializeLegalHoldPolicyMiniTypeField)(e.type);return{policyName:t,description:r,status:n,assignmentCounts:o,createdBy:a,createdAt:d,modifiedAt:u,deletedAt:f,filterStartedAt:m,filterEndedAt:y,releaseNotes:b,id:w,type:_}};const i=r(53681),n=r(53681),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(53681),c=r(72631),u=r(50793),p=r(50793),h=r(50793);class f extends d.LegalHoldPolicyMini{constructor(e){super(e)}}function m(e){return e}function g(e){if("active"==e)return e;if("applying"==e)return e;if("releasing"==e)return e;if("released"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize LegalHoldPolicyStatusField"})}function y(e){return{user:null==e.user?void 0:e.user,folder:null==e.folder?void 0:e.folder,file:null==e.file?void 0:e.file,file_version:null==e.fileVersion?void 0:e.fileVersion}}function v(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyAssignmentCountsField"'});if(null!=e.user&&!(0,u.sdIsNumber)(e.user))throw new c.BoxSdkError({message:'Expecting number for "user" of type "LegalHoldPolicyAssignmentCountsField"'});const t=null==e.user?void 0:e.user;if(null!=e.folder&&!(0,u.sdIsNumber)(e.folder))throw new c.BoxSdkError({message:'Expecting number for "folder" of type "LegalHoldPolicyAssignmentCountsField"'});const r=null==e.folder?void 0:e.folder;if(null!=e.file&&!(0,u.sdIsNumber)(e.file))throw new c.BoxSdkError({message:'Expecting number for "file" of type "LegalHoldPolicyAssignmentCountsField"'});const i=null==e.file?void 0:e.file;if(null!=e.file_version&&!(0,u.sdIsNumber)(e.file_version))throw new c.BoxSdkError({message:'Expecting number for "file_version" of type "LegalHoldPolicyAssignmentCountsField"'});return{user:t,folder:r,file:i,fileVersion:null==e.file_version?void 0:e.file_version}}t.LegalHoldPolicy=f},55047:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeLegalHoldPolicyAssignment=function(e){const t=(0,n.serializeLegalHoldPolicyAssignmentBase)(e);if(!(0,m.sdIsMap)(t))throw new h.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyAssignment"'});return Object.assign(Object.assign({},t),{legal_hold_policy:null==e.legalHoldPolicy?void 0:(0,o.serializeLegalHoldPolicyMini)(e.legalHoldPolicy),assigned_to:null==e.assignedTo?void 0:(0,a.serializeFileOrFolderOrWebLink)(e.assignedTo),assigned_by:null==e.assignedBy?void 0:(0,d.serializeUserMini)(e.assignedBy),assigned_at:null==e.assignedAt?void 0:(0,u.serializeDateTime)(e.assignedAt),deleted_at:null==e.deletedAt?void 0:(0,u.serializeDateTime)(e.deletedAt)})},t.deserializeLegalHoldPolicyAssignment=function(e){if(!(0,m.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyAssignment"'});const t=null==e.legal_hold_policy?void 0:(0,s.deserializeLegalHoldPolicyMini)(e.legal_hold_policy),r=null==e.assigned_to?void 0:(0,l.deserializeFileOrFolderOrWebLink)(e.assigned_to),n=null==e.assigned_by?void 0:(0,c.deserializeUserMini)(e.assigned_by);if(null!=e.assigned_at&&!(0,f.sdIsString)(e.assigned_at))throw new h.BoxSdkError({message:'Expecting string for "assigned_at" of type "LegalHoldPolicyAssignment"'});const o=null==e.assigned_at?void 0:(0,p.deserializeDateTime)(e.assigned_at);if(null!=e.deleted_at&&!(0,f.sdIsString)(e.deleted_at))throw new h.BoxSdkError({message:'Expecting string for "deleted_at" of type "LegalHoldPolicyAssignment"'});const a=null==e.deleted_at?void 0:(0,p.deserializeDateTime)(e.deleted_at);if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new h.BoxSdkError({message:'Expecting string for "id" of type "LegalHoldPolicyAssignment"'});const d=null==e.id?void 0:e.id,u=null==e.type?void 0:(0,i.deserializeLegalHoldPolicyAssignmentBaseTypeField)(e.type);return{legalHoldPolicy:t,assignedTo:r,assignedBy:n,assignedAt:o,deletedAt:a,id:d,type:u}};const i=r(16510),n=r(16510),o=r(53681),s=r(53681),a=r(94132),l=r(94132),d=r(95408),c=r(95408),u=r(93845),p=r(93845),h=r(72631),f=r(50793),m=r(50793)},16510:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeLegalHoldPolicyAssignmentBaseTypeField=s,t.deserializeLegalHoldPolicyAssignmentBaseTypeField=a,t.serializeLegalHoldPolicyAssignmentBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeLegalHoldPolicyAssignmentBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyAssignmentBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "LegalHoldPolicyAssignmentBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("legal_hold_policy_assignment"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize LegalHoldPolicyAssignmentBaseTypeField"})}},44212:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeLegalHoldPolicyAssignments=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeLegalHoldPolicyAssignment)(e)}))}},t.deserializeLegalHoldPolicyAssignments=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyAssignments"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "LegalHoldPolicyAssignments"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "LegalHoldPolicyAssignments"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "LegalHoldPolicyAssignments"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "LegalHoldPolicyAssignments"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeLegalHoldPolicyAssignment)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(55047),n=r(55047),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},53681:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LegalHoldPolicyMini=void 0,t.serializeLegalHoldPolicyMiniTypeField=s,t.deserializeLegalHoldPolicyMiniTypeField=a,t.serializeLegalHoldPolicyMini=function(e){return{id:e.id,type:e.type}},t.deserializeLegalHoldPolicyMini=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyMini"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "LegalHoldPolicyMini" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "LegalHoldPolicyMini"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "LegalHoldPolicyMini" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeLegalHoldPolicyMiniInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeLegalHoldPolicyMiniInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "LegalHoldPolicyMiniInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "LegalHoldPolicyMiniInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "LegalHoldPolicyMiniInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("legal_hold_policy"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize LegalHoldPolicyMiniTypeField"})}t.LegalHoldPolicyMini=class{constructor(e){this.type="legal_hold_policy",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},59997:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadata=function(e){return(0,i.serializeMetadataBase)(e)},t.deserializeMetadata=function(e){return(0,n.deserializeMetadataBase)(e)};const i=r(17404),n=r(17404)},17404:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataBase=function(e){return{$parent:null==e.parent?void 0:e.parent,$template:null==e.template?void 0:e.template,$scope:null==e.scope?void 0:e.scope,$version:null==e.version?void 0:e.version}},t.deserializeMetadataBase=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataBase"'});if(null!=e.$parent&&!(0,o.sdIsString)(e.$parent))throw new i.BoxSdkError({message:'Expecting string for "$parent" of type "MetadataBase"'});const t=null==e.$parent?void 0:e.$parent;if(null!=e.$template&&!(0,o.sdIsString)(e.$template))throw new i.BoxSdkError({message:'Expecting string for "$template" of type "MetadataBase"'});const r=null==e.$template?void 0:e.$template;if(null!=e.$scope&&!(0,o.sdIsString)(e.$scope))throw new i.BoxSdkError({message:'Expecting string for "$scope" of type "MetadataBase"'});const a=null==e.$scope?void 0:e.$scope;if(null!=e.$version&&!(0,n.sdIsNumber)(e.$version))throw new i.BoxSdkError({message:'Expecting number for "$version" of type "MetadataBase"'});const l=null==e.$version?void 0:e.$version;return{parent:t,template:r,scope:a,version:l}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793)},93267:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataCascadePolicies=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeMetadataCascadePolicy)(e)}))}},t.deserializeMetadataCascadePolicies=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "MetadataCascadePolicies"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "MetadataCascadePolicies"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "MetadataCascadePolicies"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "MetadataCascadePolicies"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "MetadataCascadePolicies"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeMetadataCascadePolicy)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(45243),n=r(45243),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},45243:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MetadataCascadePolicy=void 0,t.serializeMetadataCascadePolicyTypeField=s,t.deserializeMetadataCascadePolicyTypeField=a,t.serializeMetadataCascadePolicyOwnerEnterpriseTypeField=l,t.deserializeMetadataCascadePolicyOwnerEnterpriseTypeField=d,t.serializeMetadataCascadePolicyOwnerEnterpriseField=c,t.deserializeMetadataCascadePolicyOwnerEnterpriseField=u,t.serializeMetadataCascadePolicyParentTypeField=p,t.deserializeMetadataCascadePolicyParentTypeField=h,t.serializeMetadataCascadePolicyParentField=f,t.deserializeMetadataCascadePolicyParentField=m,t.serializeMetadataCascadePolicy=function(e){return{id:e.id,type:e.type,owner_enterprise:null==e.ownerEnterprise?void 0:c(e.ownerEnterprise),parent:null==e.parent?void 0:f(e.parent),scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey}},t.deserializeMetadataCascadePolicy=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataCascadePolicy"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "MetadataCascadePolicy" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataCascadePolicy"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "MetadataCascadePolicy" to be defined'});const r=a(e.type),s=null==e.owner_enterprise?void 0:u(e.owner_enterprise),l=null==e.parent?void 0:m(e.parent);if(null!=e.scope&&!(0,n.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "MetadataCascadePolicy"'});const d=null==e.scope?void 0:e.scope;if(null!=e.templateKey&&!(0,n.sdIsString)(e.templateKey))throw new i.BoxSdkError({message:'Expecting string for "templateKey" of type "MetadataCascadePolicy"'});const c=null==e.templateKey?void 0:e.templateKey;return{id:t,type:r,ownerEnterprise:s,parent:l,scope:d,templateKey:c}},t.serializeMetadataCascadePolicyInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,owner_enterprise:null==e.ownerEnterprise?void 0:c(e.ownerEnterprise),parent:null==e.parent?void 0:f(e.parent),scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey}},t.deserializeMetadataCascadePolicyInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataCascadePolicyInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "MetadataCascadePolicyInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataCascadePolicyInput"'});const t=e.id,r=null==e.type?void 0:a(e.type),s=null==e.owner_enterprise?void 0:u(e.owner_enterprise),l=null==e.parent?void 0:m(e.parent);if(null!=e.scope&&!(0,n.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "MetadataCascadePolicyInput"'});const d=null==e.scope?void 0:e.scope;if(null!=e.templateKey&&!(0,n.sdIsString)(e.templateKey))throw new i.BoxSdkError({message:'Expecting string for "templateKey" of type "MetadataCascadePolicyInput"'});const c=null==e.templateKey?void 0:e.templateKey;return{id:t,type:r,ownerEnterprise:s,parent:l,scope:d,templateKey:c}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("metadata_cascade_policy"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataCascadePolicyTypeField"})}function l(e){return e}function d(e){if("enterprise"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataCascadePolicyOwnerEnterpriseTypeField"})}function c(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function u(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataCascadePolicyOwnerEnterpriseField"'});const t=null==e.type?void 0:d(e.type);if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataCascadePolicyOwnerEnterpriseField"'});return{type:t,id:null==e.id?void 0:e.id}}function p(e){return e}function h(e){if("folder"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataCascadePolicyParentTypeField"})}function f(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function m(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataCascadePolicyParentField"'});const t=null==e.type?void 0:h(e.type);if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataCascadePolicyParentField"'});return{type:t,id:null==e.id?void 0:e.id}}t.MetadataCascadePolicy=class{constructor(e){this.type="metadata_cascade_policy",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.ownerEnterprise&&(this.ownerEnterprise=e.ownerEnterprise),e.parent&&(this.parent=e.parent),e.scope&&(this.scope=e.scope),e.templateKey&&(this.templateKey=e.templateKey),e.rawData&&(this.rawData=e.rawData)}}},9010:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataFieldFilterDateRange=function(e){return{lt:null==e.lt?void 0:(0,i.serializeDateTime)(e.lt),gt:null==e.gt?void 0:(0,i.serializeDateTime)(e.gt)}},t.deserializeMetadataFieldFilterDateRange=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "MetadataFieldFilterDateRange"'});if(null!=e.lt&&!(0,s.sdIsString)(e.lt))throw new o.BoxSdkError({message:'Expecting string for "lt" of type "MetadataFieldFilterDateRange"'});const t=null==e.lt?void 0:(0,n.deserializeDateTime)(e.lt);if(null!=e.gt&&!(0,s.sdIsString)(e.gt))throw new o.BoxSdkError({message:'Expecting string for "gt" of type "MetadataFieldFilterDateRange"'});const r=null==e.gt?void 0:(0,n.deserializeDateTime)(e.gt);return{lt:t,gt:r}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793)},74955:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString=function(e){if((0,d.sdIsString)(e))return e;if((0,l.sdIsNumber)(e))return e;if((0,c.sdIsList)(e))return e;try{return(0,i.serializeMetadataFieldFilterDateRange)(e)}catch(e){}try{return(0,o.serializeMetadataFieldFilterFloatRange)(e)}catch(e){}throw new a.BoxSdkError({message:"Can't serialize MetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString"})},t.deserializeMetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString=function(e){if((0,d.sdIsString)(e))return e;if((0,l.sdIsNumber)(e))return e;try{return(0,n.deserializeMetadataFieldFilterDateRange)(e)}catch(e){}try{return(0,s.deserializeMetadataFieldFilterFloatRange)(e)}catch(e){}throw new a.BoxSdkError({message:"Can't deserialize MetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString"})};const i=r(9010),n=r(9010),o=r(74854),s=r(74854),a=r(72631),l=r(50793),d=r(50793),c=r(50793)},74854:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataFieldFilterFloatRange=function(e){return{lt:null==e.lt?void 0:e.lt,gt:null==e.gt?void 0:e.gt}},t.deserializeMetadataFieldFilterFloatRange=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataFieldFilterFloatRange"'});if(null!=e.lt&&!(0,n.sdIsNumber)(e.lt))throw new i.BoxSdkError({message:'Expecting number for "lt" of type "MetadataFieldFilterFloatRange"'});const t=null==e.lt?void 0:e.lt;if(null!=e.gt&&!(0,n.sdIsNumber)(e.gt))throw new i.BoxSdkError({message:'Expecting number for "gt" of type "MetadataFieldFilterFloatRange"'});const r=null==e.gt?void 0:e.gt;return{lt:t,gt:r}};const i=r(72631),n=r(50793),o=r(50793)},56211:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataFilterScopeField=l,t.deserializeMetadataFilterScopeField=d,t.serializeMetadataFilter=function(e){return{scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,filters:null==e.filters?void 0:Object.fromEntries(Object.entries(e.filters).map((([e,t])=>[e,(0,i.serializeMetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString)(t)])))}},t.deserializeMetadataFilter=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "MetadataFilter"'});const t=null==e.scope?void 0:d(e.scope);if(null!=e.templateKey&&!(0,s.sdIsString)(e.templateKey))throw new o.BoxSdkError({message:'Expecting string for "templateKey" of type "MetadataFilter"'});const r=null==e.templateKey?void 0:e.templateKey;if(null!=e.filters&&!(0,a.sdIsMap)(e.filters))throw new o.BoxSdkError({message:'Expecting object for "filters" of type "MetadataFilter"'});const i=null==e.filters?void 0:(0,a.sdIsMap)(e.filters)?Object.fromEntries(Object.entries(e.filters).map((([e,t])=>[e,(0,n.deserializeMetadataFieldFilterDateRangeOrMetadataFieldFilterFloatRangeOrArrayOfStringOrNumberOrString)(t)]))):{};return{scope:t,templateKey:r,filters:i}};const i=r(74955),n=r(74955),o=r(72631),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("global"==e)return e;if("enterprise"==e)return e;if("enterprise_{enterprise_id}"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize MetadataFilterScopeField"})}},70376:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataFull=function(e){const t=(0,i.serializeMetadata)(e);if(!(0,l.sdIsMap)(t))throw new n.BoxSdkError({message:'Expecting a map for "MetadataFull"'});return Object.assign(Object.assign({},t),Object.assign({$canEdit:null==e.canEdit?void 0:e.canEdit,$id:null==e.id?void 0:e.id,$type:null==e.type?void 0:e.type,$typeVersion:null==e.typeVersion?void 0:e.typeVersion},e.extraData))},t.deserializeMetadataFull=function(e){if(!(0,l.sdIsMap)(e))throw new n.BoxSdkError({message:'Expecting a map for "MetadataFull"'});if(null!=e.$canEdit&&!(0,o.sdIsBoolean)(e.$canEdit))throw new n.BoxSdkError({message:'Expecting boolean for "$canEdit" of type "MetadataFull"'});const t=null==e.$canEdit?void 0:e.$canEdit;if(null!=e.$id&&!(0,a.sdIsString)(e.$id))throw new n.BoxSdkError({message:'Expecting string for "$id" of type "MetadataFull"'});const r=null==e.$id?void 0:e.$id;if(null!=e.$type&&!(0,a.sdIsString)(e.$type))throw new n.BoxSdkError({message:'Expecting string for "$type" of type "MetadataFull"'});const i=null==e.$type?void 0:e.$type;if(null!=e.$typeVersion&&!(0,s.sdIsNumber)(e.$typeVersion))throw new n.BoxSdkError({message:'Expecting number for "$typeVersion" of type "MetadataFull"'});const d=null==e.$typeVersion?void 0:e.$typeVersion;if(null!=e&&!(0,l.sdIsMap)(e))throw new n.BoxSdkError({message:'Expecting object for "extraData" of type "MetadataFull"'});const c=null==e?void 0:(0,l.sdIsMap)(e)?Object.fromEntries(Object.entries(e).map((([e,t])=>[e,t]))):{};if(null!=e.$parent&&!(0,a.sdIsString)(e.$parent))throw new n.BoxSdkError({message:'Expecting string for "$parent" of type "MetadataFull"'});const u=null==e.$parent?void 0:e.$parent;if(null!=e.$template&&!(0,a.sdIsString)(e.$template))throw new n.BoxSdkError({message:'Expecting string for "$template" of type "MetadataFull"'});const p=null==e.$template?void 0:e.$template;if(null!=e.$scope&&!(0,a.sdIsString)(e.$scope))throw new n.BoxSdkError({message:'Expecting string for "$scope" of type "MetadataFull"'});const h=null==e.$scope?void 0:e.$scope;if(null!=e.$version&&!(0,s.sdIsNumber)(e.$version))throw new n.BoxSdkError({message:'Expecting number for "$version" of type "MetadataFull"'});const f=null==e.$version?void 0:e.$version;return{canEdit:t,id:r,type:i,typeVersion:d,extraData:c,parent:u,template:p,scope:h,version:f}};const i=r(59997),n=r(72631),o=r(50793),s=r(50793),a=r(50793),l=r(50793)},26775:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataQueryOrderByDirectionField=l,t.deserializeMetadataQueryOrderByDirectionField=d,t.serializeMetadataQueryOrderByField=c,t.deserializeMetadataQueryOrderByField=u,t.serializeMetadataQuery=function(e){return{from:e.from,query:null==e.query?void 0:e.query,query_params:null==e.queryParams?void 0:e.queryParams,ancestor_folder_id:e.ancestorFolderId,order_by:null==e.orderBy?void 0:e.orderBy.map((function(e){return c(e)})),limit:null==e.limit?void 0:e.limit,marker:null==e.marker?void 0:e.marker,fields:null==e.fields?void 0:e.fields.map((function(e){return e}))}},t.deserializeMetadataQuery=function(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataQuery"'});if(null==e.from)throw new i.BoxSdkError({message:'Expecting "from" of type "MetadataQuery" to be defined'});if(!(0,o.sdIsString)(e.from))throw new i.BoxSdkError({message:'Expecting string for "from" of type "MetadataQuery"'});const t=e.from;if(null!=e.query&&!(0,o.sdIsString)(e.query))throw new i.BoxSdkError({message:'Expecting string for "query" of type "MetadataQuery"'});const r=null==e.query?void 0:e.query;if(null!=e.query_params&&!(0,a.sdIsMap)(e.query_params))throw new i.BoxSdkError({message:'Expecting object for "query_params" of type "MetadataQuery"'});const l=null==e.query_params?void 0:(0,a.sdIsMap)(e.query_params)?Object.fromEntries(Object.entries(e.query_params).map((([e,t])=>[e,function(e){if(!(0,o.sdIsString)(e))throw new i.BoxSdkError({message:'Expecting string for "MetadataQuery"'});return e}(t)]))):{};if(null==e.ancestor_folder_id)throw new i.BoxSdkError({message:'Expecting "ancestor_folder_id" of type "MetadataQuery" to be defined'});if(!(0,o.sdIsString)(e.ancestor_folder_id))throw new i.BoxSdkError({message:'Expecting string for "ancestor_folder_id" of type "MetadataQuery"'});const d=e.ancestor_folder_id;if(null!=e.order_by&&!(0,s.sdIsList)(e.order_by))throw new i.BoxSdkError({message:'Expecting array for "order_by" of type "MetadataQuery"'});const c=null==e.order_by?void 0:(0,s.sdIsList)(e.order_by)?e.order_by.map((function(e){return u(e)})):[];if(null!=e.limit&&!(0,n.sdIsNumber)(e.limit))throw new i.BoxSdkError({message:'Expecting number for "limit" of type "MetadataQuery"'});const p=null==e.limit?void 0:e.limit;if(null!=e.marker&&!(0,o.sdIsString)(e.marker))throw new i.BoxSdkError({message:'Expecting string for "marker" of type "MetadataQuery"'});const h=null==e.marker?void 0:e.marker;if(null!=e.fields&&!(0,s.sdIsList)(e.fields))throw new i.BoxSdkError({message:'Expecting array for "fields" of type "MetadataQuery"'});const f=null==e.fields?void 0:(0,s.sdIsList)(e.fields)?e.fields.map((function(e){if(!(0,o.sdIsString)(e))throw new i.BoxSdkError({message:'Expecting string for "MetadataQuery"'});return e})):[];return{from:t,query:r,queryParams:l,ancestorFolderId:d,orderBy:c,limit:p,marker:h,fields:f}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataQueryOrderByDirectionField"})}function c(e){return{field_key:null==e.fieldKey?void 0:e.fieldKey,direction:null==e.direction?void 0:e.direction}}function u(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataQueryOrderByField"'});if(null!=e.field_key&&!(0,o.sdIsString)(e.field_key))throw new i.BoxSdkError({message:'Expecting string for "field_key" of type "MetadataQueryOrderByField"'});return{fieldKey:null==e.field_key?void 0:e.field_key,direction:null==e.direction?void 0:d(e.direction)}}},90863:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataQueryResults=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileFullOrFolderFull)(e)})),limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker}},t.deserializeMetadataQueryResults=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "MetadataQueryResults"'});if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "MetadataQueryResults"'});const t=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileFullOrFolderFull)(e)})):[];if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "MetadataQueryResults"'});const r=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "MetadataQueryResults"'});const i=null==e.next_marker?void 0:e.next_marker;return{entries:t,limit:r,nextMarker:i}};const i=r(19291),n=r(19291),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},81631:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MetadataTemplate=void 0,t.serializeMetadataTemplateTypeField=l,t.deserializeMetadataTemplateTypeField=d,t.serializeMetadataTemplateFieldsTypeField=c,t.deserializeMetadataTemplateFieldsTypeField=u,t.serializeMetadataTemplateFieldsOptionsField=p,t.deserializeMetadataTemplateFieldsOptionsField=h,t.serializeMetadataTemplateFieldsField=f,t.deserializeMetadataTemplateFieldsField=m,t.serializeMetadataTemplate=function(e){return{id:e.id,type:e.type,scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,fields:null==e.fields?void 0:e.fields.map((function(e){return f(e)})),copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy}},t.deserializeMetadataTemplate=function(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataTemplate"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "MetadataTemplate" to be defined'});if(!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataTemplate"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "MetadataTemplate" to be defined'});const r=d(e.type);if(null!=e.scope&&!(0,o.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "MetadataTemplate"'});const l=null==e.scope?void 0:e.scope;if(null!=e.templateKey&&!(0,o.sdIsString)(e.templateKey))throw new i.BoxSdkError({message:'Expecting string for "templateKey" of type "MetadataTemplate"'});const c=null==e.templateKey?void 0:e.templateKey;if(null!=e.displayName&&!(0,o.sdIsString)(e.displayName))throw new i.BoxSdkError({message:'Expecting string for "displayName" of type "MetadataTemplate"'});const u=null==e.displayName?void 0:e.displayName;if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "MetadataTemplate"'});const p=null==e.hidden?void 0:e.hidden;if(null!=e.fields&&!(0,s.sdIsList)(e.fields))throw new i.BoxSdkError({message:'Expecting array for "fields" of type "MetadataTemplate"'});const h=null==e.fields?void 0:(0,s.sdIsList)(e.fields)?e.fields.map((function(e){return m(e)})):[];if(null!=e.copyInstanceOnItemCopy&&!(0,n.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new i.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "MetadataTemplate"'});const f=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;return{id:t,type:r,scope:l,templateKey:c,displayName:u,hidden:p,fields:h,copyInstanceOnItemCopy:f}},t.serializeMetadataTemplateInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,scope:null==e.scope?void 0:e.scope,templateKey:null==e.templateKey?void 0:e.templateKey,displayName:null==e.displayName?void 0:e.displayName,hidden:null==e.hidden?void 0:e.hidden,fields:null==e.fields?void 0:e.fields.map((function(e){return f(e)})),copyInstanceOnItemCopy:null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy}},t.deserializeMetadataTemplateInput=function(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataTemplateInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "MetadataTemplateInput" to be defined'});if(!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataTemplateInput"'});const t=e.id,r=null==e.type?void 0:d(e.type);if(null!=e.scope&&!(0,o.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "MetadataTemplateInput"'});const l=null==e.scope?void 0:e.scope;if(null!=e.templateKey&&!(0,o.sdIsString)(e.templateKey))throw new i.BoxSdkError({message:'Expecting string for "templateKey" of type "MetadataTemplateInput"'});const c=null==e.templateKey?void 0:e.templateKey;if(null!=e.displayName&&!(0,o.sdIsString)(e.displayName))throw new i.BoxSdkError({message:'Expecting string for "displayName" of type "MetadataTemplateInput"'});const u=null==e.displayName?void 0:e.displayName;if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "MetadataTemplateInput"'});const p=null==e.hidden?void 0:e.hidden;if(null!=e.fields&&!(0,s.sdIsList)(e.fields))throw new i.BoxSdkError({message:'Expecting array for "fields" of type "MetadataTemplateInput"'});const h=null==e.fields?void 0:(0,s.sdIsList)(e.fields)?e.fields.map((function(e){return m(e)})):[];if(null!=e.copyInstanceOnItemCopy&&!(0,n.sdIsBoolean)(e.copyInstanceOnItemCopy))throw new i.BoxSdkError({message:'Expecting boolean for "copyInstanceOnItemCopy" of type "MetadataTemplateInput"'});const f=null==e.copyInstanceOnItemCopy?void 0:e.copyInstanceOnItemCopy;return{id:t,type:r,scope:l,templateKey:c,displayName:u,hidden:p,fields:h,copyInstanceOnItemCopy:f}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("metadata_template"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataTemplateTypeField"})}function c(e){return e}function u(e){if("string"==e)return e;if("float"==e)return e;if("date"==e)return e;if("enum"==e)return e;if("multiSelect"==e)return e;if("integer"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize MetadataTemplateFieldsTypeField"})}function p(e){return{key:e.key,id:null==e.id?void 0:e.id}}function h(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataTemplateFieldsOptionsField"'});if(null==e.key)throw new i.BoxSdkError({message:'Expecting "key" of type "MetadataTemplateFieldsOptionsField" to be defined'});if(!(0,o.sdIsString)(e.key))throw new i.BoxSdkError({message:'Expecting string for "key" of type "MetadataTemplateFieldsOptionsField"'});const t=e.key;if(null!=e.id&&!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataTemplateFieldsOptionsField"'});return{key:t,id:null==e.id?void 0:e.id}}function f(e){return{type:e.type,key:e.key,displayName:e.displayName,description:null==e.description?void 0:e.description,hidden:null==e.hidden?void 0:e.hidden,options:null==e.options?void 0:e.options.map((function(e){return p(e)})),id:null==e.id?void 0:e.id}}function m(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "MetadataTemplateFieldsField"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "MetadataTemplateFieldsField" to be defined'});const t=u(e.type);if(null==e.key)throw new i.BoxSdkError({message:'Expecting "key" of type "MetadataTemplateFieldsField" to be defined'});if(!(0,o.sdIsString)(e.key))throw new i.BoxSdkError({message:'Expecting string for "key" of type "MetadataTemplateFieldsField"'});const r=e.key;if(null==e.displayName)throw new i.BoxSdkError({message:'Expecting "displayName" of type "MetadataTemplateFieldsField" to be defined'});if(!(0,o.sdIsString)(e.displayName))throw new i.BoxSdkError({message:'Expecting string for "displayName" of type "MetadataTemplateFieldsField"'});const l=e.displayName;if(null!=e.description&&!(0,o.sdIsString)(e.description))throw new i.BoxSdkError({message:'Expecting string for "description" of type "MetadataTemplateFieldsField"'});const d=null==e.description?void 0:e.description;if(null!=e.hidden&&!(0,n.sdIsBoolean)(e.hidden))throw new i.BoxSdkError({message:'Expecting boolean for "hidden" of type "MetadataTemplateFieldsField"'});const c=null==e.hidden?void 0:e.hidden;if(null!=e.options&&!(0,s.sdIsList)(e.options))throw new i.BoxSdkError({message:'Expecting array for "options" of type "MetadataTemplateFieldsField"'});const p=null==e.options?void 0:(0,s.sdIsList)(e.options)?e.options.map((function(e){return h(e)})):[];if(null!=e.id&&!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "MetadataTemplateFieldsField"'});return{type:t,key:r,displayName:l,description:d,hidden:c,options:p,id:null==e.id?void 0:e.id}}t.MetadataTemplate=class{constructor(e){this.type="metadata_template",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.scope&&(this.scope=e.scope),e.templateKey&&(this.templateKey=e.templateKey),e.displayName&&(this.displayName=e.displayName),e.hidden&&(this.hidden=e.hidden),e.fields&&(this.fields=e.fields),e.copyInstanceOnItemCopy&&(this.copyInstanceOnItemCopy=e.copyInstanceOnItemCopy),e.rawData&&(this.rawData=e.rawData)}}},12444:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadataTemplates=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeMetadataTemplate)(e)}))}},t.deserializeMetadataTemplates=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "MetadataTemplates"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "MetadataTemplates"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "MetadataTemplates"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "MetadataTemplates"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "MetadataTemplates"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeMetadataTemplate)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(81631),n=r(81631),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},37418:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeMetadatas=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeMetadata)(e)})),limit:null==e.limit?void 0:e.limit}},t.deserializeMetadatas=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Metadatas"'});if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Metadatas"'});const t=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeMetadata)(e)})):[];if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Metadatas"'});const r=null==e.limit?void 0:e.limit;return{entries:t,limit:r}};const i=r(59997),n=r(59997),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},24704:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeOutcome=function(e){return{id:e.id,collaborators:null==e.collaborators?void 0:(0,i.serializeCollaboratorVariable)(e.collaborators),completion_rule:null==e.completionRule?void 0:(0,o.serializeCompletionRuleVariable)(e.completionRule),file_collaborator_role:null==e.fileCollaboratorRole?void 0:(0,a.serializeRoleVariable)(e.fileCollaboratorRole),task_collaborators:null==e.taskCollaborators?void 0:(0,i.serializeCollaboratorVariable)(e.taskCollaborators),role:null==e.role?void 0:(0,a.serializeRoleVariable)(e.role)}},t.deserializeOutcome=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "Outcome"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "Outcome" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "Outcome"'});const t=e.id,r=null==e.collaborators?void 0:(0,n.deserializeCollaboratorVariable)(e.collaborators),i=null==e.completion_rule?void 0:(0,s.deserializeCompletionRuleVariable)(e.completion_rule),o=null==e.file_collaborator_role?void 0:(0,l.deserializeRoleVariable)(e.file_collaborator_role),a=null==e.task_collaborators?void 0:(0,n.deserializeCollaboratorVariable)(e.task_collaborators),p=null==e.role?void 0:(0,l.deserializeRoleVariable)(e.role);return{id:t,collaborators:r,completionRule:i,fileCollaboratorRole:o,taskCollaborators:a,role:p}};const i=r(44432),n=r(44432),o=r(58524),s=r(58524),a=r(91236),l=r(91236),d=r(72631),c=r(50793),u=r(50793)},31227:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializePostOAuth2Revoke=function(e){return{client_id:null==e.clientId?void 0:e.clientId,client_secret:null==e.clientSecret?void 0:e.clientSecret,token:null==e.token?void 0:e.token}},t.deserializePostOAuth2Revoke=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "PostOAuth2Revoke"'});if(null!=e.client_id&&!(0,n.sdIsString)(e.client_id))throw new i.BoxSdkError({message:'Expecting string for "client_id" of type "PostOAuth2Revoke"'});const t=null==e.client_id?void 0:e.client_id;if(null!=e.client_secret&&!(0,n.sdIsString)(e.client_secret))throw new i.BoxSdkError({message:'Expecting string for "client_secret" of type "PostOAuth2Revoke"'});const r=null==e.client_secret?void 0:e.client_secret;if(null!=e.token&&!(0,n.sdIsString)(e.token))throw new i.BoxSdkError({message:'Expecting string for "token" of type "PostOAuth2Revoke"'});const s=null==e.token?void 0:e.token;return{clientId:t,clientSecret:r,token:s}};const i=r(72631),n=r(50793),o=r(50793)},61734:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializePostOAuth2TokenGrantTypeField=s,t.deserializePostOAuth2TokenGrantTypeField=a,t.serializePostOAuth2TokenSubjectTokenTypeField=l,t.deserializePostOAuth2TokenSubjectTokenTypeField=d,t.serializePostOAuth2TokenActorTokenTypeField=c,t.deserializePostOAuth2TokenActorTokenTypeField=u,t.serializePostOAuth2TokenBoxSubjectTypeField=p,t.deserializePostOAuth2TokenBoxSubjectTypeField=h,t.serializePostOAuth2Token=function(e){return{grant_type:e.grantType,client_id:null==e.clientId?void 0:e.clientId,client_secret:null==e.clientSecret?void 0:e.clientSecret,code:null==e.code?void 0:e.code,refresh_token:null==e.refreshToken?void 0:e.refreshToken,assertion:null==e.assertion?void 0:e.assertion,subject_token:null==e.subjectToken?void 0:e.subjectToken,subject_token_type:null==e.subjectTokenType?void 0:e.subjectTokenType,actor_token:null==e.actorToken?void 0:e.actorToken,actor_token_type:null==e.actorTokenType?void 0:e.actorTokenType,scope:null==e.scope?void 0:e.scope,resource:null==e.resource?void 0:e.resource,box_subject_type:null==e.boxSubjectType?void 0:e.boxSubjectType,box_subject_id:null==e.boxSubjectId?void 0:e.boxSubjectId,box_shared_link:null==e.boxSharedLink?void 0:e.boxSharedLink}},t.deserializePostOAuth2Token=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "PostOAuth2Token"'});if(null==e.grant_type)throw new i.BoxSdkError({message:'Expecting "grant_type" of type "PostOAuth2Token" to be defined'});const t=a(e.grant_type);if(null!=e.client_id&&!(0,n.sdIsString)(e.client_id))throw new i.BoxSdkError({message:'Expecting string for "client_id" of type "PostOAuth2Token"'});const r=null==e.client_id?void 0:e.client_id;if(null!=e.client_secret&&!(0,n.sdIsString)(e.client_secret))throw new i.BoxSdkError({message:'Expecting string for "client_secret" of type "PostOAuth2Token"'});const s=null==e.client_secret?void 0:e.client_secret;if(null!=e.code&&!(0,n.sdIsString)(e.code))throw new i.BoxSdkError({message:'Expecting string for "code" of type "PostOAuth2Token"'});const l=null==e.code?void 0:e.code;if(null!=e.refresh_token&&!(0,n.sdIsString)(e.refresh_token))throw new i.BoxSdkError({message:'Expecting string for "refresh_token" of type "PostOAuth2Token"'});const c=null==e.refresh_token?void 0:e.refresh_token;if(null!=e.assertion&&!(0,n.sdIsString)(e.assertion))throw new i.BoxSdkError({message:'Expecting string for "assertion" of type "PostOAuth2Token"'});const p=null==e.assertion?void 0:e.assertion;if(null!=e.subject_token&&!(0,n.sdIsString)(e.subject_token))throw new i.BoxSdkError({message:'Expecting string for "subject_token" of type "PostOAuth2Token"'});const f=null==e.subject_token?void 0:e.subject_token,m=null==e.subject_token_type?void 0:d(e.subject_token_type);if(null!=e.actor_token&&!(0,n.sdIsString)(e.actor_token))throw new i.BoxSdkError({message:'Expecting string for "actor_token" of type "PostOAuth2Token"'});const g=null==e.actor_token?void 0:e.actor_token,y=null==e.actor_token_type?void 0:u(e.actor_token_type);if(null!=e.scope&&!(0,n.sdIsString)(e.scope))throw new i.BoxSdkError({message:'Expecting string for "scope" of type "PostOAuth2Token"'});const v=null==e.scope?void 0:e.scope;if(null!=e.resource&&!(0,n.sdIsString)(e.resource))throw new i.BoxSdkError({message:'Expecting string for "resource" of type "PostOAuth2Token"'});const b=null==e.resource?void 0:e.resource,w=null==e.box_subject_type?void 0:h(e.box_subject_type);if(null!=e.box_subject_id&&!(0,n.sdIsString)(e.box_subject_id))throw new i.BoxSdkError({message:'Expecting string for "box_subject_id" of type "PostOAuth2Token"'});const _=null==e.box_subject_id?void 0:e.box_subject_id;if(null!=e.box_shared_link&&!(0,n.sdIsString)(e.box_shared_link))throw new i.BoxSdkError({message:'Expecting string for "box_shared_link" of type "PostOAuth2Token"'});const x=null==e.box_shared_link?void 0:e.box_shared_link;return{grantType:t,clientId:r,clientSecret:s,code:l,refreshToken:c,assertion:p,subjectToken:f,subjectTokenType:m,actorToken:g,actorTokenType:y,scope:v,resource:b,boxSubjectType:w,boxSubjectId:_,boxSharedLink:x}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("authorization_code"==e)return e;if("refresh_token"==e)return e;if("client_credentials"==e)return e;if("urn:ietf:params:oauth:grant-type:jwt-bearer"==e)return e;if("urn:ietf:params:oauth:grant-type:token-exchange"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize PostOAuth2TokenGrantTypeField"})}function l(e){return e}function d(e){if("urn:ietf:params:oauth:token-type:access_token"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize PostOAuth2TokenSubjectTokenTypeField"})}function c(e){return e}function u(e){if("urn:ietf:params:oauth:token-type:id_token"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize PostOAuth2TokenActorTokenTypeField"})}function p(e){return e}function h(e){if("enterprise"==e)return e;if("user"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize PostOAuth2TokenBoxSubjectTypeField"})}},67028:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostOAuth2TokenRefreshAccessToken=void 0,t.serializePostOAuth2TokenRefreshAccessTokenGrantTypeField=s,t.deserializePostOAuth2TokenRefreshAccessTokenGrantTypeField=a,t.serializePostOAuth2TokenRefreshAccessToken=function(e){return{grant_type:e.grantType,client_id:e.clientId,client_secret:e.clientSecret,refresh_token:e.refreshToken}},t.deserializePostOAuth2TokenRefreshAccessToken=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "PostOAuth2TokenRefreshAccessToken"'});if(null==e.grant_type)throw new i.BoxSdkError({message:'Expecting "grant_type" of type "PostOAuth2TokenRefreshAccessToken" to be defined'});const t=a(e.grant_type);if(null==e.client_id)throw new i.BoxSdkError({message:'Expecting "client_id" of type "PostOAuth2TokenRefreshAccessToken" to be defined'});if(!(0,n.sdIsString)(e.client_id))throw new i.BoxSdkError({message:'Expecting string for "client_id" of type "PostOAuth2TokenRefreshAccessToken"'});const r=e.client_id;if(null==e.client_secret)throw new i.BoxSdkError({message:'Expecting "client_secret" of type "PostOAuth2TokenRefreshAccessToken" to be defined'});if(!(0,n.sdIsString)(e.client_secret))throw new i.BoxSdkError({message:'Expecting string for "client_secret" of type "PostOAuth2TokenRefreshAccessToken"'});const s=e.client_secret;if(null==e.refresh_token)throw new i.BoxSdkError({message:'Expecting "refresh_token" of type "PostOAuth2TokenRefreshAccessToken" to be defined'});if(!(0,n.sdIsString)(e.refresh_token))throw new i.BoxSdkError({message:'Expecting string for "refresh_token" of type "PostOAuth2TokenRefreshAccessToken"'});const l=e.refresh_token;return{grantType:t,clientId:r,clientSecret:s,refreshToken:l}},t.serializePostOAuth2TokenRefreshAccessTokenInput=function(e){return{grantType:null==e.grantType?void 0:e.grantType,client_id:e.clientId,client_secret:e.clientSecret,refresh_token:e.refreshToken}},t.deserializePostOAuth2TokenRefreshAccessTokenInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "PostOAuth2TokenRefreshAccessTokenInput"'});const t=null==e.grantType?void 0:a(e.grantType);if(null==e.client_id)throw new i.BoxSdkError({message:'Expecting "client_id" of type "PostOAuth2TokenRefreshAccessTokenInput" to be defined'});if(!(0,n.sdIsString)(e.client_id))throw new i.BoxSdkError({message:'Expecting string for "client_id" of type "PostOAuth2TokenRefreshAccessTokenInput"'});const r=e.client_id;if(null==e.client_secret)throw new i.BoxSdkError({message:'Expecting "client_secret" of type "PostOAuth2TokenRefreshAccessTokenInput" to be defined'});if(!(0,n.sdIsString)(e.client_secret))throw new i.BoxSdkError({message:'Expecting string for "client_secret" of type "PostOAuth2TokenRefreshAccessTokenInput"'});const s=e.client_secret;if(null==e.refresh_token)throw new i.BoxSdkError({message:'Expecting "refresh_token" of type "PostOAuth2TokenRefreshAccessTokenInput" to be defined'});if(!(0,n.sdIsString)(e.refresh_token))throw new i.BoxSdkError({message:'Expecting string for "refresh_token" of type "PostOAuth2TokenRefreshAccessTokenInput"'});const l=e.refresh_token;return{grantType:t,clientId:r,clientSecret:s,refreshToken:l}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("refresh_token"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize PostOAuth2TokenRefreshAccessTokenGrantTypeField"})}t.PostOAuth2TokenRefreshAccessToken=class{constructor(e){this.grantType="refresh_token",e.grantType&&(this.grantType=e.grantType),e.clientId&&(this.clientId=e.clientId),e.clientSecret&&(this.clientSecret=e.clientSecret),e.refreshToken&&(this.refreshToken=e.refreshToken),e.rawData&&(this.rawData=e.rawData)}}},25826:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRealtimeServer=function(e){return{type:null==e.type?void 0:e.type,url:null==e.url?void 0:e.url,ttl:null==e.ttl?void 0:e.ttl,max_retries:null==e.maxRetries?void 0:e.maxRetries,retry_timeout:null==e.retryTimeout?void 0:e.retryTimeout}},t.deserializeRealtimeServer=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "RealtimeServer"'});if(null!=e.type&&!(0,o.sdIsString)(e.type))throw new i.BoxSdkError({message:'Expecting string for "type" of type "RealtimeServer"'});const t=null==e.type?void 0:e.type;if(null!=e.url&&!(0,o.sdIsString)(e.url))throw new i.BoxSdkError({message:'Expecting string for "url" of type "RealtimeServer"'});const r=null==e.url?void 0:e.url;if(null!=e.ttl&&!(0,o.sdIsString)(e.ttl))throw new i.BoxSdkError({message:'Expecting string for "ttl" of type "RealtimeServer"'});const a=null==e.ttl?void 0:e.ttl;if(null!=e.max_retries&&!(0,o.sdIsString)(e.max_retries))throw new i.BoxSdkError({message:'Expecting string for "max_retries" of type "RealtimeServer"'});const l=null==e.max_retries?void 0:e.max_retries;if(null!=e.retry_timeout&&!(0,n.sdIsNumber)(e.retry_timeout))throw new i.BoxSdkError({message:'Expecting number for "retry_timeout" of type "RealtimeServer"'});const d=null==e.retry_timeout?void 0:e.retry_timeout;return{type:t,url:r,ttl:a,maxRetries:l,retryTimeout:d}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793)},15135:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRealtimeServers=function(e){return{chunk_size:null==e.chunkSize?void 0:e.chunkSize,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeRealtimeServer)(e)}))}},t.deserializeRealtimeServers=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "RealtimeServers"'});if(null!=e.chunk_size&&!(0,s.sdIsNumber)(e.chunk_size))throw new o.BoxSdkError({message:'Expecting number for "chunk_size" of type "RealtimeServers"'});const t=null==e.chunk_size?void 0:e.chunk_size;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "RealtimeServers"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeRealtimeServer)(e)})):[];return{chunkSize:t,entries:r}};const i=r(25826),n=r(25826),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},65176:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRecentItemInteractionTypeField=c,t.deserializeRecentItemInteractionTypeField=u,t.serializeRecentItem=function(e){return{type:null==e.type?void 0:e.type,item:null==e.item?void 0:(0,i.serializeFileFullOrFolderFullOrWebLink)(e.item),interaction_type:null==e.interactionType?void 0:e.interactionType,interacted_at:null==e.interactedAt?void 0:(0,o.serializeDateTime)(e.interactedAt),interaction_shared_link:null==e.interactionSharedLink?void 0:e.interactionSharedLink}},t.deserializeRecentItem=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "RecentItem"'});if(null!=e.type&&!(0,l.sdIsString)(e.type))throw new a.BoxSdkError({message:'Expecting string for "type" of type "RecentItem"'});const t=null==e.type?void 0:e.type,r=null==e.item?void 0:(0,n.deserializeFileFullOrFolderFullOrWebLink)(e.item),i=null==e.interaction_type?void 0:u(e.interaction_type);if(null!=e.interacted_at&&!(0,l.sdIsString)(e.interacted_at))throw new a.BoxSdkError({message:'Expecting string for "interacted_at" of type "RecentItem"'});const o=null==e.interacted_at?void 0:(0,s.deserializeDateTime)(e.interacted_at);if(null!=e.interaction_shared_link&&!(0,l.sdIsString)(e.interaction_shared_link))throw new a.BoxSdkError({message:'Expecting string for "interaction_shared_link" of type "RecentItem"'});const c=null==e.interaction_shared_link?void 0:e.interaction_shared_link;return{type:t,item:r,interactionType:i,interactedAt:o,interactionSharedLink:c}};const i=r(58820),n=r(58820),o=r(93845),s=r(93845),a=r(72631),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("item_preview"==e)return e;if("item_upload"==e)return e;if("item_comment"==e)return e;if("item_open"==e)return e;if("item_modify"==e)return e;throw new a.BoxSdkError({message:"Can't deserialize RecentItemInteractionTypeField"})}},62325:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRecentItems=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeRecentItem)(e)}))}},t.deserializeRecentItems=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "RecentItems"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "RecentItems"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "RecentItems"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "RecentItems"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "RecentItems"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeRecentItem)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(65176),n=r(65176),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},6756:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRetentionPolicies=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeRetentionPolicy)(e)})),limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker}},t.deserializeRetentionPolicies=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "RetentionPolicies"'});if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "RetentionPolicies"'});const t=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeRetentionPolicy)(e)})):[];if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "RetentionPolicies"'});const r=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "RetentionPolicies"'});const i=null==e.next_marker?void 0:e.next_marker;return{entries:t,limit:r,nextMarker:i}};const i=r(60960),n=r(60960),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},60960:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPolicy=void 0,t.serializeRetentionPolicyPolicyTypeField=v,t.deserializeRetentionPolicyPolicyTypeField=b,t.serializeRetentionPolicyRetentionTypeField=w,t.deserializeRetentionPolicyRetentionTypeField=_,t.serializeRetentionPolicyStatusField=x,t.deserializeRetentionPolicyStatusField=S,t.serializeRetentionPolicyAssignmentCountsField=k,t.deserializeRetentionPolicyAssignmentCountsField=E,t.serializeRetentionPolicy=function(e){const t=(0,o.serializeRetentionPolicyMini)(e);if(!(0,g.sdIsMap)(t))throw new u.BoxSdkError({message:'Expecting a map for "RetentionPolicy"'});return Object.assign(Object.assign({},t),{description:null==e.description?void 0:e.description,policy_type:null==e.policyType?void 0:e.policyType,retention_type:null==e.retentionType?void 0:e.retentionType,status:null==e.status?void 0:e.status,created_by:null==e.createdBy?void 0:(0,s.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,l.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,l.serializeDateTime)(e.modifiedAt),can_owner_extend_retention:null==e.canOwnerExtendRetention?void 0:e.canOwnerExtendRetention,are_owners_notified:null==e.areOwnersNotified?void 0:e.areOwnersNotified,custom_notification_recipients:null==e.customNotificationRecipients?void 0:e.customNotificationRecipients.map((function(e){return(0,s.serializeUserMini)(e)})),assignment_counts:null==e.assignmentCounts?void 0:k(e.assignmentCounts)})},t.deserializeRetentionPolicy=function(e){if(!(0,g.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RetentionPolicy"'});if(null!=e.description&&!(0,f.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "RetentionPolicy"'});const t=null==e.description?void 0:e.description,r=null==e.policy_type?void 0:b(e.policy_type),o=null==e.retention_type?void 0:_(e.retention_type),s=null==e.status?void 0:S(e.status),l=null==e.created_by?void 0:(0,a.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,f.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "RetentionPolicy"'});const c=null==e.created_at?void 0:(0,d.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,f.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "RetentionPolicy"'});const h=null==e.modified_at?void 0:(0,d.deserializeDateTime)(e.modified_at);if(null!=e.can_owner_extend_retention&&!(0,p.sdIsBoolean)(e.can_owner_extend_retention))throw new u.BoxSdkError({message:'Expecting boolean for "can_owner_extend_retention" of type "RetentionPolicy"'});const y=null==e.can_owner_extend_retention?void 0:e.can_owner_extend_retention;if(null!=e.are_owners_notified&&!(0,p.sdIsBoolean)(e.are_owners_notified))throw new u.BoxSdkError({message:'Expecting boolean for "are_owners_notified" of type "RetentionPolicy"'});const v=null==e.are_owners_notified?void 0:e.are_owners_notified;if(null!=e.custom_notification_recipients&&!(0,m.sdIsList)(e.custom_notification_recipients))throw new u.BoxSdkError({message:'Expecting array for "custom_notification_recipients" of type "RetentionPolicy"'});const w=null==e.custom_notification_recipients?void 0:(0,m.sdIsList)(e.custom_notification_recipients)?e.custom_notification_recipients.map((function(e){return(0,a.deserializeUserMini)(e)})):[],x=null==e.assignment_counts?void 0:E(e.assignment_counts);if(null!=e.policy_name&&!(0,f.sdIsString)(e.policy_name))throw new u.BoxSdkError({message:'Expecting string for "policy_name" of type "RetentionPolicy"'});const k=null==e.policy_name?void 0:e.policy_name;if(null!=e.retention_length&&!(0,f.sdIsString)(e.retention_length))throw new u.BoxSdkError({message:'Expecting string for "retention_length" of type "RetentionPolicy"'});const T=null==e.retention_length?void 0:e.retention_length,B=null==e.disposition_action?void 0:(0,n.deserializeRetentionPolicyMiniDispositionActionField)(e.disposition_action);if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "RetentionPolicy" to be defined'});if(!(0,f.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicy"'});const C=e.id;if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "RetentionPolicy" to be defined'});const I=(0,i.deserializeRetentionPolicyBaseTypeField)(e.type);return{description:t,policyType:r,retentionType:o,status:s,createdBy:l,createdAt:c,modifiedAt:h,canOwnerExtendRetention:y,areOwnersNotified:v,customNotificationRecipients:w,assignmentCounts:x,policyName:k,retentionLength:T,dispositionAction:B,id:C,type:I}};const i=r(63025),n=r(46855),o=r(46855),s=r(95408),a=r(95408),l=r(93845),d=r(93845),c=r(46855),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793),g=r(50793);class y extends c.RetentionPolicyMini{constructor(e){super(e)}}function v(e){return e}function b(e){if("finite"==e)return e;if("indefinite"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize RetentionPolicyPolicyTypeField"})}function w(e){return e}function _(e){if("modifiable"==e)return e;if("non_modifiable"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize RetentionPolicyRetentionTypeField"})}function x(e){return e}function S(e){if("active"==e)return e;if("retired"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize RetentionPolicyStatusField"})}function k(e){return{enterprise:null==e.enterprise?void 0:e.enterprise,folder:null==e.folder?void 0:e.folder,metadata_template:null==e.metadataTemplate?void 0:e.metadataTemplate}}function E(e){if(!(0,g.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignmentCountsField"'});if(null!=e.enterprise&&!(0,h.sdIsNumber)(e.enterprise))throw new u.BoxSdkError({message:'Expecting number for "enterprise" of type "RetentionPolicyAssignmentCountsField"'});const t=null==e.enterprise?void 0:e.enterprise;if(null!=e.folder&&!(0,h.sdIsNumber)(e.folder))throw new u.BoxSdkError({message:'Expecting number for "folder" of type "RetentionPolicyAssignmentCountsField"'});const r=null==e.folder?void 0:e.folder;if(null!=e.metadata_template&&!(0,h.sdIsNumber)(e.metadata_template))throw new u.BoxSdkError({message:'Expecting number for "metadata_template" of type "RetentionPolicyAssignmentCountsField"'});return{enterprise:t,folder:r,metadataTemplate:null==e.metadata_template?void 0:e.metadata_template}}t.RetentionPolicy=y},62261:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPolicyAssignment=void 0,t.serializeRetentionPolicyAssignmentTypeField=h,t.deserializeRetentionPolicyAssignmentTypeField=f,t.serializeRetentionPolicyAssignmentAssignedToTypeField=m,t.deserializeRetentionPolicyAssignmentAssignedToTypeField=g,t.serializeRetentionPolicyAssignmentAssignedToField=y,t.deserializeRetentionPolicyAssignmentAssignedToField=v,t.serializeRetentionPolicyAssignmentFilterFieldsField=b,t.deserializeRetentionPolicyAssignmentFilterFieldsField=w,t.serializeRetentionPolicyAssignment=function(e){return{id:e.id,type:e.type,retention_policy:null==e.retentionPolicy?void 0:(0,i.serializeRetentionPolicyMini)(e.retentionPolicy),assigned_to:null==e.assignedTo?void 0:y(e.assignedTo),filter_fields:null==e.filterFields?void 0:e.filterFields.map((function(e){return b(e)})),assigned_by:null==e.assignedBy?void 0:(0,o.serializeUserMini)(e.assignedBy),assigned_at:null==e.assignedAt?void 0:(0,a.serializeDateTime)(e.assignedAt),start_date_field:null==e.startDateField?void 0:e.startDateField}},t.deserializeRetentionPolicyAssignment=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignment"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "RetentionPolicyAssignment" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyAssignment"'});const t=e.id;if(null==e.type)throw new d.BoxSdkError({message:'Expecting "type" of type "RetentionPolicyAssignment" to be defined'});const r=f(e.type),i=null==e.retention_policy?void 0:(0,n.deserializeRetentionPolicyMini)(e.retention_policy),o=null==e.assigned_to?void 0:v(e.assigned_to);if(null!=e.filter_fields&&!(0,u.sdIsList)(e.filter_fields))throw new d.BoxSdkError({message:'Expecting array for "filter_fields" of type "RetentionPolicyAssignment"'});const a=null==e.filter_fields?void 0:(0,u.sdIsList)(e.filter_fields)?e.filter_fields.map((function(e){return w(e)})):[],h=null==e.assigned_by?void 0:(0,s.deserializeUserMini)(e.assigned_by);if(null!=e.assigned_at&&!(0,c.sdIsString)(e.assigned_at))throw new d.BoxSdkError({message:'Expecting string for "assigned_at" of type "RetentionPolicyAssignment"'});const m=null==e.assigned_at?void 0:(0,l.deserializeDateTime)(e.assigned_at);if(null!=e.start_date_field&&!(0,c.sdIsString)(e.start_date_field))throw new d.BoxSdkError({message:'Expecting string for "start_date_field" of type "RetentionPolicyAssignment"'});const g=null==e.start_date_field?void 0:e.start_date_field;return{id:t,type:r,retentionPolicy:i,assignedTo:o,filterFields:a,assignedBy:h,assignedAt:m,startDateField:g}},t.serializeRetentionPolicyAssignmentInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,retention_policy:null==e.retentionPolicy?void 0:(0,i.serializeRetentionPolicyMini)(e.retentionPolicy),assigned_to:null==e.assignedTo?void 0:y(e.assignedTo),filter_fields:null==e.filterFields?void 0:e.filterFields.map((function(e){return b(e)})),assigned_by:null==e.assignedBy?void 0:(0,o.serializeUserMini)(e.assignedBy),assigned_at:null==e.assignedAt?void 0:(0,a.serializeDateTime)(e.assignedAt),start_date_field:null==e.startDateField?void 0:e.startDateField}},t.deserializeRetentionPolicyAssignmentInput=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignmentInput"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "RetentionPolicyAssignmentInput" to be defined'});if(!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyAssignmentInput"'});const t=e.id,r=null==e.type?void 0:f(e.type),i=null==e.retention_policy?void 0:(0,n.deserializeRetentionPolicyMini)(e.retention_policy),o=null==e.assigned_to?void 0:v(e.assigned_to);if(null!=e.filter_fields&&!(0,u.sdIsList)(e.filter_fields))throw new d.BoxSdkError({message:'Expecting array for "filter_fields" of type "RetentionPolicyAssignmentInput"'});const a=null==e.filter_fields?void 0:(0,u.sdIsList)(e.filter_fields)?e.filter_fields.map((function(e){return w(e)})):[],h=null==e.assigned_by?void 0:(0,s.deserializeUserMini)(e.assigned_by);if(null!=e.assigned_at&&!(0,c.sdIsString)(e.assigned_at))throw new d.BoxSdkError({message:'Expecting string for "assigned_at" of type "RetentionPolicyAssignmentInput"'});const m=null==e.assigned_at?void 0:(0,l.deserializeDateTime)(e.assigned_at);if(null!=e.start_date_field&&!(0,c.sdIsString)(e.start_date_field))throw new d.BoxSdkError({message:'Expecting string for "start_date_field" of type "RetentionPolicyAssignmentInput"'});const g=null==e.start_date_field?void 0:e.start_date_field;return{id:t,type:r,retentionPolicy:i,assignedTo:o,filterFields:a,assignedBy:h,assignedAt:m,startDateField:g}};const i=r(46855),n=r(46855),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793);function h(e){return e}function f(e){if("retention_policy_assignment"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize RetentionPolicyAssignmentTypeField"})}function m(e){return e}function g(e){if("folder"==e)return e;if("enterprise"==e)return e;if("metadata_template"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize RetentionPolicyAssignmentAssignedToTypeField"})}function y(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function v(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignmentAssignedToField"'});if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyAssignmentAssignedToField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:g(e.type)}}function b(e){return{field:null==e.field?void 0:e.field,value:null==e.value?void 0:e.value}}function w(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignmentFilterFieldsField"'});if(null!=e.field&&!(0,c.sdIsString)(e.field))throw new d.BoxSdkError({message:'Expecting string for "field" of type "RetentionPolicyAssignmentFilterFieldsField"'});const t=null==e.field?void 0:e.field;if(null!=e.value&&!(0,c.sdIsString)(e.value))throw new d.BoxSdkError({message:'Expecting string for "value" of type "RetentionPolicyAssignmentFilterFieldsField"'});return{field:t,value:null==e.value?void 0:e.value}}t.RetentionPolicyAssignment=class{constructor(e){this.type="retention_policy_assignment",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.retentionPolicy&&(this.retentionPolicy=e.retentionPolicy),e.assignedTo&&(this.assignedTo=e.assignedTo),e.filterFields&&(this.filterFields=e.filterFields),e.assignedBy&&(this.assignedBy=e.assignedBy),e.assignedAt&&(this.assignedAt=e.assignedAt),e.startDateField&&(this.startDateField=e.startDateField),e.rawData&&(this.rawData=e.rawData)}}},86162:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeRetentionPolicyAssignments=function(e){return{entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeRetentionPolicyAssignment)(e)})),limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker}},t.deserializeRetentionPolicyAssignments=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "RetentionPolicyAssignments"'});if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "RetentionPolicyAssignments"'});const t=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeRetentionPolicyAssignment)(e)})):[];if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "RetentionPolicyAssignments"'});const r=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "RetentionPolicyAssignments"'});const i=null==e.next_marker?void 0:e.next_marker;return{entries:t,limit:r,nextMarker:i}};const i=r(62261),n=r(62261),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},63025:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPolicyBase=void 0,t.serializeRetentionPolicyBaseTypeField=s,t.deserializeRetentionPolicyBaseTypeField=a,t.serializeRetentionPolicyBase=function(e){return{id:e.id,type:e.type}},t.deserializeRetentionPolicyBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "RetentionPolicyBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "RetentionPolicyBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "RetentionPolicyBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeRetentionPolicyBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeRetentionPolicyBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "RetentionPolicyBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "RetentionPolicyBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("retention_policy"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize RetentionPolicyBaseTypeField"})}t.RetentionPolicyBase=class{constructor(e){this.type="retention_policy",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},46855:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RetentionPolicyMini=void 0,t.serializeRetentionPolicyMiniDispositionActionField=c,t.deserializeRetentionPolicyMiniDispositionActionField=u,t.serializeRetentionPolicyMini=function(e){const t=(0,n.serializeRetentionPolicyBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "RetentionPolicyMini"'});return Object.assign(Object.assign({},t),{policy_name:null==e.policyName?void 0:e.policyName,retention_length:null==e.retentionLength?void 0:e.retentionLength,disposition_action:null==e.dispositionAction?void 0:e.dispositionAction})},t.deserializeRetentionPolicyMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "RetentionPolicyMini"'});if(null!=e.policy_name&&!(0,a.sdIsString)(e.policy_name))throw new s.BoxSdkError({message:'Expecting string for "policy_name" of type "RetentionPolicyMini"'});const t=null==e.policy_name?void 0:e.policy_name;if(null!=e.retention_length&&!(0,a.sdIsString)(e.retention_length))throw new s.BoxSdkError({message:'Expecting string for "retention_length" of type "RetentionPolicyMini"'});const r=null==e.retention_length?void 0:e.retention_length,n=null==e.disposition_action?void 0:u(e.disposition_action);if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "RetentionPolicyMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "RetentionPolicyMini"'});const o=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "RetentionPolicyMini" to be defined'});const d=(0,i.deserializeRetentionPolicyBaseTypeField)(e.type);return{policyName:t,retentionLength:r,dispositionAction:n,id:o,type:d}};const i=r(63025),n=r(63025),o=r(63025),s=r(72631),a=r(50793),l=r(50793);class d extends o.RetentionPolicyBase{constructor(e){super(e)}}function c(e){return e}function u(e){if("permanently_delete"==e)return e;if("remove_retention"==e)return e;throw new s.BoxSdkError({message:"Can't deserialize RetentionPolicyMiniDispositionActionField"})}t.RetentionPolicyMini=d},91236:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RoleVariable=void 0,t.serializeRoleVariableTypeField=o,t.deserializeRoleVariableTypeField=s,t.serializeRoleVariableVariableTypeField=a,t.deserializeRoleVariableVariableTypeField=l,t.serializeRoleVariableVariableValueField=d,t.deserializeRoleVariableVariableValueField=c,t.serializeRoleVariable=function(e){return{type:e.type,variable_type:e.variableType,variable_value:e.variableValue}},t.deserializeRoleVariable=function(e){if(!(0,n.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "RoleVariable"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "RoleVariable" to be defined'});const t=s(e.type);if(null==e.variable_type)throw new i.BoxSdkError({message:'Expecting "variable_type" of type "RoleVariable" to be defined'});const r=l(e.variable_type);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "RoleVariable" to be defined'});const o=c(e.variable_value);return{type:t,variableType:r,variableValue:o}},t.serializeRoleVariableInput=function(e){return{type:null==e.type?void 0:e.type,variableType:null==e.variableType?void 0:e.variableType,variable_value:e.variableValue}},t.deserializeRoleVariableInput=function(e){if(!(0,n.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "RoleVariableInput"'});const t=null==e.type?void 0:s(e.type),r=null==e.variableType?void 0:l(e.variableType);if(null==e.variable_value)throw new i.BoxSdkError({message:'Expecting "variable_value" of type "RoleVariableInput" to be defined'});const o=c(e.variable_value);return{type:t,variableType:r,variableValue:o}};const i=r(72631),n=r(50793);function o(e){return e}function s(e){if("variable"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize RoleVariableTypeField"})}function a(e){return e}function l(e){if("collaborator_role"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize RoleVariableVariableTypeField"})}function d(e){return e}function c(e){if("editor"==e)return e;if("viewer"==e)return e;if("previewer"==e)return e;if("uploader"==e)return e;if("previewer uploader"==e)return e;if("viewer uploader"==e)return e;if("co-owner"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize RoleVariableVariableValueField"})}t.RoleVariable=class{constructor(e){this.type="variable",this.variableType="collaborator_role",e.type&&(this.type=e.type),e.variableType&&(this.variableType=e.variableType),e.variableValue&&(this.variableValue=e.variableValue),e.rawData&&(this.rawData=e.rawData)}}},27212:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSearchResultWithSharedLink=function(e){return{accessible_via_shared_link:null==e.accessibleViaSharedLink?void 0:e.accessibleViaSharedLink,item:null==e.item?void 0:(0,i.serializeFileFullOrFolderFullOrWebLink)(e.item),type:null==e.type?void 0:e.type}},t.deserializeSearchResultWithSharedLink=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SearchResultWithSharedLink"'});if(null!=e.accessible_via_shared_link&&!(0,s.sdIsString)(e.accessible_via_shared_link))throw new o.BoxSdkError({message:'Expecting string for "accessible_via_shared_link" of type "SearchResultWithSharedLink"'});const t=null==e.accessible_via_shared_link?void 0:e.accessible_via_shared_link,r=null==e.item?void 0:(0,n.deserializeFileFullOrFolderFullOrWebLink)(e.item);if(null!=e.type&&!(0,s.sdIsString)(e.type))throw new o.BoxSdkError({message:'Expecting string for "type" of type "SearchResultWithSharedLink"'});const i=null==e.type?void 0:e.type;return{accessibleViaSharedLink:t,item:r,type:i}};const i=r(58820),n=r(58820),o=r(72631),s=r(50793),a=r(50793)},70618:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SearchResults=void 0,t.serializeSearchResultsTypeField=d,t.deserializeSearchResultsTypeField=c,t.serializeSearchResults=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,type:e.type,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileFullOrFolderFullOrWebLink)(e)}))}},t.deserializeSearchResults=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SearchResults"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "SearchResults"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SearchResults"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "SearchResults"'});const i=null==e.offset?void 0:e.offset;if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "SearchResults" to be defined'});const d=c(e.type);if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SearchResults"'});const u=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileFullOrFolderFullOrWebLink)(e)})):[];return{totalCount:t,limit:r,offset:i,type:d,entries:u}},t.serializeSearchResultsInput=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,type:null==e.type?void 0:e.type,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeFileFullOrFolderFullOrWebLink)(e)}))}},t.deserializeSearchResultsInput=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SearchResultsInput"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "SearchResultsInput"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SearchResultsInput"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "SearchResultsInput"'});const i=null==e.offset?void 0:e.offset,d=null==e.type?void 0:c(e.type);if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SearchResultsInput"'});const u=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFileFullOrFolderFullOrWebLink)(e)})):[];return{totalCount:t,limit:r,offset:i,type:d,entries:u}};const i=r(58820),n=r(58820),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("search_results_items"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize SearchResultsTypeField"})}t.SearchResults=class{constructor(e){this.type="search_results_items",e.totalCount&&(this.totalCount=e.totalCount),e.limit&&(this.limit=e.limit),e.offset&&(this.offset=e.offset),e.type&&(this.type=e.type),e.entries&&(this.entries=e.entries),e.rawData&&(this.rawData=e.rawData)}}},76427:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSearchResultsOrSearchResultsWithSharedLinks=function(e){if("search_results_items"==e.type)return(0,i.serializeSearchResults)(e);if("search_results_with_shared_links"==e.type)return(0,o.serializeSearchResultsWithSharedLinks)(e);throw new a.BoxSdkError({message:"unknown type"})},t.deserializeSearchResultsOrSearchResultsWithSharedLinks=function(e){if(!(0,l.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "SearchResultsOrSearchResultsWithSharedLinks"'});if("search_results_items"==e.type)return(0,n.deserializeSearchResults)(e);if("search_results_with_shared_links"==e.type)return(0,s.deserializeSearchResultsWithSharedLinks)(e);throw new a.BoxSdkError({message:"Can't deserialize SearchResultsOrSearchResultsWithSharedLinks"})};const i=r(70618),n=r(70618),o=r(42984),s=r(42984),a=r(72631),l=r(50793)},42984:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SearchResultsWithSharedLinks=void 0,t.serializeSearchResultsWithSharedLinksTypeField=d,t.deserializeSearchResultsWithSharedLinksTypeField=c,t.serializeSearchResultsWithSharedLinks=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,type:e.type,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeSearchResultWithSharedLink)(e)}))}},t.deserializeSearchResultsWithSharedLinks=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SearchResultsWithSharedLinks"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "SearchResultsWithSharedLinks"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SearchResultsWithSharedLinks"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "SearchResultsWithSharedLinks"'});const i=null==e.offset?void 0:e.offset;if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "SearchResultsWithSharedLinks" to be defined'});const d=c(e.type);if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SearchResultsWithSharedLinks"'});const u=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeSearchResultWithSharedLink)(e)})):[];return{totalCount:t,limit:r,offset:i,type:d,entries:u}},t.serializeSearchResultsWithSharedLinksInput=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,type:null==e.type?void 0:e.type,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeSearchResultWithSharedLink)(e)}))}},t.deserializeSearchResultsWithSharedLinksInput=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SearchResultsWithSharedLinksInput"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "SearchResultsWithSharedLinksInput"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SearchResultsWithSharedLinksInput"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "SearchResultsWithSharedLinksInput"'});const i=null==e.offset?void 0:e.offset,d=null==e.type?void 0:c(e.type);if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SearchResultsWithSharedLinksInput"'});const u=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeSearchResultWithSharedLink)(e)})):[];return{totalCount:t,limit:r,offset:i,type:d,entries:u}};const i=r(27212),n=r(27212),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("search_results_with_shared_links"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize SearchResultsWithSharedLinksTypeField"})}t.SearchResultsWithSharedLinks=class{constructor(e){this.type="search_results_with_shared_links",e.totalCount&&(this.totalCount=e.totalCount),e.limit&&(this.limit=e.limit),e.offset&&(this.offset=e.offset),e.type&&(this.type=e.type),e.entries&&(this.entries=e.entries),e.rawData&&(this.rawData=e.rawData)}}},19801:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSessionTerminationMessage=function(e){return{message:null==e.message?void 0:e.message}},t.deserializeSessionTerminationMessage=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "SessionTerminationMessage"'});if(null!=e.message&&!(0,n.sdIsString)(e.message))throw new i.BoxSdkError({message:'Expecting string for "message" of type "SessionTerminationMessage"'});return{message:null==e.message?void 0:e.message}};const i=r(72631),n=r(50793),o=r(50793)},91616:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierTypeField=p,t.deserializeShieldInformationBarrierTypeField=h,t.serializeShieldInformationBarrierStatusField=f,t.deserializeShieldInformationBarrierStatusField=m,t.serializeShieldInformationBarrier=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,enterprise:null==e.enterprise?void 0:(0,i.serializeEnterpriseBase)(e.enterprise),status:null==e.status?void 0:e.status,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserBase)(e.createdBy),updated_at:null==e.updatedAt?void 0:(0,a.serializeDateTime)(e.updatedAt),updated_by:null==e.updatedBy?void 0:(0,o.serializeUserBase)(e.updatedBy),enabled_at:null==e.enabledAt?void 0:(0,a.serializeDateTime)(e.enabledAt),enabled_by:null==e.enabledBy?void 0:(0,o.serializeUserBase)(e.enabledBy)}},t.deserializeShieldInformationBarrier=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrier"'});if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrier"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type),i=null==e.enterprise?void 0:(0,n.deserializeEnterpriseBase)(e.enterprise),o=null==e.status?void 0:m(e.status);if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "ShieldInformationBarrier"'});const a=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at),p=null==e.created_by?void 0:(0,s.deserializeUserBase)(e.created_by);if(null!=e.updated_at&&!(0,c.sdIsString)(e.updated_at))throw new d.BoxSdkError({message:'Expecting string for "updated_at" of type "ShieldInformationBarrier"'});const f=null==e.updated_at?void 0:(0,l.deserializeDateTime)(e.updated_at),g=null==e.updated_by?void 0:(0,s.deserializeUserBase)(e.updated_by);if(null!=e.enabled_at&&!(0,c.sdIsString)(e.enabled_at))throw new d.BoxSdkError({message:'Expecting string for "enabled_at" of type "ShieldInformationBarrier"'});const y=null==e.enabled_at?void 0:(0,l.deserializeDateTime)(e.enabled_at),v=null==e.enabled_by?void 0:(0,s.deserializeUserBase)(e.enabled_by);return{id:t,type:r,enterprise:i,status:o,createdAt:a,createdBy:p,updatedAt:f,updatedBy:g,enabledAt:y,enabledBy:v}};const i=r(75762),n=r(75762),o=r(78366),s=r(78366),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793);function p(e){return e}function h(e){if("shield_information_barrier"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierTypeField"})}function f(e){return e}function m(e){if("draft"==e)return e;if("pending"==e)return e;if("disabled"==e)return e;if("enabled"==e)return e;if("invalid"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierStatusField"})}},945:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierBaseTypeField=s,t.deserializeShieldInformationBarrierBaseTypeField=a,t.serializeShieldInformationBarrierBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeShieldInformationBarrierBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("shield_information_barrier"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierBaseTypeField"})}},44345:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierReference=function(e){return{shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,i.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier)}},t.deserializeShieldInformationBarrierReference=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReference"'});return{shieldInformationBarrier:null==e.shield_information_barrier?void 0:(0,n.deserializeShieldInformationBarrierBase)(e.shield_information_barrier)}};const i=r(945),n=r(945),o=r(72631),s=r(50793)},65382:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierReportStatusField=g,t.deserializeShieldInformationBarrierReportStatusField=y,t.serializeShieldInformationBarrierReport=function(e){const t=(0,n.serializeShieldInformationBarrierReportBase)(e);if(!(0,m.sdIsMap)(t))throw new h.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReport"'});return Object.assign(Object.assign({},t),{shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,o.serializeShieldInformationBarrierReference)(e.shieldInformationBarrier),status:null==e.status?void 0:e.status,details:null==e.details?void 0:(0,a.serializeShieldInformationBarrierReportDetails)(e.details),created_at:null==e.createdAt?void 0:(0,u.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,d.serializeUserBase)(e.createdBy),updated_at:null==e.updatedAt?void 0:(0,u.serializeDateTime)(e.updatedAt)})},t.deserializeShieldInformationBarrierReport=function(e){if(!(0,m.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReport"'});const t=null==e.shield_information_barrier?void 0:(0,s.deserializeShieldInformationBarrierReference)(e.shield_information_barrier),r=null==e.status?void 0:y(e.status),n=null==e.details?void 0:(0,l.deserializeShieldInformationBarrierReportDetails)(e.details);if(null!=e.created_at&&!(0,f.sdIsString)(e.created_at))throw new h.BoxSdkError({message:'Expecting string for "created_at" of type "ShieldInformationBarrierReport"'});const o=null==e.created_at?void 0:(0,p.deserializeDateTime)(e.created_at),a=null==e.created_by?void 0:(0,c.deserializeUserBase)(e.created_by);if(null!=e.updated_at&&!(0,f.sdIsString)(e.updated_at))throw new h.BoxSdkError({message:'Expecting string for "updated_at" of type "ShieldInformationBarrierReport"'});const d=null==e.updated_at?void 0:(0,p.deserializeDateTime)(e.updated_at);if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new h.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierReport"'});const u=null==e.id?void 0:e.id,g=null==e.type?void 0:(0,i.deserializeShieldInformationBarrierReportBaseTypeField)(e.type);return{shieldInformationBarrier:t,status:r,details:n,createdAt:o,createdBy:a,updatedAt:d,id:u,type:g}};const i=r(66655),n=r(66655),o=r(44345),s=r(44345),a=r(83288),l=r(83288),d=r(78366),c=r(78366),u=r(93845),p=r(93845),h=r(72631),f=r(50793),m=r(50793);function g(e){return e}function y(e){if("pending"==e)return e;if("error"==e)return e;if("done"==e)return e;if("cancelled"==e)return e;throw new h.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierReportStatusField"})}},66655:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierReportBaseTypeField=s,t.deserializeShieldInformationBarrierReportBaseTypeField=a,t.serializeShieldInformationBarrierReportBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeShieldInformationBarrierReportBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReportBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierReportBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("shield_information_barrier_report"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierReportBaseTypeField"})}},83288:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierReportDetailsDetailsField=s,t.deserializeShieldInformationBarrierReportDetailsDetailsField=a,t.serializeShieldInformationBarrierReportDetails=function(e){return{details:null==e.details?void 0:s(e.details)}},t.deserializeShieldInformationBarrierReportDetails=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReportDetails"'});return{details:null==e.details?void 0:a(e.details)}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return{folder_id:null==e.folderId?void 0:e.folderId}}function a(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReportDetailsDetailsField"'});if(null!=e.folder_id&&!(0,n.sdIsString)(e.folder_id))throw new i.BoxSdkError({message:'Expecting string for "folder_id" of type "ShieldInformationBarrierReportDetailsDetailsField"'});return{folderId:null==e.folder_id?void 0:e.folder_id}}},89275:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierReports=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeShieldInformationBarrierReport)(e)}))}},t.deserializeShieldInformationBarrierReports=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierReports"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "ShieldInformationBarrierReports"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "ShieldInformationBarrierReports"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "ShieldInformationBarrierReports"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeShieldInformationBarrierReport)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(65382),n=r(65382),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},77749:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentTypeField=p,t.deserializeShieldInformationBarrierSegmentTypeField=h,t.serializeShieldInformationBarrierSegment=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,i.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserBase)(e.createdBy),updated_at:null==e.updatedAt?void 0:(0,a.serializeDateTime)(e.updatedAt),updated_by:null==e.updatedBy?void 0:(0,o.serializeUserBase)(e.updatedBy)}},t.deserializeShieldInformationBarrierSegment=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegment"'});if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegment"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type),i=null==e.shield_information_barrier?void 0:(0,n.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null!=e.name&&!(0,c.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "ShieldInformationBarrierSegment"'});const o=null==e.name?void 0:e.name;if(null!=e.description&&!(0,c.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "ShieldInformationBarrierSegment"'});const a=null==e.description?void 0:e.description;if(null!=e.created_at&&!(0,c.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "ShieldInformationBarrierSegment"'});const p=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at),f=null==e.created_by?void 0:(0,s.deserializeUserBase)(e.created_by);if(null!=e.updated_at&&!(0,c.sdIsString)(e.updated_at))throw new d.BoxSdkError({message:'Expecting string for "updated_at" of type "ShieldInformationBarrierSegment"'});const m=null==e.updated_at?void 0:(0,l.deserializeDateTime)(e.updated_at),g=null==e.updated_by?void 0:(0,s.deserializeUserBase)(e.updated_by);return{id:t,type:r,shieldInformationBarrier:i,name:o,description:a,createdAt:p,createdBy:f,updatedAt:m,updatedBy:g}};const i=r(945),n=r(945),o=r(78366),s=r(78366),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793);function p(e){return e}function h(e){if("shield_information_barrier_segment"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentTypeField"})}},17935:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentTypeField=f,t.deserializeShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentTypeField=m,t.serializeShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentField=g,t.deserializeShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentField=y,t.serializeShieldInformationBarrierSegmentMember=function(e){const t=(0,n.serializeShieldInformationBarrierSegmentMemberMini)(e);if(!(0,h.sdIsMap)(t))throw new u.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMember"'});return Object.assign(Object.assign({},t),{shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,o.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),shield_information_barrier_segment:null==e.shieldInformationBarrierSegment?void 0:g(e.shieldInformationBarrierSegment),created_at:null==e.createdAt?void 0:(0,d.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,a.serializeUserBase)(e.createdBy),updated_at:null==e.updatedAt?void 0:(0,d.serializeDateTime)(e.updatedAt),updated_by:null==e.updatedBy?void 0:(0,a.serializeUserBase)(e.updatedBy)})},t.deserializeShieldInformationBarrierSegmentMember=function(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMember"'});const t=null==e.shield_information_barrier?void 0:(0,s.deserializeShieldInformationBarrierBase)(e.shield_information_barrier),r=null==e.shield_information_barrier_segment?void 0:y(e.shield_information_barrier_segment);if(null!=e.created_at&&!(0,p.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "ShieldInformationBarrierSegmentMember"'});const n=null==e.created_at?void 0:(0,c.deserializeDateTime)(e.created_at),o=null==e.created_by?void 0:(0,l.deserializeUserBase)(e.created_by);if(null!=e.updated_at&&!(0,p.sdIsString)(e.updated_at))throw new u.BoxSdkError({message:'Expecting string for "updated_at" of type "ShieldInformationBarrierSegmentMember"'});const a=null==e.updated_at?void 0:(0,c.deserializeDateTime)(e.updated_at),d=null==e.updated_by?void 0:(0,l.deserializeUserBase)(e.updated_by),f=null==e.user?void 0:(0,l.deserializeUserBase)(e.user);if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentMember"'});const m=null==e.id?void 0:e.id,g=null==e.type?void 0:(0,i.deserializeShieldInformationBarrierSegmentMemberBaseTypeField)(e.type);return{shieldInformationBarrier:t,shieldInformationBarrierSegment:r,createdAt:n,createdBy:o,updatedAt:a,updatedBy:d,user:f,id:m,type:g}};const i=r(27014),n=r(28760),o=r(945),s=r(945),a=r(78366),l=r(78366),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("shield_information_barrier_segment"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentTypeField"})}function g(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function y(e){if(!(0,h.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentField"'});if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentMemberShieldInformationBarrierSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:m(e.type)}}},27014:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentMemberBaseTypeField=s,t.deserializeShieldInformationBarrierSegmentMemberBaseTypeField=a,t.serializeShieldInformationBarrierSegmentMemberBase=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}},t.deserializeShieldInformationBarrierSegmentMemberBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMemberBase"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentMemberBase"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("shield_information_barrier_segment_member"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentMemberBaseTypeField"})}},28760:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentMemberMini=function(e){const t=(0,n.serializeShieldInformationBarrierSegmentMemberBase)(e);if(!(0,d.sdIsMap)(t))throw new a.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMemberMini"'});return Object.assign(Object.assign({},t),{user:null==e.user?void 0:(0,o.serializeUserBase)(e.user)})},t.deserializeShieldInformationBarrierSegmentMemberMini=function(e){if(!(0,d.sdIsMap)(e))throw new a.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMemberMini"'});const t=null==e.user?void 0:(0,s.deserializeUserBase)(e.user);if(null!=e.id&&!(0,l.sdIsString)(e.id))throw new a.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentMemberMini"'});const r=null==e.id?void 0:e.id,n=null==e.type?void 0:(0,i.deserializeShieldInformationBarrierSegmentMemberBaseTypeField)(e.type);return{user:t,id:r,type:n}};const i=r(27014),n=r(27014),o=r(78366),s=r(78366),a=r(72631),l=r(50793),d=r(50793)},48620:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentMembers=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeShieldInformationBarrierSegmentMember)(e)}))}},t.deserializeShieldInformationBarrierSegmentMembers=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentMembers"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "ShieldInformationBarrierSegmentMembers"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "ShieldInformationBarrierSegmentMembers"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "ShieldInformationBarrierSegmentMembers"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeShieldInformationBarrierSegmentMember)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(17935),n=r(17935),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},51325:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentRestriction=function(e){const t=(0,s.serializeShieldInformationBarrierSegmentRestrictionMini)(e);if(!(0,m.sdIsMap)(t))throw new h.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestriction"'});return Object.assign(Object.assign({},t),{shield_information_barrier:null==e.shieldInformationBarrier?void 0:(0,a.serializeShieldInformationBarrierBase)(e.shieldInformationBarrier),created_at:null==e.createdAt?void 0:(0,u.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,d.serializeUserBase)(e.createdBy),updated_at:null==e.updatedAt?void 0:(0,u.serializeDateTime)(e.updatedAt),updated_by:null==e.updatedBy?void 0:(0,d.serializeUserBase)(e.updatedBy)})},t.deserializeShieldInformationBarrierSegmentRestriction=function(e){if(!(0,m.sdIsMap)(e))throw new h.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestriction"'});const t=null==e.shield_information_barrier?void 0:(0,l.deserializeShieldInformationBarrierBase)(e.shield_information_barrier);if(null!=e.created_at&&!(0,f.sdIsString)(e.created_at))throw new h.BoxSdkError({message:'Expecting string for "created_at" of type "ShieldInformationBarrierSegmentRestriction"'});const r=null==e.created_at?void 0:(0,p.deserializeDateTime)(e.created_at),s=null==e.created_by?void 0:(0,c.deserializeUserBase)(e.created_by);if(null!=e.updated_at&&!(0,f.sdIsString)(e.updated_at))throw new h.BoxSdkError({message:'Expecting string for "updated_at" of type "ShieldInformationBarrierSegmentRestriction"'});const a=null==e.updated_at?void 0:(0,p.deserializeDateTime)(e.updated_at),d=null==e.updated_by?void 0:(0,c.deserializeUserBase)(e.updated_by);if(null==e.shield_information_barrier_segment)throw new h.BoxSdkError({message:'Expecting "shield_information_barrier_segment" of type "ShieldInformationBarrierSegmentRestriction" to be defined'});const u=(0,n.deserializeShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentField)(e.shield_information_barrier_segment);if(null==e.restricted_segment)throw new h.BoxSdkError({message:'Expecting "restricted_segment" of type "ShieldInformationBarrierSegmentRestriction" to be defined'});const g=(0,o.deserializeShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentField)(e.restricted_segment),y=null==e.type?void 0:(0,i.deserializeShieldInformationBarrierSegmentRestrictionBaseTypeField)(e.type);if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new h.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentRestriction"'});const v=null==e.id?void 0:e.id;return{shieldInformationBarrier:t,createdAt:r,createdBy:s,updatedAt:a,updatedBy:d,shieldInformationBarrierSegment:u,restrictedSegment:g,type:y,id:v}};const i=r(95420),n=r(63346),o=r(63346),s=r(63346),a=r(945),l=r(945),d=r(78366),c=r(78366),u=r(93845),p=r(93845),h=r(72631),f=r(50793),m=r(50793)},95420:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentRestrictionBaseTypeField=s,t.deserializeShieldInformationBarrierSegmentRestrictionBaseTypeField=a,t.serializeShieldInformationBarrierSegmentRestrictionBase=function(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}},t.deserializeShieldInformationBarrierSegmentRestrictionBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictionBase"'});const t=null==e.type?void 0:a(e.type);if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentRestrictionBase"'});const r=null==e.id?void 0:e.id;return{type:t,id:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("shield_information_barrier_segment_restriction"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentRestrictionBaseTypeField"})}},63346:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentTypeField=l,t.deserializeShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentTypeField=d,t.serializeShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentField=c,t.deserializeShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentField=u,t.serializeShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentTypeField=p,t.deserializeShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentTypeField=h,t.serializeShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentField=f,t.deserializeShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentField=m,t.serializeShieldInformationBarrierSegmentRestrictionMini=function(e){const t=(0,n.serializeShieldInformationBarrierSegmentRestrictionBase)(e);if(!(0,a.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictionMini"'});return Object.assign(Object.assign({},t),{shield_information_barrier_segment:c(e.shieldInformationBarrierSegment),restricted_segment:f(e.restrictedSegment)})},t.deserializeShieldInformationBarrierSegmentRestrictionMini=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictionMini"'});if(null==e.shield_information_barrier_segment)throw new o.BoxSdkError({message:'Expecting "shield_information_barrier_segment" of type "ShieldInformationBarrierSegmentRestrictionMini" to be defined'});const t=u(e.shield_information_barrier_segment);if(null==e.restricted_segment)throw new o.BoxSdkError({message:'Expecting "restricted_segment" of type "ShieldInformationBarrierSegmentRestrictionMini" to be defined'});const r=m(e.restricted_segment),n=null==e.type?void 0:(0,i.deserializeShieldInformationBarrierSegmentRestrictionBaseTypeField)(e.type);if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentRestrictionMini"'});const l=null==e.id?void 0:e.id;return{shieldInformationBarrierSegment:t,restrictedSegment:r,type:n,id:l}};const i=r(95420),n=r(95420),o=r(72631),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("shield_information_barrier_segment"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentTypeField"})}function c(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function u(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentField"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentRestrictionMiniShieldInformationBarrierSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:d(e.type)}}function p(e){return e}function h(e){if("shield_information_barrier_segment"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize ShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentTypeField"})}function f(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function m(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentField"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "ShieldInformationBarrierSegmentRestrictionMiniRestrictedSegmentField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:h(e.type)}}},10:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegmentRestrictions=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeShieldInformationBarrierSegmentRestriction)(e)}))}},t.deserializeShieldInformationBarrierSegmentRestrictions=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegmentRestrictions"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "ShieldInformationBarrierSegmentRestrictions"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "ShieldInformationBarrierSegmentRestrictions"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "ShieldInformationBarrierSegmentRestrictions"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeShieldInformationBarrierSegmentRestriction)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(51325),n=r(51325),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},59410:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarrierSegments=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeShieldInformationBarrierSegment)(e)}))}},t.deserializeShieldInformationBarrierSegments=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarrierSegments"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "ShieldInformationBarrierSegments"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "ShieldInformationBarrierSegments"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "ShieldInformationBarrierSegments"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeShieldInformationBarrierSegment)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(77749),n=r(77749),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},38317:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeShieldInformationBarriers=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeShieldInformationBarrier)(e)}))}},t.deserializeShieldInformationBarriers=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ShieldInformationBarriers"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "ShieldInformationBarriers"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "ShieldInformationBarriers"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "ShieldInformationBarriers"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeShieldInformationBarrier)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(91616),n=r(91616),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},86982:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestTypeField=_,t.deserializeSignRequestTypeField=x,t.serializeSignRequestStatusField=S,t.deserializeSignRequestStatusField=k,t.serializeSignRequestSignFilesField=E,t.deserializeSignRequestSignFilesField=T,t.serializeSignRequest=function(e){const t=(0,n.serializeSignRequestBase)(e);if(!(0,w.sdIsMap)(t))throw new m.BoxSdkError({message:'Expecting a map for "SignRequest"'});return Object.assign(Object.assign({},t),{type:null==e.type?void 0:e.type,source_files:null==e.sourceFiles?void 0:e.sourceFiles.map((function(e){return(0,o.serializeFileBase)(e)})),signers:null==e.signers?void 0:e.signers.map((function(e){return(0,a.serializeSignRequestSigner)(e)})),signature_color:null==e.signatureColor?void 0:e.signatureColor,id:null==e.id?void 0:e.id,prepare_url:null==e.prepareUrl?void 0:e.prepareUrl,signing_log:null==e.signingLog?void 0:(0,d.serializeFileMini)(e.signingLog),status:null==e.status?void 0:e.status,sign_files:null==e.signFiles?void 0:E(e.signFiles),auto_expire_at:null==e.autoExpireAt?void 0:(0,h.serializeDateTime)(e.autoExpireAt),parent_folder:null==e.parentFolder?void 0:(0,u.serializeFolderMini)(e.parentFolder)})},t.deserializeSignRequest=function(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "SignRequest"'});const t=null==e.type?void 0:x(e.type);if(null!=e.source_files&&!(0,b.sdIsList)(e.source_files))throw new m.BoxSdkError({message:'Expecting array for "source_files" of type "SignRequest"'});const r=null==e.source_files?void 0:(0,b.sdIsList)(e.source_files)?e.source_files.map((function(e){return(0,s.deserializeFileBase)(e)})):[];if(null!=e.signers&&!(0,b.sdIsList)(e.signers))throw new m.BoxSdkError({message:'Expecting array for "signers" of type "SignRequest"'});const n=null==e.signers?void 0:(0,b.sdIsList)(e.signers)?e.signers.map((function(e){return(0,l.deserializeSignRequestSigner)(e)})):[];if(null!=e.signature_color&&!(0,v.sdIsString)(e.signature_color))throw new m.BoxSdkError({message:'Expecting string for "signature_color" of type "SignRequest"'});const o=null==e.signature_color?void 0:e.signature_color;if(null!=e.id&&!(0,v.sdIsString)(e.id))throw new m.BoxSdkError({message:'Expecting string for "id" of type "SignRequest"'});const a=null==e.id?void 0:e.id;if(null!=e.prepare_url&&!(0,v.sdIsString)(e.prepare_url))throw new m.BoxSdkError({message:'Expecting string for "prepare_url" of type "SignRequest"'});const d=null==e.prepare_url?void 0:e.prepare_url,u=null==e.signing_log?void 0:(0,c.deserializeFileMini)(e.signing_log),h=null==e.status?void 0:k(e.status),_=null==e.sign_files?void 0:T(e.sign_files);if(null!=e.auto_expire_at&&!(0,v.sdIsString)(e.auto_expire_at))throw new m.BoxSdkError({message:'Expecting string for "auto_expire_at" of type "SignRequest"'});const S=null==e.auto_expire_at?void 0:(0,f.deserializeDateTime)(e.auto_expire_at),E=null==e.parent_folder?void 0:(0,p.deserializeFolderMini)(e.parent_folder);if(null!=e.is_document_preparation_needed&&!(0,g.sdIsBoolean)(e.is_document_preparation_needed))throw new m.BoxSdkError({message:'Expecting boolean for "is_document_preparation_needed" of type "SignRequest"'});const B=null==e.is_document_preparation_needed?void 0:e.is_document_preparation_needed;if(null!=e.redirect_url&&!(0,v.sdIsString)(e.redirect_url))throw new m.BoxSdkError({message:'Expecting string for "redirect_url" of type "SignRequest"'});const C=null==e.redirect_url?void 0:e.redirect_url;if(null!=e.declined_redirect_url&&!(0,v.sdIsString)(e.declined_redirect_url))throw new m.BoxSdkError({message:'Expecting string for "declined_redirect_url" of type "SignRequest"'});const I=null==e.declined_redirect_url?void 0:e.declined_redirect_url;if(null!=e.are_text_signatures_enabled&&!(0,g.sdIsBoolean)(e.are_text_signatures_enabled))throw new m.BoxSdkError({message:'Expecting boolean for "are_text_signatures_enabled" of type "SignRequest"'});const A=null==e.are_text_signatures_enabled?void 0:e.are_text_signatures_enabled;if(null!=e.email_subject&&!(0,v.sdIsString)(e.email_subject))throw new m.BoxSdkError({message:'Expecting string for "email_subject" of type "SignRequest"'});const F=null==e.email_subject?void 0:e.email_subject;if(null!=e.email_message&&!(0,v.sdIsString)(e.email_message))throw new m.BoxSdkError({message:'Expecting string for "email_message" of type "SignRequest"'});const M=null==e.email_message?void 0:e.email_message;if(null!=e.are_reminders_enabled&&!(0,g.sdIsBoolean)(e.are_reminders_enabled))throw new m.BoxSdkError({message:'Expecting boolean for "are_reminders_enabled" of type "SignRequest"'});const D=null==e.are_reminders_enabled?void 0:e.are_reminders_enabled;if(null!=e.name&&!(0,v.sdIsString)(e.name))throw new m.BoxSdkError({message:'Expecting string for "name" of type "SignRequest"'});const R=null==e.name?void 0:e.name;if(null!=e.prefill_tags&&!(0,b.sdIsList)(e.prefill_tags))throw new m.BoxSdkError({message:'Expecting array for "prefill_tags" of type "SignRequest"'});const P=null==e.prefill_tags?void 0:(0,b.sdIsList)(e.prefill_tags)?e.prefill_tags.map((function(e){return(0,i.deserializeSignRequestPrefillTag)(e)})):[];if(null!=e.days_valid&&!(0,y.sdIsNumber)(e.days_valid))throw new m.BoxSdkError({message:'Expecting number for "days_valid" of type "SignRequest"'});const O=null==e.days_valid?void 0:e.days_valid;if(null!=e.external_id&&!(0,v.sdIsString)(e.external_id))throw new m.BoxSdkError({message:'Expecting string for "external_id" of type "SignRequest"'});const z=null==e.external_id?void 0:e.external_id;if(null!=e.is_phone_verification_required_to_view&&!(0,g.sdIsBoolean)(e.is_phone_verification_required_to_view))throw new m.BoxSdkError({message:'Expecting boolean for "is_phone_verification_required_to_view" of type "SignRequest"'});const N=null==e.is_phone_verification_required_to_view?void 0:e.is_phone_verification_required_to_view;if(null!=e.template_id&&!(0,v.sdIsString)(e.template_id))throw new m.BoxSdkError({message:'Expecting string for "template_id" of type "SignRequest"'});const q=null==e.template_id?void 0:e.template_id;if(null!=e.external_system_name&&!(0,v.sdIsString)(e.external_system_name))throw new m.BoxSdkError({message:'Expecting string for "external_system_name" of type "SignRequest"'});const U=null==e.external_system_name?void 0:e.external_system_name;return{type:t,sourceFiles:r,signers:n,signatureColor:o,id:a,prepareUrl:d,signingLog:u,status:h,signFiles:_,autoExpireAt:S,parentFolder:E,isDocumentPreparationNeeded:B,redirectUrl:C,declinedRedirectUrl:I,areTextSignaturesEnabled:A,emailSubject:F,emailMessage:M,areRemindersEnabled:D,name:R,prefillTags:P,daysValid:O,externalId:z,isPhoneVerificationRequiredToView:N,templateId:q,externalSystemName:U}};const i=r(3798),n=r(32991),o=r(39455),s=r(39455),a=r(47636),l=r(47636),d=r(62929),c=r(62929),u=r(70343),p=r(70343),h=r(93845),f=r(93845),m=r(72631),g=r(50793),y=r(50793),v=r(50793),b=r(50793),w=r(50793);function _(e){return e}function x(e){if("sign-request"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize SignRequestTypeField"})}function S(e){return e}function k(e){if("converting"==e)return e;if("created"==e)return e;if("sent"==e)return e;if("viewed"==e)return e;if("signed"==e)return e;if("cancelled"==e)return e;if("declined"==e)return e;if("error_converting"==e)return e;if("error_sending"==e)return e;if("expired"==e)return e;if("finalizing"==e)return e;if("error_finalizing"==e)return e;throw new m.BoxSdkError({message:"Can't deserialize SignRequestStatusField"})}function E(e){return{files:null==e.files?void 0:e.files.map((function(e){return(0,d.serializeFileMini)(e)})),is_ready_for_download:null==e.isReadyForDownload?void 0:e.isReadyForDownload}}function T(e){if(!(0,w.sdIsMap)(e))throw new m.BoxSdkError({message:'Expecting a map for "SignRequestSignFilesField"'});if(null!=e.files&&!(0,b.sdIsList)(e.files))throw new m.BoxSdkError({message:'Expecting array for "files" of type "SignRequestSignFilesField"'});const t=null==e.files?void 0:(0,b.sdIsList)(e.files)?e.files.map((function(e){return(0,c.deserializeFileMini)(e)})):[];if(null!=e.is_ready_for_download&&!(0,g.sdIsBoolean)(e.is_ready_for_download))throw new m.BoxSdkError({message:'Expecting boolean for "is_ready_for_download" of type "SignRequestSignFilesField"'});return{files:t,isReadyForDownload:null==e.is_ready_for_download?void 0:e.is_ready_for_download}}},32991:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestBase=function(e){return{is_document_preparation_needed:null==e.isDocumentPreparationNeeded?void 0:e.isDocumentPreparationNeeded,redirect_url:null==e.redirectUrl?void 0:e.redirectUrl,declined_redirect_url:null==e.declinedRedirectUrl?void 0:e.declinedRedirectUrl,are_text_signatures_enabled:null==e.areTextSignaturesEnabled?void 0:e.areTextSignaturesEnabled,email_subject:null==e.emailSubject?void 0:e.emailSubject,email_message:null==e.emailMessage?void 0:e.emailMessage,are_reminders_enabled:null==e.areRemindersEnabled?void 0:e.areRemindersEnabled,name:null==e.name?void 0:e.name,prefill_tags:null==e.prefillTags?void 0:e.prefillTags.map((function(e){return(0,i.serializeSignRequestPrefillTag)(e)})),days_valid:null==e.daysValid?void 0:e.daysValid,external_id:null==e.externalId?void 0:e.externalId,is_phone_verification_required_to_view:null==e.isPhoneVerificationRequiredToView?void 0:e.isPhoneVerificationRequiredToView,template_id:null==e.templateId?void 0:e.templateId,external_system_name:null==e.externalSystemName?void 0:e.externalSystemName}},t.deserializeSignRequestBase=function(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SignRequestBase"'});if(null!=e.is_document_preparation_needed&&!(0,s.sdIsBoolean)(e.is_document_preparation_needed))throw new o.BoxSdkError({message:'Expecting boolean for "is_document_preparation_needed" of type "SignRequestBase"'});const t=null==e.is_document_preparation_needed?void 0:e.is_document_preparation_needed;if(null!=e.redirect_url&&!(0,l.sdIsString)(e.redirect_url))throw new o.BoxSdkError({message:'Expecting string for "redirect_url" of type "SignRequestBase"'});const r=null==e.redirect_url?void 0:e.redirect_url;if(null!=e.declined_redirect_url&&!(0,l.sdIsString)(e.declined_redirect_url))throw new o.BoxSdkError({message:'Expecting string for "declined_redirect_url" of type "SignRequestBase"'});const i=null==e.declined_redirect_url?void 0:e.declined_redirect_url;if(null!=e.are_text_signatures_enabled&&!(0,s.sdIsBoolean)(e.are_text_signatures_enabled))throw new o.BoxSdkError({message:'Expecting boolean for "are_text_signatures_enabled" of type "SignRequestBase"'});const u=null==e.are_text_signatures_enabled?void 0:e.are_text_signatures_enabled;if(null!=e.email_subject&&!(0,l.sdIsString)(e.email_subject))throw new o.BoxSdkError({message:'Expecting string for "email_subject" of type "SignRequestBase"'});const p=null==e.email_subject?void 0:e.email_subject;if(null!=e.email_message&&!(0,l.sdIsString)(e.email_message))throw new o.BoxSdkError({message:'Expecting string for "email_message" of type "SignRequestBase"'});const h=null==e.email_message?void 0:e.email_message;if(null!=e.are_reminders_enabled&&!(0,s.sdIsBoolean)(e.are_reminders_enabled))throw new o.BoxSdkError({message:'Expecting boolean for "are_reminders_enabled" of type "SignRequestBase"'});const f=null==e.are_reminders_enabled?void 0:e.are_reminders_enabled;if(null!=e.name&&!(0,l.sdIsString)(e.name))throw new o.BoxSdkError({message:'Expecting string for "name" of type "SignRequestBase"'});const m=null==e.name?void 0:e.name;if(null!=e.prefill_tags&&!(0,d.sdIsList)(e.prefill_tags))throw new o.BoxSdkError({message:'Expecting array for "prefill_tags" of type "SignRequestBase"'});const g=null==e.prefill_tags?void 0:(0,d.sdIsList)(e.prefill_tags)?e.prefill_tags.map((function(e){return(0,n.deserializeSignRequestPrefillTag)(e)})):[];if(null!=e.days_valid&&!(0,a.sdIsNumber)(e.days_valid))throw new o.BoxSdkError({message:'Expecting number for "days_valid" of type "SignRequestBase"'});const y=null==e.days_valid?void 0:e.days_valid;if(null!=e.external_id&&!(0,l.sdIsString)(e.external_id))throw new o.BoxSdkError({message:'Expecting string for "external_id" of type "SignRequestBase"'});const v=null==e.external_id?void 0:e.external_id;if(null!=e.is_phone_verification_required_to_view&&!(0,s.sdIsBoolean)(e.is_phone_verification_required_to_view))throw new o.BoxSdkError({message:'Expecting boolean for "is_phone_verification_required_to_view" of type "SignRequestBase"'});const b=null==e.is_phone_verification_required_to_view?void 0:e.is_phone_verification_required_to_view;if(null!=e.template_id&&!(0,l.sdIsString)(e.template_id))throw new o.BoxSdkError({message:'Expecting string for "template_id" of type "SignRequestBase"'});const w=null==e.template_id?void 0:e.template_id;if(null!=e.external_system_name&&!(0,l.sdIsString)(e.external_system_name))throw new o.BoxSdkError({message:'Expecting string for "external_system_name" of type "SignRequestBase"'});const _=null==e.external_system_name?void 0:e.external_system_name;return{isDocumentPreparationNeeded:t,redirectUrl:r,declinedRedirectUrl:i,areTextSignaturesEnabled:u,emailSubject:p,emailMessage:h,areRemindersEnabled:f,name:m,prefillTags:g,daysValid:y,externalId:v,isPhoneVerificationRequiredToView:b,templateId:w,externalSystemName:_}};const i=r(3798),n=r(3798),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793),c=r(50793)},32571:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestCreateRequestSignatureColorField=y,t.deserializeSignRequestCreateRequestSignatureColorField=v,t.serializeSignRequestCreateRequest=function(e){const t=(0,n.serializeSignRequestBase)(e);if(!(0,g.sdIsMap)(t))throw new u.BoxSdkError({message:'Expecting a map for "SignRequestCreateRequest"'});return Object.assign(Object.assign({},t),{source_files:null==e.sourceFiles?void 0:e.sourceFiles.map((function(e){return(0,o.serializeFileBase)(e)})),signature_color:null==e.signatureColor?void 0:e.signatureColor,signers:e.signers.map((function(e){return(0,a.serializeSignRequestCreateSigner)(e)})),parent_folder:null==e.parentFolder?void 0:(0,d.serializeFolderMini)(e.parentFolder)})},t.deserializeSignRequestCreateRequest=function(e){if(!(0,g.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "SignRequestCreateRequest"'});if(null!=e.source_files&&!(0,m.sdIsList)(e.source_files))throw new u.BoxSdkError({message:'Expecting array for "source_files" of type "SignRequestCreateRequest"'});const t=null==e.source_files?void 0:(0,m.sdIsList)(e.source_files)?e.source_files.map((function(e){return(0,s.deserializeFileBase)(e)})):[],r=null==e.signature_color?void 0:v(e.signature_color);if(null==e.signers)throw new u.BoxSdkError({message:'Expecting "signers" of type "SignRequestCreateRequest" to be defined'});if(!(0,m.sdIsList)(e.signers))throw new u.BoxSdkError({message:'Expecting array for "signers" of type "SignRequestCreateRequest"'});const n=(0,m.sdIsList)(e.signers)?e.signers.map((function(e){return(0,l.deserializeSignRequestCreateSigner)(e)})):[],o=null==e.parent_folder?void 0:(0,c.deserializeFolderMini)(e.parent_folder);if(null!=e.is_document_preparation_needed&&!(0,p.sdIsBoolean)(e.is_document_preparation_needed))throw new u.BoxSdkError({message:'Expecting boolean for "is_document_preparation_needed" of type "SignRequestCreateRequest"'});const a=null==e.is_document_preparation_needed?void 0:e.is_document_preparation_needed;if(null!=e.redirect_url&&!(0,f.sdIsString)(e.redirect_url))throw new u.BoxSdkError({message:'Expecting string for "redirect_url" of type "SignRequestCreateRequest"'});const d=null==e.redirect_url?void 0:e.redirect_url;if(null!=e.declined_redirect_url&&!(0,f.sdIsString)(e.declined_redirect_url))throw new u.BoxSdkError({message:'Expecting string for "declined_redirect_url" of type "SignRequestCreateRequest"'});const y=null==e.declined_redirect_url?void 0:e.declined_redirect_url;if(null!=e.are_text_signatures_enabled&&!(0,p.sdIsBoolean)(e.are_text_signatures_enabled))throw new u.BoxSdkError({message:'Expecting boolean for "are_text_signatures_enabled" of type "SignRequestCreateRequest"'});const b=null==e.are_text_signatures_enabled?void 0:e.are_text_signatures_enabled;if(null!=e.email_subject&&!(0,f.sdIsString)(e.email_subject))throw new u.BoxSdkError({message:'Expecting string for "email_subject" of type "SignRequestCreateRequest"'});const w=null==e.email_subject?void 0:e.email_subject;if(null!=e.email_message&&!(0,f.sdIsString)(e.email_message))throw new u.BoxSdkError({message:'Expecting string for "email_message" of type "SignRequestCreateRequest"'});const _=null==e.email_message?void 0:e.email_message;if(null!=e.are_reminders_enabled&&!(0,p.sdIsBoolean)(e.are_reminders_enabled))throw new u.BoxSdkError({message:'Expecting boolean for "are_reminders_enabled" of type "SignRequestCreateRequest"'});const x=null==e.are_reminders_enabled?void 0:e.are_reminders_enabled;if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "SignRequestCreateRequest"'});const S=null==e.name?void 0:e.name;if(null!=e.prefill_tags&&!(0,m.sdIsList)(e.prefill_tags))throw new u.BoxSdkError({message:'Expecting array for "prefill_tags" of type "SignRequestCreateRequest"'});const k=null==e.prefill_tags?void 0:(0,m.sdIsList)(e.prefill_tags)?e.prefill_tags.map((function(e){return(0,i.deserializeSignRequestPrefillTag)(e)})):[];if(null!=e.days_valid&&!(0,h.sdIsNumber)(e.days_valid))throw new u.BoxSdkError({message:'Expecting number for "days_valid" of type "SignRequestCreateRequest"'});const E=null==e.days_valid?void 0:e.days_valid;if(null!=e.external_id&&!(0,f.sdIsString)(e.external_id))throw new u.BoxSdkError({message:'Expecting string for "external_id" of type "SignRequestCreateRequest"'});const T=null==e.external_id?void 0:e.external_id;if(null!=e.is_phone_verification_required_to_view&&!(0,p.sdIsBoolean)(e.is_phone_verification_required_to_view))throw new u.BoxSdkError({message:'Expecting boolean for "is_phone_verification_required_to_view" of type "SignRequestCreateRequest"'});const B=null==e.is_phone_verification_required_to_view?void 0:e.is_phone_verification_required_to_view;if(null!=e.template_id&&!(0,f.sdIsString)(e.template_id))throw new u.BoxSdkError({message:'Expecting string for "template_id" of type "SignRequestCreateRequest"'});const C=null==e.template_id?void 0:e.template_id;if(null!=e.external_system_name&&!(0,f.sdIsString)(e.external_system_name))throw new u.BoxSdkError({message:'Expecting string for "external_system_name" of type "SignRequestCreateRequest"'});const I=null==e.external_system_name?void 0:e.external_system_name;return{sourceFiles:t,signatureColor:r,signers:n,parentFolder:o,isDocumentPreparationNeeded:a,redirectUrl:d,declinedRedirectUrl:y,areTextSignaturesEnabled:b,emailSubject:w,emailMessage:_,areRemindersEnabled:x,name:S,prefillTags:k,daysValid:E,externalId:T,isPhoneVerificationRequiredToView:B,templateId:C,externalSystemName:I}};const i=r(3798),n=r(32991),o=r(39455),s=r(39455),a=r(15248),l=r(15248),d=r(70343),c=r(70343),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793),g=r(50793);function y(e){return e}function v(e){if("blue"==e)return e;if("black"==e)return e;if("red"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize SignRequestCreateRequestSignatureColorField"})}},15248:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestCreateSignerRoleField=l,t.deserializeSignRequestCreateSignerRoleField=d,t.serializeSignRequestCreateSigner=function(e){return{email:null==e.email?void 0:e.email,role:null==e.role?void 0:e.role,is_in_person:null==e.isInPerson?void 0:e.isInPerson,order:null==e.order?void 0:e.order,embed_url_external_user_id:null==e.embedUrlExternalUserId?void 0:e.embedUrlExternalUserId,redirect_url:null==e.redirectUrl?void 0:e.redirectUrl,declined_redirect_url:null==e.declinedRedirectUrl?void 0:e.declinedRedirectUrl,login_required:null==e.loginRequired?void 0:e.loginRequired,verification_phone_number:null==e.verificationPhoneNumber?void 0:e.verificationPhoneNumber,password:null==e.password?void 0:e.password,signer_group_id:null==e.signerGroupId?void 0:e.signerGroupId,suppress_notifications:null==e.suppressNotifications?void 0:e.suppressNotifications}},t.deserializeSignRequestCreateSigner=function(e){if(!(0,a.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "SignRequestCreateSigner"'});if(null!=e.email&&!(0,s.sdIsString)(e.email))throw new i.BoxSdkError({message:'Expecting string for "email" of type "SignRequestCreateSigner"'});const t=null==e.email?void 0:e.email,r=null==e.role?void 0:d(e.role);if(null!=e.is_in_person&&!(0,n.sdIsBoolean)(e.is_in_person))throw new i.BoxSdkError({message:'Expecting boolean for "is_in_person" of type "SignRequestCreateSigner"'});const l=null==e.is_in_person?void 0:e.is_in_person;if(null!=e.order&&!(0,o.sdIsNumber)(e.order))throw new i.BoxSdkError({message:'Expecting number for "order" of type "SignRequestCreateSigner"'});const c=null==e.order?void 0:e.order;if(null!=e.embed_url_external_user_id&&!(0,s.sdIsString)(e.embed_url_external_user_id))throw new i.BoxSdkError({message:'Expecting string for "embed_url_external_user_id" of type "SignRequestCreateSigner"'});const u=null==e.embed_url_external_user_id?void 0:e.embed_url_external_user_id;if(null!=e.redirect_url&&!(0,s.sdIsString)(e.redirect_url))throw new i.BoxSdkError({message:'Expecting string for "redirect_url" of type "SignRequestCreateSigner"'});const p=null==e.redirect_url?void 0:e.redirect_url;if(null!=e.declined_redirect_url&&!(0,s.sdIsString)(e.declined_redirect_url))throw new i.BoxSdkError({message:'Expecting string for "declined_redirect_url" of type "SignRequestCreateSigner"'});const h=null==e.declined_redirect_url?void 0:e.declined_redirect_url;if(null!=e.login_required&&!(0,n.sdIsBoolean)(e.login_required))throw new i.BoxSdkError({message:'Expecting boolean for "login_required" of type "SignRequestCreateSigner"'});const f=null==e.login_required?void 0:e.login_required;if(null!=e.verification_phone_number&&!(0,s.sdIsString)(e.verification_phone_number))throw new i.BoxSdkError({message:'Expecting string for "verification_phone_number" of type "SignRequestCreateSigner"'});const m=null==e.verification_phone_number?void 0:e.verification_phone_number;if(null!=e.password&&!(0,s.sdIsString)(e.password))throw new i.BoxSdkError({message:'Expecting string for "password" of type "SignRequestCreateSigner"'});const g=null==e.password?void 0:e.password;if(null!=e.signer_group_id&&!(0,s.sdIsString)(e.signer_group_id))throw new i.BoxSdkError({message:'Expecting string for "signer_group_id" of type "SignRequestCreateSigner"'});const y=null==e.signer_group_id?void 0:e.signer_group_id;if(null!=e.suppress_notifications&&!(0,n.sdIsBoolean)(e.suppress_notifications))throw new i.BoxSdkError({message:'Expecting boolean for "suppress_notifications" of type "SignRequestCreateSigner"'});const v=null==e.suppress_notifications?void 0:e.suppress_notifications;return{email:t,role:r,isInPerson:l,order:c,embedUrlExternalUserId:u,redirectUrl:p,declinedRedirectUrl:h,loginRequired:f,verificationPhoneNumber:m,password:g,signerGroupId:y,suppressNotifications:v}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("signer"==e)return e;if("approver"==e)return e;if("final_copy_reader"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize SignRequestCreateSignerRoleField"})}},3798:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestPrefillTag=function(e){return{document_tag_id:null==e.documentTagId?void 0:e.documentTagId,text_value:null==e.textValue?void 0:e.textValue,checkbox_value:null==e.checkboxValue?void 0:e.checkboxValue,date_value:null==e.dateValue?void 0:(0,i.serializeDate)(e.dateValue)}},t.deserializeSignRequestPrefillTag=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SignRequestPrefillTag"'});if(null!=e.document_tag_id&&!(0,a.sdIsString)(e.document_tag_id))throw new o.BoxSdkError({message:'Expecting string for "document_tag_id" of type "SignRequestPrefillTag"'});const t=null==e.document_tag_id?void 0:e.document_tag_id;if(null!=e.text_value&&!(0,a.sdIsString)(e.text_value))throw new o.BoxSdkError({message:'Expecting string for "text_value" of type "SignRequestPrefillTag"'});const r=null==e.text_value?void 0:e.text_value;if(null!=e.checkbox_value&&!(0,s.sdIsBoolean)(e.checkbox_value))throw new o.BoxSdkError({message:'Expecting boolean for "checkbox_value" of type "SignRequestPrefillTag"'});const i=null==e.checkbox_value?void 0:e.checkbox_value;if(null!=e.date_value&&!(0,a.sdIsString)(e.date_value))throw new o.BoxSdkError({message:'Expecting string for "date_value" of type "SignRequestPrefillTag"'});const d=null==e.date_value?void 0:(0,n.deserializeDate)(e.date_value);return{documentTagId:t,textValue:r,checkboxValue:i,dateValue:d}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},47636:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestSignerSignerDecisionTypeField=m,t.deserializeSignRequestSignerSignerDecisionTypeField=g,t.serializeSignRequestSignerSignerDecisionField=y,t.deserializeSignRequestSignerSignerDecisionField=v,t.serializeSignRequestSigner=function(e){const t=(0,n.serializeSignRequestCreateSigner)(e);if(!(0,f.sdIsMap)(t))throw new d.BoxSdkError({message:'Expecting a map for "SignRequestSigner"'});return Object.assign(Object.assign({},t),{has_viewed_document:null==e.hasViewedDocument?void 0:e.hasViewedDocument,signer_decision:null==e.signerDecision?void 0:y(e.signerDecision),inputs:null==e.inputs?void 0:e.inputs.map((function(e){return(0,o.serializeSignRequestSignerInput)(e)})),embed_url:null==e.embedUrl?void 0:e.embedUrl,iframeable_embed_url:null==e.iframeableEmbedUrl?void 0:e.iframeableEmbedUrl})},t.deserializeSignRequestSigner=function(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignRequestSigner"'});if(null!=e.has_viewed_document&&!(0,c.sdIsBoolean)(e.has_viewed_document))throw new d.BoxSdkError({message:'Expecting boolean for "has_viewed_document" of type "SignRequestSigner"'});const t=null==e.has_viewed_document?void 0:e.has_viewed_document,r=null==e.signer_decision?void 0:v(e.signer_decision);if(null!=e.inputs&&!(0,h.sdIsList)(e.inputs))throw new d.BoxSdkError({message:'Expecting array for "inputs" of type "SignRequestSigner"'});const n=null==e.inputs?void 0:(0,h.sdIsList)(e.inputs)?e.inputs.map((function(e){return(0,s.deserializeSignRequestSignerInput)(e)})):[];if(null!=e.embed_url&&!(0,p.sdIsString)(e.embed_url))throw new d.BoxSdkError({message:'Expecting string for "embed_url" of type "SignRequestSigner"'});const o=null==e.embed_url?void 0:e.embed_url;if(null!=e.iframeable_embed_url&&!(0,p.sdIsString)(e.iframeable_embed_url))throw new d.BoxSdkError({message:'Expecting string for "iframeable_embed_url" of type "SignRequestSigner"'});const a=null==e.iframeable_embed_url?void 0:e.iframeable_embed_url;if(null!=e.email&&!(0,p.sdIsString)(e.email))throw new d.BoxSdkError({message:'Expecting string for "email" of type "SignRequestSigner"'});const l=null==e.email?void 0:e.email,m=null==e.role?void 0:(0,i.deserializeSignRequestCreateSignerRoleField)(e.role);if(null!=e.is_in_person&&!(0,c.sdIsBoolean)(e.is_in_person))throw new d.BoxSdkError({message:'Expecting boolean for "is_in_person" of type "SignRequestSigner"'});const g=null==e.is_in_person?void 0:e.is_in_person;if(null!=e.order&&!(0,u.sdIsNumber)(e.order))throw new d.BoxSdkError({message:'Expecting number for "order" of type "SignRequestSigner"'});const y=null==e.order?void 0:e.order;if(null!=e.embed_url_external_user_id&&!(0,p.sdIsString)(e.embed_url_external_user_id))throw new d.BoxSdkError({message:'Expecting string for "embed_url_external_user_id" of type "SignRequestSigner"'});const b=null==e.embed_url_external_user_id?void 0:e.embed_url_external_user_id;if(null!=e.redirect_url&&!(0,p.sdIsString)(e.redirect_url))throw new d.BoxSdkError({message:'Expecting string for "redirect_url" of type "SignRequestSigner"'});const w=null==e.redirect_url?void 0:e.redirect_url;if(null!=e.declined_redirect_url&&!(0,p.sdIsString)(e.declined_redirect_url))throw new d.BoxSdkError({message:'Expecting string for "declined_redirect_url" of type "SignRequestSigner"'});const _=null==e.declined_redirect_url?void 0:e.declined_redirect_url;if(null!=e.login_required&&!(0,c.sdIsBoolean)(e.login_required))throw new d.BoxSdkError({message:'Expecting boolean for "login_required" of type "SignRequestSigner"'});const x=null==e.login_required?void 0:e.login_required;if(null!=e.verification_phone_number&&!(0,p.sdIsString)(e.verification_phone_number))throw new d.BoxSdkError({message:'Expecting string for "verification_phone_number" of type "SignRequestSigner"'});const S=null==e.verification_phone_number?void 0:e.verification_phone_number;if(null!=e.password&&!(0,p.sdIsString)(e.password))throw new d.BoxSdkError({message:'Expecting string for "password" of type "SignRequestSigner"'});const k=null==e.password?void 0:e.password;if(null!=e.signer_group_id&&!(0,p.sdIsString)(e.signer_group_id))throw new d.BoxSdkError({message:'Expecting string for "signer_group_id" of type "SignRequestSigner"'});const E=null==e.signer_group_id?void 0:e.signer_group_id;if(null!=e.suppress_notifications&&!(0,c.sdIsBoolean)(e.suppress_notifications))throw new d.BoxSdkError({message:'Expecting boolean for "suppress_notifications" of type "SignRequestSigner"'});const T=null==e.suppress_notifications?void 0:e.suppress_notifications;return{hasViewedDocument:t,signerDecision:r,inputs:n,embedUrl:o,iframeableEmbedUrl:a,email:l,role:m,isInPerson:g,order:y,embedUrlExternalUserId:b,redirectUrl:w,declinedRedirectUrl:_,loginRequired:x,verificationPhoneNumber:S,password:k,signerGroupId:E,suppressNotifications:T}};const i=r(15248),n=r(15248),o=r(6992),s=r(6992),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793),f=r(50793);function m(e){return e}function g(e){if("signed"==e)return e;if("declined"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize SignRequestSignerSignerDecisionTypeField"})}function y(e){return{type:null==e.type?void 0:e.type,finalized_at:null==e.finalizedAt?void 0:(0,a.serializeDateTime)(e.finalizedAt),additional_info:null==e.additionalInfo?void 0:e.additionalInfo}}function v(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignRequestSignerSignerDecisionField"'});const t=null==e.type?void 0:g(e.type);if(null!=e.finalized_at&&!(0,p.sdIsString)(e.finalized_at))throw new d.BoxSdkError({message:'Expecting string for "finalized_at" of type "SignRequestSignerSignerDecisionField"'});const r=null==e.finalized_at?void 0:(0,l.deserializeDateTime)(e.finalized_at);if(null!=e.additional_info&&!(0,p.sdIsString)(e.additional_info))throw new d.BoxSdkError({message:'Expecting string for "additional_info" of type "SignRequestSignerSignerDecisionField"'});return{type:t,finalizedAt:r,additionalInfo:null==e.additional_info?void 0:e.additional_info}}},6992:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequestSignerInputTypeField=c,t.deserializeSignRequestSignerInputTypeField=u,t.serializeSignRequestSignerInputContentTypeField=p,t.deserializeSignRequestSignerInputContentTypeField=h,t.serializeSignRequestSignerInput=function(e){const t=(0,n.serializeSignRequestPrefillTag)(e);if(!(0,d.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "SignRequestSignerInput"'});return Object.assign(Object.assign({},t),{type:null==e.type?void 0:e.type,content_type:null==e.contentType?void 0:e.contentType,page_index:e.pageIndex,read_only:null==e.readOnly?void 0:e.readOnly})},t.deserializeSignRequestSignerInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SignRequestSignerInput"'});const t=null==e.type?void 0:u(e.type),r=null==e.content_type?void 0:h(e.content_type);if(null==e.page_index)throw new o.BoxSdkError({message:'Expecting "page_index" of type "SignRequestSignerInput" to be defined'});if(!(0,a.sdIsNumber)(e.page_index))throw new o.BoxSdkError({message:'Expecting number for "page_index" of type "SignRequestSignerInput"'});const n=e.page_index;if(null!=e.read_only&&!(0,s.sdIsBoolean)(e.read_only))throw new o.BoxSdkError({message:'Expecting boolean for "read_only" of type "SignRequestSignerInput"'});const c=null==e.read_only?void 0:e.read_only;if(null!=e.document_tag_id&&!(0,l.sdIsString)(e.document_tag_id))throw new o.BoxSdkError({message:'Expecting string for "document_tag_id" of type "SignRequestSignerInput"'});const p=null==e.document_tag_id?void 0:e.document_tag_id;if(null!=e.text_value&&!(0,l.sdIsString)(e.text_value))throw new o.BoxSdkError({message:'Expecting string for "text_value" of type "SignRequestSignerInput"'});const f=null==e.text_value?void 0:e.text_value;if(null!=e.checkbox_value&&!(0,s.sdIsBoolean)(e.checkbox_value))throw new o.BoxSdkError({message:'Expecting boolean for "checkbox_value" of type "SignRequestSignerInput"'});const m=null==e.checkbox_value?void 0:e.checkbox_value;if(null!=e.date_value&&!(0,l.sdIsString)(e.date_value))throw new o.BoxSdkError({message:'Expecting string for "date_value" of type "SignRequestSignerInput"'});const g=null==e.date_value?void 0:(0,i.deserializeDate)(e.date_value);return{type:t,contentType:r,pageIndex:n,readOnly:c,documentTagId:p,textValue:f,checkboxValue:m,dateValue:g}};const i=r(93845),n=r(3798),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("signature"==e)return e;if("date"==e)return e;if("text"==e)return e;if("checkbox"==e)return e;if("radio"==e)return e;if("dropdown"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize SignRequestSignerInputTypeField"})}function p(e){return e}function h(e){if("signature"==e)return e;if("initial"==e)return e;if("stamp"==e)return e;if("date"==e)return e;if("checkbox"==e)return e;if("text"==e)return e;if("full_name"==e)return e;if("first_name"==e)return e;if("last_name"==e)return e;if("company"==e)return e;if("title"==e)return e;if("email"==e)return e;if("attachment"==e)return e;if("radio"==e)return e;if("dropdown"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize SignRequestSignerInputContentTypeField"})}},58267:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignRequests=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeSignRequest)(e)}))}},t.deserializeSignRequests=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SignRequests"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SignRequests"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "SignRequests"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SignRequests"'});const i=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeSignRequest)(e)})):[];return{limit:t,nextMarker:r,entries:i}};const i=r(86982),n=r(86982),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},15139:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignTemplateTypeField=m,t.deserializeSignTemplateTypeField=g,t.serializeSignTemplateAdditionalInfoNonEditableField=y,t.deserializeSignTemplateAdditionalInfoNonEditableField=v,t.serializeSignTemplateAdditionalInfoRequiredSignersField=b,t.deserializeSignTemplateAdditionalInfoRequiredSignersField=w,t.serializeSignTemplateAdditionalInfoRequiredField=_,t.deserializeSignTemplateAdditionalInfoRequiredField=x,t.serializeSignTemplateAdditionalInfoField=S,t.deserializeSignTemplateAdditionalInfoField=k,t.serializeSignTemplateReadySignLinkField=E,t.deserializeSignTemplateReadySignLinkField=T,t.serializeSignTemplateCustomBrandingField=B,t.deserializeSignTemplateCustomBrandingField=C,t.serializeSignTemplate=function(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,name:null==e.name?void 0:e.name,email_subject:null==e.emailSubject?void 0:e.emailSubject,email_message:null==e.emailMessage?void 0:e.emailMessage,days_valid:null==e.daysValid?void 0:e.daysValid,parent_folder:null==e.parentFolder?void 0:(0,i.serializeFolderMini)(e.parentFolder),source_files:null==e.sourceFiles?void 0:e.sourceFiles.map((function(e){return(0,o.serializeFileMini)(e)})),are_fields_locked:null==e.areFieldsLocked?void 0:e.areFieldsLocked,are_options_locked:null==e.areOptionsLocked?void 0:e.areOptionsLocked,are_recipients_locked:null==e.areRecipientsLocked?void 0:e.areRecipientsLocked,are_email_settings_locked:null==e.areEmailSettingsLocked?void 0:e.areEmailSettingsLocked,are_files_locked:null==e.areFilesLocked?void 0:e.areFilesLocked,signers:null==e.signers?void 0:e.signers.map((function(e){return(0,a.serializeTemplateSigner)(e)})),additional_info:null==e.additionalInfo?void 0:S(e.additionalInfo),ready_sign_link:null==e.readySignLink?void 0:E(e.readySignLink),custom_branding:null==e.customBranding?void 0:B(e.customBranding)}},t.deserializeSignTemplate=function(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignTemplate"'});const t=null==e.type?void 0:g(e.type);if(null!=e.id&&!(0,p.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "SignTemplate"'});const r=null==e.id?void 0:e.id;if(null!=e.name&&!(0,p.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "SignTemplate"'});const i=null==e.name?void 0:e.name;if(null!=e.email_subject&&!(0,p.sdIsString)(e.email_subject))throw new d.BoxSdkError({message:'Expecting string for "email_subject" of type "SignTemplate"'});const o=null==e.email_subject?void 0:e.email_subject;if(null!=e.email_message&&!(0,p.sdIsString)(e.email_message))throw new d.BoxSdkError({message:'Expecting string for "email_message" of type "SignTemplate"'});const a=null==e.email_message?void 0:e.email_message;if(null!=e.days_valid&&!(0,u.sdIsNumber)(e.days_valid))throw new d.BoxSdkError({message:'Expecting number for "days_valid" of type "SignTemplate"'});const m=null==e.days_valid?void 0:e.days_valid,y=null==e.parent_folder?void 0:(0,n.deserializeFolderMini)(e.parent_folder);if(null!=e.source_files&&!(0,h.sdIsList)(e.source_files))throw new d.BoxSdkError({message:'Expecting array for "source_files" of type "SignTemplate"'});const v=null==e.source_files?void 0:(0,h.sdIsList)(e.source_files)?e.source_files.map((function(e){return(0,s.deserializeFileMini)(e)})):[];if(null!=e.are_fields_locked&&!(0,c.sdIsBoolean)(e.are_fields_locked))throw new d.BoxSdkError({message:'Expecting boolean for "are_fields_locked" of type "SignTemplate"'});const b=null==e.are_fields_locked?void 0:e.are_fields_locked;if(null!=e.are_options_locked&&!(0,c.sdIsBoolean)(e.are_options_locked))throw new d.BoxSdkError({message:'Expecting boolean for "are_options_locked" of type "SignTemplate"'});const w=null==e.are_options_locked?void 0:e.are_options_locked;if(null!=e.are_recipients_locked&&!(0,c.sdIsBoolean)(e.are_recipients_locked))throw new d.BoxSdkError({message:'Expecting boolean for "are_recipients_locked" of type "SignTemplate"'});const _=null==e.are_recipients_locked?void 0:e.are_recipients_locked;if(null!=e.are_email_settings_locked&&!(0,c.sdIsBoolean)(e.are_email_settings_locked))throw new d.BoxSdkError({message:'Expecting boolean for "are_email_settings_locked" of type "SignTemplate"'});const x=null==e.are_email_settings_locked?void 0:e.are_email_settings_locked;if(null!=e.are_files_locked&&!(0,c.sdIsBoolean)(e.are_files_locked))throw new d.BoxSdkError({message:'Expecting boolean for "are_files_locked" of type "SignTemplate"'});const S=null==e.are_files_locked?void 0:e.are_files_locked;if(null!=e.signers&&!(0,h.sdIsList)(e.signers))throw new d.BoxSdkError({message:'Expecting array for "signers" of type "SignTemplate"'});const E=null==e.signers?void 0:(0,h.sdIsList)(e.signers)?e.signers.map((function(e){return(0,l.deserializeTemplateSigner)(e)})):[],B=null==e.additional_info?void 0:k(e.additional_info),I=null==e.ready_sign_link?void 0:T(e.ready_sign_link),A=null==e.custom_branding?void 0:C(e.custom_branding);return{type:t,id:r,name:i,emailSubject:o,emailMessage:a,daysValid:m,parentFolder:y,sourceFiles:v,areFieldsLocked:b,areOptionsLocked:w,areRecipientsLocked:_,areEmailSettingsLocked:x,areFilesLocked:S,signers:E,additionalInfo:B,readySignLink:I,customBranding:A}};const i=r(70343),n=r(70343),o=r(62929),s=r(62929),a=r(15048),l=r(15048),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793),f=r(50793);function m(e){return e}function g(e){if("sign-template"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize SignTemplateTypeField"})}function y(e){return e}function v(e){if("email_subject"==e)return e;if("email_message"==e)return e;if("name"==e)return e;if("days_valid"==e)return e;if("signers"==e)return e;if("source_files"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize SignTemplateAdditionalInfoNonEditableField"})}function b(e){return e}function w(e){if("email"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize SignTemplateAdditionalInfoRequiredSignersField"})}function _(e){return{signers:null==e.signers?void 0:e.signers.map((function(e){return e.map((function(e){return e}))}))}}function x(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignTemplateAdditionalInfoRequiredField"'});if(null!=e.signers&&!(0,h.sdIsList)(e.signers))throw new d.BoxSdkError({message:'Expecting array for "signers" of type "SignTemplateAdditionalInfoRequiredField"'});return{signers:null==e.signers?void 0:(0,h.sdIsList)(e.signers)?e.signers.map((function(e){return(0,h.sdIsList)(e)?e.map((function(e){return w(e)})):[]})):[]}}function S(e){return{non_editable:null==e.nonEditable?void 0:e.nonEditable.map((function(e){return e})),required:null==e.required?void 0:_(e.required)}}function k(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignTemplateAdditionalInfoField"'});if(null!=e.non_editable&&!(0,h.sdIsList)(e.non_editable))throw new d.BoxSdkError({message:'Expecting array for "non_editable" of type "SignTemplateAdditionalInfoField"'});return{nonEditable:null==e.non_editable?void 0:(0,h.sdIsList)(e.non_editable)?e.non_editable.map((function(e){return v(e)})):[],required:null==e.required?void 0:x(e.required)}}function E(e){return{url:null==e.url?void 0:e.url,name:null==e.name?void 0:e.name,instructions:null==e.instructions?void 0:e.instructions,folder_id:null==e.folderId?void 0:e.folderId,is_notification_disabled:null==e.isNotificationDisabled?void 0:e.isNotificationDisabled,is_active:null==e.isActive?void 0:e.isActive}}function T(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignTemplateReadySignLinkField"'});if(null!=e.url&&!(0,p.sdIsString)(e.url))throw new d.BoxSdkError({message:'Expecting string for "url" of type "SignTemplateReadySignLinkField"'});const t=null==e.url?void 0:e.url;if(null!=e.name&&!(0,p.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "SignTemplateReadySignLinkField"'});const r=null==e.name?void 0:e.name;if(null!=e.instructions&&!(0,p.sdIsString)(e.instructions))throw new d.BoxSdkError({message:'Expecting string for "instructions" of type "SignTemplateReadySignLinkField"'});const i=null==e.instructions?void 0:e.instructions;if(null!=e.folder_id&&!(0,p.sdIsString)(e.folder_id))throw new d.BoxSdkError({message:'Expecting string for "folder_id" of type "SignTemplateReadySignLinkField"'});const n=null==e.folder_id?void 0:e.folder_id;if(null!=e.is_notification_disabled&&!(0,c.sdIsBoolean)(e.is_notification_disabled))throw new d.BoxSdkError({message:'Expecting boolean for "is_notification_disabled" of type "SignTemplateReadySignLinkField"'});const o=null==e.is_notification_disabled?void 0:e.is_notification_disabled;if(null!=e.is_active&&!(0,c.sdIsBoolean)(e.is_active))throw new d.BoxSdkError({message:'Expecting boolean for "is_active" of type "SignTemplateReadySignLinkField"'});return{url:t,name:r,instructions:i,folderId:n,isNotificationDisabled:o,isActive:null==e.is_active?void 0:e.is_active}}function B(e){return{company_name:null==e.companyName?void 0:e.companyName,logo_uri:null==e.logoUri?void 0:e.logoUri,branding_color:null==e.brandingColor?void 0:e.brandingColor,email_footer_text:null==e.emailFooterText?void 0:e.emailFooterText}}function C(e){if(!(0,f.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "SignTemplateCustomBrandingField"'});if(null!=e.company_name&&!(0,p.sdIsString)(e.company_name))throw new d.BoxSdkError({message:'Expecting string for "company_name" of type "SignTemplateCustomBrandingField"'});const t=null==e.company_name?void 0:e.company_name;if(null!=e.logo_uri&&!(0,p.sdIsString)(e.logo_uri))throw new d.BoxSdkError({message:'Expecting string for "logo_uri" of type "SignTemplateCustomBrandingField"'});const r=null==e.logo_uri?void 0:e.logo_uri;if(null!=e.branding_color&&!(0,p.sdIsString)(e.branding_color))throw new d.BoxSdkError({message:'Expecting string for "branding_color" of type "SignTemplateCustomBrandingField"'});const i=null==e.branding_color?void 0:e.branding_color;if(null!=e.email_footer_text&&!(0,p.sdIsString)(e.email_footer_text))throw new d.BoxSdkError({message:'Expecting string for "email_footer_text" of type "SignTemplateCustomBrandingField"'});return{companyName:t,logoUri:r,brandingColor:i,emailFooterText:null==e.email_footer_text?void 0:e.email_footer_text}}},55064:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSignTemplates=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeSignTemplate)(e)}))}},t.deserializeSignTemplates=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SignTemplates"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "SignTemplates"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "SignTemplates"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "SignTemplates"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "SignTemplates"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeSignTemplate)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(15139),n=r(15139),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},75897:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeSkillCardsMetadata=function(e){return{$canEdit:null==e.canEdit?void 0:e.canEdit,$id:null==e.id?void 0:e.id,$parent:null==e.parent?void 0:e.parent,$scope:null==e.scope?void 0:e.scope,$template:null==e.template?void 0:e.template,$type:null==e.type?void 0:e.type,$typeVersion:null==e.typeVersion?void 0:e.typeVersion,$version:null==e.version?void 0:e.version,cards:null==e.cards?void 0:e.cards.map((function(e){return(0,i.serializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)}))}},t.deserializeSkillCardsMetadata=function(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "SkillCardsMetadata"'});if(null!=e.$canEdit&&!(0,s.sdIsBoolean)(e.$canEdit))throw new o.BoxSdkError({message:'Expecting boolean for "$canEdit" of type "SkillCardsMetadata"'});const t=null==e.$canEdit?void 0:e.$canEdit;if(null!=e.$id&&!(0,l.sdIsString)(e.$id))throw new o.BoxSdkError({message:'Expecting string for "$id" of type "SkillCardsMetadata"'});const r=null==e.$id?void 0:e.$id;if(null!=e.$parent&&!(0,l.sdIsString)(e.$parent))throw new o.BoxSdkError({message:'Expecting string for "$parent" of type "SkillCardsMetadata"'});const i=null==e.$parent?void 0:e.$parent;if(null!=e.$scope&&!(0,l.sdIsString)(e.$scope))throw new o.BoxSdkError({message:'Expecting string for "$scope" of type "SkillCardsMetadata"'});const u=null==e.$scope?void 0:e.$scope;if(null!=e.$template&&!(0,l.sdIsString)(e.$template))throw new o.BoxSdkError({message:'Expecting string for "$template" of type "SkillCardsMetadata"'});const p=null==e.$template?void 0:e.$template;if(null!=e.$type&&!(0,l.sdIsString)(e.$type))throw new o.BoxSdkError({message:'Expecting string for "$type" of type "SkillCardsMetadata"'});const h=null==e.$type?void 0:e.$type;if(null!=e.$typeVersion&&!(0,a.sdIsNumber)(e.$typeVersion))throw new o.BoxSdkError({message:'Expecting number for "$typeVersion" of type "SkillCardsMetadata"'});const f=null==e.$typeVersion?void 0:e.$typeVersion;if(null!=e.$version&&!(0,a.sdIsNumber)(e.$version))throw new o.BoxSdkError({message:'Expecting number for "$version" of type "SkillCardsMetadata"'});const m=null==e.$version?void 0:e.$version;if(null!=e.cards&&!(0,d.sdIsList)(e.cards))throw new o.BoxSdkError({message:'Expecting array for "cards" of type "SkillCardsMetadata"'});const g=null==e.cards?void 0:(0,d.sdIsList)(e.cards)?e.cards.map((function(e){return(0,n.deserializeKeywordSkillCardOrStatusSkillCardOrTimelineSkillCardOrTranscriptSkillCard)(e)})):[];return{canEdit:t,id:r,parent:i,scope:u,template:p,type:h,typeVersion:f,version:m,cards:g}};const i=r(20633),n=r(20633),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793),c=r(50793)},77421:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StatusSkillCard=t.StatusSkillCardInvocationField=t.StatusSkillCardSkillField=void 0,t.serializeStatusSkillCardTypeField=l,t.deserializeStatusSkillCardTypeField=d,t.serializeStatusSkillCardSkillCardTypeField=c,t.deserializeStatusSkillCardSkillCardTypeField=u,t.serializeStatusSkillCardSkillCardTitleField=p,t.deserializeStatusSkillCardSkillCardTitleField=h,t.serializeStatusSkillCardStatusCodeField=f,t.deserializeStatusSkillCardStatusCodeField=m,t.serializeStatusSkillCardStatusField=g,t.deserializeStatusSkillCardStatusField=y,t.serializeStatusSkillCardSkillTypeField=v,t.deserializeStatusSkillCardSkillTypeField=b,t.serializeStatusSkillCardSkillField=w,t.deserializeStatusSkillCardSkillField=_,t.serializeStatusSkillCardSkillFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeStatusSkillCardSkillFieldInput=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardSkillFieldInput"'});const t=null==e.type?void 0:b(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StatusSkillCardSkillFieldInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StatusSkillCardSkillFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeStatusSkillCardInvocationTypeField=x,t.deserializeStatusSkillCardInvocationTypeField=S,t.serializeStatusSkillCardInvocationField=k,t.deserializeStatusSkillCardInvocationField=E,t.serializeStatusSkillCardInvocationFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeStatusSkillCardInvocationFieldInput=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardInvocationFieldInput"'});const t=null==e.type?void 0:S(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StatusSkillCardInvocationFieldInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StatusSkillCardInvocationFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeStatusSkillCard=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:e.type,skill_card_type:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:p(e.skillCardTitle),status:g(e.status),skill:w(e.skill),invocation:k(e.invocation)}},t.deserializeStatusSkillCard=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCard"'});if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "StatusSkillCard"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "StatusSkillCard" to be defined'});const r=d(e.type);if(null==e.skill_card_type)throw new o.BoxSdkError({message:'Expecting "skill_card_type" of type "StatusSkillCard" to be defined'});const i=u(e.skill_card_type),l=null==e.skill_card_title?void 0:h(e.skill_card_title);if(null==e.status)throw new o.BoxSdkError({message:'Expecting "status" of type "StatusSkillCard" to be defined'});const c=y(e.status);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "StatusSkillCard" to be defined'});const p=_(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "StatusSkillCard" to be defined'});const f=E(e.invocation);return{createdAt:t,type:r,skillCardType:i,skillCardTitle:l,status:c,skill:p,invocation:f}},t.serializeStatusSkillCardInput=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:null==e.type?void 0:e.type,skillCardType:null==e.skillCardType?void 0:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:p(e.skillCardTitle),status:g(e.status),skill:w(e.skill),invocation:k(e.invocation)}},t.deserializeStatusSkillCardInput=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardInput"'});if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "StatusSkillCardInput"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at),r=null==e.type?void 0:d(e.type),i=null==e.skillCardType?void 0:u(e.skillCardType),l=null==e.skill_card_title?void 0:h(e.skill_card_title);if(null==e.status)throw new o.BoxSdkError({message:'Expecting "status" of type "StatusSkillCardInput" to be defined'});const c=y(e.status);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "StatusSkillCardInput" to be defined'});const p=_(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "StatusSkillCardInput" to be defined'});const f=E(e.invocation);return{createdAt:t,type:r,skillCardType:i,skillCardTitle:l,status:c,skill:p,invocation:f}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793);t.StatusSkillCardSkillField=class{constructor(e){this.type="service",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};t.StatusSkillCardInvocationField=class{constructor(e){this.type="skill_invocation",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};function l(e){return e}function d(e){if("skill_card"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StatusSkillCardTypeField"})}function c(e){return e}function u(e){if("status"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StatusSkillCardSkillCardTypeField"})}function p(e){return{code:null==e.code?void 0:e.code,message:e.message}}function h(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardSkillCardTitleField"'});if(null!=e.code&&!(0,s.sdIsString)(e.code))throw new o.BoxSdkError({message:'Expecting string for "code" of type "StatusSkillCardSkillCardTitleField"'});const t=null==e.code?void 0:e.code;if(null==e.message)throw new o.BoxSdkError({message:'Expecting "message" of type "StatusSkillCardSkillCardTitleField" to be defined'});if(!(0,s.sdIsString)(e.message))throw new o.BoxSdkError({message:'Expecting string for "message" of type "StatusSkillCardSkillCardTitleField"'});return{code:t,message:e.message}}function f(e){return e}function m(e){if("invoked"==e)return e;if("processing"==e)return e;if("success"==e)return e;if("transient_failure"==e)return e;if("permanent_failure"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StatusSkillCardStatusCodeField"})}function g(e){return{code:e.code,message:null==e.message?void 0:e.message}}function y(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardStatusField"'});if(null==e.code)throw new o.BoxSdkError({message:'Expecting "code" of type "StatusSkillCardStatusField" to be defined'});const t=m(e.code);if(null!=e.message&&!(0,s.sdIsString)(e.message))throw new o.BoxSdkError({message:'Expecting string for "message" of type "StatusSkillCardStatusField"'});return{code:t,message:null==e.message?void 0:e.message}}function v(e){return e}function b(e){if("service"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StatusSkillCardSkillTypeField"})}function w(e){return{type:e.type,id:e.id}}function _(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardSkillField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "StatusSkillCardSkillField" to be defined'});const t=b(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StatusSkillCardSkillField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StatusSkillCardSkillField"'});return{type:t,id:e.id}}function x(e){return e}function S(e){if("skill_invocation"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StatusSkillCardInvocationTypeField"})}function k(e){return{type:e.type,id:e.id}}function E(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StatusSkillCardInvocationField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "StatusSkillCardInvocationField" to be defined'});const t=S(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StatusSkillCardInvocationField" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StatusSkillCardInvocationField"'});return{type:t,id:e.id}}t.StatusSkillCard=class{constructor(e){this.type="skill_card",this.skillCardType="status",e.createdAt&&(this.createdAt=e.createdAt),e.type&&(this.type=e.type),e.skillCardType&&(this.skillCardType=e.skillCardType),e.skillCardTitle&&(this.skillCardTitle=e.skillCardTitle),e.status&&(this.status=e.status),e.skill&&(this.skill=e.skill),e.invocation&&(this.invocation=e.invocation),e.rawData&&(this.rawData=e.rawData)}}},95199:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeStoragePolicies=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeStoragePolicy)(e)}))}},t.deserializeStoragePolicies=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StoragePolicies"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "StoragePolicies"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "StoragePolicies"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "StoragePolicies"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "StoragePolicies"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeStoragePolicy)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(32735),n=r(32735),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},32735:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StoragePolicy=void 0,t.serializeStoragePolicy=function(e){const t=(0,n.serializeStoragePolicyMini)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "StoragePolicy"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name})},t.deserializeStoragePolicy=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "StoragePolicy"'});if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "StoragePolicy"'});const t=null==e.name?void 0:e.name;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "StoragePolicy" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicy"'});const r=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "StoragePolicy" to be defined'});const n=(0,i.deserializeStoragePolicyMiniTypeField)(e.type);return{name:t,id:r,type:n}};const i=r(42600),n=r(42600),o=r(42600),s=r(72631),a=r(50793),l=r(50793);class d extends o.StoragePolicyMini{constructor(e){super(e)}}t.StoragePolicy=d},66778:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StoragePolicyAssignment=void 0,t.serializeStoragePolicyAssignmentTypeField=l,t.deserializeStoragePolicyAssignmentTypeField=d,t.serializeStoragePolicyAssignmentAssignedToField=c,t.deserializeStoragePolicyAssignmentAssignedToField=u,t.serializeStoragePolicyAssignment=function(e){return{id:e.id,type:e.type,storage_policy:null==e.storagePolicy?void 0:(0,i.serializeStoragePolicyMini)(e.storagePolicy),assigned_to:null==e.assignedTo?void 0:c(e.assignedTo)}},t.deserializeStoragePolicyAssignment=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StoragePolicyAssignment"'});if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StoragePolicyAssignment" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicyAssignment"'});const t=e.id;if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "StoragePolicyAssignment" to be defined'});const r=d(e.type),i=null==e.storage_policy?void 0:(0,n.deserializeStoragePolicyMini)(e.storage_policy),l=null==e.assigned_to?void 0:u(e.assigned_to);return{id:t,type:r,storagePolicy:i,assignedTo:l}},t.serializeStoragePolicyAssignmentInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,storage_policy:null==e.storagePolicy?void 0:(0,i.serializeStoragePolicyMini)(e.storagePolicy),assigned_to:null==e.assignedTo?void 0:c(e.assignedTo)}},t.deserializeStoragePolicyAssignmentInput=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StoragePolicyAssignmentInput"'});if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "StoragePolicyAssignmentInput" to be defined'});if(!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicyAssignmentInput"'});const t=e.id,r=null==e.type?void 0:d(e.type),i=null==e.storage_policy?void 0:(0,n.deserializeStoragePolicyMini)(e.storage_policy),l=null==e.assigned_to?void 0:u(e.assigned_to);return{id:t,type:r,storagePolicy:i,assignedTo:l}};const i=r(42600),n=r(42600),o=r(72631),s=r(50793),a=r(50793);function l(e){return e}function d(e){if("storage_policy_assignment"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize StoragePolicyAssignmentTypeField"})}function c(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function u(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StoragePolicyAssignmentAssignedToField"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicyAssignmentAssignedToField"'});const t=null==e.id?void 0:e.id;if(null!=e.type&&!(0,s.sdIsString)(e.type))throw new o.BoxSdkError({message:'Expecting string for "type" of type "StoragePolicyAssignmentAssignedToField"'});return{id:t,type:null==e.type?void 0:e.type}}t.StoragePolicyAssignment=class{constructor(e){this.type="storage_policy_assignment",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.storagePolicy&&(this.storagePolicy=e.storagePolicy),e.assignedTo&&(this.assignedTo=e.assignedTo),e.rawData&&(this.rawData=e.rawData)}}},87335:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeStoragePolicyAssignments=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeStoragePolicyAssignment)(e)}))}},t.deserializeStoragePolicyAssignments=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "StoragePolicyAssignments"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "StoragePolicyAssignments"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "StoragePolicyAssignments"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "StoragePolicyAssignments"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "StoragePolicyAssignments"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeStoragePolicyAssignment)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(66778),n=r(66778),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},42600:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StoragePolicyMini=void 0,t.serializeStoragePolicyMiniTypeField=s,t.deserializeStoragePolicyMiniTypeField=a,t.serializeStoragePolicyMini=function(e){return{id:e.id,type:e.type}},t.deserializeStoragePolicyMini=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "StoragePolicyMini"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "StoragePolicyMini" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicyMini"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "StoragePolicyMini" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeStoragePolicyMiniInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeStoragePolicyMiniInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "StoragePolicyMiniInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "StoragePolicyMiniInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "StoragePolicyMiniInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("storage_policy"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize StoragePolicyMiniTypeField"})}t.StoragePolicyMini=class{constructor(e){this.type="storage_policy",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},62125:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTaskTypeField=m,t.deserializeTaskTypeField=g,t.serializeTaskActionField=y,t.deserializeTaskActionField=v,t.serializeTaskCompletionRuleField=b,t.deserializeTaskCompletionRuleField=w,t.serializeTask=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,item:null==e.item?void 0:(0,i.serializeFileMini)(e.item),due_at:null==e.dueAt?void 0:(0,d.serializeDateTime)(e.dueAt),action:null==e.action?void 0:e.action,message:null==e.message?void 0:e.message,task_assignment_collection:null==e.taskAssignmentCollection?void 0:(0,o.serializeTaskAssignments)(e.taskAssignmentCollection),is_completed:null==e.isCompleted?void 0:e.isCompleted,created_by:null==e.createdBy?void 0:(0,a.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,d.serializeDateTime)(e.createdAt),completion_rule:null==e.completionRule?void 0:e.completionRule}},t.deserializeTask=function(e){if(!(0,f.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "Task"'});if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "Task"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:g(e.type),i=null==e.item?void 0:(0,n.deserializeFileMini)(e.item);if(null!=e.due_at&&!(0,h.sdIsString)(e.due_at))throw new u.BoxSdkError({message:'Expecting string for "due_at" of type "Task"'});const o=null==e.due_at?void 0:(0,c.deserializeDateTime)(e.due_at),a=null==e.action?void 0:v(e.action);if(null!=e.message&&!(0,h.sdIsString)(e.message))throw new u.BoxSdkError({message:'Expecting string for "message" of type "Task"'});const d=null==e.message?void 0:e.message,m=null==e.task_assignment_collection?void 0:(0,s.deserializeTaskAssignments)(e.task_assignment_collection);if(null!=e.is_completed&&!(0,p.sdIsBoolean)(e.is_completed))throw new u.BoxSdkError({message:'Expecting boolean for "is_completed" of type "Task"'});const y=null==e.is_completed?void 0:e.is_completed,b=null==e.created_by?void 0:(0,l.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,h.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "Task"'});const _=null==e.created_at?void 0:(0,c.deserializeDateTime)(e.created_at),x=null==e.completion_rule?void 0:w(e.completion_rule);return{id:t,type:r,item:i,dueAt:o,action:a,message:d,taskAssignmentCollection:m,isCompleted:y,createdBy:b,createdAt:_,completionRule:x}};const i=r(62929),n=r(62929),o=r(85065),s=r(85065),a=r(95408),l=r(95408),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793),f=r(50793);function m(e){return e}function g(e){if("task"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TaskTypeField"})}function y(e){return e}function v(e){if("review"==e)return e;if("complete"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TaskActionField"})}function b(e){return e}function w(e){if("all_assignees"==e)return e;if("any_assignee"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TaskCompletionRuleField"})}},6884:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTaskAssignmentTypeField=p,t.deserializeTaskAssignmentTypeField=h,t.serializeTaskAssignmentResolutionStateField=f,t.deserializeTaskAssignmentResolutionStateField=m,t.serializeTaskAssignment=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,item:null==e.item?void 0:(0,i.serializeFileMini)(e.item),assigned_to:null==e.assignedTo?void 0:(0,o.serializeUserMini)(e.assignedTo),message:null==e.message?void 0:e.message,completed_at:null==e.completedAt?void 0:(0,a.serializeDateTime)(e.completedAt),assigned_at:null==e.assignedAt?void 0:(0,a.serializeDateTime)(e.assignedAt),reminded_at:null==e.remindedAt?void 0:(0,a.serializeDateTime)(e.remindedAt),resolution_state:null==e.resolutionState?void 0:e.resolutionState,assigned_by:null==e.assignedBy?void 0:(0,o.serializeUserMini)(e.assignedBy)}},t.deserializeTaskAssignment=function(e){if(!(0,u.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TaskAssignment"'});if(null!=e.id&&!(0,c.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TaskAssignment"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:h(e.type),i=null==e.item?void 0:(0,n.deserializeFileMini)(e.item),o=null==e.assigned_to?void 0:(0,s.deserializeUserMini)(e.assigned_to);if(null!=e.message&&!(0,c.sdIsString)(e.message))throw new d.BoxSdkError({message:'Expecting string for "message" of type "TaskAssignment"'});const a=null==e.message?void 0:e.message;if(null!=e.completed_at&&!(0,c.sdIsString)(e.completed_at))throw new d.BoxSdkError({message:'Expecting string for "completed_at" of type "TaskAssignment"'});const p=null==e.completed_at?void 0:(0,l.deserializeDateTime)(e.completed_at);if(null!=e.assigned_at&&!(0,c.sdIsString)(e.assigned_at))throw new d.BoxSdkError({message:'Expecting string for "assigned_at" of type "TaskAssignment"'});const f=null==e.assigned_at?void 0:(0,l.deserializeDateTime)(e.assigned_at);if(null!=e.reminded_at&&!(0,c.sdIsString)(e.reminded_at))throw new d.BoxSdkError({message:'Expecting string for "reminded_at" of type "TaskAssignment"'});const g=null==e.reminded_at?void 0:(0,l.deserializeDateTime)(e.reminded_at),y=null==e.resolution_state?void 0:m(e.resolution_state),v=null==e.assigned_by?void 0:(0,s.deserializeUserMini)(e.assigned_by);return{id:t,type:r,item:i,assignedTo:o,message:a,completedAt:p,assignedAt:f,remindedAt:g,resolutionState:y,assignedBy:v}};const i=r(62929),n=r(62929),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793);function p(e){return e}function h(e){if("task_assignment"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TaskAssignmentTypeField"})}function f(e){return e}function m(e){if("completed"==e)return e;if("incomplete"==e)return e;if("approved"==e)return e;if("rejected"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TaskAssignmentResolutionStateField"})}},85065:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTaskAssignments=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeTaskAssignment)(e)}))}},t.deserializeTaskAssignments=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TaskAssignments"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "TaskAssignments"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TaskAssignments"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeTaskAssignment)(e)})):[];return{totalCount:t,entries:r}};const i=r(6884),n=r(6884),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},46682:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTasks=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeTask)(e)}))}},t.deserializeTasks=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Tasks"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Tasks"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Tasks"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeTask)(e)})):[];return{totalCount:t,entries:r}};const i=r(62125),n=r(62125),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},15048:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTemplateSignerRoleField=u,t.deserializeTemplateSignerRoleField=p,t.serializeTemplateSigner=function(e){return{inputs:null==e.inputs?void 0:e.inputs.map((function(e){return(0,i.serializeTemplateSignerInput)(e)})),email:null==e.email?void 0:e.email,role:null==e.role?void 0:e.role,is_in_person:null==e.isInPerson?void 0:e.isInPerson,order:null==e.order?void 0:e.order,signer_group_id:null==e.signerGroupId?void 0:e.signerGroupId,label:null==e.label?void 0:e.label,public_id:null==e.publicId?void 0:e.publicId}},t.deserializeTemplateSigner=function(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TemplateSigner"'});if(null!=e.inputs&&!(0,d.sdIsList)(e.inputs))throw new o.BoxSdkError({message:'Expecting array for "inputs" of type "TemplateSigner"'});const t=null==e.inputs?void 0:(0,d.sdIsList)(e.inputs)?e.inputs.map((function(e){return(0,n.deserializeTemplateSignerInput)(e)})):[];if(null!=e.email&&!(0,l.sdIsString)(e.email))throw new o.BoxSdkError({message:'Expecting string for "email" of type "TemplateSigner"'});const r=null==e.email?void 0:e.email,i=null==e.role?void 0:p(e.role);if(null!=e.is_in_person&&!(0,s.sdIsBoolean)(e.is_in_person))throw new o.BoxSdkError({message:'Expecting boolean for "is_in_person" of type "TemplateSigner"'});const u=null==e.is_in_person?void 0:e.is_in_person;if(null!=e.order&&!(0,a.sdIsNumber)(e.order))throw new o.BoxSdkError({message:'Expecting number for "order" of type "TemplateSigner"'});const h=null==e.order?void 0:e.order;if(null!=e.signer_group_id&&!(0,l.sdIsString)(e.signer_group_id))throw new o.BoxSdkError({message:'Expecting string for "signer_group_id" of type "TemplateSigner"'});const f=null==e.signer_group_id?void 0:e.signer_group_id;if(null!=e.label&&!(0,l.sdIsString)(e.label))throw new o.BoxSdkError({message:'Expecting string for "label" of type "TemplateSigner"'});const m=null==e.label?void 0:e.label;if(null!=e.public_id&&!(0,l.sdIsString)(e.public_id))throw new o.BoxSdkError({message:'Expecting string for "public_id" of type "TemplateSigner"'});const g=null==e.public_id?void 0:e.public_id;return{inputs:t,email:r,role:i,isInPerson:u,order:h,signerGroupId:f,label:m,publicId:g}};const i=r(8772),n=r(8772),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793),c=r(50793);function u(e){return e}function p(e){if("signer"==e)return e;if("approver"==e)return e;if("final_copy_reader"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TemplateSignerRoleField"})}},8772:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTemplateSignerInputTypeField=u,t.deserializeTemplateSignerInputTypeField=p,t.serializeTemplateSignerInputContentTypeField=h,t.deserializeTemplateSignerInputContentTypeField=f,t.serializeTemplateSignerInputCoordinatesField=m,t.deserializeTemplateSignerInputCoordinatesField=g,t.serializeTemplateSignerInputDimensionsField=y,t.deserializeTemplateSignerInputDimensionsField=v,t.serializeTemplateSignerInput=function(e){const t=(0,n.serializeSignRequestPrefillTag)(e);if(!(0,c.sdIsMap)(t))throw new o.BoxSdkError({message:'Expecting a map for "TemplateSignerInput"'});return Object.assign(Object.assign({},t),{type:null==e.type?void 0:e.type,content_type:null==e.contentType?void 0:e.contentType,is_required:null==e.isRequired?void 0:e.isRequired,page_index:e.pageIndex,document_id:null==e.documentId?void 0:e.documentId,dropdown_choices:null==e.dropdownChoices?void 0:e.dropdownChoices.map((function(e){return e})),group_id:null==e.groupId?void 0:e.groupId,coordinates:null==e.coordinates?void 0:m(e.coordinates),dimensions:null==e.dimensions?void 0:y(e.dimensions),label:null==e.label?void 0:e.label,read_only:null==e.readOnly?void 0:e.readOnly})},t.deserializeTemplateSignerInput=function(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TemplateSignerInput"'});const t=null==e.type?void 0:p(e.type),r=null==e.content_type?void 0:f(e.content_type);if(null!=e.is_required&&!(0,s.sdIsBoolean)(e.is_required))throw new o.BoxSdkError({message:'Expecting boolean for "is_required" of type "TemplateSignerInput"'});const n=null==e.is_required?void 0:e.is_required;if(null==e.page_index)throw new o.BoxSdkError({message:'Expecting "page_index" of type "TemplateSignerInput" to be defined'});if(!(0,a.sdIsNumber)(e.page_index))throw new o.BoxSdkError({message:'Expecting number for "page_index" of type "TemplateSignerInput"'});const u=e.page_index;if(null!=e.document_id&&!(0,l.sdIsString)(e.document_id))throw new o.BoxSdkError({message:'Expecting string for "document_id" of type "TemplateSignerInput"'});const h=null==e.document_id?void 0:e.document_id;if(null!=e.dropdown_choices&&!(0,d.sdIsList)(e.dropdown_choices))throw new o.BoxSdkError({message:'Expecting array for "dropdown_choices" of type "TemplateSignerInput"'});const m=null==e.dropdown_choices?void 0:(0,d.sdIsList)(e.dropdown_choices)?e.dropdown_choices.map((function(e){if(!(0,l.sdIsString)(e))throw new o.BoxSdkError({message:'Expecting string for "TemplateSignerInput"'});return e})):[];if(null!=e.group_id&&!(0,l.sdIsString)(e.group_id))throw new o.BoxSdkError({message:'Expecting string for "group_id" of type "TemplateSignerInput"'});const y=null==e.group_id?void 0:e.group_id,b=null==e.coordinates?void 0:g(e.coordinates),w=null==e.dimensions?void 0:v(e.dimensions);if(null!=e.label&&!(0,l.sdIsString)(e.label))throw new o.BoxSdkError({message:'Expecting string for "label" of type "TemplateSignerInput"'});const _=null==e.label?void 0:e.label;if(null!=e.read_only&&!(0,s.sdIsBoolean)(e.read_only))throw new o.BoxSdkError({message:'Expecting boolean for "read_only" of type "TemplateSignerInput"'});const x=null==e.read_only?void 0:e.read_only;if(null!=e.document_tag_id&&!(0,l.sdIsString)(e.document_tag_id))throw new o.BoxSdkError({message:'Expecting string for "document_tag_id" of type "TemplateSignerInput"'});const S=null==e.document_tag_id?void 0:e.document_tag_id;if(null!=e.text_value&&!(0,l.sdIsString)(e.text_value))throw new o.BoxSdkError({message:'Expecting string for "text_value" of type "TemplateSignerInput"'});const k=null==e.text_value?void 0:e.text_value;if(null!=e.checkbox_value&&!(0,s.sdIsBoolean)(e.checkbox_value))throw new o.BoxSdkError({message:'Expecting boolean for "checkbox_value" of type "TemplateSignerInput"'});const E=null==e.checkbox_value?void 0:e.checkbox_value;if(null!=e.date_value&&!(0,l.sdIsString)(e.date_value))throw new o.BoxSdkError({message:'Expecting string for "date_value" of type "TemplateSignerInput"'});const T=null==e.date_value?void 0:(0,i.deserializeDate)(e.date_value);return{type:t,contentType:r,isRequired:n,pageIndex:u,documentId:h,dropdownChoices:m,groupId:y,coordinates:b,dimensions:w,label:_,readOnly:x,documentTagId:S,textValue:k,checkboxValue:E,dateValue:T}};const i=r(93845),n=r(3798),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793),c=r(50793);function u(e){return e}function p(e){if("signature"==e)return e;if("date"==e)return e;if("text"==e)return e;if("checkbox"==e)return e;if("attachment"==e)return e;if("radio"==e)return e;if("dropdown"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TemplateSignerInputTypeField"})}function h(e){return e}function f(e){if("signature"==e)return e;if("initial"==e)return e;if("stamp"==e)return e;if("date"==e)return e;if("checkbox"==e)return e;if("text"==e)return e;if("full_name"==e)return e;if("first_name"==e)return e;if("last_name"==e)return e;if("company"==e)return e;if("title"==e)return e;if("email"==e)return e;if("attachment"==e)return e;if("radio"==e)return e;if("dropdown"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TemplateSignerInputContentTypeField"})}function m(e){return{x:null==e.x?void 0:e.x,y:null==e.y?void 0:e.y}}function g(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TemplateSignerInputCoordinatesField"'});if(null!=e.x&&!(0,a.sdIsNumber)(e.x))throw new o.BoxSdkError({message:'Expecting number for "x" of type "TemplateSignerInputCoordinatesField"'});const t=null==e.x?void 0:e.x;if(null!=e.y&&!(0,a.sdIsNumber)(e.y))throw new o.BoxSdkError({message:'Expecting number for "y" of type "TemplateSignerInputCoordinatesField"'});return{x:t,y:null==e.y?void 0:e.y}}function y(e){return{width:null==e.width?void 0:e.width,height:null==e.height?void 0:e.height}}function v(e){if(!(0,c.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TemplateSignerInputDimensionsField"'});if(null!=e.width&&!(0,a.sdIsNumber)(e.width))throw new o.BoxSdkError({message:'Expecting number for "width" of type "TemplateSignerInputDimensionsField"'});const t=null==e.width?void 0:e.width;if(null!=e.height&&!(0,a.sdIsNumber)(e.height))throw new o.BoxSdkError({message:'Expecting number for "height" of type "TemplateSignerInputDimensionsField"'});return{width:t,height:null==e.height?void 0:e.height}}},13669:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TermsOfService=void 0,t.serializeTermsOfServiceStatusField=p,t.deserializeTermsOfServiceStatusField=h,t.serializeTermsOfServiceEnterpriseTypeField=f,t.deserializeTermsOfServiceEnterpriseTypeField=m,t.serializeTermsOfServiceEnterpriseField=g,t.deserializeTermsOfServiceEnterpriseField=y,t.serializeTermsOfServiceTosTypeField=v,t.deserializeTermsOfServiceTosTypeField=b,t.serializeTermsOfService=function(e){const t=(0,n.serializeTermsOfServiceBase)(e);if(!(0,c.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "TermsOfService"'});return Object.assign(Object.assign({},t),{status:null==e.status?void 0:e.status,enterprise:null==e.enterprise?void 0:g(e.enterprise),tos_type:null==e.tosType?void 0:e.tosType,text:null==e.text?void 0:e.text,created_at:null==e.createdAt?void 0:(0,o.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,o.serializeDateTime)(e.modifiedAt)})},t.deserializeTermsOfService=function(e){if(!(0,c.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "TermsOfService"'});const t=null==e.status?void 0:h(e.status),r=null==e.enterprise?void 0:y(e.enterprise),n=null==e.tos_type?void 0:b(e.tos_type);if(null!=e.text&&!(0,d.sdIsString)(e.text))throw new l.BoxSdkError({message:'Expecting string for "text" of type "TermsOfService"'});const o=null==e.text?void 0:e.text;if(null!=e.created_at&&!(0,d.sdIsString)(e.created_at))throw new l.BoxSdkError({message:'Expecting string for "created_at" of type "TermsOfService"'});const a=null==e.created_at?void 0:(0,s.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,d.sdIsString)(e.modified_at))throw new l.BoxSdkError({message:'Expecting string for "modified_at" of type "TermsOfService"'});const u=null==e.modified_at?void 0:(0,s.deserializeDateTime)(e.modified_at);if(null==e.id)throw new l.BoxSdkError({message:'Expecting "id" of type "TermsOfService" to be defined'});if(!(0,d.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "TermsOfService"'});const p=e.id;if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "TermsOfService" to be defined'});const f=(0,i.deserializeTermsOfServiceBaseTypeField)(e.type);return{status:t,enterprise:r,tosType:n,text:o,createdAt:a,modifiedAt:u,id:p,type:f}};const i=r(10308),n=r(10308),o=r(93845),s=r(93845),a=r(10308),l=r(72631),d=r(50793),c=r(50793);class u extends a.TermsOfServiceBase{constructor(e){super(e)}}function p(e){return e}function h(e){if("enabled"==e)return e;if("disabled"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize TermsOfServiceStatusField"})}function f(e){return e}function m(e){if("enterprise"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize TermsOfServiceEnterpriseTypeField"})}function g(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}}function y(e){if(!(0,c.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "TermsOfServiceEnterpriseField"'});if(null!=e.id&&!(0,d.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "TermsOfServiceEnterpriseField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:m(e.type);if(null!=e.name&&!(0,d.sdIsString)(e.name))throw new l.BoxSdkError({message:'Expecting string for "name" of type "TermsOfServiceEnterpriseField"'});return{id:t,type:r,name:null==e.name?void 0:e.name}}function v(e){return e}function b(e){if("managed"==e)return e;if("external"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize TermsOfServiceTosTypeField"})}t.TermsOfService=u},10308:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TermsOfServiceBase=void 0,t.serializeTermsOfServiceBaseTypeField=s,t.deserializeTermsOfServiceBaseTypeField=a,t.serializeTermsOfServiceBase=function(e){return{id:e.id,type:e.type}},t.deserializeTermsOfServiceBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "TermsOfServiceBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "TermsOfServiceBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "TermsOfServiceBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "TermsOfServiceBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeTermsOfServiceBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeTermsOfServiceBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "TermsOfServiceBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "TermsOfServiceBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "TermsOfServiceBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("terms_of_service"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize TermsOfServiceBaseTypeField"})}t.TermsOfServiceBase=class{constructor(e){this.type="terms_of_service",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},60848:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TermsOfServiceUserStatus=void 0,t.serializeTermsOfServiceUserStatusTypeField=h,t.deserializeTermsOfServiceUserStatusTypeField=f,t.serializeTermsOfServiceUserStatus=function(e){return{id:e.id,type:e.type,tos:null==e.tos?void 0:(0,i.serializeTermsOfServiceBase)(e.tos),user:null==e.user?void 0:(0,o.serializeUserMini)(e.user),is_accepted:null==e.isAccepted?void 0:e.isAccepted,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt)}},t.deserializeTermsOfServiceUserStatus=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TermsOfServiceUserStatus"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "TermsOfServiceUserStatus" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TermsOfServiceUserStatus"'});const t=e.id;if(null==e.type)throw new d.BoxSdkError({message:'Expecting "type" of type "TermsOfServiceUserStatus" to be defined'});const r=f(e.type),i=null==e.tos?void 0:(0,n.deserializeTermsOfServiceBase)(e.tos),o=null==e.user?void 0:(0,s.deserializeUserMini)(e.user);if(null!=e.is_accepted&&!(0,c.sdIsBoolean)(e.is_accepted))throw new d.BoxSdkError({message:'Expecting boolean for "is_accepted" of type "TermsOfServiceUserStatus"'});const a=null==e.is_accepted?void 0:e.is_accepted;if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TermsOfServiceUserStatus"'});const h=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TermsOfServiceUserStatus"'});const m=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);return{id:t,type:r,tos:i,user:o,isAccepted:a,createdAt:h,modifiedAt:m}},t.serializeTermsOfServiceUserStatusInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,tos:null==e.tos?void 0:(0,i.serializeTermsOfServiceBase)(e.tos),user:null==e.user?void 0:(0,o.serializeUserMini)(e.user),is_accepted:null==e.isAccepted?void 0:e.isAccepted,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt)}},t.deserializeTermsOfServiceUserStatusInput=function(e){if(!(0,p.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TermsOfServiceUserStatusInput"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "TermsOfServiceUserStatusInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TermsOfServiceUserStatusInput"'});const t=e.id,r=null==e.type?void 0:f(e.type),i=null==e.tos?void 0:(0,n.deserializeTermsOfServiceBase)(e.tos),o=null==e.user?void 0:(0,s.deserializeUserMini)(e.user);if(null!=e.is_accepted&&!(0,c.sdIsBoolean)(e.is_accepted))throw new d.BoxSdkError({message:'Expecting boolean for "is_accepted" of type "TermsOfServiceUserStatusInput"'});const a=null==e.is_accepted?void 0:e.is_accepted;if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TermsOfServiceUserStatusInput"'});const h=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TermsOfServiceUserStatusInput"'});const m=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);return{id:t,type:r,tos:i,user:o,isAccepted:a,createdAt:h,modifiedAt:m}};const i=r(10308),n=r(10308),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793);function h(e){return e}function f(e){if("terms_of_service_user_status"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TermsOfServiceUserStatusTypeField"})}t.TermsOfServiceUserStatus=class{constructor(e){this.type="terms_of_service_user_status",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.tos&&(this.tos=e.tos),e.user&&(this.user=e.user),e.isAccepted&&(this.isAccepted=e.isAccepted),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.rawData&&(this.rawData=e.rawData)}}},32228:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTermsOfServiceUserStatuses=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeTermsOfServiceUserStatus)(e)}))}},t.deserializeTermsOfServiceUserStatuses=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TermsOfServiceUserStatuses"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "TermsOfServiceUserStatuses"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TermsOfServiceUserStatuses"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeTermsOfServiceUserStatus)(e)})):[];return{totalCount:t,entries:r}};const i=r(60848),n=r(60848),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},67426:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTermsOfServices=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeTermsOfService)(e)}))}},t.deserializeTermsOfServices=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TermsOfServices"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "TermsOfServices"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.entries&&!(0,a.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TermsOfServices"'});const r=null==e.entries?void 0:(0,a.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeTermsOfService)(e)})):[];return{totalCount:t,entries:r}};const i=r(13669),n=r(13669),o=r(72631),s=r(50793),a=r(50793),l=r(50793)},37086:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TimelineSkillCard=t.TimelineSkillCardInvocationField=t.TimelineSkillCardSkillField=void 0,t.serializeTimelineSkillCardTypeField=c,t.deserializeTimelineSkillCardTypeField=u,t.serializeTimelineSkillCardSkillCardTypeField=p,t.deserializeTimelineSkillCardSkillCardTypeField=h,t.serializeTimelineSkillCardSkillCardTitleField=f,t.deserializeTimelineSkillCardSkillCardTitleField=m,t.serializeTimelineSkillCardSkillTypeField=g,t.deserializeTimelineSkillCardSkillTypeField=y,t.serializeTimelineSkillCardSkillField=v,t.deserializeTimelineSkillCardSkillField=b,t.serializeTimelineSkillCardSkillFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeTimelineSkillCardSkillFieldInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardSkillFieldInput"'});const t=null==e.type?void 0:y(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TimelineSkillCardSkillFieldInput" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TimelineSkillCardSkillFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeTimelineSkillCardInvocationTypeField=w,t.deserializeTimelineSkillCardInvocationTypeField=_,t.serializeTimelineSkillCardInvocationField=x,t.deserializeTimelineSkillCardInvocationField=S,t.serializeTimelineSkillCardInvocationFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeTimelineSkillCardInvocationFieldInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardInvocationFieldInput"'});const t=null==e.type?void 0:_(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TimelineSkillCardInvocationFieldInput" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TimelineSkillCardInvocationFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeTimelineSkillCardEntriesAppearsField=k,t.deserializeTimelineSkillCardEntriesAppearsField=E,t.serializeTimelineSkillCardEntriesField=T,t.deserializeTimelineSkillCardEntriesField=B,t.serializeTimelineSkillCard=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:e.type,skill_card_type:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:f(e.skillCardTitle),skill:v(e.skill),invocation:x(e.invocation),duration:null==e.duration?void 0:e.duration,entries:e.entries.map((function(e){return T(e)}))}},t.deserializeTimelineSkillCard=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCard"'});if(null!=e.created_at&&!(0,a.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "TimelineSkillCard"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TimelineSkillCard" to be defined'});const r=u(e.type);if(null==e.skill_card_type)throw new o.BoxSdkError({message:'Expecting "skill_card_type" of type "TimelineSkillCard" to be defined'});const i=h(e.skill_card_type),c=null==e.skill_card_title?void 0:m(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "TimelineSkillCard" to be defined'});const p=b(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "TimelineSkillCard" to be defined'});const f=S(e.invocation);if(null!=e.duration&&!(0,s.sdIsNumber)(e.duration))throw new o.BoxSdkError({message:'Expecting number for "duration" of type "TimelineSkillCard"'});const g=null==e.duration?void 0:e.duration;if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "TimelineSkillCard" to be defined'});if(!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TimelineSkillCard"'});const y=(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return B(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:c,skill:p,invocation:f,duration:g,entries:y}},t.serializeTimelineSkillCardInput=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:null==e.type?void 0:e.type,skillCardType:null==e.skillCardType?void 0:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:f(e.skillCardTitle),skill:v(e.skill),invocation:x(e.invocation),duration:null==e.duration?void 0:e.duration,entries:e.entries.map((function(e){return T(e)}))}},t.deserializeTimelineSkillCardInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardInput"'});if(null!=e.created_at&&!(0,a.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "TimelineSkillCardInput"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at),r=null==e.type?void 0:u(e.type),i=null==e.skillCardType?void 0:h(e.skillCardType),c=null==e.skill_card_title?void 0:m(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "TimelineSkillCardInput" to be defined'});const p=b(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "TimelineSkillCardInput" to be defined'});const f=S(e.invocation);if(null!=e.duration&&!(0,s.sdIsNumber)(e.duration))throw new o.BoxSdkError({message:'Expecting number for "duration" of type "TimelineSkillCardInput"'});const g=null==e.duration?void 0:e.duration;if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "TimelineSkillCardInput" to be defined'});if(!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TimelineSkillCardInput"'});const y=(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return B(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:c,skill:p,invocation:f,duration:g,entries:y}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);t.TimelineSkillCardSkillField=class{constructor(e){this.type="service",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};t.TimelineSkillCardInvocationField=class{constructor(e){this.type="skill_invocation",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};function c(e){return e}function u(e){if("skill_card"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TimelineSkillCardTypeField"})}function p(e){return e}function h(e){if("timeline"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TimelineSkillCardSkillCardTypeField"})}function f(e){return{code:null==e.code?void 0:e.code,message:e.message}}function m(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardSkillCardTitleField"'});if(null!=e.code&&!(0,a.sdIsString)(e.code))throw new o.BoxSdkError({message:'Expecting string for "code" of type "TimelineSkillCardSkillCardTitleField"'});const t=null==e.code?void 0:e.code;if(null==e.message)throw new o.BoxSdkError({message:'Expecting "message" of type "TimelineSkillCardSkillCardTitleField" to be defined'});if(!(0,a.sdIsString)(e.message))throw new o.BoxSdkError({message:'Expecting string for "message" of type "TimelineSkillCardSkillCardTitleField"'});return{code:t,message:e.message}}function g(e){return e}function y(e){if("service"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TimelineSkillCardSkillTypeField"})}function v(e){return{type:e.type,id:e.id}}function b(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardSkillField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TimelineSkillCardSkillField" to be defined'});const t=y(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TimelineSkillCardSkillField" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TimelineSkillCardSkillField"'});return{type:t,id:e.id}}function w(e){return e}function _(e){if("skill_invocation"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TimelineSkillCardInvocationTypeField"})}function x(e){return{type:e.type,id:e.id}}function S(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardInvocationField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TimelineSkillCardInvocationField" to be defined'});const t=_(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TimelineSkillCardInvocationField" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TimelineSkillCardInvocationField"'});return{type:t,id:e.id}}function k(e){return{start:null==e.start?void 0:e.start,end:null==e.end?void 0:e.end}}function E(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardEntriesAppearsField"'});if(null!=e.start&&!(0,s.sdIsNumber)(e.start))throw new o.BoxSdkError({message:'Expecting number for "start" of type "TimelineSkillCardEntriesAppearsField"'});const t=null==e.start?void 0:e.start;if(null!=e.end&&!(0,s.sdIsNumber)(e.end))throw new o.BoxSdkError({message:'Expecting number for "end" of type "TimelineSkillCardEntriesAppearsField"'});return{start:t,end:null==e.end?void 0:e.end}}function T(e){return{text:null==e.text?void 0:e.text,appears:null==e.appears?void 0:e.appears.map((function(e){return k(e)})),image_url:null==e.imageUrl?void 0:e.imageUrl}}function B(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TimelineSkillCardEntriesField"'});if(null!=e.text&&!(0,a.sdIsString)(e.text))throw new o.BoxSdkError({message:'Expecting string for "text" of type "TimelineSkillCardEntriesField"'});const t=null==e.text?void 0:e.text;if(null!=e.appears&&!(0,l.sdIsList)(e.appears))throw new o.BoxSdkError({message:'Expecting array for "appears" of type "TimelineSkillCardEntriesField"'});const r=null==e.appears?void 0:(0,l.sdIsList)(e.appears)?e.appears.map((function(e){return E(e)})):[];if(null!=e.image_url&&!(0,a.sdIsString)(e.image_url))throw new o.BoxSdkError({message:'Expecting string for "image_url" of type "TimelineSkillCardEntriesField"'});return{text:t,appears:r,imageUrl:null==e.image_url?void 0:e.image_url}}t.TimelineSkillCard=class{constructor(e){this.type="skill_card",this.skillCardType="timeline",e.createdAt&&(this.createdAt=e.createdAt),e.type&&(this.type=e.type),e.skillCardType&&(this.skillCardType=e.skillCardType),e.skillCardTitle&&(this.skillCardTitle=e.skillCardTitle),e.skill&&(this.skill=e.skill),e.invocation&&(this.invocation=e.invocation),e.duration&&(this.duration=e.duration),e.entries&&(this.entries=e.entries),e.rawData&&(this.rawData=e.rawData)}}},55852:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTrackingCodeTypeField=s,t.deserializeTrackingCodeTypeField=a,t.serializeTrackingCode=function(e){return{type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name,value:null==e.value?void 0:e.value}},t.deserializeTrackingCode=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "TrackingCode"'});const t=null==e.type?void 0:a(e.type);if(null!=e.name&&!(0,n.sdIsString)(e.name))throw new i.BoxSdkError({message:'Expecting string for "name" of type "TrackingCode"'});const r=null==e.name?void 0:e.name;if(null!=e.value&&!(0,n.sdIsString)(e.value))throw new i.BoxSdkError({message:'Expecting string for "value" of type "TrackingCode"'});const s=null==e.value?void 0:e.value;return{type:t,name:r,value:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("tracking_code"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize TrackingCodeTypeField"})}},20749:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TranscriptSkillCard=t.TranscriptSkillCardInvocationField=t.TranscriptSkillCardSkillField=void 0,t.serializeTranscriptSkillCardTypeField=c,t.deserializeTranscriptSkillCardTypeField=u,t.serializeTranscriptSkillCardSkillCardTypeField=p,t.deserializeTranscriptSkillCardSkillCardTypeField=h,t.serializeTranscriptSkillCardSkillCardTitleField=f,t.deserializeTranscriptSkillCardSkillCardTitleField=m,t.serializeTranscriptSkillCardSkillTypeField=g,t.deserializeTranscriptSkillCardSkillTypeField=y,t.serializeTranscriptSkillCardSkillField=v,t.deserializeTranscriptSkillCardSkillField=b,t.serializeTranscriptSkillCardSkillFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeTranscriptSkillCardSkillFieldInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardSkillFieldInput"'});const t=null==e.type?void 0:y(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TranscriptSkillCardSkillFieldInput" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TranscriptSkillCardSkillFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeTranscriptSkillCardInvocationTypeField=w,t.deserializeTranscriptSkillCardInvocationTypeField=_,t.serializeTranscriptSkillCardInvocationField=x,t.deserializeTranscriptSkillCardInvocationField=S,t.serializeTranscriptSkillCardInvocationFieldInput=function(e){return{type:null==e.type?void 0:e.type,id:e.id}},t.deserializeTranscriptSkillCardInvocationFieldInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardInvocationFieldInput"'});const t=null==e.type?void 0:_(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TranscriptSkillCardInvocationFieldInput" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TranscriptSkillCardInvocationFieldInput"'});const r=e.id;return{type:t,id:r}},t.serializeTranscriptSkillCardEntriesAppearsField=k,t.deserializeTranscriptSkillCardEntriesAppearsField=E,t.serializeTranscriptSkillCardEntriesField=T,t.deserializeTranscriptSkillCardEntriesField=B,t.serializeTranscriptSkillCard=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:e.type,skill_card_type:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:f(e.skillCardTitle),skill:v(e.skill),invocation:x(e.invocation),duration:null==e.duration?void 0:e.duration,entries:e.entries.map((function(e){return T(e)}))}},t.deserializeTranscriptSkillCard=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCard"'});if(null!=e.created_at&&!(0,a.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "TranscriptSkillCard"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TranscriptSkillCard" to be defined'});const r=u(e.type);if(null==e.skill_card_type)throw new o.BoxSdkError({message:'Expecting "skill_card_type" of type "TranscriptSkillCard" to be defined'});const i=h(e.skill_card_type),c=null==e.skill_card_title?void 0:m(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "TranscriptSkillCard" to be defined'});const p=b(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "TranscriptSkillCard" to be defined'});const f=S(e.invocation);if(null!=e.duration&&!(0,s.sdIsNumber)(e.duration))throw new o.BoxSdkError({message:'Expecting number for "duration" of type "TranscriptSkillCard"'});const g=null==e.duration?void 0:e.duration;if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "TranscriptSkillCard" to be defined'});if(!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TranscriptSkillCard"'});const y=(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return B(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:c,skill:p,invocation:f,duration:g,entries:y}},t.serializeTranscriptSkillCardInput=function(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),type:null==e.type?void 0:e.type,skillCardType:null==e.skillCardType?void 0:e.skillCardType,skill_card_title:null==e.skillCardTitle?void 0:f(e.skillCardTitle),skill:v(e.skill),invocation:x(e.invocation),duration:null==e.duration?void 0:e.duration,entries:e.entries.map((function(e){return T(e)}))}},t.deserializeTranscriptSkillCardInput=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardInput"'});if(null!=e.created_at&&!(0,a.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "TranscriptSkillCardInput"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at),r=null==e.type?void 0:u(e.type),i=null==e.skillCardType?void 0:h(e.skillCardType),c=null==e.skill_card_title?void 0:m(e.skill_card_title);if(null==e.skill)throw new o.BoxSdkError({message:'Expecting "skill" of type "TranscriptSkillCardInput" to be defined'});const p=b(e.skill);if(null==e.invocation)throw new o.BoxSdkError({message:'Expecting "invocation" of type "TranscriptSkillCardInput" to be defined'});const f=S(e.invocation);if(null!=e.duration&&!(0,s.sdIsNumber)(e.duration))throw new o.BoxSdkError({message:'Expecting number for "duration" of type "TranscriptSkillCardInput"'});const g=null==e.duration?void 0:e.duration;if(null==e.entries)throw new o.BoxSdkError({message:'Expecting "entries" of type "TranscriptSkillCardInput" to be defined'});if(!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "TranscriptSkillCardInput"'});const y=(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return B(e)})):[];return{createdAt:t,type:r,skillCardType:i,skillCardTitle:c,skill:p,invocation:f,duration:g,entries:y}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);t.TranscriptSkillCardSkillField=class{constructor(e){this.type="service",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};t.TranscriptSkillCardInvocationField=class{constructor(e){this.type="skill_invocation",e.type&&(this.type=e.type),e.id&&(this.id=e.id),e.rawData&&(this.rawData=e.rawData)}};function c(e){return e}function u(e){if("skill_card"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TranscriptSkillCardTypeField"})}function p(e){return e}function h(e){if("transcript"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TranscriptSkillCardSkillCardTypeField"})}function f(e){return{code:null==e.code?void 0:e.code,message:e.message}}function m(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardSkillCardTitleField"'});if(null!=e.code&&!(0,a.sdIsString)(e.code))throw new o.BoxSdkError({message:'Expecting string for "code" of type "TranscriptSkillCardSkillCardTitleField"'});const t=null==e.code?void 0:e.code;if(null==e.message)throw new o.BoxSdkError({message:'Expecting "message" of type "TranscriptSkillCardSkillCardTitleField" to be defined'});if(!(0,a.sdIsString)(e.message))throw new o.BoxSdkError({message:'Expecting string for "message" of type "TranscriptSkillCardSkillCardTitleField"'});return{code:t,message:e.message}}function g(e){return e}function y(e){if("service"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TranscriptSkillCardSkillTypeField"})}function v(e){return{type:e.type,id:e.id}}function b(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardSkillField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TranscriptSkillCardSkillField" to be defined'});const t=y(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TranscriptSkillCardSkillField" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TranscriptSkillCardSkillField"'});return{type:t,id:e.id}}function w(e){return e}function _(e){if("skill_invocation"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize TranscriptSkillCardInvocationTypeField"})}function x(e){return{type:e.type,id:e.id}}function S(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardInvocationField"'});if(null==e.type)throw new o.BoxSdkError({message:'Expecting "type" of type "TranscriptSkillCardInvocationField" to be defined'});const t=_(e.type);if(null==e.id)throw new o.BoxSdkError({message:'Expecting "id" of type "TranscriptSkillCardInvocationField" to be defined'});if(!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "TranscriptSkillCardInvocationField"'});return{type:t,id:e.id}}function k(e){return{start:null==e.start?void 0:e.start}}function E(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardEntriesAppearsField"'});if(null!=e.start&&!(0,s.sdIsNumber)(e.start))throw new o.BoxSdkError({message:'Expecting number for "start" of type "TranscriptSkillCardEntriesAppearsField"'});return{start:null==e.start?void 0:e.start}}function T(e){return{text:null==e.text?void 0:e.text,appears:null==e.appears?void 0:e.appears.map((function(e){return k(e)}))}}function B(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "TranscriptSkillCardEntriesField"'});if(null!=e.text&&!(0,a.sdIsString)(e.text))throw new o.BoxSdkError({message:'Expecting string for "text" of type "TranscriptSkillCardEntriesField"'});const t=null==e.text?void 0:e.text;if(null!=e.appears&&!(0,l.sdIsList)(e.appears))throw new o.BoxSdkError({message:'Expecting array for "appears" of type "TranscriptSkillCardEntriesField"'});return{text:t,appears:null==e.appears?void 0:(0,l.sdIsList)(e.appears)?e.appears.map((function(e){return E(e)})):[]}}t.TranscriptSkillCard=class{constructor(e){this.type="skill_card",this.skillCardType="transcript",e.createdAt&&(this.createdAt=e.createdAt),e.type&&(this.type=e.type),e.skillCardType&&(this.skillCardType=e.skillCardType),e.skillCardTitle&&(this.skillCardTitle=e.skillCardTitle),e.skill&&(this.skill=e.skill),e.invocation&&(this.invocation=e.invocation),e.duration&&(this.duration=e.duration),e.entries&&(this.entries=e.entries),e.rawData&&(this.rawData=e.rawData)}}},37416:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TrashFile=void 0,t.serializeTrashFileTypeField=g,t.deserializeTrashFileTypeField=y,t.serializeTrashFilePathCollectionEntriesTypeField=v,t.deserializeTrashFilePathCollectionEntriesTypeField=b,t.serializeTrashFilePathCollectionEntriesField=w,t.deserializeTrashFilePathCollectionEntriesField=_,t.serializeTrashFilePathCollectionField=x,t.deserializeTrashFilePathCollectionField=S,t.serializeTrashFileItemStatusField=k,t.deserializeTrashFileItemStatusField=E,t.serializeTrashFile=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:e.type,sequence_id:e.sequenceId,name:null==e.name?void 0:e.name,sha1:e.sha1,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),description:e.description,size:e.size,path_collection:x(e.pathCollection),created_at:(0,d.serializeDateTime)(e.createdAt),modified_at:(0,d.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:(0,d.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,d.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,d.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,d.serializeDateTime)(e.contentModifiedAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),modified_by:(0,o.serializeUserMini)(e.modifiedBy),owned_by:(0,o.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,parent:null==e.parent?void 0:(0,a.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFile=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFile"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "TrashFile"'});const t=e.id;if(null!=e.etag&&!(0,h.sdIsString)(e.etag))throw new u.BoxSdkError({message:'Expecting string for "etag" of type "TrashFile"'});const r=null==e.etag?void 0:e.etag;if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "TrashFile" to be defined'});const i=y(e.type);if(null==e.sequence_id)throw new u.BoxSdkError({message:'Expecting "sequence_id" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.sequence_id))throw new u.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFile"'});const o=e.sequence_id;if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "TrashFile"'});const a=null==e.name?void 0:e.name;if(null==e.sha1)throw new u.BoxSdkError({message:'Expecting "sha1" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.sha1))throw new u.BoxSdkError({message:'Expecting string for "sha1" of type "TrashFile"'});const d=e.sha1,f=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.description)throw new u.BoxSdkError({message:'Expecting "description" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "TrashFile"'});const g=e.description;if(null==e.size)throw new u.BoxSdkError({message:'Expecting "size" of type "TrashFile" to be defined'});if(!(0,p.sdIsNumber)(e.size))throw new u.BoxSdkError({message:'Expecting number for "size" of type "TrashFile"'});const v=e.size;if(null==e.path_collection)throw new u.BoxSdkError({message:'Expecting "path_collection" of type "TrashFile" to be defined'});const b=S(e.path_collection);if(null==e.created_at)throw new u.BoxSdkError({message:'Expecting "created_at" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFile"'});const w=(0,c.deserializeDateTime)(e.created_at);if(null==e.modified_at)throw new u.BoxSdkError({message:'Expecting "modified_at" of type "TrashFile" to be defined'});if(!(0,h.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFile"'});const _=(0,c.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,h.sdIsString)(e.trashed_at))throw new u.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFile"'});const x=null==e.trashed_at?void 0:(0,c.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,h.sdIsString)(e.purged_at))throw new u.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFile"'});const k=null==e.purged_at?void 0:(0,c.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,h.sdIsString)(e.content_created_at))throw new u.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFile"'});const T=null==e.content_created_at?void 0:(0,c.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,h.sdIsString)(e.content_modified_at))throw new u.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFile"'});const B=null==e.content_modified_at?void 0:(0,c.deserializeDateTime)(e.content_modified_at),C=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new u.BoxSdkError({message:'Expecting "modified_by" of type "TrashFile" to be defined'});const I=(0,s.deserializeUserMini)(e.modified_by);if(null==e.owned_by)throw new u.BoxSdkError({message:'Expecting "owned_by" of type "TrashFile" to be defined'});const A=(0,s.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,h.sdIsString)(e.shared_link))throw new u.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFile"'});const F=null==e.shared_link?void 0:e.shared_link,M=null==e.parent?void 0:(0,l.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new u.BoxSdkError({message:'Expecting "item_status" of type "TrashFile" to be defined'});const D=E(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,sha1:d,fileVersion:f,description:g,size:v,pathCollection:b,createdAt:w,modifiedAt:_,trashedAt:x,purgedAt:k,contentCreatedAt:T,contentModifiedAt:B,createdBy:C,modifiedBy:I,ownedBy:A,sharedLink:F,parent:M,itemStatus:D}},t.serializeTrashFileInput=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type,sequence_id:e.sequenceId,name:null==e.name?void 0:e.name,sha1:e.sha1,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),description:e.description,size:e.size,path_collection:x(e.pathCollection),created_at:(0,d.serializeDateTime)(e.createdAt),modified_at:(0,d.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:(0,d.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,d.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,d.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,d.serializeDateTime)(e.contentModifiedAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),modified_by:(0,o.serializeUserMini)(e.modifiedBy),owned_by:(0,o.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,parent:null==e.parent?void 0:(0,a.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFileInput=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFileInput"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "TrashFileInput"'});const t=e.id;if(null!=e.etag&&!(0,h.sdIsString)(e.etag))throw new u.BoxSdkError({message:'Expecting string for "etag" of type "TrashFileInput"'});const r=null==e.etag?void 0:e.etag,i=null==e.type?void 0:y(e.type);if(null==e.sequence_id)throw new u.BoxSdkError({message:'Expecting "sequence_id" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.sequence_id))throw new u.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFileInput"'});const o=e.sequence_id;if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "TrashFileInput"'});const a=null==e.name?void 0:e.name;if(null==e.sha1)throw new u.BoxSdkError({message:'Expecting "sha1" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.sha1))throw new u.BoxSdkError({message:'Expecting string for "sha1" of type "TrashFileInput"'});const d=e.sha1,f=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.description)throw new u.BoxSdkError({message:'Expecting "description" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "TrashFileInput"'});const g=e.description;if(null==e.size)throw new u.BoxSdkError({message:'Expecting "size" of type "TrashFileInput" to be defined'});if(!(0,p.sdIsNumber)(e.size))throw new u.BoxSdkError({message:'Expecting number for "size" of type "TrashFileInput"'});const v=e.size;if(null==e.path_collection)throw new u.BoxSdkError({message:'Expecting "path_collection" of type "TrashFileInput" to be defined'});const b=S(e.path_collection);if(null==e.created_at)throw new u.BoxSdkError({message:'Expecting "created_at" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFileInput"'});const w=(0,c.deserializeDateTime)(e.created_at);if(null==e.modified_at)throw new u.BoxSdkError({message:'Expecting "modified_at" of type "TrashFileInput" to be defined'});if(!(0,h.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFileInput"'});const _=(0,c.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,h.sdIsString)(e.trashed_at))throw new u.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFileInput"'});const x=null==e.trashed_at?void 0:(0,c.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,h.sdIsString)(e.purged_at))throw new u.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFileInput"'});const k=null==e.purged_at?void 0:(0,c.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,h.sdIsString)(e.content_created_at))throw new u.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFileInput"'});const T=null==e.content_created_at?void 0:(0,c.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,h.sdIsString)(e.content_modified_at))throw new u.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFileInput"'});const B=null==e.content_modified_at?void 0:(0,c.deserializeDateTime)(e.content_modified_at),C=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new u.BoxSdkError({message:'Expecting "modified_by" of type "TrashFileInput" to be defined'});const I=(0,s.deserializeUserMini)(e.modified_by);if(null==e.owned_by)throw new u.BoxSdkError({message:'Expecting "owned_by" of type "TrashFileInput" to be defined'});const A=(0,s.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,h.sdIsString)(e.shared_link))throw new u.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFileInput"'});const F=null==e.shared_link?void 0:e.shared_link,M=null==e.parent?void 0:(0,l.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new u.BoxSdkError({message:'Expecting "item_status" of type "TrashFileInput" to be defined'});const D=E(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,sha1:d,fileVersion:f,description:g,size:v,pathCollection:b,createdAt:w,modifiedAt:_,trashedAt:x,purgedAt:k,contentCreatedAt:T,contentModifiedAt:B,createdBy:C,modifiedBy:I,ownedBy:A,sharedLink:F,parent:M,itemStatus:D}};const i=r(95053),n=r(95053),o=r(95408),s=r(95408),a=r(70343),l=r(70343),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793);function g(e){return e}function y(e){if("file"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TrashFileTypeField"})}function v(e){return e}function b(e){if("folder"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TrashFilePathCollectionEntriesTypeField"})}function w(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,sequence_id:null==e.sequenceId?void 0:e.sequenceId,etag:null==e.etag?void 0:e.etag,name:null==e.name?void 0:e.name}}function _(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFilePathCollectionEntriesField"'});const t=null==e.type?void 0:b(e.type);if(null!=e.id&&!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "TrashFilePathCollectionEntriesField"'});const r=null==e.id?void 0:e.id;if(null!=e.sequence_id&&!(0,h.sdIsString)(e.sequence_id))throw new u.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFilePathCollectionEntriesField"'});const i=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.etag&&!(0,h.sdIsString)(e.etag))throw new u.BoxSdkError({message:'Expecting string for "etag" of type "TrashFilePathCollectionEntriesField"'});const n=null==e.etag?void 0:e.etag;if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "TrashFilePathCollectionEntriesField"'});return{type:t,id:r,sequenceId:i,etag:n,name:null==e.name?void 0:e.name}}function x(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return w(e)}))}}function S(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFilePathCollectionField"'});if(null==e.total_count)throw new u.BoxSdkError({message:'Expecting "total_count" of type "TrashFilePathCollectionField" to be defined'});if(!(0,p.sdIsNumber)(e.total_count))throw new u.BoxSdkError({message:'Expecting number for "total_count" of type "TrashFilePathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new u.BoxSdkError({message:'Expecting "entries" of type "TrashFilePathCollectionField" to be defined'});if(!(0,f.sdIsList)(e.entries))throw new u.BoxSdkError({message:'Expecting array for "entries" of type "TrashFilePathCollectionField"'});return{totalCount:t,entries:(0,f.sdIsList)(e.entries)?e.entries.map((function(e){return _(e)})):[]}}function k(e){return e}function E(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TrashFileItemStatusField"})}t.TrashFile=class{constructor(e){this.type="file",e.id&&(this.id=e.id),e.etag&&(this.etag=e.etag),e.type&&(this.type=e.type),e.sequenceId&&(this.sequenceId=e.sequenceId),e.name&&(this.name=e.name),e.sha1&&(this.sha1=e.sha1),e.fileVersion&&(this.fileVersion=e.fileVersion),e.description&&(this.description=e.description),e.size&&(this.size=e.size),e.pathCollection&&(this.pathCollection=e.pathCollection),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.trashedAt&&(this.trashedAt=e.trashedAt),e.purgedAt&&(this.purgedAt=e.purgedAt),e.contentCreatedAt&&(this.contentCreatedAt=e.contentCreatedAt),e.contentModifiedAt&&(this.contentModifiedAt=e.contentModifiedAt),e.createdBy&&(this.createdBy=e.createdBy),e.modifiedBy&&(this.modifiedBy=e.modifiedBy),e.ownedBy&&(this.ownedBy=e.ownedBy),e.sharedLink&&(this.sharedLink=e.sharedLink),e.parent&&(this.parent=e.parent),e.itemStatus&&(this.itemStatus=e.itemStatus),e.rawData&&(this.rawData=e.rawData)}}},40950:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TrashFileRestored=void 0,t.serializeTrashFileRestoredTypeField=g,t.deserializeTrashFileRestoredTypeField=y,t.serializeTrashFileRestoredPathCollectionField=v,t.deserializeTrashFileRestoredPathCollectionField=b,t.serializeTrashFileRestoredItemStatusField=w,t.deserializeTrashFileRestoredItemStatusField=_,t.serializeTrashFileRestored=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:e.type,sequence_id:e.sequenceId,name:null==e.name?void 0:e.name,sha1:e.sha1,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),description:e.description,size:e.size,path_collection:v(e.pathCollection),created_at:(0,d.serializeDateTime)(e.createdAt),modified_at:(0,d.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:e.trashedAt,purged_at:null==e.purgedAt?void 0:e.purgedAt,content_created_at:null==e.contentCreatedAt?void 0:(0,d.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,d.serializeDateTime)(e.contentModifiedAt),created_by:null==e.createdBy?void 0:(0,a.serializeUserMini)(e.createdBy),modified_by:(0,a.serializeUserMini)(e.modifiedBy),owned_by:(0,a.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,parent:null==e.parent?void 0:(0,o.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFileRestored=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFileRestored"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "TrashFileRestored"'});const t=e.id;if(null!=e.etag&&!(0,h.sdIsString)(e.etag))throw new u.BoxSdkError({message:'Expecting string for "etag" of type "TrashFileRestored"'});const r=null==e.etag?void 0:e.etag;if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "TrashFileRestored" to be defined'});const i=y(e.type);if(null==e.sequence_id)throw new u.BoxSdkError({message:'Expecting "sequence_id" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.sequence_id))throw new u.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFileRestored"'});const o=e.sequence_id;if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "TrashFileRestored"'});const a=null==e.name?void 0:e.name;if(null==e.sha1)throw new u.BoxSdkError({message:'Expecting "sha1" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.sha1))throw new u.BoxSdkError({message:'Expecting string for "sha1" of type "TrashFileRestored"'});const d=e.sha1,f=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.description)throw new u.BoxSdkError({message:'Expecting "description" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "TrashFileRestored"'});const g=e.description;if(null==e.size)throw new u.BoxSdkError({message:'Expecting "size" of type "TrashFileRestored" to be defined'});if(!(0,p.sdIsNumber)(e.size))throw new u.BoxSdkError({message:'Expecting number for "size" of type "TrashFileRestored"'});const v=e.size;if(null==e.path_collection)throw new u.BoxSdkError({message:'Expecting "path_collection" of type "TrashFileRestored" to be defined'});const w=b(e.path_collection);if(null==e.created_at)throw new u.BoxSdkError({message:'Expecting "created_at" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFileRestored"'});const x=(0,c.deserializeDateTime)(e.created_at);if(null==e.modified_at)throw new u.BoxSdkError({message:'Expecting "modified_at" of type "TrashFileRestored" to be defined'});if(!(0,h.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFileRestored"'});const S=(0,c.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,h.sdIsString)(e.trashed_at))throw new u.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFileRestored"'});const k=null==e.trashed_at?void 0:e.trashed_at;if(null!=e.purged_at&&!(0,h.sdIsString)(e.purged_at))throw new u.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFileRestored"'});const E=null==e.purged_at?void 0:e.purged_at;if(null!=e.content_created_at&&!(0,h.sdIsString)(e.content_created_at))throw new u.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFileRestored"'});const T=null==e.content_created_at?void 0:(0,c.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,h.sdIsString)(e.content_modified_at))throw new u.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFileRestored"'});const B=null==e.content_modified_at?void 0:(0,c.deserializeDateTime)(e.content_modified_at),C=null==e.created_by?void 0:(0,l.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new u.BoxSdkError({message:'Expecting "modified_by" of type "TrashFileRestored" to be defined'});const I=(0,l.deserializeUserMini)(e.modified_by);if(null==e.owned_by)throw new u.BoxSdkError({message:'Expecting "owned_by" of type "TrashFileRestored" to be defined'});const A=(0,l.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,h.sdIsString)(e.shared_link))throw new u.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFileRestored"'});const F=null==e.shared_link?void 0:e.shared_link,M=null==e.parent?void 0:(0,s.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new u.BoxSdkError({message:'Expecting "item_status" of type "TrashFileRestored" to be defined'});const D=_(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,sha1:d,fileVersion:f,description:g,size:v,pathCollection:w,createdAt:x,modifiedAt:S,trashedAt:k,purgedAt:E,contentCreatedAt:T,contentModifiedAt:B,createdBy:C,modifiedBy:I,ownedBy:A,sharedLink:F,parent:M,itemStatus:D}},t.serializeTrashFileRestoredInput=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type,sequence_id:e.sequenceId,name:null==e.name?void 0:e.name,sha1:e.sha1,file_version:null==e.fileVersion?void 0:(0,i.serializeFileVersionMini)(e.fileVersion),description:e.description,size:e.size,path_collection:v(e.pathCollection),created_at:(0,d.serializeDateTime)(e.createdAt),modified_at:(0,d.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:e.trashedAt,purged_at:null==e.purgedAt?void 0:e.purgedAt,content_created_at:null==e.contentCreatedAt?void 0:(0,d.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,d.serializeDateTime)(e.contentModifiedAt),created_by:null==e.createdBy?void 0:(0,a.serializeUserMini)(e.createdBy),modified_by:(0,a.serializeUserMini)(e.modifiedBy),owned_by:(0,a.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,parent:null==e.parent?void 0:(0,o.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFileRestoredInput=function(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFileRestoredInput"'});if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "TrashFileRestoredInput"'});const t=e.id;if(null!=e.etag&&!(0,h.sdIsString)(e.etag))throw new u.BoxSdkError({message:'Expecting string for "etag" of type "TrashFileRestoredInput"'});const r=null==e.etag?void 0:e.etag,i=null==e.type?void 0:y(e.type);if(null==e.sequence_id)throw new u.BoxSdkError({message:'Expecting "sequence_id" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.sequence_id))throw new u.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFileRestoredInput"'});const o=e.sequence_id;if(null!=e.name&&!(0,h.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "TrashFileRestoredInput"'});const a=null==e.name?void 0:e.name;if(null==e.sha1)throw new u.BoxSdkError({message:'Expecting "sha1" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.sha1))throw new u.BoxSdkError({message:'Expecting string for "sha1" of type "TrashFileRestoredInput"'});const d=e.sha1,f=null==e.file_version?void 0:(0,n.deserializeFileVersionMini)(e.file_version);if(null==e.description)throw new u.BoxSdkError({message:'Expecting "description" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.description))throw new u.BoxSdkError({message:'Expecting string for "description" of type "TrashFileRestoredInput"'});const g=e.description;if(null==e.size)throw new u.BoxSdkError({message:'Expecting "size" of type "TrashFileRestoredInput" to be defined'});if(!(0,p.sdIsNumber)(e.size))throw new u.BoxSdkError({message:'Expecting number for "size" of type "TrashFileRestoredInput"'});const v=e.size;if(null==e.path_collection)throw new u.BoxSdkError({message:'Expecting "path_collection" of type "TrashFileRestoredInput" to be defined'});const w=b(e.path_collection);if(null==e.created_at)throw new u.BoxSdkError({message:'Expecting "created_at" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFileRestoredInput"'});const x=(0,c.deserializeDateTime)(e.created_at);if(null==e.modified_at)throw new u.BoxSdkError({message:'Expecting "modified_at" of type "TrashFileRestoredInput" to be defined'});if(!(0,h.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFileRestoredInput"'});const S=(0,c.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,h.sdIsString)(e.trashed_at))throw new u.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFileRestoredInput"'});const k=null==e.trashed_at?void 0:e.trashed_at;if(null!=e.purged_at&&!(0,h.sdIsString)(e.purged_at))throw new u.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFileRestoredInput"'});const E=null==e.purged_at?void 0:e.purged_at;if(null!=e.content_created_at&&!(0,h.sdIsString)(e.content_created_at))throw new u.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFileRestoredInput"'});const T=null==e.content_created_at?void 0:(0,c.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,h.sdIsString)(e.content_modified_at))throw new u.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFileRestoredInput"'});const B=null==e.content_modified_at?void 0:(0,c.deserializeDateTime)(e.content_modified_at),C=null==e.created_by?void 0:(0,l.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new u.BoxSdkError({message:'Expecting "modified_by" of type "TrashFileRestoredInput" to be defined'});const I=(0,l.deserializeUserMini)(e.modified_by);if(null==e.owned_by)throw new u.BoxSdkError({message:'Expecting "owned_by" of type "TrashFileRestoredInput" to be defined'});const A=(0,l.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,h.sdIsString)(e.shared_link))throw new u.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFileRestoredInput"'});const F=null==e.shared_link?void 0:e.shared_link,M=null==e.parent?void 0:(0,s.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new u.BoxSdkError({message:'Expecting "item_status" of type "TrashFileRestoredInput" to be defined'});const D=_(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,sha1:d,fileVersion:f,description:g,size:v,pathCollection:w,createdAt:x,modifiedAt:S,trashedAt:k,purgedAt:E,contentCreatedAt:T,contentModifiedAt:B,createdBy:C,modifiedBy:I,ownedBy:A,sharedLink:F,parent:M,itemStatus:D}};const i=r(95053),n=r(95053),o=r(70343),s=r(70343),a=r(95408),l=r(95408),d=r(93845),c=r(93845),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793);function g(e){return e}function y(e){if("file"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TrashFileRestoredTypeField"})}function v(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,o.serializeFolderMini)(e)}))}}function b(e){if(!(0,m.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "TrashFileRestoredPathCollectionField"'});if(null==e.total_count)throw new u.BoxSdkError({message:'Expecting "total_count" of type "TrashFileRestoredPathCollectionField" to be defined'});if(!(0,p.sdIsNumber)(e.total_count))throw new u.BoxSdkError({message:'Expecting number for "total_count" of type "TrashFileRestoredPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new u.BoxSdkError({message:'Expecting "entries" of type "TrashFileRestoredPathCollectionField" to be defined'});if(!(0,f.sdIsList)(e.entries))throw new u.BoxSdkError({message:'Expecting array for "entries" of type "TrashFileRestoredPathCollectionField"'});return{totalCount:t,entries:(0,f.sdIsList)(e.entries)?e.entries.map((function(e){return(0,s.deserializeFolderMini)(e)})):[]}}function w(e){return e}function _(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize TrashFileRestoredItemStatusField"})}t.TrashFileRestored=class{constructor(e){this.type="file",e.id&&(this.id=e.id),e.etag&&(this.etag=e.etag),e.type&&(this.type=e.type),e.sequenceId&&(this.sequenceId=e.sequenceId),e.name&&(this.name=e.name),e.sha1&&(this.sha1=e.sha1),e.fileVersion&&(this.fileVersion=e.fileVersion),e.description&&(this.description=e.description),e.size&&(this.size=e.size),e.pathCollection&&(this.pathCollection=e.pathCollection),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.trashedAt&&(this.trashedAt=e.trashedAt),e.purgedAt&&(this.purgedAt=e.purgedAt),e.contentCreatedAt&&(this.contentCreatedAt=e.contentCreatedAt),e.contentModifiedAt&&(this.contentModifiedAt=e.contentModifiedAt),e.createdBy&&(this.createdBy=e.createdBy),e.modifiedBy&&(this.modifiedBy=e.modifiedBy),e.ownedBy&&(this.ownedBy=e.ownedBy),e.sharedLink&&(this.sharedLink=e.sharedLink),e.parent&&(this.parent=e.parent),e.itemStatus&&(this.itemStatus=e.itemStatus),e.rawData&&(this.rawData=e.rawData)}}},4346:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TrashFolder=void 0,t.serializeTrashFolderTypeField=f,t.deserializeTrashFolderTypeField=m,t.serializeTrashFolderPathCollectionEntriesTypeField=g,t.deserializeTrashFolderPathCollectionEntriesTypeField=y,t.serializeTrashFolderPathCollectionEntriesField=v,t.deserializeTrashFolderPathCollectionEntriesField=b,t.serializeTrashFolderPathCollectionField=w,t.deserializeTrashFolderPathCollectionField=_,t.serializeTrashFolderItemStatusField=x,t.deserializeTrashFolderItemStatusField=S,t.serializeTrashFolder=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:e.type,sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:e.name,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),description:e.description,size:e.size,path_collection:w(e.pathCollection),created_by:(0,i.serializeUserMini)(e.createdBy),modified_by:(0,i.serializeUserMini)(e.modifiedBy),trashed_at:null==e.trashedAt?void 0:(0,a.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,a.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,a.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,a.serializeDateTime)(e.contentModifiedAt),owned_by:(0,i.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,folder_upload_email:null==e.folderUploadEmail?void 0:e.folderUploadEmail,parent:null==e.parent?void 0:(0,o.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFolder=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolder"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "TrashFolder" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashFolder"'});const t=e.id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashFolder"'});const r=null==e.etag?void 0:e.etag;if(null==e.type)throw new d.BoxSdkError({message:'Expecting "type" of type "TrashFolder" to be defined'});const i=m(e.type);if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFolder"'});const o=null==e.sequence_id?void 0:e.sequence_id;if(null==e.name)throw new d.BoxSdkError({message:'Expecting "name" of type "TrashFolder" to be defined'});if(!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashFolder"'});const a=e.name;if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFolder"'});const p=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFolder"'});const f=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null==e.description)throw new d.BoxSdkError({message:'Expecting "description" of type "TrashFolder" to be defined'});if(!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "TrashFolder"'});const g=e.description;if(null==e.size)throw new d.BoxSdkError({message:'Expecting "size" of type "TrashFolder" to be defined'});if(!(0,c.sdIsNumber)(e.size))throw new d.BoxSdkError({message:'Expecting number for "size" of type "TrashFolder"'});const y=e.size;if(null==e.path_collection)throw new d.BoxSdkError({message:'Expecting "path_collection" of type "TrashFolder" to be defined'});const v=_(e.path_collection);if(null==e.created_by)throw new d.BoxSdkError({message:'Expecting "created_by" of type "TrashFolder" to be defined'});const b=(0,n.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new d.BoxSdkError({message:'Expecting "modified_by" of type "TrashFolder" to be defined'});const w=(0,n.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new d.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFolder"'});const x=null==e.trashed_at?void 0:(0,l.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,u.sdIsString)(e.purged_at))throw new d.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFolder"'});const k=null==e.purged_at?void 0:(0,l.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,u.sdIsString)(e.content_created_at))throw new d.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFolder"'});const E=null==e.content_created_at?void 0:(0,l.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,u.sdIsString)(e.content_modified_at))throw new d.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFolder"'});const T=null==e.content_modified_at?void 0:(0,l.deserializeDateTime)(e.content_modified_at);if(null==e.owned_by)throw new d.BoxSdkError({message:'Expecting "owned_by" of type "TrashFolder" to be defined'});const B=(0,n.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,u.sdIsString)(e.shared_link))throw new d.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFolder"'});const C=null==e.shared_link?void 0:e.shared_link;if(null!=e.folder_upload_email&&!(0,u.sdIsString)(e.folder_upload_email))throw new d.BoxSdkError({message:'Expecting string for "folder_upload_email" of type "TrashFolder"'});const I=null==e.folder_upload_email?void 0:e.folder_upload_email,A=null==e.parent?void 0:(0,s.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new d.BoxSdkError({message:'Expecting "item_status" of type "TrashFolder" to be defined'});const F=S(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,createdAt:p,modifiedAt:f,description:g,size:y,pathCollection:v,createdBy:b,modifiedBy:w,trashedAt:x,purgedAt:k,contentCreatedAt:E,contentModifiedAt:T,ownedBy:B,sharedLink:C,folderUploadEmail:I,parent:A,itemStatus:F}},t.serializeTrashFolderInput=function(e){return{id:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type,sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:e.name,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),description:e.description,size:e.size,path_collection:w(e.pathCollection),created_by:(0,i.serializeUserMini)(e.createdBy),modified_by:(0,i.serializeUserMini)(e.modifiedBy),trashed_at:null==e.trashedAt?void 0:(0,a.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,a.serializeDateTime)(e.purgedAt),content_created_at:null==e.contentCreatedAt?void 0:(0,a.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,a.serializeDateTime)(e.contentModifiedAt),owned_by:(0,i.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,folder_upload_email:null==e.folderUploadEmail?void 0:e.folderUploadEmail,parent:null==e.parent?void 0:(0,o.serializeFolderMini)(e.parent),item_status:e.itemStatus}},t.deserializeTrashFolderInput=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolderInput"'});if(null==e.id)throw new d.BoxSdkError({message:'Expecting "id" of type "TrashFolderInput" to be defined'});if(!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashFolderInput"'});const t=e.id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashFolderInput"'});const r=null==e.etag?void 0:e.etag,i=null==e.type?void 0:m(e.type);if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFolderInput"'});const o=null==e.sequence_id?void 0:e.sequence_id;if(null==e.name)throw new d.BoxSdkError({message:'Expecting "name" of type "TrashFolderInput" to be defined'});if(!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashFolderInput"'});const a=e.name;if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFolderInput"'});const p=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFolderInput"'});const f=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null==e.description)throw new d.BoxSdkError({message:'Expecting "description" of type "TrashFolderInput" to be defined'});if(!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "TrashFolderInput"'});const g=e.description;if(null==e.size)throw new d.BoxSdkError({message:'Expecting "size" of type "TrashFolderInput" to be defined'});if(!(0,c.sdIsNumber)(e.size))throw new d.BoxSdkError({message:'Expecting number for "size" of type "TrashFolderInput"'});const y=e.size;if(null==e.path_collection)throw new d.BoxSdkError({message:'Expecting "path_collection" of type "TrashFolderInput" to be defined'});const v=_(e.path_collection);if(null==e.created_by)throw new d.BoxSdkError({message:'Expecting "created_by" of type "TrashFolderInput" to be defined'});const b=(0,n.deserializeUserMini)(e.created_by);if(null==e.modified_by)throw new d.BoxSdkError({message:'Expecting "modified_by" of type "TrashFolderInput" to be defined'});const w=(0,n.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new d.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFolderInput"'});const x=null==e.trashed_at?void 0:(0,l.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,u.sdIsString)(e.purged_at))throw new d.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFolderInput"'});const k=null==e.purged_at?void 0:(0,l.deserializeDateTime)(e.purged_at);if(null!=e.content_created_at&&!(0,u.sdIsString)(e.content_created_at))throw new d.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFolderInput"'});const E=null==e.content_created_at?void 0:(0,l.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,u.sdIsString)(e.content_modified_at))throw new d.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFolderInput"'});const T=null==e.content_modified_at?void 0:(0,l.deserializeDateTime)(e.content_modified_at);if(null==e.owned_by)throw new d.BoxSdkError({message:'Expecting "owned_by" of type "TrashFolderInput" to be defined'});const B=(0,n.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,u.sdIsString)(e.shared_link))throw new d.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFolderInput"'});const C=null==e.shared_link?void 0:e.shared_link;if(null!=e.folder_upload_email&&!(0,u.sdIsString)(e.folder_upload_email))throw new d.BoxSdkError({message:'Expecting string for "folder_upload_email" of type "TrashFolderInput"'});const I=null==e.folder_upload_email?void 0:e.folder_upload_email,A=null==e.parent?void 0:(0,s.deserializeFolderMini)(e.parent);if(null==e.item_status)throw new d.BoxSdkError({message:'Expecting "item_status" of type "TrashFolderInput" to be defined'});const F=S(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,createdAt:p,modifiedAt:f,description:g,size:y,pathCollection:v,createdBy:b,modifiedBy:w,trashedAt:x,purgedAt:k,contentCreatedAt:E,contentModifiedAt:T,ownedBy:B,sharedLink:C,folderUploadEmail:I,parent:A,itemStatus:F}};const i=r(95408),n=r(95408),o=r(70343),s=r(70343),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("folder"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashFolderTypeField"})}function g(e){return e}function y(e){if("folder"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashFolderPathCollectionEntriesTypeField"})}function v(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,sequence_id:null==e.sequenceId?void 0:e.sequenceId,etag:null==e.etag?void 0:e.etag,name:null==e.name?void 0:e.name}}function b(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolderPathCollectionEntriesField"'});const t=null==e.type?void 0:y(e.type);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashFolderPathCollectionEntriesField"'});const r=null==e.id?void 0:e.id;if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFolderPathCollectionEntriesField"'});const i=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashFolderPathCollectionEntriesField"'});const n=null==e.etag?void 0:e.etag;if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashFolderPathCollectionEntriesField"'});return{type:t,id:r,sequenceId:i,etag:n,name:null==e.name?void 0:e.name}}function w(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return v(e)}))}}function _(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolderPathCollectionField"'});if(null==e.total_count)throw new d.BoxSdkError({message:'Expecting "total_count" of type "TrashFolderPathCollectionField" to be defined'});if(!(0,c.sdIsNumber)(e.total_count))throw new d.BoxSdkError({message:'Expecting number for "total_count" of type "TrashFolderPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new d.BoxSdkError({message:'Expecting "entries" of type "TrashFolderPathCollectionField" to be defined'});if(!(0,p.sdIsList)(e.entries))throw new d.BoxSdkError({message:'Expecting array for "entries" of type "TrashFolderPathCollectionField"'});return{totalCount:t,entries:(0,p.sdIsList)(e.entries)?e.entries.map((function(e){return b(e)})):[]}}function x(e){return e}function S(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashFolderItemStatusField"})}t.TrashFolder=class{constructor(e){this.type="folder",e.id&&(this.id=e.id),e.etag&&(this.etag=e.etag),e.type&&(this.type=e.type),e.sequenceId&&(this.sequenceId=e.sequenceId),e.name&&(this.name=e.name),e.createdAt&&(this.createdAt=e.createdAt),e.modifiedAt&&(this.modifiedAt=e.modifiedAt),e.description&&(this.description=e.description),e.size&&(this.size=e.size),e.pathCollection&&(this.pathCollection=e.pathCollection),e.createdBy&&(this.createdBy=e.createdBy),e.modifiedBy&&(this.modifiedBy=e.modifiedBy),e.trashedAt&&(this.trashedAt=e.trashedAt),e.purgedAt&&(this.purgedAt=e.purgedAt),e.contentCreatedAt&&(this.contentCreatedAt=e.contentCreatedAt),e.contentModifiedAt&&(this.contentModifiedAt=e.contentModifiedAt),e.ownedBy&&(this.ownedBy=e.ownedBy),e.sharedLink&&(this.sharedLink=e.sharedLink),e.folderUploadEmail&&(this.folderUploadEmail=e.folderUploadEmail),e.parent&&(this.parent=e.parent),e.itemStatus&&(this.itemStatus=e.itemStatus),e.rawData&&(this.rawData=e.rawData)}}},84064:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTrashFolderRestoredTypeField=f,t.deserializeTrashFolderRestoredTypeField=m,t.serializeTrashFolderRestoredPathCollectionField=g,t.deserializeTrashFolderRestoredPathCollectionField=y,t.serializeTrashFolderRestoredItemStatusField=v,t.deserializeTrashFolderRestoredItemStatusField=b,t.serializeTrashFolderRestored=function(e){return{id:null==e.id?void 0:e.id,etag:null==e.etag?void 0:e.etag,type:null==e.type?void 0:e.type,sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:null==e.name?void 0:e.name,created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),description:null==e.description?void 0:e.description,size:null==e.size?void 0:e.size,path_collection:null==e.pathCollection?void 0:g(e.pathCollection),created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,o.serializeUserMini)(e.modifiedBy),trashed_at:null==e.trashedAt?void 0:e.trashedAt,purged_at:null==e.purgedAt?void 0:e.purgedAt,content_created_at:null==e.contentCreatedAt?void 0:(0,a.serializeDateTime)(e.contentCreatedAt),content_modified_at:null==e.contentModifiedAt?void 0:(0,a.serializeDateTime)(e.contentModifiedAt),owned_by:null==e.ownedBy?void 0:(0,o.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,folder_upload_email:null==e.folderUploadEmail?void 0:e.folderUploadEmail,parent:null==e.parent?void 0:(0,i.serializeFolderMini)(e.parent),item_status:null==e.itemStatus?void 0:e.itemStatus}},t.deserializeTrashFolderRestored=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolderRestored"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashFolderRestored"'});const t=null==e.id?void 0:e.id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashFolderRestored"'});const r=null==e.etag?void 0:e.etag,i=null==e.type?void 0:m(e.type);if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashFolderRestored"'});const o=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashFolderRestored"'});const a=null==e.name?void 0:e.name;if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TrashFolderRestored"'});const p=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashFolderRestored"'});const f=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "TrashFolderRestored"'});const g=null==e.description?void 0:e.description;if(null!=e.size&&!(0,c.sdIsNumber)(e.size))throw new d.BoxSdkError({message:'Expecting number for "size" of type "TrashFolderRestored"'});const v=null==e.size?void 0:e.size,w=null==e.path_collection?void 0:y(e.path_collection),_=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by),x=null==e.modified_by?void 0:(0,s.deserializeUserMini)(e.modified_by);if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new d.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashFolderRestored"'});const S=null==e.trashed_at?void 0:e.trashed_at;if(null!=e.purged_at&&!(0,u.sdIsString)(e.purged_at))throw new d.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashFolderRestored"'});const k=null==e.purged_at?void 0:e.purged_at;if(null!=e.content_created_at&&!(0,u.sdIsString)(e.content_created_at))throw new d.BoxSdkError({message:'Expecting string for "content_created_at" of type "TrashFolderRestored"'});const E=null==e.content_created_at?void 0:(0,l.deserializeDateTime)(e.content_created_at);if(null!=e.content_modified_at&&!(0,u.sdIsString)(e.content_modified_at))throw new d.BoxSdkError({message:'Expecting string for "content_modified_at" of type "TrashFolderRestored"'});const T=null==e.content_modified_at?void 0:(0,l.deserializeDateTime)(e.content_modified_at),B=null==e.owned_by?void 0:(0,s.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,u.sdIsString)(e.shared_link))throw new d.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashFolderRestored"'});const C=null==e.shared_link?void 0:e.shared_link;if(null!=e.folder_upload_email&&!(0,u.sdIsString)(e.folder_upload_email))throw new d.BoxSdkError({message:'Expecting string for "folder_upload_email" of type "TrashFolderRestored"'});const I=null==e.folder_upload_email?void 0:e.folder_upload_email,A=null==e.parent?void 0:(0,n.deserializeFolderMini)(e.parent),F=null==e.item_status?void 0:b(e.item_status);return{id:t,etag:r,type:i,sequenceId:o,name:a,createdAt:p,modifiedAt:f,description:g,size:v,pathCollection:w,createdBy:_,modifiedBy:x,trashedAt:S,purgedAt:k,contentCreatedAt:E,contentModifiedAt:T,ownedBy:B,sharedLink:C,folderUploadEmail:I,parent:A,itemStatus:F}};const i=r(70343),n=r(70343),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("folder"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashFolderRestoredTypeField"})}function g(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,i.serializeFolderMini)(e)}))}}function y(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashFolderRestoredPathCollectionField"'});if(null==e.total_count)throw new d.BoxSdkError({message:'Expecting "total_count" of type "TrashFolderRestoredPathCollectionField" to be defined'});if(!(0,c.sdIsNumber)(e.total_count))throw new d.BoxSdkError({message:'Expecting number for "total_count" of type "TrashFolderRestoredPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new d.BoxSdkError({message:'Expecting "entries" of type "TrashFolderRestoredPathCollectionField" to be defined'});if(!(0,p.sdIsList)(e.entries))throw new d.BoxSdkError({message:'Expecting array for "entries" of type "TrashFolderRestoredPathCollectionField"'});return{totalCount:t,entries:(0,p.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFolderMini)(e)})):[]}}function v(e){return e}function b(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashFolderRestoredItemStatusField"})}},13640:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTrashWebLinkTypeField=f,t.deserializeTrashWebLinkTypeField=m,t.serializeTrashWebLinkPathCollectionEntriesTypeField=g,t.deserializeTrashWebLinkPathCollectionEntriesTypeField=y,t.serializeTrashWebLinkPathCollectionEntriesField=v,t.deserializeTrashWebLinkPathCollectionEntriesField=b,t.serializeTrashWebLinkPathCollectionField=w,t.deserializeTrashWebLinkPathCollectionField=_,t.serializeTrashWebLinkItemStatusField=x,t.deserializeTrashWebLinkItemStatusField=S,t.serializeTrashWebLink=function(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,sequence_id:null==e.sequenceId?void 0:e.sequenceId,etag:null==e.etag?void 0:e.etag,name:null==e.name?void 0:e.name,url:null==e.url?void 0:e.url,parent:null==e.parent?void 0:(0,i.serializeFolderMini)(e.parent),description:null==e.description?void 0:e.description,path_collection:null==e.pathCollection?void 0:w(e.pathCollection),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:(0,a.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,a.serializeDateTime)(e.purgedAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,o.serializeUserMini)(e.modifiedBy),owned_by:null==e.ownedBy?void 0:(0,o.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,item_status:null==e.itemStatus?void 0:e.itemStatus}},t.deserializeTrashWebLink=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashWebLink"'});const t=null==e.type?void 0:m(e.type);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashWebLink"'});const r=null==e.id?void 0:e.id;if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashWebLink"'});const i=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashWebLink"'});const o=null==e.etag?void 0:e.etag;if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashWebLink"'});const a=null==e.name?void 0:e.name;if(null!=e.url&&!(0,u.sdIsString)(e.url))throw new d.BoxSdkError({message:'Expecting string for "url" of type "TrashWebLink"'});const c=null==e.url?void 0:e.url,p=null==e.parent?void 0:(0,n.deserializeFolderMini)(e.parent);if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "TrashWebLink"'});const f=null==e.description?void 0:e.description,g=null==e.path_collection?void 0:_(e.path_collection);if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TrashWebLink"'});const y=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashWebLink"'});const v=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new d.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashWebLink"'});const b=null==e.trashed_at?void 0:(0,l.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,u.sdIsString)(e.purged_at))throw new d.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashWebLink"'});const w=null==e.purged_at?void 0:(0,l.deserializeDateTime)(e.purged_at),x=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by),k=null==e.modified_by?void 0:(0,s.deserializeUserMini)(e.modified_by),E=null==e.owned_by?void 0:(0,s.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,u.sdIsString)(e.shared_link))throw new d.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashWebLink"'});const T=null==e.shared_link?void 0:e.shared_link,B=null==e.item_status?void 0:S(e.item_status);return{type:t,id:r,sequenceId:i,etag:o,name:a,url:c,parent:p,description:f,pathCollection:g,createdAt:y,modifiedAt:v,trashedAt:b,purgedAt:w,createdBy:x,modifiedBy:k,ownedBy:E,sharedLink:T,itemStatus:B}};const i=r(70343),n=r(70343),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("web_link"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashWebLinkTypeField"})}function g(e){return e}function y(e){if("folder"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashWebLinkPathCollectionEntriesTypeField"})}function v(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,sequence_id:null==e.sequenceId?void 0:e.sequenceId,etag:null==e.etag?void 0:e.etag,name:null==e.name?void 0:e.name}}function b(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashWebLinkPathCollectionEntriesField"'});const t=null==e.type?void 0:y(e.type);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashWebLinkPathCollectionEntriesField"'});const r=null==e.id?void 0:e.id;if(null!=e.sequence_id&&!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashWebLinkPathCollectionEntriesField"'});const i=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashWebLinkPathCollectionEntriesField"'});const n=null==e.etag?void 0:e.etag;if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashWebLinkPathCollectionEntriesField"'});return{type:t,id:r,sequenceId:i,etag:n,name:null==e.name?void 0:e.name}}function w(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return v(e)}))}}function _(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashWebLinkPathCollectionField"'});if(null==e.total_count)throw new d.BoxSdkError({message:'Expecting "total_count" of type "TrashWebLinkPathCollectionField" to be defined'});if(!(0,c.sdIsNumber)(e.total_count))throw new d.BoxSdkError({message:'Expecting number for "total_count" of type "TrashWebLinkPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new d.BoxSdkError({message:'Expecting "entries" of type "TrashWebLinkPathCollectionField" to be defined'});if(!(0,p.sdIsList)(e.entries))throw new d.BoxSdkError({message:'Expecting array for "entries" of type "TrashWebLinkPathCollectionField"'});return{totalCount:t,entries:(0,p.sdIsList)(e.entries)?e.entries.map((function(e){return b(e)})):[]}}function x(e){return e}function S(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashWebLinkItemStatusField"})}},49238:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeTrashWebLinkRestoredTypeField=f,t.deserializeTrashWebLinkRestoredTypeField=m,t.serializeTrashWebLinkRestoredPathCollectionField=g,t.deserializeTrashWebLinkRestoredPathCollectionField=y,t.serializeTrashWebLinkRestoredItemStatusField=v,t.deserializeTrashWebLinkRestoredItemStatusField=b,t.serializeTrashWebLinkRestored=function(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id,sequence_id:e.sequenceId,etag:null==e.etag?void 0:e.etag,name:null==e.name?void 0:e.name,url:null==e.url?void 0:e.url,parent:null==e.parent?void 0:(0,i.serializeFolderMini)(e.parent),description:null==e.description?void 0:e.description,path_collection:g(e.pathCollection),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,a.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:e.trashedAt,purged_at:null==e.purgedAt?void 0:e.purgedAt,created_by:null==e.createdBy?void 0:(0,o.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,o.serializeUserMini)(e.modifiedBy),owned_by:null==e.ownedBy?void 0:(0,o.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:e.sharedLink,item_status:null==e.itemStatus?void 0:e.itemStatus}},t.deserializeTrashWebLinkRestored=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashWebLinkRestored"'});const t=null==e.type?void 0:m(e.type);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "TrashWebLinkRestored"'});const r=null==e.id?void 0:e.id;if(null==e.sequence_id)throw new d.BoxSdkError({message:'Expecting "sequence_id" of type "TrashWebLinkRestored" to be defined'});if(!(0,u.sdIsString)(e.sequence_id))throw new d.BoxSdkError({message:'Expecting string for "sequence_id" of type "TrashWebLinkRestored"'});const i=e.sequence_id;if(null!=e.etag&&!(0,u.sdIsString)(e.etag))throw new d.BoxSdkError({message:'Expecting string for "etag" of type "TrashWebLinkRestored"'});const o=null==e.etag?void 0:e.etag;if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "TrashWebLinkRestored"'});const a=null==e.name?void 0:e.name;if(null!=e.url&&!(0,u.sdIsString)(e.url))throw new d.BoxSdkError({message:'Expecting string for "url" of type "TrashWebLinkRestored"'});const c=null==e.url?void 0:e.url,p=null==e.parent?void 0:(0,n.deserializeFolderMini)(e.parent);if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "TrashWebLinkRestored"'});const f=null==e.description?void 0:e.description;if(null==e.path_collection)throw new d.BoxSdkError({message:'Expecting "path_collection" of type "TrashWebLinkRestored" to be defined'});const g=y(e.path_collection);if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "TrashWebLinkRestored"'});const v=null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new d.BoxSdkError({message:'Expecting string for "modified_at" of type "TrashWebLinkRestored"'});const w=null==e.modified_at?void 0:(0,l.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,u.sdIsString)(e.trashed_at))throw new d.BoxSdkError({message:'Expecting string for "trashed_at" of type "TrashWebLinkRestored"'});const _=null==e.trashed_at?void 0:e.trashed_at;if(null!=e.purged_at&&!(0,u.sdIsString)(e.purged_at))throw new d.BoxSdkError({message:'Expecting string for "purged_at" of type "TrashWebLinkRestored"'});const x=null==e.purged_at?void 0:e.purged_at,S=null==e.created_by?void 0:(0,s.deserializeUserMini)(e.created_by),k=null==e.modified_by?void 0:(0,s.deserializeUserMini)(e.modified_by),E=null==e.owned_by?void 0:(0,s.deserializeUserMini)(e.owned_by);if(null!=e.shared_link&&!(0,u.sdIsString)(e.shared_link))throw new d.BoxSdkError({message:'Expecting string for "shared_link" of type "TrashWebLinkRestored"'});const T=null==e.shared_link?void 0:e.shared_link,B=null==e.item_status?void 0:b(e.item_status);return{type:t,id:r,sequenceId:i,etag:o,name:a,url:c,parent:p,description:f,pathCollection:g,createdAt:v,modifiedAt:w,trashedAt:_,purgedAt:x,createdBy:S,modifiedBy:k,ownedBy:E,sharedLink:T,itemStatus:B}};const i=r(70343),n=r(70343),o=r(95408),s=r(95408),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("web_link"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashWebLinkRestoredTypeField"})}function g(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,i.serializeFolderMini)(e)}))}}function y(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "TrashWebLinkRestoredPathCollectionField"'});if(null==e.total_count)throw new d.BoxSdkError({message:'Expecting "total_count" of type "TrashWebLinkRestoredPathCollectionField" to be defined'});if(!(0,c.sdIsNumber)(e.total_count))throw new d.BoxSdkError({message:'Expecting number for "total_count" of type "TrashWebLinkRestoredPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new d.BoxSdkError({message:'Expecting "entries" of type "TrashWebLinkRestoredPathCollectionField" to be defined'});if(!(0,p.sdIsList)(e.entries))throw new d.BoxSdkError({message:'Expecting array for "entries" of type "TrashWebLinkRestoredPathCollectionField"'});return{totalCount:t,entries:(0,p.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeFolderMini)(e)})):[]}}function v(e){return e}function b(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize TrashWebLinkRestoredItemStatusField"})}},3868:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadPart=function(e){const t=(0,i.serializeUploadPartMini)(e);if(!(0,a.sdIsMap)(t))throw new n.BoxSdkError({message:'Expecting a map for "UploadPart"'});return Object.assign(Object.assign({},t),{sha1:null==e.sha1?void 0:e.sha1})},t.deserializeUploadPart=function(e){if(!(0,a.sdIsMap)(e))throw new n.BoxSdkError({message:'Expecting a map for "UploadPart"'});if(null!=e.sha1&&!(0,s.sdIsString)(e.sha1))throw new n.BoxSdkError({message:'Expecting string for "sha1" of type "UploadPart"'});const t=null==e.sha1?void 0:e.sha1;if(null!=e.part_id&&!(0,s.sdIsString)(e.part_id))throw new n.BoxSdkError({message:'Expecting string for "part_id" of type "UploadPart"'});const r=null==e.part_id?void 0:e.part_id;if(null!=e.offset&&!(0,o.sdIsNumber)(e.offset))throw new n.BoxSdkError({message:'Expecting number for "offset" of type "UploadPart"'});const i=null==e.offset?void 0:e.offset;if(null!=e.size&&!(0,o.sdIsNumber)(e.size))throw new n.BoxSdkError({message:'Expecting number for "size" of type "UploadPart"'});const l=null==e.size?void 0:e.size;return{sha1:t,partId:r,offset:i,size:l}};const i=r(81891),n=r(72631),o=r(50793),s=r(50793),a=r(50793)},81891:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadPartMini=function(e){return{part_id:null==e.partId?void 0:e.partId,offset:null==e.offset?void 0:e.offset,size:null==e.size?void 0:e.size}},t.deserializeUploadPartMini=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UploadPartMini"'});if(null!=e.part_id&&!(0,o.sdIsString)(e.part_id))throw new i.BoxSdkError({message:'Expecting string for "part_id" of type "UploadPartMini"'});const t=null==e.part_id?void 0:e.part_id;if(null!=e.offset&&!(0,n.sdIsNumber)(e.offset))throw new i.BoxSdkError({message:'Expecting number for "offset" of type "UploadPartMini"'});const r=null==e.offset?void 0:e.offset;if(null!=e.size&&!(0,n.sdIsNumber)(e.size))throw new i.BoxSdkError({message:'Expecting number for "size" of type "UploadPartMini"'});const a=null==e.size?void 0:e.size;return{partId:t,offset:r,size:a}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793)},2001:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadPartsOrderDirectionField=c,t.deserializeUploadPartsOrderDirectionField=u,t.serializeUploadPartsOrderField=p,t.deserializeUploadPartsOrderField=h,t.serializeUploadParts=function(e){return{total_count:null==e.totalCount?void 0:e.totalCount,limit:null==e.limit?void 0:e.limit,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeUploadPart)(e)}))}},t.deserializeUploadParts=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UploadParts"'});if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "UploadParts"'});const t=null==e.total_count?void 0:e.total_count;if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "UploadParts"'});const r=null==e.limit?void 0:e.limit;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "UploadParts"'});const i=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "UploadParts"'});const a=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "UploadParts"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeUploadPart)(e)})):[];return{totalCount:t,limit:r,offset:i,order:a,entries:c}};const i=r(3868),n=r(3868),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize UploadPartsOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UploadPartsOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "UploadPartsOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},26391:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadSessionTypeField=d,t.deserializeUploadSessionTypeField=c,t.serializeUploadSessionSessionEndpointsField=u,t.deserializeUploadSessionSessionEndpointsField=p,t.serializeUploadSession=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,session_expires_at:null==e.sessionExpiresAt?void 0:(0,i.serializeDateTime)(e.sessionExpiresAt),part_size:null==e.partSize?void 0:e.partSize,total_parts:null==e.totalParts?void 0:e.totalParts,num_parts_processed:null==e.numPartsProcessed?void 0:e.numPartsProcessed,session_endpoints:null==e.sessionEndpoints?void 0:u(e.sessionEndpoints)}},t.deserializeUploadSession=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UploadSession"'});if(null!=e.id&&!(0,a.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "UploadSession"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:c(e.type);if(null!=e.session_expires_at&&!(0,a.sdIsString)(e.session_expires_at))throw new o.BoxSdkError({message:'Expecting string for "session_expires_at" of type "UploadSession"'});const i=null==e.session_expires_at?void 0:(0,n.deserializeDateTime)(e.session_expires_at);if(null!=e.part_size&&!(0,s.sdIsNumber)(e.part_size))throw new o.BoxSdkError({message:'Expecting number for "part_size" of type "UploadSession"'});const d=null==e.part_size?void 0:e.part_size;if(null!=e.total_parts&&!(0,s.sdIsNumber)(e.total_parts))throw new o.BoxSdkError({message:'Expecting number for "total_parts" of type "UploadSession"'});const u=null==e.total_parts?void 0:e.total_parts;if(null!=e.num_parts_processed&&!(0,s.sdIsNumber)(e.num_parts_processed))throw new o.BoxSdkError({message:'Expecting number for "num_parts_processed" of type "UploadSession"'});const h=null==e.num_parts_processed?void 0:e.num_parts_processed,f=null==e.session_endpoints?void 0:p(e.session_endpoints);return{id:t,type:r,sessionExpiresAt:i,partSize:d,totalParts:u,numPartsProcessed:h,sessionEndpoints:f}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("upload_session"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize UploadSessionTypeField"})}function u(e){return{upload_part:null==e.uploadPart?void 0:e.uploadPart,commit:null==e.commit?void 0:e.commit,abort:null==e.abort?void 0:e.abort,list_parts:null==e.listParts?void 0:e.listParts,status:null==e.status?void 0:e.status,log_event:null==e.logEvent?void 0:e.logEvent}}function p(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UploadSessionSessionEndpointsField"'});if(null!=e.upload_part&&!(0,a.sdIsString)(e.upload_part))throw new o.BoxSdkError({message:'Expecting string for "upload_part" of type "UploadSessionSessionEndpointsField"'});const t=null==e.upload_part?void 0:e.upload_part;if(null!=e.commit&&!(0,a.sdIsString)(e.commit))throw new o.BoxSdkError({message:'Expecting string for "commit" of type "UploadSessionSessionEndpointsField"'});const r=null==e.commit?void 0:e.commit;if(null!=e.abort&&!(0,a.sdIsString)(e.abort))throw new o.BoxSdkError({message:'Expecting string for "abort" of type "UploadSessionSessionEndpointsField"'});const i=null==e.abort?void 0:e.abort;if(null!=e.list_parts&&!(0,a.sdIsString)(e.list_parts))throw new o.BoxSdkError({message:'Expecting string for "list_parts" of type "UploadSessionSessionEndpointsField"'});const n=null==e.list_parts?void 0:e.list_parts;if(null!=e.status&&!(0,a.sdIsString)(e.status))throw new o.BoxSdkError({message:'Expecting string for "status" of type "UploadSessionSessionEndpointsField"'});const s=null==e.status?void 0:e.status;if(null!=e.log_event&&!(0,a.sdIsString)(e.log_event))throw new o.BoxSdkError({message:'Expecting string for "log_event" of type "UploadSessionSessionEndpointsField"'});return{uploadPart:t,commit:r,abort:i,listParts:n,status:s,logEvent:null==e.log_event?void 0:e.log_event}}},2090:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadUrl=function(e){return{upload_url:null==e.uploadUrl?void 0:e.uploadUrl,upload_token:null==e.uploadToken?void 0:e.uploadToken}},t.deserializeUploadUrl=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UploadUrl"'});if(null!=e.upload_url&&!(0,n.sdIsString)(e.upload_url))throw new i.BoxSdkError({message:'Expecting string for "upload_url" of type "UploadUrl"'});const t=null==e.upload_url?void 0:e.upload_url;if(null!=e.upload_token&&!(0,n.sdIsString)(e.upload_token))throw new i.BoxSdkError({message:'Expecting string for "upload_token" of type "UploadUrl"'});const r=null==e.upload_token?void 0:e.upload_token;return{uploadUrl:t,uploadToken:r}};const i=r(72631),n=r(50793),o=r(50793)},31621:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUploadedPart=function(e){return{part:null==e.part?void 0:(0,i.serializeUploadPart)(e.part)}},t.deserializeUploadedPart=function(e){if(!(0,s.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UploadedPart"'});return{part:null==e.part?void 0:(0,n.deserializeUploadPart)(e.part)}};const i=r(3868),n=r(3868),o=r(72631),s=r(50793)},1543:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.User=void 0,t.serializeUserStatusField=f,t.deserializeUserStatusField=m,t.serializeUserNotificationEmailField=g,t.deserializeUserNotificationEmailField=y,t.serializeUser=function(e){const t=(0,n.serializeUserMini)(e);if(!(0,p.sdIsMap)(t))throw new l.BoxSdkError({message:'Expecting a map for "User"'});return Object.assign(Object.assign({},t),{created_at:null==e.createdAt?void 0:(0,o.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,o.serializeDateTime)(e.modifiedAt),language:null==e.language?void 0:e.language,timezone:null==e.timezone?void 0:e.timezone,space_amount:null==e.spaceAmount?void 0:e.spaceAmount,space_used:null==e.spaceUsed?void 0:e.spaceUsed,max_upload_size:null==e.maxUploadSize?void 0:e.maxUploadSize,status:null==e.status?void 0:e.status,job_title:null==e.jobTitle?void 0:e.jobTitle,phone:null==e.phone?void 0:e.phone,address:null==e.address?void 0:e.address,avatar_url:null==e.avatarUrl?void 0:e.avatarUrl,notification_email:null==e.notificationEmail?void 0:g(e.notificationEmail)})},t.deserializeUser=function(e){if(!(0,p.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "User"'});if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new l.BoxSdkError({message:'Expecting string for "created_at" of type "User"'});const t=null==e.created_at?void 0:(0,s.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,u.sdIsString)(e.modified_at))throw new l.BoxSdkError({message:'Expecting string for "modified_at" of type "User"'});const r=null==e.modified_at?void 0:(0,s.deserializeDateTime)(e.modified_at);if(null!=e.language&&!(0,u.sdIsString)(e.language))throw new l.BoxSdkError({message:'Expecting string for "language" of type "User"'});const n=null==e.language?void 0:e.language;if(null!=e.timezone&&!(0,u.sdIsString)(e.timezone))throw new l.BoxSdkError({message:'Expecting string for "timezone" of type "User"'});const o=null==e.timezone?void 0:e.timezone;if(null!=e.space_amount&&!(0,c.sdIsNumber)(e.space_amount))throw new l.BoxSdkError({message:'Expecting number for "space_amount" of type "User"'});const a=null==e.space_amount?void 0:e.space_amount;if(null!=e.space_used&&!(0,c.sdIsNumber)(e.space_used))throw new l.BoxSdkError({message:'Expecting number for "space_used" of type "User"'});const d=null==e.space_used?void 0:e.space_used;if(null!=e.max_upload_size&&!(0,c.sdIsNumber)(e.max_upload_size))throw new l.BoxSdkError({message:'Expecting number for "max_upload_size" of type "User"'});const h=null==e.max_upload_size?void 0:e.max_upload_size,f=null==e.status?void 0:m(e.status);if(null!=e.job_title&&!(0,u.sdIsString)(e.job_title))throw new l.BoxSdkError({message:'Expecting string for "job_title" of type "User"'});const g=null==e.job_title?void 0:e.job_title;if(null!=e.phone&&!(0,u.sdIsString)(e.phone))throw new l.BoxSdkError({message:'Expecting string for "phone" of type "User"'});const v=null==e.phone?void 0:e.phone;if(null!=e.address&&!(0,u.sdIsString)(e.address))throw new l.BoxSdkError({message:'Expecting string for "address" of type "User"'});const b=null==e.address?void 0:e.address;if(null!=e.avatar_url&&!(0,u.sdIsString)(e.avatar_url))throw new l.BoxSdkError({message:'Expecting string for "avatar_url" of type "User"'});const w=null==e.avatar_url?void 0:e.avatar_url,_=null==e.notification_email?void 0:y(e.notification_email);if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new l.BoxSdkError({message:'Expecting string for "name" of type "User"'});const x=null==e.name?void 0:e.name;if(null!=e.login&&!(0,u.sdIsString)(e.login))throw new l.BoxSdkError({message:'Expecting string for "login" of type "User"'});const S=null==e.login?void 0:e.login;if(null==e.id)throw new l.BoxSdkError({message:'Expecting "id" of type "User" to be defined'});if(!(0,u.sdIsString)(e.id))throw new l.BoxSdkError({message:'Expecting string for "id" of type "User"'});const k=e.id;if(null==e.type)throw new l.BoxSdkError({message:'Expecting "type" of type "User" to be defined'});const E=(0,i.deserializeUserBaseTypeField)(e.type);return{createdAt:t,modifiedAt:r,language:n,timezone:o,spaceAmount:a,spaceUsed:d,maxUploadSize:h,status:f,jobTitle:g,phone:v,address:b,avatarUrl:w,notificationEmail:_,name:x,login:S,id:k,type:E}};const i=r(78366),n=r(95408),o=r(93845),s=r(93845),a=r(95408),l=r(72631),d=r(50793),c=r(50793),u=r(50793),p=r(50793);class h extends a.UserMini{constructor(e){super(e)}}function f(e){return e}function m(e){if("active"==e)return e;if("inactive"==e)return e;if("cannot_delete_edit"==e)return e;if("cannot_delete_edit_upload"==e)return e;throw new l.BoxSdkError({message:"Can't deserialize UserStatusField"})}function g(e){return{email:null==e.email?void 0:e.email,is_confirmed:null==e.isConfirmed?void 0:e.isConfirmed}}function y(e){if(!(0,p.sdIsMap)(e))throw new l.BoxSdkError({message:'Expecting a map for "UserNotificationEmailField"'});if(null!=e.email&&!(0,u.sdIsString)(e.email))throw new l.BoxSdkError({message:'Expecting string for "email" of type "UserNotificationEmailField"'});const t=null==e.email?void 0:e.email;if(null!=e.is_confirmed&&!(0,d.sdIsBoolean)(e.is_confirmed))throw new l.BoxSdkError({message:'Expecting boolean for "is_confirmed" of type "UserNotificationEmailField"'});return{email:t,isConfirmed:null==e.is_confirmed?void 0:e.is_confirmed}}t.User=h},59730:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUserAvatarPicUrlsField=s,t.deserializeUserAvatarPicUrlsField=a,t.serializeUserAvatar=function(e){return{pic_urls:null==e.picUrls?void 0:s(e.picUrls)}},t.deserializeUserAvatar=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UserAvatar"'});return{picUrls:null==e.pic_urls?void 0:a(e.pic_urls)}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return{small:null==e.small?void 0:e.small,large:null==e.large?void 0:e.large,preview:null==e.preview?void 0:e.preview}}function a(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UserAvatarPicUrlsField"'});if(null!=e.small&&!(0,n.sdIsString)(e.small))throw new i.BoxSdkError({message:'Expecting string for "small" of type "UserAvatarPicUrlsField"'});const t=null==e.small?void 0:e.small;if(null!=e.large&&!(0,n.sdIsString)(e.large))throw new i.BoxSdkError({message:'Expecting string for "large" of type "UserAvatarPicUrlsField"'});const r=null==e.large?void 0:e.large;if(null!=e.preview&&!(0,n.sdIsString)(e.preview))throw new i.BoxSdkError({message:'Expecting string for "preview" of type "UserAvatarPicUrlsField"'});return{small:t,large:r,preview:null==e.preview?void 0:e.preview}}},78366:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UserBase=void 0,t.serializeUserBaseTypeField=s,t.deserializeUserBaseTypeField=a,t.serializeUserBase=function(e){return{id:e.id,type:e.type}},t.deserializeUserBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UserBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "UserBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "UserBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "UserBase" to be defined'});const r=a(e.type);return{id:t,type:r}},t.serializeUserBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type}},t.deserializeUserBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "UserBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "UserBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "UserBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);return{id:t,type:r}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("user"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize UserBaseTypeField"})}t.UserBase=class{constructor(e){this.type="user",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.rawData&&(this.rawData=e.rawData)}}},21517:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UserCollaborations=void 0,t.serializeUserCollaborations=function(e){const t=(0,n.serializeUserBase)(e);if(!(0,d.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "UserCollaborations"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name,login:null==e.login?void 0:e.login,is_active:null==e.isActive?void 0:e.isActive})},t.deserializeUserCollaborations=function(e){if(!(0,d.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "UserCollaborations"'});if(null!=e.name&&!(0,l.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "UserCollaborations"'});const t=null==e.name?void 0:e.name;if(null!=e.login&&!(0,l.sdIsString)(e.login))throw new s.BoxSdkError({message:'Expecting string for "login" of type "UserCollaborations"'});const r=null==e.login?void 0:e.login;if(null!=e.is_active&&!(0,a.sdIsBoolean)(e.is_active))throw new s.BoxSdkError({message:'Expecting boolean for "is_active" of type "UserCollaborations"'});const n=null==e.is_active?void 0:e.is_active;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "UserCollaborations" to be defined'});if(!(0,l.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "UserCollaborations"'});const o=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "UserCollaborations" to be defined'});const c=(0,i.deserializeUserBaseTypeField)(e.type);return{name:t,login:r,isActive:n,id:o,type:c}};const i=r(78366),n=r(78366),o=r(78366),s=r(72631),a=r(50793),l=r(50793),d=r(50793);class c extends o.UserBase{constructor(e){super(e)}}t.UserCollaborations=c},88510:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UserFull=void 0,t.serializeUserFullRoleField=v,t.deserializeUserFullRoleField=b,t.serializeUserFullEnterpriseTypeField=w,t.deserializeUserFullEnterpriseTypeField=_,t.serializeUserFullEnterpriseField=x,t.deserializeUserFullEnterpriseField=S,t.serializeUserFull=function(e){const t=(0,a.serializeUser)(e);if(!(0,g.sdIsMap)(t))throw new u.BoxSdkError({message:'Expecting a map for "UserFull"'});return Object.assign(Object.assign({},t),{role:null==e.role?void 0:e.role,tracking_codes:null==e.trackingCodes?void 0:e.trackingCodes.map((function(e){return(0,l.serializeTrackingCode)(e)})),can_see_managed_users:null==e.canSeeManagedUsers?void 0:e.canSeeManagedUsers,is_sync_enabled:null==e.isSyncEnabled?void 0:e.isSyncEnabled,is_external_collab_restricted:null==e.isExternalCollabRestricted?void 0:e.isExternalCollabRestricted,is_exempt_from_device_limits:null==e.isExemptFromDeviceLimits?void 0:e.isExemptFromDeviceLimits,is_exempt_from_login_verification:null==e.isExemptFromLoginVerification?void 0:e.isExemptFromLoginVerification,enterprise:null==e.enterprise?void 0:x(e.enterprise),my_tags:null==e.myTags?void 0:e.myTags.map((function(e){return e})),hostname:null==e.hostname?void 0:e.hostname,is_platform_access_only:null==e.isPlatformAccessOnly?void 0:e.isPlatformAccessOnly,external_app_user_id:null==e.externalAppUserId?void 0:e.externalAppUserId})},t.deserializeUserFull=function(e){if(!(0,g.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UserFull"'});const t=null==e.role?void 0:b(e.role);if(null!=e.tracking_codes&&!(0,m.sdIsList)(e.tracking_codes))throw new u.BoxSdkError({message:'Expecting array for "tracking_codes" of type "UserFull"'});const r=null==e.tracking_codes?void 0:(0,m.sdIsList)(e.tracking_codes)?e.tracking_codes.map((function(e){return(0,d.deserializeTrackingCode)(e)})):[];if(null!=e.can_see_managed_users&&!(0,p.sdIsBoolean)(e.can_see_managed_users))throw new u.BoxSdkError({message:'Expecting boolean for "can_see_managed_users" of type "UserFull"'});const a=null==e.can_see_managed_users?void 0:e.can_see_managed_users;if(null!=e.is_sync_enabled&&!(0,p.sdIsBoolean)(e.is_sync_enabled))throw new u.BoxSdkError({message:'Expecting boolean for "is_sync_enabled" of type "UserFull"'});const l=null==e.is_sync_enabled?void 0:e.is_sync_enabled;if(null!=e.is_external_collab_restricted&&!(0,p.sdIsBoolean)(e.is_external_collab_restricted))throw new u.BoxSdkError({message:'Expecting boolean for "is_external_collab_restricted" of type "UserFull"'});const c=null==e.is_external_collab_restricted?void 0:e.is_external_collab_restricted;if(null!=e.is_exempt_from_device_limits&&!(0,p.sdIsBoolean)(e.is_exempt_from_device_limits))throw new u.BoxSdkError({message:'Expecting boolean for "is_exempt_from_device_limits" of type "UserFull"'});const y=null==e.is_exempt_from_device_limits?void 0:e.is_exempt_from_device_limits;if(null!=e.is_exempt_from_login_verification&&!(0,p.sdIsBoolean)(e.is_exempt_from_login_verification))throw new u.BoxSdkError({message:'Expecting boolean for "is_exempt_from_login_verification" of type "UserFull"'});const v=null==e.is_exempt_from_login_verification?void 0:e.is_exempt_from_login_verification,w=null==e.enterprise?void 0:S(e.enterprise);if(null!=e.my_tags&&!(0,m.sdIsList)(e.my_tags))throw new u.BoxSdkError({message:'Expecting array for "my_tags" of type "UserFull"'});const _=null==e.my_tags?void 0:(0,m.sdIsList)(e.my_tags)?e.my_tags.map((function(e){if(!(0,f.sdIsString)(e))throw new u.BoxSdkError({message:'Expecting string for "UserFull"'});return e})):[];if(null!=e.hostname&&!(0,f.sdIsString)(e.hostname))throw new u.BoxSdkError({message:'Expecting string for "hostname" of type "UserFull"'});const x=null==e.hostname?void 0:e.hostname;if(null!=e.is_platform_access_only&&!(0,p.sdIsBoolean)(e.is_platform_access_only))throw new u.BoxSdkError({message:'Expecting boolean for "is_platform_access_only" of type "UserFull"'});const k=null==e.is_platform_access_only?void 0:e.is_platform_access_only;if(null!=e.external_app_user_id&&!(0,f.sdIsString)(e.external_app_user_id))throw new u.BoxSdkError({message:'Expecting string for "external_app_user_id" of type "UserFull"'});const E=null==e.external_app_user_id?void 0:e.external_app_user_id;if(null!=e.created_at&&!(0,f.sdIsString)(e.created_at))throw new u.BoxSdkError({message:'Expecting string for "created_at" of type "UserFull"'});const T=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,f.sdIsString)(e.modified_at))throw new u.BoxSdkError({message:'Expecting string for "modified_at" of type "UserFull"'});const B=null==e.modified_at?void 0:(0,n.deserializeDateTime)(e.modified_at);if(null!=e.language&&!(0,f.sdIsString)(e.language))throw new u.BoxSdkError({message:'Expecting string for "language" of type "UserFull"'});const C=null==e.language?void 0:e.language;if(null!=e.timezone&&!(0,f.sdIsString)(e.timezone))throw new u.BoxSdkError({message:'Expecting string for "timezone" of type "UserFull"'});const I=null==e.timezone?void 0:e.timezone;if(null!=e.space_amount&&!(0,h.sdIsNumber)(e.space_amount))throw new u.BoxSdkError({message:'Expecting number for "space_amount" of type "UserFull"'});const A=null==e.space_amount?void 0:e.space_amount;if(null!=e.space_used&&!(0,h.sdIsNumber)(e.space_used))throw new u.BoxSdkError({message:'Expecting number for "space_used" of type "UserFull"'});const F=null==e.space_used?void 0:e.space_used;if(null!=e.max_upload_size&&!(0,h.sdIsNumber)(e.max_upload_size))throw new u.BoxSdkError({message:'Expecting number for "max_upload_size" of type "UserFull"'});const M=null==e.max_upload_size?void 0:e.max_upload_size,D=null==e.status?void 0:(0,o.deserializeUserStatusField)(e.status);if(null!=e.job_title&&!(0,f.sdIsString)(e.job_title))throw new u.BoxSdkError({message:'Expecting string for "job_title" of type "UserFull"'});const R=null==e.job_title?void 0:e.job_title;if(null!=e.phone&&!(0,f.sdIsString)(e.phone))throw new u.BoxSdkError({message:'Expecting string for "phone" of type "UserFull"'});const P=null==e.phone?void 0:e.phone;if(null!=e.address&&!(0,f.sdIsString)(e.address))throw new u.BoxSdkError({message:'Expecting string for "address" of type "UserFull"'});const O=null==e.address?void 0:e.address;if(null!=e.avatar_url&&!(0,f.sdIsString)(e.avatar_url))throw new u.BoxSdkError({message:'Expecting string for "avatar_url" of type "UserFull"'});const z=null==e.avatar_url?void 0:e.avatar_url,N=null==e.notification_email?void 0:(0,s.deserializeUserNotificationEmailField)(e.notification_email);if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "UserFull"'});const q=null==e.name?void 0:e.name;if(null!=e.login&&!(0,f.sdIsString)(e.login))throw new u.BoxSdkError({message:'Expecting string for "login" of type "UserFull"'});const U=null==e.login?void 0:e.login;if(null==e.id)throw new u.BoxSdkError({message:'Expecting "id" of type "UserFull" to be defined'});if(!(0,f.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UserFull"'});const L=e.id;if(null==e.type)throw new u.BoxSdkError({message:'Expecting "type" of type "UserFull" to be defined'});const j=(0,i.deserializeUserBaseTypeField)(e.type);return{role:t,trackingCodes:r,canSeeManagedUsers:a,isSyncEnabled:l,isExternalCollabRestricted:c,isExemptFromDeviceLimits:y,isExemptFromLoginVerification:v,enterprise:w,myTags:_,hostname:x,isPlatformAccessOnly:k,externalAppUserId:E,createdAt:T,modifiedAt:B,language:C,timezone:I,spaceAmount:A,spaceUsed:F,maxUploadSize:M,status:D,jobTitle:R,phone:P,address:O,avatarUrl:z,notificationEmail:N,name:q,login:U,id:L,type:j}};const i=r(78366),n=r(93845),o=r(1543),s=r(1543),a=r(1543),l=r(55852),d=r(55852),c=r(1543),u=r(72631),p=r(50793),h=r(50793),f=r(50793),m=r(50793),g=r(50793);class y extends c.User{constructor(e){super(e)}}function v(e){return e}function b(e){if("admin"==e)return e;if("coadmin"==e)return e;if("user"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UserFullRoleField"})}function w(e){return e}function _(e){if("enterprise"==e)return e;throw new u.BoxSdkError({message:"Can't deserialize UserFullEnterpriseTypeField"})}function x(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name}}function S(e){if(!(0,g.sdIsMap)(e))throw new u.BoxSdkError({message:'Expecting a map for "UserFullEnterpriseField"'});if(null!=e.id&&!(0,f.sdIsString)(e.id))throw new u.BoxSdkError({message:'Expecting string for "id" of type "UserFullEnterpriseField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:_(e.type);if(null!=e.name&&!(0,f.sdIsString)(e.name))throw new u.BoxSdkError({message:'Expecting string for "name" of type "UserFullEnterpriseField"'});return{id:t,type:r,name:null==e.name?void 0:e.name}}t.UserFull=y},80632:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UserIntegrationMappings=void 0,t.serializeUserIntegrationMappings=function(e){const t=(0,n.serializeUserBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "UserIntegrationMappings"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name,login:null==e.login?void 0:e.login})},t.deserializeUserIntegrationMappings=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "UserIntegrationMappings"'});if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "UserIntegrationMappings"'});const t=null==e.name?void 0:e.name;if(null!=e.login&&!(0,a.sdIsString)(e.login))throw new s.BoxSdkError({message:'Expecting string for "login" of type "UserIntegrationMappings"'});const r=null==e.login?void 0:e.login;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "UserIntegrationMappings" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "UserIntegrationMappings"'});const n=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "UserIntegrationMappings" to be defined'});const o=(0,i.deserializeUserBaseTypeField)(e.type);return{name:t,login:r,id:n,type:o}};const i=r(78366),n=r(78366),o=r(78366),s=r(72631),a=r(50793),l=r(50793);class d extends o.UserBase{constructor(e){super(e)}}t.UserIntegrationMappings=d},95408:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UserMini=void 0,t.serializeUserMini=function(e){const t=(0,n.serializeUserBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "UserMini"'});return Object.assign(Object.assign({},t),{name:null==e.name?void 0:e.name,login:null==e.login?void 0:e.login})},t.deserializeUserMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "UserMini"'});if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "UserMini"'});const t=null==e.name?void 0:e.name;if(null!=e.login&&!(0,a.sdIsString)(e.login))throw new s.BoxSdkError({message:'Expecting string for "login" of type "UserMini"'});const r=null==e.login?void 0:e.login;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "UserMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "UserMini"'});const n=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "UserMini" to be defined'});const o=(0,i.deserializeUserBaseTypeField)(e.type);return{name:t,login:r,id:n,type:o}};const i=r(78366),n=r(78366),o=r(78366),s=r(72631),a=r(50793),l=r(50793);class d extends o.UserBase{constructor(e){super(e)}}t.UserMini=d},57076:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeUsersOrderDirectionField=c,t.deserializeUsersOrderDirectionField=u,t.serializeUsersOrderField=p,t.deserializeUsersOrderField=h,t.serializeUsers=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,total_count:null==e.totalCount?void 0:e.totalCount,offset:null==e.offset?void 0:e.offset,order:null==e.order?void 0:e.order.map((function(e){return p(e)})),entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeUserFull)(e)}))}},t.deserializeUsers=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Users"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Users"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "Users"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "Users"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.total_count&&!(0,s.sdIsNumber)(e.total_count))throw new o.BoxSdkError({message:'Expecting number for "total_count" of type "Users"'});const c=null==e.total_count?void 0:e.total_count;if(null!=e.offset&&!(0,s.sdIsNumber)(e.offset))throw new o.BoxSdkError({message:'Expecting number for "offset" of type "Users"'});const u=null==e.offset?void 0:e.offset;if(null!=e.order&&!(0,l.sdIsList)(e.order))throw new o.BoxSdkError({message:'Expecting array for "order" of type "Users"'});const p=null==e.order?void 0:(0,l.sdIsList)(e.order)?e.order.map((function(e){return h(e)})):[];if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Users"'});const f=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeUserFull)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,totalCount:c,offset:u,order:p,entries:f}};const i=r(88510),n=r(88510),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793);function c(e){return e}function u(e){if("ASC"==e)return e;if("DESC"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize UsersOrderDirectionField"})}function p(e){return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:e.direction}}function h(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "UsersOrderField"'});if(null!=e.by&&!(0,a.sdIsString)(e.by))throw new o.BoxSdkError({message:'Expecting string for "by" of type "UsersOrderField"'});return{by:null==e.by?void 0:e.by,direction:null==e.direction?void 0:u(e.direction)}}},99698:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWatermarkWatermarkField=l,t.deserializeWatermarkWatermarkField=d,t.serializeWatermark=function(e){return{watermark:null==e.watermark?void 0:l(e.watermark)}},t.deserializeWatermark=function(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Watermark"'});return{watermark:null==e.watermark?void 0:d(e.watermark)}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793);function l(e){return{created_at:null==e.createdAt?void 0:(0,i.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,i.serializeDateTime)(e.modifiedAt)}}function d(e){if(!(0,a.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "WatermarkWatermarkField"'});if(null!=e.created_at&&!(0,s.sdIsString)(e.created_at))throw new o.BoxSdkError({message:'Expecting string for "created_at" of type "WatermarkWatermarkField"'});const t=null==e.created_at?void 0:(0,n.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,s.sdIsString)(e.modified_at))throw new o.BoxSdkError({message:'Expecting string for "modified_at" of type "WatermarkWatermarkField"'});return{createdAt:t,modifiedAt:null==e.modified_at?void 0:(0,n.deserializeDateTime)(e.modified_at)}}},60238:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebLink=void 0,t.serializeWebLinkPathCollectionField=b,t.deserializeWebLinkPathCollectionField=w,t.serializeWebLinkSharedLinkAccessField=_,t.deserializeWebLinkSharedLinkAccessField=x,t.serializeWebLinkSharedLinkEffectiveAccessField=S,t.deserializeWebLinkSharedLinkEffectiveAccessField=k,t.serializeWebLinkSharedLinkEffectivePermissionField=E,t.deserializeWebLinkSharedLinkEffectivePermissionField=T,t.serializeWebLinkSharedLinkPermissionsField=B,t.deserializeWebLinkSharedLinkPermissionsField=C,t.serializeWebLinkSharedLinkField=I,t.deserializeWebLinkSharedLinkField=A,t.serializeWebLinkItemStatusField=F,t.deserializeWebLinkItemStatusField=M,t.serializeWebLink=function(e){const t=(0,n.serializeWebLinkMini)(e);if(!(0,y.sdIsMap)(t))throw new p.BoxSdkError({message:'Expecting a map for "WebLink"'});return Object.assign(Object.assign({},t),{parent:null==e.parent?void 0:(0,o.serializeFolderMini)(e.parent),description:null==e.description?void 0:e.description,path_collection:null==e.pathCollection?void 0:b(e.pathCollection),created_at:null==e.createdAt?void 0:(0,d.serializeDateTime)(e.createdAt),modified_at:null==e.modifiedAt?void 0:(0,d.serializeDateTime)(e.modifiedAt),trashed_at:null==e.trashedAt?void 0:(0,d.serializeDateTime)(e.trashedAt),purged_at:null==e.purgedAt?void 0:(0,d.serializeDateTime)(e.purgedAt),created_by:null==e.createdBy?void 0:(0,a.serializeUserMini)(e.createdBy),modified_by:null==e.modifiedBy?void 0:(0,a.serializeUserMini)(e.modifiedBy),owned_by:null==e.ownedBy?void 0:(0,a.serializeUserMini)(e.ownedBy),shared_link:null==e.sharedLink?void 0:I(e.sharedLink),item_status:null==e.itemStatus?void 0:e.itemStatus})},t.deserializeWebLink=function(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "WebLink"'});const t=null==e.parent?void 0:(0,s.deserializeFolderMini)(e.parent);if(null!=e.description&&!(0,m.sdIsString)(e.description))throw new p.BoxSdkError({message:'Expecting string for "description" of type "WebLink"'});const r=null==e.description?void 0:e.description,n=null==e.path_collection?void 0:w(e.path_collection);if(null!=e.created_at&&!(0,m.sdIsString)(e.created_at))throw new p.BoxSdkError({message:'Expecting string for "created_at" of type "WebLink"'});const o=null==e.created_at?void 0:(0,c.deserializeDateTime)(e.created_at);if(null!=e.modified_at&&!(0,m.sdIsString)(e.modified_at))throw new p.BoxSdkError({message:'Expecting string for "modified_at" of type "WebLink"'});const a=null==e.modified_at?void 0:(0,c.deserializeDateTime)(e.modified_at);if(null!=e.trashed_at&&!(0,m.sdIsString)(e.trashed_at))throw new p.BoxSdkError({message:'Expecting string for "trashed_at" of type "WebLink"'});const d=null==e.trashed_at?void 0:(0,c.deserializeDateTime)(e.trashed_at);if(null!=e.purged_at&&!(0,m.sdIsString)(e.purged_at))throw new p.BoxSdkError({message:'Expecting string for "purged_at" of type "WebLink"'});const u=null==e.purged_at?void 0:(0,c.deserializeDateTime)(e.purged_at),h=null==e.created_by?void 0:(0,l.deserializeUserMini)(e.created_by),f=null==e.modified_by?void 0:(0,l.deserializeUserMini)(e.modified_by),g=null==e.owned_by?void 0:(0,l.deserializeUserMini)(e.owned_by),v=null==e.shared_link?void 0:A(e.shared_link),b=null==e.item_status?void 0:M(e.item_status);if(null!=e.url&&!(0,m.sdIsString)(e.url))throw new p.BoxSdkError({message:'Expecting string for "url" of type "WebLink"'});const _=null==e.url?void 0:e.url;if(null!=e.sequence_id&&!(0,m.sdIsString)(e.sequence_id))throw new p.BoxSdkError({message:'Expecting string for "sequence_id" of type "WebLink"'});const x=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,m.sdIsString)(e.name))throw new p.BoxSdkError({message:'Expecting string for "name" of type "WebLink"'});const S=null==e.name?void 0:e.name;if(null==e.id)throw new p.BoxSdkError({message:'Expecting "id" of type "WebLink" to be defined'});if(!(0,m.sdIsString)(e.id))throw new p.BoxSdkError({message:'Expecting string for "id" of type "WebLink"'});const k=e.id;if(null==e.type)throw new p.BoxSdkError({message:'Expecting "type" of type "WebLink" to be defined'});const E=(0,i.deserializeWebLinkBaseTypeField)(e.type);if(null!=e.etag&&!(0,m.sdIsString)(e.etag))throw new p.BoxSdkError({message:'Expecting string for "etag" of type "WebLink"'});const T=null==e.etag?void 0:e.etag;return{parent:t,description:r,pathCollection:n,createdAt:o,modifiedAt:a,trashedAt:d,purgedAt:u,createdBy:h,modifiedBy:f,ownedBy:g,sharedLink:v,itemStatus:b,url:_,sequenceId:x,name:S,id:k,type:E,etag:T}};const i=r(3719),n=r(44793),o=r(70343),s=r(70343),a=r(95408),l=r(95408),d=r(93845),c=r(93845),u=r(44793),p=r(72631),h=r(50793),f=r(50793),m=r(50793),g=r(50793),y=r(50793);class v extends u.WebLinkMini{constructor(e){super(e)}}function b(e){return{total_count:e.totalCount,entries:e.entries.map((function(e){return(0,o.serializeFolderMini)(e)}))}}function w(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "WebLinkPathCollectionField"'});if(null==e.total_count)throw new p.BoxSdkError({message:'Expecting "total_count" of type "WebLinkPathCollectionField" to be defined'});if(!(0,f.sdIsNumber)(e.total_count))throw new p.BoxSdkError({message:'Expecting number for "total_count" of type "WebLinkPathCollectionField"'});const t=e.total_count;if(null==e.entries)throw new p.BoxSdkError({message:'Expecting "entries" of type "WebLinkPathCollectionField" to be defined'});if(!(0,g.sdIsList)(e.entries))throw new p.BoxSdkError({message:'Expecting array for "entries" of type "WebLinkPathCollectionField"'});return{totalCount:t,entries:(0,g.sdIsList)(e.entries)?e.entries.map((function(e){return(0,s.deserializeFolderMini)(e)})):[]}}function _(e){return e}function x(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize WebLinkSharedLinkAccessField"})}function S(e){return e}function k(e){if("open"==e)return e;if("company"==e)return e;if("collaborators"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize WebLinkSharedLinkEffectiveAccessField"})}function E(e){return e}function T(e){if("can_edit"==e)return e;if("can_download"==e)return e;if("can_preview"==e)return e;if("no_access"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize WebLinkSharedLinkEffectivePermissionField"})}function B(e){return{can_download:e.canDownload,can_preview:e.canPreview,can_edit:e.canEdit}}function C(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "WebLinkSharedLinkPermissionsField"'});if(null==e.can_download)throw new p.BoxSdkError({message:'Expecting "can_download" of type "WebLinkSharedLinkPermissionsField" to be defined'});if(!(0,h.sdIsBoolean)(e.can_download))throw new p.BoxSdkError({message:'Expecting boolean for "can_download" of type "WebLinkSharedLinkPermissionsField"'});const t=e.can_download;if(null==e.can_preview)throw new p.BoxSdkError({message:'Expecting "can_preview" of type "WebLinkSharedLinkPermissionsField" to be defined'});if(!(0,h.sdIsBoolean)(e.can_preview))throw new p.BoxSdkError({message:'Expecting boolean for "can_preview" of type "WebLinkSharedLinkPermissionsField"'});const r=e.can_preview;if(null==e.can_edit)throw new p.BoxSdkError({message:'Expecting "can_edit" of type "WebLinkSharedLinkPermissionsField" to be defined'});if(!(0,h.sdIsBoolean)(e.can_edit))throw new p.BoxSdkError({message:'Expecting boolean for "can_edit" of type "WebLinkSharedLinkPermissionsField"'});return{canDownload:t,canPreview:r,canEdit:e.can_edit}}function I(e){return{url:e.url,download_url:null==e.downloadUrl?void 0:e.downloadUrl,vanity_url:null==e.vanityUrl?void 0:e.vanityUrl,vanity_name:null==e.vanityName?void 0:e.vanityName,access:null==e.access?void 0:e.access,effective_access:e.effectiveAccess,effective_permission:e.effectivePermission,unshared_at:null==e.unsharedAt?void 0:(0,d.serializeDateTime)(e.unsharedAt),is_password_enabled:e.isPasswordEnabled,permissions:null==e.permissions?void 0:B(e.permissions),download_count:e.downloadCount,preview_count:e.previewCount}}function A(e){if(!(0,y.sdIsMap)(e))throw new p.BoxSdkError({message:'Expecting a map for "WebLinkSharedLinkField"'});if(null==e.url)throw new p.BoxSdkError({message:'Expecting "url" of type "WebLinkSharedLinkField" to be defined'});if(!(0,m.sdIsString)(e.url))throw new p.BoxSdkError({message:'Expecting string for "url" of type "WebLinkSharedLinkField"'});const t=e.url;if(null!=e.download_url&&!(0,m.sdIsString)(e.download_url))throw new p.BoxSdkError({message:'Expecting string for "download_url" of type "WebLinkSharedLinkField"'});const r=null==e.download_url?void 0:e.download_url;if(null!=e.vanity_url&&!(0,m.sdIsString)(e.vanity_url))throw new p.BoxSdkError({message:'Expecting string for "vanity_url" of type "WebLinkSharedLinkField"'});const i=null==e.vanity_url?void 0:e.vanity_url;if(null!=e.vanity_name&&!(0,m.sdIsString)(e.vanity_name))throw new p.BoxSdkError({message:'Expecting string for "vanity_name" of type "WebLinkSharedLinkField"'});const n=null==e.vanity_name?void 0:e.vanity_name,o=null==e.access?void 0:x(e.access);if(null==e.effective_access)throw new p.BoxSdkError({message:'Expecting "effective_access" of type "WebLinkSharedLinkField" to be defined'});const s=k(e.effective_access);if(null==e.effective_permission)throw new p.BoxSdkError({message:'Expecting "effective_permission" of type "WebLinkSharedLinkField" to be defined'});const a=T(e.effective_permission);if(null!=e.unshared_at&&!(0,m.sdIsString)(e.unshared_at))throw new p.BoxSdkError({message:'Expecting string for "unshared_at" of type "WebLinkSharedLinkField"'});const l=null==e.unshared_at?void 0:(0,c.deserializeDateTime)(e.unshared_at);if(null==e.is_password_enabled)throw new p.BoxSdkError({message:'Expecting "is_password_enabled" of type "WebLinkSharedLinkField" to be defined'});if(!(0,h.sdIsBoolean)(e.is_password_enabled))throw new p.BoxSdkError({message:'Expecting boolean for "is_password_enabled" of type "WebLinkSharedLinkField"'});const d=e.is_password_enabled,u=null==e.permissions?void 0:C(e.permissions);if(null==e.download_count)throw new p.BoxSdkError({message:'Expecting "download_count" of type "WebLinkSharedLinkField" to be defined'});if(!(0,f.sdIsNumber)(e.download_count))throw new p.BoxSdkError({message:'Expecting number for "download_count" of type "WebLinkSharedLinkField"'});const g=e.download_count;if(null==e.preview_count)throw new p.BoxSdkError({message:'Expecting "preview_count" of type "WebLinkSharedLinkField" to be defined'});if(!(0,f.sdIsNumber)(e.preview_count))throw new p.BoxSdkError({message:'Expecting number for "preview_count" of type "WebLinkSharedLinkField"'});return{url:t,downloadUrl:r,vanityUrl:i,vanityName:n,access:o,effectiveAccess:s,effectivePermission:a,unsharedAt:l,isPasswordEnabled:d,permissions:u,downloadCount:g,previewCount:e.preview_count}}function F(e){return e}function M(e){if("active"==e)return e;if("trashed"==e)return e;if("deleted"==e)return e;throw new p.BoxSdkError({message:"Can't deserialize WebLinkItemStatusField"})}t.WebLink=v},3719:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebLinkBase=void 0,t.serializeWebLinkBaseTypeField=s,t.deserializeWebLinkBaseTypeField=a,t.serializeWebLinkBase=function(e){return{id:e.id,type:e.type,etag:null==e.etag?void 0:e.etag}},t.deserializeWebLinkBase=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "WebLinkBase"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "WebLinkBase" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "WebLinkBase"'});const t=e.id;if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "WebLinkBase" to be defined'});const r=a(e.type);if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "WebLinkBase"'});const s=null==e.etag?void 0:e.etag;return{id:t,type:r,etag:s}},t.serializeWebLinkBaseInput=function(e){return{id:e.id,type:null==e.type?void 0:e.type,etag:null==e.etag?void 0:e.etag}},t.deserializeWebLinkBaseInput=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "WebLinkBaseInput"'});if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "WebLinkBaseInput" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "WebLinkBaseInput"'});const t=e.id,r=null==e.type?void 0:a(e.type);if(null!=e.etag&&!(0,n.sdIsString)(e.etag))throw new i.BoxSdkError({message:'Expecting string for "etag" of type "WebLinkBaseInput"'});const s=null==e.etag?void 0:e.etag;return{id:t,type:r,etag:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("web_link"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize WebLinkBaseTypeField"})}t.WebLinkBase=class{constructor(e){this.type="web_link",e.id&&(this.id=e.id),e.type&&(this.type=e.type),e.etag&&(this.etag=e.etag),e.rawData&&(this.rawData=e.rawData)}}},44793:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebLinkMini=void 0,t.serializeWebLinkMini=function(e){const t=(0,n.serializeWebLinkBase)(e);if(!(0,l.sdIsMap)(t))throw new s.BoxSdkError({message:'Expecting a map for "WebLinkMini"'});return Object.assign(Object.assign({},t),{url:null==e.url?void 0:e.url,sequence_id:null==e.sequenceId?void 0:e.sequenceId,name:null==e.name?void 0:e.name})},t.deserializeWebLinkMini=function(e){if(!(0,l.sdIsMap)(e))throw new s.BoxSdkError({message:'Expecting a map for "WebLinkMini"'});if(null!=e.url&&!(0,a.sdIsString)(e.url))throw new s.BoxSdkError({message:'Expecting string for "url" of type "WebLinkMini"'});const t=null==e.url?void 0:e.url;if(null!=e.sequence_id&&!(0,a.sdIsString)(e.sequence_id))throw new s.BoxSdkError({message:'Expecting string for "sequence_id" of type "WebLinkMini"'});const r=null==e.sequence_id?void 0:e.sequence_id;if(null!=e.name&&!(0,a.sdIsString)(e.name))throw new s.BoxSdkError({message:'Expecting string for "name" of type "WebLinkMini"'});const n=null==e.name?void 0:e.name;if(null==e.id)throw new s.BoxSdkError({message:'Expecting "id" of type "WebLinkMini" to be defined'});if(!(0,a.sdIsString)(e.id))throw new s.BoxSdkError({message:'Expecting string for "id" of type "WebLinkMini"'});const o=e.id;if(null==e.type)throw new s.BoxSdkError({message:'Expecting "type" of type "WebLinkMini" to be defined'});const d=(0,i.deserializeWebLinkBaseTypeField)(e.type);if(null!=e.etag&&!(0,a.sdIsString)(e.etag))throw new s.BoxSdkError({message:'Expecting string for "etag" of type "WebLinkMini"'});const c=null==e.etag?void 0:e.etag;return{url:t,sequenceId:r,name:n,id:o,type:d,etag:c}};const i=r(3719),n=r(3719),o=r(3719),s=r(72631),a=r(50793),l=r(50793);class d extends o.WebLinkBase{constructor(e){super(e)}}t.WebLinkMini=d},36257:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWebhookTriggersField=f,t.deserializeWebhookTriggersField=m,t.serializeWebhook=function(e){const t=(0,o.serializeWebhookMini)(e);if(!(0,h.sdIsMap)(t))throw new c.BoxSdkError({message:'Expecting a map for "Webhook"'});return Object.assign(Object.assign({},t),{created_by:null==e.createdBy?void 0:(0,s.serializeUserMini)(e.createdBy),created_at:null==e.createdAt?void 0:(0,l.serializeDateTime)(e.createdAt),address:null==e.address?void 0:e.address,triggers:null==e.triggers?void 0:e.triggers.map((function(e){return e}))})},t.deserializeWebhook=function(e){if(!(0,h.sdIsMap)(e))throw new c.BoxSdkError({message:'Expecting a map for "Webhook"'});const t=null==e.created_by?void 0:(0,a.deserializeUserMini)(e.created_by);if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new c.BoxSdkError({message:'Expecting string for "created_at" of type "Webhook"'});const r=null==e.created_at?void 0:(0,d.deserializeDateTime)(e.created_at);if(null!=e.address&&!(0,u.sdIsString)(e.address))throw new c.BoxSdkError({message:'Expecting string for "address" of type "Webhook"'});const o=null==e.address?void 0:e.address;if(null!=e.triggers&&!(0,p.sdIsList)(e.triggers))throw new c.BoxSdkError({message:'Expecting array for "triggers" of type "Webhook"'});const s=null==e.triggers?void 0:(0,p.sdIsList)(e.triggers)?e.triggers.map((function(e){return m(e)})):[];if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new c.BoxSdkError({message:'Expecting string for "id" of type "Webhook"'});const l=null==e.id?void 0:e.id,f=null==e.type?void 0:(0,i.deserializeWebhookMiniTypeField)(e.type),g=null==e.target?void 0:(0,n.deserializeWebhookMiniTargetField)(e.target);return{createdBy:t,createdAt:r,address:o,triggers:s,id:l,type:f,target:g}};const i=r(29510),n=r(29510),o=r(29510),s=r(95408),a=r(95408),l=r(93845),d=r(93845),c=r(72631),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("FILE.UPLOADED"==e)return e;if("FILE.PREVIEWED"==e)return e;if("FILE.DOWNLOADED"==e)return e;if("FILE.TRASHED"==e)return e;if("FILE.DELETED"==e)return e;if("FILE.RESTORED"==e)return e;if("FILE.COPIED"==e)return e;if("FILE.MOVED"==e)return e;if("FILE.LOCKED"==e)return e;if("FILE.UNLOCKED"==e)return e;if("FILE.RENAMED"==e)return e;if("COMMENT.CREATED"==e)return e;if("COMMENT.UPDATED"==e)return e;if("COMMENT.DELETED"==e)return e;if("TASK_ASSIGNMENT.CREATED"==e)return e;if("TASK_ASSIGNMENT.UPDATED"==e)return e;if("METADATA_INSTANCE.CREATED"==e)return e;if("METADATA_INSTANCE.UPDATED"==e)return e;if("METADATA_INSTANCE.DELETED"==e)return e;if("FOLDER.CREATED"==e)return e;if("FOLDER.RENAMED"==e)return e;if("FOLDER.DOWNLOADED"==e)return e;if("FOLDER.RESTORED"==e)return e;if("FOLDER.DELETED"==e)return e;if("FOLDER.COPIED"==e)return e;if("FOLDER.MOVED"==e)return e;if("FOLDER.TRASHED"==e)return e;if("WEBHOOK.DELETED"==e)return e;if("COLLABORATION.CREATED"==e)return e;if("COLLABORATION.ACCEPTED"==e)return e;if("COLLABORATION.REJECTED"==e)return e;if("COLLABORATION.REMOVED"==e)return e;if("COLLABORATION.UPDATED"==e)return e;if("SHARED_LINK.DELETED"==e)return e;if("SHARED_LINK.CREATED"==e)return e;if("SHARED_LINK.UPDATED"==e)return e;if("SIGN_REQUEST.COMPLETED"==e)return e;if("SIGN_REQUEST.DECLINED"==e)return e;if("SIGN_REQUEST.EXPIRED"==e)return e;if("SIGN_REQUEST.SIGNER_EMAIL_BOUNCED"==e)return e;throw new c.BoxSdkError({message:"Can't deserialize WebhookTriggersField"})}},29510:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWebhookMiniTypeField=s,t.deserializeWebhookMiniTypeField=a,t.serializeWebhookMiniTargetTypeField=l,t.deserializeWebhookMiniTargetTypeField=d,t.serializeWebhookMiniTargetField=c,t.deserializeWebhookMiniTargetField=u,t.serializeWebhookMini=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,target:null==e.target?void 0:c(e.target)}},t.deserializeWebhookMini=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "WebhookMini"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "WebhookMini"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:a(e.type),s=null==e.target?void 0:u(e.target);return{id:t,type:r,target:s}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("webhook"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize WebhookMiniTypeField"})}function l(e){return e}function d(e){if("file"==e)return e;if("folder"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize WebhookMiniTargetTypeField"})}function c(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type}}function u(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "WebhookMiniTargetField"'});if(null!=e.id&&!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "WebhookMiniTargetField"'});return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:d(e.type)}}},70934:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWebhooks=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeWebhookMini)(e)}))}},t.deserializeWebhooks=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Webhooks"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Webhooks"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "Webhooks"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "Webhooks"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Webhooks"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeWebhookMini)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(29510),n=r(29510),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},90213:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWorkflowFlowsTypeField=f,t.deserializeWorkflowFlowsTypeField=m,t.serializeWorkflowFlowsTriggerTypeField=g,t.deserializeWorkflowFlowsTriggerTypeField=y,t.serializeWorkflowFlowsTriggerTriggerTypeField=v,t.deserializeWorkflowFlowsTriggerTriggerTypeField=b,t.serializeWorkflowFlowsTriggerScopeTypeField=w,t.deserializeWorkflowFlowsTriggerScopeTypeField=_,t.serializeWorkflowFlowsTriggerScopeObjectTypeField=x,t.deserializeWorkflowFlowsTriggerScopeObjectTypeField=S,t.serializeWorkflowFlowsTriggerScopeObjectField=k,t.deserializeWorkflowFlowsTriggerScopeObjectField=E,t.serializeWorkflowFlowsTriggerScopeField=T,t.deserializeWorkflowFlowsTriggerScopeField=B,t.serializeWorkflowFlowsTriggerField=C,t.deserializeWorkflowFlowsTriggerField=I,t.serializeWorkflowFlowsOutcomesTypeField=A,t.deserializeWorkflowFlowsOutcomesTypeField=F,t.serializeWorkflowFlowsOutcomesActionTypeField=M,t.deserializeWorkflowFlowsOutcomesActionTypeField=D,t.serializeWorkflowFlowsOutcomesIfRejectedTypeField=R,t.deserializeWorkflowFlowsOutcomesIfRejectedTypeField=P,t.serializeWorkflowFlowsOutcomesIfRejectedActionTypeField=O,t.deserializeWorkflowFlowsOutcomesIfRejectedActionTypeField=z,t.serializeWorkflowFlowsOutcomesIfRejectedField=N,t.deserializeWorkflowFlowsOutcomesIfRejectedField=q,t.serializeWorkflowFlowsOutcomesField=U,t.deserializeWorkflowFlowsOutcomesField=L,t.serializeWorkflowFlowsField=j,t.deserializeWorkflowFlowsField=H,t.serializeWorkflow=function(e){const t=(0,n.serializeWorkflowMini)(e);if(!(0,h.sdIsMap)(t))throw new d.BoxSdkError({message:'Expecting a map for "Workflow"'});return Object.assign(Object.assign({},t),{flows:null==e.flows?void 0:e.flows.map((function(e){return j(e)}))})},t.deserializeWorkflow=function(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "Workflow"'});if(null!=e.flows&&!(0,p.sdIsList)(e.flows))throw new d.BoxSdkError({message:'Expecting array for "flows" of type "Workflow"'});const t=null==e.flows?void 0:(0,p.sdIsList)(e.flows)?e.flows.map((function(e){return H(e)})):[];if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "Workflow"'});const r=null==e.id?void 0:e.id,n=null==e.type?void 0:(0,i.deserializeWorkflowMiniTypeField)(e.type);if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "Workflow"'});const o=null==e.name?void 0:e.name;if(null!=e.description&&!(0,u.sdIsString)(e.description))throw new d.BoxSdkError({message:'Expecting string for "description" of type "Workflow"'});const s=null==e.description?void 0:e.description;if(null!=e.is_enabled&&!(0,c.sdIsBoolean)(e.is_enabled))throw new d.BoxSdkError({message:'Expecting boolean for "is_enabled" of type "Workflow"'});const a=null==e.is_enabled?void 0:e.is_enabled;return{flows:t,id:r,type:n,name:o,description:s,isEnabled:a}};const i=r(3386),n=r(3386),o=r(78366),s=r(78366),a=r(93845),l=r(93845),d=r(72631),c=r(50793),u=r(50793),p=r(50793),h=r(50793);function f(e){return e}function m(e){if("flow"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsTypeField"})}function g(e){return e}function y(e){if("trigger"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsTriggerTypeField"})}function v(e){return e}function b(e){if("WORKFLOW_MANUAL_START"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsTriggerTriggerTypeField"})}function w(e){return e}function _(e){if("trigger_scope"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsTriggerScopeTypeField"})}function x(e){return e}function S(e){if("folder"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsTriggerScopeObjectTypeField"})}function k(e){return{type:null==e.type?void 0:e.type,id:null==e.id?void 0:e.id}}function E(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsTriggerScopeObjectField"'});const t=null==e.type?void 0:S(e.type);if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "WorkflowFlowsTriggerScopeObjectField"'});return{type:t,id:null==e.id?void 0:e.id}}function T(e){return{type:null==e.type?void 0:e.type,ref:null==e.ref?void 0:e.ref,object:null==e.object?void 0:k(e.object)}}function B(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsTriggerScopeField"'});const t=null==e.type?void 0:_(e.type);if(null!=e.ref&&!(0,u.sdIsString)(e.ref))throw new d.BoxSdkError({message:'Expecting string for "ref" of type "WorkflowFlowsTriggerScopeField"'});return{type:t,ref:null==e.ref?void 0:e.ref,object:null==e.object?void 0:E(e.object)}}function C(e){return{type:null==e.type?void 0:e.type,trigger_type:null==e.triggerType?void 0:e.triggerType,scope:null==e.scope?void 0:e.scope.map((function(e){return T(e)}))}}function I(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsTriggerField"'});const t=null==e.type?void 0:y(e.type),r=null==e.trigger_type?void 0:b(e.trigger_type);if(null!=e.scope&&!(0,p.sdIsList)(e.scope))throw new d.BoxSdkError({message:'Expecting array for "scope" of type "WorkflowFlowsTriggerField"'});return{type:t,triggerType:r,scope:null==e.scope?void 0:(0,p.sdIsList)(e.scope)?e.scope.map((function(e){return B(e)})):[]}}function A(e){return e}function F(e){if("outcome"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsOutcomesTypeField"})}function M(e){return e}function D(e){if("add_metadata"==e)return e;if("assign_task"==e)return e;if("copy_file"==e)return e;if("copy_folder"==e)return e;if("create_folder"==e)return e;if("delete_file"==e)return e;if("delete_folder"==e)return e;if("lock_file"==e)return e;if("move_file"==e)return e;if("move_folder"==e)return e;if("remove_watermark_file"==e)return e;if("rename_folder"==e)return e;if("restore_folder"==e)return e;if("share_file"==e)return e;if("share_folder"==e)return e;if("unlock_file"==e)return e;if("upload_file"==e)return e;if("wait_for_task"==e)return e;if("watermark_file"==e)return e;if("go_back_to_step"==e)return e;if("apply_file_classification"==e)return e;if("apply_folder_classification"==e)return e;if("send_notification"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsOutcomesActionTypeField"})}function R(e){return e}function P(e){if("outcome"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsOutcomesIfRejectedTypeField"})}function O(e){return e}function z(e){if("add_metadata"==e)return e;if("assign_task"==e)return e;if("copy_file"==e)return e;if("copy_folder"==e)return e;if("create_folder"==e)return e;if("delete_file"==e)return e;if("delete_folder"==e)return e;if("lock_file"==e)return e;if("move_file"==e)return e;if("move_folder"==e)return e;if("remove_watermark_file"==e)return e;if("rename_folder"==e)return e;if("restore_folder"==e)return e;if("share_file"==e)return e;if("share_folder"==e)return e;if("unlock_file"==e)return e;if("upload_file"==e)return e;if("wait_for_task"==e)return e;if("watermark_file"==e)return e;if("go_back_to_step"==e)return e;if("apply_file_classification"==e)return e;if("apply_folder_classification"==e)return e;if("send_notification"==e)return e;throw new d.BoxSdkError({message:"Can't deserialize WorkflowFlowsOutcomesIfRejectedActionTypeField"})}function N(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name,action_type:null==e.actionType?void 0:e.actionType}}function q(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsOutcomesIfRejectedField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "WorkflowFlowsOutcomesIfRejectedField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:P(e.type);if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "WorkflowFlowsOutcomesIfRejectedField"'});return{id:t,type:r,name:null==e.name?void 0:e.name,actionType:null==e.action_type?void 0:z(e.action_type)}}function U(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name,action_type:null==e.actionType?void 0:e.actionType,if_rejected:null==e.ifRejected?void 0:e.ifRejected.map((function(e){return N(e)}))}}function L(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsOutcomesField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "WorkflowFlowsOutcomesField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:F(e.type);if(null!=e.name&&!(0,u.sdIsString)(e.name))throw new d.BoxSdkError({message:'Expecting string for "name" of type "WorkflowFlowsOutcomesField"'});const i=null==e.name?void 0:e.name,n=null==e.action_type?void 0:D(e.action_type);if(null!=e.if_rejected&&!(0,p.sdIsList)(e.if_rejected))throw new d.BoxSdkError({message:'Expecting array for "if_rejected" of type "WorkflowFlowsOutcomesField"'});return{id:t,type:r,name:i,actionType:n,ifRejected:null==e.if_rejected?void 0:(0,p.sdIsList)(e.if_rejected)?e.if_rejected.map((function(e){return q(e)})):[]}}function j(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,trigger:null==e.trigger?void 0:C(e.trigger),outcomes:null==e.outcomes?void 0:e.outcomes.map((function(e){return U(e)})),created_at:null==e.createdAt?void 0:(0,a.serializeDateTime)(e.createdAt),created_by:null==e.createdBy?void 0:(0,o.serializeUserBase)(e.createdBy)}}function H(e){if(!(0,h.sdIsMap)(e))throw new d.BoxSdkError({message:'Expecting a map for "WorkflowFlowsField"'});if(null!=e.id&&!(0,u.sdIsString)(e.id))throw new d.BoxSdkError({message:'Expecting string for "id" of type "WorkflowFlowsField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:m(e.type),i=null==e.trigger?void 0:I(e.trigger);if(null!=e.outcomes&&!(0,p.sdIsList)(e.outcomes))throw new d.BoxSdkError({message:'Expecting array for "outcomes" of type "WorkflowFlowsField"'});const n=null==e.outcomes?void 0:(0,p.sdIsList)(e.outcomes)?e.outcomes.map((function(e){return L(e)})):[];if(null!=e.created_at&&!(0,u.sdIsString)(e.created_at))throw new d.BoxSdkError({message:'Expecting string for "created_at" of type "WorkflowFlowsField"'});return{id:t,type:r,trigger:i,outcomes:n,createdAt:null==e.created_at?void 0:(0,l.deserializeDateTime)(e.created_at),createdBy:null==e.created_by?void 0:(0,s.deserializeUserBase)(e.created_by)}}},3386:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWorkflowMiniTypeField=a,t.deserializeWorkflowMiniTypeField=l,t.serializeWorkflowMini=function(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,name:null==e.name?void 0:e.name,description:null==e.description?void 0:e.description,is_enabled:null==e.isEnabled?void 0:e.isEnabled}},t.deserializeWorkflowMini=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "WorkflowMini"'});if(null!=e.id&&!(0,o.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "WorkflowMini"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:l(e.type);if(null!=e.name&&!(0,o.sdIsString)(e.name))throw new i.BoxSdkError({message:'Expecting string for "name" of type "WorkflowMini"'});const a=null==e.name?void 0:e.name;if(null!=e.description&&!(0,o.sdIsString)(e.description))throw new i.BoxSdkError({message:'Expecting string for "description" of type "WorkflowMini"'});const d=null==e.description?void 0:e.description;if(null!=e.is_enabled&&!(0,n.sdIsBoolean)(e.is_enabled))throw new i.BoxSdkError({message:'Expecting boolean for "is_enabled" of type "WorkflowMini"'});const c=null==e.is_enabled?void 0:e.is_enabled;return{id:t,type:r,name:a,description:d,isEnabled:c}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793);function a(e){return e}function l(e){if("workflow"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize WorkflowMiniTypeField"})}},70018:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeWorkflows=function(e){return{limit:null==e.limit?void 0:e.limit,next_marker:null==e.nextMarker?void 0:e.nextMarker,prev_marker:null==e.prevMarker?void 0:e.prevMarker,entries:null==e.entries?void 0:e.entries.map((function(e){return(0,i.serializeWorkflow)(e)}))}},t.deserializeWorkflows=function(e){if(!(0,d.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "Workflows"'});if(null!=e.limit&&!(0,s.sdIsNumber)(e.limit))throw new o.BoxSdkError({message:'Expecting number for "limit" of type "Workflows"'});const t=null==e.limit?void 0:e.limit;if(null!=e.next_marker&&!(0,a.sdIsString)(e.next_marker))throw new o.BoxSdkError({message:'Expecting string for "next_marker" of type "Workflows"'});const r=null==e.next_marker?void 0:e.next_marker;if(null!=e.prev_marker&&!(0,a.sdIsString)(e.prev_marker))throw new o.BoxSdkError({message:'Expecting string for "prev_marker" of type "Workflows"'});const i=null==e.prev_marker?void 0:e.prev_marker;if(null!=e.entries&&!(0,l.sdIsList)(e.entries))throw new o.BoxSdkError({message:'Expecting array for "entries" of type "Workflows"'});const c=null==e.entries?void 0:(0,l.sdIsList)(e.entries)?e.entries.map((function(e){return(0,n.deserializeWorkflow)(e)})):[];return{limit:t,nextMarker:r,prevMarker:i,entries:c}};const i=r(90213),n=r(90213),o=r(72631),s=r(50793),a=r(50793),l=r(50793),d=r(50793)},63055:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeZipDownloadNameConflictsTypeField=d,t.deserializeZipDownloadNameConflictsTypeField=c,t.serializeZipDownloadNameConflictsField=u,t.deserializeZipDownloadNameConflictsField=p,t.serializeZipDownload=function(e){return{download_url:null==e.downloadUrl?void 0:e.downloadUrl,status_url:null==e.statusUrl?void 0:e.statusUrl,expires_at:null==e.expiresAt?void 0:(0,i.serializeDateTime)(e.expiresAt),name_conflicts:null==e.nameConflicts?void 0:e.nameConflicts.map((function(e){return e.map((function(e){return u(e)}))}))}},t.deserializeZipDownload=function(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ZipDownload"'});if(null!=e.download_url&&!(0,s.sdIsString)(e.download_url))throw new o.BoxSdkError({message:'Expecting string for "download_url" of type "ZipDownload"'});const t=null==e.download_url?void 0:e.download_url;if(null!=e.status_url&&!(0,s.sdIsString)(e.status_url))throw new o.BoxSdkError({message:'Expecting string for "status_url" of type "ZipDownload"'});const r=null==e.status_url?void 0:e.status_url;if(null!=e.expires_at&&!(0,s.sdIsString)(e.expires_at))throw new o.BoxSdkError({message:'Expecting string for "expires_at" of type "ZipDownload"'});const i=null==e.expires_at?void 0:(0,n.deserializeDateTime)(e.expires_at);if(null!=e.name_conflicts&&!(0,a.sdIsList)(e.name_conflicts))throw new o.BoxSdkError({message:'Expecting array for "name_conflicts" of type "ZipDownload"'});const d=null==e.name_conflicts?void 0:(0,a.sdIsList)(e.name_conflicts)?e.name_conflicts.map((function(e){return(0,a.sdIsList)(e)?e.map((function(e){return p(e)})):[]})):[];return{downloadUrl:t,statusUrl:r,expiresAt:i,nameConflicts:d}};const i=r(93845),n=r(93845),o=r(72631),s=r(50793),a=r(50793),l=r(50793);function d(e){return e}function c(e){if("file"==e)return e;if("folder"==e)return e;throw new o.BoxSdkError({message:"Can't deserialize ZipDownloadNameConflictsTypeField"})}function u(e){return{id:null==e.id?void 0:e.id,type:null==e.type?void 0:e.type,original_name:null==e.originalName?void 0:e.originalName,download_name:null==e.downloadName?void 0:e.downloadName}}function p(e){if(!(0,l.sdIsMap)(e))throw new o.BoxSdkError({message:'Expecting a map for "ZipDownloadNameConflictsField"'});if(null!=e.id&&!(0,s.sdIsString)(e.id))throw new o.BoxSdkError({message:'Expecting string for "id" of type "ZipDownloadNameConflictsField"'});const t=null==e.id?void 0:e.id,r=null==e.type?void 0:c(e.type);if(null!=e.original_name&&!(0,s.sdIsString)(e.original_name))throw new o.BoxSdkError({message:'Expecting string for "original_name" of type "ZipDownloadNameConflictsField"'});const i=null==e.original_name?void 0:e.original_name;if(null!=e.download_name&&!(0,s.sdIsString)(e.download_name))throw new o.BoxSdkError({message:'Expecting string for "download_name" of type "ZipDownloadNameConflictsField"'});return{id:t,type:r,originalName:i,downloadName:null==e.download_name?void 0:e.download_name}}},37248:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeZipDownloadRequestItemsTypeField=a,t.deserializeZipDownloadRequestItemsTypeField=l,t.serializeZipDownloadRequestItemsField=d,t.deserializeZipDownloadRequestItemsField=c,t.serializeZipDownloadRequest=function(e){return{items:e.items.map((function(e){return d(e)})),download_file_name:null==e.downloadFileName?void 0:e.downloadFileName}},t.deserializeZipDownloadRequest=function(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ZipDownloadRequest"'});if(null==e.items)throw new i.BoxSdkError({message:'Expecting "items" of type "ZipDownloadRequest" to be defined'});if(!(0,o.sdIsList)(e.items))throw new i.BoxSdkError({message:'Expecting array for "items" of type "ZipDownloadRequest"'});const t=(0,o.sdIsList)(e.items)?e.items.map((function(e){return c(e)})):[];if(null!=e.download_file_name&&!(0,n.sdIsString)(e.download_file_name))throw new i.BoxSdkError({message:'Expecting string for "download_file_name" of type "ZipDownloadRequest"'});const r=null==e.download_file_name?void 0:e.download_file_name;return{items:t,downloadFileName:r}};const i=r(72631),n=r(50793),o=r(50793),s=r(50793);function a(e){return e}function l(e){if("file"==e)return e;if("folder"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ZipDownloadRequestItemsTypeField"})}function d(e){return{type:e.type,id:e.id}}function c(e){if(!(0,s.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ZipDownloadRequestItemsField"'});if(null==e.type)throw new i.BoxSdkError({message:'Expecting "type" of type "ZipDownloadRequestItemsField" to be defined'});const t=l(e.type);if(null==e.id)throw new i.BoxSdkError({message:'Expecting "id" of type "ZipDownloadRequestItemsField" to be defined'});if(!(0,n.sdIsString)(e.id))throw new i.BoxSdkError({message:'Expecting string for "id" of type "ZipDownloadRequestItemsField"'});return{type:t,id:e.id}}},47237:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.serializeZipDownloadStatusStateField=s,t.deserializeZipDownloadStatusStateField=a,t.serializeZipDownloadStatus=function(e){return{total_file_count:null==e.totalFileCount?void 0:e.totalFileCount,downloaded_file_count:null==e.downloadedFileCount?void 0:e.downloadedFileCount,skipped_file_count:null==e.skippedFileCount?void 0:e.skippedFileCount,skipped_folder_count:null==e.skippedFolderCount?void 0:e.skippedFolderCount,state:null==e.state?void 0:e.state}},t.deserializeZipDownloadStatus=function(e){if(!(0,o.sdIsMap)(e))throw new i.BoxSdkError({message:'Expecting a map for "ZipDownloadStatus"'});if(null!=e.total_file_count&&!(0,n.sdIsNumber)(e.total_file_count))throw new i.BoxSdkError({message:'Expecting number for "total_file_count" of type "ZipDownloadStatus"'});const t=null==e.total_file_count?void 0:e.total_file_count;if(null!=e.downloaded_file_count&&!(0,n.sdIsNumber)(e.downloaded_file_count))throw new i.BoxSdkError({message:'Expecting number for "downloaded_file_count" of type "ZipDownloadStatus"'});const r=null==e.downloaded_file_count?void 0:e.downloaded_file_count;if(null!=e.skipped_file_count&&!(0,n.sdIsNumber)(e.skipped_file_count))throw new i.BoxSdkError({message:'Expecting number for "skipped_file_count" of type "ZipDownloadStatus"'});const s=null==e.skipped_file_count?void 0:e.skipped_file_count;if(null!=e.skipped_folder_count&&!(0,n.sdIsNumber)(e.skipped_folder_count))throw new i.BoxSdkError({message:'Expecting number for "skipped_folder_count" of type "ZipDownloadStatus"'});const l=null==e.skipped_folder_count?void 0:e.skipped_folder_count,d=null==e.state?void 0:a(e.state);return{totalFileCount:t,downloadedFileCount:r,skippedFileCount:s,skippedFolderCount:l,state:d}};const i=r(72631),n=r(50793),o=r(50793);function s(e){return e}function a(e){if("in_progress"==e)return e;if("failed"==e)return e;if("succeeded"==e)return e;throw new i.BoxSdkError({message:"Can't deserialize ZipDownloadStatusStateField"})}},50793:(e,t)=>{"use strict";function r(e){return"string"==typeof e}function i(e){return"object"==typeof e&&null!=e&&!Array.isArray(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.jsonToSerializedData=function(e){return JSON.parse(e)},t.sdToJson=function(e){return JSON.stringify(e)},t.sdToUrlParams=function(e){if(!i(e)&&!r(e))throw new Error("Expecting an object or string as an argument for sdToUrlParams");const t=r(e)?JSON.parse(e):e;return new URLSearchParams(Object.fromEntries(Object.entries(t).filter((([e,t])=>null!=t)))).toString()},t.sdIsEmpty=function(e){return null==e},t.sdIsBoolean=function(e){return"boolean"==typeof e},t.sdIsNumber=function(e){return"number"==typeof e},t.sdIsString=r,t.sdIsList=function(e){return Array.isArray(e)},t.sdIsMap=i},16882:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NIL",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"parse",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"v1",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"v3",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"v4",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"v5",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"validate",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"version",{enumerable:!0,get:function(){return l.default}});var i=p(r(89125)),n=p(r(14851)),o=p(r(37338)),s=p(r(49865)),a=p(r(25293)),l=p(r(86598)),d=p(r(49350)),c=p(r(655)),u=p(r(99121));function p(e){return e&&e.__esModule?e:{default:e}}},45630:(e,t)=>{"use strict";function r(e){return 14+(e+64>>>9<<4)+1}function i(e,t){const r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function n(e,t,r,n,o,s){return i((a=i(i(t,e),i(n,s)))<<(l=o)|a>>>32-l,r);var a,l}function o(e,t,r,i,o,s,a){return n(t&r|~t&i,e,t,o,s,a)}function s(e,t,r,i,o,s,a){return n(t&i|r&~i,e,t,o,s,a)}function a(e,t,r,i,o,s,a){return n(t^r^i,e,t,o,s,a)}function l(e,t,r,i,o,s,a){return n(r^(t|~i),e,t,o,s,a)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var d=function(e){if("string"==typeof e){const t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(let r=0;r>5]>>>n%32&255,o=parseInt(i.charAt(r>>>4&15)+i.charAt(15&r),16);t.push(o)}return t}(function(e,t){e[t>>5]|=128<>5]|=(255&e[r/8])<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};t.default=r},25293:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default="00000000-0000-0000-0000-000000000000"},99121:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,n=(i=r(49350))&&i.__esModule?i:{default:i};var o=function(e){if(!(0,n.default)(e))throw TypeError("Invalid UUID");let t;const r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=255&t,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=255&t,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=255&t,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=255&t,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=255&t,r};t.default=o},23573:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i},41223:(e,t)=>{"use strict";let r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){if(!r&&(r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!r))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return r(i)};const i=new Uint8Array(16)},55577:(e,t)=>{"use strict";function r(e,t,r,i){switch(e){case 0:return t&r^~t&i;case 1:case 3:return t^r^i;case 2:return t&r^t&i^r&i}}function i(e,t){return e<>>32-t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=function(e){const t=[1518500249,1859775393,2400959708,3395469782],n=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"==typeof e){const t=unescape(encodeURIComponent(e));e=[];for(let r=0;r>>0;u=c,c=d,d=i(l,30)>>>0,l=s,s=a}n[0]=n[0]+s>>>0,n[1]=n[1]+l>>>0,n[2]=n[2]+d>>>0,n[3]=n[3]+c>>>0,n[4]=n[4]+u>>>0}return[n[0]>>24&255,n[0]>>16&255,n[0]>>8&255,255&n[0],n[1]>>24&255,n[1]>>16&255,n[1]>>8&255,255&n[1],n[2]>>24&255,n[2]>>16&255,n[2]>>8&255,255&n[2],n[3]>>24&255,n[3]>>16&255,n[3]>>8&255,255&n[3],n[4]>>24&255,n[4]>>16&255,n[4]>>8&255,255&n[4]]};t.default=n},655:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.unsafeStringify=s;var i,n=(i=r(49350))&&i.__esModule?i:{default:i};const o=[];for(let e=0;e<256;++e)o.push((e+256).toString(16).slice(1));function s(e,t=0){return o[e[t+0]]+o[e[t+1]]+o[e[t+2]]+o[e[t+3]]+"-"+o[e[t+4]]+o[e[t+5]]+"-"+o[e[t+6]]+o[e[t+7]]+"-"+o[e[t+8]]+o[e[t+9]]+"-"+o[e[t+10]]+o[e[t+11]]+o[e[t+12]]+o[e[t+13]]+o[e[t+14]]+o[e[t+15]]}var a=function(e,t=0){const r=s(e,t);if(!(0,n.default)(r))throw TypeError("Stringified UUID is invalid");return r};t.default=a},89125:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,n=(i=r(41223))&&i.__esModule?i:{default:i},o=r(655);let s,a,l=0,d=0;var c=function(e,t,r){let i=t&&r||0;const c=t||new Array(16);let u=(e=e||{}).node||s,p=void 0!==e.clockseq?e.clockseq:a;if(null==u||null==p){const t=e.random||(e.rng||n.default)();null==u&&(u=s=[1|t[0],t[1],t[2],t[3],t[4],t[5]]),null==p&&(p=a=16383&(t[6]<<8|t[7]))}let h=void 0!==e.msecs?e.msecs:Date.now(),f=void 0!==e.nsecs?e.nsecs:d+1;const m=h-l+(f-d)/1e4;if(m<0&&void 0===e.clockseq&&(p=p+1&16383),(m<0||h>l)&&void 0===e.nsecs&&(f=0),f>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");l=h,d=f,a=p,h+=122192928e5;const g=(1e4*(268435455&h)+f)%4294967296;c[i++]=g>>>24&255,c[i++]=g>>>16&255,c[i++]=g>>>8&255,c[i++]=255&g;const y=h/4294967296*1e4&268435455;c[i++]=y>>>8&255,c[i++]=255&y,c[i++]=y>>>24&15|16,c[i++]=y>>>16&255,c[i++]=p>>>8|128,c[i++]=255&p;for(let e=0;e<6;++e)c[i+e]=u[e];return t||(0,o.unsafeStringify)(c)};t.default=c},14851:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=o(r(32816)),n=o(r(45630));function o(e){return e&&e.__esModule?e:{default:e}}var s=(0,i.default)("v3",48,n.default);t.default=s},32816:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.URL=t.DNS=void 0,t.default=function(e,t,r){function i(e,i,s,a){var l;if("string"==typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));const t=[];for(let r=0;r{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=s(r(53887)),n=s(r(41223)),o=r(655);function s(e){return e&&e.__esModule?e:{default:e}}var a=function(e,t,r){if(i.default.randomUUID&&!t&&!e)return i.default.randomUUID();const s=(e=e||{}).random||(e.rng||n.default)();if(s[6]=15&s[6]|64,s[8]=63&s[8]|128,t){r=r||0;for(let e=0;e<16;++e)t[r+e]=s[e];return t}return(0,o.unsafeStringify)(s)};t.default=a},49865:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=o(r(32816)),n=o(r(55577));function o(e){return e&&e.__esModule?e:{default:e}}var s=(0,i.default)("v5",80,n.default);t.default=s},49350:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,n=(i=r(23573))&&i.__esModule?i:{default:i};var o=function(e){return"string"==typeof e&&n.default.test(e)};t.default=o},86598:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,n=(i=r(49350))&&i.__esModule?i:{default:i};var o=function(e){if(!(0,n.default)(e))throw TypeError("Invalid UUID");return parseInt(e.slice(14,15),16)};t.default=o},15037:(e,t,r)=>{var i;function n(e){this.rand=e}if(e.exports=function(e){return i||(i=new n(null)),i.generate(e)},e.exports.Rand=n,n.prototype.generate=function(e){return this._rand(e)},n.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r{var i=r(92861).Buffer;function n(e){i.isBuffer(e)||(e=i.from(e));for(var t=e.length/4|0,r=new Array(t),n=0;n>>24]^c[f>>>16&255]^u[m>>>8&255]^p[255&g]^t[y++],s=d[f>>>24]^c[m>>>16&255]^u[g>>>8&255]^p[255&h]^t[y++],a=d[m>>>24]^c[g>>>16&255]^u[h>>>8&255]^p[255&f]^t[y++],l=d[g>>>24]^c[h>>>16&255]^u[f>>>8&255]^p[255&m]^t[y++],h=o,f=s,m=a,g=l;return o=(i[h>>>24]<<24|i[f>>>16&255]<<16|i[m>>>8&255]<<8|i[255&g])^t[y++],s=(i[f>>>24]<<24|i[m>>>16&255]<<16|i[g>>>8&255]<<8|i[255&h])^t[y++],a=(i[m>>>24]<<24|i[g>>>16&255]<<16|i[h>>>8&255]<<8|i[255&f])^t[y++],l=(i[g>>>24]<<24|i[h>>>16&255]<<16|i[f>>>8&255]<<8|i[255&m])^t[y++],[o>>>=0,s>>>=0,a>>>=0,l>>>=0]}var a=[0,1,2,4,8,16,32,64,128,27,54],l=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],i=[],n=[[],[],[],[]],o=[[],[],[],[]],s=0,a=0,l=0;l<256;++l){var d=a^a<<1^a<<2^a<<3^a<<4;d=d>>>8^255&d^99,r[s]=d,i[d]=s;var c=e[s],u=e[c],p=e[u],h=257*e[d]^16843008*d;n[0][s]=h<<24|h>>>8,n[1][s]=h<<16|h>>>16,n[2][s]=h<<8|h>>>24,n[3][s]=h,h=16843009*p^65537*u^257*c^16843008*s,o[0][d]=h<<24|h>>>8,o[1][d]=h<<16|h>>>16,o[2][d]=h<<8|h>>>24,o[3][d]=h,0===s?s=a=1:(s=c^e[e[e[p^c]]],a^=e[e[a]])}return{SBOX:r,INV_SBOX:i,SUB_MIX:n,INV_SUB_MIX:o}}();function d(e){this._key=n(e),this._reset()}d.blockSize=16,d.keySize=32,d.prototype.blockSize=d.blockSize,d.prototype.keySize=d.keySize,d.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,i=4*(r+1),n=[],o=0;o>>24,s=l.SBOX[s>>>24]<<24|l.SBOX[s>>>16&255]<<16|l.SBOX[s>>>8&255]<<8|l.SBOX[255&s],s^=a[o/t|0]<<24):t>6&&o%t==4&&(s=l.SBOX[s>>>24]<<24|l.SBOX[s>>>16&255]<<16|l.SBOX[s>>>8&255]<<8|l.SBOX[255&s]),n[o]=n[o-t]^s}for(var d=[],c=0;c>>24]]^l.INV_SUB_MIX[1][l.SBOX[p>>>16&255]]^l.INV_SUB_MIX[2][l.SBOX[p>>>8&255]]^l.INV_SUB_MIX[3][l.SBOX[255&p]]}this._nRounds=r,this._keySchedule=n,this._invKeySchedule=d},d.prototype.encryptBlockRaw=function(e){return s(e=n(e),this._keySchedule,l.SUB_MIX,l.SBOX,this._nRounds)},d.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=i.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},d.prototype.decryptBlock=function(e){var t=(e=n(e))[1];e[1]=e[3],e[3]=t;var r=s(e,this._invKeySchedule,l.INV_SUB_MIX,l.INV_SBOX,this._nRounds),o=i.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},d.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=d},92356:(e,t,r)=>{var i=r(50462),n=r(92861).Buffer,o=r(56168),s=r(56698),a=r(25892),l=r(30295),d=r(45122);function c(e,t,r,s){o.call(this);var l=n.alloc(4,0);this._cipher=new i.AES(t);var c=this._cipher.encryptBlock(l);this._ghash=new a(c),r=function(e,t,r){if(12===t.length)return e._finID=n.concat([t,n.from([0,0,0,1])]),n.concat([t,n.from([0,0,0,2])]);var i=new a(r),o=t.length,s=o%16;i.update(t),s&&(s=16-s,i.update(n.alloc(s,0))),i.update(n.alloc(8,0));var l=8*o,c=n.alloc(8);c.writeUIntBE(l,0,8),i.update(c),e._finID=i.state;var u=n.from(e._finID);return d(u),u}(this,r,c),this._prev=n.from(r),this._cache=n.allocUnsafe(0),this._secCache=n.allocUnsafe(0),this._decrypt=s,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}s(c,o),c.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=n.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},c.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=l(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var i=Math.min(e.length,t.length),n=0;n{var i=r(25799),n=r(36171),o=r(3219);t.createCipher=t.Cipher=i.createCipher,t.createCipheriv=t.Cipheriv=i.createCipheriv,t.createDecipher=t.Decipher=n.createDecipher,t.createDecipheriv=t.Decipheriv=n.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(o)}},36171:(e,t,r)=>{var i=r(92356),n=r(92861).Buffer,o=r(530),s=r(50650),a=r(56168),l=r(50462),d=r(68078);function c(e,t,r){a.call(this),this._cache=new u,this._last=void 0,this._cipher=new l.AES(t),this._prev=n.from(r),this._mode=e,this._autopadding=!0}function u(){this.cache=n.allocUnsafe(0)}function p(e,t,r){var a=o[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=n.from(r)),"GCM"!==a.mode&&r.length!==a.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=n.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===a.type?new s(a.module,t,r,!0):"auth"===a.type?new i(a.module,t,r,!0):new c(a.module,t,r)}r(56698)(c,a),c.prototype._update=function(e){var t,r;this._cache.add(e);for(var i=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),i.push(r);return n.concat(i)},c.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");var r=-1;for(;++r16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},u.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=o[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var i=d(t,!1,r.key,r.iv);return p(e,i.key,i.iv)},t.createDecipheriv=p},25799:(e,t,r)=>{var i=r(530),n=r(92356),o=r(92861).Buffer,s=r(50650),a=r(56168),l=r(50462),d=r(68078);function c(e,t,r){a.call(this),this._cache=new p,this._cipher=new l.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}r(56698)(c,a),c.prototype._update=function(e){var t,r;this._cache.add(e);for(var i=[];t=this._cache.get();)r=this._mode.encrypt(this,t),i.push(r);return o.concat(i)};var u=o.alloc(16,16);function p(){this.cache=o.allocUnsafe(0)}function h(e,t,r){var a=i[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=o.from(r)),"GCM"!==a.mode&&r.length!==a.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===a.type?new s(a.module,t,r):"auth"===a.type?new n(a.module,t,r):new c(a.module,t,r)}c.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(u))throw this._cipher.scrub(),new Error("data not multiple of block length")},c.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},p.prototype.add=function(e){this.cache=o.concat([this.cache,e])},p.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},p.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),r=-1;++r{var i=r(92861).Buffer,n=i.alloc(16,0);function o(e){var t=i.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function s(e){this.h=e,this.state=i.alloc(16,0),this.cache=i.allocUnsafe(0)}s.prototype.ghash=function(e){for(var t=-1;++t0;t--)i[t]=i[t]>>>1|(1&i[t-1])<<31;i[0]=i[0]>>>1,r&&(i[0]=i[0]^225<<24)}this.state=o(n)},s.prototype.update=function(e){var t;for(this.cache=i.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},s.prototype.final=function(e,t){return this.cache.length&&this.ghash(i.concat([this.cache,n],16)),this.ghash(o([0,e,0,t])),this.state},e.exports=s},45122:e=>{e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},92884:(e,t,r)=>{var i=r(30295);t.encrypt=function(e,t){var r=i(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var n=e._cipher.decryptBlock(t);return i(n,r)}},46383:(e,t,r)=>{var i=r(92861).Buffer,n=r(30295);function o(e,t,r){var o=t.length,s=n(t,e._cache);return e._cache=e._cache.slice(o),e._prev=i.concat([e._prev,r?t:s]),s}t.encrypt=function(e,t,r){for(var n,s=i.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=i.allocUnsafe(0)),!(e._cache.length<=t.length)){s=i.concat([s,o(e,t,r)]);break}n=e._cache.length,s=i.concat([s,o(e,t.slice(0,n),r)]),t=t.slice(n)}return s}},32883:(e,t,r)=>{var i=r(92861).Buffer;function n(e,t,r){for(var i,n,s=-1,a=0;++s<8;)i=t&1<<7-s?128:0,a+=(128&(n=e._cipher.encryptBlock(e._prev)[0]^i))>>s%8,e._prev=o(e._prev,r?i:n);return a}function o(e,t){var r=e.length,n=-1,o=i.allocUnsafe(e.length);for(e=i.concat([e,i.from([t])]);++n>7;return o}t.encrypt=function(e,t,r){for(var o=t.length,s=i.allocUnsafe(o),a=-1;++a{var i=r(92861).Buffer;function n(e,t,r){var n=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=i.concat([e._prev.slice(1),i.from([r?t:n])]),n}t.encrypt=function(e,t,r){for(var o=t.length,s=i.allocUnsafe(o),a=-1;++a{var i=r(30295),n=r(92861).Buffer,o=r(45122);function s(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),o=e._cache.length;e._cache=n.concat([e._cache,n.allocUnsafe(16*r)]);for(var a=0;a{t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},530:(e,t,r)=>{var i={ECB:r(52632),CBC:r(92884),CFB:r(46383),CFB8:r(86975),CFB1:r(32883),OFB:r(46843),CTR:r(63053),GCM:r(63053)},n=r(3219);for(var o in n)n[o].module=i[n[o].mode];e.exports=n},46843:(e,t,r)=>{var i=r(48287).Buffer,n=r(30295);function o(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length{var i=r(50462),n=r(92861).Buffer,o=r(56168);function s(e,t,r,s){o.call(this),this._cipher=new i.AES(t),this._prev=n.from(r),this._cache=n.allocUnsafe(0),this._secCache=n.allocUnsafe(0),this._decrypt=s,this._mode=e}r(56698)(s,o),s.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},s.prototype._final=function(){this._cipher.scrub()},e.exports=s},30125:(e,t,r)=>{var i=r(84050),n=r(1241),o=r(530),s=r(32438),a=r(68078);function l(e,t,r){if(e=e.toLowerCase(),o[e])return n.createCipheriv(e,t,r);if(s[e])return new i({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function d(e,t,r){if(e=e.toLowerCase(),o[e])return n.createDecipheriv(e,t,r);if(s[e])return new i({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,i;if(e=e.toLowerCase(),o[e])r=o[e].key,i=o[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,i=s[e].iv}var n=a(t,!1,r,i);return l(e,n.key,n.iv)},t.createCipheriv=t.Cipheriv=l,t.createDecipher=t.Decipher=function(e,t){var r,i;if(e=e.toLowerCase(),o[e])r=o[e].key,i=o[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,i=s[e].iv}var n=a(t,!1,r,i);return d(e,n.key,n.iv)},t.createDecipheriv=t.Decipheriv=d,t.listCiphers=t.getCiphers=function(){return Object.keys(s).concat(n.getCiphers())}},84050:(e,t,r)=>{var i=r(56168),n=r(29560),o=r(56698),s=r(92861).Buffer,a={"des-ede3-cbc":n.CBC.instantiate(n.EDE),"des-ede3":n.EDE,"des-ede-cbc":n.CBC.instantiate(n.EDE),"des-ede":n.EDE,"des-cbc":n.CBC.instantiate(n.DES),"des-ecb":n.DES};function l(e){i.call(this);var t,r=e.mode.toLowerCase(),n=a[r];t=e.decrypt?"decrypt":"encrypt";var o=e.key;s.isBuffer(o)||(o=s.from(o)),"des-ede"!==r&&"des-ede-cbc"!==r||(o=s.concat([o,o.slice(0,8)]));var l=e.iv;s.isBuffer(l)||(l=s.from(l)),this._des=n.create({key:o,iv:l,type:t})}a.des=a["des-cbc"],a.des3=a["des-ede3-cbc"],e.exports=l,o(l,i),l.prototype._update=function(e){return s.from(this._des.update(e))},l.prototype._final=function(){return s.from(this._des.final())}},32438:(e,t)=>{t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},67332:(e,t,r)=>{"use strict";var i=r(39404),n=r(53209),o=r(92861).Buffer;function s(e){var t,r=e.modulus.byteLength();do{t=new i(n(r))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function a(e,t){var r=function(e){var t=s(e);return{blinder:t.toRed(i.mont(e.modulus)).redPow(new i(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),n=t.modulus.byteLength(),a=new i(e).mul(r.blinder).umod(t.modulus),l=a.toRed(i.mont(t.prime1)),d=a.toRed(i.mont(t.prime2)),c=t.coefficient,u=t.prime1,p=t.prime2,h=l.redPow(t.exponent1).fromRed(),f=d.redPow(t.exponent2).fromRed(),m=h.isub(f).imul(c).umod(u).imul(p);return f.iadd(m).imul(r.unblinder).umod(t.modulus).toArrayLike(o,"be",n)}a.getr=s,e.exports=a},55715:(e,t,r)=>{"use strict";e.exports=r(62951)},20:(e,t,r)=>{"use strict";var i=r(92861).Buffer,n=r(47108),o=r(28399),s=r(56698),a=r(35359),l=r(74847),d=r(62951);function c(e){o.Writable.call(this);var t=d[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function u(e){o.Writable.call(this);var t=d[e];if(!t)throw new Error("Unknown message digest");this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function p(e){return new c(e)}function h(e){return new u(e)}Object.keys(d).forEach((function(e){d[e].id=i.from(d[e].id,"hex"),d[e.toLowerCase()]=d[e]})),s(c,o.Writable),c.prototype._write=function(e,t,r){this._hash.update(e),r()},c.prototype.update=function(e,t){return this._hash.update("string"==typeof e?i.from(e,t):e),this},c.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),i=a(r,e,this._hashType,this._signType,this._tag);return t?i.toString(t):i},s(u,o.Writable),u.prototype._write=function(e,t,r){this._hash.update(e),r()},u.prototype.update=function(e,t){return this._hash.update("string"==typeof e?i.from(e,t):e),this},u.prototype.verify=function(e,t,r){var n="string"==typeof t?i.from(t,r):t;this.end();var o=this._hash.digest();return l(n,o,e,this._signType,this._tag)},e.exports={Sign:p,Verify:h,createSign:p,createVerify:h}},35359:(e,t,r)=>{"use strict";var i=r(92861).Buffer,n=r(83507),o=r(67332),s=r(86729).ec,a=r(39404),l=r(78170),d=r(64589);function c(e,t,r,o){if((e=i.from(e.toArray())).length0&&r.ishrn(i),r}function p(e,t,r){var o,s;do{for(o=i.alloc(0);8*o.length{"use strict";var i=r(92861).Buffer,n=r(39404),o=r(86729).ec,s=r(78170),a=r(64589);function l(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=0)throw new Error("invalid sig")}e.exports=function(e,t,r,d,c){var u=s(r);if("ec"===u.type){if("ecdsa"!==d&&"ecdsa/rsa"!==d)throw new Error("wrong public key type");return function(e,t,r){var i=a[r.data.algorithm.curve.join(".")];if(!i)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var n=new o(i),s=r.data.subjectPrivateKey.data;return n.verify(t,e,s)}(e,t,u)}if("dsa"===u.type){if("dsa"!==d)throw new Error("wrong public key type");return function(e,t,r){var i=r.data.p,o=r.data.q,a=r.data.g,d=r.data.pub_key,c=s.signature.decode(e,"der"),u=c.s,p=c.r;l(u,o),l(p,o);var h=n.mont(i),f=u.invm(o),m=a.toRed(h).redPow(new n(t).mul(f).mod(o)).fromRed().mul(d.toRed(h).redPow(p.mul(f).mod(o)).fromRed()).mod(i).mod(o);return 0===m.cmp(p)}(e,t,u)}if("rsa"!==d&&"ecdsa/rsa"!==d)throw new Error("wrong public key type");t=i.concat([c,t]);for(var p=u.modulus.byteLength(),h=[1],f=0;t.length+h.length+2{"use strict";var i=r(48287).Buffer,n=r(48287).SlowBuffer;function o(e,t){if(!i.isBuffer(e)||!i.isBuffer(t))return!1;if(e.length!==t.length)return!1;for(var r=0,n=0;n{var i=r(48287).Buffer;e.exports=function(e,t){for(var r=Math.min(e.length,t.length),n=new i(r),o=0;o{"use strict"; +/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */const i=r(67526),n=r(251),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=l,t.SlowBuffer=function(e){+e!=e&&(e=0);return l.alloc(+e)},t.INSPECT_MAX_BYTES=50;const s=2147483647;function a(e){if(e>s)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return u(e)}return d(e,t,r)}function d(e,t,r){if("string"==typeof e)return function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!l.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const r=0|m(e,t);let i=a(r);const n=i.write(e,t);n!==r&&(i=i.slice(0,n));return i}(e,t);if(ArrayBuffer.isView(e))return function(e){if(J(e,Uint8Array)){const t=new Uint8Array(e);return h(t.buffer,t.byteOffset,t.byteLength)}return p(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(J(e,ArrayBuffer)||e&&J(e.buffer,ArrayBuffer))return h(e,t,r);if("undefined"!=typeof SharedArrayBuffer&&(J(e,SharedArrayBuffer)||e&&J(e.buffer,SharedArrayBuffer)))return h(e,t,r);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const i=e.valueOf&&e.valueOf();if(null!=i&&i!==e)return l.from(i,t,r);const n=function(e){if(l.isBuffer(e)){const t=0|f(e.length),r=a(t);return 0===r.length||e.copy(r,0,0,t),r}if(void 0!==e.length)return"number"!=typeof e.length||Y(e.length)?a(0):p(e);if("Buffer"===e.type&&Array.isArray(e.data))return p(e.data)}(e);if(n)return n;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return l.from(e[Symbol.toPrimitive]("string"),t,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function c(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return c(e),a(e<0?0:0|f(e))}function p(e){const t=e.length<0?0:0|f(e.length),r=a(t);for(let i=0;i=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|e}function m(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||J(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const r=e.length,i=arguments.length>2&&!0===arguments[2];if(!i&&0===r)return 0;let n=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return W(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(e).length;default:if(n)return i?-1:W(e).length;t=(""+t).toLowerCase(),n=!0}}function g(e,t,r){let i=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return A(this,t,r);case"utf8":case"utf-8":return T(this,t,r);case"ascii":return C(this,t,r);case"latin1":case"binary":return I(this,t,r);case"base64":return E(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F(this,t,r);default:if(i)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),i=!0}}function y(e,t,r){const i=e[t];e[t]=e[r],e[r]=i}function v(e,t,r,i,n){if(0===e.length)return-1;if("string"==typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),Y(r=+r)&&(r=n?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(n)return-1;r=e.length-1}else if(r<0){if(!n)return-1;r=0}if("string"==typeof t&&(t=l.from(t,i)),l.isBuffer(t))return 0===t.length?-1:b(e,t,r,i,n);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,i,n);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,i,n){let o,s=1,a=e.length,l=t.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(e.length<2||t.length<2)return-1;s=2,a/=2,l/=2,r/=2}function d(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(n){let i=-1;for(o=r;oa&&(r=a-l),o=r;o>=0;o--){let r=!0;for(let i=0;in&&(i=n):i=n;const o=t.length;let s;for(i>o/2&&(i=o/2),s=0;s>8,n=r%256,o.push(n),o.push(i);return o}(t,e.length-r),e,r,i)}function E(e,t,r){return 0===t&&r===e.length?i.fromByteArray(e):i.fromByteArray(e.slice(t,r))}function T(e,t,r){r=Math.min(e.length,r);const i=[];let n=t;for(;n239?4:t>223?3:t>191?2:1;if(n+s<=r){let r,i,a,l;switch(s){case 1:t<128&&(o=t);break;case 2:r=e[n+1],128==(192&r)&&(l=(31&t)<<6|63&r,l>127&&(o=l));break;case 3:r=e[n+1],i=e[n+2],128==(192&r)&&128==(192&i)&&(l=(15&t)<<12|(63&r)<<6|63&i,l>2047&&(l<55296||l>57343)&&(o=l));break;case 4:r=e[n+1],i=e[n+2],a=e[n+3],128==(192&r)&&128==(192&i)&&128==(192&a)&&(l=(15&t)<<18|(63&r)<<12|(63&i)<<6|63&a,l>65535&&l<1114112&&(o=l))}}null===o?(o=65533,s=1):o>65535&&(o-=65536,i.push(o>>>10&1023|55296),o=56320|1023&o),i.push(o),n+=s}return function(e){const t=e.length;if(t<=B)return String.fromCharCode.apply(String,e);let r="",i=0;for(;ii.length?(l.isBuffer(t)||(t=l.from(t)),t.copy(i,n)):Uint8Array.prototype.set.call(i,t,n);else{if(!l.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(i,n)}n+=t.length}return i},l.byteLength=m,l.prototype._isBuffer=!0,l.prototype.swap16=function(){const e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tr&&(e+=" ... "),""},o&&(l.prototype[o]=l.prototype.inspect),l.prototype.compare=function(e,t,r,i,n){if(J(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),t<0||r>e.length||i<0||n>this.length)throw new RangeError("out of range index");if(i>=n&&t>=r)return 0;if(i>=n)return-1;if(t>=r)return 1;if(this===e)return 0;let o=(n>>>=0)-(i>>>=0),s=(r>>>=0)-(t>>>=0);const a=Math.min(o,s),d=this.slice(i,n),c=e.slice(t,r);for(let e=0;e>>=0,isFinite(r)?(r>>>=0,void 0===i&&(i="utf8")):(i=r,r=void 0)}const n=this.length-t;if((void 0===r||r>n)&&(r=n),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");let o=!1;for(;;)switch(i){case"hex":return w(this,e,t,r);case"utf8":case"utf-8":return _(this,e,t,r);case"ascii":case"latin1":case"binary":return x(this,e,t,r);case"base64":return S(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),o=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const B=4096;function C(e,t,r){let i="";r=Math.min(e.length,r);for(let n=t;ni)&&(r=i);let n="";for(let i=t;ir)throw new RangeError("Trying to access beyond buffer length")}function D(e,t,r,i,n,o){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||te.length)throw new RangeError("Index out of range")}function R(e,t,r,i,n){j(t,i,n,e,r,7);let o=Number(t&BigInt(4294967295));e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o,o>>=8,e[r++]=o;let s=Number(t>>BigInt(32)&BigInt(4294967295));return e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s,s>>=8,e[r++]=s,r}function P(e,t,r,i,n){j(t,i,n,e,r,7);let o=Number(t&BigInt(4294967295));e[r+7]=o,o>>=8,e[r+6]=o,o>>=8,e[r+5]=o,o>>=8,e[r+4]=o;let s=Number(t>>BigInt(32)&BigInt(4294967295));return e[r+3]=s,s>>=8,e[r+2]=s,s>>=8,e[r+1]=s,s>>=8,e[r]=s,r+8}function O(e,t,r,i,n,o){if(r+i>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function z(e,t,r,i,o){return t=+t,r>>>=0,o||O(e,0,r,4),n.write(e,t,r,i,23,4),r+4}function N(e,t,r,i,o){return t=+t,r>>>=0,o||O(e,0,r,8),n.write(e,t,r,i,52,8),r+8}l.prototype.slice=function(e,t){const r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t>>=0,t>>>=0,r||M(e,t,this.length);let i=this[e],n=1,o=0;for(;++o>>=0,t>>>=0,r||M(e,t,this.length);let i=this[e+--t],n=1;for(;t>0&&(n*=256);)i+=this[e+--t]*n;return i},l.prototype.readUint8=l.prototype.readUInt8=function(e,t){return e>>>=0,t||M(e,1,this.length),this[e]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||M(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||M(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||M(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||M(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readBigUInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||$(e,this.length-8);const i=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,n=this[++e]+256*this[++e]+65536*this[++e]+r*2**24;return BigInt(i)+(BigInt(n)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||$(e,this.length-8);const i=t*2**24+65536*this[++e]+256*this[++e]+this[++e],n=this[++e]*2**24+65536*this[++e]+256*this[++e]+r;return(BigInt(i)<>>=0,t>>>=0,r||M(e,t,this.length);let i=this[e],n=1,o=0;for(;++o=n&&(i-=Math.pow(2,8*t)),i},l.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||M(e,t,this.length);let i=t,n=1,o=this[e+--i];for(;i>0&&(n*=256);)o+=this[e+--i]*n;return n*=128,o>=n&&(o-=Math.pow(2,8*t)),o},l.prototype.readInt8=function(e,t){return e>>>=0,t||M(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||M(e,2,this.length);const r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},l.prototype.readInt16BE=function(e,t){e>>>=0,t||M(e,2,this.length);const r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||M(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||M(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readBigInt64LE=Z((function(e){H(e>>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||$(e,this.length-8);const i=this[e+4]+256*this[e+5]+65536*this[e+6]+(r<<24);return(BigInt(i)<>>=0,"offset");const t=this[e],r=this[e+7];void 0!==t&&void 0!==r||$(e,this.length-8);const i=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(i)<>>=0,t||M(e,4,this.length),n.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||M(e,4,this.length),n.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||M(e,8,this.length),n.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||M(e,8,this.length),n.read(this,e,!1,52,8)},l.prototype.writeUintLE=l.prototype.writeUIntLE=function(e,t,r,i){if(e=+e,t>>>=0,r>>>=0,!i){D(this,e,t,r,Math.pow(2,8*r)-1,0)}let n=1,o=0;for(this[t]=255&e;++o>>=0,r>>>=0,!i){D(this,e,t,r,Math.pow(2,8*r)-1,0)}let n=r-1,o=1;for(this[t+n]=255&e;--n>=0&&(o*=256);)this[t+n]=e/o&255;return t+r},l.prototype.writeUint8=l.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,1,255,0),this[t]=255&e,t+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeBigUInt64LE=Z((function(e,t=0){return R(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),l.prototype.writeBigUInt64BE=Z((function(e,t=0){return P(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),l.prototype.writeIntLE=function(e,t,r,i){if(e=+e,t>>>=0,!i){const i=Math.pow(2,8*r-1);D(this,e,t,r,i-1,-i)}let n=0,o=1,s=0;for(this[t]=255&e;++n>>=0,!i){const i=Math.pow(2,8*r-1);D(this,e,t,r,i-1,-i)}let n=r-1,o=1,s=0;for(this[t+n]=255&e;--n>=0&&(o*=256);)e<0&&0===s&&0!==this[t+n+1]&&(s=1),this[t+n]=(e/o|0)-s&255;return t+r},l.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},l.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||D(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeBigInt64LE=Z((function(e,t=0){return R(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),l.prototype.writeBigInt64BE=Z((function(e,t=0){return P(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),l.prototype.writeFloatLE=function(e,t,r){return z(this,e,t,!0,r)},l.prototype.writeFloatBE=function(e,t,r){return z(this,e,t,!1,r)},l.prototype.writeDoubleLE=function(e,t,r){return N(this,e,t,!0,r)},l.prototype.writeDoubleBE=function(e,t,r){return N(this,e,t,!1,r)},l.prototype.copy=function(e,t,r,i){if(!l.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),i||0===i||(i=this.length),t>=e.length&&(t=e.length),t||(t=0),i>0&&i=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-t>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(n=t;n=i+4;r-=3)t=`_${e.slice(r-3,r)}${t}`;return`${e.slice(0,r)}${t}`}function j(e,t,r,i,n,o){if(e>r||e3?0===t||t===BigInt(0)?`>= 0${i} and < 2${i} ** ${8*(o+1)}${i}`:`>= -(2${i} ** ${8*(o+1)-1}${i}) and < 2 ** ${8*(o+1)-1}${i}`:`>= ${t}${i} and <= ${r}${i}`,new q.ERR_OUT_OF_RANGE("value",n,e)}!function(e,t,r){H(t,"offset"),void 0!==e[t]&&void 0!==e[t+r]||$(t,e.length-(r+1))}(i,n,o)}function H(e,t){if("number"!=typeof e)throw new q.ERR_INVALID_ARG_TYPE(t,"number",e)}function $(e,t,r){if(Math.floor(e)!==e)throw H(e,r),new q.ERR_OUT_OF_RANGE(r||"offset","an integer",e);if(t<0)throw new q.ERR_BUFFER_OUT_OF_BOUNDS;throw new q.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${t}`,e)}U("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"}),RangeError),U("ERR_INVALID_ARG_TYPE",(function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`}),TypeError),U("ERR_OUT_OF_RANGE",(function(e,t,r){let i=`The value of "${e}" is out of range.`,n=r;return Number.isInteger(r)&&Math.abs(r)>2**32?n=L(String(r)):"bigint"==typeof r&&(n=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(n=L(n)),n+="n"),i+=` It must be ${t}. Received ${n}`,i}),RangeError);const G=/[^+/0-9A-Za-z-_]/g;function W(e,t){let r;t=t||1/0;const i=e.length;let n=null;const o=[];for(let s=0;s55295&&r<57344){if(!n){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===i){(t-=3)>-1&&o.push(239,191,189);continue}n=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),n=r;continue}r=65536+(n-55296<<10|r-56320)}else n&&(t-=3)>-1&&o.push(239,191,189);if(n=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function K(e){return i.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function V(e,t,r,i){let n;for(n=0;n=t.length||n>=e.length);++n)t[n+r]=e[n];return n}function J(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function Y(e){return e!=e}const Q=function(){const e="0123456789abcdef",t=new Array(256);for(let r=0;r<16;++r){const i=16*r;for(let n=0;n<16;++n)t[i+n]=e[r]+e[n]}return t}();function Z(e){return"undefined"==typeof BigInt?X:e}function X(){throw new Error("BigInt not supported")}},38075:(e,t,r)=>{"use strict";var i=r(70453),n=r(10487),o=n(i("String.prototype.indexOf"));e.exports=function(e,t){var r=i(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?n(r):r}},10487:(e,t,r)=>{"use strict";var i=r(66743),n=r(70453),o=r(96897),s=r(69675),a=n("%Function.prototype.apply%"),l=n("%Function.prototype.call%"),d=n("%Reflect.apply%",!0)||i.call(l,a),c=r(30655),u=n("%Math.max%");e.exports=function(e){if("function"!=typeof e)throw new s("a function is required");var t=d(i,l,arguments);return o(t,1+u(0,e.length-(arguments.length-1)),!0)};var p=function(){return d(i,a,arguments)};c?c(e.exports,"apply",{value:p}):e.exports.apply=p},56168:(e,t,r)=>{var i=r(92861).Buffer,n=r(88310).Transform,o=r(83141).I;function s(e){n.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(56698)(s,n),s.prototype.update=function(e,t,r){"string"==typeof e&&(e=i.from(e,t));var n=this._update(e);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)},s.prototype.setAutoPadding=function(){},s.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},s.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},s.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},s.prototype._transform=function(e,t,r){var i;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){i=e}finally{r(i)}},s.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},s.prototype._finalOrDigest=function(e){var t=this.__final()||i.alloc(0);return e&&(t=this._toString(t,e,!0)),t},s.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var i=this._decoder.write(e);return r&&(i+=this._decoder.end()),i},e.exports=s},5971:e=>{function t(e){if(e)return function(e){for(var r in t.prototype)e[r]=t.prototype[r];return e}(e)}e.exports=t,t.prototype.on=t.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},t.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r,i=this._callbacks["$"+e];if(!i)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n=0;n{function i(e){return Object.prototype.toString.call(e)}t.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===i(e)},t.isBoolean=function(e){return"boolean"==typeof e},t.isNull=function(e){return null===e},t.isNullOrUndefined=function(e){return null==e},t.isNumber=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=function(e){return void 0===e},t.isRegExp=function(e){return"[object RegExp]"===i(e)},t.isObject=function(e){return"object"==typeof e&&null!==e},t.isDate=function(e){return"[object Date]"===i(e)},t.isError=function(e){return"[object Error]"===i(e)||e instanceof Error},t.isFunction=function(e){return"function"==typeof e},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(48287).Buffer.isBuffer},61324:(e,t,r)=>{var i=r(48287).Buffer,n=r(86729),o=r(92801);e.exports=function(e){return new a(e)};var s={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function a(e){this.curveType=s[e],this.curveType||(this.curveType={name:e}),this.curve=new n.ec(this.curveType.name),this.keys=void 0}function l(e,t,r){Array.isArray(e)||(e=e.toArray());var n=new i(e);if(r&&n.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},47108:(e,t,r)=>{"use strict";var i=r(56698),n=r(88276),o=r(66011),s=r(62802),a=r(56168);function l(e){a.call(this,"digest"),this._hash=e}i(l,a),l.prototype._update=function(e){this._hash.update(e)},l.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new n:"rmd160"===e||"ripemd160"===e?new o:new l(s(e))}},20320:(e,t,r)=>{var i=r(88276);e.exports=function(e){return(new i).update(e).digest()}},83507:(e,t,r)=>{"use strict";var i=r(56698),n=r(41800),o=r(56168),s=r(92861).Buffer,a=r(20320),l=r(66011),d=r(62802),c=s.alloc(128);function u(e,t){o.call(this,"digest"),"string"==typeof t&&(t=s.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,this._key=t,t.length>r)?t=("rmd160"===e?new l:d(e)).update(t).digest():t.length{"use strict";var i=r(56698),n=r(92861).Buffer,o=r(56168),s=n.alloc(128),a=64;function l(e,t){o.call(this,"digest"),"string"==typeof t&&(t=n.from(t)),this._alg=e,this._key=t,t.length>a?t=e(t):t.length{"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(53209),t.createHash=t.Hash=r(47108),t.createHmac=t.Hmac=r(83507);var i=r(55715),n=Object.keys(i),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(n);t.getHashes=function(){return o};var s=r(78396);t.pbkdf2=s.pbkdf2,t.pbkdf2Sync=s.pbkdf2Sync;var a=r(30125);t.Cipher=a.Cipher,t.createCipher=a.createCipher,t.Cipheriv=a.Cipheriv,t.createCipheriv=a.createCipheriv,t.Decipher=a.Decipher,t.createDecipher=a.createDecipher,t.Decipheriv=a.Decipheriv,t.createDecipheriv=a.createDecipheriv,t.getCiphers=a.getCiphers,t.listCiphers=a.listCiphers;var l=r(15380);t.DiffieHellmanGroup=l.DiffieHellmanGroup,t.createDiffieHellmanGroup=l.createDiffieHellmanGroup,t.getDiffieHellman=l.getDiffieHellman,t.createDiffieHellman=l.createDiffieHellman,t.DiffieHellman=l.DiffieHellman;var d=r(20);t.createSign=d.createSign,t.Sign=d.Sign,t.createVerify=d.createVerify,t.Verify=d.Verify,t.createECDH=r(61324);var c=r(97168);t.publicEncrypt=c.publicEncrypt,t.privateEncrypt=c.privateEncrypt,t.publicDecrypt=c.publicDecrypt,t.privateDecrypt=c.privateDecrypt;var u=r(76983);t.randomFill=u.randomFill,t.randomFillSync=u.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},73923:(e,t,r)=>{"use strict";var i=r(88997),n=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function s(e,t,r){var o=t[r];if(null!=o){if(n.call(e,r)&&(void 0===e[r]||null===e[r]))throw new TypeError("Cannot convert undefined or null to object ("+r+")");n.call(e,r)&&i(o)?e[r]=a(Object(e[r]),t[r]):e[r]=o}}function a(e,t){if(e===t)return e;for(var r in t=Object(t))n.call(t,r)&&s(e,t,r);if(Object.getOwnPropertySymbols)for(var i=Object.getOwnPropertySymbols(t),a=0;a{"use strict";var i=r(30655),n=r(58068),o=r(69675),s=r(75795);e.exports=function(e,t,r){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new o("`obj` must be an object or a function`");if("string"!=typeof t&&"symbol"!=typeof t)throw new o("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new o("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new o("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new o("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new o("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,d=arguments.length>5?arguments[5]:null,c=arguments.length>6&&arguments[6],u=!!s&&s(e,t);if(i)i(e,t,{configurable:null===d&&u?u.configurable:!d,enumerable:null===a&&u?u.enumerable:!a,value:r,writable:null===l&&u?u.writable:!l});else{if(!c&&(a||l||d))throw new n("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");e[t]=r}}},29560:(e,t,r)=>{"use strict";t.utils=r(87626),t.Cipher=r(82808),t.DES=r(82211),t.CBC=r(3389),t.EDE=r(65279)},3389:(e,t,r)=>{"use strict";var i=r(43349),n=r(56698),o={};function s(e){i.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t{"use strict";var i=r(43349);function n(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=!1!==e.padding}e.exports=n,n.prototype._init=function(){},n.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},n.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),i=0;i0;i--)t+=this._buffer(e,t),r+=this._flushBuffer(n,r);return t+=this._buffer(e,t),n},n.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},n.prototype._pad=function(e,t){if(0===t)return!1;for(;t{"use strict";var i=r(43349),n=r(56698),o=r(87626),s=r(82808);function a(){this.tmp=new Array(2),this.keys=null}function l(e){s.call(this,e);var t=new a;this._desState=t,this.deriveKeys(t,e.key)}n(l,s),e.exports=l,l.create=function(e){return new l(e)};var d=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];l.prototype.deriveKeys=function(e,t){e.keys=new Array(32),i.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),n=o.readUInt32BE(t,4);o.pc1(r,n,e.tmp,0),r=e.tmp[0],n=e.tmp[1];for(var s=0;s>>1];r=o.r28shl(r,a),n=o.r28shl(n,a),o.pc2(r,n,e.keys,s)}},l.prototype._update=function(e,t,r,i){var n=this._desState,s=o.readUInt32BE(e,t),a=o.readUInt32BE(e,t+4);o.ip(s,a,n.tmp,0),s=n.tmp[0],a=n.tmp[1],"encrypt"===this.type?this._encrypt(n,s,a,n.tmp,0):this._decrypt(n,s,a,n.tmp,0),s=n.tmp[0],a=n.tmp[1],o.writeUInt32BE(r,s,i),o.writeUInt32BE(r,a,i+4)},l.prototype._pad=function(e,t){if(!1===this.padding)return!1;for(var r=e.length-t,i=t;i>>0,s=p}o.rip(a,s,i,n)},l.prototype._decrypt=function(e,t,r,i,n){for(var s=r,a=t,l=e.keys.length-2;l>=0;l-=2){var d=e.keys[l],c=e.keys[l+1];o.expand(s,e.tmp,0),d^=e.tmp[0],c^=e.tmp[1];var u=o.substitute(d,c),p=s;s=(a^o.permute(u))>>>0,a=p}o.rip(s,a,i,n)}},65279:(e,t,r)=>{"use strict";var i=r(43349),n=r(56698),o=r(82808),s=r(82211);function a(e,t){i.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),n=t.slice(8,16),o=t.slice(16,24);this.ciphers="encrypt"===e?[s.create({type:"encrypt",key:r}),s.create({type:"decrypt",key:n}),s.create({type:"encrypt",key:o})]:[s.create({type:"decrypt",key:o}),s.create({type:"encrypt",key:n}),s.create({type:"decrypt",key:r})]}function l(e){o.call(this,e);var t=new a(this.type,this.options.key);this._edeState=t}n(l,o),e.exports=l,l.create=function(e){return new l(e)},l.prototype._update=function(e,t,r,i){var n=this._edeState;n.ciphers[0]._update(e,t,r,i),n.ciphers[1]._update(r,i,r,i),n.ciphers[2]._update(r,i,r,i)},l.prototype._pad=s.prototype._pad,l.prototype._unpad=s.prototype._unpad},87626:(e,t)=>{"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,i){for(var n=0,o=0,s=6;s>=0;s-=2){for(var a=0;a<=24;a+=8)n<<=1,n|=t>>>a+s&1;for(a=0;a<=24;a+=8)n<<=1,n|=e>>>a+s&1}for(s=6;s>=0;s-=2){for(a=1;a<=25;a+=8)o<<=1,o|=t>>>a+s&1;for(a=1;a<=25;a+=8)o<<=1,o|=e>>>a+s&1}r[i+0]=n>>>0,r[i+1]=o>>>0},t.rip=function(e,t,r,i){for(var n=0,o=0,s=0;s<4;s++)for(var a=24;a>=0;a-=8)n<<=1,n|=t>>>a+s&1,n<<=1,n|=e>>>a+s&1;for(s=4;s<8;s++)for(a=24;a>=0;a-=8)o<<=1,o|=t>>>a+s&1,o<<=1,o|=e>>>a+s&1;r[i+0]=n>>>0,r[i+1]=o>>>0},t.pc1=function(e,t,r,i){for(var n=0,o=0,s=7;s>=5;s--){for(var a=0;a<=24;a+=8)n<<=1,n|=t>>a+s&1;for(a=0;a<=24;a+=8)n<<=1,n|=e>>a+s&1}for(a=0;a<=24;a+=8)n<<=1,n|=t>>a+s&1;for(s=1;s<=3;s++){for(a=0;a<=24;a+=8)o<<=1,o|=t>>a+s&1;for(a=0;a<=24;a+=8)o<<=1,o|=e>>a+s&1}for(a=0;a<=24;a+=8)o<<=1,o|=e>>a+s&1;r[i+0]=n>>>0,r[i+1]=o>>>0},t.r28shl=function(e,t){return e<>>28-t};var r=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];t.pc2=function(e,t,i,n){for(var o=0,s=0,a=r.length>>>1,l=0;l>>r[l]&1;for(l=a;l>>r[l]&1;i[n+0]=o>>>0,i[n+1]=s>>>0},t.expand=function(e,t,r){var i=0,n=0;i=(1&e)<<5|e>>>27;for(var o=23;o>=15;o-=4)i<<=6,i|=e>>>o&63;for(o=11;o>=3;o-=4)n|=e>>>o&63,n<<=6;n|=(31&e)<<1|e>>>31,t[r+0]=i>>>0,t[r+1]=n>>>0};var i=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];t.substitute=function(e,t){for(var r=0,n=0;n<4;n++){r<<=4,r|=i[64*n+(e>>>18-6*n&63)]}for(n=0;n<4;n++){r<<=4,r|=i[256+64*n+(t>>>18-6*n&63)]}return r>>>0};var n=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];t.permute=function(e){for(var t=0,r=0;r>>n[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var i=e.toString(2);i.length{var i=r(48287).Buffer,n=r(4934),o=r(23241),s=r(14910);var a={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new i(o[e].prime,"hex"),r=new i(o[e].gen,"hex");return new s(t,r)},t.createDiffieHellman=t.DiffieHellman=function e(t,r,o,l){return i.isBuffer(r)||void 0===a[r]?e(t,"binary",r,o):(r=r||"binary",l=l||"binary",o=o||new i([2]),i.isBuffer(o)||(o=new i(o,l)),"number"==typeof t?new s(n(t,o),o,!0):(i.isBuffer(t)||(t=new i(t,r)),new s(t,o,!0)))}},14910:(e,t,r)=>{var i=r(48287).Buffer,n=r(66473),o=new(r(52244)),s=new n(24),a=new n(11),l=new n(10),d=new n(3),c=new n(7),u=r(4934),p=r(53209);function h(e,t){return t=t||"utf8",i.isBuffer(e)||(e=new i(e,t)),this._pub=new n(e),this}function f(e,t){return t=t||"utf8",i.isBuffer(e)||(e=new i(e,t)),this._priv=new n(e),this}e.exports=g;var m={};function g(e,t,r){this.setGenerator(t),this.__prime=new n(e),this._prime=n.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=h,this.setPrivateKey=f):this._primeCode=8}function y(e,t){var r=new i(e.toArray());return t?r.toString(t):r}Object.defineProperty(g.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),i=[r,e.toString(16)].join("_");if(i in m)return m[i];var n,p=0;if(e.isEven()||!u.simpleSieve||!u.fermatTest(e)||!o.test(e))return p+=1,p+="02"===r||"05"===r?8:4,m[i]=p,p;switch(o.test(e.shrn(1))||(p+=2),r){case"02":e.mod(s).cmp(a)&&(p+=8);break;case"05":(n=e.mod(l)).cmp(d)&&n.cmp(c)&&(p+=8);break;default:p+=4}return m[i]=p,p}(this.__prime,this.__gen)),this._primeCode}}),g.prototype.generateKeys=function(){return this._priv||(this._priv=new n(p(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},g.prototype.computeSecret=function(e){var t=(e=(e=new n(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new i(t.toArray()),o=this.getPrime();if(r.length{var i=r(53209);e.exports=v,v.simpleSieve=g,v.fermatTest=y;var n=r(66473),o=new n(24),s=new(r(52244)),a=new n(1),l=new n(2),d=new n(5),c=(new n(16),new n(8),new n(10)),u=new n(3),p=(new n(7),new n(11)),h=new n(4),f=(new n(12),null);function m(){if(null!==f)return f;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var i=Math.ceil(Math.sqrt(r)),n=0;ne;)r.ishrn(1);if(r.isEven()&&r.iadd(a),r.testn(1)||r.iadd(l),t.cmp(l)){if(!t.cmp(d))for(;r.mod(c).cmp(u);)r.iadd(h)}else for(;r.mod(o).cmp(p);)r.iadd(h);if(g(f=r.shrn(1))&&g(r)&&y(f)&&y(r)&&s.test(f)&&s.test(r))return r}}},66473:function(e,t,r){!function(e,t){"use strict";function i(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var s;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(66089).Buffer}catch(e){}function a(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},76320:e=>{"use strict";var t={single_source_shortest_paths:function(e,r,i){var n={},o={};o[r]=0;var s,a,l,d,c,u,p,h=t.PriorityQueue.make();for(h.push(r,0);!h.empty();)for(l in a=(s=h.pop()).value,d=s.cost,c=e[a]||{})c.hasOwnProperty(l)&&(u=d+c[l],p=o[l],(void 0===o[l]||p>u)&&(o[l]=u,h.push(l,u),n[l]=a));if(void 0!==i&&void 0===o[i]){var f=["Could not find a path from ",r," to ",i,"."].join("");throw new Error(f)}return n},extract_shortest_path_from_predecessor_list:function(e,t){for(var r=[],i=t;i;)r.push(i),e[i],i=e[i];return r.reverse(),r},find_path:function(e,r,i){var n=t.single_source_shortest_paths(e,r,i);return t.extract_shortest_path_from_predecessor_list(n,i)},PriorityQueue:{make:function(e){var r,i=t.PriorityQueue,n={};for(r in e=e||{},i)i.hasOwnProperty(r)&&(n[r]=i[r]);return n.queue=[],n.sorter=e.sorter||i.default_sorter,n},default_sorter:function(e,t){return e.cost-t.cost},push:function(e,t){var r={value:e,cost:t};this.queue.push(r),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};e.exports=t},34783:function(e,t,r){var i=r(48287).Buffer;!function(e){"use strict";function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function o(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}function d(e,t,r){return(d=l()?Reflect.construct:function(e,t,r){var i=[null];i.push.apply(i,t);var n=new(Function.bind.apply(e,i));return r&&a(n,r.prototype),n}).apply(null,arguments)}function c(e){var t="function"==typeof Map?new Map:void 0;return(c=function(e){if(null===e||-1===Function.toString.call(e).indexOf("[native code]"))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return d(e,arguments,s(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),a(r,e)})(e)}function u(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}var p="app",h="user",f="team",m="dropboxapi.com",g="dropbox.com",y={api:"api",notify:"bolt",content:"api-content"},v={};function b(e){var t="000".concat(e.charCodeAt(0).toString(16)).slice(-4);return"\\u".concat(t)}v.accountSetProfilePhoto=function(e){return this.request("account/set_profile_photo",e,"user","api","rpc","account_info.write")},v.authTokenFromOauth1=function(e){return this.request("auth/token/from_oauth1",e,"app","api","rpc",null)},v.authTokenRevoke=function(){return this.request("auth/token/revoke",null,"user","api","rpc",null)},v.checkApp=function(e){return this.request("check/app",e,"app","api","rpc",null)},v.checkUser=function(e){return this.request("check/user",e,"user","api","rpc","account_info.read")},v.contactsDeleteManualContacts=function(){return this.request("contacts/delete_manual_contacts",null,"user","api","rpc","contacts.write")},v.contactsDeleteManualContactsBatch=function(e){return this.request("contacts/delete_manual_contacts_batch",e,"user","api","rpc","contacts.write")},v.filePropertiesPropertiesAdd=function(e){return this.request("file_properties/properties/add",e,"user","api","rpc","files.metadata.write")},v.filePropertiesPropertiesOverwrite=function(e){return this.request("file_properties/properties/overwrite",e,"user","api","rpc","files.metadata.write")},v.filePropertiesPropertiesRemove=function(e){return this.request("file_properties/properties/remove",e,"user","api","rpc","files.metadata.write")},v.filePropertiesPropertiesSearch=function(e){return this.request("file_properties/properties/search",e,"user","api","rpc","files.metadata.read")},v.filePropertiesPropertiesSearchContinue=function(e){return this.request("file_properties/properties/search/continue",e,"user","api","rpc","files.metadata.read")},v.filePropertiesPropertiesUpdate=function(e){return this.request("file_properties/properties/update",e,"user","api","rpc","files.metadata.write")},v.filePropertiesTemplatesAddForTeam=function(e){return this.request("file_properties/templates/add_for_team",e,"team","api","rpc","files.team_metadata.write")},v.filePropertiesTemplatesAddForUser=function(e){return this.request("file_properties/templates/add_for_user",e,"user","api","rpc","files.metadata.write")},v.filePropertiesTemplatesGetForTeam=function(e){return this.request("file_properties/templates/get_for_team",e,"team","api","rpc","files.team_metadata.write")},v.filePropertiesTemplatesGetForUser=function(e){return this.request("file_properties/templates/get_for_user",e,"user","api","rpc","files.metadata.read")},v.filePropertiesTemplatesListForTeam=function(){return this.request("file_properties/templates/list_for_team",null,"team","api","rpc","files.team_metadata.write")},v.filePropertiesTemplatesListForUser=function(){return this.request("file_properties/templates/list_for_user",null,"user","api","rpc","files.metadata.read")},v.filePropertiesTemplatesRemoveForTeam=function(e){return this.request("file_properties/templates/remove_for_team",e,"team","api","rpc","files.team_metadata.write")},v.filePropertiesTemplatesRemoveForUser=function(e){return this.request("file_properties/templates/remove_for_user",e,"user","api","rpc","files.metadata.write")},v.filePropertiesTemplatesUpdateForTeam=function(e){return this.request("file_properties/templates/update_for_team",e,"team","api","rpc","files.team_metadata.write")},v.filePropertiesTemplatesUpdateForUser=function(e){return this.request("file_properties/templates/update_for_user",e,"user","api","rpc","files.metadata.write")},v.fileRequestsCount=function(){return this.request("file_requests/count",null,"user","api","rpc","file_requests.read")},v.fileRequestsCreate=function(e){return this.request("file_requests/create",e,"user","api","rpc","file_requests.write")},v.fileRequestsDelete=function(e){return this.request("file_requests/delete",e,"user","api","rpc","file_requests.write")},v.fileRequestsDeleteAllClosed=function(){return this.request("file_requests/delete_all_closed",null,"user","api","rpc","file_requests.write")},v.fileRequestsGet=function(e){return this.request("file_requests/get",e,"user","api","rpc","file_requests.read")},v.fileRequestsListV2=function(e){return this.request("file_requests/list_v2",e,"user","api","rpc","file_requests.read")},v.fileRequestsList=function(){return this.request("file_requests/list",null,"user","api","rpc","file_requests.read")},v.fileRequestsListContinue=function(e){return this.request("file_requests/list/continue",e,"user","api","rpc","file_requests.read")},v.fileRequestsUpdate=function(e){return this.request("file_requests/update",e,"user","api","rpc","file_requests.write")},v.filesAlphaGetMetadata=function(e){return this.request("files/alpha/get_metadata",e,"user","api","rpc","files.metadata.read")},v.filesAlphaUpload=function(e){return this.request("files/alpha/upload",e,"user","content","upload","files.content.write")},v.filesCopyV2=function(e){return this.request("files/copy_v2",e,"user","api","rpc","files.content.write")},v.filesCopy=function(e){return this.request("files/copy",e,"user","api","rpc","files.content.write")},v.filesCopyBatchV2=function(e){return this.request("files/copy_batch_v2",e,"user","api","rpc","files.content.write")},v.filesCopyBatch=function(e){return this.request("files/copy_batch",e,"user","api","rpc","files.content.write")},v.filesCopyBatchCheckV2=function(e){return this.request("files/copy_batch/check_v2",e,"user","api","rpc","files.content.write")},v.filesCopyBatchCheck=function(e){return this.request("files/copy_batch/check",e,"user","api","rpc","files.content.write")},v.filesCopyReferenceGet=function(e){return this.request("files/copy_reference/get",e,"user","api","rpc","files.content.write")},v.filesCopyReferenceSave=function(e){return this.request("files/copy_reference/save",e,"user","api","rpc","files.content.write")},v.filesCreateFolderV2=function(e){return this.request("files/create_folder_v2",e,"user","api","rpc","files.content.write")},v.filesCreateFolder=function(e){return this.request("files/create_folder",e,"user","api","rpc","files.content.write")},v.filesCreateFolderBatch=function(e){return this.request("files/create_folder_batch",e,"user","api","rpc","files.content.write")},v.filesCreateFolderBatchCheck=function(e){return this.request("files/create_folder_batch/check",e,"user","api","rpc","files.content.write")},v.filesDeleteV2=function(e){return this.request("files/delete_v2",e,"user","api","rpc","files.content.write")},v.filesDelete=function(e){return this.request("files/delete",e,"user","api","rpc","files.content.write")},v.filesDeleteBatch=function(e){return this.request("files/delete_batch",e,"user","api","rpc","files.content.write")},v.filesDeleteBatchCheck=function(e){return this.request("files/delete_batch/check",e,"user","api","rpc","files.content.write")},v.filesDownload=function(e){return this.request("files/download",e,"user","content","download","files.content.read")},v.filesDownloadZip=function(e){return this.request("files/download_zip",e,"user","content","download","files.content.read")},v.filesExport=function(e){return this.request("files/export",e,"user","content","download","files.content.read")},v.filesGetFileLockBatch=function(e){return this.request("files/get_file_lock_batch",e,"user","api","rpc","files.content.read")},v.filesGetMetadata=function(e){return this.request("files/get_metadata",e,"user","api","rpc","files.metadata.read")},v.filesGetPreview=function(e){return this.request("files/get_preview",e,"user","content","download","files.content.read")},v.filesGetTemporaryLink=function(e){return this.request("files/get_temporary_link",e,"user","api","rpc","files.content.read")},v.filesGetTemporaryUploadLink=function(e){return this.request("files/get_temporary_upload_link",e,"user","api","rpc","files.content.write")},v.filesGetThumbnail=function(e){return this.request("files/get_thumbnail",e,"user","content","download","files.content.read")},v.filesGetThumbnailV2=function(e){return this.request("files/get_thumbnail_v2",e,"app, user","content","download","files.content.read")},v.filesGetThumbnailBatch=function(e){return this.request("files/get_thumbnail_batch",e,"user","content","rpc","files.content.read")},v.filesListFolder=function(e){return this.request("files/list_folder",e,"app, user","api","rpc","files.metadata.read")},v.filesListFolderContinue=function(e){return this.request("files/list_folder/continue",e,"app, user","api","rpc","files.metadata.read")},v.filesListFolderGetLatestCursor=function(e){return this.request("files/list_folder/get_latest_cursor",e,"user","api","rpc","files.metadata.read")},v.filesListFolderLongpoll=function(e){return this.request("files/list_folder/longpoll",e,"noauth","notify","rpc","files.metadata.read")},v.filesListRevisions=function(e){return this.request("files/list_revisions",e,"user","api","rpc","files.metadata.read")},v.filesLockFileBatch=function(e){return this.request("files/lock_file_batch",e,"user","api","rpc","files.content.write")},v.filesMoveV2=function(e){return this.request("files/move_v2",e,"user","api","rpc","files.content.write")},v.filesMove=function(e){return this.request("files/move",e,"user","api","rpc","files.content.write")},v.filesMoveBatchV2=function(e){return this.request("files/move_batch_v2",e,"user","api","rpc","files.content.write")},v.filesMoveBatch=function(e){return this.request("files/move_batch",e,"user","api","rpc","files.content.write")},v.filesMoveBatchCheckV2=function(e){return this.request("files/move_batch/check_v2",e,"user","api","rpc","files.content.write")},v.filesMoveBatchCheck=function(e){return this.request("files/move_batch/check",e,"user","api","rpc","files.content.write")},v.filesPaperCreate=function(e){return this.request("files/paper/create",e,"user","api","upload","files.content.write")},v.filesPaperUpdate=function(e){return this.request("files/paper/update",e,"user","api","upload","files.content.write")},v.filesPermanentlyDelete=function(e){return this.request("files/permanently_delete",e,"user","api","rpc","files.permanent_delete")},v.filesPropertiesAdd=function(e){return this.request("files/properties/add",e,"user","api","rpc","files.metadata.write")},v.filesPropertiesOverwrite=function(e){return this.request("files/properties/overwrite",e,"user","api","rpc","files.metadata.write")},v.filesPropertiesRemove=function(e){return this.request("files/properties/remove",e,"user","api","rpc","files.metadata.write")},v.filesPropertiesTemplateGet=function(e){return this.request("files/properties/template/get",e,"user","api","rpc","files.metadata.read")},v.filesPropertiesTemplateList=function(){return this.request("files/properties/template/list",null,"user","api","rpc","files.metadata.read")},v.filesPropertiesUpdate=function(e){return this.request("files/properties/update",e,"user","api","rpc","files.metadata.write")},v.filesRestore=function(e){return this.request("files/restore",e,"user","api","rpc","files.content.write")},v.filesSaveUrl=function(e){return this.request("files/save_url",e,"user","api","rpc","files.content.write")},v.filesSaveUrlCheckJobStatus=function(e){return this.request("files/save_url/check_job_status",e,"user","api","rpc","files.content.write")},v.filesSearch=function(e){return this.request("files/search",e,"user","api","rpc","files.metadata.read")},v.filesSearchV2=function(e){return this.request("files/search_v2",e,"user","api","rpc","files.metadata.read")},v.filesSearchContinueV2=function(e){return this.request("files/search/continue_v2",e,"user","api","rpc","files.metadata.read")},v.filesTagsAdd=function(e){return this.request("files/tags/add",e,"user","api","rpc","files.metadata.write")},v.filesTagsGet=function(e){return this.request("files/tags/get",e,"user","api","rpc","files.metadata.read")},v.filesTagsRemove=function(e){return this.request("files/tags/remove",e,"user","api","rpc","files.metadata.write")},v.filesUnlockFileBatch=function(e){return this.request("files/unlock_file_batch",e,"user","api","rpc","files.content.write")},v.filesUpload=function(e){return this.request("files/upload",e,"user","content","upload","files.content.write")},v.filesUploadSessionAppendV2=function(e){return this.request("files/upload_session/append_v2",e,"user","content","upload","files.content.write")},v.filesUploadSessionAppend=function(e){return this.request("files/upload_session/append",e,"user","content","upload","files.content.write")},v.filesUploadSessionFinish=function(e){return this.request("files/upload_session/finish",e,"user","content","upload","files.content.write")},v.filesUploadSessionFinishBatch=function(e){return this.request("files/upload_session/finish_batch",e,"user","api","rpc","files.content.write")},v.filesUploadSessionFinishBatchV2=function(e){return this.request("files/upload_session/finish_batch_v2",e,"user","api","rpc","files.content.write")},v.filesUploadSessionFinishBatchCheck=function(e){return this.request("files/upload_session/finish_batch/check",e,"user","api","rpc","files.content.write")},v.filesUploadSessionStart=function(e){return this.request("files/upload_session/start",e,"user","content","upload","files.content.write")},v.filesUploadSessionStartBatch=function(e){return this.request("files/upload_session/start_batch",e,"user","api","rpc","files.content.write")},v.openidUserinfo=function(e){return this.request("openid/userinfo",e,"user","api","rpc","openid")},v.paperDocsArchive=function(e){return this.request("paper/docs/archive",e,"user","api","rpc","files.content.write")},v.paperDocsCreate=function(e){return this.request("paper/docs/create",e,"user","api","upload","files.content.write")},v.paperDocsDownload=function(e){return this.request("paper/docs/download",e,"user","api","download","files.content.read")},v.paperDocsFolderUsersList=function(e){return this.request("paper/docs/folder_users/list",e,"user","api","rpc","sharing.read")},v.paperDocsFolderUsersListContinue=function(e){return this.request("paper/docs/folder_users/list/continue",e,"user","api","rpc","sharing.read")},v.paperDocsGetFolderInfo=function(e){return this.request("paper/docs/get_folder_info",e,"user","api","rpc","sharing.read")},v.paperDocsList=function(e){return this.request("paper/docs/list",e,"user","api","rpc","files.metadata.read")},v.paperDocsListContinue=function(e){return this.request("paper/docs/list/continue",e,"user","api","rpc","files.metadata.read")},v.paperDocsPermanentlyDelete=function(e){return this.request("paper/docs/permanently_delete",e,"user","api","rpc","files.permanent_delete")},v.paperDocsSharingPolicyGet=function(e){return this.request("paper/docs/sharing_policy/get",e,"user","api","rpc","sharing.read")},v.paperDocsSharingPolicySet=function(e){return this.request("paper/docs/sharing_policy/set",e,"user","api","rpc","sharing.write")},v.paperDocsUpdate=function(e){return this.request("paper/docs/update",e,"user","api","upload","files.content.write")},v.paperDocsUsersAdd=function(e){return this.request("paper/docs/users/add",e,"user","api","rpc","sharing.write")},v.paperDocsUsersList=function(e){return this.request("paper/docs/users/list",e,"user","api","rpc","sharing.read")},v.paperDocsUsersListContinue=function(e){return this.request("paper/docs/users/list/continue",e,"user","api","rpc","sharing.read")},v.paperDocsUsersRemove=function(e){return this.request("paper/docs/users/remove",e,"user","api","rpc","sharing.write")},v.paperFoldersCreate=function(e){return this.request("paper/folders/create",e,"user","api","rpc","files.content.write")},v.sharingAddFileMember=function(e){return this.request("sharing/add_file_member",e,"user","api","rpc","sharing.write")},v.sharingAddFolderMember=function(e){return this.request("sharing/add_folder_member",e,"user","api","rpc","sharing.write")},v.sharingCheckJobStatus=function(e){return this.request("sharing/check_job_status",e,"user","api","rpc","sharing.write")},v.sharingCheckRemoveMemberJobStatus=function(e){return this.request("sharing/check_remove_member_job_status",e,"user","api","rpc","sharing.write")},v.sharingCheckShareJobStatus=function(e){return this.request("sharing/check_share_job_status",e,"user","api","rpc","sharing.write")},v.sharingCreateSharedLink=function(e){return this.request("sharing/create_shared_link",e,"user","api","rpc","sharing.write")},v.sharingCreateSharedLinkWithSettings=function(e){return this.request("sharing/create_shared_link_with_settings",e,"user","api","rpc","sharing.write")},v.sharingGetFileMetadata=function(e){return this.request("sharing/get_file_metadata",e,"user","api","rpc","sharing.read")},v.sharingGetFileMetadataBatch=function(e){return this.request("sharing/get_file_metadata/batch",e,"user","api","rpc","sharing.read")},v.sharingGetFolderMetadata=function(e){return this.request("sharing/get_folder_metadata",e,"user","api","rpc","sharing.read")},v.sharingGetSharedLinkFile=function(e){return this.request("sharing/get_shared_link_file",e,"user","content","download","sharing.read")},v.sharingGetSharedLinkMetadata=function(e){return this.request("sharing/get_shared_link_metadata",e,"app, user","api","rpc","sharing.read")},v.sharingGetSharedLinks=function(e){return this.request("sharing/get_shared_links",e,"user","api","rpc","sharing.read")},v.sharingListFileMembers=function(e){return this.request("sharing/list_file_members",e,"user","api","rpc","sharing.read")},v.sharingListFileMembersBatch=function(e){return this.request("sharing/list_file_members/batch",e,"user","api","rpc","sharing.read")},v.sharingListFileMembersContinue=function(e){return this.request("sharing/list_file_members/continue",e,"user","api","rpc","sharing.read")},v.sharingListFolderMembers=function(e){return this.request("sharing/list_folder_members",e,"user","api","rpc","sharing.read")},v.sharingListFolderMembersContinue=function(e){return this.request("sharing/list_folder_members/continue",e,"user","api","rpc","sharing.read")},v.sharingListFolders=function(e){return this.request("sharing/list_folders",e,"user","api","rpc","sharing.read")},v.sharingListFoldersContinue=function(e){return this.request("sharing/list_folders/continue",e,"user","api","rpc","sharing.read")},v.sharingListMountableFolders=function(e){return this.request("sharing/list_mountable_folders",e,"user","api","rpc","sharing.read")},v.sharingListMountableFoldersContinue=function(e){return this.request("sharing/list_mountable_folders/continue",e,"user","api","rpc","sharing.read")},v.sharingListReceivedFiles=function(e){return this.request("sharing/list_received_files",e,"user","api","rpc","sharing.read")},v.sharingListReceivedFilesContinue=function(e){return this.request("sharing/list_received_files/continue",e,"user","api","rpc","sharing.read")},v.sharingListSharedLinks=function(e){return this.request("sharing/list_shared_links",e,"user","api","rpc","sharing.read")},v.sharingModifySharedLinkSettings=function(e){return this.request("sharing/modify_shared_link_settings",e,"user","api","rpc","sharing.write")},v.sharingMountFolder=function(e){return this.request("sharing/mount_folder",e,"user","api","rpc","sharing.write")},v.sharingRelinquishFileMembership=function(e){return this.request("sharing/relinquish_file_membership",e,"user","api","rpc","sharing.write")},v.sharingRelinquishFolderMembership=function(e){return this.request("sharing/relinquish_folder_membership",e,"user","api","rpc","sharing.write")},v.sharingRemoveFileMember=function(e){return this.request("sharing/remove_file_member",e,"user","api","rpc","sharing.write")},v.sharingRemoveFileMember2=function(e){return this.request("sharing/remove_file_member_2",e,"user","api","rpc","sharing.write")},v.sharingRemoveFolderMember=function(e){return this.request("sharing/remove_folder_member",e,"user","api","rpc","sharing.write")},v.sharingRevokeSharedLink=function(e){return this.request("sharing/revoke_shared_link",e,"user","api","rpc","sharing.write")},v.sharingSetAccessInheritance=function(e){return this.request("sharing/set_access_inheritance",e,"user","api","rpc","sharing.write")},v.sharingShareFolder=function(e){return this.request("sharing/share_folder",e,"user","api","rpc","sharing.write")},v.sharingTransferFolder=function(e){return this.request("sharing/transfer_folder",e,"user","api","rpc","sharing.write")},v.sharingUnmountFolder=function(e){return this.request("sharing/unmount_folder",e,"user","api","rpc","sharing.write")},v.sharingUnshareFile=function(e){return this.request("sharing/unshare_file",e,"user","api","rpc","sharing.write")},v.sharingUnshareFolder=function(e){return this.request("sharing/unshare_folder",e,"user","api","rpc","sharing.write")},v.sharingUpdateFileMember=function(e){return this.request("sharing/update_file_member",e,"user","api","rpc","sharing.write")},v.sharingUpdateFolderMember=function(e){return this.request("sharing/update_folder_member",e,"user","api","rpc","sharing.write")},v.sharingUpdateFolderPolicy=function(e){return this.request("sharing/update_folder_policy",e,"user","api","rpc","sharing.write")},v.teamDevicesListMemberDevices=function(e){return this.request("team/devices/list_member_devices",e,"team","api","rpc","sessions.list")},v.teamDevicesListMembersDevices=function(e){return this.request("team/devices/list_members_devices",e,"team","api","rpc","sessions.list")},v.teamDevicesListTeamDevices=function(e){return this.request("team/devices/list_team_devices",e,"team","api","rpc","sessions.list")},v.teamDevicesRevokeDeviceSession=function(e){return this.request("team/devices/revoke_device_session",e,"team","api","rpc","sessions.modify")},v.teamDevicesRevokeDeviceSessionBatch=function(e){return this.request("team/devices/revoke_device_session_batch",e,"team","api","rpc","sessions.modify")},v.teamFeaturesGetValues=function(e){return this.request("team/features/get_values",e,"team","api","rpc","team_info.read")},v.teamGetInfo=function(){return this.request("team/get_info",null,"team","api","rpc","team_info.read")},v.teamGroupsCreate=function(e){return this.request("team/groups/create",e,"team","api","rpc","groups.write")},v.teamGroupsDelete=function(e){return this.request("team/groups/delete",e,"team","api","rpc","groups.write")},v.teamGroupsGetInfo=function(e){return this.request("team/groups/get_info",e,"team","api","rpc","groups.read")},v.teamGroupsJobStatusGet=function(e){return this.request("team/groups/job_status/get",e,"team","api","rpc","groups.write")},v.teamGroupsList=function(e){return this.request("team/groups/list",e,"team","api","rpc","groups.read")},v.teamGroupsListContinue=function(e){return this.request("team/groups/list/continue",e,"team","api","rpc","groups.read")},v.teamGroupsMembersAdd=function(e){return this.request("team/groups/members/add",e,"team","api","rpc","groups.write")},v.teamGroupsMembersList=function(e){return this.request("team/groups/members/list",e,"team","api","rpc","groups.read")},v.teamGroupsMembersListContinue=function(e){return this.request("team/groups/members/list/continue",e,"team","api","rpc","groups.read")},v.teamGroupsMembersRemove=function(e){return this.request("team/groups/members/remove",e,"team","api","rpc","groups.write")},v.teamGroupsMembersSetAccessType=function(e){return this.request("team/groups/members/set_access_type",e,"team","api","rpc","groups.write")},v.teamGroupsUpdate=function(e){return this.request("team/groups/update",e,"team","api","rpc","groups.write")},v.teamLegalHoldsCreatePolicy=function(e){return this.request("team/legal_holds/create_policy",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsGetPolicy=function(e){return this.request("team/legal_holds/get_policy",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsListHeldRevisions=function(e){return this.request("team/legal_holds/list_held_revisions",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsListHeldRevisionsContinue=function(e){return this.request("team/legal_holds/list_held_revisions_continue",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsListPolicies=function(e){return this.request("team/legal_holds/list_policies",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsReleasePolicy=function(e){return this.request("team/legal_holds/release_policy",e,"team","api","rpc","team_data.governance.write")},v.teamLegalHoldsUpdatePolicy=function(e){return this.request("team/legal_holds/update_policy",e,"team","api","rpc","team_data.governance.write")},v.teamLinkedAppsListMemberLinkedApps=function(e){return this.request("team/linked_apps/list_member_linked_apps",e,"team","api","rpc","sessions.list")},v.teamLinkedAppsListMembersLinkedApps=function(e){return this.request("team/linked_apps/list_members_linked_apps",e,"team","api","rpc","sessions.list")},v.teamLinkedAppsListTeamLinkedApps=function(e){return this.request("team/linked_apps/list_team_linked_apps",e,"team","api","rpc","sessions.list")},v.teamLinkedAppsRevokeLinkedApp=function(e){return this.request("team/linked_apps/revoke_linked_app",e,"team","api","rpc","sessions.modify")},v.teamLinkedAppsRevokeLinkedAppBatch=function(e){return this.request("team/linked_apps/revoke_linked_app_batch",e,"team","api","rpc","sessions.modify")},v.teamMemberSpaceLimitsExcludedUsersAdd=function(e){return this.request("team/member_space_limits/excluded_users/add",e,"team","api","rpc","members.write")},v.teamMemberSpaceLimitsExcludedUsersList=function(e){return this.request("team/member_space_limits/excluded_users/list",e,"team","api","rpc","members.read")},v.teamMemberSpaceLimitsExcludedUsersListContinue=function(e){return this.request("team/member_space_limits/excluded_users/list/continue",e,"team","api","rpc","members.read")},v.teamMemberSpaceLimitsExcludedUsersRemove=function(e){return this.request("team/member_space_limits/excluded_users/remove",e,"team","api","rpc","members.write")},v.teamMemberSpaceLimitsGetCustomQuota=function(e){return this.request("team/member_space_limits/get_custom_quota",e,"team","api","rpc","members.read")},v.teamMemberSpaceLimitsRemoveCustomQuota=function(e){return this.request("team/member_space_limits/remove_custom_quota",e,"team","api","rpc","members.write")},v.teamMemberSpaceLimitsSetCustomQuota=function(e){return this.request("team/member_space_limits/set_custom_quota",e,"team","api","rpc","members.read")},v.teamMembersAddV2=function(e){return this.request("team/members/add_v2",e,"team","api","rpc","members.write")},v.teamMembersAdd=function(e){return this.request("team/members/add",e,"team","api","rpc","members.write")},v.teamMembersAddJobStatusGetV2=function(e){return this.request("team/members/add/job_status/get_v2",e,"team","api","rpc","members.write")},v.teamMembersAddJobStatusGet=function(e){return this.request("team/members/add/job_status/get",e,"team","api","rpc","members.write")},v.teamMembersDeleteProfilePhotoV2=function(e){return this.request("team/members/delete_profile_photo_v2",e,"team","api","rpc","members.write")},v.teamMembersDeleteProfilePhoto=function(e){return this.request("team/members/delete_profile_photo",e,"team","api","rpc","members.write")},v.teamMembersGetAvailableTeamMemberRoles=function(){return this.request("team/members/get_available_team_member_roles",null,"team","api","rpc","members.read")},v.teamMembersGetInfoV2=function(e){return this.request("team/members/get_info_v2",e,"team","api","rpc","members.read")},v.teamMembersGetInfo=function(e){return this.request("team/members/get_info",e,"team","api","rpc","members.read")},v.teamMembersListV2=function(e){return this.request("team/members/list_v2",e,"team","api","rpc","members.read")},v.teamMembersList=function(e){return this.request("team/members/list",e,"team","api","rpc","members.read")},v.teamMembersListContinueV2=function(e){return this.request("team/members/list/continue_v2",e,"team","api","rpc","members.read")},v.teamMembersListContinue=function(e){return this.request("team/members/list/continue",e,"team","api","rpc","members.read")},v.teamMembersMoveFormerMemberFiles=function(e){return this.request("team/members/move_former_member_files",e,"team","api","rpc","members.write")},v.teamMembersMoveFormerMemberFilesJobStatusCheck=function(e){return this.request("team/members/move_former_member_files/job_status/check",e,"team","api","rpc","members.write")},v.teamMembersRecover=function(e){return this.request("team/members/recover",e,"team","api","rpc","members.delete")},v.teamMembersRemove=function(e){return this.request("team/members/remove",e,"team","api","rpc","members.delete")},v.teamMembersRemoveJobStatusGet=function(e){return this.request("team/members/remove/job_status/get",e,"team","api","rpc","members.delete")},v.teamMembersSecondaryEmailsAdd=function(e){return this.request("team/members/secondary_emails/add",e,"team","api","rpc","members.write")},v.teamMembersSecondaryEmailsDelete=function(e){return this.request("team/members/secondary_emails/delete",e,"team","api","rpc","members.write")},v.teamMembersSecondaryEmailsResendVerificationEmails=function(e){return this.request("team/members/secondary_emails/resend_verification_emails",e,"team","api","rpc","members.write")},v.teamMembersSendWelcomeEmail=function(e){return this.request("team/members/send_welcome_email",e,"team","api","rpc","members.write")},v.teamMembersSetAdminPermissionsV2=function(e){return this.request("team/members/set_admin_permissions_v2",e,"team","api","rpc","members.write")},v.teamMembersSetAdminPermissions=function(e){return this.request("team/members/set_admin_permissions",e,"team","api","rpc","members.write")},v.teamMembersSetProfileV2=function(e){return this.request("team/members/set_profile_v2",e,"team","api","rpc","members.write")},v.teamMembersSetProfile=function(e){return this.request("team/members/set_profile",e,"team","api","rpc","members.write")},v.teamMembersSetProfilePhotoV2=function(e){return this.request("team/members/set_profile_photo_v2",e,"team","api","rpc","members.write")},v.teamMembersSetProfilePhoto=function(e){return this.request("team/members/set_profile_photo",e,"team","api","rpc","members.write")},v.teamMembersSuspend=function(e){return this.request("team/members/suspend",e,"team","api","rpc","members.write")},v.teamMembersUnsuspend=function(e){return this.request("team/members/unsuspend",e,"team","api","rpc","members.write")},v.teamNamespacesList=function(e){return this.request("team/namespaces/list",e,"team","api","rpc","team_data.member")},v.teamNamespacesListContinue=function(e){return this.request("team/namespaces/list/continue",e,"team","api","rpc","team_data.member")},v.teamPropertiesTemplateAdd=function(e){return this.request("team/properties/template/add",e,"team","api","rpc","files.team_metadata.write")},v.teamPropertiesTemplateGet=function(e){return this.request("team/properties/template/get",e,"team","api","rpc","files.team_metadata.write")},v.teamPropertiesTemplateList=function(){return this.request("team/properties/template/list",null,"team","api","rpc","files.team_metadata.write")},v.teamPropertiesTemplateUpdate=function(e){return this.request("team/properties/template/update",e,"team","api","rpc","files.team_metadata.write")},v.teamReportsGetActivity=function(e){return this.request("team/reports/get_activity",e,"team","api","rpc","team_info.read")},v.teamReportsGetDevices=function(e){return this.request("team/reports/get_devices",e,"team","api","rpc","team_info.read")},v.teamReportsGetMembership=function(e){return this.request("team/reports/get_membership",e,"team","api","rpc","team_info.read")},v.teamReportsGetStorage=function(e){return this.request("team/reports/get_storage",e,"team","api","rpc","team_info.read")},v.teamSharingAllowlistAdd=function(e){return this.request("team/sharing_allowlist/add",e,"team","api","rpc","team_info.write")},v.teamSharingAllowlistList=function(e){return this.request("team/sharing_allowlist/list",e,"team","api","rpc","team_info.read")},v.teamSharingAllowlistListContinue=function(e){return this.request("team/sharing_allowlist/list/continue",e,"team","api","rpc","team_info.read")},v.teamSharingAllowlistRemove=function(e){return this.request("team/sharing_allowlist/remove",e,"team","api","rpc","team_info.write")},v.teamTeamFolderActivate=function(e){return this.request("team/team_folder/activate",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderArchive=function(e){return this.request("team/team_folder/archive",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderArchiveCheck=function(e){return this.request("team/team_folder/archive/check",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderCreate=function(e){return this.request("team/team_folder/create",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderGetInfo=function(e){return this.request("team/team_folder/get_info",e,"team","api","rpc","team_data.content.read")},v.teamTeamFolderList=function(e){return this.request("team/team_folder/list",e,"team","api","rpc","team_data.content.read")},v.teamTeamFolderListContinue=function(e){return this.request("team/team_folder/list/continue",e,"team","api","rpc","team_data.content.read")},v.teamTeamFolderPermanentlyDelete=function(e){return this.request("team/team_folder/permanently_delete",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderRename=function(e){return this.request("team/team_folder/rename",e,"team","api","rpc","team_data.content.write")},v.teamTeamFolderUpdateSyncSettings=function(e){return this.request("team/team_folder/update_sync_settings",e,"team","api","rpc","team_data.content.write")},v.teamTokenGetAuthenticatedAdmin=function(){return this.request("team/token/get_authenticated_admin",null,"team","api","rpc","team_info.read")},v.teamLogGetEvents=function(e){return this.request("team_log/get_events",e,"team","api","rpc","events.read")},v.teamLogGetEventsContinue=function(e){return this.request("team_log/get_events/continue",e,"team","api","rpc","events.read")},v.usersFeaturesGetValues=function(e){return this.request("users/features/get_values",e,"user","api","rpc","account_info.read")},v.usersGetAccount=function(e){return this.request("users/get_account",e,"user","api","rpc","sharing.read")},v.usersGetAccountBatch=function(e){return this.request("users/get_account_batch",e,"user","api","rpc","sharing.read")},v.usersGetCurrentAccount=function(){return this.request("users/get_current_account",null,"user","api","rpc","account_info.read")},v.usersGetSpaceUsage=function(){return this.request("users/get_space_usage",null,"user","api","rpc","account_info.read")};var w=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";return r?(t!==m&&void 0!==y[e]&&(e=y[e],r="-"),"https://".concat(e).concat(r).concat(t,"/2/")):"https://".concat(t,"/2/")},_=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g;return e!==g&&(e="meta-".concat(e)),"https://".concat(e,"/oauth2/authorize")},x=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:".",r="api";return e!==m&&(r=y[r],t="-"),"https://".concat(r).concat(t).concat(e,"/oauth2/token")};function S(e){return JSON.stringify(e).replace(/[\u007f-\uffff]/g,b)}function k(e){return new Date(Date.now()+1e3*e)}function E(){return"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope||"undefined"!=typeof window}function T(){return"undefined"!=typeof window}function B(){return"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope}function C(e){return e.toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}var I,A,F,M=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(o,e);var r,i,n=(r=o,i=l(),function(){var e,t=s(r);if(i){var n=s(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return u(this,e)});function o(e,r,i){var s;return t(this,o),(s=n.call(this,"Response failed with a ".concat(e," code"))).name="DropboxResponseError",s.status=e,s.headers=r,s.error=i,s}return o}(c(Error)),D=function e(r,i,n){t(this,e),this.status=r,this.headers=i,this.result=n};function R(e){return e.text().then((function(t){var r;try{r=JSON.parse(t)}catch(e){r=t}throw new M(e.status,e.headers,r)}))}function P(e){return e.ok?e.text().then((function(t){var r;try{r=JSON.parse(t)}catch(e){r=t}return new D(e.status,e.headers,r)})):R(e)}var O=["legacy","offline","online"],z=["code","token"],N=["none","user","team"],q=function(){function e(i){t(this,e),i=i||{},T()?(I=window.fetch.bind(window),A=window.crypto||window.msCrypto):B()?(I=self.fetch.bind(self),A=self.crypto):(I=r(43092),A=r(91565)),F="undefined"==typeof TextEncoder?r(40537).TextEncoder:TextEncoder,this.fetch=i.fetch||I,this.accessToken=i.accessToken,this.accessTokenExpiresAt=i.accessTokenExpiresAt,this.refreshToken=i.refreshToken,this.clientId=i.clientId,this.clientSecret=i.clientSecret,this.domain=i.domain,this.domainDelimiter=i.domainDelimiter,this.customHeaders=i.customHeaders,this.dataOnBody=i.dataOnBody}return o(e,[{key:"setAccessToken",value:function(e){this.accessToken=e}},{key:"getAccessToken",value:function(){return this.accessToken}},{key:"setClientId",value:function(e){this.clientId=e}},{key:"getClientId",value:function(){return this.clientId}},{key:"setClientSecret",value:function(e){this.clientSecret=e}},{key:"getClientSecret",value:function(){return this.clientSecret}},{key:"getRefreshToken",value:function(){return this.refreshToken}},{key:"setRefreshToken",value:function(e){this.refreshToken=e}},{key:"getAccessTokenExpiresAt",value:function(){return this.accessTokenExpiresAt}},{key:"setAccessTokenExpiresAt",value:function(e){this.accessTokenExpiresAt=e}},{key:"setCodeVerifier",value:function(e){this.codeVerifier=e}},{key:"getCodeVerifier",value:function(){return this.codeVerifier}},{key:"generateCodeChallenge",value:function(){var e,t=this,r=(new F).encode(this.codeVerifier);if(T()||B())return A.subtle.digest("SHA-256",r).then((function(r){var i=btoa(String.fromCharCode.apply(null,new Uint8Array(r)));e=C(i).substr(0,128),t.codeChallenge=e}));var i=A.createHash("sha256").update(r).digest();return e=C(i),this.codeChallenge=e,Promise.resolve()}},{key:"generatePKCECodes",value:function(){var e;if(T()||B()){var t=new Uint8Array(128),r=A.getRandomValues(t);e=C(btoa(r)).substr(0,128)}else e=C(A.randomBytes(128)).substr(0,128);return this.codeVerifier=e,this.generateCodeChallenge()}},{key:"getAuthenticationUrl",value:function(e,t){var r,i=this,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"token",o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"none",l=arguments.length>6&&void 0!==arguments[6]&&arguments[6],d=this.getClientId(),c=_(this.domain);if(!d)throw Error("A client id is required. You can set the client id using .setClientId().");if("code"!==n&&!e)throw Error("A redirect uri is required.");if(!z.includes(n))throw Error("Authorization type must be code or token");if(o&&!O.includes(o))throw Error("Token Access Type must be legacy, offline, or online");if(s&&!(s instanceof Array))throw Error("Scope must be an array of strings");if(!N.includes(a))throw Error("includeGrantedScopes must be none, user, or team");return r="code"===n?"".concat(c,"?response_type=code&client_id=").concat(d):"".concat(c,"?response_type=token&client_id=").concat(d),e&&(r+="&redirect_uri=".concat(e)),t&&(r+="&state=".concat(t)),o&&(r+="&token_access_type=".concat(o)),s&&(r+="&scope=".concat(s.join(" "))),"none"!==a&&(r+="&include_granted_scopes=".concat(a)),l?this.generatePKCECodes().then((function(){return r+="&code_challenge_method=S256",r+="&code_challenge=".concat(i.codeChallenge)})):Promise.resolve(r)}},{key:"getAccessTokenFromCode",value:function(e,t){var r=this.getClientId(),i=this.getClientSecret();if(!r)throw Error("A client id is required. You can set the client id using .setClientId().");var n=x(this.domain,this.domainDelimiter);if(n+="?grant_type=authorization_code",n+="&code=".concat(t),n+="&client_id=".concat(r),i)n+="&client_secret=".concat(i);else{if(!this.codeVerifier)throw Error("You must use PKCE when generating the authorization URL to not include a client secret");n+="&code_verifier=".concat(this.codeVerifier)}return e&&(n+="&redirect_uri=".concat(e)),this.fetch(n,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"}}).then((function(e){return P(e)}))}},{key:"checkAndRefreshAccessToken",value:function(){var e=this.getRefreshToken()&&this.getClientId(),t=!this.getAccessTokenExpiresAt()||new Date(Date.now()+3e5)>=this.getAccessTokenExpiresAt(),r=!this.getAccessToken();return(t||r)&&e?this.refreshAccessToken():Promise.resolve()}},{key:"refreshAccessToken",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=this.getClientId(),i=this.getClientSecret();if(!r)throw Error("A client id is required. You can set the client id using .setClientId().");if(t&&!(t instanceof Array))throw Error("Scope must be an array of strings");var n=x(this.domain,this.domainDelimiter),o={headers:{"Content-Type":"application/json"},method:"POST"};if(this.dataOnBody){var s={grant_type:"refresh_token",client_id:r,refresh_token:this.getRefreshToken()};i&&(s.client_secret=i),t&&(s.scope=t.join(" ")),o.body=s}else n+="?grant_type=refresh_token&refresh_token=".concat(this.getRefreshToken()),n+="&client_id=".concat(r),i&&(n+="&client_secret=".concat(i)),t&&(n+="&scope=".concat(t.join(" ")));return this.fetch(n,o).then((function(e){return P(e)})).then((function(t){e.setAccessToken(t.result.access_token),e.setAccessTokenExpiresAt(k(t.result.expires_in))}))}}]),e}(),U="undefined"==typeof btoa?function(e){return i.from(e).toString("base64")}:btoa;e.Dropbox=function(){function e(r){t(this,e),this.auth=(r=r||{}).auth?r.auth:new q(r),this.fetch=r.fetch||this.auth.fetch,this.selectUser=r.selectUser,this.selectAdmin=r.selectAdmin,this.pathRoot=r.pathRoot,this.domain=r.domain||this.auth.domain,this.domainDelimiter=r.domainDelimiter||this.auth.domainDelimiter,this.customHeaders=r.customHeaders||this.auth.customHeaders,Object.assign(this,v)}return o(e,[{key:"request",value:function(e,t,r,i,n){switch(n){case"rpc":return this.rpcRequest(e,t,r,i);case"download":return this.downloadRequest(e,t,r,i);case"upload":return this.uploadRequest(e,t,r,i);default:throw Error("Invalid request style: ".concat(n))}}},{key:"rpcRequest",value:function(e,t,r,i){var n=this;return this.auth.checkAndRefreshAccessToken().then((function(){var e={method:"POST",body:t?JSON.stringify(t):null,headers:{}};return t&&(e.headers["Content-Type"]="application/json"),n.setAuthHeaders(r,e),n.setCommonHeaders(e),e})).then((function(t){return n.fetch(w(i,n.domain,n.domainDelimiter)+e,t)})).then((function(e){return P(e)}))}},{key:"downloadRequest",value:function(e,t,r,i){var n=this;return this.auth.checkAndRefreshAccessToken().then((function(){var e={method:"POST",headers:{"Dropbox-API-Arg":S(t)}};return n.setAuthHeaders(r,e),n.setCommonHeaders(e),e})).then((function(t){return n.fetch(w(i,n.domain,n.domainDelimiter)+e,t)})).then((function(e){return function(e){return e.ok?new Promise((function(t){E()?e.blob().then((function(e){return t(e)})):e.buffer().then((function(e){return t(e)}))})).then((function(t){var r=JSON.parse(e.headers.get("dropbox-api-result"));return E()?r.fileBlob=t:r.fileBinary=t,new D(e.status,e.headers,r)})):R(e)}(e)}))}},{key:"uploadRequest",value:function(e,t,r,i){var n=this;return this.auth.checkAndRefreshAccessToken().then((function(){var e=t.contents;delete t.contents;var i={body:e,method:"POST",headers:{"Content-Type":"application/octet-stream","Dropbox-API-Arg":S(t)}};return n.setAuthHeaders(r,i),n.setCommonHeaders(i),i})).then((function(t){return n.fetch(w(i,n.domain,n.domainDelimiter)+e,t)})).then((function(e){return P(e)}))}},{key:"setAuthHeaders",value:function(e,t){if(e.split(",").length>1){var r=e.replace(" ","").split(",");r.includes(h)&&this.auth.getAccessToken()?e=h:r.includes(f)&&this.auth.getAccessToken()?e=f:r.includes(p)&&(e=p)}switch(e){case p:if(this.auth.clientId&&this.auth.clientSecret){var i=U("".concat(this.auth.clientId,":").concat(this.auth.clientSecret));t.headers.Authorization="Basic ".concat(i)}break;case f:case h:this.auth.getAccessToken()&&(t.headers.Authorization="Bearer ".concat(this.auth.getAccessToken()));break;case"noauth":case"cookie":break;default:throw Error("Unhandled auth type: ".concat(e))}}},{key:"setCommonHeaders",value:function(e){var t=this;this.selectUser&&(e.headers["Dropbox-API-Select-User"]=this.selectUser),this.selectAdmin&&(e.headers["Dropbox-API-Select-Admin"]=this.selectAdmin),this.pathRoot&&(e.headers["Dropbox-API-Path-Root"]=this.pathRoot),this.customHeaders&&Object.keys(this.customHeaders).forEach((function(r){e.headers[r]=t.customHeaders[r]}))}}]),e}(),e.DropboxAuth=q,e.DropboxResponse=D,e.DropboxResponseError=M,Object.defineProperty(e,"__esModule",{value:!0})}(t)},22010:(e,t,r)=>{"use strict";var i=r(92861).Buffer,n=r(3527),o=128;function s(e){if(i.isBuffer(e))return e;if("string"==typeof e)return i.from(e,"base64");throw new TypeError("ECDSA signature must be a Base64 string or a Buffer")}function a(e,t,r){for(var i=0;t+i=o&&--i,i}e.exports={derToJose:function(e,t){e=s(e);var r=n(t),o=r+1,a=e.length,l=0;if(48!==e[l++])throw new Error('Could not find expected "seq"');var d=e[l++];if(129===d&&(d=e[l++]),a-l{"use strict";function t(e){return(e/8|0)+(e%8==0?0:1)}var r={ES256:t(256),ES384:t(384),ES512:t(521)};e.exports=function(e){var t=r[e];if(t)return t;throw new Error('Unknown algorithm "'+e+'"')}},86729:(e,t,r)=>{"use strict";var i=t;i.version=r(1636).rE,i.utils=r(47011),i.rand=r(15037),i.curve=r(894),i.curves=r(60480),i.ec=r(57447),i.eddsa=r(8650)},36677:(e,t,r)=>{"use strict";var i=r(28490),n=r(47011),o=n.getNAF,s=n.getJSF,a=n.assert;function l(e,t){this.type=e,this.p=new i(t.p,16),this.red=t.prime?i.red(t.prime):i.mont(this.p),this.zero=new i(0).toRed(this.red),this.one=new i(1).toRed(this.red),this.two=new i(2).toRed(this.red),this.n=t.n&&new i(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function d(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=l,l.prototype.point=function(){throw new Error("Not implemented")},l.prototype.validate=function(){throw new Error("Not implemented")},l.prototype._fixedNafMul=function(e,t){a(e.precomputed);var r=e._getDoubles(),i=o(t,1,this._bitLength),n=(1<=s;c--)l=(l<<1)+i[c];d.push(l)}for(var u=this.jpoint(null,null,null),p=this.jpoint(null,null,null),h=n;h>0;h--){for(s=0;s=0;d--){for(var c=0;d>=0&&0===s[d];d--)c++;if(d>=0&&c++,l=l.dblp(c),d<0)break;var u=s[d];a(0!==u),l="affine"===e.type?u>0?l.mixedAdd(n[u-1>>1]):l.mixedAdd(n[-u-1>>1].neg()):u>0?l.add(n[u-1>>1]):l.add(n[-u-1>>1].neg())}return"affine"===e.type?l.toP():l},l.prototype._wnafMulAdd=function(e,t,r,i,n){var a,l,d,c=this._wnafT1,u=this._wnafT2,p=this._wnafT3,h=0;for(a=0;a=1;a-=2){var m=a-1,g=a;if(1===c[m]&&1===c[g]){var y=[t[m],null,null,t[g]];0===t[m].y.cmp(t[g].y)?(y[1]=t[m].add(t[g]),y[2]=t[m].toJ().mixedAdd(t[g].neg())):0===t[m].y.cmp(t[g].y.redNeg())?(y[1]=t[m].toJ().mixedAdd(t[g]),y[2]=t[m].add(t[g].neg())):(y[1]=t[m].toJ().mixedAdd(t[g]),y[2]=t[m].toJ().mixedAdd(t[g].neg()));var v=[-3,-1,-5,-7,0,7,5,1,3],b=s(r[m],r[g]);for(h=Math.max(b[0].length,h),p[m]=new Array(h),p[g]=new Array(h),l=0;l=0;a--){for(var k=0;a>=0;){var E=!0;for(l=0;l=0&&k++,x=x.dblp(k),a<0)break;for(l=0;l0?d=u[l][T-1>>1]:T<0&&(d=u[l][-T-1>>1].neg()),x="affine"===d.type?x.mixedAdd(d):x.add(d))}}for(a=0;a=Math.ceil((e.bitLength()+1)/t.step)},d.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],i=this,n=0;n{"use strict";var i=r(47011),n=r(28490),o=r(56698),s=r(36677),a=i.assert;function l(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,s.call(this,"edwards",e),this.a=new n(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new n(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new n(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),a(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function d(e,t,r,i,o){s.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===i?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new n(t,16),this.y=new n(r,16),this.z=i?new n(i,16):this.curve.one,this.t=o&&new n(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(l,s),e.exports=l,l.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},l.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},l.prototype.jpoint=function(e,t,r,i){return this.point(e,t,r,i)},l.prototype.pointFromX=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),i=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),s=i.redMul(o.redInvm()),a=s.redSqrt();if(0!==a.redSqr().redSub(s).cmp(this.zero))throw new Error("invalid point");var l=a.fromRed().isOdd();return(t&&!l||!t&&l)&&(a=a.redNeg()),this.point(e,a)},l.prototype.pointFromY=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),i=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),s=i.redMul(o.redInvm());if(0===s.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var a=s.redSqrt();if(0!==a.redSqr().redSub(s).cmp(this.zero))throw new Error("invalid point");return a.fromRed().isOdd()!==t&&(a=a.redNeg()),this.point(a,e)},l.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),i=t.redMul(this.a).redAdd(r),n=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===i.cmp(n)},o(d,s.BasePoint),l.prototype.pointFromJSON=function(e){return d.fromJSON(this,e)},l.prototype.point=function(e,t,r,i){return new d(this,e,t,r,i)},d.fromJSON=function(e,t){return new d(e,t[0],t[1],t[2])},d.prototype.inspect=function(){return this.isInfinity()?"":""},d.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},d.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var i=this.curve._mulA(e),n=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=i.redAdd(t),s=o.redSub(r),a=i.redSub(t),l=n.redMul(s),d=o.redMul(a),c=n.redMul(a),u=s.redMul(o);return this.curve.point(l,d,u,c)},d.prototype._projDbl=function(){var e,t,r,i,n,o,s=this.x.redAdd(this.y).redSqr(),a=this.x.redSqr(),l=this.y.redSqr();if(this.curve.twisted){var d=(i=this.curve._mulA(a)).redAdd(l);this.zOne?(e=s.redSub(a).redSub(l).redMul(d.redSub(this.curve.two)),t=d.redMul(i.redSub(l)),r=d.redSqr().redSub(d).redSub(d)):(n=this.z.redSqr(),o=d.redSub(n).redISub(n),e=s.redSub(a).redISub(l).redMul(o),t=d.redMul(i.redSub(l)),r=d.redMul(o))}else i=a.redAdd(l),n=this.curve._mulC(this.z).redSqr(),o=i.redSub(n).redSub(n),e=this.curve._mulC(s.redISub(i)).redMul(o),t=this.curve._mulC(i).redMul(a.redISub(l)),r=i.redMul(o);return this.curve.point(e,t,r)},d.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},d.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),i=this.t.redMul(this.curve.dd).redMul(e.t),n=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),s=n.redSub(i),a=n.redAdd(i),l=r.redAdd(t),d=o.redMul(s),c=a.redMul(l),u=o.redMul(l),p=s.redMul(a);return this.curve.point(d,c,p,u)},d.prototype._projAdd=function(e){var t,r,i=this.z.redMul(e.z),n=i.redSqr(),o=this.x.redMul(e.x),s=this.y.redMul(e.y),a=this.curve.d.redMul(o).redMul(s),l=n.redSub(a),d=n.redAdd(a),c=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(s),u=i.redMul(l).redMul(c);return this.curve.twisted?(t=i.redMul(d).redMul(s.redSub(this.curve._mulA(o))),r=l.redMul(d)):(t=i.redMul(d).redMul(s.redSub(o)),r=this.curve._mulC(l).redMul(d)),this.curve.point(u,t,r)},d.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},d.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},d.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},d.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},d.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},d.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},d.prototype.getX=function(){return this.normalize(),this.x.fromRed()},d.prototype.getY=function(){return this.normalize(),this.y.fromRed()},d.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},d.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),i=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(i),0===this.x.cmp(t))return!0}},d.prototype.toP=d.prototype.normalize,d.prototype.mixedAdd=d.prototype.add},894:(e,t,r)=>{"use strict";var i=t;i.base=r(36677),i.short=r(39188),i.mont=r(30370),i.edwards=r(31298)},30370:(e,t,r)=>{"use strict";var i=r(28490),n=r(56698),o=r(36677),s=r(47011);function a(e){o.call(this,"mont",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.b,16).toRed(this.red),this.i4=new i(4).toRed(this.red).redInvm(),this.two=new i(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function l(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new i(t,16),this.z=new i(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}n(a,o),e.exports=a,a.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),i=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===i.redSqrt().redSqr().cmp(i)},n(l,o.BasePoint),a.prototype.decodePoint=function(e,t){return this.point(s.toArray(e,t),1)},a.prototype.point=function(e,t){return new l(this,e,t)},a.prototype.pointFromJSON=function(e){return l.fromJSON(this,e)},l.prototype.precompute=function(){},l.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},l.fromJSON=function(e,t){return new l(e,t[0],t[1]||e.one)},l.prototype.inspect=function(){return this.isInfinity()?"":""},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},l.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),i=e.redMul(t),n=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(i,n)},l.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),i=this.x.redSub(this.z),n=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),s=n.redMul(i),a=t.z.redMul(o.redAdd(s).redSqr()),l=t.x.redMul(o.redISub(s).redSqr());return this.curve.point(a,l)},l.prototype.mul=function(e){for(var t=e.clone(),r=this,i=this.curve.point(null,null),n=[];0!==t.cmpn(0);t.iushrn(1))n.push(t.andln(1));for(var o=n.length-1;o>=0;o--)0===n[o]?(r=r.diffAdd(i,this),i=i.dbl()):(i=r.diffAdd(i,this),r=r.dbl());return i},l.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},l.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},l.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},39188:(e,t,r)=>{"use strict";var i=r(47011),n=r(28490),o=r(56698),s=r(36677),a=i.assert;function l(e){s.call(this,"short",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function d(e,t,r,i){s.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new n(t,16),this.y=new n(r,16),i&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function c(e,t,r,i){s.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===i?(this.x=this.curve.one,this.y=this.curve.one,this.z=new n(0)):(this.x=new n(t,16),this.y=new n(r,16),this.z=new n(i,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(l,s),e.exports=l,l.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new n(e.beta,16).toRed(this.red);else{var i=this._getEndoRoots(this.p);t=(t=i[0].cmp(i[1])<0?i[0]:i[1]).toRed(this.red)}if(e.lambda)r=new n(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],a(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new n(e.a,16),b:new n(e.b,16)}})):this._getEndoBasis(r)}}},l.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:n.mont(e),r=new n(2).toRed(t).redInvm(),i=r.redNeg(),o=new n(3).toRed(t).redNeg().redSqrt().redMul(r);return[i.redAdd(o).fromRed(),i.redSub(o).fromRed()]},l.prototype._getEndoBasis=function(e){for(var t,r,i,o,s,a,l,d,c,u=this.n.ushrn(Math.floor(this.n.bitLength()/2)),p=e,h=this.n.clone(),f=new n(1),m=new n(0),g=new n(0),y=new n(1),v=0;0!==p.cmpn(0);){var b=h.div(p);d=h.sub(b.mul(p)),c=g.sub(b.mul(f));var w=y.sub(b.mul(m));if(!i&&d.cmp(u)<0)t=l.neg(),r=f,i=d.neg(),o=c;else if(i&&2==++v)break;l=d,h=p,p=d,g=f,f=c,y=m,m=w}s=d.neg(),a=c;var _=i.sqr().add(o.sqr());return s.sqr().add(a.sqr()).cmp(_)>=0&&(s=t,a=r),i.negative&&(i=i.neg(),o=o.neg()),s.negative&&(s=s.neg(),a=a.neg()),[{a:i,b:o},{a:s,b:a}]},l.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],i=t[1],n=i.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),s=n.mul(r.a),a=o.mul(i.a),l=n.mul(r.b),d=o.mul(i.b);return{k1:e.sub(s).sub(a),k2:l.add(d).neg()}},l.prototype.pointFromX=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),i=r.redSqrt();if(0!==i.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=i.fromRed().isOdd();return(t&&!o||!t&&o)&&(i=i.redNeg()),this.point(e,i)},l.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,i=this.a.redMul(t),n=t.redSqr().redMul(t).redIAdd(i).redIAdd(this.b);return 0===r.redSqr().redISub(n).cmpn(0)},l.prototype._endoWnafMulAdd=function(e,t,r){for(var i=this._endoWnafT1,n=this._endoWnafT2,o=0;o":""},d.prototype.isInfinity=function(){return this.inf},d.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),i=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,i)},d.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),i=e.redInvm(),n=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(i),o=n.redSqr().redISub(this.x.redAdd(this.x)),s=n.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,s)},d.prototype.getX=function(){return this.x.fromRed()},d.prototype.getY=function(){return this.y.fromRed()},d.prototype.mul=function(e){return e=new n(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},d.prototype.mulAdd=function(e,t,r){var i=[this,t],n=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n):this.curve._wnafMulAdd(1,i,n,2)},d.prototype.jmulAdd=function(e,t,r){var i=[this,t],n=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n,!0):this.curve._wnafMulAdd(1,i,n,2,!0)},d.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},d.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,i=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(i)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(i)}}}return t},d.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(c,s.BasePoint),l.prototype.jpoint=function(e,t,r){return new c(this,e,t,r)},c.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),i=this.y.redMul(t).redMul(e);return this.curve.point(r,i)},c.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},c.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),i=this.x.redMul(t),n=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),s=e.y.redMul(r.redMul(this.z)),a=i.redSub(n),l=o.redSub(s);if(0===a.cmpn(0))return 0!==l.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var d=a.redSqr(),c=d.redMul(a),u=i.redMul(d),p=l.redSqr().redIAdd(c).redISub(u).redISub(u),h=l.redMul(u.redISub(p)).redISub(o.redMul(c)),f=this.z.redMul(e.z).redMul(a);return this.curve.jpoint(p,h,f)},c.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,i=e.x.redMul(t),n=this.y,o=e.y.redMul(t).redMul(this.z),s=r.redSub(i),a=n.redSub(o);if(0===s.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=s.redSqr(),d=l.redMul(s),c=r.redMul(l),u=a.redSqr().redIAdd(d).redISub(c).redISub(c),p=a.redMul(c.redISub(u)).redISub(n.redMul(d)),h=this.z.redMul(s);return this.curve.jpoint(u,p,h)},c.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t=0)return!1;if(r.redIAdd(n),0===this.x.cmp(r))return!0}},c.prototype.inspect=function(){return this.isInfinity()?"":""},c.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},60480:(e,t,r)=>{"use strict";var i,n=t,o=r(77952),s=r(894),a=r(47011).assert;function l(e){"short"===e.type?this.curve=new s.short(e):"edwards"===e.type?this.curve=new s.edwards(e):this.curve=new s.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function d(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new l(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=l,d("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),d("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),d("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),d("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:o.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),d("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:o.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),d("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),d("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{i=r(74011)}catch(e){i=void 0}d("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",i]})},57447:(e,t,r)=>{"use strict";var i=r(28490),n=r(32723),o=r(47011),s=r(60480),a=r(15037),l=o.assert,d=r(61200),c=r(28545);function u(e){if(!(this instanceof u))return new u(e);"string"==typeof e&&(l(Object.prototype.hasOwnProperty.call(s,e),"Unknown curve "+e),e=s[e]),e instanceof s.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=u,u.prototype.keyPair=function(e){return new d(this,e)},u.prototype.keyFromPrivate=function(e,t){return d.fromPrivate(this,e,t)},u.prototype.keyFromPublic=function(e,t){return d.fromPublic(this,e,t)},u.prototype.genKeyPair=function(e){e||(e={});for(var t=new n({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||a(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),o=this.n.sub(new i(2));;){var s=new i(t.generate(r));if(!(s.cmp(o)>0))return s.iaddn(1),this.keyFromPrivate(s)}},u.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},u.prototype.sign=function(e,t,r,o){"object"==typeof r&&(o=r,r=null),o||(o={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new i(e,16));for(var s=this.n.byteLength(),a=t.getPrivate().toArray("be",s),l=e.toArray("be",s),d=new n({hash:this.hash,entropy:a,nonce:l,pers:o.pers,persEnc:o.persEnc||"utf8"}),u=this.n.sub(new i(1)),p=0;;p++){var h=o.k?o.k(p):new i(d.generate(this.n.byteLength()));if(!((h=this._truncateToN(h,!0)).cmpn(1)<=0||h.cmp(u)>=0)){var f=this.g.mul(h);if(!f.isInfinity()){var m=f.getX(),g=m.umod(this.n);if(0!==g.cmpn(0)){var y=h.invm(this.n).mul(g.mul(t.getPrivate()).iadd(e));if(0!==(y=y.umod(this.n)).cmpn(0)){var v=(f.getY().isOdd()?1:0)|(0!==m.cmp(g)?2:0);return o.canonical&&y.cmp(this.nh)>0&&(y=this.n.sub(y),v^=1),new c({r:g,s:y,recoveryParam:v})}}}}}},u.prototype.verify=function(e,t,r,n){e=this._truncateToN(new i(e,16)),r=this.keyFromPublic(r,n);var o=(t=new c(t,"hex")).r,s=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(s.cmpn(1)<0||s.cmp(this.n)>=0)return!1;var a,l=s.invm(this.n),d=l.mul(e).umod(this.n),u=l.mul(o).umod(this.n);return this.curve._maxwellTrick?!(a=this.g.jmulAdd(d,r.getPublic(),u)).isInfinity()&&a.eqXToP(o):!(a=this.g.mulAdd(d,r.getPublic(),u)).isInfinity()&&0===a.getX().umod(this.n).cmp(o)},u.prototype.recoverPubKey=function(e,t,r,n){l((3&r)===r,"The recovery param is more than two bits"),t=new c(t,n);var o=this.n,s=new i(e),a=t.r,d=t.s,u=1&r,p=r>>1;if(a.cmp(this.curve.p.umod(this.curve.n))>=0&&p)throw new Error("Unable to find sencond key candinate");a=p?this.curve.pointFromX(a.add(this.curve.n),u):this.curve.pointFromX(a,u);var h=t.r.invm(o),f=o.sub(s).mul(h).umod(o),m=d.mul(h).umod(o);return this.g.mulAdd(f,a,m)},u.prototype.getKeyRecoveryParam=function(e,t,r,i){if(null!==(t=new c(t,i)).recoveryParam)return t.recoveryParam;for(var n=0;n<4;n++){var o;try{o=this.recoverPubKey(e,t,n)}catch(e){continue}if(o.eq(r))return n}throw new Error("Unable to find valid recovery factor")}},61200:(e,t,r)=>{"use strict";var i=r(28490),n=r(47011).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new i(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?n(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||n(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||n(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return""}},28545:(e,t,r)=>{"use strict";var i=r(28490),n=r(47011),o=n.assert;function s(e,t){if(e instanceof s)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new i(e.r,16),this.s=new i(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function a(){this.place=0}function l(e,t){var r=e[t.place++];if(!(128&r))return r;var i=15&r;if(0===i||i>4)return!1;if(0===e[t.place])return!1;for(var n=0,o=0,s=t.place;o>>=0;return!(n<=127)&&(t.place=s,n)}function d(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=s,s.prototype._importDER=function(e,t){e=n.toArray(e,t);var r=new a;if(48!==e[r.place++])return!1;var o=l(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var s=l(e,r);if(!1===s)return!1;if(128&e[r.place])return!1;var d=e.slice(r.place,s+r.place);if(r.place+=s,2!==e[r.place++])return!1;var c=l(e,r);if(!1===c)return!1;if(e.length!==c+r.place)return!1;if(128&e[r.place])return!1;var u=e.slice(r.place,c+r.place);if(0===d[0]){if(!(128&d[1]))return!1;d=d.slice(1)}if(0===u[0]){if(!(128&u[1]))return!1;u=u.slice(1)}return this.r=new i(d),this.s=new i(u),this.recoveryParam=null,!0},s.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=d(t),r=d(r);!(r[0]||128&r[1]);)r=r.slice(1);var i=[2];c(i,t.length),(i=i.concat(t)).push(2),c(i,r.length);var o=i.concat(r),s=[48];return c(s,o.length),s=s.concat(o),n.encode(s,e)}},8650:(e,t,r)=>{"use strict";var i=r(77952),n=r(60480),o=r(47011),s=o.assert,a=o.parseBytes,l=r(46661),d=r(90220);function c(e){if(s("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof c))return new c(e);e=n[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=i.sha512}e.exports=c,c.prototype.sign=function(e,t){e=a(e);var r=this.keyFromSecret(t),i=this.hashInt(r.messagePrefix(),e),n=this.g.mul(i),o=this.encodePoint(n),s=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),l=i.add(s).umod(this.curve.n);return this.makeSignature({R:n,S:l,Rencoded:o})},c.prototype.verify=function(e,t,r){if(e=a(e),(t=this.makeSignature(t)).S().gte(t.eddsa.curve.n)||t.S().isNeg())return!1;var i=this.keyFromPublic(r),n=this.hashInt(t.Rencoded(),i.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(i.pub().mul(n)).eq(o)},c.prototype.hashInt=function(){for(var e=this.hash(),t=0;t{"use strict";var i=r(47011),n=i.assert,o=i.parseBytes,s=i.cachedProperty;function a(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}a.fromPublic=function(e,t){return t instanceof a?t:new a(e,{pub:t})},a.fromSecret=function(e,t){return t instanceof a?t:new a(e,{secret:t})},a.prototype.secret=function(){return this._secret},s(a,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),s(a,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),s(a,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,i=t.slice(0,e.encodingLength);return i[0]&=248,i[r]&=127,i[r]|=64,i})),s(a,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),s(a,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),s(a,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),a.prototype.sign=function(e){return n(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},a.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},a.prototype.getSecret=function(e){return n(this._secret,"KeyPair is public only"),i.encode(this.secret(),e)},a.prototype.getPublic=function(e){return i.encode(this.pubBytes(),e)},e.exports=a},90220:(e,t,r)=>{"use strict";var i=r(28490),n=r(47011),o=n.assert,s=n.cachedProperty,a=n.parseBytes;function l(e,t){this.eddsa=e,"object"!=typeof t&&(t=a(t)),Array.isArray(t)&&(o(t.length===2*e.encodingLength,"Signature has invalid size"),t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),o(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof i&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}s(l,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),s(l,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),s(l,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),s(l,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),l.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},l.prototype.toHex=function(){return n.encode(this.toBytes(),"hex").toUpperCase()},e.exports=l},74011:e=>{e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},47011:(e,t,r)=>{"use strict";var i=t,n=r(28490),o=r(43349),s=r(64367);i.assert=o,i.toArray=s.toArray,i.zero2=s.zero2,i.toHex=s.toHex,i.encode=s.encode,i.getNAF=function(e,t,r){var i,n=new Array(Math.max(e.bitLength(),r)+1);for(i=0;i(o>>1)-1?(o>>1)-l:l,s.isubn(a)):a=0,n[i]=a,s.iushrn(1)}return n},i.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var i,n=0,o=0;e.cmpn(-n)>0||t.cmpn(-o)>0;){var s,a,l=e.andln(3)+n&3,d=t.andln(3)+o&3;3===l&&(l=-1),3===d&&(d=-1),s=1&l?3!==(i=e.andln(7)+n&7)&&5!==i||2!==d?l:-l:0,r[0].push(s),a=1&d?3!==(i=t.andln(7)+o&7)&&5!==i||2!==l?d:-d:0,r[1].push(a),2*n===s+1&&(n=1-n),2*o===a+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},i.cachedProperty=function(e,t,r){var i="_"+t;e.prototype[t]=function(){return void 0!==this[i]?this[i]:this[i]=r.call(this)}},i.parseBytes=function(e){return"string"==typeof e?i.toArray(e,"hex"):e},i.intFromLE=function(e){return new n(e,"hex","le")}},28490:function(e,t,r){!function(e,t){"use strict";function i(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var s;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(79368).Buffer}catch(e){}function a(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},30655:(e,t,r)=>{"use strict";var i=r(70453)("%Object.defineProperty%",!0)||!1;if(i)try{i({},"a",{value:1})}catch(e){i=!1}e.exports=i},41237:e=>{"use strict";e.exports=EvalError},69383:e=>{"use strict";e.exports=Error},79290:e=>{"use strict";e.exports=RangeError},79538:e=>{"use strict";e.exports=ReferenceError},58068:e=>{"use strict";e.exports=SyntaxError},69675:e=>{"use strict";e.exports=TypeError},35345:e=>{"use strict";e.exports=URIError},30228:e=>{"use strict";var t=Object.prototype.hasOwnProperty,r="~";function i(){}function n(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function o(e,t,i,o,s){if("function"!=typeof i)throw new TypeError("The listener must be a function");var a=new n(i,o||e,s),l=r?r+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],a]:e._events[l].push(a):(e._events[l]=a,e._eventsCount++),e}function s(e,t){0==--e._eventsCount?e._events=new i:delete e._events[t]}function a(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),(new i).__proto__||(r=!1)),a.prototype.eventNames=function(){var e,i,n=[];if(0===this._eventsCount)return n;for(i in e=this._events)t.call(e,i)&&n.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(e)):n},a.prototype.listeners=function(e){var t=r?r+e:e,i=this._events[t];if(!i)return[];if(i.fn)return[i.fn];for(var n=0,o=i.length,s=new Array(o);n{"use strict";var t,r="object"==typeof Reflect?Reflect:null,i=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var n=Number.isNaN||function(e){return e!=e};function o(){o.init.call(this)}e.exports=o,e.exports.once=function(e,t){return new Promise((function(r,i){function n(r){e.removeListener(t,o),i(r)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",n),r([].slice.call(arguments))}m(e,t,o,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&m(e,"error",t,r)}(e,n,{once:!0})}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var s=10;function a(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function l(e){return void 0===e._maxListeners?o.defaultMaxListeners:e._maxListeners}function d(e,t,r,i){var n,o,s,d;if(a(r),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),o=e._events),s=o[t]),void 0===s)s=o[t]=r,++e._eventsCount;else if("function"==typeof s?s=o[t]=i?[r,s]:[s,r]:i?s.unshift(r):s.push(r),(n=l(e))>0&&s.length>n&&!s.warned){s.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=s.length,d=c,console&&console.warn&&console.warn(d)}return e}function c(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function u(e,t,r){var i={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},n=c.bind(i);return n.listener=r,i.wrapFn=n,n}function p(e,t,r){var i=e._events;if(void 0===i)return[];var n=i[t];return void 0===n?[]:"function"==typeof n?r?[n.listener||n]:[n]:r?function(e){for(var t=new Array(e.length),r=0;r0&&(s=t[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var l=o[e];if(void 0===l)return!1;if("function"==typeof l)i(l,this,t);else{var d=l.length,c=f(l,d);for(r=0;r=0;o--)if(r[o]===t||r[o].listener===t){s=r[o].listener,n=o;break}if(n<0)return this;0===n?r.shift():function(e,t){for(;t+1=0;i--)this.removeListener(e,t[i]);return this},o.prototype.listeners=function(e){return p(this,e,!0)},o.prototype.rawListeners=function(e){return p(this,e,!1)},o.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):h.call(e,t)},o.prototype.listenerCount=h,o.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},68078:(e,t,r)=>{var i=r(92861).Buffer,n=r(88276);e.exports=function(e,t,r,o){if(i.isBuffer(e)||(e=i.from(e,"binary")),t&&(i.isBuffer(t)||(t=i.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var s=r/8,a=i.alloc(s),l=i.alloc(o||0),d=i.alloc(0);s>0||o>0;){var c=new n;c.update(d),c.update(e),t&&c.update(t),d=c.digest();var u=0;if(s>0){var p=a.length-s;u=Math.min(s,d.length),d.copy(a,p,0,u),s-=u}if(u0){var h=l.length-o,f=Math.min(o,d.length-u);d.copy(l,h,u,u+f),o-=f}}return d.fill(0),{key:a,iv:l}}},78463:e=>{e.exports=s,s.default=s,s.stable=c,s.stableStringify=c;var t="[...]",r="[Circular]",i=[],n=[];function o(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function s(e,t,r,s){var a;void 0===s&&(s=o()),l(e,"",0,[],void 0,0,s);try{a=0===n.length?JSON.stringify(e,t,r):JSON.stringify(e,p(t),r)}catch(e){return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;0!==i.length;){var d=i.pop();4===d.length?Object.defineProperty(d[0],d[1],d[3]):d[0][d[1]]=d[2]}}return a}function a(e,t,r,o){var s=Object.getOwnPropertyDescriptor(o,r);void 0!==s.get?s.configurable?(Object.defineProperty(o,r,{value:e}),i.push([o,r,t,s])):n.push([t,r,e]):(o[r]=e,i.push([o,r,t]))}function l(e,i,n,o,s,d,c){var u;if(d+=1,"object"==typeof e&&null!==e){for(u=0;uc.depthLimit)return void a(t,e,i,s);if(void 0!==c.edgesLimit&&n+1>c.edgesLimit)return void a(t,e,i,s);if(o.push(e),Array.isArray(e))for(u=0;ut?1:0}function c(e,t,r,s){void 0===s&&(s=o());var a,l=u(e,"",0,[],void 0,0,s)||e;try{a=0===n.length?JSON.stringify(l,t,r):JSON.stringify(l,p(t),r)}catch(e){return JSON.stringify("[unable to serialize, circular reference is too complex to analyze]")}finally{for(;0!==i.length;){var d=i.pop();4===d.length?Object.defineProperty(d[0],d[1],d[3]):d[0][d[1]]=d[2]}}return a}function u(e,n,o,s,l,c,p){var h;if(c+=1,"object"==typeof e&&null!==e){for(h=0;hp.depthLimit)return void a(t,e,n,l);if(void 0!==p.edgesLimit&&o+1>p.edgesLimit)return void a(t,e,n,l);if(s.push(e),Array.isArray(e))for(h=0;h0)for(var i=0;i{"use strict";const i=r(43918),n=r(32923),o=r(8904);e.exports={XMLParser:n,XMLValidator:i,XMLBuilder:o}},35334:(e,t)=>{"use strict";const r=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i="["+r+"]["+(r+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040")+"]*",n=new RegExp("^"+i+"$");t.isExist=function(e){return void 0!==e},t.isEmptyObject=function(e){return 0===Object.keys(e).length},t.merge=function(e,t,r){if(t){const i=Object.keys(t),n=i.length;for(let o=0;o{"use strict";const i=r(35334),n={allowBooleanAttributes:!1,unpairedTags:[]};function o(e){return" "===e||"\t"===e||"\n"===e||"\r"===e}function s(e,t){const r=t;for(;t5&&"xml"===i)return f("InvalidXml","XML declaration allowed only at the start of the document.",g(e,t));if("?"==e[t]&&">"==e[t+1]){t++;break}}return t}function a(e,t){if(e.length>t+5&&"-"===e[t+1]&&"-"===e[t+2]){for(t+=3;t"===e[t+2]){t+=2;break}}else if(e.length>t+8&&"D"===e[t+1]&&"O"===e[t+2]&&"C"===e[t+3]&&"T"===e[t+4]&&"Y"===e[t+5]&&"P"===e[t+6]&&"E"===e[t+7]){let r=1;for(t+=8;t"===e[t]&&(r--,0===r))break}else if(e.length>t+9&&"["===e[t+1]&&"C"===e[t+2]&&"D"===e[t+3]&&"A"===e[t+4]&&"T"===e[t+5]&&"A"===e[t+6]&&"["===e[t+7])for(t+=8;t"===e[t+2]){t+=2;break}return t}t.validate=function(e,t){t=Object.assign({},n,t);const r=[];let l=!1,d=!1;"\ufeff"===e[0]&&(e=e.substr(1));for(let n=0;n"!==e[n]&&" "!==e[n]&&"\t"!==e[n]&&"\n"!==e[n]&&"\r"!==e[n];n++)v+=e[n];if(v=v.trim(),"/"===v[v.length-1]&&(v=v.substring(0,v.length-1),n--),u=v,!i.isName(u)){let t;return t=0===v.trim().length?"Invalid space after '<'.":"Tag '"+v+"' is an invalid name.",f("InvalidTag",t,g(e,n))}const b=c(e,n);if(!1===b)return f("InvalidAttr","Attributes for '"+v+"' have open quote.",g(e,n));let w=b.value;if(n=b.index,"/"===w[w.length-1]){const r=n-w.length;w=w.substring(0,w.length-1);const i=p(w,t);if(!0!==i)return f(i.err.code,i.err.msg,g(e,r+i.err.line));l=!0}else if(y){if(!b.tagClosed)return f("InvalidTag","Closing tag '"+v+"' doesn't have proper closing.",g(e,n));if(w.trim().length>0)return f("InvalidTag","Closing tag '"+v+"' can't have attributes or invalid starting.",g(e,m));if(0===r.length)return f("InvalidTag","Closing tag '"+v+"' has not been opened.",g(e,m));{const t=r.pop();if(v!==t.tagName){let r=g(e,t.tagStartPos);return f("InvalidTag","Expected closing tag '"+t.tagName+"' (opened in line "+r.line+", col "+r.col+") instead of closing tag '"+v+"'.",g(e,m))}0==r.length&&(d=!0)}}else{const i=p(w,t);if(!0!==i)return f(i.err.code,i.err.msg,g(e,n-w.length+i.err.line));if(!0===d)return f("InvalidXml","Multiple possible root nodes found.",g(e,n));-1!==t.unpairedTags.indexOf(v)||r.push({tagName:v,tagStartPos:m}),l=!0}for(n++;n0)||f("InvalidXml","Invalid '"+JSON.stringify(r.map((e=>e.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):f("InvalidXml","Start tag expected.",1)};const l='"',d="'";function c(e,t){let r="",i="",n=!1;for(;t"===e[t]&&""===i){n=!0;break}r+=e[t]}return""===i&&{value:r,index:t,tagClosed:n}}const u=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function p(e,t){const r=i.getAllMatches(e,u),n={};for(let e=0;e{"use strict";const i=r(12788),n={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function o(e){this.options=Object.assign({},n,e),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=l),this.processTextOrObjNode=s,this.options.format?(this.indentate=a,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function s(e,t,r){const i=this.j2x(e,r+1);return void 0!==e[this.options.textNodeName]&&1===Object.keys(e).length?this.buildTextValNode(e[this.options.textNodeName],t,i.attrStr,r):this.buildObjectNode(i.val,t,i.attrStr,r)}function a(e){return this.options.indentBy.repeat(e)}function l(e){return!(!e.startsWith(this.options.attributeNamePrefix)||e===this.options.textNodeName)&&e.substr(this.attrPrefixLen)}o.prototype.build=function(e){return this.options.preserveOrder?i(e,this.options):(Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(e={[this.options.arrayNodeName]:e}),this.j2x(e,0).val)},o.prototype.j2x=function(e,t){let r="",i="";for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n))if(void 0===e[n])this.isAttribute(n)&&(i+="");else if(null===e[n])this.isAttribute(n)?i+="":"?"===n[0]?i+=this.indentate(t)+"<"+n+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+n+"/"+this.tagEndChar;else if(e[n]instanceof Date)i+=this.buildTextValNode(e[n],n,"",t);else if("object"!=typeof e[n]){const o=this.isAttribute(n);if(o)r+=this.buildAttrPairStr(o,""+e[n]);else if(n===this.options.textNodeName){let t=this.options.tagValueProcessor(n,""+e[n]);i+=this.replaceEntitiesValue(t)}else i+=this.buildTextValNode(e[n],n,"",t)}else if(Array.isArray(e[n])){const r=e[n].length;let o="",s="";for(let a=0;a"+e+n}},o.prototype.closeTag=function(e){let t="";return-1!==this.options.unpairedTags.indexOf(e)?this.options.suppressUnpairedNode||(t="/"):t=this.options.suppressEmptyNode?"/":`>`+this.newLine;if(!1!==this.options.commentPropName&&t===this.options.commentPropName)return this.indentate(i)+`\x3c!--${e}--\x3e`+this.newLine;if("?"===t[0])return this.indentate(i)+"<"+t+r+"?"+this.tagEndChar;{let n=this.options.tagValueProcessor(t,e);return n=this.replaceEntitiesValue(n),""===n?this.indentate(i)+"<"+t+r+this.closeTag(t)+this.tagEndChar:this.indentate(i)+"<"+t+r+">"+n+"0&&this.options.processEntities)for(let t=0;t{function t(e,s,a,l){let d="",c=!1;for(let u=0;u`,c=!1;continue}if(h===s.commentPropName){d+=l+`\x3c!--${p[h][0][s.textNodeName]}--\x3e`,c=!0;continue}if("?"===h[0]){const e=i(p[":@"],s),t="?xml"===h?"":l;let r=p[h][0][s.textNodeName];r=0!==r.length?" "+r:"",d+=t+`<${h}${r}${e}?>`,c=!0;continue}let m=l;""!==m&&(m+=s.indentBy);const g=l+`<${h}${i(p[":@"],s)}`,y=t(p[h],s,f,m);-1!==s.unpairedTags.indexOf(h)?s.suppressUnpairedNode?d+=g+">":d+=g+"/>":y&&0!==y.length||!s.suppressEmptyNode?y&&y.endsWith(">")?d+=g+`>${y}${l}`:(d+=g+">",y&&""!==l&&(y.includes("/>")||y.includes("`):d+=g+"/>",c=!0}return d}function r(e){const t=Object.keys(e);for(let r=0;r0&&t.processEntities)for(let r=0;r0&&(i="\n"),t(e,r,"",i)}},9400:(e,t,r)=>{const i=r(35334);function n(e,t){let r="";for(;t"===e[t]){if(p?"-"===e[t-1]&&"-"===e[t-2]&&(p=!1,i--):i--,0===i)break}else"["===e[t]?u=!0:h+=e[t];else{if(u&&s(e,t))t+=7,[entityName,val,t]=n(e,t+1),-1===val.indexOf("&")&&(r[c(entityName)]={regx:RegExp(`&${entityName};`,"g"),val});else if(u&&a(e,t))t+=8;else if(u&&l(e,t))t+=8;else if(u&&d(e,t))t+=9;else{if(!o)throw new Error("Invalid DOCTYPE");p=!0}i++,h=""}if(0!==i)throw new Error("Unclosed DOCTYPE")}return{entities:r,i:t}}},50460:(e,t)=>{const r={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(e,t,r){return e}};t.buildOptions=function(e){return Object.assign({},r,e)},t.defaultOptions=r},17680:(e,t,r)=>{"use strict";const i=r(35334),n=r(23832),o=r(9400),s=r(17983);function a(e){const t=Object.keys(e);for(let r=0;r0)){s||(e=this.replaceEntitiesValue(e));const i=this.options.tagValueProcessor(t,e,r,n,o);if(null==i)return e;if(typeof i!=typeof e||i!==e)return i;if(this.options.trimValues)return w(e,this.options.parseTagValue,this.options.numberParseOptions);return e.trim()===e?w(e,this.options.parseTagValue,this.options.numberParseOptions):e}}function d(e){if(this.options.removeNSPrefix){const t=e.split(":"),r="/"===e.charAt(0)?"/":"";if("xmlns"===t[0])return"";2===t.length&&(e=r+t[1])}return e}const c=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function u(e,t,r){if(!this.options.ignoreAttributes&&"string"==typeof e){const r=i.getAllMatches(e,c),n=r.length,o={};for(let e=0;e",a,"Closing Tag is not closed.");let n=e.substring(a+2,t).trim();if(this.options.removeNSPrefix){const e=n.indexOf(":");-1!==e&&(n=n.substr(e+1))}this.options.transformTagName&&(n=this.options.transformTagName(n)),r&&(i=this.saveTextToParentTag(i,r,s));const o=s.substring(s.lastIndexOf(".")+1);if(n&&-1!==this.options.unpairedTags.indexOf(n))throw new Error(`Unpaired tag can not be used as closing tag: `);let l=0;o&&-1!==this.options.unpairedTags.indexOf(o)?(l=s.lastIndexOf(".",s.lastIndexOf(".")-1),this.tagsNodeStack.pop()):l=s.lastIndexOf("."),s=s.substring(0,l),r=this.tagsNodeStack.pop(),i="",a=t}else if("?"===e[a+1]){let t=v(e,a,!1,"?>");if(!t)throw new Error("Pi Tag is not closed.");if(i=this.saveTextToParentTag(i,r,s),this.options.ignoreDeclaration&&"?xml"===t.tagName||this.options.ignorePiTags);else{const e=new n(t.tagName);e.add(this.options.textNodeName,""),t.tagName!==t.tagExp&&t.attrExpPresent&&(e[":@"]=this.buildAttributesMap(t.tagExp,s,t.tagName)),this.addChild(r,e,s)}a=t.closeIndex+1}else if("!--"===e.substr(a+1,3)){const t=y(e,"--\x3e",a+4,"Comment is not closed.");if(this.options.commentPropName){const n=e.substring(a+4,t-2);i=this.saveTextToParentTag(i,r,s),r.add(this.options.commentPropName,[{[this.options.textNodeName]:n}])}a=t}else if("!D"===e.substr(a+1,2)){const t=o(e,a);this.docTypeEntities=t.entities,a=t.i}else if("!["===e.substr(a+1,2)){const t=y(e,"]]>",a,"CDATA is not closed.")-2,n=e.substring(a+9,t);i=this.saveTextToParentTag(i,r,s);let o=this.parseTextData(n,r.tagname,s,!0,!1,!0,!0);null==o&&(o=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:n}]):r.add(this.options.textNodeName,o),a=t+2}else{let o=v(e,a,this.options.removeNSPrefix),l=o.tagName;const d=o.rawTagName;let c=o.tagExp,u=o.attrExpPresent,p=o.closeIndex;this.options.transformTagName&&(l=this.options.transformTagName(l)),r&&i&&"!xml"!==r.tagname&&(i=this.saveTextToParentTag(i,r,s,!1));const h=r;if(h&&-1!==this.options.unpairedTags.indexOf(h.tagname)&&(r=this.tagsNodeStack.pop(),s=s.substring(0,s.lastIndexOf("."))),l!==t.tagname&&(s+=s?"."+l:l),this.isItStopNode(this.options.stopNodes,s,l)){let t="";if(c.length>0&&c.lastIndexOf("/")===c.length-1)"/"===l[l.length-1]?(l=l.substr(0,l.length-1),s=s.substr(0,s.length-1),c=l):c=c.substr(0,c.length-1),a=o.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(l))a=o.closeIndex;else{const r=this.readStopNodeData(e,d,p+1);if(!r)throw new Error(`Unexpected end of ${d}`);a=r.i,t=r.tagContent}const i=new n(l);l!==c&&u&&(i[":@"]=this.buildAttributesMap(c,s,l)),t&&(t=this.parseTextData(t,l,s,!0,u,!0,!0)),s=s.substr(0,s.lastIndexOf(".")),i.add(this.options.textNodeName,t),this.addChild(r,i,s)}else{if(c.length>0&&c.lastIndexOf("/")===c.length-1){"/"===l[l.length-1]?(l=l.substr(0,l.length-1),s=s.substr(0,s.length-1),c=l):c=c.substr(0,c.length-1),this.options.transformTagName&&(l=this.options.transformTagName(l));const e=new n(l);l!==c&&u&&(e[":@"]=this.buildAttributesMap(c,s,l)),this.addChild(r,e,s),s=s.substr(0,s.lastIndexOf("."))}else{const e=new n(l);this.tagsNodeStack.push(r),l!==c&&u&&(e[":@"]=this.buildAttributesMap(c,s,l)),this.addChild(r,e,s),r=e}i="",a=p}}else i+=e[a]}return t.child};function h(e,t,r){const i=this.options.updateTag(t.tagname,r,t[":@"]);!1===i||("string"==typeof i?(t.tagname=i,e.addChild(t)):e.addChild(t))}const f=function(e){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];e=e.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];e=e.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let t in this.htmlEntities){const r=this.htmlEntities[t];e=e.replace(r.regex,r.val)}e=e.replace(this.ampEntity.regex,this.ampEntity.val)}return e};function m(e,t,r,i){return e&&(void 0===i&&(i=0===Object.keys(t.child).length),void 0!==(e=this.parseTextData(e,t.tagname,r,!1,!!t[":@"]&&0!==Object.keys(t[":@"]).length,i))&&""!==e&&t.add(this.options.textNodeName,e),e=""),e}function g(e,t,r){const i="*."+r;for(const r in e){const n=e[r];if(i===n||t===n)return!0}return!1}function y(e,t,r,i){const n=e.indexOf(t,r);if(-1===n)throw new Error(i);return n+t.length-1}function v(e,t,r,i=">"){const n=function(e,t,r=">"){let i,n="";for(let o=t;o",r,`${t} is not closed`);if(e.substring(r+2,o).trim()===t&&(n--,0===n))return{tagContent:e.substring(i,r),i:o};r=o}else if("?"===e[r+1]){r=y(e,"?>",r+1,"StopNode is not closed.")}else if("!--"===e.substr(r+1,3)){r=y(e,"--\x3e",r+3,"StopNode is not closed.")}else if("!["===e.substr(r+1,2)){r=y(e,"]]>",r,"StopNode is not closed.")-2}else{const i=v(e,r,">");if(i){(i&&i.tagName)===t&&"/"!==i.tagExp[i.tagExp.length-1]&&n++,r=i.closeIndex}}}function w(e,t,r){if(t&&"string"==typeof e){const t=e.trim();return"true"===t||"false"!==t&&s(e,r)}return i.isExist(e)?e:""}e.exports=class{constructor(e){this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(e,t)=>String.fromCharCode(Number.parseInt(t,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(e,t)=>String.fromCharCode(Number.parseInt(t,16))}},this.addExternalEntities=a,this.parseXml=p,this.parseTextData=l,this.resolveNameSpace=d,this.buildAttributesMap=u,this.isItStopNode=g,this.replaceEntitiesValue=f,this.readStopNodeData=b,this.saveTextToParentTag=m,this.addChild=h}}},32923:(e,t,r)=>{const{buildOptions:i}=r(50460),n=r(17680),{prettify:o}=r(75629),s=r(43918);e.exports=class{constructor(e){this.externalEntities={},this.options=i(e)}parse(e,t){if("string"==typeof e);else{if(!e.toString)throw new Error("XML data is accepted in String or Bytes[] form.");e=e.toString()}if(t){!0===t&&(t={});const r=s.validate(e,t);if(!0!==r)throw Error(`${r.err.msg}:${r.err.line}:${r.err.col}`)}const r=new n(this.options);r.addExternalEntities(this.externalEntities);const i=r.parseXml(e);return this.options.preserveOrder||void 0===i?i:o(i,this.options)}addEntity(e,t){if(-1!==t.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==e.indexOf("&")||-1!==e.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");if("&"===t)throw new Error("An entity with value '&' is not permitted");this.externalEntities[e]=t}}},75629:(e,t)=>{"use strict";function r(e,t,s){let a;const l={};for(let d=0;d0&&(l[t.textNodeName]=a):void 0!==a&&(l[t.textNodeName]=a),l}function i(e){const t=Object.keys(e);for(let e=0;e{"use strict";e.exports=class{constructor(e){this.tagname=e,this.child=[],this[":@"]={}}add(e,t){"__proto__"===e&&(e="#__proto__"),this.child.push({[e]:t})}addChild(e){"__proto__"===e.tagname&&(e.tagname="#__proto__"),e[":@"]&&Object.keys(e[":@"]).length>0?this.child.push({[e.tagname]:e.child,":@":e[":@"]}):this.child.push({[e.tagname]:e.child})}}},82682:(e,t,r)=>{"use strict";var i=r(69600),n=Object.prototype.toString,o=Object.prototype.hasOwnProperty;e.exports=function(e,t,r){if(!i(t))throw new TypeError("iterator must be a function");var s;arguments.length>=3&&(s=r),"[object Array]"===n.call(e)?function(e,t,r){for(var i=0,n=e.length;i{"use strict";var t=Object.prototype.toString,r=Math.max,i=function(e,t){for(var r=[],i=0;i{"use strict";var i=r(89353);e.exports=Function.prototype.bind||i},70453:(e,t,r)=>{"use strict";var i,n=r(69383),o=r(41237),s=r(79290),a=r(79538),l=r(58068),d=r(69675),c=r(35345),u=Function,p=function(e){try{return u('"use strict"; return ('+e+").constructor;")()}catch(e){}},h=Object.getOwnPropertyDescriptor;if(h)try{h({},"")}catch(e){h=null}var f=function(){throw new d},m=h?function(){try{return f}catch(e){try{return h(arguments,"callee").get}catch(e){return f}}}():f,g=r(64039)(),y=r(80024)(),v=Object.getPrototypeOf||(y?function(e){return e.__proto__}:null),b={},w="undefined"!=typeof Uint8Array&&v?v(Uint8Array):i,_={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?i:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?i:ArrayBuffer,"%ArrayIteratorPrototype%":g&&v?v([][Symbol.iterator]()):i,"%AsyncFromSyncIteratorPrototype%":i,"%AsyncFunction%":b,"%AsyncGenerator%":b,"%AsyncGeneratorFunction%":b,"%AsyncIteratorPrototype%":b,"%Atomics%":"undefined"==typeof Atomics?i:Atomics,"%BigInt%":"undefined"==typeof BigInt?i:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?i:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?i:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?i:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":n,"%eval%":eval,"%EvalError%":o,"%Float32Array%":"undefined"==typeof Float32Array?i:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?i:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?i:FinalizationRegistry,"%Function%":u,"%GeneratorFunction%":b,"%Int8Array%":"undefined"==typeof Int8Array?i:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?i:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?i:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":g&&v?v(v([][Symbol.iterator]())):i,"%JSON%":"object"==typeof JSON?JSON:i,"%Map%":"undefined"==typeof Map?i:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&g&&v?v((new Map)[Symbol.iterator]()):i,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?i:Promise,"%Proxy%":"undefined"==typeof Proxy?i:Proxy,"%RangeError%":s,"%ReferenceError%":a,"%Reflect%":"undefined"==typeof Reflect?i:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?i:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&g&&v?v((new Set)[Symbol.iterator]()):i,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?i:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":g&&v?v(""[Symbol.iterator]()):i,"%Symbol%":g?Symbol:i,"%SyntaxError%":l,"%ThrowTypeError%":m,"%TypedArray%":w,"%TypeError%":d,"%Uint8Array%":"undefined"==typeof Uint8Array?i:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?i:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?i:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?i:Uint32Array,"%URIError%":c,"%WeakMap%":"undefined"==typeof WeakMap?i:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?i:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?i:WeakSet};if(v)try{null.error}catch(e){var x=v(v(e));_["%Error.prototype%"]=x}var S=function e(t){var r;if("%AsyncFunction%"===t)r=p("async function () {}");else if("%GeneratorFunction%"===t)r=p("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=p("async function* () {}");else if("%AsyncGenerator%"===t){var i=e("%AsyncGeneratorFunction%");i&&(r=i.prototype)}else if("%AsyncIteratorPrototype%"===t){var n=e("%AsyncGenerator%");n&&v&&(r=v(n.prototype))}return _[t]=r,r},k={__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"]},E=r(66743),T=r(9957),B=E.call(Function.call,Array.prototype.concat),C=E.call(Function.apply,Array.prototype.splice),I=E.call(Function.call,String.prototype.replace),A=E.call(Function.call,String.prototype.slice),F=E.call(Function.call,RegExp.prototype.exec),M=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,D=/\\(\\)?/g,R=function(e,t){var r,i=e;if(T(k,i)&&(i="%"+(r=k[i])[0]+"%"),T(_,i)){var n=_[i];if(n===b&&(n=S(i)),void 0===n&&!t)throw new d("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:i,value:n}}throw new l("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new d("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new d('"allowMissing" argument must be a boolean');if(null===F(/^%?[^%]*%?$/,e))throw new l("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=function(e){var t=A(e,0,1),r=A(e,-1);if("%"===t&&"%"!==r)throw new l("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new l("invalid intrinsic syntax, expected opening `%`");var i=[];return I(e,M,(function(e,t,r,n){i[i.length]=r?I(n,D,"$1"):t||e})),i}(e),i=r.length>0?r[0]:"",n=R("%"+i+"%",t),o=n.name,s=n.value,a=!1,c=n.alias;c&&(i=c[0],C(r,B([0,1],c)));for(var u=1,p=!0;u=r.length){var y=h(s,f);s=(p=!!y)&&"get"in y&&!("originalValue"in y.get)?y.get:s[f]}else p=T(s,f),s=s[f];p&&!a&&(_[o]=s)}}return s}},75795:(e,t,r)=>{"use strict";var i=r(70453)("%Object.getOwnPropertyDescriptor%",!0);if(i)try{i([],"length")}catch(e){i=null}e.exports=i},30592:(e,t,r)=>{"use strict";var i=r(30655),n=function(){return!!i};n.hasArrayLengthDefineBug=function(){if(!i)return null;try{return 1!==i([],"length",{value:1}).length}catch(e){return!0}},e.exports=n},80024:e=>{"use strict";var t={__proto__:null,foo:{}},r=Object;e.exports=function(){return{__proto__:t}.foo===t.foo&&!(t instanceof r)}},64039:(e,t,r)=>{"use strict";var i="undefined"!=typeof Symbol&&Symbol,n=r(41333);e.exports=function(){return"function"==typeof i&&("function"==typeof Symbol&&("symbol"==typeof i("foo")&&("symbol"==typeof Symbol("bar")&&n())))}},41333:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var n=Object.getOwnPropertyDescriptor(e,t);if(42!==n.value||!0!==n.enumerable)return!1}return!0}},49092:(e,t,r)=>{"use strict";var i=r(41333);e.exports=function(){return i()&&!!Symbol.toStringTag}},4729:(e,t,r)=>{"use strict";var i=r(92861).Buffer,n=r(88310).Transform;function o(e){n.call(this),this._block=i.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(56698)(o,n),o.prototype._transform=function(e,t,r){var i=null;try{this.update(e,t)}catch(e){i=e}r(i)},o.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},o.prototype.update=function(e,t){if(function(e,t){if(!i.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}(e,"Data"),this._finalized)throw new Error("Digest already called");i.isBuffer(e)||(e=i.from(e,t));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var o=this._blockOffset;o0;++s)this._length[s]+=a,(a=this._length[s]/4294967296|0)>0&&(this._length[s]-=4294967296*a);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},o.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=o},77952:(e,t,r)=>{var i=t;i.utils=r(45045),i.common=r(66166),i.sha=r(46229),i.ripemd=r(46784),i.hmac=r(28948),i.sha1=i.sha.sha1,i.sha256=i.sha.sha256,i.sha224=i.sha.sha224,i.sha384=i.sha.sha384,i.sha512=i.sha.sha512,i.ripemd160=i.ripemd.ripemd160},66166:(e,t,r)=>{"use strict";var i=r(45045),n=r(43349);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=i.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=i.join32(e,0,e.length-r,this.endian);for(var n=0;n>>24&255,i[n++]=e>>>16&255,i[n++]=e>>>8&255,i[n++]=255&e}else for(i[n++]=255&e,i[n++]=e>>>8&255,i[n++]=e>>>16&255,i[n++]=e>>>24&255,i[n++]=0,i[n++]=0,i[n++]=0,i[n++]=0,o=8;o{"use strict";var i=r(45045),n=r(43349);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(i.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),n(e.length<=this.blockSize);for(var t=e.length;t{"use strict";var i=r(45045),n=r(66166),o=i.rotl32,s=i.sum32,a=i.sum32_3,l=i.sum32_4,d=n.BlockHash;function c(){if(!(this instanceof c))return new c;d.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function u(e,t,r,i){return e<=15?t^r^i:e<=31?t&r|~t&i:e<=47?(t|~r)^i:e<=63?t&i|r&~i:t^(r|~i)}function p(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function h(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}i.inherits(c,d),t.ripemd160=c,c.blockSize=512,c.outSize=160,c.hmacStrength=192,c.padLength=64,c.prototype._update=function(e,t){for(var r=this.h[0],i=this.h[1],n=this.h[2],d=this.h[3],c=this.h[4],v=r,b=i,w=n,_=d,x=c,S=0;S<80;S++){var k=s(o(l(r,u(S,i,n,d),e[f[S]+t],p(S)),g[S]),c);r=c,c=d,d=o(n,10),n=i,i=k,k=s(o(l(v,u(79-S,b,w,_),e[m[S]+t],h(S)),y[S]),x),v=x,x=_,_=o(w,10),w=b,b=k}k=a(this.h[1],n,_),this.h[1]=a(this.h[2],d,x),this.h[2]=a(this.h[3],c,v),this.h[3]=a(this.h[4],r,b),this.h[4]=a(this.h[0],i,w),this.h[0]=k},c.prototype._digest=function(e){return"hex"===e?i.toHex32(this.h,"little"):i.split32(this.h,"little")};var f=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],m=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],g=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],y=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]},46229:(e,t,r)=>{"use strict";t.sha1=r(43917),t.sha224=r(47714),t.sha256=r(2287),t.sha384=r(21911),t.sha512=r(57766)},43917:(e,t,r)=>{"use strict";var i=r(45045),n=r(66166),o=r(66225),s=i.rotl32,a=i.sum32,l=i.sum32_5,d=o.ft_1,c=n.BlockHash,u=[1518500249,1859775393,2400959708,3395469782];function p(){if(!(this instanceof p))return new p;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}i.inherits(p,c),e.exports=p,p.blockSize=512,p.outSize=160,p.hmacStrength=80,p.padLength=64,p.prototype._update=function(e,t){for(var r=this.W,i=0;i<16;i++)r[i]=e[t+i];for(;i{"use strict";var i=r(45045),n=r(2287);function o(){if(!(this instanceof o))return new o;n.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}i.inherits(o,n),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?i.toHex32(this.h.slice(0,7),"big"):i.split32(this.h.slice(0,7),"big")}},2287:(e,t,r)=>{"use strict";var i=r(45045),n=r(66166),o=r(66225),s=r(43349),a=i.sum32,l=i.sum32_4,d=i.sum32_5,c=o.ch32,u=o.maj32,p=o.s0_256,h=o.s1_256,f=o.g0_256,m=o.g1_256,g=n.BlockHash,y=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=y,this.W=new Array(64)}i.inherits(v,g),e.exports=v,v.blockSize=512,v.outSize=256,v.hmacStrength=192,v.padLength=64,v.prototype._update=function(e,t){for(var r=this.W,i=0;i<16;i++)r[i]=e[t+i];for(;i{"use strict";var i=r(45045),n=r(57766);function o(){if(!(this instanceof o))return new o;n.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}i.inherits(o,n),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?i.toHex32(this.h.slice(0,12),"big"):i.split32(this.h.slice(0,12),"big")}},57766:(e,t,r)=>{"use strict";var i=r(45045),n=r(66166),o=r(43349),s=i.rotr64_hi,a=i.rotr64_lo,l=i.shr64_hi,d=i.shr64_lo,c=i.sum64,u=i.sum64_hi,p=i.sum64_lo,h=i.sum64_4_hi,f=i.sum64_4_lo,m=i.sum64_5_hi,g=i.sum64_5_lo,y=n.BlockHash,v=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function b(){if(!(this instanceof b))return new b;y.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=v,this.W=new Array(160)}function w(e,t,r,i,n){var o=e&r^~e&n;return o<0&&(o+=4294967296),o}function _(e,t,r,i,n,o){var s=t&i^~t&o;return s<0&&(s+=4294967296),s}function x(e,t,r,i,n){var o=e&r^e&n^r&n;return o<0&&(o+=4294967296),o}function S(e,t,r,i,n,o){var s=t&i^t&o^i&o;return s<0&&(s+=4294967296),s}function k(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function E(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function T(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function B(e,t){var r=a(e,t,14)^a(e,t,18)^a(t,e,9);return r<0&&(r+=4294967296),r}function C(e,t){var r=s(e,t,1)^s(e,t,8)^l(e,t,7);return r<0&&(r+=4294967296),r}function I(e,t){var r=a(e,t,1)^a(e,t,8)^d(e,t,7);return r<0&&(r+=4294967296),r}function A(e,t){var r=s(e,t,19)^s(t,e,29)^l(e,t,6);return r<0&&(r+=4294967296),r}function F(e,t){var r=a(e,t,19)^a(t,e,29)^d(e,t,6);return r<0&&(r+=4294967296),r}i.inherits(b,y),e.exports=b,b.blockSize=1024,b.outSize=512,b.hmacStrength=192,b.padLength=128,b.prototype._prepareBlock=function(e,t){for(var r=this.W,i=0;i<32;i++)r[i]=e[t+i];for(;i{"use strict";var i=r(45045).rotr32;function n(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function s(e,t,r){return e^t^r}t.ft_1=function(e,t,r,i){return 0===e?n(t,r,i):1===e||3===e?s(t,r,i):2===e?o(t,r,i):void 0},t.ch32=n,t.maj32=o,t.p32=s,t.s0_256=function(e){return i(e,2)^i(e,13)^i(e,22)},t.s1_256=function(e){return i(e,6)^i(e,11)^i(e,25)},t.g0_256=function(e){return i(e,7)^i(e,18)^e>>>3},t.g1_256=function(e){return i(e,17)^i(e,19)^e>>>10}},45045:(e,t,r)=>{"use strict";var i=r(43349),n=r(56698);function o(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function s(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function a(e){return 1===e.length?"0"+e:e}function l(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=n,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),n=0;n>6|192,r[i++]=63&s|128):o(e,n)?(s=65536+((1023&s)<<10)+(1023&e.charCodeAt(++n)),r[i++]=s>>18|240,r[i++]=s>>12&63|128,r[i++]=s>>6&63|128,r[i++]=63&s|128):(r[i++]=s>>12|224,r[i++]=s>>6&63|128,r[i++]=63&s|128)}else for(n=0;n>>0}return s},t.split32=function(e,t){for(var r=new Array(4*e.length),i=0,n=0;i>>24,r[n+1]=o>>>16&255,r[n+2]=o>>>8&255,r[n+3]=255&o):(r[n+3]=o>>>24,r[n+2]=o>>>16&255,r[n+1]=o>>>8&255,r[n]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,i){return e+t+r+i>>>0},t.sum32_5=function(e,t,r,i,n){return e+t+r+i+n>>>0},t.sum64=function(e,t,r,i){var n=e[t],o=i+e[t+1]>>>0,s=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,i){return(t+i>>>0>>0},t.sum64_lo=function(e,t,r,i){return t+i>>>0},t.sum64_4_hi=function(e,t,r,i,n,o,s,a){var l=0,d=t;return l+=(d=d+i>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,i,n,o,s,a){return t+i+o+a>>>0},t.sum64_5_hi=function(e,t,r,i,n,o,s,a,l,d){var c=0,u=t;return c+=(u=u+i>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,i,n,o,s,a,l,d){return t+i+o+a+d>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},9957:(e,t,r)=>{"use strict";var i=Function.prototype.call,n=Object.prototype.hasOwnProperty,o=r(66743);e.exports=o.call(i,n)},32723:(e,t,r)=>{"use strict";var i=r(77952),n=r(64367),o=r(43349);function s(e){if(!(this instanceof s))return new s(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=n.toArray(e.entropy,e.entropyEnc||"hex"),r=n.toArray(e.nonce,e.nonceEnc||"hex"),i=n.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,i)}e.exports=s,s.prototype._init=function(e,t,r){var i=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var n=0;n=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},s.prototype.generate=function(e,t,r,i){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(i=r,r=t,t=null),r&&(r=n.toArray(r,i||"hex"),this._update(r));for(var o=[];o.length{"use strict";t.Us=void 0;var i=r(34550);function n(e){var t=i.statusCodeToReasonPhrase[e.toString()];if(!t)throw new Error("Status code does not exist: "+e);return t}t.Us=n},34550:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reasonPhraseToStatusCode=t.statusCodeToReasonPhrase=void 0,t.statusCodeToReasonPhrase={202:"Accepted",502:"Bad Gateway",400:"Bad Request",409:"Conflict",100:"Continue",201:"Created",417:"Expectation Failed",424:"Failed Dependency",403:"Forbidden",504:"Gateway Timeout",410:"Gone",505:"HTTP Version Not Supported",418:"I'm a teapot",419:"Insufficient Space on Resource",507:"Insufficient Storage",500:"Internal Server Error",411:"Length Required",423:"Locked",420:"Method Failure",405:"Method Not Allowed",301:"Moved Permanently",302:"Moved Temporarily",207:"Multi-Status",300:"Multiple Choices",511:"Network Authentication Required",204:"No Content",203:"Non Authoritative Information",406:"Not Acceptable",404:"Not Found",501:"Not Implemented",304:"Not Modified",200:"OK",206:"Partial Content",402:"Payment Required",308:"Permanent Redirect",412:"Precondition Failed",428:"Precondition Required",102:"Processing",103:"Early Hints",426:"Upgrade Required",407:"Proxy Authentication Required",431:"Request Header Fields Too Large",408:"Request Timeout",413:"Request Entity Too Large",414:"Request-URI Too Long",416:"Requested Range Not Satisfiable",205:"Reset Content",303:"See Other",503:"Service Unavailable",101:"Switching Protocols",307:"Temporary Redirect",429:"Too Many Requests",401:"Unauthorized",451:"Unavailable For Legal Reasons",422:"Unprocessable Entity",415:"Unsupported Media Type",305:"Use Proxy",421:"Misdirected Request"},t.reasonPhraseToStatusCode={Accepted:202,"Bad Gateway":502,"Bad Request":400,Conflict:409,Continue:100,Created:201,"Expectation Failed":417,"Failed Dependency":424,Forbidden:403,"Gateway Timeout":504,Gone:410,"HTTP Version Not Supported":505,"I'm a teapot":418,"Insufficient Space on Resource":419,"Insufficient Storage":507,"Internal Server Error":500,"Length Required":411,Locked:423,"Method Failure":420,"Method Not Allowed":405,"Moved Permanently":301,"Moved Temporarily":302,"Multi-Status":207,"Multiple Choices":300,"Network Authentication Required":511,"No Content":204,"Non Authoritative Information":203,"Not Acceptable":406,"Not Found":404,"Not Implemented":501,"Not Modified":304,OK:200,"Partial Content":206,"Payment Required":402,"Permanent Redirect":308,"Precondition Failed":412,"Precondition Required":428,Processing:102,"Early Hints":103,"Upgrade Required":426,"Proxy Authentication Required":407,"Request Header Fields Too Large":431,"Request Timeout":408,"Request Entity Too Large":413,"Request-URI Too Long":414,"Requested Range Not Satisfiable":416,"Reset Content":205,"See Other":303,"Service Unavailable":503,"Switching Protocols":101,"Temporary Redirect":307,"Too Many Requests":429,Unauthorized:401,"Unavailable For Legal Reasons":451,"Unprocessable Entity":422,"Unsupported Media Type":415,"Use Proxy":305,"Misdirected Request":421}},251:(e,t)=>{ +/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */ +t.read=function(e,t,r,i,n){var o,s,a=8*n-i-1,l=(1<>1,c=-7,u=r?n-1:0,p=r?-1:1,h=e[t+u];for(u+=p,o=h&(1<<-c)-1,h>>=-c,c+=a;c>0;o=256*o+e[t+u],u+=p,c-=8);for(s=o&(1<<-c)-1,o>>=-c,c+=i;c>0;s=256*s+e[t+u],u+=p,c-=8);if(0===o)o=1-d;else{if(o===l)return s?NaN:1/0*(h?-1:1);s+=Math.pow(2,i),o-=d}return(h?-1:1)*s*Math.pow(2,o-i)},t.write=function(e,t,r,i,n,o){var s,a,l,d=8*o-n-1,c=(1<>1,p=23===n?Math.pow(2,-24)-Math.pow(2,-77):0,h=i?0:o-1,f=i?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=c):(s=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-s))<1&&(s--,l*=2),(t+=s+u>=1?p/l:p*Math.pow(2,1-u))*l>=2&&(s++,l/=2),s+u>=c?(a=0,s=c):s+u>=1?(a=(t*l-1)*Math.pow(2,n),s+=u):(a=t*Math.pow(2,u-1)*Math.pow(2,n),s=0));n>=8;e[r+h]=255&a,h+=f,a/=256,n-=8);for(s=s<0;e[r+h]=255&s,h+=f,s/=256,d-=8);e[r+h-f]|=128*m}},56698:e=>{"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},20311:e=>{"use strict";e.exports=function(e,t,r,i,n,o,s,a){if(!e){var l;if(void 0===t)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var d=[r,i,n,o,s,a],c=0;(l=new Error(t.replace(/%s/g,(function(){return d[c++]})))).name="Invariant Violation"}throw l.framesToPop=1,l}}},47244:(e,t,r)=>{"use strict";var i=r(49092)(),n=r(38075)("Object.prototype.toString"),o=function(e){return!(i&&e&&"object"==typeof e&&Symbol.toStringTag in e)&&"[object Arguments]"===n(e)},s=function(e){return!!o(e)||null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==n(e)&&"[object Function]"===n(e.callee)},a=function(){return o(arguments)}();o.isLegacyArguments=s,e.exports=a?o:s},69600:e=>{"use strict";var t,r,i=Function.prototype.toString,n="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof n&&"function"==typeof Object.defineProperty)try{t=Object.defineProperty({},"length",{get:function(){throw r}}),r={},n((function(){throw 42}),null,t)}catch(e){e!==r&&(n=null)}else n=null;var o=/^\s*class\b/,s=function(e){try{var t=i.call(e);return o.test(t)}catch(e){return!1}},a=function(e){try{return!s(e)&&(i.call(e),!0)}catch(e){return!1}},l=Object.prototype.toString,d="function"==typeof Symbol&&!!Symbol.toStringTag,c=!(0 in[,]),u=function(){return!1};if("object"==typeof document){var p=document.all;l.call(p)===l.call(document.all)&&(u=function(e){if((c||!e)&&(void 0===e||"object"==typeof e))try{var t=l.call(e);return("[object HTMLAllCollection]"===t||"[object HTML document.all class]"===t||"[object HTMLCollection]"===t||"[object Object]"===t)&&null==e("")}catch(e){}return!1})}e.exports=n?function(e){if(u(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;try{n(e,null,t)}catch(e){if(e!==r)return!1}return!s(e)&&a(e)}:function(e){if(u(e))return!0;if(!e)return!1;if("function"!=typeof e&&"object"!=typeof e)return!1;if(d)return a(e);if(s(e))return!1;var t=l.call(e);return!("[object Function]"!==t&&"[object GeneratorFunction]"!==t&&!/^\[object HTML/.test(t))&&a(e)}},48184:(e,t,r)=>{"use strict";var i,n=Object.prototype.toString,o=Function.prototype.toString,s=/^\s*(?:function)?\*/,a=r(49092)(),l=Object.getPrototypeOf;e.exports=function(e){if("function"!=typeof e)return!1;if(s.test(o.call(e)))return!0;if(!a)return"[object GeneratorFunction]"===n.call(e);if(!l)return!1;if(void 0===i){var t=function(){if(!a)return!1;try{return Function("return function*() {}")()}catch(e){}}();i=!!t&&l(t)}return l(e)===i}},88997:e=>{"use strict";e.exports=function(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}},35680:(e,t,r)=>{"use strict";var i=r(25767);e.exports=function(e){return!!i(e)}},64634:e=>{var t={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==t.call(e)}},37260:(e,t,r)=>{var i=r(25747);e.exports=function(e,t){t=t||{};var r=i.decode(e,t);if(!r)return null;var n=r.payload;if("string"==typeof n)try{var o=JSON.parse(n);null!==o&&"object"==typeof o&&(n=o)}catch(e){}return!0===t.complete?{header:r.header,payload:n,signature:r.signature}:n}},44040:(e,t,r)=>{e.exports={decode:r(37260),verify:r(91691),sign:r(37651),JsonWebTokenError:r(81741),NotBeforeError:r(13726),TokenExpiredError:r(18980)}},81741:e=>{var t=function(e,t){Error.call(this,e),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor),this.name="JsonWebTokenError",this.message=e,t&&(this.inner=t)};(t.prototype=Object.create(Error.prototype)).constructor=t,e.exports=t},13726:(e,t,r)=>{var i=r(81741),n=function(e,t){i.call(this,e),this.name="NotBeforeError",this.date=t};(n.prototype=Object.create(i.prototype)).constructor=n,e.exports=n},18980:(e,t,r)=>{var i=r(81741),n=function(e,t){i.call(this,e),this.name="TokenExpiredError",this.expiredAt=t};(n.prototype=Object.create(i.prototype)).constructor=n,e.exports=n},1977:(e,t,r)=>{var i=r(65606);const n=r(99589);e.exports=n.satisfies(i.version,">=15.7.0")},74977:(e,t,r)=>{var i=r(65606),n=r(99589);e.exports=n.satisfies(i.version,"^6.12.0 || >=8.0.0")},34623:(e,t,r)=>{var i=r(65606);const n=r(99589);e.exports=n.satisfies(i.version,">=16.9.0")},40855:(e,t,r)=>{var i=r(6585);e.exports=function(e,t){var r=t||Math.floor(Date.now()/1e3);if("string"==typeof e){var n=i(e);if(void 0===n)return;return Math.floor(r+n/1e3)}return"number"==typeof e?r+e:void 0}},47019:(e,t,r)=>{const i=r(1977),n=r(34623),o={ec:["ES256","ES384","ES512"],rsa:["RS256","PS256","RS384","PS384","RS512","PS512"],"rsa-pss":["PS256","PS384","PS512"]},s={ES256:"prime256v1",ES384:"secp384r1",ES512:"secp521r1"};e.exports=function(e,t){if(!e||!t)return;const r=t.asymmetricKeyType;if(!r)return;const a=o[r];if(!a)throw new Error(`Unknown key type "${r}".`);if(!a.includes(e))throw new Error(`"alg" parameter for "${r}" key type must be one of: ${a.join(", ")}.`);if(i)switch(r){case"ec":const r=t.asymmetricKeyDetails.namedCurve,i=s[e];if(r!==i)throw new Error(`"alg" parameter "${e}" requires curve "${i}".`);break;case"rsa-pss":if(n){const r=parseInt(e.slice(-3),10),{hashAlgorithm:i,mgf1HashAlgorithm:n,saltLength:o}=t.asymmetricKeyDetails;if(i!==`sha${r}`||n!==i)throw new Error(`Invalid key for this operation, its RSA-PSS parameters do not meet the requirements of "alg" ${e}.`);if(void 0!==o&&o>r>>3)throw new Error(`Invalid key for this operation, its RSA-PSS parameter saltLength does not meet the requirements of "alg" ${e}.`)}}}},37651:(e,t,r)=>{var i=r(48287).Buffer;const n=r(40855),o=r(74977),s=r(47019),a=r(25747),l=r(46111),d=r(87914),c=r(58928),u=r(73639),p=r(79001),h=r(45931),f=r(67083),{KeyObject:m,createSecretKey:g,createPrivateKey:y}=r(91565),v=["RS256","RS384","RS512","ES256","ES384","ES512","HS256","HS384","HS512","none"];o&&v.splice(3,0,"PS256","PS384","PS512");const b={expiresIn:{isValid:function(e){return c(e)||h(e)&&e},message:'"expiresIn" should be a number of seconds or string representing a timespan'},notBefore:{isValid:function(e){return c(e)||h(e)&&e},message:'"notBefore" should be a number of seconds or string representing a timespan'},audience:{isValid:function(e){return h(e)||Array.isArray(e)},message:'"audience" must be a string or array'},algorithm:{isValid:l.bind(null,v),message:'"algorithm" must be a valid string enum value'},header:{isValid:p,message:'"header" must be an object'},encoding:{isValid:h,message:'"encoding" must be a string'},issuer:{isValid:h,message:'"issuer" must be a string'},subject:{isValid:h,message:'"subject" must be a string'},jwtid:{isValid:h,message:'"jwtid" must be a string'},noTimestamp:{isValid:d,message:'"noTimestamp" must be a boolean'},keyid:{isValid:h,message:'"keyid" must be a string'},mutatePayload:{isValid:d,message:'"mutatePayload" must be a boolean'},allowInsecureKeySizes:{isValid:d,message:'"allowInsecureKeySizes" must be a boolean'},allowInvalidAsymmetricKeyTypes:{isValid:d,message:'"allowInvalidAsymmetricKeyTypes" must be a boolean'}},w={iat:{isValid:u,message:'"iat" should be a number of seconds'},exp:{isValid:u,message:'"exp" should be a number of seconds'},nbf:{isValid:u,message:'"nbf" should be a number of seconds'}};function _(e,t,r,i){if(!p(r))throw new Error('Expected "'+i+'" to be a plain object.');Object.keys(r).forEach((function(n){const o=e[n];if(o){if(!o.isValid(r[n]))throw new Error(o.message)}else if(!t)throw new Error('"'+n+'" is not allowed in "'+i+'"')}))}const x={audience:"aud",issuer:"iss",subject:"sub",jwtid:"jti"},S=["expiresIn","notBefore","noTimestamp","audience","issuer","subject","jwtid"];e.exports=function(e,t,r,o){"function"==typeof r?(o=r,r={}):r=r||{};const l="object"==typeof e&&!i.isBuffer(e),d=Object.assign({alg:r.algorithm||"HS256",typ:l?"JWT":void 0,kid:r.keyid},r.header);function c(e){if(o)return o(e);throw e}if(!t&&"none"!==r.algorithm)return c(new Error("secretOrPrivateKey must have a value"));if(null!=t&&!(t instanceof m))try{t=y(t)}catch(e){try{t=g("string"==typeof t?i.from(t):t)}catch(e){return c(new Error("secretOrPrivateKey is not valid key material"))}}if(d.alg.startsWith("HS")&&"secret"!==t.type)return c(new Error(`secretOrPrivateKey must be a symmetric key when using ${d.alg}`));if(/^(?:RS|PS|ES)/.test(d.alg)){if("private"!==t.type)return c(new Error(`secretOrPrivateKey must be an asymmetric key when using ${d.alg}`));if(!r.allowInsecureKeySizes&&!d.alg.startsWith("ES")&&void 0!==t.asymmetricKeyDetails&&t.asymmetricKeyDetails.modulusLength<2048)return c(new Error(`secretOrPrivateKey has a minimum key size of 2048 bits for ${d.alg}`))}if(void 0===e)return c(new Error("payload is required"));if(l){try{!function(e){_(w,!0,e,"payload")}(e)}catch(e){return c(e)}r.mutatePayload||(e=Object.assign({},e))}else{const t=S.filter((function(e){return void 0!==r[e]}));if(t.length>0)return c(new Error("invalid "+t.join(",")+" option for "+typeof e+" payload"))}if(void 0!==e.exp&&void 0!==r.expiresIn)return c(new Error('Bad "options.expiresIn" option the payload already has an "exp" property.'));if(void 0!==e.nbf&&void 0!==r.notBefore)return c(new Error('Bad "options.notBefore" option the payload already has an "nbf" property.'));try{!function(e){_(b,!1,e,"options")}(r)}catch(e){return c(e)}if(!r.allowInvalidAsymmetricKeyTypes)try{s(d.alg,t)}catch(e){return c(e)}const u=e.iat||Math.floor(Date.now()/1e3);if(r.noTimestamp?delete e.iat:l&&(e.iat=u),void 0!==r.notBefore){try{e.nbf=n(r.notBefore,u)}catch(e){return c(e)}if(void 0===e.nbf)return c(new Error('"notBefore" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60'))}if(void 0!==r.expiresIn&&"object"==typeof e){try{e.exp=n(r.expiresIn,u)}catch(e){return c(e)}if(void 0===e.exp)return c(new Error('"expiresIn" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60'))}Object.keys(x).forEach((function(t){const i=x[t];if(void 0!==r[t]){if(void 0!==e[i])return c(new Error('Bad "options.'+t+'" option. The payload already has an "'+i+'" property.'));e[i]=r[t]}}));const p=r.encoding||"utf8";if("function"!=typeof o){let i=a.sign({header:d,payload:e,secret:t,encoding:p});if(!r.allowInsecureKeySizes&&/^(?:RS|PS)/.test(d.alg)&&i.length<256)throw new Error(`secretOrPrivateKey has a minimum key size of 2048 bits for ${d.alg}`);return i}o=o&&f(o),a.createSign({header:d,privateKey:t,payload:e,encoding:p}).once("error",o).once("done",(function(e){if(!r.allowInsecureKeySizes&&/^(?:RS|PS)/.test(d.alg)&&e.length<256)return o(new Error(`secretOrPrivateKey has a minimum key size of 2048 bits for ${d.alg}`));o(null,e)}))}},91691:(e,t,r)=>{var i=r(48287).Buffer;const n=r(81741),o=r(13726),s=r(18980),a=r(37260),l=r(40855),d=r(47019),c=r(74977),u=r(25747),{KeyObject:p,createSecretKey:h,createPublicKey:f}=r(91565),m=["RS256","RS384","RS512"],g=["ES256","ES384","ES512"],y=["RS256","RS384","RS512"],v=["HS256","HS384","HS512"];c&&(m.splice(m.length,0,"PS256","PS384","PS512"),y.splice(y.length,0,"PS256","PS384","PS512")),e.exports=function(e,t,r,c){let b;if("function"!=typeof r||c||(c=r,r={}),r||(r={}),r=Object.assign({},r),b=c||function(e,t){if(e)throw e;return t},r.clockTimestamp&&"number"!=typeof r.clockTimestamp)return b(new n("clockTimestamp must be a number"));if(void 0!==r.nonce&&("string"!=typeof r.nonce||""===r.nonce.trim()))return b(new n("nonce must be a non-empty string"));if(void 0!==r.allowInvalidAsymmetricKeyTypes&&"boolean"!=typeof r.allowInvalidAsymmetricKeyTypes)return b(new n("allowInvalidAsymmetricKeyTypes must be a boolean"));const w=r.clockTimestamp||Math.floor(Date.now()/1e3);if(!e)return b(new n("jwt must be provided"));if("string"!=typeof e)return b(new n("jwt must be a string"));const _=e.split(".");if(3!==_.length)return b(new n("jwt malformed"));let x;try{x=a(e,{complete:!0})}catch(e){return b(e)}if(!x)return b(new n("invalid token"));const S=x.header;let k;if("function"==typeof t){if(!c)return b(new n("verify must be called asynchronous if secret or public key is provided as a callback"));k=t}else k=function(e,r){return r(null,t)};return k(S,(function(t,a){if(t)return b(new n("error in secret or public key callback: "+t.message));const c=""!==_[2].trim();if(!c&&a)return b(new n("jwt signature is required"));if(c&&!a)return b(new n("secret or public key must be provided"));if(!c&&!r.algorithms)return b(new n('please specify "none" in "algorithms" to verify unsigned tokens'));if(null!=a&&!(a instanceof p))try{a=f(a)}catch(e){try{a=h("string"==typeof a?i.from(a):a)}catch(e){return b(new n("secretOrPublicKey is not valid key material"))}}if(r.algorithms||("secret"===a.type?r.algorithms=v:["rsa","rsa-pss"].includes(a.asymmetricKeyType)?r.algorithms=y:"ec"===a.asymmetricKeyType?r.algorithms=g:r.algorithms=m),-1===r.algorithms.indexOf(x.header.alg))return b(new n("invalid algorithm"));if(S.alg.startsWith("HS")&&"secret"!==a.type)return b(new n(`secretOrPublicKey must be a symmetric key when using ${S.alg}`));if(/^(?:RS|PS|ES)/.test(S.alg)&&"public"!==a.type)return b(new n(`secretOrPublicKey must be an asymmetric key when using ${S.alg}`));if(!r.allowInvalidAsymmetricKeyTypes)try{d(S.alg,a)}catch(e){return b(e)}let k;try{k=u.verify(e,x.header.alg,a)}catch(e){return b(e)}if(!k)return b(new n("invalid signature"));const E=x.payload;if(void 0!==E.nbf&&!r.ignoreNotBefore){if("number"!=typeof E.nbf)return b(new n("invalid nbf value"));if(E.nbf>w+(r.clockTolerance||0))return b(new o("jwt not active",new Date(1e3*E.nbf)))}if(void 0!==E.exp&&!r.ignoreExpiration){if("number"!=typeof E.exp)return b(new n("invalid exp value"));if(w>=E.exp+(r.clockTolerance||0))return b(new s("jwt expired",new Date(1e3*E.exp)))}if(r.audience){const e=Array.isArray(r.audience)?r.audience:[r.audience];if(!(Array.isArray(E.aud)?E.aud:[E.aud]).some((function(t){return e.some((function(e){return e instanceof RegExp?e.test(t):e===t}))})))return b(new n("jwt audience invalid. expected: "+e.join(" or ")))}if(r.issuer){if("string"==typeof r.issuer&&E.iss!==r.issuer||Array.isArray(r.issuer)&&-1===r.issuer.indexOf(E.iss))return b(new n("jwt issuer invalid. expected: "+r.issuer))}if(r.subject&&E.sub!==r.subject)return b(new n("jwt subject invalid. expected: "+r.subject));if(r.jwtid&&E.jti!==r.jwtid)return b(new n("jwt jwtid invalid. expected: "+r.jwtid));if(r.nonce&&E.nonce!==r.nonce)return b(new n("jwt nonce invalid. expected: "+r.nonce));if(r.maxAge){if("number"!=typeof E.iat)return b(new n("iat required when maxAge is specified"));const e=l(r.maxAge,E.iat);if(void 0===e)return b(new n('"maxAge" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60'));if(w>=e+(r.clockTolerance||0))return b(new s("maxAge exceeded",new Date(1e3*e)))}if(!0===r.complete){const e=x.signature;return b(null,{header:S,payload:E,signature:e})}return b(null,E)}))}},58789:(e,t,r)=>{var i=r(41045),n=r(92861).Buffer,o=r(91565),s=r(22010),a=r(40537),l="secret must be a string or buffer",d="key must be a string or a buffer",c="function"==typeof o.createPublicKey;function u(e){if(!n.isBuffer(e)&&"string"!=typeof e){if(!c)throw m(d);if("object"!=typeof e)throw m(d);if("string"!=typeof e.type)throw m(d);if("string"!=typeof e.asymmetricKeyType)throw m(d);if("function"!=typeof e.export)throw m(d)}}function p(e){if(!n.isBuffer(e)&&"string"!=typeof e&&"object"!=typeof e)throw m("key must be a string, a buffer or an object")}function h(e){return e.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function f(e){var t=4-(e=e.toString()).length%4;if(4!==t)for(var r=0;r{var i=r(13387),n=r(57599);t.ALGORITHMS=["HS256","HS384","HS512","RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],t.sign=i.sign,t.verify=n.verify,t.decode=n.decode,t.isValid=n.isValid,t.createSign=function(e){return new i(e)},t.createVerify=function(e){return new n(e)}},18948:(e,t,r)=>{var i=r(65606),n=r(92861).Buffer,o=r(88310);function s(e){if(this.buffer=null,this.writable=!0,this.readable=!0,!e)return this.buffer=n.alloc(0),this;if("function"==typeof e.pipe)return this.buffer=n.alloc(0),e.pipe(this),this;if(e.length||"object"==typeof e)return this.buffer=e,this.writable=!1,i.nextTick(function(){this.emit("end",e),this.readable=!1,this.emit("close")}.bind(this)),this;throw new TypeError("Unexpected data type ("+typeof e+")")}r(40537).inherits(s,o),s.prototype.write=function(e){this.buffer=n.concat([this.buffer,n.from(e)]),this.emit("data",e)},s.prototype.end=function(e){e&&this.write(e),this.emit("end",e),this.emit("close"),this.writable=!1,this.readable=!1},e.exports=s},13387:(e,t,r)=>{var i=r(92861).Buffer,n=r(18948),o=r(58789),s=r(88310),a=r(82851),l=r(40537);function d(e,t){return i.from(e,t).toString("base64").replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function c(e){var t=e.header,r=e.payload,i=e.secret||e.privateKey,n=e.encoding,s=o(t.alg),c=function(e,t,r){r=r||"utf8";var i=d(a(e),"binary"),n=d(a(t),r);return l.format("%s.%s",i,n)}(t,r,n),u=s.sign(c,i);return l.format("%s.%s",c,u)}function u(e){var t=e.secret||e.privateKey||e.key,r=new n(t);this.readable=!0,this.header=e.header,this.encoding=e.encoding,this.secret=this.privateKey=this.key=r,this.payload=new n(e.payload),this.secret.once("close",function(){!this.payload.writable&&this.readable&&this.sign()}.bind(this)),this.payload.once("close",function(){!this.secret.writable&&this.readable&&this.sign()}.bind(this))}l.inherits(u,s),u.prototype.sign=function(){try{var e=c({header:this.header,payload:this.payload.buffer,secret:this.secret.buffer,encoding:this.encoding});return this.emit("done",e),this.emit("data",e),this.emit("end"),this.readable=!1,e}catch(e){this.readable=!1,this.emit("error",e),this.emit("close")}},u.sign=c,e.exports=u},82851:(e,t,r)=>{var i=r(48287).Buffer;e.exports=function(e){return"string"==typeof e?e:"number"==typeof e||i.isBuffer(e)?e.toString():JSON.stringify(e)}},57599:(e,t,r)=>{var i=r(92861).Buffer,n=r(18948),o=r(58789),s=r(88310),a=r(82851),l=r(40537),d=/^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/;function c(e){if(function(e){return"[object Object]"===Object.prototype.toString.call(e)}(e))return e;try{return JSON.parse(e)}catch(e){return}}function u(e){var t=e.split(".",1)[0];return c(i.from(t,"base64").toString("binary"))}function p(e){return e.split(".")[2]}function h(e){return d.test(e)&&!!u(e)}function f(e,t,r){if(!t){var i=new Error("Missing algorithm parameter for jws.verify");throw i.code="MISSING_ALGORITHM",i}var n=p(e=a(e)),s=function(e){return e.split(".",2).join(".")}(e);return o(t).verify(s,n,r)}function m(e,t){if(t=t||{},!h(e=a(e)))return null;var r=u(e);if(!r)return null;var n=function(e,t){t=t||"utf8";var r=e.split(".")[1];return i.from(r,"base64").toString(t)}(e);return("JWT"===r.typ||t.json)&&(n=JSON.parse(n,t.encoding)),{header:r,payload:n,signature:p(e)}}function g(e){var t=(e=e||{}).secret||e.publicKey||e.key,r=new n(t);this.readable=!0,this.algorithm=e.algorithm,this.encoding=e.encoding,this.secret=this.publicKey=this.key=r,this.signature=new n(e.signature),this.secret.once("close",function(){!this.signature.writable&&this.readable&&this.verify()}.bind(this)),this.signature.once("close",function(){!this.secret.writable&&this.readable&&this.verify()}.bind(this))}l.inherits(g,s),g.prototype.verify=function(){try{var e=f(this.signature.buffer,this.algorithm,this.key.buffer),t=m(this.signature.buffer,this.encoding);return this.emit("done",e,t),this.emit("data",e),this.emit("end"),this.readable=!1,e}catch(e){this.readable=!1,this.emit("error",e),this.emit("close")}},g.decode=m,g.isValid=h,g.verify=f,e.exports=g},98860:function(e,t,r){!function(e,t){"use strict";function r(e){return r.result?r.result:e&&"function"==typeof e.getSerializer?(r.result=e.getSerializer(),r.result):Promise.reject(new Error("localforage.getSerializer() was not available! localforage v1.4+ is required!"))}function i(e,t){return t&&e.then((function(e){t(null,e)}),(function(e){t(e)})),e}function n(e,t){var r=this.getItem(e).then((function(t){return{key:e,value:t}}));return i(r,t),r}function o(e){var t=this,r=new Promise((function(r,i){for(var o=[],s=0,a=e.length;st?1:0}var i=new Promise((function(i,n){t.ready().then((function(){var o=t._dbInfo,s=o.db.transaction(o.storeName,"readonly").objectStore(o.storeName),a=e.sort(r),d=l.bound(e[0],e[e.length-1],!1,!1),c=s.openCursor(d),u={},p=0;c.onsuccess=function(){var e=c.result;if(e){for(var t=e.key;t>a[p];)if(++p===a.length)return void i(u);if(t===a[p]){var r=e.value;void 0===r&&(r=null),u[t]=r,e.continue()}else e.continue(a[p])}else i(u)},c.onerror=function(){n(c.error)}})).catch(n)}));return i}function c(e){var t=this,i=new Promise((function(i,n){t.ready().then((function(){return r(t)})).then((function(r){var o=t._dbInfo;o.db.transaction((function(t){for(var s=new Array(e.length),a=0,l=e.length;a{ +/*! + localForage -- Offline Storage, Improved + Version 1.10.0 + https://localforage.github.io/localForage + (c) 2013-2017 Mozilla, Apache License 2.0 +*/ +e.exports=function e(t,r,i){function n(s,a){if(!r[s]){if(!t[s]){if(o)return o(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var d=r[s]={exports:{}};t[s][0].call(d.exports,(function(e){var r=t[s][1][e];return n(r||e)}),d,d.exports,e,t,r,i)}return r[s].exports}for(var o=void 0,s=0;s=43)}})).catch((function(){return!1}))}function x(e){return"boolean"==typeof m?d.resolve(m):_(e).then((function(e){return m=e}))}function S(e){var t=g[e.name],r={};r.promise=new d((function(e,t){r.resolve=e,r.reject=t})),t.deferredOperations.push(r),t.dbReady?t.dbReady=t.dbReady.then((function(){return r.promise})):t.dbReady=r.promise}function k(e){var t=g[e.name].deferredOperations.pop();if(t)return t.resolve(),t.promise}function E(e,t){var r=g[e.name].deferredOperations.pop();if(r)return r.reject(t),r.promise}function T(e,t){return new d((function(r,i){if(g[e.name]=g[e.name]||O(),e.db){if(!t)return r(e.db);S(e),e.db.close()}var n=[e.name];t&&n.push(e.version);var o=s.open.apply(s,n);t&&(o.onupgradeneeded=function(t){var r=o.result;try{r.createObjectStore(e.storeName),t.oldVersion<=1&&r.createObjectStore(f)}catch(r){if("ConstraintError"!==r.name)throw r;console.warn('The database "'+e.name+'" has been upgraded from version '+t.oldVersion+" to version "+t.newVersion+', but the storage "'+e.storeName+'" already exists.')}}),o.onerror=function(e){e.preventDefault(),i(o.error)},o.onsuccess=function(){var t=o.result;t.onversionchange=function(e){e.target.close()},r(t),k(e)}}))}function B(e){return T(e,!1)}function C(e){return T(e,!0)}function I(e,t){if(!e.db)return!0;var r=!e.db.objectStoreNames.contains(e.storeName),i=e.versione.db.version;if(i&&(e.version!==t&&console.warn('The database "'+e.name+"\" can't be downgraded from version "+e.db.version+" to version "+e.version+"."),e.version=e.db.version),n||r){if(r){var o=e.db.version+1;o>e.version&&(e.version=o)}return!0}return!1}function A(e){return new d((function(t,r){var i=new FileReader;i.onerror=r,i.onloadend=function(r){var i=btoa(r.target.result||"");t({__local_forage_encoded_blob:!0,data:i,type:e.type})},i.readAsBinaryString(e)}))}function F(e){return l([w(atob(e.data))],{type:e.type})}function M(e){return e&&e.__local_forage_encoded_blob}function D(e){var t=this,r=t._initReady().then((function(){var e=g[t._dbInfo.name];if(e&&e.dbReady)return e.dbReady}));return u(r,e,e),r}function R(e){S(e);for(var t=g[e.name],r=t.forages,i=0;i0&&(!e.db||"InvalidStateError"===n.name||"NotFoundError"===n.name))return d.resolve().then((function(){if(!e.db||"NotFoundError"===n.name&&!e.db.objectStoreNames.contains(e.storeName)&&e.version<=e.db.version)return e.db&&(e.version=e.db.version+1),C(e)})).then((function(){return R(e).then((function(){P(e,t,r,i-1)}))})).catch(r);r(n)}}function O(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function z(e){var t=this,r={db:null};if(e)for(var i in e)r[i]=e[i];var n=g[r.name];n||(n=O(),g[r.name]=n),n.forages.push(t),t._initReady||(t._initReady=t.ready,t.ready=D);var o=[];function s(){return d.resolve()}for(var a=0;a>4,c[l++]=(15&i)<<4|n>>2,c[l++]=(3&n)<<6|63&o;return d}function fe(e){var t,r=new Uint8Array(e),i="";for(t=0;t>2],i+=J[(3&r[t])<<4|r[t+1]>>4],i+=J[(15&r[t+1])<<2|r[t+2]>>6],i+=J[63&r[t+2]];return r.length%3==2?i=i.substring(0,i.length-1)+"=":r.length%3==1&&(i=i.substring(0,i.length-2)+"=="),i}function me(e,t){var r="";if(e&&(r=pe.call(e)),e&&("[object ArrayBuffer]"===r||e.buffer&&"[object ArrayBuffer]"===pe.call(e.buffer))){var i,n=Z;e instanceof ArrayBuffer?(i=e,n+=ee):(i=e.buffer,"[object Int8Array]"===r?n+=re:"[object Uint8Array]"===r?n+=ie:"[object Uint8ClampedArray]"===r?n+=ne:"[object Int16Array]"===r?n+=oe:"[object Uint16Array]"===r?n+=ae:"[object Int32Array]"===r?n+=se:"[object Uint32Array]"===r?n+=le:"[object Float32Array]"===r?n+=de:"[object Float64Array]"===r?n+=ce:t(new Error("Failed to get type for BinaryArray"))),t(n+fe(i))}else if("[object Blob]"===r){var o=new FileReader;o.onload=function(){var r=Y+e.type+"~"+fe(this.result);t(Z+te+r)},o.readAsArrayBuffer(e)}else try{t(JSON.stringify(e))}catch(r){console.error("Couldn't convert value into a JSON string: ",e),t(null,r)}}function ge(e){if(e.substring(0,X)!==Z)return JSON.parse(e);var t,r=e.substring(ue),i=e.substring(X,ue);if(i===te&&Q.test(r)){var n=r.match(Q);t=n[1],r=r.substring(n[0].length)}var o=he(r);switch(i){case ee:return o;case te:return l([o],{type:t});case re:return new Int8Array(o);case ie:return new Uint8Array(o);case ne:return new Uint8ClampedArray(o);case oe:return new Int16Array(o);case ae:return new Uint16Array(o);case se:return new Int32Array(o);case le:return new Uint32Array(o);case de:return new Float32Array(o);case ce:return new Float64Array(o);default:throw new Error("Unkown type: "+i)}}var ye={serialize:me,deserialize:ge,stringToBuffer:he,bufferToString:fe};function ve(e,t,r,i){e.executeSql("CREATE TABLE IF NOT EXISTS "+t.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],r,i)}function be(e){var t=this,r={db:null};if(e)for(var i in e)r[i]="string"!=typeof e[i]?e[i].toString():e[i];var n=new d((function(e,i){try{r.db=openDatabase(r.name,String(r.version),r.description,r.size)}catch(e){return i(e)}r.db.transaction((function(n){ve(n,r,(function(){t._dbInfo=r,e()}),(function(e,t){i(t)}))}),i)}));return r.serializer=ye,n}function we(e,t,r,i,n,o){e.executeSql(r,i,n,(function(e,s){s.code===s.SYNTAX_ERR?e.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[t.storeName],(function(e,a){a.rows.length?o(e,s):ve(e,t,(function(){e.executeSql(r,i,n,o)}),o)}),o):o(e,s)}),o)}function _e(e,t){var r=this;e=p(e);var i=new d((function(t,i){r.ready().then((function(){var n=r._dbInfo;n.db.transaction((function(r){we(r,n,"SELECT * FROM "+n.storeName+" WHERE key = ? LIMIT 1",[e],(function(e,r){var i=r.rows.length?r.rows.item(0).value:null;i&&(i=n.serializer.deserialize(i)),t(i)}),(function(e,t){i(t)}))}))})).catch(i)}));return c(i,t),i}function xe(e,t){var r=this,i=new d((function(t,i){r.ready().then((function(){var n=r._dbInfo;n.db.transaction((function(r){we(r,n,"SELECT * FROM "+n.storeName,[],(function(r,i){for(var o=i.rows,s=o.length,a=0;a0)return void o(Se.apply(n,[e,a,r,i-1]));s(t)}}))}))})).catch(s)}));return c(o,r),o}function ke(e,t,r){return Se.apply(this,[e,t,r,1])}function Ee(e,t){var r=this;e=p(e);var i=new d((function(t,i){r.ready().then((function(){var n=r._dbInfo;n.db.transaction((function(r){we(r,n,"DELETE FROM "+n.storeName+" WHERE key = ?",[e],(function(){t()}),(function(e,t){i(t)}))}))})).catch(i)}));return c(i,t),i}function Te(e){var t=this,r=new d((function(e,r){t.ready().then((function(){var i=t._dbInfo;i.db.transaction((function(t){we(t,i,"DELETE FROM "+i.storeName,[],(function(){e()}),(function(e,t){r(t)}))}))})).catch(r)}));return c(r,e),r}function Be(e){var t=this,r=new d((function(e,r){t.ready().then((function(){var i=t._dbInfo;i.db.transaction((function(t){we(t,i,"SELECT COUNT(key) as c FROM "+i.storeName,[],(function(t,r){var i=r.rows.item(0).c;e(i)}),(function(e,t){r(t)}))}))})).catch(r)}));return c(r,e),r}function Ce(e,t){var r=this,i=new d((function(t,i){r.ready().then((function(){var n=r._dbInfo;n.db.transaction((function(r){we(r,n,"SELECT key FROM "+n.storeName+" WHERE id = ? LIMIT 1",[e+1],(function(e,r){var i=r.rows.length?r.rows.item(0).key:null;t(i)}),(function(e,t){i(t)}))}))})).catch(i)}));return c(i,t),i}function Ie(e){var t=this,r=new d((function(e,r){t.ready().then((function(){var i=t._dbInfo;i.db.transaction((function(t){we(t,i,"SELECT key FROM "+i.storeName,[],(function(t,r){for(var i=[],n=0;n '__WebKitDatabaseInfoTable__'",[],(function(r,i){for(var n=[],o=0;o0}function ze(e){var t=this,r={};if(e)for(var i in e)r[i]=e[i];return r.keyPrefix=Re(e,t._defaultConfig),Oe()?(t._dbInfo=r,r.serializer=ye,d.resolve()):d.reject()}function Ne(e){var t=this,r=t.ready().then((function(){for(var e=t._dbInfo.keyPrefix,r=localStorage.length-1;r>=0;r--){var i=localStorage.key(r);0===i.indexOf(e)&&localStorage.removeItem(i)}}));return c(r,e),r}function qe(e,t){var r=this;e=p(e);var i=r.ready().then((function(){var t=r._dbInfo,i=localStorage.getItem(t.keyPrefix+e);return i&&(i=t.serializer.deserialize(i)),i}));return c(i,t),i}function Ue(e,t){var r=this,i=r.ready().then((function(){for(var t=r._dbInfo,i=t.keyPrefix,n=i.length,o=localStorage.length,s=1,a=0;a=0;t--){var r=localStorage.key(t);0===r.indexOf(e)&&localStorage.removeItem(r)}})):d.reject("Invalid arguments"),c(i,t),i}var Ke={_driver:"localStorageWrapper",_initStorage:ze,_support:De(),iterate:Ue,getItem:qe,setItem:Ge,removeItem:$e,clear:Ne,length:He,key:Le,keys:je,dropInstance:We},Ve=function(e,t){return e===t||"number"==typeof e&&"number"==typeof t&&isNaN(e)&&isNaN(t)},Je=function(e,t){for(var r=e.length,i=0;i{var t=1/0,r=9007199254740991,i=17976931348623157e292,n=NaN,o="[object Arguments]",s="[object Function]",a="[object GeneratorFunction]",l="[object String]",d="[object Symbol]",c=/^\s+|\s+$/g,u=/^[-+]0x[0-9a-f]+$/i,p=/^0b[01]+$/i,h=/^0o[0-7]+$/i,f=/^(?:0|[1-9]\d*)$/,m=parseInt;function g(e){return e!=e}function y(e,t){return function(e,t){for(var r=-1,i=e?e.length:0,n=Array(i);++r-1&&e%1==0&&e-1&&e%1==0&&e<=r}(e.length)&&!function(e){var t=F(e)?x.call(e):"";return t==s||t==a}(e)}function F(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function M(e){return!!e&&"object"==typeof e}e.exports=function(e,r,o,s){var a;e=A(e)?e:(a=e)?y(a,function(e){return A(e)?T(e):B(e)}(a)):[],o=o&&!s?function(e){var r=function(e){if(!e)return 0===e?e:0;if(e=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||M(e)&&x.call(e)==d}(e))return n;if(F(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=F(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(c,"");var r=p.test(e);return r||h.test(e)?m(e.slice(2),r?2:8):u.test(e)?n:+e}(e),e===t||e===-1/0){return(e<0?-1:1)*i}return e==e?e:0}(e),o=r%1;return r==r?o?r-o:r:0}(o):0;var f=e.length;return o<0&&(o=E(f+o,0)),function(e){return"string"==typeof e||!I(e)&&M(e)&&x.call(e)==l}(e)?o<=f&&e.indexOf(r,o)>-1:!!f&&function(e,t,r){if(t!=t)return function(e,t,r,i){for(var n=e.length,o=r+(i?1:-1);i?o--:++o-1}},87914:e=>{var t=Object.prototype.toString;e.exports=function(e){return!0===e||!1===e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Boolean]"==t.call(e)}},58928:e=>{var t=1/0,r=17976931348623157e292,i=NaN,n="[object Symbol]",o=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,l=/^0o[0-7]+$/i,d=parseInt,c=Object.prototype.toString;function u(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=function(e){return"number"==typeof e&&e==function(e){var p=function(e){if(!e)return 0===e?e:0;if(e=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&c.call(e)==n}(e))return i;if(u(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=u(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var r=a.test(e);return r||l.test(e)?d(e.slice(2),r?2:8):s.test(e)?i:+e}(e),e===t||e===-1/0){return(e<0?-1:1)*r}return e==e?e:0}(e),h=p%1;return p==p?h?p-h:p:0}(e)}},73639:e=>{var t=Object.prototype.toString;e.exports=function(e){return"number"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Number]"==t.call(e)}},79001:e=>{var t,r,i=Function.prototype,n=Object.prototype,o=i.toString,s=n.hasOwnProperty,a=o.call(Object),l=n.toString,d=(t=Object.getPrototypeOf,r=Object,function(e){return t(r(e))});e.exports=function(e){if(!function(e){return!!e&&"object"==typeof e}(e)||"[object Object]"!=l.call(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e))return!1;var t=d(e);if(null===t)return!0;var r=s.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&o.call(r)==a}},45931:e=>{var t=Object.prototype.toString,r=Array.isArray;e.exports=function(e){return"string"==typeof e||!r(e)&&function(e){return!!e&&"object"==typeof e}(e)&&"[object String]"==t.call(e)}},67083:e=>{var t=1/0,r=17976931348623157e292,i=NaN,n="[object Symbol]",o=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,l=/^0o[0-7]+$/i,d=parseInt,c=Object.prototype.toString;function u(e,u){var h;if("function"!=typeof u)throw new TypeError("Expected a function");return e=function(e){var u=function(e){if(!e)return 0===e?e:0;if(e=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&c.call(e)==n}(e))return i;if(p(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=p(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var r=a.test(e);return r||l.test(e)?d(e.slice(2),r?2:8):s.test(e)?i:+e}(e),e===t||e===-1/0){return(e<0?-1:1)*r}return e==e?e:0}(e),h=u%1;return u==u?h?u-h:u:0}(e),function(){return--e>0&&(h=u.apply(this,arguments)),e<=1&&(u=void 0),h}}function p(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=function(e){return u(2,e)}},55580:(e,t,r)=>{var i=r(56110)(r(9325),"DataView");e.exports=i},21549:(e,t,r)=>{var i=r(22032),n=r(63862),o=r(66721),s=r(12749),a=r(35749);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t{var i=r(63702),n=r(70080),o=r(24739),s=r(48655),a=r(31175);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t{var i=r(56110)(r(9325),"Map");e.exports=i},53661:(e,t,r)=>{var i=r(63040),n=r(17670),o=r(90289),s=r(4509),a=r(72949);function l(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t{var i=r(56110)(r(9325),"Promise");e.exports=i},76545:(e,t,r)=>{var i=r(56110)(r(9325),"Set");e.exports=i},38859:(e,t,r)=>{var i=r(53661),n=r(31380),o=r(51459);function s(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new i;++t{var i=r(80079),n=r(51420),o=r(90938),s=r(63605),a=r(29817),l=r(80945);function d(e){var t=this.__data__=new i(e);this.size=t.size}d.prototype.clear=n,d.prototype.delete=o,d.prototype.get=s,d.prototype.has=a,d.prototype.set=l,e.exports=d},51873:(e,t,r)=>{var i=r(9325).Symbol;e.exports=i},37828:(e,t,r)=>{var i=r(9325).Uint8Array;e.exports=i},28303:(e,t,r)=>{var i=r(56110)(r(9325),"WeakMap");e.exports=i},91033:e=>{e.exports=function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}},83729:e=>{e.exports=function(e,t){for(var r=-1,i=null==e?0:e.length;++r{e.exports=function(e,t){for(var r=-1,i=null==e?0:e.length,n=0,o=[];++r{var i=r(78096),n=r(72428),o=r(56449),s=r(3656),a=r(30361),l=r(37167),d=Object.prototype.hasOwnProperty;e.exports=function(e,t){var r=o(e),c=!r&&n(e),u=!r&&!c&&s(e),p=!r&&!c&&!u&&l(e),h=r||c||u||p,f=h?i(e.length,String):[],m=f.length;for(var g in e)!t&&!d.call(e,g)||h&&("length"==g||u&&("offset"==g||"parent"==g)||p&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||a(g,m))||f.push(g);return f}},14528:e=>{e.exports=function(e,t){for(var r=-1,i=t.length,n=e.length;++r{e.exports=function(e,t){for(var r=-1,i=null==e?0:e.length;++r{var i=r(43360),n=r(75288);e.exports=function(e,t,r){(void 0!==r&&!n(e[t],r)||void 0===r&&!(t in e))&&i(e,t,r)}},16547:(e,t,r)=>{var i=r(43360),n=r(75288),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,r){var s=e[t];o.call(e,t)&&n(s,r)&&(void 0!==r||t in e)||i(e,t,r)}},26025:(e,t,r)=>{var i=r(75288);e.exports=function(e,t){for(var r=e.length;r--;)if(i(e[r][0],t))return r;return-1}},74733:(e,t,r)=>{var i=r(21791),n=r(95950);e.exports=function(e,t){return e&&i(t,n(t),e)}},43838:(e,t,r)=>{var i=r(21791),n=r(37241);e.exports=function(e,t){return e&&i(t,n(t),e)}},43360:(e,t,r)=>{var i=r(93243);e.exports=function(e,t,r){"__proto__"==t&&i?i(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}},9999:(e,t,r)=>{var i=r(37217),n=r(83729),o=r(16547),s=r(74733),a=r(43838),l=r(93290),d=r(23007),c=r(92271),u=r(48948),p=r(50002),h=r(83349),f=r(5861),m=r(76189),g=r(77199),y=r(35529),v=r(56449),b=r(3656),w=r(87730),_=r(23805),x=r(38440),S=r(95950),k=r(37241),E="[object Arguments]",T="[object Function]",B="[object Object]",C={};C[E]=C["[object Array]"]=C["[object ArrayBuffer]"]=C["[object DataView]"]=C["[object Boolean]"]=C["[object Date]"]=C["[object Float32Array]"]=C["[object Float64Array]"]=C["[object Int8Array]"]=C["[object Int16Array]"]=C["[object Int32Array]"]=C["[object Map]"]=C["[object Number]"]=C[B]=C["[object RegExp]"]=C["[object Set]"]=C["[object String]"]=C["[object Symbol]"]=C["[object Uint8Array]"]=C["[object Uint8ClampedArray]"]=C["[object Uint16Array]"]=C["[object Uint32Array]"]=!0,C["[object Error]"]=C[T]=C["[object WeakMap]"]=!1,e.exports=function e(t,r,I,A,F,M){var D,R=1&r,P=2&r,O=4&r;if(I&&(D=F?I(t,A,F,M):I(t)),void 0!==D)return D;if(!_(t))return t;var z=v(t);if(z){if(D=m(t),!R)return d(t,D)}else{var N=f(t),q=N==T||"[object GeneratorFunction]"==N;if(b(t))return l(t,R);if(N==B||N==E||q&&!F){if(D=P||q?{}:y(t),!R)return P?u(t,a(D,t)):c(t,s(D,t))}else{if(!C[N])return F?t:{};D=g(t,N,R)}}M||(M=new i);var U=M.get(t);if(U)return U;M.set(t,D),x(t)?t.forEach((function(i){D.add(e(i,r,I,i,t,M))})):w(t)&&t.forEach((function(i,n){D.set(n,e(i,r,I,n,t,M))}));var L=z?void 0:(O?P?h:p:P?k:S)(t);return n(L||t,(function(i,n){L&&(i=t[n=i]),o(D,n,e(i,r,I,n,t,M))})),D}},39344:(e,t,r)=>{var i=r(23805),n=Object.create,o=function(){function e(){}return function(t){if(!i(t))return{};if(n)return n(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();e.exports=o},83120:(e,t,r)=>{var i=r(14528),n=r(45891);e.exports=function e(t,r,o,s,a){var l=-1,d=t.length;for(o||(o=n),a||(a=[]);++l0&&o(c)?r>1?e(c,r-1,o,s,a):i(a,c):s||(a[a.length]=c)}return a}},86649:(e,t,r)=>{var i=r(83221)();e.exports=i},82199:(e,t,r)=>{var i=r(14528),n=r(56449);e.exports=function(e,t,r){var o=t(e);return n(e)?o:i(o,r(e))}},72552:(e,t,r)=>{var i=r(51873),n=r(659),o=r(59350),s=i?i.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":s&&s in Object(e)?n(e):o(e)}},27534:(e,t,r)=>{var i=r(72552),n=r(40346);e.exports=function(e){return n(e)&&"[object Arguments]"==i(e)}},60270:(e,t,r)=>{var i=r(87068),n=r(40346);e.exports=function e(t,r,o,s,a){return t===r||(null==t||null==r||!n(t)&&!n(r)?t!=t&&r!=r:i(t,r,o,s,e,a))}},87068:(e,t,r)=>{var i=r(37217),n=r(25911),o=r(21986),s=r(50689),a=r(5861),l=r(56449),d=r(3656),c=r(37167),u="[object Arguments]",p="[object Array]",h="[object Object]",f=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,m,g,y){var v=l(e),b=l(t),w=v?p:a(e),_=b?p:a(t),x=(w=w==u?h:w)==h,S=(_=_==u?h:_)==h,k=w==_;if(k&&d(e)){if(!d(t))return!1;v=!0,x=!1}if(k&&!x)return y||(y=new i),v||c(e)?n(e,t,r,m,g,y):o(e,t,w,r,m,g,y);if(!(1&r)){var E=x&&f.call(e,"__wrapped__"),T=S&&f.call(t,"__wrapped__");if(E||T){var B=E?e.value():e,C=T?t.value():t;return y||(y=new i),g(B,C,r,m,y)}}return!!k&&(y||(y=new i),s(e,t,r,m,g,y))}},29172:(e,t,r)=>{var i=r(5861),n=r(40346);e.exports=function(e){return n(e)&&"[object Map]"==i(e)}},45083:(e,t,r)=>{var i=r(1882),n=r(87296),o=r(23805),s=r(47473),a=/^\[object .+?Constructor\]$/,l=Function.prototype,d=Object.prototype,c=l.toString,u=d.hasOwnProperty,p=RegExp("^"+c.call(u).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||n(e))&&(i(e)?p:a).test(s(e))}},16038:(e,t,r)=>{var i=r(5861),n=r(40346);e.exports=function(e){return n(e)&&"[object Set]"==i(e)}},4901:(e,t,r)=>{var i=r(72552),n=r(30294),o=r(40346),s={};s["[object Float32Array]"]=s["[object Float64Array]"]=s["[object Int8Array]"]=s["[object Int16Array]"]=s["[object Int32Array]"]=s["[object Uint8Array]"]=s["[object Uint8ClampedArray]"]=s["[object Uint16Array]"]=s["[object Uint32Array]"]=!0,s["[object Arguments]"]=s["[object Array]"]=s["[object ArrayBuffer]"]=s["[object Boolean]"]=s["[object DataView]"]=s["[object Date]"]=s["[object Error]"]=s["[object Function]"]=s["[object Map]"]=s["[object Number]"]=s["[object Object]"]=s["[object RegExp]"]=s["[object Set]"]=s["[object String]"]=s["[object WeakMap]"]=!1,e.exports=function(e){return o(e)&&n(e.length)&&!!s[i(e)]}},88984:(e,t,r)=>{var i=r(55527),n=r(3650),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!i(e))return n(e);var t=[];for(var r in Object(e))o.call(e,r)&&"constructor"!=r&&t.push(r);return t}},72903:(e,t,r)=>{var i=r(23805),n=r(55527),o=r(90181),s=Object.prototype.hasOwnProperty;e.exports=function(e){if(!i(e))return o(e);var t=n(e),r=[];for(var a in e)("constructor"!=a||!t&&s.call(e,a))&&r.push(a);return r}},85250:(e,t,r)=>{var i=r(37217),n=r(87805),o=r(86649),s=r(42824),a=r(23805),l=r(37241),d=r(14974);e.exports=function e(t,r,c,u,p){t!==r&&o(r,(function(o,l){if(p||(p=new i),a(o))s(t,r,l,c,e,u,p);else{var h=u?u(d(t,l),o,l+"",t,r,p):void 0;void 0===h&&(h=o),n(t,l,h)}}),l)}},42824:(e,t,r)=>{var i=r(87805),n=r(93290),o=r(71961),s=r(23007),a=r(35529),l=r(72428),d=r(56449),c=r(83693),u=r(3656),p=r(1882),h=r(23805),f=r(11331),m=r(37167),g=r(14974),y=r(69884);e.exports=function(e,t,r,v,b,w,_){var x=g(e,r),S=g(t,r),k=_.get(S);if(k)i(e,r,k);else{var E=w?w(x,S,r+"",e,t,_):void 0,T=void 0===E;if(T){var B=d(S),C=!B&&u(S),I=!B&&!C&&m(S);E=S,B||C||I?d(x)?E=x:c(x)?E=s(x):C?(T=!1,E=n(S,!0)):I?(T=!1,E=o(S,!0)):E=[]:f(S)||l(S)?(E=x,l(x)?E=y(x):h(x)&&!p(x)||(E=a(S))):T=!1}T&&(_.set(S,E),b(E,S,v,w,_),_.delete(S)),i(e,r,E)}}},13195:e=>{var t=Math.floor,r=Math.random;e.exports=function(e,i){return e+t(r()*(i-e+1))}},69302:(e,t,r)=>{var i=r(83488),n=r(56757),o=r(32865);e.exports=function(e,t){return o(n(e,t,i),e+"")}},19570:(e,t,r)=>{var i=r(37334),n=r(93243),o=r(83488),s=n?function(e,t){return n(e,"toString",{configurable:!0,enumerable:!1,value:i(t),writable:!0})}:o;e.exports=s},25160:e=>{e.exports=function(e,t,r){var i=-1,n=e.length;t<0&&(t=-t>n?0:n+t),(r=r>n?n:r)<0&&(r+=n),n=t>r?0:r-t>>>0,t>>>=0;for(var o=Array(n);++i{e.exports=function(e,t){for(var r=-1,i=Array(e);++r{var i=r(31800),n=/^\s+/;e.exports=function(e){return e?e.slice(0,i(e)+1).replace(n,""):e}},27301:e=>{e.exports=function(e){return function(t){return e(t)}}},19219:e=>{e.exports=function(e,t){return e.has(t)}},49653:(e,t,r)=>{var i=r(37828);e.exports=function(e){var t=new e.constructor(e.byteLength);return new i(t).set(new i(e)),t}},93290:(e,t,r)=>{e=r.nmd(e);var i=r(9325),n=t&&!t.nodeType&&t,o=n&&e&&!e.nodeType&&e,s=o&&o.exports===n?i.Buffer:void 0,a=s?s.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var r=e.length,i=a?a(r):new e.constructor(r);return e.copy(i),i}},76169:(e,t,r)=>{var i=r(49653);e.exports=function(e,t){var r=t?i(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}},73201:e=>{var t=/\w*$/;e.exports=function(e){var r=new e.constructor(e.source,t.exec(e));return r.lastIndex=e.lastIndex,r}},93736:(e,t,r)=>{var i=r(51873),n=i?i.prototype:void 0,o=n?n.valueOf:void 0;e.exports=function(e){return o?Object(o.call(e)):{}}},71961:(e,t,r)=>{var i=r(49653);e.exports=function(e,t){var r=t?i(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},23007:e=>{e.exports=function(e,t){var r=-1,i=e.length;for(t||(t=Array(i));++r{var i=r(16547),n=r(43360);e.exports=function(e,t,r,o){var s=!r;r||(r={});for(var a=-1,l=t.length;++a{var i=r(21791),n=r(4664);e.exports=function(e,t){return i(e,n(e),t)}},48948:(e,t,r)=>{var i=r(21791),n=r(86375);e.exports=function(e,t){return i(e,n(e),t)}},55481:(e,t,r)=>{var i=r(9325)["__core-js_shared__"];e.exports=i},20999:(e,t,r)=>{var i=r(69302),n=r(36800);e.exports=function(e){return i((function(t,r){var i=-1,o=r.length,s=o>1?r[o-1]:void 0,a=o>2?r[2]:void 0;for(s=e.length>3&&"function"==typeof s?(o--,s):void 0,a&&n(r[0],r[1],a)&&(s=o<3?void 0:s,o=1),t=Object(t);++i{e.exports=function(e){return function(t,r,i){for(var n=-1,o=Object(t),s=i(t),a=s.length;a--;){var l=s[e?a:++n];if(!1===r(o[l],l,o))break}return t}}},93243:(e,t,r)=>{var i=r(56110),n=function(){try{var e=i(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=n},25911:(e,t,r)=>{var i=r(38859),n=r(14248),o=r(19219);e.exports=function(e,t,r,s,a,l){var d=1&r,c=e.length,u=t.length;if(c!=u&&!(d&&u>c))return!1;var p=l.get(e),h=l.get(t);if(p&&h)return p==t&&h==e;var f=-1,m=!0,g=2&r?new i:void 0;for(l.set(e,t),l.set(t,e);++f{var i=r(51873),n=r(37828),o=r(75288),s=r(25911),a=r(20317),l=r(84247),d=i?i.prototype:void 0,c=d?d.valueOf:void 0;e.exports=function(e,t,r,i,d,u,p){switch(r){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!u(new n(e),new n(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var h=a;case"[object Set]":var f=1&i;if(h||(h=l),e.size!=t.size&&!f)return!1;var m=p.get(e);if(m)return m==t;i|=2,p.set(e,t);var g=s(h(e),h(t),i,d,u,p);return p.delete(e),g;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},50689:(e,t,r)=>{var i=r(50002),n=Object.prototype.hasOwnProperty;e.exports=function(e,t,r,o,s,a){var l=1&r,d=i(e),c=d.length;if(c!=i(t).length&&!l)return!1;for(var u=c;u--;){var p=d[u];if(!(l?p in t:n.call(t,p)))return!1}var h=a.get(e),f=a.get(t);if(h&&f)return h==t&&f==e;var m=!0;a.set(e,t),a.set(t,e);for(var g=l;++u{var i="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;e.exports=i},50002:(e,t,r)=>{var i=r(82199),n=r(4664),o=r(95950);e.exports=function(e){return i(e,o,n)}},83349:(e,t,r)=>{var i=r(82199),n=r(86375),o=r(37241);e.exports=function(e){return i(e,o,n)}},12651:(e,t,r)=>{var i=r(74218);e.exports=function(e,t){var r=e.__data__;return i(t)?r["string"==typeof t?"string":"hash"]:r.map}},56110:(e,t,r)=>{var i=r(45083),n=r(10392);e.exports=function(e,t){var r=n(e,t);return i(r)?r:void 0}},28879:(e,t,r)=>{var i=r(74335)(Object.getPrototypeOf,Object);e.exports=i},659:(e,t,r)=>{var i=r(51873),n=Object.prototype,o=n.hasOwnProperty,s=n.toString,a=i?i.toStringTag:void 0;e.exports=function(e){var t=o.call(e,a),r=e[a];try{e[a]=void 0;var i=!0}catch(e){}var n=s.call(e);return i&&(t?e[a]=r:delete e[a]),n}},4664:(e,t,r)=>{var i=r(79770),n=r(63345),o=Object.prototype.propertyIsEnumerable,s=Object.getOwnPropertySymbols,a=s?function(e){return null==e?[]:(e=Object(e),i(s(e),(function(t){return o.call(e,t)})))}:n;e.exports=a},86375:(e,t,r)=>{var i=r(14528),n=r(28879),o=r(4664),s=r(63345),a=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)i(t,o(e)),e=n(e);return t}:s;e.exports=a},5861:(e,t,r)=>{var i=r(55580),n=r(68223),o=r(32804),s=r(76545),a=r(28303),l=r(72552),d=r(47473),c="[object Map]",u="[object Promise]",p="[object Set]",h="[object WeakMap]",f="[object DataView]",m=d(i),g=d(n),y=d(o),v=d(s),b=d(a),w=l;(i&&w(new i(new ArrayBuffer(1)))!=f||n&&w(new n)!=c||o&&w(o.resolve())!=u||s&&w(new s)!=p||a&&w(new a)!=h)&&(w=function(e){var t=l(e),r="[object Object]"==t?e.constructor:void 0,i=r?d(r):"";if(i)switch(i){case m:return f;case g:return c;case y:return u;case v:return p;case b:return h}return t}),e.exports=w},10392:e=>{e.exports=function(e,t){return null==e?void 0:e[t]}},22032:(e,t,r)=>{var i=r(81042);e.exports=function(){this.__data__=i?i(null):{},this.size=0}},63862:e=>{e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},66721:(e,t,r)=>{var i=r(81042),n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(i){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return n.call(t,e)?t[e]:void 0}},12749:(e,t,r)=>{var i=r(81042),n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return i?void 0!==t[e]:n.call(t,e)}},35749:(e,t,r)=>{var i=r(81042);e.exports=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=i&&void 0===t?"__lodash_hash_undefined__":t,this}},76189:e=>{var t=Object.prototype.hasOwnProperty;e.exports=function(e){var r=e.length,i=new e.constructor(r);return r&&"string"==typeof e[0]&&t.call(e,"index")&&(i.index=e.index,i.input=e.input),i}},77199:(e,t,r)=>{var i=r(49653),n=r(76169),o=r(73201),s=r(93736),a=r(71961);e.exports=function(e,t,r){var l=e.constructor;switch(t){case"[object ArrayBuffer]":return i(e);case"[object Boolean]":case"[object Date]":return new l(+e);case"[object DataView]":return n(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return a(e,r);case"[object Map]":case"[object Set]":return new l;case"[object Number]":case"[object String]":return new l(e);case"[object RegExp]":return o(e);case"[object Symbol]":return s(e)}}},35529:(e,t,r)=>{var i=r(39344),n=r(28879),o=r(55527);e.exports=function(e){return"function"!=typeof e.constructor||o(e)?{}:i(n(e))}},45891:(e,t,r)=>{var i=r(51873),n=r(72428),o=r(56449),s=i?i.isConcatSpreadable:void 0;e.exports=function(e){return o(e)||n(e)||!!(s&&e&&e[s])}},30361:e=>{var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,r){var i=typeof e;return!!(r=null==r?9007199254740991:r)&&("number"==i||"symbol"!=i&&t.test(e))&&e>-1&&e%1==0&&e{var i=r(75288),n=r(64894),o=r(30361),s=r(23805);e.exports=function(e,t,r){if(!s(r))return!1;var a=typeof t;return!!("number"==a?n(r)&&o(t,r.length):"string"==a&&t in r)&&i(r[t],e)}},74218:e=>{e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},87296:(e,t,r)=>{var i,n=r(55481),o=(i=/[^.]+$/.exec(n&&n.keys&&n.keys.IE_PROTO||""))?"Symbol(src)_1."+i:"";e.exports=function(e){return!!o&&o in e}},55527:e=>{var t=Object.prototype;e.exports=function(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||t)}},63702:e=>{e.exports=function(){this.__data__=[],this.size=0}},70080:(e,t,r)=>{var i=r(26025),n=Array.prototype.splice;e.exports=function(e){var t=this.__data__,r=i(t,e);return!(r<0)&&(r==t.length-1?t.pop():n.call(t,r,1),--this.size,!0)}},24739:(e,t,r)=>{var i=r(26025);e.exports=function(e){var t=this.__data__,r=i(t,e);return r<0?void 0:t[r][1]}},48655:(e,t,r)=>{var i=r(26025);e.exports=function(e){return i(this.__data__,e)>-1}},31175:(e,t,r)=>{var i=r(26025);e.exports=function(e,t){var r=this.__data__,n=i(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}},63040:(e,t,r)=>{var i=r(21549),n=r(80079),o=r(68223);e.exports=function(){this.size=0,this.__data__={hash:new i,map:new(o||n),string:new i}}},17670:(e,t,r)=>{var i=r(12651);e.exports=function(e){var t=i(this,e).delete(e);return this.size-=t?1:0,t}},90289:(e,t,r)=>{var i=r(12651);e.exports=function(e){return i(this,e).get(e)}},4509:(e,t,r)=>{var i=r(12651);e.exports=function(e){return i(this,e).has(e)}},72949:(e,t,r)=>{var i=r(12651);e.exports=function(e,t){var r=i(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}},20317:e=>{e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e,i){r[++t]=[i,e]})),r}},81042:(e,t,r)=>{var i=r(56110)(Object,"create");e.exports=i},3650:(e,t,r)=>{var i=r(74335)(Object.keys,Object);e.exports=i},90181:e=>{e.exports=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}},86009:(e,t,r)=>{e=r.nmd(e);var i=r(34840),n=t&&!t.nodeType&&t,o=n&&e&&!e.nodeType&&e,s=o&&o.exports===n&&i.process,a=function(){try{var e=o&&o.require&&o.require("util").types;return e||s&&s.binding&&s.binding("util")}catch(e){}}();e.exports=a},59350:e=>{var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},74335:e=>{e.exports=function(e,t){return function(r){return e(t(r))}}},56757:(e,t,r)=>{var i=r(91033),n=Math.max;e.exports=function(e,t,r){return t=n(void 0===t?e.length-1:t,0),function(){for(var o=arguments,s=-1,a=n(o.length-t,0),l=Array(a);++s{var i=r(34840),n="object"==typeof self&&self&&self.Object===Object&&self,o=i||n||Function("return this")();e.exports=o},14974:e=>{e.exports=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}},31380:e=>{e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},51459:e=>{e.exports=function(e){return this.__data__.has(e)}},84247:e=>{e.exports=function(e){var t=-1,r=Array(e.size);return e.forEach((function(e){r[++t]=e})),r}},32865:(e,t,r)=>{var i=r(19570),n=r(51811)(i);e.exports=n},51811:e=>{var t=Date.now;e.exports=function(e){var r=0,i=0;return function(){var n=t(),o=16-(n-i);if(i=n,o>0){if(++r>=800)return arguments[0]}else r=0;return e.apply(void 0,arguments)}}},51420:(e,t,r)=>{var i=r(80079);e.exports=function(){this.__data__=new i,this.size=0}},90938:e=>{e.exports=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}},63605:e=>{e.exports=function(e){return this.__data__.get(e)}},29817:e=>{e.exports=function(e){return this.__data__.has(e)}},80945:(e,t,r)=>{var i=r(80079),n=r(68223),o=r(53661);e.exports=function(e,t){var r=this.__data__;if(r instanceof i){var s=r.__data__;if(!n||s.length<199)return s.push([e,t]),this.size=++r.size,this;r=this.__data__=new o(s)}return r.set(e,t),this.size=r.size,this}},47473:e=>{var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},31800:e=>{var t=/\s/;e.exports=function(e){for(var r=e.length;r--&&t.test(e.charAt(r)););return r}},21013:(e,t,r)=>{var i=r(25160),n=r(36800),o=r(61489),s=Math.ceil,a=Math.max;e.exports=function(e,t,r){t=(r?n(e,t,r):void 0===t)?1:a(o(t),0);var l=null==e?0:e.length;if(!l||t<1)return[];for(var d=0,c=0,u=Array(s(l/t));d{var i=r(9999);e.exports=function(e){return i(e,5)}},37334:e=>{e.exports=function(e){return function(){return e}}},38221:(e,t,r)=>{var i=r(23805),n=r(10124),o=r(99374),s=Math.max,a=Math.min;e.exports=function(e,t,r){var l,d,c,u,p,h,f=0,m=!1,g=!1,y=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function v(t){var r=l,i=d;return l=d=void 0,f=t,u=e.apply(i,r)}function b(e){var r=e-h;return void 0===h||r>=t||r<0||g&&e-f>=c}function w(){var e=n();if(b(e))return _(e);p=setTimeout(w,function(e){var r=t-(e-h);return g?a(r,c-(e-f)):r}(e))}function _(e){return p=void 0,y&&l?v(e):(l=d=void 0,u)}function x(){var e=n(),r=b(e);if(l=arguments,d=this,h=e,r){if(void 0===p)return function(e){return f=e,p=setTimeout(w,t),m?v(e):u}(h);if(g)return clearTimeout(p),p=setTimeout(w,t),v(h)}return void 0===p&&(p=setTimeout(w,t)),u}return t=o(t)||0,i(r)&&(m=!!r.leading,c=(g="maxWait"in r)?s(o(r.maxWait)||0,t):c,y="trailing"in r?!!r.trailing:y),x.cancel=function(){void 0!==p&&clearTimeout(p),f=0,l=h=d=p=void 0},x.flush=function(){return void 0===p?u:_(n())},x}},75288:e=>{e.exports=function(e,t){return e===t||e!=e&&t!=t}},35970:(e,t,r)=>{var i=r(83120);e.exports=function(e){return(null==e?0:e.length)?i(e,1):[]}},83488:e=>{e.exports=function(e){return e}},72428:(e,t,r)=>{var i=r(27534),n=r(40346),o=Object.prototype,s=o.hasOwnProperty,a=o.propertyIsEnumerable,l=i(function(){return arguments}())?i:function(e){return n(e)&&s.call(e,"callee")&&!a.call(e,"callee")};e.exports=l},56449:e=>{var t=Array.isArray;e.exports=t},64894:(e,t,r)=>{var i=r(1882),n=r(30294);e.exports=function(e){return null!=e&&n(e.length)&&!i(e)}},83693:(e,t,r)=>{var i=r(64894),n=r(40346);e.exports=function(e){return n(e)&&i(e)}},3656:(e,t,r)=>{e=r.nmd(e);var i=r(9325),n=r(89935),o=t&&!t.nodeType&&t,s=o&&e&&!e.nodeType&&e,a=s&&s.exports===o?i.Buffer:void 0,l=(a?a.isBuffer:void 0)||n;e.exports=l},2404:(e,t,r)=>{var i=r(60270);e.exports=function(e,t){return i(e,t)}},1882:(e,t,r)=>{var i=r(72552),n=r(23805);e.exports=function(e){if(!n(e))return!1;var t=i(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},30294:e=>{e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},87730:(e,t,r)=>{var i=r(29172),n=r(27301),o=r(86009),s=o&&o.isMap,a=s?n(s):i;e.exports=a},23805:e=>{e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},40346:e=>{e.exports=function(e){return null!=e&&"object"==typeof e}},11331:(e,t,r)=>{var i=r(72552),n=r(28879),o=r(40346),s=Function.prototype,a=Object.prototype,l=s.toString,d=a.hasOwnProperty,c=l.call(Object);e.exports=function(e){if(!o(e)||"[object Object]"!=i(e))return!1;var t=n(e);if(null===t)return!0;var r=d.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&l.call(r)==c}},38440:(e,t,r)=>{var i=r(16038),n=r(27301),o=r(86009),s=o&&o.isSet,a=s?n(s):i;e.exports=a},44394:(e,t,r)=>{var i=r(72552),n=r(40346);e.exports=function(e){return"symbol"==typeof e||n(e)&&"[object Symbol]"==i(e)}},37167:(e,t,r)=>{var i=r(4901),n=r(27301),o=r(86009),s=o&&o.isTypedArray,a=s?n(s):i;e.exports=a},95950:(e,t,r)=>{var i=r(70695),n=r(88984),o=r(64894);e.exports=function(e){return o(e)?i(e):n(e)}},37241:(e,t,r)=>{var i=r(70695),n=r(72903),o=r(64894);e.exports=function(e){return o(e)?i(e,!0):n(e)}},2543:function(e,t,r){var i; +/** + * @license + * Lodash + * Copyright OpenJS Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */e=r.nmd(e),function(){var n,o="Expected a function",s="__lodash_hash_undefined__",a="__lodash_placeholder__",l=16,d=32,c=64,u=128,p=256,h=1/0,f=9007199254740991,m=NaN,g=4294967295,y=[["ary",u],["bind",1],["bindKey",2],["curry",8],["curryRight",l],["flip",512],["partial",d],["partialRight",c],["rearg",p]],v="[object Arguments]",b="[object Array]",w="[object Boolean]",_="[object Date]",x="[object Error]",S="[object Function]",k="[object GeneratorFunction]",E="[object Map]",T="[object Number]",B="[object Object]",C="[object Promise]",I="[object RegExp]",A="[object Set]",F="[object String]",M="[object Symbol]",D="[object WeakMap]",R="[object ArrayBuffer]",P="[object DataView]",O="[object Float32Array]",z="[object Float64Array]",N="[object Int8Array]",q="[object Int16Array]",U="[object Int32Array]",L="[object Uint8Array]",j="[object Uint8ClampedArray]",H="[object Uint16Array]",$="[object Uint32Array]",G=/\b__p \+= '';/g,W=/\b(__p \+=) '' \+/g,K=/(__e\(.*?\)|\b__t\)) \+\n'';/g,V=/&(?:amp|lt|gt|quot|#39);/g,J=/[&<>"']/g,Y=RegExp(V.source),Q=RegExp(J.source),Z=/<%-([\s\S]+?)%>/g,X=/<%([\s\S]+?)%>/g,ee=/<%=([\s\S]+?)%>/g,te=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,re=/^\w*$/,ie=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ne=/[\\^$.*+?()[\]{}|]/g,oe=RegExp(ne.source),se=/^\s+/,ae=/\s/,le=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,de=/\{\n\/\* \[wrapped with (.+)\] \*/,ce=/,? & /,ue=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,pe=/[()=,{}\[\]\/\s]/,he=/\\(\\)?/g,fe=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,me=/\w*$/,ge=/^[-+]0x[0-9a-f]+$/i,ye=/^0b[01]+$/i,ve=/^\[object .+?Constructor\]$/,be=/^0o[0-7]+$/i,we=/^(?:0|[1-9]\d*)$/,_e=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,xe=/($^)/,Se=/['\n\r\u2028\u2029\\]/g,ke="\\ud800-\\udfff",Ee="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Te="\\u2700-\\u27bf",Be="a-z\\xdf-\\xf6\\xf8-\\xff",Ce="A-Z\\xc0-\\xd6\\xd8-\\xde",Ie="\\ufe0e\\ufe0f",Ae="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Fe="['’]",Me="["+ke+"]",De="["+Ae+"]",Re="["+Ee+"]",Pe="\\d+",Oe="["+Te+"]",ze="["+Be+"]",Ne="[^"+ke+Ae+Pe+Te+Be+Ce+"]",qe="\\ud83c[\\udffb-\\udfff]",Ue="[^"+ke+"]",Le="(?:\\ud83c[\\udde6-\\uddff]){2}",je="[\\ud800-\\udbff][\\udc00-\\udfff]",He="["+Ce+"]",$e="\\u200d",Ge="(?:"+ze+"|"+Ne+")",We="(?:"+He+"|"+Ne+")",Ke="(?:['’](?:d|ll|m|re|s|t|ve))?",Ve="(?:['’](?:D|LL|M|RE|S|T|VE))?",Je="(?:"+Re+"|"+qe+")"+"?",Ye="["+Ie+"]?",Qe=Ye+Je+("(?:"+$e+"(?:"+[Ue,Le,je].join("|")+")"+Ye+Je+")*"),Ze="(?:"+[Oe,Le,je].join("|")+")"+Qe,Xe="(?:"+[Ue+Re+"?",Re,Le,je,Me].join("|")+")",et=RegExp(Fe,"g"),tt=RegExp(Re,"g"),rt=RegExp(qe+"(?="+qe+")|"+Xe+Qe,"g"),it=RegExp([He+"?"+ze+"+"+Ke+"(?="+[De,He,"$"].join("|")+")",We+"+"+Ve+"(?="+[De,He+Ge,"$"].join("|")+")",He+"?"+Ge+"+"+Ke,He+"+"+Ve,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Pe,Ze].join("|"),"g"),nt=RegExp("["+$e+ke+Ee+Ie+"]"),ot=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,st=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],at=-1,lt={};lt[O]=lt[z]=lt[N]=lt[q]=lt[U]=lt[L]=lt[j]=lt[H]=lt[$]=!0,lt[v]=lt[b]=lt[R]=lt[w]=lt[P]=lt[_]=lt[x]=lt[S]=lt[E]=lt[T]=lt[B]=lt[I]=lt[A]=lt[F]=lt[D]=!1;var dt={};dt[v]=dt[b]=dt[R]=dt[P]=dt[w]=dt[_]=dt[O]=dt[z]=dt[N]=dt[q]=dt[U]=dt[E]=dt[T]=dt[B]=dt[I]=dt[A]=dt[F]=dt[M]=dt[L]=dt[j]=dt[H]=dt[$]=!0,dt[x]=dt[S]=dt[D]=!1;var ct={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ut=parseFloat,pt=parseInt,ht="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,ft="object"==typeof self&&self&&self.Object===Object&&self,mt=ht||ft||Function("return this")(),gt=t&&!t.nodeType&&t,yt=gt&&e&&!e.nodeType&&e,vt=yt&&yt.exports===gt,bt=vt&&ht.process,wt=function(){try{var e=yt&&yt.require&&yt.require("util").types;return e||bt&&bt.binding&&bt.binding("util")}catch(e){}}(),_t=wt&&wt.isArrayBuffer,xt=wt&&wt.isDate,St=wt&&wt.isMap,kt=wt&&wt.isRegExp,Et=wt&&wt.isSet,Tt=wt&&wt.isTypedArray;function Bt(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function Ct(e,t,r,i){for(var n=-1,o=null==e?0:e.length;++n-1}function Rt(e,t,r){for(var i=-1,n=null==e?0:e.length;++i-1;);return r}function ir(e,t){for(var r=e.length;r--&&Ht(t,e[r],0)>-1;);return r}var nr=Vt({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),or=Vt({"&":"&","<":"<",">":">",'"':""","'":"'"});function sr(e){return"\\"+ct[e]}function ar(e){return nt.test(e)}function lr(e){var t=-1,r=Array(e.size);return e.forEach((function(e,i){r[++t]=[i,e]})),r}function dr(e,t){return function(r){return e(t(r))}}function cr(e,t){for(var r=-1,i=e.length,n=0,o=[];++r",""":'"',"'":"'"});var yr=function e(t){var r,i=(t=null==t?mt:yr.defaults(mt.Object(),t,yr.pick(mt,st))).Array,ae=t.Date,ke=t.Error,Ee=t.Function,Te=t.Math,Be=t.Object,Ce=t.RegExp,Ie=t.String,Ae=t.TypeError,Fe=i.prototype,Me=Ee.prototype,De=Be.prototype,Re=t["__core-js_shared__"],Pe=Me.toString,Oe=De.hasOwnProperty,ze=0,Ne=(r=/[^.]+$/.exec(Re&&Re.keys&&Re.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"",qe=De.toString,Ue=Pe.call(Be),Le=mt._,je=Ce("^"+Pe.call(Oe).replace(ne,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),He=vt?t.Buffer:n,$e=t.Symbol,Ge=t.Uint8Array,We=He?He.allocUnsafe:n,Ke=dr(Be.getPrototypeOf,Be),Ve=Be.create,Je=De.propertyIsEnumerable,Ye=Fe.splice,Qe=$e?$e.isConcatSpreadable:n,Ze=$e?$e.iterator:n,Xe=$e?$e.toStringTag:n,rt=function(){try{var e=ho(Be,"defineProperty");return e({},"",{}),e}catch(e){}}(),nt=t.clearTimeout!==mt.clearTimeout&&t.clearTimeout,ct=ae&&ae.now!==mt.Date.now&&ae.now,ht=t.setTimeout!==mt.setTimeout&&t.setTimeout,ft=Te.ceil,gt=Te.floor,yt=Be.getOwnPropertySymbols,bt=He?He.isBuffer:n,wt=t.isFinite,Ut=Fe.join,Vt=dr(Be.keys,Be),vr=Te.max,br=Te.min,wr=ae.now,_r=t.parseInt,xr=Te.random,Sr=Fe.reverse,kr=ho(t,"DataView"),Er=ho(t,"Map"),Tr=ho(t,"Promise"),Br=ho(t,"Set"),Cr=ho(t,"WeakMap"),Ir=ho(Be,"create"),Ar=Cr&&new Cr,Fr={},Mr=qo(kr),Dr=qo(Er),Rr=qo(Tr),Pr=qo(Br),Or=qo(Cr),zr=$e?$e.prototype:n,Nr=zr?zr.valueOf:n,qr=zr?zr.toString:n;function Ur(e){if(ra(e)&&!Gs(e)&&!(e instanceof $r)){if(e instanceof Hr)return e;if(Oe.call(e,"__wrapped__"))return Uo(e)}return new Hr(e)}var Lr=function(){function e(){}return function(t){if(!ta(t))return{};if(Ve)return Ve(t);e.prototype=t;var r=new e;return e.prototype=n,r}}();function jr(){}function Hr(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=n}function $r(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=g,this.__views__=[]}function Gr(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t=t?e:t)),e}function li(e,t,r,i,o,s){var a,l=1&t,d=2&t,c=4&t;if(r&&(a=o?r(e,i,o,s):r(e)),a!==n)return a;if(!ta(e))return e;var u=Gs(e);if(u){if(a=function(e){var t=e.length,r=new e.constructor(t);t&&"string"==typeof e[0]&&Oe.call(e,"index")&&(r.index=e.index,r.input=e.input);return r}(e),!l)return An(e,a)}else{var p=go(e),h=p==S||p==k;if(Js(e))return kn(e,l);if(p==B||p==v||h&&!o){if(a=d||h?{}:vo(e),!l)return d?function(e,t){return Fn(e,mo(e),t)}(e,function(e,t){return e&&Fn(t,Da(t),e)}(a,e)):function(e,t){return Fn(e,fo(e),t)}(e,ni(a,e))}else{if(!dt[p])return o?e:{};a=function(e,t,r){var i=e.constructor;switch(t){case R:return En(e);case w:case _:return new i(+e);case P:return function(e,t){var r=t?En(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}(e,r);case O:case z:case N:case q:case U:case L:case j:case H:case $:return Tn(e,r);case E:return new i;case T:case F:return new i(e);case I:return function(e){var t=new e.constructor(e.source,me.exec(e));return t.lastIndex=e.lastIndex,t}(e);case A:return new i;case M:return n=e,Nr?Be(Nr.call(n)):{}}var n}(e,p,l)}}s||(s=new Jr);var f=s.get(e);if(f)return f;s.set(e,a),aa(e)?e.forEach((function(i){a.add(li(i,t,r,i,e,s))})):ia(e)&&e.forEach((function(i,n){a.set(n,li(i,t,r,n,e,s))}));var m=u?n:(c?d?oo:no:d?Da:Ma)(e);return It(m||e,(function(i,n){m&&(i=e[n=i]),ti(a,n,li(i,t,r,n,e,s))})),a}function di(e,t,r){var i=r.length;if(null==e)return!i;for(e=Be(e);i--;){var o=r[i],s=t[o],a=e[o];if(a===n&&!(o in e)||!s(a))return!1}return!0}function ci(e,t,r){if("function"!=typeof e)throw new Ae(o);return Mo((function(){e.apply(n,r)}),t)}function ui(e,t,r,i){var n=-1,o=Dt,s=!0,a=e.length,l=[],d=t.length;if(!a)return l;r&&(t=Pt(t,Xt(r))),i?(o=Rt,s=!1):t.length>=200&&(o=tr,s=!1,t=new Vr(t));e:for(;++n-1},Wr.prototype.set=function(e,t){var r=this.__data__,i=ri(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this},Kr.prototype.clear=function(){this.size=0,this.__data__={hash:new Gr,map:new(Er||Wr),string:new Gr}},Kr.prototype.delete=function(e){var t=uo(this,e).delete(e);return this.size-=t?1:0,t},Kr.prototype.get=function(e){return uo(this,e).get(e)},Kr.prototype.has=function(e){return uo(this,e).has(e)},Kr.prototype.set=function(e,t){var r=uo(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this},Vr.prototype.add=Vr.prototype.push=function(e){return this.__data__.set(e,s),this},Vr.prototype.has=function(e){return this.__data__.has(e)},Jr.prototype.clear=function(){this.__data__=new Wr,this.size=0},Jr.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},Jr.prototype.get=function(e){return this.__data__.get(e)},Jr.prototype.has=function(e){return this.__data__.has(e)},Jr.prototype.set=function(e,t){var r=this.__data__;if(r instanceof Wr){var i=r.__data__;if(!Er||i.length<199)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new Kr(i)}return r.set(e,t),this.size=r.size,this};var pi=Rn(wi),hi=Rn(_i,!0);function fi(e,t){var r=!0;return pi(e,(function(e,i,n){return r=!!t(e,i,n)})),r}function mi(e,t,r){for(var i=-1,o=e.length;++i0&&r(a)?t>1?yi(a,t-1,r,i,n):Ot(n,a):i||(n[n.length]=a)}return n}var vi=Pn(),bi=Pn(!0);function wi(e,t){return e&&vi(e,t,Ma)}function _i(e,t){return e&&bi(e,t,Ma)}function xi(e,t){return Mt(t,(function(t){return Zs(e[t])}))}function Si(e,t){for(var r=0,i=(t=wn(t,e)).length;null!=e&&rt}function Bi(e,t){return null!=e&&Oe.call(e,t)}function Ci(e,t){return null!=e&&t in Be(e)}function Ii(e,t,r){for(var o=r?Rt:Dt,s=e[0].length,a=e.length,l=a,d=i(a),c=1/0,u=[];l--;){var p=e[l];l&&t&&(p=Pt(p,Xt(t))),c=br(p.length,c),d[l]=!r&&(t||s>=120&&p.length>=120)?new Vr(l&&p):n}p=e[0];var h=-1,f=d[0];e:for(;++h=a?l:l*("desc"==r[i]?-1:1)}return e.index-t.index}(e,t,r)}))}function Gi(e,t,r){for(var i=-1,n=t.length,o={};++i-1;)a!==e&&Ye.call(a,l,1),Ye.call(e,l,1);return e}function Ki(e,t){for(var r=e?t.length:0,i=r-1;r--;){var n=t[r];if(r==i||n!==o){var o=n;wo(n)?Ye.call(e,n,1):pn(e,n)}}return e}function Vi(e,t){return e+gt(xr()*(t-e+1))}function Ji(e,t){var r="";if(!e||t<1||t>f)return r;do{t%2&&(r+=e),(t=gt(t/2))&&(e+=e)}while(t);return r}function Yi(e,t){return Do(Co(e,t,nl),e+"")}function Qi(e){return Qr(La(e))}function Zi(e,t){var r=La(e);return Oo(r,ai(t,0,r.length))}function Xi(e,t,r,i){if(!ta(e))return e;for(var o=-1,s=(t=wn(t,e)).length,a=s-1,l=e;null!=l&&++oo?0:o+t),(r=r>o?o:r)<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var s=i(o);++n>>1,s=e[o];null!==s&&!da(s)&&(r?s<=t:s=200){var d=t?null:Yn(e);if(d)return ur(d);s=!1,n=tr,l=new Vr}else l=t?[]:a;e:for(;++i=i?e:nn(e,t,r)}var Sn=nt||function(e){return mt.clearTimeout(e)};function kn(e,t){if(t)return e.slice();var r=e.length,i=We?We(r):new e.constructor(r);return e.copy(i),i}function En(e){var t=new e.constructor(e.byteLength);return new Ge(t).set(new Ge(e)),t}function Tn(e,t){var r=t?En(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function Bn(e,t){if(e!==t){var r=e!==n,i=null===e,o=e==e,s=da(e),a=t!==n,l=null===t,d=t==t,c=da(t);if(!l&&!c&&!s&&e>t||s&&a&&d&&!l&&!c||i&&a&&d||!r&&d||!o)return 1;if(!i&&!s&&!c&&e1?r[o-1]:n,a=o>2?r[2]:n;for(s=e.length>3&&"function"==typeof s?(o--,s):n,a&&_o(r[0],r[1],a)&&(s=o<3?n:s,o=1),t=Be(t);++i-1?o[s?t[a]:a]:n}}function Un(e){return io((function(t){var r=t.length,i=r,s=Hr.prototype.thru;for(e&&t.reverse();i--;){var a=t[i];if("function"!=typeof a)throw new Ae(o);if(s&&!l&&"wrapper"==ao(a))var l=new Hr([],!0)}for(i=l?i:r;++i1&&w.reverse(),h&&cl))return!1;var c=s.get(e),u=s.get(t);if(c&&u)return c==t&&u==e;var p=-1,h=!0,f=2&r?new Vr:n;for(s.set(e,t),s.set(t,e);++p-1&&e%1==0&&e1?"& ":"")+t[i],t=t.join(r>2?", ":" "),e.replace(le,"{\n/* [wrapped with "+t+"] */\n")}(i,function(e,t){return It(y,(function(r){var i="_."+r[0];t&r[1]&&!Dt(e,i)&&e.push(i)})),e.sort()}(function(e){var t=e.match(de);return t?t[1].split(ce):[]}(i),r)))}function Po(e){var t=0,r=0;return function(){var i=wr(),o=16-(i-r);if(r=i,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(n,arguments)}}function Oo(e,t){var r=-1,i=e.length,o=i-1;for(t=t===n?i:t;++r1?e[t-1]:n;return r="function"==typeof r?(e.pop(),r):n,ss(e,r)}));function hs(e){var t=Ur(e);return t.__chain__=!0,t}function fs(e,t){return t(e)}var ms=io((function(e){var t=e.length,r=t?e[0]:0,i=this.__wrapped__,o=function(t){return si(t,e)};return!(t>1||this.__actions__.length)&&i instanceof $r&&wo(r)?((i=i.slice(r,+r+(t?1:0))).__actions__.push({func:fs,args:[o],thisArg:n}),new Hr(i,this.__chain__).thru((function(e){return t&&!e.length&&e.push(n),e}))):this.thru(o)}));var gs=Mn((function(e,t,r){Oe.call(e,r)?++e[r]:oi(e,r,1)}));var ys=qn($o),vs=qn(Go);function bs(e,t){return(Gs(e)?It:pi)(e,co(t,3))}function ws(e,t){return(Gs(e)?At:hi)(e,co(t,3))}var _s=Mn((function(e,t,r){Oe.call(e,r)?e[r].push(t):oi(e,r,[t])}));var xs=Yi((function(e,t,r){var n=-1,o="function"==typeof t,s=Ks(e)?i(e.length):[];return pi(e,(function(e){s[++n]=o?Bt(t,e,r):Ai(e,t,r)})),s})),Ss=Mn((function(e,t,r){oi(e,r,t)}));function ks(e,t){return(Gs(e)?Pt:qi)(e,co(t,3))}var Es=Mn((function(e,t,r){e[r?0:1].push(t)}),(function(){return[[],[]]}));var Ts=Yi((function(e,t){if(null==e)return[];var r=t.length;return r>1&&_o(e,t[0],t[1])?t=[]:r>2&&_o(t[0],t[1],t[2])&&(t=[t[0]]),$i(e,yi(t,1),[])})),Bs=ct||function(){return mt.Date.now()};function Cs(e,t,r){return t=r?n:t,t=e&&null==t?e.length:t,Zn(e,u,n,n,n,n,t)}function Is(e,t){var r;if("function"!=typeof t)throw new Ae(o);return e=ma(e),function(){return--e>0&&(r=t.apply(this,arguments)),e<=1&&(t=n),r}}var As=Yi((function(e,t,r){var i=1;if(r.length){var n=cr(r,lo(As));i|=d}return Zn(e,i,t,r,n)})),Fs=Yi((function(e,t,r){var i=3;if(r.length){var n=cr(r,lo(Fs));i|=d}return Zn(t,i,e,r,n)}));function Ms(e,t,r){var i,s,a,l,d,c,u=0,p=!1,h=!1,f=!0;if("function"!=typeof e)throw new Ae(o);function m(t){var r=i,o=s;return i=s=n,u=t,l=e.apply(o,r)}function g(e){var r=e-c;return c===n||r>=t||r<0||h&&e-u>=a}function y(){var e=Bs();if(g(e))return v(e);d=Mo(y,function(e){var r=t-(e-c);return h?br(r,a-(e-u)):r}(e))}function v(e){return d=n,f&&i?m(e):(i=s=n,l)}function b(){var e=Bs(),r=g(e);if(i=arguments,s=this,c=e,r){if(d===n)return function(e){return u=e,d=Mo(y,t),p?m(e):l}(c);if(h)return Sn(d),d=Mo(y,t),m(c)}return d===n&&(d=Mo(y,t)),l}return t=ya(t)||0,ta(r)&&(p=!!r.leading,a=(h="maxWait"in r)?vr(ya(r.maxWait)||0,t):a,f="trailing"in r?!!r.trailing:f),b.cancel=function(){d!==n&&Sn(d),u=0,i=c=s=d=n},b.flush=function(){return d===n?l:v(Bs())},b}var Ds=Yi((function(e,t){return ci(e,1,t)})),Rs=Yi((function(e,t,r){return ci(e,ya(t)||0,r)}));function Ps(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new Ae(o);var r=function(){var i=arguments,n=t?t.apply(this,i):i[0],o=r.cache;if(o.has(n))return o.get(n);var s=e.apply(this,i);return r.cache=o.set(n,s)||o,s};return r.cache=new(Ps.Cache||Kr),r}function Os(e){if("function"!=typeof e)throw new Ae(o);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ps.Cache=Kr;var zs=_n((function(e,t){var r=(t=1==t.length&&Gs(t[0])?Pt(t[0],Xt(co())):Pt(yi(t,1),Xt(co()))).length;return Yi((function(i){for(var n=-1,o=br(i.length,r);++n=t})),$s=Fi(function(){return arguments}())?Fi:function(e){return ra(e)&&Oe.call(e,"callee")&&!Je.call(e,"callee")},Gs=i.isArray,Ws=_t?Xt(_t):function(e){return ra(e)&&Ei(e)==R};function Ks(e){return null!=e&&ea(e.length)&&!Zs(e)}function Vs(e){return ra(e)&&Ks(e)}var Js=bt||yl,Ys=xt?Xt(xt):function(e){return ra(e)&&Ei(e)==_};function Qs(e){if(!ra(e))return!1;var t=Ei(e);return t==x||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!oa(e)}function Zs(e){if(!ta(e))return!1;var t=Ei(e);return t==S||t==k||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Xs(e){return"number"==typeof e&&e==ma(e)}function ea(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=f}function ta(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function ra(e){return null!=e&&"object"==typeof e}var ia=St?Xt(St):function(e){return ra(e)&&go(e)==E};function na(e){return"number"==typeof e||ra(e)&&Ei(e)==T}function oa(e){if(!ra(e)||Ei(e)!=B)return!1;var t=Ke(e);if(null===t)return!0;var r=Oe.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Pe.call(r)==Ue}var sa=kt?Xt(kt):function(e){return ra(e)&&Ei(e)==I};var aa=Et?Xt(Et):function(e){return ra(e)&&go(e)==A};function la(e){return"string"==typeof e||!Gs(e)&&ra(e)&&Ei(e)==F}function da(e){return"symbol"==typeof e||ra(e)&&Ei(e)==M}var ca=Tt?Xt(Tt):function(e){return ra(e)&&ea(e.length)&&!!lt[Ei(e)]};var ua=Kn(Ni),pa=Kn((function(e,t){return e<=t}));function ha(e){if(!e)return[];if(Ks(e))return la(e)?fr(e):An(e);if(Ze&&e[Ze])return function(e){for(var t,r=[];!(t=e.next()).done;)r.push(t.value);return r}(e[Ze]());var t=go(e);return(t==E?lr:t==A?ur:La)(e)}function fa(e){return e?(e=ya(e))===h||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function ma(e){var t=fa(e),r=t%1;return t==t?r?t-r:t:0}function ga(e){return e?ai(ma(e),0,g):0}function ya(e){if("number"==typeof e)return e;if(da(e))return m;if(ta(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ta(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Zt(e);var r=ye.test(e);return r||be.test(e)?pt(e.slice(2),r?2:8):ge.test(e)?m:+e}function va(e){return Fn(e,Da(e))}function ba(e){return null==e?"":cn(e)}var wa=Dn((function(e,t){if(Eo(t)||Ks(t))Fn(t,Ma(t),e);else for(var r in t)Oe.call(t,r)&&ti(e,r,t[r])})),_a=Dn((function(e,t){Fn(t,Da(t),e)})),xa=Dn((function(e,t,r,i){Fn(t,Da(t),e,i)})),Sa=Dn((function(e,t,r,i){Fn(t,Ma(t),e,i)})),ka=io(si);var Ea=Yi((function(e,t){e=Be(e);var r=-1,i=t.length,o=i>2?t[2]:n;for(o&&_o(t[0],t[1],o)&&(i=1);++r1),t})),Fn(e,oo(e),r),i&&(r=li(r,7,to));for(var n=t.length;n--;)pn(r,t[n]);return r}));var za=io((function(e,t){return null==e?{}:function(e,t){return Gi(e,t,(function(t,r){return Ca(e,r)}))}(e,t)}));function Na(e,t){if(null==e)return{};var r=Pt(oo(e),(function(e){return[e]}));return t=co(t),Gi(e,r,(function(e,r){return t(e,r[0])}))}var qa=Qn(Ma),Ua=Qn(Da);function La(e){return null==e?[]:er(e,Ma(e))}var ja=zn((function(e,t,r){return t=t.toLowerCase(),e+(r?Ha(t):t)}));function Ha(e){return Qa(ba(e).toLowerCase())}function $a(e){return(e=ba(e))&&e.replace(_e,nr).replace(tt,"")}var Ga=zn((function(e,t,r){return e+(r?"-":"")+t.toLowerCase()})),Wa=zn((function(e,t,r){return e+(r?" ":"")+t.toLowerCase()})),Ka=On("toLowerCase");var Va=zn((function(e,t,r){return e+(r?"_":"")+t.toLowerCase()}));var Ja=zn((function(e,t,r){return e+(r?" ":"")+Qa(t)}));var Ya=zn((function(e,t,r){return e+(r?" ":"")+t.toUpperCase()})),Qa=On("toUpperCase");function Za(e,t,r){return e=ba(e),(t=r?n:t)===n?function(e){return ot.test(e)}(e)?function(e){return e.match(it)||[]}(e):function(e){return e.match(ue)||[]}(e):e.match(t)||[]}var Xa=Yi((function(e,t){try{return Bt(e,n,t)}catch(e){return Qs(e)?e:new ke(e)}})),el=io((function(e,t){return It(t,(function(t){t=No(t),oi(e,t,As(e[t],e))})),e}));function tl(e){return function(){return e}}var rl=Un(),il=Un(!0);function nl(e){return e}function ol(e){return Pi("function"==typeof e?e:li(e,1))}var sl=Yi((function(e,t){return function(r){return Ai(r,e,t)}})),al=Yi((function(e,t){return function(r){return Ai(e,r,t)}}));function ll(e,t,r){var i=Ma(t),n=xi(t,i);null!=r||ta(t)&&(n.length||!i.length)||(r=t,t=e,e=this,n=xi(t,Ma(t)));var o=!(ta(r)&&"chain"in r&&!r.chain),s=Zs(e);return It(n,(function(r){var i=t[r];e[r]=i,s&&(e.prototype[r]=function(){var t=this.__chain__;if(o||t){var r=e(this.__wrapped__);return(r.__actions__=An(this.__actions__)).push({func:i,args:arguments,thisArg:e}),r.__chain__=t,r}return i.apply(e,Ot([this.value()],arguments))})})),e}function dl(){}var cl=$n(Pt),ul=$n(Ft),pl=$n(qt);function hl(e){return xo(e)?Kt(No(e)):function(e){return function(t){return Si(t,e)}}(e)}var fl=Wn(),ml=Wn(!0);function gl(){return[]}function yl(){return!1}var vl=Hn((function(e,t){return e+t}),0),bl=Jn("ceil"),wl=Hn((function(e,t){return e/t}),1),_l=Jn("floor");var xl,Sl=Hn((function(e,t){return e*t}),1),kl=Jn("round"),El=Hn((function(e,t){return e-t}),0);return Ur.after=function(e,t){if("function"!=typeof t)throw new Ae(o);return e=ma(e),function(){if(--e<1)return t.apply(this,arguments)}},Ur.ary=Cs,Ur.assign=wa,Ur.assignIn=_a,Ur.assignInWith=xa,Ur.assignWith=Sa,Ur.at=ka,Ur.before=Is,Ur.bind=As,Ur.bindAll=el,Ur.bindKey=Fs,Ur.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Gs(e)?e:[e]},Ur.chain=hs,Ur.chunk=function(e,t,r){t=(r?_o(e,t,r):t===n)?1:vr(ma(t),0);var o=null==e?0:e.length;if(!o||t<1)return[];for(var s=0,a=0,l=i(ft(o/t));so?0:o+r),(i=i===n||i>o?o:ma(i))<0&&(i+=o),i=r>i?0:ga(i);r>>0)?(e=ba(e))&&("string"==typeof t||null!=t&&!sa(t))&&!(t=cn(t))&&ar(e)?xn(fr(e),0,r):e.split(t,r):[]},Ur.spread=function(e,t){if("function"!=typeof e)throw new Ae(o);return t=null==t?0:vr(ma(t),0),Yi((function(r){var i=r[t],n=xn(r,0,t);return i&&Ot(n,i),Bt(e,this,n)}))},Ur.tail=function(e){var t=null==e?0:e.length;return t?nn(e,1,t):[]},Ur.take=function(e,t,r){return e&&e.length?nn(e,0,(t=r||t===n?1:ma(t))<0?0:t):[]},Ur.takeRight=function(e,t,r){var i=null==e?0:e.length;return i?nn(e,(t=i-(t=r||t===n?1:ma(t)))<0?0:t,i):[]},Ur.takeRightWhile=function(e,t){return e&&e.length?fn(e,co(t,3),!1,!0):[]},Ur.takeWhile=function(e,t){return e&&e.length?fn(e,co(t,3)):[]},Ur.tap=function(e,t){return t(e),e},Ur.throttle=function(e,t,r){var i=!0,n=!0;if("function"!=typeof e)throw new Ae(o);return ta(r)&&(i="leading"in r?!!r.leading:i,n="trailing"in r?!!r.trailing:n),Ms(e,t,{leading:i,maxWait:t,trailing:n})},Ur.thru=fs,Ur.toArray=ha,Ur.toPairs=qa,Ur.toPairsIn=Ua,Ur.toPath=function(e){return Gs(e)?Pt(e,No):da(e)?[e]:An(zo(ba(e)))},Ur.toPlainObject=va,Ur.transform=function(e,t,r){var i=Gs(e),n=i||Js(e)||ca(e);if(t=co(t,4),null==r){var o=e&&e.constructor;r=n?i?new o:[]:ta(e)&&Zs(o)?Lr(Ke(e)):{}}return(n?It:wi)(e,(function(e,i,n){return t(r,e,i,n)})),r},Ur.unary=function(e){return Cs(e,1)},Ur.union=rs,Ur.unionBy=is,Ur.unionWith=ns,Ur.uniq=function(e){return e&&e.length?un(e):[]},Ur.uniqBy=function(e,t){return e&&e.length?un(e,co(t,2)):[]},Ur.uniqWith=function(e,t){return t="function"==typeof t?t:n,e&&e.length?un(e,n,t):[]},Ur.unset=function(e,t){return null==e||pn(e,t)},Ur.unzip=os,Ur.unzipWith=ss,Ur.update=function(e,t,r){return null==e?e:hn(e,t,bn(r))},Ur.updateWith=function(e,t,r,i){return i="function"==typeof i?i:n,null==e?e:hn(e,t,bn(r),i)},Ur.values=La,Ur.valuesIn=function(e){return null==e?[]:er(e,Da(e))},Ur.without=as,Ur.words=Za,Ur.wrap=function(e,t){return Ns(bn(t),e)},Ur.xor=ls,Ur.xorBy=ds,Ur.xorWith=cs,Ur.zip=us,Ur.zipObject=function(e,t){return yn(e||[],t||[],ti)},Ur.zipObjectDeep=function(e,t){return yn(e||[],t||[],Xi)},Ur.zipWith=ps,Ur.entries=qa,Ur.entriesIn=Ua,Ur.extend=_a,Ur.extendWith=xa,ll(Ur,Ur),Ur.add=vl,Ur.attempt=Xa,Ur.camelCase=ja,Ur.capitalize=Ha,Ur.ceil=bl,Ur.clamp=function(e,t,r){return r===n&&(r=t,t=n),r!==n&&(r=(r=ya(r))==r?r:0),t!==n&&(t=(t=ya(t))==t?t:0),ai(ya(e),t,r)},Ur.clone=function(e){return li(e,4)},Ur.cloneDeep=function(e){return li(e,5)},Ur.cloneDeepWith=function(e,t){return li(e,5,t="function"==typeof t?t:n)},Ur.cloneWith=function(e,t){return li(e,4,t="function"==typeof t?t:n)},Ur.conformsTo=function(e,t){return null==t||di(e,t,Ma(t))},Ur.deburr=$a,Ur.defaultTo=function(e,t){return null==e||e!=e?t:e},Ur.divide=wl,Ur.endsWith=function(e,t,r){e=ba(e),t=cn(t);var i=e.length,o=r=r===n?i:ai(ma(r),0,i);return(r-=t.length)>=0&&e.slice(r,o)==t},Ur.eq=Ls,Ur.escape=function(e){return(e=ba(e))&&Q.test(e)?e.replace(J,or):e},Ur.escapeRegExp=function(e){return(e=ba(e))&&oe.test(e)?e.replace(ne,"\\$&"):e},Ur.every=function(e,t,r){var i=Gs(e)?Ft:fi;return r&&_o(e,t,r)&&(t=n),i(e,co(t,3))},Ur.find=ys,Ur.findIndex=$o,Ur.findKey=function(e,t){return Lt(e,co(t,3),wi)},Ur.findLast=vs,Ur.findLastIndex=Go,Ur.findLastKey=function(e,t){return Lt(e,co(t,3),_i)},Ur.floor=_l,Ur.forEach=bs,Ur.forEachRight=ws,Ur.forIn=function(e,t){return null==e?e:vi(e,co(t,3),Da)},Ur.forInRight=function(e,t){return null==e?e:bi(e,co(t,3),Da)},Ur.forOwn=function(e,t){return e&&wi(e,co(t,3))},Ur.forOwnRight=function(e,t){return e&&_i(e,co(t,3))},Ur.get=Ba,Ur.gt=js,Ur.gte=Hs,Ur.has=function(e,t){return null!=e&&yo(e,t,Bi)},Ur.hasIn=Ca,Ur.head=Ko,Ur.identity=nl,Ur.includes=function(e,t,r,i){e=Ks(e)?e:La(e),r=r&&!i?ma(r):0;var n=e.length;return r<0&&(r=vr(n+r,0)),la(e)?r<=n&&e.indexOf(t,r)>-1:!!n&&Ht(e,t,r)>-1},Ur.indexOf=function(e,t,r){var i=null==e?0:e.length;if(!i)return-1;var n=null==r?0:ma(r);return n<0&&(n=vr(i+n,0)),Ht(e,t,n)},Ur.inRange=function(e,t,r){return t=fa(t),r===n?(r=t,t=0):r=fa(r),function(e,t,r){return e>=br(t,r)&&e=-9007199254740991&&e<=f},Ur.isSet=aa,Ur.isString=la,Ur.isSymbol=da,Ur.isTypedArray=ca,Ur.isUndefined=function(e){return e===n},Ur.isWeakMap=function(e){return ra(e)&&go(e)==D},Ur.isWeakSet=function(e){return ra(e)&&"[object WeakSet]"==Ei(e)},Ur.join=function(e,t){return null==e?"":Ut.call(e,t)},Ur.kebabCase=Ga,Ur.last=Qo,Ur.lastIndexOf=function(e,t,r){var i=null==e?0:e.length;if(!i)return-1;var o=i;return r!==n&&(o=(o=ma(r))<0?vr(i+o,0):br(o,i-1)),t==t?function(e,t,r){for(var i=r+1;i--;)if(e[i]===t)return i;return i}(e,t,o):jt(e,Gt,o,!0)},Ur.lowerCase=Wa,Ur.lowerFirst=Ka,Ur.lt=ua,Ur.lte=pa,Ur.max=function(e){return e&&e.length?mi(e,nl,Ti):n},Ur.maxBy=function(e,t){return e&&e.length?mi(e,co(t,2),Ti):n},Ur.mean=function(e){return Wt(e,nl)},Ur.meanBy=function(e,t){return Wt(e,co(t,2))},Ur.min=function(e){return e&&e.length?mi(e,nl,Ni):n},Ur.minBy=function(e,t){return e&&e.length?mi(e,co(t,2),Ni):n},Ur.stubArray=gl,Ur.stubFalse=yl,Ur.stubObject=function(){return{}},Ur.stubString=function(){return""},Ur.stubTrue=function(){return!0},Ur.multiply=Sl,Ur.nth=function(e,t){return e&&e.length?Hi(e,ma(t)):n},Ur.noConflict=function(){return mt._===this&&(mt._=Le),this},Ur.noop=dl,Ur.now=Bs,Ur.pad=function(e,t,r){e=ba(e);var i=(t=ma(t))?hr(e):0;if(!t||i>=t)return e;var n=(t-i)/2;return Gn(gt(n),r)+e+Gn(ft(n),r)},Ur.padEnd=function(e,t,r){e=ba(e);var i=(t=ma(t))?hr(e):0;return t&&it){var i=e;e=t,t=i}if(r||e%1||t%1){var o=xr();return br(e+o*(t-e+ut("1e-"+((o+"").length-1))),t)}return Vi(e,t)},Ur.reduce=function(e,t,r){var i=Gs(e)?zt:Jt,n=arguments.length<3;return i(e,co(t,4),r,n,pi)},Ur.reduceRight=function(e,t,r){var i=Gs(e)?Nt:Jt,n=arguments.length<3;return i(e,co(t,4),r,n,hi)},Ur.repeat=function(e,t,r){return t=(r?_o(e,t,r):t===n)?1:ma(t),Ji(ba(e),t)},Ur.replace=function(){var e=arguments,t=ba(e[0]);return e.length<3?t:t.replace(e[1],e[2])},Ur.result=function(e,t,r){var i=-1,o=(t=wn(t,e)).length;for(o||(o=1,e=n);++if)return[];var r=g,i=br(e,g);t=co(t),e-=g;for(var n=Qt(i,t);++r=s)return e;var l=r-hr(i);if(l<1)return i;var d=a?xn(a,0,l).join(""):e.slice(0,l);if(o===n)return d+i;if(a&&(l+=d.length-l),sa(o)){if(e.slice(l).search(o)){var c,u=d;for(o.global||(o=Ce(o.source,ba(me.exec(o))+"g")),o.lastIndex=0;c=o.exec(u);)var p=c.index;d=d.slice(0,p===n?l:p)}}else if(e.indexOf(cn(o),l)!=l){var h=d.lastIndexOf(o);h>-1&&(d=d.slice(0,h))}return d+i},Ur.unescape=function(e){return(e=ba(e))&&Y.test(e)?e.replace(V,gr):e},Ur.uniqueId=function(e){var t=++ze;return ba(e)+t},Ur.upperCase=Ya,Ur.upperFirst=Qa,Ur.each=bs,Ur.eachRight=ws,Ur.first=Ko,ll(Ur,(xl={},wi(Ur,(function(e,t){Oe.call(Ur.prototype,t)||(xl[t]=e)})),xl),{chain:!1}),Ur.VERSION="4.17.21",It(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){Ur[e].placeholder=Ur})),It(["drop","take"],(function(e,t){$r.prototype[e]=function(r){r=r===n?1:vr(ma(r),0);var i=this.__filtered__&&!t?new $r(this):this.clone();return i.__filtered__?i.__takeCount__=br(r,i.__takeCount__):i.__views__.push({size:br(r,g),type:e+(i.__dir__<0?"Right":"")}),i},$r.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),It(["filter","map","takeWhile"],(function(e,t){var r=t+1,i=1==r||3==r;$r.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:co(e,3),type:r}),t.__filtered__=t.__filtered__||i,t}})),It(["head","last"],(function(e,t){var r="take"+(t?"Right":"");$r.prototype[e]=function(){return this[r](1).value()[0]}})),It(["initial","tail"],(function(e,t){var r="drop"+(t?"":"Right");$r.prototype[e]=function(){return this.__filtered__?new $r(this):this[r](1)}})),$r.prototype.compact=function(){return this.filter(nl)},$r.prototype.find=function(e){return this.filter(e).head()},$r.prototype.findLast=function(e){return this.reverse().find(e)},$r.prototype.invokeMap=Yi((function(e,t){return"function"==typeof e?new $r(this):this.map((function(r){return Ai(r,e,t)}))})),$r.prototype.reject=function(e){return this.filter(Os(co(e)))},$r.prototype.slice=function(e,t){e=ma(e);var r=this;return r.__filtered__&&(e>0||t<0)?new $r(r):(e<0?r=r.takeRight(-e):e&&(r=r.drop(e)),t!==n&&(r=(t=ma(t))<0?r.dropRight(-t):r.take(t-e)),r)},$r.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},$r.prototype.toArray=function(){return this.take(g)},wi($r.prototype,(function(e,t){var r=/^(?:filter|find|map|reject)|While$/.test(t),i=/^(?:head|last)$/.test(t),o=Ur[i?"take"+("last"==t?"Right":""):t],s=i||/^find/.test(t);o&&(Ur.prototype[t]=function(){var t=this.__wrapped__,a=i?[1]:arguments,l=t instanceof $r,d=a[0],c=l||Gs(t),u=function(e){var t=o.apply(Ur,Ot([e],a));return i&&p?t[0]:t};c&&r&&"function"==typeof d&&1!=d.length&&(l=c=!1);var p=this.__chain__,h=!!this.__actions__.length,f=s&&!p,m=l&&!h;if(!s&&c){t=m?t:new $r(this);var g=e.apply(t,a);return g.__actions__.push({func:fs,args:[u],thisArg:n}),new Hr(g,p)}return f&&m?e.apply(this,a):(g=this.thru(u),f?i?g.value()[0]:g.value():g)})})),It(["pop","push","shift","sort","splice","unshift"],(function(e){var t=Fe[e],r=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",i=/^(?:pop|shift)$/.test(e);Ur.prototype[e]=function(){var e=arguments;if(i&&!this.__chain__){var n=this.value();return t.apply(Gs(n)?n:[],e)}return this[r]((function(r){return t.apply(Gs(r)?r:[],e)}))}})),wi($r.prototype,(function(e,t){var r=Ur[t];if(r){var i=r.name+"";Oe.call(Fr,i)||(Fr[i]=[]),Fr[i].push({name:t,func:r})}})),Fr[Ln(n,2).name]=[{name:"wrapper",func:n}],$r.prototype.clone=function(){var e=new $r(this.__wrapped__);return e.__actions__=An(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=An(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=An(this.__views__),e},$r.prototype.reverse=function(){if(this.__filtered__){var e=new $r(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},$r.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,r=Gs(e),i=t<0,n=r?e.length:0,o=function(e,t,r){var i=-1,n=r.length;for(;++i=this.__values__.length;return{done:e,value:e?n:this.__values__[this.__index__++]}},Ur.prototype.plant=function(e){for(var t,r=this;r instanceof jr;){var i=Uo(r);i.__index__=0,i.__values__=n,t?o.__wrapped__=i:t=i;var o=i;r=r.__wrapped__}return o.__wrapped__=e,t},Ur.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof $r){var t=e;return this.__actions__.length&&(t=new $r(this)),(t=t.reverse()).__actions__.push({func:fs,args:[ts],thisArg:n}),new Hr(t,this.__chain__)}return this.thru(ts)},Ur.prototype.toJSON=Ur.prototype.valueOf=Ur.prototype.value=function(){return mn(this.__wrapped__,this.__actions__)},Ur.prototype.first=Ur.prototype.head,Ze&&(Ur.prototype[Ze]=function(){return this}),Ur}();mt._=yr,(i=function(){return yr}.call(t,r,t,e))===n||(e.exports=i)}.call(this)},55364:(e,t,r)=>{var i=r(85250),n=r(20999)((function(e,t,r){i(e,t,r)}));e.exports=n},10124:(e,t,r)=>{var i=r(9325);e.exports=function(){return i.Date.now()}},58253:(e,t,r)=>{var i=r(13195),n=r(36800),o=r(17400),s=parseFloat,a=Math.min,l=Math.random;e.exports=function(e,t,r){if(r&&"boolean"!=typeof r&&n(e,t,r)&&(t=r=void 0),void 0===r&&("boolean"==typeof t?(r=t,t=void 0):"boolean"==typeof e&&(r=e,e=void 0)),void 0===e&&void 0===t?(e=0,t=1):(e=o(e),void 0===t?(t=e,e=0):t=o(t)),e>t){var d=e;e=t,t=d}if(r||e%1||t%1){var c=l();return a(e+c*(t-e+s("1e-"+((c+"").length-1))),t)}return i(e,t)}},63345:e=>{e.exports=function(){return[]}},89935:e=>{e.exports=function(){return!1}},7350:(e,t,r)=>{var i=r(38221),n=r(23805);e.exports=function(e,t,r){var o=!0,s=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return n(r)&&(o="leading"in r?!!r.leading:o,s="trailing"in r?!!r.trailing:s),i(e,t,{leading:o,maxWait:t,trailing:s})}},17400:(e,t,r)=>{var i=r(99374),n=1/0;e.exports=function(e){return e?(e=i(e))===n||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},61489:(e,t,r)=>{var i=r(17400);e.exports=function(e){var t=i(e),r=t%1;return t==t?r?t-r:t:0}},99374:(e,t,r)=>{var i=r(54128),n=r(23805),o=r(44394),s=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,l=/^0o[0-7]+$/i,d=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(o(e))return NaN;if(n(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=n(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=i(e);var r=a.test(e);return r||l.test(e)?d(e.slice(2),r?2:8):s.test(e)?NaN:+e}},69884:(e,t,r)=>{var i=r(21791),n=r(37241);e.exports=function(e){return i(e,n(e))}},88276:(e,t,r)=>{"use strict";var i=r(56698),n=r(4729),o=r(92861).Buffer,s=new Array(16);function a(){n.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function l(e,t){return e<>>32-t}function d(e,t,r,i,n,o,s){return l(e+(t&r|~t&i)+n+o|0,s)+t|0}function c(e,t,r,i,n,o,s){return l(e+(t&i|r&~i)+n+o|0,s)+t|0}function u(e,t,r,i,n,o,s){return l(e+(t^r^i)+n+o|0,s)+t|0}function p(e,t,r,i,n,o,s){return l(e+(r^(t|~i))+n+o|0,s)+t|0}i(a,n),a.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,i=this._b,n=this._c,o=this._d;r=d(r,i,n,o,e[0],3614090360,7),o=d(o,r,i,n,e[1],3905402710,12),n=d(n,o,r,i,e[2],606105819,17),i=d(i,n,o,r,e[3],3250441966,22),r=d(r,i,n,o,e[4],4118548399,7),o=d(o,r,i,n,e[5],1200080426,12),n=d(n,o,r,i,e[6],2821735955,17),i=d(i,n,o,r,e[7],4249261313,22),r=d(r,i,n,o,e[8],1770035416,7),o=d(o,r,i,n,e[9],2336552879,12),n=d(n,o,r,i,e[10],4294925233,17),i=d(i,n,o,r,e[11],2304563134,22),r=d(r,i,n,o,e[12],1804603682,7),o=d(o,r,i,n,e[13],4254626195,12),n=d(n,o,r,i,e[14],2792965006,17),r=c(r,i=d(i,n,o,r,e[15],1236535329,22),n,o,e[1],4129170786,5),o=c(o,r,i,n,e[6],3225465664,9),n=c(n,o,r,i,e[11],643717713,14),i=c(i,n,o,r,e[0],3921069994,20),r=c(r,i,n,o,e[5],3593408605,5),o=c(o,r,i,n,e[10],38016083,9),n=c(n,o,r,i,e[15],3634488961,14),i=c(i,n,o,r,e[4],3889429448,20),r=c(r,i,n,o,e[9],568446438,5),o=c(o,r,i,n,e[14],3275163606,9),n=c(n,o,r,i,e[3],4107603335,14),i=c(i,n,o,r,e[8],1163531501,20),r=c(r,i,n,o,e[13],2850285829,5),o=c(o,r,i,n,e[2],4243563512,9),n=c(n,o,r,i,e[7],1735328473,14),r=u(r,i=c(i,n,o,r,e[12],2368359562,20),n,o,e[5],4294588738,4),o=u(o,r,i,n,e[8],2272392833,11),n=u(n,o,r,i,e[11],1839030562,16),i=u(i,n,o,r,e[14],4259657740,23),r=u(r,i,n,o,e[1],2763975236,4),o=u(o,r,i,n,e[4],1272893353,11),n=u(n,o,r,i,e[7],4139469664,16),i=u(i,n,o,r,e[10],3200236656,23),r=u(r,i,n,o,e[13],681279174,4),o=u(o,r,i,n,e[0],3936430074,11),n=u(n,o,r,i,e[3],3572445317,16),i=u(i,n,o,r,e[6],76029189,23),r=u(r,i,n,o,e[9],3654602809,4),o=u(o,r,i,n,e[12],3873151461,11),n=u(n,o,r,i,e[15],530742520,16),r=p(r,i=u(i,n,o,r,e[2],3299628645,23),n,o,e[0],4096336452,6),o=p(o,r,i,n,e[7],1126891415,10),n=p(n,o,r,i,e[14],2878612391,15),i=p(i,n,o,r,e[5],4237533241,21),r=p(r,i,n,o,e[12],1700485571,6),o=p(o,r,i,n,e[3],2399980690,10),n=p(n,o,r,i,e[10],4293915773,15),i=p(i,n,o,r,e[1],2240044497,21),r=p(r,i,n,o,e[8],1873313359,6),o=p(o,r,i,n,e[15],4264355552,10),n=p(n,o,r,i,e[6],2734768916,15),i=p(i,n,o,r,e[13],1309151649,21),r=p(r,i,n,o,e[4],4149444226,6),o=p(o,r,i,n,e[11],3174756917,10),n=p(n,o,r,i,e[2],718787259,15),i=p(i,n,o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+i|0,this._c=this._c+n|0,this._d=this._d+o|0},a.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=a},52244:(e,t,r)=>{var i=r(61158),n=r(15037);function o(e){this.rand=e||new n.Rand}e.exports=o,o.create=function(e){return new o(e)},o.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var n=new i(this.rand.generate(r))}while(n.cmp(e)>=0);return n},o.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},o.prototype.test=function(e,t,r){var n=e.bitLength(),o=i.mont(e),s=new i(1).toRed(o);t||(t=Math.max(1,n/48|0));for(var a=e.subn(1),l=0;!a.testn(l);l++);for(var d=e.shrn(l),c=a.toRed(o);t>0;t--){var u=this._randrange(new i(2),a);r&&r(u);var p=u.toRed(o).redPow(d);if(0!==p.cmp(s)&&0!==p.cmp(c)){for(var h=1;h0;t--){var c=this._randrange(new i(2),s),u=e.gcd(c);if(0!==u.cmpn(1))return u;var p=c.toRed(n).redPow(l);if(0!==p.cmp(o)&&0!==p.cmp(d)){for(var h=1;h=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},7598:(e,t,r)=>{ +/*! + * mime-db + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2015-2022 Douglas Christopher Wilson + * MIT Licensed + */ +e.exports=r(81813)},86049:(e,t,r)=>{"use strict"; +/*! + * mime-types + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2015 Douglas Christopher Wilson + * MIT Licensed + */var i,n,o,s=r(7598),a=r(57975).extname,l=/^\s*([^;\s]*)(?:;|\s|$)/,d=/^text\//i;function c(e){if(!e||"string"!=typeof e)return!1;var t=l.exec(e),r=t&&s[t[1].toLowerCase()];return r&&r.charset?r.charset:!(!t||!d.test(t[1]))&&"UTF-8"}t.charset=c,t.charsets={lookup:c},t.contentType=function(e){if(!e||"string"!=typeof e)return!1;var r=-1===e.indexOf("/")?t.lookup(e):e;if(!r)return!1;if(-1===r.indexOf("charset")){var i=t.charset(r);i&&(r+="; charset="+i.toLowerCase())}return r},t.extension=function(e){if(!e||"string"!=typeof e)return!1;var r=l.exec(e),i=r&&t.extensions[r[1].toLowerCase()];if(!i||!i.length)return!1;return i[0]},t.extensions=Object.create(null),t.lookup=function(e){if(!e||"string"!=typeof e)return!1;var r=a("x."+e).toLowerCase().substr(1);if(!r)return!1;return t.types[r]||!1},t.types=Object.create(null),i=t.extensions,n=t.types,o=["nginx","apache",void 0,"iana"],Object.keys(s).forEach((function(e){var t=s[e],r=t.extensions;if(r&&r.length){i[e]=r;for(var a=0;ac||d===c&&"application/"===n[l].substr(0,12)))continue}n[l]=e}}}))},43349:e=>{function t(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=t,t.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},64367:(e,t)=>{"use strict";var r=t;function i(e){return 1===e.length?"0"+e:e}function n(e){for(var t="",r=0;r>8,s=255&n;o?r.push(o,s):r.push(s)}return r},r.zero2=i,r.toHex=n,r.encode=function(e,t){return"hex"===t?n(e):e}},6585:e=>{var t=1e3,r=60*t,i=60*r,n=24*i,o=7*n,s=365.25*n;function a(e,t,r,i){var n=t>=1.5*r;return Math.round(e/r)+" "+i+(n?"s":"")}e.exports=function(e,l){l=l||{};var d=typeof e;if("string"===d&&e.length>0)return function(e){if((e=String(e)).length>100)return;var a=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!a)return;var l=parseFloat(a[1]);switch((a[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return l*s;case"weeks":case"week":case"w":return l*o;case"days":case"day":case"d":return l*n;case"hours":case"hour":case"hrs":case"hr":case"h":return l*i;case"minutes":case"minute":case"mins":case"min":case"m":return l*r;case"seconds":case"second":case"secs":case"sec":case"s":return l*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:return}}(e);if("number"===d&&isFinite(e))return l.long?function(e){var o=Math.abs(e);if(o>=n)return a(e,o,n,"day");if(o>=i)return a(e,o,i,"hour");if(o>=r)return a(e,o,r,"minute");if(o>=t)return a(e,o,t,"second");return e+" ms"}(e):function(e){var o=Math.abs(e);if(o>=n)return Math.round(e/n)+"d";if(o>=i)return Math.round(e/i)+"h";if(o>=r)return Math.round(e/r)+"m";if(o>=t)return Math.round(e/t)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},43092:(e,t,r)=>{"use strict";var i=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r.g)return r.g;throw new Error("unable to locate global object")}();e.exports=t=i.fetch,i.fetch&&(t.default=i.fetch.bind(i)),t.Headers=i.Headers,t.Request=i.Request,t.Response=i.Response},58859:(e,t,r)=>{var i="function"==typeof Map&&Map.prototype,n=Object.getOwnPropertyDescriptor&&i?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=i&&n&&"function"==typeof n.get?n.get:null,s=i&&Map.prototype.forEach,a="function"==typeof Set&&Set.prototype,l=Object.getOwnPropertyDescriptor&&a?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,d=a&&l&&"function"==typeof l.get?l.get:null,c=a&&Set.prototype.forEach,u="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,p="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,h="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,f=Boolean.prototype.valueOf,m=Object.prototype.toString,g=Function.prototype.toString,y=String.prototype.match,v=String.prototype.slice,b=String.prototype.replace,w=String.prototype.toUpperCase,_=String.prototype.toLowerCase,x=RegExp.prototype.test,S=Array.prototype.concat,k=Array.prototype.join,E=Array.prototype.slice,T=Math.floor,B="function"==typeof BigInt?BigInt.prototype.valueOf:null,C=Object.getOwnPropertySymbols,I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,A="function"==typeof Symbol&&"object"==typeof Symbol.iterator,F="function"==typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===A||"symbol")?Symbol.toStringTag:null,M=Object.prototype.propertyIsEnumerable,D=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function R(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||x.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var i=e<0?-T(-e):T(e);if(i!==e){var n=String(i),o=v.call(t,n.length+1);return b.call(n,r,"$&_")+"."+b.call(b.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return b.call(t,r,"$&_")}var P=r(42634),O=P.custom,z=j(O)?O:null;function N(e,t,r){var i="double"===(r.quoteStyle||t)?'"':"'";return i+e+i}function q(e){return b.call(String(e),/"/g,""")}function U(e){return!("[object Array]"!==G(e)||F&&"object"==typeof e&&F in e)}function L(e){return!("[object RegExp]"!==G(e)||F&&"object"==typeof e&&F in e)}function j(e){if(A)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!I)return!1;try{return I.call(e),!0}catch(e){}return!1}e.exports=function e(t,i,n,a){var l=i||{};if($(l,"quoteStyle")&&"single"!==l.quoteStyle&&"double"!==l.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if($(l,"maxStringLength")&&("number"==typeof l.maxStringLength?l.maxStringLength<0&&l.maxStringLength!==1/0:null!==l.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var m=!$(l,"customInspect")||l.customInspect;if("boolean"!=typeof m&&"symbol"!==m)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if($(l,"indent")&&null!==l.indent&&"\t"!==l.indent&&!(parseInt(l.indent,10)===l.indent&&l.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if($(l,"numericSeparator")&&"boolean"!=typeof l.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var w=l.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return K(t,l);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var x=String(t);return w?R(t,x):x}if("bigint"==typeof t){var T=String(t)+"n";return w?R(t,T):T}var C=void 0===l.depth?5:l.depth;if(void 0===n&&(n=0),n>=C&&C>0&&"object"==typeof t)return U(t)?"[Array]":"[Object]";var O=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=k.call(Array(e.indent+1)," ")}return{base:r,prev:k.call(Array(t+1),r)}}(l,n);if(void 0===a)a=[];else if(W(a,t)>=0)return"[Circular]";function H(t,r,i){if(r&&(a=E.call(a)).push(r),i){var o={depth:l.depth};return $(l,"quoteStyle")&&(o.quoteStyle=l.quoteStyle),e(t,o,n+1,a)}return e(t,l,n+1,a)}if("function"==typeof t&&!L(t)){var V=function(e){if(e.name)return e.name;var t=y.call(g.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(t),ee=X(t,H);return"[Function"+(V?": "+V:" (anonymous)")+"]"+(ee.length>0?" { "+k.call(ee,", ")+" }":"")}if(j(t)){var te=A?b.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):I.call(t);return"object"!=typeof t||A?te:J(te)}if(function(e){if(!e||"object"!=typeof e)return!1;if("undefined"!=typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"==typeof e.nodeName&&"function"==typeof e.getAttribute}(t)){for(var re="<"+_.call(String(t.nodeName)),ie=t.attributes||[],ne=0;ne"}if(U(t)){if(0===t.length)return"[]";var oe=X(t,H);return O&&!function(e){for(var t=0;t=0)return!1;return!0}(oe)?"["+Z(oe,O)+"]":"[ "+k.call(oe,", ")+" ]"}if(function(e){return!("[object Error]"!==G(e)||F&&"object"==typeof e&&F in e)}(t)){var se=X(t,H);return"cause"in Error.prototype||!("cause"in t)||M.call(t,"cause")?0===se.length?"["+String(t)+"]":"{ ["+String(t)+"] "+k.call(se,", ")+" }":"{ ["+String(t)+"] "+k.call(S.call("[cause]: "+H(t.cause),se),", ")+" }"}if("object"==typeof t&&m){if(z&&"function"==typeof t[z]&&P)return P(t,{depth:C-n});if("symbol"!==m&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!o||!e||"object"!=typeof e)return!1;try{o.call(e);try{d.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var ae=[];return s&&s.call(t,(function(e,r){ae.push(H(r,t,!0)+" => "+H(e,t))})),Q("Map",o.call(t),ae,O)}if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{d.call(e);try{o.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var le=[];return c&&c.call(t,(function(e){le.push(H(e,t))})),Q("Set",d.call(t),le,O)}if(function(e){if(!u||!e||"object"!=typeof e)return!1;try{u.call(e,u);try{p.call(e,p)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return Y("WeakMap");if(function(e){if(!p||!e||"object"!=typeof e)return!1;try{p.call(e,p);try{u.call(e,u)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return Y("WeakSet");if(function(e){if(!h||!e||"object"!=typeof e)return!1;try{return h.call(e),!0}catch(e){}return!1}(t))return Y("WeakRef");if(function(e){return!("[object Number]"!==G(e)||F&&"object"==typeof e&&F in e)}(t))return J(H(Number(t)));if(function(e){if(!e||"object"!=typeof e||!B)return!1;try{return B.call(e),!0}catch(e){}return!1}(t))return J(H(B.call(t)));if(function(e){return!("[object Boolean]"!==G(e)||F&&"object"==typeof e&&F in e)}(t))return J(f.call(t));if(function(e){return!("[object String]"!==G(e)||F&&"object"==typeof e&&F in e)}(t))return J(H(String(t)));if("undefined"!=typeof window&&t===window)return"{ [object Window] }";if("undefined"!=typeof globalThis&&t===globalThis||void 0!==r.g&&t===r.g)return"{ [object globalThis] }";if(!function(e){return!("[object Date]"!==G(e)||F&&"object"==typeof e&&F in e)}(t)&&!L(t)){var de=X(t,H),ce=D?D(t)===Object.prototype:t instanceof Object||t.constructor===Object,ue=t instanceof Object?"":"null prototype",pe=!ce&&F&&Object(t)===t&&F in t?v.call(G(t),8,-1):ue?"Object":"",he=(ce||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(pe||ue?"["+k.call(S.call([],pe||[],ue||[]),": ")+"] ":"");return 0===de.length?he+"{}":O?he+"{"+Z(de,O)+"}":he+"{ "+k.call(de,", ")+" }"}return String(t)};var H=Object.prototype.hasOwnProperty||function(e){return e in this};function $(e,t){return H.call(e,t)}function G(e){return m.call(e)}function W(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,i=e.length;rt.maxStringLength){var r=e.length-t.maxStringLength,i="... "+r+" more character"+(r>1?"s":"");return K(v.call(e,0,t.maxStringLength),t)+i}return N(b.call(b.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,V),"single",t)}function V(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+w.call(t.toString(16))}function J(e){return"Object("+e+")"}function Y(e){return e+" { ? }"}function Q(e,t,r,i){return e+" ("+t+") {"+(i?Z(r,i):k.call(r,", "))+"}"}function Z(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+k.call(e,","+r)+"\n"+t.prev}function X(e,t){var r=U(e),i=[];if(r){i.length=e.length;for(var n=0;n{"use strict";var i=r(87568);t.certificate=r(36413);var n=i.define("RSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}));t.RSAPrivateKey=n;var o=i.define("RSAPublicKey",(function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())}));t.RSAPublicKey=o;var s=i.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())})),a=i.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}));t.PublicKey=a;var l=i.define("PrivateKeyInfo",(function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())}));t.PrivateKey=l;var d=i.define("EncryptedPrivateKeyInfo",(function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())}));t.EncryptedPrivateKey=d;var c=i.define("DSAPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())}));t.DSAPrivateKey=c,t.DSAparam=i.define("DSAparam",(function(){this.int()}));var u=i.define("ECParameters",(function(){this.choice({namedCurve:this.objid()})})),p=i.define("ECPrivateKey",(function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(u),this.key("publicKey").optional().explicit(1).bitstr())}));t.ECPrivateKey=p,t.signature=i.define("signature",(function(){this.seq().obj(this.key("r").int(),this.key("s").int())}))},36413:(e,t,r)=>{"use strict";var i=r(87568),n=i.define("Time",(function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})})),o=i.define("AttributeTypeValue",(function(){this.seq().obj(this.key("type").objid(),this.key("value").any())})),s=i.define("AlgorithmIdentifier",(function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())})),a=i.define("SubjectPublicKeyInfo",(function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())})),l=i.define("RelativeDistinguishedName",(function(){this.setof(o)})),d=i.define("RDNSequence",(function(){this.seqof(l)})),c=i.define("Name",(function(){this.choice({rdnSequence:this.use(d)})})),u=i.define("Validity",(function(){this.seq().obj(this.key("notBefore").use(n),this.key("notAfter").use(n))})),p=i.define("Extension",(function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())})),h=i.define("TBSCertificate",(function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(s),this.key("issuer").use(c),this.key("validity").use(u),this.key("subject").use(c),this.key("subjectPublicKeyInfo").use(a),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(p).optional())})),f=i.define("X509Certificate",(function(){this.seq().obj(this.key("tbsCertificate").use(h),this.key("signatureAlgorithm").use(s),this.key("signatureValue").bitstr())}));e.exports=f},24101:(e,t,r)=>{"use strict";var i=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,n=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,o=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,s=r(68078),a=r(1241),l=r(92861).Buffer;e.exports=function(e,t){var r,d=e.toString(),c=d.match(i);if(c){var u="aes"+c[1],p=l.from(c[2],"hex"),h=l.from(c[3].replace(/[\r\n]/g,""),"base64"),f=s(t,p.slice(0,8),parseInt(c[1],10)).key,m=[],g=a.createDecipheriv(u,f,p);m.push(g.update(h)),m.push(g.final()),r=l.concat(m)}else{var y=d.match(o);r=l.from(y[2].replace(/[\r\n]/g,""),"base64")}return{tag:d.match(n)[1],data:r}}},78170:(e,t,r)=>{"use strict";var i=r(21137),n=r(15579),o=r(24101),s=r(1241),a=r(78396),l=r(92861).Buffer;function d(e){var t;"object"!=typeof e||l.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=l.from(e));var r,d,c=o(e,t),u=c.tag,p=c.data;switch(u){case"CERTIFICATE":d=i.certificate.decode(p,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(d||(d=i.PublicKey.decode(p,"der")),r=d.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPublicKey.decode(d.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return d.subjectPrivateKey=d.subjectPublicKey,{type:"ec",data:d};case"1.2.840.10040.4.1":return d.algorithm.params.pub_key=i.DSAparam.decode(d.subjectPublicKey.data,"der"),{type:"dsa",data:d.algorithm.params};default:throw new Error("unknown key id "+r)}case"ENCRYPTED PRIVATE KEY":p=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,i=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),o=n[e.algorithm.decrypt.cipher.algo.join(".")],d=e.algorithm.decrypt.cipher.iv,c=e.subjectPrivateKey,u=parseInt(o.split("-")[1],10)/8,p=a.pbkdf2Sync(t,r,i,u,"sha1"),h=s.createDecipheriv(o,p,d),f=[];return f.push(h.update(c)),f.push(h.final()),l.concat(f)}(p=i.EncryptedPrivateKey.decode(p,"der"),t);case"PRIVATE KEY":switch(r=(d=i.PrivateKey.decode(p,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return i.RSAPrivateKey.decode(d.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:d.algorithm.curve,privateKey:i.ECPrivateKey.decode(d.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return d.algorithm.params.priv_key=i.DSAparam.decode(d.subjectPrivateKey,"der"),{type:"dsa",params:d.algorithm.params};default:throw new Error("unknown key id "+r)}case"RSA PUBLIC KEY":return i.RSAPublicKey.decode(p,"der");case"RSA PRIVATE KEY":return i.RSAPrivateKey.decode(p,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:i.DSAPrivateKey.decode(p,"der")};case"EC PRIVATE KEY":return{curve:(p=i.ECPrivateKey.decode(p,"der")).parameters.value,privateKey:p.privateKey};default:throw new Error("unknown key type "+u)}}d.signature=i.signature,e.exports=d},57975:(e,t,r)=>{"use strict";var i=r(65606);function n(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function o(e,t){for(var r,i="",n=0,o=-1,s=0,a=0;a<=e.length;++a){if(a2){var l=i.lastIndexOf("/");if(l!==i.length-1){-1===l?(i="",n=0):n=(i=i.slice(0,l)).length-1-i.lastIndexOf("/"),o=a,s=0;continue}}else if(2===i.length||1===i.length){i="",n=0,o=a,s=0;continue}t&&(i.length>0?i+="/..":i="..",n=2)}else i.length>0?i+="/"+e.slice(o+1,a):i=e.slice(o+1,a),n=a-o-1;o=a,s=0}else 46===r&&-1!==s?++s:s=-1}return i}var s={resolve:function(){for(var e,t="",r=!1,s=arguments.length-1;s>=-1&&!r;s--){var a;s>=0?a=arguments[s]:(void 0===e&&(e=i.cwd()),a=e),n(a),0!==a.length&&(t=a+"/"+t,r=47===a.charCodeAt(0))}return t=o(t,!r),r?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function(e){if(n(e),0===e.length)return".";var t=47===e.charCodeAt(0),r=47===e.charCodeAt(e.length-1);return 0!==(e=o(e,!t)).length||t||(e="."),e.length>0&&r&&(e+="/"),t?"/"+e:e},isAbsolute:function(e){return n(e),e.length>0&&47===e.charCodeAt(0)},join:function(){if(0===arguments.length)return".";for(var e,t=0;t0&&(void 0===e?e=r:e+="/"+r)}return void 0===e?".":s.normalize(e)},relative:function(e,t){if(n(e),n(t),e===t)return"";if((e=s.resolve(e))===(t=s.resolve(t)))return"";for(var r=1;rd){if(47===t.charCodeAt(a+u))return t.slice(a+u+1);if(0===u)return t.slice(a+u)}else o>d&&(47===e.charCodeAt(r+u)?c=u:0===u&&(c=0));break}var p=e.charCodeAt(r+u);if(p!==t.charCodeAt(a+u))break;47===p&&(c=u)}var h="";for(u=r+c+1;u<=i;++u)u!==i&&47!==e.charCodeAt(u)||(0===h.length?h+="..":h+="/..");return h.length>0?h+t.slice(a+c):(a+=c,47===t.charCodeAt(a)&&++a,t.slice(a))},_makeLong:function(e){return e},dirname:function(e){if(n(e),0===e.length)return".";for(var t=e.charCodeAt(0),r=47===t,i=-1,o=!0,s=e.length-1;s>=1;--s)if(47===(t=e.charCodeAt(s))){if(!o){i=s;break}}else o=!1;return-1===i?r?"/":".":r&&1===i?"//":e.slice(0,i)},basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');n(e);var r,i=0,o=-1,s=!0;if(void 0!==t&&t.length>0&&t.length<=e.length){if(t.length===e.length&&t===e)return"";var a=t.length-1,l=-1;for(r=e.length-1;r>=0;--r){var d=e.charCodeAt(r);if(47===d){if(!s){i=r+1;break}}else-1===l&&(s=!1,l=r+1),a>=0&&(d===t.charCodeAt(a)?-1==--a&&(o=r):(a=-1,o=l))}return i===o?o=l:-1===o&&(o=e.length),e.slice(i,o)}for(r=e.length-1;r>=0;--r)if(47===e.charCodeAt(r)){if(!s){i=r+1;break}}else-1===o&&(s=!1,o=r+1);return-1===o?"":e.slice(i,o)},extname:function(e){n(e);for(var t=-1,r=0,i=-1,o=!0,s=0,a=e.length-1;a>=0;--a){var l=e.charCodeAt(a);if(47!==l)-1===i&&(o=!1,i=a+1),46===l?-1===t?t=a:1!==s&&(s=1):-1!==t&&(s=-1);else if(!o){r=a+1;break}}return-1===t||-1===i||0===s||1===s&&t===i-1&&t===r+1?"":e.slice(t,i)},format:function(e){if(null===e||"object"!=typeof e)throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return function(e,t){var r=t.dir||t.root,i=t.base||(t.name||"")+(t.ext||"");return r?r===t.root?r+i:r+e+i:i}("/",e)},parse:function(e){n(e);var t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;var r,i=e.charCodeAt(0),o=47===i;o?(t.root="/",r=1):r=0;for(var s=-1,a=0,l=-1,d=!0,c=e.length-1,u=0;c>=r;--c)if(47!==(i=e.charCodeAt(c)))-1===l&&(d=!1,l=c+1),46===i?-1===s?s=c:1!==u&&(u=1):-1!==s&&(u=-1);else if(!d){a=c+1;break}return-1===s||-1===l||0===u||1===u&&s===l-1&&s===a+1?-1!==l&&(t.base=t.name=0===a&&o?e.slice(1,l):e.slice(a,l)):(0===a&&o?(t.name=e.slice(1,s),t.base=e.slice(1,l)):(t.name=e.slice(a,s),t.base=e.slice(a,l)),t.ext=e.slice(s,l)),a>0?t.dir=e.slice(0,a-1):o&&(t.dir="/"),t},sep:"/",delimiter:":",win32:null,posix:null};s.posix=s,e.exports=s},78396:(e,t,r)=>{t.pbkdf2=r(43832),t.pbkdf2Sync=r(21352)},43832:(e,t,r)=>{var i,n,o=r(92861).Buffer,s=r(64196),a=r(2455),l=r(21352),d=r(93382),c=r.g.crypto&&r.g.crypto.subtle,u={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},p=[];function h(){return n||(n=r.g.process&&r.g.process.nextTick?r.g.process.nextTick:r.g.queueMicrotask?r.g.queueMicrotask:r.g.setImmediate?r.g.setImmediate:r.g.setTimeout)}function f(e,t,r,i,n){return c.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then((function(e){return c.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:n}},e,i<<3)})).then((function(e){return o.from(e)}))}e.exports=function(e,t,n,m,g,y){"function"==typeof g&&(y=g,g=void 0);var v=u[(g=g||"sha1").toLowerCase()];if(v&&"function"==typeof r.g.Promise){if(s(n,m),e=d(e,a,"Password"),t=d(t,a,"Salt"),"function"!=typeof y)throw new Error("No callback provided to pbkdf2");!function(e,t){e.then((function(e){h()((function(){t(null,e)}))}),(function(e){h()((function(){t(e)}))}))}(function(e){if(r.g.process&&!r.g.process.browser)return Promise.resolve(!1);if(!c||!c.importKey||!c.deriveBits)return Promise.resolve(!1);if(void 0!==p[e])return p[e];var t=f(i=i||o.alloc(8),i,10,128,e).then((function(){return!0})).catch((function(){return!1}));return p[e]=t,t}(v).then((function(r){return r?f(e,t,n,m,v):l(e,t,n,m,g)})),y)}else h()((function(){var r;try{r=l(e,t,n,m,g)}catch(e){return y(e)}y(null,r)}))}},2455:(e,t,r)=>{var i,n=r(65606);if(r.g.process&&r.g.process.browser)i="utf-8";else if(r.g.process&&r.g.process.version){i=parseInt(n.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else i="utf-8";e.exports=i},64196:e=>{var t=Math.pow(2,30)-1;e.exports=function(e,r){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof r)throw new TypeError("Key length not a number");if(r<0||r>t||r!=r)throw new TypeError("Bad key length")}},21352:(e,t,r)=>{var i=r(20320),n=r(66011),o=r(62802),s=r(92861).Buffer,a=r(64196),l=r(2455),d=r(93382),c=s.alloc(128),u={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function p(e,t,r){var a=function(e){function t(t){return o(e).update(t).digest()}function r(e){return(new n).update(e).digest()}return"rmd160"===e||"ripemd160"===e?r:"md5"===e?i:t}(e),l="sha512"===e||"sha384"===e?128:64;t.length>l?t=a(t):t.length{var i=r(92861).Buffer;e.exports=function(e,t,r){if(i.isBuffer(e))return e;if("string"==typeof e)return i.from(e,t);if(ArrayBuffer.isView(e))return i.from(e.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},57985:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.apiServer,i=void 0===r?d:r,u=t.apiProtocol,p=void 0===u?"https":u,h=t.params,f=void 0===h?{}:h,m=(0,n.default)(t,["apiServer","apiProtocol","params"]);(0,s.default)((0,a.isApiMethod)(e),"Method `"+e+"` is not pCloud API method."),(0,s.default)(!(0,a.isAuthMethod)(e)||"auth"in f||"access_token"in f||"username"in f,"`auth` must be present for methods that require authentication.");var g=o.default.format({protocol:p,host:c[locationid]||i,pathname:e,query:f});void 0===m.responseType&&(m.responseType="json");return(0,l.default)(g,m).then((function(e){return"json"===m.responseType&&0!==e.result?Promise.reject(e):e}))};var n=i(r(91847)),o=i(r(88835)),s=i(r(20311)),a=r(27413),l=i(r(47023)),d="eapi.pcloud.com",c={1:"api.pcloud.com",2:"eapi.pcloud.com"}},47023:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};(0,s.default)(e.length,"`url` is required.");var r=t.method,i=void 0===r?"get":r,u=t.responseType,p=void 0===u?"json":u,h=t.onProgress,f=void 0===h?function(){}:h,m=t.xhr,g=t.pipe,y=void 0!==g&&g,v=t.files,b=void 0===v?[]:v;if("get"===i&&e in l)return void 0===d[e]&&(d[e]=[]),new Promise((function(r){d[e].push([function(e){r(e)},t])}));l[e]=1;var w=o.default[i](e);w.on("progress",f),b.length&&((0,s.default)(-1!==["put","post"].indexOf(i),"When uploading, `method` must be either `post` or `put`."),b.forEach((function(e){var t=e.name,r=void 0===t?void 0:t,i=e.file;(0,s.default)(i,"`file` is a required property of `files`."),w.attach("file-upload-"+ ++c,i,r)})));"responseType"in w&&"json"!==p&&w.responseType(p);if("node"===ENV&&(w.use(a.httpProgressMiddleware),y))return new Promise((function(e,t){w.pipe(y).on("finish",e).on("error",t)}));m&&m(w.xhr);return w.then((function(t){if("json"===p){var r=t.body;return function(t){if(_(),e in d)for(;d[e].length;){var r=d[e].shift();(0,(0,n.default)(r,1)[0])(t)}}(r),r}if("text"===p)return t.text})).catch((function(e){var t={result:e.status||500,error:"Network Error"};return _(),Promise.reject(t)}));function _(){e in l&&delete l[e]}};var n=i(r(85715)),o=i(r(15734)),s=i(r(20311)),a=r(27413),l={},d={};var c=1},21272:(e,t,r)=>{"use strict";var i=r(6305),n=r(24994);t.A=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"oauth",r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];(0,o.default)(-1!==["oauth","pcloud"].indexOf(t),"`type` must be either `oauth` or `pcloud`."),"oauth"===t&&((0,o.default)("string"==typeof e,"`token` is required."),(0,o.default)(e.length,"`token` is required."));function i(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=(0,s.default)({},function(r){var i={params:{}};return(0,d.isAuthMethod)(r)&&e&&(i.params["oauth"===t?"access_token":"auth"]=e),i}(r),n);return(0,a.default)(r,o).catch((function(e){return 500===e.result&&apiServer!==c?(apiServer=c,i(r,n)):Promise.reject(e)}))}function n(){return i("getapiserver",{}).then((function(e){return apiServer=e.api[0]}))}function u(t){e=t}var p,h={api:i,setupProxy:n};for(var f in l){if(Object.prototype.hasOwnProperty.call(l,f))"function"==typeof(p=(0,l[f])({client:h,setToken:u,type:t}))&&(h[f]=p)}r&&n();return h};var o=n(r(20311)),s=n(r(73923)),a=n(r(57985)),l=i(r(83666)),d=r(27413),c="api.pcloud.com"},32614:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311)),o={view:0,edit:7};t.default=function(e){var t=e.client,r=e.type;return function(e,i,s){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"view";return(0,n.default)("pcloud"===r,"This method supports only clients of type `pcloud`."),(0,n.default)("number"==typeof e,"`folderid` must be number."),(0,n.default)(0!==e,"`folderid` cannot be 0."),(0,n.default)(-1!=["view","edit"].indexOf(a),"`permissions` can be either `view` or `edit`."),(0,n.default)(i,"`userid` is required."),(0,n.default)("number"==typeof i,"`userid` is required."),(0,n.default)(parseInt(i),"`userid` must be either number or a valid mail address."),(0,n.default)(s,"`clientid` is required"),(0,n.default)("string"==typeof s,"`clientid` is required"),t.api("sharefolder",{params:{folderid:e,permissions:o[a],userid:i,client_id:s}}).then((function(){return!0}))}}},14813:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(47023));t.default=function(){return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return function(e){var r=t.onBegin,i=t.onProgress,o=t.onFinish;return r&&r(),(0,n.default)(e,{type:"arraybuffer",onProgress:function(e){"download"===e.direction&&t.onProgress&&i&&i(e)}}).then((function(e){return t.onFinish&&o&&o(e),e}))}}}},79099:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=function(e){var t=e.client;return function(e,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=t.getfilelink,o=t.download;return n(e).then(o(r,i))}}},62324:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(73738)),o=i(r(20311));t.default=function(e){var t=e.client;return function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};(0,o.default)(e,"`file` is required."),(0,o.default)("object"===(0,n.default)(e),"`file` of type File must be supplied.");var s=i.onBegin,a=i.onProgress,l=i.onFinish;return s&&s(),t.api("uploadfile",{method:"post",params:{folderid:r,nopartial:1},files:[{file:e}],onProgress:function(e){"upload"===e.direction&&a&&a(e)}}).then((function(e){var t=e.metadata,r=e.checksums,i={metadata:t[0],checksums:r[0]};return l&&l(i),i}))}}},58292:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(0,n.default)(e.length,"`name` for is required"),(0,n.default)("string"==typeof e,"`name` is required and be a string."),(0,n.default)("number"==typeof r,"`parentfolderid` is required."),t.api("createfolder",{params:{name:e,folderid:r}}).then((function(e){return e.metadata}))}}},33881:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e){return(0,n.default)("number"==typeof e,"`fileid` must be a number."),(0,n.default)(e,"`fileid` is required."),t.api("deletefile",{params:{fileid:e}}).then((function(){return!0}))}}},65315:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e){return(0,n.default)("number"==typeof e,"`folderid must be a number.`"),(0,n.default)(e,"`folderid` is required and can't be `0`."),t.api("deletefolderrecursive",{params:{folderid:e}}).then((function(){return!0}))}}},30964:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(27413);t.default=function(e){var t=e.client;return function(e){return t.api("getfilelink",{params:{fileid:e,forcedownload:1}}).then((function(e){return(0,i.pCloudUrl)(e)}))}}},84591:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(73738)),o=i(r(20311)),s=i(r(94220));t.default=function(e){var t=e.client;return function(e,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"auto",a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"32x32";(0,o.default)("object"===(0,n.default)(e)&&"length"in e&&e.length,"`fileids` is required, must be array of numbers."),(0,o.default)(-1!==["auto","png","jpg"].indexOf(i),'thumbType must be one of: "auto", "png", "jpg".'),(0,o.default)(-1!==["32x32","120x120"].indexOf(a),'size must be one of: "32x32", "120x120".'),(0,o.default)(r,"`receiveThumb` is required."),(0,o.default)("function"==typeof r,"`receiveThumb` must be a function.");var l=[],d=(0,s.default)();return t.api("getthumbs",{responseType:"text",params:{fileids:e.join(","),type:i,size:a,crop:1},onProgress:function(e){var t=d(e.currentTarget.responseText);l=l.concat(t),t.forEach(r)}}).then((function(e){var t=d(e);return t.forEach(r),l.concat(t)}))}}},83666:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"appshare",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"createfolder",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"deletefile",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"download",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"downloadfile",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"deletefolder",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"getfilelink",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"getthumbs",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"listfolder",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"login",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"movefile",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"movefolder",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"register",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"remoteupload",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"renamefile",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"renamefolder",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"sharefolder",{enumerable:!0,get:function(){return w.default}}),Object.defineProperty(t,"upload",{enumerable:!0,get:function(){return _.default}}),Object.defineProperty(t,"userinfo",{enumerable:!0,get:function(){return x.default}});var n=i(r(32614)),o=i(r(58292)),s=i(r(33881)),a=i(r(14813)),l=i(r(79099)),d=i(r(65315)),c=i(r(30964)),u=i(r(84591)),p=i(r(43956)),h=i(r(28199)),f=i(r(61131)),m=i(r(6173)),g=i(r(86689)),y=i(r(8727)),v=i(r(50004)),b=i(r(91962)),w=i(r(44221)),_=i(r(62324)),x=i(r(59147))},43956:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(43693)),o=i(r(20311));function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,i)}return r}function a(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1?arguments[1]:void 0;return(0,o.default)("number"==typeof e,"`folderid` must be a number."),t.api("listfolder",{params:a({folderid:e},r)}).then((function(e){return e.metadata}))}}},28199:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311)),o=r(27413);t.default=function(e){var t=e.client,r=e.setToken;return function(e,i){return(0,n.default)("string"==typeof e&&(0,o.isEmail)(e),"`email` must be provided."),(0,n.default)(i,"`password` is required."),(0,n.default)(i.length,"`password` is required."),t.api("userinfo",{params:{username:e,password:i,getauth:1,logout:1}}).then((function(e){var t=e.auth;return r(t),t}))}}},61131:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e,r){return(0,n.default)("number"==typeof e,"`fileid` must be number."),(0,n.default)(0!==e,"`fileid` cannot be 0."),(0,n.default)(r,"`tofolderid` is required."),t.api("renamefile",{params:{fileid:e,tofolderid:r}}).then((function(e){return e.metadata}))}}},6173:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e,r){return(0,n.default)("number"==typeof e,"`folderid` must be number."),(0,n.default)(0!==e,"`folderid` cannot be 0."),(0,n.default)(r,"`tofolderid` is required."),t.api("renamefolder",{params:{folderid:e,tofolderid:r}}).then((function(e){return e.metadata}))}}},86689:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311)),o=r(27413);t.default=function(e){var t=e.client;return function(e,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};(0,n.default)("string"==typeof e&&(0,o.isEmail)(e),"`email` must be provided."),(0,n.default)(r,"`password` is required."),(0,n.default)(r.length,"`password` is required.");var s={mail:e,password:r,getauth:1,logout:1,termsaccepted:"yes"};return i.invite&&(s.invite=i.invite),i.ref&&(s.ref=i.ref),"web"===ENV&&(s.os=4,s.device=navigator.userAgent),t.api("register",{params:s}).then((function(e){return e.userid}))}}},8727:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311)),o=r(27413);t.default=function(e){var t=e.client;return function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};(0,n.default)(e,"`file` is required."),(0,n.default)("string"==typeof e,"`file` must be supplied");var a,l=i.onBegin,d=i.onProgress,c=i.onFinish,u="pcloud-sdk-remote-"+(0,o.uniqueNumber)()+"-"+(0,o.randomNumber)(),p=function e(t){f(t),a=setTimeout((function(){return e(t)}),200)},h=function(){a&&clearTimeout(a)},f=function(e){t.api("uploadprogress",{params:{progresshash:u,apiServer:e}}).then((function(e){var t=e.files;return d&&d(s(t))})).catch((function(e){var t=e.result,r=e.error;1900===t&&d&&d(s()),console.log(r)}))};return l&&l(),t.api("currentserver").then((function(i){var n=i.hostname,o=t.api("downloadfile",{method:"post",params:{folderid:r,progresshash:u,nopartial:1,url:e,apiServer:n}});return p(n),o})).then((function(e){var t=e.metadata;return h(),c&&c({metadata:t[0]}),{metadata:t[0]}})).catch((function(e){h(),console.log("Error",e)}))}};var s=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return{all:{downloaded:e.reduce((function(e,t){var r=t.downloaded;return e+(void 0===r?0:r)}),0),size:e.reduce((function(e,t){var r=t.size;return e+(void 0===r?0:r)}),0)},files:e}}},50004:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e,r){return(0,n.default)("number"==typeof e,"`fileid` must be number."),(0,n.default)(0!==e,"`fileid` cannot be 0."),(0,n.default)(r,"`toname` is required."),(0,n.default)(r.length,"`toname` is required."),t.api("renamefile",{params:{fileid:e,toname:r}}).then((function(e){return e.metadata}))}}},91962:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311));t.default=function(e){var t=e.client;return function(e,r){return(0,n.default)("number"==typeof e,"`folderid` must be number."),(0,n.default)(0!==e,"`folderid` cannot be 0."),(0,n.default)(r,"`toname` is required."),(0,n.default)(r.length,"`toname` is required."),t.api("renamefolder",{params:{folderid:e,toname:r}}).then((function(e){return e.metadata}))}}},44221:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(r(20311)),o=r(27413),s={view:0,edit:7};t.default=function(e){var t=e.client;return function(e,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"view",a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;(0,n.default)("number"==typeof e,"`folderid` must be number."),(0,n.default)(0!==e,"`folderid` cannot be 0."),(0,n.default)(-1!=["view","edit"].indexOf(i),"`permissions` can be either `view` or `edit`."),(0,n.default)(r,"`mail` is required."),(0,n.default)("string"==typeof r,"`mail` is required."),(0,n.default)((0,o.isEmail)(r),"`mail` must be either number or a valid mail address.");var l={};return l.folderid=e,l.permissions=s[i],l.mail=r,a&&(l.message=a),t.api("sharefolder",{params:l}).then((function(){return!0}))}}},59147:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=function(e){var t=e.client;return function(){return t.api("userinfo")}}},83679:(e,t,r)=>{"use strict";r.g.ENV="web"},85403:(e,t,r)=>{"use strict";r(83679),e.exports={createClient:r(21272).A,oauth:r(16019).A,ApiMethod:r(57985).default,ApiRequest:r(57985).default}},16019:(e,t,r)=>{"use strict";var i=r(24994);t.A=void 0;var n=i(r(88835)),o=i(r(20311)),s=i(r(57985)),a=r(52768);function l(e){return n.default.format({protocol:"https",hostname:"my.pcloud.com",pathname:"/oauth2/authorize",query:e})}var d={initOauthToken:function(e){var t=e.client_id,r=void 0===t?null:t,i=e.redirect_uri,n=void 0===i?null:i,s=e.receiveToken,a=void 0===s?null:s,d=e.response_type,c=void 0===d?"token":d;(0,o.default)(r,"`client_id` is required."),(0,o.default)(n,"`redirect_uri` is required."),(0,o.default)(a,"`receiveToken` is required.");var u=l({redirect_uri:n,client_id:r,response_type:c});window.open(u,"oauth","width=680,height=700"),window.__setPcloudToken=function(e,t){a(e,t),delete window.__setPcloudToken}},initOauthPollToken:function(e){var t=(0,a.generateRandomString)(40),r=e.client_id,i=void 0===r?null:r,n=e.receiveToken,d=void 0===n?null:n,c=e.onError,u=void 0===c?null:c;(0,o.default)(i,"`client_id` is required."),(0,o.default)(d,"`receiveToken` is required."),(0,o.default)(u,"`onError` is required.");var p=l({request_id:t,client_id:i,response_type:"poll_token"});window.open(p,"","width=680,height=700"),(0,s.default)("oauth2_token",{apiServer:"eapi.pcloud.com",params:{client_id:i,request_id:t}}).then((function(e){d(e.access_token,e.locationid)})).catch((function(e){u(e)})),(0,s.default)("oauth2_token",{apiServer:"api.pcloud.com",params:{client_id:i,request_id:t}}).then((function(e){d(e.access_token,e.locationid)})).catch((function(e){u(e)}))},popup:function(){var e=location.hash.match(/access_token=([^&]+)/),t=location.search.match(/code=([^&]+)/),r=location.hash.match(/locationid=([^&]+)/),i=r?r[1]:null,n=e?e[1]:t?t[1]:null;n&&(window.opener.__setPcloudToken(n,i),window.close())},getTokenFromCode:function(e,t,r){return(0,s.default)("oauth2_token",{params:{client_id:t,client_secret:r,code:e}})}};t.A=d},52768:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isEmail=function(e){return/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(\s".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(e)},t.fileext=function(e){return e.split(".").pop()},t.formatSize=function(e,t){void 0===t&&(t=1);return(e=parseInt(e,10))>=1099511627776?(e/1099511627776).toFixed(t)+" Tb":e>=1073741824?(e/1073741824).toFixed(t)+" Gb":e>=1048576?(e/1048576).toFixed(t)+" Mb":e>=1024?(e/1024).toFixed(t)+" Kb":e.toFixed(t)+" B"},t.uniqueNumber=function(){return++r},t.randomNumber=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10;return Math.random()*(10<{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=0,r=0;e.on("response",(function(i){0===r&&(r=i.headers["content-length"]),i.on("data",(function(i){t+=i.length,e.emit("progress",{direction:"download",loaded:t,total:r})}))}))}},27413:(e,t,r)=>{"use strict";var i=r(24994);Object.defineProperty(t,"__esModule",{value:!0});var n={httpProgressMiddleware:!0};Object.defineProperty(t,"httpProgressMiddleware",{enumerable:!0,get:function(){return s.default}});var o=r(52768);Object.keys(o).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(n,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}}))}));var s=i(r(17898)),a=r(66719);Object.keys(a).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(n,e)||Object.defineProperty(t,e,{enumerable:!0,get:function(){return a[e]}}))}))},66719:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isApiMethod=i,t.isAuthMethod=n,t.isOAuthMethod=function(e){return n(e)&&"oauth"in r[e]},t.pCloudApiMethods=void 0;var r={oauth2_token:{auth:!1,type:"write"},register:{auth:!1,type:"write"},listfolder:{auth:!0,type:"read"},createfolder:{auth:!0,type:"write"},userinfo:{auth:!0,type:"read"},currentserver:{auth:!1,type:"read"},uploadfile:{auth:!0,type:"write"},getfilelink:{auth:!0,type:"read"},getapiserver:{auth:!1,type:"read"},renamefolder:{auth:!0,type:"write"},deletefile:{auth:!0,type:"write"},deletefolderrecursive:{auth:!0,type:"write"},logout:{auth:!0,type:"write"},createfolderifnotexists:{auth:!0,type:"write"},getthumblink:{auth:!0,type:"read"},getvideolink:{auth:!0,type:"read"},getaudiolink:{auth:!0,type:"read"},deletefolder:{auth:!0,type:"write"},diff:{auth:!0,type:"write"},subscribe:{auth:!0,type:"write"},listnotifications:{auth:!0,type:"write"},readnotifications:{auth:!0,type:"write"},listshares:{auth:!0,type:"read"},acceptshare:{auth:!0,type:"write"},declineshare:{auth:!0,type:"write"},removeshare:{auth:!0,type:"write"},cancelsharerequest:{auth:!0,type:"write"},changeshare:{auth:!0,type:"write"},sharefolder:{auth:!0,type:"write"},copyfile:{auth:!0,type:"write"},checksumfile:{auth:!0,type:"read"},copyfolder:{auth:!0,type:"write"},listpublinks:{auth:!0,type:"read"},getfilepublink:{auth:!0,type:"write"},getfolderpublink:{auth:!0,type:"write"},gettreepublink:{auth:!0,type:"write"},deletepublink:{auth:!0,type:"write"},changepublink:{auth:!0,type:"write"},copypubfile:{auth:!0,type:"write"},renamefile:{auth:!0,type:"write"},showpublink:{auth:!1,type:"read"},getzip:{auth:!0,type:"write"},getziplink:{auth:!0,type:"write"},createuploadlink:{auth:!0,type:"write"},listuploadlinks:{auth:!0,type:"read"},deleteuploadlink:{auth:!0,type:"write"},changeuploadlink:{auth:!0,type:"write"},uploadlinkprogress:{auth:!0,type:"read"},downloadfile:{auth:!0,type:"write"},lostpassword:{auth:!1,type:"write"},resetpassword:{auth:!1,type:"write"},changepassword:{auth:!0,type:"write"},verifyemail:{auth:!1,type:"write"},sharerequestinfo:{auth:!1,type:"read"},sendverificationemail:{auth:!0,type:"write"},getthumbslinks:{auth:!0,type:"read"},getthumbs:{auth:!0,type:"read"},uploadprogress:{auth:!0,type:"write"},invite:{auth:!0,type:"write"},fb_assign:{auth:!0,type:"write"},userbonuses:{auth:!0,type:"write"},givebonus:{auth:!0,type:"write"},userinvites:{auth:!0,type:"write"},getvideolinks:{auth:!0,type:"read"},backup_modify:{auth:!0,type:"write"},backup_list:{auth:!0,type:"read"},social_assign:{auth:!0,type:"write"},extractarchive:{auth:!0,type:"write"},extractarchiveprogress:{auth:!0,type:"write"},listrevisions:{auth:!0,type:"read"},revertrevision:{auth:!0,type:"write"},supportedlanguages:{auth:!0,type:"read"},newsletter_check:{auth:!0,type:"read"},blockchain_address:{auth:!0,type:"read"},trash_list:{auth:!0,type:"read"},trash_clear:{auth:!0,type:"write"},trash_restore:{auth:!0,type:"write"},trash_getrestorepath:{auth:!0,type:"write"},collection_list:{auth:!0,type:"read"},collection_details:{auth:!0,type:"read"},collection_create:{auth:!0,type:"write"},collection_rename:{auth:!0,type:"write"},collection_delete:{auth:!0,type:"write"},collection_linkfiles:{auth:!0,type:"write"},collection_unlinkfiles:{auth:!0,type:"write"},collection_move:{auth:!0,type:"write"},app_userlist:{auth:!0,type:"read"},app_userdelete:{auth:!0,type:"write"},gettextfile:{auth:!0,type:"write"},getpubtextfile:{auth:!1,type:"write"},account_teams:{auth:!0,type:"read"},account_teamcreate:{auth:!0,type:"read"},account_info:{auth:!0,type:"read"},account_modify:{auth:!0,type:"write"},account_users:{auth:!0,type:"read"},account_invitemail:{auth:!0,type:"read"},account_usermodify:{auth:!0,type:"write"},account_teammodify:{auth:!0,type:"write"},account_teamlink:{auth:!0,type:"write"},account_billinginfo:{auth:!0,type:"read"},account_invoice_modify:{auth:!0,type:"write"},account_upload_avatar:{auth:!0,type:"write"},account_teamunlink:{auth:!0,type:"write"},account_teamlink_head:{auth:!0,type:"write"},account_teamlink_accept:{auth:!0,type:"write"},account_invitelist:{auth:!0,type:"read"},account_invalidate_password:{auth:!0,type:"write"},account_invitecancel:{auth:!0,type:"write"},commentlist:{auth:!0,type:"read"},commentpost:{auth:!0,type:"write"},commentdelete:{auth:!0,type:"write"},eventsubscribe:{auth:!0,type:"write"},account_teamshare:{auth:!0,type:"write"},account_modifyshare:{auth:!0,type:"write"},account_stopshare:{auth:!0,type:"write"},account_listshares:{auth:!0,type:"read"},account_log:{auth:!0,type:"read"},account_paystripe:{auth:!0,type:"read"},listtokens:{auth:!0,type:"read"},deletetoken:{auth:!0,type:"write"},savezip:{auth:!0,type:"write"},savezipprogress:{auth:!0,type:"write"},contactload:{auth:!0,type:"write"},sendpublink:{auth:!0,type:"write"},contactlist:{auth:!0,type:"read"},account_viewtoken:{auth:!0,type:"write"},eventslast:{auth:!0,type:"write"},search:{auth:!0,type:"read"},issueproforma:{auth:!0,type:"write"},listproforma:{auth:!0,type:"write"},getbreadcrumb:{auth:!0,type:"read"},getpreviewlink:{auth:!0,type:"read"},getpublinkpreviewdownload:{type:"read",auth:!1},setlanguage:{auth:!0,type:"write"},account_branding:{auth:!0,type:"read"},account_branding_set:{auth:!0,type:"write"},account_branding_logo_upload:{auth:!0,type:"write"},account_logintoken:{auth:!0,type:"write"},getpublinkstats:{auth:!0,type:"read"},getpublinkadpreference:{auth:!0,type:"read"},setpublinkadpreference:{auth:!0,type:"write"},account_ispublinktrafficlimited:{auth:!0,type:"read"},getreferrallink:{auth:!0,type:"read"},sendreferrallink:{auth:!0,type:"write"},listpaymentsubscriptions:{auth:!0,type:"read"},getip:{auth:!1,type:"read"},crypto_getuserkeys:{auth:!0,type:"read"},crypto_getfolderkey:{auth:!0,type:"read"},crypto_getfilekey:{auth:!0,type:"read"},crypto_reset:{auth:!0,type:"write"},crypto_setuserkeys:{auth:!0,type:"write"},crypto_getuserhint:{auth:!0,type:"write"},upload_create:{auth:!0,type:"write"},upload_write:{auth:!0,type:"write"},upload_save:{auth:!0,type:"write"},crypto_getroot:{auth:!0,type:"read"},crypto_getfolderskey:{auth:!0,type:"read"},stat:{auth:!0,type:"read"}};function i(e){return e in r}function n(e){return i(e)&&r[e].auth}t.pCloudApiMethods=r},94220:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e,t=0,s=[];return function(a){for(var l,d,c=[];-1!==(e=a.indexOf("\n",t+1));){var u=(l=a.substr(t,e-t),d=void 0,d=l.split("|"),{result:parseInt(d[i],10),url:o in d?d[o].trim():"",fileid:parseInt(d[r],10),size:d[n]}),p=u.result,h=u.url,f=u.fileid;if(t=e,6001===p&&(h=s[parseInt(u.size,10)].url,p=0),0===p){var m={url:h,fileid:f};s.push(m),c.push(m)}}return c}},t.THUMB_URL=t.THUMB_LINEID=t.THUMB_SIZE=t.THUMB_RESULT=t.THUMB_FILEID=void 0;var r=0;t.THUMB_FILEID=r;var i=1;t.THUMB_RESULT=i;var n=2;t.THUMB_SIZE=n;t.THUMB_LINEID=2;var o=3;t.THUMB_URL=o},80819:e=>{e.exports={pad:function(e,t){var r=e;if("number"!=typeof t)t=16;else{if(t>255)throw new RangeError("pad(): PKCS#7 padding cannot be longer than 255 bytes");if(t<0)throw new RangeError("pad(): PKCS#7 padding size must be positive")}if("string"==typeof e){var i=t-e.length%t;isNaN(i)&&(i=0);for(var n=String.fromCharCode(i),o=0;o0){var r=e.charCodeAt(e.length-1);if(r>e.length)throw new Error("unpad(): cannot remove "+r+" bytes from a "+e.length+"-byte(s) string");for(var i=e.length-2,n=e.length-r;i>=n;i--)if(e.charCodeAt(i)!==r)throw new Error("unpad(): found a padding byte of "+e.charCodeAt(i)+" instead of "+r+" at position "+i);t=e.substring(0,n)}else if(e instanceof Uint8Array||e instanceof Uint8ClampedArray){var o=e.byteLength,s=o-(r=e[o-1]);if(s<0)throw new Error("unpad(): cannot remove "+r+" bytes from a "+o+"-byte(s) string");for(i=o-2;i>=s;i--)if(e[i]!==r)throw new Error("unpad(): found a padding byte of "+e[i]+" instead of "+r+" at position "+i);t=e.slice(0,s)}return t}}},76578:e=>{"use strict";e.exports=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]},33225:(e,t,r)=>{"use strict";var i=r(65606);void 0===i||!i.version||0===i.version.indexOf("v0.")||0===i.version.indexOf("v1.")&&0!==i.version.indexOf("v1.8.")?e.exports={nextTick:function(e,t,r,n){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var o,s,a=arguments.length;switch(a){case 0:case 1:return i.nextTick(e);case 2:return i.nextTick((function(){e.call(null,t)}));case 3:return i.nextTick((function(){e.call(null,t,r)}));case 4:return i.nextTick((function(){e.call(null,t,r,n)}));default:for(o=new Array(a-1),s=0;s{var t,r,i=e.exports={};function n(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(e){if(t===setTimeout)return setTimeout(e,0);if((t===n||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:n}catch(e){t=n}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var a,l=[],d=!1,c=-1;function u(){d&&a&&(d=!1,a.length?l=a.concat(l):c=-1,l.length&&p())}function p(){if(!d){var e=s(u);d=!0;for(var t=l.length;t;){for(a=l,l=[];++c1)for(var r=1;r{t.publicEncrypt=r(28902),t.privateDecrypt=r(77362),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},48206:(e,t,r)=>{var i=r(47108),n=r(92861).Buffer;function o(e){var t=n.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,s=n.alloc(0),a=0;s.length=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function l(e,t,r){var i=a(e,r);return r-1>=t&&(i|=a(e,r-1)<<4),i}function d(e,t,r,i){for(var n=0,o=Math.min(e.length,r),s=t;s=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),i(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n=0;n-=3)s=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[o]|=s<>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var i=0;i=t;i-=2)n=l(e,t,i)<=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(e.length-t)%2==0?t+1:t;i=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=t)i++;i--,n=n/t|0;for(var o=e.length-r,s=o%i,a=Math.min(o,o-s)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var c=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],u=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function h(e,t,r){r.negative=t.negative^e.negative;var i=e.length+t.length|0;r.length=i,i=i-1|0;var n=0|e.words[0],o=0|t.words[0],s=n*o,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var d=1;d>>26,u=67108863&l,p=Math.min(d,t.length-1),h=Math.max(0,d-e.length+1);h<=p;h++){var f=d-h|0;c+=(s=(n=0|e.words[f])*(o=0|t.words[h])+u)/67108864|0,u=67108863&s}r.words[d]=0|u,l=0|c}return 0!==l?r.words[d]=0|l:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,o=0,s=0;s>>24-n&16777215)||s!==this.length-1?c[6-l.length]+l+r:l+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=u[e],h=p[e];r="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modn(h).toString(e);r=(f=f.idivn(h)).isZero()?m+r:c[d-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return i(void 0!==s),this.toArrayLike(s,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,l="le"===t,d=new e(o),c=this.clone();if(l){for(a=0;!c.isZero();a++)s=c.andln(255),c.iushrn(8),d[a]=s;for(;a=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 8191&t||(r+=13,t>>>=13),127&t||(r+=7,t>>>=7),15&t||(r+=4,t>>>=4),3&t||(r+=2,t>>>=2),1&t||r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var i=0;ie.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){i("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){i("number"==typeof e&&e>=0);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,i=e):(r=e,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,i,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=e):(r=e,i=this);for(var o=0,s=0;s>26,this.words[s]=67108863&t;for(;0!==o&&s>26,this.words[s]=67108863&t;if(0===o&&s>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,v=g>>>13,b=0|s[3],w=8191&b,_=b>>>13,x=0|s[4],S=8191&x,k=x>>>13,E=0|s[5],T=8191&E,B=E>>>13,C=0|s[6],I=8191&C,A=C>>>13,F=0|s[7],M=8191&F,D=F>>>13,R=0|s[8],P=8191&R,O=R>>>13,z=0|s[9],N=8191&z,q=z>>>13,U=0|a[0],L=8191&U,j=U>>>13,H=0|a[1],$=8191&H,G=H>>>13,W=0|a[2],K=8191&W,V=W>>>13,J=0|a[3],Y=8191&J,Q=J>>>13,Z=0|a[4],X=8191&Z,ee=Z>>>13,te=0|a[5],re=8191&te,ie=te>>>13,ne=0|a[6],oe=8191&ne,se=ne>>>13,ae=0|a[7],le=8191&ae,de=ae>>>13,ce=0|a[8],ue=8191&ce,pe=ce>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(d+(i=Math.imul(u,L))|0)+((8191&(n=(n=Math.imul(u,j))+Math.imul(p,L)|0))<<13)|0;d=((o=Math.imul(p,j))+(n>>>13)|0)+(ge>>>26)|0,ge&=67108863,i=Math.imul(f,L),n=(n=Math.imul(f,j))+Math.imul(m,L)|0,o=Math.imul(m,j);var ye=(d+(i=i+Math.imul(u,$)|0)|0)+((8191&(n=(n=n+Math.imul(u,G)|0)+Math.imul(p,$)|0))<<13)|0;d=((o=o+Math.imul(p,G)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,i=Math.imul(y,L),n=(n=Math.imul(y,j))+Math.imul(v,L)|0,o=Math.imul(v,j),i=i+Math.imul(f,$)|0,n=(n=n+Math.imul(f,G)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,G)|0;var ve=(d+(i=i+Math.imul(u,K)|0)|0)+((8191&(n=(n=n+Math.imul(u,V)|0)+Math.imul(p,K)|0))<<13)|0;d=((o=o+Math.imul(p,V)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,i=Math.imul(w,L),n=(n=Math.imul(w,j))+Math.imul(_,L)|0,o=Math.imul(_,j),i=i+Math.imul(y,$)|0,n=(n=n+Math.imul(y,G)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(f,K)|0,n=(n=n+Math.imul(f,V)|0)+Math.imul(m,K)|0,o=o+Math.imul(m,V)|0;var be=(d+(i=i+Math.imul(u,Y)|0)|0)+((8191&(n=(n=n+Math.imul(u,Q)|0)+Math.imul(p,Y)|0))<<13)|0;d=((o=o+Math.imul(p,Q)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,i=Math.imul(S,L),n=(n=Math.imul(S,j))+Math.imul(k,L)|0,o=Math.imul(k,j),i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(y,K)|0,n=(n=n+Math.imul(y,V)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,V)|0,i=i+Math.imul(f,Y)|0,n=(n=n+Math.imul(f,Q)|0)+Math.imul(m,Y)|0,o=o+Math.imul(m,Q)|0;var we=(d+(i=i+Math.imul(u,X)|0)|0)+((8191&(n=(n=n+Math.imul(u,ee)|0)+Math.imul(p,X)|0))<<13)|0;d=((o=o+Math.imul(p,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,i=Math.imul(T,L),n=(n=Math.imul(T,j))+Math.imul(B,L)|0,o=Math.imul(B,j),i=i+Math.imul(S,$)|0,n=(n=n+Math.imul(S,G)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(w,K)|0,n=(n=n+Math.imul(w,V)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,V)|0,i=i+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,Q)|0)+Math.imul(v,Y)|0,o=o+Math.imul(v,Q)|0,i=i+Math.imul(f,X)|0,n=(n=n+Math.imul(f,ee)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,ee)|0;var _e=(d+(i=i+Math.imul(u,re)|0)|0)+((8191&(n=(n=n+Math.imul(u,ie)|0)+Math.imul(p,re)|0))<<13)|0;d=((o=o+Math.imul(p,ie)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,i=Math.imul(I,L),n=(n=Math.imul(I,j))+Math.imul(A,L)|0,o=Math.imul(A,j),i=i+Math.imul(T,$)|0,n=(n=n+Math.imul(T,G)|0)+Math.imul(B,$)|0,o=o+Math.imul(B,G)|0,i=i+Math.imul(S,K)|0,n=(n=n+Math.imul(S,V)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,V)|0,i=i+Math.imul(w,Y)|0,n=(n=n+Math.imul(w,Q)|0)+Math.imul(_,Y)|0,o=o+Math.imul(_,Q)|0,i=i+Math.imul(y,X)|0,n=(n=n+Math.imul(y,ee)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,ee)|0,i=i+Math.imul(f,re)|0,n=(n=n+Math.imul(f,ie)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ie)|0;var xe=(d+(i=i+Math.imul(u,oe)|0)|0)+((8191&(n=(n=n+Math.imul(u,se)|0)+Math.imul(p,oe)|0))<<13)|0;d=((o=o+Math.imul(p,se)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,i=Math.imul(M,L),n=(n=Math.imul(M,j))+Math.imul(D,L)|0,o=Math.imul(D,j),i=i+Math.imul(I,$)|0,n=(n=n+Math.imul(I,G)|0)+Math.imul(A,$)|0,o=o+Math.imul(A,G)|0,i=i+Math.imul(T,K)|0,n=(n=n+Math.imul(T,V)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,V)|0,i=i+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,Q)|0)+Math.imul(k,Y)|0,o=o+Math.imul(k,Q)|0,i=i+Math.imul(w,X)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,ee)|0,i=i+Math.imul(y,re)|0,n=(n=n+Math.imul(y,ie)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ie)|0,i=i+Math.imul(f,oe)|0,n=(n=n+Math.imul(f,se)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,se)|0;var Se=(d+(i=i+Math.imul(u,le)|0)|0)+((8191&(n=(n=n+Math.imul(u,de)|0)+Math.imul(p,le)|0))<<13)|0;d=((o=o+Math.imul(p,de)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,i=Math.imul(P,L),n=(n=Math.imul(P,j))+Math.imul(O,L)|0,o=Math.imul(O,j),i=i+Math.imul(M,$)|0,n=(n=n+Math.imul(M,G)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(I,K)|0,n=(n=n+Math.imul(I,V)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,V)|0,i=i+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,Q)|0)+Math.imul(B,Y)|0,o=o+Math.imul(B,Q)|0,i=i+Math.imul(S,X)|0,n=(n=n+Math.imul(S,ee)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,ee)|0,i=i+Math.imul(w,re)|0,n=(n=n+Math.imul(w,ie)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ie)|0,i=i+Math.imul(y,oe)|0,n=(n=n+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,i=i+Math.imul(f,le)|0,n=(n=n+Math.imul(f,de)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,de)|0;var ke=(d+(i=i+Math.imul(u,ue)|0)|0)+((8191&(n=(n=n+Math.imul(u,pe)|0)+Math.imul(p,ue)|0))<<13)|0;d=((o=o+Math.imul(p,pe)|0)+(n>>>13)|0)+(ke>>>26)|0,ke&=67108863,i=Math.imul(N,L),n=(n=Math.imul(N,j))+Math.imul(q,L)|0,o=Math.imul(q,j),i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(O,$)|0,o=o+Math.imul(O,G)|0,i=i+Math.imul(M,K)|0,n=(n=n+Math.imul(M,V)|0)+Math.imul(D,K)|0,o=o+Math.imul(D,V)|0,i=i+Math.imul(I,Y)|0,n=(n=n+Math.imul(I,Q)|0)+Math.imul(A,Y)|0,o=o+Math.imul(A,Q)|0,i=i+Math.imul(T,X)|0,n=(n=n+Math.imul(T,ee)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,ee)|0,i=i+Math.imul(S,re)|0,n=(n=n+Math.imul(S,ie)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ie)|0,i=i+Math.imul(w,oe)|0,n=(n=n+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,i=i+Math.imul(y,le)|0,n=(n=n+Math.imul(y,de)|0)+Math.imul(v,le)|0,o=o+Math.imul(v,de)|0,i=i+Math.imul(f,ue)|0,n=(n=n+Math.imul(f,pe)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,pe)|0;var Ee=(d+(i=i+Math.imul(u,fe)|0)|0)+((8191&(n=(n=n+Math.imul(u,me)|0)+Math.imul(p,fe)|0))<<13)|0;d=((o=o+Math.imul(p,me)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,i=Math.imul(N,$),n=(n=Math.imul(N,G))+Math.imul(q,$)|0,o=Math.imul(q,G),i=i+Math.imul(P,K)|0,n=(n=n+Math.imul(P,V)|0)+Math.imul(O,K)|0,o=o+Math.imul(O,V)|0,i=i+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,Q)|0)+Math.imul(D,Y)|0,o=o+Math.imul(D,Q)|0,i=i+Math.imul(I,X)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,ee)|0,i=i+Math.imul(T,re)|0,n=(n=n+Math.imul(T,ie)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ie)|0,i=i+Math.imul(S,oe)|0,n=(n=n+Math.imul(S,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,i=i+Math.imul(w,le)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(_,le)|0,o=o+Math.imul(_,de)|0,i=i+Math.imul(y,ue)|0,n=(n=n+Math.imul(y,pe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,pe)|0;var Te=(d+(i=i+Math.imul(f,fe)|0)|0)+((8191&(n=(n=n+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;d=((o=o+Math.imul(m,me)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,i=Math.imul(N,K),n=(n=Math.imul(N,V))+Math.imul(q,K)|0,o=Math.imul(q,V),i=i+Math.imul(P,Y)|0,n=(n=n+Math.imul(P,Q)|0)+Math.imul(O,Y)|0,o=o+Math.imul(O,Q)|0,i=i+Math.imul(M,X)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(D,X)|0,o=o+Math.imul(D,ee)|0,i=i+Math.imul(I,re)|0,n=(n=n+Math.imul(I,ie)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ie)|0,i=i+Math.imul(T,oe)|0,n=(n=n+Math.imul(T,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,i=i+Math.imul(S,le)|0,n=(n=n+Math.imul(S,de)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,de)|0,i=i+Math.imul(w,ue)|0,n=(n=n+Math.imul(w,pe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,pe)|0;var Be=(d+(i=i+Math.imul(y,fe)|0)|0)+((8191&(n=(n=n+Math.imul(y,me)|0)+Math.imul(v,fe)|0))<<13)|0;d=((o=o+Math.imul(v,me)|0)+(n>>>13)|0)+(Be>>>26)|0,Be&=67108863,i=Math.imul(N,Y),n=(n=Math.imul(N,Q))+Math.imul(q,Y)|0,o=Math.imul(q,Q),i=i+Math.imul(P,X)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,ee)|0,i=i+Math.imul(M,re)|0,n=(n=n+Math.imul(M,ie)|0)+Math.imul(D,re)|0,o=o+Math.imul(D,ie)|0,i=i+Math.imul(I,oe)|0,n=(n=n+Math.imul(I,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,i=i+Math.imul(T,le)|0,n=(n=n+Math.imul(T,de)|0)+Math.imul(B,le)|0,o=o+Math.imul(B,de)|0,i=i+Math.imul(S,ue)|0,n=(n=n+Math.imul(S,pe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,pe)|0;var Ce=(d+(i=i+Math.imul(w,fe)|0)|0)+((8191&(n=(n=n+Math.imul(w,me)|0)+Math.imul(_,fe)|0))<<13)|0;d=((o=o+Math.imul(_,me)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,i=Math.imul(N,X),n=(n=Math.imul(N,ee))+Math.imul(q,X)|0,o=Math.imul(q,ee),i=i+Math.imul(P,re)|0,n=(n=n+Math.imul(P,ie)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ie)|0,i=i+Math.imul(M,oe)|0,n=(n=n+Math.imul(M,se)|0)+Math.imul(D,oe)|0,o=o+Math.imul(D,se)|0,i=i+Math.imul(I,le)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,de)|0,i=i+Math.imul(T,ue)|0,n=(n=n+Math.imul(T,pe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,pe)|0;var Ie=(d+(i=i+Math.imul(S,fe)|0)|0)+((8191&(n=(n=n+Math.imul(S,me)|0)+Math.imul(k,fe)|0))<<13)|0;d=((o=o+Math.imul(k,me)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,i=Math.imul(N,re),n=(n=Math.imul(N,ie))+Math.imul(q,re)|0,o=Math.imul(q,ie),i=i+Math.imul(P,oe)|0,n=(n=n+Math.imul(P,se)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,se)|0,i=i+Math.imul(M,le)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(D,le)|0,o=o+Math.imul(D,de)|0,i=i+Math.imul(I,ue)|0,n=(n=n+Math.imul(I,pe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,pe)|0;var Ae=(d+(i=i+Math.imul(T,fe)|0)|0)+((8191&(n=(n=n+Math.imul(T,me)|0)+Math.imul(B,fe)|0))<<13)|0;d=((o=o+Math.imul(B,me)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,i=Math.imul(N,oe),n=(n=Math.imul(N,se))+Math.imul(q,oe)|0,o=Math.imul(q,se),i=i+Math.imul(P,le)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(O,le)|0,o=o+Math.imul(O,de)|0,i=i+Math.imul(M,ue)|0,n=(n=n+Math.imul(M,pe)|0)+Math.imul(D,ue)|0,o=o+Math.imul(D,pe)|0;var Fe=(d+(i=i+Math.imul(I,fe)|0)|0)+((8191&(n=(n=n+Math.imul(I,me)|0)+Math.imul(A,fe)|0))<<13)|0;d=((o=o+Math.imul(A,me)|0)+(n>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,i=Math.imul(N,le),n=(n=Math.imul(N,de))+Math.imul(q,le)|0,o=Math.imul(q,de),i=i+Math.imul(P,ue)|0,n=(n=n+Math.imul(P,pe)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,pe)|0;var Me=(d+(i=i+Math.imul(M,fe)|0)|0)+((8191&(n=(n=n+Math.imul(M,me)|0)+Math.imul(D,fe)|0))<<13)|0;d=((o=o+Math.imul(D,me)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,i=Math.imul(N,ue),n=(n=Math.imul(N,pe))+Math.imul(q,ue)|0,o=Math.imul(q,pe);var De=(d+(i=i+Math.imul(P,fe)|0)|0)+((8191&(n=(n=n+Math.imul(P,me)|0)+Math.imul(O,fe)|0))<<13)|0;d=((o=o+Math.imul(O,me)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863;var Re=(d+(i=Math.imul(N,fe))|0)+((8191&(n=(n=Math.imul(N,me))+Math.imul(q,fe)|0))<<13)|0;return d=((o=Math.imul(q,me))+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,l[0]=ge,l[1]=ye,l[2]=ve,l[3]=be,l[4]=we,l[5]=_e,l[6]=xe,l[7]=Se,l[8]=ke,l[9]=Ee,l[10]=Te,l[11]=Be,l[12]=Ce,l[13]=Ie,l[14]=Ae,l[15]=Fe,l[16]=Me,l[17]=De,l[18]=Re,0!==d&&(l[19]=d,r.length++),r};function m(e,t,r){return(new g).mulp(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(f=h),o.prototype.mulTo=function(e,t){var r,i=this.length+e.length;return r=10===this.length&&10===e.length?f(this,e,t):i<63?h(this,e,t):i<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,e,t):m(this,e,t),r},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,i=0;i>=1;return i},g.prototype.permute=function(e,t,r,i,n,o){for(var s=0;s>>=1)n++;return 1<>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*t;s>=26,t+=n/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>n}return t}(e);if(0===t.length)return new o(1);for(var r=this,i=0;i=0);var t,r=e%26,n=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(t=0;t>>26-r}s&&(this.words[t]=s,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t=0),n=t?(t-t%26)/26:0;var o=e%26,s=Math.min((e-o)/26,this.length),a=67108863^67108863>>>o<s)for(this.length-=s,d=0;d=0&&(0!==c||d>=n);d--){var u=0|this.words[d];this.words[d]=c<<26-o|u>>>o,c=u&a}return l&&0!==c&&(l.words[l.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return i(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){i("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,n=1<=0);var t=e%26,r=(e-t)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(i("number"==typeof e),i(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t>26)-(l/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),i=this.clone(),n=e,s=0|n.words[n.length-1];0!==(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,l=i.length-n.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var d=0;d=0;u--){var p=67108864*(0|i.words[n.length+u])+(0|i.words[n.length+u-1]);for(p=Math.min(p/s|0,67108863),i._ishlnsubmul(n,p,u);0!==i.negative;)p--,i.negative=0,i._ishlnsubmul(n,1,u),i.isZero()||(i.negative^=1);a&&(a.words[u]=p)}return a&&a.strip(),i.strip(),"div"!==t&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(e,t,r){return i(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(e)),{div:n,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):this.negative&e.negative?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,i=e.ushrn(1),n=e.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){i(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;n>=0;n--)r=(t*r+(0|this.words[n]))%e;return r},o.prototype.idivn=function(e){i(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new o(1),s=new o(0),a=new o(0),l=new o(1),d=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++d;for(var c=r.clone(),u=t.clone();!t.isZero();){for(var p=0,h=1;!(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(c),s.isub(u)),n.iushrn(1),s.iushrn(1);for(var f=0,m=1;!(r.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(r.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(c),l.isub(u)),a.iushrn(1),l.iushrn(1);t.cmp(r)>=0?(t.isub(r),n.isub(a),s.isub(l)):(r.isub(t),a.isub(n),l.isub(s))}return{a,b:l,gcd:r.iushln(d)}},o.prototype._invmp=function(e){i(0===e.negative),i(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,s=new o(1),a=new o(0),l=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var d=0,c=1;!(t.words[0]&c)&&d<26;++d,c<<=1);if(d>0)for(t.iushrn(d);d-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var u=0,p=1;!(r.words[0]&p)&&u<26;++u,p<<=1);if(u>0)for(r.iushrn(u);u-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(r)>=0?(t.isub(r),s.isub(a)):(r.isub(t),a.isub(s))}return(n=0===t.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(e),n},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var i=0;t.isEven()&&r.isEven();i++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=t.cmp(r);if(n<0){var o=t;t=r,r=o}else if(0===n||0===r.cmpn(1))break;t.isub(r)}return r.iushln(i)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return!(1&this.words[0])},o.prototype.isOdd=function(){return!(1&~this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){i("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),i(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:ne.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|e.words[r];if(i!==n){in&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new S(e)},o.prototype.toRed=function(e){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return i(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return i(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else i(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var i=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(b,v),b.prototype.split=function(e,t){for(var r=4194303,i=Math.min(e.length,9),n=0;n>>22,o=s}o>>>=22,e.words[n-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r>>=26,e.words[r]=n,t=i}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new w;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return y[e]=t,t},S.prototype._verify1=function(e){i(0===e.negative,"red works only with positives"),i(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){i(!(e.negative|t.negative),"red works only with positives"),i(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(i(t%2==1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),l=a.redNeg(),d=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,d).cmp(l);)c.redIAdd(l);for(var u=this.pow(c,n),p=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();i(g=0;i--){for(var d=t.words[i],c=l-1;c>=0;c--){var u=d>>c&1;n!==r[0]&&(n=this.sqr(n)),0!==u||0!==s?(s<<=1,s|=u,(4===++a||0===i&&0===c)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}l=26}return n},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,S),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=r.nmd(e),this)},77362:(e,t,r)=>{var i=r(78170),n=r(48206),o=r(52061),s=r(82509),a=r(67332),l=r(47108),d=r(99247),c=r(92861).Buffer;e.exports=function(e,t,r){var u;u=e.padding?e.padding:r?1:4;var p,h=i(e),f=h.modulus.byteLength();if(t.length>f||new s(t).cmp(h.modulus)>=0)throw new Error("decryption error");p=r?d(new s(t),h):a(t,h);var m=c.alloc(f-p.length);if(p=c.concat([m,p],f),4===u)return function(e,t){var r=e.modulus.byteLength(),i=l("sha1").update(c.alloc(0)).digest(),s=i.length;if(0!==t[0])throw new Error("decryption error");var a=t.slice(1,s+1),d=t.slice(s+1),u=o(a,n(d,s)),p=o(d,n(u,r-s-1));if(function(e,t){e=c.from(e),t=c.from(t);var r=0,i=e.length;e.length!==t.length&&(r++,i=Math.min(e.length,t.length));var n=-1;for(;++n=t.length){o++;break}var s=t.slice(2,n-1);("0002"!==i.toString("hex")&&!r||"0001"!==i.toString("hex")&&r)&&o++;s.length<8&&o++;if(o)throw new Error("decryption error");return t.slice(n)}(0,p,r);if(3===u)return p;throw new Error("unknown padding")}},28902:(e,t,r)=>{var i=r(78170),n=r(53209),o=r(47108),s=r(48206),a=r(52061),l=r(82509),d=r(99247),c=r(67332),u=r(92861).Buffer;e.exports=function(e,t,r){var p;p=e.padding?e.padding:r?1:4;var h,f=i(e);if(4===p)h=function(e,t){var r=e.modulus.byteLength(),i=t.length,d=o("sha1").update(u.alloc(0)).digest(),c=d.length,p=2*c;if(i>r-p-2)throw new Error("message too long");var h=u.alloc(r-i-p-2),f=r-c-1,m=n(c),g=a(u.concat([d,h,u.alloc(1,1),t],f),s(m,f)),y=a(m,s(g,c));return new l(u.concat([u.alloc(1),y,g],r))}(f,t);else if(1===p)h=function(e,t,r){var i,o=t.length,s=e.modulus.byteLength();if(o>s-11)throw new Error("message too long");i=r?u.alloc(s-o-3,255):function(e){var t,r=u.allocUnsafe(e),i=0,o=n(2*e),s=0;for(;i=0)throw new Error("data too long for modulus")}return r?c(h,f):d(h,f)}},99247:(e,t,r)=>{var i=r(82509),n=r(92861).Buffer;e.exports=function(e,t){return n.from(e.toRed(i.mont(t.modulus)).redPow(new i(t.publicExponent)).fromRed().toArray())}},52061:e=>{e.exports=function(e,t){for(var r=e.length,i=-1;++i{const i=r(91333),n=r(90157),o=r(47899),s=r(56756);function a(e,t,r,o,s){const a=[].slice.call(arguments,1),l=a.length,d="function"==typeof a[l-1];if(!d&&!i())throw new Error("Callback required as last argument");if(!d){if(l<1)throw new Error("Too few arguments provided");return 1===l?(r=t,t=o=void 0):2!==l||t.getContext||(o=r,r=t,t=void 0),new Promise((function(i,s){try{const s=n.create(r,o);i(e(s,t,o))}catch(e){s(e)}}))}if(l<2)throw new Error("Too few arguments provided");2===l?(s=r,r=t,t=o=void 0):3===l&&(t.getContext&&void 0===s?(s=o,o=void 0):(s=o,o=r,r=t,t=void 0));try{const i=n.create(r,o);s(null,e(i,t,o))}catch(e){s(e)}}t.create=n.create,t.toCanvas=a.bind(null,o.render),t.toDataURL=a.bind(null,o.renderToDataURL),t.toString=a.bind(null,(function(e,t,r){return s.render(e,r)}))},91333:e=>{e.exports=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then}},28802:(e,t,r)=>{const i=r(56886).getSymbolSize;t.getRowColCoords=function(e){if(1===e)return[];const t=Math.floor(e/7)+2,r=i(e),n=145===r?26:2*Math.ceil((r-13)/(2*t-2)),o=[r-7];for(let e=1;e{const i=r(30208),n=["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"," ","$","%","*","+","-",".","/",":"];function o(e){this.mode=i.ALPHANUMERIC,this.data=e}o.getBitsLength=function(e){return 11*Math.floor(e/2)+e%2*6},o.prototype.getLength=function(){return this.data.length},o.prototype.getBitsLength=function(){return o.getBitsLength(this.data.length)},o.prototype.write=function(e){let t;for(t=0;t+2<=this.data.length;t+=2){let r=45*n.indexOf(this.data[t]);r+=n.indexOf(this.data[t+1]),e.put(r,11)}this.data.length%2&&e.put(n.indexOf(this.data[t]),6)},e.exports=o},99899:e=>{function t(){this.buffer=[],this.length=0}t.prototype={get:function(e){const t=Math.floor(e/8);return 1==(this.buffer[t]>>>7-e%8&1)},put:function(e,t){for(let r=0;r>>t-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}},e.exports=t},8820:e=>{function t(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}t.prototype.set=function(e,t,r,i){const n=e*this.size+t;this.data[n]=r,i&&(this.reservedBit[n]=!0)},t.prototype.get=function(e,t){return this.data[e*this.size+t]},t.prototype.xor=function(e,t,r){this.data[e*this.size+t]^=r},t.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]},e.exports=t},25822:(e,t,r)=>{const i=r(30208);function n(e){this.mode=i.BYTE,this.data="string"==typeof e?(new TextEncoder).encode(e):new Uint8Array(e)}n.getBitsLength=function(e){return 8*e},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(e){for(let t=0,r=this.data.length;t{const i=r(49953),n=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],o=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];t.getBlocksCount=function(e,t){switch(t){case i.L:return n[4*(e-1)+0];case i.M:return n[4*(e-1)+1];case i.Q:return n[4*(e-1)+2];case i.H:return n[4*(e-1)+3];default:return}},t.getTotalCodewordsCount=function(e,t){switch(t){case i.L:return o[4*(e-1)+0];case i.M:return o[4*(e-1)+1];case i.Q:return o[4*(e-1)+2];case i.H:return o[4*(e-1)+3];default:return}}},49953:(e,t)=>{t.L={bit:1},t.M={bit:0},t.Q={bit:3},t.H={bit:2},t.isValid=function(e){return e&&void 0!==e.bit&&e.bit>=0&&e.bit<4},t.from=function(e,r){if(t.isValid(e))return e;try{return function(e){if("string"!=typeof e)throw new Error("Param is not a string");switch(e.toLowerCase()){case"l":case"low":return t.L;case"m":case"medium":return t.M;case"q":case"quartile":return t.Q;case"h":case"high":return t.H;default:throw new Error("Unknown EC Level: "+e)}}(e)}catch(e){return r}}},7756:(e,t,r)=>{const i=r(56886).getSymbolSize;t.getPositions=function(e){const t=i(e);return[[0,0],[t-7,0],[0,t-7]]}},84565:(e,t,r)=>{const i=r(56886),n=i.getBCHDigit(1335);t.getEncodedBits=function(e,t){const r=e.bit<<3|t;let o=r<<10;for(;i.getBCHDigit(o)-n>=0;)o^=1335<{const r=new Uint8Array(512),i=new Uint8Array(256);!function(){let e=1;for(let t=0;t<255;t++)r[t]=e,i[e]=t,e<<=1,256&e&&(e^=285);for(let e=255;e<512;e++)r[e]=r[e-255]}(),t.log=function(e){if(e<1)throw new Error("log("+e+")");return i[e]},t.exp=function(e){return r[e]},t.mul=function(e,t){return 0===e||0===t?0:r[i[e]+i[t]]}},24861:(e,t,r)=>{const i=r(30208),n=r(56886);function o(e){this.mode=i.KANJI,this.data=e}o.getBitsLength=function(e){return 13*e},o.prototype.getLength=function(){return this.data.length},o.prototype.getBitsLength=function(){return o.getBitsLength(this.data.length)},o.prototype.write=function(e){let t;for(t=0;t=33088&&r<=40956)r-=33088;else{if(!(r>=57408&&r<=60351))throw new Error("Invalid SJIS character: "+this.data[t]+"\nMake sure your charset is UTF-8");r-=49472}r=192*(r>>>8&255)+(255&r),e.put(r,13)}},e.exports=o},81332:(e,t)=>{t.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const r=3,i=3,n=40,o=10;function s(e,r,i){switch(e){case t.Patterns.PATTERN000:return(r+i)%2==0;case t.Patterns.PATTERN001:return r%2==0;case t.Patterns.PATTERN010:return i%3==0;case t.Patterns.PATTERN011:return(r+i)%3==0;case t.Patterns.PATTERN100:return(Math.floor(r/2)+Math.floor(i/3))%2==0;case t.Patterns.PATTERN101:return r*i%2+r*i%3==0;case t.Patterns.PATTERN110:return(r*i%2+r*i%3)%2==0;case t.Patterns.PATTERN111:return(r*i%3+(r+i)%2)%2==0;default:throw new Error("bad maskPattern:"+e)}}t.isValid=function(e){return null!=e&&""!==e&&!isNaN(e)&&e>=0&&e<=7},t.from=function(e){return t.isValid(e)?parseInt(e,10):void 0},t.getPenaltyN1=function(e){const t=e.size;let i=0,n=0,o=0,s=null,a=null;for(let l=0;l=5&&(i+=r+(n-5)),s=t,n=1),t=e.get(d,l),t===a?o++:(o>=5&&(i+=r+(o-5)),a=t,o=1)}n>=5&&(i+=r+(n-5)),o>=5&&(i+=r+(o-5))}return i},t.getPenaltyN2=function(e){const t=e.size;let r=0;for(let i=0;i=10&&(1488===i||93===i)&&r++,o=o<<1&2047|e.get(s,n),s>=10&&(1488===o||93===o)&&r++}return r*n},t.getPenaltyN4=function(e){let t=0;const r=e.data.length;for(let i=0;i{const i=r(21878),n=r(67044);t.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},t.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},t.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},t.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},t.MIXED={bit:-1},t.getCharCountIndicator=function(e,t){if(!e.ccBits)throw new Error("Invalid mode: "+e);if(!i.isValid(t))throw new Error("Invalid version: "+t);return t>=1&&t<10?e.ccBits[0]:t<27?e.ccBits[1]:e.ccBits[2]},t.getBestModeForData=function(e){return n.testNumeric(e)?t.NUMERIC:n.testAlphanumeric(e)?t.ALPHANUMERIC:n.testKanji(e)?t.KANJI:t.BYTE},t.toString=function(e){if(e&&e.id)return e.id;throw new Error("Invalid mode")},t.isValid=function(e){return e&&e.bit&&e.ccBits},t.from=function(e,r){if(t.isValid(e))return e;try{return function(e){if("string"!=typeof e)throw new Error("Param is not a string");switch(e.toLowerCase()){case"numeric":return t.NUMERIC;case"alphanumeric":return t.ALPHANUMERIC;case"kanji":return t.KANJI;case"byte":return t.BYTE;default:throw new Error("Unknown mode: "+e)}}(e)}catch(e){return r}}},24357:(e,t,r)=>{const i=r(30208);function n(e){this.mode=i.NUMERIC,this.data=e.toString()}n.getBitsLength=function(e){return 10*Math.floor(e/3)+(e%3?e%3*3+1:0)},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(e){let t,r,i;for(t=0;t+3<=this.data.length;t+=3)r=this.data.substr(t,3),i=parseInt(r,10),e.put(i,10);const n=this.data.length-t;n>0&&(r=this.data.substr(t),i=parseInt(r,10),e.put(i,3*n+1))},e.exports=n},64713:(e,t,r)=>{const i=r(2731);t.mul=function(e,t){const r=new Uint8Array(e.length+t.length-1);for(let n=0;n=0;){const e=r[0];for(let n=0;n{const i=r(56886),n=r(49953),o=r(99899),s=r(8820),a=r(28802),l=r(7756),d=r(81332),c=r(97518),u=r(74764),p=r(31427),h=r(84565),f=r(30208),m=r(29801);function g(e,t,r){const i=e.size,n=h.getEncodedBits(t,r);let o,s;for(o=0;o<15;o++)s=1==(n>>o&1),o<6?e.set(o,8,s,!0):o<8?e.set(o+1,8,s,!0):e.set(i-15+o,8,s,!0),o<8?e.set(8,i-o-1,s,!0):o<9?e.set(8,15-o-1+1,s,!0):e.set(8,15-o-1,s,!0);e.set(i-8,8,1,!0)}function y(e,t,r){const n=new o;r.forEach((function(t){n.put(t.mode.bit,4),n.put(t.getLength(),f.getCharCountIndicator(t.mode,e)),t.write(n)}));const s=8*(i.getSymbolTotalCodewords(e)-c.getTotalCodewordsCount(e,t));for(n.getLengthInBits()+4<=s&&n.put(0,4);n.getLengthInBits()%8!=0;)n.putBit(0);const a=(s-n.getLengthInBits())/8;for(let e=0;e=0&&t<=6&&(0===i||6===i)||i>=0&&i<=6&&(0===t||6===t)||t>=2&&t<=4&&i>=2&&i<=4?e.set(n+t,o+i,!0,!0):e.set(n+t,o+i,!1,!0))}}(f,t),function(e){const t=e.size;for(let r=8;r=7&&function(e,t){const r=e.size,i=p.getEncodedBits(t);let n,o,s;for(let t=0;t<18;t++)n=Math.floor(t/3),o=t%3+r-8-3,s=1==(i>>t&1),e.set(n,o,s,!0),e.set(o,n,s,!0)}(f,t),function(e,t){const r=e.size;let i=-1,n=r-1,o=7,s=0;for(let a=r-1;a>0;a-=2)for(6===a&&a--;;){for(let r=0;r<2;r++)if(!e.isReserved(n,a-r)){let i=!1;s>>o&1)),e.set(n,a-r,i),o--,-1===o&&(s++,o=7)}if(n+=i,n<0||r<=n){n-=i,i=-i;break}}}(f,u),isNaN(n)&&(n=d.getBestMask(f,g.bind(null,f,r))),d.applyMask(n,f),g(f,r,n),{modules:f,version:t,errorCorrectionLevel:r,maskPattern:n,segments:o}}t.create=function(e,t){if(void 0===e||""===e)throw new Error("No input text");let r,o,s=n.M;return void 0!==t&&(s=n.from(t.errorCorrectionLevel,n.M),r=p.from(t.version),o=d.from(t.maskPattern),t.toSJISFunc&&i.setToSJISFunction(t.toSJISFunc)),v(e,r,s,o)}},74764:(e,t,r)=>{const i=r(64713);function n(e){this.genPoly=void 0,this.degree=e,this.degree&&this.initialize(this.degree)}n.prototype.initialize=function(e){this.degree=e,this.genPoly=i.generateECPolynomial(this.degree)},n.prototype.encode=function(e){if(!this.genPoly)throw new Error("Encoder not initialized");const t=new Uint8Array(e.length+this.degree);t.set(e);const r=i.mod(t,this.genPoly),n=this.degree-r.length;if(n>0){const e=new Uint8Array(this.degree);return e.set(r,n),e}return r},e.exports=n},67044:(e,t)=>{const r="[0-9]+";let i="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";i=i.replace(/u/g,"\\u");const n="(?:(?![A-Z0-9 $%*+\\-./:]|"+i+")(?:.|[\r\n]))+";t.KANJI=new RegExp(i,"g"),t.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),t.BYTE=new RegExp(n,"g"),t.NUMERIC=new RegExp(r,"g"),t.ALPHANUMERIC=new RegExp("[A-Z $%*+\\-./:]+","g");const o=new RegExp("^"+i+"$"),s=new RegExp("^"+r+"$"),a=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");t.testKanji=function(e){return o.test(e)},t.testNumeric=function(e){return s.test(e)},t.testAlphanumeric=function(e){return a.test(e)}},29801:(e,t,r)=>{const i=r(30208),n=r(24357),o=r(11433),s=r(25822),a=r(24861),l=r(67044),d=r(56886),c=r(76320);function u(e){return unescape(encodeURIComponent(e)).length}function p(e,t,r){const i=[];let n;for(;null!==(n=e.exec(r));)i.push({data:n[0],index:n.index,mode:t,length:n[0].length});return i}function h(e){const t=p(l.NUMERIC,i.NUMERIC,e),r=p(l.ALPHANUMERIC,i.ALPHANUMERIC,e);let n,o;d.isKanjiModeEnabled()?(n=p(l.BYTE,i.BYTE,e),o=p(l.KANJI,i.KANJI,e)):(n=p(l.BYTE_KANJI,i.BYTE,e),o=[]);return t.concat(r,n,o).sort((function(e,t){return e.index-t.index})).map((function(e){return{data:e.data,mode:e.mode,length:e.length}}))}function f(e,t){switch(t){case i.NUMERIC:return n.getBitsLength(e);case i.ALPHANUMERIC:return o.getBitsLength(e);case i.KANJI:return a.getBitsLength(e);case i.BYTE:return s.getBitsLength(e)}}function m(e,t){let r;const l=i.getBestModeForData(e);if(r=i.from(t,l),r!==i.BYTE&&r.bit=0?e[e.length-1]:null;return r&&r.mode===t.mode?(e[e.length-1].data+=t.data,e):(e.push(t),e)}),[])}(a))},t.rawSplit=function(e){return t.fromArray(h(e,d.isKanjiModeEnabled()))}},56886:(e,t)=>{let r;const i=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];t.getSymbolSize=function(e){if(!e)throw new Error('"version" cannot be null or undefined');if(e<1||e>40)throw new Error('"version" should be in range from 1 to 40');return 4*e+17},t.getSymbolTotalCodewords=function(e){return i[e]},t.getBCHDigit=function(e){let t=0;for(;0!==e;)t++,e>>>=1;return t},t.setToSJISFunction=function(e){if("function"!=typeof e)throw new Error('"toSJISFunc" is not a valid function.');r=e},t.isKanjiModeEnabled=function(){return void 0!==r},t.toSJIS=function(e){return r(e)}},21878:(e,t)=>{t.isValid=function(e){return!isNaN(e)&&e>=1&&e<=40}},31427:(e,t,r)=>{const i=r(56886),n=r(97518),o=r(49953),s=r(30208),a=r(21878),l=i.getBCHDigit(7973);function d(e,t){return s.getCharCountIndicator(e,t)+4}function c(e,t){let r=0;return e.forEach((function(e){const i=d(e.mode,t);r+=i+e.getBitsLength()})),r}t.from=function(e,t){return a.isValid(e)?parseInt(e,10):t},t.getCapacity=function(e,t,r){if(!a.isValid(e))throw new Error("Invalid QR Code version");void 0===r&&(r=s.BYTE);const o=8*(i.getSymbolTotalCodewords(e)-n.getTotalCodewordsCount(e,t));if(r===s.MIXED)return o;const l=o-d(r,e);switch(r){case s.NUMERIC:return Math.floor(l/10*3);case s.ALPHANUMERIC:return Math.floor(l/11*2);case s.KANJI:return Math.floor(l/13);case s.BYTE:default:return Math.floor(l/8)}},t.getBestVersionForData=function(e,r){let i;const n=o.from(r,o.M);if(Array.isArray(e)){if(e.length>1)return function(e,r){for(let i=1;i<=40;i++)if(c(e,i)<=t.getCapacity(i,r,s.MIXED))return i}(e,n);if(0===e.length)return 1;i=e[0]}else i=e;return function(e,r,i){for(let n=1;n<=40;n++)if(r<=t.getCapacity(n,i,e))return n}(i.mode,i.getLength(),n)},t.getEncodedBits=function(e){if(!a.isValid(e)||e<7)throw new Error("Invalid QR Code version");let t=e<<12;for(;i.getBCHDigit(t)-l>=0;)t^=7973<{const i=r(92726);t.render=function(e,t,r){let n=r,o=t;void 0!==n||t&&t.getContext||(n=t,t=void 0),t||(o=function(){try{return document.createElement("canvas")}catch(e){throw new Error("You need to specify a canvas element")}}()),n=i.getOptions(n);const s=i.getImageWidth(e.modules.size,n),a=o.getContext("2d"),l=a.createImageData(s,s);return i.qrToImageData(l.data,e,n),function(e,t,r){e.clearRect(0,0,t.width,t.height),t.style||(t.style={}),t.height=r,t.width=r,t.style.height=r+"px",t.style.width=r+"px"}(a,o,s),a.putImageData(l,0,0),o},t.renderToDataURL=function(e,r,i){let n=i;void 0!==n||r&&r.getContext||(n=r,r=void 0),n||(n={});const o=t.render(e,r,n),s=n.type||"image/png",a=n.rendererOpts||{};return o.toDataURL(s,a.quality)}},56756:(e,t,r)=>{const i=r(92726);function n(e,t){const r=e.a/255,i=t+'="'+e.hex+'"';return r<1?i+" "+t+'-opacity="'+r.toFixed(2).slice(1)+'"':i}function o(e,t,r){let i=e+t;return void 0!==r&&(i+=" "+r),i}t.render=function(e,t,r){const s=i.getOptions(t),a=e.modules.size,l=e.modules.data,d=a+2*s.margin,c=s.color.light.a?"':"",u="0&&d>0&&e[l-1]||(i+=s?o("M",d+r,.5+c+r):o("m",n,0),n=0,s=!1),d+1',p='viewBox="0 0 '+d+" "+d+'"',h=''+c+u+"\n";return"function"==typeof r&&r(null,h),h}},92726:(e,t)=>{function r(e){if("number"==typeof e&&(e=e.toString()),"string"!=typeof e)throw new Error("Color should be defined as hex string");let t=e.slice().replace("#","").split("");if(t.length<3||5===t.length||t.length>8)throw new Error("Invalid hex color: "+e);3!==t.length&&4!==t.length||(t=Array.prototype.concat.apply([],t.map((function(e){return[e,e]})))),6===t.length&&t.push("F","F");const r=parseInt(t.join(""),16);return{r:r>>24&255,g:r>>16&255,b:r>>8&255,a:255&r,hex:"#"+t.slice(0,6).join("")}}t.getOptions=function(e){e||(e={}),e.color||(e.color={});const t=void 0===e.margin||null===e.margin||e.margin<0?4:e.margin,i=e.width&&e.width>=21?e.width:void 0,n=e.scale||4;return{width:i,scale:i?4:n,margin:t,color:{dark:r(e.color.dark||"#000000ff"),light:r(e.color.light||"#ffffffff")},type:e.type,rendererOpts:e.rendererOpts||{}}},t.getScale=function(e,t){return t.width&&t.width>=e+2*t.margin?t.width/(e+2*t.margin):t.scale},t.getImageWidth=function(e,r){const i=t.getScale(e,r);return Math.floor((e+2*r.margin)*i)},t.qrToImageData=function(e,r,i){const n=r.modules.size,o=r.modules.data,s=t.getScale(n,i),a=Math.floor((n+2*i.margin)*s),l=i.margin*s,d=[i.color.light,i.color.dark];for(let t=0;t=l&&r>=l&&t{"use strict";var t=String.prototype.replace,r=/%20/g,i="RFC1738",n="RFC3986";e.exports={default:n,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:i,RFC3986:n}},55373:(e,t,r)=>{"use strict";var i=r(98636),n=r(62642),o=r(74765);e.exports={formats:o,parse:n,stringify:i}},62642:(e,t,r)=>{"use strict";var i=r(37720),n=Object.prototype.hasOwnProperty,o=Array.isArray,s={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:i.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1},a=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},l=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},d=function(e,t,r,i){if(e){var o=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,s=/(\[[^[\]]*])/g,a=r.depth>0&&/(\[[^[\]]*])/.exec(o),d=a?o.slice(0,a.index):o,c=[];if(d){if(!r.plainObjects&&n.call(Object.prototype,d)&&!r.allowPrototypes)return;c.push(d)}for(var u=0;r.depth>0&&null!==(a=s.exec(o))&&u=0;--o){var s,a=e[o];if("[]"===a&&r.parseArrays)s=r.allowEmptyArrays&&(""===n||r.strictNullHandling&&null===n)?[]:[].concat(n);else{s=r.plainObjects?Object.create(null):{};var d="["===a.charAt(0)&&"]"===a.charAt(a.length-1)?a.slice(1,-1):a,c=r.decodeDotInKeys?d.replace(/%2E/g,"."):d,u=parseInt(c,10);r.parseArrays||""!==c?!isNaN(u)&&a!==c&&String(u)===c&&u>=0&&r.parseArrays&&u<=r.arrayLimit?(s=[])[u]=n:"__proto__"!==c&&(s[c]=n):s={0:n}}n=s}return n}(c,t,r,i)}};e.exports=function(e,t){var r=function(e){if(!e)return s;if(void 0!==e.allowEmptyArrays&&"boolean"!=typeof e.allowEmptyArrays)throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(void 0!==e.decodeDotInKeys&&"boolean"!=typeof e.decodeDotInKeys)throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?s.charset:e.charset,r=void 0===e.duplicates?s.duplicates:e.duplicates;if("combine"!==r&&"first"!==r&&"last"!==r)throw new TypeError("The duplicates option must be either combine, first, or last");return{allowDots:void 0===e.allowDots?!0===e.decodeDotInKeys||s.allowDots:!!e.allowDots,allowEmptyArrays:"boolean"==typeof e.allowEmptyArrays?!!e.allowEmptyArrays:s.allowEmptyArrays,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:s.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:s.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:s.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:s.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:s.comma,decodeDotInKeys:"boolean"==typeof e.decodeDotInKeys?e.decodeDotInKeys:s.decodeDotInKeys,decoder:"function"==typeof e.decoder?e.decoder:s.decoder,delimiter:"string"==typeof e.delimiter||i.isRegExp(e.delimiter)?e.delimiter:s.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:s.depth,duplicates:r,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:s.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:s.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:s.plainObjects,strictDepth:"boolean"==typeof e.strictDepth?!!e.strictDepth:s.strictDepth,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:s.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var c="string"==typeof e?function(e,t){var r={__proto__:null},d=t.ignoreQueryPrefix?e.replace(/^\?/,""):e;d=d.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var c,u=t.parameterLimit===1/0?void 0:t.parameterLimit,p=d.split(t.delimiter,u),h=-1,f=t.charset;if(t.charsetSentinel)for(c=0;c-1&&(g=o(g)?[g]:g);var w=n.call(r,m);w&&"combine"===t.duplicates?r[m]=i.combine(r[m],g):w&&"last"!==t.duplicates||(r[m]=g)}return r}(e,r):e,u=r.plainObjects?Object.create(null):{},p=Object.keys(c),h=0;h{"use strict";var i=r(920),n=r(37720),o=r(74765),s=Object.prototype.hasOwnProperty,a={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},l=Array.isArray,d=Array.prototype.push,c=function(e,t){d.apply(e,l(t)?t:[t])},u=Date.prototype.toISOString,p=o.default,h={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:n.encode,encodeValuesOnly:!1,format:p,formatter:o.formatters[p],indices:!1,serializeDate:function(e){return u.call(e)},skipNulls:!1,strictNullHandling:!1},f={},m=function e(t,r,o,s,a,d,u,p,m,g,y,v,b,w,_,x,S,k){for(var E,T=t,B=k,C=0,I=!1;void 0!==(B=B.get(f))&&!I;){var A=B.get(t);if(C+=1,void 0!==A){if(A===C)throw new RangeError("Cyclic object value");I=!0}void 0===B.get(f)&&(C=0)}if("function"==typeof g?T=g(r,T):T instanceof Date?T=b(T):"comma"===o&&l(T)&&(T=n.maybeMap(T,(function(e){return e instanceof Date?b(e):e}))),null===T){if(d)return m&&!x?m(r,h.encoder,S,"key",w):r;T=""}if("string"==typeof(E=T)||"number"==typeof E||"boolean"==typeof E||"symbol"==typeof E||"bigint"==typeof E||n.isBuffer(T))return m?[_(x?r:m(r,h.encoder,S,"key",w))+"="+_(m(T,h.encoder,S,"value",w))]:[_(r)+"="+_(String(T))];var F,M=[];if(void 0===T)return M;if("comma"===o&&l(T))x&&m&&(T=n.maybeMap(T,m)),F=[{value:T.length>0?T.join(",")||null:void 0}];else if(l(g))F=g;else{var D=Object.keys(T);F=y?D.sort(y):D}var R=p?r.replace(/\./g,"%2E"):r,P=s&&l(T)&&1===T.length?R+"[]":R;if(a&&l(T)&&0===T.length)return P+"[]";for(var O=0;O0?w+b:""}},37720:(e,t,r)=>{"use strict";var i=r(74765),n=Object.prototype.hasOwnProperty,o=Array.isArray,s=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),a=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},i=0;i1;){var t=e.pop(),r=t.obj[t.prop];if(o(r)){for(var i=[],n=0;n=l?a.slice(c,c+l):a,p=[],h=0;h=48&&f<=57||f>=65&&f<=90||f>=97&&f<=122||o===i.RFC1738&&(40===f||41===f)?p[p.length]=u.charAt(h):f<128?p[p.length]=s[f]:f<2048?p[p.length]=s[192|f>>6]+s[128|63&f]:f<55296||f>=57344?p[p.length]=s[224|f>>12]+s[128|f>>6&63]+s[128|63&f]:(h+=1,f=65536+((1023&f)<<10|1023&u.charCodeAt(h)),p[p.length]=s[240|f>>18]+s[128|f>>12&63]+s[128|f>>6&63]+s[128|63&f])}d+=p.join("")}return d},isBuffer:function(e){return!(!e||"object"!=typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(o(e)){for(var r=[],i=0;i{"use strict";var i=r(65606),n=65536,o=4294967295;var s=r(92861).Buffer,a=r.g.crypto||r.g.msCrypto;a&&a.getRandomValues?e.exports=function(e,t){if(e>o)throw new RangeError("requested too many random bytes");var r=s.allocUnsafe(e);if(e>0)if(e>n)for(var l=0;l{"use strict";var i=r(65606);function n(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(92861),s=r(53209),a=o.Buffer,l=o.kMaxLength,d=r.g.crypto||r.g.msCrypto,c=Math.pow(2,32)-1;function u(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>c||e<0)throw new TypeError("offset must be a uint32");if(e>l||e>t)throw new RangeError("offset out of range")}function p(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>c||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>l)throw new RangeError("buffer too small")}function h(e,t,r,n){if(i.browser){var o=e.buffer,a=new Uint8Array(o,t,r);return d.getRandomValues(a),n?void i.nextTick((function(){n(null,e)})):e}if(!n)return s(r).copy(e,t),e;s(r,(function(r,i){if(r)return n(r);i.copy(e,t),n(null,e)}))}d&&d.getRandomValues||!i.browser?(t.randomFill=function(e,t,i,n){if(!(a.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)n=t,t=0,i=e.length;else if("function"==typeof i)n=i,i=e.length-t;else if("function"!=typeof n)throw new TypeError('"cb" argument must be a function');return u(t,e.length),p(i,t,e.length),h(e,t,i,n)},t.randomFillSync=function(e,t,i){void 0===t&&(t=0);if(!(a.isBuffer(e)||e instanceof r.g.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');u(t,e.length),void 0===i&&(i=e.length-t);return p(i,t,e.length),h(e,t,i)}):(t.randomFill=n,t.randomFillSync=n)},25382:(e,t,r)=>{"use strict";var i=r(33225),n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=u;var o=Object.create(r(15622));o.inherits=r(56698);var s=r(45412),a=r(16708);o.inherits(u,s);for(var l=n(a.prototype),d=0;d{"use strict";e.exports=o;var i=r(74610),n=Object.create(r(15622));function o(e){if(!(this instanceof o))return new o(e);i.call(this,e)}n.inherits=r(56698),n.inherits(o,i),o.prototype._transform=function(e,t,r){r(null,e)}},45412:(e,t,r)=>{"use strict";var i=r(65606),n=r(33225);e.exports=b;var o,s=r(64634);b.ReadableState=v;r(37007).EventEmitter;var a=function(e,t){return e.listeners(t).length},l=r(40345),d=r(34106).Buffer,c=(void 0!==r.g?r.g:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var u=Object.create(r(15622));u.inherits=r(56698);var p=r(79838),h=void 0;h=p&&p.debuglog?p.debuglog("stream"):function(){};var f,m=r(83222),g=r(75896);u.inherits(b,l);var y=["error","close","destroy","pause","resume"];function v(e,t){e=e||{};var i=t instanceof(o=o||r(25382));this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var n=e.highWaterMark,s=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:i&&(s||0===s)?s:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new m,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(f||(f=r(83141).I),this.decoder=new f(e.encoding),this.encoding=e.encoding)}function b(e){if(o=o||r(25382),!(this instanceof b))return new b(e);this._readableState=new v(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),l.call(this)}function w(e,t,r,i,n){var o,s=e._readableState;null===t?(s.reading=!1,function(e,t){if(t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,k(e)}(e,s)):(n||(o=function(e,t){var r;i=t,d.isBuffer(i)||i instanceof c||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var i;return r}(s,t)),o?e.emit("error",o):s.objectMode||t&&t.length>0?("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===d.prototype||(t=function(e){return d.from(e)}(t)),i?s.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):_(e,s,t,!0):s.ended?e.emit("error",new Error("stream.push() after EOF")):(s.reading=!1,s.decoder&&!r?(t=s.decoder.write(t),s.objectMode||0!==t.length?_(e,s,t,!1):T(e,s)):_(e,s,t,!1))):i||(s.reading=!1));return function(e){return!e.ended&&(e.needReadable||e.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=x?e=x:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function k(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(h("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?n.nextTick(E,e):E(e))}function E(e){h("emit readable"),e.emit("readable"),A(e)}function T(e,t){t.readingMore||(t.readingMore=!0,n.nextTick(B,e,t))}function B(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var i;eo.length?o.length:e;if(s===o.length?n+=o:n+=o.slice(0,e),0===(e-=s)){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}(e,t):function(e,t){var r=d.allocUnsafe(e),i=t.head,n=1;i.data.copy(r),e-=i.data.length;for(;i=i.next;){var o=i.data,s=e>o.length?o.length:e;if(o.copy(r,r.length-e,0,s),0===(e-=s)){s===o.length?(++n,i.next?t.head=i.next:t.head=t.tail=null):(t.head=i,i.data=o.slice(s));break}++n}return t.length-=n,r}(e,t);return i}(e,t.buffer,t.decoder),r);var r}function M(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,n.nextTick(D,t,e))}function D(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function R(e,t){for(var r=0,i=e.length;r=t.highWaterMark||t.ended))return h("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?M(this):k(this),null;if(0===(e=S(e,t))&&t.ended)return 0===t.length&&M(this),null;var i,n=t.needReadable;return h("need readable",n),(0===t.length||t.length-e0?F(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&M(this)),null!==i&&this.emit("data",i),i},b.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},b.prototype.pipe=function(e,t){var r=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,h("pipe count=%d opts=%j",o.pipesCount,t);var l=(!t||!1!==t.end)&&e!==i.stdout&&e!==i.stderr?c:b;function d(t,i){h("onunpipe"),t===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,h("cleanup"),e.removeListener("close",y),e.removeListener("finish",v),e.removeListener("drain",u),e.removeListener("error",g),e.removeListener("unpipe",d),r.removeListener("end",c),r.removeListener("end",b),r.removeListener("data",m),p=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||u())}function c(){h("onend"),e.end()}o.endEmitted?n.nextTick(l):r.once("end",l),e.on("unpipe",d);var u=function(e){return function(){var t=e._readableState;h("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&a(e,"data")&&(t.flowing=!0,A(e))}}(r);e.on("drain",u);var p=!1;var f=!1;function m(t){h("ondata"),f=!1,!1!==e.write(t)||f||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==R(o.pipes,e))&&!p&&(h("false write response, pause",o.awaitDrain),o.awaitDrain++,f=!0),r.pause())}function g(t){h("onerror",t),b(),e.removeListener("error",g),0===a(e,"error")&&e.emit("error",t)}function y(){e.removeListener("finish",v),b()}function v(){h("onfinish"),e.removeListener("close",y),b()}function b(){h("unpipe"),r.unpipe(e)}return r.on("data",m),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?s(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",g),e.once("close",y),e.once("finish",v),e.emit("pipe",r),o.flowing||(h("pipe resume"),r.resume()),e},b.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var i=t.pipes,n=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o{"use strict";e.exports=s;var i=r(25382),n=Object.create(r(15622));function o(e,t){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(!i)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=t&&this.push(t),i(e);var n=this._readableState;n.reading=!1,(n.needReadable||n.length{"use strict";var i=r(65606),n=r(33225);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var i=e.entry;e.entry=null;for(;i;){var n=i.callback;t.pendingcb--,n(r),i=i.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=y;var s,a=!i.browser&&["v0.10","v0.9."].indexOf(i.version.slice(0,5))>-1?setImmediate:n.nextTick;y.WritableState=g;var l=Object.create(r(15622));l.inherits=r(56698);var d={deprecate:r(94643)},c=r(40345),u=r(34106).Buffer,p=(void 0!==r.g?r.g:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var h,f=r(75896);function m(){}function g(e,t){s=s||r(25382),e=e||{};var i=t instanceof s;this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var l=e.highWaterMark,d=e.writableHighWaterMark,c=this.objectMode?16:16384;this.highWaterMark=l||0===l?l:i&&(d||0===d)?d:c,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,i=r.sync,o=r.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,i,o){--t.pendingcb,r?(n.nextTick(o,i),n.nextTick(S,e,t),e._writableState.errorEmitted=!0,e.emit("error",i)):(o(i),e._writableState.errorEmitted=!0,e.emit("error",i),S(e,t))}(e,r,i,t,o);else{var s=_(r);s||r.corked||r.bufferProcessing||!r.bufferedRequest||w(e,r),i?a(b,e,r,s,o):b(e,r,s,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function y(e){if(s=s||r(25382),!(h.call(y,this)||this instanceof s))return new y(e);this._writableState=new g(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),c.call(this)}function v(e,t,r,i,n,o,s){t.writelen=i,t.writecb=s,t.writing=!0,t.sync=!0,r?e._writev(n,t.onwrite):e._write(n,o,t.onwrite),t.sync=!1}function b(e,t,r,i){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,i(),S(e,t)}function w(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var i=t.bufferedRequestCount,n=new Array(i),s=t.corkedRequestsFree;s.entry=r;for(var a=0,l=!0;r;)n[a]=r,r.isBuf||(l=!1),r=r.next,a+=1;n.allBuffers=l,v(e,t,!0,t.length,n,"",s.finish),t.pendingcb++,t.lastBufferedRequest=null,s.next?(t.corkedRequestsFree=s.next,s.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var d=r.chunk,c=r.encoding,u=r.callback;if(v(e,t,!1,t.objectMode?1:d.length,d,c,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function _(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function x(e,t){e._final((function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),S(e,t)}))}function S(e,t){var r=_(t);return r&&(!function(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,n.nextTick(x,e,t)):(t.prefinished=!0,e.emit("prefinish")))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}l.inherits(y,c),g.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(g.prototype,"buffer",{get:d.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(h=Function.prototype[Symbol.hasInstance],Object.defineProperty(y,Symbol.hasInstance,{value:function(e){return!!h.call(this,e)||this===y&&(e&&e._writableState instanceof g)}})):h=function(e){return e instanceof this},y.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},y.prototype.write=function(e,t,r){var i,o=this._writableState,s=!1,a=!o.objectMode&&(i=e,u.isBuffer(i)||i instanceof p);return a&&!u.isBuffer(e)&&(e=function(e){return u.from(e)}(e)),"function"==typeof t&&(r=t,t=null),a?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=m),o.ended?function(e,t){var r=new Error("write after end");e.emit("error",r),n.nextTick(t,r)}(this,r):(a||function(e,t,r,i){var o=!0,s=!1;return null===r?s=new TypeError("May not write null values to stream"):"string"==typeof r||void 0===r||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),n.nextTick(i,s),o=!1),o}(this,o,e,r))&&(o.pendingcb++,s=function(e,t,r,i,n,o){if(!r){var s=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=u.from(t,r));return t}(t,i,n);i!==s&&(r=!0,n="buffer",i=s)}var a=t.objectMode?1:i.length;t.length+=a;var l=t.length-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(y.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),y.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},y.prototype._writev=null,y.prototype.end=function(e,t,r){var i=this._writableState;"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),i.corked&&(i.corked=1,this.uncork()),i.ending||function(e,t,r){t.ending=!0,S(e,t),r&&(t.finished?n.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,i,r)},Object.defineProperty(y.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),y.prototype.destroy=f.destroy,y.prototype._undestroy=f.undestroy,y.prototype._destroy=function(e,t){this.end(),t(e)}},83222:(e,t,r)=>{"use strict";var i=r(34106).Buffer,n=r(15340);e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return i.alloc(0);for(var t,r,n,o=i.allocUnsafe(e>>>0),s=this.head,a=0;s;)t=s.data,r=o,n=a,t.copy(r,n),a+=s.data.length,s=s.next;return o},e}(),n&&n.inspect&&n.inspect.custom&&(e.exports.prototype[n.inspect.custom]=function(){var e=n.inspect({length:this.length});return this.constructor.name+" "+e})},75896:(e,t,r)=>{"use strict";var i=r(33225);function n(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,o=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return o||s?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.nextTick(n,this,e)):i.nextTick(n,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted||(r._writableState.errorEmitted=!0,i.nextTick(n,r,e)):i.nextTick(n,r,e):t&&t(e)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},40345:(e,t,r)=>{e.exports=r(37007).EventEmitter},34106:(e,t,r)=>{var i=r(48287),n=i.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return n(e,t,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=i:(o(i,t),t.Buffer=s),o(n,s),s.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return n(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var i=n(e);return void 0!==t?"string"==typeof r?i.fill(t,r):i.fill(t):i.fill(0),i},s.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},28399:(e,t,r)=>{(t=e.exports=r(45412)).Stream=t,t.Readable=t,t.Writable=r(16708),t.Duplex=r(25382),t.Transform=r(74610),t.PassThrough=r(63600)},66011:(e,t,r)=>{"use strict";var i=r(48287).Buffer,n=r(56698),o=r(4729),s=new Array(16),a=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],l=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],d=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],c=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],u=[0,1518500249,1859775393,2400959708,2840853838],p=[1352829926,1548603684,1836072691,2053994217,0];function h(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function f(e,t){return e<>>32-t}function m(e,t,r,i,n,o,s,a){return f(e+(t^r^i)+o+s|0,a)+n|0}function g(e,t,r,i,n,o,s,a){return f(e+(t&r|~t&i)+o+s|0,a)+n|0}function y(e,t,r,i,n,o,s,a){return f(e+((t|~r)^i)+o+s|0,a)+n|0}function v(e,t,r,i,n,o,s,a){return f(e+(t&i|r&~i)+o+s|0,a)+n|0}function b(e,t,r,i,n,o,s,a){return f(e+(t^(r|~i))+o+s|0,a)+n|0}n(h,o),h.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,i=0|this._b,n=0|this._c,o=0|this._d,h=0|this._e,w=0|this._a,_=0|this._b,x=0|this._c,S=0|this._d,k=0|this._e,E=0;E<80;E+=1){var T,B;E<16?(T=m(r,i,n,o,h,e[a[E]],u[0],d[E]),B=b(w,_,x,S,k,e[l[E]],p[0],c[E])):E<32?(T=g(r,i,n,o,h,e[a[E]],u[1],d[E]),B=v(w,_,x,S,k,e[l[E]],p[1],c[E])):E<48?(T=y(r,i,n,o,h,e[a[E]],u[2],d[E]),B=y(w,_,x,S,k,e[l[E]],p[2],c[E])):E<64?(T=v(r,i,n,o,h,e[a[E]],u[3],d[E]),B=g(w,_,x,S,k,e[l[E]],p[3],c[E])):(T=b(r,i,n,o,h,e[a[E]],u[4],d[E]),B=m(w,_,x,S,k,e[l[E]],p[4],c[E])),r=h,h=o,o=f(n,10),n=i,i=T,w=k,k=S,S=f(x,10),x=_,_=B}var C=this._b+n+S|0;this._b=this._c+o+k|0,this._c=this._d+h+w|0,this._d=this._e+r+_|0,this._e=this._a+i+x|0,this._a=C},h.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=i.alloc?i.alloc(20):new i(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=h},92861:(e,t,r)=>{ +/*! safe-buffer. MIT License. Feross Aboukhadijeh */ +var i=r(48287),n=i.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return n(e,t,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=i:(o(i,t),t.Buffer=s),s.prototype=Object.create(n.prototype),o(n,s),s.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return n(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var i=n(e);return void 0!==t?"string"==typeof r?i.fill(t,r):i.fill(t):i.fill(0),i},s.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},93904:(e,t,r)=>{const i=Symbol("SemVer ANY");class n{static get ANY(){return i}constructor(e,t){if(t=o(t),e instanceof n){if(e.loose===!!t.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),d("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===i?this.value="":this.value=this.operator+this.semver.version,d("comp",this)}parse(e){const t=this.options.loose?s[a.COMPARATORLOOSE]:s[a.COMPARATOR],r=e.match(t);if(!r)throw new TypeError(`Invalid comparator: ${e}`);this.operator=void 0!==r[1]?r[1]:"","="===this.operator&&(this.operator=""),r[2]?this.semver=new c(r[2],this.options.loose):this.semver=i}toString(){return this.value}test(e){if(d("Comparator.test",e,this.options.loose),this.semver===i||e===i)return!0;if("string"==typeof e)try{e=new c(e,this.options)}catch(e){return!1}return l(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof n))throw new TypeError("a Comparator is required");return""===this.operator?""===this.value||new u(e.value,t).test(this.value):""===e.operator?""===e.value||new u(this.value,t).test(e.semver):(!(t=o(t)).includePrerelease||"<0.0.0-0"!==this.value&&"<0.0.0-0"!==e.value)&&(!(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))&&(!(!this.operator.startsWith(">")||!e.operator.startsWith(">"))||(!(!this.operator.startsWith("<")||!e.operator.startsWith("<"))||(!(this.semver.version!==e.semver.version||!this.operator.includes("=")||!e.operator.includes("="))||(!!(l(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))||!!(l(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))))))}}e.exports=n;const o=r(98587),{safeRe:s,t:a}=r(99718),l=r(72111),d=r(57272),c=r(53908),u=r(78311)},78311:(e,t,r)=>{const i=/\s+/g;class n{constructor(e,t){if(t=s(t),e instanceof n)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new n(e.raw,t);if(e instanceof a)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(i," "),this.set=this.raw.split("||").map((e=>this.parseRange(e.trim()))).filter((e=>e.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter((e=>!y(e[0]))),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const e of this.set)if(1===e.length&&v(e[0])){this.set=[e];break}}this.formatted=void 0}get range(){if(void 0===this.formatted){this.formatted="";for(let e=0;e0&&(this.formatted+="||");const t=this.set[e];for(let e=0;e0&&(this.formatted+=" "),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){const t=((this.options.includePrerelease&&m)|(this.options.loose&&g))+":"+e,r=o.get(t);if(r)return r;const i=this.options.loose,n=i?c[u.HYPHENRANGELOOSE]:c[u.HYPHENRANGE];e=e.replace(n,A(this.options.includePrerelease)),l("hyphen replace",e),e=e.replace(c[u.COMPARATORTRIM],p),l("comparator trim",e),e=e.replace(c[u.TILDETRIM],h),l("tilde trim",e),e=e.replace(c[u.CARETTRIM],f),l("caret trim",e);let s=e.split(" ").map((e=>w(e,this.options))).join(" ").split(/\s+/).map((e=>I(e,this.options)));i&&(s=s.filter((e=>(l("loose invalid filter",e,this.options),!!e.match(c[u.COMPARATORLOOSE]))))),l("range list",s);const d=new Map,v=s.map((e=>new a(e,this.options)));for(const e of v){if(y(e))return[e];d.set(e.value,e)}d.size>1&&d.has("")&&d.delete("");const b=[...d.values()];return o.set(t,b),b}intersects(e,t){if(!(e instanceof n))throw new TypeError("a Range is required");return this.set.some((r=>b(r,t)&&e.set.some((e=>b(e,t)&&r.every((r=>e.every((e=>r.intersects(e,t)))))))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new d(e,this.options)}catch(e){return!1}for(let t=0;t"<0.0.0-0"===e.value,v=e=>""===e.value,b=(e,t)=>{let r=!0;const i=e.slice();let n=i.pop();for(;r&&i.length;)r=i.every((e=>n.intersects(e,t))),n=i.pop();return r},w=(e,t)=>(l("comp",e,t),e=k(e,t),l("caret",e),e=x(e,t),l("tildes",e),e=T(e,t),l("xrange",e),e=C(e,t),l("stars",e),e),_=e=>!e||"x"===e.toLowerCase()||"*"===e,x=(e,t)=>e.trim().split(/\s+/).map((e=>S(e,t))).join(" "),S=(e,t)=>{const r=t.loose?c[u.TILDELOOSE]:c[u.TILDE];return e.replace(r,((t,r,i,n,o)=>{let s;return l("tilde",e,t,r,i,n,o),_(r)?s="":_(i)?s=`>=${r}.0.0 <${+r+1}.0.0-0`:_(n)?s=`>=${r}.${i}.0 <${r}.${+i+1}.0-0`:o?(l("replaceTilde pr",o),s=`>=${r}.${i}.${n}-${o} <${r}.${+i+1}.0-0`):s=`>=${r}.${i}.${n} <${r}.${+i+1}.0-0`,l("tilde return",s),s}))},k=(e,t)=>e.trim().split(/\s+/).map((e=>E(e,t))).join(" "),E=(e,t)=>{l("caret",e,t);const r=t.loose?c[u.CARETLOOSE]:c[u.CARET],i=t.includePrerelease?"-0":"";return e.replace(r,((t,r,n,o,s)=>{let a;return l("caret",e,t,r,n,o,s),_(r)?a="":_(n)?a=`>=${r}.0.0${i} <${+r+1}.0.0-0`:_(o)?a="0"===r?`>=${r}.${n}.0${i} <${r}.${+n+1}.0-0`:`>=${r}.${n}.0${i} <${+r+1}.0.0-0`:s?(l("replaceCaret pr",s),a="0"===r?"0"===n?`>=${r}.${n}.${o}-${s} <${r}.${n}.${+o+1}-0`:`>=${r}.${n}.${o}-${s} <${r}.${+n+1}.0-0`:`>=${r}.${n}.${o}-${s} <${+r+1}.0.0-0`):(l("no pr"),a="0"===r?"0"===n?`>=${r}.${n}.${o}${i} <${r}.${n}.${+o+1}-0`:`>=${r}.${n}.${o}${i} <${r}.${+n+1}.0-0`:`>=${r}.${n}.${o} <${+r+1}.0.0-0`),l("caret return",a),a}))},T=(e,t)=>(l("replaceXRanges",e,t),e.split(/\s+/).map((e=>B(e,t))).join(" ")),B=(e,t)=>{e=e.trim();const r=t.loose?c[u.XRANGELOOSE]:c[u.XRANGE];return e.replace(r,((r,i,n,o,s,a)=>{l("xRange",e,r,i,n,o,s,a);const d=_(n),c=d||_(o),u=c||_(s),p=u;return"="===i&&p&&(i=""),a=t.includePrerelease?"-0":"",d?r=">"===i||"<"===i?"<0.0.0-0":"*":i&&p?(c&&(o=0),s=0,">"===i?(i=">=",c?(n=+n+1,o=0,s=0):(o=+o+1,s=0)):"<="===i&&(i="<",c?n=+n+1:o=+o+1),"<"===i&&(a="-0"),r=`${i+n}.${o}.${s}${a}`):c?r=`>=${n}.0.0${a} <${+n+1}.0.0-0`:u&&(r=`>=${n}.${o}.0${a} <${n}.${+o+1}.0-0`),l("xRange return",r),r}))},C=(e,t)=>(l("replaceStars",e,t),e.trim().replace(c[u.STAR],"")),I=(e,t)=>(l("replaceGTE0",e,t),e.trim().replace(c[t.includePrerelease?u.GTE0PRE:u.GTE0],"")),A=e=>(t,r,i,n,o,s,a,l,d,c,u,p)=>`${r=_(i)?"":_(n)?`>=${i}.0.0${e?"-0":""}`:_(o)?`>=${i}.${n}.0${e?"-0":""}`:s?`>=${r}`:`>=${r}${e?"-0":""}`} ${l=_(d)?"":_(c)?`<${+d+1}.0.0-0`:_(u)?`<${d}.${+c+1}.0-0`:p?`<=${d}.${c}.${u}-${p}`:e?`<${d}.${c}.${+u+1}-0`:`<=${l}`}`.trim(),F=(e,t,r)=>{for(let r=0;r0){const i=e[r].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}},53908:(e,t,r)=>{const i=r(57272),{MAX_LENGTH:n,MAX_SAFE_INTEGER:o}=r(16874),{safeRe:s,t:a}=r(99718),l=r(98587),{compareIdentifiers:d}=r(61123);class c{constructor(e,t){if(t=l(t),e instanceof c){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if("string"!=typeof e)throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>n)throw new TypeError(`version is longer than ${n} characters`);i("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const r=e.trim().match(t.loose?s[a.LOOSE]:s[a.FULL]);if(!r)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map((e=>{if(/^[0-9]+$/.test(e)){const t=+e;if(t>=0&&t=0;)"number"==typeof this.prerelease[i]&&(this.prerelease[i]++,i=-2);if(-1===i){if(t===this.prerelease.join(".")&&!1===r)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(t){let i=[t,e];!1===r&&(i=[t]),0===d(this.prerelease[0],t)?isNaN(this.prerelease[1])&&(this.prerelease=i):this.prerelease=i}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}e.exports=c},57414:(e,t,r)=>{const i=r(30144);e.exports=(e,t)=>{const r=i(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null}},72111:(e,t,r)=>{const i=r(94641),n=r(13999),o=r(35580),s=r(54089),a=r(7059),l=r(25200);e.exports=(e,t,r,d)=>{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return i(e,r,d);case"!=":return n(e,r,d);case">":return o(e,r,d);case">=":return s(e,r,d);case"<":return a(e,r,d);case"<=":return l(e,r,d);default:throw new TypeError(`Invalid operator: ${t}`)}}},46170:(e,t,r)=>{const i=r(53908),n=r(30144),{safeRe:o,t:s}=r(99718);e.exports=(e,t)=>{if(e instanceof i)return e;if("number"==typeof e&&(e=String(e)),"string"!=typeof e)return null;let r=null;if((t=t||{}).rtl){const i=t.includePrerelease?o[s.COERCERTLFULL]:o[s.COERCERTL];let n;for(;(n=i.exec(e))&&(!r||r.index+r[0].length!==e.length);)r&&n.index+n[0].length===r.index+r[0].length||(r=n),i.lastIndex=n.index+n[1].length+n[2].length;i.lastIndex=-1}else r=e.match(t.includePrerelease?o[s.COERCEFULL]:o[s.COERCE]);if(null===r)return null;const a=r[2],l=r[3]||"0",d=r[4]||"0",c=t.includePrerelease&&r[5]?`-${r[5]}`:"",u=t.includePrerelease&&r[6]?`+${r[6]}`:"";return n(`${a}.${l}.${d}${c}${u}`,t)}},40909:(e,t,r)=>{const i=r(53908);e.exports=(e,t,r)=>{const n=new i(e,r),o=new i(t,r);return n.compare(o)||n.compareBuild(o)}},11763:(e,t,r)=>{const i=r(50560);e.exports=(e,t)=>i(e,t,!0)},50560:(e,t,r)=>{const i=r(53908);e.exports=(e,t,r)=>new i(e,r).compare(new i(t,r))},51832:(e,t,r)=>{const i=r(30144);e.exports=(e,t)=>{const r=i(e,null,!0),n=i(t,null,!0),o=r.compare(n);if(0===o)return null;const s=o>0,a=s?r:n,l=s?n:r,d=!!a.prerelease.length;if(!!l.prerelease.length&&!d)return l.patch||l.minor?a.patch?"patch":a.minor?"minor":"major":"major";const c=d?"pre":"";return r.major!==n.major?c+"major":r.minor!==n.minor?c+"minor":r.patch!==n.patch?c+"patch":"prerelease"}},94641:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>0===i(e,t,r)},35580:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>i(e,t,r)>0},54089:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>i(e,t,r)>=0},93007:(e,t,r)=>{const i=r(53908);e.exports=(e,t,r,n,o)=>{"string"==typeof r&&(o=n,n=r,r=void 0);try{return new i(e instanceof i?e.version:e,r).inc(t,n,o).version}catch(e){return null}}},7059:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>i(e,t,r)<0},25200:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>i(e,t,r)<=0},32938:(e,t,r)=>{const i=r(53908);e.exports=(e,t)=>new i(e,t).major},46254:(e,t,r)=>{const i=r(53908);e.exports=(e,t)=>new i(e,t).minor},13999:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>0!==i(e,t,r)},30144:(e,t,r)=>{const i=r(53908);e.exports=(e,t,r=!1)=>{if(e instanceof i)return e;try{return new i(e,t)}catch(e){if(!r)return null;throw e}}},24493:(e,t,r)=>{const i=r(53908);e.exports=(e,t)=>new i(e,t).patch},31729:(e,t,r)=>{const i=r(30144);e.exports=(e,t)=>{const r=i(e,t);return r&&r.prerelease.length?r.prerelease:null}},9970:(e,t,r)=>{const i=r(50560);e.exports=(e,t,r)=>i(t,e,r)},74277:(e,t,r)=>{const i=r(40909);e.exports=(e,t)=>e.sort(((e,r)=>i(r,e,t)))},97638:(e,t,r)=>{const i=r(78311);e.exports=(e,t,r)=>{try{t=new i(t,r)}catch(e){return!1}return t.test(e)}},43927:(e,t,r)=>{const i=r(40909);e.exports=(e,t)=>e.sort(((e,r)=>i(e,r,t)))},56953:(e,t,r)=>{const i=r(30144);e.exports=(e,t)=>{const r=i(e,t);return r?r.version:null}},99589:(e,t,r)=>{const i=r(99718),n=r(16874),o=r(53908),s=r(61123),a=r(30144),l=r(56953),d=r(57414),c=r(93007),u=r(51832),p=r(32938),h=r(46254),f=r(24493),m=r(31729),g=r(50560),y=r(9970),v=r(11763),b=r(40909),w=r(43927),_=r(74277),x=r(35580),S=r(7059),k=r(94641),E=r(13999),T=r(54089),B=r(25200),C=r(72111),I=r(46170),A=r(93904),F=r(78311),M=r(97638),D=r(77631),R=r(19628),P=r(270),O=r(41261),z=r(13874),N=r(97075),q=r(75571),U=r(5342),L=r(76780),j=r(72525),H=r(75032);e.exports={parse:a,valid:l,clean:d,inc:c,diff:u,major:p,minor:h,patch:f,prerelease:m,compare:g,rcompare:y,compareLoose:v,compareBuild:b,sort:w,rsort:_,gt:x,lt:S,eq:k,neq:E,gte:T,lte:B,cmp:C,coerce:I,Comparator:A,Range:F,satisfies:M,toComparators:D,maxSatisfying:R,minSatisfying:P,minVersion:O,validRange:z,outside:N,gtr:q,ltr:U,intersects:L,simplifyRange:j,subset:H,SemVer:o,re:i.re,src:i.src,tokens:i.t,SEMVER_SPEC_VERSION:n.SEMVER_SPEC_VERSION,RELEASE_TYPES:n.RELEASE_TYPES,compareIdentifiers:s.compareIdentifiers,rcompareIdentifiers:s.rcompareIdentifiers}},16874:e=>{const t=Number.MAX_SAFE_INTEGER||9007199254740991;e.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:t,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}},57272:(e,t,r)=>{var i=r(65606);const n=("object"==typeof i&&i.env,()=>{});e.exports=n},61123:e=>{const t=/^[0-9]+$/,r=(e,r)=>{const i=t.test(e),n=t.test(r);return i&&n&&(e=+e,r=+r),e===r?0:i&&!n?-1:n&&!i?1:er(t,e)}},68794:e=>{e.exports=class{constructor(){this.max=1e3,this.map=new Map}get(e){const t=this.map.get(e);return void 0===t?void 0:(this.map.delete(e),this.map.set(e,t),t)}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&void 0!==t){if(this.map.size>=this.max){const e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}},98587:e=>{const t=Object.freeze({loose:!0}),r=Object.freeze({});e.exports=e=>e?"object"!=typeof e?t:e:r},99718:(e,t,r)=>{const{MAX_SAFE_COMPONENT_LENGTH:i,MAX_SAFE_BUILD_LENGTH:n,MAX_LENGTH:o}=r(16874),s=r(57272),a=(t=e.exports={}).re=[],l=t.safeRe=[],d=t.src=[],c=t.t={};let u=0;const p="[a-zA-Z0-9-]",h=[["\\s",1],["\\d",o],[p,n]],f=(e,t,r)=>{const i=(e=>{for(const[t,r]of h)e=e.split(`${t}*`).join(`${t}{0,${r}}`).split(`${t}+`).join(`${t}{1,${r}}`);return e})(t),n=u++;s(e,n,t),c[e]=n,d[n]=t,a[n]=new RegExp(t,r?"g":void 0),l[n]=new RegExp(i,r?"g":void 0)};f("NUMERICIDENTIFIER","0|[1-9]\\d*"),f("NUMERICIDENTIFIERLOOSE","\\d+"),f("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${p}*`),f("MAINVERSION",`(${d[c.NUMERICIDENTIFIER]})\\.(${d[c.NUMERICIDENTIFIER]})\\.(${d[c.NUMERICIDENTIFIER]})`),f("MAINVERSIONLOOSE",`(${d[c.NUMERICIDENTIFIERLOOSE]})\\.(${d[c.NUMERICIDENTIFIERLOOSE]})\\.(${d[c.NUMERICIDENTIFIERLOOSE]})`),f("PRERELEASEIDENTIFIER",`(?:${d[c.NUMERICIDENTIFIER]}|${d[c.NONNUMERICIDENTIFIER]})`),f("PRERELEASEIDENTIFIERLOOSE",`(?:${d[c.NUMERICIDENTIFIERLOOSE]}|${d[c.NONNUMERICIDENTIFIER]})`),f("PRERELEASE",`(?:-(${d[c.PRERELEASEIDENTIFIER]}(?:\\.${d[c.PRERELEASEIDENTIFIER]})*))`),f("PRERELEASELOOSE",`(?:-?(${d[c.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${d[c.PRERELEASEIDENTIFIERLOOSE]})*))`),f("BUILDIDENTIFIER",`${p}+`),f("BUILD",`(?:\\+(${d[c.BUILDIDENTIFIER]}(?:\\.${d[c.BUILDIDENTIFIER]})*))`),f("FULLPLAIN",`v?${d[c.MAINVERSION]}${d[c.PRERELEASE]}?${d[c.BUILD]}?`),f("FULL",`^${d[c.FULLPLAIN]}$`),f("LOOSEPLAIN",`[v=\\s]*${d[c.MAINVERSIONLOOSE]}${d[c.PRERELEASELOOSE]}?${d[c.BUILD]}?`),f("LOOSE",`^${d[c.LOOSEPLAIN]}$`),f("GTLT","((?:<|>)?=?)"),f("XRANGEIDENTIFIERLOOSE",`${d[c.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),f("XRANGEIDENTIFIER",`${d[c.NUMERICIDENTIFIER]}|x|X|\\*`),f("XRANGEPLAIN",`[v=\\s]*(${d[c.XRANGEIDENTIFIER]})(?:\\.(${d[c.XRANGEIDENTIFIER]})(?:\\.(${d[c.XRANGEIDENTIFIER]})(?:${d[c.PRERELEASE]})?${d[c.BUILD]}?)?)?`),f("XRANGEPLAINLOOSE",`[v=\\s]*(${d[c.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[c.XRANGEIDENTIFIERLOOSE]})(?:\\.(${d[c.XRANGEIDENTIFIERLOOSE]})(?:${d[c.PRERELEASELOOSE]})?${d[c.BUILD]}?)?)?`),f("XRANGE",`^${d[c.GTLT]}\\s*${d[c.XRANGEPLAIN]}$`),f("XRANGELOOSE",`^${d[c.GTLT]}\\s*${d[c.XRANGEPLAINLOOSE]}$`),f("COERCEPLAIN",`(^|[^\\d])(\\d{1,${i}})(?:\\.(\\d{1,${i}}))?(?:\\.(\\d{1,${i}}))?`),f("COERCE",`${d[c.COERCEPLAIN]}(?:$|[^\\d])`),f("COERCEFULL",d[c.COERCEPLAIN]+`(?:${d[c.PRERELEASE]})?`+`(?:${d[c.BUILD]})?(?:$|[^\\d])`),f("COERCERTL",d[c.COERCE],!0),f("COERCERTLFULL",d[c.COERCEFULL],!0),f("LONETILDE","(?:~>?)"),f("TILDETRIM",`(\\s*)${d[c.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",f("TILDE",`^${d[c.LONETILDE]}${d[c.XRANGEPLAIN]}$`),f("TILDELOOSE",`^${d[c.LONETILDE]}${d[c.XRANGEPLAINLOOSE]}$`),f("LONECARET","(?:\\^)"),f("CARETTRIM",`(\\s*)${d[c.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",f("CARET",`^${d[c.LONECARET]}${d[c.XRANGEPLAIN]}$`),f("CARETLOOSE",`^${d[c.LONECARET]}${d[c.XRANGEPLAINLOOSE]}$`),f("COMPARATORLOOSE",`^${d[c.GTLT]}\\s*(${d[c.LOOSEPLAIN]})$|^$`),f("COMPARATOR",`^${d[c.GTLT]}\\s*(${d[c.FULLPLAIN]})$|^$`),f("COMPARATORTRIM",`(\\s*)${d[c.GTLT]}\\s*(${d[c.LOOSEPLAIN]}|${d[c.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",f("HYPHENRANGE",`^\\s*(${d[c.XRANGEPLAIN]})\\s+-\\s+(${d[c.XRANGEPLAIN]})\\s*$`),f("HYPHENRANGELOOSE",`^\\s*(${d[c.XRANGEPLAINLOOSE]})\\s+-\\s+(${d[c.XRANGEPLAINLOOSE]})\\s*$`),f("STAR","(<|>)?=?\\s*\\*"),f("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),f("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},75571:(e,t,r)=>{const i=r(97075);e.exports=(e,t,r)=>i(e,t,">",r)},76780:(e,t,r)=>{const i=r(78311);e.exports=(e,t,r)=>(e=new i(e,r),t=new i(t,r),e.intersects(t,r))},5342:(e,t,r)=>{const i=r(97075);e.exports=(e,t,r)=>i(e,t,"<",r)},19628:(e,t,r)=>{const i=r(53908),n=r(78311);e.exports=(e,t,r)=>{let o=null,s=null,a=null;try{a=new n(t,r)}catch(e){return null}return e.forEach((e=>{a.test(e)&&(o&&-1!==s.compare(e)||(o=e,s=new i(o,r)))})),o}},270:(e,t,r)=>{const i=r(53908),n=r(78311);e.exports=(e,t,r)=>{let o=null,s=null,a=null;try{a=new n(t,r)}catch(e){return null}return e.forEach((e=>{a.test(e)&&(o&&1!==s.compare(e)||(o=e,s=new i(o,r)))})),o}},41261:(e,t,r)=>{const i=r(53908),n=r(78311),o=r(35580);e.exports=(e,t)=>{e=new n(e,t);let r=new i("0.0.0");if(e.test(r))return r;if(r=new i("0.0.0-0"),e.test(r))return r;r=null;for(let t=0;t{const t=new i(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":s&&!o(t,s)||(s=t);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${e.operator}`)}})),!s||r&&!o(r,s)||(r=s)}return r&&e.test(r)?r:null}},97075:(e,t,r)=>{const i=r(53908),n=r(93904),{ANY:o}=n,s=r(78311),a=r(97638),l=r(35580),d=r(7059),c=r(25200),u=r(54089);e.exports=(e,t,r,p)=>{let h,f,m,g,y;switch(e=new i(e,p),t=new s(t,p),r){case">":h=l,f=c,m=d,g=">",y=">=";break;case"<":h=d,f=u,m=l,g="<",y="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(a(e,t,p))return!1;for(let r=0;r{e.semver===o&&(e=new n(">=0.0.0")),s=s||e,a=a||e,h(e.semver,s.semver,p)?s=e:m(e.semver,a.semver,p)&&(a=e)})),s.operator===g||s.operator===y)return!1;if((!a.operator||a.operator===g)&&f(e,a.semver))return!1;if(a.operator===y&&m(e,a.semver))return!1}return!0}},72525:(e,t,r)=>{const i=r(97638),n=r(50560);e.exports=(e,t,r)=>{const o=[];let s=null,a=null;const l=e.sort(((e,t)=>n(e,t,r)));for(const e of l){i(e,t,r)?(a=e,s||(s=e)):(a&&o.push([s,a]),a=null,s=null)}s&&o.push([s,null]);const d=[];for(const[e,t]of o)e===t?d.push(e):t||e!==l[0]?t?e===l[0]?d.push(`<=${t}`):d.push(`${e} - ${t}`):d.push(`>=${e}`):d.push("*");const c=d.join(" || "),u="string"==typeof t.raw?t.raw:String(t);return c.length{const i=r(78311),n=r(93904),{ANY:o}=n,s=r(97638),a=r(50560),l=[new n(">=0.0.0-0")],d=[new n(">=0.0.0")],c=(e,t,r)=>{if(e===t)return!0;if(1===e.length&&e[0].semver===o){if(1===t.length&&t[0].semver===o)return!0;e=r.includePrerelease?l:d}if(1===t.length&&t[0].semver===o){if(r.includePrerelease)return!0;t=d}const i=new Set;let n,c,h,f,m,g,y;for(const t of e)">"===t.operator||">="===t.operator?n=u(n,t,r):"<"===t.operator||"<="===t.operator?c=p(c,t,r):i.add(t.semver);if(i.size>1)return null;if(n&&c){if(h=a(n.semver,c.semver,r),h>0)return null;if(0===h&&(">="!==n.operator||"<="!==c.operator))return null}for(const e of i){if(n&&!s(e,String(n),r))return null;if(c&&!s(e,String(c),r))return null;for(const i of t)if(!s(e,String(i),r))return!1;return!0}let v=!(!c||r.includePrerelease||!c.semver.prerelease.length)&&c.semver,b=!(!n||r.includePrerelease||!n.semver.prerelease.length)&&n.semver;v&&1===v.prerelease.length&&"<"===c.operator&&0===v.prerelease[0]&&(v=!1);for(const e of t){if(y=y||">"===e.operator||">="===e.operator,g=g||"<"===e.operator||"<="===e.operator,n)if(b&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===b.major&&e.semver.minor===b.minor&&e.semver.patch===b.patch&&(b=!1),">"===e.operator||">="===e.operator){if(f=u(n,e,r),f===e&&f!==n)return!1}else if(">="===n.operator&&!s(n.semver,String(e),r))return!1;if(c)if(v&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===v.major&&e.semver.minor===v.minor&&e.semver.patch===v.patch&&(v=!1),"<"===e.operator||"<="===e.operator){if(m=p(c,e,r),m===e&&m!==c)return!1}else if("<="===c.operator&&!s(c.semver,String(e),r))return!1;if(!e.operator&&(c||n)&&0!==h)return!1}return!(n&&g&&!c&&0!==h)&&(!(c&&y&&!n&&0!==h)&&(!b&&!v))},u=(e,t,r)=>{if(!e)return t;const i=a(e.semver,t.semver,r);return i>0?e:i<0||">"===t.operator&&">="===e.operator?t:e},p=(e,t,r)=>{if(!e)return t;const i=a(e.semver,t.semver,r);return i<0?e:i>0||"<"===t.operator&&"<="===e.operator?t:e};e.exports=(e,t,r={})=>{if(e===t)return!0;e=new i(e,r),t=new i(t,r);let n=!1;e:for(const i of e.set){for(const e of t.set){const t=c(i,e,r);if(n=n||null!==t,t)continue e}if(n)return!1}return!0}},77631:(e,t,r)=>{const i=r(78311);e.exports=(e,t)=>new i(e,t).set.map((e=>e.map((e=>e.value)).join(" ").trim().split(" ")))},13874:(e,t,r)=>{const i=r(78311);e.exports=(e,t)=>{try{return new i(e,t).range||"*"}catch(e){return null}}},96897:(e,t,r)=>{"use strict";var i=r(70453),n=r(30041),o=r(30592)(),s=r(75795),a=r(69675),l=i("%Math.floor%");e.exports=function(e,t){if("function"!=typeof e)throw new a("`fn` is not a function");if("number"!=typeof t||t<0||t>4294967295||l(t)!==t)throw new a("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],i=!0,d=!0;if("length"in e&&s){var c=s(e,"length");c&&!c.configurable&&(i=!1),c&&!c.writable&&(d=!1)}return(i||d||!r)&&(o?n(e,"length",t,!0,!0):n(e,"length",t)),e}},90392:(e,t,r)=>{var i=r(92861).Buffer;function n(e,t){this._block=i.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}n.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=i.from(e,t));for(var r=this._block,n=this._blockSize,o=e.length,s=this._len,a=0;a=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var i=(4294967295&r)>>>0,n=(r-i)/4294967296;this._block.writeUInt32BE(n,this._blockSize-8),this._block.writeUInt32BE(i,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=n},62802:(e,t,r)=>{var i=e.exports=function(e){e=e.toLowerCase();var t=i[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t};i.sha=r(27816),i.sha1=r(63737),i.sha224=r(26710),i.sha256=r(24107),i.sha384=r(32827),i.sha512=r(82890)},27816:(e,t,r)=>{var i=r(56698),n=r(90392),o=r(92861).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],a=new Array(80);function l(){this.init(),this._w=a,n.call(this,64,56)}function d(e){return e<<30|e>>>2}function c(e,t,r,i){return 0===e?t&r|~t&i:2===e?t&r|t&i|r&i:t^r^i}i(l,n),l.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},l.prototype._update=function(e){for(var t,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,a=0|this._d,l=0|this._e,u=0;u<16;++u)r[u]=e.readInt32BE(4*u);for(;u<80;++u)r[u]=r[u-3]^r[u-8]^r[u-14]^r[u-16];for(var p=0;p<80;++p){var h=~~(p/20),f=0|((t=i)<<5|t>>>27)+c(h,n,o,a)+l+r[p]+s[h];l=a,a=o,o=d(n),n=i,i=f}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=a+this._d|0,this._e=l+this._e|0},l.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=l},63737:(e,t,r)=>{var i=r(56698),n=r(90392),o=r(92861).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],a=new Array(80);function l(){this.init(),this._w=a,n.call(this,64,56)}function d(e){return e<<5|e>>>27}function c(e){return e<<30|e>>>2}function u(e,t,r,i){return 0===e?t&r|~t&i:2===e?t&r|t&i|r&i:t^r^i}i(l,n),l.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},l.prototype._update=function(e){for(var t,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,a=0|this._d,l=0|this._e,p=0;p<16;++p)r[p]=e.readInt32BE(4*p);for(;p<80;++p)r[p]=(t=r[p-3]^r[p-8]^r[p-14]^r[p-16])<<1|t>>>31;for(var h=0;h<80;++h){var f=~~(h/20),m=d(i)+u(f,n,o,a)+l+r[h]+s[f]|0;l=a,a=o,o=c(n),n=i,i=m}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=a+this._d|0,this._e=l+this._e|0},l.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=l},26710:(e,t,r)=>{var i=r(56698),n=r(24107),o=r(90392),s=r(92861).Buffer,a=new Array(64);function l(){this.init(),this._w=a,o.call(this,64,56)}i(l,n),l.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},l.prototype._hash=function(){var e=s.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=l},24107:(e,t,r)=>{var i=r(56698),n=r(90392),o=r(92861).Buffer,s=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],a=new Array(64);function l(){this.init(),this._w=a,n.call(this,64,56)}function d(e,t,r){return r^e&(t^r)}function c(e,t,r){return e&t|r&(e|t)}function u(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function p(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function h(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}i(l,n),l.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},l.prototype._update=function(e){for(var t,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,a=0|this._d,l=0|this._e,f=0|this._f,m=0|this._g,g=0|this._h,y=0;y<16;++y)r[y]=e.readInt32BE(4*y);for(;y<64;++y)r[y]=0|(((t=r[y-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[y-7]+h(r[y-15])+r[y-16];for(var v=0;v<64;++v){var b=g+p(l)+d(l,f,m)+s[v]+r[v]|0,w=u(i)+c(i,n,o)|0;g=m,m=f,f=l,l=a+b|0,a=o,o=n,n=i,i=b+w|0}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=a+this._d|0,this._e=l+this._e|0,this._f=f+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},l.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=l},32827:(e,t,r)=>{var i=r(56698),n=r(82890),o=r(90392),s=r(92861).Buffer,a=new Array(160);function l(){this.init(),this._w=a,o.call(this,128,112)}i(l,n),l.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},l.prototype._hash=function(){var e=s.allocUnsafe(48);function t(t,r,i){e.writeInt32BE(t,i),e.writeInt32BE(r,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=l},82890:(e,t,r)=>{var i=r(56698),n=r(90392),o=r(92861).Buffer,s=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],a=new Array(160);function l(){this.init(),this._w=a,n.call(this,128,112)}function d(e,t,r){return r^e&(t^r)}function c(e,t,r){return e&t|r&(e|t)}function u(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function p(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function h(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function f(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function g(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function y(e,t){return e>>>0>>0?1:0}i(l,n),l.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},l.prototype._update=function(e){for(var t=this._w,r=0|this._ah,i=0|this._bh,n=0|this._ch,o=0|this._dh,a=0|this._eh,l=0|this._fh,v=0|this._gh,b=0|this._hh,w=0|this._al,_=0|this._bl,x=0|this._cl,S=0|this._dl,k=0|this._el,E=0|this._fl,T=0|this._gl,B=0|this._hl,C=0;C<32;C+=2)t[C]=e.readInt32BE(4*C),t[C+1]=e.readInt32BE(4*C+4);for(;C<160;C+=2){var I=t[C-30],A=t[C-30+1],F=h(I,A),M=f(A,I),D=m(I=t[C-4],A=t[C-4+1]),R=g(A,I),P=t[C-14],O=t[C-14+1],z=t[C-32],N=t[C-32+1],q=M+O|0,U=F+P+y(q,M)|0;U=(U=U+D+y(q=q+R|0,R)|0)+z+y(q=q+N|0,N)|0,t[C]=U,t[C+1]=q}for(var L=0;L<160;L+=2){U=t[L],q=t[L+1];var j=c(r,i,n),H=c(w,_,x),$=u(r,w),G=u(w,r),W=p(a,k),K=p(k,a),V=s[L],J=s[L+1],Y=d(a,l,v),Q=d(k,E,T),Z=B+K|0,X=b+W+y(Z,B)|0;X=(X=(X=X+Y+y(Z=Z+Q|0,Q)|0)+V+y(Z=Z+J|0,J)|0)+U+y(Z=Z+q|0,q)|0;var ee=G+H|0,te=$+j+y(ee,G)|0;b=v,B=T,v=l,T=E,l=a,E=k,a=o+X+y(k=S+Z|0,S)|0,o=n,S=x,n=i,x=_,i=r,_=w,r=X+te+y(w=Z+ee|0,Z)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+x|0,this._dl=this._dl+S|0,this._el=this._el+k|0,this._fl=this._fl+E|0,this._gl=this._gl+T|0,this._hl=this._hl+B|0,this._ah=this._ah+r+y(this._al,w)|0,this._bh=this._bh+i+y(this._bl,_)|0,this._ch=this._ch+n+y(this._cl,x)|0,this._dh=this._dh+o+y(this._dl,S)|0,this._eh=this._eh+a+y(this._el,k)|0,this._fh=this._fh+l+y(this._fl,E)|0,this._gh=this._gh+v+y(this._gl,T)|0,this._hh=this._hh+b+y(this._hl,B)|0},l.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,r,i){e.writeInt32BE(t,i),e.writeInt32BE(r,i+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=l},920:(e,t,r)=>{"use strict";var i=r(70453),n=r(38075),o=r(58859),s=r(69675),a=i("%WeakMap%",!0),l=i("%Map%",!0),d=n("WeakMap.prototype.get",!0),c=n("WeakMap.prototype.set",!0),u=n("WeakMap.prototype.has",!0),p=n("Map.prototype.get",!0),h=n("Map.prototype.set",!0),f=n("Map.prototype.has",!0),m=function(e,t){for(var r,i=e;null!==(r=i.next);i=r)if(r.key===t)return i.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,i={assert:function(e){if(!i.has(e))throw new s("Side channel does not contain "+o(e))},get:function(i){if(a&&i&&("object"==typeof i||"function"==typeof i)){if(e)return d(e,i)}else if(l){if(t)return p(t,i)}else if(r)return function(e,t){var r=m(e,t);return r&&r.value}(r,i)},has:function(i){if(a&&i&&("object"==typeof i||"function"==typeof i)){if(e)return u(e,i)}else if(l){if(t)return f(t,i)}else if(r)return function(e,t){return!!m(e,t)}(r,i);return!1},set:function(i,n){a&&i&&("object"==typeof i||"function"==typeof i)?(e||(e=new a),c(e,i,n)):l?(t||(t=new l),h(t,i,n)):(r||(r={key:{},next:null}),function(e,t,r){var i=m(e,t);i?i.value=r:e.next={key:t,next:e.next,value:r}}(r,i,n))}};return i}},88310:(e,t,r)=>{e.exports=n;var i=r(37007).EventEmitter;function n(){i.call(this)}r(56698)(n,i),n.Readable=r(46891),n.Writable=r(81999),n.Duplex=r(88101),n.Transform=r(59083),n.PassThrough=r(3681),n.finished=r(14257),n.pipeline=r(5267),n.Stream=n,n.prototype.pipe=function(e,t){var r=this;function n(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",n),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",a),r.on("close",l));var s=!1;function a(){s||(s=!0,e.end())}function l(){s||(s=!0,"function"==typeof e.destroy&&e.destroy())}function d(e){if(c(),0===i.listenerCount(this,"error"))throw e}function c(){r.removeListener("data",n),e.removeListener("drain",o),r.removeListener("end",a),r.removeListener("close",l),r.removeListener("error",d),e.removeListener("error",d),r.removeListener("end",c),r.removeListener("close",c),e.removeListener("close",c)}return r.on("error",d),e.on("error",d),r.on("end",c),r.on("close",c),e.on("close",c),e.emit("pipe",r),e}},12463:e=>{"use strict";var t={};function r(e,r,i){i||(i=Error);var n=function(e){var t,i;function n(t,i,n){return e.call(this,function(e,t,i){return"string"==typeof r?r:r(e,t,i)}(t,i,n))||this}return i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i,n}(i);n.prototype.name=i.name,n.prototype.code=e,t[e]=n}function i(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}r("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),r("ERR_INVALID_ARG_TYPE",(function(e,t,r){var n,o,s,a;if("string"==typeof t&&(o="not ",t.substr(!s||s<0?0:+s,o.length)===o)?(n="must not be",t=t.replace(/^not /,"")):n="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))a="The ".concat(e," ").concat(n," ").concat(i(t,"type"));else{var l=function(e,t,r){return"number"!=typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";a='The "'.concat(e,'" ').concat(l," ").concat(n," ").concat(i(t,"type"))}return a+=". Received type ".concat(typeof r)}),TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.F=t},88101:(e,t,r)=>{"use strict";var i=r(65606),n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=c;var o=r(46891),s=r(81999);r(56698)(c,o);for(var a=n(s.prototype),l=0;l{"use strict";e.exports=n;var i=r(59083);function n(e){if(!(this instanceof n))return new n(e);i.call(this,e)}r(56698)(n,i),n.prototype._transform=function(e,t,r){r(null,e)}},46891:(e,t,r)=>{"use strict";var i,n=r(65606);e.exports=E,E.ReadableState=k;r(37007).EventEmitter;var o=function(e,t){return e.listeners(t).length},s=r(41396),a=r(48287).Buffer,l=(void 0!==r.g?r.g:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var d,c=r(99580);d=c&&c.debuglog?c.debuglog("stream"):function(){};var u,p,h,f=r(81766),m=r(54347),g=r(66644).getHighWaterMark,y=r(12463).F,v=y.ERR_INVALID_ARG_TYPE,b=y.ERR_STREAM_PUSH_AFTER_EOF,w=y.ERR_METHOD_NOT_IMPLEMENTED,_=y.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(56698)(E,s);var x=m.errorOrDestroy,S=["error","close","destroy","pause","resume"];function k(e,t,n){i=i||r(88101),e=e||{},"boolean"!=typeof n&&(n=t instanceof i),this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=g(this,e,"readableHighWaterMark",n),this.buffer=new f,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(u||(u=r(83141).I),this.decoder=new u(e.encoding),this.encoding=e.encoding)}function E(e){if(i=i||r(88101),!(this instanceof E))return new E(e);var t=this instanceof i;this._readableState=new k(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),s.call(this)}function T(e,t,r,i,n){d("readableAddChunk",t);var o,s=e._readableState;if(null===t)s.reading=!1,function(e,t){if(d("onEofChunk"),t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?A(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,F(e)))}(e,s);else if(n||(o=function(e,t){var r;i=t,a.isBuffer(i)||i instanceof l||"string"==typeof t||void 0===t||e.objectMode||(r=new v("chunk",["string","Buffer","Uint8Array"],t));var i;return r}(s,t)),o)x(e,o);else if(s.objectMode||t&&t.length>0)if("string"==typeof t||s.objectMode||Object.getPrototypeOf(t)===a.prototype||(t=function(e){return a.from(e)}(t)),i)s.endEmitted?x(e,new _):B(e,s,t,!0);else if(s.ended)x(e,new b);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(t=s.decoder.write(t),s.objectMode||0!==t.length?B(e,s,t,!1):M(e,s)):B(e,s,t,!1)}else i||(s.reading=!1,M(e,s));return!s.ended&&(s.lengtht.highWaterMark&&(t.highWaterMark=function(e){return e>=C?e=C:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function A(e){var t=e._readableState;d("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(d("emitReadable",t.flowing),t.emittedReadable=!0,n.nextTick(F,e))}function F(e){var t=e._readableState;d("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,z(e)}function M(e,t){t.readingMore||(t.readingMore=!0,n.nextTick(D,e,t))}function D(e,t){for(;!t.reading&&!t.ended&&(t.length0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function P(e){d("readable nexttick read 0"),e.read(0)}function O(e,t){d("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),z(e),t.flowing&&!t.reading&&e.read(0)}function z(e){var t=e._readableState;for(d("flow",t.flowing);t.flowing&&null!==e.read(););}function N(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r);var r}function q(e){var t=e._readableState;d("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,n.nextTick(U,t,e))}function U(e,t){if(d("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function L(e,t){for(var r=0,i=e.length;r=t.highWaterMark:t.length>0)||t.ended))return d("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?q(this):A(this),null;if(0===(e=I(e,t))&&t.ended)return 0===t.length&&q(this),null;var i,n=t.needReadable;return d("need readable",n),(0===t.length||t.length-e0?N(e,t):null)?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&q(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){x(this,new w("_read()"))},E.prototype.pipe=function(e,t){var r=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=e;break;case 1:i.pipes=[i.pipes,e];break;default:i.pipes.push(e)}i.pipesCount+=1,d("pipe count=%d opts=%j",i.pipesCount,t);var s=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?l:g;function a(t,n){d("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,d("cleanup"),e.removeListener("close",f),e.removeListener("finish",m),e.removeListener("drain",c),e.removeListener("error",h),e.removeListener("unpipe",a),r.removeListener("end",l),r.removeListener("end",g),r.removeListener("data",p),u=!0,!i.awaitDrain||e._writableState&&!e._writableState.needDrain||c())}function l(){d("onend"),e.end()}i.endEmitted?n.nextTick(s):r.once("end",s),e.on("unpipe",a);var c=function(e){return function(){var t=e._readableState;d("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&o(e,"data")&&(t.flowing=!0,z(e))}}(r);e.on("drain",c);var u=!1;function p(t){d("ondata");var n=e.write(t);d("dest.write",n),!1===n&&((1===i.pipesCount&&i.pipes===e||i.pipesCount>1&&-1!==L(i.pipes,e))&&!u&&(d("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function h(t){d("onerror",t),g(),e.removeListener("error",h),0===o(e,"error")&&x(e,t)}function f(){e.removeListener("finish",m),g()}function m(){d("onfinish"),e.removeListener("close",f),g()}function g(){d("unpipe"),r.unpipe(e)}return r.on("data",p),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",h),e.once("close",f),e.once("finish",m),e.emit("pipe",r),i.flowing||(d("pipe resume"),r.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var i=t.pipes,n=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,d("on readable",i.length,i.reading),i.length?A(this):i.reading||n.nextTick(P,this))),r},E.prototype.addListener=E.prototype.on,E.prototype.removeListener=function(e,t){var r=s.prototype.removeListener.call(this,e,t);return"readable"===e&&n.nextTick(R,this),r},E.prototype.removeAllListeners=function(e){var t=s.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||n.nextTick(R,this),t},E.prototype.resume=function(){var e=this._readableState;return e.flowing||(d("resume"),e.flowing=!e.readableListening,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,n.nextTick(O,e,t))}(this,e)),e.paused=!1,this},E.prototype.pause=function(){return d("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(d("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},E.prototype.wrap=function(e){var t=this,r=this._readableState,i=!1;for(var n in e.on("end",(function(){if(d("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)})),e.on("data",(function(n){(d("wrapped data"),r.decoder&&(n=r.decoder.write(n)),r.objectMode&&null==n)||(r.objectMode||n&&n.length)&&(t.push(n)||(i=!0,e.pause()))})),e)void 0===this[n]&&"function"==typeof e[n]&&(this[n]=function(t){return function(){return e[t].apply(e,arguments)}}(n));for(var o=0;o{"use strict";e.exports=c;var i=r(12463).F,n=i.ERR_METHOD_NOT_IMPLEMENTED,o=i.ERR_MULTIPLE_CALLBACK,s=i.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=i.ERR_TRANSFORM_WITH_LENGTH_0,l=r(88101);function d(e,t){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(null===i)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),i(e);var n=this._readableState;n.reading=!1,(n.needReadable||n.length{"use strict";var i,n=r(65606);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var i=e.entry;e.entry=null;for(;i;){var n=i.callback;t.pendingcb--,n(r),i=i.next}t.corkedRequestsFree.next=e}(t,e)}}e.exports=E,E.WritableState=k;var s={deprecate:r(94643)},a=r(41396),l=r(48287).Buffer,d=(void 0!==r.g?r.g:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{}).Uint8Array||function(){};var c,u=r(54347),p=r(66644).getHighWaterMark,h=r(12463).F,f=h.ERR_INVALID_ARG_TYPE,m=h.ERR_METHOD_NOT_IMPLEMENTED,g=h.ERR_MULTIPLE_CALLBACK,y=h.ERR_STREAM_CANNOT_PIPE,v=h.ERR_STREAM_DESTROYED,b=h.ERR_STREAM_NULL_VALUES,w=h.ERR_STREAM_WRITE_AFTER_END,_=h.ERR_UNKNOWN_ENCODING,x=u.errorOrDestroy;function S(){}function k(e,t,s){i=i||r(88101),e=e||{},"boolean"!=typeof s&&(s=t instanceof i),this.objectMode=!!e.objectMode,s&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=p(this,e,"writableHighWaterMark",s),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var a=!1===e.decodeStrings;this.decodeStrings=!a,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,i=r.sync,o=r.writecb;if("function"!=typeof o)throw new g;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,i,o){--t.pendingcb,r?(n.nextTick(o,i),n.nextTick(F,e,t),e._writableState.errorEmitted=!0,x(e,i)):(o(i),e._writableState.errorEmitted=!0,x(e,i),F(e,t))}(e,r,i,t,o);else{var s=I(r)||e.destroyed;s||r.corked||r.bufferProcessing||!r.bufferedRequest||C(e,r),i?n.nextTick(B,e,r,s,o):B(e,r,s,o)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function E(e){var t=this instanceof(i=i||r(88101));if(!t&&!c.call(E,this))return new E(e);this._writableState=new k(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),a.call(this)}function T(e,t,r,i,n,o,s){t.writelen=i,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new v("write")):r?e._writev(n,t.onwrite):e._write(n,o,t.onwrite),t.sync=!1}function B(e,t,r,i){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,i(),F(e,t)}function C(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var i=t.bufferedRequestCount,n=new Array(i),s=t.corkedRequestsFree;s.entry=r;for(var a=0,l=!0;r;)n[a]=r,r.isBuf||(l=!1),r=r.next,a+=1;n.allBuffers=l,T(e,t,!0,t.length,n,"",s.finish),t.pendingcb++,t.lastBufferedRequest=null,s.next?(t.corkedRequestsFree=s.next,s.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var d=r.chunk,c=r.encoding,u=r.callback;if(T(e,t,!1,t.objectMode?1:d.length,d,c,u),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function I(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function A(e,t){e._final((function(r){t.pendingcb--,r&&x(e,r),t.prefinished=!0,e.emit("prefinish"),F(e,t)}))}function F(e,t){var r=I(t);if(r&&(function(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,n.nextTick(A,e,t)))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var i=e._readableState;(!i||i.autoDestroy&&i.endEmitted)&&e.destroy()}return r}r(56698)(E,a),k.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(k.prototype,"buffer",{get:s.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(c=Function.prototype[Symbol.hasInstance],Object.defineProperty(E,Symbol.hasInstance,{value:function(e){return!!c.call(this,e)||this===E&&(e&&e._writableState instanceof k)}})):c=function(e){return e instanceof this},E.prototype.pipe=function(){x(this,new y)},E.prototype.write=function(e,t,r){var i,o=this._writableState,s=!1,a=!o.objectMode&&(i=e,l.isBuffer(i)||i instanceof d);return a&&!l.isBuffer(e)&&(e=function(e){return l.from(e)}(e)),"function"==typeof t&&(r=t,t=null),a?t="buffer":t||(t=o.defaultEncoding),"function"!=typeof r&&(r=S),o.ending?function(e,t){var r=new w;x(e,r),n.nextTick(t,r)}(this,r):(a||function(e,t,r,i){var o;return null===r?o=new b:"string"==typeof r||t.objectMode||(o=new f("chunk",["string","Buffer"],r)),!o||(x(e,o),n.nextTick(i,o),!1)}(this,o,e,r))&&(o.pendingcb++,s=function(e,t,r,i,n,o){if(!r){var s=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=l.from(t,r));return t}(t,i,n);i!==s&&(r=!0,n="buffer",i=s)}var a=t.objectMode?1:i.length;t.length+=a;var d=t.length-1))throw new _(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(E.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(E.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),E.prototype._write=function(e,t,r){r(new m("_write()"))},E.prototype._writev=null,E.prototype.end=function(e,t,r){var i=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),i.corked&&(i.corked=1,this.uncork()),i.ending||function(e,t,r){t.ending=!0,F(e,t),r&&(t.finished?n.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,i,r),this},Object.defineProperty(E.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(E.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),E.prototype.destroy=u.destroy,E.prototype._undestroy=u.undestroy,E.prototype._destroy=function(e,t){t(e)}},65034:(e,t,r)=>{"use strict";var i,n=r(65606);function o(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,t||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var s=r(14257),a=Symbol("lastResolve"),l=Symbol("lastReject"),d=Symbol("error"),c=Symbol("ended"),u=Symbol("lastPromise"),p=Symbol("handlePromise"),h=Symbol("stream");function f(e,t){return{value:e,done:t}}function m(e){var t=e[a];if(null!==t){var r=e[h].read();null!==r&&(e[u]=null,e[a]=null,e[l]=null,t(f(r,!1)))}}function g(e){n.nextTick(m,e)}var y=Object.getPrototypeOf((function(){})),v=Object.setPrototypeOf((o(i={get stream(){return this[h]},next:function(){var e=this,t=this[d];if(null!==t)return Promise.reject(t);if(this[c])return Promise.resolve(f(void 0,!0));if(this[h].destroyed)return new Promise((function(t,r){n.nextTick((function(){e[d]?r(e[d]):t(f(void 0,!0))}))}));var r,i=this[u];if(i)r=new Promise(function(e,t){return function(r,i){e.then((function(){t[c]?r(f(void 0,!0)):t[p](r,i)}),i)}}(i,this));else{var o=this[h].read();if(null!==o)return Promise.resolve(f(o,!1));r=new Promise(this[p])}return this[u]=r,r}},Symbol.asyncIterator,(function(){return this})),o(i,"return",(function(){var e=this;return new Promise((function(t,r){e[h].destroy(null,(function(e){e?r(e):t(f(void 0,!0))}))}))})),i),y);e.exports=function(e){var t,r=Object.create(v,(o(t={},h,{value:e,writable:!0}),o(t,a,{value:null,writable:!0}),o(t,l,{value:null,writable:!0}),o(t,d,{value:null,writable:!0}),o(t,c,{value:e._readableState.endEmitted,writable:!0}),o(t,p,{value:function(e,t){var i=r[h].read();i?(r[u]=null,r[a]=null,r[l]=null,e(f(i,!1))):(r[a]=e,r[l]=t)},writable:!0}),t));return r[u]=null,s(e,(function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[l];return null!==t&&(r[u]=null,r[a]=null,r[l]=null,t(e)),void(r[d]=e)}var i=r[a];null!==i&&(r[u]=null,r[a]=null,r[l]=null,i(f(void 0,!0))),r[c]=!0})),e.on("readable",g.bind(null,r)),r}},81766:(e,t,r)=>{"use strict";function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,i)}return r}function n(e){for(var t=1;t0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return l.alloc(0);for(var t,r,i,n=l.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=n,i=s,l.prototype.copy.call(t,r,i),s+=o.data.length,o=o.next;return n}},{key:"consume",value:function(e,t){var r;return en.length?n.length:e;if(o===n.length?i+=n:i+=n.slice(0,e),0==(e-=o)){o===n.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=n.slice(o));break}++r}return this.length-=r,i}},{key:"_getBuffer",value:function(e){var t=l.allocUnsafe(e),r=this.head,i=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var n=r.data,o=e>n.length?n.length:e;if(n.copy(t,t.length-e,0,o),0==(e-=o)){o===n.length?(++i,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=n.slice(o));break}++i}return this.length-=i,t}},{key:c,value:function(e,t){return d(this,n(n({},t),{},{depth:0,customInspect:!1}))}}],r&&s(t.prototype,r),i&&s(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}()},54347:(e,t,r)=>{"use strict";var i=r(65606);function n(e,t){s(e,t),o(e)}function o(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function s(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,a=this._readableState&&this._readableState.destroyed,l=this._writableState&&this._writableState.destroyed;return a||l?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.nextTick(s,this,e)):i.nextTick(s,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,(function(e){!t&&e?r._writableState?r._writableState.errorEmitted?i.nextTick(o,r):(r._writableState.errorEmitted=!0,i.nextTick(n,r,e)):i.nextTick(n,r,e):t?(i.nextTick(o,r),t(e)):i.nextTick(o,r)})),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(e,t){var r=e._readableState,i=e._writableState;r&&r.autoDestroy||i&&i.autoDestroy?e.destroy(t):e.emit("error",t)}}},14257:(e,t,r)=>{"use strict";var i=r(12463).F.ERR_STREAM_PREMATURE_CLOSE;function n(){}e.exports=function e(t,r,o){if("function"==typeof r)return e(t,null,r);r||(r={}),o=function(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,i=new Array(r),n=0;n{e.exports=function(){throw new Error("Readable.from is not available in the browser")}},5267:(e,t,r)=>{"use strict";var i;var n=r(12463).F,o=n.ERR_MISSING_ARGS,s=n.ERR_STREAM_DESTROYED;function a(e){if(e)throw e}function l(e){e()}function d(e,t){return e.pipe(t)}e.exports=function(){for(var e=arguments.length,t=new Array(e),n=0;n0,(function(e){c||(c=e),e&&p.forEach(l),o||(p.forEach(l),u(c))}))}));return t.reduce(d)}},66644:(e,t,r)=>{"use strict";var i=r(12463).F.ERR_INVALID_OPT_VALUE;e.exports={getHighWaterMark:function(e,t,r,n){var o=function(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}(t,n,r);if(null!=o){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new i(n?r:"highWaterMark",o);return Math.floor(o)}return e.objectMode?16:16384}}},41396:(e,t,r)=>{e.exports=r(37007).EventEmitter},83141:(e,t,r)=>{"use strict";var i=r(15003).Buffer,n=i.isEncoding||function(e){switch((e=""+e)&&e.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!0;default:return!1}};function o(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(i.isEncoding===n||!n(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=l,this.end=d,t=4;break;case"utf8":this.fillLast=a,t=4;break;case"base64":this.text=c,this.end=u,t=3;break;default:return this.write=p,void(this.end=h)}this.lastNeed=0,this.lastTotal=0,this.lastChar=i.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function a(e){var t=this.lastTotal-this.lastNeed,r=function(e,t){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function l(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function d(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function c(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function u(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function p(e){return e.toString(this.encoding)}function h(e){return e&&e.length?this.write(e):""}t.I=o,o.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return n>0&&(e.lastNeed=n-1),n;if(--i=0)return n>0&&(e.lastNeed=n-2),n;if(--i=0)return n>0&&(2===n?n=0:e.lastNeed=n-3),n;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var i=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,i),e.toString("utf8",t,i)},o.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},15003:(e,t,r)=>{var i=r(48287),n=i.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return n(e,t,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=i:(o(i,t),t.Buffer=s),o(n,s),s.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return n(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var i=n(e);return void 0!==t?"string"==typeof r?i.fill(t,r):i.fill(t):i.fill(0),i},s.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},17983:e=>{const t=/^[-+]?0x[a-fA-F0-9]+$/,r=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const i={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};e.exports=function(e,n={}){if(n=Object.assign({},i,n),!e||"string"!=typeof e)return e;let o=e.trim();if(void 0!==n.skipLike&&n.skipLike.test(o))return e;if(n.hex&&t.test(o))return Number.parseInt(o,16);{const t=r.exec(o);if(t){const r=t[1],i=t[2];let s=function(e){if(e&&-1!==e.indexOf("."))return"."===(e=e.replace(/0+$/,""))?e="0":"."===e[0]?e="0"+e:"."===e[e.length-1]&&(e=e.substr(0,e.length-1)),e;return e}(t[3]);const a=t[4]||t[6];if(!n.leadingZeros&&i.length>0&&r&&"."!==o[2])return e;if(!n.leadingZeros&&i.length>0&&!r&&"."!==o[1])return e;{const t=Number(o),l=""+t;return-1!==l.search(/[eE]/)||a?n.eNotation?t:e:-1!==o.indexOf(".")?"0"===l&&""===s||l===s||r&&l==="-"+s?t:e:i?s===l||r+s===l?t:e:o===l||o===r+l?t:e}}return e}}},51380:e=>{"use strict";function t(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);"Object"===i&&e.constructor&&(i=e.constructor.name);if("Map"===i||"Set"===i)return Array.from(e);if("Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r{"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}var n;"undefined"!=typeof window?n=window:"undefined"==typeof self?(console.warn("Using browser-only version of superagent in non-browser environment"),n=void 0):n=self;var o=r(5971),s=r(78463),a=r(31948),l=r(85125),d=r(19450),c=r(51380);function u(){}e.exports=function(e,r){return"function"==typeof r?new t.Request("GET",e).end(r):1===arguments.length?new t.Request("GET",e):new t.Request(e,r)};var p=t=e.exports;t.Request=b,p.getXHR=function(){if(n.XMLHttpRequest&&(!n.location||"file:"!==n.location.protocol||!n.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}throw new Error("Browser-only version of superagent could not find XHR")};var h="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};function f(e){if(!l(e))return e;var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&m(t,r,e[r]);return t.join("&")}function m(e,t,r){if(void 0!==r)if(null!==r)if(Array.isArray(r))r.forEach((function(r){m(e,t,r)}));else if(l(r))for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&m(e,"".concat(t,"[").concat(i,"]"),r[i]);else e.push(encodeURI(t)+"="+encodeURIComponent(r));else e.push(encodeURI(t))}function g(e){for(var t,r,i={},n=e.split("&"),o=0,s=n.length;o0||e instanceof Object)?t(e):null)},v.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,i="cannot ".concat(t," ").concat(r," (").concat(this.status,")"),n=new Error(i);return n.status=this.status,n.method=t,n.url=r,n},p.Response=v,o(b.prototype),a(b.prototype),b.prototype.type=function(e){return this.set("Content-Type",p.types[e]||e),this},b.prototype.accept=function(e){return this.set("Accept",p.types[e]||e),this},b.prototype.auth=function(e,t,r){1===arguments.length&&(t=""),"object"===i(t)&&null!==t&&(r=t,t=""),r||(r={type:"function"==typeof btoa?"basic":"auto"});return this._auth(e,t,r,(function(e){if("function"==typeof btoa)return btoa(e);throw new Error("Cannot use basic auth, btoa is not a function")}))},b.prototype.query=function(e){return"string"!=typeof e&&(e=f(e)),e&&this._query.push(e),this},b.prototype.attach=function(e,t,r){if(t){if(this._data)throw new Error("superagent can't mix .send() and .attach()");this._getFormData().append(e,t,r||t.name)}return this},b.prototype._getFormData=function(){return this._formData||(this._formData=new n.FormData),this._formData},b.prototype.callback=function(e,t){if(this._shouldRetry(e,t))return this._retry();var r=this._callback;this.clearTimeout(),e&&(this._maxRetries&&(e.retries=this._retries-1),this.emit("error",e)),r(e,t)},b.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},b.prototype.agent=function(){return console.warn("This is not supported in browser version of superagent"),this},b.prototype.ca=b.prototype.agent,b.prototype.buffer=b.prototype.ca,b.prototype.write=function(){throw new Error("Streaming is not supported in browser version of superagent")},b.prototype.pipe=b.prototype.write,b.prototype._isHost=function(e){return e&&"object"===i(e)&&!Array.isArray(e)&&"[object Object]"!==Object.prototype.toString.call(e)},b.prototype.end=function(e){this._endCalled&&console.warn("Warning: .end() was called twice. This is not supported in superagent"),this._endCalled=!0,this._callback=e||u,this._finalizeQueryString(),this._end()},b.prototype._setUploadTimeout=function(){var e=this;this._uploadTimeout&&!this._uploadTimeoutTimer&&(this._uploadTimeoutTimer=setTimeout((function(){e._timeoutError("Upload timeout of ",e._uploadTimeout,"ETIMEDOUT")}),this._uploadTimeout))},b.prototype._end=function(){if(this._aborted)return this.callback(new Error("The request has been aborted even before .end() was called"));var e=this;this.xhr=p.getXHR();var t=this.xhr,r=this._formData||this._data;this._setTimeouts(),t.onreadystatechange=function(){var r=t.readyState;if(r>=2&&e._responseTimeoutTimer&&clearTimeout(e._responseTimeoutTimer),4===r){var i;try{i=t.status}catch(e){i=0}if(!i){if(e.timedout||e._aborted)return;return e.crossDomainError()}e.emit("end")}};var i=function(t,r){r.total>0&&(r.percent=r.loaded/r.total*100,100===r.percent&&clearTimeout(e._uploadTimeoutTimer)),r.direction=t,e.emit("progress",r)};if(this.hasListeners("progress"))try{t.addEventListener("progress",i.bind(null,"download")),t.upload&&t.upload.addEventListener("progress",i.bind(null,"upload"))}catch(e){}t.upload&&this._setUploadTimeout();try{this.username&&this.password?t.open(this.method,this.url,!0,this.username,this.password):t.open(this.method,this.url,!0)}catch(e){return this.callback(e)}if(this._withCredentials&&(t.withCredentials=!0),!this._formData&&"GET"!==this.method&&"HEAD"!==this.method&&"string"!=typeof r&&!this._isHost(r)){var n=this._header["content-type"],o=this._serializer||p.serialize[n?n.split(";")[0]:""];!o&&y(n)&&(o=p.serialize["application/json"]),o&&(r=o(r))}for(var s in this.header)null!==this.header[s]&&Object.prototype.hasOwnProperty.call(this.header,s)&&t.setRequestHeader(s,this.header[s]);this._responseType&&(t.responseType=this._responseType),this.emit("request",this),t.send(void 0===r?null:r)},p.agent=function(){return new c},["GET","POST","OPTIONS","PATCH","PUT","DELETE"].forEach((function(e){c.prototype[e.toLowerCase()]=function(t,r){var i=new p.Request(e,t);return this._setDefaults(i),r&&i.end(r),i}})),c.prototype.del=c.prototype.delete,p.get=function(e,t,r){var i=p("GET",e);return"function"==typeof t&&(r=t,t=null),t&&i.query(t),r&&i.end(r),i},p.head=function(e,t,r){var i=p("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&i.query(t),r&&i.end(r),i},p.options=function(e,t,r){var i=p("OPTIONS",e);return"function"==typeof t&&(r=t,t=null),t&&i.send(t),r&&i.end(r),i},p.del=w,p.delete=w,p.patch=function(e,t,r){var i=p("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&i.send(t),r&&i.end(r),i},p.post=function(e,t,r){var i=p("POST",e);return"function"==typeof t&&(r=t,t=null),t&&i.send(t),r&&i.end(r),i},p.put=function(e,t,r){var i=p("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&i.send(t),r&&i.end(r),i}},85125:e=>{"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}e.exports=function(e){return null!==e&&"object"===t(e)}},31948:(e,t,r)=>{"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}var n=r(85125);function o(e){if(e)return function(e){for(var t in o.prototype)Object.prototype.hasOwnProperty.call(o.prototype,t)&&(e[t]=o.prototype[t]);return e}(e)}e.exports=o,o.prototype.clearTimeout=function(){return clearTimeout(this._timer),clearTimeout(this._responseTimeoutTimer),clearTimeout(this._uploadTimeoutTimer),delete this._timer,delete this._responseTimeoutTimer,delete this._uploadTimeoutTimer,this},o.prototype.parse=function(e){return this._parser=e,this},o.prototype.responseType=function(e){return this._responseType=e,this},o.prototype.serialize=function(e){return this._serializer=e,this},o.prototype.timeout=function(e){if(!e||"object"!==i(e))return this._timeout=e,this._responseTimeout=0,this._uploadTimeout=0,this;for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))switch(t){case"deadline":this._timeout=e.deadline;break;case"response":this._responseTimeout=e.response;break;case"upload":this._uploadTimeout=e.upload;break;default:console.warn("Unknown timeout option",t)}return this},o.prototype.retry=function(e,t){return 0!==arguments.length&&!0!==e||(e=1),e<=0&&(e=0),this._maxRetries=e,this._retries=0,this._retryCallback=t,this};var s=["ECONNRESET","ETIMEDOUT","EADDRINFO","ESOCKETTIMEDOUT"];o.prototype._shouldRetry=function(e,t){if(!this._maxRetries||this._retries++>=this._maxRetries)return!1;if(this._retryCallback)try{var r=this._retryCallback(e,t);if(!0===r)return!0;if(!1===r)return!1}catch(e){console.error(e)}if(t&&t.status&&t.status>=500&&501!==t.status)return!0;if(e){if(e.code&&s.includes(e.code))return!0;if(e.timeout&&"ECONNABORTED"===e.code)return!0;if(e.crossDomain)return!0}return!1},o.prototype._retry=function(){return this.clearTimeout(),this.req&&(this.req=null,this.req=this.request()),this._aborted=!1,this.timedout=!1,this.timedoutError=null,this._end()},o.prototype.then=function(e,t){var r=this;if(!this._fullfilledPromise){var i=this;this._endCalled&&console.warn("Warning: superagent request was sent twice, because both .end() and .then() were called. Never call .end() if you use promises"),this._fullfilledPromise=new Promise((function(e,t){i.on("abort",(function(){if(!(r._maxRetries&&r._maxRetries>r._retries))if(r.timedout&&r.timedoutError)t(r.timedoutError);else{var e=new Error("Aborted");e.code="ABORTED",e.status=r.status,e.method=r.method,e.url=r.url,t(e)}})),i.end((function(r,i){r?t(r):e(i)}))}))}return this._fullfilledPromise.then(e,t)},o.prototype.catch=function(e){return this.then(void 0,e)},o.prototype.use=function(e){return e(this),this},o.prototype.ok=function(e){if("function"!=typeof e)throw new Error("Callback required");return this._okCallback=e,this},o.prototype._isResponseOK=function(e){return!!e&&(this._okCallback?this._okCallback(e):e.status>=200&&e.status<300)},o.prototype.get=function(e){return this._header[e.toLowerCase()]},o.prototype.getHeader=o.prototype.get,o.prototype.set=function(e,t){if(n(e)){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},o.prototype.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},o.prototype.field=function(e,t){if(null==e)throw new Error(".field(name, val) name can not be empty");if(this._data)throw new Error(".field() can't be used if .send() is used. Please use only .send() or only .field() & .attach()");if(n(e)){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&this.field(r,e[r]);return this}if(Array.isArray(t)){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&this.field(e,t[i]);return this}if(null==t)throw new Error(".field(name, val) val can not be empty");return"boolean"==typeof t&&(t=String(t)),this._getFormData().append(e,t),this},o.prototype.abort=function(){return this._aborted||(this._aborted=!0,this.xhr&&this.xhr.abort(),this.req&&this.req.abort(),this.clearTimeout(),this.emit("abort")),this},o.prototype._auth=function(e,t,r,i){switch(r.type){case"basic":this.set("Authorization","Basic ".concat(i("".concat(e,":").concat(t))));break;case"auto":this.username=e,this.password=t;break;case"bearer":this.set("Authorization","Bearer ".concat(e))}return this},o.prototype.withCredentials=function(e){return void 0===e&&(e=!0),this._withCredentials=e,this},o.prototype.redirects=function(e){return this._maxRedirects=e,this},o.prototype.maxResponseSize=function(e){if("number"!=typeof e)throw new TypeError("Invalid argument");return this._maxResponseSize=e,this},o.prototype.toJSON=function(){return{method:this.method,url:this.url,data:this._data,headers:this._header}},o.prototype.send=function(e){var t=n(e),r=this._header["content-type"];if(this._formData)throw new Error(".send() can't be used if .attach() or .field() is used. Please use only .send() or only .field() & .attach()");if(t&&!this._data)Array.isArray(e)?this._data=[]:this._isHost(e)||(this._data={});else if(e&&this._data&&this._isHost(this._data))throw new Error("Can't merge these send calls");if(t&&n(this._data))for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(this._data[i]=e[i]);else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],this._data="application/x-www-form-urlencoded"===r?this._data?"".concat(this._data,"&").concat(e):e:(this._data||"")+e):this._data=e;return!t||this._isHost(e)||r||this.type("json"),this},o.prototype.sortQuery=function(e){return this._sort=void 0===e||e,this},o.prototype._finalizeQueryString=function(){var e=this._query.join("&");if(e&&(this.url+=(this.url.includes("?")?"&":"?")+e),this._query.length=0,this._sort){var t=this.url.indexOf("?");if(t>=0){var r=this.url.slice(t+1).split("&");"function"==typeof this._sort?r.sort(this._sort):r.sort(),this.url=this.url.slice(0,t)+"?"+r.join("&")}}},o.prototype._appendQueryString=function(){console.warn("Unsupported")},o.prototype._timeoutError=function(e,t,r){if(!this._aborted){var i=new Error("".concat(e+t,"ms exceeded"));i.timeout=t,i.code="ECONNABORTED",i.errno=r,this.timedout=!0,this.timedoutError=i,this.abort(),this.callback(i)}},o.prototype._setTimeouts=function(){var e=this;this._timeout&&!this._timer&&(this._timer=setTimeout((function(){e._timeoutError("Timeout of ",e._timeout,"ETIME")}),this._timeout)),this._responseTimeout&&!this._responseTimeoutTimer&&(this._responseTimeoutTimer=setTimeout((function(){e._timeoutError("Response timeout of ",e._responseTimeout,"ETIMEDOUT")}),this._responseTimeout))}},19450:(e,t,r)=>{"use strict";var i=r(33048);function n(e){if(e)return function(e){for(var t in n.prototype)Object.prototype.hasOwnProperty.call(n.prototype,t)&&(e[t]=n.prototype[t]);return e}(e)}e.exports=n,n.prototype.get=function(e){return this.header[e.toLowerCase()]},n.prototype._setHeaderProperties=function(e){var t=e["content-type"]||"";this.type=i.type(t);var r=i.params(t);for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(this[n]=r[n]);this.links={};try{e.link&&(this.links=i.parseLinks(e.link))}catch(e){}},n.prototype._setStatusProperties=function(e){var t=e/100|0;this.statusCode=e,this.status=this.statusCode,this.statusType=t,this.info=1===t,this.ok=2===t,this.redirect=3===t,this.clientError=4===t,this.serverError=5===t,this.error=(4===t||5===t)&&this.toError(),this.created=201===e,this.accepted=202===e,this.noContent=204===e,this.badRequest=400===e,this.unauthorized=401===e,this.notAcceptable=406===e,this.forbidden=403===e,this.notFound=404===e,this.unprocessableEntity=422===e}},33048:(e,t)=>{"use strict";t.type=function(e){return e.split(/ *; */).shift()},t.params=function(e){return e.split(/ *; */).reduce((function(e,t){var r=t.split(/ *= */),i=r.shift(),n=r.shift();return i&&n&&(e[i]=n),e}),{})},t.parseLinks=function(e){return e.split(/ *, */).reduce((function(e,t){var r=t.split(/ *; */),i=r[0].slice(1,-1);return e[r[1].split(/ *= */)[1].slice(1,-1)]=i,e}),{})},t.cleanHeader=function(e,t){return delete e["content-type"],delete e["content-length"],delete e["transfer-encoding"],delete e.host,t&&(delete e.authorization,delete e.cookie),e}},61270:function(e,t,r){var i;/*! https://mths.be/punycode v1.4.1 by @mathias */e=r.nmd(e),function(){t&&t.nodeType,e&&e.nodeType;var n="object"==typeof r.g&&r.g;n.global!==n&&n.window!==n&&n.self;var o,s=2147483647,a=36,l=/^xn--/,d=/[^\x20-\x7E]/,c=/[\x2E\u3002\uFF0E\uFF61]/g,u={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},p=Math.floor,h=String.fromCharCode;function f(e){throw new RangeError(u[e])}function m(e,t){for(var r=e.length,i=[];r--;)i[r]=t(e[r]);return i}function g(e,t){var r=e.split("@"),i="";return r.length>1&&(i=r[0]+"@",e=r[1]),i+m((e=e.replace(c,".")).split("."),t).join(".")}function y(e){for(var t,r,i=[],n=0,o=e.length;n=55296&&t<=56319&&n65535&&(t+=h((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=h(e)})).join("")}function b(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function w(e,t,r){var i=0;for(e=r?p(e/700):e>>1,e+=p(e/t);e>455;i+=a)e=p(e/35);return p(i+36*e/(e+38))}function _(e){var t,r,i,n,o,l,d,c,u,h,m,g=[],y=e.length,b=0,_=128,x=72;for((r=e.lastIndexOf("-"))<0&&(r=0),i=0;i=128&&f("not-basic"),g.push(e.charCodeAt(i));for(n=r>0?r+1:0;n=y&&f("invalid-input"),((c=(m=e.charCodeAt(n++))-48<10?m-22:m-65<26?m-65:m-97<26?m-97:a)>=a||c>p((s-b)/l))&&f("overflow"),b+=c*l,!(c<(u=d<=x?1:d>=x+26?26:d-x));d+=a)l>p(s/(h=a-u))&&f("overflow"),l*=h;x=w(b-o,t=g.length+1,0==o),p(b/t)>s-_&&f("overflow"),_+=p(b/t),b%=t,g.splice(b++,0,_)}return v(g)}function x(e){var t,r,i,n,o,l,d,c,u,m,g,v,_,x,S,k=[];for(v=(e=y(e)).length,t=128,r=0,o=72,l=0;l=t&&gp((s-r)/(_=i+1))&&f("overflow"),r+=(d-t)*_,t=d,l=0;ls&&f("overflow"),g==t){for(c=r,u=a;!(c<(m=u<=o?1:u>=o+26?26:u-o));u+=a)S=c-m,x=a-m,k.push(h(b(m+S%x,0))),c=p(S/x);k.push(h(b(c,0))),o=w(r,_,i==n),r=0,++i}++r,++t}return k.join("")}o={version:"1.4.1",ucs2:{decode:y,encode:v},decode:_,encode:x,toASCII:function(e){return g(e,(function(e){return d.test(e)?"xn--"+x(e):e}))},toUnicode:function(e){return g(e,(function(e){return l.test(e)?_(e.slice(4).toLowerCase()):e}))}},void 0===(i=function(){return o}.call(t,r,t,e))||(e.exports=i)}()},88835:(e,t,r)=>{"use strict";var i=r(61270);function n(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var o=/^([a-z0-9.+-]+:)/i,s=/:[0-9]*$/,a=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,l=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),d=["'"].concat(l),c=["%","/","?",";","#"].concat(d),u=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,h=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,f={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},g={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},y=r(55373);function v(e,t,r){if(e&&"object"==typeof e&&e instanceof n)return e;var i=new n;return i.parse(e,t,r),i}n.prototype.parse=function(e,t,r){if("string"!=typeof e)throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var n=e.indexOf("?"),s=-1!==n&&n127?M+="x":M+=F[D];if(!M.match(p)){var P=I.slice(0,T),O=I.slice(T+1),z=F.match(h);z&&(P.push(z[1]),O.unshift(z[2])),O.length&&(v="/"+O.join(".")+v),this.hostname=P.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),C||(this.hostname=i.toASCII(this.hostname));var N=this.port?":"+this.port:"",q=this.hostname||"";this.host=q+N,this.href+=this.host,C&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==v[0]&&(v="/"+v))}if(!f[_])for(T=0,A=d.length;T0)&&r.host.split("@"))&&(r.auth=C.shift(),r.hostname=C.shift(),r.host=r.hostname);return r.search=e.search,r.query=e.query,null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!x.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var k=x.slice(-1)[0],E=(r.host||e.host||x.length>1)&&("."===k||".."===k)||""===k,T=0,B=x.length;B>=0;B--)"."===(k=x[B])?x.splice(B,1):".."===k?(x.splice(B,1),T++):T&&(x.splice(B,1),T--);if(!w&&!_)for(;T--;T)x.unshift("..");!w||""===x[0]||x[0]&&"/"===x[0].charAt(0)||x.unshift(""),E&&"/"!==x.join("/").substr(-1)&&x.push("");var C,I=""===x[0]||x[0]&&"/"===x[0].charAt(0);S&&(r.hostname=I?"":x.length?x.shift():"",r.host=r.hostname,(C=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=C.shift(),r.hostname=C.shift(),r.host=r.hostname));return(w=w||r.host&&x.length)&&!I&&x.unshift(""),x.length>0?r.pathname=x.join("/"):(r.pathname=null,r.path=null),null===r.pathname&&null===r.search||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},n.prototype.parseHost=function(){var e=this.host,t=s.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.parse=v,t.resolve=function(e,t){return v(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?v(e,!1,!0).resolveObject(t):t},t.format=function(e){return"string"==typeof e&&(e=v(e)),e instanceof n?e.format():n.prototype.format.call(e)},t.Url=n},94643:(e,t,r)=>{function i(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=function(e,t){if(i("noDeprecation"))return e;var r=!1;return function(){if(!r){if(i("throwDeprecation"))throw new Error(t);i("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}},81135:e=>{e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},49032:(e,t,r)=>{"use strict";var i=r(47244),n=r(48184),o=r(25767),s=r(35680);function a(e){return e.call.bind(e)}var l="undefined"!=typeof BigInt,d="undefined"!=typeof Symbol,c=a(Object.prototype.toString),u=a(Number.prototype.valueOf),p=a(String.prototype.valueOf),h=a(Boolean.prototype.valueOf);if(l)var f=a(BigInt.prototype.valueOf);if(d)var m=a(Symbol.prototype.valueOf);function g(e,t){if("object"!=typeof e)return!1;try{return t(e),!0}catch(e){return!1}}function y(e){return"[object Map]"===c(e)}function v(e){return"[object Set]"===c(e)}function b(e){return"[object WeakMap]"===c(e)}function w(e){return"[object WeakSet]"===c(e)}function _(e){return"[object ArrayBuffer]"===c(e)}function x(e){return"undefined"!=typeof ArrayBuffer&&(_.working?_(e):e instanceof ArrayBuffer)}function S(e){return"[object DataView]"===c(e)}function k(e){return"undefined"!=typeof DataView&&(S.working?S(e):e instanceof DataView)}t.isArgumentsObject=i,t.isGeneratorFunction=n,t.isTypedArray=s,t.isPromise=function(e){return"undefined"!=typeof Promise&&e instanceof Promise||null!==e&&"object"==typeof e&&"function"==typeof e.then&&"function"==typeof e.catch},t.isArrayBufferView=function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):s(e)||k(e)},t.isUint8Array=function(e){return"Uint8Array"===o(e)},t.isUint8ClampedArray=function(e){return"Uint8ClampedArray"===o(e)},t.isUint16Array=function(e){return"Uint16Array"===o(e)},t.isUint32Array=function(e){return"Uint32Array"===o(e)},t.isInt8Array=function(e){return"Int8Array"===o(e)},t.isInt16Array=function(e){return"Int16Array"===o(e)},t.isInt32Array=function(e){return"Int32Array"===o(e)},t.isFloat32Array=function(e){return"Float32Array"===o(e)},t.isFloat64Array=function(e){return"Float64Array"===o(e)},t.isBigInt64Array=function(e){return"BigInt64Array"===o(e)},t.isBigUint64Array=function(e){return"BigUint64Array"===o(e)},y.working="undefined"!=typeof Map&&y(new Map),t.isMap=function(e){return"undefined"!=typeof Map&&(y.working?y(e):e instanceof Map)},v.working="undefined"!=typeof Set&&v(new Set),t.isSet=function(e){return"undefined"!=typeof Set&&(v.working?v(e):e instanceof Set)},b.working="undefined"!=typeof WeakMap&&b(new WeakMap),t.isWeakMap=function(e){return"undefined"!=typeof WeakMap&&(b.working?b(e):e instanceof WeakMap)},w.working="undefined"!=typeof WeakSet&&w(new WeakSet),t.isWeakSet=function(e){return w(e)},_.working="undefined"!=typeof ArrayBuffer&&_(new ArrayBuffer),t.isArrayBuffer=x,S.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&S(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=k;var E="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function T(e){return"[object SharedArrayBuffer]"===c(e)}function B(e){return void 0!==E&&(void 0===T.working&&(T.working=T(new E)),T.working?T(e):e instanceof E)}function C(e){return g(e,u)}function I(e){return g(e,p)}function A(e){return g(e,h)}function F(e){return l&&g(e,f)}function M(e){return d&&g(e,m)}t.isSharedArrayBuffer=B,t.isAsyncFunction=function(e){return"[object AsyncFunction]"===c(e)},t.isMapIterator=function(e){return"[object Map Iterator]"===c(e)},t.isSetIterator=function(e){return"[object Set Iterator]"===c(e)},t.isGeneratorObject=function(e){return"[object Generator]"===c(e)},t.isWebAssemblyCompiledModule=function(e){return"[object WebAssembly.Module]"===c(e)},t.isNumberObject=C,t.isStringObject=I,t.isBooleanObject=A,t.isBigIntObject=F,t.isSymbolObject=M,t.isBoxedPrimitive=function(e){return C(e)||I(e)||A(e)||F(e)||M(e)},t.isAnyArrayBuffer=function(e){return"undefined"!=typeof Uint8Array&&(x(e)||B(e))},["isProxy","isExternal","isModuleNamespaceObject"].forEach((function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw new Error(e+" is not supported in userland")}})}))},40537:(e,t,r)=>{var i=r(65606),n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},i=0;i=n)return e;switch(e){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch(e){return"[Circular]"}default:return e}})),a=i[r];r=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),m(r)?i.showHidden=r:r&&t._extend(i,r),b(i.showHidden)&&(i.showHidden=!1),b(i.depth)&&(i.depth=2),b(i.colors)&&(i.colors=!1),b(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=d),u(i,e,i.depth)}function d(e,t){var r=l.styles[t];return r?"["+l.colors[r][0]+"m"+e+"["+l.colors[r][1]+"m":e}function c(e,t){return e}function u(e,r,i){if(e.customInspect&&r&&k(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var n=r.inspect(i,e);return v(n)||(n=u(e,n,i)),n}var o=function(e,t){if(b(t))return e.stylize("undefined","undefined");if(v(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(y(t))return e.stylize(""+t,"number");if(m(t))return e.stylize(""+t,"boolean");if(g(t))return e.stylize("null","null")}(e,r);if(o)return o;var s=Object.keys(r),a=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(r)),S(r)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return p(r);if(0===s.length){if(k(r)){var l=r.name?": "+r.name:"";return e.stylize("[Function"+l+"]","special")}if(w(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(x(r))return e.stylize(Date.prototype.toString.call(r),"date");if(S(r))return p(r)}var d,c="",_=!1,E=["{","}"];(f(r)&&(_=!0,E=["[","]"]),k(r))&&(c=" [Function"+(r.name?": "+r.name:"")+"]");return w(r)&&(c=" "+RegExp.prototype.toString.call(r)),x(r)&&(c=" "+Date.prototype.toUTCString.call(r)),S(r)&&(c=" "+p(r)),0!==s.length||_&&0!=r.length?i<0?w(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),d=_?function(e,t,r,i,n){for(var o=[],s=0,a=t.length;s=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1}),0);if(i>60)return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(d,c,E)):E[0]+c+E[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function h(e,t,r,i,n,o){var s,a,l;if((l=Object.getOwnPropertyDescriptor(t,n)||{value:t[n]}).get?a=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(a=e.stylize("[Setter]","special")),C(i,n)||(s="["+n+"]"),a||(e.seen.indexOf(l.value)<0?(a=g(r)?u(e,l.value,null):u(e,l.value,r-1)).indexOf("\n")>-1&&(a=o?a.split("\n").map((function(e){return" "+e})).join("\n").slice(2):"\n"+a.split("\n").map((function(e){return" "+e})).join("\n")):a=e.stylize("[Circular]","special")),b(s)){if(o&&n.match(/^\d+$/))return a;(s=JSON.stringify(""+n)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.slice(1,-1),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function f(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function g(e){return null===e}function y(e){return"number"==typeof e}function v(e){return"string"==typeof e}function b(e){return void 0===e}function w(e){return _(e)&&"[object RegExp]"===E(e)}function _(e){return"object"==typeof e&&null!==e}function x(e){return _(e)&&"[object Date]"===E(e)}function S(e){return _(e)&&("[object Error]"===E(e)||e instanceof Error)}function k(e){return"function"==typeof e}function E(e){return Object.prototype.toString.call(e)}function T(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(e=e.toUpperCase(),!s[e])if(a.test(e)){var r=i.pid;s[e]=function(){var i=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,i)}}else s[e]=function(){};return s[e]},t.inspect=l,l.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},l.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=r(49032),t.isArray=f,t.isBoolean=m,t.isNull=g,t.isNullOrUndefined=function(e){return null==e},t.isNumber=y,t.isString=v,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=b,t.isRegExp=w,t.types.isRegExp=w,t.isObject=_,t.isDate=x,t.types.isDate=x,t.isError=S,t.types.isNativeError=S,t.isFunction=k,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(81135);var B=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function C(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){var e,r;console.log("%s - %s",(e=new Date,r=[T(e.getHours()),T(e.getMinutes()),T(e.getSeconds())].join(":"),[e.getDate(),B[e.getMonth()],r].join(" ")),t.format.apply(t,arguments))},t.inherits=r(56698),t._extend=function(e,t){if(!t||!_(t))return e;for(var r=Object.keys(t),i=r.length;i--;)e[r[i]]=t[r[i]];return e};var I="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function A(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(I&&e[I]){var t;if("function"!=typeof(t=e[I]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,I,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,i=new Promise((function(e,i){t=e,r=i})),n=[],o=0;o{"use strict";var i=r(82682),n=r(39209),o=r(10487),s=r(38075),a=r(75795),l=s("Object.prototype.toString"),d=r(49092)(),c="undefined"==typeof globalThis?r.g:globalThis,u=n(),p=s("String.prototype.slice"),h=Object.getPrototypeOf,f=s("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r-1?t:"Object"===t&&function(e){var t=!1;return i(m,(function(r,i){if(!t)try{r(e),t=p(i,1)}catch(e){}})),t}(e)}return a?function(e){var t=!1;return i(m,(function(r,i){if(!t)try{"$"+r(e)===i&&(t=p(i,1))}catch(e){}})),t}(e):null}},55512:e=>{"use strict";e.exports=function(e,t,r,i){var n=self||window;try{try{var o;try{o=new n.Blob([e])}catch(t){(o=new(n.BlobBuilder||n.WebKitBlobBuilder||n.MozBlobBuilder||n.MSBlobBuilder)).append(e),o=o.getBlob()}var s=n.URL||n.webkitURL,a=s.createObjectURL(o),l=new n[t](a,r);return s.revokeObjectURL(a),l}catch(i){return new n[t]("data:application/javascript,".concat(encodeURIComponent(e)),r)}}catch(e){if(!i)throw Error("Inline worker is not supported");return new n[t](i,r)}}},26692:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(73363)),s=n(r(48079)),a=n(r(64007)),l=n(r(11393));t.default=function(e){var t="xregexp",r=/(\()(?!\?)|\\([1-9]\d*)|\\[\s\S]|\[(?:[^\\\]]|\\[\s\S])*\]/g,i=e.union([/\({{([\w$]+)}}\)|{{([\w$]+)}}/,r],"g",{conjunction:"or"});function n(e){var t=/^(?:\(\?:\))*\^/,r=/\$(?:\(\?:\))*$/;return t.test(e)&&r.test(e)&&r.test(e.replace(/\\[\s\S]/g,""))?e.replace(t,"").replace(r,""):e}function d(r,i){var n=i?"x":"";return e.isRegExp(r)?r[t]&&r[t].captureNames?r:e(r.source,n):e(r,n)}function c(t){return t instanceof RegExp?t:e.escape(t)}function u(e,t,r){return e["subpattern".concat(r)]=t,e}function p(e,t,r){return e+(t1?a-1:0),d=1;d")):a="(?:",g=v;var p=h[c].pattern.replace(r,(function(e,t,r){if(t){if(s=h[c].names[v-g],++v,s)return"(?<".concat(s,">")}else if(r)return d=+r-1,h[c].names[d]?"\\k<".concat(h[c].names[d],">"):"\\".concat(+r+g);return e}));return(0,l.default)(u="".concat(a)).call(u,p,")")}if(n){if(s=_[b],w[++b]=++v,s)return"(?<".concat(s,">")}else if(o)return _[d=+o-1]?"\\k<".concat(_[d],">"):"\\".concat(w[+o]);return e}));return e(x,c)}},e.exports=t.default},87409:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(64007)),s=n(r(11393)),a=n(r(18979));t.default=function(e){function t(e,t,r,i){return{name:e,value:t,start:r,end:i}}e.matchRecursive=function(r,i,n,l,d){l=l||"",d=d||{};var c,u=-1!==(0,o.default)(l).call(l,"g"),p=-1!==(0,o.default)(l).call(l,"y"),h=l.replace(/y/g,"");i=e(i,h),n=e(n,h);var f=d.escapeChar;if(f){var m,g;if(f.length>1)throw new Error("Cannot use more than one escape character");f=e.escape(f),c=new RegExp((0,s.default)(m=(0,s.default)(g="(?:".concat(f,"[\\S\\s]|(?:(?!")).call(g,e.union([i,n],"",{conjunction:"or"}).source,")[^")).call(m,f,"])+)+"),l.replace(e._hasNativeFlag("s")?/[^imsu]/g:/[^imu]/g,""))}for(var y,v,b,w,_=0,x=0,S=0,k=0,E=d.valueNames,T=[];;){if(f&&(S+=(e.exec(r,c,S,"sticky")||[""])[0].length),b=e.exec(r,i,S),w=e.exec(r,n,S),b&&w&&(b.index<=w.index?w=null:b=null),b||w)S=(x=(b||w).index)+(b||w)[0].length;else if(!_)break;if(p&&!_&&x>k)break;if(b)_||(y=x,v=S),_+=1;else if(w&&_){if(!(_-=1)&&(E?(E[0]&&y>k&&T.push(t(E[0],(0,a.default)(r).call(r,k,y),k,y)),E[1]&&T.push(t(E[1],(0,a.default)(r).call(r,y,v),y,v)),E[2]&&T.push(t(E[2],(0,a.default)(r).call(r,v,x),v,x)),E[3]&&T.push(t(E[3],(0,a.default)(r).call(r,x,S),x,S))):T.push((0,a.default)(r).call(r,v,x)),k=S,!u))break}else{var B=d.unbalanced||"error";if("skip"!==B&&"skip-lazy"!==B){if("error"===B){var C,I=w?"right":"left",A=w?x:y;throw new Error((0,s.default)(C="Unbalanced ".concat(I," delimiter found in string at position ")).call(C,A))}throw new Error("Unsupported value for unbalanced: ".concat(B))}if(w)w=null;else{if("skip"===B)S=y+(e.exec(r,i,y,"sticky")[0].length||1);else S=y+1;_=0}}x===S&&(S+=1)}return u&&T.length>0&&!p&&E&&E[0]&&r.length>k&&T.push(t(E[0],(0,a.default)(r).call(r,k),k,r.length)),T}},e.exports=t.default},77801:(e,t,r)=>{"use strict";var i=r(18979),n=r(49763),o=r(16781),s=r(62222),a=r(66615),l=r(53930),d=r(5946);l(t,"__esModule",{value:!0}),t.default=void 0;var c=d(r(34875)),u=d(r(86226)),p=d(r(11393)),h=d(r(64007));function f(e,t){var r=void 0!==o&&s(e)||e["@@iterator"];if(!r){if(a(e)||(r=function(e,t){var r;if(!e)return;if("string"==typeof e)return m(e,t);var o=i(r=Object.prototype.toString.call(e)).call(r,8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return n(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return m(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var l=0,d=function(){};return{s:d,n:function(){return l>=e.length?{done:!0}:{done:!1,value:e[l++]}},e:function(e){throw e},f:d}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,u=!0,p=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return u=e.done,e},e:function(e){p=!0,c=e},f:function(){try{u||null==r.return||r.return()}finally{if(p)throw c}}}}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r + * Steven Levithan (c) 2008-present MIT License + */t.default=function(e){var t={},r={},i=e._dec,n=e._hex,o=e._pad4;function s(e){return e.replace(/[- _]+/g,"").toLowerCase()}function a(e){var t=/^\\[xu](.+)/.exec(e);return t?i(t[1]):e.charCodeAt("\\"===e[0]?1:0)}function l(r){var i,s,l;return t[r]["b!"]||(t[r]["b!"]=(i=t[r].bmp,s="",l=-1,(0,u.default)(e).call(e,i,/(\\x..|\\u....|\\?[\s\S])(?:-(\\x..|\\u....|\\?[\s\S]))?/,(function(e){var t=a(e[1]);t>l+1&&(s+="\\u".concat(o(n(l+1))),t>l+2&&(s+="-\\u".concat(o(n(t-1))))),l=a(e[2]||e[1])})),l<65535&&(s+="\\u".concat(o(n(l+1))),l<65534&&(s+="-\\uFFFF")),s))}function d(e,r){var i=r?"a!":"a=";return t[e][i]||(t[e][i]=function(e,r){var i,n,o=t[e],s="";return o.bmp&&!o.isBmpLast&&(s=(0,p.default)(i="[".concat(o.bmp,"]")).call(i,o.astral?"|":"")),o.astral&&(s+=o.astral),o.isBmpLast&&o.bmp&&(s+=(0,p.default)(n="".concat(o.astral?"|":"","[")).call(n,o.bmp,"]")),r?"(?:(?!".concat(s,")(?:[\ud800-\udbff][\udc00-\udfff]|[\0-￿]))"):"(?:".concat(s,")")}(e,r))}e.addToken(/\\([pP])(?:{(\^?)(?:(\w+)=)?([^}]*)}|([A-Za-z]))/,(function(e,i,n){var o="Unknown Unicode token ",a=(0,c.default)(e,6),u=a[0],f=a[1],m=a[2],g=a[3],y=a[4],v=a[5],b="P"===f||!!m,w=-1!==(0,h.default)(n).call(n,"A"),_=s(v||y),x=t[_];if("P"===f&&m)throw new SyntaxError("Invalid double negation "+u);if(!t.hasOwnProperty(_))throw new SyntaxError(o+u);if(g&&(!r[g]||!r[g][_]))throw new SyntaxError(o+u);if(x.inverseOf){var S;if(_=s(x.inverseOf),!t.hasOwnProperty(_))throw new ReferenceError((0,p.default)(S="".concat("Unicode token missing data "+u," -> ")).call(S,x.inverseOf));x=t[_],b=!b}if(!x.bmp&&!w)throw new SyntaxError("Astral mode required for Unicode token "+u);if(w){if("class"===i)throw new SyntaxError("Astral mode does not support Unicode tokens within character classes");return d(_,b)}return"class"===i?b?l(_):x.bmp:"".concat((b?"[^":"[")+x.bmp,"]")}),{scope:"all",optionalFlags:"A",leadChar:"\\"}),e.addUnicodeData=function(i,n){n&&(r[n]={});var o,a=f(i);try{for(a.s();!(o=a.n()).done;){var l=o.value;if(!l.name)throw new Error("Unicode token requires name");if(!(l.inverseOf||l.bmp||l.astral))throw new Error("Unicode token has no character data "+l.name);var d=s(l.name);if(t[d]=l,n&&(r[n][d]=!0),l.alias){var c=s(l.alias);t[c]=l,n&&(r[n][c]=!0)}}}catch(e){a.e(e)}finally{a.f()}e.cache.flush("patterns")},e._getUnicodeProperty=function(e){var r=s(e);return t[r]}},e.exports=t.default},47884:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(4311)); +/*! + * XRegExp Unicode Categories 5.1.1 + * + * Steven Levithan (c) 2010-present MIT License + * Unicode data by Mathias Bynens + */t.default=function(e){if(!e.addUnicodeData)throw new ReferenceError("Unicode Base must be loaded before Unicode Categories");e.addUnicodeData(o.default)},e.exports=t.default},59749:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(88477)); +/*! + * XRegExp Unicode Properties 5.1.1 + * + * Steven Levithan (c) 2012-present MIT License + * Unicode data by Mathias Bynens + */t.default=function(e){if(!e.addUnicodeData)throw new ReferenceError("Unicode Base must be loaded before Unicode Properties");var t=o.default;t.push({name:"Assigned",inverseOf:"Cn"}),e.addUnicodeData(t)},e.exports=t.default},50302:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(5142)); +/*! + * XRegExp Unicode Scripts 5.1.1 + * + * Steven Levithan (c) 2010-present MIT License + * Unicode data by Mathias Bynens + */t.default=function(e){if(!e.addUnicodeData)throw new ReferenceError("Unicode Base must be loaded before Unicode Scripts");e.addUnicodeData(o.default,"Script")},e.exports=t.default},53050:(e,t,r)=>{"use strict";var i=r(53930),n=r(5946);i(t,"__esModule",{value:!0}),t.default=void 0;var o=n(r(56011)),s=n(r(26692)),a=n(r(87409)),l=n(r(77801)),d=n(r(47884)),c=n(r(59749)),u=n(r(50302));(0,s.default)(o.default),(0,a.default)(o.default),(0,l.default)(o.default),(0,d.default)(o.default),(0,c.default)(o.default),(0,u.default)(o.default);var p=o.default;t.default=p,e.exports=t.default},56011:(e,t,r)=>{"use strict";var i=r(18979),n=r(49763),o=r(16781),s=r(62222),a=r(66615),l=r(53930),d=r(5946);l(t,"__esModule",{value:!0}),t.default=void 0;var c=d(r(34875)),u=d(r(52730)),p=d(r(129)),h=d(r(18979)),f=d(r(36586)),m=d(r(64007)),g=d(r(86226)),y=d(r(27681)),v=d(r(11393));function b(e,t){var r=void 0!==o&&s(e)||e["@@iterator"];if(!r){if(a(e)||(r=function(e,t){var r;if(!e)return;if("string"==typeof e)return w(e,t);var o=i(r=Object.prototype.toString.call(e)).call(r,8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return n(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return w(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var l=0,d=function(){};return{s:d,n:function(){return l>=e.length?{done:!0}:{done:!1,value:e[l++]}},e:function(e){throw e},f:d}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,u=!0,p=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return u=e.done,e},e:function(e){p=!0,c=e},f:function(){try{u||null==r.return||r.return()}finally{if(p)throw c}}}}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=new Array(t);r + * Steven Levithan (c) 2007-present MIT License + */var _="xregexp",x={astral:!1,namespacing:!0},S={},k={},E={},T=[],B="default",C="class",I={default:/\\(?:0(?:[0-3][0-7]{0,2}|[4-7][0-7]?)?|[1-9]\d*|x[\dA-Fa-f]{2}|u(?:[\dA-Fa-f]{4}|{[\dA-Fa-f]+})|c[A-Za-z]|[\s\S])|\(\?(?:[:=!]|<[=!])|[?*+]\?|{\d+(?:,\d*)?}\??|[\s\S]/,class:/\\(?:[0-3][0-7]{0,2}|[4-7][0-7]?|x[\dA-Fa-f]{2}|u(?:[\dA-Fa-f]{4}|{[\dA-Fa-f]+})|c[A-Za-z]|[\s\S])|[\s\S]/},A=/\$(?:\{([^\}]+)\}|<([^>]+)>|(\d\d?|[\s\S]?))/g,F=void 0===/()??/.exec("")[1],M=void 0!==(0,u.default)(/x/);function D(e){var t=!0;try{if(new RegExp("",e),"y"===e){".."===".a".replace(new RegExp("a","gy"),".")&&(t=!1)}}catch(e){t=!1}return t}var R=D("d"),P=D("s"),O=D("u"),z=D("y"),N={d:R,g:!0,i:!0,m:!0,s:P,u:O,y:z},q=P?/[^dgimsuy]+/g:/[^dgimuy]+/g;function U(e,t,r,i,n){var o;if(e[_]={captureNames:t},n)return e;if(e.__proto__)e.__proto__=ee.prototype;else for(var s in ee.prototype)e[s]=ee.prototype[s];return e[_].source=r,e[_].flags=i?(0,p.default)(o=i.split("")).call(o).join(""):i,e}function L(e){return e.replace(/([\s\S])(?=[\s\S]*\1)/g,"")}function j(e,t){var r;if(!ee.isRegExp(e))throw new TypeError("Type RegExp expected");var i=e[_]||{},n=function(e){return M?(0,u.default)(e):/\/([a-z]*)$/i.exec(RegExp.prototype.toString.call(e))[1]}(e),o="",s="",a=null,l=null;return(t=t||{}).removeG&&(s+="g"),t.removeY&&(s+="y"),s&&(n=n.replace(new RegExp("[".concat(s,"]+"),"g"),"")),t.addG&&(o+="g"),t.addY&&(o+="y"),o&&(n=L(n+o)),t.isInternalOnly||(void 0!==i.source&&(a=i.source),null!=(0,u.default)(i)&&(l=o?L((0,u.default)(i)+o):(0,u.default)(i))),e=U(new RegExp(t.source||e.source,n),function(e){return!(!e[_]||!e[_].captureNames)}(e)?(0,h.default)(r=i.captureNames).call(r,0):null,a,l,t.isInternalOnly)}function H(e){return(0,f.default)(e,16)}function $(e,t,r){var i=e.index+e[0].length,n=e.input[e.index-1],o=e.input[i];return/^[()|]$/.test(n)||/^[()|]$/.test(o)||0===e.index||i===e.input.length||/\(\?(?:[:=!]|<[=!])$/.test(e.input.substring(e.index-4,e.index))||function(e,t,r){var i=-1!==(0,m.default)(r).call(r,"x")?/^(?:\s|#[^#\n]*|\(\?#[^)]*\))*(?:[?*+]|{\d+(?:,\d*)?})/:/^(?:\(\?#[^)]*\))*(?:[?*+]|{\d+(?:,\d*)?})/;return i.test((0,h.default)(e).call(e,t))}(e.input,i,r)?"":"(?:)"}function G(e){return(0,f.default)(e,10).toString(16)}function W(e,t){return Object.prototype.toString.call(e)==="[object ".concat(t,"]")}function K(e){if(null==e)throw new TypeError("Cannot convert null or undefined to object");return e}function V(e){for(;e.length<4;)e="0".concat(e);return e}function J(e){var t={};return W(e,"String")?((0,g.default)(ee).call(ee,e,/[^\s,]+/,(function(e){t[e]=!0})),t):e}function Y(e){if(!/^[\w$]$/.test(e))throw new Error("Flag must be a single character A-Za-z0-9_$");N[e]=!0}function Q(e,t,r,i,n){for(var o,s,a=T.length,l=e[r],d=null;a--;)if(!((s=T[a]).leadChar&&s.leadChar!==l||s.scope!==i&&"all"!==s.scope||s.flag&&-1===(0,m.default)(t).call(t,s.flag))&&(o=ee.exec(e,s.regex,r,"sticky"))){d={matchLength:o[0].length,output:s.handler.call(n,o,i,t),reparse:s.reparse};break}return d}function Z(e){x.astral=e}function X(e){x.namespacing=e}function ee(e,t){if(ee.isRegExp(e)){if(void 0!==t)throw new TypeError("Cannot supply flags when copying a RegExp");return j(e)}if(e=void 0===e?"":String(e),t=void 0===t?"":String(t),ee.isInstalled("astral")&&-1===(0,m.default)(t).call(t,"A")&&(t+="A"),E[e]||(E[e]={}),!E[e][t]){for(var r,i={hasNamedCapture:!1,captureNames:[]},n=B,o="",s=0,a=function(e,t){if(L(t)!==t)throw new SyntaxError("Invalid duplicate regex flag ".concat(t));e=e.replace(/^\(\?([\w$]+)\)/,(function(e,r){if(/[dgy]/.test(r))throw new SyntaxError("Cannot use flags dgy in mode modifier ".concat(e));return t=L(t+r),""}));var r,i=b(t);try{for(i.s();!(r=i.n()).done;){var n=r.value;if(!N[n])throw new SyntaxError("Unknown regex flag ".concat(n))}}catch(e){i.e(e)}finally{i.f()}return{pattern:e,flags:t}}(e,t),l=a.pattern,d=(0,u.default)(a);s")}else if(r)return"\\".concat(+r+i);return e}if(!W(e,"Array")||!e.length)throw new TypeError("Must provide a nonempty array of patterns to merge");var l,d=/(\()(?!\?)|\\([1-9]\d*)|\\[\s\S]|\[(?:[^\\\]]|\\[\s\S])*\]/g,c=[],u=b(e);try{for(u.s();!(l=u.n()).done;){var p=l.value;ee.isRegExp(p)?(i=s,n=p[_]&&p[_].captureNames||[],c.push(ee(p.source).source.replace(d,a))):c.push(ee.escape(p))}}catch(e){u.e(e)}finally{u.f()}var h="none"===o?"":"|";return ee(c.join(h),t)},S.exec=function(e){var t=this.lastIndex,r=RegExp.prototype.exec.apply(this,arguments);if(r){if(!F&&r.length>1&&-1!==(0,m.default)(r).call(r,"")){var i,n=j(this,{removeG:!0,isInternalOnly:!0});(0,h.default)(i=String(e)).call(i,r.index).replace(n,(function(){for(var e=arguments.length,t=1;tr.index&&(this.lastIndex=r.index)}return this.global||(this.lastIndex=t),r},S.test=function(e){return!!S.exec.call(this,e)},S.match=function(e){if(ee.isRegExp(e)){if(e.global){var t=String.prototype.match.apply(this,arguments);return e.lastIndex=0,t}}else e=new RegExp(e);return S.exec.call(e,K(this))},S.replace=function(e,t){var r,i,n,o=ee.isRegExp(e);return o?(e[_]&&(i=e[_].captureNames),r=e.lastIndex):e+="",n=W(t,"Function")?String(this).replace(e,(function(){for(var e=arguments.length,r=new Array(e),n=0;nd)throw new SyntaxError("Backreference to undefined group ".concat(e));return r[o]||""}throw new SyntaxError("Invalid token ".concat(e))}))})),o&&(e.global?e.lastIndex=0:e.lastIndex=r),n},S.split=function(e,t){if(!ee.isRegExp(e))return String.prototype.split.apply(this,arguments);var r,i=String(this),n=[],o=e.lastIndex,s=0;return t=(void 0===t?-1:t)>>>0,(0,g.default)(ee).call(ee,i,e,(function(e){e.index+e[0].length>s&&(n.push((0,h.default)(i).call(i,s,e.index)),e.length>1&&e.indext?(0,h.default)(n).call(n,0,t):n},ee.addToken(/\\([ABCE-RTUVXYZaeg-mopqyz]|c(?![A-Za-z])|u(?![\dA-Fa-f]{4}|{[\dA-Fa-f]+})|x(?![\dA-Fa-f]{2}))/,(function(e,t){if("B"===e[1]&&t===B)return e[0];throw new SyntaxError("Invalid escape ".concat(e[0]))}),{scope:"all",leadChar:"\\"}),ee.addToken(/\\u{([\dA-Fa-f]+)}/,(function(e,t,r){var i=H(e[1]);if(i>1114111)throw new SyntaxError("Invalid Unicode code point ".concat(e[0]));if(i<=65535)return"\\u".concat(V(G(i)));if(O&&-1!==(0,m.default)(r).call(r,"u"))return e[0];throw new SyntaxError("Cannot use Unicode code point above \\u{FFFF} without flag u")}),{scope:"all",leadChar:"\\"}),ee.addToken(/\(\?#[^)]*\)/,$,{leadChar:"("}),ee.addToken(/\s+|#[^\n]*\n?/,$,{flag:"x"}),P||ee.addToken(/\./,(function(){return"[\\s\\S]"}),{flag:"s",leadChar:"."}),ee.addToken(/\\k<([^>]+)>/,(function(e){var t,r,i=isNaN(e[1])?(0,m.default)(t=this.captureNames).call(t,e[1])+1:+e[1],n=e.index+e[0].length;if(!i||i>this.captureNames.length)throw new SyntaxError("Backreference to undefined group ".concat(e[0]));return(0,v.default)(r="\\".concat(i)).call(r,n===e.input.length||isNaN(e.input[n])?"":"(?:)")}),{leadChar:"\\"}),ee.addToken(/\\(\d+)/,(function(e,t){if(!(t===B&&/^[1-9]/.test(e[1])&&+e[1]<=this.captureNames.length)&&"0"!==e[1])throw new SyntaxError("Cannot use octal escape or backreference to undefined group ".concat(e[0]));return e[0]}),{scope:"all",leadChar:"\\"}),ee.addToken(/\(\?P?<((?:[\$A-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\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\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\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\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD23\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF45\uDF70-\uDF81\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDEB8\uDF00-\uDF1A\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCDF\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDEE0-\uDEF2\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE70-\uDEBE\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43\uDD4B]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])(?:[\$0-9A-Z_a-z\xAA\xB5\xB7\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05EF-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u07FD\u0800-\u082D\u0840-\u085B\u0860-\u086A\u0870-\u0887\u0889-\u088E\u0898-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\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-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\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-\u0B6F\u0B71\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-\u0BEF\u0C00-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3C-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C5D\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDD\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D81-\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\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-\u135F\u1369-\u1371\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1715\u171F-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u180F-\u1819\u1820-\u1878\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1ABF-\u1ACE\u1B00-\u1B4C\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CD0-\u1CD2\u1CD4-\u1CFA\u1D00-\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\u200C\u200D\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA827\uA82C\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDD00-\uDD27\uDD30-\uDD39\uDE80-\uDEA9\uDEAB\uDEAC\uDEB0\uDEB1\uDF00-\uDF1C\uDF27\uDF30-\uDF50\uDF70-\uDF85\uDFB0-\uDFC4\uDFE0-\uDFF6]|\uD804[\uDC00-\uDC46\uDC66-\uDC75\uDC7F-\uDCBA\uDCC2\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD44-\uDD47\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDC9-\uDDCC\uDDCE-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3B-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC5E-\uDC61\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB8\uDEC0-\uDEC9\uDF00-\uDF1A\uDF1D-\uDF2B\uDF30-\uDF39\uDF40-\uDF46]|\uD806[\uDC00-\uDC3A\uDCA0-\uDCE9\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD35\uDD37\uDD38\uDD3B-\uDD43\uDD50-\uDD59\uDDA0-\uDDA7\uDDAA-\uDDD7\uDDDA-\uDDE1\uDDE3\uDDE4\uDE00-\uDE3E\uDE47\uDE50-\uDE99\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD8E\uDD90\uDD91\uDD93-\uDD98\uDDA0-\uDDA9\uDEE0-\uDEF6\uDFB0]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDE70-\uDEBE\uDEC0-\uDEC9\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE7F\uDF00-\uDF4A\uDF4F-\uDF87\uDF8F-\uDF9F\uDFE0\uDFE1\uDFE3\uDFE4\uDFF0\uDFF1]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD833[\uDF00-\uDF2D\uDF30-\uDF46]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD837[\uDF00-\uDF1E]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD00-\uDD2C\uDD30-\uDD3D\uDD40-\uDD49\uDD4E\uDE90-\uDEAE\uDEC0-\uDEF9]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4B\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD83E[\uDFF0-\uDFF9]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A]|\uDB40[\uDD00-\uDDEF])*)>/,(function(e){var t;if(!ee.isInstalled("namespacing")&&("length"===e[1]||"__proto__"===e[1]))throw new SyntaxError("Cannot use reserved word as capture name ".concat(e[0]));if(-1!==(0,m.default)(t=this.captureNames).call(t,e[1]))throw new SyntaxError("Cannot use same name for multiple groups ".concat(e[0]));return this.captureNames.push(e[1]),this.hasNamedCapture=!0,"("}),{leadChar:"("}),ee.addToken(/\((?!\?)/,(function(e,t,r){return-1!==(0,m.default)(r).call(r,"n")?"(?:":(this.captureNames.push(null),"(")}),{optionalFlags:"n",leadChar:"("});var te=ee;t.default=te,e.exports=t.default},4311:e=>{e.exports=[{name:"C",alias:"Other",isBmpLast:!0,bmp:"\0--Ÿ­͸͹΀-΃΋΍΢԰՗՘֋֌֐׈-׏׫-׮׵-؅؜۝܎܏݋݌޲-޿߻߼࠮࠯࠿࡜࡝࡟࡫-࡯࢏-ࢗ࣢঄঍঎঑঒঩঱঳-঵঺঻৅৆৉৊৏-৖৘-৛৞৤৥৿਀਄਋-਎਑਒਩਱਴਷਺਻਽੃-੆੉੊੎-੐੒-੘੝੟-੥੷-઀઄઎઒઩઱઴઺઻૆૊૎૏૑-૟૤૥૲-૸଀଄଍଎଑଒଩଱଴଺଻୅୆୉୊୎-୔୘-୛୞୤୥୸-஁஄஋-஍஑஖-஘஛஝஠-஢஥-஧஫-஭஺-஽௃-௅௉௎௏௑-௖௘-௥௻-௿఍఑఩఺఻౅౉౎-౔౗౛౜౞౟౤౥౰-౶಍಑಩಴಺಻೅೉೎-೔೗-೜೟೤೥೰ೳ-೿഍഑൅൉൐-൓൤൥඀඄඗-඙඲඼඾඿෇-෉෋-෎෕෗෠-෥෰෱෵-฀฻-฾๜-຀຃຅຋຤຦຾຿໅໇໎໏໚໛໠-໿཈཭-཰྘྽࿍࿛-࿿჆჈-჌჎჏቉቎቏቗቙቞቟኉኎኏኱኶኷኿዁዆዇዗጑጖጗፛፜፽-፿᎚-᎟᏶᏷᏾᏿᚝-᚟᛹-᛿᜖-᜞᜷-᜿᝔-᝟᝭᝱᝴-᝿៞៟៪-៯៺-៿᠎᠚-᠟᡹-᡿᢫-᢯᣶-᣿᤟᤬-᤯᤼-᤿᥁-᥃᥮᥯᥵-᥿᦬-᦯᧊-᧏᧛-᧝᨜᨝᩟᩽᩾᪊-᪏᪚-᪟᪮᪯᫏-᫿᭍-᭏᭿᯴-᯻᰸-᰺᱊-᱌Ᲊ-᲏᲻᲼᳈-᳏᳻-᳿἖἗἞἟὆὇὎὏὘὚὜὞὾὿᾵῅῔῕῜῰῱῵῿​-‏‪-‮⁠-⁲⁳₏₝-₟⃁-⃏⃱-⃿↌-↏␧-␿⑋-⑟⭴⭵⮖⳴-⳸⴦⴨-⴬⴮⴯⵨-⵮⵱-⵾⶗-⶟⶧⶯⶷⶿⷇⷏⷗⷟⹞-⹿⺚⻴-⻿⿖-⿯⿼-⿿぀゗゘㄀-㄄㄰㆏㇤-㇯㈟꒍-꒏꓇-꓏꘬-꘿꛸-꛿Ɤ-꟏꟒꟔Ꟛ-꟱꠭-꠯꠺-꠿꡸-꡿꣆-꣍꣚-꣟꥔-꥞꥽-꥿꧎꧚-꧝꧿꨷-꨿꩎꩏꩚꩛꫃-꫚꫷-꬀꬇꬈꬏꬐꬗-꬟꬧꬯꭬-꭯꯮꯯꯺-꯿힤-힯퟇-퟊퟼-﩮﩯﫚-﫿﬇-﬒﬘-﬜﬷﬽﬿﭂﭅﯃-﯒﶐﶑﷈-﷎﷐-﷯︚-︟﹓﹧﹬-﹯﹵﻽-＀﾿-￁￈￉￐￑￘￙￝-￟￧￯-￾￿",astral:"\ud800[\udc0c\udc27\udc3b\udc3e\udc4e\udc4f\udc5e-\udc7f\udcfb-\udcff\udd03-\udd06\udd34-\udd36\udd8f\udd9d-\udd9f\udda1-\uddcf\uddfe-\ude7f\ude9d-\ude9f\uded1-\udedf\udefc-\udeff\udf24-\udf2c\udf4b-\udf4f\udf7b-\udf7f\udf9e\udfc4-\udfc7\udfd6-\udfff]|\ud801[\udc9e\udc9f\udcaa-\udcaf\udcd4-\udcd7\udcfc-\udcff\udd28-\udd2f\udd64-\udd6e\udd7b\udd8b\udd93\udd96\udda2\uddb2\uddba\uddbd-\uddff\udf37-\udf3f\udf56-\udf5f\udf68-\udf7f\udf86\udfb1\udfbb-\udfff]|\ud802[\udc06\udc07\udc09\udc36\udc39-\udc3b\udc3d\udc3e\udc56\udc9f-\udca6\udcb0-\udcdf\udcf3\udcf6-\udcfa\udd1c-\udd1e\udd3a-\udd3e\udd40-\udd7f\uddb8-\uddbb\uddd0\uddd1\ude04\ude07-\ude0b\ude14\ude18\ude36\ude37\ude3b-\ude3e\ude49-\ude4f\ude59-\ude5f\udea0-\udebf\udee7-\udeea\udef7-\udeff\udf36-\udf38\udf56\udf57\udf73-\udf77\udf92-\udf98\udf9d-\udfa8\udfb0-\udfff]|\ud803[\udc49-\udc7f\udcb3-\udcbf\udcf3-\udcf9\udd28-\udd2f\udd3a-\ude5f\ude7f\udeaa\udeae\udeaf\udeb2-\udeff\udf28-\udf2f\udf5a-\udf6f\udf8a-\udfaf\udfcc-\udfdf\udff7-\udfff]|\ud804[\udc4e-\udc51\udc76-\udc7e\udcbd\udcc3-\udccf\udce9-\udcef\udcfa-\udcff\udd35\udd48-\udd4f\udd77-\udd7f\udde0\uddf5-\uddff\ude12\ude3f-\ude7f\ude87\ude89\ude8e\ude9e\udeaa-\udeaf\udeeb-\udeef\udefa-\udeff\udf04\udf0d\udf0e\udf11\udf12\udf29\udf31\udf34\udf3a\udf45\udf46\udf49\udf4a\udf4e\udf4f\udf51-\udf56\udf58-\udf5c\udf64\udf65\udf6d-\udf6f\udf75-\udfff]|\ud805[\udc5c\udc62-\udc7f\udcc8-\udccf\udcda-\udd7f\uddb6\uddb7\uddde-\uddff\ude45-\ude4f\ude5a-\ude5f\ude6d-\ude7f\udeba-\udebf\udeca-\udeff\udf1b\udf1c\udf2c-\udf2f\udf47-\udfff]|\ud806[\udc3c-\udc9f\udcf3-\udcfe\udd07\udd08\udd0a\udd0b\udd14\udd17\udd36\udd39\udd3a\udd47-\udd4f\udd5a-\udd9f\udda8\udda9\uddd8\uddd9\udde5-\uddff\ude48-\ude4f\udea3-\udeaf\udef9-\udfff]|\ud807[\udc09\udc37\udc46-\udc4f\udc6d-\udc6f\udc90\udc91\udca8\udcb7-\udcff\udd07\udd0a\udd37-\udd39\udd3b\udd3e\udd48-\udd4f\udd5a-\udd5f\udd66\udd69\udd8f\udd92\udd99-\udd9f\uddaa-\udedf\udef9-\udfaf\udfb1-\udfbf\udff2-\udffe]|\ud808[\udf9a-\udfff]|\ud809[\udc6f\udc75-\udc7f\udd44-\udfff]|[\ud80a\ud80e-\ud810\ud812-\ud819\ud824-\ud82a\ud82d\ud82e\ud830-\ud832\ud83f\ud87b-\ud87d\ud87f\ud885-\udb3f\udb41-\udbff][\udc00-\udfff]|\ud80b[\udc00-\udf8f\udff3-\udfff]|\ud80d[\udc2f-\udfff]|\ud811[\ude47-\udfff]|\ud81a[\ude39-\ude3f\ude5f\ude6a-\ude6d\udebf\udeca-\udecf\udeee\udeef\udef6-\udeff\udf46-\udf4f\udf5a\udf62\udf78-\udf7c\udf90-\udfff]|\ud81b[\udc00-\ude3f\ude9b-\udeff\udf4b-\udf4e\udf88-\udf8e\udfa0-\udfdf\udfe5-\udfef\udff2-\udfff]|\ud821[\udff8-\udfff]|\ud823[\udcd6-\udcff\udd09-\udfff]|\ud82b[\udc00-\udfef\udff4\udffc\udfff]|\ud82c[\udd23-\udd4f\udd53-\udd63\udd68-\udd6f\udefc-\udfff]|\ud82f[\udc6b-\udc6f\udc7d-\udc7f\udc89-\udc8f\udc9a\udc9b\udca0-\udfff]|\ud833[\udc00-\udeff\udf2e\udf2f\udf47-\udf4f\udfc4-\udfff]|\ud834[\udcf6-\udcff\udd27\udd28\udd73-\udd7a\uddeb-\uddff\ude46-\udedf\udef4-\udeff\udf57-\udf5f\udf79-\udfff]|\ud835[\udc55\udc9d\udca0\udca1\udca3\udca4\udca7\udca8\udcad\udcba\udcbc\udcc4\udd06\udd0b\udd0c\udd15\udd1d\udd3a\udd3f\udd45\udd47-\udd49\udd51\udea6\udea7\udfcc\udfcd]|\ud836[\ude8c-\ude9a\udea0\udeb0-\udfff]|\ud837[\udc00-\udeff\udf1f-\udfff]|\ud838[\udc07\udc19\udc1a\udc22\udc25\udc2b-\udcff\udd2d-\udd2f\udd3e\udd3f\udd4a-\udd4d\udd50-\ude8f\udeaf-\udebf\udefa-\udefe\udf00-\udfff]|\ud839[\udc00-\udfdf\udfe7\udfec\udfef\udfff]|\ud83a[\udcc5\udcc6\udcd7-\udcff\udd4c-\udd4f\udd5a-\udd5d\udd60-\udfff]|\ud83b[\udc00-\udc70\udcb5-\udd00\udd3e-\uddff\ude04\ude20\ude23\ude25\ude26\ude28\ude33\ude38\ude3a\ude3c-\ude41\ude43-\ude46\ude48\ude4a\ude4c\ude50\ude53\ude55\ude56\ude58\ude5a\ude5c\ude5e\ude60\ude63\ude65\ude66\ude6b\ude73\ude78\ude7d\ude7f\ude8a\ude9c-\udea0\udea4\udeaa\udebc-\udeef\udef2-\udfff]|\ud83c[\udc2c-\udc2f\udc94-\udc9f\udcaf\udcb0\udcc0\udcd0\udcf6-\udcff\uddae-\udde5\ude03-\ude0f\ude3c-\ude3f\ude49-\ude4f\ude52-\ude5f\ude66-\udeff]|\ud83d[\uded8-\udedc\udeed-\udeef\udefd-\udeff\udf74-\udf7f\udfd9-\udfdf\udfec-\udfef\udff1-\udfff]|\ud83e[\udc0c-\udc0f\udc48-\udc4f\udc5a-\udc5f\udc88-\udc8f\udcae\udcaf\udcb2-\udcff\ude54-\ude5f\ude6e\ude6f\ude75-\ude77\ude7d-\ude7f\ude87-\ude8f\udead-\udeaf\udebb-\udebf\udec6-\udecf\udeda-\udedf\udee8-\udeef\udef7-\udeff\udf93\udfcb-\udfef\udffa-\udfff]|\ud869[\udee0-\udeff]|\ud86d[\udf39-\udf3f]|\ud86e[\udc1e\udc1f]|\ud873[\udea2-\udeaf]|\ud87a[\udfe1-\udfff]|\ud87e[\ude1e-\udfff]|\ud884[\udf4b-\udfff]|\udb40[\udc00-\udcff\uddf0-\udfff]"},{name:"Cc",alias:"Control",bmp:"\0--Ÿ"},{name:"Cf",alias:"Format",bmp:"­؀-؅؜۝܏࢐࢑࣢᠎​-‏‪-‮⁠-⁤⁦-\ufeff-",astral:"\ud804[\udcbd\udccd]|\ud80d[\udc30-\udc38]|\ud82f[\udca0-\udca3]|\ud834[\udd73-\udd7a]|\udb40[\udc01\udc20-\udc7f]"},{name:"Cn",alias:"Unassigned",bmp:"͸͹΀-΃΋΍΢԰՗՘֋֌֐׈-׏׫-׮׵-׿܎݋݌޲-޿߻߼࠮࠯࠿࡜࡝࡟࡫-࡯࢏࢒-ࢗ঄঍঎঑঒঩঱঳-঵঺঻৅৆৉৊৏-৖৘-৛৞৤৥৿਀਄਋-਎਑਒਩਱਴਷਺਻਽੃-੆੉੊੎-੐੒-੘੝੟-੥੷-઀઄઎઒઩઱઴઺઻૆૊૎૏૑-૟૤૥૲-૸଀଄଍଎଑଒଩଱଴଺଻୅୆୉୊୎-୔୘-୛୞୤୥୸-஁஄஋-஍஑஖-஘஛஝஠-஢஥-஧஫-஭஺-஽௃-௅௉௎௏௑-௖௘-௥௻-௿఍఑఩఺఻౅౉౎-౔౗౛౜౞౟౤౥౰-౶಍಑಩಴಺಻೅೉೎-೔೗-೜೟೤೥೰ೳ-೿഍഑൅൉൐-൓൤൥඀඄඗-඙඲඼඾඿෇-෉෋-෎෕෗෠-෥෰෱෵-฀฻-฾๜-຀຃຅຋຤຦຾຿໅໇໎໏໚໛໠-໿཈཭-཰྘྽࿍࿛-࿿჆჈-჌჎჏቉቎቏቗቙቞቟኉኎኏኱኶኷኿዁዆዇዗጑጖጗፛፜፽-፿᎚-᎟᏶᏷᏾᏿᚝-᚟᛹-᛿᜖-᜞᜷-᜿᝔-᝟᝭᝱᝴-᝿៞៟៪-៯៺-៿᠚-᠟᡹-᡿᢫-᢯᣶-᣿᤟᤬-᤯᤼-᤿᥁-᥃᥮᥯᥵-᥿᦬-᦯᧊-᧏᧛-᧝᨜᨝᩟᩽᩾᪊-᪏᪚-᪟᪮᪯᫏-᫿᭍-᭏᭿᯴-᯻᰸-᰺᱊-᱌Ᲊ-᲏᲻᲼᳈-᳏᳻-᳿἖἗἞἟὆὇὎὏὘὚὜὞὾὿᾵῅῔῕῜῰῱῵῿⁥⁲⁳₏₝-₟⃁-⃏⃱-⃿↌-↏␧-␿⑋-⑟⭴⭵⮖⳴-⳸⴦⴨-⴬⴮⴯⵨-⵮⵱-⵾⶗-⶟⶧⶯⶷⶿⷇⷏⷗⷟⹞-⹿⺚⻴-⻿⿖-⿯⿼-⿿぀゗゘㄀-㄄㄰㆏㇤-㇯㈟꒍-꒏꓇-꓏꘬-꘿꛸-꛿Ɤ-꟏꟒꟔Ꟛ-꟱꠭-꠯꠺-꠿꡸-꡿꣆-꣍꣚-꣟꥔-꥞꥽-꥿꧎꧚-꧝꧿꨷-꨿꩎꩏꩚꩛꫃-꫚꫷-꬀꬇꬈꬏꬐꬗-꬟꬧꬯꭬-꭯꯮꯯꯺-꯿힤-힯퟇-퟊퟼-퟿﩮﩯﫚-﫿﬇-﬒﬘-﬜﬷﬽﬿﭂﭅﯃-﯒﶐﶑﷈-﷎﷐-﷯︚-︟﹓﹧﹬-﹯﹵﻽﻾＀﾿-￁￈￉￐￑￘￙￝-￟￧￯-￸￾￿",astral:"\ud800[\udc0c\udc27\udc3b\udc3e\udc4e\udc4f\udc5e-\udc7f\udcfb-\udcff\udd03-\udd06\udd34-\udd36\udd8f\udd9d-\udd9f\udda1-\uddcf\uddfe-\ude7f\ude9d-\ude9f\uded1-\udedf\udefc-\udeff\udf24-\udf2c\udf4b-\udf4f\udf7b-\udf7f\udf9e\udfc4-\udfc7\udfd6-\udfff]|\ud801[\udc9e\udc9f\udcaa-\udcaf\udcd4-\udcd7\udcfc-\udcff\udd28-\udd2f\udd64-\udd6e\udd7b\udd8b\udd93\udd96\udda2\uddb2\uddba\uddbd-\uddff\udf37-\udf3f\udf56-\udf5f\udf68-\udf7f\udf86\udfb1\udfbb-\udfff]|\ud802[\udc06\udc07\udc09\udc36\udc39-\udc3b\udc3d\udc3e\udc56\udc9f-\udca6\udcb0-\udcdf\udcf3\udcf6-\udcfa\udd1c-\udd1e\udd3a-\udd3e\udd40-\udd7f\uddb8-\uddbb\uddd0\uddd1\ude04\ude07-\ude0b\ude14\ude18\ude36\ude37\ude3b-\ude3e\ude49-\ude4f\ude59-\ude5f\udea0-\udebf\udee7-\udeea\udef7-\udeff\udf36-\udf38\udf56\udf57\udf73-\udf77\udf92-\udf98\udf9d-\udfa8\udfb0-\udfff]|\ud803[\udc49-\udc7f\udcb3-\udcbf\udcf3-\udcf9\udd28-\udd2f\udd3a-\ude5f\ude7f\udeaa\udeae\udeaf\udeb2-\udeff\udf28-\udf2f\udf5a-\udf6f\udf8a-\udfaf\udfcc-\udfdf\udff7-\udfff]|\ud804[\udc4e-\udc51\udc76-\udc7e\udcc3-\udccc\udcce\udccf\udce9-\udcef\udcfa-\udcff\udd35\udd48-\udd4f\udd77-\udd7f\udde0\uddf5-\uddff\ude12\ude3f-\ude7f\ude87\ude89\ude8e\ude9e\udeaa-\udeaf\udeeb-\udeef\udefa-\udeff\udf04\udf0d\udf0e\udf11\udf12\udf29\udf31\udf34\udf3a\udf45\udf46\udf49\udf4a\udf4e\udf4f\udf51-\udf56\udf58-\udf5c\udf64\udf65\udf6d-\udf6f\udf75-\udfff]|\ud805[\udc5c\udc62-\udc7f\udcc8-\udccf\udcda-\udd7f\uddb6\uddb7\uddde-\uddff\ude45-\ude4f\ude5a-\ude5f\ude6d-\ude7f\udeba-\udebf\udeca-\udeff\udf1b\udf1c\udf2c-\udf2f\udf47-\udfff]|\ud806[\udc3c-\udc9f\udcf3-\udcfe\udd07\udd08\udd0a\udd0b\udd14\udd17\udd36\udd39\udd3a\udd47-\udd4f\udd5a-\udd9f\udda8\udda9\uddd8\uddd9\udde5-\uddff\ude48-\ude4f\udea3-\udeaf\udef9-\udfff]|\ud807[\udc09\udc37\udc46-\udc4f\udc6d-\udc6f\udc90\udc91\udca8\udcb7-\udcff\udd07\udd0a\udd37-\udd39\udd3b\udd3e\udd48-\udd4f\udd5a-\udd5f\udd66\udd69\udd8f\udd92\udd99-\udd9f\uddaa-\udedf\udef9-\udfaf\udfb1-\udfbf\udff2-\udffe]|\ud808[\udf9a-\udfff]|\ud809[\udc6f\udc75-\udc7f\udd44-\udfff]|[\ud80a\ud80e-\ud810\ud812-\ud819\ud824-\ud82a\ud82d\ud82e\ud830-\ud832\ud83f\ud87b-\ud87d\ud87f\ud885-\udb3f\udb41-\udb7f][\udc00-\udfff]|\ud80b[\udc00-\udf8f\udff3-\udfff]|\ud80d[\udc2f\udc39-\udfff]|\ud811[\ude47-\udfff]|\ud81a[\ude39-\ude3f\ude5f\ude6a-\ude6d\udebf\udeca-\udecf\udeee\udeef\udef6-\udeff\udf46-\udf4f\udf5a\udf62\udf78-\udf7c\udf90-\udfff]|\ud81b[\udc00-\ude3f\ude9b-\udeff\udf4b-\udf4e\udf88-\udf8e\udfa0-\udfdf\udfe5-\udfef\udff2-\udfff]|\ud821[\udff8-\udfff]|\ud823[\udcd6-\udcff\udd09-\udfff]|\ud82b[\udc00-\udfef\udff4\udffc\udfff]|\ud82c[\udd23-\udd4f\udd53-\udd63\udd68-\udd6f\udefc-\udfff]|\ud82f[\udc6b-\udc6f\udc7d-\udc7f\udc89-\udc8f\udc9a\udc9b\udca4-\udfff]|\ud833[\udc00-\udeff\udf2e\udf2f\udf47-\udf4f\udfc4-\udfff]|\ud834[\udcf6-\udcff\udd27\udd28\uddeb-\uddff\ude46-\udedf\udef4-\udeff\udf57-\udf5f\udf79-\udfff]|\ud835[\udc55\udc9d\udca0\udca1\udca3\udca4\udca7\udca8\udcad\udcba\udcbc\udcc4\udd06\udd0b\udd0c\udd15\udd1d\udd3a\udd3f\udd45\udd47-\udd49\udd51\udea6\udea7\udfcc\udfcd]|\ud836[\ude8c-\ude9a\udea0\udeb0-\udfff]|\ud837[\udc00-\udeff\udf1f-\udfff]|\ud838[\udc07\udc19\udc1a\udc22\udc25\udc2b-\udcff\udd2d-\udd2f\udd3e\udd3f\udd4a-\udd4d\udd50-\ude8f\udeaf-\udebf\udefa-\udefe\udf00-\udfff]|\ud839[\udc00-\udfdf\udfe7\udfec\udfef\udfff]|\ud83a[\udcc5\udcc6\udcd7-\udcff\udd4c-\udd4f\udd5a-\udd5d\udd60-\udfff]|\ud83b[\udc00-\udc70\udcb5-\udd00\udd3e-\uddff\ude04\ude20\ude23\ude25\ude26\ude28\ude33\ude38\ude3a\ude3c-\ude41\ude43-\ude46\ude48\ude4a\ude4c\ude50\ude53\ude55\ude56\ude58\ude5a\ude5c\ude5e\ude60\ude63\ude65\ude66\ude6b\ude73\ude78\ude7d\ude7f\ude8a\ude9c-\udea0\udea4\udeaa\udebc-\udeef\udef2-\udfff]|\ud83c[\udc2c-\udc2f\udc94-\udc9f\udcaf\udcb0\udcc0\udcd0\udcf6-\udcff\uddae-\udde5\ude03-\ude0f\ude3c-\ude3f\ude49-\ude4f\ude52-\ude5f\ude66-\udeff]|\ud83d[\uded8-\udedc\udeed-\udeef\udefd-\udeff\udf74-\udf7f\udfd9-\udfdf\udfec-\udfef\udff1-\udfff]|\ud83e[\udc0c-\udc0f\udc48-\udc4f\udc5a-\udc5f\udc88-\udc8f\udcae\udcaf\udcb2-\udcff\ude54-\ude5f\ude6e\ude6f\ude75-\ude77\ude7d-\ude7f\ude87-\ude8f\udead-\udeaf\udebb-\udebf\udec6-\udecf\udeda-\udedf\udee8-\udeef\udef7-\udeff\udf93\udfcb-\udfef\udffa-\udfff]|\ud869[\udee0-\udeff]|\ud86d[\udf39-\udf3f]|\ud86e[\udc1e\udc1f]|\ud873[\udea2-\udeaf]|\ud87a[\udfe1-\udfff]|\ud87e[\ude1e-\udfff]|\ud884[\udf4b-\udfff]|\udb40[\udc00\udc02-\udc1f\udc80-\udcff\uddf0-\udfff]|[\udbbf\udbff][\udffe\udfff]"},{name:"Co",alias:"Private_Use",bmp:"-",astral:"[\udb80-\udbbe\udbc0-\udbfe][\udc00-\udfff]|[\udbbf\udbff][\udc00-\udffd]"},{name:"Cs",alias:"Surrogate",bmp:"\ud800-\udfff"},{name:"L",alias:"Letter",bmp:"A-Za-zªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛱ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢄᢇ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎↃↄⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々〆〱-〵〻〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛥꜗ-ꜟꜢ-ꞈꞋ-ꟊꟐꟑꟓꟕ-ꟙꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",astral:"\ud800[\udc00-\udc0b\udc0d-\udc26\udc28-\udc3a\udc3c\udc3d\udc3f-\udc4d\udc50-\udc5d\udc80-\udcfa\ude80-\ude9c\udea0-\uded0\udf00-\udf1f\udf2d-\udf40\udf42-\udf49\udf50-\udf75\udf80-\udf9d\udfa0-\udfc3\udfc8-\udfcf]|\ud801[\udc00-\udc9d\udcb0-\udcd3\udcd8-\udcfb\udd00-\udd27\udd30-\udd63\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc\ude00-\udf36\udf40-\udf55\udf60-\udf67\udf80-\udf85\udf87-\udfb0\udfb2-\udfba]|\ud802[\udc00-\udc05\udc08\udc0a-\udc35\udc37\udc38\udc3c\udc3f-\udc55\udc60-\udc76\udc80-\udc9e\udce0-\udcf2\udcf4\udcf5\udd00-\udd15\udd20-\udd39\udd80-\uddb7\uddbe\uddbf\ude00\ude10-\ude13\ude15-\ude17\ude19-\ude35\ude60-\ude7c\ude80-\ude9c\udec0-\udec7\udec9-\udee4\udf00-\udf35\udf40-\udf55\udf60-\udf72\udf80-\udf91]|\ud803[\udc00-\udc48\udc80-\udcb2\udcc0-\udcf2\udd00-\udd23\ude80-\udea9\udeb0\udeb1\udf00-\udf1c\udf27\udf30-\udf45\udf70-\udf81\udfb0-\udfc4\udfe0-\udff6]|\ud804[\udc03-\udc37\udc71\udc72\udc75\udc83-\udcaf\udcd0-\udce8\udd03-\udd26\udd44\udd47\udd50-\udd72\udd76\udd83-\uddb2\uddc1-\uddc4\uddda\udddc\ude00-\ude11\ude13-\ude2b\ude80-\ude86\ude88\ude8a-\ude8d\ude8f-\ude9d\ude9f-\udea8\udeb0-\udede\udf05-\udf0c\udf0f\udf10\udf13-\udf28\udf2a-\udf30\udf32\udf33\udf35-\udf39\udf3d\udf50\udf5d-\udf61]|\ud805[\udc00-\udc34\udc47-\udc4a\udc5f-\udc61\udc80-\udcaf\udcc4\udcc5\udcc7\udd80-\uddae\uddd8-\udddb\ude00-\ude2f\ude44\ude80-\udeaa\udeb8\udf00-\udf1a\udf40-\udf46]|\ud806[\udc00-\udc2b\udca0-\udcdf\udcff-\udd06\udd09\udd0c-\udd13\udd15\udd16\udd18-\udd2f\udd3f\udd41\udda0-\udda7\uddaa-\uddd0\udde1\udde3\ude00\ude0b-\ude32\ude3a\ude50\ude5c-\ude89\ude9d\udeb0-\udef8]|\ud807[\udc00-\udc08\udc0a-\udc2e\udc40\udc72-\udc8f\udd00-\udd06\udd08\udd09\udd0b-\udd30\udd46\udd60-\udd65\udd67\udd68\udd6a-\udd89\udd98\udee0-\udef2\udfb0]|\ud808[\udc00-\udf99]|\ud809[\udc80-\udd43]|\ud80b[\udf90-\udff0]|[\ud80c\ud81c-\ud820\ud822\ud840-\ud868\ud86a-\ud86c\ud86f-\ud872\ud874-\ud879\ud880-\ud883][\udc00-\udfff]|\ud80d[\udc00-\udc2e]|\ud811[\udc00-\ude46]|\ud81a[\udc00-\ude38\ude40-\ude5e\ude70-\udebe\uded0-\udeed\udf00-\udf2f\udf40-\udf43\udf63-\udf77\udf7d-\udf8f]|\ud81b[\ude40-\ude7f\udf00-\udf4a\udf50\udf93-\udf9f\udfe0\udfe1\udfe3]|\ud821[\udc00-\udff7]|\ud823[\udc00-\udcd5\udd00-\udd08]|\ud82b[\udff0-\udff3\udff5-\udffb\udffd\udffe]|\ud82c[\udc00-\udd22\udd50-\udd52\udd64-\udd67\udd70-\udefb]|\ud82f[\udc00-\udc6a\udc70-\udc7c\udc80-\udc88\udc90-\udc99]|\ud835[\udc00-\udc54\udc56-\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd1e-\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd52-\udea5\udea8-\udec0\udec2-\udeda\udedc-\udefa\udefc-\udf14\udf16-\udf34\udf36-\udf4e\udf50-\udf6e\udf70-\udf88\udf8a-\udfa8\udfaa-\udfc2\udfc4-\udfcb]|\ud837[\udf00-\udf1e]|\ud838[\udd00-\udd2c\udd37-\udd3d\udd4e\ude90-\udead\udec0-\udeeb]|\ud839[\udfe0-\udfe6\udfe8-\udfeb\udfed\udfee\udff0-\udffe]|\ud83a[\udc00-\udcc4\udd00-\udd43\udd4b]|\ud83b[\ude00-\ude03\ude05-\ude1f\ude21\ude22\ude24\ude27\ude29-\ude32\ude34-\ude37\ude39\ude3b\ude42\ude47\ude49\ude4b\ude4d-\ude4f\ude51\ude52\ude54\ude57\ude59\ude5b\ude5d\ude5f\ude61\ude62\ude64\ude67-\ude6a\ude6c-\ude72\ude74-\ude77\ude79-\ude7c\ude7e\ude80-\ude89\ude8b-\ude9b\udea1-\udea3\udea5-\udea9\udeab-\udebb]|\ud869[\udc00-\udedf\udf00-\udfff]|\ud86d[\udc00-\udf38\udf40-\udfff]|\ud86e[\udc00-\udc1d\udc20-\udfff]|\ud873[\udc00-\udea1\udeb0-\udfff]|\ud87a[\udc00-\udfe0]|\ud87e[\udc00-\ude1d]|\ud884[\udc00-\udf4a]"},{name:"LC",alias:"Cased_Letter",bmp:"A-Za-zµÀ-ÖØ-öø-ƺƼ-ƿDŽ-ʓʕ-ʯͰ-ͳͶͷͻ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՠ-ֈႠ-ჅჇჍა-ჺჽ-ჿᎠ-Ᏽᏸ-ᏽᲀ-ᲈᲐ-ᲺᲽ-Ჿᴀ-ᴫᵫ-ᵷᵹ-ᶚḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℴℹℼ-ℿⅅ-ⅉⅎↃↄⰀ-ⱻⱾ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭꙀ-ꙭꚀ-ꚛꜢ-ꝯꝱ-ꞇꞋ-ꞎꞐ-ꟊꟐꟑꟓꟕ-ꟙꟵꟶꟺꬰ-ꭚꭠ-ꭨꭰ-ꮿff-stﬓ-ﬗA-Za-z",astral:"\ud801[\udc00-\udc4f\udcb0-\udcd3\udcd8-\udcfb\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc]|\ud803[\udc80-\udcb2\udcc0-\udcf2]|\ud806[\udca0-\udcdf]|\ud81b[\ude40-\ude7f]|\ud835[\udc00-\udc54\udc56-\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd1e-\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd52-\udea5\udea8-\udec0\udec2-\udeda\udedc-\udefa\udefc-\udf14\udf16-\udf34\udf36-\udf4e\udf50-\udf6e\udf70-\udf88\udf8a-\udfa8\udfaa-\udfc2\udfc4-\udfcb]|\ud837[\udf00-\udf09\udf0b-\udf1e]|\ud83a[\udd00-\udd43]"},{name:"Ll",alias:"Lowercase_Letter",bmp:"a-zµß-öø-ÿāăąćĉċčďđēĕėęěĝğġģĥħĩīĭįıijĵķĸĺļľŀłńņňʼnŋōŏőœŕŗřśŝşšţťŧũūŭůűųŵŷźżž-ƀƃƅƈƌƍƒƕƙ-ƛƞơƣƥƨƪƫƭưƴƶƹƺƽ-ƿdžljnjǎǐǒǔǖǘǚǜǝǟǡǣǥǧǩǫǭǯǰdzǵǹǻǽǿȁȃȅȇȉȋȍȏȑȓȕȗșțȝȟȡȣȥȧȩȫȭȯȱȳ-ȹȼȿɀɂɇɉɋɍɏ-ʓʕ-ʯͱͳͷͻ-ͽΐά-ώϐϑϕ-ϗϙϛϝϟϡϣϥϧϩϫϭϯ-ϳϵϸϻϼа-џѡѣѥѧѩѫѭѯѱѳѵѷѹѻѽѿҁҋҍҏґғҕҗҙқҝҟҡңҥҧҩҫҭүұҳҵҷҹһҽҿӂӄӆӈӊӌӎӏӑӓӕӗәӛӝӟӡӣӥӧөӫӭӯӱӳӵӷӹӻӽӿԁԃԅԇԉԋԍԏԑԓԕԗԙԛԝԟԡԣԥԧԩԫԭԯՠ-ֈა-ჺჽ-ჿᏸ-ᏽᲀ-ᲈᴀ-ᴫᵫ-ᵷᵹ-ᶚḁḃḅḇḉḋḍḏḑḓḕḗḙḛḝḟḡḣḥḧḩḫḭḯḱḳḵḷḹḻḽḿṁṃṅṇṉṋṍṏṑṓṕṗṙṛṝṟṡṣṥṧṩṫṭṯṱṳṵṷṹṻṽṿẁẃẅẇẉẋẍẏẑẓẕ-ẝẟạảấầẩẫậắằẳẵặẹẻẽếềểễệỉịọỏốồổỗộớờởỡợụủứừửữựỳỵỷỹỻỽỿ-ἇἐ-ἕἠ-ἧἰ-ἷὀ-ὅὐ-ὗὠ-ὧὰ-ώᾀ-ᾇᾐ-ᾗᾠ-ᾧᾰ-ᾴᾶᾷιῂ-ῄῆῇῐ-ΐῖῗῠ-ῧῲ-ῴῶῷℊℎℏℓℯℴℹℼℽⅆ-ⅉⅎↄⰰ-ⱟⱡⱥⱦⱨⱪⱬⱱⱳⱴⱶ-ⱻⲁⲃⲅⲇⲉⲋⲍⲏⲑⲓⲕⲗⲙⲛⲝⲟⲡⲣⲥⲧⲩⲫⲭⲯⲱⲳⲵⲷⲹⲻⲽⲿⳁⳃⳅⳇⳉⳋⳍⳏⳑⳓⳕⳗⳙⳛⳝⳟⳡⳣⳤⳬⳮⳳⴀ-ⴥⴧⴭꙁꙃꙅꙇꙉꙋꙍꙏꙑꙓꙕꙗꙙꙛꙝꙟꙡꙣꙥꙧꙩꙫꙭꚁꚃꚅꚇꚉꚋꚍꚏꚑꚓꚕꚗꚙꚛꜣꜥꜧꜩꜫꜭꜯ-ꜱꜳꜵꜷꜹꜻꜽꜿꝁꝃꝅꝇꝉꝋꝍꝏꝑꝓꝕꝗꝙꝛꝝꝟꝡꝣꝥꝧꝩꝫꝭꝯꝱ-ꝸꝺꝼꝿꞁꞃꞅꞇꞌꞎꞑꞓ-ꞕꞗꞙꞛꞝꞟꞡꞣꞥꞧꞩꞯꞵꞷꞹꞻꞽꞿꟁꟃꟈꟊꟑꟓꟕꟗꟙꟶꟺꬰ-ꭚꭠ-ꭨꭰ-ꮿff-stﬓ-ﬗa-z",astral:"\ud801[\udc28-\udc4f\udcd8-\udcfb\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc]|\ud803[\udcc0-\udcf2]|\ud806[\udcc0-\udcdf]|\ud81b[\ude60-\ude7f]|\ud835[\udc1a-\udc33\udc4e-\udc54\udc56-\udc67\udc82-\udc9b\udcb6-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udccf\udcea-\udd03\udd1e-\udd37\udd52-\udd6b\udd86-\udd9f\uddba-\uddd3\uddee-\ude07\ude22-\ude3b\ude56-\ude6f\ude8a-\udea5\udec2-\udeda\udedc-\udee1\udefc-\udf14\udf16-\udf1b\udf36-\udf4e\udf50-\udf55\udf70-\udf88\udf8a-\udf8f\udfaa-\udfc2\udfc4-\udfc9\udfcb]|\ud837[\udf00-\udf09\udf0b-\udf1e]|\ud83a[\udd22-\udd43]"},{name:"Lm",alias:"Modifier_Letter",bmp:"ʰ-ˁˆ-ˑˠ-ˤˬˮʹͺՙـۥۦߴߵߺࠚࠤࠨࣉॱๆໆჼៗᡃᪧᱸ-ᱽᴬ-ᵪᵸᶛ-ᶿⁱⁿₐ-ₜⱼⱽⵯⸯ々〱-〵〻ゝゞー-ヾꀕꓸ-ꓽꘌꙿꚜꚝꜗ-ꜟꝰꞈꟲ-ꟴꟸꟹꧏꧦꩰꫝꫳꫴꭜ-ꭟꭩー゙゚",astral:"\ud801[\udf80-\udf85\udf87-\udfb0\udfb2-\udfba]|\ud81a[\udf40-\udf43]|\ud81b[\udf93-\udf9f\udfe0\udfe1\udfe3]|\ud82b[\udff0-\udff3\udff5-\udffb\udffd\udffe]|\ud838[\udd37-\udd3d]|𞥋"},{name:"Lo",alias:"Other_Letter",bmp:"ªºƻǀ-ǃʔא-תׯ-ײؠ-ؿف-يٮٯٱ-ۓەۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪࠀ-ࠕࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣈऄ-हऽॐक़-ॡॲ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๅກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎᄀ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛱ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៜᠠ-ᡂᡄ-ᡸᢀ-ᢄᢇ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱷᳩ-ᳬᳮ-ᳳᳵᳶᳺℵ-ℸⴰ-ⵧⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ〆〼ぁ-ゖゟァ-ヺヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꀔꀖ-ꒌꓐ-ꓷꔀ-ꘋꘐ-ꘟꘪꘫꙮꚠ-ꛥꞏꟷꟻ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧠ-ꧤꧧ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩯꩱ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛꫜꫠ-ꫪꫲꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎יִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼヲ-ッア-ンᅠ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",astral:"\ud800[\udc00-\udc0b\udc0d-\udc26\udc28-\udc3a\udc3c\udc3d\udc3f-\udc4d\udc50-\udc5d\udc80-\udcfa\ude80-\ude9c\udea0-\uded0\udf00-\udf1f\udf2d-\udf40\udf42-\udf49\udf50-\udf75\udf80-\udf9d\udfa0-\udfc3\udfc8-\udfcf]|\ud801[\udc50-\udc9d\udd00-\udd27\udd30-\udd63\ude00-\udf36\udf40-\udf55\udf60-\udf67]|\ud802[\udc00-\udc05\udc08\udc0a-\udc35\udc37\udc38\udc3c\udc3f-\udc55\udc60-\udc76\udc80-\udc9e\udce0-\udcf2\udcf4\udcf5\udd00-\udd15\udd20-\udd39\udd80-\uddb7\uddbe\uddbf\ude00\ude10-\ude13\ude15-\ude17\ude19-\ude35\ude60-\ude7c\ude80-\ude9c\udec0-\udec7\udec9-\udee4\udf00-\udf35\udf40-\udf55\udf60-\udf72\udf80-\udf91]|\ud803[\udc00-\udc48\udd00-\udd23\ude80-\udea9\udeb0\udeb1\udf00-\udf1c\udf27\udf30-\udf45\udf70-\udf81\udfb0-\udfc4\udfe0-\udff6]|\ud804[\udc03-\udc37\udc71\udc72\udc75\udc83-\udcaf\udcd0-\udce8\udd03-\udd26\udd44\udd47\udd50-\udd72\udd76\udd83-\uddb2\uddc1-\uddc4\uddda\udddc\ude00-\ude11\ude13-\ude2b\ude80-\ude86\ude88\ude8a-\ude8d\ude8f-\ude9d\ude9f-\udea8\udeb0-\udede\udf05-\udf0c\udf0f\udf10\udf13-\udf28\udf2a-\udf30\udf32\udf33\udf35-\udf39\udf3d\udf50\udf5d-\udf61]|\ud805[\udc00-\udc34\udc47-\udc4a\udc5f-\udc61\udc80-\udcaf\udcc4\udcc5\udcc7\udd80-\uddae\uddd8-\udddb\ude00-\ude2f\ude44\ude80-\udeaa\udeb8\udf00-\udf1a\udf40-\udf46]|\ud806[\udc00-\udc2b\udcff-\udd06\udd09\udd0c-\udd13\udd15\udd16\udd18-\udd2f\udd3f\udd41\udda0-\udda7\uddaa-\uddd0\udde1\udde3\ude00\ude0b-\ude32\ude3a\ude50\ude5c-\ude89\ude9d\udeb0-\udef8]|\ud807[\udc00-\udc08\udc0a-\udc2e\udc40\udc72-\udc8f\udd00-\udd06\udd08\udd09\udd0b-\udd30\udd46\udd60-\udd65\udd67\udd68\udd6a-\udd89\udd98\udee0-\udef2\udfb0]|\ud808[\udc00-\udf99]|\ud809[\udc80-\udd43]|\ud80b[\udf90-\udff0]|[\ud80c\ud81c-\ud820\ud822\ud840-\ud868\ud86a-\ud86c\ud86f-\ud872\ud874-\ud879\ud880-\ud883][\udc00-\udfff]|\ud80d[\udc00-\udc2e]|\ud811[\udc00-\ude46]|\ud81a[\udc00-\ude38\ude40-\ude5e\ude70-\udebe\uded0-\udeed\udf00-\udf2f\udf63-\udf77\udf7d-\udf8f]|\ud81b[\udf00-\udf4a\udf50]|\ud821[\udc00-\udff7]|\ud823[\udc00-\udcd5\udd00-\udd08]|\ud82c[\udc00-\udd22\udd50-\udd52\udd64-\udd67\udd70-\udefb]|\ud82f[\udc00-\udc6a\udc70-\udc7c\udc80-\udc88\udc90-\udc99]|𝼊|\ud838[\udd00-\udd2c\udd4e\ude90-\udead\udec0-\udeeb]|\ud839[\udfe0-\udfe6\udfe8-\udfeb\udfed\udfee\udff0-\udffe]|\ud83a[\udc00-\udcc4]|\ud83b[\ude00-\ude03\ude05-\ude1f\ude21\ude22\ude24\ude27\ude29-\ude32\ude34-\ude37\ude39\ude3b\ude42\ude47\ude49\ude4b\ude4d-\ude4f\ude51\ude52\ude54\ude57\ude59\ude5b\ude5d\ude5f\ude61\ude62\ude64\ude67-\ude6a\ude6c-\ude72\ude74-\ude77\ude79-\ude7c\ude7e\ude80-\ude89\ude8b-\ude9b\udea1-\udea3\udea5-\udea9\udeab-\udebb]|\ud869[\udc00-\udedf\udf00-\udfff]|\ud86d[\udc00-\udf38\udf40-\udfff]|\ud86e[\udc00-\udc1d\udc20-\udfff]|\ud873[\udc00-\udea1\udeb0-\udfff]|\ud87a[\udc00-\udfe0]|\ud87e[\udc00-\ude1d]|\ud884[\udc00-\udf4a]"},{name:"Lt",alias:"Titlecase_Letter",bmp:"DžLjNjDzᾈ-ᾏᾘ-ᾟᾨ-ᾯᾼῌῼ"},{name:"Lu",alias:"Uppercase_Letter",bmp:"A-ZÀ-ÖØ-ÞĀĂĄĆĈĊČĎĐĒĔĖĘĚĜĞĠĢĤĦĨĪĬĮİIJĴĶĹĻĽĿŁŃŅŇŊŌŎŐŒŔŖŘŚŜŞŠŢŤŦŨŪŬŮŰŲŴŶŸŹŻŽƁƂƄƆƇƉ-ƋƎ-ƑƓƔƖ-ƘƜƝƟƠƢƤƦƧƩƬƮƯƱ-ƳƵƷƸƼDŽLJNJǍǏǑǓǕǗǙǛǞǠǢǤǦǨǪǬǮDZǴǶ-ǸǺǼǾȀȂȄȆȈȊȌȎȐȒȔȖȘȚȜȞȠȢȤȦȨȪȬȮȰȲȺȻȽȾɁɃ-ɆɈɊɌɎͰͲͶͿΆΈ-ΊΌΎΏΑ-ΡΣ-ΫϏϒ-ϔϘϚϜϞϠϢϤϦϨϪϬϮϴϷϹϺϽ-ЯѠѢѤѦѨѪѬѮѰѲѴѶѸѺѼѾҀҊҌҎҐҒҔҖҘҚҜҞҠҢҤҦҨҪҬҮҰҲҴҶҸҺҼҾӀӁӃӅӇӉӋӍӐӒӔӖӘӚӜӞӠӢӤӦӨӪӬӮӰӲӴӶӸӺӼӾԀԂԄԆԈԊԌԎԐԒԔԖԘԚԜԞԠԢԤԦԨԪԬԮԱ-ՖႠ-ჅჇჍᎠ-ᏵᲐ-ᲺᲽ-ᲿḀḂḄḆḈḊḌḎḐḒḔḖḘḚḜḞḠḢḤḦḨḪḬḮḰḲḴḶḸḺḼḾṀṂṄṆṈṊṌṎṐṒṔṖṘṚṜṞṠṢṤṦṨṪṬṮṰṲṴṶṸṺṼṾẀẂẄẆẈẊẌẎẐẒẔẞẠẢẤẦẨẪẬẮẰẲẴẶẸẺẼẾỀỂỄỆỈỊỌỎỐỒỔỖỘỚỜỞỠỢỤỦỨỪỬỮỰỲỴỶỸỺỼỾἈ-ἏἘ-ἝἨ-ἯἸ-ἿὈ-ὍὙὛὝὟὨ-ὯᾸ-ΆῈ-ΉῘ-ΊῨ-ῬῸ-Ώℂℇℋ-ℍℐ-ℒℕℙ-ℝℤΩℨK-ℭℰ-ℳℾℿⅅↃⰀ-ⰯⱠⱢ-ⱤⱧⱩⱫⱭ-ⱰⱲⱵⱾ-ⲀⲂⲄⲆⲈⲊⲌⲎⲐⲒⲔⲖⲘⲚⲜⲞⲠⲢⲤⲦⲨⲪⲬⲮⲰⲲⲴⲶⲸⲺⲼⲾⳀⳂⳄⳆⳈⳊⳌⳎⳐⳒⳔⳖⳘⳚⳜⳞⳠⳢⳫⳭⳲꙀꙂꙄꙆꙈꙊꙌꙎꙐꙒꙔꙖꙘꙚꙜꙞꙠꙢꙤꙦꙨꙪꙬꚀꚂꚄꚆꚈꚊꚌꚎꚐꚒꚔꚖꚘꚚꜢꜤꜦꜨꜪꜬꜮꜲꜴꜶꜸꜺꜼꜾꝀꝂꝄꝆꝈꝊꝌꝎꝐꝒꝔꝖꝘꝚꝜꝞꝠꝢꝤꝦꝨꝪꝬꝮꝹꝻꝽꝾꞀꞂꞄꞆꞋꞍꞐꞒꞖꞘꞚꞜꞞꞠꞢꞤꞦꞨꞪ-ꞮꞰ-ꞴꞶꞸꞺꞼꞾꟀꟂꟄ-ꟇꟉꟐꟖꟘꟵA-Z",astral:"\ud801[\udc00-\udc27\udcb0-\udcd3\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95]|\ud803[\udc80-\udcb2]|\ud806[\udca0-\udcbf]|\ud81b[\ude40-\ude5f]|\ud835[\udc00-\udc19\udc34-\udc4d\udc68-\udc81\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb5\udcd0-\udce9\udd04\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd38\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd6c-\udd85\udda0-\uddb9\uddd4-\udded\ude08-\ude21\ude3c-\ude55\ude70-\ude89\udea8-\udec0\udee2-\udefa\udf1c-\udf34\udf56-\udf6e\udf90-\udfa8\udfca]|\ud83a[\udd00-\udd21]"},{name:"M",alias:"Mark",bmp:"̀-ͯ҃-҉֑-ׇֽֿׁׂׅׄؐ-ًؚ-ٰٟۖ-ۜ۟-۪ۤۧۨ-ܑۭܰ-݊ަ-ް߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࢘-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣঁ-ঃ়া-ৄেৈো-্ৗৢৣ৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑੰੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣஂா-ூெ-ைொ-்ௗఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣඁ-ඃ්ා-ුූෘ-ෟෲෳัิ-ฺ็-๎ັິ-ຼ່-ໍ༹༘༙༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏႚ-ႝ፝-፟ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝᠋-᠍᠏ᢅᢆᢩᤠ-ᤫᤰ-᤻ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼᪰-ᫎᬀ-ᬄ᬴-᭄᭫-᭳ᮀ-ᮂᮡ-ᮭ᯦-᯳ᰤ-᰷᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿⃐-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯꙯-꙲ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣠-꣱ꣿꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀ꧥꨩ-ꨶꩃꩌꩍꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭ﬞ︀-️︠-︯",astral:"\ud800[\uddfd\udee0\udf76-\udf7a]|\ud802[\ude01-\ude03\ude05\ude06\ude0c-\ude0f\ude38-\ude3a\ude3f\udee5\udee6]|\ud803[\udd24-\udd27\udeab\udeac\udf46-\udf50\udf82-\udf85]|\ud804[\udc00-\udc02\udc38-\udc46\udc70\udc73\udc74\udc7f-\udc82\udcb0-\udcba\udcc2\udd00-\udd02\udd27-\udd34\udd45\udd46\udd73\udd80-\udd82\uddb3-\uddc0\uddc9-\uddcc\uddce\uddcf\ude2c-\ude37\ude3e\udedf-\udeea\udf00-\udf03\udf3b\udf3c\udf3e-\udf44\udf47\udf48\udf4b-\udf4d\udf57\udf62\udf63\udf66-\udf6c\udf70-\udf74]|\ud805[\udc35-\udc46\udc5e\udcb0-\udcc3\uddaf-\uddb5\uddb8-\uddc0\udddc\udddd\ude30-\ude40\udeab-\udeb7\udf1d-\udf2b]|\ud806[\udc2c-\udc3a\udd30-\udd35\udd37\udd38\udd3b-\udd3e\udd40\udd42\udd43\uddd1-\uddd7\uddda-\udde0\udde4\ude01-\ude0a\ude33-\ude39\ude3b-\ude3e\ude47\ude51-\ude5b\ude8a-\ude99]|\ud807[\udc2f-\udc36\udc38-\udc3f\udc92-\udca7\udca9-\udcb6\udd31-\udd36\udd3a\udd3c\udd3d\udd3f-\udd45\udd47\udd8a-\udd8e\udd90\udd91\udd93-\udd97\udef3-\udef6]|\ud81a[\udef0-\udef4\udf30-\udf36]|\ud81b[\udf4f\udf51-\udf87\udf8f-\udf92\udfe4\udff0\udff1]|\ud82f[\udc9d\udc9e]|\ud833[\udf00-\udf2d\udf30-\udf46]|\ud834[\udd65-\udd69\udd6d-\udd72\udd7b-\udd82\udd85-\udd8b\uddaa-\uddad\ude42-\ude44]|\ud836[\ude00-\ude36\ude3b-\ude6c\ude75\ude84\ude9b-\ude9f\udea1-\udeaf]|\ud838[\udc00-\udc06\udc08-\udc18\udc1b-\udc21\udc23\udc24\udc26-\udc2a\udd30-\udd36\udeae\udeec-\udeef]|\ud83a[\udcd0-\udcd6\udd44-\udd4a]|\udb40[\udd00-\uddef]"},{name:"Mc",alias:"Spacing_Mark",bmp:"ःऻा-ीॉ-ौॎॏংঃা-ীেৈোৌৗਃਾ-ੀઃા-ીૉોૌଂଃାୀେୈୋୌୗாிுூெ-ைொ-ௌௗఁ-ఃు-ౄಂಃಾೀ-ೄೇೈೊೋೕೖംഃാ-ീെ-ൈൊ-ൌൗංඃා-ෑෘ-ෟෲෳ༾༿ཿါာေးျြၖၗၢ-ၤၧ-ၭႃႄႇ-ႌႏႚ-ႜ᜕᜴ាើ-ៅះៈᤣ-ᤦᤩ-ᤫᤰᤱᤳ-ᤸᨙᨚᩕᩗᩡᩣᩤᩭ-ᩲᬄᬵᬻᬽ-ᭁᭃ᭄ᮂᮡᮦᮧ᮪ᯧᯪ-ᯬᯮ᯲᯳ᰤ-ᰫᰴᰵ᳡᳷〮〯ꠣꠤꠧꢀꢁꢴ-ꣃꥒ꥓ꦃꦴꦵꦺꦻꦾ-꧀ꨯꨰꨳꨴꩍꩻꩽꫫꫮꫯꫵꯣꯤꯦꯧꯩꯪ꯬",astral:"\ud804[\udc00\udc02\udc82\udcb0-\udcb2\udcb7\udcb8\udd2c\udd45\udd46\udd82\uddb3-\uddb5\uddbf\uddc0\uddce\ude2c-\ude2e\ude32\ude33\ude35\udee0-\udee2\udf02\udf03\udf3e\udf3f\udf41-\udf44\udf47\udf48\udf4b-\udf4d\udf57\udf62\udf63]|\ud805[\udc35-\udc37\udc40\udc41\udc45\udcb0-\udcb2\udcb9\udcbb-\udcbe\udcc1\uddaf-\uddb1\uddb8-\uddbb\uddbe\ude30-\ude32\ude3b\ude3c\ude3e\udeac\udeae\udeaf\udeb6\udf20\udf21\udf26]|\ud806[\udc2c-\udc2e\udc38\udd30-\udd35\udd37\udd38\udd3d\udd40\udd42\uddd1-\uddd3\udddc-\udddf\udde4\ude39\ude57\ude58\ude97]|\ud807[\udc2f\udc3e\udca9\udcb1\udcb4\udd8a-\udd8e\udd93\udd94\udd96\udef5\udef6]|\ud81b[\udf51-\udf87\udff0\udff1]|\ud834[\udd65\udd66\udd6d-\udd72]"},{name:"Me",alias:"Enclosing_Mark",bmp:"҈҉᪾⃝-⃠⃢-⃤꙰-꙲"},{name:"Mn",alias:"Nonspacing_Mark",bmp:"̀-ͯ҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-ٰٟۖ-ۜ۟-۪ۤۧۨ-ܑۭܰ-݊ަ-ް߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛࢘-࢟࣊-ࣣ࣡-ंऺ़ु-ै्॑-ॗॢॣঁ়ু-ৄ্ৢৣ৾ਁਂ਼ੁੂੇੈੋ-੍ੑੰੱੵઁં઼ુ-ૅેૈ્ૢૣૺ-૿ଁ଼ିୁ-ୄ୍୕ୖୢୣஂீ்ఀఄ఼ా-ీె-ైొ-్ౕౖౢౣಁ಼ಿೆೌ್ೢೣഀഁ഻഼ു-ൄ്ൢൣඁ්ි-ුූัิ-ฺ็-๎ັິ-ຼ່-ໍཱ༹༘༙༵༷-ཾྀ-྄྆྇ྍ-ྗྙ-ྼ࿆ိ-ူဲ-့္်ွှၘၙၞ-ၠၱ-ၴႂႅႆႍႝ፝-፟ᜒ-᜔ᜲᜳᝒᝓᝲᝳ឴឵ិ-ួំ៉-៓៝᠋-᠍᠏ᢅᢆᢩᤠ-ᤢᤧᤨᤲ᤹-᤻ᨘᨗᨛᩖᩘ-ᩞ᩠ᩢᩥ-ᩬᩳ-᩿᩼᪰-᪽ᪿ-ᫎᬀ-ᬃ᬴ᬶ-ᬺᬼᭂ᭫-᭳ᮀᮁᮢ-ᮥᮨᮩ᮫-ᮭ᯦ᯨᯩᯭᯯ-ᯱᰬ-ᰳᰶ᰷᳐-᳔᳒-᳢᳠-᳨᳭᳴᳸᳹᷀-᷿⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〭꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠥꠦ꠬꣄ꣅ꣠-꣱ꣿꤦ-꤭ꥇ-ꥑꦀ-ꦂ꦳ꦶ-ꦹꦼꦽꧥꨩ-ꨮꨱꨲꨵꨶꩃꩌꩼꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫬꫭ꫶ꯥꯨ꯭ﬞ︀-️︠-︯",astral:"\ud800[\uddfd\udee0\udf76-\udf7a]|\ud802[\ude01-\ude03\ude05\ude06\ude0c-\ude0f\ude38-\ude3a\ude3f\udee5\udee6]|\ud803[\udd24-\udd27\udeab\udeac\udf46-\udf50\udf82-\udf85]|\ud804[\udc01\udc38-\udc46\udc70\udc73\udc74\udc7f-\udc81\udcb3-\udcb6\udcb9\udcba\udcc2\udd00-\udd02\udd27-\udd2b\udd2d-\udd34\udd73\udd80\udd81\uddb6-\uddbe\uddc9-\uddcc\uddcf\ude2f-\ude31\ude34\ude36\ude37\ude3e\udedf\udee3-\udeea\udf00\udf01\udf3b\udf3c\udf40\udf66-\udf6c\udf70-\udf74]|\ud805[\udc38-\udc3f\udc42-\udc44\udc46\udc5e\udcb3-\udcb8\udcba\udcbf\udcc0\udcc2\udcc3\uddb2-\uddb5\uddbc\uddbd\uddbf\uddc0\udddc\udddd\ude33-\ude3a\ude3d\ude3f\ude40\udeab\udead\udeb0-\udeb5\udeb7\udf1d-\udf1f\udf22-\udf25\udf27-\udf2b]|\ud806[\udc2f-\udc37\udc39\udc3a\udd3b\udd3c\udd3e\udd43\uddd4-\uddd7\uddda\udddb\udde0\ude01-\ude0a\ude33-\ude38\ude3b-\ude3e\ude47\ude51-\ude56\ude59-\ude5b\ude8a-\ude96\ude98\ude99]|\ud807[\udc30-\udc36\udc38-\udc3d\udc3f\udc92-\udca7\udcaa-\udcb0\udcb2\udcb3\udcb5\udcb6\udd31-\udd36\udd3a\udd3c\udd3d\udd3f-\udd45\udd47\udd90\udd91\udd95\udd97\udef3\udef4]|\ud81a[\udef0-\udef4\udf30-\udf36]|\ud81b[\udf4f\udf8f-\udf92\udfe4]|\ud82f[\udc9d\udc9e]|\ud833[\udf00-\udf2d\udf30-\udf46]|\ud834[\udd67-\udd69\udd7b-\udd82\udd85-\udd8b\uddaa-\uddad\ude42-\ude44]|\ud836[\ude00-\ude36\ude3b-\ude6c\ude75\ude84\ude9b-\ude9f\udea1-\udeaf]|\ud838[\udc00-\udc06\udc08-\udc18\udc1b-\udc21\udc23\udc24\udc26-\udc2a\udd30-\udd36\udeae\udeec-\udeef]|\ud83a[\udcd0-\udcd6\udd44-\udd4a]|\udb40[\udd00-\uddef]"},{name:"N",alias:"Number",bmp:"0-9²³¹¼-¾٠-٩۰-۹߀-߉०-९০-৯৴-৹੦-੯૦-૯୦-୯୲-୷௦-௲౦-౯౸-౾೦-೯൘-൞൦-൸෦-෯๐-๙໐-໙༠-༳၀-၉႐-႙፩-፼ᛮ-ᛰ០-៩៰-៹᠐-᠙᥆-᥏᧐-᧚᪀-᪉᪐-᪙᭐-᭙᮰-᮹᱀-᱉᱐-᱙⁰⁴-⁹₀-₉⅐-ↂↅ-↉①-⒛⓪-⓿❶-➓⳽〇〡-〩〸-〺㆒-㆕㈠-㈩㉈-㉏㉑-㉟㊀-㊉㊱-㊿꘠-꘩ꛦ-ꛯ꠰-꠵꣐-꣙꤀-꤉꧐-꧙꧰-꧹꩐-꩙꯰-꯹0-9",astral:"\ud800[\udd07-\udd33\udd40-\udd78\udd8a\udd8b\udee1-\udefb\udf20-\udf23\udf41\udf4a\udfd1-\udfd5]|\ud801[\udca0-\udca9]|\ud802[\udc58-\udc5f\udc79-\udc7f\udca7-\udcaf\udcfb-\udcff\udd16-\udd1b\uddbc\uddbd\uddc0-\uddcf\uddd2-\uddff\ude40-\ude48\ude7d\ude7e\ude9d-\ude9f\udeeb-\udeef\udf58-\udf5f\udf78-\udf7f\udfa9-\udfaf]|\ud803[\udcfa-\udcff\udd30-\udd39\ude60-\ude7e\udf1d-\udf26\udf51-\udf54\udfc5-\udfcb]|\ud804[\udc52-\udc6f\udcf0-\udcf9\udd36-\udd3f\uddd0-\uddd9\udde1-\uddf4\udef0-\udef9]|\ud805[\udc50-\udc59\udcd0-\udcd9\ude50-\ude59\udec0-\udec9\udf30-\udf3b]|\ud806[\udce0-\udcf2\udd50-\udd59]|\ud807[\udc50-\udc6c\udd50-\udd59\udda0-\udda9\udfc0-\udfd4]|\ud809[\udc00-\udc6e]|\ud81a[\ude60-\ude69\udec0-\udec9\udf50-\udf59\udf5b-\udf61]|\ud81b[\ude80-\ude96]|\ud834[\udee0-\udef3\udf60-\udf78]|\ud835[\udfce-\udfff]|\ud838[\udd40-\udd49\udef0-\udef9]|\ud83a[\udcc7-\udccf\udd50-\udd59]|\ud83b[\udc71-\udcab\udcad-\udcaf\udcb1-\udcb4\udd01-\udd2d\udd2f-\udd3d]|\ud83c[\udd00-\udd0c]|\ud83e[\udff0-\udff9]"},{name:"Nd",alias:"Decimal_Number",bmp:"0-9٠-٩۰-۹߀-߉०-९০-৯੦-੯૦-૯୦-୯௦-௯౦-౯೦-೯൦-൯෦-෯๐-๙໐-໙༠-༩၀-၉႐-႙០-៩᠐-᠙᥆-᥏᧐-᧙᪀-᪉᪐-᪙᭐-᭙᮰-᮹᱀-᱉᱐-᱙꘠-꘩꣐-꣙꤀-꤉꧐-꧙꧰-꧹꩐-꩙꯰-꯹0-9",astral:"\ud801[\udca0-\udca9]|\ud803[\udd30-\udd39]|\ud804[\udc66-\udc6f\udcf0-\udcf9\udd36-\udd3f\uddd0-\uddd9\udef0-\udef9]|\ud805[\udc50-\udc59\udcd0-\udcd9\ude50-\ude59\udec0-\udec9\udf30-\udf39]|\ud806[\udce0-\udce9\udd50-\udd59]|\ud807[\udc50-\udc59\udd50-\udd59\udda0-\udda9]|\ud81a[\ude60-\ude69\udec0-\udec9\udf50-\udf59]|\ud835[\udfce-\udfff]|\ud838[\udd40-\udd49\udef0-\udef9]|\ud83a[\udd50-\udd59]|\ud83e[\udff0-\udff9]"},{name:"Nl",alias:"Letter_Number",bmp:"ᛮ-ᛰⅠ-ↂↅ-ↈ〇〡-〩〸-〺ꛦ-ꛯ",astral:"\ud800[\udd40-\udd74\udf41\udf4a\udfd1-\udfd5]|\ud809[\udc00-\udc6e]"},{name:"No",alias:"Other_Number",bmp:"²³¹¼-¾৴-৹୲-୷௰-௲౸-౾൘-൞൰-൸༪-༳፩-፼៰-៹᧚⁰⁴-⁹₀-₉⅐-⅟↉①-⒛⓪-⓿❶-➓⳽㆒-㆕㈠-㈩㉈-㉏㉑-㉟㊀-㊉㊱-㊿꠰-꠵",astral:"\ud800[\udd07-\udd33\udd75-\udd78\udd8a\udd8b\udee1-\udefb\udf20-\udf23]|\ud802[\udc58-\udc5f\udc79-\udc7f\udca7-\udcaf\udcfb-\udcff\udd16-\udd1b\uddbc\uddbd\uddc0-\uddcf\uddd2-\uddff\ude40-\ude48\ude7d\ude7e\ude9d-\ude9f\udeeb-\udeef\udf58-\udf5f\udf78-\udf7f\udfa9-\udfaf]|\ud803[\udcfa-\udcff\ude60-\ude7e\udf1d-\udf26\udf51-\udf54\udfc5-\udfcb]|\ud804[\udc52-\udc65\udde1-\uddf4]|\ud805[\udf3a\udf3b]|\ud806[\udcea-\udcf2]|\ud807[\udc5a-\udc6c\udfc0-\udfd4]|\ud81a[\udf5b-\udf61]|\ud81b[\ude80-\ude96]|\ud834[\udee0-\udef3\udf60-\udf78]|\ud83a[\udcc7-\udccf]|\ud83b[\udc71-\udcab\udcad-\udcaf\udcb1-\udcb4\udd01-\udd2d\udd2f-\udd3d]|\ud83c[\udd00-\udd0c]"},{name:"P",alias:"Punctuation",bmp:"!-#%-\\*,-\\/:;\\?@\\[-\\]_\\{\\}¡§«¶·»¿;·՚-՟։֊־׀׃׆׳״؉؊،؍؛؝-؟٪-٭۔܀-܍߷-߹࠰-࠾࡞।॥॰৽੶૰౷಄෴๏๚๛༄-༒༔༺-༽྅࿐-࿔࿙࿚၊-၏჻፠-፨᐀᙮᚛᚜᛫-᛭᜵᜶។-៖៘-៚᠀-᠊᥄᥅᨞᨟᪠-᪦᪨-᪭᭚-᭠᭽᭾᯼-᯿᰻-᰿᱾᱿᳀-᳇᳓‐-‧‰-⁃⁅-⁑⁓-⁞⁽⁾₍₎⌈-⌋〈〉❨-❵⟅⟆⟦-⟯⦃-⦘⧘-⧛⧼⧽⳹-⳼⳾⳿⵰⸀-⸮⸰-⹏⹒-⹝、-〃〈-】〔-〟〰〽゠・꓾꓿꘍-꘏꙳꙾꛲-꛷꡴-꡷꣎꣏꣸-꣺꣼꤮꤯꥟꧁-꧍꧞꧟꩜-꩟꫞꫟꫰꫱꯫﴾﴿︐-︙︰-﹒﹔-﹡﹣﹨﹪﹫!-#%-*,-/:;?@[-]_{}⦅-・",astral:"\ud800[\udd00-\udd02\udf9f\udfd0]|𐕯|\ud802[\udc57\udd1f\udd3f\ude50-\ude58\ude7f\udef0-\udef6\udf39-\udf3f\udf99-\udf9c]|\ud803[\udead\udf55-\udf59\udf86-\udf89]|\ud804[\udc47-\udc4d\udcbb\udcbc\udcbe-\udcc1\udd40-\udd43\udd74\udd75\uddc5-\uddc8\uddcd\udddb\udddd-\udddf\ude38-\ude3d\udea9]|\ud805[\udc4b-\udc4f\udc5a\udc5b\udc5d\udcc6\uddc1-\uddd7\ude41-\ude43\ude60-\ude6c\udeb9\udf3c-\udf3e]|\ud806[\udc3b\udd44-\udd46\udde2\ude3f-\ude46\ude9a-\ude9c\ude9e-\udea2]|\ud807[\udc41-\udc45\udc70\udc71\udef7\udef8\udfff]|\ud809[\udc70-\udc74]|\ud80b[\udff1\udff2]|\ud81a[\ude6e\ude6f\udef5\udf37-\udf3b\udf44]|\ud81b[\ude97-\ude9a\udfe2]|𛲟|\ud836[\ude87-\ude8b]|\ud83a[\udd5e\udd5f]"},{name:"Pc",alias:"Connector_Punctuation",bmp:"_‿⁀⁔︳︴﹍-﹏_"},{name:"Pd",alias:"Dash_Punctuation",bmp:"\\-֊־᐀᠆‐-―⸗⸚⸺⸻⹀⹝〜〰゠︱︲﹘﹣-",astral:"𐺭"},{name:"Pe",alias:"Close_Punctuation",bmp:"\\)\\]\\}༻༽᚜⁆⁾₎⌉⌋〉❩❫❭❯❱❳❵⟆⟧⟩⟫⟭⟯⦄⦆⦈⦊⦌⦎⦐⦒⦔⦖⦘⧙⧛⧽⸣⸥⸧⸩⹖⹘⹚⹜〉》」』】〕〗〙〛〞〟﴾︘︶︸︺︼︾﹀﹂﹄﹈﹚﹜﹞)]}⦆」"},{name:"Pf",alias:"Final_Punctuation",bmp:"»’”›⸃⸅⸊⸍⸝⸡"},{name:"Pi",alias:"Initial_Punctuation",bmp:"«‘‛“‟‹⸂⸄⸉⸌⸜⸠"},{name:"Po",alias:"Other_Punctuation",bmp:"!-#%-'\\*,\\.\\/:;\\?@\\¡§¶·¿;·՚-՟։׀׃׆׳״؉؊،؍؛؝-؟٪-٭۔܀-܍߷-߹࠰-࠾࡞।॥॰৽੶૰౷಄෴๏๚๛༄-༒༔྅࿐-࿔࿙࿚၊-၏჻፠-፨᙮᛫-᛭᜵᜶។-៖៘-៚᠀-᠅᠇-᠊᥄᥅᨞᨟᪠-᪦᪨-᪭᭚-᭠᭽᭾᯼-᯿᰻-᰿᱾᱿᳀-᳇᳓‖‗†-‧‰-‸※-‾⁁-⁃⁇-⁑⁓⁕-⁞⳹-⳼⳾⳿⵰⸀⸁⸆-⸈⸋⸎-⸖⸘⸙⸛⸞⸟⸪-⸮⸰-⸹⸼-⸿⹁⹃-⹏⹒-⹔、-〃〽・꓾꓿꘍-꘏꙳꙾꛲-꛷꡴-꡷꣎꣏꣸-꣺꣼꤮꤯꥟꧁-꧍꧞꧟꩜-꩟꫞꫟꫰꫱꯫︐-︖︙︰﹅﹆﹉-﹌﹐-﹒﹔-﹗﹟-﹡﹨﹪﹫!-#%-'*,./:;?@\。、・",astral:"\ud800[\udd00-\udd02\udf9f\udfd0]|𐕯|\ud802[\udc57\udd1f\udd3f\ude50-\ude58\ude7f\udef0-\udef6\udf39-\udf3f\udf99-\udf9c]|\ud803[\udf55-\udf59\udf86-\udf89]|\ud804[\udc47-\udc4d\udcbb\udcbc\udcbe-\udcc1\udd40-\udd43\udd74\udd75\uddc5-\uddc8\uddcd\udddb\udddd-\udddf\ude38-\ude3d\udea9]|\ud805[\udc4b-\udc4f\udc5a\udc5b\udc5d\udcc6\uddc1-\uddd7\ude41-\ude43\ude60-\ude6c\udeb9\udf3c-\udf3e]|\ud806[\udc3b\udd44-\udd46\udde2\ude3f-\ude46\ude9a-\ude9c\ude9e-\udea2]|\ud807[\udc41-\udc45\udc70\udc71\udef7\udef8\udfff]|\ud809[\udc70-\udc74]|\ud80b[\udff1\udff2]|\ud81a[\ude6e\ude6f\udef5\udf37-\udf3b\udf44]|\ud81b[\ude97-\ude9a\udfe2]|𛲟|\ud836[\ude87-\ude8b]|\ud83a[\udd5e\udd5f]"},{name:"Ps",alias:"Open_Punctuation",bmp:"\\(\\[\\{༺༼᚛‚„⁅⁽₍⌈⌊〈❨❪❬❮❰❲❴⟅⟦⟨⟪⟬⟮⦃⦅⦇⦉⦋⦍⦏⦑⦓⦕⦗⧘⧚⧼⸢⸤⸦⸨⹂⹕⹗⹙⹛〈《「『【〔〖〘〚〝﴿︗︵︷︹︻︽︿﹁﹃﹇﹙﹛﹝([{⦅「"},{name:"S",alias:"Symbol",bmp:"\\$\\+<->\\^`\\|~¢-¦¨©¬®-±´¸×÷˂-˅˒-˟˥-˫˭˯-˿͵΄΅϶҂֍-֏؆-؈؋؎؏۞۩۽۾߶߾߿࢈৲৳৺৻૱୰௳-௺౿൏൹฿༁-༃༓༕-༗༚-༟༴༶༸྾-࿅࿇-࿌࿎࿏࿕-࿘႞႟᎐-᎙᙭៛᥀᧞-᧿᭡-᭪᭴-᭼᾽᾿-῁῍-῏῝-῟῭-`´῾⁄⁒⁺-⁼₊-₌₠-⃀℀℁℃-℆℈℉℔№-℘℞-℣℥℧℩℮℺℻⅀-⅄⅊-⅍⅏↊↋←-⌇⌌-⌨⌫-␦⑀-⑊⒜-ⓩ─-❧➔-⟄⟇-⟥⟰-⦂⦙-⧗⧜-⧻⧾-⭳⭶-⮕⮗-⯿⳥-⳪⹐⹑⺀-⺙⺛-⻳⼀-⿕⿰-⿻〄〒〓〠〶〷〾〿゛゜㆐㆑㆖-㆟㇀-㇣㈀-㈞㈪-㉇㉐㉠-㉿㊊-㊰㋀-㏿䷀-䷿꒐-꓆꜀-꜖꜠꜡꞉꞊꠨-꠫꠶-꠹꩷-꩹꭛꭪꭫﬩﮲-﯂﵀-﵏﷏﷼-﷿﹢﹤-﹦﹩$+<->^`|~¢-₩│-○�",astral:"\ud800[\udd37-\udd3f\udd79-\udd89\udd8c-\udd8e\udd90-\udd9c\udda0\uddd0-\uddfc]|\ud802[\udc77\udc78\udec8]|𑜿|\ud807[\udfd5-\udff1]|\ud81a[\udf3c-\udf3f\udf45]|𛲜|\ud833[\udf50-\udfc3]|\ud834[\udc00-\udcf5\udd00-\udd26\udd29-\udd64\udd6a-\udd6c\udd83\udd84\udd8c-\udda9\uddae-\uddea\ude00-\ude41\ude45\udf00-\udf56]|\ud835[\udec1\udedb\udefb\udf15\udf35\udf4f\udf6f\udf89\udfa9\udfc3]|\ud836[\udc00-\uddff\ude37-\ude3a\ude6d-\ude74\ude76-\ude83\ude85\ude86]|\ud838[\udd4f\udeff]|\ud83b[\udcac\udcb0\udd2e\udef0\udef1]|\ud83c[\udc00-\udc2b\udc30-\udc93\udca0-\udcae\udcb1-\udcbf\udcc1-\udccf\udcd1-\udcf5\udd0d-\uddad\udde6-\ude02\ude10-\ude3b\ude40-\ude48\ude50\ude51\ude60-\ude65\udf00-\udfff]|\ud83d[\udc00-\uded7\udedd-\udeec\udef0-\udefc\udf00-\udf73\udf80-\udfd8\udfe0-\udfeb\udff0]|\ud83e[\udc00-\udc0b\udc10-\udc47\udc50-\udc59\udc60-\udc87\udc90-\udcad\udcb0\udcb1\udd00-\ude53\ude60-\ude6d\ude70-\ude74\ude78-\ude7c\ude80-\ude86\ude90-\udeac\udeb0-\udeba\udec0-\udec5\uded0-\uded9\udee0-\udee7\udef0-\udef6\udf00-\udf92\udf94-\udfca]"},{name:"Sc",alias:"Currency_Symbol",bmp:"\\$¢-¥֏؋߾߿৲৳৻૱௹฿៛₠-⃀꠸﷼﹩$¢£¥₩",astral:"\ud807[\udfdd-\udfe0]|𞋿|𞲰"},{name:"Sk",alias:"Modifier_Symbol",bmp:"\\^`¨¯´¸˂-˅˒-˟˥-˫˭˯-˿͵΄΅࢈᾽᾿-῁῍-῏῝-῟῭-`´῾゛゜꜀-꜖꜠꜡꞉꞊꭛꭪꭫﮲-﯂^` ̄",astral:"\ud83c[\udffb-\udfff]"},{name:"Sm",alias:"Math_Symbol",bmp:"\\+<->\\|~¬±×÷϶؆-؈⁄⁒⁺-⁼₊-₌℘⅀-⅄⅋←-↔↚↛↠↣↦↮⇎⇏⇒⇔⇴-⋿⌠⌡⍼⎛-⎳⏜-⏡▷◁◸-◿♯⟀-⟄⟇-⟥⟰-⟿⤀-⦂⦙-⧗⧜-⧻⧾-⫿⬰-⭄⭇-⭌﬩﹢﹤-﹦+<->|~¬←-↓",astral:"\ud835[\udec1\udedb\udefb\udf15\udf35\udf4f\udf6f\udf89\udfa9\udfc3]|\ud83b[\udef0\udef1]"},{name:"So",alias:"Other_Symbol",bmp:"¦©®°҂֍֎؎؏۞۩۽۾߶৺୰௳-௸௺౿൏൹༁-༃༓༕-༗༚-༟༴༶༸྾-࿅࿇-࿌࿎࿏࿕-࿘႞႟᎐-᎙᙭᥀᧞-᧿᭡-᭪᭴-᭼℀℁℃-℆℈℉℔№℗℞-℣℥℧℩℮℺℻⅊⅌⅍⅏↊↋↕-↙↜-↟↡↢↤↥↧-↭↯-⇍⇐⇑⇓⇕-⇳⌀-⌇⌌-⌟⌢-⌨⌫-⍻⍽-⎚⎴-⏛⏢-␦⑀-⑊⒜-ⓩ─-▶▸-◀◂-◷☀-♮♰-❧➔-➿⠀-⣿⬀-⬯⭅⭆⭍-⭳⭶-⮕⮗-⯿⳥-⳪⹐⹑⺀-⺙⺛-⻳⼀-⿕⿰-⿻〄〒〓〠〶〷〾〿㆐㆑㆖-㆟㇀-㇣㈀-㈞㈪-㉇㉐㉠-㉿㊊-㊰㋀-㏿䷀-䷿꒐-꓆꠨-꠫꠶꠷꠹꩷-꩹﵀-﵏﷏﷽-﷿¦│■○�",astral:"\ud800[\udd37-\udd3f\udd79-\udd89\udd8c-\udd8e\udd90-\udd9c\udda0\uddd0-\uddfc]|\ud802[\udc77\udc78\udec8]|𑜿|\ud807[\udfd5-\udfdc\udfe1-\udff1]|\ud81a[\udf3c-\udf3f\udf45]|𛲜|\ud833[\udf50-\udfc3]|\ud834[\udc00-\udcf5\udd00-\udd26\udd29-\udd64\udd6a-\udd6c\udd83\udd84\udd8c-\udda9\uddae-\uddea\ude00-\ude41\ude45\udf00-\udf56]|\ud836[\udc00-\uddff\ude37-\ude3a\ude6d-\ude74\ude76-\ude83\ude85\ude86]|𞅏|\ud83b[\udcac\udd2e]|\ud83c[\udc00-\udc2b\udc30-\udc93\udca0-\udcae\udcb1-\udcbf\udcc1-\udccf\udcd1-\udcf5\udd0d-\uddad\udde6-\ude02\ude10-\ude3b\ude40-\ude48\ude50\ude51\ude60-\ude65\udf00-\udffa]|\ud83d[\udc00-\uded7\udedd-\udeec\udef0-\udefc\udf00-\udf73\udf80-\udfd8\udfe0-\udfeb\udff0]|\ud83e[\udc00-\udc0b\udc10-\udc47\udc50-\udc59\udc60-\udc87\udc90-\udcad\udcb0\udcb1\udd00-\ude53\ude60-\ude6d\ude70-\ude74\ude78-\ude7c\ude80-\ude86\ude90-\udeac\udeb0-\udeba\udec0-\udec5\uded0-\uded9\udee0-\udee7\udef0-\udef6\udf00-\udf92\udf94-\udfca]"},{name:"Z",alias:"Separator",bmp:"    - \u2028\u2029   "},{name:"Zl",alias:"Line_Separator",bmp:"\u2028"},{name:"Zp",alias:"Paragraph_Separator",bmp:"\u2029"},{name:"Zs",alias:"Space_Separator",bmp:"    -    "}]},88477:e=>{e.exports=[{name:"ASCII",bmp:"\0-"},{name:"Alphabetic",bmp:"A-Za-zªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͅͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈְ-ׇֽֿׁׂׅׄא-תׯ-ײؐ-ؚؠ-ٗٙ-ٟٮ-ۓە-ۜۡ-ۭۨ-ۯۺ-ۼۿܐ-ܿݍ-ޱߊ-ߪߴߵߺࠀ-ࠗࠚ-ࠬࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉࣔ-ࣣࣟ-ࣰࣩ-ऻऽ-ौॎ-ॐॕ-ॣॱ-ঃঅ-ঌএঐও-নপ-রলশ-হঽ-ৄেৈোৌৎৗড়ঢ়য়-ৣৰৱৼਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਾ-ੂੇੈੋੌੑਖ਼-ੜਫ਼ੰ-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽ-ૅે-ૉોૌૐૠ-ૣૹ-ૼଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽ-ୄେୈୋୌୖୗଡ଼ଢ଼ୟ-ୣୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-ௌௐௗఀ-ఃఅ-ఌఎ-ఐఒ-నప-హఽ-ౄె-ైొ-ౌౕౖౘ-ౚౝౠ-ౣಀ-ಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ-ೄೆ-ೈೊ-ೌೕೖೝೞೠ-ೣೱೲഀ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൌൎൔ-ൗൟ-ൣൺ-ൿඁ-ඃඅ-ඖක-නඳ-රලව-ෆා-ුූෘ-ෟෲෳก-ฺเ-ๆํກຂຄຆ-ຊຌ-ຣລວ-ູົ-ຽເ-ໄໆໍໜ-ໟༀཀ-ཇཉ-ཬཱ-ཱྀྈ-ྗྙ-ྼက-ံးျ-ဿၐ-ႏႚ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜓᜟ-ᜳᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-ឳា-ៈៗៜᠠ-ᡸᢀ-ᢪᢰ-ᣵᤀ-ᤞᤠ-ᤫᤰ-ᤸᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨛᨠ-ᩞᩡ-ᩴᪧᪿᫀᫌ-ᫎᬀ-ᬳᬵ-ᭃᭅ-ᭌᮀ-ᮩᮬ-ᮯᮺ-ᯥᯧ-ᯱᰀ-ᰶᱍ-ᱏᱚ-ᱽᲀ-ᲈᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿᷧ-ᷴḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⒶ-ⓩⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙴ-ꙻꙿ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟊꟐꟑꟓꟕ-ꟙꟲ-ꠅꠇ-ꠧꡀ-ꡳꢀ-ꣃꣅꣲ-ꣷꣻꣽ-ꣿꤊ-ꤪꤰ-ꥒꥠ-ꥼꦀ-ꦲꦴ-ꦿꧏꧠ-ꧯꧺ-ꧾꨀ-ꨶꩀ-ꩍꩠ-ꩶꩺ-ꪾꫀꫂꫛ-ꫝꫠ-ꫯꫲ-ꫵꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯪ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",astral:"\ud800[\udc00-\udc0b\udc0d-\udc26\udc28-\udc3a\udc3c\udc3d\udc3f-\udc4d\udc50-\udc5d\udc80-\udcfa\udd40-\udd74\ude80-\ude9c\udea0-\uded0\udf00-\udf1f\udf2d-\udf4a\udf50-\udf7a\udf80-\udf9d\udfa0-\udfc3\udfc8-\udfcf\udfd1-\udfd5]|\ud801[\udc00-\udc9d\udcb0-\udcd3\udcd8-\udcfb\udd00-\udd27\udd30-\udd63\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc\ude00-\udf36\udf40-\udf55\udf60-\udf67\udf80-\udf85\udf87-\udfb0\udfb2-\udfba]|\ud802[\udc00-\udc05\udc08\udc0a-\udc35\udc37\udc38\udc3c\udc3f-\udc55\udc60-\udc76\udc80-\udc9e\udce0-\udcf2\udcf4\udcf5\udd00-\udd15\udd20-\udd39\udd80-\uddb7\uddbe\uddbf\ude00-\ude03\ude05\ude06\ude0c-\ude13\ude15-\ude17\ude19-\ude35\ude60-\ude7c\ude80-\ude9c\udec0-\udec7\udec9-\udee4\udf00-\udf35\udf40-\udf55\udf60-\udf72\udf80-\udf91]|\ud803[\udc00-\udc48\udc80-\udcb2\udcc0-\udcf2\udd00-\udd27\ude80-\udea9\udeab\udeac\udeb0\udeb1\udf00-\udf1c\udf27\udf30-\udf45\udf70-\udf81\udfb0-\udfc4\udfe0-\udff6]|\ud804[\udc00-\udc45\udc71-\udc75\udc82-\udcb8\udcc2\udcd0-\udce8\udd00-\udd32\udd44-\udd47\udd50-\udd72\udd76\udd80-\uddbf\uddc1-\uddc4\uddce\uddcf\uddda\udddc\ude00-\ude11\ude13-\ude34\ude37\ude3e\ude80-\ude86\ude88\ude8a-\ude8d\ude8f-\ude9d\ude9f-\udea8\udeb0-\udee8\udf00-\udf03\udf05-\udf0c\udf0f\udf10\udf13-\udf28\udf2a-\udf30\udf32\udf33\udf35-\udf39\udf3d-\udf44\udf47\udf48\udf4b\udf4c\udf50\udf57\udf5d-\udf63]|\ud805[\udc00-\udc41\udc43-\udc45\udc47-\udc4a\udc5f-\udc61\udc80-\udcc1\udcc4\udcc5\udcc7\udd80-\uddb5\uddb8-\uddbe\uddd8-\udddd\ude00-\ude3e\ude40\ude44\ude80-\udeb5\udeb8\udf00-\udf1a\udf1d-\udf2a\udf40-\udf46]|\ud806[\udc00-\udc38\udca0-\udcdf\udcff-\udd06\udd09\udd0c-\udd13\udd15\udd16\udd18-\udd35\udd37\udd38\udd3b\udd3c\udd3f-\udd42\udda0-\udda7\uddaa-\uddd7\uddda-\udddf\udde1\udde3\udde4\ude00-\ude32\ude35-\ude3e\ude50-\ude97\ude9d\udeb0-\udef8]|\ud807[\udc00-\udc08\udc0a-\udc36\udc38-\udc3e\udc40\udc72-\udc8f\udc92-\udca7\udca9-\udcb6\udd00-\udd06\udd08\udd09\udd0b-\udd36\udd3a\udd3c\udd3d\udd3f-\udd41\udd43\udd46\udd47\udd60-\udd65\udd67\udd68\udd6a-\udd8e\udd90\udd91\udd93-\udd96\udd98\udee0-\udef6\udfb0]|\ud808[\udc00-\udf99]|\ud809[\udc00-\udc6e\udc80-\udd43]|\ud80b[\udf90-\udff0]|[\ud80c\ud81c-\ud820\ud822\ud840-\ud868\ud86a-\ud86c\ud86f-\ud872\ud874-\ud879\ud880-\ud883][\udc00-\udfff]|\ud80d[\udc00-\udc2e]|\ud811[\udc00-\ude46]|\ud81a[\udc00-\ude38\ude40-\ude5e\ude70-\udebe\uded0-\udeed\udf00-\udf2f\udf40-\udf43\udf63-\udf77\udf7d-\udf8f]|\ud81b[\ude40-\ude7f\udf00-\udf4a\udf4f-\udf87\udf8f-\udf9f\udfe0\udfe1\udfe3\udff0\udff1]|\ud821[\udc00-\udff7]|\ud823[\udc00-\udcd5\udd00-\udd08]|\ud82b[\udff0-\udff3\udff5-\udffb\udffd\udffe]|\ud82c[\udc00-\udd22\udd50-\udd52\udd64-\udd67\udd70-\udefb]|\ud82f[\udc00-\udc6a\udc70-\udc7c\udc80-\udc88\udc90-\udc99\udc9e]|\ud835[\udc00-\udc54\udc56-\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd1e-\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd52-\udea5\udea8-\udec0\udec2-\udeda\udedc-\udefa\udefc-\udf14\udf16-\udf34\udf36-\udf4e\udf50-\udf6e\udf70-\udf88\udf8a-\udfa8\udfaa-\udfc2\udfc4-\udfcb]|\ud837[\udf00-\udf1e]|\ud838[\udc00-\udc06\udc08-\udc18\udc1b-\udc21\udc23\udc24\udc26-\udc2a\udd00-\udd2c\udd37-\udd3d\udd4e\ude90-\udead\udec0-\udeeb]|\ud839[\udfe0-\udfe6\udfe8-\udfeb\udfed\udfee\udff0-\udffe]|\ud83a[\udc00-\udcc4\udd00-\udd43\udd47\udd4b]|\ud83b[\ude00-\ude03\ude05-\ude1f\ude21\ude22\ude24\ude27\ude29-\ude32\ude34-\ude37\ude39\ude3b\ude42\ude47\ude49\ude4b\ude4d-\ude4f\ude51\ude52\ude54\ude57\ude59\ude5b\ude5d\ude5f\ude61\ude62\ude64\ude67-\ude6a\ude6c-\ude72\ude74-\ude77\ude79-\ude7c\ude7e\ude80-\ude89\ude8b-\ude9b\udea1-\udea3\udea5-\udea9\udeab-\udebb]|\ud83c[\udd30-\udd49\udd50-\udd69\udd70-\udd89]|\ud869[\udc00-\udedf\udf00-\udfff]|\ud86d[\udc00-\udf38\udf40-\udfff]|\ud86e[\udc00-\udc1d\udc20-\udfff]|\ud873[\udc00-\udea1\udeb0-\udfff]|\ud87a[\udc00-\udfe0]|\ud87e[\udc00-\ude1d]|\ud884[\udc00-\udf4a]"},{name:"Any",isBmpLast:!0,bmp:"\0-￿",astral:"[\ud800-\udbff][\udc00-\udfff]"},{name:"Default_Ignorable_Code_Point",bmp:"­͏؜ᅟᅠ឴឵᠋-᠏​-‏‪-‮⁠-ㅤ︀-️\ufeffᅠ￰-￸",astral:"\ud82f[\udca0-\udca3]|\ud834[\udd73-\udd7a]|[\udb40-\udb43][\udc00-\udfff]"},{name:"Lowercase",bmp:"a-zªµºß-öø-ÿāăąćĉċčďđēĕėęěĝğġģĥħĩīĭįıijĵķĸĺļľŀłńņňʼnŋōŏőœŕŗřśŝşšţťŧũūŭůűųŵŷźżž-ƀƃƅƈƌƍƒƕƙ-ƛƞơƣƥƨƪƫƭưƴƶƹƺƽ-ƿdžljnjǎǐǒǔǖǘǚǜǝǟǡǣǥǧǩǫǭǯǰdzǵǹǻǽǿȁȃȅȇȉȋȍȏȑȓȕȗșțȝȟȡȣȥȧȩȫȭȯȱȳ-ȹȼȿɀɂɇɉɋɍɏ-ʓʕ-ʸˀˁˠ-ˤͅͱͳͷͺ-ͽΐά-ώϐϑϕ-ϗϙϛϝϟϡϣϥϧϩϫϭϯ-ϳϵϸϻϼа-џѡѣѥѧѩѫѭѯѱѳѵѷѹѻѽѿҁҋҍҏґғҕҗҙқҝҟҡңҥҧҩҫҭүұҳҵҷҹһҽҿӂӄӆӈӊӌӎӏӑӓӕӗәӛӝӟӡӣӥӧөӫӭӯӱӳӵӷӹӻӽӿԁԃԅԇԉԋԍԏԑԓԕԗԙԛԝԟԡԣԥԧԩԫԭԯՠ-ֈა-ჺჽ-ჿᏸ-ᏽᲀ-ᲈᴀ-ᶿḁḃḅḇḉḋḍḏḑḓḕḗḙḛḝḟḡḣḥḧḩḫḭḯḱḳḵḷḹḻḽḿṁṃṅṇṉṋṍṏṑṓṕṗṙṛṝṟṡṣṥṧṩṫṭṯṱṳṵṷṹṻṽṿẁẃẅẇẉẋẍẏẑẓẕ-ẝẟạảấầẩẫậắằẳẵặẹẻẽếềểễệỉịọỏốồổỗộớờởỡợụủứừửữựỳỵỷỹỻỽỿ-ἇἐ-ἕἠ-ἧἰ-ἷὀ-ὅὐ-ὗὠ-ὧὰ-ώᾀ-ᾇᾐ-ᾗᾠ-ᾧᾰ-ᾴᾶᾷιῂ-ῄῆῇῐ-ΐῖῗῠ-ῧῲ-ῴῶῷⁱⁿₐ-ₜℊℎℏℓℯℴℹℼℽⅆ-ⅉⅎⅰ-ⅿↄⓐ-ⓩⰰ-ⱟⱡⱥⱦⱨⱪⱬⱱⱳⱴⱶ-ⱽⲁⲃⲅⲇⲉⲋⲍⲏⲑⲓⲕⲗⲙⲛⲝⲟⲡⲣⲥⲧⲩⲫⲭⲯⲱⲳⲵⲷⲹⲻⲽⲿⳁⳃⳅⳇⳉⳋⳍⳏⳑⳓⳕⳗⳙⳛⳝⳟⳡⳣⳤⳬⳮⳳⴀ-ⴥⴧⴭꙁꙃꙅꙇꙉꙋꙍꙏꙑꙓꙕꙗꙙꙛꙝꙟꙡꙣꙥꙧꙩꙫꙭꚁꚃꚅꚇꚉꚋꚍꚏꚑꚓꚕꚗꚙꚛ-ꚝꜣꜥꜧꜩꜫꜭꜯ-ꜱꜳꜵꜷꜹꜻꜽꜿꝁꝃꝅꝇꝉꝋꝍꝏꝑꝓꝕꝗꝙꝛꝝꝟꝡꝣꝥꝧꝩꝫꝭꝯ-ꝸꝺꝼꝿꞁꞃꞅꞇꞌꞎꞑꞓ-ꞕꞗꞙꞛꞝꞟꞡꞣꞥꞧꞩꞯꞵꞷꞹꞻꞽꞿꟁꟃꟈꟊꟑꟓꟕꟗꟙꟶꟸ-ꟺꬰ-ꭚꭜ-ꭨꭰ-ꮿff-stﬓ-ﬗa-z",astral:"\ud801[\udc28-\udc4f\udcd8-\udcfb\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc\udf80\udf83-\udf85\udf87-\udfb0\udfb2-\udfba]|\ud803[\udcc0-\udcf2]|\ud806[\udcc0-\udcdf]|\ud81b[\ude60-\ude7f]|\ud835[\udc1a-\udc33\udc4e-\udc54\udc56-\udc67\udc82-\udc9b\udcb6-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udccf\udcea-\udd03\udd1e-\udd37\udd52-\udd6b\udd86-\udd9f\uddba-\uddd3\uddee-\ude07\ude22-\ude3b\ude56-\ude6f\ude8a-\udea5\udec2-\udeda\udedc-\udee1\udefc-\udf14\udf16-\udf1b\udf36-\udf4e\udf50-\udf55\udf70-\udf88\udf8a-\udf8f\udfaa-\udfc2\udfc4-\udfc9\udfcb]|\ud837[\udf00-\udf09\udf0b-\udf1e]|\ud83a[\udd22-\udd43]"},{name:"Noncharacter_Code_Point",bmp:"﷐-﷯￾￿",astral:"[\ud83f\ud87f\ud8bf\ud8ff\ud93f\ud97f\ud9bf\ud9ff\uda3f\uda7f\udabf\udaff\udb3f\udb7f\udbbf\udbff][\udffe\udfff]"},{name:"Uppercase",bmp:"A-ZÀ-ÖØ-ÞĀĂĄĆĈĊČĎĐĒĔĖĘĚĜĞĠĢĤĦĨĪĬĮİIJĴĶĹĻĽĿŁŃŅŇŊŌŎŐŒŔŖŘŚŜŞŠŢŤŦŨŪŬŮŰŲŴŶŸŹŻŽƁƂƄƆƇƉ-ƋƎ-ƑƓƔƖ-ƘƜƝƟƠƢƤƦƧƩƬƮƯƱ-ƳƵƷƸƼDŽLJNJǍǏǑǓǕǗǙǛǞǠǢǤǦǨǪǬǮDZǴǶ-ǸǺǼǾȀȂȄȆȈȊȌȎȐȒȔȖȘȚȜȞȠȢȤȦȨȪȬȮȰȲȺȻȽȾɁɃ-ɆɈɊɌɎͰͲͶͿΆΈ-ΊΌΎΏΑ-ΡΣ-ΫϏϒ-ϔϘϚϜϞϠϢϤϦϨϪϬϮϴϷϹϺϽ-ЯѠѢѤѦѨѪѬѮѰѲѴѶѸѺѼѾҀҊҌҎҐҒҔҖҘҚҜҞҠҢҤҦҨҪҬҮҰҲҴҶҸҺҼҾӀӁӃӅӇӉӋӍӐӒӔӖӘӚӜӞӠӢӤӦӨӪӬӮӰӲӴӶӸӺӼӾԀԂԄԆԈԊԌԎԐԒԔԖԘԚԜԞԠԢԤԦԨԪԬԮԱ-ՖႠ-ჅჇჍᎠ-ᏵᲐ-ᲺᲽ-ᲿḀḂḄḆḈḊḌḎḐḒḔḖḘḚḜḞḠḢḤḦḨḪḬḮḰḲḴḶḸḺḼḾṀṂṄṆṈṊṌṎṐṒṔṖṘṚṜṞṠṢṤṦṨṪṬṮṰṲṴṶṸṺṼṾẀẂẄẆẈẊẌẎẐẒẔẞẠẢẤẦẨẪẬẮẰẲẴẶẸẺẼẾỀỂỄỆỈỊỌỎỐỒỔỖỘỚỜỞỠỢỤỦỨỪỬỮỰỲỴỶỸỺỼỾἈ-ἏἘ-ἝἨ-ἯἸ-ἿὈ-ὍὙὛὝὟὨ-ὯᾸ-ΆῈ-ΉῘ-ΊῨ-ῬῸ-Ώℂℇℋ-ℍℐ-ℒℕℙ-ℝℤΩℨK-ℭℰ-ℳℾℿⅅⅠ-ⅯↃⒶ-ⓏⰀ-ⰯⱠⱢ-ⱤⱧⱩⱫⱭ-ⱰⱲⱵⱾ-ⲀⲂⲄⲆⲈⲊⲌⲎⲐⲒⲔⲖⲘⲚⲜⲞⲠⲢⲤⲦⲨⲪⲬⲮⲰⲲⲴⲶⲸⲺⲼⲾⳀⳂⳄⳆⳈⳊⳌⳎⳐⳒⳔⳖⳘⳚⳜⳞⳠⳢⳫⳭⳲꙀꙂꙄꙆꙈꙊꙌꙎꙐꙒꙔꙖꙘꙚꙜꙞꙠꙢꙤꙦꙨꙪꙬꚀꚂꚄꚆꚈꚊꚌꚎꚐꚒꚔꚖꚘꚚꜢꜤꜦꜨꜪꜬꜮꜲꜴꜶꜸꜺꜼꜾꝀꝂꝄꝆꝈꝊꝌꝎꝐꝒꝔꝖꝘꝚꝜꝞꝠꝢꝤꝦꝨꝪꝬꝮꝹꝻꝽꝾꞀꞂꞄꞆꞋꞍꞐꞒꞖꞘꞚꞜꞞꞠꞢꞤꞦꞨꞪ-ꞮꞰ-ꞴꞶꞸꞺꞼꞾꟀꟂꟄ-ꟇꟉꟐꟖꟘꟵA-Z",astral:"\ud801[\udc00-\udc27\udcb0-\udcd3\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95]|\ud803[\udc80-\udcb2]|\ud806[\udca0-\udcbf]|\ud81b[\ude40-\ude5f]|\ud835[\udc00-\udc19\udc34-\udc4d\udc68-\udc81\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb5\udcd0-\udce9\udd04\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd38\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd6c-\udd85\udda0-\uddb9\uddd4-\udded\ude08-\ude21\ude3c-\ude55\ude70-\ude89\udea8-\udec0\udee2-\udefa\udf1c-\udf34\udf56-\udf6e\udf90-\udfa8\udfca]|\ud83a[\udd00-\udd21]|\ud83c[\udd30-\udd49\udd50-\udd69\udd70-\udd89]"},{name:"White_Space",bmp:"\t-\r …   - \u2028\u2029   "}]},5142:e=>{e.exports=[{name:"Adlam",astral:"\ud83a[\udd00-\udd4b\udd50-\udd59\udd5e\udd5f]"},{name:"Ahom",astral:"\ud805[\udf00-\udf1a\udf1d-\udf2b\udf30-\udf46]"},{name:"Anatolian_Hieroglyphs",astral:"\ud811[\udc00-\ude46]"},{name:"Arabic",bmp:"؀-؄؆-؋؍-ؚ؜-؞ؠ-ؿف-يٖ-ٯٱ-ۜ۞-ۿݐ-ݿࡰ-ࢎ࢐࢑࢘-ࣣ࣡-ࣿﭐ-﯂ﯓ-ﴽ﵀-ﶏﶒ-ﷇ﷏ﷰ-﷿ﹰ-ﹴﹶ-ﻼ",astral:"\ud803[\ude60-\ude7e]|\ud83b[\ude00-\ude03\ude05-\ude1f\ude21\ude22\ude24\ude27\ude29-\ude32\ude34-\ude37\ude39\ude3b\ude42\ude47\ude49\ude4b\ude4d-\ude4f\ude51\ude52\ude54\ude57\ude59\ude5b\ude5d\ude5f\ude61\ude62\ude64\ude67-\ude6a\ude6c-\ude72\ude74-\ude77\ude79-\ude7c\ude7e\ude80-\ude89\ude8b-\ude9b\udea1-\udea3\udea5-\udea9\udeab-\udebb\udef0\udef1]"},{name:"Armenian",bmp:"Ա-Ֆՙ-֊֍-֏ﬓ-ﬗ"},{name:"Avestan",astral:"\ud802[\udf00-\udf35\udf39-\udf3f]"},{name:"Balinese",bmp:"ᬀ-ᭌ᭐-᭾"},{name:"Bamum",bmp:"ꚠ-꛷",astral:"\ud81a[\udc00-\ude38]"},{name:"Bassa_Vah",astral:"\ud81a[\uded0-\udeed\udef0-\udef5]"},{name:"Batak",bmp:"ᯀ-᯳᯼-᯿"},{name:"Bengali",bmp:"ঀ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-৾"},{name:"Bhaiksuki",astral:"\ud807[\udc00-\udc08\udc0a-\udc36\udc38-\udc45\udc50-\udc6c]"},{name:"Bopomofo",bmp:"˪˫ㄅ-ㄯㆠ-ㆿ"},{name:"Brahmi",astral:"\ud804[\udc00-\udc4d\udc52-\udc75\udc7f]"},{name:"Braille",bmp:"⠀-⣿"},{name:"Buginese",bmp:"ᨀ-ᨛ᨞᨟"},{name:"Buhid",bmp:"ᝀ-ᝓ"},{name:"Canadian_Aboriginal",bmp:"᐀-ᙿᢰ-ᣵ",astral:"\ud806[\udeb0-\udebf]"},{name:"Carian",astral:"\ud800[\udea0-\uded0]"},{name:"Caucasian_Albanian",astral:"\ud801[\udd30-\udd63\udd6f]"},{name:"Chakma",astral:"\ud804[\udd00-\udd34\udd36-\udd47]"},{name:"Cham",bmp:"ꨀ-ꨶꩀ-ꩍ꩐-꩙꩜-꩟"},{name:"Cherokee",bmp:"Ꭰ-Ᏽᏸ-ᏽꭰ-ꮿ"},{name:"Chorasmian",astral:"\ud803[\udfb0-\udfcb]"},{name:"Common",bmp:"\0-@\\[-`\\{-©«-¹»-¿×÷ʹ-˟˥-˩ˬ-˿ʹ;΅·؅،؛؟ـ۝࣢।॥฿࿕-࿘჻᛫-᛭᜵᜶᠂᠃᠅᳓᳡ᳩ-ᳬᳮ-ᳳᳵ-᳷ᳺ -​‎-⁤⁦-⁰⁴-⁾₀-₎₠-⃀℀-℥℧-℩ℬ-ℱℳ-⅍⅏-⅟↉-↋←-␦⑀-⑊①-⟿⤀-⭳⭶-⮕⮗-⯿⸀-⹝⿰-⿻ -〄〆〈-〠〰-〷〼-〿゛゜゠・ー㆐-㆟㇀-㇣㈠-㉟㉿-㋏㋿㍘-㏿䷀-䷿꜀-꜡ꞈ-꞊꠰-꠹꤮ꧏ꭛꭪꭫﴾﴿︐-︙︰-﹒﹔-﹦﹨-﹫\ufeff!-@[-`{-・ー゙゚¢-₩│-○-�",astral:"\ud800[\udd00-\udd02\udd07-\udd33\udd37-\udd3f\udd90-\udd9c\uddd0-\uddfc\udee1-\udefb]|\ud82f[\udca0-\udca3]|\ud833[\udf50-\udfc3]|\ud834[\udc00-\udcf5\udd00-\udd26\udd29-\udd66\udd6a-\udd7a\udd83\udd84\udd8c-\udda9\uddae-\uddea\udee0-\udef3\udf00-\udf56\udf60-\udf78]|\ud835[\udc00-\udc54\udc56-\udc9c\udc9e\udc9f\udca2\udca5\udca6\udca9-\udcac\udcae-\udcb9\udcbb\udcbd-\udcc3\udcc5-\udd05\udd07-\udd0a\udd0d-\udd14\udd16-\udd1c\udd1e-\udd39\udd3b-\udd3e\udd40-\udd44\udd46\udd4a-\udd50\udd52-\udea5\udea8-\udfcb\udfce-\udfff]|\ud83b[\udc71-\udcb4\udd01-\udd3d]|\ud83c[\udc00-\udc2b\udc30-\udc93\udca0-\udcae\udcb1-\udcbf\udcc1-\udccf\udcd1-\udcf5\udd00-\uddad\udde6-\uddff\ude01\ude02\ude10-\ude3b\ude40-\ude48\ude50\ude51\ude60-\ude65\udf00-\udfff]|\ud83d[\udc00-\uded7\udedd-\udeec\udef0-\udefc\udf00-\udf73\udf80-\udfd8\udfe0-\udfeb\udff0]|\ud83e[\udc00-\udc0b\udc10-\udc47\udc50-\udc59\udc60-\udc87\udc90-\udcad\udcb0\udcb1\udd00-\ude53\ude60-\ude6d\ude70-\ude74\ude78-\ude7c\ude80-\ude86\ude90-\udeac\udeb0-\udeba\udec0-\udec5\uded0-\uded9\udee0-\udee7\udef0-\udef6\udf00-\udf92\udf94-\udfca\udff0-\udff9]|\udb40[\udc01\udc20-\udc7f]"},{name:"Coptic",bmp:"Ϣ-ϯⲀ-ⳳ⳹-⳿"},{name:"Cuneiform",astral:"\ud808[\udc00-\udf99]|\ud809[\udc00-\udc6e\udc70-\udc74\udc80-\udd43]"},{name:"Cypriot",astral:"\ud802[\udc00-\udc05\udc08\udc0a-\udc35\udc37\udc38\udc3c\udc3f]"},{name:"Cypro_Minoan",astral:"\ud80b[\udf90-\udff2]"},{name:"Cyrillic",bmp:"Ѐ-҄҇-ԯᲀ-ᲈᴫᵸⷠ-ⷿꙀ-ꚟ︮︯"},{name:"Deseret",astral:"\ud801[\udc00-\udc4f]"},{name:"Devanagari",bmp:"ऀ-ॐॕ-ॣ०-ॿ꣠-ꣿ"},{name:"Dives_Akuru",astral:"\ud806[\udd00-\udd06\udd09\udd0c-\udd13\udd15\udd16\udd18-\udd35\udd37\udd38\udd3b-\udd46\udd50-\udd59]"},{name:"Dogra",astral:"\ud806[\udc00-\udc3b]"},{name:"Duployan",astral:"\ud82f[\udc00-\udc6a\udc70-\udc7c\udc80-\udc88\udc90-\udc99\udc9c-\udc9f]"},{name:"Egyptian_Hieroglyphs",astral:"\ud80c[\udc00-\udfff]|\ud80d[\udc00-\udc2e\udc30-\udc38]"},{name:"Elbasan",astral:"\ud801[\udd00-\udd27]"},{name:"Elymaic",astral:"\ud803[\udfe0-\udff6]"},{name:"Ethiopic",bmp:"ሀ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፼ᎀ-᎙ⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮ",astral:"\ud839[\udfe0-\udfe6\udfe8-\udfeb\udfed\udfee\udff0-\udffe]"},{name:"Georgian",bmp:"Ⴀ-ჅჇჍა-ჺჼ-ჿᲐ-ᲺᲽ-Ჿⴀ-ⴥⴧⴭ"},{name:"Glagolitic",bmp:"Ⰰ-ⱟ",astral:"\ud838[\udc00-\udc06\udc08-\udc18\udc1b-\udc21\udc23\udc24\udc26-\udc2a]"},{name:"Gothic",astral:"\ud800[\udf30-\udf4a]"},{name:"Grantha",astral:"\ud804[\udf00-\udf03\udf05-\udf0c\udf0f\udf10\udf13-\udf28\udf2a-\udf30\udf32\udf33\udf35-\udf39\udf3c-\udf44\udf47\udf48\udf4b-\udf4d\udf50\udf57\udf5d-\udf63\udf66-\udf6c\udf70-\udf74]"},{name:"Greek",bmp:"Ͱ-ͳ͵-ͷͺ-ͽͿ΄ΆΈ-ΊΌΎ-ΡΣ-ϡϰ-Ͽᴦ-ᴪᵝ-ᵡᵦ-ᵪᶿἀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ῄῆ-ΐῖ-Ί῝-`ῲ-ῴῶ-῾Ωꭥ",astral:"\ud800[\udd40-\udd8e\udda0]|\ud834[\ude00-\ude45]"},{name:"Gujarati",bmp:"ઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૱ૹ-૿"},{name:"Gunjala_Gondi",astral:"\ud807[\udd60-\udd65\udd67\udd68\udd6a-\udd8e\udd90\udd91\udd93-\udd98\udda0-\udda9]"},{name:"Gurmukhi",bmp:"ਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-੶"},{name:"Han",bmp:"⺀-⺙⺛-⻳⼀-⿕々〇〡-〩〸-〻㐀-䶿一-鿿豈-舘並-龎",astral:"\ud81b[\udfe2\udfe3\udff0\udff1]|[\ud840-\ud868\ud86a-\ud86c\ud86f-\ud872\ud874-\ud879\ud880-\ud883][\udc00-\udfff]|\ud869[\udc00-\udedf\udf00-\udfff]|\ud86d[\udc00-\udf38\udf40-\udfff]|\ud86e[\udc00-\udc1d\udc20-\udfff]|\ud873[\udc00-\udea1\udeb0-\udfff]|\ud87a[\udc00-\udfe0]|\ud87e[\udc00-\ude1d]|\ud884[\udc00-\udf4a]"},{name:"Hangul",bmp:"ᄀ-ᇿ〮〯ㄱ-ㆎ㈀-㈞㉠-㉾ꥠ-ꥼ가-힣ힰ-ퟆퟋ-ퟻᅠ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ"},{name:"Hanifi_Rohingya",astral:"\ud803[\udd00-\udd27\udd30-\udd39]"},{name:"Hanunoo",bmp:"ᜠ-᜴"},{name:"Hatran",astral:"\ud802[\udce0-\udcf2\udcf4\udcf5\udcfb-\udcff]"},{name:"Hebrew",bmp:"֑-ׇא-תׯ-״יִ-זּטּ-לּמּנּסּףּפּצּ-ﭏ"},{name:"Hiragana",bmp:"ぁ-ゖゝ-ゟ",astral:"\ud82c[\udc01-\udd1f\udd50-\udd52]|🈀"},{name:"Imperial_Aramaic",astral:"\ud802[\udc40-\udc55\udc57-\udc5f]"},{name:"Inherited",bmp:"̀-ًͯ҅҆-ٰٕ॑-॔᪰-ᫎ᳐-᳔᳒-᳢᳠-᳨᳭᳴᳸᳹᷀-᷿‌‍⃐-〪⃰-゙゚〭︀-️︠-︭",astral:"\ud800[\uddfd\udee0]|𑌻|\ud833[\udf00-\udf2d\udf30-\udf46]|\ud834[\udd67-\udd69\udd7b-\udd82\udd85-\udd8b\uddaa-\uddad]|\udb40[\udd00-\uddef]"},{name:"Inscriptional_Pahlavi",astral:"\ud802[\udf60-\udf72\udf78-\udf7f]"},{name:"Inscriptional_Parthian",astral:"\ud802[\udf40-\udf55\udf58-\udf5f]"},{name:"Javanese",bmp:"ꦀ-꧍꧐-꧙꧞꧟"},{name:"Kaithi",astral:"\ud804[\udc80-\udcc2\udccd]"},{name:"Kannada",bmp:"ಀ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೝೞೠ-ೣ೦-೯ೱೲ"},{name:"Katakana",bmp:"ァ-ヺヽ-ヿㇰ-ㇿ㋐-㋾㌀-㍗ヲ-ッア-ン",astral:"\ud82b[\udff0-\udff3\udff5-\udffb\udffd\udffe]|\ud82c[\udc00\udd20-\udd22\udd64-\udd67]"},{name:"Kayah_Li",bmp:"꤀-꤭꤯"},{name:"Kharoshthi",astral:"\ud802[\ude00-\ude03\ude05\ude06\ude0c-\ude13\ude15-\ude17\ude19-\ude35\ude38-\ude3a\ude3f-\ude48\ude50-\ude58]"},{name:"Khitan_Small_Script",astral:"𖿤|\ud822[\udf00-\udfff]|\ud823[\udc00-\udcd5]"},{name:"Khmer",bmp:"ក-៝០-៩៰-៹᧠-᧿"},{name:"Khojki",astral:"\ud804[\ude00-\ude11\ude13-\ude3e]"},{name:"Khudawadi",astral:"\ud804[\udeb0-\udeea\udef0-\udef9]"},{name:"Lao",bmp:"ກຂຄຆ-ຊຌ-ຣລວ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟ"},{name:"Latin",bmp:"A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꟊꟐꟑꟓꟕ-ꟙꟲ-ꟿꬰ-ꭚꭜ-ꭤꭦ-ꭩff-stA-Za-z",astral:"\ud801[\udf80-\udf85\udf87-\udfb0\udfb2-\udfba]|\ud837[\udf00-\udf1e]"},{name:"Lepcha",bmp:"ᰀ-᰷᰻-᱉ᱍ-ᱏ"},{name:"Limbu",bmp:"ᤀ-ᤞᤠ-ᤫᤰ-᤻᥀᥄-᥏"},{name:"Linear_A",astral:"\ud801[\ude00-\udf36\udf40-\udf55\udf60-\udf67]"},{name:"Linear_B",astral:"\ud800[\udc00-\udc0b\udc0d-\udc26\udc28-\udc3a\udc3c\udc3d\udc3f-\udc4d\udc50-\udc5d\udc80-\udcfa]"},{name:"Lisu",bmp:"ꓐ-꓿",astral:"𑾰"},{name:"Lycian",astral:"\ud800[\ude80-\ude9c]"},{name:"Lydian",astral:"\ud802[\udd20-\udd39\udd3f]"},{name:"Mahajani",astral:"\ud804[\udd50-\udd76]"},{name:"Makasar",astral:"\ud807[\udee0-\udef8]"},{name:"Malayalam",bmp:"ഀ-ഌഎ-ഐഒ-ൄെ-ൈൊ-൏ൔ-ൣ൦-ൿ"},{name:"Mandaic",bmp:"ࡀ-࡛࡞"},{name:"Manichaean",astral:"\ud802[\udec0-\udee6\udeeb-\udef6]"},{name:"Marchen",astral:"\ud807[\udc70-\udc8f\udc92-\udca7\udca9-\udcb6]"},{name:"Masaram_Gondi",astral:"\ud807[\udd00-\udd06\udd08\udd09\udd0b-\udd36\udd3a\udd3c\udd3d\udd3f-\udd47\udd50-\udd59]"},{name:"Medefaidrin",astral:"\ud81b[\ude40-\ude9a]"},{name:"Meetei_Mayek",bmp:"ꫠ-꫶ꯀ-꯭꯰-꯹"},{name:"Mende_Kikakui",astral:"\ud83a[\udc00-\udcc4\udcc7-\udcd6]"},{name:"Meroitic_Cursive",astral:"\ud802[\udda0-\uddb7\uddbc-\uddcf\uddd2-\uddff]"},{name:"Meroitic_Hieroglyphs",astral:"\ud802[\udd80-\udd9f]"},{name:"Miao",astral:"\ud81b[\udf00-\udf4a\udf4f-\udf87\udf8f-\udf9f]"},{name:"Modi",astral:"\ud805[\ude00-\ude44\ude50-\ude59]"},{name:"Mongolian",bmp:"᠀᠁᠄᠆-᠙ᠠ-ᡸᢀ-ᢪ",astral:"\ud805[\ude60-\ude6c]"},{name:"Mro",astral:"\ud81a[\ude40-\ude5e\ude60-\ude69\ude6e\ude6f]"},{name:"Multani",astral:"\ud804[\ude80-\ude86\ude88\ude8a-\ude8d\ude8f-\ude9d\ude9f-\udea9]"},{name:"Myanmar",bmp:"က-႟ꧠ-ꧾꩠ-ꩿ"},{name:"Nabataean",astral:"\ud802[\udc80-\udc9e\udca7-\udcaf]"},{name:"Nandinagari",astral:"\ud806[\udda0-\udda7\uddaa-\uddd7\uddda-\udde4]"},{name:"New_Tai_Lue",bmp:"ᦀ-ᦫᦰ-ᧉ᧐-᧚᧞᧟"},{name:"Newa",astral:"\ud805[\udc00-\udc5b\udc5d-\udc61]"},{name:"Nko",bmp:"߀-ߺ߽-߿"},{name:"Nushu",astral:"𖿡|\ud82c[\udd70-\udefb]"},{name:"Nyiakeng_Puachue_Hmong",astral:"\ud838[\udd00-\udd2c\udd30-\udd3d\udd40-\udd49\udd4e\udd4f]"},{name:"Ogham",bmp:" -᚜"},{name:"Ol_Chiki",bmp:"᱐-᱿"},{name:"Old_Hungarian",astral:"\ud803[\udc80-\udcb2\udcc0-\udcf2\udcfa-\udcff]"},{name:"Old_Italic",astral:"\ud800[\udf00-\udf23\udf2d-\udf2f]"},{name:"Old_North_Arabian",astral:"\ud802[\ude80-\ude9f]"},{name:"Old_Permic",astral:"\ud800[\udf50-\udf7a]"},{name:"Old_Persian",astral:"\ud800[\udfa0-\udfc3\udfc8-\udfd5]"},{name:"Old_Sogdian",astral:"\ud803[\udf00-\udf27]"},{name:"Old_South_Arabian",astral:"\ud802[\ude60-\ude7f]"},{name:"Old_Turkic",astral:"\ud803[\udc00-\udc48]"},{name:"Old_Uyghur",astral:"\ud803[\udf70-\udf89]"},{name:"Oriya",bmp:"ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍୕-ୗଡ଼ଢ଼ୟ-ୣ୦-୷"},{name:"Osage",astral:"\ud801[\udcb0-\udcd3\udcd8-\udcfb]"},{name:"Osmanya",astral:"\ud801[\udc80-\udc9d\udca0-\udca9]"},{name:"Pahawh_Hmong",astral:"\ud81a[\udf00-\udf45\udf50-\udf59\udf5b-\udf61\udf63-\udf77\udf7d-\udf8f]"},{name:"Palmyrene",astral:"\ud802[\udc60-\udc7f]"},{name:"Pau_Cin_Hau",astral:"\ud806[\udec0-\udef8]"},{name:"Phags_Pa",bmp:"ꡀ-꡷"},{name:"Phoenician",astral:"\ud802[\udd00-\udd1b\udd1f]"},{name:"Psalter_Pahlavi",astral:"\ud802[\udf80-\udf91\udf99-\udf9c\udfa9-\udfaf]"},{name:"Rejang",bmp:"ꤰ-꥓꥟"},{name:"Runic",bmp:"ᚠ-ᛪᛮ-ᛸ"},{name:"Samaritan",bmp:"ࠀ-࠭࠰-࠾"},{name:"Saurashtra",bmp:"ꢀ-ꣅ꣎-꣙"},{name:"Sharada",astral:"\ud804[\udd80-\udddf]"},{name:"Shavian",astral:"\ud801[\udc50-\udc7f]"},{name:"Siddham",astral:"\ud805[\udd80-\uddb5\uddb8-\udddd]"},{name:"SignWriting",astral:"\ud836[\udc00-\ude8b\ude9b-\ude9f\udea1-\udeaf]"},{name:"Sinhala",bmp:"ඁ-ඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟ෦-෯ෲ-෴",astral:"\ud804[\udde1-\uddf4]"},{name:"Sogdian",astral:"\ud803[\udf30-\udf59]"},{name:"Sora_Sompeng",astral:"\ud804[\udcd0-\udce8\udcf0-\udcf9]"},{name:"Soyombo",astral:"\ud806[\ude50-\udea2]"},{name:"Sundanese",bmp:"ᮀ-ᮿ᳀-᳇"},{name:"Syloti_Nagri",bmp:"ꠀ-꠬"},{name:"Syriac",bmp:"܀-܍܏-݊ݍ-ݏࡠ-ࡪ"},{name:"Tagalog",bmp:"ᜀ-᜕ᜟ"},{name:"Tagbanwa",bmp:"ᝠ-ᝬᝮ-ᝰᝲᝳ"},{name:"Tai_Le",bmp:"ᥐ-ᥭᥰ-ᥴ"},{name:"Tai_Tham",bmp:"ᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪠-᪭"},{name:"Tai_Viet",bmp:"ꪀ-ꫂꫛ-꫟"},{name:"Takri",astral:"\ud805[\ude80-\udeb9\udec0-\udec9]"},{name:"Tamil",bmp:"ஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௺",astral:"\ud807[\udfc0-\udff1\udfff]"},{name:"Tangsa",astral:"\ud81a[\ude70-\udebe\udec0-\udec9]"},{name:"Tangut",astral:"𖿠|[\ud81c-\ud820][\udc00-\udfff]|\ud821[\udc00-\udff7]|\ud822[\udc00-\udeff]|\ud823[\udd00-\udd08]"},{name:"Telugu",bmp:"ఀ-ఌఎ-ఐఒ-నప-హ఼-ౄె-ైొ-్ౕౖౘ-ౚౝౠ-ౣ౦-౯౷-౿"},{name:"Thaana",bmp:"ހ-ޱ"},{name:"Thai",bmp:"ก-ฺเ-๛"},{name:"Tibetan",bmp:"ༀ-ཇཉ-ཬཱ-ྗྙ-ྼ྾-࿌࿎-࿔࿙࿚"},{name:"Tifinagh",bmp:"ⴰ-ⵧⵯ⵰⵿"},{name:"Tirhuta",astral:"\ud805[\udc80-\udcc7\udcd0-\udcd9]"},{name:"Toto",astral:"\ud838[\ude90-\udeae]"},{name:"Ugaritic",astral:"\ud800[\udf80-\udf9d\udf9f]"},{name:"Vai",bmp:"ꔀ-ꘫ"},{name:"Vithkuqi",astral:"\ud801[\udd70-\udd7a\udd7c-\udd8a\udd8c-\udd92\udd94\udd95\udd97-\udda1\udda3-\uddb1\uddb3-\uddb9\uddbb\uddbc]"},{name:"Wancho",astral:"\ud838[\udec0-\udef9\udeff]"},{name:"Warang_Citi",astral:"\ud806[\udca0-\udcf2\udcff]"},{name:"Yezidi",astral:"\ud803[\ude80-\udea9\udeab-\udead\udeb0\udeb1]"},{name:"Yi",bmp:"ꀀ-ꒌ꒐-꓆"},{name:"Zanabazar_Square",astral:"\ud806[\ude00-\ude47]"}]},23313:()=>{},35265:()=>{},70440:()=>{},18950:()=>{},78982:()=>{},47790:()=>{},73776:()=>{},77965:()=>{},66089:()=>{},79368:()=>{},64688:()=>{},42634:()=>{},51069:()=>{},15340:()=>{},79838:()=>{},63779:()=>{},99580:()=>{},49763:(e,t,r)=>{e.exports=r(86450)},66615:(e,t,r)=>{e.exports=r(18402)},11393:(e,t,r)=>{e.exports=r(50530)},52730:(e,t,r)=>{e.exports=r(64055)},86226:(e,t,r)=>{e.exports=r(24525)},64007:(e,t,r)=>{e.exports=r(77852)},48079:(e,t,r)=>{e.exports=r(98894)},73363:(e,t,r)=>{e.exports=r(79528)},18979:(e,t,r)=>{e.exports=r(6686)},129:(e,t,r)=>{e.exports=r(81086)},27681:(e,t,r)=>{e.exports=r(93658)},53930:(e,t,r)=>{e.exports=r(68251)},36586:(e,t,r)=>{e.exports=r(91921)},16781:(e,t,r)=>{e.exports=r(24139)},62222:(e,t,r)=>{e.exports=r(81519)},31607:e=>{e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r{var i=r(22382);e.exports=function(e){if(i(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},5946:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},94172:(e,t,r)=>{var i=r(93071),n=r(81519),o=r(1958);e.exports=function(e,t){var r=null==e?null:void 0!==i&&n(e)||e["@@iterator"];if(null!=r){var s,a,l,d,c=[],u=!0,p=!1;try{if(l=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;u=!1}else for(;!(u=(s=l.call(r)).done)&&(o(c).call(c,s.value),c.length!==t);u=!0);}catch(e){p=!0,a=e}finally{try{if(!u&&null!=r.return&&(d=r.return(),Object(d)!==d))return}finally{if(p)throw a}}return c}},e.exports.__esModule=!0,e.exports.default=e.exports},85344:e=>{e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},34875:(e,t,r)=>{var i=r(31251),n=r(94172),o=r(90426),s=r(85344);e.exports=function(e,t){return i(e)||n(e,t)||o(e,t)||s()},e.exports.__esModule=!0,e.exports.default=e.exports},90426:(e,t,r)=>{var i=r(55186),n=r(62014),o=r(31607);e.exports=function(e,t){if(e){var r;if("string"==typeof e)return o(e,t);var s=i(r={}.toString.call(e)).call(r,8,-1);return"Object"===s&&e.constructor&&(s=e.constructor.name),"Map"===s||"Set"===s?n(e):"Arguments"===s||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s)?o(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},70079:e=>{e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r{e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},43693:(e,t,r)=>{var i=r(77736);e.exports=function(e,t,r){return(t=i(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},24994:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},6305:(e,t,r)=>{var i=r(73738).default;function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(n=function(e){return e?r:t})(e)}e.exports=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=i(e)&&"function"!=typeof e)return{default:e};var r=n(t);if(r&&r.has(e))return r.get(e);var o={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&{}.hasOwnProperty.call(e,a)){var l=s?Object.getOwnPropertyDescriptor(e,a):null;l&&(l.get||l.set)?Object.defineProperty(o,a,l):o[a]=e[a]}return o.default=e,r&&r.set(e,o),o},e.exports.__esModule=!0,e.exports.default=e.exports},81156:e=>{e.exports=function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var i,n,o,s,a=[],l=!0,d=!1;try{if(o=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(i=o.call(r)).done)&&(a.push(i.value),a.length!==t);l=!0);}catch(e){d=!0,n=e}finally{try{if(!l&&null!=r.return&&(s=r.return(),Object(s)!==s))return}finally{if(d)throw n}}return a}},e.exports.__esModule=!0,e.exports.default=e.exports},47752:e=>{e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},91847:(e,t,r)=>{var i=r(54893);e.exports=function(e,t){if(null==e)return{};var r,n,o=i(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(n=0;n{e.exports=function(e,t){if(null==e)return{};var r={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(t.includes(i))continue;r[i]=e[i]}return r},e.exports.__esModule=!0,e.exports.default=e.exports},85715:(e,t,r)=>{var i=r(92987),n=r(81156),o=r(17122),s=r(47752);e.exports=function(e,t){return i(e)||n(e,t)||o(e,t)||s()},e.exports.__esModule=!0,e.exports.default=e.exports},89045:(e,t,r)=>{var i=r(73738).default;e.exports=function(e,t){if("object"!=i(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},77736:(e,t,r)=>{var i=r(73738).default,n=r(89045);e.exports=function(e){var t=n(e,"string");return"symbol"==i(t)?t:t+""},e.exports.__esModule=!0,e.exports.default=e.exports},73738:e=>{function t(r){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},17122:(e,t,r)=>{var i=r(70079);e.exports=function(e,t){if(e){if("string"==typeof e)return i(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?i(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},39209:(e,t,r)=>{"use strict";var i=r(76578),n="undefined"==typeof globalThis?r.g:globalThis;e.exports=function(){for(var e=[],t=0;t{"use strict";var i=r(86450);e.exports=i},77725:(e,t,r)=>{"use strict";var i=r(18402);e.exports=i},68690:(e,t,r)=>{"use strict";var i=r(33067);e.exports=i},45779:(e,t,r)=>{"use strict";var i=r(33266);e.exports=i},6221:(e,t,r)=>{"use strict";var i=r(6686);e.exports=i},57264:(e,t,r)=>{"use strict";var i=r(24139);r(20768),r(8549),r(87152),r(11372),e.exports=i},93607:(e,t,r)=>{"use strict";r(7057),r(57277);var i=r(92046);e.exports=i.Array.from},13531:(e,t,r)=>{"use strict";r(92425);var i=r(92046);e.exports=i.Array.isArray},96275:(e,t,r)=>{"use strict";r(58545);var i=r(61747);e.exports=i("Array","concat")},22092:(e,t,r)=>{"use strict";r(95650);var i=r(61747);e.exports=i("Array","forEach")},83309:(e,t,r)=>{"use strict";r(66391);var i=r(61747);e.exports=i("Array","indexOf")},28253:(e,t,r)=>{"use strict";r(6687);var i=r(61747);e.exports=i("Array","map")},21127:(e,t,r)=>{"use strict";r(85745);var i=r(61747);e.exports=i("Array","push")},16693:(e,t,r)=>{"use strict";r(46339);var i=r(61747);e.exports=i("Array","reduce")},75265:(e,t,r)=>{"use strict";r(62099);var i=r(61747);e.exports=i("Array","slice")},11263:(e,t,r)=>{"use strict";r(26737);var i=r(61747);e.exports=i("Array","sort")},54712:(e,t,r)=>{"use strict";r(99363),r(7057);var i=r(73448);e.exports=i},45837:(e,t,r)=>{"use strict";var i=r(88280),n=r(96275),o=Array.prototype;e.exports=function(e){var t=e.concat;return e===o||i(o,e)&&t===o.concat?n:t}},60974:(e,t,r)=>{"use strict";var i=r(88280),n=r(48804),o=RegExp.prototype;e.exports=function(e){return e===o||i(o,e)?n(e):e.flags}},44507:(e,t,r)=>{"use strict";var i=r(88280),n=r(83309),o=Array.prototype;e.exports=function(e){var t=e.indexOf;return e===o||i(o,e)&&t===o.indexOf?n:t}},39299:(e,t,r)=>{"use strict";var i=r(88280),n=r(28253),o=Array.prototype;e.exports=function(e){var t=e.map;return e===o||i(o,e)&&t===o.map?n:t}},78685:(e,t,r)=>{"use strict";var i=r(88280),n=r(21127),o=Array.prototype;e.exports=function(e){var t=e.push;return e===o||i(o,e)&&t===o.push?n:t}},28823:(e,t,r)=>{"use strict";var i=r(88280),n=r(16693),o=Array.prototype;e.exports=function(e){var t=e.reduce;return e===o||i(o,e)&&t===o.reduce?n:t}},40303:(e,t,r)=>{"use strict";var i=r(88280),n=r(75265),o=Array.prototype;e.exports=function(e){var t=e.slice;return e===o||i(o,e)&&t===o.slice?n:t}},12757:(e,t,r)=>{"use strict";var i=r(88280),n=r(11263),o=Array.prototype;e.exports=function(e){var t=e.sort;return e===o||i(o,e)&&t===o.sort?n:t}},80149:(e,t,r)=>{"use strict";r(25837);var i=r(92046).Object;e.exports=function(e,t){return i.create(e,t)}},21926:(e,t,r)=>{"use strict";r(46750);var i=r(92046).Object,n=e.exports=function(e,t,r){return i.defineProperty(e,t,r)};i.defineProperty.sham&&(n.sham=!0)},84326:(e,t,r)=>{"use strict";r(42193);var i=r(92046);e.exports=i.parseInt},48804:(e,t,r)=>{"use strict";r(9164);var i=r(40663);e.exports=i},83842:(e,t,r)=>{"use strict";r(58545),r(86024),r(94452),r(3997),r(75084),r(2596),r(5721),r(44954),r(44123),r(73377),r(72230),r(15344),r(51660),r(4610),r(33669),r(44810),r(93325),r(87024),r(38172),r(85205);var i=r(92046);e.exports=i.Symbol},62014:(e,t,r)=>{"use strict";e.exports=r(8980)},22382:(e,t,r)=>{"use strict";e.exports=r(31564)},81519:(e,t,r)=>{"use strict";e.exports=r(99029)},1958:(e,t,r)=>{"use strict";e.exports=r(63520)},55186:(e,t,r)=>{"use strict";e.exports=r(64908)},93071:(e,t,r)=>{"use strict";e.exports=r(32321)},8980:(e,t,r)=>{"use strict";var i=r(47985);e.exports=i},31564:(e,t,r)=>{"use strict";var i=r(77725);e.exports=i},99029:(e,t,r)=>{"use strict";var i=r(68690);e.exports=i},63520:(e,t,r)=>{"use strict";var i=r(45779);e.exports=i},64908:(e,t,r)=>{"use strict";var i=r(6221);e.exports=i},32321:(e,t,r)=>{"use strict";var i=r(57264);r(13939),r(21785),r(81697),r(84664),r(63422),r(70036),r(28703),r(86878),r(59671),r(50359),e.exports=i},82159:(e,t,r)=>{"use strict";var i=r(62250),n=r(4640),o=TypeError;e.exports=function(e){if(i(e))return e;throw new o(n(e)+" is not a function")}},10043:(e,t,r)=>{"use strict";var i=r(54018),n=String,o=TypeError;e.exports=function(e){if(i(e))return e;throw new o("Can't set "+n(e)+" as a prototype")}},42156:e=>{"use strict";e.exports=function(){}},36624:(e,t,r)=>{"use strict";var i=r(46285),n=String,o=TypeError;e.exports=function(e){if(i(e))return e;throw new o(n(e)+" is not an object")}},22914:(e,t,r)=>{"use strict";var i=r(70726).forEach,n=r(77623)("forEach");e.exports=n?[].forEach:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}},11229:(e,t,r)=>{"use strict";var i=r(28311),n=r(13930),o=r(39298),s=r(26818),a=r(37812),l=r(25468),d=r(20575),c=r(5543),u=r(10300),p=r(73448),h=Array;e.exports=function(e){var t=o(e),r=l(this),f=arguments.length,m=f>1?arguments[1]:void 0,g=void 0!==m;g&&(m=i(m,f>2?arguments[2]:void 0));var y,v,b,w,_,x,S=p(t),k=0;if(!S||this===h&&a(S))for(y=d(t),v=r?new this(y):h(y);y>k;k++)x=g?m(t[k],k):t[k],c(v,k,x);else for(v=r?new this:[],_=(w=u(t,S)).next;!(b=n(_,w)).done;k++)x=g?s(w,m,[b.value,k],!0):b.value,c(v,k,x);return v.length=k,v}},74436:(e,t,r)=>{"use strict";var i=r(27374),n=r(34849),o=r(20575),s=function(e){return function(t,r,s){var a=i(t),l=o(a);if(0===l)return!e&&-1;var d,c=n(s,l);if(e&&r!=r){for(;l>c;)if((d=a[c++])!=d)return!0}else for(;l>c;c++)if((e||c in a)&&a[c]===r)return e||c||0;return!e&&-1}};e.exports={includes:s(!0),indexOf:s(!1)}},70726:(e,t,r)=>{"use strict";var i=r(28311),n=r(1907),o=r(16946),s=r(39298),a=r(20575),l=r(56968),d=n([].push),c=function(e){var t=1===e,r=2===e,n=3===e,c=4===e,u=6===e,p=7===e,h=5===e||u;return function(f,m,g,y){for(var v,b,w=s(f),_=o(w),x=a(_),S=i(m,g),k=0,E=y||l,T=t?E(f,x):r||p?E(f,0):void 0;x>k;k++)if((h||k in _)&&(b=S(v=_[k],k,w),e))if(t)T[k]=b;else if(b)switch(e){case 3:return!0;case 5:return v;case 6:return k;case 2:d(T,v)}else switch(e){case 4:return!1;case 7:d(T,v)}return u?-1:n||c?c:T}};e.exports={forEach:c(0),map:c(1),filter:c(2),some:c(3),every:c(4),find:c(5),findIndex:c(6),filterReject:c(7)}},59552:(e,t,r)=>{"use strict";var i=r(98828),n=r(76264),o=r(20798),s=n("species");e.exports=function(e){return o>=51||!i((function(){var t=[];return(t.constructor={})[s]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},77623:(e,t,r)=>{"use strict";var i=r(98828);e.exports=function(e,t){var r=[][e];return!!r&&i((function(){r.call(null,t||function(){return 1},1)}))}},35043:(e,t,r)=>{"use strict";var i=r(82159),n=r(39298),o=r(16946),s=r(20575),a=TypeError,l="Reduce of empty array with no initial value",d=function(e){return function(t,r,d,c){var u=n(t),p=o(u),h=s(u);if(i(r),0===h&&d<2)throw new a(l);var f=e?h-1:0,m=e?-1:1;if(d<2)for(;;){if(f in p){c=p[f],f+=m;break}if(f+=m,e?f<0:h<=f)throw new a(l)}for(;e?f>=0:h>f;f+=m)f in p&&(c=r(c,p[f],f,u));return c}};e.exports={left:d(!1),right:d(!0)}},3130:(e,t,r)=>{"use strict";var i=r(39447),n=r(11793),o=TypeError,s=Object.getOwnPropertyDescriptor,a=i&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}();e.exports=a?function(e,t){if(n(e)&&!s(e,"length").writable)throw new o("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}},93427:(e,t,r)=>{"use strict";var i=r(1907);e.exports=i([].slice)},34321:(e,t,r)=>{"use strict";var i=r(93427),n=Math.floor,o=function(e,t){var r=e.length;if(r<8)for(var s,a,l=1;l0;)e[a]=e[--a];a!==l++&&(e[a]=s)}else for(var d=n(r/2),c=o(i(e,0,d),t),u=o(i(e,d),t),p=c.length,h=u.length,f=0,m=0;f{"use strict";var i=r(11793),n=r(25468),o=r(46285),s=r(76264)("species"),a=Array;e.exports=function(e){var t;return i(e)&&(t=e.constructor,(n(t)&&(t===a||i(t.prototype))||o(t)&&null===(t=t[s]))&&(t=void 0)),void 0===t?a:t}},56968:(e,t,r)=>{"use strict";var i=r(64010);e.exports=function(e,t){return new(i(e))(0===t?0:t)}},26818:(e,t,r)=>{"use strict";var i=r(36624),n=r(40154);e.exports=function(e,t,r,o){try{return o?t(i(r)[0],r[1]):t(r)}catch(t){n(e,"throw",t)}}},70473:(e,t,r)=>{"use strict";var i=r(76264)("iterator"),n=!1;try{var o=0,s={next:function(){return{done:!!o++}},return:function(){n=!0}};s[i]=function(){return this},Array.from(s,(function(){throw 2}))}catch(e){}e.exports=function(e,t){try{if(!t&&!n)return!1}catch(e){return!1}var r=!1;try{var o={};o[i]=function(){return{next:function(){return{done:r=!0}}}},e(o)}catch(e){}return r}},45807:(e,t,r)=>{"use strict";var i=r(1907),n=i({}.toString),o=i("".slice);e.exports=function(e){return o(n(e),8,-1)}},73948:(e,t,r)=>{"use strict";var i=r(52623),n=r(62250),o=r(45807),s=r(76264)("toStringTag"),a=Object,l="Arguments"===o(function(){return arguments}());e.exports=i?o:function(e){var t,r,i;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(r=function(e,t){try{return e[t]}catch(e){}}(t=a(e),s))?r:l?o(t):"Object"===(i=o(t))&&n(t.callee)?"Arguments":i}},57382:(e,t,r)=>{"use strict";var i=r(98828);e.exports=!i((function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}))},59550:e=>{"use strict";e.exports=function(e,t){return{value:e,done:t}}},61626:(e,t,r)=>{"use strict";var i=r(39447),n=r(74284),o=r(75817);e.exports=i?function(e,t,r){return n.f(e,t,o(1,r))}:function(e,t,r){return e[t]=r,e}},75817:e=>{"use strict";e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},5543:(e,t,r)=>{"use strict";var i=r(39447),n=r(74284),o=r(75817);e.exports=function(e,t,r){i?n.f(e,t,o(0,r)):e[t]=r}},89251:(e,t,r)=>{"use strict";var i=r(74284);e.exports=function(e,t,r){return i.f(e,t,r)}},68055:(e,t,r)=>{"use strict";var i=r(61626);e.exports=function(e,t,r,n){return n&&n.enumerable?e[t]=r:i(e,t,r),e}},2532:(e,t,r)=>{"use strict";var i=r(45951),n=Object.defineProperty;e.exports=function(e,t){try{n(i,e,{value:t,configurable:!0,writable:!0})}catch(r){i[e]=t}return t}},74535:(e,t,r)=>{"use strict";var i=r(4640),n=TypeError;e.exports=function(e,t){if(!delete e[t])throw new n("Cannot delete property "+i(t)+" of "+i(e))}},39447:(e,t,r)=>{"use strict";var i=r(98828);e.exports=!i((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))},49552:(e,t,r)=>{"use strict";var i=r(45951),n=r(46285),o=i.document,s=n(o)&&n(o.createElement);e.exports=function(e){return s?o.createElement(e):{}}},88024:e=>{"use strict";var t=TypeError;e.exports=function(e){if(e>9007199254740991)throw t("Maximum allowed index exceeded");return e}},19287:e=>{"use strict";e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},80376:e=>{"use strict";e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},93440:(e,t,r)=>{"use strict";var i=r(96794).match(/firefox\/(\d+)/i);e.exports=!!i&&+i[1]},24328:(e,t,r)=>{"use strict";var i=r(96794);e.exports=/MSIE|Trident/.test(i)},47586:(e,t,r)=>{"use strict";var i=r(42832);e.exports="NODE"===i},96794:(e,t,r)=>{"use strict";var i=r(45951).navigator,n=i&&i.userAgent;e.exports=n?String(n):""},20798:(e,t,r)=>{"use strict";var i,n,o=r(45951),s=r(96794),a=o.process,l=o.Deno,d=a&&a.versions||l&&l.version,c=d&&d.v8;c&&(n=(i=c.split("."))[0]>0&&i[0]<4?1:+(i[0]+i[1])),!n&&s&&(!(i=s.match(/Edge\/(\d+)/))||i[1]>=74)&&(i=s.match(/Chrome\/(\d+)/))&&(n=+i[1]),e.exports=n},3786:(e,t,r)=>{"use strict";var i=r(96794).match(/AppleWebKit\/(\d+)\./);e.exports=!!i&&+i[1]},42832:(e,t,r)=>{"use strict";var i=r(45951),n=r(96794),o=r(45807),s=function(e){return n.slice(0,e.length)===e};e.exports=s("Bun/")?"BUN":s("Cloudflare-Workers")?"CLOUDFLARE":s("Deno/")?"DENO":s("Node.js/")?"NODE":i.Bun&&"string"==typeof Bun.version?"BUN":i.Deno&&"object"==typeof Deno.version?"DENO":"process"===o(i.process)?"NODE":i.window&&i.document?"BROWSER":"REST"},11091:(e,t,r)=>{"use strict";var i=r(45951),n=r(76024),o=r(92361),s=r(62250),a=r(13846).f,l=r(7463),d=r(92046),c=r(28311),u=r(61626),p=r(49724);r(36128);var h=function(e){var t=function(r,i,o){if(this instanceof t){switch(arguments.length){case 0:return new e;case 1:return new e(r);case 2:return new e(r,i)}return new e(r,i,o)}return n(e,this,arguments)};return t.prototype=e.prototype,t};e.exports=function(e,t){var r,n,f,m,g,y,v,b,w,_=e.target,x=e.global,S=e.stat,k=e.proto,E=x?i:S?i[_]:i[_]&&i[_].prototype,T=x?d:d[_]||u(d,_,{})[_],B=T.prototype;for(m in t)n=!(r=l(x?m:_+(S?".":"#")+m,e.forced))&&E&&p(E,m),y=T[m],n&&(v=e.dontCallGetSet?(w=a(E,m))&&w.value:E[m]),g=n&&v?v:t[m],(r||k||typeof y!=typeof g)&&(b=e.bind&&n?c(g,i):e.wrap&&n?h(g):k&&s(g)?o(g):g,(e.sham||g&&g.sham||y&&y.sham)&&u(b,"sham",!0),u(T,m,b),k&&(p(d,f=_+"Prototype")||u(d,f,{}),u(d[f],m,g),e.real&&B&&(r||!B[m])&&u(B,m,g)))}},98828:e=>{"use strict";e.exports=function(e){try{return!!e()}catch(e){return!0}}},76024:(e,t,r)=>{"use strict";var i=r(41505),n=Function.prototype,o=n.apply,s=n.call;e.exports="object"==typeof Reflect&&Reflect.apply||(i?s.bind(o):function(){return s.apply(o,arguments)})},28311:(e,t,r)=>{"use strict";var i=r(92361),n=r(82159),o=r(41505),s=i(i.bind);e.exports=function(e,t){return n(e),void 0===t?e:o?s(e,t):function(){return e.apply(t,arguments)}}},41505:(e,t,r)=>{"use strict";var i=r(98828);e.exports=!i((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))},13930:(e,t,r)=>{"use strict";var i=r(41505),n=Function.prototype.call;e.exports=i?n.bind(n):function(){return n.apply(n,arguments)}},36833:(e,t,r)=>{"use strict";var i=r(39447),n=r(49724),o=Function.prototype,s=i&&Object.getOwnPropertyDescriptor,a=n(o,"name"),l=a&&"something"===function(){}.name,d=a&&(!i||i&&s(o,"name").configurable);e.exports={EXISTS:a,PROPER:l,CONFIGURABLE:d}},51871:(e,t,r)=>{"use strict";var i=r(1907),n=r(82159);e.exports=function(e,t,r){try{return i(n(Object.getOwnPropertyDescriptor(e,t)[r]))}catch(e){}}},92361:(e,t,r)=>{"use strict";var i=r(45807),n=r(1907);e.exports=function(e){if("Function"===i(e))return n(e)}},1907:(e,t,r)=>{"use strict";var i=r(41505),n=Function.prototype,o=n.call,s=i&&n.bind.bind(o,o);e.exports=i?s:function(e){return function(){return o.apply(e,arguments)}}},61747:(e,t,r)=>{"use strict";var i=r(45951),n=r(92046);e.exports=function(e,t){var r=n[e+"Prototype"],o=r&&r[t];if(o)return o;var s=i[e],a=s&&s.prototype;return a&&a[t]}},85582:(e,t,r)=>{"use strict";var i=r(92046),n=r(45951),o=r(62250),s=function(e){return o(e)?e:void 0};e.exports=function(e,t){return arguments.length<2?s(i[e])||s(n[e]):i[e]&&i[e][t]||n[e]&&n[e][t]}},73448:(e,t,r)=>{"use strict";var i=r(73948),n=r(29367),o=r(87136),s=r(93742),a=r(76264)("iterator");e.exports=function(e){if(!o(e))return n(e,a)||n(e,"@@iterator")||s[i(e)]}},10300:(e,t,r)=>{"use strict";var i=r(13930),n=r(82159),o=r(36624),s=r(4640),a=r(73448),l=TypeError;e.exports=function(e,t){var r=arguments.length<2?a(e):t;if(n(r))return o(i(r,e));throw new l(s(e)+" is not iterable")}},96656:(e,t,r)=>{"use strict";var i=r(1907),n=r(11793),o=r(62250),s=r(45807),a=r(90160),l=i([].push);e.exports=function(e){if(o(e))return e;if(n(e)){for(var t=e.length,r=[],i=0;i{"use strict";var i=r(82159),n=r(87136);e.exports=function(e,t){var r=e[t];return n(r)?void 0:i(r)}},45951:function(e,t,r){"use strict";var i=function(e){return e&&e.Math===Math&&e};e.exports=i("object"==typeof globalThis&&globalThis)||i("object"==typeof window&&window)||i("object"==typeof self&&self)||i("object"==typeof r.g&&r.g)||i("object"==typeof this&&this)||function(){return this}()||Function("return this")()},49724:(e,t,r)=>{"use strict";var i=r(1907),n=r(39298),o=i({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return o(n(e),t)}},38530:e=>{"use strict";e.exports={}},62416:(e,t,r)=>{"use strict";var i=r(85582);e.exports=i("document","documentElement")},73648:(e,t,r)=>{"use strict";var i=r(39447),n=r(98828),o=r(49552);e.exports=!i&&!n((function(){return 7!==Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},16946:(e,t,r)=>{"use strict";var i=r(1907),n=r(98828),o=r(45807),s=Object,a=i("".split);e.exports=n((function(){return!s("z").propertyIsEnumerable(0)}))?function(e){return"String"===o(e)?a(e,""):s(e)}:s},12647:(e,t,r)=>{"use strict";var i=r(1907),n=r(62250),o=r(36128),s=i(Function.toString);n(o.inspectSource)||(o.inspectSource=function(e){return s(e)}),e.exports=o.inspectSource},64932:(e,t,r)=>{"use strict";var i,n,o,s=r(40551),a=r(45951),l=r(46285),d=r(61626),c=r(49724),u=r(36128),p=r(92522),h=r(38530),f="Object already initialized",m=a.TypeError,g=a.WeakMap;if(s||u.state){var y=u.state||(u.state=new g);y.get=y.get,y.has=y.has,y.set=y.set,i=function(e,t){if(y.has(e))throw new m(f);return t.facade=e,y.set(e,t),t},n=function(e){return y.get(e)||{}},o=function(e){return y.has(e)}}else{var v=p("state");h[v]=!0,i=function(e,t){if(c(e,v))throw new m(f);return t.facade=e,d(e,v,t),t},n=function(e){return c(e,v)?e[v]:{}},o=function(e){return c(e,v)}}e.exports={set:i,get:n,has:o,enforce:function(e){return o(e)?n(e):i(e,{})},getterFor:function(e){return function(t){var r;if(!l(t)||(r=n(t)).type!==e)throw new m("Incompatible receiver, "+e+" required");return r}}}},37812:(e,t,r)=>{"use strict";var i=r(76264),n=r(93742),o=i("iterator"),s=Array.prototype;e.exports=function(e){return void 0!==e&&(n.Array===e||s[o]===e)}},11793:(e,t,r)=>{"use strict";var i=r(45807);e.exports=Array.isArray||function(e){return"Array"===i(e)}},62250:e=>{"use strict";var t="object"==typeof document&&document.all;e.exports=void 0===t&&void 0!==t?function(e){return"function"==typeof e||e===t}:function(e){return"function"==typeof e}},25468:(e,t,r)=>{"use strict";var i=r(1907),n=r(98828),o=r(62250),s=r(73948),a=r(85582),l=r(12647),d=function(){},c=a("Reflect","construct"),u=/^\s*(?:class|function)\b/,p=i(u.exec),h=!u.test(d),f=function(e){if(!o(e))return!1;try{return c(d,[],e),!0}catch(e){return!1}},m=function(e){if(!o(e))return!1;switch(s(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return h||!!p(u,l(e))}catch(e){return!0}};m.sham=!0,e.exports=!c||n((function(){var e;return f(f.call)||!f(Object)||!f((function(){e=!0}))||e}))?m:f},7463:(e,t,r)=>{"use strict";var i=r(98828),n=r(62250),o=/#|\.prototype\./,s=function(e,t){var r=l[a(e)];return r===c||r!==d&&(n(t)?i(t):!!t)},a=s.normalize=function(e){return String(e).replace(o,".").toLowerCase()},l=s.data={},d=s.NATIVE="N",c=s.POLYFILL="P";e.exports=s},87136:e=>{"use strict";e.exports=function(e){return null==e}},46285:(e,t,r)=>{"use strict";var i=r(62250);e.exports=function(e){return"object"==typeof e?null!==e:i(e)}},54018:(e,t,r)=>{"use strict";var i=r(46285);e.exports=function(e){return i(e)||null===e}},7376:e=>{"use strict";e.exports=!0},25594:(e,t,r)=>{"use strict";var i=r(85582),n=r(62250),o=r(88280),s=r(51175),a=Object;e.exports=s?function(e){return"symbol"==typeof e}:function(e){var t=i("Symbol");return n(t)&&o(t.prototype,a(e))}},40154:(e,t,r)=>{"use strict";var i=r(13930),n=r(36624),o=r(29367);e.exports=function(e,t,r){var s,a;n(e);try{if(!(s=o(e,"return"))){if("throw"===t)throw r;return r}s=i(s,e)}catch(e){a=!0,s=e}if("throw"===t)throw r;if(a)throw s;return n(s),r}},47181:(e,t,r)=>{"use strict";var i=r(95116).IteratorPrototype,n=r(58075),o=r(75817),s=r(14840),a=r(93742),l=function(){return this};e.exports=function(e,t,r,d){var c=t+" Iterator";return e.prototype=n(i,{next:o(+!d,r)}),s(e,c,!1,!0),a[c]=l,e}},60183:(e,t,r)=>{"use strict";var i=r(11091),n=r(13930),o=r(7376),s=r(36833),a=r(62250),l=r(47181),d=r(15972),c=r(79192),u=r(14840),p=r(61626),h=r(68055),f=r(76264),m=r(93742),g=r(95116),y=s.PROPER,v=s.CONFIGURABLE,b=g.IteratorPrototype,w=g.BUGGY_SAFARI_ITERATORS,_=f("iterator"),x="keys",S="values",k="entries",E=function(){return this};e.exports=function(e,t,r,s,f,g,T){l(r,t,s);var B,C,I,A=function(e){if(e===f&&P)return P;if(!w&&e&&e in D)return D[e];switch(e){case x:case S:case k:return function(){return new r(this,e)}}return function(){return new r(this)}},F=t+" Iterator",M=!1,D=e.prototype,R=D[_]||D["@@iterator"]||f&&D[f],P=!w&&R||A(f),O="Array"===t&&D.entries||R;if(O&&(B=d(O.call(new e)))!==Object.prototype&&B.next&&(o||d(B)===b||(c?c(B,b):a(B[_])||h(B,_,E)),u(B,F,!0,!0),o&&(m[F]=E)),y&&f===S&&R&&R.name!==S&&(!o&&v?p(D,"name",S):(M=!0,P=function(){return n(R,this)})),f)if(C={values:A(S),keys:g?P:A(x),entries:A(k)},T)for(I in C)(w||M||!(I in D))&&h(D,I,C[I]);else i({target:t,proto:!0,forced:w||M},C);return o&&!T||D[_]===P||h(D,_,P,{name:f}),m[t]=P,C}},95116:(e,t,r)=>{"use strict";var i,n,o,s=r(98828),a=r(62250),l=r(46285),d=r(58075),c=r(15972),u=r(68055),p=r(76264),h=r(7376),f=p("iterator"),m=!1;[].keys&&("next"in(o=[].keys())?(n=c(c(o)))!==Object.prototype&&(i=n):m=!0),!l(i)||s((function(){var e={};return i[f].call(e)!==e}))?i={}:h&&(i=d(i)),a(i[f])||u(i,f,(function(){return this})),e.exports={IteratorPrototype:i,BUGGY_SAFARI_ITERATORS:m}},93742:e=>{"use strict";e.exports={}},20575:(e,t,r)=>{"use strict";var i=r(3121);e.exports=function(e){return i(e.length)}},41176:e=>{"use strict";var t=Math.ceil,r=Math.floor;e.exports=Math.trunc||function(e){var i=+e;return(i>0?r:t)(i)}},72778:(e,t,r)=>{"use strict";var i=r(45951),n=r(98828),o=r(1907),s=r(90160),a=r(65993).trim,l=r(86395),d=i.parseInt,c=i.Symbol,u=c&&c.iterator,p=/^[+-]?0x/i,h=o(p.exec),f=8!==d(l+"08")||22!==d(l+"0x16")||u&&!n((function(){d(Object(u))}));e.exports=f?function(e,t){var r=a(s(e));return d(r,t>>>0||(h(p,r)?16:10))}:d},58075:(e,t,r)=>{"use strict";var i,n=r(36624),o=r(42220),s=r(80376),a=r(38530),l=r(62416),d=r(49552),c=r(92522),u="prototype",p="script",h=c("IE_PROTO"),f=function(){},m=function(e){return"<"+p+">"+e+""},g=function(e){e.write(m("")),e.close();var t=e.parentWindow.Object;return e=null,t},y=function(){try{i=new ActiveXObject("htmlfile")}catch(e){}var e,t,r;y="undefined"!=typeof document?document.domain&&i?g(i):(t=d("iframe"),r="java"+p+":",t.style.display="none",l.appendChild(t),t.src=String(r),(e=t.contentWindow.document).open(),e.write(m("document.F=Object")),e.close(),e.F):g(i);for(var n=s.length;n--;)delete y[u][s[n]];return y()};a[h]=!0,e.exports=Object.create||function(e,t){var r;return null!==e?(f[u]=n(e),r=new f,f[u]=null,r[h]=e):r=y(),void 0===t?r:o.f(r,t)}},42220:(e,t,r)=>{"use strict";var i=r(39447),n=r(58661),o=r(74284),s=r(36624),a=r(27374),l=r(2875);t.f=i&&!n?Object.defineProperties:function(e,t){s(e);for(var r,i=a(t),n=l(t),d=n.length,c=0;d>c;)o.f(e,r=n[c++],i[r]);return e}},74284:(e,t,r)=>{"use strict";var i=r(39447),n=r(73648),o=r(58661),s=r(36624),a=r(70470),l=TypeError,d=Object.defineProperty,c=Object.getOwnPropertyDescriptor,u="enumerable",p="configurable",h="writable";t.f=i?o?function(e,t,r){if(s(e),t=a(t),s(r),"function"==typeof e&&"prototype"===t&&"value"in r&&h in r&&!r[h]){var i=c(e,t);i&&i[h]&&(e[t]=r.value,r={configurable:p in r?r[p]:i[p],enumerable:u in r?r[u]:i[u],writable:!1})}return d(e,t,r)}:d:function(e,t,r){if(s(e),t=a(t),s(r),n)try{return d(e,t,r)}catch(e){}if("get"in r||"set"in r)throw new l("Accessors not supported");return"value"in r&&(e[t]=r.value),e}},13846:(e,t,r)=>{"use strict";var i=r(39447),n=r(13930),o=r(22574),s=r(75817),a=r(27374),l=r(70470),d=r(49724),c=r(73648),u=Object.getOwnPropertyDescriptor;t.f=i?u:function(e,t){if(e=a(e),t=l(t),c)try{return u(e,t)}catch(e){}if(d(e,t))return s(!n(o.f,e,t),e[t])}},25407:(e,t,r)=>{"use strict";var i=r(45807),n=r(27374),o=r(24443).f,s=r(93427),a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return a&&"Window"===i(e)?function(e){try{return o(e)}catch(e){return s(a)}}(e):o(n(e))}},24443:(e,t,r)=>{"use strict";var i=r(23045),n=r(80376).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return i(e,n)}},87170:(e,t)=>{"use strict";t.f=Object.getOwnPropertySymbols},15972:(e,t,r)=>{"use strict";var i=r(49724),n=r(62250),o=r(39298),s=r(92522),a=r(57382),l=s("IE_PROTO"),d=Object,c=d.prototype;e.exports=a?d.getPrototypeOf:function(e){var t=o(e);if(i(t,l))return t[l];var r=t.constructor;return n(r)&&t instanceof r?r.prototype:t instanceof d?c:null}},88280:(e,t,r)=>{"use strict";var i=r(1907);e.exports=i({}.isPrototypeOf)},23045:(e,t,r)=>{"use strict";var i=r(1907),n=r(49724),o=r(27374),s=r(74436).indexOf,a=r(38530),l=i([].push);e.exports=function(e,t){var r,i=o(e),d=0,c=[];for(r in i)!n(a,r)&&n(i,r)&&l(c,r);for(;t.length>d;)n(i,r=t[d++])&&(~s(c,r)||l(c,r));return c}},2875:(e,t,r)=>{"use strict";var i=r(23045),n=r(80376);e.exports=Object.keys||function(e){return i(e,n)}},22574:(e,t)=>{"use strict";var r={}.propertyIsEnumerable,i=Object.getOwnPropertyDescriptor,n=i&&!r.call({1:2},1);t.f=n?function(e){var t=i(this,e);return!!t&&t.enumerable}:r},79192:(e,t,r)=>{"use strict";var i=r(51871),n=r(46285),o=r(74239),s=r(10043);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,r={};try{(e=i(Object.prototype,"__proto__","set"))(r,[]),t=r instanceof Array}catch(e){}return function(r,i){return o(r),s(i),n(r)?(t?e(r,i):r.__proto__=i,r):r}}():void 0)},54878:(e,t,r)=>{"use strict";var i=r(52623),n=r(73948);e.exports=i?{}.toString:function(){return"[object "+n(this)+"]"}},60581:(e,t,r)=>{"use strict";var i=r(13930),n=r(62250),o=r(46285),s=TypeError;e.exports=function(e,t){var r,a;if("string"===t&&n(r=e.toString)&&!o(a=i(r,e)))return a;if(n(r=e.valueOf)&&!o(a=i(r,e)))return a;if("string"!==t&&n(r=e.toString)&&!o(a=i(r,e)))return a;throw new s("Can't convert object to primitive value")}},92046:e=>{"use strict";e.exports={}},85606:(e,t,r)=>{"use strict";var i=r(36624);e.exports=function(){var e=i(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t}},40663:(e,t,r)=>{"use strict";var i=r(13930),n=r(49724),o=r(88280),s=r(85606),a=RegExp.prototype;e.exports=function(e){var t=e.flags;return void 0!==t||"flags"in a||n(e,"flags")||!o(a,e)?t:i(s,e)}},74239:(e,t,r)=>{"use strict";var i=r(87136),n=TypeError;e.exports=function(e){if(i(e))throw new n("Can't call method on "+e);return e}},14840:(e,t,r)=>{"use strict";var i=r(52623),n=r(74284).f,o=r(61626),s=r(49724),a=r(54878),l=r(76264)("toStringTag");e.exports=function(e,t,r,d){var c=r?e:e&&e.prototype;c&&(s(c,l)||n(c,l,{configurable:!0,value:t}),d&&!i&&o(c,"toString",a))}},92522:(e,t,r)=>{"use strict";var i=r(85816),n=r(6499),o=i("keys");e.exports=function(e){return o[e]||(o[e]=n(e))}},36128:(e,t,r)=>{"use strict";var i=r(7376),n=r(45951),o=r(2532),s="__core-js_shared__",a=e.exports=n[s]||o(s,{});(a.versions||(a.versions=[])).push({version:"3.38.1",mode:i?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})},85816:(e,t,r)=>{"use strict";var i=r(36128);e.exports=function(e,t){return i[e]||(i[e]=t||{})}},11470:(e,t,r)=>{"use strict";var i=r(1907),n=r(65482),o=r(90160),s=r(74239),a=i("".charAt),l=i("".charCodeAt),d=i("".slice),c=function(e){return function(t,r){var i,c,u=o(s(t)),p=n(r),h=u.length;return p<0||p>=h?e?"":void 0:(i=l(u,p))<55296||i>56319||p+1===h||(c=l(u,p+1))<56320||c>57343?e?a(u,p):i:e?d(u,p,p+2):c-56320+(i-55296<<10)+65536}};e.exports={codeAt:c(!1),charAt:c(!0)}},65993:(e,t,r)=>{"use strict";var i=r(1907),n=r(74239),o=r(90160),s=r(86395),a=i("".replace),l=RegExp("^["+s+"]+"),d=RegExp("(^|[^"+s+"])["+s+"]+$"),c=function(e){return function(t){var r=o(n(t));return 1&e&&(r=a(r,l,"")),2&e&&(r=a(r,d,"$1")),r}};e.exports={start:c(1),end:c(2),trim:c(3)}},19846:(e,t,r)=>{"use strict";var i=r(20798),n=r(98828),o=r(45951).String;e.exports=!!Object.getOwnPropertySymbols&&!n((function(){var e=Symbol("symbol detection");return!o(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&i&&i<41}))},83467:(e,t,r)=>{"use strict";var i=r(13930),n=r(85582),o=r(76264),s=r(68055);e.exports=function(){var e=n("Symbol"),t=e&&e.prototype,r=t&&t.valueOf,a=o("toPrimitive");t&&!t[a]&&s(t,a,(function(e){return i(r,this)}),{arity:1})}},12595:(e,t,r)=>{"use strict";var i=r(85582),n=r(1907),o=i("Symbol"),s=o.keyFor,a=n(o.prototype.valueOf);e.exports=o.isRegisteredSymbol||function(e){try{return void 0!==s(a(e))}catch(e){return!1}}},69197:(e,t,r)=>{"use strict";for(var i=r(85816),n=r(85582),o=r(1907),s=r(25594),a=r(76264),l=n("Symbol"),d=l.isWellKnownSymbol,c=n("Object","getOwnPropertyNames"),u=o(l.prototype.valueOf),p=i("wks"),h=0,f=c(l),m=f.length;h{"use strict";var i=r(19846);e.exports=i&&!!Symbol.for&&!!Symbol.keyFor},34849:(e,t,r)=>{"use strict";var i=r(65482),n=Math.max,o=Math.min;e.exports=function(e,t){var r=i(e);return r<0?n(r+t,0):o(r,t)}},27374:(e,t,r)=>{"use strict";var i=r(16946),n=r(74239);e.exports=function(e){return i(n(e))}},65482:(e,t,r)=>{"use strict";var i=r(41176);e.exports=function(e){var t=+e;return t!=t||0===t?0:i(t)}},3121:(e,t,r)=>{"use strict";var i=r(65482),n=Math.min;e.exports=function(e){var t=i(e);return t>0?n(t,9007199254740991):0}},39298:(e,t,r)=>{"use strict";var i=r(74239),n=Object;e.exports=function(e){return n(i(e))}},46028:(e,t,r)=>{"use strict";var i=r(13930),n=r(46285),o=r(25594),s=r(29367),a=r(60581),l=r(76264),d=TypeError,c=l("toPrimitive");e.exports=function(e,t){if(!n(e)||o(e))return e;var r,l=s(e,c);if(l){if(void 0===t&&(t="default"),r=i(l,e,t),!n(r)||o(r))return r;throw new d("Can't convert object to primitive value")}return void 0===t&&(t="number"),a(e,t)}},70470:(e,t,r)=>{"use strict";var i=r(46028),n=r(25594);e.exports=function(e){var t=i(e,"string");return n(t)?t:t+""}},52623:(e,t,r)=>{"use strict";var i={};i[r(76264)("toStringTag")]="z",e.exports="[object z]"===String(i)},90160:(e,t,r)=>{"use strict";var i=r(73948),n=String;e.exports=function(e){if("Symbol"===i(e))throw new TypeError("Cannot convert a Symbol value to a string");return n(e)}},4640:e=>{"use strict";var t=String;e.exports=function(e){try{return t(e)}catch(e){return"Object"}}},6499:(e,t,r)=>{"use strict";var i=r(1907),n=0,o=Math.random(),s=i(1..toString);e.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+s(++n+o,36)}},51175:(e,t,r)=>{"use strict";var i=r(19846);e.exports=i&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},58661:(e,t,r)=>{"use strict";var i=r(39447),n=r(98828);e.exports=i&&n((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},40551:(e,t,r)=>{"use strict";var i=r(45951),n=r(62250),o=i.WeakMap;e.exports=n(o)&&/native code/.test(String(o))},20366:(e,t,r)=>{"use strict";var i=r(92046),n=r(49724),o=r(80560),s=r(74284).f;e.exports=function(e){var t=i.Symbol||(i.Symbol={});n(t,e)||s(t,e,{value:o.f(e)})}},80560:(e,t,r)=>{"use strict";var i=r(76264);t.f=i},76264:(e,t,r)=>{"use strict";var i=r(45951),n=r(85816),o=r(49724),s=r(6499),a=r(19846),l=r(51175),d=i.Symbol,c=n("wks"),u=l?d.for||d:d&&d.withoutSetter||s;e.exports=function(e){return o(c,e)||(c[e]=a&&o(d,e)?d[e]:u("Symbol."+e)),c[e]}},86395:e=>{"use strict";e.exports="\t\n\v\f\r                 \u2028\u2029\ufeff"},58545:(e,t,r)=>{"use strict";var i=r(11091),n=r(98828),o=r(11793),s=r(46285),a=r(39298),l=r(20575),d=r(88024),c=r(5543),u=r(56968),p=r(59552),h=r(76264),f=r(20798),m=h("isConcatSpreadable"),g=f>=51||!n((function(){var e=[];return e[m]=!1,e.concat()[0]!==e})),y=function(e){if(!s(e))return!1;var t=e[m];return void 0!==t?!!t:o(e)};i({target:"Array",proto:!0,arity:1,forced:!g||!p("concat")},{concat:function(e){var t,r,i,n,o,s=a(this),p=u(s,0),h=0;for(t=-1,i=arguments.length;t{"use strict";var i=r(11091),n=r(22914);i({target:"Array",proto:!0,forced:[].forEach!==n},{forEach:n})},57277:(e,t,r)=>{"use strict";var i=r(11091),n=r(11229);i({target:"Array",stat:!0,forced:!r(70473)((function(e){Array.from(e)}))},{from:n})},66391:(e,t,r)=>{"use strict";var i=r(11091),n=r(92361),o=r(74436).indexOf,s=r(77623),a=n([].indexOf),l=!!a&&1/a([1],1,-0)<0;i({target:"Array",proto:!0,forced:l||!s("indexOf")},{indexOf:function(e){var t=arguments.length>1?arguments[1]:void 0;return l?a(this,e,t)||0:o(this,e,t)}})},92425:(e,t,r)=>{"use strict";r(11091)({target:"Array",stat:!0},{isArray:r(11793)})},99363:(e,t,r)=>{"use strict";var i=r(27374),n=r(42156),o=r(93742),s=r(64932),a=r(74284).f,l=r(60183),d=r(59550),c=r(7376),u=r(39447),p="Array Iterator",h=s.set,f=s.getterFor(p);e.exports=l(Array,"Array",(function(e,t){h(this,{type:p,target:i(e),index:0,kind:t})}),(function(){var e=f(this),t=e.target,r=e.index++;if(!t||r>=t.length)return e.target=null,d(void 0,!0);switch(e.kind){case"keys":return d(r,!1);case"values":return d(t[r],!1)}return d([r,t[r]],!1)}),"values");var m=o.Arguments=o.Array;if(n("keys"),n("values"),n("entries"),!c&&u&&"values"!==m.name)try{a(m,"name",{value:"values"})}catch(e){}},6687:(e,t,r)=>{"use strict";var i=r(11091),n=r(70726).map;i({target:"Array",proto:!0,forced:!r(59552)("map")},{map:function(e){return n(this,e,arguments.length>1?arguments[1]:void 0)}})},85745:(e,t,r)=>{"use strict";var i=r(11091),n=r(39298),o=r(20575),s=r(3130),a=r(88024);i({target:"Array",proto:!0,arity:1,forced:r(98828)((function(){return 4294967297!==[].push.call({length:4294967296},1)}))||!function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}}()},{push:function(e){var t=n(this),r=o(t),i=arguments.length;a(r+i);for(var l=0;l{"use strict";var i=r(11091),n=r(35043).left,o=r(77623),s=r(20798);i({target:"Array",proto:!0,forced:!r(47586)&&s>79&&s<83||!o("reduce")},{reduce:function(e){var t=arguments.length;return n(this,e,t,t>1?arguments[1]:void 0)}})},62099:(e,t,r)=>{"use strict";var i=r(11091),n=r(11793),o=r(25468),s=r(46285),a=r(34849),l=r(20575),d=r(27374),c=r(5543),u=r(76264),p=r(59552),h=r(93427),f=p("slice"),m=u("species"),g=Array,y=Math.max;i({target:"Array",proto:!0,forced:!f},{slice:function(e,t){var r,i,u,p=d(this),f=l(p),v=a(e,f),b=a(void 0===t?f:t,f);if(n(p)&&(r=p.constructor,(o(r)&&(r===g||n(r.prototype))||s(r)&&null===(r=r[m]))&&(r=void 0),r===g||void 0===r))return h(p,v,b);for(i=new(void 0===r?g:r)(y(b-v,0)),u=0;v{"use strict";var i=r(11091),n=r(1907),o=r(82159),s=r(39298),a=r(20575),l=r(74535),d=r(90160),c=r(98828),u=r(34321),p=r(77623),h=r(93440),f=r(24328),m=r(20798),g=r(3786),y=[],v=n(y.sort),b=n(y.push),w=c((function(){y.sort(void 0)})),_=c((function(){y.sort(null)})),x=p("sort"),S=!c((function(){if(m)return m<70;if(!(h&&h>3)){if(f)return!0;if(g)return g<603;var e,t,r,i,n="";for(e=65;e<76;e++){switch(t=String.fromCharCode(e),e){case 66:case 69:case 70:case 72:r=3;break;case 68:case 71:r=4;break;default:r=2}for(i=0;i<47;i++)y.push({k:t+i,v:r})}for(y.sort((function(e,t){return t.v-e.v})),i=0;id(r)?1:-1}}(e)),r=a(n),i=0;i{"use strict";var i=r(11091),n=r(85582),o=r(76024),s=r(13930),a=r(1907),l=r(98828),d=r(62250),c=r(25594),u=r(93427),p=r(96656),h=r(19846),f=String,m=n("JSON","stringify"),g=a(/./.exec),y=a("".charAt),v=a("".charCodeAt),b=a("".replace),w=a(1..toString),_=/[\uD800-\uDFFF]/g,x=/^[\uD800-\uDBFF]$/,S=/^[\uDC00-\uDFFF]$/,k=!h||l((function(){var e=n("Symbol")("stringify detection");return"[null]"!==m([e])||"{}"!==m({a:e})||"{}"!==m(Object(e))})),E=l((function(){return'"\\udf06\\ud834"'!==m("\udf06\ud834")||'"\\udead"'!==m("\udead")})),T=function(e,t){var r=u(arguments),i=p(t);if(d(i)||void 0!==e&&!c(e))return r[1]=function(e,t){if(d(i)&&(t=s(i,this,f(e),t)),!c(t))return t},o(m,null,r)},B=function(e,t,r){var i=y(r,t-1),n=y(r,t+1);return g(x,e)&&!g(S,n)||g(S,e)&&!g(x,i)?"\\u"+w(v(e,0),16):e};m&&i({target:"JSON",stat:!0,arity:3,forced:k||E},{stringify:function(e,t,r){var i=u(arguments),n=o(k?T:m,null,i);return E&&"string"==typeof n?b(n,_,B):n}})},87024:(e,t,r)=>{"use strict";var i=r(45951);r(14840)(i.JSON,"JSON",!0)},38172:()=>{},25837:(e,t,r)=>{"use strict";r(11091)({target:"Object",stat:!0,sham:!r(39447)},{create:r(58075)})},46750:(e,t,r)=>{"use strict";var i=r(11091),n=r(39447),o=r(74284).f;i({target:"Object",stat:!0,forced:Object.defineProperty!==o,sham:!n},{defineProperty:o})},55264:(e,t,r)=>{"use strict";var i=r(11091),n=r(19846),o=r(98828),s=r(87170),a=r(39298);i({target:"Object",stat:!0,forced:!n||o((function(){s.f(1)}))},{getOwnPropertySymbols:function(e){var t=s.f;return t?t(a(e)):[]}})},86024:()=>{},42193:(e,t,r)=>{"use strict";var i=r(11091),n=r(72778);i({global:!0,forced:parseInt!==n},{parseInt:n})},85205:()=>{},9164:()=>{},7057:(e,t,r)=>{"use strict";var i=r(11470).charAt,n=r(90160),o=r(64932),s=r(60183),a=r(59550),l="String Iterator",d=o.set,c=o.getterFor(l);s(String,"String",(function(e){d(this,{type:l,string:n(e),index:0})}),(function(){var e,t=c(this),r=t.string,n=t.index;return n>=r.length?a(void 0,!0):(e=i(r,n),t.index+=e.length,a(e,!1))}))},3997:(e,t,r)=>{"use strict";r(20366)("asyncIterator")},23674:(e,t,r)=>{"use strict";var i=r(11091),n=r(45951),o=r(13930),s=r(1907),a=r(7376),l=r(39447),d=r(19846),c=r(98828),u=r(49724),p=r(88280),h=r(36624),f=r(27374),m=r(70470),g=r(90160),y=r(75817),v=r(58075),b=r(2875),w=r(24443),_=r(25407),x=r(87170),S=r(13846),k=r(74284),E=r(42220),T=r(22574),B=r(68055),C=r(89251),I=r(85816),A=r(92522),F=r(38530),M=r(6499),D=r(76264),R=r(80560),P=r(20366),O=r(83467),z=r(14840),N=r(64932),q=r(70726).forEach,U=A("hidden"),L="Symbol",j="prototype",H=N.set,$=N.getterFor(L),G=Object[j],W=n.Symbol,K=W&&W[j],V=n.RangeError,J=n.TypeError,Y=n.QObject,Q=S.f,Z=k.f,X=_.f,ee=T.f,te=s([].push),re=I("symbols"),ie=I("op-symbols"),ne=I("wks"),oe=!Y||!Y[j]||!Y[j].findChild,se=function(e,t,r){var i=Q(G,t);i&&delete G[t],Z(e,t,r),i&&e!==G&&Z(G,t,i)},ae=l&&c((function(){return 7!==v(Z({},"a",{get:function(){return Z(this,"a",{value:7}).a}})).a}))?se:Z,le=function(e,t){var r=re[e]=v(K);return H(r,{type:L,tag:e,description:t}),l||(r.description=t),r},de=function(e,t,r){e===G&&de(ie,t,r),h(e);var i=m(t);return h(r),u(re,i)?(r.enumerable?(u(e,U)&&e[U][i]&&(e[U][i]=!1),r=v(r,{enumerable:y(0,!1)})):(u(e,U)||Z(e,U,y(1,v(null))),e[U][i]=!0),ae(e,i,r)):Z(e,i,r)},ce=function(e,t){h(e);var r=f(t),i=b(r).concat(fe(r));return q(i,(function(t){l&&!o(ue,r,t)||de(e,t,r[t])})),e},ue=function(e){var t=m(e),r=o(ee,this,t);return!(this===G&&u(re,t)&&!u(ie,t))&&(!(r||!u(this,t)||!u(re,t)||u(this,U)&&this[U][t])||r)},pe=function(e,t){var r=f(e),i=m(t);if(r!==G||!u(re,i)||u(ie,i)){var n=Q(r,i);return!n||!u(re,i)||u(r,U)&&r[U][i]||(n.enumerable=!0),n}},he=function(e){var t=X(f(e)),r=[];return q(t,(function(e){u(re,e)||u(F,e)||te(r,e)})),r},fe=function(e){var t=e===G,r=X(t?ie:f(e)),i=[];return q(r,(function(e){!u(re,e)||t&&!u(G,e)||te(i,re[e])})),i};d||(B(K=(W=function(){if(p(K,this))throw new J("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?g(arguments[0]):void 0,t=M(e),r=function(e){var i=void 0===this?n:this;i===G&&o(r,ie,e),u(i,U)&&u(i[U],t)&&(i[U][t]=!1);var s=y(1,e);try{ae(i,t,s)}catch(e){if(!(e instanceof V))throw e;se(i,t,s)}};return l&&oe&&ae(G,t,{configurable:!0,set:r}),le(t,e)})[j],"toString",(function(){return $(this).tag})),B(W,"withoutSetter",(function(e){return le(M(e),e)})),T.f=ue,k.f=de,E.f=ce,S.f=pe,w.f=_.f=he,x.f=fe,R.f=function(e){return le(D(e),e)},l&&(C(K,"description",{configurable:!0,get:function(){return $(this).description}}),a||B(G,"propertyIsEnumerable",ue,{unsafe:!0}))),i({global:!0,constructor:!0,wrap:!0,forced:!d,sham:!d},{Symbol:W}),q(b(ne),(function(e){P(e)})),i({target:L,stat:!0,forced:!d},{useSetter:function(){oe=!0},useSimple:function(){oe=!1}}),i({target:"Object",stat:!0,forced:!d,sham:!l},{create:function(e,t){return void 0===t?v(e):ce(v(e),t)},defineProperty:de,defineProperties:ce,getOwnPropertyDescriptor:pe}),i({target:"Object",stat:!0,forced:!d},{getOwnPropertyNames:he}),O(),z(W,L),F[U]=!0},75084:()=>{},13313:(e,t,r)=>{"use strict";var i=r(11091),n=r(85582),o=r(49724),s=r(90160),a=r(85816),l=r(84411),d=a("string-to-symbol-registry"),c=a("symbol-to-string-registry");i({target:"Symbol",stat:!0,forced:!l},{for:function(e){var t=s(e);if(o(d,t))return d[t];var r=n("Symbol")(t);return d[t]=r,c[r]=t,r}})},2596:(e,t,r)=>{"use strict";r(20366)("hasInstance")},5721:(e,t,r)=>{"use strict";r(20366)("isConcatSpreadable")},44954:(e,t,r)=>{"use strict";r(20366)("iterator")},94452:(e,t,r)=>{"use strict";r(23674),r(13313),r(10751),r(49721),r(55264)},10751:(e,t,r)=>{"use strict";var i=r(11091),n=r(49724),o=r(25594),s=r(4640),a=r(85816),l=r(84411),d=a("symbol-to-string-registry");i({target:"Symbol",stat:!0,forced:!l},{keyFor:function(e){if(!o(e))throw new TypeError(s(e)+" is not a symbol");if(n(d,e))return d[e]}})},73377:(e,t,r)=>{"use strict";r(20366)("matchAll")},44123:(e,t,r)=>{"use strict";r(20366)("match")},72230:(e,t,r)=>{"use strict";r(20366)("replace")},15344:(e,t,r)=>{"use strict";r(20366)("search")},51660:(e,t,r)=>{"use strict";r(20366)("species")},4610:(e,t,r)=>{"use strict";r(20366)("split")},33669:(e,t,r)=>{"use strict";var i=r(20366),n=r(83467);i("toPrimitive"),n()},44810:(e,t,r)=>{"use strict";var i=r(85582),n=r(20366),o=r(14840);n("toStringTag"),o(i("Symbol"),"Symbol")},93325:(e,t,r)=>{"use strict";r(20366)("unscopables")},20768:(e,t,r)=>{"use strict";var i=r(76264),n=r(74284).f,o=i("metadata"),s=Function.prototype;void 0===s[o]&&n(s,o,{value:null})},8549:(e,t,r)=>{"use strict";r(20366)("asyncDispose")},81697:(e,t,r)=>{"use strict";r(20366)("customMatcher")},87152:(e,t,r)=>{"use strict";r(20366)("dispose")},13939:(e,t,r)=>{"use strict";r(11091)({target:"Symbol",stat:!0},{isRegisteredSymbol:r(12595)})},63422:(e,t,r)=>{"use strict";r(11091)({target:"Symbol",stat:!0,name:"isRegisteredSymbol"},{isRegistered:r(12595)})},21785:(e,t,r)=>{"use strict";r(11091)({target:"Symbol",stat:!0,forced:!0},{isWellKnownSymbol:r(69197)})},70036:(e,t,r)=>{"use strict";r(11091)({target:"Symbol",stat:!0,name:"isWellKnownSymbol",forced:!0},{isWellKnown:r(69197)})},28703:(e,t,r)=>{"use strict";r(20366)("matcher")},86878:(e,t,r)=>{"use strict";r(20366)("metadataKey")},11372:(e,t,r)=>{"use strict";r(20366)("metadata")},84664:(e,t,r)=>{"use strict";r(20366)("observable")},59671:(e,t,r)=>{"use strict";r(20366)("patternMatch")},50359:(e,t,r)=>{"use strict";r(20366)("replaceAll")},60237:()=>{},12560:(e,t,r)=>{"use strict";r(99363);var i=r(19287),n=r(45951),o=r(14840),s=r(93742);for(var a in i)o(n[a],a),s[a]=s.Array},86450:(e,t,r)=>{"use strict";var i=r(93607);e.exports=i},18402:(e,t,r)=>{"use strict";var i=r(13531);e.exports=i},41969:(e,t,r)=>{"use strict";var i=r(22092);e.exports=i},33067:(e,t,r)=>{"use strict";var i=r(54712);r(12560),e.exports=i},50530:(e,t,r)=>{"use strict";var i=r(45837);e.exports=i},64055:(e,t,r)=>{"use strict";var i=r(60974);e.exports=i},24525:(e,t,r)=>{"use strict";var i=r(73948),n=r(49724),o=r(88280),s=r(41969);r(60237);var a=Array.prototype,l={DOMTokenList:!0,NodeList:!0};e.exports=function(e){var t=e.forEach;return e===a||o(a,e)&&t===a.forEach||n(l,i(e))?s:t}},77852:(e,t,r)=>{"use strict";var i=r(44507);e.exports=i},98894:(e,t,r)=>{"use strict";var i=r(39299);e.exports=i},33266:(e,t,r)=>{"use strict";var i=r(78685);e.exports=i},79528:(e,t,r)=>{"use strict";var i=r(28823);e.exports=i},6686:(e,t,r)=>{"use strict";var i=r(40303);e.exports=i},81086:(e,t,r)=>{"use strict";var i=r(12757);e.exports=i},93658:(e,t,r)=>{"use strict";var i=r(80149);e.exports=i},68251:(e,t,r)=>{"use strict";var i=r(21926);e.exports=i},91921:(e,t,r)=>{"use strict";var i=r(84326);e.exports=i},24139:(e,t,r)=>{"use strict";var i=r(83842);r(12560),e.exports=i},99211:(e,t)=>{"use strict";function r(e,t,r){var i;if(void 0===r&&(r={}),!t.codes){t.codes={};for(var n=0;n=8&&(a-=8,s[d++]=255&l>>a)}if(a>=t.bits||255&l<<8-a)throw new SyntaxError("Unexpected end of data");return s}function i(e,t,r){void 0===r&&(r={});for(var i=r.pad,n=void 0===i||i,o=(1<t.bits;)a-=t.bits,s+=t.chars[o&l>>a];if(a&&(s+=t.chars[o&l<{"use strict";r.r(t),r.d(t,{decode:()=>s,encode:()=>o});const i={},n={};["ҠҿԀԟڀڿݠޟ߀ߟကဟႠႿᄀᅟᆀᆟᇠሿበቿዠዿጠጿᎠᏟᐠᙟᚠᛟកសᠠᡟᣀᣟᦀᦟ᧠᧿ᨠᨿᯀᯟᰀᰟᴀᴟ⇠⇿⋀⋟⍀⏟␀␟─❟➀➿⠀⥿⦠⦿⨠⩟⪀⪿⫠⭟ⰀⰟⲀⳟⴀⴟⵀⵟ⺠⻟㇀㇟㐀䶟䷀龿ꀀꑿ꒠꒿ꔀꗿꙀꙟꚠꛟ꜀ꝟꞀꞟꡀꡟ","ƀƟɀʟ"].forEach(((e,t)=>{const r=[];e.match(/../gu).forEach((e=>{const t=e.codePointAt(0),i=e.codePointAt(1);for(let e=t;e<=i;e++)r.push(String.fromCodePoint(e))}));const o=15-8*t;i[o]=r,r.forEach(((e,t)=>{n[e]=[o,t]}))}));const o=e=>{const t=e.length;let r="",n=0,o=0;for(let s=0;s=0;e--){n=(n<<1)+(t>>e&1),o++,15===o&&(r+=i[o][n],n=0,o=0)}}if(0!==o){for(;!(o in i);)n=1+(n<<1),o++;r+=i[o][n]}return r},s=e=>{const t=e.length,r=new Uint8Array(Math.floor(15*t/8));let i=0,o=0,s=0;for(let a=0;a=0;e--){o=(o<<1)+(c>>e&1),s++,8===s&&(r[i]=o,i++,o=0,s=0)}}if(o!==(1<{"use strict";r.r(t),r.d(t,{CompactEncrypt:()=>wt,CompactSign:()=>St,EmbeddedJWK:()=>Dt,EncryptJWT:()=>It,FlattenedEncrypt:()=>it,FlattenedSign:()=>xt,GeneralEncrypt:()=>ot,GeneralSign:()=>Et,SignJWT:()=>Ct,UnsecuredJWT:()=>Gt,base64url:()=>n,calculateJwkThumbprint:()=>Ft,calculateJwkThumbprintUri:()=>Mt,compactDecrypt:()=>Je,compactVerify:()=>ct,createLocalJWKSet:()=>Nt,createRemoteJWKSet:()=>Ht,cryptoRuntime:()=>Xt,decodeJwt:()=>Jt,decodeProtectedHeader:()=>Vt,errors:()=>i,experimental_jwksCache:()=>$t,exportJWK:()=>tt,exportPKCS8:()=>et,exportSPKI:()=>Xe,flattenedDecrypt:()=>Ve,flattenedVerify:()=>dt,generalDecrypt:()=>Ye,generalVerify:()=>ut,generateKeyPair:()=>Qt,generateSecret:()=>Zt,importJWK:()=>ze,importPKCS8:()=>Oe,importSPKI:()=>Re,importX509:()=>Pe,jwksCache:()=>Lt,jwtDecrypt:()=>bt,jwtVerify:()=>vt});var i={};r.r(i),r.d(i,{JOSEAlgNotAllowed:()=>S,JOSEError:()=>w,JOSENotSupported:()=>k,JWEDecryptionFailed:()=>E,JWEInvalid:()=>T,JWKInvalid:()=>I,JWKSInvalid:()=>A,JWKSMultipleMatchingKeys:()=>M,JWKSNoMatchingKey:()=>F,JWKSTimeout:()=>D,JWSInvalid:()=>B,JWSSignatureVerificationFailed:()=>R,JWTClaimValidationFailed:()=>_,JWTExpired:()=>x,JWTInvalid:()=>C});var n={};r.r(n),r.d(n,{decode:()=>Kt,encode:()=>Wt});const o=crypto,s=e=>e instanceof CryptoKey,a=async(e,t)=>{const r=`SHA-${e.slice(-3)}`;return new Uint8Array(await o.subtle.digest(r,t))},l=new TextEncoder,d=new TextDecoder,c=2**32;function u(...e){const t=e.reduce(((e,{length:t})=>e+t),0),r=new Uint8Array(t);let i=0;for(const t of e)r.set(t,i),i+=t.length;return r}function p(e,t,r){if(t<0||t>=c)throw new RangeError(`value must be >= 0 and <= 4294967295. Received ${t}`);e.set([t>>>24,t>>>16,t>>>8,255&t],r)}function h(e){const t=Math.floor(e/c),r=e%c,i=new Uint8Array(8);return p(i,t,0),p(i,r,4),i}function f(e){const t=new Uint8Array(4);return p(t,e),t}function m(e){return u(f(e.length),e)}const g=e=>{let t=e;"string"==typeof t&&(t=l.encode(t));const r=[];for(let e=0;eg(e).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"),v=e=>{const t=atob(e),r=new Uint8Array(t.length);for(let e=0;e{let t=e;t instanceof Uint8Array&&(t=d.decode(t)),t=t.replace(/-/g,"+").replace(/_/g,"/").replace(/\s/g,"");try{return v(t)}catch{throw new TypeError("The input to be decoded is not correctly encoded.")}};class w extends Error{constructor(e,t){super(e,t),this.code="ERR_JOSE_GENERIC",this.name=this.constructor.name,Error.captureStackTrace?.(this,this.constructor)}}w.code="ERR_JOSE_GENERIC";class _ extends w{constructor(e,t,r="unspecified",i="unspecified"){super(e,{cause:{claim:r,reason:i,payload:t}}),this.code="ERR_JWT_CLAIM_VALIDATION_FAILED",this.claim=r,this.reason=i,this.payload=t}}_.code="ERR_JWT_CLAIM_VALIDATION_FAILED";class x extends w{constructor(e,t,r="unspecified",i="unspecified"){super(e,{cause:{claim:r,reason:i,payload:t}}),this.code="ERR_JWT_EXPIRED",this.claim=r,this.reason=i,this.payload=t}}x.code="ERR_JWT_EXPIRED";class S extends w{constructor(){super(...arguments),this.code="ERR_JOSE_ALG_NOT_ALLOWED"}}S.code="ERR_JOSE_ALG_NOT_ALLOWED";class k extends w{constructor(){super(...arguments),this.code="ERR_JOSE_NOT_SUPPORTED"}}k.code="ERR_JOSE_NOT_SUPPORTED";class E extends w{constructor(e="decryption operation failed",t){super(e,t),this.code="ERR_JWE_DECRYPTION_FAILED"}}E.code="ERR_JWE_DECRYPTION_FAILED";class T extends w{constructor(){super(...arguments),this.code="ERR_JWE_INVALID"}}T.code="ERR_JWE_INVALID";class B extends w{constructor(){super(...arguments),this.code="ERR_JWS_INVALID"}}B.code="ERR_JWS_INVALID";class C extends w{constructor(){super(...arguments),this.code="ERR_JWT_INVALID"}}C.code="ERR_JWT_INVALID";class I extends w{constructor(){super(...arguments),this.code="ERR_JWK_INVALID"}}I.code="ERR_JWK_INVALID";class A extends w{constructor(){super(...arguments),this.code="ERR_JWKS_INVALID"}}A.code="ERR_JWKS_INVALID";class F extends w{constructor(e="no applicable key found in the JSON Web Key Set",t){super(e,t),this.code="ERR_JWKS_NO_MATCHING_KEY"}}F.code="ERR_JWKS_NO_MATCHING_KEY";class M extends w{constructor(e="multiple matching keys found in the JSON Web Key Set",t){super(e,t),this.code="ERR_JWKS_MULTIPLE_MATCHING_KEYS"}}Symbol.asyncIterator,M.code="ERR_JWKS_MULTIPLE_MATCHING_KEYS";class D extends w{constructor(e="request timed out",t){super(e,t),this.code="ERR_JWKS_TIMEOUT"}}D.code="ERR_JWKS_TIMEOUT";class R extends w{constructor(e="signature verification failed",t){super(e,t),this.code="ERR_JWS_SIGNATURE_VERIFICATION_FAILED"}}R.code="ERR_JWS_SIGNATURE_VERIFICATION_FAILED";const P=o.getRandomValues.bind(o);function O(e){switch(e){case"A128GCM":case"A128GCMKW":case"A192GCM":case"A192GCMKW":case"A256GCM":case"A256GCMKW":return 96;case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return 128;default:throw new k(`Unsupported JWE Algorithm: ${e}`)}}const z=(e,t)=>{if(t.length<<3!==O(e))throw new T("Invalid Initialization Vector length")},N=(e,t)=>{const r=e.byteLength<<3;if(r!==t)throw new T(`Invalid Content Encryption Key length. Expected ${t} bits, got ${r} bits`)},q=(e,t)=>{if(!(e instanceof Uint8Array))throw new TypeError("First argument must be a buffer");if(!(t instanceof Uint8Array))throw new TypeError("Second argument must be a buffer");if(e.length!==t.length)throw new TypeError("Input buffers must have the same length");const r=e.length;let i=0,n=-1;for(;++ne.usages.includes(t)))){let e="CryptoKey does not support this operation, its usages must include ";if(t.length>2){const r=t.pop();e+=`one of ${t.join(", ")}, or ${r}.`}else 2===t.length?e+=`one of ${t[0]} or ${t[1]}.`:e+=`${t[0]}.`;throw new TypeError(e)}}function $(e,t,...r){switch(t){case"HS256":case"HS384":case"HS512":{if(!L(e.algorithm,"HMAC"))throw U("HMAC");const r=parseInt(t.slice(2),10);if(j(e.algorithm.hash)!==r)throw U(`SHA-${r}`,"algorithm.hash");break}case"RS256":case"RS384":case"RS512":{if(!L(e.algorithm,"RSASSA-PKCS1-v1_5"))throw U("RSASSA-PKCS1-v1_5");const r=parseInt(t.slice(2),10);if(j(e.algorithm.hash)!==r)throw U(`SHA-${r}`,"algorithm.hash");break}case"PS256":case"PS384":case"PS512":{if(!L(e.algorithm,"RSA-PSS"))throw U("RSA-PSS");const r=parseInt(t.slice(2),10);if(j(e.algorithm.hash)!==r)throw U(`SHA-${r}`,"algorithm.hash");break}case"EdDSA":if("Ed25519"!==e.algorithm.name&&"Ed448"!==e.algorithm.name)throw U("Ed25519 or Ed448");break;case"ES256":case"ES384":case"ES512":{if(!L(e.algorithm,"ECDSA"))throw U("ECDSA");const r=function(e){switch(e){case"ES256":return"P-256";case"ES384":return"P-384";case"ES512":return"P-521";default:throw new Error("unreachable")}}(t);if(e.algorithm.namedCurve!==r)throw U(r,"algorithm.namedCurve");break}default:throw new TypeError("CryptoKey does not support this operation")}H(e,r)}function G(e,t,...r){switch(t){case"A128GCM":case"A192GCM":case"A256GCM":{if(!L(e.algorithm,"AES-GCM"))throw U("AES-GCM");const r=parseInt(t.slice(1,4),10);if(e.algorithm.length!==r)throw U(r,"algorithm.length");break}case"A128KW":case"A192KW":case"A256KW":{if(!L(e.algorithm,"AES-KW"))throw U("AES-KW");const r=parseInt(t.slice(1,4),10);if(e.algorithm.length!==r)throw U(r,"algorithm.length");break}case"ECDH":switch(e.algorithm.name){case"ECDH":case"X25519":case"X448":break;default:throw U("ECDH, X25519, or X448")}break;case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":if(!L(e.algorithm,"PBKDF2"))throw U("PBKDF2");break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":{if(!L(e.algorithm,"RSA-OAEP"))throw U("RSA-OAEP");const r=parseInt(t.slice(9),10)||1;if(j(e.algorithm.hash)!==r)throw U(`SHA-${r}`,"algorithm.hash");break}default:throw new TypeError("CryptoKey does not support this operation")}H(e,r)}function W(e,t,...r){if((r=r.filter(Boolean)).length>2){const t=r.pop();e+=`one of type ${r.join(", ")}, or ${t}.`}else 2===r.length?e+=`one of type ${r[0]} or ${r[1]}.`:e+=`of type ${r[0]}.`;return null==t?e+=` Received ${t}`:"function"==typeof t&&t.name?e+=` Received function ${t.name}`:"object"==typeof t&&null!=t&&t.constructor?.name&&(e+=` Received an instance of ${t.constructor.name}`),e}const K=(e,...t)=>W("Key must be ",e,...t);function V(e,t,...r){return W(`Key for the ${e} algorithm must be `,t,...r)}const J=e=>!!s(e)||"KeyObject"===e?.[Symbol.toStringTag],Y=["CryptoKey"];const Q=async(e,t,r,i,n,a)=>{if(!(s(t)||t instanceof Uint8Array))throw new TypeError(K(t,...Y,"Uint8Array"));if(!i)throw new T("JWE Initialization Vector missing");if(!n)throw new T("JWE Authentication Tag missing");switch(z(e,i),e){case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return t instanceof Uint8Array&&N(t,parseInt(e.slice(-3),10)),async function(e,t,r,i,n,s){if(!(t instanceof Uint8Array))throw new TypeError(K(t,"Uint8Array"));const a=parseInt(e.slice(1,4),10),l=await o.subtle.importKey("raw",t.subarray(a>>3),"AES-CBC",!1,["decrypt"]),d=await o.subtle.importKey("raw",t.subarray(0,a>>3),{hash:"SHA-"+(a<<1),name:"HMAC"},!1,["sign"]),c=u(s,i,r,h(s.length<<3)),p=new Uint8Array((await o.subtle.sign("HMAC",d,c)).slice(0,a>>3));let f,m;try{f=q(n,p)}catch{}if(!f)throw new E;try{m=new Uint8Array(await o.subtle.decrypt({iv:i,name:"AES-CBC"},l,r))}catch{}if(!m)throw new E;return m}(e,t,r,i,n,a);case"A128GCM":case"A192GCM":case"A256GCM":return t instanceof Uint8Array&&N(t,parseInt(e.slice(1,4),10)),async function(e,t,r,i,n,s){let a;t instanceof Uint8Array?a=await o.subtle.importKey("raw",t,"AES-GCM",!1,["decrypt"]):(G(t,e,"decrypt"),a=t);try{return new Uint8Array(await o.subtle.decrypt({additionalData:s,iv:i,name:"AES-GCM",tagLength:128},a,u(r,n)))}catch{throw new E}}(e,t,r,i,n,a);default:throw new k("Unsupported JWE Content Encryption Algorithm")}},Z=(...e)=>{const t=e.filter(Boolean);if(0===t.length||1===t.length)return!0;let r;for(const e of t){const t=Object.keys(e);if(r&&0!==r.size)for(const e of t){if(r.has(e))return!1;r.add(e)}else r=new Set(t)}return!0};function X(e){if("object"!=typeof(t=e)||null===t||"[object Object]"!==Object.prototype.toString.call(e))return!1;var t;if(null===Object.getPrototypeOf(e))return!0;let r=e;for(;null!==Object.getPrototypeOf(r);)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r}const ee=[{hash:"SHA-256",name:"HMAC"},!0,["sign"]];function te(e,t){if(e.algorithm.length!==parseInt(t.slice(1,4),10))throw new TypeError(`Invalid key size for alg: ${t}`)}function re(e,t,r){if(s(e))return G(e,t,r),e;if(e instanceof Uint8Array)return o.subtle.importKey("raw",e,"AES-KW",!0,[r]);throw new TypeError(K(e,...Y,"Uint8Array"))}const ie=async(e,t,r)=>{const i=await re(t,e,"wrapKey");te(i,e);const n=await o.subtle.importKey("raw",r,...ee);return new Uint8Array(await o.subtle.wrapKey("raw",n,i,"AES-KW"))},ne=async(e,t,r)=>{const i=await re(t,e,"unwrapKey");te(i,e);const n=await o.subtle.unwrapKey("raw",r,i,"AES-KW",...ee);return new Uint8Array(await o.subtle.exportKey("raw",n))};async function oe(e,t,r,i,n=new Uint8Array(0),d=new Uint8Array(0)){if(!s(e))throw new TypeError(K(e,...Y));if(G(e,"ECDH"),!s(t))throw new TypeError(K(t,...Y));G(t,"ECDH","deriveBits");const c=u(m(l.encode(r)),m(n),m(d),f(i));let p;p="X25519"===e.algorithm.name?256:"X448"===e.algorithm.name?448:Math.ceil(parseInt(e.algorithm.namedCurve.substr(-3),10)/8)<<3;return async function(e,t,r){const i=Math.ceil((t>>3)/32),n=new Uint8Array(32*i);for(let t=0;t>3)}(new Uint8Array(await o.subtle.deriveBits({name:e.algorithm.name,public:e},t,p)),i,c)}function se(e){if(!s(e))throw new TypeError(K(e,...Y));return["P-256","P-384","P-521"].includes(e.algorithm.namedCurve)||"X25519"===e.algorithm.name||"X448"===e.algorithm.name}async function ae(e,t,r,i){!function(e){if(!(e instanceof Uint8Array)||e.length<8)throw new T("PBES2 Salt Input must be 8 or more octets")}(e);const n=function(e,t){return u(l.encode(e),new Uint8Array([0]),t)}(t,e),a=parseInt(t.slice(13,16),10),d={hash:`SHA-${t.slice(8,11)}`,iterations:r,name:"PBKDF2",salt:n},c={length:a,name:"AES-KW"},p=await function(e,t){if(e instanceof Uint8Array)return o.subtle.importKey("raw",e,"PBKDF2",!1,["deriveBits"]);if(s(e))return G(e,t,"deriveBits","deriveKey"),e;throw new TypeError(K(e,...Y,"Uint8Array"))}(i,t);if(p.usages.includes("deriveBits"))return new Uint8Array(await o.subtle.deriveBits(d,p,a));if(p.usages.includes("deriveKey"))return o.subtle.deriveKey(d,p,c,!1,["wrapKey","unwrapKey"]);throw new TypeError('PBKDF2 key "usages" must include "deriveBits" or "deriveKey"')}function le(e){switch(e){case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":return"RSA-OAEP";default:throw new k(`alg ${e} is not supported either by JOSE or your javascript runtime`)}}const de=(e,t)=>{if(e.startsWith("RS")||e.startsWith("PS")){const{modulusLength:r}=t.algorithm;if("number"!=typeof r||r<2048)throw new TypeError(`${e} requires key modulusLength to be 2048 bits or larger`)}};function ce(e){return X(e)&&"string"==typeof e.kty}const ue=async e=>{if(!e.alg)throw new TypeError('"alg" argument is required when "jwk.alg" is not present');const{algorithm:t,keyUsages:r}=function(e){let t,r;switch(e.kty){case"RSA":switch(e.alg){case"PS256":case"PS384":case"PS512":t={name:"RSA-PSS",hash:`SHA-${e.alg.slice(-3)}`},r=e.d?["sign"]:["verify"];break;case"RS256":case"RS384":case"RS512":t={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${e.alg.slice(-3)}`},r=e.d?["sign"]:["verify"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":t={name:"RSA-OAEP",hash:`SHA-${parseInt(e.alg.slice(-3),10)||1}`},r=e.d?["decrypt","unwrapKey"]:["encrypt","wrapKey"];break;default:throw new k('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"EC":switch(e.alg){case"ES256":t={name:"ECDSA",namedCurve:"P-256"},r=e.d?["sign"]:["verify"];break;case"ES384":t={name:"ECDSA",namedCurve:"P-384"},r=e.d?["sign"]:["verify"];break;case"ES512":t={name:"ECDSA",namedCurve:"P-521"},r=e.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":t={name:"ECDH",namedCurve:e.crv},r=e.d?["deriveBits"]:[];break;default:throw new k('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"OKP":switch(e.alg){case"EdDSA":t={name:e.crv},r=e.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":t={name:e.crv},r=e.d?["deriveBits"]:[];break;default:throw new k('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;default:throw new k('Invalid or unsupported JWK "kty" (Key Type) Parameter value')}return{algorithm:t,keyUsages:r}}(e),i=[t,e.ext??!1,e.key_ops??r],n={...e};return delete n.alg,delete n.use,o.subtle.importKey("jwk",n,...i)},pe=e=>b(e);let he,fe;const me=e=>"KeyObject"===e?.[Symbol.toStringTag],ge=async(e,t,r,i,n=!1)=>{let o=e.get(t);if(o?.[i])return o[i];const s=await ue({...r,alg:i});return n&&Object.freeze(t),o?o[i]=s:e.set(t,{[i]:s}),s},ye=(e,t)=>{if(me(e)){let r=e.export({format:"jwk"});return delete r.d,delete r.dp,delete r.dq,delete r.p,delete r.q,delete r.qi,r.k?pe(r.k):(fe||(fe=new WeakMap),ge(fe,e,r,t))}if(ce(e)){if(e.k)return b(e.k);fe||(fe=new WeakMap);return ge(fe,e,e,t,!0)}return e},ve=(e,t)=>{if(me(e)){let r=e.export({format:"jwk"});return r.k?pe(r.k):(he||(he=new WeakMap),ge(he,e,r,t))}if(ce(e)){if(e.k)return b(e.k);he||(he=new WeakMap);return ge(he,e,e,t,!0)}return e};function be(e){switch(e){case"A128GCM":return 128;case"A192GCM":return 192;case"A256GCM":case"A128CBC-HS256":return 256;case"A192CBC-HS384":return 384;case"A256CBC-HS512":return 512;default:throw new k(`Unsupported JWE Algorithm: ${e}`)}}const we=e=>P(new Uint8Array(be(e)>>3)),_e=(e,t)=>`-----BEGIN ${t}-----\n${(e.match(/.{1,64}/g)||[]).join("\n")}\n-----END ${t}-----`,xe=async(e,t,r)=>{if(!s(r))throw new TypeError(K(r,...Y));if(!r.extractable)throw new TypeError("CryptoKey is not extractable");if(r.type!==e)throw new TypeError(`key is not a ${e} key`);return _e(g(new Uint8Array(await o.subtle.exportKey(t,r))),`${e.toUpperCase()} KEY`)},Se=e=>xe("public","spki",e),ke=e=>xe("private","pkcs8",e),Ee=(e,t,r=0)=>{0===r&&(t.unshift(t.length),t.unshift(6));const i=e.indexOf(t[0],r);if(-1===i)return!1;const n=e.subarray(i,i+t.length);return n.length===t.length&&(n.every(((e,r)=>e===t[r]))||Ee(e,t,i+1))},Te=e=>{switch(!0){case Ee(e,[42,134,72,206,61,3,1,7]):return"P-256";case Ee(e,[43,129,4,0,34]):return"P-384";case Ee(e,[43,129,4,0,35]):return"P-521";case Ee(e,[43,101,110]):return"X25519";case Ee(e,[43,101,111]):return"X448";case Ee(e,[43,101,112]):return"Ed25519";case Ee(e,[43,101,113]):return"Ed448";default:throw new k("Invalid or unsupported EC Key Curve or OKP Key Sub Type")}},Be=async(e,t,r,i,n)=>{let s,a;const l=new Uint8Array(atob(r.replace(e,"")).split("").map((e=>e.charCodeAt(0)))),d="spki"===t;switch(i){case"PS256":case"PS384":case"PS512":s={name:"RSA-PSS",hash:`SHA-${i.slice(-3)}`},a=d?["verify"]:["sign"];break;case"RS256":case"RS384":case"RS512":s={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${i.slice(-3)}`},a=d?["verify"]:["sign"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":s={name:"RSA-OAEP",hash:`SHA-${parseInt(i.slice(-3),10)||1}`},a=d?["encrypt","wrapKey"]:["decrypt","unwrapKey"];break;case"ES256":s={name:"ECDSA",namedCurve:"P-256"},a=d?["verify"]:["sign"];break;case"ES384":s={name:"ECDSA",namedCurve:"P-384"},a=d?["verify"]:["sign"];break;case"ES512":s={name:"ECDSA",namedCurve:"P-521"},a=d?["verify"]:["sign"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{const e=Te(l);s=e.startsWith("P-")?{name:"ECDH",namedCurve:e}:{name:e},a=d?[]:["deriveBits"];break}case"EdDSA":s={name:Te(l)},a=d?["verify"]:["sign"];break;default:throw new k('Invalid or unsupported "alg" (Algorithm) value')}return o.subtle.importKey(t,l,s,n?.extractable??!1,a)},Ce=(e,t,r)=>Be(/(?:-----(?:BEGIN|END) PRIVATE KEY-----|\s)/g,"pkcs8",e,t,r),Ie=(e,t,r)=>Be(/(?:-----(?:BEGIN|END) PUBLIC KEY-----|\s)/g,"spki",e,t,r);function Ae(e){const t=[];let r=0;for(;r=128;)r=128*r+e[t]-128,t++;r=128*r+e[t]-128,t++}let i=0;if(e[t]<128)i=e[t],t++;else{if(128===i){for(i=0;0!==e[t+i]||0!==e[t+i+1];){if(i>e.byteLength)throw new TypeError("invalid indefinite form length");i++}const r=t+i+2;return{byteLength:r,contents:e.subarray(t,t+i),raw:e.subarray(0,r)}}{const r=127&e[t];t++,i=0;for(let n=0;n{let i;try{i=Me(e)}catch(e){throw new TypeError("Failed to parse the X.509 certificate",{cause:e})}return Ie(i,t,r)};async function Re(e,t,r){if("string"!=typeof e||0!==e.indexOf("-----BEGIN PUBLIC KEY-----"))throw new TypeError('"spki" must be SPKI formatted string');return Ie(e,t,r)}async function Pe(e,t,r){if("string"!=typeof e||0!==e.indexOf("-----BEGIN CERTIFICATE-----"))throw new TypeError('"x509" must be X.509 formatted string');return De(e,t,r)}async function Oe(e,t,r){if("string"!=typeof e||0!==e.indexOf("-----BEGIN PRIVATE KEY-----"))throw new TypeError('"pkcs8" must be PKCS#8 formatted string');return Ce(e,t,r)}async function ze(e,t){if(!X(e))throw new TypeError("JWK must be an object");switch(t||(t=e.alg),e.kty){case"oct":if("string"!=typeof e.k||!e.k)throw new TypeError('missing "k" (Key Value) Parameter value');return b(e.k);case"RSA":if(void 0!==e.oth)throw new k('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');case"EC":case"OKP":return ue({...e,alg:t});default:throw new k('Unsupported "kty" (Key Type) Parameter value')}}const Ne=e=>e?.[Symbol.toStringTag],qe=(e,t,r)=>{if(void 0!==t.use&&"sig"!==t.use)throw new TypeError("Invalid key for this operation, when present its use must be sig");if(void 0!==t.key_ops&&!0!==t.key_ops.includes?.(r))throw new TypeError(`Invalid key for this operation, when present its key_ops must include ${r}`);if(void 0!==t.alg&&t.alg!==e)throw new TypeError(`Invalid key for this operation, when present its alg must be ${e}`);return!0},Ue=(e,t,r,i)=>{if(!(t instanceof Uint8Array)){if(i&&ce(t)){if(function(e){return ce(e)&&"oct"===e.kty&&"string"==typeof e.k}(t)&&qe(e,t,r))return;throw new TypeError('JSON Web Key for symmetric algorithms must have JWK "kty" (Key Type) equal to "oct" and the JWK "k" (Key Value) present')}if(!J(t))throw new TypeError(V(e,t,...Y,"Uint8Array",i?"JSON Web Key":null));if("secret"!==t.type)throw new TypeError(`${Ne(t)} instances for symmetric algorithms must be of type "secret"`)}};function Le(e,t,r,i){t.startsWith("HS")||"dir"===t||t.startsWith("PBES2")||/^A\d{3}(?:GCM)?KW$/.test(t)?Ue(t,r,i,e):((e,t,r,i)=>{if(i&&ce(t))switch(r){case"sign":if(function(e){return"oct"!==e.kty&&"string"==typeof e.d}(t)&&qe(e,t,r))return;throw new TypeError("JSON Web Key for this operation be a private JWK");case"verify":if(function(e){return"oct"!==e.kty&&void 0===e.d}(t)&&qe(e,t,r))return;throw new TypeError("JSON Web Key for this operation be a public JWK")}if(!J(t))throw new TypeError(V(e,t,...Y,i?"JSON Web Key":null));if("secret"===t.type)throw new TypeError(`${Ne(t)} instances for asymmetric algorithms must not be of type "secret"`);if("sign"===r&&"public"===t.type)throw new TypeError(`${Ne(t)} instances for asymmetric algorithm signing must be of type "private"`);if("decrypt"===r&&"public"===t.type)throw new TypeError(`${Ne(t)} instances for asymmetric algorithm decryption must be of type "private"`);if(t.algorithm&&"verify"===r&&"private"===t.type)throw new TypeError(`${Ne(t)} instances for asymmetric algorithm verifying must be of type "public"`);if(t.algorithm&&"encrypt"===r&&"private"===t.type)throw new TypeError(`${Ne(t)} instances for asymmetric algorithm encryption must be of type "public"`)})(t,r,i,e)}const je=Le.bind(void 0,!1),He=Le.bind(void 0,!0);const $e=async(e,t,r,i,n)=>{if(!(s(r)||r instanceof Uint8Array))throw new TypeError(K(r,...Y,"Uint8Array"));switch(i?z(e,i):i=P(new Uint8Array(O(e)>>3)),e){case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return r instanceof Uint8Array&&N(r,parseInt(e.slice(-3),10)),async function(e,t,r,i,n){if(!(r instanceof Uint8Array))throw new TypeError(K(r,"Uint8Array"));const s=parseInt(e.slice(1,4),10),a=await o.subtle.importKey("raw",r.subarray(s>>3),"AES-CBC",!1,["encrypt"]),l=await o.subtle.importKey("raw",r.subarray(0,s>>3),{hash:"SHA-"+(s<<1),name:"HMAC"},!1,["sign"]),d=new Uint8Array(await o.subtle.encrypt({iv:i,name:"AES-CBC"},a,t)),c=u(n,i,d,h(n.length<<3));return{ciphertext:d,tag:new Uint8Array((await o.subtle.sign("HMAC",l,c)).slice(0,s>>3)),iv:i}}(e,t,r,i,n);case"A128GCM":case"A192GCM":case"A256GCM":return r instanceof Uint8Array&&N(r,parseInt(e.slice(1,4),10)),async function(e,t,r,i,n){let s;r instanceof Uint8Array?s=await o.subtle.importKey("raw",r,"AES-GCM",!1,["encrypt"]):(G(r,e,"encrypt"),s=r);const a=new Uint8Array(await o.subtle.encrypt({additionalData:n,iv:i,name:"AES-GCM",tagLength:128},s,t)),l=a.slice(-16);return{ciphertext:a.slice(0,-16),tag:l,iv:i}}(e,t,r,i,n);default:throw new k("Unsupported JWE Content Encryption Algorithm")}};const Ge=async function(e,t,r,i,n){switch(je(e,t,"decrypt"),t=await(ve?.(t,e))||t,e){case"dir":if(void 0!==r)throw new T("Encountered unexpected JWE Encrypted Key");return t;case"ECDH-ES":if(void 0!==r)throw new T("Encountered unexpected JWE Encrypted Key");case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{if(!X(i.epk))throw new T('JOSE Header "epk" (Ephemeral Public Key) missing or invalid');if(!se(t))throw new k("ECDH with the provided key is not allowed or not supported by your javascript runtime");const n=await ze(i.epk,e);let o,s;if(void 0!==i.apu){if("string"!=typeof i.apu)throw new T('JOSE Header "apu" (Agreement PartyUInfo) invalid');try{o=b(i.apu)}catch{throw new T("Failed to base64url decode the apu")}}if(void 0!==i.apv){if("string"!=typeof i.apv)throw new T('JOSE Header "apv" (Agreement PartyVInfo) invalid');try{s=b(i.apv)}catch{throw new T("Failed to base64url decode the apv")}}const a=await oe(n,t,"ECDH-ES"===e?i.enc:e,"ECDH-ES"===e?be(i.enc):parseInt(e.slice(-5,-2),10),o,s);if("ECDH-ES"===e)return a;if(void 0===r)throw new T("JWE Encrypted Key missing");return ne(e.slice(-6),a,r)}case"RSA1_5":case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":if(void 0===r)throw new T("JWE Encrypted Key missing");return(async(e,t,r)=>{if(!s(t))throw new TypeError(K(t,...Y));if(G(t,e,"decrypt","unwrapKey"),de(e,t),t.usages.includes("decrypt"))return new Uint8Array(await o.subtle.decrypt(le(e),t,r));if(t.usages.includes("unwrapKey")){const i=await o.subtle.unwrapKey("raw",r,t,le(e),...ee);return new Uint8Array(await o.subtle.exportKey("raw",i))}throw new TypeError('RSA-OAEP key "usages" must include "decrypt" or "unwrapKey" for this operation')})(e,t,r);case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":{if(void 0===r)throw new T("JWE Encrypted Key missing");if("number"!=typeof i.p2c)throw new T('JOSE Header "p2c" (PBES2 Count) missing or invalid');const o=n?.maxPBES2Count||1e4;if(i.p2c>o)throw new T('JOSE Header "p2c" (PBES2 Count) out is of acceptable bounds');if("string"!=typeof i.p2s)throw new T('JOSE Header "p2s" (PBES2 Salt) missing or invalid');let s;try{s=b(i.p2s)}catch{throw new T("Failed to base64url decode the p2s")}return(async(e,t,r,i,n)=>{const o=await ae(n,e,i,t);return ne(e.slice(-6),o,r)})(e,t,r,i.p2c,s)}case"A128KW":case"A192KW":case"A256KW":if(void 0===r)throw new T("JWE Encrypted Key missing");return ne(e,t,r);case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":{if(void 0===r)throw new T("JWE Encrypted Key missing");if("string"!=typeof i.iv)throw new T('JOSE Header "iv" (Initialization Vector) missing or invalid');if("string"!=typeof i.tag)throw new T('JOSE Header "tag" (Authentication Tag) missing or invalid');let n,o;try{n=b(i.iv)}catch{throw new T("Failed to base64url decode the iv")}try{o=b(i.tag)}catch{throw new T("Failed to base64url decode the tag")}return async function(e,t,r,i,n){const o=e.slice(0,7);return Q(o,t,r,i,n,new Uint8Array(0))}(e,t,r,n,o)}default:throw new k('Invalid or unsupported "alg" (JWE Algorithm) header value')}};const We=function(e,t,r,i,n){if(void 0!==n.crit&&void 0===i?.crit)throw new e('"crit" (Critical) Header Parameter MUST be integrity protected');if(!i||void 0===i.crit)return new Set;if(!Array.isArray(i.crit)||0===i.crit.length||i.crit.some((e=>"string"!=typeof e||0===e.length)))throw new e('"crit" (Critical) Header Parameter MUST be an array of non-empty strings when present');let o;o=void 0!==r?new Map([...Object.entries(r),...t.entries()]):t;for(const t of i.crit){if(!o.has(t))throw new k(`Extension Header Parameter "${t}" is not recognized`);if(void 0===n[t])throw new e(`Extension Header Parameter "${t}" is missing`);if(o.get(t)&&void 0===i[t])throw new e(`Extension Header Parameter "${t}" MUST be integrity protected`)}return new Set(i.crit)},Ke=(e,t)=>{if(void 0!==t&&(!Array.isArray(t)||t.some((e=>"string"!=typeof e))))throw new TypeError(`"${e}" option must be an array of strings`);if(t)return new Set(t)};async function Ve(e,t,r){if(!X(e))throw new T("Flattened JWE must be an object");if(void 0===e.protected&&void 0===e.header&&void 0===e.unprotected)throw new T("JOSE Header missing");if(void 0!==e.iv&&"string"!=typeof e.iv)throw new T("JWE Initialization Vector incorrect type");if("string"!=typeof e.ciphertext)throw new T("JWE Ciphertext missing or incorrect type");if(void 0!==e.tag&&"string"!=typeof e.tag)throw new T("JWE Authentication Tag incorrect type");if(void 0!==e.protected&&"string"!=typeof e.protected)throw new T("JWE Protected Header incorrect type");if(void 0!==e.encrypted_key&&"string"!=typeof e.encrypted_key)throw new T("JWE Encrypted Key incorrect type");if(void 0!==e.aad&&"string"!=typeof e.aad)throw new T("JWE AAD incorrect type");if(void 0!==e.header&&!X(e.header))throw new T("JWE Shared Unprotected Header incorrect type");if(void 0!==e.unprotected&&!X(e.unprotected))throw new T("JWE Per-Recipient Unprotected Header incorrect type");let i;if(e.protected)try{const t=b(e.protected);i=JSON.parse(d.decode(t))}catch{throw new T("JWE Protected Header is invalid")}if(!Z(i,e.header,e.unprotected))throw new T("JWE Protected, JWE Unprotected Header, and JWE Per-Recipient Unprotected Header Parameter names must be disjoint");const n={...i,...e.header,...e.unprotected};if(We(T,new Map,r?.crit,i,n),void 0!==n.zip)throw new k('JWE "zip" (Compression Algorithm) Header Parameter is not supported.');const{alg:o,enc:s}=n;if("string"!=typeof o||!o)throw new T("missing JWE Algorithm (alg) in JWE Header");if("string"!=typeof s||!s)throw new T("missing JWE Encryption Algorithm (enc) in JWE Header");const a=r&&Ke("keyManagementAlgorithms",r.keyManagementAlgorithms),c=r&&Ke("contentEncryptionAlgorithms",r.contentEncryptionAlgorithms);if(a&&!a.has(o)||!a&&o.startsWith("PBES2"))throw new S('"alg" (Algorithm) Header Parameter value not allowed');if(c&&!c.has(s))throw new S('"enc" (Encryption Algorithm) Header Parameter value not allowed');let p;if(void 0!==e.encrypted_key)try{p=b(e.encrypted_key)}catch{throw new T("Failed to base64url decode the encrypted_key")}let h,f,m,g=!1;"function"==typeof t&&(t=await t(i,e),g=!0);try{h=await Ge(o,t,p,n,r)}catch(e){if(e instanceof TypeError||e instanceof T||e instanceof k)throw e;h=we(s)}if(void 0!==e.iv)try{f=b(e.iv)}catch{throw new T("Failed to base64url decode the iv")}if(void 0!==e.tag)try{m=b(e.tag)}catch{throw new T("Failed to base64url decode the tag")}const y=l.encode(e.protected??"");let v,w;v=void 0!==e.aad?u(y,l.encode("."),l.encode(e.aad)):y;try{w=b(e.ciphertext)}catch{throw new T("Failed to base64url decode the ciphertext")}const _={plaintext:await Q(s,h,w,f,m,v)};if(void 0!==e.protected&&(_.protectedHeader=i),void 0!==e.aad)try{_.additionalAuthenticatedData=b(e.aad)}catch{throw new T("Failed to base64url decode the aad")}return void 0!==e.unprotected&&(_.sharedUnprotectedHeader=e.unprotected),void 0!==e.header&&(_.unprotectedHeader=e.header),g?{..._,key:t}:_}async function Je(e,t,r){if(e instanceof Uint8Array&&(e=d.decode(e)),"string"!=typeof e)throw new T("Compact JWE must be a string or Uint8Array");const{0:i,1:n,2:o,3:s,4:a,length:l}=e.split(".");if(5!==l)throw new T("Invalid Compact JWE");const c=await Ve({ciphertext:s,iv:o||void 0,protected:i,tag:a||void 0,encrypted_key:n||void 0},t,r),u={plaintext:c.plaintext,protectedHeader:c.protectedHeader};return"function"==typeof t?{...u,key:c.key}:u}async function Ye(e,t,r){if(!X(e))throw new T("General JWE must be an object");if(!Array.isArray(e.recipients)||!e.recipients.every(X))throw new T("JWE Recipients missing or incorrect type");if(!e.recipients.length)throw new T("JWE Recipients has no members");for(const i of e.recipients)try{return await Ve({aad:e.aad,ciphertext:e.ciphertext,encrypted_key:i.encrypted_key,header:i.header,iv:e.iv,protected:e.protected,tag:e.tag,unprotected:e.unprotected},t,r)}catch{}throw new E}const Qe=Symbol(),Ze=async e=>{if(e instanceof Uint8Array)return{kty:"oct",k:y(e)};if(!s(e))throw new TypeError(K(e,...Y,"Uint8Array"));if(!e.extractable)throw new TypeError("non-extractable CryptoKey cannot be exported as a JWK");const{ext:t,key_ops:r,alg:i,use:n,...a}=await o.subtle.exportKey("jwk",e);return a};async function Xe(e){return Se(e)}async function et(e){return ke(e)}async function tt(e){return Ze(e)}const rt=async function(e,t,r,i,n={}){let a,l,d;switch(je(e,r,"encrypt"),r=await(ye?.(r,e))||r,e){case"dir":d=r;break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{if(!se(r))throw new k("ECDH with the provided key is not allowed or not supported by your javascript runtime");const{apu:c,apv:u}=n;let{epk:p}=n;p||(p=(await async function(e){if(!s(e))throw new TypeError(K(e,...Y));return o.subtle.generateKey(e.algorithm,!0,["deriveBits"])}(r)).privateKey);const{x:h,y:f,crv:m,kty:g}=await tt(p),v=await oe(r,p,"ECDH-ES"===e?t:e,"ECDH-ES"===e?be(t):parseInt(e.slice(-5,-2),10),c,u);if(l={epk:{x:h,crv:m,kty:g}},"EC"===g&&(l.epk.y=f),c&&(l.apu=y(c)),u&&(l.apv=y(u)),"ECDH-ES"===e){d=v;break}d=i||we(t);const b=e.slice(-6);a=await ie(b,v,d);break}case"RSA1_5":case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":d=i||we(t),a=await(async(e,t,r)=>{if(!s(t))throw new TypeError(K(t,...Y));if(G(t,e,"encrypt","wrapKey"),de(e,t),t.usages.includes("encrypt"))return new Uint8Array(await o.subtle.encrypt(le(e),t,r));if(t.usages.includes("wrapKey")){const i=await o.subtle.importKey("raw",r,...ee);return new Uint8Array(await o.subtle.wrapKey("raw",i,t,le(e)))}throw new TypeError('RSA-OAEP key "usages" must include "encrypt" or "wrapKey" for this operation')})(e,r,d);break;case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":{d=i||we(t);const{p2c:o,p2s:s}=n;({encryptedKey:a,...l}=await(async(e,t,r,i=2048,n=P(new Uint8Array(16)))=>{const o=await ae(n,e,i,t);return{encryptedKey:await ie(e.slice(-6),o,r),p2c:i,p2s:y(n)}})(e,r,d,o,s));break}case"A128KW":case"A192KW":case"A256KW":d=i||we(t),a=await ie(e,r,d);break;case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":{d=i||we(t);const{iv:o}=n;({encryptedKey:a,...l}=await async function(e,t,r,i){const n=e.slice(0,7),o=await $e(n,r,t,i,new Uint8Array(0));return{encryptedKey:o.ciphertext,iv:y(o.iv),tag:y(o.tag)}}(e,r,d,o));break}default:throw new k('Invalid or unsupported "alg" (JWE Algorithm) header value')}return{cek:d,encryptedKey:a,parameters:l}};class it{constructor(e){if(!(e instanceof Uint8Array))throw new TypeError("plaintext must be an instance of Uint8Array");this._plaintext=e}setKeyManagementParameters(e){if(this._keyManagementParameters)throw new TypeError("setKeyManagementParameters can only be called once");return this._keyManagementParameters=e,this}setProtectedHeader(e){if(this._protectedHeader)throw new TypeError("setProtectedHeader can only be called once");return this._protectedHeader=e,this}setSharedUnprotectedHeader(e){if(this._sharedUnprotectedHeader)throw new TypeError("setSharedUnprotectedHeader can only be called once");return this._sharedUnprotectedHeader=e,this}setUnprotectedHeader(e){if(this._unprotectedHeader)throw new TypeError("setUnprotectedHeader can only be called once");return this._unprotectedHeader=e,this}setAdditionalAuthenticatedData(e){return this._aad=e,this}setContentEncryptionKey(e){if(this._cek)throw new TypeError("setContentEncryptionKey can only be called once");return this._cek=e,this}setInitializationVector(e){if(this._iv)throw new TypeError("setInitializationVector can only be called once");return this._iv=e,this}async encrypt(e,t){if(!this._protectedHeader&&!this._unprotectedHeader&&!this._sharedUnprotectedHeader)throw new T("either setProtectedHeader, setUnprotectedHeader, or sharedUnprotectedHeader must be called before #encrypt()");if(!Z(this._protectedHeader,this._unprotectedHeader,this._sharedUnprotectedHeader))throw new T("JWE Protected, JWE Shared Unprotected and JWE Per-Recipient Header Parameter names must be disjoint");const r={...this._protectedHeader,...this._unprotectedHeader,...this._sharedUnprotectedHeader};if(We(T,new Map,t?.crit,this._protectedHeader,r),void 0!==r.zip)throw new k('JWE "zip" (Compression Algorithm) Header Parameter is not supported.');const{alg:i,enc:n}=r;if("string"!=typeof i||!i)throw new T('JWE "alg" (Algorithm) Header Parameter missing or invalid');if("string"!=typeof n||!n)throw new T('JWE "enc" (Encryption Algorithm) Header Parameter missing or invalid');let o,s,a,c,p;if(this._cek&&("dir"===i||"ECDH-ES"===i))throw new TypeError(`setContentEncryptionKey cannot be called with JWE "alg" (Algorithm) Header ${i}`);{let r;({cek:s,encryptedKey:o,parameters:r}=await rt(i,n,e,this._cek,this._keyManagementParameters)),r&&(t&&Qe in t?this._unprotectedHeader?this._unprotectedHeader={...this._unprotectedHeader,...r}:this.setUnprotectedHeader(r):this._protectedHeader?this._protectedHeader={...this._protectedHeader,...r}:this.setProtectedHeader(r))}c=this._protectedHeader?l.encode(y(JSON.stringify(this._protectedHeader))):l.encode(""),this._aad?(p=y(this._aad),a=u(c,l.encode("."),l.encode(p))):a=c;const{ciphertext:h,tag:f,iv:m}=await $e(n,this._plaintext,s,this._iv,a),g={ciphertext:y(h)};return m&&(g.iv=y(m)),f&&(g.tag=y(f)),o&&(g.encrypted_key=y(o)),p&&(g.aad=p),this._protectedHeader&&(g.protected=d.decode(c)),this._sharedUnprotectedHeader&&(g.unprotected=this._sharedUnprotectedHeader),this._unprotectedHeader&&(g.header=this._unprotectedHeader),g}}class nt{constructor(e,t,r){this.parent=e,this.key=t,this.options=r}setUnprotectedHeader(e){if(this.unprotectedHeader)throw new TypeError("setUnprotectedHeader can only be called once");return this.unprotectedHeader=e,this}addRecipient(...e){return this.parent.addRecipient(...e)}encrypt(...e){return this.parent.encrypt(...e)}done(){return this.parent}}class ot{constructor(e){this._recipients=[],this._plaintext=e}addRecipient(e,t){const r=new nt(this,e,{crit:t?.crit});return this._recipients.push(r),r}setProtectedHeader(e){if(this._protectedHeader)throw new TypeError("setProtectedHeader can only be called once");return this._protectedHeader=e,this}setSharedUnprotectedHeader(e){if(this._unprotectedHeader)throw new TypeError("setSharedUnprotectedHeader can only be called once");return this._unprotectedHeader=e,this}setAdditionalAuthenticatedData(e){return this._aad=e,this}async encrypt(){if(!this._recipients.length)throw new T("at least one recipient must be added");if(1===this._recipients.length){const[e]=this._recipients,t=await new it(this._plaintext).setAdditionalAuthenticatedData(this._aad).setProtectedHeader(this._protectedHeader).setSharedUnprotectedHeader(this._unprotectedHeader).setUnprotectedHeader(e.unprotectedHeader).encrypt(e.key,{...e.options}),r={ciphertext:t.ciphertext,iv:t.iv,recipients:[{}],tag:t.tag};return t.aad&&(r.aad=t.aad),t.protected&&(r.protected=t.protected),t.unprotected&&(r.unprotected=t.unprotected),t.encrypted_key&&(r.recipients[0].encrypted_key=t.encrypted_key),t.header&&(r.recipients[0].header=t.header),r}let e;for(let t=0;t>3};case"RS256":case"RS384":case"RS512":return{hash:r,name:"RSASSA-PKCS1-v1_5"};case"ES256":case"ES384":case"ES512":return{hash:r,name:"ECDSA",namedCurve:t.namedCurve};case"EdDSA":return{name:t.name};default:throw new k(`alg ${e} is not supported either by JOSE or your javascript runtime`)}}async function at(e,t,r){if("sign"===r&&(t=await ve(t,e)),"verify"===r&&(t=await ye(t,e)),s(t))return $(t,e,r),t;if(t instanceof Uint8Array){if(!e.startsWith("HS"))throw new TypeError(K(t,...Y));return o.subtle.importKey("raw",t,{hash:`SHA-${e.slice(-3)}`,name:"HMAC"},!1,[r])}throw new TypeError(K(t,...Y,"Uint8Array","JSON Web Key"))}const lt=async(e,t,r,i)=>{const n=await at(e,t,"verify");de(e,n);const s=st(e,n.algorithm);try{return await o.subtle.verify(s,n,r,i)}catch{return!1}};async function dt(e,t,r){if(!X(e))throw new B("Flattened JWS must be an object");if(void 0===e.protected&&void 0===e.header)throw new B('Flattened JWS must have either of the "protected" or "header" members');if(void 0!==e.protected&&"string"!=typeof e.protected)throw new B("JWS Protected Header incorrect type");if(void 0===e.payload)throw new B("JWS Payload missing");if("string"!=typeof e.signature)throw new B("JWS Signature missing or incorrect type");if(void 0!==e.header&&!X(e.header))throw new B("JWS Unprotected Header incorrect type");let i={};if(e.protected)try{const t=b(e.protected);i=JSON.parse(d.decode(t))}catch{throw new B("JWS Protected Header is invalid")}if(!Z(i,e.header))throw new B("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");const n={...i,...e.header};let o=!0;if(We(B,new Map([["b64",!0]]),r?.crit,i,n).has("b64")&&(o=i.b64,"boolean"!=typeof o))throw new B('The "b64" (base64url-encode payload) Header Parameter must be a boolean');const{alg:s}=n;if("string"!=typeof s||!s)throw new B('JWS "alg" (Algorithm) Header Parameter missing or invalid');const a=r&&Ke("algorithms",r.algorithms);if(a&&!a.has(s))throw new S('"alg" (Algorithm) Header Parameter value not allowed');if(o){if("string"!=typeof e.payload)throw new B("JWS Payload must be a string")}else if("string"!=typeof e.payload&&!(e.payload instanceof Uint8Array))throw new B("JWS Payload must be a string or an Uint8Array instance");let c=!1;"function"==typeof t?(t=await t(i,e),c=!0,He(s,t,"verify"),ce(t)&&(t=await ze(t,s))):He(s,t,"verify");const p=u(l.encode(e.protected??""),l.encode("."),"string"==typeof e.payload?l.encode(e.payload):e.payload);let h;try{h=b(e.signature)}catch{throw new B("Failed to base64url decode the signature")}if(!await lt(s,t,h,p))throw new R;let f;if(o)try{f=b(e.payload)}catch{throw new B("Failed to base64url decode the payload")}else f="string"==typeof e.payload?l.encode(e.payload):e.payload;const m={payload:f};return void 0!==e.protected&&(m.protectedHeader=i),void 0!==e.header&&(m.unprotectedHeader=e.header),c?{...m,key:t}:m}async function ct(e,t,r){if(e instanceof Uint8Array&&(e=d.decode(e)),"string"!=typeof e)throw new B("Compact JWS must be a string or Uint8Array");const{0:i,1:n,2:o,length:s}=e.split(".");if(3!==s)throw new B("Invalid Compact JWS");const a=await dt({payload:n,protected:i,signature:o},t,r),l={payload:a.payload,protectedHeader:a.protectedHeader};return"function"==typeof t?{...l,key:a.key}:l}async function ut(e,t,r){if(!X(e))throw new B("General JWS must be an object");if(!Array.isArray(e.signatures)||!e.signatures.every(X))throw new B("JWS Signatures missing or incorrect type");for(const i of e.signatures)try{return await dt({header:i.header,payload:e.payload,protected:i.protected,signature:i.signature},t,r)}catch{}throw new R}const pt=e=>Math.floor(e.getTime()/1e3),ht=86400,ft=/^(\+|\-)? ?(\d+|\d+\.\d+) ?(seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)(?: (ago|from now))?$/i,mt=e=>{const t=ft.exec(e);if(!t||t[4]&&t[1])throw new TypeError("Invalid time period format");const r=parseFloat(t[2]);let i;switch(t[3].toLowerCase()){case"sec":case"secs":case"second":case"seconds":case"s":i=Math.round(r);break;case"minute":case"minutes":case"min":case"mins":case"m":i=Math.round(60*r);break;case"hour":case"hours":case"hr":case"hrs":case"h":i=Math.round(3600*r);break;case"day":case"days":case"d":i=Math.round(r*ht);break;case"week":case"weeks":case"w":i=Math.round(604800*r);break;default:i=Math.round(31557600*r)}return"-"===t[1]||"ago"===t[4]?-i:i},gt=e=>e.toLowerCase().replace(/^application\//,""),yt=(e,t,r={})=>{let i;try{i=JSON.parse(d.decode(t))}catch{}if(!X(i))throw new C("JWT Claims Set must be a top-level JSON object");const{typ:n}=r;if(n&&("string"!=typeof e.typ||gt(e.typ)!==gt(n)))throw new _('unexpected "typ" JWT header value',i,"typ","check_failed");const{requiredClaims:o=[],issuer:s,subject:a,audience:l,maxTokenAge:c}=r,u=[...o];void 0!==c&&u.push("iat"),void 0!==l&&u.push("aud"),void 0!==a&&u.push("sub"),void 0!==s&&u.push("iss");for(const e of new Set(u.reverse()))if(!(e in i))throw new _(`missing required "${e}" claim`,i,e,"missing");if(s&&!(Array.isArray(s)?s:[s]).includes(i.iss))throw new _('unexpected "iss" claim value',i,"iss","check_failed");if(a&&i.sub!==a)throw new _('unexpected "sub" claim value',i,"sub","check_failed");if(l&&(p=i.aud,h="string"==typeof l?[l]:l,!("string"==typeof p?h.includes(p):Array.isArray(p)&&h.some(Set.prototype.has.bind(new Set(p))))))throw new _('unexpected "aud" claim value',i,"aud","check_failed");var p,h;let f;switch(typeof r.clockTolerance){case"string":f=mt(r.clockTolerance);break;case"number":f=r.clockTolerance;break;case"undefined":f=0;break;default:throw new TypeError("Invalid clockTolerance option type")}const{currentDate:m}=r,g=pt(m||new Date);if((void 0!==i.iat||c)&&"number"!=typeof i.iat)throw new _('"iat" claim must be a number',i,"iat","invalid");if(void 0!==i.nbf){if("number"!=typeof i.nbf)throw new _('"nbf" claim must be a number',i,"nbf","invalid");if(i.nbf>g+f)throw new _('"nbf" claim timestamp check failed',i,"nbf","check_failed")}if(void 0!==i.exp){if("number"!=typeof i.exp)throw new _('"exp" claim must be a number',i,"exp","invalid");if(i.exp<=g-f)throw new x('"exp" claim timestamp check failed',i,"exp","check_failed")}if(c){const e=g-i.iat;if(e-f>("number"==typeof c?c:mt(c)))throw new x('"iat" claim timestamp check failed (too far in the past)',i,"iat","check_failed");if(e<0-f)throw new _('"iat" claim timestamp check failed (it should be in the past)',i,"iat","check_failed")}return i};async function vt(e,t,r){const i=await ct(e,t,r);if(i.protectedHeader.crit?.includes("b64")&&!1===i.protectedHeader.b64)throw new C("JWTs MUST NOT use unencoded payload");const n={payload:yt(i.protectedHeader,i.payload,r),protectedHeader:i.protectedHeader};return"function"==typeof t?{...n,key:i.key}:n}async function bt(e,t,r){const i=await Je(e,t,r),n=yt(i.protectedHeader,i.plaintext,r),{protectedHeader:o}=i;if(void 0!==o.iss&&o.iss!==n.iss)throw new _('replicated "iss" claim header parameter mismatch',n,"iss","mismatch");if(void 0!==o.sub&&o.sub!==n.sub)throw new _('replicated "sub" claim header parameter mismatch',n,"sub","mismatch");if(void 0!==o.aud&&JSON.stringify(o.aud)!==JSON.stringify(n.aud))throw new _('replicated "aud" claim header parameter mismatch',n,"aud","mismatch");const s={payload:n,protectedHeader:o};return"function"==typeof t?{...s,key:i.key}:s}class wt{constructor(e){this._flattened=new it(e)}setContentEncryptionKey(e){return this._flattened.setContentEncryptionKey(e),this}setInitializationVector(e){return this._flattened.setInitializationVector(e),this}setProtectedHeader(e){return this._flattened.setProtectedHeader(e),this}setKeyManagementParameters(e){return this._flattened.setKeyManagementParameters(e),this}async encrypt(e,t){const r=await this._flattened.encrypt(e,t);return[r.protected,r.encrypted_key,r.iv,r.ciphertext,r.tag].join(".")}}const _t=async(e,t,r)=>{const i=await at(e,t,"sign");de(e,i);const n=await o.subtle.sign(st(e,i.algorithm),i,r);return new Uint8Array(n)};class xt{constructor(e){if(!(e instanceof Uint8Array))throw new TypeError("payload must be an instance of Uint8Array");this._payload=e}setProtectedHeader(e){if(this._protectedHeader)throw new TypeError("setProtectedHeader can only be called once");return this._protectedHeader=e,this}setUnprotectedHeader(e){if(this._unprotectedHeader)throw new TypeError("setUnprotectedHeader can only be called once");return this._unprotectedHeader=e,this}async sign(e,t){if(!this._protectedHeader&&!this._unprotectedHeader)throw new B("either setProtectedHeader or setUnprotectedHeader must be called before #sign()");if(!Z(this._protectedHeader,this._unprotectedHeader))throw new B("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");const r={...this._protectedHeader,...this._unprotectedHeader};let i=!0;if(We(B,new Map([["b64",!0]]),t?.crit,this._protectedHeader,r).has("b64")&&(i=this._protectedHeader.b64,"boolean"!=typeof i))throw new B('The "b64" (base64url-encode payload) Header Parameter must be a boolean');const{alg:n}=r;if("string"!=typeof n||!n)throw new B('JWS "alg" (Algorithm) Header Parameter missing or invalid');He(n,e,"sign");let o,s=this._payload;i&&(s=l.encode(y(s))),o=this._protectedHeader?l.encode(y(JSON.stringify(this._protectedHeader))):l.encode("");const a=u(o,l.encode("."),s),c=await _t(n,e,a),p={signature:y(c),payload:""};return i&&(p.payload=d.decode(s)),this._unprotectedHeader&&(p.header=this._unprotectedHeader),this._protectedHeader&&(p.protected=d.decode(o)),p}}class St{constructor(e){this._flattened=new xt(e)}setProtectedHeader(e){return this._flattened.setProtectedHeader(e),this}async sign(e,t){const r=await this._flattened.sign(e,t);if(void 0===r.payload)throw new TypeError("use the flattened module for creating JWS with b64: false");return`${r.protected}.${r.payload}.${r.signature}`}}class kt{constructor(e,t,r){this.parent=e,this.key=t,this.options=r}setProtectedHeader(e){if(this.protectedHeader)throw new TypeError("setProtectedHeader can only be called once");return this.protectedHeader=e,this}setUnprotectedHeader(e){if(this.unprotectedHeader)throw new TypeError("setUnprotectedHeader can only be called once");return this.unprotectedHeader=e,this}addSignature(...e){return this.parent.addSignature(...e)}sign(...e){return this.parent.sign(...e)}done(){return this.parent}}class Et{constructor(e){this._signatures=[],this._payload=e}addSignature(e,t){const r=new kt(this,e,t);return this._signatures.push(r),r}async sign(){if(!this._signatures.length)throw new B("at least one signature must be added");const e={signatures:[],payload:""};for(let t=0;t{if("string"!=typeof e||!e)throw new I(`${t} missing or invalid`)};async function Ft(e,t){if(!X(e))throw new TypeError("JWK must be an object");if(t??(t="sha256"),"sha256"!==t&&"sha384"!==t&&"sha512"!==t)throw new TypeError('digestAlgorithm must one of "sha256", "sha384", or "sha512"');let r;switch(e.kty){case"EC":At(e.crv,'"crv" (Curve) Parameter'),At(e.x,'"x" (X Coordinate) Parameter'),At(e.y,'"y" (Y Coordinate) Parameter'),r={crv:e.crv,kty:e.kty,x:e.x,y:e.y};break;case"OKP":At(e.crv,'"crv" (Subtype of Key Pair) Parameter'),At(e.x,'"x" (Public Key) Parameter'),r={crv:e.crv,kty:e.kty,x:e.x};break;case"RSA":At(e.e,'"e" (Exponent) Parameter'),At(e.n,'"n" (Modulus) Parameter'),r={e:e.e,kty:e.kty,n:e.n};break;case"oct":At(e.k,'"k" (Key Value) Parameter'),r={k:e.k,kty:e.kty};break;default:throw new k('"kty" (Key Type) Parameter missing or unsupported')}const i=l.encode(JSON.stringify(r));return y(await a(t,i))}async function Mt(e,t){t??(t="sha256");const r=await Ft(e,t);return`urn:ietf:params:oauth:jwk-thumbprint:sha-${t.slice(-3)}:${r}`}async function Dt(e,t){const r={...e,...t?.header};if(!X(r.jwk))throw new B('"jwk" (JSON Web Key) Header Parameter must be a JSON object');const i=await ze({...r.jwk,ext:!0},r.alg);if(i instanceof Uint8Array||"public"!==i.type)throw new B('"jwk" (JSON Web Key) Header Parameter must be a public key');return i}function Rt(e){return X(e)}function Pt(e){return"function"==typeof structuredClone?structuredClone(e):JSON.parse(JSON.stringify(e))}class Ot{constructor(e){if(this._cached=new WeakMap,!function(e){return e&&"object"==typeof e&&Array.isArray(e.keys)&&e.keys.every(Rt)}(e))throw new A("JSON Web Key Set malformed");this._jwks=Pt(e)}async getKey(e,t){const{alg:r,kid:i}={...e,...t?.header},n=function(e){switch("string"==typeof e&&e.slice(0,2)){case"RS":case"PS":return"RSA";case"ES":return"EC";case"Ed":return"OKP";default:throw new k('Unsupported "alg" value for a JSON Web Key Set')}}(r),o=this._jwks.keys.filter((e=>{let t=n===e.kty;if(t&&"string"==typeof i&&(t=i===e.kid),t&&"string"==typeof e.alg&&(t=r===e.alg),t&&"string"==typeof e.use&&(t="sig"===e.use),t&&Array.isArray(e.key_ops)&&(t=e.key_ops.includes("verify")),t&&"EdDSA"===r&&(t="Ed25519"===e.crv||"Ed448"===e.crv),t)switch(r){case"ES256":t="P-256"===e.crv;break;case"ES256K":t="secp256k1"===e.crv;break;case"ES384":t="P-384"===e.crv;break;case"ES512":t="P-521"===e.crv}return t})),{0:s,length:a}=o;if(0===a)throw new F;if(1!==a){const e=new M,{_cached:t}=this;throw e[Symbol.asyncIterator]=async function*(){for(const e of o)try{yield await zt(t,e,r)}catch{}},e}return zt(this._cached,s,r)}}async function zt(e,t,r){const i=e.get(t)||e.set(t,{}).get(t);if(void 0===i[r]){const e=await ze({...t,ext:!0},r);if(e instanceof Uint8Array||"public"!==e.type)throw new A("JSON Web Key Set members must be public keys");i[r]=e}return i[r]}function Nt(e){const t=new Ot(e),r=async(e,r)=>t.getKey(e,r);return Object.defineProperties(r,{jwks:{value:()=>Pt(t._jwks),enumerable:!0,configurable:!1,writable:!1}}),r}const qt=async(e,t,r)=>{let i,n,o=!1;"function"==typeof AbortController&&(i=new AbortController,n=setTimeout((()=>{o=!0,i.abort()}),t));const s=await fetch(e.href,{signal:i?i.signal:void 0,redirect:"manual",headers:r.headers}).catch((e=>{if(o)throw new D;throw e}));if(void 0!==n&&clearTimeout(n),200!==s.status)throw new w("Expected 200 OK from the JSON Web Key Set HTTP response");try{return await s.json()}catch{throw new w("Failed to parse the JSON Web Key Set HTTP response as JSON")}};let Ut;if("undefined"==typeof navigator||!navigator.userAgent?.startsWith?.("Mozilla/5.0 ")){Ut=`${"jose"}/${"v5.9.4"}`}const Lt=Symbol();class jt{constructor(e,t){if(!(e instanceof URL))throw new TypeError("url must be an instance of URL");var r,i;this._url=new URL(e.href),this._options={agent:t?.agent,headers:t?.headers},this._timeoutDuration="number"==typeof t?.timeoutDuration?t?.timeoutDuration:5e3,this._cooldownDuration="number"==typeof t?.cooldownDuration?t?.cooldownDuration:3e4,this._cacheMaxAge="number"==typeof t?.cacheMaxAge?t?.cacheMaxAge:6e5,void 0!==t?.[Lt]&&(this._cache=t?.[Lt],r=t?.[Lt],i=this._cacheMaxAge,"object"==typeof r&&null!==r&&"uat"in r&&"number"==typeof r.uat&&!(Date.now()-r.uat>=i)&&"jwks"in r&&X(r.jwks)&&Array.isArray(r.jwks.keys)&&Array.prototype.every.call(r.jwks.keys,X)&&(this._jwksTimestamp=this._cache.uat,this._local=Nt(this._cache.jwks)))}coolingDown(){return"number"==typeof this._jwksTimestamp&&Date.now(){this._local=Nt(e),this._cache&&(this._cache.uat=Date.now(),this._cache.jwks=e),this._jwksTimestamp=Date.now(),this._pendingFetch=void 0})).catch((e=>{throw this._pendingFetch=void 0,e}))),await this._pendingFetch}}function Ht(e,t){const r=new jt(e,t),i=async(e,t)=>r.getKey(e,t);return Object.defineProperties(i,{coolingDown:{get:()=>r.coolingDown(),enumerable:!0,configurable:!1},fresh:{get:()=>r.fresh(),enumerable:!0,configurable:!1},reload:{value:()=>r.reload(),enumerable:!0,configurable:!1,writable:!1},reloading:{get:()=>!!r._pendingFetch,enumerable:!0,configurable:!1},jwks:{value:()=>r._local?.jwks(),enumerable:!0,configurable:!1,writable:!1}}),i}const $t=Lt;class Gt extends Bt{encode(){return`${y(JSON.stringify({alg:"none"}))}.${y(JSON.stringify(this._payload))}.`}static decode(e,t){if("string"!=typeof e)throw new C("Unsecured JWT must be a string");const{0:r,1:i,2:n,length:o}=e.split(".");if(3!==o||""!==n)throw new C("Invalid Unsecured JWT");let s;try{if(s=JSON.parse(d.decode(b(r))),"none"!==s.alg)throw new Error}catch{throw new C("Invalid Unsecured JWT")}return{payload:yt(s,b(i),t),header:s}}}const Wt=y,Kt=b;function Vt(e){let t;if("string"==typeof e){const r=e.split(".");3!==r.length&&5!==r.length||([t]=r)}else if("object"==typeof e&&e){if(!("protected"in e))throw new TypeError("Token does not contain a Protected Header");t=e.protected}try{if("string"!=typeof t||!t)throw new Error;const e=JSON.parse(d.decode(Kt(t)));if(!X(e))throw new Error;return e}catch{throw new TypeError("Invalid Token or Protected Header formatting")}}function Jt(e){if("string"!=typeof e)throw new C("JWTs must use Compact JWS serialization, JWT must be a string");const{1:t,length:r}=e.split(".");if(5===r)throw new C("Only JWTs using Compact JWS serialization can be decoded");if(3!==r)throw new C("Invalid JWT");if(!t)throw new C("JWTs must contain a payload");let i,n;try{i=Kt(t)}catch{throw new C("Failed to base64url decode the payload")}try{n=JSON.parse(d.decode(i))}catch{throw new C("Failed to parse the decoded payload as JSON")}if(!X(n))throw new C("Invalid JWT Claims Set");return n}function Yt(e){const t=e?.modulusLength??2048;if("number"!=typeof t||t<2048)throw new k("Invalid or unsupported modulusLength option provided, 2048 bits or larger keys must be used");return t}async function Qt(e,t){return async function(e,t){let r,i;switch(e){case"PS256":case"PS384":case"PS512":r={name:"RSA-PSS",hash:`SHA-${e.slice(-3)}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:Yt(t)},i=["sign","verify"];break;case"RS256":case"RS384":case"RS512":r={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${e.slice(-3)}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:Yt(t)},i=["sign","verify"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":r={name:"RSA-OAEP",hash:`SHA-${parseInt(e.slice(-3),10)||1}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:Yt(t)},i=["decrypt","unwrapKey","encrypt","wrapKey"];break;case"ES256":r={name:"ECDSA",namedCurve:"P-256"},i=["sign","verify"];break;case"ES384":r={name:"ECDSA",namedCurve:"P-384"},i=["sign","verify"];break;case"ES512":r={name:"ECDSA",namedCurve:"P-521"},i=["sign","verify"];break;case"EdDSA":{i=["sign","verify"];const e=t?.crv??"Ed25519";switch(e){case"Ed25519":case"Ed448":r={name:e};break;default:throw new k("Invalid or unsupported crv option provided")}break}case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{i=["deriveKey","deriveBits"];const e=t?.crv??"P-256";switch(e){case"P-256":case"P-384":case"P-521":r={name:"ECDH",namedCurve:e};break;case"X25519":case"X448":r={name:e};break;default:throw new k("Invalid or unsupported crv option provided, supported values are P-256, P-384, P-521, X25519, and X448")}break}default:throw new k('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}return o.subtle.generateKey(r,t?.extractable??!1,i)}(e,t)}async function Zt(e,t){return async function(e,t){let r,i,n;switch(e){case"HS256":case"HS384":case"HS512":r=parseInt(e.slice(-3),10),i={name:"HMAC",hash:`SHA-${r}`,length:r},n=["sign","verify"];break;case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return r=parseInt(e.slice(-3),10),P(new Uint8Array(r>>3));case"A128KW":case"A192KW":case"A256KW":r=parseInt(e.slice(1,4),10),i={name:"AES-KW",length:r},n=["wrapKey","unwrapKey"];break;case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":case"A128GCM":case"A192GCM":case"A256GCM":r=parseInt(e.slice(1,4),10),i={name:"AES-GCM",length:r},n=["encrypt","decrypt"];break;default:throw new k('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}return o.subtle.generateKey(i,t?.extractable??!1,n)}(e,t)}const Xt="WebCryptoAPI"},3219:e=>{"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},62951:e=>{"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},64589:e=>{"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},23241:e=>{"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},1636:e=>{"use strict";e.exports={rE:"6.5.7"}},81813:e=>{"use strict";e.exports=JSON.parse('{"application/1d-interleaved-parityfec":{"source":"iana"},"application/3gpdash-qoe-report+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/3gpp-ims+xml":{"source":"iana","compressible":true},"application/3gpphal+json":{"source":"iana","compressible":true},"application/3gpphalforms+json":{"source":"iana","compressible":true},"application/a2l":{"source":"iana"},"application/ace+cbor":{"source":"iana"},"application/activemessage":{"source":"iana"},"application/activity+json":{"source":"iana","compressible":true},"application/alto-costmap+json":{"source":"iana","compressible":true},"application/alto-costmapfilter+json":{"source":"iana","compressible":true},"application/alto-directory+json":{"source":"iana","compressible":true},"application/alto-endpointcost+json":{"source":"iana","compressible":true},"application/alto-endpointcostparams+json":{"source":"iana","compressible":true},"application/alto-endpointprop+json":{"source":"iana","compressible":true},"application/alto-endpointpropparams+json":{"source":"iana","compressible":true},"application/alto-error+json":{"source":"iana","compressible":true},"application/alto-networkmap+json":{"source":"iana","compressible":true},"application/alto-networkmapfilter+json":{"source":"iana","compressible":true},"application/alto-updatestreamcontrol+json":{"source":"iana","compressible":true},"application/alto-updatestreamparams+json":{"source":"iana","compressible":true},"application/aml":{"source":"iana"},"application/andrew-inset":{"source":"iana","extensions":["ez"]},"application/applefile":{"source":"iana"},"application/applixware":{"source":"apache","extensions":["aw"]},"application/at+jwt":{"source":"iana"},"application/atf":{"source":"iana"},"application/atfx":{"source":"iana"},"application/atom+xml":{"source":"iana","compressible":true,"extensions":["atom"]},"application/atomcat+xml":{"source":"iana","compressible":true,"extensions":["atomcat"]},"application/atomdeleted+xml":{"source":"iana","compressible":true,"extensions":["atomdeleted"]},"application/atomicmail":{"source":"iana"},"application/atomsvc+xml":{"source":"iana","compressible":true,"extensions":["atomsvc"]},"application/atsc-dwd+xml":{"source":"iana","compressible":true,"extensions":["dwd"]},"application/atsc-dynamic-event-message":{"source":"iana"},"application/atsc-held+xml":{"source":"iana","compressible":true,"extensions":["held"]},"application/atsc-rdt+json":{"source":"iana","compressible":true},"application/atsc-rsat+xml":{"source":"iana","compressible":true,"extensions":["rsat"]},"application/atxml":{"source":"iana"},"application/auth-policy+xml":{"source":"iana","compressible":true},"application/bacnet-xdd+zip":{"source":"iana","compressible":false},"application/batch-smtp":{"source":"iana"},"application/bdoc":{"compressible":false,"extensions":["bdoc"]},"application/beep+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/calendar+json":{"source":"iana","compressible":true},"application/calendar+xml":{"source":"iana","compressible":true,"extensions":["xcs"]},"application/call-completion":{"source":"iana"},"application/cals-1840":{"source":"iana"},"application/captive+json":{"source":"iana","compressible":true},"application/cbor":{"source":"iana"},"application/cbor-seq":{"source":"iana"},"application/cccex":{"source":"iana"},"application/ccmp+xml":{"source":"iana","compressible":true},"application/ccxml+xml":{"source":"iana","compressible":true,"extensions":["ccxml"]},"application/cdfx+xml":{"source":"iana","compressible":true,"extensions":["cdfx"]},"application/cdmi-capability":{"source":"iana","extensions":["cdmia"]},"application/cdmi-container":{"source":"iana","extensions":["cdmic"]},"application/cdmi-domain":{"source":"iana","extensions":["cdmid"]},"application/cdmi-object":{"source":"iana","extensions":["cdmio"]},"application/cdmi-queue":{"source":"iana","extensions":["cdmiq"]},"application/cdni":{"source":"iana"},"application/cea":{"source":"iana"},"application/cea-2018+xml":{"source":"iana","compressible":true},"application/cellml+xml":{"source":"iana","compressible":true},"application/cfw":{"source":"iana"},"application/city+json":{"source":"iana","compressible":true},"application/clr":{"source":"iana"},"application/clue+xml":{"source":"iana","compressible":true},"application/clue_info+xml":{"source":"iana","compressible":true},"application/cms":{"source":"iana"},"application/cnrp+xml":{"source":"iana","compressible":true},"application/coap-group+json":{"source":"iana","compressible":true},"application/coap-payload":{"source":"iana"},"application/commonground":{"source":"iana"},"application/conference-info+xml":{"source":"iana","compressible":true},"application/cose":{"source":"iana"},"application/cose-key":{"source":"iana"},"application/cose-key-set":{"source":"iana"},"application/cpl+xml":{"source":"iana","compressible":true,"extensions":["cpl"]},"application/csrattrs":{"source":"iana"},"application/csta+xml":{"source":"iana","compressible":true},"application/cstadata+xml":{"source":"iana","compressible":true},"application/csvm+json":{"source":"iana","compressible":true},"application/cu-seeme":{"source":"apache","extensions":["cu"]},"application/cwt":{"source":"iana"},"application/cybercash":{"source":"iana"},"application/dart":{"compressible":true},"application/dash+xml":{"source":"iana","compressible":true,"extensions":["mpd"]},"application/dash-patch+xml":{"source":"iana","compressible":true,"extensions":["mpp"]},"application/dashdelta":{"source":"iana"},"application/davmount+xml":{"source":"iana","compressible":true,"extensions":["davmount"]},"application/dca-rft":{"source":"iana"},"application/dcd":{"source":"iana"},"application/dec-dx":{"source":"iana"},"application/dialog-info+xml":{"source":"iana","compressible":true},"application/dicom":{"source":"iana"},"application/dicom+json":{"source":"iana","compressible":true},"application/dicom+xml":{"source":"iana","compressible":true},"application/dii":{"source":"iana"},"application/dit":{"source":"iana"},"application/dns":{"source":"iana"},"application/dns+json":{"source":"iana","compressible":true},"application/dns-message":{"source":"iana"},"application/docbook+xml":{"source":"apache","compressible":true,"extensions":["dbk"]},"application/dots+cbor":{"source":"iana"},"application/dskpp+xml":{"source":"iana","compressible":true},"application/dssc+der":{"source":"iana","extensions":["dssc"]},"application/dssc+xml":{"source":"iana","compressible":true,"extensions":["xdssc"]},"application/dvcs":{"source":"iana"},"application/ecmascript":{"source":"iana","compressible":true,"extensions":["es","ecma"]},"application/edi-consent":{"source":"iana"},"application/edi-x12":{"source":"iana","compressible":false},"application/edifact":{"source":"iana","compressible":false},"application/efi":{"source":"iana"},"application/elm+json":{"source":"iana","charset":"UTF-8","compressible":true},"application/elm+xml":{"source":"iana","compressible":true},"application/emergencycalldata.cap+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/emergencycalldata.comment+xml":{"source":"iana","compressible":true},"application/emergencycalldata.control+xml":{"source":"iana","compressible":true},"application/emergencycalldata.deviceinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.ecall.msd":{"source":"iana"},"application/emergencycalldata.providerinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.serviceinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.subscriberinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.veds+xml":{"source":"iana","compressible":true},"application/emma+xml":{"source":"iana","compressible":true,"extensions":["emma"]},"application/emotionml+xml":{"source":"iana","compressible":true,"extensions":["emotionml"]},"application/encaprtp":{"source":"iana"},"application/epp+xml":{"source":"iana","compressible":true},"application/epub+zip":{"source":"iana","compressible":false,"extensions":["epub"]},"application/eshop":{"source":"iana"},"application/exi":{"source":"iana","extensions":["exi"]},"application/expect-ct-report+json":{"source":"iana","compressible":true},"application/express":{"source":"iana","extensions":["exp"]},"application/fastinfoset":{"source":"iana"},"application/fastsoap":{"source":"iana"},"application/fdt+xml":{"source":"iana","compressible":true,"extensions":["fdt"]},"application/fhir+json":{"source":"iana","charset":"UTF-8","compressible":true},"application/fhir+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/fido.trusted-apps+json":{"compressible":true},"application/fits":{"source":"iana"},"application/flexfec":{"source":"iana"},"application/font-sfnt":{"source":"iana"},"application/font-tdpfr":{"source":"iana","extensions":["pfr"]},"application/font-woff":{"source":"iana","compressible":false},"application/framework-attributes+xml":{"source":"iana","compressible":true},"application/geo+json":{"source":"iana","compressible":true,"extensions":["geojson"]},"application/geo+json-seq":{"source":"iana"},"application/geopackage+sqlite3":{"source":"iana"},"application/geoxacml+xml":{"source":"iana","compressible":true},"application/gltf-buffer":{"source":"iana"},"application/gml+xml":{"source":"iana","compressible":true,"extensions":["gml"]},"application/gpx+xml":{"source":"apache","compressible":true,"extensions":["gpx"]},"application/gxf":{"source":"apache","extensions":["gxf"]},"application/gzip":{"source":"iana","compressible":false,"extensions":["gz"]},"application/h224":{"source":"iana"},"application/held+xml":{"source":"iana","compressible":true},"application/hjson":{"extensions":["hjson"]},"application/http":{"source":"iana"},"application/hyperstudio":{"source":"iana","extensions":["stk"]},"application/ibe-key-request+xml":{"source":"iana","compressible":true},"application/ibe-pkg-reply+xml":{"source":"iana","compressible":true},"application/ibe-pp-data":{"source":"iana"},"application/iges":{"source":"iana"},"application/im-iscomposing+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/index":{"source":"iana"},"application/index.cmd":{"source":"iana"},"application/index.obj":{"source":"iana"},"application/index.response":{"source":"iana"},"application/index.vnd":{"source":"iana"},"application/inkml+xml":{"source":"iana","compressible":true,"extensions":["ink","inkml"]},"application/iotp":{"source":"iana"},"application/ipfix":{"source":"iana","extensions":["ipfix"]},"application/ipp":{"source":"iana"},"application/isup":{"source":"iana"},"application/its+xml":{"source":"iana","compressible":true,"extensions":["its"]},"application/java-archive":{"source":"apache","compressible":false,"extensions":["jar","war","ear"]},"application/java-serialized-object":{"source":"apache","compressible":false,"extensions":["ser"]},"application/java-vm":{"source":"apache","compressible":false,"extensions":["class"]},"application/javascript":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["js","mjs"]},"application/jf2feed+json":{"source":"iana","compressible":true},"application/jose":{"source":"iana"},"application/jose+json":{"source":"iana","compressible":true},"application/jrd+json":{"source":"iana","compressible":true},"application/jscalendar+json":{"source":"iana","compressible":true},"application/json":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["json","map"]},"application/json-patch+json":{"source":"iana","compressible":true},"application/json-seq":{"source":"iana"},"application/json5":{"extensions":["json5"]},"application/jsonml+json":{"source":"apache","compressible":true,"extensions":["jsonml"]},"application/jwk+json":{"source":"iana","compressible":true},"application/jwk-set+json":{"source":"iana","compressible":true},"application/jwt":{"source":"iana"},"application/kpml-request+xml":{"source":"iana","compressible":true},"application/kpml-response+xml":{"source":"iana","compressible":true},"application/ld+json":{"source":"iana","compressible":true,"extensions":["jsonld"]},"application/lgr+xml":{"source":"iana","compressible":true,"extensions":["lgr"]},"application/link-format":{"source":"iana"},"application/load-control+xml":{"source":"iana","compressible":true},"application/lost+xml":{"source":"iana","compressible":true,"extensions":["lostxml"]},"application/lostsync+xml":{"source":"iana","compressible":true},"application/lpf+zip":{"source":"iana","compressible":false},"application/lxf":{"source":"iana"},"application/mac-binhex40":{"source":"iana","extensions":["hqx"]},"application/mac-compactpro":{"source":"apache","extensions":["cpt"]},"application/macwriteii":{"source":"iana"},"application/mads+xml":{"source":"iana","compressible":true,"extensions":["mads"]},"application/manifest+json":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["webmanifest"]},"application/marc":{"source":"iana","extensions":["mrc"]},"application/marcxml+xml":{"source":"iana","compressible":true,"extensions":["mrcx"]},"application/mathematica":{"source":"iana","extensions":["ma","nb","mb"]},"application/mathml+xml":{"source":"iana","compressible":true,"extensions":["mathml"]},"application/mathml-content+xml":{"source":"iana","compressible":true},"application/mathml-presentation+xml":{"source":"iana","compressible":true},"application/mbms-associated-procedure-description+xml":{"source":"iana","compressible":true},"application/mbms-deregister+xml":{"source":"iana","compressible":true},"application/mbms-envelope+xml":{"source":"iana","compressible":true},"application/mbms-msk+xml":{"source":"iana","compressible":true},"application/mbms-msk-response+xml":{"source":"iana","compressible":true},"application/mbms-protection-description+xml":{"source":"iana","compressible":true},"application/mbms-reception-report+xml":{"source":"iana","compressible":true},"application/mbms-register+xml":{"source":"iana","compressible":true},"application/mbms-register-response+xml":{"source":"iana","compressible":true},"application/mbms-schedule+xml":{"source":"iana","compressible":true},"application/mbms-user-service-description+xml":{"source":"iana","compressible":true},"application/mbox":{"source":"iana","extensions":["mbox"]},"application/media-policy-dataset+xml":{"source":"iana","compressible":true,"extensions":["mpf"]},"application/media_control+xml":{"source":"iana","compressible":true},"application/mediaservercontrol+xml":{"source":"iana","compressible":true,"extensions":["mscml"]},"application/merge-patch+json":{"source":"iana","compressible":true},"application/metalink+xml":{"source":"apache","compressible":true,"extensions":["metalink"]},"application/metalink4+xml":{"source":"iana","compressible":true,"extensions":["meta4"]},"application/mets+xml":{"source":"iana","compressible":true,"extensions":["mets"]},"application/mf4":{"source":"iana"},"application/mikey":{"source":"iana"},"application/mipc":{"source":"iana"},"application/missing-blocks+cbor-seq":{"source":"iana"},"application/mmt-aei+xml":{"source":"iana","compressible":true,"extensions":["maei"]},"application/mmt-usd+xml":{"source":"iana","compressible":true,"extensions":["musd"]},"application/mods+xml":{"source":"iana","compressible":true,"extensions":["mods"]},"application/moss-keys":{"source":"iana"},"application/moss-signature":{"source":"iana"},"application/mosskey-data":{"source":"iana"},"application/mosskey-request":{"source":"iana"},"application/mp21":{"source":"iana","extensions":["m21","mp21"]},"application/mp4":{"source":"iana","extensions":["mp4s","m4p"]},"application/mpeg4-generic":{"source":"iana"},"application/mpeg4-iod":{"source":"iana"},"application/mpeg4-iod-xmt":{"source":"iana"},"application/mrb-consumer+xml":{"source":"iana","compressible":true},"application/mrb-publish+xml":{"source":"iana","compressible":true},"application/msc-ivr+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/msc-mixer+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/msword":{"source":"iana","compressible":false,"extensions":["doc","dot"]},"application/mud+json":{"source":"iana","compressible":true},"application/multipart-core":{"source":"iana"},"application/mxf":{"source":"iana","extensions":["mxf"]},"application/n-quads":{"source":"iana","extensions":["nq"]},"application/n-triples":{"source":"iana","extensions":["nt"]},"application/nasdata":{"source":"iana"},"application/news-checkgroups":{"source":"iana","charset":"US-ASCII"},"application/news-groupinfo":{"source":"iana","charset":"US-ASCII"},"application/news-transmission":{"source":"iana"},"application/nlsml+xml":{"source":"iana","compressible":true},"application/node":{"source":"iana","extensions":["cjs"]},"application/nss":{"source":"iana"},"application/oauth-authz-req+jwt":{"source":"iana"},"application/oblivious-dns-message":{"source":"iana"},"application/ocsp-request":{"source":"iana"},"application/ocsp-response":{"source":"iana"},"application/octet-stream":{"source":"iana","compressible":false,"extensions":["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{"source":"iana","extensions":["oda"]},"application/odm+xml":{"source":"iana","compressible":true},"application/odx":{"source":"iana"},"application/oebps-package+xml":{"source":"iana","compressible":true,"extensions":["opf"]},"application/ogg":{"source":"iana","compressible":false,"extensions":["ogx"]},"application/omdoc+xml":{"source":"apache","compressible":true,"extensions":["omdoc"]},"application/onenote":{"source":"apache","extensions":["onetoc","onetoc2","onetmp","onepkg"]},"application/opc-nodeset+xml":{"source":"iana","compressible":true},"application/oscore":{"source":"iana"},"application/oxps":{"source":"iana","extensions":["oxps"]},"application/p21":{"source":"iana"},"application/p21+zip":{"source":"iana","compressible":false},"application/p2p-overlay+xml":{"source":"iana","compressible":true,"extensions":["relo"]},"application/parityfec":{"source":"iana"},"application/passport":{"source":"iana"},"application/patch-ops-error+xml":{"source":"iana","compressible":true,"extensions":["xer"]},"application/pdf":{"source":"iana","compressible":false,"extensions":["pdf"]},"application/pdx":{"source":"iana"},"application/pem-certificate-chain":{"source":"iana"},"application/pgp-encrypted":{"source":"iana","compressible":false,"extensions":["pgp"]},"application/pgp-keys":{"source":"iana","extensions":["asc"]},"application/pgp-signature":{"source":"iana","extensions":["asc","sig"]},"application/pics-rules":{"source":"apache","extensions":["prf"]},"application/pidf+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/pidf-diff+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/pkcs10":{"source":"iana","extensions":["p10"]},"application/pkcs12":{"source":"iana"},"application/pkcs7-mime":{"source":"iana","extensions":["p7m","p7c"]},"application/pkcs7-signature":{"source":"iana","extensions":["p7s"]},"application/pkcs8":{"source":"iana","extensions":["p8"]},"application/pkcs8-encrypted":{"source":"iana"},"application/pkix-attr-cert":{"source":"iana","extensions":["ac"]},"application/pkix-cert":{"source":"iana","extensions":["cer"]},"application/pkix-crl":{"source":"iana","extensions":["crl"]},"application/pkix-pkipath":{"source":"iana","extensions":["pkipath"]},"application/pkixcmp":{"source":"iana","extensions":["pki"]},"application/pls+xml":{"source":"iana","compressible":true,"extensions":["pls"]},"application/poc-settings+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/postscript":{"source":"iana","compressible":true,"extensions":["ai","eps","ps"]},"application/ppsp-tracker+json":{"source":"iana","compressible":true},"application/problem+json":{"source":"iana","compressible":true},"application/problem+xml":{"source":"iana","compressible":true},"application/provenance+xml":{"source":"iana","compressible":true,"extensions":["provx"]},"application/prs.alvestrand.titrax-sheet":{"source":"iana"},"application/prs.cww":{"source":"iana","extensions":["cww"]},"application/prs.cyn":{"source":"iana","charset":"7-BIT"},"application/prs.hpub+zip":{"source":"iana","compressible":false},"application/prs.nprend":{"source":"iana"},"application/prs.plucker":{"source":"iana"},"application/prs.rdf-xml-crypt":{"source":"iana"},"application/prs.xsf+xml":{"source":"iana","compressible":true},"application/pskc+xml":{"source":"iana","compressible":true,"extensions":["pskcxml"]},"application/pvd+json":{"source":"iana","compressible":true},"application/qsig":{"source":"iana"},"application/raml+yaml":{"compressible":true,"extensions":["raml"]},"application/raptorfec":{"source":"iana"},"application/rdap+json":{"source":"iana","compressible":true},"application/rdf+xml":{"source":"iana","compressible":true,"extensions":["rdf","owl"]},"application/reginfo+xml":{"source":"iana","compressible":true,"extensions":["rif"]},"application/relax-ng-compact-syntax":{"source":"iana","extensions":["rnc"]},"application/remote-printing":{"source":"iana"},"application/reputon+json":{"source":"iana","compressible":true},"application/resource-lists+xml":{"source":"iana","compressible":true,"extensions":["rl"]},"application/resource-lists-diff+xml":{"source":"iana","compressible":true,"extensions":["rld"]},"application/rfc+xml":{"source":"iana","compressible":true},"application/riscos":{"source":"iana"},"application/rlmi+xml":{"source":"iana","compressible":true},"application/rls-services+xml":{"source":"iana","compressible":true,"extensions":["rs"]},"application/route-apd+xml":{"source":"iana","compressible":true,"extensions":["rapd"]},"application/route-s-tsid+xml":{"source":"iana","compressible":true,"extensions":["sls"]},"application/route-usd+xml":{"source":"iana","compressible":true,"extensions":["rusd"]},"application/rpki-ghostbusters":{"source":"iana","extensions":["gbr"]},"application/rpki-manifest":{"source":"iana","extensions":["mft"]},"application/rpki-publication":{"source":"iana"},"application/rpki-roa":{"source":"iana","extensions":["roa"]},"application/rpki-updown":{"source":"iana"},"application/rsd+xml":{"source":"apache","compressible":true,"extensions":["rsd"]},"application/rss+xml":{"source":"apache","compressible":true,"extensions":["rss"]},"application/rtf":{"source":"iana","compressible":true,"extensions":["rtf"]},"application/rtploopback":{"source":"iana"},"application/rtx":{"source":"iana"},"application/samlassertion+xml":{"source":"iana","compressible":true},"application/samlmetadata+xml":{"source":"iana","compressible":true},"application/sarif+json":{"source":"iana","compressible":true},"application/sarif-external-properties+json":{"source":"iana","compressible":true},"application/sbe":{"source":"iana"},"application/sbml+xml":{"source":"iana","compressible":true,"extensions":["sbml"]},"application/scaip+xml":{"source":"iana","compressible":true},"application/scim+json":{"source":"iana","compressible":true},"application/scvp-cv-request":{"source":"iana","extensions":["scq"]},"application/scvp-cv-response":{"source":"iana","extensions":["scs"]},"application/scvp-vp-request":{"source":"iana","extensions":["spq"]},"application/scvp-vp-response":{"source":"iana","extensions":["spp"]},"application/sdp":{"source":"iana","extensions":["sdp"]},"application/secevent+jwt":{"source":"iana"},"application/senml+cbor":{"source":"iana"},"application/senml+json":{"source":"iana","compressible":true},"application/senml+xml":{"source":"iana","compressible":true,"extensions":["senmlx"]},"application/senml-etch+cbor":{"source":"iana"},"application/senml-etch+json":{"source":"iana","compressible":true},"application/senml-exi":{"source":"iana"},"application/sensml+cbor":{"source":"iana"},"application/sensml+json":{"source":"iana","compressible":true},"application/sensml+xml":{"source":"iana","compressible":true,"extensions":["sensmlx"]},"application/sensml-exi":{"source":"iana"},"application/sep+xml":{"source":"iana","compressible":true},"application/sep-exi":{"source":"iana"},"application/session-info":{"source":"iana"},"application/set-payment":{"source":"iana"},"application/set-payment-initiation":{"source":"iana","extensions":["setpay"]},"application/set-registration":{"source":"iana"},"application/set-registration-initiation":{"source":"iana","extensions":["setreg"]},"application/sgml":{"source":"iana"},"application/sgml-open-catalog":{"source":"iana"},"application/shf+xml":{"source":"iana","compressible":true,"extensions":["shf"]},"application/sieve":{"source":"iana","extensions":["siv","sieve"]},"application/simple-filter+xml":{"source":"iana","compressible":true},"application/simple-message-summary":{"source":"iana"},"application/simplesymbolcontainer":{"source":"iana"},"application/sipc":{"source":"iana"},"application/slate":{"source":"iana"},"application/smil":{"source":"iana"},"application/smil+xml":{"source":"iana","compressible":true,"extensions":["smi","smil"]},"application/smpte336m":{"source":"iana"},"application/soap+fastinfoset":{"source":"iana"},"application/soap+xml":{"source":"iana","compressible":true},"application/sparql-query":{"source":"iana","extensions":["rq"]},"application/sparql-results+xml":{"source":"iana","compressible":true,"extensions":["srx"]},"application/spdx+json":{"source":"iana","compressible":true},"application/spirits-event+xml":{"source":"iana","compressible":true},"application/sql":{"source":"iana"},"application/srgs":{"source":"iana","extensions":["gram"]},"application/srgs+xml":{"source":"iana","compressible":true,"extensions":["grxml"]},"application/sru+xml":{"source":"iana","compressible":true,"extensions":["sru"]},"application/ssdl+xml":{"source":"apache","compressible":true,"extensions":["ssdl"]},"application/ssml+xml":{"source":"iana","compressible":true,"extensions":["ssml"]},"application/stix+json":{"source":"iana","compressible":true},"application/swid+xml":{"source":"iana","compressible":true,"extensions":["swidtag"]},"application/tamp-apex-update":{"source":"iana"},"application/tamp-apex-update-confirm":{"source":"iana"},"application/tamp-community-update":{"source":"iana"},"application/tamp-community-update-confirm":{"source":"iana"},"application/tamp-error":{"source":"iana"},"application/tamp-sequence-adjust":{"source":"iana"},"application/tamp-sequence-adjust-confirm":{"source":"iana"},"application/tamp-status-query":{"source":"iana"},"application/tamp-status-response":{"source":"iana"},"application/tamp-update":{"source":"iana"},"application/tamp-update-confirm":{"source":"iana"},"application/tar":{"compressible":true},"application/taxii+json":{"source":"iana","compressible":true},"application/td+json":{"source":"iana","compressible":true},"application/tei+xml":{"source":"iana","compressible":true,"extensions":["tei","teicorpus"]},"application/tetra_isi":{"source":"iana"},"application/thraud+xml":{"source":"iana","compressible":true,"extensions":["tfi"]},"application/timestamp-query":{"source":"iana"},"application/timestamp-reply":{"source":"iana"},"application/timestamped-data":{"source":"iana","extensions":["tsd"]},"application/tlsrpt+gzip":{"source":"iana"},"application/tlsrpt+json":{"source":"iana","compressible":true},"application/tnauthlist":{"source":"iana"},"application/token-introspection+jwt":{"source":"iana"},"application/toml":{"compressible":true,"extensions":["toml"]},"application/trickle-ice-sdpfrag":{"source":"iana"},"application/trig":{"source":"iana","extensions":["trig"]},"application/ttml+xml":{"source":"iana","compressible":true,"extensions":["ttml"]},"application/tve-trigger":{"source":"iana"},"application/tzif":{"source":"iana"},"application/tzif-leap":{"source":"iana"},"application/ubjson":{"compressible":false,"extensions":["ubj"]},"application/ulpfec":{"source":"iana"},"application/urc-grpsheet+xml":{"source":"iana","compressible":true},"application/urc-ressheet+xml":{"source":"iana","compressible":true,"extensions":["rsheet"]},"application/urc-targetdesc+xml":{"source":"iana","compressible":true,"extensions":["td"]},"application/urc-uisocketdesc+xml":{"source":"iana","compressible":true},"application/vcard+json":{"source":"iana","compressible":true},"application/vcard+xml":{"source":"iana","compressible":true},"application/vemmi":{"source":"iana"},"application/vividence.scriptfile":{"source":"apache"},"application/vnd.1000minds.decision-model+xml":{"source":"iana","compressible":true,"extensions":["1km"]},"application/vnd.3gpp-prose+xml":{"source":"iana","compressible":true},"application/vnd.3gpp-prose-pc3ch+xml":{"source":"iana","compressible":true},"application/vnd.3gpp-v2x-local-service-information":{"source":"iana"},"application/vnd.3gpp.5gnas":{"source":"iana"},"application/vnd.3gpp.access-transfer-events+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.bsf+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.gmop+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.gtpc":{"source":"iana"},"application/vnd.3gpp.interworking-data":{"source":"iana"},"application/vnd.3gpp.lpp":{"source":"iana"},"application/vnd.3gpp.mc-signalling-ear":{"source":"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-payload":{"source":"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-signalling":{"source":"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-floor-request+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-location-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-signed+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-ue-init-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-location-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-transmission-request+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mid-call+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.ngap":{"source":"iana"},"application/vnd.3gpp.pfcp":{"source":"iana"},"application/vnd.3gpp.pic-bw-large":{"source":"iana","extensions":["plb"]},"application/vnd.3gpp.pic-bw-small":{"source":"iana","extensions":["psb"]},"application/vnd.3gpp.pic-bw-var":{"source":"iana","extensions":["pvb"]},"application/vnd.3gpp.s1ap":{"source":"iana"},"application/vnd.3gpp.sms":{"source":"iana"},"application/vnd.3gpp.sms+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.srvcc-ext+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.srvcc-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.state-and-event-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.ussd+xml":{"source":"iana","compressible":true},"application/vnd.3gpp2.bcmcsinfo+xml":{"source":"iana","compressible":true},"application/vnd.3gpp2.sms":{"source":"iana"},"application/vnd.3gpp2.tcap":{"source":"iana","extensions":["tcap"]},"application/vnd.3lightssoftware.imagescal":{"source":"iana"},"application/vnd.3m.post-it-notes":{"source":"iana","extensions":["pwn"]},"application/vnd.accpac.simply.aso":{"source":"iana","extensions":["aso"]},"application/vnd.accpac.simply.imp":{"source":"iana","extensions":["imp"]},"application/vnd.acucobol":{"source":"iana","extensions":["acu"]},"application/vnd.acucorp":{"source":"iana","extensions":["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{"source":"apache","compressible":false,"extensions":["air"]},"application/vnd.adobe.flash.movie":{"source":"iana"},"application/vnd.adobe.formscentral.fcdt":{"source":"iana","extensions":["fcdt"]},"application/vnd.adobe.fxp":{"source":"iana","extensions":["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{"source":"iana"},"application/vnd.adobe.xdp+xml":{"source":"iana","compressible":true,"extensions":["xdp"]},"application/vnd.adobe.xfdf":{"source":"iana","extensions":["xfdf"]},"application/vnd.aether.imp":{"source":"iana"},"application/vnd.afpc.afplinedata":{"source":"iana"},"application/vnd.afpc.afplinedata-pagedef":{"source":"iana"},"application/vnd.afpc.cmoca-cmresource":{"source":"iana"},"application/vnd.afpc.foca-charset":{"source":"iana"},"application/vnd.afpc.foca-codedfont":{"source":"iana"},"application/vnd.afpc.foca-codepage":{"source":"iana"},"application/vnd.afpc.modca":{"source":"iana"},"application/vnd.afpc.modca-cmtable":{"source":"iana"},"application/vnd.afpc.modca-formdef":{"source":"iana"},"application/vnd.afpc.modca-mediummap":{"source":"iana"},"application/vnd.afpc.modca-objectcontainer":{"source":"iana"},"application/vnd.afpc.modca-overlay":{"source":"iana"},"application/vnd.afpc.modca-pagesegment":{"source":"iana"},"application/vnd.age":{"source":"iana","extensions":["age"]},"application/vnd.ah-barcode":{"source":"iana"},"application/vnd.ahead.space":{"source":"iana","extensions":["ahead"]},"application/vnd.airzip.filesecure.azf":{"source":"iana","extensions":["azf"]},"application/vnd.airzip.filesecure.azs":{"source":"iana","extensions":["azs"]},"application/vnd.amadeus+json":{"source":"iana","compressible":true},"application/vnd.amazon.ebook":{"source":"apache","extensions":["azw"]},"application/vnd.amazon.mobi8-ebook":{"source":"iana"},"application/vnd.americandynamics.acc":{"source":"iana","extensions":["acc"]},"application/vnd.amiga.ami":{"source":"iana","extensions":["ami"]},"application/vnd.amundsen.maze+xml":{"source":"iana","compressible":true},"application/vnd.android.ota":{"source":"iana"},"application/vnd.android.package-archive":{"source":"apache","compressible":false,"extensions":["apk"]},"application/vnd.anki":{"source":"iana"},"application/vnd.anser-web-certificate-issue-initiation":{"source":"iana","extensions":["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{"source":"apache","extensions":["fti"]},"application/vnd.antix.game-component":{"source":"iana","extensions":["atx"]},"application/vnd.apache.arrow.file":{"source":"iana"},"application/vnd.apache.arrow.stream":{"source":"iana"},"application/vnd.apache.thrift.binary":{"source":"iana"},"application/vnd.apache.thrift.compact":{"source":"iana"},"application/vnd.apache.thrift.json":{"source":"iana"},"application/vnd.api+json":{"source":"iana","compressible":true},"application/vnd.aplextor.warrp+json":{"source":"iana","compressible":true},"application/vnd.apothekende.reservation+json":{"source":"iana","compressible":true},"application/vnd.apple.installer+xml":{"source":"iana","compressible":true,"extensions":["mpkg"]},"application/vnd.apple.keynote":{"source":"iana","extensions":["key"]},"application/vnd.apple.mpegurl":{"source":"iana","extensions":["m3u8"]},"application/vnd.apple.numbers":{"source":"iana","extensions":["numbers"]},"application/vnd.apple.pages":{"source":"iana","extensions":["pages"]},"application/vnd.apple.pkpass":{"compressible":false,"extensions":["pkpass"]},"application/vnd.arastra.swi":{"source":"iana"},"application/vnd.aristanetworks.swi":{"source":"iana","extensions":["swi"]},"application/vnd.artisan+json":{"source":"iana","compressible":true},"application/vnd.artsquare":{"source":"iana"},"application/vnd.astraea-software.iota":{"source":"iana","extensions":["iota"]},"application/vnd.audiograph":{"source":"iana","extensions":["aep"]},"application/vnd.autopackage":{"source":"iana"},"application/vnd.avalon+json":{"source":"iana","compressible":true},"application/vnd.avistar+xml":{"source":"iana","compressible":true},"application/vnd.balsamiq.bmml+xml":{"source":"iana","compressible":true,"extensions":["bmml"]},"application/vnd.balsamiq.bmpr":{"source":"iana"},"application/vnd.banana-accounting":{"source":"iana"},"application/vnd.bbf.usp.error":{"source":"iana"},"application/vnd.bbf.usp.msg":{"source":"iana"},"application/vnd.bbf.usp.msg+json":{"source":"iana","compressible":true},"application/vnd.bekitzur-stech+json":{"source":"iana","compressible":true},"application/vnd.bint.med-content":{"source":"iana"},"application/vnd.biopax.rdf+xml":{"source":"iana","compressible":true},"application/vnd.blink-idb-value-wrapper":{"source":"iana"},"application/vnd.blueice.multipass":{"source":"iana","extensions":["mpm"]},"application/vnd.bluetooth.ep.oob":{"source":"iana"},"application/vnd.bluetooth.le.oob":{"source":"iana"},"application/vnd.bmi":{"source":"iana","extensions":["bmi"]},"application/vnd.bpf":{"source":"iana"},"application/vnd.bpf3":{"source":"iana"},"application/vnd.businessobjects":{"source":"iana","extensions":["rep"]},"application/vnd.byu.uapi+json":{"source":"iana","compressible":true},"application/vnd.cab-jscript":{"source":"iana"},"application/vnd.canon-cpdl":{"source":"iana"},"application/vnd.canon-lips":{"source":"iana"},"application/vnd.capasystems-pg+json":{"source":"iana","compressible":true},"application/vnd.cendio.thinlinc.clientconf":{"source":"iana"},"application/vnd.century-systems.tcp_stream":{"source":"iana"},"application/vnd.chemdraw+xml":{"source":"iana","compressible":true,"extensions":["cdxml"]},"application/vnd.chess-pgn":{"source":"iana"},"application/vnd.chipnuts.karaoke-mmd":{"source":"iana","extensions":["mmd"]},"application/vnd.ciedi":{"source":"iana"},"application/vnd.cinderella":{"source":"iana","extensions":["cdy"]},"application/vnd.cirpack.isdn-ext":{"source":"iana"},"application/vnd.citationstyles.style+xml":{"source":"iana","compressible":true,"extensions":["csl"]},"application/vnd.claymore":{"source":"iana","extensions":["cla"]},"application/vnd.cloanto.rp9":{"source":"iana","extensions":["rp9"]},"application/vnd.clonk.c4group":{"source":"iana","extensions":["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{"source":"iana","extensions":["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{"source":"iana","extensions":["c11amz"]},"application/vnd.coffeescript":{"source":"iana"},"application/vnd.collabio.xodocuments.document":{"source":"iana"},"application/vnd.collabio.xodocuments.document-template":{"source":"iana"},"application/vnd.collabio.xodocuments.presentation":{"source":"iana"},"application/vnd.collabio.xodocuments.presentation-template":{"source":"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{"source":"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{"source":"iana"},"application/vnd.collection+json":{"source":"iana","compressible":true},"application/vnd.collection.doc+json":{"source":"iana","compressible":true},"application/vnd.collection.next+json":{"source":"iana","compressible":true},"application/vnd.comicbook+zip":{"source":"iana","compressible":false},"application/vnd.comicbook-rar":{"source":"iana"},"application/vnd.commerce-battelle":{"source":"iana"},"application/vnd.commonspace":{"source":"iana","extensions":["csp"]},"application/vnd.contact.cmsg":{"source":"iana","extensions":["cdbcmsg"]},"application/vnd.coreos.ignition+json":{"source":"iana","compressible":true},"application/vnd.cosmocaller":{"source":"iana","extensions":["cmc"]},"application/vnd.crick.clicker":{"source":"iana","extensions":["clkx"]},"application/vnd.crick.clicker.keyboard":{"source":"iana","extensions":["clkk"]},"application/vnd.crick.clicker.palette":{"source":"iana","extensions":["clkp"]},"application/vnd.crick.clicker.template":{"source":"iana","extensions":["clkt"]},"application/vnd.crick.clicker.wordbank":{"source":"iana","extensions":["clkw"]},"application/vnd.criticaltools.wbs+xml":{"source":"iana","compressible":true,"extensions":["wbs"]},"application/vnd.cryptii.pipe+json":{"source":"iana","compressible":true},"application/vnd.crypto-shade-file":{"source":"iana"},"application/vnd.cryptomator.encrypted":{"source":"iana"},"application/vnd.cryptomator.vault":{"source":"iana"},"application/vnd.ctc-posml":{"source":"iana","extensions":["pml"]},"application/vnd.ctct.ws+xml":{"source":"iana","compressible":true},"application/vnd.cups-pdf":{"source":"iana"},"application/vnd.cups-postscript":{"source":"iana"},"application/vnd.cups-ppd":{"source":"iana","extensions":["ppd"]},"application/vnd.cups-raster":{"source":"iana"},"application/vnd.cups-raw":{"source":"iana"},"application/vnd.curl":{"source":"iana"},"application/vnd.curl.car":{"source":"apache","extensions":["car"]},"application/vnd.curl.pcurl":{"source":"apache","extensions":["pcurl"]},"application/vnd.cyan.dean.root+xml":{"source":"iana","compressible":true},"application/vnd.cybank":{"source":"iana"},"application/vnd.cyclonedx+json":{"source":"iana","compressible":true},"application/vnd.cyclonedx+xml":{"source":"iana","compressible":true},"application/vnd.d2l.coursepackage1p0+zip":{"source":"iana","compressible":false},"application/vnd.d3m-dataset":{"source":"iana"},"application/vnd.d3m-problem":{"source":"iana"},"application/vnd.dart":{"source":"iana","compressible":true,"extensions":["dart"]},"application/vnd.data-vision.rdz":{"source":"iana","extensions":["rdz"]},"application/vnd.datapackage+json":{"source":"iana","compressible":true},"application/vnd.dataresource+json":{"source":"iana","compressible":true},"application/vnd.dbf":{"source":"iana","extensions":["dbf"]},"application/vnd.debian.binary-package":{"source":"iana"},"application/vnd.dece.data":{"source":"iana","extensions":["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{"source":"iana","compressible":true,"extensions":["uvt","uvvt"]},"application/vnd.dece.unspecified":{"source":"iana","extensions":["uvx","uvvx"]},"application/vnd.dece.zip":{"source":"iana","extensions":["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{"source":"iana","extensions":["fe_launch"]},"application/vnd.desmume.movie":{"source":"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{"source":"iana"},"application/vnd.dm.delegation+xml":{"source":"iana","compressible":true},"application/vnd.dna":{"source":"iana","extensions":["dna"]},"application/vnd.document+json":{"source":"iana","compressible":true},"application/vnd.dolby.mlp":{"source":"apache","extensions":["mlp"]},"application/vnd.dolby.mobile.1":{"source":"iana"},"application/vnd.dolby.mobile.2":{"source":"iana"},"application/vnd.doremir.scorecloud-binary-document":{"source":"iana"},"application/vnd.dpgraph":{"source":"iana","extensions":["dpg"]},"application/vnd.dreamfactory":{"source":"iana","extensions":["dfac"]},"application/vnd.drive+json":{"source":"iana","compressible":true},"application/vnd.ds-keypoint":{"source":"apache","extensions":["kpxx"]},"application/vnd.dtg.local":{"source":"iana"},"application/vnd.dtg.local.flash":{"source":"iana"},"application/vnd.dtg.local.html":{"source":"iana"},"application/vnd.dvb.ait":{"source":"iana","extensions":["ait"]},"application/vnd.dvb.dvbisl+xml":{"source":"iana","compressible":true},"application/vnd.dvb.dvbj":{"source":"iana"},"application/vnd.dvb.esgcontainer":{"source":"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{"source":"iana"},"application/vnd.dvb.ipdcesgaccess":{"source":"iana"},"application/vnd.dvb.ipdcesgaccess2":{"source":"iana"},"application/vnd.dvb.ipdcesgpdd":{"source":"iana"},"application/vnd.dvb.ipdcroaming":{"source":"iana"},"application/vnd.dvb.iptv.alfec-base":{"source":"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{"source":"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-container+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-generic+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-msglist+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-registration-request+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-registration-response+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-init+xml":{"source":"iana","compressible":true},"application/vnd.dvb.pfr":{"source":"iana"},"application/vnd.dvb.service":{"source":"iana","extensions":["svc"]},"application/vnd.dxr":{"source":"iana"},"application/vnd.dynageo":{"source":"iana","extensions":["geo"]},"application/vnd.dzr":{"source":"iana"},"application/vnd.easykaraoke.cdgdownload":{"source":"iana"},"application/vnd.ecdis-update":{"source":"iana"},"application/vnd.ecip.rlp":{"source":"iana"},"application/vnd.eclipse.ditto+json":{"source":"iana","compressible":true},"application/vnd.ecowin.chart":{"source":"iana","extensions":["mag"]},"application/vnd.ecowin.filerequest":{"source":"iana"},"application/vnd.ecowin.fileupdate":{"source":"iana"},"application/vnd.ecowin.series":{"source":"iana"},"application/vnd.ecowin.seriesrequest":{"source":"iana"},"application/vnd.ecowin.seriesupdate":{"source":"iana"},"application/vnd.efi.img":{"source":"iana"},"application/vnd.efi.iso":{"source":"iana"},"application/vnd.emclient.accessrequest+xml":{"source":"iana","compressible":true},"application/vnd.enliven":{"source":"iana","extensions":["nml"]},"application/vnd.enphase.envoy":{"source":"iana"},"application/vnd.eprints.data+xml":{"source":"iana","compressible":true},"application/vnd.epson.esf":{"source":"iana","extensions":["esf"]},"application/vnd.epson.msf":{"source":"iana","extensions":["msf"]},"application/vnd.epson.quickanime":{"source":"iana","extensions":["qam"]},"application/vnd.epson.salt":{"source":"iana","extensions":["slt"]},"application/vnd.epson.ssf":{"source":"iana","extensions":["ssf"]},"application/vnd.ericsson.quickcall":{"source":"iana"},"application/vnd.espass-espass+zip":{"source":"iana","compressible":false},"application/vnd.eszigno3+xml":{"source":"iana","compressible":true,"extensions":["es3","et3"]},"application/vnd.etsi.aoc+xml":{"source":"iana","compressible":true},"application/vnd.etsi.asic-e+zip":{"source":"iana","compressible":false},"application/vnd.etsi.asic-s+zip":{"source":"iana","compressible":false},"application/vnd.etsi.cug+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvcommand+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvdiscovery+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvprofile+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-bc+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-cod+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-npvr+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvservice+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsync+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvueprofile+xml":{"source":"iana","compressible":true},"application/vnd.etsi.mcid+xml":{"source":"iana","compressible":true},"application/vnd.etsi.mheg5":{"source":"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{"source":"iana","compressible":true},"application/vnd.etsi.pstn+xml":{"source":"iana","compressible":true},"application/vnd.etsi.sci+xml":{"source":"iana","compressible":true},"application/vnd.etsi.simservs+xml":{"source":"iana","compressible":true},"application/vnd.etsi.timestamp-token":{"source":"iana"},"application/vnd.etsi.tsl+xml":{"source":"iana","compressible":true},"application/vnd.etsi.tsl.der":{"source":"iana"},"application/vnd.eu.kasparian.car+json":{"source":"iana","compressible":true},"application/vnd.eudora.data":{"source":"iana"},"application/vnd.evolv.ecig.profile":{"source":"iana"},"application/vnd.evolv.ecig.settings":{"source":"iana"},"application/vnd.evolv.ecig.theme":{"source":"iana"},"application/vnd.exstream-empower+zip":{"source":"iana","compressible":false},"application/vnd.exstream-package":{"source":"iana"},"application/vnd.ezpix-album":{"source":"iana","extensions":["ez2"]},"application/vnd.ezpix-package":{"source":"iana","extensions":["ez3"]},"application/vnd.f-secure.mobile":{"source":"iana"},"application/vnd.familysearch.gedcom+zip":{"source":"iana","compressible":false},"application/vnd.fastcopy-disk-image":{"source":"iana"},"application/vnd.fdf":{"source":"iana","extensions":["fdf"]},"application/vnd.fdsn.mseed":{"source":"iana","extensions":["mseed"]},"application/vnd.fdsn.seed":{"source":"iana","extensions":["seed","dataless"]},"application/vnd.ffsns":{"source":"iana"},"application/vnd.ficlab.flb+zip":{"source":"iana","compressible":false},"application/vnd.filmit.zfc":{"source":"iana"},"application/vnd.fints":{"source":"iana"},"application/vnd.firemonkeys.cloudcell":{"source":"iana"},"application/vnd.flographit":{"source":"iana","extensions":["gph"]},"application/vnd.fluxtime.clip":{"source":"iana","extensions":["ftc"]},"application/vnd.font-fontforge-sfd":{"source":"iana"},"application/vnd.framemaker":{"source":"iana","extensions":["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{"source":"iana","extensions":["fnc"]},"application/vnd.frogans.ltf":{"source":"iana","extensions":["ltf"]},"application/vnd.fsc.weblaunch":{"source":"iana","extensions":["fsc"]},"application/vnd.fujifilm.fb.docuworks":{"source":"iana"},"application/vnd.fujifilm.fb.docuworks.binder":{"source":"iana"},"application/vnd.fujifilm.fb.docuworks.container":{"source":"iana"},"application/vnd.fujifilm.fb.jfi+xml":{"source":"iana","compressible":true},"application/vnd.fujitsu.oasys":{"source":"iana","extensions":["oas"]},"application/vnd.fujitsu.oasys2":{"source":"iana","extensions":["oa2"]},"application/vnd.fujitsu.oasys3":{"source":"iana","extensions":["oa3"]},"application/vnd.fujitsu.oasysgp":{"source":"iana","extensions":["fg5"]},"application/vnd.fujitsu.oasysprs":{"source":"iana","extensions":["bh2"]},"application/vnd.fujixerox.art-ex":{"source":"iana"},"application/vnd.fujixerox.art4":{"source":"iana"},"application/vnd.fujixerox.ddd":{"source":"iana","extensions":["ddd"]},"application/vnd.fujixerox.docuworks":{"source":"iana","extensions":["xdw"]},"application/vnd.fujixerox.docuworks.binder":{"source":"iana","extensions":["xbd"]},"application/vnd.fujixerox.docuworks.container":{"source":"iana"},"application/vnd.fujixerox.hbpl":{"source":"iana"},"application/vnd.fut-misnet":{"source":"iana"},"application/vnd.futoin+cbor":{"source":"iana"},"application/vnd.futoin+json":{"source":"iana","compressible":true},"application/vnd.fuzzysheet":{"source":"iana","extensions":["fzs"]},"application/vnd.genomatix.tuxedo":{"source":"iana","extensions":["txd"]},"application/vnd.gentics.grd+json":{"source":"iana","compressible":true},"application/vnd.geo+json":{"source":"iana","compressible":true},"application/vnd.geocube+xml":{"source":"iana","compressible":true},"application/vnd.geogebra.file":{"source":"iana","extensions":["ggb"]},"application/vnd.geogebra.slides":{"source":"iana"},"application/vnd.geogebra.tool":{"source":"iana","extensions":["ggt"]},"application/vnd.geometry-explorer":{"source":"iana","extensions":["gex","gre"]},"application/vnd.geonext":{"source":"iana","extensions":["gxt"]},"application/vnd.geoplan":{"source":"iana","extensions":["g2w"]},"application/vnd.geospace":{"source":"iana","extensions":["g3w"]},"application/vnd.gerber":{"source":"iana"},"application/vnd.globalplatform.card-content-mgt":{"source":"iana"},"application/vnd.globalplatform.card-content-mgt-response":{"source":"iana"},"application/vnd.gmx":{"source":"iana","extensions":["gmx"]},"application/vnd.google-apps.document":{"compressible":false,"extensions":["gdoc"]},"application/vnd.google-apps.presentation":{"compressible":false,"extensions":["gslides"]},"application/vnd.google-apps.spreadsheet":{"compressible":false,"extensions":["gsheet"]},"application/vnd.google-earth.kml+xml":{"source":"iana","compressible":true,"extensions":["kml"]},"application/vnd.google-earth.kmz":{"source":"iana","compressible":false,"extensions":["kmz"]},"application/vnd.gov.sk.e-form+xml":{"source":"iana","compressible":true},"application/vnd.gov.sk.e-form+zip":{"source":"iana","compressible":false},"application/vnd.gov.sk.xmldatacontainer+xml":{"source":"iana","compressible":true},"application/vnd.grafeq":{"source":"iana","extensions":["gqf","gqs"]},"application/vnd.gridmp":{"source":"iana"},"application/vnd.groove-account":{"source":"iana","extensions":["gac"]},"application/vnd.groove-help":{"source":"iana","extensions":["ghf"]},"application/vnd.groove-identity-message":{"source":"iana","extensions":["gim"]},"application/vnd.groove-injector":{"source":"iana","extensions":["grv"]},"application/vnd.groove-tool-message":{"source":"iana","extensions":["gtm"]},"application/vnd.groove-tool-template":{"source":"iana","extensions":["tpl"]},"application/vnd.groove-vcard":{"source":"iana","extensions":["vcg"]},"application/vnd.hal+json":{"source":"iana","compressible":true},"application/vnd.hal+xml":{"source":"iana","compressible":true,"extensions":["hal"]},"application/vnd.handheld-entertainment+xml":{"source":"iana","compressible":true,"extensions":["zmm"]},"application/vnd.hbci":{"source":"iana","extensions":["hbci"]},"application/vnd.hc+json":{"source":"iana","compressible":true},"application/vnd.hcl-bireports":{"source":"iana"},"application/vnd.hdt":{"source":"iana"},"application/vnd.heroku+json":{"source":"iana","compressible":true},"application/vnd.hhe.lesson-player":{"source":"iana","extensions":["les"]},"application/vnd.hl7cda+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.hl7v2+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.hp-hpgl":{"source":"iana","extensions":["hpgl"]},"application/vnd.hp-hpid":{"source":"iana","extensions":["hpid"]},"application/vnd.hp-hps":{"source":"iana","extensions":["hps"]},"application/vnd.hp-jlyt":{"source":"iana","extensions":["jlt"]},"application/vnd.hp-pcl":{"source":"iana","extensions":["pcl"]},"application/vnd.hp-pclxl":{"source":"iana","extensions":["pclxl"]},"application/vnd.httphone":{"source":"iana"},"application/vnd.hydrostatix.sof-data":{"source":"iana","extensions":["sfd-hdstx"]},"application/vnd.hyper+json":{"source":"iana","compressible":true},"application/vnd.hyper-item+json":{"source":"iana","compressible":true},"application/vnd.hyperdrive+json":{"source":"iana","compressible":true},"application/vnd.hzn-3d-crossword":{"source":"iana"},"application/vnd.ibm.afplinedata":{"source":"iana"},"application/vnd.ibm.electronic-media":{"source":"iana"},"application/vnd.ibm.minipay":{"source":"iana","extensions":["mpy"]},"application/vnd.ibm.modcap":{"source":"iana","extensions":["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{"source":"iana","extensions":["irm"]},"application/vnd.ibm.secure-container":{"source":"iana","extensions":["sc"]},"application/vnd.iccprofile":{"source":"iana","extensions":["icc","icm"]},"application/vnd.ieee.1905":{"source":"iana"},"application/vnd.igloader":{"source":"iana","extensions":["igl"]},"application/vnd.imagemeter.folder+zip":{"source":"iana","compressible":false},"application/vnd.imagemeter.image+zip":{"source":"iana","compressible":false},"application/vnd.immervision-ivp":{"source":"iana","extensions":["ivp"]},"application/vnd.immervision-ivu":{"source":"iana","extensions":["ivu"]},"application/vnd.ims.imsccv1p1":{"source":"iana"},"application/vnd.ims.imsccv1p2":{"source":"iana"},"application/vnd.ims.imsccv1p3":{"source":"iana"},"application/vnd.ims.lis.v2.result+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolproxy+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolproxy.id+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolsettings+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolsettings.simple+json":{"source":"iana","compressible":true},"application/vnd.informedcontrol.rms+xml":{"source":"iana","compressible":true},"application/vnd.informix-visionary":{"source":"iana"},"application/vnd.infotech.project":{"source":"iana"},"application/vnd.infotech.project+xml":{"source":"iana","compressible":true},"application/vnd.innopath.wamp.notification":{"source":"iana"},"application/vnd.insors.igm":{"source":"iana","extensions":["igm"]},"application/vnd.intercon.formnet":{"source":"iana","extensions":["xpw","xpx"]},"application/vnd.intergeo":{"source":"iana","extensions":["i2g"]},"application/vnd.intertrust.digibox":{"source":"iana"},"application/vnd.intertrust.nncp":{"source":"iana"},"application/vnd.intu.qbo":{"source":"iana","extensions":["qbo"]},"application/vnd.intu.qfx":{"source":"iana","extensions":["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.conceptitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.knowledgeitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.newsitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.newsmessage+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.packageitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.planningitem+xml":{"source":"iana","compressible":true},"application/vnd.ipunplugged.rcprofile":{"source":"iana","extensions":["rcprofile"]},"application/vnd.irepository.package+xml":{"source":"iana","compressible":true,"extensions":["irp"]},"application/vnd.is-xpr":{"source":"iana","extensions":["xpr"]},"application/vnd.isac.fcs":{"source":"iana","extensions":["fcs"]},"application/vnd.iso11783-10+zip":{"source":"iana","compressible":false},"application/vnd.jam":{"source":"iana","extensions":["jam"]},"application/vnd.japannet-directory-service":{"source":"iana"},"application/vnd.japannet-jpnstore-wakeup":{"source":"iana"},"application/vnd.japannet-payment-wakeup":{"source":"iana"},"application/vnd.japannet-registration":{"source":"iana"},"application/vnd.japannet-registration-wakeup":{"source":"iana"},"application/vnd.japannet-setstore-wakeup":{"source":"iana"},"application/vnd.japannet-verification":{"source":"iana"},"application/vnd.japannet-verification-wakeup":{"source":"iana"},"application/vnd.jcp.javame.midlet-rms":{"source":"iana","extensions":["rms"]},"application/vnd.jisp":{"source":"iana","extensions":["jisp"]},"application/vnd.joost.joda-archive":{"source":"iana","extensions":["joda"]},"application/vnd.jsk.isdn-ngn":{"source":"iana"},"application/vnd.kahootz":{"source":"iana","extensions":["ktz","ktr"]},"application/vnd.kde.karbon":{"source":"iana","extensions":["karbon"]},"application/vnd.kde.kchart":{"source":"iana","extensions":["chrt"]},"application/vnd.kde.kformula":{"source":"iana","extensions":["kfo"]},"application/vnd.kde.kivio":{"source":"iana","extensions":["flw"]},"application/vnd.kde.kontour":{"source":"iana","extensions":["kon"]},"application/vnd.kde.kpresenter":{"source":"iana","extensions":["kpr","kpt"]},"application/vnd.kde.kspread":{"source":"iana","extensions":["ksp"]},"application/vnd.kde.kword":{"source":"iana","extensions":["kwd","kwt"]},"application/vnd.kenameaapp":{"source":"iana","extensions":["htke"]},"application/vnd.kidspiration":{"source":"iana","extensions":["kia"]},"application/vnd.kinar":{"source":"iana","extensions":["kne","knp"]},"application/vnd.koan":{"source":"iana","extensions":["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{"source":"iana","extensions":["sse"]},"application/vnd.las":{"source":"iana"},"application/vnd.las.las+json":{"source":"iana","compressible":true},"application/vnd.las.las+xml":{"source":"iana","compressible":true,"extensions":["lasxml"]},"application/vnd.laszip":{"source":"iana"},"application/vnd.leap+json":{"source":"iana","compressible":true},"application/vnd.liberty-request+xml":{"source":"iana","compressible":true},"application/vnd.llamagraphics.life-balance.desktop":{"source":"iana","extensions":["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{"source":"iana","compressible":true,"extensions":["lbe"]},"application/vnd.logipipe.circuit+zip":{"source":"iana","compressible":false},"application/vnd.loom":{"source":"iana"},"application/vnd.lotus-1-2-3":{"source":"iana","extensions":["123"]},"application/vnd.lotus-approach":{"source":"iana","extensions":["apr"]},"application/vnd.lotus-freelance":{"source":"iana","extensions":["pre"]},"application/vnd.lotus-notes":{"source":"iana","extensions":["nsf"]},"application/vnd.lotus-organizer":{"source":"iana","extensions":["org"]},"application/vnd.lotus-screencam":{"source":"iana","extensions":["scm"]},"application/vnd.lotus-wordpro":{"source":"iana","extensions":["lwp"]},"application/vnd.macports.portpkg":{"source":"iana","extensions":["portpkg"]},"application/vnd.mapbox-vector-tile":{"source":"iana","extensions":["mvt"]},"application/vnd.marlin.drm.actiontoken+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.conftoken+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.license+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.mdcf":{"source":"iana"},"application/vnd.mason+json":{"source":"iana","compressible":true},"application/vnd.maxar.archive.3tz+zip":{"source":"iana","compressible":false},"application/vnd.maxmind.maxmind-db":{"source":"iana"},"application/vnd.mcd":{"source":"iana","extensions":["mcd"]},"application/vnd.medcalcdata":{"source":"iana","extensions":["mc1"]},"application/vnd.mediastation.cdkey":{"source":"iana","extensions":["cdkey"]},"application/vnd.meridian-slingshot":{"source":"iana"},"application/vnd.mfer":{"source":"iana","extensions":["mwf"]},"application/vnd.mfmp":{"source":"iana","extensions":["mfm"]},"application/vnd.micro+json":{"source":"iana","compressible":true},"application/vnd.micrografx.flo":{"source":"iana","extensions":["flo"]},"application/vnd.micrografx.igx":{"source":"iana","extensions":["igx"]},"application/vnd.microsoft.portable-executable":{"source":"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{"source":"iana"},"application/vnd.miele+json":{"source":"iana","compressible":true},"application/vnd.mif":{"source":"iana","extensions":["mif"]},"application/vnd.minisoft-hp3000-save":{"source":"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{"source":"iana"},"application/vnd.mobius.daf":{"source":"iana","extensions":["daf"]},"application/vnd.mobius.dis":{"source":"iana","extensions":["dis"]},"application/vnd.mobius.mbk":{"source":"iana","extensions":["mbk"]},"application/vnd.mobius.mqy":{"source":"iana","extensions":["mqy"]},"application/vnd.mobius.msl":{"source":"iana","extensions":["msl"]},"application/vnd.mobius.plc":{"source":"iana","extensions":["plc"]},"application/vnd.mobius.txf":{"source":"iana","extensions":["txf"]},"application/vnd.mophun.application":{"source":"iana","extensions":["mpn"]},"application/vnd.mophun.certificate":{"source":"iana","extensions":["mpc"]},"application/vnd.motorola.flexsuite":{"source":"iana"},"application/vnd.motorola.flexsuite.adsi":{"source":"iana"},"application/vnd.motorola.flexsuite.fis":{"source":"iana"},"application/vnd.motorola.flexsuite.gotap":{"source":"iana"},"application/vnd.motorola.flexsuite.kmr":{"source":"iana"},"application/vnd.motorola.flexsuite.ttc":{"source":"iana"},"application/vnd.motorola.flexsuite.wem":{"source":"iana"},"application/vnd.motorola.iprm":{"source":"iana"},"application/vnd.mozilla.xul+xml":{"source":"iana","compressible":true,"extensions":["xul"]},"application/vnd.ms-3mfdocument":{"source":"iana"},"application/vnd.ms-artgalry":{"source":"iana","extensions":["cil"]},"application/vnd.ms-asf":{"source":"iana"},"application/vnd.ms-cab-compressed":{"source":"iana","extensions":["cab"]},"application/vnd.ms-color.iccprofile":{"source":"apache"},"application/vnd.ms-excel":{"source":"iana","compressible":false,"extensions":["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{"source":"iana","extensions":["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{"source":"iana","extensions":["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{"source":"iana","extensions":["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{"source":"iana","extensions":["xltm"]},"application/vnd.ms-fontobject":{"source":"iana","compressible":true,"extensions":["eot"]},"application/vnd.ms-htmlhelp":{"source":"iana","extensions":["chm"]},"application/vnd.ms-ims":{"source":"iana","extensions":["ims"]},"application/vnd.ms-lrm":{"source":"iana","extensions":["lrm"]},"application/vnd.ms-office.activex+xml":{"source":"iana","compressible":true},"application/vnd.ms-officetheme":{"source":"iana","extensions":["thmx"]},"application/vnd.ms-opentype":{"source":"apache","compressible":true},"application/vnd.ms-outlook":{"compressible":false,"extensions":["msg"]},"application/vnd.ms-package.obfuscated-opentype":{"source":"apache"},"application/vnd.ms-pki.seccat":{"source":"apache","extensions":["cat"]},"application/vnd.ms-pki.stl":{"source":"apache","extensions":["stl"]},"application/vnd.ms-playready.initiator+xml":{"source":"iana","compressible":true},"application/vnd.ms-powerpoint":{"source":"iana","compressible":false,"extensions":["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{"source":"iana","extensions":["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{"source":"iana","extensions":["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{"source":"iana","extensions":["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{"source":"iana","extensions":["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{"source":"iana","extensions":["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{"source":"iana","compressible":true},"application/vnd.ms-printing.printticket+xml":{"source":"apache","compressible":true},"application/vnd.ms-printschematicket+xml":{"source":"iana","compressible":true},"application/vnd.ms-project":{"source":"iana","extensions":["mpp","mpt"]},"application/vnd.ms-tnef":{"source":"iana"},"application/vnd.ms-windows.devicepairing":{"source":"iana"},"application/vnd.ms-windows.nwprinting.oob":{"source":"iana"},"application/vnd.ms-windows.printerpairing":{"source":"iana"},"application/vnd.ms-windows.wsd.oob":{"source":"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{"source":"iana"},"application/vnd.ms-wmdrm.lic-resp":{"source":"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{"source":"iana"},"application/vnd.ms-wmdrm.meter-resp":{"source":"iana"},"application/vnd.ms-word.document.macroenabled.12":{"source":"iana","extensions":["docm"]},"application/vnd.ms-word.template.macroenabled.12":{"source":"iana","extensions":["dotm"]},"application/vnd.ms-works":{"source":"iana","extensions":["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{"source":"iana","extensions":["wpl"]},"application/vnd.ms-xpsdocument":{"source":"iana","compressible":false,"extensions":["xps"]},"application/vnd.msa-disk-image":{"source":"iana"},"application/vnd.mseq":{"source":"iana","extensions":["mseq"]},"application/vnd.msign":{"source":"iana"},"application/vnd.multiad.creator":{"source":"iana"},"application/vnd.multiad.creator.cif":{"source":"iana"},"application/vnd.music-niff":{"source":"iana"},"application/vnd.musician":{"source":"iana","extensions":["mus"]},"application/vnd.muvee.style":{"source":"iana","extensions":["msty"]},"application/vnd.mynfc":{"source":"iana","extensions":["taglet"]},"application/vnd.nacamar.ybrid+json":{"source":"iana","compressible":true},"application/vnd.ncd.control":{"source":"iana"},"application/vnd.ncd.reference":{"source":"iana"},"application/vnd.nearst.inv+json":{"source":"iana","compressible":true},"application/vnd.nebumind.line":{"source":"iana"},"application/vnd.nervana":{"source":"iana"},"application/vnd.netfpx":{"source":"iana"},"application/vnd.neurolanguage.nlu":{"source":"iana","extensions":["nlu"]},"application/vnd.nimn":{"source":"iana"},"application/vnd.nintendo.nitro.rom":{"source":"iana"},"application/vnd.nintendo.snes.rom":{"source":"iana"},"application/vnd.nitf":{"source":"iana","extensions":["ntf","nitf"]},"application/vnd.noblenet-directory":{"source":"iana","extensions":["nnd"]},"application/vnd.noblenet-sealer":{"source":"iana","extensions":["nns"]},"application/vnd.noblenet-web":{"source":"iana","extensions":["nnw"]},"application/vnd.nokia.catalogs":{"source":"iana"},"application/vnd.nokia.conml+wbxml":{"source":"iana"},"application/vnd.nokia.conml+xml":{"source":"iana","compressible":true},"application/vnd.nokia.iptv.config+xml":{"source":"iana","compressible":true},"application/vnd.nokia.isds-radio-presets":{"source":"iana"},"application/vnd.nokia.landmark+wbxml":{"source":"iana"},"application/vnd.nokia.landmark+xml":{"source":"iana","compressible":true},"application/vnd.nokia.landmarkcollection+xml":{"source":"iana","compressible":true},"application/vnd.nokia.n-gage.ac+xml":{"source":"iana","compressible":true,"extensions":["ac"]},"application/vnd.nokia.n-gage.data":{"source":"iana","extensions":["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{"source":"iana","extensions":["n-gage"]},"application/vnd.nokia.ncd":{"source":"iana"},"application/vnd.nokia.pcd+wbxml":{"source":"iana"},"application/vnd.nokia.pcd+xml":{"source":"iana","compressible":true},"application/vnd.nokia.radio-preset":{"source":"iana","extensions":["rpst"]},"application/vnd.nokia.radio-presets":{"source":"iana","extensions":["rpss"]},"application/vnd.novadigm.edm":{"source":"iana","extensions":["edm"]},"application/vnd.novadigm.edx":{"source":"iana","extensions":["edx"]},"application/vnd.novadigm.ext":{"source":"iana","extensions":["ext"]},"application/vnd.ntt-local.content-share":{"source":"iana"},"application/vnd.ntt-local.file-transfer":{"source":"iana"},"application/vnd.ntt-local.ogw_remote-access":{"source":"iana"},"application/vnd.ntt-local.sip-ta_remote":{"source":"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{"source":"iana"},"application/vnd.oasis.opendocument.chart":{"source":"iana","extensions":["odc"]},"application/vnd.oasis.opendocument.chart-template":{"source":"iana","extensions":["otc"]},"application/vnd.oasis.opendocument.database":{"source":"iana","extensions":["odb"]},"application/vnd.oasis.opendocument.formula":{"source":"iana","extensions":["odf"]},"application/vnd.oasis.opendocument.formula-template":{"source":"iana","extensions":["odft"]},"application/vnd.oasis.opendocument.graphics":{"source":"iana","compressible":false,"extensions":["odg"]},"application/vnd.oasis.opendocument.graphics-template":{"source":"iana","extensions":["otg"]},"application/vnd.oasis.opendocument.image":{"source":"iana","extensions":["odi"]},"application/vnd.oasis.opendocument.image-template":{"source":"iana","extensions":["oti"]},"application/vnd.oasis.opendocument.presentation":{"source":"iana","compressible":false,"extensions":["odp"]},"application/vnd.oasis.opendocument.presentation-template":{"source":"iana","extensions":["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{"source":"iana","compressible":false,"extensions":["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{"source":"iana","extensions":["ots"]},"application/vnd.oasis.opendocument.text":{"source":"iana","compressible":false,"extensions":["odt"]},"application/vnd.oasis.opendocument.text-master":{"source":"iana","extensions":["odm"]},"application/vnd.oasis.opendocument.text-template":{"source":"iana","extensions":["ott"]},"application/vnd.oasis.opendocument.text-web":{"source":"iana","extensions":["oth"]},"application/vnd.obn":{"source":"iana"},"application/vnd.ocf+cbor":{"source":"iana"},"application/vnd.oci.image.manifest.v1+json":{"source":"iana","compressible":true},"application/vnd.oftn.l10n+json":{"source":"iana","compressible":true},"application/vnd.oipf.contentaccessdownload+xml":{"source":"iana","compressible":true},"application/vnd.oipf.contentaccessstreaming+xml":{"source":"iana","compressible":true},"application/vnd.oipf.cspg-hexbinary":{"source":"iana"},"application/vnd.oipf.dae.svg+xml":{"source":"iana","compressible":true},"application/vnd.oipf.dae.xhtml+xml":{"source":"iana","compressible":true},"application/vnd.oipf.mippvcontrolmessage+xml":{"source":"iana","compressible":true},"application/vnd.oipf.pae.gem":{"source":"iana"},"application/vnd.oipf.spdiscovery+xml":{"source":"iana","compressible":true},"application/vnd.oipf.spdlist+xml":{"source":"iana","compressible":true},"application/vnd.oipf.ueprofile+xml":{"source":"iana","compressible":true},"application/vnd.oipf.userprofile+xml":{"source":"iana","compressible":true},"application/vnd.olpc-sugar":{"source":"iana","extensions":["xo"]},"application/vnd.oma-scws-config":{"source":"iana"},"application/vnd.oma-scws-http-request":{"source":"iana"},"application/vnd.oma-scws-http-response":{"source":"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.drm-trigger+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.imd+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.ltkm":{"source":"iana"},"application/vnd.oma.bcast.notification+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.provisioningtrigger":{"source":"iana"},"application/vnd.oma.bcast.sgboot":{"source":"iana"},"application/vnd.oma.bcast.sgdd+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.sgdu":{"source":"iana"},"application/vnd.oma.bcast.simple-symbol-container":{"source":"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.sprov+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.stkm":{"source":"iana"},"application/vnd.oma.cab-address-book+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-feature-handler+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-pcc+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-subs-invite+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-user-prefs+xml":{"source":"iana","compressible":true},"application/vnd.oma.dcd":{"source":"iana"},"application/vnd.oma.dcdc":{"source":"iana"},"application/vnd.oma.dd2+xml":{"source":"iana","compressible":true,"extensions":["dd2"]},"application/vnd.oma.drm.risd+xml":{"source":"iana","compressible":true},"application/vnd.oma.group-usage-list+xml":{"source":"iana","compressible":true},"application/vnd.oma.lwm2m+cbor":{"source":"iana"},"application/vnd.oma.lwm2m+json":{"source":"iana","compressible":true},"application/vnd.oma.lwm2m+tlv":{"source":"iana"},"application/vnd.oma.pal+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.detailed-progress-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.final-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.groups+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.invocation-descriptor+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.optimized-progress-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.push":{"source":"iana"},"application/vnd.oma.scidm.messages+xml":{"source":"iana","compressible":true},"application/vnd.oma.xcap-directory+xml":{"source":"iana","compressible":true},"application/vnd.omads-email+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omads-file+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omads-folder+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omaloc-supl-init":{"source":"iana"},"application/vnd.onepager":{"source":"iana"},"application/vnd.onepagertamp":{"source":"iana"},"application/vnd.onepagertamx":{"source":"iana"},"application/vnd.onepagertat":{"source":"iana"},"application/vnd.onepagertatp":{"source":"iana"},"application/vnd.onepagertatx":{"source":"iana"},"application/vnd.openblox.game+xml":{"source":"iana","compressible":true,"extensions":["obgx"]},"application/vnd.openblox.game-binary":{"source":"iana"},"application/vnd.openeye.oeb":{"source":"iana"},"application/vnd.openofficeorg.extension":{"source":"apache","extensions":["oxt"]},"application/vnd.openstreetmap.data+xml":{"source":"iana","compressible":true,"extensions":["osm"]},"application/vnd.opentimestamps.ots":{"source":"iana"},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawing+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{"source":"iana","compressible":false,"extensions":["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slide":{"source":"iana","extensions":["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{"source":"iana","extensions":["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.template":{"source":"iana","extensions":["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{"source":"iana","compressible":false,"extensions":["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{"source":"iana","extensions":["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.theme+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.vmldrawing":{"source":"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{"source":"iana","compressible":false,"extensions":["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{"source":"iana","extensions":["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.core-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.relationships+xml":{"source":"iana","compressible":true},"application/vnd.oracle.resource+json":{"source":"iana","compressible":true},"application/vnd.orange.indata":{"source":"iana"},"application/vnd.osa.netdeploy":{"source":"iana"},"application/vnd.osgeo.mapguide.package":{"source":"iana","extensions":["mgp"]},"application/vnd.osgi.bundle":{"source":"iana"},"application/vnd.osgi.dp":{"source":"iana","extensions":["dp"]},"application/vnd.osgi.subsystem":{"source":"iana","extensions":["esa"]},"application/vnd.otps.ct-kip+xml":{"source":"iana","compressible":true},"application/vnd.oxli.countgraph":{"source":"iana"},"application/vnd.pagerduty+json":{"source":"iana","compressible":true},"application/vnd.palm":{"source":"iana","extensions":["pdb","pqa","oprc"]},"application/vnd.panoply":{"source":"iana"},"application/vnd.paos.xml":{"source":"iana"},"application/vnd.patentdive":{"source":"iana"},"application/vnd.patientecommsdoc":{"source":"iana"},"application/vnd.pawaafile":{"source":"iana","extensions":["paw"]},"application/vnd.pcos":{"source":"iana"},"application/vnd.pg.format":{"source":"iana","extensions":["str"]},"application/vnd.pg.osasli":{"source":"iana","extensions":["ei6"]},"application/vnd.piaccess.application-licence":{"source":"iana"},"application/vnd.picsel":{"source":"iana","extensions":["efif"]},"application/vnd.pmi.widget":{"source":"iana","extensions":["wg"]},"application/vnd.poc.group-advertisement+xml":{"source":"iana","compressible":true},"application/vnd.pocketlearn":{"source":"iana","extensions":["plf"]},"application/vnd.powerbuilder6":{"source":"iana","extensions":["pbd"]},"application/vnd.powerbuilder6-s":{"source":"iana"},"application/vnd.powerbuilder7":{"source":"iana"},"application/vnd.powerbuilder7-s":{"source":"iana"},"application/vnd.powerbuilder75":{"source":"iana"},"application/vnd.powerbuilder75-s":{"source":"iana"},"application/vnd.preminet":{"source":"iana"},"application/vnd.previewsystems.box":{"source":"iana","extensions":["box"]},"application/vnd.proteus.magazine":{"source":"iana","extensions":["mgz"]},"application/vnd.psfs":{"source":"iana"},"application/vnd.publishare-delta-tree":{"source":"iana","extensions":["qps"]},"application/vnd.pvi.ptid1":{"source":"iana","extensions":["ptid"]},"application/vnd.pwg-multiplexed":{"source":"iana"},"application/vnd.pwg-xhtml-print+xml":{"source":"iana","compressible":true},"application/vnd.qualcomm.brew-app-res":{"source":"iana"},"application/vnd.quarantainenet":{"source":"iana"},"application/vnd.quark.quarkxpress":{"source":"iana","extensions":["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{"source":"iana"},"application/vnd.radisys.moml+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-conf+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-conn+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-dialog+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-stream+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-conf+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-base+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-fax-detect+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-group+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-speech+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-transform+xml":{"source":"iana","compressible":true},"application/vnd.rainstor.data":{"source":"iana"},"application/vnd.rapid":{"source":"iana"},"application/vnd.rar":{"source":"iana","extensions":["rar"]},"application/vnd.realvnc.bed":{"source":"iana","extensions":["bed"]},"application/vnd.recordare.musicxml":{"source":"iana","extensions":["mxl"]},"application/vnd.recordare.musicxml+xml":{"source":"iana","compressible":true,"extensions":["musicxml"]},"application/vnd.renlearn.rlprint":{"source":"iana"},"application/vnd.resilient.logic":{"source":"iana"},"application/vnd.restful+json":{"source":"iana","compressible":true},"application/vnd.rig.cryptonote":{"source":"iana","extensions":["cryptonote"]},"application/vnd.rim.cod":{"source":"apache","extensions":["cod"]},"application/vnd.rn-realmedia":{"source":"apache","extensions":["rm"]},"application/vnd.rn-realmedia-vbr":{"source":"apache","extensions":["rmvb"]},"application/vnd.route66.link66+xml":{"source":"iana","compressible":true,"extensions":["link66"]},"application/vnd.rs-274x":{"source":"iana"},"application/vnd.ruckus.download":{"source":"iana"},"application/vnd.s3sms":{"source":"iana"},"application/vnd.sailingtracker.track":{"source":"iana","extensions":["st"]},"application/vnd.sar":{"source":"iana"},"application/vnd.sbm.cid":{"source":"iana"},"application/vnd.sbm.mid2":{"source":"iana"},"application/vnd.scribus":{"source":"iana"},"application/vnd.sealed.3df":{"source":"iana"},"application/vnd.sealed.csf":{"source":"iana"},"application/vnd.sealed.doc":{"source":"iana"},"application/vnd.sealed.eml":{"source":"iana"},"application/vnd.sealed.mht":{"source":"iana"},"application/vnd.sealed.net":{"source":"iana"},"application/vnd.sealed.ppt":{"source":"iana"},"application/vnd.sealed.tiff":{"source":"iana"},"application/vnd.sealed.xls":{"source":"iana"},"application/vnd.sealedmedia.softseal.html":{"source":"iana"},"application/vnd.sealedmedia.softseal.pdf":{"source":"iana"},"application/vnd.seemail":{"source":"iana","extensions":["see"]},"application/vnd.seis+json":{"source":"iana","compressible":true},"application/vnd.sema":{"source":"iana","extensions":["sema"]},"application/vnd.semd":{"source":"iana","extensions":["semd"]},"application/vnd.semf":{"source":"iana","extensions":["semf"]},"application/vnd.shade-save-file":{"source":"iana"},"application/vnd.shana.informed.formdata":{"source":"iana","extensions":["ifm"]},"application/vnd.shana.informed.formtemplate":{"source":"iana","extensions":["itp"]},"application/vnd.shana.informed.interchange":{"source":"iana","extensions":["iif"]},"application/vnd.shana.informed.package":{"source":"iana","extensions":["ipk"]},"application/vnd.shootproof+json":{"source":"iana","compressible":true},"application/vnd.shopkick+json":{"source":"iana","compressible":true},"application/vnd.shp":{"source":"iana"},"application/vnd.shx":{"source":"iana"},"application/vnd.sigrok.session":{"source":"iana"},"application/vnd.simtech-mindmapper":{"source":"iana","extensions":["twd","twds"]},"application/vnd.siren+json":{"source":"iana","compressible":true},"application/vnd.smaf":{"source":"iana","extensions":["mmf"]},"application/vnd.smart.notebook":{"source":"iana"},"application/vnd.smart.teacher":{"source":"iana","extensions":["teacher"]},"application/vnd.snesdev-page-table":{"source":"iana"},"application/vnd.software602.filler.form+xml":{"source":"iana","compressible":true,"extensions":["fo"]},"application/vnd.software602.filler.form-xml-zip":{"source":"iana"},"application/vnd.solent.sdkm+xml":{"source":"iana","compressible":true,"extensions":["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{"source":"iana","extensions":["dxp"]},"application/vnd.spotfire.sfs":{"source":"iana","extensions":["sfs"]},"application/vnd.sqlite3":{"source":"iana"},"application/vnd.sss-cod":{"source":"iana"},"application/vnd.sss-dtf":{"source":"iana"},"application/vnd.sss-ntf":{"source":"iana"},"application/vnd.stardivision.calc":{"source":"apache","extensions":["sdc"]},"application/vnd.stardivision.draw":{"source":"apache","extensions":["sda"]},"application/vnd.stardivision.impress":{"source":"apache","extensions":["sdd"]},"application/vnd.stardivision.math":{"source":"apache","extensions":["smf"]},"application/vnd.stardivision.writer":{"source":"apache","extensions":["sdw","vor"]},"application/vnd.stardivision.writer-global":{"source":"apache","extensions":["sgl"]},"application/vnd.stepmania.package":{"source":"iana","extensions":["smzip"]},"application/vnd.stepmania.stepchart":{"source":"iana","extensions":["sm"]},"application/vnd.street-stream":{"source":"iana"},"application/vnd.sun.wadl+xml":{"source":"iana","compressible":true,"extensions":["wadl"]},"application/vnd.sun.xml.calc":{"source":"apache","extensions":["sxc"]},"application/vnd.sun.xml.calc.template":{"source":"apache","extensions":["stc"]},"application/vnd.sun.xml.draw":{"source":"apache","extensions":["sxd"]},"application/vnd.sun.xml.draw.template":{"source":"apache","extensions":["std"]},"application/vnd.sun.xml.impress":{"source":"apache","extensions":["sxi"]},"application/vnd.sun.xml.impress.template":{"source":"apache","extensions":["sti"]},"application/vnd.sun.xml.math":{"source":"apache","extensions":["sxm"]},"application/vnd.sun.xml.writer":{"source":"apache","extensions":["sxw"]},"application/vnd.sun.xml.writer.global":{"source":"apache","extensions":["sxg"]},"application/vnd.sun.xml.writer.template":{"source":"apache","extensions":["stw"]},"application/vnd.sus-calendar":{"source":"iana","extensions":["sus","susp"]},"application/vnd.svd":{"source":"iana","extensions":["svd"]},"application/vnd.swiftview-ics":{"source":"iana"},"application/vnd.sycle+xml":{"source":"iana","compressible":true},"application/vnd.syft+json":{"source":"iana","compressible":true},"application/vnd.symbian.install":{"source":"apache","extensions":["sis","sisx"]},"application/vnd.syncml+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["xsm"]},"application/vnd.syncml.dm+wbxml":{"source":"iana","charset":"UTF-8","extensions":["bdm"]},"application/vnd.syncml.dm+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["xdm"]},"application/vnd.syncml.dm.notification":{"source":"iana"},"application/vnd.syncml.dmddf+wbxml":{"source":"iana"},"application/vnd.syncml.dmddf+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["ddf"]},"application/vnd.syncml.dmtnds+wbxml":{"source":"iana"},"application/vnd.syncml.dmtnds+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.syncml.ds.notification":{"source":"iana"},"application/vnd.tableschema+json":{"source":"iana","compressible":true},"application/vnd.tao.intent-module-archive":{"source":"iana","extensions":["tao"]},"application/vnd.tcpdump.pcap":{"source":"iana","extensions":["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{"source":"iana","compressible":true},"application/vnd.tmd.mediaflex.api+xml":{"source":"iana","compressible":true},"application/vnd.tml":{"source":"iana"},"application/vnd.tmobile-livetv":{"source":"iana","extensions":["tmo"]},"application/vnd.tri.onesource":{"source":"iana"},"application/vnd.trid.tpt":{"source":"iana","extensions":["tpt"]},"application/vnd.triscape.mxs":{"source":"iana","extensions":["mxs"]},"application/vnd.trueapp":{"source":"iana","extensions":["tra"]},"application/vnd.truedoc":{"source":"iana"},"application/vnd.ubisoft.webplayer":{"source":"iana"},"application/vnd.ufdl":{"source":"iana","extensions":["ufd","ufdl"]},"application/vnd.uiq.theme":{"source":"iana","extensions":["utz"]},"application/vnd.umajin":{"source":"iana","extensions":["umj"]},"application/vnd.unity":{"source":"iana","extensions":["unityweb"]},"application/vnd.uoml+xml":{"source":"iana","compressible":true,"extensions":["uoml"]},"application/vnd.uplanet.alert":{"source":"iana"},"application/vnd.uplanet.alert-wbxml":{"source":"iana"},"application/vnd.uplanet.bearer-choice":{"source":"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{"source":"iana"},"application/vnd.uplanet.cacheop":{"source":"iana"},"application/vnd.uplanet.cacheop-wbxml":{"source":"iana"},"application/vnd.uplanet.channel":{"source":"iana"},"application/vnd.uplanet.channel-wbxml":{"source":"iana"},"application/vnd.uplanet.list":{"source":"iana"},"application/vnd.uplanet.list-wbxml":{"source":"iana"},"application/vnd.uplanet.listcmd":{"source":"iana"},"application/vnd.uplanet.listcmd-wbxml":{"source":"iana"},"application/vnd.uplanet.signal":{"source":"iana"},"application/vnd.uri-map":{"source":"iana"},"application/vnd.valve.source.material":{"source":"iana"},"application/vnd.vcx":{"source":"iana","extensions":["vcx"]},"application/vnd.vd-study":{"source":"iana"},"application/vnd.vectorworks":{"source":"iana"},"application/vnd.vel+json":{"source":"iana","compressible":true},"application/vnd.verimatrix.vcas":{"source":"iana"},"application/vnd.veritone.aion+json":{"source":"iana","compressible":true},"application/vnd.veryant.thin":{"source":"iana"},"application/vnd.ves.encrypted":{"source":"iana"},"application/vnd.vidsoft.vidconference":{"source":"iana"},"application/vnd.visio":{"source":"iana","extensions":["vsd","vst","vss","vsw"]},"application/vnd.visionary":{"source":"iana","extensions":["vis"]},"application/vnd.vividence.scriptfile":{"source":"iana"},"application/vnd.vsf":{"source":"iana","extensions":["vsf"]},"application/vnd.wap.sic":{"source":"iana"},"application/vnd.wap.slc":{"source":"iana"},"application/vnd.wap.wbxml":{"source":"iana","charset":"UTF-8","extensions":["wbxml"]},"application/vnd.wap.wmlc":{"source":"iana","extensions":["wmlc"]},"application/vnd.wap.wmlscriptc":{"source":"iana","extensions":["wmlsc"]},"application/vnd.webturbo":{"source":"iana","extensions":["wtb"]},"application/vnd.wfa.dpp":{"source":"iana"},"application/vnd.wfa.p2p":{"source":"iana"},"application/vnd.wfa.wsc":{"source":"iana"},"application/vnd.windows.devicepairing":{"source":"iana"},"application/vnd.wmc":{"source":"iana"},"application/vnd.wmf.bootstrap":{"source":"iana"},"application/vnd.wolfram.mathematica":{"source":"iana"},"application/vnd.wolfram.mathematica.package":{"source":"iana"},"application/vnd.wolfram.player":{"source":"iana","extensions":["nbp"]},"application/vnd.wordperfect":{"source":"iana","extensions":["wpd"]},"application/vnd.wqd":{"source":"iana","extensions":["wqd"]},"application/vnd.wrq-hp3000-labelled":{"source":"iana"},"application/vnd.wt.stf":{"source":"iana","extensions":["stf"]},"application/vnd.wv.csp+wbxml":{"source":"iana"},"application/vnd.wv.csp+xml":{"source":"iana","compressible":true},"application/vnd.wv.ssp+xml":{"source":"iana","compressible":true},"application/vnd.xacml+json":{"source":"iana","compressible":true},"application/vnd.xara":{"source":"iana","extensions":["xar"]},"application/vnd.xfdl":{"source":"iana","extensions":["xfdl"]},"application/vnd.xfdl.webform":{"source":"iana"},"application/vnd.xmi+xml":{"source":"iana","compressible":true},"application/vnd.xmpie.cpkg":{"source":"iana"},"application/vnd.xmpie.dpkg":{"source":"iana"},"application/vnd.xmpie.plan":{"source":"iana"},"application/vnd.xmpie.ppkg":{"source":"iana"},"application/vnd.xmpie.xlim":{"source":"iana"},"application/vnd.yamaha.hv-dic":{"source":"iana","extensions":["hvd"]},"application/vnd.yamaha.hv-script":{"source":"iana","extensions":["hvs"]},"application/vnd.yamaha.hv-voice":{"source":"iana","extensions":["hvp"]},"application/vnd.yamaha.openscoreformat":{"source":"iana","extensions":["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{"source":"iana","compressible":true,"extensions":["osfpvg"]},"application/vnd.yamaha.remote-setup":{"source":"iana"},"application/vnd.yamaha.smaf-audio":{"source":"iana","extensions":["saf"]},"application/vnd.yamaha.smaf-phrase":{"source":"iana","extensions":["spf"]},"application/vnd.yamaha.through-ngn":{"source":"iana"},"application/vnd.yamaha.tunnel-udpencap":{"source":"iana"},"application/vnd.yaoweme":{"source":"iana"},"application/vnd.yellowriver-custom-menu":{"source":"iana","extensions":["cmp"]},"application/vnd.youtube.yt":{"source":"iana"},"application/vnd.zul":{"source":"iana","extensions":["zir","zirz"]},"application/vnd.zzazz.deck+xml":{"source":"iana","compressible":true,"extensions":["zaz"]},"application/voicexml+xml":{"source":"iana","compressible":true,"extensions":["vxml"]},"application/voucher-cms+json":{"source":"iana","compressible":true},"application/vq-rtcpxr":{"source":"iana"},"application/wasm":{"source":"iana","compressible":true,"extensions":["wasm"]},"application/watcherinfo+xml":{"source":"iana","compressible":true,"extensions":["wif"]},"application/webpush-options+json":{"source":"iana","compressible":true},"application/whoispp-query":{"source":"iana"},"application/whoispp-response":{"source":"iana"},"application/widget":{"source":"iana","extensions":["wgt"]},"application/winhlp":{"source":"apache","extensions":["hlp"]},"application/wita":{"source":"iana"},"application/wordperfect5.1":{"source":"iana"},"application/wsdl+xml":{"source":"iana","compressible":true,"extensions":["wsdl"]},"application/wspolicy+xml":{"source":"iana","compressible":true,"extensions":["wspolicy"]},"application/x-7z-compressed":{"source":"apache","compressible":false,"extensions":["7z"]},"application/x-abiword":{"source":"apache","extensions":["abw"]},"application/x-ace-compressed":{"source":"apache","extensions":["ace"]},"application/x-amf":{"source":"apache"},"application/x-apple-diskimage":{"source":"apache","extensions":["dmg"]},"application/x-arj":{"compressible":false,"extensions":["arj"]},"application/x-authorware-bin":{"source":"apache","extensions":["aab","x32","u32","vox"]},"application/x-authorware-map":{"source":"apache","extensions":["aam"]},"application/x-authorware-seg":{"source":"apache","extensions":["aas"]},"application/x-bcpio":{"source":"apache","extensions":["bcpio"]},"application/x-bdoc":{"compressible":false,"extensions":["bdoc"]},"application/x-bittorrent":{"source":"apache","extensions":["torrent"]},"application/x-blorb":{"source":"apache","extensions":["blb","blorb"]},"application/x-bzip":{"source":"apache","compressible":false,"extensions":["bz"]},"application/x-bzip2":{"source":"apache","compressible":false,"extensions":["bz2","boz"]},"application/x-cbr":{"source":"apache","extensions":["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{"source":"apache","extensions":["vcd"]},"application/x-cfs-compressed":{"source":"apache","extensions":["cfs"]},"application/x-chat":{"source":"apache","extensions":["chat"]},"application/x-chess-pgn":{"source":"apache","extensions":["pgn"]},"application/x-chrome-extension":{"extensions":["crx"]},"application/x-cocoa":{"source":"nginx","extensions":["cco"]},"application/x-compress":{"source":"apache"},"application/x-conference":{"source":"apache","extensions":["nsc"]},"application/x-cpio":{"source":"apache","extensions":["cpio"]},"application/x-csh":{"source":"apache","extensions":["csh"]},"application/x-deb":{"compressible":false},"application/x-debian-package":{"source":"apache","extensions":["deb","udeb"]},"application/x-dgc-compressed":{"source":"apache","extensions":["dgc"]},"application/x-director":{"source":"apache","extensions":["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{"source":"apache","extensions":["wad"]},"application/x-dtbncx+xml":{"source":"apache","compressible":true,"extensions":["ncx"]},"application/x-dtbook+xml":{"source":"apache","compressible":true,"extensions":["dtb"]},"application/x-dtbresource+xml":{"source":"apache","compressible":true,"extensions":["res"]},"application/x-dvi":{"source":"apache","compressible":false,"extensions":["dvi"]},"application/x-envoy":{"source":"apache","extensions":["evy"]},"application/x-eva":{"source":"apache","extensions":["eva"]},"application/x-font-bdf":{"source":"apache","extensions":["bdf"]},"application/x-font-dos":{"source":"apache"},"application/x-font-framemaker":{"source":"apache"},"application/x-font-ghostscript":{"source":"apache","extensions":["gsf"]},"application/x-font-libgrx":{"source":"apache"},"application/x-font-linux-psf":{"source":"apache","extensions":["psf"]},"application/x-font-pcf":{"source":"apache","extensions":["pcf"]},"application/x-font-snf":{"source":"apache","extensions":["snf"]},"application/x-font-speedo":{"source":"apache"},"application/x-font-sunos-news":{"source":"apache"},"application/x-font-type1":{"source":"apache","extensions":["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{"source":"apache"},"application/x-freearc":{"source":"apache","extensions":["arc"]},"application/x-futuresplash":{"source":"apache","extensions":["spl"]},"application/x-gca-compressed":{"source":"apache","extensions":["gca"]},"application/x-glulx":{"source":"apache","extensions":["ulx"]},"application/x-gnumeric":{"source":"apache","extensions":["gnumeric"]},"application/x-gramps-xml":{"source":"apache","extensions":["gramps"]},"application/x-gtar":{"source":"apache","extensions":["gtar"]},"application/x-gzip":{"source":"apache"},"application/x-hdf":{"source":"apache","extensions":["hdf"]},"application/x-httpd-php":{"compressible":true,"extensions":["php"]},"application/x-install-instructions":{"source":"apache","extensions":["install"]},"application/x-iso9660-image":{"source":"apache","extensions":["iso"]},"application/x-iwork-keynote-sffkey":{"extensions":["key"]},"application/x-iwork-numbers-sffnumbers":{"extensions":["numbers"]},"application/x-iwork-pages-sffpages":{"extensions":["pages"]},"application/x-java-archive-diff":{"source":"nginx","extensions":["jardiff"]},"application/x-java-jnlp-file":{"source":"apache","compressible":false,"extensions":["jnlp"]},"application/x-javascript":{"compressible":true},"application/x-keepass2":{"extensions":["kdbx"]},"application/x-latex":{"source":"apache","compressible":false,"extensions":["latex"]},"application/x-lua-bytecode":{"extensions":["luac"]},"application/x-lzh-compressed":{"source":"apache","extensions":["lzh","lha"]},"application/x-makeself":{"source":"nginx","extensions":["run"]},"application/x-mie":{"source":"apache","extensions":["mie"]},"application/x-mobipocket-ebook":{"source":"apache","extensions":["prc","mobi"]},"application/x-mpegurl":{"compressible":false},"application/x-ms-application":{"source":"apache","extensions":["application"]},"application/x-ms-shortcut":{"source":"apache","extensions":["lnk"]},"application/x-ms-wmd":{"source":"apache","extensions":["wmd"]},"application/x-ms-wmz":{"source":"apache","extensions":["wmz"]},"application/x-ms-xbap":{"source":"apache","extensions":["xbap"]},"application/x-msaccess":{"source":"apache","extensions":["mdb"]},"application/x-msbinder":{"source":"apache","extensions":["obd"]},"application/x-mscardfile":{"source":"apache","extensions":["crd"]},"application/x-msclip":{"source":"apache","extensions":["clp"]},"application/x-msdos-program":{"extensions":["exe"]},"application/x-msdownload":{"source":"apache","extensions":["exe","dll","com","bat","msi"]},"application/x-msmediaview":{"source":"apache","extensions":["mvb","m13","m14"]},"application/x-msmetafile":{"source":"apache","extensions":["wmf","wmz","emf","emz"]},"application/x-msmoney":{"source":"apache","extensions":["mny"]},"application/x-mspublisher":{"source":"apache","extensions":["pub"]},"application/x-msschedule":{"source":"apache","extensions":["scd"]},"application/x-msterminal":{"source":"apache","extensions":["trm"]},"application/x-mswrite":{"source":"apache","extensions":["wri"]},"application/x-netcdf":{"source":"apache","extensions":["nc","cdf"]},"application/x-ns-proxy-autoconfig":{"compressible":true,"extensions":["pac"]},"application/x-nzb":{"source":"apache","extensions":["nzb"]},"application/x-perl":{"source":"nginx","extensions":["pl","pm"]},"application/x-pilot":{"source":"nginx","extensions":["prc","pdb"]},"application/x-pkcs12":{"source":"apache","compressible":false,"extensions":["p12","pfx"]},"application/x-pkcs7-certificates":{"source":"apache","extensions":["p7b","spc"]},"application/x-pkcs7-certreqresp":{"source":"apache","extensions":["p7r"]},"application/x-pki-message":{"source":"iana"},"application/x-rar-compressed":{"source":"apache","compressible":false,"extensions":["rar"]},"application/x-redhat-package-manager":{"source":"nginx","extensions":["rpm"]},"application/x-research-info-systems":{"source":"apache","extensions":["ris"]},"application/x-sea":{"source":"nginx","extensions":["sea"]},"application/x-sh":{"source":"apache","compressible":true,"extensions":["sh"]},"application/x-shar":{"source":"apache","extensions":["shar"]},"application/x-shockwave-flash":{"source":"apache","compressible":false,"extensions":["swf"]},"application/x-silverlight-app":{"source":"apache","extensions":["xap"]},"application/x-sql":{"source":"apache","extensions":["sql"]},"application/x-stuffit":{"source":"apache","compressible":false,"extensions":["sit"]},"application/x-stuffitx":{"source":"apache","extensions":["sitx"]},"application/x-subrip":{"source":"apache","extensions":["srt"]},"application/x-sv4cpio":{"source":"apache","extensions":["sv4cpio"]},"application/x-sv4crc":{"source":"apache","extensions":["sv4crc"]},"application/x-t3vm-image":{"source":"apache","extensions":["t3"]},"application/x-tads":{"source":"apache","extensions":["gam"]},"application/x-tar":{"source":"apache","compressible":true,"extensions":["tar"]},"application/x-tcl":{"source":"apache","extensions":["tcl","tk"]},"application/x-tex":{"source":"apache","extensions":["tex"]},"application/x-tex-tfm":{"source":"apache","extensions":["tfm"]},"application/x-texinfo":{"source":"apache","extensions":["texinfo","texi"]},"application/x-tgif":{"source":"apache","extensions":["obj"]},"application/x-ustar":{"source":"apache","extensions":["ustar"]},"application/x-virtualbox-hdd":{"compressible":true,"extensions":["hdd"]},"application/x-virtualbox-ova":{"compressible":true,"extensions":["ova"]},"application/x-virtualbox-ovf":{"compressible":true,"extensions":["ovf"]},"application/x-virtualbox-vbox":{"compressible":true,"extensions":["vbox"]},"application/x-virtualbox-vbox-extpack":{"compressible":false,"extensions":["vbox-extpack"]},"application/x-virtualbox-vdi":{"compressible":true,"extensions":["vdi"]},"application/x-virtualbox-vhd":{"compressible":true,"extensions":["vhd"]},"application/x-virtualbox-vmdk":{"compressible":true,"extensions":["vmdk"]},"application/x-wais-source":{"source":"apache","extensions":["src"]},"application/x-web-app-manifest+json":{"compressible":true,"extensions":["webapp"]},"application/x-www-form-urlencoded":{"source":"iana","compressible":true},"application/x-x509-ca-cert":{"source":"iana","extensions":["der","crt","pem"]},"application/x-x509-ca-ra-cert":{"source":"iana"},"application/x-x509-next-ca-cert":{"source":"iana"},"application/x-xfig":{"source":"apache","extensions":["fig"]},"application/x-xliff+xml":{"source":"apache","compressible":true,"extensions":["xlf"]},"application/x-xpinstall":{"source":"apache","compressible":false,"extensions":["xpi"]},"application/x-xz":{"source":"apache","extensions":["xz"]},"application/x-zmachine":{"source":"apache","extensions":["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{"source":"iana"},"application/xacml+xml":{"source":"iana","compressible":true},"application/xaml+xml":{"source":"apache","compressible":true,"extensions":["xaml"]},"application/xcap-att+xml":{"source":"iana","compressible":true,"extensions":["xav"]},"application/xcap-caps+xml":{"source":"iana","compressible":true,"extensions":["xca"]},"application/xcap-diff+xml":{"source":"iana","compressible":true,"extensions":["xdf"]},"application/xcap-el+xml":{"source":"iana","compressible":true,"extensions":["xel"]},"application/xcap-error+xml":{"source":"iana","compressible":true},"application/xcap-ns+xml":{"source":"iana","compressible":true,"extensions":["xns"]},"application/xcon-conference-info+xml":{"source":"iana","compressible":true},"application/xcon-conference-info-diff+xml":{"source":"iana","compressible":true},"application/xenc+xml":{"source":"iana","compressible":true,"extensions":["xenc"]},"application/xhtml+xml":{"source":"iana","compressible":true,"extensions":["xhtml","xht"]},"application/xhtml-voice+xml":{"source":"apache","compressible":true},"application/xliff+xml":{"source":"iana","compressible":true,"extensions":["xlf"]},"application/xml":{"source":"iana","compressible":true,"extensions":["xml","xsl","xsd","rng"]},"application/xml-dtd":{"source":"iana","compressible":true,"extensions":["dtd"]},"application/xml-external-parsed-entity":{"source":"iana"},"application/xml-patch+xml":{"source":"iana","compressible":true},"application/xmpp+xml":{"source":"iana","compressible":true},"application/xop+xml":{"source":"iana","compressible":true,"extensions":["xop"]},"application/xproc+xml":{"source":"apache","compressible":true,"extensions":["xpl"]},"application/xslt+xml":{"source":"iana","compressible":true,"extensions":["xsl","xslt"]},"application/xspf+xml":{"source":"apache","compressible":true,"extensions":["xspf"]},"application/xv+xml":{"source":"iana","compressible":true,"extensions":["mxml","xhvml","xvml","xvm"]},"application/yang":{"source":"iana","extensions":["yang"]},"application/yang-data+json":{"source":"iana","compressible":true},"application/yang-data+xml":{"source":"iana","compressible":true},"application/yang-patch+json":{"source":"iana","compressible":true},"application/yang-patch+xml":{"source":"iana","compressible":true},"application/yin+xml":{"source":"iana","compressible":true,"extensions":["yin"]},"application/zip":{"source":"iana","compressible":false,"extensions":["zip"]},"application/zlib":{"source":"iana"},"application/zstd":{"source":"iana"},"audio/1d-interleaved-parityfec":{"source":"iana"},"audio/32kadpcm":{"source":"iana"},"audio/3gpp":{"source":"iana","compressible":false,"extensions":["3gpp"]},"audio/3gpp2":{"source":"iana"},"audio/aac":{"source":"iana"},"audio/ac3":{"source":"iana"},"audio/adpcm":{"source":"apache","extensions":["adp"]},"audio/amr":{"source":"iana","extensions":["amr"]},"audio/amr-wb":{"source":"iana"},"audio/amr-wb+":{"source":"iana"},"audio/aptx":{"source":"iana"},"audio/asc":{"source":"iana"},"audio/atrac-advanced-lossless":{"source":"iana"},"audio/atrac-x":{"source":"iana"},"audio/atrac3":{"source":"iana"},"audio/basic":{"source":"iana","compressible":false,"extensions":["au","snd"]},"audio/bv16":{"source":"iana"},"audio/bv32":{"source":"iana"},"audio/clearmode":{"source":"iana"},"audio/cn":{"source":"iana"},"audio/dat12":{"source":"iana"},"audio/dls":{"source":"iana"},"audio/dsr-es201108":{"source":"iana"},"audio/dsr-es202050":{"source":"iana"},"audio/dsr-es202211":{"source":"iana"},"audio/dsr-es202212":{"source":"iana"},"audio/dv":{"source":"iana"},"audio/dvi4":{"source":"iana"},"audio/eac3":{"source":"iana"},"audio/encaprtp":{"source":"iana"},"audio/evrc":{"source":"iana"},"audio/evrc-qcp":{"source":"iana"},"audio/evrc0":{"source":"iana"},"audio/evrc1":{"source":"iana"},"audio/evrcb":{"source":"iana"},"audio/evrcb0":{"source":"iana"},"audio/evrcb1":{"source":"iana"},"audio/evrcnw":{"source":"iana"},"audio/evrcnw0":{"source":"iana"},"audio/evrcnw1":{"source":"iana"},"audio/evrcwb":{"source":"iana"},"audio/evrcwb0":{"source":"iana"},"audio/evrcwb1":{"source":"iana"},"audio/evs":{"source":"iana"},"audio/flexfec":{"source":"iana"},"audio/fwdred":{"source":"iana"},"audio/g711-0":{"source":"iana"},"audio/g719":{"source":"iana"},"audio/g722":{"source":"iana"},"audio/g7221":{"source":"iana"},"audio/g723":{"source":"iana"},"audio/g726-16":{"source":"iana"},"audio/g726-24":{"source":"iana"},"audio/g726-32":{"source":"iana"},"audio/g726-40":{"source":"iana"},"audio/g728":{"source":"iana"},"audio/g729":{"source":"iana"},"audio/g7291":{"source":"iana"},"audio/g729d":{"source":"iana"},"audio/g729e":{"source":"iana"},"audio/gsm":{"source":"iana"},"audio/gsm-efr":{"source":"iana"},"audio/gsm-hr-08":{"source":"iana"},"audio/ilbc":{"source":"iana"},"audio/ip-mr_v2.5":{"source":"iana"},"audio/isac":{"source":"apache"},"audio/l16":{"source":"iana"},"audio/l20":{"source":"iana"},"audio/l24":{"source":"iana","compressible":false},"audio/l8":{"source":"iana"},"audio/lpc":{"source":"iana"},"audio/melp":{"source":"iana"},"audio/melp1200":{"source":"iana"},"audio/melp2400":{"source":"iana"},"audio/melp600":{"source":"iana"},"audio/mhas":{"source":"iana"},"audio/midi":{"source":"apache","extensions":["mid","midi","kar","rmi"]},"audio/mobile-xmf":{"source":"iana","extensions":["mxmf"]},"audio/mp3":{"compressible":false,"extensions":["mp3"]},"audio/mp4":{"source":"iana","compressible":false,"extensions":["m4a","mp4a"]},"audio/mp4a-latm":{"source":"iana"},"audio/mpa":{"source":"iana"},"audio/mpa-robust":{"source":"iana"},"audio/mpeg":{"source":"iana","compressible":false,"extensions":["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{"source":"iana"},"audio/musepack":{"source":"apache"},"audio/ogg":{"source":"iana","compressible":false,"extensions":["oga","ogg","spx","opus"]},"audio/opus":{"source":"iana"},"audio/parityfec":{"source":"iana"},"audio/pcma":{"source":"iana"},"audio/pcma-wb":{"source":"iana"},"audio/pcmu":{"source":"iana"},"audio/pcmu-wb":{"source":"iana"},"audio/prs.sid":{"source":"iana"},"audio/qcelp":{"source":"iana"},"audio/raptorfec":{"source":"iana"},"audio/red":{"source":"iana"},"audio/rtp-enc-aescm128":{"source":"iana"},"audio/rtp-midi":{"source":"iana"},"audio/rtploopback":{"source":"iana"},"audio/rtx":{"source":"iana"},"audio/s3m":{"source":"apache","extensions":["s3m"]},"audio/scip":{"source":"iana"},"audio/silk":{"source":"apache","extensions":["sil"]},"audio/smv":{"source":"iana"},"audio/smv-qcp":{"source":"iana"},"audio/smv0":{"source":"iana"},"audio/sofa":{"source":"iana"},"audio/sp-midi":{"source":"iana"},"audio/speex":{"source":"iana"},"audio/t140c":{"source":"iana"},"audio/t38":{"source":"iana"},"audio/telephone-event":{"source":"iana"},"audio/tetra_acelp":{"source":"iana"},"audio/tetra_acelp_bb":{"source":"iana"},"audio/tone":{"source":"iana"},"audio/tsvcis":{"source":"iana"},"audio/uemclip":{"source":"iana"},"audio/ulpfec":{"source":"iana"},"audio/usac":{"source":"iana"},"audio/vdvi":{"source":"iana"},"audio/vmr-wb":{"source":"iana"},"audio/vnd.3gpp.iufp":{"source":"iana"},"audio/vnd.4sb":{"source":"iana"},"audio/vnd.audiokoz":{"source":"iana"},"audio/vnd.celp":{"source":"iana"},"audio/vnd.cisco.nse":{"source":"iana"},"audio/vnd.cmles.radio-events":{"source":"iana"},"audio/vnd.cns.anp1":{"source":"iana"},"audio/vnd.cns.inf1":{"source":"iana"},"audio/vnd.dece.audio":{"source":"iana","extensions":["uva","uvva"]},"audio/vnd.digital-winds":{"source":"iana","extensions":["eol"]},"audio/vnd.dlna.adts":{"source":"iana"},"audio/vnd.dolby.heaac.1":{"source":"iana"},"audio/vnd.dolby.heaac.2":{"source":"iana"},"audio/vnd.dolby.mlp":{"source":"iana"},"audio/vnd.dolby.mps":{"source":"iana"},"audio/vnd.dolby.pl2":{"source":"iana"},"audio/vnd.dolby.pl2x":{"source":"iana"},"audio/vnd.dolby.pl2z":{"source":"iana"},"audio/vnd.dolby.pulse.1":{"source":"iana"},"audio/vnd.dra":{"source":"iana","extensions":["dra"]},"audio/vnd.dts":{"source":"iana","extensions":["dts"]},"audio/vnd.dts.hd":{"source":"iana","extensions":["dtshd"]},"audio/vnd.dts.uhd":{"source":"iana"},"audio/vnd.dvb.file":{"source":"iana"},"audio/vnd.everad.plj":{"source":"iana"},"audio/vnd.hns.audio":{"source":"iana"},"audio/vnd.lucent.voice":{"source":"iana","extensions":["lvp"]},"audio/vnd.ms-playready.media.pya":{"source":"iana","extensions":["pya"]},"audio/vnd.nokia.mobile-xmf":{"source":"iana"},"audio/vnd.nortel.vbk":{"source":"iana"},"audio/vnd.nuera.ecelp4800":{"source":"iana","extensions":["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{"source":"iana","extensions":["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{"source":"iana","extensions":["ecelp9600"]},"audio/vnd.octel.sbc":{"source":"iana"},"audio/vnd.presonus.multitrack":{"source":"iana"},"audio/vnd.qcelp":{"source":"iana"},"audio/vnd.rhetorex.32kadpcm":{"source":"iana"},"audio/vnd.rip":{"source":"iana","extensions":["rip"]},"audio/vnd.rn-realaudio":{"compressible":false},"audio/vnd.sealedmedia.softseal.mpeg":{"source":"iana"},"audio/vnd.vmx.cvsd":{"source":"iana"},"audio/vnd.wave":{"compressible":false},"audio/vorbis":{"source":"iana","compressible":false},"audio/vorbis-config":{"source":"iana"},"audio/wav":{"compressible":false,"extensions":["wav"]},"audio/wave":{"compressible":false,"extensions":["wav"]},"audio/webm":{"source":"apache","compressible":false,"extensions":["weba"]},"audio/x-aac":{"source":"apache","compressible":false,"extensions":["aac"]},"audio/x-aiff":{"source":"apache","extensions":["aif","aiff","aifc"]},"audio/x-caf":{"source":"apache","compressible":false,"extensions":["caf"]},"audio/x-flac":{"source":"apache","extensions":["flac"]},"audio/x-m4a":{"source":"nginx","extensions":["m4a"]},"audio/x-matroska":{"source":"apache","extensions":["mka"]},"audio/x-mpegurl":{"source":"apache","extensions":["m3u"]},"audio/x-ms-wax":{"source":"apache","extensions":["wax"]},"audio/x-ms-wma":{"source":"apache","extensions":["wma"]},"audio/x-pn-realaudio":{"source":"apache","extensions":["ram","ra"]},"audio/x-pn-realaudio-plugin":{"source":"apache","extensions":["rmp"]},"audio/x-realaudio":{"source":"nginx","extensions":["ra"]},"audio/x-tta":{"source":"apache"},"audio/x-wav":{"source":"apache","extensions":["wav"]},"audio/xm":{"source":"apache","extensions":["xm"]},"chemical/x-cdx":{"source":"apache","extensions":["cdx"]},"chemical/x-cif":{"source":"apache","extensions":["cif"]},"chemical/x-cmdf":{"source":"apache","extensions":["cmdf"]},"chemical/x-cml":{"source":"apache","extensions":["cml"]},"chemical/x-csml":{"source":"apache","extensions":["csml"]},"chemical/x-pdb":{"source":"apache"},"chemical/x-xyz":{"source":"apache","extensions":["xyz"]},"font/collection":{"source":"iana","extensions":["ttc"]},"font/otf":{"source":"iana","compressible":true,"extensions":["otf"]},"font/sfnt":{"source":"iana"},"font/ttf":{"source":"iana","compressible":true,"extensions":["ttf"]},"font/woff":{"source":"iana","extensions":["woff"]},"font/woff2":{"source":"iana","extensions":["woff2"]},"image/aces":{"source":"iana","extensions":["exr"]},"image/apng":{"compressible":false,"extensions":["apng"]},"image/avci":{"source":"iana","extensions":["avci"]},"image/avcs":{"source":"iana","extensions":["avcs"]},"image/avif":{"source":"iana","compressible":false,"extensions":["avif"]},"image/bmp":{"source":"iana","compressible":true,"extensions":["bmp"]},"image/cgm":{"source":"iana","extensions":["cgm"]},"image/dicom-rle":{"source":"iana","extensions":["drle"]},"image/emf":{"source":"iana","extensions":["emf"]},"image/fits":{"source":"iana","extensions":["fits"]},"image/g3fax":{"source":"iana","extensions":["g3"]},"image/gif":{"source":"iana","compressible":false,"extensions":["gif"]},"image/heic":{"source":"iana","extensions":["heic"]},"image/heic-sequence":{"source":"iana","extensions":["heics"]},"image/heif":{"source":"iana","extensions":["heif"]},"image/heif-sequence":{"source":"iana","extensions":["heifs"]},"image/hej2k":{"source":"iana","extensions":["hej2"]},"image/hsj2":{"source":"iana","extensions":["hsj2"]},"image/ief":{"source":"iana","extensions":["ief"]},"image/jls":{"source":"iana","extensions":["jls"]},"image/jp2":{"source":"iana","compressible":false,"extensions":["jp2","jpg2"]},"image/jpeg":{"source":"iana","compressible":false,"extensions":["jpeg","jpg","jpe"]},"image/jph":{"source":"iana","extensions":["jph"]},"image/jphc":{"source":"iana","extensions":["jhc"]},"image/jpm":{"source":"iana","compressible":false,"extensions":["jpm"]},"image/jpx":{"source":"iana","compressible":false,"extensions":["jpx","jpf"]},"image/jxr":{"source":"iana","extensions":["jxr"]},"image/jxra":{"source":"iana","extensions":["jxra"]},"image/jxrs":{"source":"iana","extensions":["jxrs"]},"image/jxs":{"source":"iana","extensions":["jxs"]},"image/jxsc":{"source":"iana","extensions":["jxsc"]},"image/jxsi":{"source":"iana","extensions":["jxsi"]},"image/jxss":{"source":"iana","extensions":["jxss"]},"image/ktx":{"source":"iana","extensions":["ktx"]},"image/ktx2":{"source":"iana","extensions":["ktx2"]},"image/naplps":{"source":"iana"},"image/pjpeg":{"compressible":false},"image/png":{"source":"iana","compressible":false,"extensions":["png"]},"image/prs.btif":{"source":"iana","extensions":["btif"]},"image/prs.pti":{"source":"iana","extensions":["pti"]},"image/pwg-raster":{"source":"iana"},"image/sgi":{"source":"apache","extensions":["sgi"]},"image/svg+xml":{"source":"iana","compressible":true,"extensions":["svg","svgz"]},"image/t38":{"source":"iana","extensions":["t38"]},"image/tiff":{"source":"iana","compressible":false,"extensions":["tif","tiff"]},"image/tiff-fx":{"source":"iana","extensions":["tfx"]},"image/vnd.adobe.photoshop":{"source":"iana","compressible":true,"extensions":["psd"]},"image/vnd.airzip.accelerator.azv":{"source":"iana","extensions":["azv"]},"image/vnd.cns.inf2":{"source":"iana"},"image/vnd.dece.graphic":{"source":"iana","extensions":["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{"source":"iana","extensions":["djvu","djv"]},"image/vnd.dvb.subtitle":{"source":"iana","extensions":["sub"]},"image/vnd.dwg":{"source":"iana","extensions":["dwg"]},"image/vnd.dxf":{"source":"iana","extensions":["dxf"]},"image/vnd.fastbidsheet":{"source":"iana","extensions":["fbs"]},"image/vnd.fpx":{"source":"iana","extensions":["fpx"]},"image/vnd.fst":{"source":"iana","extensions":["fst"]},"image/vnd.fujixerox.edmics-mmr":{"source":"iana","extensions":["mmr"]},"image/vnd.fujixerox.edmics-rlc":{"source":"iana","extensions":["rlc"]},"image/vnd.globalgraphics.pgb":{"source":"iana"},"image/vnd.microsoft.icon":{"source":"iana","compressible":true,"extensions":["ico"]},"image/vnd.mix":{"source":"iana"},"image/vnd.mozilla.apng":{"source":"iana"},"image/vnd.ms-dds":{"compressible":true,"extensions":["dds"]},"image/vnd.ms-modi":{"source":"iana","extensions":["mdi"]},"image/vnd.ms-photo":{"source":"apache","extensions":["wdp"]},"image/vnd.net-fpx":{"source":"iana","extensions":["npx"]},"image/vnd.pco.b16":{"source":"iana","extensions":["b16"]},"image/vnd.radiance":{"source":"iana"},"image/vnd.sealed.png":{"source":"iana"},"image/vnd.sealedmedia.softseal.gif":{"source":"iana"},"image/vnd.sealedmedia.softseal.jpg":{"source":"iana"},"image/vnd.svf":{"source":"iana"},"image/vnd.tencent.tap":{"source":"iana","extensions":["tap"]},"image/vnd.valve.source.texture":{"source":"iana","extensions":["vtf"]},"image/vnd.wap.wbmp":{"source":"iana","extensions":["wbmp"]},"image/vnd.xiff":{"source":"iana","extensions":["xif"]},"image/vnd.zbrush.pcx":{"source":"iana","extensions":["pcx"]},"image/webp":{"source":"apache","extensions":["webp"]},"image/wmf":{"source":"iana","extensions":["wmf"]},"image/x-3ds":{"source":"apache","extensions":["3ds"]},"image/x-cmu-raster":{"source":"apache","extensions":["ras"]},"image/x-cmx":{"source":"apache","extensions":["cmx"]},"image/x-freehand":{"source":"apache","extensions":["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{"source":"apache","compressible":true,"extensions":["ico"]},"image/x-jng":{"source":"nginx","extensions":["jng"]},"image/x-mrsid-image":{"source":"apache","extensions":["sid"]},"image/x-ms-bmp":{"source":"nginx","compressible":true,"extensions":["bmp"]},"image/x-pcx":{"source":"apache","extensions":["pcx"]},"image/x-pict":{"source":"apache","extensions":["pic","pct"]},"image/x-portable-anymap":{"source":"apache","extensions":["pnm"]},"image/x-portable-bitmap":{"source":"apache","extensions":["pbm"]},"image/x-portable-graymap":{"source":"apache","extensions":["pgm"]},"image/x-portable-pixmap":{"source":"apache","extensions":["ppm"]},"image/x-rgb":{"source":"apache","extensions":["rgb"]},"image/x-tga":{"source":"apache","extensions":["tga"]},"image/x-xbitmap":{"source":"apache","extensions":["xbm"]},"image/x-xcf":{"compressible":false},"image/x-xpixmap":{"source":"apache","extensions":["xpm"]},"image/x-xwindowdump":{"source":"apache","extensions":["xwd"]},"message/cpim":{"source":"iana"},"message/delivery-status":{"source":"iana"},"message/disposition-notification":{"source":"iana","extensions":["disposition-notification"]},"message/external-body":{"source":"iana"},"message/feedback-report":{"source":"iana"},"message/global":{"source":"iana","extensions":["u8msg"]},"message/global-delivery-status":{"source":"iana","extensions":["u8dsn"]},"message/global-disposition-notification":{"source":"iana","extensions":["u8mdn"]},"message/global-headers":{"source":"iana","extensions":["u8hdr"]},"message/http":{"source":"iana","compressible":false},"message/imdn+xml":{"source":"iana","compressible":true},"message/news":{"source":"iana"},"message/partial":{"source":"iana","compressible":false},"message/rfc822":{"source":"iana","compressible":true,"extensions":["eml","mime"]},"message/s-http":{"source":"iana"},"message/sip":{"source":"iana"},"message/sipfrag":{"source":"iana"},"message/tracking-status":{"source":"iana"},"message/vnd.si.simp":{"source":"iana"},"message/vnd.wfa.wsc":{"source":"iana","extensions":["wsc"]},"model/3mf":{"source":"iana","extensions":["3mf"]},"model/e57":{"source":"iana"},"model/gltf+json":{"source":"iana","compressible":true,"extensions":["gltf"]},"model/gltf-binary":{"source":"iana","compressible":true,"extensions":["glb"]},"model/iges":{"source":"iana","compressible":false,"extensions":["igs","iges"]},"model/mesh":{"source":"iana","compressible":false,"extensions":["msh","mesh","silo"]},"model/mtl":{"source":"iana","extensions":["mtl"]},"model/obj":{"source":"iana","extensions":["obj"]},"model/step":{"source":"iana"},"model/step+xml":{"source":"iana","compressible":true,"extensions":["stpx"]},"model/step+zip":{"source":"iana","compressible":false,"extensions":["stpz"]},"model/step-xml+zip":{"source":"iana","compressible":false,"extensions":["stpxz"]},"model/stl":{"source":"iana","extensions":["stl"]},"model/vnd.collada+xml":{"source":"iana","compressible":true,"extensions":["dae"]},"model/vnd.dwf":{"source":"iana","extensions":["dwf"]},"model/vnd.flatland.3dml":{"source":"iana"},"model/vnd.gdl":{"source":"iana","extensions":["gdl"]},"model/vnd.gs-gdl":{"source":"apache"},"model/vnd.gs.gdl":{"source":"iana"},"model/vnd.gtw":{"source":"iana","extensions":["gtw"]},"model/vnd.moml+xml":{"source":"iana","compressible":true},"model/vnd.mts":{"source":"iana","extensions":["mts"]},"model/vnd.opengex":{"source":"iana","extensions":["ogex"]},"model/vnd.parasolid.transmit.binary":{"source":"iana","extensions":["x_b"]},"model/vnd.parasolid.transmit.text":{"source":"iana","extensions":["x_t"]},"model/vnd.pytha.pyox":{"source":"iana"},"model/vnd.rosette.annotated-data-model":{"source":"iana"},"model/vnd.sap.vds":{"source":"iana","extensions":["vds"]},"model/vnd.usdz+zip":{"source":"iana","compressible":false,"extensions":["usdz"]},"model/vnd.valve.source.compiled-map":{"source":"iana","extensions":["bsp"]},"model/vnd.vtu":{"source":"iana","extensions":["vtu"]},"model/vrml":{"source":"iana","compressible":false,"extensions":["wrl","vrml"]},"model/x3d+binary":{"source":"apache","compressible":false,"extensions":["x3db","x3dbz"]},"model/x3d+fastinfoset":{"source":"iana","extensions":["x3db"]},"model/x3d+vrml":{"source":"apache","compressible":false,"extensions":["x3dv","x3dvz"]},"model/x3d+xml":{"source":"iana","compressible":true,"extensions":["x3d","x3dz"]},"model/x3d-vrml":{"source":"iana","extensions":["x3dv"]},"multipart/alternative":{"source":"iana","compressible":false},"multipart/appledouble":{"source":"iana"},"multipart/byteranges":{"source":"iana"},"multipart/digest":{"source":"iana"},"multipart/encrypted":{"source":"iana","compressible":false},"multipart/form-data":{"source":"iana","compressible":false},"multipart/header-set":{"source":"iana"},"multipart/mixed":{"source":"iana"},"multipart/multilingual":{"source":"iana"},"multipart/parallel":{"source":"iana"},"multipart/related":{"source":"iana","compressible":false},"multipart/report":{"source":"iana"},"multipart/signed":{"source":"iana","compressible":false},"multipart/vnd.bint.med-plus":{"source":"iana"},"multipart/voice-message":{"source":"iana"},"multipart/x-mixed-replace":{"source":"iana"},"text/1d-interleaved-parityfec":{"source":"iana"},"text/cache-manifest":{"source":"iana","compressible":true,"extensions":["appcache","manifest"]},"text/calendar":{"source":"iana","extensions":["ics","ifb"]},"text/calender":{"compressible":true},"text/cmd":{"compressible":true},"text/coffeescript":{"extensions":["coffee","litcoffee"]},"text/cql":{"source":"iana"},"text/cql-expression":{"source":"iana"},"text/cql-identifier":{"source":"iana"},"text/css":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["css"]},"text/csv":{"source":"iana","compressible":true,"extensions":["csv"]},"text/csv-schema":{"source":"iana"},"text/directory":{"source":"iana"},"text/dns":{"source":"iana"},"text/ecmascript":{"source":"iana"},"text/encaprtp":{"source":"iana"},"text/enriched":{"source":"iana"},"text/fhirpath":{"source":"iana"},"text/flexfec":{"source":"iana"},"text/fwdred":{"source":"iana"},"text/gff3":{"source":"iana"},"text/grammar-ref-list":{"source":"iana"},"text/html":{"source":"iana","compressible":true,"extensions":["html","htm","shtml"]},"text/jade":{"extensions":["jade"]},"text/javascript":{"source":"iana","compressible":true},"text/jcr-cnd":{"source":"iana"},"text/jsx":{"compressible":true,"extensions":["jsx"]},"text/less":{"compressible":true,"extensions":["less"]},"text/markdown":{"source":"iana","compressible":true,"extensions":["markdown","md"]},"text/mathml":{"source":"nginx","extensions":["mml"]},"text/mdx":{"compressible":true,"extensions":["mdx"]},"text/mizar":{"source":"iana"},"text/n3":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["n3"]},"text/parameters":{"source":"iana","charset":"UTF-8"},"text/parityfec":{"source":"iana"},"text/plain":{"source":"iana","compressible":true,"extensions":["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{"source":"iana","charset":"UTF-8"},"text/prs.fallenstein.rst":{"source":"iana"},"text/prs.lines.tag":{"source":"iana","extensions":["dsc"]},"text/prs.prop.logic":{"source":"iana"},"text/raptorfec":{"source":"iana"},"text/red":{"source":"iana"},"text/rfc822-headers":{"source":"iana"},"text/richtext":{"source":"iana","compressible":true,"extensions":["rtx"]},"text/rtf":{"source":"iana","compressible":true,"extensions":["rtf"]},"text/rtp-enc-aescm128":{"source":"iana"},"text/rtploopback":{"source":"iana"},"text/rtx":{"source":"iana"},"text/sgml":{"source":"iana","extensions":["sgml","sgm"]},"text/shaclc":{"source":"iana"},"text/shex":{"source":"iana","extensions":["shex"]},"text/slim":{"extensions":["slim","slm"]},"text/spdx":{"source":"iana","extensions":["spdx"]},"text/strings":{"source":"iana"},"text/stylus":{"extensions":["stylus","styl"]},"text/t140":{"source":"iana"},"text/tab-separated-values":{"source":"iana","compressible":true,"extensions":["tsv"]},"text/troff":{"source":"iana","extensions":["t","tr","roff","man","me","ms"]},"text/turtle":{"source":"iana","charset":"UTF-8","extensions":["ttl"]},"text/ulpfec":{"source":"iana"},"text/uri-list":{"source":"iana","compressible":true,"extensions":["uri","uris","urls"]},"text/vcard":{"source":"iana","compressible":true,"extensions":["vcard"]},"text/vnd.a":{"source":"iana"},"text/vnd.abc":{"source":"iana"},"text/vnd.ascii-art":{"source":"iana"},"text/vnd.curl":{"source":"iana","extensions":["curl"]},"text/vnd.curl.dcurl":{"source":"apache","extensions":["dcurl"]},"text/vnd.curl.mcurl":{"source":"apache","extensions":["mcurl"]},"text/vnd.curl.scurl":{"source":"apache","extensions":["scurl"]},"text/vnd.debian.copyright":{"source":"iana","charset":"UTF-8"},"text/vnd.dmclientscript":{"source":"iana"},"text/vnd.dvb.subtitle":{"source":"iana","extensions":["sub"]},"text/vnd.esmertec.theme-descriptor":{"source":"iana","charset":"UTF-8"},"text/vnd.familysearch.gedcom":{"source":"iana","extensions":["ged"]},"text/vnd.ficlab.flt":{"source":"iana"},"text/vnd.fly":{"source":"iana","extensions":["fly"]},"text/vnd.fmi.flexstor":{"source":"iana","extensions":["flx"]},"text/vnd.gml":{"source":"iana"},"text/vnd.graphviz":{"source":"iana","extensions":["gv"]},"text/vnd.hans":{"source":"iana"},"text/vnd.hgl":{"source":"iana"},"text/vnd.in3d.3dml":{"source":"iana","extensions":["3dml"]},"text/vnd.in3d.spot":{"source":"iana","extensions":["spot"]},"text/vnd.iptc.newsml":{"source":"iana"},"text/vnd.iptc.nitf":{"source":"iana"},"text/vnd.latex-z":{"source":"iana"},"text/vnd.motorola.reflex":{"source":"iana"},"text/vnd.ms-mediapackage":{"source":"iana"},"text/vnd.net2phone.commcenter.command":{"source":"iana"},"text/vnd.radisys.msml-basic-layout":{"source":"iana"},"text/vnd.senx.warpscript":{"source":"iana"},"text/vnd.si.uricatalogue":{"source":"iana"},"text/vnd.sosi":{"source":"iana"},"text/vnd.sun.j2me.app-descriptor":{"source":"iana","charset":"UTF-8","extensions":["jad"]},"text/vnd.trolltech.linguist":{"source":"iana","charset":"UTF-8"},"text/vnd.wap.si":{"source":"iana"},"text/vnd.wap.sl":{"source":"iana"},"text/vnd.wap.wml":{"source":"iana","extensions":["wml"]},"text/vnd.wap.wmlscript":{"source":"iana","extensions":["wmls"]},"text/vtt":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["vtt"]},"text/x-asm":{"source":"apache","extensions":["s","asm"]},"text/x-c":{"source":"apache","extensions":["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{"source":"nginx","extensions":["htc"]},"text/x-fortran":{"source":"apache","extensions":["f","for","f77","f90"]},"text/x-gwt-rpc":{"compressible":true},"text/x-handlebars-template":{"extensions":["hbs"]},"text/x-java-source":{"source":"apache","extensions":["java"]},"text/x-jquery-tmpl":{"compressible":true},"text/x-lua":{"extensions":["lua"]},"text/x-markdown":{"compressible":true,"extensions":["mkd"]},"text/x-nfo":{"source":"apache","extensions":["nfo"]},"text/x-opml":{"source":"apache","extensions":["opml"]},"text/x-org":{"compressible":true,"extensions":["org"]},"text/x-pascal":{"source":"apache","extensions":["p","pas"]},"text/x-processing":{"compressible":true,"extensions":["pde"]},"text/x-sass":{"extensions":["sass"]},"text/x-scss":{"extensions":["scss"]},"text/x-setext":{"source":"apache","extensions":["etx"]},"text/x-sfv":{"source":"apache","extensions":["sfv"]},"text/x-suse-ymp":{"compressible":true,"extensions":["ymp"]},"text/x-uuencode":{"source":"apache","extensions":["uu"]},"text/x-vcalendar":{"source":"apache","extensions":["vcs"]},"text/x-vcard":{"source":"apache","extensions":["vcf"]},"text/xml":{"source":"iana","compressible":true,"extensions":["xml"]},"text/xml-external-parsed-entity":{"source":"iana"},"text/yaml":{"compressible":true,"extensions":["yaml","yml"]},"video/1d-interleaved-parityfec":{"source":"iana"},"video/3gpp":{"source":"iana","extensions":["3gp","3gpp"]},"video/3gpp-tt":{"source":"iana"},"video/3gpp2":{"source":"iana","extensions":["3g2"]},"video/av1":{"source":"iana"},"video/bmpeg":{"source":"iana"},"video/bt656":{"source":"iana"},"video/celb":{"source":"iana"},"video/dv":{"source":"iana"},"video/encaprtp":{"source":"iana"},"video/ffv1":{"source":"iana"},"video/flexfec":{"source":"iana"},"video/h261":{"source":"iana","extensions":["h261"]},"video/h263":{"source":"iana","extensions":["h263"]},"video/h263-1998":{"source":"iana"},"video/h263-2000":{"source":"iana"},"video/h264":{"source":"iana","extensions":["h264"]},"video/h264-rcdo":{"source":"iana"},"video/h264-svc":{"source":"iana"},"video/h265":{"source":"iana"},"video/iso.segment":{"source":"iana","extensions":["m4s"]},"video/jpeg":{"source":"iana","extensions":["jpgv"]},"video/jpeg2000":{"source":"iana"},"video/jpm":{"source":"apache","extensions":["jpm","jpgm"]},"video/jxsv":{"source":"iana"},"video/mj2":{"source":"iana","extensions":["mj2","mjp2"]},"video/mp1s":{"source":"iana"},"video/mp2p":{"source":"iana"},"video/mp2t":{"source":"iana","extensions":["ts"]},"video/mp4":{"source":"iana","compressible":false,"extensions":["mp4","mp4v","mpg4"]},"video/mp4v-es":{"source":"iana"},"video/mpeg":{"source":"iana","compressible":false,"extensions":["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{"source":"iana"},"video/mpv":{"source":"iana"},"video/nv":{"source":"iana"},"video/ogg":{"source":"iana","compressible":false,"extensions":["ogv"]},"video/parityfec":{"source":"iana"},"video/pointer":{"source":"iana"},"video/quicktime":{"source":"iana","compressible":false,"extensions":["qt","mov"]},"video/raptorfec":{"source":"iana"},"video/raw":{"source":"iana"},"video/rtp-enc-aescm128":{"source":"iana"},"video/rtploopback":{"source":"iana"},"video/rtx":{"source":"iana"},"video/scip":{"source":"iana"},"video/smpte291":{"source":"iana"},"video/smpte292m":{"source":"iana"},"video/ulpfec":{"source":"iana"},"video/vc1":{"source":"iana"},"video/vc2":{"source":"iana"},"video/vnd.cctv":{"source":"iana"},"video/vnd.dece.hd":{"source":"iana","extensions":["uvh","uvvh"]},"video/vnd.dece.mobile":{"source":"iana","extensions":["uvm","uvvm"]},"video/vnd.dece.mp4":{"source":"iana"},"video/vnd.dece.pd":{"source":"iana","extensions":["uvp","uvvp"]},"video/vnd.dece.sd":{"source":"iana","extensions":["uvs","uvvs"]},"video/vnd.dece.video":{"source":"iana","extensions":["uvv","uvvv"]},"video/vnd.directv.mpeg":{"source":"iana"},"video/vnd.directv.mpeg-tts":{"source":"iana"},"video/vnd.dlna.mpeg-tts":{"source":"iana"},"video/vnd.dvb.file":{"source":"iana","extensions":["dvb"]},"video/vnd.fvt":{"source":"iana","extensions":["fvt"]},"video/vnd.hns.video":{"source":"iana"},"video/vnd.iptvforum.1dparityfec-1010":{"source":"iana"},"video/vnd.iptvforum.1dparityfec-2005":{"source":"iana"},"video/vnd.iptvforum.2dparityfec-1010":{"source":"iana"},"video/vnd.iptvforum.2dparityfec-2005":{"source":"iana"},"video/vnd.iptvforum.ttsavc":{"source":"iana"},"video/vnd.iptvforum.ttsmpeg2":{"source":"iana"},"video/vnd.motorola.video":{"source":"iana"},"video/vnd.motorola.videop":{"source":"iana"},"video/vnd.mpegurl":{"source":"iana","extensions":["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{"source":"iana","extensions":["pyv"]},"video/vnd.nokia.interleaved-multimedia":{"source":"iana"},"video/vnd.nokia.mp4vr":{"source":"iana"},"video/vnd.nokia.videovoip":{"source":"iana"},"video/vnd.objectvideo":{"source":"iana"},"video/vnd.radgamettools.bink":{"source":"iana"},"video/vnd.radgamettools.smacker":{"source":"iana"},"video/vnd.sealed.mpeg1":{"source":"iana"},"video/vnd.sealed.mpeg4":{"source":"iana"},"video/vnd.sealed.swf":{"source":"iana"},"video/vnd.sealedmedia.softseal.mov":{"source":"iana"},"video/vnd.uvvu.mp4":{"source":"iana","extensions":["uvu","uvvu"]},"video/vnd.vivo":{"source":"iana","extensions":["viv"]},"video/vnd.youtube.yt":{"source":"iana"},"video/vp8":{"source":"iana"},"video/vp9":{"source":"iana"},"video/webm":{"source":"apache","compressible":false,"extensions":["webm"]},"video/x-f4v":{"source":"apache","extensions":["f4v"]},"video/x-fli":{"source":"apache","extensions":["fli"]},"video/x-flv":{"source":"apache","compressible":false,"extensions":["flv"]},"video/x-m4v":{"source":"apache","extensions":["m4v"]},"video/x-matroska":{"source":"apache","compressible":false,"extensions":["mkv","mk3d","mks"]},"video/x-mng":{"source":"apache","extensions":["mng"]},"video/x-ms-asf":{"source":"apache","extensions":["asf","asx"]},"video/x-ms-vob":{"source":"apache","extensions":["vob"]},"video/x-ms-wm":{"source":"apache","extensions":["wm"]},"video/x-ms-wmv":{"source":"apache","compressible":false,"extensions":["wmv"]},"video/x-ms-wmx":{"source":"apache","extensions":["wmx"]},"video/x-ms-wvx":{"source":"apache","extensions":["wvx"]},"video/x-msvideo":{"source":"apache","extensions":["avi"]},"video/x-sgi-movie":{"source":"apache","extensions":["movie"]},"video/x-smv":{"source":"apache","extensions":["smv"]},"x-conference/x-cooltalk":{"source":"apache","extensions":["ice"]},"x-shader/x-fragment":{"compressible":true},"x-shader/x-vertex":{"compressible":true}}')},15579:e=>{"use strict";e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var r=__webpack_module_cache__[e]={id:e,loaded:!1,exports:{}};return __webpack_modules__[e].call(r.exports,r,r.exports,__webpack_require__),r.loaded=!0,r.exports}__webpack_require__.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return __webpack_require__.d(t,{a:t}),t},__webpack_require__.d=(e,t)=>{for(var r in t)__webpack_require__.o(t,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},__webpack_require__.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var __webpack_exports__={};(()=>{"use strict";__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>jH});var e={};__webpack_require__.r(e),__webpack_require__.d(e,{AccessPolicy:()=>go,AppendBlobAppendBlockExceptionHeaders:()=>Qa,AppendBlobAppendBlockFromUrlExceptionHeaders:()=>Xa,AppendBlobAppendBlockFromUrlHeaders:()=>Za,AppendBlobAppendBlockHeaders:()=>Ya,AppendBlobCreateExceptionHeaders:()=>Ja,AppendBlobCreateHeaders:()=>Va,AppendBlobSealExceptionHeaders:()=>tl,AppendBlobSealHeaders:()=>el,ArrowConfiguration:()=>Oo,ArrowField:()=>zo,BlobAbortCopyFromURLExceptionHeaders:()=>ba,BlobAbortCopyFromURLHeaders:()=>va,BlobAcquireLeaseExceptionHeaders:()=>ia,BlobAcquireLeaseHeaders:()=>ra,BlobBreakLeaseExceptionHeaders:()=>ua,BlobBreakLeaseHeaders:()=>ca,BlobChangeLeaseExceptionHeaders:()=>da,BlobChangeLeaseHeaders:()=>la,BlobCopyFromURLExceptionHeaders:()=>ya,BlobCopyFromURLHeaders:()=>ga,BlobCreateSnapshotExceptionHeaders:()=>ha,BlobCreateSnapshotHeaders:()=>pa,BlobDeleteExceptionHeaders:()=>Ls,BlobDeleteHeaders:()=>Us,BlobDeleteImmutabilityPolicyExceptionHeaders:()=>Qs,BlobDeleteImmutabilityPolicyHeaders:()=>Ys,BlobDownloadExceptionHeaders:()=>zs,BlobDownloadHeaders:()=>Os,BlobFlatListSegment:()=>vo,BlobGetAccountInfoExceptionHeaders:()=>Sa,BlobGetAccountInfoHeaders:()=>xa,BlobGetPropertiesExceptionHeaders:()=>qs,BlobGetPropertiesHeaders:()=>Ns,BlobGetTagsExceptionHeaders:()=>Ba,BlobGetTagsHeaders:()=>Ta,BlobHierarchyListSegment:()=>So,BlobItemInternal:()=>bo,BlobName:()=>wo,BlobPrefix:()=>ko,BlobPropertiesInternal:()=>_o,BlobQueryExceptionHeaders:()=>Ea,BlobQueryHeaders:()=>ka,BlobReleaseLeaseExceptionHeaders:()=>oa,BlobReleaseLeaseHeaders:()=>na,BlobRenewLeaseExceptionHeaders:()=>aa,BlobRenewLeaseHeaders:()=>sa,BlobServiceProperties:()=>Yn,BlobServiceStatistics:()=>io,BlobSetExpiryExceptionHeaders:()=>Gs,BlobSetExpiryHeaders:()=>$s,BlobSetHttpHeadersExceptionHeaders:()=>Ks,BlobSetHttpHeadersHeaders:()=>Ws,BlobSetImmutabilityPolicyExceptionHeaders:()=>Js,BlobSetImmutabilityPolicyHeaders:()=>Vs,BlobSetLegalHoldExceptionHeaders:()=>Xs,BlobSetLegalHoldHeaders:()=>Zs,BlobSetMetadataExceptionHeaders:()=>ta,BlobSetMetadataHeaders:()=>ea,BlobSetTagsExceptionHeaders:()=>Ia,BlobSetTagsHeaders:()=>Ca,BlobSetTierExceptionHeaders:()=>_a,BlobSetTierHeaders:()=>wa,BlobStartCopyFromURLExceptionHeaders:()=>ma,BlobStartCopyFromURLHeaders:()=>fa,BlobTag:()=>fo,BlobTags:()=>ho,BlobUndeleteExceptionHeaders:()=>Hs,BlobUndeleteHeaders:()=>js,Block:()=>Bo,BlockBlobCommitBlockListExceptionHeaders:()=>ul,BlockBlobCommitBlockListHeaders:()=>cl,BlockBlobGetBlockListExceptionHeaders:()=>hl,BlockBlobGetBlockListHeaders:()=>pl,BlockBlobPutBlobFromUrlExceptionHeaders:()=>ol,BlockBlobPutBlobFromUrlHeaders:()=>nl,BlockBlobStageBlockExceptionHeaders:()=>al,BlockBlobStageBlockFromURLExceptionHeaders:()=>dl,BlockBlobStageBlockFromURLHeaders:()=>ll,BlockBlobStageBlockHeaders:()=>sl,BlockBlobUploadExceptionHeaders:()=>il,BlockBlobUploadHeaders:()=>rl,BlockList:()=>To,BlockLookupList:()=>Eo,ClearRange:()=>Ao,ContainerAcquireLeaseExceptionHeaders:()=>_s,ContainerAcquireLeaseHeaders:()=>ws,ContainerBreakLeaseExceptionHeaders:()=>Bs,ContainerBreakLeaseHeaders:()=>Ts,ContainerChangeLeaseExceptionHeaders:()=>Is,ContainerChangeLeaseHeaders:()=>Cs,ContainerCreateExceptionHeaders:()=>ts,ContainerCreateHeaders:()=>es,ContainerDeleteExceptionHeaders:()=>os,ContainerDeleteHeaders:()=>ns,ContainerFilterBlobsExceptionHeaders:()=>bs,ContainerFilterBlobsHeaders:()=>vs,ContainerGetAccessPolicyExceptionHeaders:()=>ds,ContainerGetAccessPolicyHeaders:()=>ls,ContainerGetAccountInfoExceptionHeaders:()=>Ps,ContainerGetAccountInfoHeaders:()=>Rs,ContainerGetPropertiesExceptionHeaders:()=>is,ContainerGetPropertiesHeaders:()=>rs,ContainerItem:()=>so,ContainerListBlobFlatSegmentExceptionHeaders:()=>Fs,ContainerListBlobFlatSegmentHeaders:()=>As,ContainerListBlobHierarchySegmentExceptionHeaders:()=>Ds,ContainerListBlobHierarchySegmentHeaders:()=>Ms,ContainerProperties:()=>ao,ContainerReleaseLeaseExceptionHeaders:()=>Ss,ContainerReleaseLeaseHeaders:()=>xs,ContainerRenameExceptionHeaders:()=>ms,ContainerRenameHeaders:()=>fs,ContainerRenewLeaseExceptionHeaders:()=>Es,ContainerRenewLeaseHeaders:()=>ks,ContainerRestoreExceptionHeaders:()=>hs,ContainerRestoreHeaders:()=>ps,ContainerSetAccessPolicyExceptionHeaders:()=>us,ContainerSetAccessPolicyHeaders:()=>cs,ContainerSetMetadataExceptionHeaders:()=>as,ContainerSetMetadataHeaders:()=>ss,ContainerSubmitBatchExceptionHeaders:()=>ys,ContainerSubmitBatchHeaders:()=>gs,CorsRule:()=>eo,DelimitedTextConfiguration:()=>Ro,FilterBlobItem:()=>po,FilterBlobSegment:()=>uo,GeoReplication:()=>no,JsonTextConfiguration:()=>Po,KeyInfo:()=>lo,ListBlobsFlatSegmentResponse:()=>yo,ListBlobsHierarchySegmentResponse:()=>xo,ListContainersSegmentResponse:()=>oo,Logging:()=>Qn,Metrics:()=>Xn,PageBlobClearPagesExceptionHeaders:()=>Pa,PageBlobClearPagesHeaders:()=>Ra,PageBlobCopyIncrementalExceptionHeaders:()=>Ka,PageBlobCopyIncrementalHeaders:()=>Wa,PageBlobCreateExceptionHeaders:()=>Fa,PageBlobCreateHeaders:()=>Aa,PageBlobGetPageRangesDiffExceptionHeaders:()=>La,PageBlobGetPageRangesDiffHeaders:()=>Ua,PageBlobGetPageRangesExceptionHeaders:()=>qa,PageBlobGetPageRangesHeaders:()=>Na,PageBlobResizeExceptionHeaders:()=>Ha,PageBlobResizeHeaders:()=>ja,PageBlobUpdateSequenceNumberExceptionHeaders:()=>Ga,PageBlobUpdateSequenceNumberHeaders:()=>$a,PageBlobUploadPagesExceptionHeaders:()=>Da,PageBlobUploadPagesFromURLExceptionHeaders:()=>za,PageBlobUploadPagesFromURLHeaders:()=>Oa,PageBlobUploadPagesHeaders:()=>Ma,PageList:()=>Co,PageRange:()=>Io,QueryFormat:()=>Do,QueryRequest:()=>Fo,QuerySerialization:()=>Mo,RetentionPolicy:()=>Zn,ServiceFilterBlobsExceptionHeaders:()=>Xo,ServiceFilterBlobsHeaders:()=>Zo,ServiceGetAccountInfoExceptionHeaders:()=>Jo,ServiceGetAccountInfoHeaders:()=>Vo,ServiceGetPropertiesExceptionHeaders:()=>Lo,ServiceGetPropertiesHeaders:()=>Uo,ServiceGetStatisticsExceptionHeaders:()=>Ho,ServiceGetStatisticsHeaders:()=>jo,ServiceGetUserDelegationKeyExceptionHeaders:()=>Ko,ServiceGetUserDelegationKeyHeaders:()=>Wo,ServiceListContainersSegmentExceptionHeaders:()=>Go,ServiceListContainersSegmentHeaders:()=>$o,ServiceSetPropertiesExceptionHeaders:()=>qo,ServiceSetPropertiesHeaders:()=>No,ServiceSubmitBatchExceptionHeaders:()=>Qo,ServiceSubmitBatchHeaders:()=>Yo,SignedIdentifier:()=>mo,StaticWebsite:()=>to,StorageError:()=>ro,UserDelegationKey:()=>co});function t(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(i=Object.getOwnPropertySymbols(e);n0&&n[n.length-1])||6!==a[0]&&2!==a[0])){o=0;continue}if(3===a[0]&&(!n||a[1]>n[0]&&a[1]=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function o(e){return this instanceof o?(this.v=e,this):new o(e)}function s(e,t,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i,n=r.apply(e,t||[]),s=[];return i=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",(function(e){return function(t){return Promise.resolve(t).then(e,c)}})),i[Symbol.asyncIterator]=function(){return this},i;function a(e,t){n[e]&&(i[e]=function(t){return new Promise((function(r,i){s.push([e,t,r,i])>1||l(e,t)}))},t&&(i[e]=t(i[e])))}function l(e,t){try{!function(e){e.value instanceof o?Promise.resolve(e.value.v).then(d,c):u(s[0][2],e)}(n[e](t))}catch(e){u(s[0][3],e)}}function d(e){l("next",e)}function c(e){l("throw",e)}function u(e,t){e(t),s.shift(),s.length&&l(s[0][0],s[0][1])}}function a(e){var t,r;return t={},i("next"),i("throw",(function(e){throw e})),i("return"),t[Symbol.iterator]=function(){return this},t;function i(i,n){t[i]=e[i]?function(t){return(r=!r)?{value:o(e[i](t)),done:!1}:n?n(t):t}:n}}function l(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=n(e),t={},i("next"),i("throw"),i("return"),t[Symbol.asyncIterator]=function(){return this},t);function i(r){t[r]=e[r]&&function(t){return new Promise((function(i,n){(function(e,t,r,i){Promise.resolve(i).then((function(t){e({value:t,done:r})}),t)})(i,n,(t=e[r](t)).done,t.value)}))}}}Object.create;"function"==typeof SuppressedError&&SuppressedError;const d=()=>"",c=/\s+at.*[(\s](.*)\)?/,u=/^(?:(?:(?:node|node:[\w/]+|(?:(?:node:)?internal\/[\w/]*|.*node_modules\/(?:babel-polyfill|pirates)\/.*)?\w+)(?:\.js)?:\d+:\d+)|native)/;function p(e,{pretty:t=!1,basePath:r,pathFilter:i}={}){const n=r&&new RegExp(`(file://)?${function(e){if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}(r.replace(/\\/g,"/"))}/?`,"g"),o=t?d():"";if("string"==typeof e)return e.replace(/\\/g,"/").split("\n").filter((e=>{const t=e.match(c);if(null===t||!t[1])return!0;const r=t[1];return!(r.includes(".app/Contents/Resources/electron.asar")||r.includes(".app/Contents/Resources/default_app.asar")||r.includes("node_modules/electron/dist/resources/electron.asar")||r.includes("node_modules/electron/dist/resources/default_app.asar"))&&(i?!u.test(r)&&i(r):!u.test(r))})).filter((e=>""!==e.trim())).map((e=>(n&&(e=e.replace(n,"")),t&&(e=e.replace(c,((e,t)=>e.replace(t,t.replace(o,"~"))))),e))).join("\n")}class h extends Error{#e;name="AggregateError";constructor(e){if(!Array.isArray(e))throw new TypeError("Expected input to be an Array, got "+typeof e);let t=(e=e.map((e=>e instanceof Error?e:null!==e&&"object"==typeof e?Object.assign(new Error(e.message),e):new Error(e)))).map((e=>"string"==typeof e.stack&&e.stack.length>0?p(e.stack).replaceAll(/\s+at .*aggregate-error\/index.js:\d+:\d+\)?/g,""):String(e))).join("\n");t="\n"+function(e,t=1,r={}){const{indent:i=" ",includeEmptyLines:n=!1}=r;if("string"!=typeof e)throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof e}\``);if("number"!=typeof t)throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof t}\``);if(t<0)throw new RangeError(`Expected \`count\` to be at least 0, got \`${t}\``);if("string"!=typeof i)throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof i}\``);if(0===t)return e;const o=n?/^/gm:/^(?!\s*$)/gm;return e.replace(o,i.repeat(t))}(t,4),super(t),this.#e=e}get errors(){return[...this.#e]}}var f=__webpack_require__(88055),m=__webpack_require__.n(f),g=__webpack_require__(7350),y=__webpack_require__.n(g); +/** + * @license lucide v0.416.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */ +const v=(e,t,r=[])=>{const i=document.createElementNS("http://www.w3.org/2000/svg",e);return Object.keys(t).forEach((e=>{i.setAttribute(e,String(t[e]))})),r.length&&r.forEach((e=>{const t=v(...e);i.appendChild(t)})),i};var b=([e,t,r])=>v(e,t,r); +/** + * @license lucide v0.416.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */ +const w={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"},_=["svg",w,[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}],["path",{d:"M3 3v5h5"}]]],x=["svg",w,[["path",{d:"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}],["path",{d:"M3 3v5h5"}],["path",{d:"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16"}],["path",{d:"M16 16h5v5"}]]],S=["svg",w,[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}],["path",{d:"M10 9H8"}],["path",{d:"M16 13H8"}],["path",{d:"M16 17H8"}]]],k=require("obsidian");let E=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e));for(;e--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&r[e]];return t};const T="uwxv4ofkrmc4zzf",B="3729fc1c-0af2-4bec-9376-d7ac4f0ff806",C="https://login.microsoftonline.com/common",I="application/octet-stream",A="remotely-save",F="remotely-save-cb-onedrive",M="remotely-save-cb-dropbox",D=6912e6,R="_debug_remotely_save/",P="remotely-save-cb-pro",O="cli-RcskZDNbskll95WHJ3rNa8G34YlD3DML3cmwGOpEpbpvm82rIVGWmQMKJ60NjjGJKB6H_fOeHicW9W0H",z="573787634452-5301p7h0r85rpc03hbnrn5k9qqt3bulf.apps.googleusercontent.com",N="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",q="remotely-save-cb-box",U="o0ohclnln6xf7fpd1pnomqpl42v0w3hl",L="oDrcpdgifz24NJMN6OmgC2kvYCChbYMX",j="remotely-save-cb-pcloud",H="zrDphYT1giQ",$="TqjVEEaXlsHwCOczzm0R9SBmxf2y",G="remotely-save-cb-yandexdisk",W="01d8aee92915469dba50b70965d77323",K="71da4965f9124deab95444df46afa651",V="remotely-save-cb-koofr",J="LUOCNJ27DECBGKZRG22RHPBAMVK3CUWF",Y="WJH6XQF2AXK6UINDM2T3STD7OAYCX6H4ZL3T4KPYSTW4R5AKI4W26Q6C76WZQ5DT",Q="remotely-save-cb-onedrivefull";function Z(e,t,r){var i;if(void 0===r&&(r={}),!t.codes){t.codes={};for(var n=0;n=8&&(a-=8,s[d++]=255&l>>a)}if(a>=t.bits||255&l<<8-a)throw new SyntaxError("Unexpected end of data");return s}function X(e,t,r){void 0===r&&(r={});for(var i=r.pad,n=void 0===i||i,o=(1<t.bits;)a-=t.bits,s+=t.chars[o&l>>a];if(a&&(s+=t.chars[o&l<r(void 0,void 0,void 0,(function*(){const t=O,i=E(128),n=yield function(e){return r(this,void 0,void 0,(function*(){if(void 0===e||""===e)return"";try{return ne(new Uint8Array(yield crypto.subtle.digest("SHA-256",(new TextEncoder).encode(e))),{pad:!1})}catch(e){return""}}))}(i);let o=`${oe}/oauth2/authorize?response_type=code&client_id=${t}&token_access_type=offline&code_challenge_method=S256&code_challenge=${n}&scope=pro.list.read`;return e&&(o+=`&redirect_uri=obsidian://${P}`),{authUrl:o,codeVerifier:i,codeChallenge:n}})),le=(e,t,i)=>r(void 0,void 0,void 0,(function*(){const r=O;try{const i={code:t,grant_type:"authorization_code",code_verifier:e,client_id:r,scope:"pro.list.read"},n=yield fetch(`${oe}/api/v1/oauth2/token`,{method:"POST",body:new URLSearchParams(i)});return yield n.json()}catch(e){console.error(e),void 0!==i&&(yield i(e))}})),de=(e,t,i)=>r(void 0,void 0,void 0,(function*(){if(void 0!==t.error)throw Error(`remotely save account auth failed, please auth again: ${t.error}`);e.accessToken=t.access_token,e.accessTokenExpiresAtTimeMs=Date.now()+1e3*t.expires_in-3e5,e.accessTokenExpiresInMs=1e3*t.expires_in,e.refreshToken=t.refresh_token||e.refreshToken,e.credentialsShouldBeDeletedAtTimeMs=Date.now()+D,yield null==i?void 0:i(),console.info("finish updating local info of Remotely Save official website token")})),ce=(e,t)=>r(void 0,void 0,void 0,(function*(){var i,n,o;const s=Date.now();if(void 0!==e.accessToken&&""!==e.accessToken&&e.accessTokenExpiresAtTimeMs>s&&(null!==(i=e.credentialsShouldBeDeletedAtTimeMs)&&void 0!==i?i:s+1e6)>s)return e.accessToken;console.debug(`currently, accessToken=${e.accessToken}, accessTokenExpiresAtTimeMs=${e.accessTokenExpiresAtTimeMs}, credentialsShouldBeDeletedAtTimeMs=${e.credentialsShouldBeDeletedAtTimeMs},comp1=${e.accessTokenExpiresAtTimeMs>s}, comp2=${(null!==(n=e.credentialsShouldBeDeletedAtTimeMs)&&void 0!==n?n:s+1e6)>s}`);const a=yield(l=null!==(o=e.refreshToken)&&void 0!==o?o:"refresh-",r(void 0,void 0,void 0,(function*(){const e=O;try{console.info("start auto getting refreshed Remotely Save access token.");const t=yield fetch(`${oe}/api/v1/oauth2/token`,{method:"POST",body:new URLSearchParams({grant_type:"refresh_token",refresh_token:l,client_id:e,scope:"pro.list.read"})}),r=yield t.json();return console.info("finish auto getting refreshed Remotely Save access token."),r}catch(e){throw console.error(e),e}})));var l;if(yield de(e,a,t),void 0!==a.error)throw Error("cannot update accessToken");return a.access_token})),ue=(e,t,i)=>r(void 0,void 0,void 0,(function*(){const r=yield ce(e,i),n=yield fetch(`${oe}/api/v1/pro/list`,{method:"GET",headers:{Authorization:`Bearer ${r}`,"REMOTELYSAVE-API-Plugin-Ver":t}}),o=yield n.json();return e.enabledProFeatures=o.proFeatures,yield null==i?void 0:i(),o})),pe=(e,t,i)=>r(void 0,void 0,void 0,(function*(){const r=yield ce(e,i),n=yield fetch(`${oe}/api/v1/profile/list`,{method:"GET",headers:{Authorization:`Bearer ${r}`,"REMOTELYSAVE-API-Plugin-Ver":t}}),o=yield n.json();return e.email=o.email,yield null==i?void 0:i(),o}));var he=__webpack_require__(57975);const fe=new Set(["Deserialize","Serialize","Retry","Sign"]);class me{constructor(e){var t;this._policies=[],this._policies=null!==(t=null==e?void 0:e.slice(0))&&void 0!==t?t:[],this._orderedPolicies=void 0}addPolicy(e,t={}){if(t.phase&&t.afterPhase)throw new Error("Policies inside a phase cannot specify afterPhase.");if(t.phase&&!fe.has(t.phase))throw new Error(`Invalid phase name: ${t.phase}`);if(t.afterPhase&&!fe.has(t.afterPhase))throw new Error(`Invalid afterPhase name: ${t.afterPhase}`);this._policies.push({policy:e,options:t}),this._orderedPolicies=void 0}removePolicy(e){const t=[];return this._policies=this._policies.filter((r=>!(e.name&&r.policy.name===e.name||e.phase&&r.options.phase===e.phase)||(t.push(r.policy),!1))),this._orderedPolicies=void 0,t}sendRequest(e,t){return this.getOrderedPolicies().reduceRight(((e,t)=>r=>t.sendRequest(r,e)),(t=>e.sendRequest(t)))(t)}getOrderedPolicies(){return this._orderedPolicies||(this._orderedPolicies=this.orderPolicies()),this._orderedPolicies}clone(){return new me(this._policies)}static create(){return new me}orderPolicies(){const e=[],t=new Map;function r(e){return{name:e,policies:new Set,hasRun:!1,hasAfterPolicies:!1}}const i=r("Serialize"),n=r("None"),o=r("Deserialize"),s=r("Retry"),a=r("Sign"),l=[i,n,o,s,a];function d(e){return"Retry"===e?s:"Serialize"===e?i:"Deserialize"===e?o:"Sign"===e?a:n}for(const e of this._policies){const r=e.policy,i=e.options,n=r.name;if(t.has(n))throw new Error("Duplicate policy names not allowed in pipeline");const o={policy:r,dependsOn:new Set,dependants:new Set};i.afterPhase&&(o.afterPhase=d(i.afterPhase),o.afterPhase.hasAfterPolicies=!0),t.set(n,o);d(i.phase).policies.add(o)}for(const e of this._policies){const{policy:r,options:i}=e,n=r.name,o=t.get(n);if(!o)throw new Error(`Missing node for policy ${n}`);if(i.afterPolicies)for(const e of i.afterPolicies){const r=t.get(e);r&&(o.dependsOn.add(r),r.dependants.add(o))}if(i.beforePolicies)for(const e of i.beforePolicies){const r=t.get(e);r&&(r.dependsOn.add(o),o.dependants.add(r))}}function c(r){r.hasRun=!0;for(const i of r.policies)if((!i.afterPhase||i.afterPhase.hasRun&&!i.afterPhase.policies.size)&&0===i.dependsOn.size){e.push(i.policy);for(const e of i.dependants)e.dependsOn.delete(i);t.delete(i.policy.name),r.policies.delete(i)}}function u(){for(const e of l){if(c(e),e.policies.size>0&&e!==n)return void(n.hasRun||c(n));e.hasAfterPolicies&&c(n)}}let p=0;for(;t.size>0;){p++;const t=e.length;if(u(),e.length<=t&&p>1)throw new Error("Cannot satisfy policy dependencies due to requirements cycle.")}return e}}function ge(){return me.create()}var ye=__webpack_require__(65606);const ve=void(void 0!==ye&&ye.env);let be,we=[],_e=[];const xe=[];ve&&ke(ve);const Se=Object.assign((e=>Te(e)),{enable:ke,enabled:Ee,disable:function(){const e=be||"";return ke(""),e},log:function(...e){if(e.length>0){const t=String(e[0]);t.includes(":error")?console.error(...e):t.includes(":warning")?console.warn(...e):t.includes(":info")?console.info(...e):(t.includes(":verbose"),console.debug(...e))}}});function ke(e){be=e,we=[],_e=[];const t=/\*/g,r=e.split(",").map((e=>e.trim().replace(t,".*?")));for(const e of r)e.startsWith("-")?_e.push(new RegExp(`^${e.substr(1)}$`)):we.push(new RegExp(`^${e}$`));for(const e of xe)e.enabled=Ee(e.namespace)}function Ee(e){if(e.endsWith("*"))return!0;for(const t of _e)if(t.test(e))return!1;for(const t of we)if(t.test(e))return!0;return!1}function Te(e){const t=Object.assign((function(...r){if(!t.enabled)return;r.length>0&&(r[0]=`${e} ${r[0]}`);t.log(...r)}),{enabled:Ee(e),destroy:Be,log:Se.log,namespace:e,extend:Ce});return xe.push(t),t}function Be(){const e=xe.indexOf(this);return e>=0&&(xe.splice(e,1),!0)}function Ce(e){const t=Te(`${this.namespace}:${e}`);return t.log=this.log,t}const Ie=Se;var Ae=__webpack_require__(65606);const Fe=new Set,Me=void 0!==Ae&&Ae.env&&Ae.env.AZURE_LOG_LEVEL||void 0;let De;const Re=Ie("azure");Re.log=(...e)=>{Ie.log(...e)};const Pe=["verbose","info","warning","error"];Me&&(Le(Me)?function(e){if(e&&!Le(e))throw new Error(`Unknown log level '${e}'. Acceptable values: ${Pe.join(",")}`);De=e;const t=[];for(const e of Fe)Ue(e)&&t.push(e.namespace);Ie.enable(t.join(","))}(Me):console.error(`AZURE_LOG_LEVEL set to unknown log level '${Me}'; logging is not enabled. Acceptable values: ${Pe.join(", ")}.`));const Oe={verbose:400,info:300,warning:200,error:100};function ze(e){const t=Re.extend(e);return Ne(Re,t),{error:qe(t,"error"),warning:qe(t,"warning"),info:qe(t,"info"),verbose:qe(t,"verbose")}}function Ne(e,t){t.log=(...t)=>{e.log(...t)}}function qe(e,t){const r=Object.assign(e.extend(t),{level:t});if(Ne(e,r),Ue(r)){const e=Ie.disable();Ie.enable(e+","+r.namespace)}return Fe.add(r),r}function Ue(e){return Boolean(De&&Oe[e.level]<=Oe[De])}function Le(e){return Pe.includes(e)}const je=ze("core-rest-pipeline");class He extends Error{constructor(e){super(e),this.name="AbortError"}}function $e(e,t){let r;const{abortSignal:i,abortErrorMsg:n}=null!=t?t:{};return function(e,t){const{cleanupBeforeAbort:r,abortSignal:i,abortErrorMsg:n}=null!=t?t:{};return new Promise(((t,o)=>{function s(){o(new He(null!=n?n:"The operation was aborted."))}function a(){null==i||i.removeEventListener("abort",l)}function l(){null==r||r(),a(),s()}if(null==i?void 0:i.aborted)return s();try{e((e=>{a(),t(e)}),(e=>{a(),o(e)}))}catch(e){o(e)}null==i||i.addEventListener("abort",l)}))}((t=>{r=setTimeout(t,e)}),{cleanupBeforeAbort:()=>clearTimeout(r),abortSignal:i,abortErrorMsg:null!=n?n:"The delay was aborted."})}function Ge(e){return!("object"!=typeof e||null===e||Array.isArray(e)||e instanceof RegExp||e instanceof Date)}function We(e){if(Ge(e)){const t="string"==typeof e.name,r="string"==typeof e.message;return t&&r}return!1}function Ke(e){if(We(e))return e.message;{let t;try{t="object"==typeof e&&e?JSON.stringify(e):String(e)}catch(e){t="[unable to stringify input]"}return`Unknown error ${t}`}}function Ve(e,t){switch(t){case"utf-8":return function(e){return(new TextEncoder).encode(e)}(e);case"base64":return Je(e);case"base64url":return function(e){const t=e.replace(/-/g,"+").replace(/_/g,"/");return Je(t)}(e);case"hex":return function(e){const t=new Uint8Array(e.length/2);for(let r=0;re.charCodeAt(0))))}const Ye=new Set("0123456789abcdefABCDEF");function Qe(){let e="";for(let t=0;t<32;t++){const r=Math.floor(16*Math.random());e+=12===t?"4":16===t?3&r|8:r.toString(16),7!==t&&11!==t&&15!==t&&19!==t||(e+="-")}return e}var Ze;const Xe="function"==typeof(null===(Ze=null===globalThis||void 0===globalThis?void 0:globalThis.crypto)||void 0===Ze?void 0:Ze.randomUUID)?globalThis.crypto.randomUUID.bind(globalThis.crypto):Qe;function et(){return Xe()}var tt,rt,it;"undefined"!=typeof window&&window.document,"object"==typeof self&&"function"==typeof(null===self||void 0===self?void 0:self.importScripts)&&("DedicatedWorkerGlobalScope"===(null===(tt=self.constructor)||void 0===tt?void 0:tt.name)||"ServiceWorkerGlobalScope"===(null===(rt=self.constructor)||void 0===rt?void 0:rt.name)||null===(it=self.constructor)||void 0===it||it.name),"undefined"!=typeof Deno&&void 0!==Deno.version&&Deno.version.deno,"undefined"!=typeof Bun&&Bun.version;const nt=void 0!==globalThis.process&&Boolean(globalThis.process.version)&&Boolean(void 0),ot=nt,st=("undefined"!=typeof navigator&&(null===navigator||void 0===navigator||navigator.product),"REDACTED"),at=["x-ms-client-request-id","x-ms-return-client-request-id","x-ms-useragent","x-ms-correlation-request-id","x-ms-request-id","client-request-id","ms-cv","return-client-request-id","traceparent","Access-Control-Allow-Credentials","Access-Control-Allow-Headers","Access-Control-Allow-Methods","Access-Control-Allow-Origin","Access-Control-Expose-Headers","Access-Control-Max-Age","Access-Control-Request-Headers","Access-Control-Request-Method","Origin","Accept","Accept-Encoding","Cache-Control","Connection","Content-Length","Content-Type","Date","ETag","Expires","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","Last-Modified","Pragma","Request-Id","Retry-After","Server","Transfer-Encoding","User-Agent","WWW-Authenticate"],lt=["api-version"];class dt{constructor({additionalAllowedHeaderNames:e=[],additionalAllowedQueryParameters:t=[]}={}){e=at.concat(e),t=lt.concat(t),this.allowedHeaderNames=new Set(e.map((e=>e.toLowerCase()))),this.allowedQueryParameters=new Set(t.map((e=>e.toLowerCase())))}sanitize(e){const t=new Set;return JSON.stringify(e,((e,r)=>{if(r instanceof Error)return Object.assign(Object.assign({},r),{name:r.name,message:r.message});if("headers"===e)return this.sanitizeHeaders(r);if("url"===e)return this.sanitizeUrl(r);if("query"===e)return this.sanitizeQuery(r);if("body"!==e&&"response"!==e&&"operationSpec"!==e){if(Array.isArray(r)||Ge(r)){if(t.has(r))return"[Circular]";t.add(r)}return r}}),2)}sanitizeUrl(e){if("string"!=typeof e||null===e||""===e)return e;const t=new URL(e);if(!t.search)return e;for(const[e]of t.searchParams)this.allowedQueryParameters.has(e.toLowerCase())||t.searchParams.set(e,st);return t.toString()}sanitizeHeaders(e){const t={};for(const r of Object.keys(e))this.allowedHeaderNames.has(r.toLowerCase())?t[r]=e[r]:t[r]=st;return t}sanitizeQuery(e){if("object"!=typeof e||null===e)return e;const t={};for(const r of Object.keys(e))this.allowedQueryParameters.has(r.toLowerCase())?t[r]=e[r]:t[r]=st;return t}}const ct="redirectPolicy",ut=["GET","HEAD"];function pt(e={}){const{maxRetries:t=20}=e;return{name:ct,async sendRequest(e,r){const i=await r(e);return ht(r,i,t)}}}async function ht(e,t,r,i=0){const{request:n,status:o,headers:s}=t,a=s.get("location");if(a&&(300===o||301===o&&ut.includes(n.method)||302===o&&ut.includes(n.method)||303===o&&"POST"===n.method||307===o)&&ie.brand===r));if(t)return t}}(t.userAgentData.brands);n&&e.set(n.brand,n.version)}else if(null==t?void 0:t.platform){r=t.platform;const i=function(e){const t=[{name:"Firefox",regex:/Firefox\/([\d.]+)/},{name:"Safari",regex:/Version\/([\d.]+).*Safari/}];for(const r of t){const t=e.match(r.regex);if(t)return{brand:r.name,version:t[1]}}}(t.userAgent);i&&e.set(i.brand,i.version)}else"string"==typeof globalThis.EdgeRuntime&&e.set("EdgeRuntime",globalThis.EdgeRuntime);e.set("OS",r)}(t);const r=function(e){const t=[];for(const[r,i]of e){const e=i?`${r}/${i}`:r;t.push(e)}return t.join(" ")}(t);return e?`${e} ${r}`:r}const gt="x-ms-useragent";const yt=Symbol("rawContent");function vt(e){return function(e){return"function"==typeof e[yt]}(e)?e[yt]():e.stream()}function bt(e){return Boolean(e&&"function"==typeof e.pipe)}function wt(e){return Boolean(e&&"function"==typeof e.getReader&&"function"==typeof e.tee)}async function _t(e){if(e instanceof Blob||e instanceof Uint8Array)return e;if(wt(e))return new Response(e).blob();const t=vt(e);if(bt(t))throw new Error("Encountered unexpected type. In the browser, `concat` supports Web ReadableStream, Blob, Uint8Array, and files created using `createFile` only.");return _t(t)}function xt(e){let t="";for(const[r,i]of e)t+=`${r}: ${i}\r\n`;return t}function St(e){return e instanceof Uint8Array?e.byteLength:function(e){return"function"==typeof e.stream}(e)?-1===e.size?void 0:e.size:void 0}async function kt(e,t,r){const i=[Ve(`--${r}`,"utf-8"),...t.flatMap((e=>[Ve("\r\n","utf-8"),Ve(xt(e.headers),"utf-8"),Ve("\r\n","utf-8"),e.body,Ve(`\r\n--${r}`,"utf-8")])),Ve("--\r\n\r\n","utf-8")],n=function(e){let t=0;for(const r of e){const e=St(r);if(void 0===e)return;t+=e}return t}(i);n&&e.headers.set("Content-Length",n),e.body=await async function(e){const t=[];for(const r of e)t.push(await _t("function"==typeof r?r():r));return new Blob(t)}(i)}const Et="multipartPolicy",Tt=new Set("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");function Bt(){return{name:Et,async sendRequest(e,t){var r;if(!e.multipartBody)return t(e);if(e.body)throw new Error("multipartBody and regular body cannot be set at the same time");let i=e.multipartBody.boundary;const n=null!==(r=e.headers.get("Content-Type"))&&void 0!==r?r:"multipart/mixed",o=n.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!o)throw new Error(`Got multipart request body, but content-type header was not multipart: ${n}`);const[,s,a]=o;if(a&&i&&a!==i)throw new Error(`Multipart boundary was specified as ${a} in the header, but got ${i} in the request body`);return null!=i||(i=a),i?function(e){if(e.length>70)throw new Error(`Multipart boundary "${e}" exceeds maximum length of 70 characters`);if(Array.from(e).some((e=>!Tt.has(e))))throw new Error(`Multipart boundary "${e}" contains invalid characters`)}(i):i=`----AzSDKFormBoundary${et()}`,e.headers.set("Content-Type",`${s}; boundary=${i}`),await kt(e,e.multipartBody.parts,i),e.multipartBody=void 0,t(e)}}}function Ct(e,t,r){return new Promise(((i,n)=>{let o,s;const a=()=>n(new He((null==r?void 0:r.abortErrorMsg)?null==r?void 0:r.abortErrorMsg:"The operation was aborted.")),l=()=>{(null==r?void 0:r.abortSignal)&&s&&r.abortSignal.removeEventListener("abort",s)};if(s=()=>(o&&clearTimeout(o),l(),a()),(null==r?void 0:r.abortSignal)&&r.abortSignal.aborted)return a();o=setTimeout((()=>{l(),i(t)}),e),(null==r?void 0:r.abortSignal)&&r.abortSignal.addEventListener("abort",s)}))}function It(e,t){const r=e.headers.get(t);if(!r)return;const i=Number(r);return Number.isNaN(i)?void 0:i}const At="Retry-After",Ft=["retry-after-ms","x-ms-retry-after-ms",At];function Mt(e){if(e&&[429,503].includes(e.status))try{for(const t of Ft){const r=It(e,t);if(0===r||r){return r*(t===At?1e3:1)}}const t=e.headers.get(At);if(!t)return;const r=Date.parse(t)-Date.now();return Number.isFinite(r)?Math.max(0,r):void 0}catch(e){return}}function Dt(e={}){var t,r;const i=null!==(t=e.retryDelayInMs)&&void 0!==t?t:1e3,n=null!==(r=e.maxRetryDelayInMs)&&void 0!==r?r:64e3;let o=i;return{name:"exponentialRetryStrategy",retry({retryCount:t,response:r,responseError:i}){const s=function(e){if(!e)return!1;return"ETIMEDOUT"===e.code||"ESOCKETTIMEDOUT"===e.code||"ECONNREFUSED"===e.code||"ECONNRESET"===e.code||"ENOENT"===e.code||"ENOTFOUND"===e.code}(i),a=s&&e.ignoreSystemErrors,l=function(e){return Boolean(e&&void 0!==e.status&&(e.status>=500||408===e.status)&&501!==e.status&&505!==e.status)}(r),d=l&&e.ignoreHttpStatusCodes,c=r&&(function(e){return Number.isFinite(Mt(e))}(r)||!l);if(c||d||a)return{skipStrategy:!0};if(i&&!s&&!l)return{errorToThrow:i};const u=o*Math.pow(2,t),p=Math.min(n,u);var h,f;return o=p/2+(h=0,f=p/2,h=Math.ceil(h),f=Math.floor(f),Math.floor(Math.random()*(f-h+1))+h),{retryAfterInMs:o}}}}const Rt=ze("core-rest-pipeline retryPolicy");function Pt(e,t={maxRetries:3}){const r=t.logger||Rt;return{name:"retryPolicy",async sendRequest(i,n){var o,s;let a,l,d=-1;e:for(;;){d+=1,a=void 0,l=void 0;try{r.info(`Retry ${d}: Attempting to send request`,i.requestId),a=await n(i),r.info(`Retry ${d}: Received a response from request`,i.requestId)}catch(e){if(r.error(`Retry ${d}: Received an error from request`,i.requestId),l=e,!e||"RestError"!==l.name)throw e;a=l.response}if(null===(o=i.abortSignal)||void 0===o?void 0:o.aborted){r.error(`Retry ${d}: Request aborted.`);throw new He}if(d>=(null!==(s=t.maxRetries)&&void 0!==s?s:3)){if(r.info(`Retry ${d}: Maximum retries reached. Returning the last received response, or throwing the last received error.`),l)throw l;if(a)return a;throw new Error("Maximum retries reached with no response or error to throw")}r.info(`Retry ${d}: Processing ${e.length} retry strategies.`);t:for(const t of e){const e=t.logger||Rt;e.info(`Retry ${d}: Processing retry strategy ${t.name}.`);const r=t.retry({retryCount:d,response:a,responseError:l});if(r.skipStrategy){e.info(`Retry ${d}: Skipped.`);continue t}const{errorToThrow:n,retryAfterInMs:o,redirectTo:s}=r;if(n)throw e.error(`Retry ${d}: Retry strategy ${t.name} throws error:`,n),n;if(o||0===o){e.info(`Retry ${d}: Retry strategy ${t.name} retries after ${o}`),await Ct(o,void 0,{abortSignal:i.abortSignal});continue e}if(s){e.info(`Retry ${d}: Retry strategy ${t.name} redirects to ${s}`),i.url=s;continue e}}if(l)throw r.info("None of the retry strategies could work with the received error. Throwing it."),l;if(a)return r.info("None of the retry strategies could work with the received response. Returning it."),a}}}}function Ot(e){return e.toLowerCase()}class zt{constructor(e){if(this._headersMap=new Map,e)for(const t of Object.keys(e))this.set(t,e[t])}set(e,t){this._headersMap.set(Ot(e),{name:e,value:String(t).trim()})}get(e){var t;return null===(t=this._headersMap.get(Ot(e)))||void 0===t?void 0:t.value}has(e){return this._headersMap.has(Ot(e))}delete(e){this._headersMap.delete(Ot(e))}toJSON(e={}){const t={};if(e.preserveCase)for(const e of this._headersMap.values())t[e.name]=e.value;else for(const[e,r]of this._headersMap)t[e]=r.value;return t}toString(){return JSON.stringify(this.toJSON({preserveCase:!0}))}[Symbol.iterator](){return function*(e){for(const t of e.values())yield[t.name,t.value]}(this._headersMap)}}function Nt(e){return new zt(e)}function qt(){return{name:"formDataPolicy",async sendRequest(e,t){if(nt&&"undefined"!=typeof FormData&&e.body instanceof FormData&&(e.formData=function(e){var t;const r={};for(const[i,n]of e.entries())null!==(t=r[i])&&void 0!==t||(r[i]=[]),r[i].push(n);return r}(e.body),e.body=void 0),e.formData){const t=e.headers.get("Content-Type");t&&-1!==t.indexOf("application/x-www-form-urlencoded")?e.body=function(e){const t=new URLSearchParams;for(const[r,i]of Object.entries(e))if(Array.isArray(i))for(const e of i)t.append(r,e.toString());else t.append(r,i.toString());return t.toString()}(e.formData):await async function(e,t){const r=t.headers.get("Content-Type");if(r&&!r.startsWith("multipart/form-data"))return;t.headers.set("Content-Type",null!=r?r:"multipart/form-data");const i=[];for(const[t,r]of Object.entries(e))for(const e of Array.isArray(r)?r:[r])if("string"==typeof e)i.push({headers:Nt({"Content-Disposition":`form-data; name="${t}"`}),body:Ve(e,"utf-8")});else{if(null==e||"object"!=typeof e)throw new Error(`Unexpected value for key ${t}: ${e}. Value should be serialized to string first.`);{const r=e.name||"blob",n=Nt();n.set("Content-Disposition",`form-data; name="${t}"; filename="${r}"`),n.set("Content-Type",e.type||"application/octet-stream"),i.push({headers:n,body:e})}}t.multipartBody={parts:i}}(e.formData,e),e.formData=void 0}return t(e)}}}const Ut="proxyPolicy is not supported in browser environment";function Lt(){throw new Error(Ut)}const jt={span:Symbol.for("@azure/core-tracing span"),namespace:Symbol.for("@azure/core-tracing namespace")};function Ht(e={}){let t=new $t(e.parentContext);return e.span&&(t=t.setValue(jt.span,e.span)),e.namespace&&(t=t.setValue(jt.namespace,e.namespace)),t}class $t{constructor(e){this._contextMap=e instanceof $t?new Map(e._contextMap):new Map}setValue(e,t){const r=new $t(this);return r._contextMap.set(e,t),r}getValue(e){return this._contextMap.get(e)}deleteValue(e){const t=new $t(this);return t._contextMap.delete(e),t}}const Gt={instrumenterImplementation:void 0};function Wt(){return Gt.instrumenterImplementation||(Gt.instrumenterImplementation={createRequestHeaders:()=>({}),parseTraceparentHeader:()=>{},startSpan:(e,t)=>({span:{end:()=>{},isRecording:()=>!1,recordException:()=>{},setAttribute:()=>{},setStatus:()=>{},addEvent:()=>{}},tracingContext:Ht({parentContext:t.tracingContext})}),withContext:(e,t,...r)=>t(...r)}),Gt.instrumenterImplementation}function Kt(e){const{namespace:t,packageName:r,packageVersion:i}=e;function n(e,n,o){var s;const a=Wt().startSpan(e,Object.assign(Object.assign({},o),{packageName:r,packageVersion:i,tracingContext:null===(s=null==n?void 0:n.tracingOptions)||void 0===s?void 0:s.tracingContext}));let l=a.tracingContext;const d=a.span;l.getValue(jt.namespace)||(l=l.setValue(jt.namespace,t)),d.setAttribute("az.namespace",l.getValue(jt.namespace));return{span:d,updatedOptions:Object.assign({},n,{tracingOptions:Object.assign(Object.assign({},null==n?void 0:n.tracingOptions),{tracingContext:l})})}}function o(e,t,...r){return Wt().withContext(e,t,...r)}return{startSpan:n,withSpan:async function(e,t,r,i){const{span:s,updatedOptions:a}=n(e,t,i);try{const e=await o(a.tracingOptions.tracingContext,(()=>Promise.resolve(r(a,s))));return s.setStatus({status:"success"}),e}catch(e){throw s.setStatus({status:"error",error:e}),e}finally{s.end()}},withContext:o,parseTraceparentHeader:function(e){return Wt().parseTraceparentHeader(e)},createRequestHeaders:function(e){return Wt().createRequestHeaders(e)}}}const Vt={},Jt=new dt;class Yt extends Error{constructor(e,t={}){super(e),this.name="RestError",this.code=t.code,this.statusCode=t.statusCode,Object.defineProperty(this,"request",{value:t.request,enumerable:!1}),Object.defineProperty(this,"response",{value:t.response,enumerable:!1}),Object.setPrototypeOf(this,Yt.prototype)}[Vt](){return`RestError: ${this.message} \n ${Jt.sanitize(Object.assign(Object.assign({},this),{request:this.request,response:this.response}))}`}}function Qt(e){return e instanceof Yt||We(e)&&"RestError"===e.name}Yt.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR",Yt.PARSE_ERROR="PARSE_ERROR";function Zt(e={}){const t=mt(e.userAgentPrefix),r=new dt({additionalAllowedQueryParameters:e.additionalAllowedQueryParameters}),i=function(){try{return Kt({namespace:"",packageName:"@azure/core-rest-pipeline",packageVersion:ft})}catch(e){return void je.warning(`Error when creating the TracingClient: ${Ke(e)}`)}}();return{name:"tracingPolicy",async sendRequest(e,n){var o;if(!i)return n(e);const s=await t,a={"http.url":r.sanitizeUrl(e.url),"http.method":e.method,"http.user_agent":s,requestId:e.requestId};s&&(a["http.user_agent"]=s);const{span:l,tracingContext:d}=null!==(o=function(e,t,r){try{const{span:i,updatedOptions:n}=e.startSpan(`HTTP ${t.method}`,{tracingOptions:t.tracingOptions},{spanKind:"client",spanAttributes:r});if(!i.isRecording())return void i.end();const o=e.createRequestHeaders(n.tracingOptions.tracingContext);for(const[e,r]of Object.entries(o))t.headers.set(e,r);return{span:i,tracingContext:n.tracingOptions.tracingContext}}catch(e){return void je.warning(`Skipping creating a tracing span due to an error: ${Ke(e)}`)}}(i,e,a))&&void 0!==o?o:{};if(!l||!d)return n(e);try{const t=await i.withContext(d,n,e);return function(e,t){try{e.setAttribute("http.status_code",t.status);const r=t.headers.get("x-ms-request-id");r&&e.setAttribute("serviceRequestId",r),e.setStatus({status:"success"}),e.end()}catch(e){je.warning(`Skipping tracing span processing due to an error: ${Ke(e)}`)}}(l,t),t}catch(e){throw function(e,t){try{e.setStatus({status:"error",error:We(t)?t:void 0}),Qt(t)&&t.statusCode&&e.setAttribute("http.status_code",t.statusCode),e.end()}catch(e){je.warning(`Skipping tracing span processing due to an error: ${Ke(e)}`)}}(l,e),e}}}}function Xt(e){var t;const r=ge();var i;return nt&&(e.tlsOptions&&r.addPolicy((i=e.tlsOptions,{name:"tlsPolicy",sendRequest:async(e,t)=>(e.tlsSettings||(e.tlsSettings=i),t(e))})),r.addPolicy(function(){throw new Error(Ut)}(e.proxyOptions)),r.addPolicy(function(){throw new Error("decompressResponsePolicy is not supported in browser environment")}())),r.addPolicy(qt(),{beforePolicies:[Et]}),r.addPolicy(function(e={}){const t=mt(e.userAgentPrefix);return{name:"userAgentPolicy",sendRequest:async(e,r)=>(e.headers.has(gt)||e.headers.set(gt,await t),r(e))}}(e.userAgentOptions)),r.addPolicy(function(e="x-ms-client-request-id"){return{name:"setClientRequestIdPolicy",sendRequest:async(t,r)=>(t.headers.has(e)||t.headers.set(e,t.requestId),r(t))}}(null===(t=e.telemetryOptions)||void 0===t?void 0:t.clientRequestIdHeaderName)),r.addPolicy(Bt(),{afterPhase:"Deserialize"}),r.addPolicy(function(e={}){var t;return{name:"defaultRetryPolicy",sendRequest:Pt([{name:"throttlingRetryStrategy",retry({response:e}){const t=Mt(e);return Number.isFinite(t)?{retryAfterInMs:t}:{skipStrategy:!0}}},Dt(e)],{maxRetries:null!==(t=e.maxRetries)&&void 0!==t?t:3}).sendRequest}}(e.retryOptions),{phase:"Retry"}),r.addPolicy(Zt(Object.assign(Object.assign({},e.userAgentOptions),e.loggingOptions)),{afterPhase:"Retry"}),nt&&r.addPolicy(pt(e.redirectOptions),{afterPhase:"Retry"}),r.addPolicy(function(e={}){var t;const r=null!==(t=e.logger)&&void 0!==t?t:je.info,i=new dt({additionalAllowedHeaderNames:e.additionalAllowedHeaderNames,additionalAllowedQueryParameters:e.additionalAllowedQueryParameters});return{name:"logPolicy",async sendRequest(e,t){if(!r.enabled)return t(e);r(`Request: ${i.sanitize(e)}`);const n=await t(e);return r(`Response status code: ${n.status}`),r(`Headers: ${i.sanitize(n.headers)}`),n}}}(e.loggingOptions),{afterPhase:"Sign"}),r}class er{async sendRequest(e){if("https:"!==new URL(e.url).protocol&&!e.allowInsecureConnection)throw new Error(`Cannot connect to ${e.url} while allowInsecureConnection is false.`);if(e.proxySettings)throw new Error("HTTP proxy is not supported in browser environment");try{return await async function(e){const{abortController:t,abortControllerCleanup:r}=function(e){const t=new AbortController;let r,i;if(e.abortSignal){if(e.abortSignal.aborted)throw new He("The operation was aborted.");i=e=>{"abort"===e.type&&t.abort()},e.abortSignal.addEventListener("abort",i),r=()=>{var t;i&&(null===(t=e.abortSignal)||void 0===t||t.removeEventListener("abort",i))}}e.timeout>0&&setTimeout((()=>{t.abort()}),e.timeout);return{abortController:t,abortControllerCleanup:r}}(e);try{const i=function(e){const t=new Headers;for(const[r,i]of e)t.append(r,i);return t}(e.headers),{streaming:n,body:o}=function(e){const t="function"==typeof e.body?e.body():e.body;if(bt(t))throw new Error("Node streams are not supported in browser environment.");return wt(t)?{streaming:!0,body:tr(t,{onProgress:e.onUploadProgress})}:{streaming:!1,body:t}}(e),s=Object.assign(Object.assign({body:o,method:e.method,headers:i,signal:t.signal},"credentials"in Request.prototype?{credentials:e.withCredentials?"include":"same-origin"}:{}),"cache"in Request.prototype?{cache:"no-store"}:{});n&&(s.duplex="half");const a=await fetch(e.url,s);return function(e){return("function"==typeof Blob||"object"==typeof Blob)&&e instanceof Blob}(e.body)&&e.onUploadProgress&&e.onUploadProgress({loadedBytes:e.body.size}),async function(e,t,r){var i,n;const o=function(e){const t=Nt();for(const[r,i]of e.headers)t.set(r,i);return t}(e),s={request:t,headers:o,status:e.status},a=wt(e.body)?tr(e.body,{onProgress:t.onDownloadProgress,onEnd:r}):e.body;if((null===(i=t.streamResponseStatusCodes)||void 0===i?void 0:i.has(Number.POSITIVE_INFINITY))||(null===(n=t.streamResponseStatusCodes)||void 0===n?void 0:n.has(s.status)))if(t.enableBrowserStreams)s.browserStreamBody=null!=a?a:void 0;else{const e=new Response(a);s.blobBody=e.blob(),null==r||r()}else{const e=new Response(a);s.bodyAsText=await e.text(),null==r||r()}return s}(a,e,r)}catch(e){throw null==r||r(),e}}(e)}catch(t){throw function(e,t){var r;return e&&"AbortError"===(null==e?void 0:e.name)?e:new Yt(`Error sending request: ${e.message}`,{code:null!==(r=null==e?void 0:e.code)&&void 0!==r?r:Yt.REQUEST_SEND_ERROR,request:t})}(t,e)}}}function tr(e,t={}){let r=0;const{onProgress:i,onEnd:n}=t;if(function(e){return void 0!==e.pipeThrough&&void 0!==self.TransformStream}(e))return e.pipeThrough(new TransformStream({transform(e,t){null!==e?(t.enqueue(e),r+=e.length,i&&i({loadedBytes:r})):t.terminate()},flush(){null==n||n()}}));{const t=e.getReader();return new ReadableStream({async pull(e){var o;const{done:s,value:a}=await t.read();if(s||!a)return null==n||n(),e.close(),void t.releaseLock();r+=null!==(o=null==a?void 0:a.length)&&void 0!==o?o:0,e.enqueue(a),i&&i({loadedBytes:r})},cancel:e=>(null==n||n(),t.cancel(e))})}}function rr(){return new er}class ir{constructor(e){var t,r,i,n,o,s,a;this.url=e.url,this.body=e.body,this.headers=null!==(t=e.headers)&&void 0!==t?t:Nt(),this.method=null!==(r=e.method)&&void 0!==r?r:"GET",this.timeout=null!==(i=e.timeout)&&void 0!==i?i:0,this.multipartBody=e.multipartBody,this.formData=e.formData,this.disableKeepAlive=null!==(n=e.disableKeepAlive)&&void 0!==n&&n,this.proxySettings=e.proxySettings,this.streamResponseStatusCodes=e.streamResponseStatusCodes,this.withCredentials=null!==(o=e.withCredentials)&&void 0!==o&&o,this.abortSignal=e.abortSignal,this.tracingOptions=e.tracingOptions,this.onUploadProgress=e.onUploadProgress,this.onDownloadProgress=e.onDownloadProgress,this.requestId=e.requestId||et(),this.allowInsecureConnection=null!==(s=e.allowInsecureConnection)&&void 0!==s&&s,this.enableBrowserStreams=null!==(a=e.enableBrowserStreams)&&void 0!==a&&a}}function nr(e){return new ir(e)}const or={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:12e4};function sr(e,t){let r,i=null,n=null;const o=Object.assign(Object.assign({},or),t),s={get isRefreshing(){return null!==i},get shouldRefresh(){var e;return!s.isRefreshing&&(!!((null==n?void 0:n.refreshAfterTimestamp)&&n.refreshAfterTimestampe.getToken(t,a)),o.retryIntervalInMs,null!==(l=null==n?void 0:n.expiresOnTimestamp)&&void 0!==l?l:Date.now()).then((e=>(i=null,n=e,r=a.tenantId,n))).catch((e=>{throw i=null,n=null,r=void 0,e}))}return i}return async(e,t)=>{const i=Boolean(t.claims),o=r!==t.tenantId;i&&(n=null);return o||i||s.mustRefresh?a(e,t):(s.shouldRefresh&&a(e,t),n)}}async function ar(e){const{scopes:t,getAccessToken:r,request:i}=e,n={abortSignal:i.abortSignal,tracingOptions:i.tracingOptions},o=await r(t,n);o&&e.request.headers.set("Authorization",`Bearer ${o.token}`)}function lr(e){var t;const{credential:r,scopes:i,challengeCallbacks:n}=e,o=e.logger||je,s=Object.assign({authorizeRequest:null!==(t=null==n?void 0:n.authorizeRequest)&&void 0!==t?t:ar,authorizeRequestOnChallenge:null==n?void 0:n.authorizeRequestOnChallenge},n),a=r?sr(r):()=>Promise.resolve(null);return{name:"bearerTokenAuthenticationPolicy",async sendRequest(e,t){if(!e.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.");let r,n;await s.authorizeRequest({scopes:Array.isArray(i)?i:[i],request:e,getAccessToken:a,logger:o});try{r=await t(e)}catch(e){n=e,r=e.response}if(s.authorizeRequestOnChallenge&&401===(null==r?void 0:r.status)&&function(e){const t=e.headers.get("WWW-Authenticate");if(401===e.status&&t)return t}(r)){if(await s.authorizeRequestOnChallenge({scopes:Array.isArray(i)?i:[i],request:e,response:r,getAccessToken:a,logger:o}))return t(e)}if(n)throw n;return r}}}function dr(e){const t=e;return t&&"function"==typeof t.getToken&&(void 0===t.signRequest||t.getToken.length>0)}class cr{constructor(e,t){this._nextPolicy=e,this._options=t}shouldLog(e){return this._options.shouldLog(e)}log(e,t){this._options.log(e,t)}}class ur extends cr{sendRequest(e){return this._nextPolicy.sendRequest(this.signRequest(e))}signRequest(e){return e}}class pr extends ur{constructor(e,t){super(e,t)}}class hr{create(e,t){throw new Error("Method should be implemented in children classes.")}}class fr extends hr{create(e,t){return new pr(e,t)}}class mr{}const gr="DisableKeepAlivePolicy";function yr(e){let t="";for(let r=0;r""===l[e].serializedName));if("Sequence"===a||d){const t=null!==(r=e.parsedBody)&&void 0!==r?r:[];for(const r of Object.keys(l))l[r].serializedName&&(t[r]=null===(i=e.parsedBody)||void 0===i?void 0:i[r]);if(n)for(const e of Object.keys(n))t[e]=n[e];return!s||e.parsedBody||n||0!==Object.getOwnPropertyNames(l).length?t:null}return function(e){const t=Object.assign(Object.assign({},e.headers),e.body);return e.hasNullableType&&0===Object.getOwnPropertyNames(t).length?e.shouldWrapBody?{body:null}:null:e.shouldWrapBody?Object.assign(Object.assign({},e.headers),{body:e.body}):t}({body:e.parsedBody,headers:n,hasNullableType:s,shouldWrapBody:(c=e.parsedBody,u=a,"Composite"!==u&&"Dictionary"!==u&&("string"==typeof c||"number"==typeof c||"boolean"==typeof c||null!==(null==u?void 0:u.match(/^(Date|DateTime|DateTimeRfc1123|UnixTime|ByteArray|Base64Url)$/i))||null==c))});var c,u}class kr{constructor(e={},t=!1){this.modelMappers=e,this.isXML=t}validateConstraints(e,t,r){const i=(e,i)=>{throw new Error(`"${r}" with value "${t}" should satisfy the constraint "${e}": ${i}.`)};if(e.constraints&&null!=t){const{ExclusiveMaximum:r,ExclusiveMinimum:n,InclusiveMaximum:o,InclusiveMinimum:s,MaxItems:a,MaxLength:l,MinItems:d,MinLength:c,MultipleOf:u,Pattern:p,UniqueItems:h}=e.constraints;if(void 0!==r&&t>=r&&i("ExclusiveMaximum",r),void 0!==n&&t<=n&&i("ExclusiveMinimum",n),void 0!==o&&t>o&&i("InclusiveMaximum",o),void 0!==s&&ta&&i("MaxItems",a),void 0!==l&&t.length>l&&i("MaxLength",l),void 0!==d&&t.lengthr.indexOf(e)!==t))&&i("UniqueItems",h)}}serialize(e,t,r,i={xml:{}}){var n,o,s;const a={xml:{rootName:null!==(n=i.xml.rootName)&&void 0!==n?n:"",includeRoot:null!==(o=i.xml.includeRoot)&&void 0!==o&&o,xmlCharKey:null!==(s=i.xml.xmlCharKey)&&void 0!==s?s:wr}};let l={};const d=e.type.name;r||(r=e.serializedName),null!==d.match(/^Sequence$/i)&&(l=[]),e.isConstant&&(t=e.defaultValue);const{required:c,nullable:u}=e;if(c&&u&&void 0===t)throw new Error(`${r} cannot be undefined.`);if(c&&!u&&null==t)throw new Error(`${r} cannot be null or undefined.`);if(!c&&!1===u&&null===t)throw new Error(`${r} cannot be null.`);if(null==t)l=t;else if(null!==d.match(/^any$/i))l=t;else if(null!==d.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/i))l=function(e,t,r){if(null!=r)if(null!==e.match(/^Number$/i)){if("number"!=typeof r)throw new Error(`${t} with value ${r} must be of type number.`)}else if(null!==e.match(/^String$/i)){if("string"!=typeof r.valueOf())throw new Error(`${t} with value "${r}" must be of type string.`)}else if(null!==e.match(/^Uuid$/i)){if("string"!=typeof r.valueOf()||(i=r,!xr.test(i)))throw new Error(`${t} with value "${r}" must be of type string and a valid uuid.`)}else if(null!==e.match(/^Boolean$/i)){if("boolean"!=typeof r)throw new Error(`${t} with value ${r} must be of type boolean.`)}else if(null!==e.match(/^Stream$/i)){const e=typeof r;if(!("string"===e||"function"==typeof r.pipe||"function"==typeof r.tee||r instanceof ArrayBuffer||ArrayBuffer.isView(r)||("function"==typeof Blob||"object"==typeof Blob)&&r instanceof Blob||"function"===e))throw new Error(`${t} must be a string, Blob, ArrayBuffer, ArrayBufferView, ReadableStream, or () => ReadableStream.`)}var i;return r}(d,r,t);else if(null!==d.match(/^Enum$/i)){l=function(e,t,r){if(!t)throw new Error(`Please provide a set of allowedValues to validate ${e} as an Enum Type.`);if(!t.some((e=>"string"==typeof e.valueOf()?e.toLowerCase()===r.toLowerCase():e===r)))throw new Error(`${r} is not a valid value for ${e}. The valid values are: ${JSON.stringify(t)}.`);return r}(r,e.type.allowedValues,t)}else null!==d.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/i)?l=function(e,t,r){if(null!=t)if(null!==e.match(/^Date$/i)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(`${r} must be an instanceof Date or a string in ISO8601 format.`);t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(null!==e.match(/^DateTime$/i)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(`${r} must be an instanceof Date or a string in ISO8601 format.`);t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(null!==e.match(/^DateTimeRfc1123$/i)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(`${r} must be an instanceof Date or a string in RFC-1123 format.`);t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(null!==e.match(/^UnixTime$/i)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(`${r} must be an instanceof Date or a string in RFC-1123/ISO8601 format for it to be serialized in UnixTime/Epoch format.`);t=function(e){if(!e)return;"string"==typeof e.valueOf()&&(e=new Date(e));return Math.floor(e.getTime()/1e3)}(t)}else if(null!==e.match(/^TimeSpan$/i)&&!function(e){return _r.test(e)}(t))throw new Error(`${r} must be a string in ISO 8601 format. Instead was "${t}".`);return t}(d,t,r):null!==d.match(/^ByteArray$/i)?l=function(e,t){if(null!=t){if(!(t instanceof Uint8Array))throw new Error(`${e} must be of type Uint8Array.`);t=yr(t)}return t}(r,t):null!==d.match(/^Base64Url$/i)?l=function(e,t){if(null!=t){if(!(t instanceof Uint8Array))throw new Error(`${e} must be of type Uint8Array.`);t=function(e){if(!e)return;if(!(e instanceof Uint8Array))throw new Error("Please provide an input of type Uint8Array for converting to Base64Url.");const t=yr(e);return function(e,t){let r=e.length;for(;r-1>=0&&e[r-1]===t;)--r;return e.substr(0,r)}(t,"=").replace(/\+/g,"-").replace(/\//g,"_")}(t)}return t}(r,t):null!==d.match(/^Sequence$/i)?l=function(e,t,r,i,n,o){var s;if(!Array.isArray(r))throw new Error(`${i} must be of type Array.`);let a=t.type.element;if(!a||"object"!=typeof a)throw new Error(`element" metadata for an Array must be defined in the mapper and it must of type "object" in ${i}.`);"Composite"===a.type.name&&a.type.className&&(a=null!==(s=e.modelMappers[a.type.className])&&void 0!==s?s:a);const l=[];for(let t=0;te!==n));a&&(s[n]=e.serialize(l,r[n],i+'["'+n+'"]',o))}}return s}return r}(this,e,t,r,Boolean(this.isXML),a));return l}deserialize(e,t,r,i={xml:{}}){var n,o,s,a;const l={xml:{rootName:null!==(n=i.xml.rootName)&&void 0!==n?n:"",includeRoot:null!==(o=i.xml.includeRoot)&&void 0!==o&&o,xmlCharKey:null!==(s=i.xml.xmlCharKey)&&void 0!==s?s:wr},ignoreUnknownProperties:null!==(a=i.ignoreUnknownProperties)&&void 0!==a&&a};if(null==t)return this.isXML&&"Sequence"===e.type.name&&!e.xmlIsWrapped&&(t=[]),void 0!==e.defaultValue&&(t=e.defaultValue),t;let d;const c=e.type.name;if(r||(r=e.serializedName),null!==c.match(/^Composite$/i))d=function(e,t,r,i,n){var o,s;const a=null!==(o=n.xml.xmlCharKey)&&void 0!==o?o:wr;Mr(e,t)&&(t=Fr(e,t,r,"serializedName"));const l=Cr(e,t,i);let d={};const c=[];for(const o of Object.keys(l)){const u=l[o],p=Tr(l[o].serializedName);c.push(p[0]);const{serializedName:h,xmlName:f,xmlElementName:m}=u;let g=i;""!==h&&void 0!==h&&(g=i+"."+h);const y=u.headerCollectionPrefix;if(y){const t={};for(const i of Object.keys(r))i.startsWith(y)&&(t[i.substring(y.length)]=e.deserialize(u.type.value,r[i],g,n)),c.push(i);d[o]=t}else if(e.isXML)if(u.xmlIsAttribute&&r[br])d[o]=e.deserialize(u,r[br][f],g,n);else if(u.xmlIsMsText)void 0!==r[a]?d[o]=r[a]:"string"==typeof r&&(d[o]=r);else{const t=m||f||h;if(u.xmlIsWrapped){const t=r[f],i=null!==(s=null==t?void 0:t[m])&&void 0!==s?s:[];d[o]=e.deserialize(u,i,g,n),c.push(f)}else{const i=r[t];d[o]=e.deserialize(u,i,g,n),c.push(t)}}else{let i,s=r,a=0;for(const e of p){if(!s)break;a++,s=s[e]}null===s&&a{for(const t in l){if(Tr(l[t].serializedName)[0]===e)return!1}return!0};for(const o in r)t(o)&&(d[o]=e.deserialize(u,r[o],i+'["'+o+'"]',n))}else if(r&&!n.ignoreUnknownProperties)for(const e of Object.keys(r))void 0!==d[e]||c.includes(e)||Ar(e,n)||(d[e]=r[e]);return d}(this,e,t,r,l);else{if(this.isXML){const e=l.xml.xmlCharKey;void 0!==t[br]&&void 0!==t[e]&&(t=t[e])}null!==c.match(/^Number$/i)?(d=parseFloat(t),isNaN(d)&&(d=t)):null!==c.match(/^Boolean$/i)?d="true"===t||"false"!==t&&t:null!==c.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/i)?d=t:null!==c.match(/^(Date|DateTime|DateTimeRfc1123)$/i)?d=new Date(t):null!==c.match(/^UnixTime$/i)?d=function(e){if(!e)return;return new Date(1e3*e)}(t):null!==c.match(/^ByteArray$/i)?d=vr(t):null!==c.match(/^Base64Url$/i)?d=function(e){if(!e)return;if(e&&"string"!=typeof e.valueOf())throw new Error("Please provide an input of type string for converting to Uint8Array");return vr(e=e.replace(/-/g,"+").replace(/_/g,"/"))}(t):null!==c.match(/^Sequence$/i)?d=function(e,t,r,i,n){var o;let s=t.type.element;if(!s||"object"!=typeof s)throw new Error(`element" metadata for an Array must be defined in the mapper and it must of type "object" in ${i}`);if(r){Array.isArray(r)||(r=[r]),"Composite"===s.type.name&&s.type.className&&(s=null!==(o=e.modelMappers[s.type.className])&&void 0!==o?o:s);const t=[];for(let o=0;o0)if(n.isConstant)o=n.defaultValue;else{let t=qr(e,i);!t.propertyFound&&r&&(t=qr(r,i));let s=!1;t.propertyFound||(s=n.required||"options"===i[0]&&2===i.length),o=s?n.defaultValue:t.propertyValue}}else{n.required&&(o={});for(const t in i){const s=n.type.modelProperties[t],a=Nr(e,{parameterPath:i[t],mapper:s},r);void 0!==a&&(o||(o={}),o[t]=a)}}return o}function qr(e,t){const r={propertyFound:!1};let i=0;for(;ie.toLowerCase())):[];try{if(0===a.length||a.some((t=>-1!==e.indexOf(t))))return r.parsedBody=JSON.parse(o),r;if(a.some((e=>-1!==t.indexOf(e)))){if(!n)throw new Error("Parsing XML not supported.");const e=await n(o,i.xml);return r.parsedBody=e,r}}catch(e){const t=`Error "${e}" occurred while parsing the response body - ${r.bodyAsText}.`,i=e.code||Yt.PARSE_ERROR;throw new Yt(t,{code:i,statusCode:r.status,request:r.request,response:r})}}return r}(e,t,r,i,n);if(!function(e){const t=e.request,r=Lr(t),i=null==r?void 0:r.shouldDeserialize;let n;n=void 0===i||("boolean"==typeof i?i:i(e));return n}(o))return o;const s=Lr(o.request),a=null==s?void 0:s.operationSpec;if(!a||!a.responses)return o;const l=function(e){let t;const r=e.request,i=Lr(r),n=null==i?void 0:i.operationSpec;n&&(t=(null==i?void 0:i.operationResponseGetter)?null==i?void 0:i.operationResponseGetter(n,e):n.responses[e.status]);return t}(o),{error:d,shouldReturnResponse:c}=function(e,t,r,i){var n;const o=200<=e.status&&e.status<300,s=function(e){const t=Object.keys(e.responses);return 0===t.length||1===t.length&&"default"===t[0]}(t)?o:!!r;if(s){if(!r)return{error:null,shouldReturnResponse:!1};if(!r.isError)return{error:null,shouldReturnResponse:!1}}const a=null!=r?r:t.responses.default,l=(null===(n=e.request.streamResponseStatusCodes)||void 0===n?void 0:n.has(e.status))?`Unexpected status code: ${e.status}`:e.bodyAsText,d=new Yt(l,{statusCode:e.status,request:e.request,response:e});if(!a)throw d;const c=a.bodyMapper,u=a.headersMapper;try{if(e.parsedBody){const r=e.parsedBody;let n;if(c){let e=r;if(t.isXML&&c.type.name===Rr){e=[];const t=c.xmlElementName;"object"==typeof r&&t&&(e=r[t])}n=t.serializer.deserialize(c,e,"error.response.parsedBody",i)}const o=r.error||n||r;d.code=o.code,o.message&&(d.message=o.message),c&&(d.response.parsedBody=n)}e.headers&&u&&(d.response.parsedHeaders=t.serializer.deserialize(u,e.headers.toJSON(),"operationRes.parsedHeaders"))}catch(t){d.message=`Error "${t.message}" occurred in deserializing the responseBody - "${e.bodyAsText}" for the default response.`}return{error:d,shouldReturnResponse:!1}}(o,a,l,i);if(d)throw d;if(c)return o;if(l){if(l.bodyMapper){let e=o.parsedBody;a.isXML&&l.bodyMapper.type.name===Rr&&(e="object"==typeof e?e[l.bodyMapper.xmlElementName]:[]);try{o.parsedBody=a.serializer.deserialize(l.bodyMapper,e,"operationRes.parsedBody",i)}catch(e){throw new Yt(`Error ${e} occurred in deserializing the responseBody - ${o.bodyAsText}`,{statusCode:o.status,request:o.request,response:o})}}else"HEAD"===a.httpMethod&&(o.parsedBody=r.status>=200&&r.status<300);l.headersMapper&&(o.parsedHeaders=a.serializer.deserialize(l.headersMapper,o.headers.toJSON(),"operationRes.parsedHeaders",{xml:{},ignoreUnknownProperties:!0}))}return o}(l,d,r,p,c)}}}function Gr(e){const{parameterPath:t,mapper:r}=e;let i;return i="string"==typeof t?t:Array.isArray(t)?t.join("."):r.serializedName,i}function Wr(e={}){const t=e.stringifyXML;return{name:"serializationPolicy",async sendRequest(e,r){const i=Lr(e),n=null==i?void 0:i.operationSpec,o=null==i?void 0:i.operationArguments;return n&&o&&(function(e,t,r){var i,n;if(r.headerParameters)for(const i of r.headerParameters){let n=Nr(t,i);if(null!=n||i.mapper.required){n=r.serializer.serialize(i.mapper,n,Gr(i));const t=i.mapper.headerCollectionPrefix;if(t)for(const r of Object.keys(n))e.headers.set(t+r,n[r]);else e.headers.set(i.mapper.serializedName||Gr(i),n)}}const o=null===(n=null===(i=t.options)||void 0===i?void 0:i.requestOptions)||void 0===n?void 0:n.customHeaders;if(o)for(const t of Object.keys(o))e.headers.set(t,o[t])}(e,o,n),function(e,t,r,i=function(){throw new Error("XML serialization unsupported!")}){var n,o,s,a,l;const d=null===(n=t.options)||void 0===n?void 0:n.serializerOptions,c={xml:{rootName:null!==(o=null==d?void 0:d.xml.rootName)&&void 0!==o?o:"",includeRoot:null!==(s=null==d?void 0:d.xml.includeRoot)&&void 0!==s&&s,xmlCharKey:null!==(a=null==d?void 0:d.xml.xmlCharKey)&&void 0!==a?a:wr}},u=c.xml.xmlCharKey;if(r.requestBody&&r.requestBody.mapper){e.body=Nr(t,r.requestBody);const n=r.requestBody.mapper,{required:o,serializedName:s,xmlName:a,xmlElementName:d,xmlNamespace:p,xmlNamespacePrefix:h,nullable:f}=n,m=n.type.name;try{if(void 0!==e.body&&null!==e.body||f&&null===e.body||o){const t=Gr(r.requestBody);e.body=r.serializer.serialize(n,e.body,t,c);const o=m===Or;if(r.isXML){const t=h?`xmlns:${h}`:"xmlns",r=function(e,t,r,i,n){if(e&&!["Composite","Sequence","Dictionary"].includes(r)){const r={};return r[n.xml.xmlCharKey]=i,r[br]={[t]:e},r}return i}(p,t,m,e.body,c);m===Rr?e.body=i(function(e,t,r,i){Array.isArray(e)||(e=[e]);if(!r||!i)return{[t]:e};const n={[t]:e};return n[br]={[r]:i},n}(r,d||a||s,t,p),{rootName:a||s,xmlCharKey:u}):o||(e.body=i(r,{rootName:a||s,xmlCharKey:u}))}else{if(m===Pr&&((null===(l=r.contentType)||void 0===l?void 0:l.match("text/plain"))||"text"===r.mediaType))return;o||(e.body=JSON.stringify(e.body))}}}catch(e){throw new Error(`Error "${e.message}" occurred in serializing the payload - ${JSON.stringify(s,void 0," ")}.`)}}else if(r.formDataParameters&&r.formDataParameters.length>0){e.formData={};for(const i of r.formDataParameters){const n=Nr(t,i);if(null!=n){const t=i.mapper.serializedName||Gr(i);e.formData[t]=r.serializer.serialize(i.mapper,n,Gr(i),c)}}}}(e,o,n,t)),r(e)}}}function Kr(e={}){const t=Xt(null!=e?e:{});return e.credentialOptions&&t.addPolicy(lr({credential:e.credentialOptions.credential,scopes:e.credentialOptions.credentialScopes})),t.addPolicy(Wr(e.serializationOptions),{phase:"Serialize"}),t.addPolicy($r(e.deserializationOptions),{phase:"Deserialize"}),t}let Vr;const Jr={CSV:",",SSV:" ",Multi:"Multi",TSV:"\t",Pipes:"|"};function Yr(e,t,r,i){const n=function(e,t,r){var i;const n=new Map;if(null===(i=e.urlParameters)||void 0===i?void 0:i.length)for(const i of e.urlParameters){let o=Nr(t,i,r);const s=Gr(i);o=e.serializer.serialize(i.mapper,o,s),i.skipEncoding||(o=encodeURIComponent(o)),n.set(`{${i.mapper.serializedName||s}}`,o)}return n}(t,r,i);let o=!1,s=Qr(e,n);if(t.path){let e=Qr(t.path,n);"/{nextLink}"===t.path&&e.startsWith("/")&&(e=e.substring(1)),!function(e){return e.includes("://")}(e)?s=function(e,t){if(!t)return e;const r=new URL(e);let i=r.pathname;i.endsWith("/")||(i=`${i}/`);t.startsWith("/")&&(t=t.substring(1));const n=t.indexOf("?");if(-1!==n){const e=t.substring(0,n),o=t.substring(n+1);i+=e,o&&(r.search=r.search?`${r.search}&${o}`:o)}else i+=t;return r.pathname=i,r.toString()}(s,e):(s=e,o=!0)}const{queryParams:a,sequenceParams:l}=function(e,t,r){var i;const n=new Map,o=new Set;if(null===(i=e.queryParameters)||void 0===i?void 0:i.length)for(const i of e.queryParameters){"Sequence"===i.mapper.type.name&&i.mapper.serializedName&&o.add(i.mapper.serializedName);let s=Nr(t,i,r);if(null!=s||i.mapper.required){s=e.serializer.serialize(i.mapper,s,Gr(i));const t=i.collectionFormat?Jr[i.collectionFormat]:"";if(Array.isArray(s)&&(s=s.map((e=>null==e?"":e))),"Multi"===i.collectionFormat&&0===s.length)continue;!Array.isArray(s)||"SSV"!==i.collectionFormat&&"TSV"!==i.collectionFormat||(s=s.join(t)),i.skipEncoding||(s=Array.isArray(s)?s.map((e=>encodeURIComponent(e))):encodeURIComponent(s)),!Array.isArray(s)||"CSV"!==i.collectionFormat&&"Pipes"!==i.collectionFormat||(s=s.join(t)),n.set(i.mapper.serializedName||Gr(i),s)}}return{queryParams:n,sequenceParams:o}}(t,r,i);return s=function(e,t,r,i=!1){if(0===t.size)return e;const n=new URL(e),o=function(e){const t=new Map;if(!e||"?"!==e[0])return t;const r=(e=e.slice(1)).split("&");for(const e of r){const[r,i]=e.split("=",2),n=t.get(r);n?Array.isArray(n)?n.push(i):t.set(r,[n,i]):t.set(r,i)}return t}(n.search);for(const[e,n]of t){const t=o.get(e);if(Array.isArray(t))if(Array.isArray(n)){t.push(...n);const r=new Set(t);o.set(e,Array.from(r))}else t.push(n);else t?(Array.isArray(n)?n.unshift(t):r.has(e)&&o.set(e,[t,n]),i||o.set(e,n)):o.set(e,n)}const s=[];for(const[e,t]of o)if("string"==typeof t)s.push(`${e}=${t}`);else if(Array.isArray(t))for(const r of t)s.push(`${e}=${r}`);else s.push(`${e}=${t}`);return n.search=s.length?`?${s.join("&")}`:"",n.toString()}(s,a,l,o),s}function Qr(e,t){let r=e;for(const[e,i]of t)r=r.split(e).join(i);return r}const Zr=ze("core-client");class Xr{constructor(e={}){var t,r;if(this._requestContentType=e.requestContentType,this._endpoint=null!==(t=e.endpoint)&&void 0!==t?t:e.baseUri,e.baseUri&&Zr.warning("The baseUri option for SDK Clients has been deprecated, please use endpoint instead."),this._allowInsecureConnection=e.allowInsecureConnection,this._httpClient=e.httpClient||(Vr||(Vr=rr()),Vr),this.pipeline=e.pipeline||function(e){const t=function(e){if(e.credentialScopes)return e.credentialScopes;if(e.endpoint)return`${e.endpoint}/.default`;if(e.baseUri)return`${e.baseUri}/.default`;if(e.credential&&!e.credentialScopes)throw new Error("When using credentials, the ServiceClientOptions must contain either a endpoint or a credentialScopes. Unable to create a bearerTokenAuthenticationPolicy");return}(e),r=e.credential&&t?{credentialScopes:t,credential:e.credential}:void 0;return Kr(Object.assign(Object.assign({},e),{credentialOptions:r}))}(e),null===(r=e.additionalPolicies)||void 0===r?void 0:r.length)for(const{policy:t,position:r}of e.additionalPolicies){const e="perRetry"===r?"Sign":void 0;this.pipeline.addPolicy(t,{afterPhase:e})}}async sendRequest(e){return this.pipeline.sendRequest(this._httpClient,e)}async sendOperationRequest(e,t){const r=t.baseUrl||this._endpoint;if(!r)throw new Error("If operationSpec.baseUrl is not specified, then the ServiceClient must have a endpoint string property that contains the base URL to use.");const i=nr({url:Yr(r,t,e,this)});i.method=t.httpMethod;const n=Lr(i);n.operationSpec=t,n.operationArguments=e;const o=t.contentType||this._requestContentType;o&&t.requestBody&&i.headers.set("Content-Type",o);const s=e.options;if(s){const e=s.requestOptions;e&&(e.timeout&&(i.timeout=e.timeout),e.onUploadProgress&&(i.onUploadProgress=e.onUploadProgress),e.onDownloadProgress&&(i.onDownloadProgress=e.onDownloadProgress),void 0!==e.shouldDeserialize&&(n.shouldDeserialize=e.shouldDeserialize),e.allowInsecureConnection&&(i.allowInsecureConnection=!0)),s.abortSignal&&(i.abortSignal=s.abortSignal),s.tracingOptions&&(i.tracingOptions=s.tracingOptions)}this._allowInsecureConnection&&(i.allowInsecureConnection=!0),void 0===i.streamResponseStatusCodes&&(i.streamResponseStatusCodes=function(e){const t=new Set;for(const r in e.responses){const i=e.responses[r];i.bodyMapper&&i.bodyMapper.type.name===Or&&t.add(Number(r))}return t}(t));try{const e=await this.sendRequest(i),r=Sr(e,t.responses[e.status]);return(null==s?void 0:s.onResponse)&&s.onResponse(e,r),r}catch(e){if("object"==typeof e&&(null==e?void 0:e.response)){const r=e.response,i=Sr(r,t.responses[e.statusCode]||t.responses.default);e.details=i,(null==s?void 0:s.onResponse)&&s.onResponse(r,i,e)}throw e}}}const ei="/.default",ti={AUTHORIZATION:"authorization"};const ri=async e=>{const t={abortSignal:(r=e.request).abortSignal,requestOptions:{timeout:r.timeout},tracingOptions:r.tracingOptions};var r;const i=function(e){const t=e.headers.get("WWW-Authenticate");if(401===e.status&&t)return t;return}(e.response);if(i){const r=function(e){const t=e.slice(7),r=`${t.trim()} `.split(" ").filter((e=>e));return r.map((e=>(([e,t])=>({[e]:t}))(e.trim().split("=")))).reduce(((e,t)=>Object.assign(Object.assign({},e),t)),{})}(i),n=function(e,t){if(!t.resource_id)return e.scopes;const r=new URL(t.resource_id);r.pathname=ei;let i=r.toString();"https://disk.azure.com/.default"===i&&(i="https://disk.azure.com//.default");return[i]}(e,r),o=function(e){const t=new URL(e.authorization_uri),r=t.pathname.split("/")[1];if(r&&(i=r,/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/.test(i)))return r;var i;return}(r);if(!o)return!1;const s=await e.getAccessToken(n,Object.assign(Object.assign({},t),{tenantId:o}));return!!s&&(e.request.headers.set(ti.AUTHORIZATION,`Bearer ${s.token}`),!0)}return!1};const ii=Symbol("Original PipelineRequest"),ni=Symbol.for("@azure/core-client original request");function oi(e,t={}){const r=e[ii],i=Nt(e.headers.toJson({preserveCase:!0}));if(r)return r.headers=i,r;{const r=nr({url:e.url,method:e.method,headers:i,withCredentials:e.withCredentials,timeout:e.timeout,requestId:e.requestId,abortSignal:e.abortSignal,body:e.body,formData:e.formData,disableKeepAlive:!!e.keepAlive,onDownloadProgress:e.onDownloadProgress,onUploadProgress:e.onUploadProgress,proxySettings:e.proxySettings,streamResponseStatusCodes:e.streamResponseStatusCodes});return t.originalRequest&&(r[ni]=t.originalRequest),r}}function si(e,t){var r;const i=null!==(r=null==t?void 0:t.originalRequest)&&void 0!==r?r:e,n={url:e.url,method:e.method,headers:ai(e.headers),withCredentials:e.withCredentials,timeout:e.timeout,requestId:e.headers.get("x-ms-client-request-id")||e.requestId,abortSignal:e.abortSignal,body:e.body,formData:e.formData,keepAlive:!!e.disableKeepAlive,onDownloadProgress:e.onDownloadProgress,onUploadProgress:e.onUploadProgress,proxySettings:e.proxySettings,streamResponseStatusCodes:e.streamResponseStatusCodes,clone(){throw new Error("Cannot clone a non-proxied WebResourceLike")},prepare(){throw new Error("WebResourceLike.prepare() is not supported by @azure/core-http-compat")},validateRequestProperties(){}};return(null==t?void 0:t.createProxy)?new Proxy(n,{get:(t,r,o)=>r===ii?e:"clone"===r?()=>si(oi(n,{originalRequest:i}),{createProxy:!0,originalRequest:i}):Reflect.get(t,r,o),set(t,r,i,n){"keepAlive"===r&&(e.disableKeepAlive=!i);return"string"==typeof r&&["url","method","withCredentials","timeout","requestId","abortSignal","body","formData","onDownloadProgress","onUploadProgress","proxySettings","streamResponseStatusCodes"].includes(r)&&(e[r]=i),Reflect.set(t,r,i,n)}}):n}function ai(e){return new di(e.toJSON({preserveCase:!0}))}function li(e){return e.toLowerCase()}class di{constructor(e){if(this._headersMap={},e)for(const t in e)this.set(t,e[t])}set(e,t){this._headersMap[li(e)]={name:e,value:t.toString()}}get(e){const t=this._headersMap[li(e)];return t?t.value:void 0}contains(e){return!!this._headersMap[li(e)]}remove(e){const t=this.contains(e);return delete this._headersMap[li(e)],t}rawHeaders(){return this.toJson({preserveCase:!0})}headersArray(){const e=[];for(const t in this._headersMap)e.push(this._headersMap[t]);return e}headerNames(){const e=[],t=this.headersArray();for(let r=0;r"headers"===n?i:"request"===n?r:n===ci?e:Reflect.get(t,n,o),set:(e,t,n,o)=>("headers"===t?i=n:"request"===t&&(r=n),Reflect.set(e,t,n,o))}):Object.assign(Object.assign({},e),{request:r,headers:i})}function pi(e){const t=e[ci],r=Nt(e.headers.toJson({preserveCase:!0}));return t?(t.headers=r,t):Object.assign(Object.assign({},e),{headers:r,request:oi(e.request)})}class hi extends Xr{constructor(e){var t,r;super(e),!1!==(null===(t=e.keepAliveOptions)||void 0===t?void 0:t.enable)||this.pipeline.getOrderedPolicies().some((e=>e.name===gr))||this.pipeline.addPolicy({name:gr,sendRequest:async(e,t)=>(e.disableKeepAlive=!0,t(e))}),!1===(null===(r=e.redirectOptions)||void 0===r?void 0:r.handleRedirects)&&this.pipeline.removePolicy({name:ct})}async sendOperationRequest(e,t){var r;const i=null===(r=null==e?void 0:e.options)||void 0===r?void 0:r.onResponse;let n;e.options=Object.assign(Object.assign({},e.options),{onResponse:function(e,t,r){n=e,i&&i(e,t,r)}});const o=await super.sendOperationRequest(e,t);return n&&Object.defineProperty(o,"_response",{value:ui(n)}),o}}var fi;!function(e){e[e.ERROR=1]="ERROR",e[e.INFO=3]="INFO",e[e.OFF=0]="OFF",e[e.WARNING=2]="WARNING"}(fi||(fi={}));const mi={log(e,t){},shouldLog:e=>!1};function gi(e){const t=e.slice().reverse();return{name:"RequestPolicyFactoryPolicy",async sendRequest(e,r){let i={sendRequest:async e=>ui(await r(oi(e)),{createProxy:!0})};for(const e of t)i=e.create(i,mi);const n=si(e,{createProxy:!0});return pi(await i.sendRequest(n))}}}const yi="$";if(!(document&&DOMParser&&Node&&XMLSerializer))throw new Error('This library depends on the following DOM objects: ["document", "DOMParser", "Node", "XMLSerializer"] to parse XML, but some of these are undefined. You may provide a polyfill to make these globally available in order to support your environment. For more information, please refer to https://aka.ms/azsdk/js/web-workers. ');let vi;try{void 0!==self.trustedTypes&&(vi=self.trustedTypes.createPolicy("@azure/core-xml#xml.browser",{createHTML:e=>e}))}catch(aI){console.warn('Could not create trusted types policy "@azure/core-xml#xml.browser"')}const bi=document.implementation.createDocument(null,null,null),wi=new DOMParser;function _i(e,t={}){var r,i,n,o,s,a;try{const l={rootName:null!==(r=t.rootName)&&void 0!==r?r:"",includeRoot:null!==(i=t.includeRoot)&&void 0!==i&&i,xmlCharKey:null!==(n=t.xmlCharKey)&&void 0!==n?n:"_",cdataPropName:null!==(o=t.cdataPropName)&&void 0!==o?o:"__cdata",stopNodes:null!==(s=t.stopNodes)&&void 0!==s?s:[]},d=wi.parseFromString(null!==(a=null==vi?void 0:vi.createHTML(e))&&void 0!==a?a:e,"application/xml");let c;return function(e){const t=e.getElementsByTagName("parsererror");if(t.length>0&&function(){var e,t;if(void 0===xi)try{const r=null!==(e=null==vi?void 0:vi.createHTML("INVALID"))&&void 0!==e?e:"INVALID";xi=null!==(t=wi.parseFromString(r,"text/xml").getElementsByTagName("parsererror")[0].namespaceURI)&&void 0!==t?t:""}catch(e){xi=""}return xi}())for(let e=0;e'+ki.serializeToString(l).replace(/ xmlns=""/g,"")}function Ti(e){const t=[];for(const r of Object.keys(e)){const i=bi.createAttribute(r);i.value=e[r].toString(),t.push(i)}return t}function Bi(e,t,r){var i;if(null==e||"string"==typeof e||"number"==typeof e||"boolean"==typeof e){const r=bi.createElement(t);return r.textContent=null==e?"":e.toString(),[r]}if(Array.isArray(e)){const i=[];for(const n of e)for(const e of Bi(n,t,r))i.push(e);return i}if("object"==typeof e){let n;n=(null===(i=e[yi])||void 0===i?void 0:i.xmlns)?bi.createElementNS(e[yi].xmlns,t):bi.createElement(t);for(const t of Object.keys(e))if(t===yi)for(const r of Ti(e[t]))n.attributes.setNamedItem(r);else if(t===r.xmlCharKey)n.textContent=e[t].toString();else if(t===r.cdataPropName){const r=bi.createCDATASection(e[t].toString());n.appendChild(r)}else for(const i of Bi(e[t],t,r))n.appendChild(i);return[n]}throw new Error(`Illegal value passed to buildObject: ${e}`)}const Ci=ze("storage-blob"),Ii="12.25.0",Ai="2024-11-04",Fi=268435456,Mi=4194304e3,Di=5e4,Ri=4194304,Pi="https://storage.azure.com/.default",Oi={FORCE_BROWSER_NO_CACHE:"_",SIGNATURE:"sig",SNAPSHOT:"snapshot",VERSIONID:"versionid",TIMEOUT:"timeout"},zi=202,Ni="Content-ID",qi="Content-Length",Ui="Content-Transfer-Encoding",Li="Content-Type",ji="Cookie",Hi="x-ms-error-code",$i="x-ms-version",Gi="",Wi="\r\n",Ki="HTTP/1.1",Vi=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-copy-source-error-code","x-ms-copy-source-status-code","x-ms-if-tags","x-ms-source-if-tags"],Ji=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"],Yi=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];var Qi,Zi=__webpack_require__(48287).Buffer;function Xi(e){const t=new URL(e);let r=t.pathname;return r=r||"/",r=encodeURIComponent(r).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%"),t.pathname=r,t.toString()}function en(e,t){const r=e.split(";");for(const e of r)if(e.trim().startsWith(t))return e.trim().match(t+"=(.*)")[1];return""}function tn(e){let t="";e.startsWith("UseDevelopmentStorage=true")&&(t=function(e){let t="";if(-1!==e.search("DevelopmentStorageProxyUri=")){const r=e.split(";");for(const e of r)e.trim().startsWith("DevelopmentStorageProxyUri=")&&(t=e.trim().match("DevelopmentStorageProxyUri=(.*)")[1])}return t}(e),e="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;");let r=en(e,"BlobEndpoint");if(r=r.endsWith("/")?r.slice(0,-1):r,-1!==e.search("DefaultEndpointsProtocol=")&&-1!==e.search("AccountKey=")){let i="",n="",o=Zi.from("accountKey","base64"),s="";if(n=en(e,"AccountName"),o=Zi.from(en(e,"AccountKey"),"base64"),!r){i=en(e,"DefaultEndpointsProtocol");const t=i.toLowerCase();if("https"!==t&&"http"!==t)throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'");if(s=en(e,"EndpointSuffix"),!s)throw new Error("Invalid EndpointSuffix in the provided Connection String");r=`${i}://${n}.blob.${s}`}if(!n)throw new Error("Invalid AccountName in the provided Connection String");if(0===o.length)throw new Error("Invalid AccountKey in the provided Connection String");return{kind:"AccountConnString",url:r,accountName:n,accountKey:o,proxyUri:t}}{let t=en(e,"SharedAccessSignature"),i=en(e,"AccountName");if(i||(i=fn(r)),!r)throw new Error("Invalid BlobEndpoint in the provided SAS Connection String");if(!t)throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String");return t.startsWith("?")&&(t=t.substring(1)),{kind:"SASConnString",url:r,accountName:i,accountSas:t}}}function rn(e,t){const r=new URL(e);let i=r.pathname;return i=i?i.endsWith("/")?`${i}${t}`:`${i}/${t}`:t,r.pathname=i,r.toString()}function nn(e,t,r){const i=new URL(e),n=encodeURIComponent(t),o=r?encodeURIComponent(r):void 0,s=""===i.search?"?":i.search,a=[];for(const e of s.slice(1).split("&"))if(e){const[t]=e.split("=",2);t!==n&&a.push(e)}return o&&a.push(`${n}=${o}`),i.search=a.length?`?${a.join("&")}`:"",i.toString()}function on(e,t){var r;return null!==(r=new URL(e).searchParams.get(t))&&void 0!==r?r:void 0}function sn(e,t){const r=new URL(e);return r.hostname=t,r.toString()}function an(e){try{return new URL(e).pathname}catch(e){return}}function ln(e){const t=new URL(e),r=t.pathname;if(!r)throw new RangeError("Invalid url without valid path.");let i=t.search||"";return i=i.trim(),""!==i&&(i=i.startsWith("?")?i:`?${i}`),`${r}${i}`}function dn(e,t){const r=new URL(e);let i=r.search;return i?i+="&"+t:i=t,r.search=i,r.toString()}function cn(e,t=!0){const r=e.toISOString();return t?r.substring(0,r.length-1)+"0000Z":r.substring(0,r.length-5)+"Z"}function un(e,t){e.length>42&&(e=e.slice(0,42));const r=e+function(e,t,r=" "){if(String.prototype.padStart)return e.padStart(t,r);return r=r||" ",e.length>t?e:((t-=e.length)>r.length&&(r+=r.repeat(t/r.length)),r.slice(0,t)+e)}(t.toString(),48-e.length,"0");return i=r,ot?Zi.from(i).toString("base64"):btoa(i);var i}async function pn(e,t,r){return new Promise(((i,n)=>{let o;const s=()=>{void 0!==o&&clearTimeout(o),n(r)};o=setTimeout((()=>{void 0!==t&&t.removeEventListener("abort",s),i()}),e),void 0!==t&&t.addEventListener("abort",s)}))}function hn(e,t){return e.toLocaleLowerCase()===t.toLocaleLowerCase()}function fn(e){const t=new URL(e);let r;try{return r="blob"===t.hostname.split(".")[1]?t.hostname.split(".")[0]:mn(t)?t.pathname.split("/")[1]:"",r}catch(e){throw new Error("Unable to extract accountName with provided information.")}}function mn(e){const t=e.host;return/^.*:.*:.*$|^(localhost|host.docker.internal)(:[0-9]+)?$|^(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])(\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])){3}(:[0-9]+)?$/.test(t)||Boolean(e.port)&&Yi.includes(e.port)}function gn(e){if(void 0===e)return;const t=[];for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)){const i=e[r];t.push(`${encodeURIComponent(r)}=${encodeURIComponent(i)}`)}return t.join("&")}function yn(e){if(void 0===e)return;const t={blobTagSet:[]};for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)){const i=e[r];t.blobTagSet.push({key:r,value:i})}return t}function vn(e){if(void 0===e)return;const t={};for(const r of e.blobTagSet)t[r.key]=r.value;return t}function bn(e){if(void 0!==e)switch(e.kind){case"csv":return{format:{type:"delimited",delimitedTextConfiguration:{columnSeparator:e.columnSeparator||",",fieldQuote:e.fieldQuote||"",recordSeparator:e.recordSeparator,escapeChar:e.escapeCharacter||"",headersPresent:e.hasHeaders||!1}}};case"json":return{format:{type:"json",jsonTextConfiguration:{recordSeparator:e.recordSeparator}}};case"arrow":return{format:{type:"arrow",arrowConfiguration:{schema:e.schema}}};case"parquet":return{format:{type:"parquet"}};default:throw Error("Invalid BlobQueryTextConfiguration.")}}function wn(e){if(!e)return;if("policy-id"in e)return;const t=[];for(const r in e){const i=r.split("_"),n="or-";i[0].startsWith(n)&&(i[0]=i[0].substring(n.length));const o={ruleId:i[1],replicationStatus:e[r]},s=t.findIndex((e=>e.policyId===i[0]));s>-1?t[s].rules.push(o):t.push({policyId:i[0],rules:[o]})}return t}function _n(e){return e?e.scheme+" "+e.value:void 0}function xn(e){return e.encoded?decodeURIComponent(e.content):e.content}function Sn(e){var t;return Object.assign(Object.assign({},e),{segment:{blobPrefixes:null===(t=e.segment.blobPrefixes)||void 0===t?void 0:t.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name)}))),blobItems:e.segment.blobItems.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name)})))}})}function*kn(e){let t=[],r=[];e.pageRange&&(t=e.pageRange),e.clearRange&&(r=e.clearRange);let i=0,n=0;for(;i=1?Math.floor(r.maxTries):Bn.maxTries,tryTimeoutInMs:r.tryTimeoutInMs&&r.tryTimeoutInMs>=0?r.tryTimeoutInMs:Bn.tryTimeoutInMs,retryDelayInMs:r.retryDelayInMs&&r.retryDelayInMs>=0?Math.min(r.retryDelayInMs,r.maxRetryDelayInMs?r.maxRetryDelayInMs:Bn.maxRetryDelayInMs):Bn.retryDelayInMs,maxRetryDelayInMs:r.maxRetryDelayInMs&&r.maxRetryDelayInMs>=0?r.maxRetryDelayInMs:Bn.maxRetryDelayInMs,secondaryHost:r.secondaryHost?r.secondaryHost:Bn.secondaryHost}}async sendRequest(e){return this.attemptSendRequest(e,!1,1)}async attemptSendRequest(e,t,r){const i=e.clone(),n=t||!this.retryOptions.secondaryHost||!("GET"===e.method||"HEAD"===e.method||"OPTIONS"===e.method)||r%2==1;let o;n||(i.url=sn(i.url,this.retryOptions.secondaryHost)),this.retryOptions.tryTimeoutInMs&&(i.url=nn(i.url,Oi.TIMEOUT,Math.floor(this.retryOptions.tryTimeoutInMs/1e3).toString()));try{if(Ci.info(`RetryPolicy: =====> Try=${r} ${n?"Primary":"Secondary"}`),o=await this._nextPolicy.sendRequest(i),!this.shouldRetry(n,r,o))return o;t=t||!n&&404===o.status}catch(e){if(Ci.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`),!this.shouldRetry(n,r,o,e))throw e}return await this.delay(n,r,e.abortSignal),this.attemptSendRequest(e,t,++r)}shouldRetry(e,t,r,i){if(t>=this.retryOptions.maxTries)return Ci.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${this.retryOptions.maxTries}, no further try.`),!1;const n=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"];if(i)for(const e of n)if(i.name.toUpperCase().includes(e)||i.message.toUpperCase().includes(e)||i.code&&i.code.toString().toUpperCase()===e)return Ci.info(`RetryPolicy: Network error ${e} found, will retry.`),!0;if(r||i){const t=r?r.status:i?i.statusCode:0;if(!e&&404===t)return Ci.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(503===t||500===t)return Ci.info(`RetryPolicy: Will retry for status code ${t}.`),!0}return!("PARSE_ERROR"!==(null==i?void 0:i.code)||!(null==i?void 0:i.message.startsWith('Error "Error: Unclosed root tag')))&&(Ci.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0)}async delay(e,t,r){let i=0;if(e)switch(this.retryOptions.retryPolicyType){case Qi.EXPONENTIAL:i=Math.min((Math.pow(2,t-1)-1)*this.retryOptions.retryDelayInMs,this.retryOptions.maxRetryDelayInMs);break;case Qi.FIXED:i=this.retryOptions.retryDelayInMs}else i=1e3*Math.random();return Ci.info(`RetryPolicy: Delay for ${i}ms`),pn(i,r,Cn)}}class An{constructor(e){this.retryOptions=e}create(e,t){return new In(e,t,this.retryOptions)}}let Fn;var Mn;!function(e){e[e.EXPONENTIAL=0]="EXPONENTIAL",e[e.FIXED=1]="FIXED"}(Mn||(Mn={}));const Dn={maxRetryDelayInMs:12e4,maxTries:4,retryDelayInMs:4e3,retryPolicyType:Mn.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},Rn=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"],Pn=new He("The operation was aborted.");class On extends cr{constructor(e,t){super(e,t)}async sendRequest(e){return ot||("GET"!==e.method.toUpperCase()&&"HEAD"!==e.method.toUpperCase()||(e.url=nn(e.url,Oi.FORCE_BROWSER_NO_CACHE,(new Date).getTime().toString())),e.headers.remove(ji),e.headers.remove(qi)),this._nextPolicy.sendRequest(e)}}class zn{create(e,t){return new On(e,t)}}function Nn(e){if(!e||"object"!=typeof e)return!1;const t=e;return Array.isArray(t.factories)&&"object"==typeof t.options&&"function"==typeof t.toServiceClientOptions}class qn{constructor(e,t={}){this.factories=e,this.options=t}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}}function Un(e,t={}){e||(e=new fr);const r=new qn([],t);return r._credential=e,r}function Ln(e){var r;const i=e.options,{httpClient:n}=i,o=t(i,["httpClient"]);let s=e._coreHttpClient;var a;s||(s=n?(a=n,{sendRequest:async e=>pi(await a.sendRequest(si(e,{createProxy:!0})))}):(Fn||(Fn=rr()),Fn),e._coreHttpClient=s);let l=e._corePipeline;if(!l){const t=`azsdk-js-azure-storage-blob/${Ii}`,i=o.userAgentOptions&&o.userAgentOptions.userAgentPrefix?`${o.userAgentOptions.userAgentPrefix} ${t}`:`${t}`;l=Kr(Object.assign(Object.assign({},o),{loggingOptions:{additionalAllowedHeaderNames:Vi,additionalAllowedQueryParameters:Ji,logger:Ci.info},userAgentOptions:{userAgentPrefix:i},serializationOptions:{stringifyXML:Ei,serializerOptions:{xml:{xmlCharKey:"#"}}},deserializationOptions:{parseXML:_i,serializerOptions:{xml:{xmlCharKey:"#"}}}})),l.removePolicy({phase:"Retry"}),l.removePolicy({name:"decompressResponsePolicy"}),l.addPolicy({name:"StorageCorrectContentLengthPolicy",sendRequest:async(e,t)=>t(e)}),l.addPolicy(function(e={}){var t,r,i,n,o,s;const a=null!==(t=e.retryPolicyType)&&void 0!==t?t:Dn.retryPolicyType,l=null!==(r=e.maxTries)&&void 0!==r?r:Dn.maxTries,d=null!==(i=e.retryDelayInMs)&&void 0!==i?i:Dn.retryDelayInMs,c=null!==(n=e.maxRetryDelayInMs)&&void 0!==n?n:Dn.maxRetryDelayInMs,u=null!==(o=e.secondaryHost)&&void 0!==o?o:Dn.secondaryHost,p=null!==(s=e.tryTimeoutInMs)&&void 0!==s?s:Dn.tryTimeoutInMs;function h({isPrimaryRetry:e,attempt:t,response:r,error:i}){var n,o;if(t>=l)return Ci.info(`RetryPolicy: Attempt(s) ${t} >= maxTries ${l}, no further try.`),!1;if(i){for(const e of Rn)if(i.name.toUpperCase().includes(e)||i.message.toUpperCase().includes(e)||i.code&&i.code.toString().toUpperCase()===e)return Ci.info(`RetryPolicy: Network error ${e} found, will retry.`),!0;if("PARSE_ERROR"===(null==i?void 0:i.code)&&(null==i?void 0:i.message.startsWith('Error "Error: Unclosed root tag')))return Ci.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0}if(r||i){const t=null!==(o=null!==(n=null==r?void 0:r.status)&&void 0!==n?n:null==i?void 0:i.statusCode)&&void 0!==o?o:0;if(!e&&404===t)return Ci.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(503===t||500===t)return Ci.info(`RetryPolicy: Will retry for status code ${t}.`),!0}return!1}function f(e,t){let r=0;if(e)switch(a){case Mn.EXPONENTIAL:r=Math.min((Math.pow(2,t-1)-1)*d,c);break;case Mn.FIXED:r=d}else r=1e3*Math.random();return Ci.info(`RetryPolicy: Delay for ${r}ms`),r}return{name:"storageRetryPolicy",async sendRequest(e,t){p&&(e.url=nn(e.url,Oi.TIMEOUT,String(Math.floor(p/1e3))));const r=e.url,i=u?sn(e.url,u):void 0;let n,o,s=!1,a=1,l=!0;for(;l;){const d=s||!i||!["GET","HEAD","OPTIONS"].includes(e.method)||a%2==1;e.url=d?r:i,n=void 0,o=void 0;try{Ci.info(`RetryPolicy: =====> Try=${a} ${d?"Primary":"Secondary"}`),n=await t(e),s=s||!d&&404===n.status}catch(e){if(!Qt(e))throw Ci.error(`RetryPolicy: Caught error, message: ${Ke(e)}`),e;Ci.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`),o=e}l=h({isPrimaryRetry:d,attempt:a,response:n,error:o}),l&&await pn(f(d,a),e.abortSignal,Pn),a++}if(n)return n;throw null!=o?o:new Yt("RetryPolicy failed without known error.")}}}(o.retryOptions),{phase:"Retry"}),l.addPolicy({name:"storageBrowserPolicy",sendRequest:async(e,t)=>(ot||("GET"!==e.method&&"HEAD"!==e.method||(e.url=nn(e.url,Oi.FORCE_BROWSER_NO_CACHE,(new Date).getTime().toString())),e.headers.delete(ji),e.headers.delete(qi)),t(e))});const n=function(e){const t=[$n,Hn,Gn,Wn,Kn,Vn,Jn];if(e.factories.length){const r=e.factories.filter((e=>!t.some((t=>t(e)))));if(r.length){const e=r.some((e=>function(e){return"InjectorPolicyFactory"===e.constructor.name}(e)));return{wrappedPolicies:gi(r),afterRetry:e}}}}(e);n&&l.addPolicy(n.wrappedPolicies,n.afterRetry?{afterPhase:"Retry"}:void 0);const s=jn(e);dr(s)?l.addPolicy(lr({credential:s,scopes:null!==(r=o.audience)&&void 0!==r?r:Pi,challengeCallbacks:{authorizeRequestOnChallenge:ri}}),{phase:"Sign"}):s instanceof mr&&l.addPolicy((s.accountName,s.accountKey,{name:"storageSharedKeyCredentialPolicy",sendRequest:async(e,t)=>t(e)}),{phase:"Sign"}),e._corePipeline=l}return Object.assign(Object.assign({},o),{allowInsecureConnection:!0,httpClient:s,pipeline:l})}function jn(e){if(e._credential)return e._credential;let t=new fr;for(const r of e.factories)if(dr(r.credential))t=r.credential;else if(Hn(r))return r;return t}function Hn(e){return e instanceof mr||"StorageSharedKeyCredential"===e.constructor.name}function $n(e){return e instanceof fr||"AnonymousCredential"===e.constructor.name}function Gn(e){return dr(e.credential)}function Wn(e){return e instanceof zn||"StorageBrowserPolicyFactory"===e.constructor.name}function Kn(e){return e instanceof An||"StorageRetryPolicyFactory"===e.constructor.name}function Vn(e){return"TelemetryPolicyFactory"===e.constructor.name}function Jn(e){const t={log(e,t){},shouldLog:e=>!1},r=e.create({sendRequest:async e=>({request:e,headers:e.headers.clone(),status:500})},t).constructor.name;return["GenerateClientRequestIdPolicy","TracingPolicy","LogPolicy","ProxyPolicy","DisableResponseDecompressionPolicy","KeepAlivePolicy","DeserializationPolicy"].some((e=>r.startsWith(e)))}const Yn={serializedName:"BlobServiceProperties",xmlName:"StorageServiceProperties",type:{name:"Composite",className:"BlobServiceProperties",modelProperties:{blobAnalyticsLogging:{serializedName:"Logging",xmlName:"Logging",type:{name:"Composite",className:"Logging"}},hourMetrics:{serializedName:"HourMetrics",xmlName:"HourMetrics",type:{name:"Composite",className:"Metrics"}},minuteMetrics:{serializedName:"MinuteMetrics",xmlName:"MinuteMetrics",type:{name:"Composite",className:"Metrics"}},cors:{serializedName:"Cors",xmlName:"Cors",xmlIsWrapped:!0,xmlElementName:"CorsRule",type:{name:"Sequence",element:{type:{name:"Composite",className:"CorsRule"}}}},defaultServiceVersion:{serializedName:"DefaultServiceVersion",xmlName:"DefaultServiceVersion",type:{name:"String"}},deleteRetentionPolicy:{serializedName:"DeleteRetentionPolicy",xmlName:"DeleteRetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}},staticWebsite:{serializedName:"StaticWebsite",xmlName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite"}}}}},Qn={serializedName:"Logging",type:{name:"Composite",className:"Logging",modelProperties:{version:{serializedName:"Version",required:!0,xmlName:"Version",type:{name:"String"}},deleteProperty:{serializedName:"Delete",required:!0,xmlName:"Delete",type:{name:"Boolean"}},read:{serializedName:"Read",required:!0,xmlName:"Read",type:{name:"Boolean"}},write:{serializedName:"Write",required:!0,xmlName:"Write",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}},Zn={serializedName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy",modelProperties:{enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},days:{constraints:{InclusiveMinimum:1},serializedName:"Days",xmlName:"Days",type:{name:"Number"}}}}},Xn={serializedName:"Metrics",type:{name:"Composite",className:"Metrics",modelProperties:{version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},includeAPIs:{serializedName:"IncludeAPIs",xmlName:"IncludeAPIs",type:{name:"Boolean"}},retentionPolicy:{serializedName:"RetentionPolicy",xmlName:"RetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}}}}},eo={serializedName:"CorsRule",type:{name:"Composite",className:"CorsRule",modelProperties:{allowedOrigins:{serializedName:"AllowedOrigins",required:!0,xmlName:"AllowedOrigins",type:{name:"String"}},allowedMethods:{serializedName:"AllowedMethods",required:!0,xmlName:"AllowedMethods",type:{name:"String"}},allowedHeaders:{serializedName:"AllowedHeaders",required:!0,xmlName:"AllowedHeaders",type:{name:"String"}},exposedHeaders:{serializedName:"ExposedHeaders",required:!0,xmlName:"ExposedHeaders",type:{name:"String"}},maxAgeInSeconds:{constraints:{InclusiveMinimum:0},serializedName:"MaxAgeInSeconds",required:!0,xmlName:"MaxAgeInSeconds",type:{name:"Number"}}}}},to={serializedName:"StaticWebsite",type:{name:"Composite",className:"StaticWebsite",modelProperties:{enabled:{serializedName:"Enabled",required:!0,xmlName:"Enabled",type:{name:"Boolean"}},indexDocument:{serializedName:"IndexDocument",xmlName:"IndexDocument",type:{name:"String"}},errorDocument404Path:{serializedName:"ErrorDocument404Path",xmlName:"ErrorDocument404Path",type:{name:"String"}},defaultIndexDocumentPath:{serializedName:"DefaultIndexDocumentPath",xmlName:"DefaultIndexDocumentPath",type:{name:"String"}}}}},ro={serializedName:"StorageError",type:{name:"Composite",className:"StorageError",modelProperties:{message:{serializedName:"Message",xmlName:"Message",type:{name:"String"}},code:{serializedName:"Code",xmlName:"Code",type:{name:"String"}},authenticationErrorDetail:{serializedName:"AuthenticationErrorDetail",xmlName:"AuthenticationErrorDetail",type:{name:"String"}}}}},io={serializedName:"BlobServiceStatistics",xmlName:"StorageServiceStats",type:{name:"Composite",className:"BlobServiceStatistics",modelProperties:{geoReplication:{serializedName:"GeoReplication",xmlName:"GeoReplication",type:{name:"Composite",className:"GeoReplication"}}}}},no={serializedName:"GeoReplication",type:{name:"Composite",className:"GeoReplication",modelProperties:{status:{serializedName:"Status",required:!0,xmlName:"Status",type:{name:"Enum",allowedValues:["live","bootstrap","unavailable"]}},lastSyncOn:{serializedName:"LastSyncTime",required:!0,xmlName:"LastSyncTime",type:{name:"DateTimeRfc1123"}}}}},oo={serializedName:"ListContainersSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListContainersSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},containerItems:{serializedName:"ContainerItems",required:!0,xmlName:"Containers",xmlIsWrapped:!0,xmlElementName:"Container",type:{name:"Sequence",element:{type:{name:"Composite",className:"ContainerItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},so={serializedName:"ContainerItem",xmlName:"Container",type:{name:"Composite",className:"ContainerItem",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},deleted:{serializedName:"Deleted",xmlName:"Deleted",type:{name:"Boolean"}},version:{serializedName:"Version",xmlName:"Version",type:{name:"String"}},properties:{serializedName:"Properties",xmlName:"Properties",type:{name:"Composite",className:"ContainerProperties"}},metadata:{serializedName:"Metadata",xmlName:"Metadata",type:{name:"Dictionary",value:{type:{name:"String"}}}}}}},ao={serializedName:"ContainerProperties",type:{name:"Composite",className:"ContainerProperties",modelProperties:{lastModified:{serializedName:"Last-Modified",required:!0,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:!0,xmlName:"Etag",type:{name:"String"}},leaseStatus:{serializedName:"LeaseStatus",xmlName:"LeaseStatus",type:{name:"Enum",allowedValues:["locked","unlocked"]}},leaseState:{serializedName:"LeaseState",xmlName:"LeaseState",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseDuration:{serializedName:"LeaseDuration",xmlName:"LeaseDuration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},publicAccess:{serializedName:"PublicAccess",xmlName:"PublicAccess",type:{name:"Enum",allowedValues:["container","blob"]}},hasImmutabilityPolicy:{serializedName:"HasImmutabilityPolicy",xmlName:"HasImmutabilityPolicy",type:{name:"Boolean"}},hasLegalHold:{serializedName:"HasLegalHold",xmlName:"HasLegalHold",type:{name:"Boolean"}},defaultEncryptionScope:{serializedName:"DefaultEncryptionScope",xmlName:"DefaultEncryptionScope",type:{name:"String"}},preventEncryptionScopeOverride:{serializedName:"DenyEncryptionScopeOverride",xmlName:"DenyEncryptionScopeOverride",type:{name:"Boolean"}},deletedOn:{serializedName:"DeletedTime",xmlName:"DeletedTime",type:{name:"DateTimeRfc1123"}},remainingRetentionDays:{serializedName:"RemainingRetentionDays",xmlName:"RemainingRetentionDays",type:{name:"Number"}},isImmutableStorageWithVersioningEnabled:{serializedName:"ImmutableStorageWithVersioningEnabled",xmlName:"ImmutableStorageWithVersioningEnabled",type:{name:"Boolean"}}}}},lo={serializedName:"KeyInfo",type:{name:"Composite",className:"KeyInfo",modelProperties:{startsOn:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",required:!0,xmlName:"Expiry",type:{name:"String"}}}}},co={serializedName:"UserDelegationKey",type:{name:"Composite",className:"UserDelegationKey",modelProperties:{signedObjectId:{serializedName:"SignedOid",required:!0,xmlName:"SignedOid",type:{name:"String"}},signedTenantId:{serializedName:"SignedTid",required:!0,xmlName:"SignedTid",type:{name:"String"}},signedStartsOn:{serializedName:"SignedStart",required:!0,xmlName:"SignedStart",type:{name:"String"}},signedExpiresOn:{serializedName:"SignedExpiry",required:!0,xmlName:"SignedExpiry",type:{name:"String"}},signedService:{serializedName:"SignedService",required:!0,xmlName:"SignedService",type:{name:"String"}},signedVersion:{serializedName:"SignedVersion",required:!0,xmlName:"SignedVersion",type:{name:"String"}},value:{serializedName:"Value",required:!0,xmlName:"Value",type:{name:"String"}}}}},uo={serializedName:"FilterBlobSegment",xmlName:"EnumerationResults",type:{name:"Composite",className:"FilterBlobSegment",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},where:{serializedName:"Where",required:!0,xmlName:"Where",type:{name:"String"}},blobs:{serializedName:"Blobs",required:!0,xmlName:"Blobs",xmlIsWrapped:!0,xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"FilterBlobItem"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},po={serializedName:"FilterBlobItem",xmlName:"Blob",type:{name:"Composite",className:"FilterBlobItem",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",type:{name:"String"}},tags:{serializedName:"Tags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}}}}},ho={serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags",modelProperties:{blobTagSet:{serializedName:"BlobTagSet",required:!0,xmlName:"TagSet",xmlIsWrapped:!0,xmlElementName:"Tag",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobTag"}}}}}}},fo={serializedName:"BlobTag",xmlName:"Tag",type:{name:"Composite",className:"BlobTag",modelProperties:{key:{serializedName:"Key",required:!0,xmlName:"Key",type:{name:"String"}},value:{serializedName:"Value",required:!0,xmlName:"Value",type:{name:"String"}}}}},mo={serializedName:"SignedIdentifier",xmlName:"SignedIdentifier",type:{name:"Composite",className:"SignedIdentifier",modelProperties:{id:{serializedName:"Id",required:!0,xmlName:"Id",type:{name:"String"}},accessPolicy:{serializedName:"AccessPolicy",xmlName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy"}}}}},go={serializedName:"AccessPolicy",type:{name:"Composite",className:"AccessPolicy",modelProperties:{startsOn:{serializedName:"Start",xmlName:"Start",type:{name:"String"}},expiresOn:{serializedName:"Expiry",xmlName:"Expiry",type:{name:"String"}},permissions:{serializedName:"Permission",xmlName:"Permission",type:{name:"String"}}}}},yo={serializedName:"ListBlobsFlatSegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsFlatSegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},segment:{serializedName:"Segment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment"}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},vo={serializedName:"BlobFlatListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobFlatListSegment",modelProperties:{blobItems:{serializedName:"BlobItems",required:!0,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}},bo={serializedName:"BlobItemInternal",xmlName:"Blob",type:{name:"Composite",className:"BlobItemInternal",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}},deleted:{serializedName:"Deleted",required:!0,xmlName:"Deleted",type:{name:"Boolean"}},snapshot:{serializedName:"Snapshot",required:!0,xmlName:"Snapshot",type:{name:"String"}},versionId:{serializedName:"VersionId",xmlName:"VersionId",type:{name:"String"}},isCurrentVersion:{serializedName:"IsCurrentVersion",xmlName:"IsCurrentVersion",type:{name:"Boolean"}},properties:{serializedName:"Properties",xmlName:"Properties",type:{name:"Composite",className:"BlobPropertiesInternal"}},metadata:{serializedName:"Metadata",xmlName:"Metadata",type:{name:"Dictionary",value:{type:{name:"String"}}}},blobTags:{serializedName:"BlobTags",xmlName:"Tags",type:{name:"Composite",className:"BlobTags"}},objectReplicationMetadata:{serializedName:"ObjectReplicationMetadata",xmlName:"OrMetadata",type:{name:"Dictionary",value:{type:{name:"String"}}}},hasVersionsOnly:{serializedName:"HasVersionsOnly",xmlName:"HasVersionsOnly",type:{name:"Boolean"}}}}},wo={serializedName:"BlobName",type:{name:"Composite",className:"BlobName",modelProperties:{encoded:{serializedName:"Encoded",xmlName:"Encoded",xmlIsAttribute:!0,type:{name:"Boolean"}},content:{serializedName:"content",xmlName:"content",xmlIsMsText:!0,type:{name:"String"}}}}},_o={serializedName:"BlobPropertiesInternal",xmlName:"Properties",type:{name:"Composite",className:"BlobPropertiesInternal",modelProperties:{createdOn:{serializedName:"Creation-Time",xmlName:"Creation-Time",type:{name:"DateTimeRfc1123"}},lastModified:{serializedName:"Last-Modified",required:!0,xmlName:"Last-Modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"Etag",required:!0,xmlName:"Etag",type:{name:"String"}},contentLength:{serializedName:"Content-Length",xmlName:"Content-Length",type:{name:"Number"}},contentType:{serializedName:"Content-Type",xmlName:"Content-Type",type:{name:"String"}},contentEncoding:{serializedName:"Content-Encoding",xmlName:"Content-Encoding",type:{name:"String"}},contentLanguage:{serializedName:"Content-Language",xmlName:"Content-Language",type:{name:"String"}},contentMD5:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}},contentDisposition:{serializedName:"Content-Disposition",xmlName:"Content-Disposition",type:{name:"String"}},cacheControl:{serializedName:"Cache-Control",xmlName:"Cache-Control",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"BlobType",xmlName:"BlobType",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},leaseStatus:{serializedName:"LeaseStatus",xmlName:"LeaseStatus",type:{name:"Enum",allowedValues:["locked","unlocked"]}},leaseState:{serializedName:"LeaseState",xmlName:"LeaseState",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseDuration:{serializedName:"LeaseDuration",xmlName:"LeaseDuration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},copyId:{serializedName:"CopyId",xmlName:"CopyId",type:{name:"String"}},copyStatus:{serializedName:"CopyStatus",xmlName:"CopyStatus",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},copySource:{serializedName:"CopySource",xmlName:"CopySource",type:{name:"String"}},copyProgress:{serializedName:"CopyProgress",xmlName:"CopyProgress",type:{name:"String"}},copyCompletedOn:{serializedName:"CopyCompletionTime",xmlName:"CopyCompletionTime",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"CopyStatusDescription",xmlName:"CopyStatusDescription",type:{name:"String"}},serverEncrypted:{serializedName:"ServerEncrypted",xmlName:"ServerEncrypted",type:{name:"Boolean"}},incrementalCopy:{serializedName:"IncrementalCopy",xmlName:"IncrementalCopy",type:{name:"Boolean"}},destinationSnapshot:{serializedName:"DestinationSnapshot",xmlName:"DestinationSnapshot",type:{name:"String"}},deletedOn:{serializedName:"DeletedTime",xmlName:"DeletedTime",type:{name:"DateTimeRfc1123"}},remainingRetentionDays:{serializedName:"RemainingRetentionDays",xmlName:"RemainingRetentionDays",type:{name:"Number"}},accessTier:{serializedName:"AccessTier",xmlName:"AccessTier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}},accessTierInferred:{serializedName:"AccessTierInferred",xmlName:"AccessTierInferred",type:{name:"Boolean"}},archiveStatus:{serializedName:"ArchiveStatus",xmlName:"ArchiveStatus",type:{name:"Enum",allowedValues:["rehydrate-pending-to-hot","rehydrate-pending-to-cool","rehydrate-pending-to-cold"]}},customerProvidedKeySha256:{serializedName:"CustomerProvidedKeySha256",xmlName:"CustomerProvidedKeySha256",type:{name:"String"}},encryptionScope:{serializedName:"EncryptionScope",xmlName:"EncryptionScope",type:{name:"String"}},accessTierChangedOn:{serializedName:"AccessTierChangeTime",xmlName:"AccessTierChangeTime",type:{name:"DateTimeRfc1123"}},tagCount:{serializedName:"TagCount",xmlName:"TagCount",type:{name:"Number"}},expiresOn:{serializedName:"Expiry-Time",xmlName:"Expiry-Time",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"Sealed",xmlName:"Sealed",type:{name:"Boolean"}},rehydratePriority:{serializedName:"RehydratePriority",xmlName:"RehydratePriority",type:{name:"Enum",allowedValues:["High","Standard"]}},lastAccessedOn:{serializedName:"LastAccessTime",xmlName:"LastAccessTime",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"ImmutabilityPolicyUntilDate",xmlName:"ImmutabilityPolicyUntilDate",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"ImmutabilityPolicyMode",xmlName:"ImmutabilityPolicyMode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"LegalHold",xmlName:"LegalHold",type:{name:"Boolean"}}}}},xo={serializedName:"ListBlobsHierarchySegmentResponse",xmlName:"EnumerationResults",type:{name:"Composite",className:"ListBlobsHierarchySegmentResponse",modelProperties:{serviceEndpoint:{serializedName:"ServiceEndpoint",required:!0,xmlName:"ServiceEndpoint",xmlIsAttribute:!0,type:{name:"String"}},containerName:{serializedName:"ContainerName",required:!0,xmlName:"ContainerName",xmlIsAttribute:!0,type:{name:"String"}},prefix:{serializedName:"Prefix",xmlName:"Prefix",type:{name:"String"}},marker:{serializedName:"Marker",xmlName:"Marker",type:{name:"String"}},maxPageSize:{serializedName:"MaxResults",xmlName:"MaxResults",type:{name:"Number"}},delimiter:{serializedName:"Delimiter",xmlName:"Delimiter",type:{name:"String"}},segment:{serializedName:"Segment",xmlName:"Blobs",type:{name:"Composite",className:"BlobHierarchyListSegment"}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},So={serializedName:"BlobHierarchyListSegment",xmlName:"Blobs",type:{name:"Composite",className:"BlobHierarchyListSegment",modelProperties:{blobPrefixes:{serializedName:"BlobPrefixes",xmlName:"BlobPrefixes",xmlElementName:"BlobPrefix",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobPrefix"}}}},blobItems:{serializedName:"BlobItems",required:!0,xmlName:"BlobItems",xmlElementName:"Blob",type:{name:"Sequence",element:{type:{name:"Composite",className:"BlobItemInternal"}}}}}}},ko={serializedName:"BlobPrefix",type:{name:"Composite",className:"BlobPrefix",modelProperties:{name:{serializedName:"Name",xmlName:"Name",type:{name:"Composite",className:"BlobName"}}}}},Eo={serializedName:"BlockLookupList",xmlName:"BlockList",type:{name:"Composite",className:"BlockLookupList",modelProperties:{committed:{serializedName:"Committed",xmlName:"Committed",xmlElementName:"Committed",type:{name:"Sequence",element:{type:{name:"String"}}}},uncommitted:{serializedName:"Uncommitted",xmlName:"Uncommitted",xmlElementName:"Uncommitted",type:{name:"Sequence",element:{type:{name:"String"}}}},latest:{serializedName:"Latest",xmlName:"Latest",xmlElementName:"Latest",type:{name:"Sequence",element:{type:{name:"String"}}}}}}},To={serializedName:"BlockList",type:{name:"Composite",className:"BlockList",modelProperties:{committedBlocks:{serializedName:"CommittedBlocks",xmlName:"CommittedBlocks",xmlIsWrapped:!0,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}},uncommittedBlocks:{serializedName:"UncommittedBlocks",xmlName:"UncommittedBlocks",xmlIsWrapped:!0,xmlElementName:"Block",type:{name:"Sequence",element:{type:{name:"Composite",className:"Block"}}}}}}},Bo={serializedName:"Block",type:{name:"Composite",className:"Block",modelProperties:{name:{serializedName:"Name",required:!0,xmlName:"Name",type:{name:"String"}},size:{serializedName:"Size",required:!0,xmlName:"Size",type:{name:"Number"}}}}},Co={serializedName:"PageList",type:{name:"Composite",className:"PageList",modelProperties:{pageRange:{serializedName:"PageRange",xmlName:"PageRange",xmlElementName:"PageRange",type:{name:"Sequence",element:{type:{name:"Composite",className:"PageRange"}}}},clearRange:{serializedName:"ClearRange",xmlName:"ClearRange",xmlElementName:"ClearRange",type:{name:"Sequence",element:{type:{name:"Composite",className:"ClearRange"}}}},continuationToken:{serializedName:"NextMarker",xmlName:"NextMarker",type:{name:"String"}}}}},Io={serializedName:"PageRange",xmlName:"PageRange",type:{name:"Composite",className:"PageRange",modelProperties:{start:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:!0,xmlName:"End",type:{name:"Number"}}}}},Ao={serializedName:"ClearRange",xmlName:"ClearRange",type:{name:"Composite",className:"ClearRange",modelProperties:{start:{serializedName:"Start",required:!0,xmlName:"Start",type:{name:"Number"}},end:{serializedName:"End",required:!0,xmlName:"End",type:{name:"Number"}}}}},Fo={serializedName:"QueryRequest",xmlName:"QueryRequest",type:{name:"Composite",className:"QueryRequest",modelProperties:{queryType:{serializedName:"QueryType",required:!0,xmlName:"QueryType",type:{name:"String"}},expression:{serializedName:"Expression",required:!0,xmlName:"Expression",type:{name:"String"}},inputSerialization:{serializedName:"InputSerialization",xmlName:"InputSerialization",type:{name:"Composite",className:"QuerySerialization"}},outputSerialization:{serializedName:"OutputSerialization",xmlName:"OutputSerialization",type:{name:"Composite",className:"QuerySerialization"}}}}},Mo={serializedName:"QuerySerialization",type:{name:"Composite",className:"QuerySerialization",modelProperties:{format:{serializedName:"Format",xmlName:"Format",type:{name:"Composite",className:"QueryFormat"}}}}},Do={serializedName:"QueryFormat",type:{name:"Composite",className:"QueryFormat",modelProperties:{type:{serializedName:"Type",required:!0,xmlName:"Type",type:{name:"Enum",allowedValues:["delimited","json","arrow","parquet"]}},delimitedTextConfiguration:{serializedName:"DelimitedTextConfiguration",xmlName:"DelimitedTextConfiguration",type:{name:"Composite",className:"DelimitedTextConfiguration"}},jsonTextConfiguration:{serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration"}},arrowConfiguration:{serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration"}},parquetTextConfiguration:{serializedName:"ParquetTextConfiguration",xmlName:"ParquetTextConfiguration",type:{name:"Dictionary",value:{type:{name:"any"}}}}}}},Ro={serializedName:"DelimitedTextConfiguration",xmlName:"DelimitedTextConfiguration",type:{name:"Composite",className:"DelimitedTextConfiguration",modelProperties:{columnSeparator:{serializedName:"ColumnSeparator",xmlName:"ColumnSeparator",type:{name:"String"}},fieldQuote:{serializedName:"FieldQuote",xmlName:"FieldQuote",type:{name:"String"}},recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}},escapeChar:{serializedName:"EscapeChar",xmlName:"EscapeChar",type:{name:"String"}},headersPresent:{serializedName:"HeadersPresent",xmlName:"HasHeaders",type:{name:"Boolean"}}}}},Po={serializedName:"JsonTextConfiguration",xmlName:"JsonTextConfiguration",type:{name:"Composite",className:"JsonTextConfiguration",modelProperties:{recordSeparator:{serializedName:"RecordSeparator",xmlName:"RecordSeparator",type:{name:"String"}}}}},Oo={serializedName:"ArrowConfiguration",xmlName:"ArrowConfiguration",type:{name:"Composite",className:"ArrowConfiguration",modelProperties:{schema:{serializedName:"Schema",required:!0,xmlName:"Schema",xmlIsWrapped:!0,xmlElementName:"Field",type:{name:"Sequence",element:{type:{name:"Composite",className:"ArrowField"}}}}}}},zo={serializedName:"ArrowField",xmlName:"Field",type:{name:"Composite",className:"ArrowField",modelProperties:{type:{serializedName:"Type",required:!0,xmlName:"Type",type:{name:"String"}},name:{serializedName:"Name",xmlName:"Name",type:{name:"String"}},precision:{serializedName:"Precision",xmlName:"Precision",type:{name:"Number"}},scale:{serializedName:"Scale",xmlName:"Scale",type:{name:"Number"}}}}},No={serializedName:"Service_setPropertiesHeaders",type:{name:"Composite",className:"ServiceSetPropertiesHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},qo={serializedName:"Service_setPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceSetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Uo={serializedName:"Service_getPropertiesHeaders",type:{name:"Composite",className:"ServiceGetPropertiesHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Lo={serializedName:"Service_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ServiceGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},jo={serializedName:"Service_getStatisticsHeaders",type:{name:"Composite",className:"ServiceGetStatisticsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ho={serializedName:"Service_getStatisticsExceptionHeaders",type:{name:"Composite",className:"ServiceGetStatisticsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},$o={serializedName:"Service_listContainersSegmentHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Go={serializedName:"Service_listContainersSegmentExceptionHeaders",type:{name:"Composite",className:"ServiceListContainersSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Wo={serializedName:"Service_getUserDelegationKeyHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ko={serializedName:"Service_getUserDelegationKeyExceptionHeaders",type:{name:"Composite",className:"ServiceGetUserDelegationKeyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Vo={serializedName:"Service_getAccountInfoHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}},isHierarchicalNamespaceEnabled:{serializedName:"x-ms-is-hns-enabled",xmlName:"x-ms-is-hns-enabled",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Jo={serializedName:"Service_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ServiceGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Yo={serializedName:"Service_submitBatchHeaders",type:{name:"Composite",className:"ServiceSubmitBatchHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Qo={serializedName:"Service_submitBatchExceptionHeaders",type:{name:"Composite",className:"ServiceSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Zo={serializedName:"Service_filterBlobsHeaders",type:{name:"Composite",className:"ServiceFilterBlobsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Xo={serializedName:"Service_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ServiceFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},es={serializedName:"Container_createHeaders",type:{name:"Composite",className:"ContainerCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ts={serializedName:"Container_createExceptionHeaders",type:{name:"Composite",className:"ContainerCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},rs={serializedName:"Container_getPropertiesHeaders",type:{name:"Composite",className:"ContainerGetPropertiesHeaders",modelProperties:{metadata:{serializedName:"x-ms-meta",headerCollectionPrefix:"x-ms-meta-",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobPublicAccess:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}},hasImmutabilityPolicy:{serializedName:"x-ms-has-immutability-policy",xmlName:"x-ms-has-immutability-policy",type:{name:"Boolean"}},hasLegalHold:{serializedName:"x-ms-has-legal-hold",xmlName:"x-ms-has-legal-hold",type:{name:"Boolean"}},defaultEncryptionScope:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}},denyEncryptionScopeOverride:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}},isImmutableStorageWithVersioningEnabled:{serializedName:"x-ms-immutable-storage-with-versioning-enabled",xmlName:"x-ms-immutable-storage-with-versioning-enabled",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},is={serializedName:"Container_getPropertiesExceptionHeaders",type:{name:"Composite",className:"ContainerGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ns={serializedName:"Container_deleteHeaders",type:{name:"Composite",className:"ContainerDeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},os={serializedName:"Container_deleteExceptionHeaders",type:{name:"Composite",className:"ContainerDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ss={serializedName:"Container_setMetadataHeaders",type:{name:"Composite",className:"ContainerSetMetadataHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},as={serializedName:"Container_setMetadataExceptionHeaders",type:{name:"Composite",className:"ContainerSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ls={serializedName:"Container_getAccessPolicyHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyHeaders",modelProperties:{blobPublicAccess:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ds={serializedName:"Container_getAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},cs={serializedName:"Container_setAccessPolicyHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},us={serializedName:"Container_setAccessPolicyExceptionHeaders",type:{name:"Composite",className:"ContainerSetAccessPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ps={serializedName:"Container_restoreHeaders",type:{name:"Composite",className:"ContainerRestoreHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},hs={serializedName:"Container_restoreExceptionHeaders",type:{name:"Composite",className:"ContainerRestoreExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},fs={serializedName:"Container_renameHeaders",type:{name:"Composite",className:"ContainerRenameHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ms={serializedName:"Container_renameExceptionHeaders",type:{name:"Composite",className:"ContainerRenameExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},gs={serializedName:"Container_submitBatchHeaders",type:{name:"Composite",className:"ContainerSubmitBatchHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}}}}},ys={serializedName:"Container_submitBatchExceptionHeaders",type:{name:"Composite",className:"ContainerSubmitBatchExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},vs={serializedName:"Container_filterBlobsHeaders",type:{name:"Composite",className:"ContainerFilterBlobsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},bs={serializedName:"Container_filterBlobsExceptionHeaders",type:{name:"Composite",className:"ContainerFilterBlobsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ws={serializedName:"Container_acquireLeaseHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},_s={serializedName:"Container_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},xs={serializedName:"Container_releaseLeaseHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Ss={serializedName:"Container_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ks={serializedName:"Container_renewLeaseHeaders",type:{name:"Composite",className:"ContainerRenewLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Es={serializedName:"Container_renewLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ts={serializedName:"Container_breakLeaseHeaders",type:{name:"Composite",className:"ContainerBreakLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseTime:{serializedName:"x-ms-lease-time",xmlName:"x-ms-lease-time",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Bs={serializedName:"Container_breakLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Cs={serializedName:"Container_changeLeaseHeaders",type:{name:"Composite",className:"ContainerChangeLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Is={serializedName:"Container_changeLeaseExceptionHeaders",type:{name:"Composite",className:"ContainerChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},As={serializedName:"Container_listBlobFlatSegmentHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Fs={serializedName:"Container_listBlobFlatSegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobFlatSegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ms={serializedName:"Container_listBlobHierarchySegmentHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentHeaders",modelProperties:{contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ds={serializedName:"Container_listBlobHierarchySegmentExceptionHeaders",type:{name:"Composite",className:"ContainerListBlobHierarchySegmentExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Rs={serializedName:"Container_getAccountInfoHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}},isHierarchicalNamespaceEnabled:{serializedName:"x-ms-is-hns-enabled",xmlName:"x-ms-is-hns-enabled",type:{name:"Boolean"}}}}},Ps={serializedName:"Container_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"ContainerGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Os={serializedName:"Blob_downloadHeaders",type:{name:"Composite",className:"BlobDownloadHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},createdOn:{serializedName:"x-ms-creation-time",xmlName:"x-ms-creation-time",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",headerCollectionPrefix:"x-ms-meta-",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}}},objectReplicationPolicyId:{serializedName:"x-ms-or-policy-id",xmlName:"x-ms-or-policy-id",type:{name:"String"}},objectReplicationRules:{serializedName:"x-ms-or",headerCollectionPrefix:"x-ms-or-",xmlName:"x-ms-or",type:{name:"Dictionary",value:{type:{name:"String"}}}},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},contentRange:{serializedName:"content-range",xmlName:"content-range",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletedOn:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},isCurrentVersion:{serializedName:"x-ms-is-current-version",xmlName:"x-ms-is-current-version",type:{name:"Boolean"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},blobContentMD5:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}},tagCount:{serializedName:"x-ms-tag-count",xmlName:"x-ms-tag-count",type:{name:"Number"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}},lastAccessed:{serializedName:"x-ms-last-access-time",xmlName:"x-ms-last-access-time",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}},contentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}}}},zs={serializedName:"Blob_downloadExceptionHeaders",type:{name:"Composite",className:"BlobDownloadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ns={serializedName:"Blob_getPropertiesHeaders",type:{name:"Composite",className:"BlobGetPropertiesHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},createdOn:{serializedName:"x-ms-creation-time",xmlName:"x-ms-creation-time",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",headerCollectionPrefix:"x-ms-meta-",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}}},objectReplicationPolicyId:{serializedName:"x-ms-or-policy-id",xmlName:"x-ms-or-policy-id",type:{name:"String"}},objectReplicationRules:{serializedName:"x-ms-or",headerCollectionPrefix:"x-ms-or-",xmlName:"x-ms-or",type:{name:"Dictionary",value:{type:{name:"String"}}}},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletedOn:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},isIncrementalCopy:{serializedName:"x-ms-incremental-copy",xmlName:"x-ms-incremental-copy",type:{name:"Boolean"}},destinationSnapshot:{serializedName:"x-ms-copy-destination-snapshot",xmlName:"x-ms-copy-destination-snapshot",type:{name:"String"}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},accessTier:{serializedName:"x-ms-access-tier",xmlName:"x-ms-access-tier",type:{name:"String"}},accessTierInferred:{serializedName:"x-ms-access-tier-inferred",xmlName:"x-ms-access-tier-inferred",type:{name:"Boolean"}},archiveStatus:{serializedName:"x-ms-archive-status",xmlName:"x-ms-archive-status",type:{name:"String"}},accessTierChangedOn:{serializedName:"x-ms-access-tier-change-time",xmlName:"x-ms-access-tier-change-time",type:{name:"DateTimeRfc1123"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},isCurrentVersion:{serializedName:"x-ms-is-current-version",xmlName:"x-ms-is-current-version",type:{name:"Boolean"}},tagCount:{serializedName:"x-ms-tag-count",xmlName:"x-ms-tag-count",type:{name:"Number"}},expiresOn:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}},rehydratePriority:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}},lastAccessed:{serializedName:"x-ms-last-access-time",xmlName:"x-ms-last-access-time",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiresOn:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},qs={serializedName:"Blob_getPropertiesExceptionHeaders",type:{name:"Composite",className:"BlobGetPropertiesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Us={serializedName:"Blob_deleteHeaders",type:{name:"Composite",className:"BlobDeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ls={serializedName:"Blob_deleteExceptionHeaders",type:{name:"Composite",className:"BlobDeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},js={serializedName:"Blob_undeleteHeaders",type:{name:"Composite",className:"BlobUndeleteHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Hs={serializedName:"Blob_undeleteExceptionHeaders",type:{name:"Composite",className:"BlobUndeleteExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},$s={serializedName:"Blob_setExpiryHeaders",type:{name:"Composite",className:"BlobSetExpiryHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Gs={serializedName:"Blob_setExpiryExceptionHeaders",type:{name:"Composite",className:"BlobSetExpiryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ws={serializedName:"Blob_setHttpHeadersHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ks={serializedName:"Blob_setHttpHeadersExceptionHeaders",type:{name:"Composite",className:"BlobSetHttpHeadersExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Vs={serializedName:"Blob_setImmutabilityPolicyHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyExpiry:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}},immutabilityPolicyMode:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}}}},Js={serializedName:"Blob_setImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobSetImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ys={serializedName:"Blob_deleteImmutabilityPolicyHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},Qs={serializedName:"Blob_deleteImmutabilityPolicyExceptionHeaders",type:{name:"Composite",className:"BlobDeleteImmutabilityPolicyExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Zs={serializedName:"Blob_setLegalHoldHeaders",type:{name:"Composite",className:"BlobSetLegalHoldHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},legalHold:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}}}},Xs={serializedName:"Blob_setLegalHoldExceptionHeaders",type:{name:"Composite",className:"BlobSetLegalHoldExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ea={serializedName:"Blob_setMetadataHeaders",type:{name:"Composite",className:"BlobSetMetadataHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ta={serializedName:"Blob_setMetadataExceptionHeaders",type:{name:"Composite",className:"BlobSetMetadataExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ra={serializedName:"Blob_acquireLeaseHeaders",type:{name:"Composite",className:"BlobAcquireLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},ia={serializedName:"Blob_acquireLeaseExceptionHeaders",type:{name:"Composite",className:"BlobAcquireLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},na={serializedName:"Blob_releaseLeaseHeaders",type:{name:"Composite",className:"BlobReleaseLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},oa={serializedName:"Blob_releaseLeaseExceptionHeaders",type:{name:"Composite",className:"BlobReleaseLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},sa={serializedName:"Blob_renewLeaseHeaders",type:{name:"Composite",className:"BlobRenewLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},aa={serializedName:"Blob_renewLeaseExceptionHeaders",type:{name:"Composite",className:"BlobRenewLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},la={serializedName:"Blob_changeLeaseHeaders",type:{name:"Composite",className:"BlobChangeLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},leaseId:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},da={serializedName:"Blob_changeLeaseExceptionHeaders",type:{name:"Composite",className:"BlobChangeLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ca={serializedName:"Blob_breakLeaseHeaders",type:{name:"Composite",className:"BlobBreakLeaseHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},leaseTime:{serializedName:"x-ms-lease-time",xmlName:"x-ms-lease-time",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}}}}},ua={serializedName:"Blob_breakLeaseExceptionHeaders",type:{name:"Composite",className:"BlobBreakLeaseExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},pa={serializedName:"Blob_createSnapshotHeaders",type:{name:"Composite",className:"BlobCreateSnapshotHeaders",modelProperties:{snapshot:{serializedName:"x-ms-snapshot",xmlName:"x-ms-snapshot",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ha={serializedName:"Blob_createSnapshotExceptionHeaders",type:{name:"Composite",className:"BlobCreateSnapshotExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},fa={serializedName:"Blob_startCopyFromURLHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ma={serializedName:"Blob_startCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobStartCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ga={serializedName:"Blob_copyFromURLHeaders",type:{name:"Composite",className:"BlobCopyFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{defaultValue:"success",isConstant:!0,serializedName:"x-ms-copy-status",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ya={serializedName:"Blob_copyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},va={serializedName:"Blob_abortCopyFromURLHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ba={serializedName:"Blob_abortCopyFromURLExceptionHeaders",type:{name:"Composite",className:"BlobAbortCopyFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},wa={serializedName:"Blob_setTierHeaders",type:{name:"Composite",className:"BlobSetTierHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},_a={serializedName:"Blob_setTierExceptionHeaders",type:{name:"Composite",className:"BlobSetTierExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},xa={serializedName:"Blob_getAccountInfoHeaders",type:{name:"Composite",className:"BlobGetAccountInfoHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},skuName:{serializedName:"x-ms-sku-name",xmlName:"x-ms-sku-name",type:{name:"Enum",allowedValues:["Standard_LRS","Standard_GRS","Standard_RAGRS","Standard_ZRS","Premium_LRS"]}},accountKind:{serializedName:"x-ms-account-kind",xmlName:"x-ms-account-kind",type:{name:"Enum",allowedValues:["Storage","BlobStorage","StorageV2","FileStorage","BlockBlobStorage"]}},isHierarchicalNamespaceEnabled:{serializedName:"x-ms-is-hns-enabled",xmlName:"x-ms-is-hns-enabled",type:{name:"Boolean"}}}}},Sa={serializedName:"Blob_getAccountInfoExceptionHeaders",type:{name:"Composite",className:"BlobGetAccountInfoExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ka={serializedName:"Blob_queryHeaders",type:{name:"Composite",className:"BlobQueryHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},metadata:{serializedName:"x-ms-meta",headerCollectionPrefix:"x-ms-meta-",xmlName:"x-ms-meta",type:{name:"Dictionary",value:{type:{name:"String"}}}},contentLength:{serializedName:"content-length",xmlName:"content-length",type:{name:"Number"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},contentRange:{serializedName:"content-range",xmlName:"content-range",type:{name:"String"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},contentEncoding:{serializedName:"content-encoding",xmlName:"content-encoding",type:{name:"String"}},cacheControl:{serializedName:"cache-control",xmlName:"cache-control",type:{name:"String"}},contentDisposition:{serializedName:"content-disposition",xmlName:"content-disposition",type:{name:"String"}},contentLanguage:{serializedName:"content-language",xmlName:"content-language",type:{name:"String"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},blobType:{serializedName:"x-ms-blob-type",xmlName:"x-ms-blob-type",type:{name:"Enum",allowedValues:["BlockBlob","PageBlob","AppendBlob"]}},copyCompletionTime:{serializedName:"x-ms-copy-completion-time",xmlName:"x-ms-copy-completion-time",type:{name:"DateTimeRfc1123"}},copyStatusDescription:{serializedName:"x-ms-copy-status-description",xmlName:"x-ms-copy-status-description",type:{name:"String"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyProgress:{serializedName:"x-ms-copy-progress",xmlName:"x-ms-copy-progress",type:{name:"String"}},copySource:{serializedName:"x-ms-copy-source",xmlName:"x-ms-copy-source",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},leaseDuration:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Enum",allowedValues:["infinite","fixed"]}},leaseState:{serializedName:"x-ms-lease-state",xmlName:"x-ms-lease-state",type:{name:"Enum",allowedValues:["available","leased","expired","breaking","broken"]}},leaseStatus:{serializedName:"x-ms-lease-status",xmlName:"x-ms-lease-status",type:{name:"Enum",allowedValues:["locked","unlocked"]}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},acceptRanges:{serializedName:"accept-ranges",xmlName:"accept-ranges",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-server-encrypted",xmlName:"x-ms-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},blobContentMD5:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}},contentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}}}},Ea={serializedName:"Blob_queryExceptionHeaders",type:{name:"Composite",className:"BlobQueryExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ta={serializedName:"Blob_getTagsHeaders",type:{name:"Composite",className:"BlobGetTagsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ba={serializedName:"Blob_getTagsExceptionHeaders",type:{name:"Composite",className:"BlobGetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ca={serializedName:"Blob_setTagsHeaders",type:{name:"Composite",className:"BlobSetTagsHeaders",modelProperties:{clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ia={serializedName:"Blob_setTagsExceptionHeaders",type:{name:"Composite",className:"BlobSetTagsExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Aa={serializedName:"PageBlob_createHeaders",type:{name:"Composite",className:"PageBlobCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Fa={serializedName:"PageBlob_createExceptionHeaders",type:{name:"Composite",className:"PageBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ma={serializedName:"PageBlob_uploadPagesHeaders",type:{name:"Composite",className:"PageBlobUploadPagesHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Da={serializedName:"PageBlob_uploadPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ra={serializedName:"PageBlob_clearPagesHeaders",type:{name:"Composite",className:"PageBlobClearPagesHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Pa={serializedName:"PageBlob_clearPagesExceptionHeaders",type:{name:"Composite",className:"PageBlobClearPagesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Oa={serializedName:"PageBlob_uploadPagesFromURLHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},za={serializedName:"PageBlob_uploadPagesFromURLExceptionHeaders",type:{name:"Composite",className:"PageBlobUploadPagesFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Na={serializedName:"PageBlob_getPageRangesHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},qa={serializedName:"PageBlob_getPageRangesExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ua={serializedName:"PageBlob_getPageRangesDiffHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},La={serializedName:"PageBlob_getPageRangesDiffExceptionHeaders",type:{name:"Composite",className:"PageBlobGetPageRangesDiffExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ja={serializedName:"PageBlob_resizeHeaders",type:{name:"Composite",className:"PageBlobResizeHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ha={serializedName:"PageBlob_resizeExceptionHeaders",type:{name:"Composite",className:"PageBlobResizeExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},$a={serializedName:"PageBlob_updateSequenceNumberHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},blobSequenceNumber:{serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ga={serializedName:"PageBlob_updateSequenceNumberExceptionHeaders",type:{name:"Composite",className:"PageBlobUpdateSequenceNumberExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Wa={serializedName:"PageBlob_copyIncrementalHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},copyId:{serializedName:"x-ms-copy-id",xmlName:"x-ms-copy-id",type:{name:"String"}},copyStatus:{serializedName:"x-ms-copy-status",xmlName:"x-ms-copy-status",type:{name:"Enum",allowedValues:["pending","success","aborted","failed"]}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ka={serializedName:"PageBlob_copyIncrementalExceptionHeaders",type:{name:"Composite",className:"PageBlobCopyIncrementalExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Va={serializedName:"AppendBlob_createHeaders",type:{name:"Composite",className:"AppendBlobCreateHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ja={serializedName:"AppendBlob_createExceptionHeaders",type:{name:"Composite",className:"AppendBlobCreateExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Ya={serializedName:"AppendBlob_appendBlockHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobAppendOffset:{serializedName:"x-ms-blob-append-offset",xmlName:"x-ms-blob-append-offset",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Qa={serializedName:"AppendBlob_appendBlockExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Za={serializedName:"AppendBlob_appendBlockFromUrlHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},blobAppendOffset:{serializedName:"x-ms-blob-append-offset",xmlName:"x-ms-blob-append-offset",type:{name:"String"}},blobCommittedBlockCount:{serializedName:"x-ms-blob-committed-block-count",xmlName:"x-ms-blob-committed-block-count",type:{name:"Number"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},Xa={serializedName:"AppendBlob_appendBlockFromUrlExceptionHeaders",type:{name:"Composite",className:"AppendBlobAppendBlockFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},el={serializedName:"AppendBlob_sealHeaders",type:{name:"Composite",className:"AppendBlobSealHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isSealed:{serializedName:"x-ms-blob-sealed",xmlName:"x-ms-blob-sealed",type:{name:"Boolean"}}}}},tl={serializedName:"AppendBlob_sealExceptionHeaders",type:{name:"Composite",className:"AppendBlobSealExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},rl={serializedName:"BlockBlob_uploadHeaders",type:{name:"Composite",className:"BlockBlobUploadHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},il={serializedName:"BlockBlob_uploadExceptionHeaders",type:{name:"Composite",className:"BlockBlobUploadExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},nl={serializedName:"BlockBlob_putBlobFromUrlHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ol={serializedName:"BlockBlob_putBlobFromUrlExceptionHeaders",type:{name:"Composite",className:"BlockBlobPutBlobFromUrlExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},sl={serializedName:"BlockBlob_stageBlockHeaders",type:{name:"Composite",className:"BlockBlobStageBlockHeaders",modelProperties:{contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},al={serializedName:"BlockBlob_stageBlockExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ll={serializedName:"BlockBlob_stageBlockFromURLHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLHeaders",modelProperties:{contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},dl={serializedName:"BlockBlob_stageBlockFromURLExceptionHeaders",type:{name:"Composite",className:"BlockBlobStageBlockFromURLExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},cl={serializedName:"BlockBlob_commitBlockListHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListHeaders",modelProperties:{etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},contentMD5:{serializedName:"content-md5",xmlName:"content-md5",type:{name:"ByteArray"}},xMsContentCrc64:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},versionId:{serializedName:"x-ms-version-id",xmlName:"x-ms-version-id",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},isServerEncrypted:{serializedName:"x-ms-request-server-encrypted",xmlName:"x-ms-request-server-encrypted",type:{name:"Boolean"}},encryptionKeySha256:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}},encryptionScope:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},ul={serializedName:"BlockBlob_commitBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobCommitBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},pl={serializedName:"BlockBlob_getBlockListHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListHeaders",modelProperties:{lastModified:{serializedName:"last-modified",xmlName:"last-modified",type:{name:"DateTimeRfc1123"}},etag:{serializedName:"etag",xmlName:"etag",type:{name:"String"}},contentType:{serializedName:"content-type",xmlName:"content-type",type:{name:"String"}},blobContentLength:{serializedName:"x-ms-blob-content-length",xmlName:"x-ms-blob-content-length",type:{name:"Number"}},clientRequestId:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}},requestId:{serializedName:"x-ms-request-id",xmlName:"x-ms-request-id",type:{name:"String"}},version:{serializedName:"x-ms-version",xmlName:"x-ms-version",type:{name:"String"}},date:{serializedName:"date",xmlName:"date",type:{name:"DateTimeRfc1123"}},errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},hl={serializedName:"BlockBlob_getBlockListExceptionHeaders",type:{name:"Composite",className:"BlockBlobGetBlockListExceptionHeaders",modelProperties:{errorCode:{serializedName:"x-ms-error-code",xmlName:"x-ms-error-code",type:{name:"String"}}}}},fl={parameterPath:["options","contentType"],mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Content-Type",type:{name:"String"}}},ml={parameterPath:"blobServiceProperties",mapper:Yn},gl={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},yl={parameterPath:"url",mapper:{serializedName:"url",required:!0,xmlName:"url",type:{name:"String"}},skipEncoding:!0},vl={parameterPath:"restype",mapper:{defaultValue:"service",isConstant:!0,serializedName:"restype",type:{name:"String"}}},bl={parameterPath:"comp",mapper:{defaultValue:"properties",isConstant:!0,serializedName:"comp",type:{name:"String"}}},wl={parameterPath:["options","timeoutInSeconds"],mapper:{constraints:{InclusiveMinimum:0},serializedName:"timeout",xmlName:"timeout",type:{name:"Number"}}},_l={parameterPath:"version",mapper:{defaultValue:"2024-11-04",isConstant:!0,serializedName:"x-ms-version",type:{name:"String"}}},xl={parameterPath:["options","requestId"],mapper:{serializedName:"x-ms-client-request-id",xmlName:"x-ms-client-request-id",type:{name:"String"}}},Sl={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},kl={parameterPath:"comp",mapper:{defaultValue:"list",isConstant:!0,serializedName:"comp",type:{name:"String"}}},El={parameterPath:["options","prefix"],mapper:{serializedName:"prefix",xmlName:"prefix",type:{name:"String"}}},Tl={parameterPath:["options","marker"],mapper:{serializedName:"marker",xmlName:"marker",type:{name:"String"}}},Bl={parameterPath:["options","maxPageSize"],mapper:{constraints:{InclusiveMinimum:1},serializedName:"maxresults",xmlName:"maxresults",type:{name:"Number"}}},Cl={parameterPath:"keyInfo",mapper:lo},Il={parameterPath:"restype",mapper:{defaultValue:"account",isConstant:!0,serializedName:"restype",type:{name:"String"}}},Al={parameterPath:"body",mapper:{serializedName:"body",required:!0,xmlName:"body",type:{name:"Stream"}}},Fl={parameterPath:"comp",mapper:{defaultValue:"batch",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Ml={parameterPath:"contentLength",mapper:{serializedName:"Content-Length",required:!0,xmlName:"Content-Length",type:{name:"Number"}}},Dl={parameterPath:"multipartContentType",mapper:{serializedName:"Content-Type",required:!0,xmlName:"Content-Type",type:{name:"String"}}},Rl={parameterPath:"comp",mapper:{defaultValue:"blobs",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Pl={parameterPath:["options","where"],mapper:{serializedName:"where",xmlName:"where",type:{name:"String"}}},Ol={parameterPath:"restype",mapper:{defaultValue:"container",isConstant:!0,serializedName:"restype",type:{name:"String"}}},zl={parameterPath:["options","metadata"],mapper:{serializedName:"x-ms-meta",xmlName:"x-ms-meta",headerCollectionPrefix:"x-ms-meta-",type:{name:"Dictionary",value:{type:{name:"String"}}}}},Nl={parameterPath:["options","access"],mapper:{serializedName:"x-ms-blob-public-access",xmlName:"x-ms-blob-public-access",type:{name:"Enum",allowedValues:["container","blob"]}}},ql={parameterPath:["options","leaseAccessConditions","leaseId"],mapper:{serializedName:"x-ms-lease-id",xmlName:"x-ms-lease-id",type:{name:"String"}}},Ul={parameterPath:["options","modifiedAccessConditions","ifModifiedSince"],mapper:{serializedName:"If-Modified-Since",xmlName:"If-Modified-Since",type:{name:"DateTimeRfc1123"}}},Ll={parameterPath:["options","modifiedAccessConditions","ifUnmodifiedSince"],mapper:{serializedName:"If-Unmodified-Since",xmlName:"If-Unmodified-Since",type:{name:"DateTimeRfc1123"}}},jl={parameterPath:"comp",mapper:{defaultValue:"metadata",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Hl={parameterPath:"comp",mapper:{defaultValue:"acl",isConstant:!0,serializedName:"comp",type:{name:"String"}}},$l={parameterPath:"comp",mapper:{defaultValue:"undelete",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Gl={parameterPath:"comp",mapper:{defaultValue:"lease",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Wl={parameterPath:"action",mapper:{defaultValue:"acquire",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},Kl={parameterPath:["options","duration"],mapper:{serializedName:"x-ms-lease-duration",xmlName:"x-ms-lease-duration",type:{name:"Number"}}},Vl={parameterPath:["options","proposedLeaseId"],mapper:{serializedName:"x-ms-proposed-lease-id",xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}},Jl={parameterPath:"action",mapper:{defaultValue:"release",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},Yl={parameterPath:"leaseId",mapper:{serializedName:"x-ms-lease-id",required:!0,xmlName:"x-ms-lease-id",type:{name:"String"}}},Ql={parameterPath:"action",mapper:{defaultValue:"renew",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},Zl={parameterPath:"action",mapper:{defaultValue:"break",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},Xl={parameterPath:["options","breakPeriod"],mapper:{serializedName:"x-ms-lease-break-period",xmlName:"x-ms-lease-break-period",type:{name:"Number"}}},ed={parameterPath:"action",mapper:{defaultValue:"change",isConstant:!0,serializedName:"x-ms-lease-action",type:{name:"String"}}},td={parameterPath:"proposedLeaseId",mapper:{serializedName:"x-ms-proposed-lease-id",required:!0,xmlName:"x-ms-proposed-lease-id",type:{name:"String"}}},rd={parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListBlobsIncludeItem",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["copy","deleted","metadata","snapshots","uncommittedblobs","versions","tags","immutabilitypolicy","legalhold","deletedwithversions"]}}}},collectionFormat:"CSV"},id={parameterPath:["options","snapshot"],mapper:{serializedName:"snapshot",xmlName:"snapshot",type:{name:"String"}}},nd={parameterPath:["options","versionId"],mapper:{serializedName:"versionid",xmlName:"versionid",type:{name:"String"}}},od={parameterPath:["options","range"],mapper:{serializedName:"x-ms-range",xmlName:"x-ms-range",type:{name:"String"}}},sd={parameterPath:["options","cpkInfo","encryptionKey"],mapper:{serializedName:"x-ms-encryption-key",xmlName:"x-ms-encryption-key",type:{name:"String"}}},ad={parameterPath:["options","cpkInfo","encryptionKeySha256"],mapper:{serializedName:"x-ms-encryption-key-sha256",xmlName:"x-ms-encryption-key-sha256",type:{name:"String"}}},ld={parameterPath:["options","cpkInfo","encryptionAlgorithm"],mapper:{serializedName:"x-ms-encryption-algorithm",xmlName:"x-ms-encryption-algorithm",type:{name:"String"}}},dd={parameterPath:["options","modifiedAccessConditions","ifMatch"],mapper:{serializedName:"If-Match",xmlName:"If-Match",type:{name:"String"}}},cd={parameterPath:["options","modifiedAccessConditions","ifNoneMatch"],mapper:{serializedName:"If-None-Match",xmlName:"If-None-Match",type:{name:"String"}}},ud={parameterPath:["options","modifiedAccessConditions","ifTags"],mapper:{serializedName:"x-ms-if-tags",xmlName:"x-ms-if-tags",type:{name:"String"}}},pd={parameterPath:["options","blobHttpHeaders","blobCacheControl"],mapper:{serializedName:"x-ms-blob-cache-control",xmlName:"x-ms-blob-cache-control",type:{name:"String"}}},hd={parameterPath:["options","blobHttpHeaders","blobContentType"],mapper:{serializedName:"x-ms-blob-content-type",xmlName:"x-ms-blob-content-type",type:{name:"String"}}},fd={parameterPath:["options","blobHttpHeaders","blobContentMD5"],mapper:{serializedName:"x-ms-blob-content-md5",xmlName:"x-ms-blob-content-md5",type:{name:"ByteArray"}}},md={parameterPath:["options","blobHttpHeaders","blobContentEncoding"],mapper:{serializedName:"x-ms-blob-content-encoding",xmlName:"x-ms-blob-content-encoding",type:{name:"String"}}},gd={parameterPath:["options","blobHttpHeaders","blobContentLanguage"],mapper:{serializedName:"x-ms-blob-content-language",xmlName:"x-ms-blob-content-language",type:{name:"String"}}},yd={parameterPath:["options","blobHttpHeaders","blobContentDisposition"],mapper:{serializedName:"x-ms-blob-content-disposition",xmlName:"x-ms-blob-content-disposition",type:{name:"String"}}},vd={parameterPath:"comp",mapper:{defaultValue:"immutabilityPolicies",isConstant:!0,serializedName:"comp",type:{name:"String"}}},bd={parameterPath:["options","immutabilityPolicyExpiry"],mapper:{serializedName:"x-ms-immutability-policy-until-date",xmlName:"x-ms-immutability-policy-until-date",type:{name:"DateTimeRfc1123"}}},wd={parameterPath:["options","immutabilityPolicyMode"],mapper:{serializedName:"x-ms-immutability-policy-mode",xmlName:"x-ms-immutability-policy-mode",type:{name:"Enum",allowedValues:["Mutable","Unlocked","Locked"]}}},_d={parameterPath:["options","encryptionScope"],mapper:{serializedName:"x-ms-encryption-scope",xmlName:"x-ms-encryption-scope",type:{name:"String"}}},xd={parameterPath:["options","tier"],mapper:{serializedName:"x-ms-access-tier",xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}},Sd={parameterPath:["options","rehydratePriority"],mapper:{serializedName:"x-ms-rehydrate-priority",xmlName:"x-ms-rehydrate-priority",type:{name:"Enum",allowedValues:["High","Standard"]}}},kd={parameterPath:["options","sourceModifiedAccessConditions","sourceIfModifiedSince"],mapper:{serializedName:"x-ms-source-if-modified-since",xmlName:"x-ms-source-if-modified-since",type:{name:"DateTimeRfc1123"}}},Ed={parameterPath:["options","sourceModifiedAccessConditions","sourceIfUnmodifiedSince"],mapper:{serializedName:"x-ms-source-if-unmodified-since",xmlName:"x-ms-source-if-unmodified-since",type:{name:"DateTimeRfc1123"}}},Td={parameterPath:["options","sourceModifiedAccessConditions","sourceIfMatch"],mapper:{serializedName:"x-ms-source-if-match",xmlName:"x-ms-source-if-match",type:{name:"String"}}},Bd={parameterPath:["options","sourceModifiedAccessConditions","sourceIfNoneMatch"],mapper:{serializedName:"x-ms-source-if-none-match",xmlName:"x-ms-source-if-none-match",type:{name:"String"}}},Cd={parameterPath:["options","sourceModifiedAccessConditions","sourceIfTags"],mapper:{serializedName:"x-ms-source-if-tags",xmlName:"x-ms-source-if-tags",type:{name:"String"}}},Id={parameterPath:"copySource",mapper:{serializedName:"x-ms-copy-source",required:!0,xmlName:"x-ms-copy-source",type:{name:"String"}}},Ad={parameterPath:["options","blobTagsString"],mapper:{serializedName:"x-ms-tags",xmlName:"x-ms-tags",type:{name:"String"}}},Fd={parameterPath:["options","legalHold"],mapper:{serializedName:"x-ms-legal-hold",xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}},Md={parameterPath:["options","sourceContentMD5"],mapper:{serializedName:"x-ms-source-content-md5",xmlName:"x-ms-source-content-md5",type:{name:"ByteArray"}}},Dd={parameterPath:["options","copySourceAuthorization"],mapper:{serializedName:"x-ms-copy-source-authorization",xmlName:"x-ms-copy-source-authorization",type:{name:"String"}}},Rd={parameterPath:["options","copySourceTags"],mapper:{serializedName:"x-ms-copy-source-tag-option",xmlName:"x-ms-copy-source-tag-option",type:{name:"Enum",allowedValues:["REPLACE","COPY"]}}},Pd={parameterPath:["options","queryRequest"],mapper:Fo},Od={parameterPath:"comp",mapper:{defaultValue:"tags",isConstant:!0,serializedName:"comp",type:{name:"String"}}},zd={parameterPath:["options","tags"],mapper:ho},Nd={parameterPath:["options","transactionalContentMD5"],mapper:{serializedName:"Content-MD5",xmlName:"Content-MD5",type:{name:"ByteArray"}}},qd={parameterPath:["options","transactionalContentCrc64"],mapper:{serializedName:"x-ms-content-crc64",xmlName:"x-ms-content-crc64",type:{name:"ByteArray"}}},Ud={parameterPath:"blobContentLength",mapper:{serializedName:"x-ms-blob-content-length",required:!0,xmlName:"x-ms-blob-content-length",type:{name:"Number"}}},Ld={parameterPath:["options","blobSequenceNumber"],mapper:{defaultValue:0,serializedName:"x-ms-blob-sequence-number",xmlName:"x-ms-blob-sequence-number",type:{name:"Number"}}},jd={parameterPath:["options","contentType"],mapper:{defaultValue:"application/octet-stream",isConstant:!0,serializedName:"Content-Type",type:{name:"String"}}},Hd={parameterPath:"body",mapper:{serializedName:"body",required:!0,xmlName:"body",type:{name:"Stream"}}},$d={parameterPath:"accept",mapper:{defaultValue:"application/xml",isConstant:!0,serializedName:"Accept",type:{name:"String"}}},Gd={parameterPath:"comp",mapper:{defaultValue:"page",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Wd={parameterPath:"pageWrite",mapper:{defaultValue:"update",isConstant:!0,serializedName:"x-ms-page-write",type:{name:"String"}}},Kd={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThanOrEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-le",xmlName:"x-ms-if-sequence-number-le",type:{name:"Number"}}},Vd={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberLessThan"],mapper:{serializedName:"x-ms-if-sequence-number-lt",xmlName:"x-ms-if-sequence-number-lt",type:{name:"Number"}}},Jd={parameterPath:["options","sequenceNumberAccessConditions","ifSequenceNumberEqualTo"],mapper:{serializedName:"x-ms-if-sequence-number-eq",xmlName:"x-ms-if-sequence-number-eq",type:{name:"Number"}}},Yd={parameterPath:"sourceUrl",mapper:{serializedName:"x-ms-copy-source",required:!0,xmlName:"x-ms-copy-source",type:{name:"String"}}},Qd={parameterPath:["options","sourceContentCrc64"],mapper:{serializedName:"x-ms-source-content-crc64",xmlName:"x-ms-source-content-crc64",type:{name:"ByteArray"}}},Zd={parameterPath:"comp",mapper:{defaultValue:"pagelist",isConstant:!0,serializedName:"comp",type:{name:"String"}}},Xd={parameterPath:"comp",mapper:{defaultValue:"appendblock",isConstant:!0,serializedName:"comp",type:{name:"String"}}},ec={parameterPath:["options","appendPositionAccessConditions","maxSize"],mapper:{serializedName:"x-ms-blob-condition-maxsize",xmlName:"x-ms-blob-condition-maxsize",type:{name:"Number"}}},tc={parameterPath:["options","appendPositionAccessConditions","appendPosition"],mapper:{serializedName:"x-ms-blob-condition-appendpos",xmlName:"x-ms-blob-condition-appendpos",type:{name:"Number"}}},rc={parameterPath:["options","sourceRange"],mapper:{serializedName:"x-ms-source-range",xmlName:"x-ms-source-range",type:{name:"String"}}},ic={parameterPath:"blobType",mapper:{defaultValue:"BlockBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}},nc={parameterPath:"comp",mapper:{defaultValue:"block",isConstant:!0,serializedName:"comp",type:{name:"String"}}},oc={parameterPath:"blockId",mapper:{serializedName:"blockid",required:!0,xmlName:"blockid",type:{name:"String"}}},sc={parameterPath:"blocks",mapper:Eo},ac={parameterPath:"comp",mapper:{defaultValue:"blocklist",isConstant:!0,serializedName:"comp",type:{name:"String"}}};class lc{constructor(e){this.client=e}setProperties(e,t){return this.client.sendOperationRequest({blobServiceProperties:e,options:t},cc)}getProperties(e){return this.client.sendOperationRequest({options:e},uc)}getStatistics(e){return this.client.sendOperationRequest({options:e},pc)}listContainersSegment(e){return this.client.sendOperationRequest({options:e},hc)}getUserDelegationKey(e,t){return this.client.sendOperationRequest({keyInfo:e,options:t},fc)}getAccountInfo(e){return this.client.sendOperationRequest({options:e},mc)}submitBatch(e,t,r,i){return this.client.sendOperationRequest({contentLength:e,multipartContentType:t,body:r,options:i},gc)}filterBlobs(e){return this.client.sendOperationRequest({options:e},yc)}}const dc=Er(e,!0),cc={path:"/",httpMethod:"PUT",responses:{202:{headersMapper:No},default:{bodyMapper:ro,headersMapper:qo}},requestBody:ml,queryParameters:[vl,bl,wl],urlParameters:[yl],headerParameters:[fl,gl,_l,xl],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:dc},uc={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:Yn,headersMapper:Uo},default:{bodyMapper:ro,headersMapper:Lo}},queryParameters:[vl,bl,wl],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:dc},pc={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:io,headersMapper:jo},default:{bodyMapper:ro,headersMapper:Ho}},queryParameters:[vl,wl,{parameterPath:"comp",mapper:{defaultValue:"stats",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:dc},hc={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:oo,headersMapper:$o},default:{bodyMapper:ro,headersMapper:Go}},queryParameters:[wl,kl,El,Tl,Bl,{parameterPath:["options","include"],mapper:{serializedName:"include",xmlName:"include",xmlElementName:"ListContainersIncludeType",type:{name:"Sequence",element:{type:{name:"Enum",allowedValues:["metadata","deleted","system"]}}}},collectionFormat:"CSV"}],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:dc},fc={path:"/",httpMethod:"POST",responses:{200:{bodyMapper:co,headersMapper:Wo},default:{bodyMapper:ro,headersMapper:Ko}},requestBody:Cl,queryParameters:[vl,wl,{parameterPath:"comp",mapper:{defaultValue:"userdelegationkey",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[fl,gl,_l,xl],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:dc},mc={path:"/",httpMethod:"GET",responses:{200:{headersMapper:Vo},default:{bodyMapper:ro,headersMapper:Jo}},queryParameters:[bl,wl,Il],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:dc},gc={path:"/",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Yo},default:{bodyMapper:ro,headersMapper:Qo}},requestBody:Al,queryParameters:[wl,Fl],urlParameters:[yl],headerParameters:[gl,_l,xl,Ml,Dl],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:dc},yc={path:"/",httpMethod:"GET",responses:{200:{bodyMapper:uo,headersMapper:Zo},default:{bodyMapper:ro,headersMapper:Xo}},queryParameters:[wl,Tl,Bl,Rl,Pl],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:dc};class vc{constructor(e){this.client=e}create(e){return this.client.sendOperationRequest({options:e},wc)}getProperties(e){return this.client.sendOperationRequest({options:e},_c)}delete(e){return this.client.sendOperationRequest({options:e},xc)}setMetadata(e){return this.client.sendOperationRequest({options:e},Sc)}getAccessPolicy(e){return this.client.sendOperationRequest({options:e},kc)}setAccessPolicy(e){return this.client.sendOperationRequest({options:e},Ec)}restore(e){return this.client.sendOperationRequest({options:e},Tc)}rename(e,t){return this.client.sendOperationRequest({sourceContainerName:e,options:t},Bc)}submitBatch(e,t,r,i){return this.client.sendOperationRequest({contentLength:e,multipartContentType:t,body:r,options:i},Cc)}filterBlobs(e){return this.client.sendOperationRequest({options:e},Ic)}acquireLease(e){return this.client.sendOperationRequest({options:e},Ac)}releaseLease(e,t){return this.client.sendOperationRequest({leaseId:e,options:t},Fc)}renewLease(e,t){return this.client.sendOperationRequest({leaseId:e,options:t},Mc)}breakLease(e){return this.client.sendOperationRequest({options:e},Dc)}changeLease(e,t,r){return this.client.sendOperationRequest({leaseId:e,proposedLeaseId:t,options:r},Rc)}listBlobFlatSegment(e){return this.client.sendOperationRequest({options:e},Pc)}listBlobHierarchySegment(e,t){return this.client.sendOperationRequest({delimiter:e,options:t},Oc)}getAccountInfo(e){return this.client.sendOperationRequest({options:e},zc)}}const bc=Er(e,!0),wc={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:es},default:{bodyMapper:ro,headersMapper:ts}},queryParameters:[wl,Ol],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,Nl,{parameterPath:["options","containerEncryptionScope","defaultEncryptionScope"],mapper:{serializedName:"x-ms-default-encryption-scope",xmlName:"x-ms-default-encryption-scope",type:{name:"String"}}},{parameterPath:["options","containerEncryptionScope","preventEncryptionScopeOverride"],mapper:{serializedName:"x-ms-deny-encryption-scope-override",xmlName:"x-ms-deny-encryption-scope-override",type:{name:"Boolean"}}}],isXML:!0,serializer:bc},_c={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:rs},default:{bodyMapper:ro,headersMapper:is}},queryParameters:[wl,Ol],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql],isXML:!0,serializer:bc},xc={path:"/{containerName}",httpMethod:"DELETE",responses:{202:{headersMapper:ns},default:{bodyMapper:ro,headersMapper:os}},queryParameters:[wl,Ol],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll],isXML:!0,serializer:bc},Sc={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ss},default:{bodyMapper:ro,headersMapper:as}},queryParameters:[wl,Ol,jl],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,ql,Ul],isXML:!0,serializer:bc},kc={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}},serializedName:"SignedIdentifiers",xmlName:"SignedIdentifiers",xmlIsWrapped:!0,xmlElementName:"SignedIdentifier"},headersMapper:ls},default:{bodyMapper:ro,headersMapper:ds}},queryParameters:[wl,Ol,Hl],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql],isXML:!0,serializer:bc},Ec={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:cs},default:{bodyMapper:ro,headersMapper:us}},requestBody:{parameterPath:["options","containerAcl"],mapper:{serializedName:"containerAcl",xmlName:"SignedIdentifiers",xmlIsWrapped:!0,xmlElementName:"SignedIdentifier",type:{name:"Sequence",element:{type:{name:"Composite",className:"SignedIdentifier"}}}}},queryParameters:[wl,Ol,Hl],urlParameters:[yl],headerParameters:[fl,gl,_l,xl,Nl,ql,Ul,Ll],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:bc},Tc={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:ps},default:{bodyMapper:ro,headersMapper:hs}},queryParameters:[wl,Ol,$l],urlParameters:[yl],headerParameters:[_l,xl,Sl,{parameterPath:["options","deletedContainerName"],mapper:{serializedName:"x-ms-deleted-container-name",xmlName:"x-ms-deleted-container-name",type:{name:"String"}}},{parameterPath:["options","deletedContainerVersion"],mapper:{serializedName:"x-ms-deleted-container-version",xmlName:"x-ms-deleted-container-version",type:{name:"String"}}}],isXML:!0,serializer:bc},Bc={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:fs},default:{bodyMapper:ro,headersMapper:ms}},queryParameters:[wl,Ol,{parameterPath:"comp",mapper:{defaultValue:"rename",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,{parameterPath:"sourceContainerName",mapper:{serializedName:"x-ms-source-container-name",required:!0,xmlName:"x-ms-source-container-name",type:{name:"String"}}},{parameterPath:["options","sourceLeaseId"],mapper:{serializedName:"x-ms-source-lease-id",xmlName:"x-ms-source-lease-id",type:{name:"String"}}}],isXML:!0,serializer:bc},Cc={path:"/{containerName}",httpMethod:"POST",responses:{202:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:gs},default:{bodyMapper:ro,headersMapper:ys}},requestBody:Al,queryParameters:[wl,Fl,Ol],urlParameters:[yl],headerParameters:[gl,_l,xl,Ml,Dl],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:bc},Ic={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:uo,headersMapper:vs},default:{bodyMapper:ro,headersMapper:bs}},queryParameters:[wl,Tl,Bl,Rl,Pl,Ol],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:bc},Ac={path:"/{containerName}",httpMethod:"PUT",responses:{201:{headersMapper:ws},default:{bodyMapper:ro,headersMapper:_s}},queryParameters:[wl,Ol,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Wl,Kl,Vl],isXML:!0,serializer:bc},Fc={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:xs},default:{bodyMapper:ro,headersMapper:Ss}},queryParameters:[wl,Ol,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Jl,Yl],isXML:!0,serializer:bc},Mc={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:ks},default:{bodyMapper:ro,headersMapper:Es}},queryParameters:[wl,Ol,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Yl,Ql],isXML:!0,serializer:bc},Dc={path:"/{containerName}",httpMethod:"PUT",responses:{202:{headersMapper:Ts},default:{bodyMapper:ro,headersMapper:Bs}},queryParameters:[wl,Ol,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Zl,Xl],isXML:!0,serializer:bc},Rc={path:"/{containerName}",httpMethod:"PUT",responses:{200:{headersMapper:Cs},default:{bodyMapper:ro,headersMapper:Is}},queryParameters:[wl,Ol,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Yl,ed,td],isXML:!0,serializer:bc},Pc={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:yo,headersMapper:As},default:{bodyMapper:ro,headersMapper:Fs}},queryParameters:[wl,kl,El,Tl,Bl,Ol,rd],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:bc},Oc={path:"/{containerName}",httpMethod:"GET",responses:{200:{bodyMapper:xo,headersMapper:Ms},default:{bodyMapper:ro,headersMapper:Ds}},queryParameters:[wl,kl,El,Tl,Bl,Ol,rd,{parameterPath:"delimiter",mapper:{serializedName:"delimiter",required:!0,xmlName:"delimiter",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:bc},zc={path:"/{containerName}",httpMethod:"GET",responses:{200:{headersMapper:Rs},default:{bodyMapper:ro,headersMapper:Ps}},queryParameters:[bl,wl,Il],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:bc};class Nc{constructor(e){this.client=e}download(e){return this.client.sendOperationRequest({options:e},Uc)}getProperties(e){return this.client.sendOperationRequest({options:e},Lc)}delete(e){return this.client.sendOperationRequest({options:e},jc)}undelete(e){return this.client.sendOperationRequest({options:e},Hc)}setExpiry(e,t){return this.client.sendOperationRequest({expiryOptions:e,options:t},$c)}setHttpHeaders(e){return this.client.sendOperationRequest({options:e},Gc)}setImmutabilityPolicy(e){return this.client.sendOperationRequest({options:e},Wc)}deleteImmutabilityPolicy(e){return this.client.sendOperationRequest({options:e},Kc)}setLegalHold(e,t){return this.client.sendOperationRequest({legalHold:e,options:t},Vc)}setMetadata(e){return this.client.sendOperationRequest({options:e},Jc)}acquireLease(e){return this.client.sendOperationRequest({options:e},Yc)}releaseLease(e,t){return this.client.sendOperationRequest({leaseId:e,options:t},Qc)}renewLease(e,t){return this.client.sendOperationRequest({leaseId:e,options:t},Zc)}changeLease(e,t,r){return this.client.sendOperationRequest({leaseId:e,proposedLeaseId:t,options:r},Xc)}breakLease(e){return this.client.sendOperationRequest({options:e},eu)}createSnapshot(e){return this.client.sendOperationRequest({options:e},tu)}startCopyFromURL(e,t){return this.client.sendOperationRequest({copySource:e,options:t},ru)}copyFromURL(e,t){return this.client.sendOperationRequest({copySource:e,options:t},iu)}abortCopyFromURL(e,t){return this.client.sendOperationRequest({copyId:e,options:t},nu)}setTier(e,t){return this.client.sendOperationRequest({tier:e,options:t},ou)}getAccountInfo(e){return this.client.sendOperationRequest({options:e},su)}query(e){return this.client.sendOperationRequest({options:e},au)}getTags(e){return this.client.sendOperationRequest({options:e},lu)}setTags(e){return this.client.sendOperationRequest({options:e},du)}}const qc=Er(e,!0),Uc={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Os},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:Os},default:{bodyMapper:ro,headersMapper:zs}},queryParameters:[wl,id,nd],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,od,{parameterPath:["options","rangeGetContentMD5"],mapper:{serializedName:"x-ms-range-get-content-md5",xmlName:"x-ms-range-get-content-md5",type:{name:"Boolean"}}},{parameterPath:["options","rangeGetContentCRC64"],mapper:{serializedName:"x-ms-range-get-content-crc64",xmlName:"x-ms-range-get-content-crc64",type:{name:"Boolean"}}},sd,ad,ld,dd,cd,ud],isXML:!0,serializer:qc},Lc={path:"/{containerName}/{blob}",httpMethod:"HEAD",responses:{200:{headersMapper:Ns},default:{bodyMapper:ro,headersMapper:qs}},queryParameters:[wl,id,nd],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud],isXML:!0,serializer:qc},jc={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{202:{headersMapper:Us},default:{bodyMapper:ro,headersMapper:Ls}},queryParameters:[wl,id,nd,{parameterPath:["options","blobDeleteType"],mapper:{serializedName:"deletetype",xmlName:"deletetype",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,dd,cd,ud,{parameterPath:["options","deleteSnapshots"],mapper:{serializedName:"x-ms-delete-snapshots",xmlName:"x-ms-delete-snapshots",type:{name:"Enum",allowedValues:["include","only"]}}}],isXML:!0,serializer:qc},Hc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:js},default:{bodyMapper:ro,headersMapper:Hs}},queryParameters:[wl,$l],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:qc},$c={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:$s},default:{bodyMapper:ro,headersMapper:Gs}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"expiry",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,{parameterPath:"expiryOptions",mapper:{serializedName:"x-ms-expiry-option",required:!0,xmlName:"x-ms-expiry-option",type:{name:"String"}}},{parameterPath:["options","expiresOn"],mapper:{serializedName:"x-ms-expiry-time",xmlName:"x-ms-expiry-time",type:{name:"String"}}}],isXML:!0,serializer:qc},Gc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Ws},default:{bodyMapper:ro,headersMapper:Ks}},queryParameters:[bl,wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,dd,cd,ud,pd,hd,fd,md,gd,yd],isXML:!0,serializer:qc},Wc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Vs},default:{bodyMapper:ro,headersMapper:Js}},queryParameters:[wl,vd],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ll,bd,wd],isXML:!0,serializer:qc},Kc={path:"/{containerName}/{blob}",httpMethod:"DELETE",responses:{200:{headersMapper:Ys},default:{bodyMapper:ro,headersMapper:Qs}},queryParameters:[wl,vd],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:qc},Vc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:Zs},default:{bodyMapper:ro,headersMapper:Xs}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"legalhold",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,{parameterPath:"legalHold",mapper:{serializedName:"x-ms-legal-hold",required:!0,xmlName:"x-ms-legal-hold",type:{name:"Boolean"}}}],isXML:!0,serializer:qc},Jc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ea},default:{bodyMapper:ro,headersMapper:ta}},queryParameters:[wl,jl],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d],isXML:!0,serializer:qc},Yc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ra},default:{bodyMapper:ro,headersMapper:ia}},queryParameters:[wl,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Wl,Kl,Vl,dd,cd,ud],isXML:!0,serializer:qc},Qc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:na},default:{bodyMapper:ro,headersMapper:oa}},queryParameters:[wl,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Jl,Yl,dd,cd,ud],isXML:!0,serializer:qc},Zc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:sa},default:{bodyMapper:ro,headersMapper:aa}},queryParameters:[wl,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Yl,Ql,dd,cd,ud],isXML:!0,serializer:qc},Xc={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:la},default:{bodyMapper:ro,headersMapper:da}},queryParameters:[wl,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Yl,ed,td,dd,cd,ud],isXML:!0,serializer:qc},eu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ca},default:{bodyMapper:ro,headersMapper:ua}},queryParameters:[wl,Gl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,Zl,Xl,dd,cd,ud],isXML:!0,serializer:qc},tu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:pa},default:{bodyMapper:ro,headersMapper:ha}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"snapshot",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d],isXML:!0,serializer:qc},ru={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:fa},default:{bodyMapper:ro,headersMapper:ma}},queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,ql,Ul,Ll,dd,cd,ud,bd,wd,xd,Sd,kd,Ed,Td,Bd,Cd,Id,Ad,{parameterPath:["options","sealBlob"],mapper:{serializedName:"x-ms-seal-blob",xmlName:"x-ms-seal-blob",type:{name:"Boolean"}}},Fd],isXML:!0,serializer:qc},iu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:ga},default:{bodyMapper:ro,headersMapper:ya}},queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,zl,ql,Ul,Ll,dd,cd,ud,bd,wd,_d,xd,kd,Ed,Td,Bd,Id,Ad,Fd,{parameterPath:"xMsRequiresSync",mapper:{defaultValue:"true",isConstant:!0,serializedName:"x-ms-requires-sync",type:{name:"String"}}},Md,Dd,Rd],isXML:!0,serializer:qc},nu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:va},default:{bodyMapper:ro,headersMapper:ba}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"copy",isConstant:!0,serializedName:"comp",type:{name:"String"}}},{parameterPath:"copyId",mapper:{serializedName:"copyid",required:!0,xmlName:"copyid",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,{parameterPath:"copyActionAbortConstant",mapper:{defaultValue:"abort",isConstant:!0,serializedName:"x-ms-copy-action",type:{name:"String"}}}],isXML:!0,serializer:qc},ou={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:wa},202:{headersMapper:wa},default:{bodyMapper:ro,headersMapper:_a}},queryParameters:[wl,id,nd,{parameterPath:"comp",mapper:{defaultValue:"tier",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,ud,Sd,{parameterPath:"tier",mapper:{serializedName:"x-ms-access-tier",required:!0,xmlName:"x-ms-access-tier",type:{name:"Enum",allowedValues:["P4","P6","P10","P15","P20","P30","P40","P50","P60","P70","P80","Hot","Cool","Archive","Cold"]}}}],isXML:!0,serializer:qc},su={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{headersMapper:xa},default:{bodyMapper:ro,headersMapper:Sa}},queryParameters:[bl,wl,Il],urlParameters:[yl],headerParameters:[_l,xl,Sl],isXML:!0,serializer:qc},au={path:"/{containerName}/{blob}",httpMethod:"POST",responses:{200:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ka},206:{bodyMapper:{type:{name:"Stream"},serializedName:"parsedResponse"},headersMapper:ka},default:{bodyMapper:ro,headersMapper:Ea}},requestBody:Pd,queryParameters:[wl,id,{parameterPath:"comp",mapper:{defaultValue:"query",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[fl,gl,_l,xl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:qc},lu={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:ho,headersMapper:Ta},default:{bodyMapper:ro,headersMapper:Ba}},queryParameters:[wl,id,nd,Od],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,ud],isXML:!0,serializer:qc},du={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{204:{headersMapper:Ca},default:{bodyMapper:ro,headersMapper:Ia}},requestBody:zd,queryParameters:[wl,nd,Od],urlParameters:[yl],headerParameters:[fl,gl,_l,xl,ql,ud,Nd,qd],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:qc};class cu{constructor(e){this.client=e}create(e,t,r){return this.client.sendOperationRequest({contentLength:e,blobContentLength:t,options:r},pu)}uploadPages(e,t,r){return this.client.sendOperationRequest({contentLength:e,body:t,options:r},hu)}clearPages(e,t){return this.client.sendOperationRequest({contentLength:e,options:t},fu)}uploadPagesFromURL(e,t,r,i,n){return this.client.sendOperationRequest({sourceUrl:e,sourceRange:t,contentLength:r,range:i,options:n},mu)}getPageRanges(e){return this.client.sendOperationRequest({options:e},gu)}getPageRangesDiff(e){return this.client.sendOperationRequest({options:e},yu)}resize(e,t){return this.client.sendOperationRequest({blobContentLength:e,options:t},vu)}updateSequenceNumber(e,t){return this.client.sendOperationRequest({sequenceNumberAction:e,options:t},bu)}copyIncremental(e,t){return this.client.sendOperationRequest({copySource:e,options:t},wu)}}const uu=Er(e,!0),pu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Aa},default:{bodyMapper:ro,headersMapper:Fa}},queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,pd,hd,fd,md,gd,yd,bd,wd,_d,xd,Ad,Fd,{parameterPath:"blobType",mapper:{defaultValue:"PageBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}},Ud,Ld],isXML:!0,serializer:uu},hu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ma},default:{bodyMapper:ro,headersMapper:Da}},requestBody:Hd,queryParameters:[wl,Gd],urlParameters:[yl],headerParameters:[_l,xl,Ml,ql,Ul,Ll,od,sd,ad,ld,dd,cd,ud,_d,Nd,qd,jd,$d,Wd,Kd,Vd,Jd],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"binary",serializer:uu},fu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ra},default:{bodyMapper:ro,headersMapper:Pa}},queryParameters:[wl,Gd],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,ql,Ul,Ll,od,sd,ad,ld,dd,cd,ud,_d,Kd,Vd,Jd,{parameterPath:"pageWrite",mapper:{defaultValue:"clear",isConstant:!0,serializedName:"x-ms-page-write",type:{name:"String"}}}],isXML:!0,serializer:uu},mu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Oa},default:{bodyMapper:ro,headersMapper:za}},queryParameters:[wl,Gd],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d,kd,Ed,Td,Bd,Md,Dd,Wd,Kd,Vd,Jd,Yd,{parameterPath:"sourceRange",mapper:{serializedName:"x-ms-source-range",required:!0,xmlName:"x-ms-source-range",type:{name:"String"}}},Qd,{parameterPath:"range",mapper:{serializedName:"x-ms-range",required:!0,xmlName:"x-ms-range",type:{name:"String"}}}],isXML:!0,serializer:uu},gu={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Co,headersMapper:Na},default:{bodyMapper:ro,headersMapper:qa}},queryParameters:[wl,Tl,Bl,id,Zd],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,od,dd,cd,ud],isXML:!0,serializer:uu},yu={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:Co,headersMapper:Ua},default:{bodyMapper:ro,headersMapper:La}},queryParameters:[wl,Tl,Bl,id,Zd,{parameterPath:["options","prevsnapshot"],mapper:{serializedName:"prevsnapshot",xmlName:"prevsnapshot",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,od,dd,cd,ud,{parameterPath:["options","prevSnapshotUrl"],mapper:{serializedName:"x-ms-previous-snapshot-url",xmlName:"x-ms-previous-snapshot-url",type:{name:"String"}}}],isXML:!0,serializer:uu},vu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:ja},default:{bodyMapper:ro,headersMapper:Ha}},queryParameters:[bl,wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d,Ud],isXML:!0,serializer:uu},bu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:$a},default:{bodyMapper:ro,headersMapper:Ga}},queryParameters:[bl,wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,dd,cd,ud,Ld,{parameterPath:"sequenceNumberAction",mapper:{serializedName:"x-ms-sequence-number-action",required:!0,xmlName:"x-ms-sequence-number-action",type:{name:"Enum",allowedValues:["max","update","increment"]}}}],isXML:!0,serializer:uu},wu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{202:{headersMapper:Wa},default:{bodyMapper:ro,headersMapper:Ka}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"incrementalcopy",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ul,Ll,dd,cd,ud,Id],isXML:!0,serializer:uu};class _u{constructor(e){this.client=e}create(e,t){return this.client.sendOperationRequest({contentLength:e,options:t},Su)}appendBlock(e,t,r){return this.client.sendOperationRequest({contentLength:e,body:t,options:r},ku)}appendBlockFromUrl(e,t,r){return this.client.sendOperationRequest({sourceUrl:e,contentLength:t,options:r},Eu)}seal(e){return this.client.sendOperationRequest({options:e},Tu)}}const xu=Er(e,!0),Su={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Va},default:{bodyMapper:ro,headersMapper:Ja}},queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,pd,hd,fd,md,gd,yd,bd,wd,_d,Ad,Fd,{parameterPath:"blobType",mapper:{defaultValue:"AppendBlob",isConstant:!0,serializedName:"x-ms-blob-type",type:{name:"String"}}}],isXML:!0,serializer:xu},ku={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Ya},default:{bodyMapper:ro,headersMapper:Qa}},requestBody:Hd,queryParameters:[wl,Xd],urlParameters:[yl],headerParameters:[_l,xl,Ml,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d,Nd,qd,jd,$d,ec,tc],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"binary",serializer:xu},Eu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:Za},default:{bodyMapper:ro,headersMapper:Xa}},queryParameters:[wl,Xd],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,_d,kd,Ed,Td,Bd,Md,Dd,Nd,Yd,Qd,ec,tc,rc],isXML:!0,serializer:xu},Tu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{200:{headersMapper:el},default:{bodyMapper:ro,headersMapper:tl}},queryParameters:[wl,{parameterPath:"comp",mapper:{defaultValue:"seal",isConstant:!0,serializedName:"comp",type:{name:"String"}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,Ul,Ll,dd,cd,tc],isXML:!0,serializer:xu};class Bu{constructor(e){this.client=e}upload(e,t,r){return this.client.sendOperationRequest({contentLength:e,body:t,options:r},Iu)}putBlobFromUrl(e,t,r){return this.client.sendOperationRequest({contentLength:e,copySource:t,options:r},Au)}stageBlock(e,t,r,i){return this.client.sendOperationRequest({blockId:e,contentLength:t,body:r,options:i},Fu)}stageBlockFromURL(e,t,r,i){return this.client.sendOperationRequest({blockId:e,contentLength:t,sourceUrl:r,options:i},Mu)}commitBlockList(e,t){return this.client.sendOperationRequest({blocks:e,options:t},Du)}getBlockList(e,t){return this.client.sendOperationRequest({listType:e,options:t},Ru)}}const Cu=Er(e,!0),Iu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:rl},default:{bodyMapper:ro,headersMapper:il}},requestBody:Hd,queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Ml,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,pd,hd,fd,md,gd,yd,bd,wd,_d,xd,Ad,Fd,Nd,qd,jd,$d,ic],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"binary",serializer:Cu},Au={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:nl},default:{bodyMapper:ro,headersMapper:ol}},queryParameters:[wl],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,pd,hd,fd,md,gd,yd,_d,xd,kd,Ed,Td,Bd,Cd,Id,Ad,Md,Dd,Rd,Nd,ic,{parameterPath:["options","copySourceBlobProperties"],mapper:{serializedName:"x-ms-copy-source-blob-properties",xmlName:"x-ms-copy-source-blob-properties",type:{name:"Boolean"}}}],isXML:!0,serializer:Cu},Fu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:sl},default:{bodyMapper:ro,headersMapper:al}},requestBody:Hd,queryParameters:[wl,nc,oc],urlParameters:[yl],headerParameters:[_l,xl,Ml,ql,sd,ad,ld,_d,Nd,qd,jd,$d],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"binary",serializer:Cu},Mu={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:ll},default:{bodyMapper:ro,headersMapper:dl}},queryParameters:[wl,nc,oc],urlParameters:[yl],headerParameters:[_l,xl,Sl,Ml,ql,sd,ad,ld,_d,kd,Ed,Td,Bd,Md,Dd,Yd,Qd,rc],isXML:!0,serializer:Cu},Du={path:"/{containerName}/{blob}",httpMethod:"PUT",responses:{201:{headersMapper:cl},default:{bodyMapper:ro,headersMapper:ul}},requestBody:sc,queryParameters:[wl,ac],urlParameters:[yl],headerParameters:[fl,gl,_l,xl,zl,ql,Ul,Ll,sd,ad,ld,dd,cd,ud,pd,hd,fd,md,gd,yd,bd,wd,_d,xd,Ad,Fd,Nd,qd],isXML:!0,contentType:"application/xml; charset=utf-8",mediaType:"xml",serializer:Cu},Ru={path:"/{containerName}/{blob}",httpMethod:"GET",responses:{200:{bodyMapper:To,headersMapper:pl},default:{bodyMapper:ro,headersMapper:hl}},queryParameters:[wl,id,ac,{parameterPath:"listType",mapper:{defaultValue:"committed",serializedName:"blocklisttype",required:!0,xmlName:"blocklisttype",type:{name:"Enum",allowedValues:["committed","uncommitted","all"]}}}],urlParameters:[yl],headerParameters:[_l,xl,Sl,ql,ud],isXML:!0,serializer:Cu};class Pu extends hi{constructor(e,t){var r,i;if(void 0===e)throw new Error("'url' cannot be null");t||(t={});const n="azsdk-js-azure-storage-blob/12.25.0",o=t.userAgentOptions&&t.userAgentOptions.userAgentPrefix?`${t.userAgentOptions.userAgentPrefix} ${n}`:`${n}`;super(Object.assign(Object.assign(Object.assign({},{requestContentType:"application/json; charset=utf-8"}),t),{userAgentOptions:{userAgentPrefix:o},endpoint:null!==(i=null!==(r=t.endpoint)&&void 0!==r?r:t.baseUri)&&void 0!==i?i:"{url}"})),this.url=e,this.version=t.version||"2024-11-04",this.service=new lc(this),this.container=new vc(this),this.blob=new Nc(this),this.pageBlob=new cu(this),this.appendBlob=new _u(this),this.blockBlob=new Bu(this)}}class Ou extends Pu{async sendOperationRequest(e,t){const r=Object.assign({},t);return"/{containerName}"!==r.path&&"/{containerName}/{blob}"!==r.path||(r.path=""),super.sendOperationRequest(e,r)}}class zu{constructor(e,t){this.url=Xi(e),this.accountName=fn(e),this.pipeline=t,this.storageClientContext=new Ou(this.url,Ln(t)),this.isHttps=hn(function(e){try{const t=new URL(e);return t.protocol.endsWith(":")?t.protocol.slice(0,-1):t.protocol}catch(e){return}}(this.url)||"","https"),this.credential=jn(t);this.storageClientContext.requestContentType=void 0}}const Nu=Kt({packageName:"@azure/storage-blob",packageVersion:Ii,namespace:"Microsoft.Storage"});class qu{constructor(){this.read=!1,this.add=!1,this.create=!1,this.write=!1,this.delete=!1,this.deleteVersion=!1,this.tag=!1,this.move=!1,this.execute=!1,this.setImmutabilityPolicy=!1,this.permanentDelete=!1}static parse(e){const t=new qu;for(const r of e)switch(r){case"r":t.read=!0;break;case"a":t.add=!0;break;case"c":t.create=!0;break;case"w":t.write=!0;break;case"d":t.delete=!0;break;case"x":t.deleteVersion=!0;break;case"t":t.tag=!0;break;case"m":t.move=!0;break;case"e":t.execute=!0;break;case"i":t.setImmutabilityPolicy=!0;break;case"y":t.permanentDelete=!0;break;default:throw new RangeError(`Invalid permission: ${r}`)}return t}static from(e){const t=new qu;return e.read&&(t.read=!0),e.add&&(t.add=!0),e.create&&(t.create=!0),e.write&&(t.write=!0),e.delete&&(t.delete=!0),e.deleteVersion&&(t.deleteVersion=!0),e.tag&&(t.tag=!0),e.move&&(t.move=!0),e.execute&&(t.execute=!0),e.setImmutabilityPolicy&&(t.setImmutabilityPolicy=!0),e.permanentDelete&&(t.permanentDelete=!0),t}toString(){const e=[];return this.read&&e.push("r"),this.add&&e.push("a"),this.create&&e.push("c"),this.write&&e.push("w"),this.delete&&e.push("d"),this.deleteVersion&&e.push("x"),this.tag&&e.push("t"),this.move&&e.push("m"),this.execute&&e.push("e"),this.setImmutabilityPolicy&&e.push("i"),this.permanentDelete&&e.push("y"),e.join("")}}class Uu{constructor(){this.read=!1,this.add=!1,this.create=!1,this.write=!1,this.delete=!1,this.deleteVersion=!1,this.list=!1,this.tag=!1,this.move=!1,this.execute=!1,this.setImmutabilityPolicy=!1,this.permanentDelete=!1,this.filterByTags=!1}static parse(e){const t=new Uu;for(const r of e)switch(r){case"r":t.read=!0;break;case"a":t.add=!0;break;case"c":t.create=!0;break;case"w":t.write=!0;break;case"d":t.delete=!0;break;case"l":t.list=!0;break;case"t":t.tag=!0;break;case"x":t.deleteVersion=!0;break;case"m":t.move=!0;break;case"e":t.execute=!0;break;case"i":t.setImmutabilityPolicy=!0;break;case"y":t.permanentDelete=!0;break;case"f":t.filterByTags=!0;break;default:throw new RangeError(`Invalid permission ${r}`)}return t}static from(e){const t=new Uu;return e.read&&(t.read=!0),e.add&&(t.add=!0),e.create&&(t.create=!0),e.write&&(t.write=!0),e.delete&&(t.delete=!0),e.list&&(t.list=!0),e.deleteVersion&&(t.deleteVersion=!0),e.tag&&(t.tag=!0),e.move&&(t.move=!0),e.execute&&(t.execute=!0),e.setImmutabilityPolicy&&(t.setImmutabilityPolicy=!0),e.permanentDelete&&(t.permanentDelete=!0),e.filterByTags&&(t.filterByTags=!0),t}toString(){const e=[];return this.read&&e.push("r"),this.add&&e.push("a"),this.create&&e.push("c"),this.write&&e.push("w"),this.delete&&e.push("d"),this.deleteVersion&&e.push("x"),this.list&&e.push("l"),this.tag&&e.push("t"),this.move&&e.push("m"),this.execute&&e.push("e"),this.setImmutabilityPolicy&&e.push("i"),this.permanentDelete&&e.push("y"),this.filterByTags&&e.push("f"),e.join("")}}class Lu{}function ju(e){return e.end?`${e.start}-${e.end}`:e.start}var Hu;!function(e){e.Https="https",e.HttpsAndHttp="https,http"}(Hu||(Hu={}));class $u{get ipRange(){if(this.ipRangeInner)return{end:this.ipRangeInner.end,start:this.ipRangeInner.start}}constructor(e,t,r,i,n,o,s,a,l,d,c,u,p,h,f,m,g,y,v,b){this.version=e,this.signature=t,void 0!==r&&"string"!=typeof r?(this.permissions=r.permissions,this.services=r.services,this.resourceTypes=r.resourceTypes,this.protocol=r.protocol,this.startsOn=r.startsOn,this.expiresOn=r.expiresOn,this.ipRangeInner=r.ipRange,this.identifier=r.identifier,this.encryptionScope=r.encryptionScope,this.resource=r.resource,this.cacheControl=r.cacheControl,this.contentDisposition=r.contentDisposition,this.contentEncoding=r.contentEncoding,this.contentLanguage=r.contentLanguage,this.contentType=r.contentType,r.userDelegationKey&&(this.signedOid=r.userDelegationKey.signedObjectId,this.signedTenantId=r.userDelegationKey.signedTenantId,this.signedStartsOn=r.userDelegationKey.signedStartsOn,this.signedExpiresOn=r.userDelegationKey.signedExpiresOn,this.signedService=r.userDelegationKey.signedService,this.signedVersion=r.userDelegationKey.signedVersion,this.preauthorizedAgentObjectId=r.preauthorizedAgentObjectId,this.correlationId=r.correlationId)):(this.services=i,this.resourceTypes=n,this.expiresOn=a,this.permissions=r,this.protocol=o,this.startsOn=s,this.ipRangeInner=l,this.encryptionScope=b,this.identifier=d,this.resource=c,this.cacheControl=u,this.contentDisposition=p,this.contentEncoding=h,this.contentLanguage=f,this.contentType=m,g&&(this.signedOid=g.signedObjectId,this.signedTenantId=g.signedTenantId,this.signedStartsOn=g.signedStartsOn,this.signedExpiresOn=g.signedExpiresOn,this.signedService=g.signedService,this.signedVersion=g.signedVersion,this.preauthorizedAgentObjectId=y,this.correlationId=v))}toString(){const e=["sv","ss","srt","spr","st","se","sip","si","ses","skoid","sktid","skt","ske","sks","skv","sr","sp","sig","rscc","rscd","rsce","rscl","rsct","saoid","scid"],t=[];for(const r of e)switch(r){case"sv":this.tryAppendQueryParameter(t,r,this.version);break;case"ss":this.tryAppendQueryParameter(t,r,this.services);break;case"srt":this.tryAppendQueryParameter(t,r,this.resourceTypes);break;case"spr":this.tryAppendQueryParameter(t,r,this.protocol);break;case"st":this.tryAppendQueryParameter(t,r,this.startsOn?cn(this.startsOn,!1):void 0);break;case"se":this.tryAppendQueryParameter(t,r,this.expiresOn?cn(this.expiresOn,!1):void 0);break;case"sip":this.tryAppendQueryParameter(t,r,this.ipRange?ju(this.ipRange):void 0);break;case"si":this.tryAppendQueryParameter(t,r,this.identifier);break;case"ses":this.tryAppendQueryParameter(t,r,this.encryptionScope);break;case"skoid":this.tryAppendQueryParameter(t,r,this.signedOid);break;case"sktid":this.tryAppendQueryParameter(t,r,this.signedTenantId);break;case"skt":this.tryAppendQueryParameter(t,r,this.signedStartsOn?cn(this.signedStartsOn,!1):void 0);break;case"ske":this.tryAppendQueryParameter(t,r,this.signedExpiresOn?cn(this.signedExpiresOn,!1):void 0);break;case"sks":this.tryAppendQueryParameter(t,r,this.signedService);break;case"skv":this.tryAppendQueryParameter(t,r,this.signedVersion);break;case"sr":this.tryAppendQueryParameter(t,r,this.resource);break;case"sp":this.tryAppendQueryParameter(t,r,this.permissions);break;case"sig":this.tryAppendQueryParameter(t,r,this.signature);break;case"rscc":this.tryAppendQueryParameter(t,r,this.cacheControl);break;case"rscd":this.tryAppendQueryParameter(t,r,this.contentDisposition);break;case"rsce":this.tryAppendQueryParameter(t,r,this.contentEncoding);break;case"rscl":this.tryAppendQueryParameter(t,r,this.contentLanguage);break;case"rsct":this.tryAppendQueryParameter(t,r,this.contentType);break;case"saoid":this.tryAppendQueryParameter(t,r,this.preauthorizedAgentObjectId);break;case"scid":this.tryAppendQueryParameter(t,r,this.correlationId)}return t.join("&")}tryAppendQueryParameter(e,t,r){r&&(t=encodeURIComponent(t),r=encodeURIComponent(r),t.length>0&&r.length>0&&e.push(`${t}=${r}`))}}function Gu(e,t,r){return Wu(e,t,r).sasQueryParameters}function Wu(e,t,r){const i=e.version?e.version:Ai,n=t instanceof mr?t:void 0;let o;if(void 0===n&&void 0!==r&&(o=new Lu(r,t)),void 0===n&&void 0===o)throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.");if(i>="2020-12-06")return void 0!==n?function(e,t){if(e=Vu(e),!(e.identifier||e.permissions&&e.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r,i="c",n=e.snapshotTime;e.blobName&&(i="b",e.snapshotTime?i="bs":e.versionId&&(i="bv",n=e.versionId));e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const o=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,i,n,e.encryptionScope,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n"),s=t.computeHMACSHA256(o);return{sasQueryParameters:new $u(e.version,s,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,void 0,void 0,void 0,e.encryptionScope),stringToSign:o}}(e,n):function(e,t){if(e=Vu(e),!e.permissions||!e.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r,i="c",n=e.snapshotTime;e.blobName&&(i="b",e.snapshotTime?i="bs":e.versionId&&(i="bv",n=e.versionId));e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const o=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?cn(t.userDelegationKey.signedStartsOn,!1):"",t.userDelegationKey.signedExpiresOn?cn(t.userDelegationKey.signedExpiresOn,!1):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,void 0,e.correlationId,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,i,n,e.encryptionScope,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n"),s=t.computeHMACSHA256(o);return{sasQueryParameters:new $u(e.version,s,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId,e.encryptionScope),stringToSign:o}}(e,o);if(i>="2018-11-09")return void 0!==n?function(e,t){if(e=Vu(e),!(e.identifier||e.permissions&&e.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r,i="c",n=e.snapshotTime;e.blobName&&(i="b",e.snapshotTime?i="bs":e.versionId&&(i="bv",n=e.versionId));e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const o=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,i,n,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n"),s=t.computeHMACSHA256(o);return{sasQueryParameters:new $u(e.version,s,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType),stringToSign:o}}(e,n):i>="2020-02-10"?function(e,t){if(e=Vu(e),!e.permissions||!e.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r,i="c",n=e.snapshotTime;e.blobName&&(i="b",e.snapshotTime?i="bs":e.versionId&&(i="bv",n=e.versionId));e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const o=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?cn(t.userDelegationKey.signedStartsOn,!1):"",t.userDelegationKey.signedExpiresOn?cn(t.userDelegationKey.signedExpiresOn,!1):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.preauthorizedAgentObjectId,void 0,e.correlationId,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,i,n,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n"),s=t.computeHMACSHA256(o);return{sasQueryParameters:new $u(e.version,s,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey,e.preauthorizedAgentObjectId,e.correlationId),stringToSign:o}}(e,o):function(e,t){if(e=Vu(e),!e.permissions||!e.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r,i="c",n=e.snapshotTime;e.blobName&&(i="b",e.snapshotTime?i="bs":e.versionId&&(i="bv",n=e.versionId));e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const o=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),t.userDelegationKey.signedObjectId,t.userDelegationKey.signedTenantId,t.userDelegationKey.signedStartsOn?cn(t.userDelegationKey.signedStartsOn,!1):"",t.userDelegationKey.signedExpiresOn?cn(t.userDelegationKey.signedExpiresOn,!1):"",t.userDelegationKey.signedService,t.userDelegationKey.signedVersion,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,i,n,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType].join("\n"),s=t.computeHMACSHA256(o);return{sasQueryParameters:new $u(e.version,s,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType,t.userDelegationKey),stringToSign:o}}(e,o);if(i>="2015-04-05"){if(void 0!==n)return function(e,t){if(e=Vu(e),!(e.identifier||e.permissions&&e.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r,i="c";e.blobName&&(i="b");e.permissions&&(r=e.blobName?qu.parse(e.permissions.toString()).toString():Uu.parse(e.permissions.toString()).toString());const n=[r||"",e.startsOn?cn(e.startsOn,!1):"",e.expiresOn?cn(e.expiresOn,!1):"",Ku(t.accountName,e.containerName,e.blobName),e.identifier,e.ipRange?ju(e.ipRange):"",e.protocol?e.protocol:"",e.version,e.cacheControl?e.cacheControl:"",e.contentDisposition?e.contentDisposition:"",e.contentEncoding?e.contentEncoding:"",e.contentLanguage?e.contentLanguage:"",e.contentType?e.contentType:""].join("\n"),o=t.computeHMACSHA256(n);return{sasQueryParameters:new $u(e.version,o,r,void 0,void 0,e.protocol,e.startsOn,e.expiresOn,e.ipRange,e.identifier,i,e.cacheControl,e.contentDisposition,e.contentEncoding,e.contentLanguage,e.contentType),stringToSign:n}}(e,n);throw new RangeError("'version' must be >= '2018-11-09' when generating user delegation SAS using user delegation key.")}throw new RangeError("'version' must be >= '2015-04-05'.")}function Ku(e,t,r){const i=[`/blob/${e}/${t}`];return r&&i.push(`/${r}`),i.join("")}function Vu(e){const t=e.version?e.version:Ai;if(e.snapshotTime&&t<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(void 0===e.blobName&&e.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(e.versionId&&t<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(void 0===e.blobName&&e.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(e.permissions&&e.permissions.setImmutabilityPolicy&&t<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(e.permissions&&e.permissions.deleteVersion&&t<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(e.permissions&&e.permissions.permanentDelete&&t<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(e.permissions&&e.permissions.tag&&t<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(t<"2020-02-10"&&e.permissions&&(e.permissions.move||e.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(t<"2021-04-10"&&e.permissions&&e.permissions.filterByTags)throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(t<"2020-02-10"&&(e.preauthorizedAgentObjectId||e.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(e.encryptionScope&&t<"2020-12-06")throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");return e.version=t,e}class Ju{get leaseId(){return this._leaseId}get url(){return this._url}constructor(e,t){const r=e.storageClientContext;this._url=e.url,void 0===e.name?(this._isContainer=!0,this._containerOrBlobOperation=r.container):(this._isContainer=!1,this._containerOrBlobOperation=r.blob),t||(t=et()),this._leaseId=t}async acquireLease(e,t={}){var r,i,n,o,s;if(this._isContainer&&((null===(r=t.conditions)||void 0===r?void 0:r.ifMatch)&&(null===(i=t.conditions)||void 0===i?void 0:i.ifMatch)!==Gi||(null===(n=t.conditions)||void 0===n?void 0:n.ifNoneMatch)&&(null===(o=t.conditions)||void 0===o?void 0:o.ifNoneMatch)!==Gi||(null===(s=t.conditions)||void 0===s?void 0:s.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return Nu.withSpan("BlobLeaseClient-acquireLease",t,(async r=>{var i;return Tn(await this._containerOrBlobOperation.acquireLease({abortSignal:t.abortSignal,duration:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),proposedLeaseId:this._leaseId,tracingOptions:r.tracingOptions}))}))}async changeLease(e,t={}){var r,i,n,o,s;if(this._isContainer&&((null===(r=t.conditions)||void 0===r?void 0:r.ifMatch)&&(null===(i=t.conditions)||void 0===i?void 0:i.ifMatch)!==Gi||(null===(n=t.conditions)||void 0===n?void 0:n.ifNoneMatch)&&(null===(o=t.conditions)||void 0===o?void 0:o.ifNoneMatch)!==Gi||(null===(s=t.conditions)||void 0===s?void 0:s.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return Nu.withSpan("BlobLeaseClient-changeLease",t,(async r=>{var i;const n=Tn(await this._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions}));return this._leaseId=e,n}))}async releaseLease(e={}){var t,r,i,n,o;if(this._isContainer&&((null===(t=e.conditions)||void 0===t?void 0:t.ifMatch)&&(null===(r=e.conditions)||void 0===r?void 0:r.ifMatch)!==Gi||(null===(i=e.conditions)||void 0===i?void 0:i.ifNoneMatch)&&(null===(n=e.conditions)||void 0===n?void 0:n.ifNoneMatch)!==Gi||(null===(o=e.conditions)||void 0===o?void 0:o.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return Nu.withSpan("BlobLeaseClient-releaseLease",e,(async t=>{var r;return Tn(await this._containerOrBlobOperation.releaseLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),tracingOptions:t.tracingOptions}))}))}async renewLease(e={}){var t,r,i,n,o;if(this._isContainer&&((null===(t=e.conditions)||void 0===t?void 0:t.ifMatch)&&(null===(r=e.conditions)||void 0===r?void 0:r.ifMatch)!==Gi||(null===(i=e.conditions)||void 0===i?void 0:i.ifNoneMatch)&&(null===(n=e.conditions)||void 0===n?void 0:n.ifNoneMatch)!==Gi||(null===(o=e.conditions)||void 0===o?void 0:o.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return Nu.withSpan("BlobLeaseClient-renewLease",e,(async t=>{var r;return this._containerOrBlobOperation.renewLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),tracingOptions:t.tracingOptions})}))}async breakLease(e,t={}){var r,i,n,o,s;if(this._isContainer&&((null===(r=t.conditions)||void 0===r?void 0:r.ifMatch)&&(null===(i=t.conditions)||void 0===i?void 0:i.ifMatch)!==Gi||(null===(n=t.conditions)||void 0===n?void 0:n.ifNoneMatch)&&(null===(o=t.conditions)||void 0===o?void 0:o.ifNoneMatch)!==Gi||(null===(s=t.conditions)||void 0===s?void 0:s.tagConditions)))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return Nu.withSpan("BlobLeaseClient-breakLease",t,(async r=>{var i;const n={abortSignal:t.abortSignal,breakPeriod:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions};return Tn(await this._containerOrBlobOperation.breakLease(n))}))}}class Yu{get acceptRanges(){return this.originalResponse.acceptRanges}get cacheControl(){return this.originalResponse.cacheControl}get contentDisposition(){return this.originalResponse.contentDisposition}get contentEncoding(){return this.originalResponse.contentEncoding}get contentLanguage(){return this.originalResponse.contentLanguage}get blobSequenceNumber(){return this.originalResponse.blobSequenceNumber}get blobType(){return this.originalResponse.blobType}get contentLength(){return this.originalResponse.contentLength}get contentMD5(){return this.originalResponse.contentMD5}get contentRange(){return this.originalResponse.contentRange}get contentType(){return this.originalResponse.contentType}get copyCompletedOn(){}get copyId(){return this.originalResponse.copyId}get copyProgress(){return this.originalResponse.copyProgress}get copySource(){return this.originalResponse.copySource}get copyStatus(){return this.originalResponse.copyStatus}get copyStatusDescription(){return this.originalResponse.copyStatusDescription}get leaseDuration(){return this.originalResponse.leaseDuration}get leaseState(){return this.originalResponse.leaseState}get leaseStatus(){return this.originalResponse.leaseStatus}get date(){return this.originalResponse.date}get blobCommittedBlockCount(){return this.originalResponse.blobCommittedBlockCount}get etag(){return this.originalResponse.etag}get errorCode(){return this.originalResponse.errorCode}get isServerEncrypted(){return this.originalResponse.isServerEncrypted}get blobContentMD5(){return this.originalResponse.blobContentMD5}get lastModified(){return this.originalResponse.lastModified}get metadata(){return this.originalResponse.metadata}get requestId(){return this.originalResponse.requestId}get clientRequestId(){return this.originalResponse.clientRequestId}get version(){return this.originalResponse.version}get encryptionKeySha256(){return this.originalResponse.encryptionKeySha256}get contentCrc64(){return this.originalResponse.contentCrc64}get blobBody(){throw Error("Quick query in browser is not supported yet.")}get readableStreamBody(){}get _response(){return this.originalResponse._response}constructor(e,t={}){this.originalResponse=e}}var Qu,Zu,Xu;function ep(e){if(void 0!==e)return e}function tp(e,t){if(e&&!t)throw new RangeError("Customer-provided encryption key must be used over HTTPS.");e&&!e.encryptionAlgorithm&&(e.encryptionAlgorithm="AES256")}function rp(e){const t=(e._response.parsedBody.pageRange||[]).map((e=>({offset:e.start,count:e.end-e.start}))),r=(e._response.parsedBody.clearRange||[]).map((e=>({offset:e.start,count:e.end-e.start})));return Object.assign(Object.assign({},e),{pageRange:t,clearRange:r,_response:Object.assign(Object.assign({},e._response),{parsedBody:{pageRange:t,clearRange:r}})})}!function(e){e.Hot="Hot",e.Cool="Cool",e.Cold="Cold",e.Archive="Archive"}(Qu||(Qu={})),function(e){e.P4="P4",e.P6="P6",e.P10="P10",e.P15="P15",e.P20="P20",e.P30="P30",e.P40="P40",e.P50="P50",e.P60="P60",e.P70="P70",e.P80="P80"}(Zu||(Zu={})),function(e){e.StorageOAuthScopes="https://storage.azure.com/.default",e.DiskComputeOAuthScopes="https://disk.compute.azure.com/.default"}(Xu||(Xu={}));ze("core-lro");class ip extends Error{constructor(e){super(e),this.name="PollerStoppedError",Object.setPrototypeOf(this,ip.prototype)}}class np extends Error{constructor(e){super(e),this.name="PollerCancelledError",Object.setPrototypeOf(this,np.prototype)}}class op{constructor(e){this.resolveOnUnsuccessful=!1,this.stopped=!0,this.pollProgressCallbacks=[],this.operation=e,this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t})),this.promise.catch((()=>{}))}async startPolling(e={}){for(this.stopped&&(this.stopped=!1);!this.isStopped()&&!this.isDone();)await this.poll(e),await this.delay()}async pollOnce(e={}){this.isDone()||(this.operation=await this.operation.update({abortSignal:e.abortSignal,fireProgress:this.fireProgress.bind(this)})),this.processUpdatedState()}fireProgress(e){for(const t of this.pollProgressCallbacks)t(e)}async cancelOnce(e={}){this.operation=await this.operation.cancel(e)}poll(e={}){if(!this.pollOncePromise){this.pollOncePromise=this.pollOnce(e);const t=()=>{this.pollOncePromise=void 0};this.pollOncePromise.then(t,t).catch(this.reject)}return this.pollOncePromise}processUpdatedState(){if(this.operation.state.error&&(this.stopped=!0,!this.resolveOnUnsuccessful))throw this.reject(this.operation.state.error),this.operation.state.error;if(this.operation.state.isCancelled&&(this.stopped=!0,!this.resolveOnUnsuccessful)){const e=new np("Operation was canceled");throw this.reject(e),e}this.isDone()&&this.resolve&&this.resolve(this.getResult())}async pollUntilDone(e={}){return this.stopped&&this.startPolling(e).catch(this.reject),this.processUpdatedState(),this.promise}onProgress(e){return this.pollProgressCallbacks.push(e),()=>{this.pollProgressCallbacks=this.pollProgressCallbacks.filter((t=>t!==e))}}isDone(){const e=this.operation.state;return Boolean(e.isCompleted||e.isCancelled||e.error)}stopPolling(){this.stopped||(this.stopped=!0,this.reject&&this.reject(new ip("This poller is already stopped")))}isStopped(){return this.stopped}cancelOperation(e={}){if(this.cancelPromise){if(e.abortSignal)throw new Error("A cancel request is currently pending")}else this.cancelPromise=this.cancelOnce(e);return this.cancelPromise}getOperationState(){return this.operation.state}getResult(){return this.operation.state.result}toString(){return this.operation.toString()}}class sp extends op{constructor(e){const{blobClient:t,copySource:r,intervalInMs:i=15e3,onProgress:n,resumeFrom:o,startCopyFromURLOptions:s}=e;let a;o&&(a=JSON.parse(o).state);super(cp(Object.assign(Object.assign({},a),{blobClient:t,copySource:r,startCopyFromURLOptions:s}))),"function"==typeof n&&this.onProgress(n),this.intervalInMs=i}delay(){return $e(this.intervalInMs)}}const ap=async function(e={}){const t=this.state,{copyId:r}=t;return t.isCompleted?cp(t):r?(await t.blobClient.abortCopyFromURL(r,{abortSignal:e.abortSignal}),t.isCancelled=!0,cp(t)):(t.isCancelled=!0,cp(t))},lp=async function(e={}){const t=this.state,{blobClient:r,copySource:i,startCopyFromURLOptions:n}=t;if(t.isStarted){if(!t.isCompleted)try{const r=await t.blobClient.getProperties({abortSignal:e.abortSignal}),{copyStatus:i,copyProgress:n}=r,o=t.copyProgress;n&&(t.copyProgress=n),"pending"===i&&n!==o&&"function"==typeof e.fireProgress?e.fireProgress(t):"success"===i?(t.result=r,t.isCompleted=!0):"failed"===i&&(t.error=new Error(`Blob copy failed with reason: "${r.copyStatusDescription||"unknown"}"`),t.isCompleted=!0)}catch(e){t.error=e,t.isCompleted=!0}}else{t.isStarted=!0;const e=await r.startCopyFromURL(i,n);t.copyId=e.copyId,"success"===e.copyStatus&&(t.result=e,t.isCompleted=!0)}return cp(t)},dp=function(){return JSON.stringify({state:this.state},((e,t)=>{if("blobClient"!==e)return t}))};function cp(e){return{state:Object.assign({},e),cancel:ap,toString:dp,update:lp}}function up(e){if(e.offset<0)throw new RangeError("Range.offset cannot be smaller than 0.");if(e.count&&e.count<=0)throw new RangeError("Range.count must be larger than 0. Leave it undefined if you want a range from offset to the end.");return e.count?`bytes=${e.offset}-${e.offset+e.count-1}`:`bytes=${e.offset}-`}var pp,hp=__webpack_require__(37007);!function(e){e[e.Good=0]="Good",e[e.Error=1]="Error"}(pp||(pp={}));class fp{constructor(e=5){if(this.actives=0,this.completed=0,this.offset=0,this.operations=[],this.state=pp.Good,e<1)throw new RangeError("concurrency must be larger than 0");this.concurrency=e,this.emitter=new hp.EventEmitter}addOperation(e){this.operations.push((async()=>{try{this.actives++,await e(),this.actives--,this.completed++,this.parallelExecute()}catch(e){this.emitter.emit("error",e)}}))}async do(){return 0===this.operations.length?Promise.resolve():(this.parallelExecute(),new Promise(((e,t)=>{this.emitter.on("finish",e),this.emitter.on("error",(e=>{this.state=pp.Error,t(e)}))})))}nextOperation(){return this.offset=this.operations.length)this.emitter.emit("finish");else for(;this.actives{var n;const o=Tn(await this.blobContext.download({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),requestOptions:{onDownloadProgress:ot?void 0:r.onProgress},range:0!==e||t?up({offset:e,count:t}):void 0,rangeGetContentMD5:r.rangeGetContentMD5,rangeGetContentCRC64:r.rangeGetContentCrc64,snapshot:r.snapshot,cpkInfo:r.customerProvidedKey,tracingOptions:i.tracingOptions})),s=Object.assign(Object.assign({},o),{_response:o._response,objectReplicationDestinationPolicyId:o.objectReplicationPolicyId,objectReplicationSourceProperties:wn(o.objectReplicationRules)});if(!ot)return s;if((void 0===r.maxRetryRequests||r.maxRetryRequests<0)&&(r.maxRetryRequests=5),void 0===o.contentLength)throw new RangeError("File download response doesn't contain valid content length header");if(!o.etag)throw new RangeError("File download response doesn't contain valid etag header");return new 1(s,(async t=>{var i;const n={leaseAccessConditions:r.conditions,modifiedAccessConditions:{ifMatch:r.conditions.ifMatch||o.etag,ifModifiedSince:r.conditions.ifModifiedSince,ifNoneMatch:r.conditions.ifNoneMatch,ifUnmodifiedSince:r.conditions.ifUnmodifiedSince,ifTags:null===(i=r.conditions)||void 0===i?void 0:i.tagConditions},range:up({count:e+o.contentLength-t,offset:t}),rangeGetContentMD5:r.rangeGetContentMD5,rangeGetContentCRC64:r.rangeGetContentCrc64,snapshot:r.snapshot,cpkInfo:r.customerProvidedKey};return(await this.blobContext.download(Object.assign({abortSignal:r.abortSignal},n))).readableStreamBody}),e,o.contentLength,{maxRetryRequests:r.maxRetryRequests,onProgress:r.onProgress})}))}async exists(e={}){return Nu.withSpan("BlobClient-exists",e,(async t=>{try{return tp(e.customerProvidedKey,this.isHttps),await this.getProperties({abortSignal:e.abortSignal,customerProvidedKey:e.customerProvidedKey,conditions:e.conditions,tracingOptions:t.tracingOptions}),!0}catch(e){if(404===e.statusCode)return!1;if(409===e.statusCode&&("BlobUsesCustomerSpecifiedEncryption"===e.details.errorCode||"BlobDoesNotUseCustomerSpecifiedEncryption"===e.details.errorCode))return!0;throw e}}))}async getProperties(e={}){return e.conditions=e.conditions||{},tp(e.customerProvidedKey,this.isHttps),Nu.withSpan("BlobClient-getProperties",e,(async t=>{var r;const i=Tn(await this.blobContext.getProperties({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),cpkInfo:e.customerProvidedKey,tracingOptions:t.tracingOptions}));return Object.assign(Object.assign({},i),{_response:i._response,objectReplicationDestinationPolicyId:i.objectReplicationPolicyId,objectReplicationSourceProperties:wn(i.objectReplicationRules)})}))}async delete(e={}){return e.conditions=e.conditions||{},Nu.withSpan("BlobClient-delete",e,(async t=>{var r;return Tn(await this.blobContext.delete({abortSignal:e.abortSignal,deleteSnapshots:e.deleteSnapshots,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),tracingOptions:t.tracingOptions}))}))}async deleteIfExists(e={}){return Nu.withSpan("BlobClient-deleteIfExists",e,(async e=>{var t,r;try{const t=Tn(await this.delete(e));return Object.assign(Object.assign({succeeded:!0},t),{_response:t._response})}catch(e){if("BlobNotFound"===(null===(t=e.details)||void 0===t?void 0:t.errorCode))return Object.assign(Object.assign({succeeded:!1},null===(r=e.response)||void 0===r?void 0:r.parsedHeaders),{_response:e.response});throw e}}))}async undelete(e={}){return Nu.withSpan("BlobClient-undelete",e,(async t=>Tn(await this.blobContext.undelete({abortSignal:e.abortSignal,tracingOptions:t.tracingOptions}))))}async setHTTPHeaders(e,t={}){return t.conditions=t.conditions||{},tp(t.customerProvidedKey,this.isHttps),Nu.withSpan("BlobClient-setHTTPHeaders",t,(async r=>{var i;return Tn(await this.blobContext.setHttpHeaders({abortSignal:t.abortSignal,blobHttpHeaders:e,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions}))}))}async setMetadata(e,t={}){return t.conditions=t.conditions||{},tp(t.customerProvidedKey,this.isHttps),Nu.withSpan("BlobClient-setMetadata",t,(async r=>{var i;return Tn(await this.blobContext.setMetadata({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope,tracingOptions:r.tracingOptions}))}))}async setTags(e,t={}){return Nu.withSpan("BlobClient-setTags",t,(async r=>{var i;return Tn(await this.blobContext.setTags({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions,tags:yn(e)}))}))}async getTags(e={}){return Nu.withSpan("BlobClient-getTags",e,(async t=>{var r;const i=Tn(await this.blobContext.getTags({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),tracingOptions:t.tracingOptions}));return Object.assign(Object.assign({},i),{_response:i._response,tags:vn({blobTagSet:i.blobTagSet})||{}})}))}getBlobLeaseClient(e){return new Ju(this,e)}async createSnapshot(e={}){return e.conditions=e.conditions||{},tp(e.customerProvidedKey,this.isHttps),Nu.withSpan("BlobClient-createSnapshot",e,(async t=>{var r;return Tn(await this.blobContext.createSnapshot({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,metadata:e.metadata,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),cpkInfo:e.customerProvidedKey,encryptionScope:e.encryptionScope,tracingOptions:t.tracingOptions}))}))}async beginCopyFromURL(e,t={}){const r=new sp({blobClient:{abortCopyFromURL:(...e)=>this.abortCopyFromURL(...e),getProperties:(...e)=>this.getProperties(...e),startCopyFromURL:(...e)=>this.startCopyFromURL(...e)},copySource:e,intervalInMs:t.intervalInMs,onProgress:t.onProgress,resumeFrom:t.resumeFrom,startCopyFromURLOptions:t});return await r.poll(),r}async abortCopyFromURL(e,t={}){return Nu.withSpan("BlobClient-abortCopyFromURL",t,(async r=>Tn(await this.blobContext.abortCopyFromURL(e,{abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,tracingOptions:r.tracingOptions}))))}async syncCopyFromURL(e,t={}){return t.conditions=t.conditions||{},t.sourceConditions=t.sourceConditions||{},Nu.withSpan("BlobClient-syncCopyFromURL",t,(async r=>{var i,n,o,s,a,l,d;return Tn(await this.blobContext.copyFromURL(e,{abortSignal:t.abortSignal,metadata:t.metadata,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:null===(n=t.sourceConditions)||void 0===n?void 0:n.ifMatch,sourceIfModifiedSince:null===(o=t.sourceConditions)||void 0===o?void 0:o.ifModifiedSince,sourceIfNoneMatch:null===(s=t.sourceConditions)||void 0===s?void 0:s.ifNoneMatch,sourceIfUnmodifiedSince:null===(a=t.sourceConditions)||void 0===a?void 0:a.ifUnmodifiedSince},sourceContentMD5:t.sourceContentMD5,copySourceAuthorization:_n(t.sourceAuthorization),tier:ep(t.tier),blobTagsString:gn(t.tags),immutabilityPolicyExpiry:null===(l=t.immutabilityPolicy)||void 0===l?void 0:l.expiriesOn,immutabilityPolicyMode:null===(d=t.immutabilityPolicy)||void 0===d?void 0:d.policyMode,legalHold:t.legalHold,encryptionScope:t.encryptionScope,copySourceTags:t.copySourceTags,tracingOptions:r.tracingOptions}))}))}async setAccessTier(e,t={}){return Nu.withSpan("BlobClient-setAccessTier",t,(async r=>{var i;return Tn(await this.blobContext.setTier(ep(e),{abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),rehydratePriority:t.rehydratePriority,tracingOptions:r.tracingOptions}))}))}async downloadToBuffer(e,t,r,i={}){var n;let o,s=0,a=0,l=i;e instanceof gp?(o=e,s=t||0,a="number"==typeof r?r:0):(s="number"==typeof e?e:0,a="number"==typeof t?t:0,l=r||{});let d=null!==(n=l.blockSize)&&void 0!==n?n:0;if(d<0)throw new RangeError("blockSize option must be >= 0");if(0===d&&(d=Ri),s<0)throw new RangeError("offset option must be >= 0");if(a&&a<=0)throw new RangeError("count option must be greater than 0");return l.conditions||(l.conditions={}),Nu.withSpan("BlobClient-downloadToBuffer",l,(async e=>{if(!a){const t=await this.getProperties(Object.assign(Object.assign({},l),{tracingOptions:e.tracingOptions}));if(a=t.contentLength-s,a<0)throw new RangeError(`offset ${s} shouldn't be larger than blob size ${t.contentLength}`)}if(!o)try{o=gp.alloc(a)}catch(e){throw new Error(`Unable to allocate the buffer of size: ${a}(in bytes). Please try passing your own buffer to the "downloadToBuffer" method or try using other methods like "download" or "downloadToFile".\t ${e.message}`)}if(o.length{let r=s+a;i+d{const n=await this.download(t,r,Object.assign(Object.assign({},i),{tracingOptions:e.tracingOptions}));return n.readableStreamBody&&await void n.readableStreamBody,n.blobDownloadStream=void 0,n}))}getBlobAndContainerNamesFromUrl(){let e,t;try{const r=new URL(this.url);if("blob"===r.host.split(".")[1]){const i=r.pathname.match("/([^/]*)(/(.*))?");e=i[1],t=i[3]}else if(mn(r)){const i=r.pathname.match("/([^/]*)/([^/]*)(/(.*))?");e=i[2],t=i[4]}else{const i=r.pathname.match("/([^/]*)(/(.*))?");e=i[1],t=i[3]}if(e=decodeURIComponent(e),t=decodeURIComponent(t),t=t.replace(/\\/g,"/"),!e)throw new Error("Provided containerName is invalid.");return{blobName:t,containerName:e}}catch(e){throw new Error("Unable to extract blobName and containerName with provided information.")}}async startCopyFromURL(e,t={}){return Nu.withSpan("BlobClient-startCopyFromURL",t,(async r=>{var i,n,o;return t.conditions=t.conditions||{},t.sourceConditions=t.sourceConditions||{},Tn(await this.blobContext.startCopyFromURL(e,{abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:t.sourceConditions.ifMatch,sourceIfModifiedSince:t.sourceConditions.ifModifiedSince,sourceIfNoneMatch:t.sourceConditions.ifNoneMatch,sourceIfUnmodifiedSince:t.sourceConditions.ifUnmodifiedSince,sourceIfTags:t.sourceConditions.tagConditions},immutabilityPolicyExpiry:null===(n=t.immutabilityPolicy)||void 0===n?void 0:n.expiriesOn,immutabilityPolicyMode:null===(o=t.immutabilityPolicy)||void 0===o?void 0:o.policyMode,legalHold:t.legalHold,rehydratePriority:t.rehydratePriority,tier:ep(t.tier),blobTagsString:gn(t.tags),sealBlob:t.sealBlob,tracingOptions:r.tracingOptions}))}))}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof mr))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");const r=Gu(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).toString();t(dn(this.url,r))}))}generateSasStringToSign(e){if(!(this.credential instanceof mr))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");return Wu(Object.assign({containerName:this._containerName,blobName:this._name,snapshotTime:this._snapshot,versionId:this._versionId},e),this.credential).stringToSign}async deleteImmutabilityPolicy(e={}){return Nu.withSpan("BlobClient-deleteImmutabilityPolicy",e,(async e=>Tn(await this.blobContext.deleteImmutabilityPolicy({tracingOptions:e.tracingOptions}))))}async setImmutabilityPolicy(e,t={}){return Nu.withSpan("BlobClient-setImmutabilityPolicy",t,(async t=>Tn(await this.blobContext.setImmutabilityPolicy({immutabilityPolicyExpiry:e.expiriesOn,immutabilityPolicyMode:e.policyMode,tracingOptions:t.tracingOptions}))))}async setLegalHold(e,t={}){return Nu.withSpan("BlobClient-setLegalHold",t,(async t=>Tn(await this.blobContext.setLegalHold(e,{tracingOptions:t.tracingOptions}))))}async getAccountInfo(e={}){return Nu.withSpan("BlobClient-getAccountInfo",e,(async t=>Tn(await this.blobContext.getAccountInfo({abortSignal:e.abortSignal,tracingOptions:t.tracingOptions}))))}}class vp extends yp{constructor(e,t,r,i){let n,o;if(i=i||{},Nn(t))o=e,n=t;else if(ot&&t instanceof mr||t instanceof fr||dr(t))o=e,n=Un(t,i=r);else if(t||"string"==typeof t){if(!t||"string"!=typeof t||!r||"string"!=typeof r)throw new Error("Expecting non-empty strings for containerName and blobName parameters");{const s=t,a=r,l=tn(e);if("AccountConnString"===l.kind){if(!ot)throw new Error("Account connection string is only supported in Node.js environment");{const e=new mr(l.accountName,l.accountKey);o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a)),i.proxyOptions||(i.proxyOptions=Lt(l.proxyUri)),n=Un(e,i)}}else{if("SASConnString"!==l.kind)throw new Error("Connection string must be either an Account connection string or a SAS connection string");o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a))+"?"+l.accountSas,n=Un(new fr,i)}}}else o=e,n=Un(new fr,i);super(o,n),this.appendBlobContext=this.storageClientContext.appendBlob}withSnapshot(e){return new vp(nn(this.url,Oi.SNAPSHOT,0===e.length?void 0:e),this.pipeline)}async create(e={}){return e.conditions=e.conditions||{},tp(e.customerProvidedKey,this.isHttps),Nu.withSpan("AppendBlobClient-create",e,(async t=>{var r,i,n;return Tn(await this.appendBlobContext.create(0,{abortSignal:e.abortSignal,blobHttpHeaders:e.blobHTTPHeaders,leaseAccessConditions:e.conditions,metadata:e.metadata,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),cpkInfo:e.customerProvidedKey,encryptionScope:e.encryptionScope,immutabilityPolicyExpiry:null===(i=e.immutabilityPolicy)||void 0===i?void 0:i.expiriesOn,immutabilityPolicyMode:null===(n=e.immutabilityPolicy)||void 0===n?void 0:n.policyMode,legalHold:e.legalHold,blobTagsString:gn(e.tags),tracingOptions:t.tracingOptions}))}))}async createIfNotExists(e={}){const t={ifNoneMatch:"*"};return Nu.withSpan("AppendBlobClient-createIfNotExists",e,(async e=>{var r,i;try{const r=Tn(await this.create(Object.assign(Object.assign({},e),{conditions:t})));return Object.assign(Object.assign({succeeded:!0},r),{_response:r._response})}catch(e){if("BlobAlreadyExists"===(null===(r=e.details)||void 0===r?void 0:r.errorCode))return Object.assign(Object.assign({succeeded:!1},null===(i=e.response)||void 0===i?void 0:i.parsedHeaders),{_response:e.response});throw e}}))}async seal(e={}){return e.conditions=e.conditions||{},Nu.withSpan("AppendBlobClient-seal",e,(async t=>{var r;return Tn(await this.appendBlobContext.seal({abortSignal:e.abortSignal,appendPositionAccessConditions:e.conditions,leaseAccessConditions:e.conditions,modifiedAccessConditions:Object.assign(Object.assign({},e.conditions),{ifTags:null===(r=e.conditions)||void 0===r?void 0:r.tagConditions}),tracingOptions:t.tracingOptions}))}))}async appendBlock(e,t,r={}){return r.conditions=r.conditions||{},tp(r.customerProvidedKey,this.isHttps),Nu.withSpan("AppendBlobClient-appendBlock",r,(async i=>{var n;return Tn(await this.appendBlobContext.appendBlock(t,e,{abortSignal:r.abortSignal,appendPositionAccessConditions:r.conditions,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},transactionalContentMD5:r.transactionalContentMD5,transactionalContentCrc64:r.transactionalContentCrc64,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope,tracingOptions:i.tracingOptions}))}))}async appendBlockFromURL(e,t,r,i={}){return i.conditions=i.conditions||{},i.sourceConditions=i.sourceConditions||{},tp(i.customerProvidedKey,this.isHttps),Nu.withSpan("AppendBlobClient-appendBlockFromURL",i,(async n=>{var o,s,a,l,d;return Tn(await this.appendBlobContext.appendBlockFromUrl(e,0,{abortSignal:i.abortSignal,sourceRange:up({offset:t,count:r}),sourceContentMD5:i.sourceContentMD5,sourceContentCrc64:i.sourceContentCrc64,leaseAccessConditions:i.conditions,appendPositionAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:null===(o=i.conditions)||void 0===o?void 0:o.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:null===(s=i.sourceConditions)||void 0===s?void 0:s.ifMatch,sourceIfModifiedSince:null===(a=i.sourceConditions)||void 0===a?void 0:a.ifModifiedSince,sourceIfNoneMatch:null===(l=i.sourceConditions)||void 0===l?void 0:l.ifNoneMatch,sourceIfUnmodifiedSince:null===(d=i.sourceConditions)||void 0===d?void 0:d.ifUnmodifiedSince},copySourceAuthorization:_n(i.sourceAuthorization),cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,tracingOptions:n.tracingOptions}))}))}}class bp extends yp{constructor(e,t,r,i){let n,o;if(i=i||{},Nn(t))o=e,n=t;else if(ot&&t instanceof mr||t instanceof fr||dr(t))o=e,n=Un(t,i=r);else if(t||"string"==typeof t){if(!t||"string"!=typeof t||!r||"string"!=typeof r)throw new Error("Expecting non-empty strings for containerName and blobName parameters");{const s=t,a=r,l=tn(e);if("AccountConnString"===l.kind){if(!ot)throw new Error("Account connection string is only supported in Node.js environment");{const e=new mr(l.accountName,l.accountKey);o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a)),i.proxyOptions||(i.proxyOptions=Lt(l.proxyUri)),n=Un(e,i)}}else{if("SASConnString"!==l.kind)throw new Error("Connection string must be either an Account connection string or a SAS connection string");o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a))+"?"+l.accountSas,n=Un(new fr,i)}}}else o=e,r&&"string"!=typeof r&&(i=r),n=Un(new fr,i);super(o,n),this.blockBlobContext=this.storageClientContext.blockBlob,this._blobContext=this.storageClientContext.blob}withSnapshot(e){return new bp(nn(this.url,Oi.SNAPSHOT,0===e.length?void 0:e),this.pipeline)}async query(e,t={}){if(tp(t.customerProvidedKey,this.isHttps),!ot)throw new Error("This operation currently is only supported in Node.js.");return Nu.withSpan("BlockBlobClient-query",t,(async r=>{var i;const n=Tn(await this._blobContext.query({abortSignal:t.abortSignal,queryRequest:{queryType:"SQL",expression:e,inputSerialization:bn(t.inputTextConfiguration),outputSerialization:bn(t.outputTextConfiguration)},leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),cpkInfo:t.customerProvidedKey,tracingOptions:r.tracingOptions}));return new Yu(n,{abortSignal:t.abortSignal,onProgress:t.onProgress,onError:t.onError})}))}async upload(e,t,r={}){return r.conditions=r.conditions||{},tp(r.customerProvidedKey,this.isHttps),Nu.withSpan("BlockBlobClient-upload",r,(async i=>{var n,o,s;return Tn(await this.blockBlobContext.upload(t,e,{abortSignal:r.abortSignal,blobHttpHeaders:r.blobHTTPHeaders,leaseAccessConditions:r.conditions,metadata:r.metadata,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),requestOptions:{onUploadProgress:r.onProgress},cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope,immutabilityPolicyExpiry:null===(o=r.immutabilityPolicy)||void 0===o?void 0:o.expiriesOn,immutabilityPolicyMode:null===(s=r.immutabilityPolicy)||void 0===s?void 0:s.policyMode,legalHold:r.legalHold,tier:ep(r.tier),blobTagsString:gn(r.tags),tracingOptions:i.tracingOptions}))}))}async syncUploadFromURL(e,t={}){return t.conditions=t.conditions||{},tp(t.customerProvidedKey,this.isHttps),Nu.withSpan("BlockBlobClient-syncUploadFromURL",t,(async r=>{var i,n,o,s,a,l;return Tn(await this.blockBlobContext.putBlobFromUrl(0,e,Object.assign(Object.assign({},t),{blobHttpHeaders:t.blobHTTPHeaders,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:null===(n=t.sourceConditions)||void 0===n?void 0:n.ifMatch,sourceIfModifiedSince:null===(o=t.sourceConditions)||void 0===o?void 0:o.ifModifiedSince,sourceIfNoneMatch:null===(s=t.sourceConditions)||void 0===s?void 0:s.ifNoneMatch,sourceIfUnmodifiedSince:null===(a=t.sourceConditions)||void 0===a?void 0:a.ifUnmodifiedSince,sourceIfTags:null===(l=t.sourceConditions)||void 0===l?void 0:l.tagConditions},cpkInfo:t.customerProvidedKey,copySourceAuthorization:_n(t.sourceAuthorization),tier:ep(t.tier),blobTagsString:gn(t.tags),copySourceTags:t.copySourceTags,tracingOptions:r.tracingOptions})))}))}async stageBlock(e,t,r,i={}){return tp(i.customerProvidedKey,this.isHttps),Nu.withSpan("BlockBlobClient-stageBlock",i,(async n=>Tn(await this.blockBlobContext.stageBlock(e,r,t,{abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,requestOptions:{onUploadProgress:i.onProgress},transactionalContentMD5:i.transactionalContentMD5,transactionalContentCrc64:i.transactionalContentCrc64,cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,tracingOptions:n.tracingOptions}))))}async stageBlockFromURL(e,t,r=0,i,n={}){return tp(n.customerProvidedKey,this.isHttps),Nu.withSpan("BlockBlobClient-stageBlockFromURL",n,(async o=>Tn(await this.blockBlobContext.stageBlockFromURL(e,0,t,{abortSignal:n.abortSignal,leaseAccessConditions:n.conditions,sourceContentMD5:n.sourceContentMD5,sourceContentCrc64:n.sourceContentCrc64,sourceRange:0!==r||i?up({offset:r,count:i}):void 0,cpkInfo:n.customerProvidedKey,encryptionScope:n.encryptionScope,copySourceAuthorization:_n(n.sourceAuthorization),tracingOptions:o.tracingOptions}))))}async commitBlockList(e,t={}){return t.conditions=t.conditions||{},tp(t.customerProvidedKey,this.isHttps),Nu.withSpan("BlockBlobClient-commitBlockList",t,(async r=>{var i,n,o;return Tn(await this.blockBlobContext.commitBlockList({latest:e},{abortSignal:t.abortSignal,blobHttpHeaders:t.blobHTTPHeaders,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope,immutabilityPolicyExpiry:null===(n=t.immutabilityPolicy)||void 0===n?void 0:n.expiriesOn,immutabilityPolicyMode:null===(o=t.immutabilityPolicy)||void 0===o?void 0:o.policyMode,legalHold:t.legalHold,tier:ep(t.tier),blobTagsString:gn(t.tags),tracingOptions:r.tracingOptions}))}))}async getBlockList(e,t={}){return Nu.withSpan("BlockBlobClient-getBlockList",t,(async r=>{var i;const n=Tn(await this.blockBlobContext.getBlockList(e,{abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions}));return n.committedBlocks||(n.committedBlocks=[]),n.uncommittedBlocks||(n.uncommittedBlocks=[]),n}))}async uploadData(e,t={}){return Nu.withSpan("BlockBlobClient-uploadData",t,(async t=>{if(ot){let r;return r=e instanceof gp?e:e instanceof ArrayBuffer?gp.from(e):gp.from(e.buffer,e.byteOffset,e.byteLength),this.uploadSeekableInternal(((e,t)=>r.slice(e,e+t)),r.byteLength,t)}{const r=new Blob([e]);return this.uploadSeekableInternal(((e,t)=>r.slice(e,e+t)),r.size,t)}}))}async uploadBrowserData(e,t={}){return Nu.withSpan("BlockBlobClient-uploadBrowserData",t,(async t=>{const r=new Blob([e]);return this.uploadSeekableInternal(((e,t)=>r.slice(e,e+t)),r.size,t)}))}async uploadSeekableInternal(e,t,r={}){var i,n;let o=null!==(i=r.blockSize)&&void 0!==i?i:0;if(o<0||o>Mi)throw new RangeError("blockSize option must be >= 0 and <= 4194304000");const s=null!==(n=r.maxSingleShotSize)&&void 0!==n?n:Fi;if(s<0||s>Fi)throw new RangeError("maxSingleShotSize option must be >= 0 and <= 268435456");if(0===o){if(t>2097152e8)throw new RangeError(`${t} is too larger to upload to a block blob.`);t>s&&(o=Math.ceil(t/Di),o{if(t<=s)return Tn(await this.upload(e(0,t),t,i));const n=Math.floor((t-1)/o)+1;if(n>Di)throw new RangeError("The buffer's size is too big or the BlockSize is too small;the number of blocks must be <= 50000");const a=[],l=et();let d=0;const c=new fp(r.concurrency);for(let s=0;s{const c=un(l,s),u=o*s,p=(s===n-1?t:u+o)-u;a.push(c),await this.stageBlock(c,e(u,p),p,{abortSignal:r.abortSignal,conditions:r.conditions,encryptionScope:r.encryptionScope,tracingOptions:i.tracingOptions}),d+=p,r.onProgress&&r.onProgress({loadedBytes:d})}));return await c.do(),this.commitBlockList(a,i)}))}async uploadFile(e,t={}){return Nu.withSpan("BlockBlobClient-uploadFile",t,(async e=>{const r=(await void 0).size;return this.uploadSeekableInternal(((e,t)=>()=>{}),r,Object.assign(Object.assign({},t),{tracingOptions:e.tracingOptions}))}))}async uploadStream(e,t=8388608,r=5,i={}){return i.blobHTTPHeaders||(i.blobHTTPHeaders={}),i.conditions||(i.conditions={}),Nu.withSpan("BlockBlobClient-uploadStream",i,(async n=>{let o=0;const s=et();let a=0;const l=[],d=new mp(e,t,r,(async(e,t)=>{const r=un(s,o);l.push(r),o++,await this.stageBlock(r,e,t,{customerProvidedKey:i.customerProvidedKey,conditions:i.conditions,encryptionScope:i.encryptionScope,tracingOptions:n.tracingOptions}),a+=t,i.onProgress&&i.onProgress({loadedBytes:a})}),Math.ceil(r/4*3));return await d.do(),Tn(await this.commitBlockList(l,Object.assign(Object.assign({},i),{tracingOptions:n.tracingOptions})))}))}}class wp extends yp{constructor(e,t,r,i){let n,o;if(i=i||{},Nn(t))o=e,n=t;else if(ot&&t instanceof mr||t instanceof fr||dr(t))o=e,n=Un(t,i=r);else if(t||"string"==typeof t){if(!t||"string"!=typeof t||!r||"string"!=typeof r)throw new Error("Expecting non-empty strings for containerName and blobName parameters");{const s=t,a=r,l=tn(e);if("AccountConnString"===l.kind){if(!ot)throw new Error("Account connection string is only supported in Node.js environment");{const e=new mr(l.accountName,l.accountKey);o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a)),i.proxyOptions||(i.proxyOptions=Lt(l.proxyUri)),n=Un(e,i)}}else{if("SASConnString"!==l.kind)throw new Error("Connection string must be either an Account connection string or a SAS connection string");o=rn(rn(l.url,encodeURIComponent(s)),encodeURIComponent(a))+"?"+l.accountSas,n=Un(new fr,i)}}}else o=e,n=Un(new fr,i);super(o,n),this.pageBlobContext=this.storageClientContext.pageBlob}withSnapshot(e){return new wp(nn(this.url,Oi.SNAPSHOT,0===e.length?void 0:e),this.pipeline)}async create(e,t={}){return t.conditions=t.conditions||{},tp(t.customerProvidedKey,this.isHttps),Nu.withSpan("PageBlobClient-create",t,(async r=>{var i,n,o;return Tn(await this.pageBlobContext.create(0,e,{abortSignal:t.abortSignal,blobHttpHeaders:t.blobHTTPHeaders,blobSequenceNumber:t.blobSequenceNumber,leaseAccessConditions:t.conditions,metadata:t.metadata,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),cpkInfo:t.customerProvidedKey,encryptionScope:t.encryptionScope,immutabilityPolicyExpiry:null===(n=t.immutabilityPolicy)||void 0===n?void 0:n.expiriesOn,immutabilityPolicyMode:null===(o=t.immutabilityPolicy)||void 0===o?void 0:o.policyMode,legalHold:t.legalHold,tier:ep(t.tier),blobTagsString:gn(t.tags),tracingOptions:r.tracingOptions}))}))}async createIfNotExists(e,t={}){return Nu.withSpan("PageBlobClient-createIfNotExists",t,(async r=>{var i,n;try{const i={ifNoneMatch:"*"},n=Tn(await this.create(e,Object.assign(Object.assign({},t),{conditions:i,tracingOptions:r.tracingOptions})));return Object.assign(Object.assign({succeeded:!0},n),{_response:n._response})}catch(e){if("BlobAlreadyExists"===(null===(i=e.details)||void 0===i?void 0:i.errorCode))return Object.assign(Object.assign({succeeded:!1},null===(n=e.response)||void 0===n?void 0:n.parsedHeaders),{_response:e.response});throw e}}))}async uploadPages(e,t,r,i={}){return i.conditions=i.conditions||{},tp(i.customerProvidedKey,this.isHttps),Nu.withSpan("PageBlobClient-uploadPages",i,(async n=>{var o;return Tn(await this.pageBlobContext.uploadPages(r,e,{abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:null===(o=i.conditions)||void 0===o?void 0:o.tagConditions}),requestOptions:{onUploadProgress:i.onProgress},range:up({offset:t,count:r}),sequenceNumberAccessConditions:i.conditions,transactionalContentMD5:i.transactionalContentMD5,transactionalContentCrc64:i.transactionalContentCrc64,cpkInfo:i.customerProvidedKey,encryptionScope:i.encryptionScope,tracingOptions:n.tracingOptions}))}))}async uploadPagesFromURL(e,t,r,i,n={}){return n.conditions=n.conditions||{},n.sourceConditions=n.sourceConditions||{},tp(n.customerProvidedKey,this.isHttps),Nu.withSpan("PageBlobClient-uploadPagesFromURL",n,(async o=>{var s,a,l,d,c;return Tn(await this.pageBlobContext.uploadPagesFromURL(e,up({offset:t,count:i}),0,up({offset:r,count:i}),{abortSignal:n.abortSignal,sourceContentMD5:n.sourceContentMD5,sourceContentCrc64:n.sourceContentCrc64,leaseAccessConditions:n.conditions,sequenceNumberAccessConditions:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},n.conditions),{ifTags:null===(s=n.conditions)||void 0===s?void 0:s.tagConditions}),sourceModifiedAccessConditions:{sourceIfMatch:null===(a=n.sourceConditions)||void 0===a?void 0:a.ifMatch,sourceIfModifiedSince:null===(l=n.sourceConditions)||void 0===l?void 0:l.ifModifiedSince,sourceIfNoneMatch:null===(d=n.sourceConditions)||void 0===d?void 0:d.ifNoneMatch,sourceIfUnmodifiedSince:null===(c=n.sourceConditions)||void 0===c?void 0:c.ifUnmodifiedSince},cpkInfo:n.customerProvidedKey,encryptionScope:n.encryptionScope,copySourceAuthorization:_n(n.sourceAuthorization),tracingOptions:o.tracingOptions}))}))}async clearPages(e=0,t,r={}){return r.conditions=r.conditions||{},Nu.withSpan("PageBlobClient-clearPages",r,(async i=>{var n;return Tn(await this.pageBlobContext.clearPages(0,{abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),range:up({offset:e,count:t}),sequenceNumberAccessConditions:r.conditions,cpkInfo:r.customerProvidedKey,encryptionScope:r.encryptionScope,tracingOptions:i.tracingOptions}))}))}async getPageRanges(e=0,t,r={}){return r.conditions=r.conditions||{},Nu.withSpan("PageBlobClient-getPageRanges",r,(async i=>{var n;return rp(Tn(await this.pageBlobContext.getPageRanges({abortSignal:r.abortSignal,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),range:up({offset:e,count:t}),tracingOptions:i.tracingOptions})))}))}async listPageRangesSegment(e=0,t,r,i={}){return Nu.withSpan("PageBlobClient-getPageRangesSegment",i,(async n=>{var o;return Tn(await this.pageBlobContext.getPageRanges({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:null===(o=i.conditions)||void 0===o?void 0:o.tagConditions}),range:up({offset:e,count:t}),marker:r,maxPageSize:i.maxPageSize,tracingOptions:n.tracingOptions}))}))}listPageRangeItemSegments(){return s(this,arguments,(function*(e=0,t,r,i={}){let n;if(r||void 0===r)do{n=yield o(this.listPageRangesSegment(e,t,r,i)),r=n.continuationToken,yield yield o(yield o(n))}while(r)}))}listPageRangeItems(){return s(this,arguments,(function*(e=0,t,r={}){var i,n,s,d;try{for(var c,u=!0,p=l(this.listPageRangeItemSegments(e,t,undefined,r));!(i=(c=yield o(p.next())).done);u=!0){d=c.value,u=!1;const e=d;yield o(yield*a(l(kn(e))))}}catch(e){n={error:e}}finally{try{u||i||!(s=p.return)||(yield o(s.call(p)))}finally{if(n)throw n.error}}}))}listPageRanges(e=0,t,r={}){r.conditions=r.conditions||{};const i=this.listPageRangeItems(e,t,r);return{next:()=>i.next(),[Symbol.asyncIterator](){return this},byPage:(i={})=>this.listPageRangeItemSegments(e,t,i.continuationToken,Object.assign({maxPageSize:i.maxPageSize},r))}}async getPageRangesDiff(e,t,r,i={}){return i.conditions=i.conditions||{},Nu.withSpan("PageBlobClient-getPageRangesDiff",i,(async n=>{var o;return rp(Tn(await this.pageBlobContext.getPageRangesDiff({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:null===(o=i.conditions)||void 0===o?void 0:o.tagConditions}),prevsnapshot:r,range:up({offset:e,count:t}),tracingOptions:n.tracingOptions})))}))}async listPageRangesDiffSegment(e,t,r,i,n={}){return Nu.withSpan("PageBlobClient-getPageRangesDiffSegment",n,(async o=>{var s;return Tn(await this.pageBlobContext.getPageRangesDiff({abortSignal:null==n?void 0:n.abortSignal,leaseAccessConditions:null==n?void 0:n.conditions,modifiedAccessConditions:Object.assign(Object.assign({},null==n?void 0:n.conditions),{ifTags:null===(s=null==n?void 0:n.conditions)||void 0===s?void 0:s.tagConditions}),prevsnapshot:r,range:up({offset:e,count:t}),marker:i,maxPageSize:null==n?void 0:n.maxPageSize,tracingOptions:o.tracingOptions}))}))}listPageRangeDiffItemSegments(e,t,r,i,n){return s(this,arguments,(function*(){let s;if(i||void 0===i)do{s=yield o(this.listPageRangesDiffSegment(e,t,r,i,n)),i=s.continuationToken,yield yield o(yield o(s))}while(i)}))}listPageRangeDiffItems(e,t,r,i){return s(this,arguments,(function*(){var n,s,d,c;try{for(var u,p=!0,h=l(this.listPageRangeDiffItemSegments(e,t,r,undefined,i));!(n=(u=yield o(h.next())).done);p=!0){c=u.value,p=!1;const e=c;yield o(yield*a(l(kn(e))))}}catch(e){s={error:e}}finally{try{p||n||!(d=h.return)||(yield o(d.call(h)))}finally{if(s)throw s.error}}}))}listPageRangesDiff(e,t,r,i={}){i.conditions=i.conditions||{};const n=this.listPageRangeDiffItems(e,t,r,Object.assign({},i));return{next:()=>n.next(),[Symbol.asyncIterator](){return this},byPage:(n={})=>this.listPageRangeDiffItemSegments(e,t,r,n.continuationToken,Object.assign({maxPageSize:n.maxPageSize},i))}}async getPageRangesDiffForManagedDisks(e,t,r,i={}){return i.conditions=i.conditions||{},Nu.withSpan("PageBlobClient-GetPageRangesDiffForManagedDisks",i,(async n=>{var o;return rp(Tn(await this.pageBlobContext.getPageRangesDiff({abortSignal:i.abortSignal,leaseAccessConditions:i.conditions,modifiedAccessConditions:Object.assign(Object.assign({},i.conditions),{ifTags:null===(o=i.conditions)||void 0===o?void 0:o.tagConditions}),prevSnapshotUrl:r,range:up({offset:e,count:t}),tracingOptions:n.tracingOptions})))}))}async resize(e,t={}){return t.conditions=t.conditions||{},Nu.withSpan("PageBlobClient-resize",t,(async r=>{var i;return Tn(await this.pageBlobContext.resize(e,{abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),encryptionScope:t.encryptionScope,tracingOptions:r.tracingOptions}))}))}async updateSequenceNumber(e,t,r={}){return r.conditions=r.conditions||{},Nu.withSpan("PageBlobClient-updateSequenceNumber",r,(async i=>{var n;return Tn(await this.pageBlobContext.updateSequenceNumber(e,{abortSignal:r.abortSignal,blobSequenceNumber:t,leaseAccessConditions:r.conditions,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:null===(n=r.conditions)||void 0===n?void 0:n.tagConditions}),tracingOptions:i.tracingOptions}))}))}async startCopyIncremental(e,t={}){return Nu.withSpan("PageBlobClient-startCopyIncremental",t,(async r=>{var i;return Tn(await this.pageBlobContext.copyIncremental(e,{abortSignal:t.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},t.conditions),{ifTags:null===(i=t.conditions)||void 0===i?void 0:i.tagConditions}),tracingOptions:r.tracingOptions}))}))}}async function _p(e){return async function(e){const t=new FileReader;return new Promise(((r,i)=>{t.onloadend=e=>{r(e.target.result)},t.onerror=i,t.readAsText(e)}))}(await e.blobBody)}const xp=": ";class Sp{constructor(e,t){if(!e||!e.contentType)throw new RangeError("batchResponse is malformed or doesn't contain valid content-type.");if(!t||0===t.size)throw new RangeError("Invalid state: subRequests is not provided or size is 0.");this.batchResponse=e,this.subRequests=t,this.responseBatchBoundary=this.batchResponse.contentType.split("=")[1],this.perResponsePrefix=`--${this.responseBatchBoundary}${Wi}`,this.batchResponseEnding=`--${this.responseBatchBoundary}--`}async parseBatchResponse(){if(this.batchResponse._response.status!==zi)throw new Error(`Invalid state: batch request failed with status: '${this.batchResponse._response.status}'.`);const e=(await _p(this.batchResponse)).split(this.batchResponseEnding)[0].split(this.perResponsePrefix).slice(1),t=e.length;if(t!==this.subRequests.size&&1!==t)throw new Error("Invalid state: sub responses' count is not equal to sub requests' count.");const r=new Array(t);let i=0,n=0;for(let o=0;o=0&&u{void 0===this.keys[e]||this.keys[e]===kp.UNLOCKED?(this.keys[e]=kp.LOCKED,t()):this.onUnlockEvent(e,(()=>{this.keys[e]=kp.LOCKED,t()}))}))}static async unlock(e){return new Promise((t=>{this.keys[e]===kp.LOCKED&&this.emitUnlockEvent(e),delete this.keys[e],t()}))}static onUnlockEvent(e,t){void 0===this.listeners[e]?this.listeners[e]=[t]:this.listeners[e].push(t)}static emitUnlockEvent(e){if(void 0!==this.listeners[e]&&this.listeners[e].length>0){const t=this.listeners[e].shift();setImmediate((()=>{t.call(this)}))}}}Ep.keys={},Ep.listeners={};class Tp{constructor(){this.batch="batch",this.batchRequest=new Bp}getMultiPartContentType(){return this.batchRequest.getMultipartContentType()}getHttpRequestBody(){return this.batchRequest.getHttpRequestBody()}getSubRequests(){return this.batchRequest.getSubRequests()}async addSubRequestInternal(e,t){await Ep.lock(this.batch);try{this.batchRequest.preAddSubRequest(e),await t(),this.batchRequest.postAddSubRequest(e)}finally{await Ep.unlock(this.batch)}}setBatchType(e){if(this.batchType||(this.batchType=e),this.batchType!==e)throw new RangeError(`BlobBatch only supports one operation type per batch and it already is being used for ${this.batchType} operations.`)}async deleteBlob(e,t,r){let i,n;if("string"==typeof e&&(ot&&t instanceof mr||t instanceof fr||dr(t)))i=e,n=t;else{if(!(e instanceof yp))throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.");i=e.url,n=e.credential,r=t}return r||(r={}),Nu.withSpan("BatchDeleteRequest-addSubRequest",r,(async e=>{this.setBatchType("delete"),await this.addSubRequestInternal({url:i,credential:n},(async()=>{await new yp(i,this.batchRequest.createPipeline(n)).delete(e)}))}))}async setBlobAccessTier(e,t,r,i){let n,o,s;if("string"==typeof e&&(ot&&t instanceof mr||t instanceof fr||dr(t)))n=e,o=t,s=r;else{if(!(e instanceof yp))throw new RangeError("Invalid arguments. Either url and credential, or BlobClient need be provided.");n=e.url,o=e.credential,s=t,i=r}return i||(i={}),Nu.withSpan("BatchSetTierRequest-addSubRequest",i,(async e=>{this.setBatchType("setAccessTier"),await this.addSubRequestInternal({url:n,credential:o},(async()=>{await new yp(n,this.batchRequest.createPipeline(o)).setAccessTier(s,e)}))}))}}class Bp{constructor(){this.operationCount=0,this.body="";const e=et();this.boundary=`batch_${e}`,this.subRequestPrefix=`--${this.boundary}${Wi}${Li}: application/http${Wi}${Ui}: binary`,this.multipartContentType=`multipart/mixed; boundary=${this.boundary}`,this.batchRequestEnding=`--${this.boundary}--`,this.subRequests=new Map}createPipeline(e){const t=ge();var r;t.addPolicy(Wr({stringifyXML:Ei,serializerOptions:{xml:{xmlCharKey:"#"}}}),{phase:"Serialize"}),t.addPolicy({name:"batchHeaderFilterPolicy",async sendRequest(e,t){let r="";for(const[t]of e.headers)hn(t,$i)&&(r=t);return""!==r&&e.headers.delete(r),t(e)}}),t.addPolicy((r=this,{name:"batchRequestAssemblePolicy",sendRequest:async e=>(r.appendSubRequestToBody(e),{request:e,status:200,headers:Nt()})}),{afterPhase:"Sign"}),dr(e)?t.addPolicy(lr({credential:e,scopes:Pi,challengeCallbacks:{authorizeRequestOnChallenge:ri}}),{phase:"Sign"}):e instanceof mr&&t.addPolicy((e.accountName,e.accountKey,{name:"storageSharedKeyCredentialPolicy",sendRequest:async(e,t)=>t(e)}),{phase:"Sign"});const i=new qn([]);return i._credential=e,i._corePipeline=t,i}appendSubRequestToBody(e){this.body+=[this.subRequestPrefix,`${Ni}: ${this.operationCount}`,"",`${e.method.toString()} ${ln(e.url)} ${Ki}${Wi}`].join(Wi);for(const[t,r]of e.headers)this.body+=`${t}: ${r}${Wi}`;this.body+=Wi}preAddSubRequest(e){if(this.operationCount>=256)throw new RangeError("Cannot exceed 256 sub requests in a single batch");const t=an(e.url);if(!t||""===t)throw new RangeError(`Invalid url for sub request: '${e.url}'`)}postAddSubRequest(e){this.subRequests.set(this.operationCount,e),this.operationCount++}getHttpRequestBody(){return`${this.body}${this.batchRequestEnding}${Wi}`}getMultipartContentType(){return this.multipartContentType}getSubRequests(){return this.subRequests}}class Cp{constructor(e,t,r){let i;i=Nn(t)?t:Un(t||new fr,r);const n=new Ou(e,Ln(i)),o=an(e);this.serviceOrContainerContext=o&&"/"!==o?n.container:n.service}createBatch(){return new Tp}async deleteBlobs(e,t,r){const i=new Tp;for(const n of e)"string"==typeof n?await i.deleteBlob(n,t,r):await i.deleteBlob(n,t);return this.submitBatch(i)}async setBlobsAccessTier(e,t,r,i){const n=new Tp;for(const o of e)"string"==typeof o?await n.setBlobAccessTier(o,t,r,i):await n.setBlobAccessTier(o,t,r);return this.submitBatch(n)}async submitBatch(e,t={}){if(!e||0===e.getSubRequests().size)throw new RangeError("Batch request should contain one or more sub requests.");return Nu.withSpan("BlobBatchClient-submitBatch",t,(async t=>{const r=e.getHttpRequestBody(),i=Tn(await this.serviceOrContainerContext.submitBatch((n=r,new Blob([n]).size),e.getMultiPartContentType(),r,Object.assign({},t)));var n;const o=new Sp(i,e.getSubRequests()),s=await o.parseBatchResponse();return{_response:i._response,contentType:i.contentType,errorCode:i.errorCode,requestId:i.requestId,clientRequestId:i.clientRequestId,version:i.version,subResponses:s.subResponses,subResponsesSucceededCount:s.subResponsesSucceededCount,subResponsesFailedCount:s.subResponsesFailedCount}}))}}class Ip extends zu{get containerName(){return this._containerName}constructor(e,t,r){let i,n;if(r=r||{},Nn(t))n=e,i=t;else if(ot&&t instanceof mr||t instanceof fr||dr(t))n=e,i=Un(t,r);else if(t||"string"==typeof t){if(!t||"string"!=typeof t)throw new Error("Expecting non-empty strings for containerName parameter");{const o=t,s=tn(e);if("AccountConnString"===s.kind){if(!ot)throw new Error("Account connection string is only supported in Node.js environment");{const e=new mr(s.accountName,s.accountKey);n=rn(s.url,encodeURIComponent(o)),r.proxyOptions||(r.proxyOptions=Lt(s.proxyUri)),i=Un(e,r)}}else{if("SASConnString"!==s.kind)throw new Error("Connection string must be either an Account connection string or a SAS connection string");n=rn(s.url,encodeURIComponent(o))+"?"+s.accountSas,i=Un(new fr,r)}}}else n=e,i=Un(new fr,r);super(n,i),this._containerName=this.getContainerNameFromUrl(),this.containerContext=this.storageClientContext.container}async create(e={}){return Nu.withSpan("ContainerClient-create",e,(async e=>Tn(await this.containerContext.create(e))))}async createIfNotExists(e={}){return Nu.withSpan("ContainerClient-createIfNotExists",e,(async e=>{var t,r;try{const t=await this.create(e);return Object.assign(Object.assign({succeeded:!0},t),{_response:t._response})}catch(e){if("ContainerAlreadyExists"===(null===(t=e.details)||void 0===t?void 0:t.errorCode))return Object.assign(Object.assign({succeeded:!1},null===(r=e.response)||void 0===r?void 0:r.parsedHeaders),{_response:e.response});throw e}}))}async exists(e={}){return Nu.withSpan("ContainerClient-exists",e,(async t=>{try{return await this.getProperties({abortSignal:e.abortSignal,tracingOptions:t.tracingOptions}),!0}catch(e){if(404===e.statusCode)return!1;throw e}}))}getBlobClient(e){return new yp(rn(this.url,En(e)),this.pipeline)}getAppendBlobClient(e){return new vp(rn(this.url,En(e)),this.pipeline)}getBlockBlobClient(e){return new bp(rn(this.url,En(e)),this.pipeline)}getPageBlobClient(e){return new wp(rn(this.url,En(e)),this.pipeline)}async getProperties(e={}){return e.conditions||(e.conditions={}),Nu.withSpan("ContainerClient-getProperties",e,(async t=>Tn(await this.containerContext.getProperties(Object.assign(Object.assign({abortSignal:e.abortSignal},e.conditions),{tracingOptions:t.tracingOptions})))))}async delete(e={}){return e.conditions||(e.conditions={}),Nu.withSpan("ContainerClient-delete",e,(async t=>Tn(await this.containerContext.delete({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,modifiedAccessConditions:e.conditions,tracingOptions:t.tracingOptions}))))}async deleteIfExists(e={}){return Nu.withSpan("ContainerClient-deleteIfExists",e,(async e=>{var t,r;try{const t=await this.delete(e);return Object.assign(Object.assign({succeeded:!0},t),{_response:t._response})}catch(e){if("ContainerNotFound"===(null===(t=e.details)||void 0===t?void 0:t.errorCode))return Object.assign(Object.assign({succeeded:!1},null===(r=e.response)||void 0===r?void 0:r.parsedHeaders),{_response:e.response});throw e}}))}async setMetadata(e,t={}){if(t.conditions||(t.conditions={}),t.conditions.ifUnmodifiedSince)throw new RangeError("the IfUnmodifiedSince must have their default values because they are ignored by the blob service");return Nu.withSpan("ContainerClient-setMetadata",t,(async r=>Tn(await this.containerContext.setMetadata({abortSignal:t.abortSignal,leaseAccessConditions:t.conditions,metadata:e,modifiedAccessConditions:t.conditions,tracingOptions:r.tracingOptions}))))}async getAccessPolicy(e={}){return e.conditions||(e.conditions={}),Nu.withSpan("ContainerClient-getAccessPolicy",e,(async t=>{const r=Tn(await this.containerContext.getAccessPolicy({abortSignal:e.abortSignal,leaseAccessConditions:e.conditions,tracingOptions:t.tracingOptions})),i={_response:r._response,blobPublicAccess:r.blobPublicAccess,date:r.date,etag:r.etag,errorCode:r.errorCode,lastModified:r.lastModified,requestId:r.requestId,clientRequestId:r.clientRequestId,signedIdentifiers:[],version:r.version};for(const e of r){let t;e.accessPolicy&&(t={permissions:e.accessPolicy.permissions},e.accessPolicy.expiresOn&&(t.expiresOn=new Date(e.accessPolicy.expiresOn)),e.accessPolicy.startsOn&&(t.startsOn=new Date(e.accessPolicy.startsOn))),i.signedIdentifiers.push({accessPolicy:t,id:e.id})}return i}))}async setAccessPolicy(e,t,r={}){return r.conditions=r.conditions||{},Nu.withSpan("ContainerClient-setAccessPolicy",r,(async i=>{const n=[];for(const e of t||[])n.push({accessPolicy:{expiresOn:e.accessPolicy.expiresOn?cn(e.accessPolicy.expiresOn):"",permissions:e.accessPolicy.permissions,startsOn:e.accessPolicy.startsOn?cn(e.accessPolicy.startsOn):""},id:e.id});return Tn(await this.containerContext.setAccessPolicy({abortSignal:r.abortSignal,access:e,containerAcl:n,leaseAccessConditions:r.conditions,modifiedAccessConditions:r.conditions,tracingOptions:i.tracingOptions}))}))}getBlobLeaseClient(e){return new Ju(this,e)}async uploadBlockBlob(e,t,r,i={}){return Nu.withSpan("ContainerClient-uploadBlockBlob",i,(async i=>{const n=this.getBlockBlobClient(e),o=await n.upload(t,r,i);return{blockBlobClient:n,response:o}}))}async deleteBlob(e,t={}){return Nu.withSpan("ContainerClient-deleteBlob",t,(async r=>{let i=this.getBlobClient(e);return t.versionId&&(i=i.withVersion(t.versionId)),i.delete(r)}))}async listBlobFlatSegment(e,t={}){return Nu.withSpan("ContainerClient-listBlobFlatSegment",t,(async r=>{const i=Tn(await this.containerContext.listBlobFlatSegment(Object.assign(Object.assign({marker:e},t),{tracingOptions:r.tracingOptions})));var n;return Object.assign(Object.assign({},i),{_response:Object.assign(Object.assign({},i._response),{parsedBody:(n=i._response.parsedBody,Object.assign(Object.assign({},n),{segment:{blobItems:n.segment.blobItems.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name)})))}}))}),segment:Object.assign(Object.assign({},i.segment),{blobItems:i.segment.blobItems.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name),tags:vn(e.blobTags),objectReplicationSourceProperties:wn(e.objectReplicationMetadata)})))})})}))}async listBlobHierarchySegment(e,t,r={}){return Nu.withSpan("ContainerClient-listBlobHierarchySegment",r,(async i=>{var n;const o=Tn(await this.containerContext.listBlobHierarchySegment(e,Object.assign(Object.assign({marker:t},r),{tracingOptions:i.tracingOptions})));return Object.assign(Object.assign({},o),{_response:Object.assign(Object.assign({},o._response),{parsedBody:Sn(o._response.parsedBody)}),segment:Object.assign(Object.assign({},o.segment),{blobItems:o.segment.blobItems.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name),tags:vn(e.blobTags),objectReplicationSourceProperties:wn(e.objectReplicationMetadata)}))),blobPrefixes:null===(n=o.segment.blobPrefixes)||void 0===n?void 0:n.map((e=>Object.assign(Object.assign({},e),{name:xn(e.name)})))})})}))}listSegments(e){return s(this,arguments,(function*(e,t={}){let r;if(e||void 0===e)do{r=yield o(this.listBlobFlatSegment(e,t)),e=r.continuationToken,yield yield o(yield o(r))}while(e)}))}listItems(){return s(this,arguments,(function*(e={}){var t,r,i,n;try{for(var s,d=!0,c=l(this.listSegments(undefined,e));!(t=(s=yield o(c.next())).done);d=!0){n=s.value,d=!1;const e=n;yield o(yield*a(l(e.segment.blobItems)))}}catch(e){r={error:e}}finally{try{d||t||!(i=c.return)||(yield o(i.call(c)))}finally{if(r)throw r.error}}}))}listBlobsFlat(e={}){const t=[];e.includeCopy&&t.push("copy"),e.includeDeleted&&t.push("deleted"),e.includeMetadata&&t.push("metadata"),e.includeSnapshots&&t.push("snapshots"),e.includeVersions&&t.push("versions"),e.includeUncommitedBlobs&&t.push("uncommittedblobs"),e.includeTags&&t.push("tags"),e.includeDeletedWithVersions&&t.push("deletedwithversions"),e.includeImmutabilityPolicy&&t.push("immutabilitypolicy"),e.includeLegalHold&&t.push("legalhold"),""===e.prefix&&(e.prefix=void 0);const r=Object.assign(Object.assign({},e),t.length>0?{include:t}:{}),i=this.listItems(r);return{next:()=>i.next(),[Symbol.asyncIterator](){return this},byPage:(e={})=>this.listSegments(e.continuationToken,Object.assign({maxPageSize:e.maxPageSize},r))}}listHierarchySegments(e,t){return s(this,arguments,(function*(e,t,r={}){let i;if(t||void 0===t)do{i=yield o(this.listBlobHierarchySegment(e,t,r)),t=i.continuationToken,yield yield o(yield o(i))}while(t)}))}listItemsByHierarchy(e){return s(this,arguments,(function*(e,t={}){var r,i,n,s;try{for(var a,d=!0,c=l(this.listHierarchySegments(e,undefined,t));!(r=(a=yield o(c.next())).done);d=!0){s=a.value,d=!1;const e=s.segment;if(e.blobPrefixes)for(const t of e.blobPrefixes)yield yield o(Object.assign({kind:"prefix"},t));for(const t of e.blobItems)yield yield o(Object.assign({kind:"blob"},t))}}catch(e){i={error:e}}finally{try{d||r||!(n=c.return)||(yield o(n.call(c)))}finally{if(i)throw i.error}}}))}listBlobsByHierarchy(e,t={}){if(""===e)throw new RangeError("delimiter should contain one or more characters");const r=[];t.includeCopy&&r.push("copy"),t.includeDeleted&&r.push("deleted"),t.includeMetadata&&r.push("metadata"),t.includeSnapshots&&r.push("snapshots"),t.includeVersions&&r.push("versions"),t.includeUncommitedBlobs&&r.push("uncommittedblobs"),t.includeTags&&r.push("tags"),t.includeDeletedWithVersions&&r.push("deletedwithversions"),t.includeImmutabilityPolicy&&r.push("immutabilitypolicy"),t.includeLegalHold&&r.push("legalhold"),""===t.prefix&&(t.prefix=void 0);const i=Object.assign(Object.assign({},t),r.length>0?{include:r}:{}),n=this.listItemsByHierarchy(e,i);return{next:async()=>n.next(),[Symbol.asyncIterator](){return this},byPage:(t={})=>this.listHierarchySegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},i))}}async findBlobsByTagsSegment(e,t,r={}){return Nu.withSpan("ContainerClient-findBlobsByTagsSegment",r,(async i=>{const n=Tn(await this.containerContext.filterBlobs({abortSignal:r.abortSignal,where:e,marker:t,maxPageSize:r.maxPageSize,tracingOptions:i.tracingOptions})),o=Object.assign(Object.assign({},n),{_response:n._response,blobs:n.blobs.map((e=>{var t;let r="";return 1===(null===(t=e.tags)||void 0===t?void 0:t.blobTagSet.length)&&(r=e.tags.blobTagSet[0].value),Object.assign(Object.assign({},e),{tags:vn(e.tags),tagValue:r})}))});return o}))}findBlobsByTagsSegments(e,t){return s(this,arguments,(function*(e,t,r={}){let i;if(t||void 0===t)do{i=yield o(this.findBlobsByTagsSegment(e,t,r)),i.blobs=i.blobs||[],t=i.continuationToken,yield yield o(i)}while(t)}))}findBlobsByTagsItems(e){return s(this,arguments,(function*(e,t={}){var r,i,n,s;try{for(var d,c=!0,u=l(this.findBlobsByTagsSegments(e,undefined,t));!(r=(d=yield o(u.next())).done);c=!0){s=d.value,c=!1;const e=s;yield o(yield*a(l(e.blobs)))}}catch(e){i={error:e}}finally{try{c||r||!(n=u.return)||(yield o(n.call(u)))}finally{if(i)throw i.error}}}))}findBlobsByTags(e,t={}){const r=Object.assign({},t),i=this.findBlobsByTagsItems(e,r);return{next:()=>i.next(),[Symbol.asyncIterator](){return this},byPage:(t={})=>this.findBlobsByTagsSegments(e,t.continuationToken,Object.assign({maxPageSize:t.maxPageSize},r))}}async getAccountInfo(e={}){return Nu.withSpan("ContainerClient-getAccountInfo",e,(async t=>Tn(await this.containerContext.getAccountInfo({abortSignal:e.abortSignal,tracingOptions:t.tracingOptions}))))}getContainerNameFromUrl(){let e;try{const t=new URL(this.url);if(e="blob"===t.hostname.split(".")[1]?t.pathname.split("/")[1]:mn(t)?t.pathname.split("/")[2]:t.pathname.split("/")[1],e=decodeURIComponent(e),!e)throw new Error("Provided containerName is invalid.");return e}catch(e){throw new Error("Unable to extract containerName with provided information.")}}generateSasUrl(e){return new Promise((t=>{if(!(this.credential instanceof mr))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");const r=Gu(Object.assign({containerName:this._containerName},e),this.credential).toString();t(dn(this.url,r))}))}generateSasStringToSign(e){if(!(this.credential instanceof mr))throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");return Wu(Object.assign({containerName:this._containerName},e),this.credential).stringToSign}getBlobBatchClient(){return new Cp(this.url,this.pipeline)}}var Ap=__webpack_require__(2404),Fp=__webpack_require__.n(Ap);class Mp{checkConnectCommonOps(e){return r(this,void 0,void 0,(function*(){try{console.info("check connect: create folder");const e=`rs-test-folder-${E()}/`;yield this.mkdir(e),console.info("check connect: upload file");const t=`${e}rs-test-file-${E()}`,r=Date.now(),i=Date.now(),n=new ArrayBuffer(100);yield this.writeFile(t,n,i,r),console.info("check connect: overwrite file");const o=Date.now(),s=new ArrayBuffer(200);yield this.writeFile(t,s,o,r),console.info("check connect: download file");const a=yield this.readFile(t);if(!Fp()(s,a))throw Error("downloaded file is not equal with uploaded file!");return console.info("check connect: delete file"),yield this.rm(t),console.info("check connect: delete folder"),yield this.rm(e),!0}catch(t){return console.error(t),null==e||e(t),!1}}))}}var Dp=__webpack_require__(53050),Rp=__webpack_require__.n(Dp),Pp=__webpack_require__(48287).Buffer;const Op=(e,t=!0,r=!0)=>{if(!t&&!r)throw Error("parameter error for isHiddenPath");const i=he.posix.normalize(e).split("/");for(const e of i)if("."!==e&&".."!==e&&""!==e){if(t&&"."===e[0])return!0;if(r&&"_"===e[0])return!0}return!1},zp=(e,t=!1)=>{const r=[];if(""===e||"/"===e)return r;const i=e.split("/");for(let e=0;e+1r(void 0,void 0,void 0,(function*(){const r=zp(e);for(const e of r){(yield t.adapter.exists(e))||(console.info(`mkdir ${e}`),yield t.adapter.mkdir(e))}})),qp=e=>e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength),Up=e=>Pp.from(e),Lp=e=>Up(e).toString("hex"),jp=e=>void 0!==e&&!Rp()("\\p{Cc}|\\p{Cf}|\\p{Co}|\\p{Cn}|\\p{Zl}|\\p{Zp}","A").test(e),Hp=e=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE89\uDE8F-\uDEC2\uDEC6\uDECE-\uDEDC\uDEDF-\uDEE9]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g.test(e),$p=(e,t=!0)=>{const r={};return e.forEach(((e,i)=>{t?r[i.toLowerCase()]=e:r[i]=e})),r},Gp=e=>{const t=he.posix.dirname(e);return"."===t||"/"===t?"/":t.endsWith("/")?t:`${t}/`},Wp=e=>[...e].reverse().join(""),Kp=e=>{if(void 0===e||""===e||"."===e||".."===e||e.startsWith("/"))throw Error(`do not know which level for ${e}`);let t=e;return e.endsWith("/")&&(t=e.slice(0,-1)),t.split("/").length},Vp=(e,t=!1)=>{if(null!=e&&!Number.isNaN(e))return t?window.moment(e).toISOString(!0):window.moment(e).format()},Jp=(e,t)=>r(void 0,void 0,void 0,(function*(){const r=yield e.adapter.stat(t);if(null==r)throw Error(`${t} doesn't exist cannot run stat`);return(void 0===r.ctime||null===r.ctime||Number.isNaN(r.ctime))&&(r.ctime=void 0),(void 0===r.mtime||null===r.mtime||Number.isNaN(r.mtime))&&(r.mtime=void 0),void 0!==r.size&&null!==r.size&&!Number.isNaN(r.size)||"folder"!==r.type||(r.size=0),r})),Yp=(e,t)=>{const r=[".git",".github",".gitlab",".svn","node_modules",".DS_Store","__MACOSX ","Icon\r","desktop.ini","Desktop.ini","thumbs.db","Thumbs.db"].concat(void 0!==t?t:[]);for(const t of r)if(e===t||e===`${t}/`||e.endsWith(`/${t}`)||e.endsWith(`/${t}/`))return!0;const i=e.split("/");if(i.length>0){const e=i[i.length-1];if(e.startsWith("~$")){const t=["doc","docx","ppt","pptx","xls","xlsx"];for(const r of t)if(e.endsWith(`.${r}`))return!0}}return!1},Qp=e=>{const t=document.createElement("template");return t.innerHTML=e,t.content},Zp=e=>new Promise((t=>setTimeout(t,e))),Xp=(e,t)=>{const i=document.getElementsByClassName("app-container")[0],n=document.querySelector(".is-mobile .app-container .status-bar");if(void 0===i||void 0===n)return console.warn("give up watching appContainer for statusbar"),void console.warn(`appContainer=${i}, statusbar=${n}`);if("enable"===e){const e=(e,t)=>r(void 0,void 0,void 0,(function*(){for(const t of e)if("childList"===t.type&&t.addedNodes.length>0){const e=t.addedNodes[0];if(e.className.contains("mobile-navbar")||e.className.contains("mobile-toolbar")){yield Zp(300);const t=window.getComputedStyle(e).getPropertyValue("height");n.style.setProperty("display","flex"),n.style.setProperty("margin-bottom",t)}}})),t=new MutationObserver(e);t.observe(i,{attributes:!1,childList:!0,characterData:!1,subtree:!1});try{const e=document.getElementsByClassName("mobile-navbar")[0],t=window.getComputedStyle(e).getPropertyValue("height");n.style.setProperty("display","flex"),n.style.setProperty("margin-bottom",t)}catch(e){}return t}return void 0!==t&&(console.debug("disconnect oldAppContainerObserver"),t.disconnect(),t=void 0),n.style.removeProperty("display"),void n.style.removeProperty("margin-bottom")},eh=e=>{const t=[],r=[e];let i=0;for(;r.length;){const e=r.pop();switch(typeof e){case"boolean":i+=4;break;case"string":i+=2*e.length;break;case"number":i+=8;break;case"object":if(!t.includes(e)){t.push(e);for(const t in e)e.hasOwnProperty(t)&&r.push(e[t])}}}return i},th=(e,t)=>{if(e<0)throw Error("totalSize should not be negative");if(t<=0)throw Error("chunkSize should not be negative or zero");if(0===e)return[];if(e<=t)return[{start:0,end:e-1}];const r=[],i=Math.ceil(1*e/t);for(let n=0;nr(void 0,void 0,void 0,(function*(){const r=yield window.crypto.subtle.digest("SHA-1",e);if("base64"===t)return(e=>Up(e).toString("base64"))(r);if("hex"===t)return Lp(r);throw Error(`not supported stringify option = ${t}`)})),ih=e=>{if(void 0===e)return"";let t=he.posix.normalize(e.trim());return void 0===t||""===t||"/"===t||"."===t?"":(t.startsWith("/")&&(t=t.slice(1)),t.endsWith("/")||(t=`${t}/`),t)},nh={containerSasUrl:"",containerName:"",remotePrefix:"",generateFolderObject:!1,partsConcurrency:5,kind:"azureblobstorage"},oh=(e,t)=>{if(t.startsWith("/")||!t.endsWith("/"))throw Error(`remotePrefix should not have leading slash but should have tailing slash: ${t}`);return`${t}${e}`},sh=(e,t,r)=>{var i,n,o;const s=((e,t)=>{if(t.startsWith("/")||!t.endsWith("/"))throw Error(`remotePrefix should not have leading slash but should have tailing slash: ${t}`);if(!e.startsWith(t))throw Error(`${e} does not start with ${t}!`);return e.slice(t.length)})(e,r);let a=t.lastModified.valueOf();const l=null===(i=t.metadata)||void 0===i?void 0:i.mtime;if(void 0!==l&&""!==l)try{a=new Date(l).valueOf()}catch(e){}let d;void 0!==t.contentMD5&&(d=Lp(t.contentMD5.buffer));const c={key:s,keyRaw:s,mtimeCli:a,mtimeSvr:t.lastModified.valueOf(),size:null!==(n=t.contentLength)&&void 0!==n?n:0,sizeRaw:null!==(o=t.contentLength)&&void 0!==o?o:0,hash:d};return s.endsWith("/")&&(c.synthesizedFolder=!1),c};class ah extends Mp{constructor(e,t){super(),this.kind="azureblobstorage",this.config=e,this.vaultName=t,this.synthFoldersCache={},this.remotePrefix=`${t}/`;const r=ih(this.config.remotePrefix);""!==r&&(this.remotePrefix=r),this.containerClient=new Ip(this.config.containerSasUrl)}walk(){return r(this,void 0,void 0,(function*(){var e,t,r,i;const n=[],o=new Set;try{for(var s,a=!0,d=l(this.containerClient.listBlobsFlat({prefix:this.remotePrefix,includeMetadata:!0}));!(e=(s=yield d.next()).done);a=!0){i=s.value,a=!1;const e=i,t=this.containerClient.getBlockBlobClient(e.name),r=yield t.getProperties(),l=sh(e.name,r,this.remotePrefix);n.push(l),o.add(l.key);for(const e of zp(l.key,!0))o.has(e)?delete this.synthFoldersCache[e]:(!this.synthFoldersCache.hasOwnProperty(e)||l.mtimeSvr>=this.synthFoldersCache[e].mtimeSvr)&&(this.synthFoldersCache[e]={key:e,keyRaw:e,size:0,sizeRaw:0,sizeEnc:0,mtimeSvr:l.mtimeSvr,mtimeSvrFmt:l.mtimeSvrFmt,mtimeCli:l.mtimeCli,mtimeCliFmt:l.mtimeCliFmt,synthesizedFolder:!0})}}catch(e){t={error:e}}finally{try{a||e||!(r=d.return)||(yield r.call(d))}finally{if(t)throw t.error}}for(const e of Object.keys(this.synthFoldersCache))n.push(this.synthFoldersCache[e]);return n}))}walkPartial(){return r(this,void 0,void 0,(function*(){var e,t,r,i;const n=[];try{for(var o,s=!0,a=l(this.containerClient.listBlobsByHierarchy("/",{prefix:this.remotePrefix,includeMetadata:!0}));!(e=(o=yield a.next()).done);s=!0){i=o.value,s=!1;const e=i;if("prefix"===e.kind)continue;const t=this.containerClient.getBlockBlobClient(e.name),r=yield t.getProperties(),a=sh(e.name,r,this.remotePrefix);n.push(a)}}catch(e){t={error:e}}finally{try{s||e||!(r=a.return)||(yield r.call(a))}finally{if(t)throw t.error}}return n}))}stat(e){return r(this,void 0,void 0,(function*(){const t=oh(e,this.remotePrefix),r=this.containerClient.getBlockBlobClient(t),i=yield r.getProperties();return sh(t,i,this.remotePrefix)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){var r;if(!e.endsWith("/"))throw new Error(`You should not call mkdir on ${e}!`);if(!(null!==(r=this.config.generateFolderObject)&&void 0!==r&&r)){const r={key:e,keyRaw:e,size:0,sizeRaw:0,sizeEnc:0,mtimeSvr:t,mtimeCli:t,synthesizedFolder:!0};return this.synthFoldersCache[e]=r,r}return yield this.writeFile(e,new ArrayBuffer(0),null!=t?t:Date.now(),null!=i?i:Date.now())}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){var r,o;const s=oh(e,this.remotePrefix),a=this.containerClient.getBlockBlobClient(s),l={mtime:new Date(i).toISOString(),ctime:new Date(n).toISOString()};if(e.endsWith("/")){console.debug("yeah we have folder upload");if(!(null!==(r=this.config.generateFolderObject)&&void 0!==r&&r))throw Error("if not generate folder object, the func should not go here");l.hdi_isfolder="true"}const d=yield a.uploadData(t,{metadata:l,concurrency:null!==(o=this.config.partsConcurrency)&&void 0!==o?o:5});if(e.endsWith("/")&&(console.debug("yeah we have folder upload"),console.debug(d)),d._response.status>=300)throw Error(`upload ${e} failed with ${JSON.stringify(d)}`);return yield this.stat(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){const t=oh(e,this.remotePrefix),r=this.containerClient.getBlockBlobClient(t),i=yield r.download();if(i._response.status>=300)throw Error(`download ${e} failed with ${JSON.stringify(i)}`);return yield(yield i.blobBody).arrayBuffer()}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){const t=oh(e,this.remotePrefix);if(e.endsWith("/")){this.synthFoldersCache.hasOwnProperty(e)&&delete this.synthFoldersCache[e];try{const e=this.containerClient.getBlockBlobClient(t);yield e.deleteIfExists()}catch(e){}}else{const r=this.containerClient.getBlockBlobClient(t),i=yield r.deleteIfExists();if(!i.succeeded)throw Error(`something goes wrong while deleting ${e}: ${JSON.stringify(i)}`)}}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this.walkPartial()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}allowEmptyFile(){return!0}}var lh=__webpack_require__(80070),dh=__webpack_require__(86049),ch=__webpack_require__(72322),uh=__webpack_require__(58686),ph=__webpack_require__(30228);class hh extends Error{constructor(e){super(e),this.name="TimeoutError"}}class fh extends Error{constructor(e){super(),this.name="AbortError",this.message=e}}const mh=e=>void 0===globalThis.DOMException?new fh(e):new DOMException(e),gh=e=>{const t=void 0===e.reason?mh("This operation was aborted."):e.reason;return t instanceof Error?t:mh(t)};class yh{#t=[];enqueue(e,t){const r={priority:(t={priority:0,...t}).priority,run:e};if(this.size&&this.#t[this.size-1].priority>=t.priority)return void this.#t.push(r);const i=function(e,t,r){let i=0,n=e.length;for(;n>0;){const o=Math.trunc(n/2);let s=i+o;r(e[s],t)<=0?(i=++s,n-=o+1):n=o}return i}(this.#t,r,((e,t)=>t.priority-e.priority));this.#t.splice(i,0,r)}dequeue(){const e=this.#t.shift();return e?.run}filter(e){return this.#t.filter((t=>t.priority===e.priority)).map((e=>e.run))}get size(){return this.#t.length}}class vh extends ph{#r;#i;#n=0;#o;#s;#a=0;#l;#d;#t;#c;#u=0;#p;#h;#f;timeout;constructor(e){if(super(),!("number"==typeof(e={carryoverConcurrencyCount:!1,intervalCap:Number.POSITIVE_INFINITY,interval:0,concurrency:Number.POSITIVE_INFINITY,autoStart:!0,queueClass:yh,...e}).intervalCap&&e.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??""}\` (${typeof e.intervalCap})`);if(void 0===e.interval||!(Number.isFinite(e.interval)&&e.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??""}\` (${typeof e.interval})`);this.#r=e.carryoverConcurrencyCount,this.#i=e.intervalCap===Number.POSITIVE_INFINITY||0===e.interval,this.#o=e.intervalCap,this.#s=e.interval,this.#t=new e.queueClass,this.#c=e.queueClass,this.concurrency=e.concurrency,this.timeout=e.timeout,this.#f=!0===e.throwOnTimeout,this.#h=!1===e.autoStart}get#m(){return this.#i||this.#n{this.#b()}),t)),!0;this.#n=this.#r?this.#u:0}return!1}#v(){if(0===this.#t.size)return this.#l&&clearInterval(this.#l),this.#l=void 0,this.emit("empty"),0===this.#u&&this.emit("idle"),!1;if(!this.#h){const e=!this.#x;if(this.#m&&this.#g){const t=this.#t.dequeue();return!!t&&(this.emit("active"),t(),e&&this.#_(),!0)}}return!1}#_(){this.#i||void 0!==this.#l||(this.#l=setInterval((()=>{this.#w()}),this.#s),this.#a=Date.now()+this.#s)}#w(){0===this.#n&&0===this.#u&&this.#l&&(clearInterval(this.#l),this.#l=void 0),this.#n=this.#r?this.#u:0,this.#S()}#S(){for(;this.#v(););}get concurrency(){return this.#p}set concurrency(e){if(!("number"==typeof e&&e>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#p=e,this.#S()}async#k(e){return new Promise(((t,r)=>{e.addEventListener("abort",(()=>{r(e.reason)}),{once:!0})}))}async add(e,t={}){return t={timeout:this.timeout,throwOnTimeout:this.#f,...t},new Promise(((r,i)=>{this.#t.enqueue((async()=>{this.#u++,this.#n++;try{t.signal?.throwIfAborted();let i=e({signal:t.signal});t.timeout&&(i=function(e,t){const{milliseconds:r,fallback:i,message:n,customTimers:o={setTimeout,clearTimeout}}=t;let s;const a=new Promise(((a,l)=>{if("number"!=typeof r||1!==Math.sign(r))throw new TypeError(`Expected \`milliseconds\` to be a positive number, got \`${r}\``);if(t.signal){const{signal:r}=t;r.aborted&&l(gh(r));const i=()=>{l(gh(r))};r.addEventListener("abort",i,{once:!0}),e.finally((()=>{r.removeEventListener("abort",i)}))}if(r===Number.POSITIVE_INFINITY)return void e.then(a,l);const d=new hh;s=o.setTimeout.call(void 0,(()=>{if(i)try{a(i())}catch(e){l(e)}else"function"==typeof e.cancel&&e.cancel(),!1===n?a():n instanceof Error?l(n):(d.message=n??`Promise timed out after ${r} milliseconds`,l(d))}),r),(async()=>{try{a(await e)}catch(e){l(e)}})()})).finally((()=>{a.clear()}));return a.clear=()=>{o.clearTimeout.call(void 0,s),s=void 0},a}(Promise.resolve(i),{milliseconds:t.timeout})),t.signal&&(i=Promise.race([i,this.#k(t.signal)]));const n=await i;r(n),this.emit("completed",n)}catch(e){if(e instanceof hh&&!t.throwOnTimeout)return void r();i(e),this.emit("error",e)}finally{this.#y()}}),t),this.emit("add"),this.#v()}))}async addAll(e,t){return Promise.all(e.map((async e=>this.add(e,t))))}start(){return this.#h?(this.#h=!1,this.#S(),this):this}pause(){this.#h=!0}clear(){this.#t=new this.#c}async onEmpty(){0!==this.#t.size&&await this.#E("empty")}async onSizeLessThan(e){this.#t.sizethis.#t.size{const i=()=>{t&&!t()||(this.off(e,i),r())};this.on(e,i)}))}get size(){return this.#t.size}sizeBy(e){return this.#t.filter(e).length}get pending(){return this.#u}get isPaused(){return this.#h}}const bh={accessToken:"",refreshToken:"",accessTokenExpiresInMs:0,accessTokenExpiresAtTimeMs:0,credentialsShouldBeDeletedAtTimeMs:0,kind:"box"},wh=(e,t,r)=>{var i,n,o,s,a,l,d,c;if(void 0===t||""===t||"0"===t)throw Error(`parentID=${t} should not be in fromBoxItemToEntity`);let u=e.name;if(void 0!==r&&""!==r&&"/"!==r){if(!r.endsWith("/"))throw Error(`parentFolderPath=${r} should not be in fromFileToBoxEntity`);u=`${r}${e.name}`}if("folder"===e.type){u=`${u}/`;const a=null!==(s=null!==(n=null===(i=e.contentModifiedAt)||void 0===i?void 0:i.value.valueOf())&&void 0!==n?n:null===(o=e.modifiedAt)||void 0===o?void 0:o.value.valueOf())&&void 0!==s?s:Date.now();return{key:u,keyRaw:u,mtimeCli:a,mtimeSvr:a,id:e.id,parentID:t,isFolder:!0,size:0,sizeRaw:0,hash:void 0,hashSha1:void 0,parentIDPath:r}}if("file"===e.type){const i=null!==(c=null!==(l=null===(a=e.contentModifiedAt)||void 0===a?void 0:a.value.valueOf())&&void 0!==l?l:null===(d=e.modifiedAt)||void 0===d?void 0:d.value.valueOf())&&void 0!==c?c:Date.now();return{key:u,keyRaw:u,mtimeCli:i,mtimeSvr:i,id:e.id,parentID:t,isFolder:!1,size:e.size,sizeRaw:e.size,hash:e.sha1,hashSha1:e.sha1,parentIDPath:r}}throw Error("we do not support web link Box item")},_h=(e,t,r)=>{var i,n,o,s,a;if(void 0===t||""===t||"0"===t)throw Error(`parentID=${t} should not be in fromRawResponseToEntity`);let l=e.name;if(void 0!==r&&""!==r&&"/"!==r){if(!r.endsWith("/"))throw Error(`parentFolderPath=${r} should not be in fromFileToBoxEntity`);l=`${r}${e.name}`}if("folder"===e.type)l=`${l}/`;else if("file"!==e.type)throw Error("we do not support web link Box item");const d=null!==(i=e.content_modified_at)&&void 0!==i?i:e.modified_at;let c=Date.now();return void 0!==d&&(c=new Date(d).valueOf()),{key:l,keyRaw:l,mtimeCli:c,mtimeSvr:c,id:e.id,parentID:t,isFolder:!1,size:null!==(n=e.size)&&void 0!==n?n:0,sizeRaw:null!==(o=e.size)&&void 0!==o?o:0,hash:null!==(s=e.sha1)&&void 0!==s?s:void 0,hashSha1:null!==(a=e.sha1)&&void 0!==a?a:void 0,parentIDPath:r}};class xh extends Mp{constructor(e,t,r){super(),this.kind="box",this.boxConfig=e,this.remoteBaseDir=this.boxConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.keyToBoxEntity={},this.baseDirID=""}_init(){return r(this,void 0,void 0,(function*(){var e,t,r,i,n;const o=yield this._getAccessToken();if(this.vaultFolderExists);else{const s=new ch.BoxDeveloperTokenAuth({token:o}),a=new uh.r({auth:s});let l,d=0;const c=1e3;for(;!this.vaultFolderExists;){if(l=yield a.folders.getFolderItems("0",{queryParams:{fields:["id","type","name","sha1","size","created_at","modified_at","expires_at","parent","content_created_at","content_modified_at","etag"],offset:d,limit:c}}),(null!==(t=null===(e=l.entries)||void 0===e?void 0:e.filter((e=>e.name===this.remoteBaseDir)).length)&&void 0!==t?t:0)>0){const e=null===(r=l.entries)||void 0===r?void 0:r.filter((e=>e.name===this.remoteBaseDir))[0];this.baseDirID=e.id,this.vaultFolderExists=!0;break}if((null!==(i=l.offset)&&void 0!==i?i:0)>=(null!==(n=l.totalCount)&&void 0!==n?n:0))break;d+=c}if(!this.vaultFolderExists){const e=yield a.folders.createFolder({name:this.remoteBaseDir,parent:{id:"0"}});this.baseDirID=e.id,this.vaultFolderExists=!0}}}))}_getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.boxConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now();if(this.boxConfig.accessTokenExpiresAtTimeMs>e)return this.boxConfig.accessToken;const t=yield(i=this.boxConfig.refreshToken,r(void 0,void 0,void 0,(function*(){console.debug("refreshing token");const e=yield fetch("https://api.box.com/oauth2/token",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:U,client_secret:L,grant_type:"refresh_token",refresh_token:i}).toString()});if(200===e.status){const t=yield e.json();return console.debug("new token obtained"),t}throw Error("cannot refresh an access token")})));var i;return this.boxConfig.accessToken=t.access_token,this.boxConfig.accessTokenExpiresInMs=1e3*t.expires_in,this.boxConfig.accessTokenExpiresAtTimeMs=e+1e3*t.expires_in-12e4,this.boxConfig.refreshToken=t.refresh_token||this.boxConfig.refreshToken,yield this.saveUpdatedConfigFunc(),console.info("Box accessToken updated"),this.boxConfig.accessToken}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e=[],t=new vh({concurrency:5,autoStart:!0});t.on("error",(e=>{throw t.pause(),t.clear(),e}));let i=[{id:this.baseDirID,folderPath:""}];for(;0!==i.length;){const n=[];for(const{id:o,folderPath:s}of i)t.add((()=>r(this,void 0,void 0,(function*(){const t=yield this._walkFolder(o,s);for(const r of t)if(e.push(r),r.isFolder){const e={id:r.id,folderPath:r.keyRaw};n.push(e)}}))));yield t.onIdle(),i=n}return e}))}_walkFolder(e,t){return r(this,void 0,void 0,(function*(){var r,i;const n=[],o=yield this._getAccessToken(),s=new ch.BoxDeveloperTokenAuth({token:o}),a=new uh.r({auth:s});if(void 0===e||""===e||"root"===e)throw Error("something goes wrong walking folder");let l,d=0;do{l=yield a.folders.getFolderItems(e,{queryParams:{fields:["id","type","name","sha1","size","created_at","modified_at","expires_at","parent","content_created_at","content_modified_at","etag"],offset:d,limit:1e3}});for(const i of null!==(r=l.entries)&&void 0!==r?r:[]){const r=wh(i,e,t);this.keyToBoxEntity[r.keyRaw]=r,n.push(r)}d+=1e3}while(d<(null!==(i=null==l?void 0:l.totalCount)&&void 0!==i?i:0));return n}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();return yield this._walkFolder(this.baseDirID,"")}))}stat(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToBoxEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);const i=yield this._getAccessToken(),n=new ch.BoxDeveloperTokenAuth({token:i}),o=new uh.r({auth:n});let s;s=t.isFolder?yield o.folders.getFolderById(r):yield o.files.getFileById(r);const a=wh(s,t.parentID,t.parentIDPath);return this.keyToBoxEntity[e]=a,a}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not mkdir on key=${e}`);yield this._init();const t=this.keyToBoxEntity[e],r=null==t?void 0:t.id;if(void 0!==t&&void 0!==r)return t;const i=zp(e);let n,o;if(0===i.length)throw Error(`cannot getFolderLevels of ${e}`);if(1===i.length)o=this.baseDirID,n="";else{if(n=`${i[i.length-2]}/`,!(n in this.keyToBoxEntity))throw Error(`parent of ${e}: ${n} is not created before??`);o=this.keyToBoxEntity[n].id}let s=i[i.length-1];s=s.split("/").pop();const a=yield this._getAccessToken(),l=new ch.BoxDeveloperTokenAuth({token:a}),d=new uh.r({auth:l}),c=yield d.folders.createFolder({name:s,parent:{id:o}}),u=wh(c,o,n);return this.keyToBoxEntity[e]=u,u}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`should not call writeFile on ${e}`);yield this._init();const r=this.keyToBoxEntity[e],o=null==r?void 0:r.id,s=dh.contentType(dh.lookup(e)||I)||I;let a,l;const d=zp(e);if(0===d.length)a=this.baseDirID,l="";else{if(l=`${d[d.length-1]}/`,!(l in this.keyToBoxEntity))throw Error(`parent of ${e}: ${l} is not created before??`);a=this.keyToBoxEntity[l].id}const c=e.split("/").pop();if(t.byteLength<=2e7){const r=new FormData,d={name:c,parent:{id:a},content_created_at:Vp(n),content_modified_at:Vp(i)};r.append("attributes",JSON.stringify(d)),r.append("file",new Blob([t],{type:s}));let u="";u=void 0===o?"https://upload.box.com/api/2.0/files/content":`https://upload.box.com/api/2.0/files/${o}/content`;const p=yield fetch(u,{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`},body:r});if(200!==p.status&&201!==p.status)throw Error(`create file ${e} failed! attributes=${JSON.stringify(d)}`);const h=yield p.json();if(void 0===h.entries)throw Error(`upload small file ${e} failed!`);const f=_h(h.entries[0],a,l);return this.keyToBoxEntity[e]=f,f}{let r="";r=void 0===o?"https://upload.box.com/api/2.0/files/upload_sessions":`https://upload.box.com/api/2.0/files/${o}/upload_sessions`;const s=yield fetch(r,{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Type":"application/json"},body:JSON.stringify({file_name:c,file_size:t.byteLength,folder_id:a})});if(200!==s.status&&201!==s.status)throw Error(`Create upload session for ${e} failed! Response header=${JSON.stringify(s.headers)}`);const d=yield s.json(),u=d.part_size,p=th(t.byteLength,u),h=[];for(const{start:r,end:i}of p){const n=t.slice(r,i+1),o=yield rh(n,"base64"),s=yield fetch(d.session_endpoints.upload_part,{method:"PUT",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Range":`bytes ${r}-${i}/${t.byteLength}`,"Content-Type":"application/octet-stream",digest:`sha=${o}`},body:n});if(200!==s.status&&201!==s.status)throw Error(`Upload chunk for ${e}, ${r}-${i} failed! Response header=${JSON.stringify(s.headers)}`);h.push(yield s.json())}const f=yield rh(t,"base64");let m=202,g=0;do{const t=yield fetch(d.session_endpoints.commit,{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Type":"application/json",digest:`sha=${f}`},body:JSON.stringify({parts:h.map((e=>e.part)),attributes:{content_modified_at:Vp(i,!1),content_created_at:Vp(n,!1)}})});if(m=t.status,200===m||201===m){const r=yield t.json();if(void 0===r.entries)throw Error(`Upload big file ${e} failed!`);const i=_h(r.entries[0],a,l);return this.keyToBoxEntity[e]=i,i}if(202!==m)throw Error(`Commit all chunks for ${e} failed! Response header=${JSON.stringify(t.headers)}`);yield Zp(500),g+=1}while(202===m&&g<4);throw Error(`Commit all chunks for ${e} failed! No idea what happened`)}}))}readFile(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToBoxEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);const i=yield fetch(`https://api.box.com/2.0/files/${r}/content`,{method:"GET",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`}});if(200!==i.status)throw Error(`Cannot download file ${e} with id ${r}. Response header=${JSON.stringify(i.headers)}`);return yield i.arrayBuffer()}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToBoxEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);const i=yield this._getAccessToken(),n=new ch.BoxDeveloperTokenAuth({token:i}),o=new uh.r({auth:n});t.isFolder?yield o.folders.deleteFolderById(r,{queryParams:{recursive:!0}}):yield o.files.deleteFileById(r)}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){yield fetch("https://api.box.com/oauth2/revoke",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:U,client_secret:L,token:this.boxConfig.refreshToken}).toString()})}))}allowEmptyFile(){return!0}}const Sh={accessToken:"",refreshToken:"",accessTokenExpiresInMs:0,accessTokenExpiresAtTimeMs:0,credentialsShouldBeDeletedAtTimeMs:0,scope:"https://www.googleapis.com/auth/drive.file",kind:"googledrive"},kh="application/vnd.google-apps.folder",Eh=e=>r(void 0,void 0,void 0,(function*(){console.debug("refreshing token");const t=yield fetch("https://oauth2.googleapis.com/token",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:z,client_secret:N,grant_type:"refresh_token",refresh_token:e}).toString()});if(200===t.status){const e=yield t.json();return console.debug("new token obtained"),e}throw Error("cannot refresh an access token")})),Th=(e,t,r)=>{if(void 0===t||""===t||"root"===t)throw Error(`parentID=${t} should not be in fromFileToGDEntity`);let i=e.name;if(void 0!==r&&""!==r&&"/"!==r){if(!r.endsWith("/"))throw Error(`parentFolderPath=${r} should not be in fromFileToGDEntity`);i=`${r}${e.name}`}const n=e.mimeType===kh;return n&&(i=`${i}/`),{key:i,keyRaw:i,mtimeCli:Date.parse(e.modifiedTime),mtimeSvr:Date.parse(e.modifiedTime),size:n?0:Number.parseInt(e.size),sizeRaw:n?0:Number.parseInt(e.size),hash:n?void 0:e.md5Checksum,id:e.id,parentID:t,isFolder:n}};class Bh extends Mp{constructor(e,t,r){super(),this.kind="googledrive",this.googleDriveConfig=e,this.remoteBaseDir=this.googleDriveConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.keyToGDEntity={},this.baseDirID=""}_init(){return r(this,void 0,void 0,(function*(){if(yield this._getAccessToken(),this.vaultFolderExists);else{const e=`https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(`name='${this.remoteBaseDir}' and mimeType='application/vnd.google-apps.folder' and trashed=false`)}&pageSize=1000&fields=kind,nextPageToken,files(kind,fileExtension,md5Checksum,mimeType,parents,size,spaces,id,name,trashed,createdTime,modifiedTime,quotaBytesUsed,originalFilename,fullFileExtension,sha1Checksum,sha256Checksum)`,t=yield fetch(e,{method:"GET",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`}}),r=yield t.json();if(r.files.length>0)this.baseDirID=r.files[0].id,this.vaultFolderExists=!0;else{console.debug(`we need to create the base dir ${this.remoteBaseDir}`);const e={mimeType:kh,name:this.remoteBaseDir},t=yield fetch("https://www.googleapis.com/drive/v3/files",{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Type":"application/json"},body:JSON.stringify(e)}),r=yield t.json();if(200!==t.status)throw Error(`cannot create base dir ${this.remoteBaseDir} in init func.`);console.debug(`succeed to create the base dir ${this.remoteBaseDir}`),this.baseDirID=r.id,this.vaultFolderExists=!0}}}))}_getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.googleDriveConfig.accessToken||""===this.googleDriveConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now();if(this.googleDriveConfig.accessTokenExpiresAtTimeMs>e)return this.googleDriveConfig.accessToken;const t=yield Eh(this.googleDriveConfig.refreshToken);return this.googleDriveConfig.accessToken=t.access_token,this.googleDriveConfig.accessTokenExpiresInMs=1e3*t.expires_in,this.googleDriveConfig.accessTokenExpiresAtTimeMs=e+1e3*t.expires_in-12e4,yield this.saveUpdatedConfigFunc(),console.info("Google Drive accessToken updated"),this.googleDriveConfig.accessToken}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e=[],t=new vh({concurrency:5,autoStart:!0});t.on("error",(e=>{throw t.pause(),t.clear(),e}));let i=[{id:this.baseDirID,folderPath:""}];for(;0!==i.length;){const n=[];for(const{id:o,folderPath:s}of i)t.add((()=>r(this,void 0,void 0,(function*(){const t=yield this._walkFolder(o,s);for(const r of t)if(e.push(r),r.isFolder){const e={id:r.id,folderPath:r.keyRaw};n.push(e)}}))));yield t.onIdle(),i=n}return e}))}_walkFolder(e,t){return r(this,void 0,void 0,(function*(){const r=[];let i;if(void 0===e||""===e||"root"===e)throw Error("something goes wrong walking folder");do{const n=`https://www.googleapis.com/drive/v3/files?q=${encodeURIComponent(`'${e}' in parents and trashed=false`)}&pageSize=1000&fields=kind,nextPageToken,files(kind,fileExtension,md5Checksum,mimeType,parents,size,spaces,id,name,trashed,createdTime,modifiedTime,quotaBytesUsed,originalFilename,fullFileExtension,sha1Checksum,sha256Checksum)${void 0!==i?`&pageToken=${i}`:""}`,o=yield fetch(n,{method:"GET",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`}});if(200!==o.status)throw Error(`cannot walk for parentID=${e}`);const s=yield o.json();for(const i of s.files){const n=Th(i,e,t);this.keyToGDEntity[n.keyRaw]=n,r.push(n)}i=s.nextPageToken}while(void 0!==i);return r}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();return yield this._walkFolder(this.baseDirID,"")}))}stat(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToGDEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);const i=`https://www.googleapis.com/drive/v3/files/${r}?fields=kind,fileExtension,md5Checksum,mimeType,parents,size,spaces,id,name,trashed,createdTime,modifiedTime,quotaBytesUsed,originalFilename,fullFileExtension,sha1Checksum,sha256Checksum`,n=yield fetch(i,{method:"GET",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`}});if(200!==n.status)throw Error(`cannot get file meta fileID=${r}, key=${e}`);const o=yield n.json(),s=Th(o,t.parentID,t.parentIDPath);return this.keyToGDEntity[e]=s,s}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not mkdir on key=${e}`);yield this._init();const r=zp(e);let n,o;if(0===r.length)throw Error(`cannot getFolderLevels of ${e}`);if(1===r.length)o=this.baseDirID,n="";else{if(n=`${r[r.length-2]}/`,!(n in this.keyToGDEntity))throw Error(`parent of ${e}: ${n} is not created before??`);o=this.keyToGDEntity[n].id}let s=r[r.length-1];s=s.split("/").pop();const a={mimeType:kh,modifiedTime:Vp(t,!0),createdTime:Vp(i,!0),name:s,parents:[o]},l=yield fetch("https://www.googleapis.com/drive/v3/files",{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Type":"application/json"},body:JSON.stringify(a)});if(200!==l.status&&201!==l.status)throw Error(`create folder ${e} failed! meta=${JSON.stringify(a)}`);const d=yield l.json(),c=Th(d,o,n);return this.keyToGDEntity[e]=c,c}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`should not call writeFile on ${e}`);yield this._init();const r=dh.contentType(dh.lookup(e)||I)||I;let o,s;const a=zp(e);if(0===a.length)o=this.baseDirID,s="";else{if(s=`${a[a.length-1]}/`,!(s in this.keyToGDEntity))throw Error(`parent of ${e}: ${s} is not created before??`);o=this.keyToGDEntity[s].id}const l=e.split("/").pop();if(t.byteLength<=5242880){const a=new FormData,d={name:l,modifiedTime:Vp(i,!0),createdTime:Vp(n,!0),parents:[o]};a.append("metadata",new Blob([JSON.stringify(d)],{type:"application/json; charset=UTF-8"})),a.append("media",new Blob([t],{type:r}));const c=yield fetch("https://www.googleapis.com/upload/drive/v3/files?uploadType=multipart&fields=kind,fileExtension,md5Checksum,mimeType,parents,size,spaces,id,name,trashed,createdTime,modifiedTime,quotaBytesUsed,originalFilename,fullFileExtension,sha1Checksum,sha256Checksum",{method:"POST",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`},body:a});if(200!==c.status&&201!==c.status)throw Error(`create file ${e} failed! meta=${JSON.stringify(d)}`);const u=yield c.json();console.debug(`upload ${e} with ${JSON.stringify(d)}, res2=${JSON.stringify(u)}`);const p=Th(u,o,s);return this.keyToGDEntity[e]=p,p}{const a={name:l,modifiedTime:Vp(i,!0),createdTime:Vp(n,!0),parents:[o]},d=JSON.stringify(a),c={Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Type":"application/json","Content-Length":`${d.length}`,"X-Upload-Content-Type":r,"X-Upload-Content-Length":`${t.byteLength}`},u=yield fetch("https://www.googleapis.com/upload/drive/v3/files?uploadType=resumable&fields=kind,fileExtension,md5Checksum,mimeType,parents,size,spaces,id,name,trashed,createdTime,modifiedTime,quotaBytesUsed,originalFilename,fullFileExtension,sha1Checksum,sha256Checksum",{method:"POST",headers:c,body:d});if(200!==u.status)throw Error(`create resumable file ${e} failed! meta=${JSON.stringify(a)}, header=${JSON.stringify(c)}`);const p=u.headers.get("Location");if(null===p||!p.startsWith("http"))throw Error(`create resumable file ${e} failed! meta=${JSON.stringify(a)}, header=${JSON.stringify(c)}`);console.debug(`key=${e}, uploadLocaltion=${p}`);const h=5242880,f=th(t.byteLength,h);let m;for(const{start:r,end:i}of f){console.debug(`key=${e}, start upload chunk ${r}-${i}/${t.byteLength}`);const n=yield fetch(p,{method:"PUT",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`,"Content-Length":""+(i-r+1),"Content-Range":`bytes ${r}-${i}/${t.byteLength}`},body:t.slice(r,i+1)});if(n.status>=400&&n.status<=599)throw Error(`create resumable file ${e} failed! meta=${JSON.stringify(a)}, header=${JSON.stringify(c)}`);if(200===n.status||201===n.status){const t=yield n.json();console.debug(`upload ${e} with ${JSON.stringify(a)}, res2=${JSON.stringify(t)}`),void 0===t.id||null===t.id||""===t.id||(m=Th(t,o,s),this.keyToGDEntity[e]=m)}}if(void 0===m)throw Error(`something goes wrong while uploading large file ${e}`);return m}}))}readFile(e){return r(this,void 0,void 0,(function*(){var t;if(e.endsWith("/"))throw Error(`you should not call readFile on ${e}`);yield this._init();const r=null===(t=this.keyToGDEntity[e])||void 0===t?void 0:t.id;if(void 0===r)throw Error(`no fileID found for key=${e}`);const i=yield fetch(`https://www.googleapis.com/drive/v3/files/${r}?alt=media`,{method:"GET",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`}});if(200!==i.status)throw Error(`cannot download ${e} using fileID=${r}`);return yield i.arrayBuffer()}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){var t;yield this._init();const r=null===(t=this.keyToGDEntity[e])||void 0===t?void 0:t.id;if(void 0===r)throw Error(`no fileID found for key=${e}`);if(200!==(yield fetch(`https://www.googleapis.com/drive/v3/files/${r}`,{method:"PATCH",headers:{Authorization:`Bearer ${yield this._getAccessToken()}`},body:JSON.stringify({trashed:!0})})).status)throw Error(`cannot rm ${e} using fileID=${r}`)}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){if(200===(yield fetch(`https://oauth2.googleapis.com/revoke?token=${this._getAccessToken()}`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"}})).status)return!0;throw Error("cannot revoke")}))}allowEmptyFile(){return!0}}const Ch={"Content-Type":"application/json"},Ih=/\{[^{}]+\}/g;class Ah extends Request{constructor(e,t){super(e,t);for(const e in t)e in this||(this[e]=t[e])}}function Fh(e){let{baseUrl:t="",fetch:r=globalThis.fetch,querySerializer:i,bodySerializer:n,headers:o,...s}={...e};t.endsWith("/")&&(t=t.substring(0,t.length-1)),o=zh(Ch,o);const a=[];async function l(e,l){const{fetch:d=r,headers:c,params:u={},parseAs:p="json",querySerializer:h,bodySerializer:f=n??Oh,...m}=l||{};let g="function"==typeof i?i:Ph(i);h&&(g="function"==typeof h?h:Ph({..."object"==typeof i?i:{},...h}));const y={redirect:"follow",...s,...m,headers:zh(o,c,u.header)};let v,b;y.body&&(y.body=f(y.body),y.body instanceof FormData&&y.headers.delete("Content-Type"));let w=new Ah(function(e,t){let r=`${t.baseUrl}${e}`;t.params?.path&&(r=function(e,t){let r=e;for(const i of e.match(Ih)??[]){let e=i.substring(1,i.length-1),n=!1,o="simple";if(e.endsWith("*")&&(n=!0,e=e.substring(0,e.length-1)),e.startsWith(".")?(o="label",e=e.substring(1)):e.startsWith(";")&&(o="matrix",e=e.substring(1)),!t||void 0===t[e]||null===t[e])continue;const s=t[e];Array.isArray(s)?r=r.replace(i,Rh(e,s,{style:o,explode:n})):r="object"!=typeof s?"matrix"!==o?r.replace(i,"label"===o?`.${encodeURIComponent(s)}`:encodeURIComponent(s)):r.replace(i,`;${Mh(e,s)}`):r.replace(i,Dh(e,s,{style:o,explode:n}))}return r}(r,t.params.path));let i=t.querySerializer(t.params.query??{});i.startsWith("?")&&(i=i.substring(1));i&&(r+=`?${i}`);return r}(e,{baseUrl:t,params:u,querySerializer:g}),y);if(a.length){v=Math.random().toString(36).slice(2,11),b=Object.freeze({baseUrl:t,fetch:d,parseAs:p,querySerializer:g,bodySerializer:f});for(const t of a)if(t&&"object"==typeof t&&"function"==typeof t.onRequest){const r=await t.onRequest({request:w,schemaPath:e,params:u,options:b,id:v});if(r){if(!(r instanceof Request))throw new Error("onRequest: must return new Request() when modifying the request");w=r}}}let _=await d(w);if(a.length)for(let t=a.length-1;t>=0;t--){const r=a[t];if(r&&"object"==typeof r&&"function"==typeof r.onResponse){const t=await r.onResponse({request:w,response:_,schemaPath:e,params:u,options:b,id:v});if(t){if(!(t instanceof Response))throw new Error("onResponse: must return new Response() when modifying the response");_=t}}}if(204===_.status||"0"===_.headers.get("Content-Length"))return _.ok?{data:{},response:_}:{error:{},response:_};if(_.ok)return"stream"===p?{data:_.body,response:_}:{data:await _[p](),response:_};let x=await _.text();try{x=JSON.parse(x)}catch{}return{error:x,response:_}}return{GET:(e,t)=>l(e,{...t,method:"GET"}),PUT:(e,t)=>l(e,{...t,method:"PUT"}),POST:(e,t)=>l(e,{...t,method:"POST"}),DELETE:(e,t)=>l(e,{...t,method:"DELETE"}),OPTIONS:(e,t)=>l(e,{...t,method:"OPTIONS"}),HEAD:(e,t)=>l(e,{...t,method:"HEAD"}),PATCH:(e,t)=>l(e,{...t,method:"PATCH"}),TRACE:(e,t)=>l(e,{...t,method:"TRACE"}),use(...e){for(const t of e)if(t){if("object"!=typeof t||!("onRequest"in t)&&!("onResponse"in t))throw new Error("Middleware must be an object with one of `onRequest()` or `onResponse()`");a.push(t)}},eject(...e){for(const t of e){const e=a.indexOf(t);-1!==e&&a.splice(e,1)}}}}function Mh(e,t,r){if(null==t)return"";if("object"==typeof t)throw new Error("Deeply-nested arrays/objects aren’t supported. Provide your own `querySerializer()` to handle these.");return`${e}=${!0===r?.allowReserved?t:encodeURIComponent(t)}`}function Dh(e,t,r){if(!t||"object"!=typeof t)return"";const i=[],n={simple:",",label:".",matrix:";"}[r.style]||"&";if("deepObject"!==r.style&&!1===r.explode){for(const e in t)i.push(e,!0===r.allowReserved?t[e]:encodeURIComponent(t[e]));const n=i.join(",");switch(r.style){case"form":return`${e}=${n}`;case"label":return`.${n}`;case"matrix":return`;${e}=${n}`;default:return n}}for(const n in t){const o="deepObject"===r.style?`${e}[${n}]`:n;i.push(Mh(o,t[n],r))}const o=i.join(n);return"label"===r.style||"matrix"===r.style?`${n}${o}`:o}function Rh(e,t,r){if(!Array.isArray(t))return"";if(!1===r.explode){const i={form:",",spaceDelimited:"%20",pipeDelimited:"|"}[r.style]||",",n=(!0===r.allowReserved?t:t.map((e=>encodeURIComponent(e)))).join(i);switch(r.style){case"simple":return n;case"label":return`.${n}`;case"matrix":return`;${e}=${n}`;default:return`${e}=${n}`}}const i={simple:",",label:".",matrix:";"}[r.style]||"&",n=[];for(const i of t)"simple"===r.style||"label"===r.style?n.push(!0===r.allowReserved?i:encodeURIComponent(i)):n.push(Mh(e,i,r));return"label"===r.style||"matrix"===r.style?`${i}${n.join(i)}`:n.join(i)}function Ph(e){return function(t){const r=[];if(t&&"object"==typeof t)for(const i in t){const n=t[i];null!=n&&(Array.isArray(n)?r.push(Rh(i,n,{style:"form",explode:!0,...e?.array,allowReserved:e?.allowReserved||!1})):"object"!=typeof n?r.push(Mh(i,n,e)):r.push(Dh(i,n,{style:"deepObject",explode:!0,...e?.object,allowReserved:e?.allowReserved||!1})))}return r.join("&")}}function Oh(e){return e instanceof FormData?e:JSON.stringify(e)}function zh(...e){const t=new Headers;for(const r of e){if(!r||"object"!=typeof r)continue;const e=r instanceof Headers?r.entries():Object.entries(r);for(const[r,i]of e)if(null===i)t.delete(r);else if(Array.isArray(i))for(const e of i)t.append(r,e);else void 0!==i&&t.set(r,i)}return t}const Nh={accessToken:"",accessTokenExpiresInMs:0,accessTokenExpiresAtTimeMs:0,refreshToken:"",remoteBaseDir:"",credentialsShouldBeDeletedAtTimeMs:0,scope:"",api:"https://app.koofr.net",mountID:"",kind:"koofr"},qh=(e,t)=>{if("/"===e||""===e)throw Error(`do not know how to deal with path: ${e}`);if(!e.startsWith("/"))throw Error(`path returned by koofr should starts with slash: ${e}`);if("file"===t)return e.slice(1);if("dir"===t)return`${e.slice(1)}/`;throw Error(`do not know how to deal with path and type: ${e}, ${t}`)},Uh=(e,t)=>{let r=e;return"/"===e||""===e?r=`/${t}`:e.startsWith("/")?(console.warn(`why the path ${e} starts with '/'? but we just go on.`),r=`/${t}${e}`):r=`/${t}/${e}`,r.endsWith("/")&&(r=r.slice(0,r.length-1)),r},Lh=e=>{var t,r,i,n;if("error"===e.type)throw Error(`cannot understand ${JSON.stringify(e)}`);const o=qh(null!==(t=e.path)&&void 0!==t?t:"/",null===(r=e.file)||void 0===r?void 0:r.type);if("dir"===(null===(i=e.file)||void 0===i?void 0:i.type)||"file"===(null===(n=e.file)||void 0===n?void 0:n.type))return{key:o,keyRaw:o,mtimeCli:e.file.modified,mtimeSvr:e.file.modified,size:e.file.size,sizeRaw:e.file.size,hash:e.file.hash};throw Error(`cannot understand ${JSON.stringify(e)}`)},jh=(e,t)=>{const r=qh(`${t}/${e.name}`,e.type);if("dir"===e.type||"file"===e.type)return{key:r,keyRaw:r,mtimeCli:e.modified,mtimeSvr:e.modified,size:e.size,sizeRaw:e.size,hash:e.hash};throw Error(`cannot understand ${JSON.stringify(e)}`)},Hh=(e,t)=>{const i={onRequest(i){return r(this,arguments,void 0,(function*({request:i}){const n=yield(()=>r(this,void 0,void 0,(function*(){if(""===e.refreshToken)throw Error("The user has not manually auth yet.");const i=Date.now();if(e.accessTokenExpiresAtTimeMs>i)return e.accessToken;const n=yield(o=e.api,s=e.refreshToken,r(void 0,void 0,void 0,(function*(){console.debug("refreshing token");const e=yield fetch(`${o}/oauth2/token`,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:J,client_secret:Y,grant_type:"refresh_token",refresh_token:s}).toString()});if(200===e.status){const t=yield e.json();return console.debug("new token obtained"),t}{const t=yield e.json();throw Error(`cannot refresh an access token: ${JSON.stringify(t)}`)}})));var o,s;return e.accessToken=n.access_token,e.accessTokenExpiresInMs=1e3*n.expires_in,e.accessTokenExpiresAtTimeMs=i+1e3*n.expires_in-12e4,yield t(),console.info("Koofr accessToken updated"),e.accessToken})))();return i.headers.set("Authorization",`Bearer ${n}`),i}))}};return i};class $h extends Mp{constructor(e,t,r){super(),this.kind="koofr",this.koofrConfig=e,this.remoteBaseDir=this.koofrConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.placeID=this.koofrConfig.mountID;const i=Fh({baseUrl:this.koofrConfig.api});i.use(Hh(this.koofrConfig,r)),this.client=i}_init(){return r(this,void 0,void 0,(function*(){var e;if(""===this.koofrConfig.refreshToken)throw Error("You have not auth yet!");if(void 0===this.placeID||""===this.placeID){const{data:e,error:t}=yield this.client.GET("/api/v2.1/places"),r=null==e?void 0:e.places.filter((e=>e.isPrimary))[0].id;if(this.placeID=null!=r?r:"",""===this.placeID)throw Error("cannot find primary placeID")}if(this.vaultFolderExists);else{const{data:t,error:r}=yield this.client.GET("/api/v2.1/mounts/{mountId}/files/list",{params:{query:{path:"/"},path:{mountId:this.placeID}}}),i=null==t?void 0:t.files.filter((e=>e.name===this.remoteBaseDir));if((null!==(e=null==i?void 0:i.length)&&void 0!==e?e:0)>0)this.vaultFolderExists=!0;else{const{data:e,error:t}=yield this.client.POST("/api/v2.1/mounts/{mountId}/files/folder",{params:{query:{path:"/"},path:{mountId:this.placeID}},body:{name:this.remoteBaseDir}});if(void 0===e)throw Error(JSON.stringify(t));this.vaultFolderExists=!0}}}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const{data:e,error:t}=yield this.client.GET("/content/api/v2.1/mounts/{mountId}/files/listrecursive",{params:{query:{path:this.remoteBaseDir},path:{mountId:this.placeID}},parseAs:"text"});if(void 0!==t)throw Error(JSON.stringify(t));const r=JSON.parse(`[${e.trim().split("\n").join(",")}]`).filter((e=>"/"!==e.path)).map(Lh);return r}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();const{data:e,error:t}=yield this.client.GET("/api/v2.1/mounts/{mountId}/files/list",{params:{query:{path:this.remoteBaseDir},path:{mountId:this.placeID}}});if(void 0!==t)throw Error(JSON.stringify(t));const r=e.files.map((e=>jh(e,"")));return r}))}stat(e){return r(this,void 0,void 0,(function*(){yield this._init();const{data:t,error:r}=yield this.client.GET("/api/v2.1/mounts/{mountId}/files/info",{params:{query:{path:Uh(e,this.remoteBaseDir)},path:{mountId:this.placeID}}});if(void 0!==r)throw Error(JSON.stringify(r));return jh(t,Uh(Gp(e),this.remoteBaseDir))}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){yield this._init();const t=Gp(e),r=e.slice(0,-1).split("/").pop(),{data:i,error:n}=yield this.client.POST("/api/v2.1/mounts/{mountId}/files/folder",{params:{query:{path:Uh(t,this.remoteBaseDir)},path:{mountId:this.placeID}},body:{name:r}});if(void 0!==n)throw Error(JSON.stringify(n));return this.stat(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){yield this._init();const r=e.split("/").pop(),{data:n,error:o}=yield this.client.POST("/content/api/v2.1/mounts/{mountId}/files/put",{params:{query:{path:Uh(Gp(e),this.remoteBaseDir),filename:r,info:!0,overwrite:!0,autorename:!1,modified:i},path:{mountId:this.placeID}},body:t,bodySerializer:e=>e});if(void 0!==o)throw Error(JSON.stringify(o));return jh(n,Uh(Gp(e),this.remoteBaseDir))}))}readFile(e){return r(this,void 0,void 0,(function*(){yield this._init();const{data:t,error:r}=yield this.client.GET("/content/api/v2.1/mounts/{mountId}/files/get",{params:{query:{path:Uh(e,this.remoteBaseDir),force:!0},path:{mountId:this.placeID}},parseAs:"arrayBuffer"});if(void 0!==r)throw Error(JSON.stringify(r));return t}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){yield this._init();const{data:t,error:r}=yield this.client.DELETE("/api/v2.1/mounts/{mountId}/files/remove",{params:{query:{path:Uh(e,this.remoteBaseDir),force:!0},path:{mountId:this.placeID}}});if(void 0!==r)throw Error(JSON.stringify(r))}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}allowEmptyFile(){return!0}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Gh={LIBRARY_NAME:"MSAL.JS",SKU:"msal.js.common",CACHE_PREFIX:"msal",DEFAULT_AUTHORITY:"https://login.microsoftonline.com/common/",DEFAULT_AUTHORITY_HOST:"login.microsoftonline.com",DEFAULT_COMMON_TENANT:"common",ADFS:"adfs",DSTS:"dstsv2",AAD_INSTANCE_DISCOVERY_ENDPT:"https://login.microsoftonline.com/common/discovery/instance?api-version=1.1&authorization_endpoint=",CIAM_AUTH_URL:".ciamlogin.com",AAD_TENANT_DOMAIN_SUFFIX:".onmicrosoft.com",RESOURCE_DELIM:"|",NO_ACCOUNT:"NO_ACCOUNT",CLAIMS:"claims",CONSUMER_UTID:"9188040d-6c67-4c5b-b112-36a304b66dad",OPENID_SCOPE:"openid",PROFILE_SCOPE:"profile",OFFLINE_ACCESS_SCOPE:"offline_access",EMAIL_SCOPE:"email",CODE_RESPONSE_TYPE:"code",CODE_GRANT_TYPE:"authorization_code",RT_GRANT_TYPE:"refresh_token",FRAGMENT_RESPONSE_MODE:"fragment",S256_CODE_CHALLENGE_METHOD:"S256",URL_FORM_CONTENT_TYPE:"application/x-www-form-urlencoded;charset=utf-8",AUTHORIZATION_PENDING:"authorization_pending",NOT_DEFINED:"not_defined",EMPTY_STRING:"",NOT_APPLICABLE:"N/A",NOT_AVAILABLE:"Not Available",FORWARD_SLASH:"/",IMDS_ENDPOINT:"http://169.254.169.254/metadata/instance/compute/location",IMDS_VERSION:"2020-06-01",IMDS_TIMEOUT:2e3,AZURE_REGION_AUTO_DISCOVER_FLAG:"TryAutoDetect",REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX:"login.microsoft.com",KNOWN_PUBLIC_CLOUDS:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"],TOKEN_RESPONSE_TYPE:"token",ID_TOKEN_RESPONSE_TYPE:"id_token",SHR_NONCE_VALIDITY:240,INVALID_INSTANCE:"invalid_instance"},Wh=200,Kh=200,Vh=299,Jh=302,Yh=400,Qh=499,Zh=500,Xh=500,ef=599,tf=[Gh.OPENID_SCOPE,Gh.PROFILE_SCOPE,Gh.OFFLINE_ACCESS_SCOPE],rf=[...tf,Gh.EMAIL_SCOPE],nf="Content-Type",of="Retry-After",sf="X-AnchorMailbox",af="x-ms-request-id",lf="x-ms-httpver",df={COMMON:"common",ORGANIZATIONS:"organizations",CONSUMERS:"consumers"},cf="access_token",uf="xms_cc",pf={LOGIN:"login",SELECT_ACCOUNT:"select_account",CONSENT:"consent",NONE:"none",CREATE:"create",NO_SESSION:"no_session"},hf={PLAIN:"plain",S256:"S256"},ff={QUERY:"query",FRAGMENT:"fragment",FORM_POST:"form_post"},mf="authorization_code",gf="password",yf="refresh_token",vf="device_code",bf="MSSTS",wf="ADFS",_f="Generic",xf="-",Sf=".",kf={ID_TOKEN:"IdToken",ACCESS_TOKEN:"AccessToken",ACCESS_TOKEN_WITH_AUTH_SCHEME:"AccessToken_With_AuthScheme",REFRESH_TOKEN:"RefreshToken"},Ef="appmetadata",Tf="1",Bf="authority-metadata",Cf=86400,If="config",Af="cache",Ff="network",Mf="hardcoded_values",Df={SCHEMA_VERSION:5,MAX_CUR_HEADER_BYTES:80,MAX_LAST_HEADER_BYTES:330,MAX_CACHED_ERRORS:50,CACHE_KEY:"server-telemetry",CATEGORY_SEPARATOR:"|",VALUE_SEPARATOR:",",OVERFLOW_TRUE:"1",OVERFLOW_FALSE:"0",UNKNOWN_ERROR:"unknown_error"},Rf={BEARER:"Bearer",POP:"pop",SSH:"ssh-cert"},Pf=60,Of=3600,zf="throttling",Nf="retry-after, h429",qf="invalid_grant",Uf="client_mismatch",Lf="username",jf="password",Hf=200,$f=400,Gf="1",Wf="3",Kf="4",Vf="2",Jf="4",Yf="5",Qf="0",Zf="1",Xf="2",em="3",tm="4",rm="AZURE_POD_IDENTITY_AUTHORITY_HOST",im="IDENTITY_ENDPOINT",nm="IMDS_ENDPOINT",om="MSI_ENDPOINT",sm="user-assigned-client-id",am="user-assigned-resource-id",lm="user-assigned-object-id",dm="get",cm="post",um={SUCCESS:Wh,SUCCESS_RANGE_START:Kh,SUCCESS_RANGE_END:Vh,SERVER_ERROR:Zh},pm="sha256",hm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",fm="msal.js.node",mm="urn:ietf:params:oauth:client-assertion-type:jwt-bearer",gm="authorization_pending",ym="http://",vm="localhost",bm=62,wm=371,_m=671,xm=871,Sm=872,km="RS256",Em="PS256",Tm="x5t#S256",Bm="x5t",Cm="x5c",Im="aud",Am="exp",Fm="iss",Mm="sub",Dm="nbf",Rm="jti",Pm=100,Om=5e3,zm="unexpected_error",Nm="post_request_failed",qm={[zm]:"Unexpected error in authentication.",[Nm]:"Post request failed from the network, could be a 4xx/5xx or a network unavailability. Please check the exact error code for details."};class Um extends Error{constructor(e,t,r){super(t?`${e}: ${t}`:e),Object.setPrototypeOf(this,Um.prototype),this.errorCode=e||Gh.EMPTY_STRING,this.errorMessage=t||Gh.EMPTY_STRING,this.subError=r||Gh.EMPTY_STRING,this.name="AuthError"}setCorrelationId(e){this.correlationId=e}}function Lm(e){const{skus:t,libraryName:r,libraryVersion:i,extensionName:n,extensionVersion:o}=e,s=new Map([[0,[r,i]],[2,[n,o]]]);let a=[];if(t?.length){if(a=t.split(","),a.length<4)return t}else a=Array.from({length:4},(()=>"|"));return s.forEach(((e,t)=>{2===e.length&&e[0]?.length&&e[1]?.length&&function(e){const{skuArr:t,index:r,skuName:i,skuVersion:n}=e;if(r>=t.length)return;t[r]=[i,n].join("|")}({skuArr:a,index:t,skuName:e[0],skuVersion:e[1]})})),a.join(",")}class jm{constructor(e,t){this.cacheOutcome=Qf,this.cacheManager=t,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||Gh.EMPTY_STRING,this.wrapperVer=e.wrapperVer||Gh.EMPTY_STRING,this.telemetryCacheKey=Df.CACHE_KEY+xf+e.clientId}generateCurrentRequestHeaderValue(){const e=`${this.apiId}${Df.VALUE_SEPARATOR}${this.cacheOutcome}`,t=[this.wrapperSKU,this.wrapperVer],r=this.getNativeBrokerErrorCode();r?.length&&t.push(`broker_error=${r}`);const i=t.join(Df.VALUE_SEPARATOR),n=[e,this.getRegionDiscoveryFields()].join(Df.VALUE_SEPARATOR);return[Df.SCHEMA_VERSION,n,i].join(Df.CATEGORY_SEPARATOR)}generateLastRequestHeaderValue(){const e=this.getLastRequests(),t=jm.maxErrorsToSend(e),r=e.failedRequests.slice(0,2*t).join(Df.VALUE_SEPARATOR),i=e.errors.slice(0,t).join(Df.VALUE_SEPARATOR),n=e.errors.length,o=[n,t=Df.MAX_CACHED_ERRORS&&(t.failedRequests.shift(),t.failedRequests.shift(),t.errors.shift()),t.failedRequests.push(this.apiId,this.correlationId),e instanceof Error&&e&&e.toString()?e instanceof Um?e.subError?t.errors.push(e.subError):e.errorCode?t.errors.push(e.errorCode):t.errors.push(e.toString()):t.errors.push(e.toString()):t.errors.push(Df.UNKNOWN_ERROR),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)}incrementCacheHits(){const e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e),e.cacheHits}getLastRequests(){return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||{failedRequests:[],errors:[],cacheHits:0}}clearTelemetryCache(){const e=this.getLastRequests(),t=jm.maxErrorsToSend(e);if(t===e.errors.length)this.cacheManager.removeItem(this.telemetryCacheKey);else{const r={failedRequests:e.failedRequests.slice(2*t),errors:e.errors.slice(t),cacheHits:0};this.cacheManager.setServerTelemetry(this.telemetryCacheKey,r)}}static maxErrorsToSend(e){let t,r=0,i=0;const n=e.errors.length;for(t=0;t{}),this.piiLoggingEnabled=i.piiLoggingEnabled||!1,this.level="number"==typeof i.logLevel?i.logLevel:Ym.Info,this.correlationId=i.correlationId||Gh.EMPTY_STRING,this.packageName=t||Gh.EMPTY_STRING,this.packageVersion=r||Gh.EMPTY_STRING}static createDefaultLoggerOptions(){return{loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:Ym.Info}}clone(e,t,r){return new Qm({loggerCallback:this.localCallback,piiLoggingEnabled:this.piiLoggingEnabled,logLevel:this.level,correlationId:r||this.correlationId},e,t)}logMessage(e,t){if(t.logLevel>this.level||!this.piiLoggingEnabled&&t.containsPii)return;const r=`${`[${(new Date).toUTCString()}] : [${t.correlationId||this.correlationId||""}]`} : ${this.packageName}@${this.packageVersion} : ${Ym[t.logLevel]} - ${e}`;this.executeCallback(t.logLevel,r,t.containsPii||!1)}executeCallback(e,t,r){this.localCallback&&this.localCallback(e,t,r)}error(e,t){this.logMessage(e,{logLevel:Ym.Error,containsPii:!1,correlationId:t||Gh.EMPTY_STRING})}errorPii(e,t){this.logMessage(e,{logLevel:Ym.Error,containsPii:!0,correlationId:t||Gh.EMPTY_STRING})}warning(e,t){this.logMessage(e,{logLevel:Ym.Warning,containsPii:!1,correlationId:t||Gh.EMPTY_STRING})}warningPii(e,t){this.logMessage(e,{logLevel:Ym.Warning,containsPii:!0,correlationId:t||Gh.EMPTY_STRING})}info(e,t){this.logMessage(e,{logLevel:Ym.Info,containsPii:!1,correlationId:t||Gh.EMPTY_STRING})}infoPii(e,t){this.logMessage(e,{logLevel:Ym.Info,containsPii:!0,correlationId:t||Gh.EMPTY_STRING})}verbose(e,t){this.logMessage(e,{logLevel:Ym.Verbose,containsPii:!1,correlationId:t||Gh.EMPTY_STRING})}verbosePii(e,t){this.logMessage(e,{logLevel:Ym.Verbose,containsPii:!0,correlationId:t||Gh.EMPTY_STRING})}trace(e,t){this.logMessage(e,{logLevel:Ym.Trace,containsPii:!1,correlationId:t||Gh.EMPTY_STRING})}tracePii(e,t){this.logMessage(e,{logLevel:Ym.Trace,containsPii:!0,correlationId:t||Gh.EMPTY_STRING})}isPiiLoggingEnabled(){return this.piiLoggingEnabled||!1}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Zm=0,Xm=1,eg=2,tg=3; +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const rg="redirect_uri_empty",ig="claims_request_parsing_error",ng="authority_uri_insecure",og="url_parse_error",sg="empty_url_error",ag="empty_input_scopes_error",lg="invalid_prompt_value",dg="invalid_claims",cg="token_request_empty",ug="logout_request_empty",pg="invalid_code_challenge_method",hg="pkce_params_missing",fg="invalid_cloud_discovery_metadata",mg="invalid_authority_metadata",gg="untrusted_authority",yg="missing_ssh_jwk",vg="missing_ssh_kid",bg="missing_nonce_authentication_header",wg="invalid_authentication_header",_g="cannot_set_OIDCOptions",xg="cannot_allow_native_broker",Sg="authority_mismatch",kg={[rg]:"A redirect URI is required for all calls, and none has been set.",[ig]:"Could not parse the given claims request object.",[ng]:"Authority URIs must use https. Please see here for valid authority configuration options: https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-js-initializing-client-applications#configuration-options",[og]:"URL could not be parsed into appropriate segments.",[sg]:"URL was empty or null.",[ag]:"Scopes cannot be passed as null, undefined or empty array because they are required to obtain an access token.",[lg]:"Please see here for valid configuration options: https://azuread.github.io/microsoft-authentication-library-for-js/ref/modules/_azure_msal_common.html#commonauthorizationurlrequest",[dg]:"Given claims parameter must be a stringified JSON object.",[cg]:"Token request was empty and not found in cache.",[ug]:"The logout request was null or undefined.",[pg]:'code_challenge_method passed is invalid. Valid values are "plain" and "S256".',[hg]:"Both params: code_challenge and code_challenge_method are to be passed if to be sent in the request",[fg]:"Invalid cloudDiscoveryMetadata provided. Must be a stringified JSON object containing tenant_discovery_endpoint and metadata fields",[mg]:"Invalid authorityMetadata provided. Must by a stringified JSON object containing authorization_endpoint, token_endpoint, issuer fields.",[gg]:"The provided authority is not a trusted authority. Please include this authority in the knownAuthorities config parameter.",[yg]:"Missing sshJwk in SSH certificate request. A stringified JSON Web Key is required when using the SSH authentication scheme.",[vg]:"Missing sshKid in SSH certificate request. A string that uniquely identifies the public SSH key is required when using the SSH authentication scheme.",[bg]:"Unable to find an authentication header containing server nonce. Either the Authentication-Info or WWW-Authenticate headers must be present in order to obtain a server nonce.",[wg]:"Invalid authentication header provided",[_g]:"Cannot set OIDCOptions parameter. Please change the protocol mode to OIDC or use a non-Microsoft authority.",[xg]:"Cannot set allowNativeBroker parameter to true when not in AAD protocol mode.",[Sg]:"Authority mismatch error. Authority provided in login request or PublicClientApplication config does not match the environment of the provided account. Please use a matching account or make an interactive request to login to this authority."};class Eg extends Um{constructor(e){super(e,kg[e]),this.name="ClientConfigurationError",Object.setPrototypeOf(this,Eg.prototype)}}function Tg(e){return new Eg(e)} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Bg{static isEmptyObj(e){if(e)try{const t=JSON.parse(e);return 0===Object.keys(t).length}catch(e){}return!0}static startsWith(e,t){return 0===e.indexOf(t)}static endsWith(e,t){return e.length>=t.length&&e.lastIndexOf(t)===e.length-t.length}static queryStringToObject(e){const t={},r=e.split("&"),i=e=>decodeURIComponent(e.replace(/\+/g," "));return r.forEach((e=>{if(e.trim()){const[r,n]=e.split(/=(.+)/g,2);r&&n&&(t[i(r)]=i(n))}})),t}static trimArrayEntries(e){return e.map((e=>e.trim()))}static removeEmptyStringsFromArray(e){return e.filter((e=>!!e))}static jsonParseHelper(e){try{return JSON.parse(e)}catch(e){return null}}static matchPattern(e,t){return new RegExp(e.replace(/\\/g,"\\\\").replace(/\*/g,"[^ ]*").replace(/\?/g,"\\?")).test(t)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Cg="client_info_decoding_error",Ig="client_info_empty_error",Ag="token_parsing_error",Fg="null_or_empty_token",Mg="endpoints_resolution_error",Dg="network_error",Rg="openid_config_error",Pg="hash_not_deserialized",Og="invalid_state",zg="state_mismatch",Ng="state_not_found",qg="nonce_mismatch",Ug="auth_time_not_found",Lg="max_age_transpired",jg="multiple_matching_tokens",Hg="multiple_matching_accounts",$g="multiple_matching_appMetadata",Gg="request_cannot_be_made",Wg="cannot_remove_empty_scope",Kg="cannot_append_scopeset",Vg="empty_input_scopeset",Jg="device_code_polling_cancelled",Yg="device_code_expired",Qg="device_code_unknown_error",Zg="no_account_in_silent_request",Xg="invalid_cache_record",ey="invalid_cache_environment",ty="no_account_found",ry="no_crypto_object",iy="unexpected_credential_type",ny="invalid_assertion",oy="invalid_client_credential",sy="token_refresh_required",ay="user_timeout_reached",ly="token_claims_cnf_required_for_signedjwt",dy="authorization_code_missing_from_server_response",cy="binding_key_not_removed",uy="end_session_endpoint_not_supported",py="key_id_missing",hy="no_network_connectivity",fy="user_canceled",my="missing_tenant_id_error",gy="method_not_implemented",yy="nested_app_auth_bridge_disabled",vy={[Cg]:"The client info could not be parsed/decoded correctly",[Ig]:"The client info was empty",[Ag]:"Token cannot be parsed",[Fg]:"The token is null or empty",[Mg]:"Endpoints cannot be resolved",[Dg]:"Network request failed",[Rg]:"Could not retrieve endpoints. Check your authority and verify the .well-known/openid-configuration endpoint returns the required endpoints.",[Pg]:"The hash parameters could not be deserialized",[Og]:"State was not the expected format",[zg]:"State mismatch error",[Ng]:"State not found",[qg]:"Nonce mismatch error",[Ug]:"Max Age was requested and the ID token is missing the auth_time variable. auth_time is an optional claim and is not enabled by default - it must be enabled. See https://aka.ms/msaljs/optional-claims for more information.",[Lg]:"Max Age is set to 0, or too much time has elapsed since the last end-user authentication.",[jg]:"The cache contains multiple tokens satisfying the requirements. Call AcquireToken again providing more requirements such as authority or account.",[Hg]:"The cache contains multiple accounts satisfying the given parameters. Please pass more info to obtain the correct account",[$g]:"The cache contains multiple appMetadata satisfying the given parameters. Please pass more info to obtain the correct appMetadata",[Gg]:"Token request cannot be made without authorization code or refresh token.",[Wg]:"Cannot remove null or empty scope from ScopeSet",[Kg]:"Cannot append ScopeSet",[Vg]:"Empty input ScopeSet cannot be processed",[Jg]:"Caller has cancelled token endpoint polling during device code flow by setting DeviceCodeRequest.cancel = true.",[Yg]:"Device code is expired.",[Qg]:"Device code stopped polling for unknown reasons.",[Zg]:"Please pass an account object, silent flow is not supported without account information",[Xg]:"Cache record object was null or undefined.",[ey]:"Invalid environment when attempting to create cache entry",[ty]:"No account found in cache for given key.",[ry]:"No crypto object detected.",[iy]:"Unexpected credential type.",[ny]:"Client assertion must meet requirements described in https://tools.ietf.org/html/rfc7515",[oy]:"Client credential (secret, certificate, or assertion) must not be empty when creating a confidential client. An application should at most have one credential",[sy]:"Cannot return token from cache because it must be refreshed. This may be due to one of the following reasons: forceRefresh parameter is set to true, claims have been requested, there is no cached access token or it is expired.",[ay]:"User defined timeout for device code polling reached",[ly]:"Cannot generate a POP jwt if the token_claims are not populated",[dy]:"Server response does not contain an authorization code to proceed",[cy]:"Could not remove the credential's binding key from storage.",[uy]:"The provided authority does not support logout",[py]:"A keyId value is missing from the requested bound token's cache record and is required to match the token to it's stored binding key.",[hy]:"No network connectivity. Check your internet connection.",[fy]:"User cancelled the flow.",[my]:"A tenant id - not common, organizations, or consumers - must be specified when using the client_credentials flow.",[gy]:"This method has not been implemented",[yy]:"The nested app auth bridge is disabled"};class by extends Um{constructor(e,t){super(e,t?`${vy[e]}: ${t}`:vy[e]),this.name="ClientAuthError",Object.setPrototypeOf(this,by.prototype)}}function wy(e,t){return new by(e,t)}function _y(e){if(!e||e.indexOf("=")<0)return null;try{const t= +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function(e){return e.startsWith("#/")?e.substring(2):e.startsWith("#")||e.startsWith("?")?e.substring(1):e}(e),r=Object.fromEntries(new URLSearchParams(t));if(r.code||r.error||r.error_description||r.state)return r}catch(e){throw wy(Pg)}return null} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class xy{get urlString(){return this._urlString}constructor(e){if(this._urlString=e,!this._urlString)throw Tg(sg);e.includes("#")||(this._urlString=xy.canonicalizeUri(e))}static canonicalizeUri(e){if(e){let t=e.toLowerCase();return Bg.endsWith(t,"?")?t=t.slice(0,-1):Bg.endsWith(t,"?/")&&(t=t.slice(0,-2)),Bg.endsWith(t,"/")||(t+="/"),t}return e}validateAsUri(){let e;try{e=this.getUrlComponents()}catch(e){throw Tg(og)}if(!e.HostNameAndPort||!e.PathSegments)throw Tg(og);if(!e.Protocol||"https:"!==e.Protocol.toLowerCase())throw Tg(ng)}static appendQueryString(e,t){return t?e.indexOf("?")<0?`${e}?${t}`:`${e}&${t}`:e}static removeHashFromUrl(e){return xy.canonicalizeUri(e.split("#")[0])}replaceTenantPath(e){const t=this.getUrlComponents(),r=t.PathSegments;return!e||0===r.length||r[0]!==df.COMMON&&r[0]!==df.ORGANIZATIONS||(r[0]=e),xy.constructAuthorityUriFromObject(t)}getUrlComponents(){const e=RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"),t=this.urlString.match(e);if(!t)throw Tg(og);const r={Protocol:t[1],HostNameAndPort:t[4],AbsolutePath:t[5],QueryString:t[7]};let i=r.AbsolutePath.split("/");return i=i.filter((e=>e&&e.length>0)),r.PathSegments=i,r.QueryString&&r.QueryString.endsWith("/")&&(r.QueryString=r.QueryString.substring(0,r.QueryString.length-1)),r}static getDomainFromUrl(e){const t=RegExp("^([^:/?#]+://)?([^/?#]*)"),r=e.match(t);if(!r)throw Tg(og);return r[2]}static getAbsoluteUrl(e,t){if(e[0]===Gh.FORWARD_SLASH){const r=new xy(t).getUrlComponents();return r.Protocol+"//"+r.HostNameAndPort+e}return e}static constructAuthorityUriFromObject(e){return new xy(e.Protocol+"//"+e.HostNameAndPort+"/"+e.PathSegments.join("/"))}static hashContainsKnownProperties(e){return!!_y(e)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Sy={"login.microsoftonline.com":{token_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.com/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.com/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/logout"},"login.chinacloudapi.cn":{token_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.chinacloudapi.cn/{tenantid}/discovery/v2.0/keys",issuer:"https://login.partner.microsoftonline.cn/{tenantid}/v2.0",authorization_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/logout"},"login.microsoftonline.us":{token_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.us/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.us/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/logout"}},ky={tenant_discovery_endpoint:"https://{canonicalAuthority}/v2.0/.well-known/openid-configuration",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},Ey=new Set;function Ty(e,t,r,i){if(i?.trace(`getAliasesFromMetadata called with source: ${r}`),e&&t){const n=By(t,e);if(n)return i?.trace(`getAliasesFromMetadata: found cloud discovery metadata in ${r}, returning aliases`),n.aliases;i?.trace(`getAliasesFromMetadata: did not find cloud discovery metadata in ${r}`)}return null}function By(e,t){for(let r=0;r{e.aliases.forEach((e=>{Ey.add(e)}))})); +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Cy="AAD",Iy="OIDC",Ay="none"; +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Fy="refreshTokenClientExecutePostToTokenEndpoint",My="authorizationCodeClientExecutePostToTokenEndpoint",Dy="refreshTokenClientExecuteTokenRequest",Ry="refreshTokenClientAcquireToken",Py="refreshTokenClientAcquireTokenWithCachedRefreshToken",Oy="refreshTokenClientAcquireTokenByRefreshToken",zy="refreshTokenClientCreateTokenRequestBody",Ny="silentFlowClientAcquireCachedToken",qy="silentFlowClientGenerateResultFromCacheRecord",Uy="getAuthCodeUrl",Ly="updateTokenEndpointAuthority",jy="authClientAcquireToken",Hy="authClientExecuteTokenRequest",$y="authClientCreateTokenRequestBody",Gy="authClientCreateQueryString",Wy="popTokenGenerateCnf",Ky="popTokenGenerateKid",Vy="handleServerTokenResponse",Jy="authorityFactoryCreateDiscoveredInstance",Yy="authorityResolveEndpointsAsync",Qy="authorityGetCloudDiscoveryMetadataFromNetwork",Zy="authorityUpdateCloudDiscoveryMetadata",Xy="authorityGetEndpointMetadataFromNetwork",ev="authorityUpdateEndpointMetadata",tv="authorityUpdateMetadataWithRegionalInformation",rv="regionDiscoveryDetectRegion",iv="regionDiscoveryGetRegionFromIMDS",nv="regionDiscoveryGetCurrentVersion",ov="cacheManagerGetRefreshToken",sv=(new Map([["acquireTokenByCode","ATByCode"],["acquireTokenByRefreshToken","ATByRT"],["acquireTokenSilent","ATS"],["acquireTokenSilentAsync","ATSAsync"],["acquireTokenPopup","ATPopup"],["acquireTokenRedirect","ATRedirect"],["cryptoOptsGetPublicKeyThumbprint","CryptoGetPKThumb"],["cryptoOptsSignJwt","CryptoSignJwt"],["silentCacheClientAcquireToken","SltCacheClientAT"],["silentIframeClientAcquireToken","SltIframeClientAT"],["silentRefreshClientAcquireToken","SltRClientAT"],["ssoSilent","SsoSlt"],["standardInteractionClientGetDiscoveredAuthority","StdIntClientGetDiscAuth"],["fetchAccountIdWithNativeBroker","FetchAccIdWithNtvBroker"],["nativeInteractionClientAcquireToken","NtvIntClientAT"],["baseClientCreateTokenRequestHeaders","BaseClientCreateTReqHead"],[Fy,"RTClientExecPost"],[My,"AuthCodeClientExecPost"],["brokerHandshake","BrokerHandshake"],["acquireTokenByRefreshTokenInBroker","ATByRTInBroker"],["acquireTokenByBroker","ATByBroker"],[Dy,"RTClientExecTReq"],[Ry,"RTClientAT"],[Py,"RTClientATWithCachedRT"],[Oy,"RTClientATByRT"],[zy,"RTClientCreateTReqBody"],["acquireTokenFromCache","ATFromCache"],[Ny,"SltFlowClientATCached"],[qy,"SltFlowClientGenResFromCache"],["acquireTokenBySilentIframe","ATBySltIframe"],["initializeBaseRequest","InitBaseReq"],["initializeSilentRequest","InitSltReq"],["initializeClientApplication","InitClientApplication"],["silentIframeClientTokenHelper","SIClientTHelper"],["silentHandlerInitiateAuthRequest","SHandlerInitAuthReq"],["silentHandlerMonitorIframeForHash","SltHandlerMonitorIframeForHash"],["silentHandlerLoadFrame","SHandlerLoadFrame"],["silentHandlerLoadFrameSync","SHandlerLoadFrameSync"],["standardInteractionClientCreateAuthCodeClient","StdIntClientCreateAuthCodeClient"],["standardInteractionClientGetClientConfiguration","StdIntClientGetClientConf"],["standardInteractionClientInitializeAuthorizationRequest","StdIntClientInitAuthReq"],["standardInteractionClientInitializeAuthorizationCodeRequest","StdIntClientInitAuthCodeReq"],[Uy,"GetAuthCodeUrl"],["handleCodeResponseFromServer","HandleCodeResFromServer"],["handleCodeResponse","HandleCodeResp"],[Ly,"UpdTEndpointAuth"],[jy,"AuthClientAT"],[Hy,"AuthClientExecTReq"],[$y,"AuthClientCreateTReqBody"],[Gy,"AuthClientCreateQueryStr"],[Wy,"PopTGenCnf"],[Ky,"PopTGenKid"],[Vy,"HandleServerTRes"],["deserializeResponse","DeserializeRes"],[Jy,"AuthFactCreateDiscInst"],[Yy,"AuthResolveEndpointsAsync"],["authorityResolveEndpointsFromLocalSources","AuthResolveEndpointsFromLocal"],[Qy,"AuthGetCDMetaFromNet"],[Zy,"AuthUpdCDMeta"],[Xy,"AuthUpdCDMetaFromNet"],[ev,"AuthUpdEndpointMeta"],[tv,"AuthUpdMetaWithRegInfo"],[rv,"RegDiscDetectReg"],[iv,"RegDiscGetRegFromIMDS"],[nv,"RegDiscGetCurrentVer"],["acquireTokenByCodeAsync","ATByCodeAsync"],["getEndpointMetadataFromNetwork","GetEndpointMetaFromNet"],["getCloudDiscoveryMetadataFromNetworkMeasurement","GetCDMetaFromNet"],["handleRedirectPromise","HandleRedirectPromise"],["handleNativeRedirectPromise","HandleNtvRedirectPromise"],["updateCloudDiscoveryMetadataMeasurement","UpdateCDMeta"],["usernamePasswordClientAcquireToken","UserPassClientAT"],["nativeMessageHandlerHandshake","NtvMsgHandlerHandshake"],["nativeGenerateAuthResult","NtvGenAuthRes"],["removeHiddenIframe","RemoveHiddenIframe"],["clearTokensAndKeysWithClaims","ClearTAndKeysWithClaims"],[ov,"CacheManagerGetRT"],["generatePkceCodes","GenPkceCodes"],["generateCodeVerifier","GenCodeVerifier"],["generateCodeChallengeFromVerifier","GenCodeChallengeFromVerifier"],["sha256Digest","Sha256Digest"],["getRandomValues","GetRandomValues"]]),new Set(["accessTokenSize","durationMs","idTokenSize","matsSilentStatus","matsHttpStatus","refreshTokenSize","queuedTimeMs","startTimeMs","status","multiMatchedAT","multiMatchedID","multiMatchedRT"]),(e,t,r,i,n)=>(...o)=>{r.trace(`Executing function ${t}`);const s=i?.startMeasurement(t,n);if(n){const e=t+"CallCount";i?.incrementFields({[e]:1},n)}return i?.setPreQueueTime(t,n),e(...o).then((e=>(r.trace(`Returning result from ${t}`),s?.end({success:!0}),e))).catch((e=>{r.trace(`Error occurred in ${t}`);try{r.trace(JSON.stringify(e))}catch(e){r.trace("Unable to print error message.")}throw s?.end({success:!1},e),e}))}); +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class av{constructor(e,t,r,i){this.networkInterface=e,this.logger=t,this.performanceClient=r,this.correlationId=i}async detectRegion(e,t){this.performanceClient?.addQueueMeasurement(rv,this.correlationId);let r=e;if(r)t.region_source=Wf;else{const e=av.IMDS_OPTIONS;try{const i=await sv(this.getRegionFromIMDS.bind(this),iv,this.logger,this.performanceClient,this.correlationId)(Gh.IMDS_VERSION,e);if(i.status===Hf&&(r=i.body,t.region_source=Kf),i.status===$f){const i=await sv(this.getCurrentVersion.bind(this),nv,this.logger,this.performanceClient,this.correlationId)(e);if(!i)return t.region_source=Gf,null;const n=await sv(this.getRegionFromIMDS.bind(this),iv,this.logger,this.performanceClient,this.correlationId)(i,e);n.status===Hf&&(r=n.body,t.region_source=Kf)}}catch(e){return t.region_source=Gf,null}}return r||(t.region_source=Gf),r||null}async getRegionFromIMDS(e,t){return this.performanceClient?.addQueueMeasurement(iv,this.correlationId),this.networkInterface.sendGetRequestAsync(`${Gh.IMDS_ENDPOINT}?api-version=${e}&format=text`,t,Gh.IMDS_TIMEOUT)}async getCurrentVersion(e){this.performanceClient?.addQueueMeasurement(nv,this.correlationId);try{const t=await this.networkInterface.sendGetRequestAsync(`${Gh.IMDS_ENDPOINT}?format=json`,e);return t.status===$f&&t.body&&t.body["newest-versions"]&&t.body["newest-versions"].length>0?t.body["newest-versions"][0]:null}catch(e){return null}}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function lv(e,t){const r=function(e){if(!e)throw wy(Fg);const t=/^([^\.\s]*)\.([^\.\s]+)\.([^\.\s]*)$/.exec(e);if(!t||t.length<4)throw wy(Ag);return t[2]}(e);try{const e=t(r);return JSON.parse(e)}catch(e){throw wy(Ag)}}function dv(e,t){if(0===t||Date.now()-3e5>e+t)throw wy(Lg)} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function cv(){return Math.round((new Date).getTime()/1e3)}function uv(e,t){const r=Number(e)||0;return cv()+t>r}function pv(e,t){return new Promise((r=>setTimeout((()=>r(t)),e)))} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function hv(e){return[vv(e),bv(e),wv(e),_v(e),xv(e)].join(xf).toLowerCase()}function fv(e){return e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("credentialType")&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("secret")}function mv(e){return!!e&&(fv(e)&&e.hasOwnProperty("realm")&&e.hasOwnProperty("target")&&(e.credentialType===kf.ACCESS_TOKEN||e.credentialType===kf.ACCESS_TOKEN_WITH_AUTH_SCHEME))}function gv(e){return!!e&&(fv(e)&&e.hasOwnProperty("realm")&&e.credentialType===kf.ID_TOKEN)}function yv(e){return!!e&&(fv(e)&&e.credentialType===kf.REFRESH_TOKEN)}function vv(e){return[e.homeAccountId,e.environment].join(xf).toLowerCase()}function bv(e){const t=e.credentialType===kf.REFRESH_TOKEN&&e.familyId||e.clientId;return[e.credentialType,t,e.realm||""].join(xf).toLowerCase()}function wv(e){return(e.target||"").toLowerCase()}function _v(e){return(e.requestedClaimsHash||"").toLowerCase()}function xv(e){return e.tokenType&&e.tokenType.toLowerCase()!==Rf.BEARER.toLowerCase()?e.tokenType.toLowerCase():""}function Sv(e,t){return!!t&&(0===e.indexOf(Ef)&&t.hasOwnProperty("clientId")&&t.hasOwnProperty("environment"))}function kv(){return cv()+Cf}function Ev(e,t,r){e.authorization_endpoint=t.authorization_endpoint,e.token_endpoint=t.token_endpoint,e.end_session_endpoint=t.end_session_endpoint,e.issuer=t.issuer,e.endpointsFromNetwork=r,e.jwks_uri=t.jwks_uri}function Tv(e,t,r){e.aliases=t.aliases,e.preferred_cache=t.preferred_cache,e.preferred_network=t.preferred_network,e.aliasesFromNetwork=r}function Bv(e){return e.expiresAt<=cv()}av.IMDS_OPTIONS={headers:{Metadata:"true"}}; +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Cv{constructor(e,t,r,i,n,o,s,a){this.canonicalAuthority=e,this._canonicalAuthority.validateAsUri(),this.networkInterface=t,this.cacheManager=r,this.authorityOptions=i,this.regionDiscoveryMetadata={region_used:void 0,region_source:void 0,region_outcome:void 0},this.logger=n,this.performanceClient=s,this.correlationId=o,this.managedIdentity=a||!1,this.regionDiscovery=new av(t,this.logger,this.performanceClient,this.correlationId)}getAuthorityType(e){if(e.HostNameAndPort.endsWith(Gh.CIAM_AUTH_URL))return tg;const t=e.PathSegments;if(t.length)switch(t[0].toLowerCase()){case Gh.ADFS:return Xm;case Gh.DSTS:return eg}return Zm}get authorityType(){return this.getAuthorityType(this.canonicalAuthorityUrlComponents)}get protocolMode(){return this.authorityOptions.protocolMode}get options(){return this.authorityOptions}get canonicalAuthority(){return this._canonicalAuthority.urlString}set canonicalAuthority(e){this._canonicalAuthority=new xy(e),this._canonicalAuthority.validateAsUri(),this._canonicalAuthorityUrlComponents=null}get canonicalAuthorityUrlComponents(){return this._canonicalAuthorityUrlComponents||(this._canonicalAuthorityUrlComponents=this._canonicalAuthority.getUrlComponents()),this._canonicalAuthorityUrlComponents}get hostnameAndPort(){return this.canonicalAuthorityUrlComponents.HostNameAndPort.toLowerCase()}get tenant(){return this.canonicalAuthorityUrlComponents.PathSegments[0]}get authorizationEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.authorization_endpoint);throw wy(Mg)}get tokenEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint);throw wy(Mg)}get deviceCodeEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint.replace("/token","/devicecode"));throw wy(Mg)}get endSessionEndpoint(){if(this.discoveryComplete()){if(!this.metadata.end_session_endpoint)throw wy(uy);return this.replacePath(this.metadata.end_session_endpoint)}throw wy(Mg)}get selfSignedJwtAudience(){if(this.discoveryComplete())return this.replacePath(this.metadata.issuer);throw wy(Mg)}get jwksUri(){if(this.discoveryComplete())return this.replacePath(this.metadata.jwks_uri);throw wy(Mg)}canReplaceTenant(e){return 1===e.PathSegments.length&&!Cv.reservedTenantDomains.has(e.PathSegments[0])&&this.getAuthorityType(e)===Zm&&this.protocolMode===Cy}replaceTenant(e){return e.replace(/{tenant}|{tenantid}/g,this.tenant)}replacePath(e){let t=e;const r=new xy(this.metadata.canonical_authority).getUrlComponents(),i=r.PathSegments;return this.canonicalAuthorityUrlComponents.PathSegments.forEach(((e,n)=>{let o=i[n];if(0===n&&this.canReplaceTenant(r)){const e=new xy(this.metadata.authorization_endpoint).getUrlComponents().PathSegments[0];o!==e&&(this.logger.verbose(`Replacing tenant domain name ${o} with id ${e}`),o=e)}e!==o&&(t=t.replace(`/${o}/`,`/${e}/`))})),this.replaceTenant(t)}get defaultOpenIdConfigurationEndpoint(){const e=this.hostnameAndPort;return this.canonicalAuthority.endsWith("v2.0/")||this.authorityType===Xm||this.protocolMode!==Cy&&!this.isAliasOfKnownMicrosoftAuthority(e)?`${this.canonicalAuthority}.well-known/openid-configuration`:`${this.canonicalAuthority}v2.0/.well-known/openid-configuration`}discoveryComplete(){return!!this.metadata}async resolveEndpointsAsync(){this.performanceClient?.addQueueMeasurement(Yy,this.correlationId);const e=this.getCurrentMetadataEntity(),t=await sv(this.updateCloudDiscoveryMetadata.bind(this),Zy,this.logger,this.performanceClient,this.correlationId)(e);this.canonicalAuthority=this.canonicalAuthority.replace(this.hostnameAndPort,e.preferred_network);const r=await sv(this.updateEndpointMetadata.bind(this),ev,this.logger,this.performanceClient,this.correlationId)(e);this.updateCachedMetadata(e,t,{source:r}),this.performanceClient?.addFields({cloudDiscoverySource:t,authorityEndpointSource:r},this.correlationId)}getCurrentMetadataEntity(){let e=this.cacheManager.getAuthorityMetadataByAlias(this.hostnameAndPort);return e||(e={aliases:[],preferred_cache:this.hostnameAndPort,preferred_network:this.hostnameAndPort,canonical_authority:this.canonicalAuthority,authorization_endpoint:"",token_endpoint:"",end_session_endpoint:"",issuer:"",aliasesFromNetwork:!1,endpointsFromNetwork:!1,expiresAt:kv(),jwks_uri:""}),e}updateCachedMetadata(e,t,r){t!==Af&&r?.source!==Af&&(e.expiresAt=kv(),e.canonical_authority=this.canonicalAuthority);const i=this.cacheManager.generateAuthorityMetadataCacheKey(e.preferred_cache);this.cacheManager.setAuthorityMetadata(i,e),this.metadata=e}async updateEndpointMetadata(e){this.performanceClient?.addQueueMeasurement(ev,this.correlationId);const t=this.updateEndpointMetadataFromLocalSources(e);if(t){if(t.source===Mf&&this.authorityOptions.azureRegionConfiguration?.azureRegion&&t.metadata){Ev(e,await sv(this.updateMetadataWithRegionalInformation.bind(this),tv,this.logger,this.performanceClient,this.correlationId)(t.metadata),!1),e.canonical_authority=this.canonicalAuthority}return t.source}let r=await sv(this.getEndpointMetadataFromNetwork.bind(this),Xy,this.logger,this.performanceClient,this.correlationId)();if(r)return this.authorityOptions.azureRegionConfiguration?.azureRegion&&(r=await sv(this.updateMetadataWithRegionalInformation.bind(this),tv,this.logger,this.performanceClient,this.correlationId)(r)),Ev(e,r,!0),Ff;throw wy(Rg,this.defaultOpenIdConfigurationEndpoint)}updateEndpointMetadataFromLocalSources(e){this.logger.verbose("Attempting to get endpoint metadata from authority configuration");const t=this.getEndpointMetadataFromConfig();if(t)return this.logger.verbose("Found endpoint metadata in authority configuration"),Ev(e,t,!1),{source:If};if(this.logger.verbose("Did not find endpoint metadata in the config... Attempting to get endpoint metadata from the hardcoded values."),this.authorityOptions.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get endpoint metadata from the network metadata cache.");else{const t=this.getEndpointMetadataFromHardcodedValues();if(t)return Ev(e,t,!1),{source:Mf,metadata:t};this.logger.verbose("Did not find endpoint metadata in hardcoded values... Attempting to get endpoint metadata from the network metadata cache.")}const r=Bv(e);return this.isAuthoritySameType(e)&&e.endpointsFromNetwork&&!r?(this.logger.verbose("Found endpoint metadata in the cache."),{source:Af}):(r&&this.logger.verbose("The metadata entity is expired."),null)}isAuthoritySameType(e){return new xy(e.canonical_authority).getUrlComponents().PathSegments.length===this.canonicalAuthorityUrlComponents.PathSegments.length}getEndpointMetadataFromConfig(){if(this.authorityOptions.authorityMetadata)try{return JSON.parse(this.authorityOptions.authorityMetadata)}catch(e){throw Tg(mg)}return null}async getEndpointMetadataFromNetwork(){this.performanceClient?.addQueueMeasurement(Xy,this.correlationId);const e={},t=this.defaultOpenIdConfigurationEndpoint;this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: attempting to retrieve OAuth endpoints from ${t}`);try{const r=await this.networkInterface.sendGetRequestAsync(t,e),i= +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function(e){return e.hasOwnProperty("authorization_endpoint")&&e.hasOwnProperty("token_endpoint")&&e.hasOwnProperty("issuer")&&e.hasOwnProperty("jwks_uri")}(r.body);return i?r.body:(this.logger.verbose("Authority.getEndpointMetadataFromNetwork: could not parse response as OpenID configuration"),null)}catch(e){return this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: ${e}`),null}}getEndpointMetadataFromHardcodedValues(){return this.hostnameAndPort in Sy?Sy[this.hostnameAndPort]:null}async updateMetadataWithRegionalInformation(e){this.performanceClient?.addQueueMeasurement(tv,this.correlationId);const t=this.authorityOptions.azureRegionConfiguration?.azureRegion;if(t){if(t!==Gh.AZURE_REGION_AUTO_DISCOVER_FLAG)return this.regionDiscoveryMetadata.region_outcome=Vf,this.regionDiscoveryMetadata.region_used=t,Cv.replaceWithRegionalInformation(e,t);const r=await sv(this.regionDiscovery.detectRegion.bind(this.regionDiscovery),rv,this.logger,this.performanceClient,this.correlationId)(this.authorityOptions.azureRegionConfiguration?.environmentRegion,this.regionDiscoveryMetadata);if(r)return this.regionDiscoveryMetadata.region_outcome=Jf,this.regionDiscoveryMetadata.region_used=r,Cv.replaceWithRegionalInformation(e,r);this.regionDiscoveryMetadata.region_outcome=Yf}return e}async updateCloudDiscoveryMetadata(e){this.performanceClient?.addQueueMeasurement(Zy,this.correlationId);const t=this.updateCloudDiscoveryMetadataFromLocalSources(e);if(t)return t;const r=await sv(this.getCloudDiscoveryMetadataFromNetwork.bind(this),Qy,this.logger,this.performanceClient,this.correlationId)();if(r)return Tv(e,r,!0),Ff;throw Tg(gg)}updateCloudDiscoveryMetadataFromLocalSources(e){this.logger.verbose("Attempting to get cloud discovery metadata from authority configuration"),this.logger.verbosePii(`Known Authorities: ${this.authorityOptions.knownAuthorities||Gh.NOT_APPLICABLE}`),this.logger.verbosePii(`Authority Metadata: ${this.authorityOptions.authorityMetadata||Gh.NOT_APPLICABLE}`),this.logger.verbosePii(`Canonical Authority: ${e.canonical_authority||Gh.NOT_APPLICABLE}`);const t=this.getCloudDiscoveryMetadataFromConfig();if(t)return this.logger.verbose("Found cloud discovery metadata in authority configuration"),Tv(e,t,!1),If;if(this.logger.verbose("Did not find cloud discovery metadata in the config... Attempting to get cloud discovery metadata from the hardcoded values."),this.options.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded cloud discovery metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get cloud discovery metadata from the network metadata cache.");else{const t=(r=this.hostnameAndPort,By(ky.metadata,r));if(t)return this.logger.verbose("Found cloud discovery metadata from hardcoded values."),Tv(e,t,!1),Mf;this.logger.verbose("Did not find cloud discovery metadata in hardcoded values... Attempting to get cloud discovery metadata from the network metadata cache.")}var r;const i=Bv(e);return this.isAuthoritySameType(e)&&e.aliasesFromNetwork&&!i?(this.logger.verbose("Found cloud discovery metadata in the cache."),Af):(i&&this.logger.verbose("The metadata entity is expired."),null)}getCloudDiscoveryMetadataFromConfig(){if(this.authorityType===tg)return this.logger.verbose("CIAM authorities do not support cloud discovery metadata, generate the aliases from authority host."),Cv.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort);if(this.authorityOptions.cloudDiscoveryMetadata){this.logger.verbose("The cloud discovery metadata has been provided as a network response, in the config.");try{this.logger.verbose("Attempting to parse the cloud discovery metadata.");const e=By(JSON.parse(this.authorityOptions.cloudDiscoveryMetadata).metadata,this.hostnameAndPort);if(this.logger.verbose("Parsed the cloud discovery metadata."),e)return this.logger.verbose("There is returnable metadata attached to the parsed cloud discovery metadata."),e;this.logger.verbose("There is no metadata attached to the parsed cloud discovery metadata.")}catch(e){throw this.logger.verbose("Unable to parse the cloud discovery metadata. Throwing Invalid Cloud Discovery Metadata Error."),Tg(fg)}}return this.isInKnownAuthorities()?(this.logger.verbose("The host is included in knownAuthorities. Creating new cloud discovery metadata from the host."),Cv.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)):null}async getCloudDiscoveryMetadataFromNetwork(){this.performanceClient?.addQueueMeasurement(Qy,this.correlationId);const e=`${Gh.AAD_INSTANCE_DISCOVERY_ENDPT}${this.canonicalAuthority}oauth2/v2.0/authorize`,t={};let r=null;try{const i=await this.networkInterface.sendGetRequestAsync(e,t);let n,o;if( +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function(e){return e.hasOwnProperty("tenant_discovery_endpoint")&&e.hasOwnProperty("metadata")}(i.body))n=i.body,o=n.metadata,this.logger.verbosePii(`tenant_discovery_endpoint is: ${n.tenant_discovery_endpoint}`);else{if(! +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function(e){return e.hasOwnProperty("error")&&e.hasOwnProperty("error_description")}(i.body))return this.logger.error("AAD did not return a CloudInstanceDiscoveryResponse or CloudInstanceDiscoveryErrorResponse"),null;if(this.logger.warning(`A CloudInstanceDiscoveryErrorResponse was returned. The cloud instance discovery network request's status code is: ${i.status}`),n=i.body,n.error===Gh.INVALID_INSTANCE)return this.logger.error("The CloudInstanceDiscoveryErrorResponse error is invalid_instance."),null;this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error is ${n.error}`),this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error description is ${n.error_description}`),this.logger.warning("Setting the value of the CloudInstanceDiscoveryMetadata (returned from the network) to []"),o=[]}this.logger.verbose("Attempting to find a match between the developer's authority and the CloudInstanceDiscoveryMetadata returned from the network request."),r=By(o,this.hostnameAndPort)}catch(e){if(e instanceof Um)this.logger.error(`There was a network error while attempting to get the cloud discovery instance metadata.\nError: ${e.errorCode}\nError Description: ${e.errorMessage}`);else{const t=e;this.logger.error(`A non-MSALJS error was thrown while attempting to get the cloud instance discovery metadata.\nError: ${t.name}\nError Description: ${t.message}`)}return null}return r||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),r=Cv.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),r}isInKnownAuthorities(){return this.authorityOptions.knownAuthorities.filter((e=>e&&xy.getDomainFromUrl(e).toLowerCase()===this.hostnameAndPort)).length>0}static generateAuthority(e,t){let r;if(t&&t.azureCloudInstance!==Ay){const e=t.tenant?t.tenant:Gh.DEFAULT_COMMON_TENANT;r=`${t.azureCloudInstance}/${e}/`}return r||e}static createCloudDiscoveryMetadataFromHost(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}}getPreferredCache(){if(this.managedIdentity)return Gh.DEFAULT_AUTHORITY_HOST;if(this.discoveryComplete())return this.metadata.preferred_cache;throw wy(Mg)}isAlias(e){return this.metadata.aliases.indexOf(e)>-1}isAliasOfKnownMicrosoftAuthority(e){return Ey.has(e)}static isPublicCloudAuthority(e){return Gh.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0}static buildRegionalAuthorityString(e,t,r){const i=new xy(e);i.validateAsUri();const n=i.getUrlComponents();let o=`${t}.${n.HostNameAndPort}`;this.isPublicCloudAuthority(n.HostNameAndPort)&&(o=`${t}.${Gh.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX}`);const s=xy.constructAuthorityUriFromObject({...i.getUrlComponents(),HostNameAndPort:o}).urlString;return r?`${s}?${r}`:s}static replaceWithRegionalInformation(e,t){const r={...e};return r.authorization_endpoint=Cv.buildRegionalAuthorityString(r.authorization_endpoint,t),r.token_endpoint=Cv.buildRegionalAuthorityString(r.token_endpoint,t),r.end_session_endpoint&&(r.end_session_endpoint=Cv.buildRegionalAuthorityString(r.end_session_endpoint,t)),r}static transformCIAMAuthority(e){let t=e;const r=new xy(e).getUrlComponents();if(0===r.PathSegments.length&&r.HostNameAndPort.endsWith(Gh.CIAM_AUTH_URL)){t=`${t}${r.HostNameAndPort.split(".")[0]}${Gh.AAD_TENANT_DOMAIN_SUFFIX}`}return t}}function Iv(e){return e.endsWith(Gh.FORWARD_SLASH)?e:`${e}${Gh.FORWARD_SLASH}`}Cv.reservedTenantDomains=new Set(["{tenant}","{tenantid}",df.COMMON,df.CONSUMERS,df.ORGANIZATIONS]); +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Av={createNewGuid:()=>{throw wy(gy)},base64Decode:()=>{throw wy(gy)},base64Encode:()=>{throw wy(gy)},base64UrlEncode:()=>{throw wy(gy)},encodeKid:()=>{throw wy(gy)},async getPublicKeyThumbprint(){throw wy(gy)},async removeTokenBindingKey(){throw wy(gy)},async clearKeystore(){throw wy(gy)},async signJwt(){throw wy(gy)},async hashString(){throw wy(gy)}},Fv="@azure/msal-common",Mv="14.15.0"; +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Dv{constructor(e){const t=e?Bg.trimArrayEntries([...e]):[],r=t?Bg.removeEmptyStringsFromArray(t):[];this.validateInputScopes(r),this.scopes=new Set,r.forEach((e=>this.scopes.add(e)))}static fromString(e){const t=(e||Gh.EMPTY_STRING).split(" ");return new Dv(t)}static createSearchScopes(e){const t=new Dv(e);return t.containsOnlyOIDCScopes()?t.removeScope(Gh.OFFLINE_ACCESS_SCOPE):t.removeOIDCScopes(),t}validateInputScopes(e){if(!e||e.length<1)throw Tg(ag)}containsScope(e){const t=this.printScopesLowerCase().split(" "),r=new Dv(t);return!!e&&r.scopes.has(e.toLowerCase())}containsScopeSet(e){return!(!e||e.scopes.size<=0)&&(this.scopes.size>=e.scopes.size&&e.asArray().every((e=>this.containsScope(e))))}containsOnlyOIDCScopes(){let e=0;return rf.forEach((t=>{this.containsScope(t)&&(e+=1)})),this.scopes.size===e}appendScope(e){e&&this.scopes.add(e.trim())}appendScopes(e){try{e.forEach((e=>this.appendScope(e)))}catch(e){throw wy(Kg)}}removeScope(e){if(!e)throw wy(Wg);this.scopes.delete(e.trim())}removeOIDCScopes(){rf.forEach((e=>{this.scopes.delete(e)}))}unionScopeSets(e){if(!e)throw wy(Vg);const t=new Set;return e.scopes.forEach((e=>t.add(e.toLowerCase()))),this.scopes.forEach((e=>t.add(e.toLowerCase()))),t}intersectingScopeSets(e){if(!e)throw wy(Vg);e.containsOnlyOIDCScopes()||e.removeOIDCScopes();const t=this.unionScopeSets(e),r=e.getScopeCount(),i=this.getScopeCount();return t.sizee.push(t))),e}printScopes(){if(this.scopes){return this.asArray().join(" ")}return Gh.EMPTY_STRING}printScopesLowerCase(){return this.printScopes().toLowerCase()}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function Rv(e,t){if(!e)throw wy(Ig);try{const r=t(e);return JSON.parse(r)}catch(e){throw wy(Cg)}}function Pv(e){if(!e)throw wy(Cg);const t=e.split(Sf,2);return{uid:t[0],utid:t.length<2?Gh.EMPTY_STRING:t[1]}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function Ov(e,t){return!!e&&!!t&&e===t.split(".")[1]}function zv(e,t,r,i){if(i){const{oid:t,sub:r,tid:n,name:o,tfp:s,acr:a}=i,l=n||s||a||"";return{tenantId:l,localAccountId:t||r||"",name:o,isHomeTenant:Ov(l,e)}}return{tenantId:r,localAccountId:t,isHomeTenant:Ov(r,e)}}function Nv(e,t,r,i){let n=e;if(t){const{isHomeTenant:r,...i}=t;n={...e,...i}}if(r){const{isHomeTenant:t,...o}=zv(e.homeAccountId,e.localAccountId,e.tenantId,r);return n={...n,...o,idTokenClaims:r,idToken:i},n}return n} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function qv(e){if(e){return e.tid||e.tfp||e.acr||null}return null} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Uv{generateAccountId(){return[this.homeAccountId,this.environment].join(xf).toLowerCase()}generateAccountKey(){return Uv.generateAccountCacheKey({homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId})}getAccountInfo(){return{homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId,name:this.name,nativeAccountId:this.nativeAccountId,authorityType:this.authorityType,tenantProfiles:new Map((this.tenantProfiles||[]).map((e=>[e.tenantId,e])))}}isSingleTenant(){return!this.tenantProfiles}static generateAccountCacheKey(e){const t=e.homeAccountId.split(".")[1];return[e.homeAccountId,e.environment||"",t||e.tenantId||""].join(xf).toLowerCase()}static createAccount(e,t,r){const i=new Uv;let n;t.authorityType===Xm?i.authorityType=wf:t.protocolMode===Cy?i.authorityType=bf:i.authorityType=_f,e.clientInfo&&r&&(n=Rv(e.clientInfo,r)),i.clientInfo=e.clientInfo,i.homeAccountId=e.homeAccountId,i.nativeAccountId=e.nativeAccountId;const o=e.environment||t&&t.getPreferredCache();if(!o)throw wy(ey);i.environment=o,i.realm=n?.utid||qv(e.idTokenClaims)||"",i.localAccountId=n?.uid||e.idTokenClaims?.oid||e.idTokenClaims?.sub||"";const s=e.idTokenClaims?.preferred_username||e.idTokenClaims?.upn,a=e.idTokenClaims?.emails?e.idTokenClaims.emails[0]:null;if(i.username=s||a||"",i.name=e.idTokenClaims?.name||"",i.cloudGraphHostName=e.cloudGraphHostName,i.msGraphHost=e.msGraphHost,e.tenantProfiles)i.tenantProfiles=e.tenantProfiles;else{const t=zv(e.homeAccountId,i.localAccountId,i.realm,e.idTokenClaims);i.tenantProfiles=[t]}return i}static createFromAccountInfo(e,t,r){const i=new Uv;return i.authorityType=e.authorityType||_f,i.homeAccountId=e.homeAccountId,i.localAccountId=e.localAccountId,i.nativeAccountId=e.nativeAccountId,i.realm=e.tenantId,i.environment=e.environment,i.username=e.username,i.name=e.name,i.cloudGraphHostName=t,i.msGraphHost=r,i.tenantProfiles=Array.from(e.tenantProfiles?.values()||[]),i}static generateHomeAccountId(e,t,r,i,n){if(t!==Xm&&t!==eg){if(e)try{const t=Rv(e,i.base64Decode);if(t.uid&&t.utid)return`${t.uid}.${t.utid}`}catch(e){}r.warning("No client info in response")}return n?.sub||""}static isAccountEntity(e){return!!e&&(e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("localAccountId")&&e.hasOwnProperty("username")&&e.hasOwnProperty("authorityType"))}static accountInfoIsEqual(e,t,r){if(!e||!t)return!1;let i=!0;if(r){const r=e.idTokenClaims||{},n=t.idTokenClaims||{};i=r.iat===n.iat&&r.nonce===n.nonce}return e.homeAccountId===t.homeAccountId&&e.localAccountId===t.localAccountId&&e.username===t.username&&e.tenantId===t.tenantId&&e.environment===t.environment&&e.nativeAccountId===t.nativeAccountId&&i}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Lv="cache_quota_exceeded",jv="cache_error_unknown",Hv={[Lv]:"Exceeded cache storage capacity.",[jv]:"Unexpected error occurred when using cache storage."};class $v extends Error{constructor(e,t){const r=t||(Hv[e]?Hv[e]:Hv[jv]);super(`${e}: ${r}`),Object.setPrototypeOf(this,$v.prototype),this.name="CacheError",this.errorCode=e,this.errorMessage=r}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Gv{constructor(e,t,r,i){this.clientId=e,this.cryptoImpl=t,this.commonLogger=r.clone(Fv,Mv),this.staticAuthorityOptions=i}getAllAccounts(e){return this.buildTenantProfiles(this.getAccountsFilteredBy(e||{}),e)}getAccountInfoFilteredBy(e){const t=this.getAllAccounts(e);if(t.length>1){return t.sort((e=>e.idTokenClaims?-1:1))[0]}return 1===t.length?t[0]:null}getBaseAccountInfo(e){const t=this.getAccountsFilteredBy(e);return t.length>0?t[0].getAccountInfo():null}buildTenantProfiles(e,t){return e.flatMap((e=>this.getTenantProfilesFromAccountEntity(e,t?.tenantId,t)))}getTenantedAccountInfoByFilter(e,t,r,i){let n,o=null;if(i&&!this.tenantProfileMatchesFilter(r,i))return null;const s=this.getIdToken(e,t,r.tenantId);return s&&(n=lv(s.secret,this.cryptoImpl.base64Decode),!this.idTokenClaimsMatchTenantProfileFilter(n,i))?null:(o=Nv(e,r,n,s?.secret),o)}getTenantProfilesFromAccountEntity(e,t,r){const i=e.getAccountInfo();let n=i.tenantProfiles||new Map;const o=this.getTokenKeys();if(t){const e=n.get(t);if(!e)return[];n=new Map([[t,e]])}const s=[];return n.forEach((e=>{const t=this.getTenantedAccountInfoByFilter(i,o,e,r);t&&s.push(t)})),s}tenantProfileMatchesFilter(e,t){return!(t.localAccountId&&!this.matchLocalAccountIdFromTenantProfile(e,t.localAccountId))&&((!t.name||e.name===t.name)&&(void 0===t.isHomeTenant||e.isHomeTenant===t.isHomeTenant))}idTokenClaimsMatchTenantProfileFilter(e,t){if(t){if(t.localAccountId&&!this.matchLocalAccountIdFromTokenClaims(e,t.localAccountId))return!1;if(t.loginHint&&!this.matchLoginHintFromTokenClaims(e,t.loginHint))return!1;if(t.username&&!this.matchUsername(e.preferred_username,t.username))return!1;if(t.name&&!this.matchName(e,t.name))return!1;if(t.sid&&!this.matchSid(e,t.sid))return!1}return!0}async saveCacheRecord(e,t,r){if(!e)throw wy(Xg);try{e.account&&this.setAccount(e.account),e.idToken&&!1!==t?.idToken&&this.setIdTokenCredential(e.idToken),e.accessToken&&!1!==t?.accessToken&&await this.saveAccessToken(e.accessToken),e.refreshToken&&!1!==t?.refreshToken&&this.setRefreshTokenCredential(e.refreshToken),e.appMetadata&&this.setAppMetadata(e.appMetadata)}catch(e){throw this.commonLogger?.error("CacheManager.saveCacheRecord: failed"),e instanceof Error?(this.commonLogger?.errorPii(`CacheManager.saveCacheRecord: ${e.message}`,r),"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name||e.message.includes("exceeded the quota")?(this.commonLogger?.error("CacheManager.saveCacheRecord: exceeded storage quota",r),new $v(Lv)):new $v(e.name,e.message)):(this.commonLogger?.errorPii(`CacheManager.saveCacheRecord: ${e}`,r),new $v(jv))}}async saveAccessToken(e){const t={clientId:e.clientId,credentialType:e.credentialType,environment:e.environment,homeAccountId:e.homeAccountId,realm:e.realm,tokenType:e.tokenType,requestedClaimsHash:e.requestedClaimsHash},r=this.getTokenKeys(),i=Dv.fromString(e.target),n=[];r.accessToken.forEach((e=>{if(!this.accessTokenKeyMatchesFilter(e,t,!1))return;const r=this.getAccessTokenCredential(e);if(r&&this.credentialMatchesFilter(r,t)){Dv.fromString(r.target).intersectingScopeSets(i)&&n.push(this.removeAccessToken(e))}})),await Promise.all(n),this.setAccessTokenCredential(e)}getAccountsFilteredBy(e){const t=this.getAccountKeys(),r=[];return t.forEach((t=>{if(!this.isAccountKey(t,e.homeAccountId))return;const i=this.getAccount(t,this.commonLogger);if(!i)return;if(e.homeAccountId&&!this.matchHomeAccountId(i,e.homeAccountId))return;if(e.username&&!this.matchUsername(i.username,e.username))return;if(e.environment&&!this.matchEnvironment(i,e.environment))return;if(e.realm&&!this.matchRealm(i,e.realm))return;if(e.nativeAccountId&&!this.matchNativeAccountId(i,e.nativeAccountId))return;if(e.authorityType&&!this.matchAuthorityType(i,e.authorityType))return;const n={localAccountId:e?.localAccountId,name:e?.name},o=i.tenantProfiles?.filter((e=>this.tenantProfileMatchesFilter(e,n)));o&&0===o.length||r.push(i)})),r}isAccountKey(e,t,r){return!(e.split(xf).length<3)&&(!(t&&!e.toLowerCase().includes(t.toLowerCase()))&&!(r&&!e.toLowerCase().includes(r.toLowerCase())))}isCredentialKey(e){if(e.split(xf).length<6)return!1;const t=e.toLowerCase();if(-1===t.indexOf(kf.ID_TOKEN.toLowerCase())&&-1===t.indexOf(kf.ACCESS_TOKEN.toLowerCase())&&-1===t.indexOf(kf.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase())&&-1===t.indexOf(kf.REFRESH_TOKEN.toLowerCase()))return!1;if(t.indexOf(kf.REFRESH_TOKEN.toLowerCase())>-1){const e=`${kf.REFRESH_TOKEN}${xf}${this.clientId}${xf}`,r=`${kf.REFRESH_TOKEN}${xf}${Tf}${xf}`;if(-1===t.indexOf(e.toLowerCase())&&-1===t.indexOf(r.toLowerCase()))return!1}else if(-1===t.indexOf(this.clientId.toLowerCase()))return!1;return!0}credentialMatchesFilter(e,t){if(t.clientId&&!this.matchClientId(e,t.clientId))return!1;if(t.userAssertionHash&&!this.matchUserAssertionHash(e,t.userAssertionHash))return!1;if("string"==typeof t.homeAccountId&&!this.matchHomeAccountId(e,t.homeAccountId))return!1;if(t.environment&&!this.matchEnvironment(e,t.environment))return!1;if(t.realm&&!this.matchRealm(e,t.realm))return!1;if(t.credentialType&&!this.matchCredentialType(e,t.credentialType))return!1;if(t.familyId&&!this.matchFamilyId(e,t.familyId))return!1;if(t.target&&!this.matchTarget(e,t.target))return!1;if((t.requestedClaimsHash||e.requestedClaimsHash)&&e.requestedClaimsHash!==t.requestedClaimsHash)return!1;if(e.credentialType===kf.ACCESS_TOKEN_WITH_AUTH_SCHEME){if(t.tokenType&&!this.matchTokenType(e,t.tokenType))return!1;if(t.tokenType===Rf.SSH&&t.keyId&&!this.matchKeyId(e,t.keyId))return!1}return!0}getAppMetadataFilteredBy(e){const t=this.getKeys(),r={};return t.forEach((t=>{if(!this.isAppMetadata(t))return;const i=this.getAppMetadata(t);i&&(e.environment&&!this.matchEnvironment(i,e.environment)||e.clientId&&!this.matchClientId(i,e.clientId)||(r[t]=i))})),r}getAuthorityMetadataByAlias(e){const t=this.getAuthorityMetadataKeys();let r=null;return t.forEach((t=>{if(!this.isAuthorityMetadata(t)||-1===t.indexOf(this.clientId))return;const i=this.getAuthorityMetadata(t);i&&-1!==i.aliases.indexOf(e)&&(r=i)})),r}async removeAllAccounts(){const e=this.getAccountKeys(),t=[];e.forEach((e=>{t.push(this.removeAccount(e))})),await Promise.all(t)}async removeAccount(e){const t=this.getAccount(e,this.commonLogger);t&&(await this.removeAccountContext(t),this.removeItem(e))}async removeAccountContext(e){const t=this.getTokenKeys(),r=e.generateAccountId(),i=[];t.idToken.forEach((e=>{0===e.indexOf(r)&&this.removeIdToken(e)})),t.accessToken.forEach((e=>{0===e.indexOf(r)&&i.push(this.removeAccessToken(e))})),t.refreshToken.forEach((e=>{0===e.indexOf(r)&&this.removeRefreshToken(e)})),await Promise.all(i)}updateOutdatedCachedAccount(e,t,r){if(t&&t.isSingleTenant()){this.commonLogger?.verbose("updateOutdatedCachedAccount: Found a single-tenant (outdated) account entity in the cache, migrating to multi-tenant account entity");const i=this.getAccountKeys().filter((e=>e.startsWith(t.homeAccountId))),n=[];i.forEach((e=>{const t=this.getCachedAccountEntity(e);t&&n.push(t)}));const o=n.find((e=>Ov(e.realm,e.homeAccountId)))||n[0];o.tenantProfiles=n.map((e=>({tenantId:e.realm,localAccountId:e.localAccountId,name:e.name,isHomeTenant:Ov(e.realm,e.homeAccountId)})));const s=Gv.toObject(new Uv,{...o}),a=s.generateAccountKey();return i.forEach((t=>{t!==a&&this.removeOutdatedAccount(e)})),this.setAccount(s),r?.verbose("Updated an outdated account entity in the cache"),s}return t}async removeAccessToken(e){const t=this.getAccessTokenCredential(e);if(t){if(t.credentialType.toLowerCase()===kf.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase()&&t.tokenType===Rf.POP){const e=t.keyId;if(e)try{await this.cryptoImpl.removeTokenBindingKey(e)}catch(e){throw wy(cy)}}return this.removeItem(e)}}removeAppMetadata(){return this.getKeys().forEach((e=>{this.isAppMetadata(e)&&this.removeItem(e)})),!0}readAccountFromCache(e){const t=Uv.generateAccountCacheKey(e);return this.getAccount(t,this.commonLogger)}getIdToken(e,t,r,i,n){this.commonLogger.trace("CacheManager - getIdToken called");const o={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:kf.ID_TOKEN,clientId:this.clientId,realm:r},s=this.getIdTokensByFilter(o,t),a=s.size;if(a<1)return this.commonLogger.info("CacheManager:getIdToken - No token found"),null;if(a>1){let t=s;if(!r){const r=new Map;s.forEach(((t,i)=>{t.realm===e.tenantId&&r.set(i,t)}));const i=r.size;if(i<1)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account but none match account entity tenant id, returning first result"),s.values().next().value;if(1===i)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account, defaulting to home tenant profile"),r.values().next().value;t=r}return this.commonLogger.info("CacheManager:getIdToken - Multiple matching ID tokens found, clearing them"),t.forEach(((e,t)=>{this.removeIdToken(t)})),i&&n&&i.addFields({multiMatchedID:s.size},n),null}return this.commonLogger.info("CacheManager:getIdToken - Returning ID token"),s.values().next().value}getIdTokensByFilter(e,t){const r=t&&t.idToken||this.getTokenKeys().idToken,i=new Map;return r.forEach((t=>{if(!this.idTokenKeyMatchesFilter(t,{clientId:this.clientId,...e}))return;const r=this.getIdTokenCredential(t);r&&this.credentialMatchesFilter(r,e)&&i.set(t,r)})),i}idTokenKeyMatchesFilter(e,t){const r=e.toLowerCase();return(!t.clientId||-1!==r.indexOf(t.clientId.toLowerCase()))&&(!t.homeAccountId||-1!==r.indexOf(t.homeAccountId.toLowerCase()))}removeIdToken(e){this.removeItem(e)}removeRefreshToken(e){this.removeItem(e)}getAccessToken(e,t,r,i,n,o){this.commonLogger.trace("CacheManager - getAccessToken called");const s=Dv.createSearchScopes(t.scopes),a=t.authenticationScheme||Rf.BEARER,l=a&&a.toLowerCase()!==Rf.BEARER.toLowerCase()?kf.ACCESS_TOKEN_WITH_AUTH_SCHEME:kf.ACCESS_TOKEN,d={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:l,clientId:this.clientId,realm:i||e.tenantId,target:s,tokenType:a,keyId:t.sshKid,requestedClaimsHash:t.requestedClaimsHash},c=r&&r.accessToken||this.getTokenKeys().accessToken,u=[];c.forEach((e=>{if(this.accessTokenKeyMatchesFilter(e,d,!0)){const t=this.getAccessTokenCredential(e);t&&this.credentialMatchesFilter(t,d)&&u.push(t)}}));const p=u.length;return p<1?(this.commonLogger.info("CacheManager:getAccessToken - No token found"),null):p>1?(this.commonLogger.info("CacheManager:getAccessToken - Multiple access tokens found, clearing them"),u.forEach((e=>{this.removeAccessToken(hv(e))})),n&&o&&n.addFields({multiMatchedAT:u.length},o),null):(this.commonLogger.info("CacheManager:getAccessToken - Returning access token"),u[0])}accessTokenKeyMatchesFilter(e,t,r){const i=e.toLowerCase();if(t.clientId&&-1===i.indexOf(t.clientId.toLowerCase()))return!1;if(t.homeAccountId&&-1===i.indexOf(t.homeAccountId.toLowerCase()))return!1;if(t.realm&&-1===i.indexOf(t.realm.toLowerCase()))return!1;if(t.requestedClaimsHash&&-1===i.indexOf(t.requestedClaimsHash.toLowerCase()))return!1;if(t.target){const e=t.target.asArray();for(let t=0;t{if(!this.accessTokenKeyMatchesFilter(t,e,!0))return;const i=this.getAccessTokenCredential(t);i&&this.credentialMatchesFilter(i,e)&&r.push(i)})),r}getRefreshToken(e,t,r,i,n){this.commonLogger.trace("CacheManager - getRefreshToken called");const o=t?Tf:void 0,s={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:kf.REFRESH_TOKEN,clientId:this.clientId,familyId:o},a=r&&r.refreshToken||this.getTokenKeys().refreshToken,l=[];a.forEach((e=>{if(this.refreshTokenKeyMatchesFilter(e,s)){const t=this.getRefreshTokenCredential(e);t&&this.credentialMatchesFilter(t,s)&&l.push(t)}}));const d=l.length;return d<1?(this.commonLogger.info("CacheManager:getRefreshToken - No refresh token found."),null):(d>1&&i&&n&&i.addFields({multiMatchedRT:d},n),this.commonLogger.info("CacheManager:getRefreshToken - returning refresh token"),l[0])}refreshTokenKeyMatchesFilter(e,t){const r=e.toLowerCase();return(!t.familyId||-1!==r.indexOf(t.familyId.toLowerCase()))&&(!(!t.familyId&&t.clientId&&-1===r.indexOf(t.clientId.toLowerCase()))&&(!t.homeAccountId||-1!==r.indexOf(t.homeAccountId.toLowerCase())))}readAppMetadataFromCache(e){const t={environment:e,clientId:this.clientId},r=this.getAppMetadataFilteredBy(t),i=Object.keys(r).map((e=>r[e])),n=i.length;if(n<1)return null;if(n>1)throw wy($g);return i[0]}isAppMetadataFOCI(e){const t=this.readAppMetadataFromCache(e);return!(!t||t.familyId!==Tf)}matchHomeAccountId(e,t){return!("string"!=typeof e.homeAccountId||t!==e.homeAccountId)}matchLocalAccountIdFromTokenClaims(e,t){return t===(e.oid||e.sub)}matchLocalAccountIdFromTenantProfile(e,t){return e.localAccountId===t}matchName(e,t){return!(t.toLowerCase()!==e.name?.toLowerCase())}matchUsername(e,t){return!(!e||"string"!=typeof e||t?.toLowerCase()!==e.toLowerCase())}matchUserAssertionHash(e,t){return!(!e.userAssertionHash||t!==e.userAssertionHash)}matchEnvironment(e,t){if(this.staticAuthorityOptions){const r=function(e,t){let r;const i=e.canonicalAuthority;if(i){const n=new xy(i).getUrlComponents().HostNameAndPort;r=Ty(n,e.cloudDiscoveryMetadata?.metadata,If,t)||Ty(n,ky.metadata,Mf,t)||e.knownAuthorities}return r||[]}(this.staticAuthorityOptions,this.commonLogger);if(r.includes(t)&&r.includes(e.environment))return!0}const r=this.getAuthorityMetadataByAlias(t);return!!(r&&r.aliases.indexOf(e.environment)>-1)}matchCredentialType(e,t){return e.credentialType&&t.toLowerCase()===e.credentialType.toLowerCase()}matchClientId(e,t){return!(!e.clientId||t!==e.clientId)}matchFamilyId(e,t){return!(!e.familyId||t!==e.familyId)}matchRealm(e,t){return!(e.realm?.toLowerCase()!==t.toLowerCase())}matchNativeAccountId(e,t){return!(!e.nativeAccountId||t!==e.nativeAccountId)}matchLoginHintFromTokenClaims(e,t){return e.login_hint===t||(e.preferred_username===t||e.upn===t)}matchSid(e,t){return e.sid===t}matchAuthorityType(e,t){return!(!e.authorityType||t.toLowerCase()!==e.authorityType.toLowerCase())}matchTarget(e,t){if(e.credentialType!==kf.ACCESS_TOKEN&&e.credentialType!==kf.ACCESS_TOKEN_WITH_AUTH_SCHEME||!e.target)return!1;return Dv.fromString(e.target).containsScopeSet(t)}matchTokenType(e,t){return!(!e.tokenType||e.tokenType!==t)}matchKeyId(e,t){return!(!e.keyId||e.keyId!==t)}isAppMetadata(e){return-1!==e.indexOf(Ef)}isAuthorityMetadata(e){return-1!==e.indexOf(Bf)}generateAuthorityMetadataCacheKey(e){return`${Bf}-${this.clientId}-${e}`}static toObject(e,t){for(const r in t)e[r]=t[r];return e}}class Wv extends Gv{setAccount(){throw wy(gy)}getAccount(){throw wy(gy)}getCachedAccountEntity(){throw wy(gy)}setIdTokenCredential(){throw wy(gy)}getIdTokenCredential(){throw wy(gy)}setAccessTokenCredential(){throw wy(gy)}getAccessTokenCredential(){throw wy(gy)}setRefreshTokenCredential(){throw wy(gy)}getRefreshTokenCredential(){throw wy(gy)}setAppMetadata(){throw wy(gy)}getAppMetadata(){throw wy(gy)}setServerTelemetry(){throw wy(gy)}getServerTelemetry(){throw wy(gy)}setAuthorityMetadata(){throw wy(gy)}getAuthorityMetadata(){throw wy(gy)}getAuthorityMetadataKeys(){throw wy(gy)}setThrottlingCache(){throw wy(gy)}getThrottlingCache(){throw wy(gy)}removeItem(){throw wy(gy)}getKeys(){throw wy(gy)}getAccountKeys(){throw wy(gy)}getTokenKeys(){throw wy(gy)}async clear(){throw wy(gy)}updateCredentialCacheKey(){throw wy(gy)}removeOutdatedAccount(){throw wy(gy)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const Kv={tokenRenewalOffsetSeconds:300,preventCorsPreflight:!1},Vv={loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:Ym.Info,correlationId:Gh.EMPTY_STRING},Jv={claimsBasedCachingEnabled:!1},Yv={async sendGetRequestAsync(){throw wy(gy)},async sendPostRequestAsync(){throw wy(gy)}},Qv={sku:Gh.SKU,version:Mv,cpu:Gh.EMPTY_STRING,os:Gh.EMPTY_STRING},Zv={clientSecret:Gh.EMPTY_STRING,clientAssertion:void 0},Xv={azureCloudInstance:Ay,tenant:`${Gh.DEFAULT_COMMON_TENANT}`},eb={application:{appName:"",appVersion:""}};function tb(e){return e.authOptions.authority.options.protocolMode===Iy} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class rb{static generateThrottlingStorageKey(e){return`${zf}.${JSON.stringify(e)}`}static preProcess(e,t){const r=rb.generateThrottlingStorageKey(t),i=e.getThrottlingCache(r);if(i){if(i.throttleTime=500&&e.status<600}static checkResponseForRetryAfter(e){return!!e.headers&&(e.headers.hasOwnProperty(of)&&(e.status<200||e.status>=300))}static calculateThrottleTime(e){const t=e<=0?0:e,r=Date.now()/1e3;return Math.floor(1e3*Math.min(r+(t||Pf),r+Of))}static removeThrottle(e,t,r,i){const n={clientId:t,authority:r.authority,scopes:r.scopes,homeAccountIdentifier:i,claims:r.claims,authenticationScheme:r.authenticationScheme,resourceRequestMethod:r.resourceRequestMethod,resourceRequestUri:r.resourceRequestUri,shrClaims:r.shrClaims,sshKid:r.sshKid},o=this.generateThrottlingStorageKey(n);e.removeItem(o)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class ib{constructor(e,t){this.networkClient=e,this.cacheManager=t}async sendPostRequest(e,t,r){let i;rb.preProcess(this.cacheManager,e);try{i=await this.networkClient.sendPostRequestAsync(t,r)}catch(e){throw e instanceof Um?e:wy(Dg)}return rb.postProcess(this.cacheManager,e,i),i}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const nb="home_account_id",ob="UPN"; +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class sb{static validateRedirectUri(e){if(!e)throw Tg(rg)}static validatePrompt(e){const t=[];for(const e in pf)t.push(pf[e]);if(t.indexOf(e)<0)throw Tg(lg)}static validateClaims(e){try{JSON.parse(e)}catch(e){throw Tg(dg)}}static validateCodeChallengeParams(e,t){if(!e||!t)throw Tg(hg);this.validateCodeChallengeMethod(t)}static validateCodeChallengeMethod(e){if([hf.PLAIN,hf.S256].indexOf(e)<0)throw Tg(pg)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class ab{constructor(){this.parameters=new Map}addResponseTypeCode(){this.parameters.set($m,encodeURIComponent(Gh.CODE_RESPONSE_TYPE))}addResponseTypeForTokenAndIdToken(){this.parameters.set($m,encodeURIComponent(`${Gh.TOKEN_RESPONSE_TYPE} ${Gh.ID_TOKEN_RESPONSE_TYPE}`))}addResponseMode(e){this.parameters.set("response_mode",encodeURIComponent(e||ff.QUERY))}addNativeBroker(){this.parameters.set("nativebroker",encodeURIComponent("1"))}addScopes(e,t=!0,r=tf){!t||r.includes("openid")||e.includes("openid")||r.push("openid");const i=t?[...e||[],...r]:e||[],n=new Dv(i);this.parameters.set("scope",encodeURIComponent(n.printScopes()))}addClientId(e){this.parameters.set(Hm,encodeURIComponent(e))}addRedirectUri(e){sb.validateRedirectUri(e),this.parameters.set("redirect_uri",encodeURIComponent(e))}addPostLogoutRedirectUri(e){sb.validateRedirectUri(e),this.parameters.set("post_logout_redirect_uri",encodeURIComponent(e))}addIdTokenHint(e){this.parameters.set("id_token_hint",encodeURIComponent(e))}addDomainHint(e){this.parameters.set("domain_hint",encodeURIComponent(e))}addLoginHint(e){this.parameters.set("login_hint",encodeURIComponent(e))}addCcsUpn(e){this.parameters.set(sf,encodeURIComponent(`UPN:${e}`))}addCcsOid(e){this.parameters.set(sf,encodeURIComponent(`Oid:${e.uid}@${e.utid}`))}addSid(e){this.parameters.set("sid",encodeURIComponent(e))}addClaims(e,t){const r=this.addClientCapabilitiesToClaims(e,t);sb.validateClaims(r),this.parameters.set("claims",encodeURIComponent(r))}addCorrelationId(e){this.parameters.set("client-request-id",encodeURIComponent(e))}addLibraryInfo(e){this.parameters.set("x-client-SKU",e.sku),this.parameters.set("x-client-VER",e.version),e.os&&this.parameters.set("x-client-OS",e.os),e.cpu&&this.parameters.set("x-client-CPU",e.cpu)}addApplicationTelemetry(e){e?.appName&&this.parameters.set("x-app-name",e.appName),e?.appVersion&&this.parameters.set("x-app-ver",e.appVersion)}addPrompt(e){sb.validatePrompt(e),this.parameters.set("prompt",encodeURIComponent(e))}addState(e){e&&this.parameters.set("state",encodeURIComponent(e))}addNonce(e){this.parameters.set("nonce",encodeURIComponent(e))}addCodeChallengeParams(e,t){if(sb.validateCodeChallengeParams(e,t),!e||!t)throw Tg(hg);this.parameters.set("code_challenge",encodeURIComponent(e)),this.parameters.set("code_challenge_method",encodeURIComponent(t))}addAuthorizationCode(e){this.parameters.set("code",encodeURIComponent(e))}addDeviceCode(e){this.parameters.set("device_code",encodeURIComponent(e))}addRefreshToken(e){this.parameters.set("refresh_token",encodeURIComponent(e))}addCodeVerifier(e){this.parameters.set("code_verifier",encodeURIComponent(e))}addClientSecret(e){this.parameters.set("client_secret",encodeURIComponent(e))}addClientAssertion(e){e&&this.parameters.set("client_assertion",encodeURIComponent(e))}addClientAssertionType(e){e&&this.parameters.set("client_assertion_type",encodeURIComponent(e))}addOboAssertion(e){this.parameters.set("assertion",encodeURIComponent(e))}addRequestTokenUse(e){this.parameters.set("requested_token_use",encodeURIComponent(e))}addGrantType(e){this.parameters.set("grant_type",encodeURIComponent(e))}addClientInfo(){this.parameters.set("client_info","1")}addExtraQueryParameters(e){Object.entries(e).forEach((([e,t])=>{!this.parameters.has(e)&&t&&this.parameters.set(e,t)}))}addClientCapabilitiesToClaims(e,t){let r;if(e)try{r=JSON.parse(e)}catch(e){throw Tg(dg)}else r={};return t&&t.length>0&&(r.hasOwnProperty(cf)||(r[cf]={}),r[cf][uf]={values:t}),JSON.stringify(r)}addUsername(e){this.parameters.set(Lf,encodeURIComponent(e))}addPassword(e){this.parameters.set(jf,encodeURIComponent(e))}addPopToken(e){e&&(this.parameters.set(Gm,Rf.POP),this.parameters.set(Wm,encodeURIComponent(e)))}addSshJwk(e){e&&(this.parameters.set(Gm,Rf.SSH),this.parameters.set(Wm,encodeURIComponent(e)))}addServerTelemetry(e){this.parameters.set("x-client-current-telemetry",e.generateCurrentRequestHeaderValue()),this.parameters.set("x-client-last-telemetry",e.generateLastRequestHeaderValue())}addThrottling(){this.parameters.set("x-ms-lib-capability",Nf)}addLogoutHint(e){this.parameters.set("logout_hint",encodeURIComponent(e))}createQueryString(){const e=new Array;return this.parameters.forEach(((t,r)=>{e.push(`${r}=${t}`)})),e.join("&")}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +async function lb(e,t,r,i,n,o,s){s?.addQueueMeasurement(Jy,o);const a=Cv.transformCIAMAuthority(Iv(e)),l=new Cv(a,t,r,i,n,o,s);try{return await sv(l.resolveEndpointsAsync.bind(l),Yy,n,s,o)(),l}catch(e){throw wy(Mg)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class db{constructor(e,t){this.config=function({authOptions:e,systemOptions:t,loggerOptions:r,cacheOptions:i,storageInterface:n,networkInterface:o,cryptoInterface:s,clientCredentials:a,libraryInfo:l,telemetry:d,serverTelemetryManager:c,persistencePlugin:u,serializableCache:p}){const h={...Vv,...r};return{authOptions:(f=e,{clientCapabilities:[],azureCloudOptions:Xv,skipAuthorityMetadataCache:!1,instanceAware:!1,...f}),systemOptions:{...Kv,...t},loggerOptions:h,cacheOptions:{...Jv,...i},storageInterface:n||new Wv(e.clientId,Av,new Qm(h)),networkInterface:o||Yv,cryptoInterface:s||Av,clientCredentials:a||Zv,libraryInfo:{...Qv,...l},telemetry:{...eb,...d},serverTelemetryManager:c||null,persistencePlugin:u||null,serializableCache:p||null};var f}(e),this.logger=new Qm(this.config.loggerOptions,Fv,Mv),this.cryptoUtils=this.config.cryptoInterface,this.cacheManager=this.config.storageInterface,this.networkClient=this.config.networkInterface,this.networkManager=new ib(this.networkClient,this.cacheManager),this.serverTelemetryManager=this.config.serverTelemetryManager,this.authority=this.config.authOptions.authority,this.performanceClient=t}createTokenRequestHeaders(e){const t={};if(t[nf]=Gh.URL_FORM_CONTENT_TYPE,!this.config.systemOptions.preventCorsPreflight&&e)switch(e.type){case nb:try{const r=Pv(e.credential);t[sf]=`Oid:${r.uid}@${r.utid}`}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ob:t[sf]=`UPN: ${e.credential}`}return t}async executePostToTokenEndpoint(e,t,r,i,n,o){o&&this.performanceClient?.addQueueMeasurement(o,n);const s=await this.networkManager.sendPostRequest(i,e,{body:t,headers:r});return this.performanceClient?.addFields({refreshTokenSize:s.body.refresh_token?.length||0,httpVerToken:s.headers?.[lf]||""},n),this.config.serverTelemetryManager&&s.status<500&&429!==s.status&&this.config.serverTelemetryManager.clearTelemetryCache(),s}async updateAuthority(e,t){this.performanceClient?.addQueueMeasurement(Ly,t);const r=`https://${e}/${this.authority.tenant}/`,i=await lb(r,this.networkClient,this.cacheManager,this.authority.options,this.logger,t,this.performanceClient);this.authority=i}createTokenQueryParameters(e){const t=new ab;return e.tokenQueryParameters&&t.addExtraQueryParameters(e.tokenQueryParameters),t.createQueryString()}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const cb="no_tokens_found",ub="native_account_unavailable",pb="refresh_token_expired",hb="bad_token",fb=["interaction_required","consent_required","login_required",hb],mb=["message_only","additional_action","basic_action","user_password_expired","consent_required","bad_token"],gb={[cb]:"No refresh token found in the cache. Please sign-in.",[ub]:"The requested account is not available in the native broker. It may have been deleted or logged out. Please sign-in again using an interactive API.",[pb]:"Refresh token has expired.",[hb]:"Identity provider returned bad_token due to an expired or invalid refresh token. Please invoke an interactive API to resolve."};class yb extends Um{constructor(e,t,r,i,n,o,s,a){super(e,t,r),Object.setPrototypeOf(this,yb.prototype),this.timestamp=i||Gh.EMPTY_STRING,this.traceId=n||Gh.EMPTY_STRING,this.correlationId=o||Gh.EMPTY_STRING,this.claims=s||Gh.EMPTY_STRING,this.name="InteractionRequiredAuthError",this.errorNo=a}}function vb(e,t,r){const i=!!e&&fb.indexOf(e)>-1,n=!!r&&mb.indexOf(r)>-1,o=!!t&&fb.some((e=>t.indexOf(e)>-1));return i||o||n}function bb(e){return new yb(e,gb[e])} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class wb{static setRequestState(e,t,r){const i=wb.generateLibraryState(e,r);return t?`${i}${Gh.RESOURCE_DELIM}${t}`:i}static generateLibraryState(e,t){if(!e)throw wy(ry);const r={id:e.createNewGuid()};t&&(r.meta=t);const i=JSON.stringify(r);return e.base64Encode(i)}static parseRequestState(e,t){if(!e)throw wy(ry);if(!t)throw wy(Og);try{const r=t.split(Gh.RESOURCE_DELIM),i=r[0],n=r.length>1?r.slice(1).join(Gh.RESOURCE_DELIM):Gh.EMPTY_STRING,o=e.base64Decode(i),s=JSON.parse(o);return{userRequestState:n||Gh.EMPTY_STRING,libraryState:s}}catch(e){throw wy(Og)}}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +const _b="sw";class xb{constructor(e,t){this.cryptoUtils=e,this.performanceClient=t}async generateCnf(e,t){this.performanceClient?.addQueueMeasurement(Wy,e.correlationId);const r=await sv(this.generateKid.bind(this),Wy,t,this.performanceClient,e.correlationId)(e),i=this.cryptoUtils.base64UrlEncode(JSON.stringify(r));return{kid:r.kid,reqCnfString:i}}async generateKid(e){this.performanceClient?.addQueueMeasurement(Ky,e.correlationId);return{kid:await this.cryptoUtils.getPublicKeyThumbprint(e),xms_ksl:_b}}async signPopToken(e,t,r){return this.signPayload(e,t,r)}async signPayload(e,t,r,i){const{resourceRequestMethod:n,resourceRequestUri:o,shrClaims:s,shrNonce:a,shrOptions:l}=r,d=o?new xy(o):void 0,c=d?.getUrlComponents();return this.cryptoUtils.signJwt({at:e,ts:cv(),m:n?.toUpperCase(),u:c?.HostNameAndPort,nonce:a||this.cryptoUtils.createNewGuid(),p:c?.AbsolutePath,q:c?.QueryString?[[],c.QueryString]:void 0,client_claims:s||void 0,...i},t,l,r.correlationId)}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Sb{constructor(e,t){this.cache=e,this.hasChanged=t}get cacheHasChanged(){return this.hasChanged}get tokenCache(){return this.cache}}class kb{constructor(e,t,r,i,n,o,s){this.clientId=e,this.cacheStorage=t,this.cryptoObj=r,this.logger=i,this.serializableCache=n,this.persistencePlugin=o,this.performanceClient=s}validateServerAuthorizationCodeResponse(e,t){if(!e.state||!t)throw e.state?wy(Ng,"Cached State"):wy(Ng,"Server State");let r,i;try{r=decodeURIComponent(e.state)}catch(t){throw wy(Og,e.state)}try{i=decodeURIComponent(t)}catch(t){throw wy(Og,e.state)}if(r!==i)throw wy(zg);if(e.error||e.error_description||e.suberror){const t= +/*! @azure/msal-common v14.15.0 2024-09-20 */ +function(e){const t="code=",r=e.error_uri?.lastIndexOf(t);return r&&r>=0?e.error_uri?.substring(r+5):void 0}(e);if(vb(e.error,e.error_description,e.suberror))throw new yb(e.error||"",e.error_description,e.suberror,e.timestamp||"",e.trace_id||"",e.correlation_id||"",e.claims||"",t);throw new Jm(e.error||"",e.error_description,e.suberror,t)}}validateTokenResponse(e,t){if(e.error||e.error_description||e.suberror){const r=`Error(s): ${e.error_codes||Gh.NOT_AVAILABLE} - Timestamp: ${e.timestamp||Gh.NOT_AVAILABLE} - Description: ${e.error_description||Gh.NOT_AVAILABLE} - Correlation ID: ${e.correlation_id||Gh.NOT_AVAILABLE} - Trace ID: ${e.trace_id||Gh.NOT_AVAILABLE}`,i=e.error_codes?.length?e.error_codes[0]:void 0,n=new Jm(e.error,r,e.suberror,i,e.status);if(t&&e.status&&e.status>=Xh&&e.status<=ef)return void this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently unavailable and the access token is unable to be refreshed.\n${n}`);if(t&&e.status&&e.status>=Yh&&e.status<=Qh)return void this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently available but is unable to refresh the access token.\n${n}`);if(vb(e.error,e.error_description,e.suberror))throw new yb(e.error,e.error_description,e.suberror,e.timestamp||Gh.EMPTY_STRING,e.trace_id||Gh.EMPTY_STRING,e.correlation_id||Gh.EMPTY_STRING,e.claims||Gh.EMPTY_STRING,i);throw n}}async handleServerTokenResponse(e,t,r,i,n,o,s,a,l){let d,c;if(this.performanceClient?.addQueueMeasurement(Vy,e.correlation_id),e.id_token){if(d=lv(e.id_token||Gh.EMPTY_STRING,this.cryptoObj.base64Decode),n&&n.nonce&&d.nonce!==n.nonce)throw wy(qg);if(i.maxAge||0===i.maxAge){const e=d.auth_time;if(!e)throw wy(Ug);dv(e,i.maxAge)}}this.homeAccountIdentifier=Uv.generateHomeAccountId(e.client_info||Gh.EMPTY_STRING,t.authorityType,this.logger,this.cryptoObj,d),n&&n.state&&(c=wb.parseRequestState(this.cryptoObj,n.state)),e.key_id=e.key_id||i.sshKid||void 0;const u=this.generateCacheRecord(e,t,r,i,d,o,n);let p;try{if(this.persistencePlugin&&this.serializableCache&&(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),p=new Sb(this.serializableCache,!0),await this.persistencePlugin.beforeCacheAccess(p)),s&&!a&&u.account){const e=u.account.generateAccountKey();if(!this.cacheStorage.getAccount(e,this.logger))return this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),await kb.generateAuthenticationResult(this.cryptoObj,t,u,!1,i,d,c,void 0,l)}await this.cacheStorage.saveCacheRecord(u,i.storeInCache,i.correlationId)}finally{this.persistencePlugin&&this.serializableCache&&p&&(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),await this.persistencePlugin.afterCacheAccess(p))}return kb.generateAuthenticationResult(this.cryptoObj,t,u,!1,i,d,c,e,l)}generateCacheRecord(e,t,r,i,n,o,s){const a=t.getPreferredCache();if(!a)throw wy(ey);const l=qv(n);let d,c;var u,p,h,f,m;e.id_token&&n&&(u=this.homeAccountIdentifier,p=a,h=e.id_token,f=this.clientId,m=l||"",d={credentialType:kf.ID_TOKEN,homeAccountId:u,environment:p,clientId:f,secret:h,realm:m},c=function(e,t,r,i,n,o,s,a,l,d,c){c?.verbose("setCachedAccount called");const u=e.getAccountKeys().find((e=>e.startsWith(r)));let p=null;u&&(p=e.getAccount(u,c));const h=p||Uv.createAccount({homeAccountId:r,idTokenClaims:n,clientInfo:o,environment:s,cloudGraphHostName:l?.cloud_graph_host_name,msGraphHost:l?.msgraph_host,nativeAccountId:d},t,i),f=h.tenantProfiles||[],m=a||h.realm;if(m&&!f.find((e=>e.tenantId===m))){const e=zv(r,h.localAccountId,m,n);f.push(e)}return h.tenantProfiles=f,h}(this.cacheStorage,t,this.homeAccountIdentifier,this.cryptoObj.base64Decode,n,e.client_info,a,l,s,void 0,this.logger));let g=null;if(e.access_token){const n=e.scope?Dv.fromString(e.scope):new Dv(i.scopes||[]),s=("string"==typeof e.expires_in?parseInt(e.expires_in,10):e.expires_in)||0,d=("string"==typeof e.ext_expires_in?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,c=("string"==typeof e.refresh_in?parseInt(e.refresh_in,10):e.refresh_in)||void 0,u=r+s,p=u+d,h=c&&c>0?r+c:void 0;g=function(e,t,r,i,n,o,s,a,l,d,c,u,p,h,f){const m={homeAccountId:e,credentialType:kf.ACCESS_TOKEN,secret:r,cachedAt:cv().toString(),expiresOn:s.toString(),extendedExpiresOn:a.toString(),environment:t,clientId:i,realm:n,target:o,tokenType:c||Rf.BEARER};if(u&&(m.userAssertionHash=u),d&&(m.refreshOn=d.toString()),h&&(m.requestedClaims=h,m.requestedClaimsHash=f),m.tokenType?.toLowerCase()!==Rf.BEARER.toLowerCase())switch(m.credentialType=kf.ACCESS_TOKEN_WITH_AUTH_SCHEME,m.tokenType){case Rf.POP:const e=lv(r,l);if(!e?.cnf?.kid)throw wy(ly);m.keyId=e.cnf.kid;break;case Rf.SSH:m.keyId=p}return m}(this.homeAccountIdentifier,a,e.access_token,this.clientId,l||t.tenant||"",n.printScopes(),u,p,this.cryptoObj.base64Decode,h,e.token_type,o,e.key_id,i.claims,i.requestedClaimsHash)}let y=null;if(e.refresh_token){let t;if(e.refresh_token_expires_in){t=r+("string"==typeof e.refresh_token_expires_in?parseInt(e.refresh_token_expires_in,10):e.refresh_token_expires_in)}y=function(e,t,r,i,n,o,s){const a={credentialType:kf.REFRESH_TOKEN,homeAccountId:e,environment:t,clientId:i,secret:r};return o&&(a.userAssertionHash=o),n&&(a.familyId=n),s&&(a.expiresOn=s.toString()),a}(this.homeAccountIdentifier,a,e.refresh_token,this.clientId,e.foci,o,t)}let v=null;return e.foci&&(v={clientId:this.clientId,environment:a,familyId:e.foci}),{account:c,idToken:d,accessToken:g,refreshToken:y,appMetadata:v}}static async generateAuthenticationResult(e,t,r,i,n,o,s,a,l){let d,c,u=Gh.EMPTY_STRING,p=[],h=null,f=Gh.EMPTY_STRING;if(r.accessToken){if(r.accessToken.tokenType!==Rf.POP||n.popKid)u=r.accessToken.secret;else{const t=new xb(e),{secret:i,keyId:o}=r.accessToken;if(!o)throw wy(py);u=await t.signPopToken(i,o,n)}p=Dv.fromString(r.accessToken.target).asArray(),h=new Date(1e3*Number(r.accessToken.expiresOn)),d=new Date(1e3*Number(r.accessToken.extendedExpiresOn)),r.accessToken.refreshOn&&(c=new Date(1e3*Number(r.accessToken.refreshOn)))}r.appMetadata&&(f=r.appMetadata.familyId===Tf?Tf:"");const m=o?.oid||o?.sub||"",g=o?.tid||"";a?.spa_accountid&&r.account&&(r.account.nativeAccountId=a?.spa_accountid);const y=r.account?Nv(r.account.getAccountInfo(),void 0,o,r.idToken?.secret):null;return{authority:t.canonicalAuthority,uniqueId:m,tenantId:g,scopes:p,account:y,idToken:r?.idToken?.secret||"",idTokenClaims:o||{},accessToken:u,fromCache:i,expiresOn:h,extExpiresOn:d,refreshOn:c,correlationId:n.correlationId,requestId:l||Gh.EMPTY_STRING,familyId:f,tokenType:r.accessToken?.tokenType||Gh.EMPTY_STRING,state:s?s.userRequestState:Gh.EMPTY_STRING,cloudGraphHostName:r.account?.cloudGraphHostName||Gh.EMPTY_STRING,msGraphHost:r.account?.msGraphHost||Gh.EMPTY_STRING,code:a?.spa_code,fromNativeBroker:!1}}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +async function Eb(e,t,r){if("string"==typeof e)return e;return e({clientId:t,tokenEndpoint:r})} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Tb extends db{constructor(e,t){super(e,t),this.includeRedirectUri=!0,this.oidcDefaultScopes=this.config.authOptions.authority.options.OIDCOptions?.defaultScopes}async getAuthCodeUrl(e){this.performanceClient?.addQueueMeasurement(Uy,e.correlationId);const t=await sv(this.createAuthCodeUrlQueryString.bind(this),Gy,this.logger,this.performanceClient,e.correlationId)(e);return xy.appendQueryString(this.authority.authorizationEndpoint,t)}async acquireToken(e,t){if(this.performanceClient?.addQueueMeasurement(jy,e.correlationId),!e.code)throw wy(Gg);const r=cv(),i=await sv(this.executeTokenRequest.bind(this),Hy,this.logger,this.performanceClient,e.correlationId)(this.authority,e),n=i.headers?.[af],o=new kb(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient);return o.validateTokenResponse(i.body),sv(o.handleServerTokenResponse.bind(o),Vy,this.logger,this.performanceClient,e.correlationId)(i.body,this.authority,r,e,t,void 0,void 0,void 0,n)}handleFragmentResponse(e,t){if(new kb(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null).validateServerAuthorizationCodeResponse(e,t),!e.code)throw wy(dy);return e}getLogoutUri(e){if(!e)throw Tg(ug);const t=this.createLogoutUrlQueryString(e);return xy.appendQueryString(this.authority.endSessionEndpoint,t)}async executeTokenRequest(e,t){this.performanceClient?.addQueueMeasurement(Hy,t.correlationId);const r=this.createTokenQueryParameters(t),i=xy.appendQueryString(e.tokenEndpoint,r),n=await sv(this.createTokenRequestBody.bind(this),$y,this.logger,this.performanceClient,t.correlationId)(t);let o;if(t.clientInfo)try{const e=Rv(t.clientInfo,this.cryptoUtils.base64Decode);o={credential:`${e.uid}${Sf}${e.utid}`,type:nb}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}const s=this.createTokenRequestHeaders(o||t.ccsCredential),a={clientId:t.tokenBodyParameters?.clientId||this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:t.scopes,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid};return sv(this.executePostToTokenEndpoint.bind(this),My,this.logger,this.performanceClient,t.correlationId)(i,n,s,a,t.correlationId,My)}async createTokenRequestBody(e){this.performanceClient?.addQueueMeasurement($y,e.correlationId);const t=new ab;if(t.addClientId(e.tokenBodyParameters?.[Hm]||this.config.authOptions.clientId),this.includeRedirectUri?t.addRedirectUri(e.redirectUri):sb.validateRedirectUri(e.redirectUri),t.addScopes(e.scopes,!0,this.oidcDefaultScopes),t.addAuthorizationCode(e.code),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&!tb(this.config)&&t.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&t.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const r=this.config.clientCredentials.clientAssertion;t.addClientAssertion(await Eb(r.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),t.addClientAssertionType(r.assertionType)}if(t.addGrantType(mf),t.addClientInfo(),e.authenticationScheme===Rf.POP){const r=new xb(this.cryptoUtils,this.performanceClient);let i;if(e.popKid)i=this.cryptoUtils.encodeKid(e.popKid);else{i=(await sv(r.generateCnf.bind(r),Wy,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString}t.addPopToken(i)}else if(e.authenticationScheme===Rf.SSH){if(!e.sshJwk)throw Tg(yg);t.addSshJwk(e.sshJwk)}const r=e.correlationId||this.config.cryptoInterface.createNewGuid();let i;if(t.addCorrelationId(r),(!Bg.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.clientInfo)try{const t=Rv(e.clientInfo,this.cryptoUtils.base64Decode);i={credential:`${t.uid}${Sf}${t.utid}`,type:nb}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}else i=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&i)switch(i.type){case nb:try{const e=Pv(i.credential);t.addCcsOid(e)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ob:t.addCcsUpn(i.credential)}return e.tokenBodyParameters&&t.addExtraQueryParameters(e.tokenBodyParameters),!e.enableSpaAuthorizationCode||e.tokenBodyParameters&&e.tokenBodyParameters[Km]||t.addExtraQueryParameters({[Km]:"1"}),t.createQueryString()}async createAuthCodeUrlQueryString(e){this.performanceClient?.addQueueMeasurement(Gy,e.correlationId);const t=new ab;t.addClientId(e.extraQueryParameters?.[Hm]||this.config.authOptions.clientId);const r=[...e.scopes||[],...e.extraScopesToConsent||[]];t.addScopes(r,!0,this.oidcDefaultScopes),t.addRedirectUri(e.redirectUri);const i=e.correlationId||this.config.cryptoInterface.createNewGuid();if(t.addCorrelationId(i),t.addResponseMode(e.responseMode),t.addResponseTypeCode(),t.addLibraryInfo(this.config.libraryInfo),tb(this.config)||t.addApplicationTelemetry(this.config.telemetry.application),t.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&t.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&t.addPrompt(e.prompt),e.domainHint&&t.addDomainHint(e.domainHint),e.prompt!==pf.SELECT_ACCOUNT)if(e.sid&&e.prompt===pf.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),t.addSid(e.sid);else if(e.account){const r=this.extractAccountSid(e.account);let i=this.extractLoginHint(e.account);if(i&&e.domainHint&&(this.logger.warning('AuthorizationCodeClient.createAuthCodeUrlQueryString: "domainHint" param is set, skipping opaque "login_hint" claim. Please consider not passing domainHint'),i=null),i){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),t.addLoginHint(i);try{const r=Pv(e.account.homeAccountId);t.addCcsOid(r)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(r&&e.prompt===pf.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),t.addSid(r);try{const r=Pv(e.account.homeAccountId);t.addCcsOid(r)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),t.addLoginHint(e.loginHint),t.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),t.addLoginHint(e.account.username);try{const r=Pv(e.account.homeAccountId);t.addCcsOid(r)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),t.addLoginHint(e.loginHint),t.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");if(e.nonce&&t.addNonce(e.nonce),e.state&&t.addState(e.state),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.addExtraQueryParams(e,t),e.nativeBroker&&(t.addNativeBroker(),e.authenticationScheme===Rf.POP)){const r=new xb(this.cryptoUtils);let i;if(e.popKid)i=this.cryptoUtils.encodeKid(e.popKid);else{i=(await sv(r.generateCnf.bind(r),Wy,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString}t.addPopToken(i)}return t.createQueryString()}createLogoutUrlQueryString(e){const t=new ab;return e.postLogoutRedirectUri&&t.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&t.addCorrelationId(e.correlationId),e.idTokenHint&&t.addIdTokenHint(e.idTokenHint),e.state&&t.addState(e.state),e.logoutHint&&t.addLogoutHint(e.logoutHint),this.addExtraQueryParams(e,t),t.createQueryString()}addExtraQueryParams(e,t){!(e.extraQueryParameters&&e.extraQueryParameters.hasOwnProperty("instance_aware"))&&this.config.authOptions.instanceAware&&(e.extraQueryParameters=e.extraQueryParameters||{},e.extraQueryParameters.instance_aware="true"),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters)}extractAccountSid(e){return e.idTokenClaims?.sid||null}extractLoginHint(e){return e.idTokenClaims?.login_hint||null}}class Bb extends db{constructor(e,t){super(e,t)}async acquireToken(e){this.performanceClient?.addQueueMeasurement(Ry,e.correlationId);const t=cv(),r=await sv(this.executeTokenRequest.bind(this),Dy,this.logger,this.performanceClient,e.correlationId)(e,this.authority),i=r.headers?.[af],n=new kb(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return n.validateTokenResponse(r.body),sv(n.handleServerTokenResponse.bind(n),Vy,this.logger,this.performanceClient,e.correlationId)(r.body,this.authority,t,e,void 0,void 0,!0,e.forceCache,i)}async acquireTokenByRefreshToken(e){if(!e)throw Tg(cg);if(this.performanceClient?.addQueueMeasurement(Oy,e.correlationId),!e.account)throw wy(Zg);if(this.cacheManager.isAppMetadataFOCI(e.account.environment))try{return await sv(this.acquireTokenWithCachedRefreshToken.bind(this),Py,this.logger,this.performanceClient,e.correlationId)(e,!0)}catch(t){const r=t instanceof yb&&t.errorCode===cb,i=t instanceof Jm&&t.errorCode===qf&&t.subError===Uf;if(r||i)return sv(this.acquireTokenWithCachedRefreshToken.bind(this),Py,this.logger,this.performanceClient,e.correlationId)(e,!1);throw t}return sv(this.acquireTokenWithCachedRefreshToken.bind(this),Py,this.logger,this.performanceClient,e.correlationId)(e,!1)}async acquireTokenWithCachedRefreshToken(e,t){this.performanceClient?.addQueueMeasurement(Py,e.correlationId);const r=((e,t,r,i,n)=>(...o)=>{r.trace(`Executing function ${t}`);const s=i?.startMeasurement(t,n);if(n){const e=t+"CallCount";i?.incrementFields({[e]:1},n)}try{const i=e(...o);return s?.end({success:!0}),r.trace(`Returning result from ${t}`),i}catch(e){r.trace(`Error occurred in ${t}`);try{r.trace(JSON.stringify(e))}catch(e){r.trace("Unable to print error message.")}throw s?.end({success:!1},e),e}})(this.cacheManager.getRefreshToken.bind(this.cacheManager),ov,this.logger,this.performanceClient,e.correlationId)(e.account,t,void 0,this.performanceClient,e.correlationId);if(!r)throw bb(cb);if(r.expiresOn&&uv(r.expiresOn,e.refreshTokenExpirationOffsetSeconds||300))throw bb(pb);const i={...e,refreshToken:r.secret,authenticationScheme:e.authenticationScheme||Rf.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:nb}};try{return await sv(this.acquireToken.bind(this),Ry,this.logger,this.performanceClient,e.correlationId)(i)}catch(e){if(e instanceof yb&&e.subError===hb){this.logger.verbose("acquireTokenWithRefreshToken: bad refresh token, removing from cache");const e=hv(r);this.cacheManager.removeRefreshToken(e)}throw e}}async executeTokenRequest(e,t){this.performanceClient?.addQueueMeasurement(Dy,e.correlationId);const r=this.createTokenQueryParameters(e),i=xy.appendQueryString(t.tokenEndpoint,r),n=await sv(this.createTokenRequestBody.bind(this),zy,this.logger,this.performanceClient,e.correlationId)(e),o=this.createTokenRequestHeaders(e.ccsCredential),s={clientId:e.tokenBodyParameters?.clientId||this.config.authOptions.clientId,authority:t.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return sv(this.executePostToTokenEndpoint.bind(this),Fy,this.logger,this.performanceClient,e.correlationId)(i,n,o,s,e.correlationId,Fy)}async createTokenRequestBody(e){this.performanceClient?.addQueueMeasurement(zy,e.correlationId);const t=e.correlationId,r=new ab;if(r.addClientId(e.tokenBodyParameters?.[Hm]||this.config.authOptions.clientId),e.redirectUri&&r.addRedirectUri(e.redirectUri),r.addScopes(e.scopes,!0,this.config.authOptions.authority.options.OIDCOptions?.defaultScopes),r.addGrantType(yf),r.addClientInfo(),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&!tb(this.config)&&r.addServerTelemetry(this.serverTelemetryManager),r.addCorrelationId(t),r.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&r.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const t=this.config.clientCredentials.clientAssertion;r.addClientAssertion(await Eb(t.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),r.addClientAssertionType(t.assertionType)}if(e.authenticationScheme===Rf.POP){const t=new xb(this.cryptoUtils,this.performanceClient);let i;if(e.popKid)i=this.cryptoUtils.encodeKid(e.popKid);else{i=(await sv(t.generateCnf.bind(t),Wy,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString}r.addPopToken(i)}else if(e.authenticationScheme===Rf.SSH){if(!e.sshJwk)throw Tg(yg);r.addSshJwk(e.sshJwk)}if((!Bg.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case nb:try{const t=Pv(e.ccsCredential.credential);r.addCcsOid(t)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ob:r.addCcsUpn(e.ccsCredential.credential)}return e.tokenBodyParameters&&r.addExtraQueryParameters(e.tokenBodyParameters),r.createQueryString()}} +/*! @azure/msal-common v14.15.0 2024-09-20 */ +class Cb extends db{constructor(e,t){super(e,t)}async acquireToken(e){try{const[t,r]=await this.acquireCachedToken({...e,scopes:e.scopes?.length?e.scopes:[...tf]});if(r===tm){this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'. It's not expired, but must be refreshed.");new Bb(this.config,this.performanceClient).acquireTokenByRefreshToken(e).catch((()=>{}))}return t}catch(t){if(t instanceof by&&t.errorCode===sy){return new Bb(this.config,this.performanceClient).acquireTokenByRefreshToken(e)}throw t}}async acquireCachedToken(e){this.performanceClient?.addQueueMeasurement(Ny,e.correlationId);let t=Qf;if(e.forceRefresh||!this.config.cacheOptions.claimsBasedCachingEnabled&&!Bg.isEmptyObj(e.claims))throw this.setCacheOutcome(Zf,e.correlationId),wy(sy);if(!e.account)throw wy(Zg);const r=e.account.tenantId||function(e){const t=new xy(e).getUrlComponents(),r=t.PathSegments.slice(-1)[0]?.toLowerCase();switch(r){case df.COMMON:case df.ORGANIZATIONS:case df.CONSUMERS:return;default:return r}}(e.authority),i=this.cacheManager.getTokenKeys(),n=this.cacheManager.getAccessToken(e.account,e,i,r,this.performanceClient,e.correlationId);if(!n)throw this.setCacheOutcome(Xf,e.correlationId),wy(sy);if(o=n.cachedAt,Number(o)>cv()||uv(n.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw this.setCacheOutcome(em,e.correlationId),wy(sy);var o;n.refreshOn&&uv(n.refreshOn,0)&&(t=tm);const s=e.authority||this.authority.getPreferredCache(),a={account:this.cacheManager.readAccountFromCache(e.account),accessToken:n,idToken:this.cacheManager.getIdToken(e.account,i,r,this.performanceClient,e.correlationId),refreshToken:null,appMetadata:this.cacheManager.readAppMetadataFromCache(s)};return this.setCacheOutcome(t,e.correlationId),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[await sv(this.generateResultFromCacheRecord.bind(this),qy,this.logger,this.performanceClient,e.correlationId)(a,e),t]}setCacheOutcome(e,t){this.serverTelemetryManager?.setCacheOutcome(e),this.performanceClient?.addFields({cacheOutcome:e},t),e!==Qf&&this.logger.info(`Token refresh is required due to cache outcome: ${e}`)}async generateResultFromCacheRecord(e,t){let r;if(this.performanceClient?.addQueueMeasurement(qy,t.correlationId),e.idToken&&(r=lv(e.idToken.secret,this.config.cryptoInterface.base64Decode)),t.maxAge||0===t.maxAge){const e=r?.auth_time;if(!e)throw wy(Ug);dv(e,t.maxAge)}return kb.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,t,r)}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Ib{static getNetworkResponse(e,t,r){return{headers:e,body:t,status:r}}static urlToHttpOptions(e){const t={protocol:e.protocol,hostname:e.hostname&&e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:`${e.pathname||""}${e.search||""}`,href:e.href};return""!==e.port&&(t.port=Number(e.port)),(e.username||e.password)&&(t.auth=`${decodeURIComponent(e.username)}:${decodeURIComponent(e.password)}`),t}}var Ab=__webpack_require__(35265),Fb=__webpack_require__(70440),Mb=__webpack_require__(48287).Buffer; +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Db{constructor(e,t){this.proxyUrl=e||"",this.customAgentOptions=t||{}}async sendGetRequestAsync(e,t,r){return this.proxyUrl?Rb(e,this.proxyUrl,dm,t,this.customAgentOptions,r):Pb(e,dm,t,this.customAgentOptions,r)}async sendPostRequestAsync(e,t){return this.proxyUrl?Rb(e,this.proxyUrl,cm,t,this.customAgentOptions):Pb(e,cm,t,this.customAgentOptions)}}const Rb=(e,t,r,i,n,o)=>{const s=new URL(e),a=new URL(t),l=i?.headers||{},d={host:a.hostname,port:a.port,method:"CONNECT",path:s.hostname,headers:l};n&&Object.keys(n).length&&(d.agent=new Ab.Agent(n));let c="";if(r===cm){const e=i?.body||"";c=`Content-Type: application/x-www-form-urlencoded\r\nContent-Length: ${e.length}\r\n\r\n${e}`}else o&&(d.timeout=o);const u=`${r.toUpperCase()} ${s.href} HTTP/1.1\r\nHost: ${s.host}\r\nConnection: close\r\n`+c+"\r\n";return new Promise(((e,t)=>{const r=Ab.request(d);o&&r.on("timeout",(()=>{r.destroy(),t(new Error("Request time out"))})),r.end(),r.on("connect",((i,n)=>{const o=i?.statusCode||um.SERVER_ERROR;(oum.SUCCESS_RANGE_END)&&(r.destroy(),n.destroy(),t(new Error(`Error connecting to proxy. Http status code: ${i.statusCode}. Http status message: ${i?.statusMessage||"Unknown"}`))),n.write(u);const s=[];n.on("data",(e=>{s.push(e)})),n.on("end",(()=>{const t=Mb.concat([...s]).toString().split("\r\n"),i=parseInt(t[0].split(" ")[1]),n=t[0].split(" ").slice(2).join(" "),o=t[t.length-1],a=t.slice(1,t.length-2),l=new Map;a.forEach((e=>{const t=e.split(new RegExp(/:\s(.*)/s)),r=t[0];let i=t[1];try{const e=JSON.parse(i);e&&"object"==typeof e&&(i=e)}catch(e){}l.set(r,i)}));const d=Object.fromEntries(l),c=Ib.getNetworkResponse(d,Ob(i,n,d,o),i);(iVh)&&c.body.error!==gm&&r.destroy(),e(c)})),n.on("error",(e=>{r.destroy(),n.destroy(),t(new Error(e.toString()))}))})),r.on("error",(e=>{r.destroy(),t(new Error(e.toString()))}))}))},Pb=(e,t,r,i,n)=>{const o=t===cm,s=r?.body||"",a=new URL(e),l={method:t,headers:r?.headers||{},...Ib.urlToHttpOptions(a)};return i&&Object.keys(i).length&&(l.agent=new Fb.Agent(i)),o?l.headers={...l.headers,"Content-Length":s.length}:n&&(l.timeout=n),new Promise(((e,t)=>{let r;r="http:"===l.protocol?Ab.request(l):Fb.request(l),o&&r.write(s),n&&r.on("timeout",(()=>{r.destroy(),t(new Error("Request time out"))})),r.end(),r.on("response",(t=>{const i=t.headers,n=t.statusCode,o=t.statusMessage,s=[];t.on("data",(e=>{s.push(e)})),t.on("end",(()=>{const t=Mb.concat([...s]).toString(),a=i,l=Ib.getNetworkResponse(a,Ob(n,o,a,t),n);(nVh)&&l.body.error!==gm&&r.destroy(),e(l)}))})),r.on("error",(e=>{r.destroy(),t(new Error(e.toString()))}))}))},Ob=(e,t,r,i)=>{let n;try{n=JSON.parse(i)}catch(i){let o,s;e>=Yh&&e<=Qh?(o="client_error",s="A client"):e>=Xh&&e<=ef?(o="server_error",s="A server"):(o="unknown_error",s="An unknown"),n={error:o,error_description:`${s} error occured.\nHttp status code: ${e}\nHttp status message: ${t||"Unknown"}\nHeaders: ${JSON.stringify(r)}`}}return n},zb="invalid_file_extension",Nb="invalid_file_path",qb="invalid_managed_identity_id_type",Ub="invalid_secret",Lb="missing_client_id",jb="network_unavailable",Hb="platform_not_supported",$b="unable_to_create_azure_arc",Gb="unable_to_create_cloud_shell",Wb="unable_to_create_source",Kb="unable_to_read_secret_file",Vb="user_assigned_not_available_at_runtime",Jb="www_authenticate_header_missing",Yb="www_authenticate_header_unsupported_format",Qb={[rm]:"azure_pod_identity_authority_host_url_malformed",[im]:"identity_endpoint_url_malformed",[nm]:"imds_endpoint_url_malformed",[om]:"msi_endpoint_url_malformed"},Zb={[zb]:"The file path in the WWW-Authenticate header does not contain a .key file.",[Nb]:"The file path in the WWW-Authenticate header is not in a valid Windows or Linux Format.",[qb]:"More than one ManagedIdentityIdType was provided.",[Ub]:"The secret in the file on the file path in the WWW-Authenticate header is greater than 4096 bytes.",[Hb]:"The platform is not supported by Azure Arc. Azure Arc only supports Windows and Linux.",[Lb]:"A ManagedIdentityId id was not provided.",[Qb.AZURE_POD_IDENTITY_AUTHORITY_HOST]:`The Managed Identity's '${rm}' environment variable is malformed.`,[Qb.IDENTITY_ENDPOINT]:`The Managed Identity's '${im}' environment variable is malformed.`,[Qb.IMDS_ENDPOINT]:`The Managed Identity's '${nm}' environment variable is malformed.`,[Qb.MSI_ENDPOINT]:`The Managed Identity's '${om}' environment variable is malformed.`,[jb]:"Authentication unavailable. The request to the managed identity endpoint timed out.",[$b]:"Azure Arc Managed Identities can only be system assigned.",[Gb]:"Cloud Shell Managed Identities can only be system assigned.",[Wb]:"Unable to create a Managed Identity source based on environment variables.",[Kb]:"Unable to read the secret file.",[Vb]:"Service Fabric user assigned managed identity ClientId or ResourceId is not configurable at runtime.",[Jb]:"A 401 response was received form the Azure Arc Managed Identity, but the www-authenticate header is missing.",[Yb]:"A 401 response was received form the Azure Arc Managed Identity, but the www-authenticate header is in an unsupported format."};class Xb extends Um{constructor(e){super(e,Zb[e]),this.name="ManagedIdentityError",Object.setPrototypeOf(this,Xb.prototype)}}function ew(e){return new Xb(e)} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +const tw={code:"invalid_loopback_server_address_type",desc:"Loopback server address is not type string. This is unexpected."},rw={code:"unable_to_load_redirectUrl",desc:"Loopback server callback was invoked without a url. This is unexpected."},iw={code:"no_auth_code_in_response",desc:"No auth code found in the server response. Please check your network trace to determine what happened."},nw={code:"no_loopback_server_exists",desc:"No loopback server exists yet."},ow={code:"loopback_server_already_exists",desc:"Loopback server already exists. Cannot create another."},sw={code:"loopback_server_timeout",desc:"Timed out waiting for auth code listener to be registered."},aw={code:"state_not_found",desc:"State not found. Please verify that the request originated from msal."},lw={code:"thumbprint_missing_from_client_certificate",desc:"Client certificate does not contain a SHA-1 or SHA-256 thumbprint."};class dw extends Um{constructor(e,t){super(e,t),this.name="NodeAuthError"}static createInvalidLoopbackAddressTypeError(){return new dw(tw.code,`${tw.desc}`)}static createUnableToLoadRedirectUrlError(){return new dw(rw.code,`${rw.desc}`)}static createNoAuthCodeInResponseError(){return new dw(iw.code,`${iw.desc}`)}static createNoLoopbackServerExistsError(){return new dw(nw.code,`${nw.desc}`)}static createLoopbackServerAlreadyExistsError(){return new dw(ow.code,`${ow.desc}`)}static createLoopbackServerTimeoutError(){return new dw(sw.code,`${sw.desc}`)}static createStateNotFoundError(){return new dw(aw.code,aw.desc)}static createThumbprintMissingError(){return new dw(lw.code,lw.desc)}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +const cw={clientId:Gh.EMPTY_STRING,authority:Gh.DEFAULT_AUTHORITY,clientSecret:Gh.EMPTY_STRING,clientAssertion:Gh.EMPTY_STRING,clientCertificate:{thumbprint:Gh.EMPTY_STRING,thumbprintSha256:Gh.EMPTY_STRING,privateKey:Gh.EMPTY_STRING,x5c:Gh.EMPTY_STRING},knownAuthorities:[],cloudDiscoveryMetadata:Gh.EMPTY_STRING,authorityMetadata:Gh.EMPTY_STRING,clientCapabilities:[],protocolMode:Cy,azureCloudOptions:{azureCloudInstance:Ay,tenant:Gh.EMPTY_STRING},skipAuthorityMetadataCache:!1},uw={claimsBasedCachingEnabled:!1},pw={loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:Ym.Info},hw={loggerOptions:pw,networkClient:new Db,proxyUrl:Gh.EMPTY_STRING,customAgentOptions:{},disableInternalRetries:!1},fw={application:{appName:Gh.EMPTY_STRING,appVersion:Gh.EMPTY_STRING}};var mw,gw=new Uint8Array(16);function yw(){if(!mw&&!(mw="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return mw(gw)}const vw=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;const bw=function(e){return"string"==typeof e&&vw.test(e)};for(var ww=[],_w=0;_w<256;++_w)ww.push((_w+256).toString(16).substr(1));const xw=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(ww[e[t+0]]+ww[e[t+1]]+ww[e[t+2]]+ww[e[t+3]]+"-"+ww[e[t+4]]+ww[e[t+5]]+"-"+ww[e[t+6]]+ww[e[t+7]]+"-"+ww[e[t+8]]+ww[e[t+9]]+"-"+ww[e[t+10]]+ww[e[t+11]]+ww[e[t+12]]+ww[e[t+13]]+ww[e[t+14]]+ww[e[t+15]]).toLowerCase();if(!bw(r))throw TypeError("Stringified UUID is invalid");return r};const Sw=function(e,t,r){var i=(e=e||{}).random||(e.rng||yw)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,t){r=r||0;for(var n=0;n<16;++n)t[r+n]=i[n];return t}return xw(i)}; +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class kw{generateGuid(){return Sw()}isGuid(e){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(e)}}var Ew=__webpack_require__(48287).Buffer; +/*! @azure/msal-node v2.15.0 2024-10-03 */class Tw{static base64Encode(e,t){return Ew.from(e,t).toString("base64")}static base64EncodeUrl(e,t){return Tw.base64Encode(e,t).replace(/=/g,Gh.EMPTY_STRING).replace(/\+/g,"-").replace(/\//g,"_")}static base64Decode(e){return Ew.from(e,"base64").toString("utf8")}static base64DecodeUrl(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");for(;t.length%4;)t+="=";return Tw.base64Decode(t)}}var Bw=__webpack_require__(91565); +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Cw{sha256(e){return Bw.createHash(pm).update(e).digest()}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Iw{constructor(){this.hashUtils=new Cw}async generatePkceCodes(){const e=this.generateCodeVerifier();return{verifier:e,challenge:this.generateCodeChallengeFromVerifier(e)}}generateCodeVerifier(){const e=[],t=256-256%hm.length;for(;e.length<=32;){const r=Bw.randomBytes(1)[0];if(r>=t)continue;const i=r%hm.length;e.push(hm[i])}const r=e.join(Gh.EMPTY_STRING);return Tw.base64EncodeUrl(r)}generateCodeChallengeFromVerifier(e){return Tw.base64EncodeUrl(this.hashUtils.sha256(e).toString("base64"),"base64")}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Aw{constructor(){this.pkceGenerator=new Iw,this.guidGenerator=new kw,this.hashUtils=new Cw}base64UrlEncode(){throw new Error("Method not implemented.")}encodeKid(){throw new Error("Method not implemented.")}createNewGuid(){return this.guidGenerator.generateGuid()}base64Encode(e){return Tw.base64Encode(e)}base64Decode(e){return Tw.base64Decode(e)}generatePkceCodes(){return this.pkceGenerator.generatePkceCodes()}getPublicKeyThumbprint(){throw new Error("Method not implemented.")}removeTokenBindingKey(){throw new Error("Method not implemented.")}clearKeystore(){throw new Error("Method not implemented.")}signJwt(){throw new Error("Method not implemented.")}async hashString(e){return Tw.base64EncodeUrl(this.hashUtils.sha256(e).toString("base64"),"base64")}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Fw{static deserializeJSONBlob(e){return e?JSON.parse(e):{}}static deserializeAccounts(e){const t={};return e&&Object.keys(e).map((function(r){const i=e[r],n={homeAccountId:i.home_account_id,environment:i.environment,realm:i.realm,localAccountId:i.local_account_id,username:i.username,authorityType:i.authority_type,name:i.name,clientInfo:i.client_info,lastModificationTime:i.last_modification_time,lastModificationApp:i.last_modification_app,tenantProfiles:i.tenantProfiles?.map((e=>JSON.parse(e)))},o=new Uv;Gv.toObject(o,n),t[r]=o})),t}static deserializeIdTokens(e){const t={};return e&&Object.keys(e).map((function(r){const i=e[r],n={homeAccountId:i.home_account_id,environment:i.environment,credentialType:i.credential_type,clientId:i.client_id,secret:i.secret,realm:i.realm};t[r]=n})),t}static deserializeAccessTokens(e){const t={};return e&&Object.keys(e).map((function(r){const i=e[r],n={homeAccountId:i.home_account_id,environment:i.environment,credentialType:i.credential_type,clientId:i.client_id,secret:i.secret,realm:i.realm,target:i.target,cachedAt:i.cached_at,expiresOn:i.expires_on,extendedExpiresOn:i.extended_expires_on,refreshOn:i.refresh_on,keyId:i.key_id,tokenType:i.token_type,requestedClaims:i.requestedClaims,requestedClaimsHash:i.requestedClaimsHash,userAssertionHash:i.userAssertionHash};t[r]=n})),t}static deserializeRefreshTokens(e){const t={};return e&&Object.keys(e).map((function(r){const i=e[r],n={homeAccountId:i.home_account_id,environment:i.environment,credentialType:i.credential_type,clientId:i.client_id,secret:i.secret,familyId:i.family_id,target:i.target,realm:i.realm};t[r]=n})),t}static deserializeAppMetadata(e){const t={};return e&&Object.keys(e).map((function(r){const i=e[r];t[r]={clientId:i.client_id,environment:i.environment,familyId:i.family_id}})),t}static deserializeAllCache(e){return{accounts:e.Account?this.deserializeAccounts(e.Account):{},idTokens:e.IdToken?this.deserializeIdTokens(e.IdToken):{},accessTokens:e.AccessToken?this.deserializeAccessTokens(e.AccessToken):{},refreshTokens:e.RefreshToken?this.deserializeRefreshTokens(e.RefreshToken):{},appMetadata:e.AppMetadata?this.deserializeAppMetadata(e.AppMetadata):{}}}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Mw{static serializeJSONBlob(e){return JSON.stringify(e)}static serializeAccounts(e){const t={};return Object.keys(e).map((function(r){const i=e[r];t[r]={home_account_id:i.homeAccountId,environment:i.environment,realm:i.realm,local_account_id:i.localAccountId,username:i.username,authority_type:i.authorityType,name:i.name,client_info:i.clientInfo,last_modification_time:i.lastModificationTime,last_modification_app:i.lastModificationApp,tenantProfiles:i.tenantProfiles?.map((e=>JSON.stringify(e)))}})),t}static serializeIdTokens(e){const t={};return Object.keys(e).map((function(r){const i=e[r];t[r]={home_account_id:i.homeAccountId,environment:i.environment,credential_type:i.credentialType,client_id:i.clientId,secret:i.secret,realm:i.realm}})),t}static serializeAccessTokens(e){const t={};return Object.keys(e).map((function(r){const i=e[r];t[r]={home_account_id:i.homeAccountId,environment:i.environment,credential_type:i.credentialType,client_id:i.clientId,secret:i.secret,realm:i.realm,target:i.target,cached_at:i.cachedAt,expires_on:i.expiresOn,extended_expires_on:i.extendedExpiresOn,refresh_on:i.refreshOn,key_id:i.keyId,token_type:i.tokenType,requestedClaims:i.requestedClaims,requestedClaimsHash:i.requestedClaimsHash,userAssertionHash:i.userAssertionHash}})),t}static serializeRefreshTokens(e){const t={};return Object.keys(e).map((function(r){const i=e[r];t[r]={home_account_id:i.homeAccountId,environment:i.environment,credential_type:i.credentialType,client_id:i.clientId,secret:i.secret,family_id:i.familyId,target:i.target,realm:i.realm}})),t}static serializeAppMetadata(e){const t={};return Object.keys(e).map((function(r){const i=e[r];t[r]={client_id:i.clientId,environment:i.environment,family_id:i.familyId}})),t}static serializeAllCache(e){return{Account:this.serializeAccounts(e.accounts),IdToken:this.serializeIdTokens(e.idTokens),AccessToken:this.serializeAccessTokens(e.accessTokens),RefreshToken:this.serializeRefreshTokens(e.refreshTokens),AppMetadata:this.serializeAppMetadata(e.appMetadata)}}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Dw extends Gv{constructor(e,t,r,i){super(t,r,e,i),this.cache={},this.changeEmitters=[],this.logger=e}registerChangeEmitter(e){this.changeEmitters.push(e)}emitChange(){this.changeEmitters.forEach((e=>e.call(null)))}cacheToInMemoryCache(e){const t={accounts:{},idTokens:{},accessTokens:{},refreshTokens:{},appMetadata:{}};for(const r in e){const i=e[r];if("object"==typeof i)if(i instanceof Uv)t.accounts[r]=i;else if(gv(i))t.idTokens[r]=i;else if(mv(i))t.accessTokens[r]=i;else if(yv(i))t.refreshTokens[r]=i;else{if(!Sv(r,i))continue;t.appMetadata[r]=i}}return t}inMemoryCacheToCache(e){let t=this.getCache();return t={...t,...e.accounts,...e.idTokens,...e.accessTokens,...e.refreshTokens,...e.appMetadata},t}getInMemoryCache(){this.logger.trace("Getting in-memory cache");return this.cacheToInMemoryCache(this.getCache())}setInMemoryCache(e){this.logger.trace("Setting in-memory cache");const t=this.inMemoryCacheToCache(e);this.setCache(t),this.emitChange()}getCache(){return this.logger.trace("Getting cache key-value store"),this.cache}setCache(e){this.logger.trace("Setting cache key value store"),this.cache=e,this.emitChange()}getItem(e){this.logger.tracePii(`Item key: ${e}`);return this.getCache()[e]}setItem(e,t){this.logger.tracePii(`Item key: ${e}`);const r=this.getCache();r[e]=t,this.setCache(r)}getAccountKeys(){const e=this.getInMemoryCache();return Object.keys(e.accounts)}getTokenKeys(){const e=this.getInMemoryCache();return{idToken:Object.keys(e.idTokens),accessToken:Object.keys(e.accessTokens),refreshToken:Object.keys(e.refreshTokens)}}getAccount(e){const t=this.getCachedAccountEntity(e);return t&&Uv.isAccountEntity(t)?this.updateOutdatedCachedAccount(e,t):null}getCachedAccountEntity(e){return this.getItem(e)?Object.assign(new Uv,this.getItem(e)):null}setAccount(e){const t=e.generateAccountKey();this.setItem(t,e)}getIdTokenCredential(e){const t=this.getItem(e);return gv(t)?t:null}setIdTokenCredential(e){const t=hv(e);this.setItem(t,e)}getAccessTokenCredential(e){const t=this.getItem(e);return mv(t)?t:null}setAccessTokenCredential(e){const t=hv(e);this.setItem(t,e)}getRefreshTokenCredential(e){const t=this.getItem(e);return yv(t)?t:null}setRefreshTokenCredential(e){const t=hv(e);this.setItem(t,e)}getAppMetadata(e){const t=this.getItem(e);return Sv(e,t)?t:null}setAppMetadata(e){const t=function({environment:e,clientId:t}){return[Ef,e,t].join(xf).toLowerCase()}(e);this.setItem(t,e)}getServerTelemetry(e){const t=this.getItem(e);return t&&function(e,t){const r=0===e.indexOf(Df.CACHE_KEY);let i=!0;return t&&(i=t.hasOwnProperty("failedRequests")&&t.hasOwnProperty("errors")&&t.hasOwnProperty("cacheHits")),r&&i}(e,t)?t:null}setServerTelemetry(e,t){this.setItem(e,t)}getAuthorityMetadata(e){const t=this.getItem(e);return t&&function(e,t){return!!t&&0===e.indexOf(Bf)&&t.hasOwnProperty("aliases")&&t.hasOwnProperty("preferred_cache")&&t.hasOwnProperty("preferred_network")&&t.hasOwnProperty("canonical_authority")&&t.hasOwnProperty("authorization_endpoint")&&t.hasOwnProperty("token_endpoint")&&t.hasOwnProperty("issuer")&&t.hasOwnProperty("aliasesFromNetwork")&&t.hasOwnProperty("endpointsFromNetwork")&&t.hasOwnProperty("expiresAt")&&t.hasOwnProperty("jwks_uri")}(e,t)?t:null}getAuthorityMetadataKeys(){return this.getKeys().filter((e=>this.isAuthorityMetadata(e)))}setAuthorityMetadata(e,t){this.setItem(e,t)}getThrottlingCache(e){const t=this.getItem(e);return t&&function(e,t){let r=!1;e&&(r=0===e.indexOf(zf));let i=!0;return t&&(i=t.hasOwnProperty("throttleTime")),r&&i}(e,t)?t:null}setThrottlingCache(e,t){this.setItem(e,t)}removeItem(e){this.logger.tracePii(`Item key: ${e}`);let t=!1;const r=this.getCache();return r[e]&&(delete r[e],t=!0),t&&(this.setCache(r),this.emitChange()),t}removeOutdatedAccount(e){this.removeItem(e)}containsKey(e){return this.getKeys().includes(e)}getKeys(){this.logger.trace("Retrieving all cache keys");const e=this.getCache();return[...Object.keys(e)]}async clear(){this.logger.trace("Clearing cache entries created by MSAL");this.getKeys().forEach((e=>{this.removeItem(e)})),this.emitChange()}static generateInMemoryCache(e){return Fw.deserializeAllCache(Fw.deserializeJSONBlob(e))}static generateJsonCache(e){return Mw.serializeAllCache(e)}updateCredentialCacheKey(e,t){const r=hv(t);if(e!==r){const i=this.getItem(e);if(i)return this.removeItem(e),this.setItem(r,i),this.logger.verbose(`Updated an outdated ${t.credentialType} cache key`),r;this.logger.error(`Attempted to update an outdated ${t.credentialType} cache key but no item matching the outdated key was found in storage`)}return e}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +const Rw={},Pw={},Ow={},zw={},Nw={};class qw{constructor(e,t,r){this.cacheHasChanged=!1,this.storage=e,this.storage.registerChangeEmitter(this.handleChangeEvent.bind(this)),r&&(this.persistence=r),this.logger=t}hasChanged(){return this.cacheHasChanged}serialize(){this.logger.trace("Serializing in-memory cache");let e=Mw.serializeAllCache(this.storage.getInMemoryCache());return this.cacheSnapshot?(this.logger.trace("Reading cache snapshot from disk"),e=this.mergeState(JSON.parse(this.cacheSnapshot),e)):this.logger.trace("No cache snapshot to merge"),this.cacheHasChanged=!1,JSON.stringify(e)}deserialize(e){if(this.logger.trace("Deserializing JSON to in-memory cache"),this.cacheSnapshot=e,this.cacheSnapshot){this.logger.trace("Reading cache snapshot from disk");const e=Fw.deserializeAllCache(this.overlayDefaults(JSON.parse(this.cacheSnapshot)));this.storage.setInMemoryCache(e)}else this.logger.trace("No cache snapshot to deserialize")}getKVStore(){return this.storage.getCache()}async getAllAccounts(){let e;this.logger.trace("getAllAccounts called");try{return this.persistence&&(e=new Sb(this,!0),await this.persistence.beforeCacheAccess(e)),this.storage.getAllAccounts()}finally{this.persistence&&e&&await this.persistence.afterCacheAccess(e)}}async getAccountByHomeId(e){const t=await this.getAllAccounts();return e&&t&&t.length&&t.filter((t=>t.homeAccountId===e))[0]||null}async getAccountByLocalId(e){const t=await this.getAllAccounts();return e&&t&&t.length&&t.filter((t=>t.localAccountId===e))[0]||null}async removeAccount(e){let t;this.logger.trace("removeAccount called");try{this.persistence&&(t=new Sb(this,!0),await this.persistence.beforeCacheAccess(t)),await this.storage.removeAccount(Uv.generateAccountCacheKey(e))}finally{this.persistence&&t&&await this.persistence.afterCacheAccess(t)}}handleChangeEvent(){this.cacheHasChanged=!0}mergeState(e,t){this.logger.trace("Merging in-memory cache with cache snapshot");const r=this.mergeRemovals(e,t);return this.mergeUpdates(r,t)}mergeUpdates(e,t){return Object.keys(t).forEach((r=>{const i=t[r];if(e.hasOwnProperty(r)){const t=null!==i,n="object"==typeof i,o=!Array.isArray(i),s=void 0!==e[r]&&null!==e[r];t&&n&&o&&s?this.mergeUpdates(e[r],i):e[r]=i}else null!==i&&(e[r]=i)})),e}mergeRemovals(e,t){this.logger.trace("Remove updated entries in cache");const r=e.Account?this.mergeRemovalsDict(e.Account,t.Account):e.Account,i=e.AccessToken?this.mergeRemovalsDict(e.AccessToken,t.AccessToken):e.AccessToken,n=e.RefreshToken?this.mergeRemovalsDict(e.RefreshToken,t.RefreshToken):e.RefreshToken,o=e.IdToken?this.mergeRemovalsDict(e.IdToken,t.IdToken):e.IdToken,s=e.AppMetadata?this.mergeRemovalsDict(e.AppMetadata,t.AppMetadata):e.AppMetadata;return{...e,Account:r,AccessToken:i,RefreshToken:n,IdToken:o,AppMetadata:s}}mergeRemovalsDict(e,t){const r={...e};return Object.keys(e).forEach((e=>{t&&t.hasOwnProperty(e)||delete r[e]})),r}overlayDefaults(e){return this.logger.trace("Overlaying input cache with the default cache"),{Account:{...Rw,...e.Account},IdToken:{...Pw,...e.IdToken},AccessToken:{...Ow,...e.AccessToken},RefreshToken:{...zw,...e.RefreshToken},AppMetadata:{...Nw,...e.AppMetadata}}}}var Uw=__webpack_require__(44040); +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Lw{static fromAssertion(e){const t=new Lw;return t.jwt=e,t}static fromCertificate(e,t,r){const i=new Lw;return i.privateKey=t,i.thumbprint=e,i.useSha256=!1,r&&(i.publicCertificate=this.parseCertificate(r)),i}static fromCertificateWithSha256Thumbprint(e,t,r){const i=new Lw;return i.privateKey=t,i.thumbprint=e,i.useSha256=!0,r&&(i.publicCertificate=this.parseCertificate(r)),i}getJwt(e,t,r){if(this.privateKey&&this.thumbprint)return this.jwt&&!this.isExpired()&&t===this.issuer&&r===this.jwtAudience?this.jwt:this.createJwt(e,t,r);if(this.jwt)return this.jwt;throw wy(ny)}createJwt(e,t,r){this.issuer=t,this.jwtAudience=r;const i=cv();this.expirationTime=i+600;const n={alg:this.useSha256?Em:km},o=this.useSha256?Tm:Bm;Object.assign(n,{[o]:Tw.base64EncodeUrl(this.thumbprint,"hex")}),this.publicCertificate&&Object.assign(n,{[Cm]:this.publicCertificate});const s={[Im]:this.jwtAudience,[Am]:this.expirationTime,[Fm]:this.issuer,[Mm]:this.issuer,[Dm]:i,[Rm]:e.createNewGuid()};return this.jwt=Uw.sign(s,this.privateKey,{header:n}),this.jwt}isExpired(){return this.expirationTime0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.username&&t.addCcsUpn(e.username),t.createQueryString()}}var $w=__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */class Gw{constructor(e){this.config=function({auth:e,broker:t,cache:r,system:i,telemetry:n}){const o={...hw,networkClient:new Db(i?.proxyUrl,i?.customAgentOptions),loggerOptions:i?.loggerOptions||pw,disableInternalRetries:i?.disableInternalRetries||!1};if(e.clientCertificate&&!e.clientCertificate.thumbprint&&!e.clientCertificate.thumbprintSha256)throw dw.createStateNotFoundError();return{auth:{...cw,...e},broker:{...t},cache:{...uw,...r},system:{...o,...i},telemetry:{...fw,...n}}}(e),this.cryptoProvider=new Aw,this.logger=new Qm(this.config.system.loggerOptions,"@azure/msal-node",jw),this.storage=new Dw(this.logger,this.config.auth.clientId,this.cryptoProvider,function(e){const t=e.cloudDiscoveryMetadata;let r;if(t)try{r=JSON.parse(t)}catch(e){throw Tg(fg)}return{canonicalAuthority:e.authority?Iv(e.authority):void 0,knownAuthorities:e.knownAuthorities,cloudDiscoveryMetadata:r}}(this.config.auth)),this.tokenCache=new qw(this.storage,this.logger,this.config.cache.cachePlugin)}async getAuthCodeUrl(e){this.logger.info("getAuthCodeUrl called",e.correlationId);const t={...e,...await this.initializeBaseRequest(e),responseMode:e.responseMode||ff.QUERY,authenticationScheme:Rf.BEARER},r=await this.buildOauthClientConfiguration(t.authority,t.correlationId,void 0,void 0,e.azureCloudOptions),i=new Tb(r);return this.logger.verbose("Auth code client created",t.correlationId),i.getAuthCodeUrl(t)}async acquireTokenByCode(e,t){this.logger.info("acquireTokenByCode called"),e.state&&t&&(this.logger.info("acquireTokenByCode - validating state"),this.validateState(e.state,t.state||""),t={...t,state:""});const r={...e,...await this.initializeBaseRequest(e),authenticationScheme:Rf.BEARER},i=this.initializeServerTelemetryManager(xm,r.correlationId);try{const n=await this.buildOauthClientConfiguration(r.authority,r.correlationId,i,void 0,e.azureCloudOptions),o=new Tb(n);return this.logger.verbose("Auth code client created",r.correlationId),await o.acquireToken(r,t)}catch(e){throw e instanceof Um&&e.setCorrelationId(r.correlationId),i.cacheFailedRequest(e),e}}async acquireTokenByRefreshToken(e){this.logger.info("acquireTokenByRefreshToken called",e.correlationId);const t={...e,...await this.initializeBaseRequest(e),authenticationScheme:Rf.BEARER},r=this.initializeServerTelemetryManager(Sm,t.correlationId);try{const i=await this.buildOauthClientConfiguration(t.authority,t.correlationId,r,void 0,e.azureCloudOptions),n=new Bb(i);return this.logger.verbose("Refresh token client created",t.correlationId),await n.acquireToken(t)}catch(e){throw e instanceof Um&&e.setCorrelationId(t.correlationId),r.cacheFailedRequest(e),e}}async acquireTokenSilent(e){const t={...e,...await this.initializeBaseRequest(e),forceRefresh:e.forceRefresh||!1},r=this.initializeServerTelemetryManager(bm,t.correlationId,t.forceRefresh);try{const i=await this.buildOauthClientConfiguration(t.authority,t.correlationId,r,void 0,e.azureCloudOptions),n=new Cb(i);return this.logger.verbose("Silent flow client created",t.correlationId),await n.acquireToken(t)}catch(e){throw e instanceof Um&&e.setCorrelationId(t.correlationId),r.cacheFailedRequest(e),e}}async acquireTokenByUsernamePassword(e){this.logger.info("acquireTokenByUsernamePassword called",e.correlationId);const t={...e,...await this.initializeBaseRequest(e)},r=this.initializeServerTelemetryManager(wm,t.correlationId);try{const i=await this.buildOauthClientConfiguration(t.authority,t.correlationId,r,void 0,e.azureCloudOptions),n=new Hw(i);return this.logger.verbose("Username password client created",t.correlationId),await n.acquireToken(t)}catch(e){throw e instanceof Um&&e.setCorrelationId(t.correlationId),r.cacheFailedRequest(e),e}}getTokenCache(){return this.logger.info("getTokenCache called"),this.tokenCache}validateState(e,t){if(!e)throw dw.createStateNotFoundError();if(e!==t)throw wy(zg)}getLogger(){return this.logger}setLogger(e){this.logger=e}async buildOauthClientConfiguration(e,t,r,i,n){this.logger.verbose("buildOauthClientConfiguration called",t);const o=n||this.config.auth.azureCloudOptions,s=await this.createAuthority(e,t,i,o);this.logger.info(`Building oauth client configuration with the following authority: ${s.tokenEndpoint}.`,t),r?.updateRegionDiscoveryMetadata(s.regionDiscoveryMetadata);return{authOptions:{clientId:this.config.auth.clientId,authority:s,clientCapabilities:this.config.auth.clientCapabilities},loggerOptions:{logLevel:this.config.system.loggerOptions.logLevel,loggerCallback:this.config.system.loggerOptions.loggerCallback,piiLoggingEnabled:this.config.system.loggerOptions.piiLoggingEnabled,correlationId:t},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.cryptoProvider,networkInterface:this.config.system.networkClient,storageInterface:this.storage,serverTelemetryManager:r,clientCredentials:{clientSecret:this.clientSecret,clientAssertion:await this.getClientAssertion(s)},libraryInfo:{sku:fm,version:jw,cpu:$w.arch||Gh.EMPTY_STRING,os:$w.platform||Gh.EMPTY_STRING},telemetry:this.config.telemetry,persistencePlugin:this.config.cache.cachePlugin,serializableCache:this.tokenCache}}async getClientAssertion(e){return this.developerProvidedClientAssertion&&(this.clientAssertion=Lw.fromAssertion(await Eb(this.developerProvidedClientAssertion,this.config.auth.clientId,e.tokenEndpoint))),this.clientAssertion&&{assertion:this.clientAssertion.getJwt(this.cryptoProvider,this.config.auth.clientId,e.tokenEndpoint),assertionType:mm}}async initializeBaseRequest(e){return this.logger.verbose("initializeRequestScopes called",e.correlationId),e.authenticationScheme&&e.authenticationScheme===Rf.POP&&this.logger.verbose("Authentication Scheme 'pop' is not supported yet, setting Authentication Scheme to 'Bearer' for request",e.correlationId),e.authenticationScheme=Rf.BEARER,this.config.cache.claimsBasedCachingEnabled&&e.claims&&!Bg.isEmptyObj(e.claims)&&(e.requestedClaimsHash=await this.cryptoProvider.hashString(e.claims)),{...e,scopes:[...e&&e.scopes||[],...tf],correlationId:e&&e.correlationId||this.cryptoProvider.createNewGuid(),authority:e.authority||this.config.auth.authority}}initializeServerTelemetryManager(e,t,r){const i={clientId:this.config.auth.clientId,correlationId:t,apiId:e,forceRefresh:r||!1};return new jm(i,this.storage)}async createAuthority(e,t,r,i){this.logger.verbose("createAuthority called",t);const n=Cv.generateAuthority(e,i),o={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,azureRegionConfiguration:r,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache};return lb(n,this.config.system.networkClient,this.storage,o,this.logger,t)}clearCache(){this.storage.clear()}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Ww{async listenForAuthCode(e,t){if(this.server)throw dw.createLoopbackServerAlreadyExistsError();return new Promise(((r,i)=>{this.server=Ab.createServer(((n,o)=>{const s=n.url;if(!s)return o.end(t||"Error occurred loading redirectUrl"),void i(dw.createUnableToLoadRedirectUrlError());if(s===Gh.FORWARD_SLASH)return void o.end(e||"Auth code was successfully acquired. You can close this window now.");const a=this.getRedirectUri(),l=_y(new URL(s,a).search)||{};l.code&&(o.writeHead(Jh,{location:a}),o.end()),l.error&&o.end(t||`Error occurred: ${l.error}`),r(l)})),this.server.listen(0,"127.0.0.1")}))}getRedirectUri(){if(!this.server||!this.server.listening)throw dw.createNoLoopbackServerExistsError();const e=this.server.address();if(!e||"string"==typeof e||!e.port)throw this.closeServer(),dw.createInvalidLoopbackAddressTypeError();const t=e&&e.port;return`${ym}${vm}:${t}`}closeServer(){this.server&&(this.server.close(),"function"==typeof this.server.closeAllConnections&&this.server.closeAllConnections(),this.server.unref(),this.server=void 0)}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Kw extends db{constructor(e){super(e)}async acquireToken(e){const t=await this.getDeviceCode(e);e.deviceCodeCallback(t);const r=cv(),i=await this.acquireTokenWithDeviceCode(e,t),n=new kb(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return n.validateTokenResponse(i),n.handleServerTokenResponse(i,this.authority,r,e)}async getDeviceCode(e){const t=this.createExtraQueryParameters(e),r=xy.appendQueryString(this.authority.deviceCodeEndpoint,t),i=this.createQueryString(e),n=this.createTokenRequestHeaders(),o={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return this.executePostRequestToDeviceCodeEndpoint(r,i,n,o)}createExtraQueryParameters(e){const t=new ab;return e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters),t.createQueryString()}async executePostRequestToDeviceCodeEndpoint(e,t,r,i){const{body:{user_code:n,device_code:o,verification_uri:s,expires_in:a,interval:l,message:d}}=await this.networkManager.sendPostRequest(i,e,{body:t,headers:r});return{userCode:n,deviceCode:o,verificationUri:s,expiresIn:a,interval:l,message:d}}createQueryString(e){const t=new ab;return t.addScopes(e.scopes),t.addClientId(this.config.authOptions.clientId),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),t.createQueryString()}continuePolling(e,t,r){if(r)throw this.logger.error("Token request cancelled by setting DeviceCodeRequest.cancel = true"),wy(Jg);if(t&&tt)throw this.logger.error(`User defined timeout for device code polling reached. The timeout was set for ${t}`),wy(ay);if(cv()>e)throw t&&this.logger.verbose(`User specified timeout ignored as the device code has expired before the timeout elapsed. The user specified timeout was set for ${t}`),this.logger.error(`Device code expired. Expiration time of device code was ${e}`),wy(Yg);return!0}async acquireTokenWithDeviceCode(e,t){const r=this.createTokenQueryParameters(e),i=xy.appendQueryString(this.authority.tokenEndpoint,r),n=this.createTokenRequestBody(e,t),o=this.createTokenRequestHeaders(),s=e.timeout?cv()+e.timeout:void 0,a=cv()+t.expiresIn,l=1e3*t.interval;for(;this.continuePolling(a,s,e.cancel);){const t={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},r=await this.executePostToTokenEndpoint(i,n,o,t,e.correlationId);if(!r.body||!r.body.error)return this.logger.verbose("Authorization completed successfully. Polling stopped."),r.body;if(r.body.error!==Gh.AUTHORIZATION_PENDING)throw this.logger.info("Unexpected error in polling from the server"),d=Nm,c=r.body.error,new Um(d,c?`${qm[d]} ${c}`:qm[d]);this.logger.info("Authorization pending. Continue polling."),await pv(l)}var d,c;throw this.logger.error("Polling stopped for unknown reasons."),wy(Qg)}createTokenRequestBody(e,t){const r=new ab;r.addScopes(e.scopes),r.addClientId(this.config.authOptions.clientId),r.addGrantType(vf),r.addDeviceCode(t.deviceCode);const i=e.correlationId||this.config.cryptoInterface.createNewGuid();return r.addCorrelationId(i),r.addClientInfo(),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&r.addServerTelemetry(this.serverTelemetryManager),(!Bg.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),r.createQueryString()}} +/*! @azure/msal-node v2.15.0 2024-10-03 */ +class Vw extends Gw{constructor(e){super(e),this.config.broker.nativeBrokerPlugin&&(this.config.broker.nativeBrokerPlugin.isBrokerAvailable?(this.nativeBrokerPlugin=this.config.broker.nativeBrokerPlugin,this.nativeBrokerPlugin.setLogger(this.config.system.loggerOptions)):this.logger.warning("NativeBroker implementation was provided but the broker is unavailable.")),this.skus=jm.makeExtraSkuString({libraryName:fm,libraryVersion:jw})}async acquireTokenByDeviceCode(e){this.logger.info("acquireTokenByDeviceCode called",e.correlationId);const t=Object.assign(e,await this.initializeBaseRequest(e)),r=this.initializeServerTelemetryManager(_m,t.correlationId);try{const i=await this.buildOauthClientConfiguration(t.authority,t.correlationId,r,void 0,e.azureCloudOptions),n=new Kw(i);return this.logger.verbose("Device code client created",t.correlationId),await n.acquireToken(t)}catch(e){throw e instanceof Um&&e.setCorrelationId(t.correlationId),r.cacheFailedRequest(e),e}}async acquireTokenInteractive(e){const t=e.correlationId||this.cryptoProvider.createNewGuid();this.logger.trace("acquireTokenInteractive called",t);const{openBrowser:r,successTemplate:i,errorTemplate:n,windowHandle:o,loopbackClient:s,...a}=e;if(this.nativeBrokerPlugin){const r={...a,clientId:this.config.auth.clientId,scopes:e.scopes||tf,redirectUri:`${ym}${vm}`,authority:e.authority||this.config.auth.authority,correlationId:t,extraParameters:{...a.extraQueryParameters,...a.tokenQueryParameters,[Vm]:this.skus},accountId:a.account?.nativeAccountId};return this.nativeBrokerPlugin.acquireTokenInteractive(r,o)}const{verifier:l,challenge:d}=await this.cryptoProvider.generatePkceCodes(),c=s||new Ww;let u={},p=null;try{const o=c.listenForAuthCode(i,n).then((e=>{u=e})).catch((e=>{p=e})),s=await this.waitForRedirectUri(c),h={...a,correlationId:t,scopes:e.scopes||tf,redirectUri:s,responseMode:ff.QUERY,codeChallenge:d,codeChallengeMethod:hf.S256},f=await this.getAuthCodeUrl(h);if(await r(f),await o,p)throw p;if(u.error)throw new Jm(u.error,u.error_description,u.suberror);if(!u.code)throw dw.createNoAuthCodeInResponseError();const m=u.client_info,g={code:u.code,codeVerifier:l,clientInfo:m||Gh.EMPTY_STRING,...h};return await this.acquireTokenByCode(g)}finally{c.closeServer()}}async acquireTokenSilent(e){const t=e.correlationId||this.cryptoProvider.createNewGuid();if(this.logger.trace("acquireTokenSilent called",t),this.nativeBrokerPlugin){const r={...e,clientId:this.config.auth.clientId,scopes:e.scopes||tf,redirectUri:`${ym}${vm}`,authority:e.authority||this.config.auth.authority,correlationId:t,extraParameters:{...e.tokenQueryParameters,[Vm]:this.skus},accountId:e.account.nativeAccountId,forceRefresh:e.forceRefresh||!1};return this.nativeBrokerPlugin.acquireTokenSilent(r)}return super.acquireTokenSilent(e)}async signOut(e){if(this.nativeBrokerPlugin&&e.account.nativeAccountId){const t={clientId:this.config.auth.clientId,accountId:e.account.nativeAccountId,correlationId:e.correlationId||this.cryptoProvider.createNewGuid()};await this.nativeBrokerPlugin.signOut(t)}await this.getTokenCache().removeAccount(e.account)}async getAllAccounts(){if(this.nativeBrokerPlugin){const e=this.cryptoProvider.createNewGuid();return this.nativeBrokerPlugin.getAllAccounts(this.config.auth.clientId,e)}return this.getTokenCache().getAllAccounts()}async waitForRedirectUri(e){return new Promise(((t,r)=>{let i=0;const n=setInterval((()=>{if(Om/Pm7200&&(t=r/2));return{status:e.status,access_token:e.body.access_token,expires_in:r,scope:e.body.resource,token_type:e.body.token_type,refresh_in:t,correlation_id:e.body.correlation_id||e.body.correlationId,error:"string"==typeof e.body.error?e.body.error:e.body.error?.code,error_description:e.body.message||("string"==typeof e.body.error?e.body.error_description:e.body.error?.message),error_codes:e.body.error_codes,timestamp:e.body.timestamp,trace_id:e.body.trace_id}}async acquireTokenWithManagedIdentity(e,t,r,i){const n=this.createRequest(e.resource,t),o=n.headers;o[nf]=Gh.URL_FORM_CONTENT_TYPE;const s={headers:o};Object.keys(n.bodyParameters).length&&(s.body=n.computeParametersBodyString());const a=cv();let l;try{l=n.httpMethod===cm?await this.networkClient.sendPostRequestAsync(n.computeUri(),s):await this.networkClient.sendGetRequestAsync(n.computeUri(),s)}catch(e){throw e instanceof Um?e:wy(Dg)}const d=new kb(t.id,this.nodeStorage,this.cryptoProvider,this.logger,null,null),c=await this.getServerTokenResponseAsync(l,this.networkClient,n,s);return d.validateTokenResponse(c,i),d.handleServerTokenResponse(c,r,a,e)}getManagedIdentityUserAssignedIdQueryParameterKey(e){switch(e){case sm:return this.logger.info("[Managed Identity] Adding user assigned client id to the request."),Jw;case am:return this.logger.info("[Managed Identity] Adding user assigned resource id to the request."),Qw;case lm:return this.logger.info("[Managed Identity] Adding user assigned object id to the request."),Yw;default:throw ew(qb)}}}Zw.getValidatedEnvVariableUrlString=(e,t,r,i)=>{try{return new xy(t).urlString}catch(t){throw i.info(`[Managed Identity] ${r} managed identity is unavailable because the '${e}' environment variable is malformed.`),ew(Qb[e])}};__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */__webpack_require__(23313);var Xw=__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */ +Xw.env.ProgramData,Xw.env.ProgramFiles;__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */__webpack_require__(65606); +/*! @azure/msal-node v2.15.0 2024-10-03 */const e_="1.0.0",t_=!k.Platform.isAndroidApp&&(0,k.requireApiVersion)("0.13.26")||k.Platform.isAndroidApp&&(0,k.requireApiVersion)("0.14.6"),r_=["User.Read","Files.ReadWrite","offline_access"],i_=`obsidian://${Q}`,n_={accessToken:"",clientID:B,authority:C,refreshToken:"",accessTokenExpiresInSeconds:0,accessTokenExpiresAtTime:0,deltaLink:"",username:"",credentialsShouldBeDeletedAtTime:0,emptyFile:"skip",kind:"onedrivefull"};const o_=(e,t)=>{const r=`/drive/root:/${t}`;let i=e;return"/"===e||""===e?r:(i.endsWith("/")&&(i=i.slice(0,i.length-1)),i.startsWith("/")?(console.warn(`why the path ${i} starts with '/'? but we just go on.`),i=`${r}${i}`):i=`${r}/${i}`,i)},s_=(e,t)=>{var r,i,n;let o="";const s=`/drive/root:/${t}`,a=`/drive/root:/${encodeURIComponent(t)}`;if(void 0===e.parentReference||null===e.parentReference||void 0===e.parentReference.path||null===e.parentReference.path)throw Error("x.parentReference.path is undefinded or null");const l=`${null===(r=e.parentReference)||void 0===r?void 0:r.path}/${e.name}`,d=l.startsWith(s),c=l.startsWith(a);if(d)o=l.substring(s.length+1);else{if(!c)throw Error(`we meet file/folder and do not know how to deal with it:\n${(e=>{var t,r,i;return null===(t=e.parentReference)||void 0===t||t.path,e.name,`parentPath="${null!==(i=null===(r=e.parentReference)||void 0===r?void 0:r.path)&&void 0!==i?i:"(no parentReference or path)"}", selfName="${e.name}"`})(e)}`);o=l.substring(a.length+1)}const u="folder"in e;u&&(o=`${o}/`);const p=null===(i=null==e?void 0:e.fileSystemInfo)||void 0===i?void 0:i.lastModifiedDateTime;if(null==p)throw Error(`onedrive cannot parse mtime: ${JSON.stringify(e,null,2)}`);let h=null===(n=null==e?void 0:e.fileSystemInfo)||void 0===n?void 0:n.createdDateTime;null==h&&(h=p);return{key:o,keyRaw:o,mtimeSvr:Date.parse(p),mtimeCli:Date.parse(p),ctimeCli:Date.parse(h),size:u?0:e.size,sizeRaw:u?0:e.size,synthesizedFile:!1}};class a_{constructor(e,t){this.onedriveFullConfig=e,this.saveUpdatedConfigFunc=t}getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.onedriveFullConfig.accessToken||""===this.onedriveFullConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now();if(this.onedriveFullConfig.accessTokenExpiresAtTime>e)return this.onedriveFullConfig.accessToken;{const o=yield(t=this.onedriveFullConfig.clientID,i=this.onedriveFullConfig.authority,n=this.onedriveFullConfig.refreshToken,r(void 0,void 0,void 0,(function*(){try{const e=yield(0,k.request)({url:`${i}/oauth2/v2.0/token`,method:"POST",contentType:"application/x-www-form-urlencoded",body:new URLSearchParams({tenant:"consumers",client_id:t,scope:r_.join(" "),refresh_token:n,grant_type:"refresh_token"}).toString()}),r=JSON.parse(e);return r.error,r}catch(e){throw console.error(e),e}})));if(void 0!==o.error){const e=o;throw Error(`Error while refreshing accessToken: ${e.error}, ${e.error_codes}: ${e.error_description}`)}const s=o;return this.onedriveFullConfig.accessToken=s.access_token,this.onedriveFullConfig.refreshToken=s.refresh_token,this.onedriveFullConfig.accessTokenExpiresInSeconds=s.expires_in,this.onedriveFullConfig.accessTokenExpiresAtTime=e+1e3*s.expires_in-12e4,yield this.saveUpdatedConfigFunc(),console.info("Onedrive accessToken updated"),this.onedriveFullConfig.accessToken}var t,i,n}))}}const l_=e=>{const t=m()(e);return t.accessToken="x",t.accessTokenExpiresInSeconds=1,t.accessTokenExpiresAtTime=1,t};class d_ extends Mp{constructor(e,t,r){super(),this.kind="onedrivefull",this.onedriveFullConfig=e,this.remoteBaseDir=this.onedriveFullConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.authGetter=new a_(e,r),this.foldersCreatedBefore=new Set}_init(){return r(this,void 0,void 0,(function*(){if(""===this.onedriveFullConfig.accessToken||""===this.onedriveFullConfig.refreshToken)throw Error("The user has not manually auth yet.");if(this.vaultFolderExists);else{const e=yield this._getJson("/drive/root/children");this.vaultFolderExists=e.value.filter((e=>e.name===this.remoteBaseDir)).length>0,this.vaultFolderExists||(console.info(`remote does not have folder /${this.remoteBaseDir}`),yield this._postJson("/drive/root/children",{name:`${this.remoteBaseDir}`,folder:{},"@microsoft.graph.conflictBehavior":"replace"}),console.info(`remote folder /${this.remoteBaseDir} created`),this.vaultFolderExists=!0)}}))}_buildUrl(e){let t="";if(e.startsWith("http://")||e.startsWith("https://"))t=e;else{t=`https://graph.microsoft.com/v1.0${encodeURI(e)}`}return t=t.replace(/#/g,"%23"),t}_getJson(e){return r(this,void 0,void 0,(function*(){const t=this._buildUrl(e);return console.debug(`getJson, theUrl=${t}`),JSON.parse(yield(0,k.request)({url:t,method:"GET",contentType:"application/json",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`,"Cache-Control":"no-cache"}}))}))}_postJson(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);return console.debug(`postJson, theUrl=${r}`),JSON.parse(yield(0,k.request)({url:r,method:"POST",contentType:"application/json",body:JSON.stringify(t),headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}))}))}_patchJson(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);return console.debug(`patchJson, theUrl=${r}`),JSON.parse(yield(0,k.request)({url:r,method:"PATCH",contentType:"application/json",body:JSON.stringify(t),headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}))}))}_deleteJson(e){return r(this,void 0,void 0,(function*(){const t=this._buildUrl(e);console.debug(`deleteJson, theUrl=${t}`),t_?yield(0,k.requestUrl)({url:t,method:"DELETE",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}):yield fetch(t,{method:"DELETE",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}})}))}_putArrayBuffer(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);console.debug(`putArrayBuffer, theUrl=${r}`);{const e=yield fetch(r,{method:"PUT",body:t,headers:{"Content-Type":I,Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}});return yield e.json()}}))}_putUint8ArrayByRange(e,t,i,n,o){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);console.debug(`putUint8ArrayByRange, theUrl=${r}, range=${i}-${n-1}, len=${n-i}, size=${o}`);{const e=yield fetch(r,{method:"PUT",body:t.subarray(i,n),headers:{"Content-Length":""+(n-i),"Content-Range":`bytes ${i}-${n-1}/${o}`,"Content-Type":I}});return yield e.json()}}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e="@odata.nextLink",t="@odata.deltaLink";let r=yield this._getJson(`/drive/root:/${this.remoteBaseDir}:/delta`);const i=r.value;for(;e in r;)r=yield this._getJson(r[e]),i.push(...m()(r.value));t in r&&(this.onedriveFullConfig.deltaLink=r[t],yield this.saveUpdatedConfigFunc());const n=i.map((e=>s_(e,this.remoteBaseDir))).filter((e=>"/"!==e.key));return n}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();const e="@odata.deltaLink",t=yield this._getJson(`/drive/root:/${this.remoteBaseDir}:/delta`),r=t.value;e in t&&(this.onedriveFullConfig.deltaLink=t[e],yield this.saveUpdatedConfigFunc());const i=r.map((e=>s_(e,this.remoteBaseDir))).filter((e=>"/"!==e.key));return i}))}stat(e){return r(this,void 0,void 0,(function*(){return yield this._init(),yield this._statFromRoot(o_(e,this.remoteBaseDir))}))}_statFromRoot(e){return r(this,void 0,void 0,(function*(){const t=yield this._getJson(`${e}?$select=cTag,eTag,fileSystemInfo,folder,file,name,parentReference,size`);return s_(t,this.remoteBaseDir)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not call mkdir on ${e}`);yield this._init();const r=o_(e,this.remoteBaseDir);return console.debug(`mkdir uploadFolder=${r}`),yield this._mkdirFromRoot(r,t,i)}))}_mkdirFromRoot(e,t,i){return r(this,void 0,void 0,(function*(){if(this.foldersCreatedBefore.has(e));else{const r={folder:{},"@microsoft.graph.conflictBehavior":"replace"},n={};if(void 0!==t&&0!==t){const e=new Date(t).toISOString();n.lastModifiedDateTime=e}if(void 0!==i&&0!==i){const e=new Date(i).toISOString();n.createdDateTime=e}Object.keys(n).length>0&&(r.fileSystemInfo=n),yield this._patchJson(e,r)}return yield this._statFromRoot(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`you should not call writeFile on ${e}`);yield this._init();const r=o_(e,this.remoteBaseDir);return console.debug(`uploadFile=${r}`),yield this._writeFileFromRoot(r,t,i,n,e,this.onedriveFullConfig.emptyFile)}))}_writeFileFromRoot(e,t,i,n,o,s){return r(this,void 0,void 0,(function*(){if(0===t.byteLength){if("error"===s)throw Error(`${o}: Empty file is not allowed in OneDrive, and please write something in it.`);return{key:o,keyRaw:o,mtimeSvr:i,mtimeCli:i,ctimeCli:n,size:0,sizeRaw:0,synthesizedFile:!0}}const r=new Date(n).toISOString(),a=new Date(i).toISOString(),l=6553600;if(t.byteLength<4e6)yield this._putArrayBuffer(`${e}:/content?${new URLSearchParams({"@microsoft.graph.conflictBehavior":"replace"})}`,t),0!==i&&0!==n&&(yield this._patchJson(e,{fileSystemInfo:{lastModifiedDateTime:a,createdDateTime:r}}));else{let o={item:{"@microsoft.graph.conflictBehavior":"replace"}};0!==i&&0!==n&&(o={item:{"@microsoft.graph.conflictBehavior":"replace",fileSystemInfo:{lastModifiedDateTime:a,createdDateTime:r}}});const s=yield this._postJson(`${e}:/createUploadSession`,o),d=s.uploadUrl;console.debug("uploadSession = "),console.debug(s);const c=new Uint8Array(t);let u=0;for(;u"===(yield this.getUserDisplayName()))throw Error("unknown display name!")}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){yield this._init();return(yield this._getJson("/me?$select=displayName")).displayName||""}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}getRevokeAddr(){return r(this,void 0,void 0,(function*(){return"https://account.live.com/consent/Manage"}))}allowEmptyFile(){return!1}}var c_=__webpack_require__(85403),u_=__webpack_require__.n(c_);const p_={accessToken:"",hostname:"eapi.pcloud.com",locationid:2,credentialsShouldBeDeletedAtTimeMs:0,emptyFile:"skip",kind:"pcloud"},h_=(e,t)=>{if(void 0===e.parentfolderid||0===e.parentfolderid)throw Error(`parentfolderid=${e.parentfolderid} should not be in fromRawResponseToEntity`);let r,i,n,o=e.name,s=0;if(void 0!==t&&""!==t&&"/"!==t){if(!t.endsWith("/"))throw Error(`parentFolderPath=${t} should not be in fromRawResponseToEntity`);o=`${t}${e.name}`}e.isfolder?(o=`${o}/`,n=e.folderid):(s=e.size,r=e.hash,i=`${e.hash}`,n=e.fileid);const a=new Date(e.modified).valueOf();return{key:o,keyRaw:o,mtimeCli:a,mtimeSvr:a,id:n,parentID:e.parentfolderid,isFolder:e.isfolder,size:s,sizeRaw:s,hash:i,hashPCloud:r,parentIDPath:t}},f_=e=>{var t;const r=[],i={};if(void 0===e.contents||0===e.contents.length)return{entities:r,key2Entity:i};let n=[];for(const r of null!==(t=e.contents)&&void 0!==t?t:[])n.push({folderPath:"",itself:r});for(;0!==n.length;){const t=[];for(const{folderPath:o,itself:s}of n){if(s.isfolder&&s.folderid===e.folderid);else{const e=h_(s,o);r.push(e),i[e.keyRaw]=e}if(s.isfolder&&void 0!==s.contents&&s.contents.length>0)for(const e of s.contents)if(""===o||"/"===o){const r={itself:e,folderPath:`${s.name}/`};t.push(r)}else{const r={itself:e,folderPath:`${o}${s.name}/`};t.push(r)}}n=t}return{entities:r,key2Entity:i}};class m_ extends Mp{constructor(e,t,r){super(),this.kind="pcloud",this.pCloudConfig=e,this.remoteBaseDir=this.pCloudConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.keyToPCloudEntity={},this.baseDirID=0,__webpack_require__.g.locationid=e.locationid,this.client=u_().createClient(e.accessToken)}_init(){return r(this,void 0,void 0,(function*(){if(this.vaultFolderExists);else{const e=yield this.client.listfolder(0,{recursive:!1});if(void 0===e.contents)throw Error("cannot listfolder of root!");const t=e.contents.filter((e=>e.isfolder&&e.name===this.remoteBaseDir));if(t.length>0){const e=t[0];this.baseDirID=e.folderid,this.vaultFolderExists=!0}else{const e=yield this.client.createfolder(this.remoteBaseDir,0);this.baseDirID=e.folderid,this.vaultFolderExists=!0}}}))}_getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.pCloudConfig.accessToken)throw Error("The user has not manually auth yet.");return this.pCloudConfig.accessToken}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e=yield this.client.listfolder(this.baseDirID,{recursive:!0}),{entities:t,key2Entity:r}=f_(e);return this.keyToPCloudEntity=Object.assign(this.keyToPCloudEntity,r),t}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();const e=yield this.client.listfolder(this.baseDirID,{recursive:!1}),{entities:t,key2Entity:r}=f_(e);return this.keyToPCloudEntity=Object.assign(this.keyToPCloudEntity,r),t}))}stat(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToPCloudEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);return t}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not mkdir on key=${e}`);yield this._init();const t=this.keyToPCloudEntity[e],r=null==t?void 0:t.id;if(void 0!==t&&void 0!==r)return t;const i=zp(e);let n,o;if(0===i.length)throw Error(`cannot getFolderLevels of ${e}`);if(1===i.length)o=this.baseDirID,n="";else{if(n=`${i[i.length-2]}/`,!(n in this.keyToPCloudEntity))throw Error(`parent of ${e}: ${n} is not created before??`);o=this.keyToPCloudEntity[n].id}let s=i[i.length-1];s=s.split("/").pop();const a=yield this.client.createfolder(s,o),l=h_(a,n);return this.keyToPCloudEntity[e]=l,l}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`should not call writeFile on ${e}`);yield this._init();const r=this.keyToPCloudEntity[e];null==r||r.id;let o,s;const a=zp(e);if(0===a.length)o=this.baseDirID,s="";else{if(s=`${a[a.length-1]}/`,!(s in this.keyToPCloudEntity))throw Error(`parent of ${e}: ${s} is not created before??`);o=this.keyToPCloudEntity[s].id}const l=e.split("/").pop(),d=new URLSearchParams({access_token:yield this._getAccessToken(),folderid:`${o}`,filename:l,nopartial:"1",renameifexists:"0",mtime:`${Math.floor(i/1e3)}`,ctime:`${Math.floor(n/1e3)}`}),c=`https://${this.pCloudConfig.hostname}/uploadfile?${d}`;if(t.byteLength>0){const r=yield fetch(c,{method:"PUT",body:t}),i=yield r.json(),n=h_(i.metadata[0],s);return this.keyToPCloudEntity[e]=n,n}{const r=new AbortController,i=setTimeout((()=>r.abort()),300);try{yield fetch(c,{method:"PUT",body:t,signal:r.signal})}catch(e){}finally{clearTimeout(i)}const n=new URLSearchParams({access_token:yield this._getAccessToken(),path:(u=e,p=this.remoteBaseDir,`/${p}/${u}`)}),o=`https://${this.pCloudConfig.hostname}/stat?${n}`,a=yield fetch(o),l=yield a.json(),d=h_(l.metadata,s);return this.keyToPCloudEntity[e]=d,d}var u,p}))}readFile(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToPCloudEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);const i=new URLSearchParams({access_token:yield this._getAccessToken(),forcedownload:"1",fileid:`${r}`}),n=`https://${this.pCloudConfig.hostname}/getfilelink?${i}`,o=(yield(0,k.requestUrl)(n)).json,s=`https://${o.hosts[0]}${o.path}`;return(yield(0,k.requestUrl)(s)).arrayBuffer}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=this.keyToPCloudEntity[e],r=null==t?void 0:t.id;if(void 0===t||void 0===r)throw Error(`no fileID found for key=${e}`);e.endsWith("/")?yield this.client.deletefolder(r):yield this.client.deletefile(r)}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}allowEmptyFile(){return!0}}class g_{constructor(e){this.accessToken=e,this.apiVersion=1,this.host="https://cloud-api.yandex.net"}_api(e,t,i,n,o,s){return r(this,void 0,void 0,(function*(){let r="";void 0!==n&&(r=`?${new URLSearchParams(n)}`);const a=`${this.host}/v${this.apiVersion}/${t}${r}`,l={Authorization:`OAuth ${this.accessToken}`};void 0!==s&&(l["Content-Type"]=s);const d=yield fetch(a,{method:e,headers:l,body:o});if(!(d.status>=200&&d.status<300))throw Error(JSON.stringify(yield d.json()));return"json"===i?yield d.json():"arrayBuffer"===i?yield d.arrayBuffer():"raw"===i?d:void 0}))}disk(){return r(this,void 0,void 0,(function*(){return yield this._api("GET","disk/","json")}))}diskResources(e,t,i,n){return r(this,void 0,void 0,(function*(){const r={path:e};return void 0!==t&&(r.fields=t.join(",")),void 0!==i&&(r.limit=`${i}`),void 0!==n&&(r.offset=`${n}`),yield this._api("GET","disk/resources","json",r)}))}diskResourcesFiles(e,t,i){return r(this,void 0,void 0,(function*(){const r={};return void 0!==e&&(r.fields=e.join(",")),void 0!==t&&(r.limit=`${t}`),void 0!==i&&(r.offset=`${i}`),yield this._api("GET","disk/resources/files","json",r)}))}diskResourcesPatch(e,t,i){return r(this,void 0,void 0,(function*(){const r={path:e};return void 0!==i&&(r.fields=i.join(",")),yield this._api("PATCH","disk/resources","json",r,JSON.stringify({custom_properties:t}),"application/json")}))}diskResoucesUpload(e,t,i){return r(this,void 0,void 0,(function*(){const r={path:e,overwrite:`${null!=i&&i}`},n=yield this._api("GET","disk/resources/upload","json",r);if(n.templated)throw Error(`do not know how to deal with upload link with templated: ${JSON.stringify(n)}`);const o=yield fetch(n.href,{method:n.method,body:t});if(200===o.status||201===o.status||202===o.status)return!0;throw Error(`upload failed. status=${o.status}, link=${n.href}`)}))}diskResoucesDownload(e){return r(this,void 0,void 0,(function*(){const t={path:e},r=yield this._api("GET","disk/resources/download","json",t);if(r.templated)throw Error(`do not know how to deal with download link with templated: ${JSON.stringify(r)}`);const i=yield fetch(r.href,{method:r.method});if(200===i.status||201===i.status||202===i.status)return yield i.arrayBuffer();throw Error(`download failed. status=${i.status}, link=${r.href}`)}))}diskResourcesDelete(e,t){return r(this,void 0,void 0,(function*(){const r={path:e,permanently:`${null!=t&&t}`},i=yield this._api("DELETE","disk/resources","raw",r);if(204!==i.status){if(202===i.status)return yield i.json();throw Error(`do not know how to deal with delete response ${i}`)}}))}diskResourcesPut(e,t){return r(this,void 0,void 0,(function*(){const r={path:e};return void 0!==t&&(r.fields=t.join(",")),yield this._api("PUT","disk/resources","json",r)}))}}const y_={accessToken:"",accessTokenExpiresInMs:0,accessTokenExpiresAtTimeMs:0,refreshToken:"",scope:"",kind:"yandexdisk"},v_=(e,t)=>{let r=e;return"/"===e||""===e?r=`disk:/${t}`:e.startsWith("/")?(console.warn(`why the path ${e} starts with '/'? but we just go on.`),r=`disk:/${t}${e}`):r=`disk:/${t}/${e}`,r.endsWith("/")&&(r=r.slice(0,r.length-1)),r},b_=(e,t)=>{var r,i;const n=((e,t,r)=>{if(e!==`disk:/${t}`&&!e.startsWith(`disk:/${t}/`))throw Error(`"${e}" doesn't starts with "disk:/${t}/"`);let i=e.slice(`disk:/${t}/`.length);return"dir"===r&&(i=`${i}/`),i})(e.path,t,e.type);if("dir"===e.type)return{key:n,keyRaw:n,size:0,sizeRaw:0};return{key:n,keyRaw:n,mtimeCli:Date.parse(null!==(i=null===(r=null==e?void 0:e.custom_properties)||void 0===r?void 0:r.rclone_modified)&&void 0!==i?i:e.modified).valueOf(),mtimeSvr:Date.parse(e.modified).valueOf(),size:e.size,sizeRaw:e.size,hash:e.sha256}},w_=["name","created","modified","path","type","size","sha256","md5","_embedded.limit","_embedded.offset","_embedded.total","_embedded.items.created","_embedded.items.modified","_embedded.items.path","_embedded.items.name","_embedded.items.type","_embedded.items.size","_embedded.items.sha256","_embedded.items.md5","_embedded.items.mime_type","_embedded.items.file","_embedded.items.custom_properties"];class __ extends Mp{constructor(e,t,r){super(),this.kind="yandexdisk",this.yandexDiskConfig=e,this.remoteBaseDir=this.yandexDiskConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r}_init(){return r(this,void 0,void 0,(function*(){var e,t,r,i;const n=yield this._getAccessToken(),o=new g_(n);if(this.vaultFolderExists);else{const n=[];let s=0;const a=100;let l=100;do{const d=yield o.diskResources("disk:/",w_,a,s);n.push(...null!==(t=null===(e=d._embedded)||void 0===e?void 0:e.items)&&void 0!==t?t:[]),l=null!==(i=null===(r=d._embedded)||void 0===r?void 0:r.total)&&void 0!==i?i:0,s+=a}while(se.name===this.remoteBaseDir)).length>0||(yield o.diskResourcesPut(`disk:/${this.remoteBaseDir}`)),this.vaultFolderExists=!0}}))}_getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.yandexDiskConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now();if(this.yandexDiskConfig.accessTokenExpiresAtTimeMs>e)return this.yandexDiskConfig.accessToken;const t=yield(i=this.yandexDiskConfig.refreshToken,r(void 0,void 0,void 0,(function*(){console.debug("refreshing token");const e=yield fetch("https://oauth.yandex.com/token",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:W,client_secret:K,grant_type:"refresh_token",refresh_token:i}).toString()});if(200===e.status){const t=yield e.json();return console.debug("new token obtained"),t}{const t=yield e.json();throw Error(`cannot refresh an access token: ${JSON.stringify(t)}`)}})));var i;return this.yandexDiskConfig.accessToken=t.access_token,this.yandexDiskConfig.accessTokenExpiresInMs=1e3*t.expires_in,this.yandexDiskConfig.accessTokenExpiresAtTimeMs=e+1e3*t.expires_in-12e4,yield this.saveUpdatedConfigFunc(),console.info("Yandex Disk accessToken updated"),this.yandexDiskConfig.accessToken}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e=new vh({concurrency:5,autoStart:!0});e.on("error",(t=>{throw e.pause(),e.clear(),t}));const t=[];let i=["/"];for(;0!==i.length;){const n=[];for(const o of i)e.add((()=>r(this,void 0,void 0,(function*(){const e=yield this._walkFolder(o);for(const r of e)t.push(r),r.keyRaw.endsWith("/")&&n.push(r.keyRaw)}))));yield e.onIdle(),i=n}return t}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();return yield this._walkFolder("/")}))}_walkFolder(e){return r(this,void 0,void 0,(function*(){var t,r,i,n;if(!e.endsWith("/"))throw Error(`should not call _walkFolder on ${e}`);const o=new g_(yield this._getAccessToken()),s=v_(e,this.remoteBaseDir),a=[];let l=0;let d=100;do{const e=yield o.diskResources(s,w_,100,l);a.push(...(null!==(r=null===(t=e._embedded)||void 0===t?void 0:t.items)&&void 0!==r?r:[]).map((e=>b_(e,this.remoteBaseDir)))),d=null!==(n=null===(i=e._embedded)||void 0===i?void 0:i.total)&&void 0!==n?n:0,l+=100}while(l0&&(yield r.diskResourcesPatch(n,o));return yield this.stat(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){yield this._init();const r=new g_(yield this._getAccessToken()),o=v_(e,this.remoteBaseDir);yield r.diskResoucesUpload(o,t,!0);const s={};void 0!==i&&(s.rclone_modified=Vp(i,!0)),void 0!==n&&(s.rclone_created=Vp(n,!0)),Object.keys(s).length>0&&(yield r.diskResourcesPatch(o,s));return yield this.stat(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=new g_(yield this._getAccessToken()),r=v_(e,this.remoteBaseDir);return yield t.diskResoucesDownload(r)}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}rm(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=new g_(yield this._getAccessToken()),r=v_(e,this.remoteBaseDir);yield t.diskResourcesDelete(r,!1)}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init()}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw yield this._init(),new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){yield fetch("https://oauth.yandex.com/revoke_token",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({client_id:W,client_secret:K,access_token:this.yandexDiskConfig.refreshToken}).toString()})}))}allowEmptyFile(){return!0}}function x_(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`should not call ${e} in copyFolder`);const r=yield t.stat(e);return{entity:yield i.mkdir(e,r.mtimeCli),content:void 0}}))}function S_(e,t,i){return r(this,void 0,void 0,(function*(){var r;if(e.endsWith("/"))throw Error(`should not call ${e} in copyFile`);const n=yield t.stat(e),o=yield t.readFile(e);if(void 0===n.size||0===n.size)n.size=o.byteLength;else if(n.size!==o.byteLength)throw Error(`error copying ${t.kind}=>${i.kind}: size not matched`);if(void 0===n.mtimeCli)throw Error(`error copying ${t.kind}=>${i.kind}, no mtimeCli`);return{entity:yield i.writeFile(e,o,n.mtimeCli,null!==(r=n.ctimeCli)&&void 0!==r?r:n.mtimeCli),content:o}}))}var k_=__webpack_require__(73790),E_=__webpack_require__.n(k_),T_=__webpack_require__(98860),B_=__webpack_require__(66604);(0,T_.extendPrototype)(E_()),(0,B_.extendPrototype)(E_());const C_=20240220,I_="remotelysavedb",A_=(e,t,i,n,o)=>r(void 0,void 0,void 0,(function*(){if(t!==i){if(t<20220326)throw Error("You are using a very old version of Remotely Save. No way to auto update internal DB. Please install and enable 0.3.40 firstly, then install a later version.");if(20220326===t&&20240220===i)return yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){const r=20240220;console.debug("start upgrading internal db from 20220326 to 20240220");const n=(e=>{const t=[];for(const r of e){const e={key:r.localKey,keyEnc:r.remoteKey,keyRaw:void 0!==r.remoteKey&&""!==r.remoteKey?r.remoteKey:r.localKey,mtimeCli:r.localMtime,mtimeSvr:r.remoteMtime,size:r.localSize,sizeEnc:r.remoteSize,sizeRaw:void 0!==r.remoteKey&&""!==r.remoteKey?r.remoteSize:r.localSize,etag:r.remoteExtraKey};t.push(e)}return t})(yield F_(e,t));for(const r of n)yield D_(e,t,i,r);yield e.versionTbl.setItem(`${t}\tversion`,r),console.debug("finish upgrading internal db from 20220326 to 20240220")})))(e,n,o);if(ir(void 0,void 0,void 0,(function*(){var i;return yield Promise.all((null!==(i=yield e.syncMappingTbl.keys())&&void 0!==i?i:[]).filter((e=>e.startsWith(`${t}\t`))).map((t=>r(void 0,void 0,void 0,(function*(){return yield e.syncMappingTbl.getItem(t)})))))})),M_=e=>r(void 0,void 0,void 0,(function*(){const t=Date.now()-864e5;let r=(yield e.syncPlansTbl.keys()).map((e=>{const r=Number.parseInt(e.split("\t")[1]);return{ts:r,key:e,expired:r<=t}}));const i=new Set(r.filter((e=>e.expired)).map((e=>e.key)));r.length-i.size>20&&(r=r.filter((e=>!e.expired)),r.sort(((e,t)=>-(e.ts-t.ts))),r.slice(20).forEach((e=>{i.add(e.key)}))),yield e.syncPlansTbl.removeItems(Array.from(i))})),D_=(e,t,i,n)=>r(void 0,void 0,void 0,(function*(){yield e.prevSyncRecordsTbl.setItem(`${t}\t${i}\t${n.key}`,n)})),R_=(e,t,i,n)=>r(void 0,void 0,void 0,(function*(){yield e.prevSyncRecordsTbl.removeItem(`${t}\t${i}\t${n}`)})),P_=(e,t,i)=>r(void 0,void 0,void 0,(function*(){yield e.simpleKVForMiscTbl.setItem(`${t}-lastSuccessSyncMillis`,i)})),O_=(e,t)=>r(void 0,void 0,void 0,(function*(){return yield e.simpleKVForMiscTbl.getItem(`${t}-lastSuccessSyncMillis`)})),z_=(e,t,i)=>r(void 0,void 0,void 0,(function*(){yield e.simpleKVForMiscTbl.setItem(`${t}-lastFailedSyncMillis`,i)})),N_=(e,t)=>r(void 0,void 0,void 0,(function*(){return yield e.simpleKVForMiscTbl.getItem(`${t}-lastFailedSyncMillis`)}));__webpack_require__(48287).Buffer;function q_(e,t){let r={};for(let e=0;er));a++);if(an(e,"a"))),U_(t,r).forEach((e=>n(e,"b"))),i.sort(((e,t)=>e.oStart-t.oStart));let o=[],s=0;function a(e){e>s&&(o.push({stable:!0,buffer:"o",bufferStart:s,bufferLength:e-s,bufferContent:t.slice(s,e)}),s=e)}for(;i.length;){let n=i.shift(),l=n.oStart,d=n.oStart+n.oLength,c=[n];for(a(l);i.length;){const e=i[0],t=e.oStart;if(t>d)break;d=Math.max(d,t+e.oLength),c.push(i.shift())}if(1===c.length){if(n.abLength>0){const t="a"===n.ab?e:r;o.push({stable:!0,buffer:n.ab,bufferStart:n.abStart,bufferLength:n.abLength,bufferContent:t.slice(n.abStart,n.abStart+n.abLength)})}}else{let i={a:[e.length,-1,t.length,-1],b:[r.length,-1,t.length,-1]};for(;c.length;){n=c.shift();const e=n.oStart,t=e+n.oLength,r=n.abStart,o=r+n.abLength;let s=i[n.ab];s[0]=Math.min(r,s[0]),s[1]=Math.max(o,s[1]),s[2]=Math.min(e,s[2]),s[3]=Math.max(t,s[3])}const s=i.a[0]+(l-i.a[2]),a=i.a[1]+(d-i.a[3]),u=i.b[0]+(l-i.b[2]),p=i.b[1]+(d-i.b[3]);let h={stable:!1,aStart:s,aLength:a-s,aContent:e.slice(s,a),oStart:l,oLength:d-l,oContent:t.slice(l,d),bStart:u,bLength:p-u,bContent:r.slice(u,p)};o.push(h)}s=d}return a(t.length),o}(e,t,r);let s=[];function a(){s.length&&n.push({ok:s}),s=[]}return o.forEach((e=>{e.stable?s.push(...e.bufferContent):i.excludeFalseConflicts&&function(e,t){if(e.length!==t.length)return!1;for(let r=0;r{if(e.ok)l=l.concat(e.ok);else{const t=function(e,t){const r=q_(e,t);let i=[],n=e.length,o=t.length,s={common:[]};function a(){s.common.length&&(s.common.reverse(),i.push(s),s={common:[]})}for(let l=r;null!==l;l=l.chain){let r={buffer1:[],buffer2:[]};for(;--n>l.buffer1index;)r.buffer1.push(e[n]);for(;--o>l.buffer2index;)r.buffer2.push(t[o]);(r.buffer1.length||r.buffer2.length)&&(a(),r.buffer1.reverse(),r.buffer2.reverse(),i.push(r)),n>=0&&s.common.push(e[n])}return a(),i.reverse(),i}(e.conflict.a,e.conflict.b);for(let e=0;e>>>>>>"].includes(n[e])&&(n[e]="`"+n[e]+"`");return{conflict:i,result:n}}function G_(e,t){const r=e.trim(),i=t.trim();if(""===r&&""===i)return r.length>=i.length?e:t;if(""===i)return e;if(""===r)return t;const n=function(e,t){const r=e.split("\n");let i=q_(r,t.split("\n"));const n=[];do{n.unshift(r[i.buffer1index]),i=i.chain}while(null!=i&&-1!==i.buffer1index);return n.join("\n")}(e,t);return $_(e,n,t).result.join("\n")}function W_(e,t,i,n){return r(this,void 0,void 0,(function*(){var r,o,s;if(e.endsWith("/"))throw Error(`should not call ${e} in mergeFile`);if(!e.endsWith(".md")&&!e.endsWith(".markdown"))throw Error("currently only support markdown files in mergeFile");const[a,l]=yield Promise.all([t.readFile(e),i.readFile(e)]);let d;const c=new TextDecoder("utf-8");if(Fp()(a,l))d=a;else if(null==n){const e=G_(c.decode(a),c.decode(l));d=(new TextEncoder).encode(e).buffer}else{const e=function(e,t,r){return $_(e,r,t).result.join("\n")}(c.decode(a),c.decode(l),c.decode(n));d=(new TextEncoder).encode(e).buffer}const u=Date.now(),p=yield i.writeFile(e,d,u,u);yield t.writeFile(e,d,null!==(r=p.mtimeCli)&&void 0!==r?r:u,null!==(s=null!==(o=p.ctimeCli)&&void 0!==o?o:p.mtimeCli)&&void 0!==s?s:u);return{entity:p,content:d}}))}function K_(e){if(""===e||"."===e||".."===e||"/"===e||e.endsWith("/"))throw Error(`we cannot rename key=${e}`);const t=e.split("/"),r=t[t.length-1],i=r.split(".");if(0===i.length)throw Error(`we cannot rename key=${e}`);if(1===i.length)t[t.length-1]=`${r}.dup`;else if(2===i.length)""===i[0]?t[t.length-1]=`${r}.dup`:""===i[1]?t[t.length-1]=`${i[0]}.dup`:t[t.length-1]=`${i[0]}.dup.${i[1]}`;else{const e=i.slice(0,i.length-1).join("."),r=i[i.length-1];t[t.length-1]=`${e}.dup.${r}`}return t.join("/")}function V_(e,t,i,n,o,s){return r(this,void 0,void 0,(function*(){var r,a,l,d,c,u;console.debug(`tryDuplicateFileForSameSizes: ${e}`);const p=yield n.readFile(e),h=yield i.readFile(e),f=function(e,t){if(e.byteLength!==t.byteLength)return!1;const r=new Uint8Array(e),i=new Uint8Array(t);for(let e=0;er(void 0,void 0,void 0,(function*(){yield e.fileContentHistoryTbl.setItem(`${t}\t${i}\t${n.key}`,o)})),Q_=(e,t,i,n)=>r(void 0,void 0,void 0,(function*(){return yield e.fileContentHistoryTbl.getItem(`${t}\t${i}\t${n.key}`)})),Z_=(e,t,i,n)=>r(void 0,void 0,void 0,(function*(){yield e.fileContentHistoryTbl.removeItem(`${t}\t${i}\t${n}`)})),X_=(e,t)=>{const r=Object.assign({},e);return void 0!==r.mtimeCli&&(0===r.mtimeCli?r.mtimeCli=void 0:("s3"!==t&&"dropbox"!==t||(r.mtimeCli=1e3*Math.floor(r.mtimeCli/1e3)),r.mtimeCliFmt=Vp(r.mtimeCli))),void 0!==r.ctimeCli&&(0===r.ctimeCli?r.ctimeCli=void 0:("s3"!==t&&"dropbox"!==t||(r.ctimeCli=1e3*Math.floor(r.ctimeCli/1e3)),r.ctimeCliFmt=Vp(r.ctimeCli))),void 0!==r.mtimeSvr&&(0===r.mtimeSvr?r.mtimeSvr=void 0:("s3"!==t&&"dropbox"!==t||(r.mtimeSvr=1e3*Math.floor(r.mtimeSvr/1e3)),r.mtimeSvrFmt=Vp(r.mtimeSvr))),void 0!==r.prevSyncTime&&(0===r.prevSyncTime?r.prevSyncTime=void 0:("s3"!==t&&"dropbox"!==t||(r.prevSyncTime=1e3*Math.floor(r.prevSyncTime/1e3)),r.prevSyncTimeFmt=Vp(r.prevSyncTime))),r},ex=e=>{if(!e.key.endsWith("/")&&void 0===e.mtimeCli&&void 0===e.mtimeSvr)throw e.key===e.keyEnc?Error(`Your remote file ${e.key} has last modified time 0, don't know how to deal with it.`):Error(`Your remote file ${e.key} (encrypted as ${e.keyEnc}) has last modified time 0, don't know how to deal with it.`);return e},tx=(e,t)=>{if(!t.startsWith("."))throw Error(`configDir should starts with . but we get ${t}`);return e===t||e.startsWith(`${t}/`)},rx=(e,t,r,i,n,o,s)=>{if(void 0===e)throw Error("checkIsSkipItemOrNotByName meets undefinded key!");let a,l=!1,d=!1;if(void 0!==s&&s.length>0)for(const t of s)""!==t.trim()&&(l=!0,Rp()(t,"A").test(e)&&(d=!0));l&&!d&&(a=!0);let c=!1;if(void 0!==o&&o.length>0)for(const t of o)""!==t.trim()&&Rp()(t,"A").test(e)&&void 0===a&&(c=!0,a=!0);void 0===a&&(t?tx(e,n)&&(a=!1):r&&((e,t)=>{if(!t.startsWith("."))throw Error(`configDir should starts with . but we get ${t}`);return e===t||e===`${t}/`||e===`${t}/bookmarks.json`})(e,n)?a=!1:tx(e,n)&&(a=!0)),Yp(e,[])&&void 0===a&&(c=!0,a=!0);const u=Op(e,!0,!1)||!i&&Op(e,!1,!0)||"/"===e||"_remotely-save-metadata-on-remote.json"===e||"_remotely-save-metadata-on-remote.bin"===e;if(void 0===a&&(c=u,a=u),void 0===a)throw Error(`no finalIsIgnored in checkIsSkipItemOrNotByName for ${e}`);return{enableAllowMode:l,isExplictlyAllowed:d,isExplictlyIgnored:c,finalIsIgnored:a}},ix=(e,t,i,n,o,s,a,l,d,c,u,p)=>r(void 0,void 0,void 0,(function*(){null==p||p.addIndent(),null==p||p.insert("ensembleMixedEnties: enter"),null==p||p.insertSize("sizeof localEntityList",e),null==p||p.insertSize("sizeof prevSyncEntityList",t),null==p||p.insertSize("sizeof remoteEntityList",i);const r={},h={};let f=0;for(const e of i){const t=ex(X_(e,u)),i=t.key,c=rx(i,n,o,a,s,l,d);h[i]=c,c.finalIsIgnored&&!i.startsWith(s)&&(f+=1),r[i]={key:i,remote:t}}if(null==p||p.insert("ensembleMixedEnties: finish remote"),null==p||p.insertSize("sizeof finalMappings",r),Object.keys(r).filter((e=>!e.startsWith(s))).length-f==0||0===e.filter((e=>{var t;return!(null===(t=e.key)||void 0===t?void 0:t.startsWith(s))})).length);else for(const e of t){const t=e.key;if(!(t in h)){const e=rx(t,n,o,a,s,l,d);h[t]=e}const i=yield c.encryptEntity(X_(e,u));r.hasOwnProperty(t)?r[t].prevSync=i:r[t]={key:t,prevSync:i}}null==p||p.insert("ensembleMixedEnties: finish prevSync"),null==p||p.insertSize("sizeof finalMappings",r);for(const t of e){const e=t.key;if(!(e in h)){const t=rx(e,n,o,a,s,l,d);h[e]=t}const i=yield c.encryptEntity(X_(t,u));r.hasOwnProperty(e)?r[e].local=i:r[e]={key:e,local:i}}null==p||p.insert("ensembleMixedEnties: finish local"),null==p||p.insertSize("sizeof finalMappings",r);const m=(e=>{const t=Object.keys(e),r=t.sort(((e,t)=>e.length-t.length)),i=new Set;for(const t of r)if(e[t].isExplictlyIgnored)e[t].finalIsIgnored=!0,i.add(t);else{const r=zp(t,!0).reverse();for(const n of r)if(i.has(n)){e[t].isExplictlyIgnored=!0,e[t].finalIsIgnored=!0,i.add(t);break}}let n=!1;if(t.length>0&&void 0!==t[0]&&void 0!==e[t[0]]&&(n=e[t[0]].enableAllowMode),n)for(let t=0;t(void 0!==t&&t>0&&(e.mtimeCli=t),e),ox=(e,t,i,n,o,s,a,l)=>r(void 0,void 0,void 0,(function*(){var d;if("only_history"===n.decision)yield R_(a,t,i,e),"smart_conflict"===l&&(yield Z_(a,t,i,e));else if("local_is_created_too_large_then_do_nothing"===n.decision||"remote_is_created_too_large_then_do_nothing"===n.decision||"folder_to_skip"===n.decision);else if("equal"===n.decision||"conflict_created_then_do_nothing"===n.decision||"folder_existed_both_then_do_nothing"===n.decision){if(void 0!==n.prevSync){if("smart_conflict"===l&&H_(n.local)){const e=yield Q_(a,t,i,n.local);null==e&&(yield Y_(a,t,i,n.local,yield o.readFile(n.local.keyRaw)))}}else if(void 0!==n.remote){let e=n.remote;e=nx(e,null===(d=n.local)||void 0===d?void 0:d.mtimeCli),void 0!==e&&(yield D_(a,t,i,e),"smart_conflict"===l&&H_(e)&&(yield Y_(a,t,i,e,yield o.readFile(e.keyRaw))))}}else if("local_is_modified_then_push"===n.decision||"local_is_created_then_push"===n.decision||"folder_existed_local_then_also_create_remote"===n.decision||"conflict_created_then_keep_local"===n.decision||"conflict_modified_then_keep_local"===n.decision){const e=(yield o.stat(n.key)).mtimeCli,{entity:d,content:c}=yield function(e,t,i){return r(this,void 0,void 0,(function*(){return e.endsWith("/")?yield x_(e,t,i):yield S_(e,t,i)}))}(n.key,o,s);nx(d,e),yield D_(a,t,i,d),"smart_conflict"===l&&H_(d)&&(yield Y_(a,t,i,d,c))}else if("remote_is_modified_then_pull"===n.decision||"remote_is_created_then_pull"===n.decision||"conflict_created_then_keep_remote"===n.decision||"conflict_modified_then_keep_remote"===n.decision||"folder_existed_remote_then_also_create_local"===n.decision){let e,r;if(n.key.endsWith("/"))yield o.mkdir(n.key);else{const{entity:t,content:i}=yield S_(n.key,s,o);e=t,r=i}yield D_(a,t,i,n.remote),"smart_conflict"===l&&H_(n.remote)&&(yield Y_(a,t,i,n.remote,r))}else if("local_is_deleted_thus_also_delete_remote"===n.decision)yield s.rm(n.key),yield R_(a,t,i,n.key),"smart_conflict"===l&&H_(n.remote)&&(yield Z_(a,t,i,n.key));else if("remote_is_deleted_thus_also_delete_local"===n.decision)yield o.rm(n.key),yield R_(a,t,i,n.key),"smart_conflict"===l&&H_(n.local)&&(yield Z_(a,t,i,n.key));else if("conflict_created_then_smart_conflict"===n.decision||"conflict_modified_then_smart_conflict"===n.decision)if(H_(n.local,n.remote)){const e=yield Q_(a,t,i,n.local),{entity:r,content:l}=yield W_(n.key,o,s,e);yield D_(a,t,i,r),yield Y_(a,t,i,r,l)}else{yield R_(a,t,i,n.key);const e=(yield o.stat(n.key)).mtimeCli;yield J_(n.key,o,s,(n=>r(void 0,void 0,void 0,(function*(){void 0!==n&&(nx(n,e),yield D_(a,t,i,n))}))),(e=>r(void 0,void 0,void 0,(function*(){void 0!==e&&(yield D_(a,t,i,e))}))))}else if("folder_to_be_created"===n.decision){yield o.mkdir(n.key);const{entity:e}=yield x_(n.key,o,s);yield D_(a,t,i,e)}else{if("folder_to_be_deleted_on_both"!==n.decision&&"folder_to_be_deleted_on_local"!==n.decision&&"folder_to_be_deleted_on_remote"!==n.decision)throw Error(`don't know how to dispatch decision: ${JSON.stringify(n)}`);"folder_to_be_deleted_on_both"!==n.decision&&"folder_to_be_deleted_on_local"!==n.decision||(yield o.rm(n.key)),"folder_to_be_deleted_on_both"!==n.decision&&"folder_to_be_deleted_on_remote"!==n.decision||(yield s.rm(n.key)),yield R_(a,t,i,n.key)}})),sx=(e,t,i,n,o,s,a,l,d,c,u,p,f)=>r(void 0,void 0,void 0,(function*(){null==c||c.addIndent(),null==c||c.insert("doActualSync: enter"),console.debug(`concurrency === ${s}`);const{onlyMarkSyncedOps:m,folderCreationOps:g,deletionOps:y,uploadDownloads:v,allFilesCount:b,realModifyDeleteCount:w,realTotalCount:_}=(e=>{const t=[],r=[],i=[],n=[],o=Object.keys(e).sort(((e,t)=>t.length-e.length));let s=0,a=0,l=0;for(let d=0;d=0&&w>=0&&b>0)if(100===a&&w===b);else if(100*w>=b*a){const e=l(a,w,b);throw null==c||c.insert("doActualSync: error branch"),null==c||c.removeIndent(),Error(e)}const x=[m,g,y,v],S=["1. record the items already being synced","2. create all folders from shadowest to deepest","3. delete files and folders from deepest to shadowest",`4. upload or download files in parallel, with the desired concurrency=${s}`];let k=0;for(let e=0;er(void 0,void 0,void 0,(function*(){yield null==f?void 0:f(p,k,_,a,s.decision),(void 0===s.change||s.change)&&(k+=1),yield ox(a,n,o,s,t,i,d,u)}));c.add(h).catch((e=>{const t=`${a}: ${e.message}`;m.push(new Error(t)),m.length>=3&&(g=!0,c.pause(),c.clear())}))}if(yield c.onIdle(),m.length>0)throw g&&m.push(new Error("too many errors, stop the remaining tasks")),new h(m)}null==c||c.insert(`doActualSync: step ${e} end`),null==c||c.removeIndent()}null==c||c.insert("doActualSync: exit"),null==c||c.removeIndent()}));function ax(e,t,i,n,o,s,a,l,d,c,u,p,h,f,m,g,y,v,b){return r(this,void 0,void 0,(function*(){var w,_,x,S,k,E,T,B,C,I,A;console.info("startting sync."),f(!0);let F=!0,M=0;try{if(yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){if(console.debug("checkProRunnableAndFixInplace"),void 0===e.pro||void 0===e.pro.refreshToken)throw Error('you need to "connect" to your account to use PRO features');for(const r of e.pro.enabledProFeatures){const n=r.expireAtTimeMs>=Date.now()+3456e6,o=r.expireAtTimeMs<=Date.now();if(n||o){console.info("the pro feature is too far in the future and has expired, check again."),yield ue(e.pro,t,i);break}}const r=[];"smart_conflict"===e.conflictAction&&(1===e.pro.enabledProFeatures.filter((e=>"feature-smart_conflict"===e.featureName)).length||r.push("You're trying to use \"smart conflict\" PRO feature but you haven't subscribe to it."));const n=[{feature:"feature-google_drive",service:"googledrive",name:"Google Drive"},{feature:"feature-onedrive_full",service:"onedrivefull",name:"Onedrive (Full)"},{feature:"feature-box",service:"box",name:"Box"},{feature:"feature-pcloud",service:"pcloud",name:"pCloud"},{feature:"feature-yandex_disk",service:"yandexdisk",name:"Yandex Disk"},{feature:"feature-koofr",service:"koofr",name:"Koofr"},{feature:"feature-azure_blob_storage",service:"azureblobstorage",name:"Azure Blob Storage"}];for(const{feature:t,service:i,name:o}of n)console.debug(`checking "${t}", serviceType=${e.serviceType}`),e.serviceType===i&&(1===e.pro.enabledProFeatures.filter((e=>e.featureName===t)).length||r.push(`You're trying to use "sync with ${o}" PRO feature but you haven't subscribe to it.`));if(0!==r.length)throw Error(r.join("\n\n"));return!0})))(c,u,p),yield null==m?void 0:m(s,M),M=1,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F),null==n||n.insert("start big sync func"),M=2,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F),i.innerFs!==t)throw Error("your enc should has inner of the remote");const f=yield i.isPasswordOk();if(!f.ok)throw Error(f.reason);null==n||n.insert(`finish step${M} (list partial remote and check password)`),M=3,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F);const g=yield i.walk();null==n||n.insert(`finish step${M} (list remote)`),M=4,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F);const D=yield e.walk();null==n||n.insert(`finish step${M} (list local)`),M=5,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F);const R=yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){const r=[],n=yield e.prevSyncRecordsTbl.getItems();for(const e of Object.getOwnPropertyNames(n))if(e.startsWith(`${t}\t${i}\t`)){const t=n[e];null!==t&&r.push(t)}return r})))(o,l,a);null==n||n.insert(`finish step${M} (prev sync)`),M=6,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F);let P=yield ix(D,R,g,null!==(w=c.syncConfigDir)&&void 0!==w&&w,null!==(_=c.syncBookmarks)&&void 0!==_&&_,d,null!==(x=c.syncUnderscoreItems)&&void 0!==x&&x,null!==(S=c.ignorePaths)&&void 0!==S?S:[],null!==(k=c.onlyAllowPaths)&&void 0!==k?k:[],i,c.serviceType,n);null==n||n.insert(`finish step${M} (build partial mixedEntity)`),P=yield((e,t,i,n,o,s,a,l)=>r(void 0,void 0,void 0,(function*(){var r,d,c,u,p,h,f,m;null==o||o.addIndent(),null==o||o.insert("getSyncPlanInplace: enter");const g=Object.keys(e).sort(((e,t)=>t.length-e.length));null==o||o.insert("getSyncPlanInplace: finish sorting"),null==o||o.insertSize("sizeof sortedKeys",g);const y=new Set;for(let s=0;s=(null!==(u=null!==(c=_.mtimeCli)&&void 0!==c?c:_.mtimeSvr)&&void 0!==u?u:0)?(v.decisionBranch=11,v.decision="conflict_created_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=12,v.decision="conflict_created_then_keep_remote",v.change=!0,y.add(Gp(a))):"keep_larger"===i?b.sizeEnc>=_.sizeEnc?(v.decisionBranch=13,v.decision="conflict_created_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=14,v.decision="conflict_created_then_keep_remote",v.change=!0,y.add(Gp(a))):"smart_conflict"===i&&(v.decisionBranch=302,v.decision="conflict_created_then_smart_conflict",v.change=!0,y.add(Gp(a)));else if("incremental_pull_only"===n||"incremental_pull_and_delete_only"===n)v.decisionBranch=22,v.decision="conflict_created_then_keep_remote",v.change=!0,y.add(Gp(a));else{if("incremental_push_only"!==n&&"incremental_push_and_delete_only"!==n)throw Error(`no idea how to deal with syncDirection=${n} while conflict created`);v.decisionBranch=23,v.decision="conflict_created_then_keep_local",v.change=!0,y.add(Gp(a))}else if("bidirectional"===n)"keep_newer"===i||"smart_conflict"===i&&a.startsWith(`${l}/`)?(null!==(h=null!==(p=b.mtimeCli)&&void 0!==p?p:b.mtimeSvr)&&void 0!==h?h:0)>=(null!==(m=null!==(f=_.mtimeCli)&&void 0!==f?f:_.mtimeSvr)&&void 0!==m?m:0)?(v.decisionBranch=16,v.decision="conflict_modified_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=17,v.decision="conflict_modified_then_keep_remote",v.change=!0,y.add(Gp(a))):"keep_larger"===i?b.sizeEnc>=_.sizeEnc?(v.decisionBranch=18,v.decision="conflict_modified_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=19,v.decision="conflict_modified_then_keep_remote",v.change=!0,y.add(Gp(a))):"smart_conflict"===i&&(v.decisionBranch=301,v.decision="conflict_modified_then_smart_conflict",v.change=!0,y.add(Gp(a)));else if("incremental_pull_only"===n||"incremental_pull_and_delete_only"===n)v.decisionBranch=24,v.decision="conflict_modified_then_keep_remote",v.change=!0,y.add(Gp(a));else{if("incremental_push_only"!==n&&"incremental_push_and_delete_only"!==n)throw Error(`no idea how to deal with syncDirection=${n} while conflict modified`);v.decisionBranch=25,v.decision="conflict_modified_then_keep_local",v.change=!0,y.add(Gp(a))}}else v.decisionBranch=2,v.decision="equal",v.change=!1,y.add(Gp(a));else if(void 0===b&&void 0!==_)if(void 0===w)t<=0||_.sizeEnc<=t?"incremental_push_only"===n||"incremental_push_and_delete_only"===n?(v.decisionBranch=28,v.decision="conflict_created_then_do_nothing",v.change=!1,y.add(Gp(a))):(v.decisionBranch=3,v.decision="remote_is_created_then_pull",v.change=!0,y.add(Gp(a))):(v.decisionBranch=36,v.decision="remote_is_created_too_large_then_do_nothing",v.change=!1,y.add(Gp(a)));else if(w.mtimeSvr!==_.mtimeCli&&w.mtimeSvr!==_.mtimeSvr||w.sizeEnc!==_.sizeEnc){if(!(t<=0||_.sizeEnc<=t))throw Error(`remote is modified (branch 5) but size larger than ${t}, don't know what to do: ${JSON.stringify(v)}`);"incremental_push_only"===n||"incremental_push_and_delete_only"===n?(v.decisionBranch=30,v.decision="conflict_created_then_do_nothing",v.change=!1,y.add(Gp(a))):(v.decisionBranch=5,v.decision="remote_is_modified_then_pull",v.change=!0,y.add(Gp(a)))}else"incremental_push_only"===n?(v.decisionBranch=29,v.decision="conflict_created_then_do_nothing",v.change=!1,y.add(Gp(a))):"incremental_push_and_delete_only"===n?(v.decisionBranch=38,v.decision="local_is_deleted_thus_also_delete_remote",v.change=!0):"incremental_pull_only"===n||"incremental_pull_and_delete_only"===n?(v.decisionBranch=35,v.decision="conflict_created_then_keep_remote",v.change=!0,y.add(Gp(a))):(v.decisionBranch=4,v.decision="local_is_deleted_thus_also_delete_remote",v.change=!0);else{if(void 0===b||void 0!==_)throw Error(`should not reach branch -1 while getting sync plan: ${JSON.stringify(v)}`);if(void 0===w)t<=0||b.sizeEnc<=t?"incremental_pull_only"===n||"incremental_pull_and_delete_only"===n?(v.decisionBranch=31,v.decision="conflict_created_then_do_nothing",v.change=!1,y.add(Gp(a))):(v.decisionBranch=6,v.decision="local_is_created_then_push",v.change=!0,y.add(Gp(a))):(v.decisionBranch=37,v.decision="local_is_created_too_large_then_do_nothing",v.change=!1,y.add(Gp(a)));else if(w.mtimeSvr!==b.mtimeCli&&w.mtimeCli!==b.mtimeCli||w.sizeEnc!==b.sizeEnc){if(!(t<=0||b.sizeEnc<=t))throw Error(`local is modified (branch 8) but size larger than ${t}, don't know what to do: ${JSON.stringify(v)}`);"incremental_pull_only"===n||"incremental_pull_and_delete_only"===n?(v.decisionBranch=34,v.decision="conflict_created_then_do_nothing",v.change=!1,y.add(Gp(a))):(v.decisionBranch=8,v.decision="local_is_modified_then_push",v.change=!0,y.add(Gp(a)))}else"incremental_push_only"===n||"incremental_push_and_delete_only"===n?(v.decisionBranch=32,v.decision="conflict_created_then_keep_local",v.change=!0):"incremental_pull_only"===n?(v.decisionBranch=33,v.decision="conflict_created_then_do_nothing",v.change=!1):"incremental_pull_and_delete_only"===n?a===`${l}/`||a===`${l}/bookmarks.json`?(v.decisionBranch=139,v.decision="conflict_created_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=39,v.decision="remote_is_deleted_thus_also_delete_local",v.change=!0):a===`${l}/`||a===`${l}/bookmarks.json`?(v.decisionBranch=140,v.decision="conflict_created_then_keep_local",v.change=!0,y.add(Gp(a))):(v.decisionBranch=7,v.decision="remote_is_deleted_thus_also_delete_local",v.change=!0)}if(void 0===v.decision)throw Error(`unexpectedly no decision of file in the end: ${JSON.stringify(v)}`)}}if(null==o||o.insert("getSyncPlanInplace: finish looping"),y.delete("/"),y.delete(""),y.size>0)throw console.error(g),console.error(e),Error(`unexpectedly keptFolder no decisions: ${[...y]}`);const v=Date.now(),b=Vp(v),w=eh(e);return e["/$@meta"]={key:"/$@meta",sideNotes:{version:"20240714 fs version",generateTime:v,generateTimeFmt:b,service:s.serviceType,concurrency:s.concurrency,hasPassword:""!==s.password,syncConfigDir:s.syncConfigDir,syncBookmarks:s.syncBookmarks,syncUnderscoreItems:s.syncUnderscoreItems,skipSizeLargerThan:s.skipSizeLargerThan,protectModifyPercentage:s.protectModifyPercentage,conflictAction:i,syncDirection:n,triggerSource:a,sizeof:w}},null==o||o.insert("getSyncPlanInplace: exit"),null==o||o.insertSize("sizeof mixedEntityMappings in the end of getSyncPlanInplace",e),null==o||o.removeIndent(),e})))(P,null!==(E=c.skipSizeLargerThan)&&void 0!==E?E:-1,null!==(T=c.conflictAction)&&void 0!==T?T:"keep_newer",null!==(B=c.syncDirection)&&void 0!==B?B:"bidirectional",n,c,s,d),console.debug("mixedEntityMappings:"),console.debug(P),null==n||n.insert("finish building full sync plan"),yield((e,t,i,n)=>r(void 0,void 0,void 0,(function*(){const r=Date.now(),o={ts:r,tsFmt:Vp(r),vaultRandomID:i,remoteType:n,syncPlan:JSON.stringify(t,null,2)};yield e.syncPlansTbl.setItem(`${i}\t${r}`,o)})))(o,P,l,c.serviceType),null==n||n.insert("finish writing sync plan"),null==n||n.insert(`finish step${M} (make plan)`),M=7,"dry"!==s?(yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F),yield sx(P,e,i,l,a,null!==(C=c.concurrency)&&void 0!==C?C:5,null!==(I=c.protectModifyPercentage)&&void 0!==I?I:50,h,o,n,null!==(A=c.conflictAction)&&void 0!==A?A:"keep_newer",s,b),null==n||n.insert(`finish step${M} (actual sync)`)):(yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F),null==n||n.insert(`finish step${M} (skip actual sync because of dry run)`))}catch(e){null==n||n.insert("start error branch"),F=!1,yield null==g?void 0:g(s,e),null==n||n.insert("finish error branch")}null==n||n.insert("finish syncRun"),yield null==n?void 0:n.save(o,l,c.serviceType),M=8,yield null==m?void 0:m(s,M),yield null==y?void 0:y(s,M),yield null==v?void 0:v(s,M,F),console.info("endding sync."),f(!1)}))}var lx=__webpack_require__(48287).Buffer;const dx=e=>{if(null==e)return console.debug("the messy config is null or undefined, skip"),e;if("readme"in e&&"d"in e){return JSON.parse(ie(Wp(e.d),{out:lx.allocUnsafe,loose:!0}).toString("utf-8"))}return e},cx=(e,t)=>{if(!t)return e;const r=JSON.parse(e),i=Object.fromEntries(Object.entries(r).filter((([e,t])=>"/$@meta"===e||(void 0===t.change||!0===t.change))));return JSON.stringify(i,null,2)},ux=(e,t,i,n,o)=>r(void 0,void 0,void 0,(function*(){console.info("exporting sync plans"),yield Np(R,t);const s=yield((e,t)=>r(void 0,void 0,void 0,(function*(){const r=[];return yield e.syncPlansTbl.iterate(((e,i,n)=>{i.startsWith(`${t}\t`)&&r.push(e)})),r.sort(((e,t)=>-(e.ts-t.ts))),void 0===r?[]:r.map((e=>e.syncPlan))})))(e,i);let a="";a=0===s.length?"No sync plans history found":n<=0?"Sync plans found:\n\n"+s.map((e=>"```json\n"+cx(e,o)+"\n```\n")).join("\n"):"Sync plans found:\n\n"+s.map((e=>"```json\n"+cx(e,o)+"\n```\n")).slice(0,n).join("\n");const l=Date.now(),d=`${R}sync_plans_hist_exported_on_${l}.md`;yield t.create(d,a,{mtime:l}),console.info("finish exporting sync plans")})),px=(e,t,i)=>r(void 0,void 0,void 0,(function*(){console.info("exporting profiler results"),yield Np(R,t);const n=yield((e,t)=>r(void 0,void 0,void 0,(function*(){const r=[];return yield e.profilerResultsTbl.iterate(((e,i,n)=>{i.startsWith(`${t}\t`)&&r.push({val:e,ts:Number.parseInt(i.split("\t")[1])})})),r.sort(((e,t)=>-(e.ts-t.ts))),void 0===r?[]:r.map((e=>e.val))})))(e,i);let o="";o=0===n.length?"No profiler results found":"Profiler results found:\n\n"+n.map((e=>"```\n"+e+"\n```\n")).join("\n");const s=Date.now(),a=`${R}profiler_results_exported_on_${s}.md`;yield t.create(a,o,{mtime:s}),console.info("finish exporting profiler results")}));var hx=__webpack_require__(34783),fx=__webpack_require__(58253),mx=__webpack_require__.n(fx);const gx={accessToken:"",clientID:T,refreshToken:"",accessTokenExpiresInSeconds:0,accessTokenExpiresAtTime:0,accountID:"",username:"",credentialsShouldBeDeletedAtTime:0},yx=(e,t)=>{let r=e;return"/"===e||""===e?r=`/${t}`:e.startsWith("/")?(console.warn(`why the path ${e} starts with '/'? but we just go on.`),r=`/${t}${e}`):r=`/${t}/${e}`,r.endsWith("/")&&(r=r.slice(0,r.length-1)),r},vx=(e,t)=>{let r=((e,t)=>{if(e!==`/${t}`&&!e.startsWith(`/${t}/`))throw Error(`"${e}" doesn't starts with "/${t}/"`);return e.slice(`/${t}/`.length)})(e.path_display,t);if("folder"!==e[".tag"]||r.endsWith("/")||(r=`${r}/`),"folder"===e[".tag"])return{key:r,keyRaw:r,size:0,sizeRaw:0};if("file"===e[".tag"]){return{key:r,keyRaw:r,mtimeCli:Date.parse(e.client_modified).valueOf(),mtimeSvr:Date.parse(e.server_modified).valueOf(),size:e.size,sizeRaw:e.size,hash:e.content_hash}}throw Error("do not support deleted tag")};function bx(e){return r(this,arguments,void 0,(function*(e,t=""){const r=[1,2,4,8];for(let i=0;ir(void 0,void 0,void 0,(function*(){try{const r=yield fetch("https://api.dropboxapi.com/oauth2/token",{method:"POST",body:new URLSearchParams({code:i,grant_type:"authorization_code",code_verifier:t,client_id:e,redirect_uri:`obsidian://${M}`})});return yield r.json()}catch(e){console.error(e),void 0!==n&&(yield n(e))}})),_x=(e,t,i)=>r(void 0,void 0,void 0,(function*(){console.info("start updating local info of Dropbox token"),e.accessToken=t.access_token,e.accessTokenExpiresInSeconds=Number.parseInt(t.expires_in),e.accessTokenExpiresAtTime=Date.now()+1e3*Number.parseInt(t.expires_in)-1e4,e.credentialsShouldBeDeletedAtTime=Date.now()+D,void 0!==t.refresh_token&&(e.refreshToken=t.refresh_token,e.accountID=t.account_id),void 0!==i&&(yield i()),console.info("finish updating local info of Dropbox token")}));class xx extends Mp{constructor(e,t,r){super(),this.kind="dropbox",this.dropboxConfig=e,this.remoteBaseDir=this.dropboxConfig.remoteBaseDir||t||"",this.saveUpdatedConfigFunc=r,this.vaultFolderExists=!1,this.foldersCreatedBefore=new Set}_init(){return r(this,void 0,void 0,(function*(){if(""===this.dropboxConfig.accessToken||""===this.dropboxConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now(),t={"Cache-Control":"no-cache"};if(this.dropboxConfig.accessTokenExpiresAtTime>e)this.dropbox=new hx.Dropbox({accessToken:this.dropboxConfig.accessToken,customHeaders:t});else{if(""===this.dropboxConfig.refreshToken)throw Error("We need to automatically refresh token but none is stored.");const e=yield(i=this.dropboxConfig.clientID,n=this.dropboxConfig.refreshToken,r(void 0,void 0,void 0,(function*(){try{console.info("start auto getting refreshed Dropbox access token.");const e=yield fetch("https://api.dropboxapi.com/oauth2/token",{method:"POST",body:new URLSearchParams({grant_type:"refresh_token",refresh_token:n,client_id:i})}),t=yield e.json();return console.info("finish auto getting refreshed Dropbox access token."),t}catch(e){throw console.error(e),e}})));_x(this.dropboxConfig,e,this.saveUpdatedConfigFunc),this.dropbox=new hx.Dropbox({accessToken:this.dropboxConfig.accessToken,customHeaders:t})}var i,n;if(this.vaultFolderExists);else{const e=yield this.dropbox.filesListFolder({path:"",recursive:!1});for(const t of e.result.entries)if(t.path_display===`/${this.remoteBaseDir}`){this.vaultFolderExists=!0;break}if(!this.vaultFolderExists){if(console.info(`remote does not have folder /${this.remoteBaseDir}`),Hp(`/${this.remoteBaseDir}`))throw new Error(`/${this.remoteBaseDir}: Error: Dropbox does not support emoji in folder names.`);yield this.dropbox.filesCreateFolderV2({path:`/${this.remoteBaseDir}`}),console.info(`remote folder /${this.remoteBaseDir} created`),this.vaultFolderExists=!0}}return this}))}walk(){return r(this,void 0,void 0,(function*(){return yield this._walk(!1)}))}walkPartial(){return r(this,void 0,void 0,(function*(){return yield this._walk(!0)}))}_walk(e){return r(this,void 0,void 0,(function*(){yield this._init();let t=yield this.dropbox.filesListFolder({path:`/${this.remoteBaseDir}`,recursive:!e,include_deleted:!1,limit:e?10:1e3});if(200!==t.status)throw Error(JSON.stringify(t));const r=t.result.entries.filter((e=>"deleted"!==e[".tag"])).filter((e=>e.path_display!==`/${this.remoteBaseDir}`)).map((e=>vx(e,this.remoteBaseDir)));if(!e)for(;t.result.has_more;){if(t=yield this.dropbox.filesListFolderContinue({cursor:t.result.cursor}),200!==t.status)throw Error(JSON.stringify(t));const e=t.result.entries.filter((e=>"deleted"!==e[".tag"])).filter((e=>e.path_display!==`/${this.remoteBaseDir}`)).map((e=>vx(e,this.remoteBaseDir)));r.push(...e)}return(e=>{for(const t of e)if(void 0===t.key)throw Error("dropbox list should all have key, but meet undefined");e.sort(((e,t)=>e.key.length-t.key.length));const t={"":""};for(const r of e){let e=Gp(r.key);"/"===e&&(e="");const i=e.toLocaleLowerCase(),n=r.key.split("/");if(r.key.endsWith("/")){if(!t.hasOwnProperty(i))throw Error(`${e} doesn't have cases record??`);{const e=`${t[i]}${n.slice(-2).join("/")}`;t[e.toLocaleLowerCase()]=e,r.key=e}}else{if(!t.hasOwnProperty(i))throw Error(`${e} doesn't have cases record??`);{const e=`${t[i]}${n.slice(-1).join("/")}`;r.key=e}}}})(r),r}))}stat(e){return r(this,void 0,void 0,(function*(){return yield this._init(),yield this._statFromRoot(yx(e,this.remoteBaseDir))}))}_statFromRoot(e){return r(this,void 0,void 0,(function*(){const t=yield bx((()=>this.dropbox.filesGetMetadata({path:e})));if(void 0===t)throw Error("dropbox.filesGetMetadata undefinded");if(200!==t.status)throw Error(JSON.stringify(t));return vx(t.result,this.remoteBaseDir)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not call mkdir on ${e}`);yield this._init();const r=yx(e,this.remoteBaseDir);return yield this._mkdirFromRoot(r,t,i)}))}_mkdirFromRoot(e,t,i){return r(this,void 0,void 0,(function*(){var t,r,i;if(Hp(e))throw new Error(`${e}: Error: Dropbox does not support emoji in file / folder names.`);if(null===(t=this.foldersCreatedBefore)||void 0===t?void 0:t.has(e));else try{yield bx((()=>this.dropbox.filesCreateFolderV2({path:e})),e),null===(r=this.foldersCreatedBefore)||void 0===r||r.add(e)}catch(t){const r=t;if(void 0===r.status)throw r;if(409!==r.status)throw r;null===(i=this.foldersCreatedBefore)||void 0===i||i.add(e)}return yield this._statFromRoot(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`you should not call writeFile on ${e}`);yield this._init();const r=yx(e,this.remoteBaseDir);return yield this._writeFileFromRoot(r,t,i,n,e)}))}_writeFileFromRoot(e,t,i,n,o){return r(this,void 0,void 0,(function*(){var r;if(Hp(o))throw new Error(`${o}: Error: Dropbox does not support emoji in file / folder names.`);const s=1e3*Math.floor(i/1e3),a=(Math.floor(n/1e3),new Date(s).toISOString().replace(/\.\d{3}Z$/,"Z"));if(yield bx((()=>this.dropbox.filesUpload({path:e,contents:t,mode:{".tag":"overwrite"},client_modified:a})),o),void 0!==this.foldersCreatedBefore){const e=zp(o).map((e=>yx(e,this.remoteBaseDir)));for(const t of e)null===(r=this.foldersCreatedBefore)||void 0===r||r.add(t)}return yield this._statFromRoot(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){if(yield this._init(),e.endsWith("/"))throw new Error(`you should not call readFile on folder ${e}`);const t=yx(e,this.remoteBaseDir);return yield this._readFileFromRoot(t)}))}_readFileFromRoot(e){return r(this,void 0,void 0,(function*(){const t=yield bx((()=>this.dropbox.filesDownload({path:e})),`downloadFromRemoteRaw=${e}`);if(void 0===t)throw Error(`unknown rsp from dropbox download: ${t}`);if(void 0!==t.result.fileBlob){const e=t.result.fileBlob;return yield e.arrayBuffer()}if(void 0!==t.result.fileBinary){const e=t.result.fileBinary;return qp(e)}throw Error(`unknown rsp from dropbox download: ${t}`)}))}rename(e,t){return r(this,void 0,void 0,(function*(){const r=yx(e,this.remoteBaseDir),i=yx(t,this.remoteBaseDir);yield this._init();try{yield bx((()=>this.dropbox.filesMoveV2({from_path:r,to_path:i})),`${e}=>${t}`)}catch(e){console.error("some error while moving"),console.error(e)}}))}rm(e){return r(this,void 0,void 0,(function*(){if("/"===e)return;const t=yx(e,this.remoteBaseDir);yield this._init();try{yield bx((()=>this.dropbox.filesDeleteV2({path:t})),e)}catch(e){console.error("some error while deleting"),console.error(e)}}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{yield this._init();if(void 0===(yield this._statFromRoot(`/${this.remoteBaseDir}`)))throw Error("cannot check root vault folder!")}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){yield this._init();return(yield this.dropbox.usersGetCurrentAccount()).result.name.display_name}))}revokeAuth(){return r(this,void 0,void 0,(function*(){try{return yield this._init(),yield this.dropbox.authTokenRevoke(),!0}catch(e){return!1}}))}allowEmptyFile(){return!0}}const Sx="KNQWY5DFMRPV",kx="U2FsdGVkX",Ex=(e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4){const i=yield window.crypto.subtle.importKey("raw",(new TextEncoder).encode(t),{name:"PBKDF2"},!1,["deriveKey","deriveBits"]);return yield window.crypto.subtle.deriveBits({name:"PBKDF2",salt:e,iterations:r,hash:"SHA-256"},i,384)})),Tx=(e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4,i=""){let n;n=""!==i?(e=>{const t=e.match(/[\da-f]{2}/gi);if(null===t)throw Error(`input ${e} is not hex, no way to transform`);return new Uint8Array(t.map((e=>Number.parseInt(e,16))))})(i):window.crypto.getRandomValues(new Uint8Array(8));const o=yield Ex(n,t,r),s=o.slice(0,32),a=o.slice(32,48),l=yield window.crypto.subtle.importKey("raw",s,{name:"AES-CBC"},!1,["encrypt","decrypt"]),d=yield window.crypto.subtle.encrypt({name:"AES-CBC",iv:a},l,e),c=(new TextEncoder).encode("Salted__"),u=new Uint8Array([...c,...n,...new Uint8Array(d)]);return qp(u)})),Bx=(e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4){e.slice(0,8);const i=e.slice(8,16),n=yield Ex(new Uint8Array(i),t,r),o=n.slice(0,32),s=n.slice(32,48),a=yield window.crypto.subtle.importKey("raw",o,{name:"AES-CBC"},!1,["encrypt","decrypt"]);return yield window.crypto.subtle.decrypt({name:"AES-CBC",iv:s},a,e.slice(16))}));var Cx=__webpack_require__(88563),Ix=__webpack_require__(55512),Ax=__webpack_require__.n(Ix);function Fx(){return Ax()('(()=>{var t={114:function(t,e,r){"use strict";var n=this&&this.__awaiter||function(t,e,r,n){return new(r||(r=Promise))((function(o,s){function i(t){try{a(n.next(t))}catch(t){s(t)}}function c(t){try{a(n.throw(t))}catch(t){s(t)}}function a(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}a((n=n.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.AESCipherBlock=e.EMECipher=void 0;const o=r(469);function s(t,e){if(16!==e.length)throw Error("len must be 16");const r=new Uint8Array(16);r[0]=2*e[0],e[15]>=128&&(r[0]=135^r[0]);for(let t=1;t<16;t++)r[t]=2*e[t],e[t-1]>=128&&(r[t]=r[t]+1);t.set(r)}function i(t,e,r){if(e.length!==r.length)throw Error(`input1.length=${e.length} is not equal to input2.length=${r.length}`);for(let n=0;n128)throw Error(`EME operates on 1 to 128 block-cipher blocks, you passed ${u}`);const h=new Uint8Array(l.length),f=yield function(t,e){return n(this,void 0,void 0,(function*(){const r=new Uint8Array(16),n=new Uint8Array(16);yield t.encrypt(n,r);const o=new Array(e);for(let t=0;t=r)break}}function v(t){return E(0,t)}function x(t){const e=Math.floor(t/b),r=t%b;let n=32+e*(g+b);return 0!==r&&(n+=g+r),n}function A(t){let r=t;if(r-=32,r<0)throw new Error(e.msgErrorEncryptedFileTooShort);const n=Math.floor(r/w);let o=r%w,s=n*b;if(0!==o&&(o-=g,o<=0))throw new Error(e.msgErrorEncryptedFileBadHeader);return s+=o,s}e.Cipher=class{constructor(t){this.dataKey=new Uint8Array(32),this.nameKey=new Uint8Array(32),this.nameTweak=new Uint8Array(16),this.dirNameEncrypt=!0,this.fileNameEnc=t}toString(){return`\\ndataKey=${this.dataKey} \\nnameKey=${this.nameKey}\\nnameTweak=${this.nameTweak}\\ndirNameEncrypt=${this.dirNameEncrypt}\\nfileNameEnc=${this.fileNameEnc}\\n`}encodeToString(t){if("base32"===this.fileNameEnc)return f.base32hex.stringify(t,{pad:!1}).toLowerCase();if("base64"===this.fileNameEnc)return f.base64url.stringify(t,{pad:!1});if("base32768"===this.fileNameEnc)return y.encode(t);throw Error(`unknown fileNameEnc=${this.fileNameEnc}`)}decodeString(t){if("base32"===this.fileNameEnc){if(t.endsWith("="))throw new Error(e.msgErrorBadBase32Encoding);return f.base32hex.parse(t.toUpperCase(),{loose:!0})}if("base64"===this.fileNameEnc)return f.base64url.parse(t,{loose:!0});if("base32768"===this.fileNameEnc)return y.decode(t);throw Error(`unknown fileNameEnc=${this.fileNameEnc}`)}key(t,e){return i(this,void 0,void 0,(function*(){const r=this.dataKey.length+this.nameKey.length+this.nameTweak.length;let n,o=m;return""!==e&&(o=(new TextEncoder).encode(e)),n=""===t?new Uint8Array(r):yield(0,c.scryptAsync)((new TextEncoder).encode(t),o,{N:16384,r:8,p:1,dkLen:r}),this.dataKey.set(n.slice(0,this.dataKey.length)),this.nameKey.set(n.slice(this.dataKey.length,this.dataKey.length+this.nameKey.length)),this.nameTweak.set(n.slice(this.dataKey.length+this.nameKey.length)),this}))}updateInternalKey(t,e,r){return this.dataKey=t,this.nameKey=e,this.nameTweak=r,this}getInternalKey(){return{dataKey:this.dataKey,nameKey:this.nameKey,nameTweak:this.nameTweak}}encryptSegment(t){return i(this,void 0,void 0,(function*(){if(""===t)return"";const e=(0,u.pad)((new TextEncoder).encode(t),16),r=new h.AESCipherBlock(this.nameKey),n=new h.EMECipher(r),o=yield n.encrypt(this.nameTweak,e);return this.encodeToString(o)}))}encryptFileName(t){return i(this,void 0,void 0,(function*(){const e=t.split("/");for(let t=0;t>=BigInt(8),n=n+BigInt(o)+BigInt(s),e[t]=Number(n),n>>=BigInt(8)}n!==BigInt(0)&&E(8,e)},e.encryptedSize=x,e.decryptedSize=A},506:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createCipher=e.rotl=e.sigma=void 0;const n=r(605),o=r(527),s=t=>Uint8Array.from(t.split("").map((t=>t.charCodeAt(0)))),i=s("expand 16-byte k"),c=s("expand 32-byte k"),a=(0,o.u32)(i),l=(0,o.u32)(c);function u(t){return t.byteOffset%4==0}e.sigma=l.slice(),e.rotl=function(t,e){return t<>>32-e};const h=2**32-1,f=new Uint32Array;e.createCipher=function(t,e){const{allowShortKeys:r,extendNonceFn:s,counterLength:i,counterRight:c,rounds:y}=(0,o.checkOpts)({allowShortKeys:!1,counterLength:8,counterRight:!1,rounds:20},e);if("function"!=typeof t)throw new Error("core must be a function");return(0,n.number)(i),(0,n.number)(y),(0,n.bool)(c),(0,n.bool)(r),(e,d,p,g,b=0)=>{(0,n.bytes)(e),(0,n.bytes)(d),(0,n.bytes)(p);const w=p.length;if(g||(g=new Uint8Array(w)),(0,n.bytes)(g),(0,n.number)(b),b<0||b>=h)throw new Error("arx: counter overflow");if(g.length=h)throw new Error("arx: counter overflow");const u=Math.min(64,l-o);if(p&&64===u){const t=o/4;if(o%4!=0)throw new Error("arx: invalid block position");for(let e,r=0;r<16;r++)e=t+r,b[e]=g[e]^d[r];o+=64}else{for(let t,e=0;e0;)m.pop().fill(0);return g}}},605:(t,e)=>{"use strict";function r(t){if(!Number.isSafeInteger(t)||t<0)throw new Error(`positive integer expected, not ${t}`)}function n(t){if("boolean"!=typeof t)throw new Error(`boolean expected, not ${t}`)}function o(t){return t instanceof Uint8Array||null!=t&&"object"==typeof t&&"Uint8Array"===t.constructor.name}function s(t,...e){if(!o(t))throw new Error("Uint8Array expected");if(e.length>0&&!e.includes(t.length))throw new Error(`Uint8Array expected of length ${e}, not of length=${t.length}`)}function i(t){if("function"!=typeof t||"function"!=typeof t.create)throw new Error("hash must be wrapped by utils.wrapConstructor");r(t.outputLen),r(t.blockLen)}function c(t,e=!0){if(t.destroyed)throw new Error("Hash instance has been destroyed");if(e&&t.finished)throw new Error("Hash#digest() has already been called")}function a(t,e){s(t);const r=e.outputLen;if(t.length{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.poly1305=e.wrapConstructorWithKey=void 0;const n=r(605),o=r(527),s=(t,e)=>255&t[e++]|(255&t[e++])<<8;class i{constructor(t){this.blockLen=16,this.outputLen=16,this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.pos=0,this.finished=!1,t=(0,o.toBytes)(t),(0,n.bytes)(t,32);const e=s(t,0),r=s(t,2),i=s(t,4),c=s(t,6),a=s(t,8),l=s(t,10),u=s(t,12),h=s(t,14);this.r[0]=8191&e,this.r[1]=8191&(e>>>13|r<<3),this.r[2]=7939&(r>>>10|i<<6),this.r[3]=8191&(i>>>7|c<<9),this.r[4]=255&(c>>>4|a<<12),this.r[5]=a>>>1&8190,this.r[6]=8191&(a>>>14|l<<2),this.r[7]=8065&(l>>>11|u<<5),this.r[8]=8191&(u>>>8|h<<8),this.r[9]=h>>>5&127;for(let e=0;e<8;e++)this.pad[e]=s(t,16+2*e)}process(t,e,r=!1){const n=r?0:2048,{h:o,r:i}=this,c=i[0],a=i[1],l=i[2],u=i[3],h=i[4],f=i[5],y=i[6],d=i[7],p=i[8],g=i[9],b=s(t,e+0),w=s(t,e+2),m=s(t,e+4),E=s(t,e+6),v=s(t,e+8),x=s(t,e+10),A=s(t,e+12),k=s(t,e+14);let U=o[0]+(8191&b),B=o[1]+(8191&(b>>>13|w<<3)),L=o[2]+(8191&(w>>>10|m<<6)),S=o[3]+(8191&(m>>>7|E<<9)),C=o[4]+(8191&(E>>>4|v<<12)),_=o[5]+(v>>>1&8191),T=o[6]+(8191&(v>>>14|x<<2)),M=o[7]+(8191&(x>>>11|A<<5)),N=o[8]+(8191&(A>>>8|k<<8)),O=o[9]+(k>>>5|n),I=0,K=I+U*c+B*(5*g)+L*(5*p)+S*(5*d)+C*(5*y);I=K>>>13,K&=8191,K+=_*(5*f)+T*(5*h)+M*(5*u)+N*(5*l)+O*(5*a),I+=K>>>13,K&=8191;let H=I+U*a+B*c+L*(5*g)+S*(5*p)+C*(5*d);I=H>>>13,H&=8191,H+=_*(5*y)+T*(5*f)+M*(5*h)+N*(5*u)+O*(5*l),I+=H>>>13,H&=8191;let j=I+U*l+B*a+L*c+S*(5*g)+C*(5*p);I=j>>>13,j&=8191,j+=_*(5*d)+T*(5*y)+M*(5*f)+N*(5*h)+O*(5*u),I+=j>>>13,j&=8191;let P=I+U*u+B*l+L*a+S*c+C*(5*g);I=P>>>13,P&=8191,P+=_*(5*p)+T*(5*d)+M*(5*y)+N*(5*f)+O*(5*h),I+=P>>>13,P&=8191;let $=I+U*h+B*u+L*l+S*a+C*c;I=$>>>13,$&=8191,$+=_*(5*g)+T*(5*p)+M*(5*d)+N*(5*y)+O*(5*f),I+=$>>>13,$&=8191;let D=I+U*f+B*h+L*u+S*l+C*a;I=D>>>13,D&=8191,D+=_*c+T*(5*g)+M*(5*p)+N*(5*d)+O*(5*y),I+=D>>>13,D&=8191;let F=I+U*y+B*f+L*h+S*u+C*l;I=F>>>13,F&=8191,F+=_*a+T*c+M*(5*g)+N*(5*p)+O*(5*d),I+=F>>>13,F&=8191;let V=I+U*d+B*y+L*f+S*h+C*u;I=V>>>13,V&=8191,V+=_*l+T*a+M*c+N*(5*g)+O*(5*p),I+=V>>>13,V&=8191;let R=I+U*p+B*d+L*y+S*f+C*h;I=R>>>13,R&=8191,R+=_*u+T*l+M*a+N*c+O*(5*g),I+=R>>>13,R&=8191;let z=I+U*g+B*p+L*d+S*y+C*f;I=z>>>13,z&=8191,z+=_*h+T*u+M*l+N*a+O*c,I+=z>>>13,z&=8191,I=(I<<2)+I|0,I=I+K|0,K=8191&I,I>>>=13,H+=I,o[0]=K,o[1]=H,o[2]=j,o[3]=P,o[4]=$,o[5]=D,o[6]=F,o[7]=V,o[8]=R,o[9]=z}finalize(){const{h:t,pad:e}=this,r=new Uint16Array(10);let n=t[1]>>>13;t[1]&=8191;for(let e=2;e<10;e++)t[e]+=n,n=t[e]>>>13,t[e]&=8191;t[0]+=5*n,n=t[0]>>>13,t[0]&=8191,t[1]+=n,n=t[1]>>>13,t[1]&=8191,t[2]+=n,r[0]=t[0]+5,n=r[0]>>>13,r[0]&=8191;for(let e=1;e<10;e++)r[e]=t[e]+n,n=r[e]>>>13,r[e]&=8191;r[9]-=8192;let o=(1^n)-1;for(let t=0;t<10;t++)r[t]&=o;o=~o;for(let e=0;e<10;e++)t[e]=t[e]&o|r[e];t[0]=65535&(t[0]|t[1]<<13),t[1]=65535&(t[1]>>>3|t[2]<<10),t[2]=65535&(t[2]>>>6|t[3]<<7),t[3]=65535&(t[3]>>>9|t[4]<<4),t[4]=65535&(t[4]>>>12|t[5]<<1|t[6]<<14),t[5]=65535&(t[6]>>>2|t[7]<<11),t[6]=65535&(t[7]>>>5|t[8]<<8),t[7]=65535&(t[8]>>>8|t[9]<<5);let s=t[0]+e[0];t[0]=65535&s;for(let r=1;r<8;r++)s=(t[r]+e[r]|0)+(s>>>16)|0,t[r]=65535&s}update(t){(0,n.exists)(this);const{buffer:e,blockLen:r}=this,s=(t=(0,o.toBytes)(t)).length;for(let n=0;n>>0,t[s++]=r[e]>>>8;return t}digest(){const{buffer:t,outputLen:e}=this;this.digestInto(t);const r=t.slice(0,e);return this.destroy(),r}}function c(t){const e=(e,r)=>t(r).update((0,o.toBytes)(e)).digest(),r=t(new Uint8Array(32));return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=e=>t(e),e}e.wrapConstructorWithKey=c,e.poly1305=c((t=>new i(t)))},22:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.polyval=e.ghash=e._toGHASHKey=void 0;const n=r(527),o=r(605),s=16,i=new Uint8Array(16),c=(0,n.u32)(i),a=t=>(t>>>0&255)<<24|(t>>>8&255)<<16|(t>>>16&255)<<8|t>>>24&255;function l(t){t.reverse();const e=1&t[15];let r=0;for(let e=0;e>>1|r,r=(1&n)<<7}return t[0]^=225&-e,t}e._toGHASHKey=l;class u{constructor(t,e){this.blockLen=s,this.outputLen=s,this.s0=0,this.s1=0,this.s2=0,this.s3=0,this.finished=!1,t=(0,n.toBytes)(t),(0,o.bytes)(t,16);const r=(0,n.createView)(t);let i=r.getUint32(0,!1),c=r.getUint32(4,!1),l=r.getUint32(8,!1),u=r.getUint32(12,!1);const h=[];for(let t=0;t<128;t++)h.push({s0:a(i),s1:a(c),s2:a(l),s3:a(u)}),({s0:i,s1:c,s2:l,s3:u}={s3:(d=l)<<31|(p=u)>>>1,s2:(y=c)<<31|d>>>1,s1:(f=i)<<31|y>>>1,s0:f>>>1^225<<24&-(1&p)});var f,y,d,p;const g=(b=e||1024)>65536?8:b>1024?4:2;var b;if(![1,2,4,8].includes(g))throw new Error(`ghash: wrong window size=${g}, should be 2, 4 or 8`);this.W=g;const w=128/g,m=this.windowSize=2**g,E=[];for(let t=0;t>>g-i-1&1))continue;const{s0:c,s1:a,s2:l,s3:u}=h[g*t+i];r^=c,n^=a,o^=l,s^=u}E.push({s0:r,s1:n,s2:o,s3:s})}this.t=E}_updateBlock(t,e,r,n){t^=this.s0,e^=this.s1,r^=this.s2,n^=this.s3;const{W:o,t:s,windowSize:i}=this;let c=0,a=0,l=0,u=0;const h=(1<>>8*t&255;for(let t=8/o-1;t>=0;t--){const r=e>>>o*t&h,{s0:n,s1:y,s2:d,s3:p}=s[f*i+r];c^=n,a^=y,l^=d,u^=p,f+=1}}this.s0=c,this.s1=a,this.s2=l,this.s3=u}update(t){t=(0,n.toBytes)(t),(0,o.exists)(this);const e=(0,n.u32)(t),r=Math.floor(t.length/s),a=t.length%s;for(let t=0;tt(r,e.length).update((0,n.toBytes)(e)).digest(),r=t(new Uint8Array(16),0);return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=(e,r)=>t(e,r),e}e.ghash=f(((t,e)=>new u(t,e))),e.polyval=f(((t,e)=>new h(t,e)))},469:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.unsafe=e.siv=e.gcm=e.cfb=e.cbc=e.ecb=e.ctr=e.expandKeyDecLE=e.expandKeyLE=void 0;const n=r(527),o=r(22),s=r(605),i=16,c=new Uint8Array(i);function a(t){return t<<1^283&-(t>>7)}function l(t,e){let r=0;for(;e>0;e>>=1)r^=t&-(1&e),t=a(t);return r}const u=(()=>{let t=new Uint8Array(256);for(let e=0,r=1;e<256;e++,r^=a(r))t[e]=r;const e=new Uint8Array(256);e[0]=99;for(let r=0;r<255;r++){let n=t[255-r];n|=n<<8,e[t[r]]=255&(n^n>>4^n>>5^n>>6^n>>7^99)}return e})(),h=u.map(((t,e)=>u.indexOf(e))),f=t=>t<<8|t>>>24;function y(t,e){if(256!==t.length)throw new Error("Wrong sbox length");const r=new Uint32Array(256).map(((r,n)=>e(t[n]))),n=r.map(f),o=n.map(f),s=o.map(f),i=new Uint32Array(65536),c=new Uint32Array(65536),a=new Uint16Array(65536);for(let e=0;e<256;e++)for(let l=0;l<256;l++){const u=256*e+l;i[u]=r[e]^n[l],c[u]=o[e]^s[l],a[u]=t[e]<<8|t[l]}return{sbox:t,sbox2:a,T0:r,T1:n,T2:o,T3:s,T01:i,T23:c}}const d=y(u,(t=>l(t,3)<<24|t<<16|t<<8|l(t,2))),p=y(h,(t=>l(t,11)<<24|l(t,13)<<16|l(t,9)<<8|l(t,14))),g=(()=>{const t=new Uint8Array(16);for(let e=0,r=1;e<16;e++,r=a(r))t[e]=r;return t})();function b(t){(0,s.bytes)(t);const e=t.length;if(![16,24,32].includes(e))throw new Error(`aes: wrong key size: should be 16, 24 or 32, got: ${e}`);const{sbox2:r}=d,o=(0,n.u32)(t),i=o.length,c=t=>E(r,t,t,t,t),a=new Uint32Array(e+28);a.set(o);for(let t=i;t>>8)^g[t/i-1]:i>6&&t%i==4&&(e=c(e)),a[t]=a[t-i]^e}var l;return a}function w(t){const e=b(t),r=e.slice(),n=e.length,{sbox2:o}=d,{T0:s,T1:i,T2:c,T3:a}=p;for(let t=0;t>>8&255]^c[n>>>16&255]^a[n>>>24]}return r}function m(t,e,r,n,o,s){return t[r<<8&65280|n>>>8&255]^e[o>>>8&65280|s>>>24&255]}function E(t,e,r,n,o){return t[255&e|65280&r]|t[n>>>16&255|o>>>16&65280]<<16}function v(t,e,r,n,o){const{sbox2:s,T01:i,T23:c}=d;let a=0;e^=t[a++],r^=t[a++],n^=t[a++],o^=t[a++];const l=t.length/4-2;for(let s=0;s=0;t--)r=r+(255&a[t])|0,a[t]=255&r,r>>>=8;({s0:u,s1:h,s2:f,s3:y}=v(t,l[0],l[1],l[2],l[3]))}const g=i*Math.floor(d.length/4);if(g>>0,u.setUint32(y,p,e),({s0:g,s1:b,s2:w,s3:m}=v(t,l[0],l[1],l[2],l[3]));const E=i*Math.floor(h.length/4);if(E16)throw new Error(`aes/pcks5: wrong padding byte: ${n}`);const o=t.subarray(0,-n);for(let e=0;er(t,e),decrypt:(t,e)=>r(t,e)}})),e.ecb=(0,n.wrapCipher)({blockSize:16},(function(t,e={}){(0,s.bytes)(t);const r=!e.disablePadding;return{encrypt:(e,n)=>{(0,s.bytes)(e);const{b:o,o:i,out:c}=L(e,r,n),a=b(t);let l=0;for(;l+4<=o.length;){const{s0:t,s1:e,s2:r,s3:n}=v(a,o[l+0],o[l+1],o[l+2],o[l+3]);i[l++]=t,i[l++]=e,i[l++]=r,i[l++]=n}if(r){const t=C(e.subarray(4*l)),{s0:r,s1:n,s2:o,s3:s}=v(a,t[0],t[1],t[2],t[3]);i[l++]=r,i[l++]=n,i[l++]=o,i[l++]=s}return a.fill(0),c},decrypt:(e,o)=>{B(e);const s=w(t),i=A(e.length,o),c=(0,n.u32)(e),a=(0,n.u32)(i);for(let t=0;t+4<=c.length;){const{s0:e,s1:r,s2:n,s3:o}=x(s,c[t+0],c[t+1],c[t+2],c[t+3]);a[t++]=e,a[t++]=r,a[t++]=n,a[t++]=o}return s.fill(0),S(i,r)}}})),e.cbc=(0,n.wrapCipher)({blockSize:16,nonceLength:16},(function(t,e,r={}){(0,s.bytes)(t),(0,s.bytes)(e,16);const o=!r.disablePadding;return{encrypt:(r,s)=>{const i=b(t),{b:c,o:a,out:l}=L(r,o,s),u=(0,n.u32)(e);let h=u[0],f=u[1],y=u[2],d=u[3],p=0;for(;p+4<=c.length;)h^=c[p+0],f^=c[p+1],y^=c[p+2],d^=c[p+3],({s0:h,s1:f,s2:y,s3:d}=v(i,h,f,y,d)),a[p++]=h,a[p++]=f,a[p++]=y,a[p++]=d;if(o){const t=C(r.subarray(4*p));h^=t[0],f^=t[1],y^=t[2],d^=t[3],({s0:h,s1:f,s2:y,s3:d}=v(i,h,f,y,d)),a[p++]=h,a[p++]=f,a[p++]=y,a[p++]=d}return i.fill(0),l},decrypt:(r,s)=>{B(r);const i=w(t),c=(0,n.u32)(e),a=A(r.length,s),l=(0,n.u32)(r),u=(0,n.u32)(a);let h=c[0],f=c[1],y=c[2],d=c[3];for(let t=0;t+4<=l.length;){const e=h,r=f,n=y,o=d;h=l[t+0],f=l[t+1],y=l[t+2],d=l[t+3];const{s0:s,s1:c,s2:a,s3:p}=x(i,h,f,y,d);u[t++]=s^e,u[t++]=c^r,u[t++]=a^n,u[t++]=p^o}return i.fill(0),S(a,o)}}})),e.cfb=(0,n.wrapCipher)({blockSize:16,nonceLength:16},(function(t,e){function r(r,o,s){const c=b(t),a=r.length;s=A(a,s);const l=(0,n.u32)(r),u=(0,n.u32)(s),h=o?u:l,f=(0,n.u32)(e);let y=f[0],d=f[1],p=f[2],g=f[3];for(let t=0;t+4<=l.length;){const{s0:e,s1:r,s2:n,s3:o}=v(c,y,d,p,g);u[t+0]=l[t+0]^e,u[t+1]=l[t+1]^r,u[t+2]=l[t+2]^n,u[t+3]=l[t+3]^o,y=h[t++],d=h[t++],p=h[t++],g=h[t++]}const w=i*Math.floor(l.length/4);if(wr(t,!0,e),decrypt:(t,e)=>r(t,!1,e)}})),e.gcm=(0,n.wrapCipher)({blockSize:16,nonceLength:12,tagLength:16},(function(t,e,r){if((0,s.bytes)(e),0===e.length)throw new Error("aes/gcm: empty nonce");const i=16;function a(t,e,n){const s=_(o.ghash,!1,t,n,r);for(let t=0;t{(0,s.bytes)(t);const{xk:e,authKey:r,counter:n,tagMask:o}=l(),c=new Uint8Array(t.length+i);U(e,!1,n,t,c);const u=a(r,o,c.subarray(0,c.length-i));return c.set(u,t.length),e.fill(0),c},decrypt:t=>{if((0,s.bytes)(t),t.lengthn=>{if(!Number.isSafeInteger(n)||e>n||n>r)throw new Error(`${t}: invalid value=${n}, must be [${e}..${r}]`)};function M(t){return null!=t&&"object"==typeof t&&(t instanceof Uint32Array||"Uint32Array"===t.constructor.name)}e.siv=(0,n.wrapCipher)({blockSize:16,nonceLength:12,tagLength:16},(function(t,e,r){const i=T("AAD",0,2**36),c=T("plaintext",0,2**36),a=T("nonce",12,12),l=T("ciphertext",16,2**36+16);function u(){const r=t.length;if(16!==r&&24!==r&&32!==r)throw new Error(`key length must be 16, 24 or 32 bytes, got: ${r} bytes`);const o=b(t),s=new Uint8Array(r),i=new Uint8Array(16),c=(0,n.u32)(e);let a=0,l=c[0],u=c[1],h=c[2],f=0;for(const t of[i,s].map(n.u32)){const e=(0,n.u32)(t);for(let t=0;t{(0,s.bytes)(t),c(t.length);const{encKey:e,authKey:r}=u(),n=h(e,r,t),o=new Uint8Array(t.length+16);return o.set(n,t.length),o.set(f(e,n,t)),e.fill(0),r.fill(0),o},decrypt:t=>{(0,s.bytes)(t),l(t.length);const e=t.subarray(-16),{encKey:r,authKey:o}=u(),i=f(r,e,t.subarray(0,-16)),c=h(r,o,i);if(r.fill(0),o.fill(0),!(0,n.equalBytes)(e,c))throw new Error("invalid polyval tag");return i}}})),e.unsafe={expandKeyLE:b,expandKeyDecLE:w,encrypt:v,decrypt:x,encryptBlock:function(t,e){if((0,s.bytes)(e,16),!M(t))throw new Error("_encryptBlock accepts result of expandKeyLE");const r=(0,n.u32)(e);let{s0:o,s1:i,s2:c,s3:a}=v(t,r[0],r[1],r[2],r[3]);return r[0]=o,r[1]=i,r[2]=c,r[3]=a,e},decryptBlock:function(t,e){if((0,s.bytes)(e,16),!M(t))throw new Error("_decryptBlock accepts result of expandKeyLE");const r=(0,n.u32)(e);let{s0:o,s1:i,s2:c,s3:a}=x(t,r[0],r[1],r[2],r[3]);return r[0]=o,r[1]=i,r[2]=c,r[3]=a,e},ctrCounter:k,ctr32:U}},297:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getWebcryptoSubtle=e.randomBytes=void 0;const r="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0;e.randomBytes=function(t=32){if(r&&"function"==typeof r.getRandomValues)return r.getRandomValues(new Uint8Array(t));throw new Error("crypto.getRandomValues must be defined")},e.getWebcryptoSubtle=function(){if(r&&"object"==typeof r.subtle&&null!=r.subtle)return r.subtle;throw new Error("crypto.subtle must be defined")}},190:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.secretbox=e.xsalsa20poly1305=e.xsalsa20=e.salsa20=e.hsalsa=void 0;const n=r(605),o=r(506),s=r(210),i=r(527);function c(t,e,r,n,s,i=20){let c=t[0],a=e[0],l=e[1],u=e[2],h=e[3],f=t[1],y=r[0],d=r[1],p=s,g=t[2],b=e[4],w=e[5],m=e[6],E=e[7],v=t[3],x=c,A=a,k=l,U=u,B=h,L=f,S=y,C=d,_=p,T=0,M=g,N=b,O=w,I=m,K=E,H=v;for(let t=0;t{const o=16;return(0,n.bytes)(t,32),(0,n.bytes)(r,24),{encrypt:(i,c)=>{(0,n.bytes)(i);const a=i.length+32;c?(0,n.bytes)(c,a):c=new Uint8Array(a),c.set(i,32),(0,e.xsalsa20)(t,r,c,c);const l=c.subarray(0,32),u=(0,s.poly1305)(c.subarray(32),l);return c.set(u,o),c.subarray(0,o).fill(0),c.subarray(o)},decrypt:c=>{(0,n.bytes)(c);const a=c.length;if(a{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.u64Lengths=e.setBigUint64=e.wrapCipher=e.Hash=e.equalBytes=e.checkOpts=e.concatBytes=e.toBytes=e.bytesToUtf8=e.utf8ToBytes=e.asyncLoop=e.nextTick=e.numberToBytesBE=e.bytesToNumberBE=e.hexToNumber=e.hexToBytes=e.bytesToHex=e.isLE=e.createView=e.u32=e.u16=e.u8=void 0;\n/*! noble-ciphers - MIT License (c) 2023 Paul Miller (paulmillr.com) */\nconst n=r(605);e.u8=t=>new Uint8Array(t.buffer,t.byteOffset,t.byteLength);e.u16=t=>new Uint16Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/2));e.u32=t=>new Uint32Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/4));if(e.createView=t=>new DataView(t.buffer,t.byteOffset,t.byteLength),e.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!e.isLE)throw new Error("Non little-endian hardware is not supported");const o=Array.from({length:256},((t,e)=>e.toString(16).padStart(2,"0")));function s(t){(0,n.bytes)(t);let e="";for(let r=0;r=i&&t<=c?t-i:t>=a&&t<=l?t-(a-10):t>=u&&t<=h?t-(u-10):void 0}function y(t){if("string"!=typeof t)throw new Error("hex string expected, got "+typeof t);const e=t.length,r=e/2;if(e%2)throw new Error("padded hex string expected, got unpadded hex of length "+e);const n=new Uint8Array(r);for(let e=0,o=0;e{},e.asyncLoop=async function(t,r,n){let o=Date.now();for(let s=0;s=0&&t>o&s),c=Number(r&s),a=n?4:0,l=n?0:4;t.setUint32(e+a,i,n),t.setUint32(e+l,c,n)}e.wrapCipher=(t,e)=>(Object.assign(e,t),e),e.setBigUint64=g,e.u64Lengths=function(t,r){const n=new Uint8Array(16),o=(0,e.createView)(n);return g(o,0,BigInt(r?r.length:0),!0),g(o,8,BigInt(t.length),!0),n}},489:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.gcm=e.ctr=e.cbc=e.utils=e.managedNonce=e.getWebcryptoSubtle=e.randomBytes=void 0;const n=r(297);Object.defineProperty(e,"randomBytes",{enumerable:!0,get:function(){return n.randomBytes}}),Object.defineProperty(e,"getWebcryptoSubtle",{enumerable:!0,get:function(){return n.getWebcryptoSubtle}});const o=r(527),s=r(605);e.managedNonce=function(t){return(0,s.number)(t.nonceLength),(e,...r)=>({encrypt:(s,...i)=>{const{nonceLength:c}=t,a=(0,n.randomBytes)(c),l=t(e,a,...r).encrypt(s,...i),u=(0,o.concatBytes)(a,l);return l.fill(0),u},decrypt:(n,...o)=>{const{nonceLength:s}=t,i=n.subarray(0,s),c=n.subarray(s);return t(e,i,...r).decrypt(c,...o)}})},e.utils={async encrypt(t,e,r,o){const s=(0,n.getWebcryptoSubtle)(),i=await s.importKey("raw",t,e,!0,["encrypt"]),c=await s.encrypt(r,i,o);return new Uint8Array(c)},async decrypt(t,e,r,o){const s=(0,n.getWebcryptoSubtle)(),i=await s.importKey("raw",t,e,!0,["decrypt"]),c=await s.decrypt(r,i,o);return new Uint8Array(c)}};const i="AES-CBC",c="AES-CTR",a="AES-GCM";function l(t){return(r,n,o)=>{(0,s.bytes)(r),(0,s.bytes)(n);const l={name:t,length:8*r.length},u=function(t,e,r){if(t===i)return{name:i,iv:e};if(t===c)return{name:c,counter:e,length:64};if(t===a)return r?{name:a,iv:e,additionalData:r}:{name:a,iv:e};throw new Error("unknown aes block mode")}(t,n,o);return{encrypt:t=>((0,s.bytes)(t),e.utils.encrypt(r,l,u,t)),decrypt:t=>((0,s.bytes)(t),e.utils.decrypt(r,l,u,t))}}}e.cbc=l(i),e.ctr=l(c),e.gcm=l(a)},557:(t,e)=>{"use strict";function r(t){if(!Number.isSafeInteger(t)||t<0)throw new Error(`positive integer expected, not ${t}`)}function n(t){if("boolean"!=typeof t)throw new Error(`boolean expected, not ${t}`)}function o(t){return t instanceof Uint8Array||null!=t&&"object"==typeof t&&"Uint8Array"===t.constructor.name}function s(t,...e){if(!o(t))throw new Error("Uint8Array expected");if(e.length>0&&!e.includes(t.length))throw new Error(`Uint8Array expected of length ${e}, not of length=${t.length}`)}function i(t){if("function"!=typeof t||"function"!=typeof t.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");r(t.outputLen),r(t.blockLen)}function c(t,e=!0){if(t.destroyed)throw new Error("Hash instance has been destroyed");if(e&&t.finished)throw new Error("Hash#digest() has already been called")}function a(t,e){s(t);const r=e.outputLen;if(t.length{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.HashMD=e.Maj=e.Chi=void 0;const n=r(557),o=r(175);e.Chi=(t,e,r)=>t&e^~t&r;e.Maj=(t,e,r)=>t&e^t&r^e&r;class s extends o.Hash{constructor(t,e,r,n){super(),this.blockLen=t,this.outputLen=e,this.padOffset=r,this.isLE=n,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(t),this.view=(0,o.createView)(this.buffer)}update(t){(0,n.exists)(this);const{view:e,buffer:r,blockLen:s}=this,i=(t=(0,o.toBytes)(t)).length;for(let n=0;ns-c&&(this.process(r,0),c=0);for(let t=c;t>o&s),c=Number(r&s),a=n?4:0,l=n?0:4;t.setUint32(e+a,i,n),t.setUint32(e+l,c,n)}(r,s-8,BigInt(8*this.length),i),this.process(r,0);const a=(0,o.createView)(t),l=this.outputLen;if(l%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const u=l/4,h=this.get();if(u>h.length)throw new Error("_sha2: outputLen bigger than state");for(let t=0;t{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.crypto=void 0,e.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0},615:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hmac=e.HMAC=void 0;const n=r(557),o=r(175);class s extends o.Hash{constructor(t,e){super(),this.finished=!1,this.destroyed=!1,(0,n.hash)(t);const r=(0,o.toBytes)(e);if(this.iHash=t.create(),"function"!=typeof this.iHash.update)throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const s=this.blockLen,i=new Uint8Array(s);i.set(r.length>s?t.create().update(r).digest():r);for(let t=0;tnew s(t,e).update(r).digest(),e.hmac.create=(t,e)=>new s(t,e)},941:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.pbkdf2=function(t,e,r,n){const{c:o,dkLen:a,DK:l,PRF:u,PRFSalt:h}=i(t,e,r,n);let f;const y=new Uint8Array(4),d=(0,s.createView)(y),p=new Uint8Array(u.outputLen);for(let t=1,e=0;e{h._cloneInto(y).update(g).digestInto(g);for(let t=0;t= 1");const h=(0,s.toBytes)(e),f=(0,s.toBytes)(r),y=new Uint8Array(l),d=o.hmac.create(t,h),p=d._cloneInto().update(f);return{c:a,dkLen:l,asyncTick:u,DK:y,PRF:d,PRFSalt:p}}function c(t,e,r,n,o){return t.destroy(),e.destroy(),n&&n.destroy(),o.fill(0),r}},663:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.scrypt=function(t,e,r){const{N:n,r:o,p:s,dkLen:c,blockSize32:h,V:f,B32:y,B:d,tmp:p,blockMixCb:g}=l(t,e,r);i.isLE||(0,i.byteSwap32)(y);for(let t=0;t{a(f,r,f,r+=h,o),g()})),a(f,(n-1)*h,y,e,o),g(),await(0,i.asyncLoop)(n,b,(()=>{const t=y[e+h-16]%n;for(let r=0;r0&&(i+=16),c(r,s,t,e+=16,r,i)}function l(t,e,r){const c=(0,i.checkOpts)({dkLen:32,asyncTick:10,maxmem:1073742848},r),{N:a,r:l,p:u,dkLen:h,asyncTick:f,maxmem:y,onProgress:d}=c;if((0,n.number)(a),(0,n.number)(l),(0,n.number)(u),(0,n.number)(h),(0,n.number)(f),(0,n.number)(y),void 0!==d&&"function"!=typeof d)throw new Error("progressCb should be function");const p=128*l,g=p/4;if(a<=1||a&a-1||a>2**32)throw new Error("Scrypt: N must be larger than 1, a power of 2, and less than 2^32");if(u<0||u>137438953440/p)throw new Error("Scrypt: p must be a positive integer less than or equal to ((2^32 - 1) * 32) / (128 * r)");if(h<0||h>137438953440)throw new Error("Scrypt: dkLen should be positive integer less than or equal to (2^32 - 1) * 32");const b=p*(a+u);if(b>y)throw new Error(`Scrypt: parameters too large, ${b} (128 * r * (N + p)) > ${y} (maxmem)`);const w=(0,s.pbkdf2)(o.sha256,t,e,{c:1,dkLen:p*u}),m=(0,i.u32)(w),E=(0,i.u32)(new Uint8Array(p*a)),v=(0,i.u32)(new Uint8Array(p));let x=()=>{};if(d){const t=2*a*u,e=Math.max(Math.floor(t/1e4),1);let r=0;x=()=>{r++,!d||r%e&&r!==t||d(r/t)}}return{N:a,r:l,p:u,dkLen:h,blockSize32:g,V:E,B32:m,B:w,tmp:v,blockMixCb:x,asyncTick:f}}function u(t,e,r,n,i){const c=(0,s.pbkdf2)(o.sha256,t,r,{c:1,dkLen:e});return r.fill(0),n.fill(0),i.fill(0),c}},623:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.sha224=e.sha256=e.SHA256=void 0;const n=r(202),o=r(175),s=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),i=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),c=new Uint32Array(64);class a extends n.HashMD{constructor(){super(64,32,8,!1),this.A=0|i[0],this.B=0|i[1],this.C=0|i[2],this.D=0|i[3],this.E=0|i[4],this.F=0|i[5],this.G=0|i[6],this.H=0|i[7]}get(){const{A:t,B:e,C:r,D:n,E:o,F:s,G:i,H:c}=this;return[t,e,r,n,o,s,i,c]}set(t,e,r,n,o,s,i,c){this.A=0|t,this.B=0|e,this.C=0|r,this.D=0|n,this.E=0|o,this.F=0|s,this.G=0|i,this.H=0|c}process(t,e){for(let r=0;r<16;r++,e+=4)c[r]=t.getUint32(e,!1);for(let t=16;t<64;t++){const e=c[t-15],r=c[t-2],n=(0,o.rotr)(e,7)^(0,o.rotr)(e,18)^e>>>3,s=(0,o.rotr)(r,17)^(0,o.rotr)(r,19)^r>>>10;c[t]=s+c[t-7]+n+c[t-16]|0}let{A:r,B:i,C:a,D:l,E:u,F:h,G:f,H:y}=this;for(let t=0;t<64;t++){const e=y+((0,o.rotr)(u,6)^(0,o.rotr)(u,11)^(0,o.rotr)(u,25))+(0,n.Chi)(u,h,f)+s[t]+c[t]|0,d=((0,o.rotr)(r,2)^(0,o.rotr)(r,13)^(0,o.rotr)(r,22))+(0,n.Maj)(r,i,a)|0;y=f,f=h,h=u,u=l+e|0,l=a,a=i,i=r,r=e+d|0}r=r+this.A|0,i=i+this.B|0,a=a+this.C|0,l=l+this.D|0,u=u+this.E|0,h=h+this.F|0,f=f+this.G|0,y=y+this.H|0,this.set(r,i,a,l,u,h,f,y)}roundClean(){c.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}e.SHA256=a;class l extends a{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}e.sha256=(0,o.wrapConstructor)((()=>new a)),e.sha224=(0,o.wrapConstructor)((()=>new l))},175:(t,e,r)=>{"use strict";\n/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */Object.defineProperty(e,"__esModule",{value:!0}),e.Hash=e.nextTick=e.byteSwapIfBE=e.byteSwap=e.isLE=e.rotl=e.rotr=e.createView=e.u32=e.u8=void 0,e.isBytes=function(t){return t instanceof Uint8Array||null!=t&&"object"==typeof t&&"Uint8Array"===t.constructor.name},e.byteSwap32=function(t){for(let r=0;r=0&&tt().update(l(e)).digest(),r=t();return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=()=>t(),e},e.wrapConstructorWithOpts=function(t){const e=(e,r)=>t(r).update(l(e)).digest(),r=t({});return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=e=>t(e),e},e.wrapXOFConstructorWithOpts=function(t){const e=(e,r)=>t(r).update(l(e)).digest(),r=t({});return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=e=>t(e),e},e.randomBytes=function(t=32){if(n.crypto&&"function"==typeof n.crypto.getRandomValues)return n.crypto.getRandomValues(new Uint8Array(t));if(n.crypto&&"function"==typeof n.crypto.randomBytes)return n.crypto.randomBytes(t);throw new Error("crypto.getRandomValues must be defined")};const n=r(145),o=r(557);e.u8=t=>new Uint8Array(t.buffer,t.byteOffset,t.byteLength);e.u32=t=>new Uint32Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/4));e.createView=t=>new DataView(t.buffer,t.byteOffset,t.byteLength);e.rotr=(t,e)=>t<<32-e|t>>>e;e.rotl=(t,e)=>t<>>32-e>>>0,e.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];e.byteSwap=t=>t<<24&4278190080|t<<8&16711680|t>>>8&65280|t>>>24&255,e.byteSwapIfBE=e.isLE?t=>t:t=>(0,e.byteSwap)(t);const s=Array.from({length:256},((t,e)=>e.toString(16).padStart(2,"0")));const i={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function c(t){return t>=i._0&&t<=i._9?t-i._0:t>=i._A&&t<=i._F?t-(i._A-10):t>=i._a&&t<=i._f?t-(i._a-10):void 0}function a(t){if("string"!=typeof t)throw new Error("utf8ToBytes expected string, got "+typeof t);return new Uint8Array((new TextEncoder).encode(t))}function l(t){return"string"==typeof t&&(t=a(t)),(0,o.bytes)(t),t}e.nextTick=async()=>{};e.Hash=class{clone(){return this._cloneInto()}};const u={}.toString},819:t=>{t.exports={pad:function(t,e){var r=t;if("number"!=typeof e)e=16;else{if(e>255)throw new RangeError("pad(): PKCS#7 padding cannot be longer than 255 bytes");if(e<0)throw new RangeError("pad(): PKCS#7 padding size must be positive")}if("string"==typeof t){var n=e-t.length%e;isNaN(n)&&(n=0);for(var o=String.fromCharCode(n),s=0;s0){var r=t.charCodeAt(t.length-1);if(r>t.length)throw new Error("unpad(): cannot remove "+r+" bytes from a "+t.length+"-byte(s) string");for(var n=t.length-2,o=t.length-r;n>=o;n--)if(t.charCodeAt(n)!==r)throw new Error("unpad(): found a padding byte of "+t.charCodeAt(n)+" instead of "+r+" at position "+n);e=t.substring(0,o)}else if(t instanceof Uint8Array||t instanceof Uint8ClampedArray){var s=t.byteLength,i=s-(r=t[s-1]);if(i<0)throw new Error("unpad(): cannot remove "+r+" bytes from a "+s+"-byte(s) string");for(n=s-2;n>=i;n--)if(t[n]!==r)throw new Error("unpad(): found a padding byte of "+t[n]+" instead of "+r+" at position "+n);e=t.slice(0,i)}return e}}},211:(t,e)=>{"use strict";function r(t,e,r){var n;if(void 0===r&&(r={}),!e.codes){e.codes={};for(var o=0;o=8&&(c-=8,i[l++]=255&a>>c)}if(c>=e.bits||255&a<<8-c)throw new SyntaxError("Unexpected end of data");return i}function n(t,e,r){void 0===r&&(r={});for(var n=r.pad,o=void 0===n||n,s=(1<e.bits;)c-=e.bits,i+=e.chars[s&a>>c];if(c&&(i+=e.chars[s&a<{"use strict";r.r(e),r.d(e,{decode:()=>i,encode:()=>s});const n={},o={};["ҠҿԀԟڀڿݠޟ߀ߟကဟႠႿᄀᅟᆀᆟᇠሿበቿዠዿጠጿᎠᏟᐠᙟᚠᛟកសᠠᡟᣀᣟᦀᦟ᧠᧿ᨠᨿᯀᯟᰀᰟᴀᴟ⇠⇿⋀⋟⍀⏟␀␟─❟➀➿⠀⥿⦠⦿⨠⩟⪀⪿⫠⭟ⰀⰟⲀⳟⴀⴟⵀⵟ⺠⻟㇀㇟㐀䶟䷀龿ꀀꑿ꒠꒿ꔀꗿꙀꙟꚠꛟ꜀ꝟꞀꞟꡀꡟ","ƀƟɀʟ"].forEach(((t,e)=>{const r=[];t.match(/../gu).forEach((t=>{const e=t.codePointAt(0),n=t.codePointAt(1);for(let t=e;t<=n;t++)r.push(String.fromCodePoint(t))}));const s=15-8*e;n[s]=r,r.forEach(((t,e)=>{o[t]=[s,e]}))}));const s=t=>{const e=t.length;let r="",o=0,s=0;for(let i=0;i=0;t--){o=(o<<1)+(e>>t&1),s++,15===s&&(r+=n[s][o],o=0,s=0)}}if(0!==s){for(;!(s in n);)o=1+(o<<1),s++;r+=n[s][o]}return r},i=t=>{const e=t.length,r=new Uint8Array(Math.floor(15*e/8));let n=0,s=0,i=0;for(let c=0;c=0;t--){s=(s<<1)+(u>>t&1),i++,8===i&&(r[n]=s,n++,s=0,i=0)}}if(s!==(1<{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},(()=>{"use strict";function t(t,e,r,n){return new(r||(r=Promise))((function(o,s){function i(t){try{a(n.next(t))}catch(t){s(t)}}function c(t){try{a(n.throw(t))}catch(t){s(t)}}function a(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(i,c)}a((n=n.apply(t,e||[])).next())}))}Object.create;Object.create;"function"==typeof SuppressedError&&SuppressedError;var e=r(563);const n=self,o=((t=21)=>{let e="",r=crypto.getRandomValues(new Uint8Array(t));for(;t--;)e+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&r[t]];return e})(),s=new e.Cipher("base64");n.addEventListener("message",(e=>t(void 0,void 0,void 0,(function*(){const r=e.ports[0],{action:n,dataKeyBuf:i,nameKeyBuf:c,nameTweakBuf:a,inputName:l,inputContent:u}=e.data;if("prepare"===n)try{if(void 0===i||void 0===c||void 0===a)throw Error(`worker [${o}]: prepare: internal keys not transferred to worker properly`);s.updateInternalKey(new Uint8Array(i),new Uint8Array(c),new Uint8Array(a)),r.postMessage({status:"ok"})}catch(t){console.error(t),r.postMessage({status:"error",error:t})}else if("encryptName"===n)try{if(void 0===l)throw Error(`worker [${o}]: encryptName: internal inputName not transferred to worker properly`);const e=yield function(e){return t(this,void 0,void 0,(function*(){return yield s.encryptFileName(e)}))}(l);r.postMessage({status:"ok",outputName:e})}catch(t){console.error(`worker [${o}]: encryptName=${l}`),console.error(t),r.postMessage({status:"error",error:t})}else if("decryptName"===n)try{if(void 0===l)throw Error(`worker [${o}]: decryptName: internal inputName not transferred to worker properly`);const e=yield function(e){return t(this,void 0,void 0,(function*(){return yield s.decryptFileName(e)}))}(l);r.postMessage({status:"ok",outputName:e})}catch(t){console.error(`worker [${o}]: decryptName=${l}`),console.error(t),r.postMessage({status:"error",error:t})}else if("encryptContent"===n)try{if(void 0===u)throw Error(`worker [${o}]: encryptContent: internal inputContent not transferred to worker properly`);const e=yield function(e){return t(this,void 0,void 0,(function*(){return(yield s.encryptData(new Uint8Array(e),void 0)).buffer}))}(u);r.postMessage({status:"ok",outputContent:e},[e])}catch(t){console.error(t),r.postMessage({status:"error",error:t})}else if("decryptContent"===n)try{if(void 0===u)throw Error(`worker [${o}]: decryptContent: internal inputContent not transferred to worker properly`);const e=yield function(e){return t(this,void 0,void 0,(function*(){return(yield s.decryptData(new Uint8Array(e))).buffer}))}(u);r.postMessage({status:"ok",outputContent:e},[e])}catch(t){console.error(t),r.postMessage({status:"error",error:t})}else r.postMessage({status:"error",error:`worker [${o}]: unknown action=${n}`})}))))})()})();',"Worker",void 0,void 0)}const Mx=Cx.encryptedSize;class Dx{constructor(e,t){this.password=e,this.init=!1,this.workerIdx=0,this.cipher=new Cx.Cipher("base64"),this.workers=[];for(let e=0;e{const i=new MessageChannel;i.port2.onmessage=t=>{const{status:i}=t.data;"ok"===i?(this.init=!0,e()):r("error after prepareByCallingWorker")},i.port2.onmessageerror=e=>{r(e)},this.workers[t].postMessage({action:"prepare",dataKeyBuf:this.cipher.dataKey.buffer,nameKeyBuf:this.cipher.nameKey.buffer,nameTweakBuf:this.cipher.nameTweak.buffer},[i.port1])})));yield Promise.all(e)}))}encryptNameByCallingWorker(e){return r(this,void 0,void 0,(function*(){yield this.prepareByCallingWorker(),++this.workerIdx;const t=this.workerIdx%this.workers.length;return yield new Promise(((r,i)=>{const n=new MessageChannel;n.port2.onmessage=e=>{const{outputName:t}=e.data;void 0===t?i("unknown outputName after encryptNameByCallingWorker"):r(t)},n.port2.onmessageerror=e=>{i(e)},this.workers[t].postMessage({action:"encryptName",inputName:e},[n.port1])}))}))}decryptNameByCallingWorker(e){return r(this,void 0,void 0,(function*(){yield this.prepareByCallingWorker(),++this.workerIdx;const t=this.workerIdx%this.workers.length;return yield new Promise(((r,i)=>{const n=new MessageChannel;n.port2.onmessage=e=>{const{outputName:t,status:n}=e.data;"error"===n?i("error"):void 0===t?i("unknown outputName after decryptNameByCallingWorker"):r(t)},n.port2.onmessageerror=e=>{i(e)},this.workers[t].postMessage({action:"decryptName",inputName:e},[n.port1])}))}))}encryptContentByCallingWorker(e){return r(this,void 0,void 0,(function*(){yield this.prepareByCallingWorker(),++this.workerIdx;const t=this.workerIdx%this.workers.length;return yield new Promise(((r,i)=>{const n=new MessageChannel;n.port2.onmessage=e=>{const{outputContent:t}=e.data;void 0===t?i("unknown outputContent after encryptContentByCallingWorker"):r(t)},n.port2.onmessageerror=e=>{i(e)},this.workers[t].postMessage({action:"encryptContent",inputContent:e},[n.port1])}))}))}decryptContentByCallingWorker(e){return r(this,void 0,void 0,(function*(){yield this.prepareByCallingWorker(),++this.workerIdx;const t=this.workerIdx%this.workers.length;return yield new Promise(((r,i)=>{const n=new MessageChannel;n.port2.onmessage=e=>{const{outputContent:t,status:n}=e.data;"error"===n?i("error"):void 0===t?i("unknown outputContent after decryptContentByCallingWorker"):r(t)},n.port2.onmessageerror=e=>{i(e)},this.workers[t].postMessage({action:"decryptContent",inputContent:e},[n.port1,e])}))}))}}function Rx(e){return!(!e.startsWith(Sx)&&!e.startsWith(kx))}function Px(e){const t=m()(e);return t.keyEnc=t.keyRaw,t.sizeEnc=t.sizeRaw,t}class Ox extends Mp{constructor(e,t,r){super(),this.innerFs=e,this.password=null!=t?t:"",this.method=r,this.cacheMapOrigToEnc={},this.hasCacheMap=!1,this.kind=`encrypt(${this.innerFs.kind},${""!==this.password?r:"no password"})`,""!==this.password&&"rclone-base64"===r&&(this.cipherRClone=new Dx(t,5))}isPasswordEmpty(){return""===this.password}isFolderAware(){if("openssl-base64"===this.method)return!1;if("rclone-base64"===this.method)return!0;throw Error(`no idea about isFolderAware for method=${this.method}`)}isPasswordOk(){return r(this,void 0,void 0,(function*(){const e=yield this.walkPartial();if(void 0===e||0===e.length)return{ok:!0,reason:"empty_remote"};const t=e[0].keyRaw;if(this.isPasswordEmpty())return function(e){return Rx(e)}(t)?{ok:!1,reason:"remote_encrypted_local_no_password"}:{ok:!0,reason:"likely_no_password_both_sides"};if("unknown"===this.method)return{ok:!1,reason:"unknown_encryption_method"};if(function(e,t){return!(!Rx(e)||"openssl-base64"===t)||!Rx(e)&&"openssl-base64"===t}(t,this.method))return{ok:!1,reason:"encryption_method_not_matched"};try{if(void 0===(yield this._decryptName(t)))throw Error("decryption failed");return{ok:!0,reason:"password_matched"}}catch(e){return{ok:!1,reason:"password_or_method_not_matched_or_remote_not_encrypted"}}}))}walk(){return r(this,void 0,void 0,(function*(){const e=yield this.innerFs.walk();return yield this._dealWithWalk(e)}))}walkPartial(){return r(this,void 0,void 0,(function*(){const e=yield this.innerFs.walkPartial();return yield this._dealWithWalk(e)}))}_dealWithWalk(e){return r(this,void 0,void 0,(function*(){const t=[];if(this.isPasswordEmpty()){for(const r of e)t.push(Px(r)),this.cacheMapOrigToEnc[r.key]=r.key;return this.hasCacheMap=!0,t}for(const r of e){if(Yp(r.keyRaw,[]))continue;const e=yield this._decryptName(r.keyRaw),i=e.endsWith("/")?0:void 0;t.push({key:e,keyRaw:r.keyRaw,keyEnc:r.key,mtimeCli:r.mtimeCli,mtimeSvr:r.mtimeSvr,size:i,sizeEnc:r.size,sizeRaw:r.sizeRaw,hash:void 0,synthesizedFolder:r.synthesizedFolder}),this.cacheMapOrigToEnc[e]=r.keyRaw}return this.hasCacheMap=!0,t}))}stat(e){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for stat");const t=this.cacheMapOrigToEnc[e];if(void 0===t)throw new Error(`no encrypted key ${e} before!`);const r=yield this.innerFs.stat(t);return this.isPasswordEmpty()?Px(r):{key:e,keyRaw:r.keyRaw,keyEnc:r.key,mtimeCli:r.mtimeCli,mtimeSvr:r.mtimeSvr,size:void 0,sizeEnc:r.size,sizeRaw:r.sizeRaw,hash:void 0,synthesizedFolder:r.synthesizedFolder}}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for mkdir");if(!e.endsWith("/"))throw new Error(`should not call mkdir on ${e}`);let r=this.cacheMapOrigToEnc[e];if(void 0===r&&(r=this.isPasswordEmpty()?e:yield this._encryptName(e),this.cacheMapOrigToEnc[e]=r),this.isPasswordEmpty()||this.isFolderAware()){return Px(yield this.innerFs.mkdir(r,t,i))}{const n=Date.now();let o=new ArrayBuffer(0);this.innerFs.allowEmptyFile()||(o=new ArrayBuffer(1));const s=yield this.innerFs.writeFile(r,o,null!=t?t:n,null!=i?i:n);return{key:e,keyRaw:s.keyRaw,keyEnc:s.key,mtimeCli:s.mtimeCli,mtimeSvr:s.mtimeSvr,size:0,sizeEnc:s.size,sizeRaw:s.sizeRaw,hash:void 0,synthesizedFolder:s.synthesizedFolder}}}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for readFile");let r=this.cacheMapOrigToEnc[e];if(void 0===r&&(r=this.isPasswordEmpty()?e:yield this._encryptName(e),this.cacheMapOrigToEnc[e]=r),this.isPasswordEmpty()){return Px(yield this.innerFs.writeFile(r,t,i,n))}{const o=yield this._encryptContent(t),s=yield this.innerFs.writeFile(r,o,i,n);return{key:e,keyRaw:s.keyRaw,keyEnc:s.key,mtimeCli:s.mtimeCli,mtimeSvr:s.mtimeSvr,size:void 0,sizeEnc:s.size,sizeRaw:s.sizeRaw,hash:void 0,synthesizedFolder:s.synthesizedFolder}}}))}readFile(e){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for readFile");const t=this.cacheMapOrigToEnc[e];if(void 0===t)throw new Error(`no encrypted key ${e} before! cannot readFile`);const r=yield this.innerFs.readFile(t);if(this.isPasswordEmpty())return r;return yield this._decryptContent(r)}))}rename(e,t){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for readFile");let r=this.cacheMapOrigToEnc[e];void 0===r&&(r=this.isPasswordEmpty()?e:yield this._encryptName(e),this.cacheMapOrigToEnc[e]=r);let i=this.cacheMapOrigToEnc[t];return void 0===i&&(i=this.isPasswordEmpty()?t:yield this._encryptName(t),this.cacheMapOrigToEnc[t]=i),yield this.innerFs.rename(r,i)}))}rm(e){return r(this,void 0,void 0,(function*(){if(!this.hasCacheMap)throw new Error("You have to build the cacheMap firstly for rm");const t=this.cacheMapOrigToEnc[e];if(void 0===t)throw new Error(`no encrypted key ${e} before! cannot rm`);return yield this.innerFs.rm(t)}))}checkConnect(e){return r(this,void 0,void 0,(function*(){return yield this.innerFs.checkConnect(e)}))}closeResources(){return r(this,void 0,void 0,(function*(){"rclone-base64"===this.method&&void 0!==this.cipherRClone&&this.cipherRClone.closeResources()}))}encryptEntity(e){return r(this,void 0,void 0,(function*(){if(void 0===e.key)throw Error(`input ${e.keyRaw} is abnormal without key`);if(this.isPasswordEmpty())return Px(e);const t=m()(e);if(void 0===t.sizeEnc&&void 0!==t.size&&(t.sizeEnc=this._getSizeFromOrigToEnc(t.size)),void 0===t.keyEnc||""===t.keyEnc){let r=this.cacheMapOrigToEnc[e.key];void 0!==r&&""!==r&&r!==t.key?t.keyEnc=r:(r=yield this._encryptName(e.key),t.keyEnc=r,this.cacheMapOrigToEnc[e.key]=r)}return t}))}_encryptContent(e){return r(this,void 0,void 0,(function*(){if(""===this.password)return e;if("openssl-base64"===this.method){const t=yield Tx(e,this.password);if(void 0===t)throw Error("cannot encrypt content");return t}if("rclone-base64"===this.method){const t=yield this.cipherRClone.encryptContentByCallingWorker(e);if(void 0===t)throw Error("cannot encrypt content");return t}throw Error(`not supported encrypt method=${this.method}`)}))}_decryptContent(e){return r(this,void 0,void 0,(function*(){if(""===this.password)return e;if("openssl-base64"===this.method){const t=yield Bx(e,this.password);if(void 0===t)throw Error("cannot decrypt content");return t}if("rclone-base64"===this.method){const t=yield this.cipherRClone.decryptContentByCallingWorker(e);if(void 0===t)throw Error("cannot decrypt content");return t}throw Error(`not supported decrypt method=${this.method}`)}))}_encryptName(e){return r(this,void 0,void 0,(function*(){if(""===this.password)return e;if("openssl-base64"===this.method){const t=yield((e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4,i=""){const n=yield Tx(qp((new TextEncoder).encode(e)),t,r,i);return ne(new Uint8Array(n),{pad:!1})})))(e,this.password);if(void 0===t)throw Error(`cannot encrypt name=${e}`);return t}if("rclone-base64"===this.method){const t=yield this.cipherRClone.encryptNameByCallingWorker(e);if(void 0===t)throw Error(`cannot encrypt name=${e}`);return t}throw Error(`not supported encrypt method=${this.method}`)}))}_decryptName(e){return r(this,void 0,void 0,(function*(){if(""===this.password)return e;if("openssl-base64"!==this.method){if("rclone-base64"===this.method){const t=yield this.cipherRClone.decryptNameByCallingWorker(e);if(void 0===t)throw Error(`cannot decrypt name=${e}`);return t}throw Error(`not supported decrypt method=${this.method}`)}if(e.startsWith(Sx))try{const t=yield((e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4){return(new TextDecoder).decode(yield Bx(qp(re(e,{loose:!0})),t,r))})))(e,this.password);if(void 0!==t&&jp(t))return t;throw Error(`cannot decrypt name=${e}`)}catch(t){throw Error(`cannot decrypt name=${e}`)}else{if(!e.startsWith(kx))throw Error(`method=${this.method} but the name=${e}, likely mismatch`);try{const t=yield((e,t,...i)=>r(void 0,[e,t,...i],void 0,(function*(e,t,r=2e4){return(new TextDecoder).decode(yield Bx(qp(ie(e,{loose:!0})),t,r))})))(e,this.password);if(void 0!==t&&jp(t))return t;throw Error(`cannot decrypt name=${e}`)}catch(t){throw Error(`cannot decrypt name=${e}`)}}}))}_getSizeFromOrigToEnc(e){if(""===this.password)return e;if("openssl-base64"===this.method)return(e=>{if(e<0||Number.isNaN(e)||!Number.isInteger(e))throw Error(`getSizeFromOrigToEnc: x=${e} is not a valid size`);return 16*(Math.floor(e/16)+1)+16})(e);if("rclone-base64"===this.method)return Mx(e);throw Error(`not supported encrypt method=${this.method}`)}getUserDisplayName(){return r(this,void 0,void 0,(function*(){return yield this.innerFs.getUserDisplayName()}))}revokeAuth(){return r(this,void 0,void 0,(function*(){return yield this.innerFs.revokeAuth()}))}allowEmptyFile(){return!0}}const zx=["User.Read","Files.ReadWrite.AppFolder","offline_access"],Nx=`obsidian://${F}`,qx={accessToken:"",clientID:B,authority:C,refreshToken:"",accessTokenExpiresInSeconds:0,accessTokenExpiresAtTime:0,deltaLink:"",username:"",credentialsShouldBeDeletedAtTime:0,emptyFile:"skip",kind:"onedrive"};const Ux=(e,t)=>{const r=`/drive/special/approot:/${t}`;let i=e;return"/"===e||""===e?r:(i.endsWith("/")&&(i=i.slice(0,i.length-1)),i.startsWith("/")?(console.warn(`why the path ${i} starts with '/'? but we just go on.`),i=`${r}${i}`):i=`${r}/${i}`,i)},Lx=e=>{var t,r;return`parentPath="${null!==(r=null===(t=e.parentReference)||void 0===t?void 0:t.path)&&void 0!==r?r:"(no parentReference or path)"}", selfName="${e.name}"`},jx=(e,t)=>{var r,i;let n="";const o="/drive/items/",s=encodeURIComponent(t);if(void 0===e.parentReference||null===e.parentReference||void 0===e.parentReference.path||null===e.parentReference.path)throw Error("x.parentReference.path is undefinded or null");const a=`${e.parentReference.path}/${e.name}`,l=a.match(/^\/drive\/root:\/[^\/]+\/remotely-save\//g),d=a.match(/^\/drive\/root:\/[^\/]+\/Graph\//g),c=a.match(/^\/drive\/root:\/[^\/]+\/Graph 1\//g),u=a.match(/^\/drive\/root:\/[^\/]+\/Graph%201\//g),p=a.match(/^\/Livefolders\/[^\/]+\/remotely-save\//g),h=a.match(/^\/drive\/root:\/[^\/]+\/app\/remotely-save\//g);if(null!==l&&a.startsWith(`${l[0]}${t}`)){const e=`${l[0]}${t}`;n=a.substring(e.length+1)}else if(null!==l&&a.startsWith(`${l[0]}${s}`)){const e=`${l[0]}${s}`;n=a.substring(e.length+1)}else if(null!==d&&a.startsWith(`${d[0]}${t}`)){const e=`${d[0]}${t}`;n=a.substring(e.length+1)}else if(null!==d&&a.startsWith(`${d[0]}${s}`)){const e=`${d[0]}${s}`;n=a.substring(e.length+1)}else if(null!==c&&a.startsWith(`${c[0]}${t}`)){const e=`${c[0]}${t}`;n=a.substring(e.length+1)}else if(null!==c&&a.startsWith(`${c[0]}${s}`)){const e=`${c[0]}${s}`;n=a.substring(e.length+1)}else if(null!==u&&a.startsWith(`${u[0]}${t}`)){const e=`${u[0]}${t}`;n=a.substring(e.length+1)}else if(null!==u&&a.startsWith(`${u[0]}${s}`)){const e=`${u[0]}${s}`;n=a.substring(e.length+1)}else if(null!==p&&a.startsWith(`${p[0]}${t}`)){const e=`${p[0]}${t}`;n=a.substring(e.length+1)}else if(null!==p&&a.startsWith(`${p[0]}${s}`)){const e=`${p[0]}${s}`;n=a.substring(e.length+1)}else if(null!==h&&a.startsWith(`${h[0]}${t}`)){const e=`${h[0]}${t}`;n=a.substring(e.length+1)}else if(null!==h&&a.startsWith(`${h[0]}${s}`)){const e=`${h[0]}${s}`;n=a.substring(e.length+1)}else{if(!e.parentReference.path.startsWith(o))throw Error(`file/folder, no idea how to deal with it without known prefix:\nfullPathOriginal=${a}\nmatchFirstPrefixRes=${l}\nmatchFifthPrefixRes=${d}\nmatchSixthPrefixRes=${c}\nmatchSixthV2PrefixRes=${u}\nmatchSecondPrefixRes=${p}\nmatchThirdPrefixRes=${h}\n${Lx(e)}`);{if(void 0===e.name||null===e.name)throw Error(`OneDrive item no name variable while matching ${o}`);const r=decodeURIComponent(e.parentReference.path);if(n=r.substring(r.indexOf(":")+1),n.startsWith(`/${t}/`))n=n.substring(`/${t}/`.length),n=`${n}/${e.name}`;else{if(n!==`/${t}`)throw Error(`file/folder with /drive/items/, no idea how to deal with it:\nfullPathOriginal=${a}\nmatchFirstPrefixRes=${l}\nmatchFifthPrefixRes=${d}\nmatchSixthPrefixRes=${c}\nmatchSixthV2PrefixRes=${u}\nmatchSecondPrefixRes=${p}\nmatchThirdPrefixRes=${h}\n${Lx(e)}`);n=e.name}}}const f="folder"in e;f&&(n=`${n}/`);const m=null===(r=null==e?void 0:e.fileSystemInfo)||void 0===r?void 0:r.lastModifiedDateTime;if(null==m)throw Error(`onedrive cannot parse mtime: ${JSON.stringify(e,null,2)}`);let g=null===(i=null==e?void 0:e.fileSystemInfo)||void 0===i?void 0:i.createdDateTime;null==g&&(g=m);return{key:n,keyRaw:n,mtimeSvr:Date.parse(m),mtimeCli:Date.parse(m),ctimeCli:Date.parse(g),size:f?0:e.size,sizeRaw:f?0:e.size,synthesizedFile:!1}};class Hx{constructor(e,t){this.onedriveConfig=e,this.saveUpdatedConfigFunc=t}getAccessToken(){return r(this,void 0,void 0,(function*(){if(""===this.onedriveConfig.accessToken||""===this.onedriveConfig.refreshToken)throw Error("The user has not manually auth yet.");const e=Date.now();if(this.onedriveConfig.accessTokenExpiresAtTime>e)return this.onedriveConfig.accessToken;{const o=yield(t=this.onedriveConfig.clientID,i=this.onedriveConfig.authority,n=this.onedriveConfig.refreshToken,r(void 0,void 0,void 0,(function*(){try{const e=yield(0,k.request)({url:`${i}/oauth2/v2.0/token`,method:"POST",contentType:"application/x-www-form-urlencoded",body:new URLSearchParams({tenant:"consumers",client_id:t,scope:zx.join(" "),refresh_token:n,grant_type:"refresh_token"}).toString()}),r=JSON.parse(e);return r.error,r}catch(e){throw console.error(e),e}})));if(void 0!==o.error){const e=o;throw Error(`Error while refreshing accessToken: ${e.error}, ${e.error_codes}: ${e.error_description}`)}const s=o;return this.onedriveConfig.accessToken=s.access_token,this.onedriveConfig.refreshToken=s.refresh_token,this.onedriveConfig.accessTokenExpiresInSeconds=s.expires_in,this.onedriveConfig.accessTokenExpiresAtTime=e+1e3*s.expires_in-12e4,yield this.saveUpdatedConfigFunc(),console.info("Onedrive accessToken updated"),this.onedriveConfig.accessToken}var t,i,n}))}}const $x=e=>{const t=m()(e);return t.accessToken="x",t.accessTokenExpiresInSeconds=1,t.accessTokenExpiresAtTime=1,t};class Gx extends Mp{constructor(e,t,r){super(),this.kind="onedrive",this.onedriveConfig=e,this.remoteBaseDir=this.onedriveConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.authGetter=new Hx(e,r),this.foldersCreatedBefore=new Set}_init(){return r(this,void 0,void 0,(function*(){if(""===this.onedriveConfig.accessToken||""===this.onedriveConfig.refreshToken)throw Error("The user has not manually auth yet.");if(this.vaultFolderExists);else{const e=yield this._getJson("/drive/special/approot/children");this.vaultFolderExists=e.value.filter((e=>e.name===this.remoteBaseDir)).length>0,this.vaultFolderExists||(console.info(`remote does not have folder /${this.remoteBaseDir}`),yield this._postJson("/drive/special/approot/children",{name:`${this.remoteBaseDir}`,folder:{},"@microsoft.graph.conflictBehavior":"replace"}),console.info(`remote folder /${this.remoteBaseDir} created`),this.vaultFolderExists=!0)}}))}_buildUrl(e){let t="";if(e.startsWith("http://")||e.startsWith("https://"))t=e;else{t=`https://graph.microsoft.com/v1.0${encodeURI(e)}`}return t=t.replace(/#/g,"%23"),t}_getJson(e){return r(this,void 0,void 0,(function*(){const t=this._buildUrl(e);return console.debug(`getJson, theUrl=${t}`),JSON.parse(yield(0,k.request)({url:t,method:"GET",contentType:"application/json",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`,"Cache-Control":"no-cache"}}))}))}_postJson(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);return console.debug(`postJson, theUrl=${r}`),JSON.parse(yield(0,k.request)({url:r,method:"POST",contentType:"application/json",body:JSON.stringify(t),headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}))}))}_patchJson(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);return console.debug(`patchJson, theUrl=${r}`),JSON.parse(yield(0,k.request)({url:r,method:"PATCH",contentType:"application/json",body:JSON.stringify(t),headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}))}))}_deleteJson(e){return r(this,void 0,void 0,(function*(){const t=this._buildUrl(e);console.debug(`deleteJson, theUrl=${t}`),t_?yield(0,k.requestUrl)({url:t,method:"DELETE",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}}):yield fetch(t,{method:"DELETE",headers:{Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}})}))}_putArrayBuffer(e,t){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);console.debug(`putArrayBuffer, theUrl=${r}`);{const e=yield fetch(r,{method:"PUT",body:t,headers:{"Content-Type":I,Authorization:`Bearer ${yield this.authGetter.getAccessToken()}`}});return yield e.json()}}))}_putUint8ArrayByRange(e,t,i,n,o){return r(this,void 0,void 0,(function*(){const r=this._buildUrl(e);console.debug(`putUint8ArrayByRange, theUrl=${r}, range=${i}-${n-1}, len=${n-i}, size=${o}`);{const e=yield fetch(r,{method:"PUT",body:t.subarray(i,n),headers:{"Content-Length":""+(n-i),"Content-Range":`bytes ${i}-${n-1}/${o}`,"Content-Type":I}});return yield e.json()}}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();const e="@odata.nextLink",t="@odata.deltaLink";let r=yield this._getJson(`/drive/special/approot:/${this.remoteBaseDir}:/delta`);const i=r.value;for(;e in r;)r=yield this._getJson(r[e]),i.push(...m()(r.value));t in r&&(this.onedriveConfig.deltaLink=r[t],yield this.saveUpdatedConfigFunc());const n=i.map((e=>jx(e,this.remoteBaseDir))).filter((e=>"/"!==e.key));return n}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();const e="@odata.deltaLink",t=yield this._getJson(`/drive/special/approot:/${this.remoteBaseDir}:/delta`),r=t.value;e in t&&(this.onedriveConfig.deltaLink=t[e],yield this.saveUpdatedConfigFunc());const i=r.map((e=>jx(e,this.remoteBaseDir))).filter((e=>"/"!==e.key));return i}))}stat(e){return r(this,void 0,void 0,(function*(){return yield this._init(),yield this._statFromRoot(Ux(e,this.remoteBaseDir))}))}_statFromRoot(e){return r(this,void 0,void 0,(function*(){const t=yield this._getJson(`${e}?$select=cTag,eTag,fileSystemInfo,folder,file,name,parentReference,size`);return jx(t,this.remoteBaseDir)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not call mkdir on ${e}`);yield this._init();const r=Ux(e,this.remoteBaseDir);return console.debug(`mkdir uploadFolder=${r}`),yield this._mkdirFromRoot(r,t,i)}))}_mkdirFromRoot(e,t,i){return r(this,void 0,void 0,(function*(){if(this.foldersCreatedBefore.has(e));else{const r={folder:{},"@microsoft.graph.conflictBehavior":"replace"},n={};if(void 0!==t&&0!==t){const e=new Date(t).toISOString();n.lastModifiedDateTime=e}if(void 0!==i&&0!==i){const e=new Date(i).toISOString();n.createdDateTime=e}Object.keys(n).length>0&&(r.fileSystemInfo=n),yield this._patchJson(e,r)}return yield this._statFromRoot(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`you should not call writeFile on ${e}`);yield this._init();const r=Ux(e,this.remoteBaseDir);return console.debug(`uploadFile=${r}`),yield this._writeFileFromRoot(r,t,i,n,e,this.onedriveConfig.emptyFile)}))}_writeFileFromRoot(e,t,i,n,o,s){return r(this,void 0,void 0,(function*(){if(0===t.byteLength){if("error"===s)throw Error(`${o}: Empty file is not allowed in OneDrive, and please write something in it.`);return{key:o,keyRaw:o,mtimeSvr:i,mtimeCli:i,ctimeCli:n,size:0,sizeRaw:0,synthesizedFile:!0}}const r=new Date(n).toISOString(),a=new Date(i).toISOString(),l=6553600;if(t.byteLength<4e6)yield this._putArrayBuffer(`${e}:/content?${new URLSearchParams({"@microsoft.graph.conflictBehavior":"replace"})}`,t),0!==i&&0!==n&&(yield this._patchJson(e,{fileSystemInfo:{lastModifiedDateTime:a,createdDateTime:r}}));else{let o={item:{"@microsoft.graph.conflictBehavior":"replace"}};0!==i&&0!==n&&(o={item:{"@microsoft.graph.conflictBehavior":"replace",fileSystemInfo:{lastModifiedDateTime:a,createdDateTime:r}}});const s=yield this._postJson(`${e}:/createUploadSession`,o),d=s.uploadUrl;console.debug("uploadSession = "),console.debug(s);const c=new Uint8Array(t);let u=0;for(;u"===(yield this.getUserDisplayName()))throw Error("unknown display name!")}catch(t){return console.debug(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){yield this._init();return(yield this._getJson("/me?$select=displayName")).displayName||""}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}getRevokeAddr(){return r(this,void 0,void 0,(function*(){return"https://account.live.com/consent/Manage"}))}allowEmptyFile(){return!1}}var Wx=__webpack_require__(48287),Kx=__webpack_require__(88310);const Vx=e=>{let t=e.httpHandler;return{setHttpHandler(e){t=e},httpHandler:()=>t,updateHttpClientConfig(e,r){t.updateHttpClientConfig(e,r)},httpHandlerConfigs:()=>t.httpHandlerConfigs()}};var Jx,Yx,Qx,Zx;!function(e){e.HEADER="header",e.QUERY="query"}(Jx||(Jx={})),function(e){e.HEADER="header",e.QUERY="query"}(Yx||(Yx={})),function(e){e.HTTP="http",e.HTTPS="https"}(Qx||(Qx={})),function(e){e.MD5="md5",e.CRC32="crc32",e.CRC32C="crc32c",e.SHA1="sha1",e.SHA256="sha256"}(Zx||(Zx={}));var Xx;!function(e){e[e.HEADER=0]="HEADER",e[e.TRAILER=1]="TRAILER"}(Xx||(Xx={}));const eS="__smithy_context";var tS,rS;!function(e){e.PROFILE="profile",e.SSO_SESSION="sso-session",e.SERVICES="services"}(tS||(tS={})),function(e){e.HTTP_0_9="http/0.9",e.HTTP_1_0="http/1.0",e.TDS_8_0="tds/8.0"}(rS||(rS={}));class iS{constructor(e){this.method=e.method||"GET",this.hostname=e.hostname||"localhost",this.port=e.port,this.query=e.query||{},this.headers=e.headers||{},this.body=e.body,this.protocol=e.protocol?":"!==e.protocol.slice(-1)?`${e.protocol}:`:e.protocol:"https:",this.path=e.path?"/"!==e.path.charAt(0)?`/${e.path}`:e.path:"/",this.username=e.username,this.password=e.password,this.fragment=e.fragment}static clone(e){const t=new iS({...e,headers:{...e.headers}});var r;return t.query&&(t.query=(r=t.query,Object.keys(r).reduce(((e,t)=>{const i=r[t];return{...e,[t]:Array.isArray(i)?[...i]:i}}),{}))),t}static isInstance(e){if(!e)return!1;const t=e;return"method"in t&&"protocol"in t&&"hostname"in t&&"path"in t&&"object"==typeof t.query&&"object"==typeof t.headers}clone(){return iS.clone(this)}}class nS{constructor(e){this.statusCode=e.statusCode,this.reason=e.reason,this.headers=e.headers||{},this.body=e.body}static isInstance(e){if(!e)return!1;const t=e;return"number"==typeof t.statusCode&&"object"==typeof t.headers}}const oS={step:"build",tags:["SET_EXPECT_HEADER","EXPECT_HEADER"],name:"addExpectContinueMiddleware",override:!0},sS=e=>({applyToStack:t=>{t.add(function(e){return t=>async r=>{const{request:i}=r;return iS.isInstance(i)&&i.body&&"node"===e.runtime&&"FetchHttpHandler"!==e.requestHandler?.constructor?.name&&(i.headers={...i.headers,Expect:"100-continue"}),t({...r,request:i})}}(e),oS)}}),aS={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},lS=aS.WHEN_SUPPORTED,dS=aS.WHEN_SUPPORTED;var cS,uS;!function(e){e.MD5="MD5",e.CRC32="CRC32",e.CRC32C="CRC32C",e.SHA1="SHA1",e.SHA256="SHA256"}(cS||(cS={})),function(e){e.HEADER="header",e.TRAILER="trailer"}(uS||(uS={}));const pS=cS.MD5,hS=cS.CRC32;var fS;!function(e){e.ENV="env",e.CONFIG="shared config entry"}(fS||(fS={}));function mS(e,t,r){e.__aws_sdk_context?e.__aws_sdk_context.features||(e.__aws_sdk_context.features={}):e.__aws_sdk_context={features:{}},e.__aws_sdk_context.features[t]=r}const gS=[cS.CRC32,cS.CRC32C,cS.SHA1,cS.SHA256],yS=[cS.SHA256,cS.SHA1,cS.CRC32,cS.CRC32C],vS=e=>e===cS.MD5?"content-md5":`x-amz-checksum-${e.toLowerCase()}`,bS=e=>"function"==typeof ArrayBuffer&&e instanceof ArrayBuffer||"[object ArrayBuffer]"===Object.prototype.toString.call(e),wS=e=>void 0!==e&&"string"!=typeof e&&!ArrayBuffer.isView(e)&&!bS(e);var _S=__webpack_require__(48287).Buffer,xS=void 0!==_S&&_S.from?function(e){return _S.from(e,"utf8")}:e=>(new TextEncoder).encode(e);function SS(e){return e instanceof Uint8Array?e:"string"==typeof e?xS(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}function kS(e){return"string"==typeof e?0===e.length:0===e.byteLength}function ES(e){return new Uint8Array([(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e])}function TS(e){if(!Uint32Array.from){for(var t=new Uint32Array(e.length),r=0;r>>8^IS[255&(this.checksum^s)]}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(4294967295^this.checksum)>>>0},e}(),IS=TS([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]),AS=function(){function e(){this.crc32c=new FS}return e.prototype.update=function(e){kS(e)||this.crc32c.update(SS(e))},e.prototype.digest=function(){return r(this,void 0,void 0,(function(){return i(this,(function(e){return[2,ES(this.crc32c.digest())]}))}))},e.prototype.reset=function(){this.crc32c=new FS},e}();var FS=function(){function e(){this.checksum=4294967295}return e.prototype.update=function(e){var t,r;try{for(var i=n(e),o=i.next();!o.done;o=i.next()){var s=o.value;this.checksum=this.checksum>>>8^MS[255&(this.checksum^s)]}}catch(e){t={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(4294967295^this.checksum)>>>0},e}(),MS=TS([0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697]);const DS=(e,t)=>({[cS.MD5]:t.md5,[cS.CRC32]:BS,[cS.CRC32C]:AS,[cS.SHA1]:t.sha1,[cS.SHA256]:t.sha256}[e]),RS=e=>(new TextEncoder).encode(e),PS=e=>"string"==typeof e?RS(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e),OS=(e,t)=>{const r=new e;return r.update(PS(t||"")),r.digest()},zS={name:"flexibleChecksumsMiddleware",step:"build",tags:["BODY_CHECKSUM"],override:!0},NS=(e,t)=>(r,i)=>async n=>{if(!iS.isInstance(n.request))return r(n);const{request:o}=n,{body:s,headers:a}=o,{base64Encoder:l,streamHasher:d}=e,{input:c,requestChecksumRequired:u,requestAlgorithmMember:p}=t,h=((e,{requestChecksumRequired:t,requestAlgorithmMember:r},i)=>{const n=i?hS:pS;if(!r||!e[r])return t?n:void 0;const o=e[r];if(!gS.includes(o))throw new Error(`The checksum algorithm "${o}" is not supported by the client. Select one of ${gS}.`);return o})(c,{requestChecksumRequired:u,requestAlgorithmMember:p},!!i.isS3ExpressBucket);let f=s,m=a;if(h){switch(h){case cS.CRC32:mS(i,"FLEXIBLE_CHECKSUMS_REQ_CRC32","U");break;case cS.CRC32C:mS(i,"FLEXIBLE_CHECKSUMS_REQ_CRC32C","V");break;case cS.SHA1:mS(i,"FLEXIBLE_CHECKSUMS_REQ_SHA1","X");break;case cS.SHA256:mS(i,"FLEXIBLE_CHECKSUMS_REQ_SHA256","Y")}const t=vS(h),r=DS(h,e);if(wS(s)){const{getAwsChunkedEncodingStream:i,bodyLengthChecker:n}=e;f=i(s,{base64Encoder:l,bodyLengthChecker:n,checksumLocationName:t,checksumAlgorithmFn:r,streamHasher:d}),m={...a,"content-encoding":a["content-encoding"]?`${a["content-encoding"]},aws-chunked`:"aws-chunked","transfer-encoding":"chunked","x-amz-decoded-content-length":a["content-length"],"x-amz-content-sha256":"STREAMING-UNSIGNED-PAYLOAD-TRAILER","x-amz-trailer":t},delete m["content-length"]}else if(!((e,t)=>{const r=e.toLowerCase();for(const e of Object.keys(t))if(r===e.toLowerCase())return!0;return!1})(t,a)){const e=await OS(r,s);m={...a,[t]:l(e)}}}return await r({...n,request:{...o,headers:m,body:f}})},qS=(e=[])=>{const t=[];for(const r of yS)e.includes(r)&&gS.includes(r)&&t.push(r);return t};function US(e){return new Blob([e]).stream()}const LS=async(e,{streamHasher:t,checksumAlgorithmFn:r,base64Encoder:i})=>{const n=wS(e)?t(r,e):OS(r,e);return i(await n)},jS={name:"flexibleChecksumsResponseMiddleware",toMiddleware:"deserializerMiddleware",relation:"after",tags:["BODY_CHECKSUM"],override:!0},HS=(e,t)=>(r,i)=>async n=>{if(!iS.isInstance(n.request))return r(n);const o=n.input,s=await r(n),a=s.response;let l;const{requestValidationModeMember:d,responseAlgorithms:c}=t;if(d&&"ENABLED"===o[d]){const{clientName:t,commandName:r}=i;if("S3Client"===t&&"GetObjectCommand"===r&&qS(c).every((e=>{const t=vS(e),r=a.headers[t];return!r||(e=>{const t=e.lastIndexOf("-");if(-1!==t){const r=e.slice(t+1);if(!r.startsWith("0")){const e=parseInt(r,10);if(!isNaN(e)&&e>=1&&e<=1e4)return!0}}return!1})(r)})))return s;const n=wS(a.body);n&&(l=await e.streamCollector(a.body),a.body=US(l)),await(async(e,{config:t,responseAlgorithms:r})=>{const i=qS(r),{body:n,headers:o}=e;for(const e of i){const r=vS(e),i=o[r];if(i){const o=DS(e,t),{streamHasher:s,base64Encoder:a}=t,l=await LS(n,{streamHasher:s,checksumAlgorithmFn:o,base64Encoder:a});if(l===i)break;throw new Error(`Checksum mismatch: expected "${l}" but received "${i}" in response header "${r}".`)}}})(s.response,{config:e,responseAlgorithms:c}),n&&l&&(a.body=US(l))}return s},$S=(e,t)=>({applyToStack:r=>{r.add(NS(e,t),zS),r.addRelativeTo(HS(e,t),jS)}}),GS=e=>e[eS]||(e[eS]={}),WS=e=>{if("function"==typeof e)return e;const t=Promise.resolve(e);return()=>t};const KS={name:"hostHeaderMiddleware",step:"build",priority:"low",tags:["HOST"],override:!0},VS=e=>({applyToStack:t=>{t.add((e=>t=>async r=>{if(!iS.isInstance(r.request))return t(r);const{request:i}=r,{handlerProtocol:n=""}=e.requestHandler.metadata||{};if(n.indexOf("h2")>=0&&!i.headers[":authority"])delete i.headers.host,i.headers[":authority"]=i.hostname+(i.port?":"+i.port:"");else if(!i.headers.host){let e=i.hostname;null!=i.port&&(e+=`:${i.port}`),i.headers.host=e}return t(r)})(e),KS)}}),JS={name:"loggerMiddleware",tags:["LOGGER"],step:"initialize",override:!0};var YS=__webpack_require__(65606);const QS="X-Amzn-Trace-Id",ZS={step:"build",tags:["RECURSION_DETECTION"],name:"recursionDetectionMiddleware",override:!0,priority:"low"},XS=e=>({applyToStack:t=>{t.add((e=>t=>async r=>{const{request:i}=r;if(!iS.isInstance(i)||"node"!==e.runtime||i.headers.hasOwnProperty(QS))return t(r);const n=YS.env.AWS_LAMBDA_FUNCTION_NAME,o=YS.env._X_AMZN_TRACE_ID,s=e=>"string"==typeof e&&e.length>0;return s(n)&&s(o)&&(i.headers[QS]=o),t({...r,request:i})})(e),ZS)}}),ek=(e,t)=>{const r=[];if(e&&r.push(e),t)for(const e of t)r.push(e);return r},tk=(e,t)=>`${e||"anonymous"}${t&&t.length>0?` (a.k.a. ${t.join(",")})`:""}`,rk=()=>{let e=[],t=[],r=!1;const i=new Set,n=r=>(e.forEach((e=>{r.add(e.middleware,{...e})})),t.forEach((e=>{r.addRelativeTo(e.middleware,{...e})})),r.identifyOnResolve?.(a.identifyOnResolve()),r),o=e=>{const t=[];return e.before.forEach((e=>{0===e.before.length&&0===e.after.length?t.push(e):t.push(...o(e))})),t.push(e),e.after.reverse().forEach((e=>{0===e.before.length&&0===e.after.length?t.push(e):t.push(...o(e))})),t},s=(r=!1)=>{const i=[],n=[],s={};e.forEach((e=>{const t={...e,before:[],after:[]};for(const e of ek(t.name,t.aliases))s[e]=t;i.push(t)})),t.forEach((e=>{const t={...e,before:[],after:[]};for(const e of ek(t.name,t.aliases))s[e]=t;n.push(t)})),n.forEach((e=>{if(e.toMiddleware){const t=s[e.toMiddleware];if(void 0===t){if(r)return;throw new Error(`${e.toMiddleware} is not found when adding ${tk(e.name,e.aliases)} middleware ${e.relation} ${e.toMiddleware}`)}"after"===e.relation&&t.after.push(e),"before"===e.relation&&t.before.push(e)}}));const a=(l=i,l.sort(((e,t)=>ik[t.step]-ik[e.step]||nk[t.priority||"normal"]-nk[e.priority||"normal"]))).map(o).reduce(((e,t)=>(e.push(...t),e)),[]);var l;return a},a={add:(t,r={})=>{const{name:n,override:o,aliases:s}=r,a={step:"initialize",priority:"normal",middleware:t,...r},l=ek(n,s);if(l.length>0){if(l.some((e=>i.has(e)))){if(!o)throw new Error(`Duplicate middleware name '${tk(n,s)}'`);for(const t of l){const r=e.findIndex((e=>e.name===t||e.aliases?.some((e=>e===t))));if(-1===r)continue;const i=e[r];if(i.step!==a.step||a.priority!==i.priority)throw new Error(`"${tk(i.name,i.aliases)}" middleware with ${i.priority} priority in ${i.step} step cannot be overridden by "${tk(n,s)}" middleware with ${a.priority} priority in ${a.step} step.`);e.splice(r,1)}}for(const e of l)i.add(e)}e.push(a)},addRelativeTo:(e,r)=>{const{name:n,override:o,aliases:s}=r,a={middleware:e,...r},l=ek(n,s);if(l.length>0){if(l.some((e=>i.has(e)))){if(!o)throw new Error(`Duplicate middleware name '${tk(n,s)}'`);for(const e of l){const r=t.findIndex((t=>t.name===e||t.aliases?.some((t=>t===e))));if(-1===r)continue;const i=t[r];if(i.toMiddleware!==a.toMiddleware||i.relation!==a.relation)throw new Error(`"${tk(i.name,i.aliases)}" middleware ${i.relation} "${i.toMiddleware}" middleware cannot be overridden by "${tk(n,s)}" middleware ${a.relation} "${a.toMiddleware}" middleware.`);t.splice(r,1)}}for(const e of l)i.add(e)}t.push(a)},clone:()=>n(rk()),use:e=>{e.applyToStack(a)},remove:r=>"string"==typeof r?(r=>{let n=!1;const o=e=>{const t=ek(e.name,e.aliases);if(t.includes(r)){n=!0;for(const e of t)i.delete(e);return!1}return!0};return e=e.filter(o),t=t.filter(o),n})(r):(r=>{let n=!1;const o=e=>{if(e.middleware===r){n=!0;for(const t of ek(e.name,e.aliases))i.delete(t);return!1}return!0};return e=e.filter(o),t=t.filter(o),n})(r),removeByTag:r=>{let n=!1;const o=e=>{const{tags:t,name:o,aliases:s}=e;if(t&&t.includes(r)){const e=ek(o,s);for(const t of e)i.delete(t);return n=!0,!1}return!0};return e=e.filter(o),t=t.filter(o),n},concat:e=>{const t=n(rk());return t.use(e),t.identifyOnResolve(r||t.identifyOnResolve()||(e.identifyOnResolve?.()??!1)),t},applyToStack:n,identify:()=>s(!0).map((e=>{const t=e.step??e.relation+" "+e.toMiddleware;return tk(e.name,e.aliases)+" - "+t})),identifyOnResolve:e=>("boolean"==typeof e&&(r=e),r),resolve:(e,t)=>{for(const r of s().map((e=>e.middleware)).reverse())e=r(e,t);return r&&console.log(a.identify()),e}};return a},ik={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},nk={high:3,normal:2,low:1};class ok{constructor(e){this.config=e,this.middlewareStack=rk()}send(e,t,r){const i="function"!=typeof t?t:void 0,n="function"==typeof t?t:r;let o;if(void 0===i&&!0===this.config.cacheMiddleware){this.handlers||(this.handlers=new WeakMap);const t=this.handlers;t.has(e.constructor)?o=t.get(e.constructor):(o=e.resolveMiddleware(this.middlewareStack,this.config,i),t.set(e.constructor,o))}else delete this.handlers,o=e.resolveMiddleware(this.middlewareStack,this.config,i);if(!n)return o(e).then((e=>e.output));o(e).then((e=>n(null,e.output)),(e=>n(e))).catch((()=>{}))}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}}const sk={},ak=new Array(64);for(let e=0,t="A".charCodeAt(0),r="Z".charCodeAt(0);e+t<=r;e++){const r=String.fromCharCode(e+t);sk[r]=e,ak[e]=r}for(let e=0,t="a".charCodeAt(0),r="z".charCodeAt(0);e+t<=r;e++){const r=String.fromCharCode(e+t),i=e+26;sk[r]=i,ak[i]=r}for(let e=0;e<10;e++){sk[e.toString(10)]=e+52;const t=e.toString(10),r=e+52;sk[t]=r,ak[r]=t}sk["+"]=62,ak[62]="+",sk["/"]=63,ak[63]="/";const lk=e=>{let t=e.length/4*3;"=="===e.slice(-2)?t-=2:"="===e.slice(-1)&&t--;const r=new ArrayBuffer(t),i=new DataView(r);for(let t=0;t>=6;const o=t/4*3;r>>=n%8;const s=Math.floor(n/8);for(let e=0;e>t)}}return new Uint8Array(r)};function dk(e){let t;t="string"==typeof e?RS(e):e;const r="object"==typeof t&&"number"==typeof t.length,i="object"==typeof t&&"number"==typeof t.byteOffset&&"number"==typeof t.byteLength;if(!r&&!i)throw new Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");let n="";for(let e=0;e>t]}n+="==".slice(0,4-o)}return n}const ck=e=>{if("string"==typeof e)return e;if("object"!=typeof e||"number"!=typeof e.byteOffset||"number"!=typeof e.byteLength)throw new Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return new TextDecoder("utf-8").decode(e)};class uk extends Uint8Array{static fromString(e,t="utf-8"){if("string"==typeof e)return function(e,t){return"base64"===t?uk.mutate(lk(e)):uk.mutate(RS(e))}(e,t);throw new Error(`Unsupported conversion from ${typeof e} to Uint8ArrayBlobAdapter.`)}static mutate(e){return Object.setPrototypeOf(e,uk.prototype),e}transformToString(e="utf-8"){return function(e,t="utf-8"){return"base64"===t?dk(e):ck(e)}(this,e)}}const pk=(e,t)=>{const{base64Encoder:r,bodyLengthChecker:i,checksumAlgorithmFn:n,checksumLocationName:o,streamHasher:s}=t,a=void 0!==r&&void 0!==i&&void 0!==n&&void 0!==o&&void 0!==s,l=a?s(n,e):void 0,d=e.getReader();return new ReadableStream({async pull(e){const{value:t,done:n}=await d.read();if(n){if(e.enqueue("0\r\n"),a){const t=r(await l);e.enqueue(`${o}:${t}\r\n`),e.enqueue("\r\n")}e.close()}else e.enqueue(`${(i(t)||0).toString(16)}\r\n${t}\r\n`)}})},hk=e=>encodeURIComponent(e).replace(/[!'()*]/g,fk),fk=e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`;function mk(e){const t=[];for(let r of Object.keys(e).sort()){const i=e[r];if(r=hk(r),Array.isArray(i))for(let e=0,n=i.length;e{e&&setTimeout((()=>{const t=new Error(`Request did not complete within ${e} ms`);t.name="TimeoutError",r(t)}),e)}))}const yk={supported:void 0};class vk{static create(e){return"function"==typeof e?.handle?e:new vk(e)}constructor(e){"function"==typeof e?this.configProvider=e().then((e=>e||{})):(this.config=e??{},this.configProvider=Promise.resolve(this.config)),void 0===yk.supported&&(yk.supported=Boolean("undefined"!=typeof Request&&"keepalive"in new Request("https://[::1]")))}destroy(){}async handle(e,{abortSignal:t}={}){this.config||(this.config=await this.configProvider);const r=this.config.requestTimeout,i=!0===this.config.keepAlive,n=this.config.credentials;if(t?.aborted){const e=new Error("Request aborted");return e.name="AbortError",Promise.reject(e)}let o=e.path;const s=mk(e.query||{});s&&(o+=`?${s}`),e.fragment&&(o+=`#${e.fragment}`);let a="";if(null!=e.username||null!=e.password){a=`${e.username??""}:${e.password??""}@`}const{port:l,method:d}=e,c=`${e.protocol}//${a}${e.hostname}${l?`:${l}`:""}${o}`,u="GET"===d||"HEAD"===d?void 0:e.body,p={body:u,headers:new Headers(e.headers),method:d,credentials:n};this.config?.cache&&(p.cache=this.config.cache),u&&(p.duplex="half"),"undefined"!=typeof AbortController&&(p.signal=t),yk.supported&&(p.keepalive=i),"function"==typeof this.config.requestInit&&Object.assign(p,this.config.requestInit(e));let h=()=>{};const f=new Request(c,p),m=[fetch(f).then((e=>{const t=e.headers,r={};for(const e of t.entries())r[e[0]]=e[1];return null!=e.body?{response:new nS({headers:r,reason:e.statusText,statusCode:e.status,body:e.body})}:e.blob().then((t=>({response:new nS({headers:r,reason:e.statusText,statusCode:e.status,body:t})})))})),gk(r)];return t&&m.push(new Promise(((e,r)=>{const i=()=>{const e=new Error("Request aborted");e.name="AbortError",r(e)};if("function"==typeof t.addEventListener){const e=t;e.addEventListener("abort",i,{once:!0}),h=()=>e.removeEventListener("abort",i)}else t.onabort=i}))),Promise.race(m).finally(h)}updateHttpClientConfig(e,t){this.config=void 0,this.configProvider=this.configProvider.then((r=>(r[e]=t,r)))}httpHandlerConfigs(){return this.config??{}}}const bk=e=>"function"==typeof Blob&&e instanceof Blob?async function(e){const t=await function(e){return new Promise(((t,r)=>{const i=new FileReader;i.onloadend=()=>{if(2!==i.readyState)return r(new Error("Reader aborted too early"));const e=i.result??"",n=e.indexOf(","),o=n>-1?n+1:e.length;t(e.substring(o))},i.onabort=()=>r(new Error("Read aborted")),i.onerror=()=>r(i.error),i.readAsDataURL(e)}))}(e),r=lk(t);return new Uint8Array(r)}(e):async function(e){const t=[],r=e.getReader();let i=!1,n=0;for(;!i;){const{done:e,value:o}=await r.read();o&&(t.push(o),n+=o.length),i=e}const o=new Uint8Array(n);let s=0;for(const e of t)o.set(e,s),s+=e.length;return o}(e);const wk={},_k={};for(let e=0;e<256;e++){let t=e.toString(16).toLowerCase();1===t.length&&(t=`0${t}`),wk[e]=t,_k[t]=e}function xk(e){if(e.length%2!=0)throw new Error("Hex encoded strings must have an even number length");const t=new Uint8Array(e.length/2);for(let r=0;r"function"==typeof ReadableStream&&(e?.constructor?.name===ReadableStream.name||e instanceof ReadableStream),Ek="The stream has already been transformed.",Tk=e=>{if(!Bk(e)&&!kk(e)){throw new Error(`Unexpected stream implementation, expect Blob or ReadableStream, got ${e?.__proto__?.constructor?.name||e}`)}let t=!1;const r=async()=>{if(t)throw new Error(Ek);return t=!0,await bk(e)};return Object.assign(e,{transformToByteArray:r,transformToString:async e=>{const t=await r();if("base64"===e)return dk(t);if("hex"===e)return Sk(t);if(void 0===e||"utf8"===e||"utf-8"===e)return ck(t);if("function"==typeof TextDecoder)return new TextDecoder(e).decode(t);throw new Error("TextDecoder is not available, please make sure polyfill is provided.")},transformToWebStream:()=>{if(t)throw new Error(Ek);if(t=!0,Bk(e))return(e=>{if("function"!=typeof e.stream)throw new Error("Cannot transform payload Blob to web stream. Please make sure the Blob.stream() is polyfilled.\nIf you are using React Native, this API is not yet supported, see: https://react-native.canny.io/feature-requests/p/fetch-streaming-body");return e.stream()})(e);if(kk(e))return e;throw new Error(`Cannot transform payload to web stream, got ${e}`)}})},Bk=e=>"function"==typeof Blob&&e instanceof Blob;const Ck=async(e=new Uint8Array,t)=>{if(e instanceof Uint8Array)return uk.mutate(e);if(!e)return uk.mutate(new Uint8Array);const r=t.streamCollector(e);return uk.mutate(await r)};class Ik{constructor(){this.middlewareStack=rk()}static classBuilder(){return new Ak}resolveMiddlewareWithContext(e,t,r,{middlewareFn:i,clientName:n,commandName:o,inputFilterSensitiveLog:s,outputFilterSensitiveLog:a,smithyContext:l,additionalContext:d,CommandCtor:c}){for(const n of i.bind(this)(c,e,t,r))this.middlewareStack.use(n);const u=e.concat(this.middlewareStack),{logger:p}=t,h={logger:p,clientName:n,commandName:o,inputFilterSensitiveLog:s,outputFilterSensitiveLog:a,[eS]:{commandInstance:this,...l},...d},{requestHandler:f}=t;return u.resolve((e=>f.handle(e.request,r||{})),h)}}class Ak{constructor(){this._init=()=>{},this._ep={},this._middlewareFn=()=>[],this._commandName="",this._clientName="",this._additionalContext={},this._smithyContext={},this._inputFilterSensitiveLog=e=>e,this._outputFilterSensitiveLog=e=>e,this._serializer=null,this._deserializer=null}init(e){this._init=e}ep(e){return this._ep=e,this}m(e){return this._middlewareFn=e,this}s(e,t,r={}){return this._smithyContext={service:e,operation:t,...r},this}c(e={}){return this._additionalContext=e,this}n(e,t){return this._clientName=e,this._commandName=t,this}f(e=e=>e,t=e=>e){return this._inputFilterSensitiveLog=e,this._outputFilterSensitiveLog=t,this}ser(e){return this._serializer=e,this}de(e){return this._deserializer=e,this}build(){const e=this;let t;return t=class extends Ik{static getEndpointParameterInstructions(){return e._ep}constructor(...[t]){super(),this.serialize=e._serializer,this.deserialize=e._deserializer,this.input=t??{},e._init(this)}resolveMiddleware(r,i,n){return this.resolveMiddlewareWithContext(r,i,n,{CommandCtor:t,middlewareFn:e._middlewareFn,clientName:e._clientName,commandName:e._commandName,inputFilterSensitiveLog:e._inputFilterSensitiveLog,outputFilterSensitiveLog:e._outputFilterSensitiveLog,smithyContext:e._smithyContext,additionalContext:e._additionalContext})}}}}const Fk="***SensitiveInformation***",Mk=e=>{switch(e){case"true":return!0;case"false":return!1;default:throw new Error(`Unable to parse boolean value "${e}"`)}},Dk=e=>{if(null!=e){if("string"==typeof e){const t=parseFloat(e);if(!Number.isNaN(t))return String(t)!==String(e)&&Qk.warn(Yk(`Expected number but observed string: ${e}`)),t}if("number"==typeof e)return e;throw new TypeError(`Expected number, got ${typeof e}: ${e}`)}},Rk=Math.ceil(2**127*(2-2**-23)),Pk=e=>{const t=Dk(e);if(void 0!==t&&!Number.isNaN(t)&&t!==1/0&&t!==-1/0&&Math.abs(t)>Rk)throw new TypeError(`Expected 32-bit float, got ${e}`);return t},Ok=e=>{if(null!=e){if(Number.isInteger(e)&&!Number.isNaN(e))return e;throw new TypeError(`Expected integer, got ${typeof e}: ${e}`)}},zk=e=>Uk(e,32),Nk=e=>Uk(e,16),qk=e=>Uk(e,8),Uk=(e,t)=>{const r=Ok(e);if(void 0!==r&&Lk(r,t)!==r)throw new TypeError(`Expected ${t}-bit integer, got ${e}`);return r},Lk=(e,t)=>{switch(t){case 32:return Int32Array.of(e)[0];case 16:return Int16Array.of(e)[0];case 8:return Int8Array.of(e)[0]}},jk=(e,t)=>{if(null==e){if(t)throw new TypeError(`Expected a non-null value for ${t}`);throw new TypeError("Expected a non-null value")}return e},Hk=e=>{if(null==e)return;if("object"==typeof e&&!Array.isArray(e))return e;const t=Array.isArray(e)?"array":typeof e;throw new TypeError(`Expected object, got ${t}: ${e}`)},$k=e=>{if(null!=e){if("string"==typeof e)return e;if(["boolean","number","bigint"].includes(typeof e))return Qk.warn(Yk(`Expected string, got ${typeof e}: ${e}`)),String(e);throw new TypeError(`Expected string, got ${typeof e}: ${e}`)}},Gk=/(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g,Wk=e=>{const t=e.match(Gk);if(null===t||t[0].length!==e.length)throw new TypeError("Expected real number, got implicit NaN");return parseFloat(e)},Kk=e=>Ok("string"==typeof e?Wk(e):e),Vk=e=>zk("string"==typeof e?Wk(e):e),Jk=e=>Nk("string"==typeof e?Wk(e):e),Yk=e=>String(new TypeError(e).stack||e).split("\n").slice(0,5).filter((e=>!e.includes("stackTraceWarning"))).join("\n"),Qk={warn:console.warn},Zk=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],Xk=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function eE(e){const t=e.getUTCFullYear(),r=e.getUTCMonth(),i=e.getUTCDay(),n=e.getUTCDate(),o=e.getUTCHours(),s=e.getUTCMinutes(),a=e.getUTCSeconds(),l=o<10?`0${o}`:`${o}`,d=s<10?`0${s}`:`${s}`,c=a<10?`0${a}`:`${a}`;return`${Zk[i]}, ${n<10?`0${n}`:`${n}`} ${Xk[r]} ${t} ${l}:${d}:${c} GMT`}const tE=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/),rE=e=>{if(null==e)return;if("string"!=typeof e)throw new TypeError("RFC-3339 date-times must be expressed as strings");const t=tE.exec(e);if(!t)throw new TypeError("Invalid RFC-3339 date-time value");const[r,i,n,o,s,a,l,d,c]=t,u=Jk(yE(i)),p=fE(n,"month",1,12),h=fE(o,"day",1,31),f=aE(u,p,h,{hours:s,minutes:a,seconds:l,fractionalMilliseconds:d});return"Z"!=c.toUpperCase()&&f.setTime(f.getTime()-gE(c)),f},iE=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),nE=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),oE=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),sE=e=>{if(null==e)return;if("string"!=typeof e)throw new TypeError("RFC-7231 date-times must be expressed as strings");let t=iE.exec(e);if(t){const[e,r,i,n,o,s,a,l]=t;return aE(Jk(yE(n)),cE(i),fE(r,"day",1,31),{hours:o,minutes:s,seconds:a,fractionalMilliseconds:l})}if(t=nE.exec(e),t){const[e,r,i,n,o,s,a,l]=t;return dE(aE(lE(n),cE(i),fE(r,"day",1,31),{hours:o,minutes:s,seconds:a,fractionalMilliseconds:l}))}if(t=oE.exec(e),t){const[e,r,i,n,o,s,a,l]=t;return aE(Jk(yE(l)),cE(r),fE(i.trimLeft(),"day",1,31),{hours:n,minutes:o,seconds:s,fractionalMilliseconds:a})}throw new TypeError("Invalid RFC-7231 date-time value")},aE=(e,t,r,i)=>{const n=t-1;return pE(e,n,r),new Date(Date.UTC(e,n,r,fE(i.hours,"hour",0,23),fE(i.minutes,"minute",0,59),fE(i.seconds,"seconds",0,60),mE(i.fractionalMilliseconds)))},lE=e=>{const t=(new Date).getUTCFullYear(),r=100*Math.floor(t/100)+Jk(yE(e));return re.getTime()-(new Date).getTime()>15768e8?new Date(Date.UTC(e.getUTCFullYear()-100,e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())):e,cE=e=>{const t=Xk.indexOf(e);if(t<0)throw new TypeError(`Invalid month: ${e}`);return t+1},uE=[31,28,31,30,31,30,31,31,30,31,30,31],pE=(e,t,r)=>{let i=uE[t];if(1===t&&hE(e)&&(i=29),r>i)throw new TypeError(`Invalid day for ${Xk[t]} in ${e}: ${r}`)},hE=e=>e%4==0&&(e%100!=0||e%400==0),fE=(e,t,r,i)=>{const n=(e=>qk("string"==typeof e?Wk(e):e))(yE(e));if(ni)throw new TypeError(`${t} must be between ${r} and ${i}, inclusive`);return n},mE=e=>null==e?0:1e3*(e=>Pk("string"==typeof e?Wk(e):e))("0."+e),gE=e=>{const t=e[0];let r=1;if("+"==t)r=1;else{if("-"!=t)throw new TypeError(`Offset direction, ${t}, must be "+" or "-"`);r=-1}return r*(60*Number(e.substring(1,3))+Number(e.substring(4,6)))*60*1e3},yE=e=>{let t=0;for(;t{Object.entries(t).filter((([,e])=>void 0!==e)).forEach((([t,r])=>{null!=e[t]&&""!==e[t]||(e[t]=r)}));const r=e.message||e.Message||"UnknownError";return e.message=r,delete e.Message,e},wE=e=>({httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}),_E=e=>{switch(e){case"standard":case"cross-region":return{retryMode:"standard",connectionTimeout:3100};case"in-region":return{retryMode:"standard",connectionTimeout:1100};case"mobile":return{retryMode:"standard",connectionTimeout:3e4};default:return{}}};function xE(e){return encodeURIComponent(e).replace(/[!'()*]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}const SE=e=>{const t=[];for(const r in Zx){const i=Zx[r];void 0!==e[i]&&t.push({algorithmId:()=>i,checksumConstructor:()=>e[i]})}return{_checksumAlgorithms:t,addChecksumAlgorithm(e){this._checksumAlgorithms.push(e)},checksumAlgorithms(){return this._checksumAlgorithms}}},kE=e=>{const t={};return e.checksumAlgorithms().forEach((e=>{t[e.algorithmId()]=e.checksumConstructor()})),t},EE=e=>{let t=e.retryStrategy;return{setRetryStrategy(e){t=e},retryStrategy:()=>t}},TE=e=>{const t={};return t.retryStrategy=e.retryStrategy(),t},BE=e=>({...SE(e),...EE(e)}),CE=e=>Array.isArray(e)?e:[e],IE=e=>{const t="#text";for(const r in e)e.hasOwnProperty(r)&&void 0!==e[r][t]?e[r]=e[r][t]:"object"==typeof e[r]&&null!==e[r]&&(e[r]=IE(e[r]));return e},AE=e=>null!=e,FE=function(){const e=Object.getPrototypeOf(this).constructor,t=new(Function.bind.apply(String,[null,...arguments]));return Object.setPrototypeOf(t,e.prototype),t};FE.prototype=Object.create(String.prototype,{constructor:{value:FE,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf(FE,String);class ME{trace(){}debug(){}info(){}warn(){}error(){}}function DE(e,t,r){let i,n,o;if(void 0===t&&void 0===r)i={},o=e;else{if(i=e,"function"==typeof t)return n=t,o=r,RE(i,n,o);o=t}for(const e of Object.keys(o))Array.isArray(o[e])?PE(i,null,o,e):i[e]=o[e];return i}const RE=(e,t,r)=>DE(e,Object.entries(r).reduce(((e,[r,i])=>(Array.isArray(i)?e[r]=i:e[r]="function"==typeof i?[t,i()]:[t,i],e)),{})),PE=(e,t,r,i)=>{if(null!==t){let n=r[i];"function"==typeof n&&(n=[,n]);const[o=OE,s=zE,a=i]=n;return void(("function"==typeof o&&o(t[a])||"function"!=typeof o&&o)&&(e[i]=s(t[a])))}let[n,o]=r[i];if("function"==typeof o){let t;const r=void 0===n&&null!=(t=o()),s="function"==typeof n&&!!n(void 0)||"function"!=typeof n&&!!n;r?e[i]=t:s&&(e[i]=o())}else{const t=void 0===n&&null!=o,r="function"==typeof n&&!!n(o)||"function"!=typeof n&&!!n;(t||r)&&(e[i]=o)}},OE=e=>null!=e,zE=e=>e;function NE(e){return(e.includes(",")||e.includes('"'))&&(e=`"${e.replace(/"/g,'\\"')}"`),e}const qE=e=>e.toISOString().replace(".000Z","Z");const UE={step:"finalizeRequest",tags:["CHECK_CONTENT_LENGTH_HEADER"],name:"getCheckContentLengthHeaderPlugin",override:!0},LE=e=>({applyToStack:e=>{e.add(((e,t)=>async r=>{const{request:i}=r;if(iS.isInstance(i)&&!("content-length"in i.headers)){const e="Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.";"function"!=typeof t?.logger?.warn||t.logger instanceof ME?console.warn(e):t.logger.warn(e)}return e({...r})}),UE)}}),jE={tags:["REGION_REDIRECT","S3"],name:"regionRedirectEndpointMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"};const HE={step:"initialize",tags:["REGION_REDIRECT","S3"],name:"regionRedirectMiddleware",override:!0},$E=e=>({applyToStack:t=>{var r;t.add(function(e){return(t,r)=>async i=>{try{return await t(i)}catch(n){if(e.followRegionRedirects&&(301===n?.$metadata?.httpStatusCode||400===n?.$metadata?.httpStatusCode&&"IllegalLocationConstraintException"===n?.name)){try{const t=n.$response.headers["x-amz-bucket-region"];r.logger?.debug(`Redirecting from ${await e.region()} to ${t}`),r.__s3RegionRedirect=t}catch(e){throw new Error("Region redirect failed: "+e)}return t(i)}throw n}}}(e),HE),t.addRelativeTo((r=e,(e,t)=>async i=>{const n=await r.region(),o=r.region;let s=()=>{};t.__s3RegionRedirect&&(Object.defineProperty(r,"region",{writable:!1,value:async()=>t.__s3RegionRedirect}),s=()=>Object.defineProperty(r,"region",{writable:!0,value:o}));try{const o=await e(i);if(t.__s3RegionRedirect&&(s(),n!==await r.region()))throw new Error("Region was not restored following S3 region redirect.");return o}catch(e){throw s(),e}}),jE)}}),GE={tags:["S3"],name:"s3ExpiresMiddleware",override:!0,relation:"after",toMiddleware:"deserializerMiddleware"},WE=e=>({applyToStack:e=>{e.addRelativeTo(((e,t)=>async r=>{const i=await e(r),{response:n}=i;if(nS.isInstance(n)&&n.headers.expires){n.headers.expiresstring=n.headers.expires;try{sE(n.headers.expires)}catch(e){t.logger?.warn(`AWS SDK Warning for ${t.clientName}::${t.commandName} response parsing (${n.headers.expires}): ${e}`),delete n.headers.expires}}return i}),GE)}});class KE{constructor(e={}){this.data=e,this.lastPurgeTime=Date.now()}get(e){const t=this.data[e];if(t)return t}set(e,t){return this.data[e]=t,t}delete(e){delete this.data[e]}async purgeExpired(){const e=Date.now();if(!(this.lastPurgeTime+KE.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>e))for(const t in this.data){const r=this.data[t];if(!r.isRefreshing){const i=await r.identity;i.expiration&&i.expiration.getTime(){if((e.expiration?.getTime()??0){i.set(r,new VE(Promise.resolve(e)))}))),e})):i.set(r,new VE(this.getIdentity(r))).identity}async getIdentity(e){await this.cache.purgeExpired().catch((e=>{console.warn("Error while clearing expired entries in S3ExpressIdentityCache: \n"+e)}));const t=await this.createSessionFn(e);if(!t.Credentials?.AccessKeyId||!t.Credentials?.SecretAccessKey)throw new Error("s3#createSession response credential missing AccessKeyId or SecretAccessKey.");return{accessKeyId:t.Credentials.AccessKeyId,secretAccessKey:t.Credentials.SecretAccessKey,sessionToken:t.Credentials.SessionToken,expiration:t.Credentials.Expiration?new Date(t.Credentials.Expiration):void 0}}}JE.REFRESH_WINDOW_MS=6e4;const YE="X-Amz-Date",QE="X-Amz-Signature",ZE="X-Amz-Security-Token",XE="authorization",eT=YE.toLowerCase(),tT=[XE,eT,"date"],rT=QE.toLowerCase(),iT="x-amz-content-sha256",nT=ZE.toLowerCase(),oT={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},sT=/^proxy-/,aT=/^sec-/,lT="AWS4-HMAC-SHA256",dT="AWS4-HMAC-SHA256-PAYLOAD",cT="aws4_request",uT={},pT=[],hT=(e,t,r)=>`${e}/${t}/${r}/${cT}`,fT=(e,t,r)=>{const i=new e(t);return i.update(PS(r)),i.digest()},mT=({headers:e},t,r)=>{const i={};for(const n of Object.keys(e).sort()){if(null==e[n])continue;const o=n.toLowerCase();(o in oT||t?.has(o)||sT.test(o)||aT.test(o))&&(!r||r&&!r.has(o))||(i[o]=e[n].trim().replace(/\s+/g," "))}return i},gT=async({headers:e,body:t},r)=>{for(const t of Object.keys(e))if(t.toLowerCase()===iT)return e[t];if(null==t)return"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";if("string"==typeof t||ArrayBuffer.isView(t)||bS(t)){const e=new r;return e.update(PS(t)),Sk(await e.digest())}return"UNSIGNED-PAYLOAD"};class yT{format(e){const t=[];for(const r of Object.keys(e)){const i=RS(r);t.push(Uint8Array.from([i.byteLength]),i,this.formatHeaderValue(e[r]))}const r=new Uint8Array(t.reduce(((e,t)=>e+t.byteLength),0));let i=0;for(const e of t)r.set(e,i),i+=e.byteLength;return r}formatHeaderValue(e){switch(e.type){case"boolean":return Uint8Array.from([e.value?0:1]);case"byte":return Uint8Array.from([2,e.value]);case"short":const t=new DataView(new ArrayBuffer(3));return t.setUint8(0,3),t.setInt16(1,e.value,!1),new Uint8Array(t.buffer);case"integer":const r=new DataView(new ArrayBuffer(5));return r.setUint8(0,4),r.setInt32(1,e.value,!1),new Uint8Array(r.buffer);case"long":const i=new Uint8Array(9);return i[0]=5,i.set(e.value.bytes,1),i;case"binary":const n=new DataView(new ArrayBuffer(3+e.value.byteLength));n.setUint8(0,6),n.setUint16(1,e.value.byteLength,!1);const o=new Uint8Array(n.buffer);return o.set(e.value,3),o;case"string":const s=RS(e.value),a=new DataView(new ArrayBuffer(3+s.byteLength));a.setUint8(0,7),a.setUint16(1,s.byteLength,!1);const l=new Uint8Array(a.buffer);return l.set(s,3),l;case"timestamp":const d=new Uint8Array(9);return d[0]=8,d.set(wT.fromNumber(e.value.valueOf()).bytes,1),d;case"uuid":if(!bT.test(e.value))throw new Error(`Invalid UUID received: ${e.value}`);const c=new Uint8Array(17);return c[0]=9,c.set(xk(e.value.replace(/\-/g,"")),1),c}}}var vT;!function(e){e[e.boolTrue=0]="boolTrue",e[e.boolFalse=1]="boolFalse",e[e.byte=2]="byte",e[e.short=3]="short",e[e.integer=4]="integer",e[e.long=5]="long",e[e.byteArray=6]="byteArray",e[e.string=7]="string",e[e.timestamp=8]="timestamp",e[e.uuid=9]="uuid"}(vT||(vT={}));const bT=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;class wT{constructor(e){if(this.bytes=e,8!==e.byteLength)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(e){if(e>0x8000000000000000||e<-0x8000000000000000)throw new Error(`${e} is too large (or, if negative, too small) to represent as an Int64`);const t=new Uint8Array(8);for(let r=7,i=Math.abs(Math.round(e));r>-1&&i>0;r--,i/=256)t[r]=i;return e<0&&_T(t),new wT(t)}valueOf(){const e=this.bytes.slice(0),t=128&e[0];return t&&_T(e),parseInt(Sk(e),16)*(t?-1:1)}toString(){return String(this.valueOf())}}function _T(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,0===e[t]);t--);}const xT=e=>{e=iS.clone(e);for(const t of Object.keys(e.headers))tT.indexOf(t.toLowerCase())>-1&&delete e.headers[t];return e},ST=e=>"number"==typeof e?new Date(1e3*e):"string"==typeof e?Number(e)?new Date(1e3*Number(e)):new Date(e):e;class kT{constructor({applyChecksum:e,credentials:t,region:r,service:i,sha256:n,uriEscapePath:o=!0}){this.headerFormatter=new yT,this.service=i,this.sha256=n,this.uriEscapePath=o,this.applyChecksum="boolean"!=typeof e||e,this.regionProvider=WS(r),this.credentialProvider=WS(t)}async presign(e,t={}){const{signingDate:r=new Date,expiresIn:i=3600,unsignableHeaders:n,unhoistableHeaders:o,signableHeaders:s,hoistableHeaders:a,signingRegion:l,signingService:d}=t,c=await this.credentialProvider();this.validateResolvedCredentials(c);const u=l??await this.regionProvider(),{longDate:p,shortDate:h}=ET(r);if(i>604800)return Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future");const f=hT(h,u,d??this.service),m=((e,t={})=>{const{headers:r,query:i={}}=iS.clone(e);for(const e of Object.keys(r)){const n=e.toLowerCase();("x-amz-"===n.slice(0,6)&&!t.unhoistableHeaders?.has(n)||t.hoistableHeaders?.has(n))&&(i[e]=r[e],delete r[e])}return{...e,headers:r,query:i}})(xT(e),{unhoistableHeaders:o,hoistableHeaders:a});c.sessionToken&&(m.query[ZE]=c.sessionToken),m.query["X-Amz-Algorithm"]=lT,m.query["X-Amz-Credential"]=`${c.accessKeyId}/${f}`,m.query[YE]=p,m.query["X-Amz-Expires"]=i.toString(10);const g=mT(m,n,s);return m.query["X-Amz-SignedHeaders"]=TT(g),m.query[QE]=await this.getSignature(p,f,this.getSigningKey(c,u,h,d),this.createCanonicalRequest(m,g,await gT(e,this.sha256))),m}async sign(e,t){return"string"==typeof e?this.signString(e,t):e.headers&&e.payload?this.signEvent(e,t):e.message?this.signMessage(e,t):this.signRequest(e,t)}async signEvent({headers:e,payload:t},{signingDate:r=new Date,priorSignature:i,signingRegion:n,signingService:o}){const s=n??await this.regionProvider(),{shortDate:a,longDate:l}=ET(r),d=hT(a,s,o??this.service),c=await gT({headers:{},body:t},this.sha256),u=new this.sha256;u.update(e);const p=Sk(await u.digest()),h=[dT,l,d,i,p,c].join("\n");return this.signString(h,{signingDate:r,signingRegion:s,signingService:o})}async signMessage(e,{signingDate:t=new Date,signingRegion:r,signingService:i}){return this.signEvent({headers:this.headerFormatter.format(e.message.headers),payload:e.message.body},{signingDate:t,signingRegion:r,signingService:i,priorSignature:e.priorSignature}).then((t=>({message:e.message,signature:t})))}async signString(e,{signingDate:t=new Date,signingRegion:r,signingService:i}={}){const n=await this.credentialProvider();this.validateResolvedCredentials(n);const o=r??await this.regionProvider(),{shortDate:s}=ET(t),a=new this.sha256(await this.getSigningKey(n,o,s,i));return a.update(PS(e)),Sk(await a.digest())}async signRequest(e,{signingDate:t=new Date,signableHeaders:r,unsignableHeaders:i,signingRegion:n,signingService:o}={}){const s=await this.credentialProvider();this.validateResolvedCredentials(s);const a=n??await this.regionProvider(),l=xT(e),{longDate:d,shortDate:c}=ET(t),u=hT(c,a,o??this.service);l.headers[eT]=d,s.sessionToken&&(l.headers[nT]=s.sessionToken);const p=await gT(l,this.sha256);!((e,t)=>{e=e.toLowerCase();for(const r of Object.keys(t))if(e===r.toLowerCase())return!0;return!1})(iT,l.headers)&&this.applyChecksum&&(l.headers[iT]=p);const h=mT(l,i,r),f=await this.getSignature(d,u,this.getSigningKey(s,a,c,o),this.createCanonicalRequest(l,h,p));return l.headers[XE]=`${lT} Credential=${s.accessKeyId}/${u}, SignedHeaders=${TT(h)}, Signature=${f}`,l}createCanonicalRequest(e,t,r){const i=Object.keys(t).sort();return`${e.method}\n${this.getCanonicalPath(e)}\n${(({query:e={}})=>{const t=[],r={};for(const i of Object.keys(e)){if(i.toLowerCase()===rT)continue;const n=hk(i);t.push(n);const o=e[i];"string"==typeof o?r[n]=`${n}=${hk(o)}`:Array.isArray(o)&&(r[n]=o.slice(0).reduce(((e,t)=>e.concat([`${n}=${hk(t)}`])),[]).sort().join("&"))}return t.sort().map((e=>r[e])).filter((e=>e)).join("&")})(e)}\n${i.map((e=>`${e}:${t[e]}`)).join("\n")}\n\n${i.join(";")}\n${r}`}async createStringToSign(e,t,r){const i=new this.sha256;i.update(PS(r));const n=await i.digest();return`${lT}\n${e}\n${t}\n${Sk(n)}`}getCanonicalPath({path:e}){if(this.uriEscapePath){const t=[];for(const r of e.split("/"))0!==r?.length&&"."!==r&&(".."===r?t.pop():t.push(r));const r=`${e?.startsWith("/")?"/":""}${t.join("/")}${t.length>0&&e?.endsWith("/")?"/":""}`;return hk(r).replace(/%2F/g,"/")}return e}async getSignature(e,t,r,i){const n=await this.createStringToSign(e,t,i),o=new this.sha256(await r);return o.update(PS(n)),Sk(await o.digest())}getSigningKey(e,t,r,i){return(async(e,t,r,i,n)=>{const o=`${r}:${i}:${n}:${Sk(await fT(e,t.secretAccessKey,t.accessKeyId))}:${t.sessionToken}`;if(o in uT)return uT[o];for(pT.push(o);pT.length>50;)delete uT[pT.shift()];let s=`AWS4${t.secretAccessKey}`;for(const t of[r,i,n,cT])s=await fT(e,s,t);return uT[o]=s})(this.sha256,e,r,t,i||this.service)}validateResolvedCredentials(e){if("object"!=typeof e||"string"!=typeof e.accessKeyId||"string"!=typeof e.secretAccessKey)throw new Error("Resolved credential object is not valid")}}const ET=e=>{const t=(r=e,ST(r).toISOString().replace(/\.\d{3}Z$/,"Z")).replace(/[\-:]/g,"");var r;return{longDate:t,shortDate:t.slice(0,8)}},TT=e=>Object.keys(e).sort().join(";");var BT;!function(e){e.ENV="env",e.CONFIG="shared config entry"}(BT||(BT={}));const CT="X-Amz-S3session-Token",IT=CT.toLowerCase();class AT extends kT{async signWithCredentials(e,t,r){const i=FT(t);e.headers[IT]=t.sessionToken;return MT(this,i),this.signRequest(e,r??{})}async presignWithCredentials(e,t,r){const i=FT(t);delete e.headers[IT],e.headers[CT]=t.sessionToken,e.query=e.query??{},e.query[CT]=t.sessionToken;return MT(this,i),this.presign(e,r)}}function FT(e){return{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey,expiration:e.expiration}}function MT(e,t){const r=setTimeout((()=>{throw new Error("SignatureV4S3Express credential override was created but not called.")}),10),i=e.credentialProvider;e.credentialProvider=()=>(clearTimeout(r),e.credentialProvider=i,Promise.resolve(t))}const DT={name:"s3ExpressMiddleware",step:"build",tags:["S3","S3_EXPRESS"],override:!0},RT=e=>({applyToStack:t=>{t.add((e=>(t,r)=>async i=>{if(r.endpointV2){const t=r.endpointV2,n="sigv4-s3express"===t.properties?.authSchemes?.[0]?.name;if(("S3Express"===t.properties?.backend||"Directory"===t.properties?.bucketType)&&(mS(r,"S3_EXPRESS_BUCKET","J"),r.isS3ExpressBucket=!0),n){const t=i.input.Bucket;if(t){const n=await e.s3ExpressIdentityProvider.getS3ExpressIdentity(await e.credentials(),{Bucket:t});r.s3ExpressIdentity=n,iS.isInstance(i.request)&&n.sessionToken&&(i.request.headers[IT]=n.sessionToken)}}}return t(i)})(e),DT)}});const PT=(e,t)=>(r,i)=>async n=>{const o=e.httpAuthSchemeProvider(await t.httpAuthSchemeParametersProvider(e,i,n.input)),s=function(e){const t=new Map;for(const r of e)t.set(r.schemeId,r);return t}(e.httpAuthSchemes),a=GS(i),l=[];for(const r of o){const n=s.get(r.schemeId);if(!n){l.push(`HttpAuthScheme \`${r.schemeId}\` was not enabled for this service.`);continue}const o=n.identityProvider(await t.identityProviderConfigProvider(e));if(!o){l.push(`HttpAuthScheme \`${r.schemeId}\` did not have an IdentityProvider configured.`);continue}const{identityProperties:d={},signingProperties:c={}}=r.propertiesExtractor?.(e,i)||{};r.identityProperties=Object.assign(r.identityProperties||{},d),r.signingProperties=Object.assign(r.signingProperties||{},c),a.selectedHttpAuthScheme={httpAuthOption:r,identity:await o(r.identityProperties),signer:n.signer};break}if(!a.selectedHttpAuthScheme)throw new Error(l.join("\n"));return r(n)},OT=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,zT=/(\d+\.){3}\d+/,NT=/\.\./,qT=e=>OT.test(e)&&!zT.test(e)&&!NT.test(e),UT=e=>{const[t,r,i,,,n]=e.split(":"),o="arn"===t&&e.split(":").length>=6,s=Boolean(o&&r&&i&&n);if(o&&!s)throw new Error(`Invalid ARN: ${e} was an invalid ARN.`);return s},LT=(e,t,r)=>{const i=async()=>{const i=r[e]??r[t];return"function"==typeof i?i():i};return"credentialScope"===e||"CredentialScope"===t?async()=>{const e="function"==typeof r.credentials?await r.credentials():r.credentials;return e?.credentialScope??e?.CredentialScope}:"accountId"===e||"AccountId"===t?async()=>{const e="function"==typeof r.credentials?await r.credentials():r.credentials;return e?.accountId??e?.AccountId}:"endpoint"===e||"endpoint"===t?async()=>{const e=await i();if(e&&"object"==typeof e){if("url"in e)return e.url.href;if("hostname"in e){const{protocol:t,hostname:r,port:i,path:n}=e;return`${t}//${r}${i?":"+i:""}${n}`}}return e}:i},jT=async e=>{};const HT=e=>{if("string"==typeof e)return HT(new URL(e));const{hostname:t,pathname:r,port:i,protocol:n,search:o}=e;let s;return o&&(s=function(e){const t={};if(e=e.replace(/^\?/,""))for(const r of e.split("&")){let[e,i=null]=r.split("=");e=decodeURIComponent(e),i&&(i=decodeURIComponent(i)),e in t?Array.isArray(t[e])?t[e].push(i):t[e]=[t[e],i]:t[e]=i}return t}(o)),{hostname:t,port:i?parseInt(i):void 0,protocol:n,path:r,query:s}},$T=e=>"object"==typeof e?"url"in e?HT(e.url):e:HT(e),GT=async(e,t,r,i)=>{if(!r.endpoint){let e;e=r.serviceConfiguredEndpoint?await r.serviceConfiguredEndpoint():await jT(r.serviceId),e&&(r.endpoint=()=>Promise.resolve($T(e)))}const n=await WT(e,t,r);if("function"!=typeof r.endpointProvider)throw new Error("config.endpointProvider is not set.");return r.endpointProvider(n,i)},WT=async(e,t,r)=>{const i={},n=t?.getEndpointParameterInstructions?.()||{};for(const[t,o]of Object.entries(n))switch(o.type){case"staticContextParams":i[t]=o.value;break;case"contextParams":i[t]=e[o.name];break;case"clientContextParams":case"builtInParams":i[t]=await LT(o.name,t,r)();break;default:throw new Error("Unrecognized endpoint parameter instruction: "+JSON.stringify(o))}return 0===Object.keys(n).length&&Object.assign(i,r),"s3"===String(r.serviceId).toLowerCase()&&await(async e=>{const t=e?.Bucket||"";if("string"==typeof e.Bucket&&(e.Bucket=t.replace(/#/g,encodeURIComponent("#")).replace(/\?/g,encodeURIComponent("?"))),UT(t)){if(!0===e.ForcePathStyle)throw new Error("Path-style addressing cannot be used with ARN buckets")}else(!qT(t)||-1!==t.indexOf(".")&&!String(e.Endpoint).startsWith("http:")||t.toLowerCase()!==t||t.length<3)&&(e.ForcePathStyle=!0);return e.DisableMultiRegionAccessPoints&&(e.disableMultiRegionAccessPoints=!0,e.DisableMRAP=!0),e})(i),i},KT={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},VT={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function JT(e,t,r){return{applyToStack:i=>{i.add(((e,t)=>r=>async i=>{const{response:n}=await r(i);try{return{response:n,output:await t(n,e)}}catch(e){if(Object.defineProperty(e,"$response",{value:n}),!("$metadata"in e)){const t="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";e.message+="\n "+t,void 0!==e.$responseBodyText&&e.$response&&(e.$response.body=e.$responseBodyText)}throw e}})(e,r),KT),i.add(((e,t)=>(r,i)=>async n=>{const o=i.endpointV2?.url&&e.urlParser?async()=>e.urlParser(i.endpointV2.url):e.endpoint;if(!o)throw new Error("No valid endpoint provider available.");const s=await t(n.input,{...e,endpoint:o});return r({...n,request:s})})(e,t),VT)}}}const YT={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:VT.name},QT=(e,t)=>({applyToStack:r=>{r.addRelativeTo((({config:e,instructions:t})=>(r,i)=>async n=>{const o=await GT(n.input,{getEndpointParameterInstructions:()=>t},{...e},i);i.endpointV2=o,i.authSchemes=o.properties?.authSchemes;const s=i.authSchemes?.[0];if(s){i.signing_region=s.signingRegion,i.signing_service=s.signingName;const e=GS(i),t=e?.selectedHttpAuthScheme?.httpAuthOption;t&&(t.signingProperties=Object.assign(t.signingProperties||{},{signing_region:s.signingRegion,signingRegion:s.signingRegion,signing_service:s.signingName,signingName:s.signingName,signingRegionSet:s.signingRegionSet},s.properties))}return r({...n})})({config:e,instructions:t}),YT)}}),ZT={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:YT.name},XT=e=>e=>{throw e},eB=(e,t)=>{};var tB;!function(e){e.STANDARD="standard",e.ADAPTIVE="adaptive"}(tB||(tB={}));const rB=tB.STANDARD,iB=["BandwidthLimitExceeded","EC2ThrottledException","LimitExceededException","PriorRequestNotComplete","ProvisionedThroughputExceededException","RequestLimitExceeded","RequestThrottled","RequestThrottledException","SlowDown","ThrottledException","Throttling","ThrottlingException","TooManyRequestsException","TransactionInProgressException"],nB=["TimeoutError","RequestTimeout","RequestTimeoutException"],oB=[500,502,503,504],sB=["ECONNRESET","ECONNREFUSED","EPIPE","ETIMEDOUT"],aB=e=>429===e.$metadata?.httpStatusCode||iB.includes(e.name)||1==e.$retryable?.throttling,lB=e=>(e=>e.$metadata?.clockSkewCorrected)(e)||nB.includes(e.name)||sB.includes(e?.code||"")||oB.includes(e.$metadata?.httpStatusCode||0);class dB{constructor(e){this.currentCapacity=0,this.enabled=!1,this.lastMaxRate=0,this.measuredTxRate=0,this.requestCount=0,this.lastTimestamp=0,this.timeWindow=0,this.beta=e?.beta??.7,this.minCapacity=e?.minCapacity??1,this.minFillRate=e?.minFillRate??.5,this.scaleConstant=e?.scaleConstant??.4,this.smooth=e?.smooth??.8;const t=this.getCurrentTimeInSeconds();this.lastThrottleTime=t,this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}getCurrentTimeInSeconds(){return Date.now()/1e3}async getSendToken(){return this.acquireTokenBucket(1)}async acquireTokenBucket(e){if(this.enabled){if(this.refillTokenBucket(),e>this.currentCapacity){const t=(e-this.currentCapacity)/this.fillRate*1e3;await new Promise((e=>setTimeout(e,t)))}this.currentCapacity=this.currentCapacity-e}}refillTokenBucket(){const e=this.getCurrentTimeInSeconds();if(!this.lastTimestamp)return void(this.lastTimestamp=e);const t=(e-this.lastTimestamp)*this.fillRate;this.currentCapacity=Math.min(this.maxCapacity,this.currentCapacity+t),this.lastTimestamp=e}updateClientSendingRate(e){let t;if(this.updateMeasuredRate(),aB(e)){const e=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=e,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),t=this.cubicThrottle(e),this.enableTokenBucket()}else this.calculateTimeWindow(),t=this.cubicSuccess(this.getCurrentTimeInSeconds());const r=Math.min(t,2*this.measuredTxRate);this.updateTokenBucketRate(r)}calculateTimeWindow(){this.timeWindow=this.getPrecise(Math.pow(this.lastMaxRate*(1-this.beta)/this.scaleConstant,1/3))}cubicThrottle(e){return this.getPrecise(e*this.beta)}cubicSuccess(e){return this.getPrecise(this.scaleConstant*Math.pow(e-this.lastThrottleTime-this.timeWindow,3)+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(e){this.refillTokenBucket(),this.fillRate=Math.max(e,this.minFillRate),this.maxCapacity=Math.max(e,this.minCapacity),this.currentCapacity=Math.min(this.currentCapacity,this.maxCapacity)}updateMeasuredRate(){const e=this.getCurrentTimeInSeconds(),t=Math.floor(2*e)/2;if(this.requestCount++,t>this.lastTxRateBucket){const e=this.requestCount/(t-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(e*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=t}}getPrecise(e){return parseFloat(e.toFixed(8))}}const cB=100,uB=2e4,pB="amz-sdk-invocation-id",hB="amz-sdk-request",fB=({retryDelay:e,retryCount:t,retryCost:r})=>({getRetryCount:()=>t,getRetryDelay:()=>Math.min(uB,e),getRetryCost:()=>r});class mB{constructor(e){this.maxAttempts=e,this.mode=tB.STANDARD,this.capacity=500,this.retryBackoffStrategy=(()=>{let e=cB;return{computeNextBackoffDelay:t=>Math.floor(Math.min(uB,Math.random()*2**t*e)),setDelayBase:t=>{e=t}}})(),this.maxAttemptsProvider="function"==typeof e?e:async()=>e}async acquireInitialRetryToken(e){return fB({retryDelay:cB,retryCount:0})}async refreshRetryTokenForRetry(e,t){const r=await this.getMaxAttempts();if(this.shouldRetry(e,t,r)){const r=t.errorType;this.retryBackoffStrategy.setDelayBase("THROTTLING"===r?500:cB);const i=this.retryBackoffStrategy.computeNextBackoffDelay(e.getRetryCount()),n=t.retryAfterHint?Math.max(t.retryAfterHint.getTime()-Date.now()||0,i):i,o=this.getCapacityCost(r);return this.capacity-=o,fB({retryDelay:n,retryCount:e.getRetryCount()+1,retryCost:o})}throw new Error("No retry token available")}recordSuccess(e){this.capacity=Math.max(500,this.capacity+(e.getRetryCost()??1))}getCapacity(){return this.capacity}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch(e){return console.warn("Max attempts provider could not resolve. Using default of 3"),3}}shouldRetry(e,t,r){return e.getRetryCount()+1=this.getCapacityCost(t.errorType)&&this.isRetryableError(t.errorType)}getCapacityCost(e){return"TRANSIENT"===e?10:5}isRetryableError(e){return"THROTTLING"===e||"TRANSIENT"===e}}class gB{constructor(e,t){this.maxAttemptsProvider=e,this.mode=tB.ADAPTIVE;const{rateLimiter:r}=t??{};this.rateLimiter=r??new dB,this.standardRetryStrategy=new mB(e)}async acquireInitialRetryToken(e){return await this.rateLimiter.getSendToken(),this.standardRetryStrategy.acquireInitialRetryToken(e)}async refreshRetryTokenForRetry(e,t){return this.rateLimiter.updateClientSendingRate(t),this.standardRetryStrategy.refreshRetryTokenForRetry(e,t)}recordSuccess(e){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(e)}}const yB={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let vB;const bB=new Uint8Array(16);function wB(){if(!vB&&(vB="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!vB))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return vB(bB)}const _B=[];for(let e=0;e<256;++e)_B.push((e+256).toString(16).slice(1));function xB(e,t=0){return _B[e[t+0]]+_B[e[t+1]]+_B[e[t+2]]+_B[e[t+3]]+"-"+_B[e[t+4]]+_B[e[t+5]]+"-"+_B[e[t+6]]+_B[e[t+7]]+"-"+_B[e[t+8]]+_B[e[t+9]]+"-"+_B[e[t+10]]+_B[e[t+11]]+_B[e[t+12]]+_B[e[t+13]]+_B[e[t+14]]+_B[e[t+15]]}const SB=function(e,t,r){if(yB.randomUUID&&!t&&!e)return yB.randomUUID();const i=(e=e||{}).random||(e.rng||wB)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,t){r=r||0;for(let e=0;e<16;++e)t[r+e]=i[e];return t}return xB(i)},kB=e=>e instanceof Error?e:e instanceof Object?Object.assign(new Error,e):"string"==typeof e?new Error(e):new Error(`AWS SDK error wrapper for ${e}`);const EB=e=>e?.body instanceof ReadableStream,TB=e=>void 0!==e.acquireInitialRetryToken&&void 0!==e.refreshRetryTokenForRetry&&void 0!==e.recordSuccess,BB=e=>{const t={error:e,errorType:CB(e)},r=FB(e.$response);return r&&(t.retryAfterHint=r),t},CB=e=>aB(e)?"THROTTLING":lB(e)?"TRANSIENT":(e=>{if(void 0!==e.$metadata?.httpStatusCode){const t=e.$metadata.httpStatusCode;return 500<=t&&t<=599&&!lB(e)}return!1})(e)?"SERVER_ERROR":"CLIENT_ERROR",IB={name:"retryMiddleware",tags:["RETRY"],step:"finalizeRequest",priority:"high",override:!0},AB=e=>({applyToStack:t=>{t.add((e=>(t,r)=>async i=>{let n=await e.retryStrategy();const o=await e.maxAttempts();if(!TB(n))return n?.mode&&(r.userAgent=[...r.userAgent||[],["cfg/retry-mode",n.mode]]),n.retry(t,i);{let e=await n.acquireInitialRetryToken(r.partition_id),s=new Error,a=0,l=0;const{request:d}=i,c=iS.isInstance(d);for(c&&(d.headers[pB]=SB());;)try{c&&(d.headers[hB]=`attempt=${a+1}; max=${o}`);const{response:r,output:s}=await t(i);return n.recordSuccess(e),s.$metadata.attempts=a+1,s.$metadata.totalRetryDelay=l,{response:r,output:s}}catch(t){const i=BB(t);if(s=kB(t),c&&EB(d))throw(r.logger instanceof ME?console:r.logger)?.warn("An error was encountered in a non-retryable streaming request."),s;try{e=await n.refreshRetryTokenForRetry(e,i)}catch(e){throw s.$metadata||(s.$metadata={}),s.$metadata.attempts=a+1,s.$metadata.totalRetryDelay=l,s}a=e.getRetryCount();const o=e.getRetryDelay();l+=o,await new Promise((e=>setTimeout(e,o)))}}})(e),IB)}}),FB=e=>{if(!nS.isInstance(e))return;const t=Object.keys(e.headers).find((e=>"retry-after"===e.toLowerCase()));if(!t)return;const r=e.headers[t],i=Number(r);if(!Number.isNaN(i))return new Date(1e3*i);return new Date(r)},MB={step:"finalizeRequest",tags:["HTTP_SIGNING"],name:"httpSigningMiddleware",aliases:["apiKeyMiddleware","tokenMiddleware","awsAuthMiddleware"],override:!0,relation:"after",toMiddleware:IB.name},DB=e=>({applyToStack:e=>{e.addRelativeTo(((e,t)=>async r=>{if(!iS.isInstance(r.request))return e(r);const i=GS(t).selectedHttpAuthScheme;if(!i)throw new Error("No HttpAuthScheme was selected: unable to sign request");const{httpAuthOption:{signingProperties:n={}},identity:o,signer:s}=i,a=await e({...r,request:await s.sign(r.request,o,n)}).catch((s.errorHandler||XT)(n));return(s.successHandler||eB)(a.response,n),a}),MB)}});class RB{constructor(e){this.authSchemes=new Map;for(const[t,r]of Object.entries(e))void 0!==r&&this.authSchemes.set(t,r)}getIdentityProvider(e){return this.authSchemes.get(e)}}const PB=(OB=3e5,e=>zB(e)&&e.expiration.getTime()-Date.now()void 0!==e.expiration,NB=e=>{if("function"==typeof e)return e;const t=Promise.resolve(e);return()=>t};function qB(e,t){return new UB(e,t)}class UB{constructor(e,t){this.input=e,this.context=t,this.query={},this.method="",this.headers={},this.path="",this.body=null,this.hostname="",this.resolvePathStack=[]}async build(){const{hostname:e,protocol:t="https",port:r,path:i}=await this.context.endpoint();this.path=i;for(const e of this.resolvePathStack)e(this.path);return new iS({protocol:t,hostname:this.hostname||e,port:r,method:this.method,path:this.path,query:this.query,body:this.body,headers:this.headers})}hn(e){return this.hostname=e,this}bp(e){return this.resolvePathStack.push((t=>{this.path=`${t?.endsWith("/")?t.slice(0,-1):t||""}`+e})),this}p(e,t,r,i){return this.resolvePathStack.push((n=>{this.path=((e,t,r,i,n,o)=>{if(null==t||void 0===t[r])throw new Error("No value provided for input HTTP label: "+r+".");{const t=i();if(t.length<=0)throw new Error("Empty value provided for input HTTP label: "+r+".");e=e.replace(n,o?t.split("/").map((e=>xE(e))).join("/"):xE(t))}return e})(n,this.input,e,t,r,i)})),this}h(e){return this.headers=e,this}q(e){return this.query=e,this}b(e){return this.body=e,this}m(e){return this.method=e,this}}const LB=e=>e=>{throw e},jB=(e,t)=>{},HB=e=>(t,r)=>async i=>{if(!iS.isInstance(i.request))return t(i);const n=GS(r).selectedHttpAuthScheme;if(!n)throw new Error("No HttpAuthScheme was selected: unable to sign request");const{httpAuthOption:{signingProperties:o={}},identity:s,signer:a}=n;let l;l=r.s3ExpressIdentity?await(async(e,t,r,i)=>{const n=await i.signWithCredentials(r,e,{});if(n.headers["X-Amz-Security-Token"]||n.headers["x-amz-security-token"])throw new Error("X-Amz-Security-Token must not be set for s3-express requests.");return n})(r.s3ExpressIdentity,0,i.request,await e.signer()):await a.sign(i.request,s,o);const d=await t({...i,request:l}).catch((a.errorHandler||LB)(o));return(a.successHandler||jB)(d.response,o),d},$B={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},GB=e=>(t,r)=>async i=>{const n=await t(i),{response:o}=n;if(!nS.isInstance(o))return n;const{statusCode:s,body:a}=o;if(s<200||s>=300)return n;if(!("function"==typeof a?.stream||"function"==typeof a?.pipe||"function"==typeof a?.tee))return n;let l=a,d=a;!a||"object"!=typeof a||a instanceof Uint8Array||([l,d]=await async function(e){return"function"==typeof e.stream&&(e=e.stream()),e.tee()}(a)),o.body=d;const c=await WB(l,{streamCollector:async e=>async function(e,t){let r=0;const i=[],n=e.getReader();let o=!1;for(;!o;){const{done:e,value:s}=await n.read();if(s&&(i.push(s),r+=s?.byteLength??0),r>=t)break;o=e}n.releaseLock();const s=new Uint8Array(Math.min(t,r));let a=0;for(const e of i){if(e.byteLength>s.byteLength-a){s.set(e.subarray(0,s.byteLength-a),a);break}s.set(e,a),a+=e.length}return s}(e,3e3)});"function"==typeof l?.destroy&&l.destroy();const u=e.utf8Encoder(c.subarray(c.length-16));if(0===c.length&&$B[r.commandName]){const e=new Error("S3 aborted request");throw e.name="InternalError",e}return u&&u.endsWith("")&&(o.statusCode=400),n},WB=(e=new Uint8Array,t)=>e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array),KB={relation:"after",toMiddleware:"deserializerMiddleware",tags:["THROW_200_EXCEPTIONS","S3"],name:"throw200ExceptionsMiddleware",override:!0},VB=e=>({applyToStack:t=>{t.addRelativeTo(GB(e),KB)}});const JB={name:"bucketEndpointMiddleware",override:!0,relation:"after",toMiddleware:"endpointV2Middleware"};const YB={step:"initialize",tags:["VALIDATE_BUCKET_NAME"],name:"validateBucketNameMiddleware",override:!0},QB=e=>({applyToStack:t=>{t.add(function({bucketEndpoint:e}){return t=>async r=>{const{input:{Bucket:i}}=r;if(!e&&"string"==typeof i&&!("string"==typeof(n=i)&&0===n.indexOf("arn:")&&n.split(":").length>=6)&&i.indexOf("/")>=0){const e=new Error(`Bucket name shouldn't contain '/', received '${i}'`);throw e.name="InvalidBucketName",e}var n;return t({...r})}}(e),YB),t.addRelativeTo(function(e){return(t,r)=>async i=>{if(e.bucketEndpoint){const e=r.endpointV2;if(e){const t=i.input.Bucket;if("string"==typeof t)try{const i=new URL(t);r.endpointV2={...e,url:i}}catch(e){const i=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${t} could not be parsed as URL.`;throw"NoOpLogger"===r.logger?.constructor?.name?console.warn(i):r.logger?.warn?.(i),e}}}return t(i)}}(e),JB)}});const ZB=new RegExp("^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$"),XB=e=>ZB.test(e)||e.startsWith("[")&&e.endsWith("]"),eC=new RegExp("^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$"),tC=(e,t=!1)=>{if(!t)return eC.test(e);const r=e.split(".");for(const e of r)if(!tC(e))return!1;return!0},rC={},iC="endpoints";function nC(e){return"object"!=typeof e||null==e?e:"ref"in e?`$${nC(e.ref)}`:"fn"in e?`${e.fn}(${(e.argv||[]).map(nC).join(", ")})`:JSON.stringify(e,null,2)}class oC extends Error{constructor(e){super(e),this.name="EndpointError"}}const sC=(e,t)=>(e=>{const t=e.split("."),r=[];for(const i of t){const t=i.indexOf("[");if(-1!==t){if(i.indexOf("]")!==i.length-1)throw new oC(`Path: '${e}' does not end with ']'`);const n=i.slice(t+1,-1);if(Number.isNaN(parseInt(n)))throw new oC(`Invalid array index: '${n}' in path: '${e}'`);0!==t&&r.push(i.slice(0,t)),r.push(n)}else r.push(i)}return r})(t).reduce(((r,i)=>{if("object"!=typeof r)throw new oC(`Index '${i}' in '${t}' not found in '${JSON.stringify(e)}'`);return Array.isArray(r)?r[parseInt(i)]:r[i]}),e),aC={[Qx.HTTP]:80,[Qx.HTTPS]:443},lC={booleanEquals:(e,t)=>e===t,getAttr:sC,isSet:e=>null!=e,isValidHostLabel:tC,not:e=>!e,parseURL:e=>{const t=(()=>{try{if(e instanceof URL)return e;if("object"==typeof e&&"hostname"in e){const{hostname:t,port:r,protocol:i="",path:n="",query:o={}}=e,s=new URL(`${i}//${t}${r?`:${r}`:""}${n}`);return s.search=Object.entries(o).map((([e,t])=>`${e}=${t}`)).join("&"),s}return new URL(e)}catch(e){return null}})();if(!t)return console.error(`Unable to parse ${JSON.stringify(e)} as a whatwg URL.`),null;const r=t.href,{host:i,hostname:n,pathname:o,protocol:s,search:a}=t;if(a)return null;const l=s.slice(0,-1);if(!Object.values(Qx).includes(l))return null;const d=XB(n);return{scheme:l,authority:`${i}${r.includes(`${i}:${aC[l]}`)||"string"==typeof e&&e.includes(`${i}:${aC[l]}`)?`:${aC[l]}`:""}`,path:o,normalizedPath:o.endsWith("/")?o:`${o}/`,isIp:d}},stringEquals:(e,t)=>e===t,substring:(e,t,r,i)=>t>=r||e.lengthencodeURIComponent(e).replace(/[!*'()]/g,(e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`))},dC=(e,t)=>{const r=[],i={...t.endpointParams,...t.referenceRecord};let n=0;for(;n{if("string"==typeof e)return dC(e,r);if(e.fn)return uC(e,r);if(e.ref)return(({ref:e},t)=>({...t.endpointParams,...t.referenceRecord}[e]))(e,r);throw new oC(`'${t}': ${String(e)} is not a string, function or reference.`)},uC=({fn:e,argv:t},r)=>{const i=t.map((e=>["boolean","number"].includes(typeof e)?e:cC(e,"arg",r))),n=e.split(".");return n[0]in rC&&null!=n[1]?rC[n[0]][n[1]](...i):lC[e](...i)},pC=({assign:e,...t},r)=>{if(e&&e in r.referenceRecord)throw new oC(`'${e}' is already defined in Reference Record.`);const i=uC(t,r);return r.logger?.debug?.(`${iC} evaluateCondition: ${nC(t)} = ${nC(i)}`),{result:""===i||!!i,...null!=e&&{toAssign:{name:e,value:i}}}},hC=(e=[],t)=>{const r={};for(const i of e){const{result:e,toAssign:n}=pC(i,{...t,referenceRecord:{...t.referenceRecord,...r}});if(!e)return{result:e};n&&(r[n.name]=n.value,t.logger?.debug?.(`${iC} assign: ${n.name} := ${nC(n.value)}`))}return{result:!0,referenceRecord:r}},fC=(e,t)=>Object.entries(e).reduce(((e,[r,i])=>({...e,[r]:i.map((e=>{const i=cC(e,"Header value entry",t);if("string"!=typeof i)throw new oC(`Header '${r}' value '${i}' is not a string`);return i}))})),{}),mC=(e,t)=>{if(Array.isArray(e))return e.map((e=>mC(e,t)));switch(typeof e){case"string":return dC(e,t);case"object":if(null===e)throw new oC(`Unexpected endpoint property: ${e}`);return gC(e,t);case"boolean":return e;default:throw new oC("Unexpected endpoint property type: "+typeof e)}},gC=(e,t)=>Object.entries(e).reduce(((e,[r,i])=>({...e,[r]:mC(i,t)})),{}),yC=(e,t)=>{const r=cC(e,"Endpoint URL",t);if("string"==typeof r)try{return new URL(r)}catch(e){throw console.error(`Failed to construct URL with ${r}`,e),e}throw new oC("Endpoint URL must be a string, got "+typeof r)},vC=(e,t)=>{const{conditions:r,endpoint:i}=e,{result:n,referenceRecord:o}=hC(r,t);if(!n)return;const s={...t,referenceRecord:{...t.referenceRecord,...o}},{url:a,properties:l,headers:d}=i;return t.logger?.debug?.(`${iC} Resolving endpoint from template: ${nC(i)}`),{...null!=d&&{headers:fC(d,s)},...null!=l&&{properties:gC(l,s)},url:yC(a,s)}},bC=(e,t)=>{const{conditions:r,error:i}=e,{result:n,referenceRecord:o}=hC(r,t);if(n)throw new oC(cC(i,"Error",{...t,referenceRecord:{...t.referenceRecord,...o}}))},wC=(e,t)=>{const{conditions:r,rules:i}=e,{result:n,referenceRecord:o}=hC(r,t);if(n)return _C(i,{...t,referenceRecord:{...t.referenceRecord,...o}})},_C=(e,t)=>{for(const r of e)if("endpoint"===r.type){const e=vC(r,t);if(e)return e}else if("error"===r.type)bC(r,t);else{if("tree"!==r.type)throw new oC(`Unknown endpoint rule: ${r}`);{const e=wC(r,t);if(e)return e}}throw new oC("Rules evaluation failed")},xC=(e,t=!1)=>{if(t){for(const t of e.split("."))if(!xC(t))return!1;return!0}return!!tC(e)&&(!(e.length<3||e.length>63)&&(e===e.toLowerCase()&&!XB(e)))};let SC=JSON.parse('{"partitions":[{"id":"aws","outputs":{"dnsSuffix":"amazonaws.com","dualStackDnsSuffix":"api.aws","implicitGlobalRegion":"us-east-1","name":"aws","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^(us|eu|ap|sa|ca|me|af|il|mx)\\\\-\\\\w+\\\\-\\\\d+$","regions":{"af-south-1":{"description":"Africa (Cape Town)"},"ap-east-1":{"description":"Asia Pacific (Hong Kong)"},"ap-northeast-1":{"description":"Asia Pacific (Tokyo)"},"ap-northeast-2":{"description":"Asia Pacific (Seoul)"},"ap-northeast-3":{"description":"Asia Pacific (Osaka)"},"ap-south-1":{"description":"Asia Pacific (Mumbai)"},"ap-south-2":{"description":"Asia Pacific (Hyderabad)"},"ap-southeast-1":{"description":"Asia Pacific (Singapore)"},"ap-southeast-2":{"description":"Asia Pacific (Sydney)"},"ap-southeast-3":{"description":"Asia Pacific (Jakarta)"},"ap-southeast-4":{"description":"Asia Pacific (Melbourne)"},"ap-southeast-5":{"description":"Asia Pacific (Malaysia)"},"aws-global":{"description":"AWS Standard global region"},"ca-central-1":{"description":"Canada (Central)"},"ca-west-1":{"description":"Canada West (Calgary)"},"eu-central-1":{"description":"Europe (Frankfurt)"},"eu-central-2":{"description":"Europe (Zurich)"},"eu-north-1":{"description":"Europe (Stockholm)"},"eu-south-1":{"description":"Europe (Milan)"},"eu-south-2":{"description":"Europe (Spain)"},"eu-west-1":{"description":"Europe (Ireland)"},"eu-west-2":{"description":"Europe (London)"},"eu-west-3":{"description":"Europe (Paris)"},"il-central-1":{"description":"Israel (Tel Aviv)"},"me-central-1":{"description":"Middle East (UAE)"},"me-south-1":{"description":"Middle East (Bahrain)"},"sa-east-1":{"description":"South America (Sao Paulo)"},"us-east-1":{"description":"US East (N. Virginia)"},"us-east-2":{"description":"US East (Ohio)"},"us-west-1":{"description":"US West (N. California)"},"us-west-2":{"description":"US West (Oregon)"}}},{"id":"aws-cn","outputs":{"dnsSuffix":"amazonaws.com.cn","dualStackDnsSuffix":"api.amazonwebservices.com.cn","implicitGlobalRegion":"cn-northwest-1","name":"aws-cn","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^cn\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-cn-global":{"description":"AWS China global region"},"cn-north-1":{"description":"China (Beijing)"},"cn-northwest-1":{"description":"China (Ningxia)"}}},{"id":"aws-us-gov","outputs":{"dnsSuffix":"amazonaws.com","dualStackDnsSuffix":"api.aws","implicitGlobalRegion":"us-gov-west-1","name":"aws-us-gov","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^us\\\\-gov\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-us-gov-global":{"description":"AWS GovCloud (US) global region"},"us-gov-east-1":{"description":"AWS GovCloud (US-East)"},"us-gov-west-1":{"description":"AWS GovCloud (US-West)"}}},{"id":"aws-iso","outputs":{"dnsSuffix":"c2s.ic.gov","dualStackDnsSuffix":"c2s.ic.gov","implicitGlobalRegion":"us-iso-east-1","name":"aws-iso","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-iso\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-iso-global":{"description":"AWS ISO (US) global region"},"us-iso-east-1":{"description":"US ISO East"},"us-iso-west-1":{"description":"US ISO WEST"}}},{"id":"aws-iso-b","outputs":{"dnsSuffix":"sc2s.sgov.gov","dualStackDnsSuffix":"sc2s.sgov.gov","implicitGlobalRegion":"us-isob-east-1","name":"aws-iso-b","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-isob\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-iso-b-global":{"description":"AWS ISOB (US) global region"},"us-isob-east-1":{"description":"US ISOB East (Ohio)"}}},{"id":"aws-iso-e","outputs":{"dnsSuffix":"cloud.adc-e.uk","dualStackDnsSuffix":"cloud.adc-e.uk","implicitGlobalRegion":"eu-isoe-west-1","name":"aws-iso-e","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^eu\\\\-isoe\\\\-\\\\w+\\\\-\\\\d+$","regions":{"eu-isoe-west-1":{"description":"EU ISOE West"}}},{"id":"aws-iso-f","outputs":{"dnsSuffix":"csp.hci.ic.gov","dualStackDnsSuffix":"csp.hci.ic.gov","implicitGlobalRegion":"us-isof-south-1","name":"aws-iso-f","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-isof\\\\-\\\\w+\\\\-\\\\d+$","regions":{}}],"version":"1.1"}'),kC="";const EC={isVirtualHostableS3Bucket:xC,parseArn:e=>{const t=e.split(":");if(t.length<6)return null;const[r,i,n,o,s,...a]=t;if("arn"!==r||""===i||""===n||""===a.join(":"))return null;return{partition:i,service:n,region:o,accountId:s,resourceId:a.map((e=>e.split("/"))).flat()}},partition:e=>{const{partitions:t}=SC;for(const r of t){const{regions:t,outputs:i}=r;for(const[r,n]of Object.entries(t))if(r===e)return{...i,...n}}for(const r of t){const{regionRegex:t,outputs:i}=r;if(new RegExp(t).test(e))return{...i}}const r=t.find((e=>"aws"===e.id));if(!r)throw new Error("Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.");return{...r.outputs}}};rC.aws=EC;const TC=/\d{12}\.ddb/;const BC="user-agent",CC="x-amz-user-agent",IC=/[^\!\$\%\&\'\*\+\-\.\^\_\`\|\~\d\w]/g,AC=/[^\!\$\%\&\'\*\+\-\.\^\_\`\|\~\d\w\#]/g;const FC=e=>(t,r)=>async i=>{const{request:n}=i;if(!iS.isInstance(n))return t(i);const{headers:o}=n,s=r?.userAgent?.map(MC)||[],a=(await e.defaultUserAgentProvider()).map(MC);await async function(e,t,r){const i=r.request;if("rpc-v2-cbor"===i?.headers?.["smithy-protocol"]&&mS(e,"PROTOCOL_RPC_V2_CBOR","M"),"function"==typeof t.retryStrategy){const r=await t.retryStrategy();"function"==typeof r.acquireInitialRetryToken?r.constructor?.name?.includes("Adaptive")?mS(e,"RETRY_MODE_ADAPTIVE","F"):mS(e,"RETRY_MODE_STANDARD","E"):mS(e,"RETRY_MODE_LEGACY","D")}if("function"==typeof t.accountIdEndpointMode){const r=e.endpointV2;switch(String(r?.url?.hostname).match(TC)&&mS(e,"ACCOUNT_ID_ENDPOINT","O"),await(t.accountIdEndpointMode?.())){case"disabled":mS(e,"ACCOUNT_ID_MODE_DISABLED","Q");break;case"preferred":mS(e,"ACCOUNT_ID_MODE_PREFERRED","P");break;case"required":mS(e,"ACCOUNT_ID_MODE_REQUIRED","R")}}const n=e.__smithy_context?.selectedHttpAuthScheme?.identity;if(n?.$source){const t=n;t.accountId&&mS(e,"RESOLVED_ACCOUNT_ID","T");for(const[r,i]of Object.entries(t.$source??{}))mS(e,r,i)}}(r,e,i);const l=r;a.push(`m/${function(e){let t="";for(const r in e){const i=e[r];if(!(t.length+i.length+1<=1024))break;t.length?t+=","+i:t+=i}return t}(Object.assign({},r.__smithy_context?.features,l.__aws_sdk_context?.features))}`);const d=e?.customUserAgent?.map(MC)||[],c=await e.userAgentAppId();c&&a.push(MC([`app/${c}`]));const u=(kC?[kC]:[]).concat([...a,...s,...d]).join(" "),p=[...a.filter((e=>e.startsWith("aws-sdk-"))),...d].join(" ");return"browser"!==e.runtime?(p&&(o[CC]=o[CC]?`${o[BC]} ${p}`:p),o[BC]=u):o[CC]=u,t({...i,request:n})},MC=e=>{const t=e[0].split("/").map((e=>e.replace(IC,"-"))).join("/"),r=e[1]?.replace(AC,"-"),i=t.indexOf("/"),n=t.substring(0,i);let o=t.substring(i+1);return"api"===n&&(o=o.toLowerCase()),[n,o,r].filter((e=>e&&e.length>0)).reduce(((e,t,r)=>{switch(r){case 0:return t;case 1:return`${e}/${t}`;default:return`${e}#${t}`}}),"")},DC={name:"getUserAgentMiddleware",step:"build",priority:"low",tags:["SET_USER_AGENT","USER_AGENT"],override:!0},RC=e=>"string"==typeof e&&(e.startsWith("fips-")||e.endsWith("-fips")),PC=e=>RC(e)?["fips-aws-global","aws-fips"].includes(e)?"us-east-1":e.replace(/fips-(dkr-|prod-)?|-fips/,""):e,OC="content-length";const zC={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},NC=e=>({applyToStack:t=>{var r;t.add((r=e.bodyLengthChecker,e=>async t=>{const i=t.request;if(iS.isInstance(i)){const{body:e,headers:t}=i;if(e&&-1===Object.keys(t).map((e=>e.toLowerCase())).indexOf(OC))try{const t=r(e);i.headers={...i.headers,[OC]:String(t)}}catch(e){}}return e({...t,request:i})}),zC)}});const qC=e=>{let t,r=!1;e.credentials&&(r=!0,t=((e,t,r)=>{if(void 0===e)return;const i="function"!=typeof e?async()=>Promise.resolve(e):e;let n,o,s,a=!1;const l=async e=>{o||(o=i(e));try{n=await o,s=!0,a=!1}finally{o=void 0}return n};return void 0===t?async e=>(s&&!e?.forceRefresh||(n=await l(e)),n):async e=>(s&&!e?.forceRefresh||(n=await l(e)),a?n:r(n)?t(n)?(await l(e),n):n:(a=!0,n))})(e.credentials,PB,zB)),t||(t=e.credentialDefaultProvider?NB(e.credentialDefaultProvider(Object.assign({},e,{parentClientConfig:e}))):async()=>{throw new Error("`credentials` is missing")});const{signingEscapePath:i=!0,systemClockOffset:n=e.systemClockOffset||0,sha256:o}=e;let s;return s=e.signer?NB(e.signer):e.regionInfoProvider?()=>NB(e.region)().then((async t=>[await e.regionInfoProvider(t,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},t])).then((([r,n])=>{const{signingRegion:s,signingService:a}=r;e.signingRegion=e.signingRegion||s||n,e.signingName=e.signingName||a||e.serviceId;const l={...e,credentials:t,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||kT)(l)})):async r=>{const n=(r=Object.assign({},{name:"sigv4",signingName:e.signingName||e.defaultSigningName,signingRegion:await NB(e.region)(),properties:{}},r)).signingRegion,s=r.signingName;e.signingRegion=e.signingRegion||n,e.signingName=e.signingName||s||e.serviceId;const a={...e,credentials:t,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||kT)(a)},{...e,systemClockOffset:n,signingEscapePath:i,credentials:r?async()=>t().then((e=>{return r="CREDENTIALS_CODE",i="e",(t=e).$source||(t.$source={}),t.$source[r]=i,t;var t,r,i})):t,signer:s}};Error;const UC=null;class LC{constructor(e){this.sigv4Signer=new AT(e),this.signerOptions=e}async sign(e,t={}){if("*"===t.signingRegion){if("node"!==this.signerOptions.runtime)throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().sign(e,t)}return this.sigv4Signer.sign(e,t)}async signWithCredentials(e,t,r={}){if("*"===r.signingRegion){if("node"!==this.signerOptions.runtime)throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().signWithCredentials(e,t,r)}return this.sigv4Signer.signWithCredentials(e,t,r)}async presign(e,t={}){if("*"===t.signingRegion){if("node"!==this.signerOptions.runtime)throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().presign(e,t)}return this.sigv4Signer.presign(e,t)}async presignWithCredentials(e,t,r={}){if("*"===r.signingRegion)throw new Error("Method presignWithCredentials is not supported for [signingRegion=*].");return this.sigv4Signer.presignWithCredentials(e,t,r)}getSigv4aSigner(){if(!this.sigv4aSigner){let e=null;try{if(e=UC,"function"!=typeof e)throw new Error}catch(e){throw e.message=`${e.message}\nPlease check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. \nYou must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. \nFor more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`,e}this.sigv4aSigner=new e({...this.signerOptions,signingAlgorithm:1})}return this.sigv4aSigner}}const jC="required",HC="type",$C="conditions",GC="fn",WC="argv",KC="ref",VC="assign",JC="url",YC="properties",QC="backend",ZC="authSchemes",XC="disableDoubleEncoding",eI="signingName",tI="signingRegion",rI="headers",iI="signingRegionSet",nI=!0,oI="isSet",sI="booleanEquals",aI="error",lI="aws.partition",dI="stringEquals",cI="getAttr",uI="name",pI="substring",hI="bucketSuffix",fI="parseURL",mI="{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",gI="endpoint",yI="tree",vI="aws.isVirtualHostableS3Bucket",bI="{url#scheme}://{Bucket}.{url#authority}{url#path}",wI="not",_I="{url#scheme}://{url#authority}{url#path}",xI="hardwareType",SI="regionPrefix",kI="bucketAliasSuffix",EI="outpostId",TI="isValidHostLabel",BI="sigv4a",CI="s3-outposts",II="s3",AI="{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",FI="https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",MI="https://{Bucket}.s3.{partitionResult#dnsSuffix}",DI="aws.parseArn",RI="bucketArn",PI="arnType",OI="s3-object-lambda",zI="accesspoint",NI="accessPointName",qI="{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",UI="mrapPartition",LI="outpostType",jI="arnPrefix",HI="{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",$I="https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",GI="https://s3.{partitionResult#dnsSuffix}",WI={[jC]:!1,[HC]:"String"},KI={[jC]:!0,default:!1,[HC]:"Boolean"},VI={[jC]:!1,[HC]:"Boolean"},JI={[GC]:sI,[WC]:[{[KC]:"Accelerate"},!0]},YI={[GC]:sI,[WC]:[{[KC]:"UseFIPS"},!0]},QI={[GC]:sI,[WC]:[{[KC]:"UseDualStack"},!0]},ZI={[GC]:oI,[WC]:[{[KC]:"Endpoint"}]},XI={[GC]:lI,[WC]:[{[KC]:"Region"}],[VC]:"partitionResult"},eA={[GC]:dI,[WC]:[{[GC]:cI,[WC]:[{[KC]:"partitionResult"},uI]},"aws-cn"]},tA={[GC]:oI,[WC]:[{[KC]:"Bucket"}]},rA={[KC]:"Bucket"},iA={[GC]:fI,[WC]:[{[KC]:"Endpoint"}],[VC]:"url"},nA={[GC]:sI,[WC]:[{[GC]:cI,[WC]:[{[KC]:"url"},"isIp"]},!0]},oA={[KC]:"url"},sA={[GC]:"uriEncode",[WC]:[rA],[VC]:"uri_encoded_bucket"},aA={[QC]:"S3Express",[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:"s3express",[tI]:"{Region}"}]},lA={},dA={[GC]:vI,[WC]:[rA,!1]},cA={[aI]:"S3Express bucket name is not a valid virtual hostable name.",[HC]:aI},uA={[QC]:"S3Express",[ZC]:[{[XC]:!0,[uI]:"sigv4-s3express",[eI]:"s3express",[tI]:"{Region}"}]},pA={[GC]:oI,[WC]:[{[KC]:"UseS3ExpressControlEndpoint"}]},hA={[GC]:sI,[WC]:[{[KC]:"UseS3ExpressControlEndpoint"},!0]},fA={[GC]:wI,[WC]:[ZI]},mA={[aI]:"Unrecognized S3Express bucket name format.",[HC]:aI},gA={[GC]:wI,[WC]:[tA]},yA={[KC]:xI},vA={[$C]:[fA],[aI]:"Expected a endpoint to be specified but no endpoint was found",[HC]:aI},bA={[ZC]:[{[XC]:!0,[uI]:BI,[eI]:CI,[iI]:["*"]},{[XC]:!0,[uI]:"sigv4",[eI]:CI,[tI]:"{Region}"}]},wA={[GC]:sI,[WC]:[{[KC]:"ForcePathStyle"},!1]},_A={[KC]:"ForcePathStyle"},xA={[GC]:sI,[WC]:[{[KC]:"Accelerate"},!1]},SA={[GC]:dI,[WC]:[{[KC]:"Region"},"aws-global"]},kA={[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:II,[tI]:"us-east-1"}]},EA={[GC]:wI,[WC]:[SA]},TA={[GC]:sI,[WC]:[{[KC]:"UseGlobalEndpoint"},!0]},BA={[JC]:"https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",[YC]:{[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:II,[tI]:"{Region}"}]},[rI]:{}},CA={[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:II,[tI]:"{Region}"}]},IA={[GC]:sI,[WC]:[{[KC]:"UseGlobalEndpoint"},!1]},AA={[GC]:sI,[WC]:[{[KC]:"UseDualStack"},!1]},FA={[JC]:"https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},MA={[GC]:sI,[WC]:[{[KC]:"UseFIPS"},!1]},DA={[JC]:"https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},RA={[JC]:"https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},PA={[GC]:sI,[WC]:[{[GC]:cI,[WC]:[oA,"isIp"]},!1]},OA={[JC]:AI,[YC]:CA,[rI]:{}},zA={[JC]:bI,[YC]:CA,[rI]:{}},NA={[gI]:zA,[HC]:gI},qA={[JC]:FI,[YC]:CA,[rI]:{}},UA={[JC]:"https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},LA={[aI]:"Invalid region: region was not a valid DNS name.",[HC]:aI},jA={[KC]:RI},HA={[KC]:PI},$A={[GC]:cI,[WC]:[jA,"service"]},GA={[KC]:NI},WA={[$C]:[QI],[aI]:"S3 Object Lambda does not support Dual-stack",[HC]:aI},KA={[$C]:[JI],[aI]:"S3 Object Lambda does not support S3 Accelerate",[HC]:aI},VA={[$C]:[{[GC]:oI,[WC]:[{[KC]:"DisableAccessPoints"}]},{[GC]:sI,[WC]:[{[KC]:"DisableAccessPoints"},!0]}],[aI]:"Access points are not supported for this operation",[HC]:aI},JA={[$C]:[{[GC]:oI,[WC]:[{[KC]:"UseArnRegion"}]},{[GC]:sI,[WC]:[{[KC]:"UseArnRegion"},!1]},{[GC]:wI,[WC]:[{[GC]:dI,[WC]:[{[GC]:cI,[WC]:[jA,"region"]},"{Region}"]}]}],[aI]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",[HC]:aI},YA={[GC]:cI,[WC]:[{[KC]:"bucketPartition"},uI]},QA={[GC]:cI,[WC]:[jA,"accountId"]},ZA={[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:OI,[tI]:"{bucketArn#region}"}]},XA={[aI]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",[HC]:aI},eF={[aI]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",[HC]:aI},tF={[aI]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",[HC]:aI},rF={[aI]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",[HC]:aI},iF={[aI]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",[HC]:aI},nF={[aI]:"Invalid ARN: Expected a resource of the format `accesspoint:` but no name was provided",[HC]:aI},oF={[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:II,[tI]:"{bucketArn#region}"}]},sF={[ZC]:[{[XC]:!0,[uI]:BI,[eI]:CI,[iI]:["*"]},{[XC]:!0,[uI]:"sigv4",[eI]:CI,[tI]:"{bucketArn#region}"}]},aF={[GC]:DI,[WC]:[rA]},lF={[JC]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:CA,[rI]:{}},dF={[JC]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:CA,[rI]:{}},cF={[JC]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:CA,[rI]:{}},uF={[JC]:HI,[YC]:CA,[rI]:{}},pF={[JC]:"https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:CA,[rI]:{}},hF={[KC]:"UseObjectLambdaEndpoint"},fF={[ZC]:[{[XC]:!0,[uI]:"sigv4",[eI]:OI,[tI]:"{Region}"}]},mF={[JC]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},gF={[JC]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},yF={[JC]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},vF={[JC]:_I,[YC]:CA,[rI]:{}},bF={[JC]:"https://s3.{Region}.{partitionResult#dnsSuffix}",[YC]:CA,[rI]:{}},wF=[{[KC]:"Region"}],_F=[{[KC]:"Endpoint"}],xF=[rA],SF=[QI],kF=[JI],EF=[ZI,iA],TF=[{[GC]:oI,[WC]:[{[KC]:"DisableS3ExpressSessionAuth"}]},{[GC]:sI,[WC]:[{[KC]:"DisableS3ExpressSessionAuth"},!0]}],BF=[nA],CF=[sA],IF=[dA],AF=[YI],FF=[{[GC]:pI,[WC]:[rA,6,14,!0],[VC]:"s3expressAvailabilityZoneId"},{[GC]:pI,[WC]:[rA,14,16,!0],[VC]:"s3expressAvailabilityZoneDelim"},{[GC]:dI,[WC]:[{[KC]:"s3expressAvailabilityZoneDelim"},"--"]}],MF=[{[$C]:[YI],[gI]:{[JC]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",[YC]:aA,[rI]:{}},[HC]:gI},{[gI]:{[JC]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",[YC]:aA,[rI]:{}},[HC]:gI}],DF=[{[GC]:pI,[WC]:[rA,6,15,!0],[VC]:"s3expressAvailabilityZoneId"},{[GC]:pI,[WC]:[rA,15,17,!0],[VC]:"s3expressAvailabilityZoneDelim"},{[GC]:dI,[WC]:[{[KC]:"s3expressAvailabilityZoneDelim"},"--"]}],RF=[{[$C]:[YI],[gI]:{[JC]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",[YC]:uA,[rI]:{}},[HC]:gI},{[gI]:{[JC]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",[YC]:uA,[rI]:{}},[HC]:gI}],PF=[tA],OF=[{[GC]:TI,[WC]:[{[KC]:EI},!1]}],zF=[{[GC]:dI,[WC]:[{[KC]:SI},"beta"]}],NF=[XI],qF=[{[GC]:TI,[WC]:[{[KC]:"Region"},!1]}],UF=[{[GC]:dI,[WC]:[{[KC]:"Region"},"us-east-1"]}],LF=[{[GC]:dI,[WC]:[HA,zI]}],jF=[{[GC]:cI,[WC]:[jA,"resourceId[1]"],[VC]:NI},{[GC]:wI,[WC]:[{[GC]:dI,[WC]:[GA,""]}]}],HF=[jA,"resourceId[1]"],$F=[{[GC]:wI,[WC]:[{[GC]:dI,[WC]:[{[GC]:cI,[WC]:[jA,"region"]},""]}]}],GF=[{[GC]:wI,[WC]:[{[GC]:oI,[WC]:[{[GC]:cI,[WC]:[jA,"resourceId[2]"]}]}]}],WF=[jA,"resourceId[2]"],KF=[{[GC]:lI,[WC]:[{[GC]:cI,[WC]:[jA,"region"]}],[VC]:"bucketPartition"}],VF=[{[GC]:dI,[WC]:[YA,{[GC]:cI,[WC]:[{[KC]:"partitionResult"},uI]}]}],JF=[{[GC]:TI,[WC]:[{[GC]:cI,[WC]:[jA,"region"]},!0]}],YF=[{[GC]:TI,[WC]:[QA,!1]}],QF=[{[GC]:TI,[WC]:[GA,!1]}],ZF=[{[GC]:TI,[WC]:[{[KC]:"Region"},!0]}],XF={version:"1.0",parameters:{Bucket:WI,Region:WI,UseFIPS:KI,UseDualStack:KI,Endpoint:WI,ForcePathStyle:KI,Accelerate:KI,UseGlobalEndpoint:KI,UseObjectLambdaEndpoint:VI,Key:WI,Prefix:WI,CopySource:WI,DisableAccessPoints:VI,DisableMultiRegionAccessPoints:KI,UseArnRegion:VI,UseS3ExpressControlEndpoint:VI,DisableS3ExpressSessionAuth:VI},rules:[{[$C]:[{[GC]:oI,[WC]:wF}],rules:[{[$C]:[JI,YI],error:"Accelerate cannot be used with FIPS",[HC]:aI},{[$C]:[QI,ZI],error:"Cannot set dual-stack in combination with a custom endpoint.",[HC]:aI},{[$C]:[ZI,YI],error:"A custom endpoint cannot be combined with FIPS",[HC]:aI},{[$C]:[ZI,JI],error:"A custom endpoint cannot be combined with S3 Accelerate",[HC]:aI},{[$C]:[YI,XI,eA],error:"Partition does not support FIPS",[HC]:aI},{[$C]:[tA,{[GC]:pI,[WC]:[rA,0,6,nI],[VC]:hI},{[GC]:dI,[WC]:[{[KC]:hI},"--x-s3"]}],rules:[{[$C]:SF,error:"S3Express does not support Dual-stack.",[HC]:aI},{[$C]:kF,error:"S3Express does not support S3 Accelerate.",[HC]:aI},{[$C]:EF,rules:[{[$C]:TF,rules:[{[$C]:BF,rules:[{[$C]:CF,rules:[{endpoint:{[JC]:mI,[YC]:aA,[rI]:lA},[HC]:gI}],[HC]:yI}],[HC]:yI},{[$C]:IF,rules:[{endpoint:{[JC]:bI,[YC]:aA,[rI]:lA},[HC]:gI}],[HC]:yI},cA],[HC]:yI},{[$C]:BF,rules:[{[$C]:CF,rules:[{endpoint:{[JC]:mI,[YC]:uA,[rI]:lA},[HC]:gI}],[HC]:yI}],[HC]:yI},{[$C]:IF,rules:[{endpoint:{[JC]:bI,[YC]:uA,[rI]:lA},[HC]:gI}],[HC]:yI},cA],[HC]:yI},{[$C]:[pA,hA],rules:[{[$C]:[sA,fA],rules:[{[$C]:AF,endpoint:{[JC]:"https://s3express-control-fips.{Region}.amazonaws.com/{uri_encoded_bucket}",[YC]:aA,[rI]:lA},[HC]:gI},{endpoint:{[JC]:"https://s3express-control.{Region}.amazonaws.com/{uri_encoded_bucket}",[YC]:aA,[rI]:lA},[HC]:gI}],[HC]:yI}],[HC]:yI},{[$C]:IF,rules:[{[$C]:TF,rules:[{[$C]:FF,rules:MF,[HC]:yI},{[$C]:DF,rules:MF,[HC]:yI},mA],[HC]:yI},{[$C]:FF,rules:RF,[HC]:yI},{[$C]:DF,rules:RF,[HC]:yI},mA],[HC]:yI},cA],[HC]:yI},{[$C]:[gA,pA,hA],rules:[{[$C]:EF,endpoint:{[JC]:_I,[YC]:aA,[rI]:lA},[HC]:gI},{[$C]:AF,endpoint:{[JC]:"https://s3express-control-fips.{Region}.amazonaws.com",[YC]:aA,[rI]:lA},[HC]:gI},{endpoint:{[JC]:"https://s3express-control.{Region}.amazonaws.com",[YC]:aA,[rI]:lA},[HC]:gI}],[HC]:yI},{[$C]:[tA,{[GC]:pI,[WC]:[rA,49,50,nI],[VC]:xI},{[GC]:pI,[WC]:[rA,8,12,nI],[VC]:SI},{[GC]:pI,[WC]:[rA,0,7,nI],[VC]:kI},{[GC]:pI,[WC]:[rA,32,49,nI],[VC]:EI},{[GC]:lI,[WC]:wF,[VC]:"regionPartition"},{[GC]:dI,[WC]:[{[KC]:kI},"--op-s3"]}],rules:[{[$C]:OF,rules:[{[$C]:[{[GC]:dI,[WC]:[yA,"e"]}],rules:[{[$C]:zF,rules:[vA,{[$C]:EF,endpoint:{[JC]:"https://{Bucket}.ec2.{url#authority}",[YC]:bA,[rI]:lA},[HC]:gI}],[HC]:yI},{endpoint:{[JC]:"https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}",[YC]:bA,[rI]:lA},[HC]:gI}],[HC]:yI},{[$C]:[{[GC]:dI,[WC]:[yA,"o"]}],rules:[{[$C]:zF,rules:[vA,{[$C]:EF,endpoint:{[JC]:"https://{Bucket}.op-{outpostId}.{url#authority}",[YC]:bA,[rI]:lA},[HC]:gI}],[HC]:yI},{endpoint:{[JC]:"https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}",[YC]:bA,[rI]:lA},[HC]:gI}],[HC]:yI},{error:'Unrecognized hardware type: "Expected hardware type o or e but got {hardwareType}"',[HC]:aI}],[HC]:yI},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",[HC]:aI}],[HC]:yI},{[$C]:PF,rules:[{[$C]:[ZI,{[GC]:wI,[WC]:[{[GC]:oI,[WC]:[{[GC]:fI,[WC]:_F}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",[HC]:aI},{[$C]:[wA,dA],rules:[{[$C]:NF,rules:[{[$C]:qF,rules:[{[$C]:[JI,eA],error:"S3 Accelerate cannot be used in this region",[HC]:aI},{[$C]:[QI,YI,xA,fA,SA],endpoint:{[JC]:"https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[QI,YI,xA,fA,EA,TA],rules:[{endpoint:BA,[HC]:gI}],[HC]:yI},{[$C]:[QI,YI,xA,fA,EA,IA],endpoint:BA,[HC]:gI},{[$C]:[AA,YI,xA,fA,SA],endpoint:{[JC]:"https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,YI,xA,fA,EA,TA],rules:[{endpoint:FA,[HC]:gI}],[HC]:yI},{[$C]:[AA,YI,xA,fA,EA,IA],endpoint:FA,[HC]:gI},{[$C]:[QI,MA,JI,fA,SA],endpoint:{[JC]:"https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[QI,MA,JI,fA,EA,TA],rules:[{endpoint:DA,[HC]:gI}],[HC]:yI},{[$C]:[QI,MA,JI,fA,EA,IA],endpoint:DA,[HC]:gI},{[$C]:[QI,MA,xA,fA,SA],endpoint:{[JC]:"https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[QI,MA,xA,fA,EA,TA],rules:[{endpoint:RA,[HC]:gI}],[HC]:yI},{[$C]:[QI,MA,xA,fA,EA,IA],endpoint:RA,[HC]:gI},{[$C]:[AA,MA,xA,ZI,iA,nA,SA],endpoint:{[JC]:AI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,MA,xA,ZI,iA,PA,SA],endpoint:{[JC]:bI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,MA,xA,ZI,iA,nA,EA,TA],rules:[{[$C]:UF,endpoint:OA,[HC]:gI},{endpoint:OA,[HC]:gI}],[HC]:yI},{[$C]:[AA,MA,xA,ZI,iA,PA,EA,TA],rules:[{[$C]:UF,endpoint:zA,[HC]:gI},NA],[HC]:yI},{[$C]:[AA,MA,xA,ZI,iA,nA,EA,IA],endpoint:OA,[HC]:gI},{[$C]:[AA,MA,xA,ZI,iA,PA,EA,IA],endpoint:zA,[HC]:gI},{[$C]:[AA,MA,JI,fA,SA],endpoint:{[JC]:FI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,MA,JI,fA,EA,TA],rules:[{[$C]:UF,endpoint:qA,[HC]:gI},{endpoint:qA,[HC]:gI}],[HC]:yI},{[$C]:[AA,MA,JI,fA,EA,IA],endpoint:qA,[HC]:gI},{[$C]:[AA,MA,xA,fA,SA],endpoint:{[JC]:MI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,MA,xA,fA,EA,TA],rules:[{[$C]:UF,endpoint:{[JC]:MI,[YC]:CA,[rI]:lA},[HC]:gI},{endpoint:UA,[HC]:gI}],[HC]:yI},{[$C]:[AA,MA,xA,fA,EA,IA],endpoint:UA,[HC]:gI}],[HC]:yI},LA],[HC]:yI}],[HC]:yI},{[$C]:[ZI,iA,{[GC]:dI,[WC]:[{[GC]:cI,[WC]:[oA,"scheme"]},"http"]},{[GC]:vI,[WC]:[rA,nI]},wA,MA,AA,xA],rules:[{[$C]:NF,rules:[{[$C]:qF,rules:[NA],[HC]:yI},LA],[HC]:yI}],[HC]:yI},{[$C]:[wA,{[GC]:DI,[WC]:xF,[VC]:RI}],rules:[{[$C]:[{[GC]:cI,[WC]:[jA,"resourceId[0]"],[VC]:PI},{[GC]:wI,[WC]:[{[GC]:dI,[WC]:[HA,""]}]}],rules:[{[$C]:[{[GC]:dI,[WC]:[$A,OI]}],rules:[{[$C]:LF,rules:[{[$C]:jF,rules:[WA,KA,{[$C]:$F,rules:[VA,{[$C]:GF,rules:[JA,{[$C]:KF,rules:[{[$C]:NF,rules:[{[$C]:VF,rules:[{[$C]:JF,rules:[{[$C]:[{[GC]:dI,[WC]:[QA,""]}],error:"Invalid ARN: Missing account id",[HC]:aI},{[$C]:YF,rules:[{[$C]:QF,rules:[{[$C]:EF,endpoint:{[JC]:qI,[YC]:ZA,[rI]:lA},[HC]:gI},{[$C]:AF,endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:ZA,[rI]:lA},[HC]:gI},{endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:ZA,[rI]:lA},[HC]:gI}],[HC]:yI},XA],[HC]:yI},eF],[HC]:yI},tF],[HC]:yI},rF],[HC]:yI}],[HC]:yI}],[HC]:yI},iF],[HC]:yI},{error:"Invalid ARN: bucket ARN is missing a region",[HC]:aI}],[HC]:yI},nF],[HC]:yI},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",[HC]:aI}],[HC]:yI},{[$C]:LF,rules:[{[$C]:jF,rules:[{[$C]:$F,rules:[{[$C]:LF,rules:[{[$C]:$F,rules:[VA,{[$C]:GF,rules:[JA,{[$C]:KF,rules:[{[$C]:NF,rules:[{[$C]:[{[GC]:dI,[WC]:[YA,"{partitionResult#name}"]}],rules:[{[$C]:JF,rules:[{[$C]:[{[GC]:dI,[WC]:[$A,II]}],rules:[{[$C]:YF,rules:[{[$C]:QF,rules:[{[$C]:kF,error:"Access Points do not support S3 Accelerate",[HC]:aI},{[$C]:[YI,QI],endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:oF,[rI]:lA},[HC]:gI},{[$C]:[YI,AA],endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:oF,[rI]:lA},[HC]:gI},{[$C]:[MA,QI],endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:oF,[rI]:lA},[HC]:gI},{[$C]:[MA,AA,ZI,iA],endpoint:{[JC]:qI,[YC]:oF,[rI]:lA},[HC]:gI},{[$C]:[MA,AA],endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:oF,[rI]:lA},[HC]:gI}],[HC]:yI},XA],[HC]:yI},eF],[HC]:yI},{error:"Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}",[HC]:aI}],[HC]:yI},tF],[HC]:yI},rF],[HC]:yI}],[HC]:yI}],[HC]:yI},iF],[HC]:yI}],[HC]:yI}],[HC]:yI},{[$C]:[{[GC]:TI,[WC]:[GA,nI]}],rules:[{[$C]:SF,error:"S3 MRAP does not support dual-stack",[HC]:aI},{[$C]:AF,error:"S3 MRAP does not support FIPS",[HC]:aI},{[$C]:kF,error:"S3 MRAP does not support S3 Accelerate",[HC]:aI},{[$C]:[{[GC]:sI,[WC]:[{[KC]:"DisableMultiRegionAccessPoints"},nI]}],error:"Invalid configuration: Multi-Region Access Point ARNs are disabled.",[HC]:aI},{[$C]:[{[GC]:lI,[WC]:wF,[VC]:UI}],rules:[{[$C]:[{[GC]:dI,[WC]:[{[GC]:cI,[WC]:[{[KC]:UI},uI]},{[GC]:cI,[WC]:[jA,"partition"]}]}],rules:[{endpoint:{[JC]:"https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}",[YC]:{[ZC]:[{[XC]:nI,name:BI,[eI]:II,[iI]:["*"]}]},[rI]:lA},[HC]:gI}],[HC]:yI},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",[HC]:aI}],[HC]:yI}],[HC]:yI},{error:"Invalid Access Point Name",[HC]:aI}],[HC]:yI},nF],[HC]:yI},{[$C]:[{[GC]:dI,[WC]:[$A,CI]}],rules:[{[$C]:SF,error:"S3 Outposts does not support Dual-stack",[HC]:aI},{[$C]:AF,error:"S3 Outposts does not support FIPS",[HC]:aI},{[$C]:kF,error:"S3 Outposts does not support S3 Accelerate",[HC]:aI},{[$C]:[{[GC]:oI,[WC]:[{[GC]:cI,[WC]:[jA,"resourceId[4]"]}]}],error:"Invalid Arn: Outpost Access Point ARN contains sub resources",[HC]:aI},{[$C]:[{[GC]:cI,[WC]:HF,[VC]:EI}],rules:[{[$C]:OF,rules:[JA,{[$C]:KF,rules:[{[$C]:NF,rules:[{[$C]:VF,rules:[{[$C]:JF,rules:[{[$C]:YF,rules:[{[$C]:[{[GC]:cI,[WC]:WF,[VC]:LI}],rules:[{[$C]:[{[GC]:cI,[WC]:[jA,"resourceId[3]"],[VC]:NI}],rules:[{[$C]:[{[GC]:dI,[WC]:[{[KC]:LI},zI]}],rules:[{[$C]:EF,endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}",[YC]:sF,[rI]:lA},[HC]:gI},{endpoint:{[JC]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}",[YC]:sF,[rI]:lA},[HC]:gI}],[HC]:yI},{error:"Expected an outpost type `accesspoint`, found {outpostType}",[HC]:aI}],[HC]:yI},{error:"Invalid ARN: expected an access point name",[HC]:aI}],[HC]:yI},{error:"Invalid ARN: Expected a 4-component resource",[HC]:aI}],[HC]:yI},eF],[HC]:yI},tF],[HC]:yI},rF],[HC]:yI}],[HC]:yI}],[HC]:yI},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",[HC]:aI}],[HC]:yI},{error:"Invalid ARN: The Outpost Id was not set",[HC]:aI}],[HC]:yI},{error:"Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})",[HC]:aI}],[HC]:yI},{error:"Invalid ARN: No ARN type specified",[HC]:aI}],[HC]:yI},{[$C]:[{[GC]:pI,[WC]:[rA,0,4,!1],[VC]:jI},{[GC]:dI,[WC]:[{[KC]:jI},"arn:"]},{[GC]:wI,[WC]:[{[GC]:oI,[WC]:[aF]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",[HC]:aI},{[$C]:[{[GC]:sI,[WC]:[_A,nI]},aF],error:"Path-style addressing cannot be used with ARN buckets",[HC]:aI},{[$C]:CF,rules:[{[$C]:NF,rules:[{[$C]:[xA],rules:[{[$C]:[QI,fA,YI,SA],endpoint:{[JC]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[QI,fA,YI,EA,TA],rules:[{endpoint:lF,[HC]:gI}],[HC]:yI},{[$C]:[QI,fA,YI,EA,IA],endpoint:lF,[HC]:gI},{[$C]:[AA,fA,YI,SA],endpoint:{[JC]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,fA,YI,EA,TA],rules:[{endpoint:dF,[HC]:gI}],[HC]:yI},{[$C]:[AA,fA,YI,EA,IA],endpoint:dF,[HC]:gI},{[$C]:[QI,fA,MA,SA],endpoint:{[JC]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[QI,fA,MA,EA,TA],rules:[{endpoint:cF,[HC]:gI}],[HC]:yI},{[$C]:[QI,fA,MA,EA,IA],endpoint:cF,[HC]:gI},{[$C]:[AA,ZI,iA,MA,SA],endpoint:{[JC]:HI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,ZI,iA,MA,EA,TA],rules:[{[$C]:UF,endpoint:uF,[HC]:gI},{endpoint:uF,[HC]:gI}],[HC]:yI},{[$C]:[AA,ZI,iA,MA,EA,IA],endpoint:uF,[HC]:gI},{[$C]:[AA,fA,MA,SA],endpoint:{[JC]:$I,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[AA,fA,MA,EA,TA],rules:[{[$C]:UF,endpoint:{[JC]:$I,[YC]:CA,[rI]:lA},[HC]:gI},{endpoint:pF,[HC]:gI}],[HC]:yI},{[$C]:[AA,fA,MA,EA,IA],endpoint:pF,[HC]:gI}],[HC]:yI},{error:"Path-style addressing cannot be used with S3 Accelerate",[HC]:aI}],[HC]:yI}],[HC]:yI}],[HC]:yI},{[$C]:[{[GC]:oI,[WC]:[hF]},{[GC]:sI,[WC]:[hF,nI]}],rules:[{[$C]:NF,rules:[{[$C]:ZF,rules:[WA,KA,{[$C]:EF,endpoint:{[JC]:_I,[YC]:fF,[rI]:lA},[HC]:gI},{[$C]:AF,endpoint:{[JC]:"https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}",[YC]:fF,[rI]:lA},[HC]:gI},{endpoint:{[JC]:"https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}",[YC]:fF,[rI]:lA},[HC]:gI}],[HC]:yI},LA],[HC]:yI}],[HC]:yI},{[$C]:[gA],rules:[{[$C]:NF,rules:[{[$C]:ZF,rules:[{[$C]:[YI,QI,fA,SA],endpoint:{[JC]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[YI,QI,fA,EA,TA],rules:[{endpoint:mF,[HC]:gI}],[HC]:yI},{[$C]:[YI,QI,fA,EA,IA],endpoint:mF,[HC]:gI},{[$C]:[YI,AA,fA,SA],endpoint:{[JC]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[YI,AA,fA,EA,TA],rules:[{endpoint:gF,[HC]:gI}],[HC]:yI},{[$C]:[YI,AA,fA,EA,IA],endpoint:gF,[HC]:gI},{[$C]:[MA,QI,fA,SA],endpoint:{[JC]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[MA,QI,fA,EA,TA],rules:[{endpoint:yF,[HC]:gI}],[HC]:yI},{[$C]:[MA,QI,fA,EA,IA],endpoint:yF,[HC]:gI},{[$C]:[MA,AA,ZI,iA,SA],endpoint:{[JC]:_I,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[MA,AA,ZI,iA,EA,TA],rules:[{[$C]:UF,endpoint:vF,[HC]:gI},{endpoint:vF,[HC]:gI}],[HC]:yI},{[$C]:[MA,AA,ZI,iA,EA,IA],endpoint:vF,[HC]:gI},{[$C]:[MA,AA,fA,SA],endpoint:{[JC]:GI,[YC]:kA,[rI]:lA},[HC]:gI},{[$C]:[MA,AA,fA,EA,TA],rules:[{[$C]:UF,endpoint:{[JC]:GI,[YC]:CA,[rI]:lA},[HC]:gI},{endpoint:bF,[HC]:gI}],[HC]:yI},{[$C]:[MA,AA,fA,EA,IA],endpoint:bF,[HC]:gI}],[HC]:yI},LA],[HC]:yI}],[HC]:yI}],[HC]:yI},{error:"A region must be set when sending requests to S3.",[HC]:aI}]},eM=new class{constructor({size:e,params:t}){this.data=new Map,this.parameters=[],this.capacity=e??50,t&&(this.parameters=t)}get(e,t){const r=this.hash(e);if(!1===r)return t();if(!this.data.has(r)){if(this.data.size>this.capacity+10){const e=this.data.keys();let t=0;for(;;){const{value:r,done:i}=e.next();if(this.data.delete(r),i||++t>10)break}}this.data.set(r,t())}return this.data.get(r)}size(){return this.data.size}hash(e){let t="";const{parameters:r}=this;if(0===r.length)return!1;for(const i of r){const r=String(e[i]??"");if(r.includes("|;"))return!1;t+=r+"|;"}return t}}({size:50,params:["Accelerate","Bucket","DisableAccessPoints","DisableMultiRegionAccessPoints","DisableS3ExpressSessionAuth","Endpoint","ForcePathStyle","Region","UseArnRegion","UseDualStack","UseFIPS","UseGlobalEndpoint","UseObjectLambdaEndpoint","UseS3ExpressControlEndpoint"]}),tM=(e,t={})=>eM.get(e,(()=>((e,t)=>{const{endpointParams:r,logger:i}=t,{parameters:n,rules:o}=e;t.logger?.debug?.(`${iC} Initial EndpointParams: ${nC(r)}`);const s=Object.entries(n).filter((([,e])=>null!=e.default)).map((([e,t])=>[e,t.default]));if(s.length>0)for(const[e,t]of s)r[e]=r[e]??t;const a=Object.entries(n).filter((([,e])=>e.required)).map((([e])=>e));for(const e of a)if(null==r[e])throw new oC(`Missing required parameter: '${e}'`);const l=_C(o,{endpointParams:r,logger:i,referenceRecord:{}});return t.logger?.debug?.(`${iC} Resolved endpoint: ${nC(l)}`),l})(XF,{endpointParams:e,logger:t.logger})));rC.aws=EC;const rM=(iM=async(e,t,r)=>({operation:GS(t).operation,region:await WS(e.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}),async(e,t,r)=>{if(!r)throw new Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");const i=await iM(e,t,r),n=GS(t)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!n)throw new Error(`getEndpointParameterInstructions() is not defined on \`${t.commandName}\``);const o=await WT(r,{getEndpointParameterInstructions:n},e);return Object.assign(i,o)});var iM;function nM(e){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"s3",region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}function oM(e){return{schemeId:"aws.auth#sigv4a",signingProperties:{name:"s3",region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}const sM=((e,t,r)=>i=>{const n=e(i),o=n.properties?.authSchemes;if(!o)return t(i);const s=[];for(const e of o){const{name:t,properties:n={},...a}=e,l=t.toLowerCase();let d;if(t!==l&&console.warn(`HttpAuthScheme has been normalized with lowercasing: \`${t}\` to \`${l}\``),"sigv4a"===l){d="aws.auth#sigv4a";const e=o.find((e=>{const t=e.name.toLowerCase();return"sigv4a"!==t&&t.startsWith("sigv4")}));if(!UC&&e)continue}else{if(!l.startsWith("sigv4"))throw new Error(`Unknown HttpAuthScheme found in \`@smithy.rules#endpointRuleSet\`: \`${l}\``);d="aws.auth#sigv4"}const c=r[d];if(!c)throw new Error(`Could not find HttpAuthOption create function for \`${d}\``);const u=c(i);u.schemeId=d,u.signingProperties={...u.signingProperties||{},...a,...n},s.push(u)}return s})(tM,(e=>{const t=[];return e.operation,t.push(nM(e)),t.push(oM(e)),t}),{"aws.auth#sigv4":nM,"aws.auth#sigv4a":oM}),aM=e=>{const t=(e=>(e.sigv4aSigningRegionSet=NB(e.sigv4aSigningRegionSet),e))(qC(e));return{...t}},lM={ForcePathStyle:{type:"clientContextParams",name:"forcePathStyle"},UseArnRegion:{type:"clientContextParams",name:"useArnRegion"},DisableMultiRegionAccessPoints:{type:"clientContextParams",name:"disableMultiregionAccessPoints"},Accelerate:{type:"clientContextParams",name:"useAccelerateEndpoint"},DisableS3ExpressSessionAuth:{type:"clientContextParams",name:"disableS3ExpressSessionAuth"},UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class dM extends vE{constructor(e){super(e),Object.setPrototypeOf(this,dM.prototype)}}class cM extends dM{constructor(e){super({name:"NoSuchUpload",$fault:"client",...e}),this.name="NoSuchUpload",this.$fault="client",Object.setPrototypeOf(this,cM.prototype)}}class uM extends dM{constructor(e){super({name:"ObjectNotInActiveTierError",$fault:"client",...e}),this.name="ObjectNotInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,uM.prototype)}}class pM extends dM{constructor(e){super({name:"BucketAlreadyExists",$fault:"client",...e}),this.name="BucketAlreadyExists",this.$fault="client",Object.setPrototypeOf(this,pM.prototype)}}class hM extends dM{constructor(e){super({name:"BucketAlreadyOwnedByYou",$fault:"client",...e}),this.name="BucketAlreadyOwnedByYou",this.$fault="client",Object.setPrototypeOf(this,hM.prototype)}}class fM extends dM{constructor(e){super({name:"NoSuchBucket",$fault:"client",...e}),this.name="NoSuchBucket",this.$fault="client",Object.setPrototypeOf(this,fM.prototype)}}var mM;!function(e){e.visit=(e,t)=>void 0!==e.Prefix?t.Prefix(e.Prefix):void 0!==e.Tag?t.Tag(e.Tag):void 0!==e.And?t.And(e.And):t._(e.$unknown[0],e.$unknown[1])}(mM||(mM={}));var gM;!function(e){e.visit=(e,t)=>void 0!==e.Prefix?t.Prefix(e.Prefix):void 0!==e.Tag?t.Tag(e.Tag):void 0!==e.AccessPointArn?t.AccessPointArn(e.AccessPointArn):void 0!==e.And?t.And(e.And):t._(e.$unknown[0],e.$unknown[1])}(gM||(gM={}));class yM extends dM{constructor(e){super({name:"InvalidObjectState",$fault:"client",...e}),this.name="InvalidObjectState",this.$fault="client",Object.setPrototypeOf(this,yM.prototype),this.StorageClass=e.StorageClass,this.AccessTier=e.AccessTier}}class vM extends dM{constructor(e){super({name:"NoSuchKey",$fault:"client",...e}),this.name="NoSuchKey",this.$fault="client",Object.setPrototypeOf(this,vM.prototype)}}class bM extends dM{constructor(e){super({name:"NotFound",$fault:"client",...e}),this.name="NotFound",this.$fault="client",Object.setPrototypeOf(this,bM.prototype)}}const wM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk}}),_M=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk}}),xM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk}}),SM=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk},...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk}}),kM=e=>({...e,...e.SecretAccessKey&&{SecretAccessKey:Fk},...e.SessionToken&&{SessionToken:Fk}}),EM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk},...e.Credentials&&{Credentials:kM(e.Credentials)}}),TM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk}}),BM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk}}),CM=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk}}),IM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk}}),AM=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk}});var FM=__webpack_require__(86454);const MM=(e,t)=>((e,t)=>Ck(e,t).then((e=>t.utf8Encoder(e))))(e,t).then((e=>{if(e.length){const t=new FM.XMLParser({attributeNamePrefix:"",htmlEntities:!0,ignoreAttributes:!1,ignoreDeclaration:!0,parseTagValue:!1,trimValues:!1,tagValueProcessor:(e,t)=>""===t.trim()&&t.includes("\n")?"":void 0});let r;t.addEntity("#xD","\r"),t.addEntity("#10","\n");try{r=t.parse(e,!0)}catch(t){throw t&&"object"==typeof t&&Object.defineProperty(t,"$responseBodyText",{value:e}),t}const i="#text",n=Object.keys(r)[0],o=r[n];return o[i]&&(o[n]=o[i],delete o[i]),IE(o)}return{}})),DM=async(e,t)=>{const r=await MM(e,t);return r.Error&&(r.Error.message=r.Error.message??r.Error.Message),r};class RM{constructor(e){this.value=e}toString(){return(""+this.value).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">").replace(/\r/g," ").replace(/\n/g," ").replace(/\u0085/g,"…").replace(/\u2028/,"
")}}class PM{static of(e,t,r){const i=new PM(e);return void 0!==t&&i.addChildNode(new RM(t)),void 0!==r&&i.withName(r),i}constructor(e,t=[]){this.name=e,this.children=t,this.attributes={}}withName(e){return this.name=e,this}addAttribute(e,t){return this.attributes[e]=t,this}addChildNode(e){return this.children.push(e),this}removeAttribute(e){return delete this.attributes[e],this}n(e){return this.name=e,this}c(e){return this.children.push(e),this}a(e,t){return null!=t&&(this.attributes[e]=t),this}cc(e,t,r=t){if(null!=e[t]){const i=PM.of(t,e[t]).withName(r);this.c(i)}}l(e,t,r,i){if(null!=e[t]){i().map((e=>{e.withName(r),this.c(e)}))}}lc(e,t,r,i){if(null!=e[t]){const e=i(),t=new PM(r);e.map((e=>{t.c(e)})),this.c(t)}}toString(){const e=Boolean(this.children.length);let t=`<${this.name}`;const r=this.attributes;for(const e of Object.keys(r)){const n=r[e];null!=n&&(t+=` ${e}="${i=""+n,i.replace(/&/g,"&").replace(//g,">").replace(/"/g,""")}"`)}var i;return t+(e?`>${this.children.map((e=>e.toString())).join("")}`:"/>")}}class OM extends dM{constructor(e){super({name:"ObjectAlreadyInActiveTierError",$fault:"client",...e}),this.name="ObjectAlreadyInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,OM.prototype)}}var zM;!function(e){e.visit=(e,t)=>void 0!==e.Records?t.Records(e.Records):void 0!==e.Stats?t.Stats(e.Stats):void 0!==e.Progress?t.Progress(e.Progress):void 0!==e.Cont?t.Cont(e.Cont):void 0!==e.End?t.End(e.End):t._(e.$unknown[0],e.$unknown[1])}(zM||(zM={}));const NM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk}}),qM=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk},...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk},...e.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Fk}}),UM=e=>({...e,...e.SSEKMSKeyId&&{SSEKMSKeyId:Fk}}),LM=e=>({...e,...e.SSECustomerKey&&{SSECustomerKey:Fk}}),jM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[HO]:e[oP],[IO]:e[fR]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[nz]:[,"AbortMultipartUpload"],[pO]:[,jk(e[EP],"UploadId")]});return r.m("DELETE").h(i).q(n).b(undefined),r.build()},HM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{"content-type":"application/xml",[_O]:e[KD],[xO]:e[VD],[kO]:e[oR],[EO]:e[sR],[HO]:e[oP],[IO]:e[fR],[KP]:e[BR],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[pO]:[,jk(e[EP],"UploadId")]});let o,s;return void 0!==e.MultipartUpload&&(s=xD(e.MultipartUpload,t),s=s.n("CompleteMultipartUpload"),o=fO,s.a("xmlns","http://s3.amazonaws.com/doc/2006-03-01/"),o+=s.toString()),r.m("POST").h(i).q(n).b(o),r.build()},$M=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[mO]:e[RD],[AP]:e[WD],[FP]:e[JD],[MP]:e[YD],[DP]:e[QD],[zP]:e[aR],[UP]:[()=>AE(e[hR]),()=>eE(e[hR]).toString()],[AO]:e[wR],[FO]:e[_R],[MO]:e[xR],[DO]:e[SR],[KO]:e[hP],[GO]:e[uP],[iz]:e[CP],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP],[VO]:e[vP],[YO]:e[yP],[JO]:[()=>AE(e[HD]),()=>e[HD].toString()],[HO]:e[oP],[ez]:e[_P],[NO]:e[HR],[qO]:[()=>AE(e[$R]),()=>qE(e[$R]).toString()],[zO]:e[jR],[IO]:e[fR],[wO]:e[GD],...void 0!==e.Metadata&&Object.keys(e.Metadata).reduce(((t,r)=>(t[`x-amz-meta-${r.toLowerCase()}`]=e.Metadata[r],t)),{})});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[uO]:[,""]});return r.m("POST").h(i).q(n).b(undefined),r.build()},GM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[TO]:e[pP],[KO]:e[hP],[VO]:e[vP],[YO]:e[yP],[JO]:[()=>AE(e[HD]),()=>e[HD].toString()]});r.bp("/"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1);const n=DE({[lO]:[,""]});return r.m("GET").h(i).q(n).b(undefined),r.build()},WM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[RO]:e[PR],[HO]:e[oP],[bO]:[()=>AE(e[jD]),()=>e[jD].toString()],[IO]:e[fR]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[nz]:[,"DeleteObject"],[hO]:[,e[TP]]});return r.m("DELETE").h(i).q(n).b(undefined),r.build()},KM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[GP]:e[ER],[WP]:[()=>AE(e[TR]),()=>eE(e[TR]).toString()],[KP]:e[BR],[VP]:[()=>AE(e[AR]),()=>eE(e[AR]).toString()],[tO]:e[YR],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP],[HO]:e[oP],[IO]:e[fR],[SO]:e[XD]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[nz]:[,"GetObject"],[rO]:[,e[ZR]],[iO]:[,e[XR]],[nO]:[,e[eP]],[oO]:[,e[tP]],[sO]:[,e[rP]],[aO]:[()=>void 0!==e.ResponseExpires,()=>eE(e[iP]).toString()],[hO]:[,e[TP]],[XP]:[()=>void 0!==e.PartNumber,()=>e[VR].toString()]});return r.m("GET").h(i).q(n).b(undefined),r.build()},VM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[GP]:e[ER],[WP]:[()=>AE(e[TR]),()=>eE(e[TR]).toString()],[KP]:e[BR],[VP]:[()=>AE(e[AR]),()=>eE(e[AR]).toString()],[tO]:e[YR],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP],[HO]:e[oP],[IO]:e[fR],[SO]:e[XD]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[rO]:[,e[ZR]],[iO]:[,e[XR]],[nO]:[,e[eP]],[oO]:[,e[tP]],[sO]:[,e[rP]],[aO]:[()=>void 0!==e.ResponseExpires,()=>eE(e[iP]).toString()],[hO]:[,e[TP]],[XP]:[()=>void 0!==e.PartNumber,()=>e[VR].toString()]});return r.m("HEAD").h(i).q(n).b(undefined),r.build()},JM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[HO]:e[oP],[IO]:e[fR],[UO]:[()=>AE(e[GR]),()=>(e[GR]||[]).map(NE).join(", ")]});r.bp("/"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1);const n=DE({[YP]:[,"2"],[qP]:[,e[cR]],[LP]:[,e[gR]],[ZP]:[()=>void 0!==e.MaxKeys,()=>e[OR].toString()],[eO]:[,e[WR]],[NP]:[,e[lR]],[$P]:[()=>void 0!==e.FetchOwner,()=>e[bR].toString()],[dO]:[,e[dP]]});return r.m("GET").h(i).q(n).b(undefined),r.build()},YM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{[zP]:e[aR]||"application/octet-stream",[mO]:e[RD],[AP]:e[WD],[FP]:e[JD],[MP]:e[YD],[DP]:e[QD],[RP]:[()=>AE(e[ZD]),()=>e[ZD].toString()],[PP]:e[eR],[WO]:e[GD],[_O]:e[KD],[xO]:e[VD],[kO]:e[oR],[EO]:e[sR],[UP]:[()=>AE(e[hR]),()=>eE(e[hR]).toString()],[KP]:e[BR],[AO]:e[wR],[FO]:e[_R],[MO]:e[xR],[DO]:e[SR],[KO]:e[hP],[GO]:e[uP],[iz]:e[CP],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP],[VO]:e[vP],[YO]:e[yP],[JO]:[()=>AE(e[HD]),()=>e[HD].toString()],[HO]:e[oP],[ez]:e[_P],[NO]:e[HR],[qO]:[()=>AE(e[$R]),()=>qE(e[$R]).toString()],[zO]:e[jR],[IO]:e[fR],...void 0!==e.Metadata&&Object.keys(e.Metadata).reduce(((t,r)=>(t[`x-amz-meta-${r.toLowerCase()}`]=e.Metadata[r],t)),{})});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[nz]:[,"PutObject"]});let o,s;return void 0!==e.Body&&(s=e.Body,o=s),r.m("PUT").h(i).q(n).b(o),r.build()},QM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{"content-type":"application/xml",[PP]:e[eR],[WO]:e[GD],[IO]:e[fR],[HO]:e[oP]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[cO]:[,""],[hO]:[,e[TP]]});let o,s;return void 0!==e.Tagging&&(s=ED(e.Tagging,t),o=fO,s.a("xmlns","http://s3.amazonaws.com/doc/2006-03-01/"),o+=s.toString()),r.m("PUT").h(i).q(n).b(o),r.build()},ZM=async(e,t)=>{const r=qB(e,t),i=DE({},AE,{"content-type":"application/octet-stream",[RP]:[()=>AE(e[ZD]),()=>e[ZD].toString()],[PP]:e[eR],[WO]:e[GD],[_O]:e[KD],[xO]:e[VD],[kO]:e[oR],[EO]:e[sR],[QO]:e[fP],[ZO]:e[mP],[XO]:e[gP],[HO]:e[oP],[IO]:e[fR]});r.bp("/{Key+}"),r.p("Bucket",(()=>e.Bucket),"{Bucket}",!1),r.p("Key",(()=>e.Key),"{Key+}",!0);const n=DE({[nz]:[,"UploadPart"],[XP]:[null!=jk(e.PartNumber,"PartNumber"),()=>e[VR].toString()],[pO]:[,jk(e[EP],"UploadId")]});let o,s;return void 0!==e.Body&&(s=e.Body,o=s),r.m("PUT").h(i).q(n).b(o),r.build()},XM=async(e,t)=>{if(204!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[QR]:[,e.headers[jO]]});return await Ck(e.body,t),r},eD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[vR]:[,e.headers[CO]],[hP]:[,e.headers[KO]],[TP]:[,e.headers[rz]],[vP]:[,e.headers[VO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[QR]:[,e.headers[jO]]}),i=jk(Hk(await MM(e.body,t)),"body");return null!=i[LD]&&(r[LD]=$k(i[LD])),null!=i[KD]&&(r[KD]=$k(i[KD])),null!=i[VD]&&(r[VD]=$k(i[VD])),null!=i[oR]&&(r[oR]=$k(i[oR])),null!=i[sR]&&(r[sR]=$k(i[sR])),null!=i[yR]&&(r[yR]=$k(i[yR])),null!=i[FR]&&(r[FR]=$k(i[FR])),null!=i[DR]&&(r[DR]=$k(i[DR])),r},tD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[PD]:[()=>void 0!==e.headers[gO],()=>jk(sE(e.headers[gO]))],[ND]:[,e.headers[yO]],[hP]:[,e.headers[KO]],[fP]:[,e.headers[QO]],[gP]:[,e.headers[XO]],[vP]:[,e.headers[VO]],[yP]:[,e.headers[YO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[QR]:[,e.headers[jO]],[GD]:[,e.headers[wO]]}),i=jk(Hk(await MM(e.body,t)),"body");return null!=i[LD]&&(r[LD]=$k(i[LD])),null!=i[FR]&&(r[FR]=$k(i[FR])),null!=i[EP]&&(r[EP]=$k(i[EP])),r},rD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[hP]:[,e.headers[KO]],[vP]:[,e.headers[VO]],[yP]:[,e.headers[YO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])]}),i=jk(Hk(await MM(e.body,t)),"body");return null!=i[$D]&&(r[$D]=MD(i[$D],t)),r},iD=async(e,t)=>{if(204!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[uR]:[()=>void 0!==e.headers[BO],()=>Mk(e.headers[BO])],[TP]:[,e.headers[rz]],[QR]:[,e.headers[jO]]});return await Ck(e.body,t),r},nD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[uR]:[()=>void 0!==e.headers[BO],()=>Mk(e.headers[BO])],[zD]:[,e.headers[IP]],[vR]:[,e.headers[CO]],[lP]:[,e.headers[LO]],[RR]:[()=>void 0!==e.headers[JP],()=>jk(sE(e.headers[JP]))],[ZD]:[()=>void 0!==e.headers[RP],()=>Kk(e.headers[RP])],[yR]:[,e.headers[jP]],[KD]:[,e.headers[_O]],[VD]:[,e.headers[xO]],[oR]:[,e.headers[kO]],[sR]:[,e.headers[EO]],[zR]:[()=>void 0!==e.headers[PO],()=>Vk(e.headers[PO])],[TP]:[,e.headers[rz]],[WD]:[,e.headers[AP]],[JD]:[,e.headers[FP]],[YD]:[,e.headers[MP]],[QD]:[,e.headers[DP]],[nR]:[,e.headers[OP]],[aR]:[,e.headers[zP]],[hR]:[()=>void 0!==e.headers[UP],()=>jk(sE(e.headers[UP]))],[mR]:[,e.headers[HP]],[CP]:[,e.headers[iz]],[hP]:[,e.headers[KO]],[fP]:[,e.headers[QO]],[gP]:[,e.headers[XO]],[vP]:[,e.headers[VO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[uP]:[,e.headers[GO]],[QR]:[,e.headers[jO]],[sP]:[,e.headers[$O]],[KR]:[()=>void 0!==e.headers[OO],()=>Vk(e.headers[OO])],[xP]:[()=>void 0!==e.headers[tz],()=>Vk(e.headers[tz])],[HR]:[,e.headers[NO]],[$R]:[()=>void 0!==e.headers[qO],()=>jk(rE(e.headers[qO]))],[jR]:[,e.headers[zO]],Metadata:[,Object.keys(e.headers).filter((e=>e.startsWith("x-amz-meta-"))).reduce(((t,r)=>(t[r.substring(11)]=e.headers[r],t)),{})]}),i=e.body;return t.sdkStreamMixin(i),r.Body=i,r},oD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[uR]:[()=>void 0!==e.headers[BO],()=>Mk(e.headers[BO])],[zD]:[,e.headers[IP]],[vR]:[,e.headers[CO]],[lP]:[,e.headers[LO]],[qD]:[,e.headers[vO]],[RR]:[()=>void 0!==e.headers[JP],()=>jk(sE(e.headers[JP]))],[ZD]:[()=>void 0!==e.headers[RP],()=>Kk(e.headers[RP])],[KD]:[,e.headers[_O]],[VD]:[,e.headers[xO]],[oR]:[,e.headers[kO]],[sR]:[,e.headers[EO]],[yR]:[,e.headers[jP]],[zR]:[()=>void 0!==e.headers[PO],()=>Vk(e.headers[PO])],[TP]:[,e.headers[rz]],[WD]:[,e.headers[AP]],[JD]:[,e.headers[FP]],[YD]:[,e.headers[MP]],[QD]:[,e.headers[DP]],[aR]:[,e.headers[zP]],[hR]:[()=>void 0!==e.headers[UP],()=>jk(sE(e.headers[UP]))],[mR]:[,e.headers[HP]],[CP]:[,e.headers[iz]],[hP]:[,e.headers[KO]],[fP]:[,e.headers[QO]],[gP]:[,e.headers[XO]],[vP]:[,e.headers[VO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[uP]:[,e.headers[GO]],[QR]:[,e.headers[jO]],[sP]:[,e.headers[$O]],[KR]:[()=>void 0!==e.headers[OO],()=>Vk(e.headers[OO])],[HR]:[,e.headers[NO]],[$R]:[()=>void 0!==e.headers[qO],()=>jk(rE(e.headers[qO]))],[jR]:[,e.headers[zO]],Metadata:[,Object.keys(e.headers).filter((e=>e.startsWith("x-amz-meta-"))).reduce(((t,r)=>(t[r.substring(11)]=e.headers[r],t)),{})]});return await Ck(e.body,t),r},sD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[QR]:[,e.headers[jO]]}),i=jk(Hk(await MM(e.body,t)),"body");return""===i.CommonPrefixes?r[rR]=[]:null!=i[rR]&&(r[rR]=CD(CE(i[rR]),t)),""===i.Contents?r[dR]=[]:null!=i[dR]&&(r[dR]=ID(CE(i[dR]),t)),null!=i[lR]&&(r[lR]=$k(i[lR])),null!=i[cR]&&(r[cR]=$k(i[cR])),null!=i[gR]&&(r[gR]=$k(i[gR])),null!=i[IR]&&(r[IR]=Mk(i[IR])),null!=i[MR]&&(r[MR]=Vk(i[MR])),null!=i[OR]&&(r[OR]=Vk(i[OR])),null!=i[NR]&&(r[NR]=$k(i[NR])),null!=i[qR]&&(r[qR]=$k(i[qR])),null!=i[WR]&&(r[WR]=$k(i[WR])),null!=i[dP]&&(r[dP]=$k(i[dP])),r},aD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[vR]:[,e.headers[CO]],[yR]:[,e.headers[jP]],[KD]:[,e.headers[_O]],[VD]:[,e.headers[xO]],[oR]:[,e.headers[kO]],[sR]:[,e.headers[EO]],[hP]:[,e.headers[KO]],[TP]:[,e.headers[rz]],[fP]:[,e.headers[QO]],[gP]:[,e.headers[XO]],[vP]:[,e.headers[VO]],[yP]:[,e.headers[YO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[QR]:[,e.headers[jO]]});return await Ck(e.body,t),r},lD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[TP]:[,e.headers[rz]]});return await Ck(e.body,t),r},dD=async(e,t)=>{if(200!==e.statusCode&&e.statusCode>=300)return cD(e,t);const r=DE({$metadata:DD(e),[hP]:[,e.headers[KO]],[yR]:[,e.headers[jP]],[KD]:[,e.headers[_O]],[VD]:[,e.headers[xO]],[oR]:[,e.headers[kO]],[sR]:[,e.headers[EO]],[fP]:[,e.headers[QO]],[gP]:[,e.headers[XO]],[vP]:[,e.headers[VO]],[HD]:[()=>void 0!==e.headers[JO],()=>Mk(e.headers[JO])],[QR]:[,e.headers[jO]]});return await Ck(e.body,t),r},cD=async(e,t)=>{const r={...e,body:await DM(e.body,t)},i=((e,t)=>void 0!==t?.Error?.Code?t.Error.Code:void 0!==t?.Code?t.Code:404==e.statusCode?"NotFound":void 0)(e,r.body);switch(i){case"NoSuchUpload":case"com.amazonaws.s3#NoSuchUpload":throw await vD(r,t);case"ObjectNotInActiveTierError":case"com.amazonaws.s3#ObjectNotInActiveTierError":throw await _D(r,t);case"BucketAlreadyExists":case"com.amazonaws.s3#BucketAlreadyExists":throw await hD(r,t);case"BucketAlreadyOwnedByYou":case"com.amazonaws.s3#BucketAlreadyOwnedByYou":throw await fD(r,t);case"NoSuchBucket":case"com.amazonaws.s3#NoSuchBucket":throw await gD(r,t);case"InvalidObjectState":case"com.amazonaws.s3#InvalidObjectState":throw await mD(r,t);case"NoSuchKey":case"com.amazonaws.s3#NoSuchKey":throw await yD(r,t);case"NotFound":case"com.amazonaws.s3#NotFound":throw await bD(r,t);case"ObjectAlreadyInActiveTierError":case"com.amazonaws.s3#ObjectAlreadyInActiveTierError":throw await wD(r,t);default:const n=r.body;return uD({output:e,parsedBody:n,errorCode:i})}},uD=(pD=dM,({output:e,parsedBody:t,errorCode:r})=>{(({output:e,parsedBody:t,exceptionCtor:r,errorCode:i})=>{const n=wE(e),o=n.httpStatusCode?n.httpStatusCode+"":void 0,s=new r({name:t?.code||t?.Code||i||o||"UnknownError",$fault:"client",$metadata:n});throw bE(s,t)})({output:e,parsedBody:t,exceptionCtor:pD,errorCode:r})});var pD;const hD=async(e,t)=>{const r=DE({}),i=(e.body,new pM({$metadata:DD(e),...r}));return bE(i,e.body)},fD=async(e,t)=>{const r=DE({}),i=(e.body,new hM({$metadata:DD(e),...r}));return bE(i,e.body)},mD=async(e,t)=>{const r=DE({}),i=e.body;null!=i[UD]&&(r[UD]=$k(i[UD])),null!=i[uP]&&(r[uP]=$k(i[uP]));const n=new yM({$metadata:DD(e),...r});return bE(n,e.body)},gD=async(e,t)=>{const r=DE({}),i=(e.body,new fM({$metadata:DD(e),...r}));return bE(i,e.body)},yD=async(e,t)=>{const r=DE({}),i=(e.body,new vM({$metadata:DD(e),...r}));return bE(i,e.body)},vD=async(e,t)=>{const r=DE({}),i=(e.body,new cM({$metadata:DD(e),...r}));return bE(i,e.body)},bD=async(e,t)=>{const r=DE({}),i=(e.body,new bM({$metadata:DD(e),...r}));return bE(i,e.body)},wD=async(e,t)=>{const r=DE({}),i=(e.body,new OM({$metadata:DD(e),...r}));return bE(i,e.body)},_D=async(e,t)=>{const r=DE({}),i=(e.body,new uM({$metadata:DD(e),...r}));return bE(i,e.body)},xD=(e,t)=>{const r=new PM(tR);return r.l(e,"Parts","Part",(()=>SD(e[JR],t))),r},SD=(e,t)=>e.filter((e=>null!=e)).map((e=>{const t=(e=>{const t=new PM(iR);return t.cc(e,yR),t.cc(e,KD),t.cc(e,VD),t.cc(e,oR),t.cc(e,sR),null!=e[VR]&&t.c(PM.of(VR,String(e[VR])).n(VR)),t})(e);return t.n(QP)})),kD=(e,t)=>{const r=new PM(kP);return null!=e[FR]&&r.c(PM.of(LR,e[FR]).n(FR)),r.cc(e,BP),r},ED=(e,t)=>{const r=new PM(_P);return r.lc(e,"TagSet","TagSet",(()=>TD(e[SP],t))),r},TD=(e,t)=>e.filter((e=>null!=e)).map((e=>kD(e,t).n(kP))),BD=(e,t)=>(e||[]).filter((e=>null!=e)).map((e=>$k(e))),CD=(e,t)=>(e||[]).filter((e=>null!=e)).map((e=>(e=>{const t={};return null!=e[WR]&&(t[WR]=$k(e[WR])),t})(e))),ID=(e,t)=>(e||[]).filter((e=>null!=e)).map((e=>((e,t)=>{const r={};return null!=e[FR]&&(r[FR]=$k(e[FR])),null!=e[RR]&&(r[RR]=jk(rE(e[RR]))),null!=e[yR]&&(r[yR]=$k(e[yR])),""===e.ChecksumAlgorithm?r[GD]=[]:null!=e[GD]&&(r[GD]=BD(CE(e[GD]))),null!=e[wP]&&(r[wP]=Kk(e[wP])),null!=e[uP]&&(r[uP]=$k(e[uP])),null!=e[UR]&&(r[UR]=AD(e[UR],t)),null!=e[aP]&&(r[aP]=FD(e[aP],t)),r})(e,t))),AD=(e,t)=>{const r={};return null!=e[pR]&&(r[pR]=$k(e[pR])),null!=e[kR]&&(r[kR]=$k(e[kR])),r},FD=(e,t)=>{const r={};return null!=e[CR]&&(r[CR]=Mk(e[CR])),null!=e[nP]&&(r[nP]=jk(rE(e[nP]))),r},MD=(e,t)=>{const r={};return null!=e[OD]&&(r[OD]=$k(e[OD])),null!=e[cP]&&(r[cP]=$k(e[cP])),null!=e[bP]&&(r[bP]=$k(e[bP])),null!=e[vR]&&(r[vR]=jk(rE(e[vR]))),r},DD=e=>({httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}),RD="ACL",PD="AbortDate",OD="AccessKeyId",zD="AcceptRanges",ND="AbortRuleId",qD="ArchiveStatus",UD="AccessTier",LD="Bucket",jD="BypassGovernanceRetention",HD="BucketKeyEnabled",$D="Credentials",GD="ChecksumAlgorithm",WD="CacheControl",KD="ChecksumCRC32",VD="ChecksumCRC32C",JD="ContentDisposition",YD="ContentEncoding",QD="ContentLanguage",ZD="ContentLength",XD="ChecksumMode",eR="ContentMD5",tR="CompletedMultipartUpload",rR="CommonPrefixes",iR="CompletedPart",nR="ContentRange",oR="ChecksumSHA1",sR="ChecksumSHA256",aR="ContentType",lR="ContinuationToken",dR="Contents",cR="Delimiter",uR="DeleteMarker",pR="DisplayName",hR="Expires",fR="ExpectedBucketOwner",mR="ExpiresString",gR="EncodingType",yR="ETag",vR="Expiration",bR="FetchOwner",wR="GrantFullControl",_R="GrantRead",xR="GrantReadACP",SR="GrantWriteACP",kR="ID",ER="IfMatch",TR="IfModifiedSince",BR="IfNoneMatch",CR="IsRestoreInProgress",IR="IsTruncated",AR="IfUnmodifiedSince",FR="Key",MR="KeyCount",DR="Location",RR="LastModified",PR="MFA",OR="MaxKeys",zR="MissingMeta",NR="Name",qR="NextContinuationToken",UR="Owner",LR="ObjectKey",jR="ObjectLockLegalHoldStatus",HR="ObjectLockMode",$R="ObjectLockRetainUntilDate",GR="OptionalObjectAttributes",WR="Prefix",KR="PartsCount",VR="PartNumber",JR="Parts",YR="Range",QR="RequestCharged",ZR="ResponseCacheControl",XR="ResponseContentDisposition",eP="ResponseContentEncoding",tP="ResponseContentLanguage",rP="ResponseContentType",iP="ResponseExpires",nP="RestoreExpiryDate",oP="RequestPayer",sP="ReplicationStatus",aP="RestoreStatus",lP="Restore",dP="StartAfter",cP="SecretAccessKey",uP="StorageClass",pP="SessionMode",hP="ServerSideEncryption",fP="SSECustomerAlgorithm",mP="SSECustomerKey",gP="SSECustomerKeyMD5",yP="SSEKMSEncryptionContext",vP="SSEKMSKeyId",bP="SessionToken",wP="Size",_P="Tagging",xP="TagCount",SP="TagSet",kP="Tag",EP="UploadId",TP="VersionId",BP="Value",CP="WebsiteRedirectLocation",IP="accept-ranges",AP="cache-control",FP="content-disposition",MP="content-encoding",DP="content-language",RP="content-length",PP="content-md5",OP="content-range",zP="content-type",NP="continuation-token",qP="delimiter",UP="expires",LP="encoding-type",jP="etag",HP="expiresstring",$P="fetch-owner",GP="if-match",WP="if-modified-since",KP="if-none-match",VP="if-unmodified-since",JP="last-modified",YP="list-type",QP="member",ZP="max-keys",XP="partNumber",eO="prefix",tO="range",rO="response-cache-control",iO="response-content-disposition",nO="response-content-encoding",oO="response-content-language",sO="response-content-type",aO="response-expires",lO="session",dO="start-after",cO="tagging",uO="uploads",pO="uploadId",hO="versionId",fO='',mO="x-amz-acl",gO="x-amz-abort-date",yO="x-amz-abort-rule-id",vO="x-amz-archive-status",bO="x-amz-bypass-governance-retention",wO="x-amz-checksum-algorithm",_O="x-amz-checksum-crc32",xO="x-amz-checksum-crc32c",SO="x-amz-checksum-mode",kO="x-amz-checksum-sha1",EO="x-amz-checksum-sha256",TO="x-amz-create-session-mode",BO="x-amz-delete-marker",CO="x-amz-expiration",IO="x-amz-expected-bucket-owner",AO="x-amz-grant-full-control",FO="x-amz-grant-read",MO="x-amz-grant-read-acp",DO="x-amz-grant-write-acp",RO="x-amz-mfa",PO="x-amz-missing-meta",OO="x-amz-mp-parts-count",zO="x-amz-object-lock-legal-hold",NO="x-amz-object-lock-mode",qO="x-amz-object-lock-retain-until-date",UO="x-amz-optional-object-attributes",LO="x-amz-restore",jO="x-amz-request-charged",HO="x-amz-request-payer",$O="x-amz-replication-status",GO="x-amz-storage-class",WO="x-amz-sdk-checksum-algorithm",KO="x-amz-server-side-encryption",VO="x-amz-server-side-encryption-aws-kms-key-id",JO="x-amz-server-side-encryption-bucket-key-enabled",YO="x-amz-server-side-encryption-context",QO="x-amz-server-side-encryption-customer-algorithm",ZO="x-amz-server-side-encryption-customer-key",XO="x-amz-server-side-encryption-customer-key-md5",ez="x-amz-tagging",tz="x-amz-tagging-count",rz="x-amz-version-id",iz="x-amz-website-redirect-location",nz="x-id";class oz extends(Ik.classBuilder().ep({...lM,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r)]})).s("AmazonS3","CreateSession",{}).n("S3Client","CreateSessionCommand").f(TM,EM).ser(GM).de(rD).build()){}const sz="3.675.0";function az(e){return"string"==typeof e?0===e.length:0===e.byteLength}var lz={name:"SHA-1"},dz={name:"HMAC",hash:lz},cz=new Uint8Array([218,57,163,238,94,107,75,13,50,85,191,239,149,96,24,144,175,216,7,9]);const uz={};function pz(){return"undefined"!=typeof window?window:"undefined"!=typeof self?self:uz}var hz=function(){function e(e){this.toHash=new Uint8Array(0),void 0!==e&&(this.key=new Promise((function(t,r){pz().crypto.subtle.importKey("raw",fz(e),dz,!1,["sign"]).then(t,r)})),this.key.catch((function(){})))}return e.prototype.update=function(e){if(!az(e)){var t=fz(e),r=new Uint8Array(this.toHash.byteLength+t.byteLength);r.set(this.toHash,0),r.set(t,this.toHash.byteLength),this.toHash=r}},e.prototype.digest=function(){var e=this;return this.key?this.key.then((function(t){return pz().crypto.subtle.sign(dz,t,e.toHash).then((function(e){return new Uint8Array(e)}))})):az(this.toHash)?Promise.resolve(cz):Promise.resolve().then((function(){return pz().crypto.subtle.digest(lz,e.toHash)})).then((function(e){return Promise.resolve(new Uint8Array(e))}))},e.prototype.reset=function(){this.toHash=new Uint8Array(0)},e}();function fz(e){return"string"==typeof e?(t=e,(new TextEncoder).encode(t)):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e);var t}var mz=["decrypt","digest","encrypt","exportKey","generateKey","importKey","sign","verify"];function gz(e){return!(!function(e){if("object"==typeof e&&"object"==typeof e.crypto){return"function"==typeof e.crypto.getRandomValues}return!1}(e)||"object"!=typeof e.crypto.subtle)&&yz(e.crypto.subtle)}function yz(e){return e&&mz.every((function(t){return"function"==typeof e[t]}))}var vz=function(){function e(e){if(!gz(pz()))throw new Error("SHA1 not supported");this.hash=new hz(e)}return e.prototype.update=function(e,t){this.hash.update(SS(e))},e.prototype.digest=function(){return this.hash.digest()},e.prototype.reset=function(){this.hash.reset()},e}(),bz={name:"SHA-256"},wz={name:"HMAC",hash:bz},_z=new Uint8Array([227,176,196,66,152,252,28,20,154,251,244,200,153,111,185,36,39,174,65,228,100,155,147,76,164,149,153,27,120,82,184,85]),xz=function(){function e(e){this.toHash=new Uint8Array(0),this.secret=e,this.reset()}return e.prototype.update=function(e){if(!kS(e)){var t=SS(e),r=new Uint8Array(this.toHash.byteLength+t.byteLength);r.set(this.toHash,0),r.set(t,this.toHash.byteLength),this.toHash=r}},e.prototype.digest=function(){var e=this;return this.key?this.key.then((function(t){return pz().crypto.subtle.sign(wz,t,e.toHash).then((function(e){return new Uint8Array(e)}))})):kS(this.toHash)?Promise.resolve(_z):Promise.resolve().then((function(){return pz().crypto.subtle.digest(bz,e.toHash)})).then((function(e){return Promise.resolve(new Uint8Array(e))}))},e.prototype.reset=function(){var e=this;this.toHash=new Uint8Array(0),this.secret&&void 0!==this.secret&&(this.key=new Promise((function(t,r){pz().crypto.subtle.importKey("raw",SS(e.secret),wz,!1,["sign"]).then(t,r)})),this.key.catch((function(){})))},e}(),Sz=64,kz=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),Ez=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],Tz=Math.pow(2,53)-1,Bz=function(){function e(){this.state=Int32Array.from(Ez),this.temp=new Int32Array(64),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}return e.prototype.update=function(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");var t=0,r=e.byteLength;if(this.bytesHashed+=r,8*this.bytesHashed>Tz)throw new Error("Cannot hash more than 2^53 - 1 bits");for(;r>0;)this.buffer[this.bufferLength++]=e[t++],r--,this.bufferLength===Sz&&(this.hashBuffer(),this.bufferLength=0)},e.prototype.digest=function(){if(!this.finished){var e=8*this.bytesHashed,t=new DataView(this.buffer.buffer,this.buffer.byteOffset,this.buffer.byteLength),r=this.bufferLength;if(t.setUint8(this.bufferLength++,128),r%Sz>=56){for(var i=this.bufferLength;i>>24&255,n[4*i+1]=this.state[i]>>>16&255,n[4*i+2]=this.state[i]>>>8&255,n[4*i+3]=this.state[i]>>>0&255;return n},e.prototype.hashBuffer=function(){for(var e=this.buffer,t=this.state,r=t[0],i=t[1],n=t[2],o=t[3],s=t[4],a=t[5],l=t[6],d=t[7],c=0;c>>17|u<<15)^(u>>>19|u<<13)^u>>>10,h=((u=this.temp[c-15])>>>7|u<<25)^(u>>>18|u<<14)^u>>>3;this.temp[c]=(p+this.temp[c-7]|0)+(h+this.temp[c-16]|0)}var f=(((s>>>6|s<<26)^(s>>>11|s<<21)^(s>>>25|s<<7))+(s&a^~s&l)|0)+(d+(kz[c]+this.temp[c]|0)|0)|0,m=((r>>>2|r<<30)^(r>>>13|r<<19)^(r>>>22|r<<10))+(r&i^r&n^i&n)|0;d=l,l=a,a=s,s=o+f|0,o=n,n=i,i=r,r=f+m|0}t[0]+=r,t[1]+=i,t[2]+=n,t[3]+=o,t[4]+=s,t[5]+=a,t[6]+=l,t[7]+=d},e}(),Cz=function(){function e(e){this.secret=e,this.hash=new Bz,this.reset()}return e.prototype.update=function(e){if(!kS(e)&&!this.error)try{this.hash.update(SS(e))}catch(e){this.error=e}},e.prototype.digestSync=function(){if(this.error)throw this.error;return this.outer?(this.outer.finished||this.outer.update(this.hash.digest()),this.outer.digest()):this.hash.digest()},e.prototype.digest=function(){return r(this,void 0,void 0,(function(){return i(this,(function(e){return[2,this.digestSync()]}))}))},e.prototype.reset=function(){if(this.hash=new Bz,this.secret){this.outer=new Bz;var e=function(e){var t=SS(e);if(t.byteLength>Sz){var r=new Bz;r.update(t),t=r.digest()}var i=new Uint8Array(Sz);return i.set(t),i}(this.secret),t=new Uint8Array(Sz);t.set(e);for(var r=0;rasync r=>{const i="undefined"!=typeof window&&window?.navigator?.userAgent?Fz().parse(window.navigator.userAgent):void 0,n=[["aws-sdk-js",t],["ua","2.1"],[`os/${i?.os?.name||"other"}`,i?.os?.version],["lang/js"],["md/browser",`${i?.browser?.name??"unknown"}_${i?.browser?.version??"unknown"}`]];e&&n.push([`api/${e}`,t]);const o=await(r?.userAgentAppId?.());return o&&n.push([`app/${o}`]),n};class Dz{constructor(e){if(this.bytes=e,8!==e.byteLength)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(e){if(e>0x8000000000000000||e<-0x8000000000000000)throw new Error(`${e} is too large (or, if negative, too small) to represent as an Int64`);const t=new Uint8Array(8);for(let r=7,i=Math.abs(Math.round(e));r>-1&&i>0;r--,i/=256)t[r]=i;return e<0&&Rz(t),new Dz(t)}valueOf(){const e=this.bytes.slice(0),t=128&e[0];return t&&Rz(e),parseInt(Sk(e),16)*(t?-1:1)}toString(){return String(this.valueOf())}}function Rz(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,0===e[t]);t--);}class Pz{constructor(e,t){this.toUtf8=e,this.fromUtf8=t}format(e){const t=[];for(const r of Object.keys(e)){const i=this.fromUtf8(r);t.push(Uint8Array.from([i.byteLength]),i,this.formatHeaderValue(e[r]))}const r=new Uint8Array(t.reduce(((e,t)=>e+t.byteLength),0));let i=0;for(const e of t)r.set(e,i),i+=e.byteLength;return r}formatHeaderValue(e){switch(e.type){case"boolean":return Uint8Array.from([e.value?0:1]);case"byte":return Uint8Array.from([2,e.value]);case"short":const t=new DataView(new ArrayBuffer(3));return t.setUint8(0,3),t.setInt16(1,e.value,!1),new Uint8Array(t.buffer);case"integer":const r=new DataView(new ArrayBuffer(5));return r.setUint8(0,4),r.setInt32(1,e.value,!1),new Uint8Array(r.buffer);case"long":const i=new Uint8Array(9);return i[0]=5,i.set(e.value.bytes,1),i;case"binary":const n=new DataView(new ArrayBuffer(3+e.value.byteLength));n.setUint8(0,6),n.setUint16(1,e.value.byteLength,!1);const o=new Uint8Array(n.buffer);return o.set(e.value,3),o;case"string":const s=this.fromUtf8(e.value),a=new DataView(new ArrayBuffer(3+s.byteLength));a.setUint8(0,7),a.setUint16(1,s.byteLength,!1);const l=new Uint8Array(a.buffer);return l.set(s,3),l;case"timestamp":const d=new Uint8Array(9);return d[0]=8,d.set(Dz.fromNumber(e.value.valueOf()).bytes,1),d;case"uuid":if(!Wz.test(e.value))throw new Error(`Invalid UUID received: ${e.value}`);const c=new Uint8Array(17);return c[0]=9,c.set(xk(e.value.replace(/\-/g,"")),1),c}}parse(e){const t={};let r=0;for(;re,isEndOfStream:()=>t}}getAvailableMessages(){const e=this.messageBuffer;this.messageBuffer=[];const t=this.isEndOfStream;return{getMessages:()=>e,isEndOfStream:()=>t}}encode({headers:e,body:t}){const r=this.headerMarshaller.format(e),i=r.byteLength+t.byteLength+16,n=new Uint8Array(i),o=new DataView(n.buffer,n.byteOffset,n.byteLength),s=new CS;return o.setUint32(0,i,!1),o.setUint32(4,r.byteLength,!1),o.setUint32(8,s.update(n.subarray(0,8)).digest(),!1),n.set(r,12),n.set(t,r.byteLength+12),o.setUint32(i-4,s.update(n.subarray(8,i-4)).digest(),!1),n}decode(e){const{headers:t,body:r}=function({byteLength:e,byteOffset:t,buffer:r}){if(e<16)throw new Error("Provided message too short to accommodate event stream message overhead");const i=new DataView(r,t,e),n=i.getUint32(0,!1);if(e!==n)throw new Error("Reported message length does not match received message length");const o=i.getUint32(4,!1),s=i.getUint32(8,!1),a=i.getUint32(e-4,!1),l=(new CS).update(new Uint8Array(r,t,8));if(s!==l.digest())throw new Error(`The prelude checksum specified in the message (${s}) does not match the calculated CRC32 checksum (${l.digest()})`);if(l.update(new Uint8Array(r,t+8,e-12)),a!==l.digest())throw new Error(`The message checksum (${l.digest()}) did not match the expected value of ${a}`);return{headers:new DataView(r,t+8+4,o),body:new Uint8Array(r,t+8+4+o,n-o-16)}}(e);return{headers:this.headerMarshaller.parse(t),body:r}}formatHeaders(e){return this.headerMarshaller.format(e)}}class Vz{constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(const e of this.options.inputStream){const t=this.options.decoder.decode(e);yield t}}}class Jz{constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(const e of this.options.messageStream){const t=this.options.encoder.encode(e);yield t}this.options.includeEndFrame&&(yield new Uint8Array(0))}}class Yz{constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(const e of this.options.messageStream){const t=await this.options.deserializer(e);void 0!==t&&(yield t)}}}class Qz{constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(const e of this.options.inputStream){const t=this.options.serializer(e);yield t}}}function Zz(e,t){return async function(r){const{value:i}=r.headers[":message-type"];if("error"===i){const e=new Error(r.headers[":error-message"].value||"UnknownError");throw e.name=r.headers[":error-code"].value,e}if("exception"===i){const i=r.headers[":exception-type"].value,n={[i]:r},o=await e(n);if(o.$unknown){const e=new Error(t(r.body));throw e.name=i,e}throw o[i]}if("event"===i){const t={[r.headers[":event-type"].value]:r},i=await e(t);if(i.$unknown)return;return i}throw Error(`Unrecognizable event type: ${r.headers[":event-type"].value}`)}}class Xz{constructor({utf8Encoder:e,utf8Decoder:t}){this.eventStreamCodec=new Kz(e,t),this.utfEncoder=e}deserialize(e,t){const r=function(e){let t=0,r=0,i=null,n=null;const o=e=>{if("number"!=typeof e)throw new Error("Attempted to allocate an event message where size was not a number: "+e);t=e,r=4,i=new Uint8Array(e),new DataView(i.buffer).setUint32(0,e,!1)};return{[Symbol.asyncIterator]:async function*(){const s=e[Symbol.asyncIterator]();for(;;){const{value:e,done:a}=await s.next();if(a){if(!t)return;if(t!==r)throw new Error("Truncated event message received.");return void(yield i)}const l=e.length;let d=0;for(;d{const t=e[Symbol.asyncIterator]();return new ReadableStream({async pull(e){const{done:r,value:i}=await t.next();if(r)return e.close();e.enqueue(i)}})})(r):r}}const tN=e=>"function"==typeof ReadableStream&&e instanceof ReadableStream,rN=e=>new eN(e);const iN=async function(e,t){const r=new e;return await function(e,t,r=1048576){return new Promise(((i,n)=>{const o=new FileReader;o.addEventListener("error",n),o.addEventListener("abort",n);const s=e.size;let a=0;function l(){a>=s?i():o.readAsArrayBuffer(e.slice(a,Math.min(s,a+r)))}o.addEventListener("load",(e=>{const r=e.target.result;t(new Uint8Array(r)),a+=r.byteLength,l()})),l()}))}(t,(e=>{r.update(e)})),r.digest()},nN=64,oN=[1732584193,4023233417,2562383102,271733878];class sN{constructor(){this.reset()}update(e){if(function(e){if("string"==typeof e)return 0===e.length;return 0===e.byteLength}(e))return;if(this.finished)throw new Error("Attempted to update an already finished hash.");const t=function(e){if("string"==typeof e)return RS(e);if(ArrayBuffer.isView(e))return new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT);return new Uint8Array(e)}(e);let r=0,{byteLength:i}=t;for(this.bytesHashed+=i;i>0;)this.buffer.setUint8(this.bufferLength++,t[r++]),i--,this.bufferLength===nN&&(this.hashBuffer(),this.bufferLength=0)}async digest(){if(!this.finished){const{buffer:e,bufferLength:t,bytesHashed:r}=this,i=8*r;if(e.setUint8(this.bufferLength++,128),t%nN>=56){for(let t=this.bufferLength;t>>0,!0),e.setUint32(60,Math.floor(i/4294967296),!0),this.hashBuffer(),this.finished=!0}const e=new DataView(new ArrayBuffer(16));for(let t=0;t<4;t++)e.setUint32(4*t,this.state[t],!0);return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}hashBuffer(){const{buffer:e,state:t}=this;let r=t[0],i=t[1],n=t[2],o=t[3];r=lN(r,i,n,o,e.getUint32(0,!0),7,3614090360),o=lN(o,r,i,n,e.getUint32(4,!0),12,3905402710),n=lN(n,o,r,i,e.getUint32(8,!0),17,606105819),i=lN(i,n,o,r,e.getUint32(12,!0),22,3250441966),r=lN(r,i,n,o,e.getUint32(16,!0),7,4118548399),o=lN(o,r,i,n,e.getUint32(20,!0),12,1200080426),n=lN(n,o,r,i,e.getUint32(24,!0),17,2821735955),i=lN(i,n,o,r,e.getUint32(28,!0),22,4249261313),r=lN(r,i,n,o,e.getUint32(32,!0),7,1770035416),o=lN(o,r,i,n,e.getUint32(36,!0),12,2336552879),n=lN(n,o,r,i,e.getUint32(40,!0),17,4294925233),i=lN(i,n,o,r,e.getUint32(44,!0),22,2304563134),r=lN(r,i,n,o,e.getUint32(48,!0),7,1804603682),o=lN(o,r,i,n,e.getUint32(52,!0),12,4254626195),n=lN(n,o,r,i,e.getUint32(56,!0),17,2792965006),i=lN(i,n,o,r,e.getUint32(60,!0),22,1236535329),r=dN(r,i,n,o,e.getUint32(4,!0),5,4129170786),o=dN(o,r,i,n,e.getUint32(24,!0),9,3225465664),n=dN(n,o,r,i,e.getUint32(44,!0),14,643717713),i=dN(i,n,o,r,e.getUint32(0,!0),20,3921069994),r=dN(r,i,n,o,e.getUint32(20,!0),5,3593408605),o=dN(o,r,i,n,e.getUint32(40,!0),9,38016083),n=dN(n,o,r,i,e.getUint32(60,!0),14,3634488961),i=dN(i,n,o,r,e.getUint32(16,!0),20,3889429448),r=dN(r,i,n,o,e.getUint32(36,!0),5,568446438),o=dN(o,r,i,n,e.getUint32(56,!0),9,3275163606),n=dN(n,o,r,i,e.getUint32(12,!0),14,4107603335),i=dN(i,n,o,r,e.getUint32(32,!0),20,1163531501),r=dN(r,i,n,o,e.getUint32(52,!0),5,2850285829),o=dN(o,r,i,n,e.getUint32(8,!0),9,4243563512),n=dN(n,o,r,i,e.getUint32(28,!0),14,1735328473),i=dN(i,n,o,r,e.getUint32(48,!0),20,2368359562),r=cN(r,i,n,o,e.getUint32(20,!0),4,4294588738),o=cN(o,r,i,n,e.getUint32(32,!0),11,2272392833),n=cN(n,o,r,i,e.getUint32(44,!0),16,1839030562),i=cN(i,n,o,r,e.getUint32(56,!0),23,4259657740),r=cN(r,i,n,o,e.getUint32(4,!0),4,2763975236),o=cN(o,r,i,n,e.getUint32(16,!0),11,1272893353),n=cN(n,o,r,i,e.getUint32(28,!0),16,4139469664),i=cN(i,n,o,r,e.getUint32(40,!0),23,3200236656),r=cN(r,i,n,o,e.getUint32(52,!0),4,681279174),o=cN(o,r,i,n,e.getUint32(0,!0),11,3936430074),n=cN(n,o,r,i,e.getUint32(12,!0),16,3572445317),i=cN(i,n,o,r,e.getUint32(24,!0),23,76029189),r=cN(r,i,n,o,e.getUint32(36,!0),4,3654602809),o=cN(o,r,i,n,e.getUint32(48,!0),11,3873151461),n=cN(n,o,r,i,e.getUint32(60,!0),16,530742520),i=cN(i,n,o,r,e.getUint32(8,!0),23,3299628645),r=uN(r,i,n,o,e.getUint32(0,!0),6,4096336452),o=uN(o,r,i,n,e.getUint32(28,!0),10,1126891415),n=uN(n,o,r,i,e.getUint32(56,!0),15,2878612391),i=uN(i,n,o,r,e.getUint32(20,!0),21,4237533241),r=uN(r,i,n,o,e.getUint32(48,!0),6,1700485571),o=uN(o,r,i,n,e.getUint32(12,!0),10,2399980690),n=uN(n,o,r,i,e.getUint32(40,!0),15,4293915773),i=uN(i,n,o,r,e.getUint32(4,!0),21,2240044497),r=uN(r,i,n,o,e.getUint32(32,!0),6,1873313359),o=uN(o,r,i,n,e.getUint32(60,!0),10,4264355552),n=uN(n,o,r,i,e.getUint32(24,!0),15,2734768916),i=uN(i,n,o,r,e.getUint32(52,!0),21,1309151649),r=uN(r,i,n,o,e.getUint32(16,!0),6,4149444226),o=uN(o,r,i,n,e.getUint32(44,!0),10,3174756917),n=uN(n,o,r,i,e.getUint32(8,!0),15,718787259),i=uN(i,n,o,r,e.getUint32(36,!0),21,3951481745),t[0]=r+t[0]&4294967295,t[1]=i+t[1]&4294967295,t[2]=n+t[2]&4294967295,t[3]=o+t[3]&4294967295}reset(){this.state=Uint32Array.from(oN),this.buffer=new DataView(new ArrayBuffer(nN)),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}}function aN(e,t,r,i,n,o){return((t=(t+e&4294967295)+(i+o&4294967295)&4294967295)<>>32-n)+r&4294967295}function lN(e,t,r,i,n,o,s){return aN(t&r|~t&i,e,t,n,o,s)}function dN(e,t,r,i,n,o,s){return aN(t&i|r&~i,e,t,n,o,s)}function cN(e,t,r,i,n,o,s){return aN(t^r^i,e,t,n,o,s)}function uN(e,t,r,i,n,o,s){return aN(r^(t|~i),e,t,n,o,s)}const pN="function"==typeof TextEncoder?new TextEncoder:null,hN=e=>{if("string"==typeof e){if(pN)return pN.encode(e).byteLength;let t=e.length;for(let r=t-1;r>=0;r--){const i=e.charCodeAt(r);i>127&&i<=2047?t++:i>2047&&i<=65535&&(t+=2),i>=56320&&i<=57343&&r--}return t}if("number"==typeof e.byteLength)return e.byteLength;if("number"==typeof e.size)return e.size;throw new Error(`Body Length computation failed for ${e}`)},fN=e=>new Date(Date.now()+e),mN=e=>nS.isInstance(e)?e.headers?.date??e.headers?.Date:void 0,gN=(e,t)=>{const r=Date.parse(e);return((e,t)=>Math.abs(fN(t).getTime()-e)>=3e5)(r,t)?r-Date.now():t},yN=(e,t)=>{if(!t)throw new Error(`Property \`${e}\` is not resolved for AWS SDK SigV4Auth`);return t},vN=async e=>{const t=yN("context",e.context),r=yN("config",e.config),i=t.endpointV2?.properties?.authSchemes?.[0],n=yN("signer",r.signer),o=await n(i),s=e?.signingRegion,a=e?.signingRegionSet,l=e?.signingName;return{config:r,signer:o,signingRegion:s,signingRegionSet:a,signingName:l}};class bN{async sign(e,t,r){if(!iS.isInstance(e))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");const i=await vN(r),{config:n,signer:o}=i;let{signingRegion:s,signingName:a}=i;const l=r.context;if(l?.authSchemes?.length){const[e,t]=l.authSchemes;"sigv4a"===e?.name&&"sigv4"===t?.name&&(s=t?.signingRegion??s,a=t?.signingName??a)}return await o.sign(e,{signingDate:fN(n.systemClockOffset),signingRegion:s,signingService:a})}errorHandler(e){return t=>{const r=t.ServerTime??mN(t.$response);if(r){const i=yN("config",e.config),n=i.systemClockOffset;i.systemClockOffset=gN(r,i.systemClockOffset);i.systemClockOffset!==n&&t.$metadata&&(t.$metadata.clockSkewCorrected=!0)}throw t}}successHandler(e,t){const r=mN(e);if(r){const e=yN("config",t.config);e.systemClockOffset=gN(r,e.systemClockOffset)}}}class wN extends bN{async sign(e,t,r){if(!iS.isInstance(e))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");const{config:i,signer:n,signingRegion:o,signingRegionSet:s,signingName:a}=await vN(r),l=(await(i.sigv4aSigningRegionSet?.())??s??[o]).join(",");return await n.sign(e,{signingDate:fN(i.systemClockOffset),signingRegion:l,signingService:a})}}const _N=["in-region","cross-region","mobile","standard","legacy"],xN=()=>{const e="undefined"!=typeof window&&window?.navigator?.userAgent?Fz().parse(window.navigator.userAgent):void 0,t=e?.platform?.type;return"tablet"===t||"mobile"===t},SN=e=>{const t=(({defaultsMode:e}={})=>((e,t,r)=>{let i,n,o,s=!1;const a=async()=>{n||(n=e());try{i=await n,o=!0,s=!1}finally{n=void 0}return i};return void 0===t?async e=>(o&&!e?.forceRefresh||(i=await a()),i):async e=>(o&&!e?.forceRefresh||(i=await a()),s?i:r&&!r(i)?(s=!0,i):t(i)?(await a(),i):i)})((async()=>{const t="function"==typeof e?await e():e;switch(t?.toLowerCase()){case"auto":return Promise.resolve(xN()?"mobile":"standard");case"mobile":case"in-region":case"cross-region":case"standard":case"legacy":return Promise.resolve(t?.toLocaleLowerCase());case void 0:return Promise.resolve("legacy");default:throw new Error(`Invalid parameter for "defaultsMode", expect ${_N.join(", ")}, got ${t}`)}})))(e),r=()=>t().then(_E),i=(e=>({apiVersion:"2006-03-01",base64Decoder:e?.base64Decoder??lk,base64Encoder:e?.base64Encoder??dk,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??tM,extensions:e?.extensions??[],getAwsChunkedEncodingStream:e?.getAwsChunkedEncodingStream??pk,httpAuthSchemeProvider:e?.httpAuthSchemeProvider??sM,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new bN},{schemeId:"aws.auth#sigv4a",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4a"),signer:new wN}],logger:e?.logger??new ME,sdkStreamMixin:e?.sdkStreamMixin??Tk,serviceId:e?.serviceId??"S3",signerConstructor:e?.signerConstructor??LC,signingEscapePath:e?.signingEscapePath??!1,urlParser:e?.urlParser??HT,useArnRegion:e?.useArnRegion??!1,utf8Decoder:e?.utf8Decoder??RS,utf8Encoder:e?.utf8Encoder??ck}))(e);return{...i,...e,runtime:"browser",defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??hN,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(new Error("Credential is missing"))),defaultUserAgentProvider:e?.defaultUserAgentProvider??Mz({serviceId:i.serviceId,clientVersion:sz}),eventStreamSerdeProvider:e?.eventStreamSerdeProvider??rN,maxAttempts:e?.maxAttempts??3,md5:e?.md5??sN,region:e?.region??(n="Region is missing",()=>Promise.reject(n)),requestHandler:vk.create(e?.requestHandler??r),retryMode:e?.retryMode??(async()=>(await r()).retryMode||rB),sha1:e?.sha1??vz,sha256:e?.sha256??Iz,streamCollector:e?.streamCollector??bk,streamHasher:e?.streamHasher??iN,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(false)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(false))};var n},kN=e=>{let t=async()=>{if(void 0===e.region)throw new Error("Region is missing from runtimeConfig");const t=e.region;return"string"==typeof t?t:t()};return{setRegion(e){t=e},region:()=>t}},EN=e=>{const t=e.httpAuthSchemes;let r=e.httpAuthSchemeProvider,i=e.credentials;return{setHttpAuthScheme(e){const r=t.findIndex((t=>t.schemeId===e.schemeId));-1===r?t.push(e):t.splice(r,1,e)},httpAuthSchemes:()=>t,setHttpAuthSchemeProvider(e){r=e},httpAuthSchemeProvider:()=>r,setCredentials(e){i=e},credentials:()=>i}},TN=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()});class BN extends ok{constructor(...[e]){const t=SN(e||{});var r;const i=function(e){const t=NB(e.userAgentAppId??void 0);return{...e,customUserAgent:"string"==typeof e.customUserAgent?[[e.customUserAgent]]:e.customUserAgent,userAgentAppId:async()=>{const r=await t();if(!function(e){return void 0===e||"string"==typeof e&&e.length<=50}(r)){const t="NoOpLogger"!==e.logger?.constructor?.name&&e.logger?e.logger:console;"string"!=typeof r?t?.warn("userAgentAppId must be a string or undefined."):r.length>50&&t?.warn("The provided userAgentAppId exceeds the maximum length of 50 characters.")}return r}}}((r=t,{...r,useFipsEndpoint:r.useFipsEndpoint??!1,useDualstackEndpoint:r.useDualstackEndpoint??!1,forcePathStyle:r.forcePathStyle??!1,useAccelerateEndpoint:r.useAccelerateEndpoint??!1,useGlobalEndpoint:r.useGlobalEndpoint??!1,disableMultiregionAccessPoints:r.disableMultiregionAccessPoints??!1,defaultSigningName:"s3"}));var n;const o=(e=>({...e,eventStreamMarshaller:e.eventStreamSerdeProvider(e)}))((e=>{const t=e.tls??!0,{endpoint:r}=e,i=null!=r?async()=>$T(await WS(r)()):void 0,n=!!r,o={...e,endpoint:i,tls:t,isCustomEndpoint:n,useDualstackEndpoint:WS(e.useDualstackEndpoint??!1),useFipsEndpoint:WS(e.useFipsEndpoint??!1)};let s;return o.serviceConfiguredEndpoint=async()=>(e.serviceId&&!s&&(s=jT(e.serviceId)),s),o})((e=>{const{region:t,useFipsEndpoint:r}=e;if(!t)throw new Error("Region is missing");return{...e,region:async()=>{if("string"==typeof t)return PC(t);const e=await t();return PC(e)},useFipsEndpoint:async()=>{const e="string"==typeof t?t:await t();return!!RC(e)||("function"!=typeof r?Promise.resolve(!!r):r())}}})((e=>{const{retryStrategy:t}=e,r=WS(e.maxAttempts??3);return{...e,maxAttempts:r,retryStrategy:async()=>t||(await WS(e.retryMode)()===tB.ADAPTIVE?new gB(r):new mB(r))}})((n=i,{...n,requestChecksumCalculation:WS(n.requestChecksumCalculation??lS),responseChecksumValidation:WS(n.responseChecksumValidation??dS)}))))),s=((e,{session:t})=>{const[r,i]=t;return{...e,forcePathStyle:e.forcePathStyle??!1,useAccelerateEndpoint:e.useAccelerateEndpoint??!1,disableMultiregionAccessPoints:e.disableMultiregionAccessPoints??!1,followRegionRedirects:e.followRegionRedirects??!1,s3ExpressIdentityProvider:e.s3ExpressIdentityProvider??new JE((async e=>r().send(new i({Bucket:e,SessionMode:"ReadWrite"})))),bucketEndpoint:e.bucketEndpoint??!1}})(aM(o),{session:[()=>this,oz]}),a=((e,t)=>{const r={...kN(e),...BE(e),...Vx(e),...EN(e)};return t.forEach((e=>e.configure(r))),{...e,...(o=r,{region:o.region()}),...(n=r,{...kE(n),...TE(n)}),...(i=r,{httpHandler:i.httpHandler()}),...TN(r)};var i,n,o})(s,e?.extensions||[]);var l;super(a),this.config=a,this.middlewareStack.use((l=this.config,{applyToStack:e=>{e.add(FC(l),DC)}})),this.middlewareStack.use(AB(this.config)),this.middlewareStack.use(NC(this.config)),this.middlewareStack.use(VS(this.config)),this.middlewareStack.use((this.config,{applyToStack:e=>{e.add(((e,t)=>async r=>{try{const i=await e(r),{clientName:n,commandName:o,logger:s,dynamoDbDocumentClientOptions:a={}}=t,{overrideInputFilterSensitiveLog:l,overrideOutputFilterSensitiveLog:d}=a,c=l??t.inputFilterSensitiveLog,u=d??t.outputFilterSensitiveLog,{$metadata:p,...h}=i.output;return s?.info?.({clientName:n,commandName:o,input:c(r.input),output:u(h),metadata:p}),i}catch(e){const{clientName:i,commandName:n,logger:o,dynamoDbDocumentClientOptions:s={}}=t,{overrideInputFilterSensitiveLog:a}=s,l=a??t.inputFilterSensitiveLog;throw o?.error?.({clientName:i,commandName:n,input:l(r.input),error:e,metadata:e.$metadata}),e}}),JS)}})),this.middlewareStack.use(XS(this.config)),this.middlewareStack.use(((e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r})=>({applyToStack:i=>{i.addRelativeTo(PT(e,{httpAuthSchemeParametersProvider:t,identityProviderConfigProvider:r}),ZT)}}))(this.config,{httpAuthSchemeParametersProvider:rM,identityProviderConfigProvider:async e=>new RB({"aws.auth#sigv4":e.credentials,"aws.auth#sigv4a":e.credentials})})),this.middlewareStack.use(DB(this.config)),this.middlewareStack.use(QB(this.config)),this.middlewareStack.use(sS(this.config)),this.middlewareStack.use($E(this.config)),this.middlewareStack.use(RT(this.config)),this.middlewareStack.use((e=>({applyToStack:t=>{t.addRelativeTo(HB(e),MB)}}))(this.config))}destroy(){super.destroy()}}class CN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Prefix:{type:"contextParams",name:"Prefix"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r)]})).s("AmazonS3","ListObjectsV2",{}).n("S3Client","ListObjectsV2Command").f(void 0,void 0).ser(JM).de(sD).build()){}const IN={name:"ssecMiddleware",step:"initialize",tags:["SSE"],override:!0},AN=e=>({applyToStack:t=>{var r;t.add((r=e,e=>async t=>{const i={...t.input},n=[{target:"SSECustomerKey",hash:"SSECustomerKeyMD5"},{target:"CopySourceSSECustomerKey",hash:"CopySourceSSECustomerKeyMD5"}];for(const e of n){const t=i[e.target];if(t){let n;"string"==typeof t?FN(t,r)?n=r.base64Decoder(t):(n=r.utf8Decoder(t),i[e.target]=r.base64Encoder(n)):(n=ArrayBuffer.isView(t)?new Uint8Array(t.buffer,t.byteOffset,t.byteLength):new Uint8Array(t),i[e.target]=r.base64Encoder(n));const o=new r.md5;o.update(n),i[e.hash]=r.base64Encoder(await o.digest())}}return e({...t,input:i})}),IN)}});function FN(e,t){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(e))return!1;try{return 32===t.base64Decoder(e).length}catch{return!1}}class MN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r),AN(r),WE()]})).s("AmazonS3","HeadObject",{}).n("S3Client","HeadObjectCommand").f(AM,IM).ser(VM).de(oD).build()){}class DN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),$S(r,{input:this.input,requestAlgorithmMember:"ChecksumAlgorithm",requestChecksumRequired:!1}),LE(),VB(r),AN(r)]})).s("AmazonS3","PutObject",{}).n("S3Client","PutObjectCommand").f(qM,NM).ser(YM).de(aD).build()){}class RN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),$S(r,{input:this.input,requestChecksumRequired:!1,requestValidationModeMember:"ChecksumMode",responseAlgorithms:["CRC32","CRC32C","SHA256","SHA1"]}),AN(r),WE()]})).s("AmazonS3","GetObject",{}).n("S3Client","GetObjectCommand").f(CM,BM).ser(KM).de(nD).build()){}class PN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r)]})).s("AmazonS3","DeleteObject",{}).n("S3Client","DeleteObjectCommand").f(void 0,void 0).ser(WM).de(iD).build()){}class ON extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r),AN(r)]})).s("AmazonS3","CreateMultipartUpload",{}).n("S3Client","CreateMultipartUploadCommand").f(SM,xM).ser($M).de(tD).build()){}class zN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r)]})).s("AmazonS3","AbortMultipartUpload",{}).n("S3Client","AbortMultipartUploadCommand").f(void 0,void 0).ser(jM).de(XM).build()){}class NN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),$S(r,{input:this.input,requestAlgorithmMember:"ChecksumAlgorithm",requestChecksumRequired:!1}),VB(r),AN(r)]})).s("AmazonS3","UploadPart",{}).n("S3Client","UploadPartCommand").f(LM,UM).ser(ZM).de(dD).build()){}class qN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),VB(r),AN(r)]})).s("AmazonS3","CompleteMultipartUpload",{}).n("S3Client","CompleteMultipartUploadCommand").f(_M,wM).ser(HM).de(eD).build()){}class UN extends(Ik.classBuilder().ep({...lM,Bucket:{type:"contextParams",name:"Bucket"}}).m((function(e,t,r,i){return[JT(r,this.serialize,this.deserialize),QT(r,e.getEndpointParameterInstructions()),$S(r,{input:this.input,requestAlgorithmMember:"ChecksumAlgorithm",requestChecksumRequired:!0}),VB(r)]})).s("AmazonS3","PutObjectTagging",{}).n("S3Client","PutObjectTaggingCommand").f(void 0,void 0).ser(QM).de(lD).build()){}class LN{constructor(){this.onabort=null,this._aborted=!1,Object.defineProperty(this,"_aborted",{value:!1,writable:!0})}get aborted(){return this._aborted}abort(){this._aborted=!0,this.onabort&&(this.onabort(this),this.onabort=null)}}class jN{constructor(){this.signal=new LN}abort(){this.signal.abort()}}var HN=__webpack_require__(66339);const $N={lstatSync:()=>{},runtime:"browser"},GN=e=>{if(null==e)return 0;if("string"==typeof e)return HN.hp.byteLength(e);if("number"==typeof e.byteLength)return e.byteLength;if("number"==typeof e.length)return e.length;if("number"==typeof e.size)return e.size;if("string"==typeof e.path)try{return $N.lstatSync(e.path).size}catch(e){return}};async function*WN(e,t,r){let i=1;const n={chunks:[],length:0};for await(const o of r(e))for(n.chunks.push(o),n.length+=o.byteLength;n.length>t;){const e=n.chunks.length>1?HN.hp.concat(n.chunks):n.chunks[0];yield{partNumber:i,data:e.subarray(0,t)},n.chunks=[e.subarray(t)],n.length=n.chunks[0].byteLength,i+=1}yield{partNumber:i,data:1!==n.chunks.length?HN.hp.concat(n.chunks):n.chunks[0],lastPart:!0}}async function*KN(e,t){let r=1,i=0,n=t;for(;n{this.bytesUploadedSoFar=t.loaded,this.totalBytes=t.total,this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:e.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})};null!==n&&n.on("xhr.upload.progress",o);const s=await Promise.all([this.client.send(new DN(t)),r?.endpoint?.()]),a=s[0];let l=s[1];if(l||(l=$T(await GT(t,DN,{...r}))),!l)throw new Error('Could not resolve endpoint from S3 "client.config.endpoint()" nor EndpointsV2.');null!==n&&n.off("xhr.upload.progress",o);const d=this.params.Key.split("/").map((e=>xE(e))).join("/"),c=xE(this.params.Bucket),u=(()=>{const e=l.hostname.startsWith(`${c}.`),t=this.client.config.forcePathStyle,r=l.port?`:${l.port}`:"";return t?`${l.protocol}//${l.hostname}${r}/${c}/${d}`:e?`${l.protocol}//${l.hostname}${r}/${d}`:`${l.protocol}//${c}.${l.hostname}${r}/${d}`})();this.singleUploadResult={...a,Bucket:this.params.Bucket,Key:this.params.Key,Location:u};const p=GN(e.data);this.__notifyProgress({loaded:p,total:p,part:1,Key:this.params.Key,Bucket:this.params.Bucket})}async __createMultipartUpload(){if(!this.createMultiPartPromise){const e={...this.params,Body:void 0};this.createMultiPartPromise=this.client.send(new ON(e)).then((e=>(this.abortMultipartUploadCommand=new zN({Bucket:this.params.Bucket,Key:this.params.Key,UploadId:e.UploadId}),e)))}return this.createMultiPartPromise}async __doConcurrentUpload(e){for await(const t of e){if(this.uploadEnqueuedPartsCount>this.MAX_PARTS)throw new Error(`Exceeded ${this.MAX_PARTS} parts in multipart upload to Bucket: ${this.params.Bucket} Key: ${this.params.Key}.`);if(this.abortController.signal.aborted)return;if(1===t.partNumber&&t.lastPart)return await this.__uploadUsingPut(t);if(!this.uploadId){const{UploadId:e}=await this.__createMultipartUpload();if(this.uploadId=e,this.abortController.signal.aborted)return}const e=GN(t.data)||0,r=this.client.config.requestHandler,i=r instanceof hp.EventEmitter?r:null;let n=0;const o=(r,i)=>{(Number(i.query.partNumber)||-1)===t.partNumber&&(r.total&&e&&(this.bytesUploadedSoFar+=r.loaded-n,n=r.loaded),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket}))};null!==i&&i.on("xhr.upload.progress",o),this.uploadEnqueuedPartsCount+=1;const s=await this.client.send(new NN({...this.params,ContentLength:void 0,UploadId:this.uploadId,Body:t.data,PartNumber:t.partNumber}));if(null!==i&&i.off("xhr.upload.progress",o),this.abortController.signal.aborted)return;if(!s.ETag)throw new Error(`Part ${t.partNumber} is missing ETag in UploadPart response. Missing Bucket CORS configuration for ETag header?`);this.uploadedParts.push({PartNumber:t.partNumber,ETag:s.ETag,...s.ChecksumCRC32&&{ChecksumCRC32:s.ChecksumCRC32},...s.ChecksumCRC32C&&{ChecksumCRC32C:s.ChecksumCRC32C},...s.ChecksumSHA1&&{ChecksumSHA1:s.ChecksumSHA1},...s.ChecksumSHA256&&{ChecksumSHA256:s.ChecksumSHA256}}),null===i&&(this.bytesUploadedSoFar+=e),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})}}async __doMultipartUpload(){const e=((e,t)=>{if(e instanceof Uint8Array)return KN(e,t);if(e instanceof Kx.Readable)return WN(e,t,VN);if(e instanceof String||"string"==typeof e)return KN(HN.hp.from(e),t);if("function"==typeof e.stream)return WN(e.stream(),t,JN);if(e instanceof ReadableStream)return WN(e,t,JN);throw new Error("Body Data is unsupported format, expected data to be one of: string | Uint8Array | Buffer | Readable | ReadableStream | Blob;.")})(this.params.Body,this.partSize),t=[];for(let r=0;r{t.push(e)}));this.concurrentUploaders.push(r)}if(await Promise.all(this.concurrentUploaders),t.length>=1)throw await this.markUploadAsAborted(),t[0];if(this.abortController.signal.aborted)throw await this.markUploadAsAborted(),Object.assign(new Error("Upload aborted."),{name:"AbortError"});let r;if(this.isMultiPart){this.uploadedParts.sort(((e,t)=>e.PartNumber-t.PartNumber));const e={...this.params,Body:void 0,UploadId:this.uploadId,MultipartUpload:{Parts:this.uploadedParts}};r=await this.client.send(new qN(e)),"string"==typeof r?.Location&&r.Location.includes("%2F")&&(r.Location=r.Location.replace(/%2F/g,"/"))}else r=this.singleUploadResult;return this.abortMultipartUploadCommand=null,this.tags.length&&await this.client.send(new UN({...this.params,Tagging:{TagSet:this.tags}})),r}async markUploadAsAborted(){this.uploadId&&!this.leavePartsOnError&&null!==this.abortMultipartUploadCommand&&(await this.client.send(this.abortMultipartUploadCommand),this.abortMultipartUploadCommand=null)}__notifyProgress(e){this.uploadEvent&&this.emit(this.uploadEvent,e)}async __abortTimeout(e){return new Promise(((t,r)=>{e.onabort=()=>{const e=new Error("Upload aborted.");e.name="AbortError",r(e)}}))}__validateInput(){if(!this.params)throw new Error("InputError: Upload requires params to be passed to upload.");if(!this.client)throw new Error("InputError: Upload requires a AWS client to do uploads with.");if(this.partSize{const t=e.headers,r={};for(const e of Object.keys(t))r[e.toLowerCase()]=t[e];const i=new ReadableStream({start(t){t.enqueue(new Uint8Array(e.arrayBuffer)),t.close()}});return{response:new nS({headers:r,statusCode:e.status,body:i})}})),gk(this.requestTimeoutInMs)];return t&&u.push(new Promise(((e,r)=>{t.onabort=()=>{const e=new Error("Request aborted");e.name="AbortError",r(e)}}))),Promise.race(u)}))}}const XN=e=>{if(void 0===e)return"";let t=he.posix.normalize(e.trim());return void 0===t||""===t||"/"===t||"."===t?"":(t.startsWith("/")&&(t=t.slice(1)),t.endsWith("/")||(t=`${t}/`),t)},eq=(e,t)=>{if(e!==`${t}`&&!e.startsWith(`${t}`))throw Error(`"${e}" doesn't starts with "${t}"`);return e.slice(`${t}`.length)},tq=(e,t)=>{if(void 0===t||""===t)return e;let r=e;return"/"!==e&&""!==e||(r=t),e.startsWith("/")||(r=`${t}${e}`),r},rq=(e,t,r,i)=>{if(void 0===e.LastModified)throw Error(`s3 object ${e.Key} doesn't have LastModified value: ${JSON.stringify(e)}`);const n=1e3*Math.floor(e.LastModified.valueOf()/1e3);let o=n;if(e.Key in r){const t=r[e.Key];0!==t&&(o=t>=1e12?t:1e3*t)}const s=eq(e.Key,t);return{key:s,keyRaw:s,mtimeSvr:n,mtimeCli:o,sizeRaw:e.Size,size:e.Size,etag:e.ETag,synthesizedFolder:!1}};class iq extends Mp{constructor(e){super(),this.s3Config=e,this.s3Client=(e=>{let t,r=e.s3Endpoint;return r.startsWith("http://")||r.startsWith("https://")||(r=`https://${r}`),t=t_&&e.bypassCorsLocally?new BN({region:e.s3Region,endpoint:r,forcePathStyle:e.forcePathStyle,credentials:{accessKeyId:e.s3AccessKeyID,secretAccessKey:e.s3SecretAccessKey},requestHandler:new ZN(void 0,e.reverseProxyNoSignUrl)}):new BN({region:e.s3Region,endpoint:r,forcePathStyle:e.forcePathStyle,credentials:{accessKeyId:e.s3AccessKeyID,secretAccessKey:e.s3SecretAccessKey}}),t.middlewareStack.add(((e,t)=>t=>(t.request.headers["cache-control"]="no-cache",e(t))),{step:"build"}),t})(e),this.kind="s3",this.synthFoldersCache={}}walk(){return r(this,void 0,void 0,(function*(){const e=(yield this._walkFromRoot(this.s3Config.remotePrefix,!1)).filter((e=>""!==e.key&&"/"!==e.key));return e}))}walkPartial(){return r(this,void 0,void 0,(function*(){const e=(yield this._walkFromRoot(this.s3Config.remotePrefix,!0)).filter((e=>""!==e.key&&"/"!==e.key));return e}))}_walkFromRoot(e,t){return r(this,void 0,void 0,(function*(){var i,n;const o={Bucket:this.s3Config.s3BucketName};void 0!==e&&""!==e&&(o.Prefix=e),t&&(o.MaxKeys=10);const s=[],a={},l={},d=t?1:this.s3Config.partsConcurrency,c=new vh({concurrency:d,autoStart:!0});c.on("error",(e=>{throw c.pause(),c.clear(),e}));let u=!0;do{const e=yield this.s3Client.send(new CN(o));if(200!==e.$metadata.httpStatusCode)throw Error("some thing bad while listing remote!");if(void 0===e.Contents)break;if(s.push(...e.Contents),this.s3Config.useAccurateMTime)for(const t of e.Contents)c.add((()=>r(this,void 0,void 0,(function*(){const e=yield this.s3Client.send(new MN({Bucket:this.s3Config.s3BucketName,Key:t.Key}));if(200!==e.$metadata.httpStatusCode)throw Error("some thing bad while heading single object!");void 0===e.Metadata||(a[t.Key]=Math.floor(Number.parseFloat(e.Metadata.mtime||e.Metadata.MTime||"0")),l[t.Key]=Math.floor(Number.parseFloat(e.Metadata.ctime||e.Metadata.CTime||"0")))}))));if(t)u=!1;else if(u=null!==(i=e.IsTruncated)&&void 0!==i&&i,o.ContinuationToken=e.NextContinuationToken,u&&(void 0===o.ContinuationToken||""===o.ContinuationToken))throw Error("isTruncated is true but no continuationToken provided")}while(u);yield c.onIdle();const p=[],h=new Set;for(const e of s){const t=rq(e,null!==(n=this.s3Config.remotePrefix)&&void 0!==n?n:"",a);h.add(t.key),p.push(t);for(const e of zp(t.key,!0))h.has(e)?delete this.synthFoldersCache[e]:(!this.synthFoldersCache.hasOwnProperty(e)||t.mtimeSvr>=this.synthFoldersCache[e].mtimeSvr)&&(this.synthFoldersCache[e]={key:e,keyRaw:e,size:0,sizeRaw:0,sizeEnc:0,mtimeSvr:t.mtimeSvr,mtimeSvrFmt:t.mtimeSvrFmt,mtimeCli:t.mtimeCli,mtimeCliFmt:t.mtimeCliFmt,synthesizedFolder:!0})}for(const e of Object.keys(this.synthFoldersCache))p.push(this.synthFoldersCache[e]);return p}))}stat(e){return r(this,void 0,void 0,(function*(){var t;if(this.synthFoldersCache.hasOwnProperty(e))return this.synthFoldersCache[e];let r=e;return r=tq(r,null!==(t=this.s3Config.remotePrefix)&&void 0!==t?t:""),yield this._statFromRoot(r)}))}_statFromRoot(e){return r(this,void 0,void 0,(function*(){var t,r;if(void 0!==this.s3Config.remotePrefix&&""!==this.s3Config.remotePrefix&&!e.startsWith(this.s3Config.remotePrefix))throw Error("_statFromRoot should only accept prefix-ed path");const i=yield this.s3Client.send(new MN({Bucket:this.s3Config.s3BucketName,Key:e}));return((e,t,r,i)=>{if(void 0===t.LastModified)throw Error(`s3 object ${e} doesn't have LastModified value: ${JSON.stringify(t)}`);const n=1e3*Math.floor(t.LastModified.valueOf()/1e3);let o=n;if(i&&void 0!==t.Metadata){const e=Math.floor(Number.parseFloat(t.Metadata.mtime||t.Metadata.MTime||"0"));0!==e&&(o=e>=1e12?e:1e3*e)}const s=eq(e,r);return{key:s,keyRaw:s,mtimeSvr:n,mtimeCli:o,sizeRaw:t.ContentLength,size:t.ContentLength,etag:t.ETag,synthesizedFolder:!1}})(e,i,null!==(t=this.s3Config.remotePrefix)&&void 0!==t?t:"",null!==(r=this.s3Config.useAccurateMTime)&&void 0!==r&&r)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){var r,n;if(!e.endsWith("/"))throw new Error(`You should not call mkdir on ${e}!`);if(!(null!==(r=this.s3Config.generateFolderObject)&&void 0!==r&&r)){const r={key:e,keyRaw:e,size:0,sizeRaw:0,sizeEnc:0,mtimeSvr:t,mtimeCli:t,synthesizedFolder:!0};return this.synthFoldersCache[e]=r,r}const o=tq(e,null!==(n=this.s3Config.remotePrefix)&&void 0!==n?n:"");return yield this._mkdirFromRoot(o,t,i)}))}_mkdirFromRoot(e,t,i){return r(this,void 0,void 0,(function*(){if(void 0!==this.s3Config.remotePrefix&&""!==this.s3Config.remotePrefix&&!e.startsWith(this.s3Config.remotePrefix))throw Error("_mkdirFromRoot should only accept prefix-ed path");const r=I,n={Bucket:this.s3Config.s3BucketName,Key:e,Body:"",ContentType:r,ContentLength:0},o={};return void 0!==t&&0!==t&&(o.MTime=""+t/1e3),void 0!==i&&0!==i&&(o.CTime=""+i/1e3),Object.keys(o).length>0&&(n.Metadata=o),yield this.s3Client.send(new DN(n)),yield this._statFromRoot(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){var r;const o=tq(e,null!==(r=this.s3Config.remotePrefix)&&void 0!==r?r:"");return yield this._writeFileFromRoot(o,t,i,n)}))}_writeFileFromRoot(e,t,i,n){return r(this,void 0,void 0,(function*(){if(void 0!==this.s3Config.remotePrefix&&""!==this.s3Config.remotePrefix&&!e.startsWith(this.s3Config.remotePrefix))throw Error("_writeFileFromRoot should only accept prefix-ed path");const r=new Uint8Array(t);let o=I;o=dh.contentType(dh.lookup(e)||I)||I;const s=new QN({client:this.s3Client,queueSize:this.s3Config.partsConcurrency,partSize:5242880,leavePartsOnError:!1,params:{Bucket:this.s3Config.s3BucketName,Key:e,Body:r,ContentType:o,Metadata:{MTime:""+i/1e3,CTime:""+n/1e3}}});return s.on("httpUploadProgress",(e=>{})),yield s.done(),yield this._statFromRoot(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){var t;if(e.endsWith("/"))throw new Error(`you should not call readFile on folder ${e}`);const r=tq(e,null!==(t=this.s3Config.remotePrefix)&&void 0!==t?t:"");return yield this._readFileFromRoot(r)}))}_readFileFromRoot(e){return r(this,void 0,void 0,(function*(){if(void 0!==this.s3Config.remotePrefix&&""!==this.s3Config.remotePrefix&&!e.startsWith(this.s3Config.remotePrefix))throw Error("_readFileFromRoot should only accept prefix-ed path");const t=yield this.s3Client.send(new RN({Bucket:this.s3Config.s3BucketName,Key:e})),i=yield(e=>r(void 0,void 0,void 0,(function*(){if(void 0===e)throw Error("ObjectBody is undefined and don't know how to deal with it");if(e instanceof Kx.Readable)return yield new Promise(((t,r)=>{const i=[];e.on("data",(e=>i.push(e))),e.on("error",r),e.on("end",(()=>t(qp(Wx.Buffer.concat(i)))))}));if(e instanceof ReadableStream)return yield new Response(e,{}).arrayBuffer();if(e instanceof Blob)return yield e.arrayBuffer();throw TypeError(`The type of ${e} is not one of the supported types`)})))(t.Body);return i}))}rename(e,t){return r(this,void 0,void 0,(function*(){throw Error("rename not implemented for s3")}))}rm(e){return r(this,void 0,void 0,(function*(){var t,r;if("/"!==e)if(e.endsWith("/")){if(this.synthFoldersCache.hasOwnProperty(e))return void delete this.synthFoldersCache[e];try{const r=tq(e,null!==(t=this.s3Config.remotePrefix)&&void 0!==t?t:"");yield this.s3Client.send(new PN({Bucket:this.s3Config.s3BucketName,Key:r}))}catch(e){}}else{const t=tq(e,null!==(r=this.s3Config.remotePrefix)&&void 0!==r?r:"");yield this.s3Client.send(new PN({Bucket:this.s3Config.s3BucketName,Key:t}))}}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{const e={Bucket:this.s3Config.s3BucketName},t=yield this.s3Client.send(new CN(e));if(void 0===t||void 0===t.$metadata||void 0===t.$metadata.httpStatusCode)throw Error("results or $metadata or httStatusCode is undefined");if(200!==t.$metadata.httpStatusCode)throw Error("not 200 httpStatusCode")}catch(t){if(console.debug(t),void 0!==e)if(this.s3Config.s3Endpoint.contains(this.s3Config.s3BucketName)){const r=new h([t,new Error("Maybe you've included the bucket name inside the endpoint setting. Please remove the bucket name and try again.")]);e(r)}else e(t);return!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}allowEmptyFile(){return!0}}var nq=__webpack_require__(19409),oq=__webpack_require__(26794),sq=__webpack_require__(21013),aq=__webpack_require__.n(sq),lq=__webpack_require__(35970),dq=__webpack_require__.n(lq),cq=__webpack_require__(65606),uq={2:e=>{function t(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var o=i(e,t,n);return o&&{start:o[0],end:o[1],pre:n.slice(0,o[0]),body:n.slice(o[0]+e.length,o[1]),post:n.slice(o[1]+t.length)}}function r(e,t){var r=t.match(e);return r?r[0]:null}function i(e,t,r){var i,n,o,s,a,l=r.indexOf(e),d=r.indexOf(t,l+1),c=l;if(l>=0&&d>0){for(i=[],o=r.length;c>=0&&!a;)c==l?(i.push(c),l=r.indexOf(e,c+1)):1==i.length?a=[i.pop(),d]:((n=i.pop())=0?l:d;i.length&&(a=[o,s])}return a}e.exports=t,t.range=i},101:function(e,t,r){var i;e=r.nmd(e),function(){var n=(e&&e.exports,"object"==typeof global&&global);n.global!==n&&n.window;var o=function(e){this.message=e};(o.prototype=new Error).name="InvalidCharacterError";var s=function(e){throw new o(e)},a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",l=/[\t\n\f\r ]/g,d={encode:function(e){e=String(e),/[^\0-\xFF]/.test(e)&&s("The string to be encoded contains characters outside of the Latin1 range.");for(var t,r,i,n,o=e.length%3,l="",d=-1,c=e.length-o;++d>18&63)+a.charAt(n>>12&63)+a.charAt(n>>6&63)+a.charAt(63&n);return 2==o?(t=e.charCodeAt(d)<<8,r=e.charCodeAt(++d),l+=a.charAt((n=t+r)>>10)+a.charAt(n>>4&63)+a.charAt(n<<2&63)+"="):1==o&&(n=e.charCodeAt(d),l+=a.charAt(n>>2)+a.charAt(n<<4&63)+"=="),l},decode:function(e){var t=(e=String(e).replace(l,"")).length;t%4==0&&(t=(e=e.replace(/==?$/,"")).length),(t%4==1||/[^+a-zA-Z0-9/]/.test(e))&&s("Invalid character: the string to be decoded is not correctly encoded.");for(var r,i,n=0,o="",d=-1;++d>(-2*n&6)));return o},version:"1.0.0"};void 0===(i=function(){return d}.call(t,r,t,e))||(e.exports=i)}()},172:(e,t)=>{t.d=function(e){if(!e)return 0;for(var t=(e=e.toString()).length,r=e.length;r--;){var i=e.charCodeAt(r);56320<=i&&i<=57343&&r--,127{var t={utf8:{stringToBytes:function(e){return t.bin.stringToBytes(unescape(encodeURIComponent(e)))},bytesToString:function(e){return decodeURIComponent(escape(t.bin.bytesToString(e)))}},bin:{stringToBytes:function(e){for(var t=[],r=0;r{var t,r;t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(e,t){return e<>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 16711935&r.rotl(e,8)|4278255360&r.rotl(e,24);for(var t=0;t0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],r=0,i=0;r>>5]|=e[r]<<24-i%32;return t},wordsToBytes:function(e){for(var t=[],r=0;r<32*e.length;r+=8)t.push(e[r>>>5]>>>24-r%32&255);return t},bytesToHex:function(e){for(var t=[],r=0;r>>4).toString(16)),t.push((15&e[r]).toString(16));return t.join("")},hexToBytes:function(e){for(var t=[],r=0;r>>6*(3-o)&63)):r.push("=");return r.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/gi,"");for(var r=[],i=0,n=0;i>>6-2*n);return r}},e.exports=r},635:(e,t,r)=>{const i=r(31),n=r(338),o=r(221);e.exports={XMLParser:n,XMLValidator:i,XMLBuilder:o}},705:(e,t)=>{const r=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i="["+r+"]["+r+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*",n=new RegExp("^"+i+"$");t.isExist=function(e){return void 0!==e},t.isEmptyObject=function(e){return 0===Object.keys(e).length},t.merge=function(e,t,r){if(t){const i=Object.keys(t),n=i.length;for(let o=0;o{const i=r(705),n={allowBooleanAttributes:!1,unpairedTags:[]};function o(e){return" "===e||"\t"===e||"\n"===e||"\r"===e}function s(e,t){const r=t;for(;t5&&"xml"===i)return f("InvalidXml","XML declaration allowed only at the start of the document.",g(e,t));if("?"==e[t]&&">"==e[t+1]){t++;break}}return t}function a(e,t){if(e.length>t+5&&"-"===e[t+1]&&"-"===e[t+2]){for(t+=3;t"===e[t+2]){t+=2;break}}else if(e.length>t+8&&"D"===e[t+1]&&"O"===e[t+2]&&"C"===e[t+3]&&"T"===e[t+4]&&"Y"===e[t+5]&&"P"===e[t+6]&&"E"===e[t+7]){let r=1;for(t+=8;t"===e[t]&&(r--,0===r))break}else if(e.length>t+9&&"["===e[t+1]&&"C"===e[t+2]&&"D"===e[t+3]&&"A"===e[t+4]&&"T"===e[t+5]&&"A"===e[t+6]&&"["===e[t+7])for(t+=8;t"===e[t+2]){t+=2;break}return t}t.validate=function(e,t){t=Object.assign({},n,t);const r=[];let l=!1,d=!1;"\ufeff"===e[0]&&(e=e.substr(1));for(let n=0;n"!==e[n]&&" "!==e[n]&&"\t"!==e[n]&&"\n"!==e[n]&&"\r"!==e[n];n++)v+=e[n];if(v=v.trim(),"/"===v[v.length-1]&&(v=v.substring(0,v.length-1),n--),u=v,!i.isName(u)){let t;return t=0===v.trim().length?"Invalid space after '<'.":"Tag '"+v+"' is an invalid name.",f("InvalidTag",t,g(e,n))}const b=c(e,n);if(!1===b)return f("InvalidAttr","Attributes for '"+v+"' have open quote.",g(e,n));let w=b.value;if(n=b.index,"/"===w[w.length-1]){const r=n-w.length;w=w.substring(0,w.length-1);const i=p(w,t);if(!0!==i)return f(i.err.code,i.err.msg,g(e,r+i.err.line));l=!0}else if(y){if(!b.tagClosed)return f("InvalidTag","Closing tag '"+v+"' doesn't have proper closing.",g(e,n));if(w.trim().length>0)return f("InvalidTag","Closing tag '"+v+"' can't have attributes or invalid starting.",g(e,m));if(0===r.length)return f("InvalidTag","Closing tag '"+v+"' has not been opened.",g(e,m));{const t=r.pop();if(v!==t.tagName){let r=g(e,t.tagStartPos);return f("InvalidTag","Expected closing tag '"+t.tagName+"' (opened in line "+r.line+", col "+r.col+") instead of closing tag '"+v+"'.",g(e,m))}0==r.length&&(d=!0)}}else{const i=p(w,t);if(!0!==i)return f(i.err.code,i.err.msg,g(e,n-w.length+i.err.line));if(!0===d)return f("InvalidXml","Multiple possible root nodes found.",g(e,n));-1!==t.unpairedTags.indexOf(v)||r.push({tagName:v,tagStartPos:m}),l=!0}for(n++;n0)||f("InvalidXml","Invalid '"+JSON.stringify(r.map((e=>e.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):f("InvalidXml","Start tag expected.",1)};const l='"',d="'";function c(e,t){let r="",i="",n=!1;for(;t"===e[t]&&""===i){n=!0;break}r+=e[t]}return""===i&&{value:r,index:t,tagClosed:n}}const u=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function p(e,t){const r=i.getAllMatches(e,u),n={};for(let e=0;e{const i=r(87),n={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function o(e){this.options=Object.assign({},n,e),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=l),this.processTextOrObjNode=s,this.options.format?(this.indentate=a,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function s(e,t,r){const i=this.j2x(e,r+1);return void 0!==e[this.options.textNodeName]&&1===Object.keys(e).length?this.buildTextValNode(e[this.options.textNodeName],t,i.attrStr,r):this.buildObjectNode(i.val,t,i.attrStr,r)}function a(e){return this.options.indentBy.repeat(e)}function l(e){return!(!e.startsWith(this.options.attributeNamePrefix)||e===this.options.textNodeName)&&e.substr(this.attrPrefixLen)}o.prototype.build=function(e){return this.options.preserveOrder?i(e,this.options):(Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(e={[this.options.arrayNodeName]:e}),this.j2x(e,0).val)},o.prototype.j2x=function(e,t){let r="",i="";for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n))if(void 0===e[n])this.isAttribute(n)&&(i+="");else if(null===e[n])this.isAttribute(n)?i+="":"?"===n[0]?i+=this.indentate(t)+"<"+n+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+n+"/"+this.tagEndChar;else if(e[n]instanceof Date)i+=this.buildTextValNode(e[n],n,"",t);else if("object"!=typeof e[n]){const o=this.isAttribute(n);if(o)r+=this.buildAttrPairStr(o,""+e[n]);else if(n===this.options.textNodeName){let t=this.options.tagValueProcessor(n,""+e[n]);i+=this.replaceEntitiesValue(t)}else i+=this.buildTextValNode(e[n],n,"",t)}else if(Array.isArray(e[n])){const r=e[n].length;let o="",s="";for(let a=0;a"+e+n}},o.prototype.closeTag=function(e){let t="";return-1!==this.options.unpairedTags.indexOf(e)?this.options.suppressUnpairedNode||(t="/"):t=this.options.suppressEmptyNode?"/":`>`+this.newLine;if(!1!==this.options.commentPropName&&t===this.options.commentPropName)return this.indentate(i)+`\x3c!--${e}--\x3e`+this.newLine;if("?"===t[0])return this.indentate(i)+"<"+t+r+"?"+this.tagEndChar;{let n=this.options.tagValueProcessor(t,e);return n=this.replaceEntitiesValue(n),""===n?this.indentate(i)+"<"+t+r+this.closeTag(t)+this.tagEndChar:this.indentate(i)+"<"+t+r+">"+n+"0&&this.options.processEntities)for(let t=0;t{function t(e,s,a,l){let d="",c=!1;for(let u=0;u`,c=!1;continue}if(h===s.commentPropName){d+=l+`\x3c!--${p[h][0][s.textNodeName]}--\x3e`,c=!0;continue}if("?"===h[0]){const e=i(p[":@"],s),t="?xml"===h?"":l;let r=p[h][0][s.textNodeName];r=0!==r.length?" "+r:"",d+=t+`<${h}${r}${e}?>`,c=!0;continue}let m=l;""!==m&&(m+=s.indentBy);const g=l+`<${h}${i(p[":@"],s)}`,y=t(p[h],s,f,m);-1!==s.unpairedTags.indexOf(h)?s.suppressUnpairedNode?d+=g+">":d+=g+"/>":y&&0!==y.length||!s.suppressEmptyNode?y&&y.endsWith(">")?d+=g+`>${y}${l}`:(d+=g+">",y&&""!==l&&(y.includes("/>")||y.includes("`):d+=g+"/>",c=!0}return d}function r(e){const t=Object.keys(e);for(let r=0;r0&&t.processEntities)for(let r=0;r0&&(i="\n"),t(e,r,"",i)}},193:(e,t,r)=>{const i=r(705);function n(e,t){let r="";for(;t"===e[t]){if(p?"-"===e[t-1]&&"-"===e[t-2]&&(p=!1,i--):i--,0===i)break}else"["===e[t]?u=!0:h+=e[t];else{if(u&&s(e,t))t+=7,[entityName,val,t]=n(e,t+1),-1===val.indexOf("&")&&(r[c(entityName)]={regx:RegExp(`&${entityName};`,"g"),val});else if(u&&a(e,t))t+=8;else if(u&&l(e,t))t+=8;else if(u&&d(e,t))t+=9;else{if(!o)throw new Error("Invalid DOCTYPE");p=!0}i++,h=""}if(0!==i)throw new Error("Unclosed DOCTYPE")}return{entities:r,i:t}}},63:(e,t)=>{const r={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(e,t,r){return e}};t.buildOptions=function(e){return Object.assign({},r,e)},t.defaultOptions=r},299:(e,t,r)=>{const i=r(705),n=r(365),o=r(193),s=r(494);function a(e){const t=Object.keys(e);for(let r=0;r0)){s||(e=this.replaceEntitiesValue(e));const i=this.options.tagValueProcessor(t,e,r,n,o);return null==i?e:typeof i!=typeof e||i!==e?i:this.options.trimValues||e.trim()===e?w(e,this.options.parseTagValue,this.options.numberParseOptions):e}}function d(e){if(this.options.removeNSPrefix){const t=e.split(":"),r="/"===e.charAt(0)?"/":"";if("xmlns"===t[0])return"";2===t.length&&(e=r+t[1])}return e}const c=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function u(e,t,r){if(!this.options.ignoreAttributes&&"string"==typeof e){const r=i.getAllMatches(e,c),n=r.length,o={};for(let e=0;e",a,"Closing Tag is not closed.");let n=e.substring(a+2,t).trim();if(this.options.removeNSPrefix){const e=n.indexOf(":");-1!==e&&(n=n.substr(e+1))}this.options.transformTagName&&(n=this.options.transformTagName(n)),r&&(i=this.saveTextToParentTag(i,r,s));const o=s.substring(s.lastIndexOf(".")+1);if(n&&-1!==this.options.unpairedTags.indexOf(n))throw new Error(`Unpaired tag can not be used as closing tag: `);let l=0;o&&-1!==this.options.unpairedTags.indexOf(o)?(l=s.lastIndexOf(".",s.lastIndexOf(".")-1),this.tagsNodeStack.pop()):l=s.lastIndexOf("."),s=s.substring(0,l),r=this.tagsNodeStack.pop(),i="",a=t}else if("?"===e[a+1]){let t=v(e,a,!1,"?>");if(!t)throw new Error("Pi Tag is not closed.");if(i=this.saveTextToParentTag(i,r,s),this.options.ignoreDeclaration&&"?xml"===t.tagName||this.options.ignorePiTags);else{const e=new n(t.tagName);e.add(this.options.textNodeName,""),t.tagName!==t.tagExp&&t.attrExpPresent&&(e[":@"]=this.buildAttributesMap(t.tagExp,s,t.tagName)),this.addChild(r,e,s)}a=t.closeIndex+1}else if("!--"===e.substr(a+1,3)){const t=y(e,"--\x3e",a+4,"Comment is not closed.");if(this.options.commentPropName){const n=e.substring(a+4,t-2);i=this.saveTextToParentTag(i,r,s),r.add(this.options.commentPropName,[{[this.options.textNodeName]:n}])}a=t}else if("!D"===e.substr(a+1,2)){const t=o(e,a);this.docTypeEntities=t.entities,a=t.i}else if("!["===e.substr(a+1,2)){const t=y(e,"]]>",a,"CDATA is not closed.")-2,n=e.substring(a+9,t);i=this.saveTextToParentTag(i,r,s);let o=this.parseTextData(n,r.tagname,s,!0,!1,!0,!0);null==o&&(o=""),this.options.cdataPropName?r.add(this.options.cdataPropName,[{[this.options.textNodeName]:n}]):r.add(this.options.textNodeName,o),a=t+2}else{let o=v(e,a,this.options.removeNSPrefix),l=o.tagName;const d=o.rawTagName;let c=o.tagExp,u=o.attrExpPresent,p=o.closeIndex;this.options.transformTagName&&(l=this.options.transformTagName(l)),r&&i&&"!xml"!==r.tagname&&(i=this.saveTextToParentTag(i,r,s,!1));const h=r;if(h&&-1!==this.options.unpairedTags.indexOf(h.tagname)&&(r=this.tagsNodeStack.pop(),s=s.substring(0,s.lastIndexOf("."))),l!==t.tagname&&(s+=s?"."+l:l),this.isItStopNode(this.options.stopNodes,s,l)){let t="";if(c.length>0&&c.lastIndexOf("/")===c.length-1)"/"===l[l.length-1]?(l=l.substr(0,l.length-1),s=s.substr(0,s.length-1),c=l):c=c.substr(0,c.length-1),a=o.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(l))a=o.closeIndex;else{const r=this.readStopNodeData(e,d,p+1);if(!r)throw new Error(`Unexpected end of ${d}`);a=r.i,t=r.tagContent}const i=new n(l);l!==c&&u&&(i[":@"]=this.buildAttributesMap(c,s,l)),t&&(t=this.parseTextData(t,l,s,!0,u,!0,!0)),s=s.substr(0,s.lastIndexOf(".")),i.add(this.options.textNodeName,t),this.addChild(r,i,s)}else{if(c.length>0&&c.lastIndexOf("/")===c.length-1){"/"===l[l.length-1]?(l=l.substr(0,l.length-1),s=s.substr(0,s.length-1),c=l):c=c.substr(0,c.length-1),this.options.transformTagName&&(l=this.options.transformTagName(l));const e=new n(l);l!==c&&u&&(e[":@"]=this.buildAttributesMap(c,s,l)),this.addChild(r,e,s),s=s.substr(0,s.lastIndexOf("."))}else{const e=new n(l);this.tagsNodeStack.push(r),l!==c&&u&&(e[":@"]=this.buildAttributesMap(c,s,l)),this.addChild(r,e,s),r=e}i="",a=p}}else i+=e[a];return t.child};function h(e,t,r){const i=this.options.updateTag(t.tagname,r,t[":@"]);!1===i||("string"==typeof i?(t.tagname=i,e.addChild(t)):e.addChild(t))}const f=function(e){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];e=e.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];e=e.replace(r.regex,r.val)}if(this.options.htmlEntities)for(let t in this.htmlEntities){const r=this.htmlEntities[t];e=e.replace(r.regex,r.val)}e=e.replace(this.ampEntity.regex,this.ampEntity.val)}return e};function m(e,t,r,i){return e&&(void 0===i&&(i=0===Object.keys(t.child).length),void 0!==(e=this.parseTextData(e,t.tagname,r,!1,!!t[":@"]&&0!==Object.keys(t[":@"]).length,i))&&""!==e&&t.add(this.options.textNodeName,e),e=""),e}function g(e,t,r){const i="*."+r;for(const r in e){const n=e[r];if(i===n||t===n)return!0}return!1}function y(e,t,r,i){const n=e.indexOf(t,r);if(-1===n)throw new Error(i);return n+t.length-1}function v(e,t,r){const i=function(e,t){let r,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:">",n="";for(let o=t;o3&&void 0!==arguments[3]?arguments[3]:">");if(!i)return;let n=i.data;const o=i.index,s=n.search(/\s/);let a=n,l=!0;-1!==s&&(a=n.substring(0,s),n=n.substring(s+1).trimStart());const d=a;if(r){const e=a.indexOf(":");-1!==e&&(a=a.substr(e+1),l=a!==i.data.substr(e+1))}return{tagName:a,tagExp:n,closeIndex:o,attrExpPresent:l,rawTagName:d}}function b(e,t,r){const i=r;let n=1;for(;r",r,`${t} is not closed`);if(e.substring(r+2,o).trim()===t&&(n--,0===n))return{tagContent:e.substring(i,r),i:o};r=o}else if("?"===e[r+1])r=y(e,"?>",r+1,"StopNode is not closed.");else if("!--"===e.substr(r+1,3))r=y(e,"--\x3e",r+3,"StopNode is not closed.");else if("!["===e.substr(r+1,2))r=y(e,"]]>",r,"StopNode is not closed.")-2;else{const i=v(e,r,">");i&&((i&&i.tagName)===t&&"/"!==i.tagExp[i.tagExp.length-1]&&n++,r=i.closeIndex)}}function w(e,t,r){if(t&&"string"==typeof e){const t=e.trim();return"true"===t||"false"!==t&&s(e,r)}return i.isExist(e)?e:""}e.exports=class{constructor(e){this.options=e,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(e,t)=>String.fromCharCode(Number.parseInt(t,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(e,t)=>String.fromCharCode(Number.parseInt(t,16))}},this.addExternalEntities=a,this.parseXml=p,this.parseTextData=l,this.resolveNameSpace=d,this.buildAttributesMap=u,this.isItStopNode=g,this.replaceEntitiesValue=f,this.readStopNodeData=b,this.saveTextToParentTag=m,this.addChild=h}}},338:(e,t,r)=>{const{buildOptions:i}=r(63),n=r(299),{prettify:o}=r(728),s=r(31);e.exports=class{constructor(e){this.externalEntities={},this.options=i(e)}parse(e,t){if("string"==typeof e);else{if(!e.toString)throw new Error("XML data is accepted in String or Bytes[] form.");e=e.toString()}if(t){!0===t&&(t={});const r=s.validate(e,t);if(!0!==r)throw Error(`${r.err.msg}:${r.err.line}:${r.err.col}`)}const r=new n(this.options);r.addExternalEntities(this.externalEntities);const i=r.parseXml(e);return this.options.preserveOrder||void 0===i?i:o(i,this.options)}addEntity(e,t){if(-1!==t.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==e.indexOf("&")||-1!==e.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");if("&"===t)throw new Error("An entity with value '&' is not permitted");this.externalEntities[e]=t}}},728:(e,t)=>{function r(e,t,s){let a;const l={};for(let d=0;d0&&(l[t.textNodeName]=a):void 0!==a&&(l[t.textNodeName]=a),l}function i(e){const t=Object.keys(e);for(let e=0;e{e.exports=class{constructor(e){this.tagname=e,this.child=[],this[":@"]={}}add(e,t){"__proto__"===e&&(e="#__proto__"),this.child.push({[e]:t})}addChild(e){"__proto__"===e.tagname&&(e.tagname="#__proto__"),e[":@"]&&Object.keys(e[":@"]).length>0?this.child.push({[e.tagname]:e.child,":@":e[":@"]}):this.child.push({[e.tagname]:e.child})}}},135:e=>{function t(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}e.exports=function(e){return null!=e&&(t(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&t(e.slice(0,0))}(e)||!!e._isBuffer)}},542:(e,t,r)=>{!function(){var t=r(298),i=r(526).utf8,n=r(135),o=r(526).bin,s=function(e,r){e.constructor==String?e=r&&"binary"===r.encoding?o.stringToBytes(e):i.stringToBytes(e):n(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var a=t.bytesToWords(e),l=8*e.length,d=1732584193,c=-271733879,u=-1732584194,p=271733878,h=0;h>>24)|4278255360&(a[h]<<24|a[h]>>>8);a[l>>>5]|=128<>>9<<4)]=l;var f=s._ff,m=s._gg,g=s._hh,y=s._ii;for(h=0;h>>0,c=c+b>>>0,u=u+w>>>0,p=p+_>>>0}return t.endian([d,c,u,p])};s._ff=function(e,t,r,i,n,o,s){var a=e+(t&r|~t&i)+(n>>>0)+s;return(a<>>32-o)+t},s._gg=function(e,t,r,i,n,o,s){var a=e+(t&i|r&~i)+(n>>>0)+s;return(a<>>32-o)+t},s._hh=function(e,t,r,i,n,o,s){var a=e+(t^r^i)+(n>>>0)+s;return(a<>>32-o)+t},s._ii=function(e,t,r,i,n,o,s){var a=e+(r^(t|~i))+(n>>>0)+s;return(a<>>32-o)+t},s._blocksize=16,s._digestsize=16,e.exports=function(e,r){if(null==e)throw new Error("Illegal argument "+e);var i=t.wordsToBytes(s(e,r));return r&&r.asBytes?i:r&&r.asString?o.bytesToString(i):t.bytesToHex(i)}}()},285:(e,t,r)=>{var i=r(2);e.exports=function(e){return e?("{}"===e.substr(0,2)&&(e="\\{\\}"+e.substr(2)),g(function(e){return e.split("\\\\").join(n).split("\\{").join(o).split("\\}").join(s).split("\\,").join(a).split("\\.").join(l)}(e),!0).map(c)):[]};var n="\0SLASH"+Math.random()+"\0",o="\0OPEN"+Math.random()+"\0",s="\0CLOSE"+Math.random()+"\0",a="\0COMMA"+Math.random()+"\0",l="\0PERIOD"+Math.random()+"\0";function d(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function c(e){return e.split(n).join("\\").split(o).join("{").split(s).join("}").split(a).join(",").split(l).join(".")}function u(e){if(!e)return[""];var t=[],r=i("{","}",e);if(!r)return e.split(",");var n=r.pre,o=r.body,s=r.post,a=n.split(",");a[a.length-1]+="{"+o+"}";var l=u(s);return s.length&&(a[a.length-1]+=l.shift(),a.push.apply(a,l)),t.push.apply(t,a),t}function p(e){return"{"+e+"}"}function h(e){return/^-?0\d/.test(e)}function f(e,t){return e<=t}function m(e,t){return e>=t}function g(e,t){var r=[],n=i("{","}",e);if(!n)return[e];var o=n.pre,a=n.post.length?g(n.post,!1):[""];if(/\$$/.test(n.pre))for(var l=0;l=0;if(!_&&!x)return n.post.match(/,.*\}/)?g(e=n.pre+"{"+n.body+s+n.post):[e];if(_)y=n.body.split(/\.\./);else if(1===(y=u(n.body)).length&&1===(y=g(y[0],!1).map(p)).length)return a.map((function(e){return n.pre+y[0]+e}));if(_){var S=d(y[0]),k=d(y[1]),E=Math.max(y[0].length,y[1].length),T=3==y.length?Math.abs(d(y[2])):1,B=f;k0){var M=new Array(F+1).join("0");A=I<0?"-"+M+A.slice(1):M+A}}v.push(A)}}else{v=[];for(var D=0;D{function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function r(e){var t="function"==typeof Map?new Map:void 0;return r=function(e){if(null===e||(r=e,-1===Function.toString.call(r).indexOf("[native code]")))return e;var r;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,s)}function s(){return i(e,arguments,o(this).constructor)}return s.prototype=Object.create(e.prototype,{constructor:{value:s,enumerable:!1,writable:!0,configurable:!0}}),n(s,e)},r(e)}function i(e,t,r){return i=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}()?Reflect.construct:function(e,t,r){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return r&&n(o,r.prototype),o},i.apply(null,arguments)}function n(e,t){return n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},n(e,t)}function o(e){return o=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},o(e)}var s=function(e){function r(e){var i;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),(i=function(e,r){return!r||"object"!==t(r)&&"function"!=typeof r?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):r}(this,o(r).call(this,e))).name="ObjectPrototypeMutationError",i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&n(e,t)}(r,e),r}(r(Error));function a(e,r){for(var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:function(){},n=r.split("."),o=n.length,s=function(t){var r=n[t];if(!e)return{v:void 0};if("+"===r){if(Array.isArray(e))return{v:e.map((function(r,o){var s=n.slice(t+1);return s.length>0?a(r,s.join("."),i):i(e,o,n,t)}))};var o=n.slice(0,t).join(".");throw new Error("Object at wildcard (".concat(o,") is not an array"))}e=i(e,r,n,t)},l=0;l2&&void 0!==arguments[2]?arguments[2]:{};if("object"!=t(e)||null===e)return!1;if(void 0===r)return!1;if("number"==typeof r)return r in e;try{var n=!1;return a(e,r,(function(e,t,r,o){if(!l(r,o))return e&&e[t];n=i.own?e.hasOwnProperty(t):t in e})),n}catch(e){return!1}},hasOwn:function(e,t,r){return this.has(e,t,r||{own:!0})},isIn:function(e,r,i){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};if("object"!=t(e)||null===e)return!1;if(void 0===r)return!1;try{var o=!1,s=!1;return a(e,r,(function(e,r,n,a){return o=o||e===i||!!e&&e[r]===i,s=l(n,a)&&"object"===t(e)&&r in e,e&&e[r]})),n.validPath?o&&s:o}catch(e){return!1}},ObjectPrototypeMutationError:s}},47:(e,t,r)=>{var i=r(410),n=function(e){return"string"==typeof e};function o(e,t){for(var r=[],i=0;i=-1&&!t;r--){var i=r>=0?arguments[r]:cq.cwd();if(!n(i))throw new TypeError("Arguments to path.resolve must be strings");i&&(e=i+"/"+e,t="/"===i.charAt(0))}return(t?"/":"")+(e=o(e.split("/"),!t).join("/"))||"."},a.normalize=function(e){var t=a.isAbsolute(e),r="/"===e.substr(-1);return(e=o(e.split("/"),!t).join("/"))||t||(e="."),e&&r&&(e+="/"),(t?"/":"")+e},a.isAbsolute=function(e){return"/"===e.charAt(0)},a.join=function(){for(var e="",t=0;t=0&&""===e[r];r--);return t>r?[]:e.slice(t,r+1)}e=a.resolve(e).substr(1),t=a.resolve(t).substr(1);for(var i=r(e.split("/")),n=r(t.split("/")),o=Math.min(i.length,n.length),s=o,l=0;l{var r=Object.prototype.hasOwnProperty;function i(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(e){return null}}function n(e){try{return encodeURIComponent(e)}catch(e){return null}}t.stringify=function(e,t){t=t||"";var i,o,s=[];for(o in"string"!=typeof t&&(t="?"),e)if(r.call(e,o)){if((i=e[o])||null!=i&&!isNaN(i)||(i=""),o=n(o),i=n(i),null===o||null===i)continue;s.push(o+"="+i)}return s.length?t+s.join("&"):""},t.parse=function(e){for(var t,r=/([^=?#&]+)=?([^&]*)/g,n={};t=r.exec(e);){var o=i(t[1]),s=i(t[2]);null===o||null===s||o in n||(n[o]=s)}return n}},670:e=>{e.exports=function(e,t){if(t=t.split(":")[0],!(e=+e))return!1;switch(t){case"http":case"ws":return 80!==e;case"https":case"wss":return 443!==e;case"ftp":return 21!==e;case"gopher":return 70!==e;case"file":return!1}return 0!==e}},494:e=>{const t=/^[-+]?0x[a-fA-F0-9]+$/,r=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const i={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};e.exports=function(e){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(n=Object.assign({},i,n),!e||"string"!=typeof e)return e;let o=e.trim();if(void 0!==n.skipLike&&n.skipLike.test(o))return e;if(n.hex&&t.test(o))return Number.parseInt(o,16);{const t=r.exec(o);if(t){const r=t[1],i=t[2];let a=(s=t[3])&&-1!==s.indexOf(".")?("."===(s=s.replace(/0+$/,""))?s="0":"."===s[0]?s="0"+s:"."===s[s.length-1]&&(s=s.substr(0,s.length-1)),s):s;const l=t[4]||t[6];if(!n.leadingZeros&&i.length>0&&r&&"."!==o[2])return e;if(!n.leadingZeros&&i.length>0&&!r&&"."!==o[1])return e;{const t=Number(o),s=""+t;return-1!==s.search(/[eE]/)||l?n.eNotation?t:e:-1!==o.indexOf(".")?"0"===s&&""===a||s===a||r&&s==="-"+a?t:e:i?a===s||r+a===s?t:e:o===s||o===r+s?t:e}}return e}var s}},737:(e,t,r)=>{var i=r(670),n=r(647),o=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,s=/[\n\r\t]/g,a=/^[A-Za-z][A-Za-z0-9+-.]*:\/\//,l=/:\d+$/,d=/^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i,c=/^[a-zA-Z]:/;function u(e){return(e||"").toString().replace(o,"")}var p=[["#","hash"],["?","query"],function(e,t){return m(t.protocol)?e.replace(/\\/g,"/"):e},["/","pathname"],["@","auth",1],[NaN,"host",void 0,1,1],[/:(\d*)$/,"port",void 0,1],[NaN,"hostname",void 0,1,1]],h={hash:1,query:1};function f(e){var t,r=("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{}).location||{},i={},n=typeof(e=e||r);if("blob:"===e.protocol)i=new y(unescape(e.pathname),{});else if("string"===n)for(t in i=new y(e,{}),h)delete i[t];else if("object"===n){for(t in e)t in h||(i[t]=e[t]);void 0===i.slashes&&(i.slashes=a.test(e.href))}return i}function m(e){return"file:"===e||"ftp:"===e||"http:"===e||"https:"===e||"ws:"===e||"wss:"===e}function g(e,t){e=(e=u(e)).replace(s,""),t=t||{};var r,i=d.exec(e),n=i[1]?i[1].toLowerCase():"",o=!!i[2],a=!!i[3],l=0;return o?a?(r=i[2]+i[3]+i[4],l=i[2].length+i[3].length):(r=i[2]+i[4],l=i[2].length):a?(r=i[3]+i[4],l=i[3].length):r=i[4],"file:"===n?l>=2&&(r=r.slice(2)):m(n)?r=i[4]:n?o&&(r=r.slice(2)):l>=2&&m(t.protocol)&&(r=i[4]),{protocol:n,slashes:o||m(n),slashesCount:l,rest:r}}function y(e,t,r){if(e=(e=u(e)).replace(s,""),!(this instanceof y))return new y(e,t,r);var o,a,l,d,h,v,b=p.slice(),w=typeof t,_=this,x=0;for("object"!==w&&"string"!==w&&(r=t,t=null),r&&"function"!=typeof r&&(r=n.parse),o=!(a=g(e||"",t=f(t))).protocol&&!a.slashes,_.slashes=a.slashes||o&&t.slashes,_.protocol=a.protocol||t.protocol||"",e=a.rest,("file:"===a.protocol&&(2!==a.slashesCount||c.test(e))||!a.slashes&&(a.protocol||a.slashesCount<2||!m(_.protocol)))&&(b[3]=[/(.*)/,"pathname"]);x{},388:()=>{},805:()=>{},345:()=>{},800:()=>{}},pq={};function hq(e){var t=pq[e];if(void 0!==t)return t.exports;var r=pq[e]={id:e,loaded:!1,exports:{}};return uq[e].call(r.exports,r,r.exports,hq),r.loaded=!0,r.exports}hq.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return hq.d(t,{a:t}),t},hq.d=(e,t)=>{for(var r in t)hq.o(t,r)&&!hq.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},hq.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),hq.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var fq={};hq.d(fq,{hT:()=>Lq,O4:()=>jq,Kd:()=>qq,YK:()=>Uq,UU:()=>uj,Gu:()=>Jq,ky:()=>fL,h4:()=>pL,ch:()=>hL,hq:()=>nL,i5:()=>mL});var mq=hq(737),gq=hq.n(mq);function yq(e){if(!vq(e))throw new Error("Parameter was not an error")}function vq(e){return!!e&&"object"==typeof e&&"[object Error]"===(t=e,Object.prototype.toString.call(t))||e instanceof Error;var t}class bq extends Error{constructor(e,t){const r=[...arguments],{options:i,shortMessage:n}=function(e){let t,r="";if(0===e.length)t={};else if(vq(e[0]))t={cause:e[0]},r=e.slice(1).join(" ")||"";else if(e[0]&&"object"==typeof e[0])t=Object.assign({},e[0]),r=e.slice(1).join(" ")||"";else{if("string"!=typeof e[0])throw new Error("Invalid arguments passed to Layerr");t={},r=r=e.join(" ")||""}return{options:t,shortMessage:r}}(r);let o=n;if(i.cause&&(o=`${o}: ${i.cause.message}`),super(o),this.message=o,i.name&&"string"==typeof i.name?this.name=i.name:this.name="Layerr",i.cause&&Object.defineProperty(this,"_cause",{value:i.cause}),Object.defineProperty(this,"_info",{value:{}}),i.info&&"object"==typeof i.info&&Object.assign(this._info,i.info),Error.captureStackTrace){const e=i.constructorOpt||this.constructor;Error.captureStackTrace(this,e)}}static cause(e){return yq(e),e._cause&&vq(e._cause)?e._cause:null}static fullStack(e){yq(e);const t=bq.cause(e);return t?`${e.stack}\ncaused by: ${bq.fullStack(t)}`:e.stack??""}static info(e){yq(e);const t={},r=bq.cause(e);return r&&Object.assign(t,bq.info(r)),e._info&&Object.assign(t,e._info),t}toString(){let e=this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(e=`${e}: ${this.message}`),e}}var wq=hq(47),_q=hq.n(wq);const xq="__PATH_SEPARATOR_POSIX__",Sq="__PATH_SEPARATOR_WINDOWS__";function kq(e){try{const t=e.replace(/\//g,xq).replace(/\\\\/g,Sq);return encodeURIComponent(t).split(Sq).join("\\\\").split(xq).join("/")}catch(e){throw new bq(e,"Failed encoding path")}}function Eq(e){return e.startsWith("/")?e:"/"+e}function Tq(e){let t=e;return"/"!==t[0]&&(t="/"+t),/^.+\/$/.test(t)&&(t=t.substr(0,t.length-1)),t}function Bq(e){let t=new(gq())(e).pathname;return t.length<=0&&(t="/"),Tq(t)}function Cq(){for(var e=arguments.length,t=new Array(e),r=0;r1){var r=e.shift();e[0]=r+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var i=0;i0&&(n=n.replace(/^[\/]+/,"")),n=i0?"?":"")+s.join("&")}("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}(t.reduce(((e,t,r)=>((0===r||"/"!==t||"/"===t&&"/"!==e[e.length-1])&&e.push(t),e)),[]))}var Iq=hq(542),Aq=hq.n(Iq);function Fq(e,t){const r=e.url.replace("//",""),i=-1==r.indexOf("/")?"/":r.slice(r.indexOf("/")),n=e.method?e.method.toUpperCase():"GET",o=!!/(^|,)\s*auth\s*($|,)/.test(t.qop)&&"auth",s=`00000000${t.nc}`.slice(-8),a=function(e,t,r,i,n,o,s){const a=s||Aq()(`${t}:${r}:${i}`);return e&&"md5-sess"===e.toLowerCase()?Aq()(`${a}:${n}:${o}`):a}(t.algorithm,t.username,t.realm,t.password,t.nonce,t.cnonce,t.ha1),l=Aq()(`${n}:${i}`),d=o?Aq()(`${a}:${t.nonce}:${s}:${t.cnonce}:${o}:${l}`):Aq()(`${a}:${t.nonce}:${l}`),c={username:t.username,realm:t.realm,nonce:t.nonce,uri:i,qop:o,response:d,nc:s,cnonce:t.cnonce,algorithm:t.algorithm,opaque:t.opaque},u=[];for(const e in c)c[e]&&("qop"===e||"nc"===e||"algorithm"===e?u.push(`${e}=${c[e]}`):u.push(`${e}="${c[e]}"`));return`Digest ${u.join(", ")}`}function Mq(e){return"digest"===(e.headers&&e.headers.get("www-authenticate")||"").split(/\s/)[0].toLowerCase()}var Dq=hq(101),Rq=hq.n(Dq);function Pq(e){return Rq().decode(e)}function Oq(e,t){var r;return`Basic ${r=`${e}:${t}`,Rq().encode(r)}`}const zq="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:"undefined"!=typeof window?window:globalThis,Nq=zq.fetch.bind(zq),qq=(zq.Headers,zq.Request),Uq=zq.Response;let Lq=function(e){return e.Auto="auto",e.Digest="digest",e.None="none",e.Password="password",e.Token="token",e}({}),jq=function(e){return e.DataTypeNoLength="data-type-no-length",e.InvalidAuthType="invalid-auth-type",e.InvalidOutputFormat="invalid-output-format",e.LinkUnsupportedAuthType="link-unsupported-auth",e.InvalidUpdateRange="invalid-update-range",e.NotSupported="not-supported",e}({});function Hq(e,t,r,i,n){switch(e.authType){case Lq.Auto:t&&r&&(e.headers.Authorization=Oq(t,r));break;case Lq.Digest:e.digest=function(e,t,r){return{username:e,password:t,ha1:r,nc:0,algorithm:"md5",hasDigestAuth:!1}}(t,r,n);break;case Lq.None:break;case Lq.Password:e.headers.Authorization=Oq(t,r);break;case Lq.Token:e.headers.Authorization=`${(o=i).token_type} ${o.access_token}`;break;default:throw new bq({info:{code:jq.InvalidAuthType}},`Invalid auth type: ${e.authType}`)}var o}hq(345),hq(800);const $q="@@HOTPATCHER",Gq=()=>{};function Wq(e){return{original:e,methods:[e],final:!1}}class Kq{constructor(){this._configuration={registry:{},getEmptyAction:"null"},this.__type__=$q}get configuration(){return this._configuration}get getEmptyAction(){return this.configuration.getEmptyAction}set getEmptyAction(e){this.configuration.getEmptyAction=e}control(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e||e.__type__!==$q)throw new Error("Failed taking control of target HotPatcher instance: Invalid type or object");return Object.keys(e.configuration.registry).forEach((r=>{this.configuration.registry.hasOwnProperty(r)?t&&(this.configuration.registry[r]=Object.assign({},e.configuration.registry[r])):this.configuration.registry[r]=Object.assign({},e.configuration.registry[r])})),e._configuration=this.configuration,this}execute(e){const t=this.get(e)||Gq;for(var r=arguments.length,i=new Array(r>1?r-1:0),n=1;n0;)n=[t.shift().apply(o,n)];return n[0]}}(...t.methods)}isPatched(e){return!!this.configuration.registry[e]}patch(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{chain:i=!1}=r;if(this.configuration.registry[e]&&this.configuration.registry[e].final)throw new Error(`Failed patching '${e}': Method marked as being final`);if("function"!=typeof t)throw new Error(`Failed patching '${e}': Provided method is not a function`);if(i)this.configuration.registry[e]?this.configuration.registry[e].methods.push(t):this.configuration.registry[e]=Wq(t);else if(this.isPatched(e)){const{original:r}=this.configuration.registry[e];this.configuration.registry[e]=Object.assign(Wq(t),{original:r})}else this.configuration.registry[e]=Wq(t);return this}patchInline(e,t){this.isPatched(e)||this.patch(e,t);for(var r=arguments.length,i=new Array(r>2?r-2:0),n=2;n1?t-1:0),i=1;i{this.patch(e,t,{chain:!0})})),this}restore(e){if(!this.isPatched(e))throw new Error(`Failed restoring method: No method present for key: ${e}`);if("function"!=typeof this.configuration.registry[e].original)throw new Error(`Failed restoring method: Original method not found or of invalid type for key: ${e}`);return this.configuration.registry[e].methods=[this.configuration.registry[e].original],this}setFinal(e){if(!this.configuration.registry.hasOwnProperty(e))throw new Error(`Failed marking '${e}' as final: No method found for key`);return this.configuration.registry[e].final=!0,this}}let Vq=null;function Jq(){return Vq||(Vq=new Kq),Vq}function Yq(e){return function(e){if("object"!=typeof e||null===e||"[object Object]"!=Object.prototype.toString.call(e))return!1;if(null===Object.getPrototypeOf(e))return!0;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}(e)?Object.assign({},e):Object.setPrototypeOf(Object.assign({},e),Object.getPrototypeOf(e))}function Qq(){for(var e=arguments.length,t=new Array(e),r=0;r0;){const e=n.shift();i=i?Zq(i,e):Yq(e)}return i}function Zq(e,t){const r=Yq(e);return Object.keys(t).forEach((e=>{r.hasOwnProperty(e)?Array.isArray(t[e])?r[e]=Array.isArray(r[e])?[...r[e],...t[e]]:[...t[e]]:"object"==typeof t[e]&&t[e]?r[e]="object"==typeof r[e]&&r[e]?Zq(r[e],t[e]):Yq(t[e]):r[e]=t[e]:r[e]=t[e]})),r}function Xq(e){const t={};for(const r of e.keys())t[r]=e.get(r);return t}function eU(){for(var e=arguments.length,t=new Array(e),r=0;r(Object.keys(t).forEach((r=>{const n=r.toLowerCase();i.hasOwnProperty(n)?e[i[n]]=t[r]:(i[n]=r,e[r]=t[r])})),e)),{})}hq(805);const tU="function"==typeof ArrayBuffer,{toString:rU}=Object.prototype;function iU(e){return tU&&(e instanceof ArrayBuffer||"[object ArrayBuffer]"===rU.call(e))}function nU(e){return null!=e&&null!=e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function oU(e){return function(){for(var t=[],r=0;rt.patchInline("fetch",Nq,e.url,function(e){let t={};const r={method:e.method};if(e.headers&&(t=eU(t,e.headers)),void 0!==e.data){const[i,n]=function(e){if("string"==typeof e)return[e,{}];if(nU(e))return[e,{}];if(iU(e))return[e,{}];if(e&&"object"==typeof e)return[JSON.stringify(e),{"content-type":"application/json"}];throw new Error("Unable to convert request body: Unexpected body type: "+typeof e)}(e.data);r.body=i,t=eU(t,n)}return e.signal&&(r.signal=e.signal),e.withCredentials&&(r.credentials="include"),r.headers=t,r}(e))),e)}var pU=hq(285);const hU=e=>{if("string"!=typeof e)throw new TypeError("invalid pattern");if(e.length>65536)throw new TypeError("pattern is too long")},fU={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},mU=e=>e.replace(/[[\]\\-]/g,"\\$&"),gU=e=>e.join(""),yU=(e,t)=>{const r=t;if("["!==e.charAt(r))throw new Error("not in a brace expression");const i=[],n=[];let o=r+1,s=!1,a=!1,l=!1,d=!1,c=r,u="";e:for(;ou?i.push(mU(u)+"-"+mU(t)):t===u&&i.push(mU(t)),u="",o++):e.startsWith("-]",o+1)?(i.push(mU(t+"-")),o+=2):e.startsWith("-",o+1)?(u=t,o+=2):(i.push(mU(t)),o++)}else l=!0,o++}else d=!0,o++}if(c1&&void 0!==arguments[1]?arguments[1]:{};return t?e.replace(/\[([^\/\\])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1")},bU=new Set(["!","?","+","*","@"]),wU=e=>bU.has(e),_U="(?!\\.)",xU=new Set(["[","."]),SU=new Set(["..","."]),kU=new Set("().*{}+?[]^$\\!"),EU="[^/]",TU=EU+"*?",BU=EU+"+?";class CU{type;#T;#B;#C=!1;#I=[];#A;#F;#M;#D=!1;#R;#P;#O=!1;constructor(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.type=e,e&&(this.#B=!0),this.#A=t,this.#T=this.#A?this.#A.#T:this,this.#R=this.#T===this?r:this.#T.#R,this.#M=this.#T===this?[]:this.#T.#M,"!"!==e||this.#T.#D||this.#M.push(this),this.#F=this.#A?this.#A.#I.length:0}get hasMagic(){if(void 0!==this.#B)return this.#B;for(const e of this.#I)if("string"!=typeof e&&(e.type||e.hasMagic))return this.#B=!0;return this.#B}toString(){return void 0!==this.#P?this.#P:this.type?this.#P=this.type+"("+this.#I.map((e=>String(e))).join("|")+")":this.#P=this.#I.map((e=>String(e))).join("")}#z(){if(this!==this.#T)throw new Error("should only call on root");if(this.#D)return this;let e;for(this.toString(),this.#D=!0;e=this.#M.pop();){if("!"!==e.type)continue;let t=e,r=t.#A;for(;r;){for(let i=t.#F+1;!r.type&&i"string"==typeof e?e:e.toJSON())):[this.type,...this.#I.map((e=>e.toJSON()))];return this.isStart()&&!this.type&&e.unshift([]),this.isEnd()&&(this===this.#T||this.#T.#D&&"!"===this.#A?.type)&&e.push({}),e}isStart(){if(this.#T===this)return!0;if(!this.#A?.isStart())return!1;if(0===this.#F)return!0;const e=this.#A;for(let t=0;t1&&void 0!==arguments[1]?arguments[1]:{};const r=new CU(null,void 0,t);return CU.#N(e,r,0,t),r}toMMPattern(){if(this!==this.#T)return this.#T.toMMPattern();const e=this.toString(),[t,r,i,n]=this.toRegExpSource();if(!(i||this.#B||this.#R.nocase&&!this.#R.nocaseMagicOnly&&e.toUpperCase()!==e.toLowerCase()))return r;const o=(this.#R.nocase?"i":"")+(n?"u":"");return Object.assign(new RegExp(`^${t}$`,o),{_src:t,_glob:e})}get options(){return this.#R}toRegExpSource(e){const t=e??!!this.#R.dot;if(this.#T===this&&this.#z(),!this.type){const r=this.isStart()&&this.isEnd(),i=this.#I.map((t=>{const[i,n,o,s]="string"==typeof t?CU.#q(t,this.#B,r):t.toRegExpSource(e);return this.#B=this.#B||o,this.#C=this.#C||s,i})).join("");let n="";if(this.isStart()&&"string"==typeof this.#I[0]&&(1!==this.#I.length||!SU.has(this.#I[0]))){const r=xU,o=t&&r.has(i.charAt(0))||i.startsWith("\\.")&&r.has(i.charAt(2))||i.startsWith("\\.\\.")&&r.has(i.charAt(4)),s=!t&&!e&&r.has(i.charAt(0));n=o?"(?!(?:^|/)\\.\\.?(?:$|/))":s?_U:""}let o="";return this.isEnd()&&this.#T.#D&&"!"===this.#A?.type&&(o="(?:$|\\/)"),[n+i+o,vU(i),this.#B=!!this.#B,this.#C]}const r="*"===this.type||"+"===this.type,i="!"===this.type?"(?:(?!(?:":"(?:";let n=this.#U(t);if(this.isStart()&&this.isEnd()&&!n&&"!"!==this.type){const e=this.toString();return this.#I=[e],this.type=null,this.#B=void 0,[e,vU(this.toString()),!1,!1]}let o=!r||e||t?"":this.#U(!0);o===n&&(o=""),o&&(n=`(?:${n})(?:${o})*?`);let s="";return s="!"===this.type&&this.#O?(this.isStart()&&!t?_U:"")+BU:i+n+("!"===this.type?"))"+(!this.isStart()||t||e?"":_U)+TU+")":"@"===this.type?")":"?"===this.type?")?":"+"===this.type&&o?")":"*"===this.type&&o?")?":`)${this.type}`),[s,vU(n),this.#B=!!this.#B,this.#C]}#U(e){return this.#I.map((t=>{if("string"==typeof t)throw new Error("string type in extglob ast??");const[r,i,n,o]=t.toRegExpSource(e);return this.#C=this.#C||o,r})).filter((e=>!(this.isStart()&&this.isEnd()&&!e))).join("|")}static#q(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=!1,n="",o=!1;for(let s=0;s2&&void 0!==arguments[2]?arguments[2]:{};return hU(t),!(!r.nocomment&&"#"===t.charAt(0))&&new tL(t,r).match(e)},AU=/^\*+([^+@!?\*\[\(]*)$/,FU=e=>t=>!t.startsWith(".")&&t.endsWith(e),MU=e=>t=>t.endsWith(e),DU=e=>(e=e.toLowerCase(),t=>!t.startsWith(".")&&t.toLowerCase().endsWith(e)),RU=e=>(e=e.toLowerCase(),t=>t.toLowerCase().endsWith(e)),PU=/^\*+\.\*+$/,OU=e=>!e.startsWith(".")&&e.includes("."),zU=e=>"."!==e&&".."!==e&&e.includes("."),NU=/^\.\*+$/,qU=e=>"."!==e&&".."!==e&&e.startsWith("."),UU=/^\*+$/,LU=e=>0!==e.length&&!e.startsWith("."),jU=e=>0!==e.length&&"."!==e&&".."!==e,HU=/^\?+([^+@!?\*\[\(]*)?$/,$U=e=>{let[t,r=""]=e;const i=VU([t]);return r?(r=r.toLowerCase(),e=>i(e)&&e.toLowerCase().endsWith(r)):i},GU=e=>{let[t,r=""]=e;const i=JU([t]);return r?(r=r.toLowerCase(),e=>i(e)&&e.toLowerCase().endsWith(r)):i},WU=e=>{let[t,r=""]=e;const i=JU([t]);return r?e=>i(e)&&e.endsWith(r):i},KU=e=>{let[t,r=""]=e;const i=VU([t]);return r?e=>i(e)&&e.endsWith(r):i},VU=e=>{let[t]=e;const r=t.length;return e=>e.length===r&&!e.startsWith(".")},JU=e=>{let[t]=e;const r=t.length;return e=>e.length===r&&"."!==e&&".."!==e},YU="object"==typeof cq&&cq?"object"==typeof cq.env&&cq.env&&cq.env.__MINIMATCH_TESTING_PLATFORM__||cq.platform:"posix";IU.sep="win32"===YU?"\\":"/";const QU=Symbol("globstar **");IU.GLOBSTAR=QU,IU.filter=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return r=>IU(r,e,t)};const ZU=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Object.assign({},e,t)};IU.defaults=e=>{if(!e||"object"!=typeof e||!Object.keys(e).length)return IU;const t=IU;return Object.assign((function(r,i){return t(r,i,ZU(e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}))}),{Minimatch:class extends t.Minimatch{constructor(t){super(t,ZU(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}))}static defaults(r){return t.defaults(ZU(e,r)).Minimatch}},AST:class extends t.AST{constructor(t,r){super(t,r,ZU(e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}))}static fromGlob(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.AST.fromGlob(r,ZU(e,i))}},unescape:function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.unescape(r,ZU(e,i))},escape:function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.escape(r,ZU(e,i))},filter:function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.filter(r,ZU(e,i))},defaults:r=>t.defaults(ZU(e,r)),makeRe:function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.makeRe(r,ZU(e,i))},braceExpand:function(r){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t.braceExpand(r,ZU(e,i))},match:function(r,i){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t.match(r,i,ZU(e,n))},sep:t.sep,GLOBSTAR:QU})};const XU=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return hU(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:pU(e)};IU.braceExpand=XU,IU.makeRe=function(e){return new tL(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).makeRe()},IU.match=function(e,t){const r=new tL(t,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{});return e=e.filter((e=>r.match(e))),r.options.nonull&&!e.length&&e.push(t),e};const eL=/[?*]|[+@!]\(.*?\)|\[|\]/;class tL{options;set;pattern;windowsPathsNoEscape;nonegate;negate;comment;empty;preserveMultipleSlashes;partial;globSet;globParts;nocase;isWindows;platform;windowsNoMagicRoot;regexp;constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};hU(e),t=t||{},this.options=t,this.pattern=e,this.platform=t.platform||YU,this.isWindows="win32"===this.platform,this.windowsPathsNoEscape=!!t.windowsPathsNoEscape||!1===t.allowWindowsEscape,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!t.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!t.nonegate,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=void 0!==t.windowsNoMagicRoot?t.windowsNoMagicRoot:!(!this.isWindows||!this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;for(const e of this.set)for(const t of e)if("string"!=typeof t)return!0;return!1}debug(){}make(){const e=this.pattern,t=this.options;if(!t.nocomment&&"#"===e.charAt(0))return void(this.comment=!0);if(!e)return void(this.empty=!0);this.parseNegate(),this.globSet=[...new Set(this.braceExpand())],t.debug&&(this.debug=function(){return console.error(...arguments)}),this.debug(this.pattern,this.globSet);const r=this.globSet.map((e=>this.slashSplit(e)));this.globParts=this.preprocess(r),this.debug(this.pattern,this.globParts);let i=this.globParts.map(((e,t,r)=>{if(this.isWindows&&this.windowsNoMagicRoot){const t=!(""!==e[0]||""!==e[1]||"?"!==e[2]&&eL.test(e[2])||eL.test(e[3])),r=/^[a-z]:/i.test(e[0]);if(t)return[...e.slice(0,4),...e.slice(4).map((e=>this.parse(e)))];if(r)return[e[0],...e.slice(1).map((e=>this.parse(e)))]}return e.map((e=>this.parse(e)))}));if(this.debug(this.pattern,i),this.set=i.filter((e=>-1===e.indexOf(!1))),this.isWindows)for(let e=0;e=2?(e=this.firstPhasePreProcess(e),e=this.secondPhasePreProcess(e)):e=t>=1?this.levelOneOptimize(e):this.adjascentGlobstarOptimize(e),e}adjascentGlobstarOptimize(e){return e.map((e=>{let t=-1;for(;-1!==(t=e.indexOf("**",t+1));){let r=t;for(;"**"===e[r+1];)r++;r!==t&&e.splice(t,r-t)}return e}))}levelOneOptimize(e){return e.map((e=>0===(e=e.reduce(((e,t)=>{const r=e[e.length-1];return"**"===t&&"**"===r?e:".."===t&&r&&".."!==r&&"."!==r&&"**"!==r?(e.pop(),e):(e.push(t),e)}),[])).length?[""]:e))}levelTwoFileOptimize(e){Array.isArray(e)||(e=this.slashSplit(e));let t=!1;do{if(t=!1,!this.preserveMultipleSlashes){for(let r=1;ri&&r.splice(i+1,n-i);let o=r[i+1];const s=r[i+2],a=r[i+3];if(".."!==o)continue;if(!s||"."===s||".."===s||!a||"."===a||".."===a)continue;t=!0,r.splice(i,1);const l=r.slice(0);l[i]="**",e.push(l),i--}if(!this.preserveMultipleSlashes){for(let e=1;ee.length))}partsMatch(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=0,n=0,o=[],s="";for(;i2&&void 0!==arguments[2]&&arguments[2];const i=this.options;if(this.isWindows){const r="string"==typeof e[0]&&/^[a-z]:$/i.test(e[0]),i=!r&&""===e[0]&&""===e[1]&&"?"===e[2]&&/^[a-z]:$/i.test(e[3]),n="string"==typeof t[0]&&/^[a-z]:$/i.test(t[0]),o=i?3:r?0:void 0,s=!n&&""===t[0]&&""===t[1]&&"?"===t[2]&&"string"==typeof t[3]&&/^[a-z]:$/i.test(t[3])?3:n?0:void 0;if("number"==typeof o&&"number"==typeof s){const[r,i]=[e[o],t[s]];r.toLowerCase()===i.toLowerCase()&&(t[s]=r,s>o?t=t.slice(s):o>s&&(e=e.slice(o)))}}const{optimizationLevel:n=1}=this.options;n>=2&&(e=this.levelTwoFileOptimize(e)),this.debug("matchOne",this,{file:e,pattern:t}),this.debug("matchOne",e.length,t.length);for(var o=0,s=0,a=e.length,l=t.length;o>> no match, partial?",e,u,t,p),u!==a))}let n;if("string"==typeof d?(n=c===d,this.debug("string match",d,c,n)):(n=d.test(c),this.debug("pattern match",d,c,n)),!n)return!1}if(o===a&&s===l)return!0;if(o===a)return r;if(s===l)return o===a-1&&""===e[o];throw new Error("wtf?")}braceExpand(){return XU(this.pattern,this.options)}parse(e){hU(e);const t=this.options;if("**"===e)return QU;if(""===e)return"";let r,i=null;(r=e.match(UU))?i=t.dot?jU:LU:(r=e.match(AU))?i=(t.nocase?t.dot?RU:DU:t.dot?MU:FU)(r[1]):(r=e.match(HU))?i=(t.nocase?t.dot?GU:$U:t.dot?WU:KU)(r):(r=e.match(PU))?i=t.dot?zU:OU:(r=e.match(NU))&&(i=qU);const n=CU.fromGlob(e,this.options).toMMPattern();return i&&"object"==typeof n&&Reflect.defineProperty(n,"test",{value:i}),n}makeRe(){if(this.regexp||!1===this.regexp)return this.regexp;const e=this.set;if(!e.length)return this.regexp=!1,this.regexp;const t=this.options,r=t.noglobstar?"[^/]*?":t.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",i=new Set(t.nocase?["i"]:[]);let n=e.map((e=>{const t=e.map((e=>{if(e instanceof RegExp)for(const t of e.flags.split(""))i.add(t);return"string"==typeof e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):e===QU?QU:e._src}));return t.forEach(((e,i)=>{const n=t[i+1],o=t[i-1];e===QU&&o!==QU&&(void 0===o?void 0!==n&&n!==QU?t[i+1]="(?:\\/|"+r+"\\/)?"+n:t[i]=r:void 0===n?t[i-1]=o+"(?:\\/|"+r+")?":n!==QU&&(t[i-1]=o+"(?:\\/|\\/"+r+"\\/)"+n,t[i+1]=QU))})),t.filter((e=>e!==QU)).join("/")})).join("|");const[o,s]=e.length>1?["(?:",")"]:["",""];n="^"+o+n+s+"$",this.negate&&(n="^(?!"+n+").+$");try{this.regexp=new RegExp(n,[...i].join(""))}catch(e){this.regexp=!1}return this.regexp}slashSplit(e){return this.preserveMultipleSlashes?e.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(e)?["",...e.split(/\/+/)]:e.split(/\/+/)}match(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.partial;if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return""===e;if("/"===e&&t)return!0;const r=this.options;this.isWindows&&(e=e.split("\\").join("/"));const i=this.slashSplit(e);this.debug(this.pattern,"split",i);const n=this.set;this.debug(this.pattern,"set",n);let o=i[i.length-1];if(!o)for(let e=i.length-2;!o&&e>=0;e--)o=i[e];for(let e=0;e1&&void 0!==arguments[1]?arguments[1]:""}Invalid response: ${e.status} ${e.statusText}`);return t.status=e.status,t.response=e,t}function iL(e,t){const{status:r}=t;if(401===r&&e.digest)return t;if(r>=400)throw rL(t);return t}function nL(e,t){return arguments.length>2&&void 0!==arguments[2]&&arguments[2]?{data:t,headers:e.headers?Xq(e.headers):{},status:e.status,statusText:e.statusText}:t}IU.AST=CU,IU.Minimatch=tL,IU.escape=function(e){let{windowsPathsNoEscape:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t?e.replace(/[?*()[\]]/g,"[$&]"):e.replace(/[?*()[\]\\]/g,"\\$&")},IU.unescape=vU;const oL=(sL=function(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const n=cU({url:Cq(e.remoteURL,kq(t)),method:"COPY",headers:{Destination:Cq(e.remoteURL,kq(r)),Overwrite:!1===i.overwrite?"F":"T",Depth:i.shallow?"0":"infinity"}},e,i);return s=function(t){iL(e,t)},(o=dU(n,e))&&o.then||(o=Promise.resolve(o)),s?o.then(s):o;var o,s},function(){for(var e=[],t=0;t2&&void 0!==arguments[2]?arguments[2]:cL.Original;const i=dL().get(e,t);return"array"===r&&!1===Array.isArray(i)?[i]:"object"===r&&Array.isArray(i)?i[0]:i}function pL(e){return new Promise((t=>{t(function(e){const{multistatus:t}=e;if(""===t)return{multistatus:{response:[]}};if(!t)throw new Error("Invalid response: No root multistatus found");const r={multistatus:Array.isArray(t)?t[0]:t};return dL().set(r,"multistatus.response",uL(r,"multistatus.response",cL.Array)),dL().set(r,"multistatus.response",dL().get(r,"multistatus.response").map((e=>function(e){const t=Object.assign({},e);return t.status?dL().set(t,"status",uL(t,"status",cL.Object)):(dL().set(t,"propstat",uL(t,"propstat",cL.Object)),dL().set(t,"propstat.prop",uL(t,"propstat.prop",cL.Object))),t}(e)))),r}(new aL.XMLParser({removeNSPrefix:!0,numberParseOptions:{hex:!0,leadingZeros:!1}}).parse(e)))}))}function hL(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const{getlastmodified:i=null,getcontentlength:n="0",resourcetype:o=null,getcontenttype:s=null,getetag:a=null}=e,l=o&&"object"==typeof o&&void 0!==o.collection?"directory":"file",d={filename:t,basename:_q().basename(t),lastmod:i,size:parseInt(n,10),type:l,etag:"string"==typeof a?a.replace(/"/g,""):null};return"file"===l&&(d.mime=s&&"string"==typeof s?s.split(";")[0]:""),r&&(void 0!==e.displayname&&(e.displayname=String(e.displayname)),d.props=e),d}function fL(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=null;try{e.multistatus.response[0].propstat&&(i=e.multistatus.response[0])}catch(e){}if(!i)throw new Error("Failed getting item stat: bad response");const{propstat:{prop:n,status:o}}=i,[s,a,l]=o.split(" ",3),d=parseInt(a,10);if(d>=400){const e=new Error(`Invalid response: ${d} ${l}`);throw e.status=d,e}return hL(n,Tq(t),r)}function mL(e){switch(String(e)){case"-3":return"unlimited";case"-2":case"-1":return"unknown";default:return parseInt(String(e),10)}}function gL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const yL=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const{details:i=!1}=r,n=cU({url:Cq(e.remoteURL,kq(t)),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},e,r);return gL(dU(n,e),(function(r){return iL(e,r),gL(r.text(),(function(e){return gL(pL(e),(function(e){const n=fL(e,t,i);return nL(r,n,i)}))}))}))}));function vL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const bL=wL((function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=function(e){if(!e||"/"===e)return[];let t=e;const r=[];do{r.push(t),t=_q().dirname(t)}while(t&&"/"!==t);return r}(Tq(t));i.sort(((e,t)=>e.length>t.length?1:t.length>e.length?-1:0));let n=!1;return function(e,t){if("function"==typeof e[SL]){var r,i,n,o=e[SL]();function d(e){try{for(;!(r=o.next()).done;)if((e=t(r.value))&&e.then){if(!TL(e))return void e.then(d,n||(n=kL.bind(null,i=new EL,2)));e=e.v}i?kL(i,1,e):i=e}catch(e){kL(i||(i=new EL),2,e)}}if(d(),o.return){var s=function(e){try{r.done||o.return()}catch(e){}return e};if(i&&i.then)return i.then(s,(function(e){throw s(e)}));s()}return i}if(!("length"in e))throw new TypeError("Object is not iterable");for(var a=[],l=0;l2&&void 0!==arguments[2]?arguments[2]:{};if(!0===r.recursive)return bL(e,t,r);const i=cU({url:Cq(e.remoteURL,(n=kq(t),n.endsWith("/")?n:n+"/")),method:"MKCOL"},e,r);var n;return vL(dU(i,e),(function(t){iL(e,t)}))}));var CL=hq(388),IL=hq.n(CL);const AL=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const i={};if("object"==typeof r.range&&"number"==typeof r.range.start){let e=`bytes=${r.range.start}-`;"number"==typeof r.range.end&&(e=`${e}${r.range.end}`),i.Range=e}const n=cU({url:Cq(e.remoteURL,kq(t)),method:"GET",headers:i},e,r);return s=function(t){if(iL(e,t),i.Range&&206!==t.status){const e=new Error(`Invalid response code for partial request: ${t.status}`);throw e.status=t.status,e}return r.callback&&setTimeout((()=>{r.callback(t)}),0),t.body},(o=dU(n,e))&&o.then||(o=Promise.resolve(o)),s?o.then(s):o;var o,s})),FL=()=>{},ML=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const i=cU({url:Cq(e.remoteURL,kq(t)),method:"DELETE"},e,r);return o=function(t){iL(e,t)},(n=dU(i,e))&&n.then||(n=Promise.resolve(n)),o?n.then(o):n;var n,o})),RL=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};return function(i,n){try{var o=(s=yL(e,t,r),a=function(){return!0},s&&s.then||(s=Promise.resolve(s)),a?s.then(a):s)}catch(e){return n(e)}var s,a;return o&&o.then?o.then(void 0,n):o}(0,(function(e){if(404===e.status)return!1;throw e}))}));function PL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const OL=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const i=cU({url:Cq(e.remoteURL,kq(t),"/"),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:r.deep?"infinity":"1"}},e,r);return PL(dU(i,e),(function(i){return iL(e,i),PL(i.text(),(function(n){if(!n)throw new Error("Failed parsing directory contents: Empty response");return PL(pL(n),(function(n){const o=Eq(t);let s=function(e,t,r){let i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],n=arguments.length>4&&void 0!==arguments[4]&&arguments[4];const o=_q().join(t,"/"),{multistatus:{response:s}}=e,a=s.map((e=>{const t=function(e){try{return e.replace(/^https?:\/\/[^\/]+/,"")}catch(e){throw new bq(e,"Failed normalising HREF")}}(e.href),{propstat:{prop:r}}=e;return hL(r,"/"===o?decodeURIComponent(Tq(t)):Tq(_q().relative(decodeURIComponent(o),decodeURIComponent(t))),i)}));return n?a:a.filter((e=>e.basename&&("file"===e.type||e.filename!==r.replace(/\/$/,""))))}(n,Eq(e.remoteBasePath||e.remotePath),o,r.details,r.includeSelf);return r.glob&&(s=function(e,t){return e.filter((e=>IU(e.filename,t,{matchBase:!0})))}(s,r.glob)),nL(i,s,r.details)}))}))}))}));function zL(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const i=cU({url:Cq(e.remoteURL,kq(t)),method:"GET",headers:{Accept:"text/plain"},transformResponse:[jL]},e,r);return qL(dU(i,e),(function(t){return iL(e,t),qL(t.text(),(function(e){return nL(t,e,r.details)}))}))}));function qL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const UL=zL((function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=cU({url:Cq(e.remoteURL,kq(t)),method:"GET"},e,r);return qL(dU(i,e),(function(t){let i;return iL(e,t),function(e,t){var r=e();return r&&r.then?r.then(t):t()}((function(){return qL(t.arrayBuffer(),(function(e){i=e}))}),(function(){return nL(t,i,r.details)}))}))})),LL=zL((function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{format:i="binary"}=r;if("binary"!==i&&"text"!==i)throw new bq({info:{code:jq.InvalidOutputFormat}},`Invalid output format: ${i}`);return"text"===i?NL(e,t,r):UL(e,t,r)})),jL=e=>e;function HL(e){return new aL.XMLBuilder({attributeNamePrefix:"@_",format:!0,ignoreAttributes:!1,suppressEmptyNode:!0}).build($L({lockinfo:{"@_xmlns:d":"DAV:",lockscope:{exclusive:{}},locktype:{write:{}},owner:{href:e}}},"d"))}function $L(e,t){const r={...e};for(const e in r)r.hasOwnProperty(e)&&(r[e]&&"object"==typeof r[e]&&-1===e.indexOf(":")?(r[`${t}:${e}`]=$L(r[e],t),delete r[e]):!1===/^@_/.test(e)&&(r[`${t}:${e}`]=r[e],delete r[e]));return r}function GL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function WL(e){return function(){for(var t=[],r=0;r3&&void 0!==arguments[3]?arguments[3]:{};const n=cU({url:Cq(e.remoteURL,kq(t)),method:"UNLOCK",headers:{"Lock-Token":r}},e,i);return GL(dU(n,e),(function(t){if(iL(e,t),204!==t.status&&200!==t.status)throw rL(t)}))})),VL=WL((function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{refreshToken:i,timeout:n=JL}=r,o={Accept:"text/plain,application/xml",Timeout:n};i&&(o.If=i);const s=cU({url:Cq(e.remoteURL,kq(t)),method:"LOCK",headers:o,data:HL(e.contactHref)},e,r);return GL(dU(s,e),(function(t){return iL(e,t),GL(t.text(),(function(e){const r=(o=e,new aL.XMLParser({removeNSPrefix:!0,parseAttributeValue:!0,parseTagValue:!0}).parse(o)),i=dL().get(r,"prop.lockdiscovery.activelock.locktoken.href"),n=dL().get(r,"prop.lockdiscovery.activelock.timeout");var o;if(!i)throw rL(t,"No lock token received: ");return{token:i,serverTimeout:n}}))}))})),JL="Infinite, Second-4100000000";function YL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const QL=function(e){return function(){for(var t=[],r=0;r1&&void 0!==arguments[1]?arguments[1]:{};const r=t.path||"/",i=cU({url:Cq(e.remoteURL,r),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},e,t);return YL(dU(i,e),(function(r){return iL(e,r),YL(r.text(),(function(e){return YL(pL(e),(function(e){const i=function(e){try{const[t]=e.multistatus.response,{propstat:{prop:{"quota-used-bytes":r,"quota-available-bytes":i}}}=t;return void 0!==r&&void 0!==i?{used:parseInt(String(r),10),available:mL(i)}:null}catch(e){}return null}(e);return nL(r,i,t.details)}))}))}))}));function ZL(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const XL=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const{details:i=!1}=r,n=cU({url:Cq(e.remoteURL,kq(t)),method:"SEARCH",headers:{Accept:"text/plain,application/xml","Content-Type":e.headers["Content-Type"]||"application/xml; charset=utf-8"}},e,r);return ZL(dU(n,e),(function(r){return iL(e,r),ZL(r.text(),(function(e){return ZL(pL(e),(function(e){const n=function(e,t,r){const i={truncated:!1,results:[]};return i.truncated=e.multistatus.response.some((e=>"507"===(e.status||e.propstat?.status).split(" ",3)?.[1]&&e.href.replace(/\/$/,"").endsWith(kq(t).replace(/\/$/,"")))),e.multistatus.response.forEach((e=>{if(void 0===e.propstat)return;const t=e.href.split("/").map(decodeURIComponent).join("/");i.results.push(hL(e.propstat.prop,t,r))})),i}(e,t,i);return nL(r,n,i)}))}))}))})),ej=function(e){return function(){for(var t=[],r=0;r3&&void 0!==arguments[3]?arguments[3]:{};const n=cU({url:Cq(e.remoteURL,kq(t)),method:"MOVE",headers:{Destination:Cq(e.remoteURL,kq(r)),Overwrite:!1===i.overwrite?"F":"T"}},e,i);return s=function(t){iL(e,t)},(o=dU(n,e))&&o.then||(o=Promise.resolve(o)),s?o.then(s):o;var o,s}));var tj=hq(172);const rj=function(e){return function(){for(var t=[],r=0;r3&&void 0!==arguments[3]?arguments[3]:{};const{contentLength:n=!0,overwrite:o=!0}=i,s={"Content-Type":"application/octet-stream"};!1===n||(s["Content-Length"]="number"==typeof n?`${n}`:`${function(e){if(iU(e))return e.byteLength;if(nU(e))return e.length;if("string"==typeof e)return(0,tj.d)(e);throw new bq({info:{code:jq.DataTypeNoLength}},"Cannot calculate data length: Invalid type")}(r)}`),o||(s["If-None-Match"]="*");const a=cU({url:Cq(e.remoteURL,kq(t)),method:"PUT",headers:s,data:r},e,i);return d=function(t){try{iL(e,t)}catch(e){const t=e;if(412!==t.status||o)throw t;return!1}return!0},(l=dU(a,e))&&l.then||(l=Promise.resolve(l)),d?l.then(d):l;var l,d})),ij=function(e){return function(){for(var t=[],r=0;r2&&void 0!==arguments[2]?arguments[2]:{};const i=cU({url:Cq(e.remoteURL,kq(t)),method:"OPTIONS"},e,r);return o=function(t){try{iL(e,t)}catch(e){throw e}return{compliance:(t.headers.get("DAV")??"").split(",").map((e=>e.trim())),server:t.headers.get("Server")??""}},(n=dU(i,e))&&n.then||(n=Promise.resolve(n)),o?n.then(o):n;var n,o}));function nj(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}const oj=lj((function(e,t,r,i,n){let o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};if(r>i||r<0)throw new bq({info:{code:jq.InvalidUpdateRange}},`Invalid update range ${r} for partial update`);const s={"Content-Type":"application/octet-stream","Content-Length":""+(i-r+1),"Content-Range":`bytes ${r}-${i}/*`},a=cU({url:Cq(e.remoteURL,kq(t)),method:"PUT",headers:s,data:n},e,o);return nj(dU(a,e),(function(t){iL(e,t)}))}));function sj(e,t){var r=e();return r&&r.then?r.then(t):t(r)}const aj=lj((function(e,t,r,i,n){let o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};if(r>i||r<0)throw new bq({info:{code:jq.InvalidUpdateRange}},`Invalid update range ${r} for partial update`);const s={"Content-Type":"application/x-sabredav-partialupdate","Content-Length":""+(i-r+1),"X-Update-Range":`bytes=${r}-${i}`},a=cU({url:Cq(e.remoteURL,kq(t)),method:"PATCH",headers:s,data:n},e,o);return nj(dU(a,e),(function(t){iL(e,t)}))}));function lj(e){return function(){for(var t=[],r=0;r5&&void 0!==arguments[5]?arguments[5]:{};return nj(ij(e,t,o),(function(s){let a=!1;return sj((function(){if(s.compliance.includes("sabredav-partialupdate"))return nj(aj(e,t,r,i,n,o),(function(e){return a=!0,e}))}),(function(l){let d=!1;return a?l:sj((function(){if(s.server.includes("Apache")&&s.compliance.includes(""))return nj(oj(e,t,r,i,n,o),(function(e){return d=!0,e}))}),(function(e){if(d)return e;throw new bq({info:{code:jq.NotSupported}},"Not supported")}))}))}))})),cj="https://github.com/perry-mitchell/webdav-client/blob/master/LOCK_CONTACT.md";function uj(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{authType:r=null,remoteBasePath:i,contactHref:n=cj,ha1:o,headers:s={},httpAgent:a,httpsAgent:l,password:d,token:c,username:u,withCredentials:p}=t;let h=r;h||(h=u||d?Lq.Password:Lq.None);const f={authType:h,remoteBasePath:i,contactHref:n,ha1:o,headers:Object.assign({},s),httpAgent:a,httpsAgent:l,password:d,remotePath:Bq(e),remoteURL:e,token:c,username:u,withCredentials:p};return Hq(f,u,d,c,o),{copyFile:(e,t,r)=>oL(f,e,t,r),createDirectory:(e,t)=>BL(f,e,t),createReadStream:(e,t)=>function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const i=new(0,IL().PassThrough);return AL(e,t,r).then((e=>{e.pipe(i)})).catch((e=>{i.emit("error",e)})),i}(f,e,t),createWriteStream:(e,t,r)=>function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:FL;const n=new(0,IL().PassThrough),o={};!1===r.overwrite&&(o["If-None-Match"]="*");const s=cU({url:Cq(e.remoteURL,kq(t)),method:"PUT",headers:o,data:n,maxRedirects:0},e,r);return dU(s,e).then((t=>iL(e,t))).then((e=>{setTimeout((()=>{i(e)}),0)})).catch((e=>{n.emit("error",e)})),n}(f,e,t,r),customRequest:(e,t)=>ML(f,e,t),deleteFile:(e,t)=>DL(f,e,t),exists:(e,t)=>RL(f,e,t),getDirectoryContents:(e,t)=>OL(f,e,t),getFileContents:(e,t)=>LL(f,e,t),getFileDownloadLink:e=>function(e,t){let r=Cq(e.remoteURL,kq(t));const i=/^https:/i.test(r)?"https":"http";switch(e.authType){case Lq.None:break;case Lq.Password:{const t=Pq(e.headers.Authorization.replace(/^Basic /i,"").trim());r=r.replace(/^https?:\/\//,`${i}://${t}@`);break}default:throw new bq({info:{code:jq.LinkUnsupportedAuthType}},`Unsupported auth type for file link: ${e.authType}`)}return r}(f,e),getFileUploadLink:e=>function(e,t){let r=`${Cq(e.remoteURL,kq(t))}?Content-Type=application/octet-stream`;const i=/^https:/i.test(r)?"https":"http";switch(e.authType){case Lq.None:break;case Lq.Password:{const t=Pq(e.headers.Authorization.replace(/^Basic /i,"").trim());r=r.replace(/^https?:\/\//,`${i}://${t}@`);break}default:throw new bq({info:{code:jq.LinkUnsupportedAuthType}},`Unsupported auth type for file link: ${e.authType}`)}return r}(f,e),getHeaders:()=>Object.assign({},f.headers),getQuota:e=>QL(f,e),lock:(e,t)=>VL(f,e,t),moveFile:(e,t,r)=>ej(f,e,t,r),putFileContents:(e,t,r)=>rj(f,e,t,r),partialUpdateFileContents:(e,t,r,i,n)=>dj(f,e,t,r,i,n),getDAVCompliance:e=>ij(f,e),search:(e,t)=>XL(f,e,t),setHeaders:e=>{f.headers=Object.assign({},e)},stat:(e,t)=>yL(f,e,t),unlock:(e,t,r)=>KL(f,e,t,r)}}var pj=fq.hT,hj=fq.UU;function fj(e){return!/[^\u0000-\u00ff]/g.test(e)}function mj(e){return Object.fromEntries(Object.entries(e).map((([e,t])=>[e.toLowerCase(),t])))}t_&&(0,fq.Gu)().patch("request",(e=>r(void 0,void 0,void 0,(function*(){var t;const r=mj(Object.assign({},e.headers));delete r.host,delete r["content-length"];const i=null!==(t=r.accept)&&void 0!==t?t:r["content-type"],n=Object.assign({},r);n.hasOwnProperty("authorization")&&(n.authorization="");const o={url:e.url,method:e.method,body:e.data,headers:r,contentType:i,throw:!1};let s=yield(0,k.requestUrl)(o);401!==s.status||!k.Platform.isIosApp||e.url.endsWith("/")||e.url.endsWith(".md")||"PROPFIND"!==e.method.toUpperCase()||(console.debug("so we have 401, try appending request url with slash"),o.url=`${e.url}/`,s=yield(0,k.requestUrl)(o));const a=mj(Object.assign({},s.headers));for(const e in a)a.hasOwnProperty(e)&&(fj(a[e])||(a[e]=encodeURIComponent(a[e])));let l;const d=(0,oq.Us)(s.status);return l=[101,103,204,205,304].includes(s.status)?new Response(null,{status:s.status,statusText:d,headers:a}):new Response(s.arrayBuffer,{status:s.status,statusText:d,headers:a}),l}))));const gj=(e,t)=>{let r=e;return"/"===e||""===e?r=`/${t}/`:e.startsWith("/")?(console.warn(`why the path ${e} starts with '/'? but we just go on.`),r=`/${t}${e}`):r=`/${t}/${e}`,r},yj=e=>{let t=e;for(;t.startsWith("/..");)t=t.slice(3);return t},vj=(e,t)=>{let r=((e,t)=>{const r=yj(e);if(r!==`/${t}`&&!r.startsWith(`/${t}/`))throw Error(`"${e}" after stripping doesn't starts with "/${t}/"`);return r.slice(`/${t}/`.length)})(e.filename,t);"directory"!==e.type||r.endsWith("/")||(r=`${r}/`);const i=Date.parse(e.lastmod).valueOf();return{key:r,keyRaw:r,mtimeSvr:i,mtimeCli:i,size:e.size,sizeRaw:e.size}},bj=e=>fj(e)?e:unescape(encodeURIComponent(e));class wj extends Mp{constructor(e,t,r){super(),this._getnextcloudUploadServerAddress=()=>{let e=this.webdavConfig.address;e.endsWith("/")&&(e=e.substring(0,e.length-1));const t=e.split("/");if(t.length>3&&"dav"===t[t.length-3]&&"files"===t[t.length-2]&&""!==t[t.length-1])return t[t.length-2]="uploads",t.join("/");throw Error(`cannot construct upload address for ${t}`)},this.kind="webdav",this.webdavConfig=m()(e),this.webdavConfig.address=(e=>e.includes("%")?e:encodeURI(e))(this.webdavConfig.address),this.remoteBaseDir=this.webdavConfig.remoteBaseDir||t||"",this.vaultFolderExists=!1,this.saveUpdatedConfigFunc=r,this.supportApachePartial=!1,this.supportSabrePartial=!1,this.isNextcloud=!1,this.nextcloudUploadServerAddress=""}_init(){return r(this,void 0,void 0,(function*(){var e;if(void 0!==this.client)return;const t=(e=>{const t=e.trim();if(""===t)return{};const r=t.split("\n"),i={};for(const e of r){if(!e.includes(":"))continue;const[t,...r]=e.split(":"),n=t.trim(),o=r.join(":").trim();i[n]=o}return i})(null!==(e=this.webdavConfig.customHeaders)&&void 0!==e?e:""),r=Object.assign(Object.assign({},{"Cache-Control":"no-cache"}),t);if(""!==this.webdavConfig.username&&""!==this.webdavConfig.password?this.client=hj(this.webdavConfig.address,{username:bj(this.webdavConfig.username),password:bj(this.webdavConfig.password),headers:r,authType:"digest"===this.webdavConfig.authType?pj.Digest:pj.Password}):(console.info("no password"),this.client=hj(this.webdavConfig.address,{headers:r})),this.vaultFolderExists);else{(yield this.client.exists(`/${this.remoteBaseDir}/`))||(console.info("remote vault folder not exists, creating"),yield this.client.createDirectory(`/${this.remoteBaseDir}/`),console.info("remote vault folder created!")),this.vaultFolderExists=!0}"auto"!==this.webdavConfig.depth&&"auto_1"!==this.webdavConfig.depth&&"auto_infinity"!==this.webdavConfig.depth&&"auto_unknown"!==this.webdavConfig.depth||(this.webdavConfig.depth="manual_1",this.webdavConfig.manualRecursive=!0,void 0!==this.saveUpdatedConfigFunc&&(yield this.saveUpdatedConfigFunc(),console.info(`webdav depth="auto_???" is changed to ${this.webdavConfig.depth}`))),yield this._checkPartialSupport()}))}_checkPartialSupport(){return r(this,void 0,void 0,(function*(){const e=yield this.client.getDAVCompliance(`/${this.remoteBaseDir}/`);for(const t of e.compliance)if(t.toLocaleLowerCase().includes("nextcloud")&&""!==this.webdavConfig.username&&""!==this.webdavConfig.password){const e=this.webdavConfig.address.split("/");return e.length>3&&"dav"===e[e.length-3]&&"files"===e[e.length-2]&&""!==e[e.length-1]&&(this.isNextcloud=!0,this.nextcloudUploadServerAddress=this._getnextcloudUploadServerAddress(),console.debug(`isNextcloud=${this.isNextcloud}, uploadFolder=${this.nextcloudUploadServerAddress}`),!0)}return e.server.includes("Apache")&&e.compliance.includes("")?(this.supportApachePartial=!0,console.debug(`supportApachePartial=true, compliance=${JSON.stringify(e)}`),!0):!!e.compliance.includes("sabredav-partialupdate")&&(this.supportSabrePartial=!0,console.debug(`supportSabrePartial=true, compliance=${JSON.stringify(e)}`),!0)}))}walk(){return r(this,void 0,void 0,(function*(){yield this._init();let e=[];if("auto"===this.webdavConfig.depth||"auto_unknown"===this.webdavConfig.depth||"auto_1"===this.webdavConfig.depth||"auto_infinity"===this.webdavConfig.depth||"manual_1"===this.webdavConfig.depth||this.webdavConfig.address.includes("jianguoyun.com")||this.webdavConfig.address.includes("teracloud.jp")){const t=new nq.op([`/${this.remoteBaseDir}`]),i=10;for(;t.length>0;){const n=[];for(;t.length>0;)n.push(t.pop());const o=aq()(n,i),s=[];for(const e of o){const t=e.map((e=>r(this,void 0,void 0,(function*(){let t=yield this.client.getDirectoryContents(e,{deep:!1,details:!1});return t=t.filter((t=>yj(t.filename)!==e)),t})))),i=yield Promise.all(t);for(const e of i)if(this.webdavConfig.address.includes("jianguoyun.com")&&e.length>=749)throw Error("出错:坚果云 api 有限制,文件列表加载不全。终止同步!");const n=dq()(i);s.push(...n)}for(let r=0;rvj(e,this.remoteBaseDir))).filter((e=>"/"!==e.keyRaw));return t}))}walkPartial(){return r(this,void 0,void 0,(function*(){yield this._init();return(yield this.client.getDirectoryContents(`/${this.remoteBaseDir}`,{deep:!1,details:!1})).map((e=>vj(e,this.remoteBaseDir))).filter((e=>"/"!==e.keyRaw))}))}stat(e){return r(this,void 0,void 0,(function*(){yield this._init();const t=gj(e,this.remoteBaseDir);return yield this._statFromRoot(t)}))}_statFromRoot(e){return r(this,void 0,void 0,(function*(){const t=yield this.client.stat(e,{details:!1});return vj(t,this.remoteBaseDir)}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){if(!e.endsWith("/"))throw Error(`you should not call mkdir on ${e}`);yield this._init();const r=gj(e,this.remoteBaseDir);return yield this._mkdirFromRoot(r,t,i)}))}_mkdirFromRoot(e,t,i){return r(this,void 0,void 0,(function*(){return yield this.client.createDirectory(e,{recursive:!1}),yield this._statFromRoot(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`you should not call writeFile on ${e}`);yield this._init();const r=gj(e,this.remoteBaseDir);return yield this._writeFileFromRoot(r,t,i,n,e)}))}_writeFileFromRoot(e,t,i,n,o){return r(this,void 0,void 0,(function*(){if(t.byteLength<=10485760)return yield this._writeFileFromRootFull(e,t,i,n,o);if(!this.isNextcloud&&!this.supportApachePartial&&!this.supportSabrePartial)return yield this._writeFileFromRootFull(e,t,i,n,o);try{if(this.isNextcloud)return yield this._writeFileFromRootNextcloud(e,t,i,n,o);if(this.supportApachePartial)return yield this._writeFileFromRootApachePartial(e,t,i,n,o);if(this.supportSabrePartial)return yield this._writeFileFromRootSabrePartial(e,t,i,n,o);throw Error("Error: partial upload / update method is not implemented??")}catch(e){throw console.error("we fail to write file partially for nextcloud or apache or sabre/dav, stop!"),console.error(e),e}}))}_writeFileFromRootFull(e,t,i,n,o){return r(this,void 0,void 0,(function*(){yield this.client.putFileContents(e,t,{overwrite:!0,onUploadProgress:e=>{console.info(`Uploaded ${e.loaded} bytes of ${e.total}`)}});return yield this._statFromRoot(e)}))}_writeFileFromRootNextcloud(e,t,i,n,o){return r(this,void 0,void 0,(function*(){if(e.endsWith("/"))throw Error(`key=${e} should not have tailing slash in _writeFileFromRootNextcloud`);const r=`${this.webdavConfig.address}/${encodeURI(e)}`;console.debug(`destUrl=${r}`);const i=this.nextcloudUploadServerAddress;console.debug(`uploadServerAddress=${i}`);const n=(e=>{if(e.endsWith("/"))throw Error("file to upload by chunk should not ends with /");const t=e.split("/");return encodeURI(`${t[t.length-1]}`)})(e);console.debug(`tmpFolderName=${n}`);const s=hj(i,{username:bj(this.webdavConfig.username),password:bj(this.webdavConfig.password),headers:{"Cache-Control":"no-cache"},authType:"digest"===this.webdavConfig.authType?pj.Digest:pj.Password});yield s.createDirectory(n,{method:"MKCOL",headers:{Destination:r}}),console.debug("finish creating folder");const a=th(t.byteLength,5242880);for(let e=0;e{let r=e;return"/"===e||""===e?r=`${t}`:e.startsWith("/")?(console.warn(`why the path ${e} starts with '/'? but we just go on.`),r=`${t}${e}`):r=`${t}/${e}`,`rs:fs:v1:${encodeURIComponent(r)}`},Sj=(e,t)=>{const r=decodeURIComponent(e),i=`rs:fs:v1:${t}/`,n=":meta",o=":content";if(!r.startsWith(i))throw Error(`you should not call getOrigEntity on ${e}`);let s=r.slice(i.length);return s.endsWith(n)?s=s.slice(0,-5):s.endsWith(o)&&(s=s.slice(0,-8)),s};class kj extends Mp{constructor(e,t,r){super(),this.kind="webdis",this.webdisConfig=e,this.remoteBaseDir=this.webdisConfig.remoteBaseDir||t||"",this.saveUpdatedConfigFunc=r}_fetchCommand(e,t,i){return r(this,void 0,void 0,(function*(){var r,n;const o=this.webdisConfig.address;if(!o.startsWith("https://")&&!o.startsWith("http://"))throw Error("your webdis server address should start with https:// or http://");if(o.endsWith("/"))throw Error("your webdis server should not ends with /");if(void 0!==i&&"PUT"!==e)throw Error('you can only "POST" ArrayBuffer, not using other methods');const s=`${o}/${t}`,a=null!==(r=this.webdisConfig.username)&&void 0!==r?r:"",l=null!==(n=this.webdisConfig.password)&&void 0!==n?n:"";if(""!==a&&""!==l)return yield fetch(s,{method:e,headers:{Authorization:"Basic "+btoa(a+":"+l)},body:i});if(""===a&&""===l)return yield fetch(s,{method:e,body:i});throw Error("your username and password should both be empty or not empty!")}))}walk(){return r(this,void 0,void 0,(function*(){let e="0";const t=[];do{const r=`SCAN/${e}/MATCH/rs:fs:v1:${encodeURIComponent(this.remoteBaseDir+"/")}*:meta/COUNT/1000`,i=(yield(yield this._fetchCommand("GET",r)).json()).SCAN;e=i[0];for(const e of i[1]){const r=Sj(e,this.remoteBaseDir);t.push(yield this.stat(r))}}while("0"!==e);return t}))}walkPartial(){return r(this,void 0,void 0,(function*(){let e="0";const t=[],r=`SCAN/${e}/MATCH/rs:fs:v1:${encodeURIComponent(this.remoteBaseDir+"/")}*:meta/COUNT/10`,i=(yield(yield this._fetchCommand("GET",r)).json()).SCAN;e=i[0];for(const e of i[1]){const r=Sj(e,this.remoteBaseDir);t.push(yield this.stat(r))}return t}))}stat(e){return r(this,void 0,void 0,(function*(){const t=xj(e,this.remoteBaseDir);return yield this._statFromRaw(t)}))}_statFromRaw(e){return r(this,void 0,void 0,(function*(){const t=`HGETALL/${e}:meta`,r=(yield(yield this._fetchCommand("GET",t)).json()).HGETALL;if((0,_j.isEqual)(r,{}))throw Error(`key ${e} doesn't exist!`);const i=Sj(e,this.remoteBaseDir);return{key:i,keyRaw:i,mtimeCli:Number.parseInt(r.mtime),mtimeSvr:Number.parseInt(r.mtime),size:Number.parseInt(r.size),sizeRaw:Number.parseInt(r.size)}}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){let r=`HSET/${xj(e,this.remoteBaseDir)}:meta/size/0`;void 0!==t&&0!==t&&(r=`${r}/mtime/${t}`),void 0!==i&&0!==i&&(r=`${r}/ctime/${i}`);(yield(yield this._fetchCommand("GET",r)).json()).HSET;return yield this.stat(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){const r=xj(e,this.remoteBaseDir);let o=`HSET/${r}:meta/size/${t.byteLength}`;void 0!==i&&0!==i&&(o=`${o}/mtime/${i}`),void 0!==n&&0!==n&&(o=`${o}/ctime/${n}`);(yield(yield this._fetchCommand("GET",o)).json()).HSET;const s=`SET/${r}:content`;(yield(yield this._fetchCommand("PUT",s,t)).json()).SET;return yield this.stat(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){const t=`GET/${xj(e,this.remoteBaseDir)}:content?type=${I}`;return yield(yield this._fetchCommand("GET",t)).arrayBuffer()}))}rename(e,t){return r(this,void 0,void 0,(function*(){const r=xj(e,this.remoteBaseDir),i=xj(t,this.remoteBaseDir),n=`RENAME/${r}:content/${i}:content`;yield this._fetchCommand("POST",n);const o=`RENAME/${r}:meta/${i}:meta`;yield this._fetchCommand("POST",o)}))}rm(e){return r(this,void 0,void 0,(function*(){const t=xj(e,this.remoteBaseDir),r=`DEL/${t}:meta/${t}:content`;(yield(yield this._fetchCommand("PUT",r)).json()).DEL}))}checkConnect(e){return r(this,void 0,void 0,(function*(){try{const e=yield(yield this._fetchCommand("GET","PING/helloworld")).json();if(!(0,_j.isEqual)(e,{PING:"helloworld"}))throw Error("no correct ping response")}catch(t){return console.error(t),null==e||e(t),!1}return yield this.checkConnectCommonOps(e)}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){return this.webdisConfig.username||""}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}allowEmptyFile(){return!0}}function Ej(e,t,r){switch(e.serviceType){case"s3":return new iq(e.s3);case"webdav":return new wj(e.webdav,t,r);case"dropbox":return new xx(e.dropbox,t,r);case"onedrive":return new Gx(e.onedrive,t,r);case"onedrivefull":return new d_(e.onedrivefull,t,r);case"webdis":return new kj(e.webdis,t,r);case"googledrive":return new Bh(e.googledrive,t,r);case"box":return new xh(e.box,t,r);case"pcloud":return new m_(e.pcloud,t,r);case"yandexdisk":return new __(e.yandexdisk,t,r);case"koofr":return new $h(e.koofr,t,r);case"azureblobstorage":return new ah(e.azureblobstorage,t);default:throw Error(`cannot init client for serviceType=${e.serviceType}`)}}const Tj=(e,t)=>e===t||e===`${t}/`||e.endsWith(`/${t}`)||e.endsWith(`/${t}/`),Bj=e=>{const t=["data.json","main.js","manifest.json",".gitignore","styles.css"];for(const r of t)if(e===r||e.endsWith(`/${r}`))return!0;return!1};class Cj extends Mp{constructor(e,t,r,i,n,o,s){super(),this.vault=e,this.syncConfigDir=t,this.syncBookmarks=r,this.configDir=i,this.pluginID=n,this.profiler=o,this.deleteToWhere=s,this.kind="local"}walk(){return r(this,void 0,void 0,(function*(){var e,t,i,n,o,s,a,l;null===(e=this.profiler)||void 0===e||e.addIndent(),null===(t=this.profiler)||void 0===t||t.insert("enter walk for local");const d=[],c=this.vault.getAllLoadedFiles();null===(i=this.profiler)||void 0===i||i.insert("finish getting walk for local");for(const e of c){let t,r=e.path;if(r.startsWith("/")&&(r=r.slice(1)),"/"!==e.path&&""!==e.path){if(e instanceof k.TFile){let i=e.stat.mtime;if(i<=0&&(i=e.stat.ctime),0===i&&(i=void 0),void 0===i)throw Error(`Your file has last modified time 0: ${r}, don't know how to deal with it`);t={key:r,keyRaw:r,mtimeCli:i,mtimeSvr:i,size:e.stat.size,sizeRaw:e.stat.size}}else{if(!(e instanceof k.TFolder))throw Error(`unexpected ${e}`);r=`${r}/`,t={key:r,keyRaw:r,size:0,sizeRaw:0}}t.keyRaw.startsWith(R)||d.push(t)}}if(null===(n=this.profiler)||void 0===n||n.insert("finish transforming walk for local"),this.syncConfigDir||this.syncBookmarks){null===(o=this.profiler)||void 0===o||o.insert("into syncConfigDir or syncBookmarks");const e=!this.syncConfigDir,t=yield((e,t,i,n)=>r(void 0,void 0,void 0,(function*(){const o=new nq.op([e]);let s=[],a=0;for(;o.length>0;){const l=[];for(;o.length>0;)l.push(o.pop());const d=aq()(l,10);for(const n of d){const a=n.map((i=>r(void 0,void 0,void 0,(function*(){const r=yield Jp(t,i);if(null==r)throw Error("something goes wrong while listing hidden folder");const n="folder"===r.type;let o;if(n&&(o=yield t.adapter.list(i)),!n&&(void 0===r.mtime||null===r.mtime||0===r.mtime))throw Error(`File in Obsidian ${e} has last modified time 0: ${i}, don't know how to deal with it.`);return{itself:{key:n?`${i}/`:i,keyRaw:n?`${i}/`:i,mtimeCli:r.mtime,mtimeSvr:r.mtime,size:r.size,sizeRaw:r.size},children:o}})))),l=dq()(yield Promise.all(a));for(const e of l){s.push(e.itself);const t=Tj(e.itself.key,i);if(void 0!==e.children){for(const r of e.children.folders)Yp(r,["workspace","workspace.json"])||t&&!Bj(r)||o.push(r);for(const r of e.children.files)Yp(r,["workspace","workspace.json"])||t&&!Bj(r)||o.push(r)}}}if(n&&a>1)break;a+=1}return n&&(s=s.filter((t=>t.key===`${e}/`||t.key===`${e}/bookmarks.json`))),s})))(this.configDir,this.vault,this.pluginID,e);for(const e of t)d.push(e);null===(s=this.profiler)||void 0===s||s.insert("finish syncConfigDir")}return null===(a=this.profiler)||void 0===a||a.insert("finish walk for local"),null===(l=this.profiler)||void 0===l||l.removeIndent(),d}))}walkPartial(){return r(this,void 0,void 0,(function*(){return yield this.walk()}))}stat(e){return r(this,void 0,void 0,(function*(){const t=yield Jp(this.vault,e);if(null==t)throw Error(`${e} does not exist! cannot stat for local`);const r="folder"===t.type;return{key:r?`${e}/`:e,keyRaw:r?`${e}/`:e,ctimeCli:t.ctime,mtimeCli:t.mtime,mtimeSvr:t.mtime,ctimeCliFmt:Vp(t.ctime),mtimeCliFmt:Vp(t.mtime),mtimeSvrFmt:Vp(t.mtime),size:t.size,sizeRaw:t.size}}))}mkdir(e,t,i){return r(this,void 0,void 0,(function*(){return yield Np(e,this.vault),yield this.stat(e)}))}writeFile(e,t,i,n){return r(this,void 0,void 0,(function*(){return yield this.vault.adapter.writeBinary(e,t,{mtime:i,ctime:n}),yield this.stat(e)}))}readFile(e){return r(this,void 0,void 0,(function*(){return yield this.vault.adapter.readBinary(e)}))}rename(e,t){return r(this,void 0,void 0,(function*(){return yield this.vault.adapter.rename(e,t)}))}rm(e){return r(this,void 0,void 0,(function*(){"obsidian"===this.deleteToWhere?yield this.vault.adapter.trashLocal(e):(yield this.vault.adapter.trashSystem(e))||(yield this.vault.adapter.trashLocal(e))}))}checkConnect(e){return r(this,void 0,void 0,(function*(){return!0}))}getUserDisplayName(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}revokeAuth(){return r(this,void 0,void 0,(function*(){throw new Error("Method not implemented.")}))}allowEmptyFile(){return!0}}var Ij=__webpack_require__(55364),Aj=__webpack_require__.n(Ij),Fj=Object.prototype.toString,Mj=Array.isArray||function(e){return"[object Array]"===Fj.call(e)};function Dj(e){return"function"==typeof e}function Rj(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Pj(e,t){return null!=e&&"object"==typeof e&&t in e}var Oj=RegExp.prototype.test;var zj=/\S/;function Nj(e){return!function(e,t){return Oj.call(e,t)}(zj,e)}var qj={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};var Uj=/\s*/,Lj=/\s+/,jj=/\s*=/,Hj=/\s*\}/,$j=/#|\^|\/|>|\{|&|=|!/;function Gj(e){this.string=e,this.tail=e,this.pos=0}function Wj(e,t){this.view=e,this.cache={".":this.view},this.parent=t}function Kj(){this.templateCache={_cache:{},set:function(e,t){this._cache[e]=t},get:function(e){return this._cache[e]},clear:function(){this._cache={}}}}Gj.prototype.eos=function(){return""===this.tail},Gj.prototype.scan=function(e){var t=this.tail.match(e);if(!t||0!==t.index)return"";var r=t[0];return this.tail=this.tail.substring(r.length),this.pos+=r.length,r},Gj.prototype.scanUntil=function(e){var t,r=this.tail.search(e);switch(r){case-1:t=this.tail,this.tail="";break;case 0:t="";break;default:t=this.tail.substring(0,r),this.tail=this.tail.substring(r)}return this.pos+=t.length,t},Wj.prototype.push=function(e){return new Wj(e,this)},Wj.prototype.lookup=function(e){var t,r,i,n=this.cache;if(n.hasOwnProperty(e))t=n[e];else{for(var o,s,a,l=this,d=!1;l;){if(e.indexOf(".")>0)for(o=l.view,s=e.split("."),a=0;null!=o&&a0?n[n.length-1][4]:r;break;default:i.push(t)}return r}(function(e){for(var t,r,i=[],n=0,o=e.length;n"===s?a=this.renderPartial(o,t,r,n):"&"===s?a=this.unescapedValue(o,t):"name"===s?a=this.escapedValue(o,t,n):"text"===s&&(a=this.rawValue(o)),void 0!==a&&(l+=a);return l},Kj.prototype.renderSection=function(e,t,r,i,n){var o=this,s="",a=t.lookup(e[1]);if(a){if(Mj(a))for(var l=0,d=a.length;l0||!r)&&(n[o]=i+n[o]);return n.join("\n")},Kj.prototype.renderPartial=function(e,t,r,i){if(r){var n=this.getConfigTags(i),o=Dj(r)?r(e[1]):r[e[1]];if(null!=o){var s=e[6],a=e[5],l=e[4],d=o;0==a&&l&&(d=this.indentPartial(o,l,s));var c=this.parse(d,n);return this.renderTokens(c,t,r,d,i)}}},Kj.prototype.unescapedValue=function(e,t){var r=t.lookup(e[1]);if(null!=r)return r},Kj.prototype.escapedValue=function(e,t,r){var i=this.getConfigEscape(r)||Vj.escape,n=t.lookup(e[1]);if(null!=n)return"number"==typeof n&&i===Vj.escape?String(n):i(n)},Kj.prototype.rawValue=function(e){return e[1]},Kj.prototype.getConfigTags=function(e){return Mj(e)?e:e&&"object"==typeof e?e.tags:void 0},Kj.prototype.getConfigEscape=function(e){return e&&"object"==typeof e&&!Mj(e)?e.escape:void 0};var Vj={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(e){Jj.templateCache=e},get templateCache(){return Jj.templateCache}},Jj=new Kj;Vj.clearCache=function(){return Jj.clearCache()},Vj.parse=function(e,t){return Jj.parse(e,t)},Vj.render=function(e,t,r,i){if("string"!=typeof e)throw new TypeError('Invalid template! Template should be a "string" but "'+((Mj(n=e)?"array":typeof n)+'" was given as the first argument for mustache#render(template, view, partials)'));var n;return Jj.render(e,t,r,i)},Vj.escape=function(e){return String(e).replace(/[&<>"'`=\/]/g,(function(e){return qj[e]}))},Vj.Scanner=Gj,Vj.Context=Wj,Vj.Writer=Kj;const Yj=Vj,Qj={en:JSON.parse('{"settings_conflictaction_smart_conflict":"Smart Conflict (PRO) (beta)","settings_conflictaction_smart_conflict_desc":"

!!It\'s a PRO feature! You need an online account for this feature!!(scroll down for more info about PRO account.)

  • For small markdown files, the plugin tries to merge them with diff3 algorithm.
  • For large files or not-markdown files, the plugin saves both files by renaming them.

Please manually backup your vaule before using this feature!

","protocol_pro_connecting":"Connectting","protocol_pro_connect_manualinput_succ":"You\'ve connected","protocol_pro_connect_fail":"Something went wrong from response from Remotely Save official website. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_pro_connect_succ_revoke":"You\'ve connected as user {{email}}. If you want to disconnect, click this button.","protocol_onedrivefull_connecting":"Connecting to OneDrive...\\nPlease DO NOT close this modal.","protocol_onedrivefull_connect_succ_revoke":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","protocol_onedrivefull_connect_fail":"Something went wrong from response from OneDrive. Maybe you rejected the auth?","protocol_onedrivefull_connect_unknown":"Do not know how to deal with the callback: {{params}}","protocol_box_connecting":"Connectting","protocol_box_connect_manualinput_succ":"You\'ve connected","protocol_box_connect_fail":"Something went wrong from response from Box official website. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_box_connect_succ_revoke":"You\'ve connected. If you want to disconnect, click this button.","protocol_pcloud_connecting":"Connectting","protocol_pcloud_connect_manualinput_succ":"You\'ve connected","protocol_pcloud_connect_fail":"Something went wrong from response from pCloud website. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_pcloud_connect_succ_revoke":"You\'ve connected. If you want to disconnect, click this button.","protocol_yandexdisk_connecting":"Connectting","protocol_yandexdisk_connect_manualinput_succ":"You\'ve connected","protocol_yandexdisk_connect_fail":"Something went wrong from response from Yandex Disk website. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_yandexdisk_connect_succ_revoke":"You\'ve connected. If you want to disconnect, click this button.","protocol_koofr_connecting":"Connectting","protocol_koofr_connect_manualinput_succ":"You\'ve connected","protocol_koofr_connect_fail":"Something went wrong from response from Koofr website. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_koofr_connect_succ_revoke":"You\'ve connected. If you want to disconnect, click this button.","modal_onedrivefullauth_shortdesc":"Currently only OneDrive for personal is supported. OneDrive for Business is NOT supported (yet).\\nVisit the address in a browser, and follow the steps.\\nFinally you should be redirected to Obsidian.","modal_onedrivefullauth_shortdesc_linux":"It seems that you are using Obsidian on Linux, and you might not be able to jump back here properly. Please consider using the flatpack version of Obsidian, or creating an obsidian.desktop file.","modal_onedrivefullauth_copybutton":"Click to copy the auth url","modal_onedrivefullauth_copynotice":"The auth url is copied to the clipboard!","modal_onedrivefullrevokeauth_step1":"Step 1: Go to the following address, click the \\"Edit\\" button for the plugin, then click \\"Remove these permissions\\" button on the page.","modal_onedrivefullrevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_onedrivefullrevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_onedrivefullrevokeauth_clean_desc":"You need to click the button.","modal_onedrivefullrevokeauth_clean_button":"Clean","modal_onedrivefullrevokeauth_clean_notice":"Cleaned!","modal_onedrivefullrevokeauth_clean_fail":"Something goes wrong while revoking.","modal_googledriveauth_tutorial":"

Please firstly go to the address, then go on the auth flow. In the end, you will see a code, please paste that code here and submit.

","modal_googledriveauth_copybutton":"Click to copy the auth url","modal_googledriveauth_copynotice":"The auth url is copied to the clipboard!","modal_googledrivce_maualinput":"The Code from the website","modal_googledrivce_maualinput_desc":"Please input the code here from the end of auth flow, and press confirm.","modal_googledrive_maualinput_notice":"We are trying to connect to Google and update the credentials...","modal_googledrive_maualinput_succ_notice":"Great! The credentials are updated!","modal_googledrive_maualinput_fail_notice":"Oops! Failed to update the credentials. Please try again later.","modal_googledriverevokeauth_step1":"Step 1: Go to the following address, you can remove the connection there.","modal_googledriverevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_googledriverevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_googledriverevokeauth_clean_desc":"You need to click the button.","modal_googledriverevokeauth_clean_button":"Clean","modal_googledriverevokeauth_clean_notice":"Cleaned!","modal_googledriverevokeauth_clean_fail":"Something goes wrong while revoking.","modal_boxauth_tutorial":"

Please firstly go to the address, then go on the auth flow. In the end, you will be redirected to here.

","modal_boxauth_copybutton":"Click to copy the auth url","modal_boxauth_copynotice":"The auth url is copied to the clipboard!","modal_box_maualinput":"The Code from the website","modal_box_maualinput_desc":"Please input the code here from the end of auth flow, and press confirm.","modal_box_maualinput_notice":"We are trying to connect to Box and update the credentials...","modal_box_maualinput_succ_notice":"Great! The credentials are updated!","modal_box_maualinput_fail_notice":"Oops! Failed to update the credentials. Please try again later.","modal_boxrevokeauth_step1":"Step 1: Go to the following address, you can remove the connection there.","modal_boxrevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_boxrevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_boxrevokeauth_clean_desc":"You need to click the button.","modal_boxrevokeauth_clean_button":"Clean","modal_boxrevokeauth_clean_notice":"Cleaned!","modal_boxrevokeauth_clean_fail":"Something goes wrong while revoking.","modal_pcloudauth_tutorial":"

Please firstly go to the address, then go on the auth flow. In the end, you will be redirected to here.

","modal_pcloudauth_copybutton":"Click to copy the auth url","modal_pcloudauth_copynotice":"The auth url is copied to the clipboard!","modal_pcloudrevokeauth_step1":"Step 1: Go to the following address, you can remove the connection there.","modal_pcloudrevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_pcloudrevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_pcloudrevokeauth_clean_desc":"You need to click the button.","modal_pcloudrevokeauth_clean_button":"Clean","modal_pcloudrevokeauth_clean_notice":"Cleaned!","modal_pcloudrevokeauth_clean_fail":"Something goes wrong while revoking.","modal_yandexdiskauth_tutorial":"

Please firstly go to the address, then go on the auth flow. In the end, you will be redirected to here.

","modal_yandexdiskauth_copybutton":"Click to copy the auth url","modal_yandexdiskauth_copynotice":"The auth url is copied to the clipboard!","modal_yandexdiskrevokeauth_step1":"Step 1: Go to the following address, you can remove the connection there.","modal_yandexdiskrevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_yandexdiskrevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_yandexdiskrevokeauth_clean_desc":"You need to click the button.","modal_yandexdiskrevokeauth_clean_button":"Clean","modal_yandexdiskrevokeauth_clean_notice":"Cleaned!","modal_yandexdiskrevokeauth_clean_fail":"Something goes wrong while revoking.","modal_koofrauth_tutorial":"

Please firstly go to the address, then go on the auth flow. In the end, you will be redirected to here.

","modal_koofrauth_copybutton":"Click to copy the auth url","modal_koofrauth_copynotice":"The auth url is copied to the clipboard!","modal_koofrrevokeauth_step1":"Step 1: Go to the following address, you can remove the connection there.","modal_koofrrevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_koofrrevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_koofrrevokeauth_clean_desc":"You need to click the button.","modal_koofrrevokeauth_clean_button":"Clean","modal_koofrrevokeauth_clean_notice":"Cleaned!","modal_koofrrevokeauth_clean_fail":"Something goes wrong while revoking.","modal_remoteprefix_azureblobstorage_title":"You are changing the remote prefix config","modal_remoteprefix_azureblobstorage_shortdesc":"1. The plugin would NOT automatically move the content from the old directory to the new one directly on the remote. Everything syncs from the beginning again.\\n2. If you set the string to the empty, the prefix will be the vault name.\\n3. The remote directory name itself would not be encrypted even you\'ve set an E2E password.\\n4. Some special char like \'?\', \'/\', \'\\\\\' are not allowed. Spaces in the beginning or in the end are also trimmed.","modal_remoteprefix_azureblobstorage_invaliddirhint":"Your input contains special characters like \'?\', \'/\', \'\\\\\' which are not allowed.","modal_remoteprefix_azureblobstorage_tosave":"The prefix to save is \\"{{{prefix}}}\\"","modal_remoteprefix_azureblobstorage_secondconfirm_change":"Confirm To Change","modal_remoteprefix_azureblobstorage_notice":"New remote prefix config saved!","modal_prorevokeauth":"Revoke auth by clicking here and follow the steps.","modal_prorevokeauth_clean":"Clean","modal_prorevokeauth_clean_desc":"Clean local auth record","modal_prorevokeauth_clean_button":"Clean","modal_prorevokeauth_clean_notice":"Local auth record is cleaned","modal_prorevokeauth_clean_fail":"Fail to clean local auth record.","modal_proauth_copybutton":"Click to copy the auth url","modal_proauth_copynotice":"The auth url is copied to the clipboard!","modal_proauth_maualinput":"The Code from the website","modal_proauth_maualinput_desc":"Please input the code here from the end of auth flow, and press confirm.","modal_proauth_maualinput_notice":"Trying to connect, wait...","modal_proauth_maualinput_conn_fail":"Failed to connect","modal_cleardupfiles_warning":"Warning: The plugin just stupidly finds all the file names that looks like duplicated files (.dup in file names). Also, this only deletes local files, so you need to trigger a sync to delete remote files.","modal_cleardupfiles_warning_confirm":"Confirm to delete","modal_cleardupfiles_warning_finished":"All the detected duplicated files are removed!","settings_onedrivefull":"Remote For Onedrive (for personal) (Full)","settings_chooseservice_onedrivefull":"OneDrive for personal (Full) (PRO)","settings_onedrivefull_disclaimer1":"Disclaimer: This app is NOT an official Microsoft / OneDrive product.","settings_onedrivefull_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Onedrive, please immediately disconnect this app on https://microsoft.com/consent .","settings_onedrivefull_folder":"We will create and sync inside the folder /{{remoteBaseDir}} on your OneDrive.","settings_onedrivefull_nobiz":"Currently only OneDrive for personal is supported. OneDrive for Business is NOT supported (yet).","settings_onedrivefull_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_onedrivefull_notshowuphint":"OneDrive for personal (Full) Settings Not Available","settings_onedrivefull_notshowuphint_desc":"OneDrive for personal (Full) settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_onedrivefull_notshowuphint_view_pro":"View PRO Settings","settings_onedrivefull_revoke":"Revoke Auth","settings_onedrivefull_revoke_desc":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","settings_onedrivefull_revoke_button":"Revoke Auth","settings_onedrivefull_auth":"Auth","settings_onedrivefull_auth_desc":"Auth.","settings_onedrivefull_auth_button":"Auth","settings_onedrivefull_connect_succ":"Great! We can connect to OneDrive!","settings_onedrivefull_connect_fail":"We cannot connect to OneDrive.","settings_onedrivefull_emptyfile":"Empty File Handling","settings_onedrivefull_emptyfile_desc":"OneDrive doesn\'t allow uploading empty file (even in its official website). Do you want to show up errors or silently skip the empty files?","settings_onedrivefull_emptyfile_skip":"Skip","settings_onedrivefull_emptyfile_error":"Error and abort","settings_googledrive":"Google Drive (PRO) (beta)","settings_chooseservice_googledrive":"Google Drive (PRO) (beta)","settings_googledrive_disclaimer1":"Disclaimer: This app is NOT an official Google product. The app just uses Google Drive\'s public api.","settings_googledrive_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Google Drive, please immediately disconnect this app on https://myaccount.google.com/permissions .","settings_googledrive_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_googledrive_notshowuphint":"Google Drive Settings Not Available","settings_googledrive_notshowuphint_desc":"Google Drive settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_googledrive_notshowuphint_view_pro":"View PRO Settings","settings_googledrive_folder":"We will create and sync inside the folder {{remoteBaseDir}} on your Google Drive. DO NOT create this folder by yourself manually.","settings_googledrive_revoke":"Revoke Auth","settings_googledrive_revoke_desc":"You\'ve connected. If you want to disconnect, click this button.","settings_googledrive_revoke_button":"Revoke Auth","settings_googledrive_auth":"Auth","settings_googledrive_auth_desc":"Auth.","settings_googledrive_auth_button":"Auth","settings_googledrive_connect_succ":"Great! We can connect to Google Drive!","settings_googledrive_connect_fail":"We cannot connect to Google Drive.","settings_box":"Box (PRO) (beta)","settings_chooseservice_box":"Box (PRO) (beta)","settings_box_disclaimer1":"Disclaimer: This app is NOT an official Box product. The app just uses Box\'s public api.","settings_box_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Box, please immediately disconnect this app on https://app.box.com/account/security .","settings_box_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_box_notshowuphint":"Box Settings Not Available","settings_box_notshowuphint_desc":"Box settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_box_notshowuphint_view_pro":"View PRO Settings","settings_box_folder":"We will create and sync inside the folder {{remoteBaseDir}} on your Box. DO NOT create this folder by yourself manually.","settings_box_revoke":"Revoke Auth","settings_box_revoke_desc":"You\'ve connected. If you want to disconnect, click this button.","settings_box_revoke_button":"Revoke Auth","settings_box_auth":"Auth","settings_box_auth_desc":"Auth.","settings_box_auth_button":"Auth","settings_box_connect_succ":"Great! We can connect to Box!","settings_box_connect_fail":"We cannot connect to Box.","settings_pcloud":"pCloud (PRO) (beta)","settings_chooseservice_pcloud":"pCloud (PRO) (beta)","settings_pcloud_disclaimer1":"Disclaimer: This app is NOT an official pCloud product. The app just uses pCloud\'s public api.","settings_pcloud_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your pCloud, please immediately disconnect this app on https://my.pcloud.com/#page=settings&settings=tab-apps .","settings_pcloud_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_pcloud_notshowuphint":"pCloud Settings Not Available","settings_pcloud_notshowuphint_desc":"pCloud settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_pcloud_notshowuphint_view_pro":"View PRO Settings","settings_pcloud_folder":"We will create and sync inside the folder {{remoteBaseDir}} on your pCloud. DO NOT create this folder by yourself manually.","settings_pcloud_revoke":"Revoke Auth","settings_pcloud_revoke_desc":"You\'ve connected. If you want to disconnect, click this button.","settings_pcloud_revoke_button":"Revoke Auth","settings_pcloud_auth":"Auth","settings_pcloud_auth_desc":"Auth.","settings_pcloud_auth_button":"Auth","settings_pcloud_emptyfile":"Empty File","settings_pcloud_emptyfile_desc":"pCloud API doesn\'t work with empty file. How to deal with it?","settings_pcloud_emptyfile_skip":"Skip","settings_pcloud_emptyfile_error":"Error","settings_pcloud_connect_succ":"Great! We can connect to pCloud!","settings_pcloud_connect_fail":"We cannot connect to pCloud.","settings_yandexdisk":"Yandex Disk (PRO) (beta)","settings_chooseservice_yandexdisk":"Yandex Disk (PRO) (beta)","settings_yandexdisk_disclaimer1":"Disclaimer: This app is NOT an official Yandex Disk product. The app just uses Yandex Disk\'s public api.","settings_yandexdisk_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Yandex Disk, please immediately disconnect this app on https://app.yandexdisk.com/account/security .","settings_yandexdisk_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_yandexdisk_notshowuphint":"Yandex Disk Settings Not Available","settings_yandexdisk_notshowuphint_desc":"Yandex Disk settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_yandexdisk_notshowuphint_view_pro":"View PRO Settings","settings_yandexdisk_folder":"We will create and sync inside the folder {{remoteBaseDir}} on your Yandex Disk. DO NOT create this folder by yourself manually.","settings_yandexdisk_revoke":"Revoke Auth","settings_yandexdisk_revoke_desc":"You\'ve connected. If you want to disconnect, click this button.","settings_yandexdisk_revoke_button":"Revoke Auth","settings_yandexdisk_auth":"Auth","settings_yandexdisk_auth_desc":"Auth.","settings_yandexdisk_auth_button":"Auth","settings_yandexdisk_connect_succ":"Great! We can connect to Yandex Disk!","settings_yandexdisk_connect_fail":"We cannot connect to Yandex Disk.","settings_koofr":"Koofr (PRO) (beta)","settings_chooseservice_koofr":"Koofr (PRO) (beta)","settings_koofr_disclaimer1":"Disclaimer: This app is NOT an official Koofr product. The app just uses Koofr\'s public api.","settings_koofr_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Koofr, please immediately disconnect this app on https://app.koofr.net/app/admin/preferences/security .","settings_koofr_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_koofr_notshowuphint":"Koofr Settings Not Available","settings_koofr_notshowuphint_desc":"Koofr settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_koofr_notshowuphint_view_pro":"View PRO Settings","settings_koofr_folder":"We will create and sync inside the folder {{remoteBaseDir}} on your Koofr. DO NOT create this folder by yourself manually.","settings_koofr_revoke":"Revoke Auth","settings_koofr_revoke_desc":"You\'ve connected. If you want to disconnect, click this button.","settings_koofr_revoke_button":"Revoke Auth","settings_koofr_auth":"Auth","settings_koofr_auth_desc":"Auth.","settings_koofr_auth_button":"Auth","settings_koofr_connect_succ":"Great! We can connect to Koofr!","settings_koofr_connect_fail":"We cannot connect to Koofr.","settings_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_chooseservice_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_azureblobstorage_disclaimer1":"Disclaimer: This app is NOT an official Microsoft / Azure product. The app just uses Azure Blob Storage\'s public api.","settings_azureblobstorage_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Azure Blob Storage, please immediately delete the SAS Url and try to change your policy or account info.","settings_azureblobstorage_pro_desc":"

!!It\'s a PRO feature of Remotely Save! You need a Remotely Save online account for this feature!!(scroll down for more info about PRO account.)

","settings_azureblobstorage_notshowuphint":"Azure Blob Storage Settings Not Available","settings_azureblobstorage_notshowuphint_desc":"Azure Blob Storage settings are not available, because you haven\'t subscribed to the PRO feature in your Remotely Save account.","settings_azureblobstorage_notshowuphint_view_pro":"View PRO Settings","settings_azureblobstorage_folder":"We will create and sync inside the prefix {{remoteBaseDir}} on your Azure Blob Storage.","settings_azureblobstorage_containersasurl":"Container SAS Url","settings_azureblobstorage_containersasurl_desc":"The only connction method is providing the Container SAS Url. Remember to configure CORS as well. Please read the doc for details.","settings_azureblobstorage_containername":"Container Name","settings_azureblobstorage_containername_desc":"Input your container name here.","settings_azureblobstorage_remoteprefix":"Remote Prefix","settings_azureblobstorage_remoteprefix_desc":"Input your remote prefix of blobs for this vault. If you set this value to empty, the vault name will be used as prefix. Empty prefix is not allowed and not settable here.","settings_azureblobstorage_parts":"Parts Concurrency","settings_azureblobstorage_parts_desc":"Large files are split into small parts to upload. How many parts do you want to upload in parallel at most?","settings_azureblobstorage_generatefolderobject":"Generate Folder Object Or Not","settings_azureblobstorage_generatefolderobject_desc":"Azure Blob Storage doesn\'t have \\"real\\" folder. If you set \\"Generate\\" here, the plugin will upload a zero-byte object endding with \\"/\\" to represent the folder. By default, the plugin skips generating folder object.","settings_azureblobstorage_generatefolderobject_notgenerate":"Not generate (default)","settings_azureblobstorage_generatefolderobject_generate":"Generate","settings_azureblobstorage_connect_succ":"Great! We can connect to Azure Blob Storage!","settings_azureblobstorage_connect_fail":"We cannot connect to Azure Blob Storage.","settings_export_onedrivefull_button":"Export Onedrive (Full) Part","settings_export_googledrive_button":"Export Google Drive Part","settings_export_box_button":"Export Box Part","settings_export_pcloud_button":"Export pCloud Part","settings_export_yandexdisk_button":"Export Yandex Disk Part","settings_export_koofr_button":"Export Koofr Part","settings_export_azureblobstorage_button":"Export Azure Blob Storage Part","settings_cleardupfiles":"Clear Duplicated Files By Smart Conflict","settings_cleardupfiles_desc":"If you have ever used Smart Conflict (PRO) feature, the plugin may generate duplicated files. IF YOU ARE SURE THE DUPLICATED FILES ARE NO LONGER NEEDED, you can clear ALL of them locally here.","settings_cleardupfiles_button":"Start Scanning","settings_pro":"Account (for PRO features)","settings_pro_tutorial":"

Using basic features of Remotely Save is FREE and do NOT need an account.

However, you will need an online account and PAY for the PRO features such as smart conflict.

Firstly please click the button to sign up and sign in to the website: https://remotelysave.com. Notice: It\'s different from, and NOT affiliated with Obsidian account.

Secondly please \\"connect\\" your local device to your online account.","settings_pro_features":"Features","settings_pro_features_desc":"Here are features you\'ve enabled:
{{{features}}}","settings_pro_features_refresh_button":"Check again","settings_pro_features_refresh_fetch":"Fetching...","settings_pro_features_refresh_succ":"Refreshed!","settings_pro_revoke":"Disconnect","settings_pro_revoke_desc":"You\'ve connected as user {{email}}. If you want to disconnect, click this button.","settings_pro_revoke_button":"Disconnect","settings_pro_intro":"Remotely Save Online Account","settings_pro_intro_desc":"Click the button to jump to the website to sign up or sign in.","settings_pro_intro_button":"Sign Up / Sign In","settings_pro_auth":"Connect","settings_pro_auth_desc":"After you sign up and sign in the account on the website, you need to connect your plugin here to the online account. Please click the button to connect.","settings_pro_auth_button":"Connect"}'),zh_cn:JSON.parse('{"settings_conflictaction_smart_conflict":"智能处理冲突 (PRO) (beta)","settings_conflictaction_smart_conflict_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

  • 小 markdown 文件,本插件尝试使用 diff3 算法合并它;
  • 对于大文件或非 markdown 文件,本插件尝试改名字并均进行保存。

请注意先手动备份 vault 文件再用此功能!

","protocol_pro_connecting":"正在连接","protocol_pro_connect_manualinput_succ":"连接成功","protocol_pro_connect_fail":"Remotely Save 官网返回错误。可能是网络连接不稳定。也可能是您拒绝了授权?","protocol_pro_connect_succ_revoke":"您已连接上账号 {{email}}。如果要取消连接,请点击此按钮。","protocol_onedrivefull_connecting":"正在连接 OneDrive……\\n请不要关闭此弹窗。","protocol_onedrivefull_connect_succ_revoke":"您已作为用户 {{username}} 连接上了。如果您想取消连接,请点击此按钮。","protocol_onedrivefull_connect_fail":"OneDrive 的回调请求有点异常。您是否拒绝了鉴权?","protocol_onedrivefull_connect_unknown":"不知道如何处理此 callback:{{params}}","protocol_box_connecting":"正在连接","protocol_box_connect_manualinput_succ":"连接成功","protocol_box_connect_fail":"Box 官网返回错误。可能是网络连接不稳定。也可能是您拒绝了授权?","protocol_box_connect_succ_revoke":"您已连接上账号。如果要取消连接,请点击此按钮。","protocol_pcloud_connecting":"正在连接","protocol_pcloud_connect_manualinput_succ":"连接成功","protocol_pcloud_connect_fail":"pCloud 官网返回错误。可能是网络连接不稳定。也可能是您拒绝了授权?","protocol_pcloud_connect_succ_revoke":"您已连接上账号。如果要取消连接,请点击此按钮。","protocol_yandexdisk_connecting":"正在连接","protocol_yandexdisk_connect_manualinput_succ":"连接成功","protocol_yandexdisk_connect_fail":"Yandex Disk 官网返回错误。可能是网络连接不稳定。也可能是您拒绝了授权?","protocol_yandexdisk_connect_succ_revoke":"您已连接上账号。如果要取消连接,请点击此按钮。","protocol_koofr_connecting":"正在连接","protocol_koofr_connect_manualinput_succ":"连接成功","protocol_koofr_connect_fail":"Yandex Disk 官网返回错误。可能是网络连接不稳定。也可能是您拒绝了授权?","protocol_koofr_connect_succ_revoke":"您已连接上账号。如果要取消连接,请点击此按钮。","modal_onedrivefullauth_shortdesc":"现在只支持个人版 OneDrive,(暂)不支持企业版。\\n在浏览器中访问以下地址,然后按照网页提示操作。\\n到了最后,您应该会被自动重定向回来 Obsidian。","modal_onedrivefullauth_shortdesc_linux":"您正在用 Linux,有可能无法跳转回来。请考虑使用 flatpack 版本的 Obsidian,或创建 obsidian.desktop 文件。","modal_onedrivefullauth_copybutton":"点击此按钮从而复制鉴权 url","modal_onedrivefullauth_copynotice":"鉴权 url 已复制到剪贴板!","modal_onedrivefullrevokeauth_step1":"第 1 步:用浏览器打开以下地址,点击本插件对应的“Edit”按钮,点击“Remove these permissions”按钮。","modal_onedrivefullrevokeauth_step2":"第 2 步:点击以下按钮,清理本地保存的登录信息。","modal_onedrivefullrevokeauth_clean":"清理本地保存的登录信息","modal_onedrivefullrevokeauth_clean_desc":"您需要点击“清理”按钮。","modal_onedrivefullrevokeauth_clean_button":"清理","modal_onedrivefullrevokeauth_clean_notice":"已清理!","modal_onedrivefullrevokeauth_clean_fail":"鉴权途中出错了。","modal_googledriveauth_tutorial":"

请访问此网址,然后会进入授权流程。最后,您会看到一个码,请复制粘贴到这里然后提交。

","modal_googledriveauth_copybutton":"点击以复制网址","modal_googledriveauth_copynotice":"网址已复制!","modal_googledrivce_maualinput":"网站上的码","modal_googledrivce_maualinput_desc":"请粘贴授权流程最后的那个码,然后点击确认。","modal_googledrive_maualinput_notice":"正在尝试连接 Google 并更新授权信息......","modal_googledrive_maualinput_succ_notice":"很好!授权信息已更新!","modal_googledrive_maualinput_fail_notice":"更新授权信息失败。请稍后重试。","modal_googledriverevokeauth_step1":"第 1 步:访问以下网址,可以删除连接。","modal_googledriverevokeauth_step2":"第 2 步:点击以下按钮,从而清理本地的登录信息。","modal_googledriverevokeauth_clean":"清理本地登录信息","modal_googledriverevokeauth_clean_desc":"您需要点击此按钮。","modal_googledriverevokeauth_clean_button":"清理","modal_googledriverevokeauth_clean_notice":"已清理!","modal_googledriverevokeauth_clean_fail":"清理授权时候发生了错误。","modal_boxauth_tutorial":"

请访问此网址,然后会进入授权流程。最后,您会被重定向回来。

","modal_boxauth_copybutton":"点击以复制网址","modal_boxauth_copynotice":"网址已复制!","modal_box_maualinput":"网站上的码","modal_box_maualinput_desc":"请粘贴授权流程最后的那个码,然后点击确认。","modal_box_maualinput_notice":"正在尝试连接 Box 并更新授权信息......","modal_box_maualinput_succ_notice":"很好!授权信息已更新!","modal_box_maualinput_fail_notice":"更新授权信息失败。请稍后重试。","modal_boxrevokeauth_step1":"第 1 步:访问以下网址,可以删除连接。","modal_boxrevokeauth_step2":"第 2 步:点击以下按钮,从而清理本地的登录信息。","modal_boxrevokeauth_clean":"清理本地登录信息","modal_boxrevokeauth_clean_desc":"您需要点击此按钮。","modal_boxrevokeauth_clean_button":"清理","modal_boxrevokeauth_clean_notice":"已清理!","modal_boxrevokeauth_clean_fail":"清理授权时候发生了错误。","modal_pcloudauth_tutorial":"

请访问此网址,然后会进入授权流程。最后,您会被重定向回来。

","modal_pcloudauth_copybutton":"点击以复制网址","modal_pcloudauth_copynotice":"网址已复制!","modal_pcloudrevokeauth_step1":"第 1 步:访问以下网址,可以删除连接。","modal_pcloudrevokeauth_step2":"第 2 步:点击以下按钮,从而清理本地的登录信息。","modal_pcloudrevokeauth_clean":"清理本地登录信息","modal_pcloudrevokeauth_clean_desc":"您需要点击此按钮。","modal_pcloudrevokeauth_clean_button":"清理","modal_pcloudrevokeauth_clean_notice":"已清理!","modal_pcloudrevokeauth_clean_fail":"清理授权时候发生了错误。","modal_yandexdiskauth_tutorial":"

请访问此网址,然后会进入授权流程。最后,您会被重定向回来。

","modal_yandexdiskauth_copybutton":"点击以复制网址","modal_yandexdiskauth_copynotice":"网址已复制!","modal_yandexdisk_maualinput":"网站上的码","modal_yandexdisk_maualinput_desc":"请粘贴授权流程最后的那个码,然后点击确认。","modal_yandexdisk_maualinput_notice":"正在尝试连接 Yandex Disk 并更新授权信息......","modal_yandexdisk_maualinput_succ_notice":"很好!授权信息已更新!","modal_yandexdisk_maualinput_fail_notice":"更新授权信息失败。请稍后重试。","modal_yandexdiskrevokeauth_step1":"第 1 步:访问以下网址,可以删除连接。","modal_yandexdiskrevokeauth_step2":"第 2 步:点击以下按钮,从而清理本地的登录信息。","modal_yandexdiskrevokeauth_clean":"清理本地登录信息","modal_yandexdiskrevokeauth_clean_desc":"您需要点击此按钮。","modal_yandexdiskrevokeauth_clean_button":"清理","modal_yandexdiskrevokeauth_clean_notice":"已清理!","modal_yandexdiskrevokeauth_clean_fail":"清理授权时候发生了错误。","modal_koofrauth_tutorial":"

请访问此网址,然后会进入授权流程。最后,您会被重定向回来。

","modal_koofrauth_copybutton":"点击以复制网址","modal_koofrauth_copynotice":"网址已复制!","modal_koofr_maualinput":"网站上的码","modal_koofr_maualinput_desc":"请粘贴授权流程最后的那个码,然后点击确认。","modal_koofr_maualinput_notice":"正在尝试连接 Yandex Disk 并更新授权信息......","modal_koofr_maualinput_succ_notice":"很好!授权信息已更新!","modal_koofr_maualinput_fail_notice":"更新授权信息失败。请稍后重试。","modal_koofrrevokeauth_step1":"第 1 步:访问以下网址,可以删除连接。","modal_koofrrevokeauth_step2":"第 2 步:点击以下按钮,从而清理本地的登录信息。","modal_koofrrevokeauth_clean":"清理本地登录信息","modal_koofrrevokeauth_clean_desc":"您需要点击此按钮。","modal_koofrrevokeauth_clean_button":"清理","modal_koofrrevokeauth_clean_notice":"已清理!","modal_koofrrevokeauth_clean_fail":"清理授权时候发生了错误。","modal_remoteprefix_azureblobstorage_title":"您正在修改远端路径前缀设置","modal_remoteprefix_azureblobstorage_shortdesc":"1. 本插件并不会自动在远端把内容从旧文件夹移动到新文件夹。所有内容都会重新同步。\\n2. 如果你使得文本输入框为空,那么本设置为保存为空,文件将会使用 Vault 名字作为前缀。\\n3. 即使您设置了端对端加密的密码,远端文件夹名称本身也不会被加密。\\n4. 某些特殊字符,如“?”、“/”、“\\\\”是不允许的。文本前后的空格也会被自动删去。","modal_remoteprefix_azureblobstorage_invaliddirhint":"您所输入的内容含有某些特殊字符,如“?”、“/”、“\\\\”,它们是不允许的。","modal_remoteprefix_azureblobstorage_tosave":"您设定的新前缀为:“{{{prefix}}}”","modal_remoteprefix_azureblobstorage_secondconfirm_empty":"前缀为空,文件会保存在根目录","modal_remoteprefix_azureblobstorage_secondconfirm_change":"确认修改","modal_remoteprefix_azureblobstorage_notice":"新的远端路径前缀设置已保存!","modal_prorevokeauth":"点击这里和按照步骤取消授权。","modal_prorevokeauth_clean":"清理","modal_prorevokeauth_clean_desc":"清理本地授权记录","modal_prorevokeauth_clean_button":"清理","modal_prorevokeauth_clean_notice":"清理本地授权记录完毕","modal_prorevokeauth_clean_fail":"清理本地授权记录粗错。","modal_proauth_copybutton":"点击从而复制授权网址","modal_proauth_copynotice":"授权网址已复制!","modal_proauth_maualinput":"网站的授权码","modal_proauth_maualinput_desc":"请输入授权流程最后一步的授权码,然后点击确认。","modal_proauth_maualinput_notice":"正在连接,请稍候......","modal_proauth_maualinput_conn_fail":"连接失败","modal_cleardupfiles_warning":"警告:插件只是简单地扫描所有文件名含有 .dup 的作为重复文件。另外,本操作只删除本地文件,因此您需要触发同步来删除远端文件。","modal_cleardupfiles_warning_confirm":"确认删除","modal_cleardupfiles_warning_finished":"所有检测到的重复文件已被删除!","settings_onedrivefull":"Onedrive(个人版)(Full)设置","settings_chooseservice_onedrivefull":"OneDrive(个人版)(Full)(PRO)","settings_onedrivefull_disclaimer1":"声明:此插件不是微软或 OneDrive 的官方产品。","settings_onedrivefull_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了 OneDrive 有不符合预期的访问,请立刻从 https://microsoft.com/consent 删除记录于此插件的连接鉴权。","settings_onedrivefull_folder":"我们会在您的 OneDrive 上创建此文件夹并在里面同步:/{{remoteBaseDir}}。","settings_onedrivefull_nobiz":"现在只支持个人版 OneDrive。(暂时)并不支持企业版 OneDrive。","settings_onedrivefull_revoke":"撤回鉴权","settings_onedrivefull_revoke_desc":"您现在使用了用户名 {{username}} 来连接。如果想取消连接,请点击此按钮。","settings_onedrivefull_revoke_button":"撤回鉴权","settings_onedrivefull_auth":"鉴权","settings_onedrivefull_auth_desc":"鉴权。","settings_onedrivefull_auth_button":"鉴权","settings_onedrivefull_connect_succ":"很好!我们可连接上 OneDrive!","settings_onedrivefull_connect_fail":"我们未能连接上 OneDrive。","settings_onedrivefull_emptyfile":"空文件处理","settings_onedrivefull_emptyfile_desc":"OneDrive 不允许上传空文件(即使官网也是不允许的)。那么你想跳过空文件还是返回错误?","settings_onedrivefull_emptyfile_skip":"跳过","settings_onedrivefull_emptyfile_error":"返回错误和中断","settings_googledrive":"Google Drive (PRO) (beta)","settings_chooseservice_googledrive":"Google Drive (PRO) (beta)","settings_googledrive_disclaimer1":"声明:本插件不是 Google 的官方产品。只是用到了它的公开 API。","settings_googledrive_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 Google Drive 访问,请立刻在以下网站操作断开连接: https://myaccount.google.com/permissions 。","settings_googledrive_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_googledrive_notshowuphint":"Google Drive 设置不可用","settings_googledrive_notshowuphint_desc":"Google Drive 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_googledrive_notshowuphint_view_pro":"查看 PRO 相关设置","settings_googledrive_folder":"我们会在 Google Drive 创建此文件夹并同步内容进去: {{remoteBaseDir}} 。请不要手动在网站上创建。","settings_googledrive_revoke":"撤回鉴权","settings_googledrive_revoke_desc":"您现在已连接。如果想取消连接,请点击此按钮。","settings_googledrive_revoke_button":"撤回鉴权","settings_googledrive_auth":"鉴权","settings_googledrive_auth_desc":"鉴权.","settings_googledrive_auth_button":"鉴权","settings_googledrive_connect_succ":"很好!我们可连接上 Google Drive!","settings_googledrive_connect_fail":"我们未能连接上 Google Drive。","settings_box":"Box (PRO) (beta)","settings_chooseservice_box":"Box (PRO) (beta)","settings_box_disclaimer1":"声明:本插件不是 Box 的官方产品。只是用到了它的公开 API。","settings_box_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 Box 访问,请立刻在以下网站操作断开连接: https://app.box.com/account/security 。","settings_box_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_box_notshowuphint":"Box 设置不可用","settings_box_notshowuphint_desc":"Box 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_box_notshowuphint_view_pro":"查看 PRO 相关设置","settings_box_folder":"我们会在 Box 创建此文件夹并同步内容进去: {{remoteBaseDir}} 。请不要手动在网站上创建。","settings_box_revoke":"撤回鉴权","settings_box_revoke_desc":"您现在已连接。如果想取消连接,请点击此按钮。","settings_box_revoke_button":"撤回鉴权","settings_box_auth":"鉴权","settings_box_auth_desc":"鉴权.","settings_box_auth_button":"鉴权","settings_box_connect_succ":"很好!我们可连接上 Box!","settings_box_connect_fail":"我们未能连接上 Box。","settings_pcloud":"pCloud (PRO) (beta)","settings_chooseservice_pcloud":"pCloud (PRO) (beta)","settings_pcloud_disclaimer1":"声明:本插件不是 pCloud 的官方产品。只是用到了它的公开 API。","settings_pcloud_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 pCloud 访问,请立刻在以下网站操作断开连接: https://my.pcloud.com/#page=settings&settings=tab-apps 。","settings_pcloud_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_pcloud_notshowuphint":"pCloud 设置不可用","settings_pcloud_notshowuphint_desc":"pCloud 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_pcloud_notshowuphint_view_pro":"查看 PRO 相关设置","settings_pcloud_folder":"我们会在 pCloud 创建此文件夹并同步内容进去: {{remoteBaseDir}} 。请不要手动在网站上创建。","settings_pcloud_revoke":"撤回鉴权","settings_pcloud_revoke_desc":"您现在已连接。如果想取消连接,请点击此按钮。","settings_pcloud_revoke_button":"撤回鉴权","settings_pcloud_auth":"鉴权","settings_pcloud_auth_desc":"鉴权.","settings_pcloud_auth_button":"鉴权","settings_pcloud_emptyfile":"空文件","settings_pcloud_emptyfile_desc":"pCloud API 不支持上传空文件,怎么处理?","settings_pcloud_emptyfile_skip":"跳过","settings_pcloud_emptyfile_error":"提示错误","settings_pcloud_connect_succ":"很好!我们可连接上 pCloud!","settings_pcloud_connect_fail":"我们未能连接上 pCloud。","settings_yandexdisk":"Yandex Disk (PRO) (beta)","settings_chooseservice_yandexdisk":"Yandex Disk (PRO) (beta)","settings_yandexdisk_disclaimer1":"声明:本插件不是 Yandex Disk 的官方产品。只是用到了它的公开 API。","settings_yandexdisk_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 Yandex Disk 访问,请立刻在以下网站操作断开连接: https://id.yandex.com/profile/devices 。","settings_yandexdisk_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_yandexdisk_notshowuphint":"Yandex Disk 设置不可用","settings_yandexdisk_notshowuphint_desc":"Yandex Disk 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_yandexdisk_notshowuphint_view_pro":"查看 PRO 相关设置","settings_yandexdisk_folder":"我们会在 Yandex Disk 创建此文件夹并同步内容进去: {{remoteBaseDir}} 。请不要手动在网站上创建。","settings_yandexdisk_revoke":"撤回鉴权","settings_yandexdisk_revoke_desc":"您现在已连接。如果想取消连接,请点击此按钮。","settings_yandexdisk_revoke_button":"撤回鉴权","settings_yandexdisk_auth":"鉴权","settings_yandexdisk_auth_desc":"鉴权.","settings_yandexdisk_auth_button":"鉴权","settings_yandexdisk_connect_succ":"很好!我们可连接上 Yandex Disk!","settings_yandexdisk_connect_fail":"我们未能连接上 Yandex Disk。","settings_koofr":"Koofr (PRO) (beta)","settings_chooseservice_koofr":"Koofr (PRO) (beta)","settings_koofr_disclaimer1":"声明:本插件不是 Koofr 的官方产品。只是用到了它的公开 API。","settings_koofr_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 Koofr 访问,请立刻在以下网站操作断开连接: https://app.koofr.net/app/admin/preferences/security 。","settings_koofr_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_koofr_notshowuphint":"Koofr 设置不可用","settings_koofr_notshowuphint_desc":"Koofr 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_koofr_notshowuphint_view_pro":"查看 PRO 相关设置","settings_koofr_folder":"我们会在 Koofr 创建此文件夹并同步内容进去: {{remoteBaseDir}} 。请不要手动在网站上创建。","settings_koofr_revoke":"撤回鉴权","settings_koofr_revoke_desc":"您现在已连接。如果想取消连接,请点击此按钮。","settings_koofr_revoke_button":"撤回鉴权","settings_koofr_auth":"鉴权","settings_koofr_auth_desc":"鉴权.","settings_koofr_auth_button":"鉴权","settings_koofr_connect_succ":"很好!我们可连接上 Koofr!","settings_koofr_connect_fail":"我们未能连接上 Koofr。","settings_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_chooseservice_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_azureblobstorage_disclaimer1":"声明:本插件不是微软或 Azure 的官方产品。只是用到了 Azure 的公开 API。","settings_azureblobstorage_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现任何不符合预期的 Azure Blob Storage 访问,请立刻删除 SAS Url 然后修改预设的 policy 或账号信息。","settings_azureblobstorage_pro_desc":"

!!这是 PRO(付费)功能! 您需要在线账号来使用此功能!!向下滑可以看到 PRO 账号的更多信息。)

","settings_azureblobstorage_notshowuphint":"Azure Blob Storage 设置不可用","settings_azureblobstorage_notshowuphint_desc":"Azure Blob Storage 设置不可用,因为您没有在 Remotely Save 账号里开启这个 PRO 功能。","settings_azureblobstorage_notshowuphint_view_pro":"查看 PRO 相关设置","settings_azureblobstorage_folder":"Azure Blob Storage 里,我们会用这个前缀保存你的文件: {{remoteBaseDir}} 。","settings_azureblobstorage_containersasurl":"Container SAS Url","settings_azureblobstorage_containersasurl_desc":"目前只支持通过 Container SAS Url 进行连接。请记得同时设置 CORS。可阅读文档获取更多说明。","settings_azureblobstorage_containername":"Container 名字","settings_azureblobstorage_containername_desc":"输入 Container 名字。","settings_azureblobstorage_remoteprefix":"修改远端前缀路径","settings_azureblobstorage_remoteprefix_desc":"您可以在这里修改路径前缀。如果设置为空,那么库(vault)名字会作为前缀。不允许设置空前缀。您需要点击“确认”。","settings_azureblobstorage_parts":"分块并行度","settings_azureblobstorage_parts_desc":"大文件会被分块上传。您希望同一时间最多有多少个分块被上传?","settings_azureblobstorage_generatefolderobject":"是否生成文件夹 Object","settings_azureblobstorage_generatefolderobject_desc":"Azure Blob Storage 不存在“真正”的文件夹。如果您设置了“生成”,那么插件会上传 0 字节的以“/”结尾的 Object 来代表文件夹。默认跳过生成这种文件夹 Object。","settings_azureblobstorage_generatefolderobject_notgenerate":"不生成(默认)","settings_azureblobstorage_generatefolderobject_generate":"生成","settings_azureblobstorage_connect_succ":"很好!我们可连接上 Azure Blob Storage!","settings_azureblobstorage_connect_fail":"我们未能连接上 Azure Blob Storage。","settings_export_onedrivefull_button":"导出 OneDrive (Full) 部分","settings_export_googledrive_button":"导出 Google Drive 部分","settings_export_box_button":"导出 Box 部分","settings_export_pcloud_button":"导出 pCloud 部分","settings_export_yandexdisk_button":"导出 Yandex Disk 部分","settings_export_koofr_button":"导出 Koofr 部分","settings_export_azureblobstorage_button":"导出 Azure Blob Storage 部分","settings_cleardupfiles":"删除智能处理冲突生成的重复文件","settings_cleardupfiles_desc":"如果用过智能处理冲突 (PRO) 功能,插件可能会生成重复文件。如果您真的确认了所有重复文件都不需要了,那么可以删除本地的所有这些文件。","settings_cleardupfiles_button":"开始扫描","settings_pro":"账号(PRO 付费功能)","settings_pro_tutorial":"

使用 Remotely Save 的基本功能是免费的,而且需要注册对应账号。

但是,您需要注册账号和对PRO功能付费使用,如智能处理冲突功能。

第一步:点击按钮从而注册和登录网站:https://remotelysave.com。注意:这和 Obsidian 官方账号无关,是不同的账号。

第二部:点击“连接”按钮,从而连接本设备和在线账号。","settings_pro_features":"功能","settings_pro_features_desc":"您开通了以下功能:
{{{features}}}","settings_pro_features_refresh_button":"再次检查","settings_pro_features_refresh_fetch":"正在获取数据......","settings_pro_features_refresh_succ":"已刷新!","settings_pro_revoke":"断开连接","settings_pro_revoke_desc":"您已连接上账号 {{email}}。如果要取消连接,请点击此按钮。","settings_pro_revoke_button":"断开连接","settings_pro_intro":"Remotely Save 账号","settings_pro_intro_desc":"点击此按钮,从而到网站上注册和登录。","settings_pro_intro_button":"注册或登录","settings_pro_auth":"连接","settings_pro_auth_desc":"在网站上注册和登录后,您需要“连接”本设备和在线账号。请点击按钮开始连接。","settings_pro_auth_button":"连接"}'),zh_tw:JSON.parse('{"settings_conflictaction_smart_conflict":"智慧處理衝突 (PRO) (beta)","settings_conflictaction_smart_conflict_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

  • 小 markdown 檔案,本外掛嘗試使用 diff3 演算法合併它;
  • 對於大檔案或非 markdown 檔案,本外掛嘗試改名字並均進行儲存。

請注意先手動備份 vault 檔案再用此功能!

","protocol_pro_connecting":"正在連線","protocol_pro_connect_manualinput_succ":"連線成功","protocol_pro_connect_fail":"Remotely Save 官網返回錯誤。可能是網路連線不穩定。也可能是您拒絕了授權?","protocol_pro_connect_succ_revoke":"您已連線上賬號 {{email}}。如果要取消連線,請點選此按鈕。","protocol_onedrivefull_connecting":"正在連線 OneDrive……\\n請不要關閉此彈窗。","protocol_onedrivefull_connect_succ_revoke":"您已作為使用者 {{username}} 連線上了。如果您想取消連線,請點選此按鈕。","protocol_onedrivefull_connect_fail":"OneDrive 的回撥請求有點異常。您是否拒絕了鑑權?","protocol_onedrivefull_connect_unknown":"不知道如何處理此 callback:{{params}}","protocol_box_connecting":"正在連線","protocol_box_connect_manualinput_succ":"連線成功","protocol_box_connect_fail":"Box 官網返回錯誤。可能是網路連線不穩定。也可能是您拒絕了授權?","protocol_box_connect_succ_revoke":"您已連線上賬號。如果要取消連線,請點選此按鈕。","protocol_pcloud_connecting":"正在連線","protocol_pcloud_connect_manualinput_succ":"連線成功","protocol_pcloud_connect_fail":"pCloud 官網返回錯誤。可能是網路連線不穩定。也可能是您拒絕了授權?","protocol_pcloud_connect_succ_revoke":"您已連線上賬號。如果要取消連線,請點選此按鈕。","protocol_yandexdisk_connecting":"正在連線","protocol_yandexdisk_connect_manualinput_succ":"連線成功","protocol_yandexdisk_connect_fail":"Yandex Disk 官網返回錯誤。可能是網路連線不穩定。也可能是您拒絕了授權?","protocol_yandexdisk_connect_succ_revoke":"您已連線上賬號。如果要取消連線,請點選此按鈕。","protocol_koofr_connecting":"正在連線","protocol_koofr_connect_manualinput_succ":"連線成功","protocol_koofr_connect_fail":"Yandex Disk 官網返回錯誤。可能是網路連線不穩定。也可能是您拒絕了授權?","protocol_koofr_connect_succ_revoke":"您已連線上賬號。如果要取消連線,請點選此按鈕。","modal_onedrivefullauth_shortdesc":"現在只支援個人版 OneDrive,(暫)不支援企業版。\\n在瀏覽器中訪問以下地址,然後按照網頁提示操作。\\n到了最後,您應該會被自動重定向回來 Obsidian。","modal_onedrivefullauth_shortdesc_linux":"您正在用 Linux,有可能無法跳轉回來。請考慮使用 flatpack 版本的 Obsidian,或建立 obsidian.desktop 檔案。","modal_onedrivefullauth_copybutton":"點選此按鈕從而複製鑑權 url","modal_onedrivefullauth_copynotice":"鑑權 url 已複製到剪貼簿!","modal_onedrivefullrevokeauth_step1":"第 1 步:用瀏覽器開啟以下地址,點選本外掛對應的“Edit”按鈕,點選“Remove these permissions”按鈕。","modal_onedrivefullrevokeauth_step2":"第 2 步:點選以下按鈕,清理本地儲存的登入資訊。","modal_onedrivefullrevokeauth_clean":"清理本地儲存的登入資訊","modal_onedrivefullrevokeauth_clean_desc":"您需要點選“清理”按鈕。","modal_onedrivefullrevokeauth_clean_button":"清理","modal_onedrivefullrevokeauth_clean_notice":"已清理!","modal_onedrivefullrevokeauth_clean_fail":"鑑權途中出錯了。","modal_googledriveauth_tutorial":"

請訪問此網址,然後會進入授權流程。最後,您會看到一個碼,請複製貼上到這裡然後提交。

","modal_googledriveauth_copybutton":"點選以複製網址","modal_googledriveauth_copynotice":"網址已複製!","modal_googledrivce_maualinput":"網站上的碼","modal_googledrivce_maualinput_desc":"請貼上授權流程最後的那個碼,然後點選確認。","modal_googledrive_maualinput_notice":"正在嘗試連線 Google 並更新授權資訊......","modal_googledrive_maualinput_succ_notice":"很好!授權資訊已更新!","modal_googledrive_maualinput_fail_notice":"更新授權資訊失敗。請稍後重試。","modal_googledriverevokeauth_step1":"第 1 步:訪問以下網址,可以刪除連線。","modal_googledriverevokeauth_step2":"第 2 步:點選以下按鈕,從而清理本地的登入資訊。","modal_googledriverevokeauth_clean":"清理本地登入資訊","modal_googledriverevokeauth_clean_desc":"您需要點選此按鈕。","modal_googledriverevokeauth_clean_button":"清理","modal_googledriverevokeauth_clean_notice":"已清理!","modal_googledriverevokeauth_clean_fail":"清理授權時候發生了錯誤。","modal_boxauth_tutorial":"

請訪問此網址,然後會進入授權流程。最後,您會被重定向回來。

","modal_boxauth_copybutton":"點選以複製網址","modal_boxauth_copynotice":"網址已複製!","modal_box_maualinput":"網站上的碼","modal_box_maualinput_desc":"請貼上授權流程最後的那個碼,然後點選確認。","modal_box_maualinput_notice":"正在嘗試連線 Box 並更新授權資訊......","modal_box_maualinput_succ_notice":"很好!授權資訊已更新!","modal_box_maualinput_fail_notice":"更新授權資訊失敗。請稍後重試。","modal_boxrevokeauth_step1":"第 1 步:訪問以下網址,可以刪除連線。","modal_boxrevokeauth_step2":"第 2 步:點選以下按鈕,從而清理本地的登入資訊。","modal_boxrevokeauth_clean":"清理本地登入資訊","modal_boxrevokeauth_clean_desc":"您需要點選此按鈕。","modal_boxrevokeauth_clean_button":"清理","modal_boxrevokeauth_clean_notice":"已清理!","modal_boxrevokeauth_clean_fail":"清理授權時候發生了錯誤。","modal_pcloudauth_tutorial":"

請訪問此網址,然後會進入授權流程。最後,您會被重定向回來。

","modal_pcloudauth_copybutton":"點選以複製網址","modal_pcloudauth_copynotice":"網址已複製!","modal_pcloudrevokeauth_step1":"第 1 步:訪問以下網址,可以刪除連線。","modal_pcloudrevokeauth_step2":"第 2 步:點選以下按鈕,從而清理本地的登入資訊。","modal_pcloudrevokeauth_clean":"清理本地登入資訊","modal_pcloudrevokeauth_clean_desc":"您需要點選此按鈕。","modal_pcloudrevokeauth_clean_button":"清理","modal_pcloudrevokeauth_clean_notice":"已清理!","modal_pcloudrevokeauth_clean_fail":"清理授權時候發生了錯誤。","modal_yandexdiskauth_tutorial":"

請訪問此網址,然後會進入授權流程。最後,您會被重定向回來。

","modal_yandexdiskauth_copybutton":"點選以複製網址","modal_yandexdiskauth_copynotice":"網址已複製!","modal_yandexdisk_maualinput":"網站上的碼","modal_yandexdisk_maualinput_desc":"請貼上授權流程最後的那個碼,然後點選確認。","modal_yandexdisk_maualinput_notice":"正在嘗試連線 Yandex Disk 並更新授權資訊......","modal_yandexdisk_maualinput_succ_notice":"很好!授權資訊已更新!","modal_yandexdisk_maualinput_fail_notice":"更新授權資訊失敗。請稍後重試。","modal_yandexdiskrevokeauth_step1":"第 1 步:訪問以下網址,可以刪除連線。","modal_yandexdiskrevokeauth_step2":"第 2 步:點選以下按鈕,從而清理本地的登入資訊。","modal_yandexdiskrevokeauth_clean":"清理本地登入資訊","modal_yandexdiskrevokeauth_clean_desc":"您需要點選此按鈕。","modal_yandexdiskrevokeauth_clean_button":"清理","modal_yandexdiskrevokeauth_clean_notice":"已清理!","modal_yandexdiskrevokeauth_clean_fail":"清理授權時候發生了錯誤。","modal_koofrauth_tutorial":"

請訪問此網址,然後會進入授權流程。最後,您會被重定向回來。

","modal_koofrauth_copybutton":"點選以複製網址","modal_koofrauth_copynotice":"網址已複製!","modal_koofr_maualinput":"網站上的碼","modal_koofr_maualinput_desc":"請貼上授權流程最後的那個碼,然後點選確認。","modal_koofr_maualinput_notice":"正在嘗試連線 Yandex Disk 並更新授權資訊......","modal_koofr_maualinput_succ_notice":"很好!授權資訊已更新!","modal_koofr_maualinput_fail_notice":"更新授權資訊失敗。請稍後重試。","modal_koofrrevokeauth_step1":"第 1 步:訪問以下網址,可以刪除連線。","modal_koofrrevokeauth_step2":"第 2 步:點選以下按鈕,從而清理本地的登入資訊。","modal_koofrrevokeauth_clean":"清理本地登入資訊","modal_koofrrevokeauth_clean_desc":"您需要點選此按鈕。","modal_koofrrevokeauth_clean_button":"清理","modal_koofrrevokeauth_clean_notice":"已清理!","modal_koofrrevokeauth_clean_fail":"清理授權時候發生了錯誤。","modal_remoteprefix_azureblobstorage_title":"您正在修改遠端路徑字首設定","modal_remoteprefix_azureblobstorage_shortdesc":"1. 本外掛並不會自動在遠端把內容從舊資料夾移動到新資料夾。所有內容都會重新同步。\\n2. 如果你使得文字輸入框為空,那麼本設定為儲存為空,檔案將會使用 Vault 名字作為字首。\\n3. 即使您設定了端對端加密的密碼,遠端資料夾名稱本身也不會被加密。\\n4. 某些特殊字元,如“?”、“/”、“\\\\”是不允許的。文字前後的空格也會被自動刪去。","modal_remoteprefix_azureblobstorage_invaliddirhint":"您所輸入的內容含有某些特殊字元,如“?”、“/”、“\\\\”,它們是不允許的。","modal_remoteprefix_azureblobstorage_tosave":"您設定的新字首為:“{{{prefix}}}”","modal_remoteprefix_azureblobstorage_secondconfirm_empty":"字首為空,檔案會儲存在根目錄","modal_remoteprefix_azureblobstorage_secondconfirm_change":"確認修改","modal_remoteprefix_azureblobstorage_notice":"新的遠端路徑字首設定已儲存!","modal_prorevokeauth":"點選這裡和按照步驟取消授權。","modal_prorevokeauth_clean":"清理","modal_prorevokeauth_clean_desc":"清理本地授權記錄","modal_prorevokeauth_clean_button":"清理","modal_prorevokeauth_clean_notice":"清理本地授權記錄完畢","modal_prorevokeauth_clean_fail":"清理本地授權記錄粗錯。","modal_proauth_copybutton":"點選從而複製授權網址","modal_proauth_copynotice":"授權網址已複製!","modal_proauth_maualinput":"網站的授權碼","modal_proauth_maualinput_desc":"請輸入授權流程最後一步的授權碼,然後點選確認。","modal_proauth_maualinput_notice":"正在連線,請稍候......","modal_proauth_maualinput_conn_fail":"連線失敗","modal_cleardupfiles_warning":"警告:外掛只是簡單地掃描所有檔名含有 .dup 的作為重複檔案。另外,本操作只刪除本地檔案,因此您需要觸發同步來刪除遠端檔案。","modal_cleardupfiles_warning_confirm":"確認刪除","modal_cleardupfiles_warning_finished":"所有檢測到的重複檔案已被刪除!","settings_onedrivefull":"Onedrive(個人版)(Full)設定","settings_chooseservice_onedrivefull":"OneDrive(個人版)(Full)(PRO)","settings_onedrivefull_disclaimer1":"宣告:此外掛不是微軟或 OneDrive 的官方產品。","settings_onedrivefull_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現了 OneDrive 有不符合預期的訪問,請立刻從 https://microsoft.com/consent 刪除記錄於此外掛的連線鑑權。","settings_onedrivefull_folder":"我們會在您的 OneDrive 上建立此資料夾並在裡面同步:/{{remoteBaseDir}}。","settings_onedrivefull_nobiz":"現在只支援個人版 OneDrive。(暫時)並不支援企業版 OneDrive。","settings_onedrivefull_revoke":"撤回鑑權","settings_onedrivefull_revoke_desc":"您現在使用了使用者名稱 {{username}} 來連線。如果想取消連線,請點選此按鈕。","settings_onedrivefull_revoke_button":"撤回鑑權","settings_onedrivefull_auth":"鑑權","settings_onedrivefull_auth_desc":"鑑權。","settings_onedrivefull_auth_button":"鑑權","settings_onedrivefull_connect_succ":"很好!我們可連線上 OneDrive!","settings_onedrivefull_connect_fail":"我們未能連線上 OneDrive。","settings_onedrivefull_emptyfile":"空檔案處理","settings_onedrivefull_emptyfile_desc":"OneDrive 不允許上傳空檔案(即使官網也是不允許的)。那麼你想跳過空檔案還是返回錯誤?","settings_onedrivefull_emptyfile_skip":"跳過","settings_onedrivefull_emptyfile_error":"返回錯誤和中斷","settings_googledrive":"Google Drive (PRO) (beta)","settings_chooseservice_googledrive":"Google Drive (PRO) (beta)","settings_googledrive_disclaimer1":"宣告:本外掛不是 Google 的官方產品。只是用到了它的公開 API。","settings_googledrive_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 Google Drive 訪問,請立刻在以下網站操作斷開連線: https://myaccount.google.com/permissions 。","settings_googledrive_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_googledrive_notshowuphint":"Google Drive 設定不可用","settings_googledrive_notshowuphint_desc":"Google Drive 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_googledrive_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_googledrive_folder":"我們會在 Google Drive 建立此資料夾並同步內容進去: {{remoteBaseDir}} 。請不要手動在網站上建立。","settings_googledrive_revoke":"撤回鑑權","settings_googledrive_revoke_desc":"您現在已連線。如果想取消連線,請點選此按鈕。","settings_googledrive_revoke_button":"撤回鑑權","settings_googledrive_auth":"鑑權","settings_googledrive_auth_desc":"鑑權.","settings_googledrive_auth_button":"鑑權","settings_googledrive_connect_succ":"很好!我們可連線上 Google Drive!","settings_googledrive_connect_fail":"我們未能連線上 Google Drive。","settings_box":"Box (PRO) (beta)","settings_chooseservice_box":"Box (PRO) (beta)","settings_box_disclaimer1":"宣告:本外掛不是 Box 的官方產品。只是用到了它的公開 API。","settings_box_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 Box 訪問,請立刻在以下網站操作斷開連線: https://app.box.com/account/security 。","settings_box_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_box_notshowuphint":"Box 設定不可用","settings_box_notshowuphint_desc":"Box 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_box_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_box_folder":"我們會在 Box 建立此資料夾並同步內容進去: {{remoteBaseDir}} 。請不要手動在網站上建立。","settings_box_revoke":"撤回鑑權","settings_box_revoke_desc":"您現在已連線。如果想取消連線,請點選此按鈕。","settings_box_revoke_button":"撤回鑑權","settings_box_auth":"鑑權","settings_box_auth_desc":"鑑權.","settings_box_auth_button":"鑑權","settings_box_connect_succ":"很好!我們可連線上 Box!","settings_box_connect_fail":"我們未能連線上 Box。","settings_pcloud":"pCloud (PRO) (beta)","settings_chooseservice_pcloud":"pCloud (PRO) (beta)","settings_pcloud_disclaimer1":"宣告:本外掛不是 pCloud 的官方產品。只是用到了它的公開 API。","settings_pcloud_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 pCloud 訪問,請立刻在以下網站操作斷開連線: https://my.pcloud.com/#page=settings&settings=tab-apps 。","settings_pcloud_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_pcloud_notshowuphint":"pCloud 設定不可用","settings_pcloud_notshowuphint_desc":"pCloud 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_pcloud_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_pcloud_folder":"我們會在 pCloud 建立此資料夾並同步內容進去: {{remoteBaseDir}} 。請不要手動在網站上建立。","settings_pcloud_revoke":"撤回鑑權","settings_pcloud_revoke_desc":"您現在已連線。如果想取消連線,請點選此按鈕。","settings_pcloud_revoke_button":"撤回鑑權","settings_pcloud_auth":"鑑權","settings_pcloud_auth_desc":"鑑權.","settings_pcloud_auth_button":"鑑權","settings_pcloud_emptyfile":"空檔案","settings_pcloud_emptyfile_desc":"pCloud API 不支援上傳空檔案,怎麼處理?","settings_pcloud_emptyfile_skip":"跳過","settings_pcloud_emptyfile_error":"提示錯誤","settings_pcloud_connect_succ":"很好!我們可連線上 pCloud!","settings_pcloud_connect_fail":"我們未能連線上 pCloud。","settings_yandexdisk":"Yandex Disk (PRO) (beta)","settings_chooseservice_yandexdisk":"Yandex Disk (PRO) (beta)","settings_yandexdisk_disclaimer1":"宣告:本外掛不是 Yandex Disk 的官方產品。只是用到了它的公開 API。","settings_yandexdisk_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 Yandex Disk 訪問,請立刻在以下網站操作斷開連線: https://id.yandex.com/profile/devices 。","settings_yandexdisk_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_yandexdisk_notshowuphint":"Yandex Disk 設定不可用","settings_yandexdisk_notshowuphint_desc":"Yandex Disk 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_yandexdisk_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_yandexdisk_folder":"我們會在 Yandex Disk 建立此資料夾並同步內容進去: {{remoteBaseDir}} 。請不要手動在網站上建立。","settings_yandexdisk_revoke":"撤回鑑權","settings_yandexdisk_revoke_desc":"您現在已連線。如果想取消連線,請點選此按鈕。","settings_yandexdisk_revoke_button":"撤回鑑權","settings_yandexdisk_auth":"鑑權","settings_yandexdisk_auth_desc":"鑑權.","settings_yandexdisk_auth_button":"鑑權","settings_yandexdisk_connect_succ":"很好!我們可連線上 Yandex Disk!","settings_yandexdisk_connect_fail":"我們未能連線上 Yandex Disk。","settings_koofr":"Koofr (PRO) (beta)","settings_chooseservice_koofr":"Koofr (PRO) (beta)","settings_koofr_disclaimer1":"宣告:本外掛不是 Koofr 的官方產品。只是用到了它的公開 API。","settings_koofr_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 Koofr 訪問,請立刻在以下網站操作斷開連線: https://app.koofr.net/app/admin/preferences/security 。","settings_koofr_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_koofr_notshowuphint":"Koofr 設定不可用","settings_koofr_notshowuphint_desc":"Koofr 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_koofr_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_koofr_folder":"我們會在 Koofr 建立此資料夾並同步內容進去: {{remoteBaseDir}} 。請不要手動在網站上建立。","settings_koofr_revoke":"撤回鑑權","settings_koofr_revoke_desc":"您現在已連線。如果想取消連線,請點選此按鈕。","settings_koofr_revoke_button":"撤回鑑權","settings_koofr_auth":"鑑權","settings_koofr_auth_desc":"鑑權.","settings_koofr_auth_button":"鑑權","settings_koofr_connect_succ":"很好!我們可連線上 Koofr!","settings_koofr_connect_fail":"我們未能連線上 Koofr。","settings_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_chooseservice_azureblobstorage":"Azure Blob Storage (PRO) (alpha)","settings_azureblobstorage_disclaimer1":"宣告:本外掛不是微軟或 Azure 的官方產品。只是用到了 Azure 的公開 API。","settings_azureblobstorage_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現任何不符合預期的 Azure Blob Storage 訪問,請立刻刪除 SAS Url 然後修改預設的 policy 或賬號資訊。","settings_azureblobstorage_pro_desc":"

!!這是 PRO(付費)功能! 您需要線上賬號來使用此功能!!向下滑可以看到 PRO 賬號的更多資訊。)

","settings_azureblobstorage_notshowuphint":"Azure Blob Storage 設定不可用","settings_azureblobstorage_notshowuphint_desc":"Azure Blob Storage 設定不可用,因為您沒有在 Remotely Save 賬號裡開啟這個 PRO 功能。","settings_azureblobstorage_notshowuphint_view_pro":"檢視 PRO 相關設定","settings_azureblobstorage_folder":"Azure Blob Storage 裡,我們會用這個字首儲存你的檔案: {{remoteBaseDir}} 。","settings_azureblobstorage_containersasurl":"Container SAS Url","settings_azureblobstorage_containersasurl_desc":"目前只支援透過 Container SAS Url 進行連線。請記得同時設定 CORS。可閱讀文件獲取更多說明。","settings_azureblobstorage_containername":"Container 名字","settings_azureblobstorage_containername_desc":"輸入 Container 名字。","settings_azureblobstorage_remoteprefix":"修改遠端字首路徑","settings_azureblobstorage_remoteprefix_desc":"您可以在這裡修改路徑字首。如果設定為空,那麼庫(vault)名字會作為字首。不允許設定空字首。您需要點選“確認”。","settings_azureblobstorage_parts":"分塊並行度","settings_azureblobstorage_parts_desc":"大檔案會被分塊上傳。您希望同一時間最多有多少個分塊被上傳?","settings_azureblobstorage_generatefolderobject":"是否生成資料夾 Object","settings_azureblobstorage_generatefolderobject_desc":"Azure Blob Storage 不存在“真正”的資料夾。如果您設定了“生成”,那麼外掛會上傳 0 位元組的以“/”結尾的 Object 來代表資料夾。預設跳過生成這種資料夾 Object。","settings_azureblobstorage_generatefolderobject_notgenerate":"不生成(預設)","settings_azureblobstorage_generatefolderobject_generate":"生成","settings_azureblobstorage_connect_succ":"很好!我們可連線上 Azure Blob Storage!","settings_azureblobstorage_connect_fail":"我們未能連線上 Azure Blob Storage。","settings_export_onedrivefull_button":"匯出 OneDrive (Full) 部分","settings_export_googledrive_button":"匯出 Google Drive 部分","settings_export_box_button":"匯出 Box 部分","settings_export_pcloud_button":"匯出 pCloud 部分","settings_export_yandexdisk_button":"匯出 Yandex Disk 部分","settings_export_koofr_button":"匯出 Koofr 部分","settings_export_azureblobstorage_button":"匯出 Azure Blob Storage 部分","settings_cleardupfiles":"刪除智慧處理衝突生成的重複檔案","settings_cleardupfiles_desc":"如果用過智慧處理衝突 (PRO) 功能,外掛可能會生成重複檔案。如果您真的確認了所有重複檔案都不需要了,那麼可以刪除本地的所有這些檔案。","settings_cleardupfiles_button":"開始掃描","settings_pro":"賬號(PRO 付費功能)","settings_pro_tutorial":"

使用 Remotely Save 的基本功能是免費的,而且需要註冊對應賬號。

但是,您需要註冊賬號和對PRO功能付費使用,如智慧處理衝突功能。

第一步:點選按鈕從而註冊和登入網站:https://remotelysave.com。注意:這和 Obsidian 官方賬號無關,是不同的賬號。

第二部:點選“連線”按鈕,從而連線本裝置和線上賬號。","settings_pro_features":"功能","settings_pro_features_desc":"您開通了以下功能:
{{{features}}}","settings_pro_features_refresh_button":"再次檢查","settings_pro_features_refresh_fetch":"正在獲取資料......","settings_pro_features_refresh_succ":"已重新整理!","settings_pro_revoke":"斷開連線","settings_pro_revoke_desc":"您已連線上賬號 {{email}}。如果要取消連線,請點選此按鈕。","settings_pro_revoke_button":"斷開連線","settings_pro_intro":"Remotely Save 賬號","settings_pro_intro_desc":"點選此按鈕,從而到網站上註冊和登入。","settings_pro_intro_button":"註冊或登入","settings_pro_auth":"連線","settings_pro_auth_desc":"在網站上註冊和登入後,您需要“連線”本裝置和線上賬號。請點選按鈕開始連線。","settings_pro_auth_button":"連線"}')},Zj={en:JSON.parse('{"confirm":"Confirm","disable":"Disable","enable":"Enable","goback":"Go Back","submit":"Submit","sometext":"Here are some texts.","syncrun_alreadyrunning":"New command {{newTriggerSource}} stops because {{pluginName}} is already running in stage {{syncStatus}}!","syncrun_syncingribbon":"{{pluginName}}: syncing from {{triggerSource}}","syncrun_step0":"0/8 Remotely Save is running in dry mode, thus not actual file changes would happen.","syncrun_step1":"1/8 Remotely Save is preparing ({{serviceType}})","syncrun_step2":"2/8 Starting to fetch remote meta data and check password.","syncrun_passworderr":"Something goes wrong while checking password.","syncrun_step3":"3/8 Starting to process remote data.","syncrun_step4":"4/8 Starting to fetch local meta data.","syncrun_step5":"5/8 Starting to fetch local prev sync data.","syncrun_step6":"6/8 Starting to generate sync plan.","syncrun_step7":"7/8 Remotely Save Sync data is exchanging!","syncrun_step7skip":"7/8 Remotely Save real sync is skipped in dry run mode.","syncrun_step8":"8/8 Remotely Save finished!","syncrun_shortstep0":"0/2 Remotely Save is running in dry mode, not actual file changes would happen.","syncrun_shortstep1":"1/2 Remotely Save starts running ({{serviceType}})","syncrun_shortstep2skip":"2/2 Remotely Save real sync is skipped in dry run mode.","syncrun_shortstep2":"2/2 Remotely Save finished!","syncrun_abort":"{{manifestID}}-{{theDate}}: abort sync, triggerSource={{triggerSource}}, error while {{syncStatus}}","syncrun_abort_protectmodifypercentage":"Abort! you set changing files >= {{protectModifyPercentage}}% is not allowed but {{realModifyDeleteCount}}/{{allFilesCount}}={{percent}}% is going to be modified or deleted! If you are sure you want this sync, please adjust the allowed ratio in the settings.","protocol_saveqr":"New settings for {{manifestName}} is imported and saved. Reopen the plugin settings to make it effective.","protocol_callbacknotsupported":"Your uri calls a callback that\'s not supported yet: {{params}}","protocol_dropbox_connecting":"Connecting to Dropbox...\\nPlease DO NOT close this modal.","protocol_dropbox_connect_succ":"Good! We\'ve connected to Dropbox as user {{username}}!","protocol_dropbox_connect_succ_revoke":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","protocol_dropbox_connect_fail":"Something went wrong from response from Dropbox. Maybe the network connection is not good. Maybe you rejected the auth?","protocol_dropbox_connect_unknown":"Do not know how to deal with the callback: {{params}}","protocol_dropbox_no_modal":"You are not startting Dropbox connection from the settings page. Abort.","protocol_onedrive_connecting":"Connecting to OneDrive...\\nPlease DO NOT close this modal.","protocol_onedrive_connect_succ_revoke":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","protocol_onedrive_connect_fail":"Something went wrong from response from OneDrive. Maybe you rejected the auth?","protocol_onedrive_connect_unknown":"Do not know how to deal with the callback: {{params}}","command_startsync":"start sync","command_drynrun":"start sync (dry run only)","command_exportsyncplans_1_only_change":"export sync plans (latest 1) (change part)","command_exportsyncplans_1":"export sync plans (latest 1)","command_exportsyncplans_5":"export sync plans (latest 5)","command_exportsyncplans_all":"export sync plans (all)","command_exportlogsindb":"export logs saved in db","statusbar_sync_source_manual":"Manual: ","statusbar_sync_source_dry":"Dry: ","statusbar_sync_source_auto":"Auto: ","statusbar_sync_source_auto_once_init":"Auto (init): ","statusbar_sync_source_auto_sync_on_save":"Auto (save): ","statusbar_sync_status_prefix_success":"Successfully synced ","statusbar_sync_status_prefix_failed":"Failed to sync ","statusbar_time_years":"{{time}} years ago","statusbar_time_months":"{{time}} months ago","statusbar_time_weeks":"{{time}} weeks ago","statusbar_time_days":"{{time}} days ago","statusbar_time_hours":"{{time}} hours ago","statusbar_time_minutes":"{{time}} minutes ago","statusbar_time_lessminute":"last minute ago","statusbar_time_now":"just now","statusbar_syncing":"Syncing...","statusbar_lastsync_label":"on {{date}}","statusbar_lastsync_never":"Never Synced","statusbar_lastsync_never_label":"Never Synced before","modal_password_title":"Hold on and PLEASE READ ON...","modal_password_shortdesc":"If the field is not empty, files would be encrypted locally before being uploaded.\\nIf the field is empty, then files would be uploaded without encryption.","modal_password_attn1":"Attention 1/5: The vault name is NOT encrypted. The plugin creates a folder with the vault name on some remote services.","modal_password_attn2":"Attention 2/5: The password itself is stored in PLAIN TEXT LOCALLY.","modal_password_attn3":"Attention 3/5: Some metadata are not encrypted or can be easily guessed. (File sizes are closed to their unencrypted ones, and directory path may be stored as 0-byte-size object.)","modal_password_attn4":"Attention 4/5: You should make sure the remote store IS EMPTY, or REMOTE FILES WERE ENCRYPTED BY THAT NEW PASSWORD, to avoid conflicts.","modal_password_attn5":"Attention 5/5: The longer the password, the better.","modal_password_secondconfirm":"The Second Confirm to change password.","modal_password_notice":"New password saved!","modal_encryptionmethod_title":"Hold on and PLEASE READ ON...","modal_encryptionmethod_shortdesc":"You are changing the encrpytion method but you have set the password before.\\nAfter switching the method, you need to manually and fully delete every encrypted vault files in the remote and re-sync (so that re-upload) the newly encrypted files again.","modal_remotebasedir_title":"You are changing the remote base directory config","modal_remotebasedir_shortdesc":"1. The plugin would NOT automatically move the content from the old directory to the new one directly on the remote. Everything syncs from the beginning again.\\n2. If you set the string to the empty, the config would be reset to use the vault folder name (the default config).\\n3. The remote directory name itself would not be encrypted even you\'ve set an E2E password.\\n4. Some special char like \'?\', \'/\', \'\\\\\' are not allowed. Spaces in the beginning or in the end are also trimmed.","modal_remotebasedir_invaliddirhint":"Your input contains special characters like \'?\', \'/\', \'\\\\\' which are not allowed.","modal_remotebasedir_secondconfirm_vaultname":"Reset To The Default Vault Folder Name","modal_remotebasedir_secondconfirm_change":"Confirm To Change","modal_remotebasedir_notice":"New remote base directory config saved!","modal_remoteprefix_s3_title":"You are changing the remote prefix config","modal_remoteprefix_s3_shortdesc":"1. The plugin would NOT automatically move the content from the old directory to the new one directly on the remote. Everything syncs from the beginning again.\\n2. If you set the string to the empty, the prefix will be empty and the files will be saved at the root of the bucket.\\n3. The remote directory name itself would not be encrypted even you\'ve set an E2E password.\\n4. Some special char like \'?\', \'/\', \'\\\\\' are not allowed. Spaces in the beginning or in the end are also trimmed.","modal_remoteprefix_s3_invaliddirhint":"Your input contains special characters like \'?\', \'/\', \'\\\\\' which are not allowed.","modal_remoteprefix_s3_tosave":"The prefix to save is \\"{{{prefix}}}\\"","modal_remoteprefix_s3_secondconfirm_empty":"The prefix is empty and the files will be saved at the root of the bucket.","modal_remoteprefix_s3_secondconfirm_change":"Confirm To Change","modal_remoteprefix_s3_notice":"New remote prefix config saved!","modal_dropboxauth_manualsteps":"Step 1: Visit the address in a browser, and follow the steps.\\nStep 2: In the end of the web flow, you obtain a long code. Paste it here then click \\"Submit\\".","modal_dropboxauth_autosteps":"Visit the address in a browser, and follow the steps.\\nFinally you should be redirected to Obsidian.","modal_dropboxauth_copybutton":"Click to copy the auth url","modal_dropboxauth_copynotice":"The auth url is copied to the clipboard!","modal_dropboxauth_maualinput":"Auth Code from web page","modal_dropboxauth_maualinput_desc":"You need to click \\"Confirm\\".","modal_dropboxauth_maualinput_notice":"Trying to connect to Dropbox","modal_dropboxauth_maualinput_conn_succ":"Good! We\'ve connected to Dropbox as user {{username}}!","modal_dropboxauth_maualinput_conn_succ_revoke":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","modal_dropboxauth_maualinput_conn_fail":"Something goes wrong while connecting to Dropbox.","modal_onedriveauth_shortdesc":"Currently only OneDrive for personal is supported. OneDrive for Business is NOT supported (yet).\\nVisit the address in a browser, and follow the steps.\\nFinally you should be redirected to Obsidian.","modal_onedriveauth_shortdesc_linux":"It seems that you are using Obsidian on Linux, and you might not be able to jump back here properly. Please consider using the flatpack version of Obsidian, or creating an obsidian.desktop file.","modal_onedriveauth_copybutton":"Click to copy the auth url","modal_onedriveauth_copynotice":"The auth url is copied to the clipboard!","modal_onedriverevokeauth_step1":"Step 1: Go to the following address, click the \\"Edit\\" button for the plugin, then click \\"Remove these permissions\\" button on the page.","modal_onedriverevokeauth_step2":"Step 2: Click the button below, to clean the locally-saved login credentials.","modal_onedriverevokeauth_clean":"Clean Locally-Saved Login Credentials","modal_onedriverevokeauth_clean_desc":"You need to click the button.","modal_onedriverevokeauth_clean_button":"Clean","modal_onedriverevokeauth_clean_notice":"Cleaned!","modal_onedriverevokeauth_clean_fail":"Something goes wrong while revoking.","modal_syncconfig_attn":"Attention 1/2: This only syncs (copies) the whole Obsidian config dir, not other startting-with-dot folders or files. Except for ignoring folders .git and node_modules, it also doesn\'t understand the meaning of sub-files and sub-folders inside the config dir.\\nAttention 2/2: After the config dir is synced, plugins settings might be corrupted, and Obsidian might need to be restarted to load the new settings.\\nIf you are agreed to take your own risk, please click the following second confirm button.","modal_syncconfig_secondconfirm":"The Second Confirm To Enable.","modal_syncconfig_notice":"You\'ve enabled syncing config folder!","modal_qr_shortdesc":"This exports (partial) settings.\\nYou can use another device to scan this qrcode.\\nOr, you can click the button to copy the special uri and paste it into another device\'s web browser or Remotely Save Import Setting.","modal_qr_button":"Click to copy the special URI","modal_qr_button_notice":"The special uri is copied to the clipboard!","modal_sizesconflict_title":"Remotely Save: Some conflict were found while skipping large files","modal_sizesconflict_desc":"You\'ve set skipping files larger than {{thresholdMB}} MB ({{thresholdBytes}} bytes).\\nBut the following files have sizes larger than the threshold on one side, and sizes smaller than the threshold on the other side.\\nTo avoid unexpected overwriting or deleting, the plugin stops, and you have to manually deal with at least one side of the files.","modal_sizesconflict_copybutton":"Click to copy all the below sizes conflicts info","modal_sizesconflict_copynotice":"All the sizes conflicts info have been copied to the clipboard!","settings_basic":"Basic Settings","settings_password":"Encryption Password","settings_password_desc":"Password for E2E encryption. Empty for no password. You need to click \\"Confirm\\". Attention: The password and other info are saved locally. After changing the password, you need to manually delete all files from the remote location and re-sync to upload the encrypted files again.","settings_encryptionmethod":"Encryption Method","settings_encryptionmethod_desc":"Encryption method for E2E encryption. The RClone Crypt format is recommended, although it does not encrypt the path structure. OpenSSL enc is the legacy format of this plugin. Both are not affliated with the official RClone and OpenSSL products or communities. Attention: After switching encryption methods, you need to manually delete all original files from the remote location and re-sync to upload the encrypted files again. More info is available in the online doc.","settings_encryptionmethod_rclone":"RClone Crypt (recommended)","settings_encryptionmethod_openssl":"OpenSSL enc (legacy)","settings_autorun":"Schedule For Auto Run","settings_autorun_desc":"The plugin tries to schedule the running after every interval. Battery may be impacted.","settings_autorun_notset":"(not set)","settings_autorun_1min":"every 1 minute","settings_autorun_5min":"every 5 minutes","settings_autorun_10min":"every 10 minutes","settings_autorun_30min":"every 30 minutes","settings_runoncestartup":"Run Once On Start Up Automatically","settings_runoncestartup_desc":"This setting causes the sync to run once automatically at startup. Changes will take effect on the NEXT startup. This setting is different from the \\"schedule for auto run\\" setting, which initiates syncing after every specified interval.","settings_runoncestartup_notset":"(not set)","settings_runoncestartup_1sec":"sync once after 1 second of start up","settings_runoncestartup_10sec":"sync once after 10 seconds of start up","settings_runoncestartup_30sec":"sync once after 30 seconds of start up","settings_synconsave":"Sync On Save (experimental)","settings_synconsave_desc":"If you change your file, the plugin tries to trigger a sync.","settings_synconsave_disable":"Disable (default)","settings_synconsave_enable":"Enable","settings_skiplargefiles":"Skip Large Files","settings_skiplargefiles_desc":"Skip files with sizes larger than the threshold. Here 1 MB = 10^6 bytes.","settings_skiplargefiles_notset":"(not set)","settings_ignorepaths":"Regex Of Paths To Ignore","settings_ignorepaths_desc":"Regex of paths of folders or files to ignore. One regex per line. The path is relative to the vault root without leading slash. Non-empty allow paths and non-empty ignore paths are effective together.","settings_onlyallowpaths":"Regex Of Paths To Allow","settings_onlyallowpaths_desc":"Regex of paths of folders or files to allow to sync. One regex per line. The path is relative to the vault root without leading slash. If this setting is not empty, all paths you want to sync including config dirs must be explicitly set here. Non-empty allow paths and non-empty ignore paths are effective together.","settings_enablestatusbar_info":"Show Last Successful Sync In Status Bar","settings_enablestatusbar_info_desc":"Show the time of the last successful sync in the status bar.","settings_enablestatusbar_reloadrequired_notice":"Reload the plugin for the changes to take effect.","settings_resetstatusbar_time":"Reset Last Successful Sync Time","settings_resetstatusbar_time_desc":"Reset last successful sync time.","settings_resetstatusbar_button":"Reset","settings_resetstatusbar_notice":"Reset done!","settings_checkonnectivity":"Check Connectivity","settings_checkonnectivity_desc":"Check connectivity.","settings_checkonnectivity_button":"Check","settings_checkonnectivity_checking":"Checking...","settings_remotebasedir":"Change The Remote Base Directory (experimental)","settings_remotebasedir_desc":"By default the content is synced to a remote directory with the same name as the vault name. You can change the remote folder name here, or keep the input field empty to reset to the default. You need to click \\"Confirm\\".","settings_remoteprefix_s3":"Change The Remote Prefix (experimental)","settings_remoteprefix_s3_desc":"By default in s3 the files are saved at the root of the bucket. You can change the remote prefix here, or keep the input field empty to reset to the default. You need to click \\"Confirm\\".","settings_s3":"Remote For S3 or compatible","settings_s3_disclaimer1":"Disclaimer: This plugin is NOT an official Amazon product.","settings_s3_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your bucket, please immediately delete the access key on your AWS (or other S3-service provider) settings.","settings_s3_cors":"You need to configure CORS to allow requests from origin app://obsidian.md and capacitor://localhost and http://localhost, and add ETag into exposed headers.","settings_s3_prod":"Some Amazon S3 official docs for references:","settings_s3_prod1":"Endpoint and region info","settings_s3_prod2":"Access Key ID and Secret Access Key info","settings_s3_prod3":"Configuring CORS","settings_s3_endpoint":"Endpoint","settings_s3_region":"Region","settings_s3_region_desc":"If you are not sure what to enter, you could try the value: us-east-1 .","settings_s3_accesskeyid":"Access Key ID","settings_s3_accesskeyid_desc":"Access key ID. Attention: Access key ID and other info are saved locally.","settings_s3_secretaccesskey":"Secret Access Key","settings_s3_secretaccesskey_desc":"Secret access key. Attention: Secret access key and other info are saved locally.","settings_s3_bucketname":"Bucket Name","settings_s3_bypasscorslocally":"Bypass CORS Issue Locally","settings_s3_bypasscorslocally_desc":"The plugin allows skipping server CORS config in new version of Obsidian ( desktop>=0.13.25 or iOS>=1.1.1 or Android>=1.2.1). If you encounter any issues, please disable this setting and config CORS on servers (allowing requests from app://obsidian.md and capacitor://localhost and http://localhost and add ETag into exposed headers).","settings_s3_parts":"Parts Concurrency","settings_s3_parts_desc":"Large files are split into small parts to upload in S3. How many parts do you want to upload in parallel at most?","settings_s3_accuratemtime":"Use Accurate MTime","settings_s3_accuratemtime_desc":"Read the uploaded accurate last modified time for better sync algorithm. But it causes extra api requests / time / money to the S3 endpoint.","settings_s3_urlstyle":"S3 URL style","settings_s3_urlstyle_desc":"Whether to force path-style URLs for S3 objects (e.g., https://s3.amazonaws.com/*/ instead of https://*.s3.amazonaws.com/).","settings_s3_reverse_proxy_no_sign_url":"S3 Reverse Proxy (No Sign) Url (experimental)","settings_s3_reverse_proxy_no_sign_url_desc":"S3 reverse proxy url without signature. This is useful if you use a revers proxy but do not change the original credential signature. No http(s):// prefix. Leave it blank if you don\'t know what it is.","settings_s3_generatefolderobject":"Generate Folder Object Or Not","settings_s3_generatefolderobject_desc":"S3 doesn\'t have \\"real\\" folder. If you set \\"Generate\\" here (or use old version), the plugin will upload a zero-byte object endding with \\"/\\" to represent the folder. In the new version, the plugin skips generating folder object by default.","settings_s3_generatefolderobject_notgenerate":"Not generate (default)","settings_s3_generatefolderobject_generate":"Generate","settings_s3_connect_succ":"Great! The bucket can be accessed.","settings_s3_connect_fail":"The S3 bucket cannot be reached.","settings_dropbox":"Remote For Dropbox","settings_dropbox_disclaimer1":"Disclaimer: This app is NOT an official Dropbox product.","settings_dropbox_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Dropbox, please immediately disconnect this app on https://www.dropbox.com/account/connected_apps .","settings_dropbox_folder":"We will create and sync inside the folder /Apps/{{pluginID}}/{{remoteBaseDir}} on your Dropbox.","settings_dropbox_revoke":"Revoke Auth","settings_dropbox_revoke_desc":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","settings_dropbox_revoke_button":"Revoke Auth","settings_dropbox_revoke_notice":"Revoked!","settings_dropbox_revoke_noticeerr":"Something goes wrong while revoking.","settings_dropbox_clearlocal":"Clear Locally Saved Credentials","settings_dropbox_clearlocal_desc":"You can forcefully clear the locally saved Dropbox login credentials, but not send revoke auth request to the server.","settings_dropbox_clearlocal_button":"Clear","settings_dropbox_clearlocal_notice":"Cleared!","settings_dropbox_auth":"Auth","settings_dropbox_auth_desc":"Auth.","settings_dropbox_auth_button":"Auth","settings_dropbox_connect_succ":"Great! We can connect to Dropbox!","settings_dropbox_connect_fail":"We cannot connect to Dropbox.","settings_onedrive":"Remote For Onedrive (for personal) (App Folder)","settings_onedrive_disclaimer1":"Disclaimer: This app is NOT an official Microsoft / OneDrive product.","settings_onedrive_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins could read the info. If you see any unintentional access to your Onedrive, please immediately disconnect this app on https://microsoft.com/consent .","settings_onedrive_folder":"We will create and sync inside the folder /Apps/{{pluginID}}/{{remoteBaseDir}} on your OneDrive.","settings_onedrive_nobiz":"Currently only OneDrive for personal is supported. OneDrive for Business is NOT supported (yet).","settings_onedrive_revoke":"Revoke Auth","settings_onedrive_revoke_desc":"You\'ve connected as user {{username}}. If you want to disconnect, click this button.","settings_onedrive_revoke_button":"Revoke Auth","settings_onedrive_auth":"Auth","settings_onedrive_auth_desc":"Auth.","settings_onedrive_auth_button":"Auth","settings_onedrive_connect_succ":"Great! We can connect to OneDrive!","settings_onedrive_connect_fail":"We cannot connect to OneDrive.","settings_onedrive_emptyfile":"Empty File Handling","settings_onedrive_emptyfile_desc":"OneDrive doesn\'t allow uploading empty file (even in its official website). Do you want to show up errors or silently skip the empty files?","settings_onedrive_emptyfile_skip":"Skip","settings_onedrive_emptyfile_error":"Error and abort","settings_webdav":"Remote For Webdav","settings_webdav_disclaimer1":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins may read the info. If you see any unintentional access to your webdav server, please immediately change the username and password.","settings_webdav_cors_os":"Obsidian desktop>=0.13.25 or iOS>=1.1.1 or Android>=1.2.1 supports bypassing CORS locally. But you are using an old version, and you\'re suggested to upgrade Obsidian.","settings_webdav_cors":"You need to configure CORS to allow requests from origin app://obsidian.md and capacitor://localhost and http://localhost","settings_webdav_folder":"We will create and sync inside the folder /{{remoteBaseDir}} on your server.","settings_webdav_addr":"Server Address","settings_webdav_addr_desc":"Server address.","settings_webdav_user":"Username","settings_webdav_user_desc":"Username. Attention: the username and other info are saved locally.","settings_webdav_password":"Password","settings_webdav_password_desc":"Password. Attention: the password and other info are saved locally.","settings_webdav_auth":"Auth Type","settings_webdav_auth_desc":"If no password is provided, this option will be ignored.","settings_webdav_depth":"Depth Header Sent To Servers","settings_webdav_depth_desc":"Webdav servers should be configured to allow requests with header Depth being \'1\' or \'Infinity\'. If you are not sure what\'s this, choose \\"depth=\'1\'\\". If you are sure your server supports depth=\'infinity\', please choose that to get way better performance.","settings_webdav_depth_1":"only supports depth=\'1\'","settings_webdav_depth_inf":"supports depth=\'infinity\'","settings_webdav_customheaders":"Custom Headers Sent To Servers","settings_webdav_customheaders_desc":"Some users may want to set custom headers. If you don\'t know what it is, just leave it empty. Input them like: X-Header1:value1 in each line. All spaces around header keys and values will be removed.","settings_webdav_connect_succ":"Great! The webdav server can be accessed.","settings_webdav_connect_fail":"The webdav server cannot be reached (possible to be any of address/username/password/authtype errors).","settings_webdav_connect_fail_withcors":"The webdav server cannot be reached (possible to be any of address/username/password/authtype/CORS errors).","settings_webdis":"Remote For Webdis","settings_webdis_disclaimer1":"Disclaimer: This app is NOT an official Redis® Ltd / Redis® OSS / Webdis product. Redis is a registered trademark of Redis Ltd.","settings_webdis_disclaimer2":"Disclaimer: The information is stored locally. Other malicious/harmful/faulty plugins may read the info. If you see any unintentional access to your Webdis server, please immediately change the username and password.","settings_webdis_folder":"We will store the value with keys prefixed by :{{remoteBaseDir}} on your server.","settings_webdis_addr":"Server Address","settings_webdis_addr_desc":"Server address.","settings_webdis_user":"Username","settings_webdis_user_desc":"Username. Attention: the username and other info are saved locally.","settings_webdis_password":"Password","settings_webdis_password_desc":"Password. Attention: the password and other info are saved locally.","settings_webdis_connect_succ":"Great! The Webdis server can be accessed.","settings_webdis_connect_fail":"The Webdis server cannot be reached (possible to be any of address/username/password errors).","settings_chooseservice":"Choose A Remote Service","settings_chooseservice_desc":"Start here. What service are you connecting to? S3, Dropbox, Webdav, OneDrive for personal, or Webdis?","settings_chooseservice_s3":"S3 or compatible","settings_chooseservice_dropbox":"Dropbox","settings_chooseservice_webdav":"Webdav","settings_chooseservice_onedrive":"OneDrive for personal","settings_chooseservice_webdis":"Webdis (HTTP for Redis®)","settings_adv":"Advanced Settings","settings_concurrency":"Concurrency","settings_concurrency_desc":"How many files do you want to download or upload in parallel at most? By default it\'s set to 5. If you meet any problems such as rate limit, you can reduce the concurrency to a lower value.","settings_syncunderscore":"Sync _ Files Or Folders","settings_syncunderscore_desc":"Sync files or folders starting with _ (\\"underscore\\") or not","settings_configdir":"Sync Config Dir (experimental)","settings_configdir_desc":"Sync config dir {{configDir}} or not (inner folder .git and node_modules would be ignored). Please be aware that this may impact all your plugins\' or Obsidian\'s settings, and may require you restart Obsidian after sync. Enable this at your own risk.","settings_bookmarks":"Sync Bookmarks (experimental)","settings_bookmarks_desc":"Sync {{configDir}}/bookmarks.json or not. If you sync config dir, this option will be ignore and treated as \\"enabled\\".","settings_deletetowhere":"Deletion Destination","settings_deletetowhere_desc":"Which trash should the plugin put the files into while deleting?","settings_deletetowhere_system_trash":"system trash (default)","settings_deletetowhere_obsidian_trash":"Obsidian .trash folder","settings_conflictaction":"Action For Conflict","settings_conflictaction_desc":"

If a file is created or modified on both side since last update, it\'s a conflict event. How to deal with it? This only works for bidirectional sync.

","settings_conflictaction_keep_newer":"newer version survives (default)","settings_conflictaction_keep_larger":"larger size version survives","settings_cleanemptyfolder":"Action For Empty Folders","settings_cleanemptyfolder_desc":"The sync algorithm majorly deals with files, so you need to specify how to deal with empty folders.","settings_cleanemptyfolder_skip":"leave them as is (default)","settings_cleanemptyfolder_clean_both":"delete local and remote","settings_protectmodifypercentage":"Abort Sync If Modification Above Percentage","settings_protectmodifypercentage_desc":"Abort the sync if more than n% of the files are going to be deleted / modified. Useful to protect users\' files from unexpected modifications. You can set to 100 to disable the protection, or set to 0 to always block the sync.","settings_protectmodifypercentage_000_desc":"0 (always block)","settings_protectmodifypercentage_050_desc":"50 (default)","settings_protectmodifypercentage_100_desc":"100 (disable the protection)","settings_protectmodifypercentage_custom_desc":"custom","settings_protectmodifypercentage_customfield":"Custom Abort Sync If Modification Above Percentage","settings_protectmodifypercentage_customfield_desc":"You need to enter a number between 0 (inclusive) and 100 (inclusive). Float number is also allowed.","setting_syncdirection":"Sync Direction (experimental)","setting_syncdirection_desc":"

Which direction should the plugin sync to? Please be aware that only CHANGED files (based on time and size) are synced regardless any option.

  1. Bidirectional: Changes on both side are synced to the other side.
  2. Incremental Push: Locally created or modifed files are copied to remote.
  3. Incremental Pull: Remotely created or modifed files are copied to local.
  4. Incremental Push And Delete: Locally created or modifed files are copied to remote, and local deletion operations are run on remote too.
  5. Incremental Pull And Delete: Remotely created or modifed files are copied to local, and remote deletion operations are run on local too.
","setting_syncdirection_bidirectional_desc":"Bidirectional (default)","setting_syncdirection_incremental_push_only_desc":"Incremental Push (aka backup mode)","setting_syncdirection_incremental_pull_only_desc":"Incremental Pull","setting_syncdirection_incremental_push_and_delete_only_desc":"Incremental Push And Delete","setting_syncdirection_incremental_pull_and_delete_only_desc":"Incremental Pull And Delete","settings_enablemobilestatusbar":"Mobile Status Bar (experimental)","settings_enablemobilestatusbar_desc":"By default Obsidian mobile hides status bar. But some users want to show it up. So here is a hack.","settings_importexport":"Import and Export Partial Settings","settings_export":"Export","settings_export_desc":"Export settings by generating a QR code or URI.","settings_export_basic_and_advanced_button":"Export Basic And Advanced Part","settings_export_s3_button":"Export S3 Part","settings_export_dropbox_button":"Export Dropbox Part","settings_export_onedrive_button":"Export OneDrive (App Folder) Part","settings_export_webdav_button":"Export Webdav Part","settings_export_webdis_button":"Export Webdis Part","settings_import":"Import","settings_import_desc":"Paste the exported URI into here and click \\"Import\\". Or, you can open a camera or scan-qrcode app to scan the QR code.","settings_import_button":"Import","settings_import_error_notice":"Your URI string is empty or not correct!","settings_debug":"Debug","settings_debuglevel":"Alter Notice Level","settings_debuglevel_desc":"By default the notice level is \\"info\\". You can change to \\"debug\\" to get verbose information while syncing.","settings_outputsettingsconsole":"Output Current Settings From Disk To Console","settings_outputsettingsconsole_desc":"The settings save on disk in encoded. Click this to see the decoded settings in console.","settings_outputsettingsconsole_button":"Output","settings_outputsettingsconsole_notice":"Finished outputing in console.","settings_obfuscatesettingfile":"Obfuscate The Setting File Or Not","settings_obfuscatesettingfile_desc":"The setting file (data.json) has some sensitive information. It\'s strongly recommended to obfuscate it to avoid unexpected read and modification. If you are sure to view and edit it manually, you can disable the obfuscation.","settings_viewconsolelog":"View Console Log","settings_viewconsolelog_desc":"On desktop, please press \\"ctrl+shift+i\\" or \\"cmd+option+i\\" to view the log. On mobile, please install the third-party plugin Logstravaganza to export the console log to a note.","settings_syncplans":"Export Sync Plans","settings_syncplans_desc":"Sync plans are created every time after you trigger sync and before the actual sync. Useful to know what would actually happen in those sync. Click the button to export sync plans.","settings_syncplans_button_1_only_change":"Export latest 1 (change part)","settings_syncplans_button_5_only_change":"Export latest 5 (change part)","settings_syncplans_button_1":"Export latest 1","settings_syncplans_button_5":"Export latest 5","settings_syncplans_button_all":"Export All","settings_syncplans_notice":"Sync plans history exported.","settings_delsyncplans":"Delete Sync Plans History In DB","settings_delsyncplans_desc":"Delete sync plans history in DB.","settings_delsyncplans_button":"Delete Sync Plans History","settings_delsyncplans_notice":"Sync plans history (in DB) deleted.","settings_delprevsync":"Delete Prev Sync Details In DB","settings_delprevsync_desc":"The sync algorithm keeps the previous successful sync information in DB to determine the file changes. If you want to ignore them so that all files are treated newly created, you can delete the prev sync info here.","settings_delprevsync_button":"Delete Prev Sync Details","settings_delprevsync_notice":"Previous sync history (in local DB) deleted","settings_profiler_results":"Export Profiler Results","settings_profiler_results_desc":"The plugin records the time cost of each steps. Here you can export them to know which step is slow.","settings_profiler_results_notice":"Profiler results exported.","settings_profiler_results_button_all":"Export All","settings_profiler_enableprofiler":"Enable Profiler","settings_profiler_enableprofiler_desc":"Collect performance data or not?","settings_profiler_enabledebugprint":"Enable Profiler Printing","settings_profiler_enabledebugprint_desc":"Print profiler result in each insertion to console or not?","settings_profiler_recordsize":"Enable Profiler Recording Size","settings_profiler_recordsize_desc":"Let profiler record object sizes or not?","settings_outputbasepathvaultid":"Output Vault Base Path And Randomly Assigned ID","settings_outputbasepathvaultid_desc":"For debugging purposes.","settings_outputbasepathvaultid_button":"Output","settings_resetcache":"Reset Local Internal Cache/Databases","settings_resetcache_desc":"Reset local internal caches/databases (for debugging purposes). You would want to reload the plugin after resetting this. This option will not empty the {s3, password...} settings.","settings_resetcache_button":"Reset","settings_resetcache_notice":"Local internal cache/databases deleted. Please manually reload the plugin.","syncalgov3_title":"Remotely Save has HUGE updates on the sync algorithm","syncalgov3_texts":"Welcome to use Remotely Save!\\nFrom this version, a new algorithm has been developed:\\n
  • More robust deletion sync,
  • minimal conflict handling,
  • no meta data uploaded any more,
  • deletion / modification protection,
  • backup mode
  • new encryption method
  • ...
\\nStay tune for more! A full introduction is in the doc website.\\nIf you agree to use this, please read and check two checkboxes then click the \\"Agree\\" button, and enjoy the plugin!\\nIf you do not agree, please click the \\"Do Not Agree\\" button, the plugin will unload itself.\\nAlso, please consider visit the GitHub repo and star ⭐ it! Or even buy me a coffee. Your support is very important to me! Thanks!","syncalgov3_checkbox_manual_backup":"I will backup my vault manually firstly.","syncalgov3_checkbox_requiremultidevupdate":"I understand I need to update the plugin ACROSS ALL DEVICES to make them work properly.","syncalgov3_button_agree":"Agree","syncalgov3_button_disagree":"Do Not Agree","menu_check_file_stat":"Check file stats"}'),zh_cn:JSON.parse('{"confirm":"确认","disable":"关闭","enable":"开启","goback":"返回","submit":"提交","sometext":"这里有一段文字。","syncrun_alreadyrunning":"{{pluginName}} 正处于此阶段:{{syncStatus}}!中断触发 {{newTriggerSource}}。","syncrun_syncingribbon":"{{pluginName}}:正在由 {{triggerSource}} 触发运行","syncrun_step0":"0/8 Remotely Save 在空跑(dry run)模式,不会发生实际的文件交换。","syncrun_step1":"1/8 Remotely Save 准备同步({{serviceType}})","syncrun_step2":"2/8 正在获取远端的元数据和检查密码。","syncrun_passworderr":"检查密码时候出错。","syncrun_step3":"3/8 正在处理远端的元数据。","syncrun_step4":"4/8 正在获取本地的元数据。","syncrun_step5":"5/8 正在获取本地上一次同步的元数据。","syncrun_step6":"6/8 正在生成同步计划。","syncrun_step7":"7/8 Remotely Save 开始发生数据交换!","syncrun_step7skip":"7/8 Remotely Save 在空跑模式,跳过实际数据交换步骤。","syncrun_step8":"8/8 Remotely Save 已完成同步!","syncrun_shortstep0":"0/2 Remotely Save 在空跑(dry run)模式,不会发生实际的文件交换。","syncrun_shortstep1":"1/2 Remotely Save 开始同步({{serviceType}})","syncrun_shortstep2skip":"2/2 Remotely Save 在空跑模式,跳过实际数据交换步骤。","syncrun_shortstep2":"2/2 Remotely Save 已完成同步!","syncrun_abort":"{{manifestID}}-{{theDate}}:中断同步,同步来源={{triggerSource}},出错阶段={{syncStatus}}","syncrun_abort_protectmodifypercentage":"中断同步!您设置了不允许 >= {{protectModifyPercentage}}% 的变更,但是现在 {{realModifyDeleteCount}}/{{allFilesCount}}={{percent}}% 的文件会被修改或删除!如果您确认这次同步是您想要的,那么请在设置里修改允许比例。","protocol_saveqr":" {{manifestName}} 的新设置导入完成。请重启插件设置页使之生效。","protocol_callbacknotsupported":"您的 uri callback 暂不支持: {{params}}","protocol_dropbox_connecting":"正在连接 Dropbox……\\n请不要关闭此弹窗。","protocol_dropbox_connect_succ":"好!我们作为用户 {{username}} 连接上了 Dropbox!","protocol_dropbox_connect_succ_revoke":"您已作为用户 {{username}} 连接上了。如果您想取消连接,请点击此按钮。","protocol_dropbox_connect_fail":"Dropbox 的回调请求有点异常。您是否网络不顺畅?您是否拒绝了鉴权?","protocol_dropbox_connect_unknown":"不知道如何处理此 callback:{{params}}","protocol_dropbox_no_modal":"您不是在设置页的弹窗里触发 Dropbox 的。中止操作。","protocol_onedrive_connecting":"正在连接 OneDrive……\\n请不要关闭此弹窗。","protocol_onedrive_connect_succ_revoke":"您已作为用户 {{username}} 连接上了。如果您想取消连接,请点击此按钮。","protocol_onedrive_connect_fail":"OneDrive 的回调请求有点异常。您是否拒绝了鉴权?","protocol_onedrive_connect_unknown":"不知道如何处理此 callback:{{params}}","command_startsync":"开始同步(start sync)","command_drynrun":"开始同步(空跑模式)(start sync (dry run only))","command_exportsyncplans_json":"导出同步计划为 json 格式(export sync plans in json format)","command_exportsyncplans_1_only_change":"导出同步计划(最近 1 次)(仅修改部分)(export sync plans (latest 1) (change part))","command_exportsyncplans_1":"导出同步计划(最近 1 次)(export sync plans (latest 1))","command_exportsyncplans_5":"导出同步计划(最近 5 次)(export sync plans (latest 5))","command_exportsyncplans_all":"导出同步计划(所有)(export sync plans (all))","command_exportlogsindb":"从数据库导出终端日志(export logs saved in db)","statusbar_sync_source_manual":"手动:","statusbar_sync_source_dry":"空跑:","statusbar_sync_source_auto":"自动:","statusbar_sync_source_auto_once_init":"启动时同步:","statusbar_sync_source_auto_sync_on_save":"保存时同步:","statusbar_sync_status_prefix_success":"同步成功:","statusbar_sync_status_prefix_failed":"同步失败:","statusbar_time_years":"{{time}} 年前","statusbar_time_months":"{{time}} 月前","statusbar_time_weeks":"{{time}} 周前","statusbar_time_days":"{{time}} 天前","statusbar_time_hours":"{{time}} 小时前","statusbar_time_minutes":"{{time}} 分钟前","statusbar_time_lessminute":"1 分钟内","statusbar_time_now":"刚刚","statusbar_syncing":"正在同步","statusbar_lastsync_label":"日期:{{date}}","statusbar_lastsync_never":"没触发过同步","statusbar_lastsync_never_label":"没触发过同步","modal_password_title":"稍等一下,请阅读下文:","modal_password_shortdesc":"如果密码不是空的,那么文件会在上传之前,在本地先用此密码加密。\\n如果密码是空的,那么文件会被非加密地上传。","modal_password_attn1":"注意 1/5:库(Vault)名字是不会加密的!本插件会在一些远程存储里创建一个和库名字有着同名的文件夹。","modal_password_attn2":"注意 2/5:密码在本地不加密地保存!","modal_password_attn3":"注意 3/5:一些元信息是没有被加密的,或者可以被较容易地猜测出来。(文件大小很接近于没加密的时候,且文件夹可能会被存储为大小为 0 byte 的对象。)","modal_password_attn4":"注意 4/5:您需要确保远程存储是“空”的,或者已有文件也是被同一个新密码加密的;从而避免冲突。","modal_password_attn5":"注意 5/5:密码越长越好。","modal_password_secondconfirm":"再次确认保存新密码","modal_password_notice":"新密码已保存!","modal_encryptionmethod_title":"稍等一下,请阅读下文:","modal_encryptionmethod_shortdesc":"您正在修改加密方式,但是您已经设置了密码。\\n修改加密方式之后,您需要手动完全删除在远端的之前加密过的库文件,然后重新同步(从而重新上传)新的加密文件。","modal_remotebasedir_title":"您正在修改远端基文件夹设置","modal_remotebasedir_shortdesc":"1. 本插件并不会自动在远端把内容从旧文件夹移动到新文件夹。所有内容都会重新同步。\\n2. 如果你使得文本输入框为空,那么本设置会被重设回库的文件夹名(默认设置)。\\n3. 即使您设置了端对端加密的密码,远端文件夹名称本身也不会被加密。\\n4. 某些特殊字符,如“?”、“/”、“\\\\”是不允许的。文本前后的空格也会被自动删去。","modal_remotebasedir_invaliddirhint":"您所输入的内容含有某些特殊字符,如“?”、“/”、“\\\\”,它们是不允许的。","modal_remotebasedir_secondconfirm_vaultname":"重设回默认的库文件夹名","modal_remotebasedir_secondconfirm_change":"确认修改","modal_remotebasedir_notice":"新的远端基文件夹设置已保存!","modal_remoteprefix_s3_title":"您正在修改远端路径前缀设置","modal_remoteprefix_s3_shortdesc":"1. 本插件并不会自动在远端把内容从旧文件夹移动到新文件夹。所有内容都会重新同步。\\n2. 如果你使得文本输入框为空,那么本设置为保存为空,文件将会被存储在桶(Bucket)的根目录。\\n3. 即使您设置了端对端加密的密码,远端文件夹名称本身也不会被加密。\\n4. 某些特殊字符,如“?”、“/”、“\\\\”是不允许的。文本前后的空格也会被自动删去。","modal_remoteprefix_s3_invaliddirhint":"您所输入的内容含有某些特殊字符,如“?”、“/”、“\\\\”,它们是不允许的。","modal_remoteprefix_s3_tosave":"您设定的新前缀为:“{{{prefix}}}”","modal_remoteprefix_s3_secondconfirm_empty":"前缀为空,文件会保存在根目录","modal_remoteprefix_s3_secondconfirm_change":"确认修改","modal_remoteprefix_s3_notice":"新的远端路径前缀设置已保存!","modal_dropboxauth_manualsteps":"第 1 步:在浏览器中访问以下地址,然后按照网页提示操作。\\n到了最后,您应该会获得一串很长的代码文本,请复制粘贴到下方,并点击“提交”","modal_dropboxauth_autosteps":"在浏览器中访问以下地址,然后按照网页提示操作。\\n到了最后,您应该会被自动重定向回来 Obsidian。","modal_dropboxauth_copybutton":"点击此按钮从而复制鉴权 url","modal_dropboxauth_copynotice":"鉴权 url 已复制到剪贴板!","modal_dropboxauth_maualinput":"来自网页的授权码","modal_dropboxauth_maualinput_desc":"您需要点击“确认”","modal_dropboxauth_maualinput_notice":"正在尝试连接 Dropbox","modal_dropboxauth_maualinput_conn_succ":"很好!我们作为用户 {{username}} 连接到 Dropbox 了!","modal_dropboxauth_maualinput_conn_succ_revoke":"您已作为用户 {{username}} 连接到 Dropbox。如果您想断开连接,点击此按钮。","modal_dropboxauth_maualinput_conn_fail":"连接 Dropbox 途中出错了。","modal_onedriveauth_shortdesc":"现在只支持个人版 OneDrive,(暂)不支持企业版。\\n在浏览器中访问以下地址,然后按照网页提示操作。\\n到了最后,您应该会被自动重定向回来 Obsidian。","modal_onedriveauth_shortdesc_linux":"您正在用 Linux,有可能无法跳转回来。请考虑使用 flatpack 版本的 Obsidian,或创建 obsidian.desktop 文件。","modal_onedriveauth_copybutton":"点击此按钮从而复制鉴权 url","modal_onedriveauth_copynotice":"鉴权 url 已复制到剪贴板!","modal_onedriverevokeauth_step1":"第 1 步:用浏览器打开以下地址,点击本插件对应的“Edit”按钮,点击“Remove these permissions”按钮。","modal_onedriverevokeauth_step2":"第 2 步:点击以下按钮,清理本地保存的登录信息。","modal_onedriverevokeauth_clean":"清理本地保存的登录信息","modal_onedriverevokeauth_clean_desc":"您需要点击“清理”按钮。","modal_onedriverevokeauth_clean_button":"清理","modal_onedriverevokeauth_clean_notice":"已清理!","modal_onedriverevokeauth_clean_fail":"鉴权途中出错了。","modal_syncconfig_attn":"注意 1/2:此设置只同步(复制)整个 Obsidian 的配置文件夹,但是不会同步其它 . 开头的文件夹或文件。除了会忽略 .git 和 node_modules 文件夹之外,它也并不理解配置文件夹的里各个子文件或子文件夹的含义。\\n注意 2/2:配置文件夹被同步之后,各插件的设置或许会出错,且 Obsidian 或许需要重启来重载各插件的新配置。\\n如果您同意自行承受以上风险,您可以点击以下再次确认按钮。","modal_syncconfig_secondconfirm":"再次确认开启","modal_syncconfig_notice":"您已开启配置文件夹的同步!","modal_qr_shortdesc":"这里可导出(部分)设置。\\n您可以使用另一个设备来扫描此 QR 码。\\n又或者,您可以点击以下按钮复制此特殊 URI,然后粘贴到另一台设备的网络浏览器或 Remotely Save 设置里的导入部分。","modal_qr_button":"点击此按钮复制特殊 URI","modal_qr_button_notice":"特殊 URI 已被复制到剪贴板!","modal_sizesconflict_title":"Remotely Save:跳过大文件的时候出现了一些冲突","modal_sizesconflict_desc":"您设置了跳过同步大于 {{thresholdMB}} MB({{thresholdBytes}} bytes)的文件。\\n但是以下文件的大小,在一端大于阈值,在另一端则小于阈值。\\n为了避免意外的覆盖或删除,插件停止了运作,您需要手动处理至少一端的文件。","modal_sizesconflict_copybutton":"点击以复制以下所有文件大小冲突信息","modal_sizesconflict_copynotice":"所有的文件大小冲突信息,已被复制到剪贴板!","settings_basic":"基本设置","settings_password":"密码","settings_password_desc":"端到端加密的密码。不填写则代表没密码。您需要点击“确认”来修改。注意:密码和其它信息都会在本地保存。如果您修改了密码,您需要手动删除远端的所有文件,重新同步(从而上传)加密文件。","settings_encryptionmethod":"加密方法","settings_encryptionmethod_desc":"端到端加密的方法。推荐选用 RClone Crypt 方法,但是它没有加密文件路径结构。OpenSSL enc 是本插件一开始就支持的方式。两种方法都和 RClone、OpenSSL 官方产品和社区无利益相关。如果您修改了加密方法,您需要手动删除远端的所有文件,重新同步(从而上传)加密文件。更多详细说明见在线文档。","settings_encryptionmethod_rclone":"RClone Crypt(推荐)","settings_encryptionmethod_openssl":"OpenSSL enc(旧方法)","settings_autorun":"自动运行","settings_autorun_desc":"每隔一段时间,此插件尝试自动同步。会影响到电池用量。","settings_autorun_notset":"(不设置)","settings_autorun_1min":"每 1 分钟","settings_autorun_5min":"每 5 分钟","settings_autorun_10min":"每 10 分钟","settings_autorun_30min":"每 30 分钟","settings_runoncestartup":"启动后自动运行一次","settings_runoncestartup_desc":"本设置使得插件在程序启动后自动触发一次同步。修改后,会在下一次启动生效。本设置和“自动运行”是不同的,那个设置是指“每隔一段时间”都自动同步一次。","settings_runoncestartup_notset":"(不设置)","settings_runoncestartup_1sec":"启动后第 1 秒运行一次","settings_runoncestartup_10sec":"启动后第 10 秒运行一次","settings_runoncestartup_30sec":"启动后第 30 秒运行一次","settings_synconsave":"保存时同步(实验性质)","settings_synconsave_desc":"插件如果检查到当前文件在最近一段时间有修改保存过,则尝试同步。请注意,同步是一个很重的操作,因此会影响到耗电量。(修改设置后可能需要重载插件或重启。)","settings_synconsave_disable":"关闭(默认)","settings_synconsave_enable":"开启","settings_skiplargefiles":"跳过大文件","settings_skiplargefiles_desc":"跳过大于某一个阈值的文件。这里 1 MB = 10^6 bytes。","settings_skiplargefiles_notset":"(不设置)","settings_ignorepaths":"忽略的文件或文件夹的正则表达式","settings_ignorepaths_desc":"忽略的文件或文件夹的正则表达式。每行一条。路径是相对于库(Vault)根目录的,没有前置 / 符号。非空的忽略列表和非空的允许列表会一起生效。","settings_onlyallowpaths":"允许同步的文件或文件夹的正则表达式","settings_onlyallowpaths_desc":"允许同步的文件或文件夹的正则表达式。每行一条。路径是相对于库(Vault)根目录的,没有前置 / 符号。如果这个设置非空,那么所有您想同步的路径(包括隐藏的设置文件夹)都要明确地列出到这里。非空的忽略列表和非空的允许列表会一起生效。","settings_enablestatusbar_info":"在状态栏显示上一次成功的同步","settings_enablestatusbar_info_desc":"在状态栏显示上一次成功的同步的时间。","settings_enablestatusbar_reloadrequired_notice":"需要重新载入此插件才生效。","settings_resetstatusbar_time":"重设上一次成功同步的时间记录","settings_resetstatusbar_time_desc":"重设上一次成功同步的时间记录。","settings_resetstatusbar_button":"重设","settings_resetstatusbar_notice":"重设完毕!","settings_checkonnectivity":"检查可否连接","settings_checkonnectivity_desc":"检查可否连接。","settings_checkonnectivity_button":"检查","settings_checkonnectivity_checking":"正在检查……","settings_remotebasedir":"修改远端基文件夹(实验性质)","settings_remotebasedir_desc":"默认设定,内容会被同步到远端的和资料库同名的文件夹下。您可以在此修改远端文件夹名,或删除输入框文本从而重设到默认值。您需要点击“确认”。","settings_remoteprefix_s3":"修改远端前缀路径(实验性质)","settings_remoteprefix_s3_desc":"默认设定 s3 保存在存储桶(Bucket)的根目录。您可以在这里修改路径前缀,或者保持为空保持默认设置。您需要点击“确认”。","settings_s3":"S3 或兼容 S3 的服务的设置","settings_s3_disclaimer1":"声明:本插件不是 Amazon 的官方产品。","settings_s3_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了存储桶有不符合预期的访问,请立刻从 AWS(或其它 S3 服务商)删除记录于此的 access key。","settings_s3_cors":"您需要设置 CORS,从而允许这些源的请求访问:app://obsidian.md 和 capacitor://localhost 和 http://localhost 且增加 ETag 到暴露 headers 里。","settings_s3_prod":"一些可参考的 Amazon S3 官方文档:","settings_s3_prod1":"服务地址(Endpoint)和区域(Region)信息","settings_s3_prod2":"Access Key ID 和 Secret Access Key 信息","settings_s3_prod3":"设置 CORS","settings_s3_endpoint":"服务地址(Endpoint)","settings_s3_region":"区域(Region)","settings_s3_region_desc":"如果您不知道这个值填什么,可以尝试填写:us-east-1。","settings_s3_accesskeyid":"Access Key ID","settings_s3_accesskeyid_desc":"Access key ID。注意:access key ID 和其它信息都会在本地保存。","settings_s3_secretaccesskey":"Secret Access Key","settings_s3_secretaccesskey_desc":"Secret access key。注意:secret access key 和其它信息都会在本地保存。","settings_s3_bucketname":"存储桶(Bucket)的名字","settings_s3_bypasscorslocally":"本地绕过 CORS 问题","settings_s3_bypasscorslocally_desc":"对于 Obsidian 新版本(桌面版>=0.13.25 或 iOS>=1.1.1 或 Android>=1.2.1),本插件可以跳过服务器设置 CORS 的步骤。如果您遇到任意问题,可以关闭此设定,并在服务端设置 CORS(允许来自 app://obsidian.md 和 capacitor://localhost 和 http://localhost 的请求且增加 ETag 到暴露 headers 里)。","settings_s3_parts":"分块并行度","settings_s3_parts_desc":"在 S3 里,大文件会被分块上传。您希望同一时间最多有多少个分块被上传?","settings_s3_accuratemtime":"使用准确的文件修改时间","settings_s3_accuratemtime_desc":"读取(已上传的)准确的文件修改时间,有助于同步算法更加准确和稳定。但是它也会导致额外的 api 请求、时间、金钱花费。","settings_s3_urlstyle":"S3 URL style","settings_s3_urlstyle_desc":"是否对 S3 对象强制使用 path style URL(例如使用 https://s3.amazonaws.com/*/ 而不是 https://*.s3.amazonaws.com/)。","settings_s3_reverse_proxy_no_sign_url":"S3 反向代理(不签名)地址(实验性质)","settings_s3_reverse_proxy_no_sign_url_desc":"不会参与到签名的 S3 反向代理地址。如果您有一个反向代理,但是不想修改原始鉴权签名,这里就可以填写。没有 http(s):// 前缀。如果您不知道这是什么,留空即可。","settings_s3_generatefolderobject":"是否生成文件夹 Object","settings_s3_generatefolderobject_desc":"S3 不存在“真正”的文件夹。如果您设置了“生成”(或用了旧版本),那么插件会上传 0 字节的以“/”结尾的 Object 来代表文件夹。新版本插件会默认跳过生成这种文件夹 Object。","settings_s3_generatefolderobject_notgenerate":"不生成(默认)","settings_s3_generatefolderobject_generate":"生成","settings_s3_connect_succ":"很好!可以访问到对应存储桶。","settings_s3_connect_fail":"无法访问到对应存储桶。","settings_dropbox":"Dropbox 设置","settings_dropbox_disclaimer1":"声明:此插件不是 Dropbox 官方产品。","settings_dropbox_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了 Dropbox 有不符合预期的访问,请立刻从 https://www.dropbox.com/account/connected_apps 删除记录于此插件的连接鉴权。","settings_dropbox_folder":"我们会在您的 Dropbox 上创建此文件夹并在里面同步:/Apps/{{pluginID}}/{{remoteBaseDir}}。","settings_dropbox_revoke":"撤回鉴权","settings_dropbox_revoke_desc":"您现在使用了用户名 {{username}} 来连接。如果想取消连接,请点击此按钮。","settings_dropbox_revoke_button":"撤回鉴权","settings_dropbox_revoke_notice":"鉴权已被撤回!","settings_dropbox_revoke_noticeerr":"撤回鉴权出错。","settings_dropbox_clearlocal":"清除本地保存的鉴权信息","settings_dropbox_clearlocal_desc":"您可以强制清除本地已保存的 Dropbox 的登录鉴权信息,但不向服务器发送撤回鉴权的请求。","settings_dropbox_clearlocal_button":"清除","settings_dropbox_clearlocal_notice":"已清除!","settings_dropbox_auth":"鉴权","settings_dropbox_auth_desc":"鉴权。","settings_dropbox_auth_button":"鉴权","settings_dropbox_connect_succ":"很好!我们可连接上 Dropbox!","settings_dropbox_connect_fail":"我们未能连接上 Dropbox。","settings_onedrive":"Onedrive(个人版)(App Folder)设置","settings_onedrive_disclaimer1":"声明:此插件不是微软或 OneDrive 的官方产品。","settings_onedrive_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了 OneDrive 有不符合预期的访问,请立刻从 https://microsoft.com/consent 删除记录于此插件的连接鉴权。","settings_onedrive_folder":"我们会在您的 OneDrive 上创建此文件夹并在里面同步:/Apps/{{pluginID}}/{{remoteBaseDir}}。","settings_onedrive_nobiz":"现在只支持个人版 OneDrive。(暂时)并不支持企业版 OneDrive。","settings_onedrive_revoke":"撤回鉴权","settings_onedrive_revoke_desc":"您现在使用了用户名 {{username}} 来连接。如果想取消连接,请点击此按钮。","settings_onedrive_revoke_button":"撤回鉴权","settings_onedrive_auth":"鉴权","settings_onedrive_auth_desc":"鉴权。","settings_onedrive_auth_button":"鉴权","settings_onedrive_connect_succ":"很好!我们可连接上 OneDrive!","settings_onedrive_connect_fail":"我们未能连接上 OneDrive。","settings_onedrive_emptyfile":"空文件处理","settings_onedrive_emptyfile_desc":"OneDrive 不允许上传空文件(即使官网也是不允许的)。那么你想跳过空文件还是返回错误?","settings_onedrive_emptyfile_skip":"跳过","settings_onedrive_emptyfile_error":"返回错误和中断","settings_webdav":"Webdav 设置","settings_webdav_disclaimer1":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了 Webdav 服务器有不符合预期的访问,请立刻修改用户名和密码。","settings_webdav_cors_os":"Obsidian 桌面版>=0.13.25 或 iOS>=1.1.1 或 Android>=1.2.1 支持跳过 CORS 设置。但您正在使用旧版,建议升级。","settings_webdav_cors":"您需要设置 CORS,允许来自这些源的请求:app://obsidian.md 和 capacitor://localhost 和 http://localhost。","settings_webdav_folder":"我们会在您的服务器上创建此文件夹并在里面同步:/{{remoteBaseDir}}","settings_webdav_addr":"服务器地址","settings_webdav_addr_desc":"服务器地址。","settings_webdav_user":"用户名","settings_webdav_user_desc":"用户名。注意:用户名和其它信息都会保存在本地。","settings_webdav_password":"密码","settings_webdav_password_desc":"密码。注意:密码和其它信息都会保存在本地。","settings_webdav_auth":"鉴权类型","settings_webdav_auth_desc":"如果不填写密码,本设置会被忽略。","settings_webdav_depth":"发送到服务器的 Depth header","settings_webdav_depth_desc":"Webdav 服务器会被设为接收 Depth header 为“1”或“Infinity”请求。如果您不清楚如何设置,可以选择 depth=\'1\'。如果那你确认服务器支持 depth=\'infinity\',请选择它,会获得更加好的性能。","settings_webdav_depth_1":"只支持 depth=\'1\'","settings_webdav_depth_inf":"支持 depth=\'infinity\'","settings_webdav_customheaders":"发送到服务器的自定义 Header","settings_webdav_customheaders_desc":"有些用户需要设置自定义 header。如果您不知道是什么,可以直接留空不填。输入格式:每行形如 X-Header1:value1。header 的 key 和 value 之间的空格会被删除。","settings_webdav_connect_succ":"很好!可以连接上 Webdav 服务器。","settings_webdav_connect_fail":"无法连接上 Webdav 服务器。(可能是地址/账号/密码/鉴权类型等错误。)","settings_webdav_connect_fail_withcors":"无法连接上 Webdav 服务器。(可能是地址/账号/密码/鉴权类型/CORS 等错误。)","settings_webdis":"Webdis 设置","settings_webdis_disclaimer1":"声明:此插件不是 Redis® Ltd 或 Redis® 软件或 Wedis 的官方产品。Redis 是 Redis Ltd 的注册商标。","settings_webdis_disclaimer2":"声明:您所输入的信息存储于本地。其它有害的或者出错的插件,是有可能读取到这些信息的。如果您发现了 Webdis 服务器有不符合预期的访问,请立刻修改用户名和密码。","settings_webdis_folder":"我们会在您的服务器上创建带有此前缀的 key 并在里面同步::{{remoteBaseDir}}。","settings_webdis_addr":"服务器地址","settings_webdis_addr_desc":"服务器地址","settings_webdis_user":"用户名","settings_webdis_user_desc":"用户名。注意:用户名和其它信息都会保存在本地。","settings_webdis_password":"密码","settings_webdis_password_desc":"密码。注意:密码和其它信息都会保存在本地。","settings_webdis_connect_succ":"很好!可以连接上 Webdis 服务器。","settings_webdis_connect_fail":"无法连接上 Webdis 服务器。(可能是地址/账号/密码/鉴权类型等错误。)","settings_chooseservice":"选择远程服务","settings_chooseservice_desc":"从这里开始设置。您想连接到哪一个服务?S3、Dropbox、Webdav、OneDrive(个人版)、Webdis?","settings_chooseservice_s3":"S3 或兼容 S3 的服务","settings_chooseservice_dropbox":"Dropbox","settings_chooseservice_webdav":"Webdav","settings_chooseservice_onedrive":"OneDrive(个人版)","settings_chooseservice_webdis":"Webdis (an HTTP interface for Redis)","settings_adv":"进阶设置","settings_concurrency":"并行度","settings_concurrency_desc":"您希望同时最多有多少个文件被上传和下载?默认值是 5。如果您遇到了一些问题(如访问频率限制),您可以减少并行度。","settings_syncunderscore":"同步 _ 文件或文件夹","settings_syncunderscore_desc":"是否同步“_”(下划线)开始的文件或文件夹。","settings_configdir":"同步配置文件夹(实验性质)","settings_configdir_desc":"是否同步 Obsidian 的配置文件夹 {{configDir}}(其中的 .git 和 node_modules 依然会被忽略)。请注意,此设置可能会影响到您 Obsidian 或者所有的插件设置,也可能需要您同步完毕后重启 Obsidian。如果您同意自行承受其风险,则可以开启本设置。","settings_bookmarks":"同步书签(实验性质)","settings_bookmarks_desc":"是否同步书签 {{configDir}}/bookmarks.json 。如果您设置了同步配置文件夹,此选项会被忽略并设为“开启”。","settings_deletetowhere":"删除文件到哪里","settings_deletetowhere_desc":"插件触发删除操作时候,删除到哪里?","settings_deletetowhere_system_trash":"系统回收站(默认)","settings_deletetowhere_obsidian_trash":"Obsidian .trash 文件夹","settings_conflictaction":"处理冲突","settings_conflictaction_desc":"如果一个文件,在本地和服务器都被创建或者修改了,那么这就是一个“冲突”情况。如何处理?这个设置只在双向同步时候生效。","settings_conflictaction_keep_newer":"保留最后修改的版本(默认)","settings_conflictaction_keep_larger":"保留文件体积较大的版本","settings_cleanemptyfolder":"处理空文件夹","settings_cleanemptyfolder_desc":"同步算法主要是针对文件处理的,您需要手动指定空文件夹如何处理。","settings_cleanemptyfolder_skip":"跳过处理空文件夹(默认)","settings_cleanemptyfolder_clean_both":"删除本地和服务器的空文件夹","settings_protectmodifypercentage":"如果修改超过百分比则中止同步","settings_protectmodifypercentage_desc":"如果算法检测到超过 n% 的文件会被修改或删除,则中止同步。从而可以保护用户的文件免受预料之外的修改。您可以设置为 100 而去除此保护,也可以设置为 0 总是强制中止所有同步。","settings_protectmodifypercentage_000_desc":"0(总是强制中止)","settings_protectmodifypercentage_050_desc":"50(默认值)","settings_protectmodifypercentage_100_desc":"100(去除此保护)","settings_protectmodifypercentage_custom_desc":"自定义","settings_protectmodifypercentage_customfield":"如果修改超过自定义百分比则中止同步","settings_protectmodifypercentage_customfield_desc":"您需要输入 0(含)~ 100(含)的数字。小数也是可以的。","setting_syncdirection":"同步方向(实验性质)","setting_syncdirection_desc":"

W插件应该向哪里同步?注意每个选项都是只有修改了的文件(基于修改时间和大小判断)才会触发同步动作。

  1. 双向同步:一边的变动会同步到另一边。
  2. 增量推送:本地创建或修改的文件会复制到远端。
  3. 增量拉取:远端创建或修改的文件会复制到本地。
  4. 增量推送带删除:本地创建或修改的文件会复制到远端,本地的删除也会在远端运行。
  5. 增量拉取带删除:远端创建或修改的文件会复制到本地,远端的删除也会在本地运行。
","setting_syncdirection_bidirectional_desc":"双向同步(默认)","setting_syncdirection_incremental_push_only_desc":"增量推送(也即:备份模式)","setting_syncdirection_incremental_pull_only_desc":"增量拉取","setting_syncdirection_incremental_push_and_delete_only_desc":"增量推送带删除","setting_syncdirection_incremental_pull_and_delete_only_desc":"增量拉取带删除","settings_enablemobilestatusbar":"手机的状态栏(实验性质)","settings_enablemobilestatusbar_desc":"Obsidian 手机版默认隐藏了状态栏。有些用户希望展示它。这里提供了设置选项。","settings_importexport":"导入导出部分设置","settings_export":"导出","settings_export_desc":"用 QR 码或 URI 导出设置信息。","settings_export_basic_and_advanced_button":"导出基本或进阶设置","settings_export_s3_button":"导出 S3 部分","settings_export_dropbox_button":"导出 Dropbox 部分","settings_export_onedrive_button":"导出 OneDrive (App Folder) 部分","settings_export_webdav_button":"导出 Webdav 部分","settings_export_webdis_button":"导出 Webdis 部分","settings_import":"导入","settings_import_desc":"粘贴之前导出的 URI 到这里然后点击“导入”。或,使用拍摄 app 或者扫描 QR 码的 app,来扫描对应的 QR 码。","settings_import_button":"导入","settings_import_error_notice":"您输入的 URI 是空的或者不准确的!","settings_debug":"调试","settings_debuglevel":"修改同步提示信息","settings_debuglevel_desc":"默认值为 \\"info\\"。您可以改为 \\"debug\\" 从而在同步时候里获取更多信息。","settings_outputsettingsconsole":"读取硬盘上的设置文件输出到终端","settings_outputsettingsconsole_desc":"硬盘上的设置文件是编码过的,点击这里从而解码并输出到终端。","settings_outputsettingsconsole_button":"输出","settings_outputsettingsconsole_notice":"已输出到终端","settings_obfuscatesettingfile":"是否混淆保存设置文件","settings_obfuscatesettingfile_desc":"设置文件(data.json)含有敏感信息。强烈建议混淆后保存它,从而避免出乎意料的读取和修改。如果您确认要手动查看和修改它,可以关闭混淆保存。","settings_viewconsolelog":"查看终端输出","settings_viewconsolelog_desc":"电脑上,输入“ctrl+shift+i”或“cmd+shift+i”来查看终端输出。手机上,安装第三方插件 Logstravaganza 来导出终端输出到一篇笔记上。","settings_syncplans":"导出同步计划","settings_syncplans_desc":"每次您启动同步,并在实际上传下载前,插件会生成同步计划。它可以使您知道每次同步发生了什么。点击按钮可以导出同步计划。","settings_syncplans_button_1_only_change":"导出最近 1 次(仅修改部分)","settings_syncplans_button_5_only_change":"导出最近 5 次(仅修改部分)","settings_syncplans_button_1":"导出最近 1 次","settings_syncplans_button_5":"导出最近 5 次","settings_syncplans_button_all":"导出所有","settings_syncplans_notice":"同步计划已导出","settings_delsyncplans":"删除数据库里的同步计划历史","settings_delsyncplans_desc":"删除数据库里的同步计划历史。","settings_delsyncplans_button":"删除同步计划历史","settings_delsyncplans_notice":"(数据库里的)同步计划已被删除。","settings_delprevsync":"删除数据库里的上次同步明细","settings_delprevsync_desc":"同步算法需要上次成功同步的信息来决定文件变更,这个信息保存在本地的数据库里。如果您想忽略这些信息从而所有文件都被视为新创建的话,可以在此删除之前的信息。","settings_delprevsync_button":"删除上次同步明细","settings_delprevsync_notice":"(本地数据库里的)上次同步明细已被删除。","settings_profiler_results":"导出性能数据记录","settings_profiler_results_desc":"插件记录了每次同步每一步的耗时。这里可以导出记录得知哪一步最慢。","settings_profiler_results_notice":"性能数据已导出","settings_profiler_results_button_all":"导出所有","settings_profiler_enableprofiler":"性能收集","settings_profiler_enableprofiler_desc":"是否开启性能收集功能?","settings_profiler_enabledebugprint":"性能收集输出","settings_profiler_enabledebugprint_desc":"是否直接输出性能收集结果到终端里?","settings_profiler_recordsize":"性能收集统计对象大小","settings_profiler_recordsize_desc":"是否收集对象的大小?","settings_outputbasepathvaultid":"输出资料库对应的位置和随机分配的 ID","settings_outputbasepathvaultid_desc":"用于调试。","settings_outputbasepathvaultid_button":"输出","settings_resetcache":"重设本地缓存和数据库","settings_resetcache_desc":"(出于调试原因)重设本地缓存和数据库。您需要在重设之后重新载入此插件。本重设不会删除 s3,密码……等设定。","settings_resetcache_button":"重设","settings_resetcache_notice":"本地同步缓存和数据库已被删除。请手动重新载入此插件。","syncalgov3_title":"Remotely Save 的同步算法有重大更新","syncalgov3_texts":"欢迎使用 Remotely Save!\\n从这个版本开始,插件更新了同步算法:\\n
  • 更稳健的删除同步
  • 引入冲突处理
  • 避免上传元数据
  • 修改删除保护
  • 备份模式
  • 新的加密方式
  • ……
\\n敬请期待更多更新!详细介绍请参阅文档网站。\\n如果您同意使用新版本,请阅读和勾选两个勾选框,然后点击“同意”按钮,开始使用插件吧!\\n如果您不同意,请点击“不同意”按钮,插件将自动停止运行(unload)。\\n此外,请考虑访问 GitHub 页面然后点赞 ⭐!您的支持对我十分重要!谢谢!","syncalgov3_checkbox_manual_backup":"我将会首先手动备份我的库(Vault)。","syncalgov3_checkbox_requiremultidevupdate":"我理解,我需要在所有设备上都更新此插件使之正常运行。","syncalgov3_button_agree":"同意","syncalgov3_button_disagree":"不同意","menu_check_file_stat":"查看文件属性"}'),zh_tw:JSON.parse('{"confirm":"確認","disable":"關閉","enable":"開啟","goback":"返回","submit":"提交","sometext":"這裡有一段文字。","syncrun_alreadyrunning":"{{pluginName}} 正處於此階段:{{syncStatus}}! 中斷觸發 {{newTriggerSource}}。","syncrun_syncingribbon":"{{pluginName}}:正在由 {{triggerSource}} 觸發執行","syncrun_step0":"0/8 Remotely Save 在空跑(dry run)模式,不會發生實際的檔案交換。","syncrun_step1":"1/8 Remotely Save 準備同步({{serviceType}})","syncrun_step2":"2/8 正在獲取遠端的元數據和檢查密碼。","syncrun_passworderr":"檢查密碼時候出錯。","syncrun_step3":"3/8 正在處理遠端的元數據。","syncrun_step4":"4/8 正在獲取本地的元資料。","syncrun_step5":"5/8 正在獲取本地上一次同步的元資料。","syncrun_step6":"6/8 正在生成同步計劃。","syncrun_step7":"7/8 Remotely Save 開始發生資料交換!","syncrun_step7skip":"7/8 Remotely Save 在空跑模式,跳過實際資料交換步驟。","syncrun_step8":"8/8 Remotely Save 已完成同步!","syncrun_shortstep0":"0/2 Remotely Save 在空跑(dry run)模式,不會發生實際的檔案交換。","syncrun_shortstep1":"1/2 Remotely Save 開始同步({{serviceType}})","syncrun_shortstep2skip":"2/2 Remotely Save 在空跑模式,跳過實際資料交換步驟。","syncrun_shortstep2":"2/2 Remotely Save 已完成同步!","syncrun_abort":"{{manifestID}}-{{theDate}}:中斷同步,同步來源={{triggerSource}},出錯階段={{syncStatus}}","syncrun_abort_protectmodifypercentage":"中斷同步!您設定了不允許 >= {{protectModifyPercentage}}% 的變更,但是現在 {{realModifyDeleteCount}}/{{allFilesCount}}={{percent}}% 的檔案會被修改或刪除!如果您確認這次同步是您想要的,那麼請在設定裡修改允許比例。","protocol_saveqr":" {{manifestName}} 的新設定匯入完成。請重啟外掛設定頁使之生效。","protocol_callbacknotsupported":"您的 uri callback 暫不支援: {{params}}","protocol_dropbox_connecting":"正在連線 Dropbox……\\n請不要關閉此彈窗。","protocol_dropbox_connect_succ":"好!我們作為使用者 {{username}} 連線上了 Dropbox!","protocol_dropbox_connect_succ_revoke":"您已作為使用者 {{username}} 連線上了。如果您想取消連線,請點選此按鈕。","protocol_dropbox_connect_fail":"Dropbox 的回撥請求有點異常。您是否網路不順暢?您是否拒絕了鑑權?","protocol_dropbox_connect_unknown":"不知道如何處理此 callback:{{params}}","protocol_dropbox_no_modal":"您不是在設定頁的彈窗裡觸發 Dropbox 的。中止操作。","protocol_onedrive_connecting":"正在連線 OneDrive……\\n請不要關閉此彈窗。","protocol_onedrive_connect_succ_revoke":"您已作為使用者 {{username}} 連線上了。如果您想取消連線,請點選此按鈕。","protocol_onedrive_connect_fail":"OneDrive 的回撥請求有點異常。您是否拒絕了鑑權?","protocol_onedrive_connect_unknown":"不知道如何處理此 callback:{{params}}","command_startsync":"開始同步(start sync)","command_drynrun":"開始同步(空跑模式)(start sync (dry run only))","command_exportsyncplans_1_only_change":"匯出同步計劃(最近 1 次)(僅修改部分)(export sync plans (latest 1) (change part))","command_exportsyncplans_1":"匯出同步計劃(最近 1 次)(export sync plans (latest 1))","command_exportsyncplans_5":"匯出同步計劃(最近 5 次)(export sync plans (latest 5))","command_exportsyncplans_all":"匯出同步計劃(所有)(export sync plans (all))","command_exportlogsindb":"從資料庫匯出終端日誌(export logs saved in db)","statusbar_sync_source_manual":"手動:","statusbar_sync_source_dry":"空跑:","statusbar_sync_source_auto":"自動:","statusbar_sync_source_auto_once_init":"啟動時同步:","statusbar_sync_source_auto_sync_on_save":"儲存時同步:","statusbar_sync_status_prefix_success":"同步成功:","statusbar_sync_status_prefix_failed":"同步失敗:","statusbar_time_years":"{{time}} 年前","statusbar_time_months":"{{time}} 月前","statusbar_time_weeks":"{{time}} 周前","statusbar_time_days":"{{time}} 天前","statusbar_time_hours":"{{time}} 小時前","statusbar_time_minutes":"{{time}} 分鐘前","statusbar_time_lessminute":"1 分鐘內","statusbar_time_now":"剛剛","statusbar_syncing":"正在同步","statusbar_lastsync_label":"日期:{{date}}","statusbar_lastsync_never":"沒觸發過同步","statusbar_lastsync_never_label":"沒觸發過同步","modal_password_title":"稍等一下,請閱讀下文:","modal_password_shortdesc":"如果密碼不是空的,那麼檔案會在上傳之前,在本地先用此密碼加密。\\n如果密碼是空的,那麼檔案會被非加密地上傳。","modal_password_attn1":"注意 1/5:儲存庫(Vault)名字是不會加密的!本外掛會在一些遠端儲存裡建立一個和庫名字有著同名的資料夾。","modal_password_attn2":"注意 2/5:密碼在本地不加密地儲存!","modal_password_attn3":"注意 3/5:一些元資訊是沒有被加密的,或者可以被較容易地猜測出來。(檔案大小很接近於沒加密的時候,且資料夾可能會被儲存為大小為 0 byte 的物件。)","modal_password_attn4":"注意 4/5:您需要確保遠端儲存是“空”的,或者已有檔案也是被同一個新密碼加密的;從而避免衝突。","modal_password_attn5":"注意 5/5:密碼越長越好。","modal_password_secondconfirm":"再次確認儲存新密碼","modal_password_notice":"新密碼已儲存!","modal_encryptionmethod_title":"稍等一下,請閱讀下文:","modal_encryptionmethod_shortdesc":"您正在修改加密方式,但是您已經設定了密碼。\\n修改加密方式之後,您需要手動完全刪除在遠端的之前加密過的庫檔案,然後重新同步(從而重新上傳)新的加密檔案。","modal_remotebasedir_title":"您正在修改遠端基資料夾設定","modal_remotebasedir_shortdesc":"1. 本外掛並不會自動在遠端把內容從舊資料夾移動到新資料夾。所有內容都會重新同步。\\n2. 如果你使得文字輸入框為空,那麼本設定會被重設回庫的資料夾名(預設設定)。\\n3. 即使您設定了端對端加密的密碼,遠端資料夾名稱本身也不會被加密。\\n4. 某些特殊字元,如“?”、“/”、“\\\\”是不允許的。文字前後的空格也會被自動刪去。","modal_remotebasedir_invaliddirhint":"您所輸入的內容含有某些特殊字元,如“?”、“/”、“\\\\”,它們是不允許的。","modal_remotebasedir_secondconfirm_vaultname":"重設回預設的庫資料夾名","modal_remotebasedir_secondconfirm_change":"確認修改","modal_remotebasedir_notice":"新的遠端基資料夾設定已儲存!","modal_remoteprefix_s3_title":"您正在修改遠端路徑字首設定","modal_remoteprefix_s3_shortdesc":"1. 本外掛並不會自動在遠端把內容從舊資料夾移動到新資料夾。所有內容都會重新同步。\\n2. 如果你使得文字輸入框為空,那麼本設定為儲存為空,檔案將會被儲存在桶(Bucket)的根目錄。\\n3. 即使您設定了端對端加密的密碼,遠端資料夾名稱本身也不會被加密。\\n4. 某些特殊字元,如“?”、“/”、“\\\\”是不允許的。文字前後的空格也會被自動刪去。","modal_remoteprefix_s3_invaliddirhint":"您所輸入的內容含有某些特殊字元,如“?”、“/”、“\\\\”,它們是不允許的。","modal_remoteprefix_s3_tosave":"您設定的新字首為:“{{{prefix}}}”","modal_remoteprefix_s3_secondconfirm_empty":"字首為空,檔案會儲存在根目錄","modal_remoteprefix_s3_secondconfirm_change":"確認修改","modal_remoteprefix_s3_notice":"新的遠端路徑字首設定已儲存!","modal_dropboxauth_manualsteps":"第 1 步:在瀏覽器中訪問以下地址,然後按照網頁提示操作。\\n到了最後,您應該會獲得一串很長的程式碼文字,請複製貼上到下方,並點選“提交”","modal_dropboxauth_autosteps":"在瀏覽器中訪問以下地址,然後按照網頁提示操作。\\n到了最後,您應該會被自動重定向回來 Obsidian。","modal_dropboxauth_copybutton":"點選此按鈕從而複製鑑權 url","modal_dropboxauth_copynotice":"鑑權 url 已複製到剪貼簿!","modal_dropboxauth_maualinput":"來自網頁的授權碼","modal_dropboxauth_maualinput_desc":"您需要點選“確認”","modal_dropboxauth_maualinput_notice":"正在嘗試連線 Dropbox","modal_dropboxauth_maualinput_conn_succ":"很好!我們作為使用者 {{username}} 連線到 Dropbox 了!","modal_dropboxauth_maualinput_conn_succ_revoke":"您已作為使用者 {{username}} 連線到 Dropbox。如果您想斷開連線,點選此按鈕。","modal_dropboxauth_maualinput_conn_fail":"連線 Dropbox 途中出錯了。","modal_onedriveauth_shortdesc":"現在只支援個人版 OneDrive,(暫)不支援企業版。\\n在瀏覽器中訪問以下地址,然後按照網頁提示操作。\\n到了最後,您應該會被自動重定向回來 Obsidian。","modal_onedriveauth_shortdesc_linux":"您正在用 Linux,有可能無法跳轉回來。請考慮使用 flatpack 版本的 Obsidian,或建立 obsidian.desktop 檔案。","modal_onedriveauth_copybutton":"點選此按鈕從而複製鑑權 url","modal_onedriveauth_copynotice":"鑑權 url 已複製到剪貼簿!","modal_onedriverevokeauth_step1":"第 1 步:用瀏覽器開啟以下地址,點選本外掛對應的“Edit”按鈕,點選“Remove these permissions”按鈕。","modal_onedriverevokeauth_step2":"第 2 步:點選以下按鈕,清理本地儲存的登入資訊。","modal_onedriverevokeauth_clean":"清理本地儲存的登入資訊","modal_onedriverevokeauth_clean_desc":"您需要點選“清理”按鈕。","modal_onedriverevokeauth_clean_button":"清理","modal_onedriverevokeauth_clean_notice":"已清理!","modal_onedriverevokeauth_clean_fail":"鑑權途中出錯了。","modal_syncconfig_attn":"注意 1/2:此設定只同步(複製)整個 Obsidian 的配置資料夾,但是不會同步其它 . 開頭的資料夾或檔案。除了會忽略 .git 和 node_modules 資料夾之外,它也並不理解配置資料夾的裡各個子檔案或子資料夾的含義。\\n注意 2/2:配置資料夾被同步之後,各外掛的設定或許會出錯,且 Obsidian 或許需要重啟來過載各外掛的新配置。\\n如果您同意自行承受以上風險,您可以點選以下再次確認按鈕。","modal_syncconfig_secondconfirm":"再次確認開啟","modal_syncconfig_notice":"您已開啟配置資料夾的同步!","modal_qr_shortdesc":"這裡可匯出(部分)設定。\\n您可以使用另一個裝置來掃描此 QR 碼。\\n又或者,您可以點選以下按鈕複製此特殊 URI,然後貼上到另一臺裝置的網路瀏覽器或 Remotely Save 設定裡的匯入部分。","modal_qr_button":"點選此按鈕複製特殊 URI","modal_qr_button_notice":"特殊 URI 已被複制到剪貼簿!","modal_sizesconflict_title":"Remotely Save:跳過大檔案的時候出現了一些衝突","modal_sizesconflict_desc":"您設定了跳過同步大於 {{thresholdMB}} MB({{thresholdBytes}} bytes)的檔案。\\n但是以下檔案的大小,在一端大於閾值,在另一端則小於閾值。\\n為了避免意外的覆蓋或刪除,外掛停止了運作,您需要手動處理至少一端的檔案。","modal_sizesconflict_copybutton":"點選以複製以下所有檔案大小衝突資訊","modal_sizesconflict_copynotice":"所有的檔案大小衝突資訊,已被複制到剪貼簿!","settings_basic":"基本設定","settings_password":"密碼","settings_password_desc":"端到端加密的密碼。不填寫則代表沒密碼。您需要點選“確認”來修改。注意:密碼和其它資訊都會在本地儲存。如果您修改了密碼,您需要手動刪除遠端的所有檔案,重新同步(從而上傳)加密檔案。","settings_encryptionmethod":"加密方法","settings_encryptionmethod_desc":"端到端加密的方法。推薦選用 RClone Crypt 方法,但是它沒有加密檔案路徑結構。OpenSSL enc 是本外掛一開始就支援的方式。兩種方法都和 RClone、OpenSSL 官方產品和社群無利益相關。如果您修改了加密方法,您需要手動刪除遠端的所有檔案,重新同步(從而上傳)加密檔案。更多詳細說明見線上文件。","settings_encryptionmethod_rclone":"RClone Crypt(推薦)","settings_encryptionmethod_openssl":"OpenSSL enc(舊方法)","settings_autorun":"自動執行","settings_autorun_desc":"每隔一段時間,此外掛嘗試自動同步。會影響到電池用量。","settings_autorun_notset":"(不設定)","settings_autorun_1min":"每 1 分鐘","settings_autorun_5min":"每 5 分鐘","settings_autorun_10min":"每 10 分鐘","settings_autorun_30min":"每 30 分鐘","settings_runoncestartup":"啟動後自動執行一次","settings_runoncestartup_desc":"本設定使得外掛在程式啟動後自動觸發一次同步。修改後,會在下一次啟動生效。本設定和“自動執行”是不同的,那個設定是指“每隔一段時間”都自動同步一次。","settings_runoncestartup_notset":"(不設定)","settings_runoncestartup_1sec":"啟動後第 1 秒執行一次","settings_runoncestartup_10sec":"啟動後第 10 秒執行一次","settings_runoncestartup_30sec":"啟動後第 30 秒執行一次","settings_synconsave":"儲存時同步(實驗性質)","settings_synconsave_desc":"外掛如果檢查到當前檔案在最近一段時間有修改儲存過,則嘗試同步。請注意,同步是一個很重的操作,因此會影響到耗電量。(修改設定後可能需要過載外掛或重啟。)","settings_synconsave_disable":"關閉(預設)","settings_synconsave_enable":"開啟","settings_skiplargefiles":"跳過大檔案","settings_skiplargefiles_desc":"跳過大於某一個閾值的檔案。這裡 1 MB = 10^6 bytes。","settings_skiplargefiles_notset":"(不設定)","settings_ignorepaths":"忽略的檔案或資料夾的正則表示式","settings_ignorepaths_desc":"忽略的檔案或資料夾的正則表示式。每行一條。路徑是相對於庫(Vault)根目錄的,沒有前置 / 符號。非空的忽略列表和非空的允許列表會一起生效。","settings_onlyallowpaths":"允許同步的檔案或資料夾的正則表示式","settings_onlyallowpaths_desc":"允許同步的檔案或資料夾的正則表示式。每行一條。路徑是相對於庫(Vault)根目錄的,沒有前置 / 符號。如果這個設定非空,那麼所有您想同步的路徑(包括隱藏的設定資料夾)都要明確地列出到這裡。非空的忽略列表和非空的允許列表會一起生效。","settings_enablestatusbar_info":"在狀態列顯示上一次成功的同步","settings_enablestatusbar_info_desc":"在狀態列顯示上一次成功的同步的時間。","settings_enablestatusbar_reloadrequired_notice":"需要重新載入此外掛才生效。","settings_resetstatusbar_time":"重設上一次成功同步的時間記錄","settings_resetstatusbar_time_desc":"重設上一次成功同步的時間記錄。","settings_resetstatusbar_button":"重設","settings_resetstatusbar_notice":"重設完畢!","settings_checkonnectivity":"檢查可否連線","settings_checkonnectivity_desc":"檢查可否連線。","settings_checkonnectivity_button":"檢查","settings_checkonnectivity_checking":"正在檢查……","settings_remotebasedir":"修改遠端基資料夾(實驗性質)","settings_remotebasedir_desc":"預設設定,內容會被同步到遠端的和資料庫同名的資料夾下。您可以在此修改遠端資料夾名,或刪除輸入框文字從而重設到預設值。您需要點選“確認”。","settings_remoteprefix_s3":"修改遠端字首路徑(實驗性質)","settings_remoteprefix_s3_desc":"預設設定 s3 儲存在儲存桶(Bucket)的根目錄。您可以在這裡修改路徑字首,或者保持為空保持預設設定。您需要點選“確認”。","settings_s3":"S3 或相容 S3 的服務的設定","settings_s3_disclaimer1":"宣告:本外掛不是 Amazon 的官方產品。","settings_s3_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現了儲存桶有不符合預期的訪問,請立刻從 AWS(或其它 S3 服務商)刪除記錄於此的 access key。","settings_s3_cors":"您需要設定 CORS,從而允許這些源的請求訪問:app://obsidian.md 和 capacitor://localhost 和 http://localhost 且增加 ETag 到暴露 headers 裡。","settings_s3_prod":"一些可參考的 Amazon S3 官方文件:","settings_s3_prod1":"服務地址(Endpoint)和區域(Region)資訊","settings_s3_prod2":"Access Key ID 和 Secret Access Key 資訊","settings_s3_prod3":"設定 CORS","settings_s3_endpoint":"服務地址(Endpoint)","settings_s3_region":"區域(Region)","settings_s3_region_desc":"如果您不知道這個值填什麼,可以嘗試填寫:us-east-1。","settings_s3_accesskeyid":"Access Key ID","settings_s3_accesskeyid_desc":"Access key ID。注意:access key ID 和其它資訊都會在本地儲存。","settings_s3_secretaccesskey":"Secret Access Key","settings_s3_secretaccesskey_desc":"Secret access key。注意:secret access key 和其它資訊都會在本地儲存。","settings_s3_bucketname":"儲存桶(Bucket)的名字","settings_s3_bypasscorslocally":"本地繞過 CORS 問題","settings_s3_bypasscorslocally_desc":"對於 Obsidian 新版本(桌面版>=0.13.25 或 iOS>=1.1.1 或 Android>=1.2.1),本外掛可以跳過伺服器設定 CORS 的步驟。如果您遇到任意問題,可以關閉此設定,並在服務端設定 CORS(允許來自 app://obsidian.md 和 capacitor://localhost 和 http://localhost 的請求且增加 ETag 到暴露 headers 裡)。","settings_s3_parts":"分塊並行度","settings_s3_parts_desc":"在 S3 裡,大檔案會被分塊上傳。您希望同一時間最多有多少個分塊被上傳?","settings_s3_accuratemtime":"使用準確的檔案修改時間","settings_s3_accuratemtime_desc":"讀取(已上傳的)準確的檔案修改時間,有助於同步演算法更加準確和穩定。但是它也會導致額外的 api 請求、時間、金錢花費。","settings_s3_urlstyle":"S3 URL style","settings_s3_urlstyle_desc":"是否對 S3 物件強制使用 path style URL(例如使用 https://s3.amazonaws.com/*/ 而不是 https://*.s3.amazonaws.com/)。","settings_s3_reverse_proxy_no_sign_url":"S3 反向代理(不簽名)地址(實驗性質)","settings_s3_reverse_proxy_no_sign_url_desc":"不會參與到簽名的 S3 反向代理地址。如果您有一個反向代理,但是不想修改原始鑑權簽名,這裡就可以填寫。沒有 http(s):// 字首。如果您不知道這是什麼,留空即可。","settings_s3_generatefolderobject":"是否生成文件夾 Object","settings_s3_generatefolderobject_desc":"S3 不存在“真正”的文件夾。如果您設置了“生成”(或用了舊版本),那麼插件會上傳 0 字節的以“/”結尾的 Object 來代表文件夾。新版本插件會默認跳過生成這種文件夾 Object。","settings_s3_generatefolderobject_notgenerate":"不生成(默認)","settings_s3_generatefolderobject_generate":"生成","settings_s3_connect_succ":"很好!可以訪問到對應儲存桶。","settings_s3_connect_fail":"無法訪問到對應儲存桶。","settings_dropbox":"Dropbox 設定","settings_dropbox_disclaimer1":"宣告:此外掛不是 Dropbox 官方產品。","settings_dropbox_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現了 Dropbox 有不符合預期的訪問,請立刻從 https://www.dropbox.com/account/connected_apps 刪除記錄於此外掛的連線鑑權。","settings_dropbox_folder":"我們會在您的 Dropbox 上建立此資料夾並在裡面同步:/Apps/{{pluginID}}/{{remoteBaseDir}}。","settings_dropbox_revoke":"撤回鑑權","settings_dropbox_revoke_desc":"您現在使用了使用者名稱 {{username}} 來連線。如果想取消連線,請點選此按鈕。","settings_dropbox_revoke_button":"撤回鑑權","settings_dropbox_revoke_notice":"鑑權已被撤回!","settings_dropbox_revoke_noticeerr":"撤回鑑權出錯。","settings_dropbox_clearlocal":"清除本地儲存的鑑權資訊","settings_dropbox_clearlocal_desc":"您可以強制清除本地已儲存的 Dropbox 的登入鑑權資訊,但不向伺服器傳送撤回鑑權的請求。","settings_dropbox_clearlocal_button":"清除","settings_dropbox_clearlocal_notice":"已清除!","settings_dropbox_auth":"鑑權","settings_dropbox_auth_desc":"鑑權。","settings_dropbox_auth_button":"鑑權","settings_dropbox_connect_succ":"很好!我們可連線上 Dropbox!","settings_dropbox_connect_fail":"我們未能連線上 Dropbox。","settings_onedrive":"Onedrive(個人版)(App Folder)設定","settings_onedrive_disclaimer1":"宣告:此外掛不是微軟或 OneDrive 的官方產品。","settings_onedrive_disclaimer2":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現了 OneDrive 有不符合預期的訪問,請立刻從 https://microsoft.com/consent 刪除記錄於此外掛的連線鑑權。","settings_onedrive_folder":"我們會在您的 OneDrive 上建立此資料夾並在裡面同步:/Apps/{{pluginID}}/{{remoteBaseDir}}。","settings_onedrive_nobiz":"現在只支援個人版 OneDrive。(暫時)並不支援企業版 OneDrive。","settings_onedrive_revoke":"撤回鑑權","settings_onedrive_revoke_desc":"您現在使用了使用者名稱 {{username}} 來連線。如果想取消連線,請點選此按鈕。","settings_onedrive_revoke_button":"撤回鑑權","settings_onedrive_auth":"鑑權","settings_onedrive_auth_desc":"鑑權。","settings_onedrive_auth_button":"鑑權","settings_onedrive_connect_succ":"很好!我們可連線上 OneDrive!","settings_onedrive_connect_fail":"我們未能連線上 OneDrive。","settings_onedrive_emptyfile":"空檔案處理","settings_onedrive_emptyfile_desc":"OneDrive 不允許上傳空檔案(即使官網也是不允許的)。那麼你想跳過空檔案還是返回錯誤?","settings_onedrive_emptyfile_skip":"跳過","settings_onedrive_emptyfile_error":"返回錯誤和中斷","settings_webdav":"Webdav 設定","settings_webdav_disclaimer1":"宣告:您所輸入的資訊儲存於本地。其它有害的或者出錯的外掛,是有可能讀取到這些資訊的。如果您發現了 Webdav 伺服器有不符合預期的訪問,請立刻修改使用者名稱和密碼。","settings_webdav_cors_os":"Obsidian 桌面版>=0.13.25 或 iOS>=1.1.1 或 Android>=1.1.1 支援跳過 CORS 設定。但您正在使用舊版,建議升級。","settings_webdav_cors":"您需要設定 CORS,允許來自這些源的請求:app://obsidian.md 和 capacitor://localhost 和 http://localhost。","settings_webdav_folder":"我們會在您的伺服器上建立此資料夾並在裡面同步:/{{remoteBaseDir}}","settings_webdav_addr":"伺服器地址","settings_webdav_addr_desc":"伺服器地址。","settings_webdav_user":"使用者名稱","settings_webdav_user_desc":"使用者名稱。注意:使用者名稱和其它資訊都會儲存在本地。","settings_webdav_password":"密碼","settings_webdav_password_desc":"密碼。注意:密碼和其它資訊都會儲存在本地。","settings_webdav_auth":"鑑權型別","settings_webdav_auth_desc":"如果不填寫密碼,本設定會被忽略。","settings_webdav_depth":"傳送到伺服器的 Depth header","settings_webdav_depth_desc":"Webdav 伺服器會被設為接收 Depth header 為“1”或“Infinity”請求。如果您不清楚如何設定,可以選擇 depth=\'1\'。如果那你確認伺服器支援 depth=\'infinity\',請選擇它,會獲得更加好的效能。","settings_webdav_depth_1":"只支援 depth=\'1\'","settings_webdav_depth_inf":"支援 depth=\'infinity\'","settings_webdav_customheaders":"傳送到伺服器的自定義 Header","settings_webdav_customheaders_desc":"有些使用者需要設定自定義 header。如果您不知道是什麼,可以直接留空不填。輸入格式:每行形如 X-Header1:value1。header 的 key 和 value 之間的空格會被刪除。","settings_webdav_connect_succ":"很好!可以連線上 Webdav 伺服器。","settings_webdav_connect_fail":"無法連線上 Webdav 伺服器。(可能是地址/賬號/密碼/鑑權型別等錯誤。)","settings_webdav_connect_fail_withcors":"無法連線上 Webdav 伺服器。(可能是地址/賬號/密碼/鑑權型別/CORS 等錯誤。)","settings_webdis":"Webdis 設置","settings_webdis_disclaimer1":"聲明:此插件不是 Redis® Ltd 或 Redis® 軟件或 Wedis 的官方產品。Redis 是 Redis Ltd 的註冊商標。","settings_webdis_disclaimer2":"聲明:您所輸入的信息存儲於本地。其它有害的或者出錯的插件,是有可能讀取到這些信息的。如果您發現了 Webdis 服務器有不符合預期的訪問,請立刻修改用戶名和密碼。","settings_webdis_folder":"我們會在您的服務器上創建帶有此前綴的 key 並在裡面同步::{{remoteBaseDir}}。","settings_webdis_addr":"服務器地址","settings_webdis_addr_desc":"服務器地址","settings_webdis_user":"用戶名","settings_webdis_user_desc":"用戶名。注意:用戶名和其它信息都會保存在本地。","settings_webdis_password":"密碼","settings_webdis_password_desc":"密碼。注意:密碼和其它信息都會保存在本地。","settings_webdis_connect_succ":"很好!可以連接上 Webdis 服務器。","settings_webdis_connect_fail":"無法連接上 Webdis 服務器。(可能是地址/賬號/密碼/鑑權類型等錯誤。)","settings_chooseservice":"選擇遠端服務","settings_chooseservice_desc":"從這裡開始設定。您想連線到哪一個服務?S3、Dropbox、Webdav、OneDrive(個人版)、Webdis?","settings_chooseservice_s3":"S3 或相容 S3 的服務","settings_chooseservice_dropbox":"Dropbox","settings_chooseservice_webdav":"Webdav","settings_chooseservice_onedrive":"OneDrive(個人版)","settings_chooseservice_webdis":"Webdis (an HTTP interface for Redis®)","settings_adv":"進階設定","settings_concurrency":"並行度","settings_concurrency_desc":"您希望同時最多有多少個檔案被上傳和下載?預設值是 5。如果您遇到了一些問題(如訪問頻率限制),您可以減少並行度。","settings_syncunderscore":"同步 _ 檔案或資料夾","settings_syncunderscore_desc":"是否同步“_”(下劃線)開始的檔案或資料夾。","settings_configdir":"同步配置資料夾(實驗性質)","settings_configdir_desc":"是否同步 Obsidian 的配置資料夾 {{configDir}}(其中的 .git 和 node_modules 依然會被忽略)。請注意,此設定可能會影響到您 Obsidian 或者所有的外掛設定,也可能需要您同步完畢後重啟 Obsidian。如果您同意自行承受其風險,則可以開啟本設定。","settings_bookmarks":"同步書籤(實驗性質)","settings_bookmarks_desc":"是否同步書籤 {{configDir}}/bookmarks.json 。如果您設定了同步配置資料夾,此選項會被忽略並設為“開啟”。","settings_deletetowhere":"刪除檔案到哪裡","settings_deletetowhere_desc":"外掛觸發刪除操作時候,刪除到哪裡?","settings_deletetowhere_system_trash":"系統回收站(預設)","settings_deletetowhere_obsidian_trash":"Obsidian .trash 資料夾","settings_conflictaction":"處理衝突","settings_conflictaction_desc":"如果一個檔案,在本地和伺服器都被建立或者修改了,那麼這就是一個“衝突”情況。如何處理?這個設定只在雙向同步時候生效。","settings_conflictaction_keep_newer":"保留最後修改的版本(預設)","settings_conflictaction_keep_larger":"保留檔案體積較大的版本","settings_cleanemptyfolder":"處理空資料夾","settings_cleanemptyfolder_desc":"同步演算法主要是針對檔案處理的,您需要手動指定空資料夾如何處理。","settings_cleanemptyfolder_skip":"跳過處理空資料夾(預設)","settings_cleanemptyfolder_clean_both":"刪除本地和伺服器的空資料夾","settings_protectmodifypercentage":"如果修改超過百分比則中止同步","settings_protectmodifypercentage_desc":"如果演算法檢測到超過 n% 的檔案會被修改或刪除,則中止同步。從而可以保護使用者的檔案免受預料之外的修改。您可以設定為 100 而去除此保護,也可以設定為 0 總是強制中止所有同步。","settings_protectmodifypercentage_000_desc":"0(總是強制中止)","settings_protectmodifypercentage_050_desc":"50(預設值)","settings_protectmodifypercentage_100_desc":"100(去除此保護)","settings_protectmodifypercentage_custom_desc":"自定義","settings_protectmodifypercentage_customfield":"如果修改超過自定義百分比則中止同步","settings_protectmodifypercentage_customfield_desc":"您需要輸入 0(含)~ 100(含)的數字。小數也是可以的。","setting_syncdirection":"同步方向(實驗性質)","setting_syncdirection_desc":"

W外掛應該向哪裡同步?注意每個選項都是隻有修改了的檔案(基於修改時間和大小判斷)才會觸發同步動作。

  1. 雙向同步:一邊的變動會同步到另一邊。
  2. 增量推送:本地建立或修改的檔案會複製到遠端。
  3. 增量拉取:遠端建立或修改的檔案會複製到本地。
  4. 增量推送帶刪除:本地建立或修改的檔案會複製到遠端,本地的刪除也會在遠端執行。
  5. 增量拉取帶刪除:遠端建立或修改的檔案會複製到本地,遠端的刪除也會在本地執行。
","setting_syncdirection_bidirectional_desc":"雙向同步(預設)","setting_syncdirection_incremental_push_only_desc":"增量推送(也即:備份模式)","setting_syncdirection_incremental_pull_only_desc":"增量拉取","setting_syncdirection_incremental_push_and_delete_only_desc":"增量推送帶刪除","setting_syncdirection_incremental_pull_and_delete_only_desc":"增量拉取帶刪除","settings_enablemobilestatusbar":"手機的狀態列(實驗性質)","settings_enablemobilestatusbar_desc":"Obsidian 手機版預設隱藏了狀態列。有些使用者希望展示它。這裡提供了設定選項。","settings_importexport":"匯入匯出部分設定","settings_export":"匯出","settings_export_desc":"用 QR 碼或 URI 匯出設定資訊。","settings_export_basic_and_advanced_button":"匯出基本或進階設定","settings_export_s3_button":"匯出 S3 部分","settings_export_dropbox_button":"匯出 Dropbox 部分","settings_export_onedrive_button":"匯出 OneDrive (App Folder) 部分","settings_export_webdav_button":"匯出 Webdav 部分","settings_export_webdis_button":"匯出 Webdis 部分","settings_import":"匯入","settings_import_desc":"貼上之前匯出的 URI 到這裡然後點選“匯入”。或,使用拍攝 app 或者掃描 QR 碼的 app,來掃描對應的 QR 碼。","settings_import_button":"匯入","settings_import_error_notice":"您輸入的 URI 是空的或者不準確的!","settings_debug":"除錯","settings_debuglevel":"修改同步提示資訊","settings_debuglevel_desc":"預設值為 \\"info\\"。您可以改為 \\"debug\\" 從而在同步時候裡獲取更多資訊。","settings_outputsettingsconsole":"讀取硬碟上的設定檔案輸出到終端","settings_outputsettingsconsole_desc":"硬碟上的設定檔案是編碼過的,點選這裡從而解碼並輸出到終端。","settings_outputsettingsconsole_button":"輸出","settings_outputsettingsconsole_notice":"已輸出到終端","settings_obfuscatesettingfile":"是否混淆儲存設定檔案","settings_obfuscatesettingfile_desc":"設定檔案(data.json)含有敏感資訊。強烈建議混淆後儲存它,從而避免出乎意料的讀取和修改。如果您確認要手動檢視和修改它,可以關閉混淆儲存。","settings_viewconsolelog":"檢視終端輸出","settings_viewconsolelog_desc":"電腦上,輸入“ctrl+shift+i”或“cmd+shift+i”來檢視終端輸出。手機上,安裝第三方外掛 Logstravaganza 來匯出終端輸出到一篇筆記上。","settings_syncplans":"匯出同步計劃","settings_syncplans_desc":"每次您啟動同步,並在實際上傳下載前,外掛會生成同步計劃。它可以使您知道每次同步發生了什麼。點選按鈕可以匯出同步計劃。","settings_syncplans_button_1_only_change":"匯出最近 1 次(僅修改部分)","settings_syncplans_button_5_only_change":"匯出最近 5 次(僅修改部分)","settings_syncplans_button_1":"匯出最近 1 次","settings_syncplans_button_5":"匯出最近 5 次","settings_syncplans_button_all":"匯出所有","settings_syncplans_notice":"同步計劃已匯出","settings_delsyncplans":"刪除資料庫裡的同步計劃歷史","settings_delsyncplans_desc":"刪除資料庫裡的同步計劃歷史。","settings_delsyncplans_button":"刪除同步計劃歷史","settings_delsyncplans_notice":"(資料庫裡的)同步計劃已被刪除。","settings_delprevsync":"刪除資料庫裡的上次同步明細","settings_delprevsync_desc":"同步演算法需要上次成功同步的資訊來決定檔案變更,這個資訊儲存在本地的資料庫裡。如果您想忽略這些資訊從而所有檔案都被視為新建立的話,可以在此刪除之前的資訊。","settings_delprevsync_button":"刪除上次同步明細","settings_delprevsync_notice":"(本地資料庫裡的)上次同步明細已被刪除。","settings_profiler_results":"匯出效能資料記錄","settings_profiler_results_desc":"外掛記錄了每次同步每一步的耗時。這裡可以匯出記錄得知哪一步最慢。","settings_profiler_results_notice":"效能資料已匯出","settings_profiler_results_button_all":"匯出所有","settings_profiler_enableprofiler":"效能收集","settings_profiler_enableprofiler_desc":"是否開啟效能收集功能?","settings_profiler_enabledebugprint":"效能收集輸出","settings_profiler_enabledebugprint_desc":"是否直接輸出效能收集結果到終端裡?","settings_profiler_recordsize":"效能收集統計物件大小","settings_profiler_recordsize_desc":"是否收集物件的大小?","settings_outputbasepathvaultid":"輸出資料庫對應的位置和隨機分配的 ID","settings_outputbasepathvaultid_desc":"用於除錯。","settings_outputbasepathvaultid_button":"輸出","settings_resetcache":"重設本地快取和資料庫","settings_resetcache_desc":"(出於除錯原因)重設本地快取和資料庫。您需要在重設之後重新載入此外掛。本重設不會刪除 s3,密碼……等設定。","settings_resetcache_button":"重設","settings_resetcache_notice":"本地同步快取和資料庫已被刪除。請手動重新載入此外掛。","syncalgov3_title":"Remotely Save 的同步演算法有重大更新","syncalgov3_texts":"歡迎使用 Remotely Save!\\n從這個版本開始,外掛更新了同步演算法:\\n
  • 更穩健的刪除同步
  • 引入衝突處理
  • 避免上傳元資料
  • 修改刪除保護
  • 備份模式
  • 新的加密方式
  • ……
\\n敬請期待更多更新!詳細介紹請參閱文件網站。\\n如果您同意使用新版本,請閱讀和勾選兩個勾選框,然後點選“同意”按鈕,開始使用外掛吧!\\n如果您不同意,請點選“不同意”按鈕,外掛將自動停止執行(unload)。\\n此外,請考慮訪問 GitHub 頁面然後點贊 ⭐!您的支援對我十分重要!謝謝!","syncalgov3_checkbox_manual_backup":"我將會首先手動備份我的庫(Vault)。","syncalgov3_checkbox_requiremultidevupdate":"我理解,我需要在所有裝置上都更新此外掛使之正常執行。","syncalgov3_button_agree":"同意","syncalgov3_button_disagree":"不同意","menu_check_file_stat":"檢視檔案屬性"}')},Xj=Aj()(Zj,Qj);class eH{constructor(e,t){this.lang=e,this.saveSettingFunc=t}changeTo(e){return r(this,void 0,void 0,(function*(){this.lang=e,yield this.saveSettingFunc(e)}))}_get(e){let t=this.lang;t="auto"===this.lang&&k.moment.locale().replace("-","_")in Xj?k.moment.locale().replace("-","_"):"en";return Xj[t][e]||Xj.en[e]||e}t(e,t){return void 0===t?this._get(e):Yj.render(this._get(e),t)}}var tH=__webpack_require__(87583);const rH=(e,t)=>{const r=e;if(void 0===r.func||"settings"!==r.func||void 0===r.vault||void 0===r.data)return{status:"error",message:`the uri is not for exporting/importing settings: ${JSON.stringify(e)}`};if(r.vault!==t)return{status:"error",message:`the target vault is ${r.vault} but you are currently in ${t}: ${JSON.stringify(e)}`};let i={};try{i=JSON.parse(r.data)}catch(t){return{status:"error",message:`errors while parsing settings: ${JSON.stringify(e)}`}}return{status:"ok",message:"ok",result:i}},iH={enable:!1,enablePrinting:!1,recordSize:!1};class nH{constructor(e,t,r){if(this.breakPoints=[],this.indent=0,this.startTime=0,this.enablePrinting=null!=t&&t,this.recordSize=null!=r&&r,void 0!==e){this.startTime=Date.now();const t={label:e,fakeTimeMilli:performance.now(),indent:this.indent};this.breakPoints.push(t),this.enablePrinting&&console.debug(this.toString(-1))}}insert(e){0===this.breakPoints.length&&(this.startTime=Date.now());const t={label:e,fakeTimeMilli:performance.now(),indent:this.indent};return this.breakPoints.push(t),this.enablePrinting&&console.debug(this.toString(-1)),this}insertSize(e,t){if(!this.recordSize)return;0===this.breakPoints.length&&(this.startTime=Date.now());const r={label:e,fakeTimeMilli:performance.now(),indent:this.indent,size:eh(t)};return this.breakPoints.push(r),this.enablePrinting&&console.debug(this.toString(-1)),this}addIndent(){this.indent+=2}removeIndent(){this.indent-=2,this.indent<0&&(this.indent=0)}clear(){return this.breakPoints=[],this.indent=0,this.startTime=0,this}toString(e){var t,r,i,n;if(void 0!==e){let o=e;e<0&&(o=this.breakPoints.length+e);const s=null===(t=this.breakPoints)||void 0===t?void 0:t[o].label,a=null===(r=this.breakPoints)||void 0===r?void 0:r[o].indent;let l=0;o>=1&&(l=Math.round(10*((null===(i=this.breakPoints)||void 0===i?void 0:i[o].fakeTimeMilli)-(null===(n=this.breakPoints)||void 0===n?void 0:n[o-1].fakeTimeMilli)))/10);let d=`${" ".repeat(a)}[${s}]: ${l}ms`;if(this.breakPoints[o].hasOwnProperty("size")){d+=`, size=${this.breakPoints[o].size}`}return d}if(0===this.breakPoints.length)return"nothing in profiler";let o=`[startTime]: ${Vp(this.startTime)}`;for(let e=0;er(void 0,void 0,void 0,(function*(){const r=Date.now();yield e.profilerResultsTbl.setItem(`${i}\t${r}`,t);const n=(yield e.profilerResultsTbl.keys()).filter((e=>e.startsWith(`${i}\t`))).map((e=>Number.parseInt(e.split("\t")[1])));for(n.sort(((e,t)=>-(e-t)));n.length>5;){const t=n.pop();yield e.profilerResultsTbl.removeItem(`${i}\t${t}`)}})))(e,this.toString(),t)}))}} +/** + * @license lucide v0.416.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */ +const oH=["svg",w,[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"}],["circle",{cx:"12",cy:"12",r:"3"}]]],sH=["svg",w,[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143"}],["path",{d:"m2 2 20 20"}]]];class aH extends k.Modal{constructor(e,t,r){super(e),this.plugin=t,this.newRemotePrefix=r}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("modal_remoteprefix_azureblobstorage_title")}),t("modal_remoteprefix_azureblobstorage_shortdesc").split("\n").forEach(((t,r)=>{e.createEl("p",{text:t})})),e.createEl("p",{text:t("modal_remoteprefix_azureblobstorage_tosave",{prefix:this.newRemotePrefix})}),new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_remoteprefix_azureblobstorage_secondconfirm_change")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.azureblobstorage.remotePrefix=this.newRemotePrefix,yield this.plugin.saveSettings(),new k.Notice(t("modal_remoteprefix_azureblobstorage_notice")),this.close()})))),e.setClass("remoteprefix-azureblobstorage-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))}onClose(){const{contentEl:e}=this;e.empty()}}class lH extends k.Modal{constructor(e,t,r,i,n,o){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.t=o}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t,i=(()=>{const e=new lh.OAuthConfig({clientId:U,clientSecret:L});return new lh.BoxOAuth({config:e}).getAuthorizeUrl({redirectUri:`obsidian://${q}`})})(),n=e.createDiv();n.createDiv({text:Qp(t("modal_boxauth_tutorial"))}),n.createEl("button",{text:t("modal_boxauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_boxauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:i,text:i})}))}onClose(){const{contentEl:e}=this;e.empty()}}class dH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_boxrevokeauth_step1")});const i="https://app.box.com/account/security";t.createEl("p").createEl("a",{href:i,text:i}),t.createEl("p",{text:e("modal_boxrevokeauth_step2")}),new k.Setting(t).setName(e("modal_boxrevokeauth_clean")).setDesc(e("modal_boxrevokeauth_clean_desc")).addButton((t=>r(this,void 0,void 0,(function*(){t.setButtonText(e("modal_boxrevokeauth_clean_button")),t.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.box=m()(bh),yield this.plugin.saveSettings(),this.authDiv.toggleClass("box-auth-button-hide",""!==this.plugin.settings.box.refreshToken),this.revokeAuthDiv.toggleClass("box-revoke-auth-button-hide",""===this.plugin.settings.box.refreshToken),new k.Notice(e("modal_boxrevokeauth_clean_notice")),this.close()}catch(t){console.error(t),new k.Notice(e("modal_boxrevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class cH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.t=r,this.files=i,this.fsLocal=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_cleardupfiles_warning")}),t.createEl("pre").createEl("code",{text:this.files.join("\n")}),new k.Setting(t).addButton((t=>{t.setButtonText(e("modal_cleardupfiles_warning_confirm")),t.onClick((()=>r(this,void 0,void 0,(function*(){var t,i;yield(t=this.files,i=this.fsLocal,r(void 0,void 0,void 0,(function*(){yield Promise.all(t.map((e=>r(void 0,void 0,void 0,(function*(){return yield i.rm(e)})))))}))),new k.Notice(e("modal_cleardupfiles_warning_finished")),this.close()}))))})).addButton((t=>{t.setButtonText(e("goback")),t.onClick((()=>{this.close()}))}))}))}onClose(){const{contentEl:e}=this;e.empty()}}const uH=(e,t,i,n)=>{new k.Setting(e).setName(t("settings_cleardupfiles")).setDesc(Qp(t("settings_cleardupfiles_desc"))).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_cleardupfiles_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){var e,o,s;const a=new Cj(i.vault,null!==(e=n.settings.syncConfigDir)&&void 0!==e&&e,null!==(o=n.settings.syncBookmarks)&&void 0!==o&&o,i.vault.configDir,n.manifest.id,void 0,null!==(s=n.settings.deleteToWhere)&&void 0!==s?s:"system"),l=yield(e=>r(void 0,void 0,void 0,(function*(){const t=yield e.walk();t.sort(((e,t)=>-(e.keyRaw.length-t.keyRaw.length)));const r=new Set,i=new Set;for(const{keyRaw:e}of t){if(e.endsWith("/"))continue;e.includes("dup")&&r.add(e);const t=K_(e);r.has(t)&&i.add(t)}return[...i]})))(a);new cH(i,n,t,l,a).open()}))))}))))};class pH extends k.Modal{constructor(e,t,r,i,n,o){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.t=o}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t,i="https://remotelysave.com/auth/googledrive/start",n=e.createDiv();n.createDiv({text:Qp(t("modal_googledriveauth_tutorial"))}),n.createEl("button",{text:t("modal_googledriveauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_googledriveauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:i,text:i});let o="";new k.Setting(e).setName(t("modal_googledrivce_maualinput")).setDesc(t("modal_googledrivce_maualinput_desc")).addText((e=>e.setPlaceholder("").setValue("").onChange((e=>{o=e.trim()})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(t("submit")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(t("modal_googledrive_maualinput_notice"));try{void 0===this.plugin.settings.googledrive&&(this.plugin.settings.googledrive=m()(Sh)),this.plugin.settings.googledrive.refreshToken=o,this.plugin.settings.googledrive.accessToken="access",this.plugin.settings.googledrive.accessTokenExpiresAtTimeMs=1,this.plugin.settings.googledrive.accessTokenExpiresInMs=1;const e=yield Eh(o),r=Date.now();this.plugin.settings.googledrive.accessToken=e.access_token,this.plugin.settings.googledrive.accessTokenExpiresInMs=1e3*e.expires_in,this.plugin.settings.googledrive.accessTokenExpiresAtTimeMs=r+1e3*e.expires_in-12e4,this.plugin.settings.googledrive.credentialsShouldBeDeletedAtTimeMs=Date.now()+50976e5,yield this.plugin.saveSettings(),yield navigator.clipboard.writeText(""),new k.Notice(t("modal_googledrive_maualinput_succ_notice"))}catch(e){console.error(e),new k.Notice(t("modal_googledrive_maualinput_fail_notice"))}finally{this.authDiv.toggleClass("googledrive-auth-button-hide",""!==this.plugin.settings.googledrive.refreshToken),this.revokeAuthDiv.toggleClass("googledrive-revoke-auth-button-hide",""===this.plugin.settings.googledrive.refreshToken),this.close()}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class hH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_googledriverevokeauth_step1")});const i="https://myaccount.google.com/permissions";t.createEl("p").createEl("a",{href:i,text:i}),t.createEl("p",{text:e("modal_googledriverevokeauth_step2")}),new k.Setting(t).setName(e("modal_googledriverevokeauth_clean")).setDesc(e("modal_googledriverevokeauth_clean_desc")).addButton((t=>r(this,void 0,void 0,(function*(){t.setButtonText(e("modal_googledriverevokeauth_clean_button")),t.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.googledrive=m()(Sh),yield this.plugin.saveSettings(),this.authDiv.toggleClass("googledrive-auth-button-hide",""!==this.plugin.settings.googledrive.refreshToken),this.revokeAuthDiv.toggleClass("googledrive-revoke-auth-button-hide",""===this.plugin.settings.googledrive.refreshToken),new k.Notice(e("modal_googledriverevokeauth_clean_notice")),this.close()}catch(t){console.error(t),new k.Notice(e("modal_googledriverevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class fH extends k.Modal{constructor(e,t,r,i,n,o){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.t=o}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t,i=((e,t)=>{let r="urn:ietf:wg:oauth:2.0:oob";return t&&(r=`obsidian://${V}`),`${e}/oauth2/auth?${new URLSearchParams({response_type:"code",client_id:J,redirect_uri:r,scope:"public",state:E()})}`})(this.plugin.settings.koofr.api,!0),n=e.createDiv();n.createDiv({text:Qp(t("modal_koofrauth_tutorial"))}),n.createEl("button",{text:t("modal_koofrauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_koofrauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:i,text:i})}))}onClose(){const{contentEl:e}=this;e.empty()}}class mH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_koofrrevokeauth_step1")});const i="https://app.koofr.net/app/admin/preferences/security";t.createEl("p").createEl("a",{href:i,text:i}),t.createEl("p",{text:e("modal_koofrrevokeauth_step2")}),new k.Setting(t).setName(e("modal_koofrrevokeauth_clean")).setDesc(e("modal_koofrrevokeauth_clean_desc")).addButton((t=>r(this,void 0,void 0,(function*(){t.setButtonText(e("modal_koofrrevokeauth_clean_button")),t.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.koofr=m()(Nh),yield this.plugin.saveSettings(),this.authDiv.toggleClass("koofr-auth-button-hide",""!==this.plugin.settings.koofr.refreshToken),this.revokeAuthDiv.toggleClass("koofr-revoke-auth-button-hide",""===this.plugin.settings.koofr.refreshToken),new k.Notice(e("modal_koofrrevokeauth_clean_notice")),this.close()}catch(t){console.error(t),new k.Notice(e("modal_koofrrevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class gH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,{authUrl:t,verifier:i}=yield function(e,t){return r(this,void 0,void 0,(function*(){const r=new Aw,{verifier:i,challenge:n}=yield r.generatePkceCodes(),o={challengeMethod:"S256",verifier:i,challenge:n},s={redirectUri:i_,scopes:r_,codeChallenge:o.challenge,codeChallengeMethod:o.challengeMethod},a=new Vw({auth:{clientId:e,authority:t}});return{authUrl:yield a.getAuthCodeUrl(s),verifier:i}}))}(this.plugin.settings.onedrivefull.clientID,this.plugin.settings.onedrivefull.authority);this.plugin.oauth2Info.verifier=i;const n=(e,t)=>this.plugin.i18n.t(e,t);n("modal_onedrivefullauth_shortdesc").split("\n").forEach((t=>{e.createEl("p",{text:t})})),k.Platform.isLinux&&n("modal_onedrivefullauth_shortdesc_linux").split("\n").forEach((t=>{e.createEl("p",{text:Qp(t)})}));e.createDiv().createEl("button",{text:n("modal_onedrivefullauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(t),new k.Notice(n("modal_onedrivefullauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:t,text:t})}))}onClose(){const{contentEl:e}=this;e.empty()}}class yH extends k.Modal{constructor(e,t,r,i){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("p",{text:t("modal_onedrivefullrevokeauth_step1")});const i="https://microsoft.com/consent";e.createEl("p").createEl("a",{href:i,text:i}),e.createEl("p",{text:t("modal_onedrivefullrevokeauth_step2")}),new k.Setting(e).setName(t("modal_onedrivefullrevokeauth_clean")).setDesc(t("modal_onedrivefullrevokeauth_clean_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(t("modal_onedrivefullrevokeauth_clean_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.onedrivefull=JSON.parse(JSON.stringify(n_)),yield this.plugin.saveSettings(),this.authDiv.toggleClass("onedrivefull-auth-button-hide",""!==this.plugin.settings.onedrivefull.username),this.revokeAuthDiv.toggleClass("onedrivefull-revoke-auth-button-hide",""===this.plugin.settings.onedrivefull.username),new k.Notice(t("modal_onedrivefullrevokeauth_clean_notice")),this.close()}catch(e){console.error(e),new k.Notice(t("modal_onedrivefullrevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class vH extends k.Modal{constructor(e,t,r,i,n,o){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.t=o}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t,{authUrl:i}=yield(n=!0,r(void 0,void 0,void 0,(function*(){const e=H,t=E();let r=`https://my.pcloud.com/oauth2/authorize?response_type=code&client_id=${e}&state=${t}`;return n&&(r+=`&redirect_uri=obsidian://${j}`),{authUrl:r,state:t}})));var n;const o=e.createDiv();o.createDiv({text:Qp(t("modal_pcloudauth_tutorial"))}),o.createEl("button",{text:t("modal_pcloudauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_pcloudauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:i,text:i})}))}onClose(){const{contentEl:e}=this;e.empty()}}class bH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_pcloudrevokeauth_step1")});const i="https://my.pcloud.com/#page=settings&settings=tab-apps";t.createEl("p").createEl("a",{href:i,text:i}),t.createEl("p",{text:e("modal_pcloudrevokeauth_step2")}),new k.Setting(t).setName(e("modal_pcloudrevokeauth_clean")).setDesc(e("modal_pcloudrevokeauth_clean_desc")).addButton((t=>r(this,void 0,void 0,(function*(){t.setButtonText(e("modal_pcloudrevokeauth_clean_button")),t.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.pcloud=m()(p_),yield this.plugin.saveSettings(),this.authDiv.toggleClass("pcloud-auth-button-hide",""!==this.plugin.settings.pcloud.accessToken),this.revokeAuthDiv.toggleClass("pcloud-revoke-auth-button-hide",""===this.plugin.settings.pcloud.accessToken),new k.Notice(e("modal_pcloudrevokeauth_clean_notice")),this.close()}catch(t){console.error(t),new k.Notice(e("modal_pcloudrevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class wH extends k.Modal{constructor(e,t,r,i,n,o,s){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.proFeaturesListSetting=o,this.t=s}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,{authUrl:t,codeVerifier:i,codeChallenge:n}=yield ae(!1);this.plugin.oauth2Info.verifier=i;const o=this.t;e.createDiv().createEl("button",{text:o("modal_proauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(t),new k.Notice(o("modal_proauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:t,text:t});let s="";new k.Setting(e).setName(o("modal_proauth_maualinput")).setDesc(o("modal_proauth_maualinput_desc")).addText((e=>e.setPlaceholder("").setValue("").onChange((e=>{s=e.trim()})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(o("submit")),e.onClick((()=>r(this,void 0,void 0,(function*(){var e,t,n,a,l,d,c;new k.Notice(o("modal_proauth_maualinput_notice"));try{const u=yield le(null!=i?i:"verifier",s,(e=>r(this,void 0,void 0,(function*(){throw new k.Notice(o("protocol_pro_connect_fail")),new k.Notice(`${e}`),e}))));console.debug(u);const p=this;de(this.plugin.settings.pro,u,(()=>p.plugin.saveSettings())),yield ue(this.plugin.settings.pro,this.plugin.manifest.version,(()=>p.plugin.saveSettings())),this.proFeaturesListSetting.setDesc(Qp(o("settings_pro_features_desc",{features:xH(this.plugin.settings.pro.enabledProFeatures)}))),yield pe(this.plugin.settings.pro,this.plugin.manifest.version,(()=>p.plugin.saveSettings())),new k.Notice(o("protocol_pro_connect_manualinput_succ",{email:null!==(e=this.plugin.settings.pro.email)&&void 0!==e?e:"(no email)"})),this.plugin.oauth2Info.verifier="",null===(t=this.plugin.oauth2Info.authDiv)||void 0===t||t.toggleClass("pro-auth-button-hide",""!==(null===(n=this.plugin.settings.pro)||void 0===n?void 0:n.refreshToken)),this.plugin.oauth2Info.authDiv=void 0,null===(a=this.plugin.oauth2Info.revokeAuthSetting)||void 0===a||a.setDesc(o("protocol_pro_connect_succ_revoke",{email:null===(l=this.plugin.settings.pro)||void 0===l?void 0:l.email})),this.plugin.oauth2Info.revokeAuthSetting=void 0,null===(d=this.plugin.oauth2Info.revokeDiv)||void 0===d||d.toggleClass("pro-revoke-auth-button-hide",""===(null===(c=this.plugin.settings.pro)||void 0===c?void 0:c.email)),this.plugin.oauth2Info.revokeDiv=void 0,yield navigator.clipboard.writeText(""),this.close()}catch(e){console.error(e),new k.Notice(o("modal_proauth_maualinput_conn_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class _H extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t;e.createEl("p",{text:t("modal_prorevokeauth")}),new k.Setting(e).setName(t("modal_prorevokeauth_clean")).setDesc(t("modal_prorevokeauth_clean_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(t("modal_prorevokeauth_clean_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){var e,r;try{this.plugin.settings.pro=m()(se),yield this.plugin.saveSettings(),this.authDiv.toggleClass("pro-auth-button-hide",""!==(null===(e=this.plugin.settings.pro)||void 0===e?void 0:e.refreshToken)),this.revokeAuthDiv.toggleClass("pro-revoke-auth-button-hide",""===(null===(r=this.plugin.settings.pro)||void 0===r?void 0:r.refreshToken)),new k.Notice(t("modal_prorevokeauth_clean_notice")),this.close()}catch(e){console.error(e),new k.Notice(t("modal_prorevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}const xH=e=>void 0===e||0===e.length?"No features enabled.":e.map((e=>`${e.featureName} (expire: ${new Date(Number(e.expireAtTimeMs)).toISOString()})`)).join("
");class SH extends k.Modal{constructor(e,t,r,i,n,o){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n,this.t=o}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=this.t,i=(e=>{let t="https://oauth.yandex.com/verification_code";return e&&(t=`obsidian://${G}`),`https://oauth.yandex.com/authorize?${new URLSearchParams({response_type:"code",client_id:W,redirect_uri:t,force_confirm:"yes",state:E()})}`})(!0),n=e.createDiv();n.createDiv({text:Qp(t("modal_yandexdiskauth_tutorial"))}),n.createEl("button",{text:t("modal_yandexdiskauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_yandexdiskauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:i,text:i})}))}onClose(){const{contentEl:e}=this;e.empty()}}class kH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.t=n}onOpen(){return r(this,void 0,void 0,(function*(){const e=this.t,{contentEl:t}=this;t.createEl("p",{text:e("modal_yandexdiskrevokeauth_step1")});const i="https://app.yandexDisk.com/account/security";t.createEl("p").createEl("a",{href:i,text:i}),t.createEl("p",{text:e("modal_yandexdiskrevokeauth_step2")}),new k.Setting(t).setName(e("modal_yandexdiskrevokeauth_clean")).setDesc(e("modal_yandexdiskrevokeauth_clean_desc")).addButton((t=>r(this,void 0,void 0,(function*(){t.setButtonText(e("modal_yandexdiskrevokeauth_clean_button")),t.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.yandexdisk=m()(y_),yield this.plugin.saveSettings(),this.authDiv.toggleClass("yandexdisk-auth-button-hide",""!==this.plugin.settings.yandexdisk.refreshToken),this.revokeAuthDiv.toggleClass("yandexdisk-revoke-auth-button-hide",""===this.plugin.settings.yandexdisk.refreshToken),new k.Notice(e("modal_yandexdiskrevokeauth_clean_notice")),this.close()}catch(t){console.error(t),new k.Notice(e("modal_yandexdiskrevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class EH extends k.Modal{constructor(e,t,r,i){super(e),this.plugin=t,this.newPassword=r,this.encryptionMethodSetting=i}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("modal_password_title")}),t("modal_password_shortdesc").split("\n").forEach(((t,r)=>{e.createEl("p",{text:t})})),[t("modal_password_attn1"),t("modal_password_attn2"),t("modal_password_attn3"),t("modal_password_attn4"),t("modal_password_attn5")].forEach(((t,r)=>{r<3?e.createEl("p",{text:t,cls:"password-disclaimer"}):e.createEl("p",{text:t})})),new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_password_secondconfirm")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.password=this.newPassword,""!==this.newPassword?this.encryptionMethodSetting.settingEl.removeClass("settings-encryption-method-hide"):this.encryptionMethodSetting.settingEl.addClass("settings-encryption-method-hide"),yield this.plugin.saveSettings(),new k.Notice(t("modal_password_notice")),this.close()})))),e.setClass("password-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))}onClose(){const{contentEl:e}=this;e.empty()}}class TH extends k.Modal{constructor(e,t){super(e),this.plugin=t}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("modal_encryptionmethod_title")}),t("modal_encryptionmethod_shortdesc").split("\n").forEach(((t,r)=>{e.createEl("p",{text:Qp(t)})})),new k.Setting(e).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.close()})))),e.setClass("encryptionmethod-second-confirm")}))}onClose(){const{contentEl:e}=this;e.empty()}}class BH extends k.Modal{constructor(e,t,r,i){super(e),this.plugin=t,this.newRemoteBaseDir=r,this.service=i}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("modal_remotebasedir_title")}),t("modal_remotebasedir_shortdesc").split("\n").forEach(((t,r)=>{e.createEl("p",{text:t})})),""===this.newRemoteBaseDir||this.newRemoteBaseDir===this.app.vault.getName()?new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_remotebasedir_secondconfirm_vaultname")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings[this.service].remoteBaseDir="",yield this.plugin.saveSettings(),new k.Notice(t("modal_remotebasedir_notice")),this.close()})))),e.setClass("remotebasedir-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))})):(e=>/[?/\\]/.test(e))(this.newRemoteBaseDir)?(e.createEl("p",{text:t("modal_remotebasedir_invaliddirhint")}),new k.Setting(e).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))):new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_remotebasedir_secondconfirm_change")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings[this.service].remoteBaseDir=this.newRemoteBaseDir,yield this.plugin.saveSettings(),new k.Notice(t("modal_remotebasedir_notice")),this.close()})))),e.setClass("remotebasedir-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))}onClose(){const{contentEl:e}=this;e.empty()}}class CH extends k.Modal{constructor(e,t,r){super(e),this.plugin=t,this.newRemotePrefix=r}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("modal_remoteprefix_s3_title")}),t("modal_remoteprefix_s3_shortdesc").split("\n").forEach(((t,r)=>{e.createEl("p",{text:t})})),e.createEl("p",{text:t("modal_remoteprefix_s3_tosave",{prefix:this.newRemotePrefix})}),""===this.newRemotePrefix||this.newRemotePrefix===this.app.vault.getName()?new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_remoteprefix_s3_secondconfirm_empty")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.remotePrefix="",yield this.plugin.saveSettings(),new k.Notice(t("modal_remoteprefix_s3_notice")),this.close()})))),e.setClass("remoteprefix-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))})):new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_remoteprefix_s3_secondconfirm_change")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.remotePrefix=this.newRemotePrefix,yield this.plugin.saveSettings(),new k.Notice(t("modal_remoteprefix_s3_notice")),this.close()})))),e.setClass("remoteprefix-s3-second-confirm")})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))}onClose(){const{contentEl:e}=this;e.empty()}}class IH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);let i=!1;const n=window.navigator.userAgent.toLocaleLowerCase()||"";k.Platform.isDesktopApp&&!k.Platform.isMacOS&&(/linux/.test(n)||/ubuntu/.test(n)||/debian/.test(n)||/fedora/.test(n)||/centos/.test(n))&&(i=!0);const{authUrl:o,verifier:s}=yield((e,...t)=>r(void 0,[e,...t],void 0,(function*(e,t=!1){const r=new hx.DropboxAuth({clientId:e}),i=t?void 0:`obsidian://${M}`;return{authUrl:(yield r.getAuthenticationUrl(i,void 0,"code","offline",void 0,"none",!0)).toString(),verifier:r.getCodeVerifier()}})))(this.plugin.settings.dropbox.clientID,i);i?t("modal_dropboxauth_manualsteps").split("\n").forEach((t=>{e.createEl("p",{text:t})})):(this.plugin.oauth2Info.verifier=s,t("modal_dropboxauth_autosteps").split("\n").forEach((t=>{e.createEl("p",{text:t})})));if(e.createDiv().createEl("button",{text:t("modal_dropboxauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(o),new k.Notice(t("modal_dropboxauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:o,text:o}),i){let i="";new k.Setting(e).setName(t("modal_dropboxauth_maualinput")).setDesc(t("modal_dropboxauth_maualinput_desc")).addText((e=>e.setPlaceholder("").setValue("").onChange((e=>{i=e.trim()})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(t("submit")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(t("modal_dropboxauth_maualinput_notice"));try{const e=yield wx(this.plugin.settings.dropbox.clientID,s,i,(e=>r(this,void 0,void 0,(function*(){throw new k.Notice(t("protocol_dropbox_connect_fail")),new k.Notice(`${e}`),e})))),n=this;_x(this.plugin.settings.dropbox,e,(()=>n.plugin.saveSettings()));const o=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),a=yield o.getUserDisplayName();this.plugin.settings.dropbox.username=a,yield this.plugin.saveSettings(),new k.Notice(t("modal_dropboxauth_maualinput_conn_succ",{username:a})),this.authDiv.toggleClass("dropbox-auth-button-hide",""!==this.plugin.settings.dropbox.username),this.revokeAuthDiv.toggleClass("dropbox-revoke-auth-button-hide",""===this.plugin.settings.dropbox.username),this.revokeAuthSetting.setDesc(t("modal_dropboxauth_maualinput_conn_succ_revoke",{username:this.plugin.settings.dropbox.username})),this.close()}catch(e){console.error(e),new k.Notice(t("modal_dropboxauth_maualinput_conn_fail"))}}))))}))))}}))}onClose(){const{contentEl:e}=this;e.empty()}}class AH extends k.Modal{constructor(e,t,r,i,n){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i,this.revokeAuthSetting=n}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,{authUrl:t,verifier:i}=yield function(e,t){return r(this,void 0,void 0,(function*(){const r=new Aw,{verifier:i,challenge:n}=yield r.generatePkceCodes(),o={challengeMethod:"S256",verifier:i,challenge:n},s={redirectUri:Nx,scopes:zx,codeChallenge:o.challenge,codeChallengeMethod:o.challengeMethod},a=new Vw({auth:{clientId:e,authority:t}});return{authUrl:yield a.getAuthCodeUrl(s),verifier:i}}))}(this.plugin.settings.onedrive.clientID,this.plugin.settings.onedrive.authority);this.plugin.oauth2Info.verifier=i;const n=(e,t)=>this.plugin.i18n.t(e,t);n("modal_onedriveauth_shortdesc").split("\n").forEach((t=>{e.createEl("p",{text:t})})),k.Platform.isLinux&&n("modal_onedriveauth_shortdesc_linux").split("\n").forEach((t=>{e.createEl("p",{text:Qp(t)})}));e.createDiv().createEl("button",{text:n("modal_onedriveauth_copybutton")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(t),new k.Notice(n("modal_onedriveauth_copynotice"))}))})),e.createEl("p").createEl("a",{href:t,text:t})}))}onClose(){const{contentEl:e}=this;e.empty()}}class FH extends k.Modal{constructor(e,t,r,i){super(e),this.plugin=t,this.authDiv=r,this.revokeAuthDiv=i}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("p",{text:t("modal_onedriverevokeauth_step1")});const i="https://microsoft.com/consent";e.createEl("p").createEl("a",{href:i,text:i}),e.createEl("p",{text:t("modal_onedriverevokeauth_step2")}),new k.Setting(e).setName(t("modal_onedriverevokeauth_clean")).setDesc(t("modal_onedriverevokeauth_clean_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(t("modal_onedriverevokeauth_clean_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){try{this.plugin.settings.onedrive=JSON.parse(JSON.stringify(qx)),yield this.plugin.saveSettings(),this.authDiv.toggleClass("onedrive-auth-button-hide",""!==this.plugin.settings.onedrive.username),this.revokeAuthDiv.toggleClass("onedrive-revoke-auth-button-hide",""===this.plugin.settings.onedrive.username),new k.Notice(t("modal_onedriverevokeauth_clean_notice")),this.close()}catch(e){console.error(e),new k.Notice(t("modal_onedriverevokeauth_clean_fail"))}}))))}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}class MH extends k.Modal{constructor(e,t,r){super(e),this.plugin=t,this.saveDropdownFunc=r}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);t("modal_syncconfig_attn").split("\n").forEach((t=>{e.createEl("p",{text:t})})),new k.Setting(e).addButton((e=>{e.setButtonText(t("modal_syncconfig_secondconfirm")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.syncConfigDir=!0,yield this.plugin.saveSettings(),this.saveDropdownFunc(),new k.Notice(t("modal_syncconfig_notice")),this.close()}))))})).addButton((e=>{e.setButtonText(t("goback")),e.onClick((()=>{this.close()}))}))}))}onClose(){const{contentEl:e}=this;e.empty()}}class DH extends k.Modal{constructor(e,t,r){super(e),this.plugin=t,this.exportType=r}onOpen(){return r(this,void 0,void 0,(function*(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t),{rawUri:i,imgUri:n}=yield(o=this.plugin.settings,s=this.app.vault.getName(),a=this.plugin.manifest.version,l=this.exportType,r(void 0,void 0,void 0,(function*(){let e={};"basic_and_advanced"===l?(e=m()(o),delete e.s3,delete e.dropbox,delete e.onedrive,delete e.onedrivefull,delete e.webdav,delete e.webdis,delete e.googledrive,delete e.box,delete e.pcloud,delete e.yandexdisk,delete e.koofr,delete e.azureblobstorage,delete e.pro):"s3"===l?e={s3:m()(o.s3)}:"dropbox"===l?e={dropbox:m()(o.dropbox)}:"onedrive"===l?e={onedrive:$x(o.onedrive)}:"onedrivefull"===l?e={onedrivefull:l_(o.onedrivefull)}:"webdav"===l?e={webdav:m()(o.webdav)}:"webdis"===l?e={webdis:m()(o.webdis)}:"googledrive"===l?e={googledrive:m()(o.googledrive)}:"box"===l?e={box:m()(o.box)}:"pcloud"===l?e={pcloud:m()(o.pcloud)}:"yandexdisk"===l?e={yandexdisk:m()(o.yandexdisk)}:"koofr"===l?e={koofr:m()(o.koofr)}:"azureblobstorage"===l&&(e={azureblobstorage:m()(o.azureblobstorage)}),delete e.vaultRandomID;const t=encodeURIComponent(JSON.stringify(e)),r=encodeURIComponent(s),i=encodeURIComponent(a),n=`obsidian://${A}?func=settings&version=${i}&vault=${r}&data=${t}`;return{rawUri:n,imgUri:yield tH.toDataURL(n)}})));var o,s,a,l;const d=e.createDiv();t("modal_qr_shortdesc").split("\n").forEach((e=>{d.createEl("p",{text:e})}));e.createDiv().createEl("button",{text:t("modal_qr_button")},(e=>{e.onclick=()=>r(this,void 0,void 0,(function*(){yield navigator.clipboard.writeText(i),new k.Notice(t("modal_qr_button_notice"))}))}));e.createDiv().createEl("img",{cls:"qrcode-img"},(e=>r(this,void 0,void 0,(function*(){e.src=n}))))}))}onClose(){const{contentEl:e}=this;e.empty()}}const RH=e=>{const{eye:t,eyeOff:r}=(()=>{const e=b(oH),t=b(sH);return{eye:e.outerHTML,eyeOff:t.outerHTML}})(),i=e.inputEl.insertAdjacentElement("afterend",createSpan());return i.innerHTML=r,i.addEventListener("click",(n=>{const o="text"===e.inputEl.getAttribute("type");i.innerHTML=o?r:t,e.inputEl.setAttribute("type",o?"password":"text"),e.inputEl.focus()})),e.inputEl.setAttribute("type","password"),e};class PH extends k.PluginSettingTab{constructor(e,t){super(e,t),this.plugin=t}display(){var e,t;const{containerEl:i}=this;i.style.setProperty("overflow-wrap","break-word"),i.empty();const n=(e,t)=>this.plugin.i18n.t(e,t);i.createEl("h1",{text:"Remotely Save"});const o=i.createDiv();o.createEl("h2",{text:n("settings_chooseservice")});const s=i.createEl("div",{cls:"s3-hide"});s.toggleClass("s3-hide","s3"!==this.plugin.settings.serviceType),s.createEl("h2",{text:n("settings_s3")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[n("settings_s3_disclaimer1"),n("settings_s3_disclaimer2")])a.createEl("p",{text:e,cls:"s3-disclaimer"});t_||a.createEl("p",{text:n("settings_s3_cors")}),a.createEl("p",{text:n("settings_s3_prod")});const l=a.createEl("ul");l.createEl("li").createEl("a",{href:"https://docs.aws.amazon.com/general/latest/gr/s3.html",text:n("settings_s3_prod1")}),l.createEl("li").createEl("a",{href:"https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/getting-your-credentials.html",text:n("settings_s3_prod2")}),t_||l.createEl("li").createEl("a",{href:"https://docs.aws.amazon.com/AmazonS3/latest/userguide/enabling-cors-examples.html",text:n("settings_s3_prod3")}),new k.Setting(s).setName(n("settings_s3_endpoint")).setDesc(n("settings_s3_endpoint")).addText((e=>e.setPlaceholder("").setValue(this.plugin.settings.s3.s3Endpoint).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.s3Endpoint=e.trim(),yield this.plugin.saveSettings()})))))),new k.Setting(s).setName(n("settings_s3_region")).setDesc(n("settings_s3_region_desc")).addText((e=>e.setPlaceholder("").setValue(`${this.plugin.settings.s3.s3Region}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.s3Region=e.trim(),yield this.plugin.saveSettings()})))))),new k.Setting(s).setName(n("settings_s3_accesskeyid")).setDesc(n("settings_s3_accesskeyid_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(`${this.plugin.settings.s3.s3AccessKeyID}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.s3AccessKeyID=e.trim(),yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_s3_secretaccesskey")).setDesc(n("settings_s3_secretaccesskey_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(`${this.plugin.settings.s3.s3SecretAccessKey}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.s3SecretAccessKey=e.trim(),yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_s3_bucketname")).setDesc(n("settings_s3_bucketname")).addText((e=>e.setPlaceholder("").setValue(`${this.plugin.settings.s3.s3BucketName}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.s3BucketName=e.trim(),yield this.plugin.saveSettings()})))))),new k.Setting(s).setName(n("settings_s3_urlstyle")).setDesc(n("settings_s3_urlstyle_desc")).addDropdown((e=>{e.addOption("virtualHostedStyle","Virtual Hosted-Style (default)"),e.addOption("pathStyle","Path-Style"),e.setValue(this.plugin.settings.s3.forcePathStyle?"pathStyle":"virtualHostedStyle").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.forcePathStyle="pathStyle"===e,yield this.plugin.saveSettings()}))))})),t_&&!(0,k.requireApiVersion)(e_)&&new k.Setting(s).setName(n("settings_s3_bypasscorslocally")).setDesc(n("settings_s3_bypasscorslocally_desc")).addDropdown((e=>{e.addOption("disable",n("disable")).addOption("enable",n("enable")),e.setValue(""+(this.plugin.settings.s3.bypassCorsLocally?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.bypassCorsLocally="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_s3_parts")).setDesc(n("settings_s3_parts_desc")).addDropdown((e=>{e.addOption("1","1"),e.addOption("2","2"),e.addOption("3","3"),e.addOption("5","5"),e.addOption("10","10"),e.addOption("15","15"),e.addOption("20","20 (default)"),e.setValue(`${this.plugin.settings.s3.partsConcurrency}`).onChange((e=>r(this,void 0,void 0,(function*(){const t=Number.parseInt(e);this.plugin.settings.s3.partsConcurrency=t,yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_s3_accuratemtime")).setDesc(n("settings_s3_accuratemtime_desc")).addDropdown((e=>{e.addOption("disable",n("disable")).addOption("enable",n("enable")),e.setValue(""+(this.plugin.settings.s3.useAccurateMTime?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.useAccurateMTime="enable"===e,yield this.plugin.saveSettings()}))))}));let d=this.plugin.settings.s3.remotePrefix||"";new k.Setting(s).setName(n("settings_remoteprefix_s3")).setDesc(n("settings_remoteprefix_s3_desc")).addText((e=>e.setPlaceholder("").setValue(d).onChange((e=>{d=XN(e.trim())})))).addButton((e=>{e.setButtonText(n("confirm")),e.onClick((()=>{new CH(this.app,this.plugin,XN(d.trim())).open()}))})),new k.Setting(s).setName(n("settings_s3_reverse_proxy_no_sign_url")).setDesc(n("settings_s3_reverse_proxy_no_sign_url_desc")).addText((e=>{var t;return e.setPlaceholder("").setValue(null!==(t=this.plugin.settings.s3.reverseProxyNoSignUrl)&&void 0!==t?t:"").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.reverseProxyNoSignUrl=e.trim(),yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_s3_generatefolderobject")).setDesc(n("settings_s3_generatefolderobject_desc")).addDropdown((e=>{e.addOption("notgenerate",n("settings_s3_generatefolderobject_notgenerate")).addOption("generate",n("settings_s3_generatefolderobject_generate")),e.setValue(""+(this.plugin.settings.s3.generateFolderObject?"generate":"notgenerate")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.s3.generateFolderObject="generate"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(s).setName(n("settings_checkonnectivity")).setDesc(n("settings_checkonnectivity_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_checkonnectivity_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(n("settings_checkonnectivity_checking"));const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),t={msg:""};(yield e.checkConnect((e=>{t.msg=e})))?new k.Notice(n("settings_s3_connect_succ")):(new k.Notice(n("settings_s3_connect_fail")),new k.Notice(t.msg))}))))}))));const c=i.createEl("div",{cls:"dropbox-hide"});c.toggleClass("dropbox-hide","dropbox"!==this.plugin.settings.serviceType),c.createEl("h2",{text:n("settings_dropbox")});const u=c.createEl("div",{cls:"settings-long-desc"});for(const e of[n("settings_dropbox_disclaimer1"),n("settings_dropbox_disclaimer2")])u.createEl("p",{text:e,cls:"dropbox-disclaimer"});u.createEl("p",{text:n("settings_dropbox_folder",{pluginID:this.plugin.manifest.id,remoteBaseDir:this.plugin.settings.dropbox.remoteBaseDir||this.app.vault.getName()})});const p=c.createDiv(),h=p.createDiv({cls:"dropbox-auth-button-hide settings-auth-related"}),f=p.createDiv({cls:"dropbox-revoke-auth-button-hide settings-auth-related"}),g=new k.Setting(f).setName(n("settings_dropbox_revoke")).setDesc(n("settings_dropbox_revoke_desc",{username:this.plugin.settings.dropbox.username})).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_dropbox_revoke_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){try{const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings()));yield e.revokeAuth(),this.plugin.settings.dropbox=JSON.parse(JSON.stringify(gx)),yield this.plugin.saveSettings(),h.toggleClass("dropbox-auth-button-hide",""!==this.plugin.settings.dropbox.username),f.toggleClass("dropbox-revoke-auth-button-hide",""===this.plugin.settings.dropbox.username),new k.Notice(n("settings_dropbox_revoke_notice"))}catch(e){console.error(e),new k.Notice(n("settings_dropbox_revoke_noticeerr"))}}))))}))));new k.Setting(f).setName(n("settings_dropbox_clearlocal")).setDesc(n("settings_dropbox_clearlocal_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_dropbox_clearlocal_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){this.plugin.settings.dropbox=JSON.parse(JSON.stringify(gx)),yield this.plugin.saveSettings(),h.toggleClass("dropbox-auth-button-hide",""!==this.plugin.settings.dropbox.username),f.toggleClass("dropbox-revoke-auth-button-hide",""===this.plugin.settings.dropbox.username),new k.Notice(n("settings_dropbox_clearlocal_notice"))}))))})))),new k.Setting(h).setName(n("settings_dropbox_auth")).setDesc(n("settings_dropbox_auth_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_dropbox_auth_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){const e=new IH(this.app,this.plugin,h,f,g);this.plugin.oauth2Info.helperModal=e,this.plugin.oauth2Info.authDiv=h,this.plugin.oauth2Info.revokeDiv=f,this.plugin.oauth2Info.revokeAuthSetting=g,e.open()}))))})))),h.toggleClass("dropbox-auth-button-hide",""!==this.plugin.settings.dropbox.username),f.toggleClass("dropbox-revoke-auth-button-hide",""===this.plugin.settings.dropbox.username);let y=this.plugin.settings.dropbox.remoteBaseDir||"";new k.Setting(c).setName(n("settings_remotebasedir")).setDesc(n("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(this.app.vault.getName()).setValue(y).onChange((e=>{y=e.trim()})))).addButton((e=>{e.setButtonText(n("confirm")),e.onClick((()=>{new BH(this.app,this.plugin,y,"dropbox").open()}))})),new k.Setting(c).setName(n("settings_checkonnectivity")).setDesc(n("settings_checkonnectivity_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_checkonnectivity_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(n("settings_checkonnectivity_checking"));const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),t={msg:""};(yield e.checkConnect((e=>{t.msg=`${e}`})))?new k.Notice(n("settings_dropbox_connect_succ")):(new k.Notice(n("settings_dropbox_connect_fail")),new k.Notice(t.msg))}))))}))));const v=i.createEl("div",{cls:"onedrive-hide"});v.toggleClass("onedrive-hide","onedrive"!==this.plugin.settings.serviceType),v.createEl("h2",{text:n("settings_onedrive")});const b=v.createEl("div",{cls:"settings-long-desc"});for(const e of[n("settings_onedrive_disclaimer1"),n("settings_onedrive_disclaimer2")])b.createEl("p",{text:e,cls:"onedrive-disclaimer"});b.createEl("p",{text:n("settings_onedrive_folder",{pluginID:this.plugin.manifest.id,remoteBaseDir:this.plugin.settings.onedrive.remoteBaseDir||this.app.vault.getName()})}),b.createEl("p",{text:n("settings_onedrive_nobiz")});const w=v.createDiv(),_=w.createDiv({cls:"onedrive-auth-button-hide settings-auth-related"}),x=w.createDiv({cls:"onedrive-revoke-auth-button-hide settings-auth-related"}),S=new k.Setting(x).setName(n("settings_onedrive_revoke")).setDesc(n("settings_onedrive_revoke_desc",{username:this.plugin.settings.onedrive.username})).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_onedrive_revoke_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new FH(this.app,this.plugin,_,x).open()}))))}))));new k.Setting(_).setName(n("settings_onedrive_auth")).setDesc(n("settings_onedrive_auth_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_onedrive_auth_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){const e=new AH(this.app,this.plugin,_,x,S);this.plugin.oauth2Info.helperModal=e,this.plugin.oauth2Info.authDiv=_,this.plugin.oauth2Info.revokeDiv=x,this.plugin.oauth2Info.revokeAuthSetting=S,e.open()}))))})))),_.toggleClass("onedrive-auth-button-hide",""!==this.plugin.settings.onedrive.username),x.toggleClass("onedrive-revoke-auth-button-hide",""===this.plugin.settings.onedrive.username);let E=this.plugin.settings.onedrive.remoteBaseDir||"";new k.Setting(v).setName(n("settings_remotebasedir")).setDesc(n("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(this.app.vault.getName()).setValue(E).onChange((e=>{E=e.trim()})))).addButton((e=>{e.setButtonText(n("confirm")),e.onClick((()=>{new BH(this.app,this.plugin,E,"onedrive").open()}))})),new k.Setting(v).setName(n("settings_onedrive_emptyfile")).setDesc(n("settings_onedrive_emptyfile_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){e.addOption("skip",n("settings_onedrive_emptyfile_skip")).addOption("error",n("settings_onedrive_emptyfile_error")).setValue(this.plugin.settings.onedrive.emptyFile).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.onedrive.emptyFile=e,yield this.plugin.saveSettings()}))))})))),new k.Setting(v).setName(n("settings_checkonnectivity")).setDesc(n("settings_checkonnectivity_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_checkonnectivity_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(n("settings_checkonnectivity_checking"));const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),t={msg:""};(yield e.checkConnect((e=>{t.msg=`${e}`})))?new k.Notice(n("settings_onedrive_connect_succ")):(new k.Notice(n("settings_onedrive_connect_fail")),new k.Notice(t.msg))}))))}))));const T=i.createEl("div",{cls:"webdav-hide"});T.toggleClass("webdav-hide","webdav"!==this.plugin.settings.serviceType),T.createEl("h2",{text:n("settings_webdav")});const B=T.createEl("div",{cls:"settings-long-desc"});B.createEl("p",{text:n("settings_webdav_disclaimer1"),cls:"webdav-disclaimer"}),t_||(B.createEl("p",{text:n("settings_webdav_cors_os")}),B.createEl("p",{text:n("settings_webdav_cors")})),B.createEl("p",{text:n("settings_webdav_folder",{remoteBaseDir:this.plugin.settings.webdav.remoteBaseDir||this.app.vault.getName()})}),new k.Setting(T).setName(n("settings_webdav_addr")).setDesc(n("settings_webdav_addr_desc")).addText((e=>e.setPlaceholder("").setValue(this.plugin.settings.webdav.address).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdav.address=e.trim(),"auto"!==this.plugin.settings.webdav.depth&&"auto_1"!==this.plugin.settings.webdav.depth&&"auto_infinity"!==this.plugin.settings.webdav.depth&&"auto_unknown"!==this.plugin.settings.webdav.depth||(this.plugin.settings.webdav.depth="manual_1"),yield this.plugin.saveSettings()})))))),new k.Setting(T).setName(n("settings_webdav_user")).setDesc(n("settings_webdav_user_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(this.plugin.settings.webdav.username).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdav.username=e.trim(),"auto"!==this.plugin.settings.webdav.depth&&"auto_1"!==this.plugin.settings.webdav.depth&&"auto_infinity"!==this.plugin.settings.webdav.depth&&"auto_unknown"!==this.plugin.settings.webdav.depth||(this.plugin.settings.webdav.depth="manual_1"),yield this.plugin.saveSettings()}))))})),new k.Setting(T).setName(n("settings_webdav_password")).setDesc(n("settings_webdav_password_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(this.plugin.settings.webdav.password).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdav.password=e.trim(),"auto"!==this.plugin.settings.webdav.depth&&"auto_1"!==this.plugin.settings.webdav.depth&&"auto_infinity"!==this.plugin.settings.webdav.depth&&"auto_unknown"!==this.plugin.settings.webdav.depth||(this.plugin.settings.webdav.depth="manual_1"),yield this.plugin.saveSettings()}))))})),new k.Setting(T).setName(n("settings_webdav_auth")).setDesc(n("settings_webdav_auth_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){e.addOption("basic","basic"),t_&&e.addOption("digest","digest"),t_||"basic"===this.plugin.settings.webdav.authType||(this.plugin.settings.webdav.authType="basic",yield this.plugin.saveSettings()),e.setValue(this.plugin.settings.webdav.authType).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdav.authType=e,yield this.plugin.saveSettings()}))))})))),new k.Setting(T).setName(n("settings_webdav_depth")).setDesc(n("settings_webdav_depth_desc")).addDropdown((e=>{e.addOption("manual_1",n("settings_webdav_depth_1")),e.addOption("manual_infinity",n("settings_webdav_depth_inf")),e.setValue(this.plugin.settings.webdav.depth||"manual_1").onChange((e=>r(this,void 0,void 0,(function*(){"manual_1"===e?(this.plugin.settings.webdav.depth="manual_1",this.plugin.settings.webdav.manualRecursive=!0):"manual_infinity"===e&&(this.plugin.settings.webdav.depth="manual_infinity",this.plugin.settings.webdav.manualRecursive=!1),yield this.plugin.saveSettings()}))))})),new k.Setting(T).setName(n("settings_webdav_customheaders")).setDesc(Qp(n("settings_webdav_customheaders_desc"))).addTextArea((e=>{var t;e.setPlaceholder("X-Header1: Value1\nX-Header2: Value2").setValue(`${null!==(t=this.plugin.settings.webdav.customHeaders)&&void 0!==t?t:""}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdav.customHeaders=e.trim().split("\n").filter((e=>""!==e.trim())).join("\n"),yield this.plugin.saveSettings()})))),e.inputEl.rows=10,e.inputEl.cols=30,e.inputEl.addClass("webdav-customheaders-textarea")}));let C=this.plugin.settings.webdav.remoteBaseDir||"";new k.Setting(T).setName(n("settings_remotebasedir")).setDesc(n("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(this.app.vault.getName()).setValue(C).onChange((e=>{C=e.trim()})))).addButton((e=>{e.setButtonText(n("confirm")),e.onClick((()=>{new BH(this.app,this.plugin,C,"webdav").open()}))})),new k.Setting(T).setName(n("settings_checkonnectivity")).setDesc(n("settings_checkonnectivity_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_checkonnectivity_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(n("settings_checkonnectivity_checking"));const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),t={msg:""};(yield e.checkConnect((e=>{t.msg=`${e}`})))?new k.Notice(n("settings_webdav_connect_succ")):(t_?new k.Notice(n("settings_webdav_connect_fail")):new k.Notice(n("settings_webdav_connect_fail_withcors")),new k.Notice(t.msg))}))))}))));const I=i.createEl("div",{cls:"webdis-hide"});I.toggleClass("webdis-hide","webdis"!==this.plugin.settings.serviceType),I.createEl("h2",{text:n("settings_webdis")});const A=I.createEl("div",{cls:"settings-long-desc"});for(const e of[n("settings_webdis_disclaimer1"),n("settings_webdis_disclaimer2")])A.createEl("p",{text:e,cls:"webdis-disclaimer"});A.createEl("p",{text:n("settings_webdis_folder",{remoteBaseDir:this.plugin.settings.webdis.remoteBaseDir||this.app.vault.getName()})}),new k.Setting(I).setName(n("settings_webdis_addr")).setDesc(n("settings_webdis_addr_desc")).addText((e=>e.setPlaceholder("https://").setValue(this.plugin.settings.webdis.address).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdis.address=e.trim(),yield this.plugin.saveSettings()})))))),new k.Setting(I).setName(n("settings_webdis_user")).setDesc(n("settings_webdis_user_desc")).addText((e=>{var t;RH(e),e.setPlaceholder("").setValue(null!==(t=this.plugin.settings.webdis.username)&&void 0!==t?t:"").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdis.username=(null!=e?e:"").trim(),yield this.plugin.saveSettings()}))))})),new k.Setting(I).setName(n("settings_webdis_password")).setDesc(n("settings_webdis_password_desc")).addText((e=>{var t;RH(e),e.setPlaceholder("").setValue(null!==(t=this.plugin.settings.webdis.password)&&void 0!==t?t:"").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.webdis.password=(null!=e?e:"").trim(),yield this.plugin.saveSettings()}))))}));let F=this.plugin.settings.webdis.remoteBaseDir||"";new k.Setting(I).setName(n("settings_remotebasedir")).setDesc(n("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(this.app.vault.getName()).setValue(F).onChange((e=>{F=e.trim()})))).addButton((e=>{e.setButtonText(n("confirm")),e.onClick((()=>{new BH(this.app,this.plugin,F,"webdis").open()}))})),new k.Setting(I).setName(n("settings_checkonnectivity")).setDesc(n("settings_checkonnectivity_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_checkonnectivity_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(n("settings_checkonnectivity_checking"));const e=Ej(this.plugin.settings,this.app.vault.getName(),(()=>this.plugin.saveSettings())),t={msg:""};(yield e.checkConnect((e=>{t.msg=`${e}`})))?new k.Notice(n("settings_webdis_connect_succ")):(new k.Notice(n("settings_webdis_connect_fail")),new k.Notice(t.msg))}))))}))));const{onedriveFullDiv:M,onedriveFullAllowedToUsedDiv:D,onedriveFullNotShowUpHintSetting:R}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"onedrivefull-hide"});s.toggleClass("onedrivefull-hide","onedrivefull"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_onedrivefull")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_onedrivefull_disclaimer1"),t("settings_onedrivefull_disclaimer2")])a.createEl("p",{text:e,cls:"onedrivefull-disclaimer"});a.createEl("p",{text:t("settings_onedrivefull_folder",{remoteBaseDir:n.settings.onedrivefull.remoteBaseDir||i.vault.getName()})}),a.createEl("p",{text:t("settings_onedrivefull_nobiz")}),a.createDiv({text:Qp(t("settings_onedrivefull_pro_desc")),cls:"onedrivefull-disclaimer"});const l=new k.Setting(s).setName(t("settings_onedrivefull_notshowuphint")).setDesc(t("settings_onedrivefull_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_onedrivefull_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-onedrive_full"===e.featureName)).length);console.debug(`allow to show up onedriveFull settings? ${c}`),c?(d.removeClass("onedrivefull-allow-to-use-hide"),l.settingEl.addClass("onedrivefull-allow-to-use-hide")):(d.addClass("onedrivefull-allow-to-use-hide"),l.settingEl.removeClass("onedrivefull-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"onedrivefull-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"onedrivefull-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_onedrivefull_revoke")).setDesc(t("settings_onedrivefull_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_onedrivefull_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new yH(i,n,p,h).open()}))))}))));new k.Setting(p).setName(t("settings_onedrivefull_auth")).setDesc(t("settings_onedrivefull_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_onedrivefull_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new gH(i,n,p,h,f);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("onedrivefull-auth-button-hide",""!==n.settings.onedrivefull.refreshToken),h.toggleClass("onedrivefull-revoke-auth-button-hide",""===n.settings.onedrivefull.refreshToken);let m=n.settings.onedrivefull.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"onedrivefull").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_onedrivefull_connect_succ")):(new k.Notice(t("settings_onedrivefull_connect_fail")),new k.Notice(r.msg))}))))})))),{onedriveFullDiv:s,onedriveFullAllowedToUsedDiv:d,onedriveFullNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{googleDriveDiv:P,googleDriveAllowedToUsedDiv:O,googleDriveNotShowUpHintSetting:z}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"googledrive-hide"});s.toggleClass("googledrive-hide","googledrive"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_googledrive")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_googledrive_disclaimer1"),t("settings_googledrive_disclaimer2")])a.createEl("p",{text:e,cls:"googledrive-disclaimer"});a.createEl("p",{text:t("settings_googledrive_folder",{remoteBaseDir:n.settings.googledrive.remoteBaseDir||i.vault.getName()})}),a.createDiv({text:Qp(t("settings_googledrive_pro_desc")),cls:"googledrive-disclaimer"});const l=new k.Setting(s).setName(t("settings_googledrive_notshowuphint")).setDesc(t("settings_googledrive_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_googledrive_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-google_drive"===e.featureName)).length);console.debug(`allow to show up google drive settings? ${c}`),c?(d.removeClass("googledrive-allow-to-use-hide"),l.settingEl.addClass("googledrive-allow-to-use-hide")):(d.addClass("googledrive-allow-to-use-hide"),l.settingEl.removeClass("googledrive-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"googledrive-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"googledrive-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_googledrive_revoke")).setDesc(t("settings_googledrive_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_googledrive_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new hH(i,n,p,h,t).open()}))))}))));new k.Setting(p).setName(t("settings_googledrive_auth")).setDesc(t("settings_googledrive_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_googledrive_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new pH(i,n,p,h,f,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("googledrive-auth-button-hide",""!==n.settings.googledrive.refreshToken),h.toggleClass("googledrive-revoke-auth-button-hide",""===n.settings.googledrive.refreshToken);let m=n.settings.googledrive.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"googledrive").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_googledrive_connect_succ")):(new k.Notice(t("settings_googledrive_connect_fail")),new k.Notice(r.msg))}))))})))),{googleDriveDiv:s,googleDriveAllowedToUsedDiv:d,googleDriveNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{boxDiv:N,boxAllowedToUsedDiv:q,boxNotShowUpHintSetting:U}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"box-hide"});s.toggleClass("box-hide","box"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_box")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_box_disclaimer1"),t("settings_box_disclaimer2")])a.createEl("p",{text:e,cls:"box-disclaimer"});a.createEl("p",{text:t("settings_box_folder",{remoteBaseDir:n.settings.box.remoteBaseDir||i.vault.getName()})}),a.createDiv({text:Qp(t("settings_box_pro_desc")),cls:"box-disclaimer"});const l=new k.Setting(s).setName(t("settings_box_notshowuphint")).setDesc(t("settings_box_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_box_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-box"===e.featureName)).length);console.debug(`allow to show up box settings? ${c}`),c?(d.removeClass("box-allow-to-use-hide"),l.settingEl.addClass("box-allow-to-use-hide")):(d.addClass("box-allow-to-use-hide"),l.settingEl.removeClass("box-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"box-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"box-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_box_revoke")).setDesc(t("settings_box_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_box_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new dH(i,n,p,h,t).open()}))))}))));new k.Setting(p).setName(t("settings_box_auth")).setDesc(t("settings_box_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_box_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new lH(i,n,p,h,f,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("box-auth-button-hide",""!==n.settings.box.refreshToken),h.toggleClass("box-revoke-auth-button-hide",""===n.settings.box.refreshToken);let m=n.settings.box.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"box").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_box_connect_succ")):(new k.Notice(t("settings_box_connect_fail")),new k.Notice(r.msg))}))))})))),{boxDiv:s,boxAllowedToUsedDiv:d,boxNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{pCloudDiv:L,pCloudAllowedToUsedDiv:j,pCloudNotShowUpHintSetting:H}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"pcloud-hide"});s.toggleClass("pcloud-hide","pcloud"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_pcloud")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_pcloud_disclaimer1"),t("settings_pcloud_disclaimer2")])a.createEl("p",{text:e,cls:"pcloud-disclaimer"});a.createEl("p",{text:t("settings_pcloud_folder",{remoteBaseDir:n.settings.pcloud.remoteBaseDir||i.vault.getName()})}),a.createDiv({text:Qp(t("settings_pcloud_pro_desc")),cls:"pcloud-disclaimer"});const l=new k.Setting(s).setName(t("settings_pcloud_notshowuphint")).setDesc(t("settings_pcloud_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pcloud_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-pcloud"===e.featureName)).length);console.debug(`allow to show up pcloud settings? ${c}`),c?(d.removeClass("pcloud-allow-to-use-hide"),l.settingEl.addClass("pcloud-allow-to-use-hide")):(d.addClass("pcloud-allow-to-use-hide"),l.settingEl.removeClass("pcloud-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"pcloud-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"pcloud-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_pcloud_revoke")).setDesc(t("settings_pcloud_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pcloud_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new bH(i,n,p,h,t).open()}))))}))));new k.Setting(p).setName(t("settings_pcloud_auth")).setDesc(t("settings_pcloud_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pcloud_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new vH(i,n,p,h,f,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("pcloud-auth-button-hide",""!==n.settings.pcloud.accessToken),h.toggleClass("pcloud-revoke-auth-button-hide",""===n.settings.pcloud.accessToken);let m=n.settings.pcloud.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"pcloud").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_pcloud_connect_succ")):(new k.Notice(t("settings_pcloud_connect_fail")),new k.Notice(r.msg))}))))})))),{pCloudDiv:s,pCloudAllowedToUsedDiv:d,pCloudNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{yandexDiskDiv:$,yandexDiskAllowedToUsedDiv:G,yandexDiskNotShowUpHintSetting:W}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"yandexdisk-hide"});s.toggleClass("yandexdisk-hide","yandexdisk"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_yandexdisk")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_yandexdisk_disclaimer1"),t("settings_yandexdisk_disclaimer2")])a.createEl("p",{text:e,cls:"yandexdisk-disclaimer"});a.createEl("p",{text:t("settings_yandexdisk_folder",{remoteBaseDir:n.settings.yandexdisk.remoteBaseDir||i.vault.getName()})}),a.createDiv({text:Qp(t("settings_yandexdisk_pro_desc")),cls:"yandexdisk-disclaimer"});const l=new k.Setting(s).setName(t("settings_yandexdisk_notshowuphint")).setDesc(t("settings_yandexdisk_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_yandexdisk_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-yandex_disk"===e.featureName)).length);console.debug(`allow to show up yandexDisk settings? ${c}`),c?(d.removeClass("yandexdisk-allow-to-use-hide"),l.settingEl.addClass("yandexdisk-allow-to-use-hide")):(d.addClass("yandexdisk-allow-to-use-hide"),l.settingEl.removeClass("yandexdisk-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"yandexdisk-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"yandexdisk-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_yandexdisk_revoke")).setDesc(t("settings_yandexdisk_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_yandexdisk_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new kH(i,n,p,h,t).open()}))))}))));new k.Setting(p).setName(t("settings_yandexdisk_auth")).setDesc(t("settings_yandexdisk_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_yandexdisk_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new SH(i,n,p,h,f,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("yandexdisk-auth-button-hide",""!==n.settings.yandexdisk.refreshToken),h.toggleClass("yandexdisk-revoke-auth-button-hide",""===n.settings.yandexdisk.refreshToken);let m=n.settings.yandexdisk.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"yandexdisk").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_yandexdisk_connect_succ")):(new k.Notice(t("settings_yandexdisk_connect_fail")),new k.Notice(r.msg))}))))})))),{yandexDiskDiv:s,yandexDiskAllowedToUsedDiv:d,yandexDiskNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{koofrDiv:K,koofrAllowedToUsedDiv:V,koofrNotShowUpHintSetting:J}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"koofr-hide"});s.toggleClass("koofr-hide","koofr"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_koofr")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_koofr_disclaimer1"),t("settings_koofr_disclaimer2")])a.createEl("p",{text:e,cls:"koofr-disclaimer"});a.createEl("p",{text:t("settings_koofr_folder",{remoteBaseDir:n.settings.koofr.remoteBaseDir||i.vault.getName()})}),a.createDiv({text:Qp(t("settings_koofr_pro_desc")),cls:"koofr-disclaimer"});const l=new k.Setting(s).setName(t("settings_koofr_notshowuphint")).setDesc(t("settings_koofr_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_koofr_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-koofr"===e.featureName)).length);console.debug(`allow to show up koofr settings? ${c}`),c?(d.removeClass("koofr-allow-to-use-hide"),l.settingEl.addClass("koofr-allow-to-use-hide")):(d.addClass("koofr-allow-to-use-hide"),l.settingEl.removeClass("koofr-allow-to-use-hide"));const u=d.createDiv(),p=u.createDiv({cls:"koofr-auth-button-hide settings-auth-related"}),h=u.createDiv({cls:"koofr-revoke-auth-button-hide settings-auth-related"}),f=new k.Setting(h).setName(t("settings_koofr_revoke")).setDesc(t("settings_koofr_revoke_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_koofr_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new mH(i,n,p,h,t).open()}))))}))));new k.Setting(p).setName(t("settings_koofr_auth")).setDesc(t("settings_koofr_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_koofr_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new fH(i,n,p,h,f,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=p,n.oauth2Info.revokeDiv=h,n.oauth2Info.revokeAuthSetting=f,e.open()}))))})))),p.toggleClass("koofr-auth-button-hide",""!==n.settings.koofr.refreshToken),h.toggleClass("koofr-revoke-auth-button-hide",""===n.settings.koofr.refreshToken);let m=n.settings.koofr.remoteBaseDir||"";return new k.Setting(d).setName(t("settings_remotebasedir")).setDesc(t("settings_remotebasedir_desc")).addText((e=>e.setPlaceholder(i.vault.getName()).setValue(m).onChange((e=>{m=e.trim()})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new BH(i,n,m,"koofr").open()}))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_koofr_connect_succ")):(new k.Notice(t("settings_koofr_connect_fail")),new k.Notice(r.msg))}))))})))),{koofrDiv:s,koofrAllowedToUsedDiv:d,koofrNotShowUpHintSetting:l}})(i,n,this.app,this.plugin),{azureBlobStorageDiv:Y,azureBlobStorageAllowedToUsedDiv:Q,azureBlobStorageNotShowUpHintSetting:Z}=((e,t,i,n)=>{var o;const s=e.createEl("div",{cls:"azureblobstorage-hide"});s.toggleClass("azureblobstorage-hide","azureblobstorage"!==n.settings.serviceType),s.createEl("h2",{text:t("settings_azureblobstorage")});const a=s.createEl("div",{cls:"settings-long-desc"});for(const e of[t("settings_azureblobstorage_disclaimer1"),Qp(t("settings_azureblobstorage_disclaimer2"))])a.createEl("p",{text:e,cls:"azureblobstorage-disclaimer"});a.createEl("p",{text:t("settings_azureblobstorage_folder",{remotePrefix:n.settings.azureblobstorage.remotePrefix||`${i.vault.getName()}/`})}),a.createDiv({text:Qp(t("settings_azureblobstorage_pro_desc")),cls:"azureblobstorage-disclaimer"});const l=new k.Setting(s).setName(t("settings_azureblobstorage_notshowuphint")).setDesc(t("settings_azureblobstorage_notshowuphint_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_azureblobstorage_notshowuphint_view_pro")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.location.href="#settings-pro"}))))})))),d=s.createDiv(),c=1===(null===(o=n.settings.pro)||void 0===o?void 0:o.enabledProFeatures.filter((e=>"feature-azure_blob_storage"===e.featureName)).length);console.debug(`allow to show up azureBlobStorage settings? ${c}`),c?(d.removeClass("azureblobstorage-allow-to-use-hide"),l.settingEl.addClass("azureblobstorage-allow-to-use-hide")):(d.addClass("azureblobstorage-allow-to-use-hide"),l.settingEl.removeClass("azureblobstorage-allow-to-use-hide")),new k.Setting(d).setName(t("settings_azureblobstorage_containersasurl")).setDesc(Qp(t("settings_azureblobstorage_containersasurl_desc"))).addText((e=>{RH(e),e.setPlaceholder("").setValue(`${n.settings.azureblobstorage.containerSasUrl}`).onChange((e=>r(void 0,void 0,void 0,(function*(){n.settings.azureblobstorage.containerSasUrl=e.trim(),yield n.saveSettings()}))))})),new k.Setting(d).setName(t("settings_azureblobstorage_containername")).setDesc(t("settings_azureblobstorage_containername_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(`${n.settings.azureblobstorage.containerName}`).onChange((e=>r(void 0,void 0,void 0,(function*(){n.settings.azureblobstorage.containerName=e.trim(),yield n.saveSettings()}))))}));let u=n.settings.azureblobstorage.remotePrefix||"";return new k.Setting(d).setName(t("settings_azureblobstorage_remoteprefix")).setDesc(t("settings_azureblobstorage_remoteprefix_desc")).addText((e=>e.setPlaceholder(`${i.vault.getName()}/`).setValue(u).onChange((e=>{const t=ih(e);u=""===t?`${i.vault.getName()}/`:t})))).addButton((e=>{e.setButtonText(t("confirm")),e.onClick((()=>{new aH(i,n,u).open()}))})),new k.Setting(d).setName(t("settings_azureblobstorage_parts")).setDesc(t("settings_azureblobstorage_parts_desc")).addDropdown((e=>{e.addOption("1","1"),e.addOption("2","2"),e.addOption("3","3"),e.addOption("5","5"),e.addOption("10","10"),e.addOption("15","15"),e.addOption("20","20 (default)"),e.setValue(`${n.settings.azureblobstorage.partsConcurrency}`).onChange((e=>r(void 0,void 0,void 0,(function*(){const t=Number.parseInt(e);n.settings.azureblobstorage.partsConcurrency=t,yield n.saveSettings()}))))})),new k.Setting(d).setName(t("settings_azureblobstorage_generatefolderobject")).setDesc(t("settings_azureblobstorage_generatefolderobject_desc")).addDropdown((e=>{e.addOption("notgenerate",t("settings_azureblobstorage_generatefolderobject_notgenerate")).addOption("generate",t("settings_azureblobstorage_generatefolderobject_generate")),e.setValue(n.settings.azureblobstorage.generateFolderObject?"generate":"notgenerate").onChange((e=>r(void 0,void 0,void 0,(function*(){n.settings.azureblobstorage.generateFolderObject="generate"===e,yield n.saveSettings()}))))})),new k.Setting(d).setName(t("settings_checkonnectivity")).setDesc(t("settings_checkonnectivity_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_checkonnectivity_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new k.Notice(t("settings_checkonnectivity_checking"));const e=Ej(n.settings,i.vault.getName(),(()=>n.saveSettings())),r={msg:""};(yield e.checkConnect((e=>{r.msg=`${e}`})))?new k.Notice(t("settings_azureblobstorage_connect_succ")):(new k.Notice(t("settings_azureblobstorage_connect_fail")),new k.Notice(r.msg))}))))})))),{azureBlobStorageDiv:s,azureBlobStorageAllowedToUsedDiv:d,azureBlobStorageNotShowUpHintSetting:l}})(i,n,this.app,this.plugin);new k.Setting(o).setName(n("settings_chooseservice")).setDesc(n("settings_chooseservice_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){e.addOption("s3",n("settings_chooseservice_s3")),e.addOption("dropbox",n("settings_chooseservice_dropbox")),e.addOption("webdav",n("settings_chooseservice_webdav")),e.addOption("onedrive",n("settings_chooseservice_onedrive")),e.addOption("webdis",n("settings_chooseservice_webdis")),e.addOption("separator line","-----"),e.selectEl.lastChild.setAttribute("disabled","disabled"),e.addOption("googledrive",n("settings_chooseservice_googledrive")),e.addOption("onedrivefull",n("settings_chooseservice_onedrivefull")),e.addOption("box",n("settings_chooseservice_box")),e.addOption("pcloud",n("settings_chooseservice_pcloud")),e.addOption("yandexdisk",n("settings_chooseservice_yandexdisk")),e.addOption("koofr",n("settings_chooseservice_koofr")),e.addOption("azureblobstorage",n("settings_chooseservice_azureblobstorage")),e.setValue(this.plugin.settings.serviceType).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.serviceType=e,s.toggleClass("s3-hide","s3"!==this.plugin.settings.serviceType),c.toggleClass("dropbox-hide","dropbox"!==this.plugin.settings.serviceType),v.toggleClass("onedrive-hide","onedrive"!==this.plugin.settings.serviceType),M.toggleClass("onedrivefull-hide","onedrivefull"!==this.plugin.settings.serviceType),T.toggleClass("webdav-hide","webdav"!==this.plugin.settings.serviceType),I.toggleClass("webdis-hide","webdis"!==this.plugin.settings.serviceType),P.toggleClass("googledrive-hide","googledrive"!==this.plugin.settings.serviceType),N.toggleClass("box-hide","box"!==this.plugin.settings.serviceType),L.toggleClass("pcloud-hide","pcloud"!==this.plugin.settings.serviceType),$.toggleClass("yandexdisk-hide","yandexdisk"!==this.plugin.settings.serviceType),K.toggleClass("koofr-hide","koofr"!==this.plugin.settings.serviceType),Y.toggleClass("azureblobstorage-hide","azureblobstorage"!==this.plugin.settings.serviceType),yield this.plugin.saveSettings()}))))}))));const X=i.createEl("div");X.createEl("h2",{text:n("settings_basic")});const ee=new k.Setting(X),te=new k.Setting(X);let re=`${this.plugin.settings.password}`;ee.setName(n("settings_password")).setDesc(n("settings_password_desc")).addText((e=>{RH(e),e.setPlaceholder("").setValue(`${this.plugin.settings.password}`).onChange((e=>r(this,void 0,void 0,(function*(){re=e.trim()}))))})).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("confirm")),e.onClick((()=>r(this,void 0,void 0,(function*(){new EH(this.app,this.plugin,re,te).open()}))))})))),""===this.plugin.settings.password&&te.settingEl.addClass("settings-encryption-method-hide"),te.setName(n("settings_encryptionmethod")).setDesc(Qp(n("settings_encryptionmethod_desc"))).addDropdown((e=>{var t;e.addOption("rclone-base64",n("settings_encryptionmethod_rclone")).addOption("openssl-base64",n("settings_encryptionmethod_openssl")).setValue(null!==(t=this.plugin.settings.encryptionMethod)&&void 0!==t?t:"rclone-base64").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.encryptionMethod=e,yield this.plugin.saveSettings(),""!==this.plugin.settings.password&&new TH(this.app,this.plugin).open()}))))})),new k.Setting(X).setName(n("settings_autorun")).setDesc(n("settings_autorun_desc")).addDropdown((e=>{e.addOption("-1",n("settings_autorun_notset")),e.addOption("60000",n("settings_autorun_1min")),e.addOption("300000",n("settings_autorun_5min")),e.addOption("600000",n("settings_autorun_10min")),e.addOption("1800000",n("settings_autorun_30min")),e.setValue(`${this.plugin.settings.autoRunEveryMilliseconds}`).onChange((e=>r(this,void 0,void 0,(function*(){const t=Number.parseInt(e);if(this.plugin.settings.autoRunEveryMilliseconds=t,yield this.plugin.saveSettings(),(null==t||t<=0)&&void 0!==this.plugin.autoRunIntervalID)window.clearInterval(this.plugin.autoRunIntervalID),this.plugin.autoRunIntervalID=void 0;else if(null!=t&&t>0){const e=window.setInterval((()=>{console.info("auto run from settings.ts"),this.plugin.syncRun("auto")}),t);this.plugin.autoRunIntervalID=e,this.plugin.registerInterval(e)}}))))})),new k.Setting(X).setName(n("settings_runoncestartup")).setDesc(n("settings_runoncestartup_desc")).addDropdown((e=>{e.addOption("-1",n("settings_runoncestartup_notset")),e.addOption("1000",n("settings_runoncestartup_1sec")),e.addOption("10000",n("settings_runoncestartup_10sec")),e.addOption("30000",n("settings_runoncestartup_30sec")),e.setValue(`${this.plugin.settings.initRunAfterMilliseconds}`).onChange((e=>r(this,void 0,void 0,(function*(){const t=Number.parseInt(e);this.plugin.settings.initRunAfterMilliseconds=t,yield this.plugin.saveSettings()}))))})),new k.Setting(X).setName(n("settings_synconsave")).setDesc(n("settings_synconsave_desc")).addDropdown((e=>{var t;e.addOption("-1",n("settings_synconsave_disable")),e.addOption("1000",n("settings_synconsave_enable"));let i=!1;(null!==(t=this.plugin.settings.syncOnSaveAfterMilliseconds)&&void 0!==t?t:-1)>0&&(i=!0),e.setValue(""+(i?"1000":"-1")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.syncOnSaveAfterMilliseconds=Number.parseInt(e),yield this.plugin.saveSettings(),this.plugin.toggleSyncOnSaveIfSet()}))))})),new k.Setting(X).setName(n("settings_skiplargefiles")).setDesc(n("settings_skiplargefiles_desc")).addDropdown((e=>{e.addOption("-1",n("settings_skiplargefiles_notset"));const t=[1,5,10,20,50,100,200,500,1e3];for(const r of t)e.addOption(""+1e3*r*1e3,`${r} MB`);e.setValue(`${this.plugin.settings.skipSizeLargerThan}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.skipSizeLargerThan=Number.parseInt(e),yield this.plugin.saveSettings()}))))})),k.Platform.isMobileApp||(new k.Setting(X).setName(n("settings_enablestatusbar_info")).setDesc(n("settings_enablestatusbar_info_desc")).addToggle((e=>{var t;e.setValue(null!==(t=this.plugin.settings.enableStatusBarInfo)&&void 0!==t&&t).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.enableStatusBarInfo=e,yield this.plugin.saveSettings(),new k.Notice(n("settings_enablestatusbar_reloadrequired_notice"))}))))})),new k.Setting(X).setName(n("settings_resetstatusbar_time")).setDesc(n("settings_resetstatusbar_time_desc")).addButton((e=>{e.setButtonText(n("settings_resetstatusbar_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield P_(this.plugin.db,this.plugin.vaultRandomID,-1),yield z_(this.plugin.db,this.plugin.vaultRandomID,-1),this.plugin.updateLastSyncMsg(void 0,"not_syncing",null,null),new k.Notice(n("settings_resetstatusbar_notice"))}))))}))),new k.Setting(X).setName(n("settings_ignorepaths")).setDesc(n("settings_ignorepaths_desc")).setClass("ignorepaths-settings").addTextArea((e=>{var t;e.setValue(`${(null!==(t=this.plugin.settings.ignorePaths)&&void 0!==t?t:[]).join("\n")}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.ignorePaths=e.trim().split("\n").filter((e=>""!==e.trim())),yield this.plugin.saveSettings()})))),e.inputEl.rows=10,e.inputEl.cols=30,e.inputEl.addClass("ignorepaths-textarea")})),new k.Setting(X).setName(n("settings_onlyallowpaths")).setDesc(n("settings_onlyallowpaths_desc")).setClass("onlyallowpaths-settings").addTextArea((e=>{var t;e.setValue(`${(null!==(t=this.plugin.settings.onlyAllowPaths)&&void 0!==t?t:[]).join("\n")}`).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.onlyAllowPaths=e.trim().split("\n").filter((e=>""!==e.trim())),yield this.plugin.saveSettings()})))),e.inputEl.rows=10,e.inputEl.cols=30,e.inputEl.addClass("onlyallowpaths-textarea")}));const ie=i.createEl("div");ie.createEl("h2",{text:n("settings_adv")}),new k.Setting(ie).setName(n("settings_concurrency")).setDesc(n("settings_concurrency_desc")).addDropdown((e=>{e.addOption("1","1"),e.addOption("2","2"),e.addOption("3","3"),e.addOption("5","5 (default)"),e.addOption("10","10"),e.addOption("15","15"),e.addOption("20","20"),e.setValue(`${this.plugin.settings.concurrency}`).onChange((e=>r(this,void 0,void 0,(function*(){const t=Number.parseInt(e);this.plugin.settings.concurrency=t,yield this.plugin.saveSettings()}))))})),new k.Setting(ie).setName(n("settings_syncunderscore")).setDesc(n("settings_syncunderscore_desc")).addDropdown((e=>{e.addOption("disable",n("disable")),e.addOption("enable",n("enable")),e.setValue(""+(this.plugin.settings.syncUnderscoreItems?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.syncUnderscoreItems="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(ie).setName(n("settings_configdir")).setDesc(n("settings_configdir_desc",{configDir:this.app.vault.configDir})).addDropdown((e=>{e.addOption("disable",n("disable")),e.addOption("enable",n("enable"));const t={secondConfirm:!1};e.setValue(""+(this.plugin.settings.syncConfigDir?"enable":"disable")).onChange((i=>r(this,void 0,void 0,(function*(){"enable"!==i||t.secondConfirm?(t.secondConfirm=!1,this.plugin.settings.syncConfigDir=!1,yield this.plugin.saveSettings()):(e.setValue("disable"),new MH(this.app,this.plugin,(()=>{t.secondConfirm=!0,e.setValue("enable")})).open())}))))})),new k.Setting(ie).setName(n("settings_bookmarks")).setDesc(n("settings_bookmarks_desc",{configDir:this.app.vault.configDir})).addDropdown((e=>{e.addOption("disable",n("disable")),e.addOption("enable",n("enable")),e.setValue(""+(this.plugin.settings.syncBookmarks?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.syncBookmarks="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(ie).setName(n("settings_deletetowhere")).setDesc(n("settings_deletetowhere_desc")).addDropdown((e=>{var t;e.addOption("system",n("settings_deletetowhere_system_trash")),e.addOption("obsidian",n("settings_deletetowhere_obsidian_trash")),e.setValue(null!==(t=this.plugin.settings.deleteToWhere)&&void 0!==t?t:"system").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.deleteToWhere=e,yield this.plugin.saveSettings()}))))}));let ne=n("settings_conflictaction_desc");"smart_conflict"===(null!==(e=this.plugin.settings.conflictAction)&&void 0!==e?e:"keep_newer")&&(ne+=n("settings_conflictaction_smart_conflict_desc"));const oe=new k.Setting(ie).setName(n("settings_conflictaction")).setDesc(Qp(ne));oe.addDropdown((e=>{var t;e.addOption("keep_newer",n("settings_conflictaction_keep_newer")).addOption("keep_larger",n("settings_conflictaction_keep_larger")).addOption("smart_conflict",n("settings_conflictaction_smart_conflict")).setValue(null!==(t=this.plugin.settings.conflictAction)&&void 0!==t?t:"keep_newer").onChange((e=>r(this,void 0,void 0,(function*(){var t;this.plugin.settings.conflictAction=e,yield this.plugin.saveSettings(),ne=n("settings_conflictaction_desc"),"smart_conflict"===(null!==(t=this.plugin.settings.conflictAction)&&void 0!==t?t:"keep_newer")&&(ne+=n("settings_conflictaction_smart_conflict_desc")),oe.setDesc(Qp(ne))}))))})),uH(ie,n,this.app,this.plugin);const se=new k.Setting(ie).setName(n("settings_protectmodifypercentage")).setDesc(n("settings_protectmodifypercentage_desc")),ae=new k.Setting(ie).setName(n("settings_protectmodifypercentage_customfield")).setDesc(n("settings_protectmodifypercentage_customfield_desc"));let le;(null!==(t=this.plugin.settings.protectModifyPercentage)&&void 0!==t?t:50)%10==0&&ae.settingEl.addClass("settings-percentage-custom-hide"),ae.addText((e=>{var t;e.inputEl.type="number",le=e,e.setPlaceholder("0 ~ 100").setValue(`${null!==(t=this.plugin.settings.protectModifyPercentage)&&void 0!==t?t:50}`).onChange((e=>r(this,void 0,void 0,(function*(){let t=Number.parseFloat(e.trim());Number.isNaN(t)||(t<0?t=0:t>100&&(t=100),this.plugin.settings.protectModifyPercentage=t,yield this.plugin.saveSettings())}))))})),se.addDropdown((e=>{var t;for(const t of Array.from({length:11},((e,t)=>10*t))){let r=`${t}`;0===t?r=n("settings_protectmodifypercentage_000_desc"):50===t?r=n("settings_protectmodifypercentage_050_desc"):100===t&&(r=n("settings_protectmodifypercentage_100_desc")),e.addOption(`${t}`,r)}e.addOption("custom",n("settings_protectmodifypercentage_custom_desc"));const i=null!==(t=this.plugin.settings.protectModifyPercentage)&&void 0!==t?t:50;let o="custom";i%10==0?o=`${i}`:ae.settingEl.removeClass("settings-percentage-custom"),e.setValue(o).onChange((e=>r(this,void 0,void 0,(function*(){const t=Number.parseInt(e);"custom"===e||Number.isNaN(t)?ae.settingEl.removeClass("settings-percentage-custom-hide"):(this.plugin.settings.protectModifyPercentage=t,ae.settingEl.addClass("settings-percentage-custom-hide"),null==le||le.setValue(`${t}`),yield this.plugin.saveSettings())}))))})),new k.Setting(ie).setName(n("setting_syncdirection")).setDesc(Qp(n("setting_syncdirection_desc"))).addDropdown((e=>{var t;e.addOption("bidirectional",n("setting_syncdirection_bidirectional_desc")),e.addOption("incremental_push_only",n("setting_syncdirection_incremental_push_only_desc")),e.addOption("incremental_pull_only",n("setting_syncdirection_incremental_pull_only_desc")),e.addOption("incremental_push_and_delete_only",n("setting_syncdirection_incremental_push_and_delete_only_desc")),e.addOption("incremental_pull_and_delete_only",n("setting_syncdirection_incremental_pull_and_delete_only_desc")),e.setValue(null!==(t=this.plugin.settings.syncDirection)&&void 0!==t?t:"bidirectional").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.syncDirection=e,yield this.plugin.saveSettings()}))))})),k.Platform.isMobile&&new k.Setting(ie).setName(n("settings_enablemobilestatusbar")).setDesc(n("settings_enablemobilestatusbar_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){e.addOption("enable",n("enable")).addOption("disable",n("disable")),e.setValue(""+(this.plugin.settings.enableMobileStatusBar?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){var t;"enable"===e?(this.plugin.settings.enableMobileStatusBar=!0,this.plugin.appContainerObserver=Xp("enable")):(this.plugin.settings.enableMobileStatusBar=!1,Xp("disable",this.plugin.appContainerObserver),null===(t=this.plugin.appContainerObserver)||void 0===t||t.disconnect(),this.plugin.appContainerObserver=void 0),yield this.plugin.saveSettings()}))))}))));const de=i.createEl("div");de.createEl("h2",{text:n("settings_importexport")});const ce=new k.Setting(de).setName(n("settings_export")).setDesc(n("settings_export_desc"));ce.settingEl.addClass("setting-need-wrapping"),ce.addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_basic_and_advanced_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"basic_and_advanced").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_s3_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"s3").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_dropbox_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"dropbox").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_onedrive_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"onedrive").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_onedrivefull_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"onedrivefull").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_webdav_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"webdav").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_webdis_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"webdis").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_googledrive_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"googledrive").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_box_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"box").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_pcloud_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"pcloud").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_yandexdisk_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"yandexdisk").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_koofr_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"koofr").open()}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_export_azureblobstorage_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new DH(this.app,this.plugin,"azureblobstorage").open()}))))}))));let pe="";new k.Setting(de).setName(n("settings_import")).setDesc(n("settings_import_desc")).addText((e=>e.setPlaceholder("obsidian://remotely-save?func=settings&...").setValue("").onChange((e=>{pe=e})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("confirm")),e.onClick((()=>r(this,void 0,void 0,(function*(){if(""!==pe){try{const e=(e=>{if(!e.startsWith("obsidian://remotely-save?func=settings&"))throw Error("not valid string");const t=new URL(e);return Object.fromEntries(t.searchParams)})(pe),t=rH(e,this.app.vault.getName());if("error"===t.status)new k.Notice(t.message);else{const e=m()(t.result);this.plugin.settings=Object.assign({},this.plugin.settings,e),this.plugin.saveSettings(),new k.Notice(n("protocol_saveqr",{manifestName:this.plugin.manifest.name}))}}catch(e){new k.Notice(`${e}`)}pe=""}else new k.Notice(n("settings_import_error_notice")),pe=""}))))}))));((e,t,i,n,o,s,a,l,d,c,u,p,h,f,m,g,y,v,b)=>{var w,_,x;e.createEl("h2",{text:t("settings_pro")}).setAttribute("id","settings-pro"),e.createEl("div",{text:Qp(t("settings_pro_tutorial"))});const S=e.createDiv(),E=S.createDiv({cls:"pro-auth-button-hide settings-auth-related"}),T=S.createDiv({cls:"pro-revoke-auth-button-hide settings-auth-related"}),B=new k.Setting(T).setName(t("settings_pro_features")).setDesc(Qp(t("settings_pro_features_desc",{features:xH(n.settings.pro.enabledProFeatures)})));B.addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pro_features_refresh_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){var e,r,i,w,_,x,S;new k.Notice(t("settings_pro_features_refresh_fetch")),yield ue(n.settings.pro,n.manifest.version,o),B.setDesc(Qp(t("settings_pro_features_desc",{features:xH(n.settings.pro.enabledProFeatures)})));const E=1===(null===(e=n.settings.pro)||void 0===e?void 0:e.enabledProFeatures.filter((e=>"feature-onedrive_full"===e.featureName)).length);console.debug(`allow to show up OnedriveFull settings? ${E}`),E?(s.removeClass("onedrivefull-allow-to-use-hide"),a.settingEl.addClass("onedrivefull-allow-to-use-hide")):(s.addClass("onedrivefull-allow-to-use-hide"),a.settingEl.removeClass("onedrivefull-allow-to-use-hide"));const T=1===(null===(r=n.settings.pro)||void 0===r?void 0:r.enabledProFeatures.filter((e=>"feature-google_drive"===e.featureName)).length);console.debug(`allow to show up google drive settings? ${T}`),T?(l.removeClass("googledrive-allow-to-use-hide"),d.settingEl.addClass("googledrive-allow-to-use-hide")):(l.addClass("googledrive-allow-to-use-hide"),d.settingEl.removeClass("googledrive-allow-to-use-hide"));const C=1===(null===(i=n.settings.pro)||void 0===i?void 0:i.enabledProFeatures.filter((e=>"feature-box"===e.featureName)).length);console.debug(`allow to show up Box settings? ${C}`),C?(c.removeClass("box-allow-to-use-hide"),u.settingEl.addClass("box-allow-to-use-hide")):(c.addClass("box-allow-to-use-hide"),u.settingEl.removeClass("box-allow-to-use-hide"));const I=1===(null===(w=n.settings.pro)||void 0===w?void 0:w.enabledProFeatures.filter((e=>"feature-pcloud"===e.featureName)).length);console.debug(`allow to show up pCloud settings? ${I}`),I?(p.removeClass("pcloud-allow-to-use-hide"),h.settingEl.addClass("pcloud-allow-to-use-hide")):(p.addClass("pcloud-allow-to-use-hide"),h.settingEl.removeClass("pcloud-allow-to-use-hide"));const A=1===(null===(_=n.settings.pro)||void 0===_?void 0:_.enabledProFeatures.filter((e=>"feature-yandex_disk"===e.featureName)).length);console.debug(`allow to show up Yandex Disk settings? ${A}`),A?(f.removeClass("yandexdisk-allow-to-use-hide"),m.settingEl.addClass("yandexdisk-allow-to-use-hide")):(f.addClass("yandexdisk-allow-to-use-hide"),m.settingEl.removeClass("yandexdisk-allow-to-use-hide"));const F=1===(null===(x=n.settings.pro)||void 0===x?void 0:x.enabledProFeatures.filter((e=>"feature-koofr"===e.featureName)).length);console.debug(`allow to show up Koofr settings? ${F}`),F?(g.removeClass("koofr-allow-to-use-hide"),y.settingEl.addClass("koofr-allow-to-use-hide")):(g.addClass("koofr-allow-to-use-hide"),y.settingEl.removeClass("koofr-allow-to-use-hide"));const M=1===(null===(S=n.settings.pro)||void 0===S?void 0:S.enabledProFeatures.filter((e=>"feature-azure_blob_storage"===e.featureName)).length);console.debug(`allow to show up AzureBlobStorage settings? ${M}`),M?(v.removeClass("azureblobstorage-allow-to-use-hide"),b.settingEl.addClass("azureBlobStorage-allow-to-use-hide")):(v.addClass("azureblobstorage-allow-to-use-hide"),b.settingEl.removeClass("azureblobstorage-allow-to-use-hide")),new k.Notice(t("settings_pro_features_refresh_succ"))}))))}))));const C=new k.Setting(T).setName(t("settings_pro_revoke")).setDesc(t("settings_pro_revoke_desc",{email:null===(w=n.settings.pro)||void 0===w?void 0:w.email})).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pro_revoke_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){new _H(i,n,E,T,t).open()}))))}))));new k.Setting(E).setName(t("settings_pro_intro")).setDesc(Qp(t("settings_pro_intro_desc"))).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pro_intro_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){window.open("https://remotelysave.com/user/signupin","_self")}))))})))),new k.Setting(E).setName(t("settings_pro_auth")).setDesc(t("settings_pro_auth_desc")).addButton((e=>r(void 0,void 0,void 0,(function*(){e.setButtonText(t("settings_pro_auth_button")),e.onClick((()=>r(void 0,void 0,void 0,(function*(){const e=new wH(i,n,E,T,C,B,t);n.oauth2Info.helperModal=e,n.oauth2Info.authDiv=E,n.oauth2Info.revokeDiv=T,n.oauth2Info.revokeAuthSetting=C,e.open()}))))})))),E.toggleClass("pro-auth-button-hide",""!==(null===(_=n.settings.pro)||void 0===_?void 0:_.refreshToken)),T.toggleClass("pro-revoke-auth-button-hide",""===(null===(x=n.settings.pro)||void 0===x?void 0:x.refreshToken))})(i.createEl("div"),n,this.app,this.plugin,(()=>this.plugin.saveSettings()),D,R,O,z,q,U,j,H,G,W,V,J,Q,Z);const he=i.createEl("div");he.createEl("h2",{text:n("settings_debug")}),new k.Setting(he).setName(n("settings_debuglevel")).setDesc(n("settings_debuglevel_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){var t;e.addOption("info","info"),e.addOption("debug","debug"),e.setValue(null!==(t=this.plugin.settings.currLogLevel)&&void 0!==t?t:"info").onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.currLogLevel=e,yield this.plugin.saveSettings(),console.info(`the log level is changed to ${e}`)}))))})))),new k.Setting(he).setName(n("settings_outputsettingsconsole")).setDesc(n("settings_outputsettingsconsole_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_outputsettingsconsole_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){const e=dx(yield this.plugin.loadData());console.info(e),new k.Notice(n("settings_outputsettingsconsole_notice"))}))))})))),new k.Setting(he).setName(n("settings_obfuscatesettingfile")).setDesc(n("settings_obfuscatesettingfile_desc")).addDropdown((e=>r(this,void 0,void 0,(function*(){e.addOption("enable",n("enable")).addOption("disable",n("disable")),e.setValue(""+(this.plugin.settings.obfuscateSettingFile?"enable":"disable")).onChange((e=>r(this,void 0,void 0,(function*(){this.plugin.settings.obfuscateSettingFile="enable"===e,yield this.plugin.saveSettings()}))))})))),new k.Setting(he).setName(n("settings_viewconsolelog")).setDesc(Qp(n("settings_viewconsolelog_desc")));const fe=new k.Setting(he).setName(n("settings_syncplans")).setDesc(n("settings_syncplans_desc"));fe.settingEl.addClass("setting-need-wrapping"),fe.addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_syncplans_button_1_only_change")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield ux(this.plugin.db,this.app.vault,this.plugin.vaultRandomID,1,!0),new k.Notice(n("settings_syncplans_notice"))}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_syncplans_button_5_only_change")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield ux(this.plugin.db,this.app.vault,this.plugin.vaultRandomID,5,!0),new k.Notice(n("settings_syncplans_notice"))}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_syncplans_button_1")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield ux(this.plugin.db,this.app.vault,this.plugin.vaultRandomID,1,!1),new k.Notice(n("settings_syncplans_notice"))}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_syncplans_button_5")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield ux(this.plugin.db,this.app.vault,this.plugin.vaultRandomID,5,!1),new k.Notice(n("settings_syncplans_notice"))}))))})))).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_syncplans_button_all")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield ux(this.plugin.db,this.app.vault,this.plugin.vaultRandomID,-1,!1),new k.Notice(n("settings_syncplans_notice"))}))))})))),new k.Setting(he).setName(n("settings_delsyncplans")).setDesc(n("settings_delsyncplans_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_delsyncplans_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){var e;yield(e=this.plugin.db,r(void 0,void 0,void 0,(function*(){yield e.syncPlansTbl.clear()}))),new k.Notice(n("settings_delsyncplans_notice"))}))))})))),new k.Setting(he).setName(n("settings_delprevsync")).setDesc(n("settings_delprevsync_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_delprevsync_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){var e,t;yield(e=this.plugin.db,t=this.plugin.vaultRandomID,r(void 0,void 0,void 0,(function*(){const r=(yield e.prevSyncRecordsTbl.keys()).filter((e=>e.startsWith(`${t}\t`)));yield e.prevSyncRecordsTbl.removeItems(r)}))),new k.Notice(n("settings_delprevsync_notice"))}))))})))),new k.Setting(he).setName(n("settings_profiler_results")).setDesc(n("settings_profiler_results_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_profiler_results_button_all")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield px(this.plugin.db,this.app.vault,this.plugin.vaultRandomID),new k.Notice(n("settings_profiler_results_notice"))}))))})))),new k.Setting(he).setName(n("settings_profiler_enableprofiler")).setDesc(n("settings_profiler_enableprofiler_desc")).addDropdown((e=>{var t;e.addOption("enable",n("enable")),e.addOption("disable",n("disable")),e.setValue((null===(t=this.plugin.settings.profiler)||void 0===t?void 0:t.enable)?"enable":"disable").onChange((e=>r(this,void 0,void 0,(function*(){void 0===this.plugin.settings.profiler&&(this.plugin.settings.profiler=iH),this.plugin.settings.profiler.enable="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(he).setName(n("settings_profiler_enabledebugprint")).setDesc(n("settings_profiler_enabledebugprint_desc")).addDropdown((e=>{var t;e.addOption("enable",n("enable")),e.addOption("disable",n("disable")),e.setValue((null===(t=this.plugin.settings.profiler)||void 0===t?void 0:t.enablePrinting)?"enable":"disable").onChange((e=>r(this,void 0,void 0,(function*(){void 0===this.plugin.settings.profiler&&(this.plugin.settings.profiler=iH),this.plugin.settings.profiler.enablePrinting="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(he).setName(n("settings_profiler_recordsize")).setDesc(n("settings_profiler_recordsize_desc")).addDropdown((e=>{var t;e.addOption("enable",n("enable")),e.addOption("disable",n("disable")),e.setValue((null===(t=this.plugin.settings.profiler)||void 0===t?void 0:t.recordSize)?"enable":"disable").onChange((e=>r(this,void 0,void 0,(function*(){void 0===this.plugin.settings.profiler&&(this.plugin.settings.profiler=iH),this.plugin.settings.profiler.recordSize="enable"===e,yield this.plugin.saveSettings()}))))})),new k.Setting(he).setName(n("settings_outputbasepathvaultid")).setDesc(n("settings_outputbasepathvaultid_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_outputbasepathvaultid_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){new k.Notice(this.plugin.getVaultBasePath()),new k.Notice(this.plugin.vaultRandomID)}))))})))),new k.Setting(he).setName(n("settings_resetcache")).setDesc(n("settings_resetcache_desc")).addButton((e=>r(this,void 0,void 0,(function*(){e.setButtonText(n("settings_resetcache_button")),e.onClick((()=>r(this,void 0,void 0,(function*(){yield r(void 0,void 0,void 0,(function*(){const e=indexedDB.deleteDatabase(I_);e.onsuccess=e=>{console.info("db deleted")},e.onblocked=e=>{console.warn("trying to delete db but it was blocked")},e.onerror=e=>{console.error("tried to delete db but something goes wrong!"),console.error(e)}})),new k.Notice(n("settings_resetcache_notice")),this.plugin.unload()}))))}))))}hide(){const{containerEl:e}=this;e.empty(),super.hide()}}class OH extends k.Modal{constructor(e,t){super(e),this.plugin=t,this.agree=!1,this.manualBackup=!1,this.requireUpdateAllDev=!1}onOpen(){const{contentEl:e}=this,t=(e,t)=>this.plugin.i18n.t(e,t);e.createEl("h2",{text:t("syncalgov3_title")});const r=e.createEl("ul");t("syncalgov3_texts").split("\n").forEach((e=>{r.createEl("li",{text:Qp(e)})})),e.createDiv("modal-button-container",(e=>{let r;e.createEl("label",{cls:"mod-checkbox"},(e=>{const i=e.createEl("input",{attr:{tabindex:-1},type:"checkbox"});i.checked=this.manualBackup,i.addEventListener("click",(()=>{this.manualBackup=i.checked,void 0!==r&&(this.manualBackup&&this.requireUpdateAllDev?r.removeAttribute("disabled"):r.setAttr("disabled",!0))})),e.appendText(t("syncalgov3_checkbox_manual_backup"))})),e.createEl("label",{cls:"mod-checkbox"},(e=>{const i=e.createEl("input",{attr:{tabindex:-1},type:"checkbox"});i.checked=this.requireUpdateAllDev,i.addEventListener("click",(()=>{this.requireUpdateAllDev=i.checked,void 0!==r&&(this.manualBackup&&this.requireUpdateAllDev?r.removeAttribute("disabled"):r.setAttr("disabled",!0))})),e.appendText(t("syncalgov3_checkbox_requiremultidevupdate"))})),r=e.createEl("button",{attr:{type:"button"},cls:"mod-cta",text:t("syncalgov3_button_agree")}),r.setAttr("disabled",!0),r.addEventListener("click",(()=>{this.agree=!0,this.close()})),e.createEl("button",{attr:{type:"submit"},text:t("syncalgov3_button_disagree")}).addEventListener("click",(()=>{this.close()}))}))}onClose(){const{contentEl:e}=this;e.empty(),this.agree?(console.info("agree to use the new algorithm"),this.plugin.saveAgreeToUseNewSyncAlgorithm(),this.plugin.enableAutoSyncIfSet(),this.plugin.enableInitSyncIfSet(),this.plugin.toggleSyncOnSaveIfSet()):(console.info("do not agree to use the new algorithm"),this.plugin.unload())}}const zH={s3:{s3Endpoint:"",s3Region:"",s3AccessKeyID:"",s3SecretAccessKey:"",s3BucketName:"",bypassCorsLocally:!0,partsConcurrency:20,forcePathStyle:!1,remotePrefix:"",useAccurateMTime:!1,reverseProxyNoSignUrl:"",generateFolderObject:!1},webdav:{address:"",username:"",password:"",authType:"basic",manualRecursive:!0,depth:"manual_1",remoteBaseDir:""},dropbox:gx,onedrive:qx,onedrivefull:n_,webdis:{address:"",username:"",password:"",remoteBaseDir:""},googledrive:Sh,box:bh,pcloud:p_,yandexdisk:y_,koofr:Nh,azureblobstorage:nh,password:"",serviceType:"s3",currLogLevel:"info",autoRunEveryMilliseconds:-1,initRunAfterMilliseconds:-1,syncOnSaveAfterMilliseconds:-1,agreeToUploadExtraMetadata:!0,concurrency:5,syncConfigDir:!1,syncBookmarks:!1,syncUnderscoreItems:!1,lang:"auto",logToDB:!1,skipSizeLargerThan:-1,ignorePaths:[],onlyAllowPaths:[],enableStatusBarInfo:!0,deleteToWhere:"system",agreeToUseSyncV3:!1,conflictAction:"keep_newer",howToCleanEmptyFolder:"clean_both",protectModifyPercentage:50,syncDirection:"bidirectional",obfuscateSettingFile:!0,enableMobileStatusBar:!1,encryptionMethod:"unknown",profiler:iH,pro:se},NH="remotely-save-sync-wait",qH="remotely-save-sync-running",UH="remotely-save-logs",LH=(e,t)=>{if(void 0===t)return"";switch(t){case"manual":return e("statusbar_sync_source_manual");case"dry":return e("statusbar_sync_source_dry");case"auto":return e("statusbar_sync_source_auto");case"auto_once_init":return e("statusbar_sync_source_auto_once_init");case"auto_sync_on_save":return e("statusbar_sync_source_auto_sync_on_save");default:throw Error(`no translate for ${t}`)}};class jH extends k.Plugin{constructor(){super(...arguments),this._syncOnSaveEvent1=()=>{this._checkCurrFileModified("SYNC")},this._syncOnSaveEvent2=y()((()=>r(this,void 0,void 0,(function*(){yield this._checkCurrFileModified("FILE_CHANGES")}))),3e3,{leading:!1,trailing:!0})}syncRun(){return r(this,arguments,void 0,(function*(e="manual"){var t,i,n,o,s,a,l,d,c,u,p,f;let m;null!==(i=null===(t=this.settings.profiler)||void 0===t?void 0:t.enable)&&void 0!==i&&i&&(m=new nH(void 0,null!==(o=null===(n=this.settings.profiler)||void 0===n?void 0:n.enablePrinting)&&void 0!==o&&o,null!==(a=null===(s=this.settings.profiler)||void 0===s?void 0:s.recordSize)&&void 0!==a&&a));const g=new Cj(this.app.vault,null!==(l=this.settings.syncConfigDir)&&void 0!==l&&l,null!==(d=this.settings.syncBookmarks)&&void 0!==d&&d,this.app.vault.configDir,this.manifest.id,m,null!==(c=this.settings.deleteToWhere)&&void 0!==c?c:"system"),y=Ej(this.settings,this.app.vault.getName(),(()=>r(this,void 0,void 0,(function*(){return yield this.saveSettings()})))),v=new Ox(y,null!==(u=this.settings.password)&&void 0!==u?u:"",null!==(p=this.settings.encryptionMethod)&&void 0!==p?p:"rclone-base64"),b=(e,t)=>this.i18n.t(e,t),w=this.getCurrProfileID(),_=(e,t,r)=>{"manual"!==e&&"dry"!==e||new k.Notice(t,r)};if(this.isSyncing)return _(e,b("syncrun_alreadyrunning",{pluginName:this.manifest.name,syncStatus:"running",newTriggerSource:e})),void(void 0!==this.currSyncMsg&&""!==this.currSyncMsg&&_(e,this.currSyncMsg));yield ax(g,y,v,m,this.db,e,w,this.vaultRandomID,this.app.vault.configDir,this.settings,this.manifest.version,(()=>r(this,void 0,void 0,(function*(){return yield this.saveSettings()}))),((e,t,r)=>{const i=(100*t/r).toFixed(1);return b("syncrun_abort_protectmodifypercentage",{protectModifyPercentage:e,realModifyDeleteCount:t,allFilesCount:r,percent:i})}),(e=>r(this,void 0,void 0,(function*(){this.isSyncing=e}))),((e,t)=>r(this,void 0,void 0,(function*(){switch(t){case 0:"dry"===e&&("info"===this.settings.currLogLevel?_(e,b("syncrun_shortstep0")):_(e,b("syncrun_step0")));break;case 1:"info"===this.settings.currLogLevel?_(e,b("syncrun_shortstep1",{serviceType:this.settings.serviceType})):_(e,b("syncrun_step1",{serviceType:this.settings.serviceType}));break;case 2:"info"===this.settings.currLogLevel||_(e,b("syncrun_step2"));break;case 3:"info"===this.settings.currLogLevel||_(e,b("syncrun_step3"));break;case 4:"info"===this.settings.currLogLevel||_(e,b("syncrun_step4"));break;case 5:"info"===this.settings.currLogLevel||_(e,b("syncrun_step5"));break;case 6:"info"===this.settings.currLogLevel||_(e,b("syncrun_step6"));break;case 7:"dry"===e?"info"===this.settings.currLogLevel?_(e,b("syncrun_shortstep2skip")):_(e,b("syncrun_step7skip")):"info"===this.settings.currLogLevel||_(e,b("syncrun_step7"));break;case 8:"info"===this.settings.currLogLevel?_(e,b("syncrun_shortstep2")):_(e,b("syncrun_step8"));break;default:throw Error(`unknown step=${t} for showing notice`)}}))),((e,t)=>r(this,void 0,void 0,(function*(){var r;if(console.error(t),t instanceof h)for(const r of t.errors)_(e,r.message,1e4);else _(e,null!==(r=null==t?void 0:t.message)&&void 0!==r?r:"error while sync",1e4)}))),((e,t)=>r(this,void 0,void 0,(function*(){if(1===t)void 0!==this.syncRibbon&&((0,k.setIcon)(this.syncRibbon,qH),this.syncRibbon.setAttribute("aria-label",b("syncrun_syncingribbon",{pluginName:this.manifest.name,triggerSource:e})));else if(8===t&&void 0!==this.syncRibbon){(0,k.setIcon)(this.syncRibbon,NH);const e=`${this.manifest.name}`;this.syncRibbon.setAttribute("aria-label",e)}}))),((e,t,i)=>r(this,void 0,void 0,(function*(){if(1===t)this.updateLastSyncMsg(e,"syncing",-1,-1);else if(8===t&&i){const t=Date.now();yield P_(this.db,this.vaultRandomID,t),this.updateLastSyncMsg(e,"not_syncing",t,null)}else if(!i){const t=Date.now();yield z_(this.db,this.vaultRandomID,t),this.updateLastSyncMsg(e,"not_syncing",null,t)}}))),((t,i,n,o,s)=>r(this,void 0,void 0,(function*(){this.setCurrSyncMsg(b,t,i,n,o,s,e)})))),v.closeResources(),null==m||m.clear(),null===(f=this.syncEvent)||void 0===f||f.trigger("SYNC_DONE")}))}onload(){return r(this,void 0,void 0,(function*(){var e;console.info(`loading plugin ${this.manifest.id}`);const{iconSvgSyncWait:t,iconSvgSyncRunning:i,iconSvgLogs:n}=(()=>{const e=b(_);e.setAttribute("width","100"),e.setAttribute("height","100");const t=b(x);t.setAttribute("width","100"),t.setAttribute("height","100");const r=b(S);r.setAttribute("width","100"),r.setAttribute("height","100");const i={iconSvgSyncWait:e.outerHTML,iconSvgSyncRunning:t.outerHTML,iconSvgLogs:r.outerHTML};return e.empty(),t.empty(),r.empty(),i})();(0,k.addIcon)(NH,t),(0,k.addIcon)(qH,i),(0,k.addIcon)(UH,n),this.oauth2Info={verifier:"",helperModal:void 0,authDiv:void 0,revokeDiv:void 0,revokeAuthSetting:void 0},this.currSyncMsg="",this.isSyncing=!1,this.hasPendingSyncOnSave=!1,this.syncEvent=new k.Events,yield this.loadSettings();const o=this.getCurrProfileID();this.i18n=new eH(this.settings.lang,(e=>r(this,void 0,void 0,(function*(){this.settings.lang=e,yield this.saveSettings()}))));const s=(e,t)=>this.i18n.t(e,t);yield this.checkIfOauthExpires();const a=yield this.getVaultRandomIDFromOldConfigFile();this.tryToAddIgnoreFile();const l=this.getVaultBasePath();try{yield this.prepareDBAndVaultRandomID(l,a,o)}catch(t){throw new k.Notice(null!==(e=null==t?void 0:t.message)&&void 0!==e?e:"error of prepareDBAndVaultRandomID",1e4),t}if(this.enableAutoClearOutputToDBHistIfSet(),this.enableAutoClearSyncPlanHist(),this.registerObsidianProtocolHandler(A,(e=>r(this,void 0,void 0,(function*(){const t=rH(e,this.app.vault.getName());if("error"===t.status)new k.Notice(t.message);else{const e=m()(t.result);this.settings=Object.assign({},this.settings,e),this.saveSettings(),new k.Notice(s("protocol_saveqr",{manifestName:this.manifest.name}))}})))),this.registerObsidianProtocolHandler("remotely-save-cb",(e=>r(this,void 0,void 0,(function*(){new k.Notice(s("protocol_callbacknotsupported",{params:JSON.stringify(e)}))})))),this.registerObsidianProtocolHandler(M,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a;if(void 0===e.code||void 0===(null===(t=this.oauth2Info)||void 0===t?void 0:t.verifier))throw new k.Notice(s("protocol_dropbox_connect_fail")),Error(s("protocol_dropbox_connect_unknown",{params:JSON.stringify(e)}));{if(void 0===this.oauth2Info.helperModal)return void new k.Notice(s("protocol_dropbox_no_modal"));{const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_dropbox_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}const t=yield wx(this.settings.dropbox.clientID,this.oauth2Info.verifier,e.code,(e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_dropbox_connect_fail")),new k.Notice(`${e}`),e})))),l=this;_x(this.settings.dropbox,t,(()=>l.saveSettings()));const d=Ej(this.settings,this.app.vault.getName(),(()=>l.saveSettings())),c=yield d.getUserDisplayName();this.settings.dropbox.username=c,yield this.saveSettings(),new k.Notice(s("protocol_dropbox_connect_succ",{username:c})),this.oauth2Info.verifier="",null===(i=this.oauth2Info.helperModal)||void 0===i||i.close(),this.oauth2Info.helperModal=void 0,null===(n=this.oauth2Info.authDiv)||void 0===n||n.toggleClass("dropbox-auth-button-hide",""!==this.settings.dropbox.username),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_dropbox_connect_succ_revoke",{username:this.settings.dropbox.username})),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("dropbox-revoke-auth-button-hide",""===this.settings.dropbox.username),this.oauth2Info.revokeDiv=void 0}})))),this.registerObsidianProtocolHandler(F,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l,d,c,u,p,h,f,m;if(void 0===e.code||void 0===(null===(t=this.oauth2Info)||void 0===t?void 0:t.verifier))throw new k.Notice(s("protocol_onedrive_connect_fail")),Error(s("protocol_onedrive_connect_unknown",{params:JSON.stringify(e)}));{if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_onedrive_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}const t=yield(u=this.settings.onedrive.clientID,p=this.settings.onedrive.authority,h=e.code,f=this.oauth2Info.verifier,m=e=>r(this,void 0,void 0,(function*(){new k.Notice(s("protocol_onedrive_connect_fail")),new k.Notice(`${e}`)})),r(void 0,void 0,void 0,(function*(){try{const e=yield(0,k.request)({url:`${p}/oauth2/v2.0/token`,method:"POST",contentType:"application/x-www-form-urlencoded",body:new URLSearchParams({tenant:"consumers",client_id:u,scope:zx.join(" "),code:h,redirect_uri:Nx,grant_type:"authorization_code",code_verifier:f}).toString()}),t=JSON.parse(e);return t.error,t}catch(e){console.error(e),yield m(e)}})));if(void 0!==t.error)throw new k.Notice(`${JSON.stringify(t)}`),Error(`${JSON.stringify(t)}`);const g=this;l=this.settings.onedrive,d=t,c=()=>g.saveSettings(),r(void 0,void 0,void 0,(function*(){console.info("start updating local info of OneDrive token"),l.accessToken=d.access_token,l.accessTokenExpiresAtTime=Date.now()+d.expires_in-3e5,l.accessTokenExpiresInSeconds=d.expires_in,l.refreshToken=d.refresh_token,l.credentialsShouldBeDeletedAtTime=Date.now()+D,void 0!==c&&(yield c()),console.info("finish updating local info of Onedrive token")}));const y=Ej(this.settings,this.app.vault.getName(),(()=>g.saveSettings()));this.settings.onedrive.username=yield y.getUserDisplayName(),yield this.saveSettings(),this.oauth2Info.verifier="",null===(i=this.oauth2Info.helperModal)||void 0===i||i.close(),this.oauth2Info.helperModal=void 0,null===(n=this.oauth2Info.authDiv)||void 0===n||n.toggleClass("onedrive-auth-button-hide",""!==this.settings.onedrive.username),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_onedrive_connect_succ_revoke",{username:this.settings.onedrive.username})),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("onedrive-revoke-auth-button-hide",""===this.settings.onedrive.username),this.oauth2Info.revokeDiv=void 0}})))),this.registerObsidianProtocolHandler(Q,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l,d,c,u,p,h,f,m;if(void 0===e.code||void 0===(null===(t=this.oauth2Info)||void 0===t?void 0:t.verifier))throw new k.Notice(s("protocol_onedrivefull_connect_fail")),Error(s("protocol_onedrivefull_connect_unknown",{params:JSON.stringify(e)}));{if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_onedrivefull_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}const t=yield(u=this.settings.onedrivefull.clientID,p=this.settings.onedrivefull.authority,h=e.code,f=this.oauth2Info.verifier,m=e=>r(this,void 0,void 0,(function*(){new k.Notice(s("protocol_onedrivefull_connect_fail")),new k.Notice(`${e}`)})),r(void 0,void 0,void 0,(function*(){try{const e=yield(0,k.request)({url:`${p}/oauth2/v2.0/token`,method:"POST",contentType:"application/x-www-form-urlencoded",body:new URLSearchParams({tenant:"consumers",client_id:u,scope:r_.join(" "),code:h,redirect_uri:i_,grant_type:"authorization_code",code_verifier:f}).toString()}),t=JSON.parse(e);return t.error,t}catch(e){console.error(e),yield m(e)}})));if(void 0!==t.error)throw new k.Notice(`${JSON.stringify(t)}`),Error(`${JSON.stringify(t)}`);const g=this;l=this.settings.onedrivefull,d=t,c=()=>g.saveSettings(),r(void 0,void 0,void 0,(function*(){console.info("start updating local info of OneDrive token"),l.accessToken=d.access_token,l.accessTokenExpiresAtTime=Date.now()+d.expires_in-3e5,l.accessTokenExpiresInSeconds=d.expires_in,l.refreshToken=d.refresh_token,l.credentialsShouldBeDeletedAtTime=Date.now()+D,void 0!==c&&(yield c()),console.info("finish updating local info of Onedrive token")}));const y=Ej(this.settings,this.app.vault.getName(),(()=>g.saveSettings()));this.settings.onedrivefull.username=yield y.getUserDisplayName(),yield this.saveSettings(),this.oauth2Info.verifier="",null===(i=this.oauth2Info.helperModal)||void 0===i||i.close(),this.oauth2Info.helperModal=void 0,null===(n=this.oauth2Info.authDiv)||void 0===n||n.toggleClass("onedrivefull-auth-button-hide",""!==this.settings.onedrivefull.username),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_onedrivefull_connect_succ_revoke",{username:this.settings.onedrivefull.username})),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("onedrivefull-revoke-auth-button-hide",""===this.settings.onedrivefull.username),this.oauth2Info.revokeDiv=void 0}})))),this.registerObsidianProtocolHandler(P,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l,d;if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_pro_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}console.debug(e);const c=yield le(this.oauth2Info.verifier||"verifier",e.code,(e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_pro_connect_fail")),new k.Notice(`${e}`),e}))));console.debug(c);const u=this;yield de(this.settings.pro,c,(()=>u.saveSettings())),yield ue(this.settings.pro,this.manifest.version,(()=>u.saveSettings())),yield pe(this.settings.pro,this.manifest.version,(()=>u.saveSettings())),this.oauth2Info.verifier="",null===(t=this.oauth2Info.helperModal)||void 0===t||t.close(),this.oauth2Info.helperModal=void 0,null===(i=this.oauth2Info.authDiv)||void 0===i||i.toggleClass("pro-auth-button-hide",""!==(null===(n=this.settings.pro)||void 0===n?void 0:n.refreshToken)),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_pro_connect_succ_revoke",{email:null===(a=this.settings.pro)||void 0===a?void 0:a.email})),this.oauth2Info.revokeAuthSetting=void 0,null===(l=this.oauth2Info.revokeDiv)||void 0===l||l.toggleClass("pro-revoke-auth-button-hide",""===(null===(d=this.settings.pro)||void 0===d?void 0:d.email)),this.oauth2Info.revokeDiv=void 0})))),this.registerObsidianProtocolHandler(q,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l;if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_box_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}console.debug(e);const d=yield(c=e.code,u=e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_box_connect_fail")),new k.Notice(`${e}`),e})),r(void 0,void 0,void 0,(function*(){try{const e={code:c,grant_type:"authorization_code",client_id:U,client_secret:L},t=yield fetch("https://api.box.com/oauth2/token",{method:"POST",body:new URLSearchParams(e)});return yield t.json()}catch(e){console.error(e),void 0!==u&&(yield u(e))}})));var c,u;console.debug(d);const p=this;yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){if(void 0===t.access_token||""===t.access_token)throw Error(`remotely save account auth failed, please auth again: ${JSON.stringify(t)}`);e.accessToken=t.access_token,e.accessTokenExpiresAtTimeMs=Date.now()+1e3*t.expires_in-3e5,e.accessTokenExpiresInMs=1e3*t.expires_in,e.refreshToken=t.refresh_token||e.refreshToken,e.credentialsShouldBeDeletedAtTimeMs=Date.now()+50976e5,yield null==i?void 0:i(),console.info("finish updating local info of Box token")})))(this.settings.box,d,(()=>p.saveSettings())),this.oauth2Info.verifier="",null===(t=this.oauth2Info.helperModal)||void 0===t||t.close(),this.oauth2Info.helperModal=void 0,null===(i=this.oauth2Info.authDiv)||void 0===i||i.toggleClass("box-auth-button-hide",""!==(null===(n=this.settings.box)||void 0===n?void 0:n.refreshToken)),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_box_connect_succ_revoke")),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("box-revoke-auth-button-hide",""===(null===(l=this.settings.box)||void 0===l?void 0:l.refreshToken)),this.oauth2Info.revokeDiv=void 0})))),this.registerObsidianProtocolHandler(j,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l;if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_pcloud_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}console.debug(e);const d=yield(c=e.hostname,u=e.code,p=e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_pcloud_connect_fail")),new k.Notice(`${e}`),e})),r(void 0,void 0,void 0,(function*(){const e=H,t=$;try{const r={code:u,client_id:e,client_secret:t},i=yield fetch(`https://${c}/oauth2_token`,{method:"POST",body:new URLSearchParams(r)}),n=yield i.json();if(0!==(null==n?void 0:n.result))throw Error("result is not 0 (success) in the end");if(!("access_token"in n))throw Error("no access_token in the end");return n}catch(e){console.error(e),void 0!==p&&(yield p(e))}})));var c,u,p;console.debug(d);const h=this;yield((e,t,i,n)=>r(void 0,void 0,void 0,(function*(){if(void 0===i)throw Error("remotely save account auth failed, please auth again: undefined result");e.accessToken=i.access_token,e.hostname=t.hostname,e.locationid=t.locationid,e.credentialsShouldBeDeletedAtTimeMs=Date.now()+D,yield null==n?void 0:n(),console.info("finish updating local info of pCloud token")})))(this.settings.pcloud,e,d,(()=>h.saveSettings())),this.oauth2Info.verifier="",null===(t=this.oauth2Info.helperModal)||void 0===t||t.close(),this.oauth2Info.helperModal=void 0,null===(i=this.oauth2Info.authDiv)||void 0===i||i.toggleClass("pcloud-auth-button-hide",""!==(null===(n=this.settings.pcloud)||void 0===n?void 0:n.accessToken)),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_pcloud_connect_succ_revoke")),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("pcloud-revoke-auth-button-hide",""===(null===(l=this.settings.pcloud)||void 0===l?void 0:l.accessToken)),this.oauth2Info.revokeDiv=void 0})))),this.registerObsidianProtocolHandler(G,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l;if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_yandexdisk_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}console.debug(e);const d=yield(c=e.code,u=e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_yandexdisk_connect_fail")),new k.Notice(`${e}`),e})),r(void 0,void 0,void 0,(function*(){try{const e={code:c,grant_type:"authorization_code",client_id:W,client_secret:K},t=yield fetch("https://oauth.yandex.com/token",{method:"POST",body:new URLSearchParams(e)});if(200!==t.status){const e=yield t.json();throw Error(JSON.stringify(e))}return yield t.json()}catch(e){console.error(e),void 0!==u&&(yield u(e))}})));var c,u;console.debug(d);const p=this;yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){if(void 0===t.access_token||""===t.access_token)throw Error(`remotely save account auth failed, please auth again: ${JSON.stringify(t)}`);e.accessToken=t.access_token,e.accessTokenExpiresAtTimeMs=Date.now()+1e3*t.expires_in-3e5,e.accessTokenExpiresInMs=1e3*t.expires_in,e.refreshToken=t.refresh_token||e.refreshToken,e.credentialsShouldBeDeletedAtTimeMs=Date.now()+50976e5,yield null==i?void 0:i(),console.info("finish updating local info of Yandex Disk token")})))(this.settings.yandexdisk,d,(()=>p.saveSettings())),this.oauth2Info.verifier="",null===(t=this.oauth2Info.helperModal)||void 0===t||t.close(),this.oauth2Info.helperModal=void 0,null===(i=this.oauth2Info.authDiv)||void 0===i||i.toggleClass("yandexdisk-auth-button-hide",""!==(null===(n=this.settings.yandexdisk)||void 0===n?void 0:n.refreshToken)),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_yandexdisk_connect_succ_revoke")),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("yandexdisk-revoke-auth-button-hide",""===(null===(l=this.settings.yandexdisk)||void 0===l?void 0:l.refreshToken)),this.oauth2Info.revokeDiv=void 0})))),this.registerObsidianProtocolHandler(V,(e=>r(this,void 0,void 0,(function*(){var t,i,n,o,a,l;if(void 0!==this.oauth2Info.helperModal){const e=this.oauth2Info.helperModal.contentEl;e.empty(),s("protocol_koofr_connecting").split("\n").forEach((t=>{e.createEl("p",{text:t})}))}console.debug(e);const d=yield(c=this.settings.koofr.api,u=e.code,p=e=>r(this,void 0,void 0,(function*(){throw new k.Notice(s("protocol_koofr_connect_fail")),new k.Notice(`${e}`),e})),h=!0,r(void 0,void 0,void 0,(function*(){let e="urn:ietf:wg:oauth:2.0:oob";h&&(e=`obsidian://${V}`);try{const t={code:u,grant_type:"authorization_code",client_id:J,client_secret:Y,redirect_uri:e},r=yield fetch(`${c}/oauth2/token`,{method:"POST",body:new URLSearchParams(t)});if(200!==r.status){const e=yield r.json();throw Error(JSON.stringify(e))}return yield r.json()}catch(e){console.error(e),void 0!==p&&(yield p(e))}})));var c,u,p,h;console.debug(d);const f=this;yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){if(void 0===t.access_token||""===t.access_token)throw Error(`remotely save account auth failed, please auth again: ${JSON.stringify(t)}`);e.accessToken=t.access_token,e.accessTokenExpiresAtTimeMs=Date.now()+1e3*t.expires_in-3e5,e.accessTokenExpiresInMs=1e3*t.expires_in,e.refreshToken=t.refresh_token||e.refreshToken,e.scope=t.scope||e.scope,e.credentialsShouldBeDeletedAtTimeMs=Date.now()+50976e5,yield null==i?void 0:i(),console.info("finish updating local info of Koofr token")})))(this.settings.koofr,d,(()=>f.saveSettings())),this.oauth2Info.verifier="",null===(t=this.oauth2Info.helperModal)||void 0===t||t.close(),this.oauth2Info.helperModal=void 0,null===(i=this.oauth2Info.authDiv)||void 0===i||i.toggleClass("koofr-auth-button-hide",""!==(null===(n=this.settings.koofr)||void 0===n?void 0:n.refreshToken)),this.oauth2Info.authDiv=void 0,null===(o=this.oauth2Info.revokeAuthSetting)||void 0===o||o.setDesc(s("protocol_koofr_connect_succ_revoke")),this.oauth2Info.revokeAuthSetting=void 0,null===(a=this.oauth2Info.revokeDiv)||void 0===a||a.toggleClass("koofr-revoke-auth-button-hide",""===(null===(l=this.settings.koofr)||void 0===l?void 0:l.refreshToken)),this.oauth2Info.revokeDiv=void 0})))),this.syncRibbon=this.addRibbonIcon(NH,`${this.manifest.name}`,(()=>r(this,void 0,void 0,(function*(){return this.syncRun("manual")})))),this.enableMobileStatusBarIfSet(),(!k.Platform.isMobile||k.Platform.isMobile&&this.settings.enableMobileStatusBar)&&!0===this.settings.enableStatusBarInfo){const e=this.addStatusBarItem();this.statusBarElement=e.createEl("span"),this.statusBarElement.setAttribute("data-tooltip-position","top"),this.isSyncing||this.updateLastSyncMsg(void 0,"not_syncing",yield O_(this.db,this.vaultRandomID),yield N_(this.db,this.vaultRandomID)),this.registerInterval(window.setInterval((()=>r(this,void 0,void 0,(function*(){this.isSyncing||this.updateLastSyncMsg(void 0,"not_syncing",yield O_(this.db,this.vaultRandomID),yield N_(this.db,this.vaultRandomID))}))),3e4))}if(this.addCommand({id:"start-sync",name:s("command_startsync"),icon:NH,callback:()=>r(this,void 0,void 0,(function*(){this.syncRun("manual")}))}),this.addCommand({id:"start-sync-dry-run",name:s("command_drynrun"),icon:NH,callback:()=>r(this,void 0,void 0,(function*(){this.syncRun("dry")}))}),this.addCommand({id:"export-sync-plans-1-only-change",name:s("command_exportsyncplans_1_only_change"),icon:UH,callback:()=>r(this,void 0,void 0,(function*(){yield ux(this.db,this.app.vault,this.vaultRandomID,1,!0),new k.Notice(s("settings_syncplans_notice"))}))}),this.addCommand({id:"export-sync-plans-1",name:s("command_exportsyncplans_1"),icon:UH,callback:()=>r(this,void 0,void 0,(function*(){yield ux(this.db,this.app.vault,this.vaultRandomID,1,!1),new k.Notice(s("settings_syncplans_notice"))}))}),this.addCommand({id:"export-sync-plans-5",name:s("command_exportsyncplans_5"),icon:UH,callback:()=>r(this,void 0,void 0,(function*(){yield ux(this.db,this.app.vault,this.vaultRandomID,5,!1),new k.Notice(s("settings_syncplans_notice"))}))}),this.addCommand({id:"export-sync-plans-all",name:s("command_exportsyncplans_all"),icon:UH,callback:()=>r(this,void 0,void 0,(function*(){yield ux(this.db,this.app.vault,this.vaultRandomID,-1,!1),new k.Notice(s("settings_syncplans_notice"))}))}),this.addSettingTab(new PH(this.app,this)),this.enableCheckingFileStat(),this.settings.agreeToUseSyncV3)this.enableAutoSyncIfSet(),this.enableInitSyncIfSet(),this.toggleSyncOnSaveIfSet();else{new OH(this.app,this).open()}const{oldVersion:d}=yield(c=this.db,u=this.vaultRandomID,p=this.manifest.version,r(void 0,void 0,void 0,(function*(){let e=yield c.simpleKVForMiscTbl.getItem(`${u}-pluginversion`);return null===e&&(e="0.0.0"),yield c.simpleKVForMiscTbl.setItem(`${u}-pluginversion`,p),{oldVersion:e,newVersion:p}})));var c,u,p}))}onunload(){return r(this,void 0,void 0,(function*(){console.info(`unloading plugin ${this.manifest.id}`),this.syncRibbon=void 0,void 0!==this.appContainerObserver&&(this.appContainerObserver.disconnect(),this.appContainerObserver=void 0),void 0!==this.oauth2Info&&(this.oauth2Info.helperModal=void 0,this.oauth2Info={verifier:"",helperModal:void 0,authDiv:void 0,revokeDiv:void 0,revokeAuthSetting:void 0})}))}loadSettings(){return r(this,void 0,void 0,(function*(){this.settings=Object.assign({},m()(zH),dx(yield this.loadData())),void 0===this.settings.syncBookmarks&&(this.settings.syncBookmarks=!1),""===this.settings.dropbox.clientID&&(this.settings.dropbox.clientID=zH.dropbox.clientID),void 0===this.settings.dropbox.remoteBaseDir&&(this.settings.dropbox.remoteBaseDir=""),""===this.settings.onedrive.clientID&&(this.settings.onedrive.clientID=zH.onedrive.clientID),""===this.settings.onedrive.authority&&(this.settings.onedrive.authority=zH.onedrive.authority),void 0===this.settings.onedrive.remoteBaseDir&&(this.settings.onedrive.remoteBaseDir=""),void 0===this.settings.onedrive.emptyFile&&(this.settings.onedrive.emptyFile="skip"),void 0===this.settings.onedrive.kind&&(this.settings.onedrive.kind="onedrive"),void 0===this.settings.onedrivefull&&(this.settings.onedrivefull=n_),void 0===this.settings.webdav.manualRecursive&&(this.settings.webdav.manualRecursive=!0),void 0!==this.settings.webdav.depth&&"auto"!==this.settings.webdav.depth&&"auto_1"!==this.settings.webdav.depth&&"auto_infinity"!==this.settings.webdav.depth&&"auto_unknown"!==this.settings.webdav.depth||(this.settings.webdav.depth="manual_1",this.settings.webdav.manualRecursive=!0),void 0===this.settings.webdav.remoteBaseDir&&(this.settings.webdav.remoteBaseDir=""),void 0===this.settings.webdav.customHeaders&&(this.settings.webdav.customHeaders=""),void 0===this.settings.s3.partsConcurrency&&(this.settings.s3.partsConcurrency=20),void 0===this.settings.s3.forcePathStyle&&(this.settings.s3.forcePathStyle=!1),void 0===this.settings.s3.remotePrefix&&(this.settings.s3.remotePrefix=""),void 0===this.settings.s3.useAccurateMTime&&(this.settings.s3.useAccurateMTime=!1),void 0===this.settings.s3.generateFolderObject&&(this.settings.s3.generateFolderObject=!1),void 0===this.settings.ignorePaths&&(this.settings.ignorePaths=[]),void 0===this.settings.onlyAllowPaths&&(this.settings.onlyAllowPaths=[]),void 0===this.settings.enableStatusBarInfo&&(this.settings.enableStatusBarInfo=!0),void 0===this.settings.syncOnSaveAfterMilliseconds&&(this.settings.syncOnSaveAfterMilliseconds=-1),void 0===this.settings.deleteToWhere&&(this.settings.deleteToWhere="system"),this.settings.logToDB=!1,(0,k.requireApiVersion)(e_)&&(this.settings.s3.bypassCorsLocally=!0),void 0===this.settings.agreeToUseSyncV3&&(this.settings.agreeToUseSyncV3=!1),void 0===this.settings.conflictAction&&(this.settings.conflictAction="keep_newer"),void 0===this.settings.howToCleanEmptyFolder&&(this.settings.howToCleanEmptyFolder="clean_both"),void 0===this.settings.protectModifyPercentage&&(this.settings.protectModifyPercentage=50),void 0===this.settings.syncDirection&&(this.settings.syncDirection="bidirectional"),void 0===this.settings.obfuscateSettingFile&&(this.settings.obfuscateSettingFile=!0),void 0===this.settings.enableMobileStatusBar&&(this.settings.enableMobileStatusBar=!1),void 0!==this.settings.encryptionMethod&&"unknown"!==this.settings.encryptionMethod||(void 0===this.settings.password||""===this.settings.password?this.settings.encryptionMethod="rclone-base64":this.settings.encryptionMethod="openssl-base64"),void 0===this.settings.profiler&&(this.settings.profiler=iH),void 0===this.settings.profiler.enable&&(this.settings.profiler.enable=!1),void 0===this.settings.profiler.enablePrinting&&(this.settings.profiler.enablePrinting=!1),void 0===this.settings.profiler.recordSize&&(this.settings.profiler.recordSize=!1),void 0===this.settings.googledrive&&(this.settings.googledrive=Sh),void 0===this.settings.box&&(this.settings.box=bh),void 0===this.settings.pcloud&&(this.settings.pcloud=p_),void 0===this.settings.yandexdisk&&(this.settings.yandexdisk=y_),void 0===this.settings.koofr&&(this.settings.koofr=Nh),void 0===this.settings.azureblobstorage&&(this.settings.azureblobstorage=nh),yield this.saveSettings()}))}saveSettings(){return r(this,void 0,void 0,(function*(){this.settings.obfuscateSettingFile?yield this.saveData((e=>null==e?(console.debug("the normal config is null or undefined, skip"),e):{readme:"The file contains sensitive info, so DO NOT take screenshot of, copy, or share it to anyone! It's also generated automatically, so do not edit it manually.",d:Wp(ne(lx.from(JSON.stringify(e),"utf-8"),{pad:!1}))})(this.settings)):yield this.saveData(this.settings)}))}getCurrProfileID(){if(void 0!==this.settings.serviceType)return`${this.settings.serviceType}-default-1`;throw Error("unknown serviceType in the setting!")}checkIfOauthExpires(){return r(this,void 0,void 0,(function*(){let e=!1;const t=Date.now();""!==this.settings.dropbox.refreshToken&&void 0===this.settings.dropbox.credentialsShouldBeDeletedAtTime&&(this.settings.dropbox.credentialsShouldBeDeletedAtTime=t+2592e6,e=!0),""!==this.settings.onedrive.refreshToken&&void 0===this.settings.onedrive.credentialsShouldBeDeletedAtTime&&(this.settings.onedrive.credentialsShouldBeDeletedAtTime=t+2592e6,e=!0);let r=!1;""!==this.settings.dropbox.refreshToken&&t>=this.settings.dropbox.credentialsShouldBeDeletedAtTime&&(console.warn("dropbox expired"),r=!0,this.settings.dropbox=m()(gx),e=!0);let i=!1;""!==this.settings.onedrive.refreshToken&&t>=this.settings.onedrive.credentialsShouldBeDeletedAtTime&&(console.warn("onedrive expired"),i=!0,this.settings.onedrive=m()(qx),e=!0);let n=!1;""!==this.settings.onedrivefull.refreshToken&&t>=this.settings.onedrivefull.credentialsShouldBeDeletedAtTime&&(console.warn("onedrive full expired"),n=!0,this.settings.onedrivefull=m()(n_),e=!0);let o=!1;""!==this.settings.googledrive.refreshToken&&t>=this.settings.googledrive.credentialsShouldBeDeletedAtTimeMs&&(console.warn("google drive expired"),o=!0,this.settings.googledrive=m()(Sh),e=!0);let s=!1;""!==this.settings.box.refreshToken&&t>=this.settings.box.credentialsShouldBeDeletedAtTimeMs&&(console.warn("box expired"),s=!0,this.settings.box=m()(bh),e=!0);let a=!1;""!==this.settings.pcloud.accessToken&&t>=this.settings.pcloud.credentialsShouldBeDeletedAtTimeMs&&(console.warn("pcloud expired"),a=!0,this.settings.pcloud=m()(p_),e=!0);let l=!1;""!==this.settings.yandexdisk.refreshToken&&t>=this.settings.yandexdisk.credentialsShouldBeDeletedAtTimeMs&&(console.warn("yandex disk expired"),l=!0,this.settings.yandexdisk=m()(y_),e=!0);let d=!1;""!==this.settings.koofr.refreshToken&&t>=this.settings.koofr.credentialsShouldBeDeletedAtTimeMs&&(console.warn("koofr expired"),d=!0,this.settings.koofr=m()(Nh),e=!0),void 0===this.settings.pro&&(this.settings.pro=m()(se)),e&&(yield this.saveSettings()),r&&new k.Notice(`${this.manifest.name}: You haven't manually auth Dropbox for many days, you need to re-auth it again.`,6e3),i&&new k.Notice(`${this.manifest.name}: You haven't manually auth OneDrive (App Folder) for many days, you need to re-auth it again.`,6e3),n&&new k.Notice(`${this.manifest.name}: You haven't manually auth OneDrive (Full) for many days, you need to re-auth it again.`,6e3),o&&new k.Notice(`${this.manifest.name}: You haven't manually auth Google Drive for many days, you need to re-auth it again.`,6e3),s&&new k.Notice(`${this.manifest.name}: You haven't manually auth Box for many days, you need to re-auth it again.`,6e3),a&&new k.Notice(`${this.manifest.name}: You haven't manually auth pCloud for many days, you need to re-auth it again.`,6e3),l&&new k.Notice(`${this.manifest.name}: You haven't manually auth Yandex Disk for many days, you need to re-auth it again.`,6e3),d&&new k.Notice(`${this.manifest.name}: You haven't manually auth koofr for many days, you need to re-auth it again.`,6e3)}))}getVaultRandomIDFromOldConfigFile(){return r(this,void 0,void 0,(function*(){let e="";return void 0!==this.settings.vaultRandomID&&(""!==this.settings.vaultRandomID&&(e=this.settings.vaultRandomID),console.debug("vaultRandomID is no longer saved in data.json"),delete this.settings.vaultRandomID,yield this.saveSettings()),e}))}trash(e){return r(this,void 0,void 0,(function*(){"obsidian"===this.settings.deleteToWhere?yield this.app.vault.adapter.trashLocal(e):(yield this.app.vault.adapter.trashSystem(e))||(yield this.app.vault.adapter.trashLocal(e))}))}getVaultBasePath(){return this.app.vault.adapter instanceof k.FileSystemAdapter?this.app.vault.adapter.getBasePath().split("?")[0]:this.app.vault.adapter.getResourcePath("").split("?")[0]}prepareDBAndVaultRandomID(e,t,i){return r(this,void 0,void 0,(function*(){const{db:n,vaultRandomID:o}=yield((e,t,i)=>r(void 0,void 0,void 0,(function*(){var r;const n={versionTbl:E_().createInstance({name:I_,storeName:"schemaversion"}),syncPlansTbl:E_().createInstance({name:I_,storeName:"syncplanshistory"}),vaultRandomIDMappingTbl:E_().createInstance({name:I_,storeName:"vaultrandomidmapping"}),loggerOutputTbl:E_().createInstance({name:I_,storeName:"loggeroutput"}),simpleKVForMiscTbl:E_().createInstance({name:I_,storeName:"simplekvformisc"}),prevSyncRecordsTbl:E_().createInstance({name:I_,storeName:"prevsyncrecords"}),profilerResultsTbl:E_().createInstance({name:I_,storeName:"profilerresults"}),fileHistoryTbl:E_().createInstance({name:I_,storeName:"filefolderoperationhistory"}),syncMappingTbl:E_().createInstance({name:I_,storeName:"syncmetadatahistory"}),fileContentHistoryTbl:E_().createInstance({name:I_,storeName:"filecontenthistory"})};let o="";const s=yield n.vaultRandomIDMappingTbl.getItem(`path2id\t${e}`);if(null===s?(o=""!==t?t:E(),yield n.vaultRandomIDMappingTbl.setItem(`path2id\t${e}`,o),yield n.vaultRandomIDMappingTbl.setItem(`id2path\t${o}`,e)):o=s,""===o)throw Error("no vaultRandomID found or generated");const a=null!==(r=yield n.versionTbl.getItem(`${o}\tversion`))&&void 0!==r?r:yield n.versionTbl.getItem("version");return null===a?(console.debug("no internal db version, setting it to 20240220"),yield n.versionTbl.setItem(`${o}\tversion`,C_)):a===C_||(console.debug(`trying to upgrade db version from ${a} to 20240220`),yield A_(n,a,C_,o,i)),console.info("db connected"),{db:n,vaultRandomID:o}})))(e,t,i);this.db=n,this.vaultRandomID=o}))}enableAutoSyncIfSet(){void 0!==this.settings.autoRunEveryMilliseconds&&null!==this.settings.autoRunEveryMilliseconds&&this.settings.autoRunEveryMilliseconds>0&&this.app.workspace.onLayoutReady((()=>{const e=window.setInterval((()=>{this.syncRun("auto")}),this.settings.autoRunEveryMilliseconds);this.autoRunIntervalID=e,this.registerInterval(e)}))}enableInitSyncIfSet(){void 0!==this.settings.initRunAfterMilliseconds&&null!==this.settings.initRunAfterMilliseconds&&this.settings.initRunAfterMilliseconds>0&&this.app.workspace.onLayoutReady((()=>{window.setTimeout((()=>{this.syncRun("auto_once_init")}),this.settings.initRunAfterMilliseconds)}))}_checkCurrFileModified(e){return r(this,void 0,void 0,(function*(){console.debug("inside checkCurrFileModified");const t=this.app.workspace.getActiveFile();if(t){console.debug(`we have currentFile=${t.path}`);const r=t.stat.mtime,i=yield O_(this.db,this.vaultRandomID);if(console.debug(`lastModified=${r}, lastSuccessSyncMillis=${i}`),"SYNC"===e||"FILE_CHANGES"===e&&r>(null!=i?i:1))return console.debug("so lastModified > lastSuccessSyncMillis or it's called while syncing before"),console.debug(`caller=${e}, isSyncing=${this.isSyncing}, hasPendingSyncOnSave=${this.hasPendingSyncOnSave}`),this.isSyncing?void(this.hasPendingSyncOnSave=!0):void((this.hasPendingSyncOnSave||"FILE_CHANGES"===e)&&(this.hasPendingSyncOnSave=!1,yield this.syncRun("auto_sync_on_save")))}else console.debug("no currentFile here")}))}toggleSyncOnSaveIfSet(){var e;void 0!==this.settings.syncOnSaveAfterMilliseconds&&null!==this.settings.syncOnSaveAfterMilliseconds&&this.settings.syncOnSaveAfterMilliseconds>0?this.app.workspace.onLayoutReady((()=>{var e;this.registerEvent(null===(e=this.syncEvent)||void 0===e?void 0:e.on("SYNC_DONE",this._syncOnSaveEvent1)),this.registerEvent(this.app.vault.on("modify",this._syncOnSaveEvent2)),this.registerEvent(this.app.vault.on("create",this._syncOnSaveEvent2)),this.registerEvent(this.app.vault.on("delete",this._syncOnSaveEvent2)),this.registerEvent(this.app.vault.on("rename",this._syncOnSaveEvent2))})):(null===(e=this.syncEvent)||void 0===e||e.off("SYNC_DONE",this._syncOnSaveEvent1),this.app.vault.off("modify",this._syncOnSaveEvent2),this.app.vault.off("create",this._syncOnSaveEvent2),this.app.vault.off("delete",this._syncOnSaveEvent2),this.app.vault.off("rename",this._syncOnSaveEvent2))}enableMobileStatusBarIfSet(){this.app.workspace.onLayoutReady((()=>{k.Platform.isMobile&&this.settings.enableMobileStatusBar&&(this.appContainerObserver=Xp("enable"))}))}enableCheckingFileStat(){this.app.workspace.onLayoutReady((()=>{const e=(e,t)=>this.i18n.t(e,t);this.registerEvent(this.app.workspace.on("file-menu",((t,i)=>{i instanceof k.TFolder||t.addItem((t=>{t.setTitle(e("menu_check_file_stat")).setIcon("file-cog").onClick((()=>r(this,void 0,void 0,(function*(){var e,t,r;const n=i.path,o=new Cj(this.app.vault,null!==(e=this.settings.syncConfigDir)&&void 0!==e&&e,null!==(t=this.settings.syncBookmarks)&&void 0!==t&&t,this.app.vault.configDir,this.manifest.id,void 0,null!==(r=this.settings.deleteToWhere)&&void 0!==r?r:"system"),s=yield o.stat(n);new k.Notice(JSON.stringify(s,null,2),1e4)}))))}))})))}))}saveAgreeToUseNewSyncAlgorithm(){return r(this,void 0,void 0,(function*(){this.settings.agreeToUseSyncV3=!0,yield this.saveSettings()}))}setCurrSyncMsg(e,t,r,i,n,o,s){const a=`${i}`.length,l=`${r}`.padStart(a,"0"),d=LH(e,t),c=d+`Syncing ${l}/${i}`,u=d+`Syncing progress=${l}/${i},decision=${o},path=${n},source=${s}`;this.currSyncMsg=u,void 0!==this.statusBarElement&&(this.statusBarElement.setText(c),this.statusBarElement.setAttribute("aria-label",u))}updateLastSyncMsg(e,t,r,i){if(void 0===this.statusBarElement)return;const n=(e,t)=>this.i18n.t(e,t);let o=n("statusbar_lastsync_never"),s=n("statusbar_lastsync_never_label");const a=Math.max(null!=r?r:-999,null!=i?i:-999),l=(null!=r?r:-999)>=(null!=i?i:-999);if("syncing"===t)o=LH(n,e)+n("statusbar_syncing");else if(a>0){let e="";e=n(l?"statusbar_sync_status_prefix_success":"statusbar_sync_status_prefix_failed");const t=Date.now()-a,r=Math.floor(t/31556952e3),i=Math.floor(t/2629746e3),d=Math.floor(t/6048e5),c=Math.floor(t/864e5),u=Math.floor(t/36e5),p=Math.floor(t/6e4),h=Math.floor(t/1e3);let f="";f=r>0?n("statusbar_time_years",{time:r}):i>0?n("statusbar_time_months",{time:i}):d>0?n("statusbar_time_weeks",{time:d}):c>0?n("statusbar_time_days",{time:c}):u>0?n("statusbar_time_hours",{time:u}):p>0?n("statusbar_time_minutes",{time:p}):n(h>30?"statusbar_time_lessminute":"statusbar_time_now");o=e+f,s=e+n("statusbar_lastsync_label",{date:new Date(a).toLocaleTimeString(navigator.language,{weekday:"long",year:"numeric",month:"long",day:"numeric"})})}this.statusBarElement.setText(o),this.statusBarElement.setAttribute("aria-label",s)}tryToAddIgnoreFile(){return r(this,void 0,void 0,(function*(){const e=this.manifest.dir||`${this.app.vault.configDir}/plugins/${this.manifest.dir}`;if(!(yield this.app.vault.adapter.exists(e)))return;const t=`${e}/.gitignore`,r=yield this.app.vault.adapter.exists(t);try{r||this.app.vault.adapter.write(t,"data.json\n")}catch(e){}}))}enableAutoClearOutputToDBHistIfSet(){this.app.workspace.onLayoutReady((()=>{window.setTimeout((()=>{var e;e=this.db,r(void 0,void 0,void 0,(function*(){yield e.loggerOutputTbl.clear(),console.debug("successfully clearAllLoggerOutputRecords")}))}),3e4)}))}enableAutoClearSyncPlanHist(){this.app.workspace.onLayoutReady((()=>{window.setTimeout((()=>{M_(this.db)}),45e3);const e=window.setInterval((()=>{M_(this.db)}),3e5);this.registerInterval(e)}))}}})();var __webpack_export_target__=exports;for(var i in __webpack_exports__)__webpack_export_target__[i]=__webpack_exports__[i];__webpack_exports__.__esModule&&Object.defineProperty(__webpack_export_target__,"__esModule",{value:!0})})(); +/* nosourcemap */ \ No newline at end of file diff --git a/.vaults/.obsidian/plugins/remotely-save/manifest.json b/.vaults/.obsidian/plugins/remotely-save/manifest.json new file mode 100644 index 0000000..33b159f --- /dev/null +++ b/.vaults/.obsidian/plugins/remotely-save/manifest.json @@ -0,0 +1,11 @@ +{ + "id": "remotely-save", + "name": "Remotely Save", + "version": "0.5.25", + "minAppVersion": "0.13.21", + "description": "Yet another unofficial plugin allowing users to synchronize notes between local device and the cloud service.", + "author": "fyears", + "authorUrl": "https://github.com/fyears", + "isDesktopOnly": false, + "fundingUrl": "https://remotelysave.com" +} diff --git a/.vaults/.obsidian/plugins/remotely-save/styles.css b/.vaults/.obsidian/plugins/remotely-save/styles.css new file mode 100644 index 0000000..4726ee4 --- /dev/null +++ b/.vaults/.obsidian/plugins/remotely-save/styles.css @@ -0,0 +1,244 @@ +/* set the styles */ + +.password-second-confirm { + font-weight: bold; +} + +.password-disclaimer { + font-weight: bold; +} + +.encryptionmethod-second-confirm { + font-weight: bold; +} + +.settings-auth-related { + border-top: 1px solid var(--background-modifier-border); + padding-top: 18px; +} + +.settings-percentage-custom-hide { + display: none; +} + +.settings-encryption-method-hide { + display: none; +} + +.s3-disclaimer { + font-weight: bold; +} +.s3-hide { + display: none; +} + +.dropbox-disclaimer { + font-weight: bold; +} +.dropbox-hide { + display: none; +} + +.dropbox-auth-button-hide { + display: none; +} + +.dropbox-revoke-auth-button-hide { + display: none; +} + +.onedrive-disclaimer { + font-weight: bold; +} +.onedrive-hide { + display: none; +} + +.onedrive-auth-button-hide { + display: none; +} + +.onedrive-revoke-auth-button-hide { + display: none; +} + +.onedrivefull-allow-to-use-hide { + display: none; +} + +.onedrivefull-disclaimer { + font-weight: bold; +} +.onedrivefull-hide { + display: none; +} + +.onedrivefull-auth-button-hide { + display: none; +} + +.onedrivefull-revoke-auth-button-hide { + display: none; +} + +.webdav-disclaimer { + font-weight: bold; +} +.webdav-hide { + display: none; +} + +.webdav-customheaders-textarea { + font-family: monospace; +} + +.webdis-disclaimer { + font-weight: bold; +} +.webdis-hide { + display: none; +} + +.googledrive-disclaimer { + font-weight: bold; +} +.googledrive-hide { + display: none; +} + +.googledrive-allow-to-use-hide { + display: none; +} + +.googledrive-auth-button-hide { + display: none; +} + +.googledrive-revoke-auth-button-hide { + display: none; +} + +.box-disclaimer { + font-weight: bold; +} +.box-hide { + display: none; +} + +.box-allow-to-use-hide { + display: none; +} + +.box-auth-button-hide { + display: none; +} + +.box-revoke-auth-button-hide { + display: none; +} + +.pcloud-disclaimer { + font-weight: bold; +} +.pcloud-hide { + display: none; +} + +.pcloud-allow-to-use-hide { + display: none; +} + +.pcloud-auth-button-hide { + display: none; +} + +.pcloud-revoke-auth-button-hide { + display: none; +} + +.yandexdisk-disclaimer { + font-weight: bold; +} +.yandexdisk-hide { + display: none; +} + +.yandexdisk-allow-to-use-hide { + display: none; +} + +.yandexdisk-auth-button-hide { + display: none; +} + +.yandexdisk-revoke-auth-button-hide { + display: none; +} + +.koofr-disclaimer { + font-weight: bold; +} +.koofr-hide { + display: none; +} + +.koofr-allow-to-use-hide { + display: none; +} + +.koofr-auth-button-hide { + display: none; +} + +.koofr-revoke-auth-button-hide { + display: none; +} + +.azureblobstorage-disclaimer { + font-weight: bold; +} +.azureblobstorage-hide { + display: none; +} + +.azureblobstorage-allow-to-use-hide { + display: none; +} + +.qrcode-img { + width: 350px; + height: 350px; +} + +.ignorepaths-textarea { + font-family: monospace; +} + +.onlyallowpaths-textarea { + font-family: monospace; +} + +.logtohttpserver-warning { + color: red; + font-weight: bolder; +} + +.setting-need-wrapping .setting-item-control { + /* flex-wrap: wrap; */ + display: grid; +} + +.pro-disclaimer { + font-weight: bold; +} +.pro-hide { + display: none; +} + +.pro-auth-button-hide { + display: none; +} + +.pro-revoke-auth-button-hide { + display: none; +} diff --git a/.vaults/.obsidian/workspace.json b/.vaults/.obsidian/workspace.json new file mode 100644 index 0000000..23c2f16 --- /dev/null +++ b/.vaults/.obsidian/workspace.json @@ -0,0 +1,213 @@ +{ + "main": { + "id": "75e53e639e255f43", + "type": "split", + "children": [ + { + "id": "a53bc2cb926c1bd3", + "type": "tabs", + "children": [ + { + "id": "2efbb03a968b1686", + "type": "leaf", + "state": { + "type": "markdown", + "state": { + "file": "Therapy/Therapy Notes.md", + "mode": "source", + "source": false + }, + "icon": "lucide-file", + "title": "Therapy Notes" + } + }, + { + "id": "ab823c69c254e7e4", + "type": "leaf", + "state": { + "type": "markdown", + "state": { + "file": "Therapy/Follow-up Topics For Psychiatrist.md", + "mode": "source", + "source": false + }, + "icon": "lucide-file", + "title": "Follow-up Topics For Psychiatrist" + } + } + ], + "currentTab": 1 + } + ], + "direction": "vertical" + }, + "left": { + "id": "42fcd86e1a10b0c9", + "type": "split", + "children": [ + { + "id": "9f474fe9b550d21d", + "type": "tabs", + "children": [ + { + "id": "5dd77a930a9930be", + "type": "leaf", + "state": { + "type": "file-explorer", + "state": { + "sortOrder": "alphabetical", + "autoReveal": false + }, + "icon": "lucide-folder-closed", + "title": "Files" + } + }, + { + "id": "0ead5722cce7245c", + "type": "leaf", + "state": { + "type": "search", + "state": { + "query": "", + "matchingCase": false, + "explainSearch": false, + "collapseAll": false, + "extraContext": false, + "sortOrder": "alphabetical" + }, + "icon": "lucide-search", + "title": "Search" + } + }, + { + "id": "a9a58cdfe441a204", + "type": "leaf", + "state": { + "type": "bookmarks", + "state": {}, + "icon": "lucide-bookmark", + "title": "Bookmarks" + } + } + ] + } + ], + "direction": "horizontal", + "width": 227.5 + }, + "right": { + "id": "f0c16324cfeb3dd4", + "type": "split", + "children": [ + { + "id": "28d903712c5bd841", + "type": "tabs", + "children": [ + { + "id": "6d0d278162f36686", + "type": "leaf", + "state": { + "type": "backlink", + "state": { + "file": "Therapy/Topics For Psychiatrist.md", + "collapseAll": false, + "extraContext": false, + "sortOrder": "alphabetical", + "showSearch": false, + "searchQuery": "", + "backlinkCollapsed": false, + "unlinkedCollapsed": true + }, + "icon": "links-coming-in", + "title": "Backlinks for Topics For Psychiatrist" + } + }, + { + "id": "bb8af51d58a659f0", + "type": "leaf", + "state": { + "type": "outgoing-link", + "state": { + "file": "Therapy/Topics For Psychiatrist.md", + "linksCollapsed": false, + "unlinkedCollapsed": true + }, + "icon": "links-going-out", + "title": "Outgoing links from Topics For Psychiatrist" + } + }, + { + "id": "60900363433f10d3", + "type": "leaf", + "state": { + "type": "tag", + "state": { + "sortOrder": "frequency", + "useHierarchy": true, + "showSearch": false, + "searchQuery": "" + }, + "icon": "lucide-tags", + "title": "Tags" + } + }, + { + "id": "08bf01107be4c6e0", + "type": "leaf", + "state": { + "type": "all-properties", + "state": { + "sortOrder": "frequency", + "showSearch": false, + "searchQuery": "" + }, + "icon": "lucide-archive", + "title": "All properties" + } + }, + { + "id": "b0e98887e5a7ef4d", + "type": "leaf", + "state": { + "type": "outline", + "state": { + "file": "Therapy/Topics For Psychiatrist.md", + "followCursor": false, + "showSearch": false, + "searchQuery": "" + }, + "icon": "lucide-list", + "title": "Outline of Topics For Psychiatrist" + } + } + ] + } + ], + "direction": "horizontal", + "width": 300, + "collapsed": true + }, + "left-ribbon": { + "hiddenItems": { + "remotely-save:Remotely Save": false, + "switcher:Open quick switcher": false, + "graph:Open graph view": false, + "canvas:Create new canvas": false, + "daily-notes:Open today's daily note": false, + "templates:Insert template": false, + "command-palette:Open command palette": false, + "bases:Create new base": false + } + }, + "active": "ab823c69c254e7e4", + "lastOpenFiles": [ + "Therapy/Topics For Psychiatrist.md", + "Therapy/Follow-up Topics For Psychiatrist.md", + "Therapy/Therapy Notes.md", + "General.md", + "Therapy", + "General", + "General/Untitled", + "General" + ] +} \ No newline at end of file diff --git a/.vaults/General.md b/.vaults/General.md new file mode 100644 index 0000000..3f28a63 --- /dev/null +++ b/.vaults/General.md @@ -0,0 +1,2 @@ + +- look into other ab exercises that would be easy to form a habit with \ No newline at end of file diff --git a/.vaults/Therapy/Follow-up Topics For Psychiatrist.md b/.vaults/Therapy/Follow-up Topics For Psychiatrist.md new file mode 100644 index 0000000..f281957 --- /dev/null +++ b/.vaults/Therapy/Follow-up Topics For Psychiatrist.md @@ -0,0 +1,23 @@ +Therapist diagnosed me with OCD. Would you say thats correct? + +mar 13 11:30pm. + +Tried PRN once +- Did not notice a difference +- Did not make me tired + +Started Desvenlafaxine at 25 mg +- generally not noticing a difference +- yesterday at cub foods I felt fine until I suddenly had a wave of panic out of nowhere + - I went to the bathroom to see if that would calm me down and it did. Although I wasn't close to having a full bladder. I did have some pop before hand. + + + + + + +Use PRN more +- 30 minutes before +- try 2 if 1 not working + +She didnt give a specific diagnosis but said it was a rational diagnosis and would put it on file \ No newline at end of file diff --git a/.vaults/Therapy/Therapy Notes.md b/.vaults/Therapy/Therapy Notes.md new file mode 100644 index 0000000..f20a800 --- /dev/null +++ b/.vaults/Therapy/Therapy Notes.md @@ -0,0 +1,10 @@ +Talk about being overly critical and not enjoying anything anymore + + + +Drive further than normal + +My therapist diagnosed me with ocd is that correct? - message to psychiatrist + - ritual - avoid driving to avoid causing harm + +try PRN - give it a try a few times to see how it improves \ No newline at end of file diff --git a/.vaults/Therapy/Topics For Psychiatrist.md b/.vaults/Therapy/Topics For Psychiatrist.md new file mode 100644 index 0000000..7a24f3a --- /dev/null +++ b/.vaults/Therapy/Topics For Psychiatrist.md @@ -0,0 +1,19 @@ +## Explain Anxiety +- a few years ago I noticed I had the feeling to use the bathroom frequently. Did a bunch of appointments to figure it out and doctors didn't find anything physical. +- therapist thinks I have OCD since I avoid a lot of things and have certain rituals +- Get anxious when not near a bathroom +- Anxious when driving + +## Explain Depression +- Depressed mostly when home +- Very little motivation to do anything + +## Consider Genetic Testing for Medicine +- current medicine doesn't seem to do much + +## Consider PRN +- therapist thought it might help with anxiety episodes + +## Work Recommendations +- I have a job opportunity that requires me to drive daily +- Would this be worth trying? Or would it not work well with my anxiety? \ No newline at end of file diff --git a/.wallpapers/sunset between the clouds by exobiologyart.jpg b/.wallpapers/sunset between the clouds by exobiologyart.jpg new file mode 100644 index 0000000..8fa7b40 Binary files /dev/null and b/.wallpapers/sunset between the clouds by exobiologyart.jpg differ