diff --git a/.Rbuildignore b/.Rbuildignore index e4f5c4e..e3e63d5 100644 --- a/.Rbuildignore +++ b/.Rbuildignore @@ -18,3 +18,4 @@ ^\.automerge$ ^codecov\.yml$ ^cran-comments\.md$ +^srcjs$ diff --git a/AGENTS.md b/AGENTS.md index be07f91..942927f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -15,6 +15,15 @@ devtools::install() # install locally Single test file: `testthat::test_file("tests/testthat/test-server.R")`. +```bash +# Rebuild the React frontend bundle (after editing anything under srcjs/) +npm --prefix srcjs ci # first time / lockfile changes +npm --prefix srcjs run build # -> inst/www/amsync.{js,css} +``` + +`shinyreact` (Suggests; only for the interactive `sync_app()` / `$edit()` UI) +is installed from posit-dev/shinyreact (see `Remotes` in DESCRIPTION). + ## Related packages Interactive project browsing and live editing (`project_open()`, `project_app()`, `project_edit()`) live in the sibling `shinysync` package (`../shinysync`), which depends on autosync; autosync itself has no `shiny`/`bslib` dependency. @@ -37,7 +46,11 @@ Interactive project browsing and live editing (`project_open()`, `project_app()` **Auth (R/auth.R)**: Optional OAuth2 authentication via `auth_config()`. Validates Google OAuth2 tokens, supports email/domain allowlists and custom validators. TLS is mandatory when auth is enabled. Uses `later::later()` for auth timeout enforcement. `sync_token()` obtains an ID token interactively by delegating the Authorization Code + PKCE flow to httr2 (`oauth_server_metadata()` for discovery, `oauth_flow_auth_code()` for the browser handshake and token exchange). -**Client (R/client.R)**: `sync_fetch()` implements the client-side protocol for fetching documents from any automerge-repo server. +**Client (R/client.R)**: `sync_fetch()` implements the client-side protocol for fetching documents from any automerge-repo server. `sync_client()` opens a persistent connection whose `$open_doc()` returns `autosync_doc` handles sharing one socket; a handle's `$edit()` opens a live editor. + +**Project (R/project.R)**: `sync_project()` browses a project document's `files` map (path -> file doc ID) over a single connection, opening files on demand. + +**Interactive UI (R/app.R, R/edit.R)**: `sync_app()` is a single-window gadget (connect / browse / edit) and `$edit()` is the standalone live editor. Both render a **React frontend via shinyreact** (not bslib) and keep R as the sole owner of the Automerge documents — the browser is pure UI. `install_editor_sync()` (edit.R) wires the bidirectional editor<->document sync: an outgoing observer reads `input$content` and writes the minimal diff into the live doc; an incoming poll reflects remote changes back via a pluggable `set_editor()` callback (which bumps the `editor_doc` reactive_output revision the React CodeMirror editor watches). **Storage (R/storage.R)**: Persistence layer using `.automerge` files in a configurable data directory. @@ -68,6 +81,32 @@ Document IDs are Base58Check-encoded 16-byte random values. Peer IDs are Base64- - `secretbase` - CBOR encoding (cborenc/cbordec) and Base58/Base64 - `later` - Event loop integration (run_now for async recv) +### JS frontend (`srcjs/` -> `inst/www/`) + +The `sync_app()` / `$edit()` UI is a React app built with Vite. + +- **Source**: `srcjs/src/` (TypeScript/TSX). `index.tsx` mounts `` into the + `#root` div it appends to `` itself (`page_react()` serves a bare + page with no mount container). `App.tsx` routes on + `output$view`. Components: `ConnectScreen`, `BrowseScreen`, `FileTree` (the + `@pierre/trees` / trees.software file tree), `Editor` (CodeMirror 6), `Toast` + (notifications via `send_message`). `shiny.ts` is a typed facade over the + global `window.shinyreact` hooks; `languages.ts` maps file extensions to + CodeMirror language modes. +- **Build**: `npm --prefix srcjs run build` emits a self-contained IIFE to + `inst/www/amsync.js` + `amsync.css`. React/ReactDOM are **externalized** to + `window.shinyreact.{React,ReactDOM}` (vite.config.ts) so the bundle shares + shinyreact's single React 19 instance — never bundle a second React (it breaks + hooks). `@pierre/trees` and CodeMirror are bundled in. +- **Shipping**: the built `inst/www/*` is committed so the installed package + needs no Node; `srcjs/` is `.Rbuildignore`d. Rebuild and commit after editing + any `srcjs/` source. +- **R<->JS contract**: R reads `input$*` (url, proj_id, client_id/secret/issuer, + authenticate, connect, file, content, refresh, disconnect, exit, close) and + publishes `reactive_output`s (`view`, `init`, `authed`, `paths`, `selected`, + `editor_doc`). `paths` is emitted via `as.list()` so a length-1 vector still + serialises as a JSON array. + ## Testing Tests use port 0 (OS-assigned) by default, retrieving the actual URL via `server$url`. Test files cover server, client, handlers, storage, and integration scenarios. diff --git a/DESCRIPTION b/DESCRIPTION index ece6747..d7aa1ff 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -30,7 +30,11 @@ Imports: secretbase (>= 1.3.0) Suggests: openssl, + shiny, + shinyreact (>= 0.1.0), testthat (>= 3.0.0) +Remotes: + posit-dev/shinyreact Config/Needs/website: tidyverse/tidytemplate Config/roxygen2/markdown: TRUE Config/roxygen2/version: 8.1.0 diff --git a/NAMESPACE b/NAMESPACE index 12e9494..dc4a76d 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -2,14 +2,17 @@ S3method(print,autosync_client) S3method(print,autosync_doc) +S3method(print,autosync_project) S3method(print,autosync_server) export(auth_config) export(create_document) export(generate_document_id) export(get_document) export(list_documents) +export(sync_app) export(sync_client) export(sync_fetch) +export(sync_project) export(sync_server) export(sync_token) importFrom(automerge, @@ -24,7 +27,9 @@ importFrom(automerge, am_sync_encode, am_sync_state, am_sync_state_decode, - am_sync_state_encode + am_sync_state_encode, + am_text_content, + am_text_update ) importFrom(httr2, oauth_client, @@ -66,4 +71,5 @@ importFrom(secretbase, jsondec, jsonenc ) +importFrom(tools,file_ext) importFrom(utils,str) diff --git a/R/app.R b/R/app.R new file mode 100644 index 0000000..dd23374 --- /dev/null +++ b/R/app.R @@ -0,0 +1,469 @@ +# Single-window Shiny entry point: connect, browse, and edit in one app + +#' Launch the autosync browser app +#' +#' `sync_app()` runs one Shiny app for the whole workflow. It has two screens: +#' +#' * **Connect** -- enter a sync-server URL and a project document ID, then +#' click **Connect**. If an OIDC client ID is available, the app signs in +#' with the same browser flow as [sync_token()] first. Blank sign-in fields +#' under **Advanced** use the `OIDC_CLIENT_ID`, `OIDC_CLIENT_SECRET`, and +#' `OIDC_ISSUER` environment variables. The form shows when the first two +#' are set, but not their values. To skip sign-in, pass a `token` from an +#' earlier [sync_token()] call. For open servers, leave the sign-in blank +#' to connect without a token. +#' * **Browse & edit** -- the file tree of the project appears in a sidebar. +#' Select a file to open its document in a live CodeMirror editor. The +#' editor syncs with the server in both directions, like the `$edit()` +#' method of a document handle. **Disconnect** returns to the connect +#' screen. Close the window to end the session. +#' +#' The app builds one [sync_project()] connection and reuses it for every +#' file opened during the session. +#' +#' @inheritParams sync_project +#' @param server Sync-server URL to prefill in the connect form. Default `""`. +#' @param proj_id Project document ID to prefill. Default `""`. +#' @param token (optional) A JWT from an earlier [sync_token()] call. When +#' supplied, the app starts signed in. Default `NULL`. +#' @param debounce Milliseconds to debounce outgoing editor changes, passed +#' through to the live editor. Default 300. +#' +#' @return Invisibly `NULL`, when the app window is closed. +#' +#' @details +#' The interface is a React frontend rendered with the \pkg{shinyreact} +#' package. The file tree uses the \pkg{@pierre/trees} component, and the +#' editor uses CodeMirror 6. R owns the live Automerge documents and all +#' syncing. Requires the \pkg{shiny} and \pkg{shinyreact} packages and an +#' interactive session. +#' +#' @examplesIf interactive() +#' # Start with empty fields and fill them in the form: +#' sync_app() +#' +#' # Or prefill the server and project: +#' sync_app("wss://quarto-hub.com/ws", proj_id = "4F63WJPDzbHkkfKa66h1Qrr1sC5U") +#' +#' # Reuse a token obtained earlier, so the app starts signed in: +#' token <- sync_token() +#' sync_app("wss://quarto-hub.com/ws", proj_id = "4F63WJPD...", token = token) +#' +#' @importFrom automerge am_text_content +#' @export +sync_app <- function( + server = "", + proj_id = "", + token = NULL, + tls = NULL, + timeout = 5000L, + files_key = "files", + debounce = 300L +) { + if (!is_interactive()) { + stop("`sync_app()` requires an interactive session") + } + if ( + !requireNamespace("shiny", quietly = TRUE) || + !requireNamespace("shinyreact", quietly = TRUE) + ) { + stop( + "sync_app() requires the 'shiny' and 'shinyreact' packages.\n", + 'Install shiny with install.packages("shiny") and shinyreact with ', + 'pak::pak("posit-dev/shinyreact").' + ) + } + if ( + !is.null(token) && + (!is.character(token) || + length(token) != 1L || + is.na(token) || + !nzchar(token)) + ) { + stop( + "`token` must be a single non-empty string (from `sync_token()`), or NULL" + ) + } + + app <- build_sync_app( + server, + proj_id, + token, + tls, + timeout, + files_key, + debounce + ) + shiny::runGadget(app, stopOnCancel = FALSE) + invisible(NULL) +} + +#' Build the autosync browser Shiny app object +#' +#' Splits the app's UI and server out of [sync_app()] so the same app can be +#' launched as a gadget there and driven by `shiny::testServer()` in tests. The +#' parameters mirror [sync_app()]. +#' +#' The UI is the React frontend (`inst/www/amsync.js`) mounted by +#' [shinyreact::page_react()]; the server publishes the screen state, file tree, +#' sign-in state, and open-file content as `reactive_output()`s the client +#' reads, and reacts to the client's `input$*` events. R owns the Automerge +#' documents throughout via [sync_project()] and `install_editor_sync()`. +#' +#' @return A [shiny::shinyApp()] object. +#' +#' @noRd +build_sync_app <- function( + server, + proj_id, + token, + tls, + timeout, + files_key, + debounce +) { + ui <- amsync_react_page() + + # Named `app_server` rather than `server` so it does not shadow the `server` + # argument (the prefill URL), which the connect screen reads when rendering. + app_server <- function(input, output, session) { + # Connection and editor state lives in a plain environment, not a reactive + # one, so the sync observers can read the live document without taking a + # reactive dependency on it (which would re-fire them on every edit). Only + # the screen, file tree, selection, and pushed editor content are reactive. + # install_editor_sync() reads $doc/$at/$base/$shown from here, just as it + # does in edit_in_shiny(). + st <- new.env(parent = emptyenv()) + st$proj <- NULL # the sync_project connection, once connected + st$token <- token # JWT, pre-supplied or from the Authenticate flow + st$doc <- NULL # the currently-open autosync_doc handle + st$at <- "text" # path to the text object within a file document + st$base <- "" # the open file's content (for trailing-newline state) + st$shown <- "" # content the editor and document last agreed on + st$editor_path <- "" # the open file's path (header + editor payload) + st$editor_ext <- "" # the open file's extension (syntax highlighting) + st$editor_rev <- 0L # revision the React editor watches for server pushes + + rv <- shiny::reactiveValues( + view = "connect", # "connect", "browse", or "closed" + authed = !is.null(token), # whether a token has been obtained + paths = character(0), # file paths shown in the tree + selected = NULL, # the open file path, or NULL for none + editor = NULL # the editor_doc payload pushed to the client + ) + + # Push content to the React CodeMirror editor by bumping the revision it + # watches; carries the open path/extension and the debounce so the editor + # can pick its language and outgoing debounce. + set_editor <- function(value) { + st$editor_rev <- st$editor_rev + 1L + rv$editor <- list( + path = st$editor_path, + value = value, + ext = st$editor_ext, + rev = st$editor_rev, + debounce = as.integer(debounce) + ) + } + + # --- Outputs the React client reads --- + + output$view <- shinyreact::reactive_output(rv$view) + output$authed <- shinyreact::reactive_output(isTRUE(rv$authed)) + # as.list() so a length-1 path set still serialises as a JSON array (Shiny's + # auto_unbox would otherwise collapse it to a scalar the tree can't use). + output$paths <- shinyreact::reactive_output(as.list(rv$paths)) + output$selected <- shinyreact::reactive_output(rv$selected) + output$editor_doc <- shinyreact::reactive_output(rv$editor) + output$init <- shinyreact::reactive_output(list( + server = server, + proj_id = proj_id, + # Flags, not values: the form shows that the env vars are set and the + # connect observer falls back to them server-side, so the secret never + # leaves the R session. + client_id_env = nzchar(Sys.getenv("OIDC_CLIENT_ID")), + client_secret_env = nzchar(Sys.getenv("OIDC_CLIENT_SECRET")), + issuer = oidc_issuer() + )) + + # --- Connect screen: authenticate (if details given) and start browsing --- + + shiny::observeEvent(input$connect, { + url_in <- trimws(input$url %||% "") + proj_in <- trimws(input$proj_id %||% "") + if (!nzchar(url_in) || !nzchar(proj_in)) { + notify(session, "warning", "Enter both a server URL and a project ID.") + return() + } + + # Authenticate as part of connecting: when an OIDC client ID is provided + # (and we don't already hold a token) run the sign-in flow first, otherwise + # connect tokenless for open servers. sync_token() drives the shared + # event loop with run_now() (reentrant-safe) while it waits for the OAuth + # callback; the browser opening is the user's feedback. + if (is.null(st$token)) { + # Blank sign-in fields fall back to the environment, so an + # env-configured secret never round-trips through the browser. + client_id <- trimws(input$client_id %||% "") + if (!nzchar(client_id)) { + client_id <- Sys.getenv("OIDC_CLIENT_ID") + } + if (nzchar(client_id)) { + client_secret <- trimws(input$client_secret %||% "") + if (!nzchar(client_secret)) { + client_secret <- Sys.getenv("OIDC_CLIENT_SECRET") + } + issuer <- trimws(input$issuer %||% "") + token <- tryCatch( + sync_token( + client_id = client_id, + client_secret = client_secret, + issuer = if (nzchar(issuer)) issuer else oidc_issuer() + ), + error = function(e) { + notify( + session, + "error", + paste("Authentication failed:", conditionMessage(e)) + ) + NULL + } + ) + if (is.null(token)) { + return() # auth failed; stay on the connect screen + } + st$token <- token + rv$authed <- TRUE + } + } + + proj <- connect_with_retry( + session, + url_in, + proj_in, + st$token, + tls, + timeout, + files_key + ) + if (is.null(proj)) { + return() + } + st$proj <- proj + st$doc <- NULL + rv$paths <- proj$paths() + rv$selected <- NULL + rv$view <- "browse" + }) + + # --- Browse screen: open the selected file in the editor --- + + shiny::observeEvent( + input$file, + { + path <- input$file + if (is.null(path) || !nzchar(path)) { + return() + } + opened <- tryCatch( + { + doc <- st$proj$open(path) + base <- am_text_content(navigate_to_text(doc$doc, st$at)) + list(doc = doc, base = base) + }, + error = function(e) { + notify( + session, + "error", + paste("Could not open file:", conditionMessage(e)) + ) + NULL + } + ) + if (is.null(opened)) { + return() + } + st$doc <- opened$doc + st$base <- opened$base + st$shown <- opened$base + st$editor_path <- path + st$editor_ext <- file_ext_dot(path) + rv$selected <- path + set_editor(opened$base) + }, + ignoreInit = TRUE + ) + + # Bidirectional editor <-> document sync, shared with the $edit() gadget; + # reads the open document and tracking state from `st`, and pushes remote + # changes back to the client editor through set_editor(). + install_editor_sync(input, st, set_editor) + + # --- Browse screen: refresh the file tree (picks up added/removed files) --- + + shiny::observeEvent(input$refresh, { + if (is.null(st$proj)) { + return() + } + st$proj$refresh() + # Re-resolve the tree; drop the selection if its file is gone. + paths <- st$proj$paths() + if (!is.null(rv$selected) && !(rv$selected %in% paths)) { + rv$selected <- NULL + } + rv$paths <- paths + }) + + # --- Browse screen: disconnect and return to the connect form --- + + shiny::observeEvent(input$disconnect, { + cleanup_project(st) + rv$selected <- NULL + rv$view <- "connect" + }) + + # --- Connect screen: exit and end the app --- + + # Show a brief closing message (the "Session ended" screen), then stop the + # gadget. The short delay lets the message render and unblocks the calling + # R session. + shiny::observeEvent(input$exit, { + cleanup_project(st) + rv$view <- "closed" + later(function() shiny::stopApp(), delay = 0.75) + }) + + # Closing the window ends the session; disconnect so we never leak a socket. + session$onSessionEnded(function() cleanup_project(st)) + } + + shiny::shinyApp(ui, app_server) +} + +#' React UI page for the autosync frontend bundle +#' +#' Points [shinyreact::page_react()] at the built `inst/www/amsync.{js,css}` +#' bundle. Versioned by the JS file's mtime, so a rebuild busts the browser +#' cache. +#' +#' @return A UI definition for [shiny::shinyApp()]. +#' +#' @noRd +amsync_react_page <- function() { + shinyreact::page_react( + src_dir = system.file("www", package = "autosync"), + js_file = "amsync.js", + css_file = "amsync.css", + title = "amsync" + ) +} + +#' Connect to a project, retrying transient failures +#' +#' The first dial to a sync server (often right after signing in) can fail +#' transiently with a protocol/permission hiccup. Retry up to `retries` times, +#' one second apart, before giving up. Returns the connected `sync_project`, or +#' `NULL` after notifying the final error. +#' +#' @param session The Shiny session (for retry/failure notifications). +#' @param url,proj_id,token,tls,timeout,files_key Passed to [sync_project()]. +#' @param retries Number of extra attempts after the first. Default 5. +#' +#' @return An `sync_project`, or `NULL` on persistent failure. +#' +#' @noRd +connect_with_retry <- function( + session, + url, + proj_id, + token, + tls, + timeout, + files_key, + retries = 5L +) { + last_err <- NULL + attempts <- retries + 1L + for (attempt in seq_len(attempts)) { + proj <- tryCatch( + sync_project( + url, + proj_id, + token = token, + tls = tls, + timeout = timeout, + files_key = files_key + ), + error = function(e) { + last_err <<- e + NULL + } + ) + if (!is.null(proj)) { + return(proj) + } + if (attempt < attempts) { + notify( + session, + "warning", + sprintf("Connection failed, retrying (%d/%d)\u2026", attempt, retries) + ) + retry_pause() + } + } + notify( + session, + "error", + paste("Connection failed:", conditionMessage(last_err)) + ) + NULL +} + +#' Pause ~1 second between connection retries, driving the event loop +#' +#' Pumps the shared `later`/nanonext loop so the wait stays responsive (and so +#' tests can stub it to a no-op). +#' +#' @return Invisibly `NULL`. +#' +#' @noRd +retry_pause <- function() { + deadline <- Sys.time() + 1 + while (Sys.time() < deadline) { + run_now(0.1) + } + invisible() +} + +#' Send a transient notification to the React client +#' +#' Replaces `shiny::showNotification()` (whose default UI is absent on a bare +#' `page_react()` page) with a `send_message()` the React `Toast` handles. +#' +#' @param session The Shiny session. +#' @param type One of "message", "warning", or "error". +#' @param text The message text. +#' +#' @return Invisibly `NULL`. +#' +#' @noRd +notify <- function(session, type, text) { + shinyreact::send_message(session, "notify", list(type = type, text = text)) + invisible() +} + +#' Close a project connection held in app state, if any +#' +#' @param st The app's state environment. +#' +#' @return Invisibly `NULL`. +#' +#' @noRd +cleanup_project <- function(st) { + if (!is.null(st$proj)) { + try(st$proj$close(), silent = TRUE) + st$proj <- NULL + } + st$doc <- NULL + invisible() +} diff --git a/R/client.R b/R/client.R index 2b6f36a..70da319 100644 --- a/R/client.R +++ b/R/client.R @@ -101,6 +101,13 @@ join_msg <- function(peer_id) { #' \item{`doc`}{The live automerge document, kept in sync with the server.} #' \item{`push()`}{Push this document's local changes to the server #' immediately.} +#' \item{`edit(at = "text", ext = NULL, debounce = 300L)`}{Open this +#' document's text object at `at` in a live Shiny code editor that syncs +#' both ways, blocking until closed (requires \pkg{shiny} and +#' \pkg{shinyreact}). `at` is a key or character-vector path to an `am_text` +#' object, `ext` (e.g. `".md"`) selects syntax highlighting, and +#' `debounce` is the millisecond delay before pushing keystrokes. See +#' Details.} #' \item{`close()`}{Stop syncing this one document (detach it from the #' connection); the connection and its other documents are unaffected.} #' \item{`active`}{Logical, whether the document is still open on an active @@ -118,6 +125,17 @@ join_msg <- function(peer_id) { #' have unsynced edits — otherwise any changes made since the last #' `sync`-interval tick may be lost. #' +#' **Live editing.** A handle's `$edit()` opens its text object in a live +#' CodeMirror editor (a React frontend rendered with \pkg{shinyreact}) that syncs +#' both ways: as you type, the minimal +#' diff is written to the live document and pushed (debounced); when the text +#' changes remotely, the editor updates to the merged result. There is no +#' **Save** button — every edit is applied live. It syncs whole-text snapshots, +#' not granular operations, so a remote edit arriving in the brief window +#' between a keystroke and its debounced push can be overwritten by that push; +#' a smaller `debounce` narrows the window. The original's trailing-newline +#' state is preserved. +#' #' @examplesIf interactive() #' server <- sync_server() #' server$start() @@ -252,7 +270,10 @@ sync_client <- function( entry$unavailable <- TRUE } } - warning("Document not available on server: ", msg$documentId %||% "unknown") + warning( + "Document not available on server: ", + msg$documentId %||% "unknown" + ) } else if (msg$type == "error") { client$last_error <- msg$message warning("Server error: ", msg$message) @@ -322,6 +343,9 @@ sync_client <- function( handle$stream <- client$stream handle$connection <- client handle$push <- function() send_sync_for(entry) + handle$edit <- function(at = "text", ext = NULL, debounce = 300L) { + edit_doc(handle, at = at, ext = ext, debounce = debounce) + } handle$close <- function() { if (exists(entry$doc_id, envir = client$documents, inherits = FALSE)) { rm(list = entry$doc_id, envir = client$documents) @@ -423,7 +447,9 @@ sync_client <- function( # tripped over by a later run_now after garbage collection. if (!is.null(client$recv_aio)) { stop_aio(client$recv_aio) - for (i in seq_len(3L)) run_now() + for (i in seq_len(3L)) { + run_now() + } client$recv_aio <- NULL } close(client$stream) diff --git a/R/edit.R b/R/edit.R new file mode 100644 index 0000000..c603e1d --- /dev/null +++ b/R/edit.R @@ -0,0 +1,282 @@ +# Edit a synced Automerge text object in a live Shiny code editor + +#' Run the live editor for an open document handle +#' +#' Implements the `$edit()` method on the `autosync_doc` handle returned by +#' [sync_client()]'s `$open_doc()`: opens the document's text object at `at` +#' in a live React CodeMirror editor (rendered with \pkg{shinyreact}) that stays +#' in sync with the live document in both directions, blocks until the editor +#' closes, then prints a one-line summary. The user-facing description and +#' caveats live on [sync_client()]. +#' +#' @param doc An `autosync_doc` handle backed by an active connection. +#' @param at Character path to the text object within the document. A single +#' string addresses a top-level key; a character vector navigates nested +#' objects with `[[`. Default `"text"`. +#' @param ext File extension used to pick the editor's syntax-highlighting +#' language, or `NULL` for plain text. +#' @param debounce Milliseconds to wait after the last keystroke before pushing. +#' +#' @return Invisibly returns `doc`. +#' +#' @importFrom automerge am_text_content am_text_update +#' @noRd +edit_doc <- function(doc, at = "text", ext = NULL, debounce = 300L) { + if (!isTRUE(doc$active)) { + stop("`doc` is not active; reopen it with `$open_doc()`") + } + if (!is.character(at) || !length(at) || anyNA(at) || any(!nzchar(at))) { + stop("`at` must be a non-empty character path") + } + if ( + !is.numeric(debounce) || + length(debounce) != 1L || + is.na(debounce) || + debounce < 0 + ) { + stop("`debounce` must be a single non-negative number of milliseconds") + } + + # Validate the target is a text object before launching the editor. + navigate_to_text(doc$doc, at) + + final <- edit_in_shiny(doc, at, ext = ext, debounce = debounce) + + message(sprintf( + "Closed editor for %s (%d chars).", + paste(at, collapse = "/"), + nchar(final %||% "", type = "bytes") + )) + invisible(doc) +} + +#' Navigate a document to a text object via a character path +#' +#' @param doc An Automerge document (or forked document). +#' @param at Character vector path navigated with `[[`. +#' +#' @return The `am_text` object at the path. +#' +#' @noRd +navigate_to_text <- function(doc, at) { + node <- doc + for (key in at) { + node <- node[[key]] + if (is.null(node)) { + stop("No object found at path: ", paste(at, collapse = "/")) + } + } + if (!inherits(node, "am_text")) { + stop( + "Path ", + paste(at, collapse = "/"), + " is not a text object (got ", + paste(class(node), collapse = "/"), + ")" + ) + } + node +} + +#' Write an editor value into the live document +#' +#' Normalises `value`'s trailing-newline state to match `base`, then, if it +#' differs from the document's current content, applies the minimal diff and +#' pushes. Returns the content now agreed between editor and document, which the +#' caller tracks to distinguish its own writes from later remote changes. +#' +#' @param target The live `am_text` object. +#' @param value The editor's current contents. +#' @param base The text the editor opened with (for trailing-newline state). +#' @param push A zero-argument function that pushes local changes to the server. +#' +#' @return The (normalised) content now in the document. +#' +#' @noRd +sync_editor_to_doc <- function(target, value, base, push) { + value <- match_trailing_newline(enc2utf8(value), base) + if (!identical(value, am_text_content(target))) { + am_text_update(target, value) + push() + } + value +} + +#' Detect a remote change to reflect into the editor +#' +#' @param target The live `am_text` object. +#' @param shown The content currently reflected in the editor. +#' +#' @return The document's current content if it differs from `shown` (the +#' editor should be updated to it), otherwise `NULL`. +#' +#' @noRd +poll_doc_to_editor <- function(target, shown) { + current <- am_text_content(target) + if (identical(current, shown)) NULL else current +} + +#' Wire the bidirectional editor <-> live-document sync onto a Shiny session +#' +#' Installs the two observers shared by `edit_in_shiny()` and [sync_app()]'s +#' browse screen: an outgoing one that writes debounced editor changes into the +#' live document and pushes them, and an incoming one that polls the document +#' and reflects remote changes back into the editor. Both read the open +#' document and its tracking state from `st` -- a plain environment, not a +#' reactive one, so editing never re-fires the observers through a reactive +#' dependency on the document. +#' +#' `st$shown` is the content the editor and document last agreed on; it lets +#' each side ignore the echo of its own write: an outgoing edit sets it to what +#' we wrote, and the poll skips while the document still matches it. +#' +#' The editor is the React CodeMirror component, reached over Shiny: the +#' outgoing observer reads its value from `input$content`, and the incoming poll +#' hands new content to `set_editor()`, which pushes it to the client (bumping +#' the `editor_doc` revision the editor watches). Keeping the push pluggable +#' lets the same sync drive the browse screen and the standalone `$edit()` view. +#' +#' @param input The Shiny session's `input`. +#' @param st An environment exposing `$doc` (an `autosync_doc` handle or `NULL` +#' when nothing is open), `$at` (the text object's path), `$base` (the open +#' content, for trailing-newline state), and a mutable `$shown`. +#' @param set_editor A function of one argument (the new content) that pushes it +#' into the client editor. +#' @param poll_ms How often (ms) to poll the live document for remote changes. +#' +#' @return Invisibly `NULL`. +#' +#' @importFrom automerge am_text_content am_text_update +#' @noRd +install_editor_sync <- function(input, st, set_editor, poll_ms = 250L) { + # Outgoing: debounced editor changes -> minimal diff -> push. + shiny::observeEvent( + input$content, + { + if (is.null(st$doc) || !isTRUE(st$doc$active)) { + return() + } + target <- navigate_to_text(st$doc$doc, st$at) + st$shown <- sync_editor_to_doc( + target, + input$content %||% "", + st$base, + st$doc$push + ) + }, + ignoreInit = TRUE + ) + + # Incoming: poll the live document; reflect remote changes into the editor. + shiny::observe({ + shiny::invalidateLater(poll_ms) + if (is.null(st$doc) || !isTRUE(st$doc$active)) { + return() + } + target <- navigate_to_text(st$doc$doc, st$at) + current <- poll_doc_to_editor(target, st$shown) + if (!is.null(current)) { + st$shown <- current + set_editor(current) + } + }) + + invisible() +} + +#' Edit text live in a single-window React (CodeMirror) Shiny app +#' +#' Spins up a single-purpose [shinyreact::page_react()] gadget showing the React +#' CodeMirror editor (the app's `"edit"` view) populated with the text at `at`, +#' plus a **Close** button. While it runs, editor changes are streamed +#' (debounced) into the live document and pushed, and remote changes are polled +#' back into the editor. Blocks until the app exits, returning the document's +#' final content. +#' +#' @param doc An `autosync_doc` handle. +#' @param at Character path to the text object. +#' @param ext File extension used to choose the syntax-highlighting language. +#' @param debounce Milliseconds to debounce outgoing editor changes. +#' +#' @return The document's final text content (character scalar). +#' +#' @noRd +edit_in_shiny <- function(doc, at, ext = NULL, debounce = 300L) { + if ( + !requireNamespace("shiny", quietly = TRUE) || + !requireNamespace("shinyreact", quietly = TRUE) + ) { + stop( + "Editing a document requires the 'shiny' and 'shinyreact' packages.\n", + 'Install shiny with install.packages("shiny") and shinyreact with ', + 'pak::pak("posit-dev/shinyreact").' + ) + } + + base <- am_text_content(navigate_to_text(doc$doc, at)) + + ui <- amsync_react_page() + + server <- function(input, output, session) { + # Editor state lives in a plain environment read by the sync observers + # without a reactive dependency on the document; install_editor_sync() wires + # the bidirectional editor <-> document sync onto it (and explains `shown`). + st <- new.env(parent = emptyenv()) + st$doc <- doc + st$at <- at + st$base <- base + st$shown <- base + st$editor_rev <- 0L + + rv <- shiny::reactiveValues(editor = NULL) + + # Push content to the React editor by bumping the revision it watches. + set_editor <- function(value) { + st$editor_rev <- st$editor_rev + 1L + rv$editor <- list( + path = paste(at, collapse = "/"), + value = value, + ext = if (is.null(ext)) "" else ext, + rev = st$editor_rev, + debounce = as.integer(debounce) + ) + } + + # Drive the React app straight to the standalone editor view. + output$view <- shinyreact::reactive_output("edit") + output$editor_doc <- shinyreact::reactive_output(rv$editor) + + install_editor_sync(input, st, set_editor) + set_editor(base) # load the initial content + + # Stop exactly once; the Close button or window-close ends the session. + # Closing the editor returns to the file picker (in a browse loop), so it + # is already obvious the editor has ended -- no closing message needed here. + done <- FALSE + finish <- function() { + if (done) { + return() + } + done <<- TRUE + shiny::stopApp(am_text_content(navigate_to_text(doc$doc, at))) + } + shiny::observeEvent(input$close, finish()) + session$onSessionEnded(function() finish()) + } + + shiny::runGadget(shiny::shinyApp(ui, server), stopOnCancel = FALSE) +} + +#' Preserve the base string's trailing-newline state +#' +#' If `base` did not end in a newline, strip any trailing newline(s) the +#' editor appended; otherwise leave `edited` unchanged. +#' +#' @noRd +match_trailing_newline <- function(edited, base) { + base_has_nl <- grepl("\n$", base) + if (!base_has_nl) { + edited <- sub("\n+$", "", edited) + } + edited +} diff --git a/R/import-standalone-defer.R b/R/import-standalone-defer.R new file mode 100644 index 0000000..e689e50 --- /dev/null +++ b/R/import-standalone-defer.R @@ -0,0 +1,35 @@ +# Standalone file: do not edit by hand +# Source: https://github.com/r-lib/withr/blob/HEAD/R/standalone-defer.R +# Generated by: usethis::use_standalone("r-lib/withr", "defer") +# ---------------------------------------------------------------------- +# +# --- +# repo: r-lib/withr +# file: standalone-defer.R +# last-updated: 2024-01-15 +# license: https://unlicense.org +# --- +# +# `defer()` is similar to `on.exit()` but with a better default for +# `add` (hardcoded to `TRUE`) and `after` (`FALSE` by default). +# It also supports adding handlers to other frames which is useful +# to implement `local_` functions. +# +# +# ## Changelog +# +# 2024-01-15: +# * Rewritten to be pure base R. +# +# nocov start + +defer <- function(expr, envir = parent.frame(), after = FALSE) { + thunk <- as.call(list(function() expr)) + do.call( + on.exit, + list(thunk, add = TRUE, after = after), + envir = envir + ) +} + +# nocov end diff --git a/R/project.R b/R/project.R new file mode 100644 index 0000000..28d256c --- /dev/null +++ b/R/project.R @@ -0,0 +1,235 @@ +# Project browsing: file-tree navigation from a project document ID + +#' Open files from a project document +#' +#' Given a sync server URL and a project document ID, opens a persistent +#' connection to the server, syncs the project document over it, and exposes +#' its file tree for opening individual files. A project is an Automerge +#' document with a `files` map whose keys are file paths and whose values are +#' text objects holding each file's own document ID. +#' +#' Opening a file syncs that file's document over the **same** connection +#' rather than dialing the server again, so a session reuses a single WebSocket +#' throughout. Call the opened file's `$edit()` method to edit it live, or use +#' [sync_app()] for an interactive browser. Call `$close()` when finished to +#' disconnect. +#' +#' @inheritParams sync_fetch +#' @param proj_id Document ID of the project. +#' @param files_key Key of the files map within the project document. Default +#' `"files"`. +#' +#' @return An environment of class `"autosync_project"` (reference semantics) +#' with the following fields and methods: +#' \describe{ +#' \item{`doc`}{The live project document, kept in sync with the server.} +#' \item{`conn`}{The underlying [sync_client()] connection.} +#' \item{`paths()`}{Current sorted file paths.} +#' \item{`doc_id(path)`}{Resolve a path to its document ID.} +#' \item{`open(path)`}{Open the file's document over the project connection +#' and return its `autosync_doc` handle. Reuses the connection and any +#' already-open document.} +#' \item{`refresh()`}{Re-resolve the file tree to pick up added or removed +#' files (the project document syncs live, so this just settles pending +#' updates).} +#' \item{`close()`}{Disconnect the project connection.} +#' } +#' +#' @examplesIf interactive() +#' proj <- sync_project("wss://quarto-hub.com/ws", proj_id, token = sync_token()) +#' proj # prints the file tree +#' doc <- proj$open("/charlie/index.qmd") # open a file over the connection +#' doc$edit(at = "text", ext = ".qmd") # edit it live +#' proj$close() # disconnect when finished +#' +#' @importFrom automerge am_keys am_text_content +#' @importFrom tools file_ext +#' @export +sync_project <- function( + url, + proj_id, + token = NULL, + tls = NULL, + timeout = 5000L, + files_key = "files" +) { + conn <- sync_client(url, timeout = timeout, tls = tls, token = token) + + # Sync the project document over the connection, then validate its files map. + # Tear the connection down if either step fails so we never leak a socket. + proj_doc <- tryCatch( + conn$open_doc(proj_id), + error = function(e) { + conn$close() + stop(e) + } + ) + files_map <- tryCatch( + resolve_files_map(proj_doc$doc, files_key), + error = function(e) { + conn$close() + stop(e) + } + ) + + proj <- new.env(parent = emptyenv()) + proj$conn <- conn + proj$doc <- proj_doc$doc + proj$url <- url + proj$proj_id <- proj_id + proj$files_key <- files_key + proj$files_map <- files_map + + proj$paths <- function() { + sort(am_keys(proj$doc, proj$files_map)) + } + + proj$doc_id <- function(path) { + entry <- proj$files_map[[path]] + if (is.null(entry)) { + stop( + "Unknown path: ", path, "\nAvailable paths:\n ", + paste(proj$paths(), collapse = "\n ") + ) + } + if (!inherits(entry, "am_text")) { + stop("Entry at ", path, " is not a text object") + } + am_text_content(entry) + } + + proj$open <- function(path) { + proj$conn$open_doc(proj$doc_id(path)) + } + + proj$refresh <- function() { + # The project document syncs live over the connection; settle any pending + # updates, then re-resolve the files map to reflect added/removed files. + for (i in seq_len(5L)) { + run_now(0.05) + } + proj$files_map <- resolve_files_map(proj$doc, proj$files_key) + invisible(proj) + } + + proj$close <- function() { + proj$conn$close() + invisible(proj) + } + + class(proj) <- "autosync_project" + proj +} + +#' @export +print.autosync_project <- function(x, ...) { + paths <- x$paths() + cat("Automerge Project\n") + cat(" Project:", x$proj_id, "\n") + cat(" Server:", x$url, "\n") + cat(" Files:", length(paths), "\n\n") + cat(format_file_tree(paths)) + cat("\nCall $open(path) to open a file, $close() when done.\n") + invisible(x) +} + +#' Resolve and validate the files map within a project document +#' +#' @param doc The project document. +#' @param files_key Key of the files map. +#' +#' @return The `am_map` object. +#' +#' @noRd +resolve_files_map <- function(doc, files_key) { + files_map <- doc[[files_key]] + if (is.null(files_map)) { + stop("Project document has no `", files_key, "` map") + } + if (!inherits(files_map, "am_map")) { + stop("`", files_key, "` is not a map") + } + files_map +} + +#' File extension as a dotted suffix for tempfile() +#' +#' @param path A file path. +#' +#' @return `".ext"`, or `".txt"` if the path has no extension. +#' +#' @noRd +file_ext_dot <- function(path) { + ext <- tools::file_ext(path) + if (nzchar(ext)) paste0(".", ext) else ".txt" +} + +#' Render a set of file paths as an indented tree +#' +#' @param paths Character vector of file paths. +#' +#' @return A single string with a trailing newline. +#' +#' @noRd +format_file_tree <- function(paths) { + if (!length(paths)) { + return("/\n") + } + tree <- list() + for (p in paths) { + parts <- strsplit(p, "/", fixed = TRUE)[[1]] + parts <- parts[nzchar(parts)] + tree <- tree_insert(tree, parts) + } + lines <- c("/", tree_render(tree, prefix = "")) + paste0(paste(lines, collapse = "\n"), "\n") +} + +#' Insert a path's components into the nested tree +#' +#' @noRd +tree_insert <- function(tree, parts) { + if (!length(parts)) { + return(tree) + } + head <- parts[[1]] + if (is.null(tree[[head]])) { + tree[[head]] <- list() + } + tree[[head]] <- tree_insert(tree[[head]], parts[-1]) + tree +} + +#' Render one level of the nested tree +#' +#' Directories (nodes with children) sort before files, alphabetical within +#' each group. +#' +#' @noRd +tree_render <- function(node, prefix) { + keys <- names(node) + is_dir <- vapply(keys, function(k) length(node[[k]]) > 0L, logical(1)) + ord <- order(!is_dir, keys) + keys <- keys[ord] + is_dir <- is_dir[ord] + + # Box-drawing glyphs as \u escapes to keep the source ASCII-only: + # tee = branch, elbow = last child, pipe = vertical continuation. + tee <- "\u251c\u2500 " + elbow <- "\u2514\u2500 " + pipe <- "\u2502 " + + lines <- character(0) + n <- length(keys) + for (i in seq_len(n)) { + last <- i == n + connector <- if (last) elbow else tee + label <- if (is_dir[i]) paste0(keys[i], "/") else keys[i] + lines <- c(lines, paste0(prefix, connector, label)) + if (is_dir[i]) { + child_prefix <- paste0(prefix, if (last) " " else pipe) + lines <- c(lines, tree_render(node[[keys[i]]], child_prefix)) + } + } + lines +} diff --git a/inst/www/amsync.css b/inst/www/amsync.css new file mode 100644 index 0000000..059bbff --- /dev/null +++ b/inst/www/amsync.css @@ -0,0 +1 @@ +:root{--amsync-fg: #1f2328;--amsync-muted: #656d76;--amsync-bg: #ffffff;--amsync-bg-subtle: #f6f8fa;--amsync-border: #d0d7de;--amsync-primary: #0969da;--amsync-primary-fg: #ffffff;--amsync-accent: #4f46e5;--amsync-accent-soft: rgba(79, 70, 229, .14);--amsync-danger: #cf222e;--amsync-success: #1a7f37;--amsync-radius: 6px;--amsync-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;--amsync-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace}*{box-sizing:border-box}html,body,#root{height:100%;margin:0}body{font-family:var(--amsync-font);color:var(--amsync-fg);background:var(--amsync-bg);font-size:14px}.amsync-btn{font:inherit;padding:6px 12px;border-radius:var(--amsync-radius);border:1px solid var(--amsync-border);background:var(--amsync-bg);color:var(--amsync-fg);cursor:pointer;line-height:1.4}.amsync-btn:hover{background:var(--amsync-bg-subtle)}.amsync-btn-sm{padding:3px 8px;font-size:12px}.amsync-btn-primary{background:var(--amsync-primary);border-color:var(--amsync-primary);color:var(--amsync-primary-fg)}.amsync-btn-primary:hover{filter:brightness(.95);background:var(--amsync-primary)}.amsync-btn-outline{background:var(--amsync-bg)}.amsync-btn-danger{color:var(--amsync-danger);border-color:var(--amsync-border)}.amsync-btn-danger:hover{background:#ffebe9}.amsync-fill{flex:1 1 auto}.amsync-connect{display:flex;align-items:center;justify-content:center;min-height:100%;padding:32px 24px;overflow:auto}.amsync-signin{width:100%;max-width:360px}.amsync-brand{text-align:center;font-size:26px;font-weight:600;letter-spacing:-.03em;color:var(--amsync-fg)}.amsync-brand-dot{color:var(--amsync-accent)}.amsync-signin-subtitle{margin:6px 0 30px;text-align:center;font-size:14px;color:var(--amsync-muted)}.amsync-field{display:block;margin-bottom:16px}.amsync-field>span{display:block;font-size:13px;font-weight:500;color:var(--amsync-fg);margin-bottom:6px}.amsync-field input{font:inherit;font-weight:400;width:100%;padding:9px 12px;border:1px solid var(--amsync-border);border-radius:8px;background:var(--amsync-bg);color:var(--amsync-fg);transition:border-color .15s ease,box-shadow .15s ease}.amsync-field input::placeholder{color:#9aa4af;font-weight:400}.amsync-field input:focus{outline:none;border-color:var(--amsync-accent);box-shadow:0 0 0 3px var(--amsync-accent-soft)}.amsync-signin-authed{margin:-22px 0 22px;text-align:center;font-size:12px;color:var(--amsync-success)}.amsync-advanced-note{margin:0 0 14px;font-size:12px;line-height:1.5;color:var(--amsync-muted)}.amsync-advanced{margin-bottom:22px}.amsync-advanced>summary{cursor:pointer;width:fit-content;font-size:13px;color:var(--amsync-muted);list-style:none}.amsync-advanced>summary::-webkit-details-marker{display:none}.amsync-advanced>summary:before{content:"▸ ";font-size:10px}.amsync-advanced[open]>summary:before{content:"▾ "}.amsync-advanced-body{margin-top:14px}.amsync-advanced-body .amsync-field:last-child{margin-bottom:0}.amsync-primary-btn{font:inherit;font-weight:500;width:100%;padding:10px 16px;border:none;border-radius:8px;background:var(--amsync-fg);color:#fff;cursor:pointer;transition:opacity .15s ease}.amsync-primary-btn:hover{opacity:.88}.amsync-ghost-btn{font:inherit;display:block;width:100%;margin-top:8px;padding:8px;border:none;border-radius:8px;background:none;color:var(--amsync-muted);cursor:pointer}.amsync-ghost-btn:hover{background:var(--amsync-bg-subtle);color:var(--amsync-fg)}.amsync-browse{display:flex;height:100%}.amsync-sidebar{width:300px;flex:0 0 300px;border-right:1px solid var(--amsync-border);display:flex;flex-direction:column;background:var(--amsync-bg-subtle)}.amsync-sidebar-title{padding:10px 12px;font-weight:600;border-bottom:1px solid var(--amsync-border)}.amsync-tree-wrap{flex:1 1 auto;overflow:auto;padding:6px;min-height:0}.amsync-tree{display:block;height:100%}.amsync-empty{color:var(--amsync-muted);font-size:13px;padding:8px}.amsync-sidebar-actions{display:flex;gap:8px;padding:8px;border-top:1px solid var(--amsync-border)}.amsync-main{flex:1 1 auto;min-width:0;display:flex;flex-direction:column}.amsync-placeholder{display:flex;flex:1;align-items:center;justify-content:center;color:var(--amsync-muted);padding:24px}.amsync-editor-card{display:flex;flex-direction:column;flex:1 1 auto;min-height:0}.amsync-edit-only{height:100%}.amsync-editor-header{display:flex;align-items:center;justify-content:space-between;padding:8px 12px;border-bottom:1px solid var(--amsync-border);background:var(--amsync-bg-subtle)}.amsync-editor-title{display:inline-flex;align-items:center;gap:7px;min-width:0}.amsync-file-icon{flex:0 0 auto;color:var(--amsync-muted)}.amsync-editor-path{font-family:var(--amsync-mono);font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.amsync-editor-live{font-size:12px;color:var(--amsync-muted)}.amsync-editor{flex:1 1 auto;min-height:0;overflow:hidden}.amsync-editor .cm-editor{height:100%}.amsync-editor .cm-scroller{font-family:var(--amsync-mono)}.amsync-closed,.amsync-loading{display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;text-align:center;color:var(--amsync-muted)}.amsync-closed h5{margin:0 0 4px;color:var(--amsync-fg)}.amsync-closed p{margin:0}.amsync-toasts{position:fixed;top:16px;right:16px;display:flex;flex-direction:column;gap:8px;z-index:1000;max-width:360px}.amsync-toast{padding:10px 14px;border-radius:var(--amsync-radius);border:1px solid var(--amsync-border);background:var(--amsync-bg);box-shadow:0 2px 8px #0000001f;font-size:13px}.amsync-toast-error{border-color:var(--amsync-danger);background:#ffebe9;color:var(--amsync-danger)}.amsync-toast-warning{border-color:#d4a72c;background:#fff8c5}.amsync-toast-message{border-color:var(--amsync-success);background:#dafbe1;color:var(--amsync-success)} diff --git a/inst/www/amsync.js b/inst/www/amsync.js new file mode 100644 index 0000000..24a3670 --- /dev/null +++ b/inst/www/amsync.js @@ -0,0 +1,1881 @@ +(function(Ne){"use strict";var gf={exports:{}},Ms={};/** + * @license React + * react-jsx-runtime.production.js + * + * Copyright (c) Meta Platforms, Inc. and affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var ey=Symbol.for("react.transitional.element"),ty=Symbol.for("react.fragment");function Pf(t,e,i){var n=null;if(i!==void 0&&(n=""+i),e.key!==void 0&&(n=""+e.key),"key"in e){i={};for(var O in e)O!=="key"&&(i[O]=e[O])}else i=e;return e=i.ref,{$$typeof:ey,type:t,key:n,ref:e!==void 0?e:null,props:i}}Ms.Fragment=ty,Ms.jsx=Pf,Ms.jsxs=Pf,gf.exports=Ms;var k=gf.exports;const ji=window.shinyreact,et=ji.React,iy=ji.ReactDOM,sr=ji.useShinyInput;ji.useShinyInputValue,ji.useSetShinyInput;const oO=ji.useShinyOutputValue;ji.useShinyOutputStatus;const ny=ji.useShinyMessageHandler,Oy=ji.useShinyInitialized;function Sf(t,e=Date.now()){window.Shiny?.setInputValue?.(t,e,{priority:"event"})}function or(t){return et.useCallback(()=>Sf(t),[t])}function ry(){const t=oO("init"),e=oO("authed",!1)??!1,[i,n]=sr("url",""),[O,r]=sr("proj_id",""),[s,o]=sr("client_id",""),[a,l]=sr("client_secret",""),[c,h]=sr("issuer",""),d=or("connect"),u=or("exit"),$=et.useRef(!1);return et.useEffect(()=>{!t||$.current||($.current=!0,t.server&&n(t.server),t.proj_id&&r(t.proj_id),t.issuer&&h(t.issuer))},[t,n,r,h]),k.jsx("div",{className:"amsync-connect",children:k.jsxs("div",{className:"amsync-signin",children:[k.jsxs("div",{className:"amsync-brand",children:["autosync",k.jsx("span",{className:"amsync-brand-dot",children:"."})]}),k.jsx("p",{className:"amsync-signin-subtitle",children:"Connect to a sync project"}),e&&k.jsx("p",{className:"amsync-signin-authed",children:"✓ signed in"}),k.jsxs("label",{className:"amsync-field",children:[k.jsx("span",{children:"Server URL"}),k.jsx("input",{type:"text",value:i,placeholder:"wss://…",onChange:Q=>n(Q.target.value)})]}),k.jsxs("label",{className:"amsync-field",children:[k.jsx("span",{children:"Project ID"}),k.jsx("input",{type:"text",value:O,placeholder:"Base58 document ID",onChange:Q=>r(Q.target.value)})]}),k.jsxs("details",{className:"amsync-advanced",children:[k.jsx("summary",{children:"Advanced"}),k.jsxs("div",{className:"amsync-advanced-body",children:[k.jsx("p",{className:"amsync-advanced-note",children:"Provide a client ID to sign in (OIDC) automatically when you connect. Leave blank for open servers. Fields shown as set from the environment are used when left blank."}),k.jsxs("label",{className:"amsync-field",children:[k.jsx("span",{children:"OIDC client ID"}),k.jsx("input",{type:"text",value:s,placeholder:t?.client_id_env?"Set from $OIDC_CLIENT_ID (leave blank to use)":"",onChange:Q=>o(Q.target.value)})]}),k.jsxs("label",{className:"amsync-field",children:[k.jsx("span",{children:"OIDC client secret"}),k.jsx("input",{type:"password",value:a,placeholder:t?.client_secret_env?"Set from $OIDC_CLIENT_SECRET (leave blank to use)":"",onChange:Q=>l(Q.target.value)})]}),k.jsxs("label",{className:"amsync-field",children:[k.jsx("span",{children:"OIDC issuer"}),k.jsx("input",{type:"text",value:c,onChange:Q=>h(Q.target.value)})]})]})]}),k.jsx("button",{type:"button",className:"amsync-primary-btn",onClick:d,children:"Connect"}),k.jsx("button",{type:"button",className:"amsync-ghost-btn",onClick:u,children:"Exit"})]})})}const Xf=``,sy=` + + +`,oy=` + +`,ay=` + + +`,ly=` + +`,cy=` + + +`,hy=` + + + +`,dy=` + +`,uy=` + +`,fy=` + +`,$y=` + +`,Qy=` + + +`,py=` + + + +`,my=` + + +`,gy=` + + +`,Py=` + + +`,Sy=` + +`,Xy=` + +`,by=` + +`,yy=` + +`,xy=` + + +`,Ty=` + + +`,wy=` + + +`,vy=` + +`,ky=` + +`,_y=` + + +`,Ry=` + + + + + + + + + +`,Zy=` + + +`,Yy=` + +`,zy=` + +`,Vy=` + + + + +`,qy=` + + +`,Uy=` + + +`,Wy=` + +`,Cy=` + +`,jy=` + +`,Gy=` + + +`,Ey=` + +`,Iy=` + + +`,Ay=` + + +`,My=` + +`,Dy=` + + +`,Ly=` + +`,Ny=` + +`,By=` + + +`,Fy=` + + +`,Hy=` + +`,Ky=` + + + +`,Jy=` + + +`,ex=` + + + +`,tx=` + + +`,ix=` + +`,nx=` + + +`,Ox=[ay,uy,$y,Qy,py,my,Sy,Xy,by,xy,Ty,wy,vy,ky,_y,qy,Wy,Cy,My,Dy,By,Fy,` + + +`],rx=[sy,oy,ly,cy,hy,dy,fy,gy,Py,yy,Ry,Zy,Yy,zy,Vy,Uy,jy,Gy,Ey,Iy,Ay,Ly,Ny,Hy,Ky,Jy,ex,tx,ix,nx];function bf(t,e){return e.length===0?t:t.replace("",` + ${e.join(` + `)} +`)}const yf=bf(Xf,Ox),sx={minimal:Xf,standard:yf,complete:bf(yf,rx)},ox={".babelrc":"babel",".babelrc.json":"babel",".bash_profile":"bash",".bashrc":"bash",".browserslistrc":"browserslist",".dockerignore":"docker",".eslintignore":"eslint",".eslintrc":"eslint",".eslintrc.cjs":"eslint",".eslintrc.js":"eslint",".eslintrc.json":"eslint",".eslintrc.yaml":"eslint",".eslintrc.yml":"eslint",".gitattributes":"git",".gitignore":"git",".gitkeep":"git",".gitmodules":"git",".oxlintrc.json":"oxc",".postcssrc":"postcss",".postcssrc.json":"postcss",".postcssrc.yaml":"postcss",".postcssrc.yml":"postcss",".prettierignore":"prettier",".prettierrc":"prettier",".prettierrc.cjs":"prettier",".prettierrc.js":"prettier",".prettierrc.json":"prettier",".prettierrc.mjs":"prettier",".prettierrc.toml":"prettier",".prettierrc.yaml":"prettier",".prettierrc.yml":"prettier",".stylelintignore":"stylelint",".stylelintrc":"stylelint",".stylelintrc.cjs":"stylelint",".stylelintrc.js":"stylelint",".stylelintrc.json":"stylelint",".stylelintrc.mjs":"stylelint",".stylelintrc.yaml":"stylelint",".stylelintrc.yml":"stylelint",".terraform.lock.hcl":"terraform",".zprofile":"bash",".zshenv":"bash",".zshrc":"bash","babel.config.cjs":"babel","babel.config.js":"babel","babel.config.json":"babel","babel.config.mjs":"babel","biome.json":"biome","biome.jsonc":"biome","bootstrap.bundle.js":"bootstrap","bootstrap.bundle.min.js":"bootstrap","bootstrap.css":"bootstrap","bootstrap.js":"bootstrap","bootstrap.min.css":"bootstrap","bootstrap.min.js":"bootstrap","bun.lock":"bun","bun.lockb":"bun","bunfig.toml":"bun","claude.md":"claude","compose.yaml":"docker","compose.yml":"docker","docker-compose.override.yml":"docker","docker-compose.yaml":"docker","docker-compose.yml":"docker",dockerfile:"docker","eslint.config.cjs":"eslint","eslint.config.js":"eslint","eslint.config.mjs":"eslint","eslint.config.mts":"eslint","eslint.config.ts":"eslint",gemfile:"ruby","next.config.js":"nextjs","next.config.mjs":"nextjs","next.config.mts":"nextjs","next.config.ts":"nextjs","postcss.config.cjs":"postcss","postcss.config.js":"postcss","postcss.config.mjs":"postcss","postcss.config.ts":"postcss","prettier.config.cjs":"prettier","prettier.config.js":"prettier","prettier.config.mjs":"prettier",rakefile:"ruby","readme.md":"markdown","stylelint.config.cjs":"stylelint","stylelint.config.js":"stylelint","stylelint.config.mjs":"stylelint","svgo.config.cjs":"svgo","svgo.config.js":"svgo","svgo.config.mjs":"svgo","svgo.config.ts":"svgo","tailwind.config.cjs":"tailwind","tailwind.config.js":"tailwind","tailwind.config.mjs":"tailwind","tailwind.config.ts":"tailwind","vite.config.js":"vite","vite.config.mjs":"vite","vite.config.mts":"vite","vite.config.ts":"vite","webpack.config.babel.js":"webpack","webpack.config.cjs":"webpack","webpack.config.js":"webpack","webpack.config.mjs":"webpack","webpack.config.ts":"webpack"},ax={"7z":"zip",astro:"astro",AUTHORS:"text",avif:"image",bash:"bash",bmp:"image",bz2:"zip",c:"c",cc:"cpp",cfg:"text",CHANGELOG:"text",cjs:"javascript","code-workspace":"vscode",conf:"text",CONTRIBUTORS:"text",cpp:"cpp",csh:"bash",css:"css",csv:"table",cts:"typescript",cxx:"cpp",db:"database",editorconfig:"text",env:"text","env.development":"text","env.local":"text","env.production":"text",eot:"font",erb:"ruby",fish:"bash",gemspec:"ruby",gif:"image",go:"go",gql:"graphql",graphql:"graphql",gz:"zip",h:"c",hh:"cpp",hpp:"cpp",htm:"html",html:"html",hxx:"cpp",icns:"image",ico:"image",ini:"text",inl:"cpp",jar:"zip",jpeg:"image",jpg:"image",js:"javascript",json:"json",json5:"json",jsonc:"json",jsonl:"json",jsx:"javascript",ksh:"bash",less:"css",LICENSE:"text",log:"text",markdown:"markdown",mcp:"mcp",md:"markdown",mdx:"markdown","mdx.tsx":"markdown",mjs:"javascript",mm:"cpp",mts:"typescript",ods:"table",otf:"font",png:"image",postcss:"css",py:"python",pyi:"python",pyw:"python",pyx:"python",rake:"ruby",rar:"zip",rb:"ruby",rs:"rust",rst:"text",rtf:"text",sass:"css",scss:"css",sh:"bash",sql:"database",sqlite:"database",sqlite3:"database",styl:"css",svelte:"svelte",svg:"svg",swift:"swift",tar:"zip",tf:"terraform",tfstate:"terraform",tfvars:"terraform",tgz:"zip",tif:"image",tiff:"image",ts:"typescript",tsv:"table",tsx:"typescript",ttf:"font",txt:"text",vue:"vue",war:"zip",wasm:"wasm",wast:"wasm",wat:"wasm",webp:"image",woff:"font",woff2:"font",xhtml:"html",xls:"table",xlsx:"table",xz:"zip",yaml:"yml",yml:"yml",zig:"zig",zip:"zip",zsh:"bash"},lx={jsx:"react",sass:"sass",scss:"sass",tsx:"react"},xf=new Set(["bash","c","cpp","css","database","default","font","git","go","html","image","javascript","json","markdown","mcp","python","ruby","rust","swift","table","text","typescript","zip"]),cx=new Set(["complete"]);function hx(t){return sx[t==="none"?"minimal":t]}function dx(t){return`file-tree-builtin-${t}`}function ux(t){return t!=="none"&&cx.has(t)}function fx(t,e,i){if(t==="minimal"||t==="none")return;const n=t==="complete",O=ox[e.toLowerCase()];if(O!=null&&(n||xf.has(O)))return O;for(const r of i){if(n){const o=lx[r];if(o!=null)return o}const s=ax[r];if(s!=null&&(n||xf.has(s)))return s}return"default"}const ar="file-tree-container",wl="data-file-tree-style",Tf="data-file-tree-unsafe-css",$x="data-file-tree-scrollbar-measure",wf="data-file-tree-scrollbar-gutter-measured",Qx="--trees-scrollbar-gutter-measured",vf="f::",Ds="header",aO="context-menu",vl="context-menu-trigger";function px(t){return t.spriteSheet!=null||t.remap!=null||t.byFileName!=null||t.byFileExtension!=null||t.byFileNameContains!=null}function Ls(t){return t==null?{set:"complete",colored:!0}:typeof t=="string"?{set:t,colored:!0}:{...t,set:t.set??(px(t)?"none":"complete"),colored:t.colored??!0}}const mx=t=>t.trim().toLowerCase(),gx=t=>t.split("/").at(-1)??t,Px=t=>{const e=t.toLowerCase().split("."),i=[];for(let n=1;n[o.toLowerCase(),a]);return{resolveIcon:(o,a)=>{if(o==="file-tree-icon-file"&&a!=null){const c=gx(a),h=c.toLowerCase(),d=n.get(h);if(d!=null)return Ns(d,o);for(const[Q,p]of r)if(h.includes(Q))return Ns(p,o);const u=Px(c);for(const Q of u){const p=O.get(Q);if(p!=null)return Ns(p,o)}const $=fx(e.set,c,u);if($!=null&&e.set!=="none")return{name:dx($),remappedFrom:o,token:$}}const l=i?.[o];return l==null?{name:o}:Ns(l,o)}}}const Xx=/^#(?:[0-9a-f]{3}0|[0-9a-f]{6}00)$/i,bx=/^0(?:\.0+)?%?$/;function yx(t){const e=t.indexOf("(");if(e<=0||!t.endsWith(")"))return;const i=t.slice(0,e).trim();if(!/^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch|color)$/i.test(i))return;const n=t.slice(e+1,-1).trim();if(n.length===0)return;const O=n.lastIndexOf("/");if(O!==-1)return n.slice(O+1).trim();if(/^(?:rgba|hsla)$/i.test(i)){const r=n.split(",");if(r.length===4)return r[3]?.trim()}}function xx(t){if(t==null)return!1;const e=t.trim().toLowerCase();if(e==="transparent"||Xx.test(e))return!0;const i=yx(e);return i!=null&&bx.test(i)}function kf(t){return xx(t)?void 0:t}function Tx(t){const e=t.colors??{},i=e["sideBar.background"]??e["editor.background"]??t.bg,n=e["sideBar.foreground"]??e["editor.foreground"]??t.fg,O=e["sideBar.border"],r=e["list.activeSelectionForeground"]??e["sideBar.foreground"],s=i?.toLowerCase(),o=e["list.hoverBackground"],a=o?.toLowerCase()===s?void 0:o,l=e["list.activeSelectionBackground"],c=l?.toLowerCase()===s?e["list.focusBackground"]??e["editor.selectionBackground"]:l??e["editor.selectionBackground"],h=kf(e["list.focusOutline"])??kf(e.focusBorder),d=e["input.background"]??i,u=e["input.border"],$=e["scrollbarSlider.background"],Q=e["sideBarSectionHeader.foreground"]??n,p=e["gitDecoration.addedResourceForeground"]??e["terminal.ansiGreen"]??e["editorGutter.addedBackground"],m=e["gitDecoration.modifiedResourceForeground"]??e["terminal.ansiBlue"]??e["editorGutter.modifiedBackground"],P=e["gitDecoration.deletedResourceForeground"]??e["terminal.ansiRed"]??e["editorGutter.deletedBackground"],g={colorScheme:"light",backgroundColor:i??"",color:n??"",borderColor:"var(--trees-theme-sidebar-border, light-dark(oklch(0% 0 0 / 0.15), oklch(100% 0 0 / 0.15)))","--trees-theme-sidebar-bg":i??"","--trees-theme-sidebar-fg":n??"","--trees-theme-sidebar-header-fg":Q??"","--trees-theme-list-active-selection-fg":r??n??"","--trees-theme-list-hover-bg":a??"rgba(0,0,0,0.06)","--trees-theme-list-active-selection-bg":c??"transparent","--trees-theme-focus-ring":h??n??"","--trees-theme-input-bg":d??""};return O!=null&&O!==""&&(g["--trees-theme-sidebar-border"]=O),u!=null&&u!==""&&(g["--trees-theme-input-border"]=u),$!=null&&$!==""&&(g["--trees-theme-scrollbar-thumb"]=$),p!=null&&p!==""&&(g["--trees-theme-git-added-fg"]=p),m!=null&&m!==""&&(g["--trees-theme-git-modified-fg"]=m),P!=null&&P!==""&&(g["--trees-theme-git-deleted-fg"]=P),g}const lr=5,Bs=1<>lr;t.childVisibleChunkSums[r]+=n}function _l(t,e,i){const n=e.childVisibleChunkSums;if(n!=null){let r=i,s=0;for(const o of n){if(r>lr;for(let o=0;o>lr]+=s.visibleSubtreeCount)}e.childVisibleChunkSums=n}function kx(t,e,i,n){const O=Math.min(e.childIds.length,i+Bs);let r=n;for(let s=i;s>>Vf}function Ks(t){return(t.depthAndFlags&zf)>>Rl}function A(t){return(t.depthAndFlags&zf)!==0}function qf(t){return t.depthAndFlags&_x}function je(t,e){return(qf(t)&e)!==0}function Js(t,e){t.depthAndFlags|=e}function Rx(t,e){t.depthAndFlags=Vt(e,qf(t),Ks(t))}const Uf=Symbol("benchmarkInstrumentation");function Zx(t,e){return e==null||Object.defineProperty(t,Uf,{configurable:!0,enumerable:!1,value:e,writable:!1}),t}function Zl(t){return t==null?null:t[Uf]??null}function W(t,e,i){return t==null?i():t.measurePhase(e,i)}function eo(t,e,i){!Number.isFinite(i)||t==null||t.setCounter(e,i)}function Wf(t){return t>=48&&t<=57}function Yx(t){const e=[];let i=0,n=0;for(;n=t.length)break;n>i&&e.push(t.slice(i,n));let O=0;for(;n{const s=i.get(r);if(s!=null)return s;const o=fr(r);return i.set(r,o),o},O=Math.min(t.segments.length,e.segments.length);for(let r=0;r0&&t.charCodeAt(t.length-1)===47,i=e?t.length-1:t.length,n=[];let O=0;for(let r=0;re!=null&&typeof e=="object"&&typeof e.path=="string"&&Array.isArray(e.segments)&&typeof e.basename=="string"&&typeof e.isDirectory=="boolean")}function Ex(t){return Array.isArray(t)&&t.every(e=>typeof e=="string")}function Ix(t,e={}){return Wl(t,e).map(i=>i.path)}function Ax(t,e={}){const i=Wl(t,e);return If({paths:i.map(n=>n.path),preparedPaths:i},"prepared")}function Mx(t){const e=t.length;let i=!1;for(let n=0;n0&&O.charCodeAt(O.length-1)===47){i=!0;break}}return If({paths:t,presortedPaths:t,presortedPathsContainDirectories:i},"presorted")}function Dx(t){const e=t,i=e.preparedPaths;if(e[Ul]==="prepared"&&i!=null)return i;if(!Gx(i))throw new Error("preparedInput must come from PathStore.prepareInput()");return i}function Lx(t){const e=t;return e[Ul]==="presorted"&&e.presortedPaths!=null||Ex(e.presortedPaths)?e.presortedPaths:null}function Nx(t){const e=t;return typeof e.presortedPathsContainDirectories=="boolean"?e.presortedPathsContainDirectories:null}function Wl(t,e={}){const i=jf(e),n=Zl(e);eo(n,"workload.inputFiles",t.length);const O=W(n,"store.preparePathEntries.parse",()=>t.map(r=>$r(r)));return W(n,"store.preparePathEntries.sort",()=>O.sort((r,s)=>Mf(r,s,i.sort))),O}var Lf=class{directories=new Map;directoryStack=[0];presortedDirectoryNodeIds=[];initialExpandedPathSet;createdDirectoriesAllExpanded=!1;createdDirectoryCount=0;lastPreparedPath=null;nodes=[Cx()];options;instrumentation;segmentSortKeyCache=new Map;segmentTable=Ef();hasDeferredDirectoryIndexes=!1;constructor(t={}){this.instrumentation=Zl(t),this.options=jf(t);const e=t.initialExpandedPaths??null;if(e==null||e.length===0)this.initialExpandedPathSet=null;else{const i=new Set,n=e.length;for(let O=0;O0&&r.charCodeAt(s-1)===47?r.slice(0,s-1):r)}this.initialExpandedPathSet=i,this.createdDirectoriesAllExpanded=!0}this.directories.set(0,cr())}appendPaths(t){return W(this.instrumentation,"store.builder.appendPaths.parse",()=>this.appendPreparedPaths(t.map(e=>$r(e))))}appendPreparedPaths(t,e=!0){return this.createdDirectoriesAllExpanded=!1,W(this.instrumentation,"store.builder.appendPreparedPaths",()=>{for(const i of t)this.appendPreparedPath(i,e)}),this}appendPresortedPaths(t,e=null){return W(this.instrumentation,"store.builder.appendPresortedPaths",()=>{if(e===!1){this.appendPresortedFilePaths(t);return}this.createdDirectoriesAllExpanded=!1;let i=null,n=0;const O=this.nodes,r=this.segmentTable,s=r.idByValue,o=r.valueById,a=this.directoryStack;let l=0,c="",h=0;for(const d of t){if(i===d)throw new Error(`Duplicate path: "${d}"`);const u=d.length>0&&d.charCodeAt(d.length-1)===47,$=u?d.length-1:d.length;let Q=0,p=0;if(i!=null)if(c.length>0&&d.length>c.length&&d.startsWith(c))Q=h,p=c.length;else{const g=Math.min($,i.length);let b=!0;for(let X=0;X$&&i.charCodeAt($)===47&&(Q++,p=$+1)}l=Q,n=Q;let m=p,P=d.indexOf("/",m);for(;P>=0&&P<$;){const g=a[l];if(g===void 0)throw new Error("Directory stack underflow while building the path store");n++;const b=d.slice(m,P);let X=s.get(b);X===void 0&&(X=o.length,s.set(b,X),o.push(b));const y=O.length;O.push({depthAndFlags:Vt(n,0,ti),nameId:X,parentId:g,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(d.slice(0,P)),l++,a[l]=y,m=P+1,P=d.indexOf("/",m)}if(u){if(m<$){const b=a[l];if(b===void 0)throw new Error(`Unable to resolve directory parent for "${d}"`);n++;const X=d.slice(m,$);let y=s.get(X);y===void 0&&(y=o.length,s.set(X,y),o.push(X));const T=O.length;O.push({depthAndFlags:Vt(n,0,ti),nameId:y,parentId:b,subtreeNodeCount:1,visibleSubtreeCount:1}),l++,a[l]=T}const g=a[l];if(g===void 0)throw new Error(`Unable to resolve directory node for "${d}"`);this.promoteDirectoryToExplicit(g,d)}else{const g=a[l];if(g===void 0)throw new Error(`Unable to resolve file parent for "${d}"`);const b=d.slice(m);let X=s.get(b);X===void 0&&(X=o.length,s.set(b,X),o.push(b)),O.push({depthAndFlags:Vt(n+1,0),nameId:X,parentId:g,subtreeNodeCount:1,visibleSubtreeCount:1})}m!==c.length&&(c=d.substring(0,m),h=n),i=d}a.length=l+1,i!=null&&(this.lastPreparedPath=$r(i)),this.hasDeferredDirectoryIndexes=!0}),this}appendPresortedFilePaths(t){let e=null,i=0;const n=this.nodes,O=this.segmentTable,r=O.idByValue,s=O.valueById,o=this.directoryStack;let a=0,l="",c=0;for(const h of t){if(e===h)throw new Error(`Duplicate path: "${h}"`);const d=h.length;let u=0,$=0;if(e!=null)if(l.length>0&&h.length>l.length&&h.startsWith(l))u=c,$=l.length;else{const b=Math.min(d,e.length);for(let X=0;X=0;){const b=o[a];if(b===void 0)throw new Error("Directory stack underflow while building the path store");i++;const X=h.slice(Q,p);let y=r.get(X);y===void 0&&(y=s.length,r.set(X,y),s.push(X));const T=n.length;n.push({depthAndFlags:Vt(i,0,ti),nameId:y,parentId:b,subtreeNodeCount:1,visibleSubtreeCount:1}),this.recordCreatedDirectoryPath(h.slice(0,p)),this.presortedDirectoryNodeIds.push(T),a++,o[a]=T,Q=p+1,p=h.indexOf("/",Q)}const m=o[a];if(m===void 0)throw new Error(`Unable to resolve file parent for "${h}"`);const P=h.slice(Q);let g=r.get(P);g===void 0&&(g=s.length,r.set(P,g),s.push(P)),n.push({depthAndFlags:Vt(i+1,0),nameId:g,parentId:m,subtreeNodeCount:1,visibleSubtreeCount:1}),Q!==l.length&&(l=h.substring(0,Q),c=i),e=h}o.length=a+1,e!=null&&(this.lastPreparedPath=$r(e)),this.hasDeferredDirectoryIndexes=!0}finish(t={}){const e=t.skipSubtreeCountPass===!0;return this.hasDeferredDirectoryIndexes?(W(this.instrumentation,"store.builder.buildDirectoryIndexes",()=>this.buildPresortedFinish(e)),this.hasDeferredDirectoryIndexes=!1):e||W(this.instrumentation,"store.builder.computeSubtreeCounts",()=>this.computeSubtreeCounts(0)),{directories:this.directories,nodes:this.nodes,options:this.options,rootId:0,segmentTable:this.segmentTable,presortedDirectoryNodeIds:this.presortedDirectoryNodeIds.length>0?this.presortedDirectoryNodeIds:null}}didMatchAllInitialExpandedPaths(){return this.createdDirectoriesAllExpanded&&this.initialExpandedPathSet!=null&&this.createdDirectoryCount===this.initialExpandedPathSet.size}appendPreparedPath(t,e){if(this.hasDeferredDirectoryIndexes&&(this.buildDirectoryIndexes(),this.hasDeferredDirectoryIndexes=!1),this.lastPreparedPath!=null){if(t.path===this.lastPreparedPath.path)throw new Error(`Duplicate path: "${t.path}"`);if(e&&(this.options.sort==="default"?Wx(this.lastPreparedPath,t,this.segmentSortKeyCache):Mf(this.lastPreparedPath,t,this.options.sort))>0)throw new Error(`Builder input must be sorted before appendPaths(): "${t.path}"`)}const i=this.lastPreparedPath,n=Df(t),O=i==null?0:Df(i),r=i==null?0:jx(i.segments,t.segments),s=Math.min(r,n,O);this.directoryStack.length=s+1;for(let a=s;a=1;r--){const s=e[r];if(s==null)continue;const o=e[s.parentId];o!=null&&(o.subtreeNodeCount+=s.subtreeNodeCount,o.visibleSubtreeCount+=s.visibleSubtreeCount)}}buildDirectoryIndexes(){const t=this.nodes;for(let e=1;e0;return}t.expandedDirectoryIds.add(e);return}if(O){t.collapsedDirectoryIds.add(e),t.hasCollapsedDirectoryOverrides=!0;return}t.expandedDirectoryIds.delete(e)}function Bf(t,e){const i=t.directoryLoadInfoById.get(e);if(i!=null)return i;const n={activeAttemptId:null,errorMessage:null,nextAttemptId:1,state:"loaded"};return t.directoryLoadInfoById.set(e,n),n}function pr(t,e){return t.directoryLoadInfoById.get(e)?.state??"loaded"}function Kx(t,e){const i=Bf(t,e);if(i.state==="loading"&&i.activeAttemptId!=null)return{attemptId:i.activeAttemptId,nodeId:e,reused:!0};const n=i.nextAttemptId;return i.activeAttemptId=n,i.errorMessage=null,i.nextAttemptId+=1,i.state="loading",{attemptId:n,nodeId:e,reused:!1}}function Jx(t,e){const i=Bf(t,e);i.activeAttemptId=null,i.errorMessage=null,i.state="unloaded"}function eT(t,e,i){const n=t.directoryLoadInfoById.get(e);return n==null||n.activeAttemptId!==i?!1:(n.activeAttemptId=null,n.errorMessage=null,n.state="loaded",!0)}function tT(t,e,i){return t.directoryLoadInfoById.get(e)?.activeAttemptId===i}function iT(t,e,i,n){const O=t.directoryLoadInfoById.get(e);return O==null||O.activeAttemptId!==i?!1:(O.activeAttemptId=null,O.errorMessage=n??null,O.state="error",!0)}function nT(t,e){t.directoryLoadInfoById.delete(e)}function OT(t,e,i){const n=i,O=t.listeners.get(e);return O!=null?O.add(n):t.listeners.set(e,new Set([n])),()=>{const r=t.listeners.get(e);r!=null&&(r.delete(n),r.size===0&&t.listeners.delete(e))}}function rT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!0,operation:"add",path:t.path,projectionChanged:t.projectionChanged,visibleCountDelta:null}}function sT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!0,operation:"remove",path:t.path,projectionChanged:t.projectionChanged,recursive:t.recursive,visibleCountDelta:null}}function oT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!0,from:t.from,operation:"move",projectionChanged:t.projectionChanged,to:t.to,visibleCountDelta:null}}function aT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!1,operation:"expand",path:t.path,projectionChanged:!0,visibleCountDelta:null}}function lT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!1,operation:"collapse",path:t.path,projectionChanged:!0,visibleCountDelta:null}}function cT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],canonicalChanged:!1,operation:"mark-directory-unloaded",path:t.path,projectionChanged:t.projectionChanged,visibleCountDelta:null}}function hT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],attemptId:t.attemptId,canonicalChanged:!1,operation:"begin-child-load",path:t.path,projectionChanged:t.projectionChanged,reused:t.reused,visibleCountDelta:null}}function dT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],attemptId:t.attemptId,canonicalChanged:t.childEvents.some(e=>e.canonicalChanged),childEvents:t.childEvents,operation:"apply-child-patch",path:t.path,projectionChanged:t.projectionChanged,visibleCountDelta:null}}function uT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],attemptId:t.attemptId,canonicalChanged:!1,operation:"complete-child-load",path:t.path,projectionChanged:t.projectionChanged,stale:t.stale,visibleCountDelta:null}}function fT(t){return{affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],attemptId:t.attemptId,canonicalChanged:!1,errorMessage:t.errorMessage,operation:"fail-child-load",path:t.path,projectionChanged:t.projectionChanged,stale:t.stale,visibleCountDelta:null}}function $T(t){return{activeNodeCountAfter:t.activeNodeCountAfter,activeNodeCountBefore:t.activeNodeCountBefore,affectedAncestorIds:t.affectedAncestorIds??[],affectedNodeIds:t.affectedNodeIds??[],cachedPathEntryCountAfter:t.cachedPathEntryCountAfter,cachedPathEntryCountBefore:t.cachedPathEntryCountBefore,canonicalChanged:!1,idsPreserved:t.idsPreserved,loadInfoEntryCountAfter:t.loadInfoEntryCountAfter,loadInfoEntryCountBefore:t.loadInfoEntryCountBefore,mode:t.mode,operation:"cleanup",projectionChanged:t.projectionChanged,reclaimedCachedPathEntryCount:t.reclaimedCachedPathEntryCount,reclaimedLoadInfoEntryCount:t.reclaimedLoadInfoEntryCount,reclaimedNodeSlotCount:t.reclaimedNodeSlotCount,reclaimedSegmentCount:t.reclaimedSegmentCount,segmentCountAfter:t.segmentCountAfter,segmentCountBefore:t.segmentCountBefore,totalNodeSlotCountAfter:t.totalNodeSlotCountAfter,totalNodeSlotCountBefore:t.totalNodeSlotCountBefore,visibleCountDelta:null}}function yt(t,e,i){return{...i,visibleCountDelta:jl(t)-e}}function QT(t,e){const i=jl(t),n=Fx();t.transactionStack.push(n);try{e()}catch(O){throw Hf(t,n,!1),O}Hf(t,n,!0,jl(t)-i)}function ii(t,e){const i=t.instrumentation;if(i==null){Ff(t,e);return}W(i,"store.events.record",()=>Ff(t,e))}function Ff(t,e){const i=t.transactionStack[t.transactionStack.length-1]??null;if(i==null){Cl(t,e);return}i.events.push(e),gT(i,e)}function Hf(t,e,i,n=null){if(t.transactionStack.pop()!==e)throw new Error("Transaction stack underflow");if(!i)return;const O=t.transactionStack[t.transactionStack.length-1]??null;if(O!=null){const o=t.instrumentation;o==null?Kf(O,e):W(o,"store.events.batch.merge",()=>Kf(O,e));return}const r=pT(e,n),s=t.instrumentation;if(s==null){Cl(t,r);return}W(s,"store.events.batch.commit",()=>Cl(t,r))}function pT(t,e){return{affectedAncestorIds:[...t.affectedAncestorIds],affectedNodeIds:[...t.affectedNodeIds],canonicalChanged:t.events.some(i=>i.canonicalChanged),events:[...t.events],operation:"batch",projectionChanged:t.events.some(i=>i.projectionChanged),visibleCountDelta:e}}function mT(t,e){for(const i of e.affectedAncestorIds)t.affectedAncestorIds.add(i);for(const i of e.affectedNodeIds)t.affectedNodeIds.add(i)}function Kf(t,e){for(const i of e.events)t.events.push(i);mT(t,e)}function gT(t,e){for(const i of e.affectedNodeIds)t.affectedNodeIds.add(i);for(const i of e.affectedAncestorIds)t.affectedAncestorIds.add(i)}function Cl(t,e){const i=t.instrumentation;if(i==null){Jf(t,e);return}W(i,"store.events.emit",()=>Jf(t,e))}function Jf(t,e){t.listeners.get(e.operation)?.forEach(i=>i(e)),t.listeners.get("*")?.forEach(i=>i(e))}function jl(t){return t.snapshot.nodes[t.snapshot.rootId]?.visibleSubtreeCount??0}function lO(t,e){if(t.snapshot.options.flattenEmptyDirectories!==!0)return null;const i=t.snapshot.nodes[e];if(i==null||!A(i)||je(i,bt))return null;const n=t.snapshot.directories.get(e);if(n==null||n.childIds.length!==1)return null;const O=n.childIds[0];if(O==null)return null;const r=t.snapshot.nodes[O];return r==null||!A(r)?null:O}function Zn(t,e){let i=e;for(;;){const n=lO(t,i);if(n==null)return i;i=n}}function io(t,e){const i=[e];let n=e;for(;;){const O=lO(t,n);if(O==null)return i;i.push(O),n=O}}function e$(t,e){const i=e==null?t.snapshot.rootId:Dt(t,e);return i==null?[]:ST(t,i)}function t$(t,e){const i=$r(e),n=i.isDirectory?i.segments:i.segments.slice(0,-1),O=an(t,_T(t,n)),{createdNodeIds:r,directoryId:s}=XT(t,n),o=new Set(r);let a=s;if(i.isDirectory){const c=I(t,s);if(je(c,sn))throw new Error(`Path already exists: "${e}"`);Js(c,sn),t.pathCacheByNodeId.set(s,{path:e,version:t.pathCacheVersion}),o.add(s)}else a=yT(t,s,i.basename),o.add(a);Yn(t,s);const l=an(t,s);return rT({affectedAncestorIds:ni(t,a),affectedNodeIds:[...o],path:e,projectionChanged:a$(O,l)})}function i$(t,e,i){const n=Dt(t,e);if(n==null)throw new Error(`Path does not exist: "${e}"`);const O=I(t,n);if(je(O,bt))throw new Error("The root node cannot be removed");if(A(O)&&we(t,n).childIds.length>0&&i.recursive!==!0)throw new Error(`Cannot remove a non-empty directory without recursive: "${e}"`);const r=O.parentId,s=an(t,r),o=o$(t,n);Il(t,r,n,O.nameId),Al(t,r),Yn(t,r);const a=an(t,r);return sT({affectedAncestorIds:ni(t,r),affectedNodeIds:o,path:e,projectionChanged:a$(s,a),recursive:i.recursive===!0})}function n$(t,e,i,n){const O=Dt(t,e);if(O==null)throw new Error(`Source path does not exist: "${e}"`);const r=I(t,O);if(je(r,bt))throw new Error("The root node cannot be moved");const s=n.collision??"error",o=vT(t,O,i),a=an(t,r.parentId),l=an(t,o.parentId),c=$i(t.snapshot.segmentTable,r.nameId),h=on(t.snapshot.segmentTable,o.basename);if(o.parentId===r.parentId&&c===o.basename)return null;if(A(r)&&ZT(t,O,o.parentId))throw new Error("Cannot move a directory into one of its descendants");const d=Rn(t.snapshot.nodes,we(t,o.parentId)).get(h),u=o.existingNodeId??d??null;if(u!=null&&u!==O&&kT(t,u,s,Ks(r))==="skip")return null;const $=r.parentId;Il(t,$,O,r.nameId),r.parentId=o.parentId,r.nameId=h,t.pathCacheByNodeId.delete(O),c$(t,O),El(t,o.parentId,O),Al(t,$),t.pathCacheVersion++,Yn(t,$),o.parentId!==$&&Yn(t,o.parentId);const Q=an(t,$),p=an(t,o.parentId);return oT({affectedAncestorIds:[...new Set([...ni(t,$),...ni(t,o.parentId)])],affectedNodeIds:[O],from:e,projectionChanged:l$([a,l],[Q,p]),to:Te(t,O)})}function PT(t,e){const i=t.pathCacheByNodeId.get(e);return i!=null&&i.version===t.pathCacheVersion?i.path:null}function O$(t,e,i){return t.pathCacheByNodeId.set(e,{path:i,version:t.pathCacheVersion}),i}function Te(t,e){const i=I(t,e),n=PT(t,e);if(n!=null)return n;if(je(i,bt))return O$(t,e,"");const O=Te(t,i.parentId),r=$i(t.snapshot.segmentTable,i.nameId),s=O.length===0?r:`${O}${r}`;return O$(t,e,A(i)?`${s}/`:s)}function Yn(t,e){const i=t.instrumentation;if(i==null){h$(t,e);return}W(i,"store.recomputeCountsUpwardFrom",()=>h$(t,e))}function Gl(t,e){const i=[[e,0]],{nodes:n,directories:O}=t.snapshot;for(;i.length>0;){const r=i[i.length-1],s=r[0],o=n[s];if(o==null||!A(o)){Ml(t,s,o,!0),i.pop();continue}const a=O.get(s);if(a==null||r[1]>=a.childIds.length){Ml(t,s,o,!0),i.pop();continue}const l=a.childIds[r[1]++];i.push([l,0])}}function ni(t,e){const i=[];let n=e;for(;n!=null;){const O=I(t,n);if(i.push(n),n===t.snapshot.rootId)break;n=O.parentId}return i}function Dt(t,e){if(e.length===0)return t.snapshot.rootId;const i=Vl(e);return r$(t,i.segments,i.requiresDirectory)}function r$(t,e,i){let n=t.snapshot.rootId;for(const r of e){const s=t.snapshot.segmentTable.idByValue.get(r);if(s===void 0)return null;const o=we(t,n),a=Rn(t.snapshot.nodes,o).get(s);if(a===void 0)return null;n=a}const O=I(t,n);return i&&!A(O)?null:n}function we(t,e){const i=t.snapshot.directories.get(e);if(i===void 0)throw new Error(`Unknown directory child index for node ${String(e)}`);return i}function I(t,e){const i=t.snapshot.nodes[e];if(i===void 0||je(i,ur))throw new Error(`Unknown node ID: ${String(e)}`);return i}function ST(t,e){const i=t.snapshot.nodes[e];if(i===void 0||je(i,ur))return[];if(!A(i))return[Te(t,e)];if(we(t,e).childIds.length===0)return je(i,sn)&&!je(i,bt)?[Te(t,e)]:[];const n=[],O=[{childIndex:0,nodeId:e}];for(;O.length>0;){const r=O[O.length-1];if(r==null)break;const s=t.snapshot.nodes[r.nodeId];if(s===void 0||je(s,ur)){O.pop();continue}if(!A(s)){n.push(Te(t,r.nodeId)),O.pop();continue}const o=we(t,r.nodeId);if(o.childIds.length===0){je(s,sn)&&!je(s,bt)&&n.push(Te(t,r.nodeId)),O.pop();continue}const a=o.childIds[r.childIndex];if(a==null){O.pop();continue}r.childIndex++,O.push({childIndex:0,nodeId:a})}return n}function XT(t,e){const i=[];let n=t.snapshot.rootId;for(const O of e){const r=on(t.snapshot.segmentTable,O),s=we(t,n),o=Rn(t.snapshot.nodes,s).get(r);if(o!==void 0){if(!A(I(t,o)))throw new Error(`Cannot create a directory that collides with an existing file: "${O}"`);n=o;continue}n=bT(t,n,r),i.push(n)}return{createdNodeIds:i,directoryId:n}}function bT(t,e,i){const n=I(t,e),O=t.snapshot.nodes.length;return t.snapshot.nodes.push({depthAndFlags:Vt(fi(n)+1,0,ti),nameId:i,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),t.snapshot.directories.set(O,cr()),El(t,e,O),t.collapseNewDirectoriesByDefault&&(t.collapsedDirectoryIds.add(O),t.hasCollapsedDirectoryOverrides=!0),t.activeNodeCount++,O}function yT(t,e,i){const n=on(t.snapshot.segmentTable,i),O=we(t,e);if(Rn(t.snapshot.nodes,O).has(n))throw new Error(`Path already exists: "${YT(t,e,i)}"`);const r=I(t,e),s=t.snapshot.nodes.length;return t.snapshot.nodes.push({depthAndFlags:Vt(fi(r)+1,0),nameId:n,parentId:e,subtreeNodeCount:1,visibleSubtreeCount:1}),El(t,e,s),t.activeNodeCount++,s}function xT(t,e,i){let n=0,O=e.childIds.length;for(;n>>1,s=e.childIds[r];if(s==null){O=r;continue}TT(t,i,s)<0?O=r:n=r+1}return n}function El(t,e,i){const n=we(t,e),O=I(t,i);Rn(t.snapshot.nodes,n).set(O.nameId,i),kl(n,i,O.subtreeNodeCount,O.visibleSubtreeCount);const r=xT(t,n,i);n.childIds.splice(r,0,i),Zf(n,r),dr(t.snapshot.nodes,n)}function Il(t,e,i,n){const O=we(t,e),r=Fs(O),s=r.get(i)??-1;Rn(t.snapshot.nodes,O).delete(n),r.delete(i);const o=t.snapshot.nodes[i];o!=null&&kl(O,i,-o.subtreeNodeCount,-o.visibleSubtreeCount),s>=0&&(O.childIds.splice(s,1),Zf(O,s),dr(t.snapshot.nodes,O))}function TT(t,e,i){const n=t.snapshot.options.sort;return n==="default"?wT(t,e,i):n(s$(t,e),s$(t,i))}function wT(t,e,i){const n=I(t,e),O=I(t,i),r=A(n);if(r!==A(O))return r?-1:1;const s=Yl(zl(t.snapshot.segmentTable,n.nameId),zl(t.snapshot.segmentTable,O.nameId));if(s!==0)return s;const o=$i(t.snapshot.segmentTable,n.nameId),a=$i(t.snapshot.segmentTable,O.nameId);return o!==a?o0)throw new Error("replace collision does not support non-empty directories");const r=O.parentId,s=O.nameId;return o$(t,e),Il(t,r,e,s),Al(t,r),Yn(t,r),"handled"}function o$(t,e){const i=[],n=[{nodeId:e,visitedChildren:!1}];for(;n.length>0;){const O=n.pop();if(O==null)break;const r=I(t,O.nodeId);if(O.visitedChildren||!A(r)){A(r)&&t.snapshot.directories.delete(O.nodeId),Js(r,ur),t.pathCacheByNodeId.delete(O.nodeId),t.collapsedDirectoryIds.delete(O.nodeId)&&(t.hasCollapsedDirectoryOverrides=t.collapsedDirectoryIds.size>0),t.expandedDirectoryIds.delete(O.nodeId),nT(t,O.nodeId),t.activeNodeCount--,i.push(O.nodeId);continue}n.push({nodeId:O.nodeId,visitedChildren:!0});const s=we(t,O.nodeId);for(let o=s.childIds.length-1;o>=0;o--){const a=s.childIds[o];a!=null&&n.push({nodeId:a,visitedChildren:!1})}}return i}function Al(t,e){let i=e;for(;i!=null;){const n=I(t,i);if(!A(n)||je(n,bt)||we(t,i).childIds.length>0)return;Js(n,sn),i=n.parentId===i?null:n.parentId}}function _T(t,e){let i=t.snapshot.rootId;for(const n of e){const O=t.snapshot.segmentTable.idByValue.get(n);if(O==null)break;const r=Rn(t.snapshot.nodes,we(t,i)).get(O);if(r==null||!A(I(t,r)))break;i=r}return i}function an(t,e){const i=RT(t,e);if(i==null)return null;const n=Zn(t,i),O=I(t,n),r=i===n?null:io(t,i).map(s=>Te(t,s));return JSON.stringify({flattenedSegmentPaths:r,hasChildren:we(t,n).childIds.length>0,path:Te(t,n),terminalKind:Ks(O)})}function a$(t,e){return l$([t],[e])}function l$(t,e){for(let i=0;id$(t,e,i,n))}function h$(t,e){let i=e;for(;i!=null;){const n=I(t,i),O=n.subtreeNodeCount,r=n.visibleSubtreeCount;if(Ml(t,i,n),i===t.snapshot.rootId)return;const s=n.subtreeNodeCount-O,o=n.visibleSubtreeCount-r,a=n.parentId;(s!==0||o!==0)&&kl(we(t,a),i,s,o),i=a}}function d$(t,e,i,n){if(!A(i)){i.subtreeNodeCount=1,i.visibleSubtreeCount=1;return}const O=we(t,e);if(n){const o=t.instrumentation;o==null?Hs(t.snapshot.nodes,O):W(o,"store.recomputeNodeCounts.rebuildChildAggregates",()=>Hs(t.snapshot.nodes,O))}const r=1+O.totalChildSubtreeNodeCount,s=O.totalChildVisibleSubtreeCount;if(i.subtreeNodeCount=r,je(i,bt)){i.visibleSubtreeCount=s;return}i.visibleSubtreeCount=lO(t,e)!=null?s:gt(t,e,i)?1+s:1}function YT(t,e,i){const n=Te(t,e);return n.length===0?i:`${n}${i}`}function cO(t){return t!=null&&!je(t,ur)}function no(t,e){const i=t.snapshot.nodes[e];return!cO(i)||!A(i)||je(i,bt)?null:i}function zT(t){let e=0;for(const[i,n]of t.pathCacheByNodeId)n.version===t.pathCacheVersion&&cO(t.snapshot.nodes[i])&&(e+=1);return e}function VT(t){return Math.max(0,t.valueById.length-1)}function u$(t){return{activeNodeCount:t.activeNodeCount,cachedPathEntryCount:zT(t),loadInfoEntryCount:t.directoryLoadInfoById.size,segmentCount:VT(t.snapshot.segmentTable),totalNodeSlotCount:Math.max(0,t.snapshot.nodes.length-1)}}function qT(t,e,i,n){return{activeNodeCountAfter:n.activeNodeCount,activeNodeCountBefore:i.activeNodeCount,cachedPathEntryCountAfter:n.cachedPathEntryCount,cachedPathEntryCountBefore:i.cachedPathEntryCount,idsPreserved:e,loadInfoEntryCountAfter:n.loadInfoEntryCount,loadInfoEntryCountBefore:i.loadInfoEntryCount,mode:t,reclaimedCachedPathEntryCount:i.cachedPathEntryCount-n.cachedPathEntryCount,reclaimedLoadInfoEntryCount:i.loadInfoEntryCount-n.loadInfoEntryCount,reclaimedNodeSlotCount:i.totalNodeSlotCount-n.totalNodeSlotCount,reclaimedSegmentCount:i.segmentCount-n.segmentCount,segmentCountAfter:n.segmentCount,segmentCountBefore:i.segmentCount,totalNodeSlotCountAfter:n.totalNodeSlotCount,totalNodeSlotCountBefore:i.totalNodeSlotCount}}function f$(t){const e=[],i=[];for(const n of t.collapsedDirectoryIds)no(t,n)!=null&&e.push(Te(t,n));for(const n of t.expandedDirectoryIds)no(t,n)!=null&&i.push(Te(t,n));return{collapsedPaths:e,expandedPaths:i}}function $$(t){const e=[];for(const[i,n]of t.directoryLoadInfoById)no(t,i)==null||pr(t,i)==="loaded"||e.push({info:{activeAttemptId:null,errorMessage:n.errorMessage,nextAttemptId:n.nextAttemptId,state:n.state},path:Te(t,i)});return e}function Q$(t,e){t.collapsedDirectoryIds.clear(),t.hasCollapsedDirectoryOverrides=!1,t.expandedDirectoryIds.clear();for(const i of e.expandedPaths){const n=Dt(t,i);n!=null&&Qr(t,n,!0,I(t,n))}for(const i of e.collapsedPaths){const n=Dt(t,i);n!=null&&Qr(t,n,!1,I(t,n))}}function p$(t,e){t.directoryLoadInfoById.clear();for(const i of e){const n=Dt(t,i.path);n!=null&&no(t,n)!=null&&t.directoryLoadInfoById.set(n,{activeAttemptId:null,errorMessage:i.info.errorMessage,nextAttemptId:i.info.nextAttemptId,state:i.info.state})}}function UT(t){t.pathCacheVersion+=1,t.pathCacheByNodeId.clear(),t.pathCacheByNodeId.set(t.snapshot.rootId,{path:"",version:t.pathCacheVersion})}function WT(t){const e=t.snapshot.segmentTable,i=Ef();for(const n of t.snapshot.nodes)if(cO(n)){if(je(n,bt)){n.nameId=0;continue}n.nameId=on(i,$i(e,n.nameId))}t.snapshot.segmentTable=i}function CT(t){for(const[e,i]of t.snapshot.directories){const n=t.snapshot.nodes[e];if(!cO(n)||!A(n)){t.snapshot.directories.delete(e);continue}const O=i.childIds.filter(r=>{const s=t.snapshot.nodes[r];return cO(s)&&s.parentId===e});i.childIds=O,i.childIdByNameId=new Map(O.map(r=>[I(t,r).nameId,r])),i.childPositionById=new Map(O.map((r,s)=>[r,s])),Hs(t.snapshot.nodes,i)}}function jT(t){let e=t.snapshot.nodes.length-1;for(;e>t.snapshot.rootId;){const i=t.snapshot.nodes[e];if(cO(i))break;e-=1}t.snapshot.nodes.length=e+1}function GT(t){const e=f$(t),i=$$(t);W(t.instrumentation,"store.cleanup.stable.clearPathCaches",()=>UT(t)),W(t.instrumentation,"store.cleanup.stable.rebuildSegmentTable",()=>WT(t)),W(t.instrumentation,"store.cleanup.stable.rebuildDirectoryIndexes",()=>CT(t)),W(t.instrumentation,"store.cleanup.stable.trimTrailingRemovedNodeSlots",()=>jT(t)),W(t.instrumentation,"store.cleanup.stable.restoreExpansionOverrides",()=>Q$(t,e)),W(t.instrumentation,"store.cleanup.stable.restoreDirectoryLoadInfos",()=>p$(t,i)),W(t.instrumentation,"store.cleanup.stable.recomputeCounts",()=>Gl(t,t.snapshot.rootId))}function ET(t){const e=f$(t),i=$$(t),n=W(t.instrumentation,"store.cleanup.aggressive.listPaths",()=>e$(t)),O=Zx({...t.snapshot.options},t.instrumentation),r=W(t.instrumentation,"store.cleanup.aggressive.rebuildSnapshot",()=>{const s=new Lf(O);return s.appendPaths(n),s.finish()});t.snapshot=r,t.activeNodeCount=r.nodes.length-1,t.pathCacheByNodeId=new Map([[r.rootId,{path:"",version:0}]]),t.pathCacheVersion=0,W(t.instrumentation,"store.cleanup.aggressive.restoreExpansionOverrides",()=>Q$(t,e)),W(t.instrumentation,"store.cleanup.aggressive.restoreDirectoryLoadInfos",()=>p$(t,i)),W(t.instrumentation,"store.cleanup.aggressive.recomputeCounts",()=>Gl(t,t.snapshot.rootId))}function IT(t){for(const e of t.directoryLoadInfoById.values())if(e.state==="loading"&&e.activeAttemptId!=null)return!0;return!1}function AT(t,e){const i=u$(t);e==="stable"?W(t.instrumentation,"store.cleanup.stable",()=>GT(t)):W(t.instrumentation,"store.cleanup.aggressive",()=>ET(t));const n=u$(t);return qT(e,e==="stable",i,n)}const MT=64;function DT(t,e){const i=e+2;if(i<=t.length)return t;let n=t.length;for(;n=i)return null;const n=g$(t,t.snapshot.rootId,e,0,-1,[]),O=n.ancestors.map(s=>Te(t,s.cursor.terminalNodeId));let r=null;return{ancestorPaths:O,get ancestorRows(){if(r!=null)return r;const s=[],o=[];for(const a of n.ancestors){const l=LT(t,a,i,[...o]);s.push(l),o.push(l.row.path)}return r=s,r},index:n.index,posInSet:n.posInSet,row:mr(t,n.cursor),setSize:n.setSize,subtreeEndIndex:m$(t,n.cursor,n.index,i)}}function FT(t,e,i){const n=t.instrumentation,O=tt(t);if(O<=0||iS$(t,r));for(let h=r;h<=s&&c!=null;h++){const d=W(n,"store.getVisibleSlice.materializeRow",()=>mr(t,c));o.push(d),d.isFlattened&&(a++,l+=d.flattenedSegments?.length??0),c=W(n,"store.getVisibleSlice.advanceCursor",()=>y$(t,c))}return eo(n,"workload.visibleRowsRead",o.length),eo(n,"workload.flattenedRowsRead",a),eo(n,"workload.flattenedSegmentsRead",l),o}function P$(t,e=tt(t)){const i=t.instrumentation;return i==null?x$(t,e):W(i,"store.getVisibleTreeProjection",()=>x$(t,e))}function HT(t){return iw(P$(t))}function KT(t,e){const i=Dt(t,e);if(i==null||i===t.snapshot.rootId||A(I(t,i))&&Zn(t,i)!==i)return null;let n=0,O=i;const{nodes:r,rootId:s}=t.snapshot;for(;O!==s;){const o=I(t,O).parentId,a=we(t,o),l=Fs(a).get(O);if(l==null)throw new Error(`Child ${String(O)} was not found in its parent index`);if(n+=vx(r,a,l),o!==s){const c=I(t,o),h=lO(t,o);if(!gt(t,o,c)&&h!==O)return null;Zn(t,o)===o&&(n+=1)}O=o}return n}function JT(t,e){const i=Dt(t,e);if(i==null)throw new Error(`Path does not exist: "${e}"`);const n=I(t,i);if(!A(n))throw new Error(`Path is not a directory: "${e}"`);return gt(t,i,n)?null:(Qr(t,i,!0,n),Yn(t,i),aT({affectedAncestorIds:ni(t,i),affectedNodeIds:[i],path:e}))}function ew(t,e){const i=Dt(t,e);if(i==null)throw new Error(`Path does not exist: "${e}"`);const n=I(t,i);if(!A(n))throw new Error(`Path is not a directory: "${e}"`);return gt(t,i,n)?(Qr(t,i,!1,n),Yn(t,i),lT({affectedAncestorIds:ni(t,i),affectedNodeIds:[i],path:e})):null}function S$(t,e){return e<0||e>=tt(t)?null:X$(t,t.snapshot.rootId,e,-1)}function X$(t,e,i,n){const O=we(t,e),r=t.instrumentation,{childIndex:s,localVisibleIndex:o}=r==null?_l(t.snapshot.nodes,O,i):W(r,"store.getVisibleSlice.selectChildIndex",()=>_l(t.snapshot.nodes,O,i)),a=O.childIds[s];if(a!=null)return Dl(t,a,o,n+1);throw new Error(`Visible index ${String(i)} is out of range`)}function Dl(t,e,i,n){if(!A(I(t,e))){if(i===0)return{headNodeId:e,terminalNodeId:e,visibleDepth:n};throw new Error(`Visible index ${String(i)} is out of range for file`)}const O=b$(t,e,n);if(i===0)return O;const r=I(t,O.terminalNodeId);if(!A(r)||!gt(t,O.terminalNodeId,r))throw new Error(`Visible index ${String(i)} is out of range for collapsed directory`);return X$(t,O.terminalNodeId,i-1,O.visibleDepth)}function b$(t,e,i){return A(I(t,e))?t.instrumentation==null?{headNodeId:e,terminalNodeId:Zn(t,e),visibleDepth:i}:{headNodeId:e,terminalNodeId:W(t.instrumentation,"store.getVisibleSlice.flatten.resolveTerminalDirectory",()=>Zn(t,e)),visibleDepth:i}:{headNodeId:e,terminalNodeId:e,visibleDepth:i}}function tw(t,e){const i=I(t,e);if(!A(i))return!0;const n=i.parentId;return n===t.snapshot.rootId?!0:lO(t,n)!==e}function y$(t,e){const i=I(t,e.terminalNodeId);if(A(i)){const r=we(t,e.terminalNodeId);if(gt(t,e.terminalNodeId,i)&&r.childIds.length>0){const s=r.childIds[0];return s==null?null:Dl(t,s,0,e.visibleDepth+1)}}let n=e.terminalNodeId,O=e.visibleDepth;for(;;){const r=I(t,n);if(n===t.snapshot.rootId)return null;const s=r.parentId,o=we(t,s),a=Fs(o).get(n)??-1;if(a<0)throw new Error(`Child ${String(n)} was not found in its parent index`);const l=o.childIds[a+1]??null;if(l!=null)return Dl(t,l,0,O);tw(t,n)&&O--,n=s}}function iw(t){const e=t.paths.length,i=new Array(e);for(let n=0;n=0?t.paths[O]??null:null,path:t.paths[n]??"",posInSet:t.posInSetByIndex[n]??0,setSize:t.setSizeByIndex[n]??0}}return{getParentIndex:t.getParentIndex,rows:i,get visibleIndexByPath(){return t.visibleIndexByPath}}}function x$(t,e){const i=new Array(e),n=new Int32Array(e),O=new Int32Array(e),r=new Int32Array(e);let s=new Int32Array(MT);s.fill(-1);let o=0;const{nodes:a,directories:l,segmentTable:c}=t.snapshot,h=[[l.get(t.snapshot.rootId),0,-1,""]],d=t.snapshot.options.flattenEmptyDirectories,u=t.pathCacheByNodeId,$=t.pathCacheVersion,Q=c.valueById;for(;h.length>0&&o=X.childIds.length){h.pop();continue}const y=b[1],T=X.childIds[b[1]++],C=a[T],G=b[2]+1,J=b[3];s=DT(s,G);let j,V=T;if(A(C))V=d?Zn(t,T):T,j=V===T?`${J}${Q[C.nameId]}/`:Te(t,V);else{const L=u.get(T);j=L!=null&&L.version===$?L.path:`${J}${Q[C.nameId]}`}n[o]=s[G],i[o]=j,O[o]=y,r[o]=X.childIds.length,s[G+1]=o,o+=1;const B=a[V];B!=null&&A(B)&>(t,V,B)&&h.push([l.get(V),0,G,j])}o=o?-1:p[b]??-1},paths:i,posInSetByIndex:m,setSizeByIndex:P,get visibleIndexByPath(){if(g==null){g=new Map;for(let b=0;b0&&n=u.childIds.length){o.pop();continue}const $=u.childIds[d[1]++],Q=O[$],p=d[2]+1;if(!A(Q)){const b=c.get($);i[n++]={depth:p,flattenedSegments:void 0,hasChildren:!1,id:$,isExpanded:!1,isFlattened:!1,isLoading:!1,kind:"file",loadState:void 0,name:a[Q.nameId],path:b!=null&&b.version===h?b.path:Te(t,$)};continue}const m=l?Zn(t,$):$,P={headNodeId:$,terminalNodeId:m,visibleDepth:p};i[n++]=mr(t,P);const g=O[m];g!=null&&A(g)&>(t,m,g)&&o.push([r.get(m),0,p])}return n0,o=e.headNodeId!==e.terminalNodeId,a=t.instrumentation,l=o?a==null?io(t,e.headNodeId).map(c=>{const h=I(t,c);return{isTerminal:c===e.terminalNodeId,name:$i(t.snapshot.segmentTable,h.nameId),nodeId:c,path:Te(t,c)}}):W(a,"store.getVisibleSlice.flatten.collectSegments",()=>io(t,e.headNodeId).map(c=>{const h=I(t,c);return{isTerminal:c===e.terminalNodeId,name:$i(t.snapshot.segmentTable,h.nameId),nodeId:c,path:Te(t,c)}})):void 0;return{depth:e.visibleDepth,flattenedSegments:l,hasChildren:s,id:e.terminalNodeId,isExpanded:A(i)&>(t,e.terminalNodeId,i),isFlattened:o,isLoading:n==="loading",kind:A(i)?"directory":"file",loadState:n==null||n==="loaded"?void 0:n,name:r,path:O}}function Ow(t,e){if(e.headNodeId===e.terminalNodeId)return pr(t,e.terminalNodeId);const i=io(t,e.headNodeId);let n=!1,O=!1;for(const r of i){const s=pr(t,r);if(s==="loading")return"loading";if(s==="error"){O=!0;continue}s==="unloaded"&&(n=!0)}return O?"error":n?"unloaded":"loaded"}function rw(t){const{directories:e,nodes:i,options:n,rootId:O,presortedDirectoryNodeIds:r}=t.snapshot,s=n.flattenEmptyDirectories===!0,o=u=>{const $=i[u];if($==null||!A($))return;const Q=e.get(u);if(Q==null)throw new Error(`Unknown directory child index for node ${String(u)}`);const p=Q.childIds,m=p.length;let P=0,g=0;for(let X=0;X=wx&&dr(i,Q),$.subtreeNodeCount=1+P;let b;if(s&&m===1){const X=i[p[0]];b=X!=null&&A(X)?g:1+g}else b=1+g;$.visibleSubtreeCount=b};if(r!=null)for(let u=r.length-1;u>=0;u--)o(r[u]);else for(let u=i.length-1;u>=1;u--)o(u);const a=i[O],l=e.get(O);if(a==null||l==null)return;const c=l.childIds;let h=0,d=0;for(let u=0;unew Lf(e));if(e.preparedInput!=null){const o=Lx(e.preparedInput);o!=null?n.appendPresortedPaths(o,Nx(e.preparedInput)):n.appendPreparedPaths(Dx(e.preparedInput),!1)}else{const o=e.paths??[];e.presorted===!0?n.appendPaths(o):n.appendPreparedPaths(W(i,"store.preparePathEntries",()=>Wl(o,e)))}const O=W(i,"store.builder.finish",()=>n.finish({skipSubtreeCountPass:!0})),r=W(i,"store.state.detectAllDirectoriesExpanded",()=>(e.initialExpansion??"closed")==="closed"&&n.didMatchAllInitialExpandedPaths());this.#e=W(i,"store.state.create",()=>Bx(O,r?"open":e.initialExpansion??"closed",i)),r&&(this.#e.collapseNewDirectoriesByDefault=!0);const s=r?this.#e.snapshot.directories.size-1:W(i,"store.state.initializeExpandedPaths",()=>this.initializeExpandedPaths(e.initialExpandedPaths));r||sw(e)||(e.initialExpansion??"closed")==="closed"&&s===this.#e.snapshot.directories.size-1||(e.initialExpandedPaths?.length??0)>0&&W(i,"store.state.checkAllDirectoriesExpanded",()=>this.hasAllDirectoriesExpanded())?W(i,"store.state.initializeOpenVisibleCounts",()=>rw(this.#e)):W(i,"store.state.recomputeCounts",()=>Gl(this.#e,this.#e.snapshot.rootId))}static preparePaths(e,i={}){return Ix(e,i)}static prepareInput(e,i={}){return Ax(e,i)}static preparePresortedInput(e){return Mx(e)}list(e){return W(this.#e.instrumentation,"store.list",()=>e$(this.#e,e))}add(e){W(this.#e.instrumentation,"store.add",()=>{const i=tt(this.#e);ii(this.#e,yt(this.#e,i,t$(this.#e,e)))})}remove(e,i={}){W(this.#e.instrumentation,"store.remove",()=>{const n=tt(this.#e);ii(this.#e,yt(this.#e,n,i$(this.#e,e,i)))})}move(e,i,n={}){W(this.#e.instrumentation,"store.move",()=>{const O=tt(this.#e),r=n$(this.#e,e,i,n);r!=null&&ii(this.#e,yt(this.#e,O,r))})}batch(e){QT(this.#e,()=>{if(typeof e=="function"){e(this);return}for(const i of e)switch(i.type){case"add":this.add(i.path);break;case"remove":this.remove(i.path,{recursive:i.recursive});break;case"move":this.move(i.from,i.to,{collision:i.collision});break}})}getVisibleCount(){return W(this.#e.instrumentation,"store.getVisibleCount",()=>tt(this.#e))}getVisibleSlice(e,i){return W(this.#e.instrumentation,"store.getVisibleSlice",()=>FT(this.#e,e,i))}getVisibleRowContext(e){return W(this.#e.instrumentation,"store.getVisibleRowContext",()=>BT(this.#e,e))}getVisibleTreeProjection(){return HT(this.#e)}getVisibleTreeProjectionData(e){return P$(this.#e,e)}getVisibleIndex(e){return W(this.#e.instrumentation,"store.getVisibleIndex",()=>KT(this.#e,e))}getPathInfo(e){return W(this.#e.instrumentation,"store.getPathInfo",()=>{const i=Dt(this.#e,e);if(i==null)return null;const n=I(this.#e,i);return{depth:fi(n),kind:A(n)?"directory":"file",path:Te(this.#e,i)}})}isExpanded(e){return W(this.#e.instrumentation,"store.isExpanded",()=>{const i=this.requireDirectoryNodeId(e),n=I(this.#e,i);return gt(this.#e,i,n)})}expand(e){W(this.#e.instrumentation,"store.expand",()=>{const i=tt(this.#e),n=JT(this.#e,e);n!=null&&ii(this.#e,yt(this.#e,i,n))})}collapse(e){W(this.#e.instrumentation,"store.collapse",()=>{const i=tt(this.#e),n=ew(this.#e,e);n!=null&&ii(this.#e,yt(this.#e,i,n))})}on(e,i){return OT(this.#e,e,i)}getDirectoryLoadState(e){const i=this.requireDirectoryNodeId(e);return pr(this.#e,i)}markDirectoryUnloaded(e){W(this.#e.instrumentation,"store.markDirectoryUnloaded",()=>{const i=this.requireDirectoryNodeId(e);if(we(this.#e,i).childIds.length>0)throw new Error(`Cannot mark a directory with known children as unloaded: "${e}"`);const n=tt(this.#e);Jx(this.#e,i),ii(this.#e,yt(this.#e,n,cT({affectedAncestorIds:ni(this.#e,i),affectedNodeIds:[i],path:e,projectionChanged:this.isDirectoryProjectionVisible(i)})))})}beginChildLoad(e){return W(this.#e.instrumentation,"store.beginChildLoad",()=>{const i=this.requireDirectoryNodeId(e),n=tt(this.#e),O=Kx(this.#e,i);return ii(this.#e,yt(this.#e,n,hT({affectedAncestorIds:ni(this.#e,i),affectedNodeIds:[i],attemptId:O.attemptId,path:e,projectionChanged:this.isDirectoryProjectionVisible(i),reused:O.reused}))),O})}applyChildPatch(e,i){return W(this.#e.instrumentation,"store.applyChildPatch",()=>{const n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null||pr(this.#e,n)!=="loading"||!tT(this.#e,n,e.attemptId))return!1;const O=Te(this.#e,n);this.validateChildPatch(O,i);const r=tt(this.#e),s=[];for(const a of i.operations){ow(O,a);const l=tt(this.#e);switch(a.type){case"add":s.push(yt(this.#e,l,t$(this.#e,a.path)));break;case"remove":s.push(yt(this.#e,l,i$(this.#e,a.path,{recursive:a.recursive})));break;case"move":{const c=n$(this.#e,a.from,a.to,{collision:a.collision});c!=null&&s.push(yt(this.#e,l,c));break}}}const o=s.some(a=>a.projectionChanged)||this.isDirectoryProjectionVisible(n);return ii(this.#e,yt(this.#e,r,dT({affectedAncestorIds:ni(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,childEvents:s,path:Te(this.#e,n),projectionChanged:o}))),!0})}completeChildLoad(e){return W(this.#e.instrumentation,"store.completeChildLoad",()=>{const i=this.resolveActiveDirectoryNodeId(e.nodeId);if(i==null)return!1;const n=tt(this.#e),O=eT(this.#e,i,e.attemptId);return ii(this.#e,yt(this.#e,n,uT({affectedAncestorIds:ni(this.#e,i),affectedNodeIds:[i],attemptId:e.attemptId,path:Te(this.#e,i),projectionChanged:this.isDirectoryProjectionVisible(i),stale:!O}))),O})}failChildLoad(e,i){return W(this.#e.instrumentation,"store.failChildLoad",()=>{const n=this.resolveActiveDirectoryNodeId(e.nodeId);if(n==null)return!1;const O=tt(this.#e),r=iT(this.#e,n,e.attemptId,i);return ii(this.#e,yt(this.#e,O,fT({affectedAncestorIds:ni(this.#e,n),affectedNodeIds:[n],attemptId:e.attemptId,errorMessage:i,path:Te(this.#e,n),projectionChanged:this.isDirectoryProjectionVisible(n),stale:!r}))),r})}cleanup(e={}){return W(this.#e.instrumentation,"store.cleanup",()=>{if(this.#e.transactionStack.length>0)throw new Error("Cleanup cannot run during an open batch or transaction.");if(IT(this.#e))throw new Error("Cleanup cannot run while directory loads are active.");const i=tt(this.#e),n=AT(this.#e,e.mode??"stable");return ii(this.#e,yt(this.#e,i,$T({...n,affectedAncestorIds:[],affectedNodeIds:[],projectionChanged:n.idsPreserved===!1}))),n})}getNodeCount(){return this.#e.activeNodeCount}initializeExpandedPaths(e){if(e==null||e.length===0)return 0;let i=0;const n=[],O=[];let r=0,s=null;const o=this.#e.snapshot.segmentTable,a=o.valueById,l=this.#e.snapshot.nodes,c=new Map;for(const h of e){s!=null&&h0&&h.charCodeAt(h.length-1)===47?h.length-1:h.length;if(d===0){s=h,r=d,n.length=0,O.length=0;continue}let u=0,$=0;if(s!=null){const g=Math.min(d,r);let b=!0;for(let X=0;Xg&&h.charCodeAt(g)===47?(u+=1,$=g+1):g===d&&r>g&&s.charCodeAt(g)===47&&(u+=1,$=d+1)),u=Math.min(u,O.length)}let Q=u===0?this.#e.snapshot.rootId:O[u-1]??this.#e.snapshot.rootId,p=u,m=!0,P=$;for(;P<=d;){const g=h.indexOf("/",P),b=g===-1||g>d?d:g,X=h.slice(P,b),y=we(this.#e,Q).childIds,T=p===u?n[p]??0:0;let C=T,G;const J=c.get(X)??fr(X);c.set(X,J);const j=(V,B)=>{for(C=V;C0||he===0&&te>X)return!1}return!1};if(!j(T,y.length)&&T>0&&j(0,T),G===void 0){m=!1;break}if(!A(I(this.#e,G))){m=!1;break}if(n[p]=C,O[p]=G,Q=G,p+=1,b===d)break;P=b+1}if(s=h,r=d,n.length=p,O.length=p,!m){s=null,r=0,n.length=0,O.length=0;continue}for(let g=u;g "${e.to}"`);break}}const Ll={compact:{itemHeight:24,factor:.8},default:{itemHeight:30,factor:1},relaxed:{itemHeight:36,factor:1.2}};function aw(t,e){if(typeof t=="number")return{itemHeight:e??Ll.default.itemHeight,factor:t};const i=Ll[t??"default"];return{itemHeight:e??i.itemHeight,factor:i.factor}}const w$=Ll.default.itemHeight,lw=10,v$=420;var k$=`@layer base, theme, unsafe; + +@layer base { + :host { + /* + CSS variables use a fallback stack to ensure user and theme colors slot + in with ease. User colors take precedence over theme colors, which take + precedence over defaults. + + Fallback order: + + 1. --trees-*-override (explicit) + 2. --trees-theme-* (e.g. Shiki/VS Code tokens) + 3. defaults + + Theme variable names mirror Shiki/VS Code theme file JSON tokens. + + // Available CSS Color Overrides + --trees-fg-override + --trees-fg-muted-override + --trees-bg-override + --trees-bg-muted-override + --trees-accent-override + --trees-border-color-override + + --trees-focus-ring-color-override + --trees-focus-ring-width-override + --trees-focus-ring-offset-override + + --trees-search-fg-override + --trees-search-font-weight-override + --trees-search-bg-override + + --trees-selected-fg-override + --trees-selected-bg-override + --trees-selected-focused-border-color-override + + // Git Status Color Overrides + --trees-status-added-override + --trees-status-ignored-override + --trees-status-modified-override + --trees-status-renamed-override + --trees-status-untracked-override + --trees-status-deleted-override + --trees-git-added-color-override + --trees-git-ignored-color-override + --trees-git-modified-color-override + --trees-git-renamed-color-override + --trees-git-untracked-color-override + --trees-git-deleted-color-override + + // Built-in File Icon Color Overrides + --trees-file-icon-color + --trees-file-icon-color-astro + --trees-file-icon-color-babel + --trees-file-icon-color-bash + --trees-file-icon-color-biome + --trees-file-icon-color-bootstrap + --trees-file-icon-color-browserslist + --trees-file-icon-color-bun + --trees-file-icon-color-c + --trees-file-icon-color-cpp + --trees-file-icon-color-claude + --trees-file-icon-color-css + --trees-file-icon-color-database + --trees-file-icon-color-default + --trees-file-icon-color-docker + --trees-file-icon-color-eslint + --trees-file-icon-color-git + --trees-file-icon-color-go + --trees-file-icon-color-graphql + --trees-file-icon-color-html + --trees-file-icon-color-image + --trees-file-icon-color-javascript + --trees-file-icon-color-json + --trees-file-icon-color-markdown + --trees-file-icon-color-mcp + --trees-file-icon-color-npm + --trees-file-icon-color-oxc + --trees-file-icon-color-postcss + --trees-file-icon-color-prettier + --trees-file-icon-color-python + --trees-file-icon-color-react + --trees-file-icon-color-ruby + --trees-file-icon-color-rust + --trees-file-icon-color-sass + --trees-file-icon-color-svg + --trees-file-icon-color-svelte + --trees-file-icon-color-svgo + --trees-file-icon-color-swift + --trees-file-icon-color-table + --trees-file-icon-color-text + --trees-file-icon-color-tailwind + --trees-file-icon-color-terraform + --trees-file-icon-color-typescript + --trees-file-icon-color-vite + --trees-file-icon-color-vscode + --trees-file-icon-color-vue + --trees-file-icon-color-wasm + --trees-file-icon-color-webpack + --trees-file-icon-color-yml + --trees-file-icon-color-zig + --trees-file-icon-color-zip + + // Density + // + // A unitless scale factor for padding, gaps, and indentation. Usually + // set via \`density\` on useFileTree. Individual overrides take precedence. + // + // Compact: 0.8 + // Default: 1 + // Relaxed: 1.2 + // + --trees-density-override + + // Available CSS Layout Overrides + --trees-gap-override + --trees-border-radius-override + --trees-font-family-override + --trees-font-size-override + --trees-font-weight-regular-override + --trees-font-weight-semibold-override + --trees-level-gap-override + --trees-item-padding-x-override + --trees-item-margin-x-override + --trees-item-row-gap-override + --trees-icon-width-override + --trees-icon-nudge-override + --trees-scrollbar-gutter-override + --trees-padding-inline-override + */ + + --trees-accent: var(--trees-accent-override, #009fff); + --trees-fg: var( + --trees-fg-override, + var(--trees-theme-sidebar-fg, light-dark(#6c6c71, #adadb1)) + ); + --trees-fg-muted: var( + --trees-fg-muted-override, + var(--trees-theme-sidebar-header-fg, light-dark(#84848a, #84848a)) + ); + --trees-bg: var( + --trees-bg-override, + var(--trees-theme-sidebar-bg, light-dark(#f8f8f8, #141415)) + ); + /* var(--trees-theme-list-hover-bg, light-dark(#dfebff59, #19283c59)) */ + --trees-bg-muted: var( + --trees-bg-muted-override, + var( + --trees-theme-list-hover-bg, + light-dark( + color-mix( + in lab, + var(--trees-accent) var(--trees-bg-alpha-light, 8%), + var(--trees-bg) + ), + color-mix( + in lab, + var(--trees-accent) var(--trees-bg-alpha-dark, 10%), + var(--trees-bg) + ) + ) + ) + ); + --trees-input-bg: var( + --trees-input-bg-override, + light-dark(#f8f8f8, #070707) + ); + + --trees-added-light: #16a994; + --trees-added-dark: #00cab1; + --trees-ignored-light: #adadb1; + --trees-ignored-dark: #4a4a4e; + --trees-modified-light: #1ca1c7; + --trees-modified-dark: #08c0ef; + --trees-renamed-light: #d5a910; + --trees-renamed-dark: #ffd452; + --trees-untracked-light: #16a994; + --trees-untracked-dark: #00cab1; + --trees-deleted-light: #ff2e3f; + --trees-deleted-dark: #ff6762; + + --trees-border-color: var( + --trees-border-color-override, + var(--trees-theme-sidebar-border, light-dark(#eeeeef, #070707)) + ); + --trees-indent-guide-bg: var( + --trees-indent-guide-bg-override, + color-mix(in lab, var(--trees-fg-muted) 25%, transparent) + ); + --trees-density: var(--trees-density-override, 1); + --trees-border-radius: var( + --trees-border-radius-override, + calc(6px * var(--trees-density)) + ); + + --trees-font-family: var(--trees-font-family-override, system-ui); + --trees-font-size: var(--trees-font-size-override, 13px); + --trees-font-weight-regular: var(--trees-font-weight-regular-override, 400); + --trees-font-weight-semibold: var( + --trees-font-weight-semibold-override, + 600 + ); + + --trees-focus-ring-color: var( + --trees-focus-ring-color-override, + var(--trees-theme-focus-ring, var(--trees-accent)) + ); + --trees-focus-ring-width: var(--trees-focus-ring-width-override, 1px); + --trees-focus-ring-offset: var(--trees-focus-ring-offset-override, -1px); + + --trees-search-fg: var( + --trees-search-fg-override, + var(--trees-theme-input-fg, var(--trees-fg)) + ); + --trees-search-font-weight: var(--trees-search-font-weight-override, 600); + --trees-search-bg: var( + --trees-search-bg-override, + var(--trees-theme-input-bg, var(--trees-input-bg)) + ); + + --trees-scrollbar-thumb: var( + --trees-scrollbar-thumb-override, + var( + --trees-theme-scrollbar-thumb, + color-mix(in lab, var(--trees-fg) 25%, var(--trees-bg)) + ) + ); + + --trees-selected-fg: var( + --trees-selected-fg-override, + var(--trees-theme-list-active-selection-fg, var(--trees-fg)) + ); + --trees-selected-bg: var( + --trees-selected-bg-override, + var( + --trees-theme-list-active-selection-bg, + light-dark( + color-mix(in lab, var(--trees-accent) 12%, var(--trees-bg)), + color-mix(in lab, var(--trees-accent) 15%, var(--trees-bg)) + ) + ) + ); + --trees-selected-focused-border-color: var( + --trees-selected-focused-border-color-override, + var(--trees-theme-focus-ring, var(--trees-accent)) + ); + + /* Git status (e.g. from Shiki theme gitDecoration.*) */ + --trees-status-added: var( + --trees-status-added-override, + var( + --trees-theme-git-added-fg, + light-dark(var(--trees-added-light), var(--trees-added-dark)) + ) + ); + --trees-status-ignored: var( + --trees-status-ignored-override, + var( + --trees-theme-git-ignored-fg, + light-dark(var(--trees-ignored-light), var(--trees-ignored-dark)) + ) + ); + --trees-status-modified: var( + --trees-status-modified-override, + var( + --trees-theme-git-modified-fg, + light-dark(var(--trees-modified-light), var(--trees-modified-dark)) + ) + ); + --trees-status-renamed: var( + --trees-status-renamed-override, + var( + --trees-theme-git-renamed-fg, + light-dark(var(--trees-renamed-light), var(--trees-renamed-dark)) + ) + ); + --trees-status-untracked: var( + --trees-status-untracked-override, + var( + --trees-theme-git-untracked-fg, + light-dark(var(--trees-untracked-light), var(--trees-untracked-dark)) + ) + ); + --trees-status-deleted: var( + --trees-status-deleted-override, + var( + --trees-theme-git-deleted-fg, + light-dark(var(--trees-deleted-light), var(--trees-deleted-dark)) + ) + ); + --trees-git-modified-color: var( + --trees-git-modified-color-override, + var(--trees-status-modified) + ); + --trees-git-added-color: var( + --trees-git-added-color-override, + var(--trees-status-added) + ); + --trees-git-ignored-color: var( + --trees-git-ignored-color-override, + var(--trees-status-ignored) + ); + --trees-git-deleted-color: var( + --trees-git-deleted-color-override, + var(--trees-status-deleted) + ); + --trees-git-renamed-color: var( + --trees-git-renamed-color-override, + var(--trees-status-renamed) + ); + --trees-git-untracked-color: var( + --trees-git-untracked-color-override, + var(--trees-status-untracked) + ); + + --trees-icon-gray: light-dark(#84848a, #adadb1); + --trees-icon-red: light-dark(#d52c36, #ff6762); + --trees-icon-vermilion: light-dark(#ff8c5b, #d5512f); + --trees-icon-orange: light-dark(#d47628, #ffa359); + --trees-icon-yellow: light-dark(#d5a910, #ffd452); + --trees-icon-green: light-dark(#199f43, #5ecc71); + --trees-icon-teal: light-dark(#17a5af, #64d1db); + --trees-icon-cyan: light-dark(#1ca1c7, #68cdf2); + --trees-icon-blue: light-dark(#1a85d4, #69b1ff); + --trees-icon-indigo: light-dark(#693acf, #9d6afb); + --trees-icon-purple: light-dark(#a631be, #d568ea); + --trees-icon-pink: light-dark(#d32a61, #ff678d); + --trees-icon-mauve: light-dark(#594c5b, #79697b); + + --trees-file-icon-color-default: var( + --trees-file-icon-color, + var(--trees-icon-gray) + ); + --trees-file-icon-color-astro: var( + --trees-file-icon-color, + var(--trees-icon-purple) + ); + --trees-file-icon-color-babel: var( + --trees-file-icon-color, + var(--trees-icon-yellow) + ); + --trees-file-icon-color-bash: var( + --trees-file-icon-color, + var(--trees-icon-green) + ); + --trees-file-icon-color-biome: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-bootstrap: var( + --trees-file-icon-color, + var(--trees-icon-indigo) + ); + --trees-file-icon-color-browserslist: var( + --trees-file-icon-color, + var(--trees-icon-yellow) + ); + --trees-file-icon-color-bun: var( + --trees-file-icon-color, + var(--trees-icon-mauve) + ); + --trees-file-icon-color-c: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-cpp: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-claude: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-css: var( + --trees-file-icon-color, + var(--trees-icon-indigo) + ); + --trees-file-icon-color-database: var( + --trees-file-icon-color, + var(--trees-icon-purple) + ); + --trees-file-icon-color-docker: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-eslint: var( + --trees-file-icon-color, + var(--trees-icon-indigo) + ); + --trees-file-icon-color-git: var( + --trees-file-icon-vermilion, + var(--trees-icon-vermilion) + ); + --trees-file-icon-color-go: var( + --trees-file-icon-color, + var(--trees-icon-cyan) + ); + --trees-file-icon-color-graphql: var( + --trees-file-icon-color, + var(--trees-icon-pink) + ); + --trees-file-icon-color-html: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-image: var( + --trees-file-icon-color, + var(--trees-icon-pink) + ); + --trees-file-icon-color-javascript: var( + --trees-file-icon-color, + var(--trees-icon-yellow) + ); + --trees-file-icon-color-json: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-markdown: var( + --trees-file-icon-color, + var(--trees-icon-green) + ); + --trees-file-icon-color-mcp: var( + --trees-file-icon-color, + var(--trees-icon-teal) + ); + --trees-file-icon-color-npm: var( + --trees-file-icon-color, + var(--trees-icon-red) + ); + --trees-file-icon-color-oxc: var( + --trees-file-icon-cyan, + var(--trees-icon-cyan) + ); + --trees-file-icon-color-postcss: var( + --trees-file-icon-color, + var(--trees-icon-red) + ); + --trees-file-icon-color-prettier: var( + --trees-file-icon-color, + var(--trees-icon-teal) + ); + --trees-file-icon-color-python: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-react: var( + --trees-file-icon-color, + var(--trees-icon-cyan) + ); + --trees-file-icon-color-ruby: var( + --trees-file-icon-color, + var(--trees-icon-red) + ); + --trees-file-icon-color-rust: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-sass: var( + --trees-file-icon-color, + var(--trees-icon-pink) + ); + --trees-file-icon-color-svg: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-svelte: var( + --trees-file-icon-color, + var(--trees-icon-red) + ); + --trees-file-icon-color-svgo: var( + --trees-file-icon-color, + var(--trees-icon-green) + ); + --trees-file-icon-color-swift: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-table: var( + --trees-file-icon-color, + var(--trees-icon-teal) + ); + --trees-file-icon-color-text: var( + --trees-file-icon-color, + var(--trees-icon-gray) + ); + --trees-file-icon-color-tailwind: var( + --trees-file-icon-color, + var(--trees-icon-cyan) + ); + --trees-file-icon-color-terraform: var( + --trees-file-icon-color, + var(--trees-icon-indigo) + ); + --trees-file-icon-color-typescript: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-vite: var( + --trees-file-icon-color, + var(--trees-icon-purple) + ); + --trees-file-icon-color-vscode: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-vue: var( + --trees-file-icon-color, + var(--trees-icon-green) + ); + --trees-file-icon-color-wasm: var( + --trees-file-icon-color, + var(--trees-icon-indigo) + ); + --trees-file-icon-color-webpack: var( + --trees-file-icon-color, + var(--trees-icon-blue) + ); + --trees-file-icon-color-yml: var( + --trees-file-icon-color, + var(--trees-icon-red) + ); + --trees-file-icon-color-zig: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + --trees-file-icon-color-zip: var( + --trees-file-icon-color, + var(--trees-icon-orange) + ); + + --trees-level-gap: var( + --trees-level-gap-override, + calc(8px * var(--trees-density)) + ); + --trees-item-padding-x: var( + --trees-item-padding-x-override, + calc(8px * var(--trees-density)) + ); + --trees-item-margin-x: var( + --trees-item-margin-x-override, + calc(2px * var(--trees-density)) + ); + --trees-item-row-gap: var( + --trees-item-row-gap-override, + calc(6px * var(--trees-density)) + ); + --trees-icon-width: var(--trees-icon-width-override, 16px); + --trees-icon-nudge: var( + --trees-icon-nudge-override, + calc(1px * var(--trees-density)) + ); + --trees-row-height: var(--trees-item-height, 30px); + --trees-git-lane-width: var(--trees-git-lane-width-override, 12px); + --trees-action-lane-width: var( + --trees-action-lane-width-override, + calc(var(--trees-icon-width) + 2px) + ); + /* Keep the floating trigger aligned with the row's action lane. Going in + from the root's right edge: the scroll container reserves + \`--trees-padding-inline\` of effective inset on each side (its asymmetric + padding formula cancels the scrollbar gutter on the right), the row + sits inside that inset, and its trailing \`--trees-item-padding-x\` is the + action lane itself. The trigger's own focus-ring margin then trims one + pixel back so the button's visible right edge lines up with the lane. */ + --trees-context-menu-trigger-inline-offset: calc( + var(--trees-padding-inline) + var(--trees-item-padding-x) - + var(--trees-focus-ring-width) + ); + + --trees-scrollbar-gutter: var(--trees-scrollbar-gutter-override, 6px); + --trees-padding-inline: var(--trees-padding-inline-override, 16px); + + color-scheme: light dark; + display: flex; + flex-direction: column; + font-size: var(--trees-font-size); + color: var(--trees-fg); + background-color: var(--trees-bg); + --truncate-marker-background-color: var(--trees-bg); + --truncate-marker-background-overlay-color: transparent; + font-family: var(--trees-font-family); + font-weight: var(--trees-font-weight-regular); + } + + :host([data-file-tree-virtualized='true']) { + height: 100%; + overflow: hidden; + } + + [data-file-tree-virtualized-wrapper='true'] { + height: 100%; + overflow: hidden; + display: flex; + flex-direction: column; + } + + [data-file-tree-virtualized-root='true'] { + height: 100%; + display: flex; + flex-direction: column; + overflow: hidden; + } + + [data-file-tree-virtualized-scroll='true'], + [data-file-tree-scrollbar-measure='true'] { + --trees-scrollbar-thumb-current: transparent; + overflow-y: auto; + scrollbar-gutter: stable; + + &:hover { + --trees-scrollbar-thumb-current: var(--trees-scrollbar-thumb); + } + + &::-webkit-scrollbar { + width: var(--trees-scrollbar-gutter); + height: var(--trees-scrollbar-gutter); + } + + &::-webkit-scrollbar-track { + background: transparent; + } + + &::-webkit-scrollbar-thumb { + background-color: var(--trees-scrollbar-thumb-current); + border: 1px solid transparent; + background-clip: content-box; + border-radius: calc(var(--trees-scrollbar-gutter) / 2); + } + + &::-webkit-scrollbar-corner { + background-color: transparent; + } + } + + /* These are styles for a temporarily generated element to measure the size + * of the scrollbar. It's intended to be somewhat similar in scrollbar style + * scope to the scrollable tree so \`--trees-scrollbar-gutter-measured\` is an + * accurate reflection of the size the scrollbar gutter takes up. */ + [data-file-tree-scrollbar-measure='true'] { + position: absolute; + top: 0; + left: 0; + visibility: hidden; + pointer-events: none; + width: 100px; + height: 100px; + } + + @supports (-moz-appearance: none) { + [data-file-tree-virtualized-scroll='true'], + [data-file-tree-scrollbar-measure='true'] { + scrollbar-width: thin; + scrollbar-color: var(--trees-scrollbar-thumb-current) transparent; + } + } + + [data-file-tree-virtualized-scroll='true'] { + position: relative; + overflow-y: auto; + flex: 1 1 0; + min-height: 0; + padding-inline: max( + calc(var(--trees-padding-inline) - var(--trees-item-margin-x)), + 0px + ) + /* NOTE(amadeus): We can assume that all Webkit based browser gutters + * will align to the value of '--trees-scrollbar-gutter', however if not, then + * \`--trees-scrollbar-gutter-measured\` should correct it. Mostly we are + * hoping to avoid SSR alignment jumps if possible. In non-SSR'd environments + * \`--trees-scrollbar-gutter-measured\` should always be immediately available. + */ + max( + calc( + var(--trees-padding-inline) - var(--trees-item-margin-x) - + var( + --trees-scrollbar-gutter-measured, + var(--trees-scrollbar-gutter) + ) + ), + 0px + ); + } + + @supports (-moz-appearance: none) { + [data-file-tree-virtualized-scroll='true'] { + padding-inline: max( + calc(var(--trees-padding-inline) - var(--trees-item-margin-x)), + 0px + ) + /* NOTE(amadeus): However on Firefox it can vary a little bit, but most + * likely the majority of cases will default to a 0px width scrollbar lets + * inherit that first to avoid SSR jumps. In non-SSR'd environments + * \`--trees-scrollbar-gutter-measured\` should always be immediately available. + */ + max( + calc( + var(--trees-padding-inline) - var(--trees-item-margin-x) - + var(--trees-scrollbar-gutter-measured, 0px) + ), + 0px + ); + } + } + + [data-file-tree-sticky-overlay='true'] { + position: sticky; + top: 0; + height: 0; + z-index: 4; + overflow: visible; + pointer-events: none; + } + + /* The overlay DOM is kept populated even at scrollTop=0 so the browser has + * the rendered rows on hand the moment scrolling begins — otherwise the + * compositor paints a scrolled frame before React can mount the overlay, + * and the topmost sticky folder jumps up by a couple of pixels before it + * "snaps" into its pinned position. We hide it via CSS whenever the scroll + * is at the top and no scroll is in progress, so the preview doesn't leak + * through at rest. \`data-overlay-reveal\` is stamped on the root only when + * the user initiates a scroll while already at the top — exactly the case + * where we need the pre-mounted overlay to be visible through the first + * compositor frame. It is deliberately distinct from the general + * \`data-is-scrolling\` flag so a scroll that ends at the top (e.g. ArrowUp + * navigation) re-hides the overlay the instant the scroll lands, rather + * than waiting for the hover-suppression timer to elapse. */ + [data-file-tree-virtualized-root='true'][data-scroll-at-top='true']:not( + [data-overlay-reveal] + ) + [data-file-tree-sticky-overlay='true'] { + visibility: hidden; + } + + [data-file-tree-sticky-overlay-content='true'] { + background-color: var(--trees-bg); + position: relative; + pointer-events: none; + } + + [data-file-tree-virtualized-list='true'] { + background-color: var(--trees-bg); + position: relative; + min-height: 100%; + width: 100%; + overflow-anchor: none; + + &[data-is-scrolling] { + pointer-events: none; + } + } + + [data-file-tree-virtualized-sticky-offset='true'] { + contain: layout size; + } + + [data-file-tree-virtualized-sticky='true'] { + position: sticky; + top: 0; + width: 100%; + display: flex; + flex-direction: column; + isolation: isolate; + /* Promote to its own compositor layer so text inside the window is + * rasterized once and GPU-translated during scroll. Without this, the + * browser re-paints the window (and its text) at every scroll frame, + * which produces visible 1px shake / character tearing. */ + will-change: transform; + } + + [data-file-tree-search-container] { + display: flex; + padding: 0; + padding-inline: var(--trees-padding-inline); + margin-bottom: var(--trees-item-row-gap); + } + + [data-file-tree-search-input] { + --trees-focus-ring-width: 2px; + font-family: var(--trees-font-family); + font-size: var(--trees-font-size); + flex: 1; + height: var(--trees-row-height); + /* 1px breathing room so the focus-visible outline isn't clipped when the + * input sits flush against the top of the scroll container. */ + margin-block: 1px; + padding-inline: var(--trees-item-padding-x); + line-height: var(--trees-row-height); + color: var(--trees-search-fg); + background-color: var(--trees-search-bg); + border: 1px solid var(--trees-border-color); + border-radius: var(--trees-border-radius); + outline: none; + + &::placeholder { + color: color-mix( + in lab, + var(--trees-search-fg) 65%, + var(--trees-search-bg) + ); + } + + &:focus-visible, + &[data-file-tree-search-input-fake-focus='true'] { + outline: var(--trees-focus-ring-width) solid var(--trees-focus-ring-color); + outline-offset: var(--trees-focus-ring-offset); + } + } + + /* The wrapper for the tree items */ + [role='tree'] { + position: relative; + display: flex; + flex-direction: column; + gap: var(--trees-gap-override, 0); + } + + /* LIST ITEM */ + [data-type='item'] { + color: inherit; + font-family: var(--trees-font-family); + font-size: var(--trees-font-size); + text-align: start; + outline: none; + background-color: var(--trees-bg); + border: none; + position: relative; + + padding: 0 var(--trees-item-padding-x); + margin: 0 var(--trees-item-margin-x); + cursor: pointer; + -webkit-user-select: none; + user-select: none; + -webkit-touch-callout: none; + touch-action: manipulation; + display: flex; + flex: 0 0 var(--trees-row-height); + align-items: center; + height: var(--trees-row-height); + line-height: var(--trees-row-height); + gap: var(--trees-item-row-gap); + border-radius: var(--trees-border-radius); + /* Row states may be translucent, so markers paint the tree background first + * and then the state color on top to avoid compositing the same alpha twice. */ + --truncate-marker-background-color: var(--trees-bg); + --truncate-marker-background-overlay-color: transparent; + --truncate-marker-block-inset: 0px; + + &:hover, + &[data-item-context-hover='true'] { + background-color: var(--trees-bg-muted); + --truncate-marker-background-overlay-color: var(--trees-bg-muted); + } + + &[data-item-focused='true'], + &:focus-visible { + z-index: 2; + + /* Flattened segment markers sit high enough to cover the row outline unless + * their painted background is inset by the focus ring width. */ + [data-item-flattened-subitems] { + --truncate-marker-block-inset: var(--trees-focus-ring-width); + } + + &::before { + position: absolute; + inset: 0; + content: ''; + display: block; + border-radius: var(--trees-border-radius); + outline: var(--trees-focus-ring-width) solid + var(--trees-focus-ring-color); + outline-offset: var(--trees-focus-ring-offset); + pointer-events: none; + } + + &[data-item-selected='true']::before { + outline-color: var(--trees-selected-focused-border-color); + } + } + + &[data-item-selected='true'] { + color: var(--trees-selected-fg); + background-color: var(--trees-selected-bg); + --truncate-marker-background-overlay-color: var(--trees-selected-bg); + z-index: 3; + + [data-item-section='icon'] { + color: var(--trees-selected-fg); + } + } + + &[data-item-search-match='true'] { + font-weight: var(--trees-search-font-weight); + } + } + + [data-type='item'][data-file-tree-sticky-row='true'] { + pointer-events: auto; + } + + /* Sticky rows opt back into pointer events because the overlay wrapper is + * inert. During scroll, put them back under the same hover suppression as + * the virtualized list so translucent hover states and menu triggers do not + * paint over rows moving beneath the sticky stack. */ + [data-file-tree-virtualized-root='true'][data-is-scrolling] + [data-type='item'][data-file-tree-sticky-row='true'] { + pointer-events: none; + } + + [data-file-tree-virtualized-root='true'][data-is-scrolling] + [data-type='item'][data-file-tree-sticky-row='true']:hover:not( + [data-item-selected='true'] + ), + [data-file-tree-virtualized-root='true'][data-is-scrolling] + [data-type='item'][data-file-tree-sticky-row='true'][data-item-context-hover='true']:not( + [data-item-selected='true'] + ) { + background-color: var(--trees-bg); + --truncate-marker-background-overlay-color: transparent; + } + + [data-item-selected='true']:has(+ [data-item-selected='true']) { + border-bottom-left-radius: 0; + border-bottom-right-radius: 0; + } + + [data-item-selected='true'] + [data-item-selected='true'] { + border-top-left-radius: 0; + border-top-right-radius: 0; + } + + /* Flattened Directory Parts */ + [data-item-flattened-subitems] { + display: inline-flex; + align-items: center; + gap: 2px; + } + [data-item-flattened-subitem]:hover, + [data-item-flattened-subitem-drag-target='true'] { + text-decoration: underline; + } + + /* Icon for each item */ + [data-item-section='icon'] { + flex-shrink: 0; + display: flex; + align-items: center; + justify-content: center; + color: var(--trees-fg-muted); + fill: currentColor; + width: var(--trees-icon-width); + } + + :where([data-item-section='icon'] > [data-icon-token]) { + color: var(--trees-fg-muted); + } + + [data-file-tree-colored-icons='true'] { + [data-icon-token='astro'] { + color: var(--trees-file-icon-color-astro); + } + [data-icon-token='babel'] { + color: var(--trees-file-icon-color-babel); + } + [data-icon-token='bash'] { + color: var(--trees-file-icon-color-bash); + } + [data-icon-token='biome'] { + color: var(--trees-file-icon-color-biome); + } + [data-icon-token='bootstrap'] { + color: var(--trees-file-icon-color-bootstrap); + } + [data-icon-token='browserslist'] { + color: var(--trees-file-icon-color-browserslist); + } + [data-icon-token='bun'] { + color: var(--trees-file-icon-color-bun); + } + [data-icon-token='c'] { + color: var(--trees-file-icon-color-c); + } + [data-icon-token='cpp'] { + color: var(--trees-file-icon-color-cpp); + } + [data-icon-token='claude'] { + color: var(--trees-file-icon-color-claude); + } + [data-icon-token='css'] { + color: var(--trees-file-icon-color-css); + } + [data-icon-token='database'] { + color: var(--trees-file-icon-color-database); + } + [data-icon-token='default'] { + color: var(--trees-file-icon-color-default); + } + [data-icon-token='docker'] { + color: var(--trees-file-icon-color-docker); + } + [data-icon-token='eslint'] { + color: var(--trees-file-icon-color-eslint); + } + [data-icon-token='git'] { + color: var(--trees-file-icon-color-git); + } + [data-icon-token='go'] { + color: var(--trees-file-icon-color-go); + } + [data-icon-token='graphql'] { + color: var(--trees-file-icon-color-graphql); + } + [data-icon-token='html'] { + color: var(--trees-file-icon-color-html); + } + [data-icon-token='image'] { + color: var(--trees-file-icon-color-image); + } + [data-icon-token='javascript'] { + color: var(--trees-file-icon-color-javascript); + } + [data-icon-token='json'] { + color: var(--trees-file-icon-color-json); + } + [data-icon-token='markdown'] { + color: var(--trees-file-icon-color-markdown); + } + [data-icon-token='mcp'] { + color: var(--trees-file-icon-color-mcp); + } + [data-icon-token='npm'] { + color: var(--trees-file-icon-color-npm); + } + [data-icon-token='oxc'] { + color: var(--trees-file-icon-color-oxc); + } + [data-icon-token='postcss'] { + color: var(--trees-file-icon-color-postcss); + } + [data-icon-token='prettier'] { + color: var(--trees-file-icon-color-prettier); + } + [data-icon-token='python'] { + color: var(--trees-file-icon-color-python); + } + [data-icon-token='react'] { + color: var(--trees-file-icon-color-react); + } + [data-icon-token='ruby'] { + color: var(--trees-file-icon-color-ruby); + } + [data-icon-token='rust'] { + color: var(--trees-file-icon-color-rust); + } + [data-icon-token='sass'] { + color: var(--trees-file-icon-color-sass); + } + [data-icon-token='svg'] { + color: var(--trees-file-icon-color-svg); + } + [data-icon-token='svelte'] { + color: var(--trees-file-icon-color-svelte); + } + [data-icon-token='svgo'] { + color: var(--trees-file-icon-color-svgo); + } + [data-icon-token='swift'] { + color: var(--trees-file-icon-color-swift); + } + [data-icon-token='table'] { + color: var(--trees-file-icon-color-table); + } + [data-icon-token='text'] { + color: var(--trees-file-icon-color-text); + } + [data-icon-token='tailwind'] { + color: var(--trees-file-icon-color-tailwind); + } + [data-icon-token='terraform'] { + color: var(--trees-file-icon-color-terraform); + } + [data-icon-token='typescript'] { + color: var(--trees-file-icon-color-typescript); + } + [data-icon-token='vite'] { + color: var(--trees-file-icon-color-vite); + } + [data-icon-token='vscode'] { + color: var(--trees-file-icon-color-vscode); + } + [data-icon-token='vue'] { + color: var(--trees-file-icon-color-vue); + } + [data-icon-token='wasm'] { + color: var(--trees-file-icon-color-wasm); + } + [data-icon-token='webpack'] { + color: var(--trees-file-icon-color-webpack); + } + [data-icon-token='yml'] { + color: var(--trees-file-icon-color-yml); + } + [data-icon-token='zig'] { + color: var(--trees-file-icon-color-zig); + } + [data-icon-token='zip'] { + color: var(--trees-file-icon-color-zip); + } + } + + /* Chevron rotation and visual alignment */ + /* Chevron pointing down */ + [data-icon-name='file-tree-icon-chevron'] { + &[data-align-capitals='false'] { + transform: translate(0, var(--trees-icon-nudge)); + } + &[data-align-capitals='true'] { + transform: translate(0, 0); + } + } + + [data-item-section='content'] { + flex: 0 1 auto; + text-align: start; + min-width: 0; + max-width: 100%; + overflow: hidden; + text-overflow: ellipsis; + /* Breaks middle truncate component to also set this */ + /* white-space: nowrap; */ + } + + [data-item-section='decoration'] { + flex: 1 1 0; + min-width: 0; + display: flex; + justify-content: flex-end; + text-align: end; + overflow: hidden; + color: var(--trees-fg-muted); + } + + [data-item-section='decoration'] > span { + min-width: 0; + max-width: 100%; + display: inline-flex; + align-items: center; + justify-content: flex-end; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + + [data-item-section='git'], + [data-item-section='action'] { + flex: 0 0 auto; + display: flex; + align-items: center; + justify-content: center; + } + + [data-item-section='git'] { + width: var(--trees-git-lane-width); + } + + [data-item-section='action'] { + width: var(--trees-action-lane-width); + color: var(--trees-fg-muted); + fill: currentColor; + pointer-events: none; + } + + [data-item-section='git'] > span, + [data-item-section='action'] > span { + width: 100%; + display: inline-flex; + align-items: center; + justify-content: center; + } + + [data-item-action-affordance='decorative'] { + opacity: 0.85; + } + + [data-item-rename-input] { + appearance: none; + width: 100%; + min-width: 0; + height: calc(var(--trees-row-height) - 4px); + font-family: inherit; + font-size: inherit; + /* line-height: calc(var(--trees-row-height) - 8px); */ + color: inherit; + background-color: transparent; + border: 0; + padding-inline: 6px; + outline: none; + box-sizing: border-box; + } + + [data-item-section='content']:has([data-item-rename-input]) + ~ [data-item-section='action'], + [data-item-section='content']:has([data-item-rename-input]) + ~ [data-item-section='decoration'] { + display: none; + } + + /* Chevron pointing right */ + [aria-expanded='false'][data-item-type='folder'] + > [data-item-section='icon'] + > [data-icon-name='file-tree-icon-chevron'] { + &[data-align-capitals='true'] { + transform: rotate(-90deg) + translate( + calc(var(--trees-icon-nudge) / 2), + calc(var(--trees-icon-nudge) / 2) + ); + } + &[data-align-capitals='false'] { + transform: rotate(-90deg) + translate( + calc(var(--trees-icon-nudge) / 2 * -1), + calc(var(--trees-icon-nudge) / 2) + ); + } + } + + /* LIST IDENTATION */ + /* Spacing container */ + [data-item-section='spacing'] { + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + height: var(--trees-row-height); + padding-left: calc(calc(var(--trees-icon-width) / 2) - 0.5px); + + &:empty { + padding-left: 0; + } + } + + /* Spacing per level */ + [data-item-section='spacing-item'] { + transform: translateX(-0.25px); + display: inline-block; + border-left: 1px solid var(--trees-indent-guide-bg); + height: 100%; + margin-right: calc(var(--trees-level-gap) - 1px); + opacity: 0; + transition: opacity 150ms ease; + + & + & { + margin-left: calc( + var(--trees-item-row-gap) + calc(var(--trees-icon-width) / 2) - 0.5px + ); + } + } + + :host(:hover) [data-item-section='spacing-item'] { + opacity: 0.75; + } + + /* Git status indicator */ + + /* This is a folder that contains a git change */ + [data-item-contains-git-change='true'] > [data-item-section='git'] { + color: var(--trees-git-modified-color); + opacity: 0.5; + fill: currentColor; + } + + /* These are files that have a git change */ + [data-item-git-status] { + & + > :where([data-item-section='icon']) + > :where(:not([data-icon-name='file-tree-icon-chevron'])) { + color: var(--trees-item-git-status-color); + } + & > [data-item-section='content'] { + color: var(--trees-item-git-status-color); + } + & > [data-item-section='git'] { + color: var(--trees-item-git-status-color); + font-weight: var(--trees-font-weight-semibold); + } + } + + [data-item-git-status='added'] { + --trees-item-git-status-color: var(--trees-git-added-color); + } + + [data-item-git-status='deleted'] { + --trees-item-git-status-color: var(--trees-git-deleted-color); + } + + [data-item-git-status='ignored'] { + --trees-item-git-status-color: var(--trees-git-ignored-color); + + & > [data-item-section='icon'] { + opacity: 0.5; + } + } + + [data-item-section='git'] [data-icon-name='file-tree-icon-dot'] { + /* this is a nudge to align the dot with the likely lowercase text. it's slightly + generalizable, but other fonts are gonna need other nudges i assume */ + transform: translateY(calc(0.65ex - 50%)); + } + + [data-item-git-status='modified'] { + --trees-item-git-status-color: var(--trees-git-modified-color); + } + + [data-item-git-status='renamed'] { + --trees-item-git-status-color: var(--trees-git-renamed-color); + } + + [data-item-git-status='untracked'] { + --trees-item-git-status-color: var(--trees-git-untracked-color); + } + + /* Drag and drop */ + [data-item-drag-target='true'] { + background-color: var(--trees-selected-bg); + } + + [data-item-dragging='true'] { + opacity: 0.5; + } + + /* Lock icon for locked paths (sibling of content) */ + [data-item-section='lock'] { + flex: 0 0 auto; + margin-left: auto; + display: flex; + align-items: center; + color: var(--trees-fg-muted); + } + [data-item-section='lock'] svg { + display: block; + } + + [data-type='header-slot'] { + display: block; + flex: 0 0 auto; + } + + [data-type='context-menu-wash'] { + position: absolute; + inset: 0; + z-index: 3; + background-color: transparent; + touch-action: none; + } + + [data-type='context-menu-anchor'] { + position: absolute; + top: 0; + right: var(--trees-context-menu-trigger-inline-offset); + z-index: 4; + display: none; + align-items: center; + + &[data-visible='true'] { + display: flex; + } + } + + /* Hide the floating trigger while the scroll container is actively moving. + * The anchor is positioned against the root, not the scroll content, so its + * \`top\` follows the row via a React state update — one frame behind the + * compositor. That delay is visible as the trigger hovering over the wrong + * row during the first frame of a scroll. The \`data-is-scrolling\` flag on + * the root is flipped synchronously on \`wheel\`/\`touchmove\`/\`keydown\` before + * the compositor commits the next paint, so this selector hides the anchor + * in the same frame the scroll begins. */ + [data-file-tree-virtualized-root='true'][data-is-scrolling] + [data-type='context-menu-anchor'] { + display: none; + } + + [data-type='context-menu-anchor'] > slot[name='context-menu'] { + display: block; + width: 0; + min-width: 0; + flex: 0 0 0; + overflow: visible; + } + + /* Single floating context menu trigger */ + [data-type='context-menu-trigger'] { + all: unset; + align-items: center; + justify-content: center; + width: var(--trees-action-lane-width); + color: var(--trees-fg-muted); + fill: currentColor; + cursor: pointer; + font-family: var(--trees-font-family); + font-size: var(--trees-font-size); + border-top-right-radius: var(--trees-border-radius); + border-bottom-right-radius: var(--trees-border-radius); + margin: var(--trees-focus-ring-width); + height: calc(var(--trees-row-height) - var(--trees-focus-ring-width) * 2); + border-width: 0; + transition: color 120ms ease; + + display: flex; + } + + [data-type='context-menu-trigger']:hover, + [data-type='context-menu-trigger'][aria-expanded='true'] { + color: var(--trees-fg); + } + + /** @pierre/truncate css here, manually copy pasted for now */ + [data-truncate-container] { + /* CUSTOM TO TREES, TO SUPPORT THE OUTLINE */ + margin-top: -1px; + margin-bottom: -1px; + + /* Width of the fade from default marker to text */ + --truncate-internal-marker-fade-width: var( + --truncate-marker-fade-width, + 2px + ); + /* Width of the solid color between the fade from the default marker to the text */ + --truncate-internal-marker-gap: var(--truncate-marker-gap, 0px); + /* Opacity of the marker 'color' property, not of the element itself */ + --truncate-internal-marker-opacity: var(--truncate-marker-opacity, 50%); + /* Opacity of the marker 'color' property specifically for the middle truncate, not opacity of the element itself */ + --truncate-internal-middle-marker-opacity: var( + --truncate-middle-marker-opacity, + 80% + ); + /* Background color of the default marker */ + --truncate-internal-marker-background-color: var( + --truncate-marker-background-color, + light-dark(white, black) + ); + --truncate-internal-marker-background-overlay-color: var( + --truncate-marker-background-overlay-color, + transparent + ); + --truncate-internal-marker-block-inset: var( + --truncate-marker-block-inset, + 0px + ); + /* Duration of the fade out animation for the marker */ + --truncate-internal-marker-fade-out-duration: var( + --truncate-marker-fade-out-duration, + 0ms + ); + /* Duration of the fade in animation for the marker */ + --truncate-internal-marker-fade-in-duration: var( + --truncate-marker-fade-in-duration, + 100ms + ); + + /* FADE Variant specifics */ + --truncate-internal-fade-marker-color: var( + --truncate-fade-marker-color, + #000 + ); + --truncate-internal-fade-marker-width: var( + --truncate-fade-marker-width, + 0.2lh + ); + + /* + In some special cases people might be adding spacing in other ways + that would benefit from being able to override this, however the container + query below can't use this and would need to be redeclared with the overridden + value. It's a bad time, but better than nothing. + */ + --truncate-internal-single-line-height: 1lh; + + height: var(--truncate-internal-single-line-height); + min-width: 0; + overflow: hidden; + } + + [data-truncate-marker] { + display: flex; + position: absolute; + height: var(--truncate-internal-single-line-height); + padding-block: var(--truncate-internal-marker-block-inset); + box-sizing: border-box; + align-items: center; + background-clip: content-box; + z-index: 2; + color: color-mix( + in srgb, + currentColor var(--truncate-internal-marker-opacity), + transparent + ); + + /* Core trick for hiding the marker until overflow occurs */ + opacity: 0; + transition: opacity var(--truncate-internal-marker-fade-out-duration) + ease-in-out; + } + + @container measure (height > 1lh) { + [data-truncate-marker] { + opacity: 1; + transition: opacity var(--truncate-internal-marker-fade-in-duration) + ease-in-out; + } + } + + [data-truncate-grid] { + display: grid; + position: relative; + } + + [data-truncate-content='visible'] { + white-space: nowrap; + } + + [data-truncate-content='overflow'] { + opacity: 0; + pointer-events: none; + -webkit-user-select: none; + user-select: none; + word-break: break-all; + margin-top: calc(-1 * var(--truncate-internal-single-line-height)); + } + + [data-truncate-marker-cell] { + container: measure / size; + overflow: visible; + -webkit-user-select: none; + user-select: none; + pointer-events: none; + } + + [data-truncate-container='truncate'] { + & [data-truncate-grid] { + grid-template-columns: minmax(0, max-content) 0; + } + & [data-truncate-marker] { + right: 0; + } + & [data-truncate-fade] { + margin-right: calc(-2 * var(--truncate-internal-fade-marker-width)); + } + } + + [data-truncate-container='fruncate'] { + & [data-truncate-grid] { + grid-template-columns: 0 minmax(0, max-content) auto; + } + & [data-truncate-content] { + direction: rtl; + } + & [data-truncate-content] > span { + unicode-bidi: plaintext; + } + & [data-truncate-fade] { + margin-left: calc(-2 * var(--truncate-internal-fade-marker-width)); + } + } + + [data-truncate-variant='default'] { + & [data-truncate-marker] { + background-color: var(--truncate-internal-marker-background-color); + background-image: linear-gradient( + var(--truncate-internal-marker-background-overlay-color), + var(--truncate-internal-marker-background-overlay-color) + ); + } + & [data-truncate-marker]::after, + & [data-truncate-marker]::before { + content: ''; + position: absolute; + width: calc( + var(--truncate-internal-marker-fade-width) + + var(--truncate-internal-marker-gap) + ); + inset-block-start: var(--truncate-internal-marker-block-inset); + height: max( + 0px, + calc( + var(--truncate-internal-single-line-height) - + var(--truncate-internal-marker-block-inset) * 2 + ) + ); + background-color: var(--truncate-internal-marker-background-color); + background-image: linear-gradient( + var(--truncate-internal-marker-background-overlay-color), + var(--truncate-internal-marker-background-overlay-color) + ); + mask-image: linear-gradient( + var(--truncate-internal-fade-dir), + #000 0%, + #000 var(--truncate-internal-marker-gap), + transparent 100% + ); + } + & [data-truncate-marker]::after { + --truncate-internal-fade-dir: to right; + right: calc( + -1 * + ( + var(--truncate-internal-marker-fade-width) + + var(--truncate-internal-marker-gap) + ) + ); + } + & [data-truncate-marker]::before { + --truncate-internal-fade-dir: to left; + left: calc( + -1 * + ( + var(--truncate-internal-marker-fade-width) + + var(--truncate-internal-marker-gap) + ) + ); + } + } + + [data-truncate-variant='fade'] { + & [data-truncate-marker] { + background: transparent; + } + } + + [data-truncate-fade] { + box-shadow: + 0 0 calc(var(--truncate-internal-fade-marker-width) / 2) + var(--truncate-internal-fade-marker-color), + 0 0 var(--truncate-internal-fade-marker-width) + var(--truncate-internal-fade-marker-color); + width: calc(var(--truncate-internal-fade-marker-width) * 2); + height: calc( + var(--truncate-internal-single-line-height) - + (var(--truncate-internal-fade-marker-width) * 2) + ); + margin: var(--truncate-internal-fade-marker-width) 0; + } + + [data-truncate-group-container='middle'] { + & [data-truncate-container] { + --truncate-marker-opacity: var(--truncate-internal-middle-marker-opacity); + } + + display: flex; + min-width: 0; + + & > div { + min-width: 0; + } + + & > div[data-truncate-segment-priority='1'] { + flex: 0 1 max-content; + } + & > div[data-truncate-segment-priority='2'] { + flex: 0 999999 max-content; + } + } +} +`;const _$="@layer base, unsafe;";function R$(t){return`${_$} +@layer base { + ${t} +}`}function cw(t){return`${_$} +@layer unsafe { + ${t} +}`}const Z$=new WeakMap;function hw(t){const e=Z$.get(t);if(e!=null)return e;const i=document.createElement("div");i.setAttribute($x,"true");const n=document.createElement("div");n.style.position="relative",n.style.height="200%",i.appendChild(n),t.appendChild(i);const O=Math.max(i.offsetWidth-i.clientWidth,0);return i.remove(),Z$.set(t,O),O}function dw(t,e){if(!t.isConnected)return;const i=hw(e);if(i==null)return;const n=e.querySelector(`style[${wf}]`),O=n instanceof HTMLStyleElement?n:document.createElement("style");n instanceof HTMLStyleElement||(O.setAttribute(wf,""),e.appendChild(O)),O.textContent=`:host { ${Qx}: ${i}px; }`}let Oo;function uw(t){if(typeof CSSStyleSheet<"u"&&typeof CSSStyleSheet.prototype.replaceSync=="function"&&"adoptedStyleSheets"in t){Oo==null&&(Oo=new CSSStyleSheet,Oo.replaceSync(R$(k$)));let e=!1;try{t.adoptedStyleSheets=[Oo],e=!0}catch{}if(e){t.querySelector(`style[${wl}]`)?.remove();return}}if(t.querySelector(`style[${wl}]`)==null){const e=document.createElement("style");e.setAttribute(wl,""),e.textContent=R$(k$),t.prepend(e)}}function Nl(t,e){fw(t,e),uw(e),dw(t,e)}function fw(t,e){const i=t.querySelector('template[shadowrootmode="open"], template[data-file-tree-shadowrootmode="open"]');i instanceof HTMLTemplateElement&&(e.childNodes.length>0||(e.appendChild(i.content.cloneNode(!0)),i.hasAttribute("shadowrootmode")&&i.remove()))}if(typeof HTMLElement<"u"&&customElements.get(ar)==null){class t extends HTMLElement{constructor(){super()}connectedCallback(){const i=this.shadowRoot??this.attachShadow({mode:"open"});Nl(this,i)}}if(customElements.define(ar,t),typeof document<"u")for(const e of Array.from(document.querySelectorAll(ar)))e instanceof HTMLElement&&Nl(e,e.shadowRoot??e.attachShadow({mode:"open"}))}const $w=!0,Qw=t=>t.startsWith(vf)?t.slice(vf.length):t;function pw(t){const e=t.lastIndexOf("/");return e<0?{parentPath:"",baseName:t}:{parentPath:t.slice(0,e),baseName:t.slice(e+1)}}function mw(t,e){return t===""?e:`${t}/${e}`}function gw({files:t,path:e,isFolder:i,nextBasename:n}){const O=Qw(e),r=n.trim();if(r.length===0)return{error:"Name cannot be empty."};if(r.includes("/"))return{error:'Name cannot include "/".'};const{parentPath:s,baseName:o}=pw(O);if(r===o)return{nextFiles:t,sourcePath:O,destinationPath:O,isFolder:i};const a=mw(s,r),l=new Array(t.length),c=new Set;if(!i){const $=`${a}/`;let Q=!1;for(let p=0;pr.length!==s.length?r.length-s.length:r.localeCompare(s))){const r=(O.endsWith("/")?O.slice(0,-1):O).split("/");let s=!1;for(let o=0;on.has(O))}function bw(t,e){return e.includes(t)?Xw(e):[t]}function yw(t,e){return t===e?!0:t==null||e==null?!1:t.kind===e.kind&&t.directoryPath===e.directoryPath&&t.flattenedSegmentPath===e.flattenedSegmentPath&&t.hoveredPath===e.hoveredPath}function Y$(t,e){return{draggedPaths:t,target:e}}function z$(t,e){if(e.kind!=="directory"||e.directoryPath==null)return!1;for(const i of t)if(Pw(i)&&(e.directoryPath===i||e.directoryPath.startsWith(i)))return!0;return!1}function xw(t,e){return e.kind==="root"||e.directoryPath==null?Sw(t):e.directoryPath}function Tw(t,e){const i=t.map(n=>{const O=xw(n,e);return O===n?null:{from:n,to:O,type:"move"}}).filter(n=>n!=null);return i.length===0?null:{operations:i,result:{draggedPaths:t,operation:i.length===1?"move":"batch",target:e}}}function ww(t,e){if(t===e)return!0;if(t.length!==e.length)return!1;for(let i=0;ie.operation==="add"||e.operation==="remove"||e.operation==="move").map(e=>U$(e)),operation:"batch"}}function Rw(t){switch(t.operation){case"add":case"remove":case"move":return U$(t);case"batch":return _w(t);default:return null}}function Bl(t,e){if(t.size!==e.length)return!1;for(const i of e)if(!t.has(i))return!1;return!0}function ln(t){const e=t.endsWith("/")?t.slice(0,-1):t;if(e.length===0)return[];const i=e.split("/");return i.slice(0,-1).map((n,O)=>`${i.slice(0,O+1).join("/")}/`)}function Fl(t){return ln(t).at(-1)??null}function W$(t,e){return e==null?t:t.startsWith(e)?t.slice(e.length):t}function so(t){return t.endsWith("/")}const C$=t=>t.toLowerCase();function Zw(t){const e=t.endsWith("/")?t.slice(0,-1):t,i=e.lastIndexOf("/");return i<0?e:e.slice(i+1)}function j$(t){return t.endsWith("/")?t.slice(0,-1):t}function G$(t,e){return e&&!t.endsWith("/")?`${t}/`:t}const Yw=t=>{const e=t.trim();return e.length===0?"":(e.includes("\\")?e.replaceAll("\\","/"):e).toLowerCase()},E$=Symbol("FILE_TREE_RENAME_VIEW"),zw=512,Vw=512;function qw(t){return t==="top"||t==="center"?t:"nearest"}function Uw(t,e,i){if(t===0)return-1;if(i!=null){const n=e(i);if(n!=null)return n;const O=ln(i);for(let r=O.length-1;r>=0;r-=1){const s=O[r];if(s==null)continue;const o=e(s);if(o!=null)return o}}return 0}function Ww(t,e,i){if(t.paths.length===0)return{focusedIndex:-1,getParentIndex:t.getParentIndex,paths:t.paths,posInSetByIndex:t.posInSetByIndex,setSizeByIndex:t.setSizeByIndex};if(e==null)return{focusedIndex:0,getParentIndex:t.getParentIndex,paths:t.paths,posInSetByIndex:t.posInSetByIndex,setSizeByIndex:t.setSizeByIndex};const n=i??(O=>t.visibleIndexByPath.get(O)??null);return{focusedIndex:Uw(t.paths.length,n,e),getParentIndex:t.getParentIndex,paths:t.paths,posInSetByIndex:t.posInSetByIndex,setSizeByIndex:t.setSizeByIndex}}var Cw=class{#e;#i=new Set;#l=new Map;#c=null;#s=null;#C=new Map;#j=new Map;#Q=-1;#n=null;#p=!1;#v=t=>-1;#m=new Map;#f=null;#g=null;#P=null;#S=null;#d=null;#G;#E;#z;#O=[];#I=new Int32Array(0);#A=new Int32Array(0);#K=void 0;#R=!1;#o=null;#$="";#k=!1;#x=new Set;#M=[];#D;#L=null;#a=null;#V=null;#Z=null;#y=null;#q=null;#J=null;#xe=0;#X=null;#r=new Set;#N=0;#t;#ie=0;#ne=!1;#u=0;#B;constructor(t){const{dragAndDrop:e,fileTreeSearchMode:i,initialSearchQuery:n,initialSelectedPaths:O,renaming:r,onSearchChange:s,paths:o,preparedInput:a,...l}=t,c=V$({paths:o,preparedInput:a},"constructor",l.sort);this.#e=l,e!=null&&e!==!1&&(this.#c=e===!0?{}:e),this.#R=r!=null&&r!==!1,r!=null&&r!==!1&&r!==!0&&(this.#K=r.canRename,this.#E=r.onError,this.#G=r.onRename),this.#z=s,this.#D=i??"hide-non-matches",this.#t=this.#re(c.paths,c.preparedInput);const h=O?.map(u=>this.#Y(u)).filter(u=>u!=null)??[],d=h.at(-1)??null;h.length>0&&(this.#r=new Set(h),this.#X=d,this.#N=1),this.#W(d,!1),n!=null&&this.#F(n,!1),this.#B=this.#be()}destroy(){this.#B?.(),this.#B=null,this.#l.clear(),this.#i.clear(),this.#m.clear(),this.#s=null,this.#oe()}focusFirstItem(){this.#T().length>0&&this.#w(0)}focusLastItem(){this.#u<=0||(this.#_(),this.#w(this.#u-1))}focusNextItem(){this.#Xe(1)}focusParentItem(){if(this.#n==null)return;const t=Fl(this.#n);if(t==null)return;const e=this.#U(t);e>=0&&this.#w(e)}focusPath(t){const e=this.#t.getPathInfo(t)?.path??null;if(e==null)return;this.#_();const i=this.#U(e);i>=0&&this.#w(i)}scrollToPath(t,e){const i=this.#t.getPathInfo(t)?.path??null;if(i==null)return;this.#_();const n=this.#We(i);n<0||this.#ae(n)!=null&&(e?.focus!==!1&&this.#w(n,!1),this.#J={id:this.#xe+=1,offset:qw(e?.offset),visibleIndex:n},this.#h())}focusMountedPathFromInput(t){const e=this.#t.getPathInfo(t)?.path??null;if(e==null)return;const i=this.#U(e);i>=0&&this.#w(i)}focusNearestPath(t){const e=this.resolveNearestVisiblePath(t);if(e==null)return null;const i=this.#U(e);return i>=0?(this.#w(i),this.#T()[i]??e):null}focusPreviousItem(){this.#Xe(-1)}getFocusedIndex(){return this.#Q}getFocusedItem(){return this.#n==null?null:this.#le(this.#n)}getFocusedPath(){return this.#n}getScrollRequest(){return this.#J}clearScrollRequest(t){this.#J?.id===t&&(this.#J=null)}resolveNearestVisiblePath(t){const e=this.#T();if(this.#u===0)return null;if(t==null)return this.#n??e[0]??null;const i=this.#t.getPathInfo(t)?.path??t,n=this.#U(i);if(n>=0)return e[n]??i;const O=this.#ke(i);return O??this.#n??e[0]??null}getSelectedPaths(){return[...this.#r]}getSelectionVersion(){return this.#N}getVisibleCount(){return this.#u}getVisibleRows(t,e){if(e=this.#O.length&&O<=Vw){const r=[];for(let s=i;s<=n;s+=1){const o=this.#t.getVisibleRowContext(s);if(o==null)break;r.push(this.#ce(o))}return r}if(!this.#p&&n>=this.#O.length&&this.#_(),this.#y!=null){const r=Array.from({length:n-i+1},(l,c)=>this.#pe(i+c)),s=new Map;let o=r[0]??-1,a=o;for(let l=1;l<=r.length;l+=1){const c=r[l];if(c!=null&&c===a+1){a=c;continue}if(o>=0&&this.#t.getVisibleSlice(o,a).forEach((h,d)=>{s.set(o+d,h)}),c==null){o=-1,a=-1;continue}o=c,a=c}return Array.from({length:n-i+1},(l,c)=>{const h=i+c,d=this.#pe(h),u=s.get(d),$=this.#O[d];if(u==null||$==null)throw new Error(`Missing projection row for filtered visible index ${String(h)}`);return this.#Oe(u,h,d,{ancestorPaths:this.#ue(d),path:$})})}return this.#t.getVisibleSlice(i,n).map((r,s)=>{const o=i+s,a=this.#O[o];if(a==null)throw new Error(`Missing projection path for visible index ${String(o)}`);return this.#Oe(r,o,o,{ancestorPaths:this.#ue(o),path:a})})}getStickyRowCandidates(t,e){if(this.#y!=null)return null;if(this.#u===0||t<=0||e<=0)return[];const i=[];for(let n=0;n0?this.#he(r-1,n):void 0);if(s==null)break;i.push({row:this.#ce(s),subtreeEndIndex:s.subtreeEndIndex})}return i}getItem(t){const e=this.#t.getPathInfo(t);return e==null?null:this.#le(e.path,e)}resolveMountedDirectoryPathFromInput(t){const e=this.#t.getPathInfo(t);return e?.kind==="directory"?e.path:null}toggleMountedDirectoryFromInput(t){const e=this.resolveMountedDirectoryPathFromInput(t);e!=null&&this.#ye(e)}selectAllVisiblePaths(){this.#_();const t=[...this.#T()];this.#b(t,this.#n??this.#X)}selectOnlyPath(t){const e=this.#Y(t);e!=null&&this.#b([e],e)}selectOnlyMountedPathFromInput(t){this.#b([t],t)}selectPath(t){const e=this.#Y(t);e==null||this.#r.has(e)||this.#b([...this.#r,e])}deselectPath(t){const e=this.#Y(t);e==null||!this.#r.has(e)||this.#b([...this.#r].filter(i=>i!==e))}toggleFocusedSelection(){this.#n!=null&&this.togglePathSelectionFromInput(this.#n)}togglePathSelection(t){const e=this.#Y(t);if(e!=null){if(this.#r.has(e)){this.deselectPath(e);return}this.selectPath(e)}}togglePathSelectionFromInput(t){const e=this.#Y(t);if(e!=null){if(this.#r.has(e)){this.#b([...this.#r].filter(i=>i!==e),e);return}this.#b([...this.#r,e],e)}}selectPathRange(t,e){const i=this.#Y(t);if(i==null)return;this.#_();const n=this.#X,O=n==null?-1:this.#te(n),r=this.#te(i);if(O===-1||r===-1){const c=e?[...this.#r,i]:[i];this.#b(c,i);return}const[s,o]=O<=r?[O,r]:[r,O],a=this.#T().slice(s,o+1),l=e?[...this.#r,...a]:a;this.#b(l,n)}extendSelectionFromFocused(t){if(this.#n==null)return;const e=this.#Q;if(e===-1)return;const i=Math.min(this.#u-1,Math.max(0,e+t));if(i===e)return;!this.#p&&i>=this.#O.length&&this.#_();const n=this.#T(),O=n[e]??null,r=n[i]??null;if(O==null||r==null)return;const s=new Set(this.#r);s.has(O)&&s.has(r)?s.delete(O):s.add(r),this.#b([...s],this.#X??O,!1),this.#w(i)}getDragAndDropConfig(){return this.#c}isDragAndDropEnabled(){return this.#c!=null}getDragSession(){return this.#s==null?null:{draggedPaths:[...this.#s.draggedPaths],primaryPath:this.#s.primaryPath,target:this.#s.target==null?null:{...this.#s.target}}}startDrag(t){if(this.#c==null)return!1;const e=this.#Y(t);if(e==null||this.#a!=null&&this.#a.length>0)return!1;const i=this.getSelectedPaths(),n=bw(e,i);return this.#c.canDrag?.(n)===!1?!1:(i.includes(e)||this.#b([e],e,!1),this.#H(e),this.#s={draggedPaths:n,primaryPath:e,target:null},this.#h(),!0)}setDragTarget(t){const e=this.#s;if(e==null)return;let i=t;if(i!=null){const n=Y$(e.draggedPaths,i);(z$(e.draggedPaths,i)||this.#c?.canDrop?.(n)===!1)&&(i=null)}yw(e.target,i)||(this.#s={...e,target:i},this.#h())}cancelDrag(){this.#s!=null&&(this.#s=null,this.#h())}completeDrag(){const t=this.#s;if(t==null)return!1;this.#s=null;const e=t.target==null?null:{...t.target};if(e==null)return this.#h(),!1;const i=Y$(t.draggedPaths,e);if(z$(t.draggedPaths,e)||this.#c?.canDrop?.(i)===!1)return this.#h(),!1;const n=Tw(t.draggedPaths,e);if(n==null)return this.#h(),!1;try{if(n.operations.length===1){const O=n.operations[0];if(O==null||O.type!=="move")throw new Error("Expected a single move operation for one-item drops");this.#t.move(O.from,O.to,{collision:O.collision})}else this.#Ze(n.operations),this.#t.batch(n.operations)}catch(O){return this.#h(),this.#c?.onDropError?.(O instanceof Error?O.message:String(O),i),!1}return this.#c?.onDropComplete?.(n.result),!0}subscribe(t){return this.#i.add(t),t(),()=>{this.#i.delete(t)}}add(t){this.#t.add(t)}remove(t,e={}){this.#t.remove(t,e)}move(t,e,i={}){this.#t.move(t,e,i)}batch(t){this.#t.batch(t)}onMutation(t,e){const i=t,n=e;let O=this.#l.get(i);return O==null&&(O=new Set,this.#l.set(i,O)),O.add(n),()=>{const r=this.#l.get(i);r?.delete(n),r?.size===0&&this.#l.delete(i)}}setSearch(t){this.#F(t,!0)}openSearch(t=""){this.#F(t,!0)}closeSearch(){this.#F(null,!0)}isSearchOpen(){return this.#a!==null}getSearchValue(){return this.#a??""}getSearchMatchingPaths(){return this.#M}focusNextSearchMatch(){this.#me(1)}focusPreviousSearchMatch(){this.#me(-1)}startRenaming(t=this.#n??"",e={}){if(!this.#R)return!1;const i=this.#t.getPathInfo(t);if(i==null)return!1;const n=i.path,O=so(n),r=j$(n);if(this.#K?.({isFolder:O,path:r})===!1)return!1;for(const s of ln(n))this.#t.isExpanded(s)||this.#t.expand(s);return this.#b([n],n,!1),this.#a!=null&&(this.#F(null,!1),this.#z?.(this.#a)),this.#H(n),this.#o=n,this.#$=Zw(n),this.#k=e.removeIfCanceled??!1,this.#h(),!0}[E$](){return{cancel:()=>{this.#Te()},commit:()=>{this.#we()},getPath:()=>this.#o,getValue:()=>this.#$,isActive:()=>this.#o!=null,setValue:t=>{this.#ve(t)}}}#Te(){if(this.#o==null)return;const t=this.#o,e=this.#k;if(this.#o=null,this.#$="",this.#k=!1,e){this.remove(t,so(t)?{recursive:!0}:void 0);return}this.#H(t),this.#h()}#we(){const t=this.#o;if(t==null)return;if(this.#k&&this.#$.trim().length===0){this.#o=null,this.#$="",this.#k=!1,this.remove(t,so(t)?{recursive:!0}:void 0);return}const e=so(t),i=gw({files:this.#t.list(),isFolder:e,nextBasename:this.#$,path:j$(t)});if(this.#o=null,this.#$="",this.#k=!1,"error"in i){this.#H(t),this.#E?.(i.error),this.#h();return}if(i.sourcePath===i.destinationPath){this.#H(t),this.#h();return}this.#G?.({destinationPath:i.destinationPath,isFolder:i.isFolder,sourcePath:i.sourcePath}),this.move(G$(i.sourcePath,e),G$(i.destinationPath,e))}#ve(t){this.#o==null||this.#$===t||(this.#$=t,this.#h())}resetPaths(t,e={}){const i=this.#t.list().length,n=this.#u,O=V$({paths:t,preparedInput:e.preparedInput},"resetPaths",this.#e.sort),r=this.#re(O.paths,O.preparedInput,e.initialExpandedPaths),s=this.#n,o=this.#o,a=this.getSelectedPaths(),l=this.#X;this.#B?.(),this.#t=r,this.#m.clear(),this.#oe();const c=a.map(d=>r.getPathInfo(d)?.path??null).filter(d=>d!=null),h=!Bl(this.#r,c);this.#r=new Set(c),h&&(this.#N+=1),this.#X=l==null?null:r.getPathInfo(l)?.path??null,this.#o=o==null?null:r.getPathInfo(o)?.path??null,this.#o==null&&(this.#$="",this.#k=!1),this.#W(s,s!=null||c.length>0||this.#X!=null),this.#B=this.#be(),this.#h(),this.#Pe({canonicalChanged:!0,operation:"reset",pathCountAfter:O.paths.length,pathCountBefore:i,projectionChanged:!0,usedPreparedInput:e.preparedInput!=null,visibleCountDelta:this.#u-n})}#ke(t){this.#_();const e=Fl(t),i=W$(t,e);let n=null,O=null;for(const r of this.#T()){if(Fl(r)!==e)continue;const s=W$(r,e);if(si){O=r;break}}return n??O}#U(t){const e=this.#te(t);if(e!==-1)return e;const i=ln(t);for(let n=i.length-1;n>=0;n-=1){const O=i[n];if(O==null)continue;const r=this.#te(O);if(r!==-1)return r}return this.#T().length>0?0:-1}#le(t,e){const i=this.#m.get(t);if(i!=null)return i;const n=e??this.#t.getPathInfo(t);if(n==null)return null;const O=n.kind==="directory"?this.#_e(n.path):this.#Re(n.path);return this.#m.set(n.path,O),O}#Oe(t,e,i,n){return{ancestorPaths:n.ancestorPaths,depth:t.depth,flattenedSegments:t.flattenedSegments?.map(O=>({isTerminal:O.isTerminal,name:O.name,path:O.path})),hasChildren:t.hasChildren,index:e,isExpanded:t.isExpanded,isFlattened:t.isFlattened,isFocused:n.path===this.#n,isSelected:this.#r.has(n.path),kind:t.kind,level:t.depth,name:t.name,path:n.path,posInSet:n.posInSet??this.#I[i]??0,setSize:n.setSize??this.#A[i]??0}}#ce(t){return this.#Oe(t.row,t.index,t.index,{ancestorPaths:t.ancestorPaths,path:t.row.path,posInSet:t.posInSet,setSize:t.setSize})}#he(t,e){const i=this.#t.getVisibleRowContext(t);if(i==null)return;const n=i.ancestorRows[e];return n??(e===i.ancestorRows.length&&i.row.kind==="directory"&&i.row.isExpanded?i:void 0)}#de(t){const e=this.#C.get(t);if(e!=null)return e;const i=this.#v(t),n=i<0?[]:[...this.#de(i),i];return this.#C.set(t,n),n}#ue(t){const e=this.#j.get(t);if(e!=null)return e;const i=this.#de(t).map(n=>this.#O[n]??"").filter(n=>n!=="");return this.#j.set(t,i),i}#fe(t){this.#t.collapse(t)}#b(t,e=this.#X,i=!0){const n=[...new Set(t)],O=!Bl(this.#r,n),r=this.#X!==e;!O&&!r||(this.#r=new Set(n),this.#X=e,O&&(this.#N+=1),i&&this.#h())}#_e(t){return{collapse:()=>{this.#fe(t)},deselect:()=>{this.deselectPath(t)},expand:()=>{this.#Se(t)},focus:()=>{this.focusPath(t)},getPath:()=>t,isDirectory:()=>!0,isExpanded:()=>this.#t.isExpanded(t),isFocused:()=>this.#n===t,isSelected:()=>this.#r.has(t),select:()=>{this.selectPath(t)},toggleSelect:()=>{this.togglePathSelection(t)},toggle:()=>{this.#ye(t)}}}#Re(t){return{deselect:()=>{this.deselectPath(t)},focus:()=>{this.focusPath(t)},getPath:()=>t,isDirectory:()=>!1,isFocused:()=>this.#n===t,isSelected:()=>this.#r.has(t),select:()=>{this.selectPath(t)},toggleSelect:()=>{this.togglePathSelection(t)}}}#Ze(t){const e=this.#t.list();this.#re(e).batch(t)}#re(t,e,i){return new T$({...this.#e,paths:t,preparedInput:e??void 0,...i!==void 0?{initialExpandedPaths:i}:{}})}#se(){return this.#S!=null?this.#S:(this.#S=this.#t.list(),this.#S)}#Ye(){if(this.#P!=null)return this.#P;const t=new Set;for(const e of this.#se()){t.add(e);for(const i of ln(e))t.add(i)}return this.#P=[...t].sort(),this.#P}#ze(){return this.#d!=null?this.#d:(this.#d=this.#se().map(C$),this.#d)}#ee(){return this.#f!=null?this.#f:(this.#f=this.#Ye().filter(t=>t.endsWith("/")),this.#f)}#Ve(){return this.#g!=null?this.#g:(this.#g=this.#ee().map(C$),this.#g)}#oe(){this.#f=null,this.#g=null,this.#P=null,this.#S=null,this.#d=null}#qe(){return this.#ee().filter(t=>this.#t.isExpanded(t))}#$e(t){const e=new Set(this.#L??[]);if(t)for(const i of this.#r)for(const n of ln(i))e.add(n);this.#Qe(e)}#Qe(t){this.#ne=!0;try{for(const e of this.#ee()){const i=t.has(e),n=this.#t.isExpanded(e);i&&!n?this.#t.expand(e):!i&&n&&this.#t.collapse(e)}}finally{this.#ne=!1}}#Ue(){if(this.#a==null||this.#a.length===0){this.#M=[],this.#y=null,this.#q=null,this.#Z=null,this.#u=this.#ie;return}const t=this.#O;if(this.#M=t.filter(O=>this.#x.has(O)),this.#D!=="hide-non-matches"||this.#x.size===0){this.#y=null,this.#q=null,this.#Z=null,this.#u=this.#ie;return}const e=[],i=[],n=new Map;for(const[O,r]of t.entries())this.#V?.has(r)===!0&&(n.set(r,i.length),e.push(O),i.push(r));this.#y=e,this.#q=i,this.#Z=n,this.#u=i.length}#T(){return this.#q??this.#O}#We(t){return this.#q!=null?this.#Z?.get(t)??-1:this.#t.getVisibleIndex(t)??-1}#pe(t){return this.#y?.[t]??t}#te(t){const e=this.#Z?.get(t);return e??this.#t.getVisibleIndex(t)??-1}#me(t){const e=this.#M;if(e.length===0)return;const i=this.#n,n=i==null?-1:e.indexOf(i),O=e[n<0?t>0?0:e.length-1:Math.min(e.length-1,Math.max(0,n+t))];O!=null&&this.focusPath(O)}#F(t,e){const i=t==null?null:Yw(t),n=this.#a;if(n!==i){if(n==null&&i!=null&&(this.#L=this.#qe()),this.#a=i,i==null)this.#$e(!0),this.#L=null,this.#x.clear(),this.#V=null,this.#W(this.#n,!0);else if(i.length===0)this.#$e(!1),this.#x.clear(),this.#V=null,this.#W(this.#n,!0);else{const O=this.#ge();this.#W(O,!0)}e&&(this.#z?.(this.#a),this.#h())}}#ge(){if(this.#a==null||this.#a.length===0)return this.#x.clear(),this.#n;const t=this.#a,e=this.#se(),i=this.#ze(),n=[],O=new Set;let r=null;for(let c=0;c0?new Set:null;this.#V=a;const l=this.#D==="expand-matches"?new Set(this.#L??[]):new Set;for(const c of n){a?.add(c),c.endsWith("/")&&l.add(c);for(const h of ln(c))l.add(h),a?.add(h)}return this.#Qe(l),r??this.#n}#h(){for(const t of this.#i)t()}#Pe(t){this.#l.get(t.operation)?.forEach(e=>{e(t)}),this.#l.get("*")?.forEach(e=>{e(t)})}#Se(t){for(const e of ln(t))this.#t.isExpanded(e)||this.#t.expand(e);this.#t.isExpanded(t)||this.#t.expand(t)}#Xe(t){const e=this.#u;if(e===0)return;const i=this.#Q===-1?0:this.#Q,n=Math.min(e-1,Math.max(0,i+t));(n!==i||this.#Q===-1)&&(!this.#p&&this.#y==null&&n>=this.#O.length&&this.#_(),this.#w(n))}#W(t,e=!0){const i=this.#t.getVisibleCount();this.#ie=i;const n=Ww(this.#t.getVisibleTreeProjectionData(e?void 0:Math.min(i,zw)),t,e?O=>this.#t.getVisibleIndex(O):void 0);this.#C.clear(),this.#j.clear(),this.#p=n.paths.length>=i,this.#v=n.getParentIndex,this.#O=n.paths,this.#I=n.posInSetByIndex,this.#A=n.setSizeByIndex,this.#Ue(),this.#Q=t==null?this.#T().length>0?0:-1:this.#U(t),this.#n=this.#Q<0?null:this.#ae(this.#Q)}#ae(t){const e=this.#T()[t];return e??(this.#y!=null?null:this.#t.getVisibleRowContext(t)?.row.path??null)}#Y(t){return this.#t.getPathInfo(t)?.path??null}#H(t){if(t==null)return;const e=this.#U(t);e>=0&&this.#w(e,!1)}#w(t,e=!0){const i=this.#ae(t);i!=null&&(this.#Q===t&&this.#n===i||(this.#Q=t,this.#n=i,e&&this.#h()))}#_(){this.#p||this.#W(this.#n,!0)}#Ce(t){const e=gr(this.#o,t);e==null&&this.#o!=null&&(this.#$=""),this.#o=e;const i=gr(this.#n,t,!0),n=[...this.#r].map(o=>gr(o,t)).filter(o=>o!=null).map(o=>this.#t.getPathInfo(o)?.path??null).filter(o=>o!=null),O=gr(this.#X,t),r=O==null?null:this.#t.getPathInfo(O)?.path??null,s=[...new Set(n)];return Bl(this.#r,s)||(this.#r=new Set(s),this.#N+=1),this.#X=r,i}#be(){return this.#t.on("*",t=>{if(this.#ne)return;t.canonicalChanged&&(this.#m.clear(),this.#oe()),this.#s!=null&&q$(t)&&(this.#s=null);const e=q$(t)?this.#Ce(t):this.#n,i=this.#a!=null&&this.#a.length>0?this.#ge():this.#a===""?this.#n:e,n=this.#a!=null||t.operation!=="expand"&&t.operation!=="collapse";this.#W(i,n),this.#h();const O=Rw(t);O!=null&&this.#Pe(O)})}#ye(t){if(this.#t.isExpanded(t)){this.#fe(t);return}this.#Se(t)}};const jw=t=>{if(t==null||t.length===0)return"0";let e=`${t.length}`;for(const i of t)e+=`\0${i.path}\0${i.status}`;return e};function Gw(t){const e=t.endsWith("/");let i="",n=-1;for(let O=0;O<=t.length;O+=1){if(!(t[O]==="/"||O===t.length)){n===-1&&(n=O);continue}n!==-1&&(i!==""&&(i+="/"),i+=t.slice(n,O),n=-1)}return i===""?null:{isDirectory:e,path:i}}function Ew(t){const e=t.endsWith("/")?t.slice(0,-1):t;if(e.length===0)return[];const i=e.split("/");return i.slice(0,-1).map((n,O)=>`${i.slice(0,O+1).join("/")}/`)}function Iw(t,e){return e?`${t}/`:t}function I$(t,e=null){const i=jw(t==null?void 0:[...t]);if(i==="0")return null;if(e?.signature===i)return e;const n=new Map,O=new Set,r=new Set;for(const s of t??[]){const o=Gw(s.path);if(o==null)continue;const a=Iw(o.path,o.isDirectory);n.set(a,s.status),s.status==="ignored"&&o.isDirectory?r.add(a):o.isDirectory&&r.delete(a);for(const l of Ew(o.path))O.add(l)}return{directoriesWithChanges:O,ignoredDirectoryPaths:r,signature:i,statusByPath:n}}var me,A$,zn,M$,oo,D$,L$,Hl,Kl,Jl,Pr={},N$=[],ao=Array.isArray,ec=N$.slice,cn=Object.assign;function tc(t){t&&t.parentNode&&t.remove()}function ic(t,e,i){var n,O,r,s={};for(r in e)r=="key"?n=e[r]:r=="ref"&&typeof t!="function"?O=e[r]:s[r]=e[r];return arguments.length>2&&(s.children=arguments.length>3?ec.call(arguments,2):i),lo(t,s,n,O,null)}function lo(t,e,i,n,O){var r={type:t,props:e,key:i,ref:n,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:O??++A$,__i:-1,__u:0};return O==null&&me.vnode!=null&&me.vnode(r),r}function hO(t){return t.children}function co(t,e){this.props=t,this.context=e,this.__g=0}function dO(t,e){if(e==null)return t.__?dO(t.__,t.__i+1):null;for(var i;ea&&zn.sort(D$),t=zn.shift(),a=zn.length,8&t.__g&&(i=void 0,O=(n=(e=t).__v).__e,r=[],s=[],(o=e.__P)&&((i=cn({},n)).__v=n.__v+1,me.vnode&&me.vnode(i),nc(o,i,n,e.__n,o.namespaceURI,32&n.__u?[O]:null,r,O??dO(n),!!(32&n.__u),s,o.ownerDocument),i.__v=n.__v,i.__.__k[i.__i]=i,tQ(r,i,s),i.__e!=O&&B$(i)));oo=0}function H$(t,e,i,n,O,r,s,o,a,l,c,h){var d,u,$,Q,p,m,P,g=n&&n.__k||N$,b=e.length;for(a=Mw(i,e,g,a,b),d=0;d0?lo(s.type,s.props,s.key,s.ref?s.ref:null,s.__v):s).__=t,s.__b=t.__b+1,o=null,(l=s.__i=Dw(s,i,a,h))!=-1&&(h--,(o=i[l])&&(o.__u|=2)),o==null||o.__v==null?(l==-1&&(O>c?d--:Oa?d--:d++,s.__u|=4))):t.__k[r]=null;if(h)for(r=0;r(c?1:0)){for(O=i-1,r=i+1;O>=0||r=0?O--:r++])!=null&&!(2&l.__u)&&o==l.key&&a==l.type)return s}return-1}function J$(t,e,i){e[0]=="-"?t.setProperty(e,i??""):t[e]=i??""}function ho(t,e,i,n,O){var r;e:if(e=="style")if(typeof i=="string")t.style.cssText=i;else{if(typeof n=="string"&&(t.style.cssText=n=""),n)for(e in n)i&&e in i||J$(t.style,e,"");if(i)for(e in i)n&&i[e]==n[e]||J$(t.style,e,i[e])}else if(e[0]=="o"&&e[1]=="n")r=e!=(e=e.replace(L$,"$1")),(e=e.slice(2))[0].toLowerCase()!=e[0]&&(e=e.toLowerCase()),t.__l||(t.__l={}),t.__l[e+r]=i,i?n?i.l=n.l:(i.l=Hl,t.addEventListener(e,r?Jl:Kl,r)):t.removeEventListener(e,r?Jl:Kl,r);else{if(O=="http://www.w3.org/2000/svg")e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!="width"&&e!="height"&&e!="href"&&e!="list"&&e!="form"&&e!="tabIndex"&&e!="download"&&e!="rowSpan"&&e!="colSpan"&&e!="role"&&e!="popover"&&e in t)try{t[e]=i??"";break e}catch{}typeof i=="function"||(i==null||i===!1&&e[4]!="-"?t.removeAttribute(e):t.setAttribute(e,e=="popover"&&i==1?"":i))}}function eQ(t){return function(e){if(this.__l){var i=this.__l[e.type+t];if(e.u==null)e.u=Hl++;else if(e.u0&&e.__c.__z.push(L),j++,r[B]=null):L.nodeType==8&&L.data=="/$s"?(--j>0&&e.__c.__z.push(L),V=j===0,o=r[B],r[B]=null):j>0&&(e.__c.__z.push(L),r[B]=null));if(!V){for(;o&&o.nodeType==8&&o.nextSibling;)o=o.nextSibling;r[r.indexOf(o)]=null,e.__c.__z=[o]}e.__e=o}else{for(Oe=r.length;Oe--;)tc(r[Oe]);Oc(e)}else e.__e=i.__e,e.__k=i.__k,he.then||Oc(e);me.__e(he,e,i)}else o=e.__e=Lw(i.__e,e,i,n,O,r,s,a,l,c);return(h=me.diffed)&&h(e),128&e.__u?void 0:o}function Oc(t){t&&t.__c&&(t.__c.__g|=4),t&&t.__k&&t.__k.forEach(Oc)}function tQ(t,e,i){for(var n=0;n0?t:ao(t)?t.map(iQ):cn({},t)}function Lw(t,e,i,n,O,r,s,o,a,l){var c,h,d,u,$,Q,p,m,P=i.props,g=e.props,b=e.type;if(b=="svg"?O="http://www.w3.org/2000/svg":b=="math"?O="http://www.w3.org/1998/Math/MathML":O||(O="http://www.w3.org/1999/xhtml"),r!=null){for(c=0;c{if(t.length<2)return[t,""];const e=Math.ceil(t.length/2);return[t.slice(0,e),t.slice(e)]},ev=t=>{if(t.length<4)return[t,""];const e=t.lastIndexOf(".")+1,i=t.length-e>10,n=e>=1&&!i?e:Math.ceil(t.length/2);return[t.slice(0,n),t.slice(n)]},tv=t=>{if(t.length<4)return[t,""];const e=t.lastIndexOf("/")+1,i=t.length-e>25,n=e>=1&&!i?e:Math.ceil(t.length/2);return[t.slice(0,n),t.slice(n)]},iv=(t,{splitIndex:e}={})=>{if(typeof e!="number"){const i=Math.ceil(t.length/2);return[t.slice(0,i),t.slice(i)]}return[t.slice(0,e),t.slice(e)]},nv=(t,{splitOffset:e}={})=>{if(typeof e!="number"||e<=0||e>=t.length){const n=Math.ceil(t.length/2);return[t.slice(0,n),t.slice(n)]}const i=t.length-e;return[t.slice(0,i),t.slice(i)]},Ov=(t,{splitOffset:e}={})=>{if(typeof e!="number"||e<=0||e>=t.length){const n=Math.ceil(t.length/2);return[t.slice(0,n),t.slice(n)]}const i=e;return[t.slice(0,i),t.slice(i)]};function rv({children:t,marker:e,variant:i="default"}){"use no memo";return U("div",{"aria-hidden":!0,"data-truncate-marker-cell":!0,children:U("div",{"data-truncate-marker":!0,children:typeof e=="function"?e({children:t}):i==="fade"?U("span",{"data-truncate-fade":!0}):e})})}function sv(t){"use no memo";const{mode:e,children:i}=t;return U("div",{children:[U("div",{"data-truncate-content":"visible",children:e==="fruncate"?U("span",{children:i}):i}),U("div",{"data-truncate-content":"overflow","aria-hidden":!0,children:e==="fruncate"?U("span",{children:i}):i})]})}function rQ({children:t,mode:e="truncate",marker:i="…",variant:n="default",...O}){"use no memo";const r=U(sv,{mode:e,children:t},"content"),s=U(rv,{marker:i,mode:e,variant:n},"marker");return U("div",{"data-truncate-container":e,"data-truncate-variant":n,...O,children:U("div",{"data-truncate-grid":!0,children:e==="truncate"?[r,s]:[s,r,U("div",{"data-truncate-fill":!0},"fill")]})})}function uo({children:t,...e}){"use no memo";return U(rQ,{mode:"truncate",...e,children:t})}function oc({children:t,...e}){"use no memo";return U(rQ,{mode:"fruncate",...e,children:t})}function ov({children:t,contents:e,priority:i="end",split:n="center",minimumLength:O=12,className:r,style:s,...o}){"use no memo";let a=null,l=null;if(Array.isArray(e)){if(e.length!==2)return console.error("MiddleTruncate: contents must be an array of two items"),null;a=U(uo,{...o,children:e[0]}),l=U(oc,{...o,children:e[1]})}else{if(typeof t!="string")return console.error("MiddleTruncate: children must be a string"),null;if(t.length===0)return U("div",{className:r,style:s});if(t.length=$.length,p=i==="equal"&&!Q,m=i==="equal"&&Q,P={},g={};p&&(P.marker=""),m&&(g.marker=""),a=U(uo,{...o,...P,children:u}),l=U(oc,{...o,...g,children:$})}return U("div",{"data-truncate-group-container":"middle",className:r,style:s,children:[U("div",{"data-truncate-segment-priority":i==="start"||i==="equal"?"1":"2",children:a}),U("div",{"data-truncate-segment-priority":i==="end"||i==="equal"?"1":"2",children:l})]})}const ac={endIndex:-1,startIndex:-1};function av(t,e,i){return Math.min(Math.max(t,e),i)}function sQ(t,e){return t<0||e=n?e:Math.floor(t/i)}function cv(t,e,i){return e<=0||t<=0?-1:t>=e*i?e-1:Math.ceil(t/i)-1}function hv(t){const e=new Map;return t.forEach((i,n)=>{if(i.kind!=="directory"||!i.isExpanded)return;const O=i.ancestorPaths.length,r=e.get(O);if(r==null){e.set(O,[n]);return}r.push(n)}),e}function dv(t,e){let i=0,n=t.length-1,O=-1;for(;i<=n;){const r=Math.floor((i+n)/2),s=t[r];if(s==null)break;if(s<=e){O=r,i=r+1;continue}n=r-1}return O}function uv(t){const e=new Map,i=[];for(let O=0;O=o;a-=1){const l=i[a];l!=null&&e.set(l,O-1)}i.length=o;for(let a=o;a=0;){const h=o[l],d=h==null?null:t[h]??null;if(d!=null&&(s===0||d.ancestorPaths[s-1]===r[s-1]?.path)){c=d;break}l-=1}if(c==null)break;r.push(c)}return r.map((s,o)=>{const a=o*i,l=(n.get(s.path)??t.length-1)+1;if(l>=t.length)return{row:s,top:a};const c=l*i-e;return{row:s,top:Math.min(a,c-i)}}).filter(s=>s.top+i>0)}function fv(t,e){const i=e.totalRowCount??t.length,n=i*e.itemHeight,O=Math.max(0,e.viewportHeight),r=Math.max(0,Math.floor(e.overscan)),s=Math.max(0,n-O),o=av(e.scrollTop,0,s),a=e.stickyRows??aQ(t,o,e.itemHeight),l=a.reduce((y,T)=>Math.max(y,T.top+e.itemHeight),0),c=Math.min(n,o+l),h=Math.max(0,O-l),d=Math.max(0,n-c),u=oQ(o,i,e.itemHeight),$=oQ(c,i,e.itemHeight),Q=l<=0||u<0||u>=i?-1:u,p=Q===-1?-1:Math.min(i-1,$-1),m=Q===-1||p=i?ac:sQ($,cv(c+h,i,e.itemHeight)),g=p+1,b=lc(P)?ac:sQ(Math.max(g,P.startIndex-r),Math.min(i-1,P.endIndex+r)),X=lv(b,e.itemHeight);return{occlusion:{firstOccludedIndex:Q,lastOccludedIndex:p,occludedCount:m},physical:{itemHeight:e.itemHeight,maxScrollTop:s,overscan:r,scrollTop:o,totalHeight:n,totalRowCount:i,viewportHeight:O},projected:{contentHeight:d,paneHeight:h,paneTop:c},sticky:{height:l,rows:a},visible:P,window:{endIndex:b.endIndex,height:X,offsetTop:lc(b)?0:b.startIndex*e.itemHeight,startIndex:b.startIndex}}}const $v={added:"A",deleted:"D",ignored:null,modified:"M",renamed:"R",untracked:"U"},Qv={added:"Git status: added",deleted:"Git status: deleted",ignored:"Git status: ignored",modified:"Git status: modified",renamed:"Git status: renamed",untracked:"Git status: untracked"},pv="Contains git status items";function lQ(t){const{currentScrollTop:e,focusedIndex:i,itemHeight:n,topInset:O=0,viewportHeight:r}=t;if(i<0)return null;const s=Math.max(0,O),o=i*n,a=o+n;if(oe+r){const l=a-r;return l===e?null:l}return null}function mv(t){const{currentScrollTop:e,focusedIndex:i,itemHeight:n,offset:O,topInset:r=0,totalHeight:s,viewportHeight:o}=t;if(O==="nearest")return lQ({currentScrollTop:e,focusedIndex:i,itemHeight:n,topInset:r,viewportHeight:o});if(i<0)return null;const a=Math.max(0,r),l=i*n,c=Math.max(0,o-a),h=O==="center"?a+Math.max(0,(c-n)/2):a,d=Math.max(0,s-o),u=Math.max(0,Math.min(l-h,d));return u===e?null:u}function gv(t){const{currentScrollTop:e,focusedIndex:i,itemHeight:n,targetViewportOffset:O,totalHeight:r,viewportHeight:s}=t;if(i<0)return null;const o=Math.max(0,O),a=i*n,l=a+n,c=e+o,h=e+s;if(a>=c&&l<=h)return null;const d=Math.max(0,r-s),u=Math.max(0,Math.min(a-o,d));return u===e?null:u}function uO(t){if(t==null||!t.isConnected||t===document.body||t===document.documentElement)return!1;t.focus({preventScroll:!0});const e=t.getRootNode();return e instanceof ShadowRoot?e.activeElement===t:document.activeElement===t}function fo(t){const e=t.getRootNode();if(e instanceof ShadowRoot){const n=e.activeElement;return n instanceof HTMLElement?n:null}const i=document.activeElement;return i instanceof HTMLElement&&t.contains(i)?i:null}function Xr(t,e){if(t==null)return e;const i=t.getBoundingClientRect().height;return i>0?i:t.clientHeight>0?t.clientHeight:e}function cQ(t,e){return t!=null&&t>0?t:e}function Pv(t){const e=t.borderBoxSize,i=Array.isArray(e)?e[0]:e;return i!=null&&Number.isFinite(i.blockSize)&&i.blockSize>0?i.blockSize:t.contentRect.height>0?t.contentRect.height:null}function hQ(t,e,i,n,O=0){const r=lQ({currentScrollTop:t.scrollTop,focusedIndex:e,itemHeight:i,topInset:O,viewportHeight:n});return r==null?!1:(t.scrollTop=r,!0)}function Sv(t,e,i,n,O,r,s=0){const o=mv({currentScrollTop:t.scrollTop,focusedIndex:e,itemHeight:i,offset:r,topInset:s,totalHeight:O,viewportHeight:n});return o==null?!1:(t.scrollTop=o,!0)}function br(t,e,i,n,O,r){const s=gv({currentScrollTop:t.scrollTop,focusedIndex:e,itemHeight:i,targetViewportOffset:r,totalHeight:O,viewportHeight:n});return s==null?!1:(t.scrollTop=s,!0)}function dQ(t,e,i,n){return i.endi.end?n:null}function Xv(t){const{renamingPath:e,previousRenamingPath:i,hasRenderedInput:n}=t;return e==null?"reset":n?i===e?"ignore":"focus-input":"reveal-canonical"}function bv({ariaLabel:t,isFlattened:e=!1,ref:i,value:n,onBlur:O,onInput:r}){return U("input",{ref:i,"data-item-rename-input":!0,...e?{"data-item-flattened-rename-input":!0}:{},"aria-label":t,value:n,onBlur:O,onInput:r,onClick:s=>s.stopPropagation(),onMouseDown:s=>s.stopPropagation(),onPointerDown:s=>s.stopPropagation()})}function yv(t){const{row:e,mode:i,targetPath:n,ariaLabel:O,domId:r,isParked:s,itemHeight:o,features:a,state:l,extraStyle:c}=t,h=i==="sticky",d=e.ancestorPaths.at(-1)??"",u={};return l.isFocusRinged&&(u["data-item-focused"]=!0),e.isSelected&&(u["data-item-selected"]=!0),l.isContextHovered&&(u["data-item-context-hover"]="true"),l.isDragTarget&&(u["data-item-drag-target"]=!0),l.isDragging&&(u["data-item-dragging"]=!0),l.effectiveGitStatus!=null&&(u["data-item-git-status"]=l.effectiveGitStatus),l.containsGitChange&&(u["data-item-contains-git-change"]="true"),{"aria-expanded":!h&&e.kind==="directory"?e.isExpanded:void 0,"aria-haspopup":a.contextMenuEnabled?"menu":void 0,"aria-label":O,"aria-level":h?void 0:e.level+1,"aria-posinset":h?void 0:e.posInSet+1,"aria-selected":h?void 0:e.isSelected?"true":"false","aria-setsize":h?void 0:e.setSize,"data-file-tree-sticky-path":h?n:void 0,"data-file-tree-sticky-row":h?"true":void 0,"data-item-context-menu-button-visibility":a.actionLaneEnabled?a.contextMenuButtonVisibility:void 0,"data-item-context-menu-trigger-mode":a.contextMenuEnabled?a.contextMenuTriggerMode:void 0,"data-item-has-context-menu-action-lane":a.actionLaneEnabled?"true":void 0,"data-item-has-git-lane":a.gitLaneActive?"true":void 0,"data-item-parent-path":d.length>0?d:void 0,"data-item-parked":s?"true":void 0,"data-item-path":n,"data-item-type":e.kind==="directory"?"folder":"file","data-type":"item",id:h?void 0:r,role:h?void 0:"treeitem",style:{minHeight:`${o}px`,...c},tabIndex:!h&&e.isFocused?0:-1,...u}}function xv(t){const{event:e,mode:i,isSearchOpen:n,isDirectory:O}=t,r=e.ctrlKey||e.metaKey,s=e.shiftKey||r,o=e.shiftKey?{additive:r,kind:"range"}:r?{kind:"toggle"}:{kind:"single"};return{closeSearch:n,revealCanonical:i==="sticky",selection:o,toggleDirectory:!s&&O}}var fO,Re,cc,uQ,hc=Object.is,yr=0,fQ=[],qe=me,$Q=qe.__b,QQ=qe.__r,pQ=qe.diffed,mQ=qe.__c,gQ=qe.unmount,PQ=qe.__;function $o(t,e){qe.__h&&qe.__h(Re,t,yr||e),yr=0;var i=Re.__H||(Re.__H={__:[],__h:[]});return t>=i.__.length&&i.__.push({}),i.__[t]}function Qi(t){return yr=1,Tv(bQ,t)}function Tv(t,e,i){var n=$o(fO++,2);if(n.t=t,!n.__c&&(n.__=[bQ(void 0,e),function(o){var a=n.__N?n.__N[0]:n.__[0],l=n.t(a,o);hc(a,l)||(n.__N=[l,n.__[1]],n.__c.setState({}))}],n.__c=Re,!Re.__f)){var O=function(o,a,l){if(!n.__c.__H)return!0;var c=n.__c.__H.__.filter(function(d){return!!d.__c});if(c.every(function(d){return!d.__N}))return!r||r.call(this,o,a,l);var h=n.__c.props!==o;return c.forEach(function(d){if(d.__N){var u=d.__[0];d.__=d.__N,d.__N=void 0,hc(u,d.__[0])||(h=!0)}}),r&&r.call(this,o,a,l)||h};Re.__f=!0;var r=Re.shouldComponentUpdate,s=Re.componentWillUpdate;Re.componentWillUpdate=function(o,a,l){if(4&this.__g){var c=r;r=void 0,O(o,a,l),r=c}s&&s.call(this,o,a,l)},Re.shouldComponentUpdate=O}return n.__N||n.__}function SQ(t,e){var i=$o(fO++,3);!qe.__s&&uc(i.__H,e)&&(i.__=t,i.u=e,Re.__H.__h.push(i))}function qt(t,e){var i=$o(fO++,4);!qe.__s&&uc(i.__H,e)&&(i.__=t,i.u=e,Re.__h.push(i))}function ee(t){return yr=5,hn(function(){return{current:t}},[])}function hn(t,e){var i=$o(fO++,7);return uc(i.__H,e)&&(i.__=t(),i.__H=e,i.__h=t),i.__}function ft(t,e){return yr=8,hn(function(){return t},e)}function wv(){for(var t;t=fQ.shift();)if(t.__P&&t.__H)try{t.__H.__h.forEach(Qo),t.__H.__h.forEach(dc),t.__H.__h=[]}catch(e){t.__H.__h=[],qe.__e(e,t.__v)}}qe.__b=function(t){Re=null,$Q&&$Q(t)},qe.__=function(t,e){t&&e.__k&&e.__k.__m&&(t.__m=e.__k.__m),PQ&&PQ(t,e)},qe.__r=function(t){QQ&&QQ(t),fO=0;var e=(Re=t.__c).__H;e&&(cc===Re?(e.__h=[],Re.__h=[],e.__.forEach(function(i){i.__N&&(i.__=i.__N),i.u=i.__N=void 0})):(e.__h.forEach(Qo),e.__h.forEach(dc),e.__h=[],fO=0)),cc=Re},qe.diffed=function(t){pQ&&pQ(t);var e=t.__c;e&&e.__H&&(e.__H.__h.length&&(fQ.push(e)!==1&&uQ===qe.requestAnimationFrame||((uQ=qe.requestAnimationFrame)||vv)(wv)),e.__H.__.forEach(function(i){i.u&&(i.__H=i.u),i.u=void 0})),cc=Re=null},qe.__c=function(t,e){e.some(function(i){try{i.__h.forEach(Qo),i.__h=i.__h.filter(function(n){return!n.__||dc(n)})}catch(n){e.some(function(O){O.__h&&(O.__h=[])}),e=[],qe.__e(n,i.__v)}}),mQ&&mQ(t,e)},qe.unmount=function(t){gQ&&gQ(t);var e,i=t.__c;i&&i.__H&&(i.__H.__.forEach(function(n){try{Qo(n)}catch(O){e=O}}),i.__H=void 0,e&&qe.__e(e,i.__v))};var XQ=typeof requestAnimationFrame=="function";function vv(t){var e,i=function(){clearTimeout(n),XQ&&cancelAnimationFrame(e),setTimeout(t)},n=setTimeout(i,35);XQ&&(e=requestAnimationFrame(i))}function Qo(t){var e=Re,i=t.__c;typeof i=="function"&&(t.__c=void 0,i()),Re=e}function dc(t){var e=Re;t.__c=t.__(),Re=e}function uc(t,e){return!t||t.length!==e.length||e.some(function(i,n){return!hc(i,t[n])})}function bQ(t,e){return typeof e=="function"?e(t):e}function kv(t,e=null,i=null){"use no memo";const n=t.flattenedSegments;return n==null||n.length===0?e??t.name:U("span",{"data-item-flattened-subitems":!0,children:n.map((O,r)=>{const s=r===n.length-1;return U(hO,{children:[U("span",{"data-item-flattened-subitem":O.path,"data-item-flattened-subitem-drag-target":i===O.path?"true":void 0,children:s&&e!=null?e:U(uo,{children:O.name})}),re.isTerminal)?.path??t.path:t.path}function fc(t){const e=t.flattenedSegments;return e==null||e.length===0?t.name:e.map(i=>i.name).join(" / ")}function yQ(t,e,i,n){return t.map((O,r)=>{const s=r*i,o=O.subtreeEndIndex+1;if(o>=n)return{row:O.row,top:s};const a=o*i-e;return{row:O.row,top:Math.min(s,a-i)}}).filter(O=>O.top+i>0)}function $c({controller:t,itemHeight:e,overscan:i,scrollTop:n,stickyFolders:O,viewportHeight:r}){const s=t.getVisibleCount(),o=O&&s>0?t.getStickyRowCandidates(n,e):[],a=o==null&&O&&s>0?t.getVisibleRows(0,s-1):[],l=fv(a,{itemHeight:e,overscan:i,scrollTop:n,stickyRows:o==null?void 0:yQ(o,n,e,s),totalRowCount:s,viewportHeight:r}),c=O&&n<=0&&s>0?t.getStickyRowCandidates(1,e):[],h=c!=null&&n<=0?yQ(c,1,e,s):O&&n<=0&&a.length>0?aQ(a,1,e):l.sticky.rows;return{overlayHeight:h.reduce((d,u)=>Math.max(d,u.top+e),0),overlayRows:h,snapshot:l,visibleRows:a}}const _v=400,xQ=10,QO=40,TQ=18;function Rv(t,e,i){const n=t,O=document.elementFromPoint?.bind(document)??null,r=n.elementFromPoint?.(e,i)??O?.(e,i)??null;return t instanceof ShadowRoot&&(r==null||!t.contains(r))?Zv(t,e,i):r instanceof HTMLElement?r:null}function Zv(t,e,i){const n=Array.from(t.querySelectorAll('[data-type="item"], [data-item-flattened-subitem]'));for(let O=n.length-1;O>=0;O--){const r=n[O],s=r.getBoundingClientRect();if(e>=s.left&&e<=s.right&&i>=s.top&&i<=s.bottom)return r}return null}function wQ(t){const e=t?.closest?.('[data-type="item"]');if(!(e instanceof HTMLElement))return null;const i=e.dataset.itemPath??null;if(i==null)return null;const n=t?.closest?.("[data-item-flattened-subitem]"),O=n instanceof HTMLElement?n.getAttribute("data-item-flattened-subitem")??null:null;if(O!=null&&O.endsWith("/"))return{directoryPath:O,flattenedSegmentPath:O,hoveredPath:i,kind:"directory"};if(e.dataset.itemType==="folder")return{directoryPath:i,flattenedSegmentPath:null,hoveredPath:i,kind:"directory"};const r=e.dataset.itemParentPath??null;return r==null||r.length===0?{directoryPath:null,flattenedSegmentPath:null,hoveredPath:i,kind:"root"}:{directoryPath:r,flattenedSegmentPath:null,hoveredPath:i,kind:"directory"}}function vQ(t){const e=t.cloneNode(!0);return e.removeAttribute("id"),e.dataset.fileTreeDragPreview="true",e.setAttribute("aria-hidden","true"),e.tabIndex=-1,Object.assign(e.style,{boxShadow:"0 4px 12px rgba(0, 0, 0, 0.15)",left:"0px",margin:"0",pointerEvents:"none",position:"fixed",top:"0px",willChange:"transform",zIndex:"10000"}),e}function Yv(){return navigator.vendor!=="Apple Computer, Inc."}function zv(t,e){const i=t-e.top;if(i=0;O-=1){const r=t[O],s=i.get(r);if(s!=null){for(const o of n)i.set(o,s);return s?"ignored":null}if(e.has(r)){i.set(r,!0);for(const o of n)i.set(o,!0);return"ignored"}n.push(r)}for(const O of n)i.set(O,!1);return null}function kQ(t){return t!=null&&"toggle"in t}function _Q(t){return t.code==="Space"||t.key===" "||t.key==="Spacebar"}function Uv(t){return t.key.length===1&&/^[\p{L}\p{N}]$/u.test(t.key)&&!t.ctrlKey&&!t.metaKey&&!t.altKey}function Wv(t){return t==null?"":`[data-item-section="spacing-item"][data-ancestor-path="${t.replaceAll("\\","\\\\").replaceAll('"','\\"')}"] { opacity: 1; }`}function RQ(t){return t.shiftKey&&t.key==="F10"||t.key==="ContextMenu"}function Cv(t,e){return e&&RQ(t)||(t.ctrlKey||t.metaKey)&&_Q(t)?!0:t.key==="ArrowDown"||t.key==="ArrowLeft"||t.key==="ArrowRight"||t.key==="ArrowUp"}const jv=new Set(["ArrowDown","ArrowLeft","ArrowRight","ArrowUp","End","Home","PageDown","PageUp"]);function ZQ(t){for(const e of t.composedPath())if(e instanceof HTMLElement&&(e.dataset.fileTreeContextMenuRoot==="true"||e.dataset.type==="context-menu-anchor"||e.dataset.type===vl||e.getAttribute("slot")===aO))return!0;return!1}function Gv(t){return{bottom:t.bottom,height:t.height,left:t.left,right:t.right,top:t.top,width:t.width,x:t.x,y:t.y}}function Ev(t,e){return{bottom:e,height:0,left:t,right:t,top:e,width:0,x:t,y:e}}function Iv(t,e){if(t==null)return e.offsetTop;const i=e.getBoundingClientRect(),n=t.getBoundingClientRect();return i.top-n.top}function YQ(t,e,i){if(i==null){t.delete(e);return}t.set(e,i)}function zQ(t,e,i){if(t==null)return null;const n=e.get(t)??null;if(n!=null)return n;const O=i.get(t)??null;return O?.dataset.itemParked==="true"?null:O}function Av(t){if(t==null)return[];const e=[];for(const i of t.querySelectorAll('button[data-file-tree-sticky-row="true"]')){if(!(i instanceof HTMLElement))continue;const n=i.dataset.fileTreeStickyPath;n!=null&&e.push(n)}return e}function Mv(t,e){if(t==null||e==null)return null;for(const i of t.querySelectorAll('button[data-item-focused="true"][data-item-parked="true"]'))if(i instanceof HTMLElement&&i.dataset.itemPath===e)return i;return null}function Dv(t,e,i,n,O,r,s){const o=Math.max(0,r-O),a=e?.getBoundingClientRect()??null,l=a==null||i==null?null:i.getBoundingClientRect().top-a.top,c=Mv(t,n),h=a==null||c==null?null:c.getBoundingClientRect().top-a.top;return Math.max(0,Math.min(h??Math.max(l??0,o),Math.max(0,s-O)))}function VQ(t,e){return{kind:t.kind,name:fc(t),path:e}}function Lv(t){return t==null?void 0:`${t}__tree`}function qQ(t,e,i){if(t!=null)return`${t}__focused-item-${encodeURIComponent(e)}${i?"__parked":""}`}function UQ(t){return t==="file-tree-icon-chevron"||t==="file-tree-icon-dot"||t==="file-tree-icon-file"||t==="file-tree-icon-lock"}function WQ(t,e){if(t==null)return null;if("text"in t)return U("span",{title:t.title,children:t.text});const i=typeof t.icon=="string"?UQ(t.icon)?e(t.icon):{name:t.icon}:UQ(t.icon.name)?(()=>{const n=e(t.icon.name),{name:O,...r}=t.icon;return{...n,...r}})():t.icon;return U("span",{title:t.title,children:U(Sr,{...i})})}function CQ(t){t!=null&&uO(t.querySelector(["button:not([disabled])","[href]","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(", "))??t)}function Nv(t,e,{actionLaneEnabled:i=!1,customDecoration:n=null,decorationLaneEnabled:O=!1,dragTargetFlattenedSegmentPath:r=null,gitDecoration:s=null,gitLaneActive:o=!1,renameInput:a=null,showDecorativeActionAffordance:l=!1}={}){const c=$O(t);return U(hO,{children:[t.depth>0?U("div",{"data-item-section":"spacing",children:Array.from({length:t.depth}).map((h,d)=>U("div",{"data-item-section":"spacing-item","data-ancestor-path":t.ancestorPaths[d]},d))}):null,U("div",{"data-item-section":"icon",children:t.kind==="directory"?U(Sr,{...e("file-tree-icon-chevron")}):U(Sr,{...e("file-tree-icon-file",c)})}),U("div",{"data-item-section":"content",children:t.isFlattened?kv(t,a,r):a??U(ov,{minimumLength:5,split:"extension",children:t.name})}),O?U("div",{"data-item-section":"decoration",children:n!=null?WQ(n,e):null}):null,o?U("div",{"data-item-section":"git",children:WQ(s,e)}):null,i?U("div",{"data-item-section":"action",children:l?U("span",{"aria-hidden":"true","data-item-action-affordance":"decorative",children:U(Sr,{...e("file-tree-icon-ellipsis")})}):null}):null]})}function po(t,e,i,n={}){const{controller:O,renameView:r,visualFocusPath:s,contextHoverPath:o,draggedPathSet:a,dragTarget:l,dragAndDropEnabled:c,shouldSuppressContextMenu:h,handleRowDragStart:d,handleRowDragEnd:u,handleRowTouchStart:$,instanceId:Q,itemHeight:p,gitStatusByPath:m,ignoredGitDirectories:P,ignoredInheritanceCache:g,directoriesWithGitChanges:b,gitLaneActive:X,contextMenuEnabled:y,contextMenuTriggerMode:T,contextMenuButtonTriggerEnabled:C,contextMenuButtonVisibility:G,contextMenuRightClickEnabled:J,registerRenameInput:j,registerButton:V,resolveIcon:B,renderDecorationForRow:L,openContextMenuForRow:Oe,onRowClick:te,onKeyDown:he}=t,ue=$O(e),{isParked:Qe=!1,mode:Ye="flow",style:dt}=n,ze=Ye==="sticky",Ke=m?.get(ue)??null??qv(e.ancestorPaths,P,g),Rt=e.kind==="directory"&&(b?.has(ue)??!1),mt=L(e,ue),At=Vv(Ke,Rt),Xt=y&&C,qi=mt!=null||X||Xt,ks=Xt&&G==="always",Zt=r.getPath()===ue,iO=Zt?r.getValue():"",hi=ze||!Zt?null:U(bv,{ref:j,ariaLabel:`Rename ${fc(e)}`,isFlattened:e.isFlattened,value:iO,onBlur:()=>{r.commit()},onInput:Ie=>{r.setValue(Ie.currentTarget.value)}}),ul=Nv(e,B,{actionLaneEnabled:Xt,customDecoration:mt,decorationLaneEnabled:qi,dragTargetFlattenedSegmentPath:l?.flattenedSegmentPath??null,gitDecoration:At,gitLaneActive:X,renameInput:hi,showDecorativeActionAffordance:ks}),On={...yv({ariaLabel:fc(e),domId:e.isFocused?qQ(Q,ue,Qe):void 0,extraStyle:dt,features:{actionLaneEnabled:Xt,contextMenuButtonVisibility:Xt?G:null,contextMenuEnabled:y,contextMenuTriggerMode:y?T:null,gitLaneActive:X},isParked:Qe,itemHeight:p,mode:Ye,row:e,state:{containsGitChange:Rt,effectiveGitStatus:Ke,isContextHovered:o===ue,isDragTarget:l?.kind==="directory"&&l.directoryPath===ue,isDragging:a?.has(ue)===!0,isFocusRinged:e.isFocused&&s===ue},targetPath:ue}),key:i,onContextMenu:y||c?Ie=>{if(h()){Ie.preventDefault();return}y&&(Ie.preventDefault(),J&&(O.focusMountedPathFromInput(ue),Oe(e,ue,{anchorRect:Ev(Ie.clientX,Ie.clientY),source:"right-click"})))}:void 0,onFocus:ze?void 0:()=>{O.focusMountedPathFromInput(ue)},onKeyDown:ze?void 0:he,ref:Ie=>{V(ue,Ie)}};return!ze&&Zt?U("div",{...On,children:ul}):U("button",{...On,type:"button",draggable:c&&!Qe,onDragEnd:c&&!Qe?u:void 0,onDragStart:c&&!Qe?Ie=>{d(Ie,e,ue)}:void 0,onMouseDown:Ie=>{if(ze){Ie.preventDefault();return}O.isSearchOpen()&&Ie.preventDefault()},onTouchStart:c&&!Qe?Ie=>{$(Ie,e,ue)}:void 0,onClick:Ie=>{te(Ie,e,ue,Ye)},children:ul})}function Bv(t,e,i){return e.end!i.has($O(n))).map((n,O)=>po(t,n,e.start+O))}function jQ({composition:t,controller:e,gitStatusByPath:i,ignoredGitDirectories:n,directoriesWithGitChanges:O,icons:r,instanceId:s,itemHeight:o=w$,overscan:a=lw,renamingEnabled:l=!1,renderRowDecoration:c,searchBlurBehavior:h="close",searchEnabled:d=!1,searchFakeFocus:u=!1,slotHost:$,stickyFolders:Q=!1,initialViewportHeight:p=v$}){"use no memo";const m=ee(null),P=ee(null),g=ee(!1),b=ee(null),X=ee(null),y=ee(null),T=ee(null),C=ee(null),G=ee(new Map),J=ee(new Map),j=ee(()=>{}),V=ee(null),B=ee(0),L=ee(!1),Oe=ee(null);Oe.current!==e&&(L.current=!1,Oe.current=e);const te=ee(!1),he=ee(null),ue=ee(null),Qe=ee(!1),Ye=ee(null),dt=ee(null),ze=ee(null),Ke=ee(null),Rt=ee(null),mt=ee(null),At=ee(null),Xt=ee(null),qi=ee(!1),ks=ee(null),Zt=ee(null),iO=ee(null),hi=ee(null),ul=hn(()=>new Map,[]),[,On]=Qi(0),[Ie,vn]=Qi(null),[of,fl]=Qi(null),[af,LC]=Qi(null),[NC,nO]=Qi(null),[BC,FC]=Qi(0),[Se,lf]=Qi(null),_s=ee(Se);_s.current=Se;const $l=ee(null),Rs=ee(null),Zs=ee(null),Ys=ee(null),kb=ee(null),Ql=ee(!1),HC=()=>{Rs.current=null,Zs.current=null,Ys.current=null},cf=(S,w)=>{Rs.current=S,Zs.current=null,Ys.current=w==null?null:{path:S,scrollTop:w}},KC=(S,w)=>{Rs.current=null,Zs.current={path:S,viewportOffset:w},Ys.current=null},_b=ee(h==="retain"&&e.isSearchOpen()),[JC,Rb]=Qi(u);SQ(()=>{u||Rb(!1)},[u]);const Zb=ee(!1),hf=ft(()=>{Zb.current=!0,Rb(S=>S&&!1)},[]),[ej,tj]=Qi(()=>$c({controller:e,itemHeight:o,overscan:a,scrollTop:0,stickyFolders:Q,viewportHeight:p})),[ij,nj]=Qi(!1);SQ(()=>{nj(!0)},[]);const Yt=t?.contextMenu?.enabled===!0||t?.contextMenu?.render!=null||t?.contextMenu?.onOpen!=null||t?.contextMenu?.onClose!=null,er=t?.contextMenu?.triggerMode??(Yt?"right-click":"both"),tr=er==="both"||er==="button",Yb=t?.contextMenu?.buttonVisibility??"when-needed",Oj=er==="both"||er==="right-click";qt(()=>{const S=y.current;if(S==null)return;const w=Y=>{if(!(Y instanceof CustomEvent))return;const q=Y.detail?.path??null;kb.current=q,fl(q),nO(q==null?null:"pointer")},M=Y=>{Y instanceof CustomEvent&&(Ql.current=Y.detail?.disabled===!0)};return S.addEventListener("file-tree-debug-set-context-menu-trigger",w),S.addEventListener("file-tree-debug-set-scroll-suppression",M),()=>{S.removeEventListener("file-tree-debug-set-context-menu-trigger",w),S.removeEventListener("file-tree-debug-set-scroll-suppression",M)}},[]);const rj=ft((S,w)=>{YQ(G.current,S,w)},[]),sj=ft((S,w)=>{YQ(J.current,S,w)},[]),oj=ft(S=>{X.current=S},[]),zs=ft(S=>zQ(S,J.current,G.current),[]),zb=i!=null||n!=null||O!=null,{resolveIcon:Vb}=hn(()=>Sx(r),[r]),Vs=e[E$](),ir=Vs.getPath(),df=ir!=null,Ui=e.isSearchOpen(),aj=e.getSearchValue(),se=e.getFocusedPath(),Xe=e.getFocusedIndex(),OO=e.getScrollRequest(),rn=e.isDragAndDropEnabled(),qs=e.getDragSession(),lj=hn(()=>qs==null?null:new Set(qs.draggedPaths),[qs]),cj=qs?.target??null,Us=qs?.primaryPath??null,qb=Lv(s),{overlayHeight:hj,overlayRows:dj,snapshot:Je,visibleRows:pl}=ej,ut=Je.physical.viewportHeight,di=hn(()=>({end:Je.window.endIndex,start:Je.window.startIndex}),[Je.window.endIndex,Je.window.startIndex]),Ws=dj,Ub=Je.sticky.rows,rO=Je.physical.totalHeight,nr=Je.sticky.height,ml=hn(()=>new Set(Ub.map(S=>$O(S.row))),[Ub]),uf=Xe>=0&&Xe>=di.start&&Xe<=di.end,uj=ft((S,w)=>c?.({item:VQ(S,w),row:S})??null,[c]),Wb=ft(S=>uO(S==null?null:G.current.get(S)??null)?!0:uO(y.current),[]),gl=ft(S=>{Wb(e.focusNearestPath(S))},[e,Wb]),Cb=ee(gl);Cb.current=gl;const Or=ee(!0),ff=ee(()=>{}),ei=ft((S=!0)=>{const w=_s.current;w!=null&&(Or.current=Or.current&&S,lf(null),t?.contextMenu?.onClose?.(),Or.current&&gl(w.path))},[t?.contextMenu,gl]);ff.current=ei;const Cs=ft(S=>{const w=S==null?null:Iv(y.current,S);LC(M=>M===w?M:w)},[]),jb=ft((S,w,M)=>{const Y=e.getItem(w);if(Y==null)return;const q=zs(w);if(q?.dataset.fileTreeStickyRow==="true"){const N=T.current;cf(w,N?.scrollTop??null),te.current=!0,vn(ke=>ke===w?ke:w)}Y.focus(),Cs(q),Or.current=!0,lf({anchorRect:M?.anchorRect??null,item:VQ(S,w),path:w,source:M?.source??"keyboard"})},[e,zs,Cs]),fj=ft(S=>{if(l){if(e.isSearchOpen()){const w=T.current,M=Xr(w,ut);Ye.current=Xe<0||w==null?null:Math.max(0,Math.min(Xe*o-w.scrollTop,Math.max(0,M-o))),Qe.current=!0}e.startRenaming(S)!==!1&&(nO("focus"),On(w=>w+1))}},[e,Xe,o,l,ut]),Pl=ft((S,{restoreTreeFocus:w=!0,targetOffset:M="live-overlay"}={})=>{const Y=T.current;if(Y==null)return!1;e.focusPath(S);const q=e.getFocusedIndex();if(q<0)return!1;const N=e.getVisibleRows(q,q)[0]??null;if(N==null)return!1;const ke=Xr(Y,ut),H=e.getVisibleCount()*o,de=M==="sticky-parents"?N.ancestorPaths.length*o:$c({controller:e,itemHeight:o,overscan:a,scrollTop:Y.scrollTop,stickyFolders:Q,viewportHeight:ke}).snapshot.sticky.height;return te.current=!0,br(Y,q,o,ke,H,de),j.current(),$l.current=w?S:null,!0},[e,o,a,ut,Q]),$j=()=>g.current===!0||hi.current!=null||qi.current===!0,Gb=S=>typeof window.requestAnimationFrame=="function"?window.requestAnimationFrame(()=>{S()}):window.setTimeout(S,16),Qj=S=>{if(S!=null){if(typeof window.cancelAnimationFrame=="function"){window.cancelAnimationFrame(S);return}window.clearTimeout(S)}},kn=()=>{Ke.current!=null&&(clearTimeout(Ke.current),Ke.current=null),ze.current=null},Sl=()=>{mt.current?.remove(),mt.current=null},js=()=>{Qj(dt.current),dt.current=null,Rt.current=null},Eb=S=>{const w=y.current?.getRootNode();if(w instanceof ShadowRoot){w.append(S);return}document.body.append(S)},Gs=()=>{Xt.current?.(),Xt.current=null,hi.current!=null&&(clearTimeout(hi.current),hi.current=null),qi.current=!1,ks.current=null,iO.current=null,Zt.current!=null&&(Zt.current.setAttribute("draggable","true"),Zt.current.style.removeProperty("touch-action"),Zt.current=null),Sl(),kn(),js(),At.current=null},Xl=(S,w)=>{const M=y.current?.getRootNode(),Y=wQ(Rv(M instanceof ShadowRoot?M:document,S,w));return e.setDragTarget(Y),e.getDragSession()?.target??null},$f=S=>{const w=e.getDragAndDropConfig()?.openOnDropDelay??800;if(S==null||S.kind!=="directory"||S.directoryPath==null||w<=0){kn();return}const M=e.getItem(S.directoryPath),Y=kQ(M)?M:null;if(Y==null||Y.isExpanded()){kn();return}const q=`${S.directoryPath}::${S.flattenedSegmentPath??""}`;ze.current!==q&&(kn(),ze.current=q,Ke.current=setTimeout(()=>{const N=e.getDragSession()?.target;N?.kind!=="directory"||N.directoryPath!==S.directoryPath||N.flattenedSegmentPath!==S.flattenedSegmentPath||Y.expand()},w))},Ib=()=>{dt.current=null;const S=Rt.current,w=T.current;if(S==null||w==null||e.getDragSession()==null)return;const M=w.getBoundingClientRect(),Y=zv(S.clientY,M);if(Y===0)return;const q=Math.max(0,w.scrollHeight-w.clientHeight),N=Math.max(0,Math.min(q,w.scrollTop+Y));N!==w.scrollTop&&(w.scrollTop=N,j.current()),$f(Xl(S.clientX,S.clientY)),dt.current=Gb(Ib)},Ab=(S,w)=>{Rt.current={clientX:S,clientY:w},dt.current??=Gb(Ib)},pj=(S,w,M)=>{const Y=S.currentTarget;if(Y!=null){if(Gs(),Sl(),kn(),js(),e.startDrag(M)===!1){S.preventDefault();return}if(At.current=w,S.dataTransfer!=null&&(S.dataTransfer.effectAllowed="move",S.dataTransfer.dropEffect="move",S.dataTransfer.setData("text/plain",M),Yv())){const q=vQ(Y),N=Y.getBoundingClientRect();Object.assign(q.style,{height:`${N.height}px`,opacity:"0.85",transform:"translate3d(-9999px, 0px, 0)",width:`${N.width}px`}),Eb(q),mt.current=q,S.dataTransfer.setDragImage(q,Math.max(0,S.clientX-N.left),Math.max(0,S.clientY-N.top))}}},mj=()=>{Sl(),kn(),js(),At.current=null,e.cancelDrag()},gj=(S,w,M)=>{if(hi.current!=null||qi.current)return;const Y=S.touches[0],q=S.currentTarget;if(Y==null||q==null)return;iO.current={clientX:Y.clientX,clientY:Y.clientY},Zt.current=q,q.setAttribute("draggable","false");const N=(de={})=>{const be=de.restoreNativeDraggable??!qi.current;hi.current!=null&&(clearTimeout(hi.current),hi.current=null),document.removeEventListener("touchmove",ke),document.removeEventListener("touchend",H),document.removeEventListener("touchcancel",H),Xt.current===N&&(Xt.current=null),be&&(q.setAttribute("draggable","true"),Zt.current===q&&(Zt.current=null),iO.current=null)},ke=de=>{const be=de.touches[0],xe=iO.current;if(be==null||xe==null)return;const Ce=be.clientX-xe.clientX,Ae=be.clientY-xe.clientY;Ce*Ce+Ae*Ae<=xQ*xQ||N()},H=()=>{N()};document.addEventListener("touchmove",ke,{passive:!0}),document.addEventListener("touchend",H),document.addEventListener("touchcancel",H),Xt.current=N,hi.current=setTimeout(()=>{if(N({restoreNativeDraggable:!1}),e.startDrag(M)===!1){q.setAttribute("draggable","true"),Zt.current===q&&(Zt.current=null),iO.current=null;return}qi.current=!0,Zt.current=q,q.setAttribute("draggable","false"),q.style.setProperty("touch-action","none"),At.current=w;const de=q.getBoundingClientRect(),be=vQ(q);Object.assign(be.style,{height:`${de.height}px`,opacity:"0.85",transform:`translate3d(${de.left}px, ${de.top}px, 0)`,width:`${de.width}px`}),Eb(be),mt.current=be,ks.current={x:Y.clientX-de.left,y:Y.clientY-de.top};const xe=Wi=>{const Me=Wi.touches[0];if(Me==null)return;Wi.preventDefault();const Mt=ks.current;Mt!=null&&mt.current!=null&&(mt.current.style.transform=`translate3d(${Me.clientX-Mt.x}px, ${Me.clientY-Mt.y}px, 0)`),$f(Xl(Me.clientX,Me.clientY)),Ab(Me.clientX,Me.clientY)},Ce=Wi=>{const Me=Wi.changedTouches[0];Me!=null&&Xl(Me.clientX,Me.clientY),e.completeDrag(),Gs()},Ae=()=>{e.cancelDrag(),Gs()};Xt.current=()=>{document.removeEventListener("touchmove",xe),document.removeEventListener("touchend",Ce),document.removeEventListener("touchcancel",Ae)},document.addEventListener("touchmove",xe,{passive:!1}),document.addEventListener("touchend",Ce),document.addEventListener("touchcancel",Ae)},_v)},Mb=S=>{if(Se!=null){if(S.key==="Escape"){ei(),S.preventDefault(),S.stopPropagation();return}jv.has(S.key)&&(S.preventDefault(),S.stopPropagation());return}if(Vs.isActive()){if(S.key==="Escape")Vs.cancel();else if(S.key==="Enter")Vs.commit();else return;nO("focus"),On(Ve=>Ve+1),S.preventDefault(),S.stopPropagation();return}if(l&&S.key==="F2"){fj(se??void 0),S.preventDefault(),S.stopPropagation();return}if(Ui){if(S.key==="Escape")Qe.current=!1,Ye.current=null,e.closeSearch();else if(S.key==="Enter"){const Ve=e.getFocusedPath();Ve!=null&&e.selectOnlyPath(Ve);const Ci=T.current,Tl=Xr(Ci,ut);Ye.current=Xe<0||Ci==null?null:Math.max(0,Math.min(Xe*o-Ci.scrollTop,Math.max(0,Tl-o))),Qe.current=!0,e.closeSearch()}else if(S.key==="ArrowDown")e.focusNextSearchMatch();else if(S.key==="ArrowUp")e.focusPreviousSearchMatch();else return;nO("focus"),On(Ve=>Ve+1),S.preventDefault(),S.stopPropagation();return}if(d&&Uv(S)){e.openSearch(S.key),On(Ve=>Ve+1),S.preventDefault(),S.stopPropagation();return}const w=Yt&&RQ(S),M=Cv(S,Yt),Y=M&&y.current!=null?fo(y.current):null,q=M?new Set(Av(y.current)):new Set,N=Y?.dataset.fileTreeStickyPath??null,ke=Y?.dataset.fileTreeStickyRow==="true"&&N!=null;if(ke&&N!==se&&q.has(N)){const Ve=T.current;cf(N,Ve?.scrollTop??null),e.focusPath(N)}const H=e.getFocusedPath(),de=e.getFocusedIndex(),be=e.getFocusedItem();if(be==null)return;const xe=kQ(be)?be:null,Ce=H!=null&&(ml.has(H)||ke&&N===H&&q.has(H)),Ae=S.key==="ArrowDown"||S.key==="ArrowUp"||S.key==="ArrowRight"&&xe!=null&&xe.isExpanded(),Wi=S.key==="ArrowLeft"&&Ce&&xe!=null&&xe.isExpanded(),Me=T.current;let Mt=!0;if(S.shiftKey&&S.key==="ArrowDown")e.extendSelectionFromFocused(1);else if(S.shiftKey&&S.key==="ArrowUp")e.extendSelectionFromFocused(-1);else if(w&&H!=null&&de>=0){const Ve=e.getVisibleRows(de,de)[0]??null,Ci=zQ(H,J.current,G.current);Ve==null||Ci==null?Mt=!1:jb(Ve,H)}else if((S.ctrlKey||S.metaKey)&&_Q(S))e.toggleFocusedSelection();else if((S.ctrlKey||S.metaKey)&&S.key.toLowerCase()==="a")e.selectAllVisiblePaths();else switch(S.key){case"ArrowDown":e.focusNextItem();break;case"ArrowUp":e.focusPreviousItem();break;case"ArrowRight":xe==null||xe.isExpanded()?e.focusNextItem():xe.expand();break;case"ArrowLeft":xe!=null&&xe.isExpanded()?xe.collapse():e.focusParentItem();break;case"Home":e.focusFirstItem();break;case"End":e.focusLastItem();break;default:Mt=!1}if(!Mt)return;nO("focus");const oe=e.getFocusedPath(),zt=oe!=null&&(ml.has(oe)||q.has(oe)),ui=Ae&&oe!==H,xl=w&&ke&&N===H&&oe===H;if((Ce||xl)&&oe!=null&&(ui&&zt||xl))cf(oe,Me?.scrollTop??null),te.current=!0,vn(Ve=>Ve===oe?Ve:oe);else{const Ve=S.key==="ArrowUp"&&Ce&&oe!==H;oe!=null&&(Ve||Wi&&oe===H)?(KC(oe,Dv(y.current,Me,Y,H,o,nr,ut)),te.current=!0,vn(Ci=>Ci===oe?Ci:oe)):HC()}On(Ve=>Ve+1),S.preventDefault(),S.stopPropagation()};qt(()=>{if(!(!d||!Ui)){if(_b.current){_b.current=!1;return}uO(C.current)}},[Ui,d]),qt(()=>{const S=X.current;switch(Xv({hasRenderedInput:S!=null,previousRenamingPath:ue.current,renamingPath:ir})){case"reset":ue.current=null;return;case"reveal-canonical":ir!=null&&Pl(ir,{restoreTreeFocus:!1,targetOffset:"live-overlay"});return;case"ignore":return;case"focus-input":S!=null&&($l.current=null,ue.current=ir,uO(S),S.select());return}},[di.end,di.start,ir,Pl,ml]),qt(()=>{const S=y.current;if(S==null)return;let w=null;const M=()=>{w!=null&&(clearTimeout(w),w=null)},Y=()=>{const ke=fo(S)?.dataset.itemPath??null;vn(H=>H===ke?H:ke)},q=()=>{M(),te.current=!0,Y()},N=ke=>{const H=ke.relatedTarget;if(H==null){M(),w=setTimeout(()=>{if(w=null,fo(S)!=null){Y();return}te.current=!1,vn(null)},0);return}if(!(H instanceof Node)||!S.contains(H)){M(),te.current=!1,vn(null);return}const de=H instanceof HTMLElement?H.dataset.itemPath??null:null;vn(be=>be===de?be:de)};return S.addEventListener("focusin",q),S.addEventListener("focusout",N),()=>{M(),S.removeEventListener("focusin",q),S.removeEventListener("focusout",N)}},[]),qt(()=>{const S=y.current;S!=null&&(Je.physical.scrollTop<=0?S.dataset.scrollAtTop="true":delete S.dataset.scrollAtTop)},[Je.physical.scrollTop]),qt(()=>{let S=null;const w=T.current,M=b.current,Y=y.current;if(w==null)return;V.current=Xr(w,p);const q=()=>{const oe=e.getVisibleCount(),zt=cQ(V.current,p),ui=Math.max(0,oe*o-zt);w.scrollTop>ui&&(w.scrollTop=ui),tj($c({controller:e,itemHeight:o,overscan:a,scrollTop:Math.min(w.scrollTop,ui),stickyFolders:Q,viewportHeight:zt}))};if(!L.current){L.current=!0;const oe=e.getFocusedIndex();if(oe>=0){const zt=cQ(V.current,p),ui=e.getVisibleRows(oe,oe)[0]??null;hQ(w,oe,o,zt,Q&&ui!=null?Math.max(0,Math.min(ui.ancestorPaths.length*o,Math.max(0,zt-o))):0)}}j.current=q;let N=!1;const ke=e.subscribe(()=>{N?On(oe=>oe+1):N=!0,q()}),H=()=>{Ql.current!==!0&&(M!=null&&(M.dataset.isScrolling??=""),Y!=null&&(Y.dataset.isScrolling??=""),g.current=!0,S!=null&&clearTimeout(S),S=setTimeout(()=>{M!=null&&delete M.dataset.isScrolling,Y!=null&&delete Y.dataset.isScrolling,g.current=!1,FC(oe=>oe+1),S=null},50))};let de=null;const be=()=>{Y!=null&&delete Y.dataset.overlayReveal,de!=null&&(clearTimeout(de),de=null)},xe=()=>{Y==null||Ql.current===!0||w.scrollTop>0||(Y.dataset.overlayReveal="true",de!=null&&clearTimeout(de),de=setTimeout(()=>{be()},200))},Ce=()=>{if(q(),w.scrollTop>0&&be(),_s.current!=null&&g.current&&ff.current(),Ql.current===!0){g.current=!1;return}fl(oe=>oe==null?oe:null),H()},Ae=()=>{H(),xe()},Wi=new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"," ","Spacebar"]),Me=oe=>{Wi.has(oe.key)&&Ae()};w.addEventListener("scroll",Ce,{passive:!0}),w.addEventListener("wheel",Ae,{passive:!0}),w.addEventListener("touchmove",Ae,{passive:!0}),w.addEventListener("keydown",Me);const Mt=typeof ResizeObserver<"u"?new ResizeObserver(oe=>{V.current=(oe[0]==null?null:Pv(oe[0]))??Xr(w,p),q()}):null;return Mt?.observe(w),()=>{j.current=()=>{},ke(),w.removeEventListener("scroll",Ce),w.removeEventListener("wheel",Ae),w.removeEventListener("touchmove",Ae),w.removeEventListener("keydown",Me),S!=null&&clearTimeout(S),de!=null&&clearTimeout(de),M!=null&&delete M.dataset.isScrolling,Y!=null&&(delete Y.dataset.isScrolling,delete Y.dataset.overlayReveal),g.current=!1,V.current=null,Mt?.disconnect()}},[e,p,o,a,Q]),qt(()=>{Yt||Se==null||ei(!1)},[ei,Yt,Se]);const Db=hn(()=>Se==null?null:`${Se.path}::${Se.source}`,[Se]);qt(()=>{if(Db==null){$?.clearSlotContent(aO);return}const S=_s.current;if(S==null)return;const w=P.current??m.current;if(w==null)return;const M={anchorElement:w,anchorRect:S.anchorRect??Gv(w.getBoundingClientRect()),close:q=>{ff.current(q?.restoreFocus??!0)},restoreFocus:()=>{Or.current&&Cb.current(_s.current?.path??null)}},Y=t?.contextMenu?.render?.(S.item,M)??null;return $?.setSlotContent(aO,Y),t?.contextMenu?.onOpen?.(S.item,M),CQ(Y),queueMicrotask(()=>{Y==null||!Y.isConnected||document.activeElement===Y&&CQ(Y)}),()=>{$?.clearSlotContent(aO)}},[Db,t?.contextMenu,$]),qt(()=>{Se!=null&&e.getItem(Se.path)==null&&ei()},[ei,Se,e]),qt(()=>{if(Se==null)return;const S=y.current?.getRootNode(),w=S instanceof ShadowRoot?S.host:y.current,M=q=>{const N=q.target;N instanceof Node&&(ZQ(q)||m.current?.contains(N)!==!0&&w?.contains(N)!==!0&&ei())},Y=q=>{q.key==="Escape"&&(q.preventDefault(),q.stopPropagation(),ei())};return document.addEventListener("mousedown",M,!0),document.addEventListener("keydown",Y,!0),()=>{document.removeEventListener("mousedown",M,!0),document.removeEventListener("keydown",Y,!0)}},[ei,Se]),qt(()=>{const S=T.current,w=y.current;if(S==null||w==null){he.current=se;return}const M=se==null?null:G.current.get(se)??null,Y=fo(w),q=Y?.dataset.itemPath??null,N=df&&X.current===Y,ke=d&&C.current===Y,H=Qe.current&&!Ui,de=Ye.current??0,be=$l.current,xe=Rs.current,Ce=Zs.current,Ae=Ys.current,Wi=Y!=null,Me=te.current||Wi,Mt=he.current!==se,oe=xe!=null&&xe===se&&se!=null;let zt=!1,ui=!1;if(OO!=null&&OO.id!==B.current){B.current=OO.id;const pf=OO.visibleIndex,Hb=e.getVisibleRows(pf,pf)[0]??null;if(Hb!=null){const Mj=Q?Math.max(0,Math.min(Hb.ancestorPaths.length*o,Math.max(0,ut-o))):nr;zt=!0,ui=Sv(S,pf,o,ut,rO,OO.offset,Mj)}e.clearScrollRequest(OO.id)}const xl=!zt&&H&&br(S,Xe,o,ut,rO,de),Ve=!zt&&be!=null&&be===se&&br(S,Xe,o,ut,rO,nr),Ci=!zt&&Ce!=null&&Ce.path===se&&br(S,Xe,o,ut,rO,Ce.viewportOffset),Tl=!zt&&Ae!=null&&Ae.path===se&&S.scrollTop!==Ae.scrollTop;if(Tl&&(S.scrollTop=Ae.scrollTop),(Tl||ui||Ve||Ci||xl||Me&&Mt&&be!==se&&!oe&&hQ(S,Xe,o,ut,nr))&&j.current(),zt){he.current=se;return}if(!Me){he.current=se;return}if(N){he.current=se;return}if(ke&&!H){he.current=se;return}if(M==null){H&&Xe>=0&&(br(S,Xe,o,ut,rO,de),j.current()),he.current=se;return}(Mt||H||be===se||xe===se||Ce?.path===se||Ae?.path===se||q==null||q!==se)&&(uO(M),be===se&&($l.current=null),xe===se&&(Rs.current=null),Ce?.path===se&&(Zs.current=null),Ae?.path===se&&(Ys.current=null),Qe.current=!1,Ye.current=null),he.current=se},[e,Xe,se,uf,o,df,Ui,di,ut,d,OO,Q,nr,rO,pl]);const Pj=Xe>=0&&Xe>=Je.visible.startIndex&&Xe<=Je.visible.endIndex,Sj=se!=null&&Ws.some(S=>$O(S.row)===se),Xj=Pj||Sj,bj=tr&&te.current===!0&&Xj?se:null,yj=NC==="pointer"?of:null,sO=Se?.path??kb.current??yj??bj??of,Lb=Se?.source==="right-click";qt(()=>{g.current&&Se==null||Cs(zs(sO))},[Se,zs,di,ut,BC,Ws,sO,Cs,pl]);const xj=ft(S=>{if(g.current||ZQ(S))return;const w=S.target;if(!(w instanceof HTMLElement)||w.closest?.(`[data-type="${vl}"]`)!=null)return;const M=w.closest?.('[data-file-tree-sticky-row="true"]'),Y=w.closest?.('[data-type="item"]'),q=M instanceof HTMLElement?M.dataset.fileTreeStickyPath??null:Y instanceof HTMLElement?Y.dataset.itemPath??null:null;q!=null&&nO(N=>N==="pointer"?N:"pointer"),fl(N=>N===q?N:q)},[]),Tj=ft(()=>{fl(null)},[]);qt(()=>{if(!rn)return;const S=()=>{Gs(),e.cancelDrag()};return window.addEventListener("dragend",S),()=>{window.removeEventListener("dragend",S),Gs(),e.cancelDrag()}},[e,rn]);const wj=S=>{if(!rn||e.getDragSession()==null||qi.current)return;const w=wQ(S.target instanceof HTMLElement?S.target:null);e.setDragTarget(w),$f(e.getDragSession()?.target??null),Ab(S.clientX,S.clientY),S.dataTransfer!=null&&(S.dataTransfer.dropEffect="move"),S.preventDefault()},vj=S=>{if(!rn||e.getDragSession()==null||qi.current)return;const w=S.relatedTarget;w instanceof Node&&y.current?.contains(w)===!0||(kn(),js(),e.setDragTarget(null))},kj=S=>{!rn||e.getDragSession()==null||qi.current||(S.preventDefault(),Xl(S.clientX,S.clientY),e.completeDrag(),Sl(),kn(),js(),At.current=null)},Es=Je.window.height,_j=Je.window.offsetTop,Rj=Math.min(0,ut-Es),Zj=Math.min(0,ut-Es-nr),Yj=Ie===se||Qe.current,rr=se!=null&&Yj&&!uf&&Xe>=0?pl[Xe]??e.getVisibleRows(Xe,Xe)[0]??null:null,Nb=rr==null?null:dQ(Xe,o,di,Es),_n=At.current,zj=Us!=null&&_n!=null&&_n.path===Us&&_n.index>=di.start&&_n.index<=di.end,Is=Us!=null&&_n!=null&&_n.path===Us&&!zj&&_n.path!==rr?.path?_n:null,Bb=Is==null?null:dQ(Is.index,o,di,Es),Vj=Wv((Xe>=0?pl[Xe]??e.getVisibleRows(Xe,Xe)[0]??null:null)?.ancestorPaths.at(-1)??null),qj=Ui&&se!=null?qQ(s,se,!uf):void 0,Uj=Se?.path??(Ui?se:Ie),Wj=Se?.path??of,As=zs(sO),Qf=Yt&&tr&&!Lb&&!df&&As!=null&&af!=null&&sO!=null,Cj=Yt&&(Qf||Se!=null),bl=Se?.anchorRect,Fb=bl==null&&As!=null&&af!=null&&(Se!=null||Qf)?af:null,jj=bl!=null?{left:`${bl.left}px`,position:"fixed",right:"auto",top:`${bl.top}px`}:Fb!=null?{top:`${Fb}px`}:void 0,Gj=Lb?{opacity:"0"}:void 0,Ej=ft((S,w,M,Y)=>{const q=xv({event:{ctrlKey:S.ctrlKey,metaKey:S.metaKey,shiftKey:S.shiftKey},isDirectory:w.kind==="directory",isSearchOpen:Ui,mode:Y}),N=q.toggleDirectory&&w.kind==="directory",ke=N?e.resolveMountedDirectoryPathFromInput(M):null;if(N&&ke==null)return;const H=ke??M;switch(q.selection.kind){case"range":e.selectPathRange(H,q.selection.additive);break;case"toggle":e.togglePathSelectionFromInput(H);break;case"single":e.selectOnlyMountedPathFromInput(H);break}const de=S.currentTarget instanceof HTMLElement?S.currentTarget:null,be=w.index>=Je.visible.startIndex&&w.index<=Je.visible.endIndex,xe=Y==="flow"&&be&&de!=null&&de.dataset.itemParked!=="true";e.focusMountedPathFromInput(H),xe&&(te.current=!0,vn(Ce=>Ce===H?Ce:H),nO("focus")),N&&e.toggleMountedDirectoryFromInput(H),q.closeSearch&&e.closeSearch(),q.revealCanonical&&Pl(H,{targetOffset:"sticky-parents"})},[e,Ui,Je.visible.endIndex,Je.visible.startIndex,Pl]),Ij=()=>{if(g.current||!tr||sO==null||As==null)return;const S=e.getItem(sO);S!=null&&(Cs(As),Or.current=!0,lf({anchorRect:null,item:{kind:S.isDirectory()?"directory":"file",name:As.getAttribute("aria-label")??sO,path:S.getPath()},path:S.getPath(),source:"button"}))},yl={contextHoverPath:Wj,contextMenuButtonTriggerEnabled:tr,contextMenuButtonVisibility:Yb,contextMenuEnabled:Yt,contextMenuRightClickEnabled:Oj,contextMenuTriggerMode:er,controller:e,directoriesWithGitChanges:O,dragAndDropEnabled:rn,draggedPathSet:lj,dragTarget:cj,gitLaneActive:zb,gitStatusByPath:i,handleRowDragEnd:mj,handleRowDragStart:pj,handleRowTouchStart:gj,ignoredGitDirectories:n,ignoredInheritanceCache:ul,instanceId:s,itemHeight:o,onKeyDown:Mb,onRowClick:Ej,openContextMenuForRow:jb,registerButton:rj,registerRenameInput:oj,renameView:Vs,renderDecorationForRow:uj,resolveIcon:Vb,shouldSuppressContextMenu:$j,visualFocusPath:Uj},Aj={...yl,registerButton:sj};return U("div",{ref:y,id:qb,"data-file-tree-context-menu-button-visibility":Yt&&tr?Yb:void 0,"data-file-tree-context-menu-trigger-mode":Yt?er:void 0,"data-file-tree-has-context-menu-action-lane":Yt&&tr?"true":void 0,"data-file-tree-has-git-lane":zb?"true":void 0,"data-file-tree-virtualized-root":"true",onDragLeave:rn?vj:void 0,onDragOver:rn?wj:void 0,onDrop:rn?kj:void 0,onKeyDown:Mb,onPointerLeave:Yt?Tj:void 0,onPointerOver:Yt?xj:void 0,role:"tree",tabIndex:-1,style:{outline:"none",position:"relative"},children:[U("style",{"data-file-tree-guide-style":"true",dangerouslySetInnerHTML:{__html:Vj}}),U("slot",{name:Ds,"data-type":"header-slot"}),d?U("div",{"data-file-tree-search-container":!0,"data-open":Ui?"true":"false",children:U("input",{ref:C,"aria-activedescendant":qj,"aria-controls":qb,placeholder:"Search…","data-file-tree-search-input":!0,"data-file-tree-search-input-fake-focus":JC?"true":void 0,value:aj,onBlur:()=>{h==="retain"&&!Zb.current||e.closeSearch()},onFocus:hf,onPointerDown:hf,onInput:S=>{hf();const w=S.currentTarget;e.setSearch(w.value)}})}):null,U("div",{ref:T,"data-file-tree-virtualized-scroll":"true",children:[Q&&ij&&Ws.length>0?U("div",{"aria-hidden":"true","data-file-tree-sticky-overlay":"true",children:U("div",{"data-file-tree-sticky-overlay-content":"true",style:{height:`${hj}px`},children:Ws.map((S,w)=>po(Aj,S.row,`sticky:${$O(S.row)}`,{mode:"sticky",style:{left:"0",position:"absolute",right:"0",top:`${S.top}px`,zIndex:`${Ws.length-w}`}}))})}):null,U("div",{ref:b,"data-file-tree-virtualized-list":"true",style:{height:`${rO}px`},children:[U("div",{"data-file-tree-virtualized-sticky-offset":"true","aria-hidden":"true",style:{height:`${_j}px`}}),U("div",{"data-file-tree-virtualized-sticky":"true",style:{height:`${Es}px`,top:`${Rj}px`,bottom:`${Zj}px`},children:[Bv(yl,di,ml),rr!=null&&Nb!=null?po(yl,rr,`parked:${rr.path}`,{isParked:!0,style:{left:"0",opacity:"0",pointerEvents:Us===rr.path?"none":void 0,position:"absolute",right:"0",top:`${Nb}px`}}):null,Is!=null&&Bb!=null?po(yl,Is,`parked-drag:${Is.path}`,{isParked:!0,style:{left:"0",opacity:"0",pointerEvents:"none",position:"absolute",right:"0",top:`${Bb}px`}}):null]})]})]}),Yt?U("div",{ref:m,"data-type":"context-menu-anchor","data-visible":Cj?"true":"false",style:jj,children:[U("button",{ref:P,type:"button","data-type":vl,"aria-label":"Options","aria-haspopup":"menu","aria-expanded":Se!=null?"true":"false","data-visible":Qf?"true":"false",onMouseDown:S=>{S.preventDefault()},onClick:S=>{if(S.preventDefault(),S.stopPropagation(),Se!=null){ei();return}Ij()},tabIndex:-1,style:Gj,children:U(Sr,{...Vb("file-tree-icon-ellipsis")})}),Se!=null?U("slot",{name:aO}):null]}):null,Se!=null?U("div",{"data-type":"context-menu-wash","aria-hidden":"true",onMouseDownCapture:S=>{S.preventDefault(),ei()},onTouchStartCapture:S=>{S.preventDefault(),S.stopPropagation(),ei()},onTouchMoveCapture:S=>{S.preventDefault(),S.stopPropagation()},onWheelCapture:S=>{S.preventDefault(),S.stopPropagation()}}):null]})}const Qc={hydrateRoot:(t,e)=>{Bw(ic(jQ,e),t)},renderRoot:(t,e)=>{sc(ic(jQ,e),t)},unmountRoot:t=>{sc(null,t)}};function mo(t,e){Qc.renderRoot(t,e)}function Fv(t,e){Qc.hydrateRoot(t,e)}function Hv(t){Qc.unmountRoot(t)}var Kv=class{#e=new Map;#i=null;clearAll(){for(const t of this.#e.values())t.remove();this.#e.clear()}clearSlotContent(t){const e=this.#l(t);e!=null&&(e.remove(),this.#e.delete(t))}setHost(t){if(this.#i=t,t!=null){this.#s(t);for(const[e,i]of this.#e)this.#c(e,i)}}setSlotContent(t,e){const i=this.#l(t);if(i===e){e!=null&&(this.#e.set(t,e),this.#c(t,e));return}if(i?.remove(),e==null){this.#e.delete(t);return}this.#e.set(t,e),this.#c(t,e)}setSlotHtml(t,e){const i=e?.trim()??"";if(i.length===0){this.setSlotContent(t,null);return}const n=this.#l(t);if(n!=null&&n.innerHTML===i){this.#e.set(t,n),this.#c(t,n);return}const O=document.createElement("div");O.innerHTML=i,this.setSlotContent(t,O)}#l(t){const e=this.#e.get(t)??null;if(e!=null)return e;const i=this.#i;if(i==null)return null;for(const n of Array.from(i.children))if(n instanceof HTMLElement&&n.dataset.fileTreeManagedSlot===t)return n;return null}#c(t,e){e.slot=t,e.dataset.fileTreeManagedSlot=t,this.#i!=null&&e.parentNode!==this.#i&&this.#i.appendChild(e)}#s(t){for(const e of Array.from(t.children)){if(!(e instanceof HTMLElement))continue;const i=e.dataset.fileTreeManagedSlot;i==null||this.#e.has(i)||this.#e.set(i,e)}}};let GQ=0;function Jv(t){return t!=null&&t.length>0?t:(GQ+=1,`pst_ft_${GQ}`)}function e5({initialVisibleRowCount:t,itemHeight:e}){return t==null?v$:Math.max(0,t)*(e??w$)}function EQ(t){if(typeof document>"u")return;const e=document.createElement("div");e.innerHTML=t;const i=e.querySelector("svg");return i instanceof SVGElement?i:void 0}function IQ(t){return t.querySelector("#file-tree-icon-chevron")instanceof SVGElement&&t.querySelector("#file-tree-icon-file")instanceof SVGElement&&t.querySelector("#file-tree-icon-dot")instanceof SVGElement&&t.querySelector("#file-tree-icon-lock")instanceof SVGElement}function AQ(t){return Array.from(t.children).filter(e=>e instanceof SVGElement)}var t5=class{static LoadedCustomComponent=$w;#e;#i;#l;#c;#s;#C;#j;#Q;#n;#p=new Kv;#v;#m;#f;#g;#P;#S;#d;#G;#E;#z=null;#O;#I=!1;#A=!1;constructor(e){const{composition:i,density:n,fileTreeSearchMode:O,gitStatus:r,id:s,initialSearchQuery:o,icons:a,itemHeight:l,onSearchChange:c,onSelectionChange:h,overscan:d,renderRowDecoration:u,renaming:$,search:Q,searchBlurBehavior:p,searchFakeFocus:m,stickyFolders:P,unsafeCSS:g,initialVisibleRowCount:b,...X}=e;this.#e=i,this.#l=Jv(s),this.#g=I$(r),this.#P=a,this.#S=g,this.#c=h,this.#s=u,this.#C=$!=null&&$!==!1,this.#j=p,this.#Q=Q===!0,this.#n=m===!0,this.#v=aw(n,l),this.#m={itemHeight:this.#v.itemHeight,overscan:d,stickyFolders:P,initialVisibleRowCount:b},this.#i=new Cw({...X,fileTreeSearchMode:O,initialSearchQuery:o,onSearchChange:c,renaming:$}),this.#E=this.#i.getSelectionVersion(),this.#z=this.#c==null?null:this.subscribe(()=>{this.#k()})}unmount(){this.#O!=null&&(Hv(this.#O),delete this.#O.dataset.fileTreeVirtualizedWrapper,this.#O=void 0),this.#p.clearAll(),this.#p.setHost(null),this.#f!=null&&(delete this.#f.dataset.fileTreeVirtualized,this.#q(this.#f),this.#f=void 0)}cleanUp(){this.unmount(),this.#z?.(),this.#z=null,this.#i.destroy()}getFileTreeContainer(){return this.#f}getItem(e){return this.#i.getItem(e)}getFocusedItem(){return this.#i.getFocusedItem()}getFocusedPath(){return this.#i.getFocusedPath()}getSelectedPaths(){return this.#i.getSelectedPaths()}getComposition(){return this.#e}getItemHeight(){return this.#v.itemHeight}getDensityFactor(){return this.#v.factor}subscribe(e){let i=!1;return this.#i.subscribe(()=>{if(!i){i=!0;return}e()})}focusPath(e){this.#i.focusPath(e)}scrollToPath(e,i){this.#i.scrollToPath(e,i)}focusNearestPath(e){return this.#i.focusNearestPath(e)}add(e){this.#i.add(e)}batch(e){this.#i.batch(e)}move(e,i,n){this.#i.move(e,i,n)}onMutation(e,i){return this.#i.onMutation(e,i)}setSearch(e){this.#i.setSearch(e)}openSearch(e){this.#i.openSearch(e)}closeSearch(){this.#i.closeSearch()}isSearchOpen(){return this.#i.isSearchOpen()}getSearchValue(){return this.#i.getSearchValue()}getSearchMatchingPaths(){return this.#i.getSearchMatchingPaths()}focusNextSearchMatch(){this.#i.focusNextSearchMatch()}focusPreviousSearchMatch(){this.#i.focusPreviousSearchMatch()}startRenaming(e,i){return this.#i.startRenaming(e,i)}remove(e,i){this.#i.remove(e,i)}resetPaths(e,i){this.#i.resetPaths(e,i)}setComposition(e){this.#e=e;const i=this.#o();i!=null&&(this.#x(),mo(i.wrapper,this.#R()))}setGitStatus(e){this.#g=I$(e,this.#g);const i=this.#o();i!=null&&mo(i.wrapper,this.#R())}setIcons(e){this.#P=e;const i=this.#o();i!=null&&(this.#$(i.host,i.wrapper),mo(i.wrapper,this.#R()))}hydrate({fileTreeContainer:e}){const i=this.#Z(e),n=this.#V(i);this.#x(),Fv(n,this.#R())}render({containerWrapper:e,fileTreeContainer:i}){const n=this.#Z(i??this.#f,e),O=this.#V(n);this.#x(),mo(O,this.#R())}#K(){return{initialViewportHeight:e5({initialVisibleRowCount:this.#m.initialVisibleRowCount,itemHeight:this.#m.itemHeight}),itemHeight:this.#m.itemHeight,overscan:this.#m.overscan,stickyFolders:this.#m.stickyFolders}}#R(){return{composition:this.#e,controller:this.#i,gitStatusByPath:this.#g?.statusByPath,ignoredGitDirectories:this.#g?.ignoredDirectoryPaths,directoriesWithGitChanges:this.#g?.directoriesWithChanges,icons:this.#P,instanceId:this.#l,renamingEnabled:this.#C,renderRowDecoration:this.#s,searchBlurBehavior:this.#j,searchEnabled:this.#Q,searchFakeFocus:this.#n,slotHost:this.#p,...this.#K()}}#o(){const e=this.#f,i=this.#O;return e==null||i==null?null:{host:e,wrapper:i}}#$(e,i){const n=e.shadowRoot;n!=null&&(this.#M(n),this.#D(n)),this.#L(i)}#k(){const e=this.#c;if(e==null)return;const i=this.#i.getSelectionVersion();i!==this.#E&&(this.#E=i,e(this.#i.getSelectedPaths()))}#x(){const e=this.#e?.header?.render;if(e!=null){this.#p.setSlotContent(Ds,e());return}this.#p.setSlotHtml(Ds,this.#e?.header?.html??null)}#M(e){const i=AQ(e).find(O=>IQ(O)),n=EQ(hx(Ls(this.#P).set));n!=null&&(i!=null&&i.outerHTML===n.outerHTML||(i!=null?i.replaceWith(n):e.prepend(n)))}#D(e){const i=AQ(e),n=i.find(o=>IQ(o)),O=i.filter(o=>o!==n),r=Ls(this.#P).spriteSheet?.trim()??"";if(r.length===0){for(const o of O)o.remove();return}const s=EQ(r);if(s==null){for(const o of O)o.remove();return}if(!(O.length===1&&O[0].outerHTML===s.outerHTML)){for(const o of O)o.remove();e.appendChild(s)}}#L(e){const i=Ls(this.#P);i.colored&&ux(i.set)?e.dataset.fileTreeColoredIcons="true":delete e.dataset.fileTreeColoredIcons}#a(e){const i=e.querySelector(`style[${Tf}]`);if(this.#d==null&&i instanceof HTMLStyleElement&&(this.#d=i),this.#S==null||this.#S===""){this.#d?.remove(),this.#d=void 0,this.#G=void 0;return}this.#d?.parentNode===e&&this.#G===this.#S||(this.#d??=document.createElement("style"),this.#d.setAttribute(Tf,""),this.#d.parentNode!==e&&e.appendChild(this.#d),this.#d.textContent=cw(this.#S),this.#G=this.#S)}#V(e){if(this.#O!=null)return this.#O;const i=e.shadowRoot;if(i==null)throw new Error("FileTree requires a shadow root");const n=Array.from(i.children).filter(r=>r instanceof HTMLDivElement&&typeof r.dataset.fileTreeId=="string"&&r.dataset.fileTreeId.length>0),O=n.find(r=>r.dataset.fileTreeId===this.#l)??n[0];return O!=null&&(this.#l=O.dataset.fileTreeId??this.#l),this.#O=O??document.createElement("div"),this.#O.dataset.fileTreeId=this.#l,this.#O.dataset.fileTreeVirtualizedWrapper="true",this.#$(e,this.#O),this.#O.parentNode!==i&&i.appendChild(this.#O),this.#O}#Z(e,i){const n=e??this.#f??document.createElement(ar);i!=null&&n.parentNode!==i&&i.appendChild(n);const O=n.shadowRoot??n.attachShadow({mode:"open"});return Nl(n,O),this.#a(O),n.dataset.fileTreeVirtualized="true",n.style.display="flex",this.#y(n),this.#p.setHost(n),this.#f=n,n}#y(e){e.style.getPropertyValue("--trees-item-height")===""&&(e.style.setProperty("--trees-item-height",`${String(this.#v.itemHeight)}px`),this.#I=!0),e.style.getPropertyValue("--trees-density-override")===""&&(e.style.setProperty("--trees-density-override",String(this.#v.factor)),this.#A=!0)}#q(e){this.#I&&(e.style.removeProperty("--trees-item-height"),this.#I=!1),this.#A&&(e.style.removeProperty("--trees-density-override"),this.#A=!1)}};const MQ=typeof window>"u"?Ne.useEffect:Ne.useLayoutEffect;function i5(t,e,i){const n=t!=null?k.jsx("div",{slot:Ds,children:t}):null,O=e!=null&&i!=null?k.jsx("div",{slot:aO,children:e(i.item,i.context)}):null;return n==null&&O==null?null:k.jsxs(k.Fragment,{children:[n,O]})}function n5(t,e){return typeof window>"u"&&e!=null?k.jsxs(k.Fragment,{children:[k.jsx("template",{shadowrootmode:"open",dangerouslySetInnerHTML:{__html:e.shadowHtml}}),t]}):k.jsx(k.Fragment,{children:t})}function O5(t){const e=t.shadowRoot;return e?.querySelector("[data-file-tree-id]")instanceof HTMLElement||e?.querySelector("[data-file-tree-id]")instanceof SVGElement?!0:t.querySelector('template[shadowrootmode="open"]')instanceof HTMLTemplateElement}function r5(t,e,i,n,O){const r={...t??{}};if(e!=null&&delete r.header,i){const s=t?.contextMenu,o=s?.onClose,a=s?.onOpen;r.contextMenu={...s??{},enabled:!0,onClose:()=>{o?.(),n()},onOpen:(l,c)=>{O(l,c),a?.(l,c)}},delete r.contextMenu.render}return r.header!=null||r.contextMenu!=null?r:void 0}function s5({header:t,id:e,model:i,preloadedData:n,renderContextMenu:O,...r}){const[s,o]=Ne.useState(null),[a,l]=Ne.useState(null),c=Ne.useRef(i.getComposition()),h=Ne.useRef(i);h.current!==i&&(h.current=i,c.current=i.getComposition());const d=O!=null,u=Ne.useCallback(()=>{o(null)},[]),$=Ne.useCallback((X,y)=>{o({context:y,item:X})},[]),Q=c.current,p=Ne.useMemo(()=>r5(Q,t,d,u,$),[Q,u,$,d,t]),m=Ne.useCallback(X=>{l(X)},[]);Ne.useEffect(()=>{d||o(null)},[d]),MQ(()=>{i.setComposition(p)},[p,i]),MQ(()=>{if(a!=null)return n!=null&&O5(a)?i.hydrate({fileTreeContainer:a}):i.render({fileTreeContainer:a}),()=>{i.unmount(),i.setComposition(Q)}},[Q,a,i,n]);const P=n5(i5(t,O,s),n),g=e??n?.id,b={"--trees-item-height":`${String(i.getItemHeight())}px`,"--trees-density-override":i.getDensityFactor(),...r.style};return k.jsx(ar,{...r,id:g,ref:m,style:b,suppressHydrationWarning:n!=null,children:P})}function o5(t){const[e]=Ne.useState(()=>new t5(t)),i=Ne.useRef({timeout:null,model:e});return Ne.useEffect(()=>{const{current:n}=i;return n.timeout!=null&&(clearTimeout(n.timeout),n.timeout=null),()=>{n.timeout=setTimeout(()=>n.model.cleanUp(),1)}},[]),{model:e}}function a5(t,e){if(t===e)return!0;if(t.length!==e.length)return!1;for(let i=0;it.subscribe(s),[t]),r=Ne.useCallback(()=>{const s=n.current,o=e(t);if(s.model!==t||s.selector!==e||!s.hasValue)return s.hasValue=!0,s.model=t,s.selector=e,s.value=o,o;const a=s.value;return l5(a,o,i)?a:(s.value=o,o)},[i,t,e]);return Ne.useSyncExternalStore(O,r,r)}function h5(t){return c5(t,e=>e.getSelectedPaths(),a5)}const DQ="M12.65 12.854V24c6.042-.325 10.923-5.105 11.33-11.125H12.65Zm-1.504 0H.02c.427 5.94 5.166 10.699 11.105 11.105V12.854Zm1.505-1.505H24C23.675 5.247 18.753.325 12.65 0Zm-1.505 0V0C5.106.427.326 5.308 0 11.35Z";function d5(t){const e=t.toLowerCase().match(/\.([^./\\]+)$/);return e?e[1]:""}function u5({path:t,className:e}){return d5(t)==="qmd"?k.jsx("svg",{className:e,width:"14",height:"14",viewBox:"0 0 24 24",fill:"#39729e","aria-hidden":"true",children:k.jsx("path",{d:DQ})}):k.jsxs("svg",{className:e,width:"14",height:"14",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"1.3",strokeLinejoin:"round","aria-hidden":"true",children:[k.jsx("path",{d:"M4 1.6h5l3.5 3.6V14a.4.4 0 0 1-.4.4H4a.4.4 0 0 1-.4-.4V2a.4.4 0 0 1 .4-.4Z"}),k.jsx("path",{d:"M9 1.6v3.6h3.5"})]})}const f5=Tx({bg:"#f6f8fa",fg:"#1f2328"}),$5={set:"complete",colored:!0,spriteSheet:``,byFileExtension:{qmd:{name:"amsync-quarto",viewBox:"0 0 24 24"}}};function Q5({paths:t}){const{model:e}=o5({paths:t,search:!0,density:"compact",initialExpansion:"open",icons:$5}),i=et.useRef(!1);et.useEffect(()=>{if(!i.current){i.current=!0;return}e.resetPaths(t,{initialExpandedPaths:void 0})},[e,t]);const n=et.useMemo(()=>new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,,,2,6,,4g,,3,8,l,2,1l,2,,,,,m,,e,7,3,5,5f,8,2,3,,,n,,29,,2,6,,,2,,,2,,2,6j,,2,4,6,2,,2,r,2,2d,8,2,,,2,2y,,,,2,6,,,2t,3,2,4,,5,77,9,,2,6t,,a,2,,,4,,40,4,2,2,4,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(e=>e?parseInt(e,36):1);for(let e=0,i=0;e>1;if(t=LQ[n])e=n+1;else return!0;if(e==i)return!1}}function NQ(t){return t>=127462&&t<=127487}const BQ=8205;function m5(t,e,i=!0,n=!0){return(i?FQ:g5)(t,e,n)}function FQ(t,e,i){if(e==t.length)return e;e&&HQ(t.charCodeAt(e))&&KQ(t.charCodeAt(e-1))&&e--;let n=mc(t,e);for(e+=JQ(n);e=0&&NQ(mc(t,s));)r++,s-=2;if(r%2==0)break;e+=2}else break}return e}function g5(t,e,i){for(;e>0;){let n=FQ(t,e-2,i);if(n=56320&&t<57344}function KQ(t){return t>=55296&&t<56320}function JQ(t){return t<65536?1:2}class le{lineAt(e){if(e<0||e>this.length)throw new RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw new RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,i,n){[e,i]=pO(this,e,i);let O=[];return this.decompose(0,e,O,2),n.length&&n.decompose(0,n.length,O,3),this.decompose(i,this.length,O,1),pi.from(O,this.length-(i-e)+n.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,i=this.length){[e,i]=pO(this,e,i);let n=[];return this.decompose(e,i,n,0),pi.from(n,i-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let i=this.scanIdentical(e,1),n=this.length-this.scanIdentical(e,-1),O=new xr(this),r=new xr(e);for(let s=i,o=i;;){if(O.next(s),r.next(s),s=0,O.lineBreak!=r.lineBreak||O.done!=r.done||O.value!=r.value)return!1;if(o+=O.value.length,O.done||o>=n)return!0}}iter(e=1){return new xr(this,e)}iterRange(e,i=this.length){return new tp(this,e,i)}iterLines(e,i){let n;if(e==null)n=this.iter();else{i==null&&(i=this.lines+1);let O=this.line(e).from;n=this.iterRange(O,Math.max(O,i==this.lines+1?this.length:i<=1?0:this.line(i-1).to))}return new ip(n)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(e.length==0)throw new RangeError("A document must have at least one line");return e.length==1&&!e[0]?le.empty:e.length<=32?new Ue(e):pi.from(Ue.split(e,[]))}}class Ue extends le{constructor(e,i=P5(e)){super(),this.text=e,this.length=i}get lines(){return this.text.length}get children(){return null}lineInner(e,i,n,O){for(let r=0;;r++){let s=this.text[r],o=O+s.length;if((i?n:o)>=e)return new S5(O,o,n,s);O=o+1,n++}}decompose(e,i,n,O){let r=e<=0&&i>=this.length?this:new Ue(ep(this.text,e,i),Math.min(i,this.length)-Math.max(0,e));if(O&1){let s=n.pop(),o=go(r.text,s.text.slice(),0,r.length);if(o.length<=32)n.push(new Ue(o,s.length+r.length));else{let a=o.length>>1;n.push(new Ue(o.slice(0,a)),new Ue(o.slice(a)))}}else n.push(r)}replace(e,i,n){if(!(n instanceof Ue))return super.replace(e,i,n);[e,i]=pO(this,e,i);let O=go(this.text,go(n.text,ep(this.text,0,e)),i),r=this.length+n.length-(i-e);return O.length<=32?new Ue(O,r):pi.from(Ue.split(O,[]),r)}sliceString(e,i=this.length,n=` +`){[e,i]=pO(this,e,i);let O="";for(let r=0,s=0;r<=i&&se&&s&&(O+=n),er&&(O+=o.slice(Math.max(0,e-r),i-r)),r=a+1}return O}flatten(e){for(let i of this.text)e.push(i)}scanIdentical(){return 0}static split(e,i){let n=[],O=-1;for(let r of e)n.push(r),O+=r.length+1,n.length==32&&(i.push(new Ue(n,O)),n=[],O=-1);return O>-1&&i.push(new Ue(n,O)),i}}class pi extends le{constructor(e,i){super(),this.children=e,this.length=i,this.lines=0;for(let n of e)this.lines+=n.lines}lineInner(e,i,n,O){for(let r=0;;r++){let s=this.children[r],o=O+s.length,a=n+s.lines-1;if((i?a:o)>=e)return s.lineInner(e,i,n,O);O=o+1,n=a+1}}decompose(e,i,n,O){for(let r=0,s=0;s<=i&&r=s){let l=O&((s<=e?1:0)|(a>=i?2:0));s>=e&&a<=i&&!l?n.push(o):o.decompose(e-s,i-s,n,l)}s=a+1}}replace(e,i,n){if([e,i]=pO(this,e,i),n.lines=r&&i<=o){let a=s.replace(e-r,i-r,n),l=this.lines-s.lines+a.lines;if(a.lines>4&&a.lines>l>>6){let c=this.children.slice();return c[O]=a,new pi(c,this.length-(i-e)+n.length)}return super.replace(r,o,a)}r=o+1}return super.replace(e,i,n)}sliceString(e,i=this.length,n=` +`){[e,i]=pO(this,e,i);let O="";for(let r=0,s=0;re&&r&&(O+=n),es&&(O+=o.sliceString(e-s,i-s,n)),s=a+1}return O}flatten(e){for(let i of this.children)i.flatten(e)}scanIdentical(e,i){if(!(e instanceof pi))return 0;let n=0,[O,r,s,o]=i>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;O+=i,r+=i){if(O==s||r==o)return n;let a=this.children[O],l=e.children[r];if(a!=l)return n+a.scanIdentical(l,i);n+=a.length+1}}static from(e,i=e.reduce((n,O)=>n+O.length+1,-1)){let n=0;for(let u of e)n+=u.lines;if(n<32){let u=[];for(let $ of e)$.flatten(u);return new Ue(u,i)}let O=Math.max(32,n>>5),r=O<<1,s=O>>1,o=[],a=0,l=-1,c=[];function h(u){let $;if(u.lines>r&&u instanceof pi)for(let Q of u.children)h(Q);else u.lines>s&&(a>s||!a)?(d(),o.push(u)):u instanceof Ue&&a&&($=c[c.length-1])instanceof Ue&&u.lines+$.lines<=32?(a+=u.lines,l+=u.length+1,c[c.length-1]=new Ue($.text.concat(u.text),$.length+1+u.length)):(a+u.lines>O&&d(),a+=u.lines,l+=u.length+1,c.push(u))}function d(){a!=0&&(o.push(c.length==1?c[0]:pi.from(c,l)),l=-1,a=c.length=0)}for(let u of e)h(u);return d(),o.length==1?o[0]:new pi(o,i)}}le.empty=new Ue([""],0);function P5(t){let e=-1;for(let i of t)e+=i.length+1;return e}function go(t,e,i=0,n=1e9){for(let O=0,r=0,s=!0;r=i&&(a>n&&(o=o.slice(0,n-O)),O0?1:(e instanceof Ue?e.text.length:e.children.length)<<1]}nextInner(e,i){for(this.done=this.lineBreak=!1;;){let n=this.nodes.length-1,O=this.nodes[n],r=this.offsets[n],s=r>>1,o=O instanceof Ue?O.text.length:O.children.length;if(s==(i>0?o:0)){if(n==0)return this.done=!0,this.value="",this;i>0&&this.offsets[n-1]++,this.nodes.pop(),this.offsets.pop()}else if((r&1)==(i>0?0:1)){if(this.offsets[n]+=i,e==0)return this.lineBreak=!0,this.value=` +`,this;e--}else if(O instanceof Ue){let a=O.text[s+(i<0?-1:0)];if(this.offsets[n]+=i,a.length>Math.max(0,e))return this.value=e==0?a:i>0?a.slice(e):a.slice(0,a.length-e),this;e-=a.length}else{let a=O.children[s+(i<0?-1:0)];e>a.length?(e-=a.length,this.offsets[n]+=i):(i<0&&this.offsets[n]--,this.nodes.push(a),this.offsets.push(i>0?1:(a instanceof Ue?a.text.length:a.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}}class tp{constructor(e,i,n){this.value="",this.done=!1,this.cursor=new xr(e,i>n?-1:1),this.pos=i>n?e.length:0,this.from=Math.min(i,n),this.to=Math.max(i,n)}nextInner(e,i){if(i<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,i<0?this.pos-this.to:this.from-this.pos);let n=i<0?this.pos-this.from:this.to-this.pos;e>n&&(e=n),n-=e;let{value:O}=this.cursor.next(e);return this.pos+=(O.length+e)*i,this.value=O.length<=n?O:i<0?O.slice(O.length-n):O.slice(0,n),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=""}}class ip{constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:i,lineBreak:n,value:O}=this.inner.next(e);return i&&this.afterBreak?(this.value="",this.afterBreak=!1):i?(this.done=!0,this.value=""):n?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=O,this.afterBreak=!1),this}get lineBreak(){return!1}}typeof Symbol<"u"&&(le.prototype[Symbol.iterator]=function(){return this.iter()},xr.prototype[Symbol.iterator]=tp.prototype[Symbol.iterator]=ip.prototype[Symbol.iterator]=function(){return this});let S5=class{constructor(e,i,n,O){this.from=e,this.to=i,this.number=n,this.text=O}get length(){return this.to-this.from}};function pO(t,e,i){return e=Math.max(0,Math.min(t.length,e)),[e,Math.max(e,Math.min(t.length,i))]}function Be(t,e,i=!0,n=!0){return m5(t,e,i,n)}function X5(t){return t>=56320&&t<57344}function b5(t){return t>=55296&&t<56320}function xt(t,e){let i=t.charCodeAt(e);if(!b5(i)||e+1==t.length)return i;let n=t.charCodeAt(e+1);return X5(n)?(i-55296<<10)+(n-56320)+65536:i}function gc(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode((t>>10)+55296,(t&1023)+56320))}function mi(t){return t<65536?1:2}const Pc=/\r\n?|\n/;var it=function(t){return t[t.Simple=0]="Simple",t[t.TrackDel=1]="TrackDel",t[t.TrackBefore=2]="TrackBefore",t[t.TrackAfter=3]="TrackAfter",t}(it||(it={}));class gi{constructor(e){this.sections=e}get length(){let e=0;for(let i=0;ie)return r+(e-O);r+=o}else{if(n!=it.Simple&&l>=e&&(n==it.TrackDel&&Oe||n==it.TrackBefore&&Oe))return null;if(l>e||l==e&&i<0&&!o)return e==O||i<0?r:r+a;r+=a}O=l}if(e>O)throw new RangeError(`Position ${e} is out of range for changeset of length ${O}`);return r}touchesRange(e,i=e){for(let n=0,O=0;n=0&&O<=i&&o>=e)return Oi?"cover":!0;O=o}return!1}toString(){let e="";for(let i=0;i=0?":"+O:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(i=>typeof i!="number"))throw new RangeError("Invalid JSON representation of ChangeDesc");return new gi(e)}static create(e){return new gi(e)}}class De extends gi{constructor(e,i){super(e),this.inserted=i}apply(e){if(this.length!=e.length)throw new RangeError("Applying change set to a document with the wrong length");return Sc(this,(i,n,O,r,s)=>e=e.replace(O,O+(n-i),s),!1),e}mapDesc(e,i=!1){return Xc(this,e,i,!0)}invert(e){let i=this.sections.slice(),n=[];for(let O=0,r=0;O=0){i[O]=o,i[O+1]=s;let a=O>>1;for(;n.length0&&dn(n,i,r.text),r.forward(c),o+=c}let l=e[s++];for(;o>1].toJSON()))}return e}static of(e,i,n){let O=[],r=[],s=0,o=null;function a(c=!1){if(!c&&!O.length)return;sd||h<0||d>i)throw new RangeError(`Invalid change range ${h} to ${d} (in doc of length ${i})`);let $=u?typeof u=="string"?le.of(u.split(n||Pc)):u:le.empty,Q=$.length;if(h==d&&Q==0)return;hs&&$t(O,h-s,-1),$t(O,d-h,Q),dn(r,O,$),s=d}}return l(e),a(!o),o}static empty(e){return new De(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw new RangeError("Invalid JSON representation of ChangeSet");let i=[],n=[];for(let O=0;Oo&&typeof s!="string"))throw new RangeError("Invalid JSON representation of ChangeSet");if(r.length==1)i.push(r[0],0);else{for(;n.length=0&&i<=0&&i==t[O+1]?t[O]+=e:O>=0&&e==0&&t[O]==0?t[O+1]+=i:n?(t[O]+=e,t[O+1]+=i):t.push(e,i)}function dn(t,e,i){if(i.length==0)return;let n=e.length-2>>1;if(n>1])),!(i||s==t.sections.length||t.sections[s+1]<0);)o=t.sections[s++],a=t.sections[s++];e(O,l,r,c,h),O=l,r=c}}}function Xc(t,e,i,n=!1){let O=[],r=n?[]:null,s=new Tr(t),o=new Tr(e);for(let a=-1;;){if(s.done&&o.len||o.done&&s.len)throw new Error("Mismatched change set lengths");if(s.ins==-1&&o.ins==-1){let l=Math.min(s.len,o.len);$t(O,l,-1),s.forward(l),o.forward(l)}else if(o.ins>=0&&(s.ins<0||a==s.i||s.off==0&&(o.len=0&&a=0){let l=0,c=s.len;for(;c;)if(o.ins==-1){let h=Math.min(c,o.len);l+=h,c-=h,o.forward(h)}else if(o.ins==0&&o.lena||s.ins>=0&&s.len>a)&&(o||n.length>l),r.forward2(a),s.forward(a)}}}}class Tr{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i>1;return i>=e.length?le.empty:e[i]}textBit(e){let{inserted:i}=this.set,n=this.i-2>>1;return n>=i.length&&!e?le.empty:i[n].slice(this.off,e==null?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){this.ins==-1?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}}class Vn{constructor(e,i,n){this.from=e,this.to=i,this.flags=n}get anchor(){return this.flags&32?this.to:this.from}get head(){return this.flags&32?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&8?-1:this.flags&16?1:0}get bidiLevel(){let e=this.flags&7;return e==7?null:e}get goalColumn(){let e=this.flags>>6;return e==16777215?void 0:e}map(e,i=-1){let n,O;return this.empty?n=O=e.mapPos(this.from,i):(n=e.mapPos(this.from,1),O=e.mapPos(this.to,-1)),n==this.from&&O==this.to?this:new Vn(n,O,this.flags)}extend(e,i=e,n=0){if(e<=this.anchor&&i>=this.anchor)return x.range(e,i,void 0,void 0,n);let O=Math.abs(e-this.anchor)>Math.abs(i-this.anchor)?e:i;return x.range(this.anchor,O,void 0,void 0,n)}eq(e,i=!1){return this.anchor==e.anchor&&this.head==e.head&&this.goalColumn==e.goalColumn&&(!i||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||typeof e.anchor!="number"||typeof e.head!="number")throw new RangeError("Invalid JSON representation for SelectionRange");return x.range(e.anchor,e.head)}static create(e,i,n){return new Vn(e,i,n)}}class x{constructor(e,i){this.ranges=e,this.mainIndex=i}map(e,i=-1){return e.empty?this:x.create(this.ranges.map(n=>n.map(e,i)),this.mainIndex)}eq(e,i=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let n=0;ne.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||typeof e.main!="number"||e.main>=e.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new x(e.ranges.map(i=>Vn.fromJSON(i)),e.main)}static single(e,i=e){return new x([x.range(e,i)],0)}static create(e,i=0){if(e.length==0)throw new RangeError("A selection needs at least one range");for(let n=0,O=0;OO.from-r.from),i=e.indexOf(n);for(let O=1;Or.head?x.range(a,o):x.range(o,a))}}return new x(e,i)}}function Op(t,e){for(let i of t.ranges)if(i.to>e)throw new RangeError("Selection points outside of document")}let bc=0;class Z{constructor(e,i,n,O,r){this.combine=e,this.compareInput=i,this.compare=n,this.isStatic=O,this.id=bc++,this.default=e([]),this.extensions=typeof r=="function"?r(this):r}get reader(){return this}static define(e={}){return new Z(e.combine||(i=>i),e.compareInput||((i,n)=>i===n),e.compare||(e.combine?(i,n)=>i===n:yc),!!e.static,e.enables)}of(e){return new Po([],this,0,e)}compute(e,i){if(this.isStatic)throw new Error("Can't compute a static facet");return new Po(e,this,1,i)}computeN(e,i){if(this.isStatic)throw new Error("Can't compute a static facet");return new Po(e,this,2,i)}from(e,i){return i||(i=n=>n),this.compute([e],n=>i(n.field(e)))}}function yc(t,e){return t==e||t.length==e.length&&t.every((i,n)=>i===e[n])}class Po{constructor(e,i,n,O){this.dependencies=e,this.facet=i,this.type=n,this.value=O,this.id=bc++}dynamicSlot(e){var i;let n=this.value,O=this.facet.compareInput,r=this.id,s=e[r]>>1,o=this.type==2,a=!1,l=!1,c=[];for(let h of this.dependencies)h=="doc"?a=!0:h=="selection"?l=!0:((i=e[h.id])!==null&&i!==void 0?i:1)&1||c.push(e[h.id]);return{create(h){return h.values[s]=n(h),1},update(h,d){if(a&&d.docChanged||l&&(d.docChanged||d.selection)||xc(h,c)){let u=n(h);if(o?!rp(u,h.values[s],O):!O(u,h.values[s]))return h.values[s]=u,1}return 0},reconfigure:(h,d)=>{let u,$=d.config.address[r];if($!=null){let Q=bo(d,$);if(this.dependencies.every(p=>p instanceof Z?d.facet(p)===h.facet(p):p instanceof nt?d.field(p,!1)==h.field(p,!1):!0)||(o?rp(u=n(h),Q,O):O(u=n(h),Q)))return h.values[s]=Q,0}else u=n(h);return h.values[s]=u,1}}}}function rp(t,e,i){if(t.length!=e.length)return!1;for(let n=0;nt[a.id]),O=i.map(a=>a.type),r=n.filter(a=>!(a&1)),s=t[e.id]>>1;function o(a){let l=[];for(let c=0;cn===O),e);return e.provide&&(i.provides=e.provide(i)),i}create(e){let i=e.facet(So).find(n=>n.field==this);return(i?.create||this.createF)(e)}slot(e){let i=e[this.id]>>1;return{create:n=>(n.values[i]=this.create(n),1),update:(n,O)=>{let r=n.values[i],s=this.updateF(r,O);return this.compareF(r,s)?0:(n.values[i]=s,1)},reconfigure:(n,O)=>{let r=n.facet(So),s=O.facet(So),o;return(o=r.find(a=>a.field==this))&&o!=s.find(a=>a.field==this)?(n.values[i]=o.create(n),1):O.config.address[this.id]!=null?(n.values[i]=O.field(this),0):(n.values[i]=this.create(n),1)}}}init(e){return[this,So.of({field:this,create:e})]}get extension(){return this}}const qn={lowest:4,low:3,default:2,high:1,highest:0};function wr(t){return e=>new sp(e,t)}const Gi={highest:wr(qn.highest),high:wr(qn.high),default:wr(qn.default),low:wr(qn.low),lowest:wr(qn.lowest)};class sp{constructor(e,i){this.inner=e,this.prec=i}}class vr{of(e){return new Tc(this,e)}reconfigure(e){return vr.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}}class Tc{constructor(e,i){this.compartment=e,this.inner=i}}class Xo{constructor(e,i,n,O,r,s){for(this.base=e,this.compartments=i,this.dynamicSlots=n,this.address=O,this.staticValues=r,this.facets=s,this.statusTemplate=[];this.statusTemplate.length>1]}static resolve(e,i,n){let O=[],r=Object.create(null),s=new Map;for(let d of x5(e,i,s))d instanceof nt?O.push(d):(r[d.facet.id]||(r[d.facet.id]=[])).push(d);let o=Object.create(null),a=[],l=[];for(let d of O)o[d.id]=l.length<<1,l.push(u=>d.slot(u));let c=n?.config.facets;for(let d in r){let u=r[d],$=u[0].facet,Q=c&&c[d]||[];if(u.every(p=>p.type==0))if(o[$.id]=a.length<<1|1,yc(Q,u))a.push(n.facet($));else{let p=$.combine(u.map(m=>m.value));a.push(n&&$.compare(p,n.facet($))?n.facet($):p)}else{for(let p of u)p.type==0?(o[p.id]=a.length<<1|1,a.push(p.value)):(o[p.id]=l.length<<1,l.push(m=>p.dynamicSlot(m)));o[$.id]=l.length<<1,l.push(p=>y5(p,$,u))}}let h=l.map(d=>d(o));return new Xo(e,s,h,o,a,r)}}function x5(t,e,i){let n=[[],[],[],[],[]],O=new Map;function r(s,o){let a=O.get(s);if(a!=null){if(a<=o)return;let l=n[a].indexOf(s);l>-1&&n[a].splice(l,1),s instanceof Tc&&i.delete(s.compartment)}if(O.set(s,o),Array.isArray(s))for(let l of s)r(l,o);else if(s instanceof Tc){if(i.has(s.compartment))throw new RangeError("Duplicate use of compartment in extensions");let l=e.get(s.compartment)||s.inner;i.set(s.compartment,l),r(l,o)}else if(s instanceof sp)r(s.inner,s.prec);else if(s instanceof nt)n[o].push(s),s.provides&&r(s.provides,o);else if(s instanceof Po)n[o].push(s),s.facet.extensions&&r(s.facet.extensions,qn.default);else{let l=s.extension;if(!l)throw new Error(`Unrecognized extension value in extension set (${s}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);r(l,o)}}return r(t,qn.default),n.reduce((s,o)=>s.concat(o))}function kr(t,e){if(e&1)return 2;let i=e>>1,n=t.status[i];if(n==4)throw new Error("Cyclic dependency between fields and/or facets");if(n&2)return n;t.status[i]=4;let O=t.computeSlot(t,t.config.dynamicSlots[i]);return t.status[i]=2|O}function bo(t,e){return e&1?t.config.staticValues[e>>1]:t.values[e>>1]}const op=Z.define(),wc=Z.define({combine:t=>t.some(e=>e),static:!0}),ap=Z.define({combine:t=>t.length?t[0]:void 0,static:!0}),lp=Z.define(),cp=Z.define(),hp=Z.define(),dp=Z.define({combine:t=>t.length?t[0]:!1});class Pi{constructor(e,i){this.type=e,this.value=i}static define(){return new T5}}class T5{of(e){return new Pi(this,e)}}class w5{constructor(e){this.map=e}of(e){return new K(this,e)}}class K{constructor(e,i){this.type=e,this.value=i}map(e){let i=this.type.map(this.value,e);return i===void 0?void 0:i==this.value?this:new K(this.type,i)}is(e){return this.type==e}static define(e={}){return new w5(e.map||(i=>i))}static mapEffects(e,i){if(!e.length)return e;let n=[];for(let O of e){let r=O.map(i);r&&n.push(r)}return n}}K.reconfigure=K.define(),K.appendConfig=K.define();class Ge{constructor(e,i,n,O,r,s){this.startState=e,this.changes=i,this.selection=n,this.effects=O,this.annotations=r,this.scrollIntoView=s,this._doc=null,this._state=null,n&&Op(n,i.newLength),r.some(o=>o.type==Ge.time)||(this.annotations=r.concat(Ge.time.of(Date.now())))}static create(e,i,n,O,r,s){return new Ge(e,i,n,O,r,s)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(e){for(let i of this.annotations)if(i.type==e)return i.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(e){let i=this.annotation(Ge.userEvent);return!!(i&&(i==e||i.length>e.length&&i.slice(0,e.length)==e&&i[e.length]=="."))}}Ge.time=Pi.define(),Ge.userEvent=Pi.define(),Ge.addToHistory=Pi.define(),Ge.remote=Pi.define();function v5(t,e){let i=[];for(let n=0,O=0;;){let r,s;if(n=t[n]))r=t[n++],s=t[n++];else if(O=0;O--){let r=n[O](t);r instanceof Ge?t=r:Array.isArray(r)&&r.length==1&&r[0]instanceof Ge?t=r[0]:t=fp(e,mO(r),!1)}return t}function _5(t){let e=t.startState,i=e.facet(hp),n=t;for(let O=i.length-1;O>=0;O--){let r=i[O](t);r&&Object.keys(r).length&&(n=up(n,vc(e,r,t.changes.newLength),!0))}return n==t?t:Ge.create(e,t.changes,t.selection,n.effects,n.annotations,n.scrollIntoView)}const R5=[];function mO(t){return t==null?R5:Array.isArray(t)?t:[t]}var ve=function(t){return t[t.Word=0]="Word",t[t.Space=1]="Space",t[t.Other=2]="Other",t}(ve||(ve={}));const Z5=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;let kc;try{kc=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch{}function Y5(t){if(kc)return kc.test(t);for(let e=0;e"€"&&(i.toUpperCase()!=i.toLowerCase()||Z5.test(i)))return!0}return!1}function z5(t){return e=>{if(!/\S/.test(e))return ve.Space;if(Y5(e))return ve.Word;for(let i=0;i-1)return ve.Word;return ve.Other}}class ae{constructor(e,i,n,O,r,s){this.config=e,this.doc=i,this.selection=n,this.values=O,this.status=e.statusTemplate.slice(),this.computeSlot=r,s&&(s._state=this);for(let o=0;oO.set(l,a)),i=null),O.set(o.value.compartment,o.value.extension)):o.is(K.reconfigure)?(i=null,n=o.value):o.is(K.appendConfig)&&(i=null,n=mO(n).concat(o.value));let r;i?r=e.startState.values.slice():(i=Xo.resolve(n,O,this),r=new ae(i,this.doc,this.selection,i.dynamicSlots.map(()=>null),(a,l)=>l.reconfigure(a,this),null).values);let s=e.startState.facet(wc)?e.newSelection:e.newSelection.asSingle();new ae(i,e.newDoc,s,r,(o,a)=>a.update(o,e),e)}replaceSelection(e){return typeof e=="string"&&(e=this.toText(e)),this.changeByRange(i=>({changes:{from:i.from,to:i.to,insert:e},range:x.cursor(i.from+e.length)}))}changeByRange(e){let i=this.selection,n=e(i.ranges[0]),O=this.changes(n.changes),r=[n.range],s=mO(n.effects);for(let o=1;os.spec.fromJSON(o,a)))}}return ae.create({doc:e.doc,selection:x.fromJSON(e.selection),extensions:i.extensions?O.concat([i.extensions]):O})}static create(e={}){let i=Xo.resolve(e.extensions||[],new Map),n=e.doc instanceof le?e.doc:le.of((e.doc||"").split(i.staticFacet(ae.lineSeparator)||Pc)),O=e.selection?e.selection instanceof x?e.selection:x.single(e.selection.anchor,e.selection.head):x.single(0);return Op(O,n.length),i.staticFacet(wc)||(O=O.asSingle()),new ae(i,n,O,i.dynamicSlots.map(()=>null),(r,s)=>s.create(r),null)}get tabSize(){return this.facet(ae.tabSize)}get lineBreak(){return this.facet(ae.lineSeparator)||` +`}get readOnly(){return this.facet(dp)}phrase(e,...i){for(let n of this.facet(ae.phrases))if(Object.prototype.hasOwnProperty.call(n,e)){e=n[e];break}return i.length&&(e=e.replace(/\$(\$|\d*)/g,(n,O)=>{if(O=="$")return"$";let r=+(O||1);return!r||r>i.length?n:i[r-1]})),e}languageDataAt(e,i,n=-1){let O=[];for(let r of this.facet(op))for(let s of r(this,i,n))Object.prototype.hasOwnProperty.call(s,e)&&O.push(s[e]);return O}charCategorizer(e){let i=this.languageDataAt("wordChars",e);return z5(i.length?i[0]:"")}wordAt(e){let{text:i,from:n,length:O}=this.doc.lineAt(e),r=this.charCategorizer(e),s=e-n,o=e-n;for(;s>0;){let a=Be(i,s,!1);if(r(i.slice(a,s))!=ve.Word)break;s=a}for(;ot.length?t[0]:4}),ae.lineSeparator=ap,ae.readOnly=dp,ae.phrases=Z.define({compare(t,e){let i=Object.keys(t),n=Object.keys(e);return i.length==n.length&&i.every(O=>t[O]==e[O])}}),ae.languageData=op,ae.changeFilter=lp,ae.transactionFilter=cp,ae.transactionExtender=hp,vr.reconfigure=K.define();function Si(t,e,i={}){let n={};for(let O of t)for(let r of Object.keys(O)){let s=O[r],o=n[r];if(o===void 0)n[r]=s;else if(!(o===s||s===void 0))if(Object.hasOwnProperty.call(i,r))n[r]=i[r](o,s);else throw new Error("Config merge conflict for field "+r)}for(let O in e)n[O]===void 0&&(n[O]=e[O]);return n}class un{eq(e){return this==e}range(e,i=e){return Rc.create(e,i,this)}}un.prototype.startSide=un.prototype.endSide=0,un.prototype.point=!1,un.prototype.mapMode=it.TrackDel;function _c(t,e){return t==e||t.constructor==e.constructor&&t.eq(e)}let Rc=class Jb{constructor(e,i,n){this.from=e,this.to=i,this.value=n}static create(e,i,n){return new Jb(e,i,n)}};function Zc(t,e){return t.from-e.from||t.value.startSide-e.value.startSide}class Yc{constructor(e,i,n,O){this.from=e,this.to=i,this.value=n,this.maxPoint=O}get length(){return this.to[this.to.length-1]}findIndex(e,i,n,O=0){let r=n?this.to:this.from;for(let s=O,o=r.length;;){if(s==o)return s;let a=s+o>>1,l=r[a]-e||(n?this.value[a].endSide:this.value[a].startSide)-i;if(a==s)return l>=0?s:o;l>=0?o=a:s=a+1}}between(e,i,n,O){for(let r=this.findIndex(i,-1e9,!0),s=this.findIndex(n,1e9,!1,r);ru||d==u&&l.startSide>0&&l.endSide<=0)continue;(u-d||l.endSide-l.startSide)<0||(s<0&&(s=d),l.point&&(o=Math.max(o,u-d)),n.push(l),O.push(d-s),r.push(u-s))}return{mapped:n.length?new Yc(O,r,n,o):null,pos:s}}}class re{constructor(e,i,n,O){this.chunkPos=e,this.chunk=i,this.nextLayer=n,this.maxPoint=O}static create(e,i,n,O){return new re(e,i,n,O)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let i of this.chunk)e+=i.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(e){let{add:i=[],sort:n=!1,filterFrom:O=0,filterTo:r=this.length}=e,s=e.filter;if(i.length==0&&!s)return this;if(n&&(i=i.slice().sort(Zc)),this.isEmpty)return i.length?re.of(i):this;let o=new Qp(this,null,-1).goto(0),a=0,l=[],c=new Ei;for(;o.value||a=0){let h=i[a++];c.addInner(h.from,h.to,h.value)||l.push(h)}else o.rangeIndex==1&&o.chunkIndexthis.chunkEnd(o.chunkIndex)||ro.to||r=r&&e<=r+s.length&&s.between(r,e-r,i-r,n)===!1)return}this.nextLayer.between(e,i,n)}}iter(e=0){return _r.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,i=0){return _r.from(e).goto(i)}static compare(e,i,n,O,r=-1){let s=e.filter(h=>h.maxPoint>0||!h.isEmpty&&h.maxPoint>=r),o=i.filter(h=>h.maxPoint>0||!h.isEmpty&&h.maxPoint>=r),a=$p(s,o,n),l=new Rr(s,a,r),c=new Rr(o,a,r);n.iterGaps((h,d,u)=>pp(l,h,c,d,u,O)),n.empty&&n.length==0&&pp(l,0,c,0,0,O)}static eq(e,i,n=0,O){O==null&&(O=999999999);let r=e.filter(c=>!c.isEmpty&&i.indexOf(c)<0),s=i.filter(c=>!c.isEmpty&&e.indexOf(c)<0);if(r.length!=s.length)return!1;if(!r.length)return!0;let o=$p(r,s),a=new Rr(r,o,0).goto(n),l=new Rr(s,o,0).goto(n);for(;;){if(a.to!=l.to||!Vc(a.active,l.active)||a.point&&(!l.point||!_c(a.point,l.point)))return!1;if(a.to>O)return!0;a.next(),l.next()}}static spans(e,i,n,O,r=-1){let s=new Rr(e,null,r).goto(i),o=i,a=s.openStart;for(;;){let l=Math.min(s.to,n);if(s.point){let c=s.activeForPoint(s.to),h=s.pointFromo&&(O.span(o,l,s.active,a),a=s.openEnd(l));if(s.to>n)return a+(s.point&&s.to>n?1:0);o=s.to,s.next()}}static of(e,i=!1){let n=new Ei;for(let O of e instanceof Rc?[e]:i?V5(e):e)n.add(O.from,O.to,O.value);return n.finish()}static join(e){if(!e.length)return re.empty;let i=e[e.length-1];for(let n=e.length-2;n>=0;n--)for(let O=e[n];O!=re.empty;O=O.nextLayer)i=new re(O.chunkPos,O.chunk,i,Math.max(O.maxPoint,i.maxPoint));return i}}re.empty=new re([],[],null,-1);function V5(t){if(t.length>1)for(let e=t[0],i=1;i0)return t.slice().sort(Zc);e=n}return t}re.empty.nextLayer=re.empty;class Ei{finishChunk(e){this.chunks.push(new Yc(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,i,n){this.addInner(e,i,n)||(this.nextLayer||(this.nextLayer=new Ei)).add(e,i,n)}addInner(e,i,n){let O=e-this.lastTo||n.startSide-this.last.endSide;if(O<=0&&(e-this.lastFrom||n.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return O<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(i-this.chunkStart),this.last=n,this.lastFrom=e,this.lastTo=i,this.value.push(n),n.point&&(this.maxPoint=Math.max(this.maxPoint,i-e)),!0)}addChunk(e,i){if((e-this.lastTo||i.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,i.maxPoint),this.chunks.push(i),this.chunkPos.push(e);let n=i.value.length-1;return this.last=i.value[n],this.lastFrom=i.from[n]+e,this.lastTo=i.to[n]+e,!0}finish(){return this.finishInner(re.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return e;let i=re.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,i}}function $p(t,e,i){let n=new Map;for(let r of t)for(let s=0;s=this.minPoint)break}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex=n&&O.push(new Qp(s,i,n,r));return O.length==1?O[0]:new _r(O)}get startSide(){return this.value?this.value.startSide:0}goto(e,i=-1e9){for(let n of this.heap)n.goto(e,i);for(let n=this.heap.length>>1;n>=0;n--)zc(this.heap,n);return this.next(),this}forward(e,i){for(let n of this.heap)n.forward(e,i);for(let n=this.heap.length>>1;n>=0;n--)zc(this.heap,n);(this.to-e||this.value.endSide-i)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),zc(this.heap,0)}}}function zc(t,e){for(let i=t[e];;){let n=(e<<1)+1;if(n>=t.length)break;let O=t[n];if(n+1=0&&(O=t[n+1],n++),i.compare(O)<0)break;t[n]=i,t[e]=O,e=n}}class Rr{constructor(e,i,n){this.minPoint=n,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=_r.from(e,i,n)}goto(e,i=-1e9){return this.cursor.goto(e,i),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=i,this.openStart=-1,this.next(),this}forward(e,i){for(;this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-i)<0;)this.removeActive(this.minActive);this.cursor.forward(e,i)}removeActive(e){yo(this.active,e),yo(this.activeTo,e),yo(this.activeRank,e),this.minActive=mp(this.active,this.activeTo)}addActive(e){let i=0,{value:n,to:O,rank:r}=this.cursor;for(;i0;)i++;xo(this.active,i,n),xo(this.activeTo,i,O),xo(this.activeRank,i,r),e&&xo(e,i,this.cursor.from),this.minActive=mp(this.active,this.activeTo)}next(){let e=this.to,i=this.point;this.point=null;let n=this.openStart<0?[]:null;for(;;){let O=this.minActive;if(O>-1&&(this.activeTo[O]-this.cursor.from||this.active[O].endSide-this.cursor.startSide)<0){if(this.activeTo[O]>e){this.to=this.activeTo[O],this.endSide=this.active[O].endSide;break}this.removeActive(O),n&&yo(n,O)}else if(this.cursor.value)if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let r=this.cursor.value;if(!r.point)this.addActive(n),this.cursor.next();else if(i&&this.cursor.to==this.to&&this.cursor.from=0&&n[O]=0&&!(this.activeRank[n]e||this.activeTo[n]==e&&this.active[n].endSide>=this.point.endSide)&&i.push(this.active[n]);return i.reverse()}openEnd(e){let i=0;for(let n=this.activeTo.length-1;n>=0&&this.activeTo[n]>e;n--)i++;return i}}function pp(t,e,i,n,O,r){t.goto(e),i.goto(n);let s=n+O,o=n,a=n-e,l=!!r.boundChange;for(let c=!1;;){let h=t.to+a-i.to,d=h||t.endSide-i.endSide,u=d<0?t.to+a:i.to,$=Math.min(u,s);if(t.point||i.point?(t.point&&i.point&&_c(t.point,i.point)&&Vc(t.activeForPoint(t.to),i.activeForPoint(i.to))||r.comparePoint(o,$,t.point,i.point),c=!1):(c&&r.boundChange(o),$>o&&!Vc(t.active,i.active)&&r.compareRange(o,$,t.active,i.active),l&&$s)break;o=u,d<=0&&t.next(),d>=0&&i.next()}}function Vc(t,e){if(t.length!=e.length)return!1;for(let i=0;i=e;n--)t[n+1]=t[n];t[e]=i}function mp(t,e){let i=-1,n=1e9;for(let O=0;O=e)return O;if(O==t.length)break;r+=t.charCodeAt(O)==9?i-r%i:1,O=Be(t,O)}return n===!0?-1:t.length}const Uc="ͼ",gp=typeof Symbol>"u"?"__"+Uc:Symbol.for(Uc),Wc=typeof Symbol>"u"?"__styleSet"+Math.floor(Math.random()*1e8):Symbol("styleSet"),Pp=typeof globalThis<"u"?globalThis:typeof window<"u"?window:{};class fn{constructor(e,i){this.rules=[];let{finish:n}=i||{};function O(s){return/^@/.test(s)?[s]:s.split(/,\s*/)}function r(s,o,a,l){let c=[],h=/^@(\w+)\b/.exec(s[0]),d=h&&h[1]=="keyframes";if(h&&o==null)return a.push(s[0]+";");for(let u in o){let $=o[u];if(/&/.test(u))r(u.split(/,\s*/).map(Q=>s.map(p=>Q.replace(/&/,p))).reduce((Q,p)=>Q.concat(p)),$,a);else if($&&typeof $=="object"){if(!h)throw new RangeError("The value of a property ("+u+") should be a primitive value.");r(O(u),$,c,d)}else $!=null&&c.push(u.replace(/_.*/,"").replace(/[A-Z]/g,Q=>"-"+Q.toLowerCase())+": "+$+";")}(c.length||d)&&a.push((n&&!h&&!l?s.map(n):s).join(", ")+" {"+c.join(" ")+"}")}for(let s in e)r(O(s),e[s],this.rules)}getRules(){return this.rules.join(` +`)}static newName(){let e=Pp[gp]||1;return Pp[gp]=e+1,Uc+e.toString(36)}static mount(e,i,n){let O=e[Wc],r=n&&n.nonce;O?r&&O.setNonce(r):O=new q5(e,r),O.mount(Array.isArray(i)?i:[i],e)}}let Sp=new Map;class q5{constructor(e,i){let n=e.ownerDocument||e,O=n.defaultView;if(!e.head&&e.adoptedStyleSheets&&O.CSSStyleSheet){let r=Sp.get(n);if(r)return e[Wc]=r;this.sheet=new O.CSSStyleSheet,Sp.set(n,this)}else this.styleTag=n.createElement("style"),i&&this.styleTag.setAttribute("nonce",i);this.modules=[],e[Wc]=this}mount(e,i){let n=this.sheet,O=0,r=0;for(let s=0;s-1&&(this.modules.splice(a,1),r--,a=-1),a==-1){if(this.modules.splice(r++,0,o),n)for(let l=0;l",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},U5=typeof navigator<"u"&&/Mac/.test(navigator.platform),W5=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),Ot=0;Ot<10;Ot++)$n[48+Ot]=$n[96+Ot]=String(Ot);for(var Ot=1;Ot<=24;Ot++)$n[Ot+111]="F"+Ot;for(var Ot=65;Ot<=90;Ot++)$n[Ot]=String.fromCharCode(Ot+32),Zr[Ot]=String.fromCharCode(Ot);for(var Cc in $n)Zr.hasOwnProperty(Cc)||(Zr[Cc]=$n[Cc]);function C5(t){var e=U5&&t.metaKey&&t.shiftKey&&!t.ctrlKey&&!t.altKey||W5&&t.shiftKey&&t.key&&t.key.length==1||t.key=="Unidentified",i=!e&&t.key||(t.shiftKey?Zr:$n)[t.keyCode]||t.key||"Unidentified";return i=="Esc"&&(i="Escape"),i=="Del"&&(i="Delete"),i=="Left"&&(i="ArrowLeft"),i=="Up"&&(i="ArrowUp"),i=="Right"&&(i="ArrowRight"),i=="Down"&&(i="ArrowDown"),i}function pe(){var t=arguments[0];typeof t=="string"&&(t=document.createElement(t));var e=1,i=arguments[1];if(i&&typeof i=="object"&&i.nodeType==null&&!Array.isArray(i)){for(var n in i)if(Object.prototype.hasOwnProperty.call(i,n)){var O=i[n];typeof O=="string"?t.setAttribute(n,O):O!=null&&(t[n]=O)}e++}for(;e2);var z={mac:Tp||/Mac/.test(Pt.platform),windows:/Win/.test(Pt.platform),linux:/Linux|X11/.test(Pt.platform),ie:To,ie_version:bp?jc.documentMode||6:Ec?+Ec[1]:Gc?+Gc[1]:0,gecko:yp,gecko_version:yp?+(/Firefox\/(\d+)/.exec(Pt.userAgent)||[0,0])[1]:0,chrome:!!Ic,chrome_version:Ic?+Ic[1]:0,ios:Tp,android:/Android\b/.test(Pt.userAgent),webkit:xp,webkit_version:xp?+(/\bAppleWebKit\/(\d+)/.exec(Pt.userAgent)||[0,0])[1]:0,safari:Ac,safari_version:Ac?+(/\bVersion\/(\d+(\.\d+)?)/.exec(Pt.userAgent)||[0,0])[1]:0,tabSize:jc.documentElement.style.tabSize!=null?"tab-size":"-moz-tab-size"};function Mc(t,e){for(let i in t)i=="class"&&e.class?e.class+=" "+t.class:i=="style"&&e.style?e.style+=";"+t.style:e[i]=t[i];return e}const wo=Object.create(null);function Dc(t,e,i){if(t==e)return!0;t||(t=wo),e||(e=wo);let n=Object.keys(t),O=Object.keys(e);if(n.length-0!=O.length-0)return!1;for(let r of n)if(r!=i&&(O.indexOf(r)==-1||t[r]!==e[r]))return!1;return!0}function j5(t,e){for(let i=t.attributes.length-1;i>=0;i--){let n=t.attributes[i].name;e[n]==null&&t.removeAttribute(n)}for(let i in e){let n=e[i];i=="style"?t.style.cssText=n:t.getAttribute(i)!=n&&t.setAttribute(i,n)}}function wp(t,e,i){let n=!1;if(e)for(let O in e)i&&O in i||(n=!0,O=="style"?t.style.cssText="":t.removeAttribute(O));if(i)for(let O in i)e&&e[O]==i[O]||(n=!0,O=="style"?t.style.cssText=i[O]:t.setAttribute(O,i[O]));return n}function G5(t){let e=Object.create(null);for(let i=0;i0?3e8:-4e8:i>0?1e8:-1e8,new Un(e,i,i,n,e.widget||null,!1)}static replace(e){let i=!!e.block,n,O;if(e.isBlockGap)n=-5e8,O=4e8;else{let{start:r,end:s}=vp(e,i);n=(r?i?-3e8:-1:5e8)-1,O=(s?i?2e8:1:-6e8)+1}return new Un(e,n,O,i,e.widget||null,!0)}static line(e){return new zr(e)}static set(e,i=!1){return re.of(e,i)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}}D.none=re.empty;class Yr extends D{constructor(e){let{start:i,end:n}=vp(e);super(i?-1:5e8,n?1:-6e8,null,e),this.tagName=e.tagName||"span",this.attrs=e.class&&e.attributes?Mc(e.attributes,{class:e.class}):e.class?{class:e.class}:e.attributes||wo}eq(e){return this==e||e instanceof Yr&&this.tagName==e.tagName&&Dc(this.attrs,e.attrs)}range(e,i=e){if(e>=i)throw new RangeError("Mark decorations may not be empty");return super.range(e,i)}}Yr.prototype.point=!1;class zr extends D{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof zr&&this.spec.class==e.spec.class&&Dc(this.spec.attributes,e.spec.attributes)}range(e,i=e){if(i!=e)throw new RangeError("Line decoration ranges must be zero-length");return super.range(e,i)}}zr.prototype.mapMode=it.TrackBefore,zr.prototype.point=!0;class Un extends D{constructor(e,i,n,O,r,s){super(i,n,r,e),this.block=O,this.isReplace=s,this.mapMode=O?i<=0?it.TrackBefore:it.TrackAfter:it.TrackDel}get type(){return this.startSide!=this.endSide?rt.WidgetRange:this.startSide<=0?rt.WidgetBefore:rt.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof Un&&E5(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,i=e){if(this.isReplace&&(e>i||e==i&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&i!=e)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(e,i)}}Un.prototype.point=!0;function vp(t,e=!1){let{inclusiveStart:i,inclusiveEnd:n}=t;return i==null&&(i=t.inclusive),n==null&&(n=t.inclusive),{start:i??e,end:n??e}}function E5(t,e){return t==e||!!(t&&e&&t.compare(e))}function gO(t,e,i,n=0){let O=i.length-1;O>=0&&i[O]+n>=t?i[O]=Math.max(i[O],e):i.push(t,e)}class Vr extends un{constructor(e,i,n){super(),this.tagName=e,this.attributes=i,this.rank=n}eq(e){return e==this||e instanceof Vr&&this.tagName==e.tagName&&Dc(this.attributes,e.attributes)}static create(e){return new Vr(e.tagName,e.attributes||wo,e.rank==null?50:Math.max(0,Math.min(e.rank,100)))}static set(e,i=!1){return re.of(e,i)}}Vr.prototype.startSide=Vr.prototype.endSide=-1;function qr(t){let e;return t.nodeType==11?e=t.getSelection?t:t.ownerDocument:e=t,e.getSelection()}function Lc(t,e){return e?t==e||t.contains(e.nodeType!=1?e.parentNode:e):!1}function Ur(t,e){if(!e.anchorNode)return!1;try{return Lc(t,e.anchorNode)}catch{return!1}}function vo(t){return t.nodeType==3?Cr(t,0,t.nodeValue.length).getClientRects():t.nodeType==1?t.getClientRects():[]}function Wr(t,e,i,n){return i?kp(t,e,i,n,-1)||kp(t,e,i,n,1):!1}function Qn(t){for(var e=0;;e++)if(t=t.previousSibling,!t)return e}function ko(t){return t.nodeType==1&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(t.nodeName)}function kp(t,e,i,n,O){for(;;){if(t==i&&e==n)return!0;if(e==(O<0?0:Ii(t))){if(t.nodeName=="DIV")return!1;let r=t.parentNode;if(!r||r.nodeType!=1)return!1;e=Qn(t)+(O<0?0:1),t=r}else if(t.nodeType==1){if(t=t.childNodes[e+(O<0?-1:0)],t.nodeType==1&&t.contentEditable=="false")return!1;e=O<0?Ii(t):0}else return!1}}function Ii(t){return t.nodeType==3?t.nodeValue.length:t.childNodes.length}function _o(t,e){let i=e?t.left:t.right;return{left:i,right:i,top:t.top,bottom:t.bottom}}function I5(t){let e=t.visualViewport;return e?{left:0,right:e.width,top:0,bottom:e.height}:{left:0,right:t.innerWidth,top:0,bottom:t.innerHeight}}function _p(t,e){let i=e.width/t.offsetWidth,n=e.height/t.offsetHeight;return(i>.995&&i<1.005||!isFinite(i)||Math.abs(e.width-t.offsetWidth)<1)&&(i=1),(n>.995&&n<1.005||!isFinite(n)||Math.abs(e.height-t.offsetHeight)<1)&&(n=1),{scaleX:i,scaleY:n}}function A5(t,e,i,n,O,r,s,o){let a=t.ownerDocument,l=a.defaultView||window;for(let c=t,h=!1;c&&!h;)if(c.nodeType==1){let d,u=c==a.body,$=1,Q=1;if(u)d=I5(l);else{if(/^(fixed|sticky)$/.test(getComputedStyle(c).position)&&(h=!0),c.scrollHeight<=c.clientHeight&&c.scrollWidth<=c.clientWidth){c=c.assignedSlot||c.parentNode;continue}let P=c.getBoundingClientRect();({scaleX:$,scaleY:Q}=_p(c,P)),d={left:P.left,right:P.left+c.clientWidth*$,top:P.top,bottom:P.top+c.clientHeight*Q}}let p=0,m=0;if(O=="nearest")e.top0&&e.bottom>d.bottom+m&&(m=e.bottom-d.bottom+s)):e.bottom>d.bottom-s&&(m=e.bottom-d.bottom+s,i<0&&e.top-m0&&e.right>d.right+p&&(p=e.right-d.right+r)):e.right>d.right-r&&(p=e.right-d.right+r,i<0&&e.leftd.bottom||e.leftd.right)&&(e={left:Math.max(e.left,d.left),right:Math.min(e.right,d.right),top:Math.max(e.top,d.top),bottom:Math.min(e.bottom,d.bottom)}),c=c.assignedSlot||c.parentNode}else if(c.nodeType==11)c=c.host;else break}function Rp(t,e=!0){let i=t.ownerDocument,n=null,O=null;for(let r=t.parentNode;r&&!(r==i.body||(!e||n)&&O);)if(r.nodeType==1)!O&&r.scrollHeight>r.clientHeight&&(O=r),e&&!n&&r.scrollWidth>r.clientWidth&&(n=r),r=r.assignedSlot||r.parentNode;else if(r.nodeType==11)r=r.host;else break;return{x:n,y:O}}class M5{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:i,focusNode:n}=e;this.set(i,Math.min(e.anchorOffset,i?Ii(i):0),n,Math.min(e.focusOffset,n?Ii(n):0))}set(e,i,n,O){this.anchorNode=e,this.anchorOffset=i,this.focusNode=n,this.focusOffset=O}}let Wn=null;z.safari&&z.safari_version>=26&&(Wn=!1);function Zp(t){if(t.setActive)return t.setActive();if(Wn)return t.focus(Wn);let e=[];for(let i=t;i&&(e.push(i,i.scrollTop,i.scrollLeft),i!=i.ownerDocument);i=i.parentNode);if(t.focus(Wn==null?{get preventScroll(){return Wn={preventScroll:!0},!0}}:void 0),!Wn){Wn=!1;for(let i=0;iMath.max(0,t.document.documentElement.scrollHeight-t.innerHeight-4):t.scrollTop>Math.max(1,t.scrollHeight-t.clientHeight-4)}function Vp(t,e){for(let i=t,n=e;;){if(i.nodeType==3&&n>0)return{node:i,offset:n};if(i.nodeType==1&&n>0){if(i.contentEditable=="false")return null;i=i.childNodes[n-1],n=Ii(i)}else if(i.parentNode&&!ko(i))n=Qn(i),i=i.parentNode;else return null}}function qp(t,e){for(let i=t,n=e;;){if(i.nodeType==3&&n=i){if(o.level==n)return s;(r<0||(O!=0?O<0?o.fromi:e[r].level>o.level))&&(r=s)}}if(r<0)throw new RangeError("Index out of range");return r}}function Cp(t,e){if(t.length!=e.length)return!1;for(let i=0;i=0;Q-=3)if(bi[Q+1]==-u){let p=bi[Q+2],m=p&2?O:p&4?p&1?r:O:0;m&&(Pe[h]=Pe[bi[Q]]=m),o=Q;break}}else{if(bi.length==189)break;bi[o++]=h,bi[o++]=d,bi[o++]=a}else if(($=Pe[h])==2||$==1){let Q=$==O;a=Q?0:1;for(let p=o-3;p>=0;p-=3){let m=bi[p+2];if(m&2)break;if(Q)bi[p+2]|=2;else{if(m&4)break;bi[p+2]|=4}}}}}function J5(t,e,i,n){for(let O=0,r=n;O<=i.length;O++){let s=O?i[O-1].to:t,o=Oa;)$==p&&($=i[--Q].from,p=Q?i[Q-1].to:t),Pe[--$]=u;a=c}else r=l,a++}}}function Fc(t,e,i,n,O,r,s){let o=n%2?2:1;if(n%2==O%2)for(let a=e,l=0;aa&&s.push(new yi(a,Q.from,u));let p=Q.direction==Cn!=!(u%2);Hc(t,p?n+1:n,O,Q.inner,Q.from,Q.to,s),a=Q.to}$=Q.to}else{if($==i||(c?Pe[$]!=o:Pe[$]==o))break;$++}d?Fc(t,a,$,n+1,O,d,s):a<$&&s.push(new yi(a,$,u)),a=$}else for(let a=i,l=r.length;a>e;){let c=!0,h=!1;if(!l||a>r[l-1].to){let Q=Pe[a-1];Q!=o&&(c=!1,h=Q==16)}let d=!c&&o==1?[]:null,u=c?n:n+1,$=a;e:for(;;)if(l&&$==r[l-1].to){if(h)break e;let Q=r[--l];if(!c)for(let p=Q.from,m=l;;){if(p==e)break e;if(m&&r[m-1].to==p)p=r[--m].from;else{if(Pe[p-1]==o)break e;break}}if(d)d.push(Q);else{Q.toPe.length;)Pe[Pe.length]=256;let n=[],O=e==Cn?0:1;return Hc(t,O,O,i,0,t.length,n),n}function jp(t){return[new yi(0,t,0)]}let Gp="";function tk(t,e,i,n,O){var r;let s=n.head-t.from,o=yi.find(e,s,(r=n.bidiLevel)!==null&&r!==void 0?r:-1,n.assoc),a=e[o],l=a.side(O,i);if(s==l){let d=o+=O?1:-1;if(d<0||d>=e.length)return null;a=e[o=d],s=a.side(!O,i),l=a.side(O,i)}let c=Be(t.text,s,a.forward(O,i));(ca.to)&&(c=l),Gp=t.text.slice(Math.min(s,c),Math.max(s,c));let h=o==(O?e.length-1:0)?null:e[o+(O?1:-1)];return h&&c==l&&h.level+(O?0:1)t.some(e=>e)}),Bp=Z.define({combine:t=>t.some(e=>e)}),Fp=Z.define();class SO{constructor(e,i,n,O,r,s=!1){this.range=e,this.y=i,this.x=n,this.yMargin=O,this.xMargin=r,this.isSnapshot=s}map(e){return e.empty?this:new SO(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new SO(x.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}}const Ro=K.define({map:(t,e)=>t.map(e)}),Hp=K.define();function Tt(t,e,i){let n=t.facet(Mp);n.length?n[0](e):window.onerror&&window.onerror(String(e),i,void 0,void 0,e)||(i?console.error(i+":",e):console.error(e))}const Ai=Z.define({combine:t=>t.length?t[0]:!0});let nk=0;const XO=Z.define({combine(t){return t.filter((e,i)=>{for(let n=0;n{let a=[];return s&&a.push(Zo.of(l=>{let c=l.plugin(o);return c?s(c):D.none})),r&&a.push(r(o)),a})}static fromClass(e,i){return We.define((n,O)=>new e(n,O),i)}}class th{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}get plugin(){return this.spec&&this.spec.plugin}update(e){if(this.value){if(this.mustUpdate){let i=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(i)}catch(n){if(Tt(i.state,n,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch{}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.plugin.create(e,this.spec.arg)}catch(i){Tt(e.state,i,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var i;if(!((i=this.value)===null||i===void 0)&&i.destroy)try{this.value.destroy()}catch(n){Tt(e.state,n,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}}const Kp=Z.define(),ih=Z.define(),Zo=Z.define(),Jp=Z.define(),nh=Z.define(),jr=Z.define(),em=Z.define();function tm(t,e){let i=t.state.facet(em);if(!i.length)return i;let n=i.map(r=>r instanceof Function?r(t):r),O=[];return re.spans(n,e.from,e.to,{point(){},span(r,s,o,a){let l=r-e.from,c=s-e.from,h=O;for(let d=o.length-1;d>=0;d--,a--){let u=o[d].spec.bidiIsolate,$;if(u==null&&(u=ik(e.text,l,c)),a>0&&h.length&&($=h[h.length-1]).to==l&&$.direction==u)$.to=c,h=$.inner;else{let Q={from:l,to:c,direction:u,inner:[]};h.push(Q),h=Q.inner}}}}),O}const im=Z.define();function Oh(t){let e=0,i=0,n=0,O=0;for(let r of t.state.facet(im)){let s=r(t);s&&(s.left!=null&&(e=Math.max(e,s.left)),s.right!=null&&(i=Math.max(i,s.right)),s.top!=null&&(n=Math.max(n,s.top)),s.bottom!=null&&(O=Math.max(O,s.bottom)))}return{left:e,right:i,top:n,bottom:O}}const Gr=Z.define();class Lt{constructor(e,i,n,O){this.fromA=e,this.toA=i,this.fromB=n,this.toB=O}join(e){return new Lt(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let i=e.length,n=this;for(;i>0;i--){let O=e[i-1];if(!(O.fromA>n.toA)){if(O.toAO.push(new Lt(r,s,o,a))),this.changedRanges=O}static create(e,i,n){return new Yo(e,i,n)}get viewportChanged(){return(this.flags&4)>0}get viewportMoved(){return(this.flags&8)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&18)>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return this.flags==0&&this.transactions.length==0}}const Ok=[];class Ze{constructor(e,i,n=0){this.dom=e,this.length=i,this.flags=n,this.parent=null,e.cmTile=this}get breakAfter(){return this.flags&1}get children(){return Ok}isWidget(){return!1}get isHidden(){return!1}isComposite(){return!1}isLine(){return!1}isText(){return!1}isBlock(){return!1}get domAttrs(){return null}sync(e){if(this.flags|=2,this.flags&4){this.flags&=-5;let i=this.domAttrs;i&&j5(this.dom,i)}}toString(){return this.constructor.name+(this.children.length?`(${this.children})`:"")+(this.breakAfter?"#":"")}destroy(){this.parent=null}setDOM(e){this.dom=e,e.cmTile=this}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e,i=this.posAtStart){let n=i;for(let O of this.children){if(O==e)return n;n+=O.length+O.breakAfter}throw new RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}covers(e){return!0}coordsIn(e,i){return null}domPosFor(e,i){let n=Qn(this.dom),O=this.length?e>0:i>0;return new ri(this.parent.dom,n+(O?1:0),e==0||e==this.length)}markDirty(e){this.flags&=-3,e&&(this.flags|=4),this.parent&&this.parent.flags&2&&this.parent.markDirty(!1)}get overrideDOMText(){return null}get root(){for(let e=this;e;e=e.parent)if(e instanceof Vo)return e;return null}static get(e){return e.cmTile}}class zo extends Ze{constructor(e){super(e,0),this._children=[]}isComposite(){return!0}get children(){return this._children}get lastChild(){return this.children.length?this.children[this.children.length-1]:null}append(e){this.children.push(e),e.parent=this}sync(e){if(this.flags&2)return;super.sync(e);let i=this.dom,n=null,O,r=e?.node==i?e:null,s=0;for(let o of this.children){if(o.sync(e),s+=o.length+o.breakAfter,O=n?n.nextSibling:i.firstChild,r&&O!=o.dom&&(r.written=!0),o.dom.parentNode==i)for(;O&&O!=o.dom;)O=nm(O);else i.insertBefore(o.dom,O);n=o.dom}for(O=n?n.nextSibling:i.firstChild,r&&O&&(r.written=!0);O;)O=nm(O);this.length=s}}function nm(t){let e=t.nextSibling;return t.parentNode.removeChild(t),e}class Vo extends zo{constructor(e,i){super(i),this.view=e}owns(e){for(;e;e=e.parent)if(e==this)return!0;return!1}isBlock(){return!0}nearest(e){for(;;){if(!e)return null;let i=Ze.get(e);if(i&&this.owns(i))return i;e=e.parentNode}}blockTiles(e){for(let i=[],n=this,O=0,r=0;;)if(O==n.children.length){if(!i.length)return;n=n.parent,n.breakAfter&&r++,O=i.pop()}else{let s=n.children[O++];if(s instanceof Mi)i.push(O),n=s,O=0;else{let o=r+s.length,a=e(s,r);if(a!==void 0)return a;r=o+s.breakAfter}}}resolveBlock(e,i){let n,O=-1,r,s=-1;if(this.blockTiles((o,a)=>{let l=a+o.length;if(e>=a&&e<=l){if(o.isWidget()&&i>=-1&&i<=1){if(o.flags&32)return!0;o.flags&16&&(n=void 0)}(ae||e==a&&(i>1?o.length:o.covers(-1)))&&(!r||!o.isWidget()&&r.isWidget())&&(r=o,s=e-a)}}),!n&&!r)throw new Error("No tile at position "+e);return n&&i<0||!r?{tile:n,offset:O}:{tile:r,offset:s}}}class Mi extends zo{constructor(e,i){super(e),this.wrapper=i}isBlock(){return!0}covers(e){return this.children.length?e<0?this.children[0].covers(-1):this.lastChild.covers(1):!1}get domAttrs(){return this.wrapper.attributes}static of(e,i){let n=new Mi(i||document.createElement(e.tagName),e);return i||(n.flags|=4),n}}class bO extends zo{constructor(e,i){super(e),this.attrs=i}isLine(){return!0}static start(e,i,n){let O=new bO(i||document.createElement("div"),e);return(!i||!n)&&(O.flags|=4),O}get domAttrs(){return this.attrs}resolveInline(e,i,n){let O=null,r=-1,s=null,o=-1;function a(c,h){for(let d=0,u=0;d=h&&($.isComposite()?a($,h-u):(!s||s.isHidden&&(i>0||n&&sk(s,$)))&&(Q>h||$.flags&32)?(s=$,o=h-u):(un&&(e=n);let O=e,r=e,s=0;e==0&&i<0||e==n&&i>=0?z.chrome||z.gecko||(e?(O--,s=1):r=0)?0:o.length-1];return z.safari&&!s&&a.width==0&&(a=Array.prototype.find.call(o,l=>l.width)||a),s?_o(a,s<0):a||null}static of(e,i){let n=new jn(i||document.createTextNode(e),e);return i||(n.flags|=2),n}}class Gn extends Ze{constructor(e,i,n,O){super(e,i,O),this.widget=n}isWidget(){return!0}get isHidden(){return this.widget.isHidden}covers(e){return this.flags&48?!1:(this.flags&(e<0?64:128))>0}coordsIn(e,i){return this.coordsInWidget(e,i,!1)}coordsInWidget(e,i,n){let O=this.widget.coordsAt(this.dom,e,i);if(O)return O;if(n)return _o(this.dom.getBoundingClientRect(),this.length?e==0:i<=0);{let r=this.dom.getClientRects(),s=null;if(!r.length)return null;let o=this.flags&16?!0:this.flags&32?!1:e>0;for(let a=o?r.length-1:0;s=r[a],!(e>0?a==0:a==r.length-1||s.top0;)if(O.isComposite())if(s){if(!e)break;n&&n.break(),e--,s=!1}else if(r==O.children.length){if(!e&&!o.length)break;n&&n.leave(O),s=!!O.breakAfter,{tile:O,index:r}=o.pop(),r++}else{let a=O.children[r],l=a.breakAfter;(i>0?a.length<=e:a.length=0;o--){let a=i.marks[o],l=O.lastChild;if(l instanceof wt&&l.mark.eq(a.mark))l.dom!=a.dom&&l.setDOM(rh(a.dom)),O=l;else{if(this.cache.reused.get(a)){let h=Ze.get(a.dom);h&&h.setDOM(rh(a.dom))}let c=wt.of(a.mark,a.dom);O.append(c),O=c}this.cache.reused.set(a,2)}let r=Ze.get(e.text);r&&this.cache.reused.set(r,2);let s=new jn(e.text,e.text.nodeValue);s.flags|=8,this.pos=e.range.toB,O.append(s)}addInlineWidget(e,i,n){let O=this.afterWidget&&e.flags&48&&(this.afterWidget.flags&48)==(e.flags&48);O||this.flushBuffer();let r=this.ensureMarks(i,n);!O&&!(e.flags&16)&&r.append(this.getBuffer(1)),r.append(e),this.pos+=e.length,this.afterWidget=e}addMark(e,i,n){this.flushBuffer(),this.ensureMarks(i,n).append(e),this.pos+=e.length,this.afterWidget=null}addBlockWidget(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}continueWidget(e){let i=this.afterWidget||this.lastBlock;i.length+=e,this.pos+=e}addLineStart(e,i){var n;e||(e=rm);let O=bO.start(e,i||((n=this.cache.find(bO))===null||n===void 0?void 0:n.dom),!!i);this.getBlockPos().append(this.lastBlock=this.curLine=O)}addLine(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}addBreak(){this.lastBlock.flags|=1,this.endLine(),this.pos++}addLineStartIfNotCovered(e){this.blockPosCovered()||this.addLineStart(e)}ensureLine(e){this.curLine||this.addLineStart(e)}ensureMarks(e,i){var n;let O=this.curLine;for(let r=e.length-1;r>=0;r--){let s=e[r],o;if(i>0&&(o=O.lastChild)&&o instanceof wt&&o.mark.eq(s))O=o,i--;else{let a=wt.of(s,(n=this.cache.find(wt,l=>l.mark.eq(s)))===null||n===void 0?void 0:n.dom);O.append(a),O=a,i=0}}return O}endLine(){if(this.curLine){this.flushBuffer();let e=this.curLine.lastChild;(!e||!Om(this.curLine,!1)||e.dom.nodeName!="BR"&&e.isWidget()&&!(z.ios&&Om(this.curLine,!0)))&&this.curLine.append(this.cache.findWidget(sh,0,32)||new Gn(sh.toDOM(),0,sh,32)),this.curLine=this.afterWidget=null}}updateBlockWrappers(){this.wrapperPos>this.pos+1e4&&(this.blockWrappers.goto(this.pos),this.wrappers.length=0);for(let e=this.wrappers.length-1;e>=0;e--)this.wrappers[e].to=this.pos){let i=e.rank*102+e.value.rank,n=new ak(e.from,e.to,e.value,i),O=this.wrappers.length;for(;O>0&&(this.wrappers[O-1].rank-n.rank||this.wrappers[O-1].to-n.to)<0;)O--;this.wrappers.splice(O,0,n)}this.wrapperPos=this.pos}getBlockPos(){var e;this.updateBlockWrappers();let i=this.root;for(let n of this.wrappers){let O=i.lastChild;if(n.froms.wrapper.eq(n.wrapper)))===null||e===void 0?void 0:e.dom);i.append(r),i=r}}return i}blockPosCovered(){let e=this.lastBlock;return e!=null&&!e.breakAfter&&(!e.isWidget()||(e.flags&160)>0)}getBuffer(e){let i=2|(e<0?16:32),n=this.cache.find(qo,void 0,1);return n&&(n.flags=i),n||new qo(i)}flushBuffer(){this.afterWidget&&!(this.afterWidget.flags&32)&&(this.afterWidget.parent.append(this.getBuffer(-1)),this.afterWidget=null)}}class ck{constructor(e){this.skipCount=0,this.text="",this.textOff=0,this.cursor=e.iter()}skip(e){this.textOff+e<=this.text.length?this.textOff+=e:(this.skipCount+=e-(this.text.length-this.textOff),this.text="",this.textOff=0)}next(e){if(this.textOff==this.text.length){let{value:O,lineBreak:r,done:s}=this.cursor.next(this.skipCount);if(this.skipCount=0,s)throw new Error("Ran out of text content when drawing inline views");this.text=O;let o=this.textOff=Math.min(e,O.length);return r?null:O.slice(0,o)}let i=Math.min(this.text.length,this.textOff+e),n=this.text.slice(this.textOff,i);return this.textOff=i,n}}const Uo=[Gn,bO,jn,wt,qo,Mi,Vo];for(let t=0;t[]),this.index=Uo.map(()=>0),this.reused=new Map}add(e){let i=e.constructor.bucket,n=this.buckets[i];n.length<6?n.push(e):n[this.index[i]=(this.index[i]+1)%6]=e}find(e,i,n=2){let O=e.bucket,r=this.buckets[O],s=this.index[O];for(let o=r.length-1;o>=0;o--){let a=(o+s)%r.length,l=r[a];if((!i||i(l))&&!this.reused.has(l))return r.splice(a,1),a{if(this.cache.add(s),s.isComposite())return!1},enter:s=>this.cache.add(s),leave:()=>{},break:()=>{}}}run(e,i){let n=i&&this.getCompositionContext(i.text);for(let O=0,r=0,s=0;;){let o=sO){let l=a-O;this.preserve(l,!s,!o),O=a,r+=l}if(!o)break;i&&o.fromA<=i.range.fromA&&o.toA>=i.range.toA?(this.forward(o.fromA,i.range.fromA,i.range.fromA{if(s.isWidget())if(this.openWidget)this.builder.continueWidget(a-o);else{let l=a>0||o{s.isLine()?this.builder.addLineStart(s.attrs,this.cache.maybeReuse(s)):(this.cache.add(s),s instanceof wt&&O.unshift(s.mark)),this.openWidget=!1},leave:s=>{s.isLine()?O.length&&(O.length=r=0):s instanceof wt&&(O.shift(),r=Math.min(r,O.length))},break:()=>{this.builder.addBreak(),this.openWidget=!1}}),this.text.skip(e)}emit(e,i){let n=null,O=this.builder,r=0,s=re.spans(this.decorations,e,i,{point:(o,a,l,c,h,d)=>{if(l instanceof Un){if(this.disallowBlockEffectsFor[d]){if(l.block)throw new RangeError("Block decorations may not be specified via plugins");if(a>this.view.state.doc.lineAt(o).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}if(r=c.length,h>c.length)O.continueWidget(a-o);else{let u=l.widget||(l.block?yO.block:yO.inline),$=uk(l),Q=this.cache.findWidget(u,a-o,$)||Gn.of(u,this.view,a-o,$);l.block?(l.startSide>0&&O.addLineStartIfNotCovered(n),O.addBlockWidget(Q)):(O.ensureLine(n),O.addInlineWidget(Q,c,h))}n=null}else n=fk(n,l);a>o&&this.text.skip(a-o)},span:(o,a,l,c)=>{for(let h=o;hr,this.openMarks=s}forward(e,i,n=1){i-e<=10?this.old.advance(i-e,n,this.reuseWalker):(this.old.advance(5,-1,this.reuseWalker),this.old.advance(i-e-10,-1),this.old.advance(5,n,this.reuseWalker))}getCompositionContext(e){let i=[],n=null;for(let O=e.parentNode;;O=O.parentNode){let r=Ze.get(O);if(O==this.view.contentDOM)break;r instanceof wt?i.push(r):r?.isLine()?n=r:r instanceof Mi||(O.nodeName=="DIV"&&!n&&O!=this.view.contentDOM?n=new bO(O,rm):n||i.push(wt.of(new Yr({tagName:O.nodeName.toLowerCase(),attributes:G5(O)}),O)))}return{line:n,marks:i}}}function Om(t,e){let i=n=>{for(let O of n.children)if((e?O.isText():O.length)||i(O))return!0;return!1};return i(t)}function uk(t){let e=t.isReplace?(t.startSide<0?64:0)|(t.endSide>0?128:0):t.startSide>0?32:16;return t.block&&(e|=256),e}const rm={class:"cm-line"};function fk(t,e){let i=e.spec.attributes,n=e.spec.class;return!i&&!n||(t||(t={class:"cm-line"}),i&&Mc(i,t),n&&(t.class+=" "+n)),t}function $k(t){let e=[];for(let i=t.parents.length;i>1;i--){let n=i==t.parents.length?t.tile:t.parents[i].tile;n instanceof wt&&e.push(n.mark)}return e}function rh(t){let e=Ze.get(t);return e&&e.setDOM(t.cloneNode()),t}class yO extends Xi{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}yO.inline=new yO("span"),yO.block=new yO("div");const sh=new class extends Xi{toDOM(){return document.createElement("br")}get isHidden(){return!0}get editable(){return!0}};class sm{constructor(e){this.view=e,this.decorations=[],this.blockWrappers=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.editContextFormatting=D.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.updateDeco(),this.tile=new Vo(e,e.contentDOM),this.updateInner([new Lt(0,0,0,e.state.doc.length)],null)}update(e){var i;let n=e.changedRanges;this.minWidth>0&&n.length&&(n.every(({fromA:c,toA:h})=>hthis.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let O=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&(!((i=this.domChanged)===null||i===void 0)&&i.newSel?O=this.domChanged.newSel.head:!yk(e.changes,this.hasComposition)&&!e.selectionSet&&(O=e.state.selection.main.head));let r=O>-1?pk(this.view,e.changes,O):null;if(this.domChanged=null,this.hasComposition){let{from:c,to:h}=this.hasComposition;n=new Lt(c,h,e.changes.mapPos(c,-1),e.changes.mapPos(h,1)).addToSet(n.slice())}this.hasComposition=r?{from:r.range.fromB,to:r.range.toB}:null,(z.ie||z.chrome)&&!r&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let s=this.decorations,o=this.blockWrappers;this.updateDeco();let a=Pk(s,this.decorations,e.changes);a.length&&(n=Lt.extendWithRanges(n,a));let l=Xk(o,this.blockWrappers,e.changes);return l.length&&(n=Lt.extendWithRanges(n,l)),r&&!n.some(c=>c.fromA<=r.range.fromA&&c.toA>=r.range.toA)&&(n=r.range.addToSet(n.slice())),this.tile.flags&2&&n.length==0?!1:(this.updateInner(n,r),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,i){this.view.viewState.mustMeasureContent=!0;let{observer:n}=this.view;n.ignore(()=>{if(i||e.length){let s=this.tile,o=new dk(this.view,s,this.blockWrappers,this.decorations,this.dynamicDecorationMap);i&&Ze.get(i.text)&&o.cache.reused.set(Ze.get(i.text),2),this.tile=o.run(e,i),oh(s,o.cache.reused)}this.tile.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.tile.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let r=z.chrome||z.ios?{node:n.selectionRange.focusNode,written:!1}:void 0;this.tile.sync(r),r&&(r.written||n.selectionRange.focusNode!=r.node||!this.tile.dom.contains(r.node))&&(this.forceSelection=!0),this.tile.dom.style.height=""});let O=[];if(this.view.viewport.from||this.view.viewport.to-1)&&Ur(n,this.view.observer.selectionRange)&&!(O&&n.contains(O));if(!(r||i||s))return;let o=this.forceSelection;this.forceSelection=!1;let a=this.view.state.selection.main,l,c;if(a.empty?c=l=this.inlineDOMNearPos(a.anchor,a.assoc||1):(c=this.inlineDOMNearPos(a.head,a.head==a.from?1:-1),l=this.inlineDOMNearPos(a.anchor,a.anchor==a.from?1:-1)),z.gecko&&a.empty&&!this.hasComposition&&Qk(l)){let d=document.createTextNode("");this.view.observer.ignore(()=>l.node.insertBefore(d,l.node.childNodes[l.offset]||null)),l=c=new ri(d,0),o=!0}let h=this.view.observer.selectionRange;(o||!h.focusNode||(!Wr(l.node,l.offset,h.anchorNode,h.anchorOffset)||!Wr(c.node,c.offset,h.focusNode,h.focusOffset))&&!this.suppressWidgetCursorChange(h,a))&&(this.view.observer.ignore(()=>{z.android&&z.chrome&&n.contains(h.focusNode)&&bk(h.focusNode,n)&&(n.blur(),n.focus({preventScroll:!0}));let d=qr(this.view.root);if(d)if(a.empty){if(z.gecko){let u=mk(l.node,l.offset);if(u&&u!=3){let $=(u==1?Vp:qp)(l.node,l.offset);$&&(l=new ri($.node,$.offset))}}d.collapse(l.node,l.offset),a.bidiLevel!=null&&d.caretBidiLevel!==void 0&&(d.caretBidiLevel=a.bidiLevel)}else if(d.extend){d.collapse(l.node,l.offset);try{d.extend(c.node,c.offset)}catch{}}else{let u=document.createRange();a.anchor>a.head&&([l,c]=[c,l]),u.setEnd(c.node,c.offset),u.setStart(l.node,l.offset),d.removeAllRanges(),d.addRange(u)}s&&this.view.root.activeElement==n&&(n.blur(),O&&O.focus())}),this.view.observer.setSelectionRange(l,c)),this.impreciseAnchor=l.precise?null:new ri(h.anchorNode,h.anchorOffset),this.impreciseHead=c.precise?null:new ri(h.focusNode,h.focusOffset)}suppressWidgetCursorChange(e,i){return this.hasComposition&&i.empty&&Wr(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==i.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,i=e.state.selection.main,n=qr(e.root),{anchorNode:O,anchorOffset:r}=e.observer.selectionRange;if(!n||!i.empty||!i.assoc||!n.modify)return;let s=this.lineAt(i.head,i.assoc);if(!s)return;let o=s.posAtStart;if(i.head==o||i.head==o+s.length)return;let a=this.coordsAt(i.head,-1),l=this.coordsAt(i.head,1);if(!a||!l||a.bottom>l.top)return;let c=this.domAtPos(i.head+i.assoc,i.assoc);n.collapse(c.node,c.offset),n.modify("move",i.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let h=e.observer.selectionRange;e.docView.posFromDOM(h.anchorNode,h.anchorOffset)!=i.from&&n.collapse(O,r)}posFromDOM(e,i){let n=this.tile.nearest(e);if(!n)return this.tile.dom.compareDocumentPosition(e)&2?0:this.view.state.doc.length;let O=n.posAtStart;if(n.isComposite()){let r;if(e==n.dom)r=n.dom.childNodes[i];else{let s=Ii(e)==0?0:i==0?-1:1;for(;;){let o=e.parentNode;if(o==n.dom)break;s==0&&o.firstChild!=o.lastChild&&(e==o.firstChild?s=-1:s=1),e=o}s<0?r=e:r=e.nextSibling}if(r==n.dom.firstChild)return O;for(;r&&!Ze.get(r);)r=r.nextSibling;if(!r)return O+n.length;for(let s=0,o=O;;s++){let a=n.children[s];if(a.dom==r)return o;o+=a.length+a.breakAfter}}else return n.isText()?e==n.dom?O+i:O+(i?n.length:0):O}domAtPos(e,i){let{tile:n,offset:O}=this.tile.resolveBlock(e,i);return n.isWidget()?n.domPosFor(e,i):n.domIn(O,i)}inlineDOMNearPos(e,i){let n,O=-1,r=!1,s,o=-1,a=!1;return this.tile.blockTiles((l,c)=>{if(l.isWidget()){if(l.flags&32&&c>=e)return!0;l.flags&16&&(r=!0)}else{let h=c+l.length;if(c<=e&&(n=l,O=e-c,r=h=e&&!s&&(s=l,o=e-c,a=c>e),c>e&&s)return!0}}),!n&&!s?this.domAtPos(e,i):(r&&s?n=null:a&&n&&(s=null),n&&i<0||!s?n.domIn(O,i):s.domIn(o,i))}coordsAt(e,i){let{tile:n,offset:O}=this.tile.resolveBlock(e,i);return n.isWidget()?n.widget instanceof ah?null:n.coordsInWidget(O,i,!0):n.coordsIn(O,i)}lineAt(e,i){let{tile:n}=this.tile.resolveBlock(e,i);return n.isLine()?n:null}coordsForChar(e){let{tile:i,offset:n}=this.tile.resolveBlock(e,1);if(!i.isLine())return null;function O(r,s){if(r.isComposite())for(let o of r.children){if(o.length>=s){let a=O(o,s);if(a)return a}if(s-=o.length,s<0)break}else if(r.isText()&&sMath.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,o=-1,a=this.view.textDirection==ge.LTR,l=0,c=(h,d,u)=>{for(let $=0;$O);$++){let Q=h.children[$],p=d+Q.length,m=Q.dom.getBoundingClientRect(),{height:P}=m;if(u&&!$&&(l+=m.top-u.top),Q instanceof Mi)p>n&&c(Q,d,m);else if(d>=n&&(l>0&&i.push(-l),i.push(P+l),l=0,s)){let g=Q.dom.lastChild,b=g?vo(g):[];if(b.length){let X=b[b.length-1],y=a?X.right-m.left:m.right-X.left;y>o&&(o=y,this.minWidth=r,this.minWidthFrom=d,this.minWidthTo=p)}}u&&$==h.children.length-1&&(l+=u.bottom-m.bottom),d=p+Q.breakAfter}};return c(this.tile,0,null),i}textDirectionAt(e){let{tile:i}=this.tile.resolveBlock(e,1);return getComputedStyle(i.dom).direction=="rtl"?ge.RTL:ge.LTR}measureTextSize(){let e=this.tile.blockTiles(s=>{if(s.isLine()&&s.children.length&&s.length<=20){let o=0,a;for(let l of s.children){if(!l.isText()||/[^ -~]/.test(l.text))return;let c=vo(l.dom);if(c.length!=1)return;o+=c[0].width,a=c[0].height}if(o)return{lineHeight:s.dom.getBoundingClientRect().height,charWidth:o/s.length,textHeight:a}}});if(e)return e;let i=document.createElement("div"),n,O,r;return i.className="cm-line",i.style.width="99999px",i.style.position="absolute",i.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.tile.dom.appendChild(i);let s=vo(i.firstChild)[0];n=i.getBoundingClientRect().height,O=s&&s.width?s.width/27:7,r=s&&s.height?s.height:n,i.remove()}),{lineHeight:n,charWidth:O,textHeight:r}}computeBlockGapDeco(){let e=[],i=this.view.viewState;for(let n=0,O=0;;O++){let r=O==i.viewports.length?null:i.viewports[O],s=r?r.from-1:this.view.state.doc.length;if(s>n){let o=(i.lineBlockAt(s).bottom-i.lineBlockAt(n).top)/this.view.scaleY;e.push(D.replace({widget:new ah(o),block:!0,inclusive:!0,isBlockGap:!0}).range(n,s))}if(!r)break;n=r.to+1}return D.set(e)}updateDeco(){let e=1,i=this.view.state.facet(Zo).map(r=>(this.dynamicDecorationMap[e++]=typeof r=="function")?r(this.view):r),n=!1,O=this.view.state.facet(nh).map((r,s)=>{let o=typeof r=="function";return o&&(n=!0),o?r(this.view):r});for(O.length&&(this.dynamicDecorationMap[e++]=n,i.push(re.join(O))),this.decorations=[this.editContextFormatting,...i,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];etypeof r=="function"?r(this.view):r)}scrollIntoView(e){var i;if(e.isSnapshot){let c=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=c.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let c of this.view.state.facet(Fp))try{if(c(this.view,e.range,e))return!0}catch(h){Tt(this.view.state,h,"scroll handler")}let{range:n}=e,O=this.coordsAt(n.head,(i=n.assoc)!==null&&i!==void 0?i:n.empty?0:n.head>n.anchor?-1:1),r;if(!O)return;!n.empty&&(r=this.coordsAt(n.anchor,n.anchor>n.head?-1:1))&&(O={left:Math.min(O.left,r.left),top:Math.min(O.top,r.top),right:Math.max(O.right,r.right),bottom:Math.max(O.bottom,r.bottom)});let s=Oh(this.view),o={left:O.left-s.left,top:O.top-s.top,right:O.right+s.right,bottom:O.bottom+s.bottom},{offsetWidth:a,offsetHeight:l}=this.view.scrollDOM;if(A5(this.view.scrollDOM,o,n.head1&&(O.top>window.pageYOffset+window.visualViewport.offsetTop+window.visualViewport.height||O.bottomn.isWidget()||n.children.some(i);return i(this.tile.resolveBlock(e,1).tile)}destroy(){oh(this.tile)}}function oh(t,e){let i=e?.get(t);if(i!=1){i==null&&t.destroy();for(let n of t.children)oh(n,e)}}function Qk(t){return t.node.nodeType==1&&t.node.firstChild&&(t.offset==0||t.node.childNodes[t.offset-1].contentEditable=="false")&&(t.offset==t.node.childNodes.length||t.node.childNodes[t.offset].contentEditable=="false")}function om(t,e){let i=t.observer.selectionRange;if(!i.focusNode)return null;let n=Vp(i.focusNode,i.focusOffset),O=qp(i.focusNode,i.focusOffset),r=n||O;if(O&&n&&O.node!=n.node){let o=Ze.get(O.node);if(!o||o.isText()&&o.text!=O.node.nodeValue)r=O;else if(t.docView.lastCompositionAfterCursor){let a=Ze.get(n.node);!a||a.isText()&&a.text!=n.node.nodeValue||(r=O)}}if(t.docView.lastCompositionAfterCursor=r!=n,!r)return null;let s=e-r.offset;return{from:s,to:s+r.node.nodeValue.length,node:r.node}}function pk(t,e,i){let n=om(t,i);if(!n)return null;let{node:O,from:r,to:s}=n,o=O.nodeValue;if(/[\n\r]/.test(o)||t.state.doc.sliceString(n.from,n.to)!=o)return null;let a=e.invertedDesc;return{range:new Lt(a.mapPos(r),a.mapPos(s),r,s),text:O}}function mk(t,e){return t.nodeType!=1?0:(e&&t.childNodes[e-1].contentEditable=="false"?1:0)|(e{ne.from&&(i=!0)}),i}class ah extends Xi{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}}function xk(t,e,i=1){let n=t.charCategorizer(e),O=t.doc.lineAt(e),r=e-O.from;if(O.length==0)return x.cursor(e);r==0?i=1:r==O.length&&(i=-1);let s=r,o=r;i<0?s=Be(O.text,r,!1):o=Be(O.text,r);let a=n(O.text.slice(s,o));for(;s>0;){let l=Be(O.text,s,!1);if(n(O.text.slice(l,s))!=a)break;s=l}for(;ot.defaultLineHeight*1.5){let o=t.viewState.heightOracle.textHeight,a=Math.floor((O-i.top-(t.defaultLineHeight-o)*.5)/o);r+=a*t.viewState.heightOracle.lineLength}let s=t.state.sliceDoc(i.from,i.to);return i.from+qc(s,r,t.state.tabSize)}function lh(t,e,i){let n=t.lineBlockAt(e);if(Array.isArray(n.type)){let O;for(let r of n.type){if(r.from>e)break;if(!(r.toe)return r;(!O||r.type==rt.Text&&(O.type!=r.type||(i<0?r.frome)))&&(O=r)}}return O||n}return n}function wk(t,e,i,n){let O=lh(t,e.head,e.assoc||-1),r=!n||O.type!=rt.Text||!(t.lineWrapping||O.widgetLineBreaks)?null:t.coordsAtPos(e.assoc<0&&e.head>O.from?e.head-1:e.head);if(r){let s=t.dom.getBoundingClientRect(),o=t.textDirectionAt(O.from),a=t.posAtCoords({x:i==(o==ge.LTR)?s.right-1:s.left+1,y:(r.top+r.bottom)/2});if(a!=null)return x.cursor(a,i?-1:1)}return x.cursor(i?O.to:O.from,i?-1:1)}function am(t,e,i,n){let O=t.state.doc.lineAt(e.head),r=t.bidiSpans(O),s=t.textDirectionAt(O.from);for(let o=e,a=null;;){let l=tk(O,r,s,o,i),c=Gp;if(!l){if(O.number==(i?t.state.doc.lines:1))return o;c=` +`,O=t.state.doc.line(O.number+(i?1:-1)),r=t.bidiSpans(O),l=t.visualLineSide(O,!i)}if(a){if(!a(c))return o}else{if(!n)return l;a=n(c)}o=l}}function vk(t,e,i){let n=t.state.charCategorizer(e),O=n(i);return r=>{let s=n(r);return O==ve.Space&&(O=s),O==s}}function kk(t,e,i,n){let O=e.head,r=i?1:-1;if(O==(i?t.state.doc.length:0))return x.cursor(O,e.assoc);let s=e.goalColumn,o,a=t.contentDOM.getBoundingClientRect(),l=t.coordsAtPos(O,e.assoc||((e.empty?i:e.head==e.from)?1:-1)),c=t.documentTop;if(l)s==null&&(s=l.left-a.left),o=r<0?l.top:l.bottom;else{let $=t.viewState.lineBlockAt(O);s==null&&(s=Math.min(a.right-a.left,t.defaultCharacterWidth*(O-$.from))),o=(r<0?$.top:$.bottom)+c}let h=a.left+s,d=t.viewState.heightOracle.textHeight>>1,u=n??d;for(let $=0;;$+=d){let Q=o+(u+$)*r,p=hh(t,{x:h,y:Q},!1,r);if(i?Q>a.bottom:Qo:P{if(e>r&&eO(t)),i.from,e.head>i.from?-1:1);return n==i.from?i:x.cursor(n,nt.viewState.docHeight)return new xi(t.state.doc.length,-1);if(l=t.elementAtHeight(a),n==null)break;if(l.type==rt.Text){if(n<0?l.tot.viewport.to)break;let d=t.docView.coordsAt(n<0?l.from:l.to,n>0?-1:1);if(d&&(n<0?d.top<=a+r:d.bottom>=a+r))break}let h=t.viewState.heightOracle.textHeight/2;a=n>0?l.bottom+h:l.top-h}if(t.viewport.from>=l.to||t.viewport.to<=l.from){if(i)return null;if(l.type==rt.Text){let h=Tk(t,O,l,s,o);return new xi(h,h==l.from?1:-1)}}if(l.type!=rt.Text)return a<(l.top+l.bottom)/2?new xi(l.from,1):new xi(l.to,-1);let c=t.docView.lineAt(l.from,2);return(!c||c.length!=l.length)&&(c=t.docView.lineAt(l.from,-2)),new _k(t,s,o,t.textDirectionAt(l.from)).scanTile(c,l.from)}class _k{constructor(e,i,n,O){this.view=e,this.x=i,this.y=n,this.baseDir=O,this.line=null,this.spans=null}bidiSpansAt(e){return(!this.line||this.line.from>e||this.line.to1||n.length&&(n[0].level!=this.baseDir||n[0].to+O.from>1;t:if(s.has(Q)){let m=O+Math.floor(Math.random()*$);for(let P=0;P<$;P++){if(!s.has(m)){Q=m;break t}m++,m==r&&(m=O)}break e}s.add(Q);let p=i(Q);if(p)for(let m=0;m1)){if(P.bottomthis.y)(!l||l.top>P.top)&&(l=P),g=-1;else{let b=P.left>this.x?this.x-P.left:P.right($+$+Q)/3)return this.y=a.bottom-1,this.scan(e,i,!0);if(l&&l.top<($+Q+Q)/3)return this.y=l.top+1,this.scan(e,i,!0)}let u=(o?this.dirAt(e[c],1):this.baseDir)==ge.LTR;return{i:c,after:this.x>(d.left+d.right)/2==u}}scanText(e,i){let n=[];for(let r=0;r{let s=n[r]-i,o=n[r+1]-i;return Cr(e.dom,s,o).getClientRects()});return O.after?new xi(n[O.i+1],-1):new xi(n[O.i],1)}scanTile(e,i){if(!e.length)return new xi(i,1);if(e.children.length==1){let o=e.children[0];if(o.isText())return this.scanText(o,i);if(o.isComposite())return this.scanTile(o,i)}let n=[i];for(let o=0,a=i;o{let a=e.children[o];return a.flags&48?null:(a.dom.nodeType==1?a.dom:Cr(a.dom,0,a.length)).getClientRects()}),r=e.children[O.i],s=n[O.i];return r.isText()?this.scanText(r,s):r.isComposite()?this.scanTile(r,s):O.after?new xi(n[O.i+1],-1):new xi(s,1)}}const xO="￿";class Rk{constructor(e,i){this.points=e,this.view=i,this.text="",this.lineSeparator=i.state.facet(ae.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=xO}readRange(e,i){if(!e)return this;let n=e.parentNode;for(let O=e;;){this.findPointBefore(n,O);let r=this.text.length;this.readNode(O);let s=Ze.get(O),o=O.nextSibling;if(o==i){s?.breakAfter&&!o&&n!=this.view.contentDOM&&this.lineBreak();break}let a=Ze.get(o);(s&&a?s.breakAfter:(s?s.breakAfter:ko(O))||ko(o)&&(O.nodeName!="BR"||s?.isWidget())&&this.text.length>r)&&!Yk(o,i)&&this.lineBreak(),O=o}return this.findPointBefore(n,i),this}readTextNode(e){let i=e.nodeValue;for(let n of this.points)n.node==e&&(n.pos=this.text.length+Math.min(n.offset,i.length));for(let n=0,O=this.lineSeparator?null:/\r\n?|\n/g;;){let r=-1,s=1,o;if(this.lineSeparator?(r=i.indexOf(this.lineSeparator,n),s=this.lineSeparator.length):(o=O.exec(i))&&(r=o.index,s=o[0].length),this.append(i.slice(n,r<0?i.length:r)),r<0)break;if(this.lineBreak(),s>1)for(let a of this.points)a.node==e&&a.pos>this.text.length&&(a.pos-=s-1);n=r+s}}readNode(e){let i=Ze.get(e),n=i&&i.overrideDOMText;if(n!=null){this.findPointInside(e,n.length);for(let O=n.iter();!O.next().done;)O.lineBreak?this.lineBreak():this.append(O.value)}else e.nodeType==3?this.readTextNode(e):e.nodeName=="BR"?e.nextSibling&&this.lineBreak():e.nodeType==1&&this.readRange(e.firstChild,null)}findPointBefore(e,i){for(let n of this.points)n.node==e&&e.childNodes[n.offset]==i&&(n.pos=this.text.length)}findPointInside(e,i){for(let n of this.points)(e.nodeType==3?n.node==e:e.contains(n.node))&&(n.pos=this.text.length+(Zk(e,n.node,n.offset)?i:0))}}function Zk(t,e,i){for(;;){if(!e||i-1;let{impreciseHead:r,impreciseAnchor:s}=e.docView,o=e.state.selection;if(e.state.readOnly&&i>-1)this.newSel=null;else if(i>-1&&(this.bounds=hm(e.docView.tile,i,n,0))){let a=r||s?[]:qk(e),l=new Rk(a,e);l.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=l.text,this.newSel=Uk(a,this.bounds.from)}else{let a=e.observer.selectionRange,l=r&&r.node==a.focusNode&&r.offset==a.focusOffset||!Lc(e.contentDOM,a.focusNode)?o.main.head:e.docView.posFromDOM(a.focusNode,a.focusOffset),c=s&&s.node==a.anchorNode&&s.offset==a.anchorOffset||!Lc(e.contentDOM,a.anchorNode)?o.main.anchor:e.docView.posFromDOM(a.anchorNode,a.anchorOffset),h=e.viewport;if((z.ios||z.chrome)&&o.main.empty&&l!=c&&(h.from>0||h.to-1&&o.ranges.length>1)this.newSel=o.replaceRange(x.range(c,l));else if(e.lineWrapping&&c==l&&!(o.main.empty&&o.main.head==l)&&e.inputState.lastTouchTime>Date.now()-100){let d=e.coordsAtPos(l,-1),u=0;d&&(u=e.inputState.lastTouchY<=d.bottom?-1:1),this.newSel=x.create([x.cursor(l,u)])}else this.newSel=x.single(c,l)}}}function hm(t,e,i,n){if(t.isComposite()){let O=-1,r=-1,s=-1,o=-1;for(let a=0,l=n,c=n;ai)return hm(h,e,i,l);if(d>=e&&O==-1&&(O=a,r=l),l>i&&h.dom.parentNode==t.dom){s=a,o=c;break}c=d,l=d+h.breakAfter}return{from:r,to:o<0?n+t.length:o,startDOM:(O?t.children[O-1].dom.nextSibling:null)||t.dom.firstChild,endDOM:s=0?t.children[s].dom:null}}else return t.isText()?{from:n,to:n+t.length,startDOM:t.dom,endDOM:t.dom.nextSibling}:null}function dm(t,e){let i,{newSel:n}=e,{state:O}=t,r=O.selection.main,s=t.inputState.lastKeyTime>Date.now()-100?t.inputState.lastKeyCode:-1;if(e.bounds){let{from:o,to:a}=e.bounds,l=r.from,c=null;(s===8||z.android&&e.text.length=o&&r.to<=a&&(e.typeOver||h!=e.text)&&h.slice(0,r.from-o)==e.text.slice(0,r.from-o)&&h.slice(r.to-o)==e.text.slice(d=e.text.length-(h.length-(r.to-o)))?i={from:r.from,to:r.to,insert:le.of(e.text.slice(r.from-o,d).split(xO))}:(u=um(h,e.text,l-o,c))&&(z.chrome&&s==13&&u.toB==u.from+2&&e.text.slice(u.from,u.toB)==xO+xO&&u.toB--,i={from:o+u.from,to:o+u.toA,insert:le.of(e.text.slice(u.from,u.toB).split(xO))})}else n&&(!t.hasFocus&&O.facet(Ai)||Wo(n,r))&&(n=null);if(!i&&!n)return!1;if((z.mac||z.android)&&i&&i.from==i.to&&i.from==r.head-1&&/^\. ?$/.test(i.insert.toString())&&t.contentDOM.getAttribute("autocorrect")=="off"?(n&&i.insert.length==2&&(n=x.single(n.main.anchor-1,n.main.head-1)),i={from:i.from,to:i.to,insert:le.of([i.insert.toString().replace("."," ")])}):O.doc.lineAt(r.from).toDate.now()-50?i={from:r.from,to:r.to,insert:O.toText(t.inputState.insertingText)}:z.chrome&&i&&i.from==i.to&&i.from==r.head&&i.insert.toString()==` + `&&t.lineWrapping&&(n&&(n=x.single(n.main.anchor-1,n.main.head-1)),i={from:r.from,to:r.to,insert:le.of([" "])}),i)return dh(t,i,n,s);if(n&&!Wo(n,r)){let o=!1,a="select";return t.inputState.lastSelectionTime>Date.now()-50&&(t.inputState.lastSelectionOrigin=="select"&&(o=!0),a=t.inputState.lastSelectionOrigin,a=="select.pointer"&&(n=lm(O.facet(jr).map(l=>l(t)),n))),t.dispatch({selection:n,scrollIntoView:o,userEvent:a}),!0}else return!1}function dh(t,e,i,n=-1){if(z.ios&&t.inputState.flushIOSKey(e))return!0;let O=t.state.selection.main;if(z.android&&(e.to==O.to&&(e.from==O.from||e.from==O.from-1&&t.state.sliceDoc(e.from,O.from)==" ")&&e.insert.length==1&&e.insert.lines==2&&PO(t.contentDOM,"Enter",13)||(e.from==O.from-1&&e.to==O.to&&e.insert.length==0||n==8&&e.insert.lengthO.head)&&PO(t.contentDOM,"Backspace",8)||e.from==O.from&&e.to==O.to+1&&e.insert.length==0&&PO(t.contentDOM,"Delete",46)))return!0;let r=e.insert.toString();t.inputState.composing>=0&&t.inputState.composing++;let s,o=()=>s||(s=Vk(t,e,i));return t.state.facet(Dp).some(a=>a(t,e.from,e.to,r,o))||t.dispatch(o()),!0}function Vk(t,e,i){let n,O=t.state,r=O.selection.main,s=-1;if(e.from==e.to&&e.fromr.to){let a=e.fromh(t)),l,a);e.from==c&&(s=c)}if(s>-1)n={changes:e,selection:x.cursor(e.from+e.insert.length,-1)};else if(e.from>=r.from&&e.to<=r.to&&e.to-e.from>=(r.to-r.from)/3&&(!i||i.main.empty&&i.main.from==e.from+e.insert.length)&&t.inputState.composing<0){let a=r.frome.to?O.sliceDoc(e.to,r.to):"";n=O.replaceSelection(t.state.toText(a+e.insert.sliceString(0,void 0,t.state.lineBreak)+l))}else{let a=O.changes(e),l=i&&i.main.to<=a.newLength?i.main:void 0;if(O.selection.ranges.length>1&&(t.inputState.composing>=0||t.inputState.compositionPendingChange)&&e.to<=r.to+10&&e.to>=r.to-10){let c=t.state.sliceDoc(e.from,e.to),h,d=i&&om(t,i.main.head);if(d){let $=e.insert.length-(e.to-e.from);h={from:d.from,to:d.to-$}}else h=t.state.doc.lineAt(r.head);let u=r.to-e.to;n=O.changeByRange($=>{if($.from==r.from&&$.to==r.to)return{changes:a,range:l||$.map(a)};let Q=$.to-u,p=Q-c.length;if(t.state.sliceDoc(p,Q)!=c||Q>=h.from&&p<=h.to)return{range:$};let m=O.changes({from:p,to:Q,insert:e.insert}),P=$.to-r.to;return{changes:m,range:l?x.range(Math.max(0,l.anchor+P),Math.max(0,l.head+P)):$.map(m)}})}else n={changes:a,selection:l&&O.selection.replaceRange(l)}}let o="input.type";return(t.composing||t.inputState.compositionPendingChange&&t.inputState.compositionEndedAt>Date.now()-50)&&(t.inputState.compositionPendingChange=!1,o+=".compose",t.inputState.compositionFirstChange&&(o+=".start",t.inputState.compositionFirstChange=!1)),O.update(n,{userEvent:o,scrollIntoView:!0})}function um(t,e,i,n){let O=Math.min(t.length,e.length),r=0;for(;r0&&o>0&&t.charCodeAt(s-1)==e.charCodeAt(o-1);)s--,o--;if(n=="end"){let a=Math.max(0,r-Math.min(s,o));i-=s+a-r}if(s=s?r-i:0;r-=a,o=r+(o-s),s=r}else if(o=o?r-i:0;r-=a,s=r+(s-o),o=r}return{from:r,toA:s,toB:o}}function qk(t){let e=[];if(t.root.activeElement!=t.contentDOM)return e;let{anchorNode:i,anchorOffset:n,focusNode:O,focusOffset:r}=t.observer.selectionRange;return i&&(e.push(new cm(i,n)),(O!=i||r!=n)&&e.push(new cm(O,r))),e}function Uk(t,e){if(t.length==0)return null;let i=t[0].pos,n=t.length==2?t[1].pos:i;return i>-1&&n>-1?x.single(i+e,n+e):null}function Wo(t,e){return e.head==t.main.head&&e.anchor==t.main.anchor}class Wk{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.lastTouchTime=0,this.lastTouchX=0,this.lastTouchY=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.lastWheelEvent=0,this.pendingIOSKey=void 0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.insertingText="",this.insertingTextAt=0,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,z.safari&&e.contentDOM.addEventListener("input",()=>null),z.gecko&&Jk(e.contentDOM.ownerDocument)}handleEvent(e){!Dk(this.view,e)||this.ignoreDuringComposition(e)||e.type=="keydown"&&this.keydown(e)||(this.view.updateState!=0?Promise.resolve().then(()=>this.runHandlers(e.type,e)):this.runHandlers(e.type,e))}runHandlers(e,i){let n=this.handlers[e];if(n){for(let O of n.observers)O(this.view,i);for(let O of n.handlers){if(i.defaultPrevented)break;if(O(this.view,i)){i.preventDefault();break}}}}ensureHandlers(e){let i=Ck(e),n=this.handlers,O=this.view.contentDOM;for(let r in i)if(r!="scroll"){let s=!i[r].handlers.length,o=n[r];o&&s!=!o.handlers.length&&(O.removeEventListener(r,this.handleEvent),o=null),o||O.addEventListener(r,this.handleEvent,{passive:s})}for(let r in n)r!="scroll"&&!i[r]&&O.removeEventListener(r,this.handleEvent);this.handlers=i}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&e.keyCode!=27&&Qm.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),z.android&&z.chrome&&!e.synthetic&&(e.keyCode==13||e.keyCode==8))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;let i;return z.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&!e.shiftKey&&((i=$m.find(n=>n.keyCode==e.keyCode))&&!e.ctrlKey||jk.indexOf(e.key)>-1&&e.ctrlKey)?(this.pendingIOSKey=i||e,setTimeout(()=>this.flushIOSKey(),250),!0):(e.keyCode!=229&&this.view.observer.forceFlush(),!1)}flushIOSKey(e){let i=this.pendingIOSKey;return!i||i.key=="Enter"&&e&&e.from0?!0:z.safari&&!z.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100?(this.compositionPendingKey=!1,!0):!1}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}}function fm(t,e){return(i,n)=>{try{return e.call(t,n,i)}catch(O){Tt(i.state,O)}}}function Ck(t){let e=Object.create(null);function i(n){return e[n]||(e[n]={observers:[],handlers:[]})}for(let n of t){let O=n.spec,r=O&&O.plugin.domEventHandlers,s=O&&O.plugin.domEventObservers;if(r)for(let o in r){let a=r[o];a&&i(o).handlers.push(fm(n.value,a))}if(s)for(let o in s){let a=s[o];a&&i(o).observers.push(fm(n.value,a))}}for(let n in si)i(n).handlers.push(si[n]);for(let n in vt)i(n).observers.push(vt[n]);return e}const $m=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],jk="dthko",Qm=[16,17,18,20,91,92,224,225],Co=6;function jo(t){return Math.max(0,t)*.7+8}function Gk(t,e){return Math.max(Math.abs(t.clientX-e.clientX),Math.abs(t.clientY-e.clientY))}class Ek{constructor(e,i,n,O){this.view=e,this.startEvent=i,this.style=n,this.mustSelect=O,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=i,this.scrollParents=Rp(e.contentDOM),this.atoms=e.state.facet(jr).map(s=>s(e));let r=e.contentDOM.ownerDocument;r.addEventListener("mousemove",this.move=this.move.bind(this)),r.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=i.shiftKey,this.multiple=e.state.facet(ae.allowMultipleSelections)&&Ik(e,i),this.dragging=Mk(e,i)&&bm(i)==1?null:!1}start(e){this.dragging===!1&&this.select(e)}move(e){if(e.buttons==0)return this.destroy();if(this.dragging||this.dragging==null&&Gk(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let i=0,n=0,O=0,r=0,s=this.view.win.innerWidth,o=this.view.win.innerHeight;this.scrollParents.x&&({left:O,right:s}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:r,bottom:o}=this.scrollParents.y.getBoundingClientRect());let a=Oh(this.view);e.clientX-a.left<=O+Co?i=-jo(O-e.clientX):e.clientX+a.right>=s-Co&&(i=jo(e.clientX-s)),e.clientY-a.top<=r+Co?n=-jo(r-e.clientY):e.clientY+a.bottom>=o-Co&&(n=jo(e.clientY-o)),this.setScrollSpeed(i,n)}up(e){this.dragging==null&&this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,i){this.scrollSpeed={x:e,y:i},e||i?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:i}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),i&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=i,i=0),(e||i)&&this.view.win.scrollBy(e,i),this.dragging===!1&&this.select(this.lastEvent)}select(e){let{view:i}=this,n=lm(this.atoms,this.style.get(e,this.extend,this.multiple));(this.mustSelect||!n.eq(i.state.selection,this.dragging===!1))&&this.view.dispatch({selection:n,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){e.transactions.some(i=>i.isUserEvent("input.type"))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}}function Ik(t,e){let i=t.state.facet(Ep);return i.length?i[0](e):z.mac?e.metaKey:e.ctrlKey}function Ak(t,e){let i=t.state.facet(Ip);return i.length?i[0](e):z.mac?!e.altKey:!e.ctrlKey}function Mk(t,e){let{main:i}=t.state.selection;if(i.empty)return!1;let n=qr(t.root);if(!n||n.rangeCount==0)return!0;let O=n.getRangeAt(0).getClientRects();for(let r=0;r=e.clientX&&s.top<=e.clientY&&s.bottom>=e.clientY)return!0}return!1}function Dk(t,e){if(!e.bubbles)return!0;if(e.defaultPrevented)return!1;for(let i=e.target,n;i!=t.contentDOM;i=i.parentNode)if(!i||i.nodeType==11||(n=Ze.get(i))&&n.isWidget()&&!n.isHidden&&n.widget.ignoreEvent(e))return!1;return!0}const si=Object.create(null),vt=Object.create(null),pm=z.ie&&z.ie_version<15||z.ios&&z.webkit_version<604;function Lk(t){let e=t.dom.parentNode;if(!e)return;let i=e.appendChild(document.createElement("textarea"));i.style.cssText="position: fixed; left: -10000px; top: 10px",i.focus(),setTimeout(()=>{t.focus(),i.remove(),mm(t,i.value)},50)}function Go(t,e,i){for(let n of t.facet(e))i=n(i,t);return i}function mm(t,e){e=Go(t.state,Jc,e);let{state:i}=t,n,O=1,r=i.toText(e),s=r.lines==i.selection.ranges.length;if(uh!=null&&i.selection.ranges.every(a=>a.empty)&&uh==r.toString()){let a=-1;n=i.changeByRange(l=>{let c=i.doc.lineAt(l.from);if(c.from==a)return{range:l};a=c.from;let h=i.toText((s?r.line(O++).text:e)+i.lineBreak);return{changes:{from:c.from,insert:h},range:x.cursor(l.from+h.length)}})}else s?n=i.changeByRange(a=>{let l=r.line(O++);return{changes:{from:a.from,to:a.to,insert:l.text},range:x.cursor(a.from+l.length)}}):n=i.replaceSelection(r);t.dispatch(n,{userEvent:"input.paste",scrollIntoView:!0})}vt.scroll=t=>{t.inputState.lastScrollTop=t.scrollDOM.scrollTop,t.inputState.lastScrollLeft=t.scrollDOM.scrollLeft},vt.wheel=vt.mousewheel=t=>{t.inputState.lastWheelEvent=Date.now()},si.keydown=(t,e)=>(t.inputState.setSelectionOrigin("select"),e.keyCode==27&&t.inputState.tabFocusMode!=0&&(t.inputState.tabFocusMode=Date.now()+2e3),!1),vt.touchstart=(t,e)=>{let i=t.inputState,n=e.targetTouches[0];i.lastTouchTime=Date.now(),n&&(i.lastTouchX=n.clientX,i.lastTouchY=n.clientY),i.setSelectionOrigin("select.pointer")},vt.touchmove=t=>{t.inputState.setSelectionOrigin("select.pointer")},si.mousedown=(t,e)=>{if(t.observer.flush(),t.inputState.lastTouchTime>Date.now()-2e3)return!1;let i=null;for(let n of t.state.facet(Ap))if(i=n(t,e),i)break;if(!i&&e.button==0&&(i=Bk(t,e)),i){let n=!t.hasFocus;t.inputState.startMouseSelection(new Ek(t,e,i,n)),n&&t.observer.ignore(()=>{Zp(t.contentDOM);let r=t.root.activeElement;r&&!r.contains(t.contentDOM)&&r.blur()});let O=t.inputState.mouseSelection;if(O)return O.start(e),O.dragging===!1}else t.inputState.setSelectionOrigin("select.pointer");return!1};function gm(t,e,i,n){if(n==1)return x.cursor(e,i);if(n==2)return xk(t.state,e,i);{let O=t.docView.lineAt(e,i),r=t.state.doc.lineAt(O?O.posAtEnd:e),s=O?O.posAtStart:r.from,o=O?O.posAtEnd:r.to;return oDate.now()-400&&Math.abs(e.clientX-t.clientX)<2&&Math.abs(e.clientY-t.clientY)<2?(Sm+1)%3:1}function Bk(t,e){let i=t.posAndSideAtCoords({x:e.clientX,y:e.clientY},!1),n=bm(e),O=t.state.selection;return{update(r){r.docChanged&&(i.pos=r.changes.mapPos(i.pos),O=O.map(r.changes))},get(r,s,o){let a=t.posAndSideAtCoords({x:r.clientX,y:r.clientY},!1),l,c=gm(t,a.pos,a.assoc,n);if(i.pos!=a.pos&&!s){let h=gm(t,i.pos,i.assoc,n),d=Math.min(h.from,c.from),u=Math.max(h.to,c.to);c=d1&&(l=Fk(O,a.pos))?l:o?O.addRange(c):x.create([c])}}}function Fk(t,e){for(let i=0;i=e)return x.create(t.ranges.slice(0,i).concat(t.ranges.slice(i+1)),t.mainIndex==i?0:t.mainIndex-(t.mainIndex>i?1:0))}return null}si.dragstart=(t,e)=>{let{selection:{main:i}}=t.state;if(e.target.draggable){let O=t.docView.tile.nearest(e.target);if(O&&O.isWidget()){let r=O.posAtStart,s=r+O.length;(r>=i.to||s<=i.from)&&(i=x.range(r,s))}}let{inputState:n}=t;return n.mouseSelection&&(n.mouseSelection.dragging=!0),n.draggedContent=i,e.dataTransfer&&(e.dataTransfer.setData("Text",Go(t.state,eh,t.state.sliceDoc(i.from,i.to))),e.dataTransfer.effectAllowed="copyMove"),!1},si.dragend=t=>(t.inputState.draggedContent=null,!1);function ym(t,e,i,n){if(i=Go(t.state,Jc,i),!i)return;let O=t.posAtCoords({x:e.clientX,y:e.clientY},!1),{draggedContent:r}=t.inputState,s=n&&r&&Ak(t,e)?{from:r.from,to:r.to}:null,o={from:O,insert:i},a=t.state.changes(s?[s,o]:o);t.focus(),t.dispatch({changes:a,selection:{anchor:a.mapPos(O,-1),head:a.mapPos(O,1)},userEvent:s?"move.drop":"input.drop"}),t.inputState.draggedContent=null}si.drop=(t,e)=>{if(!e.dataTransfer)return!1;if(t.state.readOnly)return!0;let i=e.dataTransfer.files;if(i&&i.length){let n=Array(i.length),O=0,r=()=>{++O==i.length&&ym(t,e,n.filter(s=>s!=null).join(t.state.lineBreak),!1)};for(let s=0;s{/[\x00-\x08\x0e-\x1f]{2}/.test(o.result)||(n[s]=o.result),r()},o.readAsText(i[s])}return!0}else{let n=e.dataTransfer.getData("Text");if(n)return ym(t,e,n,!0),!0}return!1},si.paste=(t,e)=>{if(t.state.readOnly)return!0;t.observer.flush();let i=pm?null:e.clipboardData;return i?(mm(t,i.getData("text/plain")||i.getData("text/uri-list")),!0):(Lk(t),!1)};function Hk(t,e){let i=t.dom.parentNode;if(!i)return;let n=i.appendChild(document.createElement("textarea"));n.style.cssText="position: fixed; left: -10000px; top: 10px",n.value=e,n.focus(),n.selectionEnd=e.length,n.selectionStart=0,setTimeout(()=>{n.remove(),t.focus()},50)}function Kk(t){let e=[],i=[],n=!1;for(let O of t.selection.ranges)O.empty||(e.push(t.sliceDoc(O.from,O.to)),i.push(O));if(!e.length){let O=-1;for(let{from:r}of t.selection.ranges){let s=t.doc.lineAt(r);s.number>O&&(e.push(s.text),i.push({from:s.from,to:Math.min(t.doc.length,s.to+1)})),O=s.number}n=!0}return{text:Go(t,eh,e.join(t.lineBreak)),ranges:i,linewise:n}}let uh=null;si.copy=si.cut=(t,e)=>{if(!Ur(t.contentDOM,t.observer.selectionRange))return!1;let{text:i,ranges:n,linewise:O}=Kk(t.state);if(!i&&!O)return!1;uh=O?i:null,e.type=="cut"&&!t.state.readOnly&&t.dispatch({changes:n,scrollIntoView:!0,userEvent:"delete.cut"});let r=pm?null:e.clipboardData;return r?(r.clearData(),r.setData("text/plain",i),!0):(Hk(t,i),!1)};const xm=Pi.define();function Tm(t,e){let i=[];for(let n of t.facet(Lp)){let O=n(t,e);O&&i.push(O)}return i.length?t.update({effects:i,annotations:xm.of(!0)}):null}function wm(t){setTimeout(()=>{let e=t.hasFocus;if(e!=t.inputState.notifiedFocused){let i=Tm(t.state,e);i?t.dispatch(i):t.update([])}},10)}vt.focus=t=>{t.inputState.lastFocusTime=Date.now(),!t.scrollDOM.scrollTop&&(t.inputState.lastScrollTop||t.inputState.lastScrollLeft)&&(t.scrollDOM.scrollTop=t.inputState.lastScrollTop,t.scrollDOM.scrollLeft=t.inputState.lastScrollLeft),wm(t)},vt.blur=t=>{t.observer.clearSelectionRange(),wm(t)},vt.compositionstart=vt.compositionupdate=t=>{t.observer.editContext||(t.inputState.compositionFirstChange==null&&(t.inputState.compositionFirstChange=!0),t.inputState.composing<0&&(t.inputState.composing=0))},vt.compositionend=t=>{t.observer.editContext||(t.inputState.composing=-1,t.inputState.compositionEndedAt=Date.now(),t.inputState.compositionPendingKey=!0,t.inputState.compositionPendingChange=t.observer.pendingRecords().length>0,t.inputState.compositionFirstChange=null,z.chrome&&z.android?t.observer.flushSoon():t.inputState.compositionPendingChange?Promise.resolve().then(()=>t.observer.flush()):setTimeout(()=>{t.inputState.composing<0&&t.docView.hasComposition&&t.update([])},50))},vt.contextmenu=t=>{t.inputState.lastContextMenu=Date.now()},si.beforeinput=(t,e)=>{var i,n;if((e.inputType=="insertText"||e.inputType=="insertCompositionText")&&(t.inputState.insertingText=e.data,t.inputState.insertingTextAt=Date.now()),e.inputType=="insertReplacementText"&&t.observer.editContext){let r=(i=e.dataTransfer)===null||i===void 0?void 0:i.getData("text/plain"),s=e.getTargetRanges();if(r&&s.length){let o=s[0],a=t.posAtDOM(o.startContainer,o.startOffset),l=t.posAtDOM(o.endContainer,o.endOffset);return dh(t,{from:a,to:l,insert:t.state.toText(r)},null),!0}}let O;if(z.chrome&&z.android&&(O=$m.find(r=>r.inputType==e.inputType))&&(t.observer.delayAndroidKey(O.key,O.keyCode),O.key=="Backspace"||O.key=="Delete")){let r=((n=window.visualViewport)===null||n===void 0?void 0:n.height)||0;setTimeout(()=>{var s;(((s=window.visualViewport)===null||s===void 0?void 0:s.height)||0)>r+10&&t.hasFocus&&(t.contentDOM.blur(),t.focus())},100)}return z.ios&&e.inputType=="deleteContentForward"&&t.observer.flushSoon(),z.safari&&e.inputType=="insertText"&&t.inputState.composing>=0&&setTimeout(()=>vt.compositionend(t,e),20),!1};const vm=new Set;function Jk(t){vm.has(t)||(vm.add(t),t.addEventListener("copy",()=>{}),t.addEventListener("cut",()=>{}))}const km=["pre-wrap","normal","pre-line","break-spaces"];let TO=!1;function _m(){TO=!1}class e_{constructor(e){this.lineWrapping=e,this.doc=le.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,i){let n=this.doc.lineAt(i).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(n+=Math.max(0,Math.ceil((i-e-n*this.lineLength*.5)/this.lineLength))),this.lineHeight*n}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/Math.max(1,this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return km.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let i=!1;for(let n=0;n-1,a=Math.abs(i-this.lineHeight)>.3||this.lineWrapping!=o;if(this.lineWrapping=o,this.lineHeight=i,this.charWidth=n,this.textHeight=O,this.lineLength=r,a){this.heightSamples={};for(let l=0;l0}set outdated(e){this.flags=(e?2:0)|this.flags&-3}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>Eo&&(TO=!0),this.height=e)}replace(e,i,n){return St.of(n)}decomposeLeft(e,i){i.push(this)}decomposeRight(e,i){i.push(this)}applyChanges(e,i,n,O){let r=this,s=n.doc;for(let o=O.length-1;o>=0;o--){let{fromA:a,toA:l,fromB:c,toB:h}=O[o],d=r.lineAt(a,ye.ByPosNoHeight,n.setDoc(i),0,0),u=d.to>=l?d:r.lineAt(l,ye.ByPosNoHeight,n,0,0);for(h+=u.to-l,l=u.to;o>0&&d.from<=O[o-1].toA;)a=O[o-1].fromA,c=O[o-1].fromB,o--,ar*2){let o=e[i-1];o.break?e.splice(--i,1,o.left,null,o.right):e.splice(--i,1,o.left,o.right),n+=1+o.break,O-=o.size}else if(r>O*2){let o=e[n];o.break?e.splice(n,1,o.left,null,o.right):e.splice(n,1,o.left,o.right),n+=2+o.break,r-=o.size}else break;else if(O=r&&s(this.lineAt(0,ye.ByPos,n,O,r))}setMeasuredHeight(e){let i=e.heights[e.index++];i<0?(this.spaceAbove=-i,i=e.heights[e.index++]):this.spaceAbove=0,this.setHeight(i)}updateHeight(e,i=0,n=!1,O){return O&&O.from<=i&&O.more&&this.setMeasuredHeight(O),this.outdated=!1,this}toString(){return`block(${this.length})`}}class Ut extends Rm{constructor(e,i,n){super(e,i,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0,this.spaceAbove=n}mainBlock(e,i){return new oi(i,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.breaks)}replace(e,i,n){let O=n[0];return n.length==1&&(O instanceof Ut||O instanceof st&&O.flags&4)&&Math.abs(this.length-O.length)<10?(O instanceof st?O=new Ut(O.length,this.height,this.spaceAbove):O.height=this.height,this.outdated||(O.outdated=!1),O):St.of(n)}updateHeight(e,i=0,n=!1,O){return O&&O.from<=i&&O.more?this.setMeasuredHeight(O):(n||this.outdated)&&(this.spaceAbove=0,this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight)),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}}class st extends St{constructor(e){super(e,0)}heightMetrics(e,i){let n=e.doc.lineAt(i).number,O=e.doc.lineAt(i+this.length).number,r=O-n+1,s,o=0;if(e.lineWrapping){let a=Math.min(this.height,e.lineHeight*r);s=a/r,this.length>r+1&&(o=(this.height-a)/(this.length-r-1))}else s=this.height/r;return{firstLine:n,lastLine:O,perLine:s,perChar:o}}blockAt(e,i,n,O){let{firstLine:r,lastLine:s,perLine:o,perChar:a}=this.heightMetrics(i,O);if(i.lineWrapping){let l=O+(e0){let r=n[n.length-1];r instanceof st?n[n.length-1]=new st(r.length+O):n.push(null,new st(O-1))}if(e>0){let r=n[0];r instanceof st?n[0]=new st(e+r.length):n.unshift(new st(e-1),null)}return St.of(n)}decomposeLeft(e,i){i.push(new st(e-1),null)}decomposeRight(e,i){i.push(null,new st(this.length-e-1))}updateHeight(e,i=0,n=!1,O){let r=i+this.length;if(O&&O.from<=i+this.length&&O.more){let s=[],o=Math.max(i,O.from),a=-1;for(O.from>i&&s.push(new st(O.from-i-1).updateHeight(e,i));o<=r&&O.more;){let c=e.doc.lineAt(o).length;s.length&&s.push(null);let h=O.heights[O.index++],d=0;h<0&&(d=-h,h=O.heights[O.index++]),a==-1?a=h:Math.abs(h-a)>=Eo&&(a=-2);let u=new Ut(c,h,d);u.outdated=!1,s.push(u),o+=c+1}o<=r&&s.push(null,new st(r-o).updateHeight(e,o));let l=St.of(s);return(a<0||Math.abs(l.height-this.height)>=Eo||Math.abs(a-this.heightMetrics(e,i).perLine)>=Eo)&&(TO=!0),Io(this,l)}else(n||this.outdated)&&(this.setHeight(e.heightForGap(i,i+this.length)),this.outdated=!1);return this}toString(){return`gap(${this.length})`}}class n_ extends St{constructor(e,i,n){super(e.length+i+n.length,e.height+n.height,i|(e.outdated||n.outdated?2:0)),this.left=e,this.right=n,this.size=e.size+n.size}get break(){return this.flags&1}blockAt(e,i,n,O){let r=n+this.left.height;return eo))return l;let c=i==ye.ByPosNoHeight?ye.ByPosNoHeight:ye.ByPos;return a?l.join(this.right.lineAt(o,c,n,s,o)):this.left.lineAt(o,c,n,O,r).join(l)}forEachLine(e,i,n,O,r,s){let o=O+this.left.height,a=r+this.left.length+this.break;if(this.break)e=a&&this.right.forEachLine(e,i,n,o,a,s);else{let l=this.lineAt(a,ye.ByPos,n,O,r);e=e&&l.from<=i&&s(l),i>l.to&&this.right.forEachLine(l.to+1,i,n,o,a,s)}}replace(e,i,n){let O=this.left.length+this.break;if(ithis.left.length)return this.balanced(this.left,this.right.replace(e-O,i-O,n));let r=[];e>0&&this.decomposeLeft(e,r);let s=r.length;for(let o of n)r.push(o);if(e>0&&Zm(r,s-1),i=n&&i.push(null)),e>n&&this.right.decomposeLeft(e-n,i)}decomposeRight(e,i){let n=this.left.length,O=n+this.break;if(e>=O)return this.right.decomposeRight(e-O,i);e2*i.size||i.size>2*e.size?St.of(this.break?[e,null,i]:[e,i]):(this.left=Io(this.left,e),this.right=Io(this.right,i),this.setHeight(e.height+i.height),this.outdated=e.outdated||i.outdated,this.size=e.size+i.size,this.length=e.length+this.break+i.length,this)}updateHeight(e,i=0,n=!1,O){let{left:r,right:s}=this,o=i+r.length+this.break,a=null;return O&&O.from<=i+r.length&&O.more?a=r=r.updateHeight(e,i,n,O):r.updateHeight(e,i,n),O&&O.from<=o+s.length&&O.more?a=s=s.updateHeight(e,o,n,O):s.updateHeight(e,o,n),a?this.balanced(r,s):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}}function Zm(t,e){let i,n;t[e]==null&&(i=t[e-1])instanceof st&&(n=t[e+1])instanceof st&&t.splice(e-1,3,new st(i.length+1+n.length))}const O_=5;class fh{constructor(e,i){this.pos=e,this.oracle=i,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,i){if(this.lineStart>-1){let n=Math.min(i,this.lineEnd),O=this.nodes[this.nodes.length-1];O instanceof Ut?O.length+=n-this.pos:(n>this.pos||!this.isCovered)&&this.nodes.push(new Ut(n-this.pos,-1,0)),this.writtenTo=n,i>n&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=i}point(e,i,n){if(e=O_)&&this.addLineDeco(O,r,s)}else i>e&&this.span(e,i);this.lineEnd>-1&&this.lineEnd-1)return;let{from:e,to:i}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=i,this.writtenToe&&this.nodes.push(new Ut(this.pos-e,-1,0)),this.writtenTo=this.pos}blankContent(e,i){let n=new st(i-e);return this.oracle.doc.lineAt(e).to==i&&(n.flags|=4),n}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof Ut)return e;let i=new Ut(0,-1,0);return this.nodes.push(i),i}addBlock(e){this.enterLine();let i=e.deco;i&&i.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,i&&i.endSide>0&&(this.covering=e)}addLineDeco(e,i,n){let O=this.ensureLine();O.length+=n,O.collapsed+=n,O.widgetHeight=Math.max(O.widgetHeight,e),O.breaks+=i,this.writtenTo=this.pos=this.pos+n}finish(e){let i=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(i instanceof Ut)&&!this.isCovered?this.nodes.push(new Ut(0,-1,0)):(this.writtenToc.clientHeight||c.scrollWidth>c.clientWidth)&&h.overflow!="visible"){let d=c.getBoundingClientRect();r=Math.max(r,d.left),s=Math.min(s,d.right),o=Math.max(o,d.top),a=Math.min(l==t.parentNode?O.innerHeight:a,d.bottom)}l=h.position=="absolute"||h.position=="fixed"?c.offsetParent:c.parentNode}else if(l.nodeType==11)l=l.host;else break;return{left:r-i.left,right:Math.max(r,s)-i.left,top:o-(i.top+e),bottom:Math.max(o,a)-(i.top+e)}}function a_(t){let e=t.getBoundingClientRect(),i=t.ownerDocument.defaultView||window;return e.left0&&e.top0}function l_(t,e){let i=t.getBoundingClientRect();return{left:0,right:i.right-i.left,top:e,bottom:i.bottom-(i.top+e)}}class $h{constructor(e,i,n,O){this.from=e,this.to=i,this.size=n,this.displaySize=O}static same(e,i){if(e.length!=i.length)return!1;for(let n=0;ntypeof O!="function"&&O.class=="cm-lineWrapping");this.heightOracle=new e_(n),this.stateDeco=Vm(i),this.heightMap=St.empty().applyChanges(this.stateDeco,le.empty,this.heightOracle.setDoc(i.doc),[new Lt(0,0,0,i.doc.length)]);for(let O=0;O<2&&(this.viewport=this.getViewport(0,null),!!this.updateForViewport());O++);this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=D.set(this.lineGaps.map(O=>O.draw(this,!1))),this.scrollParent=e.scrollDOM,this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:i}=this.state.selection;for(let n=0;n<=1;n++){let O=n?i.head:i.anchor;if(!e.some(({from:r,to:s})=>O>=r&&O<=s)){let{from:r,to:s}=this.lineBlockAt(O);e.push(new Ao(r,s))}}return this.viewports=e.sort((n,O)=>n.from-O.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?zm:new Qh(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(Ir(e,this.scaler))})}update(e,i=null){this.state=e.state;let n=this.stateDeco;this.stateDeco=Vm(this.state);let O=e.changedRanges,r=Lt.extendWithRanges(O,r_(n,this.stateDeco,e?e.changes:De.empty(this.state.doc.length))),s=this.heightMap.height,o=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollOffset);_m(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),r),(this.heightMap.height!=s||TO)&&(e.flags|=2),o?(this.scrollAnchorPos=e.changes.mapPos(o.from,-1),this.scrollAnchorHeight=o.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=s);let a=r.length?this.mapViewport(this.viewport,e.changes):this.viewport;(i&&(i.range.heada.to)||!this.viewportIsAppropriate(a))&&(a=this.getViewport(0,i));let l=a.from!=this.viewport.from||a.to!=this.viewport.to;this.viewport=a,e.flags|=this.updateForViewport(),(l||!e.changes.empty||e.flags&2)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),i&&(this.scrollTarget=i),!this.mustEnforceCursorAssoc&&(e.selectionSet||e.focusChanged)&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(Bp)&&(this.mustEnforceCursorAssoc=!0)}measure(){let{view:e}=this,i=e.contentDOM,n=window.getComputedStyle(i),O=this.heightOracle,r=n.whiteSpace;this.defaultTextDirection=n.direction=="rtl"?ge.RTL:ge.LTR;let s=this.heightOracle.mustRefreshForWrapping(r)||this.mustMeasureContent==="refresh",o=i.getBoundingClientRect(),a=s||this.mustMeasureContent||this.contentDOMHeight!=o.height;this.contentDOMHeight=o.height,this.mustMeasureContent=!1;let l=0,c=0;if(o.width&&o.height){let{scaleX:X,scaleY:y}=_p(i,o);(X>.005&&Math.abs(this.scaleX-X)>.005||y>.005&&Math.abs(this.scaleY-y)>.005)&&(this.scaleX=X,this.scaleY=y,l|=16,s=a=!0)}let h=(parseInt(n.paddingTop)||0)*this.scaleY,d=(parseInt(n.paddingBottom)||0)*this.scaleY;(this.paddingTop!=h||this.paddingBottom!=d)&&(this.paddingTop=h,this.paddingBottom=d,l|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(O.lineWrapping&&(a=!0),this.editorWidth=e.scrollDOM.clientWidth,l|=16);let u=Rp(this.view.contentDOM,!1).y;u!=this.scrollParent&&(this.scrollParent=u,this.scrollAnchorHeight=-1,this.scrollOffset=0);let $=this.getScrollOffset();this.scrollOffset!=$&&(this.scrollAnchorHeight=-1,this.scrollOffset=$),this.scrolledToBottom=zp(this.scrollParent||e.win);let Q=(this.printing?l_:o_)(i,this.paddingTop),p=Q.top-this.pixelViewport.top,m=Q.bottom-this.pixelViewport.bottom;this.pixelViewport=Q;let P=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(P!=this.inView&&(this.inView=P,P&&(a=!0)),!this.inView&&!this.scrollTarget&&!a_(e.dom))return 0;let g=o.width;if((this.contentDOMWidth!=g||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=o.width,this.editorHeight=e.scrollDOM.clientHeight,l|=16),a){let X=e.docView.measureVisibleLineHeights(this.viewport);if(O.mustRefreshForHeights(X)&&(s=!0),s||O.lineWrapping&&Math.abs(g-this.contentDOMWidth)>O.charWidth){let{lineHeight:y,charWidth:T,textHeight:C}=e.docView.measureTextSize();s=y>0&&O.refresh(r,y,T,C,Math.max(5,g/T),X),s&&(e.docView.minWidth=0,l|=16)}p>0&&m>0?c=Math.max(p,m):p<0&&m<0&&(c=Math.min(p,m)),_m();for(let y of this.viewports){let T=y.from==this.viewport.from?X:e.docView.measureVisibleLineHeights(y);this.heightMap=(s?St.empty().applyChanges(this.stateDeco,le.empty,this.heightOracle,[new Lt(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(O,0,s,new t_(y.from,T))}TO&&(l|=2)}let b=!this.viewportIsAppropriate(this.viewport,c)||this.scrollTarget&&(this.scrollTarget.range.headthis.viewport.to);return b&&(l&2&&(l|=this.updateScaler()),this.viewport=this.getViewport(c,this.scrollTarget),l|=this.updateForViewport()),(l&2||b)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(s?[]:this.lineGaps,e)),l|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),l}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,i){let n=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),O=this.heightMap,r=this.heightOracle,{visibleTop:s,visibleBottom:o}=this,a=new Ao(O.lineAt(s-n*1e3,ye.ByHeight,r,0,0).from,O.lineAt(o+(1-n)*1e3,ye.ByHeight,r,0,0).to);if(i){let{head:l}=i.range;if(la.to){let c=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),h=O.lineAt(l,ye.ByPos,r,0,0),d;i.y=="center"?d=(h.top+h.bottom)/2-c/2:i.y=="start"||i.y=="nearest"&&l=o+Math.max(10,Math.min(n,250)))&&O>s-2*1e3&&r>1,s=O<<1;if(this.defaultTextDirection!=ge.LTR&&!n)return[];let o=[],a=(c,h,d,u)=>{if(h-cc&&mm.from>=d.from&&m.to<=d.to&&Math.abs(m.from-c)m.fromP));if(!p){if(hg.from<=h&&g.to>=h)){let g=i.moveToLineBoundary(x.cursor(h),!1,!0).head;g>c&&(h=g)}let m=this.gapSize(d,c,h,u),P=n||m<2e6?m:2e6;p=new $h(c,h,m,P)}o.push(p)},l=c=>{if(c.length2e6)for(let y of e)y.from>=c.from&&y.fromc.from&&a(c.from,u,c,h),$i.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let i=this.stateDeco;this.lineGaps.length&&(i=i.concat(this.lineGapDeco));let n=[];re.spans(i,this.viewport.from,this.viewport.to,{span(r,s){n.push({from:r,to:s})},point(){}},20);let O=0;if(n.length!=this.visibleRanges.length)O=12;else for(let r=0;r=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(i=>i.from<=e&&i.to>=e)||Ir(this.heightMap.lineAt(e,ye.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(i=>i.top<=e&&i.bottom>=e)||Ir(this.heightMap.lineAt(this.scaler.fromDOM(e),ye.ByHeight,this.heightOracle,0,0),this.scaler)}getScrollOffset(){return(this.scrollParent==this.view.scrollDOM?this.scrollParent.scrollTop:(this.scrollParent?this.scrollParent.getBoundingClientRect().top:0)-this.view.contentDOM.getBoundingClientRect().top)*this.scaleY}scrollAnchorAt(e){let i=this.lineBlockAtHeight(e+8);return i.from>=this.viewport.from||this.viewportLines[0].top-e>200?i:this.viewportLines[0]}elementAtHeight(e){return Ir(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}}class Ao{constructor(e,i){this.from=e,this.to=i}}function h_(t,e,i){let n=[],O=t,r=0;return re.spans(i,t,e,{span(){},point(s,o){s>O&&(n.push({from:O,to:s}),r+=s-O),O=o}},20),O=1)return e[e.length-1].to;let n=Math.floor(t*i);for(let O=0;;O++){let{from:r,to:s}=e[O],o=s-r;if(n<=o)return r+n;n-=o}}function Do(t,e){let i=0;for(let{from:n,to:O}of t.ranges){if(e<=O){i+=e-n;break}i+=O-n}return i/t.total}function d_(t,e){for(let i of t)if(e(i))return i}const zm={toDOM(t){return t},fromDOM(t){return t},scale:1,eq(t){return t==this}};function Vm(t){let e=t.facet(Zo).filter(n=>typeof n!="function"),i=t.facet(nh).filter(n=>typeof n!="function");return i.length&&e.push(re.join(i)),e}class Qh{constructor(e,i,n){let O=0,r=0,s=0;this.viewports=n.map(({from:o,to:a})=>{let l=i.lineAt(o,ye.ByPos,e,0,0).top,c=i.lineAt(a,ye.ByPos,e,0,0).bottom;return O+=c-l,{from:o,to:a,top:l,bottom:c,domTop:0,domBottom:0}}),this.scale=(7e6-O)/(i.height-O);for(let o of this.viewports)o.domTop=s+(o.top-r)*this.scale,s=o.domBottom=o.domTop+(o.bottom-o.top),r=o.bottom}toDOM(e){for(let i=0,n=0,O=0;;i++){let r=ii.from==e.viewports[n].from&&i.to==e.viewports[n].to):!1}}function Ir(t,e){if(e.scale==1)return t;let i=e.toDOM(t.top),n=e.toDOM(t.bottom);return new oi(t.from,t.length,i,n-i,Array.isArray(t._content)?t._content.map(O=>Ir(O,e)):t._content)}const Lo=Z.define({combine:t=>t.join(" ")}),ph=Z.define({combine:t=>t.indexOf(!0)>-1}),mh=fn.newName(),qm=fn.newName(),Um=fn.newName(),Wm={"&light":"."+qm,"&dark":"."+Um};function gh(t,e,i){return new fn(e,{finish(n){return/&/.test(n)?n.replace(/&\w*/,O=>{if(O=="&")return t;if(!i||!i[O])throw new RangeError(`Unsupported selector: ${O}`);return i[O]}):t+" "+n}})}const u_=gh("."+mh,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0,overflowAnchor:"none"},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#ddd"},".cm-selectionHandle":{backgroundColor:"currentColor",width:"1.5px"},".cm-selectionHandle-start::before, .cm-selectionHandle-end::before":{content:'""',backgroundColor:"inherit",borderRadius:"50%",width:"8px",height:"8px",position:"absolute",left:"-3.25px"},".cm-selectionHandle-start::before":{top:"-8px"},".cm-selectionHandle-end::before":{bottom:"-8px"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",zIndex:200},".cm-gutters-before":{insetInlineStart:0},".cm-gutters-after":{insetInlineEnd:0},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",border:"0px solid #ddd","&.cm-gutters-before":{borderRightWidth:"1px"},"&.cm-gutters-after":{borderLeftWidth:"1px"}},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-dialog":{padding:"2px 19px 4px 6px",position:"relative","& label":{fontSize:"80%"}},".cm-dialog-close":{position:"absolute",top:"3px",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",fontSize:"14px",padding:"0"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top",userSelect:"none"},".cm-highlightSpace":{backgroundImage:"radial-gradient(circle at 50% 55%, #aaa 20%, transparent 5%)",backgroundPosition:"center"},".cm-highlightTab":{backgroundImage:`url('data:image/svg+xml,')`,backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},Wm),f_={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},Ph=z.ie&&z.ie_version<=11;class $_{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new M5,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(i=>{for(let n of i)this.queue.push(n);(z.ie&&z.ie_version<=11||z.ios&&e.composing)&&i.some(n=>n.type=="childList"&&n.removedNodes.length||n.type=="characterData"&&n.oldValue.length>n.target.nodeValue.length)?this.flushSoon():this.flush()}),window.EditContext&&z.android&&e.constructor.EDIT_CONTEXT!==!1&&!(z.chrome&&z.chrome_version<126)&&(this.editContext=new p_(e),e.state.facet(Ai)&&(e.contentDOM.editContext=this.editContext.editContext)),Ph&&(this.onCharData=i=>{this.queue.push({target:i.target,type:"characterData",oldValue:i.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),typeof ResizeObserver=="function"&&(this.resizeScroll=new ResizeObserver(()=>{var i;((i=this.view.docView)===null||i===void 0?void 0:i.lastUpdate){this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),i.length>0&&i[i.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(i=>{i.length>0&&i[i.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){(e.type=="change"||!e.type)&&!e.matches||(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((i,n)=>i!=e[n]))){this.gapIntersection.disconnect();for(let i of e)this.gapIntersection.observe(i);this.gaps=e}}onSelectionChange(e){let i=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:n}=this,O=this.selectionRange;if(n.state.facet(Ai)?n.root.activeElement!=this.dom:!Ur(this.dom,O))return;let r=O.anchorNode&&n.docView.tile.nearest(O.anchorNode);if(r&&r.isWidget()&&r.widget.ignoreEvent(e)){i||(this.selectionChanged=!1);return}(z.ie&&z.ie_version<=11||z.android&&z.chrome)&&!n.state.selection.main.empty&&O.focusNode&&Wr(O.focusNode,O.focusOffset,O.anchorNode,O.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,i=qr(e.root);if(!i)return!1;let n=z.safari&&e.root.nodeType==11&&e.root.activeElement==this.dom&&Q_(this.view,i)||i;if(!n||this.selectionRange.eq(n))return!1;let O=Ur(this.dom,n);return O&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime{let r=this.delayedAndroidKey;r&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=r.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&r.force&&PO(this.dom,r.key,r.keyCode))};this.flushingAndroidKey=this.view.win.requestAnimationFrame(O)}(!this.delayedAndroidKey||e=="Enter")&&(this.delayedAndroidKey={key:e,keyCode:i,force:this.lastChange{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let i=-1,n=-1,O=!1;for(let r of e){let s=this.readMutation(r);s&&(s.typeOver&&(O=!0),i==-1?{from:i,to:n}=s:(i=Math.min(s.from,i),n=Math.max(s.to,n)))}return{from:i,to:n,typeOver:O}}readChange(){let{from:e,to:i,typeOver:n}=this.processRecords(),O=this.selectionChanged&&Ur(this.dom,this.selectionRange);if(e<0&&!O)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let r=new zk(this.view,e,i,n);return this.view.docView.domChanged={newSel:r.newSel?r.newSel.main:null},r}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let i=this.readChange();if(!i)return this.view.requestMeasure(),!1;let n=this.view.state,O=dm(this.view,i);return this.view.state==n&&(i.domChanged||i.newSel&&!Wo(this.view.state.selection,i.newSel.main))&&this.view.update([]),O}readMutation(e){let i=this.view.docView.tile.nearest(e.target);if(!i||i.isWidget())return null;if(i.markDirty(e.type=="attributes"),e.type=="childList"){let n=Cm(i,e.previousSibling||e.target.previousSibling,-1),O=Cm(i,e.nextSibling||e.target.nextSibling,1);return{from:n?i.posAfter(n):i.posAtStart,to:O?i.posBefore(O):i.posAtEnd,typeOver:!1}}else return e.type=="characterData"?{from:i.posAtStart,to:i.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener("change",this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener("change",this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(Ai)!=e.state.facet(Ai)&&(e.view.contentDOM.editContext=e.state.facet(Ai)?this.editContext.editContext:null))}destroy(){var e,i,n;this.stop(),(e=this.intersection)===null||e===void 0||e.disconnect(),(i=this.gapIntersection)===null||i===void 0||i.disconnect(),(n=this.resizeScroll)===null||n===void 0||n.disconnect();for(let O of this.scrollTargets)O.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}}function Cm(t,e,i){for(;e;){let n=Ze.get(e);if(n&&n.parent==t)return n;let O=e.parentNode;e=O!=t.dom?O:i>0?e.nextSibling:e.previousSibling}return null}function jm(t,e){let i=e.startContainer,n=e.startOffset,O=e.endContainer,r=e.endOffset,s=t.docView.domAtPos(t.state.selection.main.anchor,1);return Wr(s.node,s.offset,O,r)&&([i,n,O,r]=[O,r,i,n]),{anchorNode:i,anchorOffset:n,focusNode:O,focusOffset:r}}function Q_(t,e){if(e.getComposedRanges){let O=e.getComposedRanges(t.root)[0];if(O)return jm(t,O)}let i=null;function n(O){O.preventDefault(),O.stopImmediatePropagation(),i=O.getTargetRanges()[0]}return t.contentDOM.addEventListener("beforeinput",n,!0),t.dom.ownerDocument.execCommand("indent"),t.contentDOM.removeEventListener("beforeinput",n,!0),i?jm(t,i):null}class p_{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let i=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=n=>{let O=e.state.selection.main,{anchor:r,head:s}=O,o=this.toEditorPos(n.updateRangeStart),a=this.toEditorPos(n.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:n.updateRangeStart,editorBase:o,drifted:!1});let l=a-o>n.text.length;o==this.from&&rthis.to&&(a=r);let c=um(e.state.sliceDoc(o,a),n.text,(l?O.from:O.to)-o,l?"end":null);if(!c){let d=x.single(this.toEditorPos(n.selectionStart),this.toEditorPos(n.selectionEnd));Wo(d,O)||e.dispatch({selection:d,userEvent:"select"});return}let h={from:c.from+o,to:c.toA+o,insert:le.of(n.text.slice(c.from,c.toB).split(` +`))};if((z.mac||z.android)&&h.from==s-1&&/^\. ?$/.test(n.text)&&e.contentDOM.getAttribute("autocorrect")=="off"&&(h={from:o,to:a,insert:le.of([n.text.replace("."," ")])}),this.pendingContextChange=h,!e.state.readOnly){let d=this.to-this.from+(h.to-h.from+h.insert.length);dh(e,h,x.single(this.toEditorPos(n.selectionStart,d),this.toEditorPos(n.selectionEnd,d)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state)),h.from=0&&!/[\\p{Alphabetic}\\p{Number}_]/.test(i.text.slice(Math.max(0,n.updateRangeStart-1),Math.min(i.text.length,n.updateRangeStart+1)))&&this.handlers.compositionend(n)},this.handlers.characterboundsupdate=n=>{let O=[],r=null;for(let s=this.toEditorPos(n.rangeStart),o=this.toEditorPos(n.rangeEnd);s{let O=[];for(let r of n.getTextFormats()){let s=r.underlineStyle,o=r.underlineThickness;if(!/none/i.test(s)&&!/none/i.test(o)){let a=this.toEditorPos(r.rangeStart),l=this.toEditorPos(r.rangeEnd);if(a{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:n}=this.composing;this.composing=null,n&&this.reset(e.state)}};for(let n in this.handlers)i.addEventListener(n,this.handlers[n]);this.measureReq={read:n=>{this.editContext.updateControlBounds(n.contentDOM.getBoundingClientRect());let O=qr(n.root);O&&O.rangeCount&&this.editContext.updateSelectionBounds(O.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let i=0,n=!1,O=this.pendingContextChange;return e.changes.iterChanges((r,s,o,a,l)=>{if(n)return;let c=l.length-(s-r);if(O&&s>=O.to)if(O.from==r&&O.to==s&&O.insert.eq(l)){O=this.pendingContextChange=null,i+=c,this.to+=c;return}else O=null,this.revertPending(e.state);if(r+=i,s+=i,s<=this.from)this.from+=c,this.to+=c;else if(rthis.to||this.to-this.from+l.length>3e4){n=!0;return}this.editContext.updateText(this.toContextPos(r),this.toContextPos(s),l.toString()),this.to+=c}i+=c}),O&&!n&&this.revertPending(e.state),!n}update(e){let i=this.pendingContextChange,n=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(n.from,n.to)&&e.transactions.some(O=>!O.isUserEvent("input.type")&&O.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):!this.applyEdits(e)||!this.rangeIsValid(e.state)?(this.pendingContextChange=null,this.reset(e.state)):(e.docChanged||e.selectionSet||i)&&this.setSelection(e.state),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:i}=e.selection.main;this.from=Math.max(0,i-1e4),this.to=Math.min(e.doc.length,i+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let i=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(i.from),this.toContextPos(i.from+i.insert.length),e.doc.sliceString(i.from,i.to))}setSelection(e){let{main:i}=e.selection,n=this.toContextPos(Math.max(this.from,Math.min(this.to,i.anchor))),O=this.toContextPos(i.head);(this.editContext.selectionStart!=n||this.editContext.selectionEnd!=O)&&this.editContext.updateSelection(n,O)}rangeIsValid(e){let{head:i}=e.selection.main;return!(this.from>0&&i-this.from<500||this.to1e4*3)}toEditorPos(e,i=this.to-this.from){e=Math.min(e,i);let n=this.composing;return n&&n.drifted?n.editorBase+(e-n.contextBase):e+this.from}toContextPos(e){let i=this.composing;return i&&i.drifted?i.contextBase+(e-i.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}}class R{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return!!this.inputState&&this.inputState.composing>0}get compositionStarted(){return!!this.inputState&&this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){var i;this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:n}=e;this.dispatchTransactions=e.dispatchTransactions||n&&(O=>O.forEach(r=>n(r,this)))||(O=>this.update(O)),this.dispatch=this.dispatch.bind(this),this._root=e.root||D5(e.parent)||document,this.viewState=new Ym(this,e.state||ae.create(e)),e.scrollTo&&e.scrollTo.is(Ro)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(XO).map(O=>new th(O));for(let O of this.plugins)O.update(this);this.observer=new $_(this),this.inputState=new Wk(this),this.inputState.ensureHandlers(this.plugins),this.docView=new sm(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),!((i=document.fonts)===null||i===void 0)&&i.ready&&document.fonts.ready.then(()=>{this.viewState.mustMeasureContent="refresh",this.requestMeasure()})}dispatch(...e){let i=e.length==1&&e[0]instanceof Ge?e:e.length==1&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(i,this)}update(e){if(this.updateState!=0)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let i=!1,n=!1,O,r=this.state;for(let d of e){if(d.startState!=r)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");r=d.state}if(this.destroyed){this.viewState.state=r;return}let s=this.hasFocus,o=0,a=null;e.some(d=>d.annotation(xm))?(this.inputState.notifiedFocused=s,o=1):s!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=s,a=Tm(r,s),a||(o=1));let l=this.observer.delayedAndroidKey,c=null;if(l?(this.observer.clearDelayedAndroidKey(),c=this.observer.readChange(),(c&&!this.state.doc.eq(r.doc)||!this.state.selection.eq(r.selection))&&(c=null)):this.observer.clear(),r.facet(ae.phrases)!=this.state.facet(ae.phrases))return this.setState(r);O=Yo.create(this,r,e),O.flags|=o;let h=this.viewState.scrollTarget;try{this.updateState=2;for(let d of e){if(h&&(h=h.map(d.changes)),d.scrollIntoView){let{main:u}=d.state.selection,{x:$,y:Q}=this.state.facet(R.cursorScrollMargin);h=new SO(u.empty?u:x.cursor(u.head,u.head>u.anchor?-1:1),"nearest","nearest",Q,$)}for(let u of d.effects)u.is(Ro)&&(h=u.value.clip(this.state))}this.viewState.update(O,h),this.bidiCache=No.update(this.bidiCache,O.changes),O.empty||(this.updatePlugins(O),this.inputState.update(O)),i=this.docView.update(O),this.state.facet(Gr)!=this.styleModules&&this.mountStyles(),n=this.updateAttrs(),this.showAnnouncements(e),this.docView.updateSelection(i,e.some(d=>d.isUserEvent("select.pointer")))}finally{this.updateState=0}if(O.startState.facet(Lo)!=O.state.facet(Lo)&&(this.viewState.mustMeasureContent=!0),(i||n||h||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),i&&this.docViewUpdate(),!O.empty)for(let d of this.state.facet(Kc))try{d(O)}catch(u){Tt(this.state,u,"update listener")}(a||c)&&Promise.resolve().then(()=>{a&&this.state==a.startState&&this.dispatch(a),c&&!dm(this,c)&&l.force&&PO(this.contentDOM,l.key,l.keyCode)})}setState(e){if(this.updateState!=0)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=e;return}this.updateState=2;let i=this.hasFocus;try{for(let n of this.plugins)n.destroy(this);this.viewState=new Ym(this,e),this.plugins=e.facet(XO).map(n=>new th(n)),this.pluginMap.clear();for(let n of this.plugins)n.update(this);this.docView.destroy(),this.docView=new sm(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}i&&this.focus(),this.requestMeasure()}updatePlugins(e){let i=e.startState.facet(XO),n=e.state.facet(XO);if(i!=n){let O=[];for(let r of n){let s=i.indexOf(r);if(s<0)O.push(new th(r));else{let o=this.plugins[s];o.mustUpdate=e,O.push(o)}}for(let r of this.plugins)r.mustUpdate!=e&&r.destroy(this);this.plugins=O,this.pluginMap.clear()}else for(let O of this.plugins)O.mustUpdate=e;for(let O=0;O-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,e&&this.observer.forceFlush();let i=null,n=this.viewState.scrollParent,O=this.viewState.getScrollOffset(),{scrollAnchorPos:r,scrollAnchorHeight:s}=this.viewState;Math.abs(O-this.viewState.scrollOffset)>1&&(s=-1),this.viewState.scrollAnchorHeight=-1;try{for(let o=0;;o++){if(s<0)if(zp(n||this.win))r=-1,s=this.viewState.heightMap.height;else{let u=this.viewState.scrollAnchorAt(O);r=u.from,s=u.top}this.updateState=1;let a=this.viewState.measure();if(!a&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(o>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let l=[];a&4||([this.measureRequests,l]=[l,this.measureRequests]);let c=l.map(u=>{try{return u.read(this)}catch($){return Tt(this.state,$),Gm}}),h=Yo.create(this,this.state,[]),d=!1;h.flags|=a,i?i.flags|=a:i=h,this.updateState=2,h.empty||(this.updatePlugins(h),this.inputState.update(h),this.updateAttrs(),d=this.docView.update(h),d&&this.docViewUpdate());for(let u=0;u1||$<-1)&&(n==this.scrollDOM||this.hasFocus||Math.max(this.inputState.lastWheelEvent,this.inputState.lastTouchTime)>Date.now()-100)){O=O+$,n?n.scrollTop+=$:this.win.scrollBy(0,$),s=-1;continue}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(i&&!i.empty)for(let o of this.state.facet(Kc))o(i)}get themeClasses(){return mh+" "+(this.state.facet(ph)?Um:qm)+" "+this.state.facet(Lo)}updateAttrs(){let e=Em(this,Kp,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),i={spellcheck:"false",autocorrect:"off",autocapitalize:"off",writingsuggestions:"false",translate:"no",contenteditable:this.state.facet(Ai)?"true":"false",class:"cm-content",style:`${z.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(i["aria-readonly"]="true"),Em(this,ih,i);let n=this.observer.ignore(()=>{let O=wp(this.contentDOM,this.contentAttrs,i),r=wp(this.dom,this.editorAttrs,e);return O||r});return this.editorAttrs=e,this.contentAttrs=i,n}showAnnouncements(e){let i=!0;for(let n of e)for(let O of n.effects)if(O.is(R.announce)){i&&(this.announceDOM.textContent=""),i=!1;let r=this.announceDOM.appendChild(document.createElement("div"));r.textContent=O.value}}mountStyles(){this.styleModules=this.state.facet(Gr);let e=this.state.facet(R.cspNonce);fn.mount(this.root,this.styleModules.concat(u_).reverse(),e?{nonce:e}:void 0)}readMeasured(){if(this.updateState==2)throw new Error("Reading the editor layout isn't allowed during an update");this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(this.measureRequests.indexOf(e)>-1)return;if(e.key!=null){for(let i=0;in.plugin==e)||null),i&&i.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,i,n){return ch(this,e,am(this,e,i,n))}moveByGroup(e,i){return ch(this,e,am(this,e,i,n=>vk(this,e.head,n)))}visualLineSide(e,i){let n=this.bidiSpans(e),O=this.textDirectionAt(e.from),r=n[i?n.length-1:0];return x.cursor(r.side(i,O)+e.from,r.forward(!i,O)?1:-1)}moveToLineBoundary(e,i,n=!0){return wk(this,e,i,n)}moveVertically(e,i,n){return ch(this,e,kk(this,e,i,n))}domAtPos(e,i=1){return this.docView.domAtPos(e,i)}posAtDOM(e,i=0){return this.docView.posFromDOM(e,i)}posAtCoords(e,i=!0){this.readMeasured();let n=hh(this,e,i);return n&&n.pos}posAndSideAtCoords(e,i=!0){return this.readMeasured(),hh(this,e,i)}coordsAtPos(e,i=1){this.readMeasured();let n=this.docView.coordsAt(e,i);if(!n||n.left==n.right)return n;let O=this.state.doc.lineAt(e),r=this.bidiSpans(O),s=r[yi.find(r,e-O.from,-1,i)];return _o(n,s.dir==ge.LTR==i>0)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){return!this.state.facet(Np)||ethis.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>m_)return jp(e.length);let i=this.textDirectionAt(e.from),n;for(let r of this.bidiCache)if(r.from==e.from&&r.dir==i&&(r.fresh||Cp(r.isolates,n=tm(this,e))))return r.order;n||(n=tm(this,e));let O=ek(e.text,i,n);return this.bidiCache.push(new No(e.from,e.to,i,n,!0,O)),O}get hasFocus(){var e;return(this.dom.ownerDocument.hasFocus()||z.safari&&((e=this.inputState)===null||e===void 0?void 0:e.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{Zp(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((e.nodeType==9?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,i={}){var n,O,r,s;return Ro.of(new SO(typeof e=="number"?x.cursor(e):e,(n=i.y)!==null&&n!==void 0?n:"nearest",(O=i.x)!==null&&O!==void 0?O:"nearest",(r=i.yMargin)!==null&&r!==void 0?r:5,(s=i.xMargin)!==null&&s!==void 0?s:5))}scrollSnapshot(){let{scrollTop:e,scrollLeft:i}=this.scrollDOM,n=this.viewState.scrollAnchorAt(e);return Ro.of(new SO(x.cursor(n.from),"start","start",n.top-e,i,!0))}setTabFocusMode(e){e==null?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:typeof e=="boolean"?this.inputState.tabFocusMode=e?0:-1:this.inputState.tabFocusMode!=0&&(this.inputState.tabFocusMode=Date.now()+e)}static domEventHandlers(e){return We.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return We.define(()=>({}),{eventObservers:e})}static theme(e,i){let n=fn.newName(),O=[Lo.of(n),Gr.of(gh(`.${n}`,e))];return i&&i.dark&&O.push(ph.of(!0)),O}static baseTheme(e){return Gi.lowest(Gr.of(gh("."+mh,e,Wm)))}static findFromDOM(e){var i;let n=e.querySelector(".cm-content"),O=n&&Ze.get(n)||Ze.get(e);return((i=O?.root)===null||i===void 0?void 0:i.view)||null}}R.styleModule=Gr,R.inputHandler=Dp,R.clipboardInputFilter=Jc,R.clipboardOutputFilter=eh,R.scrollHandler=Fp,R.focusChangeEffect=Lp,R.perLineTextDirection=Np,R.exceptionSink=Mp,R.updateListener=Kc,R.editable=Ai,R.mouseSelectionStyle=Ap,R.dragMovesSelection=Ip,R.clickAddsSelectionRange=Ep,R.decorations=Zo,R.blockWrappers=Jp,R.outerDecorations=nh,R.atomicRanges=jr,R.bidiIsolatedRanges=em,R.cursorScrollMargin=Z.define({combine:t=>{let e=5,i=5;for(let n of t)typeof n=="number"?e=i=n:{x:e,y:i}=n;return{x:e,y:i}}}),R.scrollMargins=im,R.darkTheme=ph,R.cspNonce=Z.define({combine:t=>t.length?t[0]:""}),R.contentAttributes=ih,R.editorAttributes=Kp,R.lineWrapping=R.contentAttributes.of({class:"cm-lineWrapping"}),R.announce=K.define();const m_=4096,Gm={};class No{constructor(e,i,n,O,r,s){this.from=e,this.to=i,this.dir=n,this.isolates=O,this.fresh=r,this.order=s}static update(e,i){if(i.empty&&!e.some(r=>r.fresh))return e;let n=[],O=e.length?e[e.length-1].dir:ge.LTR;for(let r=Math.max(0,e.length-10);r=0;O--){let r=n[O],s=typeof r=="function"?r(t):r;s&&Mc(s,i)}return i}const g_=z.mac?"mac":z.windows?"win":z.linux?"linux":"key";function P_(t,e){const i=t.split(/-(?!$)/);let n=i[i.length-1];n=="Space"&&(n=" ");let O,r,s,o;for(let a=0;an.concat(O),[]))),i}function X_(t,e,i){return Mm(Am(t.state),e,t,i)}let pn=null;const b_=4e3;function y_(t,e=g_){let i=Object.create(null),n=Object.create(null),O=(s,o)=>{let a=n[s];if(a==null)n[s]=o;else if(a!=o)throw new Error("Key binding "+s+" is used both as a regular binding and as a multi-stroke prefix")},r=(s,o,a,l,c)=>{var h,d;let u=i[s]||(i[s]=Object.create(null)),$=o.split(/ (?!$)/).map(m=>P_(m,e));for(let m=1;m<$.length;m++){let P=$.slice(0,m).join(" ");O(P,!0),u[P]||(u[P]={preventDefault:!0,stopPropagation:!1,run:[g=>{let b=pn={view:g,prefix:P,scope:s};return setTimeout(()=>{pn==b&&(pn=null)},b_),!0}]})}let Q=$.join(" ");O(Q,!1);let p=u[Q]||(u[Q]={preventDefault:!1,stopPropagation:!1,run:((d=(h=u._any)===null||h===void 0?void 0:h.run)===null||d===void 0?void 0:d.slice())||[]});a&&p.run.push(a),l&&(p.preventDefault=!0),c&&(p.stopPropagation=!0)};for(let s of t){let o=s.scope?s.scope.split(" "):["editor"];if(s.any)for(let l of o){let c=i[l]||(i[l]=Object.create(null));c._any||(c._any={preventDefault:!1,stopPropagation:!1,run:[]});let{any:h}=s;for(let d in c)c[d].run.push(u=>h(u,Sh))}let a=s[e]||s.key;if(a)for(let l of o)r(l,a,s.run,s.preventDefault,s.stopPropagation),s.shift&&r(l,"Shift-"+a,s.shift,s.preventDefault,s.stopPropagation)}return i}let Sh=null;function Mm(t,e,i,n){Sh=e;let O=C5(e),r=xt(O,0),s=mi(r)==O.length&&O!=" ",o="",a=!1,l=!1,c=!1;pn&&pn.view==i&&pn.scope==n&&(o=pn.prefix+" ",Qm.indexOf(e.keyCode)<0&&(l=!0,pn=null));let h=new Set,d=p=>{if(p){for(let m of p.run)if(!h.has(m)&&(h.add(m),m(i)))return p.stopPropagation&&(c=!0),!0;p.preventDefault&&(p.stopPropagation&&(c=!0),l=!0)}return!1},u=t[n],$,Q;return u&&(d(u[o+Bo(O,e,!s)])?a=!0:s&&(e.altKey||e.metaKey||e.ctrlKey)&&!(z.windows&&e.ctrlKey&&e.altKey)&&!(z.mac&&e.altKey&&!(e.ctrlKey||e.metaKey))&&($=$n[e.keyCode])&&$!=O?(d(u[o+Bo($,e,!0)])||e.shiftKey&&(Q=Zr[e.keyCode])!=O&&Q!=$&&d(u[o+Bo(Q,e,!1)]))&&(a=!0):s&&e.shiftKey&&d(u[o+Bo(O,e,!0)])&&(a=!0),!a&&d(u._any)&&(a=!0)),l&&(a=!0),a&&c&&e.stopPropagation(),Sh=null,a}class En{constructor(e,i,n,O,r){this.className=e,this.left=i,this.top=n,this.width=O,this.height=r}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}update(e,i){return i.className!=this.className?!1:(this.adjust(e),!0)}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",this.width!=null&&(e.style.width=this.width+"px"),e.style.height=this.height+"px"}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(e,i,n){if(n.empty){let O=e.coordsAtPos(n.head,n.assoc||1);if(!O)return[];let r=Dm(e);return[new En(i,O.left-r.left,O.top-r.top,null,O.bottom-O.top)]}else return x_(e,i,n)}}function Dm(t){let e=t.scrollDOM.getBoundingClientRect();return{left:(t.textDirection==ge.LTR?e.left:e.right-t.scrollDOM.clientWidth*t.scaleX)-t.scrollDOM.scrollLeft*t.scaleX,top:e.top-t.scrollDOM.scrollTop*t.scaleY}}function Lm(t,e,i,n){let O=t.coordsAtPos(e,i*2);if(!O)return n;let r=t.dom.getBoundingClientRect(),s=(O.top+O.bottom)/2,o=t.posAtCoords({x:r.left+1,y:s}),a=t.posAtCoords({x:r.right-1,y:s});return o==null||a==null?n:{from:Math.max(n.from,Math.min(o,a)),to:Math.min(n.to,Math.max(o,a))}}function x_(t,e,i){if(i.to<=t.viewport.from||i.from>=t.viewport.to)return[];let n=Math.max(i.from,t.viewport.from),O=Math.min(i.to,t.viewport.to),r=t.textDirection==ge.LTR,s=t.contentDOM,o=s.getBoundingClientRect(),a=Dm(t),l=s.querySelector(".cm-line"),c=l&&window.getComputedStyle(l),h=o.left+(c?parseInt(c.paddingLeft)+Math.min(0,parseInt(c.textIndent)):0),d=o.right-(c?parseInt(c.paddingRight):0),u=lh(t,n,1),$=lh(t,O,-1),Q=u.type==rt.Text?u:null,p=$.type==rt.Text?$:null;if(Q&&(t.lineWrapping||u.widgetLineBreaks)&&(Q=Lm(t,n,1,Q)),p&&(t.lineWrapping||$.widgetLineBreaks)&&(p=Lm(t,O,-1,p)),Q&&p&&Q.from==p.from&&Q.to==p.to)return P(g(i.from,i.to,Q));{let X=Q?g(i.from,null,Q):b(u,!1),y=p?g(null,i.to,p):b($,!0),T=[];return(Q||u).to<(p||$).from-(Q&&p?1:0)||u.widgetLineBreaks>1&&X.bottom+t.defaultLineHeight/2V&&L.from=te)break;Ye>Oe&&j(Math.max(Qe,Oe),X==null&&Qe<=V,Math.min(Ye,te),y==null&&Ye>=B,ue.dir)}if(Oe=he.to+1,Oe>=te)break}return J.length==0&&j(V,X==null,B,y==null,t.textDirection),{top:C,bottom:G,horizontal:J}}function b(X,y){let T=o.top+(y?X.top:X.bottom);return{top:T,bottom:T,horizontal:[]}}}function T_(t,e){return t.constructor==e.constructor&&t.eq(e)}class w_{constructor(e,i){this.view=e,this.layer=i,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement("div")),this.dom.classList.add("cm-layer"),i.above&&this.dom.classList.add("cm-layer-above"),i.class&&this.dom.classList.add(i.class),this.scale(),this.dom.setAttribute("aria-hidden","true"),this.setOrder(e.state),e.requestMeasure(this.measureReq),i.mount&&i.mount(this.dom,e)}update(e){e.startState.facet(Fo)!=e.state.facet(Fo)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){this.layer.updateOnDocViewUpdate!==!1&&e.requestMeasure(this.measureReq)}setOrder(e){let i=0,n=e.facet(Fo);for(;i!T_(i,this.drawn[n]))){let i=this.dom.firstChild,n=0;for(let O of e)O.update&&i&&O.constructor&&this.drawn[n].constructor&&O.update(i,this.drawn[n])?(i=i.nextSibling,n++):this.dom.insertBefore(O.draw(),i);for(;i;){let O=i.nextSibling;i.remove(),i=O}this.drawn=e,z.webkit&&(this.dom.style.display=this.dom.firstChild?"":"none")}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}}const Fo=Z.define();function Nm(t){return[We.define(e=>new w_(e,t)),Fo.of(t)]}const vO=Z.define({combine(t){return Si(t,{cursorBlinkRate:1200,drawRangeCursor:!0,iosSelectionHandles:!0},{cursorBlinkRate:(e,i)=>Math.min(e,i),drawRangeCursor:(e,i)=>e||i})}});function v_(t={}){return[vO.of(t),k_,__,R_,Bp.of(!0)]}function Bm(t){return t.startState.facet(vO)!=t.state.facet(vO)}const k_=Nm({above:!0,markers(t){let{state:e}=t,i=e.facet(vO),n=[];for(let O of e.selection.ranges){let r=O==e.selection.main;if(O.empty||i.drawRangeCursor&&!(r&&z.ios&&i.iosSelectionHandles)){let s=r?"cm-cursor cm-cursor-primary":"cm-cursor cm-cursor-secondary",o=O.empty?O:x.cursor(O.head,O.assoc);for(let a of En.forRange(t,s,o))n.push(a)}}return n},update(t,e){t.transactions.some(n=>n.selection)&&(e.style.animationName=e.style.animationName=="cm-blink"?"cm-blink2":"cm-blink");let i=Bm(t);return i&&Fm(t.state,e),t.docChanged||t.selectionSet||i},mount(t,e){Fm(e.state,t)},class:"cm-cursorLayer"});function Fm(t,e){e.style.animationDuration=t.facet(vO).cursorBlinkRate+"ms"}const __=Nm({above:!1,markers(t){let e=[],{main:i,ranges:n}=t.state.selection;for(let O of n)if(!O.empty)for(let r of En.forRange(t,"cm-selectionBackground",O))e.push(r);if(z.ios&&!i.empty&&t.state.facet(vO).iosSelectionHandles){for(let O of En.forRange(t,"cm-selectionHandle cm-selectionHandle-start",x.cursor(i.from,1)))e.push(O);for(let O of En.forRange(t,"cm-selectionHandle cm-selectionHandle-end",x.cursor(i.to,1)))e.push(O)}return e},update(t,e){return t.docChanged||t.selectionSet||t.viewportChanged||Bm(t)},class:"cm-selectionLayer"}),R_=Gi.highest(R.theme({".cm-line":{"& ::selection, &::selection":{backgroundColor:"transparent !important"},caretColor:"transparent !important"},".cm-content":{caretColor:"transparent !important","& :focus":{caretColor:"initial !important","&::selection, & ::selection":{backgroundColor:"Highlight !important"}}}})),Hm=K.define({map(t,e){return t==null?null:e.mapPos(t)}}),Ar=nt.define({create(){return null},update(t,e){return t!=null&&(t=e.changes.mapPos(t)),e.effects.reduce((i,n)=>n.is(Hm)?n.value:i,t)}}),Z_=We.fromClass(class{constructor(t){this.view=t,this.cursor=null,this.measureReq={read:this.readPos.bind(this),write:this.drawCursor.bind(this)}}update(t){var e;let i=t.state.field(Ar);i==null?this.cursor!=null&&((e=this.cursor)===null||e===void 0||e.remove(),this.cursor=null):(this.cursor||(this.cursor=this.view.scrollDOM.appendChild(document.createElement("div")),this.cursor.className="cm-dropCursor"),(t.startState.field(Ar)!=i||t.docChanged||t.geometryChanged)&&this.view.requestMeasure(this.measureReq))}readPos(){let{view:t}=this,e=t.state.field(Ar),i=e!=null&&t.coordsAtPos(e);if(!i)return null;let n=t.scrollDOM.getBoundingClientRect();return{left:i.left-n.left+t.scrollDOM.scrollLeft*t.scaleX,top:i.top-n.top+t.scrollDOM.scrollTop*t.scaleY,height:i.bottom-i.top}}drawCursor(t){if(this.cursor){let{scaleX:e,scaleY:i}=this.view;t?(this.cursor.style.left=t.left/e+"px",this.cursor.style.top=t.top/i+"px",this.cursor.style.height=t.height/i+"px"):this.cursor.style.left="-100000px"}}destroy(){this.cursor&&this.cursor.remove()}setDropPos(t){this.view.state.field(Ar)!=t&&this.view.dispatch({effects:Hm.of(t)})}},{eventObservers:{dragover(t){this.setDropPos(this.view.posAtCoords({x:t.clientX,y:t.clientY}))},dragleave(t){(t.target==this.view.contentDOM||!this.view.contentDOM.contains(t.relatedTarget))&&this.setDropPos(null)},dragend(){this.setDropPos(null)},drop(){this.setDropPos(null)}}});function Y_(){return[Ar,Z_]}function Km(t,e,i,n,O){e.lastIndex=0;for(let r=t.iterRange(i,n),s=i,o;!r.next().done;s+=r.value.length)if(!r.lineBreak)for(;o=e.exec(r.value);)O(s+o.index,o)}function z_(t,e){let i=t.visibleRanges;if(i.length==1&&i[0].from==t.viewport.from&&i[0].to==t.viewport.to)return i;let n=[];for(let{from:O,to:r}of i)O=Math.max(t.state.doc.lineAt(O).from,O-e),r=Math.min(t.state.doc.lineAt(r).to,r+e),n.length&&n[n.length-1].to>=O?n[n.length-1].to=r:n.push({from:O,to:r});return n}class V_{constructor(e){const{regexp:i,decoration:n,decorate:O,boundary:r,maxLength:s=1e3}=e;if(!i.global)throw new RangeError("The regular expression given to MatchDecorator should have its 'g' flag set");if(this.regexp=i,O)this.addMatch=(o,a,l,c)=>O(c,l,l+o[0].length,o,a);else if(typeof n=="function")this.addMatch=(o,a,l,c)=>{let h=n(o,a,l);h&&c(l,l+o[0].length,h)};else if(n)this.addMatch=(o,a,l,c)=>c(l,l+o[0].length,n);else throw new RangeError("Either 'decorate' or 'decoration' should be provided to MatchDecorator");this.boundary=r,this.maxLength=s}createDeco(e){let i=new Ei,n=i.add.bind(i);for(let{from:O,to:r}of z_(e,this.maxLength))Km(e.state.doc,this.regexp,O,r,(s,o)=>this.addMatch(o,e,s,n));return i.finish()}updateDeco(e,i){let n=1e9,O=-1;return e.docChanged&&e.changes.iterChanges((r,s,o,a)=>{a>=e.view.viewport.from&&o<=e.view.viewport.to&&(n=Math.min(o,n),O=Math.max(a,O))}),e.viewportMoved||O-n>1e3?this.createDeco(e.view):O>-1?this.updateRange(e.view,i.map(e.changes),n,O):i}updateRange(e,i,n,O){for(let r of e.visibleRanges){let s=Math.max(r.from,n),o=Math.min(r.to,O);if(o>=s){let a=e.state.doc.lineAt(s),l=a.toa.from;s--)if(this.boundary.test(a.text[s-1-a.from])){c=s;break}for(;od.push(m.range(Q,p));if(a==l)for(this.regexp.lastIndex=c-a.from;(u=this.regexp.exec(a.text))&&u.indexthis.addMatch(p,e,Q,$));i=i.update({filterFrom:c,filterTo:h,filter:(Q,p)=>Qh,add:d})}}return i}}const Xh=/x/.unicode!=null?"gu":"g",q_=new RegExp(`[\0-\b +--Ÿ­؜​‎‏\u2028\u2029‭‮⁦⁧⁩\uFEFF-]`,Xh),U_={0:"null",7:"bell",8:"backspace",10:"newline",11:"vertical tab",13:"carriage return",27:"escape",8203:"zero width space",8204:"zero width non-joiner",8205:"zero width joiner",8206:"left-to-right mark",8207:"right-to-left mark",8232:"line separator",8237:"left-to-right override",8238:"right-to-left override",8294:"left-to-right isolate",8295:"right-to-left isolate",8297:"pop directional isolate",8233:"paragraph separator",65279:"zero width no-break space",65532:"object replacement"};let bh=null;function W_(){var t;if(bh==null&&typeof document<"u"&&document.body){let e=document.body.style;bh=((t=e.tabSize)!==null&&t!==void 0?t:e.MozTabSize)!=null}return bh||!1}const Ho=Z.define({combine(t){let e=Si(t,{render:null,specialChars:q_,addSpecialChars:null});return(e.replaceTabs=!W_())&&(e.specialChars=new RegExp(" |"+e.specialChars.source,Xh)),e.addSpecialChars&&(e.specialChars=new RegExp(e.specialChars.source+"|"+e.addSpecialChars.source,Xh)),e}});function C_(t={}){return[Ho.of(t),j_()]}let Jm=null;function j_(){return Jm||(Jm=We.fromClass(class{constructor(t){this.view=t,this.decorations=D.none,this.decorationCache=Object.create(null),this.decorator=this.makeDecorator(t.state.facet(Ho)),this.decorations=this.decorator.createDeco(t)}makeDecorator(t){return new V_({regexp:t.specialChars,decoration:(e,i,n)=>{let{doc:O}=i.state,r=xt(e[0],0);if(r==9){let s=O.lineAt(n),o=i.state.tabSize,a=Oi(s.text,o,n-s.from);return D.replace({widget:new A_((o-a%o)*this.view.defaultCharacterWidth/this.view.scaleX)})}return this.decorationCache[r]||(this.decorationCache[r]=D.replace({widget:new I_(t,r)}))},boundary:t.replaceTabs?void 0:/[^]/})}update(t){let e=t.state.facet(Ho);t.startState.facet(Ho)!=e?(this.decorator=this.makeDecorator(e),this.decorations=this.decorator.createDeco(t.view)):this.decorations=this.decorator.updateDeco(t,this.decorations)}},{decorations:t=>t.decorations}))}const G_="•";function E_(t){return t>=32?G_:t==10?"␤":String.fromCharCode(9216+t)}class I_ extends Xi{constructor(e,i){super(),this.options=e,this.code=i}eq(e){return e.code==this.code}toDOM(e){let i=E_(this.code),n=e.state.phrase("Control character")+" "+(U_[this.code]||"0x"+this.code.toString(16)),O=this.options.render&&this.options.render(this.code,n,i);if(O)return O;let r=document.createElement("span");return r.textContent=i,r.title=n,r.setAttribute("aria-label",n),r.className="cm-specialChar",r}ignoreEvent(){return!1}}class A_ extends Xi{constructor(e){super(),this.width=e}eq(e){return e.width==this.width}toDOM(){let e=document.createElement("span");return e.textContent=" ",e.className="cm-tab",e.style.width=this.width+"px",e}ignoreEvent(){return!1}}function M_(){return L_}const D_=D.line({class:"cm-activeLine"}),L_=We.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.docChanged||t.selectionSet)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=-1,i=[];for(let n of t.state.selection.ranges){let O=t.lineBlockAt(n.head);O.from>e&&(i.push(D_.range(O.from)),e=O.from)}return D.set(i)}},{decorations:t=>t.decorations}),yh=2e3;function N_(t,e,i){let n=Math.min(e.line,i.line),O=Math.max(e.line,i.line),r=[];if(e.off>yh||i.off>yh||e.col<0||i.col<0){let s=Math.min(e.off,i.off),o=Math.max(e.off,i.off);for(let a=n;a<=O;a++){let l=t.doc.line(a);l.length<=o&&r.push(x.range(l.from+s,l.to+o))}}else{let s=Math.min(e.col,i.col),o=Math.max(e.col,i.col);for(let a=n;a<=O;a++){let l=t.doc.line(a),c=qc(l.text,s,t.tabSize,!0);if(c<0)r.push(x.cursor(l.to));else{let h=qc(l.text,o,t.tabSize);r.push(x.range(l.from+c,l.from+h))}}}return r}function B_(t,e){let i=t.coordsAtPos(t.viewport.from);return i?Math.round(Math.abs((i.left-e)/t.defaultCharacterWidth)):-1}function eg(t,e){let i=t.posAtCoords({x:e.clientX,y:e.clientY},!1),n=t.state.doc.lineAt(i),O=i-n.from,r=O>yh?-1:O==n.length?B_(t,e.clientX):Oi(n.text,t.state.tabSize,i-n.from);return{line:n.number,col:r,off:O}}function F_(t,e){let i=eg(t,e),n=t.state.selection;return i?{update(O){if(O.docChanged){let r=O.changes.mapPos(O.startState.doc.line(i.line).from),s=O.state.doc.lineAt(r);i={line:s.number,col:i.col,off:Math.min(i.off,s.length)},n=n.map(O.changes)}},get(O,r,s){let o=eg(t,O);if(!o)return n;let a=N_(t.state,i,o);return a.length?s?x.create(a.concat(n.ranges)):x.create(a):n}}:null}function H_(t){let e=i=>i.altKey&&i.button==0;return R.mouseSelectionStyle.of((i,n)=>e(n)?F_(i,n):null)}const K_={Alt:[18,t=>!!t.altKey],Control:[17,t=>!!t.ctrlKey],Shift:[16,t=>!!t.shiftKey],Meta:[91,t=>!!t.metaKey]},J_={style:"cursor: crosshair"};function eR(t={}){let[e,i]=K_[t.key||"Alt"],n=We.fromClass(class{constructor(O){this.view=O,this.isDown=!1}set(O){this.isDown!=O&&(this.isDown=O,this.view.update([]))}},{eventObservers:{keydown(O){this.set(O.keyCode==e||i(O))},keyup(O){(O.keyCode==e||!i(O))&&this.set(!1)},mousemove(O){this.set(i(O))}}});return[n,R.contentAttributes.of(O=>{var r;return!((r=O.plugin(n))===null||r===void 0)&&r.isDown?J_:null})]}const Ko="-10000px";class tg{constructor(e,i,n,O){this.facet=i,this.createTooltipView=n,this.removeTooltipView=O,this.input=e.state.facet(i),this.tooltips=this.input.filter(s=>s);let r=null;this.tooltipViews=this.tooltips.map(s=>r=n(s,r))}update(e,i){var n;let O=e.state.facet(this.facet),r=O.filter(a=>a);if(O===this.input){for(let a of this.tooltipViews)a.update&&a.update(e);return!1}let s=[],o=i?[]:null;for(let a=0;ai[l]=a),i.length=o.length),this.input=O,this.tooltips=r,this.tooltipViews=s,!0}}function tR(t){let e=t.dom.ownerDocument.documentElement;return{top:0,left:0,bottom:e.clientHeight,right:e.clientWidth}}const xh=Z.define({combine:t=>{var e,i,n;return{position:z.ios?"absolute":((e=t.find(O=>O.position))===null||e===void 0?void 0:e.position)||"fixed",parent:((i=t.find(O=>O.parent))===null||i===void 0?void 0:i.parent)||null,tooltipSpace:((n=t.find(O=>O.tooltipSpace))===null||n===void 0?void 0:n.tooltipSpace)||tR}}}),ig=new WeakMap,Th=We.fromClass(class{constructor(t){this.view=t,this.above=[],this.inView=!0,this.madeAbsolute=!1,this.lastTransaction=0,this.measureTimeout=-1;let e=t.state.facet(xh);this.position=e.position,this.parent=e.parent,this.classes=t.themeClasses,this.createContainer(),this.measureReq={read:this.readMeasure.bind(this),write:this.writeMeasure.bind(this),key:this},this.resizeObserver=typeof ResizeObserver=="function"?new ResizeObserver(()=>this.measureSoon()):null,this.manager=new tg(t,wh,(i,n)=>this.createTooltip(i,n),i=>{this.resizeObserver&&this.resizeObserver.unobserve(i.dom),i.dom.remove()}),this.above=this.manager.tooltips.map(i=>!!i.above),this.intersectionObserver=typeof IntersectionObserver=="function"?new IntersectionObserver(i=>{Date.now()>this.lastTransaction-50&&i.length>0&&i[i.length-1].intersectionRatio<1&&this.measureSoon()},{threshold:[1]}):null,this.observeIntersection(),t.win.addEventListener("resize",this.measureSoon=this.measureSoon.bind(this)),this.maybeMeasure()}createContainer(){this.parent?(this.container=document.createElement("div"),this.container.style.position="relative",this.container.className=this.view.themeClasses,this.parent.appendChild(this.container)):this.container=this.view.dom}observeIntersection(){if(this.intersectionObserver){this.intersectionObserver.disconnect();for(let t of this.manager.tooltipViews)this.intersectionObserver.observe(t.dom)}}measureSoon(){this.measureTimeout<0&&(this.measureTimeout=setTimeout(()=>{this.measureTimeout=-1,this.maybeMeasure()},50))}update(t){t.transactions.length&&(this.lastTransaction=Date.now());let e=this.manager.update(t,this.above);e&&this.observeIntersection();let i=e||t.geometryChanged,n=t.state.facet(xh);if(n.position!=this.position&&!this.madeAbsolute){this.position=n.position;for(let O of this.manager.tooltipViews)O.dom.style.position=this.position;i=!0}if(n.parent!=this.parent){this.parent&&this.container.remove(),this.parent=n.parent,this.createContainer();for(let O of this.manager.tooltipViews)this.container.appendChild(O.dom);i=!0}else this.parent&&this.view.themeClasses!=this.classes&&(this.classes=this.container.className=this.view.themeClasses);i&&this.maybeMeasure()}createTooltip(t,e){let i=t.create(this.view),n=e?e.dom:null;if(i.dom.classList.add("cm-tooltip"),t.arrow&&!i.dom.querySelector(".cm-tooltip > .cm-tooltip-arrow")){let O=document.createElement("div");O.className="cm-tooltip-arrow",i.dom.appendChild(O)}return i.dom.style.position=this.position,i.dom.style.top=Ko,i.dom.style.left="0px",this.container.insertBefore(i.dom,n),i.mount&&i.mount(this.view),this.resizeObserver&&this.resizeObserver.observe(i.dom),i}destroy(){var t,e,i;this.view.win.removeEventListener("resize",this.measureSoon);for(let n of this.manager.tooltipViews)n.dom.remove(),(t=n.destroy)===null||t===void 0||t.call(n);this.parent&&this.container.remove(),(e=this.resizeObserver)===null||e===void 0||e.disconnect(),(i=this.intersectionObserver)===null||i===void 0||i.disconnect(),clearTimeout(this.measureTimeout)}readMeasure(){let t=1,e=1,i=!1;if(this.position=="fixed"&&this.manager.tooltipViews.length){let{dom:r}=this.manager.tooltipViews[0];if(z.safari){let s=r.getBoundingClientRect();i=Math.abs(s.top+1e4)>1||Math.abs(s.left)>1}else i=!!r.offsetParent&&r.offsetParent!=this.container.ownerDocument.body}if(i||this.position=="absolute")if(this.parent){let r=this.parent.getBoundingClientRect();r.width&&r.height&&(t=r.width/this.parent.offsetWidth,e=r.height/this.parent.offsetHeight)}else({scaleX:t,scaleY:e}=this.view.viewState);let n=this.view.scrollDOM.getBoundingClientRect(),O=Oh(this.view);return{visible:{left:n.left+O.left,top:n.top+O.top,right:n.right-O.right,bottom:n.bottom-O.bottom},parent:this.parent?this.container.getBoundingClientRect():this.view.dom.getBoundingClientRect(),pos:this.manager.tooltips.map((r,s)=>{let o=this.manager.tooltipViews[s];return o.getCoords?o.getCoords(r.pos):this.view.coordsAtPos(r.pos)}),size:this.manager.tooltipViews.map(({dom:r})=>r.getBoundingClientRect()),space:this.view.state.facet(xh).tooltipSpace(this.view),scaleX:t,scaleY:e,makeAbsolute:i}}writeMeasure(t){var e;if(t.makeAbsolute){this.madeAbsolute=!0,this.position="absolute";for(let o of this.manager.tooltipViews)o.dom.style.position="absolute"}let{visible:i,space:n,scaleX:O,scaleY:r}=t,s=[];for(let o=0;o=Math.min(i.bottom,n.bottom)||h.rightMath.min(i.right,n.right)+.1)){c.style.top=Ko;continue}let u=a.arrow?l.dom.querySelector(".cm-tooltip-arrow"):null,$=u?7:0,Q=d.right-d.left,p=(e=ig.get(l))!==null&&e!==void 0?e:d.bottom-d.top,m=l.offset||nR,P=this.view.textDirection==ge.LTR,g=d.width>n.right-n.left?P?n.left:n.right-d.width:P?Math.max(n.left,Math.min(h.left-(u?14:0)+m.x,n.right-Q)):Math.min(Math.max(n.left,h.left-Q+(u?14:0)-m.x),n.right-Q),b=this.above[o];!a.strictSide&&(b?h.top-p-$-m.yn.bottom)&&b==n.bottom-h.bottom>h.top-n.top&&(b=this.above[o]=!b);let X=(b?h.top-n.top:n.bottom-h.bottom)-$;if(Xg&&C.topy&&(y=b?C.top-p-2-$:C.bottom+$+2);if(this.position=="absolute"?(c.style.top=(y-t.parent.top)/r+"px",ng(c,(g-t.parent.left)/O)):(c.style.top=y/r+"px",ng(c,g/O)),u){let C=h.left+(P?m.x:-m.x)-(g+14-7);u.style.left=C/O+"px"}l.overlap!==!0&&s.push({left:g,top:y,right:T,bottom:y+p}),c.classList.toggle("cm-tooltip-above",b),c.classList.toggle("cm-tooltip-below",!b),l.positioned&&l.positioned(t.space)}}maybeMeasure(){if(this.manager.tooltips.length&&(this.view.inView&&this.view.requestMeasure(this.measureReq),this.inView!=this.view.inView&&(this.inView=this.view.inView,!this.inView)))for(let t of this.manager.tooltipViews)t.dom.style.top=Ko}},{eventObservers:{scroll(){this.maybeMeasure()}}});function ng(t,e){let i=parseInt(t.style.left,10);(isNaN(i)||Math.abs(e-i)>1)&&(t.style.left=e+"px")}const iR=R.baseTheme({".cm-tooltip":{zIndex:500,boxSizing:"border-box"},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:"7px",width:`${7*2}px`,position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:"7px solid transparent",borderRight:"7px solid transparent"},".cm-tooltip-above &":{bottom:"-7px","&:before":{borderTop:"7px solid #bbb"},"&:after":{borderTop:"7px solid #f5f5f5",bottom:"1px"}},".cm-tooltip-below &":{top:"-7px","&:before":{borderBottom:"7px solid #bbb"},"&:after":{borderBottom:"7px solid #f5f5f5",top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}}),nR={x:0,y:0},wh=Z.define({enables:[Th,iR]}),Jo=Z.define({combine:t=>t.reduce((e,i)=>e.concat(i),[])});class ea{static create(e){return new ea(e)}constructor(e){this.view=e,this.mounted=!1,this.dom=document.createElement("div"),this.dom.classList.add("cm-tooltip-hover"),this.manager=new tg(e,Jo,(i,n)=>this.createHostedView(i,n),i=>i.dom.remove())}createHostedView(e,i){let n=e.create(this.view);return n.dom.classList.add("cm-tooltip-section"),this.dom.insertBefore(n.dom,i?i.dom.nextSibling:this.dom.firstChild),this.mounted&&n.mount&&n.mount(this.view),n}mount(e){for(let i of this.manager.tooltipViews)i.mount&&i.mount(e);this.mounted=!0}positioned(e){for(let i of this.manager.tooltipViews)i.positioned&&i.positioned(e)}update(e){this.manager.update(e)}destroy(){var e;for(let i of this.manager.tooltipViews)(e=i.destroy)===null||e===void 0||e.call(i)}passProp(e){let i;for(let n of this.manager.tooltipViews){let O=n[e];if(O!==void 0){if(i===void 0)i=O;else if(i!==O)return}}return i}get offset(){return this.passProp("offset")}get getCoords(){return this.passProp("getCoords")}get overlap(){return this.passProp("overlap")}get resize(){return this.passProp("resize")}}const OR=wh.compute([Jo],t=>{let e=t.facet(Jo);return e.length===0?null:{pos:Math.min(...e.map(i=>i.pos)),end:Math.max(...e.map(i=>{var n;return(n=i.end)!==null&&n!==void 0?n:i.pos})),create:ea.create,above:e[0].above,arrow:e.some(i=>i.arrow)}}),Og=Z.define();class rR{constructor(e,i,n,O,r,s){this.view=e,this.source=i,this.field=n,this.locked=O,this.setHover=r,this.hoverTime=s,this.hoverTimeout=-1,this.restartTimeout=-1,this.pending=null,this.lastMove={x:0,y:0,target:e.dom,time:0},this.checkHover=this.checkHover.bind(this),e.dom.addEventListener("mouseleave",this.mouseleave=this.mouseleave.bind(this)),e.dom.addEventListener("mousemove",this.mousemove=this.mousemove.bind(this))}update(e){this.pending&&(this.pending=null,clearTimeout(this.restartTimeout),this.restartTimeout=setTimeout(()=>this.startHover(),20))}get active(){return this.view.state.field(this.field)}checkHover(){if(this.hoverTimeout=-1,this.active.length)return;let e=Date.now()-this.lastMove.time;es.bottom||i.xs.right+e.defaultCharacterWidth)return;let o=e.bidiSpans(e.state.doc.lineAt(O)).find(l=>l.from<=O&&l.to>=O),a=o&&o.dir==ge.RTL?-1:1;r=i.x{if(o&&!(Array.isArray(o)&&!o.length)){let a=Array.isArray(o)?o:[o];O&&this.locked.set(a,O),e.dispatch({effects:this.setHover.of(a)})}};if(r&&"then"in r){let o=this.pending={pos:i};r.then(a=>{this.pending==o&&(this.pending=null,s(a))},a=>Tt(e.state,a,"hover tooltip"))}else s(r)}get tooltip(){let e=this.view.plugin(Th),i=e?e.manager.tooltips.findIndex(n=>n.create==ea.create):-1;return i>-1?e.manager.tooltipViews[i]:null}mousemove(e){var i,n;this.lastMove={x:e.clientX,y:e.clientY,target:e.target,time:Date.now()},this.hoverTimeout<0&&(this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime));let{active:O,tooltip:r}=this;if(O.length&&!this.locked.has(O)&&r&&!sR(r.dom,e)||this.pending){let{pos:s}=O[0]||this.pending,o=(n=(i=O[0])===null||i===void 0?void 0:i.end)!==null&&n!==void 0?n:s;(s==o?this.view.posAtCoords(this.lastMove)!=s:!oR(this.view,s,o,e.clientX,e.clientY))&&(this.view.dispatch({effects:this.setHover.of([])}),this.pending=null)}}mouseleave(e){clearTimeout(this.hoverTimeout),this.hoverTimeout=-1;let{active:i}=this;if(i.length&&!this.locked.has(i)){let{tooltip:n}=this;n&&n.dom.contains(e.relatedTarget)?this.watchTooltipLeave(n.dom):this.view.dispatch({effects:this.setHover.of([])})}}watchTooltipLeave(e){let i=n=>{e.removeEventListener("mouseleave",i);let{active:O}=this;O.length&&!this.locked.has(O)&&!this.view.dom.contains(n.relatedTarget)&&this.view.dispatch({effects:this.setHover.of([])})};e.addEventListener("mouseleave",i)}destroy(){clearTimeout(this.hoverTimeout),clearTimeout(this.restartTimeout),this.view.dom.removeEventListener("mouseleave",this.mouseleave),this.view.dom.removeEventListener("mousemove",this.mousemove)}}const ta=4;function sR(t,e){let{left:i,right:n,top:O,bottom:r}=t.getBoundingClientRect(),s;if(s=t.querySelector(".cm-tooltip-arrow")){let o=s.getBoundingClientRect();O=Math.min(o.top,O),r=Math.max(o.bottom,r)}return e.clientX>=i-ta&&e.clientX<=n+ta&&e.clientY>=O-ta&&e.clientY<=r+ta}function oR(t,e,i,n,O,r){let s=t.scrollDOM.getBoundingClientRect(),o=t.documentTop+t.documentPadding.top+t.contentHeight;if(s.left>n||s.rightO||Math.min(s.bottom,o)=e&&a<=i}function aR(t,e={}){let i=K.define(),n=new WeakMap,O=nt.define({create(){return[]},update(s,o){let a=n.get(s);if(s.length&&(e.hideOnChange&&(o.docChanged||o.selection)?s=[]:a&&a(o)?s=[]:e.hideOn&&(s=s.filter(l=>!e.hideOn(o,l)))),o.docChanged&&s.length){let l=[];for(let c of s){let h=o.changes.mapPos(c.pos,-1,it.TrackDel);if(h!=null){let d=Object.assign(Object.create(null),c);d.pos=h,d.end!=null&&(d.end=o.changes.mapPos(d.end)),l.push(d)}}s=l}for(let l of o.effects)l.is(i)&&(s=l.value,a=void 0),(l.is(cR)&&!l.value||l.value==O)&&(s=[]);return s.length&&a&&n.set(s,a),s},provide:s=>Jo.from(s)});const r=We.define(s=>new rR(s,t,O,n,i,e.hoverTime||300));return{active:O,extension:[O,r,Og.of(r),OR]}}function lR(t,e,i,n={}){var O;let r=t.state.facet(Og).map(s=>t.plugin(s)).filter(s=>!!s);if(n.tooltip&&n.tooltip.active){let s=r.find(o=>o.field==n.tooltip.active);s&&(r=[s])}for(let s of r)s.activateHover(t,e,i,(O=n.until)!==null&&O!==void 0?O:()=>!1)}function rg(t,e){let i=t.plugin(Th);if(!i)return null;let n=i.manager.tooltips.indexOf(e);return n<0?null:i.manager.tooltipViews[n]}const cR=K.define(),sg=Z.define({combine(t){let e,i;for(let n of t)e=e||n.topContainer,i=i||n.bottomContainer;return{topContainer:e,bottomContainer:i}}});function vh(t,e){let i=t.plugin(og),n=i?i.specs.indexOf(e):-1;return n>-1?i.panels[n]:null}const og=We.fromClass(class{constructor(t){this.input=t.state.facet(Mr),this.specs=this.input.filter(i=>i),this.panels=this.specs.map(i=>i(t));let e=t.state.facet(sg);this.top=new ia(t,!0,e.topContainer),this.bottom=new ia(t,!1,e.bottomContainer),this.top.sync(this.panels.filter(i=>i.top)),this.bottom.sync(this.panels.filter(i=>!i.top));for(let i of this.panels)i.dom.classList.add("cm-panel"),i.mount&&i.mount()}update(t){let e=t.state.facet(sg);this.top.container!=e.topContainer&&(this.top.sync([]),this.top=new ia(t.view,!0,e.topContainer)),this.bottom.container!=e.bottomContainer&&(this.bottom.sync([]),this.bottom=new ia(t.view,!1,e.bottomContainer)),this.top.syncClasses(),this.bottom.syncClasses();let i=t.state.facet(Mr);if(i!=this.input){let n=i.filter(a=>a),O=[],r=[],s=[],o=[];for(let a of n){let l=this.specs.indexOf(a),c;l<0?(c=a(t.view),o.push(c)):(c=this.panels[l],c.update&&c.update(t)),O.push(c),(c.top?r:s).push(c)}this.specs=n,this.panels=O,this.top.sync(r),this.bottom.sync(s);for(let a of o)a.dom.classList.add("cm-panel"),a.mount&&a.mount()}else for(let n of this.panels)n.update&&n.update(t)}destroy(){this.top.sync([]),this.bottom.sync([])}},{provide:t=>R.scrollMargins.of(e=>{let i=e.plugin(t);return i&&{top:i.top.scrollMargin(),bottom:i.bottom.scrollMargin()}})});class ia{constructor(e,i,n){this.view=e,this.top=i,this.container=n,this.dom=void 0,this.classes="",this.panels=[],this.syncClasses()}sync(e){for(let i of this.panels)i.destroy&&e.indexOf(i)<0&&i.destroy();this.panels=e,this.syncDOM()}syncDOM(){if(this.panels.length==0){this.dom&&(this.dom.remove(),this.dom=void 0);return}if(!this.dom){this.dom=document.createElement("div"),this.dom.className=this.top?"cm-panels cm-panels-top":"cm-panels cm-panels-bottom",this.dom.style[this.top?"top":"bottom"]="0";let i=this.container||this.view.dom;i.insertBefore(this.dom,this.top?i.firstChild:null)}let e=this.dom.firstChild;for(let i of this.panels)if(i.dom.parentNode==this.dom){for(;e!=i.dom;)e=ag(e);e=e.nextSibling}else this.dom.insertBefore(i.dom,e);for(;e;)e=ag(e)}scrollMargin(){return!this.dom||this.container?0:Math.max(0,this.top?this.dom.getBoundingClientRect().bottom-Math.max(0,this.view.scrollDOM.getBoundingClientRect().top):Math.min(innerHeight,this.view.scrollDOM.getBoundingClientRect().bottom)-this.dom.getBoundingClientRect().top)}syncClasses(){if(!(!this.container||this.classes==this.view.themeClasses)){for(let e of this.classes.split(" "))e&&this.container.classList.remove(e);for(let e of(this.classes=this.view.themeClasses).split(" "))e&&this.container.classList.add(e)}}}function ag(t){let e=t.nextSibling;return t.remove(),e}const Mr=Z.define({enables:og});function hR(t,e){let i,n=new Promise(s=>i=s),O=s=>dR(s,e,i);t.state.field(kh,!1)?t.dispatch({effects:lg.of(O)}):t.dispatch({effects:K.appendConfig.of(kh.init(()=>[O]))});let r=cg.of(O);return{close:r,result:n.then(s=>((t.win.queueMicrotask||(a=>t.win.setTimeout(a,10)))(()=>{t.state.field(kh).indexOf(O)>-1&&t.dispatch({effects:r})}),s))}}const kh=nt.define({create(){return[]},update(t,e){for(let i of e.effects)i.is(lg)?t=[i.value].concat(t):i.is(cg)&&(t=t.filter(n=>n!=i.value));return t},provide:t=>Mr.computeN([t],e=>e.field(t))}),lg=K.define(),cg=K.define();function dR(t,e,i){let n=e.content?e.content(t,()=>s(null)):null;if(!n){if(n=pe("form"),e.input){let o=pe("input",e.input);/^(text|password|number|email|tel|url)$/.test(o.type)&&o.classList.add("cm-textfield"),o.name||(o.name="input"),n.appendChild(pe("label",(e.label||"")+": ",o))}else n.appendChild(document.createTextNode(e.label||""));n.appendChild(document.createTextNode(" ")),n.appendChild(pe("button",{class:"cm-button",type:"submit"},e.submitLabel||"OK"))}let O=n.nodeName=="FORM"?[n]:n.querySelectorAll("form");for(let o=0;o{l.keyCode==27?(l.preventDefault(),s(null)):l.keyCode==13&&(l.preventDefault(),s(a))}),a.addEventListener("submit",l=>{l.preventDefault(),s(a)})}let r=pe("div",n,pe("button",{onclick:()=>s(null),"aria-label":t.state.phrase("close"),class:"cm-dialog-close",type:"button"},["×"]));e.class&&(r.className=e.class),r.classList.add("cm-dialog");function s(o){r.contains(r.ownerDocument.activeElement)&&t.focus(),i(o)}return{dom:r,top:e.top,mount:()=>{if(e.focus){let o;typeof e.focus=="string"?o=n.querySelector(e.focus):o=n.querySelector("input")||n.querySelector("button"),o&&"select"in o?o.select():o&&"focus"in o&&o.focus()}}}}class Di extends un{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}}Di.prototype.elementClass="",Di.prototype.toDOM=void 0,Di.prototype.mapMode=it.TrackBefore,Di.prototype.startSide=Di.prototype.endSide=-1,Di.prototype.point=!0;const na=Z.define(),uR=Z.define(),fR={class:"",renderEmptyElements:!1,elementStyle:"",markers:()=>re.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{},side:"before"},Dr=Z.define();function $R(t){return[dg(),Dr.of({...fR,...t})]}const hg=Z.define({combine:t=>t.some(e=>e)});function dg(t){return[QR]}const QR=We.fromClass(class{constructor(t){this.view=t,this.domAfter=null,this.prevViewport=t.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters cm-gutters-before",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=t.state.facet(Dr).map(e=>new fg(t,e)),this.fixed=!t.state.facet(hg);for(let e of this.gutters)e.config.side=="after"?this.getDOMAfter().appendChild(e.dom):this.dom.appendChild(e.dom);this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),t.scrollDOM.insertBefore(this.dom,t.contentDOM)}getDOMAfter(){return this.domAfter||(this.domAfter=document.createElement("div"),this.domAfter.className="cm-gutters cm-gutters-after",this.domAfter.setAttribute("aria-hidden","true"),this.domAfter.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.domAfter.style.position=this.fixed?"sticky":"",this.view.scrollDOM.appendChild(this.domAfter)),this.domAfter}update(t){if(this.updateGutters(t)){let e=this.prevViewport,i=t.view.viewport,n=Math.min(e.to,i.to)-Math.max(e.from,i.from);this.syncGutters(n<(i.to-i.from)*.8)}if(t.geometryChanged){let e=this.view.contentHeight/this.view.scaleY+"px";this.dom.style.minHeight=e,this.domAfter&&(this.domAfter.style.minHeight=e)}this.view.state.facet(hg)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":"",this.domAfter&&(this.domAfter.style.position=this.fixed?"sticky":"")),this.prevViewport=t.view.viewport}syncGutters(t){let e=this.dom.nextSibling;t&&(this.dom.remove(),this.domAfter&&this.domAfter.remove());let i=re.iter(this.view.state.facet(na),this.view.viewport.from),n=[],O=this.gutters.map(r=>new pR(r,this.view.viewport,-this.view.documentPadding.top));for(let r of this.view.viewportLineBlocks)if(n.length&&(n=[]),Array.isArray(r.type)){let s=!0;for(let o of r.type)if(o.type==rt.Text&&s){_h(i,n,o.from);for(let a of O)a.line(this.view,o,n);s=!1}else if(o.widget)for(let a of O)a.widget(this.view,o)}else if(r.type==rt.Text){_h(i,n,r.from);for(let s of O)s.line(this.view,r,n)}else if(r.widget)for(let s of O)s.widget(this.view,r);for(let r of O)r.finish();t&&(this.view.scrollDOM.insertBefore(this.dom,e),this.domAfter&&this.view.scrollDOM.appendChild(this.domAfter))}updateGutters(t){let e=t.startState.facet(Dr),i=t.state.facet(Dr),n=t.docChanged||t.heightChanged||t.viewportChanged||!re.eq(t.startState.facet(na),t.state.facet(na),t.view.viewport.from,t.view.viewport.to);if(e==i)for(let O of this.gutters)O.update(t)&&(n=!0);else{n=!0;let O=[];for(let r of i){let s=e.indexOf(r);s<0?O.push(new fg(this.view,r)):(this.gutters[s].update(t),O.push(this.gutters[s]))}for(let r of this.gutters)r.dom.remove(),O.indexOf(r)<0&&r.destroy();for(let r of O)r.config.side=="after"?this.getDOMAfter().appendChild(r.dom):this.dom.appendChild(r.dom);this.gutters=O}return n}destroy(){for(let t of this.gutters)t.destroy();this.dom.remove(),this.domAfter&&this.domAfter.remove()}},{provide:t=>R.scrollMargins.of(e=>{let i=e.plugin(t);if(!i||i.gutters.length==0||!i.fixed)return null;let n=i.dom.offsetWidth*e.scaleX,O=i.domAfter?i.domAfter.offsetWidth*e.scaleX:0;return e.textDirection==ge.LTR?{left:n,right:O}:{right:n,left:O}})});function ug(t){return Array.isArray(t)?t:[t]}function _h(t,e,i){for(;t.value&&t.from<=i;)t.from==i&&e.push(t.value),t.next()}class pR{constructor(e,i,n){this.gutter=e,this.height=n,this.i=0,this.cursor=re.iter(e.markers,i.from)}addElement(e,i,n){let{gutter:O}=this,r=(i.top-this.height)/e.scaleY,s=i.height/e.scaleY;if(this.i==O.elements.length){let o=new $g(e,s,r,n);O.elements.push(o),O.dom.appendChild(o.dom)}else O.elements[this.i].update(e,s,r,n);this.height=i.bottom,this.i++}line(e,i,n){let O=[];_h(this.cursor,O,i.from),n.length&&(O=O.concat(n));let r=this.gutter.config.lineMarker(e,i,O);r&&O.unshift(r);let s=this.gutter;O.length==0&&!s.config.renderEmptyElements||this.addElement(e,i,O)}widget(e,i){let n=this.gutter.config.widgetMarker(e,i.widget,i),O=n?[n]:null;for(let r of e.state.facet(uR)){let s=r(e,i.widget,i);s&&(O||(O=[])).push(s)}O&&this.addElement(e,i,O)}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let i=e.elements.pop();e.dom.removeChild(i.dom),i.destroy()}}}class fg{constructor(e,i){this.view=e,this.config=i,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:"");for(let n in i.domEventHandlers)this.dom.addEventListener(n,O=>{let r=O.target,s;if(r!=this.dom&&this.dom.contains(r)){for(;r.parentNode!=this.dom;)r=r.parentNode;let a=r.getBoundingClientRect();s=(a.top+a.bottom)/2}else s=O.clientY;let o=e.lineBlockAtHeight(s-e.documentTop);i.domEventHandlers[n](e,o,O)&&O.preventDefault()});this.markers=ug(i.markers(e)),i.initialSpacer&&(this.spacer=new $g(e,0,0,[i.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let i=this.markers;if(this.markers=ug(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let O=this.config.updateSpacer(this.spacer.markers[0],e);O!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[O])}let n=e.view.viewport;return!re.eq(this.markers,i,n.from,n.to)||(this.config.lineMarkerChange?this.config.lineMarkerChange(e):!1)}destroy(){for(let e of this.elements)e.destroy()}}class $g{constructor(e,i,n,O){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,i,n,O)}update(e,i,n,O){this.height!=i&&(this.height=i,this.dom.style.height=i+"px"),this.above!=n&&(this.dom.style.marginTop=(this.above=n)?n+"px":""),mR(this.markers,O)||this.setMarkers(e,O)}setMarkers(e,i){let n="cm-gutterElement",O=this.dom.firstChild;for(let r=0,s=0;;){let o=s,a=rr(o,a,l)||s(o,a,l):s}return n}})}});class Rh extends Di{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}}function Zh(t,e){return t.state.facet(kO).formatNumber(e,t.state)}const SR=Dr.compute([kO],t=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers(e){return e.state.facet(gR)},lineMarker(e,i,n){return n.some(O=>O.toDOM)?null:new Rh(Zh(e,e.state.doc.lineAt(i.from).number))},widgetMarker:(e,i,n)=>{for(let O of e.state.facet(PR)){let r=O(e,i,n);if(r)return r}return null},lineMarkerChange:e=>e.startState.facet(kO)!=e.state.facet(kO),initialSpacer(e){return new Rh(Zh(e,Qg(e.state.doc.lines)))},updateSpacer(e,i){let n=Zh(i.view,Qg(i.view.state.doc.lines));return n==e.number?e:new Rh(n)},domEventHandlers:t.facet(kO).domEventHandlers,side:"before"}));function XR(t={}){return[kO.of(t),dg(),SR]}function Qg(t){let e=9;for(;e{let e=[],i=-1;for(let n of t.selection.ranges){let O=t.doc.lineAt(n.head).from;O>i&&(i=O,e.push(bR.range(O)))}return re.of(e)});function xR(){return yR}const pg=1024;let TR=0;class Nt{constructor(e,i){this.from=e,this.to=i}}class F{constructor(e={}){this.id=TR++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw new Error("This node type doesn't define a deserialize function")}),this.combine=e.combine||null}add(e){if(this.perNode)throw new RangeError("Can't add per-node props to node types");return typeof e!="function"&&(e=Ee.match(e)),i=>{let n=e(i);return n===void 0?null:[this,n]}}}F.closedBy=new F({deserialize:t=>t.split(" ")}),F.openedBy=new F({deserialize:t=>t.split(" ")}),F.group=new F({deserialize:t=>t.split(" ")}),F.isolate=new F({deserialize:t=>{if(t&&t!="rtl"&&t!="ltr"&&t!="auto")throw new RangeError("Invalid value for isolate: "+t);return t||"auto"}}),F.contextHash=new F({perNode:!0}),F.lookAhead=new F({perNode:!0}),F.mounted=new F({perNode:!0});class _O{constructor(e,i,n,O=!1){this.tree=e,this.overlay=i,this.parser=n,this.bracketed=O}static get(e){return e&&e.props&&e.props[F.mounted.id]}}const wR=Object.create(null);class Ee{constructor(e,i,n,O=0){this.name=e,this.props=i,this.id=n,this.flags=O}static define(e){let i=e.props&&e.props.length?Object.create(null):wR,n=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(e.name==null?8:0),O=new Ee(e.name||"",i,e.id,n);if(e.props){for(let r of e.props)if(Array.isArray(r)||(r=r(O)),r){if(r[0].perNode)throw new RangeError("Can't store a per-node prop on a node type");i[r[0].id]=r[1]}}return O}prop(e){return this.props[e.id]}get isTop(){return(this.flags&1)>0}get isSkipped(){return(this.flags&2)>0}get isError(){return(this.flags&4)>0}get isAnonymous(){return(this.flags&8)>0}is(e){if(typeof e=="string"){if(this.name==e)return!0;let i=this.prop(F.group);return i?i.indexOf(e)>-1:!1}return this.id==e}static match(e){let i=Object.create(null);for(let n in e)for(let O of n.split(" "))i[O]=e[n];return n=>{for(let O=n.prop(F.group),r=-1;r<(O?O.length:0);r++){let s=i[r<0?n.name:O[r]];if(s)return s}}}}Ee.none=new Ee("",Object.create(null),0,8);class RO{constructor(e){this.types=e;for(let i=0;i0;for(let a=this.cursor(s|fe.IncludeAnonymous);;){let l=!1;if(a.from<=r&&a.to>=O&&(!o&&a.type.isAnonymous||i(a)!==!1)){if(a.firstChild())continue;l=!0}for(;l&&n&&(o||!a.type.isAnonymous)&&n(a),!a.nextSibling();){if(!a.parent())return;l=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let i in this.props)e.push([+i,this.props[i]]);return e}balance(e={}){return this.children.length<=8?this:qh(Ee.none,this.children,this.positions,0,this.children.length,0,this.length,(i,n,O)=>new ne(this.type,i,n,O,this.propValues),e.makeTree||((i,n,O)=>new ne(Ee.none,i,n,O)))}static build(e){return RR(e)}}ne.empty=new ne(Ee.none,[],[],0);class Yh{constructor(e,i){this.buffer=e,this.index=i}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new Yh(this.buffer,this.index)}}class mn{constructor(e,i,n){this.buffer=e,this.length=i,this.set=n}get type(){return Ee.none}toString(){let e=[];for(let i=0;i0));a=s[a+3]);return o}slice(e,i,n){let O=this.buffer,r=new Uint16Array(i-e),s=0;for(let o=e,a=0;o=e&&ie;case 1:return i<=e&&n>e;case 2:return n>e;case 4:return!0}}function Lr(t,e,i,n){for(var O;t.from==t.to||(i<1?t.from>=e:t.from>e)||(i>-1?t.to<=e:t.to0?o.length:-1;e!=l;e+=i){let c=o[e],h=a[e]+s.from,d;if(!(!(r&fe.EnterBracketed&&c instanceof ne&&(d=_O.get(c))&&!d.overlay&&d.bracketed&&n>=h&&n<=h+c.length)&&!gg(O,n,h,h+c.length))){if(c instanceof mn){if(r&fe.ExcludeBuffers)continue;let u=c.findChild(0,c.buffer.length,i,n-h,O);if(u>-1)return new Ti(new vR(s,c,e,h),null,u)}else if(r&fe.IncludeAnonymous||!c.type.isAnonymous||Vh(c)){let u;if(!(r&fe.IgnoreMounts)&&(u=_O.get(c))&&!u.overlay)return new Qt(u.tree,h,e,s);let $=new Qt(c,h,e,s);return r&fe.IncludeAnonymous||!$.type.isAnonymous?$:$.nextChild(i<0?c.children.length-1:0,i,n,O,r)}}}if(r&fe.IncludeAnonymous||!s.type.isAnonymous||(s.index>=0?e=s.index+i:e=i<0?-1:s._parent._tree.children.length,s=s._parent,!s))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}prop(e){return this._tree.prop(e)}enter(e,i,n=0){let O;if(!(n&fe.IgnoreOverlays)&&(O=_O.get(this._tree))&&O.overlay){let r=e-this.from,s=n&fe.EnterBracketed&&O.bracketed;for(let{from:o,to:a}of O.overlay)if((i>0||s?o<=r:o=r:a>r))return new Qt(O.tree,O.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,i,n)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}}function Sg(t,e,i,n){let O=t.cursor(),r=[];if(!O.firstChild())return r;if(i!=null){for(let s=!1;!s;)if(s=O.type.is(i),!O.nextSibling())return r}for(;;){if(n!=null&&O.type.is(n))return r;if(O.type.is(e)&&r.push(O.node),!O.nextSibling())return n==null?r:[]}}function zh(t,e,i=e.length-1){for(let n=t;i>=0;n=n.parent){if(!n)return!1;if(!n.type.isAnonymous){if(e[i]&&e[i]!=n.name)return!1;i--}}return!0}class vR{constructor(e,i,n,O){this.parent=e,this.buffer=i,this.index=n,this.start=O}}class Ti extends Pg{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,i,n){super(),this.context=e,this._parent=i,this.index=n,this.type=e.buffer.set.types[e.buffer.buffer[n]]}child(e,i,n){let{buffer:O}=this.context,r=O.findChild(this.index+4,O.buffer[this.index+3],e,i-this.context.start,n);return r<0?null:new Ti(this.context,this,r)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}prop(e){return this.type.prop(e)}enter(e,i,n=0){if(n&fe.ExcludeBuffers)return null;let{buffer:O}=this.context,r=O.findChild(this.index+4,O.buffer[this.index+3],i>0?1:-1,e-this.context.start,i);return r<0?null:new Ti(this.context,this,r)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,i=e.buffer[this.index+3];return i<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new Ti(this.context,this._parent,i):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,i=this._parent?this._parent.index+4:0;return this.index==i?this.externalSibling(-1):new Ti(this.context,this._parent,e.findChild(i,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],i=[],{buffer:n}=this.context,O=this.index+4,r=n.buffer[this.index+3];if(r>O){let s=n.buffer[this.index+1];e.push(n.slice(O,r,s)),i.push(0)}return new ne(this.type,e,i,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}}function Xg(t){if(!t.length)return null;let e=0,i=t[0];for(let r=1;ri.from||s.to=e){let o=new Qt(s.tree,s.overlay[0].from+r.from,-1,r);(O||(O=[n])).push(Lr(o,e,i,!1))}}return O?Xg(O):n}class ra{get name(){return this.type.name}constructor(e,i=0){if(this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,this.mode=i&~fe.EnterBracketed,e instanceof Qt)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let n=e._parent;n;n=n._parent)this.stack.unshift(n.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return e?(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0):!1}yieldBuf(e,i){this.index=e;let{start:n,buffer:O}=this.buffer;return this.type=i||O.set.types[O.buffer[e]],this.from=n+O.buffer[e+1],this.to=n+O.buffer[e+2],!0}yield(e){return e?e instanceof Qt?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)):!1}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,i,n){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,i,n,this.mode));let{buffer:O}=this.buffer,r=O.findChild(this.index+4,O.buffer[this.index+3],e,i-this.buffer.start,n);return r<0?!1:(this.stack.push(this.index),this.yieldBuf(r))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,i,n=this.mode){return this.buffer?n&fe.ExcludeBuffers?!1:this.enterChild(1,e,i):this.yield(this._tree.enter(e,i,n))}parent(){if(!this.buffer)return this.yieldNode(this.mode&fe.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&fe.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return this._tree._parent?this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode)):!1;let{buffer:i}=this.buffer,n=this.stack.length-1;if(e<0){let O=n<0?0:this.stack[n]+4;if(this.index!=O)return this.yieldBuf(i.findChild(O,this.index,-1,0,4))}else{let O=i.buffer[this.index+3];if(O<(n<0?i.buffer.length:i.buffer[this.stack[n]+3]))return this.yieldBuf(O)}return n<0?this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode)):!1}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let i,n,{buffer:O}=this;if(O){if(e>0){if(this.index-1)for(let r=i+e,s=e<0?-1:n._tree.children.length;r!=s;r+=e){let o=n._tree.children[r];if(this.mode&fe.IncludeAnonymous||o instanceof mn||!o.type.isAnonymous||Vh(o))return!1}return!0}move(e,i){if(i&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,i=0){for(;(this.from==this.to||(i<1?this.from>=e:this.from>e)||(i>-1?this.to<=e:this.to=0;){for(let s=e;s;s=s._parent)if(s.index==O){if(O==this.index)return s;i=s,n=r+1;break e}O=this.stack[--r]}for(let O=n;O=0;r--){if(r<0)return zh(this._tree,e,O);let s=n[i.buffer[this.stack[r]]];if(!s.isAnonymous){if(e[O]&&e[O]!=s.name)return!1;O--}}return!0}}function Vh(t){return t.children.some(e=>e instanceof mn||!e.type.isAnonymous||Vh(e))}function RR(t){var e;let{buffer:i,nodeSet:n,maxBufferLength:O=pg,reused:r=[],minRepeatType:s=n.types.length}=t,o=Array.isArray(i)?new Yh(i,i.length):i,a=n.types,l=0,c=0;function h(X,y,T,C,G,J){let{id:j,start:V,end:B,size:L}=o,Oe=c,te=l;if(L<0)if(o.next(),L==-1){let dt=r[j];T.push(dt),C.push(V-X);return}else if(L==-3){l=j;return}else if(L==-4){c=j;return}else throw new RangeError(`Unrecognized record size: ${L}`);let he=a[j],ue,Qe,Ye=V-X;if(B-V<=O&&(Qe=p(o.pos-y,G))){let dt=new Uint16Array(Qe.size-Qe.skip),ze=o.pos-Qe.size,Ke=dt.length;for(;o.pos>ze;)Ke=m(Qe.start,dt,Ke);ue=new mn(dt,B-Qe.start,n),Ye=Qe.start-X}else{let dt=o.pos-L;o.next();let ze=[],Ke=[],Rt=j>=s?j:-1,mt=0,At=B;for(;o.pos>dt;)Rt>=0&&o.id==Rt&&o.size>=0?(o.end<=At-O&&($(ze,Ke,V,mt,o.end,At,Rt,Oe,te),mt=ze.length,At=o.end),o.next()):J>2500?d(V,dt,ze,Ke):h(V,dt,ze,Ke,Rt,J+1);if(Rt>=0&&mt>0&&mt-1&&mt>0){let Xt=u(he,te);ue=qh(he,ze,Ke,0,ze.length,0,B-V,Xt,Xt)}else ue=Q(he,ze,Ke,B-V,Oe-B,te)}T.push(ue),C.push(Ye)}function d(X,y,T,C){let G=[],J=0,j=-1;for(;o.pos>y;){let{id:V,start:B,end:L,size:Oe}=o;if(Oe>4)o.next();else{if(j>-1&&B=0;L-=3)V[Oe++]=G[L],V[Oe++]=G[L+1]-B,V[Oe++]=G[L+2]-B,V[Oe++]=Oe;T.push(new mn(V,G[2]-B,n)),C.push(B-X)}}function u(X,y){return(T,C,G)=>{let J=0,j=T.length-1,V,B;if(j>=0&&(V=T[j])instanceof ne){if(!j&&V.type==X&&V.length==G)return V;(B=V.prop(F.lookAhead))&&(J=C[j]+V.length+B)}return Q(X,T,C,G,J,y)}}function $(X,y,T,C,G,J,j,V,B){let L=[],Oe=[];for(;X.length>C;)L.push(X.pop()),Oe.push(y.pop()+T-G);X.push(Q(n.types[j],L,Oe,J-G,V-J,B)),y.push(G-T)}function Q(X,y,T,C,G,J,j){if(J){let V=[F.contextHash,J];j=j?[V].concat(j):[V]}if(G>25){let V=[F.lookAhead,G];j=j?[V].concat(j):[V]}return new ne(X,y,T,C,j)}function p(X,y){let T=o.fork(),C=0,G=0,J=0,j=T.end-O,V={size:0,start:0,skip:0};e:for(let B=T.pos-X;T.pos>B;){let L=T.size;if(T.id==y&&L>=0){V.size=C,V.start=G,V.skip=J,J+=4,C+=4,T.next();continue}let Oe=T.pos-L;if(L<0||Oe=s?4:0,he=T.start;for(T.next();T.pos>Oe;){if(T.size<0)if(T.size==-3||T.size==-4)te+=4;else break e;else T.id>=s&&(te+=4);T.next()}G=he,C+=L,J+=te}return(y<0||C==X)&&(V.size=C,V.start=G,V.skip=J),V.size>4?V:void 0}function m(X,y,T){let{id:C,start:G,end:J,size:j}=o;if(o.next(),j>=0&&C4){let B=o.pos-(j-4);for(;o.pos>B;)T=m(X,y,T)}y[--T]=V,y[--T]=J-X,y[--T]=G-X,y[--T]=C}else j==-3?l=C:j==-4&&(c=C);return T}let P=[],g=[];for(;o.pos>0;)h(t.start||0,t.bufferStart||0,P,g,-1,0);let b=(e=t.length)!==null&&e!==void 0?e:P.length?g[0]+P[0].length:0;return new ne(a[t.topID],P.reverse(),g.reverse(),b)}const bg=new WeakMap;function sa(t,e){if(!t.isAnonymous||e instanceof mn||e.type!=t)return 1;let i=bg.get(e);if(i==null){i=1;for(let n of e.children){if(n.type!=t||!(n instanceof ne)){i=1;break}i+=sa(t,n)}bg.set(e,i)}return i}function qh(t,e,i,n,O,r,s,o,a){let l=0;for(let $=n;$=c)break;y+=T}if(g==b+1){if(y>c){let T=$[b];u(T.children,T.positions,0,T.children.length,Q[b]+P);continue}h.push($[b])}else{let T=Q[g-1]+$[g-1].length-X;h.push(qh(t,$,Q,b,g,X,T,null,a))}d.push(X+P-r)}}return u(e,i,n,O,0),(o||a)(h,d,s)}class Uh{constructor(){this.map=new WeakMap}setBuffer(e,i,n){let O=this.map.get(e);O||this.map.set(e,O=new Map),O.set(i,n)}getBuffer(e,i){let n=this.map.get(e);return n&&n.get(i)}set(e,i){e instanceof Ti?this.setBuffer(e.context.buffer,e.index,i):e instanceof Qt&&this.map.set(e.tree,i)}get(e){return e instanceof Ti?this.getBuffer(e.context.buffer,e.index):e instanceof Qt?this.map.get(e.tree):void 0}cursorSet(e,i){e.buffer?this.setBuffer(e.buffer.buffer,e.index,i):this.map.set(e.tree,i)}cursorGet(e){return e.buffer?this.getBuffer(e.buffer.buffer,e.index):this.map.get(e.tree)}}class Li{constructor(e,i,n,O,r=!1,s=!1){this.from=e,this.to=i,this.tree=n,this.offset=O,this.open=(r?1:0)|(s?2:0)}get openStart(){return(this.open&1)>0}get openEnd(){return(this.open&2)>0}static addTree(e,i=[],n=!1){let O=[new Li(0,e.length,e,0,!1,n)];for(let r of i)r.to>e.length&&O.push(r);return O}static applyChanges(e,i,n=128){if(!i.length)return e;let O=[],r=1,s=e.length?e[0]:null;for(let o=0,a=0,l=0;;o++){let c=o=n)for(;s&&s.from=d.from||h<=d.to||l){let u=Math.max(d.from,a)-l,$=Math.min(d.to,h)-l;d=u>=$?null:new Li(u,$,d.tree,d.offset+l,o>0,!!c)}if(d&&O.push(d),s.to>h)break;s=rnew Nt(O.from,O.to)):[new Nt(0,0)]:[new Nt(0,e.length)],this.createParse(e,i||[],n)}parse(e,i,n){let O=this.startParse(e,i,n);for(;;){let r=O.advance();if(r)return r}}}class ZR{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,i){return this.string.slice(e,i)}}function aa(t){return(e,i,n,O)=>new zR(e,t,i,n,O)}class yg{constructor(e,i,n,O,r,s){this.parser=e,this.parse=i,this.overlay=n,this.bracketed=O,this.target=r,this.from=s}}function xg(t){if(!t.length||t.some(e=>e.from>=e.to))throw new RangeError("Invalid inner parse ranges given: "+JSON.stringify(t))}class YR{constructor(e,i,n,O,r,s,o,a){this.parser=e,this.predicate=i,this.mounts=n,this.index=O,this.start=r,this.bracketed=s,this.target=o,this.prev=a,this.depth=0,this.ranges=[]}}const Wh=new F({perNode:!0});class zR{constructor(e,i,n,O,r){this.nest=i,this.input=n,this.fragments=O,this.ranges=r,this.inner=[],this.innerDone=0,this.baseTree=null,this.stoppedAt=null,this.baseParse=e}advance(){if(this.baseParse){let n=this.baseParse.advance();if(!n)return null;if(this.baseParse=null,this.baseTree=n,this.startInner(),this.stoppedAt!=null)for(let O of this.inner)O.parse.stopAt(this.stoppedAt)}if(this.innerDone==this.inner.length){let n=this.baseTree;return this.stoppedAt!=null&&(n=new ne(n.type,n.children,n.positions,n.length,n.propValues.concat([[Wh,this.stoppedAt]]))),n}let e=this.inner[this.innerDone],i=e.parse.advance();if(i){this.innerDone++;let n=Object.assign(Object.create(null),e.target.props);n[F.mounted.id]=new _O(i,e.overlay,e.parser,e.bracketed),e.target.props=n}return null}get parsedPos(){if(this.baseParse)return 0;let e=this.input.length;for(let i=this.innerDone;i=this.stoppedAt)o=!1;else if(e.hasNode(O)){if(i){let l=i.mounts.find(c=>c.frag.from<=O.from&&c.frag.to>=O.to&&c.mount.overlay);if(l)for(let c of l.mount.overlay){let h=c.from+l.pos,d=c.to+l.pos;h>=O.from&&d<=O.to&&!i.ranges.some(u=>u.fromh)&&i.ranges.push({from:h,to:d})}}o=!1}else if(n&&(s=VR(n.ranges,O.from,O.to)))o=s!=2;else if(!O.type.isAnonymous&&(r=this.nest(O,this.input))&&(O.fromnew Nt(h.from-O.from,h.to-O.from)):null,!!r.bracketed,O.tree,c.length?c[0].from:O.from)),r.overlay?c.length&&(n={ranges:c,depth:0,prev:n}):o=!1}}else if(i&&(a=i.predicate(O))&&(a===!0&&(a=new Nt(O.from,O.to)),a.from=0&&i.ranges[l].to==a.from?i.ranges[l]={from:i.ranges[l].from,to:a.to}:i.ranges.push(a)}if(o&&O.firstChild())i&&i.depth++,n&&n.depth++;else for(;!O.nextSibling();){if(!O.parent())break e;if(i&&!--i.depth){let l=vg(this.ranges,i.ranges);l.length&&(xg(l),this.inner.splice(i.index,0,new yg(i.parser,i.parser.startParse(this.input,kg(i.mounts,l),l),i.ranges.map(c=>new Nt(c.from-i.start,c.to-i.start)),i.bracketed,i.target,l[0].from))),i=i.prev}n&&!--n.depth&&(n=n.prev)}}}}function VR(t,e,i){for(let n of t){if(n.from>=i)break;if(n.to>e)return n.from<=e&&n.to>=i?2:1}return 0}function Tg(t,e,i,n,O,r){if(e=e&&i.enter(n,1,fe.IgnoreOverlays|fe.ExcludeBuffers)))if(i.to<=e)i.next(!1)||(this.done=!0);else break}hasNode(e){if(this.moveTo(e.from),!this.done&&this.cursor.from+this.offset==e.from&&this.cursor.tree)for(let i=this.cursor.tree;;){if(i==e.tree)return!0;if(i.children.length&&i.positions[0]==0&&i.children[0]instanceof ne)i=i.children[0];else break}return!1}}let UR=class{constructor(e){var i;if(this.fragments=e,this.curTo=0,this.fragI=0,e.length){let n=this.curFrag=e[0];this.curTo=(i=n.tree.prop(Wh))!==null&&i!==void 0?i:n.to,this.inner=new wg(n.tree,-n.offset)}else this.curFrag=this.inner=null}hasNode(e){for(;this.curFrag&&e.from>=this.curTo;)this.nextFrag();return this.curFrag&&this.curFrag.from<=e.from&&this.curTo>=e.to&&this.inner.hasNode(e)}nextFrag(){var e;if(this.fragI++,this.fragI==this.fragments.length)this.curFrag=this.inner=null;else{let i=this.curFrag=this.fragments[this.fragI];this.curTo=(e=i.tree.prop(Wh))!==null&&e!==void 0?e:i.to,this.inner=new wg(i.tree,-i.offset)}}findMounts(e,i){var n;let O=[];if(this.inner){this.inner.cursor.moveTo(e,1);for(let r=this.inner.cursor.node;r;r=r.parent){let s=(n=r.tree)===null||n===void 0?void 0:n.prop(F.mounted);if(s&&s.parser==i)for(let o=this.fragI;o=r.to)break;a.tree==this.curFrag.tree&&O.push({frag:a,pos:r.from-a.offset,mount:s})}}}return O}};function vg(t,e){let i=null,n=e;for(let O=1,r=0;O=o)break;a.to<=s||(i||(n=i=e.slice()),a.fromo&&i.splice(r+1,0,new Nt(o,a.to))):a.to>o?i[r--]=new Nt(o,a.to):i.splice(r--,1))}}return n}function WR(t,e,i,n){let O=0,r=0,s=!1,o=!1,a=-1e9,l=[];for(;;){let c=O==t.length?1e9:s?t[O].to:t[O].from,h=r==e.length?1e9:o?e[r].to:e[r].from;if(s!=o){let d=Math.max(a,i),u=Math.min(c,h,n);dnew Nt(d.from+n,d.to+n)),h=WR(e,c,a,l);for(let d=0,u=a;;d++){let $=d==h.length,Q=$?l:h[d].from;if(Q>u&&i.push(new Li(u,Q,O.tree,-s,r.from>=u||r.openStart,r.to<=Q||r.openEnd)),$)break;u=h[d].to}}else i.push(new Li(a,l,O.tree,-s,r.from>=s||r.openStart,r.to<=o||r.openEnd))}return i}let CR=0,wi=class mf{constructor(e,i,n,O){this.name=e,this.set=i,this.base=n,this.modified=O,this.id=CR++}toString(){let{name:e}=this;for(let i of this.modified)i.name&&(e=`${i.name}(${e})`);return e}static define(e,i){let n=typeof e=="string"?e:"?";if(e instanceof mf&&(i=e),i?.base)throw new Error("Can not derive from a modified tag");let O=new mf(n,[],null,[]);if(O.set.push(O),i)for(let r of i.set)O.set.push(r);return O}static defineModifier(e){let i=new la(e);return n=>n.modified.indexOf(i)>-1?n:la.get(n.base||n,n.modified.concat(i).sort((O,r)=>O.id-r.id))}},jR=0;class la{constructor(e){this.name=e,this.instances=[],this.id=jR++}static get(e,i){if(!i.length)return e;let n=i[0].instances.find(o=>o.base==e&&GR(i,o.modified));if(n)return n;let O=[],r=new wi(e.name,O,e,i);for(let o of i)o.instances.push(r);let s=ER(i);for(let o of e.set)if(!o.modified.length)for(let a of s)O.push(la.get(o,a));return r}}function GR(t,e){return t.length==e.length&&t.every((i,n)=>i==e[n])}function ER(t){let e=[[]];for(let i=0;in.length-i.length)}function ot(t){let e=Object.create(null);for(let i in t){let n=t[i];Array.isArray(n)||(n=[n]);for(let O of i.split(" "))if(O){let r=[],s=2,o=O;for(let h=0;;){if(o=="..."&&h>0&&h+3==O.length){s=1;break}let d=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(o);if(!d)throw new RangeError("Invalid path: "+O);if(r.push(d[0]=="*"?"":d[0][0]=='"'?JSON.parse(d[0]):d[0]),h+=d[0].length,h==O.length)break;let u=O[h++];if(h==O.length&&u=="!"){s=0;break}if(u!="/")throw new RangeError("Invalid path: "+O);o=O.slice(h)}let a=r.length-1,l=r[a];if(!l)throw new RangeError("Invalid path: "+O);let c=new Nr(n,s,a>0?r.slice(0,a):null);e[l]=c.sort(e[l])}}return _g.add(e)}const _g=new F({combine(t,e){let i,n,O;for(;t||e;){if(!t||e&&t.depth>=e.depth?(O=e,e=e.next):(O=t,t=t.next),i&&i.mode==O.mode&&!O.context&&!i.context)continue;let r=new Nr(O.tags,O.mode,O.context);i?i.next=r:n=r,i=r}return n}});let Nr=class{constructor(e,i,n,O){this.tags=e,this.mode=i,this.context=n,this.next=O}get opaque(){return this.mode==0}get inherit(){return this.mode==1}sort(e){return!e||e.depth{let s=O;for(let o of r)for(let a of o.set){let l=i[a.id];if(l){s=s?s+" "+l:l;break}}return s},scope:n}}function IR(t,e){let i=null;for(let n of t){let O=n.style(e);O&&(i=i?i+" "+O:O)}return i}function AR(t,e,i,n=0,O=t.length){let r=new MR(n,Array.isArray(e)?e:[e],i);r.highlightRange(t.cursor(),n,O,"",r.highlighters),r.flush(O)}class MR{constructor(e,i,n){this.at=e,this.highlighters=i,this.span=n,this.class=""}startSpan(e,i){i!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=i)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,i,n,O,r){let{type:s,from:o,to:a}=e;if(o>=n||a<=i)return;s.isTop&&(r=this.highlighters.filter(u=>!u.scope||u.scope(s)));let l=O,c=DR(e)||Nr.empty,h=IR(r,c.tags);if(h&&(l&&(l+=" "),l+=h,c.mode==1&&(O+=(O?" ":"")+h)),this.startSpan(Math.max(i,o),l),c.opaque)return;let d=e.tree&&e.tree.prop(F.mounted);if(d&&d.overlay){let u=e.node.enter(d.overlay[0].from+o,1),$=this.highlighters.filter(p=>!p.scope||p.scope(d.tree.type)),Q=e.firstChild();for(let p=0,m=o;;p++){let P=p=g||!e.nextSibling())););if(!P||g>n)break;m=P.to+o,m>i&&(this.highlightRange(u.cursor(),Math.max(i,P.from+o),Math.min(n,m),"",$),this.startSpan(Math.min(n,m),l))}Q&&e.parent()}else if(e.firstChild()){d&&(O="");do if(!(e.to<=i)){if(e.from>=n)break;this.highlightRange(e,i,n,O,r),this.startSpan(Math.min(n,e.to),l)}while(e.nextSibling());e.parent()}}}function DR(t){let e=t.type.prop(_g);for(;e&&e.context&&!t.matchContext(e.context);)e=e.next;return e||null}const _=wi.define,ca=_(),gn=_(),Zg=_(gn),Yg=_(gn),Pn=_(),ha=_(Pn),Ch=_(Pn),vi=_(),In=_(vi),ki=_(),_i=_(),jh=_(),Br=_(jh),da=_(),f={comment:ca,lineComment:_(ca),blockComment:_(ca),docComment:_(ca),name:gn,variableName:_(gn),typeName:Zg,tagName:_(Zg),propertyName:Yg,attributeName:_(Yg),className:_(gn),labelName:_(gn),namespace:_(gn),macroName:_(gn),literal:Pn,string:ha,docString:_(ha),character:_(ha),attributeValue:_(ha),number:Ch,integer:_(Ch),float:_(Ch),bool:_(Pn),regexp:_(Pn),escape:_(Pn),color:_(Pn),url:_(Pn),keyword:ki,self:_(ki),null:_(ki),atom:_(ki),unit:_(ki),modifier:_(ki),operatorKeyword:_(ki),controlKeyword:_(ki),definitionKeyword:_(ki),moduleKeyword:_(ki),operator:_i,derefOperator:_(_i),arithmeticOperator:_(_i),logicOperator:_(_i),bitwiseOperator:_(_i),compareOperator:_(_i),updateOperator:_(_i),definitionOperator:_(_i),typeOperator:_(_i),controlOperator:_(_i),punctuation:jh,separator:_(jh),bracket:Br,angleBracket:_(Br),squareBracket:_(Br),paren:_(Br),brace:_(Br),content:vi,heading:In,heading1:_(In),heading2:_(In),heading3:_(In),heading4:_(In),heading5:_(In),heading6:_(In),contentSeparator:_(vi),list:_(vi),quote:_(vi),emphasis:_(vi),strong:_(vi),link:_(vi),monospace:_(vi),strikethrough:_(vi),inserted:_(),deleted:_(),changed:_(),invalid:_(),meta:da,documentMeta:_(da),annotation:_(da),processingInstruction:_(da),definition:wi.defineModifier("definition"),constant:wi.defineModifier("constant"),function:wi.defineModifier("function"),standard:wi.defineModifier("standard"),local:wi.defineModifier("local"),special:wi.defineModifier("special")};for(let t in f){let e=f[t];e instanceof wi&&(e.name=t)}Rg([{tag:f.link,class:"tok-link"},{tag:f.heading,class:"tok-heading"},{tag:f.emphasis,class:"tok-emphasis"},{tag:f.strong,class:"tok-strong"},{tag:f.keyword,class:"tok-keyword"},{tag:f.atom,class:"tok-atom"},{tag:f.bool,class:"tok-bool"},{tag:f.url,class:"tok-url"},{tag:f.labelName,class:"tok-labelName"},{tag:f.inserted,class:"tok-inserted"},{tag:f.deleted,class:"tok-deleted"},{tag:f.literal,class:"tok-literal"},{tag:f.string,class:"tok-string"},{tag:f.number,class:"tok-number"},{tag:[f.regexp,f.escape,f.special(f.string)],class:"tok-string2"},{tag:f.variableName,class:"tok-variableName"},{tag:f.local(f.variableName),class:"tok-variableName tok-local"},{tag:f.definition(f.variableName),class:"tok-variableName tok-definition"},{tag:f.special(f.variableName),class:"tok-variableName2"},{tag:f.definition(f.propertyName),class:"tok-propertyName tok-definition"},{tag:f.typeName,class:"tok-typeName"},{tag:f.namespace,class:"tok-namespace"},{tag:f.className,class:"tok-className"},{tag:f.macroName,class:"tok-macroName"},{tag:f.propertyName,class:"tok-propertyName"},{tag:f.operator,class:"tok-operator"},{tag:f.comment,class:"tok-comment"},{tag:f.meta,class:"tok-meta"},{tag:f.invalid,class:"tok-invalid"},{tag:f.punctuation,class:"tok-punctuation"}]);var Gh;const Sn=new F;function ua(t){return Z.define({combine:t?e=>e.concat(t):void 0})}const Eh=new F;class Wt{constructor(e,i,n=[],O=""){this.data=e,this.name=O,ae.prototype.hasOwnProperty("tree")||Object.defineProperty(ae.prototype,"tree",{get(){return $e(this)}}),this.parser=i,this.extension=[Xn.of(this),ae.languageData.of((r,s,o)=>{let a=zg(r,s,o),l=a.type.prop(Sn);if(!l)return[];let c=r.facet(l),h=a.type.prop(Eh);if(h){let d=a.resolve(s-a.from,o);for(let u of h)if(u.test(d,r)){let $=r.facet(u.facet);return u.type=="replace"?$:$.concat(c)}}return c})].concat(n)}isActiveAt(e,i,n=-1){return zg(e,i,n).type.prop(Sn)==this.data}findRegions(e){let i=e.facet(Xn);if(i?.data==this.data)return[{from:0,to:e.doc.length}];if(!i||!i.allowsNesting)return[];let n=[],O=(r,s)=>{if(r.prop(Sn)==this.data){n.push({from:s,to:s+r.length});return}let o=r.prop(F.mounted);if(o){if(o.tree.prop(Sn)==this.data){if(o.overlay)for(let a of o.overlay)n.push({from:a.from+s,to:a.to+s});else n.push({from:s,to:s+r.length});return}else if(o.overlay){let a=n.length;if(O(o.tree,o.overlay[0].from+s),n.length>a)return}}for(let a=0;an.isTop?i:void 0)]}),e.name)}configure(e,i){return new at(this.data,this.parser.configure(e),i||this.name)}get allowsNesting(){return this.parser.hasWrappers()}}function $e(t){let e=t.field(Wt.state,!1);return e?e.tree:ne.empty}class LR{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,i){let n=this.cursorPos-this.string.length;return e=this.cursorPos?this.doc.sliceString(e,i):this.string.slice(e-n,i-n)}}let Fr=null;class An{constructor(e,i,n=[],O,r,s,o,a){this.parser=e,this.state=i,this.fragments=n,this.tree=O,this.treeLen=r,this.viewport=s,this.skipped=o,this.scheduleOn=a,this.parse=null,this.tempSkipped=[]}static create(e,i,n){return new An(e,i,[],ne.empty,0,n,[],null)}startParse(){return this.parser.startParse(new LR(this.state.doc),this.fragments)}work(e,i){return i!=null&&i>=this.state.doc.length&&(i=void 0),this.tree!=ne.empty&&this.isDone(i??this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{var n;if(typeof e=="number"){let O=Date.now()+e;e=()=>Date.now()>O}for(this.parse||(this.parse=this.startParse()),i!=null&&(this.parse.stoppedAt==null||this.parse.stoppedAt>i)&&i=this.treeLen&&((this.parse.stoppedAt==null||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(i=this.parse.advance()););}),this.treeLen=e,this.tree=i,this.fragments=this.withoutTempSkipped(Li.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let i=Fr;Fr=this;try{return e()}finally{Fr=i}}withoutTempSkipped(e){for(let i;i=this.tempSkipped.pop();)e=Vg(e,i.from,i.to);return e}changes(e,i){let{fragments:n,tree:O,treeLen:r,viewport:s,skipped:o}=this;if(this.takeTree(),!e.empty){let a=[];if(e.iterChangedRanges((l,c,h,d)=>a.push({fromA:l,toA:c,fromB:h,toB:d})),n=Li.applyChanges(n,a),O=ne.empty,r=0,s={from:e.mapPos(s.from,-1),to:e.mapPos(s.to,1)},this.skipped.length){o=[];for(let l of this.skipped){let c=e.mapPos(l.from,1),h=e.mapPos(l.to,-1);ce.from&&(this.fragments=Vg(this.fragments,O,r),this.skipped.splice(n--,1))}return this.skipped.length>=i?!1:(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,i){this.skipped.push({from:e,to:i})}static getSkippingParser(e){return new class extends oa{createParse(i,n,O){let r=O[0].from,s=O[O.length-1].to;return{parsedPos:r,advance(){let a=Fr;if(a){for(let l of O)a.tempSkipped.push(l);e&&(a.scheduleOn=a.scheduleOn?Promise.all([a.scheduleOn,e]):e)}return this.parsedPos=s,new ne(Ee.none,[],[],s-r)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let i=this.fragments;return this.treeLen>=e&&i.length&&i[0].from==0&&i[0].to>=e}static get(){return Fr}}function Vg(t,e,i){return Li.applyChanges(t,[{fromA:e,toA:i,fromB:e,toB:i}])}class ZO{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let i=this.context.changes(e.changes,e.state),n=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),i.viewport.to);return i.work(20,n)||i.takeTree(),new ZO(i)}static init(e){let i=Math.min(3e3,e.doc.length),n=An.create(e.facet(Xn).parser,e,{from:0,to:i});return n.work(20,i)||n.takeTree(),new ZO(n)}}Wt.state=nt.define({create:ZO.init,update(t,e){for(let i of e.effects)if(i.is(Wt.setState))return i.value;return e.startState.facet(Xn)!=e.state.facet(Xn)?ZO.init(e.state):t.apply(e)}});let qg=t=>{let e=setTimeout(()=>t(),500);return()=>clearTimeout(e)};typeof requestIdleCallback<"u"&&(qg=t=>{let e=-1,i=setTimeout(()=>{e=requestIdleCallback(t,{timeout:400})},100);return()=>e<0?clearTimeout(i):cancelIdleCallback(e)});const Ih=typeof navigator<"u"&&(!((Gh=navigator.scheduling)===null||Gh===void 0)&&Gh.isInputPending)?()=>navigator.scheduling.isInputPending():null,NR=We.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let i=this.view.state.field(Wt.state).context;(i.updateViewport(e.view.viewport)||this.view.viewport.to>i.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(i)}scheduleWork(){if(this.working)return;let{state:e}=this.view,i=e.field(Wt.state);(i.tree!=i.context.tree||!i.context.isDone(e.doc.length))&&(this.working=qg(this.work))}work(e){this.working=null;let i=Date.now();if(this.chunkEndO+1e3,a=r.context.work(()=>Ih&&Ih()||Date.now()>s,O+(o?0:1e5));this.chunkBudget-=Date.now()-i,(a||this.chunkBudget<=0)&&(r.context.takeTree(),this.view.dispatch({effects:Wt.setState.of(new ZO(r.context))})),this.chunkBudget>0&&!(a&&!o)&&this.scheduleWork(),this.checkAsyncSchedule(r.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(i=>Tt(this.view.state,i)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),Xn=Z.define({combine(t){return t.length?t[0]:null},enables:t=>[Wt.state,NR,R.contentAttributes.compute([t],e=>{let i=e.facet(t);return i&&i.name?{"data-language":i.name}:{}})]});class Fe{constructor(e,i=[]){this.language=e,this.support=i,this.extension=[e,i]}}class fa{constructor(e,i,n,O,r,s=void 0){this.name=e,this.alias=i,this.extensions=n,this.filename=O,this.loadFunc=r,this.support=s,this.loading=null}load(){return this.loading||(this.loading=this.loadFunc().then(e=>this.support=e,e=>{throw this.loading=null,e}))}static of(e){let{load:i,support:n}=e;if(!i){if(!n)throw new RangeError("Must pass either 'load' or 'support' to LanguageDescription.of");i=()=>Promise.resolve(n)}return new fa(e.name,(e.alias||[]).concat(e.name).map(O=>O.toLowerCase()),e.extensions||[],e.filename,i,n)}static matchFilename(e,i){for(let O of e)if(O.filename&&O.filename.test(i))return O;let n=/\.([^.]+)$/.exec(i);if(n){for(let O of e)if(O.extensions.indexOf(n[1])>-1)return O}return null}static matchLanguageName(e,i,n=!0){i=i.toLowerCase();for(let O of e)if(O.alias.some(r=>r==i))return O;if(n)for(let O of e)for(let r of O.alias){let s=i.indexOf(r);if(s>-1&&(r.length>2||!/\w/.test(i[s-1])&&!/\w/.test(i[s+r.length])))return O}return null}}const BR=Z.define(),YO=Z.define({combine:t=>{if(!t.length)return" ";let e=t[0];if(!e||/\S/.test(e)||Array.from(e).some(i=>i!=e[0]))throw new Error("Invalid indent unit: "+JSON.stringify(t[0]));return e}});function Mn(t){let e=t.facet(YO);return e.charCodeAt(0)==9?t.tabSize*e.length:e.length}function Hr(t,e){let i="",n=t.tabSize,O=t.facet(YO)[0];if(O==" "){for(;e>=n;)i+=" ",e-=n;O=" "}for(let r=0;r=e?FR(t,i,e):null}class $a{constructor(e,i={}){this.state=e,this.options=i,this.unit=Mn(e)}lineAt(e,i=1){let n=this.state.doc.lineAt(e),{simulateBreak:O,simulateDoubleBreak:r}=this.options;return O!=null&&O>=n.from&&O<=n.to?r&&O==e?{text:"",from:e}:(i<0?O-1&&(r+=s-this.countColumn(n,n.search(/\S|$/))),r}countColumn(e,i=e.length){return Oi(e,this.state.tabSize,i)}lineIndent(e,i=1){let{text:n,from:O}=this.lineAt(e,i),r=this.options.overrideIndentation;if(r){let s=r(O);if(s>-1)return s}return this.countColumn(n,n.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}}const lt=new F;function FR(t,e,i){let n=e.resolveStack(i),O=e.resolveInner(i,-1).resolve(i,0).enterUnfinishedNodesBefore(i);if(O!=n.node){let r=[];for(let s=O;s&&!(s.fromn.node.to||s.from==n.node.from&&s.type==n.node.type);s=s.parent)r.push(s);for(let s=r.length-1;s>=0;s--)n={node:r[s],next:n}}return Ug(n,t,i)}function Ug(t,e,i){for(let n=t;n;n=n.next){let O=KR(n.node);if(O)return O(Mh.create(e,i,n))}return 0}function HR(t){return t.pos==t.options.simulateBreak&&t.options.simulateDoubleBreak}function KR(t){let e=t.type.prop(lt);if(e)return e;let i=t.firstChild,n;if(i&&(n=i.type.prop(F.closedBy))){let O=t.lastChild,r=O&&n.indexOf(O.name)>-1;return s=>Wg(s,!0,1,void 0,r&&!HR(s)?O.from:void 0)}return t.parent==null?JR:null}function JR(){return 0}class Mh extends $a{constructor(e,i,n){super(e.state,e.options),this.base=e,this.pos=i,this.context=n}get node(){return this.context.node}static create(e,i,n){return new Mh(e,i,n)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let i=this.state.doc.lineAt(e.from);for(;;){let n=e.resolve(i.from);for(;n.parent&&n.parent.from==n.from;)n=n.parent;if(e2(n,e))break;i=this.state.doc.lineAt(n.from)}return this.lineIndent(i.from)}continue(){return Ug(this.context.next,this.base,this.pos)}}function e2(t,e){for(let i=e;i;i=i.parent)if(t==i)return!0;return!1}function t2(t){let e=t.node,i=e.childAfter(e.from),n=e.lastChild;if(!i)return null;let O=t.options.simulateBreak,r=t.state.doc.lineAt(i.from),s=O==null||O<=r.from?r.to:Math.min(r.to,O);for(let o=i.to;;){let a=e.childAfter(o);if(!a||a==n)return null;if(!a.type.isSkipped){if(a.from>=s)return null;let l=/^ */.exec(r.text.slice(i.to-r.from))[0].length;return{from:i.from,to:i.to+l}}o=a.to}}function Ni({closing:t,align:e=!0,units:i=1}){return n=>Wg(n,e,i,t)}function Wg(t,e,i,n,O){let r=t.textAfter,s=r.match(/^\s*/)[0].length,o=n&&r.slice(s,s+n.length)==n||O==t.pos+s,a=e?t2(t):null;return a?o?t.column(a.from):t.column(a.to):t.baseIndent+(o?0:t.unit*i)}const Dh=t=>t.baseIndent;function Le({except:t,units:e=1}={}){return i=>{let n=t&&t.test(i.textAfter);return i.baseIndent+(n?0:e*i.unit)}}const i2=200;function n2(){return ae.transactionFilter.of(t=>{if(!t.docChanged||!t.isUserEvent("input.type")&&!t.isUserEvent("input.complete"))return t;let e=t.startState.languageDataAt("indentOnInput",t.startState.selection.main.head);if(!e.length)return t;let i=t.newDoc,{head:n}=t.newSelection.main,O=i.lineAt(n);if(n>O.from+i2)return t;let r=i.sliceString(O.from,n);if(!e.some(l=>l.test(r)))return t;let{state:s}=t,o=-1,a=[];for(let{head:l}of s.selection.ranges){let c=s.doc.lineAt(l);if(c.from==o)continue;o=c.from;let h=Ah(s,c.from);if(h==null)continue;let d=/^\s*/.exec(c.text)[0],u=Hr(s,h);d!=u&&a.push({from:c.from,to:c.from+d.length,insert:u})}return a.length?[t,{changes:a,sequential:!0}]:t})}const Cg=Z.define(),ct=new F;function Ri(t){let e=t.firstChild,i=t.lastChild;return e&&e.toi)continue;if(r&&o.from=e&&l.to>i&&(r=l)}}return r}function r2(t){let e=t.lastChild;return e&&e.to==t.to&&e.type.isError}function Qa(t,e,i){for(let n of t.facet(Cg)){let O=n(t,e,i);if(O)return O}return O2(t,e,i)}function jg(t,e){let i=e.mapPos(t.from,1),n=e.mapPos(t.to,-1);return i>=n?void 0:{from:i,to:n}}const pa=K.define({map:jg}),Kr=K.define({map:jg});function Gg(t){let e=[];for(let{head:i}of t.state.selection.ranges)e.some(n=>n.from<=i&&n.to>=i)||e.push(t.lineBlockAt(i));return e}const Dn=nt.define({create(){return D.none},update(t,e){e.isUserEvent("delete")&&e.changes.iterChangedRanges((i,n)=>t=Eg(t,i,n)),t=t.map(e.changes);for(let i of e.effects)if(i.is(pa)&&!s2(t,i.value.from,i.value.to)){let{preparePlaceholder:n}=e.state.facet(Mg),O=n?D.replace({widget:new h2(n(e.state,i.value))}):Ng;t=t.update({add:[O.range(i.value.from,i.value.to)]})}else i.is(Kr)&&(t=t.update({filter:(n,O)=>i.value.from!=n||i.value.to!=O,filterFrom:i.value.from,filterTo:i.value.to}));return e.selection&&(t=Eg(t,e.selection.main.head)),t},provide:t=>R.decorations.from(t),toJSON(t,e){let i=[];return t.between(0,e.doc.length,(n,O)=>{i.push(n,O)}),i},fromJSON(t){if(!Array.isArray(t)||t.length%2)throw new RangeError("Invalid JSON for fold state");let e=[];for(let i=0;i{Oe&&(n=!0)}),n?t.update({filterFrom:e,filterTo:i,filter:(O,r)=>O>=i||r<=e}):t}function ma(t,e,i){var n;let O=null;return(n=t.field(Dn,!1))===null||n===void 0||n.between(e,i,(r,s)=>{(!O||O.from>r)&&(O={from:r,to:s})}),O}function s2(t,e,i){let n=!1;return t.between(e,e,(O,r)=>{O==e&&r==i&&(n=!0)}),n}function Ig(t,e){return t.field(Dn,!1)?e:e.concat(K.appendConfig.of(Dg()))}const o2=t=>{for(let e of Gg(t)){let i=Qa(t.state,e.from,e.to);if(i)return t.dispatch({effects:Ig(t.state,[pa.of(i),Ag(t,i)])}),!0}return!1},a2=t=>{if(!t.state.field(Dn,!1))return!1;let e=[];for(let i of Gg(t)){let n=ma(t.state,i.from,i.to);n&&e.push(Kr.of(n),Ag(t,n,!1))}return e.length&&t.dispatch({effects:e}),e.length>0};function Ag(t,e,i=!0){let n=t.state.doc.lineAt(e.from).number,O=t.state.doc.lineAt(e.to).number;return R.announce.of(`${t.state.phrase(i?"Folded lines":"Unfolded lines")} ${n} ${t.state.phrase("to")} ${O}.`)}const l2=[{key:"Ctrl-Shift-[",mac:"Cmd-Alt-[",run:o2},{key:"Ctrl-Shift-]",mac:"Cmd-Alt-]",run:a2},{key:"Ctrl-Alt-[",run:t=>{let{state:e}=t,i=[];for(let n=0;n{let e=t.state.field(Dn,!1);if(!e||!e.size)return!1;let i=[];return e.between(0,t.state.doc.length,(n,O)=>{i.push(Kr.of({from:n,to:O}))}),t.dispatch({effects:i}),!0}}],c2={placeholderDOM:null,preparePlaceholder:null,placeholderText:"…"},Mg=Z.define({combine(t){return Si(t,c2)}});function Dg(t){return[Dn,f2]}function Lg(t,e){let{state:i}=t,n=i.facet(Mg),O=s=>{let o=t.lineBlockAt(t.posAtDOM(s.target)),a=ma(t.state,o.from,o.to);a&&t.dispatch({effects:Kr.of(a)}),s.preventDefault()};if(n.placeholderDOM)return n.placeholderDOM(t,O,e);let r=document.createElement("span");return r.textContent=n.placeholderText,r.setAttribute("aria-label",i.phrase("folded code")),r.title=i.phrase("unfold"),r.className="cm-foldPlaceholder",r.onclick=O,r}const Ng=D.replace({widget:new class extends Xi{toDOM(t){return Lg(t,null)}}});class h2 extends Xi{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return Lg(e,this.value)}}const d2={openText:"⌄",closedText:"›",markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1};class Lh extends Di{constructor(e,i){super(),this.config=e,this.open=i}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let i=document.createElement("span");return i.textContent=this.open?this.config.openText:this.config.closedText,i.title=e.state.phrase(this.open?"Fold line":"Unfold line"),i}}function u2(t={}){let e={...d2,...t},i=new Lh(e,!0),n=new Lh(e,!1),O=We.fromClass(class{constructor(s){this.from=s.viewport.from,this.markers=this.buildMarkers(s)}update(s){(s.docChanged||s.viewportChanged||s.startState.facet(Xn)!=s.state.facet(Xn)||s.startState.field(Dn,!1)!=s.state.field(Dn,!1)||$e(s.startState)!=$e(s.state)||e.foldingChanged(s))&&(this.markers=this.buildMarkers(s.view))}buildMarkers(s){let o=new Ei;for(let a of s.viewportLineBlocks){let l=ma(s.state,a.from,a.to)?n:Qa(s.state,a.from,a.to)?i:null;l&&o.add(a.from,a.from,l)}return o.finish()}}),{domEventHandlers:r}=e;return[O,$R({class:"cm-foldGutter",markers(s){var o;return((o=s.plugin(O))===null||o===void 0?void 0:o.markers)||re.empty},initialSpacer(){return new Lh(e,!1)},domEventHandlers:{...r,click:(s,o,a)=>{if(r.click&&r.click(s,o,a))return!0;let l=ma(s.state,o.from,o.to);if(l)return s.dispatch({effects:Kr.of(l)}),!0;let c=Qa(s.state,o.from,o.to);return c?(s.dispatch({effects:pa.of(c)}),!0):!1}}}),Dg()]}const f2=R.baseTheme({".cm-foldPlaceholder":{backgroundColor:"#eee",border:"1px solid #ddd",color:"#888",borderRadius:".2em",margin:"0 1px",padding:"0 1px",cursor:"pointer"},".cm-foldGutter span":{padding:"0 1px",cursor:"pointer"}});class ga{constructor(e,i){this.specs=e;let n;function O(o){let a=fn.newName();return(n||(n=Object.create(null)))["."+a]=o,a}const r=typeof i.all=="string"?i.all:i.all?O(i.all):void 0,s=i.scope;this.scope=s instanceof Wt?o=>o.prop(Sn)==s.data:s?o=>o==s:void 0,this.style=Rg(e.map(o=>({tag:o.tag,class:o.class||O(Object.assign({},o,{tag:null}))})),{all:r}).style,this.module=n?new fn(n):null,this.themeType=i.themeType}static define(e,i){return new ga(e,i||{})}}const Nh=Z.define(),Bg=Z.define({combine(t){return t.length?[t[0]]:null}});function Bh(t){let e=t.facet(Nh);return e.length?e:t.facet(Bg)}function $2(t,e){let i=[p2],n;return t instanceof ga&&(t.module&&i.push(R.styleModule.of(t.module)),n=t.themeType),e?.fallback?i.push(Bg.of(t)):n?i.push(Nh.computeN([R.darkTheme],O=>O.facet(R.darkTheme)==(n=="dark")?[t]:[])):i.push(Nh.of(t)),i}class Q2{constructor(e){this.markCache=Object.create(null),this.tree=$e(e.state),this.decorations=this.buildDeco(e,Bh(e.state)),this.decoratedTo=e.viewport.to}update(e){let i=$e(e.state),n=Bh(e.state),O=n!=Bh(e.startState),{viewport:r}=e.view,s=e.changes.mapPos(this.decoratedTo,1);i.length=r.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=s):(i!=this.tree||e.viewportChanged||O)&&(this.tree=i,this.decorations=this.buildDeco(e.view,n),this.decoratedTo=r.to)}buildDeco(e,i){if(!i||!this.tree.length)return D.none;let n=new Ei;for(let{from:O,to:r}of e.visibleRanges)AR(this.tree,i,(s,o,a)=>{n.add(s,o,this.markCache[a]||(this.markCache[a]=D.mark({class:a})))},O,r);return n.finish()}}const p2=Gi.high(We.fromClass(Q2,{decorations:t=>t.decorations})),m2=ga.define([{tag:f.meta,color:"#404740"},{tag:f.link,textDecoration:"underline"},{tag:f.heading,textDecoration:"underline",fontWeight:"bold"},{tag:f.emphasis,fontStyle:"italic"},{tag:f.strong,fontWeight:"bold"},{tag:f.strikethrough,textDecoration:"line-through"},{tag:f.keyword,color:"#708"},{tag:[f.atom,f.bool,f.url,f.contentSeparator,f.labelName],color:"#219"},{tag:[f.literal,f.inserted],color:"#164"},{tag:[f.string,f.deleted],color:"#a11"},{tag:[f.regexp,f.escape,f.special(f.string)],color:"#e40"},{tag:f.definition(f.variableName),color:"#00f"},{tag:f.local(f.variableName),color:"#30a"},{tag:[f.typeName,f.namespace],color:"#085"},{tag:f.className,color:"#167"},{tag:[f.special(f.variableName),f.macroName],color:"#256"},{tag:f.definition(f.propertyName),color:"#00c"},{tag:f.comment,color:"#940"},{tag:f.invalid,color:"#f00"}]),g2=R.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),Fg=1e4,Hg="()[]{}",Kg=Z.define({combine(t){return Si(t,{afterCursor:!0,brackets:Hg,maxScanDistance:Fg,renderMatch:X2})}}),P2=D.mark({class:"cm-matchingBracket"}),S2=D.mark({class:"cm-nonmatchingBracket"});function X2(t){let e=[],i=t.matched?P2:S2;return e.push(i.range(t.start.from,t.start.to)),t.end&&e.push(i.range(t.end.from,t.end.to)),e}function Jg(t){let e=[],i=t.facet(Kg);for(let n of t.selection.ranges){if(!n.empty)continue;let O=Zi(t,n.head,-1,i)||n.head>0&&Zi(t,n.head-1,1,i)||i.afterCursor&&(Zi(t,n.head,1,i)||n.headt.decorations}),g2];function y2(t={}){return[Kg.of(t),b2]}const Fh=new F;function Hh(t,e,i){let n=t.prop(e<0?F.openedBy:F.closedBy);if(n)return n;if(t.name.length==1){let O=i.indexOf(t.name);if(O>-1&&O%2==(e<0?1:0))return[i[O+e]]}return null}function Kh(t){let e=t.type.prop(Fh);return e?e(t.node):t}function Zi(t,e,i,n={}){let O=n.maxScanDistance||Fg,r=n.brackets||Hg,s=$e(t),o=s.resolveInner(e,i);for(let a=o;a;a=a.parent){let l=Hh(a.type,i,r);if(l&&a.from0?e>=c.from&&ec.from&&e<=c.to))return x2(t,e,i,a,c,l,r)}}return T2(t,e,i,s,o.type,O,r)}function x2(t,e,i,n,O,r,s){let o=n.parent,a={from:O.from,to:O.to},l=0,c=o?.cursor();if(c&&(i<0?c.childBefore(n.from):c.childAfter(n.to)))do if(i<0?c.to<=n.from:c.from>=n.to){if(l==0&&r.indexOf(c.type.name)>-1&&c.from0)return null;let l={from:i<0?e-1:e,to:i>0?e+1:e},c=t.doc.iterRange(e,i>0?t.doc.length:0),h=0;for(let d=0;!c.next().done&&d<=r;){let u=c.value;i<0&&(d+=u.length);let $=e+d*i;for(let Q=i>0?0:u.length-1,p=i>0?u.length:-1;Q!=p;Q+=i){let m=s.indexOf(u[Q]);if(!(m<0||n.resolveInner($+Q,1).type!=O))if(m%2==0==i>0)h++;else{if(h==1)return{start:l,end:{from:$+Q,to:$+Q+1},matched:m>>1==a>>1};h--}}i>0&&(d+=u.length)}return c.done?{start:l,matched:!1}:null}function e1(t,e,i,n=0,O=0){e==null&&(e=t.search(/[^\s\u00a0]/),e==-1&&(e=t.length));let r=O;for(let s=n;s=this.string.length}sol(){return this.pos==0}peek(){return this.string.charAt(this.pos)||void 0}next(){if(this.posi}eatSpace(){let e=this.pos;for(;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e}skipToEnd(){this.pos=this.string.length}skipTo(e){let i=this.string.indexOf(e,this.pos);if(i>-1)return this.pos=i,!0}backUp(e){this.pos-=e}column(){return this.lastColumnPosn?s.toLowerCase():s,r=this.string.substr(this.pos,e.length);return O(r)==O(e)?(i!==!1&&(this.pos+=e.length),!0):null}else{let O=this.string.slice(this.pos).match(e);return O&&O.index>0?null:(O&&i!==!1&&(this.pos+=O[0].length),O)}}current(){return this.string.slice(this.start,this.pos)}}function w2(t){return{name:t.name||"",token:t.token,blankLine:t.blankLine||(()=>{}),startState:t.startState||(()=>!0),copyState:t.copyState||v2,indent:t.indent||(()=>null),languageData:t.languageData||{},tokenTable:t.tokenTable||ed,mergeTokens:t.mergeTokens!==!1}}function v2(t){if(typeof t!="object")return t;let e={};for(let i in t){let n=t[i];e[i]=n instanceof Array?n.slice():n}return e}const i1=new WeakMap;class Yi extends Wt{constructor(e){let i=ua(e.languageData),n=w2(e),O,r=new class extends oa{createParse(s,o,a){return new _2(O,s,o,a)}};super(i,r,[],e.name),this.topNode=Y2(i,this),O=this,this.streamParser=n,this.stateAfter=new F({perNode:!0}),this.tokenTable=e.tokenTable?new a1(n.tokenTable):Z2}static define(e){return new Yi(e)}getIndent(e){let i,{overrideIndentation:n}=e.options;n&&(i=i1.get(e.state),i!=null&&i1e4)return null;for(;r=n&&i+e.length<=O&&e.prop(t.stateAfter);if(r)return{state:t.streamParser.copyState(r),pos:i+e.length};for(let s=e.children.length-1;s>=0;s--){let o=e.children[s],a=i+e.positions[s],l=o instanceof ne&&a=e.length)return e;!O&&i==0&&e.type==t.topNode&&(O=!0);for(let r=e.children.length-1;r>=0;r--){let s=e.positions[r],o=e.children[r],a;if(si&&Jh(t,r.tree,0-r.offset,i,o),l;if(a&&a.pos<=n&&(l=n1(t,r.tree,i+r.offset,a.pos+r.offset,!1)))return{state:a.state,tree:l}}return{state:t.streamParser.startState(O?Mn(O):4),tree:ne.empty}}let _2=class{constructor(e,i,n,O){this.lang=e,this.input=i,this.fragments=n,this.ranges=O,this.stoppedAt=null,this.chunks=[],this.chunkPos=[],this.chunk=[],this.chunkReused=void 0,this.rangeIndex=0,this.to=O[O.length-1].to;let r=An.get(),s=O[0].from,{state:o,tree:a}=k2(e,n,s,this.to,r?.state);this.state=o,this.parsedPos=this.chunkStart=s+a.length;for(let l=0;ll.from<=r.viewport.from&&l.to>=r.viewport.from)&&(this.state=this.lang.streamParser.startState(Mn(r.state)),r.skipUntilInView(this.parsedPos,r.viewport.from),this.parsedPos=r.viewport.from),this.moveRangeIndex()}advance(){let e=An.get(),i=this.stoppedAt==null?this.to:Math.min(this.to,this.stoppedAt),n=Math.min(i,this.chunkStart+512);for(e&&(n=Math.min(n,e.viewport.to));this.parsedPos=i?this.finish():e&&this.parsedPos>=e.viewport.to?(e.skipUntilInView(this.parsedPos,i),this.finish()):null}stopAt(e){this.stoppedAt=e}lineAfter(e){let i=this.input.chunk(e);if(this.input.lineChunks)i==` +`&&(i="");else{let n=i.indexOf(` +`);n>-1&&(i=i.slice(0,n))}return e+i.length<=this.to?i:i.slice(0,this.to-e)}nextLine(){let e=this.parsedPos,i=this.lineAfter(e),n=e+i.length;for(let O=this.rangeIndex;;){let r=this.ranges[O].to;if(r>=n||(i=i.slice(0,r-(n-i.length)),O++,O==this.ranges.length))break;let s=this.ranges[O].from,o=this.lineAfter(s);i+=o,n=s+o.length}return{line:i,end:n}}skipGapsTo(e,i,n){for(;;){let O=this.ranges[this.rangeIndex].to,r=e+i;if(n>0?O>r:O>=r)break;let s=this.ranges[++this.rangeIndex].from;i+=s-O}return i}moveRangeIndex(){for(;this.ranges[this.rangeIndex].to1){O=this.skipGapsTo(i,O,1),i+=O;let o=this.chunk.length;O=this.skipGapsTo(n,O,-1),n+=O,r+=this.chunk.length-o}let s=this.chunk.length-4;return this.lang.streamParser.mergeTokens&&r==4&&s>=0&&this.chunk[s]==e&&this.chunk[s+2]==i?this.chunk[s+2]=n:this.chunk.push(e,i,n,r),O}parseLine(e){let{line:i,end:n}=this.nextLine(),O=0,{streamParser:r}=this.lang,s=new t1(i,e?e.state.tabSize:4,e?Mn(e.state):2);if(s.eol())r.blankLine(this.state,s.indentUnit);else for(;!s.eol();){let o=O1(r.token,s,this.state);if(o&&(O=this.emitToken(this.lang.tokenTable.resolve(o),this.parsedPos+s.start,this.parsedPos+s.pos,O)),s.start>1e4)break}this.parsedPos=n,this.moveRangeIndex(),this.parsedPose.start)return O}throw new Error("Stream parser failed to advance stream.")}const ed=Object.create(null),Jr=[Ee.none],R2=new RO(Jr),r1=[],s1=Object.create(null),o1=Object.create(null);for(let[t,e]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])o1[t]=l1(ed,e);class a1{constructor(e){this.extra=e,this.table=Object.assign(Object.create(null),o1)}resolve(e){return e?this.table[e]||(this.table[e]=l1(this.extra,e)):0}}const Z2=new a1(ed);function td(t,e){r1.indexOf(t)>-1||(r1.push(t),console.warn(e))}function l1(t,e){let i=[];for(let o of e.split(" ")){let a=[];for(let l of o.split(".")){let c=t[l]||f[l];c?typeof c=="function"?a.length?a=a.map(c):td(l,`Modifier ${l} used at start of tag`):a.length?td(l,`Tag ${l} used as modifier`):a=Array.isArray(c)?c:[c]:td(l,`Unknown highlighting tag ${l}`)}for(let l of a)i.push(l)}if(!i.length)return 0;let n=e.replace(/ /g,"_"),O=n+" "+i.map(o=>o.id),r=s1[O];if(r)return r.id;let s=s1[O]=Ee.define({id:Jr.length,name:n,props:[ot({[n]:i})]});return Jr.push(s),s.id}function Y2(t,e){let i=Ee.define({id:Jr.length,name:"Document",props:[Sn.add(()=>t),lt.add(()=>n=>e.getIndent(n))],top:!0});return Jr.push(i),i}ge.RTL,ge.LTR;const z2=t=>{let{state:e}=t,i=e.doc.lineAt(e.selection.main.from),n=nd(t.state,i.from);return n.line?V2(t):n.block?U2(t):!1};function id(t,e){return({state:i,dispatch:n})=>{if(i.readOnly)return!1;let O=t(e,i);return O?(n(i.update(O)),!0):!1}}const V2=id(j2,0),q2=id(c1,0),U2=id((t,e)=>c1(t,e,C2(e)),0);function nd(t,e){let i=t.languageDataAt("commentTokens",e,1);return i.length?i[0]:{}}const es=50;function W2(t,{open:e,close:i},n,O){let r=t.sliceDoc(n-es,n),s=t.sliceDoc(O,O+es),o=/\s*$/.exec(r)[0].length,a=/^\s*/.exec(s)[0].length,l=r.length-o;if(r.slice(l-e.length,l)==e&&s.slice(a,a+i.length)==i)return{open:{pos:n-o,margin:o&&1},close:{pos:O+a,margin:a&&1}};let c,h;O-n<=2*es?c=h=t.sliceDoc(n,O):(c=t.sliceDoc(n,n+es),h=t.sliceDoc(O-es,O));let d=/^\s*/.exec(c)[0].length,u=/\s*$/.exec(h)[0].length,$=h.length-u-i.length;return c.slice(d,d+e.length)==e&&h.slice($,$+i.length)==i?{open:{pos:n+d+e.length,margin:/\s/.test(c.charAt(d+e.length))?1:0},close:{pos:O-u-i.length,margin:/\s/.test(h.charAt($-1))?1:0}}:null}function C2(t){let e=[];for(let i of t.selection.ranges){let n=t.doc.lineAt(i.from),O=i.to<=n.to?n:t.doc.lineAt(i.to);O.from>n.from&&O.from==i.to&&(O=i.to==n.to+1?n:t.doc.lineAt(i.to-1));let r=e.length-1;r>=0&&e[r].to>n.from?e[r].to=O.to:e.push({from:n.from+/^\s*/.exec(n.text)[0].length,to:O.to})}return e}function c1(t,e,i=e.selection.ranges){let n=i.map(r=>nd(e,r.from).block);if(!n.every(r=>r))return null;let O=i.map((r,s)=>W2(e,n[s],r.from,r.to));if(t!=2&&!O.every(r=>r))return{changes:e.changes(i.map((r,s)=>O[s]?[]:[{from:r.from,insert:n[s].open+" "},{from:r.to,insert:" "+n[s].close}]))};if(t!=1&&O.some(r=>r)){let r=[];for(let s=0,o;sO&&(r==s||s>h.from)){O=h.from;let d=/^\s*/.exec(h.text)[0].length,u=d==h.length,$=h.text.slice(d,d+l.length)==l?d:-1;dr.comment<0&&(!r.empty||r.single))){let r=[];for(let{line:o,token:a,indent:l,empty:c,single:h}of n)(h||!c)&&r.push({from:o.from+l,insert:a+" "});let s=e.changes(r);return{changes:s,selection:e.selection.map(s,1)}}else if(t!=1&&n.some(r=>r.comment>=0)){let r=[];for(let{line:s,comment:o,token:a}of n)if(o>=0){let l=s.from+o,c=l+a.length;s.text[c-s.from]==" "&&c++,r.push({from:l,to:c})}return{changes:r}}return null}const Od=Pi.define(),G2=Pi.define(),E2=Z.define(),h1=Z.define({combine(t){return Si(t,{minDepth:100,newGroupDelay:500,joinToEvent:(e,i)=>i},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,i)=>(n,O)=>e(n,O)||i(n,O)})}}),d1=nt.define({create(){return zi.empty},update(t,e){let i=e.state.facet(h1),n=e.annotation(Od);if(n){let a=kt.fromTransaction(e,n.selection),l=n.side,c=l==0?t.undone:t.done;return a?c=Sa(c,c.length,i.minDepth,a):c=$1(c,e.startState.selection),new zi(l==0?n.rest:c,l==0?c:n.rest)}let O=e.annotation(G2);if((O=="full"||O=="before")&&(t=t.isolate()),e.annotation(Ge.addToHistory)===!1)return e.changes.empty?t:t.addMapping(e.changes.desc);let r=kt.fromTransaction(e),s=e.annotation(Ge.time),o=e.annotation(Ge.userEvent);return r?t=t.addChanges(r,s,o,i,e):e.selection&&(t=t.addSelection(e.startState.selection,s,o,i.newGroupDelay)),(O=="full"||O=="after")&&(t=t.isolate()),t},toJSON(t){return{done:t.done.map(e=>e.toJSON()),undone:t.undone.map(e=>e.toJSON())}},fromJSON(t){return new zi(t.done.map(kt.fromJSON),t.undone.map(kt.fromJSON))}});function I2(t={}){return[d1,h1.of(t),R.domEventHandlers({beforeinput(e,i){let n=e.inputType=="historyUndo"?u1:e.inputType=="historyRedo"?rd:null;return n?(e.preventDefault(),n(i)):!1}})]}function Pa(t,e){return function({state:i,dispatch:n}){if(!e&&i.readOnly)return!1;let O=i.field(d1,!1);if(!O)return!1;let r=O.pop(t,i,e);return r?(n(r),!0):!1}}const u1=Pa(0,!1),rd=Pa(1,!1),A2=Pa(0,!0),M2=Pa(1,!0);class kt{constructor(e,i,n,O,r){this.changes=e,this.effects=i,this.mapped=n,this.startSelection=O,this.selectionsAfter=r}setSelAfter(e){return new kt(this.changes,this.effects,this.mapped,this.startSelection,e)}toJSON(){var e,i,n;return{changes:(e=this.changes)===null||e===void 0?void 0:e.toJSON(),mapped:(i=this.mapped)===null||i===void 0?void 0:i.toJSON(),startSelection:(n=this.startSelection)===null||n===void 0?void 0:n.toJSON(),selectionsAfter:this.selectionsAfter.map(O=>O.toJSON())}}static fromJSON(e){return new kt(e.changes&&De.fromJSON(e.changes),[],e.mapped&&gi.fromJSON(e.mapped),e.startSelection&&x.fromJSON(e.startSelection),e.selectionsAfter.map(x.fromJSON))}static fromTransaction(e,i){let n=Bt;for(let O of e.startState.facet(E2)){let r=O(e);r.length&&(n=n.concat(r))}return!n.length&&e.changes.empty?null:new kt(e.changes.invert(e.startState.doc),n,void 0,i||e.startState.selection,Bt)}static selection(e){return new kt(void 0,Bt,void 0,void 0,e)}}function Sa(t,e,i,n){let O=e+1>i+20?e-i-1:0,r=t.slice(O,e);return r.push(n),r}function D2(t,e){let i=[],n=!1;return t.iterChangedRanges((O,r)=>i.push(O,r)),e.iterChangedRanges((O,r,s,o)=>{for(let a=0;a=l&&s<=c&&(n=!0)}}),n}function L2(t,e){return t.ranges.length==e.ranges.length&&t.ranges.filter((i,n)=>i.empty!=e.ranges[n].empty).length===0}function f1(t,e){return t.length?e.length?t.concat(e):t:e}const Bt=[],N2=200;function $1(t,e){if(t.length){let i=t[t.length-1],n=i.selectionsAfter.slice(Math.max(0,i.selectionsAfter.length-N2));return n.length&&n[n.length-1].eq(e)?t:(n.push(e),Sa(t,t.length-1,1e9,i.setSelAfter(n)))}else return[kt.selection([e])]}function B2(t){let e=t[t.length-1],i=t.slice();return i[t.length-1]=e.setSelAfter(e.selectionsAfter.slice(0,e.selectionsAfter.length-1)),i}function sd(t,e){if(!t.length)return t;let i=t.length,n=Bt;for(;i;){let O=F2(t[i-1],e,n);if(O.changes&&!O.changes.empty||O.effects.length){let r=t.slice(0,i);return r[i-1]=O,r}else e=O.mapped,i--,n=O.selectionsAfter}return n.length?[kt.selection(n)]:Bt}function F2(t,e,i){let n=f1(t.selectionsAfter.length?t.selectionsAfter.map(o=>o.map(e)):Bt,i);if(!t.changes)return kt.selection(n);let O=t.changes.map(e),r=e.mapDesc(t.changes,!0),s=t.mapped?t.mapped.composeDesc(r):r;return new kt(O,K.mapEffects(t.effects,e),s,t.startSelection.map(r),n)}const H2=/^(input\.type|delete)($|\.)/;class zi{constructor(e,i,n=0,O=void 0){this.done=e,this.undone=i,this.prevTime=n,this.prevUserEvent=O}isolate(){return this.prevTime?new zi(this.done,this.undone):this}addChanges(e,i,n,O,r){let s=this.done,o=s[s.length-1];return o&&o.changes&&!o.changes.empty&&e.changes&&(!n||H2.test(n))&&(!o.selectionsAfter.length&&i-this.prevTime0&&i-this.prevTimei.empty?t.moveByChar(i,e):Xa(i,e))}function pt(t){return t.textDirectionAt(t.state.selection.main.head)==ge.LTR}const p1=t=>Q1(t,!pt(t)),m1=t=>Q1(t,pt(t));function g1(t,e){return li(t,i=>i.empty?t.moveByGroup(i,e):Xa(i,e))}const J2=t=>g1(t,!pt(t)),eZ=t=>g1(t,pt(t));function tZ(t,e,i){if(e.type.prop(i))return!0;let n=e.to-e.from;return n&&(n>2||/[^\s,.;:]/.test(t.sliceDoc(e.from,e.to)))||e.firstChild}function ba(t,e,i){let n=$e(t).resolveInner(e.head),O=i?F.closedBy:F.openedBy;for(let a=e.head;;){let l=i?n.childAfter(a):n.childBefore(a);if(!l)break;tZ(t,l,O)?n=l:a=i?l.to:l.from}let r=n.type.prop(O),s,o;return r&&(s=i?Zi(t,n.from,1):Zi(t,n.to,-1))&&s.matched?o=i?s.end.to:s.end.from:o=i?n.to:n.from,x.cursor(o,i?-1:1)}const iZ=t=>li(t,e=>ba(t.state,e,!pt(t))),nZ=t=>li(t,e=>ba(t.state,e,pt(t)));function P1(t,e){return li(t,i=>{if(!i.empty)return Xa(i,e);let n=t.moveVertically(i,e);return n.head!=i.head?n:t.moveToLineBoundary(i,e)})}const S1=t=>P1(t,!1),X1=t=>P1(t,!0);function b1(t){let e=t.scrollDOM.clientHeights.empty?t.moveVertically(s,e,i.height):Xa(s,e));if(O.eq(n.selection))return!1;let r;if(i.selfScroll){let s=t.coordsAtPos(n.selection.main.head),o=t.scrollDOM.getBoundingClientRect(),a=o.top+i.marginTop,l=o.bottom-i.marginBottom;s&&s.top>a&&s.bottomy1(t,!1),od=t=>y1(t,!0);function bn(t,e,i){let n=t.lineBlockAt(e.head),O=t.moveToLineBoundary(e,i);if(O.head==e.head&&O.head!=(i?n.to:n.from)&&(O=t.moveToLineBoundary(e,i,!1)),!i&&O.head==n.from&&n.length){let r=/^\s*/.exec(t.state.sliceDoc(n.from,Math.min(n.from+100,n.to)))[0].length;r&&e.head!=n.from+r&&(O=x.cursor(n.from+r))}return O}const OZ=t=>li(t,e=>bn(t,e,!0)),rZ=t=>li(t,e=>bn(t,e,!1)),sZ=t=>li(t,e=>bn(t,e,!pt(t))),oZ=t=>li(t,e=>bn(t,e,pt(t))),aZ=t=>li(t,e=>x.cursor(t.lineBlockAt(e.head).from,1)),lZ=t=>li(t,e=>x.cursor(t.lineBlockAt(e.head).to,-1));function cZ(t,e,i){let n=!1,O=zO(t.selection,r=>{let s=Zi(t,r.head,-1)||Zi(t,r.head,1)||r.head>0&&Zi(t,r.head-1,1)||r.headcZ(t,e);function Ft(t,e){let i=zO(t.state.selection,n=>{let O=e(n);return x.range(n.anchor,O.head,O.goalColumn,O.bidiLevel||void 0,O.assoc)});return i.eq(t.state.selection)?!1:(t.dispatch(ai(t.state,i)),!0)}function T1(t,e){return Ft(t,i=>t.moveByChar(i,e))}const w1=t=>T1(t,!pt(t)),v1=t=>T1(t,pt(t));function k1(t,e){return Ft(t,i=>t.moveByGroup(i,e))}const dZ=t=>k1(t,!pt(t)),uZ=t=>k1(t,pt(t)),fZ=t=>Ft(t,e=>ba(t.state,e,!pt(t))),$Z=t=>Ft(t,e=>ba(t.state,e,pt(t)));function _1(t,e){return Ft(t,i=>t.moveVertically(i,e))}const R1=t=>_1(t,!1),Z1=t=>_1(t,!0);function Y1(t,e){return Ft(t,i=>t.moveVertically(i,e,b1(t).height))}const z1=t=>Y1(t,!1),V1=t=>Y1(t,!0),QZ=t=>Ft(t,e=>bn(t,e,!0)),pZ=t=>Ft(t,e=>bn(t,e,!1)),mZ=t=>Ft(t,e=>bn(t,e,!pt(t))),gZ=t=>Ft(t,e=>bn(t,e,pt(t))),PZ=t=>Ft(t,e=>x.cursor(t.lineBlockAt(e.head).from)),SZ=t=>Ft(t,e=>x.cursor(t.lineBlockAt(e.head).to)),q1=({state:t,dispatch:e})=>(e(ai(t,{anchor:0})),!0),U1=({state:t,dispatch:e})=>(e(ai(t,{anchor:t.doc.length})),!0),W1=({state:t,dispatch:e})=>(e(ai(t,{anchor:t.selection.main.anchor,head:0})),!0),C1=({state:t,dispatch:e})=>(e(ai(t,{anchor:t.selection.main.anchor,head:t.doc.length})),!0),XZ=({state:t,dispatch:e})=>(e(t.update({selection:{anchor:0,head:t.doc.length},userEvent:"select"})),!0),bZ=({state:t,dispatch:e})=>{let i=xa(t).map(({from:n,to:O})=>x.range(n,Math.min(O+1,t.doc.length)));return e(t.update({selection:x.create(i),userEvent:"select"})),!0},yZ=({state:t,dispatch:e})=>{let i=zO(t.selection,n=>{let O=$e(t),r=O.resolveStack(n.from,1);if(n.empty){let s=O.resolveStack(n.from,-1);s.node.from>=r.node.from&&s.node.to<=r.node.to&&(r=s)}for(let s=r;s;s=s.next){let{node:o}=s;if((o.from=n.to||o.to>n.to&&o.from<=n.from)&&s.next)return x.range(o.to,o.from)}return n});return i.eq(t.selection)?!1:(e(ai(t,i)),!0)};function j1(t,e){let{state:i}=t,n=i.selection,O=i.selection.ranges.slice();for(let r of i.selection.ranges){let s=i.doc.lineAt(r.head);if(e?s.to0)for(let o=r;;){let a=t.moveVertically(o,e);if(a.heads.to){O.some(l=>l.head==a.head)||O.push(a);break}else{if(a.head==o.head)break;o=a}}}return O.length==n.ranges.length?!1:(t.dispatch(ai(i,x.create(O,O.length-1))),!0)}const xZ=t=>j1(t,!1),TZ=t=>j1(t,!0),wZ=({state:t,dispatch:e})=>{let i=t.selection,n=null;return i.ranges.length>1?n=x.create([i.main]):i.main.empty||(n=x.create([x.cursor(i.main.head)])),n?(e(ai(t,n)),!0):!1};function ts(t,e){if(t.state.readOnly)return!1;let i="delete.selection",{state:n}=t,O=n.changeByRange(r=>{let{from:s,to:o}=r;if(s==o){let a=e(r);as&&(i="delete.forward",a=ya(t,a,!0)),s=Math.min(s,a),o=Math.max(o,a)}else s=ya(t,s,!1),o=ya(t,o,!0);return s==o?{range:r}:{changes:{from:s,to:o},range:x.cursor(s,sO(t)))n.between(e,e,(O,r)=>{Oe&&(e=i?r:O)});return e}const G1=(t,e,i)=>ts(t,n=>{let O=n.from,{state:r}=t,s=r.doc.lineAt(O),o,a;if(i&&!e&&O>s.from&&OG1(t,!1,!0),E1=t=>G1(t,!0,!1),I1=(t,e)=>ts(t,i=>{let n=i.head,{state:O}=t,r=O.doc.lineAt(n),s=O.charCategorizer(n);for(let o=null;;){if(n==(e?r.to:r.from)){n==i.head&&r.number!=(e?O.doc.lines:1)&&(n+=e?1:-1);break}let a=Be(r.text,n-r.from,e)+r.from,l=r.text.slice(Math.min(n,a)-r.from,Math.max(n,a)-r.from),c=s(l);if(o!=null&&c!=o)break;(l!=" "||n!=i.head)&&(o=c),n=a}return n}),A1=t=>I1(t,!1),vZ=t=>I1(t,!0),kZ=t=>ts(t,e=>{let i=t.lineBlockAt(e.head).to;return e.headts(t,e=>{let i=t.moveToLineBoundary(e,!1).head;return e.head>i?i:Math.max(0,e.head-1)}),RZ=t=>ts(t,e=>{let i=t.moveToLineBoundary(e,!0).head;return e.head{if(t.readOnly)return!1;let i=t.changeByRange(n=>({changes:{from:n.from,to:n.to,insert:le.of(["",""])},range:x.cursor(n.from)}));return e(t.update(i,{scrollIntoView:!0,userEvent:"input"})),!0},YZ=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let i=t.changeByRange(n=>{if(!n.empty||n.from==0||n.from==t.doc.length)return{range:n};let O=n.from,r=t.doc.lineAt(O),s=O==r.from?O-1:Be(r.text,O-r.from,!1)+r.from,o=O==r.to?O+1:Be(r.text,O-r.from,!0)+r.from;return{changes:{from:s,to:o,insert:t.doc.slice(O,o).append(t.doc.slice(s,O))},range:x.cursor(o)}});return i.changes.empty?!1:(e(t.update(i,{scrollIntoView:!0,userEvent:"move.character"})),!0)};function xa(t){let e=[],i=-1;for(let n of t.selection.ranges){let O=t.doc.lineAt(n.from),r=t.doc.lineAt(n.to);if(!n.empty&&n.to==r.from&&(r=t.doc.lineAt(n.to-1)),i>=O.number){let s=e[e.length-1];s.to=r.to,s.ranges.push(n)}else e.push({from:O.from,to:r.to,ranges:[n]});i=r.number+1}return e}function M1(t,e,i){if(t.readOnly)return!1;let n=[],O=[];for(let r of xa(t)){if(i?r.to==t.doc.length:r.from==0)continue;let s=t.doc.lineAt(i?r.to+1:r.from-1),o=s.length+1;if(i){n.push({from:r.to,to:s.to},{from:r.from,insert:s.text+t.lineBreak});for(let a of r.ranges)O.push(x.range(Math.min(t.doc.length,a.anchor+o),Math.min(t.doc.length,a.head+o)))}else{n.push({from:s.from,to:r.from},{from:r.to,insert:t.lineBreak+s.text});for(let a of r.ranges)O.push(x.range(a.anchor-o,a.head-o))}}return n.length?(e(t.update({changes:n,scrollIntoView:!0,selection:x.create(O,t.selection.mainIndex),userEvent:"move.line"})),!0):!1}const zZ=({state:t,dispatch:e})=>M1(t,e,!1),VZ=({state:t,dispatch:e})=>M1(t,e,!0);function D1(t,e,i){if(t.readOnly)return!1;let n=[];for(let r of xa(t))i?n.push({from:r.from,insert:t.doc.slice(r.from,r.to)+t.lineBreak}):n.push({from:r.to,insert:t.lineBreak+t.doc.slice(r.from,r.to)});let O=t.changes(n);return e(t.update({changes:O,selection:t.selection.map(O,i?1:-1),scrollIntoView:!0,userEvent:"input.copyline"})),!0}const qZ=({state:t,dispatch:e})=>D1(t,e,!1),UZ=({state:t,dispatch:e})=>D1(t,e,!0),WZ=t=>{if(t.state.readOnly)return!1;let{state:e}=t,i=e.changes(xa(e).map(({from:O,to:r})=>(O>0?O--:r{let r;if(t.lineWrapping){let s=t.lineBlockAt(O.head),o=t.coordsAtPos(O.head,O.assoc||1);o&&(r=s.bottom+t.documentTop-o.bottom+t.defaultLineHeight/2)}return t.moveVertically(O,!0,r)}).map(i);return t.dispatch({changes:i,selection:n,scrollIntoView:!0,userEvent:"delete.line"}),!0};function CZ(t,e){if(/\(\)|\[\]|\{\}/.test(t.sliceDoc(e-1,e+1)))return{from:e,to:e};let i=$e(t).resolveInner(e),n=i.childBefore(e),O=i.childAfter(e),r;return n&&O&&n.to<=e&&O.from>=e&&(r=n.type.prop(F.closedBy))&&r.indexOf(O.name)>-1&&t.doc.lineAt(n.to).from==t.doc.lineAt(O.from).from&&!/\S/.test(t.sliceDoc(n.to,O.from))?{from:n.to,to:O.from}:null}const L1=N1(!1),jZ=N1(!0);function N1(t){return({state:e,dispatch:i})=>{if(e.readOnly)return!1;let n=e.changeByRange(O=>{let{from:r,to:s}=O,o=e.doc.lineAt(r),a=!t&&r==s&&CZ(e,r);t&&(r=s=(s<=o.to?o:e.doc.lineAt(s)).to);let l=new $a(e,{simulateBreak:r,simulateDoubleBreak:!!a}),c=Ah(l,r);for(c==null&&(c=Oi(/^\s*/.exec(e.doc.lineAt(r).text)[0],e.tabSize));so.from&&r{let O=[];for(let s=n.from;s<=n.to;){let o=t.doc.lineAt(s);o.number>i&&(n.empty||n.to>o.from)&&(e(o,O,n),i=o.number),s=o.to+1}let r=t.changes(O);return{changes:O,range:x.range(r.mapPos(n.anchor,1),r.mapPos(n.head,1))}})}const GZ=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let i=Object.create(null),n=new $a(t,{overrideIndentation:r=>{let s=i[r];return s??-1}}),O=ld(t,(r,s,o)=>{let a=Ah(n,r.from);if(a==null)return;/\S/.test(r.text)||(a=0);let l=/^\s*/.exec(r.text)[0],c=Hr(t,a);(l!=c||o.fromt.readOnly?!1:(e(t.update(ld(t,(i,n)=>{n.push({from:i.from,insert:t.facet(YO)})}),{userEvent:"input.indent"})),!0),F1=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(ld(t,(i,n)=>{let O=/^\s*/.exec(i.text)[0];if(!O)return;let r=Oi(O,t.tabSize),s=0,o=Hr(t,Math.max(0,r-Mn(t)));for(;s(t.setTabFocusMode(),!0),IZ=[{key:"Ctrl-b",run:p1,shift:w1,preventDefault:!0},{key:"Ctrl-f",run:m1,shift:v1},{key:"Ctrl-p",run:S1,shift:R1},{key:"Ctrl-n",run:X1,shift:Z1},{key:"Ctrl-a",run:aZ,shift:PZ},{key:"Ctrl-e",run:lZ,shift:SZ},{key:"Ctrl-d",run:E1},{key:"Ctrl-h",run:ad},{key:"Ctrl-k",run:kZ},{key:"Ctrl-Alt-h",run:A1},{key:"Ctrl-o",run:ZZ},{key:"Ctrl-t",run:YZ},{key:"Ctrl-v",run:od}],AZ=[{key:"ArrowLeft",run:p1,shift:w1,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:J2,shift:dZ,preventDefault:!0},{mac:"Cmd-ArrowLeft",run:sZ,shift:mZ,preventDefault:!0},{key:"ArrowRight",run:m1,shift:v1,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:eZ,shift:uZ,preventDefault:!0},{mac:"Cmd-ArrowRight",run:oZ,shift:gZ,preventDefault:!0},{key:"ArrowUp",run:S1,shift:R1,preventDefault:!0},{mac:"Cmd-ArrowUp",run:q1,shift:W1},{mac:"Ctrl-ArrowUp",run:x1,shift:z1},{key:"ArrowDown",run:X1,shift:Z1,preventDefault:!0},{mac:"Cmd-ArrowDown",run:U1,shift:C1},{mac:"Ctrl-ArrowDown",run:od,shift:V1},{key:"PageUp",run:x1,shift:z1},{key:"PageDown",run:od,shift:V1},{key:"Home",run:rZ,shift:pZ,preventDefault:!0},{key:"Mod-Home",run:q1,shift:W1},{key:"End",run:OZ,shift:QZ,preventDefault:!0},{key:"Mod-End",run:U1,shift:C1},{key:"Enter",run:L1,shift:L1},{key:"Mod-a",run:XZ},{key:"Backspace",run:ad,shift:ad,preventDefault:!0},{key:"Delete",run:E1,preventDefault:!0},{key:"Mod-Backspace",mac:"Alt-Backspace",run:A1,preventDefault:!0},{key:"Mod-Delete",mac:"Alt-Delete",run:vZ,preventDefault:!0},{mac:"Mod-Backspace",run:_Z,preventDefault:!0},{mac:"Mod-Delete",run:RZ,preventDefault:!0}].concat(IZ.map(t=>({mac:t.key,run:t.run,shift:t.shift}))),MZ=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:iZ,shift:fZ},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:nZ,shift:$Z},{key:"Alt-ArrowUp",run:zZ},{key:"Shift-Alt-ArrowUp",run:qZ},{key:"Alt-ArrowDown",run:VZ},{key:"Shift-Alt-ArrowDown",run:UZ},{key:"Mod-Alt-ArrowUp",run:xZ},{key:"Mod-Alt-ArrowDown",run:TZ},{key:"Escape",run:wZ},{key:"Mod-Enter",run:jZ},{key:"Alt-l",mac:"Ctrl-l",run:bZ},{key:"Mod-i",run:yZ,preventDefault:!0},{key:"Mod-[",run:F1},{key:"Mod-]",run:B1},{key:"Mod-Alt-\\",run:GZ},{key:"Shift-Mod-k",run:WZ},{key:"Shift-Mod-\\",run:hZ},{key:"Mod-/",run:z2},{key:"Alt-A",run:q2},{key:"Ctrl-m",mac:"Shift-Alt-m",run:EZ}].concat(AZ),DZ={key:"Tab",run:B1,shift:F1},H1=typeof String.prototype.normalize=="function"?t=>t.normalize("NFKD"):t=>t;class VO{constructor(e,i,n=0,O=e.length,r,s){this.test=s,this.value={from:0,to:0,precise:!1},this.done=!1,this.matches=[],this.buffer="",this.bufferPos=0,this.iter=e.iterRange(n,O),this.bufferStart=n,this.normalize=r?o=>r(H1(o)):H1,this.query=this.normalize(i)}peek(){if(this.bufferPos==this.buffer.length){if(this.bufferStart+=this.buffer.length,this.iter.next(),this.iter.done)return-1;this.bufferPos=0,this.buffer=this.iter.value}return xt(this.buffer,this.bufferPos)}next(){for(;this.matches.length;)this.matches.pop();return this.nextOverlapping()}nextOverlapping(){for(;;){let e=this.peek();if(e<0)return this.done=!0,this;let i=gc(e),n=this.bufferStart+this.bufferPos;this.bufferPos+=mi(e);let O=this.normalize(i);if(O.length)for(let r=0,s=n,o=!0;;r++){let a=O.charCodeAt(r),l=this.match(a,s,o,this.bufferPos+this.bufferStart,r==O.length-1);if(l)return this.value=l,this;if(r==O.length-1)break;o&&rthis.to&&(this.curLine=this.curLine.slice(0,this.to-this.curLineStart)),this.iter.next())}nextLine(){this.curLineStart=this.curLineStart+this.curLine.length+1,this.curLineStart>this.to?this.curLine="":this.getLine(0)}next(){for(let e=this.matchPos-this.curLineStart;;){this.re.lastIndex=e;let i=this.matchPos<=this.to&&this.re.exec(this.curLine);if(i){let n=this.curLineStart+i.index,O=n+i[0].length;if(this.matchPos=Ta(this.text,O+(n==O?1:0)),n==this.curLineStart+this.curLine.length&&this.nextLine(),(nthis.value.to)&&(!this.test||this.test(n,O,i)))return this.value={from:n,to:O,precise:!0,match:i},this;e=this.matchPos-this.curLineStart}else if(this.curLineStart+this.curLine.length=n||O.to<=i){let o=new qO(i,e.sliceString(i,n));return hd.set(e,o),o}if(O.from==i&&O.to==n)return O;let{text:r,from:s}=O;return s>i&&(r=e.sliceString(i,s)+r,s=i),O.to=this.to?this.to:this.text.lineAt(e).to}next(){for(;;){let e=this.re.lastIndex=this.matchPos-this.flat.from,i=this.re.exec(this.flat.text);if(i&&!i[0]&&i.index==e&&(this.re.lastIndex=e+1,i=this.re.exec(this.flat.text)),i){let n=this.flat.from+i.index,O=n+i[0].length;if((this.flat.to>=this.to||i.index+i[0].length<=this.flat.text.length-10)&&(!this.test||this.test(n,O,i)))return this.value={from:n,to:O,precise:!0,match:i},this.matchPos=Ta(this.text,O+(n==O?1:0)),this}if(this.flat.to==this.to)return this.done=!0,this;this.flat=qO.get(this.text,this.flat.from,this.chunkEnd(this.flat.from+this.flat.text.length*2))}}}typeof Symbol<"u"&&(J1.prototype[Symbol.iterator]=eP.prototype[Symbol.iterator]=function(){return this});function LZ(t){try{return new RegExp(t,cd),!0}catch{return!1}}function Ta(t,e){if(e>=t.length)return e;let i=t.lineAt(e),n;for(;e=56320&&n<57344;)e++;return e}const NZ=t=>{let{state:e}=t,i=String(e.doc.lineAt(t.state.selection.main.head).number),{close:n,result:O}=hR(t,{label:e.phrase("Go to line"),input:{type:"text",name:"line",value:i},focus:!0,submitLabel:e.phrase("go")});return O.then(r=>{let s=r&&/^([+-])?(\d+)?(:\d+)?(%)?$/.exec(r.elements.line.value);if(!s){t.dispatch({effects:n});return}let o=e.doc.lineAt(e.selection.main.head),[,a,l,c,h]=s,d=c?+c.slice(1):0,u=l?+l:o.number;if(l&&h){let p=u/100;a&&(p=p*(a=="-"?-1:1)+o.number/e.doc.lines),u=Math.round(e.doc.lines*p)}else l&&a&&(u=u*(a=="-"?-1:1)+o.number);let $=e.doc.line(Math.max(1,Math.min(e.doc.lines,u))),Q=x.cursor($.from+Math.max(0,Math.min(d,$.length)));t.dispatch({effects:[n,R.scrollIntoView(Q.from,{y:"center"})],selection:Q})}),!0},BZ={highlightWordAroundCursor:!1,minSelectionLength:1,maxMatches:100,wholeWords:!1},FZ=Z.define({combine(t){return Si(t,BZ,{highlightWordAroundCursor:(e,i)=>e||i,minSelectionLength:Math.min,maxMatches:Math.min})}});function HZ(t){return[iY,tY]}const KZ=D.mark({class:"cm-selectionMatch"}),JZ=D.mark({class:"cm-selectionMatch cm-selectionMatch-main"});function tP(t,e,i,n){return(i==0||t(e.sliceDoc(i-1,i))!=ve.Word)&&(n==e.doc.length||t(e.sliceDoc(n,n+1))!=ve.Word)}function eY(t,e,i,n){return t(e.sliceDoc(i,i+1))==ve.Word&&t(e.sliceDoc(n-1,n))==ve.Word}const tY=We.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.selectionSet||t.docChanged||t.viewportChanged)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=t.state.facet(FZ),{state:i}=t,n=i.selection;if(n.ranges.length>1)return D.none;let O=n.main,r,s=null;if(O.empty){if(!e.highlightWordAroundCursor)return D.none;let a=i.wordAt(O.head);if(!a)return D.none;s=i.charCategorizer(O.head),r=i.sliceDoc(a.from,a.to)}else{let a=O.to-O.from;if(a200)return D.none;if(e.wholeWords){if(r=i.sliceDoc(O.from,O.to),s=i.charCategorizer(O.head),!(tP(s,i,O.from,O.to)&&eY(s,i,O.from,O.to)))return D.none}else if(r=i.sliceDoc(O.from,O.to),!r)return D.none}let o=[];for(let a of t.visibleRanges){let l=new VO(i.doc,r,a.from,a.to);for(;!l.next().done;){let{from:c,to:h}=l.value;if((!s||tP(s,i,c,h))&&(O.empty&&c<=O.from&&h>=O.to?o.push(JZ.range(c,h)):(c>=O.to||h<=O.from)&&o.push(KZ.range(c,h)),o.length>e.maxMatches))return D.none}}return D.set(o)}},{decorations:t=>t.decorations}),iY=R.baseTheme({".cm-selectionMatch":{backgroundColor:"#99ff7780"},".cm-searchMatch .cm-selectionMatch":{backgroundColor:"transparent"}}),nY=({state:t,dispatch:e})=>{let{selection:i}=t,n=x.create(i.ranges.map(O=>t.wordAt(O.head)||x.cursor(O.head)),i.mainIndex);return n.eq(i)?!1:(e(t.update({selection:n})),!0)};function OY(t,e){let{main:i,ranges:n}=t.selection,O=t.wordAt(i.head),r=O&&O.from==i.from&&O.to==i.to;for(let s=!1,o=new VO(t.doc,e,n[n.length-1].to);;)if(o.next(),o.done){if(s)return null;o=new VO(t.doc,e,0,Math.max(0,n[n.length-1].from-1)),s=!0}else{if(s&&n.some(a=>a.from==o.value.from))continue;if(r){let a=t.wordAt(o.value.from);if(!a||a.from!=o.value.from||a.to!=o.value.to)continue}return o.value}}const rY=({state:t,dispatch:e})=>{let{ranges:i}=t.selection;if(i.some(r=>r.from===r.to))return nY({state:t,dispatch:e});let n=t.sliceDoc(i[0].from,i[0].to);if(t.selection.ranges.some(r=>t.sliceDoc(r.from,r.to)!=n))return!1;let O=OY(t,n);return O?(e(t.update({selection:t.selection.addRange(x.range(O.from,O.to),!1),effects:R.scrollIntoView(O.to)})),!0):!1},UO=Z.define({combine(t){return Si(t,{top:!1,caseSensitive:!1,literal:!1,regexp:!1,wholeWord:!1,createPanel:e=>new gY(e),scrollToMatch:e=>R.scrollIntoView(e)})}});class iP{constructor(e){this.search=e.search,this.caseSensitive=!!e.caseSensitive,this.literal=!!e.literal,this.regexp=!!e.regexp,this.replace=e.replace||"",this.valid=!!this.search&&(!this.regexp||LZ(this.search)),this.unquoted=this.unquote(this.search),this.wholeWord=!!e.wholeWord,this.test=e.test}unquote(e){return this.literal?e:e.replace(/\\([nrt\\])/g,(i,n)=>n=="n"?` +`:n=="r"?"\r":n=="t"?" ":"\\")}eq(e){return this.search==e.search&&this.replace==e.replace&&this.caseSensitive==e.caseSensitive&&this.regexp==e.regexp&&this.wholeWord==e.wholeWord&&this.test==e.test}create(){return this.regexp?new hY(this):new aY(this)}getCursor(e,i=0,n){let O=e.doc?e:ae.create({doc:e});return n==null&&(n=O.doc.length),this.regexp?CO(this,O,i,n):WO(this,O,i,n)}}class nP{constructor(e){this.spec=e}}function sY(t,e,i){return(n,O,r,s)=>{if(i&&!i(n,O,r,s))return!1;let o=n>=s&&O<=s+r.length?r.slice(n-s,O-s):e.doc.sliceString(n,O);return t(o,e,n,O)}}function WO(t,e,i,n){let O;return t.wholeWord&&(O=oY(e.doc,e.charCategorizer(e.selection.main.head))),t.test&&(O=sY(t.test,e,O)),new VO(e.doc,t.unquoted,i,n,t.caseSensitive?void 0:r=>r.toLowerCase(),O)}function oY(t,e){return(i,n,O,r)=>((r>i||r+O.length=i)return null;O.push(n.value)}return O}highlight(e,i,n,O){let r=WO(this.spec,e,Math.max(0,i-this.spec.unquoted.length),Math.min(n+this.spec.unquoted.length,e.doc.length));for(;!r.next().done;)O(r.value.from,r.value.to)}}function lY(t,e,i){return(n,O,r)=>(!i||i(n,O,r))&&t(r[0],e,n,O)}function CO(t,e,i,n){let O;return t.wholeWord&&(O=cY(e.charCategorizer(e.selection.main.head))),t.test&&(O=lY(t.test,e,O)),new J1(e.doc,t.search,{ignoreCase:!t.caseSensitive,test:O},i,n)}function wa(t,e){return t.slice(Be(t,e,!1),e)}function va(t,e){return t.slice(e,Be(t,e))}function cY(t){return(e,i,n)=>!n[0].length||(t(wa(n.input,n.index))!=ve.Word||t(va(n.input,n.index))!=ve.Word)&&(t(va(n.input,n.index+n[0].length))!=ve.Word||t(wa(n.input,n.index+n[0].length))!=ve.Word)}class hY extends nP{nextMatch(e,i,n){let O=CO(this.spec,e,n,e.doc.length).next();return O.done&&(O=CO(this.spec,e,0,i).next()),O.done?null:O.value}prevMatchInRange(e,i,n){for(let O=1;;O++){let r=Math.max(i,n-O*1e4),s=CO(this.spec,e,r,n),o=null;for(;!s.next().done;)o=s.value;if(o&&(r==i||o.from>r+10))return o;if(r==i)return null}}prevMatch(e,i,n){return this.prevMatchInRange(e,0,i)||this.prevMatchInRange(e,n,e.doc.length)}getReplacement(e){return this.spec.unquote(this.spec.replace).replace(/\$([$&]|\d+)/g,(i,n)=>{if(n=="&")return e.match[0];if(n=="$")return"$";for(let O=n.length;O>0;O--){let r=+n.slice(0,O);if(r>0&&r=i)return null;O.push(n.value)}return O}highlight(e,i,n,O){let r=CO(this.spec,e,Math.max(0,i-250),Math.min(n+250,e.doc.length));for(;!r.next().done;)O(r.value.from,r.value.to)}}const is=K.define(),dd=K.define(),yn=nt.define({create(t){return new ud($d(t).create(),null)},update(t,e){for(let i of e.effects)i.is(is)?t=new ud(i.value.create(),t.panel):i.is(dd)&&(t=new ud(t.query,i.value?fd:null));return t},provide:t=>Mr.from(t,e=>e.panel)});class ud{constructor(e,i){this.query=e,this.panel=i}}const dY=D.mark({class:"cm-searchMatch"}),uY=D.mark({class:"cm-searchMatch cm-searchMatch-selected"}),fY=We.fromClass(class{constructor(t){this.view=t,this.decorations=this.highlight(t.state.field(yn))}update(t){let e=t.state.field(yn);(e!=t.startState.field(yn)||t.docChanged||t.selectionSet||t.viewportChanged)&&(this.decorations=this.highlight(e))}highlight({query:t,panel:e}){if(!e||!t.spec.valid)return D.none;let{view:i}=this,n=new Ei;for(let O=0,r=i.visibleRanges,s=r.length;Or[O+1].from-2*250;)a=r[++O].to;t.highlight(i.state,o,a,(l,c)=>{let h=i.state.selection.ranges.some(d=>d.from==l&&d.to==c);n.add(l,c,h?uY:dY)})}return n.finish()}},{decorations:t=>t.decorations});function ns(t){return e=>{let i=e.state.field(yn,!1);return i&&i.query.spec.valid?t(e,i):oP(e)}}const ka=ns((t,{query:e})=>{let{to:i}=t.state.selection.main,n=e.nextMatch(t.state,i,i);if(!n)return!1;let O=x.single(n.from,n.to),r=t.state.facet(UO);return t.dispatch({selection:O,effects:[Qd(t,n),r.scrollToMatch(O.main,t)],userEvent:"select.search"}),sP(t),!0}),_a=ns((t,{query:e})=>{let{state:i}=t,{from:n}=i.selection.main,O=e.prevMatch(i,n,n);if(!O)return!1;let r=x.single(O.from,O.to),s=t.state.facet(UO);return t.dispatch({selection:r,effects:[Qd(t,O),s.scrollToMatch(r.main,t)],userEvent:"select.search"}),sP(t),!0}),$Y=ns((t,{query:e})=>{let i=e.matchAll(t.state,1e3);return!i||!i.length?!1:(t.dispatch({selection:x.create(i.map(n=>x.range(n.from,n.to))),userEvent:"select.search.matches"}),!0)}),QY=({state:t,dispatch:e})=>{let i=t.selection;if(i.ranges.length>1||i.main.empty)return!1;let{from:n,to:O}=i.main,r=[],s=0;for(let o=new VO(t.doc,t.sliceDoc(n,O));!o.next().done;){if(r.length>1e3)return!1;o.value.from==n&&(s=r.length),r.push(x.range(o.value.from,o.value.to))}return e(t.update({selection:x.create(r,s),userEvent:"select.search.matches"})),!0},OP=ns((t,{query:e})=>{let{state:i}=t,{from:n,to:O}=i.selection.main;if(i.readOnly)return!1;let r=e.nextMatch(i,n,n);if(!r)return!1;let s=r,o=[],a,l,c=[];s.precise?s.from==n&&s.to==O&&(l=i.toText(e.getReplacement(s)),o.push({from:s.from,to:s.to,insert:l}),c.push(R.announce.of(i.phrase("replaced match on line $",i.doc.lineAt(n).number)+"."))):s=e.nextMatch(i,s.from,s.to);let h=t.state.changes(o);return s&&(a=x.single(s.from,s.to).map(h),c.push(Qd(t,s)),c.push(i.facet(UO).scrollToMatch(a.main,t))),t.dispatch({changes:h,selection:a,effects:c,userEvent:"input.replace"}),!0}),pY=ns((t,{query:e})=>{if(t.state.readOnly)return!1;let i=[];for(let O of e.matchAll(t.state,1e9)){let{from:r,to:s,precise:o}=O;o&&i.push({from:r,to:s,insert:e.getReplacement(O)})}if(!i.length)return!1;let n=t.state.phrase("replaced $ matches",i.length)+".";return t.dispatch({changes:i,effects:R.announce.of(n),userEvent:"input.replace.all"}),!0});function fd(t){return t.state.facet(UO).createPanel(t)}function $d(t,e){var i,n,O,r,s;let o=t.selection.main,a=o.empty||o.to>o.from+100?"":t.sliceDoc(o.from,o.to);if(e&&!a)return e;let l=t.facet(UO);return new iP({search:((i=e?.literal)!==null&&i!==void 0?i:l.literal)?a:a.replace(/\n/g,"\\n"),caseSensitive:(n=e?.caseSensitive)!==null&&n!==void 0?n:l.caseSensitive,literal:(O=e?.literal)!==null&&O!==void 0?O:l.literal,regexp:(r=e?.regexp)!==null&&r!==void 0?r:l.regexp,wholeWord:(s=e?.wholeWord)!==null&&s!==void 0?s:l.wholeWord})}function rP(t){let e=vh(t,fd);return e&&e.dom.querySelector("[main-field]")}function sP(t){let e=rP(t);e&&e==t.root.activeElement&&e.select()}const oP=t=>{let e=t.state.field(yn,!1);if(e&&e.panel){let i=rP(t);if(i&&i!=t.root.activeElement){let n=$d(t.state,e.query.spec);n.valid&&t.dispatch({effects:is.of(n)}),i.focus(),i.select()}}else t.dispatch({effects:[dd.of(!0),e?is.of($d(t.state,e.query.spec)):K.appendConfig.of(SY)]});return!0},aP=t=>{let e=t.state.field(yn,!1);if(!e||!e.panel)return!1;let i=vh(t,fd);return i&&i.dom.contains(t.root.activeElement)&&t.focus(),t.dispatch({effects:dd.of(!1)}),!0},mY=[{key:"Mod-f",run:oP,scope:"editor search-panel"},{key:"F3",run:ka,shift:_a,scope:"editor search-panel",preventDefault:!0},{key:"Mod-g",run:ka,shift:_a,scope:"editor search-panel",preventDefault:!0},{key:"Escape",run:aP,scope:"editor search-panel"},{key:"Mod-Shift-l",run:QY},{key:"Mod-Alt-g",run:NZ},{key:"Mod-d",run:rY,preventDefault:!0}];class gY{constructor(e){this.view=e;let i=this.query=e.state.field(yn).query.spec;this.commit=this.commit.bind(this),this.searchField=pe("input",{value:i.search,placeholder:Ct(e,"Find"),"aria-label":Ct(e,"Find"),class:"cm-textfield",name:"search",form:"","main-field":"true",onchange:this.commit,onkeyup:this.commit}),this.replaceField=pe("input",{value:i.replace,placeholder:Ct(e,"Replace"),"aria-label":Ct(e,"Replace"),class:"cm-textfield",name:"replace",form:"",onchange:this.commit,onkeyup:this.commit}),this.caseField=pe("input",{type:"checkbox",name:"case",form:"",checked:i.caseSensitive,onchange:this.commit}),this.reField=pe("input",{type:"checkbox",name:"re",form:"",checked:i.regexp,onchange:this.commit}),this.wordField=pe("input",{type:"checkbox",name:"word",form:"",checked:i.wholeWord,onchange:this.commit});function n(O,r,s){return pe("button",{class:"cm-button",name:O,onclick:r,type:"button"},s)}this.dom=pe("div",{onkeydown:O=>this.keydown(O),class:"cm-search"},[this.searchField,n("next",()=>ka(e),[Ct(e,"next")]),n("prev",()=>_a(e),[Ct(e,"previous")]),n("select",()=>$Y(e),[Ct(e,"all")]),pe("label",null,[this.caseField,Ct(e,"match case")]),pe("label",null,[this.reField,Ct(e,"regexp")]),pe("label",null,[this.wordField,Ct(e,"by word")]),...e.state.readOnly?[]:[pe("br"),this.replaceField,n("replace",()=>OP(e),[Ct(e,"replace")]),n("replaceAll",()=>pY(e),[Ct(e,"replace all")])],pe("button",{name:"close",onclick:()=>aP(e),"aria-label":Ct(e,"close"),type:"button"},["×"])])}commit(){let e=new iP({search:this.searchField.value,caseSensitive:this.caseField.checked,regexp:this.reField.checked,wholeWord:this.wordField.checked,replace:this.replaceField.value});e.eq(this.query)||(this.query=e,this.view.dispatch({effects:is.of(e)}))}keydown(e){X_(this.view,e,"search-panel")?e.preventDefault():e.keyCode==13&&e.target==this.searchField?(e.preventDefault(),(e.shiftKey?_a:ka)(this.view)):e.keyCode==13&&e.target==this.replaceField&&(e.preventDefault(),OP(this.view))}update(e){for(let i of e.transactions)for(let n of i.effects)n.is(is)&&!n.value.eq(this.query)&&this.setQuery(n.value)}setQuery(e){this.query=e,this.searchField.value=e.search,this.replaceField.value=e.replace,this.caseField.checked=e.caseSensitive,this.reField.checked=e.regexp,this.wordField.checked=e.wholeWord}mount(){this.searchField.select()}get pos(){return 80}get top(){return this.view.state.facet(UO).top}}function Ct(t,e){return t.state.phrase(e)}const Ra=30,Za=/[\s\.,:;?!]/;function Qd(t,{from:e,to:i}){let n=t.state.doc.lineAt(e),O=t.state.doc.lineAt(i).to,r=Math.max(n.from,e-Ra),s=Math.min(O,i+Ra),o=t.state.sliceDoc(r,s);if(r!=n.from){for(let a=0;ao.length-Ra;a--)if(!Za.test(o[a-1])&&Za.test(o[a])){o=o.slice(0,a);break}}return R.announce.of(`${t.state.phrase("current match")}. ${o} ${t.state.phrase("on line")} ${n.number}.`)}const PY=R.baseTheme({".cm-panel.cm-search":{padding:"2px 6px 4px",position:"relative","& [name=close]":{position:"absolute",top:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:0,margin:0},"& input, & button, & label":{margin:".2em .6em .2em 0"},"& input[type=checkbox]":{marginRight:".2em"},"& label":{fontSize:"80%",whiteSpace:"pre"}},"&light .cm-searchMatch":{backgroundColor:"#ffff0054"},"&dark .cm-searchMatch":{backgroundColor:"#00ffff8a"},"&light .cm-searchMatch-selected":{backgroundColor:"#ff6a0054"},"&dark .cm-searchMatch-selected":{backgroundColor:"#ff00ff8a"}}),SY=[yn,Gi.low(fY),PY];class pd{constructor(e,i,n,O){this.state=e,this.pos=i,this.explicit=n,this.view=O,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(e){let i=$e(this.state).resolveInner(this.pos,-1);for(;i&&e.indexOf(i.name)<0;)i=i.parent;return i?{from:i.from,to:this.pos,text:this.state.sliceDoc(i.from,this.pos),type:i.type}:null}matchBefore(e){let i=this.state.doc.lineAt(this.pos),n=Math.max(i.from,this.pos-250),O=i.text.slice(n-i.from,this.pos-i.from),r=O.search(hP(e,!1));return r<0?null:{from:n+r,to:this.pos,text:O.slice(r)}}get aborted(){return this.abortListeners==null}addEventListener(e,i,n){e=="abort"&&this.abortListeners&&(this.abortListeners.push(i),n&&n.onDocChange&&(this.abortOnDocChange=!0))}}function lP(t){let e=Object.keys(t).join(""),i=/\w/.test(e);return i&&(e=e.replace(/\w/g,"")),`[${i?"\\w":""}${e.replace(/[^\w\s]/g,"\\$&")}]`}function XY(t){let e=Object.create(null),i=Object.create(null);for(let{label:O}of t){e[O[0]]=!0;for(let r=1;rtypeof O=="string"?{label:O}:O),[i,n]=e.every(O=>/^\w+$/.test(O.label))?[/\w*$/,/\w+$/]:XY(e);return O=>{let r=O.matchBefore(n);return r||O.explicit?{from:r?r.from:O.pos,options:e,validFor:i}:null}}function md(t,e){return i=>{for(let n=$e(i.state).resolveInner(i.pos,-1);n;n=n.parent){if(t.indexOf(n.name)>-1)return null;if(n.type.isTop)break}return e(i)}}class cP{constructor(e,i,n,O){this.completion=e,this.source=i,this.match=n,this.score=O}}function Ln(t){return t.selection.main.from}function hP(t,e){var i;let{source:n}=t,O=e&&n[0]!="^",r=n[n.length-1]!="$";return!O&&!r?t:new RegExp(`${O?"^":""}(?:${n})${r?"$":""}`,(i=t.flags)!==null&&i!==void 0?i:t.ignoreCase?"i":"")}const gd=Pi.define();function bY(t,e,i,n){let{main:O}=t.selection,r=i-O.from,s=n-O.from;return{...t.changeByRange(o=>{if(o!=O&&i!=n&&t.sliceDoc(o.from+r,o.from+s)!=t.sliceDoc(i,n))return{range:o};let a=t.toText(e);return{changes:{from:o.from+r,to:n==O.from?o.to:o.from+s,insert:a},range:x.cursor(o.from+r+a.length)}}),scrollIntoView:!0,userEvent:"input.complete"}}const dP=new WeakMap;function yY(t){if(!Array.isArray(t))return t;let e=dP.get(t);return e||dP.set(t,e=Ya(t)),e}const za=K.define(),Os=K.define();class xY{constructor(e){this.pattern=e,this.chars=[],this.folded=[],this.any=[],this.precise=[],this.byWord=[],this.score=0,this.matched=[];for(let i=0;i=48&&X<=57||X>=97&&X<=122?2:X>=65&&X<=90?1:0:(y=gc(X))!=y.toLowerCase()?1:y!=y.toUpperCase()?2:0;(!P||T==1&&p||b==0&&T!=0)&&(i[h]==X||n[h]==X&&(d=!0)?s[h++]=P:s.length&&(m=!1)),b=T,P+=mi(X)}return h==a&&s[0]==0&&m?this.result(-100+(d?-200:0),s,e):u==a&&$==0?this.ret(-200-e.length+(Q==e.length?0:-100),[0,Q]):o>-1?this.ret(-700-e.length,[o,o+this.pattern.length]):u==a?this.ret(-900-e.length,[$,Q]):h==a?this.result(-100+(d?-200:0)+-700+(m?0:-1100),s,e):i.length==2?null:this.result((O[0]?-700:0)+-200+-1100,O,e)}result(e,i,n){let O=[],r=0;for(let s of i){let o=s+(this.astral?mi(xt(n,s)):1);r&&O[r-1]==s?O[r-1]=o:(O[r++]=s,O[r++]=o)}return this.ret(e-n.length,O)}}class TY{constructor(e){this.pattern=e,this.matched=[],this.score=0,this.folded=e.toLowerCase()}match(e){if(e.length!1,activateOnTypingDelay:100,selectOnOpen:!0,override:null,closeOnBlur:!0,maxRenderedOptions:100,defaultKeymap:!0,tooltipClass:()=>"",optionClass:()=>"",aboveCursor:!1,icons:!0,addToOptions:[],positionInfo:wY,filterStrict:!1,compareCompletions:(e,i)=>(e.sortText||e.label).localeCompare(i.sortText||i.label),interactionDelay:75,updateSyncTime:100},{defaultKeymap:(e,i)=>e&&i,closeOnBlur:(e,i)=>e&&i,icons:(e,i)=>e&&i,tooltipClass:(e,i)=>n=>uP(e(n),i(n)),optionClass:(e,i)=>n=>uP(e(n),i(n)),addToOptions:(e,i)=>e.concat(i),filterStrict:(e,i)=>e||i})}});function uP(t,e){return t?e?t+" "+e:t:e}function wY(t,e,i,n,O,r){let s=t.textDirection==ge.RTL,o=s,a=!1,l="top",c,h,d=e.left-O.left,u=O.right-e.right,$=n.right-n.left,Q=n.bottom-n.top;if(o&&d=Q||P>e.top?c=i.bottom-e.top:(l="bottom",c=e.bottom-i.top)}let p=(e.bottom-e.top)/r.offsetHeight,m=(e.right-e.left)/r.offsetWidth;return{style:`${l}: ${c/p}px; max-width: ${h/m}px`,class:"cm-completionInfo-"+(a?s?"left-narrow":"right-narrow":o?"left":"right")}}const Pd=K.define();function vY(t){let e=t.addToOptions.slice();return t.icons&&e.push({render(i){let n=document.createElement("div");return n.classList.add("cm-completionIcon"),i.type&&n.classList.add(...i.type.split(/\s+/g).map(O=>"cm-completionIcon-"+O)),n.setAttribute("aria-hidden","true"),n},position:20}),e.push({render(i,n,O,r){let s=document.createElement("span");s.className="cm-completionLabel";let o=i.displayLabel||i.label,a=0;for(let l=0;la&&s.appendChild(document.createTextNode(o.slice(a,c)));let d=s.appendChild(document.createElement("span"));d.appendChild(document.createTextNode(o.slice(c,h))),d.className="cm-completionMatchedText",a=h}return ai.position-n.position).map(i=>i.render)}function Sd(t,e,i){if(t<=i)return{from:0,to:t};if(e<0&&(e=0),e<=t>>1){let O=Math.floor(e/i);return{from:O*i,to:(O+1)*i}}let n=Math.ceil((t-e)/i);return{from:t-n*i,to:t-(n-1)*i}}class kY{constructor(e,i,n){this.view=e,this.stateField=i,this.applyCompletion=n,this.info=null,this.infoDestroy=null,this.placeInfoReq={read:()=>this.measureInfo(),write:a=>this.placeInfo(a),key:this},this.space=null,this.currentClass="";let O=e.state.field(i),{options:r,selected:s}=O.open,o=e.state.facet(He);this.optionContent=vY(o),this.optionClass=o.optionClass,this.tooltipClass=o.tooltipClass,this.range=Sd(r.length,s,o.maxRenderedOptions),this.dom=document.createElement("div"),this.dom.className="cm-tooltip-autocomplete",this.updateTooltipClass(e.state),this.dom.addEventListener("mousedown",a=>{let{options:l}=e.state.field(i).open;for(let c=a.target,h;c&&c!=this.dom;c=c.parentNode)if(c.nodeName=="LI"&&(h=/-(\d+)$/.exec(c.id))&&+h[1]this.list.lastChild.getBoundingClientRect().bottom?this.range.to:null;c!=null&&(e.dispatch({effects:Pd.of(c)}),a.preventDefault())}}),this.dom.addEventListener("focusout",a=>{let l=e.state.field(this.stateField,!1);l&&l.tooltip&&e.state.facet(He).closeOnBlur&&a.relatedTarget!=e.contentDOM&&e.dispatch({effects:Os.of(null)})}),this.showOptions(r,O.id)}mount(){this.updateSel()}showOptions(e,i){this.list&&this.list.remove(),this.list=this.dom.appendChild(this.createListBox(e,i,this.range)),this.list.addEventListener("scroll",()=>{this.info&&this.view.requestMeasure(this.placeInfoReq)})}update(e){var i;let n=e.state.field(this.stateField),O=e.startState.field(this.stateField);if(this.updateTooltipClass(e.state),n!=O){let{options:r,selected:s,disabled:o}=n.open;(!O.open||O.open.options!=r)&&(this.range=Sd(r.length,s,e.state.facet(He).maxRenderedOptions),this.showOptions(r,n.id)),this.updateSel(),o!=((i=O.open)===null||i===void 0?void 0:i.disabled)&&this.dom.classList.toggle("cm-tooltip-autocomplete-disabled",!!o)}}updateTooltipClass(e){let i=this.tooltipClass(e);if(i!=this.currentClass){for(let n of this.currentClass.split(" "))n&&this.dom.classList.remove(n);for(let n of i.split(" "))n&&this.dom.classList.add(n);this.currentClass=i}}positioned(e){this.space=e,this.info&&this.view.requestMeasure(this.placeInfoReq)}updateSel(){let e=this.view.state.field(this.stateField),i=e.open;(i.selected>-1&&i.selected=this.range.to)&&(this.range=Sd(i.options.length,i.selected,this.view.state.facet(He).maxRenderedOptions),this.showOptions(i.options,e.id));let n=this.updateSelectedOption(i.selected);if(n){this.destroyInfo();let{completion:O}=i.options[i.selected],{info:r}=O;if(!r)return;let s=typeof r=="string"?document.createTextNode(r):r(O);if(!s)return;"then"in s?s.then(o=>{o&&this.view.state.field(this.stateField,!1)==e&&this.addInfoPane(o,O)}).catch(o=>Tt(this.view.state,o,"completion info")):(this.addInfoPane(s,O),n.setAttribute("aria-describedby",this.info.id))}}addInfoPane(e,i){this.destroyInfo();let n=this.info=document.createElement("div");if(n.className="cm-tooltip cm-completionInfo",n.id="cm-completionInfo-"+Math.floor(Math.random()*65535).toString(16),e.nodeType!=null)n.appendChild(e),this.infoDestroy=null;else{let{dom:O,destroy:r}=e;n.appendChild(O),this.infoDestroy=r||null}this.dom.appendChild(n),this.view.requestMeasure(this.placeInfoReq)}updateSelectedOption(e){let i=null;for(let n=this.list.firstChild,O=this.range.from;n;n=n.nextSibling,O++)n.nodeName!="LI"||!n.id?O--:O==e?n.hasAttribute("aria-selected")||(n.setAttribute("aria-selected","true"),i=n):n.hasAttribute("aria-selected")&&(n.removeAttribute("aria-selected"),n.removeAttribute("aria-describedby"));return i&&RY(this.list,i),i}measureInfo(){let e=this.dom.querySelector("[aria-selected]");if(!e||!this.info)return null;let i=this.dom.getBoundingClientRect(),n=this.info.getBoundingClientRect(),O=e.getBoundingClientRect(),r=this.space;if(!r){let s=this.dom.ownerDocument.documentElement;r={left:0,top:0,right:s.clientWidth,bottom:s.clientHeight}}return O.top>Math.min(r.bottom,i.bottom)-10||O.bottom{s.target==O&&s.preventDefault()});let r=null;for(let s=n.from;sn.from||n.from==0))if(r=d,typeof l!="string"&&l.header)O.appendChild(l.header(l));else{let u=O.appendChild(document.createElement("completion-section"));u.textContent=d}}const c=O.appendChild(document.createElement("li"));c.id=i+"-"+s,c.setAttribute("role","option");let h=this.optionClass(o);h&&(c.className=h);for(let d of this.optionContent){let u=d(o,this.view.state,this.view,a);u&&c.appendChild(u)}}return n.from&&O.classList.add("cm-completionListIncompleteTop"),n.tonew kY(i,t,e)}function RY(t,e){let i=t.getBoundingClientRect(),n=e.getBoundingClientRect(),O=i.height/t.offsetHeight;n.topi.bottom&&(t.scrollTop+=(n.bottom-i.bottom)/O)}function fP(t){return(t.boost||0)*100+(t.apply?10:0)+(t.info?5:0)+(t.type?1:0)}function ZY(t,e){let i=[],n=null,O=null,r=c=>{i.push(c);let{section:h}=c.completion;if(h){n||(n=[]);let d=typeof h=="string"?h:h.name;n.some(u=>u.name==d)||n.push(typeof h=="string"?{name:d}:h)}},s=e.facet(He);for(let c of t)if(c.hasResult()){let h=c.result.getMatch;if(c.result.filter===!1)for(let d of c.result.options)r(new cP(d,c.source,h?h(d):[],1e9-i.length));else{let d=e.sliceDoc(c.from,c.to),u,$=s.filterStrict?new TY(d):new xY(d);for(let Q of c.result.options)if(u=$.match(Q.label)){let p=Q.displayLabel?h?h(Q,u.matched):[]:u.matched,m=u.score+(Q.boost||0);if(r(new cP(Q,c.source,p,m)),typeof Q.section=="object"&&Q.section.rank==="dynamic"){let{name:P}=Q.section;O||(O=Object.create(null)),O[P]=Math.max(m,O[P]||-1e9)}}}}if(n){let c=Object.create(null),h=0,d=(u,$)=>(u.rank==="dynamic"&&$.rank==="dynamic"?O[$.name]-O[u.name]:0)||(typeof u.rank=="number"?u.rank:1e9)-(typeof $.rank=="number"?$.rank:1e9)||(u.name<$.name?-1:1);for(let u of n.sort(d))h-=1e5,c[u.name]=h;for(let u of i){let{section:$}=u.completion;$&&(u.score+=c[typeof $=="string"?$:$.name])}}let o=[],a=null,l=s.compareCompletions;for(let c of i.sort((h,d)=>d.score-h.score||l(h.completion,d.completion))){let h=c.completion;!a||a.label!=h.label||a.detail!=h.detail||a.type!=null&&h.type!=null&&a.type!=h.type||a.apply!=h.apply||a.boost!=h.boost?o.push(c):fP(c.completion)>fP(a)&&(o[o.length-1]=c),a=c.completion}return o}class jO{constructor(e,i,n,O,r,s){this.options=e,this.attrs=i,this.tooltip=n,this.timestamp=O,this.selected=r,this.disabled=s}setSelected(e,i){return e==this.selected||e>=this.options.length?this:new jO(this.options,$P(i,e),this.tooltip,this.timestamp,e,this.disabled)}static build(e,i,n,O,r,s){if(O&&!s&&e.some(l=>l.isPending))return O.setDisabled();let o=ZY(e,i);if(!o.length)return O&&e.some(l=>l.isPending)?O.setDisabled():null;let a=i.facet(He).selectOnOpen?0:-1;if(O&&O.selected!=a&&O.selected!=-1){let l=O.options[O.selected].completion;for(let c=0;cc.hasResult()?Math.min(l,c.from):l,1e8),create:WY,above:r.aboveCursor},O?O.timestamp:Date.now(),a,!1)}map(e){return new jO(this.options,this.attrs,{...this.tooltip,pos:e.mapPos(this.tooltip.pos)},this.timestamp,this.selected,this.disabled)}setDisabled(){return new jO(this.options,this.attrs,this.tooltip,this.timestamp,this.selected,!0)}}class Va{constructor(e,i,n){this.active=e,this.id=i,this.open=n}static start(){return new Va(qY,"cm-ac-"+Math.floor(Math.random()*2e6).toString(36),null)}update(e){let{state:i}=e,n=i.facet(He),r=(n.override||i.languageDataAt("autocomplete",Ln(i)).map(yY)).map(a=>(this.active.find(c=>c.source==a)||new Ht(a,this.active.some(c=>c.state!=0)?1:0)).update(e,n));r.length==this.active.length&&r.every((a,l)=>a==this.active[l])&&(r=this.active);let s=this.open,o=e.effects.some(a=>a.is(Xd));s&&e.docChanged&&(s=s.map(e.changes)),e.selection||r.some(a=>a.hasResult()&&e.changes.touchesRange(a.from,a.to))||!YY(r,this.active)||o?s=jO.build(r,i,this.id,s,n,o):s&&s.disabled&&!r.some(a=>a.isPending)&&(s=null),!s&&r.every(a=>!a.isPending)&&r.some(a=>a.hasResult())&&(r=r.map(a=>a.hasResult()?new Ht(a.source,0):a));for(let a of e.effects)a.is(Pd)&&(s=s&&s.setSelected(a.value,this.id));return r==this.active&&s==this.open?this:new Va(r,this.id,s)}get tooltip(){return this.open?this.open.tooltip:null}get attrs(){return this.open?this.open.attrs:this.active.length?zY:VY}}function YY(t,e){if(t==e)return!0;for(let i=0,n=0;;){for(;i-1&&(i["aria-activedescendant"]=t+"-"+e),i}const qY=[];function QP(t,e){if(t.isUserEvent("input.complete")){let n=t.annotation(gd);if(n&&e.activateOnCompletion(n))return 12}let i=t.isUserEvent("input.type");return i&&e.activateOnTyping?5:i?1:t.isUserEvent("delete.backward")?2:t.selection?8:t.docChanged?16:0}class Ht{constructor(e,i,n=!1){this.source=e,this.state=i,this.explicit=n}hasResult(){return!1}get isPending(){return this.state==1}update(e,i){let n=QP(e,i),O=this;(n&8||n&16&&this.touches(e))&&(O=new Ht(O.source,0)),n&4&&O.state==0&&(O=new Ht(this.source,1)),O=O.updateFor(e,n);for(let r of e.effects)if(r.is(za))O=new Ht(O.source,1,r.value);else if(r.is(Os))O=new Ht(O.source,0);else if(r.is(Xd))for(let s of r.value)s.source==O.source&&(O=s);return O}updateFor(e,i){return this.map(e.changes)}map(e){return this}touches(e){return e.changes.touchesRange(Ln(e.state))}}class GO extends Ht{constructor(e,i,n,O,r,s){super(e,3,i),this.limit=n,this.result=O,this.from=r,this.to=s}hasResult(){return!0}updateFor(e,i){var n;if(!(i&3))return this.map(e.changes);let O=this.result;O.map&&!e.changes.empty&&(O=O.map(O,e.changes));let r=e.changes.mapPos(this.from),s=e.changes.mapPos(this.to,1),o=Ln(e.state);if(o>s||!O||i&2&&(Ln(e.startState)==this.from||oi.map(e))}}),_t=nt.define({create(){return Va.start()},update(t,e){return t.update(e)},provide:t=>[wh.from(t,e=>e.tooltip),R.contentAttributes.from(t,e=>e.attrs)]});function bd(t,e){const i=e.completion.apply||e.completion.label;let n=t.state.field(_t).active.find(O=>O.source==e.source);return n instanceof GO?(typeof i=="string"?t.dispatch({...bY(t.state,i,n.from,n.to),annotations:gd.of(e.completion)}):i(t,e.completion,n.from,n.to),!0):!1}const WY=_Y(_t,bd);function qa(t,e="option"){return i=>{let n=i.state.field(_t,!1);if(!n||!n.open||n.open.disabled||Date.now()-n.open.timestamp-1?n.open.selected+O*(t?1:-1):t?0:s-1;return o<0?o=e=="page"?0:s-1:o>=s&&(o=e=="page"?s-1:0),i.dispatch({effects:Pd.of(o)}),!0}}const CY=t=>{let e=t.state.field(_t,!1);return t.state.readOnly||!e||!e.open||e.open.selected<0||e.open.disabled||Date.now()-e.open.timestampt.state.field(_t,!1)?(t.dispatch({effects:za.of(!0)}),!0):!1,jY=t=>{let e=t.state.field(_t,!1);return!e||!e.active.some(i=>i.state!=0)?!1:(t.dispatch({effects:Os.of(null)}),!0)};class GY{constructor(e,i){this.active=e,this.context=i,this.time=Date.now(),this.updates=[],this.done=void 0}}const EY=50,IY=1e3,AY=We.fromClass(class{constructor(t){this.view=t,this.debounceUpdate=-1,this.running=[],this.debounceAccept=-1,this.pendingStart=!1,this.composing=0;for(let e of t.state.field(_t).active)e.isPending&&this.startQuery(e)}update(t){let e=t.state.field(_t),i=t.state.facet(He);if(!t.selectionSet&&!t.docChanged&&t.startState.field(_t)==e)return;let n=t.transactions.some(r=>{let s=QP(r,i);return s&8||(r.selection||r.docChanged)&&!(s&3)});for(let r=0;rEY&&Date.now()-s.time>IY){for(let o of s.context.abortListeners)try{o()}catch(a){Tt(this.view.state,a)}s.context.abortListeners=null,this.running.splice(r--,1)}else s.updates.push(...t.transactions)}this.debounceUpdate>-1&&clearTimeout(this.debounceUpdate),t.transactions.some(r=>r.effects.some(s=>s.is(za)))&&(this.pendingStart=!0);let O=this.pendingStart?50:i.activateOnTypingDelay;if(this.debounceUpdate=e.active.some(r=>r.isPending&&!this.running.some(s=>s.active.source==r.source))?setTimeout(()=>this.startUpdate(),O):-1,this.composing!=0)for(let r of t.transactions)r.isUserEvent("input.type")?this.composing=2:this.composing==2&&r.selection&&(this.composing=3)}startUpdate(){this.debounceUpdate=-1,this.pendingStart=!1;let{state:t}=this.view,e=t.field(_t);for(let i of e.active)i.isPending&&!this.running.some(n=>n.active.source==i.source)&&this.startQuery(i);this.running.length&&e.open&&e.open.disabled&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(He).updateSyncTime))}startQuery(t){let{state:e}=this.view,i=Ln(e),n=new pd(e,i,t.explicit,this.view),O=new GY(t,n);this.running.push(O),Promise.resolve(t.source(n)).then(r=>{O.context.aborted||(O.done=r||null,this.scheduleAccept())},r=>{this.view.dispatch({effects:Os.of(null)}),Tt(this.view.state,r)})}scheduleAccept(){this.running.every(t=>t.done!==void 0)?this.accept():this.debounceAccept<0&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(He).updateSyncTime))}accept(){var t;this.debounceAccept>-1&&clearTimeout(this.debounceAccept),this.debounceAccept=-1;let e=[],i=this.view.state.facet(He),n=this.view.state.field(_t);for(let O=0;Oo.source==r.active.source);if(s&&s.isPending)if(r.done==null){let o=new Ht(r.active.source,0);for(let a of r.updates)o=o.update(a,i);o.isPending||e.push(o)}else this.startQuery(s)}(e.length||n.open&&n.open.disabled)&&this.view.dispatch({effects:Xd.of(e)})}},{eventHandlers:{blur(t){let e=this.view.state.field(_t,!1);if(e&&e.tooltip&&this.view.state.facet(He).closeOnBlur){let i=e.open&&rg(this.view,e.open.tooltip);(!i||!i.dom.contains(t.relatedTarget))&&setTimeout(()=>this.view.dispatch({effects:Os.of(null)}),10)}},compositionstart(){this.composing=1},compositionend(){this.composing==3&&setTimeout(()=>this.view.dispatch({effects:za.of(!1)}),20),this.composing=0}}}),MY=typeof navigator=="object"&&/Win/.test(navigator.platform),DY=Gi.highest(R.domEventHandlers({keydown(t,e){let i=e.state.field(_t,!1);if(!i||!i.open||i.open.disabled||i.open.selected<0||t.key.length>1||t.ctrlKey&&!(MY&&t.altKey)||t.metaKey)return!1;let n=i.open.options[i.open.selected],O=i.active.find(s=>s.source==n.source),r=n.completion.commitCharacters||O.result.commitCharacters;return r&&r.indexOf(t.key)>-1&&bd(e,n),!1}})),pP=R.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"···"',opacity:.5,display:"block",textAlign:"center",cursor:"pointer"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'𝑥'"}},".cm-completionIcon-constant":{"&:after":{content:"'𝐶'"}},".cm-completionIcon-type":{"&:after":{content:"'𝑡'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'🔑︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});class LY{constructor(e,i,n,O){this.field=e,this.line=i,this.from=n,this.to=O}}class xd{constructor(e,i,n){this.field=e,this.from=i,this.to=n}map(e){let i=e.mapPos(this.from,-1,it.TrackDel),n=e.mapPos(this.to,1,it.TrackDel);return i==null||n==null?null:new xd(this.field,i,n)}}class Td{constructor(e,i){this.lines=e,this.fieldPositions=i}instantiate(e,i){let n=[],O=[i],r=e.doc.lineAt(i),s=/^\s*/.exec(r.text)[0];for(let a of this.lines){if(n.length){let l=s,c=/^\t*/.exec(a)[0].length;for(let h=0;hnew xd(a.field,O[a.line]+a.from,O[a.line]+a.to));return{text:n,ranges:o}}static parse(e){let i=[],n=[],O=[],r;for(let s of e.split(/\r\n?|\n/)){for(;r=/[#$]\{(?:(\d+)(?::([^{}]*))?|((?:\\[{}]|[^{}])*))\}/.exec(s);){let o=r[1]?+r[1]:null,a=r[2]||r[3]||"",l=-1;o===0&&(o=1e9);let c=a.replace(/\\[{}]/g,h=>h[1]);for(let h=0;h=l&&d.field++}for(let h of O)if(h.line==n.length&&h.from>r.index){let d=r[2]?3+(r[1]||"").length:2;h.from-=d,h.to-=d}O.push(new LY(l,n.length,r.index,r.index+c.length)),s=s.slice(0,r.index)+a+s.slice(r.index+r[0].length)}s=s.replace(/\\([{}])/g,(o,a,l)=>{for(let c of O)c.line==n.length&&c.from>l&&(c.from--,c.to--);return a}),n.push(s)}return new Td(n,O)}}let NY=D.widget({widget:new class extends Xi{toDOM(){let t=document.createElement("span");return t.className="cm-snippetFieldPosition",t}ignoreEvent(){return!1}}}),BY=D.mark({class:"cm-snippetField"});class EO{constructor(e,i){this.ranges=e,this.active=i,this.deco=D.set(e.map(n=>(n.from==n.to?NY:BY).range(n.from,n.to)),!0)}map(e){let i=[];for(let n of this.ranges){let O=n.map(e);if(!O)return null;i.push(O)}return new EO(i,this.active)}selectionInsideField(e){return e.ranges.every(i=>this.ranges.some(n=>n.field==this.active&&n.from<=i.from&&n.to>=i.to))}}const rs=K.define({map(t,e){return t&&t.map(e)}}),FY=K.define(),ss=nt.define({create(){return null},update(t,e){for(let i of e.effects){if(i.is(rs))return i.value;if(i.is(FY)&&t)return new EO(t.ranges,i.value)}return t&&e.docChanged&&(t=t.map(e.changes)),t&&e.selection&&!t.selectionInsideField(e.selection)&&(t=null),t},provide:t=>R.decorations.from(t,e=>e?e.deco:D.none)});function wd(t,e){return x.create(t.filter(i=>i.field==e).map(i=>x.range(i.from,i.to)))}function HY(t){let e=Td.parse(t);return(i,n,O,r)=>{let{text:s,ranges:o}=e.instantiate(i.state,O),{main:a}=i.state.selection,l={changes:{from:O,to:r==a.from?a.to:r,insert:le.of(s)},scrollIntoView:!0,annotations:n?[gd.of(n),Ge.userEvent.of("input.complete")]:void 0};if(o.length&&(l.selection=wd(o,0)),o.some(c=>c.field>0)){let c=new EO(o,0),h=l.effects=[rs.of(c)];i.state.field(ss,!1)===void 0&&h.push(K.appendConfig.of([ss,JY,ez,pP]))}i.dispatch(i.state.update(l))}}function mP(t){return({state:e,dispatch:i})=>{let n=e.field(ss,!1);if(!n||t<0&&n.active==0)return!1;let O=n.active+t,r=t>0&&!n.ranges.some(s=>s.field==O+t);return i(e.update({selection:wd(n.ranges,O),effects:rs.of(r?null:new EO(n.ranges,O)),scrollIntoView:!0})),!0}}const KY=[{key:"Tab",run:mP(1),shift:mP(-1)},{key:"Escape",run:({state:t,dispatch:e})=>t.field(ss,!1)?(e(t.update({effects:rs.of(null)})),!0):!1}],gP=Z.define({combine(t){return t.length?t[0]:KY}}),JY=Gi.highest(wO.compute([gP],t=>t.facet(gP)));function _e(t,e){return{...e,apply:HY(t)}}const ez=R.domEventHandlers({mousedown(t,e){let i=e.state.field(ss,!1),n;if(!i||(n=e.posAtCoords({x:t.clientX,y:t.clientY}))==null)return!1;let O=i.ranges.find(r=>r.from<=n&&r.to>=n);return!O||O.field==i.active?!1:(e.dispatch({selection:wd(i.ranges,O.field),effects:rs.of(i.ranges.some(r=>r.field>O.field)?new EO(i.ranges,O.field):null),scrollIntoView:!0}),!0)}}),os={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},Nn=K.define({map(t,e){let i=e.mapPos(t,-1,it.TrackAfter);return i??void 0}}),vd=new class extends un{};vd.startSide=1,vd.endSide=-1;const PP=nt.define({create(){return re.empty},update(t,e){if(t=t.map(e.changes),e.selection){let i=e.state.doc.lineAt(e.selection.main.head);t=t.update({filter:n=>n>=i.from&&n<=i.to})}for(let i of e.effects)i.is(Nn)&&(t=t.update({add:[vd.range(i.value,i.value+1)]}));return t}});function tz(){return[nz,PP]}const kd="()[]{}<>«»»«[]{}";function SP(t){for(let e=0;e{if((iz?t.composing:t.compositionStarted)||t.state.readOnly)return!1;let O=t.state.selection.main;if(n.length>2||n.length==2&&mi(xt(n,0))==1||e!=O.from||i!=O.to)return!1;let r=rz(t.state,n);return r?(t.dispatch(r),!0):!1}),Oz=[{key:"Backspace",run:({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=XP(t,t.selection.main.head).brackets||os.brackets,O=null,r=t.changeByRange(s=>{if(s.empty){let o=sz(t.doc,s.head);for(let a of n)if(a==o&&Ua(t.doc,s.head)==SP(xt(a,0)))return{changes:{from:s.head-a.length,to:s.head+a.length},range:x.cursor(s.head-a.length)}}return{range:O=s}});return O||e(t.update(r,{scrollIntoView:!0,userEvent:"delete.backward"})),!O}}];function rz(t,e){let i=XP(t,t.selection.main.head),n=i.brackets||os.brackets;for(let O of n){let r=SP(xt(O,0));if(e==O)return r==O?lz(t,O,n.indexOf(O+O+O)>-1,i):oz(t,O,r,i.before||os.before);if(e==r&&bP(t,t.selection.main.from))return az(t,O,r)}return null}function bP(t,e){let i=!1;return t.field(PP).between(0,t.doc.length,n=>{n==e&&(i=!0)}),i}function Ua(t,e){let i=t.sliceString(e,e+2);return i.slice(0,mi(xt(i,0)))}function sz(t,e){let i=t.sliceString(e-2,e);return mi(xt(i,0))==i.length?i:i.slice(1)}function oz(t,e,i,n){let O=null,r=t.changeByRange(s=>{if(!s.empty)return{changes:[{insert:e,from:s.from},{insert:i,from:s.to}],effects:Nn.of(s.to+e.length),range:x.range(s.anchor+e.length,s.head+e.length)};let o=Ua(t.doc,s.head);return!o||/\s/.test(o)||n.indexOf(o)>-1?{changes:{insert:e+i,from:s.head},effects:Nn.of(s.head+e.length),range:x.cursor(s.head+e.length)}:{range:O=s}});return O?null:t.update(r,{scrollIntoView:!0,userEvent:"input.type"})}function az(t,e,i){let n=null,O=t.changeByRange(r=>r.empty&&Ua(t.doc,r.head)==i?{changes:{from:r.head,to:r.head+i.length,insert:i},range:x.cursor(r.head+i.length)}:n={range:r});return n?null:t.update(O,{scrollIntoView:!0,userEvent:"input.type"})}function lz(t,e,i,n){let O=n.stringPrefixes||os.stringPrefixes,r=null,s=t.changeByRange(o=>{if(!o.empty)return{changes:[{insert:e,from:o.from},{insert:e,from:o.to}],effects:Nn.of(o.to+e.length),range:x.range(o.anchor+e.length,o.head+e.length)};let a=o.head,l=Ua(t.doc,a),c;if(l==e){if(yP(t,a))return{changes:{insert:e+e,from:a},effects:Nn.of(a+e.length),range:x.cursor(a+e.length)};if(bP(t,a)){let d=i&&t.sliceDoc(a,a+e.length*3)==e+e+e?e+e+e:e;return{changes:{from:a,to:a+d.length,insert:d},range:x.cursor(a+d.length)}}}else{if(i&&t.sliceDoc(a-2*e.length,a)==e+e&&(c=xP(t,a-2*e.length,O))>-1&&yP(t,c))return{changes:{insert:e+e+e+e,from:a},effects:Nn.of(a+e.length),range:x.cursor(a+e.length)};if(t.charCategorizer(a)(l)!=ve.Word&&xP(t,a,O)>-1&&!cz(t,a,e,O))return{changes:{insert:e+e,from:a},effects:Nn.of(a+e.length),range:x.cursor(a+e.length)}}return{range:r=o}});return r?null:t.update(s,{scrollIntoView:!0,userEvent:"input.type"})}function yP(t,e){let i=$e(t).resolveInner(e+1);return i.parent&&i.from==e}function cz(t,e,i,n){let O=$e(t).resolveInner(e,-1),r=n.reduce((s,o)=>Math.max(s,o.length),0);for(let s=0;s<5;s++){let o=t.sliceDoc(O.from,Math.min(O.to,O.from+i.length+r)),a=o.indexOf(i);if(!a||a>-1&&n.indexOf(o.slice(0,a))>-1){let c=O.firstChild;for(;c&&c.from==O.from&&c.to-c.from>i.length+a;){if(t.sliceDoc(c.to-i.length,c.to)==i)return!1;c=c.firstChild}return!0}let l=O.to==e&&O.parent;if(!l)break;O=l}return!1}function xP(t,e,i){let n=t.charCategorizer(e);if(n(t.sliceDoc(e-1,e))!=ve.Word)return e;for(let O of i){let r=e-O.length;if(t.sliceDoc(r,e)==O&&n(t.sliceDoc(r-1,r))!=ve.Word)return r}return-1}function hz(t={}){return[DY,_t,He.of(t),AY,dz,pP]}const TP=[{key:"Ctrl-Space",run:yd},{mac:"Alt-`",run:yd},{mac:"Alt-i",run:yd},{key:"Escape",run:jY},{key:"ArrowDown",run:qa(!0)},{key:"ArrowUp",run:qa(!1)},{key:"PageDown",run:qa(!0,"page")},{key:"PageUp",run:qa(!1,"page")},{key:"Enter",run:CY}],dz=Gi.highest(wO.computeN([He],t=>t.facet(He).defaultKeymap?[TP]:[]));class wP{constructor(e,i,n){this.from=e,this.to=i,this.diagnostic=n}}class Bn{constructor(e,i,n){this.diagnostics=e,this.panel=i,this.selected=n}static init(e,i,n){let O=n.facet(as).markerFilter;O&&(e=O(e,n));let r=e.slice().sort((u,$)=>u.from-$.from||u.to-$.to),s=new Ei,o=[],a=0,l=n.doc.iter(),c=0,h=n.doc.length;for(let u=0;;){let $=u==r.length?null:r[u];if(!$&&!o.length)break;let Q,p;if(o.length)Q=a,p=o.reduce((g,b)=>Math.min(g,b.to),$&&$.from>Q?$.from:1e8);else{if(Q=$.from,Q>h)break;p=$.to,o.push($),u++}for(;ug.from||g.to==Q))o.push(g),u++,p=Math.min(g.to,p);else{p=Math.min(g.from,p);break}}p=Math.min(p,h);let m=!1;if(o.some(g=>g.from==Q&&(g.to==p||p==h))&&(m=Q==p,!m&&p-Q<10)){let g=Q-(c+l.value.length);g>0&&(l.next(g),c=Q);for(let b=Q;;){if(b>=p){m=!0;break}if(!l.lineBreak&&c+l.value.length>b)break;b=c+l.value.length,c+=l.value.length,l.next()}}let P=yz(o);if(m)s.add(Q,Q,D.widget({widget:new Pz(P),diagnostics:o.slice()}));else{let g=o.reduce((b,X)=>X.markClass?b+" "+X.markClass:b,"");s.add(Q,p,D.mark({class:"cm-lintRange cm-lintRange-"+P+g,diagnostics:o.slice(),inclusiveEnd:o.some(b=>b.to>p)}))}if(a=p,a==h)break;for(let g=0;g{if(!(e&&s.diagnostics.indexOf(e)<0))if(!n)n=new wP(O,r,e||s.diagnostics[0]);else{if(s.diagnostics.indexOf(n.diagnostic)<0)return!1;n=new wP(n.from,r,n.diagnostic)}}),n}function uz(t,e){let i=e.pos,n=e.end||i,O=t.state.facet(as).hideOn(t,i,n);if(O!=null)return O;let r=t.startState.doc.lineAt(e.pos);return!!(t.effects.some(s=>s.is(vP))||t.changes.touchesRange(r.from,Math.max(r.to,n)))}function fz(t,e){return t.field(jt,!1)?e:e.concat(K.appendConfig.of(xz))}const vP=K.define(),_d=K.define(),kP=K.define(),jt=nt.define({create(){return new Bn(D.none,null,null)},update(t,e){if(e.docChanged&&t.diagnostics.size){let i=t.diagnostics.map(e.changes),n=null,O=t.panel;if(t.selected){let r=e.changes.mapPos(t.selected.from,1);n=xn(i,t.selected.diagnostic,r)||xn(i,null,r)}!i.size&&O&&e.state.facet(as).autoPanel&&(O=null),t=new Bn(i,O,n)}for(let i of e.effects)if(i.is(vP)){let n=e.state.facet(as).autoPanel?i.value.length?ls.open:null:t.panel;t=Bn.init(i.value,n,e.state)}else i.is(_d)?t=new Bn(t.diagnostics,i.value?ls.open:null,t.selected):i.is(kP)&&(t=new Bn(t.diagnostics,t.panel,i.value));return t},provide:t=>[Mr.from(t,e=>e.panel),R.decorations.from(t,e=>e.diagnostics)]}),$z=D.mark({class:"cm-lintRange cm-lintRange-active"});function Qz(t,e,i){let{diagnostics:n}=t.state.field(jt),O,r=-1,s=-1;n.between(e-(i<0?1:0),e+(i>0?1:0),(a,l,{spec:c})=>{if(e>=a&&e<=l&&(a==l||(e>a||i>0)&&(eYP(t,i,!1)))}const mz=t=>{let e=t.state.field(jt,!1);(!e||!e.panel)&&t.dispatch({effects:fz(t.state,[_d.of(!0)])});let i=vh(t,ls.open);return i&&i.dom.querySelector(".cm-panel-lint ul").focus(),!0},_P=t=>{let e=t.state.field(jt,!1);return!e||!e.panel?!1:(t.dispatch({effects:_d.of(!1)}),!0)},gz=[{key:"Mod-Shift-m",run:mz,preventDefault:!0},{key:"F8",run:t=>{let e=t.state.field(jt,!1);if(!e)return!1;let i=t.state.selection.main,n=xn(e.diagnostics,null,i.to+1);return!n&&(n=xn(e.diagnostics,null,0),!n||n.from==i.from&&n.to==i.to)?!1:(t.dispatch({selection:{anchor:n.from,head:n.to},scrollIntoView:!0}),lR(t,n.from,1,{tooltip:VP,until:O=>O.docChanged||O.newSelection.main.headn.to}),!0)}}],as=Z.define({combine(t){return{sources:t.map(e=>e.source).filter(e=>e!=null),...Si(t.map(e=>e.config),{delay:750,markerFilter:null,tooltipFilter:null,needsRefresh:null,hideOn:()=>null},{delay:Math.max,markerFilter:RP,tooltipFilter:RP,needsRefresh:(e,i)=>e?i?n=>e(n)||i(n):e:i,hideOn:(e,i)=>e?i?(n,O,r)=>e(n,O,r)||i(n,O,r):e:i,autoPanel:(e,i)=>e||i})}}});function RP(t,e){return t?e?(i,n)=>e(t(i,n),n):t:e}function ZP(t){let e=[];if(t)e:for(let{name:i}of t){for(let n=0;nr.toLowerCase()==O.toLowerCase())){e.push(O);continue e}}e.push("")}return e}function YP(t,e,i){var n;let O=i?ZP(e.actions):[];return pe("li",{class:"cm-diagnostic cm-diagnostic-"+e.severity},pe("span",{class:"cm-diagnosticText"},e.renderMessage?e.renderMessage(t):e.message),(n=e.actions)===null||n===void 0?void 0:n.map((r,s)=>{let o=!1,a=u=>{if(u.preventDefault(),o)return;o=!0;let $=xn(t.state.field(jt).diagnostics,e);$&&r.apply(t,$.from,$.to)},{name:l}=r,c=O[s]?l.indexOf(O[s]):-1,h=c<0?l:[l.slice(0,c),pe("u",l.slice(c,c+1)),l.slice(c+1)],d=r.markClass?" "+r.markClass:"";return pe("button",{type:"button",class:"cm-diagnosticAction"+d,onclick:a,onmousedown:a,"aria-label":` Action: ${l}${c<0?"":` (access key "${O[s]})"`}.`},h)}),e.source&&pe("div",{class:"cm-diagnosticSource"},e.source))}class Pz extends Xi{constructor(e){super(),this.sev=e}eq(e){return e.sev==this.sev}toDOM(){return pe("span",{class:"cm-lintPoint cm-lintPoint-"+this.sev})}}class zP{constructor(e,i){this.diagnostic=i,this.id="item_"+Math.floor(Math.random()*4294967295).toString(16),this.dom=YP(e,i,!0),this.dom.id=this.id,this.dom.setAttribute("role","option")}}class ls{constructor(e){this.view=e,this.items=[];let i=O=>{if(!(O.ctrlKey||O.altKey||O.metaKey)){if(O.keyCode==27)_P(this.view),this.view.focus();else if(O.keyCode==38||O.keyCode==33)this.moveSelection((this.selectedIndex-1+this.items.length)%this.items.length);else if(O.keyCode==40||O.keyCode==34)this.moveSelection((this.selectedIndex+1)%this.items.length);else if(O.keyCode==36)this.moveSelection(0);else if(O.keyCode==35)this.moveSelection(this.items.length-1);else if(O.keyCode==13)this.view.focus();else if(O.keyCode>=65&&O.keyCode<=90&&this.selectedIndex>=0){let{diagnostic:r}=this.items[this.selectedIndex],s=ZP(r.actions);for(let o=0;o{for(let r=0;r_P(this.view)},"×")),this.update()}get selectedIndex(){let e=this.view.state.field(jt).selected;if(!e)return-1;for(let i=0;i{for(let c of l.diagnostics){if(s.has(c))continue;s.add(c);let h=-1,d;for(let u=n;un&&(this.items.splice(n,h-n),O=!0)),i&&d.diagnostic==i.diagnostic?d.dom.hasAttribute("aria-selected")||(d.dom.setAttribute("aria-selected","true"),r=d):d.dom.hasAttribute("aria-selected")&&d.dom.removeAttribute("aria-selected"),n++}});n({sel:r.dom.getBoundingClientRect(),panel:this.list.getBoundingClientRect()}),write:({sel:o,panel:a})=>{let l=a.height/this.list.offsetHeight;o.topa.bottom&&(this.list.scrollTop+=(o.bottom-a.bottom)/l)}})):this.selectedIndex<0&&this.list.removeAttribute("aria-activedescendant"),O&&this.sync()}sync(){let e=this.list.firstChild;function i(){let n=e;e=n.nextSibling,n.remove()}for(let n of this.items)if(n.dom.parentNode==this.list){for(;e!=n.dom;)i();e=n.dom.nextSibling}else this.list.insertBefore(n.dom,e);for(;e;)i()}moveSelection(e){if(this.selectedIndex<0)return;let i=this.view.state.field(jt),n=xn(i.diagnostics,this.items[e].diagnostic);n&&this.view.dispatch({selection:{anchor:n.from,head:n.to},scrollIntoView:!0,effects:kP.of(n)})}static open(e){return new ls(e)}}function Sz(t,e='viewBox="0 0 40 40"'){return`url('data:image/svg+xml,${encodeURIComponent(t)}')`}function Wa(t){return Sz(``,'width="6" height="3"')}const Xz=R.baseTheme({".cm-diagnostic":{padding:"3px 6px 3px 8px",marginLeft:"-1px",display:"block",whiteSpace:"pre-wrap"},".cm-diagnostic-error":{borderLeft:"5px solid #d11"},".cm-diagnostic-warning":{borderLeft:"5px solid orange"},".cm-diagnostic-info":{borderLeft:"5px solid #999"},".cm-diagnostic-hint":{borderLeft:"5px solid #66d"},".cm-diagnosticAction":{font:"inherit",border:"none",padding:"2px 4px",backgroundColor:"#444",color:"white",borderRadius:"3px",marginLeft:"8px",cursor:"pointer"},".cm-diagnosticSource":{fontSize:"70%",opacity:.7},".cm-lintRange":{backgroundPosition:"left bottom",backgroundRepeat:"repeat-x",paddingBottom:"0.7px"},".cm-lintRange-error":{backgroundImage:Wa("#f11")},".cm-lintRange-warning":{backgroundImage:Wa("orange")},".cm-lintRange-info":{backgroundImage:Wa("#999")},".cm-lintRange-hint":{backgroundImage:Wa("#66d")},".cm-lintRange-active":{backgroundColor:"#ffdd9980"},".cm-tooltip-lint":{padding:0,margin:0},".cm-lintPoint":{position:"relative","&:after":{content:'""',position:"absolute",bottom:0,left:"-2px",borderLeft:"3px solid transparent",borderRight:"3px solid transparent",borderBottom:"4px solid #d11"}},".cm-lintPoint-warning":{"&:after":{borderBottomColor:"orange"}},".cm-lintPoint-info":{"&:after":{borderBottomColor:"#999"}},".cm-lintPoint-hint":{"&:after":{borderBottomColor:"#66d"}},".cm-panel.cm-panel-lint":{position:"relative","& ul":{maxHeight:"100px",overflowY:"auto","& [aria-selected]":{backgroundColor:"#ddd","& u":{textDecoration:"underline"}},"&:focus [aria-selected]":{background_fallback:"#bdf",backgroundColor:"Highlight",color_fallback:"white",color:"HighlightText"},"& u":{textDecoration:"none"},padding:0,margin:0},"& [name=close]":{position:"absolute",top:"0",right:"2px",background:"inherit",border:"none",font:"inherit",padding:0,margin:0}},"&dark .cm-lintRange-active":{backgroundColor:"#86714a80"},"&dark .cm-panel.cm-panel-lint ul":{"& [aria-selected]":{backgroundColor:"#2e343e"}}});function bz(t){return t=="error"?4:t=="warning"?3:t=="info"?2:1}function yz(t){let e="hint",i=1;for(let n of t){let O=bz(n.severity);O>i&&(i=O,e=n.severity)}return e}const VP=aR(Qz,{hideOn:uz}),xz=[jt,R.decorations.compute([jt],t=>{let{selected:e,panel:i}=t.field(jt);return!e||!i||e.from==e.to?D.none:D.set([$z.range(e.from,e.to)])}),VP,Xz],Tz=[XR(),xR(),C_(),I2(),u2(),v_(),Y_(),ae.allowMultipleSelections.of(!0),n2(),$2(m2,{fallback:!0}),y2(),tz(),hz(),H_(),eR(),M_(),HZ(),wO.of([...Oz,...MZ,...mY,...K2,...l2,...TP,...gz])];class Ca{constructor(e,i,n,O,r,s,o,a,l,c=0,h){this.p=e,this.stack=i,this.state=n,this.reducePos=O,this.pos=r,this.score=s,this.buffer=o,this.bufferBase=a,this.curContext=l,this.lookAhead=c,this.parent=h}toString(){return`[${this.stack.filter((e,i)=>i%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,i,n=0){let O=e.parser.context;return new Ca(e,[],i,n,n,0,[],0,O?new qP(O,O.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,i){this.stack.push(this.state,i,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var i;let n=e>>19,O=e&65535,{parser:r}=this.p,s=this.reducePos=2e3&&!(!((i=this.p.parser.nodeSet.types[O])===null||i===void 0)&&i.isAnonymous)&&(l==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=c):this.p.lastBigReductionSizea;)this.stack.pop();this.reduceContext(O,l)}storeNode(e,i,n,O=4,r=!1){if(e==0&&(!this.stack.length||this.stack[this.stack.length-1]0&&this.buffer[s-4]==0&&this.buffer[s-1]>-1){if(i==n)return;if(this.buffer[s-2]>=i){this.buffer[s-2]=n;return}}}if(!r||this.pos==n)this.buffer.push(e,i,n,O);else{let s=this.buffer.length;if(s>0&&(this.buffer[s-4]!=0||this.buffer[s-1]<0)){let o=!1;for(let a=s;a>0&&this.buffer[a-2]>n;a-=4)if(this.buffer[a-1]>=0){o=!0;break}if(o)for(;s>0&&this.buffer[s-2]>n;)this.buffer[s]=this.buffer[s-4],this.buffer[s+1]=this.buffer[s-3],this.buffer[s+2]=this.buffer[s-2],this.buffer[s+3]=this.buffer[s-1],s-=4,O>4&&(O-=4)}this.buffer[s]=e,this.buffer[s+1]=i,this.buffer[s+2]=n,this.buffer[s+3]=O}}shift(e,i,n,O){if(e&131072)this.pushState(e&65535,this.pos);else if(e&262144)this.pos=O,this.shiftContext(i,n),i<=this.p.parser.maxNode&&this.buffer.push(i,n,O,4);else{let r=e,{parser:s}=this.p;this.pos=O;let o=s.stateFlag(r,1);!o&&(O>n||i<=s.maxNode)&&(this.reducePos=O),this.pushState(r,o?n:Math.min(n,this.reducePos)),this.shiftContext(i,n),i<=s.maxNode&&this.buffer.push(i,n,O,4)}}apply(e,i,n,O){e&65536?this.reduce(e):this.shift(e,i,n,O)}useNode(e,i){let n=this.p.reused.length-1;(n<0||this.p.reused[n]!=e)&&(this.p.reused.push(e),n++);let O=this.pos;this.reducePos=this.pos=O+e.length,this.pushState(i,O),this.buffer.push(n,O,this.reducePos,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,i=e.buffer.length;for(i&&e.buffer[i-4]==0&&(i-=4);i>0&&e.buffer[i-2]>e.reducePos;)i-=4;let n=e.buffer.slice(i),O=e.bufferBase+i;for(;e&&O==e.bufferBase;)e=e.parent;return new Ca(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,n,O,this.curContext,this.lookAhead,e)}recoverByDelete(e,i){let n=e<=this.p.parser.maxNode;n&&this.storeNode(e,this.pos,i,4),this.storeNode(0,this.pos,i,n?8:4),this.pos=this.reducePos=i,this.score-=190}canShift(e){for(let i=new wz(this);;){let n=this.p.parser.stateSlot(i.state,4)||this.p.parser.hasAction(i.state,e);if(n==0)return!1;if(!(n&65536))return!0;i.reduce(n)}}recoverByInsert(e){if(this.stack.length>=300)return[];let i=this.p.parser.nextStates(this.state);if(i.length>8||this.stack.length>=120){let O=[];for(let r=0,s;ra&1&&o==s)||O.push(i[r],s)}i=O}let n=[];for(let O=0;O>19,O=i&65535,r=this.stack.length-n*3;if(r<0||e.getGoto(this.stack[r],O,!1)<0){let s=this.findForcedReduction();if(s==null)return!1;i=s}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(i),!0}findForcedReduction(){let{parser:e}=this.p,i=[],n=(O,r)=>{if(!i.includes(O))return i.push(O),e.allActions(O,s=>{if(!(s&393216))if(s&65536){let o=(s>>19)-r;if(o>1){let a=s&65535,l=this.stack.length-o*3;if(l>=0&&e.getGoto(this.stack[l],a,!1)>=0)return o<<19|65536|a}}else{let o=n(s,r+1);if(o!=null)return o}})};return n(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(this.stack.length!=3)return!1;let{parser:e}=this.p;return e.data[e.stateSlot(this.state,1)]==65535&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let i=0;i0&&this.emitLookAhead()}}class qP{constructor(e,i){this.tracker=e,this.context=i,this.hash=e.strict?e.hash(i):0}}class wz{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let i=e&65535,n=e>>19;n==0?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(n-1)*3;let O=this.start.p.parser.getGoto(this.stack[this.base-3],i,!0);this.state=O}}class ja{constructor(e,i,n){this.stack=e,this.pos=i,this.index=n,this.buffer=e.buffer,this.index==0&&this.maybeNext()}static create(e,i=e.bufferBase+e.buffer.length){return new ja(e,i,i-e.bufferBase)}maybeNext(){let e=this.stack.parent;e!=null&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,this.index==0&&this.maybeNext()}fork(){return new ja(this.stack,this.pos,this.index)}}function cs(t,e=Uint16Array){if(typeof t!="string")return t;let i=null;for(let n=0,O=0;n=92&&s--,s>=34&&s--;let a=s-32;if(a>=46&&(a-=46,o=!0),r+=a,o)break;r*=46}i?i[O++]=r:i=new e(r)}return i}class Ga{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}}const UP=new Ga;class vz{constructor(e,i){this.input=e,this.ranges=i,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=UP,this.rangeIndex=0,this.pos=this.chunkPos=i[0].from,this.range=i[0],this.end=i[i.length-1].to,this.readNext()}resolveOffset(e,i){let n=this.range,O=this.rangeIndex,r=this.pos+e;for(;rn.to:r>=n.to;){if(O==this.ranges.length-1)return null;let s=this.ranges[++O];r+=s.from-n.to,n=s}return r}clipPos(e){if(e>=this.range.from&&ee)return Math.max(e,i.from);return this.end}peek(e){let i=this.chunkOff+e,n,O;if(i>=0&&i=this.chunk2Pos&&no.to&&(this.chunk2=this.chunk2.slice(0,o.to-n)),O=this.chunk2.charCodeAt(0)}}return n>=this.token.lookAhead&&(this.token.lookAhead=n+1),O}acceptToken(e,i=0){let n=i?this.resolveOffset(i,-1):this.pos;if(n==null||n=this.chunk2Pos&&this.posthis.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,i){if(i?(this.token=i,i.start=e,i.lookAhead=e+1,i.value=i.extended=-1):this.token=UP,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e=this.chunkPos&&i<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,i-this.chunkPos);if(e>=this.chunk2Pos&&i<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,i-this.chunk2Pos);if(e>=this.range.from&&i<=this.range.to)return this.input.read(e,i);let n="";for(let O of this.ranges){if(O.from>=i)break;O.to>e&&(n+=this.input.read(Math.max(O.from,e),Math.min(O.to,i)))}return n}}class IO{constructor(e,i){this.data=e,this.id=i}token(e,i){let{parser:n}=i.p;WP(this.data,e,i,this.id,n.data,n.tokenPrecTable)}}IO.prototype.contextual=IO.prototype.fallback=IO.prototype.extend=!1;class hs{constructor(e,i,n){this.precTable=i,this.elseToken=n,this.data=typeof e=="string"?cs(e):e}token(e,i){let n=e.pos,O=0;for(;;){let r=e.next<0,s=e.resolveOffset(1,1);if(WP(this.data,e,i,0,this.data,this.precTable),e.token.value>-1)break;if(this.elseToken==null)return;if(r||O++,s==null)break;e.reset(s,e.token)}O&&(e.reset(n,e.token),e.acceptToken(this.elseToken,O))}}hs.prototype.contextual=IO.prototype.fallback=IO.prototype.extend=!1;class ie{constructor(e,i={}){this.token=e,this.contextual=!!i.contextual,this.fallback=!!i.fallback,this.extend=!!i.extend}}function WP(t,e,i,n,O,r){let s=0,o=1<0){let $=t[u];if(a.allows($)&&(e.token.value==-1||e.token.value==$||kz($,e.token.value,O,r))){e.acceptToken($);break}}let c=e.next,h=0,d=t[s+2];if(e.next<0&&d>h&&t[l+d*3-3]==65535){s=t[l+d*3-1];continue e}for(;h>1,$=l+u+(u<<1),Q=t[$],p=t[$+1]||65536;if(c=p)h=u+1;else{s=t[$+2],e.advance();continue e}}break}}function CP(t,e,i){for(let n=e,O;(O=t[n])!=65535;n++)if(O==i)return n-e;return-1}function kz(t,e,i,n){let O=CP(i,n,e);return O<0||CP(i,n,t)e)&&!n.type.isError)return i<0?Math.max(0,Math.min(n.to-1,e-25)):Math.min(t.length,Math.max(n.from+1,e+25));if(i<0?n.prevSibling():n.nextSibling())break;if(!n.parent())return i<0?0:t.length}}let _z=class{constructor(e,i){this.fragments=e,this.nodeSet=i,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?jP(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?jP(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(ee)return this.nextStart=s,null;if(r instanceof ne){if(s==e){if(s=Math.max(this.safeFrom,e)&&(this.trees.push(r),this.start.push(s),this.index.push(0))}else this.index[i]++,this.nextStart=s+r.length}}};class Rz{constructor(e,i){this.stream=i,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(n=>new Ga)}getActions(e){let i=0,n=null,{parser:O}=e.p,{tokenizers:r}=O,s=O.stateSlot(e.state,3),o=e.curContext?e.curContext.hash:0,a=0;for(let l=0;lh.end+25&&(a=Math.max(h.lookAhead,a)),h.value!=0)){let d=i;if(h.extended>-1&&(i=this.addActions(e,h.extended,h.end,i)),i=this.addActions(e,h.value,h.end,i),!c.extend&&(n=h,i>d))break}}for(;this.actions.length>i;)this.actions.pop();return a&&e.setLookAhead(a),!n&&e.pos==this.stream.end&&(n=new Ga,n.value=e.p.parser.eofTerm,n.start=n.end=e.pos,i=this.addActions(e,n.value,n.end,i)),this.mainToken=n,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let i=new Ga,{pos:n,p:O}=e;return i.start=n,i.end=Math.min(n+1,O.stream.end),i.value=n==O.stream.end?O.parser.eofTerm:0,i}updateCachedToken(e,i,n){let O=this.stream.clipPos(n.pos);if(i.token(this.stream.reset(O,e),n),e.value>-1){let{parser:r}=n.p;for(let s=0;s=0&&n.p.parser.dialect.allows(o>>1)){o&1?e.extended=o>>1:e.value=o>>1;break}}}else e.value=0,e.end=this.stream.clipPos(O+1)}putAction(e,i,n,O){for(let r=0;re.bufferLength*4?new _z(n,e.nodeSet):null}get parsedPos(){return this.minStackPos}advance(){let e=this.stacks,i=this.minStackPos,n=this.stacks=[],O,r;if(this.bigReductionCount>300&&e.length==1){let[s]=e;for(;s.forceReduce()&&s.stack.length&&s.stack[s.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let s=0;si)n.push(o);else{if(this.advanceStack(o,n,e))continue;{O||(O=[],r=[]),O.push(o);let a=this.tokens.getMainToken(o);r.push(a.value,a.end)}}break}}if(!n.length){let s=O&&zz(O);if(s)return Gt&&console.log("Finish with "+this.stackID(s)),this.stackToTree(s);if(this.parser.strict)throw Gt&&O&&console.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),new SyntaxError("No parse at "+i);this.recovering||(this.recovering=5)}if(this.recovering&&O){let s=this.stoppedAt!=null&&O[0].pos>this.stoppedAt?O[0]:this.runRecovery(O,r,n);if(s)return Gt&&console.log("Force-finish "+this.stackID(s)),this.stackToTree(s.forceAll())}if(this.recovering){let s=this.recovering==1?1:this.recovering*3;if(n.length>s)for(n.sort((o,a)=>a.score-o.score);n.length>s;)n.pop();n.some(o=>o.reducePos>i)&&this.recovering--}else if(n.length>1){e:for(let s=0;s500&&l.buffer.length>500)if((o.score-l.score||o.buffer.length-l.buffer.length)>0)n.splice(a--,1);else{n.splice(s--,1);continue e}}}n.length>12&&(n.sort((s,o)=>o.score-s.score),n.splice(12,n.length-12))}this.minStackPos=n[0].pos;for(let s=1;s ":"";if(this.stoppedAt!=null&&O>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let l=e.curContext&&e.curContext.tracker.strict,c=l?e.curContext.hash:0;for(let h=this.fragments.nodeAt(O);h;){let d=this.parser.nodeSet.types[h.type.id]==h.type?r.getGoto(e.state,h.type.id):-1;if(d>-1&&h.length&&(!l||(h.prop(F.contextHash)||0)==c))return e.useNode(h,d),Gt&&console.log(s+this.stackID(e)+` (via reuse of ${r.getName(h.type.id)})`),!0;if(!(h instanceof ne)||h.children.length==0||h.positions[0]>0)break;let u=h.children[0];if(u instanceof ne&&h.positions[0]==0)h=u;else break}}let o=r.stateSlot(e.state,4);if(o>0)return e.reduce(o),Gt&&console.log(s+this.stackID(e)+` (via always-reduce ${r.getName(o&65535)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let a=this.tokens.getActions(e);for(let l=0;lO?i.push($):n.push($)}return!1}advanceFully(e,i){let n=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>n)return GP(e,i),!0}}runRecovery(e,i,n){let O=null,r=!1;for(let s=0;s ":"";if(o.deadEnd&&(r||(r=!0,o.restart(),Gt&&console.log(c+this.stackID(o)+" (restarted)"),this.advanceFully(o,n))))continue;let h=o.split(),d=c;for(let u=0;u<10&&h.forceReduce()&&(Gt&&console.log(d+this.stackID(h)+" (via force-reduce)"),!this.advanceFully(h,n));u++)Gt&&(d=this.stackID(h)+" -> ");for(let u of o.recoverByInsert(a))Gt&&console.log(c+this.stackID(u)+" (via recover-insert)"),this.advanceFully(u,n);this.stream.end>o.pos?(l==o.pos&&(l++,a=0),o.recoverByDelete(a,l),Gt&&console.log(c+this.stackID(o)+` (via recover-delete ${this.parser.getName(a)})`),GP(o,n)):(!O||O.scoret;class AO{constructor(e){this.start=e.start,this.shift=e.shift||Zd,this.reduce=e.reduce||Zd,this.reuse=e.reuse||Zd,this.hash=e.hash||(()=>0),this.strict=e.strict!==!1}}class ht extends oa{constructor(e){if(super(),this.wrappers=[],e.version!=14)throw new RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let i=e.nodeNames.split(" ");this.minRepeatTerm=i.length;for(let o=0;oe.topRules[o][1]),O=[];for(let o=0;o=0)r(c,a,o[l++]);else{let h=o[l+-c];for(let d=-c;d>0;d--)r(o[l++],a,h);l++}}}this.nodeSet=new RO(i.map((o,a)=>Ee.define({name:a>=this.minRepeatTerm?void 0:o,id:a,props:O[a],top:n.indexOf(a)>-1,error:a==0,skipped:e.skippedNodes&&e.skippedNodes.indexOf(a)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=pg;let s=cs(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let o=0;otypeof o=="number"?new IO(s,o):o),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,i,n){let O=new Zz(this,e,i,n);for(let r of this.wrappers)O=r(O,e,i,n);return O}getGoto(e,i,n=!1){let O=this.goto;if(i>=O[0])return-1;for(let r=O[i+1];;){let s=O[r++],o=s&1,a=O[r++];if(o&&n)return a;for(let l=r+(s>>1);r0}validAction(e,i){return!!this.allActions(e,n=>n==i?!0:null)}allActions(e,i){let n=this.stateSlot(e,4),O=n?i(n):void 0;for(let r=this.stateSlot(e,1);O==null;r+=3){if(this.data[r]==65535)if(this.data[r+1]==1)r=Bi(this.data,r+2);else break;O=i(Bi(this.data,r+1))}return O}nextStates(e){let i=[];for(let n=this.stateSlot(e,1);;n+=3){if(this.data[n]==65535)if(this.data[n+1]==1)n=Bi(this.data,n+2);else break;if(!(this.data[n+2]&1)){let O=this.data[n+1];i.some((r,s)=>s&1&&r==O)||i.push(this.data[n],O)}}return i}configure(e){let i=Object.assign(Object.create(ht.prototype),this);if(e.props&&(i.nodeSet=this.nodeSet.extend(...e.props)),e.top){let n=this.topRules[e.top];if(!n)throw new RangeError(`Invalid top rule name ${e.top}`);i.top=n}return e.tokenizers&&(i.tokenizers=this.tokenizers.map(n=>{let O=e.tokenizers.find(r=>r.from==n);return O?O.to:n})),e.specializers&&(i.specializers=this.specializers.slice(),i.specializerSpecs=this.specializerSpecs.map((n,O)=>{let r=e.specializers.find(o=>o.from==n.external);if(!r)return n;let s=Object.assign(Object.assign({},n),{external:r.to});return i.specializers[O]=EP(s),s})),e.contextTracker&&(i.context=e.contextTracker),e.dialect&&(i.dialect=this.parseDialect(e.dialect)),e.strict!=null&&(i.strict=e.strict),e.wrap&&(i.wrappers=i.wrappers.concat(e.wrap)),e.bufferLength!=null&&(i.bufferLength=e.bufferLength),i}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let i=this.dynamicPrecedences;return i==null?0:i[e]||0}parseDialect(e){let i=Object.keys(this.dialects),n=i.map(()=>!1);if(e)for(let r of e.split(" ")){let s=i.indexOf(r);s>=0&&(n[s]=!0)}let O=null;for(let r=0;rn)&&i.p.parser.stateFlag(i.state,2)&&(!e||e.scoret.external(i,n)<<1|e}return t.get}const IP=1,Vz=2,qz=3,Uz=82,Wz=76,Cz=117,jz=85,Gz=97,Ez=122,Iz=65,Az=90,Mz=95,Yd=48,AP=34,Dz=40,MP=41,Lz=32,DP=62,Nz=new ie(t=>{if(t.next==Wz||t.next==jz?t.advance():t.next==Cz&&(t.advance(),t.next==Yd+8&&t.advance()),t.next!=Uz||(t.advance(),t.next!=AP))return;t.advance();let e="";for(;t.next!=Dz;){if(t.next==Lz||t.next<=13||t.next==MP)return;e+=String.fromCharCode(t.next),t.advance()}for(t.advance();;){if(t.next<0)return t.acceptToken(IP);if(t.next==MP){let i=!0;for(let n=0;i&&n{if(t.next==DP)t.peek(1)==DP&&t.acceptToken(Vz,1);else{let e=!1,i=0;for(;;i++){if(t.next>=Iz&&t.next<=Az)e=!0;else{if(t.next>=Gz&&t.next<=Ez)return;if(t.next!=Mz&&!(t.next>=Yd&&t.next<=Yd+9))break}t.advance()}e&&i>1&&t.acceptToken(qz)}},{extend:!0}),Fz=ot({"typedef struct union enum class typename decltype auto template operator friend noexcept namespace using requires concept import export module __attribute__ __declspec __based":f.definitionKeyword,"extern MsCallModifier MsPointerModifier extern static register thread_local inline const volatile restrict _Atomic mutable constexpr constinit consteval virtual explicit VirtualSpecifier Access":f.modifier,"if else switch for while do case default return break continue goto throw try catch":f.controlKeyword,"co_return co_yield co_await":f.controlKeyword,"new sizeof delete static_assert":f.operatorKeyword,"NULL nullptr":f.null,this:f.self,"True False":f.bool,"TypeSize PrimitiveType":f.standard(f.typeName),TypeIdentifier:f.typeName,FieldIdentifier:f.propertyName,"CallExpression/FieldExpression/FieldIdentifier":f.function(f.propertyName),"ModuleName/Identifier":f.namespace,PartitionName:f.labelName,StatementIdentifier:f.labelName,"Identifier DestructorName":f.variableName,"CallExpression/Identifier":f.function(f.variableName),"CallExpression/ScopedIdentifier/Identifier":f.function(f.variableName),"FunctionDeclarator/Identifier FunctionDeclarator/DestructorName":f.function(f.definition(f.variableName)),NamespaceIdentifier:f.namespace,OperatorName:f.operator,ArithOp:f.arithmeticOperator,LogicOp:f.logicOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,AssignOp:f.definitionOperator,UpdateOp:f.updateOperator,LineComment:f.lineComment,BlockComment:f.blockComment,Number:f.number,String:f.string,"RawString SystemLibString":f.special(f.string),CharLiteral:f.character,EscapeSequence:f.escape,"UserDefinedLiteral/Identifier":f.literal,PreprocArg:f.meta,"PreprocDirectiveName #include #ifdef #ifndef #if #define #else #endif #elif":f.processingInstruction,MacroName:f.special(f.name),"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace,"< >":f.angleBracket,". ->":f.derefOperator,", ;":f.separator}),Hz={__proto__:null,bool:36,char:36,int:36,float:36,double:36,void:36,size_t:36,ssize_t:36,intptr_t:36,uintptr_t:36,charptr_t:36,int8_t:36,int16_t:36,int32_t:36,int64_t:36,uint8_t:36,uint16_t:36,uint32_t:36,uint64_t:36,char8_t:36,char16_t:36,char32_t:36,char64_t:36,const:70,volatile:72,restrict:74,_Atomic:76,mutable:78,constexpr:80,constinit:82,consteval:84,struct:88,__declspec:92,final:148,override:148,public:152,private:152,protected:152,virtual:154,extern:160,static:162,register:164,inline:166,thread_local:168,__attribute__:172,__based:178,__restrict:180,__uptr:180,__sptr:180,_unaligned:180,__unaligned:180,noexcept:194,requires:198,TRUE:798,true:798,FALSE:800,false:800,typename:218,class:220,template:234,throw:248,__cdecl:256,__clrcall:256,__stdcall:256,__fastcall:256,__thiscall:256,__vectorcall:256,try:260,catch:264,export:282,import:286,case:296,default:298,if:308,else:314,switch:318,do:322,while:324,for:330,return:334,break:338,continue:342,goto:346,co_return:350,co_yield:354,using:362,typedef:366,namespace:380,new:398,delete:400,co_await:402,concept:406,enum:410,static_assert:414,friend:422,union:424,explicit:430,operator:444,module:456,signed:518,unsigned:518,long:518,short:518,decltype:528,auto:530,sizeof:566,NULL:572,nullptr:586,this:588},Kz={__proto__:null,"<":767},Jz={__proto__:null,">":135},eV={__proto__:null,operator:388,new:576,delete:582},tV=ht.deserialize({version:14,states:"$<[Q!QQVOOP'gOUOOO([OWO'#CdO,UQUO'#CgO,`QUO'#FjO-vQbO'#CxO.XQUO'#CxO0WQUO'#KaO0_QUO'#CwO0jOpO'#DvO0rQ!dO'#D]OOQR'#JP'#JPO5[QVO'#GUO5iQUO'#JWOOQQ'#JW'#JWO8}QUO'#KtOxQVO'#IbO!(}QVO'#IdO!?SQUO'#IgO!?ZQVO'#IjP!AQO!LQO'#CaP!A]{,UO'#CbP!6q{,UO'#CbP!Ah{7[O'#CbP!6q{,UO'#CbP!Am{,UO'#CbP!AxOSO'#IzPOOO)CEp)CEpOOOO'#I}'#I}O!BSOWO,59OOOQR,59O,59OO!(}QVO,59VOOQQ,59X,59XOOQR'#Do'#DoO!(}QVO,5;ROOQR,5qOOQR'#IX'#IXOOQR'#IY'#IYOOQR'#IZ'#IZOOQR'#I['#I[O!(}QVO,5>rO!(}QVO,5>rO!(}QVO,5>rO!(}QVO,5>rO!(}QVO,5>rO!(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d-e-h-n.W.X.]/U/X/d/k/t/v/{/}0p1T1Y1i1j1t1x2S2U2k2n2q3P3U3X3s4Y4]4b4k5d5o5{6i6m6p6r6t7O7Q7V7l7t7w8o8q8w8}9O9]9a9g9i9v9y9z:V:Y:`:b:g:l:pU%qm%r7[Q&o!`Q(p#^d0X*S0U0V0W0Z5X5Y5Z5^8[R7[3_b}Oaewx{!g&U*v&v$k[!W!X!k!n!r!s!v!x#X#Y#[#h#k#n#s#t#u#v#w#x#y#z#{#|#}$P$W$Y$[$g$h$m%_%o&S&Y&d&h&z&{'O'Q'R'e'l'm'|(c(e(l)q)w*m*n*q*w*{+]+_+m+o+p,U,W,s,v,|-d-e-h-n.W.X.]/U/X/d/k/t/v/{/}1T1i1j1t1x2S2U2k2n2q3P3U3X3s4Y4]4b4k5d5o5{6i6m6p6r6t7O7Q7V7l7t7w8o8q8w8}9O9]9a9g9i9v9y9z:V:Y:`:b:g:l:pS%bf0p#d%lgnp|#O$i%O%P%U%f%j%k%y&u'w'x(T*_*e*g*y+b,q,{-f-w.O.m.t.v0e1R1S1W1[2g2r5k6q;b;c;d;j;k;l;y;z;{;| MacroName LineComment BlockComment PreprocDirective #include String EscapeSequence SystemLibString Identifier ) ( ArgumentList ConditionalExpression AssignmentExpression CallExpression PrimitiveType FieldExpression FieldIdentifier DestructorName TemplateMethod ScopedFieldIdentifier NamespaceIdentifier TemplateType TypeIdentifier ScopedTypeIdentifier ScopedNamespaceIdentifier :: NamespaceIdentifier TypeIdentifier TemplateArgumentList < TypeDescriptor const volatile restrict _Atomic mutable constexpr constinit consteval StructSpecifier struct MsDeclspecModifier __declspec Attribute AttributeName Identifier AttributeArgs { } [ ] UpdateOp ArithOp ArithOp ArithOp LogicOp BitOp BitOp BitOp CompareOp CompareOp CompareOp > CompareOp BitOp UpdateOp , Number CharLiteral AttributeArgs VirtualSpecifier BaseClassClause Access virtual FieldDeclarationList FieldDeclaration extern static register inline thread_local AttributeSpecifier __attribute__ PointerDeclarator MsBasedModifier __based MsPointerModifier FunctionDeclarator ParameterList ParameterDeclaration PointerDeclarator FunctionDeclarator Noexcept noexcept RequiresClause requires True False ParenthesizedExpression CommaExpression LambdaExpression LambdaCaptureSpecifier TemplateParameterList OptionalParameterDeclaration TypeParameterDeclaration typename class VariadicParameterDeclaration VariadicDeclarator ReferenceDeclarator OptionalTypeParameterDeclaration VariadicTypeParameterDeclaration TemplateTemplateParameterDeclaration template AbstractFunctionDeclarator AbstractPointerDeclarator AbstractArrayDeclarator AbstractParenthesizedDeclarator AbstractReferenceDeclarator ThrowSpecifier throw TrailingReturnType CompoundStatement FunctionDefinition MsCallModifier TryStatement try CatchClause catch LinkageSpecification Declaration InitDeclarator InitializerList InitializerPair SubscriptDesignator FieldDesignator ExportDeclaration export ImportDeclaration import ModuleName PartitionName HeaderName CaseStatement case default LabeledStatement StatementIdentifier ExpressionStatement IfStatement if ConditionClause Declaration else SwitchStatement switch DoStatement do while WhileStatement ForStatement for ReturnStatement return BreakStatement break ContinueStatement continue GotoStatement goto CoReturnStatement co_return CoYieldStatement co_yield AttributeStatement ForRangeLoop AliasDeclaration using TypeDefinition typedef PointerDeclarator FunctionDeclarator ArrayDeclarator ParenthesizedDeclarator ThrowStatement NamespaceDefinition namespace ScopedIdentifier Identifier OperatorName operator ArithOp BitOp CompareOp LogicOp new delete co_await ConceptDefinition concept UsingDeclaration enum StaticAssertDeclaration static_assert ConcatenatedString TemplateDeclaration FriendDeclaration friend union FunctionDefinition ExplicitFunctionSpecifier explicit FieldInitializerList FieldInitializer DefaultMethodClause DeleteMethodClause FunctionDefinition OperatorCast operator TemplateInstantiation FunctionDefinition FunctionDefinition Declaration ModuleDeclaration module RequiresExpression RequirementList SimpleRequirement TypeRequirement CompoundRequirement ReturnTypeRequirement ConstraintConjuction LogicOp ConstraintDisjunction LogicOp ArrayDeclarator ParenthesizedDeclarator ReferenceDeclarator TemplateFunction OperatorName StructuredBindingDeclarator ArrayDeclarator ParenthesizedDeclarator ReferenceDeclarator BitfieldClause FunctionDefinition FunctionDefinition Declaration FunctionDefinition Declaration AccessSpecifier UnionSpecifier ClassSpecifier EnumSpecifier SizedTypeSpecifier TypeSize EnumeratorList Enumerator DependentType Decltype decltype auto PlaceholderTypeSpecifier ParameterPackExpansion ParameterPackExpansion FieldIdentifier PointerExpression SubscriptExpression BinaryExpression ArithOp LogicOp LogicOp BitOp UnaryExpression LogicOp BitOp UpdateExpression CastExpression SizeofExpression sizeof CoAwaitExpression CompoundLiteralExpression NULL NewExpression new NewDeclarator DeleteExpression delete ParameterPackExpansion nullptr this UserDefinedLiteral ParamPack #define PreprocArg #if #ifdef #ifndef #else #endif #elif PreprocDirectiveName Macro Program",maxTerm:433,nodeProps:[["group",-35,1,8,11,15,16,17,19,71,72,100,101,102,104,191,208,229,242,243,270,271,272,277,280,281,282,284,285,286,287,290,292,293,294,295,296,"Expression",-13,18,25,26,27,43,255,256,257,258,262,263,265,266,"Type",-19,126,129,147,150,152,153,158,160,163,164,166,168,170,172,174,176,178,179,188,"Statement"],["isolate",-4,4,5,8,10,""],["openedBy",12,"(",52,"{",54,"["],["closedBy",13,")",51,"}",53,"]"]],propSources:[Fz],skippedNodes:[0,3,4,5,6,7,10,297,298,299,300,301,302,303,304,305,306,308,349,350],repeatNodeCount:43,tokenData:"&AbMfR!UOX$eXY/]YZ5gZ]$e]^1g^p$epq/]qr5}rs8Zst:Ttu$euv!AWvw!Cbwx!Eqxy!Flyz!Gmz{!Hn{|!Iw|}!LX}!O!MY!O!P# m!P!Q#8a!Q!R#@T!R![$'k![!]$@f!]!^$Bn!^!_$Co!_!`%C`!`!a%Dg!a!b%HP!b!c$e!c!n%IQ!n!o%Jl!o!w%IQ!w!x%Jl!x!}%IQ!}#O%Mx#O#P& }#P#Q&3[#Q#R&5a#R#S%IQ#S#T$e#T#i%IQ#i#j&6j#j#o%IQ#o#p&8[#p#q&9]#q#r&;o#r#s&|#Y#o;x#o;'S$e;'S;=`/V<%lO$eGz?Xe)d`(wS'f,U'm<`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a#O$ER#O#P%.w#P;'S$ER;'S;=`%=Z<%lO$ER3h$E[_)d`(wS'f,UOY$ERYZ$FZZr$ERrs$Fxsw$ERwx%4^x!P$ER!P!Q%8|!Q!`$ER!`!a%p!`!a%{_!g:t)d`(wS'f,UOY$ERYZ$FZZr$ERrs$Fxsw$ERwx%4^x!P$ER!P!Q%8|!Q!`$ER!`!a%`Zp$epq&>`qr$ers%dsw$ewx*mx!P$e!P!Q-V!Q!c$e!c!}&?z!}#O$e#O#P'b#P#R$e#R#S&?z#S#T$e#T#o&?z#o;'S$e;'S;=`/V<%lO$e,t&>ie)d`(wS'f,UOX$eXY&>`Zp$epq&>`qr$ers%dsw$ewx*mx!P$e!P!Q-V!Q!c$e!c!}&?z!}#O$e#O#P'b#P#R$e#R#S&?z#S#T$e#T#o&?z#o;'S$e;'S;=`/V<%lO$e,t&@Vc)d`(wSeY'f,UOY$eZr$ers%dsw$ewx*mx!P$e!P!Q-V!Q![&?z![!c$e!c!}&?z!}#O$e#O#P'b#P#R$e#R#S&?z#S#T$e#T#o&?z#o;'S$e;'S;=`/V<%lO$e",tokenizers:[Nz,Bz,1,2,3,4,5,6,7,8,9,10,new hs("j~RQYZXz{^~^O(s~~aP!P!Qd~iO(t~~",25,356)],topRules:{Program:[0,307]},dynamicPrecedences:{17:1,65:1,87:1,94:1,119:1,184:1,187:-10,240:-10,241:1,244:-1,246:-10,247:1,262:-1,267:2,268:2,306:-10,371:3,425:1,426:3,427:1,428:1},specialized:[{term:362,get:t=>Hz[t]||-1},{term:33,get:t=>Kz[t]||-1},{term:66,get:t=>Jz[t]||-1},{term:369,get:t=>eV[t]||-1}],tokenPrec:24852}),iV=at.define({name:"cpp",parser:tV.configure({props:[lt.add({IfStatement:Le({except:/^\s*({|else\b)/}),TryStatement:Le({except:/^\s*({|catch)\b/}),LabeledStatement:Dh,CaseStatement:t=>t.baseIndent+t.unit,BlockComment:()=>null,CompoundStatement:Ni({closing:"}"}),Statement:Le({except:/^{/})}),ct.add({"DeclarationList CompoundStatement EnumeratorList FieldDeclarationList InitializerList":Ri,BlockComment(t){return{from:t.from+2,to:t.to-2}}})]}),languageData:{commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\})$/,closeBrackets:{stringPrefixes:["L","u","U","u8","LR","UR","uR","u8R","R"]}}});function nV(){return new Fe(iV)}const OV=135,LP=1,rV=136,sV=137,NP=2,oV=138,aV=3,lV=4,BP=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],cV=58,hV=40,FP=95,dV=91,Ea=45,uV=46,fV=35,$V=37,QV=38,pV=92,mV=10,gV=42;function ds(t){return t>=65&&t<=90||t>=97&&t<=122||t>=161}function zd(t){return t>=48&&t<=57}function HP(t){return zd(t)||t>=97&&t<=102||t>=65&&t<=70}const KP=(t,e,i)=>(n,O)=>{for(let r=!1,s=0,o=0;;o++){let{next:a}=n;if(ds(a)||a==Ea||a==FP||r&&zd(a))!r&&(a!=Ea||o>0)&&(r=!0),s===o&&a==Ea&&s++,n.advance();else if(a==pV&&n.peek(1)!=mV){if(n.advance(),HP(n.next)){do n.advance();while(HP(n.next));n.next==32&&n.advance()}else n.next>-1&&n.advance();r=!0}else{r&&n.acceptToken(s==2&&O.canShift(NP)?e:a==hV?i:t);break}}},PV=new ie(KP(rV,NP,sV),{contextual:!0}),SV=new ie(KP(oV,aV,lV),{contextual:!0}),XV=new ie(t=>{if(BP.includes(t.peek(-1))){let{next:e}=t;(ds(e)||e==FP||e==fV||e==uV||e==gV||e==dV||e==cV&&ds(t.peek(1))||e==Ea||e==QV)&&t.acceptToken(OV)}}),bV=new ie(t=>{if(!BP.includes(t.peek(-1))){let{next:e}=t;if(e==$V&&(t.advance(),t.acceptToken(LP)),ds(e)){do t.advance();while(ds(t.next)||zd(t.next));t.acceptToken(LP)}}}),yV=ot({"AtKeyword import charset namespace keyframes media supports font-feature-values":f.definitionKeyword,"from to selector scope MatchFlag":f.keyword,NamespaceName:f.namespace,KeyframeName:f.labelName,KeyframeRangeName:f.operatorKeyword,TagName:f.tagName,ClassName:f.className,PseudoClassName:f.constant(f.className),IdName:f.labelName,"FeatureName PropertyName":f.propertyName,AttributeName:f.attributeName,NumberLiteral:f.number,KeywordQuery:f.keyword,UnaryQueryOp:f.operatorKeyword,"CallTag ValueName FontName":f.atom,VariableName:f.variableName,Callee:f.operatorKeyword,Unit:f.unit,"UniversalSelector NestingSelector":f.definitionOperator,"MatchOp CompareOp":f.compareOperator,"ChildOp SiblingOp, LogicOp":f.logicOperator,BinOp:f.arithmeticOperator,Important:f.modifier,Comment:f.blockComment,ColorLiteral:f.color,"ParenthesizedContent StringLiteral":f.string,":":f.punctuation,"PseudoOp #":f.derefOperator,"; , |":f.separator,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace}),xV={__proto__:null,lang:44,"nth-child":44,"nth-last-child":44,"nth-of-type":44,"nth-last-of-type":44,dir:44,"host-context":44,if:90,url:132,"url-prefix":132,domain:132,regexp:132},TV={__proto__:null,or:104,and:104,not:112,only:112,layer:186},wV={__proto__:null,selector:118,layer:182},vV={__proto__:null,"@import":178,"@media":190,"@charset":194,"@namespace":198,"@keyframes":204,"@supports":216,"@scope":220,"@font-feature-values":226},kV={__proto__:null,to:223},_V=ht.deserialize({version:14,states:"IpQYQdOOO#}QdOOP$UO`OOO%OQaO'#CfOOQP'#Ce'#CeO%VQdO'#CgO%[Q`O'#CgO%aQaO'#FdO&XQdO'#CkO&xQaO'#CcO'SQdO'#CnO'_QdO'#DtO'dQdO'#DvO'oQdO'#D}O'oQdO'#EQOOQP'#Fd'#FdO)OQhO'#EsOOQS'#Fc'#FcOOQS'#Ev'#EvQYQdOOO)VQdO'#EWO*cQhO'#E^O)VQdO'#E`O*jQdO'#EbO*uQdO'#EeO)zQhO'#EkO*}QdO'#EmO+YQdO'#EpO+_QaO'#CfO+fQ`O'#ETO+kQ`O'#FnO+vQdO'#FnQO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%j;'S;=`%{<%lO%jbFoU!e`Oy%jz#f%j#f#gGR#g;'S%j;'S;=`%{<%lO%jbGWU!e`Oy%jz#h%j#h#iGj#i;'S%j;'S;=`%{<%lO%jbGoU!e`Oy%jz#T%j#T#UHR#U;'S%j;'S;=`%{<%lO%jbHWU!e`Oy%jz#b%j#b#cHj#c;'S%j;'S;=`%{<%lO%jbHoU!e`Oy%jz#h%j#h#iIR#i;'S%j;'S;=`%{<%lO%jbIYS$cQ!e`Oy%jz;'S%j;'S;=`%{<%lO%jjIkSsYOy%jz;'S%j;'S;=`%{<%lO%jfI|U$XUOy%jz!_%j!_!`2n!`;'S%j;'S;=`%{<%lO%jjJeSrYOy%jz;'S%j;'S;=`%{<%lO%jfJvU!uQOy%jz!_%j!_!`2n!`;'S%j;'S;=`%{<%lO%j`K]P;=`<%l%Z",tokenizers:[XV,bV,PV,SV,1,2,3,4,new hs("m~RRYZ[z{a~~g~aO$T~~dP!P!Qg~lO$U~~",28,142)],topRules:{StyleSheet:[0,6],Styles:[1,116]},dynamicPrecedences:{84:1},specialized:[{term:137,get:t=>xV[t]||-1},{term:138,get:t=>TV[t]||-1},{term:4,get:t=>wV[t]||-1},{term:28,get:t=>vV[t]||-1},{term:136,get:t=>kV[t]||-1}],tokenPrec:2256});let Vd=null;function qd(){if(!Vd&&typeof document=="object"&&document.body){let{style:t}=document.body,e=[],i=new Set;for(let n in t)n!="cssText"&&n!="cssFloat"&&typeof t[n]=="string"&&(/[A-Z]/.test(n)&&(n=n.replace(/[A-Z]/g,O=>"-"+O.toLowerCase())),i.has(n)||(e.push(n),i.add(n)));Vd=e.sort().map(n=>({type:"property",label:n,apply:n+": "}))}return Vd||[]}const JP=["active","after","any-link","autofill","backdrop","before","checked","cue","default","defined","disabled","empty","enabled","file-selector-button","first","first-child","first-letter","first-line","first-of-type","focus","focus-visible","focus-within","fullscreen","has","host","host-context","hover","in-range","indeterminate","invalid","is","lang","last-child","last-of-type","left","link","marker","modal","not","nth-child","nth-last-child","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","part","placeholder","placeholder-shown","read-only","read-write","required","right","root","scope","selection","slotted","target","target-text","valid","visited","where"].map(t=>({type:"class",label:t})),eS=["above","absolute","activeborder","additive","activecaption","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","antialiased","appworkspace","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic-abegede-gez","ethiopic-halehame-aa-er","ethiopic-halehame-gez","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","graytext","grid","groove","hand","hard-light","help","hidden","hide","higher","highlight","highlighttext","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","justify","keep-all","landscape","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-hexadecimal","lower-latin","lower-norwegian","lowercase","ltr","luminosity","manipulation","match","matrix","matrix3d","medium","menu","menutext","message-box","middle","min-intrinsic","mix","monospace","move","multiple","multiple_mask_images","multiply","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","opacity","open-quote","optimizeLegibility","optimizeSpeed","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","text","text-bottom","text-top","textarea","textfield","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","to","top","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-latin","uppercase","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"].map(t=>({type:"keyword",label:t})).concat(["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"].map(t=>({type:"constant",label:t}))),RV=["a","abbr","address","article","aside","b","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","dd","del","details","dfn","dialog","div","dl","dt","em","figcaption","figure","footer","form","header","hgroup","h1","h2","h3","h4","h5","h6","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","main","meter","nav","ol","output","p","pre","ruby","section","select","small","source","span","strong","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","tr","u","ul"].map(t=>({type:"type",label:t})),ZV=["@charset","@color-profile","@container","@counter-style","@font-face","@font-feature-values","@font-palette-values","@import","@keyframes","@layer","@media","@namespace","@page","@position-try","@property","@scope","@starting-style","@supports","@view-transition"].map(t=>({type:"keyword",label:t})),Fi=/^(\w[\w-]*|-\w[\w-]*|)$/,YV=/^-(-[\w-]*)?$/;function zV(t,e){var i;if((t.name=="("||t.type.isError)&&(t=t.parent||t),t.name!="ArgList")return!1;let n=(i=t.parent)===null||i===void 0?void 0:i.firstChild;return n?.name!="Callee"?!1:e.sliceString(n.from,n.to)=="var"}const tS=new Uh,VV=["Declaration"];function qV(t){for(let e=t;;){if(e.type.isTop)return e;if(!(e=e.parent))return t}}function iS(t,e,i){if(e.to-e.from>4096){let n=tS.get(e);if(n)return n;let O=[],r=new Set,s=e.cursor(fe.IncludeAnonymous);if(s.firstChild())do for(let o of iS(t,s.node,i))r.has(o.label)||(r.add(o.label),O.push(o));while(s.nextSibling());return tS.set(e,O),O}else{let n=[],O=new Set;return e.cursor().iterate(r=>{var s;if(i(r)&&r.matchContext(VV)&&((s=r.node.nextSibling)===null||s===void 0?void 0:s.name)==":"){let o=t.sliceString(r.from,r.to);O.has(o)||(O.add(o),n.push({label:o,type:"variable"}))}}),n}}const nS=t=>e=>{let{state:i,pos:n}=e,O=$e(i).resolveInner(n,-1),r=O.type.isError&&O.from==O.to-1&&i.doc.sliceString(O.from,O.to)=="-";if(O.name=="PropertyName"||(r||O.name=="TagName")&&/^(Block|Styles)$/.test(O.resolve(O.to).name))return{from:O.from,options:qd(),validFor:Fi};if(O.name=="ValueName")return{from:O.from,options:eS,validFor:Fi};if(O.name=="PseudoClassName")return{from:O.from,options:JP,validFor:Fi};if(t(O)||(e.explicit||r)&&zV(O,i.doc))return{from:t(O)||r?O.from:n,options:iS(i.doc,qV(O),t),validFor:YV};if(O.name=="TagName"){for(let{parent:a}=O;a;a=a.parent)if(a.name=="Block")return{from:O.from,options:qd(),validFor:Fi};return{from:O.from,options:RV,validFor:Fi}}if(O.name=="AtKeyword")return{from:O.from,options:ZV,validFor:Fi};if(!e.explicit)return null;let s=O.resolve(n),o=s.childBefore(n);return o&&o.name==":"&&s.name=="PseudoClassSelector"?{from:n,options:JP,validFor:Fi}:o&&o.name==":"&&s.name=="Declaration"||s.name=="ArgList"?{from:n,options:eS,validFor:Fi}:s.name=="Block"||s.name=="Styles"?{from:n,options:qd(),validFor:Fi}:null},UV=nS(t=>t.name=="VariableName"),Ia=at.define({name:"css",parser:_V.configure({props:[lt.add({Declaration:Le()}),ct.add({"Block KeyframeList":Ri})]}),languageData:{commentTokens:{block:{open:"/*",close:"*/"}},indentOnInput:/^\s*\}$/,wordChars:"-"}});function OS(){return new Fe(Ia,Ia.data.of({autocomplete:UV}))}const WV=55,CV=1,jV=56,GV=2,EV=57,IV=3,rS=4,AV=5,Ud=6,sS=7,oS=8,aS=9,lS=10,MV=11,DV=12,LV=13,Wd=58,NV=14,BV=15,cS=59,hS=21,FV=23,dS=24,HV=25,Cd=27,uS=28,KV=29,JV=32,eq=35,tq=37,iq=38,nq=0,Oq=1,rq={area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},sq={dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},fS={dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}};function oq(t){return t==45||t==46||t==58||t>=65&&t<=90||t==95||t>=97&&t<=122||t>=161}let $S=null,QS=null,pS=0;function jd(t,e){let i=t.pos+e;if(pS==i&&QS==t)return $S;let n=t.peek(e),O="";for(;oq(n);)O+=String.fromCharCode(n),n=t.peek(++e);return QS=t,pS=i,$S=O?O.toLowerCase():n==aq||n==lq?void 0:null}const mS=60,Aa=62,Gd=47,aq=63,lq=33,cq=45;function gS(t,e){this.name=t,this.parent=e}const hq=[Ud,lS,sS,oS,aS],dq=new AO({start:null,shift(t,e,i,n){return hq.indexOf(e)>-1?new gS(jd(n,1)||"",t):t},reduce(t,e){return e==hS&&t?t.parent:t},reuse(t,e,i,n){let O=e.type.id;return O==Ud||O==tq?new gS(jd(n,1)||"",t):t},strict:!1}),uq=new ie((t,e)=>{if(t.next!=mS){t.next<0&&e.context&&t.acceptToken(Wd);return}t.advance();let i=t.next==Gd;i&&t.advance();let n=jd(t,0);if(n===void 0)return;if(!n)return t.acceptToken(i?BV:NV);let O=e.context?e.context.name:null;if(i){if(n==O)return t.acceptToken(MV);if(O&&sq[O])return t.acceptToken(Wd,-2);if(e.dialectEnabled(nq))return t.acceptToken(DV);for(let r=e.context;r;r=r.parent)if(r.name==n)return;t.acceptToken(LV)}else{if(n=="script")return t.acceptToken(sS);if(n=="style")return t.acceptToken(oS);if(n=="textarea")return t.acceptToken(aS);if(rq.hasOwnProperty(n))return t.acceptToken(lS);O&&fS[O]&&fS[O][n]?t.acceptToken(Wd,-1):t.acceptToken(Ud)}},{contextual:!0}),fq=new ie(t=>{for(let e=0,i=0;;i++){if(t.next<0){i&&t.acceptToken(cS);break}if(t.next==cq)e++;else if(t.next==Aa&&e>=2){i>=3&&t.acceptToken(cS,-2);break}else e=0;t.advance()}});function $q(t){for(;t;t=t.parent)if(t.name=="svg"||t.name=="math")return!0;return!1}const Qq=new ie((t,e)=>{if(t.next==Gd&&t.peek(1)==Aa){let i=e.dialectEnabled(Oq)||$q(e.context);t.acceptToken(i?AV:rS,2)}else t.next==Aa&&t.acceptToken(rS,1)});function Ed(t,e,i){let n=2+t.length;return new ie(O=>{for(let r=0,s=0,o=0;;o++){if(O.next<0){o&&O.acceptToken(e);break}if(r==0&&O.next==mS||r==1&&O.next==Gd||r>=2&&rs?O.acceptToken(e,-s):O.acceptToken(i,-(s-2));break}else if((O.next==10||O.next==13)&&o){O.acceptToken(e,1);break}else r=s=0;O.advance()}})}const pq=Ed("script",WV,CV),mq=Ed("style",jV,GV),gq=Ed("textarea",EV,IV),Pq=ot({"Text RawText IncompleteTag IncompleteCloseTag":f.content,"StartTag StartCloseTag SelfClosingEndTag EndTag":f.angleBracket,TagName:f.tagName,"MismatchedCloseTag/TagName":[f.tagName,f.invalid],AttributeName:f.attributeName,"AttributeValue UnquotedAttributeValue":f.attributeValue,Is:f.definitionOperator,"EntityReference CharacterReference":f.character,Comment:f.blockComment,ProcessingInst:f.processingInstruction,DoctypeDecl:f.documentMeta}),Sq=ht.deserialize({version:14,states:",xOVO!rOOO!ZQ#tO'#CrO!`Q#tO'#C{O!eQ#tO'#DOO!jQ#tO'#DRO!oQ#tO'#DTO!tOaO'#CqO#PObO'#CqO#[OdO'#CqO$kO!rO'#CqOOO`'#Cq'#CqO$rO$fO'#DUO$zQ#tO'#DWO%PQ#tO'#DXOOO`'#Dl'#DlOOO`'#DZ'#DZQVO!rOOO%UQ&rO,59^O%aQ&rO,59gO%lQ&rO,59jO%wQ&rO,59mO&SQ&rO,59oOOOa'#D_'#D_O&_OaO'#CyO&jOaO,59]OOOb'#D`'#D`O&rObO'#C|O&}ObO,59]OOOd'#Da'#DaO'VOdO'#DPO'bOdO,59]OOO`'#Db'#DbO'jO!rO,59]O'qQ#tO'#DSOOO`,59],59]OOOp'#Dc'#DcO'vO$fO,59pOOO`,59p,59pO(OQ#|O,59rO(TQ#|O,59sOOO`-E7X-E7XO(YQ&rO'#CtOOQW'#D['#D[O(hQ&rO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~Og!mO~OS!nO~Ol!qO!a!oO!c!pO~OS!rO~OS!sO~OS!tO~Ob!uOc!uOd!uO!a!wO!b!uO~Ob!xOc!xOd!xO!c!wO!d!xO~Ob!uOc!uOd!uO!a!{O!b!uO~Ob!xOc!xOd!xO!c!{O!d!xO~OT~cbd!ey|!e~",goto:"%q!aPPPPPPPPPPPPPPPPPPPPP!b!hP!nPP!zP!}#Q#T#Z#^#a#g#j#m#s#y!bP!b!bP$P$V$m$s$y%P%V%]%cPPPPPPPP%iX^OX`pXUOX`pezabcde{!O!Q!S!UR!q!dRhUR!XhXVOX`pRkVR!XkXWOX`pRnWR!XnXXOX`pQrXR!XpXYOX`pQ`ORx`Q{aQ!ObQ!QcQ!SdQ!UeZ!e{!O!Q!S!UQ!v!oR!z!vQ!y!pR!|!yQgUR!VgQjVR!YjQmWR![mQpXR!^pQtZR!`tS_O`ToXp",nodeNames:"⚠ StartCloseTag StartCloseTag StartCloseTag EndTag SelfClosingEndTag StartTag StartTag StartTag StartTag StartTag StartCloseTag StartCloseTag StartCloseTag IncompleteTag IncompleteCloseTag Document Text EntityReference CharacterReference InvalidEntity Element OpenTag TagName Attribute AttributeName Is AttributeValue UnquotedAttributeValue ScriptText CloseTag OpenTag StyleText CloseTag OpenTag TextareaText CloseTag OpenTag CloseTag SelfClosingTag Comment ProcessingInst MismatchedCloseTag CloseTag DoctypeDecl",maxTerm:68,context:dq,nodeProps:[["closedBy",-10,1,2,3,7,8,9,10,11,12,13,"EndTag",6,"EndTag SelfClosingEndTag",-4,22,31,34,37,"CloseTag"],["openedBy",4,"StartTag StartCloseTag",5,"StartTag",-4,30,33,36,38,"OpenTag"],["group",-10,14,15,18,19,20,21,40,41,42,43,"Entity",17,"Entity TextContent",-3,29,32,35,"TextContent Entity"],["isolate",-11,22,30,31,33,34,36,37,38,39,42,43,"ltr",-3,27,28,40,""]],propSources:[Pq],skippedNodes:[0],repeatNodeCount:9,tokenData:"!]tw8twx7Sx!P8t!P!Q5u!Q!]8t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6i!b;'S!6V;'S;=`!7Q<%lO!6VP!6lTO!`!6V!`!a!6{!a;'S!6V;'S;=`!7Q<%lO!6VP!7QOyPP!7TP;=`<%l!6Vq!7]V!dpOv!5kvx!6Vx!`!5k!`!a!7r!a;'S!5k;'S;=`!8V<%lO!5kq!7yS!dpyPOv(Vx;'S(V;'S;=`(h<%lO(Vq!8YP;=`<%l!5ka!8bX!b`Or!8]rs!6Vsv!8]vw!6Vw!a!8]!a!b!8}!b;'S!8];'S;=`!:V<%lO!8]a!9SX!b`Or!8]rs!6Vsv!8]vw!6Vw!`!8]!`!a!9o!a;'S!8];'S;=`!:V<%lO!8]a!9vT!b`yPOr)esv)ew;'S)e;'S;=`)y<%lO)ea!:YP;=`<%l!8]!R!:dY!b`!dpOr!4trs!5ksv!4tvw!6Vwx!8]x!`!4t!`!a!;S!a;'S!4t;'S;=`!;r<%lO!4t!R!;]V!b`!dpyPOr*Vrs(Vsv*Vwx)ex;'S*V;'S;=`*s<%lO*V!R!;uP;=`<%l!4t!V!{let l=o.type.id;if(l==KV)return Id(o,a,i);if(l==JV)return Id(o,a,n);if(l==eq)return Id(o,a,O);if(l==hS&&r.length){let c=o.node,h=c.firstChild,d=h&&SS(h,a),u;if(d){for(let $ of r)if($.tag==d&&(!$.attrs||$.attrs(u||(u=PS(h,a))))){let Q=c.lastChild,p=Q.type.id==iq?Q.from:c.to;if(p>h.to)return{parser:$.parser,overlay:[{from:h.to,to:p}]}}}}if(s&&l==dS){let c=o.node,h;if(h=c.firstChild){let d=s[a.read(h.from,h.to)];if(d)for(let u of d){if(u.tagName&&u.tagName!=SS(c.parent,a))continue;let $=c.lastChild;if($.type.id==Cd){let Q=$.from+1,p=$.lastChild,m=$.to-(p&&p.isError?0:1);if(m>Q)return{parser:u.parser,overlay:[{from:Q,to:m}],bracketed:!0}}else if($.type.id==uS)return{parser:u.parser,overlay:[{from:$.from,to:$.to}]}}}}return null})}const Xq=316,bq=317,bS=1,yq=2,xq=3,Tq=4,wq=318,vq=320,kq=321,_q=5,Rq=6,Zq=0,Ad=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],yS=125,Yq=59,Md=47,zq=42,Vq=43,qq=45,Uq=60,Wq=44,Cq=63,jq=46,Gq=91,Eq=new AO({start:!1,shift(t,e){return e==_q||e==Rq||e==vq?t:e==kq},strict:!1}),Iq=new ie((t,e)=>{let{next:i}=t;(i==yS||i==-1||e.context)&&t.acceptToken(wq)},{contextual:!0,fallback:!0}),Aq=new ie((t,e)=>{let{next:i}=t,n;Ad.indexOf(i)>-1||i==Md&&((n=t.peek(1))==Md||n==zq)||i!=yS&&i!=Yq&&i!=-1&&!e.context&&t.acceptToken(Xq)},{contextual:!0}),Mq=new ie((t,e)=>{t.next==Gq&&!e.context&&t.acceptToken(bq)},{contextual:!0}),Dq=new ie((t,e)=>{let{next:i}=t;if(i==Vq||i==qq){if(t.advance(),i==t.next){t.advance();let n=!e.context&&e.canShift(bS);t.acceptToken(n?bS:yq)}}else i==Cq&&t.peek(1)==jq&&(t.advance(),t.advance(),(t.next<48||t.next>57)&&t.acceptToken(xq))},{contextual:!0});function Dd(t,e){return t>=65&&t<=90||t>=97&&t<=122||t==95||t>=192||!e&&t>=48&&t<=57}const Lq=new ie((t,e)=>{if(t.next!=Uq||!e.dialectEnabled(Zq)||(t.advance(),t.next==Md))return;let i=0;for(;Ad.indexOf(t.next)>-1;)t.advance(),i++;if(Dd(t.next,!0)){for(t.advance(),i++;Dd(t.next,!1);)t.advance(),i++;for(;Ad.indexOf(t.next)>-1;)t.advance(),i++;if(t.next==Wq)return;for(let n=0;;n++){if(n==7){if(!Dd(t.next,!0))return;break}if(t.next!="extends".charCodeAt(n))break;t.advance(),i++}}t.acceptToken(Tq,-i)}),Nq=ot({"get set async static":f.modifier,"for while do if else switch try catch finally return throw break continue default case defer":f.controlKeyword,"in of await yield void typeof delete instanceof as satisfies":f.operatorKeyword,"let var const using function class extends":f.definitionKeyword,"import export from":f.moduleKeyword,"with debugger new":f.keyword,TemplateString:f.special(f.string),super:f.atom,BooleanLiteral:f.bool,this:f.self,null:f.null,Star:f.modifier,VariableName:f.variableName,"CallExpression/VariableName TaggedTemplateExpression/VariableName":f.function(f.variableName),VariableDefinition:f.definition(f.variableName),Label:f.labelName,PropertyName:f.propertyName,PrivatePropertyName:f.special(f.propertyName),"CallExpression/MemberExpression/PropertyName":f.function(f.propertyName),"FunctionDeclaration/VariableDefinition":f.function(f.definition(f.variableName)),"ClassDeclaration/VariableDefinition":f.definition(f.className),"NewExpression/VariableName":f.className,PropertyDefinition:f.definition(f.propertyName),PrivatePropertyDefinition:f.definition(f.special(f.propertyName)),UpdateOp:f.updateOperator,"LineComment Hashbang":f.lineComment,BlockComment:f.blockComment,Number:f.number,String:f.string,Escape:f.escape,ArithOp:f.arithmeticOperator,LogicOp:f.logicOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,RegExp:f.regexp,Equals:f.definitionOperator,Arrow:f.function(f.punctuation),": Spread":f.punctuation,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace,"InterpolationStart InterpolationEnd":f.special(f.brace),".":f.derefOperator,", ;":f.separator,"@":f.meta,TypeName:f.typeName,TypeDefinition:f.definition(f.typeName),"type enum interface implements namespace module declare":f.definitionKeyword,"abstract global Privacy readonly override":f.modifier,"is keyof unique infer asserts":f.operatorKeyword,JSXAttributeValue:f.attributeValue,JSXText:f.content,"JSXStartTag JSXStartCloseTag JSXSelfCloseEndTag JSXEndTag":f.angleBracket,"JSXIdentifier JSXNameSpacedName":f.tagName,"JSXAttribute/JSXIdentifier JSXAttribute/JSXNameSpacedName":f.attributeName,"JSXBuiltin/JSXIdentifier":f.standard(f.tagName)}),Bq={__proto__:null,export:20,as:25,from:33,default:36,async:41,function:42,in:52,out:55,const:56,extends:60,this:64,true:72,false:72,null:84,void:88,typeof:92,super:108,new:142,delete:154,yield:163,await:167,class:172,public:235,private:235,protected:235,readonly:237,instanceof:256,satisfies:259,import:292,keyof:349,unique:353,infer:359,asserts:395,is:397,abstract:417,implements:419,type:421,let:424,var:426,using:429,interface:435,enum:439,namespace:445,module:447,declare:451,global:455,defer:471,for:476,of:485,while:488,with:492,do:496,if:500,else:502,switch:506,case:512,try:518,catch:522,finally:526,return:530,throw:534,break:538,continue:542,debugger:546},Fq={__proto__:null,async:129,get:131,set:133,declare:195,public:197,private:197,protected:197,static:199,abstract:201,override:203,readonly:209,accessor:211,new:401},Hq={__proto__:null,"<":193},Kq=ht.deserialize({version:14,states:"$F|Q%TQlOOO%[QlOOO'_QpOOP(lO`OOO*zQ!0MxO'#CiO+RO#tO'#CjO+aO&jO'#CjO+oO#@ItO'#DaO.QQlO'#DgO.bQlO'#DrO%[QlO'#DzO0fQlO'#ESOOQ!0Lf'#E['#E[O1PQ`O'#EXOOQO'#Ep'#EpOOQO'#Il'#IlO1XQ`O'#GsO1dQ`O'#EoO1iQ`O'#EoO3hQ!0MxO'#JrO6[Q!0MxO'#JsO6uQ`O'#F]O6zQ,UO'#FtOOQ!0Lf'#Ff'#FfO7VO7dO'#FfO9XQMhO'#F|O9`Q`O'#F{OOQ!0Lf'#Js'#JsOOQ!0Lb'#Jr'#JrO9eQ`O'#GwOOQ['#K_'#K_O9pQ`O'#IYO9uQ!0LrO'#IZOOQ['#J`'#J`OOQ['#I_'#I_Q`QlOOQ`QlOOO9}Q!L^O'#DvO:UQlO'#EOO:]QlO'#EQO9kQ`O'#GsO:dQMhO'#CoO:rQ`O'#EnO:}Q`O'#EyO;hQMhO'#FeO;xQ`O'#GsOOQO'#K`'#K`O;}Q`O'#K`O<]Q`O'#G{O<]Q`O'#G|O<]Q`O'#HOO9kQ`O'#HRO=SQ`O'#HUO>kQ`O'#CeO>{Q`O'#HcO?TQ`O'#HiO?TQ`O'#HkO`QlO'#HmO?TQ`O'#HoO?TQ`O'#HrO?YQ`O'#HxO?_Q!0LsO'#IOO%[QlO'#IQO?jQ!0LsO'#ISO?uQ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Q%zyQ'd!iQ'o!uU+m%{%|%}Q-W'VU-k'e'f'gS-o'k'uQ0Q*jS1Q+n+oQ2o-YS2{-l-mQ3S-tS4p0R0UQ5b1RQ6v2uQ6y2|Q7O3TU7{4r4s4vQ9z7}R;O9{S$wi>PR*{%VU%Ui%V>PR0f*yQ$viS(u#v+iS)c$b$cQ)e$dQ*[$xS*e${*YQ*t%OQ*u%QQ+Q%^Q+R%_Q+V%cQ.lPQ=}>XQ>O>YQ>Z>]R>[>^Q+O%]Q.nSR#[WR'Z!el!tQ!r!v!y!z'`'l'm'n-e-u1o5{5}S'V!e-]U*j$|*Z*oS-Y'W'_S0U*k*qQ0^*rQ2u-cQ4v0[R4{0_R({#xQ!fQT-d'`-e]!qQ!r'`-e1o5{Q#p]R'i < TypeParamList in out const TypeDefinition extends ThisType this LiteralType ArithOp Number BooleanLiteral TemplateType InterpolationEnd Interpolation InterpolationStart NullType null VoidType void TypeofType typeof MemberExpression . PropertyName [ TemplateString Escape Interpolation super RegExp ] ArrayExpression Spread , } { ObjectExpression Property async get set PropertyDefinition Block : NewTarget new NewExpression ) ( ArgList UnaryExpression delete LogicOp BitOp YieldExpression yield AwaitExpression await ParenthesizedExpression ClassExpression class ClassBody MethodDeclaration Decorator @ MemberExpression PrivatePropertyName CallExpression TypeArgList CompareOp < declare Privacy static abstract override PrivatePropertyDefinition PropertyDeclaration readonly accessor Optional TypeAnnotation Equals StaticBlock FunctionExpression ArrowFunction ParamList ParamList ArrayPattern ObjectPattern PatternProperty Privacy readonly Arrow MemberExpression BinaryExpression ArithOp ArithOp ArithOp ArithOp BitOp CompareOp instanceof satisfies CompareOp BitOp BitOp BitOp LogicOp LogicOp ConditionalExpression LogicOp LogicOp AssignmentExpression UpdateOp PostfixExpression CallExpression InstantiationExpression TaggedTemplateExpression DynamicImport import ImportMeta JSXElement JSXSelfCloseEndTag JSXSelfClosingTag JSXIdentifier JSXBuiltin JSXIdentifier JSXNamespacedName JSXMemberExpression JSXSpreadAttribute JSXAttribute JSXAttributeValue JSXEscape JSXEndTag JSXOpenTag JSXFragmentTag JSXText JSXEscape JSXStartCloseTag JSXCloseTag PrefixCast < ArrowFunction TypeParamList SequenceExpression InstantiationExpression KeyofType keyof UniqueType unique ImportType InferredType infer TypeName ParenthesizedType FunctionSignature ParamList NewSignature IndexedType TupleType Label ArrayType ReadonlyType ObjectType MethodType PropertyType IndexSignature PropertyDefinition CallSignature TypePredicate asserts is NewSignature new UnionType LogicOp IntersectionType LogicOp ConditionalType ParameterizedType ClassDeclaration abstract implements type VariableDeclaration let var using TypeAliasDeclaration InterfaceDeclaration interface EnumDeclaration enum EnumBody NamespaceDeclaration namespace module AmbientDeclaration declare GlobalDeclaration global ClassDeclaration ClassBody AmbientFunctionDeclaration ExportGroup VariableName VariableName ImportDeclaration defer ImportGroup ForStatement for ForSpec ForInSpec ForOfSpec of WhileStatement while WithStatement with DoStatement do IfStatement if else SwitchStatement switch SwitchBody CaseLabel case DefaultLabel TryStatement try CatchClause catch FinallyClause finally ReturnStatement return ThrowStatement throw BreakStatement break ContinueStatement continue DebuggerStatement debugger LabeledStatement ExpressionStatement SingleExpression SingleClassItem",maxTerm:380,context:Eq,nodeProps:[["isolate",-8,5,6,14,37,39,51,53,55,""],["group",-26,9,17,19,68,207,211,215,216,218,221,224,234,237,243,245,247,249,252,258,264,266,268,270,272,274,275,"Statement",-34,13,14,32,35,36,42,51,54,55,57,62,70,72,76,80,82,84,85,110,111,120,121,136,139,141,142,143,144,145,147,148,167,169,171,"Expression",-23,31,33,37,41,43,45,173,175,177,178,180,181,182,184,185,186,188,189,190,201,203,205,206,"Type",-3,88,103,109,"ClassItem"],["openedBy",23,"<",38,"InterpolationStart",56,"[",60,"{",73,"(",160,"JSXStartCloseTag"],["closedBy",-2,24,168,">",40,"InterpolationEnd",50,"]",61,"}",74,")",165,"JSXEndTag"]],propSources:[Nq],skippedNodes:[0,5,6,278],repeatNodeCount:37,tokenData:"$Fq07[R!bOX%ZXY+gYZ-yZ[+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![!^%Z!^!_*g!_!c%Z!c!}Er!}#O%Z#O#P&c#P#R%Z#R#SEr#S#T%Z#T#oEr#o#p*g#p$g%Z$g;'SEr;'S;=`I|<%lOEr",tokenizers:[Aq,Mq,Dq,Lq,2,3,4,5,6,7,8,9,10,11,12,13,14,Iq,new hs("$S~RRtu[#O#Pg#S#T#|~_P#o#pb~gOx~~jVO#i!P#i#j!U#j#l!P#l#m!q#m;'S!P;'S;=`#v<%lO!P~!UO!U~~!XS!Q![!e!c!i!e#T#Z!e#o#p#Z~!hR!Q![!q!c!i!q#T#Z!q~!tR!Q![!}!c!i!}#T#Z!}~#QR!Q![!P!c!i!P#T#Z!P~#^R!Q![#g!c!i#g#T#Z#g~#jS!Q![#g!c!i#g#T#Z#g#q#r!P~#yP;=`<%l!P~$RO(c~~",141,340),new hs("j~RQYZXz{^~^O(Q~~aP!P!Qd~iO(R~~",25,323)],topRules:{Script:[0,7],SingleExpression:[1,276],SingleClassItem:[2,277]},dialects:{jsx:0,ts:15175},dynamicPrecedences:{80:1,82:1,94:1,169:1,199:1},specialized:[{term:327,get:t=>Bq[t]||-1},{term:343,get:t=>Fq[t]||-1},{term:95,get:t=>Hq[t]||-1}],tokenPrec:15201}),xS=[_e("function ${name}(${params}) {\n ${}\n}",{label:"function",detail:"definition",type:"keyword"}),_e("for (let ${index} = 0; ${index} < ${bound}; ${index}++) {\n ${}\n}",{label:"for",detail:"loop",type:"keyword"}),_e("for (let ${name} of ${collection}) {\n ${}\n}",{label:"for",detail:"of loop",type:"keyword"}),_e("do {\n ${}\n} while (${})",{label:"do",detail:"loop",type:"keyword"}),_e("while (${}) {\n ${}\n}",{label:"while",detail:"loop",type:"keyword"}),_e(`try { + \${} +} catch (\${error}) { + \${} +}`,{label:"try",detail:"/ catch block",type:"keyword"}),_e("if (${}) {\n ${}\n}",{label:"if",detail:"block",type:"keyword"}),_e(`if (\${}) { + \${} +} else { + \${} +}`,{label:"if",detail:"/ else block",type:"keyword"}),_e(`class \${name} { + constructor(\${params}) { + \${} + } +}`,{label:"class",detail:"definition",type:"keyword"}),_e('import {${names}} from "${module}"\n${}',{label:"import",detail:"named",type:"keyword"}),_e('import ${name} from "${module}"\n${}',{label:"import",detail:"default",type:"keyword"})],Jq=xS.concat([_e("interface ${name} {\n ${}\n}",{label:"interface",detail:"definition",type:"keyword"}),_e("type ${name} = ${type}",{label:"type",detail:"definition",type:"keyword"}),_e("enum ${name} {\n ${}\n}",{label:"enum",detail:"definition",type:"keyword"})]),TS=new Uh,wS=new Set(["Script","Block","FunctionExpression","FunctionDeclaration","ArrowFunction","MethodDeclaration","ForStatement"]);function us(t){return(e,i)=>{let n=e.node.getChild("VariableDefinition");return n&&i(n,t),!0}}const eU=["FunctionDeclaration"],tU={FunctionDeclaration:us("function"),ClassDeclaration:us("class"),ClassExpression:()=>!0,EnumDeclaration:us("constant"),TypeAliasDeclaration:us("type"),NamespaceDeclaration:us("namespace"),VariableDefinition(t,e){t.matchContext(eU)||e(t,"variable")},TypeDefinition(t,e){e(t,"type")},__proto__:null};function vS(t,e){let i=TS.get(e);if(i)return i;let n=[],O=!0;function r(s,o){let a=t.sliceString(s.from,s.to);n.push({label:a,type:o})}return e.cursor(fe.IncludeAnonymous).iterate(s=>{if(O)O=!1;else if(s.name){let o=tU[s.name];if(o&&o(s,r)||wS.has(s.name))return!1}else if(s.to-s.from>8192){for(let o of vS(t,s.node))n.push(o);return!1}}),TS.set(e,n),n}const kS=/^[\w$\xa1-\uffff][\w$\d\xa1-\uffff]*$/,_S=["TemplateString","String","RegExp","LineComment","BlockComment","VariableDefinition","TypeDefinition","Label","PropertyDefinition","PropertyName","PrivatePropertyDefinition","PrivatePropertyName","JSXText","JSXAttributeValue","JSXOpenTag","JSXCloseTag","JSXSelfClosingTag",".","?."];function iU(t){let e=$e(t.state).resolveInner(t.pos,-1);if(_S.indexOf(e.name)>-1)return null;let i=e.name=="VariableName"||e.to-e.from<20&&kS.test(t.state.sliceDoc(e.from,e.to));if(!i&&!t.explicit)return null;let n=[];for(let O=e;O;O=O.parent)wS.has(O.name)&&(n=n.concat(vS(t.state.doc,O)));return{options:n,from:i?e.from:t.pos,validFor:kS}}const Vi=at.define({name:"javascript",parser:Kq.configure({props:[lt.add({IfStatement:Le({except:/^\s*({|else\b)/}),TryStatement:Le({except:/^\s*({|catch\b|finally\b)/}),LabeledStatement:Dh,SwitchBody:t=>{let e=t.textAfter,i=/^\s*\}/.test(e),n=/^\s*(case|default)\b/.test(e);return t.baseIndent+(i?0:n?1:2)*t.unit},Block:Ni({closing:"}"}),ArrowFunction:t=>t.baseIndent+t.unit,"TemplateString BlockComment":()=>null,"Statement Property":Le({except:/^\s*{/}),JSXElement(t){let e=/^\s*<\//.test(t.textAfter);return t.lineIndent(t.node.from)+(e?0:t.unit)},JSXEscape(t){let e=/\s*\}/.test(t.textAfter);return t.lineIndent(t.node.from)+(e?0:t.unit)},"JSXOpenTag JSXSelfClosingTag"(t){return t.column(t.node.from)+t.unit}}),ct.add({"Block ClassBody SwitchBody EnumBody ObjectExpression ArrayExpression ObjectType":Ri,BlockComment(t){return{from:t.from+2,to:t.to-2}},JSXElement(t){let e=t.firstChild;if(!e||e.name=="JSXSelfClosingTag")return null;let i=t.lastChild;return{from:e.to,to:i.type.isError?t.to:i.from}},"JSXSelfClosingTag JSXOpenTag"(t){var e;let i=(e=t.firstChild)===null||e===void 0?void 0:e.nextSibling,n=t.lastChild;return!i||i.type.isError?null:{from:i.to,to:n.type.isError?t.to:n.from}}})]}),languageData:{closeBrackets:{brackets:["(","[","{","'",'"',"`"]},commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\}|<\/)$/,wordChars:"$"}}),RS={test:t=>/^JSX/.test(t.name),facet:ua({commentTokens:{block:{open:"{/*",close:"*/}"}}})},ZS=Vi.configure({dialect:"ts"},"typescript"),YS=Vi.configure({dialect:"jsx",props:[Eh.add(t=>t.isTop?[RS]:void 0)]}),zS=Vi.configure({dialect:"jsx ts",props:[Eh.add(t=>t.isTop?[RS]:void 0)]},"typescript");let VS=t=>({label:t,type:"keyword"});const qS="break case const continue default delete export extends false finally in instanceof let new return static super switch this throw true typeof var yield".split(" ").map(VS),nU=qS.concat(["declare","implements","private","protected","public"].map(VS));function Ma(t={}){let e=t.jsx?t.typescript?zS:YS:t.typescript?ZS:Vi,i=t.typescript?Jq.concat(nU):xS.concat(qS);return new Fe(e,[Vi.data.of({autocomplete:md(_S,Ya(i))}),Vi.data.of({autocomplete:iU}),t.jsx?sU:[]])}function OU(t){for(;;){if(t.name=="JSXOpenTag"||t.name=="JSXSelfClosingTag"||t.name=="JSXFragmentTag")return t;if(t.name=="JSXEscape"||!t.parent)return null;t=t.parent}}function US(t,e,i=t.length){for(let n=e?.firstChild;n;n=n.nextSibling)if(n.name=="JSXIdentifier"||n.name=="JSXBuiltin"||n.name=="JSXNamespacedName"||n.name=="JSXMemberExpression")return t.sliceString(n.from,Math.min(n.to,i));return""}const rU=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent),sU=R.inputHandler.of((t,e,i,n,O)=>{if((rU?t.composing:t.compositionStarted)||t.state.readOnly||e!=i||n!=">"&&n!="/"||!Vi.isActiveAt(t.state,e,-1))return!1;let r=O(),{state:s}=r,o=s.changeByRange(a=>{var l;let{head:c}=a,h=$e(s).resolveInner(c-1,-1),d;if(h.name=="JSXStartTag"&&(h=h.parent),!(s.doc.sliceString(c-1,c)!=n||h.name=="JSXAttributeValue"&&h.to>c)){if(n==">"&&h.name=="JSXFragmentTag")return{range:a,changes:{from:c,insert:""}};if(n=="/"&&h.name=="JSXStartCloseTag"){let u=h.parent,$=u.parent;if($&&u.from==c-2&&((d=US(s.doc,$.firstChild,c))||((l=$.firstChild)===null||l===void 0?void 0:l.name)=="JSXFragmentTag")){let Q=`${d}>`;return{range:x.cursor(c+Q.length,-1),changes:{from:c,insert:Q}}}}else if(n==">"){let u=OU(h);if(u&&u.name=="JSXOpenTag"&&!/^\/?>|^<\//.test(s.doc.sliceString(c,c+2))&&(d=US(s.doc,u,c)))return{range:a,changes:{from:c,insert:``}}}}return{range:a}});return o.changes.empty?!1:(t.dispatch([r,s.update(o,{userEvent:"input.complete",scrollIntoView:!0})]),!0)}),fs=["_blank","_self","_top","_parent"],Ld=["ascii","utf-8","utf-16","latin1","latin1"],Nd=["get","post","put","delete"],Bd=["application/x-www-form-urlencoded","multipart/form-data","text/plain"],Et=["true","false"],E={},oU={a:{attrs:{href:null,ping:null,type:null,media:null,target:fs,hreflang:null}},abbr:E,address:E,area:{attrs:{alt:null,coords:null,href:null,target:null,ping:null,media:null,hreflang:null,type:null,shape:["default","rect","circle","poly"]}},article:E,aside:E,audio:{attrs:{src:null,mediagroup:null,crossorigin:["anonymous","use-credentials"],preload:["none","metadata","auto"],autoplay:["autoplay"],loop:["loop"],controls:["controls"]}},b:E,base:{attrs:{href:null,target:fs}},bdi:E,bdo:E,blockquote:{attrs:{cite:null}},body:E,br:E,button:{attrs:{form:null,formaction:null,name:null,value:null,autofocus:["autofocus"],disabled:["autofocus"],formenctype:Bd,formmethod:Nd,formnovalidate:["novalidate"],formtarget:fs,type:["submit","reset","button"]}},canvas:{attrs:{width:null,height:null}},caption:E,center:E,cite:E,code:E,col:{attrs:{span:null}},colgroup:{attrs:{span:null}},command:{attrs:{type:["command","checkbox","radio"],label:null,icon:null,radiogroup:null,command:null,title:null,disabled:["disabled"],checked:["checked"]}},data:{attrs:{value:null}},datagrid:{attrs:{disabled:["disabled"],multiple:["multiple"]}},datalist:{attrs:{data:null}},dd:E,del:{attrs:{cite:null,datetime:null}},details:{attrs:{open:["open"]}},dfn:E,div:E,dl:E,dt:E,em:E,embed:{attrs:{src:null,type:null,width:null,height:null}},eventsource:{attrs:{src:null}},fieldset:{attrs:{disabled:["disabled"],form:null,name:null}},figcaption:E,figure:E,footer:E,form:{attrs:{action:null,name:null,"accept-charset":Ld,autocomplete:["on","off"],enctype:Bd,method:Nd,novalidate:["novalidate"],target:fs}},h1:E,h2:E,h3:E,h4:E,h5:E,h6:E,head:{children:["title","base","link","style","meta","script","noscript","command"]},header:E,hgroup:E,hr:E,html:{attrs:{manifest:null}},i:E,iframe:{attrs:{src:null,srcdoc:null,name:null,width:null,height:null,sandbox:["allow-top-navigation","allow-same-origin","allow-forms","allow-scripts"],seamless:["seamless"]}},img:{attrs:{alt:null,src:null,ismap:null,usemap:null,width:null,height:null,crossorigin:["anonymous","use-credentials"]}},input:{attrs:{alt:null,dirname:null,form:null,formaction:null,height:null,list:null,max:null,maxlength:null,min:null,name:null,pattern:null,placeholder:null,size:null,src:null,step:null,value:null,width:null,accept:["audio/*","video/*","image/*"],autocomplete:["on","off"],autofocus:["autofocus"],checked:["checked"],disabled:["disabled"],formenctype:Bd,formmethod:Nd,formnovalidate:["novalidate"],formtarget:fs,multiple:["multiple"],readonly:["readonly"],required:["required"],type:["hidden","text","search","tel","url","email","password","datetime","date","month","week","time","datetime-local","number","range","color","checkbox","radio","file","submit","image","reset","button"]}},ins:{attrs:{cite:null,datetime:null}},kbd:E,keygen:{attrs:{challenge:null,form:null,name:null,autofocus:["autofocus"],disabled:["disabled"],keytype:["RSA"]}},label:{attrs:{for:null,form:null}},legend:E,li:{attrs:{value:null}},link:{attrs:{href:null,type:null,hreflang:null,media:null,sizes:["all","16x16","16x16 32x32","16x16 32x32 64x64"]}},map:{attrs:{name:null}},mark:E,menu:{attrs:{label:null,type:["list","context","toolbar"]}},meta:{attrs:{content:null,charset:Ld,name:["viewport","application-name","author","description","generator","keywords"],"http-equiv":["content-language","content-type","default-style","refresh"]}},meter:{attrs:{value:null,min:null,low:null,high:null,max:null,optimum:null}},nav:E,noscript:E,object:{attrs:{data:null,type:null,name:null,usemap:null,form:null,width:null,height:null,typemustmatch:["typemustmatch"]}},ol:{attrs:{reversed:["reversed"],start:null,type:["1","a","A","i","I"]},children:["li","script","template","ul","ol"]},optgroup:{attrs:{disabled:["disabled"],label:null}},option:{attrs:{disabled:["disabled"],label:null,selected:["selected"],value:null}},output:{attrs:{for:null,form:null,name:null}},p:E,param:{attrs:{name:null,value:null}},pre:E,progress:{attrs:{value:null,max:null}},q:{attrs:{cite:null}},rp:E,rt:E,ruby:E,samp:E,script:{attrs:{type:["text/javascript"],src:null,async:["async"],defer:["defer"],charset:Ld}},section:E,select:{attrs:{form:null,name:null,size:null,autofocus:["autofocus"],disabled:["disabled"],multiple:["multiple"]}},slot:{attrs:{name:null}},small:E,source:{attrs:{src:null,type:null,media:null}},span:E,strong:E,style:{attrs:{type:["text/css"],media:null,scoped:null}},sub:E,summary:E,sup:E,table:E,tbody:E,td:{attrs:{colspan:null,rowspan:null,headers:null}},template:E,textarea:{attrs:{dirname:null,form:null,maxlength:null,name:null,placeholder:null,rows:null,cols:null,autofocus:["autofocus"],disabled:["disabled"],readonly:["readonly"],required:["required"],wrap:["soft","hard"]}},tfoot:E,th:{attrs:{colspan:null,rowspan:null,headers:null,scope:["row","col","rowgroup","colgroup"]}},thead:E,time:{attrs:{datetime:null}},title:E,tr:E,track:{attrs:{src:null,label:null,default:null,kind:["subtitles","captions","descriptions","chapters","metadata"],srclang:null}},ul:{children:["li","script","template","ul","ol"]},var:E,video:{attrs:{src:null,poster:null,width:null,height:null,crossorigin:["anonymous","use-credentials"],preload:["auto","metadata","none"],autoplay:["autoplay"],mediagroup:["movie"],muted:["muted"],controls:["controls"]}},wbr:E},WS={accesskey:null,class:null,contenteditable:Et,contextmenu:null,dir:["ltr","rtl","auto"],draggable:["true","false","auto"],dropzone:["copy","move","link","string:","file:"],hidden:["hidden"],id:null,inert:["inert"],itemid:null,itemprop:null,itemref:null,itemscope:["itemscope"],itemtype:null,lang:["ar","bn","de","en-GB","en-US","es","fr","hi","id","ja","pa","pt","ru","tr","zh"],spellcheck:Et,autocorrect:Et,autocapitalize:Et,style:null,tabindex:null,title:null,translate:["yes","no"],rel:["stylesheet","alternate","author","bookmark","help","license","next","nofollow","noreferrer","prefetch","prev","search","tag"],role:"alert application article banner button cell checkbox complementary contentinfo dialog document feed figure form grid gridcell heading img list listbox listitem main navigation region row rowgroup search switch tab table tabpanel textbox timer".split(" "),"aria-activedescendant":null,"aria-atomic":Et,"aria-autocomplete":["inline","list","both","none"],"aria-busy":Et,"aria-checked":["true","false","mixed","undefined"],"aria-controls":null,"aria-describedby":null,"aria-disabled":Et,"aria-dropeffect":null,"aria-expanded":["true","false","undefined"],"aria-flowto":null,"aria-grabbed":["true","false","undefined"],"aria-haspopup":Et,"aria-hidden":Et,"aria-invalid":["true","false","grammar","spelling"],"aria-label":null,"aria-labelledby":null,"aria-level":null,"aria-live":["off","polite","assertive"],"aria-multiline":Et,"aria-multiselectable":Et,"aria-owns":null,"aria-posinset":null,"aria-pressed":["true","false","mixed","undefined"],"aria-readonly":Et,"aria-relevant":null,"aria-required":Et,"aria-selected":["true","false","undefined"],"aria-setsize":null,"aria-sort":["ascending","descending","none","other"],"aria-valuemax":null,"aria-valuemin":null,"aria-valuenow":null,"aria-valuetext":null},CS="beforeunload copy cut dragstart dragover dragleave dragenter dragend drag paste focus blur change click load mousedown mouseenter mouseleave mouseup keydown keyup resize scroll unload".split(" ").map(t=>"on"+t);for(let t of CS)WS[t]=null;class $s{constructor(e,i){this.tags={...oU,...e},this.globalAttrs={...WS,...i},this.allTags=Object.keys(this.tags),this.globalAttrNames=Object.keys(this.globalAttrs)}}$s.default=new $s;function MO(t,e,i=t.length){if(!e)return"";let n=e.firstChild,O=n&&n.getChild("TagName");return O?t.sliceString(O.from,Math.min(O.to,i)):""}function DO(t,e=!1){for(;t;t=t.parent)if(t.name=="Element")if(e)e=!1;else return t;return null}function jS(t,e,i){let n=i.tags[MO(t,DO(e))];return n?.children||i.allTags}function Fd(t,e){let i=[];for(let n=DO(e);n&&!n.type.isTop;n=DO(n.parent)){let O=MO(t,n);if(O&&n.lastChild.name=="CloseTag")break;O&&i.indexOf(O)<0&&(e.name=="EndTag"||e.from>=n.firstChild.to)&&i.push(O)}return i}const GS=/^[:\-\.\w\u00b7-\uffff]*$/;function ES(t,e,i,n,O){let r=/\s*>/.test(t.sliceDoc(O,O+5))?"":">",s=DO(i,i.name=="StartTag"||i.name=="TagName");return{from:n,to:O,options:jS(t.doc,s,e).map(o=>({label:o,type:"type"})).concat(Fd(t.doc,i).map((o,a)=>({label:"/"+o,apply:"/"+o+r,type:"type",boost:99-a}))),validFor:/^\/?[:\-\.\w\u00b7-\uffff]*$/}}function IS(t,e,i,n){let O=/\s*>/.test(t.sliceDoc(n,n+5))?"":">";return{from:i,to:n,options:Fd(t.doc,e).map((r,s)=>({label:r,apply:r+O,type:"type",boost:99-s})),validFor:GS}}function aU(t,e,i,n){let O=[],r=0;for(let s of jS(t.doc,i,e))O.push({label:"<"+s,type:"type"});for(let s of Fd(t.doc,i))O.push({label:"",type:"type",boost:99-r++});return{from:n,to:n,options:O,validFor:/^<\/?[:\-\.\w\u00b7-\uffff]*$/}}function lU(t,e,i,n,O){let r=DO(i),s=r?e.tags[MO(t.doc,r)]:null,o=s&&s.attrs?Object.keys(s.attrs):[],a=s&&s.globalAttrs===!1?o:o.length?o.concat(e.globalAttrNames):e.globalAttrNames;return{from:n,to:O,options:a.map(l=>({label:l,type:"property"})),validFor:GS}}function cU(t,e,i,n,O){var r;let s=(r=i.parent)===null||r===void 0?void 0:r.getChild("AttributeName"),o=[],a;if(s){let l=t.sliceDoc(s.from,s.to),c=e.globalAttrs[l];if(!c){let h=DO(i),d=h?e.tags[MO(t.doc,h)]:null;c=d?.attrs&&d.attrs[l]}if(c){let h=t.sliceDoc(n,O).toLowerCase(),d='"',u='"';/^['"]/.test(h)?(a=h[0]=='"'?/^[^"]*$/:/^[^']*$/,d="",u=t.sliceDoc(O,O+1)==h[0]?"":h[0],h=h.slice(1),n++):a=/^[^\s<>='"]*$/;for(let $ of c)o.push({label:$,apply:d+$+u,type:"constant"})}}return{from:n,to:O,options:o,validFor:a}}function AS(t,e){let{state:i,pos:n}=e,O=$e(i).resolveInner(n,-1),r=O.resolve(n);for(let s=n,o;r==O&&(o=O.childBefore(s));){let a=o.lastChild;if(!a||!a.type.isError||a.fromAS(n,O)}const uU=Vi.parser.configure({top:"SingleExpression"}),MS=[{tag:"script",attrs:t=>t.type=="text/typescript"||t.lang=="ts",parser:ZS.parser},{tag:"script",attrs:t=>t.type=="text/babel"||t.type=="text/jsx",parser:YS.parser},{tag:"script",attrs:t=>t.type=="text/typescript-jsx",parser:zS.parser},{tag:"script",attrs(t){return/^(importmap|speculationrules|application\/(.+\+)?json)$/i.test(t.type)},parser:uU},{tag:"script",attrs(t){return!t.type||/^(?:text|application)\/(?:x-)?(?:java|ecma)script$|^module$|^$/i.test(t.type)},parser:Vi.parser},{tag:"style",attrs(t){return(!t.lang||t.lang=="css")&&(!t.type||/^(text\/)?(x-)?(stylesheet|css)$/i.test(t.type))},parser:Ia.parser}],DS=[{name:"style",parser:Ia.parser.configure({top:"Styles"})}].concat(CS.map(t=>({name:t,parser:Vi.parser}))),LS=at.define({name:"html",parser:Sq.configure({props:[lt.add({Element(t){let e=/^(\s*)(<\/)?/.exec(t.textAfter);return t.node.to<=t.pos+e[0].length?t.continue():t.lineIndent(t.node.from)+(e[2]?0:t.unit)},"OpenTag CloseTag SelfClosingTag"(t){return t.column(t.node.from)+t.unit},Document(t){if(t.pos+/\s*/.exec(t.textAfter)[0].lengtht.getChild("TagName")})]}),languageData:{commentTokens:{block:{open:""}},indentOnInput:/^\s*<\/\w+\W$/,wordChars:"-_"}}),Da=LS.configure({wrap:XS(MS,DS)});function Hd(t={}){let e="",i;t.matchClosingTags===!1&&(e="noMatch"),t.selfClosingTags===!0&&(e=(e?e+" ":"")+"selfClosing"),(t.nestedLanguages&&t.nestedLanguages.length||t.nestedAttributes&&t.nestedAttributes.length)&&(i=XS((t.nestedLanguages||[]).concat(MS),(t.nestedAttributes||[]).concat(DS)));let n=i?LS.configure({wrap:i,dialect:e}):e?Da.configure({dialect:e}):Da;return new Fe(n,[Da.data.of({autocomplete:dU(t)}),t.autoCloseTags!==!1?fU:[],Ma().support,OS().support])}const NS=new Set("area base br col command embed frame hr img input keygen link meta param source track wbr menuitem".split(" ")),fU=R.inputHandler.of((t,e,i,n,O)=>{if(t.composing||t.state.readOnly||e!=i||n!=">"&&n!="/"||!Da.isActiveAt(t.state,e,-1))return!1;let r=O(),{state:s}=r,o=s.changeByRange(a=>{var l,c,h;let d=s.doc.sliceString(a.from-1,a.to)==n,{head:u}=a,$=$e(s).resolveInner(u,-1),Q;if(d&&n==">"&&$.name=="EndTag"){let p=$.parent;if(((c=(l=p.parent)===null||l===void 0?void 0:l.lastChild)===null||c===void 0?void 0:c.name)!="CloseTag"&&(Q=MO(s.doc,p.parent,u))&&!NS.has(Q)){let m=u+(s.doc.sliceString(u,u+1)===">"?1:0),P=``;return{range:a,changes:{from:u,to:m,insert:P}}}}else if(d&&n=="/"&&$.name=="IncompleteCloseTag"){let p=$.parent;if($.from==u-2&&((h=p.lastChild)===null||h===void 0?void 0:h.name)!="CloseTag"&&(Q=MO(s.doc,p,u))&&!NS.has(Q)){let m=u+(s.doc.sliceString(u,u+1)===">"?1:0),P=`${Q}>`;return{range:x.cursor(u+P.length,-1),changes:{from:u,to:m,insert:P}}}}return{range:a}});return o.changes.empty?!1:(t.dispatch([r,s.update(o,{userEvent:"input.complete",scrollIntoView:!0})]),!0)}),$U=ot({null:f.null,instanceof:f.operatorKeyword,this:f.self,"new super assert open to with void":f.keyword,"class interface extends implements enum var":f.definitionKeyword,"module package import":f.moduleKeyword,"switch while for if else case default do break continue return try catch finally throw":f.controlKeyword,"requires exports opens uses provides public private protected static transitive abstract final strictfp synchronized native transient volatile throws":f.modifier,IntegerLiteral:f.integer,FloatingPointLiteral:f.float,"StringLiteral TextBlock":f.string,CharacterLiteral:f.character,LineComment:f.lineComment,BlockComment:f.blockComment,BooleanLiteral:f.bool,PrimitiveType:f.standard(f.typeName),TypeName:f.typeName,Identifier:f.variableName,"MethodName/Identifier":f.function(f.variableName),Definition:f.definition(f.variableName),ArithOp:f.arithmeticOperator,LogicOp:f.logicOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,AssignOp:f.definitionOperator,UpdateOp:f.updateOperator,Asterisk:f.punctuation,Label:f.labelName,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace,".":f.derefOperator,", ;":f.separator}),QU={__proto__:null,true:34,false:34,null:42,void:46,byte:48,short:48,int:48,long:48,char:48,float:48,double:48,boolean:48,extends:62,super:64,class:76,this:78,new:84,public:100,protected:102,private:104,abstract:106,static:108,final:110,strictfp:112,default:114,synchronized:116,native:118,transient:120,volatile:122,throws:150,implements:160,interface:166,enum:176,instanceof:238,open:267,module:269,requires:274,transitive:276,exports:278,to:280,opens:282,uses:284,provides:286,with:288,package:292,import:296,if:308,else:310,while:314,for:318,var:325,assert:332,switch:336,case:342,do:346,break:350,continue:354,return:358,throw:364,try:368,catch:372,finally:380},pU=ht.deserialize({version:14,states:"##jQ]QPOOQ$wQPOOO(bQQO'#H^O*iQQO'#CbOOQO'#Cb'#CbO*pQPO'#CaO*xOSO'#CpOOQO'#Hc'#HcOOQO'#Cu'#CuO,eQPO'#D_O-OQQO'#HmOOQO'#Hm'#HmO/gQQO'#HhO/nQQO'#HhOOQO'#Hh'#HhOOQO'#Hg'#HgO1rQPO'#DUO2PQPO'#GnO4wQPO'#D_O5OQPO'#DzO*pQPO'#E[O5qQPO'#E[OOQO'#DV'#DVO7SQQO'#HaO9^QQO'#EeO9eQPO'#EdO9jQPO'#EfOOQO'#Hb'#HbO7jQQO'#HbO:pQQO'#FhO:wQPO'#ExO:|QPO'#E}O:|QPO'#FPOOQO'#Ha'#HaOOQO'#HY'#HYOOQO'#Gh'#GhOOQO'#HX'#HXO<^QPO'#FiOOQO'#HW'#HWOOQO'#Gg'#GgQ]QPOOOOQO'#Hs'#HsOQQPO'#GSO>]QPO'#GUO=kQPO'#GWO:|QPO'#GXO>dQPO'#GZO?QQQO'#HiO?mQQO'#CuO?tQPO'#HxO@SQPO'#D_O@rQPO'#DpO?wQPO'#DqO@|QPO'#HxOA_QPO'#DpOA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cx![!f!o!y#_#e#l$_$m$n$o$p$q%O%b%d&]&i'^'e'h'{(U)O)Q)R*W*q+O+d+l+s+x,Y-[-^.R/O/dU#WY!W'|Q%T!eU&k#n#s+fQ(o%VS,s*T*zT.s,u-aj#UY!W!e#n#s%V%w&W)y*T*z,u-aU&V#`&`(}Q)x&[Q+e'|Q+q(`Q-s+fQ.O+rQ/g.WR0U/hQ)i%vQ,g)fR/o.mR,h)f`!jP!o'^'h*q+O-^/OT%W!g*|R%]!hW%U!e%V*z-aQ(z%^R,V({S#d`%bR&a#eQ)X%gT*t'`'iR*y'e[!lP!o'^*q-^/OR%X!gR#h`R,b)]R)a%kT-j+]-kQ/V-mR/z/WR/z/X",nodeNames:"⚠ LineComment BlockComment Program ModuleDeclaration MarkerAnnotation Identifier ScopedIdentifier . Annotation ) ( AnnotationArgumentList AssignmentExpression FieldAccess IntegerLiteral FloatingPointLiteral BooleanLiteral CharacterLiteral StringLiteral TextBlock null ClassLiteral void PrimitiveType TypeName ScopedTypeName GenericType TypeArguments AnnotatedType Wildcard extends super , ArrayType ] Dimension [ class this ParenthesizedExpression ObjectCreationExpression new ArgumentList } { ClassBody ; FieldDeclaration Modifiers public protected private abstract static final strictfp default synchronized native transient volatile VariableDeclarator Definition AssignOp ArrayInitializer MethodDeclaration TypeParameters TypeParameter TypeBound FormalParameters ReceiverParameter FormalParameter SpreadParameter Throws throws Block ClassDeclaration Superclass SuperInterfaces implements InterfaceTypeList InterfaceDeclaration interface ExtendsInterfaces InterfaceBody ConstantDeclaration EnumDeclaration enum EnumBody EnumConstant EnumBodyDeclarations AnnotationTypeDeclaration AnnotationTypeBody AnnotationTypeElementDeclaration StaticInitializer ConstructorDeclaration ConstructorBody ExplicitConstructorInvocation ArrayAccess MethodInvocation MethodName MethodReference ArrayCreationExpression Dimension AssignOp BinaryExpression CompareOp CompareOp LogicOp LogicOp BitOp BitOp BitOp ArithOp ArithOp ArithOp BitOp InstanceofExpression instanceof LambdaExpression InferredParameters TernaryExpression LogicOp : UpdateExpression UpdateOp UnaryExpression LogicOp BitOp CastExpression ElementValueArrayInitializer ElementValuePair open module ModuleBody ModuleDirective requires transitive exports to opens uses provides with PackageDeclaration package ImportDeclaration import Asterisk ExpressionStatement LabeledStatement Label IfStatement if else WhileStatement while ForStatement for ForSpec LocalVariableDeclaration var EnhancedForStatement ForSpec AssertStatement assert SwitchStatement switch SwitchBlock SwitchLabel case DoStatement do BreakStatement break ContinueStatement continue ReturnStatement return SynchronizedStatement ThrowStatement throw TryStatement try CatchClause catch CatchFormalParameter CatchType FinallyClause finally TryWithResourcesStatement ResourceSpecification Resource ClassContent",maxTerm:276,nodeProps:[["isolate",-4,1,2,18,19,""],["group",-26,4,47,76,77,82,87,92,145,147,150,151,153,156,158,161,163,165,167,172,174,176,178,180,181,183,191,"Statement",-25,6,13,14,15,16,17,18,19,20,21,22,39,40,41,99,100,102,103,106,118,120,122,125,127,130,"Expression",-7,23,24,25,26,27,29,34,"Type"],["openedBy",10,"(",44,"{"],["closedBy",11,")",45,"}"]],propSources:[$U],skippedNodes:[0,1,2],repeatNodeCount:28,tokenData:"#'f_R!_OX%QXY'fYZ)bZ^'f^p%Qpq'fqr*|rs,^st%Qtu4euv5zvw7[wx8rxyAZyzAwz{Be{|CZ|}Dq}!OE_!O!PFx!P!Q! r!Q!R!,h!R![!0`![!]!>p!]!^!@Q!^!_!@n!_!`!BX!`!a!B{!a!b!Di!b!c!EX!c!}!LT!}#O!Mj#O#P%Q#P#Q!NW#Q#R!Nt#R#S4e#S#T%Q#T#o4e#o#p# h#p#q#!U#q#r##n#r#s#$[#s#y%Q#y#z'f#z$f%Q$f$g'f$g#BY4e#BY#BZ#$x#BZ$IS4e$IS$I_#$x$I_$I|4e$I|$JO#$x$JO$JT4e$JT$JU#$x$JU$KV4e$KV$KW#$x$KW&FU4e&FU&FV#$x&FV;'S4e;'S;=`5t<%lO4eS%VV&YSOY%QYZ%lZr%Qrs%qs;'S%Q;'S;=`&s<%lO%QS%qO&YS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;'S;=`&s<%lO%QV##uV|R&YSOY%QYZ%lZr%Qrs%qs;'S%Q;'S;=`&s<%lO%QT#$cV#uP&YSOY%QYZ%lZr%Qrs%qs;'S%Q;'S;=`&s<%lO%Q_#%Ru&YS%yZ&PZOX%QXY'fYZ)bZ^'f^p%Qpq'fqr%Qrs%qst%Qtu4eu!Q%Q!Q![4e![!c%Q!c!}4e!}#R%Q#R#S4e#S#T%Q#T#o4e#o#y%Q#y#z'f#z$f%Q$f$g'f$g#BY4e#BY#BZ#$x#BZ$IS4e$IS$I_#$x$I_$I|4e$I|$JO#$x$JO$JT4e$JT$JU#$x$JU$KV4e$KV$KW#$x$KW&FU4e&FU&FV#$x&FV;'S4e;'S;=`5t<%lO4e",tokenizers:[0,1,2,3],topRules:{Program:[0,3],ClassContent:[1,194]},dynamicPrecedences:{27:1,232:-1,243:-1},specialized:[{term:231,get:t=>QU[t]||-1}],tokenPrec:7144}),mU=at.define({name:"java",parser:pU.configure({props:[lt.add({IfStatement:Le({except:/^\s*({|else\b)/}),TryStatement:Le({except:/^\s*({|catch|finally)\b/}),LabeledStatement:Dh,SwitchBlock:t=>{let e=t.textAfter,i=/^\s*\}/.test(e),n=/^\s*(case|default)\b/.test(e);return t.baseIndent+(i?0:n?1:2)*t.unit},Block:Ni({closing:"}"}),BlockComment:()=>null,Statement:Le({except:/^{/})}),ct.add({"Block SwitchBlock ClassBody ElementValueArrayInitializer ModuleBody EnumBody ConstructorBody InterfaceBody ArrayInitializer":Ri,BlockComment(t){return{from:t.from+2,to:t.to-2}}})]}),languageData:{commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\})$/}});function gU(){return new Fe(mU)}const PU=ot({String:f.string,Number:f.number,"True False":f.bool,PropertyName:f.propertyName,Null:f.null,", :":f.separator,"[ ]":f.squareBracket,"{ }":f.brace}),SU=ht.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:"#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O",goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"⚠ JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",14,"["],["closedBy",8,"}",15,"]"]],propSources:[PU],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0}),XU=at.define({name:"json",parser:SU.configure({props:[lt.add({Object:Le({except:/^\s*\}/}),Array:Le({except:/^\s*\]/})}),ct.add({"Object Array":Ri})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});function bU(){return new Fe(XU)}class La{static create(e,i,n,O,r){let s=O+(O<<8)+e+(i<<4)|0;return new La(e,i,n,s,r,[],[])}constructor(e,i,n,O,r,s,o){this.type=e,this.value=i,this.from=n,this.hash=O,this.end=r,this.children=s,this.positions=o,this.hashProp=[[F.contextHash,O]]}addChild(e,i){e.prop(F.contextHash)!=this.hash&&(e=new ne(e.type,e.children,e.positions,e.length,this.hashProp)),this.children.push(e),this.positions.push(i)}toTree(e,i=this.end){let n=this.children.length-1;return n>=0&&(i=Math.max(i,this.positions[n]+this.children[n].length+this.from)),new ne(e.types[this.type],this.children,this.positions,i-this.from).balance({makeTree:(O,r,s)=>new ne(Ee.none,O,r,s,this.hashProp)})}}var v;(function(t){t[t.Document=1]="Document",t[t.CodeBlock=2]="CodeBlock",t[t.FencedCode=3]="FencedCode",t[t.Blockquote=4]="Blockquote",t[t.HorizontalRule=5]="HorizontalRule",t[t.BulletList=6]="BulletList",t[t.OrderedList=7]="OrderedList",t[t.ListItem=8]="ListItem",t[t.ATXHeading1=9]="ATXHeading1",t[t.ATXHeading2=10]="ATXHeading2",t[t.ATXHeading3=11]="ATXHeading3",t[t.ATXHeading4=12]="ATXHeading4",t[t.ATXHeading5=13]="ATXHeading5",t[t.ATXHeading6=14]="ATXHeading6",t[t.SetextHeading1=15]="SetextHeading1",t[t.SetextHeading2=16]="SetextHeading2",t[t.HTMLBlock=17]="HTMLBlock",t[t.LinkReference=18]="LinkReference",t[t.Paragraph=19]="Paragraph",t[t.CommentBlock=20]="CommentBlock",t[t.ProcessingInstructionBlock=21]="ProcessingInstructionBlock",t[t.Escape=22]="Escape",t[t.Entity=23]="Entity",t[t.HardBreak=24]="HardBreak",t[t.Emphasis=25]="Emphasis",t[t.StrongEmphasis=26]="StrongEmphasis",t[t.Link=27]="Link",t[t.Image=28]="Image",t[t.InlineCode=29]="InlineCode",t[t.HTMLTag=30]="HTMLTag",t[t.Comment=31]="Comment",t[t.ProcessingInstruction=32]="ProcessingInstruction",t[t.Autolink=33]="Autolink",t[t.HeaderMark=34]="HeaderMark",t[t.QuoteMark=35]="QuoteMark",t[t.ListMark=36]="ListMark",t[t.LinkMark=37]="LinkMark",t[t.EmphasisMark=38]="EmphasisMark",t[t.CodeMark=39]="CodeMark",t[t.CodeText=40]="CodeText",t[t.CodeInfo=41]="CodeInfo",t[t.LinkTitle=42]="LinkTitle",t[t.LinkLabel=43]="LinkLabel",t[t.URL=44]="URL"})(v||(v={}));class yU{constructor(e,i){this.start=e,this.content=i,this.marks=[],this.parsers=[]}}class xU{constructor(){this.text="",this.baseIndent=0,this.basePos=0,this.depth=0,this.markers=[],this.pos=0,this.indent=0,this.next=-1}forward(){this.basePos>this.pos&&this.forwardInner()}forwardInner(){let e=this.skipSpace(this.basePos);this.indent=this.countIndent(e,this.pos,this.indent),this.pos=e,this.next=e==this.text.length?-1:this.text.charCodeAt(e)}skipSpace(e){return Qs(this.text,e)}reset(e){for(this.text=e,this.baseIndent=this.basePos=this.pos=this.indent=0,this.forwardInner(),this.depth=1;this.markers.length;)this.markers.pop()}moveBase(e){this.basePos=e,this.baseIndent=this.countIndent(e,this.pos,this.indent)}moveBaseColumn(e){this.baseIndent=e,this.basePos=this.findColumn(e)}addMarker(e){this.markers.push(e)}countIndent(e,i=0,n=0){for(let O=i;O=e.stack[i.depth+1].value+i.baseIndent)return!0;if(i.indent>=i.baseIndent+4)return!1;let n=(t.type==v.OrderedList?eu:Jd)(i,e,!1);return n>0&&(t.type!=v.BulletList||Kd(i,e,!1)<0)&&i.text.charCodeAt(i.pos+n-1)==t.value}const FS={[v.Blockquote](t,e,i){return i.next!=62?!1:(i.markers.push(ce(v.QuoteMark,e.lineStart+i.pos,e.lineStart+i.pos+1)),i.moveBase(i.pos+(Kt(i.text.charCodeAt(i.pos+1))?2:1)),t.end=e.lineStart+i.text.length,!0)},[v.ListItem](t,e,i){return i.indent-1?!1:(i.moveBaseColumn(i.baseIndent+t.value),!0)},[v.OrderedList]:BS,[v.BulletList]:BS,[v.Document](){return!0}};function Kt(t){return t==32||t==9||t==10||t==13}function Qs(t,e=0){for(;ei&&Kt(t.charCodeAt(e-1));)e--;return e}function KS(t){if(t.next!=96&&t.next!=126)return-1;let e=t.pos+1;for(;e-1&&t.depth==e.stack.length&&e.parser.leafBlockParsers.indexOf(o0.SetextHeading)>-1||n<3?-1:1}function e0(t,e){for(let i=t.stack.length-1;i>=0;i--)if(t.stack[i].type==e)return!0;return!1}function Jd(t,e,i){return(t.next==45||t.next==43||t.next==42)&&(t.pos==t.text.length-1||Kt(t.text.charCodeAt(t.pos+1)))&&(!i||e0(e,v.BulletList)||t.skipSpace(t.pos+2)=48&&O<=57;){n++;if(n==t.text.length)return-1;O=t.text.charCodeAt(n)}return n==t.pos||n>t.pos+9||O!=46&&O!=41||nt.pos+1||t.next!=49)?-1:n+1-t.pos}function t0(t){if(t.next!=35)return-1;let e=t.pos+1;for(;e6?-1:i}function i0(t){if(t.next!=45&&t.next!=61||t.indent>=t.baseIndent+4)return-1;let e=t.pos+1;for(;e/,O0=/\?>/,iu=[[/^<(?:script|pre|style)(?:\s|>|$)/i,/<\/(?:script|pre|style)>/i],[/^\s*/i.exec(n);if(r)return t.append(ce(v.Comment,i,i+1+r[0].length));let s=/^\?[^]*?\?>/.exec(n);if(s)return t.append(ce(v.ProcessingInstruction,i,i+1+s[0].length));let o=/^(?:![A-Z][^]*?>|!\[CDATA\[[^]*?\]\]>|\/\s*[a-zA-Z][\w-]*\s*>|\s*[a-zA-Z][\w-]*(\s+[a-zA-Z:_][\w-.:]*(?:\s*=\s*(?:[^\s"'=<>`]+|'[^']*'|"[^"]*"))?)*\s*(\/\s*)?>)/.exec(n);return o?t.append(ce(v.HTMLTag,i,i+1+o[0].length)):-1},Emphasis(t,e,i){if(e!=95&&e!=42)return-1;let n=i+1;for(;t.char(n)==e;)n++;let O=t.slice(i-1,i),r=t.slice(n,n+1),s=gs.test(O),o=gs.test(r),a=/\s|^$/.test(O),l=/\s|^$/.test(r),c=!l&&(!o||a||s),h=!a&&(!s||l||o),d=c&&(e==42||!h||s),u=h&&(e==42||!c||o);return t.append(new It(e==95?d0:u0,i,n,(d?1:0)|(u?2:0)))},HardBreak(t,e,i){if(e==92&&t.char(i+1)==10)return t.append(ce(v.HardBreak,i,i+2));if(e==32){let n=i+1;for(;t.char(n)==32;)n++;if(t.char(n)==10&&n>=i+2)return t.append(ce(v.HardBreak,i,n+1))}return-1},Link(t,e,i){return e==91?t.append(new It(Fn,i,i+1,1)):-1},Image(t,e,i){return e==33&&t.char(i+1)==91?t.append(new It(Ha,i,i+2,1)):-1},LinkEnd(t,e,i){if(e!=93)return-1;for(let n=t.parts.length-1;n>=0;n--){let O=t.parts[n];if(O instanceof It&&(O.type==Fn||O.type==Ha)){if(!O.side||t.skipSpace(O.to)==i&&!/[(\[]/.test(t.slice(i+1,i+2)))return t.parts[n]=null,-1;let r=t.takeContent(n),s=t.parts[n]=RU(t,r,O.type==Fn?v.Link:v.Image,O.from,i+1);if(O.type==Fn)for(let o=0;oe?ce(v.URL,e+i,r+i):r==t.length?null:!1}}function Q0(t,e,i){let n=t.charCodeAt(e);if(n!=39&&n!=34&&n!=40)return!1;let O=n==40?41:n;for(let r=e+1,s=!1;r=this.end?-1:this.text.charCodeAt(e-this.offset)}get end(){return this.offset+this.text.length}slice(e,i){return this.text.slice(e-this.offset,i-this.offset)}append(e){return this.parts.push(e),e.to}addDelimiter(e,i,n,O,r){return this.append(new It(e,i,n,(O?1:0)|(r?2:0)))}get hasOpenLink(){for(let e=this.parts.length-1;e>=0;e--){let i=this.parts[e];if(i instanceof It&&(i.type==Fn||i.type==Ha))return!0}return!1}addElement(e){return this.append(e)}resolveMarkers(e){for(let n=e;n=e;a--){let Q=this.parts[a];if(Q instanceof It&&Q.side&1&&Q.type==O.type&&!(r&&(O.side&1||Q.side&2)&&(Q.to-Q.from+s)%3==0&&((Q.to-Q.from)%3||s%3))){o=Q;break}}if(!o)continue;let l=O.type.resolve,c=[],h=o.from,d=O.to;if(r){let Q=Math.min(2,o.to-o.from,s);h=o.to-Q,d=O.from+Q,l=Q==1?"Emphasis":"StrongEmphasis"}o.type.mark&&c.push(this.elt(o.type.mark,h,o.to));for(let Q=a+1;Q=0;i--){let n=this.parts[i];if(n instanceof It&&n.type==e&&n.side&1)return i}return null}takeContent(e){let i=this.resolveMarkers(e);return this.parts.length=e,i}getDelimiterAt(e){let i=this.parts[e];return i instanceof It?i:null}skipSpace(e){return Qs(this.text,e-this.offset)+this.offset}elt(e,i,n,O){return typeof e=="string"?ce(this.parser.getNodeType(e),i,n,O):new h0(e,i)}}su.linkStart=Fn,su.imageStart=Ha;function ou(t,e){if(!e.length)return t;if(!t.length)return e;let i=t.slice(),n=0;for(let O of e){for(;n(e?e-1:0))return!1;if(this.fragmentEnd<0){let r=this.fragment.to;for(;r>0&&this.input.read(r-1,r)!=` +`;)r--;this.fragmentEnd=r?r-1:0}let n=this.cursor;n||(n=this.cursor=this.fragment.tree.cursor(),n.firstChild());let O=e+this.fragment.offset;for(;n.to<=O;)if(!n.parent())return!1;for(;;){if(n.from>=O)return this.fragment.from<=i;if(!n.childAfter(O))return!1}}matches(e){let i=this.cursor.tree;return i&&i.prop(F.contextHash)==e}takeNodes(e){let i=this.cursor,n=this.fragment.offset,O=this.fragmentEnd-(this.fragment.openEnd?1:0),r=e.absoluteLineStart,s=r,o=e.block.children.length,a=s,l=o;for(;;){if(i.to-n>O){if(i.type.isAnonymous&&i.firstChild())continue;break}let c=m0(i.from-n,e.ranges);if(i.to-n<=e.ranges[e.rangeI].to)e.addNode(i.tree,c);else{let h=new ne(e.parser.nodeSet.types[v.Paragraph],[],[],0,e.block.hashProp);e.reusePlaceholders.set(h,i.tree),e.addNode(h,c)}if(i.type.is("Block")&&(ZU.indexOf(i.type.id)<0?(s=i.to-n,o=e.block.children.length):(s=a,o=l),a=i.to-n,l=e.block.children.length),!i.nextSibling())break}for(;e.block.children.length>o;)e.block.children.pop(),e.block.positions.pop();return s-r}}function m0(t,e){let i=t;for(let n=1;nNa[t]),Object.keys(Na).map(t=>o0[t]),Object.keys(Na),vU,FS,Object.keys(ru).map(t=>ru[t]),Object.keys(ru),[]);function qU(t,e,i){let n=[];for(let O=t.firstChild,r=e;;O=O.nextSibling){let s=O?O.from:i;if(s>r&&n.push({from:r,to:s}),!O)break;r=O.to}return n}function UU(t){let{codeParser:e,htmlParser:i}=t;return{wrap:aa((O,r)=>{let s=O.type.id;if(e&&(s==v.CodeBlock||s==v.FencedCode)){let o="";if(s==v.FencedCode){let l=O.node.getChild(v.CodeInfo);l&&(o=r.read(l.from,l.to))}let a=e(o);if(a)return{parser:a,overlay:l=>l.type.id==v.CodeText,bracketed:s==v.FencedCode}}else if(i&&(s==v.HTMLBlock||s==v.HTMLTag||s==v.CommentBlock))return{parser:i,overlay:qU(O.node,O.from,O.to)};return null})}}const WU={resolve:"Strikethrough",mark:"StrikethroughMark"},CU={defineNodes:[{name:"Strikethrough",style:{"Strikethrough/...":f.strikethrough}},{name:"StrikethroughMark",style:f.processingInstruction}],parseInline:[{name:"Strikethrough",parse(t,e,i){if(e!=126||t.char(i+1)!=126||t.char(i+2)==126)return-1;let n=t.slice(i-1,i),O=t.slice(i+2,i+3),r=/\s|^$/.test(n),s=/\s|^$/.test(O),o=gs.test(n),a=gs.test(O);return t.addDelimiter(WU,i,i+2,!s&&(!a||r||o),!r&&(!o||s||a))},after:"Emphasis"}]};function Ps(t,e,i=0,n,O=0){let r=0,s=!0,o=-1,a=-1,l=!1,c=()=>{n.push(t.elt("TableCell",O+o,O+a,t.parser.parseInline(e.slice(o,a),O+o)))};for(let h=i;h-1)&&r++,s=!1,n&&(o>-1&&c(),n.push(t.elt("TableDelimiter",h+O,h+O+1))),o=a=-1):(l||d!=32&&d!=9)&&(o<0&&(o=h),a=h+1),l=!l&&d==92}return o>-1&&(r++,n&&c()),r}function g0(t,e){for(let i=e;iO instanceof S0)||!g0(e.text,e.basePos))return!1;let n=t.peekLine();return P0.test(n)&&Ps(t,e.text,e.basePos)==Ps(t,n,e.basePos)},before:"SetextHeading"}]};class GU{nextLine(){return!1}finish(e,i){return e.addLeafElement(i,e.elt("Task",i.start,i.start+i.content.length,[e.elt("TaskMarker",i.start,i.start+3),...e.parser.parseInline(i.content.slice(3),i.start+3)])),!0}}const EU={defineNodes:[{name:"Task",block:!0,style:f.list},{name:"TaskMarker",style:f.atom}],parseBlock:[{name:"TaskList",leaf(t,e){return/^\[[ xX]\][ \t]/.test(e.content)&&t.parentType().name=="ListItem"?new GU:null},after:"SetextHeading"}]},X0=/(www\.)|(https?:\/\/)|([\w.+-]{1,100}@)|(mailto:|xmpp:)/gy,b0=/[\w-]+(\.[\w-]+)+(:\d+)?(\/[^\s<]*)?/gy,IU=/[\w-]+\.[\w-]+($|[/:])/,y0=/[\w.+-]+@[\w-]+(\.[\w.-]+)+/gy,x0=/\/[a-zA-Z\d@.]+/gy;function T0(t,e,i,n){let O=0;for(let r=e;r-1)return-1;let n=e+i[0].length;for(;;){let O=t[n-1],r;if(/[?!.,:*_~]/.test(O)||O==")"&&T0(t,e,n,")")>T0(t,e,n,"("))n--;else if(O==";"&&(r=/&(?:#\d+|#x[a-f\d]+|\w+);$/.exec(t.slice(e,n))))n=e+r.index;else break}return n}function w0(t,e){y0.lastIndex=e;let i=y0.exec(t);if(!i)return-1;let n=i[0][i[0].length-1];return n=="_"||n=="-"?-1:e+i[0].length-(n=="."?1:0)}const MU=[jU,EU,CU,{parseInline:[{name:"Autolink",parse(t,e,i){let n=i-t.offset;if(n&&/\w/.test(t.text[n-1]))return-1;X0.lastIndex=n;let O=X0.exec(t.text),r=-1;if(!O)return-1;if(O[1]||O[2]){if(r=AU(t.text,n+O[0].length),r>-1&&t.hasOpenLink){let s=/([^\[\]]|\[[^\]]*\])*/.exec(t.text.slice(n,r));r=n+s[0].length}}else O[3]?r=w0(t.text,n):(r=w0(t.text,n+O[0].length),r>-1&&O[0]=="xmpp:"&&(x0.lastIndex=r,O=x0.exec(t.text),O&&(r=O.index+O[0].length)));return r<0?-1:(t.addElement(t.elt("URL",i,r+t.offset)),r+t.offset)}}]}];function v0(t,e,i){return(n,O,r)=>{if(O!=t||n.char(r+1)==t)return-1;let s=[n.elt(i,r,r+1)];for(let o=r+1;o"}}}),_0=new F,R0=VU.configure({props:[ct.add(t=>!t.is("Block")||t.is("Document")||au(t)!=null||BU(t)?void 0:(e,i)=>({from:i.doc.lineAt(e.from).to,to:e.to})),_0.add(au),lt.add({Document:()=>null}),Sn.add({Document:k0})]});function au(t){let e=/^(?:ATX|Setext)Heading(\d)$/.exec(t.name);return e?+e[1]:void 0}function BU(t){return t.name=="OrderedList"||t.name=="BulletList"}function FU(t,e){let i=t;for(;;){let n=i.nextSibling,O;if(!n||(O=au(n.type))!=null&&O<=e)break;i=n}return i.to}const HU=Cg.of((t,e,i)=>{for(let n=$e(t).resolveInner(i,-1);n&&!(n.fromi)return{from:i,to:r}}return null});function lu(t){return new Wt(k0,t,[],"markdown")}const KU=lu(R0),Ka=lu(R0.configure([MU,LU,DU,NU,{props:[ct.add({Table:(t,e)=>({from:e.doc.lineAt(t.from).to,to:t.to})})]}]));function JU(t,e){return i=>{if(i&&t){let n=null;if(i=/\S*/.exec(i)[0],typeof t=="function"?n=t(i):n=fa.matchLanguageName(t,i,!0),n instanceof fa)return n.support?n.support.language.parser:An.getSkippingParser(n.load());if(n)return n.parser}return e?e.parser:null}}let cu=class{constructor(e,i,n,O,r,s,o){this.node=e,this.from=i,this.to=n,this.spaceBefore=O,this.spaceAfter=r,this.type=s,this.item=o}blank(e,i=!0){let n=this.spaceBefore+(this.node.name=="Blockquote"?">":"");if(e!=null){for(;n.length0;O--)n+=" ";return n+(i?this.spaceAfter:"")}}marker(e,i){let n=this.node.name=="OrderedList"?String(+Y0(this.item,e)[2]+i):"";return this.spaceBefore+n+this.type+this.spaceAfter}};function Z0(t,e){let i=[],n=[];for(let O=t;O;O=O.parent){if(O.name=="FencedCode")return n;(O.name=="ListItem"||O.name=="Blockquote")&&i.push(O)}for(let O=i.length-1;O>=0;O--){let r=i[O],s,o=e.lineAt(r.from),a=r.from-o.from;if(r.name=="Blockquote"&&(s=/^ *>( ?)/.exec(o.text.slice(a))))n.push(new cu(r,a,a+s[0].length,"",s[1],">",null));else if(r.name=="ListItem"&&r.parent.name=="OrderedList"&&(s=/^( *)\d+([.)])( *)/.exec(o.text.slice(a)))){let l=s[3],c=s[0].length;l.length>=4&&(l=l.slice(0,l.length-4),c-=4),n.push(new cu(r.parent,a,a+c,s[1],l,s[2],r))}else if(r.name=="ListItem"&&r.parent.name=="BulletList"&&(s=/^( *)([-+*])( {1,4}\[[ xX]\])?( +)/.exec(o.text.slice(a)))){let l=s[4],c=s[0].length;l.length>4&&(l=l.slice(0,l.length-4),c-=4);let h=s[2];s[3]&&(h+=s[3].replace(/[xX]/," ")),n.push(new cu(r.parent,a,a+c,s[1],l,h,r))}}return n}function Y0(t,e){return/^(\s*)(\d+)(?=[.)])/.exec(e.sliceString(t.from,t.from+10))}function hu(t,e,i,n=0){for(let O=-1,r=t;;){if(r.name=="ListItem"){let o=Y0(r,e),a=+o[2];if(O>=0){if(a!=O+1)return;i.push({from:r.from+o[1].length,to:r.from+o[0].length,insert:String(O+2+n)})}O=a}let s=r.nextSibling;if(!s)break;r=s}}function du(t,e){let i=/^[ \t]*/.exec(t)[0].length;if(!i||e.facet(YO)!=" ")return t;let n=Oi(t,4,i),O="";for(let r=n;r>0;)r>=4?(O+=" ",r-=4):(O+=" ",r--);return O+t.slice(i)}const e4=((t={})=>({state:e,dispatch:i})=>{let n=$e(e),{doc:O}=e,r=null,s=e.changeByRange(o=>{if(!o.empty||!Ka.isActiveAt(e,o.from,-1)&&!Ka.isActiveAt(e,o.from,1))return r={range:o};let a=o.from,l=O.lineAt(a),c=Z0(n.resolveInner(a,-1),O);for(;c.length&&c[c.length-1].from>a-l.from;)c.pop();if(!c.length)return r={range:o};let h=c[c.length-1];if(h.to-h.spaceAfter.length>a-l.from)return r={range:o};let d=a>=h.to-h.spaceAfter.length&&!/\S/.test(l.text.slice(h.to));if(h.item&&d){let m=h.node.firstChild,P=h.node.getChild("ListItem","ListItem");if(m.to>=a||P&&P.to0&&!/[^\s>]/.test(O.lineAt(l.from-1).text)||t.nonTightLists===!1){let g=c.length>1?c[c.length-2]:null,b,X="";g&&g.item?(b=l.from+g.from,X=g.marker(O,1)):b=l.from+(g?g.to:0);let y=[{from:b,to:a,insert:X}];return h.node.name=="OrderedList"&&hu(h.item,O,y,-2),g&&g.node.name=="OrderedList"&&hu(g.item,O,y),{range:x.cursor(b+X.length),changes:y}}else{let g=V0(c,e,l);return{range:x.cursor(a+g.length+1),changes:{from:l.from,insert:g+e.lineBreak}}}}if(h.node.name=="Blockquote"&&d&&l.from){let m=O.lineAt(l.from-1),P=/>\s*$/.exec(m.text);if(P&&P.index==h.from){let g=e.changes([{from:m.from+P.index,to:m.to},{from:l.from+h.from,to:l.to}]);return{range:o.map(g),changes:g}}}let u=[];h.node.name=="OrderedList"&&hu(h.item,O,u);let $=h.item&&h.item.from]*/.exec(l.text)[0].length>=h.to)for(let m=0,P=c.length-1;m<=P;m++)Q+=m==P&&!$?c[m].marker(O,1):c[m].blank(ml.from&&/\s/.test(l.text.charAt(p-l.from-1));)p--;return Q=du(Q,e),t4(h.node,e.doc)&&(Q=V0(c,e,l)+e.lineBreak+Q),u.push({from:p,to:a,insert:e.lineBreak+Q}),{range:x.cursor(p+Q.length+1),changes:u}});return r?!1:(i(e.update(s,{scrollIntoView:!0,userEvent:"input"})),!0)})();function z0(t){return t.name=="QuoteMark"||t.name=="ListMark"}function t4(t,e){if(t.name!="OrderedList"&&t.name!="BulletList")return!1;let i=t.firstChild,n=t.getChild("ListItem","ListItem");if(!n)return!1;let O=e.lineAt(i.to),r=e.lineAt(n.from),s=/^[\s>]*$/.test(O.text);return O.number+(s?0:1){let i=$e(t),n=null,O=t.changeByRange(r=>{let s=r.from,{doc:o}=t;if(r.empty&&Ka.isActiveAt(t,r.from)){let a=o.lineAt(s),l=Z0(i4(i,s),o);if(l.length){let c=l[l.length-1],h=c.to-c.spaceAfter.length+(c.spaceAfter?1:0);if(s-a.from>h&&!/\S/.test(a.text.slice(h,s-a.from)))return{range:x.cursor(a.from+h),changes:{from:a.from+h,to:s}};if(s-a.from==h&&(!c.item||a.from<=c.item.from||!/\S/.test(a.text.slice(0,c.to)))){let d=a.from+c.from;if(c.item&&c.node.from{var i;let{main:n}=e.state.selection;if(n.empty)return!1;let O=(i=t.clipboardData)===null||i===void 0?void 0:i.getData("text/plain");if(!O||!/^(https?:\/\/|mailto:|xmpp:|www\.)/.test(O)||(/^www\./.test(O)&&(O="https://"+O),!Ka.isActiveAt(e.state,n.from,1)))return!1;let r=$e(e.state),s=!1;return r.iterate({from:n.from,to:n.to,enter:o=>{(o.from>n.from||s4.test(o.name))&&(s=!0)},leave:o=>{o.to=97&&t<=122||t>=65&&t<=90}function Ss(t){return t==95||t>=128||E0(t)}function $u(t){return t>=48&&t<=55||t>=97&&t<=102||t>=65&&t<=70}const gW={int:!0,integer:!0,bool:!0,boolean:!0,float:!0,double:!0,real:!0,string:!0,array:!0,object:!0,unset:!0,__proto__:null},PW=new ie(t=>{if(t.next==40){t.advance();let e=0;for(;G0(t.peek(e));)e++;let i="",n;for(;E0(n=t.peek(e));)i+=String.fromCharCode(n),e++;for(;G0(t.peek(e));)e++;t.peek(e)==41&&gW[i.toLowerCase()]&&t.acceptToken(a4)}else if(t.next==60&&t.peek(1)==60&&t.peek(2)==60){for(let n=0;n<3;n++)t.advance();for(;t.next==32||t.next==9;)t.advance();let e=t.next==39;if(e&&t.advance(),!Ss(t.next))return;let i=String.fromCharCode(t.next);for(;t.advance(),!(!Ss(t.next)&&!(t.next>=48&&t.next<=55));)i+=String.fromCharCode(t.next);if(e){if(t.next!=39)return;t.advance()}if(t.next!=10&&t.next!=13)return;for(;;){let n=t.next==10||t.next==13;if(t.advance(),t.next<0)return;if(n){for(;t.next==32||t.next==9;)t.advance();let O=!0;for(let r=0;r{t.next<0&&t.acceptToken(u4)}),XW=new ie((t,e)=>{t.next==63&&e.canShift(W0)&&t.peek(1)==62&&t.acceptToken(W0)});function bW(t){let e=t.peek(1);if(e==110||e==114||e==116||e==118||e==101||e==102||e==92||e==36||e==34||e==123)return 2;if(e>=48&&e<=55){let i=2,n;for(;i<5&&(n=t.peek(i))>=48&&n<=55;)i++;return i}if(e==120&&$u(t.peek(2)))return $u(t.peek(3))?4:3;if(e==117&&t.peek(2)==123)for(let i=3;;i++){let n=t.peek(i);if(n==125)return i==2?0:i+1;if(!$u(n))break}return 0}const yW=new ie((t,e)=>{let i=!1;for(;!(t.next==34||t.next<0||t.next==36&&(Ss(t.peek(1))||t.peek(1)==123)||t.next==123&&t.peek(1)==36);i=!0){if(t.next==92){let n=bW(t);if(n){if(i)break;return t.acceptToken(h4,n)}}else if(!i&&(t.next==91||t.next==45&&t.peek(1)==62&&Ss(t.peek(2))||t.next==63&&t.peek(1)==45&&t.peek(2)==62&&Ss(t.peek(3)))&&e.canShift(d4))break;t.advance()}i&&t.acceptToken(c4)}),xW=ot({"Visibility abstract final static":f.modifier,"for foreach while do if else elseif switch try catch finally return throw break continue default case":f.controlKeyword,"endif endfor endforeach endswitch endwhile declare enddeclare goto match":f.controlKeyword,"and or xor yield unset clone instanceof insteadof":f.operatorKeyword,"function fn class trait implements extends const enum global interface use var":f.definitionKeyword,"include include_once require require_once namespace":f.moduleKeyword,"new from echo print array list as":f.keyword,null:f.null,Boolean:f.bool,VariableName:f.variableName,"NamespaceName/...":f.namespace,"NamedType/...":f.typeName,Name:f.name,"CallExpression/Name":f.function(f.variableName),"LabelStatement/Name":f.labelName,"MemberExpression/Name":f.propertyName,"MemberExpression/VariableName":f.special(f.propertyName),"ScopedExpression/ClassMemberName/Name":f.propertyName,"ScopedExpression/ClassMemberName/VariableName":f.special(f.propertyName),"CallExpression/MemberExpression/Name":f.function(f.propertyName),"CallExpression/ScopedExpression/ClassMemberName/Name":f.function(f.propertyName),"MethodDeclaration/Name":f.function(f.definition(f.variableName)),"FunctionDefinition/Name":f.function(f.definition(f.variableName)),"ClassDeclaration/Name":f.definition(f.className),UpdateOp:f.updateOperator,ArithOp:f.arithmeticOperator,"LogicOp IntersectionType/&":f.logicOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,ControlOp:f.controlOperator,AssignOp:f.definitionOperator,"$ ConcatOp":f.operator,LineComment:f.lineComment,BlockComment:f.blockComment,Integer:f.integer,Float:f.float,String:f.string,ShellExpression:f.special(f.string),"=> ->":f.punctuation,"( )":f.paren,"#[ [ ]":f.squareBracket,"${ { }":f.brace,"-> ?->":f.derefOperator,", ; :: : \\":f.separator,"PhpOpen PhpClose":f.processingInstruction}),TW={__proto__:null,static:325,STATIC:325,class:351,CLASS:351},wW=ht.deserialize({version:14,states:"%#[Q`OWOOQhQaOOP%oO`OOOOO#t'#Hh'#HhO%tO#|O'#DuOOO#u'#Dx'#DxQ&SOWO'#DxO&XO$VOOOOQ#u'#Dy'#DyO&lQaO'#D}O'[QdO'#EQO+QQdO'#IqO+_QdO'#ERO-RQaO'#EXO/bQ`O'#EUO/gQ`O'#E_O2UQaO'#E_O2]Q`O'#EgO2bQ`O'#EqO-RQaO'#EqO2mQpO'#FOO2rQ`O'#FOOOQS'#Iq'#IqO2wQ`O'#ExOOQS'#Ih'#IhO5SQdO'#IeO9UQeO'#F]O-RQaO'#FlO-RQaO'#Fm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Q:R:S:T:U:V:W:X:Y:Z:[:]:^:_:`:a:b:c:d:e:f:g:h:i:j:k:l:m:n:o:q:r:s:u:v:w;S;e;i;j;k;n;u;v;z;|;}V>W>[>]>^>c>h>i>l>n>o>p>q>v?^?_R/a,m0}}PVX]`cjklmnopxyz!S!W!X!Y!]!g!j!r!s!w!y!z!|#Q#R#S#T#U#V#W#X#Y#Z#[#]#^#_#`#a#i#l#m#q#r$Q$R$T$z%O%Q%S%T%U%V%d%}&S&W&[&q&t&u&x'P']'a(R(V(h(t)T)X)n)u)y){*V*Z*[*|+^,Q,T,Y,c,e,g,m-`-a-t-z.[.u.w/P/X/y0O0T0e0s0}1O1R1S1W1k1o1{2W2]2r3p3u3x3y3z3{3|3}4O4P4Q4R4S4T4U4V4W4X4Y4Z4[4_4`4a4b4c4k5O5R5S5V5Z5[5_5a5b5d5e5f5g5h5i5j5k5l5m5n5o5p5q5r5u5{5|5}6O6P6Q6R6S6T6U6V6W6X6Y6Z6[6]6^6_6`6a6b6c6d6l7P7S7T7W7[7]7`7b7c7o7x7y7z7{7|7}8O8P8Q8R8S8T8U8V8W8X8Y8Z8[8]8^8_8`8a8b8d8e8f8g8h8s9T9W9Z9^9_9a9c9f9h9o9p9s9u9v:Q:R:S:T:U:V:W:X:Y:Z:[:]:^:_:`:a:b:c:d:e:f:g:h:i:j:k:l:m:n:o:q:r:s:u:v:w;S;e;i;j;k;n;u;v;z;|;}V>W>[>]>^>c>h>i>l>n>o>p>q>v?^?_T$x{$|Q(q%QQ(v%TQ(y%VR2b1WQ%c!]Q(u%SQ,d(tQ/W,cQ/Y,eQ1Q/XR2_1RQ%q!fR)m%rR/p-O",nodeNames:"⚠ ( HeredocString EscapeSequence abstract LogicOp array as Boolean break case catch clone const continue default declare do echo else elseif enddeclare endfor endforeach endif endswitch endwhile enum extends final finally fn for foreach from function global goto if implements include include_once LogicOp insteadof interface list match namespace new null LogicOp print readonly require require_once return switch throw trait try unset use var Visibility while LogicOp yield LineComment BlockComment TextInterpolation PhpClose Text PhpOpen Template TextInterpolation EmptyStatement ; } { Block : LabelStatement Name ExpressionStatement ConditionalExpression LogicOp MatchExpression ) ( ParenthesizedExpression MatchBlock MatchArm , => AssignmentExpression ArrayExpression ValueList & VariadicUnpacking ... Pair [ ] ListExpression ValueList Pair Pair SubscriptExpression MemberExpression -> ?-> Name VariableName DynamicVariable $ ${ CallExpression ArgList NamedArgument SpreadArgument CastExpression UnionType LogicOp IntersectionType OptionalType NamedType QualifiedName \\ NamespaceName Name NamespaceName Name ScopedExpression :: ClassMemberName DynamicMemberName AssignOp UpdateExpression UpdateOp YieldExpression BinaryExpression LogicOp LogicOp LogicOp BitOp BitOp BitOp CompareOp CompareOp BitOp ArithOp ConcatOp ArithOp ArithOp IncludeExpression RequireExpression CloneExpression UnaryExpression ControlOp LogicOp PrintIntrinsic FunctionExpression static ParamList Parameter #[ Attributes Attribute VariadicParameter PropertyParameter PropertyHooks PropertyHook UseList ArrowFunction NewExpression class BaseClause ClassInterfaceClause DeclarationList ConstDeclaration VariableDeclarator PropertyDeclaration VariableDeclarator MethodDeclaration UseDeclaration UseList UseInsteadOfClause UseAsClause UpdateExpression ArithOp ShellExpression ThrowExpression Integer Float String MemberExpression SubscriptExpression UnaryExpression ArithOp Interpolation String IfStatement ColonBlock SwitchStatement Block CaseStatement DefaultStatement ColonBlock WhileStatement EmptyStatement DoStatement ForStatement ForSpec SequenceExpression ForeachStatement ForSpec Pair GotoStatement ContinueStatement BreakStatement ReturnStatement TryStatement CatchDeclarator DeclareStatement EchoStatement UnsetStatement ConstDeclaration FunctionDefinition ClassDeclaration InterfaceDeclaration TraitDeclaration EnumDeclaration EnumBody EnumCase NamespaceDefinition NamespaceUseDeclaration UseGroup UseClause UseClause GlobalDeclaration FunctionStaticDeclaration Program",maxTerm:318,nodeProps:[["group",-36,2,8,49,82,84,86,89,94,95,103,107,108,112,113,116,120,126,132,137,139,140,154,155,156,157,160,161,173,174,188,190,191,192,193,194,200,"Expression",-28,75,79,81,83,201,203,208,210,211,214,217,218,219,220,221,223,224,225,226,227,228,229,230,231,234,235,239,240,"Statement",-4,121,123,124,125,"Type"],["isolate",-4,67,68,71,200,""],["openedBy",70,"phpOpen",77,"{",87,"(",102,"#["],["closedBy",72,"phpClose",78,"}",88,")",165,"]"]],propSources:[xW],skippedNodes:[0],repeatNodeCount:32,tokenData:"!GQ_R!]OX$zXY&^YZ'sZ]$z]^&^^p$zpq&^qr)Rrs+Pst+otu2buv5evw6rwx8Vxy>]yz>yz{?g{|@}|}Bb}!OCO!O!PDh!P!QKT!Q!R!!o!R![!$q![!]!,P!]!^!-a!^!_!-}!_!`!1S!`!a!2d!a!b!3t!b!c!7^!c!d!7z!d!e!9Y!e!}!7z!}#O!;b#O#P!V<%lO8VR9WV'TP%`QOw9mwx:Xx#O9m#O#P:^#P;'S9m;'S;=`;X<%lO9mQ9rV%`QOw9mwx:Xx#O9m#O#P:^#P;'S9m;'S;=`;X<%lO9mQ:^O%`QQ:aRO;'S9m;'S;=`:j;=`O9mQ:oW%`QOw9mwx:Xx#O9m#O#P:^#P;'S9m;'S;=`;X;=`<%l9m<%lO9mQ;[P;=`<%l9mR;fV'TP%`QOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zRV<%l~8V~O8V~~%fR=OW'TPOY8VYZ9PZ!^8V!^!_;{!_;'S8V;'S;=`=h;=`<%l9m<%lO8VR=mW%`QOw9mwx:Xx#O9m#O#P:^#P;'S9m;'S;=`;X;=`<%l8V<%lO9mR>YP;=`<%l8VR>dV!zQ'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zV?QV!yU'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zR?nY'TP$^QOY$zYZ%fZz$zz{@^{!^$z!^!_%k!_!`6U!`;'S$z;'S;=`&W<%lO$zR@eW$_Q'TPOY$zYZ%fZ!^$z!^!_%k!_!`6U!`;'S$z;'S;=`&W<%lO$zRAUY$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!=yYZ!>qZ!^!=y!^!_!@y!_;'S!=y;'S;=`!Bd;=`<%l!?]<%lO!=yR!BgWO#O!?]#O#P!?u#P#S!?]#S#T!@n#T;'S!?];'S;=`!@s;=`<%l!=y<%lO!?]R!CWV%UQ'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zR!CpP;=`<%l!=y_!CzV!p^'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$z_!DjY$UQ#n['TPOY$zYZ%fZ!^$z!^!_%k!_!`6U!`#p$z#p#q!EY#q;'S$z;'S;=`&W<%lO$zR!EaV$SQ'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zR!E}V!oQ'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$zR!FkV$eQ'TPOY$zYZ%fZ!^$z!^!_%k!_;'S$z;'S;=`&W<%lO$z",tokenizers:[PW,yW,XW,0,1,2,3,SW],topRules:{Template:[0,73],Program:[1,241]},dynamicPrecedences:{298:1},specialized:[{term:284,get:(t,e)=>j0(t)<<1,external:j0},{term:284,get:t=>TW[t]||-1}],tokenPrec:29889}),vW=at.define({name:"php",parser:wW.configure({props:[lt.add({IfStatement:Le({except:/^\s*({|else\b|elseif\b|endif\b)/}),TryStatement:Le({except:/^\s*({|catch\b|finally\b)/}),SwitchBody:t=>{let e=t.textAfter,i=/^\s*\}/.test(e),n=/^\s*(case|default)\b/.test(e);return t.baseIndent+(i?0:n?1:2)*t.unit},ColonBlock:t=>t.baseIndent+t.unit,"Block EnumBody DeclarationList":Ni({closing:"}"}),ArrowFunction:t=>t.baseIndent+t.unit,"String BlockComment":()=>null,Statement:Le({except:/^({|end(for|foreach|switch|while)\b)/})}),ct.add({"Block EnumBody DeclarationList SwitchBody ArrayExpression ValueList":Ri,ColonBlock(t){return{from:t.from+1,to:t.to}},BlockComment(t){return{from:t.from+2,to:t.to-2}}})]}),languageData:{commentTokens:{block:{open:"/*",close:"*/"},line:"//"},indentOnInput:/^\s*(?:case |default:|end(?:if|for(?:each)?|switch|while)|else(?:if)?|\{|\})$/,wordChars:"$",closeBrackets:{stringPrefixes:["b","B"]}}});function kW(t={}){let e=[],i;if(t.baseLanguage!==null)if(t.baseLanguage)i=t.baseLanguage;else{let n=Hd({matchClosingTags:!1});e.push(n.support),i=n.language}return new Fe(vW.configure({wrap:i&&aa(n=>n.type.isTop?{parser:i.parser,overlay:O=>O.name=="Text"}:null),top:t.plain?"Program":"Template"}),e)}const _W=1,I0=194,A0=195,RW=196,M0=197,ZW=198,YW=199,zW=200,VW=2,D0=3,L0=201,qW=24,UW=25,WW=49,CW=50,jW=55,GW=56,EW=57,IW=59,AW=60,MW=61,DW=62,LW=63,NW=65,BW=238,FW=71,HW=241,KW=242,JW=243,e3=244,t3=245,i3=246,n3=247,O3=248,N0=72,r3=249,s3=250,o3=251,a3=252,l3=253,c3=254,h3=255,d3=256,u3=73,f3=77,$3=263,Q3=112,p3=130,m3=151,g3=152,P3=155,Hn=10,Xs=13,Qu=32,Ja=9,pu=35,S3=40,X3=46,mu=123,B0=125,F0=39,H0=34,K0=92,b3=111,y3=120,x3=78,T3=117,w3=85,v3=new Set([UW,WW,CW,$3,NW,p3,GW,EW,BW,DW,LW,N0,u3,f3,AW,MW,m3,g3,P3,Q3]);function gu(t){return t==Hn||t==Xs}function Pu(t){return t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102}const k3=new ie((t,e)=>{let i;if(t.next<0)t.acceptToken(YW);else if(e.context.flags&el)gu(t.next)&&t.acceptToken(ZW,1);else if(((i=t.peek(-1))<0||gu(i))&&e.canShift(M0)){let n=0;for(;t.next==Qu||t.next==Ja;)t.advance(),n++;(t.next==Hn||t.next==Xs||t.next==pu)&&t.acceptToken(M0,-n)}else gu(t.next)&&t.acceptToken(RW,1)},{contextual:!0}),_3=new ie((t,e)=>{let i=e.context;if(i.flags)return;let n=t.peek(-1);if(n==Hn||n==Xs){let O=0,r=0;for(;;){if(t.next==Qu)O++;else if(t.next==Ja)O+=8-O%8;else break;t.advance(),r++}O!=i.indent&&t.next!=Hn&&t.next!=Xs&&t.next!=pu&&(O[t,e|J0])),Y3=new AO({start:R3,reduce(t,e,i,n){return t.flags&el&&v3.has(e)||(e==FW||e==N0)&&t.flags&J0?t.parent:t},shift(t,e,i,n){return e==I0?new tl(t,Z3(n.read(n.pos,i.pos)),0):e==A0?t.parent:e==qW||e==jW||e==IW||e==D0?new tl(t,0,el):eX.has(e)?new tl(t,0,eX.get(e)|t.flags&el):t},hash(t){return t.hash}}),z3=new ie(t=>{for(let e=0;e<5;e++){if(t.next!="print".charCodeAt(e))return;t.advance()}if(!/\w/.test(String.fromCharCode(t.next)))for(let e=0;;e++){let i=t.peek(e);if(!(i==Qu||i==Ja)){i!=S3&&i!=X3&&i!=Hn&&i!=Xs&&i!=pu&&t.acceptToken(_W);return}}}),V3=new ie((t,e)=>{let{flags:i}=e.context,n=i&Hi?H0:F0,O=(i&Ki)>0,r=!(i&Ji),s=(i&en)>0,o=t.pos;for(;!(t.next<0);)if(s&&t.next==mu)if(t.peek(1)==mu)t.advance(2);else{if(t.pos==o){t.acceptToken(D0,1);return}break}else if(r&&t.next==K0){if(t.pos==o){t.advance();let a=t.next;a>=0&&(t.advance(),q3(t,a)),t.acceptToken(VW);return}break}else if(t.next==K0&&!r&&t.peek(1)>-1)t.advance(2);else if(t.next==n&&(!O||t.peek(1)==n&&t.peek(2)==n)){if(t.pos==o){t.acceptToken(L0,O?3:1);return}break}else if(t.next==Hn){if(O)t.advance();else if(t.pos==o){t.acceptToken(L0);return}break}else t.advance();t.pos>o&&t.acceptToken(zW)});function q3(t,e){if(e==b3)for(let i=0;i<2&&t.next>=48&&t.next<=55;i++)t.advance();else if(e==y3)for(let i=0;i<2&&Pu(t.next);i++)t.advance();else if(e==T3)for(let i=0;i<4&&Pu(t.next);i++)t.advance();else if(e==w3)for(let i=0;i<8&&Pu(t.next);i++)t.advance();else if(e==x3&&t.next==mu){for(t.advance();t.next>=0&&t.next!=B0&&t.next!=F0&&t.next!=H0&&t.next!=Hn;)t.advance();t.next==B0&&t.advance()}}const U3=ot({'async "*" "**" FormatConversion FormatSpec':f.modifier,"for while if elif else try except finally return raise break continue with pass assert await yield match case":f.controlKeyword,"in not and or is del":f.operatorKeyword,"from def class global nonlocal lambda":f.definitionKeyword,import:f.moduleKeyword,"with as print":f.keyword,Boolean:f.bool,None:f.null,VariableName:f.variableName,"CallExpression/VariableName":f.function(f.variableName),"FunctionDefinition/VariableName":f.function(f.definition(f.variableName)),"ClassDefinition/VariableName":f.definition(f.className),PropertyName:f.propertyName,"CallExpression/MemberExpression/PropertyName":f.function(f.propertyName),Comment:f.lineComment,Number:f.number,String:f.string,FormatString:f.special(f.string),Escape:f.escape,UpdateOp:f.updateOperator,"ArithOp!":f.arithmeticOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,AssignOp:f.definitionOperator,Ellipsis:f.punctuation,At:f.meta,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace,".":f.derefOperator,", ;":f.separator}),W3={__proto__:null,await:44,or:54,and:56,in:60,not:62,is:64,if:70,else:72,lambda:76,yield:94,from:96,async:102,for:104,None:162,True:164,False:164,del:178,pass:182,break:186,continue:190,return:194,raise:202,import:206,as:208,global:212,nonlocal:214,assert:218,type:223,elif:236,while:240,try:246,except:248,finally:250,with:254,def:258,class:268,match:279,case:285},C3=ht.deserialize({version:14,states:"##jQ`QeOOP$}OSOOO&WQtO'#HUOOQS'#Co'#CoOOQS'#Cp'#CpO'vQdO'#CnO*UQtO'#HTOOQS'#HU'#HUOOQS'#DU'#DUOOQS'#HT'#HTO*rQdO'#D_O+VQdO'#DfO+gQdO'#DjO+zOWO'#DuO,VOWO'#DvO.[QtO'#GuOOQS'#Gu'#GuO'vQdO'#GtO0ZQtO'#GtOOQS'#Eb'#EbO0rQdO'#EcOOQS'#Gs'#GsO0|QdO'#GrOOQV'#Gr'#GrO1XQdO'#FYOO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ionDefinition","ClassDefinition","LambdaExpression","ForStatement","MatchClause"]);function il(t){return(e,i,n)=>{if(n)return!1;let O=e.node.getChild("VariableName");return O&&i(O,t),!0}}const j3={FunctionDefinition:il("function"),ClassDefinition:il("class"),ForStatement(t,e,i){if(i){for(let n=t.node.firstChild;n;n=n.nextSibling)if(n.name=="VariableName")e(n,"variable");else if(n.name=="in")break}},ImportStatement(t,e){var i,n;let{node:O}=t,r=((i=O.firstChild)===null||i===void 0?void 0:i.name)=="from";for(let s=O.getChild("import");s;s=s.nextSibling)s.name=="VariableName"&&((n=s.nextSibling)===null||n===void 0?void 0:n.name)!="as"&&e(s,r?"variable":"namespace")},AssignStatement(t,e){for(let i=t.node.firstChild;i;i=i.nextSibling)if(i.name=="VariableName")e(i,"variable");else if(i.name==":"||i.name=="AssignOp")break},ParamList(t,e){for(let i=null,n=t.node.firstChild;n;n=n.nextSibling)n.name=="VariableName"&&(!i||!/\*|AssignOp/.test(i.name))&&e(n,"variable"),i=n},CapturePattern:il("variable"),AsPattern:il("variable"),__proto__:null};function nX(t,e){let i=tX.get(e);if(i)return i;let n=[],O=!0;function r(s,o){let a=t.sliceString(s.from,s.to);n.push({label:a,type:o})}return e.cursor(fe.IncludeAnonymous).iterate(s=>{if(s.name){let o=j3[s.name];if(o&&o(s,r,O)||!O&&iX.has(s.name))return!1;O=!1}else if(s.to-s.from>8192){for(let o of nX(t,s.node))n.push(o);return!1}}),tX.set(e,n),n}const OX=/^[\w\xa1-\uffff][\w\d\xa1-\uffff]*$/,rX=["String","FormatString","Comment","PropertyName"];function G3(t){let e=$e(t.state).resolveInner(t.pos,-1);if(rX.indexOf(e.name)>-1)return null;let i=e.name=="VariableName"||e.to-e.from<20&&OX.test(t.state.sliceDoc(e.from,e.to));if(!i&&!t.explicit)return null;let n=[];for(let O=e;O;O=O.parent)iX.has(O.name)&&(n=n.concat(nX(t.state.doc,O)));return{options:n,from:i?e.from:t.pos,validFor:OX}}const E3=["__annotations__","__builtins__","__debug__","__doc__","__import__","__name__","__loader__","__package__","__spec__","False","None","True"].map(t=>({label:t,type:"constant"})).concat(["ArithmeticError","AssertionError","AttributeError","BaseException","BlockingIOError","BrokenPipeError","BufferError","BytesWarning","ChildProcessError","ConnectionAbortedError","ConnectionError","ConnectionRefusedError","ConnectionResetError","DeprecationWarning","EOFError","Ellipsis","EncodingWarning","EnvironmentError","Exception","FileExistsError","FileNotFoundError","FloatingPointError","FutureWarning","GeneratorExit","IOError","ImportError","ImportWarning","IndentationError","IndexError","InterruptedError","IsADirectoryError","KeyError","KeyboardInterrupt","LookupError","MemoryError","ModuleNotFoundError","NameError","NotADirectoryError","NotImplemented","NotImplementedError","OSError","OverflowError","PendingDeprecationWarning","PermissionError","ProcessLookupError","RecursionError","ReferenceError","ResourceWarning","RuntimeError","RuntimeWarning","StopAsyncIteration","StopIteration","SyntaxError","SyntaxWarning","SystemError","SystemExit","TabError","TimeoutError","TypeError","UnboundLocalError","UnicodeDecodeError","UnicodeEncodeError","UnicodeError","UnicodeTranslateError","UnicodeWarning","UserWarning","ValueError","Warning","ZeroDivisionError"].map(t=>({label:t,type:"type"}))).concat(["bool","bytearray","bytes","classmethod","complex","float","frozenset","int","list","map","memoryview","object","range","set","staticmethod","str","super","tuple","type"].map(t=>({label:t,type:"class"}))).concat(["abs","aiter","all","anext","any","ascii","bin","breakpoint","callable","chr","compile","delattr","dict","dir","divmod","enumerate","eval","exec","exit","filter","format","getattr","globals","hasattr","hash","help","hex","id","input","isinstance","issubclass","iter","len","license","locals","max","min","next","oct","open","ord","pow","print","property","quit","repr","reversed","round","setattr","slice","sorted","sum","vars","zip"].map(t=>({label:t,type:"function"}))),I3=[_e("def ${name}(${params}):\n ${}",{label:"def",detail:"function",type:"keyword"}),_e("for ${name} in ${collection}:\n ${}",{label:"for",detail:"loop",type:"keyword"}),_e("while ${}:\n ${}",{label:"while",detail:"loop",type:"keyword"}),_e("try:\n ${}\nexcept ${error}:\n ${}",{label:"try",detail:"/ except block",type:"keyword"}),_e(`if \${}: + +`,{label:"if",detail:"block",type:"keyword"}),_e("if ${}:\n ${}\nelse:\n ${}",{label:"if",detail:"/ else block",type:"keyword"}),_e("class ${name}:\n def __init__(self, ${params}):\n ${}",{label:"class",detail:"definition",type:"keyword"}),_e("import ${module}",{label:"import",detail:"statement",type:"keyword"}),_e("from ${module} import ${names}",{label:"from",detail:"import",type:"keyword"})],A3=md(rX,Ya(E3.concat(I3)));function Su(t){let{node:e,pos:i}=t,n=t.lineIndent(i,-1),O=null;for(;;){let r=e.childBefore(i);if(r)if(r.name=="Comment")i=r.from;else if(r.name=="Body"||r.name=="MatchBody")t.baseIndentFor(r)+t.unit<=n&&(O=r),e=r;else if(r.name=="MatchClause")e=r;else if(r.type.is("Statement"))e=r;else break;else break}return O}function Xu(t,e){let i=t.baseIndentFor(e),n=t.lineAt(t.pos,-1),O=n.from+n.text.length;return/^\s*($|#)/.test(n.text)&&t.node.toi?null:i+t.unit}const bu=at.define({name:"python",parser:C3.configure({props:[lt.add({Body:t=>{var e;let i=/^\s*(#|$)/.test(t.textAfter)&&Su(t)||t.node;return(e=Xu(t,i))!==null&&e!==void 0?e:t.continue()},MatchBody:t=>{var e;let i=Su(t);return(e=Xu(t,i||t.node))!==null&&e!==void 0?e:t.continue()},IfStatement:t=>/^\s*(else:|elif )/.test(t.textAfter)?t.baseIndent:t.continue(),"ForStatement WhileStatement":t=>/^\s*else:/.test(t.textAfter)?t.baseIndent:t.continue(),TryStatement:t=>/^\s*(except[ :]|finally:|else:)/.test(t.textAfter)?t.baseIndent:t.continue(),MatchStatement:t=>/^\s*case /.test(t.textAfter)?t.baseIndent+t.unit:t.continue(),"TupleExpression ComprehensionExpression ParamList ArgList ParenthesizedExpression":Ni({closing:")"}),"DictionaryExpression DictionaryComprehensionExpression SetExpression SetComprehensionExpression":Ni({closing:"}"}),"ArrayExpression ArrayComprehensionExpression":Ni({closing:"]"}),MemberExpression:t=>t.baseIndent+t.unit,"String FormatString":()=>null,Script:t=>{var e;let i=Su(t);return(e=i&&Xu(t,i))!==null&&e!==void 0?e:t.continue()}}),ct.add({"ArrayExpression DictionaryExpression SetExpression TupleExpression":Ri,Body:(t,e)=>({from:t.from+1,to:t.to-(t.to==e.doc.length?0:1)}),"String FormatString":(t,e)=>({from:e.doc.lineAt(t.from).to,to:t.to})})]}),languageData:{closeBrackets:{brackets:["(","[","{","'",'"',"'''",'"""'],stringPrefixes:["f","fr","rf","r","u","b","br","rb","F","FR","RF","R","U","B","BR","RB"]},commentTokens:{line:"#"},indentOnInput:/^\s*([\}\]\)]|else:|elif |except |finally:|case\s+[^:]*:?)$/}});function M3(){return new Fe(bu,[bu.data.of({autocomplete:G3}),bu.data.of({autocomplete:A3})])}const D3=1,L3=2,N3=3,B3=4,F3=5,sX=98,H3=101,K3=102,oX=114,J3=69,nl=48,aX=46,e8=43,t8=45,lX=35,cX=34,i8=124,n8=60,O8=62;function yu(t){return t>=48&&t<=57}function Ol(t){return yu(t)||t==95}const r8=new ie((t,e)=>{if(yu(t.next)){let i=!1;do t.advance();while(Ol(t.next));if(t.next==aX){if(i=!0,t.advance(),yu(t.next))do t.advance();while(Ol(t.next));else if(t.next==aX||t.next>127||/\w/.test(String.fromCharCode(t.next)))return}if(t.next==H3||t.next==J3){if(i=!0,t.advance(),(t.next==e8||t.next==t8)&&t.advance(),!Ol(t.next))return;do t.advance();while(Ol(t.next))}if(t.next==K3){let n=t.peek(1);if(n==nl+3&&t.peek(2)==nl+2||n==nl+6&&t.peek(2)==nl+4)t.advance(3),i=!0;else return}i&&t.acceptToken(F3)}else if(t.next==sX||t.next==oX){if(t.next==sX&&t.advance(),t.next!=oX)return;t.advance();let i=0;for(;t.next==lX;)i++,t.advance();if(t.next!=cX)return;t.advance();e:for(;;){if(t.next<0)return;let n=t.next==cX;if(t.advance(),n){for(let O=0;O{t.next==i8&&t.acceptToken(D3,1)}),o8=new ie(t=>{t.next==n8?t.acceptToken(L3,1):t.next==O8&&t.acceptToken(N3,1)}),a8=ot({"const macro_rules struct union enum type fn impl trait let static":f.definitionKeyword,"mod use crate":f.moduleKeyword,"pub unsafe async mut extern default move":f.modifier,"for if else loop while match continue break return await":f.controlKeyword,"as in ref":f.operatorKeyword,"where _ crate super dyn":f.keyword,self:f.self,String:f.string,Char:f.character,RawString:f.special(f.string),Boolean:f.bool,Identifier:f.variableName,"CallExpression/Identifier":f.function(f.variableName),BoundIdentifier:f.definition(f.variableName),"FunctionItem/BoundIdentifier":f.function(f.definition(f.variableName)),LoopLabel:f.labelName,FieldIdentifier:f.propertyName,"CallExpression/FieldExpression/FieldIdentifier":f.function(f.propertyName),Lifetime:f.special(f.variableName),ScopeIdentifier:f.namespace,TypeIdentifier:f.typeName,"MacroInvocation/Identifier MacroInvocation/ScopedIdentifier/Identifier":f.macroName,"MacroInvocation/TypeIdentifier MacroInvocation/ScopedIdentifier/TypeIdentifier":f.macroName,'"!"':f.macroName,UpdateOp:f.updateOperator,LineComment:f.lineComment,BlockComment:f.blockComment,Integer:f.integer,Float:f.float,ArithOp:f.arithmeticOperator,LogicOp:f.logicOperator,BitOp:f.bitwiseOperator,CompareOp:f.compareOperator,"=":f.definitionOperator,".. ... => ->":f.punctuation,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace,". DerefOp":f.derefOperator,"&":f.operator,", ; ::":f.separator,"Attribute/...":f.meta}),l8={__proto__:null,self:28,super:32,crate:34,impl:46,true:72,false:72,pub:88,in:92,const:96,unsafe:104,async:108,move:110,if:114,let:118,ref:142,mut:144,_:198,else:200,match:204,as:248,return:252,await:262,break:270,continue:276,while:312,loop:316,for:320,macro_rules:327,mod:334,extern:342,struct:346,where:364,union:379,enum:382,type:390,default:395,fn:396,trait:412,use:420,static:438,dyn:476},c8=ht.deserialize({version:14,states:"$2xQ]Q_OOP$wOWOOO&sQWO'#CnO)WQWO'#I`OOQP'#I`'#I`OOQQ'#Ie'#IeO)hO`O'#C}OOQR'#Ih'#IhO)sQWO'#IuOOQO'#Hk'#HkO)xQWO'#DpOOQR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^*e*n*w*x+U+V+h+o+}-i-t-v.U.`.p.t.x.y/Z/[/{/}0`0r0w1O1Y1Z1y2a2h2j2m2s2v3V3u3{3|4R4U4_4e4t5`5d5v6R6Y6p6v6x7c7r8gR0k+ZR0j+ZQ'R!qQ)c%XQ+w&|R4y1PX'Q!q%X&|1PR+y&|R+x&|T/S*S4TT/R*S4TR.o)sR.n)sR){%p",nodeNames:"⚠ | < > RawString Float LineComment BlockComment SourceFile ] InnerAttribute ! [ MetaItem self Metavariable super crate Identifier ScopedIdentifier :: QualifiedScope AbstractType impl SelfType MetaType TypeIdentifier ScopedTypeIdentifier ScopeIdentifier TypeArgList TypeBinding = Lifetime String Escape Char Boolean Integer } { Block ; ConstItem Vis pub ( in ) const BoundIdentifier : UnsafeBlock unsafe AsyncBlock async move IfExpression if LetDeclaration let LiteralPattern ArithOp MetaPattern SelfPattern ScopedIdentifier TuplePattern ScopedTypeIdentifier , StructPattern FieldPatternList FieldPattern ref mut FieldIdentifier .. RefPattern SlicePattern CapturedPattern ReferencePattern & MutPattern RangePattern ... OrPattern MacroPattern ParenthesizedTokens TokenBinding Identifier TokenRepetition ArithOp BitOp LogicOp UpdateOp CompareOp -> => ArithOp BracketedTokens BracedTokens _ else MatchExpression match MatchBlock MatchArm Attribute Guard UnaryExpression ArithOp DerefOp LogicOp ReferenceExpression TryExpression BinaryExpression ArithOp ArithOp BitOp BitOp BitOp BitOp LogicOp LogicOp AssignmentExpression TypeCastExpression as ReturnExpression return RangeExpression CallExpression ArgList AwaitExpression await FieldExpression GenericFunction BreakExpression break LoopLabel ContinueExpression continue IndexExpression ArrayExpression TupleExpression MacroInvocation UnitExpression ClosureExpression ParamList Parameter Parameter ParenthesizedExpression StructExpression FieldInitializerList ShorthandFieldInitializer FieldInitializer BaseFieldInitializer MatchArm WhileExpression while LoopExpression loop ForExpression for MacroInvocation MacroDefinition macro_rules MacroRule EmptyStatement ModItem mod DeclarationList AttributeItem ForeignModItem extern StructItem struct TypeParamList ConstrainedTypeParameter TraitBounds HigherRankedTraitBound RemovedTraitBound OptionalTypeParameter ConstParameter WhereClause where LifetimeClause TypeBoundClause FieldDeclarationList FieldDeclaration OrderedFieldDeclarationList UnionItem union EnumItem enum EnumVariantList EnumVariant TypeItem type FunctionItem default fn ParamList Parameter SelfParameter VariadicParameter VariadicParameter ImplItem TraitItem trait AssociatedType LetDeclaration UseDeclaration use ScopedIdentifier UseAsClause ScopedIdentifier UseList ScopedUseList UseWildcard ExternCrateDeclaration StaticItem static ExpressionStatement ExpressionStatement GenericType FunctionType ForLifetimes ParamList VariadicParameter Parameter VariadicParameter Parameter ReferenceType PointerType TupleType UnitType ArrayType MacroInvocation EmptyType DynamicType dyn BoundedType",maxTerm:359,nodeProps:[["isolate",-4,4,6,7,33,""],["group",-42,4,5,14,15,16,17,18,19,33,35,36,37,40,51,53,56,101,107,111,112,113,122,123,125,127,128,130,132,133,134,137,139,140,141,142,143,144,148,149,155,157,159,"Expression",-16,22,24,25,26,27,222,223,230,231,232,233,234,235,236,237,239,"Type",-20,42,161,162,165,166,169,170,172,188,190,194,196,204,205,207,208,209,217,218,220,"Statement",-17,49,60,62,63,64,65,68,74,75,76,77,78,80,81,83,84,99,"Pattern"],["openedBy",9,"[",38,"{",47,"("],["closedBy",12,"]",39,"}",45,")"]],propSources:[a8],skippedNodes:[0,6,7,240],repeatNodeCount:32,tokenData:"$%h_R!XOX$nXY5gYZ6iZ]$n]^5g^p$npq5gqr7Xrs9cst:Rtu;Tuv>vvwAQwxCbxy!+Tyz!,Vz{!-X{|!/_|}!0g}!O!1i!O!P!3v!P!Q!8[!Q!R!Bw!R![!Dr![!]#+q!]!^#-{!^!_#.}!_!`#1b!`!a#3o!a!b#6S!b!c#7U!c!}#8W!}#O#:T#O#P#;V#P#Q#Cb#Q#R#Dd#R#S#8W#S#T$n#T#U#8W#U#V#El#V#f#8W#f#g#Ic#g#o#8W#o#p$ S#p#q$!U#q#r$$f#r${$n${$|#8W$|4w$n4w5b#8W5b5i$n5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S$n;'S;=`4s<%lO$n",tokenizers:[s8,o8,r8,0,1,2,3],topRules:{SourceFile:[0,8]},specialized:[{term:281,get:t=>l8[t]||-1}],tokenPrec:15596}),h8=at.define({name:"rust",parser:c8.configure({props:[lt.add({IfExpression:Le({except:/^\s*({|else\b)/}),"String BlockComment":()=>null,AttributeItem:t=>t.continue(),"Statement MatchArm":Le()}),ct.add(t=>{if(/(Block|edTokens|List)$/.test(t.name))return Ri;if(t.name=="BlockComment")return e=>({from:e.from+2,to:e.to-2})})]}),languageData:{commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:\{|\})$/,closeBrackets:{stringPrefixes:["b","r","br"]}}});function d8(){return new Fe(h8)}const hX=168,xu=169,u8=170,f8=1,$8=2,dX=3,Q8=171,p8=172,uX=4,fX=173,m8=5,g8=174,$X=175,QX=176,Tu=177,pX=6,mX=7,P8=8,S8=9,rl=0,tn=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],X8=58,b8=40,wu=95,y8=91,bs=45,x8=46,vu=35,T8=37,gX=123,w8=125,ys=47,xs=42,Jt=10,PX=61,v8=43,k8=38;function NO(t){return t>=65&&t<=90||t>=97&&t<=122||t>=161}function ku(t){return t>=48&&t<=57}function _u(t){let e;return t.next==ys&&((e=t.peek(1))==ys||e==xs)}const _8=new ie((t,e)=>{if(e.dialectEnabled(rl)){let i;if(t.next<0&&e.canShift(QX))t.acceptToken(QX);else if(((i=t.peek(-1))==Jt||i<0)&&e.canShift($X)){let n=0;for(;t.next!=Jt&&tn.includes(t.next);)t.advance(),n++;t.next==Jt||_u(t)?t.acceptToken($X,-n):n&&t.acceptToken(Tu)}else if(t.next==Jt)t.acceptToken(g8,1);else if(tn.includes(t.next)){for(t.advance();t.next!=Jt&&tn.includes(t.next);)t.advance();t.acceptToken(Tu)}}else{let i=0;for(;tn.includes(t.next);)t.advance(),i++;i&&t.acceptToken(Tu)}},{contextual:!0}),R8=new ie((t,e)=>{if(_u(t)){if(t.advance(),e.dialectEnabled(rl)){let i=-1;for(let n=1;;n++){let O=t.peek(-n-1);if(O==Jt||O<0){i=n+1;break}else if(!tn.includes(O))break}if(i>-1){let n=t.next==xs,O=0;for(t.advance();t.next>=0;)if(t.next==Jt){t.advance();let r=0;for(;t.next!=Jt&&tn.includes(t.next);)r++,t.advance();if(r=0;)t.advance();t.acceptToken(pX)}else{for(t.advance();t.next>=0;){let{next:i}=t;if(t.advance(),i==xs&&t.next==ys){t.advance();break}}t.acceptToken(mX)}}}),Z8=new ie((t,e)=>{(t.next==v8||t.next==PX)&&e.dialectEnabled(rl)&&t.acceptToken(t.next==PX?P8:S8,1)}),Y8=new ie((t,e)=>{if(!e.dialectEnabled(rl))return;let i=e.context.depth;if(t.next<0&&i){t.acceptToken(xu);return}if(t.peek(-1)==Jt){let O=0;for(;t.next!=Jt&&tn.includes(t.next);)t.advance(),O++;O!=i&&t.next!=Jt&&!_u(t)&&(O{for(let i=!1,n=0,O=0;;O++){let{next:r}=t;if(NO(r)||r==bs||r==wu||i&&ku(r))!i&&(r!=bs||O>0)&&(i=!0),n===O&&r==bs&&n++,t.advance();else if(r==vu&&t.peek(1)==gX){t.acceptToken(m8,2);break}else{i&&t.acceptToken(n==2&&e.canShift(uX)?uX:e.canShift(fX)?fX:r==b8?Q8:p8);break}}}),V8=new ie(t=>{if(t.next==w8){for(t.advance();NO(t.next)||t.next==bs||t.next==wu||ku(t.next);)t.advance();t.next==vu&&t.peek(1)==gX?t.acceptToken($8,2):t.acceptToken(f8)}}),q8=new ie(t=>{if(tn.includes(t.peek(-1))){let{next:e}=t;(NO(e)||e==wu||e==vu||e==x8||e==y8||e==X8&&NO(t.peek(1))||e==bs||e==k8||e==xs)&&t.acceptToken(u8)}}),U8=new ie(t=>{if(!tn.includes(t.peek(-1))){let{next:e}=t;if(e==T8&&(t.advance(),t.acceptToken(dX)),NO(e)){do t.advance();while(NO(t.next)||ku(t.next));t.acceptToken(dX)}}});function SX(t,e){this.parent=t,this.depth=e,this.hash=(t?t.hash+t.hash<<8:0)+e+(e<<4)}const W8=new SX(null,0),C8=new AO({start:W8,shift(t,e,i,n){return e==hX?new SX(t,i.pos-n.pos):e==xu?t.parent:t},hash(t){return t.hash}}),j8=ot({"AtKeyword import charset namespace keyframes media supports include mixin use forward extend at-root":f.definitionKeyword,"Keyword selector":f.keyword,ControlKeyword:f.controlKeyword,NamespaceName:f.namespace,KeyframeName:f.labelName,KeyframeRangeName:f.operatorKeyword,TagName:f.tagName,"ClassName Suffix":f.className,PseudoClassName:f.constant(f.className),IdName:f.labelName,"FeatureName PropertyName":f.propertyName,AttributeName:f.attributeName,NumberLiteral:f.number,KeywordQuery:f.keyword,UnaryQueryOp:f.operatorKeyword,"CallTag ValueName":f.atom,VariableName:f.variableName,SassVariableName:f.special(f.variableName),Callee:f.operatorKeyword,Unit:f.unit,"UniversalSelector NestingSelector IndentedMixin IndentedInclude":f.definitionOperator,MatchOp:f.compareOperator,"ChildOp SiblingOp, LogicOp":f.logicOperator,BinOp:f.arithmeticOperator,"Important Global Default":f.modifier,Comment:f.blockComment,LineComment:f.lineComment,ColorLiteral:f.color,"ParenthesizedContent StringLiteral":f.string,"InterpolationStart InterpolationContinue InterpolationEnd":f.meta,': "..."':f.punctuation,"PseudoOp #":f.derefOperator,"; ,":f.separator,"( )":f.paren,"[ ]":f.squareBracket,"{ }":f.brace}),G8={__proto__:null,not:62,using:197,as:207,with:211,without:211,hide:225,show:225,if:263,from:269,to:271,through:273,in:279},E8={__proto__:null,url:82,"url-prefix":82,domain:82,regexp:82,lang:104,"nth-child":104,"nth-last-child":104,"nth-of-type":104,"nth-last-of-type":104,dir:104,"host-context":104},I8={__proto__:null,"@import":162,"@include":194,"@mixin":200,"@function":200,"@use":204,"@extend":214,"@at-root":218,"@forward":222,"@media":228,"@charset":232,"@namespace":236,"@keyframes":242,"@supports":254,"@if":258,"@else":260,"@for":266,"@each":276,"@while":282,"@debug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q&j'S'V'^'t(U(Y(^(w)UQ&S$cS&W$e&YQ&g$wQ&{%_Q'O%bQ'X%{Q'f&XQ(`'bQ(h'qQ(t(QR(u(SR%x$OR&R$aR&P$`QzPQ$^!fR%}$_X#ly#j#m%eQ#VhQ#_mQ$h!uR&^$iW#Rhm!u$iQ#^lQ$|#QQ%S#SQ&m%PQ&n%QQ'p&dR(f'oQ%O#QQ'v&kR)R(nQ#apQ$k!vQ$n!xQ$q!zQ$v#OQ%V#WQ%W#YQ%]#_Q%d#hQ&]$hQ&f$uQ&q%XQ'k&^Q'l&_S'm&`&bQ(k'sQ(}(eR)Q(jR&h$wR#ft",nodeNames:"⚠ InterpolationEnd InterpolationContinue Unit VariableName InterpolationStart LineComment Comment IndentedMixin IndentedInclude StyleSheet RuleSet UniversalSelector TagSelector TagName NestingSelector SuffixedSelector Suffix Interpolation SassVariableName ValueName ) ( ParenthesizedValue ColorLiteral NumberLiteral StringLiteral BinaryExpression BinOp LogicOp UnaryExpression LogicOp NamespacedValue . CallExpression Callee ArgList : ... , CallLiteral CallTag ParenthesizedContent ] [ LineNames LineName ClassSelector ClassName PseudoClassSelector :: PseudoClassName PseudoClassName ArgList PseudoClassName ArgList IdSelector # IdName AttributeSelector AttributeName MatchOp ChildSelector ChildOp DescendantSelector SiblingSelector SiblingOp PlaceholderSelector ClassName Block { Declaration PropertyName Map Important Global Default ; } ImportStatement AtKeyword import Layer layer LayerName KeywordQuery FeatureQuery FeatureName BinaryQuery ComparisonQuery CompareOp UnaryQuery LogicOp ParenthesizedQuery SelectorQuery selector IncludeStatement include Keyword MixinStatement mixin UseStatement use Keyword Star Keyword ExtendStatement extend RootStatement at-root ForwardStatement forward Keyword MediaStatement media CharsetStatement charset NamespaceStatement namespace NamespaceName KeyframesStatement keyframes KeyframeName KeyframeList KeyframeSelector KeyframeRangeName SupportsStatement supports IfStatement ControlKeyword ControlKeyword Keyword ForStatement ControlKeyword Keyword Keyword Keyword EachStatement ControlKeyword Keyword WhileStatement Contro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O$Rk!!]UOy$Rz#f$R#f#g! u#g;'S$R;'S;=`$d<%lO$RZ!!tS!hROy$Rz;'S$R;'S;=`$d<%lO$RZ!#VS!pROy$Rz;'S$R;'S;=`$d<%lO$R]!#hU!dPOy$Rz!_$R!_!`;T!`;'S$R;'S;=`$d<%lO$RW!#}P;=`<%l#r",tokenizers:[Y8,q8,V8,U8,z8,_8,R8,Z8,0,1,2,3,4],topRules:{StyleSheet:[0,10],Styles:[1,145]},dialects:{indented:0},specialized:[{term:172,get:t=>G8[t]||-1},{term:171,get:t=>E8[t]||-1},{term:80,get:t=>I8[t]||-1},{term:173,get:t=>A8[t]||-1}],tokenPrec:3217}),Ru=at.define({name:"sass",parser:M8.configure({props:[ct.add({Block:Ri,Comment(t,e){return{from:t.from+2,to:e.sliceDoc(t.to-2,t.to)=="*/"?t.to-2:t.to}}}),lt.add({Declaration:Le()})]}),languageData:{commentTokens:{block:{open:"/*",close:"*/"},line:"//"},indentOnInput:/^\s*\}$/,wordChars:"$-"}}),D8=Ru.configure({dialect:"indented",props:[lt.add({"Block RuleSet":t=>t.baseIndent+t.unit}),ct.add({Block:t=>({from:t.from,to:t.to})})]}),L8=nS(t=>t.name=="VariableName"||t.name=="SassVariableName");function XX(t){return new Fe(t?.indented?D8:Ru,Ru.data.of({autocomplete:L8}))}const N8=36,bX=1,B8=2,BO=3,Zu=4,F8=5,H8=6,K8=7,J8=8,e7=9,t7=10,i7=11,n7=12,O7=13,r7=14,s7=15,o7=16,a7=17,yX=18,l7=19,xX=20,TX=21,wX=22,c7=23,h7=24;function Yu(t){return t>=65&&t<=90||t>=97&&t<=122||t>=48&&t<=57}function d7(t){return t>=48&&t<=57||t>=97&&t<=102||t>=65&&t<=70}function Kn(t,e,i){for(let n=!1;;){if(t.next<0)return;if(t.next==e&&!n){t.advance();return}n=i&&!n&&t.next==92,t.advance()}}function u7(t,e){e:for(;;){if(t.next<0)return;if(t.next==36){t.advance();for(let i=0;i)".charCodeAt(i);for(;;){if(t.next<0)return;if(t.next==n&&t.peek(1)==39){t.advance(2);return}t.advance()}}function zu(t,e){for(;!(t.next!=95&&!Yu(t.next));)e!=null&&(e+=String.fromCharCode(t.next)),t.advance();return e}function $7(t){if(t.next==39||t.next==34||t.next==96){let e=t.next;t.advance(),Kn(t,e,!1)}else zu(t)}function vX(t,e){for(;t.next==48||t.next==49;)t.advance();e&&t.next==e&&t.advance()}function kX(t,e){for(;;){if(t.next==46){if(e)break;e=!0}else if(t.next<48||t.next>57)break;t.advance()}if(t.next==69||t.next==101)for(t.advance(),(t.next==43||t.next==45)&&t.advance();t.next>=48&&t.next<=57;)t.advance()}function _X(t){for(;!(t.next<0||t.next==10);)t.advance()}function Jn(t,e){for(let i=0;i!=&|~^/",specialVar:"?",identifierQuotes:'"',caseInsensitiveIdentifiers:!1,words:RX("absolute action add after all allocate alter and any are as asc assertion at authorization before begin between both breadth by call cascade cascaded case cast catalog check close collate collation column commit condition connect connection constraint constraints constructor continue corresponding count create cross cube current current_date current_default_transform_group current_transform_group_for_type current_path current_role current_time current_timestamp current_user cursor cycle data day deallocate declare default deferrable deferred delete depth deref desc describe descriptor deterministic diagnostics disconnect distinct do domain drop dynamic each else elseif end end-exec equals escape except exception exec execute exists exit external fetch first for foreign found from free full function general get global go goto grant group grouping handle having hold hour identity if immediate in indicator initially inner inout input insert intersect into is isolation join key language last lateral leading leave left level like limit local localtime localtimestamp locator loop map match method minute modifies module month names natural nesting new next no none not of old on only open option or order ordinality out outer output overlaps pad parameter partial path prepare preserve primary prior privileges procedure public read reads recursive redo ref references referencing relative release repeat resignal restrict result return returns revoke right role rollback rollup routine row rows savepoint schema scroll search second section select session session_user set sets signal similar size some space specific specifictype sql sqlexception sqlstate sqlwarning start state static system_user table temporary then timezone_hour timezone_minute to trailing transaction translation treat trigger under undo union unique unnest until update usage user using value values view when whenever where while with without work write year zone ","array binary bit boolean char character clob date decimal double float int integer interval large national nchar nclob numeric object precision real smallint time timestamp varchar varying ")};function Q7(t,e,i,n){let O={};for(let r in qu)O[r]=(t.hasOwnProperty(r)?t:qu)[r];return e&&(O.words=RX(e,i||"",n)),O}function ZX(t){return new ie(e=>{var i;let{next:n}=e;if(e.advance(),Jn(n,Vu)){for(;Jn(e.next,Vu);)e.advance();e.acceptToken(N8)}else if(n==36&&t.doubleDollarQuotedStrings){let O=zu(e,"");e.next==36&&(e.advance(),u7(e,O),e.acceptToken(BO))}else if(n==39||n==34&&t.doubleQuotedStrings)Kn(e,n,t.backslashEscapes),e.acceptToken(BO);else if(n==35&&t.hashComments||n==47&&e.next==47&&t.slashComments)_X(e),e.acceptToken(bX);else if(n==45&&e.next==45&&(!t.spaceAfterDashes||e.peek(1)==32))_X(e),e.acceptToken(bX);else if(n==47&&e.next==42){e.advance();for(let O=1;;){let r=e.next;if(e.next<0)break;if(e.advance(),r==42&&e.next==47){if(O--,e.advance(),!O)break}else r==47&&e.next==42&&(O++,e.advance())}e.acceptToken(B8)}else if((n==101||n==69)&&e.next==39)e.advance(),Kn(e,39,!0),e.acceptToken(BO);else if((n==110||n==78)&&e.next==39&&t.charSetCasts)e.advance(),Kn(e,39,t.backslashEscapes),e.acceptToken(BO);else if(n==95&&t.charSetCasts)for(let O=0;;O++){if(e.next==39&&O>1){e.advance(),Kn(e,39,t.backslashEscapes),e.acceptToken(BO);break}if(!Yu(e.next))break;e.advance()}else if(t.plsqlQuotingMechanism&&(n==113||n==81)&&e.next==39&&e.peek(1)>0&&!Jn(e.peek(1),Vu)){let O=e.peek(1);e.advance(2),f7(e,O),e.acceptToken(BO)}else if(Jn(n,t.identifierQuotes)){const O=n==91?93:n;Kn(e,O,!1),e.acceptToken(l7)}else if(n==40)e.acceptToken(K8);else if(n==41)e.acceptToken(J8);else if(n==123)e.acceptToken(e7);else if(n==125)e.acceptToken(t7);else if(n==91)e.acceptToken(i7);else if(n==93)e.acceptToken(n7);else if(n==59)e.acceptToken(O7);else if(t.unquotedBitLiterals&&n==48&&e.next==98)e.advance(),vX(e),e.acceptToken(wX);else if((n==98||n==66)&&(e.next==39||e.next==34)){const O=e.next;e.advance(),t.treatBitsAsBytes?(Kn(e,O,t.backslashEscapes),e.acceptToken(c7)):(vX(e,O),e.acceptToken(wX))}else if(n==48&&(e.next==120||e.next==88)||(n==120||n==88)&&e.next==39){let O=e.next==39;for(e.advance();d7(e.next);)e.advance();O&&e.next==39&&e.advance(),e.acceptToken(Zu)}else if(n==46&&e.next>=48&&e.next<=57)kX(e,!0),e.acceptToken(Zu);else if(n==46)e.acceptToken(r7);else if(n>=48&&n<=57)kX(e,!1),e.acceptToken(Zu);else if(Jn(n,t.operatorChars)){for(;Jn(e.next,t.operatorChars);)e.advance();e.acceptToken(s7)}else if(Jn(n,t.specialVar))e.next==n&&e.advance(),$7(e),e.acceptToken(a7);else if(n==58||n==44)e.acceptToken(o7);else if(Yu(n)){let O=zu(e,String.fromCharCode(n));e.acceptToken(e.next==46||e.peek(-O.length-1)==46?yX:(i=t.words[O.toLowerCase()])!==null&&i!==void 0?i:yX)}})}const YX=ZX(qu),p7=ht.deserialize({version:14,states:"%vQ]QQOOO#wQRO'#DSO$OQQO'#CwO%eQQO'#CxO%lQQO'#CyO%sQQO'#CzOOQQ'#DS'#DSOOQQ'#C}'#C}O'UQRO'#C{OOQQ'#Cv'#CvOOQQ'#C|'#C|Q]QQOOQOQQOOO'`QQO'#DOO(xQRO,59cO)PQQO,59cO)UQQO'#DSOOQQ,59d,59dO)cQQO,59dOOQQ,59e,59eO)jQQO,59eOOQQ,59f,59fO)qQQO,59fOOQQ-E6{-E6{OOQQ,59b,59bOOQQ-E6z-E6zOOQQ,59j,59jOOQQ-E6|-E6|O+VQRO1G.}O+^QQO,59cOOQQ1G/O1G/OOOQQ1G/P1G/POOQQ1G/Q1G/QP+kQQO'#C}O+rQQO1G.}O)PQQO,59cO,PQQO'#Cw",stateData:",[~OtOSPOSQOS~ORUOSUOTUOUUOVROXSOZTO]XO^QO_UO`UOaPObPOcPOdUOeUOfUOgUOhUO~O^]ORvXSvXTvXUvXVvXXvXZvX]vX_vX`vXavXbvXcvXdvXevXfvXgvXhvX~OsvX~P!jOa_Ob_Oc_O~ORUOSUOTUOUUOVROXSOZTO^tO_UO`UOa`Ob`Oc`OdUOeUOfUOgUOhUO~OWaO~P$ZOYcO~P$ZO[eO~P$ZORUOSUOTUOUUOVROXSOZTO^QO_UO`UOaPObPOcPOdUOeUOfUOgUOhUO~O]hOsoX~P%zOajObjOcjO~O^]ORkaSkaTkaUkaVkaXkaZka]ka_ka`kaakabkackadkaekafkagkahka~Oska~P'kO^]O~OWvXYvX[vX~P!jOWnO~P$ZOYoO~P$ZO[pO~P$ZO^]ORkiSkiTkiUkiVkiXkiZki]ki_ki`kiakibkickidkiekifkigkihki~Oski~P)xOWkaYka[ka~P'kO]hO~P$ZOWkiYki[ki~P)xOasObsOcsO~O",goto:"#hwPPPPPPPPPPPPPPPPPPPPPPPPPPx||||!Y!^!d!xPPP#[TYOZeUORSTWZbdfqT[OZQZORiZSWOZQbRQdSQfTZgWbdfqQ^PWk^lmrQl_Qm`RrseVORSTWZbdfq",nodeNames:"⚠ LineComment BlockComment String Number Bool Null ( ) { } [ ] ; . Operator Punctuation SpecialVar Identifier QuotedIdentifier Keyword Type Bits Bytes Builtin Script Statement CompositeIdentifier Parens Braces Brackets Statement",maxTerm:38,nodeProps:[["isolate",-4,1,2,3,19,""]],skippedNodes:[0,1,2],repeatNodeCount:3,tokenData:"RORO",tokenizers:[0,YX],topRules:{Script:[0,25]},tokenPrec:0});function Uu(t){let e=t.cursor().moveTo(t.from,-1);for(;/Comment/.test(e.name);)e.moveTo(e.from,-1);return e.node}function Ts(t,e){let i=t.sliceString(e.from,e.to),n=/^([`'"\[])(.*)([`'"\]])$/.exec(i);return n?n[2]:i}function sl(t){return t&&(t.name=="Identifier"||t.name=="QuotedIdentifier")}function m7(t,e){if(e.name=="CompositeIdentifier"){let i=[];for(let n=e.firstChild;n;n=n.nextSibling)sl(n)&&i.push(Ts(t,n));return i}return[Ts(t,e)]}function zX(t,e){for(let i=[];;){if(!e||e.name!=".")return i;let n=Uu(e);if(!sl(n))return i;i.unshift(Ts(t,n)),e=Uu(n)}}function g7(t,e){let i=$e(t).resolveInner(e,-1),n=S7(t.doc,i);return i.name=="Identifier"||i.name=="QuotedIdentifier"||i.name=="Keyword"?{from:i.from,quoted:i.name=="QuotedIdentifier"?t.doc.sliceString(i.from,i.from+1):null,parents:zX(t.doc,Uu(i)),aliases:n}:i.name=="."?{from:e,quoted:null,parents:zX(t.doc,i),aliases:n}:{from:e,quoted:null,parents:[],empty:!0,aliases:n}}const P7=new Set("where group having order union intersect except all distinct limit offset fetch for".split(" "));function S7(t,e){let i;for(let O=e;!i;O=O.parent){if(!O)return null;O.name=="Statement"&&(i=O)}let n=null;for(let O=i.firstChild,r=!1,s=null;O;O=O.nextSibling){let o=O.name=="Keyword"?t.sliceString(O.from,O.to).toLowerCase():null,a=null;if(!r)r=o=="from";else if(o=="as"&&s&&sl(O.nextSibling))a=Ts(t,O.nextSibling);else{if(o&&P7.has(o))break;s&&sl(O)&&(a=Ts(t,O))}a&&(n||(n=Object.create(null)),n[a]=m7(t,s)),s=/Identifier$/.test(O.name)?O:null}return n}function X7(t,e,i){return i.map(n=>({...n,label:n.label[0]==t?n.label:t+n.label+e,apply:void 0}))}const b7=/^\w*$/,y7=/^[`'"\[]?\w*[`'"\]]?$/;function VX(t){return t.self&&typeof t.self.label=="string"}class Wu{constructor(e,i){this.idQuote=e,this.idCaseInsensitive=i,this.list=[],this.children=void 0}child(e){let i=this.children||(this.children=Object.create(null)),n=i[e];return n||(e&&!this.list.some(O=>O.label==e)&&this.list.push(qX(e,"type",this.idQuote,this.idCaseInsensitive)),i[e]=new Wu(this.idQuote,this.idCaseInsensitive))}maybeChild(e){return this.children?this.children[e]:null}addCompletion(e){let i=this.list.findIndex(n=>n.label==e.label);i>-1?this.list[i]=e:this.list.push(e)}addCompletions(e){for(let i of e)this.addCompletion(typeof i=="string"?qX(i,"property",this.idQuote,this.idCaseInsensitive):i)}addNamespace(e){Array.isArray(e)?this.addCompletions(e):VX(e)?this.addNamespace(e.children):this.addNamespaceObject(e)}addNamespaceObject(e){for(let i of Object.keys(e)){let n=e[i],O=null,r=i.replace(/\\?\./g,o=>o=="."?"\0":o).split("\0"),s=this;VX(n)&&(O=n.self,n=n.children);for(let o=0;o{let{parents:h,from:d,quoted:u,empty:$,aliases:Q}=g7(c.state,c.pos);if($&&!c.explicit)return null;Q&&h.length==1&&(h=Q[h[0]]||h);let p=a;for(let P of h){for(;!p.children||!p.children[P];)if(p==a&&l)p=l;else if(p==l&&n)p=p.child(n);else return null;let g=p.maybeChild(P);if(!g)return null;p=g}let m=p.list;if(p==a&&Q&&(m=m.concat(Object.keys(Q).map(P=>({label:P,type:"constant"})))),u){let P=u[0],g=UX(P),b=c.state.sliceDoc(c.pos,c.pos+1)==g;return{from:d,to:b?c.pos+1:void 0,options:X7(P,g,m),validFor:y7}}else return{from:d,options:m,validFor:b7}}}function T7(t){return t==TX?"type":t==xX?"keyword":"variable"}function w7(t,e,i){let n=Object.keys(t).map(O=>i(e?O.toUpperCase():O,T7(t[O])));return md(["QuotedIdentifier","String","LineComment","BlockComment","."],Ya(n))}let v7=p7.configure({props:[lt.add({Statement:Le()}),ct.add({Statement(t,e){return{from:Math.min(t.from+100,e.doc.lineAt(t.from).to),to:t.to}},BlockComment(t){return{from:t.from+2,to:t.to-2}}}),ot({Keyword:f.keyword,Type:f.typeName,Builtin:f.standard(f.name),Bits:f.number,Bytes:f.string,Bool:f.bool,Null:f.null,Number:f.number,String:f.string,Identifier:f.name,QuotedIdentifier:f.special(f.string),SpecialVar:f.special(f.name),LineComment:f.lineComment,BlockComment:f.blockComment,Operator:f.operator,"Semi Punctuation":f.punctuation,"( )":f.paren,"{ }":f.brace,"[ ]":f.squareBracket})]});class ol{constructor(e,i,n){this.dialect=e,this.language=i,this.spec=n}get extension(){return this.language.extension}configureLanguage(e,i){return new ol(this.dialect,this.language.configure(e,i),this.spec)}static define(e){let i=Q7(e,e.keywords,e.types,e.builtin),n=at.define({name:"sql",parser:v7.configure({tokenizers:[{from:YX,to:ZX(i)}]}),languageData:{commentTokens:{line:"--",block:{open:"/*",close:"*/"}},closeBrackets:{brackets:["(","[","{","'",'"',"`"]}}});return new ol(i,n,e)}}function k7(t,e){return{label:t,type:e,boost:-1}}function _7(t,e=!1,i){return w7(t.dialect.words,e,i||k7)}function R7(t){return t.schema?x7(t.schema,t.tables,t.schemas,t.defaultTable,t.defaultSchema,t.dialect||Cu):()=>null}function Z7(t){return t.schema?(t.dialect||Cu).language.data.of({autocomplete:R7(t)}):[]}function Y7(t={}){let e=t.dialect||Cu;return new Fe(e.language,[Z7(t),e.language.data.of({autocomplete:_7(e,t.upperCaseKeywords,t.keywordCompletion)})])}const Cu=ol.define({}),ju=1,z7=2,V7=3,q7=4,U7=5,W7=36,C7=37,j7=38,G7=11,E7=13;function I7(t){return t==45||t==46||t==58||t>=65&&t<=90||t==95||t>=97&&t<=122||t>=161}function A7(t){return t==9||t==10||t==13||t==32}let WX=null,CX=null,jX=0;function Gu(t,e){let i=t.pos+e;if(CX==t&&jX==i)return WX;for(;A7(t.peek(e));)e++;let n="";for(;;){let O=t.peek(e);if(!I7(O))break;n+=String.fromCharCode(O),e++}return CX=t,jX=i,WX=n||null}function GX(t,e){this.name=t,this.parent=e}const M7=new AO({start:null,shift(t,e,i,n){return e==ju?new GX(Gu(n,1)||"",t):t},reduce(t,e){return e==G7&&t?t.parent:t},reuse(t,e,i,n){let O=e.type.id;return O==ju||O==E7?new GX(Gu(n,1)||"",t):t},strict:!1}),D7=new ie((t,e)=>{if(t.next==60){if(t.advance(),t.next==47){t.advance();let i=Gu(t,0);if(!i)return t.acceptToken(U7);if(e.context&&i==e.context.name)return t.acceptToken(z7);for(let n=e.context;n;n=n.parent)if(n.name==i)return t.acceptToken(V7,-2);t.acceptToken(q7)}else if(t.next!=33&&t.next!=63)return t.acceptToken(ju)}},{contextual:!0});function Eu(t,e){return new ie(i=>{let n=0,O=e.charCodeAt(0);e:for(;!(i.next<0);i.advance(),n++)if(i.next==O){for(let r=1;r"),N7=Eu(C7,"?>"),B7=Eu(j7,"]]>"),F7=ot({Text:f.content,"StartTag StartCloseTag EndTag SelfCloseEndTag":f.angleBracket,TagName:f.tagName,"MismatchedCloseTag/TagName":[f.tagName,f.invalid],AttributeName:f.attributeName,AttributeValue:f.attributeValue,Is:f.definitionOperator,"EntityReference CharacterReference":f.character,Comment:f.blockComment,ProcessingInst:f.processingInstruction,DoctypeDecl:f.documentMeta,Cdata:f.special(f.string)}),H7=ht.deserialize({version:14,states:",lOQOaOOOrOxO'#CfOzOpO'#CiO!tOaO'#CgOOOP'#Cg'#CgO!{OrO'#CrO#TOtO'#CsO#]OpO'#CtOOOP'#DT'#DTOOOP'#Cv'#CvQQOaOOOOOW'#Cw'#CwO#eOxO,59QOOOP,59Q,59QOOOO'#Cx'#CxO#mOpO,59TO#uO!bO,59TOOOP'#C|'#C|O$TOaO,59RO$[OpO'#CoOOOP,59R,59ROOOQ'#C}'#C}O$dOrO,59^OOOP,59^,59^OOOS'#DO'#DOO$lOtO,59_OOOP,59_,59_O$tOpO,59`O$|OpO,59`OOOP-E6t-E6tOOOW-E6u-E6uOOOP1G.l1G.lOOOO-E6v-E6vO%UO!bO1G.oO%UO!bO1G.oO%dOpO'#CkO%lO!bO'#CyO%zO!bO1G.oOOOP1G.o1G.oOOOP1G.w1G.wOOOP-E6z-E6zOOOP1G.m1G.mO&VOpO,59ZO&_OpO,59ZOOOQ-E6{-E6{OOOP1G.x1G.xOOOS-E6|-E6|OOOP1G.y1G.yO&gOpO1G.zO&gOpO1G.zOOOP1G.z1G.zO&oO!bO7+$ZO&}O!bO7+$ZOOOP7+$Z7+$ZOOOP7+$c7+$cO'YOpO,59VO'bOpO,59VO'mO!bO,59eOOOO-E6w-E6wO'{OpO1G.uO'{OpO1G.uOOOP1G.u1G.uO(TOpO7+$fOOOP7+$f7+$fO(]O!bO<c!|;'S(o;'S;=`)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iLTX|W!O`Or(ors&osv(owx'}x#T(o#T#UH`#U;'S(o;'S;=`)]<%lO(oiLwX|W!O`Or(ors&osv(owx'}x#c(o#c#dMd#d;'S(o;'S;=`)]<%lO(oiMkX|W!O`Or(ors&osv(owx'}x#V(o#V#WNW#W;'S(o;'S;=`)]<%lO(oiN_X|W!O`Or(ors&osv(owx'}x#h(o#h#iNz#i;'S(o;'S;=`)]<%lO(oi! RX|W!O`Or(ors&osv(owx'}x#m(o#m#n! n#n;'S(o;'S;=`)]<%lO(oi! uX|W!O`Or(ors&osv(owx'}x#d(o#d#e!!b#e;'S(o;'S;=`)]<%lO(oi!!iX|W!O`Or(ors&osv(owx'}x#X(o#X#Y?y#Y;'S(o;'S;=`)]<%lO(oi!#_V!SP|W!O`Or(ors&osv(owx'}x;'S(o;'S;=`)]<%lO(ok!$PXaQVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_;'S$q;'S;=`)c<%lO$qo!$wX[UVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_;'S$q;'S;=`)c<%lO$qk!%mZVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_!`$q!`!a!&`!a;'S$q;'S;=`)c<%lO$qk!&kX!RQVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_;'S$q;'S;=`)c<%lO$qk!'aZVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_#P$q#P#Q!(S#Q;'S$q;'S;=`)c<%lO$qk!(]ZVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_!`$q!`!a!)O!a;'S$q;'S;=`)c<%lO$qk!)ZXxQVP|W!O`Or$qrs%gsv$qwx'^x!^$q!^!_(o!_;'S$q;'S;=`)c<%lO$q",tokenizers:[D7,L7,N7,B7,0,1,2,3,4],topRules:{Document:[0,6]},tokenPrec:0});function al(t,e){let i=e&&e.getChild("TagName");return i?t.sliceString(i.from,i.to):""}function Iu(t,e){let i=e&&e.firstChild;return!i||i.name!="OpenTag"?"":al(t,i)}function K7(t,e,i){let n=e&&e.getChildren("Attribute").find(r=>r.from<=i&&r.to>=i),O=n&&n.getChild("AttributeName");return O?t.sliceString(O.from,O.to):""}function Au(t){for(let e=t&&t.parent;e;e=e.parent)if(e.name=="Element")return e;return null}function J7(t,e){var i;let n=$e(t).resolveInner(e,-1),O=null;for(let r=n;!O&&r.parent;r=r.parent)(r.name=="OpenTag"||r.name=="CloseTag"||r.name=="SelfClosingTag"||r.name=="MismatchedCloseTag")&&(O=r);if(O&&(O.to>e||O.lastChild.type.isError)){let r=O.parent;if(n.name=="TagName")return O.name=="CloseTag"||O.name=="MismatchedCloseTag"?{type:"closeTag",from:n.from,context:r}:{type:"openTag",from:n.from,context:Au(r)};if(n.name=="AttributeName")return{type:"attrName",from:n.from,context:O};if(n.name=="AttributeValue")return{type:"attrValue",from:n.from,context:O};let s=n==O||n.name=="Attribute"?n.childBefore(e):n;return s?.name=="StartTag"?{type:"openTag",from:e,context:Au(r)}:s?.name=="StartCloseTag"&&s.to<=e?{type:"closeTag",from:e,context:r}:s?.name=="Is"?{type:"attrValue",from:e,context:O}:s?{type:"attrName",from:e,context:O}:null}else if(n.name=="StartCloseTag")return{type:"closeTag",from:e,context:n.parent};for(;n.parent&&n.to==e&&!(!((i=n.lastChild)===null||i===void 0)&&i.type.isError);)n=n.parent;return n.name=="Element"||n.name=="Text"||n.name=="Document"?{type:"tag",from:e,context:n.name=="Element"?n:Au(n)}:null}class e6{constructor(e,i,n){this.attrs=i,this.attrValues=n,this.children=[],this.name=e.name,this.completion=Object.assign(Object.assign({type:"type"},e.completion||{}),{label:this.name}),this.openCompletion=Object.assign(Object.assign({},this.completion),{label:"<"+this.name}),this.closeCompletion=Object.assign(Object.assign({},this.completion),{label:"",boost:2}),this.closeNameCompletion=Object.assign(Object.assign({},this.completion),{label:this.name+">"}),this.text=e.textContent?e.textContent.map(O=>({label:O,type:"text"})):[]}}const Mu=/^[:\-\.\w\u00b7-\uffff]*$/;function EX(t){return Object.assign(Object.assign({type:"property"},t.completion||{}),{label:t.name})}function IX(t){return typeof t=="string"?{label:`"${t}"`,type:"constant"}:/^"/.test(t.label)?t:Object.assign(Object.assign({},t),{label:`"${t.label}"`})}function t6(t,e){let i=[],n=[],O=Object.create(null);for(let a of e){let l=EX(a);i.push(l),a.global&&n.push(l),a.values&&(O[a.name]=a.values.map(IX))}let r=[],s=[],o=Object.create(null);for(let a of t){let l=n,c=O;a.attributes&&(l=l.concat(a.attributes.map(d=>typeof d=="string"?i.find(u=>u.label==d)||{label:d,type:"property"}:(d.values&&(c==O&&(c=Object.create(c)),c[d.name]=d.values.map(IX)),EX(d)))));let h=new e6(a,l,c);o[h.name]=h,r.push(h),a.top&&s.push(h)}s.length||(s=r);for(let a=0;a{var l;let{doc:c}=a.state,h=J7(a.state,a.pos);if(!h||h.type=="tag"&&!a.explicit)return null;let{type:d,from:u,context:$}=h;if(d=="openTag"){let Q=s,p=Iu(c,$);if(p){let m=o[p];Q=m?.children||r}return{from:u,options:Q.map(m=>m.completion),validFor:Mu}}else if(d=="closeTag"){let Q=Iu(c,$);return Q?{from:u,to:a.pos+(c.sliceString(a.pos,a.pos+1)==">"?1:0),options:[((l=o[Q])===null||l===void 0?void 0:l.closeNameCompletion)||{label:Q+">",type:"type"}],validFor:Mu}:null}else if(d=="attrName"){let Q=o[al(c,$)];return{from:u,options:Q?.attrs||n,validFor:Mu}}else if(d=="attrValue"){let Q=K7(c,$,u);if(!Q)return null;let p=o[al(c,$)],m=(p?.attrValues||O)[Q];return!m||!m.length?null:{from:u,to:a.pos+(c.sliceString(a.pos,a.pos+1)=='"'?1:0),options:m,validFor:/^"[^"]*"?$/}}else if(d=="tag"){let Q=Iu(c,$),p=o[Q],m=[],P=$&&$.lastChild;Q&&(!P||P.name!="CloseTag"||al(c,P)!=Q)&&m.push(p?p.closeCompletion:{label:"",type:"type",boost:2});let g=m.concat((p?.children||($?r:s)).map(b=>b.openCompletion));if($&&p?.text.length){let b=$.firstChild;b.to>a.pos-20&&!/\S/.test(a.state.sliceDoc(b.to,a.pos))&&(g=g.concat(p.text))}return{from:u,options:g,validFor:/^<\/?[:\-\.\w\u00b7-\uffff]*$/}}else return null}}const Du=at.define({name:"xml",parser:H7.configure({props:[lt.add({Element(t){let e=/^\s*<\//.test(t.textAfter);return t.lineIndent(t.node.from)+(e?0:t.unit)},"OpenTag CloseTag SelfClosingTag"(t){return t.column(t.node.from)+t.unit}}),ct.add({Element(t){let e=t.firstChild,i=t.lastChild;return!e||e.name!="OpenTag"?null:{from:e.to,to:i.name=="CloseTag"?i.from:t.to}}}),Fh.add({"OpenTag CloseTag":t=>t.getChild("TagName")})]}),languageData:{commentTokens:{block:{open:""}},indentOnInput:/^\s*<\/$/}});function i6(t={}){let e=[Du.data.of({autocomplete:t6(t.elements||[],t.attributes||[])})];return t.autoCloseTags!==!1&&e.push(n6),new Fe(Du,e)}function AX(t,e,i=t.length){if(!e)return"";let n=e.firstChild,O=n&&n.getChild("TagName");return O?t.sliceString(O.from,Math.min(O.to,i)):""}const n6=R.inputHandler.of((t,e,i,n,O)=>{if(t.composing||t.state.readOnly||e!=i||n!=">"&&n!="/"||!Du.isActiveAt(t.state,e,-1))return!1;let r=O(),{state:s}=r,o=s.changeByRange(a=>{var l,c,h;let{head:d}=a,u=s.doc.sliceString(d-1,d)==n,$=$e(s).resolveInner(d,-1),Q;if(u&&n==">"&&$.name=="EndTag"){let p=$.parent;if(((c=(l=p.parent)===null||l===void 0?void 0:l.lastChild)===null||c===void 0?void 0:c.name)!="CloseTag"&&(Q=AX(s.doc,p.parent,d))){let m=d+(s.doc.sliceString(d,d+1)===">"?1:0),P=``;return{range:a,changes:{from:d,to:m,insert:P}}}}else if(u&&n=="/"&&$.name=="StartCloseTag"){let p=$.parent;if($.from==d-2&&((h=p.lastChild)===null||h===void 0?void 0:h.name)!="CloseTag"&&(Q=AX(s.doc,p,d))){let m=d+(s.doc.sliceString(d,d+1)===">"?1:0),P=`${Q}>`;return{range:x.cursor(d+P.length,-1),changes:{from:d,to:m,insert:P}}}}return{range:a}});return o.changes.empty?!1:(t.dispatch([r,s.update(o,{userEvent:"input.complete",scrollIntoView:!0})]),!0)}),FO=63,MX=64,O6=1,r6=2,DX=3,s6=4,LX=5,o6=6,a6=7,NX=65,l6=66,c6=8,h6=9,d6=10,u6=11,f6=12,BX=13,$6=19,Q6=20,p6=29,m6=33,g6=34,P6=47,S6=0,Lu=1,Nu=2,ws=3,Bu=4;class eO{constructor(e,i,n){this.parent=e,this.depth=i,this.type=n,this.hash=(e?e.hash+e.hash<<8:0)+i+(i<<4)+n}}eO.top=new eO(null,-1,S6);function vs(t,e){for(let i=0,n=e-t.pos-1;;n--,i++){let O=t.peek(n);if(nn(O)||O==-1)return i}}function Fu(t){return t==32||t==9}function nn(t){return t==10||t==13}function FX(t){return Fu(t)||nn(t)}function tO(t){return t<0||FX(t)}const X6=new AO({start:eO.top,reduce(t,e){return t.type==ws&&(e==Q6||e==g6)?t.parent:t},shift(t,e,i,n){if(e==DX)return new eO(t,vs(n,n.pos),Lu);if(e==NX||e==LX)return new eO(t,vs(n,n.pos),Nu);if(e==FO)return t.parent;if(e==$6||e==m6)return new eO(t,0,ws);if(e==BX&&t.type==Bu)return t.parent;if(e==P6){let O=/[1-9]/.exec(n.read(n.pos,i.pos));if(O)return new eO(t,t.depth+ +O[0],Bu)}return t},hash(t){return t.hash}});function HO(t,e,i=0){return t.peek(i)==e&&t.peek(i+1)==e&&t.peek(i+2)==e&&tO(t.peek(i+3))}const b6=new ie((t,e)=>{if(t.next==-1&&e.canShift(MX))return t.acceptToken(MX);let i=t.peek(-1);if((nn(i)||i<0)&&e.context.type!=ws){if(HO(t,45))if(e.canShift(FO))t.acceptToken(FO);else return t.acceptToken(O6,3);if(HO(t,46))if(e.canShift(FO))t.acceptToken(FO);else return t.acceptToken(r6,3);let n=0;for(;t.next==32;)n++,t.advance();(n{if(e.context.type==ws){t.next==63&&(t.advance(),tO(t.next)&&t.acceptToken(a6));return}if(t.next==45)t.advance(),tO(t.next)&&t.acceptToken(e.context.type==Lu&&e.context.depth==vs(t,t.pos-1)?s6:DX);else if(t.next==63)t.advance(),tO(t.next)&&t.acceptToken(e.context.type==Nu&&e.context.depth==vs(t,t.pos-1)?o6:LX);else{let i=t.pos;for(;;)if(Fu(t.next)){if(t.pos==i)return;t.advance()}else if(t.next==33)JX(t);else if(t.next==38)Hu(t);else if(t.next==42){Hu(t);break}else if(t.next==39||t.next==34){if(Ku(t,!0))break;return}else if(t.next==91||t.next==123){if(!T6(t))return;break}else{eb(t,!0,!1,0);break}for(;Fu(t.next);)t.advance();if(t.next==58){if(t.pos==i&&e.canShift(p6))return;let n=t.peek(1);tO(n)&&t.acceptTokenTo(e.context.type==Nu&&e.context.depth==vs(t,i)?l6:NX,i)}}},{contextual:!0});function x6(t){return t>32&&t<127&&t!=34&&t!=37&&t!=44&&t!=60&&t!=62&&t!=92&&t!=94&&t!=96&&t!=123&&t!=124&&t!=125}function HX(t){return t>=48&&t<=57||t>=97&&t<=102||t>=65&&t<=70}function KX(t,e){return t.next==37?(t.advance(),HX(t.next)&&t.advance(),HX(t.next)&&t.advance(),!0):x6(t.next)||e&&t.next==44?(t.advance(),!0):!1}function JX(t){if(t.advance(),t.next==60){for(t.advance();;)if(!KX(t,!0)){t.next==62&&t.advance();break}}else for(;KX(t,!1););}function Hu(t){for(t.advance();!tO(t.next)&&ll(t.next)!="f";)t.advance()}function Ku(t,e){let i=t.next,n=!1,O=t.pos;for(t.advance();;){let r=t.next;if(r<0)break;if(t.advance(),r==i)if(r==39)if(t.next==39)t.advance();else break;else break;else if(r==92&&i==34)t.next>=0&&t.advance();else if(nn(r)){if(e)return!1;n=!0}else if(e&&t.pos>=O+1024)return!1}return!n}function T6(t){for(let e=[],i=t.pos+1024;;)if(t.next==91||t.next==123)e.push(t.next),t.advance();else if(t.next==39||t.next==34){if(!Ku(t,!0))return!1}else if(t.next==93||t.next==125){if(e[e.length-1]!=t.next-2)return!1;if(e.pop(),t.advance(),!e.length)return!0}else{if(t.next<0||t.pos>i||nn(t.next))return!1;t.advance()}}const w6="iiisiiissisfissssssssssssisssiiissssssssssssssssssssssssssfsfssissssssssssssssssssssssssssfif";function ll(t){return t<33?"u":t>125?"s":w6[t-33]}function Ju(t,e){let i=ll(t);return i!="u"&&!(e&&i=="f")}function eb(t,e,i,n){if(ll(t.next)=="s"||(t.next==63||t.next==58||t.next==45)&&Ju(t.peek(1),i))t.advance();else return!1;let O=t.pos;for(;;){let r=t.next,s=0,o=n+1;for(;FX(r);){if(nn(r)){if(e)return!1;o=0}else o++;r=t.peek(++s)}if(!(r>=0&&(r==58?Ju(t.peek(s+1),i):r==35?t.peek(s-1)!=32:Ju(r,i)))||!i&&o<=n||o==0&&!i&&(HO(t,45,s)||HO(t,46,s)))break;if(e&&ll(r)=="f")return!1;for(let l=s;l>=0;l--)t.advance();if(e&&t.pos>O+1024)return!1}return!0}const v6=new ie((t,e)=>{if(t.next==33)JX(t),t.acceptToken(f6);else if(t.next==38||t.next==42){let i=t.next==38?d6:u6;Hu(t),t.acceptToken(i)}else t.next==39||t.next==34?(Ku(t,!1),t.acceptToken(h6)):eb(t,!1,e.context.type==ws,e.context.depth)&&t.acceptToken(c6)}),k6=new ie((t,e)=>{let i=e.context.type==Bu?e.context.depth:-1,n=t.pos;e:for(;;){let O=0,r=t.next;for(;r==32;)r=t.peek(++O);if(!O&&(HO(t,45,O)||HO(t,46,O))||!nn(r)&&(i<0&&(i=Math.max(e.context.depth+1,O)),OYAN>Y",stateData:";S~O!fOS!gOS^OS~OP_OQbORSOTUOWROXROYYOZZO[XOcPOqQO!PVO!V[O!cTO~O`cO~P]OVkOWROXROYeOZfO[dOcPOmhOqQO~OboO~P!bOVtOWROXROYeOZfO[dOcPOmrOqQO~OpwO~P#WORSOTUOWROXROYYOZZO[XOcPOqQO!PVO!cTO~OSvP!avP!bvP~P#|OWROXROYeOZfO[dOcPOqQO~OmzO~P%OOm!OOUzP!azP!bzP!dz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? ? Literal QuotedLiteral Anchor Alias Tag BlockLiteralContent Comment Stream BOM Document ] [ FlowSequence Item Tagged Anchored Anchored Tagged FlowMapping Pair Key : Pair , } { FlowMapping Pair Pair BlockSequence Item Item BlockMapping Pair Pair Key Pair Pair BlockLiteral BlockLiteralHeader Tagged Anchored Anchored Tagged Directive DirectiveName DirectiveContent Document",maxTerm:74,context:X6,nodeProps:[["isolate",-3,8,9,14,""],["openedBy",18,"[",32,"{"],["closedBy",19,"]",33,"}"]],propSources:[_6],skippedNodes:[0],repeatNodeCount:6,tokenData:"-Y~RnOX#PXY$QYZ$]Z]#P]^$]^p#Ppq$Qqs#Pst$btu#Puv$yv|#P|}&e}![#P![!]'O!]!`#P!`!a'i!a!}#P!}#O*g#O#P#P#P#Q+Q#Q#o#P#o#p+k#p#q'i#q#r,U#r;'S#P;'S;=`#z<%l?HT#P?HT?HU,o?HUO#PQ#UU!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PQ#kTOY#PZs#Pt;'S#P;'S;=`#z<%lO#PQ#}P;=`<%l#P~$VQ!f~XY$Qpq$Q~$bO!g~~$gS^~OY$bZ;'S$b;'S;=`$s<%lO$b~$vP;=`<%l$bR%OX!WQOX%kXY#PZ]%k]^#P^p%kpq#hq;'S%k;'S;=`&_<%lO%kR%rX!WQ!VPOX%kXY#PZ]%k]^#P^p%kpq#hq;'S%k;'S;=`&_<%lO%kR&bP;=`<%l%kR&lUoP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR'VUmP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR'p[!PP!WQOY#PZp#Ppq#hq{#P{|(f|}#P}!O(f!O!R#P!R![)p![;'S#P;'S;=`#z<%lO#PR(mW!PP!WQOY#PZp#Ppq#hq!R#P!R![)V![;'S#P;'S;=`#z<%lO#PR)^U!PP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR)wY!PP!WQOY#PZp#Ppq#hq{#P{|)V|}#P}!O)V!O;'S#P;'S;=`#z<%lO#PR*nUcP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR+XUbP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR+rUqP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR,]UpP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR,vU`P!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#P",tokenizers:[b6,y6,v6,k6,0,1],topRules:{Stream:[0,15]},tokenPrec:0}),Z6=ht.deserialize({version:14,states:"!vOQOPOOO]OPO'#C_OhOPO'#C^OOOO'#Cc'#CcOpOPO'#CaQOOOOOO{OPOOOOOO'#Cb'#CbO!WOPO'#C`O!`OPO,58xOOOO-E6a-E6aOOOO-E6`-E6`OOOO'#C_'#C_OOOO1G.d1G.d",stateData:"!h~OXPOYROWTP~OWVXXRXYRX~OYVOXSP~OXROYROWTX~OXROYROWTP~OYVOXSX~OX[O~OXY~",goto:"vWPPX[beioRUOQQOR]XRXQTTOUQWQRZWSSOURYS",nodeNames:"⚠ Document Frontmatter DashLine FrontmatterContent Body",maxTerm:10,skippedNodes:[0],repeatNodeCount:2,tokenData:"$z~RXOYnYZ!^Z]n]^!^^}n}!O!i!O;'Sn;'S;=`!c<%lOn~qXOYnYZ!^Z]n]^!^^;'Sn;'S;=`!c<%l~n~On~~!^~!cOY~~!fP;=`<%ln~!lZOYnYZ!^Z]n]^!^^}n}!O#_!O;'Sn;'S;=`!c<%l~n~On~~!^~#bZOYnYZ!^Z]n]^!^^}n}!O$T!O;'Sn;'S;=`!c<%l~n~On~~!^~$WXOYnYZ$sZ]n]^$s^;'Sn;'S;=`!c<%l~n~On~~$s~$zOX~Y~",tokenizers:[0],topRules:{Document:[0,1]},tokenPrec:67}),tb=at.define({name:"yaml",parser:R6.configure({props:[lt.add({Stream:t=>{for(let e=t.node.resolve(t.pos,-1);e&&e.to>=t.pos;e=e.parent){if(e.name=="BlockLiteralContent"&&e.fromt.pos)return null}}return null},FlowMapping:Ni({closing:"}"}),FlowSequence:Ni({closing:"]"})}),ct.add({"FlowMapping FlowSequence":Ri,"Item Pair BlockLiteral":(t,e)=>({from:e.doc.lineAt(t.from).to,to:t.to})})]}),languageData:{commentTokens:{line:"#"},indentOnInput:/^\s*[\]\}]$/}});function Y6(){return new Fe(tb)}const z6=at.define({name:"yaml-frontmatter",parser:Z6.configure({props:[ot({DashLine:f.meta})]})});function V6(t){let{language:e,support:i}=t.content instanceof Fe?t.content:{language:t.content,support:[]};return new Fe(z6.configure({wrap:aa(n=>n.name=="FrontmatterContent"?{parser:tb.parser}:n.name=="Body"?{parser:e.parser}:null)}),i)}function cl(t){for(var e={},i=0;i=!&|~$:]/,ci;function ef(t,e){ci=null;var i=t.next();if(i=="#")return t.skipToEnd(),"comment";if(i=="0"&&t.eat("x"))return t.eatWhile(/[\da-f]/i),"number";if(i=="."&&t.eat(/\d/))return t.match(/\d*(?:e[+\-]?\d+)?/),"number";if(/\d/.test(i))return t.match(/\d*(?:\.\d+)?(?:e[+\-]\d+)?L?/),"number";if(i=="'"||i=='"')return e.tokenize=G6(i),"string";if(i=="`")return t.match(/[^`]+`/),"string.special";if(i=="."&&t.match(/.(?:[.]|\d+)/))return"keyword";if(/[a-zA-Z\.]/.test(i)){t.eatWhile(/[\w\.]/);var n=t.current();return U6.propertyIsEnumerable(n)?"atom":C6.propertyIsEnumerable(n)?(j6.propertyIsEnumerable(n)&&!t.match(/\s*if(\s+|$)/,!1)&&(ci="block"),"keyword"):W6.propertyIsEnumerable(n)?"builtin":"variable"}else return i=="%"?(t.skipTo("%")&&t.next(),"variableName.special"):i=="<"&&t.eat("-")||i=="<"&&t.match("<-")||i=="-"&&t.match(/>>?/)||i=="="&&e.ctx.argList?"operator":rb.test(i)?(i=="$"||t.eatWhile(rb),"operator"):/[\(\){}\[\];]/.test(i)?(ci=i,i==";"?"punctuation":null):null}function G6(t){return function(e,i){if(e.eat("\\")){var n=e.next();return n=="x"?e.match(/^[a-f0-9]{2}/i):(n=="u"||n=="U")&&e.eat("{")&&e.skipTo("}")?e.next():n=="u"?e.match(/^[a-f0-9]{4}/i):n=="U"?e.match(/^[a-f0-9]{8}/i):/[0-7]/.test(n)&&e.match(/^[0-7]{1,2}/),"string.special"}else{for(var O;(O=e.next())!=null;){if(O==t){i.tokenize=ef;break}if(O=="\\"){e.backUp(1);break}}return"string"}}}var sb=1,tf=2,nf=4;function hl(t,e,i){t.ctx={type:e,indent:t.indent,flags:0,column:i.column(),prev:t.ctx}}function ob(t,e){var i=t.ctx;t.ctx={type:i.type,indent:i.indent,flags:i.flags|e,column:i.column,prev:i.prev}}function Of(t){t.indent=t.ctx.indent,t.ctx=t.ctx.prev}const E6={name:"r",startState:function(t){return{tokenize:ef,ctx:{type:"top",indent:-t,flags:tf},indent:0,afterIdent:!1}},token:function(t,e){if(t.sol()&&(e.ctx.flags&3||(e.ctx.flags|=tf),e.ctx.flags&nf&&Of(e),e.indent=t.indentation()),t.eatSpace())return null;var i=e.tokenize(t,e);return i!="comment"&&!(e.ctx.flags&tf)&&ob(e,sb),(ci==";"||ci=="{"||ci=="}")&&e.ctx.type=="block"&&Of(e),ci=="{"?hl(e,"}",t):ci=="("?(hl(e,")",t),e.afterIdent&&(e.ctx.argList=!0)):ci=="["?hl(e,"]",t):ci=="block"?hl(e,"block",t):ci==e.ctx.type?Of(e):e.ctx.type=="block"&&i!="comment"&&ob(e,nf),e.afterIdent=i=="variable"||i=="keyword",i},indent:function(t,e,i){if(t.tokenize!=ef)return 0;var n=e&&e.charAt(0),O=t.ctx,r=n==O.type;return O.flags&nf&&(O=O.prev),O.type=="block"?O.indent+(n=="{"?0:i.unit):O.flags&sb?O.column+(r?0:1):O.indent+(r?0:i.unit)},languageData:{wordChars:".",commentTokens:{line:"#"},autocomplete:ib.concat(nb,Ob)}};function wn(t,e,i){return typeof i>"u"&&(i=""),typeof e>"u"&&(e="\\b"),new RegExp("^"+i+"(("+t.join(")|(")+"))"+e)}var I6="\\\\[0-7]{1,3}",A6="\\\\x[A-Fa-f0-9]{1,2}",M6=`\\\\[abefnrtv0%?'"\\\\]`,D6="([^\\u0027\\u005C\\uD800-\\uDFFF]|[\\uD800-\\uDFFF][\\uDC00-\\uDFFF])",ab=["[<>]:","[<>=]=","<<=?",">>>?=?","=>","--?>","<--[->]?","\\/\\/","\\.{2,3}","[\\.\\\\%*+\\-<>!\\/^|&]=?","\\?","\\$","~",":"],L6=wn(["[<>]:","[<>=]=","[!=]==","<<=?",">>>?=?","=>?","--?>","<--[->]?","\\/\\/","[\\\\%*+\\-<>!\\/^|&\\u00F7\\u22BB]=?","\\?","\\$","~",":","\\u00D7","\\u2208","\\u2209","\\u220B","\\u220C","\\u2218","\\u221A","\\u221B","\\u2229","\\u222A","\\u2260","\\u2264","\\u2265","\\u2286","\\u2288","\\u228A","\\u22C5","\\b(in|isa)\\b(?!.?\\()"],""),N6=/^[;,()[\]{}]/,B6=/^[_A-Za-z\u00A1-\u2217\u2219-\uFFFF][\w\u00A1-\u2217\u2219-\uFFFF]*!*/,F6=wn([I6,A6,M6,D6],"'"),H6=["begin","function","type","struct","immutable","let","macro","for","while","quote","if","else","elseif","try","finally","catch","do"],K6=["end","else","elseif","catch","finally"],lb=["if","else","elseif","while","for","begin","let","end","do","try","catch","finally","return","break","continue","global","local","const","export","import","importall","using","function","where","macro","module","baremodule","struct","type","mutable","immutable","quote","typealias","abstract","primitive","bitstype"],cb=["true","false","nothing","NaN","Inf"],J6=wn(H6),eC=wn(K6),tC=wn(lb),iC=wn(cb),nC=/^@[_A-Za-z\u00A1-\uFFFF][\w\u00A1-\uFFFF]*!*/,OC=/^:[_A-Za-z\u00A1-\uFFFF][\w\u00A1-\uFFFF]*!*/,rC=/^(`|([_A-Za-z\u00A1-\uFFFF]*"("")?))/,sC=wn(ab,"","@"),oC=wn(ab,"",":");function hb(t){return t.nestedArrays>0}function aC(t){return t.nestedGenerators>0}function db(t,e){return typeof e>"u"&&(e=0),t.scopes.length<=e?null:t.scopes[t.scopes.length-(e+1)]}function KO(t,e){if(t.match("#=",!1))return e.tokenize=cC,e.tokenize(t,e);var i=e.leavingExpr;if(t.sol()&&(i=!1),e.leavingExpr=!1,i&&t.match(/^'+/))return"operator";if(t.match(/\.{4,}/))return"error";if(t.match(/\.{1,3}/))return"operator";if(t.eatSpace())return null;var n=t.peek();if(n==="#")return t.skipToEnd(),"comment";if(n==="["&&(e.scopes.push("["),e.nestedArrays++),n==="("&&(e.scopes.push("("),e.nestedGenerators++),hb(e)&&n==="]"){for(;e.scopes.length&&db(e)!=="[";)e.scopes.pop();e.scopes.pop(),e.nestedArrays--,e.leavingExpr=!0}if(aC(e)&&n===")"){for(;e.scopes.length&&db(e)!=="(";)e.scopes.pop();e.scopes.pop(),e.nestedGenerators--,e.leavingExpr=!0}if(hb(e)){if(e.lastToken=="end"&&t.match(":"))return"operator";if(t.match("end"))return"number"}var O;if((O=t.match(J6,!1))&&e.scopes.push(O[0]),t.match(eC,!1)&&e.scopes.pop(),t.match(/^::(?![:\$])/))return e.tokenize=lC,e.tokenize(t,e);if(!i&&(t.match(OC)||t.match(oC)))return"builtin";if(t.match(L6))return"operator";if(t.match(/^\.?\d/,!1)){var r=RegExp(/^im\b/),s=!1;if(t.match(/^0x\.[0-9a-f_]+p[\+\-]?[_\d]+/i)&&(s=!0),t.match(/^0x[0-9a-f_]+/i)&&(s=!0),t.match(/^0b[01_]+/i)&&(s=!0),t.match(/^0o[0-7_]+/i)&&(s=!0),t.match(/^(?:(?:\d[_\d]*)?\.(?!\.)(?:\d[_\d]*)?|\d[_\d]*\.(?!\.)(?:\d[_\d]*))?([Eef][\+\-]?[_\d]+)?/i)&&(s=!0),t.match(/^\d[_\d]*(e[\+\-]?\d+)?/i)&&(s=!0),s)return t.match(r),e.leavingExpr=!0,"number"}if(t.match("'"))return e.tokenize=hC,e.tokenize(t,e);if(t.match(rC))return e.tokenize=dC(t.current()),e.tokenize(t,e);if(t.match(nC)||t.match(sC))return"meta";if(t.match(N6))return null;if(t.match(tC))return"keyword";if(t.match(iC))return"builtin";var o=e.isDefinition||e.lastToken=="function"||e.lastToken=="macro"||e.lastToken=="type"||e.lastToken=="struct"||e.lastToken=="immutable";return t.match(B6)?o?t.peek()==="."?(e.isDefinition=!0,"variable"):(e.isDefinition=!1,"def"):(e.leavingExpr=!0,"variable"):(t.next(),"error")}function lC(t,e){return t.match(/.*?(?=[,;{}()=\s]|$)/),t.match("{")?e.nestedParameters++:t.match("}")&&e.nestedParameters>0&&e.nestedParameters--,e.nestedParameters>0?t.match(/.*?(?={|})/)||t.next():e.nestedParameters==0&&(e.tokenize=KO),"builtin"}function cC(t,e){return t.match("#=")&&e.nestedComments++,t.match(/.*?(?=(#=|=#))/)||t.skipToEnd(),t.match("=#")&&(e.nestedComments--,e.nestedComments==0&&(e.tokenize=KO)),"comment"}function hC(t,e){var i=!1,n;if(t.match(F6))i=!0;else if(n=t.match(/\\u([a-f0-9]{1,4})(?=')/i)){var O=parseInt(n[1],16);(O<=55295||O>=57344)&&(i=!0,t.next())}else if(n=t.match(/\\U([A-Fa-f0-9]{5,8})(?=')/)){var O=parseInt(n[1],16);O<=1114111&&(i=!0,t.next())}return i?(e.leavingExpr=!0,e.tokenize=KO,"string"):(t.match(/^[^']+(?=')/)||t.skipToEnd(),t.match("'")&&(e.tokenize=KO),"error")}function dC(t){t.substr(-3)==='"""'?t='"""':t.substr(-1)==='"'&&(t='"');function e(i,n){if(i.eat("\\"))i.next();else{if(i.match(t))return n.tokenize=KO,n.leavingExpr=!0,"string";i.eat(/[`"]/)}return i.eatWhile(/[^\\`"]/),"string"}return e}const uC={name:"julia",startState:function(){return{tokenize:KO,scopes:[],lastToken:null,leavingExpr:!1,isDefinition:!1,nestedArrays:0,nestedComments:0,nestedGenerators:0,nestedParameters:0,firstParenPos:-1}},token:function(t,e){var i=e.tokenize(t,e),n=t.current();return n&&i&&(e.lastToken=n),i},indent:function(t,e,i){var n=0;return(e==="]"||e===")"||/^end\b/.test(e)||/^else/.test(e)||/^catch\b/.test(e)||/^elseif\b/.test(e)||/^finally/.test(e))&&(n=-1),(t.scopes.length+n)*i.unit},languageData:{indentOnInput:/^\s*(end|else|catch|finally)\b$/,commentTokens:{line:"#",block:{open:"#=",close:"=#"}},closeBrackets:{brackets:["(","[","{",'"']},autocomplete:lb.concat(cb)}},fC={name:"toml",startState:function(){return{inString:!1,stringType:"",lhs:!0,inArray:0}},token:function(t,e){let i;if(!e.inString&&(i=t.match(/^('''|"""|'|")/))&&(e.stringType=i[0],e.inString=!0),t.sol()&&!e.inString&&e.inArray===0&&(e.lhs=!0),e.inString){for(;e.inString;)if(t.match(e.stringType))e.inString=!1;else if(t.peek()==="\\")t.next(),t.next();else{if(t.eol())break;t.match(/^.[^\\\"\']*/)}return e.lhs?"property":"string"}else{if(e.inArray&&t.peek()==="]")return t.next(),e.inArray--,"bracket";if(e.lhs&&t.peek()==="["&&t.skipTo("]"))return t.next(),t.peek()==="]"&&t.next(),"atom";if(t.peek()==="#")return t.skipToEnd(),"comment";if(t.eatSpace())return null;if(e.lhs&&t.eatWhile(function(n){return n!="="&&n!=" "}))return"property";if(e.lhs&&t.peek()==="=")return t.next(),e.lhs=!1,null;if(!e.lhs&&t.match(/^\d\d\d\d[\d\-\:\.T]*Z/))return"atom";if(!e.lhs&&(t.match("true")||t.match("false")))return"atom";if(!e.lhs&&t.peek()==="[")return e.inArray++,t.next(),"bracket";if(!e.lhs&&t.match(/^\-?\d+(?:\.\d+)?/))return"number";t.eatSpace()||t.next()}return null},languageData:{commentTokens:{line:"#"}}},$C={name:"properties",token:function(t,e){var i=t.sol()||e.afterSection,n=t.eol();if(e.afterSection=!1,i&&(e.nextMultiline?(e.inMultiline=!0,e.nextMultiline=!1):e.position="def"),n&&!e.nextMultiline&&(e.inMultiline=!1,e.position="def"),i)for(;t.eatSpace(););var O=t.next();return i&&(O==="#"||O==="!"||O===";")?(e.position="comment",t.skipToEnd(),"comment"):i&&O==="["?(e.afterSection=!0,t.skipTo("]"),t.eat("]"),"header"):O==="="||O===":"?(e.position="quote",null):(O==="\\"&&e.position==="quote"&&t.eol()&&(e.nextMultiline=!0),e.position)},startState:function(){return{position:"def",nextMultiline:!1,inMultiline:!1,afterSection:!1}}};var rf={};function sf(t,e){for(var i=0;i1&&t.eat("$");var i=t.next();return/['"({]/.test(i)?(e.tokens[0]=dl(i,i=="("?"quote":i=="{"?"def":"string"),JO(t,e)):(/\d/.test(i)||t.eatWhile(/\w/),e.tokens.shift(),"def")};function mC(t){return function(e,i){return e.sol()&&e.string==t&&i.tokens.shift(),e.skipToEnd(),"string.special"}}function JO(t,e){return(e.tokens[0]||QC)(t,e)}const gC={name:"shell",startState:function(){return{tokens:[]}},token:function(t,e){return JO(t,e)},languageData:{autocomplete:ub.concat(fb,$b),closeBrackets:{brackets:["(","[","{","'",'"',"`"]},commentTokens:{line:"#"}}};function PC(t){pb(t,"start");var e={},i=t.languageData||{},n=!1;for(var O in t)if(O!=i&&t.hasOwnProperty(O))for(var r=e[O]=[],s=t[O],o=0;o2&&s.token&&typeof s.token!="string"){i.pending=[];for(var l=2;l-1)return null;var O=i.indent.length-1,r=t[i.state];e:for(;;){for(var s=0;s0?h.cmdState[h.cmdState.length-1]:null}function n(h){var d=h.cmdState.pop();d&&d.closeBracket()}function O(h){for(var d=h.cmdState,u=d.length-1;u>=0;u--){var $=d[u];if($.name!="DEFAULT")return $}return{styleIdentifier:function(){return null}}}function r(h,d,u){return function(){this.name=h,this.bracketNo=0,this.style=d,this.styles=u,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var s={};s.importmodule=r("importmodule","tag",["string","builtin"]),s.documentclass=r("documentclass","tag",["","atom"]),s.usepackage=r("usepackage","tag",["atom"]),s.begin=r("begin","tag",["atom"]),s.end=r("end","tag",["atom"]),s.label=r("label","tag",["atom"]),s.ref=r("ref","tag",["atom"]),s.eqref=r("eqref","tag",["atom"]),s.cite=r("cite","tag",["atom"]),s.bibitem=r("bibitem","tag",["atom"]),s.Bibitem=r("Bibitem","tag",["atom"]),s.RBibitem=r("RBibitem","tag",["atom"]),s.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function o(h,d){h.f=d}function a(h,d){var u;if(h.match(/^\\[a-zA-Z@\xc0-\u1fff\u2060-\uffff]+/)){var $=h.current().slice(1);return u=s.hasOwnProperty($)?s[$]:s.DEFAULT,u=new u,e(d,u),o(d,c),u.style}if(h.match(/^\\[$&%#{}_]/)||h.match(/^\\[,;!\/\\]/))return"tag";if(h.match("\\["))return o(d,function(p,m){return l(p,m,"\\]")}),"keyword";if(h.match("\\("))return o(d,function(p,m){return l(p,m,"\\)")}),"keyword";if(h.match("$$"))return o(d,function(p,m){return l(p,m,"$$")}),"keyword";if(h.match("$"))return o(d,function(p,m){return l(p,m,"$")}),"keyword";var Q=h.next();if(Q=="%")return h.skipToEnd(),"comment";if(Q=="}"||Q=="]"){if(u=i(d),u)u.closeBracket(Q),o(d,c);else return"error";return"bracket"}else return Q=="{"||Q=="["?(u=s.DEFAULT,u=new u,e(d,u),"bracket"):/\d/.test(Q)?(h.eatWhile(/[\w.%]/),"atom"):(h.eatWhile(/[\w\-_]/),u=O(d),u.name=="begin"&&(u.argument=h.current()),u.styleIdentifier())}function l(h,d,u){if(h.eatSpace())return null;if(u&&h.match(u))return o(d,a),"keyword";if(h.match(/^\\[a-zA-Z@]+/))return"tag";if(h.match(/^[a-zA-Z]+/))return"variableName.special";if(h.match(/^\\[$&%#{}_]/)||h.match(/^\\[,;!\/]/)||h.match(/^[\^_&]/))return"tag";if(h.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(h.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var $=h.next();return $=="{"||$=="}"||$=="["||$=="]"||$=="("||$==")"?"bracket":$=="%"?(h.skipToEnd(),"comment"):"error"}function c(h,d){var u=h.peek(),$;return u=="{"||u=="["?($=i(d),$.openBracket(u),h.eat(u),o(d,a),"bracket"):/[ \t\r]/.test(u)?(h.eat(u),null):(o(d,a),n(d),a(h,d))}return{name:"stex",startState:function(){var h=t?function(d,u){return l(d,u)}:a;return{cmdState:[],f:h}},copyState:function(h){return{cmdState:h.cmdState.slice(),f:h.f}},token:function(h,d){return d.f(h,d)},blankLine:function(h){h.f=a,h.cmdState.length=0},languageData:{commentTokens:{line:"%"}}}}const VC=bb(!1);bb(!0);function yb(t){return t?t.trim().replace(/^\./,"").toLowerCase():""}function qC(t){let e=t.trim();const i=e.match(/^\{([^}]*)\}/);return i&&(e=i[1]),yb(e.split(/[\s,]+/)[0]??"")}const UC=new Set(["md","markdown","qmd","rmd"]);function xb(t){switch(t){case"r":case"rscript":case"rprofile":return Yi.define(E6);case"py":case"python":return M3();case"jl":case"julia":return Yi.define(uC);case"sql":return Y7();case"js":case"mjs":case"cjs":case"jsx":case"javascript":case"node":return Ma({jsx:!0});case"ts":case"typescript":return Ma({typescript:!0});case"tsx":return Ma({typescript:!0,jsx:!0});case"htm":case"html":return Hd();case"css":return OS();case"scss":return XX();case"sass":return XX({indented:!0});case"json":return bU();case"yaml":case"yml":return Y6();case"svg":case"xml":return i6();case"toml":return Yi.define(fC);case"cfg":case"conf":case"ini":return Yi.define($C);case"sh":case"zsh":case"bash":case"shell":return Yi.define(gC);case"dockerfile":case"docker":return Yi.define(YC);case"tex":case"latex":return Yi.define(VC);case"c":case"h":case"cc":case"hh":case"cxx":case"hpp":case"cpp":return nV();case"rs":case"rust":return d8();case"java":return gU();case"php":return kW();case"patch":case"diff":return Yi.define(zC);case"md":case"markdown":case"qmd":case"rmd":return U0();default:return null}}function WC(t){return t instanceof Fe?t.language:t}function CC(){return V6({content:U0({codeLanguages:t=>{const e=xb(qC(t));return e?WC(e):null}})})}function jC(t){const e=yb(t);return UC.has(e)?CC():xb(e)??[]}const Tb=Pi.define();function wb(){const t=et.useRef(null),e=et.useRef(null),i=et.useRef(new vr),n=et.useRef(-1),O=oO("editor_doc"),r=et.useRef(300);r.current=O?.debounce??300;const s=et.useRef(null);return et.useEffect(()=>{const o=new R({parent:t.current??void 0,state:ae.create({doc:"",extensions:[Tz,wO.of([DZ]),YO.of(" "),ae.tabSize.of(2),i.current.of([]),R.lineWrapping,R.updateListener.of(a=>{if(!a.docChanged||a.transactions.some(c=>c.annotation(Tb)))return;const l=a.state.doc.toString();s.current!=null&&window.clearTimeout(s.current),s.current=window.setTimeout(()=>{s.current=null,window.Shiny?.setInputValue?.("content",l)},r.current)})]})});return e.current=o,()=>{s.current!=null&&window.clearTimeout(s.current),o.destroy(),e.current=null}},[]),et.useEffect(()=>{const o=e.current;if(!o||!O||O.rev===n.current)return;n.current=O.rev;const a=o.state.doc.toString(),l=[i.current.reconfigure(jC(O.ext))];o.dispatch({changes:a===O.value?void 0:{from:0,to:a.length,insert:O.value},effects:l,annotations:Tb.of(!0)})},[O]),k.jsx("div",{className:"amsync-editor",ref:t})}function GC(){const t=oO("paths",[])??[],e=oO("selected",null)??null,i=or("refresh"),n=or("disconnect");return k.jsxs("div",{className:"amsync-browse",children:[k.jsxs("aside",{className:"amsync-sidebar",children:[k.jsx("div",{className:"amsync-sidebar-title",children:"Files"}),k.jsx("div",{className:"amsync-tree-wrap",children:t.length===0?k.jsx("div",{className:"amsync-empty",children:"No files in project."}):k.jsx(Q5,{paths:t})}),k.jsxs("div",{className:"amsync-sidebar-actions",children:[k.jsx("button",{type:"button",className:"amsync-btn amsync-btn-sm amsync-btn-outline amsync-fill",onClick:i,children:"Refresh"}),k.jsx("button",{type:"button",className:"amsync-btn amsync-btn-sm amsync-btn-danger amsync-fill",onClick:n,children:"Disconnect"})]})]}),k.jsx("main",{className:"amsync-main",children:e?k.jsxs("div",{className:"amsync-editor-card",children:[k.jsxs("div",{className:"amsync-editor-header",children:[k.jsxs("span",{className:"amsync-editor-title",children:[k.jsx(u5,{path:e,className:"amsync-file-icon"}),k.jsx("span",{className:"amsync-editor-path",children:e})]}),k.jsx("span",{className:"amsync-editor-live",children:"live"})]}),k.jsx(wb,{})]}):k.jsx("div",{className:"amsync-placeholder",children:"Select a file from the sidebar to edit."})})]})}const EC=5e3;function IC(){const[t,e]=et.useState([]),i=et.useRef(0);return ny("notify",n=>{const O=i.current+=1,r={id:O,type:n.type??"message",text:n.text??""};e(s=>[...s,r]),window.setTimeout(()=>e(s=>s.filter(o=>o.id!==O)),EC)}),t.length===0?null:k.jsx("div",{className:"amsync-toasts",children:t.map(n=>k.jsx("div",{className:`amsync-toast amsync-toast-${n.type}`,children:n.text},n.id))})}function AC(){const t=or("close");return k.jsxs("div",{className:"amsync-editor-card amsync-edit-only",children:[k.jsxs("div",{className:"amsync-editor-header",children:[k.jsx("span",{className:"amsync-editor-path",children:"Edit synced text (live)"}),k.jsx("button",{type:"button",className:"amsync-btn amsync-btn-sm amsync-btn-outline",onClick:t,children:"Close"})]}),k.jsx(wb,{})]})}function MC(){return k.jsxs("div",{className:"amsync-closed",children:[k.jsx("h5",{children:"Session ended"}),k.jsx("p",{children:"You can close this window."})]})}function DC(){const t=Oy(),e=oO("view","connect")??"connect";let i;return t?e==="closed"?i=k.jsx(MC,{}):e==="browse"?i=k.jsx(GC,{}):e==="edit"?i=k.jsx(AC,{}):i=k.jsx(ry,{}):i=k.jsx("div",{className:"amsync-loading",children:"Connecting…"}),k.jsxs(k.Fragment,{children:[k.jsx(IC,{}),i]})}const vb=document.body.appendChild(document.createElement("div"));vb.id="root",iy.createRoot(vb).render(k.jsx(DC,{}))})(window.shinyreact.React); diff --git a/man/sync_app.Rd b/man/sync_app.Rd new file mode 100644 index 0000000..a9161da --- /dev/null +++ b/man/sync_app.Rd @@ -0,0 +1,81 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/app.R +\name{sync_app} +\alias{sync_app} +\title{Launch the autosync browser app} +\usage{ +sync_app( + server = "", + proj_id = "", + token = NULL, + tls = NULL, + timeout = 5000L, + files_key = "files", + debounce = 300L +) +} +\arguments{ +\item{server}{Sync-server URL to prefill in the connect form. Default \code{""}.} + +\item{proj_id}{Project document ID to prefill. Default \code{""}.} + +\item{token}{(optional) A JWT from an earlier \code{\link[=sync_token]{sync_token()}} call. When +supplied, the app starts signed in. Default \code{NULL}.} + +\item{tls}{(optional) for secure wss:// connections to servers with +self-signed or custom CA certificates, a TLS configuration object +created by \code{\link[nanonext:tls_config]{nanonext::tls_config()}}.} + +\item{timeout}{Timeout in milliseconds for each receive operation. Default 5000.} + +\item{files_key}{Key of the files map within the project document. Default +\code{"files"}.} + +\item{debounce}{Milliseconds to debounce outgoing editor changes, passed +through to the live editor. Default 300.} +} +\value{ +Invisibly \code{NULL}, when the app window is closed. +} +\description{ +\code{sync_app()} runs one Shiny app for the whole workflow. It has two screens: +} +\details{ +\itemize{ +\item \strong{Connect} -- enter a sync-server URL and a project document ID, then +click \strong{Connect}. If an OIDC client ID is available, the app signs in +with the same browser flow as \code{\link[=sync_token]{sync_token()}} first. Blank sign-in fields +under \strong{Advanced} use the \code{OIDC_CLIENT_ID}, \code{OIDC_CLIENT_SECRET}, and +\code{OIDC_ISSUER} environment variables. The form shows when the first two +are set, but not their values. To skip sign-in, pass a \code{token} from an +earlier \code{\link[=sync_token]{sync_token()}} call. For open servers, leave the sign-in blank +to connect without a token. +\item \strong{Browse & edit} -- the file tree of the project appears in a sidebar. +Select a file to open its document in a live CodeMirror editor. The +editor syncs with the server in both directions, like the \verb{$edit()} +method of a document handle. \strong{Disconnect} returns to the connect +screen. Close the window to end the session. +} + +The app builds one \code{\link[=sync_project]{sync_project()}} connection and reuses it for every +file opened during the session. + +The interface is a React frontend rendered with the \pkg{shinyreact} +package. The file tree uses the \pkg{@pierre/trees} component, and the +editor uses CodeMirror 6. R owns the live Automerge documents and all +syncing. Requires the \pkg{shiny} and \pkg{shinyreact} packages and an +interactive session. +} +\examples{ +\dontshow{if (interactive()) withAutoprint(\{ # examplesIf} +# Start with empty fields and fill them in the form: +sync_app() + +# Or prefill the server and project: +sync_app("wss://quarto-hub.com/ws", proj_id = "4F63WJPDzbHkkfKa66h1Qrr1sC5U") + +# Reuse a token obtained earlier, so the app starts signed in: +token <- sync_token() +sync_app("wss://quarto-hub.com/ws", proj_id = "4F63WJPD...", token = token) +\dontshow{\}) # examplesIf} +} diff --git a/man/sync_client.Rd b/man/sync_client.Rd index f06cb07..3e301ed 100644 --- a/man/sync_client.Rd +++ b/man/sync_client.Rd @@ -43,6 +43,13 @@ with: \item{\code{doc}}{The live automerge document, kept in sync with the server.} \item{\code{push()}}{Push this document's local changes to the server immediately.} +\item{\code{edit(at = "text", ext = NULL, debounce = 300L)}}{Open this +document's text object at \code{at} in a live Shiny code editor that syncs +both ways, blocking until closed (requires \pkg{shiny} and +\pkg{shinyreact}). \code{at} is a key or character-vector path to an \code{am_text} +object, \code{ext} (e.g. \code{".md"}) selects syntax highlighting, and +\code{debounce} is the millisecond delay before pushing keystrokes. See +Details.} \item{\code{close()}}{Stop syncing this one document (detach it from the connection); the connection and its other documents are unaffected.} \item{\code{active}}{Logical, whether the document is still open on an active @@ -69,6 +76,17 @@ local changes are flushed periodically via a \code{\link[later:later]{later::lat Neither \code{close()} flushes pending local changes. Call \verb{$push()} first if you have unsynced edits — otherwise any changes made since the last \code{sync}-interval tick may be lost. + +\strong{Live editing.} A handle's \verb{$edit()} opens its text object in a live +CodeMirror editor (a React frontend rendered with \pkg{shinyreact}) that syncs +both ways: as you type, the minimal +diff is written to the live document and pushed (debounced); when the text +changes remotely, the editor updates to the merged result. There is no +\strong{Save} button — every edit is applied live. It syncs whole-text snapshots, +not granular operations, so a remote edit arriving in the brief window +between a keystroke and its debounced push can be overwritten by that push; +a smaller \code{debounce} narrows the window. The original's trailing-newline +state is preserved. } \examples{ \dontshow{if (interactive()) withAutoprint(\{ # examplesIf} diff --git a/man/sync_project.Rd b/man/sync_project.Rd new file mode 100644 index 0000000..b6d1ba9 --- /dev/null +++ b/man/sync_project.Rd @@ -0,0 +1,74 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/project.R +\name{sync_project} +\alias{sync_project} +\title{Open files from a project document} +\usage{ +sync_project( + url, + proj_id, + token = NULL, + tls = NULL, + timeout = 5000L, + files_key = "files" +) +} +\arguments{ +\item{url}{WebSocket URL of the sync server (e.g., "ws://localhost:3030/" +or "wss://sync.automerge.org/"). Note: trailing slash may be required.} + +\item{proj_id}{Document ID of the project.} + +\item{token}{(optional) JWT (ID token) for authenticated servers. +Sent as a Bearer token in the Authorization header of the WebSocket +upgrade request.} + +\item{tls}{(optional) for secure wss:// connections to servers with +self-signed or custom CA certificates, a TLS configuration object +created by \code{\link[nanonext:tls_config]{nanonext::tls_config()}}.} + +\item{timeout}{Timeout in milliseconds for each receive operation. Default 5000.} + +\item{files_key}{Key of the files map within the project document. Default +\code{"files"}.} +} +\value{ +An environment of class \code{"autosync_project"} (reference semantics) +with the following fields and methods: +\describe{ +\item{\code{doc}}{The live project document, kept in sync with the server.} +\item{\code{conn}}{The underlying \code{\link[=sync_client]{sync_client()}} connection.} +\item{\code{paths()}}{Current sorted file paths.} +\item{\code{doc_id(path)}}{Resolve a path to its document ID.} +\item{\code{open(path)}}{Open the file's document over the project connection +and return its \code{autosync_doc} handle. Reuses the connection and any +already-open document.} +\item{\code{refresh()}}{Re-resolve the file tree to pick up added or removed +files (the project document syncs live, so this just settles pending +updates).} +\item{\code{close()}}{Disconnect the project connection.} +} +} +\description{ +Given a sync server URL and a project document ID, opens a persistent +connection to the server, syncs the project document over it, and exposes +its file tree for opening individual files. A project is an Automerge +document with a \code{files} map whose keys are file paths and whose values are +text objects holding each file's own document ID. +} +\details{ +Opening a file syncs that file's document over the \strong{same} connection +rather than dialing the server again, so a session reuses a single WebSocket +throughout. Call the opened file's \verb{$edit()} method to edit it live, or use +\code{\link[=sync_app]{sync_app()}} for an interactive browser. Call \verb{$close()} when finished to +disconnect. +} +\examples{ +\dontshow{if (interactive()) withAutoprint(\{ # examplesIf} +proj <- sync_project("wss://quarto-hub.com/ws", proj_id, token = sync_token()) +proj # prints the file tree +doc <- proj$open("/charlie/index.qmd") # open a file over the connection +doc$edit(at = "text", ext = ".qmd") # edit it live +proj$close() # disconnect when finished +\dontshow{\}) # examplesIf} +} diff --git a/srcjs/.gitignore b/srcjs/.gitignore new file mode 100644 index 0000000..c2658d7 --- /dev/null +++ b/srcjs/.gitignore @@ -0,0 +1 @@ +node_modules/ diff --git a/srcjs/package-lock.json b/srcjs/package-lock.json new file mode 100644 index 0000000..2f59d6a --- /dev/null +++ b/srcjs/package-lock.json @@ -0,0 +1,2237 @@ +{ + "name": "autosync-frontend", + "version": "0.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "autosync-frontend", + "version": "0.0.0", + "dependencies": { + "@codemirror/commands": "^6.7.1", + "@codemirror/lang-cpp": "^6.0.2", + "@codemirror/lang-css": "^6.3.1", + "@codemirror/lang-html": "^6.4.9", + "@codemirror/lang-java": "^6.0.1", + "@codemirror/lang-javascript": "^6.2.3", + "@codemirror/lang-json": "^6.0.1", + "@codemirror/lang-markdown": "^6.3.2", + "@codemirror/lang-php": "^6.0.1", + "@codemirror/lang-python": "^6.1.7", + "@codemirror/lang-rust": "^6.0.1", + "@codemirror/lang-sass": "^6.0.2", + "@codemirror/lang-sql": "^6.8.0", + "@codemirror/lang-xml": "^6.1.0", + "@codemirror/lang-yaml": "^6.1.2", + "@codemirror/language": "^6.10.8", + "@codemirror/legacy-modes": "^6.4.3", + "@codemirror/state": "^6.5.0", + "@codemirror/view": "^6.36.1", + "@pierre/trees": "1.0.0-beta.4", + "codemirror": "^6.0.1" + }, + "devDependencies": { + "@types/react": "^19.0.0", + "@types/react-dom": "^19.0.0", + "@vitejs/plugin-react": "^4.3.4", + "react": "^19.0.0", + "react-dom": "^19.0.0", + "typescript": "^5.7.2", + "vite": "^5.4.11" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.29.7.tgz", + "integrity": "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.29.7", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.29.7.tgz", + "integrity": "sha512-locTkQyKvwIEgBzVrn8693ebc97F2U8ZHjbXwDXJ5Fn2TCpNwTlKcaKLkdHop5c/icOFE7qt7Q9JC5hnKNa6Gg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.29.7.tgz", + "integrity": "sha512-RgHBCvtjbOK2gXSNBNIkNoEc9qoVEtau3hj8gEqKQuL3HZAibKarWFEI3Lfm6EYKkLalOh8eSrj9b+ch9H/VBA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.29.7", + "@babel/generator": "^7.29.7", + "@babel/helper-compilation-targets": "^7.29.7", + "@babel/helper-module-transforms": "^7.29.7", + "@babel/helpers": "^7.29.7", + "@babel/parser": "^7.29.7", + "@babel/template": "^7.29.7", + "@babel/traverse": "^7.29.7", + "@babel/types": "^7.29.7", + "@jridgewell/remapping": "^2.3.5", + "convert-source-map": "^2.0.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.3", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/generator": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.29.7.tgz", + "integrity": "sha512-DkXD5OJQaAQIdZ1bt3UZdEnHAn9Imd3IVBdX03UFe+ony9Ojw5pzr9YVKGDY1jt+Gcn/FnGkNf8r+Vj5NOJWtQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.29.7", + "@babel/types": "^7.29.7", + "@jridgewell/gen-mapping": "^0.3.12", + "@jridgewell/trace-mapping": "^0.3.28", + "jsesc": "^3.0.2" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.29.7.tgz", + "integrity": "sha512-wem6WaBj4NaVYVdNhLPPVacES6ZJ+KBBfSkTMD3YZxbP3rm3Di85tJU5ljaUNhaOynt+Aj0xruhYuzQBt8n71g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/compat-data": "^7.29.7", + "@babel/helper-validator-option": "^7.29.7", + "browserslist": "^4.24.0", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-globals": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-globals/-/helper-globals-7.29.7.tgz", + "integrity": "sha512-3nQVUAtvkKH9zahfWgw96Jc/uFOmjACE1kQz82E2lqWmHBgjzbNlsC22nuQTfahmWeQtTq5nQ/4Nnd2A1wj4zA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.29.7.tgz", + "integrity": "sha512-ejHwrQQYcm9xnTivShn2IDOlIzInN34AXskvq9QicvCtEzq1Vzclu/tKF8Jq1Cg8JG2GL6/EmjgsCT7lXepE3g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/traverse": "^7.29.7", + "@babel/types": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.29.7.tgz", + "integrity": "sha512-UPUVSyXbOh627KiCIGQSgwWzGeBKLkaJ9PJEdrngIwMSzxLR4jS4+f1f1jb7VzBbg8nFLaYotvVPFCTqdrmTAg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-module-imports": "^7.29.7", + "@babel/helper-validator-identifier": "^7.29.7", + "@babel/traverse": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.29.7.tgz", + "integrity": "sha512-G7sHYigPY17oO5SYWnfD/0MTBwVR781S/JI643e/JhUYgVgWE/61SoW3NH9KWUKyKq5LVh3npif99Wkt6j86Jw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.29.7.tgz", + "integrity": "sha512-Pb5ijPrZ89GDH8223L4UP8i6QApWxs04RbPQJTeWDV0/keR2E36MeKnyr6LYmUUvqRRI+Iv87SuF1W6ErINzYw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.29.7.tgz", + "integrity": "sha512-qehxGkRj55h/ff8EMaJ+cYhyaKlHIxqYDn682wQD7RNp9UujOQsHog2uS0r2vzr4pW+sXf90NeeayjcNaX3fFg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.29.7.tgz", + "integrity": "sha512-N9ZErrD+yW5geCDtBqnOoxmR8+tNKiGuxKlDpuJxfsqpa2dFcexaziGAE/qoHLiDDreVNMupxGmSoNlyvsA3gw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.29.7.tgz", + "integrity": "sha512-1k2lAGRMfHTcwuNYcCNUmaUffmQv8KWMfh2iJUUeRlwlwH4FdNG7mfPI10NPfLHJFThE4Tyr4mv7kTNZOiPuBg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/template": "^7.29.7", + "@babel/types": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.29.7.tgz", + "integrity": "sha512-hnORnjP/1P/zFEndoeX+n+t1RwWRJiJpM/jO7FW32Kn9r5+sJB2JWOdYo4L6k78j15eCwY3Gm/7364B1EMwtNg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.29.7" + }, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-transform-react-jsx-self": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.29.7.tgz", + "integrity": "sha512-TL0hMc9xzy86VD31nUiwzd5otRAcyEPcsegCxolO0PvcXuH1v0kECe/UIznYFihpkvU5wg/jk4v0TTEFfm53fw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/plugin-transform-react-jsx-source": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.29.7.tgz", + "integrity": "sha512-06IyK09H3wi4cGbhDBwp5gUGo0IKtnYa8tyTiephirPCK6fbobVGiXMMI5zLQ4aKEYP3wZ3ArU44o+8KMrSG/Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-plugin-utils": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/template": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.29.7.tgz", + "integrity": "sha512-puq+Gf35oI24FeN11LkoUQFqv9uwNeWpxXZi/Ji3rRIoKAzKnxRaZ+Gkj0vKS9ZCiTESfng1N9LyOyXvo+m+Gg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.29.7", + "@babel/parser": "^7.29.7", + "@babel/types": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.29.7.tgz", + "integrity": "sha512-EhlfNQtZ+NK22w5BM61ciuiq1m58ed33Wr1Xan//ZRTy6hgjnwyCffRYwzsGXdASJSUJ1guZILsErh1eQcl+zw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.29.7", + "@babel/generator": "^7.29.7", + "@babel/helper-globals": "^7.29.7", + "@babel/parser": "^7.29.7", + "@babel/template": "^7.29.7", + "@babel/types": "^7.29.7", + "debug": "^4.3.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.29.7.tgz", + "integrity": "sha512-4zBIxpPzowiZpusoFkyGVwakdRJUyuH5PxQ/PrqghfdFWWasvnCdPfQXHrenDai+gyLARulZjZowCOj6fjT4pA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-string-parser": "^7.29.7", + "@babel/helper-validator-identifier": "^7.29.7" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@codemirror/autocomplete": { + "version": "6.20.3", + "resolved": "https://registry.npmjs.org/@codemirror/autocomplete/-/autocomplete-6.20.3.tgz", + "integrity": "sha512-tlosUqb+3BbxCxZdu4tKeRghPFC+QM7q4X5YhKV2eCmPG+1r2F3f4AaSz5sCrFqUtX4Jh20VFTKecl16MgiV9g==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.17.0", + "@lezer/common": "^1.0.0" + } + }, + "node_modules/@codemirror/commands": { + "version": "6.10.3", + "resolved": "https://registry.npmjs.org/@codemirror/commands/-/commands-6.10.3.tgz", + "integrity": "sha512-JFRiqhKu+bvSkDLI+rUhJwSxQxYb759W5GBezE8Uc8mHLqC9aV/9aTC7yJSqCtB3F00pylrLCwnyS91Ap5ej4Q==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.6.0", + "@codemirror/view": "^6.27.0", + "@lezer/common": "^1.1.0" + } + }, + "node_modules/@codemirror/lang-cpp": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/@codemirror/lang-cpp/-/lang-cpp-6.0.3.tgz", + "integrity": "sha512-URM26M3vunFFn9/sm6rzqrBzDgfWuDixp85uTY49wKudToc2jTHUrKIGGKs+QWND+YLofNNZpxcNGRynFJfvgA==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@lezer/cpp": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-css": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/@codemirror/lang-css/-/lang-css-6.3.1.tgz", + "integrity": "sha512-kr5fwBGiGtmz6l0LSJIbno9QrifNMUusivHbnA1H6Dmqy4HZFte3UAICix1VuKo0lMPKQr2rqB+0BkKi/S3Ejg==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.0.2", + "@lezer/css": "^1.1.7" + } + }, + "node_modules/@codemirror/lang-html": { + "version": "6.4.11", + "resolved": "https://registry.npmjs.org/@codemirror/lang-html/-/lang-html-6.4.11.tgz", + "integrity": "sha512-9NsXp7Nwp891pQchI7gPdTwBuSuT3K65NGTHWHNJ55HjYcHLllr0rbIZNdOzas9ztc1EUVBlHou85FFZS4BNnw==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/lang-css": "^6.0.0", + "@codemirror/lang-javascript": "^6.0.0", + "@codemirror/language": "^6.4.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.17.0", + "@lezer/common": "^1.0.0", + "@lezer/css": "^1.1.0", + "@lezer/html": "^1.3.12" + } + }, + "node_modules/@codemirror/lang-java": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@codemirror/lang-java/-/lang-java-6.0.2.tgz", + "integrity": "sha512-m5Nt1mQ/cznJY7tMfQTJchmrjdjQ71IDs+55d1GAa8DGaB8JXWsVCkVT284C3RTASaY43YknrK2X3hPO/J3MOQ==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@lezer/java": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-javascript": { + "version": "6.2.5", + "resolved": "https://registry.npmjs.org/@codemirror/lang-javascript/-/lang-javascript-6.2.5.tgz", + "integrity": "sha512-zD4e5mS+50htS7F+TYjBPsiIFGanfVqg4HyUz6WNFikgOPf2BgKlx+TQedI1w6n/IqRBVBbBWmGFdLB/7uxO4A==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/language": "^6.6.0", + "@codemirror/lint": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.17.0", + "@lezer/common": "^1.0.0", + "@lezer/javascript": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-json": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@codemirror/lang-json/-/lang-json-6.0.2.tgz", + "integrity": "sha512-x2OtO+AvwEHrEwR0FyyPtfDUiloG3rnVTSZV1W8UteaLL8/MajQd8DpvUb2YVzC+/T18aSDv0H9mu+xw0EStoQ==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@lezer/json": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-markdown": { + "version": "6.5.0", + "resolved": "https://registry.npmjs.org/@codemirror/lang-markdown/-/lang-markdown-6.5.0.tgz", + "integrity": "sha512-0K40bZ35jpHya6FriukbgaleaqzBLZfOh7HuzqbMxBXkbYMJDxfF39c23xOgxFezR+3G+tR2/Mup+Xk865OMvw==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.7.1", + "@codemirror/lang-html": "^6.0.0", + "@codemirror/language": "^6.3.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.0.0", + "@lezer/common": "^1.2.1", + "@lezer/markdown": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-php": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@codemirror/lang-php/-/lang-php-6.0.2.tgz", + "integrity": "sha512-ZKy2v1n8Fc8oEXj0Th0PUMXzQJ0AIR6TaZU+PbDHExFwdu+guzOA4jmCHS1Nz4vbFezwD7LyBdDnddSJeScMCA==", + "license": "MIT", + "dependencies": { + "@codemirror/lang-html": "^6.0.0", + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.0.0", + "@lezer/php": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-python": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/@codemirror/lang-python/-/lang-python-6.2.1.tgz", + "integrity": "sha512-IRjC8RUBhn9mGR9ywecNhB51yePWCGgvHfY1lWN/Mrp3cKuHr0isDKia+9HnvhiWNnMpbGhWrkhuWOc09exRyw==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.3.2", + "@codemirror/language": "^6.8.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.2.1", + "@lezer/python": "^1.1.4" + } + }, + "node_modules/@codemirror/lang-rust": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@codemirror/lang-rust/-/lang-rust-6.0.2.tgz", + "integrity": "sha512-EZaGjCUegtiU7kSMvOfEZpaCReowEf3yNidYu7+vfuGTm9ow4mthAparY5hisJqOHmJowVH3Upu+eJlUji6qqA==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0", + "@lezer/rust": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-sass": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/@codemirror/lang-sass/-/lang-sass-6.0.2.tgz", + "integrity": "sha512-l/bdzIABvnTo1nzdY6U+kPAC51czYQcOErfzQ9zSm9D8GmNPD0WTW8st/CJwBTPLO8jlrbyvlSEcN20dc4iL0Q==", + "license": "MIT", + "dependencies": { + "@codemirror/lang-css": "^6.2.0", + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.0.2", + "@lezer/sass": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-sql": { + "version": "6.10.0", + "resolved": "https://registry.npmjs.org/@codemirror/lang-sql/-/lang-sql-6.10.0.tgz", + "integrity": "sha512-6ayPkEd/yRw0XKBx5uAiToSgGECo/GY2NoJIHXIIQh1EVwLuKoU8BP/qK0qH5NLXAbtJRLuT73hx7P9X34iO4w==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-xml": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/@codemirror/lang-xml/-/lang-xml-6.1.0.tgz", + "integrity": "sha512-3z0blhicHLfwi2UgkZYRPioSgVTo9PV5GP5ducFH6FaHy0IAJRg+ixj5gTR1gnT/glAIC8xv4w2VL1LoZfs+Jg==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/language": "^6.4.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.0.0", + "@lezer/common": "^1.0.0", + "@lezer/xml": "^1.0.0" + } + }, + "node_modules/@codemirror/lang-yaml": { + "version": "6.1.3", + "resolved": "https://registry.npmjs.org/@codemirror/lang-yaml/-/lang-yaml-6.1.3.tgz", + "integrity": "sha512-AZ8DJBuXGVHybpBQhmZtgew5//4hv3tdkXnr3vDmOUMJRuB6vn/uuwtmTOTlqEaQFg3hQSVeA90NmvIQyUV6FQ==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/language": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.2.0", + "@lezer/lr": "^1.0.0", + "@lezer/yaml": "^1.0.0" + } + }, + "node_modules/@codemirror/language": { + "version": "6.12.3", + "resolved": "https://registry.npmjs.org/@codemirror/language/-/language-6.12.3.tgz", + "integrity": "sha512-QwCZW6Tt1siP37Jet9Tb02Zs81TQt6qQrZR2H+eGMcFsL1zMrk2/b9CLC7/9ieP1fjIUMgviLWMmgiHoJrj+ZA==", + "license": "MIT", + "dependencies": { + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.23.0", + "@lezer/common": "^1.5.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0", + "style-mod": "^4.0.0" + } + }, + "node_modules/@codemirror/legacy-modes": { + "version": "6.5.3", + "resolved": "https://registry.npmjs.org/@codemirror/legacy-modes/-/legacy-modes-6.5.3.tgz", + "integrity": "sha512-xCsmIzH78MyWkib9jlPaaun57XNkfbMIhagfaZVd0iLTqlpw3jXaIcbZm72MTmmn64eTZpBVNjbyYh+QXnxRsg==", + "license": "MIT", + "dependencies": { + "@codemirror/language": "^6.0.0" + } + }, + "node_modules/@codemirror/lint": { + "version": "6.9.6", + "resolved": "https://registry.npmjs.org/@codemirror/lint/-/lint-6.9.6.tgz", + "integrity": "sha512-6Kp7r6XfCi/D/5sdXieMfg9pJU1bUEx96WITuLU6ESaKizCz0QHFMjY/TaFSbigDdEAIgi93itLBIUETP4oK+A==", + "license": "MIT", + "dependencies": { + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.42.0", + "crelt": "^1.0.5" + } + }, + "node_modules/@codemirror/search": { + "version": "6.7.0", + "resolved": "https://registry.npmjs.org/@codemirror/search/-/search-6.7.0.tgz", + "integrity": "sha512-ZvGm99wc/s2cITtMT15LFdn8aH/aS+V+DqyGq/N5ZlV5vWtH+nILvC2nw0zX7ByNoHHDZ2IxxdW38O0tc5nVHg==", + "license": "MIT", + "dependencies": { + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.37.0", + "crelt": "^1.0.5" + } + }, + "node_modules/@codemirror/state": { + "version": "6.6.0", + "resolved": "https://registry.npmjs.org/@codemirror/state/-/state-6.6.0.tgz", + "integrity": "sha512-4nbvra5R5EtiCzr9BTHiTLc+MLXK2QGiAVYMyi8PkQd3SR+6ixar/Q/01Fa21TBIDOZXgeWV4WppsQolSreAPQ==", + "license": "MIT", + "dependencies": { + "@marijn/find-cluster-break": "^1.0.0" + } + }, + "node_modules/@codemirror/view": { + "version": "6.43.0", + "resolved": "https://registry.npmjs.org/@codemirror/view/-/view-6.43.0.tgz", + "integrity": "sha512-V7ZCLQO3Jus9hzh2jVCCPW3mO4IBMr43O37PqSUYautJSnnJF41YlgLw21x0fLJTYvJ+Vkm6Gp+qKGH9pltgXA==", + "license": "MIT", + "dependencies": { + "@codemirror/state": "^6.6.0", + "crelt": "^1.0.6", + "style-mod": "^4.1.0", + "w3c-keyname": "^2.2.4" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.21.5.tgz", + "integrity": "sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.21.5.tgz", + "integrity": "sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.21.5.tgz", + "integrity": "sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.21.5.tgz", + "integrity": "sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.21.5.tgz", + "integrity": "sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.21.5.tgz", + "integrity": "sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.21.5.tgz", + "integrity": "sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.21.5.tgz", + "integrity": "sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.21.5.tgz", + "integrity": "sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.21.5.tgz", + "integrity": "sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.21.5.tgz", + "integrity": "sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.21.5.tgz", + "integrity": "sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.21.5.tgz", + "integrity": "sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==", + "cpu": [ + "mips64el" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.21.5.tgz", + "integrity": "sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.21.5.tgz", + "integrity": "sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.21.5.tgz", + "integrity": "sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.21.5.tgz", + "integrity": "sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.21.5.tgz", + "integrity": "sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.21.5.tgz", + "integrity": "sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.21.5.tgz", + "integrity": "sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.21.5.tgz", + "integrity": "sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.21.5.tgz", + "integrity": "sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.21.5.tgz", + "integrity": "sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.13", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", + "integrity": "sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/sourcemap-codec": "^1.5.0", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/remapping": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/remapping/-/remapping-2.3.5.tgz", + "integrity": "sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.24" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", + "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/sourcemap-codec": { + "version": "1.5.5", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.5.tgz", + "integrity": "sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==", + "dev": true, + "license": "MIT" + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.31", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.31.tgz", + "integrity": "sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" + } + }, + "node_modules/@lezer/common": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/@lezer/common/-/common-1.5.2.tgz", + "integrity": "sha512-sxQE460fPZyU3sdc8lafxiPwJHBzZRy/udNFynGQky1SePYBdhkBl1kOagA9uT3pxR8K09bOrmTUqA9wb/PjSQ==", + "license": "MIT" + }, + "node_modules/@lezer/cpp": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/@lezer/cpp/-/cpp-1.1.6.tgz", + "integrity": "sha512-vh9gWWJOXFVY8HBHK3Twzq8MgwG2iN4GSyzBP9sCGTe37P15x2R14VaBQk0VA0ezTRN1KHYBBsHhvpGZ2Xy/pA==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/css": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/@lezer/css/-/css-1.3.3.tgz", + "integrity": "sha512-RzBo8r+/6QJeow7aPHIpGVIH59xTcJXp399820gZoMo9noQDRVpJLheIBUicYwKcsbOYoBRoLZlf2720dG/4Tg==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.3.0" + } + }, + "node_modules/@lezer/highlight": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/@lezer/highlight/-/highlight-1.2.3.tgz", + "integrity": "sha512-qXdH7UqTvGfdVBINrgKhDsVTJTxactNNxLk7+UMwZhU13lMHaOBlJe9Vqp907ya56Y3+ed2tlqzys7jDkTmW0g==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.3.0" + } + }, + "node_modules/@lezer/html": { + "version": "1.3.13", + "resolved": "https://registry.npmjs.org/@lezer/html/-/html-1.3.13.tgz", + "integrity": "sha512-oI7n6NJml729m7pjm9lvLvmXbdoMoi2f+1pwSDJkl9d68zGr7a9Btz8NdHTGQZtW2DA25ybeuv/SyDb9D5tseg==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/java": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@lezer/java/-/java-1.1.3.tgz", + "integrity": "sha512-yHquUfujwg6Yu4Fd1GNHCvidIvJwi/1Xu2DaKl/pfWIA2c1oXkVvawH3NyXhCaFx4OdlYBVX5wvz2f7Aoa/4Xw==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/javascript": { + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/@lezer/javascript/-/javascript-1.5.4.tgz", + "integrity": "sha512-vvYx3MhWqeZtGPwDStM2dwgljd5smolYD2lR2UyFcHfxbBQebqx8yjmFmxtJ/E6nN6u1D9srOiVWm3Rb4tmcUA==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.1.3", + "@lezer/lr": "^1.3.0" + } + }, + "node_modules/@lezer/json": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@lezer/json/-/json-1.0.3.tgz", + "integrity": "sha512-BP9KzdF9Y35PDpv04r0VeSTKDeox5vVr3efE7eBbx3r4s3oNLfunchejZhjArmeieBH+nVOpgIiBJpEAv8ilqQ==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/lr": { + "version": "1.4.10", + "resolved": "https://registry.npmjs.org/@lezer/lr/-/lr-1.4.10.tgz", + "integrity": "sha512-rnCpTIBafOx4mRp43xOxDJbFipJm/c0cia/V5TiGlhmMa+wsSdoGmUN3w5Bqrks/09Q/D4tNAmWaT8p6NRi77A==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.0.0" + } + }, + "node_modules/@lezer/markdown": { + "version": "1.6.4", + "resolved": "https://registry.npmjs.org/@lezer/markdown/-/markdown-1.6.4.tgz", + "integrity": "sha512-N0SxazMj4k65DBfaf1azqtMZd6u7MqluP84/NZnB/io8Td9aleFmAhz9hcbvSfsxT5tdYlJ5qgv5aMJGY4zEtA==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.5.0", + "@lezer/highlight": "^1.0.0" + } + }, + "node_modules/@lezer/php": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@lezer/php/-/php-1.0.5.tgz", + "integrity": "sha512-W7asp9DhM6q0W6DYNwIkLSKOvxlXRrif+UXBMxzsJUuqmhE7oVU+gS3THO4S/Puh7Xzgm858UNaFi6dxTP8dJA==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.1.0" + } + }, + "node_modules/@lezer/python": { + "version": "1.1.19", + "resolved": "https://registry.npmjs.org/@lezer/python/-/python-1.1.19.tgz", + "integrity": "sha512-MhQIURHRytsNzP/YXnqpYKW6la6voAH3kyplTOOiCdjyFY6cWWGFVmYVdHIPrElqSDf4iCDktQCockB9FxuhzQ==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/rust": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@lezer/rust/-/rust-1.0.2.tgz", + "integrity": "sha512-Lz5sIPBdF2FUXcWeCu1//ojFAZqzTQNRga0aYv6dYXqJqPfMdCAI0NzajWUd4Xijj1IKJLtjoXRPMvTKWBcqKg==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/sass": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@lezer/sass/-/sass-1.1.0.tgz", + "integrity": "sha512-3mMGdCTUZ/84ArHOuXWQr37pnf7f+Nw9ycPUeKX+wu19b7pSMcZGLbaXwvD2APMBDOGxPmpK/O6S1v1EvLoqgQ==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/xml": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/@lezer/xml/-/xml-1.0.6.tgz", + "integrity": "sha512-CdDwirL0OEaStFue/66ZmFSeppuL6Dwjlk8qk153mSQwiSH/Dlri4GNymrNWnUmPl2Um7QfV1FO9KFUyX3Twww==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.0.0" + } + }, + "node_modules/@lezer/yaml": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@lezer/yaml/-/yaml-1.0.4.tgz", + "integrity": "sha512-2lrrHqxalACEbxIbsjhqGpSW8kWpUKuY6RHgnSAFZa6qK62wvnPxA8hGOwOoDbwHcOFs5M4o27mjGu+P7TvBmw==", + "license": "MIT", + "dependencies": { + "@lezer/common": "^1.2.0", + "@lezer/highlight": "^1.0.0", + "@lezer/lr": "^1.4.0" + } + }, + "node_modules/@marijn/find-cluster-break": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@marijn/find-cluster-break/-/find-cluster-break-1.0.2.tgz", + "integrity": "sha512-l0h88YhZFyKdXIFNfSWpyjStDjGHwZ/U7iobcK1cQQD8sejsONdQtTVU+1wVN1PBw40PiiHB1vA5S7VTfQiP9g==", + "license": "MIT" + }, + "node_modules/@pierre/trees": { + "version": "1.0.0-beta.4", + "resolved": "https://registry.npmjs.org/@pierre/trees/-/trees-1.0.0-beta.4.tgz", + "integrity": "sha512-OfT1yk9ne8Te5+GB5zUY8yqE6B8BqjBHQJleH4lu8ltwNpoocZl4vXt1AzlEExpxI/pp+AFX5QG+lR3JjtTEag==", + "license": "apache-2.0", + "dependencies": { + "preact": "11.0.0-beta.0", + "preact-render-to-string": "6.6.5" + }, + "peerDependencies": { + "react": "^18.3.1 || ^19.0.0", + "react-dom": "^18.3.1 || ^19.0.0" + } + }, + "node_modules/@rolldown/pluginutils": { + "version": "1.0.0-beta.27", + "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.0.0-beta.27.tgz", + "integrity": "sha512-+d0F4MKMCbeVUJwG96uQ4SgAznZNSq93I3V+9NHA4OpvqG8mRCpGdKmK8l/dl02h2CCDHwW2FqilnTyDcAnqjA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@rollup/rollup-android-arm-eabi": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.61.1.tgz", + "integrity": "sha512-JnBB8MdXj45cajvTuO5FmPlvFVJRQgvrz1uSEl3NwqFnReAPGwb8EanbGi4z2nRaqLzjJSv5/JmycoTKlRZxHA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-android-arm64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.61.1.tgz", + "integrity": "sha512-Jx2g7iSjw4AOT0HDPHM9RV3GNjRXwybWtSFZiZAYUTjUwjVrYIwq3kBf+LnhqJlzXFAqTAh2F7IGI+O568exPw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ] + }, + "node_modules/@rollup/rollup-darwin-arm64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.61.1.tgz", + "integrity": "sha512-0F1L/Z3Eqv8mT2n3dCpeO8GcTvHvVqkP5/t6DMsn0KzhYVcg+s7Ncl5DS8qjKYEeio6Az0Gt6nyBORay5qIlCA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-darwin-x64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.61.1.tgz", + "integrity": "sha512-qLttcH871ujY4YcVfUSShhOw+CsoTatYz8gRbHO7Bb92QH059/P0y5do1KMs41fY0BpD2x4AJH/gID0zFiqVKQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@rollup/rollup-freebsd-arm64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.61.1.tgz", + "integrity": "sha512-fUI4RapGE0Oh3mb8mgfvC1O2nU1RpDZUKnDQm3xB1Ipg7C2wTs5Kstz7G2uWK99a8S2yTMq8/P4uycwNa0nJyw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-freebsd-x64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.61.1.tgz", + "integrity": "sha512-H5YrdvJaDtI/U9/emrD4b++xkvp3y/JvOe4rizHbxvkyMfRS/CiRYdji+Pl8D0brEaNFWUh1drQxgAGIl6Xudw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ] + }, + "node_modules/@rollup/rollup-linux-arm-gnueabihf": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.61.1.tgz", + "integrity": "sha512-Q8CBCCQtDFrYtXoeUXSrnFXKOnyUhx6bz+SkL6A0E7V8kAiCJ5pamq1WtbfpVGhR5TSpXY6ak3avmDc5fHTyJA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm-musleabihf": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.61.1.tgz", + "integrity": "sha512-nwnhk1581l0FBVellGcVCAT0Oi06onEA3WB53sf01VO3I0UPBkMH9sXONYME2K0ovXcNayJfNtHfm6mpJElatQ==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.61.1.tgz", + "integrity": "sha512-x5Xr49hwt3hdW75UOZm3395YwwzPyauktslv29KpWL/T+vVAzoT3azLcTWv0eMciBNrx+DYjH4paehHoLpPvpg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-arm64-musl": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.61.1.tgz", + "integrity": "sha512-unMS3H73DpaoPyyEVPjGKleM/s0mkmsauTENpw4INQY8y4+IuLNjkueQ5QCtC0D3N38Y38yhAU8OoZ20S2Tm6w==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-loong64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.61.1.tgz", + "integrity": "sha512-zNZzGRnAhwjFEYmvphJRV5XaQGjs62cCmeYYHUT//NbvEnHauw+I85nGG+SiVg5ld4GX8D1IbKIX+ozITQnhMQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-loong64-musl": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-musl/-/rollup-linux-loong64-musl-4.61.1.tgz", + "integrity": "sha512-LdpWGL8X209B2SIvWjqlc8VZgM6PKfontSerGepuldQmHYrAOtnMCXeJkxXGbC+PPZVOuu5czJo7fNV6aeW8rQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-ppc64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.61.1.tgz", + "integrity": "sha512-EC5kTtNaNGOmbMGqar8dvJy6y/hg99GAwjfBz++pxZhQATXGcRjd6c5en5wcbru0vkRmiMGsQKdMJOOf6sza4g==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-ppc64-musl": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-musl/-/rollup-linux-ppc64-musl-4.61.1.tgz", + "integrity": "sha512-8hiwp6D4acEcNK78I4rP0/XtS1sknWIAMJBPdR4l6zUtyTm5KiTDr5bXmWt4foY7nAN7AThDHgkLIEZOWKbzWw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.61.1.tgz", + "integrity": "sha512-10dh/h/BqA7DuMPWSxkR8uks18FRwnwOEqr5zOTEl+NOwP/OMzKX8OFR/Of9xxDA7D5qef1Nzar5WDD2kCCr1g==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-riscv64-musl": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.61.1.tgz", + "integrity": "sha512-YKJ5lg35DP17gcAOggnihe+APw9HLyj1Xn7gsmGumBJAUDa6NGXNixJzmkWLhcK9TOuuyQjdamzvJefkO7qHZQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-s390x-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.61.1.tgz", + "integrity": "sha512-Mlil5G2Jj6a7B3LWGctg+XPL9vdXYuzCtNXfxOQ0nPjc2m6ueUktocPGH9bnAM0bNRKb/bAWTujUU7IJQdQA+g==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.61.1.tgz", + "integrity": "sha512-bVWIOIk6pV01p4CdUbPP7CJ/434z+OooYjDuFcR+44N35YvKUC66G8MGnvcWx5mWKW3g61J+t74l3Kj15Kwn2Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-linux-x64-musl": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.61.1.tgz", + "integrity": "sha512-qy5pBvZbqNFheBz61R1rzsezjm0J7O2oNGoWtGoY89SZYLUfxAJTBAqDChqAIdB4rCiIbi9nF7yZ83GnNiLwSw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@rollup/rollup-openbsd-x64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-openbsd-x64/-/rollup-openbsd-x64-4.61.1.tgz", + "integrity": "sha512-E83TXjI4zm0+5f2qO+UOudaCYIhYwpJ5jq6YCZNIZ+6CbfhKrkAGezeiASBL9ElxAxFsRS9ZhESv8mfnj6TKeg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ] + }, + "node_modules/@rollup/rollup-openharmony-arm64": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.61.1.tgz", + "integrity": "sha512-fbWnKqVkjrJN38vNe3ahkbk6iejS/3b0Nt7EEtPpE6RBacZcGXNKbzfHN3GUUlXOPghUg0j6XUGrtjX9z1sIvA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ] + }, + "node_modules/@rollup/rollup-win32-arm64-msvc": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.61.1.tgz", + "integrity": "sha512-ArMl38iVAbk0New1ogihQNY6iphLi4ZaRsa037gUzv5yeKPY8TD3Dmy4x2RNC1VztU/uqm+G+/RwFrSka3Oy2g==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-ia32-msvc": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.61.1.tgz", + "integrity": "sha512-0mYtjHS9ucAbcATycCNK9IGBk/cCe/ma7EmSLGZdsxnOA8cjRIyU04wDpVAD9NiOfLUR9KTxdiO53uOkherqjQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-gnu": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.61.1.tgz", + "integrity": "sha512-gK1iCEPfpoSG9wfBihXxvBMi8ZfcWffYkEsC/Eih+iFENTaewvNcrEQ69lIOWYO5pePHKLHHO7nq5AILGO/HQQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@rollup/rollup-win32-x64-msvc": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.61.1.tgz", + "integrity": "sha512-X+zaP2x+j4RXGfbp/seSoRHWnPxzApilDszisZxbYH5C/jTxFhCtDNdPGZb9lJyYPs24wGxruPF7Y+sIXt9Gzw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@types/babel__core": { + "version": "7.20.5", + "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.20.5.tgz", + "integrity": "sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.20.7", + "@babel/types": "^7.20.7", + "@types/babel__generator": "*", + "@types/babel__template": "*", + "@types/babel__traverse": "*" + } + }, + "node_modules/@types/babel__generator": { + "version": "7.27.0", + "resolved": "https://registry.npmjs.org/@types/babel__generator/-/babel__generator-7.27.0.tgz", + "integrity": "sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__template": { + "version": "7.4.4", + "resolved": "https://registry.npmjs.org/@types/babel__template/-/babel__template-7.4.4.tgz", + "integrity": "sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.1.0", + "@babel/types": "^7.0.0" + } + }, + "node_modules/@types/babel__traverse": { + "version": "7.28.0", + "resolved": "https://registry.npmjs.org/@types/babel__traverse/-/babel__traverse-7.28.0.tgz", + "integrity": "sha512-8PvcXf70gTDZBgt9ptxJ8elBeBjcLOAcOtoO/mPJjtji1+CdGbHgm77om1GrsPxsiE+uXIpNSK64UYaIwQXd4Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/types": "^7.28.2" + } + }, + "node_modules/@types/estree": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.9.tgz", + "integrity": "sha512-GhdPgy1el4/ImP05X05Uw4cw2/M93BCUmnEvWZNStlCzEKME4Fkk+YpoA5OiHNQmoS7Cafb8Xa3Pya8m1Qrzeg==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/react": { + "version": "19.2.16", + "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.16.tgz", + "integrity": "sha512-esJiCAnl0kfpNdE69f3So4WJUXy95dLZydX0KwK46riIHDzHM7O9Vtf9xCHW0PXIqvgqNrswl522kA/5yx+F4w==", + "dev": true, + "license": "MIT", + "dependencies": { + "csstype": "^3.2.2" + } + }, + "node_modules/@types/react-dom": { + "version": "19.2.3", + "resolved": "https://registry.npmjs.org/@types/react-dom/-/react-dom-19.2.3.tgz", + "integrity": "sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "@types/react": "^19.2.0" + } + }, + "node_modules/@vitejs/plugin-react": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/@vitejs/plugin-react/-/plugin-react-4.7.0.tgz", + "integrity": "sha512-gUu9hwfWvvEDBBmgtAowQCojwZmJ5mcLn3aufeCsitijs3+f2NsrPtlAWIR6OPiqljl96GVCUbLe0HyqIpVaoA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/core": "^7.28.0", + "@babel/plugin-transform-react-jsx-self": "^7.27.1", + "@babel/plugin-transform-react-jsx-source": "^7.27.1", + "@rolldown/pluginutils": "1.0.0-beta.27", + "@types/babel__core": "^7.20.5", + "react-refresh": "^0.17.0" + }, + "engines": { + "node": "^14.18.0 || >=16.0.0" + }, + "peerDependencies": { + "vite": "^4.2.0 || ^5.0.0 || ^6.0.0 || ^7.0.0" + } + }, + "node_modules/baseline-browser-mapping": { + "version": "2.10.33", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.10.33.tgz", + "integrity": "sha512-bA6+tcSLpz2tIEdDXZPpPTIuxBcC4+w6SieaYyfigIa4h8GlFxbA17v22Vx3JUtuZQj9SgOsnbK+aTBzyDyEuw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "baseline-browser-mapping": "dist/cli.cjs" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/browserslist": { + "version": "4.28.2", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.2.tgz", + "integrity": "sha512-48xSriZYYg+8qXna9kwqjIVzuQxi+KYWp2+5nCYnYKPTr0LvD89Jqk2Or5ogxz0NUMfIjhh2lIUX/LyX9B4oIg==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "baseline-browser-mapping": "^2.10.12", + "caniuse-lite": "^1.0.30001782", + "electron-to-chromium": "^1.5.328", + "node-releases": "^2.0.36", + "update-browserslist-db": "^1.2.3" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001793", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001793.tgz", + "integrity": "sha512-iwSsYWaCOoh26cV8NwNRViHlrfUvYsHDfRVcbtmw0Kg6PJIZZXwMkj1442FYLBGkeUf1juAsU3DTfxW579mrPA==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "CC-BY-4.0" + }, + "node_modules/codemirror": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/codemirror/-/codemirror-6.0.2.tgz", + "integrity": "sha512-VhydHotNW5w1UGK0Qj96BwSk/Zqbp9WbnyK2W/eVMv4QyF41INRGpjUhFJY7/uDNuudSc33a/PKr4iDqRduvHw==", + "license": "MIT", + "dependencies": { + "@codemirror/autocomplete": "^6.0.0", + "@codemirror/commands": "^6.0.0", + "@codemirror/language": "^6.0.0", + "@codemirror/lint": "^6.0.0", + "@codemirror/search": "^6.0.0", + "@codemirror/state": "^6.0.0", + "@codemirror/view": "^6.0.0" + } + }, + "node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true, + "license": "MIT" + }, + "node_modules/crelt": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/crelt/-/crelt-1.0.6.tgz", + "integrity": "sha512-VQ2MBenTq1fWZUH9DJNGti7kKv6EeAuYr3cLwxUWhIu1baTaXh4Ib5W2CqHVqib4/MqbYGJqiL3Zb8GJZr3l4g==", + "license": "MIT" + }, + "node_modules/csstype": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", + "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/debug": { + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/electron-to-chromium": { + "version": "1.5.367", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.367.tgz", + "integrity": "sha512-4Mk/mrynCNQ+atY40D3UpmhLWB6AHMbYMlIrPhHcMF6x0L7O0b052FCAsxw1LlaR++UFuNg3D/A6XCuGDa0guQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/esbuild": { + "version": "0.21.5", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.21.5.tgz", + "integrity": "sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.21.5", + "@esbuild/android-arm": "0.21.5", + "@esbuild/android-arm64": "0.21.5", + "@esbuild/android-x64": "0.21.5", + "@esbuild/darwin-arm64": "0.21.5", + "@esbuild/darwin-x64": "0.21.5", + "@esbuild/freebsd-arm64": "0.21.5", + "@esbuild/freebsd-x64": "0.21.5", + "@esbuild/linux-arm": "0.21.5", + "@esbuild/linux-arm64": "0.21.5", + "@esbuild/linux-ia32": "0.21.5", + "@esbuild/linux-loong64": "0.21.5", + "@esbuild/linux-mips64el": "0.21.5", + "@esbuild/linux-ppc64": "0.21.5", + "@esbuild/linux-riscv64": "0.21.5", + "@esbuild/linux-s390x": "0.21.5", + "@esbuild/linux-x64": "0.21.5", + "@esbuild/netbsd-x64": "0.21.5", + "@esbuild/openbsd-x64": "0.21.5", + "@esbuild/sunos-x64": "0.21.5", + "@esbuild/win32-arm64": "0.21.5", + "@esbuild/win32-ia32": "0.21.5", + "@esbuild/win32-x64": "0.21.5" + } + }, + "node_modules/escalade": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz", + "integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/gensync": { + "version": "1.0.0-beta.2", + "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", + "integrity": "sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", + "dev": true, + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true, + "license": "MIT" + }, + "node_modules/nanoid": { + "version": "3.3.12", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.12.tgz", + "integrity": "sha512-ZB9RH/39qpq5Vu6Y+NmUaFhQR6pp+M2Xt76XBnEwDaGcVAqhlvxrl3B2bKS5D3NH3QR76v3aSrKaF/Kiy7lEtQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "bin": { + "nanoid": "bin/nanoid.cjs" + }, + "engines": { + "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" + } + }, + "node_modules/node-releases": { + "version": "2.0.47", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.47.tgz", + "integrity": "sha512-Uzmd6LXpouKo8EUK68IjH4+E01w/hXyV3R3g/geCJo+rXLNfh1xucB+LOzYEOQPSiUK3h/xZf0cQGcSsmyL2Og==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" + }, + "node_modules/postcss": { + "version": "8.5.15", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.15.tgz", + "integrity": "sha512-FfR8sjd4em2T6fb3I2MwAJU7HWVMr9zba+enmQeeWFfCbm+UOC/0X4DS8XtpUTMwWMGbjKYP7xjfNekzyGmB3A==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "nanoid": "^3.3.12", + "picocolors": "^1.1.1", + "source-map-js": "^1.2.1" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/preact": { + "version": "11.0.0-beta.0", + "resolved": "https://registry.npmjs.org/preact/-/preact-11.0.0-beta.0.tgz", + "integrity": "sha512-IcODoASASYwJ9kxz7+MJeiJhvLriwSb4y4mHIyxdgaRZp6kPUud7xytrk/6GZw8U3y6EFJaRb5wi9SrEK+8+lg==", + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/preact" + } + }, + "node_modules/preact-render-to-string": { + "version": "6.6.5", + "resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-6.6.5.tgz", + "integrity": "sha512-O6MHzYNIKYaiSX3bOw0gGZfEbOmlIDtDfWwN1JJdc/T3ihzRT6tGGSEWE088dWrEDGa1u7101q+6fzQnO9XCPA==", + "license": "MIT", + "peerDependencies": { + "preact": ">=10 || >= 11.0.0-0" + } + }, + "node_modules/react": { + "version": "19.2.7", + "resolved": "https://registry.npmjs.org/react/-/react-19.2.7.tgz", + "integrity": "sha512-HNe9WslTbXmFK8o8cmwgAeJFSBvt1bPdHCVKtaaV+WlAN36mpT4hcRpwbf3fY56ar2oIXzsBpOAiIRHAdY0OlQ==", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-dom": { + "version": "19.2.7", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.2.7.tgz", + "integrity": "sha512-t0BRVXvbiE/o20Hfw669rLbMCDWtYZLvmJigy2f0MxsXF+71pxhR3xOkspmsO8h3ZlNzyibAmtCa3l4lYKk6gQ==", + "license": "MIT", + "dependencies": { + "scheduler": "^0.27.0" + }, + "peerDependencies": { + "react": "^19.2.7" + } + }, + "node_modules/react-refresh": { + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.17.0.tgz", + "integrity": "sha512-z6F7K9bV85EfseRCp2bzrpyQ0Gkw1uLoCel9XBVWPg/TjRj94SkJzUTGfOa4bs7iJvBWtQG0Wq7wnI0syw3EBQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/rollup": { + "version": "4.61.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.61.1.tgz", + "integrity": "sha512-I4KW6iuRpuu2uHBLraZ1wNZe0DP7lnRha+VJ9tNaYVaVgKhW0aI3h4RYnoRPeql0flHm/Co55b7snEDcOfOJrA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "1.0.9" + }, + "bin": { + "rollup": "dist/bin/rollup" + }, + "engines": { + "node": ">=18.0.0", + "npm": ">=8.0.0" + }, + "optionalDependencies": { + "@rollup/rollup-android-arm-eabi": "4.61.1", + "@rollup/rollup-android-arm64": "4.61.1", + "@rollup/rollup-darwin-arm64": "4.61.1", + "@rollup/rollup-darwin-x64": "4.61.1", + "@rollup/rollup-freebsd-arm64": "4.61.1", + "@rollup/rollup-freebsd-x64": "4.61.1", + "@rollup/rollup-linux-arm-gnueabihf": "4.61.1", + "@rollup/rollup-linux-arm-musleabihf": "4.61.1", + "@rollup/rollup-linux-arm64-gnu": "4.61.1", + "@rollup/rollup-linux-arm64-musl": "4.61.1", + "@rollup/rollup-linux-loong64-gnu": "4.61.1", + "@rollup/rollup-linux-loong64-musl": "4.61.1", + "@rollup/rollup-linux-ppc64-gnu": "4.61.1", + "@rollup/rollup-linux-ppc64-musl": "4.61.1", + "@rollup/rollup-linux-riscv64-gnu": "4.61.1", + "@rollup/rollup-linux-riscv64-musl": "4.61.1", + "@rollup/rollup-linux-s390x-gnu": "4.61.1", + "@rollup/rollup-linux-x64-gnu": "4.61.1", + "@rollup/rollup-linux-x64-musl": "4.61.1", + "@rollup/rollup-openbsd-x64": "4.61.1", + "@rollup/rollup-openharmony-arm64": "4.61.1", + "@rollup/rollup-win32-arm64-msvc": "4.61.1", + "@rollup/rollup-win32-ia32-msvc": "4.61.1", + "@rollup/rollup-win32-x64-gnu": "4.61.1", + "@rollup/rollup-win32-x64-msvc": "4.61.1", + "fsevents": "~2.3.2" + } + }, + "node_modules/scheduler": { + "version": "0.27.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz", + "integrity": "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==", + "license": "MIT" + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/source-map-js": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", + "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==", + "dev": true, + "license": "BSD-3-Clause", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/style-mod": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/style-mod/-/style-mod-4.1.3.tgz", + "integrity": "sha512-i/n8VsZydrugj3Iuzll8+x/00GH2vnYsk1eomD8QiRrSAeW6ItbCQDtfXCeJHd0iwiNagqjQkvpvREEPtW3IoQ==", + "license": "MIT" + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/update-browserslist-db": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz", + "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "license": "MIT", + "dependencies": { + "escalade": "^3.2.0", + "picocolors": "^1.1.1" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/vite": { + "version": "5.4.21", + "resolved": "https://registry.npmjs.org/vite/-/vite-5.4.21.tgz", + "integrity": "sha512-o5a9xKjbtuhY6Bi5S3+HvbRERmouabWbyUcpXXUA1u+GNUKoROi9byOJ8M0nHbHYHkYICiMlqxkg1KkYmm25Sw==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "^0.21.3", + "postcss": "^8.4.43", + "rollup": "^4.20.0" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "node": "^18.0.0 || >=20.0.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^18.0.0 || >=20.0.0", + "less": "*", + "lightningcss": "^1.21.0", + "sass": "*", + "sass-embedded": "*", + "stylus": "*", + "sugarss": "*", + "terser": "^5.4.0" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "less": { + "optional": true + }, + "lightningcss": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + } + } + }, + "node_modules/w3c-keyname": { + "version": "2.2.8", + "resolved": "https://registry.npmjs.org/w3c-keyname/-/w3c-keyname-2.2.8.tgz", + "integrity": "sha512-dpojBhNsCNN7T82Tm7k26A6G9ML3NkhDsnw9n/eoxSRlVBB4CEtIQ/KTCLI2Fwf3ataSXRhYFkQi3SlnFwPvPQ==", + "license": "MIT" + }, + "node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "dev": true, + "license": "ISC" + } + } +} diff --git a/srcjs/package.json b/srcjs/package.json new file mode 100644 index 0000000..eeef03b --- /dev/null +++ b/srcjs/package.json @@ -0,0 +1,44 @@ +{ + "name": "autosync-frontend", + "private": true, + "version": "0.0.0", + "type": "module", + "description": "React frontend for autosync's amsync_app(), built on shinyreact.", + "scripts": { + "build": "vite build", + "dev": "vite build --watch", + "lint": "tsc --noEmit" + }, + "dependencies": { + "@codemirror/commands": "^6.7.1", + "@codemirror/lang-cpp": "^6.0.2", + "@codemirror/lang-css": "^6.3.1", + "@codemirror/lang-html": "^6.4.9", + "@codemirror/lang-java": "^6.0.1", + "@codemirror/lang-javascript": "^6.2.3", + "@codemirror/lang-json": "^6.0.1", + "@codemirror/lang-markdown": "^6.3.2", + "@codemirror/lang-php": "^6.0.1", + "@codemirror/lang-python": "^6.1.7", + "@codemirror/lang-rust": "^6.0.1", + "@codemirror/lang-sass": "^6.0.2", + "@codemirror/lang-sql": "^6.8.0", + "@codemirror/lang-xml": "^6.1.0", + "@codemirror/lang-yaml": "^6.1.2", + "@codemirror/language": "^6.10.8", + "@codemirror/legacy-modes": "^6.4.3", + "@codemirror/state": "^6.5.0", + "@codemirror/view": "^6.36.1", + "@pierre/trees": "1.0.0-beta.4", + "codemirror": "^6.0.1" + }, + "devDependencies": { + "@types/react": "^19.0.0", + "@types/react-dom": "^19.0.0", + "@vitejs/plugin-react": "^4.3.4", + "react": "^19.0.0", + "react-dom": "^19.0.0", + "typescript": "^5.7.2", + "vite": "^5.4.11" + } +} diff --git a/srcjs/src/App.tsx b/srcjs/src/App.tsx new file mode 100644 index 0000000..8e5370c --- /dev/null +++ b/srcjs/src/App.tsx @@ -0,0 +1,63 @@ +// Top-level router. The R server drives the active screen through `output$view` +// ("connect" | "browse" | "edit" | "closed"); "edit" is the standalone live +// editor launched by the autosync_doc `$edit()` method. + +import type { ReactNode } from "react"; +import { useShinyEvent, useShinyInitialized, useShinyOutputValue } from "./shiny"; +import { ConnectScreen } from "./ConnectScreen"; +import { BrowseScreen } from "./BrowseScreen"; +import { Editor } from "./Editor"; +import { Toast } from "./Toast"; + +function EditScreen() { + const close = useShinyEvent("close"); + return ( +
+
+ Edit synced text (live) + +
+ +
+ ); +} + +function ClosedScreen() { + return ( +
+
Session ended
+

You can close this window.

+
+ ); +} + +export function App() { + const initialized = useShinyInitialized(); + const view = useShinyOutputValue("view", "connect") ?? "connect"; + + let screen: ReactNode; + if (!initialized) { + screen =
Connecting…
; + } else if (view === "closed") { + screen = ; + } else if (view === "browse") { + screen = ; + } else if (view === "edit") { + screen = ; + } else { + screen = ; + } + + return ( + <> + + {screen} + + ); +} diff --git a/srcjs/src/BrowseScreen.tsx b/srcjs/src/BrowseScreen.tsx new file mode 100644 index 0000000..944b0c3 --- /dev/null +++ b/srcjs/src/BrowseScreen.tsx @@ -0,0 +1,63 @@ +// Browse screen: a sidebar with the file tree and Refresh / Disconnect actions, +// and a main pane holding the live editor (or a prompt when nothing is open). + +import { useShinyEvent, useShinyOutputValue } from "./shiny"; +import { FileTreeView } from "./FileTree"; +import { FileIcon } from "./FileIcon"; +import { Editor } from "./Editor"; + +export function BrowseScreen() { + const paths = useShinyOutputValue("paths", []) ?? []; + const selected = useShinyOutputValue("selected", null) ?? null; + const refresh = useShinyEvent("refresh"); + const disconnect = useShinyEvent("disconnect"); + + return ( +
+ +
+ {selected ? ( +
+
+ + + {selected} + + live +
+ +
+ ) : ( +
+ Select a file from the sidebar to edit. +
+ )} +
+
+ ); +} diff --git a/srcjs/src/ConnectScreen.tsx b/srcjs/src/ConnectScreen.tsx new file mode 100644 index 0000000..25aacb0 --- /dev/null +++ b/srcjs/src/ConnectScreen.tsx @@ -0,0 +1,125 @@ +// Connect screen: server URL + project ID, an optional OIDC sign-in flow (run in +// R by sync_token()), and Connect / Exit. Mirrors the former bslib connect card. +// The R server prefills the fields via `output$init`; events fire R observers. + +import { React, useShinyEvent, useShinyInput, useShinyOutputValue } from "./shiny"; + +interface Init { + server: string; + proj_id: string; + // Provenance flags only — R never sends the env vars' values. Blank fields + // fall back to the environment server-side on connect. + client_id_env: boolean; + client_secret_env: boolean; + issuer: string; +} + +export function ConnectScreen() { + const init = useShinyOutputValue("init"); + const authed = useShinyOutputValue("authed", false) ?? false; + + const [url, setUrl] = useShinyInput("url", ""); + const [projId, setProjId] = useShinyInput("proj_id", ""); + const [clientId, setClientId] = useShinyInput("client_id", ""); + const [clientSecret, setClientSecret] = useShinyInput("client_secret", ""); + const [issuer, setIssuer] = useShinyInput("issuer", ""); + + const connect = useShinyEvent("connect"); + const exit = useShinyEvent("exit"); + + // Seed the form once from the R-supplied prefill/defaults. The OIDC client + // ID and secret are deliberately not seeded: R sends only whether the env + // vars are set (shown as placeholder text) and falls back to them when the + // fields are left blank. + const seeded = React.useRef(false); + React.useEffect(() => { + if (!init || seeded.current) return; + seeded.current = true; + if (init.server) setUrl(init.server); + if (init.proj_id) setProjId(init.proj_id); + if (init.issuer) setIssuer(init.issuer); + }, [init, setUrl, setProjId, setIssuer]); + + return ( +
+
+
+ autosync. +
+

Connect to a sync project

+ {authed &&

✓ signed in

} + + + + +
+ Advanced +
+

+ Provide a client ID to sign in (OIDC) automatically when you + connect. Leave blank for open servers. Fields shown as set from + the environment are used when left blank. +

+ + + +
+
+ + + +
+
+ ); +} diff --git a/srcjs/src/Editor.tsx b/srcjs/src/Editor.tsx new file mode 100644 index 0000000..15acabd --- /dev/null +++ b/srcjs/src/Editor.tsx @@ -0,0 +1,104 @@ +// Live CodeMirror 6 editor. The R server owns the Automerge document; this editor +// is a plain text view whose value flows over Shiny: +// * outgoing: real local edits -> `input$content` (debounced), where +// install_editor_sync() writes the minimal diff into the live document. We +// send imperatively via window.Shiny only from genuine edits — a hook like +// useSetShinyInput would broadcast its default ("") on mount and clobber the +// open document before the user types anything. +// * incoming: `output$editor_doc` ({ path, value, ext, rev }) is pushed on open +// and on every remote change. We re-apply it only when `rev` advances, in a +// transaction tagged `fromServer` so the update listener ignores it (no echo +// back to R), reconfiguring the language when the extension changes. + +import { basicSetup } from "codemirror"; +import { Annotation, Compartment, EditorState } from "@codemirror/state"; +import { EditorView, keymap } from "@codemirror/view"; +import { indentWithTab } from "@codemirror/commands"; +import { indentUnit } from "@codemirror/language"; + +import { React, useShinyOutputValue } from "./shiny"; +import { languageForExt } from "./languages"; + +interface EditorDoc { + path: string; + value: string; + ext: string; + rev: number; + debounce: number; +} + +// Marks transactions originating from the server so the update listener does not +// echo them back to R as a local edit. +const fromServer = Annotation.define(); + +export function Editor() { + const hostRef = React.useRef(null); + const viewRef = React.useRef(null); + const language = React.useRef(new Compartment()); + const lastRev = React.useRef(-1); + + const doc = useShinyOutputValue("editor_doc"); + + // Debounce config lives in a ref so the (once-created) update listener always + // reads the current value without re-creating the editor view. + const debounceRef = React.useRef(300); + debounceRef.current = doc?.debounce ?? 300; + const sendTimer = React.useRef(null); + + // Create the editor view once. + React.useEffect(() => { + const view = new EditorView({ + parent: hostRef.current ?? undefined, + state: EditorState.create({ + doc: "", + extensions: [ + // basicSetup bundles syntax highlighting (defaultHighlightStyle) plus + // line numbers, history, code folding, search (Ctrl-F), autocompletion, + // bracket matching/closing, active-line + selection-match highlighting. + basicSetup, + keymap.of([indentWithTab]), + indentUnit.of(" "), + EditorState.tabSize.of(2), + language.current.of([]), + EditorView.lineWrapping, + EditorView.updateListener.of((u) => { + if (!u.docChanged) return; + // Skip server-applied changes so we never echo them back to R. + if (u.transactions.some((t) => t.annotation(fromServer))) return; + const text = u.state.doc.toString(); + if (sendTimer.current != null) window.clearTimeout(sendTimer.current); + sendTimer.current = window.setTimeout(() => { + sendTimer.current = null; + window.Shiny?.setInputValue?.("content", text); + }, debounceRef.current); + }), + ], + }), + }); + viewRef.current = view; + return () => { + if (sendTimer.current != null) window.clearTimeout(sendTimer.current); + view.destroy(); + viewRef.current = null; + }; + }, []); + + // Apply server-pushed content/extension whenever the revision advances. + React.useEffect(() => { + const view = viewRef.current; + if (!view || !doc || doc.rev === lastRev.current) return; + lastRev.current = doc.rev; + const current = view.state.doc.toString(); + const effects = [language.current.reconfigure(languageForExt(doc.ext))]; + view.dispatch({ + changes: + current === doc.value + ? undefined + : { from: 0, to: current.length, insert: doc.value }, + effects, + annotations: fromServer.of(true), + }); + }, [doc]); + + return
; +} diff --git a/srcjs/src/FileIcon.tsx b/srcjs/src/FileIcon.tsx new file mode 100644 index 0000000..505cbcf --- /dev/null +++ b/srcjs/src/FileIcon.tsx @@ -0,0 +1,52 @@ +// Small file-type icon shown beside the open file's name in the editor header. +// Quarto (.qmd) gets the official Quarto glyph; everything else gets a neutral +// document icon so the header stays visually consistent. + +interface FileIconProps { + path: string; + className?: string; +} + +// Official Quarto mark (Simple Icons, viewBox 0 0 24 24), brand colour #39729E. +export const QUARTO_PATH = + "M12.65 12.854V24c6.042-.325 10.923-5.105 11.33-11.125H12.65Zm-1.504 0H.02c.427 " + + "5.94 5.166 10.699 11.105 11.105V12.854Zm1.505-1.505H24C23.675 5.247 18.753.325 " + + "12.65 0Zm-1.505 0V0C5.106.427.326 5.308 0 11.35Z"; + +function extOf(path: string): string { + const m = path.toLowerCase().match(/\.([^./\\]+)$/); + return m ? m[1] : ""; +} + +export function FileIcon({ path, className }: FileIconProps) { + if (extOf(path) === "qmd") { + return ( + + ); + } + return ( + + ); +} diff --git a/srcjs/src/FileTree.tsx b/srcjs/src/FileTree.tsx new file mode 100644 index 0000000..0e0965e --- /dev/null +++ b/srcjs/src/FileTree.tsx @@ -0,0 +1,69 @@ +// File tree powered by @pierre/trees (trees.software). The R project connection +// owns the file list; we receive the flat `paths` vector via `output$paths` and +// the path-first model builds the visual tree. Selecting a file row reports its +// canonical path back through `input$file`, which round-trips exactly to +// sync_project()'s `$open(path)`. + +import type { CSSProperties } from "react"; +import type { FileTreeIconConfig } from "@pierre/trees"; +import { themeToTreeStyles } from "@pierre/trees"; +import { FileTree, useFileTree, useFileTreeSelection } from "@pierre/trees/react"; + +import { React, fireShinyEvent } from "./shiny"; +import { QUARTO_PATH } from "./FileIcon"; + +// Light theme matching the app chrome; the tree renders in a shadow root, so we +// drive its colours through the documented --trees-theme-* custom properties. +const TREE_THEME = themeToTreeStyles({ + type: "light", + bg: "#f6f8fa", + fg: "#1f2328", +}) as CSSProperties; + +// Keep the built-in "complete" icon set (the default) and add the official +// Quarto glyph for .qmd files via an injected sprite symbol. `set` must be +// given explicitly: supplying any custom override otherwise flips the default +// set to "none", which would drop every built-in file icon. +const TREE_ICONS: FileTreeIconConfig = { + set: "complete", + colored: true, + spriteSheet: + '' + + '' + + `` + + "", + byFileExtension: { qmd: { name: "amsync-quarto", viewBox: "0 0 24 24" } }, +}; + +export function FileTreeView({ paths }: { paths: string[] }) { + // useFileTree() builds one stable model for the component lifetime; later path + // changes (connect / refresh) are pushed via resetPaths(), not by re-creating. + const { model } = useFileTree({ + paths, + search: true, + density: "compact", + initialExpansion: "open", + icons: TREE_ICONS, + }); + + const mounted = React.useRef(false); + React.useEffect(() => { + if (!mounted.current) { + mounted.current = true; + return; + } + model.resetPaths(paths, { initialExpandedPaths: undefined }); + }, [model, paths]); + + // Selection is purely user-driven (clicks/keyboard); a single selected path + // that is a known file opens it. Directories and multi-select are ignored. + const fileSet = React.useMemo(() => new Set(paths), [paths]); + const selection = useFileTreeSelection(model); + React.useEffect(() => { + if (selection.length === 1 && fileSet.has(selection[0])) { + fireShinyEvent("file", selection[0]); + } + }, [selection, fileSet]); + + return ; +} diff --git a/srcjs/src/Toast.tsx b/srcjs/src/Toast.tsx new file mode 100644 index 0000000..cfee1a2 --- /dev/null +++ b/srcjs/src/Toast.tsx @@ -0,0 +1,43 @@ +// Transient notifications. Replaces shiny::showNotification(), whose default UI +// isn't present on a bare page_react() page. The R server pushes messages with +// send_message(session, "notify", list(type = ..., text = ...)). + +import { React, useShinyMessageHandler } from "./shiny"; + +interface Notice { + id: number; + type: string; + text: string; +} + +const TIMEOUT_MS = 5000; + +export function Toast() { + const [notices, setNotices] = React.useState([]); + const counter = React.useRef(0); + + useShinyMessageHandler<{ type?: string; text?: string }>("notify", (data) => { + const id = (counter.current += 1); + const notice: Notice = { + id, + type: data.type ?? "message", + text: data.text ?? "", + }; + setNotices((current) => [...current, notice]); + window.setTimeout( + () => setNotices((current) => current.filter((n) => n.id !== id)), + TIMEOUT_MS, + ); + }); + + if (notices.length === 0) return null; + return ( +
+ {notices.map((n) => ( +
+ {n.text} +
+ ))} +
+ ); +} diff --git a/srcjs/src/index.tsx b/srcjs/src/index.tsx new file mode 100644 index 0000000..e559986 --- /dev/null +++ b/srcjs/src/index.tsx @@ -0,0 +1,12 @@ +// Entry point: mount the React app. shinyreact::page_react() serves a bare page +// with no mount container, so the app appends its own #root div (styles.css +// targets it). React/ReactDOM come from the shared window.shinyreact instance +// (see shiny.ts), not a bundled copy. + +import "./styles.css"; +import { ReactDOM } from "./shiny"; +import { App } from "./App"; + +const root = document.body.appendChild(document.createElement("div")); +root.id = "root"; +ReactDOM.createRoot(root).render(); diff --git a/srcjs/src/languages.ts b/srcjs/src/languages.ts new file mode 100644 index 0000000..c1b39b1 --- /dev/null +++ b/srcjs/src/languages.ts @@ -0,0 +1,165 @@ +// Map a file extension to a CodeMirror 6 language extension. Mirrors the coverage +// of the former R-side `ext_to_language()` (edit.R), now that the editor lives in +// the browser. Modern languages use the dedicated @codemirror/lang-* packages; +// the long tail uses @codemirror/legacy-modes via StreamLanguage. +// +// Markdown variants (incl. Quarto .qmd / R Markdown .Rmd) are wrapped so a +// leading `--- ... ---` block is parsed as YAML front matter, and fenced code +// chunks are highlighted in their own language — including knitr/Quarto's +// `{r}` / `{python}` brace syntax. + +import type { Extension } from "@codemirror/state"; +import { LanguageSupport, StreamLanguage } from "@codemirror/language"; +import type { Language } from "@codemirror/language"; +import { cpp } from "@codemirror/lang-cpp"; +import { css } from "@codemirror/lang-css"; +import { html } from "@codemirror/lang-html"; +import { java } from "@codemirror/lang-java"; +import { javascript } from "@codemirror/lang-javascript"; +import { json } from "@codemirror/lang-json"; +import { markdown } from "@codemirror/lang-markdown"; +import { php } from "@codemirror/lang-php"; +import { python } from "@codemirror/lang-python"; +import { rust } from "@codemirror/lang-rust"; +import { sass } from "@codemirror/lang-sass"; +import { sql } from "@codemirror/lang-sql"; +import { xml } from "@codemirror/lang-xml"; +import { yaml, yamlFrontmatter } from "@codemirror/lang-yaml"; +import { r } from "@codemirror/legacy-modes/mode/r"; +import { julia } from "@codemirror/legacy-modes/mode/julia"; +import { toml } from "@codemirror/legacy-modes/mode/toml"; +import { properties } from "@codemirror/legacy-modes/mode/properties"; +import { shell } from "@codemirror/legacy-modes/mode/shell"; +import { dockerFile } from "@codemirror/legacy-modes/mode/dockerfile"; +import { diff } from "@codemirror/legacy-modes/mode/diff"; +import { stex } from "@codemirror/legacy-modes/mode/stex"; + +// Lowercase, drop a leading dot. +function normalizeKey(s?: string | null): string { + return s ? s.trim().replace(/^\./, "").toLowerCase() : ""; +} + +// Extract the language from a fenced-code info string, handling plain (```r), +// knitr (```{r}) and option-bearing (```{r setup, echo=FALSE}) forms. +function normalizeInfo(info: string): string { + let s = info.trim(); + const brace = s.match(/^\{([^}]*)\}/); + if (brace) s = brace[1]; + return normalizeKey(s.split(/[\s,]+/)[0] ?? ""); +} + +const MARKDOWN_KEYS = new Set(["md", "markdown", "qmd", "rmd"]); + +// Build the language for a normalized key. Accepts both file-extension keys and +// fenced-code language names (e.g. "py" and "python"). Returns null for unknown +// keys (plain text). Markdown is the plain variant here; the front-matter +// wrapper is applied only at the top level (see languageForExt). +function buildSupport(key: string): LanguageSupport | Language | null { + switch (key) { + case "r": + case "rscript": + case "rprofile": + return StreamLanguage.define(r); + case "py": + case "python": + return python(); + case "jl": + case "julia": + return StreamLanguage.define(julia); + case "sql": + return sql(); + case "js": + case "mjs": + case "cjs": + case "jsx": + case "javascript": + case "node": + return javascript({ jsx: true }); + case "ts": + case "typescript": + return javascript({ typescript: true }); + case "tsx": + return javascript({ typescript: true, jsx: true }); + case "htm": + case "html": + return html(); + case "css": + return css(); + case "scss": + return sass(); + case "sass": + return sass({ indented: true }); + case "json": + return json(); + case "yaml": + case "yml": + return yaml(); + case "svg": + case "xml": + return xml(); + case "toml": + return StreamLanguage.define(toml); + case "cfg": + case "conf": + case "ini": + return StreamLanguage.define(properties); + case "sh": + case "zsh": + case "bash": + case "shell": + return StreamLanguage.define(shell); + case "dockerfile": + case "docker": + return StreamLanguage.define(dockerFile); + case "tex": + case "latex": + return StreamLanguage.define(stex); + case "c": + case "h": + case "cc": + case "hh": + case "cxx": + case "hpp": + case "cpp": + return cpp(); + case "rs": + case "rust": + return rust(); + case "java": + return java(); + case "php": + return php(); + case "patch": + case "diff": + return StreamLanguage.define(diff); + case "md": + case "markdown": + case "qmd": + case "rmd": + return markdown(); + default: + return null; + } +} + +function toLanguage(x: LanguageSupport | Language): Language { + return x instanceof LanguageSupport ? x.language : x; +} + +// Markdown with YAML front matter + per-chunk code highlighting. +function markdownDoc(): Extension { + return yamlFrontmatter({ + content: markdown({ + codeLanguages: (info) => { + const support = buildSupport(normalizeInfo(info)); + return support ? toLanguage(support) : null; + }, + }), + }); +} + +export function languageForExt(ext?: string | null): Extension { + const key = normalizeKey(ext); + if (MARKDOWN_KEYS.has(key)) return markdownDoc(); + return buildSupport(key) ?? []; +} diff --git a/srcjs/src/shiny.ts b/srcjs/src/shiny.ts new file mode 100644 index 0000000..67b48e8 --- /dev/null +++ b/srcjs/src/shiny.ts @@ -0,0 +1,85 @@ +// Typed facade over the global `window.shinyreact` runtime. shinyreact's bundle +// (loaded by `page_react()` before this one) owns the single React 19 instance and +// the Shiny <-> React hooks; we read everything from it rather than importing the +// `react` package at runtime (which is externalized to `window.shinyreact.React` +// by vite — see vite.config.ts). Capturing at module load is safe because both +// dependency scripts use `defer` and shinyreact is injected first. + +type SetInputPriority = "deferred" | "immediate" | "event"; +interface SetInputOptions { + debounceMs?: number; + priority?: SetInputPriority; + type?: string; +} + +type OutputStatus = "pending" | "ready" | "recalculating" | "error"; + +interface ShinyReactGlobal { + React: typeof import("react"); + ReactDOM: typeof import("react-dom/client"); + useShinyInput: ( + id: string, + defaultValue: T, + opts?: SetInputOptions, + ) => [T, (value: T) => void]; + useShinyInputValue: (id: string) => T | undefined; + useSetShinyInput: ( + id: string, + defaultValue: T, + opts?: SetInputOptions, + ) => (value: T) => void; + useShinyOutputValue: (id: string, defaultValue?: T) => T | undefined; + useShinyOutputStatus: (id: string) => OutputStatus; + useShinyMessageHandler: ( + type: string, + handler: (data: T) => void, + ) => void; + useShinyInitialized: () => boolean; + useShinyBusy: () => boolean; +} + +declare global { + interface Window { + shinyreact: ShinyReactGlobal; + // Shiny's client global; used for imperative input sends where a hook's + // mount-time default broadcast would be harmful (see Editor.tsx). + Shiny?: { + setInputValue?: ( + id: string, + value: unknown, + opts?: { priority?: SetInputPriority }, + ) => void; + }; + } +} + +const sr = window.shinyreact; + +export const React = sr.React; +export const ReactDOM = sr.ReactDOM; +export const useShinyInput = sr.useShinyInput; +export const useShinyInputValue = sr.useShinyInputValue; +export const useSetShinyInput = sr.useSetShinyInput; +export const useShinyOutputValue = sr.useShinyOutputValue; +export const useShinyOutputStatus = sr.useShinyOutputStatus; +export const useShinyMessageHandler = sr.useShinyMessageHandler; +export const useShinyInitialized = sr.useShinyInitialized; + +/** + * Imperatively fire a Shiny "event" input (for action buttons / row clicks). + * + * Deliberately NOT via `useShinyInput`/`useSetShinyInput`: those register the + * input and re-broadcast its retained registry value to Shiny on every mount. + * With "event" priority that re-fires the matching `observeEvent()` whenever the + * component re-mounts — e.g. returning to the connect screen after Disconnect + * would auto-trigger the last Authenticate/Connect click. Sending directly means + * the input only ever changes on a real click, so nothing fires on mount. + */ +export function fireShinyEvent(id: string, value: unknown = Date.now()): void { + window.Shiny?.setInputValue?.(id, value, { priority: "event" }); +} + +/** Stable click handler that fires `input$id` as an event (see fireShinyEvent). */ +export function useShinyEvent(id: string): () => void { + return React.useCallback(() => fireShinyEvent(id), [id]); +} diff --git a/srcjs/src/styles.css b/srcjs/src/styles.css new file mode 100644 index 0000000..6f2fb83 --- /dev/null +++ b/srcjs/src/styles.css @@ -0,0 +1,373 @@ +:root { + --amsync-fg: #1f2328; + --amsync-muted: #656d76; + --amsync-bg: #ffffff; + --amsync-bg-subtle: #f6f8fa; + --amsync-border: #d0d7de; + --amsync-primary: #0969da; + --amsync-primary-fg: #ffffff; + --amsync-accent: #4f46e5; + --amsync-accent-soft: rgba(79, 70, 229, 0.14); + --amsync-danger: #cf222e; + --amsync-success: #1a7f37; + --amsync-radius: 6px; + --amsync-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, + Arial, sans-serif; + --amsync-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, + "Liberation Mono", monospace; +} + +* { + box-sizing: border-box; +} + +html, +body, +#root { + height: 100%; + margin: 0; +} + +body { + font-family: var(--amsync-font); + color: var(--amsync-fg); + background: var(--amsync-bg); + font-size: 14px; +} + +/* --- Buttons --- */ +.amsync-btn { + font: inherit; + padding: 6px 12px; + border-radius: var(--amsync-radius); + border: 1px solid var(--amsync-border); + background: var(--amsync-bg); + color: var(--amsync-fg); + cursor: pointer; + line-height: 1.4; +} +.amsync-btn:hover { + background: var(--amsync-bg-subtle); +} +.amsync-btn-sm { + padding: 3px 8px; + font-size: 12px; +} +.amsync-btn-primary { + background: var(--amsync-primary); + border-color: var(--amsync-primary); + color: var(--amsync-primary-fg); +} +.amsync-btn-primary:hover { + filter: brightness(0.95); + background: var(--amsync-primary); +} +.amsync-btn-outline { + background: var(--amsync-bg); +} +.amsync-btn-danger { + color: var(--amsync-danger); + border-color: var(--amsync-border); +} +.amsync-btn-danger:hover { + background: #ffebe9; +} +.amsync-fill { + flex: 1 1 auto; +} + +/* --- Connect screen: clean, minimal sign-in --- */ +.amsync-connect { + display: flex; + align-items: center; + justify-content: center; + min-height: 100%; + padding: 32px 24px; + overflow: auto; +} +.amsync-signin { + width: 100%; + max-width: 360px; +} +.amsync-brand { + text-align: center; + font-size: 26px; + font-weight: 600; + letter-spacing: -0.03em; + color: var(--amsync-fg); +} +.amsync-brand-dot { + color: var(--amsync-accent); +} +.amsync-signin-subtitle { + margin: 6px 0 30px; + text-align: center; + font-size: 14px; + color: var(--amsync-muted); +} + +/* Fields */ +.amsync-field { + display: block; + margin-bottom: 16px; +} +.amsync-field > span { + display: block; + font-size: 13px; + font-weight: 500; + color: var(--amsync-fg); + margin-bottom: 6px; +} +.amsync-field input { + font: inherit; + font-weight: 400; + width: 100%; + padding: 9px 12px; + border: 1px solid var(--amsync-border); + border-radius: 8px; + background: var(--amsync-bg); + color: var(--amsync-fg); + transition: border-color 0.15s ease, box-shadow 0.15s ease; +} +.amsync-field input::placeholder { + color: #9aa4af; + font-weight: 400; +} +.amsync-field input:focus { + outline: none; + border-color: var(--amsync-accent); + box-shadow: 0 0 0 3px var(--amsync-accent-soft); +} + +/* Signed-in indicator (shown when a token is already held) */ +.amsync-signin-authed { + margin: -22px 0 22px; + text-align: center; + font-size: 12px; + color: var(--amsync-success); +} +.amsync-advanced-note { + margin: 0 0 14px; + font-size: 12px; + line-height: 1.5; + color: var(--amsync-muted); +} + +/* Advanced disclosure */ +.amsync-advanced { + margin-bottom: 22px; +} +.amsync-advanced > summary { + cursor: pointer; + width: fit-content; + font-size: 13px; + color: var(--amsync-muted); + list-style: none; +} +.amsync-advanced > summary::-webkit-details-marker { + display: none; +} +.amsync-advanced > summary::before { + content: "\25b8\00a0"; /* ▸ */ + font-size: 10px; +} +.amsync-advanced[open] > summary::before { + content: "\25be\00a0"; /* ▾ */ +} +.amsync-advanced-body { + margin-top: 14px; +} +.amsync-advanced-body .amsync-field:last-child { + margin-bottom: 0; +} + +/* Primary / ghost actions */ +.amsync-primary-btn { + font: inherit; + font-weight: 500; + width: 100%; + padding: 10px 16px; + border: none; + border-radius: 8px; + background: var(--amsync-fg); + color: #ffffff; + cursor: pointer; + transition: opacity 0.15s ease; +} +.amsync-primary-btn:hover { + opacity: 0.88; +} +.amsync-ghost-btn { + font: inherit; + display: block; + width: 100%; + margin-top: 8px; + padding: 8px; + border: none; + border-radius: 8px; + background: none; + color: var(--amsync-muted); + cursor: pointer; +} +.amsync-ghost-btn:hover { + background: var(--amsync-bg-subtle); + color: var(--amsync-fg); +} + +/* --- Browse screen --- */ +.amsync-browse { + display: flex; + height: 100%; +} +.amsync-sidebar { + width: 300px; + flex: 0 0 300px; + border-right: 1px solid var(--amsync-border); + display: flex; + flex-direction: column; + background: var(--amsync-bg-subtle); +} +.amsync-sidebar-title { + padding: 10px 12px; + font-weight: 600; + border-bottom: 1px solid var(--amsync-border); +} +.amsync-tree-wrap { + flex: 1 1 auto; + overflow: auto; + padding: 6px; + min-height: 0; +} +.amsync-tree { + display: block; + height: 100%; +} +.amsync-empty { + color: var(--amsync-muted); + font-size: 13px; + padding: 8px; +} +.amsync-sidebar-actions { + display: flex; + gap: 8px; + padding: 8px; + border-top: 1px solid var(--amsync-border); +} + +/* --- Main / editor --- */ +.amsync-main { + flex: 1 1 auto; + min-width: 0; + display: flex; + flex-direction: column; +} +.amsync-placeholder { + display: flex; + flex: 1; + align-items: center; + justify-content: center; + color: var(--amsync-muted); + padding: 24px; +} +.amsync-editor-card { + display: flex; + flex-direction: column; + flex: 1 1 auto; + min-height: 0; +} +.amsync-edit-only { + height: 100%; +} +.amsync-editor-header { + display: flex; + align-items: center; + justify-content: space-between; + padding: 8px 12px; + border-bottom: 1px solid var(--amsync-border); + background: var(--amsync-bg-subtle); +} +.amsync-editor-title { + display: inline-flex; + align-items: center; + gap: 7px; + min-width: 0; +} +.amsync-file-icon { + flex: 0 0 auto; + color: var(--amsync-muted); +} +.amsync-editor-path { + font-family: var(--amsync-mono); + font-size: 13px; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} +.amsync-editor-live { + font-size: 12px; + color: var(--amsync-muted); +} +.amsync-editor { + flex: 1 1 auto; + min-height: 0; + overflow: hidden; +} +.amsync-editor .cm-editor { + height: 100%; +} +.amsync-editor .cm-scroller { + font-family: var(--amsync-mono); +} + +/* --- Closed / loading --- */ +.amsync-closed, +.amsync-loading { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + height: 100%; + text-align: center; + color: var(--amsync-muted); +} +.amsync-closed h5 { + margin: 0 0 4px; + color: var(--amsync-fg); +} +.amsync-closed p { + margin: 0; +} + +/* --- Toasts --- */ +.amsync-toasts { + position: fixed; + top: 16px; + right: 16px; + display: flex; + flex-direction: column; + gap: 8px; + z-index: 1000; + max-width: 360px; +} +.amsync-toast { + padding: 10px 14px; + border-radius: var(--amsync-radius); + border: 1px solid var(--amsync-border); + background: var(--amsync-bg); + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12); + font-size: 13px; +} +.amsync-toast-error { + border-color: var(--amsync-danger); + background: #ffebe9; + color: var(--amsync-danger); +} +.amsync-toast-warning { + border-color: #d4a72c; + background: #fff8c5; +} +.amsync-toast-message { + border-color: var(--amsync-success); + background: #dafbe1; + color: var(--amsync-success); +} diff --git a/srcjs/tsconfig.json b/srcjs/tsconfig.json new file mode 100644 index 0000000..621b61b --- /dev/null +++ b/srcjs/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "module": "ESNext", + "skipLibCheck": true, + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + "strict": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noFallthroughCasesInSwitch": true, + "esModuleInterop": true + }, + "include": ["src"] +} diff --git a/srcjs/vite.config.ts b/srcjs/vite.config.ts new file mode 100644 index 0000000..5e81fd9 --- /dev/null +++ b/srcjs/vite.config.ts @@ -0,0 +1,46 @@ +import path from "node:path"; +import { fileURLToPath } from "node:url"; + +import react from "@vitejs/plugin-react"; +import { defineConfig } from "vite"; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); + +// React/ReactDOM are externalized and pulled from window.shinyreact at runtime so +// this bundle shares the single React instance that owns the shinyreact hooks +// (two React copies would break hooks with "invalid hook call"). @pierre/trees and +// CodeMirror are bundled in. +export default defineConfig({ + define: { + "process.env.NODE_ENV": JSON.stringify("production"), + }, + plugins: [react()], + build: { + outDir: path.resolve(__dirname, "../inst/www"), + emptyOutDir: false, + cssCodeSplit: false, + // Target a level with native class private methods/fields. The default + // ('modules', which includes Safari 14) makes esbuild down-level @pierre/trees' + // private methods to WeakSet brand-checks, which minification then mangles + // into a runtime "X.has is not a function" crash. The gadget only ever runs + // in a modern browser, so es2022 is safe. + target: "es2022", + lib: { + entry: path.resolve(__dirname, "src/index.tsx"), + formats: ["iife"], + name: "autosyncFrontend", + fileName: () => "amsync.js", + }, + rollupOptions: { + external: ["react", "react-dom", "react-dom/client"], + output: { + assetFileNames: "amsync.[ext]", + globals: { + react: "window.shinyreact.React", + "react-dom": "window.shinyreact.ReactDOM", + "react-dom/client": "window.shinyreact.ReactDOM", + }, + }, + }, + }, +}); diff --git a/tests/testthat/helper.R b/tests/testthat/helper.R index 35192f4..7a829dc 100644 --- a/tests/testthat/helper.R +++ b/tests/testthat/helper.R @@ -1,5 +1,37 @@ # Test helpers +# Set the OIDC_CLIENT_* env vars to known values for a test, restoring the +# previous values (or unsetting them) when the test ends. `NULL` unsets a +# variable: the app falls back to these env vars when a sign-in field is left +# blank, so tests that connect with blank fields must unset them to stay +# hermetic. Cleanup uses the vendored withr standalone `defer()` +# (R/import-standalone-defer.R). +local_oidc_env <- function(client_id = NULL, client_secret = NULL) { + nms <- c("OIDC_CLIENT_ID", "OIDC_CLIENT_SECRET") + old <- Sys.getenv(nms, unset = NA) + defer( + { + for (nm in nms) { + if (is.na(old[[nm]])) { + Sys.unsetenv(nm) + } else { + do.call(Sys.setenv, setNames(list(old[[nm]]), nm)) + } + } + }, + envir = parent.frame() + ) + for (i in seq_along(nms)) { + val <- list(client_id, client_secret)[[i]] + if (is.null(val)) { + Sys.unsetenv(nms[[i]]) + } else { + do.call(Sys.setenv, setNames(list(val), nms[[i]])) + } + } + invisible(old) +} + # Drain any leftover later callbacks from prior tests so they don't fire # inside the next test's run_now and trip up nanonext's external-pointer # bookkeeping. Bounded so a perpetually-rescheduling callback can't hang. diff --git a/tests/testthat/test-app.R b/tests/testthat/test-app.R new file mode 100644 index 0000000..6add84d --- /dev/null +++ b/tests/testthat/test-app.R @@ -0,0 +1,411 @@ +test_that("sync_app errors in a non-interactive session", { + local_mocked_bindings(is_interactive = function() FALSE) + expect_error(sync_app(), "requires an interactive session") +}) + +test_that("sync_app errors when shiny or shinyreact is missing", { + local_mocked_bindings(is_interactive = function() TRUE) + local_mocked_bindings( + requireNamespace = function(...) FALSE, + .package = "base" + ) + expect_error(sync_app(), "requires the 'shiny' and 'shinyreact' packages") +}) + +test_that("sync_app builds the app and launches it as a gadget", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + # Mock the interactive check and the gadget launcher so the happy path runs + # without opening a window; capture the built app instead. + launched <- NULL + local_mocked_bindings(is_interactive = function() TRUE) + local_mocked_bindings( + runGadget = function(app, ...) { + launched <<- app + NULL + }, + .package = "shiny" + ) + + expect_null(sync_app("wss://x/ws", proj_id = "DOC123")) + expect_s3_class(launched, "shiny.appobj") +}) + +test_that("Exit switches to the closed screen and schedules the app to stop", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + # Stub the delayed stop so the scheduled stopApp() doesn't leak into the + # shared event loop and disturb other tests; just record that it was queued. + scheduled <- FALSE + local_mocked_bindings( + later = function(func, delay = 0, ...) { + scheduled <<- TRUE + invisible() + } + ) + + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + expect_equal(rv$view, "connect") + session$setInputs(exit = 1) + expect_equal(rv$view, "closed") + expect_true(scheduled) + }) +}) + +test_that("a token passed to the app starts it signed in", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + app <- build_sync_app("", "", "jwt.tok.en", NULL, 5000L, "files", 300L) + shiny::testServer(app, { + expect_true(rv$authed) + expect_equal(st$token, "jwt.tok.en") + }) +}) + +test_that("the app exposes the prefilled server URL and project to the client", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + # Regression: the `server` argument must not be shadowed by the app's server + # function. output$init reads `server`/`proj_id` and would error ("cannot + # coerce type 'closure'") if `server` resolved to the server function. + local_oidc_env("env-cid", "env-sec") + app <- build_sync_app( + "wss://x/ws", + "DOC123", + NULL, + NULL, + 5000L, + "files", + 300L + ) + shiny::testServer(app, { + init <- output$init + expect_equal(init$server, "wss://x/ws") + expect_equal(init$proj_id, "DOC123") + # Env-configured credentials are exposed as flags only, never values. + expect_true(init$client_id_env) + expect_true(init$client_secret_env) + expect_null(init[["client_id"]]) + expect_null(init[["client_secret"]]) + }) +}) + +test_that("sync_app rejects a malformed token", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + # Token validation runs after the interactive + package checks, so mock the + # session as interactive to reach it. + local_mocked_bindings(is_interactive = function() TRUE) + expect_error(sync_app(token = 123), "single non-empty string") + expect_error(sync_app(token = c("a", "b")), "single non-empty string") + expect_error(sync_app(token = ""), "single non-empty string") +}) + +test_that("the app connects, browses, and edits over a live server", { + skip_on_cran() + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_oidc_env() + drain_later() + + data_dir <- tempfile() + dir.create(data_dir) + on.exit(unlink(data_dir, recursive = TRUE)) + + server <- sync_server(data_dir = data_dir) + server$start() + on.exit(server$close(), add = TRUE) + + # Seed a project document whose `files` map holds one text file. + fid <- create_document(server) + fdoc <- get_document(server, fid) + fdoc[["text"]] <- automerge::am_text("hello world") + pid <- create_document(server) + pdoc <- get_document(server, pid) + pdoc[["files"]] <- automerge::am_map() + files <- pdoc[["files"]] + files[["/notes.md"]] <- automerge::am_text(fid) + + app <- build_sync_app( + server = server$url, + proj_id = pid, + token = NULL, + tls = NULL, + timeout = 5000L, + files_key = "files", + debounce = 300L + ) + + # testServer evaluates the expr with the mock session's reactives (input, + # output, session, and the server function's locals st/rv) layered over this + # test's environment, so the `server`/`pid` test locals are reachable here. + shiny::testServer(app, { + expect_equal(rv$view, "connect") + expect_false(rv$authed) + + # Connecting builds the project (its run_now() handshake runs inside the + # observer) and switches to the browse screen with the file tree loaded. + session$setInputs(url = server$url, proj_id = pid) + session$setInputs(connect = 1) + expect_equal(rv$view, "browse") + expect_equal(rv$paths, "/notes.md") + expect_s3_class(st$proj, "autosync_project") + + # Opening the file loads its document and pushes its content to the editor. + session$setInputs(file = "/notes.md") + expect_equal(rv$selected, "/notes.md") + expect_equal(st$base, "hello world") + expect_s3_class(st$doc, "autosync_doc") + expect_equal(rv$editor$value, "hello world") + expect_equal(rv$editor$ext, ".md") + expect_gt(rv$editor$rev, 0L) + + # Typing in the editor writes the minimal diff into the live document. + session$setInputs(content = "hello brave world") + expect_equal( + automerge::am_text_content(st$doc$doc[["text"]]), + "hello brave world" + ) + + # Disconnecting tears down the connection and returns to the connect form. + session$setInputs(disconnect = 1) + expect_equal(rv$view, "connect") + expect_null(st$proj) + }) +}) + +test_that("Connect auto-authenticates when an OIDC client ID is provided", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + used_token <- NULL + local_mocked_bindings(sync_token = function(...) "fresh.jwt") + local_mocked_bindings( + sync_project = function(url, proj_id, token = NULL, ...) { + used_token <<- token + list(paths = function() character(0)) + } + ) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + expect_false(rv$authed) + # A non-empty issuer is used as-is (exercises the issuer branch). + session$setInputs( + url = "wss://x/ws", + proj_id = "DOC123", + client_id = "cid", + client_secret = "sec", + issuer = "https://issuer" + ) + session$setInputs(connect = 1) + expect_equal(st$token, "fresh.jwt") + expect_true(rv$authed) + expect_equal(used_token, "fresh.jwt") # token forwarded to sync_project() + expect_equal(rv$view, "browse") + }) +}) + +test_that("Connect falls back to the OIDC env vars when the fields are blank", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_oidc_env("env-cid", "env-sec") + seen <- NULL + local_mocked_bindings(sync_token = function(client_id, client_secret, ...) { + seen <<- list(client_id = client_id, client_secret = client_secret) + "fresh.jwt" + }) + local_mocked_bindings( + sync_project = function(url, proj_id, token = NULL, ...) { + list(paths = function() character(0)) + } + ) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + session$setInputs(url = "wss://x/ws", proj_id = "DOC123") # fields blank + session$setInputs(connect = 1) + expect_equal(seen$client_id, "env-cid") + expect_equal(seen$client_secret, "env-sec") + expect_true(rv$authed) + expect_equal(rv$view, "browse") + }) +}) + +test_that("Connect connects tokenless when no OIDC client ID is given", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_oidc_env() + token_called <- FALSE + used_token <- "unset" + local_mocked_bindings(sync_token = function(...) { + token_called <<- TRUE + "x" + }) + local_mocked_bindings( + sync_project = function(url, proj_id, token = NULL, ...) { + used_token <<- token + list(paths = function() character(0)) + } + ) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + session$setInputs(url = "wss://x/ws", proj_id = "DOC123") # no client_id + session$setInputs(connect = 1) + expect_false(token_called) # no authentication attempted + expect_false(rv$authed) + expect_null(used_token) # connected without a token + expect_equal(rv$view, "browse") + }) +}) + +test_that("a failed auto-authentication stays on the connect screen", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_mocked_bindings(sync_token = function(...) stop("denied")) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + # Blank issuer falls back to oidc_issuer() (the other branch). + session$setInputs( + url = "wss://x/ws", + proj_id = "DOC123", + client_id = "cid", + issuer = "" + ) + session$setInputs(connect = 1) + expect_false(rv$authed) + expect_null(st$proj) + expect_equal(rv$view, "connect") + }) +}) + +test_that("Connect warns and stays put when the URL or project ID is blank", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + session$setInputs(url = "", proj_id = "") + session$setInputs(connect = 1) + expect_equal(rv$view, "connect") + expect_null(st$proj) + }) +}) + +test_that("a persistently failing Connect stays on the connect screen", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_oidc_env() + + # Stub the inter-retry pause so the retries don't sleep through the test. + tries <- 0L + local_mocked_bindings(retry_pause = function() invisible()) + local_mocked_bindings(sync_project = function(...) { + tries <<- tries + 1L + stop("cannot connect") + }) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + session$setInputs(url = "wss://x/ws", proj_id = "DOC123") + session$setInputs(connect = 1) + expect_equal(tries, 6L) # initial attempt + 5 retries + expect_equal(rv$view, "connect") + expect_null(st$proj) + }) +}) + +test_that("Connect retries a transient connection failure then succeeds", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + local_oidc_env() + + local_mocked_bindings(retry_pause = function() invisible()) + attempt <- 0L + local_mocked_bindings( + sync_project = function(url, proj_id, token = NULL, ...) { + attempt <<- attempt + 1L + if (attempt < 3L) { + stop("transient") + } + list(paths = function() character(0)) + } + ) + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + session$setInputs(url = "wss://x/ws", proj_id = "DOC123") + session$setInputs(connect = 1) + expect_equal(attempt, 3L) # failed twice, connected on the third try + expect_equal(rv$view, "browse") + }) +}) + +test_that("opening a file ignores a blank path and reports open errors", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + # The observer is ignoreInit, so the first input change is swallowed; prime + # it before the cases we want to observe. + session$setInputs(file = "/prime.md") + + # A blank path is ignored. + session$setInputs(file = "") + expect_null(rv$selected) + + # A project whose open() fails: the error is caught and no file opens. + st$proj <- list(open = function(path) stop("boom")) + session$setInputs(file = "/notes.md") + expect_null(rv$selected) + expect_null(st$doc) + }) +}) + +test_that("Refresh re-resolves the tree and drops a vanished selection", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + app <- build_sync_app("", "", NULL, NULL, 5000L, "files", 300L) + shiny::testServer(app, { + # No project held: refresh is a quiet no-op. + session$setInputs(refresh = 1) + expect_equal(rv$paths, character(0)) + + # With a project, the tree re-resolves and a now-missing selection clears. + refreshed <- FALSE + st$proj <- list( + refresh = function() refreshed <<- TRUE, + paths = function() c("/a.md", "/b.md") + ) + rv$selected <- "/gone.md" + session$setInputs(refresh = 2) + expect_true(refreshed) + expect_equal(rv$paths, c("/a.md", "/b.md")) + expect_null(rv$selected) + }) +}) + +test_that("cleanup_project closes the connection and clears state", { + closed <- FALSE + st <- new.env(parent = emptyenv()) + st$proj <- list(close = function() closed <<- TRUE) + st$doc <- "handle" + + cleanup_project(st) + + expect_true(closed) + expect_null(st$proj) + expect_null(st$doc) + + # Idempotent: a second call (no project held) is a quiet no-op. + expect_no_error(cleanup_project(st)) +}) diff --git a/tests/testthat/test-edit.R b/tests/testthat/test-edit.R new file mode 100644 index 0000000..1d7575b --- /dev/null +++ b/tests/testthat/test-edit.R @@ -0,0 +1,306 @@ +# Helper: seed a server document with a text object at `key` +seed_text_doc <- function(server, content, key = "text") { + doc_id <- create_document(server) + doc <- get_document(server, doc_id) + doc[[key]] <- automerge::am_text(content) + doc_id +} + +# Helper: a standalone (server-less) Automerge document with a text object, +# for exercising the sync helpers without a connection. +local_text_doc <- function(content, key = "text") { + doc <- automerge::am_create() + doc[[key]] <- automerge::am_text(content) + doc +} + +# Helper: a fake autosync_doc handle backed by a standalone text document, for +# exercising the editor without a live connection. `$push` just counts calls. +fake_doc_handle <- function(content, key = "text", active = TRUE) { + handle <- structure(new.env(parent = emptyenv()), class = "autosync_doc") + handle$active <- active + handle$doc <- local_text_doc(content, key) + handle$push_count <- 0L + handle$push <- function() handle$push_count <- handle$push_count + 1L + handle +} + +test_that("sync_editor_to_doc applies edits and pushes to the server", { + skip_on_cran() + drain_later() + data_dir <- tempfile() + dir.create(data_dir) + on.exit(unlink(data_dir, recursive = TRUE)) + + server <- sync_server(data_dir = data_dir) + server$start() + on.exit(server$close(), add = TRUE) + + doc_id <- seed_text_doc(server, "hello world") + conn <- sync_client(server$url) + on.exit(conn$close(), add = TRUE) + doc <- conn$open_doc(doc_id) + + shown <- sync_editor_to_doc( + doc$doc[["text"]], + "hello brave world", + "hello world", + doc$push + ) + + expect_equal(shown, "hello brave world") + expect_equal( + automerge::am_text_content(doc$doc[["text"]]), + "hello brave world" + ) + + # Let the server apply the pushed sync. + for (i in seq_len(20)) later::run_now(0.1) + server_doc <- get_document(server, doc_id) + expect_equal( + automerge::am_text_content(server_doc[["text"]]), + "hello brave world" + ) +}) + +test_that("sync_editor_to_doc writes the minimal diff and is a no-op unchanged", { + doc <- local_text_doc("unchanged") + pushes <- 0L + push <- function() pushes <<- pushes + 1L + + # Unchanged content: no write, no push. + shown <- sync_editor_to_doc(doc[["text"]], "unchanged", "unchanged", push) + expect_equal(shown, "unchanged") + expect_equal(pushes, 0L) + expect_equal(automerge::am_text_content(doc[["text"]]), "unchanged") + + # A real edit: written and pushed once. + shown <- sync_editor_to_doc(doc[["text"]], "changed", "unchanged", push) + expect_equal(shown, "changed") + expect_equal(pushes, 1L) + expect_equal(automerge::am_text_content(doc[["text"]]), "changed") +}) + +test_that("sync_editor_to_doc preserves the original trailing-newline state", { + doc <- local_text_doc("line one") + push <- function() invisible() + + # Original has no trailing newline; editor appends one -> stripped. + shown <- sync_editor_to_doc( + doc[["text"]], + "line one\nline two\n", + "line one", + push + ) + expect_equal(shown, "line one\nline two") + expect_equal(automerge::am_text_content(doc[["text"]]), "line one\nline two") +}) + +test_that("poll_doc_to_editor reports remote changes to reflect in the editor", { + doc <- local_text_doc("hello world") + + # Document matches what the editor shows: nothing to reflect back. + expect_null(poll_doc_to_editor(doc[["text"]], "hello world")) + + # A change arrives on the live document (e.g. from a remote peer). + automerge::am_text_splice(doc[["text"]], 0L, 0L, ">> ") + expect_equal( + poll_doc_to_editor(doc[["text"]], "hello world"), + ">> hello world" + ) +}) + +test_that("the editor and document converge without echoing", { + doc <- local_text_doc("hello world") + pushes <- 0L + push <- function() pushes <<- pushes + 1L + + # User types: the outgoing sync writes the diff and pushes once. + shown <- sync_editor_to_doc( + doc[["text"]], + "hello there world", + "hello world", + push + ) + expect_equal(pushes, 1L) + + # The poll sees the document matches the editor -> nothing to reflect back. + expect_null(poll_doc_to_editor(doc[["text"]], shown)) + + # A remote edit arrives; the poll reports it and the editor adopts it. + automerge::am_text_splice(doc[["text"]], 0L, 0L, ">> ") + current <- poll_doc_to_editor(doc[["text"]], shown) + expect_equal(current, ">> hello there world") + shown <- current + + # Re-sending the adopted content is a no-op: no echo push, no spurious diff. + shown <- sync_editor_to_doc(doc[["text"]], shown, "hello world", push) + expect_equal(pushes, 1L) + expect_equal(automerge::am_text_content(doc[["text"]]), ">> hello there world") +}) + +test_that("doc$edit errors when the target is not a text object", { + skip_on_cran() + drain_later() + data_dir <- tempfile() + dir.create(data_dir) + on.exit(unlink(data_dir, recursive = TRUE)) + + server <- sync_server(data_dir = data_dir) + server$start() + on.exit(server$close(), add = TRUE) + + doc_id <- create_document(server) + doc <- get_document(server, doc_id) + doc[["num"]] <- 42L + + conn <- sync_client(server$url) + on.exit(conn$close(), add = TRUE) + handle <- conn$open_doc(doc_id) + + # The handle exposes the editor as a method. + expect_true(is.function(handle$edit)) + expect_error( + handle$edit(at = "num"), + "not a text object" + ) +}) + +test_that("edit_doc validates its arguments", { + fake <- structure(new.env(parent = emptyenv()), class = "autosync_doc") + fake$active <- FALSE + expect_error(edit_doc(fake), "not active") + + # An active handle reaches the `at` / `debounce` checks (which error before + # the editor would launch). + fake$active <- TRUE + fake$doc <- local_text_doc("hi") + expect_error(edit_doc(fake, at = character()), "non-empty character path") + expect_error(edit_doc(fake, debounce = -1), "non-negative") + expect_error(edit_doc(fake, debounce = c(1, 2)), "single non-negative") +}) + +test_that("match_trailing_newline mirrors the base string", { + expect_equal(match_trailing_newline("a\n", "no-nl"), "a") + expect_equal(match_trailing_newline("a\n\n", "no-nl"), "a") + expect_equal(match_trailing_newline("a\n", "has-nl\n"), "a\n") + expect_equal(match_trailing_newline("a", "no-nl"), "a") +}) + +test_that("navigate_to_text errors when the path has no object", { + expect_error( + navigate_to_text(local_text_doc("x"), "missing"), + "No object found at path: missing" + ) + # A nested miss (through a real map) reports the full path. + doc <- automerge::am_create() + doc[["folder"]] <- automerge::am_map() + expect_error( + navigate_to_text(doc, c("folder", "missing")), + "No object found at path: folder/missing" + ) +}) + +test_that("install_editor_sync is a no-op while no document is open", { + skip_if_not_installed("shiny") + + pushed <- NULL + st <- new.env(parent = emptyenv()) + st$doc <- NULL + st$at <- "text" + st$base <- "" + st$shown <- "" + # A large poll interval keeps the scheduled invalidateLater from re-firing, + # so a single flushReact() runs the incoming observer exactly once. + app <- shiny::shinyApp( + shiny::fluidPage(), + function(input, output, session) { + install_editor_sync(input, st, function(v) pushed <<- v, poll_ms = 1e9) + } + ) + + shiny::testServer(app, { + session$flushReact() # incoming poll: no document -> early return + session$setInputs(content = "typed") # outgoing edit: no document -> early return + expect_equal(st$shown, "") # nothing written + expect_null(pushed) # nothing pushed to the editor + }) +}) + +test_that("install_editor_sync reflects a remote change back into the editor", { + skip_if_not_installed("shiny") + + handle <- fake_doc_handle("hello world") + pushed <- NULL + st <- new.env(parent = emptyenv()) + st$doc <- handle + st$at <- "text" + st$base <- "hello world" + st$shown <- "hello world" + # A remote peer edits the live document before the editor polls. + automerge::am_text_splice(handle$doc[["text"]], 0L, 0L, ">> ") + + app <- shiny::shinyApp( + shiny::fluidPage(), + function(input, output, session) { + install_editor_sync(input, st, function(v) pushed <<- v, poll_ms = 1e9) + } + ) + + shiny::testServer(app, { + session$flushReact() # incoming poll: current differs from shown -> adopt it + expect_equal(st$shown, ">> hello world") + expect_equal(pushed, ">> hello world") # pushed to the client editor + }) +}) + +test_that("the editor errors when shiny or shinyreact is missing", { + handle <- fake_doc_handle("hello world") + # The target validates first, then the editor checks for its UI dependencies. + local_mocked_bindings(requireNamespace = function(...) FALSE, .package = "base") + expect_error( + edit_doc(handle, at = "text"), + "requires the 'shiny' and 'shinyreact' packages" + ) +}) + +test_that("edit_doc launches the live editor and reports the final content", { + skip_if_not_installed("shiny") + skip_if_not_installed("shinyreact") + + handle <- fake_doc_handle("hello world") + + # Capture the gadget the editor would launch rather than running it, and + # report a known final content so the closing message is deterministic. + captured <- NULL + local_mocked_bindings( + runGadget = function(app, ...) { + captured <<- app + "done!" + }, + .package = "shiny" + ) + + expect_message( + expect_identical(edit_doc(handle, at = "text"), handle), + "Closed editor for text \\(5 chars\\)\\." + ) + expect_s3_class(captured, "shiny.appobj") + + # Drive the captured gadget's server to exercise its session logic. + shiny::testServer(captured, { + session$flushReact() # incoming poll observer runs once (no remote change) + + # Typing streams the minimal diff into the live document and pushes. + session$setInputs(content = "hello brave world") + expect_equal( + automerge::am_text_content(handle$doc[["text"]]), + "hello brave world" + ) + expect_gt(handle$push_count, 0L) + + # Close stops the gadget once; a second close is an idempotent no-op. + session$setInputs(close = 1) + session$setInputs(close = 2) + }) +})