From ac24ccd787f239236df1784f1392322629a664f1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 21 Oct 2023 15:05:24 +0000 Subject: [PATCH] Deploy to GitHub pages --- README.md | 154 ++++++++++++++++++++++++++++++++ README_zh_CN.md | 154 ++++++++++++++++++++++++++++++++ i18n/en_US.json | 224 +++++++++++++++++++++++++++++++++++++++++++++++ i18n/zh_CHT.json | 224 +++++++++++++++++++++++++++++++++++++++++++++++ i18n/zh_CN.json | 224 +++++++++++++++++++++++++++++++++++++++++++++++ icon.png | Bin 0 -> 19595 bytes index.css | 1 + index.js | 66 ++++++++++++++ plugin.json | 37 ++++++++ preview.png | Bin 0 -> 222510 bytes 10 files changed, 1084 insertions(+) create mode 100644 README.md create mode 100644 README_zh_CN.md create mode 100644 i18n/en_US.json create mode 100644 i18n/zh_CHT.json create mode 100644 i18n/zh_CN.json create mode 100644 icon.png create mode 100644 index.css create mode 100644 index.js create mode 100644 plugin.json create mode 100644 preview.png diff --git a/README.md b/README.md new file mode 100644 index 0000000..5024630 --- /dev/null +++ b/README.md @@ -0,0 +1,154 @@ +
+icon + +--- +[![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/Zuoqiu-Yingyi/siyuan-plugin-webview?include_prereleases&style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases/latest) +[![GitHub Release Date](https://img.shields.io/github/release-date/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases/latest) +[![GitHub License](https://img.shields.io/github/license/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/blob/main/LICENSE) +[![GitHub last commit](https://img.shields.io/github/last-commit/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/commits/main) +![GitHub repo size](https://img.shields.io/github/repo-size/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square) +![hits](https://hits.b3log.org/Zuoqiu-Yingyi/siyuan-plugin-webview.svg) +[![GitHub all releases](https://img.shields.io/github/downloads/Zuoqiu-Yingyi/siyuan-plugin-webview/total?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases) + +--- +[简体中文](./README_zh_CN.md) \| English + +--- +
+ +# SiYuan Webpage View + +A plugin for [SiYuan Note](https://github.com/siyuan-note/siyuan) that allows you to browse web pages in a tab or new window like a browser. + +## PREVIEW + +![preview image](https://cdn.jsdelivr.net/gh/Zuoqiu-Yingyi/siyuan-plugin-webview/public/preview.png) + +## INTRODUCTION + +### Function Introduction + +- Open hyperlinks in SiYuan Note new tabs (desktop only) +- Open hyperlinks in a new window +- Open the SiYuan Note editor in a new window +- Block reference context menu +- Hyperlink context menu + +### Setting Introduction + +After installing this plugin, click SiYuan Settings > Marketplace > Downloaded > Plugins > Web View (this plugin) > Settings button to open the plugin's settings panel. + +- General Settings + - `User-Agent field (User-Agent, UA)` + - This is an input field. + - Default content: `` + - For details on this field, please refer to [User-Agent - HTTP | MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent). + - Users can browse web pages using a custom UA to replace the default UA. + - This option can only be used on desktop devices. + - When opening hyperlinks in a tab + - When opening hyperlinks in a new window + - When the input field is empty, the default UA `SiYuan/x.y.z https://b3log.org/siyuan Electron` will be used. + - `x.y.z` is the current version number of SiYuan. + - `Web Page Background` + - This is an input field + - Default content: `transparent` + - User can define the background color or background image of the web page. + - For details on this field, please refer to [background - CSS: Cascading Style Sheets | MDN](https://developer.mozilla.org/en-US/docs/Web/CSS/background). + - `Reset Settings Options` + - This is a button. + - Resets all settings options to their default settings. + - After clicking this button, a confirmation dialog will pop up. + - Clicking the confirmation dialog button will reset all options for this plugin to their default settings, and the current interface will be automatically refreshed. +- Open in a Tab + - `General Settings` + - `Enable` + - This is a switch. + - Default status: *on* + - Once turned on, it enables the feature to **open hyperlinks in a tab**. + - Due to the security restrictions of the browser, this feature can only be used on desktop devices. + - `Editor Hyperlinks` + - This is a switch. + - Default status: *on* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Once turned on, clicking on hyperlinks in the editor will open them in a new tab. + - `Other Hyperlinks` + - This is a switch. + - Default status: *on* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Once turned on, clicking on hyperlinks outside of the editor will open them in a new tab. + - For example, clicking on hyperlinks in the export preview page. + - `Protocol` + - This is a group of switches. + - Default status: *all on* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Only active network protocols can be opened in a tab. + - Other protocols/inactive protocols can be opened with the default program. + - `Shortcut Keys` + - This is a group of switches. + - Default status: *left mouse button single click* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Configures the keyboard shortcut needed to open hyperlinks in a tab. +- Open in a Window + - `General Settings` + - `Enable` + - This is a switch. + - Default status: *on* + - Once turned on, it enables the feature to **open hyperlinks in a new window**. + - `Editor Hyperlinks` + - This is a switch. + - Default status: *on* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Once turned on, clicking on hyperlinks in the editor with the middle mouse button will open them in a new window. + - `Other Hyperlinks` + - This is a switch. + - Default status: *off* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Once turned on, clicking on hyperlinks outside of the editor with the middle mouse button will open them in a new window. + - For example, clicking on hyperlinks in the export preview page. + - The hyperlink will also be opened with the default browser. + - `Protocol` + - This is a group of switches. + - Default status: *all on* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Only active network protocols can be opened in a new window. + - Inactive protocols will not respond. + - Clicking on the `siyuan://` protocol will open the SiYuan Note editor in a new window and jump to the specified block. + - `Shortcut Keys` + - This is a group of switches. + - Default status: *middle mouse button click* + - Only available when the `Enable` switch in the `General Settings` tab is turned on. + - Configures the keyboard shortcuts needed to open hyperlinks in a new window. + - `SiYuan Editor` + - `Enable` + - This is a switch. + - Default status: *on* + - Once turned on, it enables the feature to **open the SiYuan editor in a new window**. + - Clicking on elements in the SiYuan interface with the configured keyboard shortcut will open the SiYuan editor in a new window and jump to the corresponding position. + - Clickable elements include: + - `Block`: any block in the editor + - `Block Icon`: the icon displayed when hovering over a block with the mouse + - `Block Reference`: inline element block reference + - `Breadcrumb`: each item in the breadcrumb + - `Document Title`: the title area of the document + - `Outline`: each item in the outline panel + - `Document Tree`: each item in the document tree + - `Backlink Panel`: each item in the backlink panel + - `Floating Preview Window`: the title bar of the floating preview window. + - `Desktop Editor` + - This is a button. + - Clicking it will open a desktop SiYuan editor in a new window. + - `Mobile Editor` + - This is a button. + - Clicking it will open a mobile SiYuan editor in a new window. + - `Focus` + - This is a switch. + - Default status: *off* + - Once turned on, when the SiYuan editor is opened in a new window, the corresponding block will be focused. + - `Editor Type` + - This is a drop-down selector. + - Default status: *Mobile Editor* + - You can choose which type of SiYuan editor to open in a new window. + +## CHANGELOG + +[CHANGELOG.md](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/blob/main/CHANGELOG.md) diff --git a/README_zh_CN.md b/README_zh_CN.md new file mode 100644 index 0000000..ddf7f65 --- /dev/null +++ b/README_zh_CN.md @@ -0,0 +1,154 @@ +
+图标 + +--- +[![GitHub 最新发行版本 (最新一次发行/预发行)](https://img.shields.io/github/v/release/Zuoqiu-Yingyi/siyuan-plugin-webview?include_prereleases&style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases/latest) +[![GitHub 最新发行时间](https://img.shields.io/github/release-date/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases/latest) +[![GitHub 许可证](https://img.shields.io/github/license/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/blob/main/LICENSE) +[![GitHub 最后一次提交时间](https://img.shields.io/github/last-commit/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/commits/main) +![GitHub 仓库大小](https://img.shields.io/github/repo-size/Zuoqiu-Yingyi/siyuan-plugin-webview?style=flat-square) +![查看次数](https://hits.b3log.org/Zuoqiu-Yingyi/siyuan-plugin-webview.svg) +[![GitHub 发行版本下载次数](https://img.shields.io/github/downloads/Zuoqiu-Yingyi/siyuan-plugin-webview/total?style=flat-square)](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/releases) + +--- +简体中文 \| [English](./README.md) + +--- +
+ +# 思源网页视图 + +一个可以让你像浏览器一样在标签页或者新窗口中浏览网页的[思源笔记](https://github.com/siyuan-note/siyuan)插件。 + +## 预览 + +![预览图片](https://cdn.jsdelivr.net/gh/Zuoqiu-Yingyi/siyuan-plugin-webview/public/preview.png) + +## 介绍 + +### 功能介绍 + +- 在思源笔记新标签页中打开超链接 (仅限桌面端) +- 在新窗口中打开超链接 +- 在新窗口中打开思源笔记编辑器 +- 块引用右键菜单 +- 超链接右键菜单 + +### 设置项介绍 + +安装本插件后可以点击 思源设置 \> 集市 \> 已下载 \> 插件 \> 网页视图(本插件)设置 按钮打开本插件的设置面板 + +- 常规设置 + - `用户代理字段 (User-Agent, UA)` + - 这是一个输入框 + - 默认内容: *\<空\>* + - 该字段详情请参考 [User-Agent - HTTP | MDN](https://developer.mozilla.org/zh-CN/docs/Web/HTTP/Headers/User-Agent) + - 用户可以在浏览网页时使用自定义的 UA 替代默认的 UA + - 该选项仅在桌面端可以使用 + - 在标签页打开超链接 + - 在新窗口打开超链接 + - 输入框为空时,将使用默认的 UA `SiYuan/x.y.z https://b3log.org/siyuan Electron` + - `x.y.z` 为思源当前版本号 + - `网页背景` + - 这是一个输入框 + - 默认内容: `transparent` + - 用户可以在这里定义网页的背景颜色或背景图片 + - 该字段详情请参考 [background - CSS:层叠样式表 | MDN](https://developer.mozilla.org/zh-CN/docs/Web/CSS/background) + - `重置设置选项` + - 这是一个按钮 + - 重置所有设置选项为默认选项 + - 点击该按钮后会弹出确认对话框 + - 点击对话框确认按钮后会重置本插件所有选项为默认选项, 之后会自动刷新当前界面 +- 打开页签 + - `常规设置` + - `启用` + - 这是一个开关 + - 默认状态: *打开* + - 开关打开后启用 **在标签页中打开超链接** 功能 + - 由于浏览器的安全限制,该功能仅在桌面端可以使用 + - `编辑器超链接` + - 这是一个开关 + - 默认状态: *打开* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 开关打开后可以通过点击编辑器中的超链接在标签页中打开超链接 + - `其他超链接` + - 这是一个开关 + - 默认状态: *打开* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 开关打开后可以通过点击不在编辑器中的超链接在标签页中打开超链接 + - 例如点击导出预览页面的超链接 + - `协议` + - 这是一组开关 + - 默认状态: *全部打开* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 仅激活的网络协议可以在标签页中打开 + - 其他协议/未激活的协议可以使用默认程序打开 + - `快捷键` + - 这是一组开关 + - 默认状态: *鼠标左键单点击* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 配置在标签页打开超链接所需使用的按键组合 +- 打开窗口 + - `常规设置` + - `启用` + - 这是一个开关 + - 默认状态: *打开* + - 开关打开后启用 **在新窗口中打开超链接** 功能 + - `编辑器超链接` + - 这是一个开关 + - 默认状态: *打开* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 开关打开后可以通过鼠标中键点击编辑器中的超链接在新窗口中打开超链接 + - `其他超链接` + - 这是一个开关 + - 默认状态: *关闭* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 开关打开后可以通过鼠标中键点击编辑器中的超链接在新窗口中打开超链接 + - 例如点击导出预览页面的超链接 + - 会同时通过默认浏览器打开超链接 + - `协议` + - 这是一组开关 + - 默认状态: *全部打开* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 仅激活的网络协议可以在新窗口中打开 + - 其他协议/未激活的协议不响应 + - 点击 `siyuan://` 协议会在新窗口打开思源编辑器并跳转到指定的块 + - `快捷键` + - 这是一组开关 + - 默认状态: *鼠标中键点击* + - 仅在 `常规设置` 页签中的 `启用` 开关打开后生效 + - 配置在新窗口打开超链接所需使用的按键组合 + - `思源编辑器` + - `启用` + - 这是一个开关 + - 默认状态: *打开* + - 开关打开后启用 **新窗口打开思源编辑器** 功能 + - 使用按键组合点击思源界面中的元素可以在新窗口中打开思源编辑器并跳转到对应的位置 + - 可点击的元素 + - `块`: 编辑器中任意的块 + - `块标`: 鼠标悬浮在块上时显示的块标 + - `块引用`: 行内元素块引用 + - `面包屑`: 面包屑中的每一项 + - `文档标题`: 文档的标题区域 + - `大纲`: 大纲面板中的每一项 + - `文档树`: 文档树中的每一项 + - `反链面板`: 反链面板中的每一项 + - `悬浮预览窗口`: 悬浮预览窗口的标题栏 + - `桌面端编辑器` + - 这是一个按钮 + - 点击后可以在新窗口打开一个桌面端思源编辑器 + - `移动端编辑器` + - 这是轧钢按钮 + - 点击后可以在新窗口打开一个移动端思源编辑器 + - `聚焦` + - 这是一个开关 + - 默认状态: *关闭* + - 开关打开后在新窗口打开思源编辑器时会聚焦对应的块 + - `编辑器类型` + - 这是一个下拉选择器 + - 默认状态: *移动端编辑器* + - 可以选择在新窗口打开的思源编辑器类型 + +## 更改日志 + +[CHANGELOG.md](https://github.com/Zuoqiu-Yingyi/siyuan-plugin-webview/blob/main/CHANGELOG.md) diff --git a/i18n/en_US.json b/i18n/en_US.json new file mode 100644 index 0000000..16eab57 --- /dev/null +++ b/i18n/en_US.json @@ -0,0 +1,224 @@ +{ + "displayName": "Web Page View", + "menu": { + "copyAlt": { + "label": "Copy Description" + }, + "copyAudio": { + "label": "Copy Audio" + }, + "copyFile": { + "label": "Copy File" + }, + "copyFileName": { + "label": "Copy File Name" + }, + "copyFrame": { + "label": "Copy Frame" + }, + "copyFrameAddress": { + "label": "Copy Frame URL" + }, + "copyImage": { + "label": "Copy Image" + }, + "copyLink": { + "label": "Copy Link" + }, + "copyLinkAddress": { + "label": "Copy Link URL" + }, + "copyPage": { + "label": "Copy Page Link" + }, + "copyPageAddress": { + "label": "Copy Page URL" + }, + "copyResourceAddress": { + "label": "Copy Resource URL" + }, + "copySelectionText": { + "label": "Copy Selected Text" + }, + "copyText": { + "label": "Copy Anchor Text" + }, + "copyTitle": { + "label": "Copy Title" + }, + "copyVideo": { + "label": "Copy Video" + }, + "openByNewWindow": { + "label": "Open with New Window" + }, + "openDesktopWindow": { + "label": "Open SiYuan Desktop Window" + }, + "openEditor": { + "label": "Open in a New Window" + }, + "openFocusedEditor": { + "label": "Open in a New Window and Focus" + }, + "openLink": { + "label": "Open Link" + }, + "openMobildWindow": { + "label": "Open SiYuan Mobile Window" + }, + "openNewTab": { + "label": "Open New Tab", + "title": "New Tab" + }, + "openResource": { + "label": "Open Resource" + }, + "openTab": { + "label": "Open in New Tab" + }, + "openTabBackground": { + "label": "Open in Background Tab" + }, + "openTabBottom": { + "label": "Open Below the Tab" + }, + "openTabCurrent": { + "label": "Open in Current Tab" + }, + "openTabRight": { + "label": "Open Right the Tab" + } + }, + "message": { + "nonStandardURL": "is not standardized, please enter the URL address of the specification" + }, + "settings": { + "background": { + "description": "The background color or background image of the web page", + "title": "Web Page Background" + }, + "general": "General", + "generalSettings": { + "reset": { + "description": "Reset all settings options to default (The page will be refreshed after resetting)", + "text": "Reset", + "title": "Reset settings options" + }, + "title": "General", + "useragent": { + "description": "Use custom User-Agent, leave this item blank to use the default User-Agent (Only desktop client)", + "title": "User-Agent (UA)" + } + }, + "mouse": { + "back": "Back button", + "button": "Mouse button", + "forward": "Forward button", + "left": "Left button", + "middle": "Middle button", + "right": "Right button" + }, + "open": { + "editorHyperlink": { + "description": "Access hyperlinks in the editor", + "title": "Editor Hyperlink" + }, + "enable": { + "tab": { + "description": "Open the hyperlink in a new tab (Only desktop client)", + "title": "Enable" + }, + "window": { + "description": "Open the hyperlink in a new window", + "title": "Enable" + } + }, + "otherHyperlink": { + "description": "Access hyperlinks elsewhere", + "title": "Other Hyperlink" + }, + "shortcut": { + "title": "Key combination for opening hyperlinks" + } + }, + "openTab": "Open Tab", + "openWindow": "Open Window", + "protocol": "Protocol", + "protocols": { + "title": "List of active URL schemes" + }, + "shortcut": "Shortcut", + "siyuan": { + "editorType": { + "description": "The type of SiYuan editor that opens in a new window by default", + "options": { + "desktop": "Desktop Editor", + "mobile": "Mobile Editor", + "window": "Native Multi-Window Editor" + }, + "title": "Editor Type" + }, + "enable": { + "description": "Open SiYuan Editor in a new window", + "title": "Enable" + }, + "focus": { + "description": "Whether the SiYuan editor opened in a new window is focused by default", + "title": "Focus" + }, + "open": { + "desktop": { + "description": "Open a window of SiYuan desktop editor", + "text": "Open", + "title": "Desktop Editor" + }, + "mobile": { + "description": "Open a window of SiYuan mobile editor", + "text": "Open", + "title": "Mobile Editor" + } + }, + "title": "SiYuan Editor" + }, + "window": { + "center": { + "description": "Show new window in the center of the screen", + "title": "Window Centering" + }, + "height": { + "description": "The default height of the new window", + "title": "Window Height" + }, + "menuBar": { + "description": "The visible state of the menu bar", + "options": { + "alwaysShow": "Always Show", + "autoHide": "Auto Hide", + "disabled": "Disabled" + }, + "title": "Menu Bar" + }, + "top": { + "description": "Whether new windows are pinned to the top by default", + "title": "Window Top" + }, + "width": { + "description": "The default width of the new window", + "title": "Window Width" + } + } + }, + "webview": { + "closeDevTools": "Close developer tools", + "enterFullscreen": "Enter full-screen mode", + "exitFullscreen": "Exit full-screen mode", + "goBackOnePage": "Go back one page", + "goForwardOnePage": "Go forward one page", + "openDevTools": "Open developer tools", + "openWithDefaultProgram": "Open with default program", + "openWithNewWindow": "Open with a new window", + "reloadCurrentPage": "Reload current page", + "stopLoadingThisPage": "Stop loading this page" + } +} diff --git a/i18n/zh_CHT.json b/i18n/zh_CHT.json new file mode 100644 index 0000000..83ee7ee --- /dev/null +++ b/i18n/zh_CHT.json @@ -0,0 +1,224 @@ +{ + "displayName": "網頁視圖", + "menu": { + "copyAlt": { + "label": "複製描述" + }, + "copyAudio": { + "label": "複製音頻" + }, + "copyFile": { + "label": "複製文件" + }, + "copyFileName": { + "label": "複製文件名" + }, + "copyFrame": { + "label": "複製框架" + }, + "copyFrameAddress": { + "label": "複製框架地址" + }, + "copyImage": { + "label": "複製圖片" + }, + "copyLink": { + "label": "複製鏈接" + }, + "copyLinkAddress": { + "label": "複製鏈接地址" + }, + "copyPage": { + "label": "複製頁面鏈接" + }, + "copyPageAddress": { + "label": "複製頁面地址" + }, + "copyResourceAddress": { + "label": "複製資源地址" + }, + "copySelectionText": { + "label": "複製劃選文本" + }, + "copyText": { + "label": "複製錨文本" + }, + "copyTitle": { + "label": "複製標題" + }, + "copyVideo": { + "label": "複製視頻" + }, + "openByNewWindow": { + "label": "使用新窗口打開" + }, + "openDesktopWindow": { + "label": "打開思源桌面端窗口" + }, + "openEditor": { + "label": "在新窗口打開" + }, + "openFocusedEditor": { + "label": "在新窗口打開並聚焦" + }, + "openLink": { + "label": "打開鏈接" + }, + "openMobildWindow": { + "label": "打開思源移動端窗口" + }, + "openNewTab": { + "label": "打開新頁簽", + "title": "新頁簽" + }, + "openResource": { + "label": "打開資源" + }, + "openTab": { + "label": "在新頁簽中打開" + }, + "openTabBackground": { + "label": "在後台頁簽中打開" + }, + "openTabBottom": { + "label": "在頁簽下側打開" + }, + "openTabCurrent": { + "label": "在當前頁簽下打開" + }, + "openTabRight": { + "label": "在頁簽右側打開" + } + }, + "message": { + "nonStandardURL": "不規範,請輸入規範的 URL 地址" + }, + "settings": { + "background": { + "description": "網頁的背景顏色或背景圖片", + "title": "網頁背景" + }, + "general": "常規", + "generalSettings": { + "reset": { + "description": "重置所有設置選項為默認選項(重置後將刷新頁面)", + "text": "重置", + "title": "重置設置選項" + }, + "title": "常規設置", + "useragent": { + "description": "使用自定義 User-Agent,該項留空則使用默認 User-Agent(僅支持桌面端)", + "title": "用戶代理字段 (User-Agent, UA)" + } + }, + "mouse": { + "back": "返回鍵", + "button": "鼠標按鍵", + "forward": "前進鍵", + "left": "左鍵", + "middle": "中鍵", + "right": "右鍵" + }, + "open": { + "editorHyperlink": { + "description": "訪問編輯器中的超鏈接", + "title": "編輯器超鏈接" + }, + "enable": { + "tab": { + "description": "在新標籤頁中打開超鏈接(僅支持桌面端)", + "title": "啟用" + }, + "window": { + "description": "在新窗口中打開超鏈接", + "title": "啟用" + } + }, + "otherHyperlink": { + "description": "訪問其他位置的超鏈接", + "title": "其他超鏈接" + }, + "shortcut": { + "title": "用於打開超鏈接的按鍵組合" + } + }, + "openTab": "打開頁簽", + "openWindow": "打開窗口", + "protocol": "協議", + "protocols": { + "title": "激活的 URL 協議列表" + }, + "shortcut": "快捷鍵", + "siyuan": { + "editorType": { + "description": "默認在新窗口中打開的思源編輯器類型", + "options": { + "desktop": "桌面端編輯器", + "mobile": "移動端編輯器", + "window": "原生多窗口編輯器" + }, + "title": "編輯器類型" + }, + "enable": { + "description": "在新窗口中打開思源編輯器", + "title": "啟用" + }, + "focus": { + "description": "在新窗口中打開的思源編輯器是否默認聚焦", + "title": "聚焦" + }, + "open": { + "desktop": { + "description": "打開一個思源桌面端編輯器窗口", + "text": "打開", + "title": "桌面端編輯器" + }, + "mobile": { + "description": "打開一個思源移動端編輯器窗口", + "text": "打開", + "title": "移動端編輯器" + } + }, + "title": "思源編輯器" + }, + "window": { + "center": { + "description": "在螢幕中央顯示新視窗", + "title": "視窗居中" + }, + "height": { + "description": "新窗口的默認高度", + "title": "窗口高度" + }, + "menuBar": { + "description": "菜單欄的可見狀態", + "options": { + "alwaysShow": "總是顯示", + "autoHide": "自動隱藏", + "disabled": "禁用" + }, + "title": "菜單欄" + }, + "top": { + "description": "打开的新窗口是否默认置顶", + "title": "窗口置頂" + }, + "width": { + "description": "新窗口的默认宽度", + "title": "窗口寬度" + } + } + }, + "webview": { + "closeDevTools": "關閉開發者工具", + "enterFullscreen": "進入全屏模式", + "exitFullscreen": "退出全屏模式", + "goBackOnePage": "轉到上一頁", + "goForwardOnePage": "轉到下一頁", + "openDevTools": "打開開發者工具", + "openWithDefaultProgram": "使用預設程式打開", + "openWithNewWindow": "使用新窗口打開", + "reloadCurrentPage": "重載當前頁面", + "stopLoadingThisPage": "停止加載此頁面" + } +} diff --git a/i18n/zh_CN.json b/i18n/zh_CN.json new file mode 100644 index 0000000..b3182ff --- /dev/null +++ b/i18n/zh_CN.json @@ -0,0 +1,224 @@ +{ + "displayName": "网页视图", + "menu": { + "copyAlt": { + "label": "复制描述" + }, + "copyAudio": { + "label": "复制音频" + }, + "copyFile": { + "label": "复制文件" + }, + "copyFileName": { + "label": "复制文件名" + }, + "copyFrame": { + "label": "复制框架" + }, + "copyFrameAddress": { + "label": "复制框架地址" + }, + "copyImage": { + "label": "复制图片" + }, + "copyLink": { + "label": "复制链接" + }, + "copyLinkAddress": { + "label": "复制链接地址" + }, + "copyPage": { + "label": "复制页面链接" + }, + "copyPageAddress": { + "label": "复制页面地址" + }, + "copyResourceAddress": { + "label": "复制资源地址" + }, + "copySelectionText": { + "label": "复制划选文本" + }, + "copyText": { + "label": "复制锚文本" + }, + "copyTitle": { + "label": "复制标题" + }, + "copyVideo": { + "label": "复制视频" + }, + "openByNewWindow": { + "label": "使用新窗口打开" + }, + "openDesktopWindow": { + "label": "打开思源桌面端窗口" + }, + "openEditor": { + "label": "在新窗口打开" + }, + "openFocusedEditor": { + "label": "在新窗口打开并聚焦" + }, + "openLink": { + "label": "打开链接" + }, + "openMobildWindow": { + "label": "打开思源移动端窗口" + }, + "openNewTab": { + "label": "打开新标签页", + "title": "新标签页" + }, + "openResource": { + "label": "打开资源" + }, + "openTab": { + "label": "在新页签中打开" + }, + "openTabBackground": { + "label": "在后台页签中打开" + }, + "openTabBottom": { + "label": "在页签下侧打开" + }, + "openTabCurrent": { + "label": "在当前页签中打开" + }, + "openTabRight": { + "label": "在页签右侧打开" + } + }, + "message": { + "nonStandardURL": "不规范,请输入规范的 URL 地址" + }, + "settings": { + "background": { + "description": "网页的背景颜色或背景图片", + "title": "网页背景" + }, + "general": "常规", + "generalSettings": { + "reset": { + "description": "重置所有设置选项为默认选项(重置后将刷新页面)", + "text": "重置", + "title": "重置设置选项" + }, + "title": "常规设置", + "useragent": { + "description": "使用自定义 User-Agent,该项留空则使用默认 User-Agent(仅支持桌面端)", + "title": "用户代理字段 (User-Agent, UA)" + } + }, + "mouse": { + "back": "返回键", + "button": "鼠标按键", + "forward": "前进键", + "left": "左键", + "middle": "中键", + "right": "右键" + }, + "open": { + "editorHyperlink": { + "description": "访问编辑器中的超链接", + "title": "编辑器超链接" + }, + "enable": { + "tab": { + "description": "在新标签页中打开超链接(仅支持桌面端)", + "title": "启用" + }, + "window": { + "description": "在新窗口中打开超链接", + "title": "启用" + } + }, + "otherHyperlink": { + "description": "访问其他位置的超链接", + "title": "其他超链接" + }, + "shortcut": { + "title": "用于打开超链接的按键组合" + } + }, + "openTab": "打开页签", + "openWindow": "打开窗口", + "protocol": "协议", + "protocols": { + "title": "激活的 URL 协议列表" + }, + "shortcut": "快捷键", + "siyuan": { + "editorType": { + "description": "默认在新窗口中打开的思源编辑器类型", + "options": { + "desktop": "桌面端编辑器", + "mobile": "移动端编辑器", + "window": "原生多窗口编辑器" + }, + "title": "编辑器类型" + }, + "enable": { + "description": "在新窗口中打开思源编辑器", + "title": "启用" + }, + "focus": { + "description": "在新窗口中打开的思源编辑器是否默认聚焦", + "title": "聚焦" + }, + "open": { + "desktop": { + "description": "打开一个思源桌面端编辑器窗口", + "text": "打开", + "title": "桌面端编辑器" + }, + "mobile": { + "description": "打开一个思源移动端编辑器窗口", + "text": "打开", + "title": "移动端编辑器" + } + }, + "title": "思源编辑器" + }, + "window": { + "center": { + "description": "在屏幕中央显示新窗口", + "title": "窗口居中" + }, + "height": { + "description": "新窗口的默认高度", + "title": "窗口高度" + }, + "menuBar": { + "description": "菜单栏的可见状态", + "options": { + "alwaysShow": "总是显示", + "autoHide": "自动隐藏", + "disabled": "禁用" + }, + "title": "菜单栏" + }, + "top": { + "description": "打开的新窗口是否默认置顶", + "title": "窗口置顶" + }, + "width": { + "description": "新窗口的默认宽度", + "title": "窗口宽度" + } + } + }, + "webview": { + "closeDevTools": "关闭开发者工具", + "enterFullscreen": "进入全屏模式", + "exitFullscreen": "退出全屏模式", + "goBackOnePage": "转到上一页", + "goForwardOnePage": "转到下一页", + "openDevTools": "打开开发者工具", + "openWithDefaultProgram": "使用默认程序打开", + "openWithNewWindow": "使用新窗口打开", + "reloadCurrentPage": "刷新当前页面", + "stopLoadingThisPage": "停止加载此页面" + } +} diff --git a/icon.png b/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..3f932dbd02c818746291cba5a0d80cdd18337207 GIT binary patch literal 19595 zcmV)(K#RYLP)eNL!&aYSZ5#!%$VN2C$QIOYJxh!|O)dEe)6U!FsKA&3A7&$(t}df_s36S*rC zcsVO|3NfEV4lh-#x(MhZq7HylNPtl#jDQ(A1Cs+e{cOxWO}s;qyG2L-76LY9cVpAH z-@d{}Z4pEOgjZz#nQBS5J%C*OP_TNCt8i}u?&UhPl$jL{q74v424Mt5n#(U^P=0A< z=<>&maU#Qs3g9ThI7*d12NV$;XY9QK9G8$Py&P5kybO`i2D_Q{e+|^X4b0!7qWN>% zqQSqt@3M!7s188{K)ASP%c9Wbr#qyc=sNT$MRXs4Qw$&o8UDdn5Z(PgiWq@5FlKtw zdo`yqGbTeRAmu7}4#D#X>5?#{R9PShWdg(ar#AYx9O7qrWq$DaJ6H7LZUhkk;lkJc zr(MH)p{JbZDu*7e2&XbL1tF044T_;b5SX&jGgo1>H4uR6Mc@$jDMUbOObnX6gRitg zIz=FmG0a=S$oyIv^DX5@-~7;R_a4SQp-thGTnd4#T37oDvRl;U9>@t1lt-A;=AxrjK^xlT>*#&`1EX*H z-Wwh?ilc=HfNf4l3dE0}q1ZY09Mh^`ph*Si-`UwMG)PjZ}6c;KL`&4D8H zg^af~7t?QeUuJ0@HADnJmgBayHnpv6O5qC4+&M5DVQADGcC$086#>Zu)Y^Md1a!1I znA`5aA>;zB-Z2!W)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y~LP2#F8Q$()KJnwoT|o&pexMF3U?E3kBl1q-jhKgMBoLxUZD{C-&xlDenCD*kt)X z*S_+ijGEd2Y6go}-TLnrL`C`Zi_V)^fBu%}q3OKLBy9tTqF77sn12dNqBvIJe4^Ri z{PA1AXzL6$14zyPwg(3S00000K>n|dpsK2>s;a80s;UBaxHT+!D@#ZK0000e in t?Ss(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var le=(t,e,n)=>(As(t,typeof e!="symbol"?e+"":e,n),n);const qe=require("siyuan");var $s=Object.defineProperty,Rs=(t,e,n)=>e in t?$s(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ft=(t,e,n)=>(Rs(t,typeof e!="symbol"?e+"":e,n),n);const vs=/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,Cs=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,Ls=/^\s*["[{]|^\s*-?\d[\d.]{0,14}\s*$/;function Os(t,e){if(t==="__proto__"||t==="constructor"&&e&&typeof e=="object"&&"prototype"in e){Ns(t);return}return e}function Ns(t){console.warn(`[destr] Dropping "${t}" key to prevent prototype pollution.`)}function Is(t,e={}){if(typeof t!="string")return t;const n=t.trim();if(t[0]==='"'&&t[t.length-1]==='"')return n.slice(1,-1);if(n.length<=9){const i=n.toLowerCase();if(i==="true")return!0;if(i==="false")return!1;if(i==="undefined")return;if(i==="null")return null;if(i==="nan")return Number.NaN;if(i==="infinity")return Number.POSITIVE_INFINITY;if(i==="-infinity")return Number.NEGATIVE_INFINITY}if(!Ls.test(t)){if(e.strict)throw new SyntaxError("[destr] Invalid JSON");return t}try{if(vs.test(t)||Cs.test(t)){if(e.strict)throw new Error("[destr] Possible prototype pollution");return JSON.parse(t,Os)}return JSON.parse(t)}catch(i){if(e.strict)throw i;return t}}const Ms=/#/g,Fs=/&/g,Ps=/=/g,di=/\+/g,Ds=/%5e/gi,Us=/%60/gi,Ws=/%7c/gi,js=/%20/gi;function qs(t){return encodeURI(""+t).replace(Ws,"|")}function ti(t){return qs(typeof t=="string"?t:JSON.stringify(t)).replace(di,"%2B").replace(js,"+").replace(Ms,"%23").replace(Fs,"%26").replace(Us,"`").replace(Ds,"^")}function Hn(t){return ti(t).replace(Ps,"%3D")}function yr(t=""){try{return decodeURIComponent(""+t)}catch{return""+t}}function Hs(t){return yr(t.replace(di," "))}function Ks(t){return yr(t.replace(di," "))}function xs(t=""){const e={};t[0]==="?"&&(t=t.slice(1));for(const n of t.split("&")){const i=n.match(/([^=]+)=?(.*)/)||[];if(i.length<2)continue;const o=Hs(i[1]);if(o==="__proto__"||o==="constructor")continue;const r=Ks(i[2]||"");e[o]===void 0?e[o]=r:Array.isArray(e[o])?e[o].push(r):e[o]=[e[o],r]}return e}function Vs(t,e){return(typeof e=="number"||typeof e=="boolean")&&(e=String(e)),e?Array.isArray(e)?e.map(n=>`${Hn(t)}=${ti(n)}`).join("&"):`${Hn(t)}=${ti(e)}`:Hn(t)}function zs(t){return Object.keys(t).filter(e=>t[e]!==void 0).map(e=>Vs(e,t[e])).filter(Boolean).join("&")}const Gs=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,Ys=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,Js=/^([/\\]\s*){2,}[^/\\]/;function wr(t,e={}){return typeof e=="boolean"&&(e={acceptRelative:e}),e.strict?Gs.test(t):Ys.test(t)||(e.acceptRelative?Js.test(t):!1)}const Xs=/\/$|\/\?/;function ni(t="",e=!1){return e?Xs.test(t):t.endsWith("/")}function Qs(t="",e=!1){if(!e)return(ni(t)?t.slice(0,-1):t)||"/";if(!ni(t,!0))return t||"/";const[n,...i]=t.split("?");return(n.slice(0,-1)||"/")+(i.length>0?`?${i.join("?")}`:"")}function Zs(t="",e=!1){if(!e)return t.endsWith("/")?t:t+"/";if(ni(t,!0))return t||"/";const[n,...i]=t.split("?");return n+"/"+(i.length>0?`?${i.join("?")}`:"")}function ea(t,e){if(na(e)||wr(t))return t;const n=Qs(e);return t.startsWith(n)?t:ra(n,t)}function ta(t,e){const n=kr(t),i={...xs(n.search),...e};return n.search=zs(i),sa(n)}function na(t){return!t||t==="/"}function ia(t){return t&&t!=="/"}const oa=/^\.?\//;function ra(t,...e){let n=t||"";for(const i of e.filter(o=>ia(o)))if(n){const o=i.replace(oa,"");n=Zs(n)+o}else n=i;return n}function kr(t="",e){const n=t.match(/^[\s\0]*(blob:|data:|javascript:|vbscript:)(.*)/);if(n){const[,m,_=""]=n;return{protocol:m,pathname:_,href:m+_,auth:"",host:"",search:"",hash:""}}if(!wr(t,{acceptRelative:!0}))return e?kr(e+t):Ri(t);const[,i="",o,r=""]=t.replace(/\\/g,"/").match(/^[\s\0]*([\w+.-]{2,}:)?\/\/([^/@]+@)?(.*)/)||[],[,a="",s=""]=r.match(/([^#/?]*)(.*)?/)||[],{pathname:u,search:f,hash:p}=Ri(s.replace(/\/(?=[A-Za-z]:)/,""));return{protocol:i,auth:o?o.slice(0,Math.max(0,o.length-1)):"",host:a,pathname:u,search:f,hash:p}}function Ri(t=""){const[e="",n="",i=""]=(t.match(/([^#?]*)(\?[^#]*)?(#.*)?/)||[]).splice(1);return{pathname:e,search:n,hash:i}}function sa(t){const e=t.pathname||"",n=t.search?(t.search.startsWith("?")?"":"?")+t.search:"",i=t.hash||"",o=t.auth?t.auth+"@":"",r=t.host||"";return(t.protocol?t.protocol+"//":"")+o+r+e+n+i}class aa extends Error{constructor(e,n){super(e,n),this.name="FetchError",n!=null&&n.cause&&!this.cause&&(this.cause=n.cause)}}function la(t){var e,n,i,o,r;const a=((e=t.error)==null?void 0:e.message)||((n=t.error)==null?void 0:n.toString())||"",s=((i=t.request)==null?void 0:i.method)||((o=t.options)==null?void 0:o.method)||"GET",u=((r=t.request)==null?void 0:r.url)||String(t.request)||"/",f=`[${s}] ${JSON.stringify(u)}`,p=t.response?`${t.response.status} ${t.response.statusText}`:"",m=`${f}: ${p}${a?` ${a}`:""}`,_=new aa(m,t.error?{cause:t.error}:void 0);for(const b of["request","options","response"])Object.defineProperty(_,b,{get(){return t[b]}});for(const[b,g]of[["data","_data"],["status","status"],["statusCode","status"],["statusText","statusText"],["statusMessage","statusText"]])Object.defineProperty(_,b,{get(){return t.response&&t.response[g]}});return _}const ua=new Set(Object.freeze(["PATCH","POST","PUT","DELETE"]));function vi(t="GET"){return ua.has(t.toUpperCase())}function ca(t){if(t===void 0)return!1;const e=typeof t;return e==="string"||e==="number"||e==="boolean"||e===null?!0:e!=="object"?!1:Array.isArray(t)?!0:t.buffer?!1:t.constructor&&t.constructor.name==="Object"||typeof t.toJSON=="function"}const fa=new Set(["image/svg","application/xml","application/xhtml","application/html"]),pa=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function ha(t=""){if(!t)return"json";const e=t.split(";").shift()||"";return pa.test(e)?"json":fa.has(e)||e.startsWith("text/")?"text":"blob"}function da(t,e,n=globalThis.Headers){const i={...e,...t};if(e!=null&&e.params&&t!=null&&t.params&&(i.params={...e==null?void 0:e.params,...t==null?void 0:t.params}),e!=null&&e.query&&t!=null&&t.query&&(i.query={...e==null?void 0:e.query,...t==null?void 0:t.query}),e!=null&&e.headers&&t!=null&&t.headers){i.headers=new n((e==null?void 0:e.headers)||{});for(const[o,r]of new n((t==null?void 0:t.headers)||{}))i.headers.set(o,r)}return i}const ma=new Set([408,409,425,429,500,502,503,504]),ga=new Set([101,204,205,304]);function Tr(t={}){const{fetch:e=globalThis.fetch,Headers:n=globalThis.Headers,AbortController:i=globalThis.AbortController}=t;async function o(s){const u=s.error&&s.error.name==="AbortError"&&!s.options.timeout||!1;if(s.options.retry!==!1&&!u){let p;typeof s.options.retry=="number"?p=s.options.retry:p=vi(s.options.method)?0:1;const m=s.response&&s.response.status||500;if(p>0&&(Array.isArray(s.options.retryStatusCodes)?s.options.retryStatusCodes.includes(m):ma.has(m))){const _=s.options.retryDelay||0;return _>0&&await new Promise(b=>setTimeout(b,_)),r(s.request,{...s.options,retry:p-1,timeout:s.options.timeout})}}const f=la(s);throw Error.captureStackTrace&&Error.captureStackTrace(f,r),f}const r=async function(s,u={}){var f;const p={request:s,options:da(u,t.defaults,n),response:void 0,error:void 0};if(p.options.method=(f=p.options.method)==null?void 0:f.toUpperCase(),p.options.onRequest&&await p.options.onRequest(p),typeof p.request=="string"&&(p.options.baseURL&&(p.request=ea(p.request,p.options.baseURL)),(p.options.query||p.options.params)&&(p.request=ta(p.request,{...p.options.params,...p.options.query}))),p.options.body&&vi(p.options.method)&&(ca(p.options.body)?(p.options.body=typeof p.options.body=="string"?p.options.body:JSON.stringify(p.options.body),p.options.headers=new n(p.options.headers||{}),p.options.headers.has("content-type")||p.options.headers.set("content-type","application/json"),p.options.headers.has("accept")||p.options.headers.set("accept","application/json")):("pipeTo"in p.options.body&&typeof p.options.body.pipeTo=="function"||typeof p.options.body.pipe=="function")&&("duplex"in p.options||(p.options.duplex="half"))),!p.options.signal&&p.options.timeout){const m=new i;setTimeout(()=>m.abort(),p.options.timeout),p.options.signal=m.signal}try{p.response=await e(p.request,p.options)}catch(m){return p.error=m,p.options.onRequestError&&await p.options.onRequestError(p),await o(p)}if(p.response.body&&!ga.has(p.response.status)&&p.options.method!=="HEAD"){const m=(p.options.parseResponse?"json":p.options.responseType)||ha(p.response.headers.get("content-type")||"");switch(m){case"json":{const _=await p.response.text(),b=p.options.parseResponse||Is;p.response._data=b(_);break}case"stream":{p.response._data=p.response.body;break}default:p.response._data=await p.response[m]()}}return p.options.onResponse&&await p.options.onResponse(p),!p.options.ignoreResponseError&&p.response.status>=400&&p.response.status<600?(p.options.onResponseError&&await p.options.onResponseError(p),await o(p)):p.response},a=async function(s,u){return(await r(s,u))._data};return a.raw=r,a.native=(...s)=>e(...s),a.create=(s={})=>Tr({...t,defaults:{...t.defaults,...s}}),a}const mi=function(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}(),ba=mi.fetch||(()=>Promise.reject(new Error("[ofetch] global.fetch is not supported!"))),_a=mi.Headers,ya=mi.AbortController,wa=Tr({fetch:ba,Headers:_a,AbortController:ya});class ka extends Error{constructor(e){super(e.statusText),ft(this,"status"),this.response=e,this.status=e.status}}class Ci extends Error{constructor(e,n){super(e.msg),ft(this,"code"),this.body=e,this.response=n,this.code=e.code}}function rt(t){if(typeof t!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(t))}function Li(t,e){for(var n="",i=0,o=-1,r=0,a,s=0;s<=t.length;++s){if(s2){var u=n.lastIndexOf("/");if(u!==n.length-1){u===-1?(n="",i=0):(n=n.slice(0,u),i=n.length-1-n.lastIndexOf("/")),o=s,r=0;continue}}else if(n.length===2||n.length===1){n="",i=0,o=s,r=0;continue}}e&&(n.length>0?n+="/..":n="..",i=2)}else n.length>0?n+="/"+t.slice(o+1,s):n=t.slice(o+1,s),i=s-o-1;o=s,r=0}else a===46&&r!==-1?++r:r=-1}return n}function Ta(t,e){var n=e.dir||e.root,i=e.base||(e.name||"")+(e.ext||"");return n?n===e.root?n+i:n+t+i:i}var xt={resolve:function(){for(var t="",e=!1,n,i=arguments.length-1;i>=-1&&!e;i--){var o;i>=0?o=arguments[i]:(n===void 0&&(n=process.cwd()),o=n),rt(o),o.length!==0&&(t=o+"/"+t,e=o.charCodeAt(0)===47)}return t=Li(t,!e),e?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function(t){if(rt(t),t.length===0)return".";var e=t.charCodeAt(0)===47,n=t.charCodeAt(t.length-1)===47;return t=Li(t,!e),t.length===0&&!e&&(t="."),t.length>0&&n&&(t+="/"),e?"/"+t:t},isAbsolute:function(t){return rt(t),t.length>0&&t.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var t,e=0;e0&&(t===void 0?t=n:t+="/"+n)}return t===void 0?".":xt.normalize(t)},relative:function(t,e){if(rt(t),rt(e),t===e||(t=xt.resolve(t),e=xt.resolve(e),t===e))return"";for(var n=1;nu){if(e.charCodeAt(r+p)===47)return e.slice(r+p+1);if(p===0)return e.slice(r+p)}else o>u&&(t.charCodeAt(n+p)===47?f=p:p===0&&(f=0));break}var m=t.charCodeAt(n+p),_=e.charCodeAt(r+p);if(m!==_)break;m===47&&(f=p)}var b="";for(p=n+f+1;p<=i;++p)(p===i||t.charCodeAt(p)===47)&&(b.length===0?b+="..":b+="/..");return b.length>0?b+e.slice(r+f):(r+=f,e.charCodeAt(r)===47&&++r,e.slice(r))},_makeLong:function(t){return t},dirname:function(t){if(rt(t),t.length===0)return".";for(var e=t.charCodeAt(0),n=e===47,i=-1,o=!0,r=t.length-1;r>=1;--r)if(e=t.charCodeAt(r),e===47){if(!o){i=r;break}}else o=!1;return i===-1?n?"/":".":n&&i===1?"//":t.slice(0,i)},basename:function(t,e){if(e!==void 0&&typeof e!="string")throw new TypeError('"ext" argument must be a string');rt(t);var n=0,i=-1,o=!0,r;if(e!==void 0&&e.length>0&&e.length<=t.length){if(e.length===t.length&&e===t)return"";var a=e.length-1,s=-1;for(r=t.length-1;r>=0;--r){var u=t.charCodeAt(r);if(u===47){if(!o){n=r+1;break}}else s===-1&&(o=!1,s=r+1),a>=0&&(u===e.charCodeAt(a)?--a===-1&&(i=r):(a=-1,i=s))}return n===i?i=s:i===-1&&(i=t.length),t.slice(n,i)}else{for(r=t.length-1;r>=0;--r)if(t.charCodeAt(r)===47){if(!o){n=r+1;break}}else i===-1&&(o=!1,i=r+1);return i===-1?"":t.slice(n,i)}},extname:function(t){rt(t);for(var e=-1,n=0,i=-1,o=!0,r=0,a=t.length-1;a>=0;--a){var s=t.charCodeAt(a);if(s===47){if(!o){n=a+1;break}continue}i===-1&&(o=!1,i=a+1),s===46?e===-1?e=a:r!==1&&(r=1):e!==-1&&(r=-1)}return e===-1||i===-1||r===0||r===1&&e===i-1&&e===n+1?"":t.slice(e,i)},format:function(t){if(t===null||typeof t!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof t);return Ta("/",t)},parse:function(t){rt(t);var e={root:"",dir:"",base:"",ext:"",name:""};if(t.length===0)return e;var n=t.charCodeAt(0),i=n===47,o;i?(e.root="/",o=1):o=0;for(var r=-1,a=0,s=-1,u=!0,f=t.length-1,p=0;f>=o;--f){if(n=t.charCodeAt(f),n===47){if(!u){a=f+1;break}continue}s===-1&&(u=!1,s=f+1),n===46?r===-1?r=f:p!==1&&(p=1):r!==-1&&(p=-1)}return r===-1||s===-1||p===0||p===1&&r===s-1&&r===a+1?s!==-1&&(a===0&&i?e.base=e.name=t.slice(1,s):e.base=e.name=t.slice(a,s)):(a===0&&i?(e.name=t.slice(1,r),e.base=t.slice(1,s)):(e.name=t.slice(a,r),e.base=t.slice(a,s)),e.ext=t.slice(r,s)),a>0?e.dir=t.slice(0,a-1):i&&(e.dir="/"),e},sep:"/",delimiter:":",win32:null,posix:null};xt.posix=xt;function Er(t,e){return function(){return t.apply(e,arguments)}}const{toString:Ea}=Object.prototype,{getPrototypeOf:gi}=Object,In=(t=>e=>{const n=Ea.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),lt=t=>(t=t.toLowerCase(),e=>In(e)===t),Mn=t=>e=>typeof e===t,{isArray:Wt}=Array,zt=Mn("undefined");function Ba(t){return t!==null&&!zt(t)&&t.constructor!==null&&!zt(t.constructor)&&Ye(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Br=lt("ArrayBuffer");function Sa(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Br(t.buffer),e}const Aa=Mn("string"),Ye=Mn("function"),Sr=Mn("number"),Fn=t=>t!==null&&typeof t=="object",$a=t=>t===!0||t===!1,En=t=>{if(In(t)!=="object")return!1;const e=gi(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},Ra=lt("Date"),va=lt("File"),Ca=lt("Blob"),La=lt("FileList"),Oa=t=>Fn(t)&&Ye(t.pipe),Na=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||Ye(t.append)&&((e=In(t))==="formdata"||e==="object"&&Ye(t.toString)&&t.toString()==="[object FormData]"))},Ia=lt("URLSearchParams"),Ma=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Xt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let i,o;if(typeof t!="object"&&(t=[t]),Wt(t))for(i=0,o=t.length;i0;)if(o=n[i],e===o.toLowerCase())return o;return null}const $r=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),Rr=t=>!zt(t)&&t!==$r;function ii(){const{caseless:t}=Rr(this)&&this||{},e={},n=(i,o)=>{const r=t&&Ar(e,o)||o;En(e[r])&&En(i)?e[r]=ii(e[r],i):En(i)?e[r]=ii({},i):Wt(i)?e[r]=i.slice():e[r]=i};for(let i=0,o=arguments.length;i(Xt(e,(o,r)=>{n&&Ye(o)?t[r]=Er(o,n):t[r]=o},{allOwnKeys:i}),t),Pa=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Da=(t,e,n,i)=>{t.prototype=Object.create(e.prototype,i),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},Ua=(t,e,n,i)=>{let o,r,a;const s={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),r=o.length;r-- >0;)a=o[r],(!i||i(a,t,e))&&!s[a]&&(e[a]=t[a],s[a]=!0);t=n!==!1&&gi(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},Wa=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const i=t.indexOf(e,n);return i!==-1&&i===n},ja=t=>{if(!t)return null;if(Wt(t))return t;let e=t.length;if(!Sr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},qa=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&gi(Uint8Array)),Ha=(t,e)=>{const n=(t&&t[Symbol.iterator]).call(t);let i;for(;(i=n.next())&&!i.done;){const o=i.value;e.call(t,o[0],o[1])}},Ka=(t,e)=>{let n;const i=[];for(;(n=t.exec(e))!==null;)i.push(n);return i},xa=lt("HTMLFormElement"),Va=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,n,i){return n.toUpperCase()+i}),Oi=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),za=lt("RegExp"),vr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),i={};Xt(n,(o,r)=>{let a;(a=e(o,r,t))!==!1&&(i[r]=a||o)}),Object.defineProperties(t,i)},Ga=t=>{vr(t,(e,n)=>{if(Ye(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const i=t[n];if(Ye(i)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},Ya=(t,e)=>{const n={},i=o=>{o.forEach(r=>{n[r]=!0})};return Wt(t)?i(t):i(String(t).split(e)),n},Ja=()=>{},Xa=(t,e)=>(t=+t,Number.isFinite(t)?t:e),Kn="abcdefghijklmnopqrstuvwxyz",Ni="0123456789",Cr={DIGIT:Ni,ALPHA:Kn,ALPHA_DIGIT:Kn+Kn.toUpperCase()+Ni},Qa=(t=16,e=Cr.ALPHA_DIGIT)=>{let n="";const{length:i}=e;for(;t--;)n+=e[Math.random()*i|0];return n};function Za(t){return!!(t&&Ye(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const el=t=>{const e=new Array(10),n=(i,o)=>{if(Fn(i)){if(e.indexOf(i)>=0)return;if(!("toJSON"in i)){e[o]=i;const r=Wt(i)?[]:{};return Xt(i,(a,s)=>{const u=n(a,o+1);!zt(u)&&(r[s]=u)}),e[o]=void 0,r}}return i};return n(t,0)},tl=lt("AsyncFunction"),nl=t=>t&&(Fn(t)||Ye(t))&&Ye(t.then)&&Ye(t.catch),v={isArray:Wt,isArrayBuffer:Br,isBuffer:Ba,isFormData:Na,isArrayBufferView:Sa,isString:Aa,isNumber:Sr,isBoolean:$a,isObject:Fn,isPlainObject:En,isUndefined:zt,isDate:Ra,isFile:va,isBlob:Ca,isRegExp:za,isFunction:Ye,isStream:Oa,isURLSearchParams:Ia,isTypedArray:qa,isFileList:La,forEach:Xt,merge:ii,extend:Fa,trim:Ma,stripBOM:Pa,inherits:Da,toFlatObject:Ua,kindOf:In,kindOfTest:lt,endsWith:Wa,toArray:ja,forEachEntry:Ha,matchAll:Ka,isHTMLForm:xa,hasOwnProperty:Oi,hasOwnProp:Oi,reduceDescriptors:vr,freezeMethods:Ga,toObjectSet:Ya,toCamelCase:Va,noop:Ja,toFiniteNumber:Xa,findKey:Ar,global:$r,isContextDefined:Rr,ALPHABET:Cr,generateString:Qa,isSpecCompliantForm:Za,toJSONObject:el,isAsyncFn:tl,isThenable:nl};function ie(t,e,n,i,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),i&&(this.request=i),o&&(this.response=o)}v.inherits(ie,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:v.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Lr=ie.prototype,Or={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{Or[t]={value:t}});Object.defineProperties(ie,Or);Object.defineProperty(Lr,"isAxiosError",{value:!0});ie.from=(t,e,n,i,o,r)=>{const a=Object.create(Lr);return v.toFlatObject(t,a,function(s){return s!==Error.prototype},s=>s!=="isAxiosError"),ie.call(a,t.message,e,n,i,o),a.cause=t,a.name=t.name,r&&Object.assign(a,r),a};const il=null;function oi(t){return v.isPlainObject(t)||v.isArray(t)}function Nr(t){return v.endsWith(t,"[]")?t.slice(0,-2):t}function Ii(t,e,n){return t?t.concat(e).map(function(i,o){return i=Nr(i),!n&&o?"["+i+"]":i}).join(n?".":""):e}function ol(t){return v.isArray(t)&&!t.some(oi)}const rl=v.toFlatObject(v,{},null,function(t){return/^is[A-Z]/.test(t)});function Pn(t,e,n){if(!v.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=v.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(b,g){return!v.isUndefined(g[b])});const i=n.metaTokens,o=n.visitor||f,r=n.dots,a=n.indexes,s=(n.Blob||typeof Blob<"u"&&Blob)&&v.isSpecCompliantForm(e);if(!v.isFunction(o))throw new TypeError("visitor must be a function");function u(b){if(b===null)return"";if(v.isDate(b))return b.toISOString();if(!s&&v.isBlob(b))throw new ie("Blob is not supported. Use a Buffer instead.");return v.isArrayBuffer(b)||v.isTypedArray(b)?s&&typeof Blob=="function"?new Blob([b]):Buffer.from(b):b}function f(b,g,y){let k=b;if(b&&!y&&typeof b=="object"){if(v.endsWith(g,"{}"))g=i?g:g.slice(0,-2),b=JSON.stringify(b);else if(v.isArray(b)&&ol(b)||(v.isFileList(b)||v.endsWith(g,"[]"))&&(k=v.toArray(b)))return g=Nr(g),k.forEach(function(W,S){!(v.isUndefined(W)||W===null)&&e.append(a===!0?Ii([g],S,r):a===null?g:g+"[]",u(W))}),!1}return oi(b)?!0:(e.append(Ii(y,g,r),u(b)),!1)}const p=[],m=Object.assign(rl,{defaultVisitor:f,convertValue:u,isVisitable:oi});function _(b,g){if(!v.isUndefined(b)){if(p.indexOf(b)!==-1)throw Error("Circular reference detected in "+g.join("."));p.push(b),v.forEach(b,function(y,k){(!(v.isUndefined(y)||y===null)&&o.call(e,y,v.isString(k)?k.trim():k,g,m))===!0&&_(y,g?g.concat(k):[k])}),p.pop()}}if(!v.isObject(t))throw new TypeError("data must be an object");return _(t),e}function Mi(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function bi(t,e){this._pairs=[],t&&Pn(t,this,e)}const Ir=bi.prototype;Ir.append=function(t,e){this._pairs.push([t,e])};Ir.toString=function(t){const e=t?function(n){return t.call(this,n,Mi)}:Mi;return this._pairs.map(function(n){return e(n[0])+"="+e(n[1])},"").join("&")};function sl(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Mr(t,e,n){if(!e)return t;const i=n&&n.encode||sl,o=n&&n.serialize;let r;if(o?r=o(e,n):r=v.isURLSearchParams(e)?e.toString():new bi(e,n).toString(i),r){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+r}return t}class al{constructor(){this.handlers=[]}use(e,n,i){return this.handlers.push({fulfilled:e,rejected:n,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){v.forEach(this.handlers,function(n){n!==null&&e(n)})}}const Fi=al,Fr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},ll=typeof URLSearchParams<"u"?URLSearchParams:bi,ul=typeof FormData<"u"?FormData:null,cl=typeof Blob<"u"?Blob:null,fl=(()=>{let t;return typeof navigator<"u"&&((t=navigator.product)==="ReactNative"||t==="NativeScript"||t==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),pl=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),tt={isBrowser:!0,classes:{URLSearchParams:ll,FormData:ul,Blob:cl},isStandardBrowserEnv:fl,isStandardBrowserWebWorkerEnv:pl,protocols:["http","https","file","blob","url","data"]};function hl(t,e){return Pn(t,new tt.classes.URLSearchParams,Object.assign({visitor:function(n,i,o,r){return tt.isNode&&v.isBuffer(n)?(this.append(i,n.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},e))}function dl(t){return v.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function ml(t){const e={},n=Object.keys(t);let i;const o=n.length;let r;for(i=0;i=n.length;return a=!a&&v.isArray(o)?o.length:a,u?(v.hasOwnProp(o,a)?o[a]=[o[a],i]:o[a]=i,!s):((!o[a]||!v.isObject(o[a]))&&(o[a]=[]),e(n,i,o[a],r)&&v.isArray(o[a])&&(o[a]=ml(o[a])),!s)}if(v.isFormData(t)&&v.isFunction(t.entries)){const n={};return v.forEachEntry(t,(i,o)=>{e(dl(i),o,n,0)}),n}return null}function gl(t,e,n){if(v.isString(t))try{return(e||JSON.parse)(t),v.trim(t)}catch(i){if(i.name!=="SyntaxError")throw i}return(n||JSON.stringify)(t)}const _i={transitional:Fr,adapter:tt.isNode?"http":"xhr",transformRequest:[function(t,e){const n=e.getContentType()||"",i=n.indexOf("application/json")>-1,o=v.isObject(t);if(o&&v.isHTMLForm(t)&&(t=new FormData(t)),v.isFormData(t))return i&&i?JSON.stringify(Pr(t)):t;if(v.isArrayBuffer(t)||v.isBuffer(t)||v.isStream(t)||v.isFile(t)||v.isBlob(t))return t;if(v.isArrayBufferView(t))return t.buffer;if(v.isURLSearchParams(t))return e.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let r;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return hl(t,this.formSerializer).toString();if((r=v.isFileList(t))||n.indexOf("multipart/form-data")>-1){const a=this.env&&this.env.FormData;return Pn(r?{"files[]":t}:t,a&&new a,this.formSerializer)}}return o||i?(e.setContentType("application/json",!1),gl(t)):t}],transformResponse:[function(t){const e=this.transitional||_i.transitional,n=e&&e.forcedJSONParsing,i=this.responseType==="json";if(t&&v.isString(t)&&(n&&!this.responseType||i)){const o=!(e&&e.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(r){if(o)throw r.name==="SyntaxError"?ie.from(r,ie.ERR_BAD_RESPONSE,this,null,this.response):r}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:tt.classes.FormData,Blob:tt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};v.forEach(["delete","get","head","post","put","patch"],t=>{_i.headers[t]={}});const yi=_i,bl=v.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),_l=t=>{const e={};let n,i,o;return t&&t.split(` +`).forEach(function(r){o=r.indexOf(":"),n=r.substring(0,o).trim().toLowerCase(),i=r.substring(o+1).trim(),!(!n||e[n]&&bl[n])&&(n==="set-cookie"?e[n]?e[n].push(i):e[n]=[i]:e[n]=e[n]?e[n]+", "+i:i)}),e},Pi=Symbol("internals");function qt(t){return t&&String(t).trim().toLowerCase()}function Bn(t){return t===!1||t==null?t:v.isArray(t)?t.map(Bn):String(t)}function yl(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let i;for(;i=n.exec(t);)e[i[1]]=i[2];return e}const wl=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function xn(t,e,n,i,o){if(v.isFunction(i))return i.call(this,e,n);if(o&&(e=n),!!v.isString(e)){if(v.isString(i))return e.indexOf(i)!==-1;if(v.isRegExp(i))return i.test(e)}}function kl(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,i)=>n.toUpperCase()+i)}function Tl(t,e){const n=v.toCamelCase(" "+e);["get","set","has"].forEach(i=>{Object.defineProperty(t,i+n,{value:function(o,r,a){return this[i].call(this,e,o,r,a)},configurable:!0})})}let Dn=class{constructor(t){t&&this.set(t)}set(t,e,n){const i=this;function o(a,s,u){const f=qt(s);if(!f)throw new Error("header name must be a non-empty string");const p=v.findKey(i,f);(!p||i[p]===void 0||u===!0||u===void 0&&i[p]!==!1)&&(i[p||s]=Bn(a))}const r=(a,s)=>v.forEach(a,(u,f)=>o(u,f,s));return v.isPlainObject(t)||t instanceof this.constructor?r(t,e):v.isString(t)&&(t=t.trim())&&!wl(t)?r(_l(t),e):t!=null&&o(e,t,n),this}get(t,e){if(t=qt(t),t){const n=v.findKey(this,t);if(n){const i=this[n];if(!e)return i;if(e===!0)return yl(i);if(v.isFunction(e))return e.call(this,i,n);if(v.isRegExp(e))return e.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,e){if(t=qt(t),t){const n=v.findKey(this,t);return!!(n&&this[n]!==void 0&&(!e||xn(this,this[n],n,e)))}return!1}delete(t,e){const n=this;let i=!1;function o(r){if(r=qt(r),r){const a=v.findKey(n,r);a&&(!e||xn(n,n[a],a,e))&&(delete n[a],i=!0)}}return v.isArray(t)?t.forEach(o):o(t),i}clear(t){const e=Object.keys(this);let n=e.length,i=!1;for(;n--;){const o=e[n];(!t||xn(this,this[o],o,t,!0))&&(delete this[o],i=!0)}return i}normalize(t){const e=this,n={};return v.forEach(this,(i,o)=>{const r=v.findKey(n,o);if(r){e[r]=Bn(i),delete e[o];return}const a=t?kl(o):String(o).trim();a!==o&&delete e[o],e[a]=Bn(i),n[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const e=Object.create(null);return v.forEach(this,(n,i)=>{n!=null&&n!==!1&&(e[i]=t&&v.isArray(n)?n.join(", "):n)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,e])=>t+": "+e).join(` +`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...e){const n=new this(t);return e.forEach(i=>n.set(i)),n}static accessor(t){const e=(this[Pi]=this[Pi]={accessors:{}}).accessors,n=this.prototype;function i(o){const r=qt(o);e[r]||(Tl(n,o),e[r]=!0)}return v.isArray(t)?t.forEach(i):i(t),this}};Dn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);v.reduceDescriptors(Dn.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(i){this[n]=i}}});v.freezeMethods(Dn);const pt=Dn;function Vn(t,e){const n=this||yi,i=e||n,o=pt.from(i.headers);let r=i.data;return v.forEach(t,function(a){r=a.call(n,r,o.normalize(),e?e.status:void 0)}),o.normalize(),r}function Dr(t){return!!(t&&t.__CANCEL__)}function Qt(t,e,n){ie.call(this,t??"canceled",ie.ERR_CANCELED,e,n),this.name="CanceledError"}v.inherits(Qt,ie,{__CANCEL__:!0});function El(t,e,n){const i=n.config.validateStatus;!n.status||!i||i(n.status)?t(n):e(new ie("Request failed with status code "+n.status,[ie.ERR_BAD_REQUEST,ie.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const Bl=tt.isStandardBrowserEnv?function(){return{write:function(t,e,n,i,o,r){const a=[];a.push(t+"="+encodeURIComponent(e)),v.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),v.isString(i)&&a.push("path="+i),v.isString(o)&&a.push("domain="+o),r===!0&&a.push("secure"),document.cookie=a.join("; ")},read:function(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function Sl(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Al(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}function Ur(t,e){return t&&!Sl(e)?Al(t,e):e}const $l=tt.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),e=document.createElement("a");let n;function i(o){let r=o;return t&&(e.setAttribute("href",r),r=e.href),e.setAttribute("href",r),{href:e.href,protocol:e.protocol?e.protocol.replace(/:$/,""):"",host:e.host,search:e.search?e.search.replace(/^\?/,""):"",hash:e.hash?e.hash.replace(/^#/,""):"",hostname:e.hostname,port:e.port,pathname:e.pathname.charAt(0)==="/"?e.pathname:"/"+e.pathname}}return n=i(window.location.href),function(o){const r=v.isString(o)?i(o):o;return r.protocol===n.protocol&&r.host===n.host}}():function(){return function(){return!0}}();function Rl(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function vl(t,e){t=t||10;const n=new Array(t),i=new Array(t);let o=0,r=0,a;return e=e!==void 0?e:1e3,function(s){const u=Date.now(),f=i[r];a||(a=u),n[o]=s,i[o]=u;let p=r,m=0;for(;p!==o;)m+=n[p++],p=p%t;if(o=(o+1)%t,o===r&&(r=(r+1)%t),u-a{const r=o.loaded,a=o.lengthComputable?o.total:void 0,s=r-n,u=i(s),f=r<=a;n=r;const p={loaded:r,total:a,progress:a?r/a:void 0,bytes:s,rate:u||void 0,estimated:u&&a&&f?(a-r)/u:void 0,event:o};p[e?"download":"upload"]=!0,t(p)}}const Cl=typeof XMLHttpRequest<"u",Ll=Cl&&function(t){return new Promise(function(e,n){let i=t.data;const o=pt.from(t.headers).normalize(),r=t.responseType;let a;function s(){t.cancelToken&&t.cancelToken.unsubscribe(a),t.signal&&t.signal.removeEventListener("abort",a)}v.isFormData(i)&&(tt.isStandardBrowserEnv||tt.isStandardBrowserWebWorkerEnv?o.setContentType(!1):o.setContentType("multipart/form-data;",!1));let u=new XMLHttpRequest;if(t.auth){const _=t.auth.username||"",b=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";o.set("Authorization","Basic "+btoa(_+":"+b))}const f=Ur(t.baseURL,t.url);u.open(t.method.toUpperCase(),Mr(f,t.params,t.paramsSerializer),!0),u.timeout=t.timeout;function p(){if(!u)return;const _=pt.from("getAllResponseHeaders"in u&&u.getAllResponseHeaders()),b={data:!r||r==="text"||r==="json"?u.responseText:u.response,status:u.status,statusText:u.statusText,headers:_,config:t,request:u};El(function(g){e(g),s()},function(g){n(g),s()},b),u=null}if("onloadend"in u?u.onloadend=p:u.onreadystatechange=function(){!u||u.readyState!==4||u.status===0&&!(u.responseURL&&u.responseURL.indexOf("file:")===0)||setTimeout(p)},u.onabort=function(){u&&(n(new ie("Request aborted",ie.ECONNABORTED,t,u)),u=null)},u.onerror=function(){n(new ie("Network Error",ie.ERR_NETWORK,t,u)),u=null},u.ontimeout=function(){let _=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";const b=t.transitional||Fr;t.timeoutErrorMessage&&(_=t.timeoutErrorMessage),n(new ie(_,b.clarifyTimeoutError?ie.ETIMEDOUT:ie.ECONNABORTED,t,u)),u=null},tt.isStandardBrowserEnv){const _=(t.withCredentials||$l(f))&&t.xsrfCookieName&&Bl.read(t.xsrfCookieName);_&&o.set(t.xsrfHeaderName,_)}i===void 0&&o.setContentType(null),"setRequestHeader"in u&&v.forEach(o.toJSON(),function(_,b){u.setRequestHeader(b,_)}),v.isUndefined(t.withCredentials)||(u.withCredentials=!!t.withCredentials),r&&r!=="json"&&(u.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&u.addEventListener("progress",Di(t.onDownloadProgress,!0)),typeof t.onUploadProgress=="function"&&u.upload&&u.upload.addEventListener("progress",Di(t.onUploadProgress)),(t.cancelToken||t.signal)&&(a=_=>{u&&(n(!_||_.type?new Qt(null,t,u):_),u.abort(),u=null)},t.cancelToken&&t.cancelToken.subscribe(a),t.signal&&(t.signal.aborted?a():t.signal.addEventListener("abort",a)));const m=Rl(f);if(m&&tt.protocols.indexOf(m)===-1){n(new ie("Unsupported protocol "+m+":",ie.ERR_BAD_REQUEST,t));return}u.send(i||null)})},Sn={http:il,xhr:Ll};v.forEach(Sn,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Wr={getAdapter:t=>{t=v.isArray(t)?t:[t];const{length:e}=t;let n,i;for(let o=0;ot instanceof pt?t.toJSON():t;function Dt(t,e){e=e||{};const n={};function i(f,p,m){return v.isPlainObject(f)&&v.isPlainObject(p)?v.merge.call({caseless:m},f,p):v.isPlainObject(p)?v.merge({},p):v.isArray(p)?p.slice():p}function o(f,p,m){if(v.isUndefined(p)){if(!v.isUndefined(f))return i(void 0,f,m)}else return i(f,p,m)}function r(f,p){if(!v.isUndefined(p))return i(void 0,p)}function a(f,p){if(v.isUndefined(p)){if(!v.isUndefined(f))return i(void 0,f)}else return i(void 0,p)}function s(f,p,m){if(m in e)return i(f,p);if(m in t)return i(void 0,f)}const u={url:r,method:r,data:r,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(f,p)=>o(Wi(f),Wi(p),!0)};return v.forEach(Object.keys(Object.assign({},t,e)),function(f){const p=u[f]||o,m=p(t[f],e[f],f);v.isUndefined(m)&&p!==s||(n[f]=m)}),n}const jr="1.5.0",wi={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{wi[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const ji={};wi.transitional=function(t,e,n){function i(o,r){return"[Axios v"+jr+"] Transitional option '"+o+"'"+r+(n?". "+n:"")}return(o,r,a)=>{if(t===!1)throw new ie(i(r," has been removed"+(e?" in "+e:"")),ie.ERR_DEPRECATED);return e&&!ji[r]&&(ji[r]=!0,console.warn(i(r," has been deprecated since v"+e+" and will be removed in the near future"))),t?t(o,r,a):!0}};function Ol(t,e,n){if(typeof t!="object")throw new ie("options must be an object",ie.ERR_BAD_OPTION_VALUE);const i=Object.keys(t);let o=i.length;for(;o-- >0;){const r=i[o],a=e[r];if(a){const s=t[r],u=s===void 0||a(s,r,t);if(u!==!0)throw new ie("option "+r+" must be "+u,ie.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ie("Unknown option "+r,ie.ERR_BAD_OPTION)}}const ri={assertOptions:Ol,validators:wi},yt=ri.validators;let Rn=class{constructor(t){this.defaults=t,this.interceptors={request:new Fi,response:new Fi}}request(t,e){typeof t=="string"?(e=e||{},e.url=t):e=t||{},e=Dt(this.defaults,e);const{transitional:n,paramsSerializer:i,headers:o}=e;n!==void 0&&ri.assertOptions(n,{silentJSONParsing:yt.transitional(yt.boolean),forcedJSONParsing:yt.transitional(yt.boolean),clarifyTimeoutError:yt.transitional(yt.boolean)},!1),i!=null&&(v.isFunction(i)?e.paramsSerializer={serialize:i}:ri.assertOptions(i,{encode:yt.function,serialize:yt.function},!0)),e.method=(e.method||this.defaults.method||"get").toLowerCase();let r=o&&v.merge(o.common,o[e.method]);o&&v.forEach(["delete","get","head","post","put","patch","common"],b=>{delete o[b]}),e.headers=pt.concat(r,o);const a=[];let s=!0;this.interceptors.request.forEach(function(b){typeof b.runWhen=="function"&&b.runWhen(e)===!1||(s=s&&b.synchronous,a.unshift(b.fulfilled,b.rejected))});const u=[];this.interceptors.response.forEach(function(b){u.push(b.fulfilled,b.rejected)});let f,p=0,m;if(!s){const b=[Ui.bind(this),void 0];for(b.unshift.apply(b,a),b.push.apply(b,u),m=b.length,f=Promise.resolve(e);p{if(!i._listeners)return;let r=i._listeners.length;for(;r-- >0;)i._listeners[r](o);i._listeners=null}),this.promise.then=o=>{let r;const a=new Promise(s=>{i.subscribe(s),r=s}).then(o);return a.cancel=function(){i.unsubscribe(r)},a},e(function(o,r,a){i.reason||(i.reason=new Qt(o,r,a),n(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}static source(){let e;return{token:new qr(function(n){e=n}),cancel:e}}};const Il=Nl;function Ml(t){return function(e){return t.apply(null,e)}}function Fl(t){return v.isObject(t)&&t.isAxiosError===!0}const si={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(si).forEach(([t,e])=>{si[e]=t});const Pl=si;function Hr(t){const e=new An(t),n=Er(An.prototype.request,e);return v.extend(n,An.prototype,e,{allOwnKeys:!0}),v.extend(n,e,null,{allOwnKeys:!0}),n.create=function(i){return Hr(Dt(t,i))},n}const we=Hr(yi);we.Axios=An;we.CanceledError=Qt;we.CancelToken=Il;we.isCancel=Dr;we.VERSION=jr;we.toFormData=Pn;we.AxiosError=ie;we.Cancel=we.CanceledError;we.all=function(t){return Promise.all(t)};we.spread=Ml;we.isAxiosError=Fl;we.mergeConfig=Dt;we.AxiosHeaders=pt;we.formToJSON=t=>Pr(v.isHTMLForm(t)?new FormData(t):t);we.getAdapter=Wr.getAdapter;we.HttpStatusCode=Pl;we.default=we;const Kr=we,{Axios:Zp,AxiosError:eh,CanceledError:th,isCancel:nh,CancelToken:ih,VERSION:oh,all:rh,Cancel:sh,isAxiosError:ah,spread:lh,toFormData:uh,AxiosHeaders:ch,HttpStatusCode:tn,formToJSON:fh,getAdapter:ph,mergeConfig:hh}=Kr;var Ot=null;typeof WebSocket<"u"?Ot=WebSocket:typeof MozWebSocket<"u"?Ot=MozWebSocket:typeof global<"u"?Ot=global.WebSocket||global.MozWebSocket:typeof window<"u"?Ot=window.WebSocket||window.MozWebSocket:typeof self<"u"&&(Ot=self.WebSocket||self.MozWebSocket);const Dl=Ot,Gn={SCHEMA_DIR_RELATIVE_PATH:"./../schemas/",SCHEMA_FILENAME_PAYLOAD:"payload.schema.json",SCHEMA_FILENAME_RESPONSE:"response.schema.json",SIYUAN_DEFAULT_BASE_URL:"http://localhost:6806/",SIYUAN_DEFAULT_TOKEN:"",REQUEST_TIMEOUT:6e4};var qi,Hi,Ki,xi,Vi;const ai=class A{constructor(e={},n="xhr"){ft(this,"_type","xhr"),ft(this,"_baseURL",((Hi=(qi=globalThis.top)==null?void 0:qi.document)==null?void 0:Hi.baseURI)??((xi=(Ki=globalThis.parent)==null?void 0:Ki.document)==null?void 0:xi.baseURI)??((Vi=globalThis.location)==null?void 0:Vi.origin)??Gn.SIYUAN_DEFAULT_BASE_URL),ft(this,"_token",Gn.SIYUAN_DEFAULT_TOKEN),ft(this,"_axios",Kr.create({baseURL:this._baseURL,timeout:Gn.REQUEST_TIMEOUT,headers:{Authorization:`Token ${this._token}`}})),ft(this,"_fetch",wa.create({baseURL:this._baseURL,headers:{Authorization:`Token ${this._token}`}})),this._setClientType(n),this._updateOptions(e,n)}_setClientType(e){this._type=e}_updateOptions(e,n=this._type){switch(this._token=e.token??this._token,this._baseURL=e.baseURL??this._baseURL,n){case"fetch":const i=e;if(i.token){const o="Authorization",r=`Token ${e.token}`;Array.isArray(i.headers)?i.headers.push([o,r]):i.headers instanceof Headers?i.headers.set(o,r):typeof i.headers=="object"?i.headers[o]=r:i.headers={[o]:r},delete e.token}this._fetch=this._fetch.create(i);break;case"xhr":default:for(const[o,r]of Object.entries(e))switch(o){case"token":this._axios.defaults.headers.Authorization=`Token ${this._token}`;break;default:this._axios.defaults[o]=r;break}break}this._baseURL=e.baseURL??this._baseURL}broadcast(e,n,i){const o=(i==null?void 0:i.baseURL)??this._baseURL,r=(i==null?void 0:i.token)??this._token,a=new URLSearchParams(e);a.set("token",r);const s=new URL(o);return s.protocol=s.protocol.replace(/^http/,"ws"),s.pathname=s.pathname.endsWith("/")?`${s.pathname}${A.ws.broadcast.pathname.substring(1)}`:`${s.pathname}${A.ws.broadcast.pathname}`,s.search=a.toString(),new Dl(s,n)}async getConf(e){return await this._request(A.api.system.getConf.pathname,A.api.system.getConf.method,void 0,e)}async upload(e,n){const i=new FormData;return i.append("assetsDirPath",e.assetsDirPath??"/assets/"),e.files.forEach(o=>i.append("file[]",o)),await this._request(A.api.asset.upload.pathname,A.api.asset.upload.method,i,n)}async getBlockAttrs(e,n){return await this._request(A.api.attr.getBlockAttrs.pathname,A.api.attr.getBlockAttrs.method,e,n)}async getBookmarkLabels(e){return await this._request(A.api.attr.getBookmarkLabels.pathname,A.api.attr.getBookmarkLabels.method,void 0,e)}async setBlockAttrs(e,n){return await this._request(A.api.attr.setBlockAttrs.pathname,A.api.attr.setBlockAttrs.method,e,n)}async appendBlock(e,n){return await this._request(A.api.block.appendBlock.pathname,A.api.block.appendBlock.method,e,n)}async deleteBlock(e,n){return await this._request(A.api.block.deleteBlock.pathname,A.api.block.deleteBlock.method,e,n)}async getBlockBreadcrumb(e,n){return await this._request(A.api.block.getBlockBreadcrumb.pathname,A.api.block.getBlockBreadcrumb.method,e,n)}async getBlockDOM(e,n){return await this._request(A.api.block.getBlockDOM.pathname,A.api.block.getBlockDOM.method,e,n)}async getBlockInfo(e,n){return await this._request(A.api.block.getBlockInfo.pathname,A.api.block.getBlockInfo.method,e,n)}async getBlockKramdown(e,n){return await this._request(A.api.block.getBlockKramdown.pathname,A.api.block.getBlockKramdown.method,e,n)}async getChildBlocks(e,n){return await this._request(A.api.block.getChildBlocks.pathname,A.api.block.getChildBlocks.method,e,n)}async getDocInfo(e,n){return await this._request(A.api.block.getDocInfo.pathname,A.api.block.getDocInfo.method,e,n)}async insertBlock(e,n){return await this._request(A.api.block.insertBlock.pathname,A.api.block.insertBlock.method,e,n)}async moveBlock(e,n){return await this._request(A.api.block.moveBlock.pathname,A.api.block.moveBlock.method,e,n)}async prependBlock(e,n){return await this._request(A.api.block.prependBlock.pathname,A.api.block.prependBlock.method,e,n)}async transferBlockRef(e,n){return await this._request(A.api.block.transferBlockRef.pathname,A.api.block.transferBlockRef.method,e,n)}async updateBlock(e,n){return await this._request(A.api.block.updateBlock.pathname,A.api.block.updateBlock.method,e,n)}async channels(e){return await this._request(A.api.broadcast.channels.pathname,A.api.broadcast.channels.method,void 0,e)}async getChannelInfo(e,n){return await this._request(A.api.broadcast.getChannelInfo.pathname,A.api.broadcast.getChannelInfo.method,e,n)}async postMessage(e,n){return await this._request(A.api.broadcast.postMessage.pathname,A.api.broadcast.postMessage.method,e,n)}async pandoc(e,n){return await this._request(A.api.convert.pandoc.pathname,A.api.convert.pandoc.method,e,n)}async exportResources(e,n){return await this._request(A.api.export.exportResources.pathname,A.api.export.exportResources.method,e,n)}async exportMdContent(e,n){return await this._request(A.api.export.exportMdContent.pathname,A.api.export.exportMdContent.method,e,n)}async getFile(e,n="text",i){return await this._request(A.api.file.getFile.pathname,A.api.file.getFile.method,e,i,!1,n)}async putFile(e,n){e.file!==void 0&&!(e.file instanceof File)&&(e.file=new File([e.file],e.path.split("/").pop()));const i=new FormData;for(const[o,r]of Object.entries(e))e.hasOwnProperty(o)&&(r instanceof Blob?i.append(o,r):i.append(o,String(r)));return await this._request(A.api.file.putFile.pathname,A.api.file.putFile.method,i,n)}async readDir(e,n){return await this._request(A.api.file.readDir.pathname,A.api.file.readDir.method,e,n)}async removeFile(e,n){return await this._request(A.api.file.removeFile.pathname,A.api.file.removeFile.method,e,n)}async renameFile(e,n){return await this._request(A.api.file.renameFile.pathname,A.api.file.renameFile.method,e,n)}async createDocWithMd(e,n){return await this._request(A.api.filetree.createDocWithMd.pathname,A.api.filetree.createDocWithMd.method,e,n)}async getDoc(e,n){return await this._request(A.api.filetree.getDoc.pathname,A.api.filetree.getDoc.method,e,n)}async getHPathByID(e,n){return await this._request(A.api.filetree.getHPathByID.pathname,A.api.filetree.getHPathByID.method,e,n)}async getHPathByPath(e,n){return await this._request(A.api.filetree.getHPathByPath.pathname,A.api.filetree.getHPathByPath.method,e,n)}async listDocsByPath(e,n){return await this._request(A.api.filetree.listDocsByPath.pathname,A.api.filetree.listDocsByPath.method,e,n)}async moveDocs(e,n){return await this._request(A.api.filetree.moveDocs.pathname,A.api.filetree.moveDocs.method,e,n)}async removeDoc(e,n){return await this._request(A.api.filetree.removeDoc.pathname,A.api.filetree.removeDoc.method,e,n)}async renameDoc(e,n){return await this._request(A.api.filetree.renameDoc.pathname,A.api.filetree.renameDoc.method,e,n)}async searchDocs(e,n){return await this._request(A.api.filetree.searchDocs.pathname,A.api.filetree.searchDocs.method,e,n)}async getDocHistoryContent(e,n){return await this._request(A.api.history.getDocHistoryContent.pathname,A.api.history.getDocHistoryContent.method,e,n)}async getHistoryItems(e,n){return await this._request(A.api.history.getHistoryItems.pathname,A.api.history.getHistoryItems.method,e,n)}async getShorthand(e,n){return await this._request(A.api.inbox.getShorthand.pathname,A.api.inbox.getShorthand.method,e,n)}async forwardProxy(e,n){return await this._request(A.api.network.forwardProxy.pathname,A.api.network.forwardProxy.method,e,n)}async closeNotebook(e,n){return await this._request(A.api.notebook.closeNotebook.pathname,A.api.notebook.closeNotebook.method,e,n)}async createNotebook(e,n){return await this._request(A.api.notebook.createNotebook.pathname,A.api.notebook.createNotebook.method,e,n)}async getNotebookConf(e,n){return await this._request(A.api.notebook.getNotebookConf.pathname,A.api.notebook.getNotebookConf.method,e,n)}async lsNotebooks(e){return await this._request(A.api.notebook.lsNotebooks.pathname,A.api.notebook.lsNotebooks.method,void 0,e)}async openNotebook(e,n){return await this._request(A.api.notebook.openNotebook.pathname,A.api.notebook.openNotebook.method,e,n)}async removeNotebook(e,n){return await this._request(A.api.notebook.removeNotebook.pathname,A.api.notebook.removeNotebook.method,e,n)}async renameNotebook(e,n){return await this._request(A.api.notebook.renameNotebook.pathname,A.api.notebook.renameNotebook.method,e,n)}async setNotebookConf(e,n){return await this._request(A.api.notebook.setNotebookConf.pathname,A.api.notebook.setNotebookConf.method,e,n)}async pushErrMsg(e,n){return await this._request(A.api.notification.pushErrMsg.pathname,A.api.notification.pushErrMsg.method,e,n)}async pushMsg(e,n){return await this._request(A.api.notification.pushMsg.pathname,A.api.notification.pushMsg.method,e,n)}async sql(e,n){return await this._request(A.api.query.sql.pathname,A.api.query.sql.method,e,n)}async openRepoSnapshotDoc(e,n){return await this._request(A.api.repo.openRepoSnapshotDoc.pathname,A.api.repo.openRepoSnapshotDoc.method,e,n)}async fullTextSearchBlock(e,n){return await this._request(A.api.search.fullTextSearchBlock.pathname,A.api.search.fullTextSearchBlock.method,e,n)}async getSnippet(e,n){return await this._request(A.api.snippet.getSnippet.pathname,A.api.snippet.getSnippet.method,e,n)}async setSnippet(e,n){return await this._request(A.api.snippet.setSnippet.pathname,A.api.snippet.setSnippet.method,e,n)}async getRecentDocs(e){return await this._request(A.api.storage.getRecentDocs.pathname,A.api.storage.getRecentDocs.method,void 0,e)}async bootProgress(e){return await this._request(A.api.system.bootProgress.pathname,A.api.system.bootProgress.method,void 0,e)}async currentTime(e){return await this._request(A.api.system.currentTime.pathname,A.api.system.currentTime.method,void 0,e)}async version(e){return await this._request(A.api.system.version.pathname,A.api.system.version.method,void 0,e)}async render(e,n){return await this._request(A.api.template.render.pathname,A.api.template.render.method,e,n)}async renderSprig(e,n){return await this._request(A.api.template.renderSprig.pathname,A.api.template.renderSprig.method,e,n)}async _request(e,n,i,o,r=!0,a="json"){try{switch((o==null?void 0:o.type)??this._type){case"fetch":{const s=o==null?void 0:o.options;a=(()=>{switch(a){case"arraybuffer":return"arrayBuffer";case"document":return"text";default:return a}})();const u=await this._fetch(e,{method:n,body:i,responseType:a,onResponse:async f=>{switch(f.response.status){case tn.Ok:break;case tn.Accepted:e===A.api.file.getFile.pathname&&this._parseFetchResponse(f.response._data);break;default:break}},...s});return r&&a==="json"&&typeof u=="object"?this._parseFetchResponse(u):u}case"xhr":default:{const s=o==null?void 0:o.options;a=(()=>{switch(a){case"arrayBuffer":return"arraybuffer";default:return a}})();const u=await this._axios.request({url:e,method:n,data:i,responseType:a,...s});switch(u.status){case tn.Ok:return r&&a==="json"&&typeof u.data=="object"?this._parseAxiosResponse(u):u.data;case tn.Accepted:return e===A.api.file.getFile.pathname?this._parseAxiosResponse(u):u.data;default:throw new ka(u)}}}}catch(s){throw s}}_parseFetchResponse(e){if(e.code===0)return e;throw new Ci(e)}_parseAxiosResponse(e){if(e.data.code===0)return e.data;throw new Ci(e.data,e)}};ft(ai,"ws",{broadcast:{pathname:"/ws/broadcast"}}),ft(ai,"api",{asset:{upload:{pathname:"/api/asset/upload",method:"POST"}},attr:{getBlockAttrs:{pathname:"/api/attr/getBlockAttrs",method:"POST"},getBookmarkLabels:{pathname:"/api/attr/getBookmarkLabels",method:"POST"},setBlockAttrs:{pathname:"/api/attr/setBlockAttrs",method:"POST"}},block:{appendBlock:{pathname:"/api/block/appendBlock",method:"POST"},deleteBlock:{pathname:"/api/block/deleteBlock",method:"POST"},getBlockBreadcrumb:{pathname:"/api/block/getBlockBreadcrumb",method:"POST"},getBlockDOM:{pathname:"/api/block/getBlockDOM",method:"POST"},getBlockInfo:{pathname:"/api/block/getBlockInfo",method:"POST"},getBlockKramdown:{pathname:"/api/block/getBlockKramdown",method:"POST"},getChildBlocks:{pathname:"/api/block/getChildBlocks",method:"POST"},getDocInfo:{pathname:"/api/block/getDocInfo",method:"POST"},insertBlock:{pathname:"/api/block/insertBlock",method:"POST"},moveBlock:{pathname:"/api/block/moveBlock",method:"POST"},prependBlock:{pathname:"/api/block/prependBlock",method:"POST"},transferBlockRef:{pathname:"/api/block/transferBlockRef",method:"POST"},updateBlock:{pathname:"/api/block/updateBlock",method:"POST"}},broadcast:{channels:{pathname:"/api/broadcast/channels",method:"GET"},getChannelInfo:{pathname:"/api/broadcast/getChannelInfo",method:"POST"},postMessage:{pathname:"/api/broadcast/postMessage",method:"POST"}},convert:{pandoc:{pathname:"/api/convert/pandoc",method:"POST"}},export:{exportMdContent:{pathname:"/api/export/exportMdContent",method:"POST"},exportResources:{pathname:"/api/export/exportResources",method:"POST"}},file:{getFile:{pathname:"/api/file/getFile",method:"POST"},putFile:{pathname:"/api/file/putFile",method:"POST"},readDir:{pathname:"/api/file/readDir",method:"POST"},removeFile:{pathname:"/api/file/removeFile",method:"POST"},renameFile:{pathname:"/api/file/renameFile",method:"POST"}},filetree:{createDocWithMd:{pathname:"/api/filetree/createDocWithMd",method:"POST"},getDoc:{pathname:"/api/filetree/getDoc",method:"POST"},getHPathByID:{pathname:"/api/filetree/getHPathByID",method:"POST"},getHPathByPath:{pathname:"/api/filetree/getHPathByPath",method:"POST"},listDocsByPath:{pathname:"/api/filetree/listDocsByPath",method:"POST"},moveDocs:{pathname:"/api/filetree/moveDocs",method:"POST"},removeDoc:{pathname:"/api/filetree/removeDoc",method:"POST"},renameDoc:{pathname:"/api/filetree/renameDoc",method:"POST"},searchDocs:{pathname:"/api/filetree/searchDocs",method:"POST"}},history:{getDocHistoryContent:{pathname:"/api/history/getDocHistoryContent",method:"POST"},getHistoryItems:{pathname:"/api/history/getHistoryItems",method:"POST"}},inbox:{getShorthand:{pathname:"/api/inbox/getShorthand",method:"POST"}},network:{forwardProxy:{pathname:"/api/network/forwardProxy",method:"POST"}},notebook:{closeNotebook:{pathname:"/api/notebook/closeNotebook",method:"POST"},createNotebook:{pathname:"/api/notebook/createNotebook",method:"POST"},getNotebookConf:{pathname:"/api/notebook/getNotebookConf",method:"POST"},lsNotebooks:{pathname:"/api/notebook/lsNotebooks",method:"POST"},openNotebook:{pathname:"/api/notebook/openNotebook",method:"POST"},removeNotebook:{pathname:"/api/notebook/removeNotebook",method:"POST"},renameNotebook:{pathname:"/api/notebook/renameNotebook",method:"POST"},setNotebookConf:{pathname:"/api/notebook/setNotebookConf",method:"POST"}},notification:{pushErrMsg:{pathname:"/api/notification/pushErrMsg",method:"POST"},pushMsg:{pathname:"/api/notification/pushMsg",method:"POST"}},query:{sql:{pathname:"/api/query/sql",method:"POST"}},repo:{openRepoSnapshotDoc:{pathname:"/api/repo/openRepoSnapshotDoc",method:"POST"}},search:{fullTextSearchBlock:{pathname:"/api/search/fullTextSearchBlock",method:"POST"}},snippet:{getSnippet:{pathname:"/api/snippet/getSnippet",method:"POST"},setSnippet:{pathname:"/api/snippet/setSnippet",method:"POST"}},storage:{getRecentDocs:{pathname:"/api/storage/getRecentDocs",method:"POST"}},system:{bootProgress:{pathname:"/api/system/bootProgress",method:"POST"},currentTime:{pathname:"/api/system/currentTime",method:"POST"},version:{pathname:"/api/system/version",method:"POST"},getConf:{pathname:"/api/system/getConf",method:"POST"}},template:{render:{pathname:"/api/template/render",method:"POST"},renderSprig:{pathname:"/api/template/renderSprig",method:"POST"}}});let Ul=ai;var xr=(t=>(t.NodeNotebook="NodeNotebook",t.NodeFolder="NodeFolder",t.NodeDocument="NodeDocument",t.NodeSuperBlock="NodeSuperBlock",t.NodeBlockquote="NodeBlockquote",t.NodeList="NodeList",t.NodeListItem="NodeListItem",t.NodeHeading="NodeHeading",t.NodeParagraph="NodeParagraph",t.NodeMathBlock="NodeMathBlock",t.NodeTable="NodeTable",t.NodeCodeBlock="NodeCodeBlock",t.NodeHTMLBlock="NodeHTMLBlock",t.NodeThematicBreak="NodeThematicBreak",t.NodeAudio="NodeAudio",t.NodeVideo="NodeVideo",t.NodeIFrame="NodeIFrame",t.NodeWidget="NodeWidget",t.NodeBlockQueryEmbed="NodeBlockQueryEmbed",t))(xr||{}),Vr=(t=>(t.d="d",t.s="s",t.b="b",t.l="l",t.i="i",t.h="h",t.p="p",t.m="m",t.t="t",t.c="c",t.html="html",t.query_embed="query_embed",t.tb="tb",t.audio="audio",t.video="video",t.iframe="iframe",t.widget="widget",t))(Vr||{}),zr=(t=>(t.d="d",t.s="s",t.b="b",t.l="l",t.i="i",t))(zr||{}),Gr=(t=>(t.h="h",t.p="p",t.m="m",t.t="t",t.c="c",t.html="html",t.query_embed="query_embed",t.tb="tb",t.audio="audio",t.video="video",t.iframe="iframe",t.widget="widget",t))(Gr||{}),Yr=(t=>(t.h1="h1",t.h2="h2",t.h3="h3",t.h4="h4",t.h5="h5",t.h6="h6",t.u="u",t.o="o",t.t="t",t.none="",t))(Yr||{}),Jr=(t=>(t.u="u",t.o="o",t.t="t",t))(Jr||{}),Xr=(t=>(t.h1="h1",t.h2="h2",t.h3="h3",t.h4="h4",t.h5="h5",t.h6="h6",t))(Xr||{}),Qr=(t=>(t[t.keyword=0]="keyword",t[t.querySyntax=1]="querySyntax",t[t.sql=2]="sql",t[t.regex=3]="regex",t))(Qr||{}),Zr=(t=>(t[t.noGroupBy=0]="noGroupBy",t[t.group=1]="group",t))(Zr||{}),es=(t=>(t[t.type=0]="type",t[t.createdASC=1]="createdASC",t[t.createdDESC=2]="createdDESC",t[t.modifiedASC=3]="modifiedASC",t[t.modifiedDESC=4]="modifiedDESC",t[t.sortByContent=5]="sortByContent",t[t.sortByRankAsc=6]="sortByRankAsc",t[t.sortByRankDesc=7]="sortByRankDesc",t))(es||{}),ts=(t=>(t[t.SortModeNameASC=0]="SortModeNameASC",t[t.SortModeNameDESC=1]="SortModeNameDESC",t[t.SortModeUpdatedASC=2]="SortModeUpdatedASC",t[t.SortModeUpdatedDESC=3]="SortModeUpdatedDESC",t[t.SortModeAlphanumASC=4]="SortModeAlphanumASC",t[t.SortModeAlphanumDESC=5]="SortModeAlphanumDESC",t[t.SortModeCustom=6]="SortModeCustom",t[t.SortModeRefCountASC=7]="SortModeRefCountASC",t[t.SortModeRefCountDESC=8]="SortModeRefCountDESC",t[t.SortModeCreatedASC=9]="SortModeCreatedASC",t[t.SortModeCreatedDESC=10]="SortModeCreatedDESC",t[t.SortModeSizeASC=11]="SortModeSizeASC",t[t.SortModeSizeDESC=12]="SortModeSizeDESC",t[t.SortModeSubDocCountASC=13]="SortModeSubDocCountASC",t[t.SortModeSubDocCountDESC=14]="SortModeSubDocCountDESC",t))(ts||{});const Nt=Object.freeze(Object.defineProperty({__proto__:null,BlockSubType:Yr,BlockType:Vr,Container:zr,GroupBy:Zr,Leaf:Gr,Method:Qr,NodeHeadingSubType:Xr,NodeListSubType:Jr,NodeType:xr,OrderBy:es,SortMode:ts},Symbol.toStringTag,{value:"Module"})),zi=ns(),Yn=ql();Kl();const Gi=Hl();function Wl(){return!!globalThis.require}function jl(){return!!globalThis.process}function ns(){return jl()&&Wl()}function ql(){switch(qe.getFrontend()){case"desktop":case"desktop-window":case"browser-desktop":return!0;case"mobile":case"browser-mobile":return!1;default:return!1}}function Hl(){switch(qe.getFrontend()){case"mobile":case"browser-mobile":return!0;case"desktop":case"desktop-window":case"browser-desktop":return!1;default:return!1}}function Kl(){switch(qe.getFrontend()){case"browser-desktop":case"browser-mobile":return!0;case"desktop":case"desktop-window":case"mobile":return!1;default:return!1}}class xl{constructor(e,n=!0){this.label=e,this.collapsed=n}stdout(e,n,...i){const o=`[\x1B[4m${this.label}\x1B[0m] - <\x1B[1m${e.name.toUpperCase()}\x1B[0m>`;if(this.collapsed?globalThis.console.groupCollapsed(o):globalThis.console.group(o),n)for(const r of i)Array.isArray(r)?e(...r):e(r);else e(...i);globalThis.console.trace(),globalThis.console.groupEnd()}dir(...e){this.stdout(globalThis.console.dir,!1,...e)}dirs(...e){this.stdout(globalThis.console.dir,!0,...e)}table(...e){this.stdout(globalThis.console.table,!1,...e)}tables(...e){this.stdout(globalThis.console.table,!0,...e)}debug(...e){this.stdout(globalThis.console.debug,!1,...e)}debugs(...e){this.stdout(globalThis.console.debug,!0,...e)}info(...e){this.stdout(globalThis.console.info,!1,...e)}infos(...e){this.stdout(globalThis.console.info,!0,...e)}log(...e){this.stdout(globalThis.console.log,!1,...e)}logs(...e){this.stdout(globalThis.console.log,!0,...e)}warn(...e){this.stdout(globalThis.console.warn,!1,...e)}warns(...e){this.stdout(globalThis.console.warn,!0,...e)}error(...e){this.stdout(globalThis.console.error,!1,...e)}errors(...e){this.stdout(globalThis.console.error,!0,...e)}}function Vl(t,e){switch(!0){case e instanceof Set:return e.has(t);case e instanceof Function:return e(t);default:return t===e}}function Yi(t,e){return Vl(t.button,e.button)&&t.type===e.type&&t.altKey===e.altKey&&t.ctrlKey===e.ctrlKey&&t.metaKey===e.metaKey&&t.shiftKey===e.shiftKey}var zl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Gl(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Yl=function(e){return Jl(e)&&!Xl(e)};function Jl(t){return!!t&&typeof t=="object"}function Xl(t){var e=Object.prototype.toString.call(t);return e==="[object RegExp]"||e==="[object Date]"||eu(t)}var Ql=typeof Symbol=="function"&&Symbol.for,Zl=Ql?Symbol.for("react.element"):60103;function eu(t){return t.$$typeof===Zl}function tu(t){return Array.isArray(t)?[]:{}}function Gt(t,e){return e.clone!==!1&&e.isMergeableObject(t)?Ut(tu(t),t,e):t}function nu(t,e,n){return t.concat(e).map(function(i){return Gt(i,n)})}function iu(t,e){if(!e.customMerge)return Ut;var n=e.customMerge(t);return typeof n=="function"?n:Ut}function ou(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(e){return Object.propertyIsEnumerable.call(t,e)}):[]}function Ji(t){return Object.keys(t).concat(ou(t))}function is(t,e){try{return e in t}catch{return!1}}function ru(t,e){return is(t,e)&&!(Object.hasOwnProperty.call(t,e)&&Object.propertyIsEnumerable.call(t,e))}function su(t,e,n){var i={};return n.isMergeableObject(t)&&Ji(t).forEach(function(o){i[o]=Gt(t[o],n)}),Ji(e).forEach(function(o){ru(t,o)||(is(t,o)&&n.isMergeableObject(e[o])?i[o]=iu(o,n)(t[o],e[o],n):i[o]=Gt(e[o],n))}),i}function Ut(t,e,n){n=n||{},n.arrayMerge=n.arrayMerge||nu,n.isMergeableObject=n.isMergeableObject||Yl,n.cloneUnlessOtherwiseSpecified=Gt;var i=Array.isArray(e),o=Array.isArray(t),r=i===o;return r?i?n.arrayMerge(t,e,n):su(t,e,n):Gt(e,n)}Ut.all=function(e,n){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(i,o){return Ut(i,o,n)},{})};var au=Ut,lu=au;const uu=Gl(lu);function vn(...t){return uu.all(t)}function cu(t){const e=globalThis.document.createElement("a");return e.href=t,new URL(e.href)}const et={id:/^\d{14}-[0-9a-z]{7}$/,url:/^siyuan:\/\/blocks\/(\d{14}-[0-9a-z]{7})/,snippet:/^\d{14}-[0-9a-z]{7}$/,created:/^\d{10}$/,history:/[\/\\]history[\/\\]\d{4}-\d{2}-\d{2}-\d{6}-(clean|update|delete|format|sync|replace)([\/\\]\d{14}-[0-9a-z]{7})+\.sy$/,snapshot:/^[0-9a-f]{40}$/,shorthand:/^\d{13}$/};function fu(t){const e=t.composedPath();for(let n=0;n(t[t.window=0]="window",t[t.app=1]="app",t[t.desktop=2]="desktop",t[t.mobile=3]="mobile",t))(Ge||{}),li=(t=>(t.window="/stage/build/app/window.html",t.app="/stage/build/app",t.desktop="/stage/build/desktop",t.mobile="/stage/build/mobile",t))(li||{});function Jn(t){switch(t){case Ge.window:return"/stage/build/app/window.html";case Ge.app:return"/stage/build/app";case Ge.desktop:return"/stage/build/desktop";case Ge.mobile:return"/stage/build/mobile"}}function Ht(t,e,n=globalThis.origin){const i=new URL(n);return i.pathname=t,e!=null&&e.id&&i.searchParams.set("id",e.id),(e==null?void 0:e.focus)!==void 0&&i.searchParams.set("focus",e.focus?"1":"0"),e!=null&&e.url&&i.searchParams.set("url",e.url),i}function Xi(t){return et.url.test(t.href)?{id:et.url.exec(t.href)[1],focus:t.searchParams.get("focus")==="1"}:null}function pu(t){return et.id.test(t.searchParams.get("id"))?{id:t.searchParams.get("id"),focus:t.searchParams.get("focus")==="1"}:null}function os(t,e=!0){switch(t.startsWith("/")&&(t=t.substring(1)),!0){case t.startsWith("stage/"):return!e;case t.startsWith("appearance/"):case t.startsWith("export/"):case t.startsWith("history/"):case t.startsWith("assets/"):case t.startsWith("emojies/"):case t.startsWith("plugins/"):case t.startsWith("public/"):case t.startsWith("snippets/"):case t.startsWith("templates/"):case t.startsWith("widgets/"):return!0;default:return!1}}function hu(t=globalThis.document.baseURI){return new URL(t).pathname}hu();function rs(t,e){return t.startsWith(e)?t.slice(e.length):t}const du=new Map([["stage","iconFolder"],["assets","iconImage"],["assets","iconImage"],["emojies","iconEmoji"],["plugins","iconPlugin"],["public","iconCloud"],["snippets","iconCode"],["templates","iconMarkdown"],["widgets","iconBoth"],["appearance","iconTheme"],["export","iconUpload"],["history","iconHistory"]]),mu=new Map([["NodeNotebook","iconFilesRoot"],["NodeFolder","iconFolder"],["d","iconFile"],["NodeDocument","iconFile"],["s","iconSuper"],["NodeSuperBlock","iconSuper"],["b","iconQuote"],["NodeBlockquote","iconQuote"],["l","iconList"],["NodeList","iconList"],["i","iconListItem"],["NodeListItem","iconListItem"],["h","iconHeadings"],["NodeHeading","iconHeadings"],["p","iconParagraph"],["NodeParagraph","iconParagraph"],["m","iconMath"],["NodeMathBlock","iconMath"],["t","iconTable"],["NodeTable","iconTable"],["c","iconCode"],["NodeCodeBlock","iconCode"],["html","iconHTML5"],["NodeHTMLBlock","iconHTML5"],["tb","#iconLine"],["NodeThematicBreak","#iconLine"],["audio","iconRecord"],["NodeAudio","iconRecord"],["video","iconVideo"],["NodeVideo","iconVideo"],["iframe","iconLanguage"],["NodeIFrame","iconLanguage"],["widget","iconBoth"],["NodeWidget","iconBoth"],["query_embed","iconSQL"],["NodeBlockQueryEmbed","iconSQL"],["h1","iconH1"],["h2","iconH2"],["h3","iconH3"],["h4","iconH4"],["h5","iconH5"],["h6","iconH6"],["u","iconList"],["o","iconOrderedList"],["t","iconCheck"]]);function gu(t){t.startsWith("/")&&(t=t.substring(1));const e=rs(t,"/").split("/")[0];return bu(e)}function bu(t){return du.get(t)??"iconHelp"}function _u(t){return mu.get(t)??"iconHelp"}function yu(t){const{protyle:e,data:n,blockElements:i}=t;if(n){const o={element:e.wysiwyg.element,id:n.id,type:Nt.NodeType.NodeDocument};return{...o,isDocumentBlock:!0,isMultiBlock:!1,blocks:[o],protyle:e,data:n}}else if(i&&i.length>0){const o=[];return i.forEach(r=>{o.push({element:r,id:r.dataset.nodeId,type:r.dataset.type,subtype:r.dataset.subtype})}),{...o[0],isDocumentBlock:!1,isMultiBlock:o.length>1,blocks:o,protyle:e}}return null}function It(t){return t=t.slice(t.findIndex(e=>e.type!=="separator"),t.findLastIndex(e=>e.type!=="separator")+1),t.length===0||(t=t.filter((e,n,i)=>{var o;return e.type!=="separator"?!0:((o=i[n-1])==null?void 0:o.type)!=="separator"})),t}const wu=` + + +`,ku=` + + +`,Tu=` + + +`,Eu=` + + + +`,Bu=` + + + + + + +`,Su=` + + + +`;function oe(){}const ki=t=>t;function Un(t,e){for(const n in e)t[n]=e[n];return t}function ss(t){return t()}function Qi(){return Object.create(null)}function Ce(t){t.forEach(ss)}function Wn(t){return typeof t=="function"}function $e(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}let nn;function Cn(t,e){return t===e?!0:(nn||(nn=document.createElement("a")),nn.href=e,t===nn.href)}function Au(t){return Object.keys(t).length===0}function Ee(t,e,n,i){if(t){const o=as(t,e,n,i);return t[0](o)}}function as(t,e,n,i){return t[1]&&i?Un(n.ctx.slice(),t[1](i(e))):n.ctx}function Be(t,e,n,i){if(t[2]&&i){const o=t[2](i(n));if(e.dirty===void 0)return o;if(typeof o=="object"){const r=[],a=Math.max(e.dirty.length,o.length);for(let s=0;s32){const e=[],n=t.ctx.length/32;for(let i=0;iwindow.performance.now():()=>Date.now(),Ti=ls?t=>requestAnimationFrame(t):oe;const Ft=new Set;function cs(t){Ft.forEach(e=>{e.c(t)||(Ft.delete(e),e.f())}),Ft.size!==0&&Ti(cs)}function fs(t){let e;return Ft.size===0&&Ti(cs),{promise:new Promise(n=>{Ft.add(e={c:t,f:n})}),abort(){Ft.delete(e)}}}function H(t,e){t.appendChild(e)}function ps(t){if(!t)return document;const e=t.getRootNode?t.getRootNode():t.ownerDocument;return e&&e.host?e:t.ownerDocument}function Ru(t){const e=K("style");return e.textContent="/* empty */",vu(ps(t),e),e.sheet}function vu(t,e){return H(t.head||t,e),e.sheet}function D(t,e,n){t.insertBefore(e,n||null)}function F(t){t.parentNode&&t.parentNode.removeChild(t)}function K(t){return document.createElement(t)}function ui(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function Ke(t){return document.createTextNode(t)}function V(){return Ke(" ")}function ve(){return Ke("")}function ue(t,e,n,i){return t.addEventListener(e,n,i),()=>t.removeEventListener(e,n,i)}function Zi(t){return function(e){return e.stopPropagation(),t.call(this,e)}}function $(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}const Cu=["width","height"];function Lu(t,e){const n=Object.getOwnPropertyDescriptors(t.__proto__);for(const i in e)e[i]==null?t.removeAttribute(i):i==="style"?t.style.cssText=e[i]:i==="__value"?t.value=t[i]=e[i]:n[i]&&n[i].set&&Cu.indexOf(i)===-1?t[i]=e[i]:$(t,i,e[i])}function Ou(t,e){Object.keys(e).forEach(n=>{Nu(t,n,e[n])})}function Nu(t,e,n){e in t?t[e]=typeof t[e]=="boolean"&&n===""?!0:n:$(t,e,n)}function eo(t){return/-/.test(t)?Ou:Lu}function to(t,e,n){t.setAttributeNS("http://www.w3.org/1999/xlink",e,n)}function ci(t){return t===""?null:+t}function Iu(t){return Array.from(t.childNodes)}function Bt(t,e){e=""+e,t.data!==e&&(t.data=e)}function Pe(t,e){t.value=e??""}function nt(t,e,n,i){n==null?t.style.removeProperty(e):t.style.setProperty(e,n,i?"important":"")}function no(t,e,n){for(let i=0;i>>0}function Pu(t,e){const n={stylesheet:Ru(e),rules:{}};return Ln.set(t,n),n}function ds(t,e,n,i,o,r,a,s=0){const u=16.666/i;let f=`{ +`;for(let k=0;k<=1;k+=u){const W=e+(n-e)*r(k);f+=k*100+`%{${a(W,1-W)}} +`}const p=f+`100% {${a(n,1-n)}} +}`,m=`__svelte_${Fu(p)}_${s}`,_=ps(t),{stylesheet:b,rules:g}=Ln.get(_)||Pu(_,t);g[m]||(g[m]=!0,b.insertRule(`@keyframes ${m} ${p}`,b.cssRules.length));const y=t.style.animation||"";return t.style.animation=`${y?`${y}, `:""}${m} ${i}ms linear ${o}ms 1 both`,On+=1,m}function fi(t,e){const n=(t.style.animation||"").split(", "),i=n.filter(e?r=>r.indexOf(e)<0:r=>r.indexOf("__svelte")===-1),o=n.length-i.length;o&&(t.style.animation=i.join(", "),On-=o,On||Du())}function Du(){Ti(()=>{On||(Ln.forEach(t=>{const{ownerNode:e}=t.stylesheet;e&&F(e)}),Ln.clear())})}let Yt;function Vt(t){Yt=t}function Ei(){if(!Yt)throw new Error("Function called outside component initialization");return Yt}function Uu(t){Ei().$$.on_mount.push(t)}function Wu(t){Ei().$$.on_destroy.push(t)}function jn(){const t=Ei();return(e,n,{cancelable:i=!1}={})=>{const o=t.$$.callbacks[e];if(o){const r=hs(e,n,{cancelable:i});return o.slice().forEach(a=>{a.call(t,r)}),!r.defaultPrevented}return!0}}function io(t,e){const n=t.$$.callbacks[e.type];n&&n.slice().forEach(i=>i.call(this,e))}const Mt=[],Jt=[];let Pt=[];const oo=[],ju=Promise.resolve();let pi=!1;function qu(){pi||(pi=!0,ju.then(ms))}function At(t){Pt.push(t)}const Xn=new Set;let Rt=0;function ms(){if(Rt!==0)return;const t=Yt;do{try{for(;Rtt.indexOf(i)===-1?e.push(i):n.push(i)),n.forEach(i=>i()),Pt=e}let Kt;function gs(){return Kt||(Kt=Promise.resolve(),Kt.then(()=>{Kt=null})),Kt}function Nn(t,e,n){t.dispatchEvent(hs(`${e?"intro":"outro"}${n}`))}const $n=new Set;let Et;function ge(){Et={r:0,c:[],p:Et}}function be(){Et.r||Ce(Et.c),Et=Et.p}function T(t,e){t&&t.i&&($n.delete(t),t.i(e))}function E(t,e,n,i){if(t&&t.o){if($n.has(t))return;$n.add(t),Et.c.push(()=>{$n.delete(t),i&&(n&&t.d(1),i())}),t.o(e)}else i&&i()}const bs={duration:0};function xu(t,e,n){const i={direction:"in"};let o=e(t,n,i),r=!1,a,s,u=0;function f(){a&&fi(t,a)}function p(){const{delay:_=0,duration:b=300,easing:g=ki,tick:y=oe,css:k}=o||bs;k&&(a=ds(t,0,1,b,_,g,k,u++)),y(0,1);const W=us()+_,S=W+b;s&&s.abort(),r=!0,At(()=>Nn(t,!0,"start")),s=fs(ee=>{if(r){if(ee>=S)return y(1,0),Nn(t,!0,"end"),f(),r=!1;if(ee>=W){const C=g((ee-W)/b);y(C,1-C)}}return r})}let m=!1;return{start(){m||(m=!0,fi(t),Wn(o)?(o=o(i),gs().then(p)):p())},invalidate(){m=!1},end(){r&&(f(),r=!1)}}}function Vu(t,e,n){const i={direction:"out"};let o=e(t,n,i),r=!0,a;const s=Et;s.r+=1;let u;function f(){const{delay:p=0,duration:m=300,easing:_=ki,tick:b=oe,css:g}=o||bs;g&&(a=ds(t,1,0,m,p,_,g));const y=us()+p,k=y+m;At(()=>Nn(t,!1,"start")),"inert"in t&&(u=t.inert,t.inert=!0),fs(W=>{if(r){if(W>=k)return b(0,1),Nn(t,!1,"end"),--s.r||Ce(s.c),!1;if(W>=y){const S=_((W-y)/m);b(1-S,S)}}return r})}return Wn(o)?gs().then(()=>{o=o(i),f()}):f(),{end(p){p&&"inert"in t&&(t.inert=u),p&&o.tick&&o.tick(1,0),r&&(a&&fi(t,a),r=!1)}}}function De(t){return(t==null?void 0:t.length)!==void 0?t:Array.from(t)}function zu(t,e){t.d(1),e.delete(t.key)}function jt(t,e){E(t,1,1,()=>{e.delete(t.key)})}function $t(t,e,n,i,o,r,a,s,u,f,p,m){let _=t.length,b=r.length,g=_;const y={};for(;g--;)y[t[g].key]=g;const k=[],W=new Map,S=new Map,ee=[];for(g=b;g--;){const ne=m(o,r,g),Q=n(ne);let q=a.get(Q);q?i&&ee.push(()=>q.p(ne,e)):(q=f(Q,ne),q.c()),W.set(Q,k[g]=q),Q in y&&S.set(Q,Math.abs(g-y[Q]))}const C=new Set,J=new Set;function z(ne){T(ne,1),ne.m(s,p),a.set(ne.key,ne),p=ne.first,b--}for(;_&&b;){const ne=k[b-1],Q=t[_-1],q=ne.key,Le=Q.key;ne===Q?(p=ne.first,_--,b--):W.has(Le)?!a.has(q)||C.has(q)?z(ne):J.has(Le)?_--:S.get(q)>S.get(Le)?(J.add(q),z(ne)):(C.add(Le),_--):(u(Q,a),_--)}for(;_--;){const ne=t[_];W.has(ne.key)||u(ne,a)}for(;b;)z(k[b-1]);return Ce(ee),k}function Bi(t,e){const n={},i={},o={$$scope:1};let r=t.length;for(;r--;){const a=t[r],s=e[r];if(s){for(const u in a)u in s||(i[u]=1);for(const u in s)o[u]||(n[u]=s[u],o[u]=1);t[r]=s}else for(const u in a)o[u]=1}for(const a in i)a in n||(n[a]=void 0);return n}function _s(t){return typeof t=="object"&&t!==null?t:{}}function P(t){t&&t.c()}function I(t,e,n){const{fragment:i,after_update:o}=t.$$;i&&i.m(e,n),At(()=>{const r=t.$$.on_mount.map(ss).filter(Wn);t.$$.on_destroy?t.$$.on_destroy.push(...r):Ce(r),t.$$.on_mount=[]}),o.forEach(At)}function M(t,e){const n=t.$$;n.fragment!==null&&(Ku(n.after_update),Ce(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function Gu(t,e){t.$$.dirty[0]===-1&&(Mt.push(t),qu(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{const g=b.length?b[0]:_;return f.ctx&&o(f.ctx[m],f.ctx[m]=g)&&(!f.skip_bound&&f.bound[m]&&f.bound[m](g),p&&Gu(t,m)),_}):[],f.update(),p=!0,Ce(f.before_update),f.fragment=i?i(f.ctx):!1,e.target){if(e.hydrate){const m=Iu(e.target);f.fragment&&f.fragment.l(m),m.forEach(F)}else f.fragment&&f.fragment.c();e.intro&&T(t.$$.fragment),I(t,e.target,e.anchor),ms()}Vt(u)}class Ne{constructor(){le(this,"$$");le(this,"$$set")}$destroy(){M(this,1),this.$destroy=oe}$on(e,n){if(!Wn(n))return oe;const i=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return i.push(n),()=>{const o=i.indexOf(n);o!==-1&&i.splice(o,1)}}$set(e){this.$$set&&!Au(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const Yu="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(Yu);function Ju(t){let e,n;return{c(){e=ui("svg"),n=ui("use"),to(n,"xlink:href",t[0]),$(e,"style",t[3]),$(e,"data-id",t[1]),$(e,"class",t[2]),j(e,"popover__block",et.id.test(t[1]))},m(i,o){D(i,e,o),H(e,n)},p(i,[o]){o&1&&to(n,"xlink:href",i[0]),o&8&&$(e,"style",i[3]),o&2&&$(e,"data-id",i[1]),o&4&&$(e,"class",i[2]),o&6&&j(e,"popover__block",et.id.test(i[1]))},i:oe,o:oe,d(i){i&&F(e)}}}function Xu(t,e,n){let{icon:i}=e,{id:o=""}=e,{className:r=""}=e,{style:a=""}=e;return t.$$set=s=>{"icon"in s&&n(0,i=s.icon),"id"in s&&n(1,o=s.id),"className"in s&&n(2,r=s.className),"style"in s&&n(3,a=s.style)},[i,o,r,a]}class Je extends Ne{constructor(e){super(),Oe(this,e,Xu,Ju,$e,{icon:0,id:1,className:2,style:3})}}const Qu=t=>({focus:t&1}),ro=t=>({focus:t[0]});function so(t,e,n){const i=t.slice();return i[13]=e[n],i}function ao(t){let e,n,i,o,r,a,s;return n=new Je({props:{icon:"#iconSearch",className:"b3-form__icon-icon"}}),{c(){e=K("div"),P(n.$$.fragment),i=V(),o=K("input"),$(o,"placeholder",t[4]),$(o,"class","b3-text-field fn__block b3-form__icon-input"),$(e,"class","b3-form__icon")},m(u,f){D(u,e,f),I(n,e,null),H(e,i),H(e,o),Pe(o,t[1]),r=!0,a||(s=[ue(o,"input",t[9]),ue(o,"change",t[5])],a=!0)},p(u,f){(!r||f&16)&&$(o,"placeholder",u[4]),f&2&&o.value!==u[1]&&Pe(o,u[1])},i(u){r||(T(n.$$.fragment,u),r=!0)},o(u){E(n.$$.fragment,u),r=!1},d(u){u&&F(e),M(n),a=!1,Ce(s)}}}function lo(t,e){let n,i,o,r,a=e[13].text+"",s,u,f,p,m;i=new Je({props:{icon:e[13].icon,className:"b3-list-item__graphic"}});function _(){return e[10](e[13])}function b(){return e[11](e[13])}return{key:t,first:null,c(){n=K("li"),P(i.$$.fragment),o=V(),r=K("span"),s=V(),$(r,"class","b3-list-item__text svelte-15drd7h"),$(n,"role","button"),$(n,"data-name",u=e[13].name),$(n,"class","b3-list-item"),j(n,"b3-list-item--focus",e[13].key===e[0]),this.first=n},m(g,y){D(g,n,y),I(i,n,null),H(n,o),H(n,r),r.innerHTML=a,H(n,s),f=!0,p||(m=[ue(n,"click",_),ue(n,"keyup",b)],p=!0)},p(g,y){e=g;const k={};y&4&&(k.icon=e[13].icon),i.$set(k),(!f||y&4)&&a!==(a=e[13].text+"")&&(r.innerHTML=a),(!f||y&4&&u!==(u=e[13].name))&&$(n,"data-name",u),(!f||y&5)&&j(n,"b3-list-item--focus",e[13].key===e[0])},i(g){f||(T(i.$$.fragment,g),f=!0)},o(g){E(i.$$.fragment,g),f=!1},d(g){g&&F(n),M(i),p=!1,Ce(m)}}}function Zu(t){let e;return{c(){e=Ke("Container")},m(n,i){D(n,e,i)},d(n){n&&F(e)}}}function ec(t){let e,n,i,o=[],r=new Map,a,s,u,f=t[3]&&ao(t),p=De(t[2]);const m=y=>y[13].key;for(let y=0;y{f=null}),be()),k&69&&(p=De(y[2]),ge(),o=$t(o,k,m,1,y,p,r,n,jt,lo,null,so),be()),b&&b.p&&(!u||k&129)&&Se(b,_,y,y[7],u?Be(_,y[7],k,Qu):Ae(y[7]),ro)},i(y){if(!u){T(f);for(let k=0;k_(k.key),y=k=>_(k.key);return t.$$set=k=>{"panels"in k&&n(2,r=k.panels),"focus"in k&&n(0,a=k.focus),"searchEnable"in k&&n(3,s=k.searchEnable),"searchPlaceholder"in k&&n(4,u=k.searchPlaceholder),"searchValue"in k&&n(1,f=k.searchValue),"$$scope"in k&&n(7,o=k.$$scope)},[a,f,r,s,u,m,_,o,i,b,g,y]}class nc extends Ne{constructor(e){super(),Oe(this,e,tc,ec,$e,{panels:2,focus:0,searchEnable:3,searchPlaceholder:4,searchValue:1})}}function ic(t){let e,n;const i=t[4].default,o=Ee(i,t,t[3],null);return{c(){e=K("div"),o&&o.c(),$(e,"data-name",t[2]),$(e,"class","config__tab-container"),j(e,"fn__none",!t[0]),j(e,"config__tab-container--top",t[1])},m(r,a){D(r,e,a),o&&o.m(e,null),n=!0},p(r,[a]){o&&o.p&&(!n||a&8)&&Se(o,i,r,r[3],n?Be(i,r[3],a,null):Ae(r[3]),null),(!n||a&4)&&$(e,"data-name",r[2]),(!n||a&1)&&j(e,"fn__none",!r[0]),(!n||a&2)&&j(e,"config__tab-container--top",r[1])},i(r){n||(T(o,r),n=!0)},o(r){E(o,r),n=!1},d(r){r&&F(e),o&&o.d(r)}}}function oc(t,e,n){let{$$slots:i={},$$scope:o}=e,{display:r=!0}=e,{top:a=!0}=e,{name:s=""}=e;return t.$$set=u=>{"display"in u&&n(0,r=u.display),"top"in u&&n(1,a=u.top),"name"in u&&n(2,s=u.name),"$$scope"in u&&n(3,o=u.$$scope)},[r,a,s,o,i]}class Qn extends Ne{constructor(e){super(),Oe(this,e,oc,ic,$e,{display:0,top:1,name:2})}}const rc=t=>({}),uo=t=>({}),sc=t=>({}),co=t=>({});function fo(t){let e,n;const i=t[7].icon,o=Ee(i,t,t[6],co);return{c(){e=K("span"),o&&o.c(),$(e,"class","item__icon")},m(r,a){D(r,e,a),o&&o.m(e,null),n=!0},p(r,a){o&&o.p&&(!n||a&64)&&Se(o,i,r,r[6],n?Be(i,r[6],a,sc):Ae(r[6]),co)},i(r){n||(T(o,r),n=!0)},o(r){E(o,r),n=!1},d(r){r&&F(e),o&&o.d(r)}}}function ac(t){let e;return{c(){e=Ke("text")},m(n,i){D(n,e,i)},d(n){n&&F(e)}}}function lc(t){let e,n,i,o,r,a,s,u,f,p,m=t[0]&&t[4].icon&&fo(t);const _=t[7].text,b=Ee(_,t,t[6],uo),g=b||ac();return{c(){e=K("div"),n=K("span"),i=V(),m&&m.c(),o=V(),r=K("span"),g&&g.c(),a=V(),s=K("span"),$(n,"class","fn__flex-1"),$(r,"class","item__text"),$(s,"class","fn__flex-1"),$(e,"role","button"),$(e,"data-type",t[1]),$(e,"class","item item--full"),j(e,"item--focus",t[2])},m(y,k){D(y,e,k),H(e,n),H(e,i),m&&m.m(e,null),H(e,o),H(e,r),g&&g.m(r,null),H(e,a),H(e,s),u=!0,f||(p=ue(e,"click",t[3]),f=!0)},p(y,[k]){y[0]&&y[4].icon?m?(m.p(y,k),k&17&&T(m,1)):(m=fo(y),m.c(),T(m,1),m.m(e,o)):m&&(ge(),E(m,1,1,()=>{m=null}),be()),b&&b.p&&(!u||k&64)&&Se(b,_,y,y[6],u?Be(_,y[6],k,rc):Ae(y[6]),uo),(!u||k&2)&&$(e,"data-type",y[1]),(!u||k&4)&&j(e,"item--focus",y[2])},i(y){u||(T(m),T(g,y),u=!0)},o(y){E(m),E(g,y),u=!1},d(y){y&&F(e),m&&m.d(),g&&g.d(y),f=!1,p()}}}function uc(t,e,n){let{$$slots:i={},$$scope:o}=e;const r=$u(i);let{key:a}=e,{icon:s}=e,{name:u=""}=e,{focus:f=!1}=e;const p=jn();function m(){f||p("changed",{key:a})}return t.$$set=_=>{"key"in _&&n(5,a=_.key),"icon"in _&&n(0,s=_.icon),"name"in _&&n(1,u=_.name),"focus"in _&&n(2,f=_.focus),"$$scope"in _&&n(6,o=_.$$scope)},[s,u,f,m,r,a,o,i]}let cc=class extends Ne{constructor(e){super(),Oe(this,e,uc,lc,$e,{key:5,icon:0,name:1,focus:2})}};const fc=t=>({focus:t&1}),po=t=>({focus:t[0]});function ho(t,e,n){const i=t.slice();return i[5]=e[n],i}function pc(t){let e,n=t[5].icon+"",i;return{c(){e=new Zt(!1),i=ve(),e.a=i},m(o,r){e.m(n,o,r),D(o,i,r)},p(o,r){r&2&&n!==(n=o[5].icon+"")&&e.p(n)},i:oe,o:oe,d(o){o&&(F(i),e.d())}}}function hc(t){let e,n;return e=new Je({props:{icon:t[5].icon}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&2&&(r.icon=i[5].icon),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function dc(t){let e,n,i,o,r,a;const s=[hc,pc],u=[];function f(p,m){var _;return m&2&&(n=null),n==null&&(n=!!((_=p[5].icon)!=null&&_.startsWith("#"))),n?0:p[5].icon?1:-1}return~(i=f(t,-1))&&(o=u[i]=s[i](t)),{c(){e=K("span"),o&&o.c(),r=V(),$(e,"slot","icon")},m(p,m){D(p,e,m),~i&&u[i].m(e,null),H(e,r),a=!0},p(p,m){let _=i;i=f(p,m),i===_?~i&&u[i].p(p,m):(o&&(ge(),E(u[_],1,1,()=>{u[_]=null}),be()),~i?(o=u[i],o?o.p(p,m):(o=u[i]=s[i](p),o.c()),T(o,1),o.m(e,r)):o=null)},i(p){a||(T(o),a=!0)},o(p){E(o),a=!1},d(p){p&&F(e),~i&&u[i].d()}}}function mc(t){let e,n,i=t[5].text+"",o;return{c(){e=K("span"),n=new Zt(!1),o=V(),n.a=o,$(e,"slot","text")},m(r,a){D(r,e,a),n.m(i,e),H(e,o)},p(r,a){a&2&&i!==(i=r[5].text+"")&&n.p(i)},d(r){r&&F(e)}}}function mo(t,e){let n,i,o;return i=new cc({props:{key:e[5].key,icon:!!e[5].icon,name:e[5].name,focus:e[5].key===e[0],$$slots:{text:[mc],icon:[dc]},$$scope:{ctx:e}}}),i.$on("changed",e[2]),{key:t,first:null,c(){n=ve(),P(i.$$.fragment),this.first=n},m(r,a){D(r,n,a),I(i,r,a),o=!0},p(r,a){e=r;const s={};a&2&&(s.key=e[5].key),a&2&&(s.icon=!!e[5].icon),a&2&&(s.name=e[5].name),a&3&&(s.focus=e[5].key===e[0]),a&18&&(s.$$scope={dirty:a,ctx:e}),i.$set(s)},i(r){o||(T(i.$$.fragment,r),o=!0)},o(r){E(i.$$.fragment,r),o=!1},d(r){r&&F(n),M(i,r)}}}function gc(t){let e;return{c(){e=Ke("Container")},m(n,i){D(n,e,i)},d(n){n&&F(e)}}}function bc(t){let e,n,i=[],o=new Map,r,a,s,u=De(t[1]);const f=b=>b[5].key;for(let b=0;b{"tabs"in u&&n(1,r=u.tabs),"focus"in u&&n(0,a=u.focus),"$$scope"in u&&n(4,o=u.$$scope)},[a,r,s,i,o]}class ys extends Ne{constructor(e){super(),Oe(this,e,_c,bc,$e,{tabs:1,focus:0})}}const yc=t=>({}),go=t=>({}),wc=t=>({}),bo=t=>({}),kc=t=>({}),_o=t=>({}),Tc=t=>({}),yo=t=>({});function Ec(t){let e,n;return{c(){e=new Zt(!1),n=ve(),e.a=n},m(i,o){e.m(t[0],i,o),D(i,n,o)},p(i,o){o&1&&e.p(i[0])},d(i){i&&(F(n),e.d())}}}function Bc(t){let e,n;return{c(){e=new Zt(!1),n=ve(),e.a=n},m(i,o){e.m(t[1],i,o),D(i,n,o)},p(i,o){o&2&&e.p(i[1])},d(i){i&&(F(n),e.d())}}}function wo(t){let e,n,i;const o=t[4].input,r=Ee(o,t,t[3],bo);return{c(){e=K("div"),n=V(),r&&r.c(),$(e,"class","fn__hr")},m(a,s){D(a,e,s),D(a,n,s),r&&r.m(a,s),i=!0},p(a,s){r&&r.p&&(!i||s&8)&&Se(r,o,a,a[3],i?Be(o,a[3],s,wc):Ae(a[3]),bo)},i(a){i||(T(r,a),i=!0)},o(a){E(r,a),i=!1},d(a){a&&(F(e),F(n)),r&&r.d(a)}}}function ko(t){let e,n,i;const o=t[4].input,r=Ee(o,t,t[3],go);return{c(){e=K("span"),n=V(),r&&r.c(),$(e,"class","fn__space")},m(a,s){D(a,e,s),D(a,n,s),r&&r.m(a,s),i=!0},p(a,s){r&&r.p&&(!i||s&8)&&Se(r,o,a,a[3],i?Be(o,a[3],s,yc):Ae(a[3]),go)},i(a){i||(T(r,a),i=!0)},o(a){E(r,a),i=!1},d(a){a&&(F(e),F(n)),r&&r.d(a)}}}function Sc(t){let e,n,i,o,r,a,s;const u=t[4].title,f=Ee(u,t,t[3],yo),p=f||Ec(t),m=t[4].text,_=Ee(m,t,t[3],_o),b=_||Bc(t);let g=t[2]&&wo(t),y=!t[2]&&ko(t);return{c(){e=K("label"),n=K("div"),p&&p.c(),i=V(),o=K("div"),b&&b.c(),r=V(),g&&g.c(),a=V(),y&&y.c(),$(o,"class","b3-label__text"),$(n,"class","fn__flex-1 svelte-2m76cy"),j(n,"visible",t[2]),$(e,"class","fn__flex b3-label")},m(k,W){D(k,e,W),H(e,n),p&&p.m(n,null),H(n,i),H(n,o),b&&b.m(o,null),H(n,r),g&&g.m(n,null),H(e,a),y&&y.m(e,null),s=!0},p(k,[W]){f?f.p&&(!s||W&8)&&Se(f,u,k,k[3],s?Be(u,k[3],W,Tc):Ae(k[3]),yo):p&&p.p&&(!s||W&1)&&p.p(k,s?W:-1),_?_.p&&(!s||W&8)&&Se(_,m,k,k[3],s?Be(m,k[3],W,kc):Ae(k[3]),_o):b&&b.p&&(!s||W&2)&&b.p(k,s?W:-1),k[2]?g?(g.p(k,W),W&4&&T(g,1)):(g=wo(k),g.c(),T(g,1),g.m(n,null)):g&&(ge(),E(g,1,1,()=>{g=null}),be()),(!s||W&4)&&j(n,"visible",k[2]),k[2]?y&&(ge(),E(y,1,1,()=>{y=null}),be()):y?(y.p(k,W),W&4&&T(y,1)):(y=ko(k),y.c(),T(y,1),y.m(e,null))},i(k){s||(T(p,k),T(b,k),T(g),T(y),s=!0)},o(k){E(p,k),E(b,k),E(g),E(y),s=!1},d(k){k&&F(e),p&&p.d(k),b&&b.d(k),g&&g.d(),y&&y.d()}}}function Ac(t,e,n){let{$$slots:i={},$$scope:o}=e,{title:r=""}=e,{text:a=""}=e,{block:s=!1}=e;return t.$$set=u=>{"title"in u&&n(0,r=u.title),"text"in u&&n(1,a=u.text),"block"in u&&n(2,s=u.block),"$$scope"in u&&n(3,o=u.$$scope)},[r,a,s,o,i]}let Te=class extends Ne{constructor(e){super(),Oe(this,e,Ac,Sc,$e,{title:0,text:1,block:2})}};var te=(t=>(t[t.checkbox=0]="checkbox",t[t.text=1]="text",t[t.number=2]="number",t[t.slider=3]="slider",t[t.button=4]="button",t[t.select=5]="select",t[t.textarea=6]="textarea",t))(te||{});function To(t,e,n){const i=t.slice();return i[19]=e[n],i}function $c(t){let e,n,i;return{c(){e=K("textarea"),e.disabled=t[2],$(e,"class","b3-text-field"),$(e,"placeholder",t[5]),j(e,"fn__block",t[3]),j(e,"fn__size200",!t[3]&&t[4]),nt(e,"height",t[8]>0?`${t[8]}px`:void 0)},m(o,r){D(o,e,r),Pe(e,t[0]),n||(i=[ue(e,"input",t[17]),ue(e,"change",t[10])],n=!0)},p(o,r){r&4&&(e.disabled=o[2]),r&32&&$(e,"placeholder",o[5]),r&65&&Pe(e,o[0]),r&8&&j(e,"fn__block",o[3]),r&24&&j(e,"fn__size200",!o[3]&&o[4]),r&256&&nt(e,"height",o[8]>0?`${o[8]}px`:void 0)},d(o){o&&F(e),n=!1,Ce(i)}}}function Rc(t){let e,n=[],i=new Map,o,r,a=De(t[6]);const s=u=>u[19].key;for(let u=0;ut[16].call(e)),j(e,"fn__block",t[3]),j(e,"fn__size200",!t[3]&&t[4]),j(e,"fn__flex-center",!t[3])},m(u,f){D(u,e,f);for(let p=0;p{"type"in z&&n(1,i=z.type),"settingKey"in z&&n(11,o=z.settingKey),"settingValue"in z&&n(0,r=z.settingValue),"disabled"in z&&n(2,a=z.disabled),"block"in z&&n(3,s=z.block),"normal"in z&&n(4,u=z.normal),"placeholder"in z&&n(5,f=z.placeholder),"options"in z&&n(6,p=z.options),"limits"in z&&n(7,m=z.limits),"height"in z&&n(8,_=z.height)},[r,i,a,s,u,f,p,m,_,g,y,o,k,W,S,ee,C,J]}class ae extends Ne{constructor(e){super(),Oe(this,e,Mc,Ic,$e,{type:1,settingKey:11,settingValue:0,disabled:2,block:3,normal:4,placeholder:5,options:6,limits:7,height:8})}}function Fc(t){let e,n,i,o,r;const a=t[2].default,s=Ee(a,t,t[1],null);return{c(){e=K("div"),n=new Zt(!1),i=V(),o=K("div"),s&&s.c(),n.a=i,$(o,"class","config-query"),$(e,"class","b3-label")},m(u,f){D(u,e,f),n.m(t[0],e),H(e,i),H(e,o),s&&s.m(o,null),r=!0},p(u,[f]){(!r||f&1)&&n.p(u[0]),s&&s.p&&(!r||f&2)&&Se(s,a,u,u[1],r?Be(a,u[1],f,null):Ae(u[1]),null)},i(u){r||(T(s,u),r=!0)},o(u){E(s,u),r=!1},d(u){u&&F(e),s&&s.d(u)}}}function Pc(t,e,n){let{$$slots:i={},$$scope:o}=e,{title:r}=e;return t.$$set=a=>{"title"in a&&n(0,r=a.title),"$$scope"in a&&n(1,o=a.$$scope)},[r,o,i]}class Si extends Ne{constructor(e){super(),Oe(this,e,Pc,Fc,$e,{title:0})}}const Dc=t=>({}),Bo=t=>({}),Uc=t=>({}),So=t=>({}),Wc=t=>({}),Ao=t=>({});function jc(t){let e,n,i,o,r,a,s,u,f;const p=t[3].icon,m=Ee(p,t,t[2],Ao),_=t[3].title,b=Ee(_,t,t[2],So),g=t[3].input,y=Ee(g,t,t[2],Bo);return{c(){e=K("label"),m&&m.c(),n=V(),i=K("span"),o=V(),r=K("div"),b&&b.c(),a=V(),s=K("span"),u=V(),y&&y.c(),$(i,"class","fn__space"),$(r,"class","fn__flex-1"),$(s,"class","fn__space"),nt(e,"min-width",t[0]),nt(e,"margin-right",t[1]),$(e,"class","fn__flex svelte-1l7osn9")},m(k,W){D(k,e,W),m&&m.m(e,null),H(e,n),H(e,i),H(e,o),H(e,r),b&&b.m(r,null),H(e,a),H(e,s),H(e,u),y&&y.m(e,null),f=!0},p(k,[W]){m&&m.p&&(!f||W&4)&&Se(m,p,k,k[2],f?Be(p,k[2],W,Wc):Ae(k[2]),Ao),b&&b.p&&(!f||W&4)&&Se(b,_,k,k[2],f?Be(_,k[2],W,Uc):Ae(k[2]),So),y&&y.p&&(!f||W&4)&&Se(y,g,k,k[2],f?Be(g,k[2],W,Dc):Ae(k[2]),Bo),(!f||W&1)&&nt(e,"min-width",k[0]),(!f||W&2)&&nt(e,"margin-right",k[1])},i(k){f||(T(m,k),T(b,k),T(y,k),f=!0)},o(k){E(m,k),E(b,k),E(y,k),f=!1},d(k){k&&F(e),m&&m.d(k),b&&b.d(k),y&&y.d(k)}}}function qc(t,e,n){let{$$slots:i={},$$scope:o}=e,{minWidth:r="24em"}=e,{marginRight:a="2em"}=e;return t.$$set=s=>{"minWidth"in s&&n(0,r=s.minWidth),"marginRight"in s&&n(1,a=s.marginRight),"$$scope"in s&&n(2,o=s.$$scope)},[r,a,o,i]}class St extends Ne{constructor(e){super(),Oe(this,e,qc,jc,$e,{minWidth:0,marginRight:1})}}var st=(t=>(t[t.Left=0]="Left",t[t.Middle=1]="Middle",t[t.Right=2]="Right",t[t.Back=3]="Back",t[t.Forward=4]="Forward",t))(st||{}),me=(t=>(t.click="click",t.dblclick="dblclick",t.contextmenu="contextmenu",t.mousedown="mousedown",t.mouseup="mouseup",t.mouseenter="mouseenter",t.mouseleave="mouseleave",t.mousewheel="mousewheel",t.mouseover="mouseover",t.mousemove="mousemove",t.mouseout="mouseout",t))(me||{});function $o(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[xc],title:[Kc],default:[Hc]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4195329&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Hc(t){let e,n;return e=new Je({props:{icon:"#iconKeymap",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Kc(t){let e;return{c(){e=K("kbd"),e.textContent="Ctrl",$(e,"slot","title")},m(n,i){D(n,e,i)},p:oe,d(n){n&&F(e)}}}function xc(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[10],type:te.checkbox,settingKey:"ctrlKey",settingValue:t[0].ctrlKey}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&1024&&(r.disabled=i[10]),o&1&&(r.settingValue=i[0].ctrlKey),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Ro(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[Gc],title:[zc],default:[Vc]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4196353&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Vc(t){let e,n;return e=new Je({props:{icon:"#iconKeymap",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function zc(t){let e;return{c(){e=K("kbd"),e.textContent="Shift",$(e,"slot","title")},m(n,i){D(n,e,i)},p:oe,d(n){n&&F(e)}}}function Gc(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[11],type:te.checkbox,settingKey:"shiftKey",settingValue:t[0].shiftKey}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&2048&&(r.disabled=i[11]),o&1&&(r.settingValue=i[0].shiftKey),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function vo(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[Xc],title:[Jc],default:[Yc]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4198401&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Yc(t){let e,n;return e=new Je({props:{icon:"#iconKeymap",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Jc(t){let e;return{c(){e=K("kbd"),e.textContent="Alt",$(e,"slot","title")},m(n,i){D(n,e,i)},p:oe,d(n){n&&F(e)}}}function Xc(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[12],type:te.checkbox,settingKey:"altKey",settingValue:t[0].altKey}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4096&&(r.disabled=i[12]),o&1&&(r.settingValue=i[0].altKey),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Co(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[ef],title:[Zc],default:[Qc]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4202497&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Qc(t){let e,n;return e=new Je({props:{icon:"#iconKeymap",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Zc(t){let e;return{c(){e=K("kbd"),e.textContent="Meta",$(e,"slot","title")},m(n,i){D(n,e,i)},p:oe,d(n){n&&F(e)}}}function ef(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[13],type:te.checkbox,settingKey:"metaKey",settingValue:t[0].metaKey}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&8192&&(r.disabled=i[13]),o&1&&(r.settingValue=i[0].metaKey),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Lo(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[of],title:[nf],default:[tf]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4538369&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function tf(t){let e,n;return e=new Je({props:{icon:"#iconSelectText",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function nf(t){let e,n;return{c(){e=K("span"),n=Ke(t[16]),$(e,"slot","title")},m(i,o){D(i,e,o),H(e,n)},p(i,o){o&65536&&Bt(n,i[16])},d(i){i&&F(e)}}}function of(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[14],type:te.select,settingKey:"button",settingValue:t[0].button,options:t[18]}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&16384&&(r.disabled=i[14]),o&1&&(r.settingValue=i[0].button),o&262144&&(r.options=i[18]),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Oo(t){let e,n;return e=new St({props:{minWidth:t[2],marginRight:t[3],$$slots:{input:[af],title:[sf],default:[rf]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.minWidth=i[2]),o&8&&(r.marginRight=i[3]),o&4882433&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function rf(t){let e,n;return e=new Je({props:{icon:"#iconSelectText",className:"svg"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function sf(t){let e,n;return{c(){e=K("span"),n=Ke(t[17]),$(e,"slot","title")},m(i,o){D(i,e,o),H(e,n)},p(i,o){o&131072&&Bt(n,i[17])},d(i){i&&F(e)}}}function af(t){let e,n;return e=new ae({props:{slot:"input",normal:!1,disabled:t[15],type:te.select,settingKey:"type",settingValue:t[0].type,options:t[19]}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&32768&&(r.disabled=i[15]),o&1&&(r.settingValue=i[0].type),o&524288&&(r.options=i[19]),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function lf(t){let e,n,i,o,r,a,s,u=t[4]&&$o(t),f=t[5]&&Ro(t),p=t[6]&&vo(t),m=t[7]&&Co(t),_=t[8]&&Lo(t),b=t[9]&&Oo(t);return{c(){u&&u.c(),e=V(),f&&f.c(),n=V(),p&&p.c(),i=V(),m&&m.c(),o=V(),_&&_.c(),r=V(),b&&b.c(),a=ve()},m(g,y){u&&u.m(g,y),D(g,e,y),f&&f.m(g,y),D(g,n,y),p&&p.m(g,y),D(g,i,y),m&&m.m(g,y),D(g,o,y),_&&_.m(g,y),D(g,r,y),b&&b.m(g,y),D(g,a,y),s=!0},p(g,y){g[4]?u?(u.p(g,y),y&16&&T(u,1)):(u=$o(g),u.c(),T(u,1),u.m(e.parentNode,e)):u&&(ge(),E(u,1,1,()=>{u=null}),be()),g[5]?f?(f.p(g,y),y&32&&T(f,1)):(f=Ro(g),f.c(),T(f,1),f.m(n.parentNode,n)):f&&(ge(),E(f,1,1,()=>{f=null}),be()),g[6]?p?(p.p(g,y),y&64&&T(p,1)):(p=vo(g),p.c(),T(p,1),p.m(i.parentNode,i)):p&&(ge(),E(p,1,1,()=>{p=null}),be()),g[7]?m?(m.p(g,y),y&128&&T(m,1)):(m=Co(g),m.c(),T(m,1),m.m(o.parentNode,o)):m&&(ge(),E(m,1,1,()=>{m=null}),be()),g[8]?_?(_.p(g,y),y&256&&T(_,1)):(_=Lo(g),_.c(),T(_,1),_.m(r.parentNode,r)):_&&(ge(),E(_,1,1,()=>{_=null}),be()),g[9]?b?(b.p(g,y),y&512&&T(b,1)):(b=Oo(g),b.c(),T(b,1),b.m(a.parentNode,a)):b&&(ge(),E(b,1,1,()=>{b=null}),be())},i(g){s||(T(u),T(f),T(p),T(m),T(_),T(b),s=!0)},o(g){E(u),E(f),E(p),E(m),E(_),E(b),s=!1},d(g){g&&(F(e),F(n),F(i),F(o),F(r),F(a)),u&&u.d(g),f&&f.d(g),p&&p.d(g),m&&m.d(g),_&&_.d(g),b&&b.d(g)}}}function uf(t){let e,n;return e=new Si({props:{title:t[1],$$slots:{default:[lf]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,[o]){const r={};o&2&&(r.title=i[1]),o&5242877&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function cf(t,e,n){let{title:i}=e,{shortcut:o}=e,{minWidth:r=void 0}=e,{marginRight:a=void 0}=e,{displayCtrlKey:s=!0}=e,{displayShiftKey:u=!0}=e,{displayAltKey:f=!0}=e,{displayMetaKey:p=!0}=e,{displayMouseButton:m=!0}=e,{displayMouseEvent:_=!0}=e,{disabledCtrlKey:b=!1}=e,{disabledShiftKey:g=!1}=e,{disabledAltKey:y=!1}=e,{disabledMetaKey:k=!1}=e,{disabledMouseButton:W=!1}=e,{disabledMouseEvent:S=!1}=e,{mouseButtonTitle:ee="Mouse Button"}=e,{mouseEventTitle:C="Mouse Event"}=e,{mouseButtonOptions:J=[{key:st.Left,text:"Left"},{key:st.Middle,text:"Middle"},{key:st.Right,text:"Right"},{key:st.Back,text:"Back"},{key:st.Forward,text:"Forward"}]}=e,{mouseEventOptions:z=[{key:me.click,text:me.click},{key:me.dblclick,text:me.dblclick},{key:me.mousedown,text:me.mousedown},{key:me.mouseup,text:me.mouseup},{key:me.mouseenter,text:me.mouseenter},{key:me.mouseleave,text:me.mouseleave},{key:me.mousewheel,text:me.mousewheel},{key:me.mouseover,text:me.mouseover},{key:me.mousemove,text:me.mousemove},{key:me.mouseout,text:me.mouseout}]}=e;const ne=jn();function Q(q){o.hasOwnProperty(q.detail.key)&&n(0,o[q.detail.key]=q.detail.value,o),ne("changed",{shortcut:o})}return t.$$set=q=>{"title"in q&&n(1,i=q.title),"shortcut"in q&&n(0,o=q.shortcut),"minWidth"in q&&n(2,r=q.minWidth),"marginRight"in q&&n(3,a=q.marginRight),"displayCtrlKey"in q&&n(4,s=q.displayCtrlKey),"displayShiftKey"in q&&n(5,u=q.displayShiftKey),"displayAltKey"in q&&n(6,f=q.displayAltKey),"displayMetaKey"in q&&n(7,p=q.displayMetaKey),"displayMouseButton"in q&&n(8,m=q.displayMouseButton),"displayMouseEvent"in q&&n(9,_=q.displayMouseEvent),"disabledCtrlKey"in q&&n(10,b=q.disabledCtrlKey),"disabledShiftKey"in q&&n(11,g=q.disabledShiftKey),"disabledAltKey"in q&&n(12,y=q.disabledAltKey),"disabledMetaKey"in q&&n(13,k=q.disabledMetaKey),"disabledMouseButton"in q&&n(14,W=q.disabledMouseButton),"disabledMouseEvent"in q&&n(15,S=q.disabledMouseEvent),"mouseButtonTitle"in q&&n(16,ee=q.mouseButtonTitle),"mouseEventTitle"in q&&n(17,C=q.mouseEventTitle),"mouseButtonOptions"in q&&n(18,J=q.mouseButtonOptions),"mouseEventOptions"in q&&n(19,z=q.mouseEventOptions)},[o,i,r,a,s,u,f,p,m,_,b,g,y,k,W,S,ee,C,J,z,Q]}class ws extends Ne{constructor(e){super(),Oe(this,e,cf,uf,$e,{title:1,shortcut:0,minWidth:2,marginRight:3,displayCtrlKey:4,displayShiftKey:5,displayAltKey:6,displayMetaKey:7,displayMouseButton:8,displayMouseEvent:9,disabledCtrlKey:10,disabledShiftKey:11,disabledAltKey:12,disabledMetaKey:13,disabledMouseButton:14,disabledMouseEvent:15,mouseButtonTitle:16,mouseEventTitle:17,mouseButtonOptions:18,mouseEventOptions:19})}}function ff(t=!0,e=(n=>(n=globalThis.process)==null?void 0:n.platform)()==="darwin"){const i=[{role:"about"},...e?[{type:"separator"},{role:"help"},{type:"separator"},{role:"services"},{type:"separator"},{role:"hide"},{role:"hideOthers"},{role:"unhide"}]:[],{type:"separator"},{role:"quit"}],o=[...e?[{role:"recentDocuments"},{role:"clearRecentDocuments"},{type:"separator"}]:[],{role:"close"}],r=[{role:"undo"},{role:"redo"},{type:"separator"},{role:"cut"},{role:"copy"},{role:"paste"},{role:"pasteAndMatchStyle"},{role:"delete"},{type:"separator"},{role:"selectAll"},{type:"separator"},{role:"toggleSpellChecker"},...e?[{type:"separator"},{role:"showSubstitutions"},{role:"toggleTextReplacement"},{type:"separator"},{role:"toggleSmartQuotes"},{role:"toggleSmartDashes"},{type:"separator"},{role:"startSpeaking"},{role:"stopSpeaking"}]:[]],a=[{role:"reload"},{role:"forceReload"},{type:"separator"},{role:"resetZoom"},{role:"zoomIn",accelerator:"CmdOrCtrl+="},{role:"zoomOut"},...e?[{role:"zoom"},{type:"separator"},{role:"front"}]:[{type:"separator"},{label:"Toggle On Top",click:(f,p,m)=>{p&&p.setAlwaysOnTop(!p.isAlwaysOnTop())},type:"checkbox",checked:t,accelerator:"CmdOrCtrl+Shift+Space"}],{role:"togglefullscreen"},{type:"separator"},{role:"toggleDevTools"}],s=[...e?[{role:"window"},{type:"separator"},{role:"toggleTabBar"},{role:"selectNextTab"},{role:"selectPreviousTab"},{role:"mergeAllWindows"},{role:"moveTabToNewWindow"},{type:"separator"}]:[],{role:"minimize"},{role:"close"}],u=[{role:"appMenu",submenu:i},{role:"fileMenu",submenu:o},{role:"editMenu",submenu:r},{role:"viewMenu",submenu:a},{role:"windowMenu",submenu:s}];return e&&u.push({role:"shareMenu"}),u}var He=(t=>(t[t.AlwaysShow=0]="AlwaysShow",t[t.AutoHide=1]="AutoHide",t[t.Disabled=2]="Disabled",t))(He||{});function pf(t,e,n,i,o){n.webPreferences=vn(n.webPreferences||{},i);const r=vn(e,n);if(ns())try{r.center&&(delete r.x,delete r.y);const{BrowserWindow:a,Menu:s}=globalThis.require("@electron/remote"),u=new a(r);if(r.enableMenuBar){const f=s.buildFromTemplate(ff(r.alwaysOnTop));u.setMenu(f)}else u.removeMenu();return r.enableElectron&&globalThis.require("@electron/remote").require("@electron/remote/main").enable(u.webContents),u.loadURL(t.href,{userAgent:o.useragent}),u}catch(a){o.logger.warn(a)}else return r.center&&(r.x=(globalThis.screen.width-r.width)/2,r.y=(globalThis.screen.height-r.height)/2),console.debug(globalThis.screen,r),globalThis.open(t.href,t.href,["popup = true",`width = ${r.width}`,`height = ${r.height}`,`left = ${r.x}`,`top = ${r.y}`].join(", "))}function No(t,e,n){const i=t.slice();return i[31]=e[n][0],i[32]=e[n][1],i[33]=e,i[34]=n,i}function Io(t,e,n){const i=t.slice();return i[31]=e[n][0],i[32]=e[n][1],i[35]=e,i[36]=n,i}function hf(t){let e,n;return e=new ae({props:{slot:"input",type:te.text,block:!0,placeholder:globalThis.navigator.userAgent,settingKey:"Text",settingValue:t[0].general.useragent}}),e.$on("changed",t[7]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].general.useragent),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function df(t){let e,n;return e=new ae({props:{slot:"input",type:te.text,settingKey:"text",settingValue:t[0].general.background}}),e.$on("changed",t[8]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].general.background),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function mf(t){let e,n;return e=new ae({props:{slot:"input",type:te.button,settingKey:"Reset",settingValue:t[2].settings.generalSettings.reset.text}}),e.$on("clicked",t[4]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p:oe,i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function gf(t){let e,n,i,o,r,a;return e=new Te({props:{title:t[2].settings.generalSettings.useragent.title,text:t[2].settings.generalSettings.useragent.description,block:!0,$$slots:{input:[hf]},$$scope:{ctx:t}}}),i=new Te({props:{title:t[2].settings.background.title,text:t[2].settings.background.description,$$slots:{input:[df]},$$scope:{ctx:t}}}),r=new Te({props:{title:t[2].settings.generalSettings.reset.title,text:t[2].settings.generalSettings.reset.description,$$slots:{input:[mf]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment),n=V(),P(i.$$.fragment),o=V(),P(r.$$.fragment)},m(s,u){I(e,s,u),D(s,n,u),I(i,s,u),D(s,o,u),I(r,s,u),a=!0},p(s,u){const f={};u[0]&1|u[1]&64&&(f.$$scope={dirty:u,ctx:s}),e.$set(f);const p={};u[0]&1|u[1]&64&&(p.$$scope={dirty:u,ctx:s}),i.$set(p);const m={};u[1]&64&&(m.$$scope={dirty:u,ctx:s}),r.$set(m)},i(s){a||(T(e.$$.fragment,s),T(i.$$.fragment,s),T(r.$$.fragment,s),a=!0)},o(s){E(e.$$.fragment,s),E(i.$$.fragment,s),E(r.$$.fragment,s),a=!1},d(s){s&&(F(n),F(o)),M(e,s),M(i,s),M(r,s)}}}function bf(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"Checkbox",settingValue:t[0].tab.enable}}),e.$on("changed",t[9]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].tab.enable),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function _f(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"Checkbox",settingValue:t[0].tab.open.targets.hyperlink.editor.enable}}),e.$on("changed",t[10]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].tab.open.targets.hyperlink.editor.enable),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function yf(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"Checkbox",settingValue:t[0].tab.open.targets.hyperlink.other.enable}}),e.$on("changed",t[11]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].tab.open.targets.hyperlink.other.enable),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function wf(t){let e,n=t[32].prefix+"",i;return{c(){e=K("code"),i=Ke(n),$(e,"slot","title"),$(e,"class","fn__code")},m(o,r){D(o,e,r),H(e,i)},p(o,r){r[0]&1&&n!==(n=o[32].prefix+"")&&Bt(i,n)},d(o){o&&F(e)}}}function kf(t){let e,n;function i(...o){return t[12](t[32],t[35],t[36],...o)}return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"Checkbox",settingValue:t[32].enable}}),e.$on("changed",i),{c(){P(e.$$.fragment)},m(o,r){I(e,o,r),n=!0},p(o,r){t=o;const a={};r[0]&1&&(a.settingValue=t[32].enable),e.$set(a)},i(o){n||(T(e.$$.fragment,o),n=!0)},o(o){E(e.$$.fragment,o),n=!1},d(o){M(e,o)}}}function Mo(t,e){let n,i,o;return i=new St({props:{minWidth:"8em",$$slots:{input:[kf],title:[wf]},$$scope:{ctx:e}}}),{key:t,first:null,c(){n=ve(),P(i.$$.fragment),this.first=n},m(r,a){D(r,n,a),I(i,r,a),o=!0},p(r,a){e=r;const s={};a[0]&1|a[1]&64&&(s.$$scope={dirty:a,ctx:e}),i.$set(s)},i(r){o||(T(i.$$.fragment,r),o=!0)},o(r){E(i.$$.fragment,r),o=!1},d(r){r&&F(n),M(i,r)}}}function Tf(t){let e=[],n=new Map,i,o,r=De(Object.entries(t[0].tab.open.protocols));const a=s=>s[31];for(let s=0;s({30:i}),({focus:i})=>[i?1073741824:0]]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1073741825|o[1]&64&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Sf(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"enable",settingValue:t[0].window.enable}}),e.$on("changed",t[13]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.enable),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Af(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"editorHyperlink",settingValue:t[0].window.open.targets.hyperlink.editor}}),e.$on("changed",t[14]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.open.targets.hyperlink.editor),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function $f(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"otherHyperlink",settingValue:t[0].window.open.targets.hyperlink.other}}),e.$on("changed",t[15]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.open.targets.hyperlink.other),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Rf(t){let e,n;return e=new ae({props:{slot:"input",type:te.number,settingKey:"width",settingValue:t[0].window.params.width,limits:{min:320,max:15360,step:40}}}),e.$on("changed",t[16]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.params.width),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function vf(t){let e,n;return e=new ae({props:{slot:"input",type:te.number,settingKey:"height",settingValue:t[0].window.params.height,limits:{min:240,max:8640,step:40}}}),e.$on("changed",t[17]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.params.height),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Cf(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"center",settingValue:t[0].window.params.center}}),e.$on("changed",t[18]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.params.center),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Lf(t){let e,n;return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"top",settingValue:t[0].window.params.alwaysOnTop}}),e.$on("changed",t[19]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.params.alwaysOnTop),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Of(t){let e,n;return e=new ae({props:{slot:"input",type:te.select,settingKey:"menuBar",settingValue:t[0].window.params.enableMenuBar?t[0].window.params.autoHideMenuBar?He.AutoHide:He.AlwaysShow:He.Disabled,options:[{key:He.AutoHide,text:t[2].settings.window.menuBar.options.autoHide},{key:He.AlwaysShow,text:t[2].settings.window.menuBar.options.alwaysShow},{key:He.Disabled,text:t[2].settings.window.menuBar.options.disabled}]}}),e.$on("changed",t[20]),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1&&(r.settingValue=i[0].window.params.enableMenuBar?i[0].window.params.autoHideMenuBar?He.AutoHide:He.AlwaysShow:He.Disabled),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Nf(t){let e,n=t[32].prefix+"",i;return{c(){e=K("code"),i=Ke(n),$(e,"slot","title"),$(e,"class","fn__code")},m(o,r){D(o,e,r),H(e,i)},p(o,r){r[0]&1&&n!==(n=o[32].prefix+"")&&Bt(i,n)},d(o){o&&F(e)}}}function If(t){let e,n;function i(...o){return t[21](t[32],t[33],t[34],...o)}return e=new ae({props:{slot:"input",type:te.checkbox,settingKey:"Checkbox",settingValue:t[32].enable}}),e.$on("changed",i),{c(){P(e.$$.fragment)},m(o,r){I(e,o,r),n=!0},p(o,r){t=o;const a={};r[0]&1&&(a.settingValue=t[32].enable),e.$set(a)},i(o){n||(T(e.$$.fragment,o),n=!0)},o(o){E(e.$$.fragment,o),n=!1},d(o){M(e,o)}}}function Fo(t,e){let n,i,o;return i=new St({props:{minWidth:"8em",$$slots:{input:[If],title:[Nf]},$$scope:{ctx:e}}}),{key:t,first:null,c(){n=ve(),P(i.$$.fragment),this.first=n},m(r,a){D(r,n,a),I(i,r,a),o=!0},p(r,a){e=r;const s={};a[0]&1|a[1]&64&&(s.$$scope={dirty:a,ctx:e}),i.$set(s)},i(r){o||(T(i.$$.fragment,r),o=!0)},o(r){E(i.$$.fragment,r),o=!1},d(r){r&&F(n),M(i,r)}}}function Mf(t){let e=[],n=new Map,i,o,r=De(Object.entries(t[0].window.open.protocols));const a=s=>s[31];for(let s=0;s({30:i}),({focus:i})=>[i?1073741824:0]]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&1073741827|o[1]&64&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Hf(t){let e,n,i,o,r,a;return e=new Qn({props:{display:t[5][0].key===t[29],$$slots:{default:[gf]},$$scope:{ctx:t}}}),i=new Qn({props:{display:t[5][1].key===t[29],$$slots:{default:[Bf]},$$scope:{ctx:t}}}),r=new Qn({props:{display:t[5][2].key===t[29],$$slots:{default:[qf]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment),n=V(),P(i.$$.fragment),o=V(),P(r.$$.fragment)},m(s,u){I(e,s,u),D(s,n,u),I(i,s,u),D(s,o,u),I(r,s,u),a=!0},p(s,u){const f={};u[0]&536870912&&(f.display=s[5][0].key===s[29]),u[0]&1|u[1]&64&&(f.$$scope={dirty:u,ctx:s}),e.$set(f);const p={};u[0]&536870912&&(p.display=s[5][1].key===s[29]),u[0]&1|u[1]&64&&(p.$$scope={dirty:u,ctx:s}),i.$set(p);const m={};u[0]&536870912&&(m.display=s[5][2].key===s[29]),u[0]&3|u[1]&64&&(m.$$scope={dirty:u,ctx:s}),r.$set(m)},i(s){a||(T(e.$$.fragment,s),T(i.$$.fragment,s),T(r.$$.fragment,s),a=!0)},o(s){E(e.$$.fragment,s),E(i.$$.fragment,s),E(r.$$.fragment,s),a=!1},d(s){s&&(F(n),F(o)),M(e,s),M(i,s),M(r,s)}}}function Kf(t){let e,n;return e=new nc({props:{panels:t[5],focus:xf,$$slots:{default:[Hf,({focus:i})=>({29:i}),({focus:i})=>[i?536870912:0]]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&536870915|o[1]&64&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}let xf=0,Vf=0,zf=0;function Gf(t,e,n){let{config:i}=e,{plugin:o}=e;const r=o.i18n;function a(){o.updateConfig(i)}function s(){o.siyuan.confirm(r.settings.generalSettings.reset.title,r.settings.generalSettings.reset.description,async()=>{await o.resetConfig(),globalThis.location.reload()})}const u=[{key:0,text:r.settings.generalSettings.title,name:r.settings.generalSettings.title,icon:"#iconSettings"},{key:1,text:r.settings.openTab,name:r.settings.openTab,icon:"#iconBoth"},{key:2,text:r.settings.openWindow,name:r.settings.openWindow,icon:"#iconOpenWindow"}],f={tab:[{key:0,text:r.settings.general,name:r.settings.general,icon:"⚙"},{key:1,text:r.settings.protocol,name:r.settings.protocol,icon:"🌐"},{key:2,text:r.settings.shortcut,name:r.settings.shortcut,icon:"⌨"}],window:[{key:0,text:r.settings.general,name:r.settings.general,icon:"⚙"},{key:1,text:r.settings.protocol,name:r.settings.protocol,icon:"🌐"},{key:2,text:r.settings.shortcut,name:r.settings.shortcut,icon:"⌨"},{key:3,text:r.settings.siyuan.title,name:r.settings.siyuan.title,icon:"📝"}]},p=G=>{n(0,i.general.useragent=G.detail.value,i),a()},m=G=>{n(0,i.general.background=G.detail.value,i),a()},_=G=>{n(0,i.tab.enable=G.detail.value,i),a()},b=G=>{n(0,i.tab.open.targets.hyperlink.editor.enable=G.detail.value,i),a()},g=G=>{n(0,i.tab.open.targets.hyperlink.other.enable=G.detail.value,i),a()},y=(G,Ie,it,Fe)=>{n(0,Ie[it][1].enable=Fe.detail.value,i),a()},k=G=>{n(0,i.window.enable=G.detail.value,i),a()},W=G=>{n(0,i.window.open.targets.hyperlink.editor=G.detail.value,i),a()},S=G=>{n(0,i.window.open.targets.hyperlink.other=G.detail.value,i),a()},ee=G=>{n(0,i.window.params.width=G.detail.value,i),a()},C=G=>{n(0,i.window.params.height=G.detail.value,i),a()},J=G=>{n(0,i.window.params.center=G.detail.value,i),a()},z=G=>{n(0,i.window.params.alwaysOnTop=G.detail.value,i),a()},ne=G=>{switch(G.detail.value){case He.AutoHide:n(0,i.window.params.enableMenuBar=!0,i),n(0,i.window.params.autoHideMenuBar=!0,i);break;case He.AlwaysShow:n(0,i.window.params.enableMenuBar=!0,i),n(0,i.window.params.autoHideMenuBar=!1,i);break;case He.Disabled:n(0,i.window.params.enableMenuBar=!1,i);break}a()},Q=(G,Ie,it,Fe)=>{n(0,Ie[it][1].enable=Fe.detail.value,i),a()},q=G=>{n(0,i.window.siyuan.enable=G.detail.value,i),a()},Le=G=>o.openSiyuanDesktopWindow(G.detail.event),Ue=G=>o.openSiyuanMobileWindow(G.detail.event),ht=G=>{n(0,i.window.siyuan.focus=G.detail.value,i),a()},We=G=>{n(0,i.window.siyuan.editorType=G.detail.value,i),a()};return t.$$set=G=>{"config"in G&&n(0,i=G.config),"plugin"in G&&n(1,o=G.plugin)},[i,o,r,a,s,u,f,p,m,_,b,g,y,k,W,S,ee,C,J,z,ne,Q,q,Le,Ue,ht,We]}class Yf extends Ne{constructor(e){super(),Oe(this,e,Gf,Kf,$e,{config:0,plugin:1},null,[-1,-1])}}function Po(t,{delay:e=0,duration:n=400,easing:i=ki}={}){const o=+getComputedStyle(t).opacity;return{delay:e,duration:n,easing:i,css:r=>`opacity: ${r*o}`}}const Jf=t=>({}),Do=t=>({});function Uo(t){let e,n;return e=new Je({props:{id:t[1],icon:t[2]}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&2&&(r.id=i[1]),o&4&&(r.icon=i[2]),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Xf(t){let e,n,i=t[2]&&Uo(t);return{c(){i&&i.c(),e=ve()},m(o,r){i&&i.m(o,r),D(o,e,r),n=!0},p(o,r){o[2]?i?(i.p(o,r),r&4&&T(i,1)):(i=Uo(o),i.c(),T(i,1),i.m(e.parentNode,e)):i&&(ge(),E(i,1,1,()=>{i=null}),be())},i(o){n||(T(i),n=!0)},o(o){E(i),n=!1},d(o){o&&F(e),i&&i.d(o)}}}function Qf(t){let e,n,i,o,r;const a=t[8].svg,s=Ee(a,t,t[7],Do),u=s||Xf(t);return{c(){e=K("span"),u&&u.c(),n=V(),i=K("span"),o=Ke(t[3]),$(i,"title",t[4]),$(i,"class","protyle-breadcrumb__text"),j(i,"protyle-breadcrumb__text--ellipsis",t[5]),$(e,"data-node-id",t[0]),$(e,"class","protyle-breadcrumb__item"),j(e,"protyle-breadcrumb__item--active",t[6])},m(f,p){D(f,e,p),u&&u.m(e,null),H(e,n),H(e,i),H(i,o),r=!0},p(f,[p]){s?s.p&&(!r||p&128)&&Se(s,a,f,f[7],r?Be(a,f[7],p,Jf):Ae(f[7]),Do):u&&u.p&&(!r||p&6)&&u.p(f,r?p:-1),(!r||p&8)&&Bt(o,f[3]),(!r||p&16)&&$(i,"title",f[4]),(!r||p&32)&&j(i,"protyle-breadcrumb__text--ellipsis",f[5]),(!r||p&1)&&$(e,"data-node-id",f[0]),(!r||p&64)&&j(e,"protyle-breadcrumb__item--active",f[6])},i(f){r||(T(u,f),r=!0)},o(f){E(u,f),r=!1},d(f){f&&F(e),u&&u.d(f)}}}function Zf(t,e,n){let{$$slots:i={},$$scope:o}=e,{itemId:r=""}=e,{iconId:a=""}=e,{icon:s=""}=e,{text:u=""}=e,{textTitle:f=""}=e,{textEllipsis:p=!0}=e,{active:m=!1}=e;return t.$$set=_=>{"itemId"in _&&n(0,r=_.itemId),"iconId"in _&&n(1,a=_.iconId),"icon"in _&&n(2,s=_.icon),"text"in _&&n(3,u=_.text),"textTitle"in _&&n(4,f=_.textTitle),"textEllipsis"in _&&n(5,p=_.textEllipsis),"active"in _&&n(6,m=_.active),"$$scope"in _&&n(7,o=_.$$scope)},[r,a,s,u,f,p,m,o,i]}class ep extends Ne{constructor(e){super(),Oe(this,e,Zf,Qf,$e,{itemId:0,iconId:1,icon:2,text:3,textTitle:4,textEllipsis:5,active:6})}}function Wo(t,e,n){const i=t.slice();return i[3]=e[n],i[5]=n,i}function tp(t){let e,n;return e=new Je({props:{className:"protyle-breadcrumb__arrow",icon:t[3].icon||"#iconRight"}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&1&&(r.icon=i[3].icon||"#iconRight"),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function np(t){let e,n;const i=[t[3]];let o={};for(let r=0;r{u[_]=null}),be()),~i?(o=u[i],o?o.p(e,m):(o=u[i]=s[i](e),o.c()),T(o,1),o.m(r.parentNode,r)):o=null)},i(p){a||(T(o),a=!0)},o(p){E(o),a=!1},d(p){p&&(F(n),F(r)),~i&&u[i].d(p)}}}function ip(t){let e=[],n=new Map,i,o,r=De(t[0]);const a=s=>s[5];for(let s=0;s{"items"in a&&n(0,r=a.items),"$$scope"in a&&n(1,o=a.$$scope)},[r,o,i]}class sp extends Ne{constructor(e){super(),Oe(this,e,rp,op,$e,{items:0})}}const vt=[];function wt(t,e=oe){let n;const i=new Set;function o(s){if($e(t,s)&&(t=s,n)){const u=!vt.length;for(const f of i)f[1](),vt.push(f,t);if(u){for(let f=0;f{i.delete(f),i.size===0&&n&&(n(),n=null)}}return{set:o,update:r,subscribe:a}}var Ze=(t=>(t.none="",t.n="b3-tooltips__n",t.ne="b3-tooltips__ne",t.e="b3-tooltips__e",t.se="b3-tooltips__se",t.s="b3-tooltips__s",t.sw="b3-tooltips__sw",t.w="b3-tooltips__w",t.nw="b3-tooltips__nw",t))(Ze||{});function Zn(t){let e,n,i,o,r,a;n=new Je({props:{icon:t[0]}});let s=[{role:"button"},{"data-type":t[5]},{"aria-label":t[6]},{class:i="block__icon fn__flex-center "+t[7]}],u={};for(let f=0;fnull}=e,b;const g={icon:wt(i),show:wt(r),none:wt(a),active:wt(s),disabled:wt(u),type:wt(f),ariaLabel:wt(p),tooltipsDirection:wt(m)},y=[g.icon.subscribe(C=>n(0,i=C)),g.show.subscribe(C=>n(1,r=C)),g.none.subscribe(C=>n(2,a=C)),g.active.subscribe(C=>n(3,s=C)),g.disabled.subscribe(C=>n(4,u=C)),g.type.subscribe(C=>n(5,f=C)),g.ariaLabel.subscribe(C=>n(6,p=C)),g.tooltipsDirection.subscribe(C=>n(7,m=C))];Wu(()=>{y.forEach(C=>C())});function k(C){io.call(this,t,C)}function W(C){io.call(this,t,C)}function S(C){Jt[C?"unshift":"push"](()=>{b=C,n(10,b)})}const ee=C=>_(C,b,g);return t.$$set=C=>{"icon"in C&&n(0,i=C.icon),"tag"in C&&n(8,o=C.tag),"show"in C&&n(1,r=C.show),"none"in C&&n(2,a=C.none),"active"in C&&n(3,s=C.active),"disabled"in C&&n(4,u=C.disabled),"type"in C&&n(5,f=C.type),"ariaLabel"in C&&n(6,p=C.ariaLabel),"tooltipsDirection"in C&&n(7,m=C.tooltipsDirection),"onClick"in C&&n(9,_=C.onClick)},t.$$.update=()=>{t.$$.dirty&1&&g.icon.set(i),t.$$.dirty&2&&g.show.set(r),t.$$.dirty&4&&g.none.set(a),t.$$.dirty&8&&g.active.set(s),t.$$.dirty&16&&g.disabled.set(u),t.$$.dirty&32&&g.type.set(f),t.$$.dirty&64&&g.ariaLabel.set(p),t.$$.dirty&128&&g.tooltipsDirection.set(m)},[i,r,a,s,u,f,p,m,o,_,b,g,k,W,S,ee]}class kt extends Ne{constructor(e){super(),Oe(this,e,lp,ap,$e,{icon:0,tag:8,show:1,none:2,active:3,disabled:4,type:5,ariaLabel:6,tooltipsDirection:7,onClick:9})}}function qo(t,e,n){const i=t.slice();return i[4]=e[n],i[6]=n,i}const up=t=>({}),Ho=t=>({}),cp=t=>({}),Ko=t=>({});function fp(t){let e,n;return e=new sp({props:{items:t[0]}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&1&&(r.items=i[0]),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function pp(t){let e;return{c(){e=K("span"),$(e,"class","fn__space")},m(n,i){D(n,e,i)},d(n){n&&F(e)}}}function hp(t){let e;return{c(){e=K("span"),$(e,"class","protyle-breadcrumb__space")},m(n,i){D(n,e,i)},d(n){n&&F(e)}}}function xo(t,e){let n,i,o,r;function a(m,_){return m[6]===0?hp:pp}let s=a(e),u=s(e);const f=[e[4]];let p={};for(let m=0;ms[6];for(let s=0;s{"items"in s&&n(0,r=s.items),"icons"in s&&n(1,a=s.icons),"$$scope"in s&&n(2,o=s.$$scope)},[r,a,o,i]}class bp extends Ne{constructor(e){super(),Oe(this,e,gp,mp,$e,{items:0,icons:1})}}const _p=t=>({}),Vo=t=>({}),yp=t=>({}),zo=t=>({});function Go(t){let e,n;return e=new bp({props:{items:t[2],icons:t[3]}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o&4&&(r.items=i[2]),o&8&&(r.icons=i[3]),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function wp(t){let e,n,i=t[1]&&Go(t);return{c(){i&&i.c(),e=ve()},m(o,r){i&&i.m(o,r),D(o,e,r),n=!0},p(o,r){o[1]?i?(i.p(o,r),r&2&&T(i,1)):(i=Go(o),i.c(),T(i,1),i.m(e.parentNode,e)):i&&(ge(),E(i,1,1,()=>{i=null}),be())},i(o){n||(T(i),n=!0)},o(o){E(i),n=!1},d(o){o&&F(e),i&&i.d(o)}}}function kp(t){let e,n,i,o;const r=t[5].breadcrumb,a=Ee(r,t,t[4],zo),s=a||wp(t),u=t[5].content,f=Ee(u,t,t[4],Vo);return{c(){e=K("div"),s&&s.c(),n=V(),i=K("div"),f&&f.c(),$(i,"class","protyle-preview"),$(e,"class","fn__flex-column"),j(e,"fullscreen",t[0])},m(p,m){D(p,e,m),s&&s.m(e,null),H(e,n),H(e,i),f&&f.m(i,null),o=!0},p(p,[m]){a?a.p&&(!o||m&16)&&Se(a,r,p,p[4],o?Be(r,p[4],m,yp):Ae(p[4]),zo):s&&s.p&&(!o||m&14)&&s.p(p,o?m:-1),f&&f.p&&(!o||m&16)&&Se(f,u,p,p[4],o?Be(u,p[4],m,_p):Ae(p[4]),Vo),(!o||m&1)&&j(e,"fullscreen",p[0])},i(p){o||(T(s,p),T(f,p),o=!0)},o(p){E(s,p),E(f,p),o=!1},d(p){p&&F(e),s&&s.d(p),f&&f.d(p)}}}function Tp(t,e,n){let{$$slots:i={},$$scope:o}=e,{fullscreen:r=!1}=e,{breadcrumb:a=!0}=e,{breadcrumbItems:s=[]}=e,{breadcrumbIcons:u=[]}=e;return t.$$set=f=>{"fullscreen"in f&&n(0,r=f.fullscreen),"breadcrumb"in f&&n(1,a=f.breadcrumb),"breadcrumbItems"in f&&n(2,s=f.breadcrumbItems),"breadcrumbIcons"in f&&n(3,u=f.breadcrumbIcons),"$$scope"in f&&n(4,o=f.$$scope)},[r,a,s,u,o,i]}class Ep extends Ne{constructor(e){super(),Oe(this,e,Tp,kp,$e,{fullscreen:0,breadcrumb:1,breadcrumbItems:2,breadcrumbIcons:3})}}const ks=$p();Rp();vp();function Bp(){return!!globalThis.require}function Sp(){return!!globalThis.process}function Ap(){var t,e;return!!((e=(t=globalThis.process)==null?void 0:t.versions)!=null&&e.hasOwnProperty("electron"))}function $p(){return Sp()&&Bp()&&Ap()}function Rp(){var t,e,n;return((n=(e=(t=globalThis.siyuan)==null?void 0:t.config)==null?void 0:e.appearance)==null?void 0:n.mode)===0}function vp(){var t,e,n;return((n=(e=(t=globalThis.siyuan)==null?void 0:t.config)==null?void 0:e.appearance)==null?void 0:n.mode)===1}const{replace:Cp}="",Lp=/[&<>'"]/g,Op={"&":"&","<":"<",">":">","'":"'",'"':"""},Np=t=>Op[t],Ct=t=>Cp.call(t,Lp,Np);var Ip={exports:{}};(function(t){(function(e,n){t.exports?t.exports=n():e.validDataUrl=n()})(zl,function(){function e(n){return e.regex.test((n||"").trim())}return e.regex=/^data:([a-z]+\/[a-z0-9-+.]+(;[a-z0-9-.!#$%*+.{}|~`]+=[a-z0-9-.!#$%*+.{}()_|~`]+)*)?(;base64)?,([a-z0-9!$&',()*+;=\-._~:@\/?%\s<>]*?)$/i,e})})(Ip);var Ts={},qn={};qn.byteLength=Pp;qn.toByteArray=Up;qn.fromByteArray=qp;var at=[],ze=[],Mp=typeof Uint8Array<"u"?Uint8Array:Array,ei="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var Lt=0,Fp=ei.length;Lt0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");n===-1&&(n=e);var i=n===e?0:4-n%4;return[n,i]}function Pp(t){var e=Es(t),n=e[0],i=e[1];return(n+i)*3/4-i}function Dp(t,e,n){return(e+n)*3/4-n}function Up(t){var e,n=Es(t),i=n[0],o=n[1],r=new Mp(Dp(t,i,o)),a=0,s=o>0?i-4:i,u;for(u=0;u>16&255,r[a++]=e>>8&255,r[a++]=e&255;return o===2&&(e=ze[t.charCodeAt(u)]<<2|ze[t.charCodeAt(u+1)]>>4,r[a++]=e&255),o===1&&(e=ze[t.charCodeAt(u)]<<10|ze[t.charCodeAt(u+1)]<<4|ze[t.charCodeAt(u+2)]>>2,r[a++]=e>>8&255,r[a++]=e&255),r}function Wp(t){return at[t>>18&63]+at[t>>12&63]+at[t>>6&63]+at[t&63]}function jp(t,e,n){for(var i,o=[],r=e;rs?s:a+r));return i===1?(e=t[n-1],o.push(at[e>>2]+at[e<<4&63]+"==")):i===2&&(e=(t[n-2]<<8)+t[n-1],o.push(at[e>>10]+at[e>>4&63]+at[e<<2&63]+"=")),o.join("")}var Ai={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */Ai.read=function(t,e,n,i,o){var r,a,s=o*8-i-1,u=(1<>1,p=-7,m=n?o-1:0,_=n?-1:1,b=t[e+m];for(m+=_,r=b&(1<<-p)-1,b>>=-p,p+=s;p>0;r=r*256+t[e+m],m+=_,p-=8);for(a=r&(1<<-p)-1,r>>=-p,p+=i;p>0;a=a*256+t[e+m],m+=_,p-=8);if(r===0)r=1-f;else{if(r===u)return a?NaN:(b?-1:1)*(1/0);a=a+Math.pow(2,i),r=r-f}return(b?-1:1)*a*Math.pow(2,r-i)};Ai.write=function(t,e,n,i,o,r){var a,s,u,f=r*8-o-1,p=(1<>1,_=o===23?Math.pow(2,-24)-Math.pow(2,-77):0,b=i?0:r-1,g=i?1:-1,y=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=p):(a=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-a))<1&&(a--,u*=2),a+m>=1?e+=_/u:e+=_*Math.pow(2,1-m),e*u>=2&&(a++,u/=2),a+m>=p?(s=0,a=p):a+m>=1?(s=(e*u-1)*Math.pow(2,o),a=a+m):(s=e*Math.pow(2,m-1)*Math.pow(2,o),a=0));o>=8;t[n+b]=s&255,b+=g,s/=256,o-=8);for(a=a<0;t[n+b]=a&255,b+=g,a/=256,f-=8);t[n+b-g]|=y*128};/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */(function(t){const e=qn,n=Ai,i=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=s,t.SlowBuffer=S,t.INSPECT_MAX_BYTES=50;const o=2147483647;t.kMaxLength=o,s.TYPED_ARRAY_SUPPORT=r(),!s.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function r(){try{const h=new Uint8Array(1),l={foo:function(){return 42}};return Object.setPrototypeOf(l,Uint8Array.prototype),Object.setPrototypeOf(h,l),h.foo()===42}catch{return!1}}Object.defineProperty(s.prototype,"parent",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,"offset",{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}});function a(h){if(h>o)throw new RangeError('The value "'+h+'" is invalid for option "size"');const l=new Uint8Array(h);return Object.setPrototypeOf(l,s.prototype),l}function s(h,l,c){if(typeof h=="number"){if(typeof l=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return m(h)}return u(h,l,c)}s.poolSize=8192;function u(h,l,c){if(typeof h=="string")return _(h,l);if(ArrayBuffer.isView(h))return g(h);if(h==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof h);if(ye(h,ArrayBuffer)||h&&ye(h.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ye(h,SharedArrayBuffer)||h&&ye(h.buffer,SharedArrayBuffer)))return y(h,l,c);if(typeof h=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const d=h.valueOf&&h.valueOf();if(d!=null&&d!==h)return s.from(d,l,c);const w=k(h);if(w)return w;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof h[Symbol.toPrimitive]=="function")return s.from(h[Symbol.toPrimitive]("string"),l,c);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof h)}s.from=function(h,l,c){return u(h,l,c)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array);function f(h){if(typeof h!="number")throw new TypeError('"size" argument must be of type number');if(h<0)throw new RangeError('The value "'+h+'" is invalid for option "size"')}function p(h,l,c){return f(h),h<=0?a(h):l!==void 0?typeof c=="string"?a(h).fill(l,c):a(h).fill(l):a(h)}s.alloc=function(h,l,c){return p(h,l,c)};function m(h){return f(h),a(h<0?0:W(h)|0)}s.allocUnsafe=function(h){return m(h)},s.allocUnsafeSlow=function(h){return m(h)};function _(h,l){if((typeof l!="string"||l==="")&&(l="utf8"),!s.isEncoding(l))throw new TypeError("Unknown encoding: "+l);const c=ee(h,l)|0;let d=a(c);const w=d.write(h,l);return w!==c&&(d=d.slice(0,w)),d}function b(h){const l=h.length<0?0:W(h.length)|0,c=a(l);for(let d=0;d=o)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o.toString(16)+" bytes");return h|0}function S(h){return+h!=h&&(h=0),s.alloc(+h)}s.isBuffer=function(l){return l!=null&&l._isBuffer===!0&&l!==s.prototype},s.compare=function(l,c){if(ye(l,Uint8Array)&&(l=s.from(l,l.offset,l.byteLength)),ye(c,Uint8Array)&&(c=s.from(c,c.offset,c.byteLength)),!s.isBuffer(l)||!s.isBuffer(c))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(l===c)return 0;let d=l.length,w=c.length;for(let B=0,R=Math.min(d,w);Bw.length?(s.isBuffer(R)||(R=s.from(R)),R.copy(w,B)):Uint8Array.prototype.set.call(w,R,B);else if(s.isBuffer(R))R.copy(w,B);else throw new TypeError('"list" argument must be an Array of Buffers');B+=R.length}return w};function ee(h,l){if(s.isBuffer(h))return h.length;if(ArrayBuffer.isView(h)||ye(h,ArrayBuffer))return h.byteLength;if(typeof h!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof h);const c=h.length,d=arguments.length>2&&arguments[2]===!0;if(!d&&c===0)return 0;let w=!1;for(;;)switch(l){case"ascii":case"latin1":case"binary":return c;case"utf8":case"utf-8":return ot(h).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return c*2;case"hex":return c>>>1;case"base64":return fe(h).length;default:if(w)return d?-1:ot(h).length;l=(""+l).toLowerCase(),w=!0}}s.byteLength=ee;function C(h,l,c){let d=!1;if((l===void 0||l<0)&&(l=0),l>this.length||((c===void 0||c>this.length)&&(c=this.length),c<=0)||(c>>>=0,l>>>=0,c<=l))return"";for(h||(h="utf8");;)switch(h){case"hex":return x(this,l,c);case"utf8":case"utf-8":return G(this,l,c);case"ascii":return Fe(this,l,c);case"latin1":case"binary":return xe(this,l,c);case"base64":return We(this,l,c);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return N(this,l,c);default:if(d)throw new TypeError("Unknown encoding: "+h);h=(h+"").toLowerCase(),d=!0}}s.prototype._isBuffer=!0;function J(h,l,c){const d=h[l];h[l]=h[c],h[c]=d}s.prototype.swap16=function(){const l=this.length;if(l%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let c=0;cc&&(l+=" ... "),""},i&&(s.prototype[i]=s.prototype.inspect),s.prototype.compare=function(l,c,d,w,B){if(ye(l,Uint8Array)&&(l=s.from(l,l.offset,l.byteLength)),!s.isBuffer(l))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof l);if(c===void 0&&(c=0),d===void 0&&(d=l?l.length:0),w===void 0&&(w=0),B===void 0&&(B=this.length),c<0||d>l.length||w<0||B>this.length)throw new RangeError("out of range index");if(w>=B&&c>=d)return 0;if(w>=B)return-1;if(c>=d)return 1;if(c>>>=0,d>>>=0,w>>>=0,B>>>=0,this===l)return 0;let R=B-w,Z=d-c;const he=Math.min(R,Z),pe=this.slice(w,B),de=l.slice(c,d);for(let se=0;se2147483647?c=2147483647:c<-2147483648&&(c=-2147483648),c=+c,je(c)&&(c=w?0:h.length-1),c<0&&(c=h.length+c),c>=h.length){if(w)return-1;c=h.length-1}else if(c<0)if(w)c=0;else return-1;if(typeof l=="string"&&(l=s.from(l,d)),s.isBuffer(l))return l.length===0?-1:ne(h,l,c,d,w);if(typeof l=="number")return l=l&255,typeof Uint8Array.prototype.indexOf=="function"?w?Uint8Array.prototype.indexOf.call(h,l,c):Uint8Array.prototype.lastIndexOf.call(h,l,c):ne(h,[l],c,d,w);throw new TypeError("val must be string, number or Buffer")}function ne(h,l,c,d,w){let B=1,R=h.length,Z=l.length;if(d!==void 0&&(d=String(d).toLowerCase(),d==="ucs2"||d==="ucs-2"||d==="utf16le"||d==="utf-16le")){if(h.length<2||l.length<2)return-1;B=2,R/=2,Z/=2,c/=2}function he(de,se){return B===1?de[se]:de.readUInt16BE(se*B)}let pe;if(w){let de=-1;for(pe=c;peR&&(c=R-Z),pe=c;pe>=0;pe--){let de=!0;for(let se=0;sew&&(d=w)):d=w;const B=l.length;d>B/2&&(d=B/2);let R;for(R=0;R>>0,isFinite(d)?(d=d>>>0,w===void 0&&(w="utf8")):(w=d,d=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const B=this.length-c;if((d===void 0||d>B)&&(d=B),l.length>0&&(d<0||c<0)||c>this.length)throw new RangeError("Attempt to write outside buffer bounds");w||(w="utf8");let R=!1;for(;;)switch(w){case"hex":return Q(this,l,c,d);case"utf8":case"utf-8":return q(this,l,c,d);case"ascii":case"latin1":case"binary":return Le(this,l,c,d);case"base64":return Ue(this,l,c,d);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ht(this,l,c,d);default:if(R)throw new TypeError("Unknown encoding: "+w);w=(""+w).toLowerCase(),R=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function We(h,l,c){return l===0&&c===h.length?e.fromByteArray(h):e.fromByteArray(h.slice(l,c))}function G(h,l,c){c=Math.min(h.length,c);const d=[];let w=l;for(;w239?4:B>223?3:B>191?2:1;if(w+Z<=c){let he,pe,de,se;switch(Z){case 1:B<128&&(R=B);break;case 2:he=h[w+1],(he&192)===128&&(se=(B&31)<<6|he&63,se>127&&(R=se));break;case 3:he=h[w+1],pe=h[w+2],(he&192)===128&&(pe&192)===128&&(se=(B&15)<<12|(he&63)<<6|pe&63,se>2047&&(se<55296||se>57343)&&(R=se));break;case 4:he=h[w+1],pe=h[w+2],de=h[w+3],(he&192)===128&&(pe&192)===128&&(de&192)===128&&(se=(B&15)<<18|(he&63)<<12|(pe&63)<<6|de&63,se>65535&&se<1114112&&(R=se))}}R===null?(R=65533,Z=1):R>65535&&(R-=65536,d.push(R>>>10&1023|55296),R=56320|R&1023),d.push(R),w+=Z}return it(d)}const Ie=4096;function it(h){const l=h.length;if(l<=Ie)return String.fromCharCode.apply(String,h);let c="",d=0;for(;dd)&&(c=d);let w="";for(let B=l;Bd&&(l=d),c<0?(c+=d,c<0&&(c=0)):c>d&&(c=d),cc)throw new RangeError("Trying to access beyond buffer length")}s.prototype.readUintLE=s.prototype.readUIntLE=function(l,c,d){l=l>>>0,c=c>>>0,d||X(l,c,this.length);let w=this[l],B=1,R=0;for(;++R>>0,c=c>>>0,d||X(l,c,this.length);let w=this[l+--c],B=1;for(;c>0&&(B*=256);)w+=this[l+--c]*B;return w},s.prototype.readUint8=s.prototype.readUInt8=function(l,c){return l=l>>>0,c||X(l,1,this.length),this[l]},s.prototype.readUint16LE=s.prototype.readUInt16LE=function(l,c){return l=l>>>0,c||X(l,2,this.length),this[l]|this[l+1]<<8},s.prototype.readUint16BE=s.prototype.readUInt16BE=function(l,c){return l=l>>>0,c||X(l,2,this.length),this[l]<<8|this[l+1]},s.prototype.readUint32LE=s.prototype.readUInt32LE=function(l,c){return l=l>>>0,c||X(l,4,this.length),(this[l]|this[l+1]<<8|this[l+2]<<16)+this[l+3]*16777216},s.prototype.readUint32BE=s.prototype.readUInt32BE=function(l,c){return l=l>>>0,c||X(l,4,this.length),this[l]*16777216+(this[l+1]<<16|this[l+2]<<8|this[l+3])},s.prototype.readBigUInt64LE=Qe(function(l){l=l>>>0,Y(l,"offset");const c=this[l],d=this[l+7];(c===void 0||d===void 0)&&ke(l,this.length-8);const w=c+this[++l]*2**8+this[++l]*2**16+this[++l]*2**24,B=this[++l]+this[++l]*2**8+this[++l]*2**16+d*2**24;return BigInt(w)+(BigInt(B)<>>0,Y(l,"offset");const c=this[l],d=this[l+7];(c===void 0||d===void 0)&&ke(l,this.length-8);const w=c*2**24+this[++l]*2**16+this[++l]*2**8+this[++l],B=this[++l]*2**24+this[++l]*2**16+this[++l]*2**8+d;return(BigInt(w)<>>0,c=c>>>0,d||X(l,c,this.length);let w=this[l],B=1,R=0;for(;++R=B&&(w-=Math.pow(2,8*c)),w},s.prototype.readIntBE=function(l,c,d){l=l>>>0,c=c>>>0,d||X(l,c,this.length);let w=c,B=1,R=this[l+--w];for(;w>0&&(B*=256);)R+=this[l+--w]*B;return B*=128,R>=B&&(R-=Math.pow(2,8*c)),R},s.prototype.readInt8=function(l,c){return l=l>>>0,c||X(l,1,this.length),this[l]&128?(255-this[l]+1)*-1:this[l]},s.prototype.readInt16LE=function(l,c){l=l>>>0,c||X(l,2,this.length);const d=this[l]|this[l+1]<<8;return d&32768?d|4294901760:d},s.prototype.readInt16BE=function(l,c){l=l>>>0,c||X(l,2,this.length);const d=this[l+1]|this[l]<<8;return d&32768?d|4294901760:d},s.prototype.readInt32LE=function(l,c){return l=l>>>0,c||X(l,4,this.length),this[l]|this[l+1]<<8|this[l+2]<<16|this[l+3]<<24},s.prototype.readInt32BE=function(l,c){return l=l>>>0,c||X(l,4,this.length),this[l]<<24|this[l+1]<<16|this[l+2]<<8|this[l+3]},s.prototype.readBigInt64LE=Qe(function(l){l=l>>>0,Y(l,"offset");const c=this[l],d=this[l+7];(c===void 0||d===void 0)&&ke(l,this.length-8);const w=this[l+4]+this[l+5]*2**8+this[l+6]*2**16+(d<<24);return(BigInt(w)<>>0,Y(l,"offset");const c=this[l],d=this[l+7];(c===void 0||d===void 0)&&ke(l,this.length-8);const w=(c<<24)+this[++l]*2**16+this[++l]*2**8+this[++l];return(BigInt(w)<>>0,c||X(l,4,this.length),n.read(this,l,!0,23,4)},s.prototype.readFloatBE=function(l,c){return l=l>>>0,c||X(l,4,this.length),n.read(this,l,!1,23,4)},s.prototype.readDoubleLE=function(l,c){return l=l>>>0,c||X(l,8,this.length),n.read(this,l,!0,52,8)},s.prototype.readDoubleBE=function(l,c){return l=l>>>0,c||X(l,8,this.length),n.read(this,l,!1,52,8)};function re(h,l,c,d,w,B){if(!s.isBuffer(h))throw new TypeError('"buffer" argument must be a Buffer instance');if(l>w||lh.length)throw new RangeError("Index out of range")}s.prototype.writeUintLE=s.prototype.writeUIntLE=function(l,c,d,w){if(l=+l,c=c>>>0,d=d>>>0,!w){const Z=Math.pow(2,8*d)-1;re(this,l,c,d,Z,0)}let B=1,R=0;for(this[c]=l&255;++R>>0,d=d>>>0,!w){const Z=Math.pow(2,8*d)-1;re(this,l,c,d,Z,0)}let B=d-1,R=1;for(this[c+B]=l&255;--B>=0&&(R*=256);)this[c+B]=l/R&255;return c+d},s.prototype.writeUint8=s.prototype.writeUInt8=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,1,255,0),this[c]=l&255,c+1},s.prototype.writeUint16LE=s.prototype.writeUInt16LE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,2,65535,0),this[c]=l&255,this[c+1]=l>>>8,c+2},s.prototype.writeUint16BE=s.prototype.writeUInt16BE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,2,65535,0),this[c]=l>>>8,this[c+1]=l&255,c+2},s.prototype.writeUint32LE=s.prototype.writeUInt32LE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,4,4294967295,0),this[c+3]=l>>>24,this[c+2]=l>>>16,this[c+1]=l>>>8,this[c]=l&255,c+4},s.prototype.writeUint32BE=s.prototype.writeUInt32BE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,4,4294967295,0),this[c]=l>>>24,this[c+1]=l>>>16,this[c+2]=l>>>8,this[c+3]=l&255,c+4};function Xe(h,l,c,d,w){Re(l,d,w,h,c,7);let B=Number(l&BigInt(4294967295));h[c++]=B,B=B>>8,h[c++]=B,B=B>>8,h[c++]=B,B=B>>8,h[c++]=B;let R=Number(l>>BigInt(32)&BigInt(4294967295));return h[c++]=R,R=R>>8,h[c++]=R,R=R>>8,h[c++]=R,R=R>>8,h[c++]=R,c}function dt(h,l,c,d,w){Re(l,d,w,h,c,7);let B=Number(l&BigInt(4294967295));h[c+7]=B,B=B>>8,h[c+6]=B,B=B>>8,h[c+5]=B,B=B>>8,h[c+4]=B;let R=Number(l>>BigInt(32)&BigInt(4294967295));return h[c+3]=R,R=R>>8,h[c+2]=R,R=R>>8,h[c+1]=R,R=R>>8,h[c]=R,c+8}s.prototype.writeBigUInt64LE=Qe(function(l,c=0){return Xe(this,l,c,BigInt(0),BigInt("0xffffffffffffffff"))}),s.prototype.writeBigUInt64BE=Qe(function(l,c=0){return dt(this,l,c,BigInt(0),BigInt("0xffffffffffffffff"))}),s.prototype.writeIntLE=function(l,c,d,w){if(l=+l,c=c>>>0,!w){const he=Math.pow(2,8*d-1);re(this,l,c,d,he-1,-he)}let B=0,R=1,Z=0;for(this[c]=l&255;++B>0)-Z&255;return c+d},s.prototype.writeIntBE=function(l,c,d,w){if(l=+l,c=c>>>0,!w){const he=Math.pow(2,8*d-1);re(this,l,c,d,he-1,-he)}let B=d-1,R=1,Z=0;for(this[c+B]=l&255;--B>=0&&(R*=256);)l<0&&Z===0&&this[c+B+1]!==0&&(Z=1),this[c+B]=(l/R>>0)-Z&255;return c+d},s.prototype.writeInt8=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,1,127,-128),l<0&&(l=255+l+1),this[c]=l&255,c+1},s.prototype.writeInt16LE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,2,32767,-32768),this[c]=l&255,this[c+1]=l>>>8,c+2},s.prototype.writeInt16BE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,2,32767,-32768),this[c]=l>>>8,this[c+1]=l&255,c+2},s.prototype.writeInt32LE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,4,2147483647,-2147483648),this[c]=l&255,this[c+1]=l>>>8,this[c+2]=l>>>16,this[c+3]=l>>>24,c+4},s.prototype.writeInt32BE=function(l,c,d){return l=+l,c=c>>>0,d||re(this,l,c,4,2147483647,-2147483648),l<0&&(l=4294967295+l+1),this[c]=l>>>24,this[c+1]=l>>>16,this[c+2]=l>>>8,this[c+3]=l&255,c+4},s.prototype.writeBigInt64LE=Qe(function(l,c=0){return Xe(this,l,c,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),s.prototype.writeBigInt64BE=Qe(function(l,c=0){return dt(this,l,c,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function mt(h,l,c,d,w,B){if(c+d>h.length)throw new RangeError("Index out of range");if(c<0)throw new RangeError("Index out of range")}function gt(h,l,c,d,w){return l=+l,c=c>>>0,w||mt(h,l,c,4),n.write(h,l,c,d,23,4),c+4}s.prototype.writeFloatLE=function(l,c,d){return gt(this,l,c,!0,d)},s.prototype.writeFloatBE=function(l,c,d){return gt(this,l,c,!1,d)};function bt(h,l,c,d,w){return l=+l,c=c>>>0,w||mt(h,l,c,8),n.write(h,l,c,d,52,8),c+8}s.prototype.writeDoubleLE=function(l,c,d){return bt(this,l,c,!0,d)},s.prototype.writeDoubleBE=function(l,c,d){return bt(this,l,c,!1,d)},s.prototype.copy=function(l,c,d,w){if(!s.isBuffer(l))throw new TypeError("argument should be a Buffer");if(d||(d=0),!w&&w!==0&&(w=this.length),c>=l.length&&(c=l.length),c||(c=0),w>0&&w=this.length)throw new RangeError("Index out of range");if(w<0)throw new RangeError("sourceEnd out of bounds");w>this.length&&(w=this.length),l.length-c>>0,d=d===void 0?this.length:d>>>0,l||(l=0);let B;if(typeof l=="number")for(B=c;B2**32?w=ce(String(c)):typeof c=="bigint"&&(w=String(c),(c>BigInt(2)**BigInt(32)||c<-(BigInt(2)**BigInt(32)))&&(w=ce(w)),w+="n"),d+=` It must be ${l}. Received ${w}`,d},RangeError);function ce(h){let l="",c=h.length;const d=h[0]==="-"?1:0;for(;c>=d+4;c-=3)l=`_${h.slice(c-3,c)}${l}`;return`${h.slice(0,c)}${l}`}function U(h,l,c){Y(l,"offset"),(h[l]===void 0||h[l+c]===void 0)&&ke(l,h.length-(c+1))}function Re(h,l,c,d,w,B){if(h>c||h3?l===0||l===BigInt(0)?Z=`>= 0${R} and < 2${R} ** ${(B+1)*8}${R}`:Z=`>= -(2${R} ** ${(B+1)*8-1}${R}) and < 2 ** ${(B+1)*8-1}${R}`:Z=`>= ${l}${R} and <= ${c}${R}`,new Ve.ERR_OUT_OF_RANGE("value",Z,h)}U(d,w,B)}function Y(h,l){if(typeof h!="number")throw new Ve.ERR_INVALID_ARG_TYPE(l,"number",h)}function ke(h,l,c){throw Math.floor(h)!==h?(Y(h,c),new Ve.ERR_OUT_OF_RANGE(c||"offset","an integer",h)):l<0?new Ve.ERR_BUFFER_OUT_OF_BOUNDS:new Ve.ERR_OUT_OF_RANGE(c||"offset",`>= ${c?1:0} and <= ${l}`,h)}const ct=/[^+/0-9A-Za-z-_]/g;function _t(h){if(h=h.split("=")[0],h=h.trim().replace(ct,""),h.length<2)return"";for(;h.length%4!==0;)h=h+"=";return h}function ot(h,l){l=l||1/0;let c;const d=h.length;let w=null;const B=[];for(let R=0;R55295&&c<57344){if(!w){if(c>56319){(l-=3)>-1&&B.push(239,191,189);continue}else if(R+1===d){(l-=3)>-1&&B.push(239,191,189);continue}w=c;continue}if(c<56320){(l-=3)>-1&&B.push(239,191,189),w=c;continue}c=(w-55296<<10|c-56320)+65536}else w&&(l-=3)>-1&&B.push(239,191,189);if(w=null,c<128){if((l-=1)<0)break;B.push(c)}else if(c<2048){if((l-=2)<0)break;B.push(c>>6|192,c&63|128)}else if(c<65536){if((l-=3)<0)break;B.push(c>>12|224,c>>6&63|128,c&63|128)}else if(c<1114112){if((l-=4)<0)break;B.push(c>>18|240,c>>12&63|128,c>>6&63|128,c&63|128)}else throw new Error("Invalid code point")}return B}function en(h){const l=[];for(let c=0;c>8,w=c%256,B.push(w),B.push(d);return B}function fe(h){return e.toByteArray(_t(h))}function Me(h,l,c,d){let w;for(w=0;w=l.length||w>=h.length);++w)l[w+c]=h[w];return w}function ye(h,l){return h instanceof l||h!=null&&h.constructor!=null&&h.constructor.name!=null&&h.constructor.name===l.name}function je(h){return h!==h}const $i=function(){const h="0123456789abcdef",l=new Array(256);for(let c=0;c<16;++c){const d=c*16;for(let w=0;w<16;++w)l[d+w]=h[c]+h[w]}return l}();function Qe(h){return typeof BigInt>"u"?Bs:h}function Bs(){throw new Error("BigInt not supported")}})(Ts);globalThis.Buffer=Ts.Buffer;function Hp(t,e){return`data:${e};base64,${t}`}var Xo,Qo;const O=(Qo=(Xo=globalThis==null?void 0:globalThis.require)==null?void 0:Xo.call(globalThis,"electron"))==null?void 0:Qo.clipboard;var on,Zo;(Zo=(on=O==null?void 0:O.availableFormats)==null?void 0:on.bind)==null||Zo.call(on,O);var rn,er;(er=(rn=O==null?void 0:O.clear)==null?void 0:rn.bind)==null||er.call(rn,O);var sn,tr;(tr=(sn=O==null?void 0:O.has)==null?void 0:sn.bind)==null||tr.call(sn,O);var an,nr;(nr=(an=O==null?void 0:O.read)==null?void 0:an.bind)==null||nr.call(an,O);var ln,ir;(ir=(ln=O==null?void 0:O.readBookmark)==null?void 0:ln.bind)==null||ir.call(ln,O);var un,or;(or=(un=O==null?void 0:O.readBuffer)==null?void 0:un.bind)==null||or.call(un,O);var cn,rr;(rr=(cn=O==null?void 0:O.readFindText)==null?void 0:cn.bind)==null||rr.call(cn,O);var fn,sr;(sr=(fn=O==null?void 0:O.readHTML)==null?void 0:fn.bind)==null||sr.call(fn,O);var pn,ar;(ar=(pn=O==null?void 0:O.readImage)==null?void 0:pn.bind)==null||ar.call(pn,O);var hn,lr;(lr=(hn=O==null?void 0:O.readRTF)==null?void 0:hn.bind)==null||lr.call(hn,O);var dn,ur;(ur=(dn=O==null?void 0:O.readText)==null?void 0:dn.bind)==null||ur.call(dn,O);var mn,cr;(cr=(mn=O==null?void 0:O.write)==null?void 0:mn.bind)==null||cr.call(mn,O);var gn,fr;(fr=(gn=O==null?void 0:O.writeBookmark)==null?void 0:gn.bind)==null||fr.call(gn,O);var bn,pr;(pr=(bn=O==null?void 0:O.writeBuffer)==null?void 0:bn.bind)==null||pr.call(bn,O);var _n,hr;(hr=(_n=O==null?void 0:O.writeFindText)==null?void 0:_n.bind)==null||hr.call(_n,O);var yn,dr;(dr=(yn=O==null?void 0:O.writeHTML)==null?void 0:yn.bind)==null||dr.call(yn,O);var wn,mr;(mr=(wn=O==null?void 0:O.writeImage)==null?void 0:wn.bind)==null||mr.call(wn,O);var kn,gr;(gr=(kn=O==null?void 0:O.writeRTF)==null?void 0:kn.bind)==null||gr.call(kn,O);var Tn,br;(br=(Tn=O==null?void 0:O.writeText)==null?void 0:Tn.bind)==null||br.call(Tn,O);var _r;const _e=(_r=globalThis==null?void 0:globalThis.require)==null?void 0:_r.call(globalThis,"electron");_e==null||_e.clipboard;_e==null||_e.contextBridge;_e==null||_e.crashReporter;_e==null||_e.ipcRenderer;const Kp=_e==null?void 0:_e.nativeImage;_e==null||_e.shell;_e==null||_e.webFrame;function xp(t){let e,n,i,o,r,a,s,u,f,p,m,_,b,g,y,k,W,S,ee;return n=new kt({props:{icon:"#iconLeft",ariaLabel:t[15].webview.goForwardOnePage,disabled:!t[5],tooltipsDirection:Ze.se}}),n.$on("click",t[16]),o=new kt({props:{icon:"#iconRight",ariaLabel:t[15].webview.goBackOnePage,disabled:!t[6],tooltipsDirection:Ze.se}}),o.$on("click",t[17]),a=new kt({props:{icon:t[7]?"#iconClose":"#iconRefresh",ariaLabel:t[7]?t[15].webview.stopLoadingThisPage:t[15].webview.reloadCurrentPage,tooltipsDirection:Ze.se}}),a.$on("click",t[18]),p=new kt({props:{icon:"#iconLanguage",ariaLabel:t[15].webview.openWithDefaultProgram,tooltipsDirection:Ze.sw}}),p.$on("click",t[20]),_=new kt({props:{icon:"#iconOpenWindow",ariaLabel:t[15].webview.openWithNewWindow,tooltipsDirection:Ze.sw}}),_.$on("click",t[21]),g=new kt({props:{icon:t[4]?"#iconFullscreenExit":"#iconFullscreen",ariaLabel:t[4]?t[15].webview.exitFullscreen:t[15].webview.enterFullscreen,active:t[4],tooltipsDirection:Ze.sw}}),g.$on("click",t[22]),k=new kt({props:{icon:"#iconBug",ariaLabel:t[9]?t[15].webview.closeDevTools:t[15].webview.openDevTools,active:t[9],tooltipsDirection:Ze.sw}}),k.$on("click",t[23]),{c(){e=K("div"),P(n.$$.fragment),i=V(),P(o.$$.fragment),r=V(),P(a.$$.fragment),s=V(),u=K("input"),f=V(),P(p.$$.fragment),m=V(),P(_.$$.fragment),b=V(),P(g.$$.fragment),y=V(),P(k.$$.fragment),$(u,"class","b3-text-field fn__flex-1 address-field svelte-1y82r3i"),$(u,"type","url"),$(e,"slot","breadcrumb"),$(e,"class","protyle-breadcrumb svelte-1y82r3i")},m(C,J){D(C,e,J),I(n,e,null),H(e,i),I(o,e,null),H(e,r),I(a,e,null),H(e,s),H(e,u),Pe(u,t[8]),H(e,f),I(p,e,null),H(e,m),I(_,e,null),H(e,b),I(g,e,null),H(e,y),I(k,e,null),W=!0,S||(ee=[ue(u,"change",t[19]),ue(u,"input",t[30])],S=!0)},p(C,J){const z={};J[0]&32&&(z.disabled=!C[5]),n.$set(z);const ne={};J[0]&64&&(ne.disabled=!C[6]),o.$set(ne);const Q={};J[0]&128&&(Q.icon=C[7]?"#iconClose":"#iconRefresh"),J[0]&128&&(Q.ariaLabel=C[7]?C[15].webview.stopLoadingThisPage:C[15].webview.reloadCurrentPage),a.$set(Q),J[0]&256&&u.value!==C[8]&&Pe(u,C[8]);const q={};J[0]&16&&(q.icon=C[4]?"#iconFullscreenExit":"#iconFullscreen"),J[0]&16&&(q.ariaLabel=C[4]?C[15].webview.exitFullscreen:C[15].webview.enterFullscreen),J[0]&16&&(q.active=C[4]),g.$set(q);const Le={};J[0]&512&&(Le.ariaLabel=C[9]?C[15].webview.closeDevTools:C[15].webview.openDevTools),J[0]&512&&(Le.active=C[9]),k.$set(Le)},i(C){W||(T(n.$$.fragment,C),T(o.$$.fragment,C),T(a.$$.fragment,C),T(p.$$.fragment,C),T(_.$$.fragment,C),T(g.$$.fragment,C),T(k.$$.fragment,C),W=!0)},o(C){E(n.$$.fragment,C),E(o.$$.fragment,C),E(a.$$.fragment,C),E(p.$$.fragment,C),E(_.$$.fragment,C),E(g.$$.fragment,C),E(k.$$.fragment,C),W=!1},d(C){C&&F(e),M(n),M(o),M(a),M(p),M(_),M(g),M(k),S=!1,Ce(ee)}}}function Vp(t){let e,n;return{c(){e=K("iframe"),Cn(e.src,n=t[0])||$(e,"src",n),$(e,"title",t[1]),$(e,"class","fn__flex-1"),e.allowFullscreen=!0,nt(e,"background",t[3])},m(i,o){D(i,e,o),t[29](e)},p(i,o){o[0]&1&&!Cn(e.src,n=i[0])&&$(e,"src",n),o[0]&2&&$(e,"title",i[1]),o[0]&8&&nt(e,"background",i[3])},d(i){i&&F(e),t[29](null)}}}function zp(t){let e,n;return{c(){e=K("webview"),Cn(e.src,n=t[0])||$(e,"src",n),$(e,"title",t[1]),$(e,"useragent",t[2]),$(e,"class","webview fn__flex-1 svelte-1y82r3i"),$(e,"allowpopups",""),j(e,"pointer-events-disable",t[12]),nt(e,"background",t[3])},m(i,o){D(i,e,o),t[28](e)},p(i,o){o[0]&1&&!Cn(e.src,n=i[0])&&$(e,"src",n),o[0]&2&&$(e,"title",i[1]),o[0]&4&&$(e,"useragent",i[2]),o[0]&4096&&j(e,"pointer-events-disable",i[12]),o[0]&8&&nt(e,"background",i[3])},d(i){i&&F(e),t[28](null)}}}function Yo(t){let e,n,i,o,r,a;return{c(){e=K("div"),n=K("span"),i=Ke(t[14]),$(e,"class","webview-status tooltip svelte-1y82r3i")},m(s,u){D(s,e,u),H(e,n),H(n,i),a=!0},p(s,u){(!a||u[0]&16384)&&Bt(i,s[14])},i(s){a||(s&&At(()=>{a&&(r&&r.end(1),o=xu(e,Po,{delay:0,duration:125}),o.start())}),a=!0)},o(s){o&&o.invalidate(),s&&(r=Vu(e,Po,{delay:500,duration:250})),a=!1},d(s){s&&F(e),s&&r&&r.end()}}}function Gp(t){let e,n,i,o;function r(f,p){return ks?zp:Vp}let s=r()(t),u=t[13]&&Yo(t);return{c(){e=K("div"),s.c(),n=V(),u&&u.c(),$(e,"slot","content"),$(e,"class","content fn__flex fn__flex-1 svelte-1y82r3i")},m(f,p){D(f,e,p),s.m(e,null),H(e,n),u&&u.m(e,null),i||(o=[ue(e,"mouseenter",Zi(t[24]),!0),ue(e,"mouseleave",Zi(t[25]),!0)],i=!0)},p(f,p){s.p(f,p),f[13]?u?(u.p(f,p),p[0]&8192&&T(u,1)):(u=Yo(f),u.c(),T(u,1),u.m(e,null)):u&&(ge(),E(u,1,1,()=>{u=null}),be())},d(f){f&&F(e),s.d(),u&&u.d(),i=!1,Ce(o)}}}function Yp(t){let e,n;return e=new Ep({props:{fullscreen:t[4],$$slots:{content:[Gp],breadcrumb:[xp]},$$scope:{ctx:t}}}),{c(){P(e.$$.fragment)},m(i,o){I(e,i,o),n=!0},p(i,o){const r={};o[0]&16&&(r.fullscreen=i[4]),o[0]&32767|o[1]&4&&(r.$$scope={dirty:o,ctx:i}),e.$set(r)},i(i){n||(T(e.$$.fragment,i),n=!0)},o(i){E(e.$$.fragment,i),n=!1},d(i){M(e,i)}}}function Jp(t,e,n){let{src:i}=e,{tab:o}=e,{plugin:r}=e,{title:a=""}=e,{useragent:s=r.useragent}=e,{background:u=r.background}=e;const f=r.i18n;let p,m=!1,_=!1,b=!1,g=!1,y=globalThis.decodeURIComponent(i),k=!1,W,S,ee=!1,C=!1,J="";function z(N){var X;if(ks)try{(X=S==null?void 0:S.loadURL)==null||X.call(S,N,{userAgent:s})}catch{n(0,i=N)}else n(0,i=N)}function ne(){var N;_&&((N=S==null?void 0:S.goBack)==null||N.call(S))}function Q(){var N;_&&((N=S==null?void 0:S.goBack)==null||N.call(S))}function q(){var N,X;g?(N=S==null?void 0:S.stop)==null||N.call(S):(X=S==null?void 0:S.reload)==null||X.call(S)}function Le(N){if(y)try{var X;try{X=new URL(y).href}catch{switch(!0){case y.startsWith("//"):{X=new URL(`https:${y}`).href;break}case os(y,!1):{X=new URL(`${globalThis.document.baseURI}${rs(y,"/")}`).href;break}default:{X=new URL(`https://${y}`).href;break}}}z(X)}catch(re){r.logger.warn(re),r.siyuan.showMessage(`${r.name}: +URL ${y} ${f.message.nonStandardURL} +`,void 0,"error")}}function Ue(){global.open(o.data.href,"_blank")}function ht(N){r.openWindow(o.data.href,{x:N.screenX,y:N.screenY,title:o.data.title})}function We(){n(4,m=!m)}function G(){var N,X,re;S&&((N=S==null?void 0:S.isDevToolsOpened)!=null&&N.call(S)?(X=S==null?void 0:S.closeDevTools)==null||X.call(S):(re=S==null?void 0:S.openDevTools)==null||re.call(S))}Uu(()=>{var N,X,re,Xe,dt,mt,gt,bt,Ve,ut;(N=S==null?void 0:S.addEventListener)==null||N.call(S,"load-commit",ce=>{var U,Re;ce.isMainFrame&&(n(8,y=globalThis.decodeURIComponent(ce.url)),n(26,o.data.href=ce.url,o)),n(5,_=(U=S==null?void 0:S.canGoBack)==null?void 0:U.call(S)),n(6,b=(Re=S==null?void 0:S.canGoForward)==null?void 0:Re.call(S))}),(X=S==null?void 0:S.addEventListener)==null||X.call(S,"page-title-updated",ce=>{n(1,a=ce.title),n(26,o.data.title=a,o),o.tab.updateTitle(a),n(26,o.tab.headElement.ariaLabel=a,o)}),(re=S==null?void 0:S.addEventListener)==null||re.call(S,"page-favicon-updated",ce=>{var Re;const U=ce.favicons;if((Re=o.tab.headElement.querySelector(".item__graphic"))==null||Re.remove(),U.length>0){const Y=U[0],ke=o.tab.headElement.querySelector(".item__icon");if(o.tab.docIcon!==Y||!ke){n(26,o.tab.docIcon=Y,o);const ct=``;ke?ke.innerHTML=ct:o.tab.headElement.insertAdjacentHTML("afterbegin",`${ct}`)}}else o.tab.setDocIcon("🌐".codePointAt(0).toString(16))}),(Xe=S==null?void 0:S.addEventListener)==null||Xe.call(S,"did-start-loading",ce=>{n(7,g=!0)}),(dt=S==null?void 0:S.addEventListener)==null||dt.call(S,"did-stop-loading",ce=>{n(7,g=!1)}),(mt=S==null?void 0:S.addEventListener)==null||mt.call(S,"devtools-open-url",ce=>{r.openWebviewTab(ce.url)}),(gt=S==null?void 0:S.addEventListener)==null||gt.call(S,"devtools-opened",ce=>n(9,k=!0)),(bt=S==null?void 0:S.addEventListener)==null||bt.call(S,"devtools-closed",ce=>n(9,k=!1)),(Ve=S==null?void 0:S.addEventListener)==null||Ve.call(S,"update-target-url",ce=>{ce.url?(n(14,J=globalThis.decodeURIComponent(ce.url)),C||n(13,C=!0)):n(13,C=!1)}),(ut=S==null?void 0:S.addEventListener)==null||ut.call(S,"context-menu",ce=>{r.logger.debug(ce);const{params:U}=ce,Re=U.titleText||U.linkText||U.altText||U.suggestedFilename,Y=[];function ke(L,fe,Me,ye=!0){const je=[];return ye&&(je.push({icon:"icon-webview-click",label:f.menu.openTabCurrent.label,action:Me,click:()=>z(L)}),je.push({type:"separator"})),je.push({icon:"iconAdd",label:f.menu.openTab.label,action:Me,click:()=>r.openWebviewTab(L,fe)}),je.push({icon:"iconMin",label:f.menu.openTabBackground.label,action:Me,click:()=>r.openWebviewTab(L,fe,void 0,{keepCursor:!0})}),je.push({icon:"iconLayoutRight",label:f.menu.openTabRight.label,action:Me,click:()=>r.openWebviewTab(L,fe,void 0,{position:"right"})}),je.push({icon:"iconLayoutBottom",label:f.menu.openTabBottom.label,action:Me,click:()=>r.openWebviewTab(L,fe,void 0,{position:"bottom"})}),je.push({type:"separator"}),je.push({icon:"iconOpenWindow",label:f.menu.openByNewWindow.label,action:Me,click:($i,Qe)=>(r.openWebpageWindow(L,fe,{screenX:Qe.screenX,screenY:Qe.screenY}),null)}),je}function ct(L){const fe=[];return L.linkURL&&fe.push({icon:"iconLink",label:f.menu.copyLinkAddress.label,action:"iconLink",click:()=>O.writeText(L.linkURL)}),L.srcURL&&fe.push({icon:"iconLink",label:f.menu.copyResourceAddress.label,action:"iconCloud",click:()=>O.writeText(L.srcURL)}),L.frameURL&&fe.push({icon:"iconLink",label:f.menu.copyFrameAddress.label,action:"iconLayout",click:()=>O.writeText(L.frameURL)}),L.pageURL&&fe.push({icon:"iconLink",label:f.menu.copyPageAddress.label,action:"iconFile",click:()=>O.writeText(L.pageURL)}),fe.push({type:"separator"}),L.titleText&&fe.push({icon:"icon-webview-title",label:f.menu.copyTitle.label,click:()=>O.writeText(L.titleText)}),L.altText&&fe.push({icon:"iconInfo",label:f.menu.copyAlt.label,click:()=>O.writeText(L.altText)}),L.linkText&&fe.push({icon:"icon-webview-anchor",label:f.menu.copyText.label,click:()=>O.writeText(L.linkText)}),L.suggestedFilename&&fe.push({icon:"iconN",label:f.menu.copyFileName.label,click:()=>O.writeText(L.suggestedFilename)}),fe}function _t(L,fe,Me){L=L||"🔗";const ye=[];return ye.push("["),ye.push(L.replaceAll("]","\\]").replaceAll(` +`,"")),ye.push("]("),ye.push(fe),Me&&ye.push(` "${Me.replaceAll(` +`,"").replaceAll("&","&").replaceAll('"',""")}"`),ye.push(")"),ye.join("")}function ot(...L){return L.filter(fe=>!!fe)}switch(U.selectionText&&(Y.push({icon:"icon-webview-select",label:f.menu.copySelectionText.label,click:()=>O.writeText(U.selectionText)}),Y.push({type:"separator"})),U.mediaType){case"none":case"file":case"canvas":case"plugin":default:{switch(!0){case!!U.linkURL:{Y.push(...ke(U.linkURL,Re,"iconLink")),Y.push({type:"separator"}),Y.push({icon:"iconLink",label:f.menu.copyLink.label,accelerator:Ct(""),click:()=>{const L=globalThis.document.createElement("a");L.href=U.linkURL,L.title=U.titleText,L.innerText=U.linkText,O.writeHTML(L.outerHTML)}}),Y.push({icon:"iconHTML5",label:f.menu.copyLink.label,accelerator:"HTML",click:()=>{const L=globalThis.document.createElement("a");L.href=U.linkURL,L.title=U.titleText,L.innerText=U.linkText,O.writeText(L.outerHTML)}}),Y.push({icon:"iconMarkdown",label:f.menu.copyLink.label,accelerator:"Markdown",click:()=>{const L=ot(U.linkText,U.altText,U.suggestedFilename,U.titleText);O.writeText(_t(L.shift(),U.linkURL,L.pop()))}});break}case!!U.frameURL:{Y.push(...ke(U.frameURL,Re,"iconLayout")),Y.push({type:"separator"}),Y.push({icon:"iconLayout",label:f.menu.copyFrame.label,accelerator:Ct("